From 2e9ca54c76d3f021adc042d8e728318cc5d44151 Mon Sep 17 00:00:00 2001 From: Eduardo Ponz Segrelles Date: Tue, 14 May 2024 08:05:19 +0200 Subject: [PATCH] Switch master to 3.0.x (#4758) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * GitHub CI for 3.0.x (#4358) * Refs #19452: Change github workflow for discovery-server Signed-off-by: elianalf <62831776+elianalf@users.noreply.github.com> * Refs #19452: Change github workflow for documentation Signed-off-by: elianalf <62831776+elianalf@users.noreply.github.com> --------- Signed-off-by: elianalf <62831776+elianalf@users.noreply.github.com> * Branch-out v3.0.0 (#4251) * Refs #19452: branch-out v3.0.0 Signed-off-by: JLBuenoLopez-eProsima * Refs #19452: update XML schema name Signed-off-by: JLBuenoLopez-eProsima * Refs #19452: remove doc legacy folder. Move github banner to resources folder Signed-off-by: JLBuenoLopez-eProsima * Refs #19452: remove .settings folder Signed-off-by: JLBuenoLopez-eProsima * Refs #19452: remove legacy m4 folder Signed-off-by: JLBuenoLopez-eProsima * Refs #19452: remove legace files from utils folder Signed-off-by: JLBuenoLopez-eProsima * Refs #19452: rename to FASTDDS_DEFAULT_PROFILES_FILE and FASTDDS_DEFAULT_PROFILES Signed-off-by: JLBuenoLopez-eProsima * Refs #19452: update XML Schema name Signed-off-by: JLBuenoLopez-eProsima * Refs #19452: update to Fast DDS, remove references to FastRTPS, remove legacy files Signed-off-by: JLBuenoLopez-eProsima * Refs #19452: update Doxygen modules Signed-off-by: JLBuenoLopez-eProsima * Refs #19452: examples, use fastdds headers instead of fastrtps ones Signed-off-by: JLBuenoLopez-eProsima * Refs #19452: rename security logging macros Signed-off-by: JLBuenoLopez-eProsima * Refs #19452: use fastdds headers Signed-off-by: JLBuenoLopez-eProsima * Refs #19452: update to fastdds headers in public headers Signed-off-by: JLBuenoLopez-eProsima * Refs #19452: update to Fast DDS configuration files. Rename deprecation macro Signed-off-by: JLBuenoLopez-eProsima * Refs #19452: use fastdds headers. Update header guards Signed-off-by: JLBuenoLopez-eProsima * Refs #19452: update fastrtps.rc Signed-off-by: JLBuenoLopez-eProsima * Refs #19452: remove System deprecated class Signed-off-by: JLBuenoLopez-eProsima * Refs #19452: remove DataWriter deprecated methods Signed-off-by: JLBuenoLopez-eProsima * Refs #19452: remove deprecated methods in ServerAttributes Signed-off-by: JLBuenoLopez-eProsima * Refs #19452: remove deprecated method in LocatorList Signed-off-by: JLBuenoLopez-eProsima * Refs #19452: remove deprecated attributes in TCPTransportDescriptor Signed-off-by: JLBuenoLopez-eProsima * Refs #19452: remove SampleInfo deprecated constexpr Signed-off-by: JLBuenoLopez-eProsima * Refs #19452: remove deprecated participant discovery callback Signed-off-by: JLBuenoLopez-eProsima * Refs #19452: remove TypeObject deprecated API Signed-off-by: JLBuenoLopez-eProsima * Refs #19452: remove RPC headers deprecated API Signed-off-by: JLBuenoLopez-eProsima * Refs #19452: rename project to Fast DDS. Update examples, tools and fuzzer CMakeLists. Changes required to build library after updating to fastdds headers Signed-off-by: JLBuenoLopez-eProsima * Refs #19452: fix examples build Signed-off-by: JLBuenoLopez-eProsima * Refs #19452: fixes in test suite Signed-off-by: JLBuenoLopez-eProsima * Refs #19452: linters Signed-off-by: JLBuenoLopez-eProsima * Refs #19452: remove deprecated API Signed-off-by: JLBuenoLopez-eProsima * Refs #19452: update versions.md Signed-off-by: JLBuenoLopez-eProsima * Refs #19452: fix Windows warning Signed-off-by: JLBuenoLopez-eProsima * Refs #19452: remove PSM source files and tests Signed-off-by: JLBuenoLopez-eProsima * Refs #19452: move TopicAttributes implementation to src/cpp/rtps/attributes folder Signed-off-by: JLBuenoLopez-eProsima * Refs #19452: sort alphabetically source files Signed-off-by: JLBuenoLopez-eProsima * Refs #19452: remove Fast RTPS legacy API implementation Signed-off-by: JLBuenoLopez-eProsima * Refs #19452: remove PSM API headers and implementation. Fixes to ensure tests build correctly Signed-off-by: JLBuenoLopez-eProsima * Refs #19452: update to libfastdds.version name and remove exported dds namespace Signed-off-by: JLBuenoLopez-eProsima * Refs #19452: fixes after rebase Signed-off-by: JLBuenoLopez-eProsima * Refs #19452: apply review suggestion related to XML header Signed-off-by: JLBuenoLopez-eProsima * Refs #19452: apply review suggestions Signed-off-by: JLBuenoLopez-eProsima * Refs #19452: missing XML xmlns Signed-off-by: JLBuenoLopez-eProsima * Refs #19452: fixes in TCPv6 unit tests Signed-off-by: JLBuenoLopez-eProsima * Refs #19452: keep legacy installation folder until migration is completed Signed-off-by: JLBuenoLopez-eProsima * Refs #19452: fixes in TCPv4 unit tests Signed-off-by: elianalf <62831776+elianalf@users.noreply.github.com> * Refs #19452: Remove Readme.html.in installation since it has been removed Signed-off-by: elianalf <62831776+elianalf@users.noreply.github.com> * Refs #19452: Remove fastrtps_example.cpp references Signed-off-by: elianalf <62831776+elianalf@users.noreply.github.com> * Refs #19452: Add head branch for discovery-server in github ci action Signed-off-by: elianalf <62831776+elianalf@users.noreply.github.com> * Refs 19452: Update default branch for asan Signed-off-by: elianalf <62831776+elianalf@users.noreply.github.com> * Refs #19452: Change Mac Github CI to work for 3.0.x-devel Signed-off-by: elianalf <62831776+elianalf@users.noreply.github.com> * Refs 19452: Add namespace where missing Signed-off-by: elianalf <62831776+elianalf@users.noreply.github.com> --------- Signed-off-by: JLBuenoLopez-eProsima Signed-off-by: elianalf <62831776+elianalf@users.noreply.github.com> Co-authored-by: elianalf <62831776+elianalf@users.noreply.github.com> Fixes after rebase Signed-off-by: JLBuenoLopez-eProsima * Remove deprecated fastrtps tests (#4270) * Refs #20340: Remove deprecated fastrtps tests Signed-off-by: elianalf <62831776+elianalf@users.noreply.github.com> Refs #20340: Restore XML parser tests Signed-off-by: elianalf <62831776+elianalf@users.noreply.github.com> * Refs #20340: Update version.md file Signed-off-by: elianalf <62831776+elianalf@users.noreply.github.com> * Refs 20340: Remove no longer supported FASTRTPS_API_TESTS Signed-off-by: elianalf <62831776+elianalf@users.noreply.github.com> --------- Signed-off-by: elianalf <62831776+elianalf@users.noreply.github.com> * Remove fixed_size_string file in fastrtps (#4269) * Refs #20392: Remove fastrtps fixed_size_string lib Signed-off-by: elianalf <62831776+elianalf@users.noreply.github.com> * Refs #20392: Update tests dependencies Signed-off-by: elianalf <62831776+elianalf@users.noreply.github.com> * Refs #20392: Update namespace fastcdr Signed-off-by: elianalf <62831776+elianalf@users.noreply.github.com> * Refs #20392: Reorder libraries to follow google style order Signed-off-by: elianalf <62831776+elianalf@users.noreply.github.com> * Refs #20392: Remove include of unused fixed_size_string Signed-off-by: elianalf <62831776+elianalf@users.noreply.github.com> * Refs #20392: Remove deprecated tests of fixed_size_string Signed-off-by: elianalf <62831776+elianalf@users.noreply.github.com> * Refs #20392: Uncrustify Signed-off-by: elianalf <62831776+elianalf@users.noreply.github.com> --------- Signed-off-by: elianalf <62831776+elianalf@users.noreply.github.com> * Make XML Parser API private (#4318) * Refs #20301: move XML Parser implementation to root source folder Signed-off-by: JLBuenoLopez-eProsima Signed-off-by: EduPonz * Refs #20301: sort alphabetically source files Signed-off-by: JLBuenoLopez-eProsima Signed-off-by: EduPonz * Refs #20301: make XML Parser private Signed-off-by: JLBuenoLopez-eProsima Signed-off-by: EduPonz * Refs #20301: remove private headers from Blackbox tests Signed-off-by: JLBuenoLopez-eProsima Signed-off-by: EduPonz * Refs #20301: new LibrarySettings class superseding LibrarySettingsAttributes Signed-off-by: JLBuenoLopez-eProsima Signed-off-by: EduPonz * Refs #20301: add library settings DDS & RTPS API. RTPSDomainTests testing the new API Signed-off-by: JLBuenoLopez-eProsima Signed-off-by: EduPonz * Refs #20301: library settings DDS API test Signed-off-by: JLBuenoLopez-eProsima Signed-off-by: EduPonz * Refs #20301: generate monitor service types in blackbox types and use them in corresponding test Signed-off-by: JLBuenoLopez-eProsima Signed-off-by: EduPonz * Refs #20301: XML profile manager get dynamic type builder wrapper and related test Signed-off-by: JLBuenoLopez-eProsima Signed-off-by: EduPonz * Refs #20301: refactor XML library settings, use new migrated structure Signed-off-by: JLBuenoLopez-eProsima Signed-off-by: EduPonz * Refs #20301: migrate to public API Signed-off-by: JLBuenoLopez-eProsima Signed-off-by: EduPonz * Refs #20301: reintroduce private headers in blackbox tests Signed-off-by: JLBuenoLopez-eProsima Signed-off-by: EduPonz * Refs #20301: update versions.md and copyright Signed-off-by: JLBuenoLopez-eProsima Signed-off-by: EduPonz * Refs #20301: remove exportation macro from private API Signed-off-by: JLBuenoLopez-eProsima Signed-off-by: EduPonz * Refs #20301: remove participant without using mocked code Signed-off-by: JLBuenoLopez-eProsima Signed-off-by: EduPonz * Refs #20301: apply review suggestion Signed-off-by: JLBuenoLopez-eProsima Signed-off-by: EduPonz * Refs #20301: linters Signed-off-by: JLBuenoLopez-eProsima Signed-off-by: EduPonz * Refs #20301: avoid using protected interface name Signed-off-by: JLBuenoLopez-eProsima Signed-off-by: EduPonz * Refs #20301: avoid using non-exported API in ParticipantTests Signed-off-by: JLBuenoLopez-eProsima Signed-off-by: EduPonz * Refs #20301: linters Signed-off-by: JLBuenoLopez-eProsima Signed-off-by: EduPonz * Refs #20301: fix Publisher and Subscriber tests Signed-off-by: JLBuenoLopez-eProsima Signed-off-by: EduPonz * Refs #20301: add get_topic_attributes_from_profile API Signed-off-by: JLBuenoLopez-eProsima Signed-off-by: EduPonz * Refs #20301: get topic attributes from profile test Signed-off-by: JLBuenoLopez-eProsima Signed-off-by: EduPonz * Refs #20301: fixes after rebase Signed-off-by: JLBuenoLopez-eProsima Signed-off-by: EduPonz * Refs #20301: fix Windows warning Signed-off-by: JLBuenoLopez-eProsima Signed-off-by: EduPonz * Refs #20301: linters Signed-off-by: JLBuenoLopez-eProsima Signed-off-by: EduPonz * Refs #20301: fix Windows warning Signed-off-by: JLBuenoLopez-eProsima Signed-off-by: EduPonz * Refs #20301: fix memory leak Signed-off-by: JLBuenoLopez-eProsima Signed-off-by: EduPonz * Refs #20301: Run Github Windows CI on 3.0.x-devel PRs Signed-off-by: EduPonz --------- Signed-off-by: JLBuenoLopez-eProsima Signed-off-by: EduPonz Co-authored-by: EduPonz * Migrate DLL API exporter and auto linkage to fastdds (#4500) * Refs #20569: Rename RTPS_DllAPI to FASTDDS_EXPORTED_API Signed-off-by: EduPonz * Refs #20569: Move fastrtps/fastrtps_dll.h to fastdds/fastdds_dll.hpp Signed-off-by: EduPonz * Refs #20569: Move fastrtps/eProsima_auto_link.h to fastdds/fastdds_auto_link.hpp Signed-off-by: EduPonz * Refs #20569: Uncrustify Signed-off-by: EduPonz --------- Signed-off-by: EduPonz * Change windows file names (#4576) * Refs #20390: Change fastdds-config.cmake name Signed-off-by: elianalf <62831776+elianalf@users.noreply.github.com> * Refs #20390: Change fastdds.manifest.in name Signed-off-by: elianalf <62831776+elianalf@users.noreply.github.com> --------- Signed-off-by: elianalf <62831776+elianalf@users.noreply.github.com> * Migrate classes from include/fastrtps to fastdds (#4518) * Refs #20566: Migrate fastrtps/attributes/TopicAttributes.h to fastdds/rtps/attributes Signed-off-by: elianalf <62831776+elianalf@users.noreply.github.com> Signed-off-by: EduPonz * Refs #20566: Migrate fastrtps/utils/IPFinder.h to fastdds/utils Signed-off-by: elianalf <62831776+elianalf@users.noreply.github.com> Signed-off-by: EduPonz * Refs #20566: Migrate fastrtps/utils/IPLocator.h to fastdds/utils Signed-off-by: elianalf <62831776+elianalf@users.noreply.github.com> Signed-off-by: EduPonz * Refs #20566: Migrate fastrtps/utils/collections to fastdds/utils/collections Signed-off-by: elianalf <62831776+elianalf@users.noreply.github.com> Signed-off-by: EduPonz * Refs #20566: Migrate fastrtps/utils/fixed_size_bitmap.hpp to fastdds/utils/ Signed-off-by: elianalf <62831776+elianalf@users.noreply.github.com> Signed-off-by: EduPonz * Refs #20566: Migrate fastrtps/utils/md5.h to fastdds/utils Signed-off-by: elianalf <62831776+elianalf@users.noreply.github.com> Signed-off-by: EduPonz * Refs #20566: Migrate fastrtps/utils/TimedConditionVariable.hpp to fastdds/utils Signed-off-by: elianalf <62831776+elianalf@users.noreply.github.com> Signed-off-by: EduPonz * Refs #20566: Migrate fastrtps/utils/TimedMutex.hpp to fastdds/utils Signed-off-by: elianalf <62831776+elianalf@users.noreply.github.com> Signed-off-by: EduPonz * Refs #20566: Uncrustify Signed-off-by: elianalf <62831776+elianalf@users.noreply.github.com> Signed-off-by: EduPonz * Refs #20566: Reorder header following google style Signed-off-by: elianalf <62831776+elianalf@users.noreply.github.com> * Regenerate file with updated headers Signed-off-by: elianalf <62831776+elianalf@users.noreply.github.com> * Refs #20566: fix rebase error Signed-off-by: elianalf <62831776+elianalf@users.noreply.github.com> --------- Signed-off-by: elianalf <62831776+elianalf@users.noreply.github.com> Signed-off-by: EduPonz * Update versions in fastdds.repos file (#4621) Signed-off-by: elianalf <62831776+elianalf@users.noreply.github.com> * Make private the necessary headers from include/fastrtps (#4545) * Refs #20567: Include what you use in latency test Signed-off-by: EduPonz * Refs #20567: Remove unnecesary and deprecated headers Signed-off-by: EduPonz * Refs #20567: Migrate allocations test to DDS Signed-off-by: EduPonz * Refs #20567: Make ParticipantAttributes private Signed-off-by: EduPonz * Refs #20567: Make ReplierAttributes & RequesterAttributes private Signed-off-by: EduPonz * Refs #20567: Make PublisherAttributes private Signed-off-by: EduPonz * Refs #20567: Make SubscriberAttributes private Signed-off-by: EduPonz * Refs #20567: Make Discovery private Signed-off-by: EduPonz * Refs #20567: Make ProxyPool private Signed-off-by: EduPonz * Refs #20567: Make Semaphore private Signed-off-by: EduPonz * Refs #20567: Make MessageReceiver private Signed-off-by: EduPonz * Refs #20567: Make BuiltinProtocols private Signed-off-by: EduPonz * Refs #20567: Make Liveliness private Signed-off-by: EduPonz * Refs #20567: Make LivelinessManager private Signed-off-by: EduPonz * Refs #20567: Make LivelinessData private Signed-off-by: EduPonz * Refs #20567: Make shared_mutex private Signed-off-by: EduPonz * Refs #20567: Make StringMatching private Signed-off-by: EduPonz * Refs #20567: Make TimeConversion private Signed-off-by: EduPonz * Refs #20567: Make DBQueue private Signed-off-by: EduPonz * Refs #20567: Add notes to versions.md Signed-off-by: EduPonz * Refs #20567: Apply Eliana's suggestions Signed-off-by: EduPonz * Refs #20567: Correctly export API in Windows for ReplierQos and RequesterQos Signed-off-by: EduPonz --------- Signed-off-by: EduPonz * Create Participant with default profile (use environment XML configuration) (#4534) * Refs #20543: Default Domain Id value Signed-off-by: JesusPoderoso * Refs #20543: Rename method Signed-off-by: JesusPoderoso * Refs #20543: Apply rev suggestions Signed-off-by: JesusPoderoso * Refs #20543: Address missed suggestions Signed-off-by: JesusPoderoso * Refs #20543: Apply last(?) revision suggestion Signed-off-by: JesusPoderoso * Refs #20543: Apply Edu' suggestion Signed-off-by: JesusPoderoso * Refs #20543: Apply Edu' suggestion (2) Signed-off-by: JesusPoderoso * Refs #20543: Add missing test Signed-off-by: JesusPoderoso * Refs #20543: Fix test Signed-off-by: JesusPoderoso * Refs #20543: Apply rev suggestions Signed-off-by: JesusPoderoso * Refs #20543: Instanciate test listener in stack Signed-off-by: JesusPoderoso * Refs #20543: Include new feature in versions.md Signed-off-by: JesusPoderoso --------- Signed-off-by: JesusPoderoso * Refactor Statistics module IDL (#4638) * Refs #20714: refactor statistics module IDL Signed-off-by: JLBuenoLopez-eProsima * Refs #20714: regenerate types Signed-off-by: JLBuenoLopez-eProsima * Refs #20714: correctly use new statistics IDL Signed-off-by: JLBuenoLopez-eProsima --------- Signed-off-by: JLBuenoLopez-eProsima * Partial implementation of X-Types1.3 (#4640) * Partial implementation of X-Types1.3 DDS ReturnCode_t generated from IDL file (#4041) * Refs #19975. Implementation on library Signed-off-by: Ricardo González Moreno * Refs #19975. Fix all compilation errors Signed-off-by: Ricardo González Moreno * Refs #19975. Fix forgotten compilation errors Signed-off-by: Ricardo González Moreno * Refs #19975. Fix old use of operator ! Signed-off-by: Ricardo González Moreno --------- Signed-off-by: Ricardo González Moreno Regenerated IDL files with types header-only fastddsgen version (#4042) * Refs #19971. Remove -cdr option in script Signed-off-by: Ricardo González Moreno * Refs #19960. Apply types header-only Signed-off-by: Ricardo González Moreno * Refs #19960. Fix compilation errors after rebase Signed-off-by: Ricardo González Moreno * Refs #19960. Trying compile VS2017 Signed-off-by: Ricardo González Moreno --------- Signed-off-by: Ricardo González Moreno Fixed error when compiling with FASTDDS_STATISTICS=OFF (#4059) Signed-off-by: adriancampo New dynamic_language_binding.idl (#4058) Signed-off-by: Ricardo González Moreno TypeObjectUtils class (#3974) * Refs #19648: XTypes v1.3 Annex B TypeObject IDL Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: generate TypeObject.idl code with Fast DDS-Gen v3.0.1 Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: regenerate using bugfixes/warnings-regressions branch Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: build new TypeObject generated code. Update headers Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: WIP, due to external annotation max serialized size is not correctly calculated Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: include BuiltinAnnotations.idl Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: builtin annotations already defined within Fast DDS-Gen: escape annotation name to redefine and generate TypeObject. Remove builtin annotations dependent on any block not yet supported Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: typo Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: update script to generate Builtin annotations TypeObject Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: API proposal Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: use xtypes1_3 namespace to avoid TypeInformation conflict Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: apply design suggestions Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: add exceptions based on DDS PSM CXX specification Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: API for bitmask flags, strings, sequences and arrays TypeIdentifiers. Consistency unit tests Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: plain maps TypeIdentifier API and unit tests Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: plain collections consistency methods and refactor corresponding tests Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: register TypeObjectRegistry in DomainParticipantFactory and create accesor to the API Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: register indirect hash TypeIdentifiers API Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: refactor to prevent pointer use Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: add register indirect hash TypeIdentifiers tests Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: AnnotationParameterValue API Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: add TypeObjectUtils API Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: more API Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: regenerate using external implementation. Refactor code to build Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: fix tests Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: include API to TypeObjectRegistry Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: finish public API Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: generate BuiltinAnnotations types to check builtin annotations consistency Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: add API to access the builtin annotation complete TypeIdentifier Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: namespace. Include builtin annotations names and kinds and avoid conflict with extensibility kinds Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: add consistency API: builtin annotations, complete struct members Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: union type consistency Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: annotation cross consistency Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: modify API for TypeLookupService Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: fix calls to TypeObjectRegistry Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: builtin annotations not included in custom annotations sequence Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: CompleteAliasBody consistency Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: CompleteEnumeratedLiteral consistency and fixes Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: enum literal sequence consistency Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: CompleteBitflag consistency Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: bitflag sequence consistency Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: CompleteBitfield consistency Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: bitfield sequence consistency Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: fix bug Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: update versions.md Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: apply review suggestions Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: regenerate types using script (only IDLs introduced in this PR has been updated) Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: fix wartnings Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: linters Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: remove non-applicable TODO Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: fix build issue Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: fix Clang warnings Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: apply review suggestion: keyed members cannot be optional Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: apply review suggestion: fix MemberFlags consistency checks Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: apply review suggestion: leverage insert API Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: apply review suggestions: improve error messages Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: apply review suggestion: check invalid union member name Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: apply review suggestion: improve readability Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: apply review suggestions: imporvements to tests and map key consistency alias check Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: apply review suggestion: ensure correct element order in sequences Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: linters Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: apply review suggestion Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: fix Windows warning Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: apply review suggestion. Bitfield name might be empty. Method to check direct hash type identifiers consistency (pending implementation Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: use Fast DDS-Gen names Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: use IDL from specification (https://www.omg.org/spec/DDS-XTypes/20190301/dds-xtypes_typeobject.idl). Update script Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: migrate to DDS ReturnCode_t Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: fix IDL typo Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: generate types Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: rename TypeIdentifierParameter to avoid conflict Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: rename xtypes namespace Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: fix missing information from IDL Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: remove warnings Signed-off-by: JLBuenoLopez-eProsima * Refs #19595: fix tests compilation Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: regenerate BuiltinAnnotation types without empty namespaces Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: fix uninitialized warning Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: linters Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: fix test linkage Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: fix windows warning Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: WIP Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: fix primitive type long double Signed-off-by: JLBuenoLopez-eProsima * Refs #19648: fix windows warning Signed-off-by: JLBuenoLopez-eProsima --------- Signed-off-by: JLBuenoLopez-eProsima Moved all typelookupservice files to src (#4053) * Moved all typelookupservice files to src Signed-off-by: adriancampo * Renamed typelookupservice directory. Fix include order. Signed-off-by: adriancampo * Fix include order. Uncrustify. Signed-off-by: adriancampo * Refs #20043: Reordered includes. Fixed mock path. Signed-off-by: adriancampo --------- Signed-off-by: adriancampo New TypeDescriptor (#4074) * Refs 17138. New TypeDescriptor Signed-off-by: Ricardo González Moreno * Refs 17138. Update doxygen. Signed-off-by: Ricardo González Moreno * Refs 17138. Remove forward class not used Signed-off-by: Ricardo González Moreno * Refs 17138. Apply suggestions Signed-off-by: Ricardo González Moreno --------- Signed-off-by: Ricardo González Moreno TypeObjectRegistry implementation (#3996) * Refs #19837: add TypeObjectRegistry::register_type_identifier test Signed-off-by: JLBuenoLopez-eProsima * Refs #19837: TypeObjectRegistry::register_type_identifier implementation Signed-off-by: JLBuenoLopez-eProsima * Refs #19837: test fixes Signed-off-by: JLBuenoLopez-eProsima * Refs #19837: add TypeObjectUtils::complete_type_object_consistency Signed-off-by: JLBuenoLopez-eProsima * Refs #19837: TypeObjectRegistry::register_type_object implementation Signed-off-by: JLBuenoLopez-eProsima * Refs #19837: TypeObjectRegistry::register_type_object test Signed-off-by: JLBuenoLopez-eProsima * Refs #19837: TypeObjectRegistry::build_minimal_from_complete_type_object skeleton Signed-off-by: JLBuenoLopez-eProsima * Refs #19837: TypeObjectRegistry::build_minimal_from_complete_alias_type implementation Signed-off-by: JLBuenoLopez-eProsima * Refs #19837: use const references in ranged for loops Signed-off-by: JLBuenoLopez-eProsima * Refs #19837: TypeObjectRegistry::build_minimal_from_complete_annotation_type implementation Signed-off-by: JLBuenoLopez-eProsima * Refs #19837: TypeObjectRegistry::build_minimal_from_complete_struct_type implementation Signed-off-by: JLBuenoLopez-eProsima * Refs #19837: TypeObjectRegistry::build_minimal_from_complete_union_type implementation Signed-off-by: JLBuenoLopez-eProsima * Refs #19837: TypeObjectRegistry::build_minimal_from_complete_bitset_type implementation Signed-off-by: JLBuenoLopez-eProsima * Refs #19837: TypeObjectRegistry::build_minimal_from_complete_sequence_type implementation Signed-off-by: JLBuenoLopez-eProsima * Refs #19837: TypeObjectRegistry::build_minimal_from_complete_array_type implementation Signed-off-by: JLBuenoLopez-eProsima * Refs #19837: TypeObjectRegistry::build_minimal_from_complete_map_type implementation Signed-off-by: JLBuenoLopez-eProsima * Refs #19837: TypeObjectRegistry::build_minimal_from_complete_enumerated_type implementation Signed-off-by: JLBuenoLopez-eProsima * Refs #19837: TypeObjectRegistry::build_minimal_from_complete_bitmask_type implementation Signed-off-by: JLBuenoLopez-eProsima * Refs #19837: TypeObjectRegistry::get_type_identifier Signed-off-by: JLBuenoLopez-eProsima * Refs #19837: fix tests Signed-off-by: JLBuenoLopez-eProsima * Refs #19837: TypeObject::get_type_identifiers implementation Signed-off-by: JLBuenoLopez-eProsima * Refs #19837: add TypeObject::get_type_identifiers test Signed-off-by: JLBuenoLopez-eProsima * Refs #19837: add TypeObject::get_type_objects tests Signed-off-by: JLBuenoLopez-eProsima * Refs #19837: TypeObjectRegistry::get_type_objects implementation Signed-off-by: JLBuenoLopez-eProsima * Refs #19837: TypeObjectRegistry constructor implementation. Register primitive TypeIdentifiers Signed-off-by: JLBuenoLopez-eProsima * Refs #19837: TypeObjectRegistry::register_type_object implementation Signed-off-by: JLBuenoLopez-eProsima * Refs #19837: TypeObjectRegistry::get_type_object implementation Signed-off-by: JLBuenoLopez-eProsima * Refs #19837: add precondition to public API Signed-off-by: JLBuenoLopez-eProsima * Refs #19837: TypeObjectRegistry::get_type_information implementation Signed-off-by: JLBuenoLopez-eProsima * Refs #19837: TypeObjectRegistry::is_builtin_annotation implementation Signed-off-by: JLBuenoLopez-eProsima * Refs #19837: TypeObjectRegistry::is_type_identifier_known implementation Signed-off-by: JLBuenoLopez-eProsima * Refs #19837: TypeObjectRegistry::get_type_dependencies impl Signed-off-by: JLBuenoLopez-eProsima * Refs #19837: linters Signed-off-by: JLBuenoLopez-eProsima * Refs #19837: apply review suggestion, protect against concurrent access to collections Signed-off-by: JLBuenoLopez-eProsima * Refs #19837: apply review suggestion, rename to calculate_type_identifier Signed-off-by: JLBuenoLopez-eProsima * Refs #19837: define NO_DEPENDENCIES constant Signed-off-by: JLBuenoLopez-eProsima * Refs #19837: apply review suggestions to TypeObjectRegistry implementation Signed-off-by: JLBuenoLopez-eProsima * Refs #19837: apply review suggestions, imporve TypeObjectRegistry tests Signed-off-by: JLBuenoLopez-eProsima * Refs #19837: TypeObjectUtils::direct_hash_type_identifier_consistency impl Signed-off-by: JLBuenoLopez-eProsima * Refs #19837: linters Signed-off-by: JLBuenoLopez-eProsima * Refs #19837: remove Windows warning Signed-off-by: JLBuenoLopez-eProsima * Refs #19837: regenerate code to avoid Clang warning Signed-off-by: JLBuenoLopez-eProsima * Refs #19837: use ExtensibilityKind and TryConstructKind defined in DynamicType IDL Signed-off-by: JLBuenoLopez-eProsima --------- Signed-off-by: JLBuenoLopez-eProsima New MemberDescriptor API (#4096) * Refs 17138. New MemberDescriptor API Signed-off-by: Ricardo González Moreno * Refs 17138. Apply suggestions Signed-off-by: Ricardo González Moreno --------- Signed-off-by: Ricardo González Moreno Regenerate code with fastddsgen and fix idl files (#4080) * Refs #20070. Regenerate source code and fix idl errors Signed-off-by: Ricardo González Moreno * Refs #20070. Fix missing include Signed-off-by: Ricardo González Moreno * Refs #20070. Trying compile VS2017 Signed-off-by: Ricardo González Moreno --------- Signed-off-by: Ricardo González Moreno New AnnotationDescriptor API (#4121) * Refs 17138. New AnnotationDescriptor API Signed-off-by: Ricardo González Moreno * Refs 17138. Apply suggestion Signed-off-by: Ricardo González Moreno --------- Signed-off-by: Ricardo González Moreno Added idl file and generated types for typelookup service. (#4054) * Added idl file and generated types for typelookup service. Signed-off-by: adriancampo * Fix directory name. Signed-off-by: adriancampo * Updated IDL. Removed old generated files. Signed-off-by: adriancampo * Refs #19794: Updated generated types Signed-off-by: adriancampo * Refs #19794: Changes to type generation script Signed-off-by: adriancampo * Refs #19794: Changes to make TypeLookup compile. Fix to type generation script. Signed-off-by: adriancampo * Refs #19794: Uncrustify Signed-off-by: adriancampo * Refs #19794: Updated fastddsgen generated file Signed-off-by: adriancampo * Refs #19794: Applied suggestions Signed-off-by: adriancampo * Refs #19794: Applied suggestions to update_generated_code_from_idl script Signed-off-by: adriancampo * Refs #19794: fixed error in script Signed-off-by: adriancampo * Refs #19794: Added OMG idl for rpc types Signed-off-by: adriancampo * Refs #19794: Uncrustified Signed-off-by: adriancampo * Refs #19794: Added new rpc_typesPubSubTypes.cxx to CMakeLists Signed-off-by: adriancampo * Refs #19794: Updated script idl and generated types after fastddsgen changes. Signed-off-by: adriancampo * Refs #19794: Updated generated code. Signed-off-by: adriancampo * Refs #19794: Applied suggestions Signed-off-by: adriancampo --------- Signed-off-by: adriancampo Created TypeObjectRegistryObserver (#4092) * Refs #20062: Created TypeObjectRegistryObserver class. Signed-off-by: adriancampo * Refs #20062: Chamges to TypeObjectUtils to work with TypeObjectRegistryObserver. Updated some generated types. Signed-off-by: adriancampo * Refs #20062: Removed TypeObjectFactory uses from discovery Signed-off-by: adriancampo * Refs #20062: Uses of TypeObjectRegistryObserver in discovery Signed-off-by: adriancampo * Refs #20062: Changed TypeObjectRegistryObserver friend class for a virtual interface (tests not compiling). Signed-off-by: adriancampo * Refs #20062: Fixed tests compilation Signed-off-by: adriancampo * Refs #20062: Applied suggestions Signed-off-by: adriancampo * Undid uncrustify changes to TypeObjectUtils.cpp --------- Signed-off-by: adriancampo New DynamicTypeMember API (#4138) * Refs 17138. New DynamicTypeMember API Signed-off-by: Ricardo González Moreno * Refs 17138. Apply suggestions Signed-off-by: Ricardo González Moreno * Refs 17138. Apply suggestion Signed-off-by: Ricardo González Moreno --------- Signed-off-by: Ricardo González Moreno New DynamicType API (#4141) * Refs 17138. New DynamicType API Signed-off-by: Ricardo González Moreno * Refs 17138. Apply suggestions Signed-off-by: Ricardo González Moreno --------- Signed-off-by: Ricardo González Moreno Create async_get_type method and remove typelookup settings (#4126) * Refs #20116: Removed TypeLookupSettings. Cleaned TypeLookupManager. Signed-off-by: adriancampo * Refs #20116: Removed auto_fill_type_object Signed-off-by: adriancampo * Refs #20116: Applied suggestions Signed-off-by: adriancampo * Refs #20116: Crated instance of TypeLookupManager in BuiltinProtocols. Improved documentation of TypeLookupManager Signed-off-by: adriancampo * Refs #20116: Applied suggestions Signed-off-by: adriancampo * Refs #20116: Added TODO for ReturnCodes of async_get_type Signed-off-by: adriancampo * Refs #20116: Fixed DomainParticipantImpl mock Signed-off-by: adriancampo * Refs #20116: Removed access to private api from mock. Signed-off-by: adriancampo * Refs #20116: Removed get_types and get_type_dependencies methods from DomainParticipant. Signed-off-by: adriancampo * Refs #20116: Removed the old methods related with TypeLookup service. Signed-off-by: adriancampo * Refs #20116: Removed tests from from ParticipantTests. Signed-off-by: adriancampo * Refs #20116: Removed unnused member. Signed-off-by: adriancampo --------- Signed-off-by: adriancampo New DynamicTypeBuilder API (#4157) * Refs 17138. New DynamicTypeBuilder API Signed-off-by: Ricardo González Moreno * Refs 17138. Apply suggestions Signed-off-by: Ricardo González Moreno --------- Signed-off-by: Ricardo González Moreno New DynamicTypeBuilderFactory API (#4170) * Refs 17138. New DynamicTypeBuilderFactory API Signed-off-by: Ricardo González Moreno * Refs 17138. Apply suggestions. Signed-off-by: Ricardo González Moreno --------- Signed-off-by: Ricardo González Moreno Move dds types (#4179) Signed-off-by: Ricardo González Moreno Update TypeInformationParameter to contain xtype (#4140) * Refs #20131: Updated TypeInformationParameter TypeInformation to xtypes Signed-off-by: adriancampo * Refs #20131: Removed old TypeObject header from QosPolicies Signed-off-by: adriancampo * Refs #20131: Removed old type validation. Signed-off-by: adriancampo * Refs #20131: Fixed windows warning. Signed-off-by: adriancampo * Refs #20131: Removed tests for private api. Signed-off-by: adriancampo * Refs #20131: Included Types.hpp for DomainId_t Signed-off-by: adriancampo --------- Signed-off-by: adriancampo Bugfix: fix feature/xtypes1.3 branch build (#4228) * Refs #20129: fixes to build feature/xtypes1.3 branch Signed-off-by: JLBuenoLopez-eProsima * Refs #20129: linters Signed-off-by: JLBuenoLopez-eProsima * Refs #20129: fix compilation with security Signed-off-by: JLBuenoLopez-eProsima * Refs #20129: apply review suggestion Signed-off-by: JLBuenoLopez-eProsima * Refs #20129: regenerate types after fixing union bug Signed-off-by: JLBuenoLopez-eProsima * Refs #20129: fix for building without Statistics module Signed-off-by: JLBuenoLopez-eProsima * Refs #20129: fix Windows warning Signed-off-by: JLBuenoLopez-eProsima --------- Signed-off-by: JLBuenoLopez-eProsima Implement TypeLookupManager async_get_type (#4177) * Refs #20130: Use TypeLookupManager in EDP Signed-off-by: adriancampo * Refs #20130: async_get_type implementation Signed-off-by: adriancampo * Refs #20130: Moved parser functions and reception checks Signed-off-by: adriancampo * Refs #20130: Fixed typo Signed-off-by: adriancampo * Refs #20130: Added functions to add and remove entries from maps. Change map keys to TypeIdentfierWithSize. Signed-off-by: adriancampo * Refs #20130: Applied suggestions Signed-off-by: adriancampo * Refs #20130: Changeds to instance_name. Signed-off-by: adriancampo * Refs #20130: Applied suggestions Signed-off-by: adriancampo * Refs #20130: Fixed copyright date Signed-off-by: adriancampo * Refs #20130: Fixed warnings in release mode. Signed-off-by: adriancampo * Refs #20130: Fix CI warning. Signed-off-by: adriancampo * Refs #20130: Fix request instanceName check. Signed-off-by: adriancampo * Refs #20130: Changes for smart_ptr ReaderProxyData and WriterProxyData. Signed-off-by: adriancampo * Refs #20130: Removed use of private header for TypeLookupManager inside the public one for BuiltinProtocols. Signed-off-by: adriancampo * Refs #20130: Fix for remove_async_get_type_callback. Signed-off-by: adriancampo --------- Signed-off-by: adriancampo New DynamicData API (#4189) * Refs #17138. New DynamicData API Signed-off-by: Ricardo González Moreno * Refs #17138. Applying suggestions Signed-off-by: Ricardo González Moreno * Refs #17138. Applying suggestions Signed-off-by: Ricardo González Moreno --------- Signed-off-by: Ricardo González Moreno Regenerate types after rebase. Signed-off-by: JLBuenoLopez-eProsima Type Object integration (#4239) * Refs #19906: refactor annotation parameter value consistency method to deal with aliases Signed-off-by: JLBuenoLopez-eProsima * Refs #19906: build wstring TypeIdentifiers Signed-off-by: JLBuenoLopez-eProsima * Refs #19906: fix long double name using Fast DDS-Gen defined name Signed-off-by: JLBuenoLopez-eProsima * Refs #19906: remove BuiltinAnnotations. Not required if not included in custom annotations sequence Signed-off-by: JLBuenoLopez-eProsima * Refs #19906: remove EquivalenceKindValue enum Signed-off-by: JLBuenoLopez-eProsima * Refs #20129: support not applied annotation (extensibility/try_construct) Signed-off-by: JLBuenoLopez-eProsima * Refs #20129: fix TypeIdentifier included in Minimal TypeObjects. Only explicit member flags Signed-off-by: JLBuenoLopez-eProsima * Refs #20129: refactor bound consistency: unbounded collections have bound 0 Signed-off-by: JLBuenoLopez-eProsima * Refs #20129: fix map key type identifier consistency Signed-off-by: JLBuenoLopez-eProsima * Refs #20129: register indirect hash TypeIdentifier correctly Signed-off-by: JLBuenoLopez-eProsima * Refs #20129: bitfields must have a name Signed-off-by: JLBuenoLopez-eProsima * Refs #20129: fix minimal_from_complete TypeIdentifier method Signed-off-by: JLBuenoLopez-eProsima * Refs #20129: fixes for maps Signed-off-by: JLBuenoLopez-eProsima * Refs #20129: update script Signed-off-by: JLBuenoLopez-eProsima * Refs #20129: regenerate types Signed-off-by: JLBuenoLopez-eProsima * Refs #20129: update script Signed-off-by: JLBuenoLopez-eProsima * Refs #20129: regenerate types after rebase Signed-off-by: JLBuenoLopez-eProsima * Refs #20129: remove tests: build TypeObject from DynamicType is not going to be implemented. TypeInformation is private API Signed-off-by: JLBuenoLopez-eProsima * Refs #20129: regenerate types and ensure library builds Signed-off-by: JLBuenoLopez-eProsima * Refs #20129: ensure examples build Signed-off-by: JLBuenoLopez-eProsima * Refs #20129: remove tests related to type compatibility/evolution Signed-off-by: JLBuenoLopez-eProsima * Refs #20129: avoid generating unnecessary TypeObjectSupport Signed-off-by: JLBuenoLopez-eProsima * Refs #20129: use new transport headers Signed-off-by: JLBuenoLopez-eProsima * Refs #20129: fix build DDS unit tests, including DDS Statistics Signed-off-by: JLBuenoLopez-eProsima * Refs #20129: remove XTypes tests. Type evolution is not going to be supported yet and remote type discovery tests are being refactored Signed-off-by: JLBuenoLopez-eProsima * Refs #20129: remove legacy ReturnCode and fix tests (pending DynamicTypesTests and RTPS Statistics tests) Signed-off-by: JLBuenoLopez-eProsima * Refs #20129: use another approach for unit test building: mock DomainParticipantFactory. Apply to DDSSQLFilter tests as proof of concept Signed-off-by: JLBuenoLopez-eProsima * Refs #20129: regenerate types and register TypeObject support by default Signed-off-by: JLBuenoLopez-eProsima * Refs #20129: fix tests compilation Signed-off-by: JLBuenoLopez-eProsima * Refs #20129: fix TypeObject tests Signed-off-by: JLBuenoLopez-eProsima * Refs #20129: fix minimal annotation parameter sequence order. Fix minimal TypeIdentifier for map keys Signed-off-by: JLBuenoLopez-eProsima * Refs #20129: regenerate types and fixes after rebase Signed-off-by: JLBuenoLopez-eProsima * Refs #20129: fix test in Release mode Signed-off-by: JLBuenoLopez-eProsima * Refs #20129: regenerate types after rebase in Fast DDS-Gen Signed-off-by: JLBuenoLopez-eProsima * Refs #20129: linters Signed-off-by: JLBuenoLopez-eProsima * Refs #20129: fix Python Bindings build Signed-off-by: JLBuenoLopez-eProsima * Refs #20129: fix old API blackbox test compilation Signed-off-by: JLBuenoLopez-eProsima * Refs #20129: fix build with TLS disabled Signed-off-by: JLBuenoLopez-eProsima * Refs #20129: regenerate types avoiding Windows warning Signed-off-by: JLBuenoLopez-eProsima * Refs #20129: fix windows max macro conflict in security tests Signed-off-by: JLBuenoLopez-eProsima * Refs #20129: regenerate types to avoid Windows warning Signed-off-by: JLBuenoLopez-eProsima * Refs #20129: avoid code in test main method Signed-off-by: JLBuenoLopez-eProsima * Refs #20129: apply review suggestions Signed-off-by: JLBuenoLopez-eProsima * Refs #20129: regenerate types after rebase Signed-off-by: JLBuenoLopez-eProsima * Refs #20129: fix CI warnings Signed-off-by: JLBuenoLopez-eProsima --------- Signed-off-by: JLBuenoLopez-eProsima Fixes after rebase Signed-off-by: JLBuenoLopez-eProsima Regenerate types after rebase Signed-off-by: JLBuenoLopez-eProsima Fixes after rebase Signed-off-by: Ricardo González Moreno Fixes for indirect hashes dependencies. (#4496) * Refs #20572: Fixes for indirect hashes dependencies. Signed-off-by: adriancampo * Refs #20572: Applied suggestion. Added tests for build_plain_map_s_type_defn_inconsistencies. Signed-off-by: adriancampo * Refs #20572: Fixes for plain_map_type_identifier_header_consistency. Signed-off-by: adriancampo * Refs #20572: Changed get_type_dependencies methods and aliases equiv_kind as map components. Signed-off-by: adriancampo * Refs #20572: Applied suggestions. Signed-off-by: adriancampo * Refs #20572: Combined map consistency methods. Signed-off-by: adriancampo * Refs #20572: Removed redundant check. Signed-off-by: adriancampo --------- Signed-off-by: adriancampo Regenerated files with last fastddsgen after rebase Signed-off-by: Ricardo González Moreno Added Annotation dependencies (#4497) * Refs #20565: Added Annotation dependencies Signed-off-by: adriancampo * Refs #20565: Applied suggestions. Added missing enum and bitmask dependencies. Signed-off-by: adriancampo * Refs #20565: Typo. Signed-off-by: adriancampo --------- Signed-off-by: adriancampo DynamicType implementation (#4190) * Refs 17138. DynamicTypePtr as shared_ptr alias Signed-off-by: Miguel Barro Refs 17138. Solve singleton initialization issues. Signed-off-by: Miguel Barro Refs 17138. Updating DynamicTypeBuilder(Factory) Signed-off-by: Miguel Barro Refs 17138. Linter Signed-off-by: Miguel Barro Refs 17138. Refactor to follow standard guidelines Signed-off-by: Miguel Barro Refs 17138. Fixed annotations issues on TypeObject generation Signed-off-by: Miguel Barro Refs 17138. Natural conversion from DynamicTypeXXX to TypeDescriptor. Signed-off-by: Miguel Barro Refs 17138. Fixing Ubuntu build issues Signed-off-by: Miguel Barro Refs 17138. Use type singletons for builder singletons Signed-off-by: Miguel Barro Refs 17138. Tests fixes Signed-off-by: Miguel Barro Refs 17138. doxygen and testing works Signed-off-by: Miguel Barro Refs 17138. ScopeLogs ancillary Signed-off-by: Miguel Barro Refs 17138. fixing DynamicData enum interfaces Signed-off-by: Miguel Barro Refs 17138. fixing DynamicData bitmask interfaces Signed-off-by: Miguel Barro Refs 17138. fix auto-id numbering Signed-off-by: Miguel Barro Refs 17138. force explicit DynamicData creation Signed-off-by: Miguel Barro Refs 17138. fixing DynamicData serialization, comparisson and copy Signed-off-by: Miguel Barro Refs 17138. fixing map implementation Signed-off-by: Miguel Barro Refs 17138. fixing struct implementation Signed-off-by: Miguel Barro Refs 17138. Fixing struct inheritance Signed-off-by: Miguel Barro Refs 17138. Trimming APIs Signed-off-by: Miguel Barro Refs 17138. Fixing union implementation Signed-off-by: Miguel Barro Refs 17138. Fixing xml profile testing Signed-off-by: Miguel Barro Refs 17138. debugging recursive structures serialization Signed-off-by: Miguel Barro Refs 17138. index management refactor and testing Signed-off-by: Miguel Barro Refs 17138. fix enum xml parsing Signed-off-by: Miguel Barro Refs 17138. fixing xml parsing tests Signed-off-by: Miguel Barro Refs 17138. fixing xml parsing tests Signed-off-by: Miguel Barro Refs 17138. update serialization/deserialization to avoid runtime allocations Signed-off-by: Miguel Barro Refs 17138. fixing union default testing Signed-off-by: Miguel Barro Refs 17138. fixing xml parsing tests Signed-off-by: Miguel Barro Refs 17138. fixing bitsets ... Signed-off-by: Miguel Barro Refs 17138. all tests fixed Signed-off-by: Miguel Barro Refs 17138. moving dynamic tracker from runtime polymorphism to build time one Signed-off-by: Miguel Barro Refs 17138. fixing examples and blackbox testing Signed-off-by: Miguel Barro Refs 17138. consistency fixes on type creation Signed-off-by: Miguel Barro Refs 17138. ostream support for annotations Signed-off-by: Miguel Barro Refs 17138. fixing dll export issues. New test binary to check them. Signed-off-by: Miguel Barro Refs 17138. Completing doxygen. Fixing CI issues. Signed-off-by: Miguel Barro Refs 17138. Fixing performance tests. Signed-off-by: Miguel Barro Refs 17138. Minor CI fixes Signed-off-by: Miguel Barro Refs 17138. Make create_xxx_builder() return constants only for static members. Signed-off-by: Miguel Barro Refs 17138. Fixing fastdds cli to work on python venv on windows Signed-off-by: Miguel Barro Refs 17138. Fixing doxygen. Signed-off-by: Miguel Barro Refs 17138. CI API fixes Signed-off-by: Miguel Barro Refs 17138. Several test fixes Signed-off-by: Miguel Barro Refs 17138. Fixing DynamicType generation from TypeObjec Signed-off-by: Miguel Barro Refs 17138. Refactor of MemberId and some serialization fixes Signed-off-by: Miguel Barro Refs 17138. API and serialization fixes Signed-off-by: Miguel Barro Refs 17138. Adapting test & examples to the new MemberId. Avoiding fastcdr dependency. Signed-off-by: Miguel Barro REfs 17138. Test fixes. Avoiding static_cast. @external allows adding members without explicit type. Signed-off-by: Miguel Barro Refs 17138. Finishing doxygen Signed-off-by: Miguel Barro Refs 17138. Fixing typos Signed-off-by: Miguel Barro Refs 17138. Fixing Mac/Windows CI issues Signed-off-by: Miguel Barro Refs 17138. Fix Mac debug conditions Refs 17138. Unifying attribute handling on config.h.in Signed-off-by: Miguel Barro Refs 17138. Moving the new API to types::v1_3 namespace. Fixing testing & examples. Signed-off-by: Miguel Barro Refs 17138. Fixing docs and gcc issues Signed-off-by: Miguel Barro Refs 17138. Reintroducing sources Fixing ambiguities and building fastrtps Fixing examples and tests. Signed-off-by: Miguel Barro Refs 17138. Providing backwards compatibility with xtypes 1.1 Signed-off-by: Miguel Barro Refs 17138. Adapt test and examples to xtypes 1.1 restoration Signed-off-by: Miguel Barro Refs 17138. GCC and MSVC toolset 141 fixes Signed-off-by: Miguel Barro Refs 17138. Tests and doc tests fixes Signed-off-by: Miguel Barro Refs 17138. Fixes testing DDSDynamicHelloWorld Signed-off-by: Miguel Barro REfs 17138. Fix Mac CI warnings Signed-off-by: Miguel Barro Refs 17138. Reintroduced the TypeLookUpExample Signed-off-by: Miguel Barro Refs 17138. Refactoring TypeLookupService to support both xtypes versions Signed-off-by: Miguel Barro Refs 17138. Refactoring TypeLookupService to support both xtypes versions. Debugging outcome. Signed-off-by: Miguel Barro Refs 17138. Fixing DDSSimpleCommunicationTypeDiscovery. Signed-off-by: Miguel Barro Refs 17138. Fixing Mac CI issues Signed-off-by: Miguel Barro Refs 17138. Linter pass Signed-off-by: Miguel Barro Refs 17138. Fixing Copyright dates Signed-off-by: Miguel Barro Refs 17138. Applyig api changes Signed-off-by: Miguel Barro Refs 17138. Refactor type builder creation according to review Signed-off-by: Miguel Barro Refs 17138. create_sequence_type update according to review Signed-off-by: Miguel Barro Refs 17138. create_map_type updated according to review Signed-off-by: Miguel Barro Refs 17138. create_primitive_type updated according to review Signed-off-by: Miguel Barro Refs 17138. Moving from create_xxx_type to get_xxxx_type according to review Signed-off-by: Miguel Barro Refs 17138. Renaming new headers using the .hpp convention Signed-off-by: Miguel Barro Refs 17138. Test fixes. Signed-off-by: Miguel Barro Refs 17138. Add external reference counting ancillary Signed-off-by: Miguel Barro Refs 17138. Refactor interfaces to raw pointers Signed-off-by: Miguel Barro Refs 17138. Introduced ancillary classes Signed-off-by: Miguel Barro Refs 17138. API update fixes...part 1 Signed-off-by: Miguel Barro Refs 17138. API update fixes ... part 2 Signed-off-by: Miguel Barro Refs 17138. API update fixes .. part 3 Signed-off-by: Miguel Barro Refs 17138. Fixing gcc issues Signed-off-by: Miguel Barro REfs 17138. API update fixes .. ongoing Signed-off-by: Miguel Barro Revert "REfs 17138. API update fixes .. ongoing" This reverts commit b6ae13fd24456ab971f390189487086c11559a2e. Signed-off-by: Miguel Barro Revert "Refs 17138. Fixing gcc issues" This reverts commit 5b37876037467e04b9cc3b36203dee70efdcd8b7. Signed-off-by: Miguel Barro Refs 17138. Spliting implementation from public APIs Signed-off-by: Miguel Barro Refs 17138. New TypeDescriptor implementation Signed-off-by: Miguel Barro Refs 17138. New MemberDescriptor implementation Signed-off-by: Miguel Barro Refs 17138. New Anotation & DynamicMembers implementation Signed-off-by: Miguel Barro Refs 17138. Fixing implementation details Signed-off-by: Miguel Barro Refs 17138. DynamicTypeBuilderFactory interface Signed-off-by: Miguel Barro Refs 17138. DynamicType interface Signed-off-by: Miguel Barro Refs 17138. DynamicTypeBuilder interface Signed-off-by: Miguel Barro Refs 17138. DynamicTypeBuilderFactory to DynamicTypeBuilderFactoryImpl mapping Signed-off-by: Miguel Barro Refs 17138. AnnotationManager interface Signed-off-by: Miguel Barro Refs 17138. AnnotationDescriptor interface Signed-off-by: Miguel Barro Refs 17138. MemberDescriptor interface Signed-off-by: Miguel Barro Refs 17138. DynamicTypeMember interface Signed-off-by: Miguel Barro Refs 17138. TypeDescriptor fixes 🛠️ Signed-off-by: Miguel Barro Refs 17138. DynamicType interface Signed-off-by: Miguel Barro Refs 17138. Rethinking annotation interfaces 🛠️ Signed-off-by: Miguel Barro Refs 17138. DynamicType and builder missing members Signed-off-by: Miguel Barro Refs 17138. DynamicTypeMember collections interfaces Signed-off-by: Miguel Barro Refs 17138. fixing smart pointers Signed-off-by: Miguel Barro Refs 17138. Fixing TypeObjectFactory ... ongoing Signed-off-by: Miguel Barro Refs 17138. Fixed TypeObjectFactory Signed-off-by: Miguel Barro Refs 17138. Splitting DynamicData into STL-free-interface+implementation Signed-off-by: Miguel Barro Refs 17138. DynamicData refactor Signed-off-by: Miguel Barro Refs 17138. DynamicDataFactory refactor Signed-off-by: Miguel Barro Refs 17138. DynamicData implementation done Signed-off-by: Miguel Barro Refs 17138. DynamicData_ptr refactor Signed-off-by: Miguel Barro Refs 17138. DynamicDataImpl builds on release mode Signed-off-by: Miguel Barro Refs 17138. DynamicDataImpl builds on debug mode Signed-off-by: Miguel Barro Refs 17138. DynamicPubSub refactor Signed-off-by: Miguel Barro Refs 17138. DynamicPubSub refactor Signed-off-by: Miguel Barro Refs 17138. DynamicPubSub refactor Signed-off-by: Miguel Barro Refs 17138. fixing fastrtps target build Signed-off-by: Miguel Barro Refs 17138. fixing fastrtps target build Signed-off-by: Miguel Barro Refs 17138. fixing fastrtps target linking Signed-off-by: Miguel Barro Refs 17138. fixing gcc errors Signed-off-by: Miguel Barro Refs 17138. fixing gcc errors Signed-off-by: Miguel Barro Refs 17138. updating examples Signed-off-by: Miguel Barro Refs 17138. fixed examples Signed-off-by: Miguel Barro Refs 17138. simplify loans Signed-off-by: Miguel Barro Refs 17138: fix DDSSQLFilterTests Signed-off-by: Miguel Barro Refs 17138: fixing ParticipantTests Signed-off-by: Miguel Barro fixed ParticipantTests Signed-off-by: Miguel Barro fixed BlackboxTests_DDS_PIM Signed-off-by: Miguel Barro fixed DDSSimpleCommunicationDynamicPublisher Signed-off-by: Miguel Barro Refs 17138. fixed DDSSimpleCommunicationDynamicSubscriber Signed-off-by: Miguel Barro Refs 17138. Creating mocks for XMLProfile testing Signed-off-by: Miguel Barro Revert "Refs 17138. Creating mocks for XMLProfile testing" This reverts commit 40c42c9937969fabd957e20768ab9e2c76976812. Refs 17138. Fixed XMLProfileParserTests Signed-off-by: Miguel Barro Refs 17138. Propagate include dependencies with xtypes target Signed-off-by: Miguel Barro Refs 17138. Fixing DynamicTypesTests Signed-off-by: Miguel Barro Refs #18494. Making it compile Signed-off-by: Ricardo González Moreno * Refs 17138. Applied new dynamic-types Types.hpp Signed-off-by: Ricardo González Moreno * Refs 17138. New TypeDescriptor Signed-off-by: Ricardo González Moreno * Refs 17138. Applying new TypeDescriptor Signed-off-by: Ricardo González Moreno * Refs 17138. Update after rebase new TypeDescriptor Signed-off-by: Ricardo González Moreno * Refs 17138. New MemberDescriptor API Signed-off-by: Ricardo González Moreno * Refs 17138. New MemberDescriptor impl Signed-off-by: Ricardo González Moreno * Refs 17138. Fix after rebase Signed-off-by: Ricardo González Moreno * Refs 17138. New AnnotationDescriptor impl Signed-off-by: Ricardo González Moreno * Refs 17138. New DynamicTypeMember API Signed-off-by: Ricardo González Moreno * Refs 17138. New DynamicTypeMember impl Signed-off-by: Ricardo González Moreno * Refs 17138. Fix after rebase Signed-off-by: Ricardo González Moreno * Refs 17138. New DynamicType API Signed-off-by: Ricardo González Moreno * Refs 17138. New DynamicType impl Signed-off-by: Ricardo González Moreno * Refs 17138. New DynamicTypeBuilder API Signed-off-by: Ricardo González Moreno * Refs 17138. New DynamicTypeBuilder impl Signed-off-by: Ricardo González Moreno * Refs 17138. New DynamicTypeBuilderFactory API Signed-off-by: Ricardo González Moreno * Refs 17138. New DynamicTypeBuilderFactory impl Signed-off-by: Ricardo González Moreno * Refs #17138. New DynamicData API Signed-off-by: Ricardo González Moreno * Refs #17138. New DynamicData impl Signed-off-by: Ricardo González Moreno * Refs #17138. Fix after rebase Signed-off-by: Ricardo González Moreno * Refs #17138. Fixes Signed-off-by: Ricardo González Moreno * Refs #17138. Continue impl DynamicData Signed-off-by: Ricardo González Moreno * Refs #17138. First approach XVCRv2 Signed-off-by: Ricardo González Moreno * Refs #17138. Several: - Support enum - Fix clearing functions Signed-off-by: Ricardo González Moreno * Refs #17138. Support string types * Refs #17138. Support string types Signed-off-by: Ricardo González Moreno * Refs #17138. Fixes after rebase Signed-off-by: Ricardo González Moreno * Refs #17138. Add primitive sequences Signed-off-by: Ricardo González Moreno * Refs #17138. Support sequences inside sequences Signed-off-by: Ricardo González Moreno * Refs #17138. Support of arrays Signed-off-by: Ricardo González Moreno * Refs #17138. Improve structure support Signed-off-by: Ricardo González Moreno * Refs #17138. Support unions. Signed-off-by: Ricardo González Moreno * Refs #17138. Support of maps. Signed-off-by: Ricardo González Moreno * Refs #17138. Support of bitmasks Signed-off-by: Ricardo González Moreno * Refs #17138. Fix rebase and remove use of old dynamic api Signed-off-by: Ricardo González Moreno * Refs #17138. Remove old code Signed-off-by: Ricardo González Moreno * Refs #17138. Refactor test to use DDS API Signed-off-by: Ricardo González Moreno * Refs #17138. Fixes Signed-off-by: Ricardo González Moreno * Refs #17138. Bring to live xml tests Signed-off-by: Ricardo González Moreno * Refs #17138. Fix Signed-off-by: Ricardo González Moreno * Refs #17138. Forgotten use of template Signed-off-by: Ricardo González Moreno * Refs #17138. Support of bitsets Signed-off-by: Ricardo González Moreno * Refs #17138. Implementation: - serialize_key - calculate_key_serialized_size - calculate_max_serialized_size Add extensibility check. Fix serialization of key. Signed-off-by: Ricardo González Moreno * Refs #17138. Testing calculate_max_serialized_size. Also fix checking string bound. Signed-off-by: Ricardo González Moreno * Refs #17138. Implement DynamicData::clone Signed-off-by: Ricardo González Moreno * Refs #17138. Implement get_complex_data Signed-off-by: Ricardo González Moreno * Refs #17138. Fix aliases of enumerators Signed-off-by: Ricardo González Moreno * Refs #17138. Move dynamictests to feature folder Signed-off-by: Ricardo González Moreno * Refs #17138. Implementation set_complex_value Signed-off-by: Ricardo González Moreno * Refs #17138. Fix warning on windows Signed-off-by: Ricardo González Moreno * Refs #17138. Improve alias management Signed-off-by: Ricardo González Moreno * Refs #17138. Remove unused file Signed-off-by: Ricardo González Moreno * Refs #17138. Fix warnings on Windows Signed-off-by: Ricardo González Moreno * Refs #17138. Change Bitmask behaviour Signed-off-by: Ricardo González Moreno * Refs #17138. Fix warnings on Windows Signed-off-by: Ricardo González Moreno * Refs #17138. Improve bitmask usage Signed-off-by: Ricardo González Moreno * Refs #17138. Removed examples Signed-off-by: Ricardo González Moreno * Refs #17138. Fix warnings Signed-off-by: Ricardo González Moreno * Refs #17138. Fix bitfield as boolean Signed-off-by: Ricardo González Moreno * Refs #17138. Fix warnings on windows Signed-off-by: Ricardo González * Refs #17138. Fix bitset Signed-off-by: Ricardo González Moreno * Refs #17138. Remove unused header Signed-off-by: Ricardo González Moreno * Refs #17138. Using new CdrSizeCalculator API for arrays Signed-off-by: Ricardo González Moreno * Refs #17138. Refactor xtypes interface library Signed-off-by: Ricardo González Moreno * Refs #17138. Fix warnings on windows Signed-off-by: Ricardo González * Refs #17138. Improves reviewing Signed-off-by: Ricardo González Moreno * Refs #17138. Fix deserialization of unions Signed-off-by: Ricardo González Moreno * Refs #17138. Applying review Signed-off-by: Ricardo González Moreno * Refs #17138. Applying changes after review Signed-off-by: Ricardo González Moreno * Refs #17138. Several fixes Signed-off-by: Ricardo González Moreno * Refs #17138. Several fixes Signed-off-by: Ricardo González Moreno * Refs #17138. - Improve enumerations - Fix reading bitset from XML - Ordering function in some classes Signed-off-by: Ricardo González Moreno * Refs #17138. - Fix sequence of strings - Fix sequence of bitmask - Add promotion on sequences Signed-off-by: Ricardo González Moreno * Refs #17138. Remove obsolete test code Signed-off-by: Ricardo González Moreno * Refs #17138. Fixing arrays and sequences Signed-off-by: Ricardo González Moreno * Refs #17138. Remove todos Signed-off-by: Ricardo González Moreno * Refs #17138. Fix Signed-off-by: Ricardo González Moreno * Refs #17138. Fix accessing an empty sequence Signed-off-by: Ricardo González Moreno * Refs #17138. Fix warning on windows Signed-off-by: Ricardo González * Refs #17138. Fix warnings on windows Signed-off-by: Ricardo González Moreno * Refs #17138. Fix warnings on windows Signed-off-by: Ricardo González Moreno * Refs #17138. Fix warnings Signed-off-by: Ricardo González * Refs #17138. Fixes in maps Signed-off-by: Ricardo González Moreno * Refs #17138. Apply suggestions 1 Signed-off-by: Ricardo González Moreno * Refs #17138. Apply suggestions 2 Signed-off-by: Ricardo González Moreno * Refs #17138. Fix inheritance Signed-off-by: Ricardo González Moreno * Refs #17138. Apply suggestions 3 Signed-off-by: Ricardo González Moreno * Refs #17138. Apply suggestions 4 Signed-off-by: Ricardo González Moreno * Refs #17138. Forgotten suggestion Signed-off-by: Ricardo González Moreno * Refs #17138. Applying suggestions 5 Signed-off-by: Ricardo González Moreno * Refs #17138. Move test to other branch Signed-off-by: Ricardo González Moreno * Refs #17138. Applying suggestions 6 Signed-off-by: Ricardo González Moreno * Refs #17138. Apply suggestions 7 Signed-off-by: Ricardo González Moreno * Refs #17138. Apply suggestion 8 Signed-off-by: Ricardo González Moreno * Refs #17138. Apply suggestions 9 Signed-off-by: Ricardo González Moreno * Refs #17138. Fix uncrustify Signed-off-by: Ricardo González Moreno * Refs #20595: apply review suggestions Signed-off-by: JLBuenoLopez-eProsima * Refs #20595: linters Signed-off-by: JLBuenoLopez-eProsima * Refs #20595: apply review suggestion and fix Mac warnings Signed-off-by: JLBuenoLopez-eProsima --------- Signed-off-by: Ricardo González Moreno Signed-off-by: Ricardo González Signed-off-by: Ricardo González Signed-off-by: JLBuenoLopez-eProsima Co-authored-by: Miguel Barro Co-authored-by: JLBuenoLopez-eProsima DynamicTypeBuilderFactoryImpl::create_type_w_type_object implementation (#4368) * Refs #20335: add verbatim to DynamicTypeBuilder Signed-off-by: JLBuenoLopez-eProsima * Refs #20335: check minimal TypeObject consistency. Check consistency before registering Signed-off-by: JLBuenoLopez-eProsima * Refs #20335: DynamicTypeBuilderFactoryImpl::create_type_w_type_object implementation Signed-off-by: JLBuenoLopez-eProsima * Refs #20335: correctly pass reference to DynamicDataImpl::delete_data Signed-off-by: JLBuenoLopez-eProsima * Refs #20335: create TypeObjectUtils and TypeObjectRegistry mock classes Signed-off-by: JLBuenoLopez-eProsima * Refs #20335: fix test suite build Signed-off-by: JLBuenoLopez-eProsima * Refs #20335: fix DDS Filter tests Signed-off-by: JLBuenoLopez-eProsima * Refs #20335: fix warning by reverting changes Signed-off-by: JLBuenoLopez-eProsima * Refs #20335: apply review suggestions Signed-off-by: JLBuenoLopez-eProsima * Refs #20335: linters Signed-off-by: JLBuenoLopez-eProsima * Refs #20335: fix bitmask generation Signed-off-by: JLBuenoLopez-eProsima * Refs #20335: Fix content filter Signed-off-by: Ricardo González Moreno * Refs #20335: fix after rebase Signed-off-by: JLBuenoLopez-eProsima * Refs #20335: apply review suggestions Signed-off-by: JLBuenoLopez-eProsima * Refs #20335: regenerate types Signed-off-by: JLBuenoLopez-eProsima * Refs #20335: fix test after union refactor Signed-off-by: JLBuenoLopez-eProsima --------- Signed-off-by: JLBuenoLopez-eProsima Signed-off-by: Ricardo González Moreno Co-authored-by: Ricardo González Moreno * Refs #20738. Fix after rebase Signed-off-by: Ricardo González Moreno * Refs #20738. Refactor monitor service Signed-off-by: Ricardo González Moreno * Refs #20738. Fix latency test Signed-off-by: Ricardo González Moreno * Refs #20738. Apply suggestions 1 Signed-off-by: Ricardo González Moreno * Refs #20738. Fix compilation without statistics Signed-off-by: Ricardo González Moreno * Refs … * TypeLookup listeners implementation (#4240) * Refs #20157: Implemented async_get_type replies. Signed-off-by: adriancampo * Refs #20157: Changeds to instance_name. Signed-off-by: adriancampo * Refs #20157: Changes to check_type_identifier_received Signed-off-by: adriancampo * Refs #20157: Added continuation point checks. Signed-off-by: adriancampo * Refs #20157: Removed old function Signed-off-by: adriancampo * Refs #20160: Implemented async_get_type request listener. Signed-off-by: adriancampo * Refs #20160: Added continuation point management Signed-off-by: adriancampo * Refs #20160: Renames and comments improvements Signed-off-by: adriancampo * Refs #20160: Fixed deadlock, renamed discovery methods. Applied suggestions. Signed-off-by: adriancampo * Refs #20160: Small fix in reply error check. Signed-off-by: adriancampo * Refs #20160: Created get_complementary_type_identifier method. Signed-off-by: adriancampo * Refs #20160: Added valid_matching check for TypeInformation. Signed-off-by: adriancampo * Refs #20160: Added send and receive error logs. Added missing continuation_point reply management Signed-off-by: adriancampo * Refs #20160: Added check for requests with no TypeIdentifiers and small fixes. Signed-off-by: adriancampo * Refs #20160: Added listener classes to handle change acks Signed-off-by: adriancampo * Refs #20160: Restored minimal_from_complete_type_identifier method from TypeObjectRegistry Signed-off-by: adriancampo * Refs #20160: Fixes for TypeInformation serializer Signed-off-by: adriancampo * Refs #20160: Added typelookup_service_threads to XMLParser Signed-off-by: adriancampo * Refs #20160. Remove old function Signed-off-by: Ricardo González Moreno * Refs #20160. Fix Signed-off-by: Ricardo González Moreno * Refs #20160: Fixes for TypeLookupManager destruction with pending callbacks. Signed-off-by: adriancampo * Refs #20160: Changes for instance_names to use the full GUID. Signed-off-by: adriancampo * Refs #20160: Applied suggestions. Removed overloaded discovery methods. Signed-off-by: adriancampo * Refs #20160: Changes for xtypes doc. Signed-off-by: adriancampo * Refs #20160: Fix for LOG macro. Remove consistency check from register_type_object(from TypeLookupManager). Signed-off-by: adriancampo * Refs #20160: Applied suggestions. Signed-off-by: adriancampo * Refs #20160: Removed obsolete check. Signed-off-by: adriancampo * Refs #20160: Fixed DS tests and warnings. Signed-off-by: adriancampo * Refs #20160: Fixes after rebase. Signed-off-by: adriancampo * Refs #20160: Windows warning. Signed-off-by: adriancampo * Refs #20160: Applied suggestions. Signed-off-by: adriancampo * Refs #20160: Fixed tests. Signed-off-by: adriancampo * Refs #20242. Update unsupported_type_info tests. Now we works successfully against OpenDDS 3.27 Signed-off-by: Ricardo González Moreno * Refs #20242. Apply suggestion Signed-off-by: Ricardo González Moreno * Refs #20242. Fix log thread being killed in windows on unit test Signed-off-by: Ricardo González --------- Signed-off-by: adriancampo Signed-off-by: Ricardo González Moreno Signed-off-by: Ricardo González Co-authored-by: Ricardo González Moreno * DataReader::return_loan returns OK on loanable sequences without loans (#4503) * Refs #20583: Add test and fix doxygen Signed-off-by: EduPonz * Refs #20583: return_loan returns OK when the loanable collection has ownership (does not have loans) Signed-off-by: EduPonz * Refs #20583: Update tests to new behaviour Signed-off-by: EduPonz * Refs #20583: Add entry to versions.md Signed-off-by: EduPonz --------- Signed-off-by: EduPonz * Structure DynamicType inheritance from TypeObject (#4712) * Hotfix: Struct DynamicType inheritance from TypeObject Signed-off-by: JLBuenoLopez-eProsima * Apply review suggestion Signed-off-by: JLBuenoLopez-eProsima --------- Signed-off-by: JLBuenoLopez-eProsima * Prepare 3.0.x-devel to become master (#4723) * Refs #20893: Upgrade mirror job Signed-off-by: eduponz * Refs #20893: Update readme warning Signed-off-by: eduponz * Refs #20893: Remove 3.0.x rebase workflow Signed-off-by: eduponz * Refs #20893: Prepare CI for master switch Signed-off-by: eduponz * Refs #20893: Update PR template Signed-off-by: eduponz * Refs #20893: Apply Eliana's suggestions Signed-off-by: eduponz * Refs #20893: Apply Eliana's suggestions Signed-off-by: eduponz --------- Signed-off-by: eduponz * Changes in doxygen to fix warnings on documentation (#4700) Signed-off-by: Ricardo González Moreno --------- Signed-off-by: elianalf <62831776+elianalf@users.noreply.github.com> Signed-off-by: JLBuenoLopez-eProsima Signed-off-by: EduPonz Signed-off-by: JesusPoderoso Signed-off-by: Ricardo González Moreno Signed-off-by: adriancampo Signed-off-by: Ricardo González Signed-off-by: eduponz Co-authored-by: elianalf <62831776+elianalf@users.noreply.github.com> Co-authored-by: José Luis Bueno López <69244257+JLBuenoLopez-eProsima@users.noreply.github.com> Co-authored-by: Jesús Poderoso <120394830+JesusPoderoso@users.noreply.github.com> Co-authored-by: Ricardo González Co-authored-by: Adrian del Campo <107918259+adriancampo@users.noreply.github.com> --- .github/pull_request_template.md | 7 +- .github/workflows/config/asan_colcon.meta | 3 +- .github/workflows/config/ci.meta | 5 +- .github/workflows/config/documentation.meta | 2 +- .github/workflows/config/tsan_colcon.meta | 3 +- .github/workflows/documentation-tests.yaml | 8 +- .github/workflows/mac-ci.yml | 2 +- .github/workflows/mirror.yml | 26 +- .github/workflows/nightly-mac-ci.yml | 30 +- .github/workflows/nightly-sanitizers-ci.yml | 28 +- .github/workflows/nightly-ubuntu-ci.yml | 34 +- .github/workflows/nightly-windows-ci.yml | 30 +- .github/workflows/rebase-3.0.x-devel.yaml | 47 - .github/workflows/reusable-mac-ci.yml | 12 +- .github/workflows/reusable-sanitizers-ci.yml | 48 +- .github/workflows/reusable-ubuntu-ci.yml | 12 +- .github/workflows/reusable-windows-ci.yml | 12 +- .github/workflows/ubuntu-ci.yml | 2 +- .github/workflows/windows-ci.yml | 2 +- .settings/org.eclipse.cdt.codan.core.prefs | 67 - CMakeLists.txt | 18 +- CTestJenkins.cmake | 88 - QUALITY.md | 2 +- README.md | 99 +- UPGRADING.md | 2 +- build_qnx/common.mk | 2 +- cmake/modules/FindTinyXML2.cmake | 2 +- cmake/packaging/Config.cmake.in | 68 +- ...rtps-config.cmake => fastdds-config.cmake} | 4 +- ...strtps.manifest.in => fastdds.manifest.in} | 0 colcon.pkg | 2 +- doc/README.html.in | 1273 - doc/design/intra-process.md | 93 - .../interprocess_shared_mem.md | 105 - .../interprocess_shared_mem1.png | Bin 86126 -> 0 bytes .../interprocess_shared_mem2.plantuml | 68 - .../interprocess_shared_mem2.png | Bin 37242 -> 0 bytes doc/pdf/FASTRTPSGEN - User Manual.odt | Bin 109970 -> 0 bytes doc/pdf/Fast RTPS - Installation Manual.odt | Bin 103394 -> 0 bytes doc/pdf/Fast RTPS - Latency Test.odt | Bin 153509 -> 0 bytes doc/pdf/Fast RTPS - Throughput Test.odt | Bin 148247 -> 0 bytes doc/pdf/Fast RTPS - User Manual.odt | Bin 281315 -> 0 bytes .../sony/PubSub_overview.png | Bin 48256 -> 0 bytes .../sony/RPC_overview.png | Bin 108738 -> 0 bytes .../sony/improvement.png | Bin 36300 -> 0 bytes .../sony/ms1_rtps_shared_memory_transport.md | 127 - .../ms2_rmw_shared_memory_data_share_sony.md | 87 - .../sony/rmw_sony_cpp.png | Bin 115480 -> 0 bytes examples/CMakeLists.txt | 2 +- .../AdvancedConfiguration.cxx | 214 - ...figuration.h => AdvancedConfiguration.hpp} | 152 +- .../AdvancedConfigurationCdrAux.hpp | 8 +- .../AdvancedConfigurationCdrAux.ipp | 4 - .../AdvancedConfigurationPubSubTypes.cxx | 16 +- .../AdvancedConfigurationPubSubTypes.h | 11 +- .../AdvancedConfigurationPublisher.cpp | 8 +- .../AdvancedConfigurationSubscriber.cpp | 8 +- ...AdvancedConfigurationTypeObjectSupport.cxx | 461 + ...AdvancedConfigurationTypeObjectSupport.hpp | 54 + .../AdvancedConfigurationv1.cxx | 361 - .../AdvancedConfigurationv1.h | 274 - .../CMakeLists.txt | 6 +- .../AdvancedConfigurationExample/README.md | 4 +- .../arg_configuration.h | 2 +- .../AdvancedConfigurationExample/shm_off.xml | 2 +- .../BasicConfigurationPublisher.cpp | 6 +- .../BasicConfigurationSubscriber.cpp | 8 +- .../BasicConfigurationExample/CMakeLists.txt | 6 +- .../BasicConfigurationExample/HelloWorld.cxx | 168 - .../{HelloWorld.h => HelloWorld.hpp} | 125 +- .../HelloWorldCdrAux.hpp | 4 +- .../HelloWorldCdrAux.ipp | 2 - .../HelloWorldPubSubTypes.cxx | 14 +- .../HelloWorldPubSubTypes.h | 9 +- .../HelloWorldTypeObjectSupport.cxx | 306 + .../HelloWorldTypeObjectSupport.hpp | 54 + .../HelloWorldv1.cxx | 288 - .../BasicConfigurationExample/HelloWorldv1.h | 244 - .../dds/BasicConfigurationExample/README.md | 2 +- .../arg_configuration.h | 2 +- examples/cpp/dds/CMakeLists.txt | 1 - .../cpp/dds/Configurability/CMakeLists.txt | 8 +- .../ConfigurabilityPublisher.cpp | 4 +- .../ConfigurabilitySubscriber.cpp | 6 +- examples/cpp/dds/Configurability/sample.cxx | 158 - .../sample.h => Configurability/sample.hpp} | 121 +- .../cpp/dds/Configurability/sampleCdrAux.hpp | 4 +- .../cpp/dds/Configurability/sampleCdrAux.ipp | 2 - .../dds/Configurability/samplePubSubTypes.cxx | 14 +- .../dds/Configurability/samplePubSubTypes.h | 9 +- .../sampleTypeObjectSupport.cxx | 224 + .../sampleTypeObjectSupport.hpp | 54 + examples/cpp/dds/Configurability/samplev1.cxx | 280 - examples/cpp/dds/Configurability/samplev1.h | 237 - .../CMakeLists.txt | 10 +- .../ContentFilteredTopicExamplePublisher.cpp | 6 +- .../ContentFilteredTopicExampleSubscriber.cpp | 10 +- .../HelloWorld.cxx | 172 - .../HelloWorld.hpp} | 124 +- .../HelloWorldCdrAux.hpp | 4 +- .../HelloWorldCdrAux.ipp | 2 - .../HelloWorldPubSubTypes.cxx | 14 +- .../HelloWorldPubSubTypes.h | 9 +- .../HelloWorldTypeObject.cxx | 263 - .../HelloWorldTypeObject.h | 65 - .../HelloWorldTypeObjectSupport.cxx | 248 + .../HelloWorldTypeObjectSupport.hpp | 54 + .../HelloWorldv1.cxx | 290 - .../HelloWorldv1.h | 244 - .../MyCustomFilterFactory.hpp | 20 +- .../dds/CustomListenerExample/CMakeLists.txt | 6 +- .../CustomListenerPublisher.cpp | 11 +- .../CustomListenerSubscriber.cpp | 11 +- .../CustomListenerSubscriber.h | 10 +- .../CustomListener_main.cpp | 8 +- .../CustomListenerExample/CustomListeners.cpp | 24 +- .../CustomListenerExample/CustomListeners.h | 22 +- .../cpp/dds/CustomListenerExample/Topic.cxx | 168 - .../Topic.hpp} | 124 +- .../dds/CustomListenerExample/TopicCdrAux.hpp | 4 +- .../dds/CustomListenerExample/TopicCdrAux.ipp | 2 - .../TopicPubSubTypes.cxx | 14 +- .../CustomListenerExample/TopicPubSubTypes.h | 9 +- .../TopicTypeObjectSupport.cxx | 248 + .../TopicTypeObjectSupport.hpp | 54 + .../cpp/dds/CustomListenerExample/Topicv1.cxx | 286 - .../cpp/dds/CustomListenerExample/Topicv1.h | 244 - .../CustomPayloadPoolExample/CMakeLists.txt | 6 +- .../CustomPayloadPoolData.cxx | 168 - ...adPoolData.h => CustomPayloadPoolData.hpp} | 124 +- .../CustomPayloadPoolDataCdrAux.hpp | 4 +- .../CustomPayloadPoolDataCdrAux.ipp | 2 - .../CustomPayloadPoolDataPubSubTypes.cxx | 14 +- .../CustomPayloadPoolDataPubSubTypes.h | 9 +- .../CustomPayloadPoolDataPublisher.cpp | 11 +- .../CustomPayloadPoolDataSubscriber.cpp | 10 +- .../CustomPayloadPoolDataSubscriber.h | 8 +- ...CustomPayloadPoolDataTypeObjectSupport.cxx | 248 + ...CustomPayloadPoolDataTypeObjectSupport.hpp | 54 + .../CustomPayloadPoolDatav1.cxx | 286 - .../CustomPayloadPoolDatav1.h | 244 - .../CustomPayloadPool_main.cpp | 9 +- .../cpp/dds/DeadlineQoSExample/CMakeLists.txt | 6 +- .../DeadlineQoSExample/deadlinepayload.cxx | 168 - ...{deadlinepayload.h => deadlinepayload.hpp} | 124 +- .../deadlinepayloadCdrAux.hpp | 4 +- .../deadlinepayloadCdrAux.ipp | 2 - .../deadlinepayloadPubSubMain.cxx | 4 - .../deadlinepayloadPubSubTypes.cxx | 14 +- .../deadlinepayloadPubSubTypes.h | 9 +- .../deadlinepayloadSubscriber.cxx | 2 +- .../deadlinepayloadSubscriber.h | 4 +- .../deadlinepayloadTypeObjectSupport.cxx | 261 + .../deadlinepayloadTypeObjectSupport.hpp | 54 + .../DeadlineQoSExample/deadlinepayloadv1.cxx | 294 - .../DeadlineQoSExample/deadlinepayloadv1.h | 244 - .../cpp/dds/DeadlineQoSExample/mapableKey.h | 56 - .../dds/DisablePositiveACKs/CMakeLists.txt | 6 +- .../DisablePositiveACKS_main.cpp | 6 +- .../DisablePositiveACKsPublisher.h | 2 +- .../DisablePositiveACKsSubscriber.cpp | 2 +- .../DisablePositiveACKsSubscriber.h | 2 +- .../cpp/dds/DisablePositiveACKs/Topic.cxx | 168 - .../Topic.h => DisablePositiveACKs/Topic.hpp} | 124 +- .../dds/DisablePositiveACKs/TopicCdrAux.hpp | 4 +- .../dds/DisablePositiveACKs/TopicCdrAux.ipp | 2 - .../DisablePositiveACKs/TopicPubSubTypes.cxx | 14 +- .../DisablePositiveACKs/TopicPubSubTypes.h | 9 +- .../TopicTypeObjectSupport.cxx | 248 + .../TopicTypeObjectSupport.hpp | 54 + .../cpp/dds/DisablePositiveACKs/Topicv1.cxx | 286 - .../cpp/dds/DisablePositiveACKs/Topicv1.h | 244 - .../dds/DiscoveryServerExample/CMakeLists.txt | 6 +- .../DiscoveryServerPublisher.cpp | 12 +- .../DiscoveryServerPublisher.h | 3 +- .../DiscoveryServerServer.cpp | 13 +- .../DiscoveryServerServer.h | 3 +- .../DiscoveryServerSubscriber.cpp | 18 +- .../DiscoveryServerSubscriber.h | 3 +- .../arg_configuration.h | 2 +- .../cpp/dds/DiscoveryServerExample/common.h | 2 +- .../types/HelloWorld.cxx | 168 - .../types/{HelloWorld.h => HelloWorld.hpp} | 124 +- .../types/HelloWorldCdrAux.hpp | 4 +- .../types/HelloWorldCdrAux.ipp | 2 - .../types/HelloWorldPubSubTypes.cxx | 14 +- .../types/HelloWorldPubSubTypes.h | 9 +- .../types/HelloWorldTypeObjectSupport.cxx | 248 + .../types/HelloWorldTypeObjectSupport.hpp | 54 + .../types/HelloWorldv1.cxx | 286 - .../types/HelloWorldv1.h | 244 - .../DynamicHelloWorldExample/CMakeLists.txt | 6 +- .../HelloWorldPublisher.cpp | 116 +- .../HelloWorldPublisher.h | 4 +- .../HelloWorldSubscriber.cpp | 35 +- .../HelloWorldSubscriber.h | 34 +- .../HelloWorld_main.cpp | 2 +- .../helloworld_example_type_profile.xml | 2 +- examples/cpp/dds/Filtering/CMakeLists.txt | 6 +- .../cpp/dds/Filtering/FilteringExample.cxx | 124 - ...ilteringExample.h => FilteringExample.hpp} | 99 +- .../dds/Filtering/FilteringExampleCdrAux.hpp | 4 +- .../dds/Filtering/FilteringExampleCdrAux.ipp | 2 - .../Filtering/FilteringExamplePubSubMain.cxx | 4 - .../Filtering/FilteringExamplePubSubTypes.cxx | 14 +- .../Filtering/FilteringExamplePubSubTypes.h | 9 +- .../Filtering/FilteringExampleSubscriber.cxx | 2 +- .../FilteringExampleTypeObjectSupport.cxx | 147 + .../FilteringExampleTypeObjectSupport.hpp | 54 + .../cpp/dds/Filtering/FilteringExamplev1.cxx | 223 - .../cpp/dds/Filtering/FilteringExamplev1.h | 216 - .../cpp/dds/FlowControlExample/CMakeLists.txt | 6 +- .../FlowControlExample/FlowControlExample.cxx | 168 - ...ontrolExample.h => FlowControlExample.hpp} | 127 +- .../FlowControlExampleCdrAux.hpp | 4 +- .../FlowControlExampleCdrAux.ipp | 2 - .../FlowControlExamplePubSubMain.cxx | 5 - .../FlowControlExamplePubSubTypes.cxx | 14 +- .../FlowControlExamplePubSubTypes.h | 9 +- .../FlowControlExampleSubscriber.cxx | 2 +- .../FlowControlExampleTypeObjectSupport.cxx | 306 + .../FlowControlExampleTypeObjectSupport.hpp | 54 + .../FlowControlExamplev1.cxx | 288 - .../FlowControlExample/FlowControlExamplev1.h | 244 - .../cpp/dds/HelloWorldExample/CMakeLists.txt | 6 +- .../cpp/dds/HelloWorldExample/HelloWorld.cxx | 168 - .../HelloWorld.hpp} | 124 +- .../HelloWorldExample/HelloWorldCdrAux.hpp | 4 +- .../HelloWorldExample/HelloWorldCdrAux.ipp | 2 - .../HelloWorldPubSubTypes.cxx | 14 +- .../HelloWorldExample/HelloWorldPubSubTypes.h | 9 +- .../HelloWorldExample/HelloWorldPublisher.cpp | 11 +- .../HelloWorldSubscriber.cpp | 8 +- .../HelloWorldExample/HelloWorldSubscriber.h | 8 +- .../HelloWorldTypeObjectSupport.cxx | 248 + .../HelloWorldTypeObjectSupport.hpp | 54 + .../dds/HelloWorldExample/HelloWorld_main.cpp | 9 +- .../dds/HelloWorldExample/HelloWorldv1.cxx | 286 - .../cpp/dds/HelloWorldExample/HelloWorldv1.h | 244 - examples/cpp/dds/HelloWorldExample/README.txt | 6 +- .../CMakeLists.txt | 6 +- .../HelloWorld.cxx | 168 - .../{HelloWorld.h => HelloWorld.hpp} | 124 +- .../HelloWorldCdrAux.hpp | 4 +- .../HelloWorldCdrAux.ipp | 2 - .../HelloWorldPubSubTypes.cxx | 14 +- .../HelloWorldPubSubTypes.h | 9 +- .../HelloWorldPublisher.cpp | 11 +- .../HelloWorldSubscriber.cpp | 4 +- .../HelloWorldSubscriber.h | 8 +- .../HelloWorldTypeObjectSupport.cxx | 248 + .../HelloWorldTypeObjectSupport.hpp | 54 + .../HelloWorld_main.cpp | 7 +- .../HelloWorldv1.cxx | 290 - .../HelloWorldv1.h | 244 - .../HelloWorldExampleSharedMem/CMakeLists.txt | 6 +- .../HelloWorldExampleSharedMem/HelloWorld.cxx | 212 - .../{HelloWorld.h => HelloWorld.hpp} | 152 +- .../HelloWorldCdrAux.hpp | 4 +- .../HelloWorldCdrAux.ipp | 2 - .../HelloWorldPubSubTypes.cxx | 14 +- .../HelloWorldPubSubTypes.h | 9 +- .../HelloWorldPublisher.h | 2 +- .../HelloWorldSubscriber.cpp | 2 +- .../HelloWorldSubscriber.h | 2 +- .../HelloWorldTypeObjectSupport.cxx | 407 + .../HelloWorldTypeObjectSupport.hpp | 54 + .../HelloWorld_main.cpp | 12 +- .../HelloWorldv1.cxx | 351 - .../HelloWorldExampleSharedMem/HelloWorldv1.h | 272 - .../dds/HelloWorldExampleTCP/CMakeLists.txt | 6 +- .../dds/HelloWorldExampleTCP/HelloWorld.cxx | 168 - .../{HelloWorld.h => HelloWorld.hpp} | 124 +- .../HelloWorldExampleTCP/HelloWorldCdrAux.hpp | 4 +- .../HelloWorldExampleTCP/HelloWorldCdrAux.ipp | 2 - .../HelloWorldPubSubTypes.cxx | 14 +- .../HelloWorldPubSubTypes.h | 9 +- .../HelloWorldPublisher.cpp | 2 +- .../HelloWorldPublisher.h | 2 +- .../HelloWorldSubscriber.cpp | 4 +- .../HelloWorldSubscriber.h | 2 +- .../HelloWorldTypeObjectSupport.cxx | 248 + .../HelloWorldTypeObjectSupport.hpp | 54 + .../HelloWorldExampleTCP/HelloWorld_main.cpp | 10 +- .../dds/HelloWorldExampleTCP/HelloWorldv1.cxx | 286 - .../dds/HelloWorldExampleTCP/HelloWorldv1.h | 244 - examples/cpp/dds/HistoryKind/CMakeLists.txt | 6 +- examples/cpp/dds/HistoryKind/pastsamples.cpp | 4 +- examples/cpp/dds/HistoryKind/sample.cxx | 158 - .../{Keys/sample.h => HistoryKind/sample.hpp} | 121 +- examples/cpp/dds/HistoryKind/sampleCdrAux.hpp | 4 +- examples/cpp/dds/HistoryKind/sampleCdrAux.ipp | 2 - .../cpp/dds/HistoryKind/samplePubSubTypes.cxx | 14 +- .../cpp/dds/HistoryKind/samplePubSubTypes.h | 9 +- .../HistoryKind/sampleTypeObjectSupport.cxx | 224 + .../HistoryKind/sampleTypeObjectSupport.hpp | 54 + examples/cpp/dds/HistoryKind/samplev1.cxx | 280 - examples/cpp/dds/HistoryKind/samplev1.h | 237 - examples/cpp/dds/Keys/CMakeLists.txt | 6 +- examples/cpp/dds/Keys/keys.cpp | 4 +- examples/cpp/dds/Keys/sample.cxx | 158 - .../{LateJoiners/sample.h => Keys/sample.hpp} | 121 +- examples/cpp/dds/Keys/sampleCdrAux.hpp | 4 +- examples/cpp/dds/Keys/sampleCdrAux.ipp | 2 - examples/cpp/dds/Keys/samplePubSubTypes.cxx | 14 +- examples/cpp/dds/Keys/samplePubSubTypes.h | 9 +- .../cpp/dds/Keys/sampleTypeObjectSupport.cxx | 224 + .../cpp/dds/Keys/sampleTypeObjectSupport.hpp | 54 + examples/cpp/dds/Keys/samplev1.cxx | 280 - examples/cpp/dds/Keys/samplev1.h | 237 - examples/cpp/dds/LateJoiners/CMakeLists.txt | 6 +- examples/cpp/dds/LateJoiners/latejoiners.cpp | 4 +- examples/cpp/dds/LateJoiners/sample.cxx | 158 - .../sample.h => LateJoiners/sample.hpp} | 121 +- examples/cpp/dds/LateJoiners/sampleCdrAux.hpp | 4 +- examples/cpp/dds/LateJoiners/sampleCdrAux.ipp | 2 - .../cpp/dds/LateJoiners/samplePubSubTypes.cxx | 14 +- .../cpp/dds/LateJoiners/samplePubSubTypes.h | 9 +- .../LateJoiners/sampleTypeObjectSupport.cxx | 224 + .../LateJoiners/sampleTypeObjectSupport.hpp | 54 + examples/cpp/dds/LateJoiners/samplev1.cxx | 280 - examples/cpp/dds/LateJoiners/samplev1.h | 237 - .../cpp/dds/LifespanQoSExample/CMakeLists.txt | 6 +- .../cpp/dds/LifespanQoSExample/Lifespan.cxx | 168 - .../{Lifespan.h => Lifespan.hpp} | 124 +- .../dds/LifespanQoSExample/LifespanCdrAux.hpp | 4 +- .../dds/LifespanQoSExample/LifespanCdrAux.ipp | 2 - .../LifespanPubSubTypes.cxx | 14 +- .../LifespanQoSExample/LifespanPubSubTypes.h | 9 +- .../LifespanQoSExample/LifespanPublisher.h | 2 +- .../LifespanQoSExample/LifespanSubscriber.cpp | 4 +- .../LifespanQoSExample/LifespanSubscriber.h | 2 +- .../LifespanTypeObjectSupport.cxx | 248 + .../LifespanTypeObjectSupport.hpp | 54 + .../dds/LifespanQoSExample/Lifespan_main.cpp | 8 +- .../cpp/dds/LifespanQoSExample/Lifespanv1.cxx | 286 - .../cpp/dds/LifespanQoSExample/Lifespanv1.h | 244 - examples/cpp/dds/LivelinessQoS/CMakeLists.txt | 6 +- .../dds/LivelinessQoS/LivelinessPublisher.h | 12 +- .../LivelinessQoS/LivelinessSubscriber.cpp | 6 +- .../dds/LivelinessQoS/LivelinessSubscriber.h | 13 +- .../cpp/dds/LivelinessQoS/Liveliness_main.cpp | 25 +- examples/cpp/dds/LivelinessQoS/Topic.cxx | 168 - .../Topic.h => LivelinessQoS/Topic.hpp} | 124 +- .../cpp/dds/LivelinessQoS/TopicCdrAux.hpp | 4 +- .../cpp/dds/LivelinessQoS/TopicCdrAux.ipp | 2 - .../dds/LivelinessQoS/TopicPubSubTypes.cxx | 14 +- .../cpp/dds/LivelinessQoS/TopicPubSubTypes.h | 9 +- .../LivelinessQoS/TopicTypeObjectSupport.cxx | 248 + .../LivelinessQoS/TopicTypeObjectSupport.hpp | 54 + examples/cpp/dds/LivelinessQoS/Topicv1.cxx | 286 - examples/cpp/dds/LivelinessQoS/Topicv1.h | 244 - .../CMakeLists.txt | 6 +- .../OwnershipStrength.cxx | 202 - ...ershipStrength.h => OwnershipStrength.hpp} | 146 +- .../OwnershipStrengthCdrAux.hpp | 4 +- .../OwnershipStrengthCdrAux.ipp | 2 - .../OwnershipStrengthPubSubMain.cxx | 10 +- .../OwnershipStrengthPubSubTypes.cxx | 14 +- .../OwnershipStrengthPubSubTypes.h | 9 +- .../OwnershipStrengthSubscriber.cxx | 4 +- .../OwnershipStrengthTypeObjectSupport.cxx | 312 + .../OwnershipStrengthTypeObjectSupport.hpp | 54 + .../OwnershipStrengthv1.cxx | 339 - .../OwnershipStrengthv1.h | 265 - .../dds/RequestReplyExample/CMakeLists.txt | 11 +- .../dds/RequestReplyExample/Calculator.cxx | 271 - .../{Calculator.h => Calculator.hpp} | 210 +- .../RequestReplyExample/CalculatorCdrAux.hpp | 6 +- .../RequestReplyExample/CalculatorCdrAux.ipp | 4 - .../RequestReplyExample/CalculatorClient.cpp | 9 +- .../CalculatorPubSubTypes.cxx | 19 +- .../CalculatorPubSubTypes.h | 14 +- .../RequestReplyExample/CalculatorServer.cpp | 9 +- .../CalculatorTypeObjectSupport.cxx | 436 + .../CalculatorTypeObjectSupport.hpp | 61 + .../dds/RequestReplyExample/Calculatorv1.cxx | 467 - .../dds/RequestReplyExample/Calculatorv1.h | 408 - .../SampleConfig_Controller/CMakeLists.txt | 6 +- .../dds/SampleConfig_Controller/sample.cxx | 158 - .../cpp/dds/SampleConfig_Controller/sample.h | 188 - .../dds/SampleConfig_Controller/sample.hpp | 215 + .../SampleConfig_Controller/sampleCdrAux.hpp | 4 +- .../SampleConfig_Controller/sampleCdrAux.ipp | 2 - .../samplePubSubTypes.cxx | 14 +- .../samplePubSubTypes.h | 9 +- .../sampleTypeObjectSupport.cxx | 224 + .../sampleTypeObjectSupport.hpp | 54 + .../sampleconfig_safest.cpp | 2 +- .../dds/SampleConfig_Controller/samplev1.cxx | 280 - .../dds/SampleConfig_Controller/samplev1.h | 237 - .../dds/SampleConfig_Events/CMakeLists.txt | 6 +- .../cpp/dds/SampleConfig_Events/README.txt | 2 +- .../cpp/dds/SampleConfig_Events/sample.cxx | 158 - examples/cpp/dds/SampleConfig_Events/sample.h | 188 - .../cpp/dds/SampleConfig_Events/sample.hpp | 215 + .../dds/SampleConfig_Events/sampleCdrAux.hpp | 4 +- .../dds/SampleConfig_Events/sampleCdrAux.ipp | 2 - .../SampleConfig_Events/samplePubSubTypes.cxx | 14 +- .../SampleConfig_Events/samplePubSubTypes.h | 9 +- .../sampleTypeObjectSupport.cxx | 224 + .../sampleTypeObjectSupport.hpp | 54 + .../sampleconfig_triggers.cpp | 2 +- .../cpp/dds/SampleConfig_Events/samplev1.cxx | 280 - .../cpp/dds/SampleConfig_Events/samplev1.h | 237 - .../SampleConfig_Multimedia/CMakeLists.txt | 6 +- .../dds/SampleConfig_Multimedia/README.txt | 2 +- .../dds/SampleConfig_Multimedia/sample.cxx | 158 - .../cpp/dds/SampleConfig_Multimedia/sample.h | 188 - .../dds/SampleConfig_Multimedia/sample.hpp | 215 + .../SampleConfig_Multimedia/sampleCdrAux.hpp | 4 +- .../SampleConfig_Multimedia/sampleCdrAux.ipp | 2 - .../samplePubSubTypes.cxx | 14 +- .../samplePubSubTypes.h | 9 +- .../sampleTypeObjectSupport.cxx | 224 + .../sampleTypeObjectSupport.hpp | 54 + .../sampleconfig_fastest.cpp | 2 +- .../dds/SampleConfig_Multimedia/samplev1.cxx | 280 - .../dds/SampleConfig_Multimedia/samplev1.h | 237 - .../SecureHelloWorldExample/CMakeLists.txt | 6 +- .../SecureHelloWorldExample/HelloWorld.cxx | 168 - .../dds/SecureHelloWorldExample/HelloWorld.h | 195 - .../SecureHelloWorldExample/HelloWorld.hpp | 227 + .../HelloWorldCdrAux.hpp | 4 +- .../HelloWorldCdrAux.ipp | 2 - .../HelloWorldPubSubTypes.cxx | 14 +- .../HelloWorldPubSubTypes.h | 9 +- .../HelloWorldPublisher.h | 2 +- .../HelloWorldSubscriber.cpp | 2 +- .../HelloWorldSubscriber.h | 2 +- .../HelloWorldTypeObjectSupport.cxx | 248 + .../HelloWorldTypeObjectSupport.hpp | 54 + .../HelloWorld_main.cpp | 8 +- .../SecureHelloWorldExample/HelloWorldv1.cxx | 286 - .../SecureHelloWorldExample/HelloWorldv1.h | 244 - .../StaticHelloWorldExample/CMakeLists.txt | 6 +- .../StaticHelloWorldExample/HelloWorld.cxx | 168 - .../dds/StaticHelloWorldExample/HelloWorld.h | 195 - .../StaticHelloWorldExample/HelloWorld.hpp | 227 + .../HelloWorldCdrAux.hpp | 4 +- .../HelloWorldCdrAux.ipp | 2 - .../HelloWorldPubSubTypes.cxx | 14 +- .../HelloWorldPubSubTypes.h | 9 +- .../HelloWorldPublisher.h | 3 +- .../HelloWorldSubscriber.cpp | 2 +- .../HelloWorldSubscriber.h | 2 +- .../HelloWorldTypeObjectSupport.cxx | 248 + .../HelloWorldTypeObjectSupport.hpp | 54 + .../HelloWorld_main.cpp | 8 +- .../StaticHelloWorldExample/HelloWorldv1.cxx | 286 - .../StaticHelloWorldExample/HelloWorldv1.h | 244 - .../cpp/dds/TypeLookupService/CMakeLists.txt | 53 - examples/cpp/dds/TypeLookupService/README.txt | 17 - .../TypeLookupService/TypeLookupPublisher.cpp | 234 - .../TypeLookupService/TypeLookupPublisher.h | 94 - .../TypeLookupSubscriber.cpp | 267 - .../TypeLookupService/TypeLookupSubscriber.h | 120 - .../dds/TypeLookupService/TypeLookup_main.cpp | 84 - .../example_type_profile.xml | 15 - .../cpp/dds/WriterLoansExample/CMakeLists.txt | 6 +- .../WriterLoansExample/LoanableHelloWorld.cxx | 168 - ...bleHelloWorld.h => LoanableHelloWorld.hpp} | 125 +- .../LoanableHelloWorldCdrAux.hpp | 4 +- .../LoanableHelloWorldCdrAux.ipp | 2 - .../LoanableHelloWorldPubSubTypes.cxx | 14 +- .../LoanableHelloWorldPubSubTypes.h | 9 +- .../LoanableHelloWorldPublisher.cxx | 2 +- .../LoanableHelloWorldSubscriber.cxx | 2 +- .../LoanableHelloWorldTypeObjectSupport.cxx | 313 + .../LoanableHelloWorldTypeObjectSupport.hpp | 54 + .../LoanableHelloWorldv1.cxx | 288 - .../WriterLoansExample/LoanableHelloWorldv1.h | 244 - .../cpp/dds/ZeroCopyExample/CMakeLists.txt | 6 +- .../ZeroCopyExample/LoanableHelloWorld.cxx | 168 - ...bleHelloWorld.h => LoanableHelloWorld.hpp} | 125 +- .../LoanableHelloWorldCdrAux.hpp | 4 +- .../LoanableHelloWorldCdrAux.ipp | 2 - .../LoanableHelloWorldPubSubTypes.cxx | 14 +- .../LoanableHelloWorldPubSubTypes.h | 9 +- .../LoanableHelloWorldPublisher.cxx | 2 +- .../LoanableHelloWorldSubscriber.cxx | 2 +- .../LoanableHelloWorldTypeObjectSupport.cxx | 313 + .../LoanableHelloWorldTypeObjectSupport.hpp | 54 + .../ZeroCopyExample/LoanableHelloWorldv1.cxx | 288 - .../ZeroCopyExample/LoanableHelloWorldv1.h | 244 - examples/cpp/rtps/AsSocket/CMakeLists.txt | 6 +- .../cpp/rtps/AsSocket/TestReaderSocket.cpp | 18 +- examples/cpp/rtps/AsSocket/TestReaderSocket.h | 6 +- .../cpp/rtps/AsSocket/TestWriterSocket.cpp | 21 +- examples/cpp/rtps/AsSocket/TestWriterSocket.h | 9 +- examples/cpp/rtps/AsSocket/main_RTPSTest.cpp | 12 +- examples/cpp/rtps/Persistent/CMakeLists.txt | 6 +- .../rtps/Persistent/TestReaderPersistent.cpp | 23 +- .../rtps/Persistent/TestReaderPersistent.h | 6 +- .../rtps/Persistent/TestWriterPersistent.cpp | 20 +- .../rtps/Persistent/TestWriterPersistent.h | 6 +- .../cpp/rtps/Persistent/main_RTPSTest.cpp | 14 +- examples/cpp/rtps/Registered/CMakeLists.txt | 6 +- .../rtps/Registered/TestReaderRegistered.cpp | 23 +- .../rtps/Registered/TestReaderRegistered.h | 6 +- .../rtps/Registered/TestWriterRegistered.cpp | 20 +- .../rtps/Registered/TestWriterRegistered.h | 6 +- .../cpp/rtps/Registered/main_RTPSTest.cpp | 14 +- fastrtps.repos => fastdds.repos | 6 +- fuzz/C++/fuzz_XMLProfiles/CMakeLists.txt | 6 +- .../C++/fuzz_XMLProfiles/fuzz_XMLProfiles.cxx | 4 +- .../1c82a2c60044985396a5dbbe58ad7fcc5d852d38 | 2 +- fuzz/C++/fuzz_processCDRMsg/CMakeLists.txt | 7 +- .../fuzz_processCDRMsg/fuzz_processCDRMsg.cxx | 3 +- fuzz/CMakeLists.txt | 2 +- include/dds/core/BuiltinTopicTypes.hpp | 220 - include/dds/core/Duration.hpp | 296 - include/dds/core/Entity.hpp | 273 - include/dds/core/EntityQos.hpp | 143 - include/dds/core/Exception.hpp | 479 - include/dds/core/InstanceHandle.hpp | 143 - include/dds/core/LengthUnlimited.hpp | 34 - include/dds/core/Optional.hpp | 105 - include/dds/core/QosProvider.hpp | 355 - include/dds/core/Reference.hpp | 485 - include/dds/core/SafeEnumeration.hpp | 97 - include/dds/core/Time.hpp | 234 - include/dds/core/Value.hpp | 238 - include/dds/core/WeakReference.hpp | 87 - include/dds/core/array.hpp | 33 - include/dds/core/cond/Condition.hpp | 148 - include/dds/core/cond/GuardCondition.hpp | 142 - include/dds/core/cond/StatusCondition.hpp | 242 - include/dds/core/cond/WaitSet.hpp | 427 - include/dds/core/cond/detail/Condition.hpp | 45 - .../dds/core/cond/detail/ConditionImpl.hpp | 92 - .../dds/core/cond/detail/GuardCondition.hpp | 50 - .../core/cond/detail/GuardConditionImpl.hpp | 130 - .../dds/core/cond/detail/StatusCondition.hpp | 49 - .../core/cond/detail/StatusConditionImpl.hpp | 132 - include/dds/core/cond/detail/WaitSet.hpp | 44 - include/dds/core/cond/detail/WaitSetImpl.hpp | 149 - include/dds/core/conformance.hpp | 25 - include/dds/core/ddscore.hpp | 38 - include/dds/core/detail/BuiltinTopicTypes.hpp | 236 - include/dds/core/detail/Entity.hpp | 40 - include/dds/core/detail/EntityQosImpl.hpp | 131 - include/dds/core/detail/InstanceHandle.hpp | 40 - include/dds/core/detail/QosProvider.hpp | 43 - include/dds/core/detail/QosProviderImpl.hpp | 153 - include/dds/core/detail/ReferenceImpl.hpp | 257 - include/dds/core/detail/Value.hpp | 203 - include/dds/core/detail/WeakReferenceImpl.hpp | 71 - include/dds/core/detail/array.hpp | 34 - include/dds/core/detail/conformance.hpp | 44 - include/dds/core/detail/dds_builtinTopics.h | 98 - .../core/detail/dds_builtinTopicsSplDcps.h | 577 - .../core/detail/dds_builtinTopics_DCPS.hpp | 26 - .../dds/core/detail/dds_dcps_builtintopics.h | 41 - .../detail/dds_dcps_builtintopicsSplDcps.h | 178 - .../detail/dds_dcps_builtintopics_DCPS.hpp | 24 - include/dds/core/detail/ddscore.hpp | 23 - include/dds/core/detail/inttypes.hpp | 24 - include/dds/core/detail/macros.hpp | 44 - include/dds/core/detail/module_docs.hpp | 165 - include/dds/core/detail/old_win_stdint.h | 247 - include/dds/core/detail/ref_traits.hpp | 67 - include/dds/core/macros.hpp | 56 - include/dds/core/policy/CorePolicy.hpp | 1705 -- include/dds/core/policy/PolicyKind.hpp | 255 - include/dds/core/policy/QosPolicyCount.hpp | 93 - include/dds/core/policy/detail/CorePolicy.hpp | 98 - .../dds/core/policy/detail/CorePolicyImpl.hpp | 1424 - .../dds/core/policy/detail/QosPolicyCount.hpp | 46 - include/dds/core/ref_traits.hpp | 59 - include/dds/core/refmacros.hpp | 186 - include/dds/core/status/State.hpp | 168 - include/dds/core/status/Status.hpp | 449 - include/dds/core/status/detail/Status.hpp | 68 - include/dds/core/status/detail/StatusImpl.hpp | 414 - include/dds/core/types.hpp | 67 - include/dds/core/xtypes/Annotation.hpp | 283 - include/dds/core/xtypes/AnnotationKind.hpp | 47 - include/dds/core/xtypes/CollectionTypes.hpp | 142 - include/dds/core/xtypes/DynamicData.hpp | 118 - include/dds/core/xtypes/DynamicType.hpp | 171 - include/dds/core/xtypes/MemberType.hpp | 165 - include/dds/core/xtypes/PrimitiveTypes.hpp | 74 - include/dds/core/xtypes/StructType.hpp | 203 - include/dds/core/xtypes/TypeKind.hpp | 79 - include/dds/core/xtypes/TypeProvider.hpp | 77 - include/dds/core/xtypes/UnionCase.hpp | 69 - include/dds/core/xtypes/UnionType.hpp | 141 - include/dds/core/xtypes/detail/Annotation.hpp | 226 - .../core/xtypes/detail/CollectionTypes.hpp | 47 - .../dds/core/xtypes/detail/DynamicData.hpp | 35 - .../dds/core/xtypes/detail/DynamicType.hpp | 101 - include/dds/core/xtypes/detail/MemberType.hpp | 245 - .../dds/core/xtypes/detail/PrimitiveTypes.hpp | 131 - include/dds/core/xtypes/detail/StructType.hpp | 187 - .../dds/core/xtypes/detail/TypeProvider.hpp | 35 - include/dds/core/xtypes/detail/UnionCase.hpp | 36 - include/dds/core/xtypes/detail/UnionType.hpp | 36 - include/dds/domain/DomainParticipant.hpp | 505 - .../dds/domain/DomainParticipantListener.hpp | 236 - .../dds/domain/detail/DomainParticipant.hpp | 34 - .../dds/domain/qos/DomainParticipantQos.hpp | 36 - .../qos/detail/DomainParticipantQos.hpp | 35 - include/dds/pub/AnyDataWriter.hpp | 373 - include/dds/pub/DataWriter.hpp | 1611 - include/dds/pub/Publisher.hpp | 331 - include/dds/pub/PublisherListener.hpp | 157 - include/dds/pub/detail/AnyDataWriter.hpp | 41 - include/dds/pub/detail/DataWriter.hpp | 41 - include/dds/pub/detail/Publisher.hpp | 48 - include/dds/pub/qos/DataWriterQos.hpp | 35 - include/dds/pub/qos/PublisherQos.hpp | 35 - include/dds/pub/qos/detail/DataWriterQos.hpp | 35 - include/dds/pub/qos/detail/PublisherQos.hpp | 35 - include/dds/sub/DataReader.hpp | 217 - include/dds/sub/DataReaderListener.hpp | 107 - include/dds/sub/Subscriber.hpp | 268 - include/dds/sub/SubscriberListener.hpp | 154 - include/dds/sub/detail/DataReader.hpp | 40 - include/dds/sub/detail/Subscriber.hpp | 48 - include/dds/sub/qos/DataReaderQos.hpp | 32 - include/dds/sub/qos/SubscriberQos.hpp | 32 - include/dds/sub/qos/detail/DataReaderQos.hpp | 35 - include/dds/sub/qos/detail/SubscriberQos.hpp | 35 - include/dds/topic/Topic.hpp | 111 - include/dds/topic/TopicListener.hpp | 107 - include/dds/topic/detail/Topic.hpp | 40 - include/dds/topic/qos/TopicQos.hpp | 36 - include/dds/topic/qos/detail/TopicQos.hpp | 35 - include/fastdds/LibrarySettings.hpp | 66 + include/{fastrtps => fastdds}/config.h.in | 34 +- .../dds/builtin/common/ReplyHeader.hpp | 72 - .../dds/builtin/common/RequestHeader.hpp | 72 - include/fastdds/dds/builtin/common/Types.hpp | 57 - .../builtin/typelookup/TypeLookupManager.hpp | 302 - .../typelookup/TypeLookupReplyListener.hpp | 100 - .../typelookup/TypeLookupRequestListener.hpp | 101 - .../typelookup/common/TypeLookupTypes.hpp | 645 - include/fastdds/dds/common/InstanceHandle.hpp | 4 +- include/fastdds/dds/core/Entity.hpp | 20 +- .../dds/core/ReturnCode.hpp} | 16 +- .../fastdds/dds/core/Types.hpp | 26 +- .../fastdds/dds/core/condition/Condition.hpp | 4 +- .../dds/core/condition/GuardCondition.hpp | 14 +- .../dds/core/condition/StatusCondition.hpp | 14 +- .../fastdds/dds/core/condition/WaitSet.hpp | 18 +- .../fastdds/dds/core/detail/DDSReturnCode.hpp | 67 +- .../fastdds/dds/core/detail/DDSReturnCode.idl | 25 + .../dds/core/detail/DDSSecurityReturnCode.hpp | 50 +- .../dds/core/detail/DDSSecurityReturnCode.idl | 10 + .../dds/core/policy/ParameterTypes.hpp | 20 +- .../fastdds/dds/core/policy/QosPolicies.hpp | 291 +- .../policy/ReaderDataLifecycleQosPolicy.hpp | 2 +- .../policy/WriterDataLifecycleQosPolicy.hpp | 2 +- .../dds/core/status/IncompatibleQosStatus.hpp | 10 +- .../fastdds/dds/core/status/StatusMask.hpp | 4 +- .../fastdds/dds/domain/DomainParticipant.hpp | 217 +- .../dds/domain/DomainParticipantFactory.hpp | 120 +- .../dds/domain/DomainParticipantListener.hpp | 117 +- .../qos/DomainParticipantFactoryQos.hpp | 8 +- .../dds/domain/qos/DomainParticipantQos.hpp | 53 +- include/fastdds/dds/domain/qos/ReplierQos.hpp | 80 + .../fastdds/dds/domain/qos/RequesterQos.hpp | 80 + include/fastdds/dds/log/FileConsumer.hpp | 6 +- include/fastdds/dds/log/Log.hpp | 100 +- include/fastdds/dds/log/OStreamConsumer.hpp | 4 +- include/fastdds/dds/log/StdoutConsumer.hpp | 2 +- include/fastdds/dds/log/StdoutErrConsumer.hpp | 6 +- include/fastdds/dds/publisher/DataWriter.hpp | 140 +- .../dds/publisher/DataWriterListener.hpp | 8 +- include/fastdds/dds/publisher/Publisher.hpp | 64 +- .../dds/publisher/PublisherListener.hpp | 6 +- .../dds/publisher/qos/DataWriterQos.hpp | 154 +- .../dds/publisher/qos/PublisherQos.hpp | 7 +- .../fastdds/dds/publisher/qos/WriterQos.hpp | 14 +- include/fastdds/dds/subscriber/DataReader.hpp | 115 +- .../dds/subscriber/DataReaderListener.hpp | 40 +- .../fastdds/dds/subscriber/ReadCondition.hpp | 12 +- include/fastdds/dds/subscriber/SampleInfo.hpp | 28 - include/fastdds/dds/subscriber/Subscriber.hpp | 61 +- .../dds/subscriber/SubscriberListener.hpp | 12 +- .../dds/subscriber/qos/DataReaderQos.hpp | 150 +- .../fastdds/dds/subscriber/qos/ReaderQos.hpp | 12 +- .../dds/subscriber/qos/SubscriberQos.hpp | 7 +- .../dds/topic/ContentFilteredTopic.hpp | 17 +- include/fastdds/dds/topic/IContentFilter.hpp | 7 +- .../dds/topic/IContentFilterFactory.hpp | 7 +- include/fastdds/dds/topic/Topic.hpp | 17 +- include/fastdds/dds/topic/TopicDataType.hpp | 108 +- include/fastdds/dds/topic/TopicListener.hpp | 4 +- include/fastdds/dds/topic/TypeSupport.hpp | 76 +- include/fastdds/dds/topic/qos/TopicQos.hpp | 6 +- include/fastdds/dds/xtypes/common.hpp | 114 + .../dynamic_types/AnnotationDescriptor.hpp | 131 + .../dds/xtypes/dynamic_types/DynamicData.hpp | 1042 + .../dynamic_types/DynamicDataFactory.hpp | 78 + .../dynamic_types/DynamicPubSubType.hpp | 154 + .../dds/xtypes/dynamic_types/DynamicType.hpp | 191 + .../dynamic_types/DynamicTypeBuilder.hpp | 211 + .../DynamicTypeBuilderFactory.hpp | 213 + .../dynamic_types/DynamicTypeMember.hpp | 139 + .../xtypes/dynamic_types/MemberDescriptor.hpp | 331 + .../xtypes/dynamic_types/TypeDescriptor.hpp | 274 + .../dds/xtypes/dynamic_types/Types.hpp | 83 + .../dynamic_types/VerbatimTextDescriptor.hpp | 133 + .../detail/dynamic_language_binding.hpp | 170 + .../detail/dynamic_language_binding.idl | 89 + .../dynamic_types/detail/type_traits.hpp | 65 + .../dds/xtypes/dynamic_types/type_traits.hpp | 31 +- .../dds/xtypes/exception/Exception.hpp | 79 + .../ITypeObjectRegistry.hpp | 144 + .../xtypes/type_representation/TypeObject.hpp | 34 +- .../type_representation/TypeObjectUtils.hpp | 3056 ++ .../detail/dds-xtypes_typeobject.idl | 1077 + .../detail/dds_xtypes_typeobject.hpp | 24387 ++++++++++++++++ .../detail/dds_xtypes_typeobjectCdrAux.hpp | 808 + .../detail/dds_xtypes_typeobjectPubSubTypes.h | 9261 ++++++ .../fastdds_auto_link.hpp} | 37 +- include/fastdds/fastdds_dll.hpp | 69 + include/fastdds/rtps/Endpoint.h | 11 +- include/fastdds/rtps/RTPSDomain.h | 63 +- .../rtps/attributes/BuiltinTransports.hpp | 6 +- .../rtps/attributes/EndpointAttributes.h | 13 +- .../rtps/attributes/HistoryAttributes.h | 4 +- .../fastdds/rtps/attributes/PropertyPolicy.h | 32 +- .../RTPSParticipantAllocationAttributes.hpp | 2 +- .../attributes/RTPSParticipantAttributes.h | 57 +- .../rtps/attributes/ReaderAttributes.h | 8 +- .../rtps/attributes/ServerAttributes.h | 44 +- .../rtps/attributes/ThreadSettings.hpp | 4 +- .../fastdds/rtps/attributes/TopicAttributes.h | 156 + .../rtps/attributes/WriterAttributes.h | 18 +- .../builtin/data/ContentFilterProperty.hpp | 14 +- .../rtps/builtin/data/ParticipantProxyData.h | 50 +- .../rtps/builtin/data/ReaderProxyData.h | 142 +- .../rtps/builtin/data/WriterProxyData.h | 147 +- include/fastdds/rtps/common/CDRMessage_t.h | 2 +- include/fastdds/rtps/common/CacheChange.h | 2 +- .../fastdds/rtps/common/CdrSerialization.hpp | 4 +- include/fastdds/rtps/common/ChangeKind_t.hpp | 4 +- include/fastdds/rtps/common/EntityId_t.hpp | 4 +- include/fastdds/rtps/common/FragmentNumber.h | 26 +- include/fastdds/rtps/common/Guid.h | 4 +- include/fastdds/rtps/common/GuidPrefix_t.hpp | 4 +- include/fastdds/rtps/common/InstanceHandle.h | 6 +- include/fastdds/rtps/common/Locator.h | 21 +- include/fastdds/rtps/common/LocatorList.hpp | 81 +- .../rtps/common/LocatorListComparisons.hpp | 2 +- .../fastdds/rtps/common/LocatorSelector.hpp | 5 +- .../rtps/common/LocatorSelectorEntry.hpp | 3 +- .../fastdds/rtps/common/LocatorWithMask.hpp | 7 +- .../fastdds/rtps/common/LocatorsIterator.hpp | 8 + include/fastdds/rtps/common/MatchingInfo.h | 49 +- .../fastdds/rtps/common/RemoteLocators.hpp | 2 +- include/fastdds/rtps/common/SampleIdentity.h | 2 +- include/fastdds/rtps/common/SequenceNumber.h | 6 +- .../fastdds/rtps/common/SerializedPayload.h | 4 +- include/fastdds/rtps/common/Time_t.h | 6 +- include/fastdds/rtps/common/Token.h | 234 +- include/fastdds/rtps/common/Types.h | 6 +- include/fastdds/rtps/common/WriteParams.h | 2 +- include/fastdds/rtps/exceptions/Exception.h | 154 +- .../rtps/flowcontrol/FlowControllerConsts.hpp | 6 +- .../ThroughputControllerDescriptor.h | 6 +- include/fastdds/rtps/history/History.h | 92 +- include/fastdds/rtps/history/ReaderHistory.h | 34 +- include/fastdds/rtps/history/WriterHistory.h | 32 +- include/fastdds/rtps/messages/CDRMessage.h | 7 +- include/fastdds/rtps/messages/CDRMessage.hpp | 4 +- .../participant/ParticipantDiscoveryInfo.h | 6 +- .../rtps/participant/RTPSParticipant.h | 38 +- .../participant/RTPSParticipantListener.h | 63 +- include/fastdds/rtps/reader/RTPSReader.h | 58 +- .../fastdds/rtps/reader/ReaderDiscoveryInfo.h | 4 +- include/fastdds/rtps/reader/ReaderListener.h | 2 +- include/fastdds/rtps/reader/StatefulReader.h | 2 +- include/fastdds/rtps/reader/StatelessReader.h | 2 +- .../fastdds/rtps/resources/ResourceEvent.h | 4 +- include/fastdds/rtps/rtps_all.h | 47 - .../security/exceptions/SecurityException.h | 72 +- .../fastdds/rtps/security/logging/Logging.h | 28 +- .../rtps/transport/ChainingTransport.h | 60 +- .../transport/ChainingTransportDescriptor.h | 12 +- .../PortBasedTransportDescriptor.hpp | 24 +- .../fastdds/rtps/transport/SenderResource.h | 3 +- .../transport/SocketTransportDescriptor.h | 12 +- .../rtps/transport/TCPTransportDescriptor.h | 14 +- .../rtps/transport/TCPv4TransportDescriptor.h | 8 +- .../rtps/transport/TCPv6TransportDescriptor.h | 8 +- .../transport/TransportDescriptorInterface.h | 24 +- .../rtps/transport/TransportInterface.h | 5 +- .../transport/TransportReceiverInterface.h | 2 +- .../rtps/transport/UDPTransportDescriptor.h | 10 +- .../rtps/transport/UDPv4TransportDescriptor.h | 8 +- .../rtps/transport/UDPv6TransportDescriptor.h | 8 +- .../network/AllowedNetworkInterface.hpp | 12 +- .../network/BlockedNetworkInterface.hpp | 12 +- .../transport/network/NetmaskFilterKind.hpp | 4 +- .../transport/network/NetworkInterface.hpp | 18 +- .../network/NetworkInterfaceWithFilter.hpp | 20 +- .../shared_mem/SharedMemTransportDescriptor.h | 32 +- .../transport/test_UDPv4TransportDescriptor.h | 12 +- .../fastdds/rtps/writer/IReaderDataFilter.hpp | 22 - .../rtps/writer/LocatorSelectorSender.hpp | 4 +- include/fastdds/rtps/writer/RTPSWriter.h | 57 +- include/fastdds/rtps/writer/ReaderProxy.h | 2 +- include/fastdds/rtps/writer/StatefulWriter.h | 2 +- include/fastdds/rtps/writer/StatelessWriter.h | 2 +- .../fastdds/rtps/writer/WriterDiscoveryInfo.h | 10 +- include/fastdds/rtps/writer/WriterListener.h | 2 +- .../dds/domain/DomainParticipant.hpp | 32 +- .../dds/publisher/qos/DataWriterQos.hpp | 4 +- .../dds/subscriber/qos/DataReaderQos.hpp | 4 +- .../statistics/monitorservice_types.idl | 49 +- .../statistics/rtps/StatisticsCommon.hpp | 2 +- include/fastdds/statistics/types.idl | 73 +- .../{fastrtps => fastdds}/utils/IPFinder.h | 23 +- .../{fastrtps => fastdds}/utils/IPLocator.h | 92 +- .../utils/TimedConditionVariable.hpp | 3 +- .../utils/TimedMutex.hpp | 0 .../ResourceLimitedContainerConfig.hpp | 0 .../collections/ResourceLimitedVector.hpp | 0 .../utils/fixed_size_bitmap.hpp | 0 include/fastdds/utils/md5.h | 160 + include/fastrtps/Domain.h | 251 - include/fastrtps/attributes/TopicAttributes.h | 151 - include/fastrtps/attributes/all_attributes.h | 29 - include/fastrtps/config/doxygen_modules.h | 48 +- include/fastrtps/fastrtps_all.h | 54 - include/fastrtps/fastrtps_dll.h | 69 - include/fastrtps/participant/Participant.h | 104 - .../participant/ParticipantListener.h | 88 - include/fastrtps/publisher/Publisher.h | 192 - include/fastrtps/publisher/PublisherHistory.h | 206 - .../fastrtps/publisher/PublisherListener.h | 92 - include/fastrtps/qos/ParameterTypes.h | 5 +- include/fastrtps/qos/QosPolicies.h | 2 +- .../fastrtps/rtps/builtin/BuiltinProtocols.h | 25 - .../rtps/builtin/discovery/endpoint/EDP.h | 25 - .../builtin/discovery/endpoint/EDPSimple.h | 25 - .../builtin/discovery/endpoint/EDPStatic.h | 25 - .../rtps/builtin/discovery/participant/PDP.h | 25 - .../discovery/participant/PDPListener.h | 25 - .../builtin/discovery/participant/PDPSimple.h | 25 - .../fastrtps/rtps/builtin/liveliness/WLP.h | 25 - .../rtps/builtin/liveliness/WLPListener.h | 25 - include/fastrtps/rtps/rtps_all.h | 25 - include/fastrtps/rtps/writer/LivelinessData.h | 23 - .../fastrtps/rtps/writer/LivelinessManager.h | 23 - include/fastrtps/subscriber/SampleInfo.h | 73 - include/fastrtps/subscriber/Subscriber.h | 190 - .../fastrtps/subscriber/SubscriberHistory.h | 282 - .../fastrtps/subscriber/SubscriberListener.h | 101 - include/fastrtps/types/AnnotationDescriptor.h | 71 - .../fastrtps/types/AnnotationParameterValue.h | 1453 - .../types/BuiltinAnnotationsTypeObject.h | 183 - include/fastrtps/types/DynamicData.h | 788 - include/fastrtps/types/DynamicDataFactory.h | 68 - include/fastrtps/types/DynamicDataHelper.hpp | 127 - include/fastrtps/types/DynamicDataPtr.h | 63 - include/fastrtps/types/DynamicPubSubType.h | 106 - include/fastrtps/types/DynamicType.h | 180 - include/fastrtps/types/DynamicTypeBuilder.h | 167 - .../types/DynamicTypeBuilderFactory.h | 317 - .../fastrtps/types/DynamicTypeBuilderPtr.h | 67 - include/fastrtps/types/DynamicTypeMember.h | 102 - include/fastrtps/types/DynamicTypePtr.h | 76 - include/fastrtps/types/MemberDescriptor.h | 223 - include/fastrtps/types/TypeDescriptor.h | 163 - include/fastrtps/types/TypeIdentifier.h | 434 - include/fastrtps/types/TypeIdentifierTypes.h | 1920 -- include/fastrtps/types/TypeNamesGenerator.h | 50 - include/fastrtps/types/TypeObject.h | 8075 ----- include/fastrtps/types/TypeObjectFactory.h | 274 - include/fastrtps/types/TypeObjectHashId.h | 187 - include/fastrtps/types/TypesBase.h | 647 - include/fastrtps/types/dds-builtin_types.idl | 137 - .../fastrtps/types/dds-language_binding.idl | 267 - .../fastrtps/types/dds-xtypes_discovery.idl | 298 - .../fastrtps/types/dds-xtypes_typeobject.idl | 1077 - include/fastrtps/utils/Semaphore.h | 100 - include/fastrtps/utils/System.h | 44 - include/fastrtps/utils/TimeConversion.h | 160 - .../collections/foonathan_memory_helpers.hpp | 74 - include/fastrtps/utils/fixed_size_string.hpp | 255 - include/fastrtps/utils/md5.h | 101 - m4/ax_check_openssl.m4 | 124 - m4/ax_cxx_compile_stdcxx_0x.m4 | 109 - m4/ax_cxx_compile_stdcxx_11.m4 | 167 - package.xml | 6 +- .../images/fastdds_github_banner.png | Bin .../images/logo/eProsimaLogo.jpg | Bin .../images/logo/eProsimaLogo.png | Bin ...RTPS_profiles.xsd => fastdds_profiles.xsd} | 115 +- src/cpp/CMakeLists.txt | 350 +- src/cpp/dds/core/Exception.cpp | 77 - src/cpp/dds/core/types.cpp | 24 - src/cpp/dds/domain/DomainParticipant.cpp | 214 - src/cpp/dds/pub/AnyDataWriter.cpp | 137 - src/cpp/dds/pub/DataWriter.cpp | 410 - src/cpp/dds/pub/Publisher.cpp | 141 - src/cpp/dds/sub/DataReader.cpp | 111 - src/cpp/dds/sub/Subscriber.cpp | 135 - src/cpp/dds/topic/Topic.cpp | 69 - .../dynamic-types/AnnotationDescriptor.cpp | 166 - .../AnnotationParameterValue.cpp | 1634 -- .../AnnotationParameterValueCdrAux.ipp | 584 - .../BuiltinAnnotationsTypeObject.cpp | 4605 --- src/cpp/dynamic-types/DynamicData.cpp | 6936 ----- src/cpp/dynamic-types/DynamicDataFactory.cpp | 232 - src/cpp/dynamic-types/DynamicDataHelper.cpp | 891 - src/cpp/dynamic-types/DynamicPubSubType.cpp | 291 - src/cpp/dynamic-types/DynamicType.cpp | 524 - src/cpp/dynamic-types/DynamicTypeBuilder.cpp | 508 - .../DynamicTypeBuilderFactory.cpp | 2858 -- src/cpp/dynamic-types/DynamicTypeMember.cpp | 169 - src/cpp/dynamic-types/MemberDescriptor.cpp | 806 - src/cpp/dynamic-types/TypeDescriptor.cpp | 665 - src/cpp/dynamic-types/TypeIdentifier.cpp | 1337 - .../dynamic-types/TypeIdentifierCdrAux.ipp | 268 - src/cpp/dynamic-types/TypeIdentifierTypes.cpp | 1484 - .../TypeIdentifierTypesCdrAux.ipp | 908 - src/cpp/dynamic-types/TypeNamesGenerator.cpp | 104 - src/cpp/dynamic-types/TypeObject.cpp | 8935 ------ src/cpp/dynamic-types/TypeObjectCdrAux.ipp | 5012 ---- src/cpp/dynamic-types/TypeObjectFactory.cpp | 2322 -- src/cpp/dynamic-types/TypeObjectHashId.cpp | 227 - .../dynamic-types/TypeObjectHashIdCdrAux.ipp | 115 - src/cpp/dynamic-types/TypesBase.cpp | 105 - .../fastdds/builtin/common/RPCHeadersImpl.cpp | 76 - .../builtin/common/RPCHeadersImplCdrAux.ipp | 185 - .../type_lookup_service/TypeLookupManager.cpp | 845 + .../type_lookup_service/TypeLookupManager.hpp | 445 + .../TypeLookupReplyListener.cpp | 327 + .../TypeLookupReplyListener.hpp | 156 + .../TypeLookupRequestListener.cpp | 461 + .../TypeLookupRequestListener.hpp | 195 + .../detail/TypeLookupTypes.hpp | 2394 ++ .../detail/TypeLookupTypes.idl | 82 + .../detail/TypeLookupTypesCdrAux.hpp | 207 + .../detail/TypeLookupTypesCdrAux.ipp | 1088 + .../detail/TypeLookupTypesPubSubTypes.cxx | 1219 + .../detail/TypeLookupTypesPubSubTypes.h | 612 + .../type_lookup_service/detail/rpc_types.hpp | 1139 + .../type_lookup_service/detail/rpc_types.idl | 80 + .../detail/rpc_typesCdrAux.hpp | 86 + .../detail/rpc_typesCdrAux.ipp | 594 + .../detail/rpc_typesPubSubTypes.cxx | 944 +- .../detail/rpc_typesPubSubTypes.h | 426 +- .../builtin/typelookup/TypeLookupManager.cpp | 762 - .../typelookup/TypeLookupReplyListener.cpp | 129 - .../typelookup/TypeLookupRequestListener.cpp | 163 - .../typelookup/common/TypeLookupTypes.cpp | 1227 - .../common/TypeLookupTypesCdrAux.ipp | 733 - .../fastdds/core/condition/GuardCondition.cpp | 2 +- .../core/condition/StatusCondition.cpp | 5 +- .../core/condition/StatusConditionImpl.cpp | 2 +- .../core/condition/StatusConditionImpl.hpp | 4 +- src/cpp/fastdds/core/condition/WaitSet.cpp | 3 - .../fastdds/core/condition/WaitSetImpl.cpp | 16 +- .../fastdds/core/condition/WaitSetImpl.hpp | 4 +- src/cpp/fastdds/core/policy/ParameterList.cpp | 2 +- .../core/policy/ParameterSerializer.hpp | 18 +- .../core/policy/QosPoliciesSerializer.hpp | 32 +- src/cpp/fastdds/domain/DomainParticipant.cpp | 62 +- .../domain/DomainParticipantFactory.cpp | 137 +- .../fastdds/domain/DomainParticipantImpl.cpp | 813 +- .../fastdds/domain/DomainParticipantImpl.hpp | 140 +- src/cpp/fastdds/log/CMakeLists.txt | 39 + src/cpp/fastdds/log/Log.cpp | 44 +- src/cpp/fastdds/publisher/DataWriter.cpp | 56 +- .../fastdds/publisher/DataWriterHistory.hpp | 4 +- src/cpp/fastdds/publisher/DataWriterImpl.cpp | 275 +- src/cpp/fastdds/publisher/DataWriterImpl.hpp | 53 +- src/cpp/fastdds/publisher/Publisher.cpp | 20 +- src/cpp/fastdds/publisher/PublisherImpl.cpp | 96 +- src/cpp/fastdds/publisher/PublisherImpl.hpp | 25 +- .../filtering/DataWriterFilteredChange.hpp | 4 +- .../DataWriterFilteredChangePool.hpp | 2 +- .../filtering/ReaderFilterCollection.hpp | 4 +- .../filtering/ReaderFilterInformation.hpp | 6 +- .../fastdds/publisher/qos/PublisherQos.cpp | 2 +- src/cpp/fastdds/publisher/qos/WriterQos.cpp | 2 +- src/cpp/fastdds/subscriber/DataReader.cpp | 26 +- src/cpp/fastdds/subscriber/DataReaderImpl.cpp | 202 +- src/cpp/fastdds/subscriber/DataReaderImpl.hpp | 26 +- .../DataReaderImpl/DataReaderLoanManager.hpp | 15 +- .../DataReaderImpl/ReadTakeCommand.hpp | 12 +- .../DataReaderImpl/SampleInfoPool.hpp | 7 +- .../DataReaderImpl/SampleLoanManager.hpp | 6 +- .../fastdds/subscriber/ReadConditionImpl.hpp | 14 +- src/cpp/fastdds/subscriber/Subscriber.cpp | 18 +- src/cpp/fastdds/subscriber/SubscriberImpl.cpp | 82 +- src/cpp/fastdds/subscriber/SubscriberImpl.hpp | 16 +- .../subscriber/history/DataReaderHistory.hpp | 9 +- .../subscriber/history/DataReaderInstance.hpp | 2 +- .../fastdds/subscriber/qos/SubscriberQos.cpp | 2 +- .../fastdds/topic/ContentFilteredTopic.cpp | 2 +- .../topic/ContentFilteredTopicImpl.cpp | 9 +- .../topic/ContentFilteredTopicImpl.hpp | 1 + .../DDSSQLFilter/DDSFilterExpression.cpp | 33 +- .../DDSSQLFilter/DDSFilterExpression.hpp | 26 +- .../DDSFilterExpressionParser.cpp | 16 +- .../DDSFilterExpressionParser.hpp | 4 +- .../identifiers.hpp | 111 +- .../topic/DDSSQLFilter/DDSFilterFactory.cpp | 175 +- .../topic/DDSSQLFilter/DDSFilterField.cpp | 203 +- .../topic/DDSSQLFilter/DDSFilterField.hpp | 20 +- .../topic/DDSSQLFilter/DDSFilterParseNode.hpp | 4 +- .../topic/DDSSQLFilter/DDSFilterValue.cpp | 8 +- .../topic/DDSSQLFilter/DDSFilterValue.hpp | 6 +- src/cpp/fastdds/topic/Topic.cpp | 6 +- src/cpp/fastdds/topic/TopicDataType.cpp | 9 +- src/cpp/fastdds/topic/TopicImpl.cpp | 26 +- src/cpp/fastdds/topic/TopicImpl.hpp | 4 +- src/cpp/fastdds/topic/TopicProxy.hpp | 5 +- src/cpp/fastdds/topic/TopicProxyFactory.cpp | 4 +- src/cpp/fastdds/topic/TopicProxyFactory.hpp | 4 +- src/cpp/fastdds/utils/QosConverters.cpp | 28 + src/cpp/fastdds/utils/QosConverters.hpp | 35 +- src/cpp/fastdds/xtypes/CMakeLists.txt | 114 + .../AnnotationDescriptorImpl.cpp | 141 + .../AnnotationDescriptorImpl.hpp | 90 + .../dynamic_types/DynamicDataFactory.cpp} | 30 +- .../dynamic_types/DynamicDataFactoryImpl.cpp | 60 + .../dynamic_types/DynamicDataFactoryImpl.hpp | 49 + .../xtypes/dynamic_types/DynamicDataImpl.cpp | 7083 +++++ .../xtypes/dynamic_types/DynamicDataImpl.hpp | 768 + .../dynamic_types/DynamicPubSubType.cpp | 267 + .../DynamicTypeBuilderFactory.cpp} | 30 +- .../DynamicTypeBuilderFactoryImpl.cpp | 1574 + .../DynamicTypeBuilderFactoryImpl.hpp | 206 + .../dynamic_types/DynamicTypeBuilderImpl.cpp | 692 + .../dynamic_types/DynamicTypeBuilderImpl.hpp | 157 + .../xtypes/dynamic_types/DynamicTypeImpl.cpp | 240 + .../xtypes/dynamic_types/DynamicTypeImpl.hpp | 147 + .../dynamic_types/DynamicTypeMemberImpl.cpp | 136 + .../dynamic_types/DynamicTypeMemberImpl.hpp | 90 + .../dynamic_types/MemberDescriptorImpl.cpp | 228 + .../dynamic_types/MemberDescriptorImpl.hpp | 327 + .../dynamic_types/TypeDescriptorImpl.cpp | 326 + .../dynamic_types/TypeDescriptorImpl.hpp | 243 + .../xtypes/dynamic_types/TypeForKind.hpp | 399 + .../dynamic_types/TypeValueConverter.hpp | 255 + .../VerbatimTextDescriptorImpl.cpp | 68 + .../VerbatimTextDescriptorImpl.hpp | 105 + .../fastdds/xtypes/dynamic_types/common.hpp | 62 + .../fastdds/xtypes/exception/Exception.cpp | 51 + ...TypeIdentifierWithSizeHashSpecialization.h | 43 + .../TypeObjectRegistry.cpp | 1165 + .../TypeObjectRegistry.hpp | 771 + .../type_representation/TypeObjectUtils.cpp | 3569 +++ .../dds_xtypes_typeobjectCdrAux.ipp | 10712 +++++++ .../dds_xtypes_typeobjectPubSubTypes.cxx | 18712 ++++++++++++ src/cpp/fastrtps.rc | 18 +- src/cpp/fastrtps_deprecated/Domain.cpp | 449 - .../participant/Participant.cpp | 68 - .../participant/ParticipantImpl.cpp | 555 - .../participant/ParticipantImpl.h | 250 - .../publisher/Publisher.cpp | 129 - .../publisher/PublisherHistory.cpp | 520 - .../publisher/PublisherImpl.cpp | 637 - .../publisher/PublisherImpl.h | 296 - .../subscriber/Subscriber.cpp | 97 - .../subscriber/SubscriberHistory.cpp | 835 - .../subscriber/SubscriberImpl.cpp | 494 - .../subscriber/SubscriberImpl.h | 272 - src/cpp/libfastdds.version | 4 + src/cpp/libfastrtps.version | 4 - .../rtps/DataSharing/DataSharingListener.hpp | 2 +- .../rtps/DataSharing/IDataSharingListener.hpp | 2 +- src/cpp/rtps/RTPSDomain.cpp | 94 +- src/cpp/rtps/RTPSDomainImpl.hpp | 57 +- .../attributes/RTPSParticipantAttributes.cpp | 7 +- .../attributes/TopicAttributes.cpp | 2 +- src/cpp/rtps/builtin/BuiltinProtocols.cpp | 50 +- .../cpp}/rtps/builtin/BuiltinProtocols.h | 5 +- .../builtin/data/ParticipantProxyData.cpp | 15 +- src/cpp/rtps/builtin/data/ReaderProxyData.cpp | 61 +- src/cpp/rtps/builtin/data/WriterProxyData.cpp | 50 +- .../discovery/database/DiscoveryDataBase.hpp | 17 +- .../database/DiscoveryDataQueueInfo.hpp | 7 +- .../database/DiscoveryEndpointInfo.hpp | 7 +- .../rtps/builtin/discovery/endpoint/EDP.cpp | 400 +- .../rtps/builtin/discovery/endpoint/EDP.h | 50 +- .../builtin/discovery/endpoint/EDPClient.cpp | 20 +- .../builtin/discovery/endpoint/EDPClient.h | 2 +- .../builtin/discovery/endpoint/EDPServer.cpp | 7 +- .../builtin/discovery/endpoint/EDPServer.hpp | 7 +- .../discovery/endpoint/EDPServerListeners.cpp | 147 +- .../discovery/endpoint/EDPServerListeners.hpp | 24 + .../builtin/discovery/endpoint/EDPSimple.cpp | 37 +- .../builtin/discovery/endpoint/EDPSimple.h | 5 +- .../discovery/endpoint/EDPSimpleListeners.cpp | 175 +- .../discovery/endpoint/EDPSimpleListeners.h | 15 +- .../builtin/discovery/endpoint/EDPStatic.cpp | 27 +- .../builtin/discovery/endpoint/EDPStatic.h | 6 +- .../DS/PDPSecurityInitiatorListener.cpp | 15 +- .../DS/PDPSecurityInitiatorListener.hpp | 5 +- .../participant/DirectMessageSender.cpp | 4 +- .../participant/DirectMessageSender.hpp | 8 +- .../builtin/discovery/participant/PDP.cpp | 163 +- .../rtps/builtin/discovery/participant/PDP.h | 43 +- .../discovery/participant/PDPClient.cpp | 16 +- .../builtin/discovery/participant/PDPClient.h | 5 +- .../discovery/participant/PDPListener.cpp | 16 +- .../discovery/participant/PDPListener.h | 0 .../discovery/participant/PDPServer.cpp | 33 +- .../discovery/participant/PDPServer.hpp | 5 +- .../participant/PDPServerListener.cpp | 11 +- .../participant/PDPServerListener.hpp | 2 +- .../discovery/participant/PDPSimple.cpp | 24 +- .../builtin/discovery/participant/PDPSimple.h | 2 +- .../participant/timedevent/DSClientEvent.cpp | 8 +- src/cpp/rtps/builtin/liveliness/WLP.cpp | 48 +- .../cpp}/rtps/builtin/liveliness/WLP.h | 17 +- .../rtps/builtin/liveliness/WLPListener.cpp | 13 +- .../rtps/builtin/liveliness/WLPListener.h | 2 +- .../rtps/flowcontrol/FlowControllerImpl.hpp | 4 +- src/cpp/rtps/history/History.cpp | 2 +- .../history/HistoryAttributesExtension.hpp | 20 +- src/cpp/rtps/history/ReaderHistory.cpp | 2 +- src/cpp/rtps/messages/MessageReceiver.cpp | 6 +- .../cpp}/rtps/messages/MessageReceiver.h | 3 +- src/cpp/rtps/messages/RTPSGapBuilder.hpp | 6 +- src/cpp/rtps/messages/RTPSMessageGroup_t.hpp | 22 +- src/cpp/rtps/messages/SendBuffersManager.hpp | 4 +- src/cpp/rtps/messages/submessages/DataMsg.hpp | 24 +- src/cpp/rtps/network/NetworkFactory.cpp | 4 +- src/cpp/rtps/network/NetworkFactory.h | 4 +- src/cpp/rtps/network/ReceiverResource.cpp | 3 +- src/cpp/rtps/network/ReceiverResource.h | 3 +- .../rtps/network/utils/external_locators.cpp | 2 +- src/cpp/rtps/participant/RTPSParticipant.cpp | 13 +- .../rtps/participant/RTPSParticipantImpl.cpp | 50 +- .../rtps/participant/RTPSParticipantImpl.h | 18 +- .../persistence/SQLite3PersistenceService.cpp | 1 - src/cpp/rtps/reader/ReaderHistoryState.hpp | 6 +- .../rtps/reader/StatefulPersistentReader.cpp | 3 +- src/cpp/rtps/reader/StatefulReader.cpp | 17 +- .../rtps/reader/StatelessPersistentReader.cpp | 3 +- src/cpp/rtps/reader/StatelessReader.cpp | 18 +- src/cpp/rtps/reader/WriterProxy.cpp | 12 +- src/cpp/rtps/reader/WriterProxy.h | 12 +- src/cpp/rtps/resources/TimedEventImpl.cpp | 4 +- src/cpp/rtps/security/SecurityManager.cpp | 22 +- src/cpp/rtps/security/SecurityManager.h | 10 +- src/cpp/rtps/transport/ChannelResource.cpp | 2 +- src/cpp/rtps/transport/TCPAcceptor.cpp | 4 +- src/cpp/rtps/transport/TCPAcceptorBasic.cpp | 4 +- src/cpp/rtps/transport/TCPAcceptorSecure.cpp | 4 +- src/cpp/rtps/transport/TCPChannelResource.cpp | 4 +- .../transport/TCPChannelResourceBasic.cpp | 4 +- .../transport/TCPChannelResourceSecure.cpp | 4 +- src/cpp/rtps/transport/TCPSenderResource.hpp | 2 +- .../rtps/transport/TCPTransportInterface.cpp | 11 +- .../rtps/transport/TCPTransportInterface.h | 2 +- src/cpp/rtps/transport/TCPv4Transport.cpp | 5 +- src/cpp/rtps/transport/TCPv4Transport.h | 4 +- src/cpp/rtps/transport/TCPv6Transport.cpp | 6 +- src/cpp/rtps/transport/TCPv6Transport.h | 4 +- src/cpp/rtps/transport/UDPChannelResource.cpp | 4 +- src/cpp/rtps/transport/UDPSenderResource.hpp | 2 +- .../rtps/transport/UDPTransportInterface.cpp | 4 +- .../rtps/transport/UDPTransportInterface.h | 2 +- src/cpp/rtps/transport/UDPv4Transport.cpp | 6 +- src/cpp/rtps/transport/UDPv4Transport.h | 2 +- src/cpp/rtps/transport/UDPv6Transport.cpp | 7 +- src/cpp/rtps/transport/UDPv6Transport.h | 2 +- .../shared_mem/SharedMemChannelResource.hpp | 5 +- .../transport/shared_mem/SharedMemLog.hpp | 4 +- .../shared_mem/SharedMemTransport.cpp | 6 +- .../transport/shared_mem/SharedMemTransport.h | 2 +- .../shared_mem/test_SharedMemTransport.h | 2 +- .../test_SharedMemTransportDescriptor.h | 8 +- .../rtps/transport/tcp/RTCPMessageManager.cpp | 5 +- .../rtps/transport/test_UDPv4Transport.cpp | 4 +- src/cpp/rtps/transport/test_UDPv4Transport.h | 12 +- .../cpp/rtps/writer/LivelinessData.hpp | 29 +- src/cpp/rtps/writer/LivelinessManager.cpp | 39 +- .../cpp/rtps/writer/LivelinessManager.hpp | 23 +- src/cpp/rtps/writer/PersistentWriter.cpp | 5 +- src/cpp/rtps/writer/ReaderLocator.cpp | 1 + src/cpp/rtps/writer/ReaderProxy.cpp | 4 +- .../rtps/writer/StatefulPersistentWriter.cpp | 3 +- src/cpp/rtps/writer/StatefulWriter.cpp | 24 +- .../rtps/writer/StatelessPersistentWriter.cpp | 3 +- src/cpp/rtps/writer/StatelessWriter.cpp | 27 +- .../accesscontrol/DistinguishedName.cpp | 2 +- .../security/accesscontrol/Permissions.cpp | 34 +- .../artifact_providers/Pkcs11Provider.cpp | 2 +- .../fastdds/domain/DomainParticipant.cpp | 34 +- .../fastdds/domain/DomainParticipantImpl.cpp | 158 +- .../fastdds/domain/DomainParticipantImpl.hpp | 28 +- .../DomainParticipantStatisticsListener.cpp | 39 +- .../DomainParticipantStatisticsListener.hpp | 8 +- .../fastdds/publisher/DataWriterImpl.hpp | 11 +- .../fastdds/subscriber/DataReaderImpl.hpp | 8 +- src/cpp/statistics/rtps/GuidUtils.hpp | 6 +- src/cpp/statistics/rtps/StatisticsBase.cpp | 44 +- src/cpp/statistics/rtps/StatisticsBase.hpp | 20 +- .../rtps/messages/OutputTrafficManager.hpp | 3 +- .../rtps/monitor-service/Interfaces.hpp | 3 +- .../rtps/monitor-service/MonitorService.cpp | 49 +- .../rtps/monitor-service/MonitorService.hpp | 10 +- .../MonitorServiceListener.cpp | 4 +- .../interfaces/IConnectionsQueryable.hpp | 1 - .../interfaces/IProxyQueryable.hpp | 0 .../interfaces/IStatusQueryable.hpp | 2 +- .../rtps/reader/StatisticsReaderImpl.cpp | 16 +- .../rtps/writer/StatisticsWriterImpl.cpp | 20 +- .../statistics/types/monitorservice_types.cxx | 2056 -- .../statistics/types/monitorservice_types.h | 1370 - .../statistics/types/monitorservice_types.hpp | 2506 ++ .../types/monitorservice_typesCdrAux.hpp | 38 +- .../types/monitorservice_typesCdrAux.ipp | 238 +- .../types/monitorservice_typesPubSubTypes.cxx | 62 +- .../types/monitorservice_typesPubSubTypes.h | 54 +- .../monitorservice_typesTypeObjectSupport.cxx | 12397 ++++++++ .../monitorservice_typesTypeObjectSupport.hpp | 127 + .../types/monitorservice_typesv1.cxx | 3011 -- .../statistics/types/monitorservice_typesv1.h | 1763 -- src/cpp/statistics/types/types.cxx | 3211 -- src/cpp/statistics/types/types.h | 2331 -- src/cpp/statistics/types/types.hpp | 3930 +++ src/cpp/statistics/types/typesCdrAux.hpp | 38 +- src/cpp/statistics/types/typesCdrAux.ipp | 288 +- src/cpp/statistics/types/typesPubSubTypes.cxx | 92 +- src/cpp/statistics/types/typesPubSubTypes.h | 89 +- .../types/typesTypeObjectSupport.cxx | 19540 +++++++++++++ .../types/typesTypeObjectSupport.hpp | 181 + src/cpp/statistics/types/typesv1.cxx | 4757 --- src/cpp/statistics/types/typesv1.h | 3093 -- .../DBQueue.h => src/cpp/utils/DBQueue.hpp | 14 +- src/cpp/utils/Host.hpp | 8 +- src/cpp/utils/IPFinder.cpp | 4 +- src/cpp/utils/IPLocator.cpp | 4 +- .../fastrtps => src/cpp}/utils/ProxyPool.hpp | 6 +- src/cpp/utils/Semaphore.hpp | 122 + src/cpp/utils/StringMatching.cpp | 6 +- .../cpp/utils/StringMatching.hpp | 20 +- src/cpp/utils/SystemInfo.cpp | 39 +- src/cpp/utils/SystemInfo.hpp | 7 +- src/cpp/utils/TimeConversion.hpp | 184 + src/cpp/utils/TimedConditionVariable.cpp | 52 +- src/cpp/utils/collections/FixedSizeQueue.hpp | 6 +- src/cpp/utils/collections/ObjectPool.hpp | 6 +- src/cpp/utils/collections/concurrent_queue.h | 11 +- .../utils/collections/unordered_vector.hpp | 2 +- src/cpp/utils/md5.cpp | 2 +- .../cpp}/utils/shared_mutex.hpp | 2 +- .../{rtps => }/xmlparser/XMLDynamicParser.cpp | 1040 +- .../{rtps => }/xmlparser/XMLElementParser.cpp | 84 +- .../xmlparser/XMLEndpointParser.cpp | 12 +- .../cpp}/xmlparser/XMLEndpointParser.h | 5 +- src/cpp/{rtps => }/xmlparser/XMLParser.cpp | 130 +- .../cpp}/xmlparser/XMLParser.h | 318 +- .../{rtps => }/xmlparser/XMLParserCommon.cpp | 58 +- .../cpp}/xmlparser/XMLParserCommon.h | 56 +- .../{rtps => }/xmlparser/XMLParserUtils.hpp | 0 .../xmlparser/XMLProfileManager.cpp | 62 +- .../cpp}/xmlparser/XMLProfileManager.h | 123 +- .../fastrtps => src/cpp}/xmlparser/XMLTree.h | 0 .../attributes/ParticipantAttributes.hpp | 12 +- .../attributes/PublisherAttributes.hpp | 38 +- .../attributes/ReplierAttributes.hpp | 18 +- .../attributes/RequesterAttributes.hpp | 18 +- .../attributes/SubscriberAttributes.hpp | 31 +- test/CMakeLists.txt | 3 +- test/blackbox/CMakeLists.txt | 128 +- .../MonitorServiceConnectionList_profile.xml | 2 +- ...onitorServiceDomainParticipant_profile.xml | 2 +- .../StatisticsDomainParticipant_profile.xml | 2 +- .../api/dds-pim/PubSubParticipant.hpp | 12 +- test/blackbox/api/dds-pim/PubSubReader.hpp | 81 +- test/blackbox/api/dds-pim/PubSubWriter.hpp | 64 +- .../api/dds-pim/PubSubWriterReader.hpp | 48 +- .../ReqRepAsReliableHelloWorldReplier.hpp | 4 +- .../ReqRepAsReliableHelloWorldRequester.hpp | 8 +- .../api/dds-pim/ReqRepHelloWorldReplier.cpp | 4 +- .../api/dds-pim/ReqRepHelloWorldRequester.cpp | 4 +- .../dds-pim/TCPReqRepHelloWorldReplier.cpp | 18 +- .../dds-pim/TCPReqRepHelloWorldRequester.cpp | 20 +- .../fastrtps_deprecated/PubSubParticipant.hpp | 678 - .../api/fastrtps_deprecated/PubSubReader.hpp | 1584 - .../api/fastrtps_deprecated/PubSubWriter.hpp | 1640 -- .../PubSubWriterReader.hpp | 869 - .../ReqRepAsReliableHelloWorldReplier.hpp | 57 - .../ReqRepAsReliableHelloWorldRequester.hpp | 71 - .../ReqRepHelloWorldReplier.cpp | 138 - .../ReqRepHelloWorldReplier.hpp | 154 - .../ReqRepHelloWorldRequester.cpp | 202 - .../ReqRepHelloWorldRequester.hpp | 188 - .../blackbox/auth_handshake_props_profile.xml | 2 +- test/blackbox/builtin_transports_profile.xml | 2 +- test/blackbox/common/BlackboxTests.cpp | 21 +- .../common/BlackboxTestsDeadlineQos.cpp | 17 +- .../common/BlackboxTestsDiscovery.cpp | 85 +- test/blackbox/common/BlackboxTestsKeys.cpp | 10 +- .../common/BlackboxTestsLifespanQoS.cpp | 34 +- .../common/BlackboxTestsLivelinessQos.cpp | 38 +- .../common/BlackboxTestsNetworkConf.cpp | 43 +- .../common/BlackboxTestsPubSubBasic.cpp | 73 +- .../BlackboxTestsPubSubFlowControllers.cpp | 24 +- .../common/BlackboxTestsPubSubFragments.cpp | 77 +- .../common/BlackboxTestsPubSubHistory.cpp | 162 +- .../BlackboxTestsRealtimeAllocations.cpp | 56 +- .../common/BlackboxTestsReliability.cpp | 12 +- .../blackbox/common/BlackboxTestsSecurity.cpp | 163 +- .../common/BlackboxTestsTransportCustom.cpp | 12 +- .../common/BlackboxTestsTransportSHM.cpp | 52 +- .../common/BlackboxTestsTransportTCP.cpp | 80 +- .../common/BlackboxTestsTransportUDP.cpp | 8 +- .../blackbox/common/BlackboxTestsVolatile.cpp | 160 +- .../common/DDSBlackboxTestsAckPositive.cpp | 44 +- .../blackbox/common/DDSBlackboxTestsBasic.cpp | 35 +- .../common/DDSBlackboxTestsContentFilter.cpp | 49 +- .../common/DDSBlackboxTestsDataReader.cpp | 41 +- .../DDSBlackboxTestsDataRepresentationQos.cpp | 10 +- .../common/DDSBlackboxTestsDataSharing.cpp | 54 +- .../common/DDSBlackboxTestsDataWriter.cpp | 70 +- .../common/DDSBlackboxTestsDiscovery.cpp | 144 +- .../common/DDSBlackboxTestsFindTopic.cpp | 25 +- .../common/DDSBlackboxTestsListeners.cpp | 16 +- .../common/DDSBlackboxTestsMonitorService.cpp | 206 +- .../common/DDSBlackboxTestsOwnershipQos.cpp | 28 +- .../common/DDSBlackboxTestsPersistence.cpp | 66 +- .../DDSBlackboxTestsPersistenceGuid.cpp | 25 +- .../common/DDSBlackboxTestsPropertyQos.cpp | 22 +- .../common/DDSBlackboxTestsSecurity.cpp | 49 +- .../common/DDSBlackboxTestsStatistics.cpp | 26 +- ...ackboxTestsStatisticsDomainParticipant.cpp | 35 +- .../DDSBlackboxTestsThreadSettingsQos.cpp | 2 - .../DDSBlackboxTestsTransportSHMUDP.cpp | 45 +- .../common/DDSBlackboxTestsUserDataQos.cpp | 22 +- test/blackbox/common/RTPSAsSocketReader.hpp | 44 +- test/blackbox/common/RTPSAsSocketWriter.hpp | 35 +- test/blackbox/common/RTPSBlackboxTests.cpp | 28 +- .../common/RTPSBlackboxTestsBasic.cpp | 39 +- .../common/RTPSBlackboxTestsDiscovery.cpp | 16 +- .../common/RTPSBlackboxTestsPersistence.cpp | 22 +- .../RTPSBlackboxTestsPersistenceGuid.cpp | 28 +- .../common/RTPSBlackboxTestsPools.cpp | 26 +- .../common/RTPSBlackboxTestsVolatile.cpp | 19 +- .../common/RTPSWithRegistrationReader.hpp | 43 +- .../common/RTPSWithRegistrationWriter.hpp | 8 +- test/blackbox/common/UDPMessageSender.hpp | 2 +- .../discovery_participant_flags_profile.xml | 2 +- test/blackbox/partitions_profile.xml | 2 +- test/blackbox/types/Data1mb.cxx | 136 - .../blackbox/types/{Data1mb.h => Data1mb.hpp} | 104 +- test/blackbox/types/Data1mbCdrAux.hpp | 6 +- test/blackbox/types/Data1mbCdrAux.ipp | 4 - test/blackbox/types/Data1mbPubSubTypes.cxx | 16 +- test/blackbox/types/Data1mbPubSubTypes.h | 11 +- .../types/Data1mbTypeObjectSupport.cxx | 238 + .../types/Data1mbTypeObjectSupport.hpp | 54 + test/blackbox/types/Data1mbv1.cxx | 243 - test/blackbox/types/Data1mbv1.h | 225 - test/blackbox/types/Data64kb.cxx | 136 - .../types/{Data64kb.h => Data64kb.hpp} | 104 +- test/blackbox/types/Data64kbCdrAux.hpp | 6 +- test/blackbox/types/Data64kbCdrAux.ipp | 4 - test/blackbox/types/Data64kbPubSubTypes.cxx | 16 +- test/blackbox/types/Data64kbPubSubTypes.h | 11 +- .../types/Data64kbTypeObjectSupport.cxx | 238 + .../types/Data64kbTypeObjectSupport.hpp | 54 + test/blackbox/types/Data64kbv1.cxx | 243 - test/blackbox/types/Data64kbv1.h | 225 - test/blackbox/types/FixedSized.cxx | 124 - .../types/{FixedSized.h => FixedSized.hpp} | 99 +- test/blackbox/types/FixedSizedCdrAux.hpp | 4 +- test/blackbox/types/FixedSizedCdrAux.ipp | 2 - test/blackbox/types/FixedSizedPubSubTypes.cxx | 14 +- test/blackbox/types/FixedSizedPubSubTypes.h | 9 +- .../types/FixedSizedTypeObjectSupport.cxx | 154 + .../types/FixedSizedTypeObjectSupport.hpp | 54 + test/blackbox/types/FixedSizedv1.cxx | 223 - test/blackbox/types/FixedSizedv1.h | 216 - test/blackbox/types/HelloWorld.cxx | 172 - .../types/{HelloWorld.h => HelloWorld.hpp} | 124 +- test/blackbox/types/HelloWorldCdrAux.hpp | 4 +- test/blackbox/types/HelloWorldCdrAux.ipp | 2 - test/blackbox/types/HelloWorldPubSubTypes.cxx | 14 +- test/blackbox/types/HelloWorldPubSubTypes.h | 9 +- test/blackbox/types/HelloWorldTypeObject.cxx | 271 - .../types/HelloWorldTypeObjectSupport.cxx | 255 + .../types/HelloWorldTypeObjectSupport.hpp | 54 + test/blackbox/types/HelloWorldv1.cxx | 294 - test/blackbox/types/HelloWorldv1.h | 244 - test/blackbox/types/KeyedData1mb.cxx | 170 - .../{KeyedData1mb.h => KeyedData1mb.hpp} | 126 +- test/blackbox/types/KeyedData1mbCdrAux.hpp | 6 +- test/blackbox/types/KeyedData1mbCdrAux.ipp | 4 - .../types/KeyedData1mbPubSubTypes.cxx | 16 +- test/blackbox/types/KeyedData1mbPubSubTypes.h | 11 +- .../types/KeyedData1mbTypeObjectSupport.cxx | 315 + .../types/KeyedData1mbTypeObjectSupport.hpp | 54 + test/blackbox/types/KeyedData1mbv1.cxx | 300 - test/blackbox/types/KeyedData1mbv1.h | 246 - test/blackbox/types/KeyedHelloWorld.cxx | 202 - ...{KeyedHelloWorld.h => KeyedHelloWorld.hpp} | 146 +- test/blackbox/types/KeyedHelloWorldCdrAux.hpp | 4 +- test/blackbox/types/KeyedHelloWorldCdrAux.ipp | 2 - .../types/KeyedHelloWorldPubSubTypes.cxx | 14 +- .../types/KeyedHelloWorldPubSubTypes.h | 9 +- .../KeyedHelloWorldTypeObjectSupport.cxx | 325 + .../KeyedHelloWorldTypeObjectSupport.hpp | 54 + test/blackbox/types/KeyedHelloWorldv1.cxx | 348 - test/blackbox/types/KeyedHelloWorldv1.h | 265 - test/blackbox/types/StringTest.cxx | 134 - .../types/{StringTest.h => StringTest.hpp} | 102 +- test/blackbox/types/StringTestCdrAux.hpp | 4 +- test/blackbox/types/StringTestCdrAux.ipp | 2 - test/blackbox/types/StringTestPubSubTypes.cxx | 14 +- test/blackbox/types/StringTestPubSubTypes.h | 9 +- .../types/StringTestTypeObjectSupport.cxx | 184 + .../types/StringTestTypeObjectSupport.hpp | 54 + test/blackbox/types/StringTestv1.cxx | 237 - test/blackbox/types/StringTestv1.h | 223 - ...3361v1.h => TestIncludeRegression3361.hpp} | 34 +- .../TestIncludeRegression3361PubSubTypes.h | 6 +- .../TestIncludeRegression3361TypeObject.cxx | 255 - ...IncludeRegression3361TypeObjectSupport.cxx | 51 + ...ncludeRegression3361TypeObjectSupport.hpp} | 46 +- .../types/TestIncludeRegression3361v1.cxx | 95 - test/blackbox/types/TestRegression3361.cxx | 138 - ...egression3361.h => TestRegression3361.hpp} | 106 +- .../types/TestRegression3361CdrAux.hpp | 4 +- .../types/TestRegression3361CdrAux.ipp | 2 - .../types/TestRegression3361PubSubTypes.cxx | 14 +- .../types/TestRegression3361PubSubTypes.h | 9 +- .../types/TestRegression3361TypeObject.cxx | 235 - .../types/TestRegression3361TypeObject.h | 66 - .../TestRegression3361TypeObjectSupport.cxx | 261 + .../TestRegression3361TypeObjectSupport.hpp | 55 + test/blackbox/types/TestRegression3361v1.cxx | 238 - test/blackbox/types/TestRegression3361v1.h | 224 - test/blackbox/types/UnboundedHelloWorld.cxx | 168 - ...edHelloWorld.h => UnboundedHelloWorld.hpp} | 124 +- .../types/UnboundedHelloWorldCdrAux.hpp | 4 +- .../types/UnboundedHelloWorldCdrAux.ipp | 2 - .../types/UnboundedHelloWorldPubSubTypes.cxx | 14 +- .../types/UnboundedHelloWorldPubSubTypes.h | 9 +- .../UnboundedHelloWorldTypeObjectSupport.cxx | 248 + .../UnboundedHelloWorldTypeObjectSupport.hpp | 54 + test/blackbox/types/UnboundedHelloWorldv1.cxx | 286 - test/blackbox/types/UnboundedHelloWorldv1.h | 244 - .../types/statistics/monitorservice_types.hpp | 2506 ++ .../statistics/monitorservice_typesCdrAux.hpp | 115 + .../statistics/monitorservice_typesCdrAux.ipp | 1011 + .../monitorservice_typesPubSubTypes.cxx | 1404 + .../monitorservice_typesPubSubTypes.h | 707 + .../monitorservice_typesTypeObjectSupport.cxx | 12397 ++++++++ .../monitorservice_typesTypeObjectSupport.hpp | 127 + test/blackbox/types/statistics/types.cxx | 3211 -- test/blackbox/types/statistics/types.h | 2331 -- test/blackbox/types/statistics/types.hpp | 3930 +++ .../blackbox/types/statistics/typesCdrAux.hpp | 38 +- .../blackbox/types/statistics/typesCdrAux.ipp | 288 +- .../types/statistics/typesPubSubTypes.cxx | 92 +- .../types/statistics/typesPubSubTypes.h | 89 +- .../statistics/typesTypeObjectSupport.cxx | 19540 +++++++++++++ .../statistics/typesTypeObjectSupport.hpp | 181 + test/blackbox/types/statistics/typesv1.cxx | 4757 --- test/blackbox/types/statistics/typesv1.h | 3093 -- test/dds/communication/CMakeLists.txt | 95 +- test/dds/communication/PubSubMain.cpp | 7 +- test/dds/communication/PublisherDynamic.cpp | 48 +- test/dds/communication/PublisherMain.cpp | 4 +- test/dds/communication/PublisherModule.cpp | 5 +- test/dds/communication/PublisherModule.hpp | 3 +- test/dds/communication/SubscriberDynamic.cpp | 118 +- test/dds/communication/SubscriberMain.cpp | 4 +- test/dds/communication/SubscriberModule.cpp | 9 +- test/dds/communication/SubscriberModule.hpp | 3 +- test/dds/communication/TCP_client_profile.xml | 2 +- test/dds/communication/TCP_server_profile.xml | 2 +- .../communication/example_type_profile.xml | 2 +- .../liveliness_assertion.120_profile.xml | 2 +- .../liveliness_assertion.360_profile.xml | 2 +- .../liveliness_assertion_profile.xml | 2 +- .../dds/communication/security/CMakeLists.txt | 15 +- .../communication/security/PublisherMain.cpp | 1 - .../security/PublisherModule.cpp | 5 +- .../security/PublisherModule.hpp | 8 +- .../communication/security/SubscriberMain.cpp | 1 - .../security/SubscriberModule.cpp | 9 +- .../security/SubscriberModule.hpp | 3 +- ...ple_secure_msg_crypto_ds_1_sub_profile.xml | 2 +- ...s_simple_secure_msg_crypto_pub_profile.xml | 2 +- ...s_simple_secure_msg_crypto_sub_profile.xml | 2 +- ...ry_no_rtps_protection_ds_1_sub_profile.xml | 2 +- ...scovery_no_rtps_protection_pub_profile.xml | 2 +- ...scovery_no_rtps_protection_sub_profile.xml | 2 +- ..._discovery_protection_ds_1_sub_profile.xml | 2 +- ...re_no_discovery_protection_pub_profile.xml | 2 +- ...re_no_discovery_protection_sub_profile.xml | 2 +- ...re_no_rtps_protection_ds_1_sub_profile.xml | 2 +- ..._secure_no_rtps_protection_pub_profile.xml | 2 +- ..._secure_no_rtps_protection_sub_profile.xml | 2 +- ...cure_msg_crypto_besteffort_pub_profile.xml | 2 +- ...cure_msg_crypto_besteffort_sub_profile.xml | 2 +- ...g_submsg_crypto_besteffort_pub_profile.xml | 2 +- ...g_submsg_crypto_besteffort_sub_profile.xml | 2 +- .../secure_simple_ds_server_idx_1_profile.xml | 2 +- ...overy_no_rtps_protection_idx_1_profile.xml | 2 +- ...o_discovery_no_rtps_protection_profile.xml | 2 +- ..._no_discovery_protection_idx_1_profile.xml | 2 +- ...server_no_discovery_protection_profile.xml | 2 +- ...erver_no_rtps_protection_idx_1_profile.xml | 2 +- ...e_ds_server_no_rtps_protection_profile.xml | 2 +- .../secure_simple_ds_server_profile.xml | 2 +- ...e_submsg_crypto_besteffort_pub_profile.xml | 2 +- ...e_submsg_crypto_besteffort_sub_profile.xml | 2 +- ...mple_allow_unauthenticated_sub_profile.xml | 2 +- ...cure_allow_unauthenticated_pub_profile.xml | 2 +- .../simple_secure_besteffort_pub_profile.xml | 2 +- .../simple_secure_besteffort_sub_profile.xml | 2 +- ..._dies_while_processing_message_profile.xml | 2 +- .../simple_besteffort_profile.xml | 2 +- .../simple_besteffort_zerocopy_profile.xml | 2 +- .../communication/simple_reliable_profile.xml | 2 +- .../simple_reliable_zerocopy_profile.xml | 2 +- test/dds/discovery/CMakeLists.txt | 2 +- test/dds/discovery/ParticipantModule.cpp | 6 +- test/dds/discovery/ParticipantModule.hpp | 3 +- test/feature/CMakeLists.txt | 13 + .../fastdds/publisher/DataWriterHistory.hpp | 4 +- .../dds/domain/DomainParticipantFactory.hpp | 69 + .../fastdds/domain/DomainParticipantImpl.hpp | 155 +- .../fastdds/dds/publisher/Publisher.hpp | 10 +- .../fastdds/dds/core/policy/QosPolicies.hpp | 204 +- .../TypeObjectRegistry.hpp | 53 + .../type_representation/TypeObjectUtils.hpp | 52 + .../rtps/builtin/BuiltinProtocols.h | 31 +- .../rtps/builtin/discovery/endpoint/EDP.h | 14 +- .../rtps/Endpoint/fastdds/rtps/Endpoint.h | 2 +- .../rtps/messages/MessageReceiver.h | 7 +- .../rtps/network/NetworkFactory.h | 8 +- .../rtps/builtin/discovery/participant/PDP.h | 14 +- .../builtin/discovery/participant/PDPSimple.h | 11 +- .../rtps/builtin/data/ParticipantProxyData.h | 14 +- .../fastrtps/publisher/PublisherHistory.h | 294 - .../RTPSDomainImpl/rtps/RTPSDomainImpl.hpp | 36 +- .../rtps/messages/RTPSGapBuilder.hpp | 2 +- .../rtps/participant/RTPSParticipant.h | 26 +- .../attributes/RTPSParticipantAttributes.h | 42 +- .../rtps/participant/RTPSParticipantImpl.h | 111 +- .../fastdds/rtps/reader/RTPSReader.h | 17 +- .../fastdds/rtps/writer/RTPSWriter.h | 11 +- .../fastdds/rtps/history/ReaderHistory.h | 10 +- .../fastdds/rtps/writer/ReaderLocator.h | 12 +- .../rtps/builtin/data/ReaderProxyData.h | 95 +- .../rtps/network/ReceiverResource.h | 11 +- .../rtps/security/SecurityManager.h | 6 +- .../rtps/security/MockAuthenticationPlugin.h | 7 +- .../rtps/security/MockCryptoKeyExchange.h | 41 +- .../rtps/security/MockCryptoKeyFactory.h | 8 +- .../rtps/security/MockCryptoTransform.h | 5 +- .../rtps/security/MockCryptographyPlugin.h | 4 +- .../rtps/security/SecurityPluginFactory.h | 8 +- .../rtps/attributes/ServerAttributes.h | 91 + .../shared_mem/SharedMemTransportDescriptor.h | 24 +- .../fastdds/rtps/reader/StatefulReader.h | 6 +- .../fastdds/rtps/writer/StatefulWriter.h | 6 +- .../fastdds/rtps/reader/StatelessReader.h | 2 +- .../fastdds/rtps/writer/StatelessWriter.h | 2 +- .../rtps}/transport/TCPTransportDescriptor.h | 20 +- .../rtps/transport/TCPv4TransportDescriptor.h | 86 + .../transport/TCPv4TransportDescriptor.h | 71 - .../transport/TCPv6TransportDescriptor.h | 35 +- .../fastdds/rtps/resources/TimedEvent.h | 6 +- .../TypeLookupManager.hpp | 20 +- .../rtps}/transport/UDPTransportDescriptor.h | 50 +- .../transport/UDPv4TransportDescriptor.h | 40 +- .../transport/UDPv6TransportDescriptor.h | 40 +- .../rtps/builtin/liveliness/WLP.h | 5 +- .../fastdds/rtps/history/WriterHistory.h | 10 +- .../rtps/builtin/data/WriterProxyData.h | 86 +- .../xmlparser/XMLEndpointParser.h | 2 +- .../xmlparser/XMLProfileManager.h | 2 +- .../rtps/network/utils/external_locators.hpp | 6 + test/performance/CMakeLists.txt | 3 +- test/performance/latency/CMakeLists.txt | 2 +- .../latency/LatencyTestPublisher.cpp | 124 +- .../latency/LatencyTestPublisher.hpp | 17 +- .../latency/LatencyTestSubscriber.cpp | 89 +- .../latency/LatencyTestSubscriber.hpp | 12 +- test/performance/latency/LatencyTestTypes.cpp | 2 +- test/performance/latency/LatencyTestTypes.hpp | 14 +- test/performance/latency/README.md | 12 +- test/performance/latency/latency_tests.py | 6 +- test/performance/latency/main_LatencyTest.cpp | 25 +- ...y_interprocess_best_effort_shm_profile.xml | 2 +- ...y_interprocess_best_effort_tcp_profile.xml | 2 +- ...y_interprocess_best_effort_udp_profile.xml | 2 +- ...ency_interprocess_reliable_shm_profile.xml | 2 +- ...ency_interprocess_reliable_tcp_profile.xml | 2 +- ...ency_interprocess_reliable_udp_profile.xml | 2 +- ...tency_intraprocess_best_effort_profile.xml | 2 +- .../latency_intraprocess_reliable_profile.xml | 2 +- test/performance/throughput/CMakeLists.txt | 2 +- test/performance/throughput/README.md | 14 +- .../throughput/ThroughputPublisher.cpp | 82 +- .../throughput/ThroughputPublisher.hpp | 19 +- .../throughput/ThroughputSubscriber.cpp | 90 +- .../throughput/ThroughputSubscriber.hpp | 15 +- .../throughput/ThroughputTypes.hpp | 14 +- .../throughput/main_ThroughputTest.cpp | 26 +- .../throughput/throughput_tests.py | 6 +- ...t_interprocess_best_effort_shm_profile.xml | 2 +- ...t_interprocess_best_effort_tcp_profile.xml | 2 +- ...t_interprocess_best_effort_udp_profile.xml | 2 +- ...hput_interprocess_reliable_shm_profile.xml | 2 +- ...hput_interprocess_reliable_tcp_profile.xml | 2 +- ...hput_interprocess_reliable_udp_profile.xml | 2 +- ...ghput_intraprocess_best_effort_profile.xml | 2 +- ...roughput_intraprocess_reliable_profile.xml | 2 +- test/performance/video/CMakeLists.txt | 4 +- test/performance/video/VideoTestPublisher.cpp | 10 +- .../performance/video/VideoTestSubscriber.cpp | 11 +- test/performance/video/VideoTestTypes.hpp | 3 +- test/performance/video/main_VideoTest.cpp | 9 +- test/performance/video/video_tests.py | 2 +- ...video_interprocess_best_effort_profile.xml | 2 +- ...o_interprocess_best_effort_tcp_profile.xml | 2 +- .../video_interprocess_reliable_profile.xml | 2 +- ...ideo_interprocess_reliable_tcp_profile.xml | 2 +- test/profiling/CMakeLists.txt | 2 +- test/profiling/MemoryTestPublisher.cpp | 377 +- test/profiling/MemoryTestPublisher.h | 194 +- test/profiling/MemoryTestSubscriber.cpp | 356 +- test/profiling/MemoryTestSubscriber.h | 181 +- test/profiling/MemoryTestTypes.cpp | 92 +- test/profiling/MemoryTestTypes.h | 180 +- test/profiling/RTPSProfilingCommon.h | 8 +- .../profiling/allocations/AllocTestCommon.cpp | 40 +- test/profiling/allocations/AllocTestCommon.h | 9 +- .../allocations/AllocTestPublisher.cpp | 179 +- .../allocations/AllocTestPublisher.h | 70 - .../allocations/AllocTestPublisher.hpp | 99 + .../allocations/AllocTestSubscriber.cpp | 200 +- .../allocations/AllocTestSubscriber.h | 104 - .../allocations/AllocTestSubscriber.hpp | 103 + test/profiling/allocations/AllocTestType.cxx | 124 - .../{AllocTestType.h => AllocTestType.hpp} | 99 +- .../allocations/AllocTestTypeCdrAux.hpp | 4 +- .../allocations/AllocTestTypeCdrAux.ipp | 2 - .../allocations/AllocTestTypePubSubTypes.cxx | 14 +- .../allocations/AllocTestTypePubSubTypes.h | 9 +- .../AllocTestTypeTypeObjectSupport.cxx | 147 + .../AllocTestTypeTypeObjectSupport.hpp | 54 + .../profiling/allocations/AllocTestTypev1.cxx | 223 - test/profiling/allocations/AllocTestTypev1.h | 216 - test/profiling/allocations/AllocTest_main.cpp | 52 +- test/profiling/allocations/CMakeLists.txt | 6 +- .../allocations/test_xml_profile.xml | 2 +- test/profiling/main_MemoryTest.cpp | 15 +- test/realtime/CMakeLists.txt | 5 +- .../TimedConditionVariableUnitTest.cpp | 2 +- test/realtime/UserThreadNonBlockedTest.cpp | 57 +- test/system/tools/fastdds/tests.py | 6 +- test/system/tools/fds/CMakeLists.txt | 2 +- ...est_wrong_xml_discovery_server_profile.xml | 2 +- .../fds/test_xml_discovery_server_profile.xml | 2 +- ...st_xml_secure_discovery_server_profile.xml | 2 +- test/system/tools/fds/tests.py | 2 +- .../XMLTesterExample_profile.xml | 2 +- .../tools/xmlvalidation/all_profile.xml | 6 +- .../xmlvalidation/dataReader_profile.xml | 2 +- .../xmlvalidation/dataWriter_profile.xml | 2 +- .../domainParticipant_profile.xml | 6 +- .../xmlvalidation/librarySettings_profile.xml | 2 +- .../tools/xmlvalidation/log_profile.xml | 2 +- .../tools/xmlvalidation/topic_profile.xml | 2 +- .../transportDescriptor_profile.xml | 2 +- .../tools/xmlvalidation/types_profile.xml | 2 +- test/unittest/CMakeLists.txt | 42 +- test/unittest/cmake/CMakeLists.txt | 4 +- test/unittest/common/GTestPrinters.hpp | 43 - test/unittest/dds/collections/CMakeLists.txt | 10 +- .../dds/core/condition/CMakeLists.txt | 31 +- .../dds/core/condition/ConditionTests.cpp | 82 +- .../condition/StatusConditionImplTests.cpp | 16 +- .../dds/core/condition/WaitSetImplTests.cpp | 44 +- test/unittest/dds/core/entity/CMakeLists.txt | 10 +- test/unittest/dds/core/entity/EntityTests.cpp | 3 +- .../dds/core/entity/mock/MockEntity.hpp | 2 +- test/unittest/dds/core/policy/CMakeLists.txt | 4 +- test/unittest/dds/participant/CMakeLists.txt | 2 +- .../dds/participant/ParticipantTests.cpp | 1504 +- .../profiles/test_xml_for_string_profile.xml | 10 +- .../dds/profiles/test_xml_profile.xml | 54 +- test/unittest/dds/publisher/CMakeLists.txt | 68 +- .../dds/publisher/DataWriterTests.cpp | 442 +- .../unittest/dds/publisher/PublisherTests.cpp | 196 +- test/unittest/dds/status/CMakeLists.txt | 53 +- test/unittest/dds/status/ListenerTests.cpp | 37 +- test/unittest/dds/subscriber/CMakeLists.txt | 12 +- .../dds/subscriber/DataReaderHistoryTests.cpp | 2 +- .../dds/subscriber/DataReaderTests.cpp | 589 +- .../dds/subscriber/SubscriberTests.cpp | 230 +- test/unittest/dds/topic/CMakeLists.txt | 2 +- .../dds/topic/DDSSQLFilter/CMakeLists.txt | 12 +- .../topic/DDSSQLFilter/DDSSQLFilterTests.cpp | 57 +- .../data_types/ContentFilterTestType.cxx | 3341 --- ...erTestType.h => ContentFilterTestType.hpp} | 2124 +- .../ContentFilterTestTypeCdrAux.hpp | 12 +- .../ContentFilterTestTypeCdrAux.ipp | 8 - .../ContentFilterTestTypePubSubTypes.cxx | 23 +- .../ContentFilterTestTypePubSubTypes.h | 18 +- .../ContentFilterTestTypeTypeObject.cxx | 3610 --- .../ContentFilterTestTypeTypeObject.h | 88 - ...ContentFilterTestTypeTypeObjectSupport.cxx | 15231 ++++++++++ ...ContentFilterTestTypeTypeObjectSupport.hpp | 61 + .../data_types/ContentFilterTestTypev1.cxx | 5318 ---- .../data_types/ContentFilterTestTypev1.h | 2359 -- test/unittest/dds/topic/TopicTests.cpp | 79 +- .../xtypes/type_representation/CMakeLists.txt | 52 + .../TypeObjectRegistryTests.cpp | 265 + .../TypeObjectUtilsTests.cpp | 3457 +++ test/unittest/dynamic_types/CMakeLists.txt | 202 - .../DynamicComplexTypesTests.cpp | 2322 -- .../dynamic_types/DynamicTypesTests.cpp | 5106 ---- .../dynamic_types/DynamicTypes_4_2_Tests.cpp | 462 - test/unittest/dynamic_types/idl/Basic.cxx | 3858 --- test/unittest/dynamic_types/idl/Basic.h | 3511 --- test/unittest/dynamic_types/idl/Basic.idl | 204 - .../dynamic_types/idl/BasicCdrAux.hpp | 366 - .../dynamic_types/idl/BasicCdrAux.ipp | 2926 -- .../dynamic_types/idl/BasicPubSubTypes.cxx | 6142 ---- .../dynamic_types/idl/BasicPubSubTypes.h | 2950 -- .../dynamic_types/idl/BasicTypeObject.cxx | 7817 ----- .../dynamic_types/idl/BasicTypeObject.h | 340 - test/unittest/dynamic_types/idl/Basicv1.cxx | 6119 ---- test/unittest/dynamic_types/idl/Basicv1.h | 5327 ---- test/unittest/dynamic_types/idl/Test.cxx | 2405 -- test/unittest/dynamic_types/idl/Test.h | 1601 - test/unittest/dynamic_types/idl/Test.idl | 93 - .../unittest/dynamic_types/idl/TestCdrAux.hpp | 112 - .../unittest/dynamic_types/idl/TestCdrAux.ipp | 873 - .../dynamic_types/idl/TestPubSubTypes.cxx | 817 - .../dynamic_types/idl/TestPubSubTypes.h | 420 - .../dynamic_types/idl/TestTypeObject.cxx | 4306 --- .../dynamic_types/idl/TestTypeObject.h | 147 - test/unittest/dynamic_types/idl/Testv1.cxx | 3744 --- test/unittest/dynamic_types/idl/Testv1.h | 1873 -- .../dynamic_types/idl/new_features_4_2.cxx | 2065 -- .../dynamic_types/idl/new_features_4_2.h | 1380 - .../dynamic_types/idl/new_features_4_2.idl | 85 - .../idl/new_features_4_2CdrAux.hpp | 92 - .../idl/new_features_4_2CdrAux.ipp | 941 - .../idl/new_features_4_2TypeObject.cxx | 3276 --- .../idl/new_features_4_2TypeObject.h | 124 - .../dynamic_types/idl/new_features_4_2v1.cxx | 2905 -- .../dynamic_types/idl/new_features_4_2v1.h | 1738 -- test/unittest/dynamic_types/types_profile.xml | 277 - test/unittest/logging/CMakeLists.txt | 15 +- .../logging/log_macros/CMakeLists.txt | 52 +- test/unittest/rtps/DataSharing/CMakeLists.txt | 2 +- .../rtps/DataSharing/SHMSegmentTests.cpp | 11 +- .../builtin/BuiltinDataSerializationTests.cpp | 86 +- test/unittest/rtps/builtin/CMakeLists.txt | 35 +- test/unittest/rtps/common/CMakeLists.txt | 20 +- .../unittest/rtps/common/CacheChangeTests.cpp | 13 +- .../rtps/common/PortParametersTests.cpp | 9 +- .../rtps/common/SequenceNumberTests.cpp | 11 +- test/unittest/rtps/common/TimeTests.cpp | 4 +- test/unittest/rtps/discovery/CMakeLists.txt | 65 +- test/unittest/rtps/discovery/EdpTests.cpp | 155 +- test/unittest/rtps/discovery/PDPTests.cpp | 36 +- test/unittest/rtps/domain/CMakeLists.txt | 67 + test/unittest/rtps/domain/RTPSDomainTests.cpp | 107 + test/unittest/rtps/flowcontrol/CMakeLists.txt | 6 +- test/unittest/rtps/history/CMakeLists.txt | 24 +- .../rtps/history/ReaderHistoryTests.cpp | 6 +- test/unittest/rtps/network/CMakeLists.txt | 44 +- .../rtps/network/ExternalLocatorsTests.cpp | 2 +- .../rtps/network/NetworkFactoryTests.cpp | 26 +- .../rtps/network/mock/MockTransport.cpp | 20 +- .../rtps/network/mock/MockTransport.h | 35 +- test/unittest/rtps/persistence/CMakeLists.txt | 8 +- .../rtps/persistence/PersistenceTests.cpp | 16 +- test/unittest/rtps/reader/CMakeLists.txt | 27 +- .../rtps/reader/WriterProxyAcknackTests.cpp | 14 +- .../rtps/reader/WriterProxyStopTest.cpp | 14 +- .../unittest/rtps/reader/WriterProxyTests.cpp | 11 +- .../rtps/resources/timedevent/CMakeLists.txt | 11 +- .../resources/timedevent/TimedEventTests.cpp | 9 +- .../resources/timedevent/mock/MockEvent.h | 7 +- test/unittest/rtps/security/CMakeLists.txt | 8 +- test/unittest/rtps/security/SecurityTests.hpp | 27 +- test/unittest/rtps/writer/CMakeLists.txt | 16 +- .../rtps/writer/LivelinessManagerTests.cpp | 148 +- .../unittest/rtps/writer/ReaderProxyTests.cpp | 15 +- .../accesscontrol/AccessControlTests.cpp | 27 +- .../security/accesscontrol/CMakeLists.txt | 18 +- .../AuthenticationPluginTests.hpp | 13 +- .../authentication/BuiltinPKIDHTests.cpp | 15 +- .../security/authentication/CMakeLists.txt | 6 +- .../security/cryptography/CMakeLists.txt | 11 +- .../cryptography/CryptographyPluginTests.hpp | 19 +- test/unittest/security/logging/CMakeLists.txt | 11 +- test/unittest/statistics/dds/CMakeLists.txt | 232 +- ...mainParticipantStatisticsListenerTests.cpp | 40 +- .../mock/fastdds/dds/publisher/DataWriter.hpp | 8 + .../StatisticsDomainParticipantMockTests.cpp | 34 +- ...sDomainParticipantStatusQueryableTests.cpp | 3 - .../mock/fastdds/publisher/DataWriterImpl.hpp | 70 +- .../fastdds/publisher/DataWriterImpl.hpp | 4 +- .../fastdds/publisher/PublisherImpl.hpp | 4 +- .../dds/StatisticsDomainParticipantTests.cpp | 143 +- .../statistics/dds/StatisticsQosTests.cpp | 33 +- test/unittest/statistics/rtps/CMakeLists.txt | 53 +- .../statistics/rtps/MonitorServiceTests.cpp | 22 +- .../statistics/rtps/RTPSStatisticsTests.cpp | 188 +- .../fastdds/publisher/DataWriterHistory.hpp | 2 +- .../statistics/rtps/StatisticsBase.hpp | 6 +- .../rtps/monitor-service/MonitorService.hpp | 10 +- test/unittest/transport/CMakeLists.txt | 27 +- test/unittest/transport/SharedMemTests.cpp | 46 +- test/unittest/transport/TCPv4Tests.cpp | 168 +- test/unittest/transport/TCPv6Tests.cpp | 56 +- test/unittest/transport/UDPv4Tests.cpp | 46 +- test/unittest/transport/UDPv6Tests.cpp | 48 +- .../transport/mock/MockReceiverResource.cpp | 35 +- .../transport/mock/MockReceiverResource.h | 5 +- .../transport/mock/MockTCPv4Transport.h | 11 +- .../transport/mock/MockTCPv6Transport.h | 4 +- test/unittest/utils/BitmapRangeTests.cpp | 2 +- test/unittest/utils/CMakeLists.txt | 48 +- test/unittest/utils/FixedSizeStringTests.cpp | 273 - test/unittest/utils/LocatorTests.cpp | 13 +- .../utils/ResourceLimitedVectorTests.cpp | 2 +- test/unittest/utils/StringMatchingTests.cpp | 49 +- test/unittest/utils/SystemInfoTests.cpp | 47 +- test/unittest/utils/shared_mutex_tests.cpp | 3 +- test/unittest/xmlparser/CMakeLists.txt | 130 +- ...M_transport_descriptors_config_profile.xml | 2 +- ...P_transport_descriptors_config_profile.xml | 2 +- .../xmlparser/XMLElementParserTests.cpp | 135 +- .../xmlparser/XMLEndpointParserTests.cpp | 22 +- test/unittest/xmlparser/XMLParserTests.cpp | 175 +- test/unittest/xmlparser/XMLParserTests.hpp | 9 +- .../xmlparser/XMLProfileParserTests.cpp | 158 +- test/unittest/xmlparser/XMLTreeTests.cpp | 18 +- .../xmlparser/log_def_file_profile.xml | 2 +- .../xmlparser/log_inactive_profile.xml | 2 +- .../log_node_file_append_profile.xml | 2 +- .../xmlparser/log_stdouterr_profile.xml | 2 +- .../log_stdouterr_two_thresholds_profile.xml | 2 +- ...rr_wrong_property_name_profile_invalid.xml | 2 +- ...r_wrong_property_value_profile_invalid.xml | 2 +- .../simple_participant_profiles_nok.xml | 2 +- .../simple_participant_profiles_ok.xml | 2 +- .../xmlparser/test_xml_deprecated.xml | 12 +- .../xmlparser/test_xml_duration_profile.xml | 2 +- test/unittest/xmlparser/test_xml_profile.xml | 54 +- .../xmlparser/test_xml_profile_env_var.xml | 12 +- ...test_xml_root_library_settings_profile.xml | 2 +- .../xmlparser/test_xml_rooted_deprecated.xml | 12 +- .../xmlparser/test_xml_rooted_profile.xml | 12 +- .../xmlparser/test_xml_security_profile.xml | 2 +- .../unittest/xmlparser/tls_config_profile.xml | 2 +- .../xmlparser/wrapper/XMLParserTest.hpp | 17 +- test/unittest/xtypes/CMakeLists.txt | 103 - test/unittest/xtypes/XTypesTests.cpp | 844 - test/unittest/xtypes/idl/Types.cxx | 5244 ---- test/unittest/xtypes/idl/Types.h | 4432 --- test/unittest/xtypes/idl/Types.idl | 271 - test/unittest/xtypes/idl/TypesCdrAux.hpp | 427 - test/unittest/xtypes/idl/TypesCdrAux.ipp | 3543 --- test/unittest/xtypes/idl/TypesPubSubTypes.cxx | 6927 ----- test/unittest/xtypes/idl/TypesPubSubTypes.h | 3337 --- test/unittest/xtypes/idl/TypesTypeObject.cxx | 8988 ------ test/unittest/xtypes/idl/TypesTypeObject.h | 394 - test/unittest/xtypes/idl/Typesv1.cxx | 8202 ------ test/unittest/xtypes/idl/Typesv1.h | 6496 ---- test/unittest/xtypes/idl/WideEnum.cxx | 591 - test/unittest/xtypes/idl/WideEnum.h | 426 - test/unittest/xtypes/idl/WideEnum.idl | 30 - test/unittest/xtypes/idl/WideEnumCdrAux.hpp | 63 - test/unittest/xtypes/idl/WideEnumCdrAux.ipp | 320 - .../xtypes/idl/WideEnumPubSubTypes.cxx | 415 - .../unittest/xtypes/idl/WideEnumPubSubTypes.h | 226 - .../xtypes/idl/WideEnumTypeObject.cxx | 957 - test/unittest/xtypes/idl/WideEnumTypeObject.h | 84 - test/unittest/xtypes/idl/WideEnumv1.cxx | 858 - test/unittest/xtypes/idl/WideEnumv1.h | 560 - test/utils/ScopedLogs.hpp | 69 + test/xtypes/CMakeLists.txt | 44 - test/xtypes/TestPublisher.cpp | 358 - test/xtypes/TestPublisher.h | 207 - test/xtypes/TestSubscriber.cpp | 379 - test/xtypes/TestSubscriber.h | 187 - test/xtypes/XTypesTests.cpp | 1687 -- test/xtypes/idl/Types.cxx | 5244 ---- test/xtypes/idl/Types.h | 4432 --- test/xtypes/idl/Types.idl | 271 - test/xtypes/idl/TypesCdrAux.hpp | 427 - test/xtypes/idl/TypesCdrAux.ipp | 3543 --- test/xtypes/idl/TypesPubSubTypes.cxx | 6927 ----- test/xtypes/idl/TypesPubSubTypes.h | 3337 --- test/xtypes/idl/TypesTypeObject.cxx | 8988 ------ test/xtypes/idl/TypesTypeObject.h | 394 - test/xtypes/idl/Typesv1.cxx | 8202 ------ test/xtypes/idl/Typesv1.h | 6496 ---- thirdparty/boost/include/boostconfig.hpp | 2 +- tools/CMakeLists.txt | 2 +- tools/fastdds/fastdds.py | 2 +- tools/fastdds/shm/clean.py | 6 +- tools/fastdds/shm/parser.py | 2 +- tools/fastdds/xml_ci/parser.py | 2 +- tools/fds/CMakeLists.txt | 16 +- tools/fds/server.cpp | 15 +- utils/doxygen/complete_doxyfile_api | 2355 -- doxyfile.in => utils/doxygen/doxyfile.in | 8 +- utils/doxygen/examples/fastrtps_example.cpp | 292 - utils/doxygen/pages/eProsimaLogo.png | Bin 7443 -> 0 bytes utils/doxygen/pages/general_architecture.png | Bin 116972 -> 0 bytes .../pages/general_architecture_old.png | Bin 39393 -> 0 bytes utils/doxygen/pages/logoEprosimaBlueRTI.gif | Bin 2170 -> 0 bytes utils/doxygen/pages/mainpage.dox | 60 - utils/futureCode/ReceivedChanges.cpp | 83 - utils/futureCode/ReceivedChanges.h | 48 - utils/futureCode/SkipList.cpp | 172 - utils/futureCode/SkipList.h | 67 - utils/images/icon/eprosima_icon.bmp | Bin 9742 -> 0 bytes utils/images/icon/eprosima_icon.ico | Bin 99678 -> 0 bytes utils/pcTests/Readme.md | 3 - .../scripts/update_generated_code_from_idl.sh | 49 +- versions.md | 32 +- 1933 files changed, 236810 insertions(+), 385883 deletions(-) delete mode 100644 .github/workflows/rebase-3.0.x-devel.yaml delete mode 100644 .settings/org.eclipse.cdt.codan.core.prefs delete mode 100644 CTestJenkins.cmake rename cmake/packaging/windows/{fastrtps-config.cmake => fastdds-config.cmake} (78%) rename cmake/packaging/windows/{fastrtps.manifest.in => fastdds.manifest.in} (100%) delete mode 100644 doc/README.html.in delete mode 100644 doc/design/intra-process.md delete mode 100644 doc/design/shared-memory-transport/interprocess_shared_mem.md delete mode 100644 doc/design/shared-memory-transport/interprocess_shared_mem1.png delete mode 100644 doc/design/shared-memory-transport/interprocess_shared_mem2.plantuml delete mode 100644 doc/design/shared-memory-transport/interprocess_shared_mem2.png delete mode 100644 doc/pdf/FASTRTPSGEN - User Manual.odt delete mode 100644 doc/pdf/Fast RTPS - Installation Manual.odt delete mode 100644 doc/pdf/Fast RTPS - Latency Test.odt delete mode 100644 doc/pdf/Fast RTPS - Throughput Test.odt delete mode 100644 doc/pdf/Fast RTPS - User Manual.odt delete mode 100755 doc/proposals/shared-memory-transport/sony/PubSub_overview.png delete mode 100755 doc/proposals/shared-memory-transport/sony/RPC_overview.png delete mode 100755 doc/proposals/shared-memory-transport/sony/improvement.png delete mode 100755 doc/proposals/shared-memory-transport/sony/ms1_rtps_shared_memory_transport.md delete mode 100755 doc/proposals/shared-memory-transport/sony/ms2_rmw_shared_memory_data_share_sony.md delete mode 100755 doc/proposals/shared-memory-transport/sony/rmw_sony_cpp.png delete mode 100644 examples/cpp/dds/AdvancedConfigurationExample/AdvancedConfiguration.cxx rename examples/cpp/dds/AdvancedConfigurationExample/{AdvancedConfiguration.h => AdvancedConfiguration.hpp} (67%) create mode 100644 examples/cpp/dds/AdvancedConfigurationExample/AdvancedConfigurationTypeObjectSupport.cxx create mode 100644 examples/cpp/dds/AdvancedConfigurationExample/AdvancedConfigurationTypeObjectSupport.hpp delete mode 100644 examples/cpp/dds/AdvancedConfigurationExample/AdvancedConfigurationv1.cxx delete mode 100644 examples/cpp/dds/AdvancedConfigurationExample/AdvancedConfigurationv1.h delete mode 100644 examples/cpp/dds/BasicConfigurationExample/HelloWorld.cxx rename examples/cpp/dds/BasicConfigurationExample/{HelloWorld.h => HelloWorld.hpp} (70%) create mode 100644 examples/cpp/dds/BasicConfigurationExample/HelloWorldTypeObjectSupport.cxx create mode 100644 examples/cpp/dds/BasicConfigurationExample/HelloWorldTypeObjectSupport.hpp delete mode 100644 examples/cpp/dds/BasicConfigurationExample/HelloWorldv1.cxx delete mode 100644 examples/cpp/dds/BasicConfigurationExample/HelloWorldv1.h delete mode 100644 examples/cpp/dds/Configurability/sample.cxx rename examples/cpp/dds/{HistoryKind/sample.h => Configurability/sample.hpp} (69%) create mode 100644 examples/cpp/dds/Configurability/sampleTypeObjectSupport.cxx create mode 100644 examples/cpp/dds/Configurability/sampleTypeObjectSupport.hpp delete mode 100644 examples/cpp/dds/Configurability/samplev1.cxx delete mode 100644 examples/cpp/dds/Configurability/samplev1.h delete mode 100644 examples/cpp/dds/ContentFilteredTopicExample/HelloWorld.cxx rename examples/cpp/dds/{HelloWorldExample/HelloWorld.h => ContentFilteredTopicExample/HelloWorld.hpp} (69%) delete mode 100644 examples/cpp/dds/ContentFilteredTopicExample/HelloWorldTypeObject.cxx delete mode 100644 examples/cpp/dds/ContentFilteredTopicExample/HelloWorldTypeObject.h create mode 100644 examples/cpp/dds/ContentFilteredTopicExample/HelloWorldTypeObjectSupport.cxx create mode 100644 examples/cpp/dds/ContentFilteredTopicExample/HelloWorldTypeObjectSupport.hpp delete mode 100644 examples/cpp/dds/ContentFilteredTopicExample/HelloWorldv1.cxx delete mode 100644 examples/cpp/dds/ContentFilteredTopicExample/HelloWorldv1.h delete mode 100644 examples/cpp/dds/CustomListenerExample/Topic.cxx rename examples/cpp/dds/{LivelinessQoS/Topic.h => CustomListenerExample/Topic.hpp} (69%) create mode 100644 examples/cpp/dds/CustomListenerExample/TopicTypeObjectSupport.cxx create mode 100644 examples/cpp/dds/CustomListenerExample/TopicTypeObjectSupport.hpp delete mode 100644 examples/cpp/dds/CustomListenerExample/Topicv1.cxx delete mode 100644 examples/cpp/dds/CustomListenerExample/Topicv1.h delete mode 100644 examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolData.cxx rename examples/cpp/dds/CustomPayloadPoolExample/{CustomPayloadPoolData.h => CustomPayloadPoolData.hpp} (69%) create mode 100644 examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolDataTypeObjectSupport.cxx create mode 100644 examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolDataTypeObjectSupport.hpp delete mode 100644 examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolDatav1.cxx delete mode 100644 examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolDatav1.h delete mode 100644 examples/cpp/dds/DeadlineQoSExample/deadlinepayload.cxx rename examples/cpp/dds/DeadlineQoSExample/{deadlinepayload.h => deadlinepayload.hpp} (71%) create mode 100644 examples/cpp/dds/DeadlineQoSExample/deadlinepayloadTypeObjectSupport.cxx create mode 100644 examples/cpp/dds/DeadlineQoSExample/deadlinepayloadTypeObjectSupport.hpp delete mode 100644 examples/cpp/dds/DeadlineQoSExample/deadlinepayloadv1.cxx delete mode 100644 examples/cpp/dds/DeadlineQoSExample/deadlinepayloadv1.h delete mode 100644 examples/cpp/dds/DeadlineQoSExample/mapableKey.h delete mode 100644 examples/cpp/dds/DisablePositiveACKs/Topic.cxx rename examples/cpp/dds/{CustomListenerExample/Topic.h => DisablePositiveACKs/Topic.hpp} (69%) create mode 100644 examples/cpp/dds/DisablePositiveACKs/TopicTypeObjectSupport.cxx create mode 100644 examples/cpp/dds/DisablePositiveACKs/TopicTypeObjectSupport.hpp delete mode 100644 examples/cpp/dds/DisablePositiveACKs/Topicv1.cxx delete mode 100644 examples/cpp/dds/DisablePositiveACKs/Topicv1.h delete mode 100644 examples/cpp/dds/DiscoveryServerExample/types/HelloWorld.cxx rename examples/cpp/dds/DiscoveryServerExample/types/{HelloWorld.h => HelloWorld.hpp} (69%) create mode 100644 examples/cpp/dds/DiscoveryServerExample/types/HelloWorldTypeObjectSupport.cxx create mode 100644 examples/cpp/dds/DiscoveryServerExample/types/HelloWorldTypeObjectSupport.hpp delete mode 100644 examples/cpp/dds/DiscoveryServerExample/types/HelloWorldv1.cxx delete mode 100644 examples/cpp/dds/DiscoveryServerExample/types/HelloWorldv1.h delete mode 100644 examples/cpp/dds/Filtering/FilteringExample.cxx rename examples/cpp/dds/Filtering/{FilteringExample.h => FilteringExample.hpp} (72%) create mode 100644 examples/cpp/dds/Filtering/FilteringExampleTypeObjectSupport.cxx create mode 100644 examples/cpp/dds/Filtering/FilteringExampleTypeObjectSupport.hpp delete mode 100644 examples/cpp/dds/Filtering/FilteringExamplev1.cxx delete mode 100644 examples/cpp/dds/Filtering/FilteringExamplev1.h delete mode 100644 examples/cpp/dds/FlowControlExample/FlowControlExample.cxx rename examples/cpp/dds/FlowControlExample/{FlowControlExample.h => FlowControlExample.hpp} (68%) create mode 100644 examples/cpp/dds/FlowControlExample/FlowControlExampleTypeObjectSupport.cxx create mode 100644 examples/cpp/dds/FlowControlExample/FlowControlExampleTypeObjectSupport.hpp delete mode 100644 examples/cpp/dds/FlowControlExample/FlowControlExamplev1.cxx delete mode 100644 examples/cpp/dds/FlowControlExample/FlowControlExamplev1.h delete mode 100644 examples/cpp/dds/HelloWorldExample/HelloWorld.cxx rename examples/cpp/dds/{ContentFilteredTopicExample/HelloWorld.h => HelloWorldExample/HelloWorld.hpp} (69%) create mode 100644 examples/cpp/dds/HelloWorldExample/HelloWorldTypeObjectSupport.cxx create mode 100644 examples/cpp/dds/HelloWorldExample/HelloWorldTypeObjectSupport.hpp delete mode 100644 examples/cpp/dds/HelloWorldExample/HelloWorldv1.cxx delete mode 100644 examples/cpp/dds/HelloWorldExample/HelloWorldv1.h delete mode 100644 examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorld.cxx rename examples/cpp/dds/HelloWorldExampleDataSharing/{HelloWorld.h => HelloWorld.hpp} (72%) create mode 100644 examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorldTypeObjectSupport.cxx create mode 100644 examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorldTypeObjectSupport.hpp delete mode 100644 examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorldv1.cxx delete mode 100644 examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorldv1.h delete mode 100644 examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorld.cxx rename examples/cpp/dds/HelloWorldExampleSharedMem/{HelloWorld.h => HelloWorld.hpp} (66%) create mode 100644 examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorldTypeObjectSupport.cxx create mode 100644 examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorldTypeObjectSupport.hpp delete mode 100644 examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorldv1.cxx delete mode 100644 examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorldv1.h delete mode 100644 examples/cpp/dds/HelloWorldExampleTCP/HelloWorld.cxx rename examples/cpp/dds/HelloWorldExampleTCP/{HelloWorld.h => HelloWorld.hpp} (69%) create mode 100644 examples/cpp/dds/HelloWorldExampleTCP/HelloWorldTypeObjectSupport.cxx create mode 100644 examples/cpp/dds/HelloWorldExampleTCP/HelloWorldTypeObjectSupport.hpp delete mode 100644 examples/cpp/dds/HelloWorldExampleTCP/HelloWorldv1.cxx delete mode 100644 examples/cpp/dds/HelloWorldExampleTCP/HelloWorldv1.h delete mode 100644 examples/cpp/dds/HistoryKind/sample.cxx rename examples/cpp/dds/{Keys/sample.h => HistoryKind/sample.hpp} (69%) create mode 100644 examples/cpp/dds/HistoryKind/sampleTypeObjectSupport.cxx create mode 100644 examples/cpp/dds/HistoryKind/sampleTypeObjectSupport.hpp delete mode 100644 examples/cpp/dds/HistoryKind/samplev1.cxx delete mode 100644 examples/cpp/dds/HistoryKind/samplev1.h delete mode 100644 examples/cpp/dds/Keys/sample.cxx rename examples/cpp/dds/{LateJoiners/sample.h => Keys/sample.hpp} (69%) create mode 100644 examples/cpp/dds/Keys/sampleTypeObjectSupport.cxx create mode 100644 examples/cpp/dds/Keys/sampleTypeObjectSupport.hpp delete mode 100644 examples/cpp/dds/Keys/samplev1.cxx delete mode 100644 examples/cpp/dds/Keys/samplev1.h delete mode 100644 examples/cpp/dds/LateJoiners/sample.cxx rename examples/cpp/dds/{Configurability/sample.h => LateJoiners/sample.hpp} (69%) create mode 100644 examples/cpp/dds/LateJoiners/sampleTypeObjectSupport.cxx create mode 100644 examples/cpp/dds/LateJoiners/sampleTypeObjectSupport.hpp delete mode 100644 examples/cpp/dds/LateJoiners/samplev1.cxx delete mode 100644 examples/cpp/dds/LateJoiners/samplev1.h delete mode 100644 examples/cpp/dds/LifespanQoSExample/Lifespan.cxx rename examples/cpp/dds/LifespanQoSExample/{Lifespan.h => Lifespan.hpp} (69%) create mode 100644 examples/cpp/dds/LifespanQoSExample/LifespanTypeObjectSupport.cxx create mode 100644 examples/cpp/dds/LifespanQoSExample/LifespanTypeObjectSupport.hpp delete mode 100644 examples/cpp/dds/LifespanQoSExample/Lifespanv1.cxx delete mode 100644 examples/cpp/dds/LifespanQoSExample/Lifespanv1.h delete mode 100644 examples/cpp/dds/LivelinessQoS/Topic.cxx rename examples/cpp/dds/{DisablePositiveACKs/Topic.h => LivelinessQoS/Topic.hpp} (69%) create mode 100644 examples/cpp/dds/LivelinessQoS/TopicTypeObjectSupport.cxx create mode 100644 examples/cpp/dds/LivelinessQoS/TopicTypeObjectSupport.hpp delete mode 100644 examples/cpp/dds/LivelinessQoS/Topicv1.cxx delete mode 100644 examples/cpp/dds/LivelinessQoS/Topicv1.h delete mode 100644 examples/cpp/dds/OwnershipStrengthQoSExample/OwnershipStrength.cxx rename examples/cpp/dds/OwnershipStrengthQoSExample/{OwnershipStrength.h => OwnershipStrength.hpp} (65%) create mode 100644 examples/cpp/dds/OwnershipStrengthQoSExample/OwnershipStrengthTypeObjectSupport.cxx create mode 100644 examples/cpp/dds/OwnershipStrengthQoSExample/OwnershipStrengthTypeObjectSupport.hpp delete mode 100644 examples/cpp/dds/OwnershipStrengthQoSExample/OwnershipStrengthv1.cxx delete mode 100644 examples/cpp/dds/OwnershipStrengthQoSExample/OwnershipStrengthv1.h delete mode 100644 examples/cpp/dds/RequestReplyExample/Calculator.cxx rename examples/cpp/dds/RequestReplyExample/{Calculator.h => Calculator.hpp} (67%) create mode 100644 examples/cpp/dds/RequestReplyExample/CalculatorTypeObjectSupport.cxx create mode 100644 examples/cpp/dds/RequestReplyExample/CalculatorTypeObjectSupport.hpp delete mode 100644 examples/cpp/dds/RequestReplyExample/Calculatorv1.cxx delete mode 100644 examples/cpp/dds/RequestReplyExample/Calculatorv1.h delete mode 100644 examples/cpp/dds/SampleConfig_Controller/sample.cxx delete mode 100644 examples/cpp/dds/SampleConfig_Controller/sample.h create mode 100644 examples/cpp/dds/SampleConfig_Controller/sample.hpp create mode 100644 examples/cpp/dds/SampleConfig_Controller/sampleTypeObjectSupport.cxx create mode 100644 examples/cpp/dds/SampleConfig_Controller/sampleTypeObjectSupport.hpp delete mode 100644 examples/cpp/dds/SampleConfig_Controller/samplev1.cxx delete mode 100644 examples/cpp/dds/SampleConfig_Controller/samplev1.h delete mode 100644 examples/cpp/dds/SampleConfig_Events/sample.cxx delete mode 100644 examples/cpp/dds/SampleConfig_Events/sample.h create mode 100644 examples/cpp/dds/SampleConfig_Events/sample.hpp create mode 100644 examples/cpp/dds/SampleConfig_Events/sampleTypeObjectSupport.cxx create mode 100644 examples/cpp/dds/SampleConfig_Events/sampleTypeObjectSupport.hpp delete mode 100644 examples/cpp/dds/SampleConfig_Events/samplev1.cxx delete mode 100644 examples/cpp/dds/SampleConfig_Events/samplev1.h delete mode 100644 examples/cpp/dds/SampleConfig_Multimedia/sample.cxx delete mode 100644 examples/cpp/dds/SampleConfig_Multimedia/sample.h create mode 100644 examples/cpp/dds/SampleConfig_Multimedia/sample.hpp create mode 100644 examples/cpp/dds/SampleConfig_Multimedia/sampleTypeObjectSupport.cxx create mode 100644 examples/cpp/dds/SampleConfig_Multimedia/sampleTypeObjectSupport.hpp delete mode 100644 examples/cpp/dds/SampleConfig_Multimedia/samplev1.cxx delete mode 100644 examples/cpp/dds/SampleConfig_Multimedia/samplev1.h delete mode 100644 examples/cpp/dds/SecureHelloWorldExample/HelloWorld.cxx delete mode 100644 examples/cpp/dds/SecureHelloWorldExample/HelloWorld.h create mode 100644 examples/cpp/dds/SecureHelloWorldExample/HelloWorld.hpp create mode 100644 examples/cpp/dds/SecureHelloWorldExample/HelloWorldTypeObjectSupport.cxx create mode 100644 examples/cpp/dds/SecureHelloWorldExample/HelloWorldTypeObjectSupport.hpp delete mode 100644 examples/cpp/dds/SecureHelloWorldExample/HelloWorldv1.cxx delete mode 100644 examples/cpp/dds/SecureHelloWorldExample/HelloWorldv1.h delete mode 100644 examples/cpp/dds/StaticHelloWorldExample/HelloWorld.cxx delete mode 100644 examples/cpp/dds/StaticHelloWorldExample/HelloWorld.h create mode 100644 examples/cpp/dds/StaticHelloWorldExample/HelloWorld.hpp create mode 100644 examples/cpp/dds/StaticHelloWorldExample/HelloWorldTypeObjectSupport.cxx create mode 100644 examples/cpp/dds/StaticHelloWorldExample/HelloWorldTypeObjectSupport.hpp delete mode 100644 examples/cpp/dds/StaticHelloWorldExample/HelloWorldv1.cxx delete mode 100644 examples/cpp/dds/StaticHelloWorldExample/HelloWorldv1.h delete mode 100644 examples/cpp/dds/TypeLookupService/CMakeLists.txt delete mode 100644 examples/cpp/dds/TypeLookupService/README.txt delete mode 100644 examples/cpp/dds/TypeLookupService/TypeLookupPublisher.cpp delete mode 100644 examples/cpp/dds/TypeLookupService/TypeLookupPublisher.h delete mode 100644 examples/cpp/dds/TypeLookupService/TypeLookupSubscriber.cpp delete mode 100644 examples/cpp/dds/TypeLookupService/TypeLookupSubscriber.h delete mode 100644 examples/cpp/dds/TypeLookupService/TypeLookup_main.cpp delete mode 100644 examples/cpp/dds/TypeLookupService/example_type_profile.xml delete mode 100644 examples/cpp/dds/WriterLoansExample/LoanableHelloWorld.cxx rename examples/cpp/dds/WriterLoansExample/{LoanableHelloWorld.h => LoanableHelloWorld.hpp} (69%) create mode 100644 examples/cpp/dds/WriterLoansExample/LoanableHelloWorldTypeObjectSupport.cxx create mode 100644 examples/cpp/dds/WriterLoansExample/LoanableHelloWorldTypeObjectSupport.hpp delete mode 100644 examples/cpp/dds/WriterLoansExample/LoanableHelloWorldv1.cxx delete mode 100644 examples/cpp/dds/WriterLoansExample/LoanableHelloWorldv1.h delete mode 100644 examples/cpp/dds/ZeroCopyExample/LoanableHelloWorld.cxx rename examples/cpp/dds/ZeroCopyExample/{LoanableHelloWorld.h => LoanableHelloWorld.hpp} (69%) create mode 100644 examples/cpp/dds/ZeroCopyExample/LoanableHelloWorldTypeObjectSupport.cxx create mode 100644 examples/cpp/dds/ZeroCopyExample/LoanableHelloWorldTypeObjectSupport.hpp delete mode 100644 examples/cpp/dds/ZeroCopyExample/LoanableHelloWorldv1.cxx delete mode 100644 examples/cpp/dds/ZeroCopyExample/LoanableHelloWorldv1.h rename fastrtps.repos => fastdds.repos (85%) delete mode 100644 include/dds/core/BuiltinTopicTypes.hpp delete mode 100644 include/dds/core/Duration.hpp delete mode 100644 include/dds/core/Entity.hpp delete mode 100644 include/dds/core/EntityQos.hpp delete mode 100644 include/dds/core/Exception.hpp delete mode 100644 include/dds/core/InstanceHandle.hpp delete mode 100644 include/dds/core/LengthUnlimited.hpp delete mode 100644 include/dds/core/Optional.hpp delete mode 100644 include/dds/core/QosProvider.hpp delete mode 100644 include/dds/core/Reference.hpp delete mode 100644 include/dds/core/SafeEnumeration.hpp delete mode 100644 include/dds/core/Time.hpp delete mode 100644 include/dds/core/Value.hpp delete mode 100644 include/dds/core/WeakReference.hpp delete mode 100644 include/dds/core/array.hpp delete mode 100644 include/dds/core/cond/Condition.hpp delete mode 100644 include/dds/core/cond/GuardCondition.hpp delete mode 100644 include/dds/core/cond/StatusCondition.hpp delete mode 100644 include/dds/core/cond/WaitSet.hpp delete mode 100644 include/dds/core/cond/detail/Condition.hpp delete mode 100644 include/dds/core/cond/detail/ConditionImpl.hpp delete mode 100644 include/dds/core/cond/detail/GuardCondition.hpp delete mode 100644 include/dds/core/cond/detail/GuardConditionImpl.hpp delete mode 100644 include/dds/core/cond/detail/StatusCondition.hpp delete mode 100644 include/dds/core/cond/detail/StatusConditionImpl.hpp delete mode 100644 include/dds/core/cond/detail/WaitSet.hpp delete mode 100644 include/dds/core/cond/detail/WaitSetImpl.hpp delete mode 100644 include/dds/core/conformance.hpp delete mode 100644 include/dds/core/ddscore.hpp delete mode 100644 include/dds/core/detail/BuiltinTopicTypes.hpp delete mode 100644 include/dds/core/detail/Entity.hpp delete mode 100644 include/dds/core/detail/EntityQosImpl.hpp delete mode 100644 include/dds/core/detail/InstanceHandle.hpp delete mode 100644 include/dds/core/detail/QosProvider.hpp delete mode 100644 include/dds/core/detail/QosProviderImpl.hpp delete mode 100644 include/dds/core/detail/ReferenceImpl.hpp delete mode 100644 include/dds/core/detail/Value.hpp delete mode 100644 include/dds/core/detail/WeakReferenceImpl.hpp delete mode 100644 include/dds/core/detail/array.hpp delete mode 100644 include/dds/core/detail/conformance.hpp delete mode 100644 include/dds/core/detail/dds_builtinTopics.h delete mode 100644 include/dds/core/detail/dds_builtinTopicsSplDcps.h delete mode 100644 include/dds/core/detail/dds_builtinTopics_DCPS.hpp delete mode 100644 include/dds/core/detail/dds_dcps_builtintopics.h delete mode 100644 include/dds/core/detail/dds_dcps_builtintopicsSplDcps.h delete mode 100644 include/dds/core/detail/dds_dcps_builtintopics_DCPS.hpp delete mode 100644 include/dds/core/detail/ddscore.hpp delete mode 100644 include/dds/core/detail/inttypes.hpp delete mode 100644 include/dds/core/detail/macros.hpp delete mode 100644 include/dds/core/detail/module_docs.hpp delete mode 100644 include/dds/core/detail/old_win_stdint.h delete mode 100644 include/dds/core/detail/ref_traits.hpp delete mode 100644 include/dds/core/macros.hpp delete mode 100644 include/dds/core/policy/CorePolicy.hpp delete mode 100644 include/dds/core/policy/PolicyKind.hpp delete mode 100644 include/dds/core/policy/QosPolicyCount.hpp delete mode 100644 include/dds/core/policy/detail/CorePolicy.hpp delete mode 100644 include/dds/core/policy/detail/CorePolicyImpl.hpp delete mode 100644 include/dds/core/policy/detail/QosPolicyCount.hpp delete mode 100644 include/dds/core/ref_traits.hpp delete mode 100644 include/dds/core/refmacros.hpp delete mode 100644 include/dds/core/status/State.hpp delete mode 100644 include/dds/core/status/Status.hpp delete mode 100644 include/dds/core/status/detail/Status.hpp delete mode 100644 include/dds/core/status/detail/StatusImpl.hpp delete mode 100644 include/dds/core/types.hpp delete mode 100644 include/dds/core/xtypes/Annotation.hpp delete mode 100644 include/dds/core/xtypes/AnnotationKind.hpp delete mode 100644 include/dds/core/xtypes/CollectionTypes.hpp delete mode 100644 include/dds/core/xtypes/DynamicData.hpp delete mode 100644 include/dds/core/xtypes/DynamicType.hpp delete mode 100644 include/dds/core/xtypes/MemberType.hpp delete mode 100644 include/dds/core/xtypes/PrimitiveTypes.hpp delete mode 100644 include/dds/core/xtypes/StructType.hpp delete mode 100644 include/dds/core/xtypes/TypeKind.hpp delete mode 100644 include/dds/core/xtypes/TypeProvider.hpp delete mode 100644 include/dds/core/xtypes/UnionCase.hpp delete mode 100644 include/dds/core/xtypes/UnionType.hpp delete mode 100644 include/dds/core/xtypes/detail/Annotation.hpp delete mode 100644 include/dds/core/xtypes/detail/CollectionTypes.hpp delete mode 100644 include/dds/core/xtypes/detail/DynamicData.hpp delete mode 100644 include/dds/core/xtypes/detail/DynamicType.hpp delete mode 100644 include/dds/core/xtypes/detail/MemberType.hpp delete mode 100644 include/dds/core/xtypes/detail/PrimitiveTypes.hpp delete mode 100644 include/dds/core/xtypes/detail/StructType.hpp delete mode 100644 include/dds/core/xtypes/detail/TypeProvider.hpp delete mode 100644 include/dds/core/xtypes/detail/UnionCase.hpp delete mode 100644 include/dds/core/xtypes/detail/UnionType.hpp delete mode 100644 include/dds/domain/DomainParticipant.hpp delete mode 100644 include/dds/domain/DomainParticipantListener.hpp delete mode 100644 include/dds/domain/detail/DomainParticipant.hpp delete mode 100644 include/dds/domain/qos/DomainParticipantQos.hpp delete mode 100644 include/dds/domain/qos/detail/DomainParticipantQos.hpp delete mode 100644 include/dds/pub/AnyDataWriter.hpp delete mode 100644 include/dds/pub/DataWriter.hpp delete mode 100644 include/dds/pub/Publisher.hpp delete mode 100644 include/dds/pub/PublisherListener.hpp delete mode 100644 include/dds/pub/detail/AnyDataWriter.hpp delete mode 100644 include/dds/pub/detail/DataWriter.hpp delete mode 100644 include/dds/pub/detail/Publisher.hpp delete mode 100644 include/dds/pub/qos/DataWriterQos.hpp delete mode 100644 include/dds/pub/qos/PublisherQos.hpp delete mode 100644 include/dds/pub/qos/detail/DataWriterQos.hpp delete mode 100644 include/dds/pub/qos/detail/PublisherQos.hpp delete mode 100644 include/dds/sub/DataReader.hpp delete mode 100644 include/dds/sub/DataReaderListener.hpp delete mode 100644 include/dds/sub/Subscriber.hpp delete mode 100644 include/dds/sub/SubscriberListener.hpp delete mode 100644 include/dds/sub/detail/DataReader.hpp delete mode 100644 include/dds/sub/detail/Subscriber.hpp delete mode 100644 include/dds/sub/qos/DataReaderQos.hpp delete mode 100644 include/dds/sub/qos/SubscriberQos.hpp delete mode 100644 include/dds/sub/qos/detail/DataReaderQos.hpp delete mode 100644 include/dds/sub/qos/detail/SubscriberQos.hpp delete mode 100644 include/dds/topic/Topic.hpp delete mode 100644 include/dds/topic/TopicListener.hpp delete mode 100644 include/dds/topic/detail/Topic.hpp delete mode 100644 include/dds/topic/qos/TopicQos.hpp delete mode 100644 include/dds/topic/qos/detail/TopicQos.hpp create mode 100644 include/fastdds/LibrarySettings.hpp rename include/{fastrtps => fastdds}/config.h.in (76%) delete mode 100644 include/fastdds/dds/builtin/common/ReplyHeader.hpp delete mode 100644 include/fastdds/dds/builtin/common/RequestHeader.hpp delete mode 100644 include/fastdds/dds/builtin/common/Types.hpp delete mode 100644 include/fastdds/dds/builtin/typelookup/TypeLookupManager.hpp delete mode 100644 include/fastdds/dds/builtin/typelookup/TypeLookupReplyListener.hpp delete mode 100644 include/fastdds/dds/builtin/typelookup/TypeLookupRequestListener.hpp delete mode 100644 include/fastdds/dds/builtin/typelookup/common/TypeLookupTypes.hpp rename include/{fastrtps/rtps/messages/MessageReceiver.h => fastdds/dds/core/ReturnCode.hpp} (65%) rename src/cpp/utils/System.cpp => include/fastdds/dds/core/Types.hpp (64%) rename test/blackbox/types/TestIncludeRegression3361.h => include/fastdds/dds/core/detail/DDSReturnCode.hpp (52%) create mode 100644 include/fastdds/dds/core/detail/DDSReturnCode.idl rename test/blackbox/types/HelloWorldTypeObject.h => include/fastdds/dds/core/detail/DDSSecurityReturnCode.hpp (55%) create mode 100644 include/fastdds/dds/core/detail/DDSSecurityReturnCode.idl create mode 100644 include/fastdds/dds/domain/qos/ReplierQos.hpp create mode 100644 include/fastdds/dds/domain/qos/RequesterQos.hpp create mode 100644 include/fastdds/dds/xtypes/common.hpp create mode 100644 include/fastdds/dds/xtypes/dynamic_types/AnnotationDescriptor.hpp create mode 100644 include/fastdds/dds/xtypes/dynamic_types/DynamicData.hpp create mode 100644 include/fastdds/dds/xtypes/dynamic_types/DynamicDataFactory.hpp create mode 100644 include/fastdds/dds/xtypes/dynamic_types/DynamicPubSubType.hpp create mode 100644 include/fastdds/dds/xtypes/dynamic_types/DynamicType.hpp create mode 100644 include/fastdds/dds/xtypes/dynamic_types/DynamicTypeBuilder.hpp create mode 100644 include/fastdds/dds/xtypes/dynamic_types/DynamicTypeBuilderFactory.hpp create mode 100644 include/fastdds/dds/xtypes/dynamic_types/DynamicTypeMember.hpp create mode 100644 include/fastdds/dds/xtypes/dynamic_types/MemberDescriptor.hpp create mode 100644 include/fastdds/dds/xtypes/dynamic_types/TypeDescriptor.hpp create mode 100644 include/fastdds/dds/xtypes/dynamic_types/Types.hpp create mode 100644 include/fastdds/dds/xtypes/dynamic_types/VerbatimTextDescriptor.hpp create mode 100644 include/fastdds/dds/xtypes/dynamic_types/detail/dynamic_language_binding.hpp create mode 100644 include/fastdds/dds/xtypes/dynamic_types/detail/dynamic_language_binding.idl create mode 100644 include/fastdds/dds/xtypes/dynamic_types/detail/type_traits.hpp rename src/cpp/dynamic-types/DynamicTypeBuilderPtr.cpp => include/fastdds/dds/xtypes/dynamic_types/type_traits.hpp (55%) create mode 100644 include/fastdds/dds/xtypes/exception/Exception.hpp create mode 100644 include/fastdds/dds/xtypes/type_representation/ITypeObjectRegistry.hpp rename test/blackbox/types/TestIncludeRegression3361.cxx => include/fastdds/dds/xtypes/type_representation/TypeObject.hpp (53%) create mode 100644 include/fastdds/dds/xtypes/type_representation/TypeObjectUtils.hpp create mode 100644 include/fastdds/dds/xtypes/type_representation/detail/dds-xtypes_typeobject.idl create mode 100644 include/fastdds/dds/xtypes/type_representation/detail/dds_xtypes_typeobject.hpp create mode 100644 include/fastdds/dds/xtypes/type_representation/detail/dds_xtypes_typeobjectCdrAux.hpp create mode 100644 include/fastdds/dds/xtypes/type_representation/detail/dds_xtypes_typeobjectPubSubTypes.h rename include/{fastrtps/eProsima_auto_link.h => fastdds/fastdds_auto_link.hpp} (62%) create mode 100644 include/fastdds/fastdds_dll.hpp create mode 100644 include/fastdds/rtps/attributes/TopicAttributes.h delete mode 100644 include/fastdds/rtps/rtps_all.h delete mode 100644 include/fastdds/rtps/writer/IReaderDataFilter.hpp rename include/{fastrtps => fastdds}/utils/IPFinder.h (86%) rename include/{fastrtps => fastdds}/utils/IPLocator.h (76%) rename include/{fastrtps => fastdds}/utils/TimedConditionVariable.hpp (99%) rename include/{fastrtps => fastdds}/utils/TimedMutex.hpp (100%) rename include/{fastrtps => fastdds}/utils/collections/ResourceLimitedContainerConfig.hpp (100%) rename include/{fastrtps => fastdds}/utils/collections/ResourceLimitedVector.hpp (100%) rename include/{fastrtps => fastdds}/utils/fixed_size_bitmap.hpp (100%) create mode 100644 include/fastdds/utils/md5.h delete mode 100644 include/fastrtps/Domain.h delete mode 100644 include/fastrtps/attributes/TopicAttributes.h delete mode 100644 include/fastrtps/attributes/all_attributes.h delete mode 100644 include/fastrtps/fastrtps_all.h delete mode 100644 include/fastrtps/fastrtps_dll.h delete mode 100644 include/fastrtps/participant/Participant.h delete mode 100644 include/fastrtps/participant/ParticipantListener.h delete mode 100644 include/fastrtps/publisher/Publisher.h delete mode 100644 include/fastrtps/publisher/PublisherHistory.h delete mode 100644 include/fastrtps/publisher/PublisherListener.h delete mode 100644 include/fastrtps/rtps/builtin/BuiltinProtocols.h delete mode 100644 include/fastrtps/rtps/builtin/discovery/endpoint/EDP.h delete mode 100644 include/fastrtps/rtps/builtin/discovery/endpoint/EDPSimple.h delete mode 100644 include/fastrtps/rtps/builtin/discovery/endpoint/EDPStatic.h delete mode 100644 include/fastrtps/rtps/builtin/discovery/participant/PDP.h delete mode 100644 include/fastrtps/rtps/builtin/discovery/participant/PDPListener.h delete mode 100644 include/fastrtps/rtps/builtin/discovery/participant/PDPSimple.h delete mode 100644 include/fastrtps/rtps/builtin/liveliness/WLP.h delete mode 100644 include/fastrtps/rtps/builtin/liveliness/WLPListener.h delete mode 100644 include/fastrtps/rtps/rtps_all.h delete mode 100644 include/fastrtps/rtps/writer/LivelinessData.h delete mode 100644 include/fastrtps/rtps/writer/LivelinessManager.h delete mode 100644 include/fastrtps/subscriber/SampleInfo.h delete mode 100644 include/fastrtps/subscriber/Subscriber.h delete mode 100644 include/fastrtps/subscriber/SubscriberHistory.h delete mode 100644 include/fastrtps/subscriber/SubscriberListener.h delete mode 100644 include/fastrtps/types/AnnotationDescriptor.h delete mode 100644 include/fastrtps/types/AnnotationParameterValue.h delete mode 100644 include/fastrtps/types/BuiltinAnnotationsTypeObject.h delete mode 100644 include/fastrtps/types/DynamicData.h delete mode 100644 include/fastrtps/types/DynamicDataFactory.h delete mode 100644 include/fastrtps/types/DynamicDataHelper.hpp delete mode 100644 include/fastrtps/types/DynamicDataPtr.h delete mode 100644 include/fastrtps/types/DynamicPubSubType.h delete mode 100644 include/fastrtps/types/DynamicType.h delete mode 100644 include/fastrtps/types/DynamicTypeBuilder.h delete mode 100644 include/fastrtps/types/DynamicTypeBuilderFactory.h delete mode 100644 include/fastrtps/types/DynamicTypeBuilderPtr.h delete mode 100644 include/fastrtps/types/DynamicTypeMember.h delete mode 100644 include/fastrtps/types/DynamicTypePtr.h delete mode 100644 include/fastrtps/types/MemberDescriptor.h delete mode 100644 include/fastrtps/types/TypeDescriptor.h delete mode 100644 include/fastrtps/types/TypeIdentifier.h delete mode 100644 include/fastrtps/types/TypeIdentifierTypes.h delete mode 100644 include/fastrtps/types/TypeNamesGenerator.h delete mode 100644 include/fastrtps/types/TypeObject.h delete mode 100644 include/fastrtps/types/TypeObjectFactory.h delete mode 100644 include/fastrtps/types/TypeObjectHashId.h delete mode 100644 include/fastrtps/types/TypesBase.h delete mode 100644 include/fastrtps/types/dds-builtin_types.idl delete mode 100644 include/fastrtps/types/dds-language_binding.idl delete mode 100644 include/fastrtps/types/dds-xtypes_discovery.idl delete mode 100644 include/fastrtps/types/dds-xtypes_typeobject.idl delete mode 100644 include/fastrtps/utils/Semaphore.h delete mode 100644 include/fastrtps/utils/System.h delete mode 100644 include/fastrtps/utils/TimeConversion.h delete mode 100644 include/fastrtps/utils/collections/foonathan_memory_helpers.hpp delete mode 100644 include/fastrtps/utils/fixed_size_string.hpp delete mode 100644 include/fastrtps/utils/md5.h delete mode 100644 m4/ax_check_openssl.m4 delete mode 100644 m4/ax_cxx_compile_stdcxx_0x.m4 delete mode 100644 m4/ax_cxx_compile_stdcxx_11.m4 rename {doc => resources}/images/fastdds_github_banner.png (100%) rename {utils => resources}/images/logo/eProsimaLogo.jpg (100%) rename {utils => resources}/images/logo/eProsimaLogo.png (100%) rename resources/xsd/{fastRTPS_profiles.xsd => fastdds_profiles.xsd} (96%) delete mode 100644 src/cpp/dds/core/Exception.cpp delete mode 100644 src/cpp/dds/core/types.cpp delete mode 100644 src/cpp/dds/domain/DomainParticipant.cpp delete mode 100644 src/cpp/dds/pub/AnyDataWriter.cpp delete mode 100644 src/cpp/dds/pub/DataWriter.cpp delete mode 100644 src/cpp/dds/pub/Publisher.cpp delete mode 100644 src/cpp/dds/sub/DataReader.cpp delete mode 100644 src/cpp/dds/sub/Subscriber.cpp delete mode 100644 src/cpp/dds/topic/Topic.cpp delete mode 100644 src/cpp/dynamic-types/AnnotationDescriptor.cpp delete mode 100644 src/cpp/dynamic-types/AnnotationParameterValue.cpp delete mode 100644 src/cpp/dynamic-types/AnnotationParameterValueCdrAux.ipp delete mode 100644 src/cpp/dynamic-types/BuiltinAnnotationsTypeObject.cpp delete mode 100644 src/cpp/dynamic-types/DynamicData.cpp delete mode 100644 src/cpp/dynamic-types/DynamicDataFactory.cpp delete mode 100644 src/cpp/dynamic-types/DynamicDataHelper.cpp delete mode 100644 src/cpp/dynamic-types/DynamicPubSubType.cpp delete mode 100644 src/cpp/dynamic-types/DynamicType.cpp delete mode 100644 src/cpp/dynamic-types/DynamicTypeBuilder.cpp delete mode 100644 src/cpp/dynamic-types/DynamicTypeBuilderFactory.cpp delete mode 100644 src/cpp/dynamic-types/DynamicTypeMember.cpp delete mode 100644 src/cpp/dynamic-types/MemberDescriptor.cpp delete mode 100644 src/cpp/dynamic-types/TypeDescriptor.cpp delete mode 100644 src/cpp/dynamic-types/TypeIdentifier.cpp delete mode 100644 src/cpp/dynamic-types/TypeIdentifierCdrAux.ipp delete mode 100644 src/cpp/dynamic-types/TypeIdentifierTypes.cpp delete mode 100644 src/cpp/dynamic-types/TypeIdentifierTypesCdrAux.ipp delete mode 100644 src/cpp/dynamic-types/TypeNamesGenerator.cpp delete mode 100644 src/cpp/dynamic-types/TypeObject.cpp delete mode 100644 src/cpp/dynamic-types/TypeObjectCdrAux.ipp delete mode 100644 src/cpp/dynamic-types/TypeObjectFactory.cpp delete mode 100644 src/cpp/dynamic-types/TypeObjectHashId.cpp delete mode 100644 src/cpp/dynamic-types/TypeObjectHashIdCdrAux.ipp delete mode 100644 src/cpp/dynamic-types/TypesBase.cpp delete mode 100644 src/cpp/fastdds/builtin/common/RPCHeadersImpl.cpp delete mode 100644 src/cpp/fastdds/builtin/common/RPCHeadersImplCdrAux.ipp create mode 100644 src/cpp/fastdds/builtin/type_lookup_service/TypeLookupManager.cpp create mode 100644 src/cpp/fastdds/builtin/type_lookup_service/TypeLookupManager.hpp create mode 100644 src/cpp/fastdds/builtin/type_lookup_service/TypeLookupReplyListener.cpp create mode 100644 src/cpp/fastdds/builtin/type_lookup_service/TypeLookupReplyListener.hpp create mode 100644 src/cpp/fastdds/builtin/type_lookup_service/TypeLookupRequestListener.cpp create mode 100644 src/cpp/fastdds/builtin/type_lookup_service/TypeLookupRequestListener.hpp create mode 100644 src/cpp/fastdds/builtin/type_lookup_service/detail/TypeLookupTypes.hpp create mode 100644 src/cpp/fastdds/builtin/type_lookup_service/detail/TypeLookupTypes.idl create mode 100644 src/cpp/fastdds/builtin/type_lookup_service/detail/TypeLookupTypesCdrAux.hpp create mode 100644 src/cpp/fastdds/builtin/type_lookup_service/detail/TypeLookupTypesCdrAux.ipp create mode 100644 src/cpp/fastdds/builtin/type_lookup_service/detail/TypeLookupTypesPubSubTypes.cxx create mode 100644 src/cpp/fastdds/builtin/type_lookup_service/detail/TypeLookupTypesPubSubTypes.h create mode 100644 src/cpp/fastdds/builtin/type_lookup_service/detail/rpc_types.hpp create mode 100644 src/cpp/fastdds/builtin/type_lookup_service/detail/rpc_types.idl create mode 100644 src/cpp/fastdds/builtin/type_lookup_service/detail/rpc_typesCdrAux.hpp create mode 100644 src/cpp/fastdds/builtin/type_lookup_service/detail/rpc_typesCdrAux.ipp rename test/unittest/dynamic_types/idl/new_features_4_2PubSubTypes.cxx => src/cpp/fastdds/builtin/type_lookup_service/detail/rpc_typesPubSubTypes.cxx (53%) rename test/unittest/dynamic_types/idl/new_features_4_2PubSubTypes.h => src/cpp/fastdds/builtin/type_lookup_service/detail/rpc_typesPubSubTypes.h (56%) delete mode 100644 src/cpp/fastdds/builtin/typelookup/TypeLookupManager.cpp delete mode 100644 src/cpp/fastdds/builtin/typelookup/TypeLookupReplyListener.cpp delete mode 100644 src/cpp/fastdds/builtin/typelookup/TypeLookupRequestListener.cpp delete mode 100644 src/cpp/fastdds/builtin/typelookup/common/TypeLookupTypes.cpp delete mode 100644 src/cpp/fastdds/builtin/typelookup/common/TypeLookupTypesCdrAux.ipp create mode 100644 src/cpp/fastdds/log/CMakeLists.txt create mode 100644 src/cpp/fastdds/xtypes/CMakeLists.txt create mode 100644 src/cpp/fastdds/xtypes/dynamic_types/AnnotationDescriptorImpl.cpp create mode 100644 src/cpp/fastdds/xtypes/dynamic_types/AnnotationDescriptorImpl.hpp rename src/cpp/{dynamic-types/DynamicDataPtr.cpp => fastdds/xtypes/dynamic_types/DynamicDataFactory.cpp} (52%) create mode 100644 src/cpp/fastdds/xtypes/dynamic_types/DynamicDataFactoryImpl.cpp create mode 100644 src/cpp/fastdds/xtypes/dynamic_types/DynamicDataFactoryImpl.hpp create mode 100644 src/cpp/fastdds/xtypes/dynamic_types/DynamicDataImpl.cpp create mode 100644 src/cpp/fastdds/xtypes/dynamic_types/DynamicDataImpl.hpp create mode 100644 src/cpp/fastdds/xtypes/dynamic_types/DynamicPubSubType.cpp rename src/cpp/{dynamic-types/DynamicTypePtr.cpp => fastdds/xtypes/dynamic_types/DynamicTypeBuilderFactory.cpp} (51%) create mode 100644 src/cpp/fastdds/xtypes/dynamic_types/DynamicTypeBuilderFactoryImpl.cpp create mode 100644 src/cpp/fastdds/xtypes/dynamic_types/DynamicTypeBuilderFactoryImpl.hpp create mode 100644 src/cpp/fastdds/xtypes/dynamic_types/DynamicTypeBuilderImpl.cpp create mode 100644 src/cpp/fastdds/xtypes/dynamic_types/DynamicTypeBuilderImpl.hpp create mode 100644 src/cpp/fastdds/xtypes/dynamic_types/DynamicTypeImpl.cpp create mode 100644 src/cpp/fastdds/xtypes/dynamic_types/DynamicTypeImpl.hpp create mode 100644 src/cpp/fastdds/xtypes/dynamic_types/DynamicTypeMemberImpl.cpp create mode 100644 src/cpp/fastdds/xtypes/dynamic_types/DynamicTypeMemberImpl.hpp create mode 100644 src/cpp/fastdds/xtypes/dynamic_types/MemberDescriptorImpl.cpp create mode 100644 src/cpp/fastdds/xtypes/dynamic_types/MemberDescriptorImpl.hpp create mode 100644 src/cpp/fastdds/xtypes/dynamic_types/TypeDescriptorImpl.cpp create mode 100644 src/cpp/fastdds/xtypes/dynamic_types/TypeDescriptorImpl.hpp create mode 100644 src/cpp/fastdds/xtypes/dynamic_types/TypeForKind.hpp create mode 100644 src/cpp/fastdds/xtypes/dynamic_types/TypeValueConverter.hpp create mode 100644 src/cpp/fastdds/xtypes/dynamic_types/VerbatimTextDescriptorImpl.cpp create mode 100644 src/cpp/fastdds/xtypes/dynamic_types/VerbatimTextDescriptorImpl.hpp create mode 100644 src/cpp/fastdds/xtypes/dynamic_types/common.hpp create mode 100644 src/cpp/fastdds/xtypes/exception/Exception.cpp create mode 100644 src/cpp/fastdds/xtypes/type_representation/TypeIdentifierWithSizeHashSpecialization.h create mode 100644 src/cpp/fastdds/xtypes/type_representation/TypeObjectRegistry.cpp create mode 100644 src/cpp/fastdds/xtypes/type_representation/TypeObjectRegistry.hpp create mode 100644 src/cpp/fastdds/xtypes/type_representation/TypeObjectUtils.cpp create mode 100644 src/cpp/fastdds/xtypes/type_representation/dds_xtypes_typeobjectCdrAux.ipp create mode 100644 src/cpp/fastdds/xtypes/type_representation/dds_xtypes_typeobjectPubSubTypes.cxx delete mode 100644 src/cpp/fastrtps_deprecated/Domain.cpp delete mode 100644 src/cpp/fastrtps_deprecated/participant/Participant.cpp delete mode 100644 src/cpp/fastrtps_deprecated/participant/ParticipantImpl.cpp delete mode 100644 src/cpp/fastrtps_deprecated/participant/ParticipantImpl.h delete mode 100644 src/cpp/fastrtps_deprecated/publisher/Publisher.cpp delete mode 100644 src/cpp/fastrtps_deprecated/publisher/PublisherHistory.cpp delete mode 100644 src/cpp/fastrtps_deprecated/publisher/PublisherImpl.cpp delete mode 100644 src/cpp/fastrtps_deprecated/publisher/PublisherImpl.h delete mode 100644 src/cpp/fastrtps_deprecated/subscriber/Subscriber.cpp delete mode 100644 src/cpp/fastrtps_deprecated/subscriber/SubscriberHistory.cpp delete mode 100644 src/cpp/fastrtps_deprecated/subscriber/SubscriberImpl.cpp delete mode 100644 src/cpp/fastrtps_deprecated/subscriber/SubscriberImpl.h create mode 100644 src/cpp/libfastdds.version delete mode 100644 src/cpp/libfastrtps.version rename src/cpp/{fastrtps_deprecated => rtps}/attributes/TopicAttributes.cpp (98%) rename {include/fastdds => src/cpp}/rtps/builtin/BuiltinProtocols.h (98%) rename {include/fastdds => src/cpp}/rtps/builtin/discovery/endpoint/EDP.h (94%) rename {include/fastdds => src/cpp}/rtps/builtin/discovery/endpoint/EDPSimple.h (99%) rename {include/fastdds => src/cpp}/rtps/builtin/discovery/endpoint/EDPStatic.h (97%) rename {include/fastdds => src/cpp}/rtps/builtin/discovery/participant/PDP.h (95%) rename {include/fastdds => src/cpp}/rtps/builtin/discovery/participant/PDPListener.h (100%) rename {include/fastdds => src/cpp}/rtps/builtin/discovery/participant/PDPSimple.h (98%) rename {include/fastdds => src/cpp}/rtps/builtin/liveliness/WLP.h (98%) rename {include/fastdds => src/cpp}/rtps/builtin/liveliness/WLPListener.h (98%) rename {include/fastdds => src/cpp}/rtps/messages/MessageReceiver.h (99%) rename include/fastdds/rtps/writer/LivelinessData.h => src/cpp/rtps/writer/LivelinessData.hpp (86%) rename include/fastdds/rtps/writer/LivelinessManager.h => src/cpp/rtps/writer/LivelinessManager.hpp (90%) rename {include/fastdds/statistics/rtps/monitor_service => src/cpp/statistics/rtps/monitor-service}/interfaces/IProxyQueryable.hpp (100%) delete mode 100644 src/cpp/statistics/types/monitorservice_types.cxx delete mode 100644 src/cpp/statistics/types/monitorservice_types.h create mode 100644 src/cpp/statistics/types/monitorservice_types.hpp create mode 100644 src/cpp/statistics/types/monitorservice_typesTypeObjectSupport.cxx create mode 100644 src/cpp/statistics/types/monitorservice_typesTypeObjectSupport.hpp delete mode 100644 src/cpp/statistics/types/monitorservice_typesv1.cxx delete mode 100644 src/cpp/statistics/types/monitorservice_typesv1.h delete mode 100644 src/cpp/statistics/types/types.cxx delete mode 100644 src/cpp/statistics/types/types.h create mode 100644 src/cpp/statistics/types/types.hpp create mode 100644 src/cpp/statistics/types/typesTypeObjectSupport.cxx create mode 100644 src/cpp/statistics/types/typesTypeObjectSupport.hpp delete mode 100644 src/cpp/statistics/types/typesv1.cxx delete mode 100644 src/cpp/statistics/types/typesv1.h rename include/fastrtps/utils/DBQueue.h => src/cpp/utils/DBQueue.hpp (97%) rename {include/fastrtps => src/cpp}/utils/ProxyPool.hpp (97%) create mode 100644 src/cpp/utils/Semaphore.hpp rename include/fastrtps/utils/StringMatching.h => src/cpp/utils/StringMatching.hpp (84%) create mode 100644 src/cpp/utils/TimeConversion.hpp rename {include/fastrtps => src/cpp}/utils/shared_mutex.hpp (99%) rename src/cpp/{rtps => }/xmlparser/XMLDynamicParser.cpp (55%) rename src/cpp/{rtps => }/xmlparser/XMLElementParser.cpp (98%) rename src/cpp/{rtps => }/xmlparser/XMLEndpointParser.cpp (98%) rename {include/fastrtps => src/cpp}/xmlparser/XMLEndpointParser.h (98%) rename src/cpp/{rtps => }/xmlparser/XMLParser.cpp (95%) rename {include/fastrtps => src/cpp}/xmlparser/XMLParser.h (65%) rename src/cpp/{rtps => }/xmlparser/XMLParserCommon.cpp (90%) rename {include/fastrtps => src/cpp}/xmlparser/XMLParserCommon.h (90%) rename src/cpp/{rtps => }/xmlparser/XMLParserUtils.hpp (100%) rename src/cpp/{rtps => }/xmlparser/XMLProfileManager.cpp (93%) rename {include/fastrtps => src/cpp}/xmlparser/XMLProfileManager.h (72%) rename {include/fastrtps => src/cpp}/xmlparser/XMLTree.h (100%) rename include/fastrtps/attributes/ParticipantAttributes.h => src/cpp/xmlparser/attributes/ParticipantAttributes.hpp (87%) rename include/fastrtps/attributes/PublisherAttributes.h => src/cpp/xmlparser/attributes/PublisherAttributes.hpp (78%) rename {include/fastrtps => src/cpp/xmlparser}/attributes/ReplierAttributes.hpp (79%) rename {include/fastrtps => src/cpp/xmlparser}/attributes/RequesterAttributes.hpp (78%) rename include/fastrtps/attributes/SubscriberAttributes.h => src/cpp/xmlparser/attributes/SubscriberAttributes.hpp (82%) delete mode 100644 test/blackbox/api/fastrtps_deprecated/PubSubParticipant.hpp delete mode 100644 test/blackbox/api/fastrtps_deprecated/PubSubReader.hpp delete mode 100644 test/blackbox/api/fastrtps_deprecated/PubSubWriter.hpp delete mode 100644 test/blackbox/api/fastrtps_deprecated/PubSubWriterReader.hpp delete mode 100644 test/blackbox/api/fastrtps_deprecated/ReqRepAsReliableHelloWorldReplier.hpp delete mode 100644 test/blackbox/api/fastrtps_deprecated/ReqRepAsReliableHelloWorldRequester.hpp delete mode 100644 test/blackbox/api/fastrtps_deprecated/ReqRepHelloWorldReplier.cpp delete mode 100644 test/blackbox/api/fastrtps_deprecated/ReqRepHelloWorldReplier.hpp delete mode 100644 test/blackbox/api/fastrtps_deprecated/ReqRepHelloWorldRequester.cpp delete mode 100644 test/blackbox/api/fastrtps_deprecated/ReqRepHelloWorldRequester.hpp delete mode 100644 test/blackbox/types/Data1mb.cxx rename test/blackbox/types/{Data1mb.h => Data1mb.hpp} (74%) create mode 100644 test/blackbox/types/Data1mbTypeObjectSupport.cxx create mode 100644 test/blackbox/types/Data1mbTypeObjectSupport.hpp delete mode 100644 test/blackbox/types/Data1mbv1.cxx delete mode 100644 test/blackbox/types/Data1mbv1.h delete mode 100644 test/blackbox/types/Data64kb.cxx rename test/blackbox/types/{Data64kb.h => Data64kb.hpp} (74%) create mode 100644 test/blackbox/types/Data64kbTypeObjectSupport.cxx create mode 100644 test/blackbox/types/Data64kbTypeObjectSupport.hpp delete mode 100644 test/blackbox/types/Data64kbv1.cxx delete mode 100644 test/blackbox/types/Data64kbv1.h delete mode 100644 test/blackbox/types/FixedSized.cxx rename test/blackbox/types/{FixedSized.h => FixedSized.hpp} (74%) create mode 100644 test/blackbox/types/FixedSizedTypeObjectSupport.cxx create mode 100644 test/blackbox/types/FixedSizedTypeObjectSupport.hpp delete mode 100644 test/blackbox/types/FixedSizedv1.cxx delete mode 100644 test/blackbox/types/FixedSizedv1.h delete mode 100644 test/blackbox/types/HelloWorld.cxx rename test/blackbox/types/{HelloWorld.h => HelloWorld.hpp} (72%) delete mode 100644 test/blackbox/types/HelloWorldTypeObject.cxx create mode 100644 test/blackbox/types/HelloWorldTypeObjectSupport.cxx create mode 100644 test/blackbox/types/HelloWorldTypeObjectSupport.hpp delete mode 100644 test/blackbox/types/HelloWorldv1.cxx delete mode 100644 test/blackbox/types/HelloWorldv1.h delete mode 100644 test/blackbox/types/KeyedData1mb.cxx rename test/blackbox/types/{KeyedData1mb.h => KeyedData1mb.hpp} (71%) create mode 100644 test/blackbox/types/KeyedData1mbTypeObjectSupport.cxx create mode 100644 test/blackbox/types/KeyedData1mbTypeObjectSupport.hpp delete mode 100644 test/blackbox/types/KeyedData1mbv1.cxx delete mode 100644 test/blackbox/types/KeyedData1mbv1.h delete mode 100644 test/blackbox/types/KeyedHelloWorld.cxx rename test/blackbox/types/{KeyedHelloWorld.h => KeyedHelloWorld.hpp} (69%) create mode 100644 test/blackbox/types/KeyedHelloWorldTypeObjectSupport.cxx create mode 100644 test/blackbox/types/KeyedHelloWorldTypeObjectSupport.hpp delete mode 100644 test/blackbox/types/KeyedHelloWorldv1.cxx delete mode 100644 test/blackbox/types/KeyedHelloWorldv1.h delete mode 100644 test/blackbox/types/StringTest.cxx rename test/blackbox/types/{StringTest.h => StringTest.hpp} (75%) create mode 100644 test/blackbox/types/StringTestTypeObjectSupport.cxx create mode 100644 test/blackbox/types/StringTestTypeObjectSupport.hpp delete mode 100644 test/blackbox/types/StringTestv1.cxx delete mode 100644 test/blackbox/types/StringTestv1.h rename test/blackbox/types/{TestIncludeRegression3361v1.h => TestIncludeRegression3361.hpp} (72%) delete mode 100644 test/blackbox/types/TestIncludeRegression3361TypeObject.cxx create mode 100644 test/blackbox/types/TestIncludeRegression3361TypeObjectSupport.cxx rename test/blackbox/types/{TestIncludeRegression3361TypeObject.h => TestIncludeRegression3361TypeObjectSupport.hpp} (51%) delete mode 100644 test/blackbox/types/TestIncludeRegression3361v1.cxx delete mode 100644 test/blackbox/types/TestRegression3361.cxx rename test/blackbox/types/{TestRegression3361.h => TestRegression3361.hpp} (73%) delete mode 100644 test/blackbox/types/TestRegression3361TypeObject.cxx delete mode 100644 test/blackbox/types/TestRegression3361TypeObject.h create mode 100644 test/blackbox/types/TestRegression3361TypeObjectSupport.cxx create mode 100644 test/blackbox/types/TestRegression3361TypeObjectSupport.hpp delete mode 100644 test/blackbox/types/TestRegression3361v1.cxx delete mode 100644 test/blackbox/types/TestRegression3361v1.h delete mode 100644 test/blackbox/types/UnboundedHelloWorld.cxx rename test/blackbox/types/{UnboundedHelloWorld.h => UnboundedHelloWorld.hpp} (69%) create mode 100644 test/blackbox/types/UnboundedHelloWorldTypeObjectSupport.cxx create mode 100644 test/blackbox/types/UnboundedHelloWorldTypeObjectSupport.hpp delete mode 100644 test/blackbox/types/UnboundedHelloWorldv1.cxx delete mode 100644 test/blackbox/types/UnboundedHelloWorldv1.h create mode 100644 test/blackbox/types/statistics/monitorservice_types.hpp create mode 100644 test/blackbox/types/statistics/monitorservice_typesCdrAux.hpp create mode 100644 test/blackbox/types/statistics/monitorservice_typesCdrAux.ipp create mode 100644 test/blackbox/types/statistics/monitorservice_typesPubSubTypes.cxx create mode 100644 test/blackbox/types/statistics/monitorservice_typesPubSubTypes.h create mode 100644 test/blackbox/types/statistics/monitorservice_typesTypeObjectSupport.cxx create mode 100644 test/blackbox/types/statistics/monitorservice_typesTypeObjectSupport.hpp delete mode 100644 test/blackbox/types/statistics/types.cxx delete mode 100644 test/blackbox/types/statistics/types.h create mode 100644 test/blackbox/types/statistics/types.hpp create mode 100644 test/blackbox/types/statistics/typesTypeObjectSupport.cxx create mode 100644 test/blackbox/types/statistics/typesTypeObjectSupport.hpp delete mode 100644 test/blackbox/types/statistics/typesv1.cxx delete mode 100644 test/blackbox/types/statistics/typesv1.h create mode 100644 test/feature/CMakeLists.txt rename test/mock/{rtps/PublisherHistory => dds/DataWriterHistory}/fastdds/publisher/DataWriterHistory.hpp (99%) create mode 100644 test/mock/dds/DomainParticipantFactory/fastdds/dds/domain/DomainParticipantFactory.hpp create mode 100644 test/mock/dds/TypeObjectRegistry/fastdds/xtypes/type_representation/TypeObjectRegistry.hpp create mode 100644 test/mock/dds/TypeObjectUtils/fastdds/dds/xtypes/type_representation/TypeObjectUtils.hpp rename test/mock/rtps/BuiltinProtocols/{fastdds => }/rtps/builtin/BuiltinProtocols.h (78%) rename test/mock/rtps/EDP/{fastdds => }/rtps/builtin/discovery/endpoint/EDP.h (91%) rename test/mock/rtps/MessageReceiver/{fastdds => }/rtps/messages/MessageReceiver.h (92%) rename test/mock/rtps/PDP/{fastdds => }/rtps/builtin/discovery/participant/PDP.h (93%) rename test/mock/rtps/PDPSimple/{fastdds => }/rtps/builtin/discovery/participant/PDPSimple.h (85%) delete mode 100644 test/mock/rtps/PublisherHistory/fastrtps/publisher/PublisherHistory.h create mode 100644 test/mock/rtps/ServerAttributes/fastdds/rtps/attributes/ServerAttributes.h rename test/mock/rtps/TCPTransportDescriptor/{fastrtps => fastdds/rtps}/transport/TCPTransportDescriptor.h (94%) create mode 100644 test/mock/rtps/TCPv4TransportDescriptor/fastdds/rtps/transport/TCPv4TransportDescriptor.h delete mode 100644 test/mock/rtps/TCPv4TransportDescriptor/fastrtps/transport/TCPv4TransportDescriptor.h rename test/mock/rtps/TCPv6TransportDescriptor/{fastrtps => fastdds/rtps}/transport/TCPv6TransportDescriptor.h (63%) rename test/mock/rtps/TypeLookupManager/fastdds/{dds/builtin/typelookup => builtin/type_lookup_service}/TypeLookupManager.hpp (80%) rename test/mock/rtps/UDPTransportDescriptor/{fastrtps => fastdds/rtps}/transport/UDPTransportDescriptor.h (56%) rename test/mock/rtps/UDPv4TransportDescriptor/{fastrtps => fastdds/rtps}/transport/UDPv4TransportDescriptor.h (62%) rename test/mock/rtps/UDPv6TransportDescriptor/{fastrtps => fastdds/rtps}/transport/UDPv6TransportDescriptor.h (62%) rename test/mock/rtps/WLP/{fastdds => }/rtps/builtin/liveliness/WLP.h (96%) rename test/mock/rtps/XMLEndPointParser/{fastrtps => }/xmlparser/XMLEndpointParser.h (96%) rename test/mock/rtps/XMLProfileManager/{fastrtps => }/xmlparser/XMLProfileManager.h (96%) delete mode 100644 test/profiling/allocations/AllocTestPublisher.h create mode 100644 test/profiling/allocations/AllocTestPublisher.hpp delete mode 100644 test/profiling/allocations/AllocTestSubscriber.h create mode 100644 test/profiling/allocations/AllocTestSubscriber.hpp delete mode 100644 test/profiling/allocations/AllocTestType.cxx rename test/profiling/allocations/{AllocTestType.h => AllocTestType.hpp} (73%) create mode 100644 test/profiling/allocations/AllocTestTypeTypeObjectSupport.cxx create mode 100644 test/profiling/allocations/AllocTestTypeTypeObjectSupport.hpp delete mode 100644 test/profiling/allocations/AllocTestTypev1.cxx delete mode 100644 test/profiling/allocations/AllocTestTypev1.h delete mode 100644 test/unittest/common/GTestPrinters.hpp delete mode 100644 test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestType.cxx rename test/unittest/dds/topic/DDSSQLFilter/data_types/{ContentFilterTestType.h => ContentFilterTestType.hpp} (58%) delete mode 100644 test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypeTypeObject.cxx delete mode 100644 test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypeTypeObject.h create mode 100644 test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypeTypeObjectSupport.cxx create mode 100644 test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypeTypeObjectSupport.hpp delete mode 100644 test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypev1.cxx delete mode 100644 test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypev1.h create mode 100644 test/unittest/dds/xtypes/type_representation/CMakeLists.txt create mode 100644 test/unittest/dds/xtypes/type_representation/TypeObjectRegistryTests.cpp create mode 100644 test/unittest/dds/xtypes/type_representation/TypeObjectUtilsTests.cpp delete mode 100644 test/unittest/dynamic_types/CMakeLists.txt delete mode 100644 test/unittest/dynamic_types/DynamicComplexTypesTests.cpp delete mode 100644 test/unittest/dynamic_types/DynamicTypesTests.cpp delete mode 100644 test/unittest/dynamic_types/DynamicTypes_4_2_Tests.cpp delete mode 100644 test/unittest/dynamic_types/idl/Basic.cxx delete mode 100644 test/unittest/dynamic_types/idl/Basic.h delete mode 100644 test/unittest/dynamic_types/idl/Basic.idl delete mode 100644 test/unittest/dynamic_types/idl/BasicCdrAux.hpp delete mode 100644 test/unittest/dynamic_types/idl/BasicCdrAux.ipp delete mode 100644 test/unittest/dynamic_types/idl/BasicPubSubTypes.cxx delete mode 100644 test/unittest/dynamic_types/idl/BasicPubSubTypes.h delete mode 100644 test/unittest/dynamic_types/idl/BasicTypeObject.cxx delete mode 100644 test/unittest/dynamic_types/idl/BasicTypeObject.h delete mode 100644 test/unittest/dynamic_types/idl/Basicv1.cxx delete mode 100644 test/unittest/dynamic_types/idl/Basicv1.h delete mode 100644 test/unittest/dynamic_types/idl/Test.cxx delete mode 100644 test/unittest/dynamic_types/idl/Test.h delete mode 100644 test/unittest/dynamic_types/idl/Test.idl delete mode 100644 test/unittest/dynamic_types/idl/TestCdrAux.hpp delete mode 100644 test/unittest/dynamic_types/idl/TestCdrAux.ipp delete mode 100644 test/unittest/dynamic_types/idl/TestPubSubTypes.cxx delete mode 100644 test/unittest/dynamic_types/idl/TestPubSubTypes.h delete mode 100644 test/unittest/dynamic_types/idl/TestTypeObject.cxx delete mode 100644 test/unittest/dynamic_types/idl/TestTypeObject.h delete mode 100644 test/unittest/dynamic_types/idl/Testv1.cxx delete mode 100644 test/unittest/dynamic_types/idl/Testv1.h delete mode 100644 test/unittest/dynamic_types/idl/new_features_4_2.cxx delete mode 100644 test/unittest/dynamic_types/idl/new_features_4_2.h delete mode 100644 test/unittest/dynamic_types/idl/new_features_4_2.idl delete mode 100644 test/unittest/dynamic_types/idl/new_features_4_2CdrAux.hpp delete mode 100644 test/unittest/dynamic_types/idl/new_features_4_2CdrAux.ipp delete mode 100644 test/unittest/dynamic_types/idl/new_features_4_2TypeObject.cxx delete mode 100644 test/unittest/dynamic_types/idl/new_features_4_2TypeObject.h delete mode 100644 test/unittest/dynamic_types/idl/new_features_4_2v1.cxx delete mode 100644 test/unittest/dynamic_types/idl/new_features_4_2v1.h delete mode 100644 test/unittest/dynamic_types/types_profile.xml create mode 100644 test/unittest/rtps/domain/CMakeLists.txt create mode 100644 test/unittest/rtps/domain/RTPSDomainTests.cpp delete mode 100644 test/unittest/utils/FixedSizeStringTests.cpp delete mode 100644 test/unittest/xtypes/CMakeLists.txt delete mode 100644 test/unittest/xtypes/XTypesTests.cpp delete mode 100644 test/unittest/xtypes/idl/Types.cxx delete mode 100644 test/unittest/xtypes/idl/Types.h delete mode 100644 test/unittest/xtypes/idl/Types.idl delete mode 100644 test/unittest/xtypes/idl/TypesCdrAux.hpp delete mode 100644 test/unittest/xtypes/idl/TypesCdrAux.ipp delete mode 100644 test/unittest/xtypes/idl/TypesPubSubTypes.cxx delete mode 100644 test/unittest/xtypes/idl/TypesPubSubTypes.h delete mode 100644 test/unittest/xtypes/idl/TypesTypeObject.cxx delete mode 100644 test/unittest/xtypes/idl/TypesTypeObject.h delete mode 100644 test/unittest/xtypes/idl/Typesv1.cxx delete mode 100644 test/unittest/xtypes/idl/Typesv1.h delete mode 100644 test/unittest/xtypes/idl/WideEnum.cxx delete mode 100644 test/unittest/xtypes/idl/WideEnum.h delete mode 100644 test/unittest/xtypes/idl/WideEnum.idl delete mode 100644 test/unittest/xtypes/idl/WideEnumCdrAux.hpp delete mode 100644 test/unittest/xtypes/idl/WideEnumCdrAux.ipp delete mode 100644 test/unittest/xtypes/idl/WideEnumPubSubTypes.cxx delete mode 100644 test/unittest/xtypes/idl/WideEnumPubSubTypes.h delete mode 100644 test/unittest/xtypes/idl/WideEnumTypeObject.cxx delete mode 100644 test/unittest/xtypes/idl/WideEnumTypeObject.h delete mode 100644 test/unittest/xtypes/idl/WideEnumv1.cxx delete mode 100644 test/unittest/xtypes/idl/WideEnumv1.h create mode 100644 test/utils/ScopedLogs.hpp delete mode 100644 test/xtypes/CMakeLists.txt delete mode 100644 test/xtypes/TestPublisher.cpp delete mode 100644 test/xtypes/TestPublisher.h delete mode 100644 test/xtypes/TestSubscriber.cpp delete mode 100644 test/xtypes/TestSubscriber.h delete mode 100644 test/xtypes/XTypesTests.cpp delete mode 100644 test/xtypes/idl/Types.cxx delete mode 100644 test/xtypes/idl/Types.h delete mode 100644 test/xtypes/idl/Types.idl delete mode 100644 test/xtypes/idl/TypesCdrAux.hpp delete mode 100644 test/xtypes/idl/TypesCdrAux.ipp delete mode 100644 test/xtypes/idl/TypesPubSubTypes.cxx delete mode 100644 test/xtypes/idl/TypesPubSubTypes.h delete mode 100644 test/xtypes/idl/TypesTypeObject.cxx delete mode 100644 test/xtypes/idl/TypesTypeObject.h delete mode 100644 test/xtypes/idl/Typesv1.cxx delete mode 100644 test/xtypes/idl/Typesv1.h delete mode 100644 utils/doxygen/complete_doxyfile_api rename doxyfile.in => utils/doxygen/doxyfile.in (99%) delete mode 100644 utils/doxygen/examples/fastrtps_example.cpp delete mode 100644 utils/doxygen/pages/eProsimaLogo.png delete mode 100644 utils/doxygen/pages/general_architecture.png delete mode 100644 utils/doxygen/pages/general_architecture_old.png delete mode 100644 utils/doxygen/pages/logoEprosimaBlueRTI.gif delete mode 100644 utils/doxygen/pages/mainpage.dox delete mode 100644 utils/futureCode/ReceivedChanges.cpp delete mode 100644 utils/futureCode/ReceivedChanges.h delete mode 100644 utils/futureCode/SkipList.cpp delete mode 100644 utils/futureCode/SkipList.h delete mode 100644 utils/images/icon/eprosima_icon.bmp delete mode 100644 utils/images/icon/eprosima_icon.ico delete mode 100644 utils/pcTests/Readme.md diff --git a/.github/pull_request_template.md b/.github/pull_request_template.md index 80a817536cc..f7e404e6d00 100644 --- a/.github/pull_request_template.md +++ b/.github/pull_request_template.md @@ -21,7 +21,7 @@ In case of bug fixes, please provide the list of supported branches where this fix should be also merged. Please uncomment following line, adjusting the corresponding target branches for the backport. --> - + @@ -32,8 +32,8 @@ ## Contributor Checklist - [ ] Commit messages follow the project guidelines. @@ -48,7 +48,6 @@ - [ ] Applicable backports have been included in the description. - ## Reviewer Checklist - [ ] The PR has a milestone assigned. diff --git a/.github/workflows/config/asan_colcon.meta b/.github/workflows/config/asan_colcon.meta index b35d778421d..58bb8ed124b 100644 --- a/.github/workflows/config/asan_colcon.meta +++ b/.github/workflows/config/asan_colcon.meta @@ -1,5 +1,5 @@ names: - fastrtps: + fastdds: cmake-args: - "-DNO_TLS=OFF" - "-DSECURITY=ON" @@ -14,4 +14,3 @@ names: - "-Dgtest_force_shared_crt=ON" - "-DBUILD_SHARED_LIBS=ON" - "-DBUILD_GMOCK=ON" - diff --git a/.github/workflows/config/ci.meta b/.github/workflows/config/ci.meta index 471c510dac4..922251be0a8 100644 --- a/.github/workflows/config/ci.meta +++ b/.github/workflows/config/ci.meta @@ -1,5 +1,5 @@ names: - fastrtps: + fastdds: cmake-args: - "-DBUILD_DOCUMENTATION=OFF" - "-DBUILD_SHARED_LIBS=ON" @@ -8,7 +8,6 @@ names: - "-DFASTDDS_ENFORCE_LOG_INFO=ON" - "-DFASTDDS_PIM_API_TESTS=ON" - "-DFASTDDS_STATISTICS=ON" - - "-DFASTRTPS_API_TESTS=OFF" - "-DINSTALL_EXAMPLES=ON" - "-DINSTALL_TOOLS=ON" - "-DINTERNAL_DEBUG=ON" @@ -19,7 +18,7 @@ names: - "-DSTRICT_REALTIME=OFF" - "-DSYSTEM_TESTS=ON" - "-DMEMORYCHECK_COMMAND_OPTIONS=-q --tool=memcheck --leak-check=yes --show-reachable=yes --num-callers=50 --log-fd=2 --error-exitcode=1" - - "-DMEMORYCHECK_SUPPRESSIONS_FILE=../../src/fastrtps/valgrind.supp" + - "-DMEMORYCHECK_SUPPRESSIONS_FILE=../../src/fastdds/valgrind.supp" googletest-distribution: cmake-args: - "-Dgtest_force_shared_crt=ON" diff --git a/.github/workflows/config/documentation.meta b/.github/workflows/config/documentation.meta index c0d85a3d55f..f6a3e624c81 100644 --- a/.github/workflows/config/documentation.meta +++ b/.github/workflows/config/documentation.meta @@ -1,5 +1,5 @@ names: - fastrtps: + fastdds: cmake-args: - "-DBUILD_SHARED_LIBS=ON" - "-DSECURITY=ON" diff --git a/.github/workflows/config/tsan_colcon.meta b/.github/workflows/config/tsan_colcon.meta index 341a32d0c23..e406dfc183a 100644 --- a/.github/workflows/config/tsan_colcon.meta +++ b/.github/workflows/config/tsan_colcon.meta @@ -3,12 +3,11 @@ names: cmake-args: - "-DCMAKE_C_FLAGS='-fsanitize=thread -O2 -g -fno-omit-frame-pointer'" - "-DCMAKE_CXX_FLAGS='-fsanitize=thread -O2 -g -fno-omit-frame-pointer'" - fastrtps: + fastdds: cmake-args: - "-DCOMPILE_EXAMPLES=OFF" - "-DEPROSIMA_BUILD_TESTS=ON" - "-DRTPS_API_TESTS=ON" - - "-DFASTRTPS_API_TESTS=OFF" - "-DFASTDDS_PIM_API_TESTS=ON" - "-DPERFORMANCE_TESTS=ON" - "-DNO_TLS=OFF" diff --git a/.github/workflows/documentation-tests.yaml b/.github/workflows/documentation-tests.yaml index ce35dd442ae..bc3ba7612af 100644 --- a/.github/workflows/documentation-tests.yaml +++ b/.github/workflows/documentation-tests.yaml @@ -44,7 +44,7 @@ jobs: - name: Sync eProsima/Fast-DDS repository uses: eProsima/eProsima-CI/external/checkout@v0 with: - path: src/fastrtps + path: src/fastdds submodules: true - name: Get minimum supported version of CMake @@ -74,14 +74,14 @@ jobs: - name: Download Fast DDS .repos uses: eProsima/eProsima-CI/ubuntu/vcs_import@v0 with: - vcs_repos_file: ./src/fastrtps/fastrtps.repos + vcs_repos_file: ./src/fastdds/fastdds.repos destination_workspace: src skip_existing: 'true' - name: Fetch Fast DDS CI dependencies uses: eProsima/eProsima-CI/multiplatform/vcs_import@v0 with: - vcs_repos_file: ${{ github.workspace }}/src/fastrtps/.github/workflows/config/ci.repos + vcs_repos_file: ${{ github.workspace }}/src/fastdds/.github/workflows/config/ci.repos destination_workspace: src skip_existing: 'true' @@ -123,7 +123,7 @@ jobs: continue-on-error: false uses: eProsima/eProsima-CI/multiplatform/colcon_build@v0 with: - colcon_meta_file: './src/fastrtps/.github/workflows/config/documentation.meta' + colcon_meta_file: './src/fastdds/.github/workflows/config/documentation.meta' colcon_build_args: '' colcon_build_args_default: '' cmake_args: '' diff --git a/.github/workflows/mac-ci.yml b/.github/workflows/mac-ci.yml index 69f34c3f044..03945a414ac 100644 --- a/.github/workflows/mac-ci.yml +++ b/.github/workflows/mac-ci.yml @@ -1,4 +1,4 @@ -name: Fast-DDS MacOS CI +name: Fast DDS MacOS CI on: workflow_dispatch: diff --git a/.github/workflows/mirror.yml b/.github/workflows/mirror.yml index 8490d894475..33940e7ba0f 100644 --- a/.github/workflows/mirror.yml +++ b/.github/workflows/mirror.yml @@ -3,15 +3,19 @@ on: push: branches: - 'master' + - '2.14.x' + jobs: - mirror_job: + mirror_job_master: + if: github.ref == 'refs/heads/master' runs-on: ubuntu-latest name: Mirror master branch to API & ABI compatible minor version branches strategy: fail-fast: false matrix: dest_branch: - - '2.14.x' + - '3.0.x' + - '3.x' steps: - name: Mirror action step id: mirror @@ -20,3 +24,21 @@ jobs: github-token: ${{ secrets.GITHUB_TOKEN }} source: 'master' dest: ${{ matrix.dest_branch }} + + mirror_job_2_x: + if: github.ref == 'refs/heads/2.14.x' + runs-on: ubuntu-latest + name: Mirror master branch to API & ABI compatible minor version branches + strategy: + fail-fast: false + matrix: + dest_branch: + - '2.x' + steps: + - name: Mirror action step + id: mirror + uses: eProsima/eProsima-CI/external/mirror-branch-action@v0 + with: + github-token: ${{ secrets.GITHUB_TOKEN }} + source: '2.14.x' + dest: ${{ matrix.dest_branch }} diff --git a/.github/workflows/nightly-mac-ci.yml b/.github/workflows/nightly-mac-ci.yml index 157e23d5e3b..f8e5959dae7 100644 --- a/.github/workflows/nightly-mac-ci.yml +++ b/.github/workflows/nightly-mac-ci.yml @@ -1,4 +1,4 @@ -name: Fast-DDS MacOS CI (nightly) +name: Fast DDS MacOS CI (nightly) on: workflow_dispatch: @@ -20,6 +20,20 @@ jobs: ctest-args: "-LE xfail" fastdds-branch: 'master' + nightly-mac-ci-2_14_x: + strategy: + fail-fast: false + matrix: + security: + - 'ON' + - 'OFF' + uses: eProsima/Fast-DDS/.github/workflows/reusable-mac-ci.yml@2.14.x + with: + label: 'nightly-sec-${{ matrix.security }}-mac-ci-2.14.x' + cmake-args: "-DSECURITY=${{ matrix.security }}" + ctest-args: "-LE xfail" + fastdds-branch: '2.14.x' + nightly-mac-ci-2_13_x: strategy: fail-fast: false @@ -61,17 +75,3 @@ jobs: cmake-args: "-DSECURITY=${{ matrix.security }}" ctest-args: "-LE xfail" fastdds-branch: '2.6.x' - - nightly-mac-ci-3_0_x-devel: - strategy: - fail-fast: false - matrix: - security: - - 'ON' - - 'OFF' - uses: eProsima/Fast-DDS/.github/workflows/reusable-mac-ci.yml@3.0.x-devel - with: - label: 'nightly-sec-${{ matrix.security }}-mac-ci-3.0.x-devel' - cmake-args: "-DSECURITY=${{ matrix.security }}" - ctest-args: "-LE xfail" - fastdds-branch: '3.0.x-devel' diff --git a/.github/workflows/nightly-sanitizers-ci.yml b/.github/workflows/nightly-sanitizers-ci.yml index c917bd88222..ddcedce2f0b 100644 --- a/.github/workflows/nightly-sanitizers-ci.yml +++ b/.github/workflows/nightly-sanitizers-ci.yml @@ -20,6 +20,20 @@ jobs: fastdds_ref: 'master' discovery_server_ref: 'master' + nightly-sanitizers-ci-2_14_x: + uses: eProsima/Fast-DDS/.github/workflows/reusable-sanitizers-ci.yml@2.14.x + with: + label: 'nightly-sec-sanitizers-ci-2.14.x' + run_asan_fastdds: true + run_asan_discovery_server: true + run_tsan_fastdds: true + colcon_build_args: '' + colcon_test_args: '' + cmake_args: '' + ctest_args: '' + fastdds_ref: '2.14.x' + discovery_server_ref: 'v1.2.2' + nightly-sanitizers-ci-2_13_x: uses: eProsima/Fast-DDS/.github/workflows/reusable-sanitizers-ci.yml@2.13.x with: @@ -61,17 +75,3 @@ jobs: ctest_args: '' fastdds_ref: '2.6.x' discovery_server_ref: 'v1.2.1' - - nightly-sanitizers-ci-3_0_x-devel: - uses: eProsima/Fast-DDS/.github/workflows/reusable-sanitizers-ci.yml@3.0.x-devel - with: - label: 'nightly-sec-sanitizers-ci-3.0.x-devel' - run_asan_fastdds: true - run_asan_discovery_server: true - run_tsan_fastdds: true - colcon_build_args: '' - colcon_test_args: '' - cmake_args: '' - ctest_args: '' - fastdds_ref: '3.0.x-devel' - discovery_server_ref: '3.0.x-devel' diff --git a/.github/workflows/nightly-ubuntu-ci.yml b/.github/workflows/nightly-ubuntu-ci.yml index 79df7e5a61c..b4216f87349 100644 --- a/.github/workflows/nightly-ubuntu-ci.yml +++ b/.github/workflows/nightly-ubuntu-ci.yml @@ -1,4 +1,4 @@ -name: Fast-DDS Ubuntu CI (nightly) +name: Fast DDS Ubuntu CI (nightly) on: workflow_dispatch: @@ -23,7 +23,7 @@ jobs: ctest-args: "-LE xfail" fastdds-branch: 'master' - nightly-ubuntu-ci-2_13_x: + nightly-ubuntu-ci-2_14_x: strategy: fail-fast: false matrix: @@ -32,15 +32,15 @@ jobs: security: - 'ON' - 'OFF' - uses: eProsima/Fast-DDS/.github/workflows/reusable-ubuntu-ci.yml@2.13.x + uses: eProsima/Fast-DDS/.github/workflows/reusable-ubuntu-ci.yml@2.14.x with: os-image: ${{ matrix.os-image }} - label: '${{ matrix.os-image }}-nightly-sec-${{ matrix.security }}-ubuntu-ci-2.13.x' + label: '${{ matrix.os-image }}-nightly-sec-${{ matrix.security }}-ubuntu-ci-2.14.x' cmake-args: "-DSECURITY=${{ matrix.security }}" ctest-args: "-LE xfail" - fastdds-branch: '2.13.x' + fastdds-branch: '2.14.x' - nightly-ubuntu-ci-2_10_x: + nightly-ubuntu-ci-2_13_x: strategy: fail-fast: false matrix: @@ -49,15 +49,15 @@ jobs: security: - 'ON' - 'OFF' - uses: eProsima/Fast-DDS/.github/workflows/reusable-ubuntu-ci.yml@2.10.x + uses: eProsima/Fast-DDS/.github/workflows/reusable-ubuntu-ci.yml@2.13.x with: os-image: ${{ matrix.os-image }} - label: '${{ matrix.os-image }}-nightly-sec-${{ matrix.security }}-ubuntu-ci-2.10.x' + label: '${{ matrix.os-image }}-nightly-sec-${{ matrix.security }}-ubuntu-ci-2.13.x' cmake-args: "-DSECURITY=${{ matrix.security }}" ctest-args: "-LE xfail" - fastdds-branch: '2.10.x' + fastdds-branch: '2.13.x' - nightly-ubuntu-ci-2_6_x: + nightly-ubuntu-ci-2_10_x: strategy: fail-fast: false matrix: @@ -66,15 +66,15 @@ jobs: security: - 'ON' - 'OFF' - uses: eProsima/Fast-DDS/.github/workflows/reusable-ubuntu-ci.yml@2.6.x + uses: eProsima/Fast-DDS/.github/workflows/reusable-ubuntu-ci.yml@2.10.x with: os-image: ${{ matrix.os-image }} - label: '${{ matrix.os-image }}-nightly-sec-${{ matrix.security }}-ubuntu-ci-2.6.x' + label: '${{ matrix.os-image }}-nightly-sec-${{ matrix.security }}-ubuntu-ci-2.10.x' cmake-args: "-DSECURITY=${{ matrix.security }}" ctest-args: "-LE xfail" - fastdds-branch: '2.6.x' + fastdds-branch: '2.10.x' - nightly-ubuntu-ci-3_0_x-devel: + nightly-ubuntu-ci-2_6_x: strategy: fail-fast: false matrix: @@ -83,10 +83,10 @@ jobs: security: - 'ON' - 'OFF' - uses: eProsima/Fast-DDS/.github/workflows/reusable-ubuntu-ci.yml@3.0.x-devel + uses: eProsima/Fast-DDS/.github/workflows/reusable-ubuntu-ci.yml@2.6.x with: os-image: ${{ matrix.os-image }} - label: '${{ matrix.os-image }}-nightly-sec-${{ matrix.security }}-ubuntu-ci-3.0.x-devel' + label: '${{ matrix.os-image }}-nightly-sec-${{ matrix.security }}-ubuntu-ci-2.6.x' cmake-args: "-DSECURITY=${{ matrix.security }}" ctest-args: "-LE xfail" - fastdds-branch: '3.0.x-devel' + fastdds-branch: '2.6.x' diff --git a/.github/workflows/nightly-windows-ci.yml b/.github/workflows/nightly-windows-ci.yml index 29c50cb09e7..edaf8226b1c 100644 --- a/.github/workflows/nightly-windows-ci.yml +++ b/.github/workflows/nightly-windows-ci.yml @@ -1,4 +1,4 @@ -name: Fast-DDS Windows CI (nightly) +name: Fast DDS Windows CI (nightly) on: workflow_dispatch: @@ -20,6 +20,20 @@ jobs: ctest-args: "-LE xfail" fastdds_branch: 'master' + nightly-windows-ci-2_14_x: + strategy: + fail-fast: false + matrix: + security: + - 'ON' + - 'OFF' + uses: eProsima/Fast-DDS/.github/workflows/reusable-windows-ci.yml@2.14.x + with: + label: 'nightly-sec-${{ matrix.security }}-windows-ci-2.14.x' + cmake-args: "-DSECURITY=${{ matrix.security }}" + ctest-args: "-LE xfail" + fastdds_branch: '2.14.x' + nightly-windows-ci-2_13_x: strategy: fail-fast: false @@ -61,17 +75,3 @@ jobs: cmake-args: "-DSECURITY=${{ matrix.security }}" ctest-args: "-LE xfail" fastdds_branch: '2.6.x' - - nightly-windows-ci-3_0_x-devel: - strategy: - fail-fast: false - matrix: - security: - - 'ON' - - 'OFF' - uses: eProsima/Fast-DDS/.github/workflows/reusable-windows-ci.yml@3.0.x-devel - with: - label: 'nightly-sec-${{ matrix.security }}-windows-ci-3.0.x-devel' - cmake-args: "-DSECURITY=${{ matrix.security }}" - ctest-args: "-LE xfail" - fastdds_branch: '3.0.x-devel' diff --git a/.github/workflows/rebase-3.0.x-devel.yaml b/.github/workflows/rebase-3.0.x-devel.yaml deleted file mode 100644 index a29973215cc..00000000000 --- a/.github/workflows/rebase-3.0.x-devel.yaml +++ /dev/null @@ -1,47 +0,0 @@ -name: rebase-3.0.x-devel-master - -on: - schedule: - - cron: '0 0 * * *' - # scheduled every midnight - workflow_dispatch: - #manual run of the workflow job - -jobs: - rebase-branches: - name: Rebase 3.0.x-devel branch HEAD with master current branch - runs-on: ubuntu-latest - - steps: - # Step 1: checkout action - - name: Checkout target repo - uses: eProsima/eProsima-CI/external/checkout@v0 - with: - ref: 3.0.x-devel - fetch-depth: 0 - persist-credentials: true - - # Step 2: Set git config - - name: Set git config - id: config - run: | - git config --local user.email "ricardogonzalez@eprosima.com" - git config --local user.name "richiprosima" - shell: bash - - # Step 3: Rebase - - name: Rebase current branch - id: rebase_master - run: | - git fetch origin master - git rebase origin/master - shell: bash - - # Step 4: Push - - name: Force push if required - id: push - run: | - if [ "$(git status | grep 'diverged\|ahead')" ]; then - git push -f - fi; - shell: bash diff --git a/.github/workflows/reusable-mac-ci.yml b/.github/workflows/reusable-mac-ci.yml index 3807960499e..02ee5916ad7 100644 --- a/.github/workflows/reusable-mac-ci.yml +++ b/.github/workflows/reusable-mac-ci.yml @@ -1,4 +1,4 @@ -name: Fast-DDS MacOS CI reusable workflow +name: Fast DDS MacOS CI reusable workflow on: workflow_call: @@ -55,7 +55,7 @@ jobs: - name: Sync eProsima/Fast-DDS repository uses: eProsima/eProsima-CI/external/checkout@v0 with: - path: src/fastrtps + path: src/fastdds ref: ${{ inputs.fastdds-branch }} - uses: eProsima/eProsima-CI/external/setup-python@v0 @@ -93,14 +93,14 @@ jobs: - name: Fetch Fast DDS dependencies uses: eProsima/eProsima-CI/multiplatform/vcs_import@v0 with: - vcs_repos_file: ${{ github.workspace }}/src/fastrtps/fastrtps.repos + vcs_repos_file: ${{ github.workspace }}/src/fastdds/fastdds.repos destination_workspace: src skip_existing: 'true' - name: Fetch Fast DDS CI dependencies uses: eProsima/eProsima-CI/multiplatform/vcs_import@v0 with: - vcs_repos_file: ${{ github.workspace }}/src/fastrtps/.github/workflows/config/ci.repos + vcs_repos_file: ${{ github.workspace }}/src/fastdds/.github/workflows/config/ci.repos destination_workspace: src skip_existing: 'true' @@ -112,7 +112,7 @@ jobs: continue-on-error: false uses: eProsima/eProsima-CI/multiplatform/colcon_build@v0 with: - colcon_meta_file: ${{ github.workspace }}/src/fastrtps/.github/workflows/config/ci.meta + colcon_meta_file: ${{ github.workspace }}/src/fastdds/.github/workflows/config/ci.meta colcon_build_args: ${{ inputs.colcon-args }} cmake_args: ${{ inputs.cmake-args }} cmake_args_default: -DCMAKE_CXX_FLAGS="-Werror -Wall -Wno-enum-constexpr-conversion" @@ -128,7 +128,7 @@ jobs: colcon_test_args_default: --event-handlers=console_direct+ ctest_args: ${{ inputs.ctest-args }} ctest_args_default: --repeat until-pass:3 --timeout 300 --label-exclude "xfail" - packages_names: fastrtps + packages_names: fastdds workspace: ${{ github.workspace }} test_report_artifact: ${{ format('test_report_{0}_{1}_{2}', inputs.label, github.job, join(matrix.*, '_')) }} diff --git a/.github/workflows/reusable-sanitizers-ci.yml b/.github/workflows/reusable-sanitizers-ci.yml index a08587bf322..ec267d7ff28 100644 --- a/.github/workflows/reusable-sanitizers-ci.yml +++ b/.github/workflows/reusable-sanitizers-ci.yml @@ -71,7 +71,7 @@ jobs: - name: Sync eProsima/Fast-DDS repository uses: eProsima/eProsima-CI/external/checkout@v0 with: - path: src/fastrtps + path: src/fastdds ref: ${{ inputs.fastdds_ref }} - name: Get minimum supported version of CMake @@ -98,27 +98,27 @@ jobs: - name: Fetch Fast DDS dependencies uses: eProsima/eProsima-CI/multiplatform/vcs_import@v0 with: - vcs_repos_file: ${{ github.workspace }}/src/fastrtps/fastrtps.repos + vcs_repos_file: ${{ github.workspace }}/src/fastdds/fastdds.repos destination_workspace: src skip_existing: 'true' - name: Fetch Fast DDS CI dependencies uses: eProsima/eProsima-CI/multiplatform/vcs_import@v0 with: - vcs_repos_file: ${{ github.workspace }}/src/fastrtps/.github/workflows/config/asan.repos + vcs_repos_file: ${{ github.workspace }}/src/fastdds/.github/workflows/config/asan.repos destination_workspace: src skip_existing: 'true' - name: Show .meta file id: show_meta run: | - cat ${{ github.workspace }}/src/fastrtps/.github/workflows/config/asan_colcon.meta + cat ${{ github.workspace }}/src/fastdds/.github/workflows/config/asan_colcon.meta - name: Colcon build continue-on-error: false uses: eProsima/eProsima-CI/multiplatform/colcon_build@v0 with: - colcon_meta_file: ${{ github.workspace }}/src/fastrtps/.github/workflows/config/asan_colcon.meta + colcon_meta_file: ${{ github.workspace }}/src/fastdds/.github/workflows/config/asan_colcon.meta colcon_build_args: ${{ inputs.colcon_build_args }} cmake_args: ${{ inputs.cmake_args }} cmake_args_default: '' @@ -166,16 +166,16 @@ jobs: - name: Show .meta file id: show_meta run: | - cat ${{ github.workspace }}/src/fastrtps/.github/workflows/config/asan_colcon.meta + cat ${{ github.workspace }}/src/fastdds/.github/workflows/config/asan_colcon.meta - name: Colcon build continue-on-error: false uses: eProsima/eProsima-CI/multiplatform/colcon_build@v0 with: - colcon_meta_file: ${{ github.workspace }}/src/fastrtps/.github/workflows/config/asan_colcon.meta + colcon_meta_file: ${{ github.workspace }}/src/fastdds/.github/workflows/config/asan_colcon.meta colcon_build_args: ${{ inputs.colcon_build_args }} cmake_args: ${{ inputs.cmake_args }} - cmake_args_default: -DEPROSIMA_BUILD_TESTS=ON -DRTPS_API_TESTS=ON -DFASTRTPS_API_TESTS=ON -DFASTDDS_PIM_API_TESTS=ON -DPERFORMANCE_TESTS=ON + cmake_args_default: -DEPROSIMA_BUILD_TESTS=ON -DRTPS_API_TESTS=ON -DFASTDDS_PIM_API_TESTS=ON -DPERFORMANCE_TESTS=ON cmake_build_type: 'Debug' workspace: ${{ github.workspace }} workspace_dependencies: '' @@ -190,7 +190,7 @@ jobs: colcon_test_args_default: '--event-handlers=console_direct+ --return-code-on-test-failure' ctest_args: ${{ inputs.ctest_args }} ctest_args_default: '--timeout 300 --label-exclude "xfail"' - packages_names: fastrtps + packages_names: fastdds workspace: ${{ github.workspace }} workspace_dependencies: '' test_report_artifact: ${{ format('test_report_{0}_{1}', inputs.label, github.job) }} @@ -198,13 +198,13 @@ jobs: - name: Report sanitizer errors if: ${{ inputs.run_asan_fastdds }} run: | - bash src/fastrtps/.github/workflows/utils/specific_errors_filter.sh \ + bash src/fastdds/.github/workflows/utils/specific_errors_filter.sh \ "==ERROR:" \ - log/latest_test/fastrtps/stdout_stderr.log \ + log/latest_test/fastdds/stdout_stderr.log \ _tmp_specific_error_file.log - python3 src/fastrtps/.github/workflows/utils/log_parser.py \ - --log-file log/latest_test/fastrtps/stdout_stderr.log \ + python3 src/fastdds/.github/workflows/utils/log_parser.py \ + --log-file log/latest_test/fastdds/stdout_stderr.log \ --specific-error-file _tmp_specific_error_file.log \ --output-file $GITHUB_STEP_SUMMARY \ --sanitizer asan @@ -263,13 +263,13 @@ jobs: - name: Show .meta file id: show_meta run: | - cat ${{ github.workspace }}/src/fastrtps/.github/workflows/config/asan_colcon.meta + cat ${{ github.workspace }}/src/fastdds/.github/workflows/config/asan_colcon.meta - name: Colcon build continue-on-error: false uses: eProsima/eProsima-CI/multiplatform/colcon_build@v0 with: - colcon_meta_file: ${{ github.workspace }}/src/fastrtps/.github/workflows/config/asan_colcon.meta + colcon_meta_file: ${{ github.workspace }}/src/fastdds/.github/workflows/config/asan_colcon.meta colcon_build_args: ${{ inputs.colcon_build_args }} cmake_args: ${{ inputs.cmake_args }} cmake_args_default: '' @@ -295,12 +295,12 @@ jobs: - name: Report sanitizer errors if: ${{ inputs.run_asan_discovery_server }} run: | - bash src/fastrtps/.github/workflows/utils/specific_errors_filter.sh \ + bash src/fastdds/.github/workflows/utils/specific_errors_filter.sh \ "==ERROR:" \ log/latest_test/discovery-server/stdout_stderr.log \ _tmp_specific_error_file.log - python3 src/fastrtps/.github/workflows/utils/log_parser.py \ + python3 src/fastdds/.github/workflows/utils/log_parser.py \ --log-file log/latest_test/discovery-server/stdout_stderr.log \ --specific-error-file _tmp_specific_error_file.log \ --output-file $GITHUB_STEP_SUMMARY \ @@ -332,7 +332,7 @@ jobs: - name: Sync eProsima/Fast-DDS repository uses: eProsima/eProsima-CI/external/checkout@v0 with: - path: src/fastrtps + path: src/fastdds ref: ${{ inputs.fastdds_ref }} - name: Get minimum supported version of CMake @@ -359,27 +359,27 @@ jobs: - name: Fetch Fast DDS dependencies uses: eProsima/eProsima-CI/multiplatform/vcs_import@v0 with: - vcs_repos_file: ${{ github.workspace }}/src/fastrtps/fastrtps.repos + vcs_repos_file: ${{ github.workspace }}/src/fastdds/fastdds.repos destination_workspace: src skip_existing: 'true' - name: Fetch Fast DDS CI dependencies uses: eProsima/eProsima-CI/multiplatform/vcs_import@v0 with: - vcs_repos_file: ${{ github.workspace }}/src/fastrtps/.github/workflows/config/ci.repos + vcs_repos_file: ${{ github.workspace }}/src/fastdds/.github/workflows/config/ci.repos destination_workspace: src skip_existing: 'true' - name: Show .meta file id: show_meta run: | - cat ${{ github.workspace }}/src/fastrtps/.github/workflows/config/tsan_colcon.meta + cat ${{ github.workspace }}/src/fastdds/.github/workflows/config/tsan_colcon.meta - name: Colcon build continue-on-error: false uses: eProsima/eProsima-CI/multiplatform/colcon_build@v0 with: - colcon_meta_file: ${{ github.workspace }}/src/fastrtps/.github/workflows/config/tsan_colcon.meta + colcon_meta_file: ${{ github.workspace }}/src/fastdds/.github/workflows/config/tsan_colcon.meta colcon_build_args: ${{ inputs.colcon_build_args }} cmake_args: ${{ inputs.cmake_args }} cmake_args_default: '' @@ -397,7 +397,7 @@ jobs: colcon_test_args_default: '--event-handlers=console_direct+ --return-code-on-test-failure' ctest_args: ${{ inputs.ctest_args }} ctest_args_default: '--timeout 300 --label-exclude "xfail" -V -E DDSSQLFilterValueTests' - packages_names: fastrtps + packages_names: fastdds workspace: ${{ github.workspace }} workspace_dependencies: '' test_report_artifact: ${{ format('test_report_{0}_{1}', inputs.label, github.job) }} @@ -410,7 +410,7 @@ jobs: # Create a dir for the exports $exports = New-Item -ItemType Directory -Path ./exports # Move to the reports dir - pushd ./log/latest_test/fastrtps + pushd ./log/latest_test/fastdds # Install the report parser module Find-Module -Repository PSGallery -Name SanReportParser | Install-Module -Scope CurrentUser -Force # Parse the report files diff --git a/.github/workflows/reusable-ubuntu-ci.yml b/.github/workflows/reusable-ubuntu-ci.yml index 6c3b1d59ff9..22a7d21b0b5 100644 --- a/.github/workflows/reusable-ubuntu-ci.yml +++ b/.github/workflows/reusable-ubuntu-ci.yml @@ -1,4 +1,4 @@ -name: Fast-DDS Ubuntu CI reusable workflow +name: Fast DDS Ubuntu CI reusable workflow on: workflow_call: @@ -53,7 +53,7 @@ jobs: - name: Sync eProsima/Fast-DDS repository uses: eProsima/eProsima-CI/external/checkout@v0 with: - path: src/fastrtps + path: src/fastdds ref: ${{ inputs.fastdds-branch }} - name: Install Fix Python version @@ -92,14 +92,14 @@ jobs: - name: Fetch Fast DDS dependencies uses: eProsima/eProsima-CI/multiplatform/vcs_import@v0 with: - vcs_repos_file: ${{ github.workspace }}/src/fastrtps/fastrtps.repos + vcs_repos_file: ${{ github.workspace }}/src/fastdds/fastdds.repos destination_workspace: src skip_existing: 'true' - name: Fetch Fast DDS CI dependencies uses: eProsima/eProsima-CI/multiplatform/vcs_import@v0 with: - vcs_repos_file: ${{ github.workspace }}/src/fastrtps/.github/workflows/config/ci.repos + vcs_repos_file: ${{ github.workspace }}/src/fastdds/.github/workflows/config/ci.repos destination_workspace: src skip_existing: 'true' @@ -133,7 +133,7 @@ jobs: continue-on-error: false uses: eProsima/eProsima-CI/multiplatform/colcon_build@v0 with: - colcon_meta_file: ${{ github.workspace }}/src/fastrtps/.github/workflows/config/ci.meta + colcon_meta_file: ${{ github.workspace }}/src/fastdds/.github/workflows/config/ci.meta colcon_build_args: ${{ inputs.colcon-args }} cmake_args: ${{ inputs.cmake-args }} cmake_args_default: -DCMAKE_CXX_FLAGS="-Werror -Wall -Wextra -Wpedantic -Wunused-value -Woverloaded-virtual" -DFASTDDS_EXAMPLE_TESTS=ON @@ -149,7 +149,7 @@ jobs: colcon_test_args_default: --event-handlers=console_direct+ ctest_args: ${{ inputs.ctest-args }} ctest_args_default: --repeat until-pass:3 --timeout 300 --label-exclude "xfail" - packages_names: fastrtps + packages_names: fastdds workspace: ${{ github.workspace }} test_report_artifact: ${{ format('test_report_{0}_{1}_{2}', inputs.label, github.job, join(matrix.*, '_')) }} diff --git a/.github/workflows/reusable-windows-ci.yml b/.github/workflows/reusable-windows-ci.yml index 3524ed8b9f0..41d7952c835 100644 --- a/.github/workflows/reusable-windows-ci.yml +++ b/.github/workflows/reusable-windows-ci.yml @@ -1,4 +1,4 @@ -name: Fast-DDS Windows CI reusable workflow +name: Fast DDS Windows CI reusable workflow on: workflow_call: @@ -52,7 +52,7 @@ jobs: - name: Sync eProsima/Fast-DDS repository uses: eProsima/eProsima-CI/external/checkout@v0 with: - path: src/fastrtps + path: src/fastdds submodules: true ref: ${{ inputs.fastdds_branch }} @@ -131,14 +131,14 @@ jobs: - name: Fetch Fast DDS dependencies uses: eProsima/eProsima-CI/multiplatform/vcs_import@v0 with: - vcs_repos_file: ${{ github.workspace }}\src\fastrtps\fastrtps.repos + vcs_repos_file: ${{ github.workspace }}\src\fastdds\fastdds.repos destination_workspace: src skip_existing: 'true' - name: Fetch Fast DDS CI dependencies uses: eProsima/eProsima-CI/multiplatform/vcs_import@v0 with: - vcs_repos_file: ${{ github.workspace }}\src\fastrtps\.github\workflows\config\ci.repos + vcs_repos_file: ${{ github.workspace }}\src\fastdds\.github\workflows\config\ci.repos destination_workspace: src skip_existing: 'true' @@ -147,7 +147,7 @@ jobs: continue-on-error: false uses: eProsima/eProsima-CI/windows/colcon_build@v0 with: - colcon_meta_file: ${{ github.workspace }}\src\fastrtps\.github\workflows\config\ci.meta + colcon_meta_file: ${{ github.workspace }}\src\fastdds\.github\workflows\config\ci.meta colcon_build_args: ${{ inputs.colcon-args }} # The following Fast DDS CMake options need to be specified here instead of in the ci.meta file # because they vary from platform to platform @@ -164,7 +164,7 @@ jobs: colcon_test_args_default: --event-handlers=console_direct+ ctest_args: ${{ inputs.ctest-args }} ctest_args_default: --repeat until-pass:3 --timeout 300 --label-exclude "xfail" - packages_names: fastrtps + packages_names: fastdds workspace: ${{ github.workspace }} test_report_artifact: ${{ format('test_report_{0}_{1}_{2}', inputs.label, github.job, join(matrix.*, '_')) }} diff --git a/.github/workflows/ubuntu-ci.yml b/.github/workflows/ubuntu-ci.yml index 01861fccbc1..9a9d14443fb 100644 --- a/.github/workflows/ubuntu-ci.yml +++ b/.github/workflows/ubuntu-ci.yml @@ -1,4 +1,4 @@ -name: Fast-DDS Ubuntu CI +name: Fast DDS Ubuntu CI on: workflow_dispatch: diff --git a/.github/workflows/windows-ci.yml b/.github/workflows/windows-ci.yml index 0838b8fdde8..d33b39bb693 100644 --- a/.github/workflows/windows-ci.yml +++ b/.github/workflows/windows-ci.yml @@ -1,4 +1,4 @@ -name: Fast-DDS Windows CI +name: Fast DDS Windows CI on: workflow_dispatch: diff --git a/.settings/org.eclipse.cdt.codan.core.prefs b/.settings/org.eclipse.cdt.codan.core.prefs deleted file mode 100644 index 77386c23cbe..00000000000 --- a/.settings/org.eclipse.cdt.codan.core.prefs +++ /dev/null @@ -1,67 +0,0 @@ -eclipse.preferences.version=1 -org.eclipse.cdt.codan.checkers.errnoreturn=Warning -org.eclipse.cdt.codan.checkers.errnoreturn.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},implicit\=>false} -org.eclipse.cdt.codan.checkers.errreturnvalue=Error -org.eclipse.cdt.codan.checkers.errreturnvalue.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true}} -org.eclipse.cdt.codan.checkers.noreturn=Error -org.eclipse.cdt.codan.checkers.noreturn.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},implicit\=>false} -org.eclipse.cdt.codan.internal.checkers.AbstractClassCreation=Error -org.eclipse.cdt.codan.internal.checkers.AbstractClassCreation.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true}} -org.eclipse.cdt.codan.internal.checkers.AmbiguousProblem=Error -org.eclipse.cdt.codan.internal.checkers.AmbiguousProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true}} -org.eclipse.cdt.codan.internal.checkers.AssignmentInConditionProblem=Warning -org.eclipse.cdt.codan.internal.checkers.AssignmentInConditionProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true}} -org.eclipse.cdt.codan.internal.checkers.AssignmentToItselfProblem=Error -org.eclipse.cdt.codan.internal.checkers.AssignmentToItselfProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true}} -org.eclipse.cdt.codan.internal.checkers.CaseBreakProblem=Warning -org.eclipse.cdt.codan.internal.checkers.CaseBreakProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},no_break_comment\=>"no break",last_case_param\=>false,empty_case_param\=>false} -org.eclipse.cdt.codan.internal.checkers.CatchByReference=Warning -org.eclipse.cdt.codan.internal.checkers.CatchByReference.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},unknown\=>false,exceptions\=>()} -org.eclipse.cdt.codan.internal.checkers.CircularReferenceProblem=Error -org.eclipse.cdt.codan.internal.checkers.CircularReferenceProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true}} -org.eclipse.cdt.codan.internal.checkers.ClassMembersInitialization=Warning -org.eclipse.cdt.codan.internal.checkers.ClassMembersInitialization.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},skip\=>true} -org.eclipse.cdt.codan.internal.checkers.FieldResolutionProblem=Error -org.eclipse.cdt.codan.internal.checkers.FieldResolutionProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true}} -org.eclipse.cdt.codan.internal.checkers.FunctionResolutionProblem=Error -org.eclipse.cdt.codan.internal.checkers.FunctionResolutionProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true}} -org.eclipse.cdt.codan.internal.checkers.InvalidArguments=Error -org.eclipse.cdt.codan.internal.checkers.InvalidArguments.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true}} -org.eclipse.cdt.codan.internal.checkers.InvalidTemplateArgumentsProblem=Error -org.eclipse.cdt.codan.internal.checkers.InvalidTemplateArgumentsProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true}} -org.eclipse.cdt.codan.internal.checkers.LabelStatementNotFoundProblem=Error -org.eclipse.cdt.codan.internal.checkers.LabelStatementNotFoundProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true}} -org.eclipse.cdt.codan.internal.checkers.MemberDeclarationNotFoundProblem=Error -org.eclipse.cdt.codan.internal.checkers.MemberDeclarationNotFoundProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true}} -org.eclipse.cdt.codan.internal.checkers.MethodResolutionProblem=Error -org.eclipse.cdt.codan.internal.checkers.MethodResolutionProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true}} -org.eclipse.cdt.codan.internal.checkers.NamingConventionFunctionChecker=-Info -org.eclipse.cdt.codan.internal.checkers.NamingConventionFunctionChecker.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},pattern\=>"^[a-z]",macro\=>true,exceptions\=>()} -org.eclipse.cdt.codan.internal.checkers.NonVirtualDestructorProblem=Warning -org.eclipse.cdt.codan.internal.checkers.NonVirtualDestructorProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true}} -org.eclipse.cdt.codan.internal.checkers.OverloadProblem=Error -org.eclipse.cdt.codan.internal.checkers.OverloadProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true}} -org.eclipse.cdt.codan.internal.checkers.RedeclarationProblem=Error -org.eclipse.cdt.codan.internal.checkers.RedeclarationProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true}} -org.eclipse.cdt.codan.internal.checkers.RedefinitionProblem=Error -org.eclipse.cdt.codan.internal.checkers.RedefinitionProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true}} -org.eclipse.cdt.codan.internal.checkers.ReturnStyleProblem=-Warning -org.eclipse.cdt.codan.internal.checkers.ReturnStyleProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true}} -org.eclipse.cdt.codan.internal.checkers.ScanfFormatStringSecurityProblem=-Warning -org.eclipse.cdt.codan.internal.checkers.ScanfFormatStringSecurityProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true}} -org.eclipse.cdt.codan.internal.checkers.StatementHasNoEffectProblem=Warning -org.eclipse.cdt.codan.internal.checkers.StatementHasNoEffectProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},macro\=>true,exceptions\=>()} -org.eclipse.cdt.codan.internal.checkers.SuggestedParenthesisProblem=Warning -org.eclipse.cdt.codan.internal.checkers.SuggestedParenthesisProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},paramNot\=>false} -org.eclipse.cdt.codan.internal.checkers.SuspiciousSemicolonProblem=Warning -org.eclipse.cdt.codan.internal.checkers.SuspiciousSemicolonProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},else\=>false,afterelse\=>false} -org.eclipse.cdt.codan.internal.checkers.TypeResolutionProblem=Error -org.eclipse.cdt.codan.internal.checkers.TypeResolutionProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true}} -org.eclipse.cdt.codan.internal.checkers.UnusedFunctionDeclarationProblem=Warning -org.eclipse.cdt.codan.internal.checkers.UnusedFunctionDeclarationProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},macro\=>true} -org.eclipse.cdt.codan.internal.checkers.UnusedStaticFunctionProblem=Warning -org.eclipse.cdt.codan.internal.checkers.UnusedStaticFunctionProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},macro\=>true} -org.eclipse.cdt.codan.internal.checkers.UnusedVariableDeclarationProblem=Warning -org.eclipse.cdt.codan.internal.checkers.UnusedVariableDeclarationProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},macro\=>true,exceptions\=>("@(\#)","$Id")} -org.eclipse.cdt.codan.internal.checkers.VariableResolutionProblem=Error -org.eclipse.cdt.codan.internal.checkers.VariableResolutionProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true}} diff --git a/CMakeLists.txt b/CMakeLists.txt index ca781828ea4..5871f3b0326 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -29,9 +29,9 @@ endif() ############################################################################### # Project # ############################################################################### -project(fastrtps VERSION "2.14.1" LANGUAGES C CXX) +project(fastdds VERSION "3.0.0" LANGUAGES C CXX) -set(PROJECT_NAME_LARGE "Fast RTPS") +set(PROJECT_NAME_LARGE "Fast DDS") string(TOUPPER "${PROJECT_NAME}" PROJECT_NAME_UPPER) message(STATUS "Version: ${PROJECT_VERSION}") @@ -229,12 +229,12 @@ option(BUILD_SHARED_LIBS "Create shared libraries by default" ON) ############################################################################### include(${PROJECT_SOURCE_DIR}/cmake/common/eprosima_libraries.cmake) -# if we are building Fast-DDS as a static library we must load Fast-CDR as one +# if we are building Fast DDS as a static library we must load Fast-CDR as one if(NOT BUILD_SHARED_LIBS) set(FASTDDS_STATIC ON) endif() -eprosima_find_package(fastcdr REQUIRED) +eprosima_find_package(fastcdr 2 REQUIRED) eprosima_find_thirdparty(Asio asio VERSION 1.10.8) eprosima_find_thirdparty(TinyXML2 tinyxml2) @@ -477,7 +477,7 @@ if(BUILD_DOCUMENTATION) set(USE_DOT YES) endif() # Configure the template doxyfile for or specific project - configure_file(doxyfile.in ${PROJECT_BINARY_DIR}/doxyfile @ONLY IMMEDIATE) + configure_file(utils/doxygen/doxyfile.in ${PROJECT_BINARY_DIR}/doxyfile @ONLY IMMEDIATE) # Add custom target to run doxygen when ever the project is build add_custom_target(doxygen COMMAND "${DOXYGEN_EXECUTABLE}" "${PROJECT_BINARY_DIR}/doxyfile" @@ -497,7 +497,6 @@ if(BUILD_DOCUMENTATION) set(README_INSTALL_LOCATION "${DOC_INSTALL_DIR}") endif() - configure_file(doc/README.html.in ${README_LOCATION}/README.html @ONLY IMMEDIATE) ### ReadTheDocs ######################## if(NOT CHECK_DOCUMENTATION) @@ -557,7 +556,7 @@ install(FILES ${PROJECT_SOURCE_DIR}/LICENSE ) # Install xml validators -install(FILES ${PROJECT_SOURCE_DIR}/resources/xsd/fastRTPS_profiles.xsd +install(FILES ${PROJECT_SOURCE_DIR}/resources/xsd/fastdds_profiles.xsd DESTINATION ${DATA_INSTALL_DIR} COMPONENT xsd ) @@ -597,11 +596,6 @@ if(BUILD_DOCUMENTATION) COMPONENT documentation ) - install(FILES "${README_LOCATION}/README.html" - DESTINATION ${README_INSTALL_LOCATION} - COMPONENT documentation - ) - if(NOT CHECK_DOCUMENTATION) install(DIRECTORY ${PROJECT_BINARY_DIR}/doc/manual DESTINATION ${DOC_INSTALL_DIR} diff --git a/CTestJenkins.cmake b/CTestJenkins.cmake deleted file mode 100644 index 1c5bbfb15c7..00000000000 --- a/CTestJenkins.cmake +++ /dev/null @@ -1,88 +0,0 @@ -# Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -# -# Licensed 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 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -set(CTEST_SOURCE_DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}") -set(CTEST_BINARY_DIRECTORY "${CTEST_SOURCE_DIRECTORY}/build") -set(CTEST_TEST_TIMEOUT 300) - -site_name(CTEST_SITE) -set(CTEST_BUILD_NAME "${JENKINS_BUILD_NAME}") -set(CTEST_BUILD_OPTIONS "${JENKINS_BUILD_OPTIONS}") -set(CTEST_BUILD_CONFIGURATION "${JENKINS_BUILD_CONFIGURATION}") - -set(CTEST_MEMORYCHECK_COMMAND_OPTIONS "${CTEST_MEMORYCHECK_COMMAND_OPTIONS} --quiet --tool=memcheck --leak-check=yes --show-reachable=yes --num-callers=50 --xml=yes --xml-file=test_%p_memcheck.xml \"--suppressions=${CTEST_SOURCE_DIRECTORY}/valgrind.supp\"") - -set(CTEST_COVERAGE_C_FLAGS "-DCMAKE_C_FLAGS:STRING=-fwrapv -fprofile-arcs -ftest-coverage") -set(CTEST_COVERAGE_CXX_FLAGS "-DCMAKE_CXX_FLAGS:STRING=-fwrapv -fprofile-arcs -ftest-coverage") -set(CTEST_COVERAGE_EXE_LD_FLAGS "-DCMAKE_EXE_LINKER_FLAGS:STRING=-fprofile-arcs -ftest-coverage") -set(CTEST_COVERAGE_SHARED_LD_FLAGS "-DCMAKE_SHARED_LINKER_FLAGS:STRING=-fprofile-arcs -ftest-coverage") - -include(ProcessorCount) -ProcessorCount(NUMBER_PROCESSORS) -message("Number of processors: " ${NUMBER_PROCESSORS}) -if(NOT NUMBER_PROCESSORS EQUAL 0) - if(${JENKINS_GENERATOR} MATCHES "Unix Makefiles") - set(CTEST_BUILD_FLAGS "-j${NUMBER_PROCESSORS} -l${NUMBER_PROCESSORS}") - # Error using visual studio with multicore - #elseif(${JENKINS_GENERATOR} MATCHES "Visual Studio") - #set(CTEST_WIN_CXX_FLAGS "-DEPROSIMA_EXTRA_CMAKE_CXX_FLAGS:STRING=/MP") - endif() - set(CTEST_TEST_ARGS ${CTEST_TEST_ARGS} PARALLEL_LEVEL ${NUMBER_PROCESSORS}) -endif() - -# Check CMake version for QUIET parameter -if(${CMAKE_MAJOR_VERSION} GREATER 3 OR (${CMAKE_MAJOR_VERSION} EQUAL 3 AND ${CMAKE_MINOR_VERSION} GREATER 2)) - set(QUIET_ QUIET) -endif() - -ctest_empty_binary_directory(${CTEST_BINARY_DIRECTORY}) - -if(UNIX) - find_program(CTEST_COVERAGE_COMMAND NAMES gcov) - find_program(CTEST_MEMORYCHECK_COMMAND NAMES valgrind) -endif() - -set(CTEST_CONFIGURE_COMMAND "${CMAKE_COMMAND}") -set(CTEST_CONFIGURE_COMMAND "${CTEST_CONFIGURE_COMMAND} -DCMAKE_BUILD_TYPE=${CTEST_BUILD_CONFIGURATION}") -set(CTEST_CONFIGURE_COMMAND "${CTEST_CONFIGURE_COMMAND} ${CTEST_BUILD_OPTIONS}") -set(CTEST_CONFIGURE_COMMAND "${CTEST_CONFIGURE_COMMAND} ${CTEST_WIN_CXX_FLAGS}") -if(CTEST_COVERAGE_COMMAND AND NOT DISABLE_CTEST_COVERAGE) - set(CTEST_CONFIGURE_COMMAND "${CTEST_CONFIGURE_COMMAND} \"${CTEST_COVERAGE_C_FLAGS}\"") - set(CTEST_CONFIGURE_COMMAND "${CTEST_CONFIGURE_COMMAND} \"${CTEST_COVERAGE_CXX_FLAGS}\"") - set(CTEST_CONFIGURE_COMMAND "${CTEST_CONFIGURE_COMMAND} \"${CTEST_COVERAGE_EXE_LD_FLAGS}\"") - set(CTEST_CONFIGURE_COMMAND "${CTEST_CONFIGURE_COMMAND} \"${CTEST_COVERAGE_SHARED_LD_FLAGS}\"") -endif() -set(CTEST_CONFIGURE_COMMAND "${CTEST_CONFIGURE_COMMAND} \"${CTEST_SOURCE_DIRECTORY}\"") -set(CTEST_BUILD_COMMAND "${CMAKE_COMMAND} --build .") -if(WIN32) - set(CTEST_BUILD_COMMAND "${CTEST_BUILD_COMMAND} --config ${CTEST_BUILD_CONFIGURATION}") -endif() -set(CTEST_CONFIGURATION_TYPE ${CTEST_BUILD_CONFIGURATION}) - -ctest_start("${JENKINS_DASHBOARD}" ${QUIET_}) -ctest_configure(RETURN_VALUE CONFIGURING_RET_VALUE ${QUIET_}) -ctest_build(RETURN_VALUE BUILDING_RET_VALUE ${QUIET_}) -ctest_test(${QUIET_}) -if(CTEST_COVERAGE_COMMAND AND NOT DISABLE_CTEST_COVERAGE) - ctest_coverage(${QUIET_}) -endif() -if(CTEST_MEMORYCHECK_COMMAND AND NOT DISABLE_CTEST_MEMORYCHECK) - ctest_memcheck(EXCLUDE_LABEL NoMemoryCheck ${QUIET_}) -endif() - -if(NOT CONFIGURING_RET_VALUE AND NOT BUILDING_RET_VALUE) - message(0) -else() - message(255) -endif() diff --git a/QUALITY.md b/QUALITY.md index ccc06545d1e..2bcedf4de59 100644 --- a/QUALITY.md +++ b/QUALITY.md @@ -2,7 +2,7 @@ This document is a declaration of software quality for *eprosima Fast DDS* inspi # Quality Declaration -*eprosima Fast DDS* (formerly Fast RTPS) is a C++ implementation of the DDS (Data Distribution Service) standard of the OMG (Object Management Group). +*eprosima Fast DDS* is a C++ implementation of the DDS (Data Distribution Service) standard of the OMG (Object Management Group). eProsima Fast DDS implements the RTPS (Real Time Publish Subscribe) protocol, which provides publisher-subscriber communications over unreliable transports such as UDP, as defined and maintained by the Object Management Group (OMG) consortium. diff --git a/README.md b/README.md index 0e583c217e6..ef9df24fb1c 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ -[![Fast DDS](doc/images/fastdds_github_banner.png)](https://eprosima.com/index.php/products-all/eprosima-fast-dds) +[![Fast DDS](resources/images/fastdds_github_banner.png)](https://eprosima.com/index.php/products-all/eprosima-fast-dds)
@@ -20,11 +20,11 @@
FIWARE Robotics - License - Releases - Issues - Forks - Stars + License + Releases + Issues + Forks + Stars Documentation badge
Status @@ -37,20 +37,22 @@

-*eprosima Fast DDS* (formerly Fast RTPS) is a C++ implementation of the DDS (Data Distribution Service) standard of the OMG (Object Management Group). eProsima Fast DDS implements the RTPS (Real Time Publish Subscribe) protocol, which provides publisher-subscriber communications over unreliable transports such as UDP, -as defined and maintained by the Object Management Group (OMG) consortium. RTPS is also the wire interoperability protocol defined for the Data Distribution -Service (DDS) standard. *eProsima Fast DDS* expose an API to access directly the RTPS protocol, giving the user full access to the protocol internals. + +> [!WARNING] +> **In preparation for v3.0.0, Fast DDS' master branch is undergoing major changes entailing API breaks.** +> **Until Fast DDS v3.0.0 is released, it is strongly advisable to use the latest stable branch, [2.14.x](https://github.com/eProsima/Fast-DDS/tree/2.14.x)**. + +*eprosima Fast DDS* is a C++ implementation of the DDS (Data Distribution Service) standard of the OMG (Object Management Group). +eProsima Fast DDS implements the RTPS (Real Time Publish Subscribe) protocol, which provides publisher-subscriber communications over unreliable transports such as UDP, as defined and maintained by the Object Management Group (OMG) consortium. +RTPS is also the wire interoperability protocol defined for the Data Distribution Service (DDS) standard. +*eProsima Fast DDS* expose an API to access directly the RTPS protocol, giving the user full access to the protocol internals. Some of the main features of this library are: -* Configurable best-effort and reliable publish-subscribe communication policies for real-time -applications. -* Plug and play connectivity so that any new applications are automatically discovered by any other -members of the network. -* Modularity and scalability to allow continuous growth with complex and simple devices in the -network. -* Configurable network behavior and interchangeable transport layer: Choose the best protocol and -system input/output channel combination for each deployment. +* Configurable best-effort and reliable publish-subscribe communication policies for real-time applications. +* Plug and play connectivity so that any new applications are automatically discovered by any other members of the network. +* Modularity and scalability to allow continuous growth with complex and simple devices in the network. +* Configurable network behavior and interchangeable transport layer: Choose the best protocol and system input/output channel combination for each deployment. * Two API Layers: a high-level Publisher-Subscriber one focused on usability (DDS) and a lower-level Writer-Reader one that provides finer access to the inner workings of the RTPS protocol. *eProsima Fast DDS* has been adopted by multiple organizations in many sectors including these important cases: @@ -58,8 +60,8 @@ system input/output channel combination for each deployment. * Robotics: ROS (Robotic Operating System) as their default middleware for every ROS 2 long term (LTS) releases and most of the non-LTS releases. * EU R&D: FIWARE Incubated GE. -This project is part of [FIWARE](https://www.fiware.org/). For more information check the FIWARE Catalogue entry for -[Robotics](https://github.com/Fiware/catalogue/tree/master/robotics). +This project is part of [FIWARE](https://www.fiware.org/). +For more information check the FIWARE Catalogue entry for [Robotics](https://github.com/Fiware/catalogue/tree/master/robotics). ## Want us to share your project with the community? @@ -96,13 +98,13 @@ You can access the documentation online, which is hosted on [Read the Docs](http ## Quality Declaration -*eprosima Fast DDS* claims to be in the **Quality Level 1** category based on the guidelines provided by -[ROS 2](https://ros.org/reps/rep-2004.html). +*eprosima Fast DDS* claims to be in the **Quality Level 1** category based on the guidelines provided by [ROS 2](https://ros.org/reps/rep-2004.html). See the [Quality Declaration](https://github.com/eProsima/Fast-DDS/blob/master/QUALITY.md) for more details. ## Quick Demo -eProsima provides the eProsima Fast DDS Suite Docker image for those who want a quick demonstration of Fast-DDS running on an Ubuntu platform. It can be downloaded from [eProsima's downloads page](https://eprosima.com/index.php/downloads-all). +eProsima provides the eProsima Fast DDS Suite Docker image for those who want a quick demonstration of Fast DDS running on an Ubuntu platform. +It can be downloaded from [eProsima's downloads page](https://eprosima.com/index.php/downloads-all). This Docker image was built for Ubuntu 20.04 (Focal Fossa). @@ -125,54 +127,44 @@ This Docker Image comes bundled with the following: ### Shapes Demo -eProsima Shapes Demo is an application in which Publishers and Subscribers are shapes of different -colors and sizes moving on a board. Each shape refers to its own topic: Square, Triangle or Circle. -A single instance of the eProsima Shapes Demo can publish on or subscribe to several topics at a -time. +eProsima Shapes Demo is an application in which Publishers and Subscribers are shapes of different colors and sizes moving on a board. +Each shape refers to its own topic: Square, Triangle or Circle. +A single instance of the eProsima Shapes Demo can publish on or subscribe to several topics at a time. -You can read more about this application on the -[Shapes Demo documentation page](https://eprosima-shapes-demo.readthedocs.io/). +You can read more about this application on the [Shapes Demo documentation page](https://eprosima-shapes-demo.readthedocs.io/). To run this application once inside the Docker container run: $ ShapesDemo -eProsima Shapes Demo usage information can be found on the -[Shapes Demo First Steps page](https://eprosima-shapes-demo.readthedocs.io/en/latest/first_steps/first_steps.html). +eProsima Shapes Demo usage information can be found on the [Shapes Demo First Steps page](https://eprosima-shapes-demo.readthedocs.io/en/latest/first_steps/first_steps.html). ### Fast DDS Monitor -eProsima Fast DDS Monitor is a graphical desktop application aimed at monitoring DDS environments -deployed using the *eProsima Fast DDS* library. Thus, the user can monitor in real time the status -of publication/subscription communications between DDS entities. They can also choose from a wide -variety of communication parameters to be measured (latency, throughput,packet loss, etc.), as well -as record and compute in real time statistical measurements on these parameters (mean, variance, -standard deviation, etc.). +eProsima Fast DDS Monitor is a graphical desktop application aimed at monitoring DDS environments deployed using the *eProsima Fast DDS* library. +Thus, the user can monitor in real time the status of publication/subscription communications between DDS entities. +They can also choose from a wide variety of communication parameters to be measured (latency, throughput,packet loss, etc.), as well as record and compute in real time statistical measurements on these parameters (mean, variance, standard deviation, etc.). -You can read more about this application on the -[Fast DDS Monitor documentation page](https://fast-dds-monitor.readthedocs.io/). +You can read more about this application on the [Fast DDS Monitor documentation page](https://fast-dds-monitor.readthedocs.io/). To run this application once inside the Docker container run: $ fastdds_monitor -eProsima Fast DDS Monitor usage information can be found on the -[Fast DDS Monitor User Manual]( -https://fast-dds-monitor.readthedocs.io/en/latest/rst/user_manual/initialize_monitoring.html). +eProsima Fast DDS Monitor usage information can be found on the [Fast DDS Monitor User Manual](https://fast-dds-monitor.readthedocs.io/en/latest/rst/user_manual/initialize_monitoring.html). ### Fast DDS libraries and Examples -Included in this Docker container is a set of binary examples that showcase several functionalities of the -Fast DDS libraries. These examples' path can be accessed from a terminal by typing +Included in this Docker container is a set of binary examples that showcase several functionalities of the Fast DDS libraries. +These examples' path can be accessed from a terminal by typing $ goToExamples -From this folder you can access all examples, both for DDS and RTPS. We detail the steps to launch two such -examples below. +From this folder you can access all examples, both for DDS and RTPS. +We detail the steps to launch two such examples below. -To launch the Hello World example (a minimal example that will perform a Publisher/Subscriber match and start -sending samples) you could run: +To launch the Hello World example (a minimal example that will perform a Publisher/Subscriber match and start sending samples) you could run: $ goToExamples $ cd dds/HelloWorldExample/bin @@ -180,8 +172,8 @@ sending samples) you could run: split-window "./HelloWorldExample subscriber" \; \ select-layout even-vertical -This example is not constrained to the current instance. It's possible to run several instances of this -container to check the communication between them by running the following from each container. +This example is not constrained to the current instance. +It is possible to run several instances of this container to check the communication between them by running the following from each container. $ goToExamples $ cd dds/HelloWorldExample/bin @@ -193,9 +185,9 @@ or $ cd dds/HelloWorldExample/bin $ ./HelloWorldExample subscriber -Another example you could launch is the Benchmark example. This example creates either a Publisher or a Subscriber and -on a successful match starts sending samples. After a few seconds the process that launched the Publisher will show -a report with the number of samples transmitted. +Another example you could launch is the Benchmark example. +This example creates either a Publisher or a Subscriber and on a successful match starts sending samples. +After a few seconds the process that launched the Publisher will show a report with the number of samples transmitted. On the subscriber side, run: @@ -235,5 +227,4 @@ More information: rosin-project.eu eu_flag -This project has received funding from the European Union’s Horizon 2020 -research and innovation programme under grant agreement no. 732287. +This project has received funding from the European Union’s Horizon 2020 research and innovation programme under grant agreement no. 732287. diff --git a/UPGRADING.md b/UPGRADING.md index 59a4631d489..d9344f7438c 100644 --- a/UPGRADING.md +++ b/UPGRADING.md @@ -1,6 +1,6 @@ Upgrading from previous versions ================================ -If you have used *fastrtpsgen* to generate part of your code, it is always *recommended* to regenerate it. +If you have used *fastddsgen* to generate part of your code, it is always *recommended* to regenerate it. When upgrading from a version older than 1.7.0, regeneration is **required**. diff --git a/build_qnx/common.mk b/build_qnx/common.mk index e5bbef9c544..b9d694d8cb9 100644 --- a/build_qnx/common.mk +++ b/build_qnx/common.mk @@ -12,7 +12,7 @@ NAME=Fast-DDS FAST-DDS_INSTALL_ROOT ?= $(INSTALL_ROOT_$(OS)) # These commands require GNU Make -FAST-DDS_CMAKE_VERSION = $(shell bash -c "grep VERSION $(PROJECT_ROOT)/../CMakeLists.txt | grep fastrtps ") +FAST-DDS_CMAKE_VERSION = $(shell bash -c "grep VERSION $(PROJECT_ROOT)/../CMakeLists.txt | grep fastdds ") FAST-DDS_VERSION = .$(subst $\",,$(word 3,$(FAST-DDS_CMAKE_VERSION))) #choose Release or Debug diff --git a/cmake/modules/FindTinyXML2.cmake b/cmake/modules/FindTinyXML2.cmake index 44b8e645758..c05986ad7f9 100644 --- a/cmake/modules/FindTinyXML2.cmake +++ b/cmake/modules/FindTinyXML2.cmake @@ -2,7 +2,7 @@ # TINYXML2_INCLUDE_DIR # TINYXML2_SOURCE_DIR -option(TINYXML2_FROM_SOURCE "Integrate TinyXML2 source code inside Fast RTPS" OFF) +option(TINYXML2_FROM_SOURCE "Integrate TinyXML2 source code inside Fast DDS" OFF) # Option for evaluating whether we are looking in for tinyxml2 in submodule set(TINYXML2_FROM_THIRDPARTY OFF) diff --git a/cmake/packaging/Config.cmake.in b/cmake/packaging/Config.cmake.in index 01693a9a802..ea462700f8f 100644 --- a/cmake/packaging/Config.cmake.in +++ b/cmake/packaging/Config.cmake.in @@ -16,7 +16,7 @@ set(@PROJECT_NAME@_VERSION @PROJECT_VERSION@) @PACKAGE_INIT@ -@FASTRTPS_PACKAGE_OPT_BIN_DIR_CONDITION@ +@FASTDDS_PACKAGE_OPT_BIN_DIR_CONDITION@ set_and_check(@PROJECT_NAME@_BIN_DIR "@PACKAGE_BIN_INSTALL_DIR@") endif() set_and_check(@PROJECT_NAME@_INCLUDE_DIR "@PACKAGE_INCLUDE_INSTALL_DIR@") @@ -25,67 +25,67 @@ set_and_check(@PROJECT_NAME@_LIB_DIR "@PACKAGE_LIB_INSTALL_DIR@") find_package(fastcdr REQUIRED) find_package(foonathan_memory REQUIRED) find_package(TinyXML2 QUIET) -@FASTRTPS_INSTALLER_DEPS_ANCILLARY@ -@FASTRTPS_PACKAGE_UNIX_OPT_DEPS@ +@FASTDDS_INSTALLER_DEPS_ANCILLARY@ +@FASTDDS_PACKAGE_UNIX_OPT_DEPS@ -set(fastrtps_known_comps static shared) -set(fastrtps_comp_static NO) -set(fastrtps_comp_shared NO) -foreach (fastrtps_comp IN LISTS ${CMAKE_FIND_PACKAGE_NAME}_FIND_COMPONENTS) - if (fastrtps_comp IN_LIST fastrtps_known_comps) - set(fastrtps_comp_${fastrtps_comp} YES) +set(fastdds_known_comps static shared) +set(fastdds_comp_static NO) +set(fastdds_comp_shared NO) +foreach (fastdds_comp IN LISTS ${CMAKE_FIND_PACKAGE_NAME}_FIND_COMPONENTS) + if (fastdds_comp IN_LIST fastdds_known_comps) + set(fastdds_comp_${fastdds_comp} YES) else () set(${CMAKE_FIND_PACKAGE_NAME}_NOT_FOUND_MESSAGE - "fastrtps does not recognize component `${fastrtps_comp}`.") + "fastdds does not recognize component `${fastdds_comp}`.") set(${CMAKE_FIND_PACKAGE_NAME}_FOUND FALSE) return() endif () endforeach () -if (fastrtps_comp_static AND fastrtps_comp_shared) +if (fastdds_comp_static AND fastdds_comp_shared) set(${CMAKE_FIND_PACKAGE_NAME}_NOT_FOUND_MESSAGE - "fastrtps `static` and `shared` components are mutually exclusive.") + "fastdds `static` and `shared` components are mutually exclusive.") set(${CMAKE_FIND_PACKAGE_NAME}_FOUND FALSE) return() endif () -set(fastrtps_static_targets "${CMAKE_CURRENT_LIST_DIR}/fastrtps-static-targets.cmake") -set(fastrtps_shared_targets "${CMAKE_CURRENT_LIST_DIR}/fastrtps-shared-targets.cmake") +set(fastdds_static_targets "${CMAKE_CURRENT_LIST_DIR}/fastdds-static-targets.cmake") +set(fastdds_shared_targets "${CMAKE_CURRENT_LIST_DIR}/fastdds-shared-targets.cmake") -macro(fastrtps_load_targets type) - if (NOT EXISTS "${fastrtps_${type}_targets}") +macro(fastdds_load_targets type) + if (NOT EXISTS "${fastdds_${type}_targets}") set(${CMAKE_FIND_PACKAGE_NAME}_NOT_FOUND_MESSAGE - "fastrtps `${type}` libraries were requested but not found.") + "fastdds `${type}` libraries were requested but not found.") set(${CMAKE_FIND_PACKAGE_NAME}_FOUND FALSE) return() endif () # find related dependency packages like OpenSSL - @FASTRTPS_INSTALLER_OPT_DEPS@ - @FASTRTPS_PACKAGE_WIN32_OPT_DEPS@ + @FASTDDS_INSTALLER_OPT_DEPS@ + @FASTDDS_PACKAGE_WIN32_OPT_DEPS@ - include("${fastrtps_${type}_targets}") + include("${fastdds_${type}_targets}") endmacro() -if (fastrtps_comp_static) - fastrtps_load_targets(static) -elseif (fastrtps_comp_shared) - fastrtps_load_targets(shared) -elseif (DEFINED fastrtps_SHARED_LIBS AND fastrtps_SHARED_LIBS) - fastrtps_load_targets(shared) -elseif (DEFINED fastrtps_SHARED_LIBS AND NOT fastrtps_SHARED_LIBS) - fastrtps_load_targets(static) +if (fastdds_comp_static) + fastdds_load_targets(static) +elseif (fastdds_comp_shared) + fastdds_load_targets(shared) +elseif (DEFINED fastdds_SHARED_LIBS AND fastdds_SHARED_LIBS) + fastdds_load_targets(shared) +elseif (DEFINED fastdds_SHARED_LIBS AND NOT fastdds_SHARED_LIBS) + fastdds_load_targets(static) elseif (BUILD_SHARED_LIBS) - if (EXISTS "${fastrtps_shared_targets}") - fastrtps_load_targets(shared) + if (EXISTS "${fastdds_shared_targets}") + fastdds_load_targets(shared) else () - fastrtps_load_targets(static) + fastdds_load_targets(static) endif () else () - if (EXISTS "${fastrtps_static_targets}") - fastrtps_load_targets(static) + if (EXISTS "${fastdds_static_targets}") + fastdds_load_targets(static) else () - fastrtps_load_targets(shared) + fastdds_load_targets(shared) endif () endif () diff --git a/cmake/packaging/windows/fastrtps-config.cmake b/cmake/packaging/windows/fastdds-config.cmake similarity index 78% rename from cmake/packaging/windows/fastrtps-config.cmake rename to cmake/packaging/windows/fastdds-config.cmake index ee4a8b9ad95..f8b17d560d1 100644 --- a/cmake/packaging/windows/fastrtps-config.cmake +++ b/cmake/packaging/windows/fastdds-config.cmake @@ -16,8 +16,8 @@ if(MSVC_VERSION LESS_EQUAL 1900) message(FATAL_ERROR "Visual Studio version ${MSVC_VERSION} is no longer supported") else() if(CMAKE_CL_64) - include("${CMAKE_CURRENT_LIST_DIR}/../share/fastrtps-x64Win64VS2019/cmake/fastrtps-config.cmake") + include("${CMAKE_CURRENT_LIST_DIR}/../share/fastdds-x64Win64VS2019/cmake/fastdds-config.cmake") else() - include("${CMAKE_CURRENT_LIST_DIR}/../share/fastrtps-i86Win32VS2019/cmake/fastrtps-config.cmake") + include("${CMAKE_CURRENT_LIST_DIR}/../share/fastdds-i86Win32VS2019/cmake/fastdds-config.cmake") endif() endif() diff --git a/cmake/packaging/windows/fastrtps.manifest.in b/cmake/packaging/windows/fastdds.manifest.in similarity index 100% rename from cmake/packaging/windows/fastrtps.manifest.in rename to cmake/packaging/windows/fastdds.manifest.in diff --git a/colcon.pkg b/colcon.pkg index d71654b9523..8e78ca24b51 100644 --- a/colcon.pkg +++ b/colcon.pkg @@ -1,5 +1,5 @@ { - "name": "fastrtps", + "name": "fastdds", "type": "cmake", "dependencies" : ["fastcdr", "FOONATHAN_MEMORY", "foonathan_memory_vendor", "googletest-distribution"] } diff --git a/doc/README.html.in b/doc/README.html.in deleted file mode 100644 index 95c615285c0..00000000000 --- a/doc/README.html.in +++ /dev/null @@ -1,1273 +0,0 @@ - - - - - - - - - -



- - - - - - - - - - -
-

eProsima
Plaza de la Encina 10-11
Nucleo 4, 2ª Planta
28760 Tres Cantos (Madrid)

-
-

-

-

Fast DDS v@PROJECT_VERSION@

-

Email: support@eprosima.com
Phone: +34 91 804 34 48
www.eprosima.com

-
-


-

-Available documentation:

-


-

-Local:

-


- -


-

Online (updated frequently):

-


- -


-


-

Copyright© 2019 eProsima. All rights reserved.

-

This copy of eProsima Fast DDS is licensed to you under the terms described in the LICENSE file included in this distribution.

- - diff --git a/doc/design/intra-process.md b/doc/design/intra-process.md deleted file mode 100644 index 89ee6c7ea93..00000000000 --- a/doc/design/intra-process.md +++ /dev/null @@ -1,93 +0,0 @@ -# Intra-process delivery - -Several requirements, each with a section. - -## Identifying local endpoints -Endpoints on the same process have the same content on the first 8 octets of their GUID prefix. - -### GUID_t refactor -* Provide methods `is_builtin()`, `is_on_same_process_as(other_guid)` and `is_on_same_host_as(other_guid)` -* Consider other improvements - * Split Guid.h into three headers (guid, prefix and entity_id) - * Converting EntityId_t to uint32_t - * Use a union on GuidPrefix_t to efficiently compare parts of it - -### Getting pointers to local endpoints -* Add methods on RTPSDomain to return a pointer to reader/writer given its guid -* Should be aware of builtin endpoints - -## Intra-process reception -The processing of new data on the subscribers is performed by the thread writing the data. -This thread is in charge of copying the `CacheChange_t` into the `ReaderHistory` and calling `NotifyChanges()`. -This decision was taken to maintain consistence with how currently operate the reception threads coming from transport -layer. - -User's documentation should make clear any user's listener registered to be informed about new changes implies having -blocked both the transport's reception threads and threads which write data. -Also should explain there is another mechanism to read samples, using the function `wait_for_unread_samples()` from the -user's thread and then taking/reading them. - -Current Reader API will be used by local writers to deliver data. The local writer will call `processDataMsg` directly. - -## Readers: management of local writers -When matching a writer, the reader should check if it is on the same process. - -**Considerations at destruction time** - -Until now a reader was safe to be destructed because we are sure that no thread will access it. This is possible because: - -* All events which use the reader were destructed first. Then the event thread will never access the reader. -* The reader was deregistered from the `ReceiverResource` objects. Then any reception thread will never access the -reader. - -Now a reader can be accessed by a writer from the local process. But it was accessed if there was a match with the -writer using discovery. Therefore, we should make sure there will be an unmatch with the writer using discovery before -the reader is destructed. And this unmatch will be instantly because the EDP builtin endpoints will use intraprocess -mechanism. - -### StatefulReader -No output traffic to local writers should be performed. -* Changes on WriterProxy - * `remote_locators_shrinked` should return an empty vector for local writers - * Timed event `heartbeat response` should never be started for local writers - * Timed event `initial acknack` should directly call `process_acknack` on the local writer - -## Writers: management of local readers -When matching a reader, the writer should check if it is on the same process. -* No output traffic to local readers should be performed. -* Samples are sent to local readers using `processDataMsg`. -* When a local reader is matched, and transient_local durability is used, the reader should automatically receive data -with `processDataMsg`. - -### StatelessWriter -* On ReaderLocator::start, no locators should be added when the reader is local - -### StatefulWriter -* Samples sent to local readers are automatically acknowledged -* Gaps sent to local readers should directly call `processGapMsg` -* Heartbeats sent to local readers should directly call `processHeartbeatMsg` -* Timed events should never be started for local readers, except for an `initial heartbeat` - -## Discovery process - -### Participant discovery (PDP) -In order to keep the sepparation of domains while on the same process, we will leave participant discovery to the standard mechanism. -No intraprocess delivery will be used for builtin PDP readers and writers. - -### Endpoint discovery (EDP) -We will leave endpoint discovery to the standard mechanism, but builtin endpoints will use the new mechanism to -send/receive `WriterProxyData` and `ReaderProxyData` to/from the ones on the local process. - -## Additional considerations - -### Security -If we rely on the comparison of the GUID to identify endpoints on the same process, those belonging to a secured participant will not be taken into account, as in that case the GUID is recalculated using a hash of the whole participant GUID. - -### Liveliness -No changes are necessary for the liveliness assertion mechanism, except that manual_by_topic assertions should directly call `processHeartbeatMsg` on local readers. - -### Side effects - -* This design isolates all message traffic from the wire, that is, tools like **wireshark™** will become useless. Given that most of our customers actually run intraprocess code, and report their issues using **wireshark™** traces, these changes will create a support nightmare. A workaround may be to supply a flag to inhibits the intraprocess behavior for debugging purposes, stating clearly, that it should be turn off during performance test. - -* Once a shared memory transport is developed for interprocess purposes, an intraprocess mechanism would be pointless. That's because the trade off between speed gain and source complexity would be very expensive. From memory consumption point of view using an interprocess discovery database would yield more benefits that having per-process discovery databases. diff --git a/doc/design/shared-memory-transport/interprocess_shared_mem.md b/doc/design/shared-memory-transport/interprocess_shared_mem.md deleted file mode 100644 index 1f650474a1e..00000000000 --- a/doc/design/shared-memory-transport/interprocess_shared_mem.md +++ /dev/null @@ -1,105 +0,0 @@ -# Interprocess Shared Memory model - -## Overview - -This document describes a model for interprocess shared memory communication of software components interchanging data messages. The objective of the model is to provide a shared memory based transport layer suitable for a Real-time Publish-Subscribe DDS (Data Distribution Service). - -## Context - -eProsima has received commercial proposals to implement a shared memory transport as an improvement of its FastRPTS product. The goals listed in this document are extracted from the customers proposals. - -### Improvements over the standard network transports - -* Reduce OS Kernel calls: This is unavoidable for transports like UDP / TCP (even with the loopback interface). -* Large message support: Network stacks needs to fragment large packets. -* Avoid data serialization / deserialization process: This is not possible in heterogeneous networks, but is possible in shared memory interprocess communication. -* Reduce memory copies: A buffer can be shared directly with several readers without additional copies. - -### Objectives - -* Increase the communications performance of processes in the same machine. -* Create a portable shared memory library (Windows / Linux / MacOS). -* Documentation. -* Tests -* Examples / Tutorials. - -## Architecture - -### Design concepts - -* **Segment**: Is a block of shared memory of fixed size that can be accessed from different processes. Shared memory segments have a global name so any process who knows the name can open the segment and map it in its address space. - -* **SegmentId**: SegmentIds are names that uniquely identify shared memory segments, these names are 16 characters UUIDs. - -* **Shared memory buffer**: Is a buffer allocated in the shared memory segment. - -* **Buffer descriptor**: Shared memory buffers can be referenced by buffers descriptors, these descriptors act like pointers to a buffer that can be copied between processes with a minimum cost. A descriptor contains the SegmentId and the offset to the data from the base of the segment. - -* **Shared memory port**: Is a communication channel identified by a port_id(uint32_t number). Through this channel, buffer descriptors are sent to other processes. It has a ring-buffer, in shared memory, where descriptors are stored. The same port can by opened by several processes for reading and writing operations. Multiple listeners can be registered in a port to be notified when descriptors are pushed to the ring-buffer. Multiple data producers can push descriptors to a port. The port contains an atomic counter with the number of listeners registered on it, each position in the ring-buffer has also a counter initialized to the number of listeners, as listeners read the descriptor, decrement the counter, so the ring-buffer position will be considered free when the counter is zero. The port also has an interprocess condition variable where the listeners will wait for incoming descriptors. - -* **Listener**: Listeners listen to descriptors pushed to a port. The Listener provides an interface for the application to wait and access to the data referenced by the descriptors. When a consumer pops a descriptor from the port listener, look at the descriptor's SegmentId field to open the origin shared memory segment (if not already opened in this process), once the origin segment is mapped locally, the consumer is able to access the data using the offset field contained in the descriptor. - -* **SharedMemoryManager**: Applications instantiate this object in order to access the shared memory resources described above. At least one per process memory manager is required. The manager provides functionality for the application to create shared memory segments, alloc data buffers in the segments, push buffer descriptors to shared memory ports and create listeners associated to a port. - -### Example scenario -![](interprocess_shared_mem1.png) - -Let's study the above example. There are three processes with a SharedMemManager per process, every process creates its own shared memory segment intended to store the buffers that will be shared with other processes. - -P1, P2 and P3 processes are participants in a RTPS-DDS environment. Discovery of participants is done by using multicast, so we have selected shared memory port0 as "multicast" port for discovery, therefore, first thing all participants do is to open the shared memory port0. A listener attached to port0 is created too, by every participant, to read the incoming descriptors. - -Each participant opens a port to receive unicast messages, ports 1, 2 and 3 respectively, and create listeners associated to those ports. - -The first message the participants send is the multicast discovery message: "I'm here, and I am listening on portN". So they alloc a buffer in its local segment, write that information to the buffer and push the buffer's descriptor through the port0. Observe how port0's ring-buffer store the descriptors to Data1a(P1), Data2a(P2), Data3a(P3) after all processes have pushed their discovery descriptors. - -After the discovery phase, participants know the other participants and their "unicast" ports so they can send messages to specific participants by pushing to the participant's unicast port. - -Finally, let's observe how P1 is sharing Data1c with P2 and P3, this is done by pushing the buffer descriptor to P2 and P3 unicast ports. This way one shared memory buffer can be shared with several processes without making any copy of the buffer (just copy the descriptors). This is an important improvement with respect to transports like UDP and TCP. - -### Design considerations - -* **Minimize global interprocess locks**: Interprocess locks are dangerous because, in the case one of the involved processes crashes while holding an interprocess lock, all the collaborating processes could be affected. In this design, pushing data to a port and reading data from the port are lock-free operations. For performance reasons waiting for data on a port, when the port is empty, requires interprocess lock mecanishms like mutexes and condition variables. This is specially dangerous in multicast ports because if one listener crashes while waiting this could block the port for the rest of the listeners. More complex design features could be added to make the library fault-tolerance, but it will possibly be at a cost of losing performance. - -* **Scalable number of processes**: Every process creates its own shared memory segments to store the locally generated messages. This is more scalable than having a global segment shared between all the involved processes. - -* **Per application / process customizable memory usage**: Again, a local shared memory segment allows to adapt the size of the segments to the requirements of the application. Imagine for example an application sending two types of data: Video and status info. It could create a big segment to store video frames, and a small segment for the status messages. - -### Future improvements - -* **Fault tolerance**: As stated in the design considerations, the possibility of a process crashing holding interprocess resources is real. Implementing fault tolerance for these cases is not an easy task. Timeouts, keep alive checks and garbage collectors are some of the things that could be added to the initial design in order to achieve fault tolerance. This will be considered in future revisions. - -### Mapping the design to FastRTPS - -#### Transport Layer - -* **Locators**: LOCATOR_KIND_SHM Is defined to identify shared memory transport endpoints. Locator_t fields are filled in this way: - * kind: 16 (Is the RTPS vendor-specific range). - * port: The locator's port contains the shared memory port_id. - * address: The whole address is set to 0 except for the first byte that is used to mark unicast (address[0]='U') or multicast (address[0]='M'). - -* **SharedMemTransportDescriptor**: The following values can be customized: - * segment_size: Size of the shared memory segment reserved by the transport. - * port_queue_capacity: Size, in number of messages, of the shared memory port message queue. - * port_overflow_policy: DISCARD or FAIL. - * segment_overflow_policy: DISCARD or FAIL - * max_message_size: By default max_message_size will be the segment_size, but is possible to specify a value <= segment_size. In that case fragmentation could occur. - -* **Default metatraffic multicast locator**: One locator, the port will be selected by the participant (will be the same as in the RTPS standard for UDP). - -* **Default metatraffic unicast locator**: One locator, the port will be selected by the participant (default port_id will be the same as in the RTPS standard for UDP). - -* **Default output locator**: There will be no default output locator. - -* **OpenInputChannel**: A SharedMemChannelResource instance will be created. An opened channels vector is maintained, if the same input locator is opened several times the channel instance is reused. - -* **OpenOutputChannel**: There will be only one SharedMemSenderResource instance per transport instance, an unordered_map of opened ports will be maintained by the SharedMemSenderResource object in order to match the destination locators to the shared memory ports. - -## Class design -![](interprocess_shared_mem2.png) - -#### RTPS Layer - -In FastRTPS transports are associated to participants, so the new SHM transport can used, by adding an instance of a SharedMemTransportDescriptor class to the list of participant's user transports. -So there is a shared memory segment per participant that will be shared by all participant's publishers. - -Transport selection: As RTPSParticipant is able to have multiple transports, a transport selection mecanishm is necessary when communicating with other participants reachable by several transports. The defined behaviour here is: If the participants involved are in the same host and both have SHM transport configured, then SHM transport is selected for all communications between those participants. diff --git a/doc/design/shared-memory-transport/interprocess_shared_mem1.png b/doc/design/shared-memory-transport/interprocess_shared_mem1.png deleted file mode 100644 index 3187e9ad53417abef858bf18a84c7f0546292af8..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 86126 zcmb4rbyQUA_x>4%5D^ANr9&lDVhHKHq96iNN=kSU5Q(7~dQb$BQo6gOb3hniB&C(^ z7)qJ}fuVl~ulIgG|Nhouu~;YG*zZ1jKl|Bx6R7?~k@6zLMF0ROl^#9N1OO-&0En0_ zkb+ml4cj~b00k&L`0FWhY^{zm_L+s-W}OKsoe3M1KAe2k^gdfCaX9%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SharedMemTransport { - ..Channel handling.. - +OpenOutputChannel() - +OpenInputChannel() - +Send() - .. - -input_channels_ -} - -struct(SharedMemTransportDescriptor) { - ..Interface implementation.. - +min_send_buffer_size() - +max_message_size() - ..Additional configuration.. - +segment_size - +port_queue_capacity - +port_overflow_policy -} - -class ChannelResource { - -} - -class SharedMemChannelResource { - +Receive() -} - -class SenderResource { -} - -class SharedMemSenderResource { - -locators_ports_map -} - -class SharedMemManager { - +create_segment() - +open_port() -} - -class SharedMemManager::Port { - +push() - +create_listener() -} - -class SharedMemManager::Listener { - +pop() -} - -TransportInterface ()-- SharedMemTransport -TransportDescriptorInterface ()-- SharedMemTransportDescriptor -ChannelResource <|-- SharedMemChannelResource -SharedMemTransport o-- SharedMemManager -SharedMemTransport "1" *-- "n" SharedMemChannelResource -SenderResource <|-- SharedMemSenderResource -SharedMemTransport "1" *-- "1" SharedMemSenderResource -SharedMemChannelResource "1" *-- "1" SharedMemManager::Listener : listen on -SharedMemManager::Listener "1" o-- "1" SharedMemManager::Port -SharedMemSenderResource "1" *-- "n" SharedMemManager::Port : send to - -@enduml -``` \ No newline at end of file diff --git a/doc/design/shared-memory-transport/interprocess_shared_mem2.png b/doc/design/shared-memory-transport/interprocess_shared_mem2.png deleted file mode 100644 index 67b022e7a30d2c8416aef0ce614e43cf308f48ed..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 37242 zcmc$`Wn9y3*anO(pmK|(l!9~)q)U{L7DlHqI;Ev8q(NdZ7@@>ykkPFIqd~fv3Zp|t z_j}@r?h+9Y5ZqLJDyvCAa4Cd<;G+5Ui{KR^ zAKwn}gWX+D&mHFc!rQ^p%AG*L(#g`*%-z!Bp1Jou8+Z2?V!XUB9L${DJscf)V9t)W z`9x{K3K_OqdhY+ePH+J%^D-q;Ytm`r(O>?i9cO&M2$f3tm>cvo;@@XEGTQv5hPUJ1 zCEy&dTQ{*;#9`|i3Eqn+_PpKfO%kx?5noV(=BXx&ShSj7RuO1;O*S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oos_63nIJfVv`t}_Yi(w+9elnqxdn0^TZgKzA2Dz zqZkwn9po>!F1mxP2yfHk?fPT51ONXDHWoG}&K~wA|4wzRk=xe|JlD7DZQB18WP#`> za~B&!TLTMgCno1VqiPd@@)00)tS`1g)N=K)~D#M$6YZ2U>})|YQybF6J*49^ijLEf%6 zuQ`7OT|VGp{H+fiRu1kzT<9?KuyL|TuyQlAiv4r%{mJ^@9rFCeIzA&-NL#4k0X4HRn)xToYf9LduQhx=7zv1*BnDyV8 z{cH20|AyH=W7t3V{P_(3S#Z9g*k54);PbbbrtlH+4<}l0GFBgux7IOlr@sF`v&9H} diff --git a/doc/pdf/Fast RTPS - Latency Test.odt b/doc/pdf/Fast RTPS - Latency Test.odt deleted file mode 100644 index b8de45281e66bb96e0d46d419f4ae4323780a2ea..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 153509 zcmdpdQ;=ps)8^Znwr$(Cr|s@(+qP}nw(ag|+qP}n+WG#Ce9 zMU+lvmb?@QC<*`o0RYgMFN*67Gr^Dp0D%9{zfS;bb8BNKcROQ!J3A|LLwzT6TN`>8 z8zVYfeMfUgI$Jwq8zWmoXKP~{Cpsr%Hz)c34U8kZP&1wY0Qe7K`~&-A=4@?Xqi=5I zNbmIDES;T=X}G+s7%UVP)W0UM65_uV|Gk?503ZMa@ITH&FfR%KAW)O|E%?VR>na;u z4@G&qx712z=GtTdnh-K5h^XtO5FH4$51DeD5HBnu6s#*z80AsEPmT}ucLx5h=_%=B z0fDw80#c$p5<$_*759$s@s(@};3h~;y#LF$^y2ceY4T(0=WEB4*%3+*0RyxRI%1s< zP$V1ZL%=c%AN1?pe^!7W0qYc82;@t^EDs+7_7NoC|Nm8C*@6#5KyMw*1cR)gpIllH z=RC|Ip@Qod0ab6QHUdYAGXxAcGR`ET?{6tQIOj!pb+|Abo(V3n5K~Nqfisc_Jpy;} zMG<};;?RVHWnUDj6Nzdad_9AMk1BG*F-rDT180YW9%6b$;{B4NBGk5Gc0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D>$XBX z&mYOw{Wj4+ufNFJ+}arEW@r3YDfW-K znlS_bz;kgxVv1pquZnm-LRQWu?RRKq0S*QR5qcrke}uNOjx;!i0|Pv_KSQ_TfWqm& zjGFy7XnGDNRt8Zr{uq${e693Lga0Xp z|CIdcr(YWWdab^Y1^?SB{wsX_K2Lt?e@6KkgP!NgFXH(Jlz$0l|NGG5{{i$@F#Gcq z{xy`p8aVh5D8GW+zoR^dw?B~F-`(`LVE6A}&tdBq@%#hWAA{fjisSSTIDZU=|Bmw< z4u4VkKj8d1IQ~1*pDo+{C!{|F%inQ+UQd5qlb^%oFT#HZ{?EblofOn>nd;~ObU+If L05C28d_n#{My91u diff --git a/doc/pdf/Fast RTPS - Throughput Test.odt b/doc/pdf/Fast RTPS - Throughput Test.odt deleted file mode 100644 index 0a1585ea441eab0ae4a958543ba0aefcb05338d5..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 148247 zcmdqHQ;=p&&@S4xZQHhO+qP|+@3f8S?&)dUwlQtnwsHFVPwb0xaW418-YX(wWz|!W zSs5!Uvuaf;$%2BR0Rce)0dZL`NEr;Xz)=DL0sTimT|oBM_U3NhPUgl=PIlI&#%|V* z4vZcSW(rcek1#bWcY6~D zV{1ECMz{aPGB`O{Mk^^u!o%Re{0xDYmJ(C>c{c$80RusS{BSA|xUqpH;iu>r8J?%50#T5J>IT%;u>oF^2;dVAlau-GETwg0jvfi8qd>?ta3YO?yS~m#mH61tHf>P7K z-}N0{R6PFlifk`A8*DGNaTQ=K{QDRJLrJ zl9G}d8`+eEd8~wlgyiJlMx5s&o>d2ZXHr5nv>$xG%>KB51U%>1^hJIk)kHZFN8y#F z!>Trap8>%RD($*3=Sb9DyYvATWO02K!psJDNiY>UvqZ#U$oXkK*Ln9-Q?d@3L?o)csn&prthV1SqId$5K-ASgRVoO1QT!q$- zM8D+#vhcZ%oFtadb3;hH8dtqR7mUJlLcUPI9ChBY`4@EAqhplj6z!e9NS)jOUNtTlnzt2W*{t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jEyxIL=J@}CqV*q8?9A+)jg9_)P-6cB%5R(gHx%N( zd8YS2pg1^!EM6km>3>7|yN{p$1CkTi2<-efoIhjZw-PU*@kjZ+{QtY~Q2o1)jZ93; zY|UP#4&=yU;_T>XW)J>r==|>i5c3~E9Y7Aw4!`~WKTaLle{1&A>iZ8kR(3`fFY8_0 z3T$WO;PhW$e_C2|V>t;21poxX{4<_ms9#ork-e3D!vRde0RZ=sFN+=Ue*o3fnZy79 diff --git a/doc/proposals/shared-memory-transport/sony/PubSub_overview.png b/doc/proposals/shared-memory-transport/sony/PubSub_overview.png deleted file mode 100755 index cfc2da4d0186bd476a2154ea9d9c6223317c1e6e..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 48256 zcma&N2RPgB_cv~|rL{*(?NzjPOAy4Si`b)9QALSSy9jEpgwj@Pq()I{6KWR`rKO4r zv15x}f*Akk=kxnMzyI}np67b5tF9(_-{ai(x$kpc=XK6I-aucM?h3~hGBPr{dv~>r z$jGR8NS_y|FOiXvb67e+NMFc(jC3`~%KN!iNM9~EtLv$gkyXKIj_og!zF+pbYw1Hq z#>RC1N8T&Et4c=JeD$7|x=Enz`Uzd-4fCMFcxHQToLdOfod#@ct6E=%mvq4QaP+|o ze0b}#GhZ)Axi^(>ri}lcBv;DG3txXGl{Z;&)AeA4@iN~Z3)&?`lRFOU2=-mOTO_1) z+2p9qXSL0w&B*jqe`<+|(d#H_3ZXRlY2`zY&?Tkm-tR2|i&O82&7NH>NRKY|Aau=`4QtdbuNZW5hiDt!dHcWA|GHVIxP2 zZ_-=rFv36kxje7~3~vzOuHud~e#fs*oI3#0tgv#G90>Mx{mAj7-o6()gXEeb%|CxQ za3BDFc%y#KQF-0!AT3!VnUwU(kagI9Kh7t+5?iiE2UdyNtkfi=}#Qr#Iu?Vh1@S97yaN*zZM(oq(V}hTU?3N zeX7#qNQAjvJw)>enbA)1-E>gSVn^sAc5}k~x@Wyq>p@U{Wt_5ybV9Ex-9Bh>jE#_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-dc#y+Ce6Yhj%xt(@$5H$qINYrLaJlj(j{aK1?Z@ z6pfq(vNfx8aSnvk#_#LYCE`{{yc%Q*G^hsn1%O80X|OZukH#zFCsRQ{MNaR-_Fu6l zfCWC+s5;%#i`(}8xlo9z^xHZALGtfsWh>kz3Sit8pavrFOld#jdPYIc4BX4} z5a=HL2oz8wLa0IieUOiy?CGatK9yqPS_j|AO;n_HHaP}-PZ9P mtjD}P+V5~uD`lxWc#8M08JymX#F~)+|1?x|lnWKDU;IDJn+bpb diff --git a/doc/proposals/shared-memory-transport/sony/RPC_overview.png b/doc/proposals/shared-memory-transport/sony/RPC_overview.png deleted file mode 100755 index d25009c43daee91af4b9e5478aa0bf16cda0b466..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 108738 zcmZ_0cRZEhVa|^!AU|w zDnLn2LUPX0cMS&o$2phR3Xe&OdO=ITKgcY>%3uuxT}VinFBAWq z>*CpxBOy7>dj16b*24gIY*TP+#50@fAjFS;fcy#gByGvb(`;<<8k=C}1^V0W;0{X6 za{RM-_*?zF*le7=P2T-mRF142k>8zbg5u38ZRwX;^SK$bV)ab4HNI9@zbd=);(7Ss zHQ3F#w-%p%De-LinWn_;Qma~s#+mWl<3UTTL>=`?8MZ+i+}qHlCQWqf$sDD_;Va=+ z`5GBYO;115Kc>9)Y-6491vee`@>c|2OQ#EcMeLSmWi+2s6MLa=nvtc=Qr-OYMc@WpzMC1~qU!_k|@% zt&zK%xJ?%Xlw+mCG=>lx?UM-#hR}#3Rf7eE-Z&}E-ZNB!SD0hR{kjMIR$+36m+m1| z2C~~rznyyab>m*#e@5$GntVvO@qL}SQk=f~r23rq z-2SiWA*UqtZbQiAwzlNrOA@VqZiFPITD;TX%}7Xdh?wY`pXqVU`Iu`pp){W`gj5=* zz`B@j8J|DyK}ezbj#G{aHd#rIX5lUl{to;3G#u|RIkoUqy5MTVF1k<2LZOsgZs*Nz z2+{yEv=O7%M!w&#mzf486=VD9qk`}eGh&-!D$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XSY1O)_#&`lLk2pzBG-qE*2JEd8!R&HOSi0OV%p^8SKo_wjp{07*08XScghVuYP_ zNWE#yNWWA1Y-C8GDO@`Dsk6LZGMJT1?pr6BxDCD^Q7py6cA`JYsL77dD;<62<}SKm zGocCLCEBz-Zt0D=e$mJw?iJ~`HtKePdwb>7R2Nj!(<=o?u3WD;Izg>Zu6i(mxc67f zho%XLFSu>n>5V%YJCINeJ*R71bu-lgbS*`32-#4{UtJY+QmC&}O5>L1?q=f$z8^Pv zil%>0slN>!`xFoRCdhMfz*&4WJS60z`+S0Y9EKtsrE7YDuv9@$f9EP{537G;jxKcK zoF0OmB1G&dj1QJRk{3YkA`Ubkd3ZoRvh@BjFo^NUT+!$2qCfD`%mTtDl)k9Y=RKx|P8t!WI8f6tqeU8Dczu+$_BiytU>#u$u^;(zhG>9A%=4T0wE zQyEZJs8c!O3Q-u}n2xKVmHu3DOl2E?T{`&k$p#`~K9=j);>yZdtdYSu0I0=tL1Nzsb~w zoV;!FK`A;r&sb2$)I2ZloS69co3CG94QFCBsad5CgP~0=%(U0X)$Gy6ZRU+FZ-F7g zxM){tHt}+6Sp$}&VV2Iq`!3TdiY&Dg(nQGVknO7ro0MAHfdLY5;8|V%U>f*XWyH4J zUP-5c7w9qqZP|&*TnD|;W^JFE4UITQjQ6x8#;rGc?EY-;g47RHSZX7W-%*85R5}?A zU4nL7YZalbgLnw(`+aFf|0q0w%ynl1nT_g8Y8rpk9nxlrH+hOd6eA#{D$$i+d7876>Hyr@;_9~uDk#M diff --git a/doc/proposals/shared-memory-transport/sony/improvement.png b/doc/proposals/shared-memory-transport/sony/improvement.png deleted file mode 100755 index b913dcdbf2d0835a906bddc6c06a7f67bd79f6c4..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 36300 zcmcG#byQp17c~kLDH613kV4T?td!vH-a?BPEi_1Qcc-{}DGsFM?;GD3@9&qfk}-1j&N(}K%{A9Lb0v{)H537OGg3|i$F?JnvK=4WYjX*9H&c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XkACc2u!P5 z-%_o(X*IJ6?unqs@60A@8-8HA;t9TT3wzv^#Wf2bAy78m5Z3ud-D7Nyzcor>#=)$Fhu#6o0a5BlPNI(95ZhTJrSZvbCVFT2NYfp!O~+G(o+eWzO&rUmON2kYuF)eQl=fHu`T=DuE1w0en2MQo zdjP|uaE)-|@U>TBR3(TR^xM}l!R~>6vcW2}dU-~ed1TEEA*p_3oBlGy;&H;nB2v7X zmx%2y=e+R4CwvahS)k*Gej^VD(r$6W6~Ph1^Y7_g&c1|HK!B{R8)XDON9&ER!HZ2B z>I{oLx|b3`$*skEaeTbJJWrcoZ@6r=$qWfQp$cnu`o)+?4%AjY_Ky&e=JeHcr7vL4 zaxkdHQ`#8|X=METS-EawM`Z8wIU*W*S%H$*`P<`v?WxK9Z0EpryQMh;rfp;1bMTt3 zUtsQZPTPes3s(bMhDLp*RGTqJmx?{peFN3w^_vCwSF0GvAIqi~KE$fa<$+)*1wwC6pvlVj>=-zcU+QF@| zqxPC6NVtLd{m+w-XxbR$if)2}g4ie>mbm6z2nO8j}F zdiwI5&A`RMhhHt_J?}q5($r$1<+%=K0l$Z?YTwe2vK3?+3m*KsH15eP|NCoa0owxC zDooyqPTm=_c;M|w)zu#x4gX(J;5iTC(Lk)dT!onYlFOV zrH zAo8rlBn|1{rE3LEbROQ%SaMH$?)C6?xz*~xZHk8v=Q*9d8*P($cye%4z56;DcRo<_ zfE_q+`lML$WU|WV;@rb(=Zkaufy}Oj diff --git a/doc/proposals/shared-memory-transport/sony/ms1_rtps_shared_memory_transport.md b/doc/proposals/shared-memory-transport/sony/ms1_rtps_shared_memory_transport.md deleted file mode 100755 index 6bce5cff89e..00000000000 --- a/doc/proposals/shared-memory-transport/sony/ms1_rtps_shared_memory_transport.md +++ /dev/null @@ -1,127 +0,0 @@ -# Overview - -DDSi-RTPS(Real-Time Publish-Subscribe) is the **protocol** that enable to support vendor implementation. And RTPS specifies implementaion and message packet format and other stuff as well. On this proposal, it will descibe how we could integrate **shared memory as transport** for RTPS layer based on. - -# Objective - -Implement a shared Memory transport using the current Fast-RTPS transport API & Architecture: The transport will be used as any other transport (including serialization and RTPS encapsulation). This approach is used in other DDS implementations such as commercial release for OpenSplice and RTI Connext DDS. This is mostly related to ROS2 RMW transport, but it can be used in any DDS application or product. - -# Requirements - -- Multi-Platform support (Windows, Linux and MacOS) along with ROS2. -- Design and Architecture Description -- Source Code [Fast-RTPS](https://github.com/eProsima/Fast-RTPS) -- Documents for user manual and tutorials. -- ROS2/RMW compatible interface (do not break ROS2 userland) -- Latency/Bandwidth improvement results. -- Intra/Inter-Process Communication - -# Architecture / Design - -## Interoperability - -There is no gurantee that the whole system is constructed with eProsima Fast-RTPS, so multiple DDS implementaions may be used in a distributed system. -To keep the interoperability between different vendor DDS implementations, the shared memory transport feature has to be implemented with the following: - -- All communications must take place using RTPS Messages. -- All implementations must implement the RTPS Message Receiver. -- Simple Participant and Endpoint Discovery Protocols. - -## Discovery - -Participant and Endpoint Discovery(PDP, EDP such as metatrrafic transmittion) will be kept as is in the current code, since this negotiation does not require shared memory use cases (all of the RTPS protocol stays put). - -## Memory Management - -- Dynamic Configuration - - Shared memory transport should be dynamically configured when necessary, that is, when the reader exists on the same host system than the writer. This is mandatory to reduce unnecessary message passing via shared memory. - - This can be detected using the GuidPrefix_t information in the locator, which includes vendor id, host id, process id and participant id. - - ``` - struct RTPS_DllAPI GuidPrefix_t - ``` - -- Lifecycle - - Shared memory lifecycle is managed by the writer corresponding to HistoryCache more likely QoS setting. - -- Owner - - Shared memory is owned by the writer. The writer is responsible of managing the shared memory (creation and removal) according to the aforementioned lifecycle. - -- Version - - Versioning must be used to check if the implementation supports the shared memory feature or not. - -## Shared Memory Framework - -Since this whole project is targeted to be multi-platform, it is mandatory not to use system dependent shared memory frameworks or primitives. - -- C/C++ implementation - - Primitive baseline implementation, can be used for multi-platform. - - But most parts need to be implemented by our own. - - Also good affinity to intra-process, just use std::shared_ptr. -- POSIX IPC shared memory (shm_open) - - This is only for Unix system, so not good affinity for Windows/Mac. -- **boost::interprocess** - - Surely multi-platform, this is generic and up-to-date interfaces. - - Generic shared memory interface - - Emulation layer available for windows and system v(xsi) if necessary. - - Memory mapped file (this can be useful to use ramfs to refresh system restart or reboot) - - Shared memory range can be truncated dynamically. - - Container mapping with allocator - - File locking (this could be useful to exclude access to the memory mapped shared memory) - - Writer has read_write mode and reader only has read_only mode. - - ***But cannot be extremly optimized via system calls, such as hugetlb to reduce TLB miss hit and pagefaults.*** - - -## Event Notification - -Writer needs to notify right after the shared memory is ready to be read on reader side. Then reader will be notified that data is ready to read out. - -- RTPS extensible message - - Submessages with ID's 0x80 to 0xff (inclusive) are vendor-specific - - But probably we should avoid sending messages via network. -- **boost::interprocess** - - Condition: after data is set by writer, notify the subscribers via condition variable on shared memory (named under topic name?). - - Semaphore: after data is set by writer, post to notify the subscribers via semaphore on shared memory. Can be used to control the number of subscribers to read via wait API (named under topic name?). - -## Security - -- Encryption / Decryption: - - Shared memory will be used as transport only, so encrypted data will be stored on shared memory. Therefore, this does not affect anything. -- Access Permission: - - Can we support access permission? Like file system based access permission? This needs to be considered. - - Since security implementation is different among platforms, boost::interprocess does not try to standardize the access permission control. This is responsibility of the implementation. - -## Quality of Service - -Since this is just a new implementation of the transport layer for shared memory, where all the rest of the RTPS protocol stays put, we expect full compatibility of configuration with Fast-RTPS. - -Nevertheless, this needs to be further considered during the detailed design and implementation. - -# Considerations - -## Intra Process Communication - -There is an intra-process communication feature in ROS2 rclcpp and rcl layer (basically zero-copy based). This has nothing to do with DDS implementation, but needs to be considered to ensure this feature doesn't break when implementing the DDS shared memory transport. Refer to [Intra-Process-Communication](https://index.ros.org//doc/ros2/Tutorials/Intra-Process-Communication/) - -Intra-process communication does not support QoS specification, e.g) RMW_QOS_POLICY_HISTORY_KEEP_ALL, !RMW_QOS_POLICY_DURABILITY_VOLATILE is not supported. - -Intra-process communication uses a ring buffer that is internally implemented [mapped_ring_buffer.hpp](https://github.com/ros2/rclcpp/blob/master/rclcpp/include/rclcpp/mapped_ring_buffer.hpp). - -**this implementataion will stay on rclcpp for other implementations, but will be decricated for eProsima Fast-RTPS use-cases basically.** - -## Container Boundary - -Using containers basically means to divide the user space into independent sections, so shared memory should not be used beyond the container boundary. - -This can be actually done just checking IP addresses to see if both participants are in the same host or not. So we don't expect addtional requirements, it just appears to be another network interface. - -# Reference - -[ROSConJP 2019 Lightning Talk Presentation](https://discourse.ros.org/uploads/short-url/1SbbxgRCiM6NH2BuSCqNAe0aogx.pdf) -[Boost.Interprocess](https://www.boost.org/doc/libs/1_71_0/doc/html/interprocess.html) - diff --git a/doc/proposals/shared-memory-transport/sony/ms2_rmw_shared_memory_data_share_sony.md b/doc/proposals/shared-memory-transport/sony/ms2_rmw_shared_memory_data_share_sony.md deleted file mode 100755 index f5c9770155d..00000000000 --- a/doc/proposals/shared-memory-transport/sony/ms2_rmw_shared_memory_data_share_sony.md +++ /dev/null @@ -1,87 +0,0 @@ -# Overview - -Sony has already done implementation using internal shared memory light framework to connect rmw layer, so that ROS2 applicatoin can use the shared memory publisher/subscriber framework without notice. This is the same target for milestone-2, so this documentation describe about the history and feasibilities, and also basic design for shared memory data sharing in linux system. - -# Background - -- We need to deal with a large amount of data for recognitions, robotics, intelligent processes like agent device. The data has to be shared among a lot of framework and process spaces, otherwise copy in/out system space overhead will stress the system resources. especially embedded devices, this could be fatal issue. -- It is impossible to complete the requirement with single process even if that is the embedded consumer devices. Data shall be shared in the host system efficiently so that application can use the data without concern. Besides data size is getting bigger and bigger such as 4K, 8K images, ToF, Lidar, Radar, PointCloud and so on. We surely need more band width/high latency data sharing against these situations. - -# Requirements - -### Publisher/Subscriber Architecture (N:N) - -![PubSub_overview](./PubSub_overview.png) - -Publisher: after system calls to map and create message on the filesystem, it will directly write the dat into the message. Then at the finish writing or closing file, that will be notified to the subscriber with file path. - -Subscriber: file path will be notified via inotify, the subscriber to get the corresponding message to open and read directly. - -**There will be no copy insluding user application or framework itself** - -### Remote Procedure Call Support (1:1 asynchronous, such as rosservice) - -![RPC_overview](./RPC_overview.png) - -Unique ID assigned for each message, so easy to recognize who’s message. - -- Perfectly Copyless Data Sharing -- Low Latency and High Throughput -- Message Lifecycle and Timestamp support -- Data Access Control via Filesystem -- Storage supported as backend (user flexibility) - -# Design - -## Platform - -Linux 2.6.13 or later (technically the platform supports [inotify](http://man7.org/linux/man-pages/man7/inotify.7.html)) - -## Data Channel - -Basically in-memory file system such as ramfs or tmpfs. but this is not a limitation or constraints, user can choose the backend file system to specify the root directory. ramfs and tmpfs is actually memory storage, but it can keep the file on the filesystem as long as system running. this would be also good, once the system reboots it will refresh the entire cache data, we can restart as clean. - -Taking advantage of linux interfaces such as map/unmap to assign the physical pages into the user process space, no additional overhead or stack will be provided from this framework. - -## Signal and Event Notification - -from our experience and benchmark on embedded linux system, [inotify](http://man7.org/linux/man-pages/man7/inotify.7.html) came up the candidate number 1. inotify is also provied by linux kernel and it allows us to notify events on filesystem and what kind of events and what file is actually changed.(written, closed or opened etc.) this is really simple linux kernel interface and also support message queue order guranteed by linux kernel. - -## Access Permission Control - -since this framework is constructed on filesystem based storage, we can control access permission just like we do with normal files and user/group permission control. without certain group or access permission, user cannot even see the files or any activities by this framework. - -## Datatype / Serialization - -Do not serialize data into the shared memory with publish/subscribe. So user application needs to be aware before to write/read the binary data fits in the certain structure. - -## Remarkable Features (Only Related) - -- Configurable parameters for each topic - root file path and ring buffer length to keep for each topic shall be predefined. -- Ring Buffer / File Mapped Shared Memory - Ring Buffer is controlled by framework, e.g) entries of single topic. -- Retain Memory - once the file is mapped into physical page, it will never unmapped unless it is necessary. - this will reduce the huge system time via system calls. -- Huge TLB - also reduce system time for cache miss, pagefaults and tlb miss hit. - -# Feasibilities - -With Sony internal framework and rmw_sony_cpp to connect the implementation to ROS2 frontend, there is a huge performance improvemnent that we have taking advantage of shared memory. - - - -of course this is only prototype and Non-DDS implementation which means in general there is not a lot of processes that is required with DDS implementation. But even anticipated value expectation in prototype, there is an improvement as followings. - - - -- Publisher:Subscriber = 1:1 -- Serializer is [Fast-CDR](https://github.com/eProsima/Fast-CDR) -- Ubuntu 18.04 ROS Dashing -- Skylake PC - -# Note - -This is just for sharing primitives, but we can work on this feature more generic way and keep the improvement as it is. diff --git a/doc/proposals/shared-memory-transport/sony/rmw_sony_cpp.png b/doc/proposals/shared-memory-transport/sony/rmw_sony_cpp.png deleted file mode 100755 index eda23ff7ecd242d2c5a3a8be7a255dc9ed8b881b..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 115480 zcmZ_01yohr7d}dNgM_4rgmiZ|(%m6~bO?tIX{EbUlsI&EiGb2whwkn}$J==C9q;#l zF&K=&UT2@R*PgZ3H@`Xgs;VrDiS`l=1_lOGUQS9K1_prv1_rJQ1qlWQ7L}lP6Zinu zMO{_`rhJ%e7q~$9D6S+915*`)es6{dT%$V4>AAqb5aB-m!uHdii^9M>{g9Uu*Yq$x zXhUvYkV-y&@)r~oY~d92IBQ4c!NBh%acb}Snn@SS3E#`pi@TlqTN0}`bt5>+QLJ~=lsT};=2o2;m7#cSW~?I?URj! z{?cP39$Ly)gUI|iB#D~35OH{QDEvz%p)&@q_Sr7+)4OwbiDCJ7z@Hzp`J5$Co1|mz zNUBz`lYIna+EhdzH2;oVnRin%neoZgV@{TU!Rk$76%kV|AJmh@vUVp5Yj~)$+-mgP z3wA&ogY4BwUX(s30bo>Dh~<2f%STRZn$6R45}O z<4~>Ra=SBmSw^xo#Y8A3Y5I)-Xs^FM}j^}l;`^k!U68c3mUI8hu zgJQL_(9K2y>Oh})z#NRbB7FjZ6`m`ElDhznn#7v$#q z(`9dMFo@YcPeFFtYi=dPu7p2EJL@J)6@LIGQuxj6weXsfeXm@Hg#26D!H!3-RNqwy*TskW;=)RRl|<+ld;`((3{dPaZ{kkeA$?{&toHV9VJfTrDW^tF{0W{G8MdL zd++xj`fl9cOI0v_j20)&DV~HhIOg=fXf(4_f!^XD1ef*Q2czQa3Kodls|vSdLI~%KjFi63 z5c&4aHn|ky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@@ -12,6 +12,6 @@ # See the License for the specific language governing permissions and # limitations under the License. -set(fastrtps_FOUND TRUE) +set(fastdds_FOUND TRUE) add_subdirectory(cpp/dds) add_subdirectory(cpp/rtps) diff --git a/examples/cpp/dds/AdvancedConfigurationExample/AdvancedConfiguration.cxx b/examples/cpp/dds/AdvancedConfigurationExample/AdvancedConfiguration.cxx deleted file mode 100644 index f423c3c9cc9..00000000000 --- a/examples/cpp/dds/AdvancedConfigurationExample/AdvancedConfiguration.cxx +++ /dev/null @@ -1,214 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file AdvancedConfiguration.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "AdvancedConfiguration.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - - - - - - -AdvancedConfiguration::AdvancedConfiguration() -{ -} - -AdvancedConfiguration::~AdvancedConfiguration() -{ -} - -AdvancedConfiguration::AdvancedConfiguration( - const AdvancedConfiguration& x) -{ - m_index = x.m_index; - m_message = x.m_message; - m_data = x.m_data; -} - -AdvancedConfiguration::AdvancedConfiguration( - AdvancedConfiguration&& x) noexcept -{ - m_index = x.m_index; - m_message = std::move(x.m_message); - m_data = std::move(x.m_data); -} - -AdvancedConfiguration& AdvancedConfiguration::operator =( - const AdvancedConfiguration& x) -{ - - m_index = x.m_index; - m_message = x.m_message; - m_data = x.m_data; - return *this; -} - -AdvancedConfiguration& AdvancedConfiguration::operator =( - AdvancedConfiguration&& x) noexcept -{ - - m_index = x.m_index; - m_message = std::move(x.m_message); - m_data = std::move(x.m_data); - return *this; -} - -bool AdvancedConfiguration::operator ==( - const AdvancedConfiguration& x) const -{ - return (m_index == x.m_index && - m_message == x.m_message && - m_data == x.m_data); -} - -bool AdvancedConfiguration::operator !=( - const AdvancedConfiguration& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void AdvancedConfiguration::index( - uint32_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint32_t AdvancedConfiguration::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint32_t& AdvancedConfiguration::index() -{ - return m_index; -} - - -/*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ -void AdvancedConfiguration::message( - const std::array& _message) -{ - m_message = _message; -} - -/*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ -void AdvancedConfiguration::message( - std::array&& _message) -{ - m_message = std::move(_message); -} - -/*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ -const std::array& AdvancedConfiguration::message() const -{ - return m_message; -} - -/*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ -std::array& AdvancedConfiguration::message() -{ - return m_message; -} - - -/*! - * @brief This function copies the value in member data - * @param _data New value to be copied in member data - */ -void AdvancedConfiguration::data( - const std::vector& _data) -{ - m_data = _data; -} - -/*! - * @brief This function moves the value in member data - * @param _data New value to be moved in member data - */ -void AdvancedConfiguration::data( - std::vector&& _data) -{ - m_data = std::move(_data); -} - -/*! - * @brief This function returns a constant reference to member data - * @return Constant reference to member data - */ -const std::vector& AdvancedConfiguration::data() const -{ - return m_data; -} - -/*! - * @brief This function returns a reference to member data - * @return Reference to member data - */ -std::vector& AdvancedConfiguration::data() -{ - return m_data; -} - - -// Include auxiliary functions like for serializing/deserializing. -#include "AdvancedConfigurationCdrAux.ipp" - -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/AdvancedConfigurationExample/AdvancedConfiguration.h b/examples/cpp/dds/AdvancedConfigurationExample/AdvancedConfiguration.hpp similarity index 67% rename from examples/cpp/dds/AdvancedConfigurationExample/AdvancedConfiguration.h rename to examples/cpp/dds/AdvancedConfigurationExample/AdvancedConfiguration.hpp index 207a02e1cd0..cf302de8bc8 100644 --- a/examples/cpp/dds/AdvancedConfigurationExample/AdvancedConfiguration.h +++ b/examples/cpp/dds/AdvancedConfigurationExample/AdvancedConfiguration.hpp @@ -13,32 +13,20 @@ // limitations under the License. /*! - * @file AdvancedConfiguration.h + * @file AdvancedConfiguration.hpp * This header file contains the declaration of the described types in the IDL file. * * This file was generated by the tool fastddsgen. */ -#include -#include "AdvancedConfigurationv1.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#ifndef _FAST_DDS_GENERATED_ADVANCEDCONFIGURATION_H_ -#define _FAST_DDS_GENERATED_ADVANCEDCONFIGURATION_H_ +#ifndef _FAST_DDS_GENERATED_ADVANCEDCONFIGURATION_HPP_ +#define _FAST_DDS_GENERATED_ADVANCEDCONFIGURATION_HPP_ #include -#include #include -#include -#include +#include #include -#include -#include -#include - - #if defined(_WIN32) #if defined(EPROSIMA_USER_DLL_EXPORT) @@ -64,19 +52,6 @@ #define ADVANCEDCONFIGURATION_DllAPI #endif // _WIN32 -namespace eprosima { -namespace fastcdr { -class Cdr; -class CdrSizeCalculator; -} // namespace fastcdr -} // namespace eprosima - - - - - - - /*! * @brief This class represents the structure AdvancedConfiguration defined by the user in the IDL file. * @ingroup AdvancedConfiguration @@ -88,73 +63,124 @@ class AdvancedConfiguration /*! * @brief Default constructor. */ - eProsima_user_DllExport AdvancedConfiguration(); + eProsima_user_DllExport AdvancedConfiguration() + { + } /*! * @brief Default destructor. */ - eProsima_user_DllExport ~AdvancedConfiguration(); + eProsima_user_DllExport ~AdvancedConfiguration() + { + } /*! * @brief Copy constructor. * @param x Reference to the object AdvancedConfiguration that will be copied. */ eProsima_user_DllExport AdvancedConfiguration( - const AdvancedConfiguration& x); + const AdvancedConfiguration& x) + { + m_index = x.m_index; + + m_message = x.m_message; + + m_data = x.m_data; + + } /*! * @brief Move constructor. * @param x Reference to the object AdvancedConfiguration that will be copied. */ eProsima_user_DllExport AdvancedConfiguration( - AdvancedConfiguration&& x) noexcept; + AdvancedConfiguration&& x) noexcept + { + m_index = x.m_index; + m_message = std::move(x.m_message); + m_data = std::move(x.m_data); + } /*! * @brief Copy assignment. * @param x Reference to the object AdvancedConfiguration that will be copied. */ eProsima_user_DllExport AdvancedConfiguration& operator =( - const AdvancedConfiguration& x); + const AdvancedConfiguration& x) + { + + m_index = x.m_index; + + m_message = x.m_message; + + m_data = x.m_data; + + return *this; + } /*! * @brief Move assignment. * @param x Reference to the object AdvancedConfiguration that will be copied. */ eProsima_user_DllExport AdvancedConfiguration& operator =( - AdvancedConfiguration&& x) noexcept; + AdvancedConfiguration&& x) noexcept + { + + m_index = x.m_index; + m_message = std::move(x.m_message); + m_data = std::move(x.m_data); + return *this; + } /*! * @brief Comparison operator. * @param x AdvancedConfiguration object to compare. */ eProsima_user_DllExport bool operator ==( - const AdvancedConfiguration& x) const; + const AdvancedConfiguration& x) const + { + return (m_index == x.m_index && + m_message == x.m_message && + m_data == x.m_data); + } /*! * @brief Comparison operator. * @param x AdvancedConfiguration object to compare. */ eProsima_user_DllExport bool operator !=( - const AdvancedConfiguration& x) const; + const AdvancedConfiguration& x) const + { + return !(*this == x); + } /*! * @brief This function sets a value in member index * @param _index New value for member index */ eProsima_user_DllExport void index( - uint32_t _index); + uint32_t _index) + { + m_index = _index; + } /*! * @brief This function returns the value of member index * @return Value of member index */ - eProsima_user_DllExport uint32_t index() const; + eProsima_user_DllExport uint32_t index() const + { + return m_index; + } /*! * @brief This function returns a reference to member index * @return Reference to member index */ - eProsima_user_DllExport uint32_t& index(); + eProsima_user_DllExport uint32_t& index() + { + return m_index; + } /*! @@ -162,26 +188,38 @@ class AdvancedConfiguration * @param _message New value to be copied in member message */ eProsima_user_DllExport void message( - const std::array& _message); + const std::array& _message) + { + m_message = _message; + } /*! * @brief This function moves the value in member message * @param _message New value to be moved in member message */ eProsima_user_DllExport void message( - std::array&& _message); + std::array&& _message) + { + m_message = std::move(_message); + } /*! * @brief This function returns a constant reference to member message * @return Constant reference to member message */ - eProsima_user_DllExport const std::array& message() const; + eProsima_user_DllExport const std::array& message() const + { + return m_message; + } /*! * @brief This function returns a reference to member message * @return Reference to member message */ - eProsima_user_DllExport std::array& message(); + eProsima_user_DllExport std::array& message() + { + return m_message; + } /*! @@ -189,26 +227,40 @@ class AdvancedConfiguration * @param _data New value to be copied in member data */ eProsima_user_DllExport void data( - const std::vector& _data); + const std::vector& _data) + { + m_data = _data; + } /*! * @brief This function moves the value in member data * @param _data New value to be moved in member data */ eProsima_user_DllExport void data( - std::vector&& _data); + std::vector&& _data) + { + m_data = std::move(_data); + } /*! * @brief This function returns a constant reference to member data * @return Constant reference to member data */ - eProsima_user_DllExport const std::vector& data() const; + eProsima_user_DllExport const std::vector& data() const + { + return m_data; + } /*! * @brief This function returns a reference to member data * @return Reference to member data */ - eProsima_user_DllExport std::vector& data(); + eProsima_user_DllExport std::vector& data() + { + return m_data; + } + + private: @@ -218,8 +270,6 @@ class AdvancedConfiguration }; -#endif // _FAST_DDS_GENERATED_ADVANCEDCONFIGURATION_H_ - +#endif // _FAST_DDS_GENERATED_ADVANCEDCONFIGURATION_HPP_ -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/AdvancedConfigurationExample/AdvancedConfigurationCdrAux.hpp b/examples/cpp/dds/AdvancedConfigurationExample/AdvancedConfigurationCdrAux.hpp index a99d903b31f..5eb6868b802 100644 --- a/examples/cpp/dds/AdvancedConfigurationExample/AdvancedConfigurationCdrAux.hpp +++ b/examples/cpp/dds/AdvancedConfigurationExample/AdvancedConfigurationCdrAux.hpp @@ -22,9 +22,9 @@ #ifndef _FAST_DDS_GENERATED_ADVANCEDCONFIGURATIONCDRAUX_HPP_ #define _FAST_DDS_GENERATED_ADVANCEDCONFIGURATIONCDRAUX_HPP_ -#include "AdvancedConfiguration.h" +#include "AdvancedConfiguration.hpp" -constexpr uint32_t AdvancedConfiguration_max_cdr_typesize {132UL}; +constexpr uint32_t AdvancedConfiguration_max_cdr_typesize {32UL}; constexpr uint32_t AdvancedConfiguration_max_key_cdr_typesize {0UL}; @@ -34,10 +34,6 @@ namespace fastcdr { class Cdr; class CdrSizeCalculator; - - - - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const AdvancedConfiguration& data); diff --git a/examples/cpp/dds/AdvancedConfigurationExample/AdvancedConfigurationCdrAux.ipp b/examples/cpp/dds/AdvancedConfigurationExample/AdvancedConfigurationCdrAux.ipp index 61815b63fe3..58b1d9fab52 100644 --- a/examples/cpp/dds/AdvancedConfigurationExample/AdvancedConfigurationCdrAux.ipp +++ b/examples/cpp/dds/AdvancedConfigurationExample/AdvancedConfigurationCdrAux.ipp @@ -34,10 +34,6 @@ using namespace eprosima::fastcdr::exception; namespace eprosima { namespace fastcdr { - - - - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, diff --git a/examples/cpp/dds/AdvancedConfigurationExample/AdvancedConfigurationPubSubTypes.cxx b/examples/cpp/dds/AdvancedConfigurationExample/AdvancedConfigurationPubSubTypes.cxx index fc1cdd916e3..007acf0d5b9 100644 --- a/examples/cpp/dds/AdvancedConfigurationExample/AdvancedConfigurationPubSubTypes.cxx +++ b/examples/cpp/dds/AdvancedConfigurationExample/AdvancedConfigurationPubSubTypes.cxx @@ -19,20 +19,18 @@ * This file was generated by the tool fastddsgen. */ +#include "AdvancedConfigurationPubSubTypes.h" +#include #include -#include "AdvancedConfigurationPubSubTypes.h" #include "AdvancedConfigurationCdrAux.hpp" +#include "AdvancedConfigurationTypeObjectSupport.hpp" using SerializedPayload_t = eprosima::fastrtps::rtps::SerializedPayload_t; using InstanceHandle_t = eprosima::fastrtps::rtps::InstanceHandle_t; using DataRepresentationId_t = eprosima::fastdds::dds::DataRepresentationId_t; - - - - AdvancedConfigurationPubSubType::AdvancedConfigurationPubSubType() { setName("AdvancedConfiguration"); @@ -221,3 +219,11 @@ bool AdvancedConfigurationPubSubType::getKey( return true; } +void AdvancedConfigurationPubSubType::register_type_object_representation() const +{ + register_AdvancedConfiguration_type_objects(); +} + + +// Include auxiliary functions like for serializing/deserializing. +#include "AdvancedConfigurationCdrAux.ipp" diff --git a/examples/cpp/dds/AdvancedConfigurationExample/AdvancedConfigurationPubSubTypes.h b/examples/cpp/dds/AdvancedConfigurationExample/AdvancedConfigurationPubSubTypes.h index 7c513bc156c..1d09762eebe 100644 --- a/examples/cpp/dds/AdvancedConfigurationExample/AdvancedConfigurationPubSubTypes.h +++ b/examples/cpp/dds/AdvancedConfigurationExample/AdvancedConfigurationPubSubTypes.h @@ -27,9 +27,9 @@ #include #include #include -#include +#include -#include "AdvancedConfiguration.h" +#include "AdvancedConfiguration.hpp" #if !defined(GEN_API_VER) || (GEN_API_VER != 2) @@ -38,10 +38,6 @@ #endif // GEN_API_VER - - - - /*! * @brief This class represents the TopicDataType of the type AdvancedConfiguration defined by the user in the IDL file. * @ingroup AdvancedConfiguration @@ -92,6 +88,9 @@ class AdvancedConfigurationPubSubType : public eprosima::fastdds::dds::TopicData eProsima_user_DllExport void deleteData( void* data) override; + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + #ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED eProsima_user_DllExport inline bool is_bounded() const override { diff --git a/examples/cpp/dds/AdvancedConfigurationExample/AdvancedConfigurationPublisher.cpp b/examples/cpp/dds/AdvancedConfigurationExample/AdvancedConfigurationPublisher.cpp index d606a603cc4..63420653ed1 100644 --- a/examples/cpp/dds/AdvancedConfigurationExample/AdvancedConfigurationPublisher.cpp +++ b/examples/cpp/dds/AdvancedConfigurationExample/AdvancedConfigurationPublisher.cpp @@ -17,9 +17,11 @@ * */ +#include "AdvancedConfigurationPublisher.h" + #include -#include #include +#include #include #include @@ -29,10 +31,6 @@ #include #include #include -#include -#include - -#include "AdvancedConfigurationPublisher.h" using namespace eprosima::fastdds::dds; using namespace eprosima::fastdds::rtps; diff --git a/examples/cpp/dds/AdvancedConfigurationExample/AdvancedConfigurationSubscriber.cpp b/examples/cpp/dds/AdvancedConfigurationExample/AdvancedConfigurationSubscriber.cpp index 807942606c4..2caa591eaa4 100644 --- a/examples/cpp/dds/AdvancedConfigurationExample/AdvancedConfigurationSubscriber.cpp +++ b/examples/cpp/dds/AdvancedConfigurationExample/AdvancedConfigurationSubscriber.cpp @@ -17,6 +17,8 @@ * */ +#include "AdvancedConfigurationSubscriber.h" + #include #include @@ -27,10 +29,6 @@ #include #include #include -#include -#include - -#include "AdvancedConfigurationSubscriber.h" using namespace eprosima::fastdds::dds; using namespace eprosima::fastdds::rtps; @@ -282,7 +280,7 @@ void HelloWorldSubscriber::SubListener::on_data_available( DataReader* reader) { SampleInfo info; - while ((reader->take_next_sample(&hello_, &info) == ReturnCode_t::RETCODE_OK) && !is_stopped()) + while ((reader->take_next_sample(&hello_, &info) == RETCODE_OK) && !is_stopped()) { if (info.instance_state == ALIVE_INSTANCE_STATE) { diff --git a/examples/cpp/dds/AdvancedConfigurationExample/AdvancedConfigurationTypeObjectSupport.cxx b/examples/cpp/dds/AdvancedConfigurationExample/AdvancedConfigurationTypeObjectSupport.cxx new file mode 100644 index 00000000000..c19034579e1 --- /dev/null +++ b/examples/cpp/dds/AdvancedConfigurationExample/AdvancedConfigurationTypeObjectSupport.cxx @@ -0,0 +1,461 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file AdvancedConfigurationTypeObjectSupport.cxx + * Source file containing the implementation to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#include "AdvancedConfigurationTypeObjectSupport.hpp" + +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include + +#include "AdvancedConfiguration.hpp" + + +using namespace eprosima::fastdds::dds::xtypes; + +void register_AdvancedConfiguration_type_objects() +{ + static std::once_flag once_flag; + std::call_once(once_flag, []() + { + register_AdvancedConfiguration_type_identifier(); + + }); +} + +void register_AdvancedConfiguration_type_identifier() +{ + { + StructTypeFlag struct_flags_AdvancedConfiguration = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::NOT_APPLIED, + false, false); + ReturnCode_t return_code_AdvancedConfiguration; + TypeIdentifierPair type_ids_AdvancedConfiguration; + QualifiedTypeName type_name_AdvancedConfiguration = "AdvancedConfiguration"; + eprosima::fastcdr::optional type_ann_builtin_AdvancedConfiguration; + eprosima::fastcdr::optional ann_custom_AdvancedConfiguration; + CompleteTypeDetail detail_AdvancedConfiguration = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_AdvancedConfiguration, ann_custom_AdvancedConfiguration, type_name_AdvancedConfiguration.to_string()); + CompleteStructHeader header_AdvancedConfiguration; + header_AdvancedConfiguration = TypeObjectUtils::build_complete_struct_header(TypeIdentifier(), detail_AdvancedConfiguration); + CompleteStructMemberSeq member_seq_AdvancedConfiguration; + { + return_code_AdvancedConfiguration = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_uint32_t", type_ids_AdvancedConfiguration); + + if (return_code_AdvancedConfiguration != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "index Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_index = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_index; + MemberId member_id_index = 0x00000000; + if (EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier1()._d() || TK_NONE == type_ids_AdvancedConfiguration.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_AdvancedConfiguration.type_identifier1()._d() && + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_AdvancedConfiguration.type_identifier1()._d() && + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_AdvancedConfiguration.type_identifier1()._d() && + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_AdvancedConfiguration.type_identifier1()._d() && + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_AdvancedConfiguration.type_identifier1()._d() && + (EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_AdvancedConfiguration.type_identifier1()._d() && + (EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_AdvancedConfiguration.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_AdvancedConfiguration.type_identifier2()._d() && + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_AdvancedConfiguration.type_identifier2()._d() && + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_AdvancedConfiguration.type_identifier2()._d() && + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_AdvancedConfiguration.type_identifier2()._d() && + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_AdvancedConfiguration.type_identifier2()._d() && + (EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_AdvancedConfiguration.type_identifier2()._d() && + (EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_AdvancedConfiguration.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure index member TypeIdentifier inconsistent."); + return; + } + MemberName name_index = "index"; + eprosima::fastcdr::optional member_ann_builtin_index; + ann_custom_AdvancedConfiguration.reset(); + CompleteMemberDetail detail_index = TypeObjectUtils::build_complete_member_detail(name_index, member_ann_builtin_index, ann_custom_AdvancedConfiguration); + CompleteStructMember member_index = TypeObjectUtils::build_complete_struct_member(common_index, detail_index); + TypeObjectUtils::add_complete_struct_member(member_seq_AdvancedConfiguration, member_index); + } + { + return_code_AdvancedConfiguration = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_array_char_20", type_ids_AdvancedConfiguration); + + if (return_code_AdvancedConfiguration != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_AdvancedConfiguration = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_char", type_ids_AdvancedConfiguration); + + if (return_code_AdvancedConfiguration != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Array element TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + TypeIdentifier* element_identifier_anonymous_array_char_20 {nullptr}; + if (EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier1()._d() || TK_NONE == type_ids_AdvancedConfiguration.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_AdvancedConfiguration.type_identifier1()._d() && + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_AdvancedConfiguration.type_identifier1()._d() && + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_AdvancedConfiguration.type_identifier1()._d() && + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_AdvancedConfiguration.type_identifier1()._d() && + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_AdvancedConfiguration.type_identifier1()._d() && + (EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_AdvancedConfiguration.type_identifier1()._d() && + (EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_array_char_20 = new TypeIdentifier(type_ids_AdvancedConfiguration.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_AdvancedConfiguration.type_identifier2()._d() && + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_AdvancedConfiguration.type_identifier2()._d() && + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_AdvancedConfiguration.type_identifier2()._d() && + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_AdvancedConfiguration.type_identifier2()._d() && + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_AdvancedConfiguration.type_identifier2()._d() && + (EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_AdvancedConfiguration.type_identifier2()._d() && + (EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_array_char_20 = new TypeIdentifier(type_ids_AdvancedConfiguration.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Array element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_array_char_20 = EK_COMPLETE; + if (TK_NONE == type_ids_AdvancedConfiguration.type_identifier2()._d()) + { + equiv_kind_anonymous_array_char_20 = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_array_char_20 = 0; + PlainCollectionHeader header_anonymous_array_char_20 = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_array_char_20, element_flags_anonymous_array_char_20); + std::string type_id_kind_anonymous_array_char_20("TI_PLAIN_ARRAY_SMALL"); + if (type_id_kind_anonymous_array_char_20 == "TI_PLAIN_ARRAY_SMALL") + { + SBoundSeq array_bound_seq; + TypeObjectUtils::add_array_dimension(array_bound_seq, static_cast(20)); + + PlainArraySElemDefn array_sdefn = TypeObjectUtils::build_plain_array_s_elem_defn(header_anonymous_array_char_20, array_bound_seq, + eprosima::fastcdr::external(element_identifier_anonymous_array_char_20)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_array_type_identifier(array_sdefn, "anonymous_array_char_20")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_char_20 already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBoundSeq array_bound_seq; + TypeObjectUtils::add_array_dimension(array_bound_seq, static_cast(20)); + + PlainArrayLElemDefn array_ldefn = TypeObjectUtils::build_plain_array_l_elem_defn(header_anonymous_array_char_20, array_bound_seq, + eprosima::fastcdr::external(element_identifier_anonymous_array_char_20)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_array_type_identifier(array_ldefn, "anonymous_array_char_20")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_char_20 already registered in TypeObjectRegistry for a different type."); + } + } + return_code_AdvancedConfiguration = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_array_char_20", type_ids_AdvancedConfiguration); + if (return_code_AdvancedConfiguration != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_char_20: Given Array TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_message = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_message; + MemberId member_id_message = 0x00000001; + if (EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier1()._d() || TK_NONE == type_ids_AdvancedConfiguration.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_AdvancedConfiguration.type_identifier1()._d() && + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_AdvancedConfiguration.type_identifier1()._d() && + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_AdvancedConfiguration.type_identifier1()._d() && + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_AdvancedConfiguration.type_identifier1()._d() && + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_AdvancedConfiguration.type_identifier1()._d() && + (EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_AdvancedConfiguration.type_identifier1()._d() && + (EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_message = TypeObjectUtils::build_common_struct_member(member_id_message, member_flags_message, type_ids_AdvancedConfiguration.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_AdvancedConfiguration.type_identifier2()._d() && + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_AdvancedConfiguration.type_identifier2()._d() && + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_AdvancedConfiguration.type_identifier2()._d() && + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_AdvancedConfiguration.type_identifier2()._d() && + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_AdvancedConfiguration.type_identifier2()._d() && + (EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_AdvancedConfiguration.type_identifier2()._d() && + (EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_message = TypeObjectUtils::build_common_struct_member(member_id_message, member_flags_message, type_ids_AdvancedConfiguration.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure message member TypeIdentifier inconsistent."); + return; + } + MemberName name_message = "message"; + eprosima::fastcdr::optional member_ann_builtin_message; + ann_custom_AdvancedConfiguration.reset(); + CompleteMemberDetail detail_message = TypeObjectUtils::build_complete_member_detail(name_message, member_ann_builtin_message, ann_custom_AdvancedConfiguration); + CompleteStructMember member_message = TypeObjectUtils::build_complete_struct_member(common_message, detail_message); + TypeObjectUtils::add_complete_struct_member(member_seq_AdvancedConfiguration, member_message); + } + { + return_code_AdvancedConfiguration = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_uint8_t_unbounded", type_ids_AdvancedConfiguration); + + if (return_code_AdvancedConfiguration != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_AdvancedConfiguration = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_byte", type_ids_AdvancedConfiguration); + + if (return_code_AdvancedConfiguration != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + TypeIdentifier* element_identifier_anonymous_sequence_uint8_t_unbounded {nullptr}; + if (EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier1()._d() || TK_NONE == type_ids_AdvancedConfiguration.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_AdvancedConfiguration.type_identifier1()._d() && + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_AdvancedConfiguration.type_identifier1()._d() && + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_AdvancedConfiguration.type_identifier1()._d() && + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_AdvancedConfiguration.type_identifier1()._d() && + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_AdvancedConfiguration.type_identifier1()._d() && + (EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_AdvancedConfiguration.type_identifier1()._d() && + (EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_uint8_t_unbounded = new TypeIdentifier(type_ids_AdvancedConfiguration.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_AdvancedConfiguration.type_identifier2()._d() && + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_AdvancedConfiguration.type_identifier2()._d() && + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_AdvancedConfiguration.type_identifier2()._d() && + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_AdvancedConfiguration.type_identifier2()._d() && + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_AdvancedConfiguration.type_identifier2()._d() && + (EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_AdvancedConfiguration.type_identifier2()._d() && + (EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_uint8_t_unbounded = new TypeIdentifier(type_ids_AdvancedConfiguration.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_sequence_uint8_t_unbounded = EK_COMPLETE; + if (TK_NONE == type_ids_AdvancedConfiguration.type_identifier2()._d()) + { + equiv_kind_anonymous_sequence_uint8_t_unbounded = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_sequence_uint8_t_unbounded = 0; + PlainCollectionHeader header_anonymous_sequence_uint8_t_unbounded = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_sequence_uint8_t_unbounded, element_flags_anonymous_sequence_uint8_t_unbounded); + std::string type_id_kind_anonymous_sequence_uint8_t_unbounded("TI_PLAIN_SEQUENCE_SMALL"); + if (type_id_kind_anonymous_sequence_uint8_t_unbounded == "TI_PLAIN_SEQUENCE_SMALL") + { + SBound bound = 0; + PlainSequenceSElemDefn seq_sdefn = TypeObjectUtils::build_plain_sequence_s_elem_defn(header_anonymous_sequence_uint8_t_unbounded, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_uint8_t_unbounded)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_sequence_type_identifier(seq_sdefn, "anonymous_sequence_uint8_t_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_uint8_t_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBound bound = 0; + PlainSequenceLElemDefn seq_ldefn = TypeObjectUtils::build_plain_sequence_l_elem_defn(header_anonymous_sequence_uint8_t_unbounded, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_uint8_t_unbounded)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_sequence_type_identifier(seq_ldefn, "anonymous_sequence_uint8_t_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_uint8_t_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + return_code_AdvancedConfiguration = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_uint8_t_unbounded", type_ids_AdvancedConfiguration); + if (return_code_AdvancedConfiguration != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_uint8_t_unbounded: Given Sequence TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_data = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_data; + MemberId member_id_data = 0x00000002; + if (EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier1()._d() || TK_NONE == type_ids_AdvancedConfiguration.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_AdvancedConfiguration.type_identifier1()._d() && + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_AdvancedConfiguration.type_identifier1()._d() && + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_AdvancedConfiguration.type_identifier1()._d() && + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_AdvancedConfiguration.type_identifier1()._d() && + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_AdvancedConfiguration.type_identifier1()._d() && + (EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_AdvancedConfiguration.type_identifier1()._d() && + (EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_data = TypeObjectUtils::build_common_struct_member(member_id_data, member_flags_data, type_ids_AdvancedConfiguration.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_AdvancedConfiguration.type_identifier2()._d() && + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_AdvancedConfiguration.type_identifier2()._d() && + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_AdvancedConfiguration.type_identifier2()._d() && + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_AdvancedConfiguration.type_identifier2()._d() && + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_AdvancedConfiguration.type_identifier2()._d() && + (EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_AdvancedConfiguration.type_identifier2()._d() && + (EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_AdvancedConfiguration.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_data = TypeObjectUtils::build_common_struct_member(member_id_data, member_flags_data, type_ids_AdvancedConfiguration.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure data member TypeIdentifier inconsistent."); + return; + } + MemberName name_data = "data"; + eprosima::fastcdr::optional member_ann_builtin_data; + ann_custom_AdvancedConfiguration.reset(); + CompleteMemberDetail detail_data = TypeObjectUtils::build_complete_member_detail(name_data, member_ann_builtin_data, ann_custom_AdvancedConfiguration); + CompleteStructMember member_data = TypeObjectUtils::build_complete_struct_member(common_data, detail_data); + TypeObjectUtils::add_complete_struct_member(member_seq_AdvancedConfiguration, member_data); + } + CompleteStructType struct_type_AdvancedConfiguration = TypeObjectUtils::build_complete_struct_type(struct_flags_AdvancedConfiguration, header_AdvancedConfiguration, member_seq_AdvancedConfiguration); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_struct_type_object(struct_type_AdvancedConfiguration, type_name_AdvancedConfiguration.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "AdvancedConfiguration already registered in TypeObjectRegistry for a different type."); + } + return_code_AdvancedConfiguration = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "AdvancedConfiguration", type_ids_AdvancedConfiguration); + if (return_code_AdvancedConfiguration != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "AdvancedConfiguration: Given Struct TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } +} + diff --git a/examples/cpp/dds/AdvancedConfigurationExample/AdvancedConfigurationTypeObjectSupport.hpp b/examples/cpp/dds/AdvancedConfigurationExample/AdvancedConfigurationTypeObjectSupport.hpp new file mode 100644 index 00000000000..c863db7608d --- /dev/null +++ b/examples/cpp/dds/AdvancedConfigurationExample/AdvancedConfigurationTypeObjectSupport.hpp @@ -0,0 +1,54 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file AdvancedConfigurationTypeObjectSupport.hpp + * Header file containing the API required to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#ifndef _FAST_DDS_GENERATED_ADVANCEDCONFIGURATION_TYPE_OBJECT_SUPPORT_HPP_ +#define _FAST_DDS_GENERATED_ADVANCEDCONFIGURATION_TYPE_OBJECT_SUPPORT_HPP_ + + +#if defined(_WIN32) +#if defined(EPROSIMA_USER_DLL_EXPORT) +#define eProsima_user_DllExport __declspec( dllexport ) +#else +#define eProsima_user_DllExport +#endif // EPROSIMA_USER_DLL_EXPORT +#else +#define eProsima_user_DllExport +#endif // _WIN32 + +/** + * @brief Register every TypeObject representation defined in the IDL file in Fast DDS TypeObjectRegistry. + */ +eProsima_user_DllExport void register_AdvancedConfiguration_type_objects(); + +#ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +/** + * @brief Register AdvancedConfiguration related TypeIdentifier. + * Fully-descriptive TypeIdentifiers are directly registered. + * Hash TypeIdentifiers require to fill the TypeObject information and hash it, consequently, the TypeObject is + * indirectly registered as well. + */ +void register_AdvancedConfiguration_type_identifier(); + + +#endif // DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +#endif // _FAST_DDS_GENERATED_ADVANCEDCONFIGURATION_TYPE_OBJECT_SUPPORT_HPP_ diff --git a/examples/cpp/dds/AdvancedConfigurationExample/AdvancedConfigurationv1.cxx b/examples/cpp/dds/AdvancedConfigurationExample/AdvancedConfigurationv1.cxx deleted file mode 100644 index 2e28c5a0822..00000000000 --- a/examples/cpp/dds/AdvancedConfigurationExample/AdvancedConfigurationv1.cxx +++ /dev/null @@ -1,361 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file AdvancedConfiguration.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "AdvancedConfiguration.h" - -#if FASTCDR_VERSION_MAJOR == 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - -namespace helper { namespace internal { - -enum class Size { - UInt8, - UInt16, - UInt32, - UInt64, -}; - -constexpr Size get_size(int s) { - return (s <= 8 ) ? Size::UInt8: - (s <= 16) ? Size::UInt16: - (s <= 32) ? Size::UInt32: Size::UInt64; -} - -template -struct FindTypeH; - -template<> -struct FindTypeH { - using type = std::uint8_t; -}; - -template<> -struct FindTypeH { - using type = std::uint16_t; -}; - -template<> -struct FindTypeH { - using type = std::uint32_t; -}; - -template<> -struct FindTypeH { - using type = std::uint64_t; -}; -} - -template -struct FindType { - using type = typename internal::FindTypeH::type; -}; -} - -#define AdvancedConfiguration_max_cdr_typesize 132ULL; - - - - - - -AdvancedConfiguration::AdvancedConfiguration() -{ - // unsigned long m_index - m_index = 0; - // char m_message - memset(&m_message, 0, ((20)) * 1); - // sequence m_data - - -} - -AdvancedConfiguration::~AdvancedConfiguration() -{ -} - -AdvancedConfiguration::AdvancedConfiguration( - const AdvancedConfiguration& x) -{ - m_index = x.m_index; - - - m_message = x.m_message; - - - m_data = x.m_data; - -} - -AdvancedConfiguration::AdvancedConfiguration( - AdvancedConfiguration&& x) noexcept -{ - m_index = x.m_index; - - - m_message = std::move(x.m_message); - - - m_data = std::move(x.m_data); - -} - -AdvancedConfiguration& AdvancedConfiguration::operator =( - const AdvancedConfiguration& x) -{ - m_index = x.m_index; - - - m_message = x.m_message; - - - m_data = x.m_data; - - return *this; -} - -AdvancedConfiguration& AdvancedConfiguration::operator =( - AdvancedConfiguration&& x) noexcept -{ - m_index = x.m_index; - - - m_message = std::move(x.m_message); - - - m_data = std::move(x.m_data); - - return *this; -} - -bool AdvancedConfiguration::operator ==( - const AdvancedConfiguration& x) const -{ - return (m_index == x.m_index && - m_message == x.m_message && - m_data == x.m_data); -} - -bool AdvancedConfiguration::operator !=( - const AdvancedConfiguration& x) const -{ - return !(*this == x); -} - -size_t AdvancedConfiguration::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return AdvancedConfiguration_max_cdr_typesize; -} - -size_t AdvancedConfiguration::getCdrSerializedSize( - const AdvancedConfiguration& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += (((20)) * 1) + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - if (data.data().size() > 0) - { - current_alignment += (data.data().size() * 1) + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - } - - - - - return current_alignment - initial_alignment; -} - - -void AdvancedConfiguration::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_index; - - scdr << m_message; - - - scdr << m_data; - - -} - -void AdvancedConfiguration::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_index; - - - - dcdr >> m_message; - - - - dcdr >> m_data; - - -} - - -bool AdvancedConfiguration::isKeyDefined() -{ - return false; -} - -void AdvancedConfiguration::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void AdvancedConfiguration::index( - uint32_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint32_t AdvancedConfiguration::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint32_t& AdvancedConfiguration::index() -{ - return m_index; -} - - -/*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ -void AdvancedConfiguration::message( - const std::array& _message) -{ - m_message = _message; -} - -/*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ -void AdvancedConfiguration::message( - std::array&& _message) -{ - m_message = std::move(_message); -} - -/*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ -const std::array& AdvancedConfiguration::message() const -{ - return m_message; -} - -/*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ -std::array& AdvancedConfiguration::message() -{ - return m_message; -} - - -/*! - * @brief This function copies the value in member data - * @param _data New value to be copied in member data - */ -void AdvancedConfiguration::data( - const std::vector& _data) -{ - m_data = _data; -} - -/*! - * @brief This function moves the value in member data - * @param _data New value to be moved in member data - */ -void AdvancedConfiguration::data( - std::vector&& _data) -{ - m_data = std::move(_data); -} - -/*! - * @brief This function returns a constant reference to member data - * @return Constant reference to member data - */ -const std::vector& AdvancedConfiguration::data() const -{ - return m_data; -} - -/*! - * @brief This function returns a reference to member data - * @return Reference to member data - */ -std::vector& AdvancedConfiguration::data() -{ - return m_data; -} - - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/AdvancedConfigurationExample/AdvancedConfigurationv1.h b/examples/cpp/dds/AdvancedConfigurationExample/AdvancedConfigurationv1.h deleted file mode 100644 index 5ea849b1748..00000000000 --- a/examples/cpp/dds/AdvancedConfigurationExample/AdvancedConfigurationv1.h +++ /dev/null @@ -1,274 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file AdvancedConfiguration.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#include - -#if FASTCDR_VERSION_MAJOR == 1 - -#ifndef _FAST_DDS_GENERATED_ADVANCEDCONFIGURATION_H_ -#define _FAST_DDS_GENERATED_ADVANCEDCONFIGURATION_H_ - - -#include - -#include -#include -#include -#include -#include -#include -#include - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define eProsima_user_DllExport -#endif // _WIN32 - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(ADVANCEDCONFIGURATION_SOURCE) -#define ADVANCEDCONFIGURATION_DllAPI __declspec( dllexport ) -#else -#define ADVANCEDCONFIGURATION_DllAPI __declspec( dllimport ) -#endif // ADVANCEDCONFIGURATION_SOURCE -#else -#define ADVANCEDCONFIGURATION_DllAPI -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define ADVANCEDCONFIGURATION_DllAPI -#endif // _WIN32 - -namespace eprosima { -namespace fastcdr { -class Cdr; -} // namespace fastcdr -} // namespace eprosima - - - - - - - -/*! - * @brief This class represents the structure AdvancedConfiguration defined by the user in the IDL file. - * @ingroup AdvancedConfiguration - */ -class AdvancedConfiguration -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport AdvancedConfiguration(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~AdvancedConfiguration(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object AdvancedConfiguration that will be copied. - */ - eProsima_user_DllExport AdvancedConfiguration( - const AdvancedConfiguration& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object AdvancedConfiguration that will be copied. - */ - eProsima_user_DllExport AdvancedConfiguration( - AdvancedConfiguration&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object AdvancedConfiguration that will be copied. - */ - eProsima_user_DllExport AdvancedConfiguration& operator =( - const AdvancedConfiguration& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object AdvancedConfiguration that will be copied. - */ - eProsima_user_DllExport AdvancedConfiguration& operator =( - AdvancedConfiguration&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x AdvancedConfiguration object to compare. - */ - eProsima_user_DllExport bool operator ==( - const AdvancedConfiguration& x) const; - - /*! - * @brief Comparison operator. - * @param x AdvancedConfiguration object to compare. - */ - eProsima_user_DllExport bool operator !=( - const AdvancedConfiguration& x) const; - - /*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ - eProsima_user_DllExport void index( - uint32_t _index); - - /*! - * @brief This function returns the value of member index - * @return Value of member index - */ - eProsima_user_DllExport uint32_t index() const; - - /*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ - eProsima_user_DllExport uint32_t& index(); - - - /*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ - eProsima_user_DllExport void message( - const std::array& _message); - - /*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ - eProsima_user_DllExport void message( - std::array&& _message); - - /*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ - eProsima_user_DllExport const std::array& message() const; - - /*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ - eProsima_user_DllExport std::array& message(); - - - /*! - * @brief This function copies the value in member data - * @param _data New value to be copied in member data - */ - eProsima_user_DllExport void data( - const std::vector& _data); - - /*! - * @brief This function moves the value in member data - * @param _data New value to be moved in member data - */ - eProsima_user_DllExport void data( - std::vector&& _data); - - /*! - * @brief This function returns a constant reference to member data - * @return Constant reference to member data - */ - eProsima_user_DllExport const std::vector& data() const; - - /*! - * @brief This function returns a reference to member data - * @return Reference to member data - */ - eProsima_user_DllExport std::vector& data(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const AdvancedConfiguration& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - uint32_t m_index; - std::array m_message; - std::vector m_data; - -}; - - -#endif // _FAST_DDS_GENERATED_ADVANCEDCONFIGURATION_H_ - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/AdvancedConfigurationExample/CMakeLists.txt b/examples/cpp/dds/AdvancedConfigurationExample/CMakeLists.txt index b58e08d8e87..16a28f79266 100644 --- a/examples/cpp/dds/AdvancedConfigurationExample/CMakeLists.txt +++ b/examples/cpp/dds/AdvancedConfigurationExample/CMakeLists.txt @@ -21,8 +21,8 @@ if(NOT fastcdr_FOUND) find_package(fastcdr 2 REQUIRED) endif() -if(NOT fastrtps_FOUND) - find_package(fastrtps 2.12 REQUIRED) +if(NOT fastdds_FOUND) + find_package(fastdds 3 REQUIRED) endif() #Check C++11 @@ -46,7 +46,7 @@ target_compile_definitions(${PROJECT_NAME} PRIVATE $<$:SHM_TRANSPORT_BUILTIN> # Enable SHM as built-in transport ) -target_link_libraries(${PROJECT_NAME} fastrtps fastcdr fastdds::optionparser) +target_link_libraries(${PROJECT_NAME} fastdds fastcdr fastdds::optionparser) install(TARGETS ${PROJECT_NAME} RUNTIME DESTINATION examples/cpp/dds/${PROJECT_NAME}/${BIN_INSTALL_DIR}) diff --git a/examples/cpp/dds/AdvancedConfigurationExample/README.md b/examples/cpp/dds/AdvancedConfigurationExample/README.md index fdc0352d5cb..c31397f38f9 100644 --- a/examples/cpp/dds/AdvancedConfigurationExample/README.md +++ b/examples/cpp/dds/AdvancedConfigurationExample/README.md @@ -85,7 +85,7 @@ QoS options: Discovery options: --ttl Set multicast discovery Time To Live on IPv4 or Hop Limit - for IPv6. If not set, uses Fast-DDS default (1 hop). + for IPv6. If not set, uses Fast DDS default (1 hop). Increase it to avoid discovery issues on scenarios with several routers. Maximum: 255. ``` @@ -100,5 +100,5 @@ This code presents how to run a publisher with this example without Shared Memor ```sh # From AdvancedConfigurationExample installation dir -FASTRTPS_DEFAULT_PROFILES_FILE=shm_off.xml ./AdvancedConfigurationExample publisher --xml-profile no_shm_participant_profile +FASTDDS_DEFAULT_PROFILES_FILE=shm_off.xml ./AdvancedConfigurationExample publisher --xml-profile no_shm_participant_profile ``` diff --git a/examples/cpp/dds/AdvancedConfigurationExample/arg_configuration.h b/examples/cpp/dds/AdvancedConfigurationExample/arg_configuration.h index 96cc666d4fe..997360b7e9c 100644 --- a/examples/cpp/dds/AdvancedConfigurationExample/arg_configuration.h +++ b/examples/cpp/dds/AdvancedConfigurationExample/arg_configuration.h @@ -239,7 +239,7 @@ const option::Descriptor usage[] = { { UNKNOWN_OPT, 0, "", "", Arg::None, "\nDiscovery options:"}, { TTL, 0, "", "ttl", Arg::NumericRange<1, 255>, "\t--ttl \tSet multicast discovery Time To Live on IPv4 or Hop Limit for IPv6." - " If not set, uses Fast-DDS default (1 hop). Increase it to avoid discovery issues" + " If not set, uses Fast DDS default (1 hop). Increase it to avoid discovery issues" " on scenarios with several routers. Maximum: 255."}, { 0, 0, 0, 0, 0, 0 } diff --git a/examples/cpp/dds/AdvancedConfigurationExample/shm_off.xml b/examples/cpp/dds/AdvancedConfigurationExample/shm_off.xml index d02bf86f1ad..50d23e0c3ca 100644 --- a/examples/cpp/dds/AdvancedConfigurationExample/shm_off.xml +++ b/examples/cpp/dds/AdvancedConfigurationExample/shm_off.xml @@ -1,6 +1,6 @@ - + custom_udpv4_transport diff --git a/examples/cpp/dds/BasicConfigurationExample/BasicConfigurationPublisher.cpp b/examples/cpp/dds/BasicConfigurationExample/BasicConfigurationPublisher.cpp index 1f231adf86d..3734b53436a 100644 --- a/examples/cpp/dds/BasicConfigurationExample/BasicConfigurationPublisher.cpp +++ b/examples/cpp/dds/BasicConfigurationExample/BasicConfigurationPublisher.cpp @@ -17,6 +17,8 @@ * */ +#include "BasicConfigurationPublisher.h" + #include #include @@ -28,10 +30,6 @@ #include #include #include -#include -#include - -#include "BasicConfigurationPublisher.h" using namespace eprosima::fastdds::dds; using namespace eprosima::fastdds::rtps; diff --git a/examples/cpp/dds/BasicConfigurationExample/BasicConfigurationSubscriber.cpp b/examples/cpp/dds/BasicConfigurationExample/BasicConfigurationSubscriber.cpp index cd333888698..5f22068cab3 100644 --- a/examples/cpp/dds/BasicConfigurationExample/BasicConfigurationSubscriber.cpp +++ b/examples/cpp/dds/BasicConfigurationExample/BasicConfigurationSubscriber.cpp @@ -17,6 +17,8 @@ * */ +#include "BasicConfigurationSubscriber.h" + #include #include @@ -27,10 +29,6 @@ #include #include #include -#include -#include - -#include "BasicConfigurationSubscriber.h" using namespace eprosima::fastdds::dds; using namespace eprosima::fastdds::rtps; @@ -254,7 +252,7 @@ void HelloWorldSubscriber::SubListener::on_data_available( DataReader* reader) { SampleInfo info; - while ((reader->take_next_sample(&hello_, &info) == ReturnCode_t::RETCODE_OK) && !is_stopped()) + while ((reader->take_next_sample(&hello_, &info) == RETCODE_OK) && !is_stopped()) { if (info.instance_state == ALIVE_INSTANCE_STATE) { diff --git a/examples/cpp/dds/BasicConfigurationExample/CMakeLists.txt b/examples/cpp/dds/BasicConfigurationExample/CMakeLists.txt index 5b951d5e9d2..ba91f9520dc 100644 --- a/examples/cpp/dds/BasicConfigurationExample/CMakeLists.txt +++ b/examples/cpp/dds/BasicConfigurationExample/CMakeLists.txt @@ -21,8 +21,8 @@ if(NOT fastcdr_FOUND) find_package(fastcdr 2 REQUIRED) endif() -if(NOT fastrtps_FOUND) - find_package(fastrtps 2.12 REQUIRED) +if(NOT fastdds_FOUND) + find_package(fastdds 3 REQUIRED) endif() #Check C++11 @@ -46,6 +46,6 @@ target_compile_definitions(${PROJECT_NAME} PRIVATE $<$:SHM_TRANSPORT_BUILTIN> # Enable SHM as built-in transport ) -target_link_libraries(${PROJECT_NAME} fastrtps fastcdr fastdds::optionparser) +target_link_libraries(${PROJECT_NAME} fastdds fastcdr fastdds::optionparser) install(TARGETS ${PROJECT_NAME} RUNTIME DESTINATION examples/cpp/dds/${PROJECT_NAME}/${BIN_INSTALL_DIR}) diff --git a/examples/cpp/dds/BasicConfigurationExample/HelloWorld.cxx b/examples/cpp/dds/BasicConfigurationExample/HelloWorld.cxx deleted file mode 100644 index 0d9236d0cee..00000000000 --- a/examples/cpp/dds/BasicConfigurationExample/HelloWorld.cxx +++ /dev/null @@ -1,168 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file HelloWorld.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "HelloWorld.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - - - - -HelloWorld::HelloWorld() -{ -} - -HelloWorld::~HelloWorld() -{ -} - -HelloWorld::HelloWorld( - const HelloWorld& x) -{ - m_index = x.m_index; - m_message = x.m_message; -} - -HelloWorld::HelloWorld( - HelloWorld&& x) noexcept -{ - m_index = x.m_index; - m_message = std::move(x.m_message); -} - -HelloWorld& HelloWorld::operator =( - const HelloWorld& x) -{ - - m_index = x.m_index; - m_message = x.m_message; - return *this; -} - -HelloWorld& HelloWorld::operator =( - HelloWorld&& x) noexcept -{ - - m_index = x.m_index; - m_message = std::move(x.m_message); - return *this; -} - -bool HelloWorld::operator ==( - const HelloWorld& x) const -{ - return (m_index == x.m_index && - m_message == x.m_message); -} - -bool HelloWorld::operator !=( - const HelloWorld& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void HelloWorld::index( - uint32_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint32_t HelloWorld::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint32_t& HelloWorld::index() -{ - return m_index; -} - - -/*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ -void HelloWorld::message( - const std::array& _message) -{ - m_message = _message; -} - -/*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ -void HelloWorld::message( - std::array&& _message) -{ - m_message = std::move(_message); -} - -/*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ -const std::array& HelloWorld::message() const -{ - return m_message; -} - -/*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ -std::array& HelloWorld::message() -{ - return m_message; -} - - -// Include auxiliary functions like for serializing/deserializing. -#include "HelloWorldCdrAux.ipp" - -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/BasicConfigurationExample/HelloWorld.h b/examples/cpp/dds/BasicConfigurationExample/HelloWorld.hpp similarity index 70% rename from examples/cpp/dds/BasicConfigurationExample/HelloWorld.h rename to examples/cpp/dds/BasicConfigurationExample/HelloWorld.hpp index aaf09e4bc57..138a79db54c 100644 --- a/examples/cpp/dds/BasicConfigurationExample/HelloWorld.h +++ b/examples/cpp/dds/BasicConfigurationExample/HelloWorld.hpp @@ -13,32 +13,18 @@ // limitations under the License. /*! - * @file HelloWorld.h + * @file HelloWorld.hpp * This header file contains the declaration of the described types in the IDL file. * * This file was generated by the tool fastddsgen. */ -#include -#include "HelloWorldv1.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#ifndef _FAST_DDS_GENERATED_HELLOWORLD_H_ -#define _FAST_DDS_GENERATED_HELLOWORLD_H_ +#ifndef _FAST_DDS_GENERATED_HELLOWORLD_HPP_ +#define _FAST_DDS_GENERATED_HELLOWORLD_HPP_ #include -#include #include -#include -#include -#include - -#include -#include -#include - - +#include #if defined(_WIN32) #if defined(EPROSIMA_USER_DLL_EXPORT) @@ -64,17 +50,6 @@ #define HELLOWORLD_DllAPI #endif // _WIN32 -namespace eprosima { -namespace fastcdr { -class Cdr; -class CdrSizeCalculator; -} // namespace fastcdr -} // namespace eprosima - - - - - /*! * @brief This class represents the structure HelloWorld defined by the user in the IDL file. * @ingroup HelloWorld @@ -86,73 +61,117 @@ class HelloWorld /*! * @brief Default constructor. */ - eProsima_user_DllExport HelloWorld(); + eProsima_user_DllExport HelloWorld() + { + } /*! * @brief Default destructor. */ - eProsima_user_DllExport ~HelloWorld(); + eProsima_user_DllExport ~HelloWorld() + { + } /*! * @brief Copy constructor. * @param x Reference to the object HelloWorld that will be copied. */ eProsima_user_DllExport HelloWorld( - const HelloWorld& x); + const HelloWorld& x) + { + m_index = x.m_index; + + m_message = x.m_message; + + } /*! * @brief Move constructor. * @param x Reference to the object HelloWorld that will be copied. */ eProsima_user_DllExport HelloWorld( - HelloWorld&& x) noexcept; + HelloWorld&& x) noexcept + { + m_index = x.m_index; + m_message = std::move(x.m_message); + } /*! * @brief Copy assignment. * @param x Reference to the object HelloWorld that will be copied. */ eProsima_user_DllExport HelloWorld& operator =( - const HelloWorld& x); + const HelloWorld& x) + { + + m_index = x.m_index; + + m_message = x.m_message; + + return *this; + } /*! * @brief Move assignment. * @param x Reference to the object HelloWorld that will be copied. */ eProsima_user_DllExport HelloWorld& operator =( - HelloWorld&& x) noexcept; + HelloWorld&& x) noexcept + { + + m_index = x.m_index; + m_message = std::move(x.m_message); + return *this; + } /*! * @brief Comparison operator. * @param x HelloWorld object to compare. */ eProsima_user_DllExport bool operator ==( - const HelloWorld& x) const; + const HelloWorld& x) const + { + return (m_index == x.m_index && + m_message == x.m_message); + } /*! * @brief Comparison operator. * @param x HelloWorld object to compare. */ eProsima_user_DllExport bool operator !=( - const HelloWorld& x) const; + const HelloWorld& x) const + { + return !(*this == x); + } /*! * @brief This function sets a value in member index * @param _index New value for member index */ eProsima_user_DllExport void index( - uint32_t _index); + uint32_t _index) + { + m_index = _index; + } /*! * @brief This function returns the value of member index * @return Value of member index */ - eProsima_user_DllExport uint32_t index() const; + eProsima_user_DllExport uint32_t index() const + { + return m_index; + } /*! * @brief This function returns a reference to member index * @return Reference to member index */ - eProsima_user_DllExport uint32_t& index(); + eProsima_user_DllExport uint32_t& index() + { + return m_index; + } /*! @@ -160,26 +179,40 @@ class HelloWorld * @param _message New value to be copied in member message */ eProsima_user_DllExport void message( - const std::array& _message); + const std::array& _message) + { + m_message = _message; + } /*! * @brief This function moves the value in member message * @param _message New value to be moved in member message */ eProsima_user_DllExport void message( - std::array&& _message); + std::array&& _message) + { + m_message = std::move(_message); + } /*! * @brief This function returns a constant reference to member message * @return Constant reference to member message */ - eProsima_user_DllExport const std::array& message() const; + eProsima_user_DllExport const std::array& message() const + { + return m_message; + } /*! * @brief This function returns a reference to member message * @return Reference to member message */ - eProsima_user_DllExport std::array& message(); + eProsima_user_DllExport std::array& message() + { + return m_message; + } + + private: @@ -188,8 +221,6 @@ class HelloWorld }; -#endif // _FAST_DDS_GENERATED_HELLOWORLD_H_ - +#endif // _FAST_DDS_GENERATED_HELLOWORLD_HPP_ -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/BasicConfigurationExample/HelloWorldCdrAux.hpp b/examples/cpp/dds/BasicConfigurationExample/HelloWorldCdrAux.hpp index 5c8468e7cb1..de0e84c6ecd 100644 --- a/examples/cpp/dds/BasicConfigurationExample/HelloWorldCdrAux.hpp +++ b/examples/cpp/dds/BasicConfigurationExample/HelloWorldCdrAux.hpp @@ -22,7 +22,7 @@ #ifndef _FAST_DDS_GENERATED_HELLOWORLDCDRAUX_HPP_ #define _FAST_DDS_GENERATED_HELLOWORLDCDRAUX_HPP_ -#include "HelloWorld.h" +#include "HelloWorld.hpp" constexpr uint32_t HelloWorld_max_cdr_typesize {28UL}; constexpr uint32_t HelloWorld_max_key_cdr_typesize {0UL}; @@ -34,8 +34,6 @@ namespace fastcdr { class Cdr; class CdrSizeCalculator; - - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const HelloWorld& data); diff --git a/examples/cpp/dds/BasicConfigurationExample/HelloWorldCdrAux.ipp b/examples/cpp/dds/BasicConfigurationExample/HelloWorldCdrAux.ipp index 42e91f3cc38..97df3fe9d9e 100644 --- a/examples/cpp/dds/BasicConfigurationExample/HelloWorldCdrAux.ipp +++ b/examples/cpp/dds/BasicConfigurationExample/HelloWorldCdrAux.ipp @@ -34,8 +34,6 @@ using namespace eprosima::fastcdr::exception; namespace eprosima { namespace fastcdr { - - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, diff --git a/examples/cpp/dds/BasicConfigurationExample/HelloWorldPubSubTypes.cxx b/examples/cpp/dds/BasicConfigurationExample/HelloWorldPubSubTypes.cxx index 85cb477896e..db018e69782 100644 --- a/examples/cpp/dds/BasicConfigurationExample/HelloWorldPubSubTypes.cxx +++ b/examples/cpp/dds/BasicConfigurationExample/HelloWorldPubSubTypes.cxx @@ -19,18 +19,18 @@ * This file was generated by the tool fastddsgen. */ +#include "HelloWorldPubSubTypes.h" +#include #include -#include "HelloWorldPubSubTypes.h" #include "HelloWorldCdrAux.hpp" +#include "HelloWorldTypeObjectSupport.hpp" using SerializedPayload_t = eprosima::fastrtps::rtps::SerializedPayload_t; using InstanceHandle_t = eprosima::fastrtps::rtps::InstanceHandle_t; using DataRepresentationId_t = eprosima::fastdds::dds::DataRepresentationId_t; - - HelloWorldPubSubType::HelloWorldPubSubType() { setName("HelloWorld"); @@ -219,3 +219,11 @@ bool HelloWorldPubSubType::getKey( return true; } +void HelloWorldPubSubType::register_type_object_representation() const +{ + register_HelloWorld_type_objects(); +} + + +// Include auxiliary functions like for serializing/deserializing. +#include "HelloWorldCdrAux.ipp" diff --git a/examples/cpp/dds/BasicConfigurationExample/HelloWorldPubSubTypes.h b/examples/cpp/dds/BasicConfigurationExample/HelloWorldPubSubTypes.h index ddbfbab5db6..52736f6dad8 100644 --- a/examples/cpp/dds/BasicConfigurationExample/HelloWorldPubSubTypes.h +++ b/examples/cpp/dds/BasicConfigurationExample/HelloWorldPubSubTypes.h @@ -27,9 +27,9 @@ #include #include #include -#include +#include -#include "HelloWorld.h" +#include "HelloWorld.hpp" #if !defined(GEN_API_VER) || (GEN_API_VER != 2) @@ -38,8 +38,6 @@ #endif // GEN_API_VER - - /*! * @brief This class represents the TopicDataType of the type HelloWorld defined by the user in the IDL file. * @ingroup HelloWorld @@ -90,6 +88,9 @@ class HelloWorldPubSubType : public eprosima::fastdds::dds::TopicDataType eProsima_user_DllExport void deleteData( void* data) override; + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + #ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED eProsima_user_DllExport inline bool is_bounded() const override { diff --git a/examples/cpp/dds/BasicConfigurationExample/HelloWorldTypeObjectSupport.cxx b/examples/cpp/dds/BasicConfigurationExample/HelloWorldTypeObjectSupport.cxx new file mode 100644 index 00000000000..8c30e9795fe --- /dev/null +++ b/examples/cpp/dds/BasicConfigurationExample/HelloWorldTypeObjectSupport.cxx @@ -0,0 +1,306 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file HelloWorldTypeObjectSupport.cxx + * Source file containing the implementation to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#include "HelloWorldTypeObjectSupport.hpp" + +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include + +#include "HelloWorld.hpp" + + +using namespace eprosima::fastdds::dds::xtypes; + +void register_HelloWorld_type_objects() +{ + static std::once_flag once_flag; + std::call_once(once_flag, []() + { + register_HelloWorld_type_identifier(); + + }); +} + +void register_HelloWorld_type_identifier() +{ + { + StructTypeFlag struct_flags_HelloWorld = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::NOT_APPLIED, + false, false); + ReturnCode_t return_code_HelloWorld; + TypeIdentifierPair type_ids_HelloWorld; + QualifiedTypeName type_name_HelloWorld = "HelloWorld"; + eprosima::fastcdr::optional type_ann_builtin_HelloWorld; + eprosima::fastcdr::optional ann_custom_HelloWorld; + CompleteTypeDetail detail_HelloWorld = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_HelloWorld, ann_custom_HelloWorld, type_name_HelloWorld.to_string()); + CompleteStructHeader header_HelloWorld; + header_HelloWorld = TypeObjectUtils::build_complete_struct_header(TypeIdentifier(), detail_HelloWorld); + CompleteStructMemberSeq member_seq_HelloWorld; + { + return_code_HelloWorld = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_uint32_t", type_ids_HelloWorld); + + if (return_code_HelloWorld != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "index Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_index = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_index; + MemberId member_id_index = 0x00000000; + if (EK_COMPLETE == type_ids_HelloWorld.type_identifier1()._d() || TK_NONE == type_ids_HelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_HelloWorld.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_HelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_HelloWorld.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure index member TypeIdentifier inconsistent."); + return; + } + MemberName name_index = "index"; + eprosima::fastcdr::optional member_ann_builtin_index; + ann_custom_HelloWorld.reset(); + CompleteMemberDetail detail_index = TypeObjectUtils::build_complete_member_detail(name_index, member_ann_builtin_index, ann_custom_HelloWorld); + CompleteStructMember member_index = TypeObjectUtils::build_complete_struct_member(common_index, detail_index); + TypeObjectUtils::add_complete_struct_member(member_seq_HelloWorld, member_index); + } + { + return_code_HelloWorld = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_array_char_20", type_ids_HelloWorld); + + if (return_code_HelloWorld != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_HelloWorld = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_char", type_ids_HelloWorld); + + if (return_code_HelloWorld != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Array element TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + TypeIdentifier* element_identifier_anonymous_array_char_20 {nullptr}; + if (EK_COMPLETE == type_ids_HelloWorld.type_identifier1()._d() || TK_NONE == type_ids_HelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_array_char_20 = new TypeIdentifier(type_ids_HelloWorld.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_HelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_array_char_20 = new TypeIdentifier(type_ids_HelloWorld.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Array element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_array_char_20 = EK_COMPLETE; + if (TK_NONE == type_ids_HelloWorld.type_identifier2()._d()) + { + equiv_kind_anonymous_array_char_20 = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_array_char_20 = 0; + PlainCollectionHeader header_anonymous_array_char_20 = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_array_char_20, element_flags_anonymous_array_char_20); + std::string type_id_kind_anonymous_array_char_20("TI_PLAIN_ARRAY_SMALL"); + if (type_id_kind_anonymous_array_char_20 == "TI_PLAIN_ARRAY_SMALL") + { + SBoundSeq array_bound_seq; + TypeObjectUtils::add_array_dimension(array_bound_seq, static_cast(20)); + + PlainArraySElemDefn array_sdefn = TypeObjectUtils::build_plain_array_s_elem_defn(header_anonymous_array_char_20, array_bound_seq, + eprosima::fastcdr::external(element_identifier_anonymous_array_char_20)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_array_type_identifier(array_sdefn, "anonymous_array_char_20")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_char_20 already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBoundSeq array_bound_seq; + TypeObjectUtils::add_array_dimension(array_bound_seq, static_cast(20)); + + PlainArrayLElemDefn array_ldefn = TypeObjectUtils::build_plain_array_l_elem_defn(header_anonymous_array_char_20, array_bound_seq, + eprosima::fastcdr::external(element_identifier_anonymous_array_char_20)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_array_type_identifier(array_ldefn, "anonymous_array_char_20")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_char_20 already registered in TypeObjectRegistry for a different type."); + } + } + return_code_HelloWorld = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_array_char_20", type_ids_HelloWorld); + if (return_code_HelloWorld != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_char_20: Given Array TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_message = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_message; + MemberId member_id_message = 0x00000001; + if (EK_COMPLETE == type_ids_HelloWorld.type_identifier1()._d() || TK_NONE == type_ids_HelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_message = TypeObjectUtils::build_common_struct_member(member_id_message, member_flags_message, type_ids_HelloWorld.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_HelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_message = TypeObjectUtils::build_common_struct_member(member_id_message, member_flags_message, type_ids_HelloWorld.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure message member TypeIdentifier inconsistent."); + return; + } + MemberName name_message = "message"; + eprosima::fastcdr::optional member_ann_builtin_message; + ann_custom_HelloWorld.reset(); + CompleteMemberDetail detail_message = TypeObjectUtils::build_complete_member_detail(name_message, member_ann_builtin_message, ann_custom_HelloWorld); + CompleteStructMember member_message = TypeObjectUtils::build_complete_struct_member(common_message, detail_message); + TypeObjectUtils::add_complete_struct_member(member_seq_HelloWorld, member_message); + } + CompleteStructType struct_type_HelloWorld = TypeObjectUtils::build_complete_struct_type(struct_flags_HelloWorld, header_HelloWorld, member_seq_HelloWorld); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_struct_type_object(struct_type_HelloWorld, type_name_HelloWorld.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "HelloWorld already registered in TypeObjectRegistry for a different type."); + } + return_code_HelloWorld = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "HelloWorld", type_ids_HelloWorld); + if (return_code_HelloWorld != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "HelloWorld: Given Struct TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } +} + diff --git a/examples/cpp/dds/BasicConfigurationExample/HelloWorldTypeObjectSupport.hpp b/examples/cpp/dds/BasicConfigurationExample/HelloWorldTypeObjectSupport.hpp new file mode 100644 index 00000000000..8650fc061e0 --- /dev/null +++ b/examples/cpp/dds/BasicConfigurationExample/HelloWorldTypeObjectSupport.hpp @@ -0,0 +1,54 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file HelloWorldTypeObjectSupport.hpp + * Header file containing the API required to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#ifndef _FAST_DDS_GENERATED_HELLOWORLD_TYPE_OBJECT_SUPPORT_HPP_ +#define _FAST_DDS_GENERATED_HELLOWORLD_TYPE_OBJECT_SUPPORT_HPP_ + + +#if defined(_WIN32) +#if defined(EPROSIMA_USER_DLL_EXPORT) +#define eProsima_user_DllExport __declspec( dllexport ) +#else +#define eProsima_user_DllExport +#endif // EPROSIMA_USER_DLL_EXPORT +#else +#define eProsima_user_DllExport +#endif // _WIN32 + +/** + * @brief Register every TypeObject representation defined in the IDL file in Fast DDS TypeObjectRegistry. + */ +eProsima_user_DllExport void register_HelloWorld_type_objects(); + +#ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +/** + * @brief Register HelloWorld related TypeIdentifier. + * Fully-descriptive TypeIdentifiers are directly registered. + * Hash TypeIdentifiers require to fill the TypeObject information and hash it, consequently, the TypeObject is + * indirectly registered as well. + */ +void register_HelloWorld_type_identifier(); + + +#endif // DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +#endif // _FAST_DDS_GENERATED_HELLOWORLD_TYPE_OBJECT_SUPPORT_HPP_ diff --git a/examples/cpp/dds/BasicConfigurationExample/HelloWorldv1.cxx b/examples/cpp/dds/BasicConfigurationExample/HelloWorldv1.cxx deleted file mode 100644 index 3b9a562b692..00000000000 --- a/examples/cpp/dds/BasicConfigurationExample/HelloWorldv1.cxx +++ /dev/null @@ -1,288 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file HelloWorld.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "HelloWorld.h" - -#if FASTCDR_VERSION_MAJOR == 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - -namespace helper { namespace internal { - -enum class Size { - UInt8, - UInt16, - UInt32, - UInt64, -}; - -constexpr Size get_size(int s) { - return (s <= 8 ) ? Size::UInt8: - (s <= 16) ? Size::UInt16: - (s <= 32) ? Size::UInt32: Size::UInt64; -} - -template -struct FindTypeH; - -template<> -struct FindTypeH { - using type = std::uint8_t; -}; - -template<> -struct FindTypeH { - using type = std::uint16_t; -}; - -template<> -struct FindTypeH { - using type = std::uint32_t; -}; - -template<> -struct FindTypeH { - using type = std::uint64_t; -}; -} - -template -struct FindType { - using type = typename internal::FindTypeH::type; -}; -} - -#define HelloWorld_max_cdr_typesize 28ULL; - - - - -HelloWorld::HelloWorld() -{ - // unsigned long m_index - m_index = 0; - // char m_message - memset(&m_message, 0, ((20)) * 1); - -} - -HelloWorld::~HelloWorld() -{ -} - -HelloWorld::HelloWorld( - const HelloWorld& x) -{ - m_index = x.m_index; - - - m_message = x.m_message; - -} - -HelloWorld::HelloWorld( - HelloWorld&& x) noexcept -{ - m_index = x.m_index; - - - m_message = std::move(x.m_message); - -} - -HelloWorld& HelloWorld::operator =( - const HelloWorld& x) -{ - m_index = x.m_index; - - - m_message = x.m_message; - - return *this; -} - -HelloWorld& HelloWorld::operator =( - HelloWorld&& x) noexcept -{ - m_index = x.m_index; - - - m_message = std::move(x.m_message); - - return *this; -} - -bool HelloWorld::operator ==( - const HelloWorld& x) const -{ - return (m_index == x.m_index && - m_message == x.m_message); -} - -bool HelloWorld::operator !=( - const HelloWorld& x) const -{ - return !(*this == x); -} - -size_t HelloWorld::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return HelloWorld_max_cdr_typesize; -} - -size_t HelloWorld::getCdrSerializedSize( - const HelloWorld& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += (((20)) * 1) + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - - return current_alignment - initial_alignment; -} - - -void HelloWorld::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_index; - - scdr << m_message; - - -} - -void HelloWorld::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_index; - - - - dcdr >> m_message; - - -} - - -bool HelloWorld::isKeyDefined() -{ - return false; -} - -void HelloWorld::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void HelloWorld::index( - uint32_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint32_t HelloWorld::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint32_t& HelloWorld::index() -{ - return m_index; -} - - -/*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ -void HelloWorld::message( - const std::array& _message) -{ - m_message = _message; -} - -/*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ -void HelloWorld::message( - std::array&& _message) -{ - m_message = std::move(_message); -} - -/*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ -const std::array& HelloWorld::message() const -{ - return m_message; -} - -/*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ -std::array& HelloWorld::message() -{ - return m_message; -} - - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/BasicConfigurationExample/HelloWorldv1.h b/examples/cpp/dds/BasicConfigurationExample/HelloWorldv1.h deleted file mode 100644 index d4554ac83a2..00000000000 --- a/examples/cpp/dds/BasicConfigurationExample/HelloWorldv1.h +++ /dev/null @@ -1,244 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file HelloWorld.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#include - -#if FASTCDR_VERSION_MAJOR == 1 - -#ifndef _FAST_DDS_GENERATED_HELLOWORLD_H_ -#define _FAST_DDS_GENERATED_HELLOWORLD_H_ - - -#include - -#include -#include -#include -#include -#include -#include -#include - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define eProsima_user_DllExport -#endif // _WIN32 - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(HELLOWORLD_SOURCE) -#define HELLOWORLD_DllAPI __declspec( dllexport ) -#else -#define HELLOWORLD_DllAPI __declspec( dllimport ) -#endif // HELLOWORLD_SOURCE -#else -#define HELLOWORLD_DllAPI -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define HELLOWORLD_DllAPI -#endif // _WIN32 - -namespace eprosima { -namespace fastcdr { -class Cdr; -} // namespace fastcdr -} // namespace eprosima - - - - - -/*! - * @brief This class represents the structure HelloWorld defined by the user in the IDL file. - * @ingroup HelloWorld - */ -class HelloWorld -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport HelloWorld(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~HelloWorld(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object HelloWorld that will be copied. - */ - eProsima_user_DllExport HelloWorld( - const HelloWorld& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object HelloWorld that will be copied. - */ - eProsima_user_DllExport HelloWorld( - HelloWorld&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object HelloWorld that will be copied. - */ - eProsima_user_DllExport HelloWorld& operator =( - const HelloWorld& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object HelloWorld that will be copied. - */ - eProsima_user_DllExport HelloWorld& operator =( - HelloWorld&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x HelloWorld object to compare. - */ - eProsima_user_DllExport bool operator ==( - const HelloWorld& x) const; - - /*! - * @brief Comparison operator. - * @param x HelloWorld object to compare. - */ - eProsima_user_DllExport bool operator !=( - const HelloWorld& x) const; - - /*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ - eProsima_user_DllExport void index( - uint32_t _index); - - /*! - * @brief This function returns the value of member index - * @return Value of member index - */ - eProsima_user_DllExport uint32_t index() const; - - /*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ - eProsima_user_DllExport uint32_t& index(); - - - /*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ - eProsima_user_DllExport void message( - const std::array& _message); - - /*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ - eProsima_user_DllExport void message( - std::array&& _message); - - /*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ - eProsima_user_DllExport const std::array& message() const; - - /*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ - eProsima_user_DllExport std::array& message(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const HelloWorld& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - uint32_t m_index; - std::array m_message; - -}; - - -#endif // _FAST_DDS_GENERATED_HELLOWORLD_H_ - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/BasicConfigurationExample/README.md b/examples/cpp/dds/BasicConfigurationExample/README.md index 02f3c1a7ef9..a95ef86a3f9 100644 --- a/examples/cpp/dds/BasicConfigurationExample/README.md +++ b/examples/cpp/dds/BasicConfigurationExample/README.md @@ -66,7 +66,7 @@ QoS options: Discovery options: --ttl Set multicast discovery Time To Live on IPv4 or Hop Limit - for IPv6. If not set, uses Fast-DDS default (1 hop). + for IPv6. If not set, uses Fast DDS default (1 hop). Increase it to avoid discovery issues on scenarios with several routers. Maximum: 255. ``` diff --git a/examples/cpp/dds/BasicConfigurationExample/arg_configuration.h b/examples/cpp/dds/BasicConfigurationExample/arg_configuration.h index 84d58fd68b3..2d8154fcdb1 100644 --- a/examples/cpp/dds/BasicConfigurationExample/arg_configuration.h +++ b/examples/cpp/dds/BasicConfigurationExample/arg_configuration.h @@ -220,7 +220,7 @@ const option::Descriptor usage[] = { { UNKNOWN_OPT, 0, "", "", Arg::None, "\nDiscovery options:"}, { TTL, 0, "", "ttl", Arg::NumericRange<1, 255>, "\t--ttl \tSet multicast discovery Time To Live on IPv4 or Hop Limit for IPv6." - " If not set, uses Fast-DDS default (1 hop). Increase it to avoid discovery issues" + " If not set, uses Fast DDS default (1 hop). Increase it to avoid discovery issues" " on scenarios with several routers. Maximum: 255."}, { 0, 0, 0, 0, 0, 0 } diff --git a/examples/cpp/dds/CMakeLists.txt b/examples/cpp/dds/CMakeLists.txt index 421eb164dcb..0ade7a00048 100644 --- a/examples/cpp/dds/CMakeLists.txt +++ b/examples/cpp/dds/CMakeLists.txt @@ -39,7 +39,6 @@ add_subdirectory(SampleConfig_Controller) add_subdirectory(SampleConfig_Events) add_subdirectory(SampleConfig_Multimedia) add_subdirectory(StaticHelloWorldExample) -add_subdirectory(TypeLookupService) add_subdirectory(WriterLoansExample) add_subdirectory(ZeroCopyExample) diff --git a/examples/cpp/dds/Configurability/CMakeLists.txt b/examples/cpp/dds/Configurability/CMakeLists.txt index 3be7f877c7d..d86f271d8c7 100644 --- a/examples/cpp/dds/Configurability/CMakeLists.txt +++ b/examples/cpp/dds/Configurability/CMakeLists.txt @@ -25,8 +25,8 @@ if(NOT foonathan_memory_FOUND) find_package(foonathan_memory REQUIRED) endif() -if(NOT fastrtps_FOUND) - find_package(fastrtps 2.12 REQUIRED) +if(NOT fastdds_FOUND) + find_package(fastdds 3 REQUIRED) endif() #Check C++11 @@ -47,7 +47,7 @@ target_compile_definitions(DDSConfigurabilityPublisher PRIVATE $<$>,$>:__DEBUG> $<$:__INTERNALDEBUG> # Internal debug activated. ) -target_link_libraries(DDSConfigurabilityPublisher fastrtps fastcdr foonathan_memory) +target_link_libraries(DDSConfigurabilityPublisher fastdds fastcdr foonathan_memory) install(TARGETS DDSConfigurabilityPublisher RUNTIME DESTINATION examples/cpp/dds/Configurability/${BIN_INSTALL_DIR} ) @@ -57,7 +57,7 @@ target_compile_definitions(DDSConfigurabilitySubscriber PRIVATE $<$>,$>:__DEBUG> $<$:__INTERNALDEBUG> # Internal debug activated. ) -target_link_libraries(DDSConfigurabilitySubscriber fastrtps fastcdr foonathan_memory) +target_link_libraries(DDSConfigurabilitySubscriber fastdds fastcdr foonathan_memory) install(TARGETS DDSConfigurabilitySubscriber RUNTIME DESTINATION examples/cpp/dds/Configurability/${BIN_INSTALL_DIR} ) diff --git a/examples/cpp/dds/Configurability/ConfigurabilityPublisher.cpp b/examples/cpp/dds/Configurability/ConfigurabilityPublisher.cpp index 608ad437ec7..26b13df5869 100644 --- a/examples/cpp/dds/Configurability/ConfigurabilityPublisher.cpp +++ b/examples/cpp/dds/Configurability/ConfigurabilityPublisher.cpp @@ -1,8 +1,8 @@ /*** - * Use Case Demonstrator for eProsima Fast RTPS + * Use Case Demonstrator for eProsima Fast DDS * -------------------------------------------- * - * This is an interactive program designed to show the effect of different configuration parameters on the behaviour of eProsima Fast RTPS + * This is an interactive program designed to show the effect of different configuration parameters on the behaviour of eProsima Fast DDS * ***/ diff --git a/examples/cpp/dds/Configurability/ConfigurabilitySubscriber.cpp b/examples/cpp/dds/Configurability/ConfigurabilitySubscriber.cpp index 6c5f7702357..4094a972244 100644 --- a/examples/cpp/dds/Configurability/ConfigurabilitySubscriber.cpp +++ b/examples/cpp/dds/Configurability/ConfigurabilitySubscriber.cpp @@ -1,8 +1,8 @@ /*** - * Use Case Demonstrator for eProsima Fast RTPS + * Use Case Demonstrator for eProsima Fast DDS * -------------------------------------------- * - * This is an interactive program designed to show the effect of different configuration parameters on the behaviour of eProsima Fast RTPS + * This is an interactive program designed to show the effect of different configuration parameters on the behaviour of eProsima Fast DDS * ***/ @@ -363,7 +363,7 @@ int main() } else if ( c == std::string("r")) { - while (EarlyReader->read_next_sample(&my_sample, &sample_info) == ReturnCode_t::RETCODE_OK) + while (EarlyReader->read_next_sample(&my_sample, &sample_info) == RETCODE_OK) { std::cout << "Sample Received! Index:" << std::to_string(my_sample.index()) << " Key:" << std::to_string(my_sample.key_value()) << std::endl; diff --git a/examples/cpp/dds/Configurability/sample.cxx b/examples/cpp/dds/Configurability/sample.cxx deleted file mode 100644 index 360d4a1b2b2..00000000000 --- a/examples/cpp/dds/Configurability/sample.cxx +++ /dev/null @@ -1,158 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file sample.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "sample.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - - - - -sample::sample() -{ -} - -sample::~sample() -{ -} - -sample::sample( - const sample& x) -{ - m_index = x.m_index; - m_key_value = x.m_key_value; -} - -sample::sample( - sample&& x) noexcept -{ - m_index = x.m_index; - m_key_value = x.m_key_value; -} - -sample& sample::operator =( - const sample& x) -{ - - m_index = x.m_index; - m_key_value = x.m_key_value; - return *this; -} - -sample& sample::operator =( - sample&& x) noexcept -{ - - m_index = x.m_index; - m_key_value = x.m_key_value; - return *this; -} - -bool sample::operator ==( - const sample& x) const -{ - return (m_index == x.m_index && - m_key_value == x.m_key_value); -} - -bool sample::operator !=( - const sample& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void sample::index( - uint8_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint8_t sample::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint8_t& sample::index() -{ - return m_index; -} - - -/*! - * @brief This function sets a value in member key_value - * @param _key_value New value for member key_value - */ -void sample::key_value( - uint8_t _key_value) -{ - m_key_value = _key_value; -} - -/*! - * @brief This function returns the value of member key_value - * @return Value of member key_value - */ -uint8_t sample::key_value() const -{ - return m_key_value; -} - -/*! - * @brief This function returns a reference to member key_value - * @return Reference to member key_value - */ -uint8_t& sample::key_value() -{ - return m_key_value; -} - - -// Include auxiliary functions like for serializing/deserializing. -#include "sampleCdrAux.ipp" - -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/HistoryKind/sample.h b/examples/cpp/dds/Configurability/sample.hpp similarity index 69% rename from examples/cpp/dds/HistoryKind/sample.h rename to examples/cpp/dds/Configurability/sample.hpp index c050c8527cc..3023a792269 100644 --- a/examples/cpp/dds/HistoryKind/sample.h +++ b/examples/cpp/dds/Configurability/sample.hpp @@ -13,32 +13,17 @@ // limitations under the License. /*! - * @file sample.h + * @file sample.hpp * This header file contains the declaration of the described types in the IDL file. * * This file was generated by the tool fastddsgen. */ -#include -#include "samplev1.h" +#ifndef _FAST_DDS_GENERATED_SAMPLE_HPP_ +#define _FAST_DDS_GENERATED_SAMPLE_HPP_ -#if FASTCDR_VERSION_MAJOR > 1 - -#ifndef _FAST_DDS_GENERATED_SAMPLE_H_ -#define _FAST_DDS_GENERATED_SAMPLE_H_ - -#include -#include #include -#include -#include -#include - -#include -#include -#include - - +#include #if defined(_WIN32) #if defined(EPROSIMA_USER_DLL_EXPORT) @@ -64,17 +49,6 @@ #define SAMPLE_DllAPI #endif // _WIN32 -namespace eprosima { -namespace fastcdr { -class Cdr; -class CdrSizeCalculator; -} // namespace fastcdr -} // namespace eprosima - - - - - /*! * @brief This class represents the structure sample defined by the user in the IDL file. * @ingroup sample @@ -86,73 +60,117 @@ class sample /*! * @brief Default constructor. */ - eProsima_user_DllExport sample(); + eProsima_user_DllExport sample() + { + } /*! * @brief Default destructor. */ - eProsima_user_DllExport ~sample(); + eProsima_user_DllExport ~sample() + { + } /*! * @brief Copy constructor. * @param x Reference to the object sample that will be copied. */ eProsima_user_DllExport sample( - const sample& x); + const sample& x) + { + m_index = x.m_index; + + m_key_value = x.m_key_value; + + } /*! * @brief Move constructor. * @param x Reference to the object sample that will be copied. */ eProsima_user_DllExport sample( - sample&& x) noexcept; + sample&& x) noexcept + { + m_index = x.m_index; + m_key_value = x.m_key_value; + } /*! * @brief Copy assignment. * @param x Reference to the object sample that will be copied. */ eProsima_user_DllExport sample& operator =( - const sample& x); + const sample& x) + { + + m_index = x.m_index; + + m_key_value = x.m_key_value; + + return *this; + } /*! * @brief Move assignment. * @param x Reference to the object sample that will be copied. */ eProsima_user_DllExport sample& operator =( - sample&& x) noexcept; + sample&& x) noexcept + { + + m_index = x.m_index; + m_key_value = x.m_key_value; + return *this; + } /*! * @brief Comparison operator. * @param x sample object to compare. */ eProsima_user_DllExport bool operator ==( - const sample& x) const; + const sample& x) const + { + return (m_index == x.m_index && + m_key_value == x.m_key_value); + } /*! * @brief Comparison operator. * @param x sample object to compare. */ eProsima_user_DllExport bool operator !=( - const sample& x) const; + const sample& x) const + { + return !(*this == x); + } /*! * @brief This function sets a value in member index * @param _index New value for member index */ eProsima_user_DllExport void index( - uint8_t _index); + uint8_t _index) + { + m_index = _index; + } /*! * @brief This function returns the value of member index * @return Value of member index */ - eProsima_user_DllExport uint8_t index() const; + eProsima_user_DllExport uint8_t index() const + { + return m_index; + } /*! * @brief This function returns a reference to member index * @return Reference to member index */ - eProsima_user_DllExport uint8_t& index(); + eProsima_user_DllExport uint8_t& index() + { + return m_index; + } /*! @@ -160,19 +178,30 @@ class sample * @param _key_value New value for member key_value */ eProsima_user_DllExport void key_value( - uint8_t _key_value); + uint8_t _key_value) + { + m_key_value = _key_value; + } /*! * @brief This function returns the value of member key_value * @return Value of member key_value */ - eProsima_user_DllExport uint8_t key_value() const; + eProsima_user_DllExport uint8_t key_value() const + { + return m_key_value; + } /*! * @brief This function returns a reference to member key_value * @return Reference to member key_value */ - eProsima_user_DllExport uint8_t& key_value(); + eProsima_user_DllExport uint8_t& key_value() + { + return m_key_value; + } + + private: @@ -181,8 +210,6 @@ class sample }; -#endif // _FAST_DDS_GENERATED_SAMPLE_H_ - +#endif // _FAST_DDS_GENERATED_SAMPLE_HPP_ -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/Configurability/sampleCdrAux.hpp b/examples/cpp/dds/Configurability/sampleCdrAux.hpp index 18ed5857add..b80dff31248 100644 --- a/examples/cpp/dds/Configurability/sampleCdrAux.hpp +++ b/examples/cpp/dds/Configurability/sampleCdrAux.hpp @@ -22,7 +22,7 @@ #ifndef _FAST_DDS_GENERATED_SAMPLECDRAUX_HPP_ #define _FAST_DDS_GENERATED_SAMPLECDRAUX_HPP_ -#include "sample.h" +#include "sample.hpp" constexpr uint32_t sample_max_cdr_typesize {6UL}; constexpr uint32_t sample_max_key_cdr_typesize {1UL}; @@ -34,8 +34,6 @@ namespace fastcdr { class Cdr; class CdrSizeCalculator; - - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const sample& data); diff --git a/examples/cpp/dds/Configurability/sampleCdrAux.ipp b/examples/cpp/dds/Configurability/sampleCdrAux.ipp index 11bc4709a6e..17a3d1025fc 100644 --- a/examples/cpp/dds/Configurability/sampleCdrAux.ipp +++ b/examples/cpp/dds/Configurability/sampleCdrAux.ipp @@ -34,8 +34,6 @@ using namespace eprosima::fastcdr::exception; namespace eprosima { namespace fastcdr { - - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, diff --git a/examples/cpp/dds/Configurability/samplePubSubTypes.cxx b/examples/cpp/dds/Configurability/samplePubSubTypes.cxx index 9095d77083a..cae143a08ca 100644 --- a/examples/cpp/dds/Configurability/samplePubSubTypes.cxx +++ b/examples/cpp/dds/Configurability/samplePubSubTypes.cxx @@ -19,18 +19,18 @@ * This file was generated by the tool fastddsgen. */ +#include "samplePubSubTypes.h" +#include #include -#include "samplePubSubTypes.h" #include "sampleCdrAux.hpp" +#include "sampleTypeObjectSupport.hpp" using SerializedPayload_t = eprosima::fastrtps::rtps::SerializedPayload_t; using InstanceHandle_t = eprosima::fastrtps::rtps::InstanceHandle_t; using DataRepresentationId_t = eprosima::fastdds::dds::DataRepresentationId_t; - - samplePubSubType::samplePubSubType() { setName("sample"); @@ -219,3 +219,11 @@ bool samplePubSubType::getKey( return true; } +void samplePubSubType::register_type_object_representation() const +{ + register_sample_type_objects(); +} + + +// Include auxiliary functions like for serializing/deserializing. +#include "sampleCdrAux.ipp" diff --git a/examples/cpp/dds/Configurability/samplePubSubTypes.h b/examples/cpp/dds/Configurability/samplePubSubTypes.h index ec881115211..9e59aa58042 100644 --- a/examples/cpp/dds/Configurability/samplePubSubTypes.h +++ b/examples/cpp/dds/Configurability/samplePubSubTypes.h @@ -27,9 +27,9 @@ #include #include #include -#include +#include -#include "sample.h" +#include "sample.hpp" #if !defined(GEN_API_VER) || (GEN_API_VER != 2) @@ -38,8 +38,6 @@ #endif // GEN_API_VER - - /*! * @brief This class represents the TopicDataType of the type sample defined by the user in the IDL file. * @ingroup sample @@ -90,6 +88,9 @@ class samplePubSubType : public eprosima::fastdds::dds::TopicDataType eProsima_user_DllExport void deleteData( void* data) override; + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + #ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED eProsima_user_DllExport inline bool is_bounded() const override { diff --git a/examples/cpp/dds/Configurability/sampleTypeObjectSupport.cxx b/examples/cpp/dds/Configurability/sampleTypeObjectSupport.cxx new file mode 100644 index 00000000000..3719bbf77e6 --- /dev/null +++ b/examples/cpp/dds/Configurability/sampleTypeObjectSupport.cxx @@ -0,0 +1,224 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file sampleTypeObjectSupport.cxx + * Source file containing the implementation to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#include "sampleTypeObjectSupport.hpp" + +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include + +#include "sample.hpp" + + +using namespace eprosima::fastdds::dds::xtypes; + +void register_sample_type_objects() +{ + static std::once_flag once_flag; + std::call_once(once_flag, []() + { + register_sample_type_identifier(); + + }); +} + +void register_sample_type_identifier() +{ + { + StructTypeFlag struct_flags_sample = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::NOT_APPLIED, + false, false); + ReturnCode_t return_code_sample; + TypeIdentifierPair type_ids_sample; + QualifiedTypeName type_name_sample = "sample"; + eprosima::fastcdr::optional type_ann_builtin_sample; + eprosima::fastcdr::optional ann_custom_sample; + CompleteTypeDetail detail_sample = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_sample, ann_custom_sample, type_name_sample.to_string()); + CompleteStructHeader header_sample; + header_sample = TypeObjectUtils::build_complete_struct_header(TypeIdentifier(), detail_sample); + CompleteStructMemberSeq member_seq_sample; + { + return_code_sample = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_byte", type_ids_sample); + + if (return_code_sample != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "index Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_index = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_index; + MemberId member_id_index = 0x00000000; + if (EK_COMPLETE == type_ids_sample.type_identifier1()._d() || TK_NONE == type_ids_sample.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_sample.type_identifier1()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_sample.type_identifier1()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_sample.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_sample.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_sample.type_identifier2()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_sample.type_identifier2()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_sample.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure index member TypeIdentifier inconsistent."); + return; + } + MemberName name_index = "index"; + eprosima::fastcdr::optional member_ann_builtin_index; + ann_custom_sample.reset(); + CompleteMemberDetail detail_index = TypeObjectUtils::build_complete_member_detail(name_index, member_ann_builtin_index, ann_custom_sample); + CompleteStructMember member_index = TypeObjectUtils::build_complete_struct_member(common_index, detail_index); + TypeObjectUtils::add_complete_struct_member(member_seq_sample, member_index); + } + { + return_code_sample = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_byte", type_ids_sample); + + if (return_code_sample != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "key_value Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_key_value = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, true, false); + CommonStructMember common_key_value; + MemberId member_id_key_value = 0x00000001; + if (EK_COMPLETE == type_ids_sample.type_identifier1()._d() || TK_NONE == type_ids_sample.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_sample.type_identifier1()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_sample.type_identifier1()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_key_value = TypeObjectUtils::build_common_struct_member(member_id_key_value, member_flags_key_value, type_ids_sample.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_sample.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_sample.type_identifier2()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_sample.type_identifier2()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_key_value = TypeObjectUtils::build_common_struct_member(member_id_key_value, member_flags_key_value, type_ids_sample.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure key_value member TypeIdentifier inconsistent."); + return; + } + MemberName name_key_value = "key_value"; + eprosima::fastcdr::optional member_ann_builtin_key_value; + ann_custom_sample.reset(); + AppliedAnnotationSeq tmp_ann_custom_key_value; + eprosima::fastcdr::optional unit_key_value; + eprosima::fastcdr::optional min_key_value; + eprosima::fastcdr::optional max_key_value; + eprosima::fastcdr::optional hash_id_key_value; + if (unit_key_value.has_value() || min_key_value.has_value() || max_key_value.has_value() || hash_id_key_value.has_value()) + { + member_ann_builtin_key_value = TypeObjectUtils::build_applied_builtin_member_annotations(unit_key_value, min_key_value, max_key_value, hash_id_key_value); + } + if (!tmp_ann_custom_key_value.empty()) + { + ann_custom_sample = tmp_ann_custom_key_value; + } + CompleteMemberDetail detail_key_value = TypeObjectUtils::build_complete_member_detail(name_key_value, member_ann_builtin_key_value, ann_custom_sample); + CompleteStructMember member_key_value = TypeObjectUtils::build_complete_struct_member(common_key_value, detail_key_value); + TypeObjectUtils::add_complete_struct_member(member_seq_sample, member_key_value); + } + CompleteStructType struct_type_sample = TypeObjectUtils::build_complete_struct_type(struct_flags_sample, header_sample, member_seq_sample); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_struct_type_object(struct_type_sample, type_name_sample.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "sample already registered in TypeObjectRegistry for a different type."); + } + return_code_sample = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "sample", type_ids_sample); + if (return_code_sample != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "sample: Given Struct TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } +} + diff --git a/examples/cpp/dds/Configurability/sampleTypeObjectSupport.hpp b/examples/cpp/dds/Configurability/sampleTypeObjectSupport.hpp new file mode 100644 index 00000000000..5ad7f2e5e07 --- /dev/null +++ b/examples/cpp/dds/Configurability/sampleTypeObjectSupport.hpp @@ -0,0 +1,54 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file sampleTypeObjectSupport.hpp + * Header file containing the API required to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#ifndef _FAST_DDS_GENERATED_SAMPLE_TYPE_OBJECT_SUPPORT_HPP_ +#define _FAST_DDS_GENERATED_SAMPLE_TYPE_OBJECT_SUPPORT_HPP_ + + +#if defined(_WIN32) +#if defined(EPROSIMA_USER_DLL_EXPORT) +#define eProsima_user_DllExport __declspec( dllexport ) +#else +#define eProsima_user_DllExport +#endif // EPROSIMA_USER_DLL_EXPORT +#else +#define eProsima_user_DllExport +#endif // _WIN32 + +/** + * @brief Register every TypeObject representation defined in the IDL file in Fast DDS TypeObjectRegistry. + */ +eProsima_user_DllExport void register_sample_type_objects(); + +#ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +/** + * @brief Register sample related TypeIdentifier. + * Fully-descriptive TypeIdentifiers are directly registered. + * Hash TypeIdentifiers require to fill the TypeObject information and hash it, consequently, the TypeObject is + * indirectly registered as well. + */ +void register_sample_type_identifier(); + + +#endif // DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +#endif // _FAST_DDS_GENERATED_SAMPLE_TYPE_OBJECT_SUPPORT_HPP_ diff --git a/examples/cpp/dds/Configurability/samplev1.cxx b/examples/cpp/dds/Configurability/samplev1.cxx deleted file mode 100644 index 3b735befaf8..00000000000 --- a/examples/cpp/dds/Configurability/samplev1.cxx +++ /dev/null @@ -1,280 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file sample.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "sample.h" - -#if FASTCDR_VERSION_MAJOR == 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - -namespace helper { namespace internal { - -enum class Size { - UInt8, - UInt16, - UInt32, - UInt64, -}; - -constexpr Size get_size(int s) { - return (s <= 8 ) ? Size::UInt8: - (s <= 16) ? Size::UInt16: - (s <= 32) ? Size::UInt32: Size::UInt64; -} - -template -struct FindTypeH; - -template<> -struct FindTypeH { - using type = std::uint8_t; -}; - -template<> -struct FindTypeH { - using type = std::uint16_t; -}; - -template<> -struct FindTypeH { - using type = std::uint32_t; -}; - -template<> -struct FindTypeH { - using type = std::uint64_t; -}; -} - -template -struct FindType { - using type = typename internal::FindTypeH::type; -}; -} - -#define sample_max_cdr_typesize 6ULL; - - - - -sample::sample() -{ - // octet m_index - m_index = 0; - // octet m_key_value - m_key_value = 0; - -} - -sample::~sample() -{ -} - -sample::sample( - const sample& x) -{ - m_index = x.m_index; - - - m_key_value = x.m_key_value; - -} - -sample::sample( - sample&& x) noexcept -{ - m_index = x.m_index; - - - m_key_value = x.m_key_value; - -} - -sample& sample::operator =( - const sample& x) -{ - m_index = x.m_index; - - - m_key_value = x.m_key_value; - - return *this; -} - -sample& sample::operator =( - sample&& x) noexcept -{ - m_index = x.m_index; - - - m_key_value = x.m_key_value; - - return *this; -} - -bool sample::operator ==( - const sample& x) const -{ - return (m_index == x.m_index && - m_key_value == x.m_key_value); -} - -bool sample::operator !=( - const sample& x) const -{ - return !(*this == x); -} - -size_t sample::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return sample_max_cdr_typesize; -} - -size_t sample::getCdrSerializedSize( - const sample& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - return current_alignment - initial_alignment; -} - - -void sample::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_index; - - scdr << m_key_value; - -} - -void sample::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_index; - - - - dcdr >> m_key_value; - - -} - - -bool sample::isKeyDefined() -{ - return true; -} - -void sample::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; - - - scdr << m_key_value; - -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void sample::index( - uint8_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint8_t sample::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint8_t& sample::index() -{ - return m_index; -} - - -/*! - * @brief This function sets a value in member key_value - * @param _key_value New value for member key_value - */ -void sample::key_value( - uint8_t _key_value) -{ - m_key_value = _key_value; -} - -/*! - * @brief This function returns the value of member key_value - * @return Value of member key_value - */ -uint8_t sample::key_value() const -{ - return m_key_value; -} - -/*! - * @brief This function returns a reference to member key_value - * @return Reference to member key_value - */ -uint8_t& sample::key_value() -{ - return m_key_value; -} - - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/Configurability/samplev1.h b/examples/cpp/dds/Configurability/samplev1.h deleted file mode 100644 index 4fa288d1bc9..00000000000 --- a/examples/cpp/dds/Configurability/samplev1.h +++ /dev/null @@ -1,237 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file sample.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#include - -#if FASTCDR_VERSION_MAJOR == 1 - -#ifndef _FAST_DDS_GENERATED_SAMPLE_H_ -#define _FAST_DDS_GENERATED_SAMPLE_H_ - - -#include - -#include -#include -#include -#include -#include -#include -#include - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define eProsima_user_DllExport -#endif // _WIN32 - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(SAMPLE_SOURCE) -#define SAMPLE_DllAPI __declspec( dllexport ) -#else -#define SAMPLE_DllAPI __declspec( dllimport ) -#endif // SAMPLE_SOURCE -#else -#define SAMPLE_DllAPI -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define SAMPLE_DllAPI -#endif // _WIN32 - -namespace eprosima { -namespace fastcdr { -class Cdr; -} // namespace fastcdr -} // namespace eprosima - - - - - -/*! - * @brief This class represents the structure sample defined by the user in the IDL file. - * @ingroup sample - */ -class sample -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport sample(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~sample(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object sample that will be copied. - */ - eProsima_user_DllExport sample( - const sample& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object sample that will be copied. - */ - eProsima_user_DllExport sample( - sample&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object sample that will be copied. - */ - eProsima_user_DllExport sample& operator =( - const sample& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object sample that will be copied. - */ - eProsima_user_DllExport sample& operator =( - sample&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x sample object to compare. - */ - eProsima_user_DllExport bool operator ==( - const sample& x) const; - - /*! - * @brief Comparison operator. - * @param x sample object to compare. - */ - eProsima_user_DllExport bool operator !=( - const sample& x) const; - - /*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ - eProsima_user_DllExport void index( - uint8_t _index); - - /*! - * @brief This function returns the value of member index - * @return Value of member index - */ - eProsima_user_DllExport uint8_t index() const; - - /*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ - eProsima_user_DllExport uint8_t& index(); - - - /*! - * @brief This function sets a value in member key_value - * @param _key_value New value for member key_value - */ - eProsima_user_DllExport void key_value( - uint8_t _key_value); - - /*! - * @brief This function returns the value of member key_value - * @return Value of member key_value - */ - eProsima_user_DllExport uint8_t key_value() const; - - /*! - * @brief This function returns a reference to member key_value - * @return Reference to member key_value - */ - eProsima_user_DllExport uint8_t& key_value(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const sample& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - uint8_t m_index; - uint8_t m_key_value; - -}; - - -#endif // _FAST_DDS_GENERATED_SAMPLE_H_ - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/ContentFilteredTopicExample/CMakeLists.txt b/examples/cpp/dds/ContentFilteredTopicExample/CMakeLists.txt index abbbc4f3c0d..0eb3d11b4fc 100644 --- a/examples/cpp/dds/ContentFilteredTopicExample/CMakeLists.txt +++ b/examples/cpp/dds/ContentFilteredTopicExample/CMakeLists.txt @@ -21,8 +21,8 @@ if(NOT fastcdr_FOUND) find_package(fastcdr 2 REQUIRED) endif() -if(NOT fastrtps_FOUND) - find_package(fastrtps 2.12 REQUIRED) +if(NOT fastdds_FOUND) + find_package(fastdds 3 REQUIRED) endif() message(STATUS "Configuring ContentFilterTopic examples...") @@ -31,10 +31,8 @@ set(CFT_COMMON_SOURCES ContentFilteredTopicExample_main.cpp ContentFilteredTopicExamplePublisher.cpp ContentFilteredTopicExampleSubscriber.cpp - HelloWorld.cxx - HelloWorldv1.cxx HelloWorldPubSubTypes.cxx - HelloWorldTypeObject.cxx + HelloWorldTypeObjectSupport.cxx ) add_executable(DDSContentFilteredTopicExample ${CFT_COMMON_SOURCES}) @@ -43,6 +41,6 @@ target_compile_definitions(DDSContentFilteredTopicExample PRIVATE $<$:__INTERNALDEBUG> # Internal debug activated. ) target_compile_features(DDSContentFilteredTopicExample PRIVATE cxx_std_11) -target_link_libraries(DDSContentFilteredTopicExample fastrtps fastcdr fastdds::optionparser) +target_link_libraries(DDSContentFilteredTopicExample fastdds fastcdr fastdds::optionparser) install(TARGETS DDSContentFilteredTopicExample RUNTIME DESTINATION examples/cpp/dds/ContentFilteredTopicExample/${BIN_INSTALL_DIR}) diff --git a/examples/cpp/dds/ContentFilteredTopicExample/ContentFilteredTopicExamplePublisher.cpp b/examples/cpp/dds/ContentFilteredTopicExample/ContentFilteredTopicExamplePublisher.cpp index f1419c701e7..77e35423bce 100644 --- a/examples/cpp/dds/ContentFilteredTopicExample/ContentFilteredTopicExamplePublisher.cpp +++ b/examples/cpp/dds/ContentFilteredTopicExample/ContentFilteredTopicExamplePublisher.cpp @@ -29,16 +29,12 @@ #include #include -#include "HelloWorldTypeObject.h" +#include "HelloWorldTypeObjectSupport.hpp" using namespace eprosima::fastdds::dds; bool ContentFilteredTopicExamplePublisher::init() { - // The default filter class requires the TypeObject to be registered - // (see https://fast-dds.docs.eprosima.com/en/latest/fastdds/dds_layer/topic/contentFilteredTopic/createContentFilteredTopic.html) - registerHelloWorldTypes(); - // Initialize internal variables matched_ = 0; diff --git a/examples/cpp/dds/ContentFilteredTopicExample/ContentFilteredTopicExampleSubscriber.cpp b/examples/cpp/dds/ContentFilteredTopicExample/ContentFilteredTopicExampleSubscriber.cpp index 1a91342c43c..b116074dfe4 100644 --- a/examples/cpp/dds/ContentFilteredTopicExample/ContentFilteredTopicExampleSubscriber.cpp +++ b/examples/cpp/dds/ContentFilteredTopicExample/ContentFilteredTopicExampleSubscriber.cpp @@ -27,17 +27,13 @@ #include #include -#include "HelloWorldTypeObject.h" +#include "HelloWorldTypeObjectSupport.hpp" using namespace eprosima::fastdds::dds; bool ContentFilteredTopicExampleSubscriber::init( bool custom_filter) { - // The default filter class requires the TypeObject to be registered - // (see https://fast-dds.docs.eprosima.com/en/latest/fastdds/dds_layer/topic/contentFilteredTopic/createContentFilteredTopic.html) - registerHelloWorldTypes(); - // Initialize internal variables matched_ = 0; @@ -55,7 +51,7 @@ bool ContentFilteredTopicExampleSubscriber::init( if (custom_filter) { // Register the filter factory - if (ReturnCode_t::RETCODE_OK != + if (eprosima::fastdds::dds::RETCODE_OK != participant_->register_content_filter_factory("MY_CUSTOM_FILTER", &filter_factory)) { return false; @@ -159,7 +155,7 @@ void ContentFilteredTopicExampleSubscriber::on_data_available( { SampleInfo info; // Take next sample from DataReader's history - if (ReturnCode_t::RETCODE_OK == reader->take_next_sample(&hello_, &info)) + if (eprosima::fastdds::dds::RETCODE_OK == reader->take_next_sample(&hello_, &info)) { // Some samples only update the instance state. Only if it is a valid sample (with data) if (ALIVE_INSTANCE_STATE == info.instance_state) diff --git a/examples/cpp/dds/ContentFilteredTopicExample/HelloWorld.cxx b/examples/cpp/dds/ContentFilteredTopicExample/HelloWorld.cxx deleted file mode 100644 index 502f3953b05..00000000000 --- a/examples/cpp/dds/ContentFilteredTopicExample/HelloWorld.cxx +++ /dev/null @@ -1,172 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file HelloWorld.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "HelloWorld.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#include "HelloWorldTypeObject.h" - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - - - - -HelloWorld::HelloWorld() -{ - // Just to register all known types - registerHelloWorldTypes(); -} - -HelloWorld::~HelloWorld() -{ -} - -HelloWorld::HelloWorld( - const HelloWorld& x) -{ - m_index = x.m_index; - m_message = x.m_message; -} - -HelloWorld::HelloWorld( - HelloWorld&& x) noexcept -{ - m_index = x.m_index; - m_message = std::move(x.m_message); -} - -HelloWorld& HelloWorld::operator =( - const HelloWorld& x) -{ - - m_index = x.m_index; - m_message = x.m_message; - return *this; -} - -HelloWorld& HelloWorld::operator =( - HelloWorld&& x) noexcept -{ - - m_index = x.m_index; - m_message = std::move(x.m_message); - return *this; -} - -bool HelloWorld::operator ==( - const HelloWorld& x) const -{ - return (m_index == x.m_index && - m_message == x.m_message); -} - -bool HelloWorld::operator !=( - const HelloWorld& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void HelloWorld::index( - uint32_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint32_t HelloWorld::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint32_t& HelloWorld::index() -{ - return m_index; -} - - -/*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ -void HelloWorld::message( - const std::string& _message) -{ - m_message = _message; -} - -/*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ -void HelloWorld::message( - std::string&& _message) -{ - m_message = std::move(_message); -} - -/*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ -const std::string& HelloWorld::message() const -{ - return m_message; -} - -/*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ -std::string& HelloWorld::message() -{ - return m_message; -} - - -// Include auxiliary functions like for serializing/deserializing. -#include "HelloWorldCdrAux.ipp" - -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/HelloWorldExample/HelloWorld.h b/examples/cpp/dds/ContentFilteredTopicExample/HelloWorld.hpp similarity index 69% rename from examples/cpp/dds/HelloWorldExample/HelloWorld.h rename to examples/cpp/dds/ContentFilteredTopicExample/HelloWorld.hpp index 5cd0ddba511..971fea8d920 100644 --- a/examples/cpp/dds/HelloWorldExample/HelloWorld.h +++ b/examples/cpp/dds/ContentFilteredTopicExample/HelloWorld.hpp @@ -13,32 +13,19 @@ // limitations under the License. /*! - * @file HelloWorld.h + * @file HelloWorld.hpp * This header file contains the declaration of the described types in the IDL file. * * This file was generated by the tool fastddsgen. */ -#include -#include "HelloWorldv1.h" +#ifndef _FAST_DDS_GENERATED_HELLOWORLD_HPP_ +#define _FAST_DDS_GENERATED_HELLOWORLD_HPP_ -#if FASTCDR_VERSION_MAJOR > 1 - -#ifndef _FAST_DDS_GENERATED_HELLOWORLD_H_ -#define _FAST_DDS_GENERATED_HELLOWORLD_H_ - -#include -#include #include -#include #include -#include - +#include #include -#include -#include - - #if defined(_WIN32) #if defined(EPROSIMA_USER_DLL_EXPORT) @@ -64,17 +51,6 @@ #define HELLOWORLD_DllAPI #endif // _WIN32 -namespace eprosima { -namespace fastcdr { -class Cdr; -class CdrSizeCalculator; -} // namespace fastcdr -} // namespace eprosima - - - - - /*! * @brief This class represents the structure HelloWorld defined by the user in the IDL file. * @ingroup HelloWorld @@ -86,73 +62,117 @@ class HelloWorld /*! * @brief Default constructor. */ - eProsima_user_DllExport HelloWorld(); + eProsima_user_DllExport HelloWorld() + { + } /*! * @brief Default destructor. */ - eProsima_user_DllExport ~HelloWorld(); + eProsima_user_DllExport ~HelloWorld() + { + } /*! * @brief Copy constructor. * @param x Reference to the object HelloWorld that will be copied. */ eProsima_user_DllExport HelloWorld( - const HelloWorld& x); + const HelloWorld& x) + { + m_index = x.m_index; + + m_message = x.m_message; + + } /*! * @brief Move constructor. * @param x Reference to the object HelloWorld that will be copied. */ eProsima_user_DllExport HelloWorld( - HelloWorld&& x) noexcept; + HelloWorld&& x) noexcept + { + m_index = x.m_index; + m_message = std::move(x.m_message); + } /*! * @brief Copy assignment. * @param x Reference to the object HelloWorld that will be copied. */ eProsima_user_DllExport HelloWorld& operator =( - const HelloWorld& x); + const HelloWorld& x) + { + + m_index = x.m_index; + + m_message = x.m_message; + + return *this; + } /*! * @brief Move assignment. * @param x Reference to the object HelloWorld that will be copied. */ eProsima_user_DllExport HelloWorld& operator =( - HelloWorld&& x) noexcept; + HelloWorld&& x) noexcept + { + + m_index = x.m_index; + m_message = std::move(x.m_message); + return *this; + } /*! * @brief Comparison operator. * @param x HelloWorld object to compare. */ eProsima_user_DllExport bool operator ==( - const HelloWorld& x) const; + const HelloWorld& x) const + { + return (m_index == x.m_index && + m_message == x.m_message); + } /*! * @brief Comparison operator. * @param x HelloWorld object to compare. */ eProsima_user_DllExport bool operator !=( - const HelloWorld& x) const; + const HelloWorld& x) const + { + return !(*this == x); + } /*! * @brief This function sets a value in member index * @param _index New value for member index */ eProsima_user_DllExport void index( - uint32_t _index); + uint32_t _index) + { + m_index = _index; + } /*! * @brief This function returns the value of member index * @return Value of member index */ - eProsima_user_DllExport uint32_t index() const; + eProsima_user_DllExport uint32_t index() const + { + return m_index; + } /*! * @brief This function returns a reference to member index * @return Reference to member index */ - eProsima_user_DllExport uint32_t& index(); + eProsima_user_DllExport uint32_t& index() + { + return m_index; + } /*! @@ -160,26 +180,40 @@ class HelloWorld * @param _message New value to be copied in member message */ eProsima_user_DllExport void message( - const std::string& _message); + const std::string& _message) + { + m_message = _message; + } /*! * @brief This function moves the value in member message * @param _message New value to be moved in member message */ eProsima_user_DllExport void message( - std::string&& _message); + std::string&& _message) + { + m_message = std::move(_message); + } /*! * @brief This function returns a constant reference to member message * @return Constant reference to member message */ - eProsima_user_DllExport const std::string& message() const; + eProsima_user_DllExport const std::string& message() const + { + return m_message; + } /*! * @brief This function returns a reference to member message * @return Reference to member message */ - eProsima_user_DllExport std::string& message(); + eProsima_user_DllExport std::string& message() + { + return m_message; + } + + private: @@ -188,8 +222,6 @@ class HelloWorld }; -#endif // _FAST_DDS_GENERATED_HELLOWORLD_H_ - +#endif // _FAST_DDS_GENERATED_HELLOWORLD_HPP_ -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/ContentFilteredTopicExample/HelloWorldCdrAux.hpp b/examples/cpp/dds/ContentFilteredTopicExample/HelloWorldCdrAux.hpp index 9f346d306be..6feb8a9da15 100644 --- a/examples/cpp/dds/ContentFilteredTopicExample/HelloWorldCdrAux.hpp +++ b/examples/cpp/dds/ContentFilteredTopicExample/HelloWorldCdrAux.hpp @@ -22,7 +22,7 @@ #ifndef _FAST_DDS_GENERATED_HELLOWORLDCDRAUX_HPP_ #define _FAST_DDS_GENERATED_HELLOWORLDCDRAUX_HPP_ -#include "HelloWorld.h" +#include "HelloWorld.hpp" constexpr uint32_t HelloWorld_max_cdr_typesize {268UL}; constexpr uint32_t HelloWorld_max_key_cdr_typesize {0UL}; @@ -34,8 +34,6 @@ namespace fastcdr { class Cdr; class CdrSizeCalculator; - - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const HelloWorld& data); diff --git a/examples/cpp/dds/ContentFilteredTopicExample/HelloWorldCdrAux.ipp b/examples/cpp/dds/ContentFilteredTopicExample/HelloWorldCdrAux.ipp index 42e91f3cc38..97df3fe9d9e 100644 --- a/examples/cpp/dds/ContentFilteredTopicExample/HelloWorldCdrAux.ipp +++ b/examples/cpp/dds/ContentFilteredTopicExample/HelloWorldCdrAux.ipp @@ -34,8 +34,6 @@ using namespace eprosima::fastcdr::exception; namespace eprosima { namespace fastcdr { - - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, diff --git a/examples/cpp/dds/ContentFilteredTopicExample/HelloWorldPubSubTypes.cxx b/examples/cpp/dds/ContentFilteredTopicExample/HelloWorldPubSubTypes.cxx index 85cb477896e..db018e69782 100644 --- a/examples/cpp/dds/ContentFilteredTopicExample/HelloWorldPubSubTypes.cxx +++ b/examples/cpp/dds/ContentFilteredTopicExample/HelloWorldPubSubTypes.cxx @@ -19,18 +19,18 @@ * This file was generated by the tool fastddsgen. */ +#include "HelloWorldPubSubTypes.h" +#include #include -#include "HelloWorldPubSubTypes.h" #include "HelloWorldCdrAux.hpp" +#include "HelloWorldTypeObjectSupport.hpp" using SerializedPayload_t = eprosima::fastrtps::rtps::SerializedPayload_t; using InstanceHandle_t = eprosima::fastrtps::rtps::InstanceHandle_t; using DataRepresentationId_t = eprosima::fastdds::dds::DataRepresentationId_t; - - HelloWorldPubSubType::HelloWorldPubSubType() { setName("HelloWorld"); @@ -219,3 +219,11 @@ bool HelloWorldPubSubType::getKey( return true; } +void HelloWorldPubSubType::register_type_object_representation() const +{ + register_HelloWorld_type_objects(); +} + + +// Include auxiliary functions like for serializing/deserializing. +#include "HelloWorldCdrAux.ipp" diff --git a/examples/cpp/dds/ContentFilteredTopicExample/HelloWorldPubSubTypes.h b/examples/cpp/dds/ContentFilteredTopicExample/HelloWorldPubSubTypes.h index cb61cd6ba23..a9b4ac119e0 100644 --- a/examples/cpp/dds/ContentFilteredTopicExample/HelloWorldPubSubTypes.h +++ b/examples/cpp/dds/ContentFilteredTopicExample/HelloWorldPubSubTypes.h @@ -27,9 +27,9 @@ #include #include #include -#include +#include -#include "HelloWorld.h" +#include "HelloWorld.hpp" #if !defined(GEN_API_VER) || (GEN_API_VER != 2) @@ -38,8 +38,6 @@ #endif // GEN_API_VER - - /*! * @brief This class represents the TopicDataType of the type HelloWorld defined by the user in the IDL file. * @ingroup HelloWorld @@ -90,6 +88,9 @@ class HelloWorldPubSubType : public eprosima::fastdds::dds::TopicDataType eProsima_user_DllExport void deleteData( void* data) override; + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + #ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED eProsima_user_DllExport inline bool is_bounded() const override { diff --git a/examples/cpp/dds/ContentFilteredTopicExample/HelloWorldTypeObject.cxx b/examples/cpp/dds/ContentFilteredTopicExample/HelloWorldTypeObject.cxx deleted file mode 100644 index 69e829c28d7..00000000000 --- a/examples/cpp/dds/ContentFilteredTopicExample/HelloWorldTypeObject.cxx +++ /dev/null @@ -1,263 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file HelloWorldTypeObject.cpp - * This source file contains the definition of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { char dummy; } -#endif - -#include "HelloWorld.h" -#include "HelloWorldTypeObject.h" -#include -#include -#include -#include -#include -#include -#include -#include -#include - -using namespace eprosima::fastrtps::rtps; - -void registerHelloWorldTypes() -{ - static std::once_flag once_flag; - std::call_once(once_flag, []() - { - TypeObjectFactory *factory = TypeObjectFactory::get_instance(); - factory->add_type_object("HelloWorld", GetHelloWorldIdentifier(true), - GetHelloWorldObject(true)); - factory->add_type_object("HelloWorld", GetHelloWorldIdentifier(false), - GetHelloWorldObject(false)); - - }); -} - - - -const TypeIdentifier* GetHelloWorldIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("HelloWorld", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetHelloWorldObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("HelloWorld", complete); -} - -const TypeObject* GetHelloWorldObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("HelloWorld", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteHelloWorldObject(); - } - //else - return GetMinimalHelloWorldObject(); -} - -const TypeObject* GetMinimalHelloWorldObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("HelloWorld", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_index; - mst_index.common().member_id(memberId++); - mst_index.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_index.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_index.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_index.common().member_flags().IS_OPTIONAL(false); - mst_index.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_index.common().member_flags().IS_KEY(false); - mst_index.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_index.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint32_t", false)); - - - MD5 index_hash("index"); - for(int i = 0; i < 4; ++i) - { - mst_index.detail().name_hash()[i] = index_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_index); - - MinimalStructMember mst_message; - mst_message.common().member_id(memberId++); - mst_message.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_message.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_message.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_message.common().member_flags().IS_OPTIONAL(false); - mst_message.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_message.common().member_flags().IS_KEY(false); - mst_message.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_message.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, false)); - - MD5 message_hash("message"); - for(int i = 0; i < 4; ++i) - { - mst_message.detail().name_hash()[i] = message_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_message); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("HelloWorld", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("HelloWorld", false); -} - -const TypeObject* GetCompleteHelloWorldObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("HelloWorld", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_index; - cst_index.common().member_id(memberId++); - cst_index.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_index.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_index.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_index.common().member_flags().IS_OPTIONAL(false); - cst_index.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_index.common().member_flags().IS_KEY(false); - cst_index.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_index.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint32_t", false)); - - - cst_index.detail().name("index"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_index); - - CompleteStructMember cst_message; - cst_message.common().member_id(memberId++); - cst_message.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_message.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_message.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_message.common().member_flags().IS_OPTIONAL(false); - cst_message.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_message.common().member_flags().IS_KEY(false); - cst_message.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_message.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, false)); - - cst_message.detail().name("message"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_message); - - - // Header - type_object->complete().struct_type().header().detail().type_name("HelloWorld"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("HelloWorld", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("HelloWorld", true); -} diff --git a/examples/cpp/dds/ContentFilteredTopicExample/HelloWorldTypeObject.h b/examples/cpp/dds/ContentFilteredTopicExample/HelloWorldTypeObject.h deleted file mode 100644 index 76b2a621eb7..00000000000 --- a/examples/cpp/dds/ContentFilteredTopicExample/HelloWorldTypeObject.h +++ /dev/null @@ -1,65 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file HelloWorldTypeObject.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifndef _FAST_DDS_GENERATED_HELLOWORLD_TYPE_OBJECT_H_ -#define _FAST_DDS_GENERATED_HELLOWORLD_TYPE_OBJECT_H_ - - -#include -#include - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif -#else -#define eProsima_user_DllExport -#endif - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(HelloWorld_SOURCE) -#define HelloWorld_DllAPI __declspec( dllexport ) -#else -#define HelloWorld_DllAPI __declspec( dllimport ) -#endif // HelloWorld_SOURCE -#else -#define HelloWorld_DllAPI -#endif -#else -#define HelloWorld_DllAPI -#endif // _WIN32 - -using namespace eprosima::fastrtps::types; - -eProsima_user_DllExport void registerHelloWorldTypes(); - - - -eProsima_user_DllExport const TypeIdentifier* GetHelloWorldIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetHelloWorldObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalHelloWorldObject(); -eProsima_user_DllExport const TypeObject* GetCompleteHelloWorldObject(); - - -#endif // _FAST_DDS_GENERATED_HELLOWORLD_TYPE_OBJECT_H_ \ No newline at end of file diff --git a/examples/cpp/dds/ContentFilteredTopicExample/HelloWorldTypeObjectSupport.cxx b/examples/cpp/dds/ContentFilteredTopicExample/HelloWorldTypeObjectSupport.cxx new file mode 100644 index 00000000000..bfae95694f4 --- /dev/null +++ b/examples/cpp/dds/ContentFilteredTopicExample/HelloWorldTypeObjectSupport.cxx @@ -0,0 +1,248 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file HelloWorldTypeObjectSupport.cxx + * Source file containing the implementation to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#include "HelloWorldTypeObjectSupport.hpp" + +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include + +#include "HelloWorld.hpp" + + +using namespace eprosima::fastdds::dds::xtypes; + +void register_HelloWorld_type_objects() +{ + static std::once_flag once_flag; + std::call_once(once_flag, []() + { + register_HelloWorld_type_identifier(); + + }); +} + +void register_HelloWorld_type_identifier() +{ + { + StructTypeFlag struct_flags_HelloWorld = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::NOT_APPLIED, + false, false); + ReturnCode_t return_code_HelloWorld; + TypeIdentifierPair type_ids_HelloWorld; + QualifiedTypeName type_name_HelloWorld = "HelloWorld"; + eprosima::fastcdr::optional type_ann_builtin_HelloWorld; + eprosima::fastcdr::optional ann_custom_HelloWorld; + CompleteTypeDetail detail_HelloWorld = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_HelloWorld, ann_custom_HelloWorld, type_name_HelloWorld.to_string()); + CompleteStructHeader header_HelloWorld; + header_HelloWorld = TypeObjectUtils::build_complete_struct_header(TypeIdentifier(), detail_HelloWorld); + CompleteStructMemberSeq member_seq_HelloWorld; + { + return_code_HelloWorld = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_uint32_t", type_ids_HelloWorld); + + if (return_code_HelloWorld != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "index Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_index = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_index; + MemberId member_id_index = 0x00000000; + if (EK_COMPLETE == type_ids_HelloWorld.type_identifier1()._d() || TK_NONE == type_ids_HelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_HelloWorld.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_HelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_HelloWorld.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure index member TypeIdentifier inconsistent."); + return; + } + MemberName name_index = "index"; + eprosima::fastcdr::optional member_ann_builtin_index; + ann_custom_HelloWorld.reset(); + CompleteMemberDetail detail_index = TypeObjectUtils::build_complete_member_detail(name_index, member_ann_builtin_index, ann_custom_HelloWorld); + CompleteStructMember member_index = TypeObjectUtils::build_complete_struct_member(common_index, detail_index); + TypeObjectUtils::add_complete_struct_member(member_seq_HelloWorld, member_index); + } + { + return_code_HelloWorld = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_string_unbounded", type_ids_HelloWorld); + + if (return_code_HelloWorld != eprosima::fastdds::dds::RETCODE_OK) + { + std::string type_id_kind_anonymous_string_unbounded("TI_STRING8_SMALL"); + if (type_id_kind_anonymous_string_unbounded == "TI_STRING8_SMALL") + { + SBound bound = 0; + StringSTypeDefn string_sdefn = TypeObjectUtils::build_string_s_type_defn(bound); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_string_type_identifier(string_sdefn, + "anonymous_string_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else if (type_id_kind_anonymous_string_unbounded == "TI_STRING8_LARGE") + { + LBound bound = 255; + StringLTypeDefn string_ldefn = TypeObjectUtils::build_string_l_type_defn(bound); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_string_type_identifier(string_ldefn, + "anonymous_string_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded: Unknown String kind."); + return; + } + return_code_HelloWorld = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_string_unbounded", type_ids_HelloWorld); + if (return_code_HelloWorld != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded: Given String TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_message = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_message; + MemberId member_id_message = 0x00000001; + if (EK_COMPLETE == type_ids_HelloWorld.type_identifier1()._d() || TK_NONE == type_ids_HelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_message = TypeObjectUtils::build_common_struct_member(member_id_message, member_flags_message, type_ids_HelloWorld.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_HelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_message = TypeObjectUtils::build_common_struct_member(member_id_message, member_flags_message, type_ids_HelloWorld.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure message member TypeIdentifier inconsistent."); + return; + } + MemberName name_message = "message"; + eprosima::fastcdr::optional member_ann_builtin_message; + ann_custom_HelloWorld.reset(); + CompleteMemberDetail detail_message = TypeObjectUtils::build_complete_member_detail(name_message, member_ann_builtin_message, ann_custom_HelloWorld); + CompleteStructMember member_message = TypeObjectUtils::build_complete_struct_member(common_message, detail_message); + TypeObjectUtils::add_complete_struct_member(member_seq_HelloWorld, member_message); + } + CompleteStructType struct_type_HelloWorld = TypeObjectUtils::build_complete_struct_type(struct_flags_HelloWorld, header_HelloWorld, member_seq_HelloWorld); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_struct_type_object(struct_type_HelloWorld, type_name_HelloWorld.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "HelloWorld already registered in TypeObjectRegistry for a different type."); + } + return_code_HelloWorld = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "HelloWorld", type_ids_HelloWorld); + if (return_code_HelloWorld != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "HelloWorld: Given Struct TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } +} + diff --git a/examples/cpp/dds/ContentFilteredTopicExample/HelloWorldTypeObjectSupport.hpp b/examples/cpp/dds/ContentFilteredTopicExample/HelloWorldTypeObjectSupport.hpp new file mode 100644 index 00000000000..8650fc061e0 --- /dev/null +++ b/examples/cpp/dds/ContentFilteredTopicExample/HelloWorldTypeObjectSupport.hpp @@ -0,0 +1,54 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file HelloWorldTypeObjectSupport.hpp + * Header file containing the API required to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#ifndef _FAST_DDS_GENERATED_HELLOWORLD_TYPE_OBJECT_SUPPORT_HPP_ +#define _FAST_DDS_GENERATED_HELLOWORLD_TYPE_OBJECT_SUPPORT_HPP_ + + +#if defined(_WIN32) +#if defined(EPROSIMA_USER_DLL_EXPORT) +#define eProsima_user_DllExport __declspec( dllexport ) +#else +#define eProsima_user_DllExport +#endif // EPROSIMA_USER_DLL_EXPORT +#else +#define eProsima_user_DllExport +#endif // _WIN32 + +/** + * @brief Register every TypeObject representation defined in the IDL file in Fast DDS TypeObjectRegistry. + */ +eProsima_user_DllExport void register_HelloWorld_type_objects(); + +#ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +/** + * @brief Register HelloWorld related TypeIdentifier. + * Fully-descriptive TypeIdentifiers are directly registered. + * Hash TypeIdentifiers require to fill the TypeObject information and hash it, consequently, the TypeObject is + * indirectly registered as well. + */ +void register_HelloWorld_type_identifier(); + + +#endif // DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +#endif // _FAST_DDS_GENERATED_HELLOWORLD_TYPE_OBJECT_SUPPORT_HPP_ diff --git a/examples/cpp/dds/ContentFilteredTopicExample/HelloWorldv1.cxx b/examples/cpp/dds/ContentFilteredTopicExample/HelloWorldv1.cxx deleted file mode 100644 index bb049241e49..00000000000 --- a/examples/cpp/dds/ContentFilteredTopicExample/HelloWorldv1.cxx +++ /dev/null @@ -1,290 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file HelloWorld.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "HelloWorld.h" - -#if FASTCDR_VERSION_MAJOR == 1 - -#include "HelloWorldTypeObject.h" - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - -namespace helper { namespace internal { - -enum class Size { - UInt8, - UInt16, - UInt32, - UInt64, -}; - -constexpr Size get_size(int s) { - return (s <= 8 ) ? Size::UInt8: - (s <= 16) ? Size::UInt16: - (s <= 32) ? Size::UInt32: Size::UInt64; -} - -template -struct FindTypeH; - -template<> -struct FindTypeH { - using type = std::uint8_t; -}; - -template<> -struct FindTypeH { - using type = std::uint16_t; -}; - -template<> -struct FindTypeH { - using type = std::uint32_t; -}; - -template<> -struct FindTypeH { - using type = std::uint64_t; -}; -} - -template -struct FindType { - using type = typename internal::FindTypeH::type; -}; -} - -#define HelloWorld_max_cdr_typesize 268ULL; - - - - -HelloWorld::HelloWorld() -{ - // unsigned long m_index - m_index = 0; - // /type_d() m_message - - - // Just to register all known types - registerHelloWorldTypes(); -} - -HelloWorld::~HelloWorld() -{ -} - -HelloWorld::HelloWorld( - const HelloWorld& x) -{ - m_index = x.m_index; - - - m_message = x.m_message; - -} - -HelloWorld::HelloWorld( - HelloWorld&& x) noexcept -{ - m_index = x.m_index; - - - m_message = std::move(x.m_message); - -} - -HelloWorld& HelloWorld::operator =( - const HelloWorld& x) -{ - m_index = x.m_index; - - - m_message = x.m_message; - - return *this; -} - -HelloWorld& HelloWorld::operator =( - HelloWorld&& x) noexcept -{ - m_index = x.m_index; - - - m_message = std::move(x.m_message); - - return *this; -} - -bool HelloWorld::operator ==( - const HelloWorld& x) const -{ - return (m_index == x.m_index && - m_message == x.m_message); -} - -bool HelloWorld::operator !=( - const HelloWorld& x) const -{ - return !(*this == x); -} - -size_t HelloWorld::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return HelloWorld_max_cdr_typesize; -} - -size_t HelloWorld::getCdrSerializedSize( - const HelloWorld& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + data.message().size() + 1; - - - return current_alignment - initial_alignment; -} - - -void HelloWorld::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_index; - - scdr << m_message.c_str(); - -} - -void HelloWorld::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_index; - - - - dcdr >> m_message; - - -} - - -bool HelloWorld::isKeyDefined() -{ - return false; -} - -void HelloWorld::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void HelloWorld::index( - uint32_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint32_t HelloWorld::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint32_t& HelloWorld::index() -{ - return m_index; -} - - -/*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ -void HelloWorld::message( - const std::string& _message) -{ - m_message = _message; -} - -/*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ -void HelloWorld::message( - std::string&& _message) -{ - m_message = std::move(_message); -} - -/*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ -const std::string& HelloWorld::message() const -{ - return m_message; -} - -/*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ -std::string& HelloWorld::message() -{ - return m_message; -} - - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/ContentFilteredTopicExample/HelloWorldv1.h b/examples/cpp/dds/ContentFilteredTopicExample/HelloWorldv1.h deleted file mode 100644 index 9f6f726e0ab..00000000000 --- a/examples/cpp/dds/ContentFilteredTopicExample/HelloWorldv1.h +++ /dev/null @@ -1,244 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file HelloWorld.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#include - -#if FASTCDR_VERSION_MAJOR == 1 - -#ifndef _FAST_DDS_GENERATED_HELLOWORLD_H_ -#define _FAST_DDS_GENERATED_HELLOWORLD_H_ - - -#include - -#include -#include -#include -#include -#include -#include -#include - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define eProsima_user_DllExport -#endif // _WIN32 - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(HELLOWORLD_SOURCE) -#define HELLOWORLD_DllAPI __declspec( dllexport ) -#else -#define HELLOWORLD_DllAPI __declspec( dllimport ) -#endif // HELLOWORLD_SOURCE -#else -#define HELLOWORLD_DllAPI -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define HELLOWORLD_DllAPI -#endif // _WIN32 - -namespace eprosima { -namespace fastcdr { -class Cdr; -} // namespace fastcdr -} // namespace eprosima - - - - - -/*! - * @brief This class represents the structure HelloWorld defined by the user in the IDL file. - * @ingroup HelloWorld - */ -class HelloWorld -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport HelloWorld(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~HelloWorld(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object HelloWorld that will be copied. - */ - eProsima_user_DllExport HelloWorld( - const HelloWorld& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object HelloWorld that will be copied. - */ - eProsima_user_DllExport HelloWorld( - HelloWorld&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object HelloWorld that will be copied. - */ - eProsima_user_DllExport HelloWorld& operator =( - const HelloWorld& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object HelloWorld that will be copied. - */ - eProsima_user_DllExport HelloWorld& operator =( - HelloWorld&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x HelloWorld object to compare. - */ - eProsima_user_DllExport bool operator ==( - const HelloWorld& x) const; - - /*! - * @brief Comparison operator. - * @param x HelloWorld object to compare. - */ - eProsima_user_DllExport bool operator !=( - const HelloWorld& x) const; - - /*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ - eProsima_user_DllExport void index( - uint32_t _index); - - /*! - * @brief This function returns the value of member index - * @return Value of member index - */ - eProsima_user_DllExport uint32_t index() const; - - /*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ - eProsima_user_DllExport uint32_t& index(); - - - /*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ - eProsima_user_DllExport void message( - const std::string& _message); - - /*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ - eProsima_user_DllExport void message( - std::string&& _message); - - /*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ - eProsima_user_DllExport const std::string& message() const; - - /*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ - eProsima_user_DllExport std::string& message(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const HelloWorld& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - uint32_t m_index; - std::string m_message; - -}; - - -#endif // _FAST_DDS_GENERATED_HELLOWORLD_H_ - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/ContentFilteredTopicExample/MyCustomFilterFactory.hpp b/examples/cpp/dds/ContentFilteredTopicExample/MyCustomFilterFactory.hpp index deb86feca93..606a37d3226 100644 --- a/examples/cpp/dds/ContentFilteredTopicExample/MyCustomFilterFactory.hpp +++ b/examples/cpp/dds/ContentFilteredTopicExample/MyCustomFilterFactory.hpp @@ -22,11 +22,11 @@ class MyCustomFilterFactory : public eprosima::fastdds::dds::IContentFilterFacto * @param filter_parameters Parameters required by the filter * @param filter_instance Instance of the filter to be evaluated * - * @return eprosima::fastrtps::types::ReturnCode_t::RETCODE_BAD_PARAMETER if the requirements for creating the + * @return eprosima::fastdds::dds::RETCODE_BAD_PARAMETER if the requirements for creating the * ContentFilteredTopic using this factory are not met - * eprosima::fastrtps::types::ReturnCode_t::RETCODE_OK if the ContentFilteredTopic is correctly created + * eprosima::fastdds::dds::RETCODE_OK if the ContentFilteredTopic is correctly created */ - eprosima::fastrtps::types::ReturnCode_t create_content_filter( + eprosima::fastdds::dds::ReturnCode_t create_content_filter( const char* filter_class_name, // My custom filter class name is 'MY_CUSTOM_FILTER'. const char* type_name, // This custom filter only supports one type: 'HelloWorld'. const eprosima::fastdds::dds::TopicDataType* /*data_type*/, // Not used in this implementation. @@ -41,7 +41,7 @@ class MyCustomFilterFactory : public eprosima::fastdds::dds::IContentFilterFacto // Check that the two mandatory filter parameters were set. 2 != filter_parameters.length()) { - return ReturnCode_t::RETCODE_BAD_PARAMETER; + return eprosima::fastdds::dds::RETCODE_BAD_PARAMETER; } // If there is an update, delete previous instance. @@ -53,7 +53,7 @@ class MyCustomFilterFactory : public eprosima::fastdds::dds::IContentFilterFacto // Instantiation of the Custom Filter. filter_instance = new MyCustomFilter(std::stoi(filter_parameters[0]), std::stoi(filter_parameters[1])); - return ReturnCode_t::RETCODE_OK; + return eprosima::fastdds::dds::RETCODE_OK; } /** @@ -62,11 +62,11 @@ class MyCustomFilterFactory : public eprosima::fastdds::dds::IContentFilterFacto * @param filter_class_name Custom filter name * @param filter_instance Instance of the filter to be deleted. * After returning, the passed pointer becomes invalid. - * @return eprosima::fastrtps::types::ReturnCode_t::RETCODE_BAD_PARAMETER if the instance was created with another + * @return eprosima::fastdds::dds::RETCODE_BAD_PARAMETER if the instance was created with another * factory - * eprosima::fastrtps::types::ReturnCode_t::RETCODE_OK if correctly deleted + * eprosima::fastdds::dds::RETCODE_OK if correctly deleted */ - eprosima::fastrtps::types::ReturnCode_t delete_content_filter( + eprosima::fastdds::dds::ReturnCode_t delete_content_filter( const char* filter_class_name, eprosima::fastdds::dds::IContentFilter* filter_instance) override { @@ -75,7 +75,7 @@ class MyCustomFilterFactory : public eprosima::fastdds::dds::IContentFilterFacto // Check the filter instance is valid nullptr != filter_instance) { - return ReturnCode_t::RETCODE_BAD_PARAMETER; + return eprosima::fastdds::dds::RETCODE_BAD_PARAMETER; } // Deletion of the Custom Filter. @@ -84,7 +84,7 @@ class MyCustomFilterFactory : public eprosima::fastdds::dds::IContentFilterFacto delete(dynamic_cast(filter_instance)); } - return ReturnCode_t::RETCODE_OK; + return eprosima::fastdds::dds::RETCODE_OK; } }; diff --git a/examples/cpp/dds/CustomListenerExample/CMakeLists.txt b/examples/cpp/dds/CustomListenerExample/CMakeLists.txt index 8a9d42515a1..ef062af7ab7 100644 --- a/examples/cpp/dds/CustomListenerExample/CMakeLists.txt +++ b/examples/cpp/dds/CustomListenerExample/CMakeLists.txt @@ -21,8 +21,8 @@ if(NOT fastcdr_FOUND) find_package(fastcdr 2 REQUIRED) endif() -if(NOT fastrtps_FOUND) - find_package(fastrtps 2.12 REQUIRED) +if(NOT fastdds_FOUND) + find_package(fastdds 3 REQUIRED) endif() # Check C++11 @@ -44,6 +44,6 @@ target_compile_definitions(DDSCustomListenerExample PRIVATE $<$>,$>:__DEBUG> $<$:__INTERNALDEBUG> # Internal debug activated. ) -target_link_libraries(DDSCustomListenerExample fastrtps fastcdr) +target_link_libraries(DDSCustomListenerExample fastdds fastcdr) install(TARGETS DDSCustomListenerExample RUNTIME DESTINATION examples/cpp/dds/CustomListenerExample/${BIN_INSTALL_DIR}) diff --git a/examples/cpp/dds/CustomListenerExample/CustomListenerPublisher.cpp b/examples/cpp/dds/CustomListenerExample/CustomListenerPublisher.cpp index f8414ce90dc..b2fa6762663 100644 --- a/examples/cpp/dds/CustomListenerExample/CustomListenerPublisher.cpp +++ b/examples/cpp/dds/CustomListenerExample/CustomListenerPublisher.cpp @@ -18,15 +18,14 @@ */ #include "CustomListenerPublisher.h" -#include -#include + +#include + #include -#include -#include #include +#include #include - -#include +#include using namespace eprosima::fastdds::dds; diff --git a/examples/cpp/dds/CustomListenerExample/CustomListenerSubscriber.cpp b/examples/cpp/dds/CustomListenerExample/CustomListenerSubscriber.cpp index bd685482f66..b3940eafef0 100644 --- a/examples/cpp/dds/CustomListenerExample/CustomListenerSubscriber.cpp +++ b/examples/cpp/dds/CustomListenerExample/CustomListenerSubscriber.cpp @@ -18,15 +18,14 @@ */ #include "CustomListenerSubscriber.h" -#include -#include + +#include + #include -#include #include -#include #include - -#include +#include +#include using namespace eprosima::fastdds::dds; diff --git a/examples/cpp/dds/CustomListenerExample/CustomListenerSubscriber.h b/examples/cpp/dds/CustomListenerExample/CustomListenerSubscriber.h index 6c3cbf44830..d5a31f44bd8 100644 --- a/examples/cpp/dds/CustomListenerExample/CustomListenerSubscriber.h +++ b/examples/cpp/dds/CustomListenerExample/CustomListenerSubscriber.h @@ -20,13 +20,13 @@ #ifndef CUSTOMLISTENERSUBSCRIBER_H_ #define CUSTOMLISTENERSUBSCRIBER_H_ -#include "TopicPubSubTypes.h" -#include "CustomListeners.h" - +#include #include #include -#include -#include +#include + +#include "CustomListeners.h" +#include "TopicPubSubTypes.h" class CustomListenerSubscriber { diff --git a/examples/cpp/dds/CustomListenerExample/CustomListener_main.cpp b/examples/cpp/dds/CustomListenerExample/CustomListener_main.cpp index c38282a8de4..907a44b5835 100644 --- a/examples/cpp/dds/CustomListenerExample/CustomListener_main.cpp +++ b/examples/cpp/dds/CustomListenerExample/CustomListener_main.cpp @@ -17,15 +17,13 @@ * */ +#include +#include + #include "CustomListenerPublisher.h" #include "CustomListenerSubscriber.h" #include "CustomListeners.h" - -#include - -#include - using eprosima::fastdds::dds::Log; int main( diff --git a/examples/cpp/dds/CustomListenerExample/CustomListeners.cpp b/examples/cpp/dds/CustomListenerExample/CustomListeners.cpp index b18b4dbf3bd..a2cdd135856 100644 --- a/examples/cpp/dds/CustomListenerExample/CustomListeners.cpp +++ b/examples/cpp/dds/CustomListenerExample/CustomListeners.cpp @@ -18,25 +18,21 @@ */ #include "CustomListeners.h" -#include -#include -#include -#include -#include -#include -#include +#include -#include -#include +#include #include +#include #include - -#include +#include +#include +#include +#include +#include using namespace eprosima::fastdds::dds; - void CustomDataWriterListener::on_publication_matched( DataWriter*, const PublicationMatchedStatus& info) @@ -84,7 +80,7 @@ void CustomDataReaderListener::on_data_available( DataReader* reader) { SampleInfo info; - if (reader->take_next_sample(&hello_, &info) == ReturnCode_t::RETCODE_OK) + if (reader->take_next_sample(&hello_, &info) == RETCODE_OK) { if (info.instance_state == ALIVE_INSTANCE_STATE) { @@ -152,7 +148,7 @@ void CustomDomainParticipantListener::on_data_available( DataReader* reader) { SampleInfo info; - if (reader->take_next_sample(&hello_, &info) == ReturnCode_t::RETCODE_OK) + if (reader->take_next_sample(&hello_, &info) == RETCODE_OK) { if (info.instance_state == ALIVE_INSTANCE_STATE) { diff --git a/examples/cpp/dds/CustomListenerExample/CustomListeners.h b/examples/cpp/dds/CustomListenerExample/CustomListeners.h index 701bfdb2079..12ef7c514ff 100644 --- a/examples/cpp/dds/CustomListenerExample/CustomListeners.h +++ b/examples/cpp/dds/CustomListenerExample/CustomListeners.h @@ -20,24 +20,18 @@ #ifndef CUSTOMLISTENERS_H_ #define CUSTOMLISTENERS_H_ -#include "TopicPubSubTypes.h" - -#include -#include -#include +#include #include - +#include +#include #include - +#include +#include #include +#include +#include -#include -#include -#include - -#include -#include - +#include "TopicPubSubTypes.h" class CustomDataWriterListener : public eprosima::fastdds::dds::DataWriterListener { diff --git a/examples/cpp/dds/CustomListenerExample/Topic.cxx b/examples/cpp/dds/CustomListenerExample/Topic.cxx deleted file mode 100644 index ca86d176ba1..00000000000 --- a/examples/cpp/dds/CustomListenerExample/Topic.cxx +++ /dev/null @@ -1,168 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file Topic.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "Topic.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - - - - -Topic::Topic() -{ -} - -Topic::~Topic() -{ -} - -Topic::Topic( - const Topic& x) -{ - m_index = x.m_index; - m_message = x.m_message; -} - -Topic::Topic( - Topic&& x) noexcept -{ - m_index = x.m_index; - m_message = std::move(x.m_message); -} - -Topic& Topic::operator =( - const Topic& x) -{ - - m_index = x.m_index; - m_message = x.m_message; - return *this; -} - -Topic& Topic::operator =( - Topic&& x) noexcept -{ - - m_index = x.m_index; - m_message = std::move(x.m_message); - return *this; -} - -bool Topic::operator ==( - const Topic& x) const -{ - return (m_index == x.m_index && - m_message == x.m_message); -} - -bool Topic::operator !=( - const Topic& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void Topic::index( - uint32_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint32_t Topic::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint32_t& Topic::index() -{ - return m_index; -} - - -/*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ -void Topic::message( - const std::string& _message) -{ - m_message = _message; -} - -/*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ -void Topic::message( - std::string&& _message) -{ - m_message = std::move(_message); -} - -/*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ -const std::string& Topic::message() const -{ - return m_message; -} - -/*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ -std::string& Topic::message() -{ - return m_message; -} - - -// Include auxiliary functions like for serializing/deserializing. -#include "TopicCdrAux.ipp" - -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/LivelinessQoS/Topic.h b/examples/cpp/dds/CustomListenerExample/Topic.hpp similarity index 69% rename from examples/cpp/dds/LivelinessQoS/Topic.h rename to examples/cpp/dds/CustomListenerExample/Topic.hpp index 2596f317a1e..8f86884c2b8 100644 --- a/examples/cpp/dds/LivelinessQoS/Topic.h +++ b/examples/cpp/dds/CustomListenerExample/Topic.hpp @@ -13,32 +13,19 @@ // limitations under the License. /*! - * @file Topic.h + * @file Topic.hpp * This header file contains the declaration of the described types in the IDL file. * * This file was generated by the tool fastddsgen. */ -#include -#include "Topicv1.h" +#ifndef _FAST_DDS_GENERATED_TOPIC_HPP_ +#define _FAST_DDS_GENERATED_TOPIC_HPP_ -#if FASTCDR_VERSION_MAJOR > 1 - -#ifndef _FAST_DDS_GENERATED_TOPIC_H_ -#define _FAST_DDS_GENERATED_TOPIC_H_ - -#include -#include #include -#include #include -#include - +#include #include -#include -#include - - #if defined(_WIN32) #if defined(EPROSIMA_USER_DLL_EXPORT) @@ -64,17 +51,6 @@ #define TOPIC_DllAPI #endif // _WIN32 -namespace eprosima { -namespace fastcdr { -class Cdr; -class CdrSizeCalculator; -} // namespace fastcdr -} // namespace eprosima - - - - - /*! * @brief This class represents the structure Topic defined by the user in the IDL file. * @ingroup Topic @@ -86,73 +62,117 @@ class Topic /*! * @brief Default constructor. */ - eProsima_user_DllExport Topic(); + eProsima_user_DllExport Topic() + { + } /*! * @brief Default destructor. */ - eProsima_user_DllExport ~Topic(); + eProsima_user_DllExport ~Topic() + { + } /*! * @brief Copy constructor. * @param x Reference to the object Topic that will be copied. */ eProsima_user_DllExport Topic( - const Topic& x); + const Topic& x) + { + m_index = x.m_index; + + m_message = x.m_message; + + } /*! * @brief Move constructor. * @param x Reference to the object Topic that will be copied. */ eProsima_user_DllExport Topic( - Topic&& x) noexcept; + Topic&& x) noexcept + { + m_index = x.m_index; + m_message = std::move(x.m_message); + } /*! * @brief Copy assignment. * @param x Reference to the object Topic that will be copied. */ eProsima_user_DllExport Topic& operator =( - const Topic& x); + const Topic& x) + { + + m_index = x.m_index; + + m_message = x.m_message; + + return *this; + } /*! * @brief Move assignment. * @param x Reference to the object Topic that will be copied. */ eProsima_user_DllExport Topic& operator =( - Topic&& x) noexcept; + Topic&& x) noexcept + { + + m_index = x.m_index; + m_message = std::move(x.m_message); + return *this; + } /*! * @brief Comparison operator. * @param x Topic object to compare. */ eProsima_user_DllExport bool operator ==( - const Topic& x) const; + const Topic& x) const + { + return (m_index == x.m_index && + m_message == x.m_message); + } /*! * @brief Comparison operator. * @param x Topic object to compare. */ eProsima_user_DllExport bool operator !=( - const Topic& x) const; + const Topic& x) const + { + return !(*this == x); + } /*! * @brief This function sets a value in member index * @param _index New value for member index */ eProsima_user_DllExport void index( - uint32_t _index); + uint32_t _index) + { + m_index = _index; + } /*! * @brief This function returns the value of member index * @return Value of member index */ - eProsima_user_DllExport uint32_t index() const; + eProsima_user_DllExport uint32_t index() const + { + return m_index; + } /*! * @brief This function returns a reference to member index * @return Reference to member index */ - eProsima_user_DllExport uint32_t& index(); + eProsima_user_DllExport uint32_t& index() + { + return m_index; + } /*! @@ -160,26 +180,40 @@ class Topic * @param _message New value to be copied in member message */ eProsima_user_DllExport void message( - const std::string& _message); + const std::string& _message) + { + m_message = _message; + } /*! * @brief This function moves the value in member message * @param _message New value to be moved in member message */ eProsima_user_DllExport void message( - std::string&& _message); + std::string&& _message) + { + m_message = std::move(_message); + } /*! * @brief This function returns a constant reference to member message * @return Constant reference to member message */ - eProsima_user_DllExport const std::string& message() const; + eProsima_user_DllExport const std::string& message() const + { + return m_message; + } /*! * @brief This function returns a reference to member message * @return Reference to member message */ - eProsima_user_DllExport std::string& message(); + eProsima_user_DllExport std::string& message() + { + return m_message; + } + + private: @@ -188,8 +222,6 @@ class Topic }; -#endif // _FAST_DDS_GENERATED_TOPIC_H_ - +#endif // _FAST_DDS_GENERATED_TOPIC_HPP_ -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/CustomListenerExample/TopicCdrAux.hpp b/examples/cpp/dds/CustomListenerExample/TopicCdrAux.hpp index 619cdbbb7b8..7b60c44c7b4 100644 --- a/examples/cpp/dds/CustomListenerExample/TopicCdrAux.hpp +++ b/examples/cpp/dds/CustomListenerExample/TopicCdrAux.hpp @@ -22,7 +22,7 @@ #ifndef _FAST_DDS_GENERATED_TOPICCDRAUX_HPP_ #define _FAST_DDS_GENERATED_TOPICCDRAUX_HPP_ -#include "Topic.h" +#include "Topic.hpp" constexpr uint32_t Topic_max_cdr_typesize {268UL}; constexpr uint32_t Topic_max_key_cdr_typesize {0UL}; @@ -34,8 +34,6 @@ namespace fastcdr { class Cdr; class CdrSizeCalculator; - - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const Topic& data); diff --git a/examples/cpp/dds/CustomListenerExample/TopicCdrAux.ipp b/examples/cpp/dds/CustomListenerExample/TopicCdrAux.ipp index ac5a8c39ef9..37570c8a6b2 100644 --- a/examples/cpp/dds/CustomListenerExample/TopicCdrAux.ipp +++ b/examples/cpp/dds/CustomListenerExample/TopicCdrAux.ipp @@ -34,8 +34,6 @@ using namespace eprosima::fastcdr::exception; namespace eprosima { namespace fastcdr { - - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, diff --git a/examples/cpp/dds/CustomListenerExample/TopicPubSubTypes.cxx b/examples/cpp/dds/CustomListenerExample/TopicPubSubTypes.cxx index ce688064a0e..8d6d0b195c9 100644 --- a/examples/cpp/dds/CustomListenerExample/TopicPubSubTypes.cxx +++ b/examples/cpp/dds/CustomListenerExample/TopicPubSubTypes.cxx @@ -19,18 +19,18 @@ * This file was generated by the tool fastddsgen. */ +#include "TopicPubSubTypes.h" +#include #include -#include "TopicPubSubTypes.h" #include "TopicCdrAux.hpp" +#include "TopicTypeObjectSupport.hpp" using SerializedPayload_t = eprosima::fastrtps::rtps::SerializedPayload_t; using InstanceHandle_t = eprosima::fastrtps::rtps::InstanceHandle_t; using DataRepresentationId_t = eprosima::fastdds::dds::DataRepresentationId_t; - - TopicPubSubType::TopicPubSubType() { setName("Topic"); @@ -219,3 +219,11 @@ bool TopicPubSubType::getKey( return true; } +void TopicPubSubType::register_type_object_representation() const +{ + register_Topic_type_objects(); +} + + +// Include auxiliary functions like for serializing/deserializing. +#include "TopicCdrAux.ipp" diff --git a/examples/cpp/dds/CustomListenerExample/TopicPubSubTypes.h b/examples/cpp/dds/CustomListenerExample/TopicPubSubTypes.h index b9100bacbe9..0b37b3746f3 100644 --- a/examples/cpp/dds/CustomListenerExample/TopicPubSubTypes.h +++ b/examples/cpp/dds/CustomListenerExample/TopicPubSubTypes.h @@ -27,9 +27,9 @@ #include #include #include -#include +#include -#include "Topic.h" +#include "Topic.hpp" #if !defined(GEN_API_VER) || (GEN_API_VER != 2) @@ -38,8 +38,6 @@ #endif // GEN_API_VER - - /*! * @brief This class represents the TopicDataType of the type Topic defined by the user in the IDL file. * @ingroup Topic @@ -90,6 +88,9 @@ class TopicPubSubType : public eprosima::fastdds::dds::TopicDataType eProsima_user_DllExport void deleteData( void* data) override; + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + #ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED eProsima_user_DllExport inline bool is_bounded() const override { diff --git a/examples/cpp/dds/CustomListenerExample/TopicTypeObjectSupport.cxx b/examples/cpp/dds/CustomListenerExample/TopicTypeObjectSupport.cxx new file mode 100644 index 00000000000..067fd08a822 --- /dev/null +++ b/examples/cpp/dds/CustomListenerExample/TopicTypeObjectSupport.cxx @@ -0,0 +1,248 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file TopicTypeObjectSupport.cxx + * Source file containing the implementation to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#include "TopicTypeObjectSupport.hpp" + +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include + +#include "Topic.hpp" + + +using namespace eprosima::fastdds::dds::xtypes; + +void register_Topic_type_objects() +{ + static std::once_flag once_flag; + std::call_once(once_flag, []() + { + register_Topic_type_identifier(); + + }); +} + +void register_Topic_type_identifier() +{ + { + StructTypeFlag struct_flags_Topic = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::NOT_APPLIED, + false, false); + ReturnCode_t return_code_Topic; + TypeIdentifierPair type_ids_Topic; + QualifiedTypeName type_name_Topic = "Topic"; + eprosima::fastcdr::optional type_ann_builtin_Topic; + eprosima::fastcdr::optional ann_custom_Topic; + CompleteTypeDetail detail_Topic = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_Topic, ann_custom_Topic, type_name_Topic.to_string()); + CompleteStructHeader header_Topic; + header_Topic = TypeObjectUtils::build_complete_struct_header(TypeIdentifier(), detail_Topic); + CompleteStructMemberSeq member_seq_Topic; + { + return_code_Topic = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_uint32_t", type_ids_Topic); + + if (return_code_Topic != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "index Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_index = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_index; + MemberId member_id_index = 0x00000000; + if (EK_COMPLETE == type_ids_Topic.type_identifier1()._d() || TK_NONE == type_ids_Topic.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_Topic.type_identifier1()._d() && + EK_COMPLETE == type_ids_Topic.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_Topic.type_identifier1()._d() && + EK_COMPLETE == type_ids_Topic.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_Topic.type_identifier1()._d() && + EK_COMPLETE == type_ids_Topic.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_Topic.type_identifier1()._d() && + EK_COMPLETE == type_ids_Topic.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_Topic.type_identifier1()._d() && + (EK_COMPLETE == type_ids_Topic.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_Topic.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_Topic.type_identifier1()._d() && + (EK_COMPLETE == type_ids_Topic.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_Topic.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_Topic.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_Topic.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_Topic.type_identifier2()._d() && + EK_COMPLETE == type_ids_Topic.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_Topic.type_identifier2()._d() && + EK_COMPLETE == type_ids_Topic.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_Topic.type_identifier2()._d() && + EK_COMPLETE == type_ids_Topic.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_Topic.type_identifier2()._d() && + EK_COMPLETE == type_ids_Topic.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_Topic.type_identifier2()._d() && + (EK_COMPLETE == type_ids_Topic.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_Topic.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_Topic.type_identifier2()._d() && + (EK_COMPLETE == type_ids_Topic.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_Topic.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_Topic.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure index member TypeIdentifier inconsistent."); + return; + } + MemberName name_index = "index"; + eprosima::fastcdr::optional member_ann_builtin_index; + ann_custom_Topic.reset(); + CompleteMemberDetail detail_index = TypeObjectUtils::build_complete_member_detail(name_index, member_ann_builtin_index, ann_custom_Topic); + CompleteStructMember member_index = TypeObjectUtils::build_complete_struct_member(common_index, detail_index); + TypeObjectUtils::add_complete_struct_member(member_seq_Topic, member_index); + } + { + return_code_Topic = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_string_unbounded", type_ids_Topic); + + if (return_code_Topic != eprosima::fastdds::dds::RETCODE_OK) + { + std::string type_id_kind_anonymous_string_unbounded("TI_STRING8_SMALL"); + if (type_id_kind_anonymous_string_unbounded == "TI_STRING8_SMALL") + { + SBound bound = 0; + StringSTypeDefn string_sdefn = TypeObjectUtils::build_string_s_type_defn(bound); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_string_type_identifier(string_sdefn, + "anonymous_string_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else if (type_id_kind_anonymous_string_unbounded == "TI_STRING8_LARGE") + { + LBound bound = 255; + StringLTypeDefn string_ldefn = TypeObjectUtils::build_string_l_type_defn(bound); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_string_type_identifier(string_ldefn, + "anonymous_string_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded: Unknown String kind."); + return; + } + return_code_Topic = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_string_unbounded", type_ids_Topic); + if (return_code_Topic != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded: Given String TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_message = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_message; + MemberId member_id_message = 0x00000001; + if (EK_COMPLETE == type_ids_Topic.type_identifier1()._d() || TK_NONE == type_ids_Topic.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_Topic.type_identifier1()._d() && + EK_COMPLETE == type_ids_Topic.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_Topic.type_identifier1()._d() && + EK_COMPLETE == type_ids_Topic.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_Topic.type_identifier1()._d() && + EK_COMPLETE == type_ids_Topic.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_Topic.type_identifier1()._d() && + EK_COMPLETE == type_ids_Topic.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_Topic.type_identifier1()._d() && + (EK_COMPLETE == type_ids_Topic.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_Topic.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_Topic.type_identifier1()._d() && + (EK_COMPLETE == type_ids_Topic.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_Topic.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_message = TypeObjectUtils::build_common_struct_member(member_id_message, member_flags_message, type_ids_Topic.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_Topic.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_Topic.type_identifier2()._d() && + EK_COMPLETE == type_ids_Topic.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_Topic.type_identifier2()._d() && + EK_COMPLETE == type_ids_Topic.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_Topic.type_identifier2()._d() && + EK_COMPLETE == type_ids_Topic.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_Topic.type_identifier2()._d() && + EK_COMPLETE == type_ids_Topic.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_Topic.type_identifier2()._d() && + (EK_COMPLETE == type_ids_Topic.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_Topic.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_Topic.type_identifier2()._d() && + (EK_COMPLETE == type_ids_Topic.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_Topic.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_message = TypeObjectUtils::build_common_struct_member(member_id_message, member_flags_message, type_ids_Topic.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure message member TypeIdentifier inconsistent."); + return; + } + MemberName name_message = "message"; + eprosima::fastcdr::optional member_ann_builtin_message; + ann_custom_Topic.reset(); + CompleteMemberDetail detail_message = TypeObjectUtils::build_complete_member_detail(name_message, member_ann_builtin_message, ann_custom_Topic); + CompleteStructMember member_message = TypeObjectUtils::build_complete_struct_member(common_message, detail_message); + TypeObjectUtils::add_complete_struct_member(member_seq_Topic, member_message); + } + CompleteStructType struct_type_Topic = TypeObjectUtils::build_complete_struct_type(struct_flags_Topic, header_Topic, member_seq_Topic); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_struct_type_object(struct_type_Topic, type_name_Topic.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Topic already registered in TypeObjectRegistry for a different type."); + } + return_code_Topic = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "Topic", type_ids_Topic); + if (return_code_Topic != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Topic: Given Struct TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } +} + diff --git a/examples/cpp/dds/CustomListenerExample/TopicTypeObjectSupport.hpp b/examples/cpp/dds/CustomListenerExample/TopicTypeObjectSupport.hpp new file mode 100644 index 00000000000..f0576f9b948 --- /dev/null +++ b/examples/cpp/dds/CustomListenerExample/TopicTypeObjectSupport.hpp @@ -0,0 +1,54 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file TopicTypeObjectSupport.hpp + * Header file containing the API required to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#ifndef _FAST_DDS_GENERATED_TOPIC_TYPE_OBJECT_SUPPORT_HPP_ +#define _FAST_DDS_GENERATED_TOPIC_TYPE_OBJECT_SUPPORT_HPP_ + + +#if defined(_WIN32) +#if defined(EPROSIMA_USER_DLL_EXPORT) +#define eProsima_user_DllExport __declspec( dllexport ) +#else +#define eProsima_user_DllExport +#endif // EPROSIMA_USER_DLL_EXPORT +#else +#define eProsima_user_DllExport +#endif // _WIN32 + +/** + * @brief Register every TypeObject representation defined in the IDL file in Fast DDS TypeObjectRegistry. + */ +eProsima_user_DllExport void register_Topic_type_objects(); + +#ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +/** + * @brief Register Topic related TypeIdentifier. + * Fully-descriptive TypeIdentifiers are directly registered. + * Hash TypeIdentifiers require to fill the TypeObject information and hash it, consequently, the TypeObject is + * indirectly registered as well. + */ +void register_Topic_type_identifier(); + + +#endif // DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +#endif // _FAST_DDS_GENERATED_TOPIC_TYPE_OBJECT_SUPPORT_HPP_ diff --git a/examples/cpp/dds/CustomListenerExample/Topicv1.cxx b/examples/cpp/dds/CustomListenerExample/Topicv1.cxx deleted file mode 100644 index a3e85584242..00000000000 --- a/examples/cpp/dds/CustomListenerExample/Topicv1.cxx +++ /dev/null @@ -1,286 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file Topic.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "Topic.h" - -#if FASTCDR_VERSION_MAJOR == 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - -namespace helper { namespace internal { - -enum class Size { - UInt8, - UInt16, - UInt32, - UInt64, -}; - -constexpr Size get_size(int s) { - return (s <= 8 ) ? Size::UInt8: - (s <= 16) ? Size::UInt16: - (s <= 32) ? Size::UInt32: Size::UInt64; -} - -template -struct FindTypeH; - -template<> -struct FindTypeH { - using type = std::uint8_t; -}; - -template<> -struct FindTypeH { - using type = std::uint16_t; -}; - -template<> -struct FindTypeH { - using type = std::uint32_t; -}; - -template<> -struct FindTypeH { - using type = std::uint64_t; -}; -} - -template -struct FindType { - using type = typename internal::FindTypeH::type; -}; -} - -#define Topic_max_cdr_typesize 268ULL; - - - - -Topic::Topic() -{ - // unsigned long m_index - m_index = 0; - // /type_d() m_message - - -} - -Topic::~Topic() -{ -} - -Topic::Topic( - const Topic& x) -{ - m_index = x.m_index; - - - m_message = x.m_message; - -} - -Topic::Topic( - Topic&& x) noexcept -{ - m_index = x.m_index; - - - m_message = std::move(x.m_message); - -} - -Topic& Topic::operator =( - const Topic& x) -{ - m_index = x.m_index; - - - m_message = x.m_message; - - return *this; -} - -Topic& Topic::operator =( - Topic&& x) noexcept -{ - m_index = x.m_index; - - - m_message = std::move(x.m_message); - - return *this; -} - -bool Topic::operator ==( - const Topic& x) const -{ - return (m_index == x.m_index && - m_message == x.m_message); -} - -bool Topic::operator !=( - const Topic& x) const -{ - return !(*this == x); -} - -size_t Topic::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return Topic_max_cdr_typesize; -} - -size_t Topic::getCdrSerializedSize( - const Topic& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + data.message().size() + 1; - - - return current_alignment - initial_alignment; -} - - -void Topic::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_index; - - scdr << m_message.c_str(); - -} - -void Topic::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_index; - - - - dcdr >> m_message; - - -} - - -bool Topic::isKeyDefined() -{ - return false; -} - -void Topic::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void Topic::index( - uint32_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint32_t Topic::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint32_t& Topic::index() -{ - return m_index; -} - - -/*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ -void Topic::message( - const std::string& _message) -{ - m_message = _message; -} - -/*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ -void Topic::message( - std::string&& _message) -{ - m_message = std::move(_message); -} - -/*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ -const std::string& Topic::message() const -{ - return m_message; -} - -/*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ -std::string& Topic::message() -{ - return m_message; -} - - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/CustomListenerExample/Topicv1.h b/examples/cpp/dds/CustomListenerExample/Topicv1.h deleted file mode 100644 index e06f22b7e2b..00000000000 --- a/examples/cpp/dds/CustomListenerExample/Topicv1.h +++ /dev/null @@ -1,244 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file Topic.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#include - -#if FASTCDR_VERSION_MAJOR == 1 - -#ifndef _FAST_DDS_GENERATED_TOPIC_H_ -#define _FAST_DDS_GENERATED_TOPIC_H_ - - -#include - -#include -#include -#include -#include -#include -#include -#include - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define eProsima_user_DllExport -#endif // _WIN32 - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(TOPIC_SOURCE) -#define TOPIC_DllAPI __declspec( dllexport ) -#else -#define TOPIC_DllAPI __declspec( dllimport ) -#endif // TOPIC_SOURCE -#else -#define TOPIC_DllAPI -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define TOPIC_DllAPI -#endif // _WIN32 - -namespace eprosima { -namespace fastcdr { -class Cdr; -} // namespace fastcdr -} // namespace eprosima - - - - - -/*! - * @brief This class represents the structure Topic defined by the user in the IDL file. - * @ingroup Topic - */ -class Topic -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport Topic(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~Topic(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object Topic that will be copied. - */ - eProsima_user_DllExport Topic( - const Topic& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object Topic that will be copied. - */ - eProsima_user_DllExport Topic( - Topic&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object Topic that will be copied. - */ - eProsima_user_DllExport Topic& operator =( - const Topic& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object Topic that will be copied. - */ - eProsima_user_DllExport Topic& operator =( - Topic&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x Topic object to compare. - */ - eProsima_user_DllExport bool operator ==( - const Topic& x) const; - - /*! - * @brief Comparison operator. - * @param x Topic object to compare. - */ - eProsima_user_DllExport bool operator !=( - const Topic& x) const; - - /*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ - eProsima_user_DllExport void index( - uint32_t _index); - - /*! - * @brief This function returns the value of member index - * @return Value of member index - */ - eProsima_user_DllExport uint32_t index() const; - - /*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ - eProsima_user_DllExport uint32_t& index(); - - - /*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ - eProsima_user_DllExport void message( - const std::string& _message); - - /*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ - eProsima_user_DllExport void message( - std::string&& _message); - - /*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ - eProsima_user_DllExport const std::string& message() const; - - /*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ - eProsima_user_DllExport std::string& message(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const Topic& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - uint32_t m_index; - std::string m_message; - -}; - - -#endif // _FAST_DDS_GENERATED_TOPIC_H_ - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/CustomPayloadPoolExample/CMakeLists.txt b/examples/cpp/dds/CustomPayloadPoolExample/CMakeLists.txt index 1b61ca13b7e..adecbdaeb26 100644 --- a/examples/cpp/dds/CustomPayloadPoolExample/CMakeLists.txt +++ b/examples/cpp/dds/CustomPayloadPoolExample/CMakeLists.txt @@ -21,8 +21,8 @@ if(NOT fastcdr_FOUND) find_package(fastcdr 2 REQUIRED) endif() -if(NOT fastrtps_FOUND) - find_package(fastrtps 2.12 REQUIRED) +if(NOT fastdds_FOUND) + find_package(fastdds 3 REQUIRED) endif() #Check C++11 @@ -43,6 +43,6 @@ target_compile_definitions(CustomPayloadPoolExample PRIVATE $<$>,$>:__DEBUG> $<$:__INTERNALDEBUG> # Internal debug activated. ) -target_link_libraries(CustomPayloadPoolExample fastrtps fastcdr fastdds::optionparser) +target_link_libraries(CustomPayloadPoolExample fastdds fastcdr fastdds::optionparser) install(TARGETS CustomPayloadPoolExample RUNTIME DESTINATION examples/cpp/dds/CustomPayloadPoolExample/${BIN_INSTALL_DIR}) diff --git a/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolData.cxx b/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolData.cxx deleted file mode 100644 index 7f304177d38..00000000000 --- a/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolData.cxx +++ /dev/null @@ -1,168 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file CustomPayloadPoolData.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "CustomPayloadPoolData.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - - - - -CustomPayloadPoolData::CustomPayloadPoolData() -{ -} - -CustomPayloadPoolData::~CustomPayloadPoolData() -{ -} - -CustomPayloadPoolData::CustomPayloadPoolData( - const CustomPayloadPoolData& x) -{ - m_index = x.m_index; - m_message = x.m_message; -} - -CustomPayloadPoolData::CustomPayloadPoolData( - CustomPayloadPoolData&& x) noexcept -{ - m_index = x.m_index; - m_message = std::move(x.m_message); -} - -CustomPayloadPoolData& CustomPayloadPoolData::operator =( - const CustomPayloadPoolData& x) -{ - - m_index = x.m_index; - m_message = x.m_message; - return *this; -} - -CustomPayloadPoolData& CustomPayloadPoolData::operator =( - CustomPayloadPoolData&& x) noexcept -{ - - m_index = x.m_index; - m_message = std::move(x.m_message); - return *this; -} - -bool CustomPayloadPoolData::operator ==( - const CustomPayloadPoolData& x) const -{ - return (m_index == x.m_index && - m_message == x.m_message); -} - -bool CustomPayloadPoolData::operator !=( - const CustomPayloadPoolData& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void CustomPayloadPoolData::index( - uint32_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint32_t CustomPayloadPoolData::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint32_t& CustomPayloadPoolData::index() -{ - return m_index; -} - - -/*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ -void CustomPayloadPoolData::message( - const std::string& _message) -{ - m_message = _message; -} - -/*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ -void CustomPayloadPoolData::message( - std::string&& _message) -{ - m_message = std::move(_message); -} - -/*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ -const std::string& CustomPayloadPoolData::message() const -{ - return m_message; -} - -/*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ -std::string& CustomPayloadPoolData::message() -{ - return m_message; -} - - -// Include auxiliary functions like for serializing/deserializing. -#include "CustomPayloadPoolDataCdrAux.ipp" - -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolData.h b/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolData.hpp similarity index 69% rename from examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolData.h rename to examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolData.hpp index 46b1c16c138..19136a331f9 100644 --- a/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolData.h +++ b/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolData.hpp @@ -13,32 +13,19 @@ // limitations under the License. /*! - * @file CustomPayloadPoolData.h + * @file CustomPayloadPoolData.hpp * This header file contains the declaration of the described types in the IDL file. * * This file was generated by the tool fastddsgen. */ -#include -#include "CustomPayloadPoolDatav1.h" +#ifndef _FAST_DDS_GENERATED_CUSTOMPAYLOADPOOLDATA_HPP_ +#define _FAST_DDS_GENERATED_CUSTOMPAYLOADPOOLDATA_HPP_ -#if FASTCDR_VERSION_MAJOR > 1 - -#ifndef _FAST_DDS_GENERATED_CUSTOMPAYLOADPOOLDATA_H_ -#define _FAST_DDS_GENERATED_CUSTOMPAYLOADPOOLDATA_H_ - -#include -#include #include -#include #include -#include - +#include #include -#include -#include - - #if defined(_WIN32) #if defined(EPROSIMA_USER_DLL_EXPORT) @@ -64,17 +51,6 @@ #define CUSTOMPAYLOADPOOLDATA_DllAPI #endif // _WIN32 -namespace eprosima { -namespace fastcdr { -class Cdr; -class CdrSizeCalculator; -} // namespace fastcdr -} // namespace eprosima - - - - - /*! * @brief This class represents the structure CustomPayloadPoolData defined by the user in the IDL file. * @ingroup CustomPayloadPoolData @@ -86,73 +62,117 @@ class CustomPayloadPoolData /*! * @brief Default constructor. */ - eProsima_user_DllExport CustomPayloadPoolData(); + eProsima_user_DllExport CustomPayloadPoolData() + { + } /*! * @brief Default destructor. */ - eProsima_user_DllExport ~CustomPayloadPoolData(); + eProsima_user_DllExport ~CustomPayloadPoolData() + { + } /*! * @brief Copy constructor. * @param x Reference to the object CustomPayloadPoolData that will be copied. */ eProsima_user_DllExport CustomPayloadPoolData( - const CustomPayloadPoolData& x); + const CustomPayloadPoolData& x) + { + m_index = x.m_index; + + m_message = x.m_message; + + } /*! * @brief Move constructor. * @param x Reference to the object CustomPayloadPoolData that will be copied. */ eProsima_user_DllExport CustomPayloadPoolData( - CustomPayloadPoolData&& x) noexcept; + CustomPayloadPoolData&& x) noexcept + { + m_index = x.m_index; + m_message = std::move(x.m_message); + } /*! * @brief Copy assignment. * @param x Reference to the object CustomPayloadPoolData that will be copied. */ eProsima_user_DllExport CustomPayloadPoolData& operator =( - const CustomPayloadPoolData& x); + const CustomPayloadPoolData& x) + { + + m_index = x.m_index; + + m_message = x.m_message; + + return *this; + } /*! * @brief Move assignment. * @param x Reference to the object CustomPayloadPoolData that will be copied. */ eProsima_user_DllExport CustomPayloadPoolData& operator =( - CustomPayloadPoolData&& x) noexcept; + CustomPayloadPoolData&& x) noexcept + { + + m_index = x.m_index; + m_message = std::move(x.m_message); + return *this; + } /*! * @brief Comparison operator. * @param x CustomPayloadPoolData object to compare. */ eProsima_user_DllExport bool operator ==( - const CustomPayloadPoolData& x) const; + const CustomPayloadPoolData& x) const + { + return (m_index == x.m_index && + m_message == x.m_message); + } /*! * @brief Comparison operator. * @param x CustomPayloadPoolData object to compare. */ eProsima_user_DllExport bool operator !=( - const CustomPayloadPoolData& x) const; + const CustomPayloadPoolData& x) const + { + return !(*this == x); + } /*! * @brief This function sets a value in member index * @param _index New value for member index */ eProsima_user_DllExport void index( - uint32_t _index); + uint32_t _index) + { + m_index = _index; + } /*! * @brief This function returns the value of member index * @return Value of member index */ - eProsima_user_DllExport uint32_t index() const; + eProsima_user_DllExport uint32_t index() const + { + return m_index; + } /*! * @brief This function returns a reference to member index * @return Reference to member index */ - eProsima_user_DllExport uint32_t& index(); + eProsima_user_DllExport uint32_t& index() + { + return m_index; + } /*! @@ -160,26 +180,40 @@ class CustomPayloadPoolData * @param _message New value to be copied in member message */ eProsima_user_DllExport void message( - const std::string& _message); + const std::string& _message) + { + m_message = _message; + } /*! * @brief This function moves the value in member message * @param _message New value to be moved in member message */ eProsima_user_DllExport void message( - std::string&& _message); + std::string&& _message) + { + m_message = std::move(_message); + } /*! * @brief This function returns a constant reference to member message * @return Constant reference to member message */ - eProsima_user_DllExport const std::string& message() const; + eProsima_user_DllExport const std::string& message() const + { + return m_message; + } /*! * @brief This function returns a reference to member message * @return Reference to member message */ - eProsima_user_DllExport std::string& message(); + eProsima_user_DllExport std::string& message() + { + return m_message; + } + + private: @@ -188,8 +222,6 @@ class CustomPayloadPoolData }; -#endif // _FAST_DDS_GENERATED_CUSTOMPAYLOADPOOLDATA_H_ - +#endif // _FAST_DDS_GENERATED_CUSTOMPAYLOADPOOLDATA_HPP_ -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolDataCdrAux.hpp b/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolDataCdrAux.hpp index 3d50c83da22..926bf7ea3d7 100644 --- a/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolDataCdrAux.hpp +++ b/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolDataCdrAux.hpp @@ -22,7 +22,7 @@ #ifndef _FAST_DDS_GENERATED_CUSTOMPAYLOADPOOLDATACDRAUX_HPP_ #define _FAST_DDS_GENERATED_CUSTOMPAYLOADPOOLDATACDRAUX_HPP_ -#include "CustomPayloadPoolData.h" +#include "CustomPayloadPoolData.hpp" constexpr uint32_t CustomPayloadPoolData_max_cdr_typesize {268UL}; constexpr uint32_t CustomPayloadPoolData_max_key_cdr_typesize {0UL}; @@ -34,8 +34,6 @@ namespace fastcdr { class Cdr; class CdrSizeCalculator; - - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const CustomPayloadPoolData& data); diff --git a/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolDataCdrAux.ipp b/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolDataCdrAux.ipp index 0fb2b162fb2..89f2aaad27d 100644 --- a/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolDataCdrAux.ipp +++ b/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolDataCdrAux.ipp @@ -34,8 +34,6 @@ using namespace eprosima::fastcdr::exception; namespace eprosima { namespace fastcdr { - - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, diff --git a/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolDataPubSubTypes.cxx b/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolDataPubSubTypes.cxx index ffd0e7faa97..3133c1d0b6c 100644 --- a/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolDataPubSubTypes.cxx +++ b/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolDataPubSubTypes.cxx @@ -19,18 +19,18 @@ * This file was generated by the tool fastddsgen. */ +#include "CustomPayloadPoolDataPubSubTypes.h" +#include #include -#include "CustomPayloadPoolDataPubSubTypes.h" #include "CustomPayloadPoolDataCdrAux.hpp" +#include "CustomPayloadPoolDataTypeObjectSupport.hpp" using SerializedPayload_t = eprosima::fastrtps::rtps::SerializedPayload_t; using InstanceHandle_t = eprosima::fastrtps::rtps::InstanceHandle_t; using DataRepresentationId_t = eprosima::fastdds::dds::DataRepresentationId_t; - - CustomPayloadPoolDataPubSubType::CustomPayloadPoolDataPubSubType() { setName("CustomPayloadPoolData"); @@ -219,3 +219,11 @@ bool CustomPayloadPoolDataPubSubType::getKey( return true; } +void CustomPayloadPoolDataPubSubType::register_type_object_representation() const +{ + register_CustomPayloadPoolData_type_objects(); +} + + +// Include auxiliary functions like for serializing/deserializing. +#include "CustomPayloadPoolDataCdrAux.ipp" diff --git a/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolDataPubSubTypes.h b/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolDataPubSubTypes.h index a8ae92cfc06..92ce3732bea 100644 --- a/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolDataPubSubTypes.h +++ b/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolDataPubSubTypes.h @@ -27,9 +27,9 @@ #include #include #include -#include +#include -#include "CustomPayloadPoolData.h" +#include "CustomPayloadPoolData.hpp" #if !defined(GEN_API_VER) || (GEN_API_VER != 2) @@ -38,8 +38,6 @@ #endif // GEN_API_VER - - /*! * @brief This class represents the TopicDataType of the type CustomPayloadPoolData defined by the user in the IDL file. * @ingroup CustomPayloadPoolData @@ -90,6 +88,9 @@ class CustomPayloadPoolDataPubSubType : public eprosima::fastdds::dds::TopicData eProsima_user_DllExport void deleteData( void* data) override; + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + #ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED eProsima_user_DllExport inline bool is_bounded() const override { diff --git a/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolDataPublisher.cpp b/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolDataPublisher.cpp index 866a7364bc4..4fa276efbfb 100644 --- a/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolDataPublisher.cpp +++ b/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolDataPublisher.cpp @@ -17,19 +17,16 @@ * */ -#include -#include - #include "CustomPayloadPoolDataPublisher.h" +#include +#include + #include #include +#include #include #include -#include -#include -#include - using namespace eprosima::fastdds::dds; using namespace eprosima::fastdds::rtps; diff --git a/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolDataSubscriber.cpp b/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolDataSubscriber.cpp index 5dc610964ac..ab35a8684e0 100644 --- a/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolDataSubscriber.cpp +++ b/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolDataSubscriber.cpp @@ -17,17 +17,15 @@ * */ -#include - #include "CustomPayloadPoolDataSubscriber.h" +#include + #include -#include #include +#include #include #include -#include -#include using namespace eprosima::fastdds::dds; @@ -151,7 +149,7 @@ void CustomPayloadPoolDataSubscriber::on_data_available( DataReader* reader) { SampleInfo info; - if (reader->take_next_sample(&hello_, &info) == ReturnCode_t::RETCODE_OK) + if (reader->take_next_sample(&hello_, &info) == RETCODE_OK) { if (info.instance_state == ALIVE_INSTANCE_STATE) { diff --git a/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolDataSubscriber.h b/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolDataSubscriber.h index ab1ab59039d..7179f216fba 100644 --- a/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolDataSubscriber.h +++ b/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolDataSubscriber.h @@ -23,13 +23,13 @@ #include #include -#include "CustomPayloadPoolDataPubSubTypes.h" -#include "CustomPayloadPool.hpp" - #include #include #include -#include +#include + +#include "CustomPayloadPool.hpp" +#include "CustomPayloadPoolDataPubSubTypes.h" class CustomPayloadPoolDataSubscriber : private eprosima::fastdds::dds::DataReaderListener { diff --git a/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolDataTypeObjectSupport.cxx b/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolDataTypeObjectSupport.cxx new file mode 100644 index 00000000000..9491872d4ac --- /dev/null +++ b/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolDataTypeObjectSupport.cxx @@ -0,0 +1,248 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file CustomPayloadPoolDataTypeObjectSupport.cxx + * Source file containing the implementation to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#include "CustomPayloadPoolDataTypeObjectSupport.hpp" + +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include + +#include "CustomPayloadPoolData.hpp" + + +using namespace eprosima::fastdds::dds::xtypes; + +void register_CustomPayloadPoolData_type_objects() +{ + static std::once_flag once_flag; + std::call_once(once_flag, []() + { + register_CustomPayloadPoolData_type_identifier(); + + }); +} + +void register_CustomPayloadPoolData_type_identifier() +{ + { + StructTypeFlag struct_flags_CustomPayloadPoolData = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::NOT_APPLIED, + false, false); + ReturnCode_t return_code_CustomPayloadPoolData; + TypeIdentifierPair type_ids_CustomPayloadPoolData; + QualifiedTypeName type_name_CustomPayloadPoolData = "CustomPayloadPoolData"; + eprosima::fastcdr::optional type_ann_builtin_CustomPayloadPoolData; + eprosima::fastcdr::optional ann_custom_CustomPayloadPoolData; + CompleteTypeDetail detail_CustomPayloadPoolData = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_CustomPayloadPoolData, ann_custom_CustomPayloadPoolData, type_name_CustomPayloadPoolData.to_string()); + CompleteStructHeader header_CustomPayloadPoolData; + header_CustomPayloadPoolData = TypeObjectUtils::build_complete_struct_header(TypeIdentifier(), detail_CustomPayloadPoolData); + CompleteStructMemberSeq member_seq_CustomPayloadPoolData; + { + return_code_CustomPayloadPoolData = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_uint32_t", type_ids_CustomPayloadPoolData); + + if (return_code_CustomPayloadPoolData != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "index Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_index = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_index; + MemberId member_id_index = 0x00000000; + if (EK_COMPLETE == type_ids_CustomPayloadPoolData.type_identifier1()._d() || TK_NONE == type_ids_CustomPayloadPoolData.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_CustomPayloadPoolData.type_identifier1()._d() && + EK_COMPLETE == type_ids_CustomPayloadPoolData.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_CustomPayloadPoolData.type_identifier1()._d() && + EK_COMPLETE == type_ids_CustomPayloadPoolData.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_CustomPayloadPoolData.type_identifier1()._d() && + EK_COMPLETE == type_ids_CustomPayloadPoolData.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_CustomPayloadPoolData.type_identifier1()._d() && + EK_COMPLETE == type_ids_CustomPayloadPoolData.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_CustomPayloadPoolData.type_identifier1()._d() && + (EK_COMPLETE == type_ids_CustomPayloadPoolData.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_CustomPayloadPoolData.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_CustomPayloadPoolData.type_identifier1()._d() && + (EK_COMPLETE == type_ids_CustomPayloadPoolData.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_CustomPayloadPoolData.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_CustomPayloadPoolData.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_CustomPayloadPoolData.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_CustomPayloadPoolData.type_identifier2()._d() && + EK_COMPLETE == type_ids_CustomPayloadPoolData.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_CustomPayloadPoolData.type_identifier2()._d() && + EK_COMPLETE == type_ids_CustomPayloadPoolData.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_CustomPayloadPoolData.type_identifier2()._d() && + EK_COMPLETE == type_ids_CustomPayloadPoolData.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_CustomPayloadPoolData.type_identifier2()._d() && + EK_COMPLETE == type_ids_CustomPayloadPoolData.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_CustomPayloadPoolData.type_identifier2()._d() && + (EK_COMPLETE == type_ids_CustomPayloadPoolData.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_CustomPayloadPoolData.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_CustomPayloadPoolData.type_identifier2()._d() && + (EK_COMPLETE == type_ids_CustomPayloadPoolData.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_CustomPayloadPoolData.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_CustomPayloadPoolData.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure index member TypeIdentifier inconsistent."); + return; + } + MemberName name_index = "index"; + eprosima::fastcdr::optional member_ann_builtin_index; + ann_custom_CustomPayloadPoolData.reset(); + CompleteMemberDetail detail_index = TypeObjectUtils::build_complete_member_detail(name_index, member_ann_builtin_index, ann_custom_CustomPayloadPoolData); + CompleteStructMember member_index = TypeObjectUtils::build_complete_struct_member(common_index, detail_index); + TypeObjectUtils::add_complete_struct_member(member_seq_CustomPayloadPoolData, member_index); + } + { + return_code_CustomPayloadPoolData = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_string_unbounded", type_ids_CustomPayloadPoolData); + + if (return_code_CustomPayloadPoolData != eprosima::fastdds::dds::RETCODE_OK) + { + std::string type_id_kind_anonymous_string_unbounded("TI_STRING8_SMALL"); + if (type_id_kind_anonymous_string_unbounded == "TI_STRING8_SMALL") + { + SBound bound = 0; + StringSTypeDefn string_sdefn = TypeObjectUtils::build_string_s_type_defn(bound); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_string_type_identifier(string_sdefn, + "anonymous_string_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else if (type_id_kind_anonymous_string_unbounded == "TI_STRING8_LARGE") + { + LBound bound = 255; + StringLTypeDefn string_ldefn = TypeObjectUtils::build_string_l_type_defn(bound); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_string_type_identifier(string_ldefn, + "anonymous_string_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded: Unknown String kind."); + return; + } + return_code_CustomPayloadPoolData = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_string_unbounded", type_ids_CustomPayloadPoolData); + if (return_code_CustomPayloadPoolData != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded: Given String TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_message = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_message; + MemberId member_id_message = 0x00000001; + if (EK_COMPLETE == type_ids_CustomPayloadPoolData.type_identifier1()._d() || TK_NONE == type_ids_CustomPayloadPoolData.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_CustomPayloadPoolData.type_identifier1()._d() && + EK_COMPLETE == type_ids_CustomPayloadPoolData.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_CustomPayloadPoolData.type_identifier1()._d() && + EK_COMPLETE == type_ids_CustomPayloadPoolData.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_CustomPayloadPoolData.type_identifier1()._d() && + EK_COMPLETE == type_ids_CustomPayloadPoolData.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_CustomPayloadPoolData.type_identifier1()._d() && + EK_COMPLETE == type_ids_CustomPayloadPoolData.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_CustomPayloadPoolData.type_identifier1()._d() && + (EK_COMPLETE == type_ids_CustomPayloadPoolData.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_CustomPayloadPoolData.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_CustomPayloadPoolData.type_identifier1()._d() && + (EK_COMPLETE == type_ids_CustomPayloadPoolData.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_CustomPayloadPoolData.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_message = TypeObjectUtils::build_common_struct_member(member_id_message, member_flags_message, type_ids_CustomPayloadPoolData.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_CustomPayloadPoolData.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_CustomPayloadPoolData.type_identifier2()._d() && + EK_COMPLETE == type_ids_CustomPayloadPoolData.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_CustomPayloadPoolData.type_identifier2()._d() && + EK_COMPLETE == type_ids_CustomPayloadPoolData.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_CustomPayloadPoolData.type_identifier2()._d() && + EK_COMPLETE == type_ids_CustomPayloadPoolData.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_CustomPayloadPoolData.type_identifier2()._d() && + EK_COMPLETE == type_ids_CustomPayloadPoolData.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_CustomPayloadPoolData.type_identifier2()._d() && + (EK_COMPLETE == type_ids_CustomPayloadPoolData.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_CustomPayloadPoolData.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_CustomPayloadPoolData.type_identifier2()._d() && + (EK_COMPLETE == type_ids_CustomPayloadPoolData.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_CustomPayloadPoolData.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_message = TypeObjectUtils::build_common_struct_member(member_id_message, member_flags_message, type_ids_CustomPayloadPoolData.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure message member TypeIdentifier inconsistent."); + return; + } + MemberName name_message = "message"; + eprosima::fastcdr::optional member_ann_builtin_message; + ann_custom_CustomPayloadPoolData.reset(); + CompleteMemberDetail detail_message = TypeObjectUtils::build_complete_member_detail(name_message, member_ann_builtin_message, ann_custom_CustomPayloadPoolData); + CompleteStructMember member_message = TypeObjectUtils::build_complete_struct_member(common_message, detail_message); + TypeObjectUtils::add_complete_struct_member(member_seq_CustomPayloadPoolData, member_message); + } + CompleteStructType struct_type_CustomPayloadPoolData = TypeObjectUtils::build_complete_struct_type(struct_flags_CustomPayloadPoolData, header_CustomPayloadPoolData, member_seq_CustomPayloadPoolData); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_struct_type_object(struct_type_CustomPayloadPoolData, type_name_CustomPayloadPoolData.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "CustomPayloadPoolData already registered in TypeObjectRegistry for a different type."); + } + return_code_CustomPayloadPoolData = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "CustomPayloadPoolData", type_ids_CustomPayloadPoolData); + if (return_code_CustomPayloadPoolData != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "CustomPayloadPoolData: Given Struct TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } +} + diff --git a/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolDataTypeObjectSupport.hpp b/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolDataTypeObjectSupport.hpp new file mode 100644 index 00000000000..adc9d80573a --- /dev/null +++ b/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolDataTypeObjectSupport.hpp @@ -0,0 +1,54 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file CustomPayloadPoolDataTypeObjectSupport.hpp + * Header file containing the API required to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#ifndef _FAST_DDS_GENERATED_CUSTOMPAYLOADPOOLDATA_TYPE_OBJECT_SUPPORT_HPP_ +#define _FAST_DDS_GENERATED_CUSTOMPAYLOADPOOLDATA_TYPE_OBJECT_SUPPORT_HPP_ + + +#if defined(_WIN32) +#if defined(EPROSIMA_USER_DLL_EXPORT) +#define eProsima_user_DllExport __declspec( dllexport ) +#else +#define eProsima_user_DllExport +#endif // EPROSIMA_USER_DLL_EXPORT +#else +#define eProsima_user_DllExport +#endif // _WIN32 + +/** + * @brief Register every TypeObject representation defined in the IDL file in Fast DDS TypeObjectRegistry. + */ +eProsima_user_DllExport void register_CustomPayloadPoolData_type_objects(); + +#ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +/** + * @brief Register CustomPayloadPoolData related TypeIdentifier. + * Fully-descriptive TypeIdentifiers are directly registered. + * Hash TypeIdentifiers require to fill the TypeObject information and hash it, consequently, the TypeObject is + * indirectly registered as well. + */ +void register_CustomPayloadPoolData_type_identifier(); + + +#endif // DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +#endif // _FAST_DDS_GENERATED_CUSTOMPAYLOADPOOLDATA_TYPE_OBJECT_SUPPORT_HPP_ diff --git a/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolDatav1.cxx b/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolDatav1.cxx deleted file mode 100644 index 51f45ea225f..00000000000 --- a/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolDatav1.cxx +++ /dev/null @@ -1,286 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file CustomPayloadPoolData.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "CustomPayloadPoolData.h" - -#if FASTCDR_VERSION_MAJOR == 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - -namespace helper { namespace internal { - -enum class Size { - UInt8, - UInt16, - UInt32, - UInt64, -}; - -constexpr Size get_size(int s) { - return (s <= 8 ) ? Size::UInt8: - (s <= 16) ? Size::UInt16: - (s <= 32) ? Size::UInt32: Size::UInt64; -} - -template -struct FindTypeH; - -template<> -struct FindTypeH { - using type = std::uint8_t; -}; - -template<> -struct FindTypeH { - using type = std::uint16_t; -}; - -template<> -struct FindTypeH { - using type = std::uint32_t; -}; - -template<> -struct FindTypeH { - using type = std::uint64_t; -}; -} - -template -struct FindType { - using type = typename internal::FindTypeH::type; -}; -} - -#define CustomPayloadPoolData_max_cdr_typesize 268ULL; - - - - -CustomPayloadPoolData::CustomPayloadPoolData() -{ - // unsigned long m_index - m_index = 0; - // /type_d() m_message - - -} - -CustomPayloadPoolData::~CustomPayloadPoolData() -{ -} - -CustomPayloadPoolData::CustomPayloadPoolData( - const CustomPayloadPoolData& x) -{ - m_index = x.m_index; - - - m_message = x.m_message; - -} - -CustomPayloadPoolData::CustomPayloadPoolData( - CustomPayloadPoolData&& x) noexcept -{ - m_index = x.m_index; - - - m_message = std::move(x.m_message); - -} - -CustomPayloadPoolData& CustomPayloadPoolData::operator =( - const CustomPayloadPoolData& x) -{ - m_index = x.m_index; - - - m_message = x.m_message; - - return *this; -} - -CustomPayloadPoolData& CustomPayloadPoolData::operator =( - CustomPayloadPoolData&& x) noexcept -{ - m_index = x.m_index; - - - m_message = std::move(x.m_message); - - return *this; -} - -bool CustomPayloadPoolData::operator ==( - const CustomPayloadPoolData& x) const -{ - return (m_index == x.m_index && - m_message == x.m_message); -} - -bool CustomPayloadPoolData::operator !=( - const CustomPayloadPoolData& x) const -{ - return !(*this == x); -} - -size_t CustomPayloadPoolData::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return CustomPayloadPoolData_max_cdr_typesize; -} - -size_t CustomPayloadPoolData::getCdrSerializedSize( - const CustomPayloadPoolData& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + data.message().size() + 1; - - - return current_alignment - initial_alignment; -} - - -void CustomPayloadPoolData::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_index; - - scdr << m_message.c_str(); - -} - -void CustomPayloadPoolData::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_index; - - - - dcdr >> m_message; - - -} - - -bool CustomPayloadPoolData::isKeyDefined() -{ - return false; -} - -void CustomPayloadPoolData::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void CustomPayloadPoolData::index( - uint32_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint32_t CustomPayloadPoolData::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint32_t& CustomPayloadPoolData::index() -{ - return m_index; -} - - -/*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ -void CustomPayloadPoolData::message( - const std::string& _message) -{ - m_message = _message; -} - -/*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ -void CustomPayloadPoolData::message( - std::string&& _message) -{ - m_message = std::move(_message); -} - -/*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ -const std::string& CustomPayloadPoolData::message() const -{ - return m_message; -} - -/*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ -std::string& CustomPayloadPoolData::message() -{ - return m_message; -} - - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolDatav1.h b/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolDatav1.h deleted file mode 100644 index 1779f3b76d7..00000000000 --- a/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPoolDatav1.h +++ /dev/null @@ -1,244 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file CustomPayloadPoolData.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#include - -#if FASTCDR_VERSION_MAJOR == 1 - -#ifndef _FAST_DDS_GENERATED_CUSTOMPAYLOADPOOLDATA_H_ -#define _FAST_DDS_GENERATED_CUSTOMPAYLOADPOOLDATA_H_ - - -#include - -#include -#include -#include -#include -#include -#include -#include - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define eProsima_user_DllExport -#endif // _WIN32 - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(CUSTOMPAYLOADPOOLDATA_SOURCE) -#define CUSTOMPAYLOADPOOLDATA_DllAPI __declspec( dllexport ) -#else -#define CUSTOMPAYLOADPOOLDATA_DllAPI __declspec( dllimport ) -#endif // CUSTOMPAYLOADPOOLDATA_SOURCE -#else -#define CUSTOMPAYLOADPOOLDATA_DllAPI -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define CUSTOMPAYLOADPOOLDATA_DllAPI -#endif // _WIN32 - -namespace eprosima { -namespace fastcdr { -class Cdr; -} // namespace fastcdr -} // namespace eprosima - - - - - -/*! - * @brief This class represents the structure CustomPayloadPoolData defined by the user in the IDL file. - * @ingroup CustomPayloadPoolData - */ -class CustomPayloadPoolData -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport CustomPayloadPoolData(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~CustomPayloadPoolData(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object CustomPayloadPoolData that will be copied. - */ - eProsima_user_DllExport CustomPayloadPoolData( - const CustomPayloadPoolData& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object CustomPayloadPoolData that will be copied. - */ - eProsima_user_DllExport CustomPayloadPoolData( - CustomPayloadPoolData&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object CustomPayloadPoolData that will be copied. - */ - eProsima_user_DllExport CustomPayloadPoolData& operator =( - const CustomPayloadPoolData& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object CustomPayloadPoolData that will be copied. - */ - eProsima_user_DllExport CustomPayloadPoolData& operator =( - CustomPayloadPoolData&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x CustomPayloadPoolData object to compare. - */ - eProsima_user_DllExport bool operator ==( - const CustomPayloadPoolData& x) const; - - /*! - * @brief Comparison operator. - * @param x CustomPayloadPoolData object to compare. - */ - eProsima_user_DllExport bool operator !=( - const CustomPayloadPoolData& x) const; - - /*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ - eProsima_user_DllExport void index( - uint32_t _index); - - /*! - * @brief This function returns the value of member index - * @return Value of member index - */ - eProsima_user_DllExport uint32_t index() const; - - /*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ - eProsima_user_DllExport uint32_t& index(); - - - /*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ - eProsima_user_DllExport void message( - const std::string& _message); - - /*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ - eProsima_user_DllExport void message( - std::string&& _message); - - /*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ - eProsima_user_DllExport const std::string& message() const; - - /*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ - eProsima_user_DllExport std::string& message(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const CustomPayloadPoolData& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - uint32_t m_index; - std::string m_message; - -}; - - -#endif // _FAST_DDS_GENERATED_CUSTOMPAYLOADPOOLDATA_H_ - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPool_main.cpp b/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPool_main.cpp index da78c8a224c..fd9f9db33ab 100644 --- a/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPool_main.cpp +++ b/examples/cpp/dds/CustomPayloadPoolExample/CustomPayloadPool_main.cpp @@ -20,14 +20,13 @@ #include #include -#include "CustomPayloadPoolDataPublisher.h" -#include "CustomPayloadPoolDataSubscriber.h" - #include -#include - +#include #include +#include "CustomPayloadPoolDataPublisher.h" +#include "CustomPayloadPoolDataSubscriber.h" + using eprosima::fastdds::dds::Log; namespace option = eprosima::option; diff --git a/examples/cpp/dds/DeadlineQoSExample/CMakeLists.txt b/examples/cpp/dds/DeadlineQoSExample/CMakeLists.txt index 4a5f3ba2af1..3713e6e2b83 100644 --- a/examples/cpp/dds/DeadlineQoSExample/CMakeLists.txt +++ b/examples/cpp/dds/DeadlineQoSExample/CMakeLists.txt @@ -25,8 +25,8 @@ if(NOT foonathan_memory_FOUND) find_package(foonathan_memory REQUIRED) endif() -if(NOT fastrtps_FOUND) - find_package(fastrtps 2.12 REQUIRED) +if(NOT fastdds_FOUND) + find_package(fastdds 3 REQUIRED) endif() #Check C++11 @@ -46,7 +46,7 @@ target_compile_definitions(DDSDeadlineQoSExample PRIVATE $<$>,$>:__DEBUG> $<$:__INTERNALDEBUG> # Internal debug activated. ) -target_link_libraries(DDSDeadlineQoSExample fastrtps fastcdr foonathan_memory) +target_link_libraries(DDSDeadlineQoSExample fastdds fastcdr foonathan_memory) if(UNIX AND NOT(QNXNTO) AND NOT(ANDROID)) target_link_libraries(DDSDeadlineQoSExample pthread) endif() diff --git a/examples/cpp/dds/DeadlineQoSExample/deadlinepayload.cxx b/examples/cpp/dds/DeadlineQoSExample/deadlinepayload.cxx deleted file mode 100644 index ded92f4bcdc..00000000000 --- a/examples/cpp/dds/DeadlineQoSExample/deadlinepayload.cxx +++ /dev/null @@ -1,168 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file deadlinepayload.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "deadlinepayload.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - - - - -HelloMsg::HelloMsg() -{ -} - -HelloMsg::~HelloMsg() -{ -} - -HelloMsg::HelloMsg( - const HelloMsg& x) -{ - m_deadlinekey = x.m_deadlinekey; - m_payload = x.m_payload; -} - -HelloMsg::HelloMsg( - HelloMsg&& x) noexcept -{ - m_deadlinekey = x.m_deadlinekey; - m_payload = std::move(x.m_payload); -} - -HelloMsg& HelloMsg::operator =( - const HelloMsg& x) -{ - - m_deadlinekey = x.m_deadlinekey; - m_payload = x.m_payload; - return *this; -} - -HelloMsg& HelloMsg::operator =( - HelloMsg&& x) noexcept -{ - - m_deadlinekey = x.m_deadlinekey; - m_payload = std::move(x.m_payload); - return *this; -} - -bool HelloMsg::operator ==( - const HelloMsg& x) const -{ - return (m_deadlinekey == x.m_deadlinekey && - m_payload == x.m_payload); -} - -bool HelloMsg::operator !=( - const HelloMsg& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member deadlinekey - * @param _deadlinekey New value for member deadlinekey - */ -void HelloMsg::deadlinekey( - uint16_t _deadlinekey) -{ - m_deadlinekey = _deadlinekey; -} - -/*! - * @brief This function returns the value of member deadlinekey - * @return Value of member deadlinekey - */ -uint16_t HelloMsg::deadlinekey() const -{ - return m_deadlinekey; -} - -/*! - * @brief This function returns a reference to member deadlinekey - * @return Reference to member deadlinekey - */ -uint16_t& HelloMsg::deadlinekey() -{ - return m_deadlinekey; -} - - -/*! - * @brief This function copies the value in member payload - * @param _payload New value to be copied in member payload - */ -void HelloMsg::payload( - const eprosima::fastcdr::fixed_string<256>& _payload) -{ - m_payload = _payload; -} - -/*! - * @brief This function moves the value in member payload - * @param _payload New value to be moved in member payload - */ -void HelloMsg::payload( - eprosima::fastcdr::fixed_string<256>&& _payload) -{ - m_payload = std::move(_payload); -} - -/*! - * @brief This function returns a constant reference to member payload - * @return Constant reference to member payload - */ -const eprosima::fastcdr::fixed_string<256>& HelloMsg::payload() const -{ - return m_payload; -} - -/*! - * @brief This function returns a reference to member payload - * @return Reference to member payload - */ -eprosima::fastcdr::fixed_string<256>& HelloMsg::payload() -{ - return m_payload; -} - - -// Include auxiliary functions like for serializing/deserializing. -#include "deadlinepayloadCdrAux.ipp" - -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/DeadlineQoSExample/deadlinepayload.h b/examples/cpp/dds/DeadlineQoSExample/deadlinepayload.hpp similarity index 71% rename from examples/cpp/dds/DeadlineQoSExample/deadlinepayload.h rename to examples/cpp/dds/DeadlineQoSExample/deadlinepayload.hpp index 4dd530394b2..e46adfefb01 100644 --- a/examples/cpp/dds/DeadlineQoSExample/deadlinepayload.h +++ b/examples/cpp/dds/DeadlineQoSExample/deadlinepayload.hpp @@ -13,32 +13,19 @@ // limitations under the License. /*! - * @file deadlinepayload.h + * @file deadlinepayload.hpp * This header file contains the declaration of the described types in the IDL file. * * This file was generated by the tool fastddsgen. */ -#include -#include "deadlinepayloadv1.h" +#ifndef _FAST_DDS_GENERATED_DEADLINEPAYLOAD_HPP_ +#define _FAST_DDS_GENERATED_DEADLINEPAYLOAD_HPP_ -#if FASTCDR_VERSION_MAJOR > 1 - -#ifndef _FAST_DDS_GENERATED_DEADLINEPAYLOAD_H_ -#define _FAST_DDS_GENERATED_DEADLINEPAYLOAD_H_ - -#include -#include #include -#include #include -#include - +#include #include -#include -#include - - #if defined(_WIN32) #if defined(EPROSIMA_USER_DLL_EXPORT) @@ -64,17 +51,6 @@ #define DEADLINEPAYLOAD_DllAPI #endif // _WIN32 -namespace eprosima { -namespace fastcdr { -class Cdr; -class CdrSizeCalculator; -} // namespace fastcdr -} // namespace eprosima - - - - - /*! * @brief This class represents the structure HelloMsg defined by the user in the IDL file. * @ingroup deadlinepayload @@ -86,73 +62,117 @@ class HelloMsg /*! * @brief Default constructor. */ - eProsima_user_DllExport HelloMsg(); + eProsima_user_DllExport HelloMsg() + { + } /*! * @brief Default destructor. */ - eProsima_user_DllExport ~HelloMsg(); + eProsima_user_DllExport ~HelloMsg() + { + } /*! * @brief Copy constructor. * @param x Reference to the object HelloMsg that will be copied. */ eProsima_user_DllExport HelloMsg( - const HelloMsg& x); + const HelloMsg& x) + { + m_deadlinekey = x.m_deadlinekey; + + m_payload = x.m_payload; + + } /*! * @brief Move constructor. * @param x Reference to the object HelloMsg that will be copied. */ eProsima_user_DllExport HelloMsg( - HelloMsg&& x) noexcept; + HelloMsg&& x) noexcept + { + m_deadlinekey = x.m_deadlinekey; + m_payload = std::move(x.m_payload); + } /*! * @brief Copy assignment. * @param x Reference to the object HelloMsg that will be copied. */ eProsima_user_DllExport HelloMsg& operator =( - const HelloMsg& x); + const HelloMsg& x) + { + + m_deadlinekey = x.m_deadlinekey; + + m_payload = x.m_payload; + + return *this; + } /*! * @brief Move assignment. * @param x Reference to the object HelloMsg that will be copied. */ eProsima_user_DllExport HelloMsg& operator =( - HelloMsg&& x) noexcept; + HelloMsg&& x) noexcept + { + + m_deadlinekey = x.m_deadlinekey; + m_payload = std::move(x.m_payload); + return *this; + } /*! * @brief Comparison operator. * @param x HelloMsg object to compare. */ eProsima_user_DllExport bool operator ==( - const HelloMsg& x) const; + const HelloMsg& x) const + { + return (m_deadlinekey == x.m_deadlinekey && + m_payload == x.m_payload); + } /*! * @brief Comparison operator. * @param x HelloMsg object to compare. */ eProsima_user_DllExport bool operator !=( - const HelloMsg& x) const; + const HelloMsg& x) const + { + return !(*this == x); + } /*! * @brief This function sets a value in member deadlinekey * @param _deadlinekey New value for member deadlinekey */ eProsima_user_DllExport void deadlinekey( - uint16_t _deadlinekey); + uint16_t _deadlinekey) + { + m_deadlinekey = _deadlinekey; + } /*! * @brief This function returns the value of member deadlinekey * @return Value of member deadlinekey */ - eProsima_user_DllExport uint16_t deadlinekey() const; + eProsima_user_DllExport uint16_t deadlinekey() const + { + return m_deadlinekey; + } /*! * @brief This function returns a reference to member deadlinekey * @return Reference to member deadlinekey */ - eProsima_user_DllExport uint16_t& deadlinekey(); + eProsima_user_DllExport uint16_t& deadlinekey() + { + return m_deadlinekey; + } /*! @@ -160,26 +180,40 @@ class HelloMsg * @param _payload New value to be copied in member payload */ eProsima_user_DllExport void payload( - const eprosima::fastcdr::fixed_string<256>& _payload); + const eprosima::fastcdr::fixed_string<256>& _payload) + { + m_payload = _payload; + } /*! * @brief This function moves the value in member payload * @param _payload New value to be moved in member payload */ eProsima_user_DllExport void payload( - eprosima::fastcdr::fixed_string<256>&& _payload); + eprosima::fastcdr::fixed_string<256>&& _payload) + { + m_payload = std::move(_payload); + } /*! * @brief This function returns a constant reference to member payload * @return Constant reference to member payload */ - eProsima_user_DllExport const eprosima::fastcdr::fixed_string<256>& payload() const; + eProsima_user_DllExport const eprosima::fastcdr::fixed_string<256>& payload() const + { + return m_payload; + } /*! * @brief This function returns a reference to member payload * @return Reference to member payload */ - eProsima_user_DllExport eprosima::fastcdr::fixed_string<256>& payload(); + eProsima_user_DllExport eprosima::fastcdr::fixed_string<256>& payload() + { + return m_payload; + } + + private: @@ -188,8 +222,6 @@ class HelloMsg }; -#endif // _FAST_DDS_GENERATED_DEADLINEPAYLOAD_H_ - +#endif // _FAST_DDS_GENERATED_DEADLINEPAYLOAD_HPP_ -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/DeadlineQoSExample/deadlinepayloadCdrAux.hpp b/examples/cpp/dds/DeadlineQoSExample/deadlinepayloadCdrAux.hpp index cf5ad3e0bdc..a23da79e9bb 100644 --- a/examples/cpp/dds/DeadlineQoSExample/deadlinepayloadCdrAux.hpp +++ b/examples/cpp/dds/DeadlineQoSExample/deadlinepayloadCdrAux.hpp @@ -22,7 +22,7 @@ #ifndef _FAST_DDS_GENERATED_DEADLINEPAYLOADCDRAUX_HPP_ #define _FAST_DDS_GENERATED_DEADLINEPAYLOADCDRAUX_HPP_ -#include "deadlinepayload.h" +#include "deadlinepayload.hpp" constexpr uint32_t HelloMsg_max_cdr_typesize {269UL}; constexpr uint32_t HelloMsg_max_key_cdr_typesize {2UL}; @@ -34,8 +34,6 @@ namespace fastcdr { class Cdr; class CdrSizeCalculator; - - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const HelloMsg& data); diff --git a/examples/cpp/dds/DeadlineQoSExample/deadlinepayloadCdrAux.ipp b/examples/cpp/dds/DeadlineQoSExample/deadlinepayloadCdrAux.ipp index a16c0446aab..6dd3947b3c6 100644 --- a/examples/cpp/dds/DeadlineQoSExample/deadlinepayloadCdrAux.ipp +++ b/examples/cpp/dds/DeadlineQoSExample/deadlinepayloadCdrAux.ipp @@ -34,8 +34,6 @@ using namespace eprosima::fastcdr::exception; namespace eprosima { namespace fastcdr { - - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, diff --git a/examples/cpp/dds/DeadlineQoSExample/deadlinepayloadPubSubMain.cxx b/examples/cpp/dds/DeadlineQoSExample/deadlinepayloadPubSubMain.cxx index e47cbdda0c6..47f019ba6ff 100644 --- a/examples/cpp/dds/DeadlineQoSExample/deadlinepayloadPubSubMain.cxx +++ b/examples/cpp/dds/DeadlineQoSExample/deadlinepayloadPubSubMain.cxx @@ -15,10 +15,6 @@ #include "deadlinepayloadPublisher.h" #include "deadlinepayloadSubscriber.h" - -#include -#include - using namespace eprosima; using namespace eprosima::fastrtps; diff --git a/examples/cpp/dds/DeadlineQoSExample/deadlinepayloadPubSubTypes.cxx b/examples/cpp/dds/DeadlineQoSExample/deadlinepayloadPubSubTypes.cxx index 300ac806538..faa25783be9 100644 --- a/examples/cpp/dds/DeadlineQoSExample/deadlinepayloadPubSubTypes.cxx +++ b/examples/cpp/dds/DeadlineQoSExample/deadlinepayloadPubSubTypes.cxx @@ -19,18 +19,18 @@ * This file was generated by the tool fastddsgen. */ +#include "deadlinepayloadPubSubTypes.h" +#include #include -#include "deadlinepayloadPubSubTypes.h" #include "deadlinepayloadCdrAux.hpp" +#include "deadlinepayloadTypeObjectSupport.hpp" using SerializedPayload_t = eprosima::fastrtps::rtps::SerializedPayload_t; using InstanceHandle_t = eprosima::fastrtps::rtps::InstanceHandle_t; using DataRepresentationId_t = eprosima::fastdds::dds::DataRepresentationId_t; - - HelloMsgPubSubType::HelloMsgPubSubType() { setName("HelloMsg"); @@ -219,3 +219,11 @@ bool HelloMsgPubSubType::getKey( return true; } +void HelloMsgPubSubType::register_type_object_representation() const +{ + register_deadlinepayload_type_objects(); +} + + +// Include auxiliary functions like for serializing/deserializing. +#include "deadlinepayloadCdrAux.ipp" diff --git a/examples/cpp/dds/DeadlineQoSExample/deadlinepayloadPubSubTypes.h b/examples/cpp/dds/DeadlineQoSExample/deadlinepayloadPubSubTypes.h index bc9fceae08e..a49ed543f16 100644 --- a/examples/cpp/dds/DeadlineQoSExample/deadlinepayloadPubSubTypes.h +++ b/examples/cpp/dds/DeadlineQoSExample/deadlinepayloadPubSubTypes.h @@ -27,9 +27,9 @@ #include #include #include -#include +#include -#include "deadlinepayload.h" +#include "deadlinepayload.hpp" #if !defined(GEN_API_VER) || (GEN_API_VER != 2) @@ -38,8 +38,6 @@ #endif // GEN_API_VER - - /*! * @brief This class represents the TopicDataType of the type HelloMsg defined by the user in the IDL file. * @ingroup deadlinepayload @@ -90,6 +88,9 @@ class HelloMsgPubSubType : public eprosima::fastdds::dds::TopicDataType eProsima_user_DllExport void deleteData( void* data) override; + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + #ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED eProsima_user_DllExport inline bool is_bounded() const override { diff --git a/examples/cpp/dds/DeadlineQoSExample/deadlinepayloadSubscriber.cxx b/examples/cpp/dds/DeadlineQoSExample/deadlinepayloadSubscriber.cxx index 09d89827bac..0a893426857 100644 --- a/examples/cpp/dds/DeadlineQoSExample/deadlinepayloadSubscriber.cxx +++ b/examples/cpp/dds/DeadlineQoSExample/deadlinepayloadSubscriber.cxx @@ -124,7 +124,7 @@ void deadlinepayloadSubscriber::SubListener::on_data_available( { SampleInfo info; HelloMsg st; - if (reader->take_next_sample(&st, &info) == ReturnCode_t::RETCODE_OK) + if (reader->take_next_sample(&st, &info) == RETCODE_OK) { if (info.valid_data) { diff --git a/examples/cpp/dds/DeadlineQoSExample/deadlinepayloadSubscriber.h b/examples/cpp/dds/DeadlineQoSExample/deadlinepayloadSubscriber.h index d65f44d76cd..bda26f3e921 100644 --- a/examples/cpp/dds/DeadlineQoSExample/deadlinepayloadSubscriber.h +++ b/examples/cpp/dds/DeadlineQoSExample/deadlinepayloadSubscriber.h @@ -24,15 +24,13 @@ #define _DEADLINEPAYLOAD_SUBSCRIBER_H_ #include -#include #include #include +#include #include #include "deadlinepayloadPubSubTypes.h" -#include "mapableKey.h" - class deadlinepayloadSubscriber { public: diff --git a/examples/cpp/dds/DeadlineQoSExample/deadlinepayloadTypeObjectSupport.cxx b/examples/cpp/dds/DeadlineQoSExample/deadlinepayloadTypeObjectSupport.cxx new file mode 100644 index 00000000000..4d75ddf0def --- /dev/null +++ b/examples/cpp/dds/DeadlineQoSExample/deadlinepayloadTypeObjectSupport.cxx @@ -0,0 +1,261 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file deadlinepayloadTypeObjectSupport.cxx + * Source file containing the implementation to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#include "deadlinepayloadTypeObjectSupport.hpp" + +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include + +#include "deadlinepayload.hpp" + + +using namespace eprosima::fastdds::dds::xtypes; + +void register_deadlinepayload_type_objects() +{ + static std::once_flag once_flag; + std::call_once(once_flag, []() + { + register_HelloMsg_type_identifier(); + + }); +} + +void register_HelloMsg_type_identifier() +{ + { + StructTypeFlag struct_flags_HelloMsg = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::NOT_APPLIED, + false, false); + ReturnCode_t return_code_HelloMsg; + TypeIdentifierPair type_ids_HelloMsg; + QualifiedTypeName type_name_HelloMsg = "HelloMsg"; + eprosima::fastcdr::optional type_ann_builtin_HelloMsg; + eprosima::fastcdr::optional ann_custom_HelloMsg; + CompleteTypeDetail detail_HelloMsg = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_HelloMsg, ann_custom_HelloMsg, type_name_HelloMsg.to_string()); + CompleteStructHeader header_HelloMsg; + header_HelloMsg = TypeObjectUtils::build_complete_struct_header(TypeIdentifier(), detail_HelloMsg); + CompleteStructMemberSeq member_seq_HelloMsg; + { + return_code_HelloMsg = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_uint16_t", type_ids_HelloMsg); + + if (return_code_HelloMsg != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "deadlinekey Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_deadlinekey = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, true, false); + CommonStructMember common_deadlinekey; + MemberId member_id_deadlinekey = 0x00000000; + if (EK_COMPLETE == type_ids_HelloMsg.type_identifier1()._d() || TK_NONE == type_ids_HelloMsg.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_HelloMsg.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloMsg.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_HelloMsg.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloMsg.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_HelloMsg.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloMsg.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_HelloMsg.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloMsg.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_HelloMsg.type_identifier1()._d() && + (EK_COMPLETE == type_ids_HelloMsg.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloMsg.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_HelloMsg.type_identifier1()._d() && + (EK_COMPLETE == type_ids_HelloMsg.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloMsg.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_deadlinekey = TypeObjectUtils::build_common_struct_member(member_id_deadlinekey, member_flags_deadlinekey, type_ids_HelloMsg.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_HelloMsg.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_HelloMsg.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloMsg.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_HelloMsg.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloMsg.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_HelloMsg.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloMsg.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_HelloMsg.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloMsg.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_HelloMsg.type_identifier2()._d() && + (EK_COMPLETE == type_ids_HelloMsg.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloMsg.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_HelloMsg.type_identifier2()._d() && + (EK_COMPLETE == type_ids_HelloMsg.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloMsg.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_deadlinekey = TypeObjectUtils::build_common_struct_member(member_id_deadlinekey, member_flags_deadlinekey, type_ids_HelloMsg.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure deadlinekey member TypeIdentifier inconsistent."); + return; + } + MemberName name_deadlinekey = "deadlinekey"; + eprosima::fastcdr::optional member_ann_builtin_deadlinekey; + ann_custom_HelloMsg.reset(); + AppliedAnnotationSeq tmp_ann_custom_deadlinekey; + eprosima::fastcdr::optional unit_deadlinekey; + eprosima::fastcdr::optional min_deadlinekey; + eprosima::fastcdr::optional max_deadlinekey; + eprosima::fastcdr::optional hash_id_deadlinekey; + if (unit_deadlinekey.has_value() || min_deadlinekey.has_value() || max_deadlinekey.has_value() || hash_id_deadlinekey.has_value()) + { + member_ann_builtin_deadlinekey = TypeObjectUtils::build_applied_builtin_member_annotations(unit_deadlinekey, min_deadlinekey, max_deadlinekey, hash_id_deadlinekey); + } + if (!tmp_ann_custom_deadlinekey.empty()) + { + ann_custom_HelloMsg = tmp_ann_custom_deadlinekey; + } + CompleteMemberDetail detail_deadlinekey = TypeObjectUtils::build_complete_member_detail(name_deadlinekey, member_ann_builtin_deadlinekey, ann_custom_HelloMsg); + CompleteStructMember member_deadlinekey = TypeObjectUtils::build_complete_struct_member(common_deadlinekey, detail_deadlinekey); + TypeObjectUtils::add_complete_struct_member(member_seq_HelloMsg, member_deadlinekey); + } + { + return_code_HelloMsg = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_string_256", type_ids_HelloMsg); + + if (return_code_HelloMsg != eprosima::fastdds::dds::RETCODE_OK) + { + std::string type_id_kind_anonymous_string_256("TI_STRING8_LARGE"); + if (type_id_kind_anonymous_string_256 == "TI_STRING8_SMALL") + { + SBound bound = static_cast(256); + StringSTypeDefn string_sdefn = TypeObjectUtils::build_string_s_type_defn(bound); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_string_type_identifier(string_sdefn, + "anonymous_string_256")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_256 already registered in TypeObjectRegistry for a different type."); + } + } + else if (type_id_kind_anonymous_string_256 == "TI_STRING8_LARGE") + { + LBound bound = 256; + StringLTypeDefn string_ldefn = TypeObjectUtils::build_string_l_type_defn(bound); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_string_type_identifier(string_ldefn, + "anonymous_string_256")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_256 already registered in TypeObjectRegistry for a different type."); + } + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_256: Unknown String kind."); + return; + } + return_code_HelloMsg = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_string_256", type_ids_HelloMsg); + if (return_code_HelloMsg != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_256: Given String TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_payload = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_payload; + MemberId member_id_payload = 0x00000001; + if (EK_COMPLETE == type_ids_HelloMsg.type_identifier1()._d() || TK_NONE == type_ids_HelloMsg.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_HelloMsg.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloMsg.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_HelloMsg.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloMsg.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_HelloMsg.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloMsg.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_HelloMsg.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloMsg.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_HelloMsg.type_identifier1()._d() && + (EK_COMPLETE == type_ids_HelloMsg.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloMsg.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_HelloMsg.type_identifier1()._d() && + (EK_COMPLETE == type_ids_HelloMsg.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloMsg.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_payload = TypeObjectUtils::build_common_struct_member(member_id_payload, member_flags_payload, type_ids_HelloMsg.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_HelloMsg.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_HelloMsg.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloMsg.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_HelloMsg.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloMsg.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_HelloMsg.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloMsg.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_HelloMsg.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloMsg.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_HelloMsg.type_identifier2()._d() && + (EK_COMPLETE == type_ids_HelloMsg.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloMsg.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_HelloMsg.type_identifier2()._d() && + (EK_COMPLETE == type_ids_HelloMsg.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloMsg.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_payload = TypeObjectUtils::build_common_struct_member(member_id_payload, member_flags_payload, type_ids_HelloMsg.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure payload member TypeIdentifier inconsistent."); + return; + } + MemberName name_payload = "payload"; + eprosima::fastcdr::optional member_ann_builtin_payload; + ann_custom_HelloMsg.reset(); + CompleteMemberDetail detail_payload = TypeObjectUtils::build_complete_member_detail(name_payload, member_ann_builtin_payload, ann_custom_HelloMsg); + CompleteStructMember member_payload = TypeObjectUtils::build_complete_struct_member(common_payload, detail_payload); + TypeObjectUtils::add_complete_struct_member(member_seq_HelloMsg, member_payload); + } + CompleteStructType struct_type_HelloMsg = TypeObjectUtils::build_complete_struct_type(struct_flags_HelloMsg, header_HelloMsg, member_seq_HelloMsg); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_struct_type_object(struct_type_HelloMsg, type_name_HelloMsg.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "HelloMsg already registered in TypeObjectRegistry for a different type."); + } + return_code_HelloMsg = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "HelloMsg", type_ids_HelloMsg); + if (return_code_HelloMsg != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "HelloMsg: Given Struct TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } +} + diff --git a/examples/cpp/dds/DeadlineQoSExample/deadlinepayloadTypeObjectSupport.hpp b/examples/cpp/dds/DeadlineQoSExample/deadlinepayloadTypeObjectSupport.hpp new file mode 100644 index 00000000000..ae7ba5c9f0a --- /dev/null +++ b/examples/cpp/dds/DeadlineQoSExample/deadlinepayloadTypeObjectSupport.hpp @@ -0,0 +1,54 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file deadlinepayloadTypeObjectSupport.hpp + * Header file containing the API required to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#ifndef _FAST_DDS_GENERATED_DEADLINEPAYLOAD_TYPE_OBJECT_SUPPORT_HPP_ +#define _FAST_DDS_GENERATED_DEADLINEPAYLOAD_TYPE_OBJECT_SUPPORT_HPP_ + + +#if defined(_WIN32) +#if defined(EPROSIMA_USER_DLL_EXPORT) +#define eProsima_user_DllExport __declspec( dllexport ) +#else +#define eProsima_user_DllExport +#endif // EPROSIMA_USER_DLL_EXPORT +#else +#define eProsima_user_DllExport +#endif // _WIN32 + +/** + * @brief Register every TypeObject representation defined in the IDL file in Fast DDS TypeObjectRegistry. + */ +eProsima_user_DllExport void register_deadlinepayload_type_objects(); + +#ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +/** + * @brief Register HelloMsg related TypeIdentifier. + * Fully-descriptive TypeIdentifiers are directly registered. + * Hash TypeIdentifiers require to fill the TypeObject information and hash it, consequently, the TypeObject is + * indirectly registered as well. + */ +void register_HelloMsg_type_identifier(); + + +#endif // DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +#endif // _FAST_DDS_GENERATED_DEADLINEPAYLOAD_TYPE_OBJECT_SUPPORT_HPP_ diff --git a/examples/cpp/dds/DeadlineQoSExample/deadlinepayloadv1.cxx b/examples/cpp/dds/DeadlineQoSExample/deadlinepayloadv1.cxx deleted file mode 100644 index 6e8e3e66443..00000000000 --- a/examples/cpp/dds/DeadlineQoSExample/deadlinepayloadv1.cxx +++ /dev/null @@ -1,294 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file deadlinepayload.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "deadlinepayload.h" - -#if FASTCDR_VERSION_MAJOR == 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - -namespace helper { namespace internal { - -enum class Size { - UInt8, - UInt16, - UInt32, - UInt64, -}; - -constexpr Size get_size(int s) { - return (s <= 8 ) ? Size::UInt8: - (s <= 16) ? Size::UInt16: - (s <= 32) ? Size::UInt32: Size::UInt64; -} - -template -struct FindTypeH; - -template<> -struct FindTypeH { - using type = std::uint8_t; -}; - -template<> -struct FindTypeH { - using type = std::uint16_t; -}; - -template<> -struct FindTypeH { - using type = std::uint32_t; -}; - -template<> -struct FindTypeH { - using type = std::uint64_t; -}; -} - -template -struct FindType { - using type = typename internal::FindTypeH::type; -}; -} - -#define HelloMsg_max_cdr_typesize 269ULL; - - - - -HelloMsg::HelloMsg() -{ - // unsigned short m_deadlinekey - m_deadlinekey = 0; - // /type_d() m_payload - - -} - -HelloMsg::~HelloMsg() -{ -} - -HelloMsg::HelloMsg( - const HelloMsg& x) -{ - m_deadlinekey = x.m_deadlinekey; - - - m_payload = x.m_payload; - -} - -HelloMsg::HelloMsg( - HelloMsg&& x) noexcept -{ - m_deadlinekey = x.m_deadlinekey; - - - m_payload = std::move(x.m_payload); - -} - -HelloMsg& HelloMsg::operator =( - const HelloMsg& x) -{ - m_deadlinekey = x.m_deadlinekey; - - - m_payload = x.m_payload; - - return *this; -} - -HelloMsg& HelloMsg::operator =( - HelloMsg&& x) noexcept -{ - m_deadlinekey = x.m_deadlinekey; - - - m_payload = std::move(x.m_payload); - - return *this; -} - -bool HelloMsg::operator ==( - const HelloMsg& x) const -{ - return (m_deadlinekey == x.m_deadlinekey && - m_payload == x.m_payload); -} - -bool HelloMsg::operator !=( - const HelloMsg& x) const -{ - return !(*this == x); -} - -size_t HelloMsg::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return HelloMsg_max_cdr_typesize; -} - -size_t HelloMsg::getCdrSerializedSize( - const HelloMsg& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 2 + eprosima::fastcdr::Cdr::alignment(current_alignment, 2); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + data.payload().size() + 1; - - - return current_alignment - initial_alignment; -} - - -void HelloMsg::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_deadlinekey; - - scdr << m_payload.c_str(); - -} - -void HelloMsg::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_deadlinekey; - - - - { - std::string aux; - dcdr >> aux; - m_payload = aux.c_str(); - } - - -} - - -bool HelloMsg::isKeyDefined() -{ - return true; -} - -void HelloMsg::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; - - scdr << m_deadlinekey; - - -} - -/*! - * @brief This function sets a value in member deadlinekey - * @param _deadlinekey New value for member deadlinekey - */ -void HelloMsg::deadlinekey( - uint16_t _deadlinekey) -{ - m_deadlinekey = _deadlinekey; -} - -/*! - * @brief This function returns the value of member deadlinekey - * @return Value of member deadlinekey - */ -uint16_t HelloMsg::deadlinekey() const -{ - return m_deadlinekey; -} - -/*! - * @brief This function returns a reference to member deadlinekey - * @return Reference to member deadlinekey - */ -uint16_t& HelloMsg::deadlinekey() -{ - return m_deadlinekey; -} - - -/*! - * @brief This function copies the value in member payload - * @param _payload New value to be copied in member payload - */ -void HelloMsg::payload( - const eprosima::fastrtps::fixed_string<256>& _payload) -{ - m_payload = _payload; -} - -/*! - * @brief This function moves the value in member payload - * @param _payload New value to be moved in member payload - */ -void HelloMsg::payload( - eprosima::fastrtps::fixed_string<256>&& _payload) -{ - m_payload = std::move(_payload); -} - -/*! - * @brief This function returns a constant reference to member payload - * @return Constant reference to member payload - */ -const eprosima::fastrtps::fixed_string<256>& HelloMsg::payload() const -{ - return m_payload; -} - -/*! - * @brief This function returns a reference to member payload - * @return Reference to member payload - */ -eprosima::fastrtps::fixed_string<256>& HelloMsg::payload() -{ - return m_payload; -} - - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/DeadlineQoSExample/deadlinepayloadv1.h b/examples/cpp/dds/DeadlineQoSExample/deadlinepayloadv1.h deleted file mode 100644 index 1711ff83a06..00000000000 --- a/examples/cpp/dds/DeadlineQoSExample/deadlinepayloadv1.h +++ /dev/null @@ -1,244 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file deadlinepayload.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#include - -#if FASTCDR_VERSION_MAJOR == 1 - -#ifndef _FAST_DDS_GENERATED_DEADLINEPAYLOAD_H_ -#define _FAST_DDS_GENERATED_DEADLINEPAYLOAD_H_ - - -#include - -#include -#include -#include -#include -#include -#include -#include - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define eProsima_user_DllExport -#endif // _WIN32 - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(DEADLINEPAYLOAD_SOURCE) -#define DEADLINEPAYLOAD_DllAPI __declspec( dllexport ) -#else -#define DEADLINEPAYLOAD_DllAPI __declspec( dllimport ) -#endif // DEADLINEPAYLOAD_SOURCE -#else -#define DEADLINEPAYLOAD_DllAPI -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define DEADLINEPAYLOAD_DllAPI -#endif // _WIN32 - -namespace eprosima { -namespace fastcdr { -class Cdr; -} // namespace fastcdr -} // namespace eprosima - - - - - -/*! - * @brief This class represents the structure HelloMsg defined by the user in the IDL file. - * @ingroup deadlinepayload - */ -class HelloMsg -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport HelloMsg(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~HelloMsg(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object HelloMsg that will be copied. - */ - eProsima_user_DllExport HelloMsg( - const HelloMsg& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object HelloMsg that will be copied. - */ - eProsima_user_DllExport HelloMsg( - HelloMsg&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object HelloMsg that will be copied. - */ - eProsima_user_DllExport HelloMsg& operator =( - const HelloMsg& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object HelloMsg that will be copied. - */ - eProsima_user_DllExport HelloMsg& operator =( - HelloMsg&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x HelloMsg object to compare. - */ - eProsima_user_DllExport bool operator ==( - const HelloMsg& x) const; - - /*! - * @brief Comparison operator. - * @param x HelloMsg object to compare. - */ - eProsima_user_DllExport bool operator !=( - const HelloMsg& x) const; - - /*! - * @brief This function sets a value in member deadlinekey - * @param _deadlinekey New value for member deadlinekey - */ - eProsima_user_DllExport void deadlinekey( - uint16_t _deadlinekey); - - /*! - * @brief This function returns the value of member deadlinekey - * @return Value of member deadlinekey - */ - eProsima_user_DllExport uint16_t deadlinekey() const; - - /*! - * @brief This function returns a reference to member deadlinekey - * @return Reference to member deadlinekey - */ - eProsima_user_DllExport uint16_t& deadlinekey(); - - - /*! - * @brief This function copies the value in member payload - * @param _payload New value to be copied in member payload - */ - eProsima_user_DllExport void payload( - const eprosima::fastrtps::fixed_string<256>& _payload); - - /*! - * @brief This function moves the value in member payload - * @param _payload New value to be moved in member payload - */ - eProsima_user_DllExport void payload( - eprosima::fastrtps::fixed_string<256>&& _payload); - - /*! - * @brief This function returns a constant reference to member payload - * @return Constant reference to member payload - */ - eProsima_user_DllExport const eprosima::fastrtps::fixed_string<256>& payload() const; - - /*! - * @brief This function returns a reference to member payload - * @return Reference to member payload - */ - eProsima_user_DllExport eprosima::fastrtps::fixed_string<256>& payload(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const HelloMsg& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - uint16_t m_deadlinekey; - eprosima::fastrtps::fixed_string<256> m_payload; - -}; - - -#endif // _FAST_DDS_GENERATED_DEADLINEPAYLOAD_H_ - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/DeadlineQoSExample/mapableKey.h b/examples/cpp/dds/DeadlineQoSExample/mapableKey.h deleted file mode 100644 index 4b34b059f79..00000000000 --- a/examples/cpp/dds/DeadlineQoSExample/mapableKey.h +++ /dev/null @@ -1,56 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -#ifndef MAPABLEKEY_H_ -#define MAPABLEKEY_H_ - -#include -#include -#include -#include - -#include - -typedef struct ex_mapableKey -{ - - eprosima::fastrtps::rtps::octet value[16]; - - ex_mapableKey& operator =( - const eprosima::fastrtps::rtps::InstanceHandle_t& ihandle) - { - for (uint8_t i = 0; i < 16; i++) - { - value[i] = ihandle.value[i]; - } - return *this; - } - -}mapable_key; - -inline bool operator <( - const ex_mapableKey& ex_mapableKey1, - const ex_mapableKey& ex_mapableKey2) -{ - for (uint8_t i = 0; i < 16; ++i) - { - if (ex_mapableKey1.value[i] < ex_mapableKey2.value[i]) - { - return true; - } - } - return false; -} - -#endif // ifndef MAPABLEKEY_H_ diff --git a/examples/cpp/dds/DisablePositiveACKs/CMakeLists.txt b/examples/cpp/dds/DisablePositiveACKs/CMakeLists.txt index 3dc4e941b59..8ad0336e19a 100644 --- a/examples/cpp/dds/DisablePositiveACKs/CMakeLists.txt +++ b/examples/cpp/dds/DisablePositiveACKs/CMakeLists.txt @@ -21,8 +21,8 @@ if(NOT fastcdr_FOUND) find_package(fastcdr 2 REQUIRED) endif() -if(NOT fastrtps_FOUND) - find_package(fastrtps 2.12 REQUIRED) +if(NOT fastdds_FOUND) + find_package(fastdds 3 REQUIRED) endif() #Check C++11 @@ -44,6 +44,6 @@ target_compile_definitions(DDSDisablePositiveACKs PRIVATE $<$>,$>:__DEBUG> $<$:__INTERNALDEBUG> # Internal debug activated. ) -target_link_libraries(DDSDisablePositiveACKs fastrtps fastcdr) +target_link_libraries(DDSDisablePositiveACKs fastdds fastcdr) install(TARGETS DDSDisablePositiveACKs RUNTIME DESTINATION examples/cpp/dds/DisablePositiveACKs/${BIN_INSTALL_DIR}) diff --git a/examples/cpp/dds/DisablePositiveACKs/DisablePositiveACKS_main.cpp b/examples/cpp/dds/DisablePositiveACKs/DisablePositiveACKS_main.cpp index e4afc17ea12..3ec4fe51f69 100644 --- a/examples/cpp/dds/DisablePositiveACKs/DisablePositiveACKS_main.cpp +++ b/examples/cpp/dds/DisablePositiveACKs/DisablePositiveACKS_main.cpp @@ -20,13 +20,14 @@ #include "DisablePositiveACKsPublisher.h" #include "DisablePositiveACKsSubscriber.h" -#include -#include +#include using namespace eprosima; using namespace fastrtps; using namespace rtps; +using namespace eprosima::fastdds::dds; + /** * @brief Parses command line arguments * @param argc Number of command line arguments @@ -182,7 +183,6 @@ int main( break; } } - Domain::stopAll(); Log::Reset(); return 0; } diff --git a/examples/cpp/dds/DisablePositiveACKs/DisablePositiveACKsPublisher.h b/examples/cpp/dds/DisablePositiveACKs/DisablePositiveACKsPublisher.h index 694f227fec9..8c0aa046795 100644 --- a/examples/cpp/dds/DisablePositiveACKs/DisablePositiveACKsPublisher.h +++ b/examples/cpp/dds/DisablePositiveACKs/DisablePositiveACKsPublisher.h @@ -20,7 +20,7 @@ #ifndef DisablePositiveACKsPublisher_H_ #define DisablePositiveACKsPublisher_H_ -#include "Topic.h" +#include "Topic.hpp" #include "TopicPubSubTypes.h" #include diff --git a/examples/cpp/dds/DisablePositiveACKs/DisablePositiveACKsSubscriber.cpp b/examples/cpp/dds/DisablePositiveACKs/DisablePositiveACKsSubscriber.cpp index 72186e17663..38569a7fb77 100644 --- a/examples/cpp/dds/DisablePositiveACKs/DisablePositiveACKsSubscriber.cpp +++ b/examples/cpp/dds/DisablePositiveACKs/DisablePositiveACKsSubscriber.cpp @@ -129,7 +129,7 @@ void DisablePositiveACKsSubscriber::SubListener::on_data_available( DataReader* reader) { SampleInfo info; - if (reader->take_next_sample(&hello, &info) == ReturnCode_t::RETCODE_OK) + if (reader->take_next_sample(&hello, &info) == RETCODE_OK) { if (info.valid_data) { diff --git a/examples/cpp/dds/DisablePositiveACKs/DisablePositiveACKsSubscriber.h b/examples/cpp/dds/DisablePositiveACKs/DisablePositiveACKsSubscriber.h index 0d383c77717..7423e10579d 100644 --- a/examples/cpp/dds/DisablePositiveACKs/DisablePositiveACKsSubscriber.h +++ b/examples/cpp/dds/DisablePositiveACKs/DisablePositiveACKsSubscriber.h @@ -20,8 +20,8 @@ #ifndef DisablePositiveACKsSubscriber_H_ #define DisablePositiveACKsSubscriber_H_ +#include "Topic.hpp" #include "TopicPubSubTypes.h" -#include "Topic.h" #include #include diff --git a/examples/cpp/dds/DisablePositiveACKs/Topic.cxx b/examples/cpp/dds/DisablePositiveACKs/Topic.cxx deleted file mode 100644 index ca86d176ba1..00000000000 --- a/examples/cpp/dds/DisablePositiveACKs/Topic.cxx +++ /dev/null @@ -1,168 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file Topic.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "Topic.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - - - - -Topic::Topic() -{ -} - -Topic::~Topic() -{ -} - -Topic::Topic( - const Topic& x) -{ - m_index = x.m_index; - m_message = x.m_message; -} - -Topic::Topic( - Topic&& x) noexcept -{ - m_index = x.m_index; - m_message = std::move(x.m_message); -} - -Topic& Topic::operator =( - const Topic& x) -{ - - m_index = x.m_index; - m_message = x.m_message; - return *this; -} - -Topic& Topic::operator =( - Topic&& x) noexcept -{ - - m_index = x.m_index; - m_message = std::move(x.m_message); - return *this; -} - -bool Topic::operator ==( - const Topic& x) const -{ - return (m_index == x.m_index && - m_message == x.m_message); -} - -bool Topic::operator !=( - const Topic& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void Topic::index( - uint32_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint32_t Topic::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint32_t& Topic::index() -{ - return m_index; -} - - -/*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ -void Topic::message( - const std::string& _message) -{ - m_message = _message; -} - -/*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ -void Topic::message( - std::string&& _message) -{ - m_message = std::move(_message); -} - -/*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ -const std::string& Topic::message() const -{ - return m_message; -} - -/*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ -std::string& Topic::message() -{ - return m_message; -} - - -// Include auxiliary functions like for serializing/deserializing. -#include "TopicCdrAux.ipp" - -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/CustomListenerExample/Topic.h b/examples/cpp/dds/DisablePositiveACKs/Topic.hpp similarity index 69% rename from examples/cpp/dds/CustomListenerExample/Topic.h rename to examples/cpp/dds/DisablePositiveACKs/Topic.hpp index 2596f317a1e..8f86884c2b8 100644 --- a/examples/cpp/dds/CustomListenerExample/Topic.h +++ b/examples/cpp/dds/DisablePositiveACKs/Topic.hpp @@ -13,32 +13,19 @@ // limitations under the License. /*! - * @file Topic.h + * @file Topic.hpp * This header file contains the declaration of the described types in the IDL file. * * This file was generated by the tool fastddsgen. */ -#include -#include "Topicv1.h" +#ifndef _FAST_DDS_GENERATED_TOPIC_HPP_ +#define _FAST_DDS_GENERATED_TOPIC_HPP_ -#if FASTCDR_VERSION_MAJOR > 1 - -#ifndef _FAST_DDS_GENERATED_TOPIC_H_ -#define _FAST_DDS_GENERATED_TOPIC_H_ - -#include -#include #include -#include #include -#include - +#include #include -#include -#include - - #if defined(_WIN32) #if defined(EPROSIMA_USER_DLL_EXPORT) @@ -64,17 +51,6 @@ #define TOPIC_DllAPI #endif // _WIN32 -namespace eprosima { -namespace fastcdr { -class Cdr; -class CdrSizeCalculator; -} // namespace fastcdr -} // namespace eprosima - - - - - /*! * @brief This class represents the structure Topic defined by the user in the IDL file. * @ingroup Topic @@ -86,73 +62,117 @@ class Topic /*! * @brief Default constructor. */ - eProsima_user_DllExport Topic(); + eProsima_user_DllExport Topic() + { + } /*! * @brief Default destructor. */ - eProsima_user_DllExport ~Topic(); + eProsima_user_DllExport ~Topic() + { + } /*! * @brief Copy constructor. * @param x Reference to the object Topic that will be copied. */ eProsima_user_DllExport Topic( - const Topic& x); + const Topic& x) + { + m_index = x.m_index; + + m_message = x.m_message; + + } /*! * @brief Move constructor. * @param x Reference to the object Topic that will be copied. */ eProsima_user_DllExport Topic( - Topic&& x) noexcept; + Topic&& x) noexcept + { + m_index = x.m_index; + m_message = std::move(x.m_message); + } /*! * @brief Copy assignment. * @param x Reference to the object Topic that will be copied. */ eProsima_user_DllExport Topic& operator =( - const Topic& x); + const Topic& x) + { + + m_index = x.m_index; + + m_message = x.m_message; + + return *this; + } /*! * @brief Move assignment. * @param x Reference to the object Topic that will be copied. */ eProsima_user_DllExport Topic& operator =( - Topic&& x) noexcept; + Topic&& x) noexcept + { + + m_index = x.m_index; + m_message = std::move(x.m_message); + return *this; + } /*! * @brief Comparison operator. * @param x Topic object to compare. */ eProsima_user_DllExport bool operator ==( - const Topic& x) const; + const Topic& x) const + { + return (m_index == x.m_index && + m_message == x.m_message); + } /*! * @brief Comparison operator. * @param x Topic object to compare. */ eProsima_user_DllExport bool operator !=( - const Topic& x) const; + const Topic& x) const + { + return !(*this == x); + } /*! * @brief This function sets a value in member index * @param _index New value for member index */ eProsima_user_DllExport void index( - uint32_t _index); + uint32_t _index) + { + m_index = _index; + } /*! * @brief This function returns the value of member index * @return Value of member index */ - eProsima_user_DllExport uint32_t index() const; + eProsima_user_DllExport uint32_t index() const + { + return m_index; + } /*! * @brief This function returns a reference to member index * @return Reference to member index */ - eProsima_user_DllExport uint32_t& index(); + eProsima_user_DllExport uint32_t& index() + { + return m_index; + } /*! @@ -160,26 +180,40 @@ class Topic * @param _message New value to be copied in member message */ eProsima_user_DllExport void message( - const std::string& _message); + const std::string& _message) + { + m_message = _message; + } /*! * @brief This function moves the value in member message * @param _message New value to be moved in member message */ eProsima_user_DllExport void message( - std::string&& _message); + std::string&& _message) + { + m_message = std::move(_message); + } /*! * @brief This function returns a constant reference to member message * @return Constant reference to member message */ - eProsima_user_DllExport const std::string& message() const; + eProsima_user_DllExport const std::string& message() const + { + return m_message; + } /*! * @brief This function returns a reference to member message * @return Reference to member message */ - eProsima_user_DllExport std::string& message(); + eProsima_user_DllExport std::string& message() + { + return m_message; + } + + private: @@ -188,8 +222,6 @@ class Topic }; -#endif // _FAST_DDS_GENERATED_TOPIC_H_ - +#endif // _FAST_DDS_GENERATED_TOPIC_HPP_ -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/DisablePositiveACKs/TopicCdrAux.hpp b/examples/cpp/dds/DisablePositiveACKs/TopicCdrAux.hpp index 619cdbbb7b8..7b60c44c7b4 100644 --- a/examples/cpp/dds/DisablePositiveACKs/TopicCdrAux.hpp +++ b/examples/cpp/dds/DisablePositiveACKs/TopicCdrAux.hpp @@ -22,7 +22,7 @@ #ifndef _FAST_DDS_GENERATED_TOPICCDRAUX_HPP_ #define _FAST_DDS_GENERATED_TOPICCDRAUX_HPP_ -#include "Topic.h" +#include "Topic.hpp" constexpr uint32_t Topic_max_cdr_typesize {268UL}; constexpr uint32_t Topic_max_key_cdr_typesize {0UL}; @@ -34,8 +34,6 @@ namespace fastcdr { class Cdr; class CdrSizeCalculator; - - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const Topic& data); diff --git a/examples/cpp/dds/DisablePositiveACKs/TopicCdrAux.ipp b/examples/cpp/dds/DisablePositiveACKs/TopicCdrAux.ipp index ac5a8c39ef9..37570c8a6b2 100644 --- a/examples/cpp/dds/DisablePositiveACKs/TopicCdrAux.ipp +++ b/examples/cpp/dds/DisablePositiveACKs/TopicCdrAux.ipp @@ -34,8 +34,6 @@ using namespace eprosima::fastcdr::exception; namespace eprosima { namespace fastcdr { - - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, diff --git a/examples/cpp/dds/DisablePositiveACKs/TopicPubSubTypes.cxx b/examples/cpp/dds/DisablePositiveACKs/TopicPubSubTypes.cxx index ce688064a0e..8d6d0b195c9 100644 --- a/examples/cpp/dds/DisablePositiveACKs/TopicPubSubTypes.cxx +++ b/examples/cpp/dds/DisablePositiveACKs/TopicPubSubTypes.cxx @@ -19,18 +19,18 @@ * This file was generated by the tool fastddsgen. */ +#include "TopicPubSubTypes.h" +#include #include -#include "TopicPubSubTypes.h" #include "TopicCdrAux.hpp" +#include "TopicTypeObjectSupport.hpp" using SerializedPayload_t = eprosima::fastrtps::rtps::SerializedPayload_t; using InstanceHandle_t = eprosima::fastrtps::rtps::InstanceHandle_t; using DataRepresentationId_t = eprosima::fastdds::dds::DataRepresentationId_t; - - TopicPubSubType::TopicPubSubType() { setName("Topic"); @@ -219,3 +219,11 @@ bool TopicPubSubType::getKey( return true; } +void TopicPubSubType::register_type_object_representation() const +{ + register_Topic_type_objects(); +} + + +// Include auxiliary functions like for serializing/deserializing. +#include "TopicCdrAux.ipp" diff --git a/examples/cpp/dds/DisablePositiveACKs/TopicPubSubTypes.h b/examples/cpp/dds/DisablePositiveACKs/TopicPubSubTypes.h index b9100bacbe9..0b37b3746f3 100644 --- a/examples/cpp/dds/DisablePositiveACKs/TopicPubSubTypes.h +++ b/examples/cpp/dds/DisablePositiveACKs/TopicPubSubTypes.h @@ -27,9 +27,9 @@ #include #include #include -#include +#include -#include "Topic.h" +#include "Topic.hpp" #if !defined(GEN_API_VER) || (GEN_API_VER != 2) @@ -38,8 +38,6 @@ #endif // GEN_API_VER - - /*! * @brief This class represents the TopicDataType of the type Topic defined by the user in the IDL file. * @ingroup Topic @@ -90,6 +88,9 @@ class TopicPubSubType : public eprosima::fastdds::dds::TopicDataType eProsima_user_DllExport void deleteData( void* data) override; + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + #ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED eProsima_user_DllExport inline bool is_bounded() const override { diff --git a/examples/cpp/dds/DisablePositiveACKs/TopicTypeObjectSupport.cxx b/examples/cpp/dds/DisablePositiveACKs/TopicTypeObjectSupport.cxx new file mode 100644 index 00000000000..067fd08a822 --- /dev/null +++ b/examples/cpp/dds/DisablePositiveACKs/TopicTypeObjectSupport.cxx @@ -0,0 +1,248 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file TopicTypeObjectSupport.cxx + * Source file containing the implementation to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#include "TopicTypeObjectSupport.hpp" + +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include + +#include "Topic.hpp" + + +using namespace eprosima::fastdds::dds::xtypes; + +void register_Topic_type_objects() +{ + static std::once_flag once_flag; + std::call_once(once_flag, []() + { + register_Topic_type_identifier(); + + }); +} + +void register_Topic_type_identifier() +{ + { + StructTypeFlag struct_flags_Topic = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::NOT_APPLIED, + false, false); + ReturnCode_t return_code_Topic; + TypeIdentifierPair type_ids_Topic; + QualifiedTypeName type_name_Topic = "Topic"; + eprosima::fastcdr::optional type_ann_builtin_Topic; + eprosima::fastcdr::optional ann_custom_Topic; + CompleteTypeDetail detail_Topic = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_Topic, ann_custom_Topic, type_name_Topic.to_string()); + CompleteStructHeader header_Topic; + header_Topic = TypeObjectUtils::build_complete_struct_header(TypeIdentifier(), detail_Topic); + CompleteStructMemberSeq member_seq_Topic; + { + return_code_Topic = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_uint32_t", type_ids_Topic); + + if (return_code_Topic != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "index Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_index = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_index; + MemberId member_id_index = 0x00000000; + if (EK_COMPLETE == type_ids_Topic.type_identifier1()._d() || TK_NONE == type_ids_Topic.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_Topic.type_identifier1()._d() && + EK_COMPLETE == type_ids_Topic.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_Topic.type_identifier1()._d() && + EK_COMPLETE == type_ids_Topic.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_Topic.type_identifier1()._d() && + EK_COMPLETE == type_ids_Topic.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_Topic.type_identifier1()._d() && + EK_COMPLETE == type_ids_Topic.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_Topic.type_identifier1()._d() && + (EK_COMPLETE == type_ids_Topic.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_Topic.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_Topic.type_identifier1()._d() && + (EK_COMPLETE == type_ids_Topic.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_Topic.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_Topic.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_Topic.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_Topic.type_identifier2()._d() && + EK_COMPLETE == type_ids_Topic.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_Topic.type_identifier2()._d() && + EK_COMPLETE == type_ids_Topic.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_Topic.type_identifier2()._d() && + EK_COMPLETE == type_ids_Topic.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_Topic.type_identifier2()._d() && + EK_COMPLETE == type_ids_Topic.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_Topic.type_identifier2()._d() && + (EK_COMPLETE == type_ids_Topic.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_Topic.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_Topic.type_identifier2()._d() && + (EK_COMPLETE == type_ids_Topic.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_Topic.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_Topic.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure index member TypeIdentifier inconsistent."); + return; + } + MemberName name_index = "index"; + eprosima::fastcdr::optional member_ann_builtin_index; + ann_custom_Topic.reset(); + CompleteMemberDetail detail_index = TypeObjectUtils::build_complete_member_detail(name_index, member_ann_builtin_index, ann_custom_Topic); + CompleteStructMember member_index = TypeObjectUtils::build_complete_struct_member(common_index, detail_index); + TypeObjectUtils::add_complete_struct_member(member_seq_Topic, member_index); + } + { + return_code_Topic = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_string_unbounded", type_ids_Topic); + + if (return_code_Topic != eprosima::fastdds::dds::RETCODE_OK) + { + std::string type_id_kind_anonymous_string_unbounded("TI_STRING8_SMALL"); + if (type_id_kind_anonymous_string_unbounded == "TI_STRING8_SMALL") + { + SBound bound = 0; + StringSTypeDefn string_sdefn = TypeObjectUtils::build_string_s_type_defn(bound); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_string_type_identifier(string_sdefn, + "anonymous_string_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else if (type_id_kind_anonymous_string_unbounded == "TI_STRING8_LARGE") + { + LBound bound = 255; + StringLTypeDefn string_ldefn = TypeObjectUtils::build_string_l_type_defn(bound); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_string_type_identifier(string_ldefn, + "anonymous_string_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded: Unknown String kind."); + return; + } + return_code_Topic = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_string_unbounded", type_ids_Topic); + if (return_code_Topic != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded: Given String TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_message = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_message; + MemberId member_id_message = 0x00000001; + if (EK_COMPLETE == type_ids_Topic.type_identifier1()._d() || TK_NONE == type_ids_Topic.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_Topic.type_identifier1()._d() && + EK_COMPLETE == type_ids_Topic.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_Topic.type_identifier1()._d() && + EK_COMPLETE == type_ids_Topic.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_Topic.type_identifier1()._d() && + EK_COMPLETE == type_ids_Topic.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_Topic.type_identifier1()._d() && + EK_COMPLETE == type_ids_Topic.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_Topic.type_identifier1()._d() && + (EK_COMPLETE == type_ids_Topic.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_Topic.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_Topic.type_identifier1()._d() && + (EK_COMPLETE == type_ids_Topic.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_Topic.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_message = TypeObjectUtils::build_common_struct_member(member_id_message, member_flags_message, type_ids_Topic.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_Topic.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_Topic.type_identifier2()._d() && + EK_COMPLETE == type_ids_Topic.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_Topic.type_identifier2()._d() && + EK_COMPLETE == type_ids_Topic.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_Topic.type_identifier2()._d() && + EK_COMPLETE == type_ids_Topic.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_Topic.type_identifier2()._d() && + EK_COMPLETE == type_ids_Topic.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_Topic.type_identifier2()._d() && + (EK_COMPLETE == type_ids_Topic.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_Topic.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_Topic.type_identifier2()._d() && + (EK_COMPLETE == type_ids_Topic.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_Topic.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_message = TypeObjectUtils::build_common_struct_member(member_id_message, member_flags_message, type_ids_Topic.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure message member TypeIdentifier inconsistent."); + return; + } + MemberName name_message = "message"; + eprosima::fastcdr::optional member_ann_builtin_message; + ann_custom_Topic.reset(); + CompleteMemberDetail detail_message = TypeObjectUtils::build_complete_member_detail(name_message, member_ann_builtin_message, ann_custom_Topic); + CompleteStructMember member_message = TypeObjectUtils::build_complete_struct_member(common_message, detail_message); + TypeObjectUtils::add_complete_struct_member(member_seq_Topic, member_message); + } + CompleteStructType struct_type_Topic = TypeObjectUtils::build_complete_struct_type(struct_flags_Topic, header_Topic, member_seq_Topic); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_struct_type_object(struct_type_Topic, type_name_Topic.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Topic already registered in TypeObjectRegistry for a different type."); + } + return_code_Topic = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "Topic", type_ids_Topic); + if (return_code_Topic != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Topic: Given Struct TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } +} + diff --git a/examples/cpp/dds/DisablePositiveACKs/TopicTypeObjectSupport.hpp b/examples/cpp/dds/DisablePositiveACKs/TopicTypeObjectSupport.hpp new file mode 100644 index 00000000000..f0576f9b948 --- /dev/null +++ b/examples/cpp/dds/DisablePositiveACKs/TopicTypeObjectSupport.hpp @@ -0,0 +1,54 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file TopicTypeObjectSupport.hpp + * Header file containing the API required to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#ifndef _FAST_DDS_GENERATED_TOPIC_TYPE_OBJECT_SUPPORT_HPP_ +#define _FAST_DDS_GENERATED_TOPIC_TYPE_OBJECT_SUPPORT_HPP_ + + +#if defined(_WIN32) +#if defined(EPROSIMA_USER_DLL_EXPORT) +#define eProsima_user_DllExport __declspec( dllexport ) +#else +#define eProsima_user_DllExport +#endif // EPROSIMA_USER_DLL_EXPORT +#else +#define eProsima_user_DllExport +#endif // _WIN32 + +/** + * @brief Register every TypeObject representation defined in the IDL file in Fast DDS TypeObjectRegistry. + */ +eProsima_user_DllExport void register_Topic_type_objects(); + +#ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +/** + * @brief Register Topic related TypeIdentifier. + * Fully-descriptive TypeIdentifiers are directly registered. + * Hash TypeIdentifiers require to fill the TypeObject information and hash it, consequently, the TypeObject is + * indirectly registered as well. + */ +void register_Topic_type_identifier(); + + +#endif // DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +#endif // _FAST_DDS_GENERATED_TOPIC_TYPE_OBJECT_SUPPORT_HPP_ diff --git a/examples/cpp/dds/DisablePositiveACKs/Topicv1.cxx b/examples/cpp/dds/DisablePositiveACKs/Topicv1.cxx deleted file mode 100644 index a3e85584242..00000000000 --- a/examples/cpp/dds/DisablePositiveACKs/Topicv1.cxx +++ /dev/null @@ -1,286 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file Topic.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "Topic.h" - -#if FASTCDR_VERSION_MAJOR == 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - -namespace helper { namespace internal { - -enum class Size { - UInt8, - UInt16, - UInt32, - UInt64, -}; - -constexpr Size get_size(int s) { - return (s <= 8 ) ? Size::UInt8: - (s <= 16) ? Size::UInt16: - (s <= 32) ? Size::UInt32: Size::UInt64; -} - -template -struct FindTypeH; - -template<> -struct FindTypeH { - using type = std::uint8_t; -}; - -template<> -struct FindTypeH { - using type = std::uint16_t; -}; - -template<> -struct FindTypeH { - using type = std::uint32_t; -}; - -template<> -struct FindTypeH { - using type = std::uint64_t; -}; -} - -template -struct FindType { - using type = typename internal::FindTypeH::type; -}; -} - -#define Topic_max_cdr_typesize 268ULL; - - - - -Topic::Topic() -{ - // unsigned long m_index - m_index = 0; - // /type_d() m_message - - -} - -Topic::~Topic() -{ -} - -Topic::Topic( - const Topic& x) -{ - m_index = x.m_index; - - - m_message = x.m_message; - -} - -Topic::Topic( - Topic&& x) noexcept -{ - m_index = x.m_index; - - - m_message = std::move(x.m_message); - -} - -Topic& Topic::operator =( - const Topic& x) -{ - m_index = x.m_index; - - - m_message = x.m_message; - - return *this; -} - -Topic& Topic::operator =( - Topic&& x) noexcept -{ - m_index = x.m_index; - - - m_message = std::move(x.m_message); - - return *this; -} - -bool Topic::operator ==( - const Topic& x) const -{ - return (m_index == x.m_index && - m_message == x.m_message); -} - -bool Topic::operator !=( - const Topic& x) const -{ - return !(*this == x); -} - -size_t Topic::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return Topic_max_cdr_typesize; -} - -size_t Topic::getCdrSerializedSize( - const Topic& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + data.message().size() + 1; - - - return current_alignment - initial_alignment; -} - - -void Topic::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_index; - - scdr << m_message.c_str(); - -} - -void Topic::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_index; - - - - dcdr >> m_message; - - -} - - -bool Topic::isKeyDefined() -{ - return false; -} - -void Topic::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void Topic::index( - uint32_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint32_t Topic::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint32_t& Topic::index() -{ - return m_index; -} - - -/*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ -void Topic::message( - const std::string& _message) -{ - m_message = _message; -} - -/*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ -void Topic::message( - std::string&& _message) -{ - m_message = std::move(_message); -} - -/*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ -const std::string& Topic::message() const -{ - return m_message; -} - -/*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ -std::string& Topic::message() -{ - return m_message; -} - - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/DisablePositiveACKs/Topicv1.h b/examples/cpp/dds/DisablePositiveACKs/Topicv1.h deleted file mode 100644 index e06f22b7e2b..00000000000 --- a/examples/cpp/dds/DisablePositiveACKs/Topicv1.h +++ /dev/null @@ -1,244 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file Topic.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#include - -#if FASTCDR_VERSION_MAJOR == 1 - -#ifndef _FAST_DDS_GENERATED_TOPIC_H_ -#define _FAST_DDS_GENERATED_TOPIC_H_ - - -#include - -#include -#include -#include -#include -#include -#include -#include - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define eProsima_user_DllExport -#endif // _WIN32 - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(TOPIC_SOURCE) -#define TOPIC_DllAPI __declspec( dllexport ) -#else -#define TOPIC_DllAPI __declspec( dllimport ) -#endif // TOPIC_SOURCE -#else -#define TOPIC_DllAPI -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define TOPIC_DllAPI -#endif // _WIN32 - -namespace eprosima { -namespace fastcdr { -class Cdr; -} // namespace fastcdr -} // namespace eprosima - - - - - -/*! - * @brief This class represents the structure Topic defined by the user in the IDL file. - * @ingroup Topic - */ -class Topic -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport Topic(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~Topic(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object Topic that will be copied. - */ - eProsima_user_DllExport Topic( - const Topic& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object Topic that will be copied. - */ - eProsima_user_DllExport Topic( - Topic&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object Topic that will be copied. - */ - eProsima_user_DllExport Topic& operator =( - const Topic& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object Topic that will be copied. - */ - eProsima_user_DllExport Topic& operator =( - Topic&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x Topic object to compare. - */ - eProsima_user_DllExport bool operator ==( - const Topic& x) const; - - /*! - * @brief Comparison operator. - * @param x Topic object to compare. - */ - eProsima_user_DllExport bool operator !=( - const Topic& x) const; - - /*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ - eProsima_user_DllExport void index( - uint32_t _index); - - /*! - * @brief This function returns the value of member index - * @return Value of member index - */ - eProsima_user_DllExport uint32_t index() const; - - /*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ - eProsima_user_DllExport uint32_t& index(); - - - /*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ - eProsima_user_DllExport void message( - const std::string& _message); - - /*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ - eProsima_user_DllExport void message( - std::string&& _message); - - /*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ - eProsima_user_DllExport const std::string& message() const; - - /*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ - eProsima_user_DllExport std::string& message(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const Topic& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - uint32_t m_index; - std::string m_message; - -}; - - -#endif // _FAST_DDS_GENERATED_TOPIC_H_ - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/DiscoveryServerExample/CMakeLists.txt b/examples/cpp/dds/DiscoveryServerExample/CMakeLists.txt index 5c09eaaad0f..035ff741189 100644 --- a/examples/cpp/dds/DiscoveryServerExample/CMakeLists.txt +++ b/examples/cpp/dds/DiscoveryServerExample/CMakeLists.txt @@ -21,8 +21,8 @@ if(NOT fastcdr_FOUND) find_package(fastcdr 2 REQUIRED) endif() -if(NOT fastrtps_FOUND) - find_package(fastrtps 2.12 REQUIRED) +if(NOT fastdds_FOUND) + find_package(fastdds 3 REQUIRED) endif() #Check C++11 @@ -44,6 +44,6 @@ target_compile_definitions(${PROJECT_NAME} PRIVATE $<$>,$>:__DEBUG> $<$:__INTERNALDEBUG> # Internal debug activated. ) -target_link_libraries(${PROJECT_NAME} fastrtps fastcdr fastdds::optionparser) +target_link_libraries(${PROJECT_NAME} fastdds fastcdr fastdds::optionparser) install(TARGETS ${PROJECT_NAME} RUNTIME DESTINATION examples/cpp/dds/${PROJECT_NAME}/${BIN_INSTALL_DIR}) diff --git a/examples/cpp/dds/DiscoveryServerExample/DiscoveryServerPublisher.cpp b/examples/cpp/dds/DiscoveryServerExample/DiscoveryServerPublisher.cpp index 32c6770f1a5..d3063562aad 100644 --- a/examples/cpp/dds/DiscoveryServerExample/DiscoveryServerPublisher.cpp +++ b/examples/cpp/dds/DiscoveryServerExample/DiscoveryServerPublisher.cpp @@ -17,6 +17,8 @@ * */ +#include "DiscoveryServerPublisher.h" + #include #include @@ -30,11 +32,7 @@ #include #include #include -#include -#include -#include - -#include "DiscoveryServerPublisher.h" +#include using namespace eprosima::fastdds::dds; using namespace eprosima::fastdds::rtps; @@ -257,8 +255,10 @@ void HelloWorldPublisher::PubListener::on_publication_matched( void HelloWorldPublisher::PubListener::on_participant_discovery( eprosima::fastdds::dds::DomainParticipant* /*participant*/, - eprosima::fastrtps::rtps::ParticipantDiscoveryInfo&& info) + eprosima::fastrtps::rtps::ParticipantDiscoveryInfo&& info, + bool& should_be_ignored) { + static_cast(should_be_ignored); if (info.status == eprosima::fastrtps::rtps::ParticipantDiscoveryInfo::DISCOVERED_PARTICIPANT) { std::cout << "Discovered Participant with GUID " << info.info.m_guid << std::endl; diff --git a/examples/cpp/dds/DiscoveryServerExample/DiscoveryServerPublisher.h b/examples/cpp/dds/DiscoveryServerExample/DiscoveryServerPublisher.h index 82bbfd6ee47..2ddb09baba9 100644 --- a/examples/cpp/dds/DiscoveryServerExample/DiscoveryServerPublisher.h +++ b/examples/cpp/dds/DiscoveryServerExample/DiscoveryServerPublisher.h @@ -101,7 +101,8 @@ class HelloWorldPublisher //! Callback executed when a DomainParticipant is discovered, dropped or removed void on_participant_discovery( eprosima::fastdds::dds::DomainParticipant* /*participant*/, - eprosima::fastrtps::rtps::ParticipantDiscoveryInfo&& info) override; + eprosima::fastrtps::rtps::ParticipantDiscoveryInfo&& info, + bool& should_be_ignored) override; private: diff --git a/examples/cpp/dds/DiscoveryServerExample/DiscoveryServerServer.cpp b/examples/cpp/dds/DiscoveryServerExample/DiscoveryServerServer.cpp index 7b71826790d..4992b318014 100644 --- a/examples/cpp/dds/DiscoveryServerExample/DiscoveryServerServer.cpp +++ b/examples/cpp/dds/DiscoveryServerExample/DiscoveryServerServer.cpp @@ -17,6 +17,8 @@ * */ +#include "DiscoveryServerServer.h" + #include #include #include @@ -24,13 +26,10 @@ #include #include -#include -#include #include #include -#include - -#include "DiscoveryServerServer.h" +#include +#include using namespace eprosima::fastdds::dds; using namespace eprosima::fastdds::rtps; @@ -251,8 +250,10 @@ DiscoveryServer::~DiscoveryServer() void DiscoveryServer::ServerListener::on_participant_discovery( eprosima::fastdds::dds::DomainParticipant* /*participant*/, - eprosima::fastrtps::rtps::ParticipantDiscoveryInfo&& info) + eprosima::fastrtps::rtps::ParticipantDiscoveryInfo&& info, + bool& should_be_ignored) { + static_cast(should_be_ignored); if (info.status == eprosima::fastrtps::rtps::ParticipantDiscoveryInfo::DISCOVERED_PARTICIPANT) { std::cout << "Discovered Participant with GUID " << info.info.m_guid << std::endl; diff --git a/examples/cpp/dds/DiscoveryServerExample/DiscoveryServerServer.h b/examples/cpp/dds/DiscoveryServerExample/DiscoveryServerServer.h index 566dd904826..8b96f66a26f 100644 --- a/examples/cpp/dds/DiscoveryServerExample/DiscoveryServerServer.h +++ b/examples/cpp/dds/DiscoveryServerExample/DiscoveryServerServer.h @@ -83,7 +83,8 @@ class DiscoveryServer //! Callback executed when a DomainParticipant is discovered, dropped or removed void on_participant_discovery( eprosima::fastdds::dds::DomainParticipant* /*participant*/, - eprosima::fastrtps::rtps::ParticipantDiscoveryInfo&& info) override; + eprosima::fastrtps::rtps::ParticipantDiscoveryInfo&& info, + bool& should_be_ignored) override; private: diff --git a/examples/cpp/dds/DiscoveryServerExample/DiscoveryServerSubscriber.cpp b/examples/cpp/dds/DiscoveryServerExample/DiscoveryServerSubscriber.cpp index 9051bac5b5f..b3d65084678 100644 --- a/examples/cpp/dds/DiscoveryServerExample/DiscoveryServerSubscriber.cpp +++ b/examples/cpp/dds/DiscoveryServerExample/DiscoveryServerSubscriber.cpp @@ -17,6 +17,8 @@ * */ +#include "DiscoveryServerSubscriber.h" + #include #include #include @@ -27,15 +29,11 @@ #include #include #include -#include -#include #include #include -#include -#include -#include - -#include "DiscoveryServerSubscriber.h" +#include +#include +#include using namespace eprosima::fastdds::dds; using namespace eprosima::fastdds::rtps; @@ -277,7 +275,7 @@ void HelloWorldSubscriber::SubListener::on_data_available( DataReader* reader) { SampleInfo info; - while ((reader->take_next_sample(&hello_, &info) == ReturnCode_t::RETCODE_OK) && !is_stopped()) + while ((reader->take_next_sample(&hello_, &info) == RETCODE_OK) && !is_stopped()) { if (info.instance_state == ALIVE_INSTANCE_STATE) { @@ -294,8 +292,10 @@ void HelloWorldSubscriber::SubListener::on_data_available( void HelloWorldSubscriber::SubListener::on_participant_discovery( eprosima::fastdds::dds::DomainParticipant* /*participant*/, - eprosima::fastrtps::rtps::ParticipantDiscoveryInfo&& info) + eprosima::fastrtps::rtps::ParticipantDiscoveryInfo&& info, + bool& should_be_ignored) { + static_cast(should_be_ignored); if (info.status == eprosima::fastrtps::rtps::ParticipantDiscoveryInfo::DISCOVERED_PARTICIPANT) { std::cout << "Discovered Participant with GUID " << info.info.m_guid << std::endl; diff --git a/examples/cpp/dds/DiscoveryServerExample/DiscoveryServerSubscriber.h b/examples/cpp/dds/DiscoveryServerExample/DiscoveryServerSubscriber.h index 21cfed4832f..44e6066bd53 100644 --- a/examples/cpp/dds/DiscoveryServerExample/DiscoveryServerSubscriber.h +++ b/examples/cpp/dds/DiscoveryServerExample/DiscoveryServerSubscriber.h @@ -108,7 +108,8 @@ class HelloWorldSubscriber //! Callback executed when a DomainParticipant is discovered, dropped or removed void on_participant_discovery( eprosima::fastdds::dds::DomainParticipant* /*participant*/, - eprosima::fastrtps::rtps::ParticipantDiscoveryInfo&& info) override; + eprosima::fastrtps::rtps::ParticipantDiscoveryInfo&& info, + bool& should_be_ignored) override; private: diff --git a/examples/cpp/dds/DiscoveryServerExample/arg_configuration.h b/examples/cpp/dds/DiscoveryServerExample/arg_configuration.h index 29f1acdd40f..411ef048a33 100644 --- a/examples/cpp/dds/DiscoveryServerExample/arg_configuration.h +++ b/examples/cpp/dds/DiscoveryServerExample/arg_configuration.h @@ -25,7 +25,7 @@ #include #include -#include +#include #include "common.h" diff --git a/examples/cpp/dds/DiscoveryServerExample/common.h b/examples/cpp/dds/DiscoveryServerExample/common.h index 5ef51a62ff4..24bdf99aa6b 100644 --- a/examples/cpp/dds/DiscoveryServerExample/common.h +++ b/examples/cpp/dds/DiscoveryServerExample/common.h @@ -21,7 +21,7 @@ #define _EPROSIMA_FASTDDS_EXAMPLES_CPP_DDS_DISCOVERYSERVEREXAMPLE_COMMON_H_ #include -#include +#include enum class TransportKind { diff --git a/examples/cpp/dds/DiscoveryServerExample/types/HelloWorld.cxx b/examples/cpp/dds/DiscoveryServerExample/types/HelloWorld.cxx deleted file mode 100644 index 4b415d67769..00000000000 --- a/examples/cpp/dds/DiscoveryServerExample/types/HelloWorld.cxx +++ /dev/null @@ -1,168 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file HelloWorld.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "HelloWorld.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - - - - -HelloWorld::HelloWorld() -{ -} - -HelloWorld::~HelloWorld() -{ -} - -HelloWorld::HelloWorld( - const HelloWorld& x) -{ - m_index = x.m_index; - m_message = x.m_message; -} - -HelloWorld::HelloWorld( - HelloWorld&& x) noexcept -{ - m_index = x.m_index; - m_message = std::move(x.m_message); -} - -HelloWorld& HelloWorld::operator =( - const HelloWorld& x) -{ - - m_index = x.m_index; - m_message = x.m_message; - return *this; -} - -HelloWorld& HelloWorld::operator =( - HelloWorld&& x) noexcept -{ - - m_index = x.m_index; - m_message = std::move(x.m_message); - return *this; -} - -bool HelloWorld::operator ==( - const HelloWorld& x) const -{ - return (m_index == x.m_index && - m_message == x.m_message); -} - -bool HelloWorld::operator !=( - const HelloWorld& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void HelloWorld::index( - uint32_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint32_t HelloWorld::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint32_t& HelloWorld::index() -{ - return m_index; -} - - -/*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ -void HelloWorld::message( - const std::string& _message) -{ - m_message = _message; -} - -/*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ -void HelloWorld::message( - std::string&& _message) -{ - m_message = std::move(_message); -} - -/*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ -const std::string& HelloWorld::message() const -{ - return m_message; -} - -/*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ -std::string& HelloWorld::message() -{ - return m_message; -} - - -// Include auxiliary functions like for serializing/deserializing. -#include "HelloWorldCdrAux.ipp" - -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/DiscoveryServerExample/types/HelloWorld.h b/examples/cpp/dds/DiscoveryServerExample/types/HelloWorld.hpp similarity index 69% rename from examples/cpp/dds/DiscoveryServerExample/types/HelloWorld.h rename to examples/cpp/dds/DiscoveryServerExample/types/HelloWorld.hpp index 5cd0ddba511..971fea8d920 100644 --- a/examples/cpp/dds/DiscoveryServerExample/types/HelloWorld.h +++ b/examples/cpp/dds/DiscoveryServerExample/types/HelloWorld.hpp @@ -13,32 +13,19 @@ // limitations under the License. /*! - * @file HelloWorld.h + * @file HelloWorld.hpp * This header file contains the declaration of the described types in the IDL file. * * This file was generated by the tool fastddsgen. */ -#include -#include "HelloWorldv1.h" +#ifndef _FAST_DDS_GENERATED_HELLOWORLD_HPP_ +#define _FAST_DDS_GENERATED_HELLOWORLD_HPP_ -#if FASTCDR_VERSION_MAJOR > 1 - -#ifndef _FAST_DDS_GENERATED_HELLOWORLD_H_ -#define _FAST_DDS_GENERATED_HELLOWORLD_H_ - -#include -#include #include -#include #include -#include - +#include #include -#include -#include - - #if defined(_WIN32) #if defined(EPROSIMA_USER_DLL_EXPORT) @@ -64,17 +51,6 @@ #define HELLOWORLD_DllAPI #endif // _WIN32 -namespace eprosima { -namespace fastcdr { -class Cdr; -class CdrSizeCalculator; -} // namespace fastcdr -} // namespace eprosima - - - - - /*! * @brief This class represents the structure HelloWorld defined by the user in the IDL file. * @ingroup HelloWorld @@ -86,73 +62,117 @@ class HelloWorld /*! * @brief Default constructor. */ - eProsima_user_DllExport HelloWorld(); + eProsima_user_DllExport HelloWorld() + { + } /*! * @brief Default destructor. */ - eProsima_user_DllExport ~HelloWorld(); + eProsima_user_DllExport ~HelloWorld() + { + } /*! * @brief Copy constructor. * @param x Reference to the object HelloWorld that will be copied. */ eProsima_user_DllExport HelloWorld( - const HelloWorld& x); + const HelloWorld& x) + { + m_index = x.m_index; + + m_message = x.m_message; + + } /*! * @brief Move constructor. * @param x Reference to the object HelloWorld that will be copied. */ eProsima_user_DllExport HelloWorld( - HelloWorld&& x) noexcept; + HelloWorld&& x) noexcept + { + m_index = x.m_index; + m_message = std::move(x.m_message); + } /*! * @brief Copy assignment. * @param x Reference to the object HelloWorld that will be copied. */ eProsima_user_DllExport HelloWorld& operator =( - const HelloWorld& x); + const HelloWorld& x) + { + + m_index = x.m_index; + + m_message = x.m_message; + + return *this; + } /*! * @brief Move assignment. * @param x Reference to the object HelloWorld that will be copied. */ eProsima_user_DllExport HelloWorld& operator =( - HelloWorld&& x) noexcept; + HelloWorld&& x) noexcept + { + + m_index = x.m_index; + m_message = std::move(x.m_message); + return *this; + } /*! * @brief Comparison operator. * @param x HelloWorld object to compare. */ eProsima_user_DllExport bool operator ==( - const HelloWorld& x) const; + const HelloWorld& x) const + { + return (m_index == x.m_index && + m_message == x.m_message); + } /*! * @brief Comparison operator. * @param x HelloWorld object to compare. */ eProsima_user_DllExport bool operator !=( - const HelloWorld& x) const; + const HelloWorld& x) const + { + return !(*this == x); + } /*! * @brief This function sets a value in member index * @param _index New value for member index */ eProsima_user_DllExport void index( - uint32_t _index); + uint32_t _index) + { + m_index = _index; + } /*! * @brief This function returns the value of member index * @return Value of member index */ - eProsima_user_DllExport uint32_t index() const; + eProsima_user_DllExport uint32_t index() const + { + return m_index; + } /*! * @brief This function returns a reference to member index * @return Reference to member index */ - eProsima_user_DllExport uint32_t& index(); + eProsima_user_DllExport uint32_t& index() + { + return m_index; + } /*! @@ -160,26 +180,40 @@ class HelloWorld * @param _message New value to be copied in member message */ eProsima_user_DllExport void message( - const std::string& _message); + const std::string& _message) + { + m_message = _message; + } /*! * @brief This function moves the value in member message * @param _message New value to be moved in member message */ eProsima_user_DllExport void message( - std::string&& _message); + std::string&& _message) + { + m_message = std::move(_message); + } /*! * @brief This function returns a constant reference to member message * @return Constant reference to member message */ - eProsima_user_DllExport const std::string& message() const; + eProsima_user_DllExport const std::string& message() const + { + return m_message; + } /*! * @brief This function returns a reference to member message * @return Reference to member message */ - eProsima_user_DllExport std::string& message(); + eProsima_user_DllExport std::string& message() + { + return m_message; + } + + private: @@ -188,8 +222,6 @@ class HelloWorld }; -#endif // _FAST_DDS_GENERATED_HELLOWORLD_H_ - +#endif // _FAST_DDS_GENERATED_HELLOWORLD_HPP_ -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/DiscoveryServerExample/types/HelloWorldCdrAux.hpp b/examples/cpp/dds/DiscoveryServerExample/types/HelloWorldCdrAux.hpp index 9f346d306be..6feb8a9da15 100644 --- a/examples/cpp/dds/DiscoveryServerExample/types/HelloWorldCdrAux.hpp +++ b/examples/cpp/dds/DiscoveryServerExample/types/HelloWorldCdrAux.hpp @@ -22,7 +22,7 @@ #ifndef _FAST_DDS_GENERATED_HELLOWORLDCDRAUX_HPP_ #define _FAST_DDS_GENERATED_HELLOWORLDCDRAUX_HPP_ -#include "HelloWorld.h" +#include "HelloWorld.hpp" constexpr uint32_t HelloWorld_max_cdr_typesize {268UL}; constexpr uint32_t HelloWorld_max_key_cdr_typesize {0UL}; @@ -34,8 +34,6 @@ namespace fastcdr { class Cdr; class CdrSizeCalculator; - - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const HelloWorld& data); diff --git a/examples/cpp/dds/DiscoveryServerExample/types/HelloWorldCdrAux.ipp b/examples/cpp/dds/DiscoveryServerExample/types/HelloWorldCdrAux.ipp index 42e91f3cc38..97df3fe9d9e 100644 --- a/examples/cpp/dds/DiscoveryServerExample/types/HelloWorldCdrAux.ipp +++ b/examples/cpp/dds/DiscoveryServerExample/types/HelloWorldCdrAux.ipp @@ -34,8 +34,6 @@ using namespace eprosima::fastcdr::exception; namespace eprosima { namespace fastcdr { - - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, diff --git a/examples/cpp/dds/DiscoveryServerExample/types/HelloWorldPubSubTypes.cxx b/examples/cpp/dds/DiscoveryServerExample/types/HelloWorldPubSubTypes.cxx index 85cb477896e..db018e69782 100644 --- a/examples/cpp/dds/DiscoveryServerExample/types/HelloWorldPubSubTypes.cxx +++ b/examples/cpp/dds/DiscoveryServerExample/types/HelloWorldPubSubTypes.cxx @@ -19,18 +19,18 @@ * This file was generated by the tool fastddsgen. */ +#include "HelloWorldPubSubTypes.h" +#include #include -#include "HelloWorldPubSubTypes.h" #include "HelloWorldCdrAux.hpp" +#include "HelloWorldTypeObjectSupport.hpp" using SerializedPayload_t = eprosima::fastrtps::rtps::SerializedPayload_t; using InstanceHandle_t = eprosima::fastrtps::rtps::InstanceHandle_t; using DataRepresentationId_t = eprosima::fastdds::dds::DataRepresentationId_t; - - HelloWorldPubSubType::HelloWorldPubSubType() { setName("HelloWorld"); @@ -219,3 +219,11 @@ bool HelloWorldPubSubType::getKey( return true; } +void HelloWorldPubSubType::register_type_object_representation() const +{ + register_HelloWorld_type_objects(); +} + + +// Include auxiliary functions like for serializing/deserializing. +#include "HelloWorldCdrAux.ipp" diff --git a/examples/cpp/dds/DiscoveryServerExample/types/HelloWorldPubSubTypes.h b/examples/cpp/dds/DiscoveryServerExample/types/HelloWorldPubSubTypes.h index cb61cd6ba23..a9b4ac119e0 100644 --- a/examples/cpp/dds/DiscoveryServerExample/types/HelloWorldPubSubTypes.h +++ b/examples/cpp/dds/DiscoveryServerExample/types/HelloWorldPubSubTypes.h @@ -27,9 +27,9 @@ #include #include #include -#include +#include -#include "HelloWorld.h" +#include "HelloWorld.hpp" #if !defined(GEN_API_VER) || (GEN_API_VER != 2) @@ -38,8 +38,6 @@ #endif // GEN_API_VER - - /*! * @brief This class represents the TopicDataType of the type HelloWorld defined by the user in the IDL file. * @ingroup HelloWorld @@ -90,6 +88,9 @@ class HelloWorldPubSubType : public eprosima::fastdds::dds::TopicDataType eProsima_user_DllExport void deleteData( void* data) override; + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + #ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED eProsima_user_DllExport inline bool is_bounded() const override { diff --git a/examples/cpp/dds/DiscoveryServerExample/types/HelloWorldTypeObjectSupport.cxx b/examples/cpp/dds/DiscoveryServerExample/types/HelloWorldTypeObjectSupport.cxx new file mode 100644 index 00000000000..bfae95694f4 --- /dev/null +++ b/examples/cpp/dds/DiscoveryServerExample/types/HelloWorldTypeObjectSupport.cxx @@ -0,0 +1,248 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file HelloWorldTypeObjectSupport.cxx + * Source file containing the implementation to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#include "HelloWorldTypeObjectSupport.hpp" + +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include + +#include "HelloWorld.hpp" + + +using namespace eprosima::fastdds::dds::xtypes; + +void register_HelloWorld_type_objects() +{ + static std::once_flag once_flag; + std::call_once(once_flag, []() + { + register_HelloWorld_type_identifier(); + + }); +} + +void register_HelloWorld_type_identifier() +{ + { + StructTypeFlag struct_flags_HelloWorld = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::NOT_APPLIED, + false, false); + ReturnCode_t return_code_HelloWorld; + TypeIdentifierPair type_ids_HelloWorld; + QualifiedTypeName type_name_HelloWorld = "HelloWorld"; + eprosima::fastcdr::optional type_ann_builtin_HelloWorld; + eprosima::fastcdr::optional ann_custom_HelloWorld; + CompleteTypeDetail detail_HelloWorld = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_HelloWorld, ann_custom_HelloWorld, type_name_HelloWorld.to_string()); + CompleteStructHeader header_HelloWorld; + header_HelloWorld = TypeObjectUtils::build_complete_struct_header(TypeIdentifier(), detail_HelloWorld); + CompleteStructMemberSeq member_seq_HelloWorld; + { + return_code_HelloWorld = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_uint32_t", type_ids_HelloWorld); + + if (return_code_HelloWorld != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "index Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_index = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_index; + MemberId member_id_index = 0x00000000; + if (EK_COMPLETE == type_ids_HelloWorld.type_identifier1()._d() || TK_NONE == type_ids_HelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_HelloWorld.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_HelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_HelloWorld.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure index member TypeIdentifier inconsistent."); + return; + } + MemberName name_index = "index"; + eprosima::fastcdr::optional member_ann_builtin_index; + ann_custom_HelloWorld.reset(); + CompleteMemberDetail detail_index = TypeObjectUtils::build_complete_member_detail(name_index, member_ann_builtin_index, ann_custom_HelloWorld); + CompleteStructMember member_index = TypeObjectUtils::build_complete_struct_member(common_index, detail_index); + TypeObjectUtils::add_complete_struct_member(member_seq_HelloWorld, member_index); + } + { + return_code_HelloWorld = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_string_unbounded", type_ids_HelloWorld); + + if (return_code_HelloWorld != eprosima::fastdds::dds::RETCODE_OK) + { + std::string type_id_kind_anonymous_string_unbounded("TI_STRING8_SMALL"); + if (type_id_kind_anonymous_string_unbounded == "TI_STRING8_SMALL") + { + SBound bound = 0; + StringSTypeDefn string_sdefn = TypeObjectUtils::build_string_s_type_defn(bound); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_string_type_identifier(string_sdefn, + "anonymous_string_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else if (type_id_kind_anonymous_string_unbounded == "TI_STRING8_LARGE") + { + LBound bound = 255; + StringLTypeDefn string_ldefn = TypeObjectUtils::build_string_l_type_defn(bound); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_string_type_identifier(string_ldefn, + "anonymous_string_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded: Unknown String kind."); + return; + } + return_code_HelloWorld = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_string_unbounded", type_ids_HelloWorld); + if (return_code_HelloWorld != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded: Given String TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_message = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_message; + MemberId member_id_message = 0x00000001; + if (EK_COMPLETE == type_ids_HelloWorld.type_identifier1()._d() || TK_NONE == type_ids_HelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_message = TypeObjectUtils::build_common_struct_member(member_id_message, member_flags_message, type_ids_HelloWorld.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_HelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_message = TypeObjectUtils::build_common_struct_member(member_id_message, member_flags_message, type_ids_HelloWorld.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure message member TypeIdentifier inconsistent."); + return; + } + MemberName name_message = "message"; + eprosima::fastcdr::optional member_ann_builtin_message; + ann_custom_HelloWorld.reset(); + CompleteMemberDetail detail_message = TypeObjectUtils::build_complete_member_detail(name_message, member_ann_builtin_message, ann_custom_HelloWorld); + CompleteStructMember member_message = TypeObjectUtils::build_complete_struct_member(common_message, detail_message); + TypeObjectUtils::add_complete_struct_member(member_seq_HelloWorld, member_message); + } + CompleteStructType struct_type_HelloWorld = TypeObjectUtils::build_complete_struct_type(struct_flags_HelloWorld, header_HelloWorld, member_seq_HelloWorld); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_struct_type_object(struct_type_HelloWorld, type_name_HelloWorld.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "HelloWorld already registered in TypeObjectRegistry for a different type."); + } + return_code_HelloWorld = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "HelloWorld", type_ids_HelloWorld); + if (return_code_HelloWorld != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "HelloWorld: Given Struct TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } +} + diff --git a/examples/cpp/dds/DiscoveryServerExample/types/HelloWorldTypeObjectSupport.hpp b/examples/cpp/dds/DiscoveryServerExample/types/HelloWorldTypeObjectSupport.hpp new file mode 100644 index 00000000000..8650fc061e0 --- /dev/null +++ b/examples/cpp/dds/DiscoveryServerExample/types/HelloWorldTypeObjectSupport.hpp @@ -0,0 +1,54 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file HelloWorldTypeObjectSupport.hpp + * Header file containing the API required to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#ifndef _FAST_DDS_GENERATED_HELLOWORLD_TYPE_OBJECT_SUPPORT_HPP_ +#define _FAST_DDS_GENERATED_HELLOWORLD_TYPE_OBJECT_SUPPORT_HPP_ + + +#if defined(_WIN32) +#if defined(EPROSIMA_USER_DLL_EXPORT) +#define eProsima_user_DllExport __declspec( dllexport ) +#else +#define eProsima_user_DllExport +#endif // EPROSIMA_USER_DLL_EXPORT +#else +#define eProsima_user_DllExport +#endif // _WIN32 + +/** + * @brief Register every TypeObject representation defined in the IDL file in Fast DDS TypeObjectRegistry. + */ +eProsima_user_DllExport void register_HelloWorld_type_objects(); + +#ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +/** + * @brief Register HelloWorld related TypeIdentifier. + * Fully-descriptive TypeIdentifiers are directly registered. + * Hash TypeIdentifiers require to fill the TypeObject information and hash it, consequently, the TypeObject is + * indirectly registered as well. + */ +void register_HelloWorld_type_identifier(); + + +#endif // DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +#endif // _FAST_DDS_GENERATED_HELLOWORLD_TYPE_OBJECT_SUPPORT_HPP_ diff --git a/examples/cpp/dds/DiscoveryServerExample/types/HelloWorldv1.cxx b/examples/cpp/dds/DiscoveryServerExample/types/HelloWorldv1.cxx deleted file mode 100644 index 90e82ea88a7..00000000000 --- a/examples/cpp/dds/DiscoveryServerExample/types/HelloWorldv1.cxx +++ /dev/null @@ -1,286 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file HelloWorld.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "HelloWorld.h" - -#if FASTCDR_VERSION_MAJOR == 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - -namespace helper { namespace internal { - -enum class Size { - UInt8, - UInt16, - UInt32, - UInt64, -}; - -constexpr Size get_size(int s) { - return (s <= 8 ) ? Size::UInt8: - (s <= 16) ? Size::UInt16: - (s <= 32) ? Size::UInt32: Size::UInt64; -} - -template -struct FindTypeH; - -template<> -struct FindTypeH { - using type = std::uint8_t; -}; - -template<> -struct FindTypeH { - using type = std::uint16_t; -}; - -template<> -struct FindTypeH { - using type = std::uint32_t; -}; - -template<> -struct FindTypeH { - using type = std::uint64_t; -}; -} - -template -struct FindType { - using type = typename internal::FindTypeH::type; -}; -} - -#define HelloWorld_max_cdr_typesize 268ULL; - - - - -HelloWorld::HelloWorld() -{ - // unsigned long m_index - m_index = 0; - // /type_d() m_message - - -} - -HelloWorld::~HelloWorld() -{ -} - -HelloWorld::HelloWorld( - const HelloWorld& x) -{ - m_index = x.m_index; - - - m_message = x.m_message; - -} - -HelloWorld::HelloWorld( - HelloWorld&& x) noexcept -{ - m_index = x.m_index; - - - m_message = std::move(x.m_message); - -} - -HelloWorld& HelloWorld::operator =( - const HelloWorld& x) -{ - m_index = x.m_index; - - - m_message = x.m_message; - - return *this; -} - -HelloWorld& HelloWorld::operator =( - HelloWorld&& x) noexcept -{ - m_index = x.m_index; - - - m_message = std::move(x.m_message); - - return *this; -} - -bool HelloWorld::operator ==( - const HelloWorld& x) const -{ - return (m_index == x.m_index && - m_message == x.m_message); -} - -bool HelloWorld::operator !=( - const HelloWorld& x) const -{ - return !(*this == x); -} - -size_t HelloWorld::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return HelloWorld_max_cdr_typesize; -} - -size_t HelloWorld::getCdrSerializedSize( - const HelloWorld& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + data.message().size() + 1; - - - return current_alignment - initial_alignment; -} - - -void HelloWorld::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_index; - - scdr << m_message.c_str(); - -} - -void HelloWorld::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_index; - - - - dcdr >> m_message; - - -} - - -bool HelloWorld::isKeyDefined() -{ - return false; -} - -void HelloWorld::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void HelloWorld::index( - uint32_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint32_t HelloWorld::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint32_t& HelloWorld::index() -{ - return m_index; -} - - -/*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ -void HelloWorld::message( - const std::string& _message) -{ - m_message = _message; -} - -/*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ -void HelloWorld::message( - std::string&& _message) -{ - m_message = std::move(_message); -} - -/*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ -const std::string& HelloWorld::message() const -{ - return m_message; -} - -/*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ -std::string& HelloWorld::message() -{ - return m_message; -} - - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/DiscoveryServerExample/types/HelloWorldv1.h b/examples/cpp/dds/DiscoveryServerExample/types/HelloWorldv1.h deleted file mode 100644 index 9f6f726e0ab..00000000000 --- a/examples/cpp/dds/DiscoveryServerExample/types/HelloWorldv1.h +++ /dev/null @@ -1,244 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file HelloWorld.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#include - -#if FASTCDR_VERSION_MAJOR == 1 - -#ifndef _FAST_DDS_GENERATED_HELLOWORLD_H_ -#define _FAST_DDS_GENERATED_HELLOWORLD_H_ - - -#include - -#include -#include -#include -#include -#include -#include -#include - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define eProsima_user_DllExport -#endif // _WIN32 - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(HELLOWORLD_SOURCE) -#define HELLOWORLD_DllAPI __declspec( dllexport ) -#else -#define HELLOWORLD_DllAPI __declspec( dllimport ) -#endif // HELLOWORLD_SOURCE -#else -#define HELLOWORLD_DllAPI -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define HELLOWORLD_DllAPI -#endif // _WIN32 - -namespace eprosima { -namespace fastcdr { -class Cdr; -} // namespace fastcdr -} // namespace eprosima - - - - - -/*! - * @brief This class represents the structure HelloWorld defined by the user in the IDL file. - * @ingroup HelloWorld - */ -class HelloWorld -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport HelloWorld(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~HelloWorld(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object HelloWorld that will be copied. - */ - eProsima_user_DllExport HelloWorld( - const HelloWorld& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object HelloWorld that will be copied. - */ - eProsima_user_DllExport HelloWorld( - HelloWorld&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object HelloWorld that will be copied. - */ - eProsima_user_DllExport HelloWorld& operator =( - const HelloWorld& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object HelloWorld that will be copied. - */ - eProsima_user_DllExport HelloWorld& operator =( - HelloWorld&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x HelloWorld object to compare. - */ - eProsima_user_DllExport bool operator ==( - const HelloWorld& x) const; - - /*! - * @brief Comparison operator. - * @param x HelloWorld object to compare. - */ - eProsima_user_DllExport bool operator !=( - const HelloWorld& x) const; - - /*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ - eProsima_user_DllExport void index( - uint32_t _index); - - /*! - * @brief This function returns the value of member index - * @return Value of member index - */ - eProsima_user_DllExport uint32_t index() const; - - /*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ - eProsima_user_DllExport uint32_t& index(); - - - /*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ - eProsima_user_DllExport void message( - const std::string& _message); - - /*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ - eProsima_user_DllExport void message( - std::string&& _message); - - /*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ - eProsima_user_DllExport const std::string& message() const; - - /*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ - eProsima_user_DllExport std::string& message(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const HelloWorld& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - uint32_t m_index; - std::string m_message; - -}; - - -#endif // _FAST_DDS_GENERATED_HELLOWORLD_H_ - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/DynamicHelloWorldExample/CMakeLists.txt b/examples/cpp/dds/DynamicHelloWorldExample/CMakeLists.txt index b5b42c636a0..8e80ce0a115 100644 --- a/examples/cpp/dds/DynamicHelloWorldExample/CMakeLists.txt +++ b/examples/cpp/dds/DynamicHelloWorldExample/CMakeLists.txt @@ -21,8 +21,8 @@ if(NOT fastcdr_FOUND) find_package(fastcdr 2 REQUIRED) endif() -if(NOT fastrtps_FOUND) - find_package(fastrtps 2.12 REQUIRED) +if(NOT fastdds_FOUND) + find_package(fastdds 3 REQUIRED) endif() #Check C++11 @@ -46,7 +46,7 @@ target_compile_definitions(DDSDynamicHelloWorldExample PRIVATE $<$:__INTERNALDEBUG> # Internal debug activated. ) -target_link_libraries(DDSDynamicHelloWorldExample fastrtps fastcdr) +target_link_libraries(DDSDynamicHelloWorldExample fastdds fastcdr) install(TARGETS DDSDynamicHelloWorldExample RUNTIME DESTINATION examples/cpp/dds/DynamicHelloWorldExample/${BIN_INSTALL_DIR}) install(FILES ${CMAKE_CURRENT_SOURCE_DIR}/helloworld_example_type_profile.xml diff --git a/examples/cpp/dds/DynamicHelloWorldExample/HelloWorldPublisher.cpp b/examples/cpp/dds/DynamicHelloWorldExample/HelloWorldPublisher.cpp index 567653d7a30..d5c6f93a514 100644 --- a/examples/cpp/dds/DynamicHelloWorldExample/HelloWorldPublisher.cpp +++ b/examples/cpp/dds/DynamicHelloWorldExample/HelloWorldPublisher.cpp @@ -18,20 +18,18 @@ */ #include "HelloWorldPublisher.h" -#include -#include -#include -#include -#include -#include -#include - -#include - -#include #include +#include +#include +#include +#include +#include +#include +#include +#include + using namespace eprosima::fastdds::dds; HelloWorldPublisher::HelloWorldPublisher() @@ -42,8 +40,8 @@ HelloWorldPublisher::HelloWorldPublisher() bool HelloWorldPublisher::init() { - if (eprosima::fastrtps::xmlparser::XMLP_ret::XML_OK != - eprosima::fastrtps::xmlparser::XMLProfileManager::loadXMLFile("helloworld_example_type_profile.xml")) + if (RETCODE_OK != + DomainParticipantFactory::get_instance()->load_XML_profiles_file("helloworld_example_type_profile.xml")) { std::cout << "Cannot open XML file \"helloworld_example_type_profile.xml\". Please, run the publisher from the folder " @@ -51,25 +49,21 @@ bool HelloWorldPublisher::init() return false; } - eprosima::fastrtps::types::DynamicType_ptr dyn_type = - eprosima::fastrtps::xmlparser::XMLProfileManager::getDynamicTypeByName("HelloWorld")->build(); - TypeSupport m_type(new eprosima::fastrtps::types::DynamicPubSubType(dyn_type)); - m_Hello = eprosima::fastrtps::types::DynamicDataFactory::get_instance()->create_data(dyn_type); + DynamicType::_ref_type dyn_type; + if (RETCODE_OK != + DomainParticipantFactory::get_instance()->get_dynamic_type_builder_from_xml_by_name("HelloWorld", + dyn_type)) + { + std::cout << + "Error getting dynamic type \"HelloWorld\"." << std::endl; + return false; + } - m_Hello->set_string_value("Hello DDS Dynamic World", 0); - m_Hello->set_uint32_value(0, 1); - eprosima::fastrtps::types::DynamicData* array = m_Hello->loan_value(2); - array->set_uint32_value(10, array->get_array_index({0, 0})); - array->set_uint32_value(20, array->get_array_index({1, 0})); - array->set_uint32_value(30, array->get_array_index({2, 0})); - array->set_uint32_value(40, array->get_array_index({3, 0})); - array->set_uint32_value(50, array->get_array_index({4, 0})); - array->set_uint32_value(60, array->get_array_index({0, 1})); - array->set_uint32_value(70, array->get_array_index({1, 1})); - array->set_uint32_value(80, array->get_array_index({2, 1})); - array->set_uint32_value(90, array->get_array_index({3, 1})); - array->set_uint32_value(100, array->get_array_index({4, 1})); - m_Hello->return_loaned_value(array); + TypeSupport m_type(new DynamicPubSubType(dyn_type)); + m_Hello = DynamicDataFactory::get_instance()->create_data(dyn_type); + m_Hello->set_string_value(m_Hello->get_member_id_by_name("message"), "Hello DDS Dynamic World"); + m_Hello->set_uint32_value(m_Hello->get_member_id_by_name("index"), 0); + m_Hello->set_uint32_values(m_Hello->get_member_id_by_name("array"), {10, 20, 30, 40, 50, 60, 70, 80, 90, 100}); DomainParticipantQos pqos; pqos.name("Participant_pub"); @@ -81,8 +75,8 @@ bool HelloWorldPublisher::init() } //REGISTER THE TYPE + //TODO(Xtypes) this property will be removed m_type.get()->auto_fill_type_information(false); - m_type.get()->auto_fill_type_object(true); m_type.register_type(mp_participant); @@ -94,7 +88,7 @@ bool HelloWorldPublisher::init() return false; } - topic_ = mp_participant->create_topic("DDSDynHelloWorldTopic", "HelloWorld", TOPIC_QOS_DEFAULT); + topic_ = mp_participant->create_topic("DDSDynHelloWorldTopic", m_type->getName(), TOPIC_QOS_DEFAULT); if (topic_ == nullptr) { @@ -163,23 +157,23 @@ void HelloWorldPublisher::runThread( if (publish(false)) { std::string message; - m_Hello->get_string_value(message, 0); - uint32_t index; - m_Hello->get_uint32_value(index, 1); + m_Hello->get_string_value(message, m_Hello->get_member_id_by_name("message")); + uint32_t index {0}; + m_Hello->get_uint32_value(index, m_Hello->get_member_id_by_name("index")); + UInt32Seq array; + m_Hello->get_uint32_values(array, m_Hello->get_member_id_by_name("array")); std::string aux_array = "["; - eprosima::fastrtps::types::DynamicData* array = m_Hello->loan_value(2); + for (uint32_t i = 0; i < 5; ++i) { aux_array += "["; for (uint32_t j = 0; j < 2; ++j) { - uint32_t elem; - array->get_uint32_value(elem, array->get_array_index({i, j})); - aux_array += std::to_string(elem) + (j == 1 ? "]" : ", "); + aux_array += std::to_string(array.at((i * 5) + j)) + (j == 1 ? "]" : ", "); } aux_array += (i == 4 ? "]" : "], "); } - m_Hello->return_loaned_value(array); + std::cout << "Message: " << message << " with index: " << index << " array: " << aux_array << " SENT" << std::endl; } @@ -197,23 +191,23 @@ void HelloWorldPublisher::runThread( else { std::string message; - m_Hello->get_string_value(message, 0); - uint32_t index; - m_Hello->get_uint32_value(index, 1); + m_Hello->get_string_value(message, m_Hello->get_member_id_by_name("message")); + uint32_t index {0}; + m_Hello->get_uint32_value(index, m_Hello->get_member_id_by_name("index")); + UInt32Seq array; + m_Hello->get_uint32_values(array, m_Hello->get_member_id_by_name("array")); std::string aux_array = "["; - eprosima::fastrtps::types::DynamicData* array = m_Hello->loan_value(2); + for (uint32_t i = 0; i < 5; ++i) { aux_array += "["; for (uint32_t j = 0; j < 2; ++j) { - uint32_t elem; - array->get_uint32_value(elem, array->get_array_index({i, j})); - aux_array += std::to_string(elem) + (j == 1 ? "]" : ", "); + aux_array += std::to_string(array.at((i * 5) + j)) + (j == 1 ? "]" : ", "); } aux_array += (i == 4 ? "]" : "], "); } - m_Hello->return_loaned_value(array); + std::cout << "Message: " << message << " with index: " << index << " array: " << aux_array << " SENT" << std::endl; } @@ -247,23 +241,13 @@ bool HelloWorldPublisher::publish( if (m_listener.firstConnected || !waitForListener || m_listener.n_matched > 0) { uint32_t index; - m_Hello->get_uint32_value(index, 1); - m_Hello->set_uint32_value(index + 1, 1); - - eprosima::fastrtps::types::DynamicData* array = m_Hello->loan_value(2); - array->set_uint32_value(10 + index, array->get_array_index({0, 0})); - array->set_uint32_value(20 + index, array->get_array_index({1, 0})); - array->set_uint32_value(30 + index, array->get_array_index({2, 0})); - array->set_uint32_value(40 + index, array->get_array_index({3, 0})); - array->set_uint32_value(50 + index, array->get_array_index({4, 0})); - array->set_uint32_value(60 + index, array->get_array_index({0, 1})); - array->set_uint32_value(70 + index, array->get_array_index({1, 1})); - array->set_uint32_value(80 + index, array->get_array_index({2, 1})); - array->set_uint32_value(90 + index, array->get_array_index({3, 1})); - array->set_uint32_value(100 + index, array->get_array_index({4, 1})); - m_Hello->return_loaned_value(array); - - writer_->write(m_Hello.get()); + m_Hello->get_uint32_value(index, m_Hello->get_member_id_by_name("index")); + m_Hello->set_uint32_value(m_Hello->get_member_id_by_name("index"), index + 1); + m_Hello->set_uint32_values(m_Hello->get_member_id_by_name( + "array"), + {10 + index, 20 + index, 30 + index, 40 + index, 50 + index, 60 + index, 70 + index, 80 + index, 90 + index, + 100 + index}); + writer_->write(&m_Hello); return true; } return false; diff --git a/examples/cpp/dds/DynamicHelloWorldExample/HelloWorldPublisher.h b/examples/cpp/dds/DynamicHelloWorldExample/HelloWorldPublisher.h index 39f10fd2e0b..03f734e35aa 100644 --- a/examples/cpp/dds/DynamicHelloWorldExample/HelloWorldPublisher.h +++ b/examples/cpp/dds/DynamicHelloWorldExample/HelloWorldPublisher.h @@ -20,6 +20,8 @@ #ifndef HELLOWORLDPUBLISHER_H_ #define HELLOWORLDPUBLISHER_H_ +#include + #include #include @@ -45,7 +47,7 @@ class HelloWorldPublisher private: - eprosima::fastrtps::types::DynamicData_ptr m_Hello; + eprosima::fastdds::dds::DynamicData::_ref_type m_Hello; eprosima::fastdds::dds::DomainParticipant* mp_participant; diff --git a/examples/cpp/dds/DynamicHelloWorldExample/HelloWorldSubscriber.cpp b/examples/cpp/dds/DynamicHelloWorldExample/HelloWorldSubscriber.cpp index 753a1590e0d..f65d324a2cf 100644 --- a/examples/cpp/dds/DynamicHelloWorldExample/HelloWorldSubscriber.cpp +++ b/examples/cpp/dds/DynamicHelloWorldExample/HelloWorldSubscriber.cpp @@ -27,13 +27,10 @@ #include #include #include -#include -#include -#include -#include +#include +#include using namespace eprosima::fastdds::dds; -using eprosima::fastrtps::types::ReturnCode_t; HelloWorldSubscriber::HelloWorldSubscriber() : mp_participant(nullptr) @@ -58,7 +55,7 @@ bool HelloWorldSubscriber::init() { return false; } - if (mp_participant->enable() != ReturnCode_t::RETCODE_OK) + if (mp_participant->enable() != RETCODE_OK) { DomainParticipantFactory::get_instance()->delete_participant(mp_participant); return false; @@ -117,40 +114,25 @@ void HelloWorldSubscriber::SubListener::on_data_available( if (dit != subscriber_->datas_.end()) { - eprosima::fastrtps::types::DynamicData_ptr data = dit->second; + DynamicData::_ref_type data {dit->second}; SampleInfo info; - if (reader->take_next_sample(data.get(), &info) == ReturnCode_t::RETCODE_OK) + if (reader->take_next_sample(&data, &info) == RETCODE_OK) { if (info.instance_state == ALIVE_INSTANCE_STATE) { - eprosima::fastrtps::types::DynamicType_ptr type = subscriber_->readers_[reader]; + const DynamicType::_ref_type type {subscriber_->readers_[reader]}; this->n_samples++; std::cout << "Received data of type " << type->get_name() << std::endl; - eprosima::fastrtps::types::DynamicDataHelper::print(data); } } } } -void HelloWorldSubscriber::SubListener::on_type_discovery( - DomainParticipant*, - const eprosima::fastrtps::rtps::SampleIdentity&, - const eprosima::fastrtps::string_255& topic_name, - const eprosima::fastrtps::types::TypeIdentifier*, - const eprosima::fastrtps::types::TypeObject*, - eprosima::fastrtps::types::DynamicType_ptr dyn_type) -{ - std::cout << "Discovered type: " << dyn_type->get_name() << " from topic " << topic_name << std::endl; - received_type_ = dyn_type; - reception_flag_.store(true); - types_cv_.notify_one(); -} - void HelloWorldSubscriber::initialize_entities() { auto type = m_listener.received_type_; std::cout << "Initializing DDS entities for type: " << type->get_name() << std::endl; - TypeSupport m_type(new eprosima::fastrtps::types::DynamicPubSubType(type)); + TypeSupport m_type(new DynamicPubSubType(type)); m_type.register_type(mp_participant); if (mp_subscriber == nullptr) @@ -184,8 +166,7 @@ void HelloWorldSubscriber::initialize_entities() topics_[reader] = topic; readers_[reader] = type; - eprosima::fastrtps::types::DynamicData_ptr data( - eprosima::fastrtps::types::DynamicDataFactory::get_instance()->create_data(type)); + DynamicData::_ref_type data {DynamicDataFactory::get_instance()->create_data(type)}; datas_[reader] = data; } diff --git a/examples/cpp/dds/DynamicHelloWorldExample/HelloWorldSubscriber.h b/examples/cpp/dds/DynamicHelloWorldExample/HelloWorldSubscriber.h index fe10753b623..447d8685e9f 100644 --- a/examples/cpp/dds/DynamicHelloWorldExample/HelloWorldSubscriber.h +++ b/examples/cpp/dds/DynamicHelloWorldExample/HelloWorldSubscriber.h @@ -20,21 +20,17 @@ #ifndef HELLOWORLDSUBSCRIBER_H_ #define HELLOWORLDSUBSCRIBER_H_ +#include +#include +#include + #include #include #include #include -#include -#include - -#include -#include - -#include - -#include -#include -#include +#include +#include +#include class HelloWorldSubscriber { @@ -65,11 +61,9 @@ class HelloWorldSubscriber std::map topics_; - std::map readers_; - - std::map datas_; + std::map readers_; - eprosima::fastrtps::SubscriberAttributes att_; + std::map datas_; eprosima::fastdds::dds::DataReaderQos qos_; @@ -99,14 +93,6 @@ class HelloWorldSubscriber eprosima::fastdds::dds::DataReader* reader, const eprosima::fastdds::dds::SubscriptionMatchedStatus& info) override; - void on_type_discovery( - eprosima::fastdds::dds::DomainParticipant* participant, - const eprosima::fastrtps::rtps::SampleIdentity& request_sample_id, - const eprosima::fastrtps::string_255& topic, - const eprosima::fastrtps::types::TypeIdentifier* identifier, - const eprosima::fastrtps::types::TypeObject* object, - eprosima::fastrtps::types::DynamicType_ptr dyn_type) override; - int n_matched; uint32_t n_samples; @@ -115,7 +101,7 @@ class HelloWorldSubscriber std::condition_variable types_cv_; - eprosima::fastrtps::types::DynamicType_ptr received_type_; + eprosima::fastdds::dds::DynamicType::_ref_type received_type_; std::atomic reception_flag_{false}; diff --git a/examples/cpp/dds/DynamicHelloWorldExample/HelloWorld_main.cpp b/examples/cpp/dds/DynamicHelloWorldExample/HelloWorld_main.cpp index a880dcd6067..582908edb44 100644 --- a/examples/cpp/dds/DynamicHelloWorldExample/HelloWorld_main.cpp +++ b/examples/cpp/dds/DynamicHelloWorldExample/HelloWorld_main.cpp @@ -20,7 +20,7 @@ #include "HelloWorldPublisher.h" #include "HelloWorldSubscriber.h" -#include +#include using eprosima::fastdds::dds::Log; diff --git a/examples/cpp/dds/DynamicHelloWorldExample/helloworld_example_type_profile.xml b/examples/cpp/dds/DynamicHelloWorldExample/helloworld_example_type_profile.xml index 1cb261cde23..4fa748f4973 100644 --- a/examples/cpp/dds/DynamicHelloWorldExample/helloworld_example_type_profile.xml +++ b/examples/cpp/dds/DynamicHelloWorldExample/helloworld_example_type_profile.xml @@ -1,5 +1,5 @@ - + diff --git a/examples/cpp/dds/Filtering/CMakeLists.txt b/examples/cpp/dds/Filtering/CMakeLists.txt index 3255936b8d4..45a34aa0889 100644 --- a/examples/cpp/dds/Filtering/CMakeLists.txt +++ b/examples/cpp/dds/Filtering/CMakeLists.txt @@ -25,8 +25,8 @@ if(NOT foonathan_memory_FOUND) find_package(foonathan_memory REQUIRED) endif() -if(NOT fastrtps_FOUND) - find_package(fastrtps 2.12 REQUIRED) +if(NOT fastdds_FOUND) + find_package(fastdds 3 REQUIRED) endif() #Check C++11 @@ -47,7 +47,7 @@ target_compile_definitions(DDSFiltering PRIVATE $<$>,$>:__DEBUG> $<$:__INTERNALDEBUG> # Internal debug activated. ) -target_link_libraries(DDSFiltering fastrtps fastcdr foonathan_memory) +target_link_libraries(DDSFiltering fastdds fastcdr foonathan_memory) install(TARGETS DDSFiltering RUNTIME DESTINATION examples/cpp/dds/Filtering/${BIN_INSTALL_DIR} ) diff --git a/examples/cpp/dds/Filtering/FilteringExample.cxx b/examples/cpp/dds/Filtering/FilteringExample.cxx deleted file mode 100644 index 3f489150d46..00000000000 --- a/examples/cpp/dds/Filtering/FilteringExample.cxx +++ /dev/null @@ -1,124 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file FilteringExample.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "FilteringExample.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - - - - -FilteringExample::FilteringExample() -{ -} - -FilteringExample::~FilteringExample() -{ -} - -FilteringExample::FilteringExample( - const FilteringExample& x) -{ - m_sampleNumber = x.m_sampleNumber; -} - -FilteringExample::FilteringExample( - FilteringExample&& x) noexcept -{ - m_sampleNumber = x.m_sampleNumber; -} - -FilteringExample& FilteringExample::operator =( - const FilteringExample& x) -{ - - m_sampleNumber = x.m_sampleNumber; - return *this; -} - -FilteringExample& FilteringExample::operator =( - FilteringExample&& x) noexcept -{ - - m_sampleNumber = x.m_sampleNumber; - return *this; -} - -bool FilteringExample::operator ==( - const FilteringExample& x) const -{ - return (m_sampleNumber == x.m_sampleNumber); -} - -bool FilteringExample::operator !=( - const FilteringExample& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member sampleNumber - * @param _sampleNumber New value for member sampleNumber - */ -void FilteringExample::sampleNumber( - int32_t _sampleNumber) -{ - m_sampleNumber = _sampleNumber; -} - -/*! - * @brief This function returns the value of member sampleNumber - * @return Value of member sampleNumber - */ -int32_t FilteringExample::sampleNumber() const -{ - return m_sampleNumber; -} - -/*! - * @brief This function returns a reference to member sampleNumber - * @return Reference to member sampleNumber - */ -int32_t& FilteringExample::sampleNumber() -{ - return m_sampleNumber; -} - - -// Include auxiliary functions like for serializing/deserializing. -#include "FilteringExampleCdrAux.ipp" - -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/Filtering/FilteringExample.h b/examples/cpp/dds/Filtering/FilteringExample.hpp similarity index 72% rename from examples/cpp/dds/Filtering/FilteringExample.h rename to examples/cpp/dds/Filtering/FilteringExample.hpp index c57439eb75c..b79790c6dec 100644 --- a/examples/cpp/dds/Filtering/FilteringExample.h +++ b/examples/cpp/dds/Filtering/FilteringExample.hpp @@ -13,32 +13,17 @@ // limitations under the License. /*! - * @file FilteringExample.h + * @file FilteringExample.hpp * This header file contains the declaration of the described types in the IDL file. * * This file was generated by the tool fastddsgen. */ -#include -#include "FilteringExamplev1.h" +#ifndef _FAST_DDS_GENERATED_FILTERINGEXAMPLE_HPP_ +#define _FAST_DDS_GENERATED_FILTERINGEXAMPLE_HPP_ -#if FASTCDR_VERSION_MAJOR > 1 - -#ifndef _FAST_DDS_GENERATED_FILTERINGEXAMPLE_H_ -#define _FAST_DDS_GENERATED_FILTERINGEXAMPLE_H_ - -#include -#include #include -#include -#include -#include - -#include -#include -#include - - +#include #if defined(_WIN32) #if defined(EPROSIMA_USER_DLL_EXPORT) @@ -64,17 +49,6 @@ #define FILTERINGEXAMPLE_DllAPI #endif // _WIN32 -namespace eprosima { -namespace fastcdr { -class Cdr; -class CdrSizeCalculator; -} // namespace fastcdr -} // namespace eprosima - - - - - /*! * @brief This class represents the structure FilteringExample defined by the user in the IDL file. * @ingroup FilteringExample @@ -86,73 +60,112 @@ class FilteringExample /*! * @brief Default constructor. */ - eProsima_user_DllExport FilteringExample(); + eProsima_user_DllExport FilteringExample() + { + } /*! * @brief Default destructor. */ - eProsima_user_DllExport ~FilteringExample(); + eProsima_user_DllExport ~FilteringExample() + { + } /*! * @brief Copy constructor. * @param x Reference to the object FilteringExample that will be copied. */ eProsima_user_DllExport FilteringExample( - const FilteringExample& x); + const FilteringExample& x) + { + m_sampleNumber = x.m_sampleNumber; + + } /*! * @brief Move constructor. * @param x Reference to the object FilteringExample that will be copied. */ eProsima_user_DllExport FilteringExample( - FilteringExample&& x) noexcept; + FilteringExample&& x) noexcept + { + m_sampleNumber = x.m_sampleNumber; + } /*! * @brief Copy assignment. * @param x Reference to the object FilteringExample that will be copied. */ eProsima_user_DllExport FilteringExample& operator =( - const FilteringExample& x); + const FilteringExample& x) + { + + m_sampleNumber = x.m_sampleNumber; + + return *this; + } /*! * @brief Move assignment. * @param x Reference to the object FilteringExample that will be copied. */ eProsima_user_DllExport FilteringExample& operator =( - FilteringExample&& x) noexcept; + FilteringExample&& x) noexcept + { + + m_sampleNumber = x.m_sampleNumber; + return *this; + } /*! * @brief Comparison operator. * @param x FilteringExample object to compare. */ eProsima_user_DllExport bool operator ==( - const FilteringExample& x) const; + const FilteringExample& x) const + { + return (m_sampleNumber == x.m_sampleNumber); + } /*! * @brief Comparison operator. * @param x FilteringExample object to compare. */ eProsima_user_DllExport bool operator !=( - const FilteringExample& x) const; + const FilteringExample& x) const + { + return !(*this == x); + } /*! * @brief This function sets a value in member sampleNumber * @param _sampleNumber New value for member sampleNumber */ eProsima_user_DllExport void sampleNumber( - int32_t _sampleNumber); + int32_t _sampleNumber) + { + m_sampleNumber = _sampleNumber; + } /*! * @brief This function returns the value of member sampleNumber * @return Value of member sampleNumber */ - eProsima_user_DllExport int32_t sampleNumber() const; + eProsima_user_DllExport int32_t sampleNumber() const + { + return m_sampleNumber; + } /*! * @brief This function returns a reference to member sampleNumber * @return Reference to member sampleNumber */ - eProsima_user_DllExport int32_t& sampleNumber(); + eProsima_user_DllExport int32_t& sampleNumber() + { + return m_sampleNumber; + } + + private: @@ -160,8 +173,6 @@ class FilteringExample }; -#endif // _FAST_DDS_GENERATED_FILTERINGEXAMPLE_H_ - +#endif // _FAST_DDS_GENERATED_FILTERINGEXAMPLE_HPP_ -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/Filtering/FilteringExampleCdrAux.hpp b/examples/cpp/dds/Filtering/FilteringExampleCdrAux.hpp index 54b78a2c93a..7b9e9f23d6c 100644 --- a/examples/cpp/dds/Filtering/FilteringExampleCdrAux.hpp +++ b/examples/cpp/dds/Filtering/FilteringExampleCdrAux.hpp @@ -22,7 +22,7 @@ #ifndef _FAST_DDS_GENERATED_FILTERINGEXAMPLECDRAUX_HPP_ #define _FAST_DDS_GENERATED_FILTERINGEXAMPLECDRAUX_HPP_ -#include "FilteringExample.h" +#include "FilteringExample.hpp" constexpr uint32_t FilteringExample_max_cdr_typesize {8UL}; constexpr uint32_t FilteringExample_max_key_cdr_typesize {0UL}; @@ -34,8 +34,6 @@ namespace fastcdr { class Cdr; class CdrSizeCalculator; - - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const FilteringExample& data); diff --git a/examples/cpp/dds/Filtering/FilteringExampleCdrAux.ipp b/examples/cpp/dds/Filtering/FilteringExampleCdrAux.ipp index d2fdb2c7032..5e95da1ef32 100644 --- a/examples/cpp/dds/Filtering/FilteringExampleCdrAux.ipp +++ b/examples/cpp/dds/Filtering/FilteringExampleCdrAux.ipp @@ -34,8 +34,6 @@ using namespace eprosima::fastcdr::exception; namespace eprosima { namespace fastcdr { - - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, diff --git a/examples/cpp/dds/Filtering/FilteringExamplePubSubMain.cxx b/examples/cpp/dds/Filtering/FilteringExamplePubSubMain.cxx index 51229191915..0da1061846b 100644 --- a/examples/cpp/dds/Filtering/FilteringExamplePubSubMain.cxx +++ b/examples/cpp/dds/Filtering/FilteringExamplePubSubMain.cxx @@ -15,10 +15,6 @@ #include "FilteringExamplePublisher.h" #include "FilteringExampleSubscriber.h" - -#include -#include - using namespace eprosima; using namespace eprosima::fastrtps; diff --git a/examples/cpp/dds/Filtering/FilteringExamplePubSubTypes.cxx b/examples/cpp/dds/Filtering/FilteringExamplePubSubTypes.cxx index be0bd937a6b..86c035eec5e 100644 --- a/examples/cpp/dds/Filtering/FilteringExamplePubSubTypes.cxx +++ b/examples/cpp/dds/Filtering/FilteringExamplePubSubTypes.cxx @@ -19,18 +19,18 @@ * This file was generated by the tool fastddsgen. */ +#include "FilteringExamplePubSubTypes.h" +#include #include -#include "FilteringExamplePubSubTypes.h" #include "FilteringExampleCdrAux.hpp" +#include "FilteringExampleTypeObjectSupport.hpp" using SerializedPayload_t = eprosima::fastrtps::rtps::SerializedPayload_t; using InstanceHandle_t = eprosima::fastrtps::rtps::InstanceHandle_t; using DataRepresentationId_t = eprosima::fastdds::dds::DataRepresentationId_t; - - FilteringExamplePubSubType::FilteringExamplePubSubType() { setName("FilteringExample"); @@ -219,3 +219,11 @@ bool FilteringExamplePubSubType::getKey( return true; } +void FilteringExamplePubSubType::register_type_object_representation() const +{ + register_FilteringExample_type_objects(); +} + + +// Include auxiliary functions like for serializing/deserializing. +#include "FilteringExampleCdrAux.ipp" diff --git a/examples/cpp/dds/Filtering/FilteringExamplePubSubTypes.h b/examples/cpp/dds/Filtering/FilteringExamplePubSubTypes.h index 7f167f7b498..8b75d448159 100644 --- a/examples/cpp/dds/Filtering/FilteringExamplePubSubTypes.h +++ b/examples/cpp/dds/Filtering/FilteringExamplePubSubTypes.h @@ -27,9 +27,9 @@ #include #include #include -#include +#include -#include "FilteringExample.h" +#include "FilteringExample.hpp" #if !defined(GEN_API_VER) || (GEN_API_VER != 2) @@ -38,8 +38,6 @@ #endif // GEN_API_VER - - /*! * @brief This class represents the TopicDataType of the type FilteringExample defined by the user in the IDL file. * @ingroup FilteringExample @@ -90,6 +88,9 @@ class FilteringExamplePubSubType : public eprosima::fastdds::dds::TopicDataType eProsima_user_DllExport void deleteData( void* data) override; + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + #ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED eProsima_user_DllExport inline bool is_bounded() const override { diff --git a/examples/cpp/dds/Filtering/FilteringExampleSubscriber.cxx b/examples/cpp/dds/Filtering/FilteringExampleSubscriber.cxx index 6a5f254046e..b2bbc02297f 100644 --- a/examples/cpp/dds/Filtering/FilteringExampleSubscriber.cxx +++ b/examples/cpp/dds/Filtering/FilteringExampleSubscriber.cxx @@ -127,7 +127,7 @@ void FilteringExampleSubscriber::SubListener::on_data_available( { SampleInfo info; FilteringExample st; - if (reader->take_next_sample(&st, &info) == ReturnCode_t::RETCODE_OK) + if (reader->take_next_sample(&st, &info) == RETCODE_OK) { if (info.valid_data) { diff --git a/examples/cpp/dds/Filtering/FilteringExampleTypeObjectSupport.cxx b/examples/cpp/dds/Filtering/FilteringExampleTypeObjectSupport.cxx new file mode 100644 index 00000000000..24837dd4cc2 --- /dev/null +++ b/examples/cpp/dds/Filtering/FilteringExampleTypeObjectSupport.cxx @@ -0,0 +1,147 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file FilteringExampleTypeObjectSupport.cxx + * Source file containing the implementation to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#include "FilteringExampleTypeObjectSupport.hpp" + +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include + +#include "FilteringExample.hpp" + + +using namespace eprosima::fastdds::dds::xtypes; + +void register_FilteringExample_type_objects() +{ + static std::once_flag once_flag; + std::call_once(once_flag, []() + { + register_FilteringExample_type_identifier(); + + }); +} + +void register_FilteringExample_type_identifier() +{ + { + StructTypeFlag struct_flags_FilteringExample = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::NOT_APPLIED, + false, false); + ReturnCode_t return_code_FilteringExample; + TypeIdentifierPair type_ids_FilteringExample; + QualifiedTypeName type_name_FilteringExample = "FilteringExample"; + eprosima::fastcdr::optional type_ann_builtin_FilteringExample; + eprosima::fastcdr::optional ann_custom_FilteringExample; + CompleteTypeDetail detail_FilteringExample = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_FilteringExample, ann_custom_FilteringExample, type_name_FilteringExample.to_string()); + CompleteStructHeader header_FilteringExample; + header_FilteringExample = TypeObjectUtils::build_complete_struct_header(TypeIdentifier(), detail_FilteringExample); + CompleteStructMemberSeq member_seq_FilteringExample; + { + return_code_FilteringExample = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_int32_t", type_ids_FilteringExample); + + if (return_code_FilteringExample != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "sampleNumber Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_sampleNumber = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_sampleNumber; + MemberId member_id_sampleNumber = 0x00000000; + if (EK_COMPLETE == type_ids_FilteringExample.type_identifier1()._d() || TK_NONE == type_ids_FilteringExample.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_FilteringExample.type_identifier1()._d() && + EK_COMPLETE == type_ids_FilteringExample.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_FilteringExample.type_identifier1()._d() && + EK_COMPLETE == type_ids_FilteringExample.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_FilteringExample.type_identifier1()._d() && + EK_COMPLETE == type_ids_FilteringExample.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_FilteringExample.type_identifier1()._d() && + EK_COMPLETE == type_ids_FilteringExample.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_FilteringExample.type_identifier1()._d() && + (EK_COMPLETE == type_ids_FilteringExample.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_FilteringExample.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_FilteringExample.type_identifier1()._d() && + (EK_COMPLETE == type_ids_FilteringExample.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_FilteringExample.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_sampleNumber = TypeObjectUtils::build_common_struct_member(member_id_sampleNumber, member_flags_sampleNumber, type_ids_FilteringExample.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_FilteringExample.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_FilteringExample.type_identifier2()._d() && + EK_COMPLETE == type_ids_FilteringExample.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_FilteringExample.type_identifier2()._d() && + EK_COMPLETE == type_ids_FilteringExample.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_FilteringExample.type_identifier2()._d() && + EK_COMPLETE == type_ids_FilteringExample.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_FilteringExample.type_identifier2()._d() && + EK_COMPLETE == type_ids_FilteringExample.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_FilteringExample.type_identifier2()._d() && + (EK_COMPLETE == type_ids_FilteringExample.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_FilteringExample.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_FilteringExample.type_identifier2()._d() && + (EK_COMPLETE == type_ids_FilteringExample.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_FilteringExample.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_sampleNumber = TypeObjectUtils::build_common_struct_member(member_id_sampleNumber, member_flags_sampleNumber, type_ids_FilteringExample.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure sampleNumber member TypeIdentifier inconsistent."); + return; + } + MemberName name_sampleNumber = "sampleNumber"; + eprosima::fastcdr::optional member_ann_builtin_sampleNumber; + ann_custom_FilteringExample.reset(); + CompleteMemberDetail detail_sampleNumber = TypeObjectUtils::build_complete_member_detail(name_sampleNumber, member_ann_builtin_sampleNumber, ann_custom_FilteringExample); + CompleteStructMember member_sampleNumber = TypeObjectUtils::build_complete_struct_member(common_sampleNumber, detail_sampleNumber); + TypeObjectUtils::add_complete_struct_member(member_seq_FilteringExample, member_sampleNumber); + } + CompleteStructType struct_type_FilteringExample = TypeObjectUtils::build_complete_struct_type(struct_flags_FilteringExample, header_FilteringExample, member_seq_FilteringExample); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_struct_type_object(struct_type_FilteringExample, type_name_FilteringExample.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "FilteringExample already registered in TypeObjectRegistry for a different type."); + } + return_code_FilteringExample = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "FilteringExample", type_ids_FilteringExample); + if (return_code_FilteringExample != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "FilteringExample: Given Struct TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } +} + diff --git a/examples/cpp/dds/Filtering/FilteringExampleTypeObjectSupport.hpp b/examples/cpp/dds/Filtering/FilteringExampleTypeObjectSupport.hpp new file mode 100644 index 00000000000..a2f76df5a00 --- /dev/null +++ b/examples/cpp/dds/Filtering/FilteringExampleTypeObjectSupport.hpp @@ -0,0 +1,54 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file FilteringExampleTypeObjectSupport.hpp + * Header file containing the API required to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#ifndef _FAST_DDS_GENERATED_FILTERINGEXAMPLE_TYPE_OBJECT_SUPPORT_HPP_ +#define _FAST_DDS_GENERATED_FILTERINGEXAMPLE_TYPE_OBJECT_SUPPORT_HPP_ + + +#if defined(_WIN32) +#if defined(EPROSIMA_USER_DLL_EXPORT) +#define eProsima_user_DllExport __declspec( dllexport ) +#else +#define eProsima_user_DllExport +#endif // EPROSIMA_USER_DLL_EXPORT +#else +#define eProsima_user_DllExport +#endif // _WIN32 + +/** + * @brief Register every TypeObject representation defined in the IDL file in Fast DDS TypeObjectRegistry. + */ +eProsima_user_DllExport void register_FilteringExample_type_objects(); + +#ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +/** + * @brief Register FilteringExample related TypeIdentifier. + * Fully-descriptive TypeIdentifiers are directly registered. + * Hash TypeIdentifiers require to fill the TypeObject information and hash it, consequently, the TypeObject is + * indirectly registered as well. + */ +void register_FilteringExample_type_identifier(); + + +#endif // DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +#endif // _FAST_DDS_GENERATED_FILTERINGEXAMPLE_TYPE_OBJECT_SUPPORT_HPP_ diff --git a/examples/cpp/dds/Filtering/FilteringExamplev1.cxx b/examples/cpp/dds/Filtering/FilteringExamplev1.cxx deleted file mode 100644 index 22b80052278..00000000000 --- a/examples/cpp/dds/Filtering/FilteringExamplev1.cxx +++ /dev/null @@ -1,223 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file FilteringExample.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "FilteringExample.h" - -#if FASTCDR_VERSION_MAJOR == 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - -namespace helper { namespace internal { - -enum class Size { - UInt8, - UInt16, - UInt32, - UInt64, -}; - -constexpr Size get_size(int s) { - return (s <= 8 ) ? Size::UInt8: - (s <= 16) ? Size::UInt16: - (s <= 32) ? Size::UInt32: Size::UInt64; -} - -template -struct FindTypeH; - -template<> -struct FindTypeH { - using type = std::uint8_t; -}; - -template<> -struct FindTypeH { - using type = std::uint16_t; -}; - -template<> -struct FindTypeH { - using type = std::uint32_t; -}; - -template<> -struct FindTypeH { - using type = std::uint64_t; -}; -} - -template -struct FindType { - using type = typename internal::FindTypeH::type; -}; -} - -#define FilteringExample_max_cdr_typesize 8ULL; - - - - -FilteringExample::FilteringExample() -{ - // long m_sampleNumber - m_sampleNumber = 0; - -} - -FilteringExample::~FilteringExample() -{ -} - -FilteringExample::FilteringExample( - const FilteringExample& x) -{ - m_sampleNumber = x.m_sampleNumber; - -} - -FilteringExample::FilteringExample( - FilteringExample&& x) noexcept -{ - m_sampleNumber = x.m_sampleNumber; - -} - -FilteringExample& FilteringExample::operator =( - const FilteringExample& x) -{ - m_sampleNumber = x.m_sampleNumber; - - return *this; -} - -FilteringExample& FilteringExample::operator =( - FilteringExample&& x) noexcept -{ - m_sampleNumber = x.m_sampleNumber; - - return *this; -} - -bool FilteringExample::operator ==( - const FilteringExample& x) const -{ - return (m_sampleNumber == x.m_sampleNumber); -} - -bool FilteringExample::operator !=( - const FilteringExample& x) const -{ - return !(*this == x); -} - -size_t FilteringExample::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return FilteringExample_max_cdr_typesize; -} - -size_t FilteringExample::getCdrSerializedSize( - const FilteringExample& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - return current_alignment - initial_alignment; -} - - -void FilteringExample::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_sampleNumber; - -} - -void FilteringExample::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_sampleNumber; - - -} - - -bool FilteringExample::isKeyDefined() -{ - return false; -} - -void FilteringExample::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member sampleNumber - * @param _sampleNumber New value for member sampleNumber - */ -void FilteringExample::sampleNumber( - int32_t _sampleNumber) -{ - m_sampleNumber = _sampleNumber; -} - -/*! - * @brief This function returns the value of member sampleNumber - * @return Value of member sampleNumber - */ -int32_t FilteringExample::sampleNumber() const -{ - return m_sampleNumber; -} - -/*! - * @brief This function returns a reference to member sampleNumber - * @return Reference to member sampleNumber - */ -int32_t& FilteringExample::sampleNumber() -{ - return m_sampleNumber; -} - - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/Filtering/FilteringExamplev1.h b/examples/cpp/dds/Filtering/FilteringExamplev1.h deleted file mode 100644 index b7e6c2228c1..00000000000 --- a/examples/cpp/dds/Filtering/FilteringExamplev1.h +++ /dev/null @@ -1,216 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file FilteringExample.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#include - -#if FASTCDR_VERSION_MAJOR == 1 - -#ifndef _FAST_DDS_GENERATED_FILTERINGEXAMPLE_H_ -#define _FAST_DDS_GENERATED_FILTERINGEXAMPLE_H_ - - -#include - -#include -#include -#include -#include -#include -#include -#include - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define eProsima_user_DllExport -#endif // _WIN32 - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(FILTERINGEXAMPLE_SOURCE) -#define FILTERINGEXAMPLE_DllAPI __declspec( dllexport ) -#else -#define FILTERINGEXAMPLE_DllAPI __declspec( dllimport ) -#endif // FILTERINGEXAMPLE_SOURCE -#else -#define FILTERINGEXAMPLE_DllAPI -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define FILTERINGEXAMPLE_DllAPI -#endif // _WIN32 - -namespace eprosima { -namespace fastcdr { -class Cdr; -} // namespace fastcdr -} // namespace eprosima - - - - - -/*! - * @brief This class represents the structure FilteringExample defined by the user in the IDL file. - * @ingroup FilteringExample - */ -class FilteringExample -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport FilteringExample(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~FilteringExample(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object FilteringExample that will be copied. - */ - eProsima_user_DllExport FilteringExample( - const FilteringExample& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object FilteringExample that will be copied. - */ - eProsima_user_DllExport FilteringExample( - FilteringExample&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object FilteringExample that will be copied. - */ - eProsima_user_DllExport FilteringExample& operator =( - const FilteringExample& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object FilteringExample that will be copied. - */ - eProsima_user_DllExport FilteringExample& operator =( - FilteringExample&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x FilteringExample object to compare. - */ - eProsima_user_DllExport bool operator ==( - const FilteringExample& x) const; - - /*! - * @brief Comparison operator. - * @param x FilteringExample object to compare. - */ - eProsima_user_DllExport bool operator !=( - const FilteringExample& x) const; - - /*! - * @brief This function sets a value in member sampleNumber - * @param _sampleNumber New value for member sampleNumber - */ - eProsima_user_DllExport void sampleNumber( - int32_t _sampleNumber); - - /*! - * @brief This function returns the value of member sampleNumber - * @return Value of member sampleNumber - */ - eProsima_user_DllExport int32_t sampleNumber() const; - - /*! - * @brief This function returns a reference to member sampleNumber - * @return Reference to member sampleNumber - */ - eProsima_user_DllExport int32_t& sampleNumber(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const FilteringExample& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - int32_t m_sampleNumber; - -}; - - -#endif // _FAST_DDS_GENERATED_FILTERINGEXAMPLE_H_ - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/FlowControlExample/CMakeLists.txt b/examples/cpp/dds/FlowControlExample/CMakeLists.txt index e321364d0e4..09fddb094bf 100644 --- a/examples/cpp/dds/FlowControlExample/CMakeLists.txt +++ b/examples/cpp/dds/FlowControlExample/CMakeLists.txt @@ -25,8 +25,8 @@ if(NOT foonathan_memory_FOUND) find_package(foonathan_memory REQUIRED) endif() -if(NOT fastrtps_FOUND) - find_package(fastrtps 2.12 REQUIRED) +if(NOT fastdds_FOUND) + find_package(fastdds 3 REQUIRED) endif() #Check C++11 @@ -47,6 +47,6 @@ target_compile_definitions(DDSFlowControlExample PRIVATE $<$>,$>:__DEBUG> $<$:__INTERNALDEBUG> # Internal debug activated. ) -target_link_libraries(DDSFlowControlExample fastrtps fastcdr foonathan_memory) +target_link_libraries(DDSFlowControlExample fastdds fastcdr foonathan_memory) install(TARGETS DDSFlowControlExample RUNTIME DESTINATION examples/cpp/dds/FlowControlExample/${BIN_INSTALL_DIR}) diff --git a/examples/cpp/dds/FlowControlExample/FlowControlExample.cxx b/examples/cpp/dds/FlowControlExample/FlowControlExample.cxx deleted file mode 100644 index c38d02771de..00000000000 --- a/examples/cpp/dds/FlowControlExample/FlowControlExample.cxx +++ /dev/null @@ -1,168 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file FlowControlExample.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "FlowControlExample.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - - - - -FlowControlExample::FlowControlExample() -{ -} - -FlowControlExample::~FlowControlExample() -{ -} - -FlowControlExample::FlowControlExample( - const FlowControlExample& x) -{ - m_message = x.m_message; - m_wasFast = x.m_wasFast; -} - -FlowControlExample::FlowControlExample( - FlowControlExample&& x) noexcept -{ - m_message = std::move(x.m_message); - m_wasFast = x.m_wasFast; -} - -FlowControlExample& FlowControlExample::operator =( - const FlowControlExample& x) -{ - - m_message = x.m_message; - m_wasFast = x.m_wasFast; - return *this; -} - -FlowControlExample& FlowControlExample::operator =( - FlowControlExample&& x) noexcept -{ - - m_message = std::move(x.m_message); - m_wasFast = x.m_wasFast; - return *this; -} - -bool FlowControlExample::operator ==( - const FlowControlExample& x) const -{ - return (m_message == x.m_message && - m_wasFast == x.m_wasFast); -} - -bool FlowControlExample::operator !=( - const FlowControlExample& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ -void FlowControlExample::message( - const std::array& _message) -{ - m_message = _message; -} - -/*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ -void FlowControlExample::message( - std::array&& _message) -{ - m_message = std::move(_message); -} - -/*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ -const std::array& FlowControlExample::message() const -{ - return m_message; -} - -/*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ -std::array& FlowControlExample::message() -{ - return m_message; -} - - -/*! - * @brief This function sets a value in member wasFast - * @param _wasFast New value for member wasFast - */ -void FlowControlExample::wasFast( - char _wasFast) -{ - m_wasFast = _wasFast; -} - -/*! - * @brief This function returns the value of member wasFast - * @return Value of member wasFast - */ -char FlowControlExample::wasFast() const -{ - return m_wasFast; -} - -/*! - * @brief This function returns a reference to member wasFast - * @return Reference to member wasFast - */ -char& FlowControlExample::wasFast() -{ - return m_wasFast; -} - - -// Include auxiliary functions like for serializing/deserializing. -#include "FlowControlExampleCdrAux.ipp" - -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/FlowControlExample/FlowControlExample.h b/examples/cpp/dds/FlowControlExample/FlowControlExample.hpp similarity index 68% rename from examples/cpp/dds/FlowControlExample/FlowControlExample.h rename to examples/cpp/dds/FlowControlExample/FlowControlExample.hpp index f73d6e41c08..68bcb6de578 100644 --- a/examples/cpp/dds/FlowControlExample/FlowControlExample.h +++ b/examples/cpp/dds/FlowControlExample/FlowControlExample.hpp @@ -13,32 +13,18 @@ // limitations under the License. /*! - * @file FlowControlExample.h + * @file FlowControlExample.hpp * This header file contains the declaration of the described types in the IDL file. * * This file was generated by the tool fastddsgen. */ -#include -#include "FlowControlExamplev1.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#ifndef _FAST_DDS_GENERATED_FLOWCONTROLEXAMPLE_H_ -#define _FAST_DDS_GENERATED_FLOWCONTROLEXAMPLE_H_ +#ifndef _FAST_DDS_GENERATED_FLOWCONTROLEXAMPLE_HPP_ +#define _FAST_DDS_GENERATED_FLOWCONTROLEXAMPLE_HPP_ #include -#include #include -#include -#include -#include - -#include -#include -#include - - +#include #if defined(_WIN32) #if defined(EPROSIMA_USER_DLL_EXPORT) @@ -64,17 +50,6 @@ #define FLOWCONTROLEXAMPLE_DllAPI #endif // _WIN32 -namespace eprosima { -namespace fastcdr { -class Cdr; -class CdrSizeCalculator; -} // namespace fastcdr -} // namespace eprosima - - - - - /*! * @brief This class represents the structure FlowControlExample defined by the user in the IDL file. * @ingroup FlowControlExample @@ -86,80 +61,127 @@ class FlowControlExample /*! * @brief Default constructor. */ - eProsima_user_DllExport FlowControlExample(); + eProsima_user_DllExport FlowControlExample() + { + } /*! * @brief Default destructor. */ - eProsima_user_DllExport ~FlowControlExample(); + eProsima_user_DllExport ~FlowControlExample() + { + } /*! * @brief Copy constructor. * @param x Reference to the object FlowControlExample that will be copied. */ eProsima_user_DllExport FlowControlExample( - const FlowControlExample& x); + const FlowControlExample& x) + { + m_message = x.m_message; + + m_wasFast = x.m_wasFast; + + } /*! * @brief Move constructor. * @param x Reference to the object FlowControlExample that will be copied. */ eProsima_user_DllExport FlowControlExample( - FlowControlExample&& x) noexcept; + FlowControlExample&& x) noexcept + { + m_message = std::move(x.m_message); + m_wasFast = x.m_wasFast; + } /*! * @brief Copy assignment. * @param x Reference to the object FlowControlExample that will be copied. */ eProsima_user_DllExport FlowControlExample& operator =( - const FlowControlExample& x); + const FlowControlExample& x) + { + + m_message = x.m_message; + + m_wasFast = x.m_wasFast; + + return *this; + } /*! * @brief Move assignment. * @param x Reference to the object FlowControlExample that will be copied. */ eProsima_user_DllExport FlowControlExample& operator =( - FlowControlExample&& x) noexcept; + FlowControlExample&& x) noexcept + { + + m_message = std::move(x.m_message); + m_wasFast = x.m_wasFast; + return *this; + } /*! * @brief Comparison operator. * @param x FlowControlExample object to compare. */ eProsima_user_DllExport bool operator ==( - const FlowControlExample& x) const; + const FlowControlExample& x) const + { + return (m_message == x.m_message && + m_wasFast == x.m_wasFast); + } /*! * @brief Comparison operator. * @param x FlowControlExample object to compare. */ eProsima_user_DllExport bool operator !=( - const FlowControlExample& x) const; + const FlowControlExample& x) const + { + return !(*this == x); + } /*! * @brief This function copies the value in member message * @param _message New value to be copied in member message */ eProsima_user_DllExport void message( - const std::array& _message); + const std::array& _message) + { + m_message = _message; + } /*! * @brief This function moves the value in member message * @param _message New value to be moved in member message */ eProsima_user_DllExport void message( - std::array&& _message); + std::array&& _message) + { + m_message = std::move(_message); + } /*! * @brief This function returns a constant reference to member message * @return Constant reference to member message */ - eProsima_user_DllExport const std::array& message() const; + eProsima_user_DllExport const std::array& message() const + { + return m_message; + } /*! * @brief This function returns a reference to member message * @return Reference to member message */ - eProsima_user_DllExport std::array& message(); + eProsima_user_DllExport std::array& message() + { + return m_message; + } /*! @@ -167,29 +189,38 @@ class FlowControlExample * @param _wasFast New value for member wasFast */ eProsima_user_DllExport void wasFast( - char _wasFast); + char _wasFast) + { + m_wasFast = _wasFast; + } /*! * @brief This function returns the value of member wasFast * @return Value of member wasFast */ - eProsima_user_DllExport char wasFast() const; + eProsima_user_DllExport char wasFast() const + { + return m_wasFast; + } /*! * @brief This function returns a reference to member wasFast * @return Reference to member wasFast */ - eProsima_user_DllExport char& wasFast(); + eProsima_user_DllExport char& wasFast() + { + return m_wasFast; + } + + private: - std::array m_message; + std::array m_message{0}; char m_wasFast{0}; }; -#endif // _FAST_DDS_GENERATED_FLOWCONTROLEXAMPLE_H_ - +#endif // _FAST_DDS_GENERATED_FLOWCONTROLEXAMPLE_HPP_ -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/FlowControlExample/FlowControlExampleCdrAux.hpp b/examples/cpp/dds/FlowControlExample/FlowControlExampleCdrAux.hpp index 4ef8e609e19..279a35713c0 100644 --- a/examples/cpp/dds/FlowControlExample/FlowControlExampleCdrAux.hpp +++ b/examples/cpp/dds/FlowControlExample/FlowControlExampleCdrAux.hpp @@ -22,7 +22,7 @@ #ifndef _FAST_DDS_GENERATED_FLOWCONTROLEXAMPLECDRAUX_HPP_ #define _FAST_DDS_GENERATED_FLOWCONTROLEXAMPLECDRAUX_HPP_ -#include "FlowControlExample.h" +#include "FlowControlExample.hpp" constexpr uint32_t FlowControlExample_max_cdr_typesize {600005UL}; constexpr uint32_t FlowControlExample_max_key_cdr_typesize {0UL}; @@ -34,8 +34,6 @@ namespace fastcdr { class Cdr; class CdrSizeCalculator; - - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const FlowControlExample& data); diff --git a/examples/cpp/dds/FlowControlExample/FlowControlExampleCdrAux.ipp b/examples/cpp/dds/FlowControlExample/FlowControlExampleCdrAux.ipp index 361c67ee3cf..f2f080c5235 100644 --- a/examples/cpp/dds/FlowControlExample/FlowControlExampleCdrAux.ipp +++ b/examples/cpp/dds/FlowControlExample/FlowControlExampleCdrAux.ipp @@ -34,8 +34,6 @@ using namespace eprosima::fastcdr::exception; namespace eprosima { namespace fastcdr { - - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, diff --git a/examples/cpp/dds/FlowControlExample/FlowControlExamplePubSubMain.cxx b/examples/cpp/dds/FlowControlExample/FlowControlExamplePubSubMain.cxx index cf18ba9d55a..a696c5d9d0e 100644 --- a/examples/cpp/dds/FlowControlExample/FlowControlExamplePubSubMain.cxx +++ b/examples/cpp/dds/FlowControlExample/FlowControlExamplePubSubMain.cxx @@ -19,14 +19,9 @@ * This file was generated by the tool fastcdrgen. */ - #include "FlowControlExamplePublisher.h" #include "FlowControlExampleSubscriber.h" - -#include -#include - using namespace eprosima; using namespace eprosima::fastrtps; diff --git a/examples/cpp/dds/FlowControlExample/FlowControlExamplePubSubTypes.cxx b/examples/cpp/dds/FlowControlExample/FlowControlExamplePubSubTypes.cxx index 1d375cfbfe3..9267a718200 100644 --- a/examples/cpp/dds/FlowControlExample/FlowControlExamplePubSubTypes.cxx +++ b/examples/cpp/dds/FlowControlExample/FlowControlExamplePubSubTypes.cxx @@ -19,18 +19,18 @@ * This file was generated by the tool fastddsgen. */ +#include "FlowControlExamplePubSubTypes.h" +#include #include -#include "FlowControlExamplePubSubTypes.h" #include "FlowControlExampleCdrAux.hpp" +#include "FlowControlExampleTypeObjectSupport.hpp" using SerializedPayload_t = eprosima::fastrtps::rtps::SerializedPayload_t; using InstanceHandle_t = eprosima::fastrtps::rtps::InstanceHandle_t; using DataRepresentationId_t = eprosima::fastdds::dds::DataRepresentationId_t; - - FlowControlExamplePubSubType::FlowControlExamplePubSubType() { setName("FlowControlExample"); @@ -219,3 +219,11 @@ bool FlowControlExamplePubSubType::getKey( return true; } +void FlowControlExamplePubSubType::register_type_object_representation() const +{ + register_FlowControlExample_type_objects(); +} + + +// Include auxiliary functions like for serializing/deserializing. +#include "FlowControlExampleCdrAux.ipp" diff --git a/examples/cpp/dds/FlowControlExample/FlowControlExamplePubSubTypes.h b/examples/cpp/dds/FlowControlExample/FlowControlExamplePubSubTypes.h index f47b513e629..ce79bf04a31 100644 --- a/examples/cpp/dds/FlowControlExample/FlowControlExamplePubSubTypes.h +++ b/examples/cpp/dds/FlowControlExample/FlowControlExamplePubSubTypes.h @@ -27,9 +27,9 @@ #include #include #include -#include +#include -#include "FlowControlExample.h" +#include "FlowControlExample.hpp" #if !defined(GEN_API_VER) || (GEN_API_VER != 2) @@ -38,8 +38,6 @@ #endif // GEN_API_VER - - /*! * @brief This class represents the TopicDataType of the type FlowControlExample defined by the user in the IDL file. * @ingroup FlowControlExample @@ -90,6 +88,9 @@ class FlowControlExamplePubSubType : public eprosima::fastdds::dds::TopicDataTyp eProsima_user_DllExport void deleteData( void* data) override; + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + #ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED eProsima_user_DllExport inline bool is_bounded() const override { diff --git a/examples/cpp/dds/FlowControlExample/FlowControlExampleSubscriber.cxx b/examples/cpp/dds/FlowControlExample/FlowControlExampleSubscriber.cxx index ffff981281c..4edeba1b574 100644 --- a/examples/cpp/dds/FlowControlExample/FlowControlExampleSubscriber.cxx +++ b/examples/cpp/dds/FlowControlExample/FlowControlExampleSubscriber.cxx @@ -124,7 +124,7 @@ void FlowControlExampleSubscriber::SubListener::on_data_available( { SampleInfo info; FlowControlExample st; - if (reader->take_next_sample(&st, &info) == ReturnCode_t::RETCODE_OK) + if (reader->take_next_sample(&st, &info) == RETCODE_OK) { if (info.valid_data) { diff --git a/examples/cpp/dds/FlowControlExample/FlowControlExampleTypeObjectSupport.cxx b/examples/cpp/dds/FlowControlExample/FlowControlExampleTypeObjectSupport.cxx new file mode 100644 index 00000000000..b6383b89cc1 --- /dev/null +++ b/examples/cpp/dds/FlowControlExample/FlowControlExampleTypeObjectSupport.cxx @@ -0,0 +1,306 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file FlowControlExampleTypeObjectSupport.cxx + * Source file containing the implementation to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#include "FlowControlExampleTypeObjectSupport.hpp" + +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include + +#include "FlowControlExample.hpp" + + +using namespace eprosima::fastdds::dds::xtypes; + +void register_FlowControlExample_type_objects() +{ + static std::once_flag once_flag; + std::call_once(once_flag, []() + { + register_FlowControlExample_type_identifier(); + + }); +} + +void register_FlowControlExample_type_identifier() +{ + { + StructTypeFlag struct_flags_FlowControlExample = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::NOT_APPLIED, + false, false); + ReturnCode_t return_code_FlowControlExample; + TypeIdentifierPair type_ids_FlowControlExample; + QualifiedTypeName type_name_FlowControlExample = "FlowControlExample"; + eprosima::fastcdr::optional type_ann_builtin_FlowControlExample; + eprosima::fastcdr::optional ann_custom_FlowControlExample; + CompleteTypeDetail detail_FlowControlExample = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_FlowControlExample, ann_custom_FlowControlExample, type_name_FlowControlExample.to_string()); + CompleteStructHeader header_FlowControlExample; + header_FlowControlExample = TypeObjectUtils::build_complete_struct_header(TypeIdentifier(), detail_FlowControlExample); + CompleteStructMemberSeq member_seq_FlowControlExample; + { + return_code_FlowControlExample = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_array_char_600000", type_ids_FlowControlExample); + + if (return_code_FlowControlExample != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_FlowControlExample = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_char", type_ids_FlowControlExample); + + if (return_code_FlowControlExample != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Array element TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + TypeIdentifier* element_identifier_anonymous_array_char_600000 {nullptr}; + if (EK_COMPLETE == type_ids_FlowControlExample.type_identifier1()._d() || TK_NONE == type_ids_FlowControlExample.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_FlowControlExample.type_identifier1()._d() && + EK_COMPLETE == type_ids_FlowControlExample.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_FlowControlExample.type_identifier1()._d() && + EK_COMPLETE == type_ids_FlowControlExample.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_FlowControlExample.type_identifier1()._d() && + EK_COMPLETE == type_ids_FlowControlExample.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_FlowControlExample.type_identifier1()._d() && + EK_COMPLETE == type_ids_FlowControlExample.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_FlowControlExample.type_identifier1()._d() && + (EK_COMPLETE == type_ids_FlowControlExample.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_FlowControlExample.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_FlowControlExample.type_identifier1()._d() && + (EK_COMPLETE == type_ids_FlowControlExample.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_FlowControlExample.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_array_char_600000 = new TypeIdentifier(type_ids_FlowControlExample.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_FlowControlExample.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_FlowControlExample.type_identifier2()._d() && + EK_COMPLETE == type_ids_FlowControlExample.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_FlowControlExample.type_identifier2()._d() && + EK_COMPLETE == type_ids_FlowControlExample.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_FlowControlExample.type_identifier2()._d() && + EK_COMPLETE == type_ids_FlowControlExample.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_FlowControlExample.type_identifier2()._d() && + EK_COMPLETE == type_ids_FlowControlExample.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_FlowControlExample.type_identifier2()._d() && + (EK_COMPLETE == type_ids_FlowControlExample.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_FlowControlExample.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_FlowControlExample.type_identifier2()._d() && + (EK_COMPLETE == type_ids_FlowControlExample.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_FlowControlExample.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_array_char_600000 = new TypeIdentifier(type_ids_FlowControlExample.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Array element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_array_char_600000 = EK_COMPLETE; + if (TK_NONE == type_ids_FlowControlExample.type_identifier2()._d()) + { + equiv_kind_anonymous_array_char_600000 = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_array_char_600000 = 0; + PlainCollectionHeader header_anonymous_array_char_600000 = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_array_char_600000, element_flags_anonymous_array_char_600000); + std::string type_id_kind_anonymous_array_char_600000("TI_PLAIN_ARRAY_LARGE"); + if (type_id_kind_anonymous_array_char_600000 == "TI_PLAIN_ARRAY_SMALL") + { + SBoundSeq array_bound_seq; + TypeObjectUtils::add_array_dimension(array_bound_seq, static_cast(600000)); + + PlainArraySElemDefn array_sdefn = TypeObjectUtils::build_plain_array_s_elem_defn(header_anonymous_array_char_600000, array_bound_seq, + eprosima::fastcdr::external(element_identifier_anonymous_array_char_600000)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_array_type_identifier(array_sdefn, "anonymous_array_char_600000")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_char_600000 already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBoundSeq array_bound_seq; + TypeObjectUtils::add_array_dimension(array_bound_seq, static_cast(600000)); + + PlainArrayLElemDefn array_ldefn = TypeObjectUtils::build_plain_array_l_elem_defn(header_anonymous_array_char_600000, array_bound_seq, + eprosima::fastcdr::external(element_identifier_anonymous_array_char_600000)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_array_type_identifier(array_ldefn, "anonymous_array_char_600000")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_char_600000 already registered in TypeObjectRegistry for a different type."); + } + } + return_code_FlowControlExample = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_array_char_600000", type_ids_FlowControlExample); + if (return_code_FlowControlExample != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_char_600000: Given Array TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_message = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_message; + MemberId member_id_message = 0x00000000; + if (EK_COMPLETE == type_ids_FlowControlExample.type_identifier1()._d() || TK_NONE == type_ids_FlowControlExample.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_FlowControlExample.type_identifier1()._d() && + EK_COMPLETE == type_ids_FlowControlExample.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_FlowControlExample.type_identifier1()._d() && + EK_COMPLETE == type_ids_FlowControlExample.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_FlowControlExample.type_identifier1()._d() && + EK_COMPLETE == type_ids_FlowControlExample.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_FlowControlExample.type_identifier1()._d() && + EK_COMPLETE == type_ids_FlowControlExample.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_FlowControlExample.type_identifier1()._d() && + (EK_COMPLETE == type_ids_FlowControlExample.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_FlowControlExample.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_FlowControlExample.type_identifier1()._d() && + (EK_COMPLETE == type_ids_FlowControlExample.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_FlowControlExample.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_message = TypeObjectUtils::build_common_struct_member(member_id_message, member_flags_message, type_ids_FlowControlExample.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_FlowControlExample.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_FlowControlExample.type_identifier2()._d() && + EK_COMPLETE == type_ids_FlowControlExample.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_FlowControlExample.type_identifier2()._d() && + EK_COMPLETE == type_ids_FlowControlExample.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_FlowControlExample.type_identifier2()._d() && + EK_COMPLETE == type_ids_FlowControlExample.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_FlowControlExample.type_identifier2()._d() && + EK_COMPLETE == type_ids_FlowControlExample.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_FlowControlExample.type_identifier2()._d() && + (EK_COMPLETE == type_ids_FlowControlExample.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_FlowControlExample.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_FlowControlExample.type_identifier2()._d() && + (EK_COMPLETE == type_ids_FlowControlExample.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_FlowControlExample.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_message = TypeObjectUtils::build_common_struct_member(member_id_message, member_flags_message, type_ids_FlowControlExample.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure message member TypeIdentifier inconsistent."); + return; + } + MemberName name_message = "message"; + eprosima::fastcdr::optional member_ann_builtin_message; + ann_custom_FlowControlExample.reset(); + CompleteMemberDetail detail_message = TypeObjectUtils::build_complete_member_detail(name_message, member_ann_builtin_message, ann_custom_FlowControlExample); + CompleteStructMember member_message = TypeObjectUtils::build_complete_struct_member(common_message, detail_message); + TypeObjectUtils::add_complete_struct_member(member_seq_FlowControlExample, member_message); + } + { + return_code_FlowControlExample = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_char", type_ids_FlowControlExample); + + if (return_code_FlowControlExample != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "wasFast Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_wasFast = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_wasFast; + MemberId member_id_wasFast = 0x00000001; + if (EK_COMPLETE == type_ids_FlowControlExample.type_identifier1()._d() || TK_NONE == type_ids_FlowControlExample.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_FlowControlExample.type_identifier1()._d() && + EK_COMPLETE == type_ids_FlowControlExample.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_FlowControlExample.type_identifier1()._d() && + EK_COMPLETE == type_ids_FlowControlExample.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_FlowControlExample.type_identifier1()._d() && + EK_COMPLETE == type_ids_FlowControlExample.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_FlowControlExample.type_identifier1()._d() && + EK_COMPLETE == type_ids_FlowControlExample.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_FlowControlExample.type_identifier1()._d() && + (EK_COMPLETE == type_ids_FlowControlExample.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_FlowControlExample.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_FlowControlExample.type_identifier1()._d() && + (EK_COMPLETE == type_ids_FlowControlExample.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_FlowControlExample.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_wasFast = TypeObjectUtils::build_common_struct_member(member_id_wasFast, member_flags_wasFast, type_ids_FlowControlExample.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_FlowControlExample.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_FlowControlExample.type_identifier2()._d() && + EK_COMPLETE == type_ids_FlowControlExample.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_FlowControlExample.type_identifier2()._d() && + EK_COMPLETE == type_ids_FlowControlExample.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_FlowControlExample.type_identifier2()._d() && + EK_COMPLETE == type_ids_FlowControlExample.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_FlowControlExample.type_identifier2()._d() && + EK_COMPLETE == type_ids_FlowControlExample.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_FlowControlExample.type_identifier2()._d() && + (EK_COMPLETE == type_ids_FlowControlExample.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_FlowControlExample.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_FlowControlExample.type_identifier2()._d() && + (EK_COMPLETE == type_ids_FlowControlExample.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_FlowControlExample.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_wasFast = TypeObjectUtils::build_common_struct_member(member_id_wasFast, member_flags_wasFast, type_ids_FlowControlExample.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure wasFast member TypeIdentifier inconsistent."); + return; + } + MemberName name_wasFast = "wasFast"; + eprosima::fastcdr::optional member_ann_builtin_wasFast; + ann_custom_FlowControlExample.reset(); + CompleteMemberDetail detail_wasFast = TypeObjectUtils::build_complete_member_detail(name_wasFast, member_ann_builtin_wasFast, ann_custom_FlowControlExample); + CompleteStructMember member_wasFast = TypeObjectUtils::build_complete_struct_member(common_wasFast, detail_wasFast); + TypeObjectUtils::add_complete_struct_member(member_seq_FlowControlExample, member_wasFast); + } + CompleteStructType struct_type_FlowControlExample = TypeObjectUtils::build_complete_struct_type(struct_flags_FlowControlExample, header_FlowControlExample, member_seq_FlowControlExample); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_struct_type_object(struct_type_FlowControlExample, type_name_FlowControlExample.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "FlowControlExample already registered in TypeObjectRegistry for a different type."); + } + return_code_FlowControlExample = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "FlowControlExample", type_ids_FlowControlExample); + if (return_code_FlowControlExample != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "FlowControlExample: Given Struct TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } +} + diff --git a/examples/cpp/dds/FlowControlExample/FlowControlExampleTypeObjectSupport.hpp b/examples/cpp/dds/FlowControlExample/FlowControlExampleTypeObjectSupport.hpp new file mode 100644 index 00000000000..7caf86c114a --- /dev/null +++ b/examples/cpp/dds/FlowControlExample/FlowControlExampleTypeObjectSupport.hpp @@ -0,0 +1,54 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file FlowControlExampleTypeObjectSupport.hpp + * Header file containing the API required to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#ifndef _FAST_DDS_GENERATED_FLOWCONTROLEXAMPLE_TYPE_OBJECT_SUPPORT_HPP_ +#define _FAST_DDS_GENERATED_FLOWCONTROLEXAMPLE_TYPE_OBJECT_SUPPORT_HPP_ + + +#if defined(_WIN32) +#if defined(EPROSIMA_USER_DLL_EXPORT) +#define eProsima_user_DllExport __declspec( dllexport ) +#else +#define eProsima_user_DllExport +#endif // EPROSIMA_USER_DLL_EXPORT +#else +#define eProsima_user_DllExport +#endif // _WIN32 + +/** + * @brief Register every TypeObject representation defined in the IDL file in Fast DDS TypeObjectRegistry. + */ +eProsima_user_DllExport void register_FlowControlExample_type_objects(); + +#ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +/** + * @brief Register FlowControlExample related TypeIdentifier. + * Fully-descriptive TypeIdentifiers are directly registered. + * Hash TypeIdentifiers require to fill the TypeObject information and hash it, consequently, the TypeObject is + * indirectly registered as well. + */ +void register_FlowControlExample_type_identifier(); + + +#endif // DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +#endif // _FAST_DDS_GENERATED_FLOWCONTROLEXAMPLE_TYPE_OBJECT_SUPPORT_HPP_ diff --git a/examples/cpp/dds/FlowControlExample/FlowControlExamplev1.cxx b/examples/cpp/dds/FlowControlExample/FlowControlExamplev1.cxx deleted file mode 100644 index 8da82aa6d10..00000000000 --- a/examples/cpp/dds/FlowControlExample/FlowControlExamplev1.cxx +++ /dev/null @@ -1,288 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file FlowControlExample.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "FlowControlExample.h" - -#if FASTCDR_VERSION_MAJOR == 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - -namespace helper { namespace internal { - -enum class Size { - UInt8, - UInt16, - UInt32, - UInt64, -}; - -constexpr Size get_size(int s) { - return (s <= 8 ) ? Size::UInt8: - (s <= 16) ? Size::UInt16: - (s <= 32) ? Size::UInt32: Size::UInt64; -} - -template -struct FindTypeH; - -template<> -struct FindTypeH { - using type = std::uint8_t; -}; - -template<> -struct FindTypeH { - using type = std::uint16_t; -}; - -template<> -struct FindTypeH { - using type = std::uint32_t; -}; - -template<> -struct FindTypeH { - using type = std::uint64_t; -}; -} - -template -struct FindType { - using type = typename internal::FindTypeH::type; -}; -} - -#define FlowControlExample_max_cdr_typesize 600005ULL; - - - - -FlowControlExample::FlowControlExample() -{ - // char m_message - memset(&m_message, 0, ((600000)) * 1); - // char m_wasFast - m_wasFast = 0; - -} - -FlowControlExample::~FlowControlExample() -{ -} - -FlowControlExample::FlowControlExample( - const FlowControlExample& x) -{ - m_message = x.m_message; - - - m_wasFast = x.m_wasFast; - -} - -FlowControlExample::FlowControlExample( - FlowControlExample&& x) noexcept -{ - m_message = std::move(x.m_message); - - - m_wasFast = x.m_wasFast; - -} - -FlowControlExample& FlowControlExample::operator =( - const FlowControlExample& x) -{ - m_message = x.m_message; - - - m_wasFast = x.m_wasFast; - - return *this; -} - -FlowControlExample& FlowControlExample::operator =( - FlowControlExample&& x) noexcept -{ - m_message = std::move(x.m_message); - - - m_wasFast = x.m_wasFast; - - return *this; -} - -bool FlowControlExample::operator ==( - const FlowControlExample& x) const -{ - return (m_message == x.m_message && - m_wasFast == x.m_wasFast); -} - -bool FlowControlExample::operator !=( - const FlowControlExample& x) const -{ - return !(*this == x); -} - -size_t FlowControlExample::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return FlowControlExample_max_cdr_typesize; -} - -size_t FlowControlExample::getCdrSerializedSize( - const FlowControlExample& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += (((600000)) * 1) + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - return current_alignment - initial_alignment; -} - - -void FlowControlExample::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_message; - - - scdr << m_wasFast; - -} - -void FlowControlExample::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_message; - - - - dcdr >> m_wasFast; - - -} - - -bool FlowControlExample::isKeyDefined() -{ - return false; -} - -void FlowControlExample::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ -void FlowControlExample::message( - const std::array& _message) -{ - m_message = _message; -} - -/*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ -void FlowControlExample::message( - std::array&& _message) -{ - m_message = std::move(_message); -} - -/*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ -const std::array& FlowControlExample::message() const -{ - return m_message; -} - -/*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ -std::array& FlowControlExample::message() -{ - return m_message; -} - - -/*! - * @brief This function sets a value in member wasFast - * @param _wasFast New value for member wasFast - */ -void FlowControlExample::wasFast( - char _wasFast) -{ - m_wasFast = _wasFast; -} - -/*! - * @brief This function returns the value of member wasFast - * @return Value of member wasFast - */ -char FlowControlExample::wasFast() const -{ - return m_wasFast; -} - -/*! - * @brief This function returns a reference to member wasFast - * @return Reference to member wasFast - */ -char& FlowControlExample::wasFast() -{ - return m_wasFast; -} - - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/FlowControlExample/FlowControlExamplev1.h b/examples/cpp/dds/FlowControlExample/FlowControlExamplev1.h deleted file mode 100644 index f72b0a10dae..00000000000 --- a/examples/cpp/dds/FlowControlExample/FlowControlExamplev1.h +++ /dev/null @@ -1,244 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file FlowControlExample.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#include - -#if FASTCDR_VERSION_MAJOR == 1 - -#ifndef _FAST_DDS_GENERATED_FLOWCONTROLEXAMPLE_H_ -#define _FAST_DDS_GENERATED_FLOWCONTROLEXAMPLE_H_ - - -#include - -#include -#include -#include -#include -#include -#include -#include - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define eProsima_user_DllExport -#endif // _WIN32 - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(FLOWCONTROLEXAMPLE_SOURCE) -#define FLOWCONTROLEXAMPLE_DllAPI __declspec( dllexport ) -#else -#define FLOWCONTROLEXAMPLE_DllAPI __declspec( dllimport ) -#endif // FLOWCONTROLEXAMPLE_SOURCE -#else -#define FLOWCONTROLEXAMPLE_DllAPI -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define FLOWCONTROLEXAMPLE_DllAPI -#endif // _WIN32 - -namespace eprosima { -namespace fastcdr { -class Cdr; -} // namespace fastcdr -} // namespace eprosima - - - - - -/*! - * @brief This class represents the structure FlowControlExample defined by the user in the IDL file. - * @ingroup FlowControlExample - */ -class FlowControlExample -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport FlowControlExample(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~FlowControlExample(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object FlowControlExample that will be copied. - */ - eProsima_user_DllExport FlowControlExample( - const FlowControlExample& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object FlowControlExample that will be copied. - */ - eProsima_user_DllExport FlowControlExample( - FlowControlExample&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object FlowControlExample that will be copied. - */ - eProsima_user_DllExport FlowControlExample& operator =( - const FlowControlExample& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object FlowControlExample that will be copied. - */ - eProsima_user_DllExport FlowControlExample& operator =( - FlowControlExample&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x FlowControlExample object to compare. - */ - eProsima_user_DllExport bool operator ==( - const FlowControlExample& x) const; - - /*! - * @brief Comparison operator. - * @param x FlowControlExample object to compare. - */ - eProsima_user_DllExport bool operator !=( - const FlowControlExample& x) const; - - /*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ - eProsima_user_DllExport void message( - const std::array& _message); - - /*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ - eProsima_user_DllExport void message( - std::array&& _message); - - /*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ - eProsima_user_DllExport const std::array& message() const; - - /*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ - eProsima_user_DllExport std::array& message(); - - - /*! - * @brief This function sets a value in member wasFast - * @param _wasFast New value for member wasFast - */ - eProsima_user_DllExport void wasFast( - char _wasFast); - - /*! - * @brief This function returns the value of member wasFast - * @return Value of member wasFast - */ - eProsima_user_DllExport char wasFast() const; - - /*! - * @brief This function returns a reference to member wasFast - * @return Reference to member wasFast - */ - eProsima_user_DllExport char& wasFast(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const FlowControlExample& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::array m_message; - char m_wasFast; - -}; - - -#endif // _FAST_DDS_GENERATED_FLOWCONTROLEXAMPLE_H_ - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/HelloWorldExample/CMakeLists.txt b/examples/cpp/dds/HelloWorldExample/CMakeLists.txt index 583847ee4f5..87fbf8dc2b4 100644 --- a/examples/cpp/dds/HelloWorldExample/CMakeLists.txt +++ b/examples/cpp/dds/HelloWorldExample/CMakeLists.txt @@ -21,8 +21,8 @@ if(NOT fastcdr_FOUND) find_package(fastcdr 2 REQUIRED) endif() -if(NOT fastrtps_FOUND) - find_package(fastrtps 2.12 REQUIRED) +if(NOT fastdds_FOUND) + find_package(fastdds 3 REQUIRED) endif() #Check C++11 @@ -43,6 +43,6 @@ target_compile_definitions(DDSHelloWorldExample PRIVATE $<$>,$>:__DEBUG> $<$:__INTERNALDEBUG> # Internal debug activated. ) -target_link_libraries(DDSHelloWorldExample fastrtps fastcdr fastdds::optionparser) +target_link_libraries(DDSHelloWorldExample fastdds fastcdr fastdds::optionparser) install(TARGETS DDSHelloWorldExample RUNTIME DESTINATION examples/cpp/dds/HelloWorldExample/${BIN_INSTALL_DIR}) diff --git a/examples/cpp/dds/HelloWorldExample/HelloWorld.cxx b/examples/cpp/dds/HelloWorldExample/HelloWorld.cxx deleted file mode 100644 index 4b415d67769..00000000000 --- a/examples/cpp/dds/HelloWorldExample/HelloWorld.cxx +++ /dev/null @@ -1,168 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file HelloWorld.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "HelloWorld.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - - - - -HelloWorld::HelloWorld() -{ -} - -HelloWorld::~HelloWorld() -{ -} - -HelloWorld::HelloWorld( - const HelloWorld& x) -{ - m_index = x.m_index; - m_message = x.m_message; -} - -HelloWorld::HelloWorld( - HelloWorld&& x) noexcept -{ - m_index = x.m_index; - m_message = std::move(x.m_message); -} - -HelloWorld& HelloWorld::operator =( - const HelloWorld& x) -{ - - m_index = x.m_index; - m_message = x.m_message; - return *this; -} - -HelloWorld& HelloWorld::operator =( - HelloWorld&& x) noexcept -{ - - m_index = x.m_index; - m_message = std::move(x.m_message); - return *this; -} - -bool HelloWorld::operator ==( - const HelloWorld& x) const -{ - return (m_index == x.m_index && - m_message == x.m_message); -} - -bool HelloWorld::operator !=( - const HelloWorld& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void HelloWorld::index( - uint32_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint32_t HelloWorld::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint32_t& HelloWorld::index() -{ - return m_index; -} - - -/*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ -void HelloWorld::message( - const std::string& _message) -{ - m_message = _message; -} - -/*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ -void HelloWorld::message( - std::string&& _message) -{ - m_message = std::move(_message); -} - -/*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ -const std::string& HelloWorld::message() const -{ - return m_message; -} - -/*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ -std::string& HelloWorld::message() -{ - return m_message; -} - - -// Include auxiliary functions like for serializing/deserializing. -#include "HelloWorldCdrAux.ipp" - -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/ContentFilteredTopicExample/HelloWorld.h b/examples/cpp/dds/HelloWorldExample/HelloWorld.hpp similarity index 69% rename from examples/cpp/dds/ContentFilteredTopicExample/HelloWorld.h rename to examples/cpp/dds/HelloWorldExample/HelloWorld.hpp index 5cd0ddba511..971fea8d920 100644 --- a/examples/cpp/dds/ContentFilteredTopicExample/HelloWorld.h +++ b/examples/cpp/dds/HelloWorldExample/HelloWorld.hpp @@ -13,32 +13,19 @@ // limitations under the License. /*! - * @file HelloWorld.h + * @file HelloWorld.hpp * This header file contains the declaration of the described types in the IDL file. * * This file was generated by the tool fastddsgen. */ -#include -#include "HelloWorldv1.h" +#ifndef _FAST_DDS_GENERATED_HELLOWORLD_HPP_ +#define _FAST_DDS_GENERATED_HELLOWORLD_HPP_ -#if FASTCDR_VERSION_MAJOR > 1 - -#ifndef _FAST_DDS_GENERATED_HELLOWORLD_H_ -#define _FAST_DDS_GENERATED_HELLOWORLD_H_ - -#include -#include #include -#include #include -#include - +#include #include -#include -#include - - #if defined(_WIN32) #if defined(EPROSIMA_USER_DLL_EXPORT) @@ -64,17 +51,6 @@ #define HELLOWORLD_DllAPI #endif // _WIN32 -namespace eprosima { -namespace fastcdr { -class Cdr; -class CdrSizeCalculator; -} // namespace fastcdr -} // namespace eprosima - - - - - /*! * @brief This class represents the structure HelloWorld defined by the user in the IDL file. * @ingroup HelloWorld @@ -86,73 +62,117 @@ class HelloWorld /*! * @brief Default constructor. */ - eProsima_user_DllExport HelloWorld(); + eProsima_user_DllExport HelloWorld() + { + } /*! * @brief Default destructor. */ - eProsima_user_DllExport ~HelloWorld(); + eProsima_user_DllExport ~HelloWorld() + { + } /*! * @brief Copy constructor. * @param x Reference to the object HelloWorld that will be copied. */ eProsima_user_DllExport HelloWorld( - const HelloWorld& x); + const HelloWorld& x) + { + m_index = x.m_index; + + m_message = x.m_message; + + } /*! * @brief Move constructor. * @param x Reference to the object HelloWorld that will be copied. */ eProsima_user_DllExport HelloWorld( - HelloWorld&& x) noexcept; + HelloWorld&& x) noexcept + { + m_index = x.m_index; + m_message = std::move(x.m_message); + } /*! * @brief Copy assignment. * @param x Reference to the object HelloWorld that will be copied. */ eProsima_user_DllExport HelloWorld& operator =( - const HelloWorld& x); + const HelloWorld& x) + { + + m_index = x.m_index; + + m_message = x.m_message; + + return *this; + } /*! * @brief Move assignment. * @param x Reference to the object HelloWorld that will be copied. */ eProsima_user_DllExport HelloWorld& operator =( - HelloWorld&& x) noexcept; + HelloWorld&& x) noexcept + { + + m_index = x.m_index; + m_message = std::move(x.m_message); + return *this; + } /*! * @brief Comparison operator. * @param x HelloWorld object to compare. */ eProsima_user_DllExport bool operator ==( - const HelloWorld& x) const; + const HelloWorld& x) const + { + return (m_index == x.m_index && + m_message == x.m_message); + } /*! * @brief Comparison operator. * @param x HelloWorld object to compare. */ eProsima_user_DllExport bool operator !=( - const HelloWorld& x) const; + const HelloWorld& x) const + { + return !(*this == x); + } /*! * @brief This function sets a value in member index * @param _index New value for member index */ eProsima_user_DllExport void index( - uint32_t _index); + uint32_t _index) + { + m_index = _index; + } /*! * @brief This function returns the value of member index * @return Value of member index */ - eProsima_user_DllExport uint32_t index() const; + eProsima_user_DllExport uint32_t index() const + { + return m_index; + } /*! * @brief This function returns a reference to member index * @return Reference to member index */ - eProsima_user_DllExport uint32_t& index(); + eProsima_user_DllExport uint32_t& index() + { + return m_index; + } /*! @@ -160,26 +180,40 @@ class HelloWorld * @param _message New value to be copied in member message */ eProsima_user_DllExport void message( - const std::string& _message); + const std::string& _message) + { + m_message = _message; + } /*! * @brief This function moves the value in member message * @param _message New value to be moved in member message */ eProsima_user_DllExport void message( - std::string&& _message); + std::string&& _message) + { + m_message = std::move(_message); + } /*! * @brief This function returns a constant reference to member message * @return Constant reference to member message */ - eProsima_user_DllExport const std::string& message() const; + eProsima_user_DllExport const std::string& message() const + { + return m_message; + } /*! * @brief This function returns a reference to member message * @return Reference to member message */ - eProsima_user_DllExport std::string& message(); + eProsima_user_DllExport std::string& message() + { + return m_message; + } + + private: @@ -188,8 +222,6 @@ class HelloWorld }; -#endif // _FAST_DDS_GENERATED_HELLOWORLD_H_ - +#endif // _FAST_DDS_GENERATED_HELLOWORLD_HPP_ -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/HelloWorldExample/HelloWorldCdrAux.hpp b/examples/cpp/dds/HelloWorldExample/HelloWorldCdrAux.hpp index 9f346d306be..6feb8a9da15 100644 --- a/examples/cpp/dds/HelloWorldExample/HelloWorldCdrAux.hpp +++ b/examples/cpp/dds/HelloWorldExample/HelloWorldCdrAux.hpp @@ -22,7 +22,7 @@ #ifndef _FAST_DDS_GENERATED_HELLOWORLDCDRAUX_HPP_ #define _FAST_DDS_GENERATED_HELLOWORLDCDRAUX_HPP_ -#include "HelloWorld.h" +#include "HelloWorld.hpp" constexpr uint32_t HelloWorld_max_cdr_typesize {268UL}; constexpr uint32_t HelloWorld_max_key_cdr_typesize {0UL}; @@ -34,8 +34,6 @@ namespace fastcdr { class Cdr; class CdrSizeCalculator; - - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const HelloWorld& data); diff --git a/examples/cpp/dds/HelloWorldExample/HelloWorldCdrAux.ipp b/examples/cpp/dds/HelloWorldExample/HelloWorldCdrAux.ipp index 42e91f3cc38..97df3fe9d9e 100644 --- a/examples/cpp/dds/HelloWorldExample/HelloWorldCdrAux.ipp +++ b/examples/cpp/dds/HelloWorldExample/HelloWorldCdrAux.ipp @@ -34,8 +34,6 @@ using namespace eprosima::fastcdr::exception; namespace eprosima { namespace fastcdr { - - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, diff --git a/examples/cpp/dds/HelloWorldExample/HelloWorldPubSubTypes.cxx b/examples/cpp/dds/HelloWorldExample/HelloWorldPubSubTypes.cxx index 85cb477896e..db018e69782 100644 --- a/examples/cpp/dds/HelloWorldExample/HelloWorldPubSubTypes.cxx +++ b/examples/cpp/dds/HelloWorldExample/HelloWorldPubSubTypes.cxx @@ -19,18 +19,18 @@ * This file was generated by the tool fastddsgen. */ +#include "HelloWorldPubSubTypes.h" +#include #include -#include "HelloWorldPubSubTypes.h" #include "HelloWorldCdrAux.hpp" +#include "HelloWorldTypeObjectSupport.hpp" using SerializedPayload_t = eprosima::fastrtps::rtps::SerializedPayload_t; using InstanceHandle_t = eprosima::fastrtps::rtps::InstanceHandle_t; using DataRepresentationId_t = eprosima::fastdds::dds::DataRepresentationId_t; - - HelloWorldPubSubType::HelloWorldPubSubType() { setName("HelloWorld"); @@ -219,3 +219,11 @@ bool HelloWorldPubSubType::getKey( return true; } +void HelloWorldPubSubType::register_type_object_representation() const +{ + register_HelloWorld_type_objects(); +} + + +// Include auxiliary functions like for serializing/deserializing. +#include "HelloWorldCdrAux.ipp" diff --git a/examples/cpp/dds/HelloWorldExample/HelloWorldPubSubTypes.h b/examples/cpp/dds/HelloWorldExample/HelloWorldPubSubTypes.h index cb61cd6ba23..a9b4ac119e0 100644 --- a/examples/cpp/dds/HelloWorldExample/HelloWorldPubSubTypes.h +++ b/examples/cpp/dds/HelloWorldExample/HelloWorldPubSubTypes.h @@ -27,9 +27,9 @@ #include #include #include -#include +#include -#include "HelloWorld.h" +#include "HelloWorld.hpp" #if !defined(GEN_API_VER) || (GEN_API_VER != 2) @@ -38,8 +38,6 @@ #endif // GEN_API_VER - - /*! * @brief This class represents the TopicDataType of the type HelloWorld defined by the user in the IDL file. * @ingroup HelloWorld @@ -90,6 +88,9 @@ class HelloWorldPubSubType : public eprosima::fastdds::dds::TopicDataType eProsima_user_DllExport void deleteData( void* data) override; + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + #ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED eProsima_user_DllExport inline bool is_bounded() const override { diff --git a/examples/cpp/dds/HelloWorldExample/HelloWorldPublisher.cpp b/examples/cpp/dds/HelloWorldExample/HelloWorldPublisher.cpp index 86f3e0009f5..1a2bdfce472 100644 --- a/examples/cpp/dds/HelloWorldExample/HelloWorldPublisher.cpp +++ b/examples/cpp/dds/HelloWorldExample/HelloWorldPublisher.cpp @@ -18,15 +18,14 @@ */ #include "HelloWorldPublisher.h" -#include -#include + +#include + #include -#include -#include #include +#include #include - -#include +#include using namespace eprosima::fastdds::dds; diff --git a/examples/cpp/dds/HelloWorldExample/HelloWorldSubscriber.cpp b/examples/cpp/dds/HelloWorldExample/HelloWorldSubscriber.cpp index 6823a32f4e6..680194c85b8 100644 --- a/examples/cpp/dds/HelloWorldExample/HelloWorldSubscriber.cpp +++ b/examples/cpp/dds/HelloWorldExample/HelloWorldSubscriber.cpp @@ -22,13 +22,11 @@ #include #include -#include -#include #include -#include #include -#include #include +#include +#include using namespace eprosima::fastdds::dds; @@ -158,7 +156,7 @@ void HelloWorldSubscriber::SubListener::on_data_available( DataReader* reader) { SampleInfo info; - if (reader->take_next_sample(&hello_, &info) == ReturnCode_t::RETCODE_OK) + if (reader->take_next_sample(&hello_, &info) == RETCODE_OK) { if (info.instance_state == ALIVE_INSTANCE_STATE) { diff --git a/examples/cpp/dds/HelloWorldExample/HelloWorldSubscriber.h b/examples/cpp/dds/HelloWorldExample/HelloWorldSubscriber.h index ecd897bd532..227198cf191 100644 --- a/examples/cpp/dds/HelloWorldExample/HelloWorldSubscriber.h +++ b/examples/cpp/dds/HelloWorldExample/HelloWorldSubscriber.h @@ -20,12 +20,12 @@ #ifndef HELLOWORLDSUBSCRIBER_H_ #define HELLOWORLDSUBSCRIBER_H_ -#include "HelloWorldPubSubTypes.h" - +#include #include #include -#include -#include +#include + +#include "HelloWorldPubSubTypes.h" class HelloWorldSubscriber { diff --git a/examples/cpp/dds/HelloWorldExample/HelloWorldTypeObjectSupport.cxx b/examples/cpp/dds/HelloWorldExample/HelloWorldTypeObjectSupport.cxx new file mode 100644 index 00000000000..bfae95694f4 --- /dev/null +++ b/examples/cpp/dds/HelloWorldExample/HelloWorldTypeObjectSupport.cxx @@ -0,0 +1,248 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file HelloWorldTypeObjectSupport.cxx + * Source file containing the implementation to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#include "HelloWorldTypeObjectSupport.hpp" + +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include + +#include "HelloWorld.hpp" + + +using namespace eprosima::fastdds::dds::xtypes; + +void register_HelloWorld_type_objects() +{ + static std::once_flag once_flag; + std::call_once(once_flag, []() + { + register_HelloWorld_type_identifier(); + + }); +} + +void register_HelloWorld_type_identifier() +{ + { + StructTypeFlag struct_flags_HelloWorld = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::NOT_APPLIED, + false, false); + ReturnCode_t return_code_HelloWorld; + TypeIdentifierPair type_ids_HelloWorld; + QualifiedTypeName type_name_HelloWorld = "HelloWorld"; + eprosima::fastcdr::optional type_ann_builtin_HelloWorld; + eprosima::fastcdr::optional ann_custom_HelloWorld; + CompleteTypeDetail detail_HelloWorld = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_HelloWorld, ann_custom_HelloWorld, type_name_HelloWorld.to_string()); + CompleteStructHeader header_HelloWorld; + header_HelloWorld = TypeObjectUtils::build_complete_struct_header(TypeIdentifier(), detail_HelloWorld); + CompleteStructMemberSeq member_seq_HelloWorld; + { + return_code_HelloWorld = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_uint32_t", type_ids_HelloWorld); + + if (return_code_HelloWorld != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "index Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_index = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_index; + MemberId member_id_index = 0x00000000; + if (EK_COMPLETE == type_ids_HelloWorld.type_identifier1()._d() || TK_NONE == type_ids_HelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_HelloWorld.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_HelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_HelloWorld.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure index member TypeIdentifier inconsistent."); + return; + } + MemberName name_index = "index"; + eprosima::fastcdr::optional member_ann_builtin_index; + ann_custom_HelloWorld.reset(); + CompleteMemberDetail detail_index = TypeObjectUtils::build_complete_member_detail(name_index, member_ann_builtin_index, ann_custom_HelloWorld); + CompleteStructMember member_index = TypeObjectUtils::build_complete_struct_member(common_index, detail_index); + TypeObjectUtils::add_complete_struct_member(member_seq_HelloWorld, member_index); + } + { + return_code_HelloWorld = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_string_unbounded", type_ids_HelloWorld); + + if (return_code_HelloWorld != eprosima::fastdds::dds::RETCODE_OK) + { + std::string type_id_kind_anonymous_string_unbounded("TI_STRING8_SMALL"); + if (type_id_kind_anonymous_string_unbounded == "TI_STRING8_SMALL") + { + SBound bound = 0; + StringSTypeDefn string_sdefn = TypeObjectUtils::build_string_s_type_defn(bound); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_string_type_identifier(string_sdefn, + "anonymous_string_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else if (type_id_kind_anonymous_string_unbounded == "TI_STRING8_LARGE") + { + LBound bound = 255; + StringLTypeDefn string_ldefn = TypeObjectUtils::build_string_l_type_defn(bound); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_string_type_identifier(string_ldefn, + "anonymous_string_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded: Unknown String kind."); + return; + } + return_code_HelloWorld = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_string_unbounded", type_ids_HelloWorld); + if (return_code_HelloWorld != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded: Given String TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_message = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_message; + MemberId member_id_message = 0x00000001; + if (EK_COMPLETE == type_ids_HelloWorld.type_identifier1()._d() || TK_NONE == type_ids_HelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_message = TypeObjectUtils::build_common_struct_member(member_id_message, member_flags_message, type_ids_HelloWorld.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_HelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_message = TypeObjectUtils::build_common_struct_member(member_id_message, member_flags_message, type_ids_HelloWorld.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure message member TypeIdentifier inconsistent."); + return; + } + MemberName name_message = "message"; + eprosima::fastcdr::optional member_ann_builtin_message; + ann_custom_HelloWorld.reset(); + CompleteMemberDetail detail_message = TypeObjectUtils::build_complete_member_detail(name_message, member_ann_builtin_message, ann_custom_HelloWorld); + CompleteStructMember member_message = TypeObjectUtils::build_complete_struct_member(common_message, detail_message); + TypeObjectUtils::add_complete_struct_member(member_seq_HelloWorld, member_message); + } + CompleteStructType struct_type_HelloWorld = TypeObjectUtils::build_complete_struct_type(struct_flags_HelloWorld, header_HelloWorld, member_seq_HelloWorld); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_struct_type_object(struct_type_HelloWorld, type_name_HelloWorld.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "HelloWorld already registered in TypeObjectRegistry for a different type."); + } + return_code_HelloWorld = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "HelloWorld", type_ids_HelloWorld); + if (return_code_HelloWorld != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "HelloWorld: Given Struct TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } +} + diff --git a/examples/cpp/dds/HelloWorldExample/HelloWorldTypeObjectSupport.hpp b/examples/cpp/dds/HelloWorldExample/HelloWorldTypeObjectSupport.hpp new file mode 100644 index 00000000000..8650fc061e0 --- /dev/null +++ b/examples/cpp/dds/HelloWorldExample/HelloWorldTypeObjectSupport.hpp @@ -0,0 +1,54 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file HelloWorldTypeObjectSupport.hpp + * Header file containing the API required to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#ifndef _FAST_DDS_GENERATED_HELLOWORLD_TYPE_OBJECT_SUPPORT_HPP_ +#define _FAST_DDS_GENERATED_HELLOWORLD_TYPE_OBJECT_SUPPORT_HPP_ + + +#if defined(_WIN32) +#if defined(EPROSIMA_USER_DLL_EXPORT) +#define eProsima_user_DllExport __declspec( dllexport ) +#else +#define eProsima_user_DllExport +#endif // EPROSIMA_USER_DLL_EXPORT +#else +#define eProsima_user_DllExport +#endif // _WIN32 + +/** + * @brief Register every TypeObject representation defined in the IDL file in Fast DDS TypeObjectRegistry. + */ +eProsima_user_DllExport void register_HelloWorld_type_objects(); + +#ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +/** + * @brief Register HelloWorld related TypeIdentifier. + * Fully-descriptive TypeIdentifiers are directly registered. + * Hash TypeIdentifiers require to fill the TypeObject information and hash it, consequently, the TypeObject is + * indirectly registered as well. + */ +void register_HelloWorld_type_identifier(); + + +#endif // DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +#endif // _FAST_DDS_GENERATED_HELLOWORLD_TYPE_OBJECT_SUPPORT_HPP_ diff --git a/examples/cpp/dds/HelloWorldExample/HelloWorld_main.cpp b/examples/cpp/dds/HelloWorldExample/HelloWorld_main.cpp index 35870eb670f..7a6fb595f09 100644 --- a/examples/cpp/dds/HelloWorldExample/HelloWorld_main.cpp +++ b/examples/cpp/dds/HelloWorldExample/HelloWorld_main.cpp @@ -20,14 +20,13 @@ #include #include -#include "HelloWorldPublisher.h" -#include "HelloWorldSubscriber.h" - #include -#include - +#include #include +#include "HelloWorldPublisher.h" +#include "HelloWorldSubscriber.h" + using eprosima::fastdds::dds::Log; namespace option = eprosima::option; diff --git a/examples/cpp/dds/HelloWorldExample/HelloWorldv1.cxx b/examples/cpp/dds/HelloWorldExample/HelloWorldv1.cxx deleted file mode 100644 index 90e82ea88a7..00000000000 --- a/examples/cpp/dds/HelloWorldExample/HelloWorldv1.cxx +++ /dev/null @@ -1,286 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file HelloWorld.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "HelloWorld.h" - -#if FASTCDR_VERSION_MAJOR == 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - -namespace helper { namespace internal { - -enum class Size { - UInt8, - UInt16, - UInt32, - UInt64, -}; - -constexpr Size get_size(int s) { - return (s <= 8 ) ? Size::UInt8: - (s <= 16) ? Size::UInt16: - (s <= 32) ? Size::UInt32: Size::UInt64; -} - -template -struct FindTypeH; - -template<> -struct FindTypeH { - using type = std::uint8_t; -}; - -template<> -struct FindTypeH { - using type = std::uint16_t; -}; - -template<> -struct FindTypeH { - using type = std::uint32_t; -}; - -template<> -struct FindTypeH { - using type = std::uint64_t; -}; -} - -template -struct FindType { - using type = typename internal::FindTypeH::type; -}; -} - -#define HelloWorld_max_cdr_typesize 268ULL; - - - - -HelloWorld::HelloWorld() -{ - // unsigned long m_index - m_index = 0; - // /type_d() m_message - - -} - -HelloWorld::~HelloWorld() -{ -} - -HelloWorld::HelloWorld( - const HelloWorld& x) -{ - m_index = x.m_index; - - - m_message = x.m_message; - -} - -HelloWorld::HelloWorld( - HelloWorld&& x) noexcept -{ - m_index = x.m_index; - - - m_message = std::move(x.m_message); - -} - -HelloWorld& HelloWorld::operator =( - const HelloWorld& x) -{ - m_index = x.m_index; - - - m_message = x.m_message; - - return *this; -} - -HelloWorld& HelloWorld::operator =( - HelloWorld&& x) noexcept -{ - m_index = x.m_index; - - - m_message = std::move(x.m_message); - - return *this; -} - -bool HelloWorld::operator ==( - const HelloWorld& x) const -{ - return (m_index == x.m_index && - m_message == x.m_message); -} - -bool HelloWorld::operator !=( - const HelloWorld& x) const -{ - return !(*this == x); -} - -size_t HelloWorld::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return HelloWorld_max_cdr_typesize; -} - -size_t HelloWorld::getCdrSerializedSize( - const HelloWorld& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + data.message().size() + 1; - - - return current_alignment - initial_alignment; -} - - -void HelloWorld::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_index; - - scdr << m_message.c_str(); - -} - -void HelloWorld::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_index; - - - - dcdr >> m_message; - - -} - - -bool HelloWorld::isKeyDefined() -{ - return false; -} - -void HelloWorld::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void HelloWorld::index( - uint32_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint32_t HelloWorld::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint32_t& HelloWorld::index() -{ - return m_index; -} - - -/*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ -void HelloWorld::message( - const std::string& _message) -{ - m_message = _message; -} - -/*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ -void HelloWorld::message( - std::string&& _message) -{ - m_message = std::move(_message); -} - -/*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ -const std::string& HelloWorld::message() const -{ - return m_message; -} - -/*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ -std::string& HelloWorld::message() -{ - return m_message; -} - - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/HelloWorldExample/HelloWorldv1.h b/examples/cpp/dds/HelloWorldExample/HelloWorldv1.h deleted file mode 100644 index 9f6f726e0ab..00000000000 --- a/examples/cpp/dds/HelloWorldExample/HelloWorldv1.h +++ /dev/null @@ -1,244 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file HelloWorld.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#include - -#if FASTCDR_VERSION_MAJOR == 1 - -#ifndef _FAST_DDS_GENERATED_HELLOWORLD_H_ -#define _FAST_DDS_GENERATED_HELLOWORLD_H_ - - -#include - -#include -#include -#include -#include -#include -#include -#include - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define eProsima_user_DllExport -#endif // _WIN32 - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(HELLOWORLD_SOURCE) -#define HELLOWORLD_DllAPI __declspec( dllexport ) -#else -#define HELLOWORLD_DllAPI __declspec( dllimport ) -#endif // HELLOWORLD_SOURCE -#else -#define HELLOWORLD_DllAPI -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define HELLOWORLD_DllAPI -#endif // _WIN32 - -namespace eprosima { -namespace fastcdr { -class Cdr; -} // namespace fastcdr -} // namespace eprosima - - - - - -/*! - * @brief This class represents the structure HelloWorld defined by the user in the IDL file. - * @ingroup HelloWorld - */ -class HelloWorld -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport HelloWorld(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~HelloWorld(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object HelloWorld that will be copied. - */ - eProsima_user_DllExport HelloWorld( - const HelloWorld& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object HelloWorld that will be copied. - */ - eProsima_user_DllExport HelloWorld( - HelloWorld&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object HelloWorld that will be copied. - */ - eProsima_user_DllExport HelloWorld& operator =( - const HelloWorld& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object HelloWorld that will be copied. - */ - eProsima_user_DllExport HelloWorld& operator =( - HelloWorld&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x HelloWorld object to compare. - */ - eProsima_user_DllExport bool operator ==( - const HelloWorld& x) const; - - /*! - * @brief Comparison operator. - * @param x HelloWorld object to compare. - */ - eProsima_user_DllExport bool operator !=( - const HelloWorld& x) const; - - /*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ - eProsima_user_DllExport void index( - uint32_t _index); - - /*! - * @brief This function returns the value of member index - * @return Value of member index - */ - eProsima_user_DllExport uint32_t index() const; - - /*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ - eProsima_user_DllExport uint32_t& index(); - - - /*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ - eProsima_user_DllExport void message( - const std::string& _message); - - /*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ - eProsima_user_DllExport void message( - std::string&& _message); - - /*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ - eProsima_user_DllExport const std::string& message() const; - - /*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ - eProsima_user_DllExport std::string& message(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const HelloWorld& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - uint32_t m_index; - std::string m_message; - -}; - - -#endif // _FAST_DDS_GENERATED_HELLOWORLD_H_ - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/HelloWorldExample/README.txt b/examples/cpp/dds/HelloWorldExample/README.txt index 2055de76c58..6e02448ed83 100644 --- a/examples/cpp/dds/HelloWorldExample/README.txt +++ b/examples/cpp/dds/HelloWorldExample/README.txt @@ -4,12 +4,12 @@ In the first one launch: ./DDSHelloWorldExample publisher (or DDSHelloWorldExamp In the second one: ./DDSHelloWorldExample subscriber (or DDSHelloWorldExample.exe subscriber on windows). In order to use xml profiles (--env or shorcut -e cli flags): - - reference the xml profiles file setting the environment variable FASTRTPS_DEFAULT_PROFILES_FILE to its path. - - name it DEFAULT_FASTRTPS_PROFILES.xml and make sure the file is besides the DDSHelloWorldExample binary. + - reference the xml profiles file setting the environment variable FASTDDS_DEFAULT_PROFILES_FILE to its path. + - name it DEFAULT_FASTDDS_PROFILES.xml and make sure the file is besides the DDSHelloWorldExample binary. The profile loaded will be the mark as default one with the corresponding attribute. For example: - + Profiles example name diff --git a/examples/cpp/dds/HelloWorldExampleDataSharing/CMakeLists.txt b/examples/cpp/dds/HelloWorldExampleDataSharing/CMakeLists.txt index 424624e354d..63830c19c42 100644 --- a/examples/cpp/dds/HelloWorldExampleDataSharing/CMakeLists.txt +++ b/examples/cpp/dds/HelloWorldExampleDataSharing/CMakeLists.txt @@ -21,8 +21,8 @@ if(NOT fastcdr_FOUND) find_package(fastcdr 2 REQUIRED) endif() -if(NOT fastrtps_FOUND) - find_package(fastrtps 2.12 REQUIRED) +if(NOT fastdds_FOUND) + find_package(fastdds 3 REQUIRED) endif() #Check C++11 @@ -41,6 +41,6 @@ file(GLOB DDS_HELLOWORLD_EXAMPLE_DATASHARING_SOURCES_CPP "*.cpp") add_executable(DDSHelloWorldExampleDataSharing ${DDS_HELLOWORLD_EXAMPLE_DATASHARING_SOURCES_CXX} ${DDS_HELLOWORLD_EXAMPLE_DATASHARING_SOURCES_CPP}) -target_link_libraries(DDSHelloWorldExampleDataSharing fastrtps fastcdr) +target_link_libraries(DDSHelloWorldExampleDataSharing fastdds fastcdr) install(TARGETS DDSHelloWorldExampleDataSharing RUNTIME DESTINATION examples/cpp/dds/HelloWorldExampleDataSharing/${BIN_INSTALL_DIR}) diff --git a/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorld.cxx b/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorld.cxx deleted file mode 100644 index 3622c2401de..00000000000 --- a/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorld.cxx +++ /dev/null @@ -1,168 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file HelloWorld.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "HelloWorld.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - - - - -HelloWorld::HelloWorld() -{ -} - -HelloWorld::~HelloWorld() -{ -} - -HelloWorld::HelloWorld( - const HelloWorld& x) -{ - m_index = x.m_index; - m_message = x.m_message; -} - -HelloWorld::HelloWorld( - HelloWorld&& x) noexcept -{ - m_index = x.m_index; - m_message = std::move(x.m_message); -} - -HelloWorld& HelloWorld::operator =( - const HelloWorld& x) -{ - - m_index = x.m_index; - m_message = x.m_message; - return *this; -} - -HelloWorld& HelloWorld::operator =( - HelloWorld&& x) noexcept -{ - - m_index = x.m_index; - m_message = std::move(x.m_message); - return *this; -} - -bool HelloWorld::operator ==( - const HelloWorld& x) const -{ - return (m_index == x.m_index && - m_message == x.m_message); -} - -bool HelloWorld::operator !=( - const HelloWorld& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void HelloWorld::index( - uint32_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint32_t HelloWorld::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint32_t& HelloWorld::index() -{ - return m_index; -} - - -/*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ -void HelloWorld::message( - const eprosima::fastcdr::fixed_string<20>& _message) -{ - m_message = _message; -} - -/*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ -void HelloWorld::message( - eprosima::fastcdr::fixed_string<20>&& _message) -{ - m_message = std::move(_message); -} - -/*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ -const eprosima::fastcdr::fixed_string<20>& HelloWorld::message() const -{ - return m_message; -} - -/*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ -eprosima::fastcdr::fixed_string<20>& HelloWorld::message() -{ - return m_message; -} - - -// Include auxiliary functions like for serializing/deserializing. -#include "HelloWorldCdrAux.ipp" - -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorld.h b/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorld.hpp similarity index 72% rename from examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorld.h rename to examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorld.hpp index 3488835aafe..22c4f7b2cda 100644 --- a/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorld.h +++ b/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorld.hpp @@ -13,32 +13,19 @@ // limitations under the License. /*! - * @file HelloWorld.h + * @file HelloWorld.hpp * This header file contains the declaration of the described types in the IDL file. * * This file was generated by the tool fastddsgen. */ -#include -#include "HelloWorldv1.h" +#ifndef _FAST_DDS_GENERATED_HELLOWORLD_HPP_ +#define _FAST_DDS_GENERATED_HELLOWORLD_HPP_ -#if FASTCDR_VERSION_MAJOR > 1 - -#ifndef _FAST_DDS_GENERATED_HELLOWORLD_H_ -#define _FAST_DDS_GENERATED_HELLOWORLD_H_ - -#include -#include #include -#include #include -#include - +#include #include -#include -#include - - #if defined(_WIN32) #if defined(EPROSIMA_USER_DLL_EXPORT) @@ -64,17 +51,6 @@ #define HELLOWORLD_DllAPI #endif // _WIN32 -namespace eprosima { -namespace fastcdr { -class Cdr; -class CdrSizeCalculator; -} // namespace fastcdr -} // namespace eprosima - - - - - /*! * @brief This class represents the structure HelloWorld defined by the user in the IDL file. * @ingroup HelloWorld @@ -86,73 +62,117 @@ class HelloWorld /*! * @brief Default constructor. */ - eProsima_user_DllExport HelloWorld(); + eProsima_user_DllExport HelloWorld() + { + } /*! * @brief Default destructor. */ - eProsima_user_DllExport ~HelloWorld(); + eProsima_user_DllExport ~HelloWorld() + { + } /*! * @brief Copy constructor. * @param x Reference to the object HelloWorld that will be copied. */ eProsima_user_DllExport HelloWorld( - const HelloWorld& x); + const HelloWorld& x) + { + m_index = x.m_index; + + m_message = x.m_message; + + } /*! * @brief Move constructor. * @param x Reference to the object HelloWorld that will be copied. */ eProsima_user_DllExport HelloWorld( - HelloWorld&& x) noexcept; + HelloWorld&& x) noexcept + { + m_index = x.m_index; + m_message = std::move(x.m_message); + } /*! * @brief Copy assignment. * @param x Reference to the object HelloWorld that will be copied. */ eProsima_user_DllExport HelloWorld& operator =( - const HelloWorld& x); + const HelloWorld& x) + { + + m_index = x.m_index; + + m_message = x.m_message; + + return *this; + } /*! * @brief Move assignment. * @param x Reference to the object HelloWorld that will be copied. */ eProsima_user_DllExport HelloWorld& operator =( - HelloWorld&& x) noexcept; + HelloWorld&& x) noexcept + { + + m_index = x.m_index; + m_message = std::move(x.m_message); + return *this; + } /*! * @brief Comparison operator. * @param x HelloWorld object to compare. */ eProsima_user_DllExport bool operator ==( - const HelloWorld& x) const; + const HelloWorld& x) const + { + return (m_index == x.m_index && + m_message == x.m_message); + } /*! * @brief Comparison operator. * @param x HelloWorld object to compare. */ eProsima_user_DllExport bool operator !=( - const HelloWorld& x) const; + const HelloWorld& x) const + { + return !(*this == x); + } /*! * @brief This function sets a value in member index * @param _index New value for member index */ eProsima_user_DllExport void index( - uint32_t _index); + uint32_t _index) + { + m_index = _index; + } /*! * @brief This function returns the value of member index * @return Value of member index */ - eProsima_user_DllExport uint32_t index() const; + eProsima_user_DllExport uint32_t index() const + { + return m_index; + } /*! * @brief This function returns a reference to member index * @return Reference to member index */ - eProsima_user_DllExport uint32_t& index(); + eProsima_user_DllExport uint32_t& index() + { + return m_index; + } /*! @@ -160,26 +180,40 @@ class HelloWorld * @param _message New value to be copied in member message */ eProsima_user_DllExport void message( - const eprosima::fastcdr::fixed_string<20>& _message); + const eprosima::fastcdr::fixed_string<20>& _message) + { + m_message = _message; + } /*! * @brief This function moves the value in member message * @param _message New value to be moved in member message */ eProsima_user_DllExport void message( - eprosima::fastcdr::fixed_string<20>&& _message); + eprosima::fastcdr::fixed_string<20>&& _message) + { + m_message = std::move(_message); + } /*! * @brief This function returns a constant reference to member message * @return Constant reference to member message */ - eProsima_user_DllExport const eprosima::fastcdr::fixed_string<20>& message() const; + eProsima_user_DllExport const eprosima::fastcdr::fixed_string<20>& message() const + { + return m_message; + } /*! * @brief This function returns a reference to member message * @return Reference to member message */ - eProsima_user_DllExport eprosima::fastcdr::fixed_string<20>& message(); + eProsima_user_DllExport eprosima::fastcdr::fixed_string<20>& message() + { + return m_message; + } + + private: @@ -188,8 +222,6 @@ class HelloWorld }; -#endif // _FAST_DDS_GENERATED_HELLOWORLD_H_ - +#endif // _FAST_DDS_GENERATED_HELLOWORLD_HPP_ -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorldCdrAux.hpp b/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorldCdrAux.hpp index b0d081fe956..5d8548e14b8 100644 --- a/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorldCdrAux.hpp +++ b/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorldCdrAux.hpp @@ -22,7 +22,7 @@ #ifndef _FAST_DDS_GENERATED_HELLOWORLDCDRAUX_HPP_ #define _FAST_DDS_GENERATED_HELLOWORLDCDRAUX_HPP_ -#include "HelloWorld.h" +#include "HelloWorld.hpp" constexpr uint32_t HelloWorld_max_cdr_typesize {33UL}; constexpr uint32_t HelloWorld_max_key_cdr_typesize {0UL}; @@ -34,8 +34,6 @@ namespace fastcdr { class Cdr; class CdrSizeCalculator; - - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const HelloWorld& data); diff --git a/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorldCdrAux.ipp b/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorldCdrAux.ipp index 42e91f3cc38..97df3fe9d9e 100644 --- a/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorldCdrAux.ipp +++ b/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorldCdrAux.ipp @@ -34,8 +34,6 @@ using namespace eprosima::fastcdr::exception; namespace eprosima { namespace fastcdr { - - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, diff --git a/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorldPubSubTypes.cxx b/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorldPubSubTypes.cxx index 85cb477896e..db018e69782 100644 --- a/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorldPubSubTypes.cxx +++ b/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorldPubSubTypes.cxx @@ -19,18 +19,18 @@ * This file was generated by the tool fastddsgen. */ +#include "HelloWorldPubSubTypes.h" +#include #include -#include "HelloWorldPubSubTypes.h" #include "HelloWorldCdrAux.hpp" +#include "HelloWorldTypeObjectSupport.hpp" using SerializedPayload_t = eprosima::fastrtps::rtps::SerializedPayload_t; using InstanceHandle_t = eprosima::fastrtps::rtps::InstanceHandle_t; using DataRepresentationId_t = eprosima::fastdds::dds::DataRepresentationId_t; - - HelloWorldPubSubType::HelloWorldPubSubType() { setName("HelloWorld"); @@ -219,3 +219,11 @@ bool HelloWorldPubSubType::getKey( return true; } +void HelloWorldPubSubType::register_type_object_representation() const +{ + register_HelloWorld_type_objects(); +} + + +// Include auxiliary functions like for serializing/deserializing. +#include "HelloWorldCdrAux.ipp" diff --git a/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorldPubSubTypes.h b/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorldPubSubTypes.h index ddbfbab5db6..52736f6dad8 100644 --- a/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorldPubSubTypes.h +++ b/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorldPubSubTypes.h @@ -27,9 +27,9 @@ #include #include #include -#include +#include -#include "HelloWorld.h" +#include "HelloWorld.hpp" #if !defined(GEN_API_VER) || (GEN_API_VER != 2) @@ -38,8 +38,6 @@ #endif // GEN_API_VER - - /*! * @brief This class represents the TopicDataType of the type HelloWorld defined by the user in the IDL file. * @ingroup HelloWorld @@ -90,6 +88,9 @@ class HelloWorldPubSubType : public eprosima::fastdds::dds::TopicDataType eProsima_user_DllExport void deleteData( void* data) override; + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + #ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED eProsima_user_DllExport inline bool is_bounded() const override { diff --git a/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorldPublisher.cpp b/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorldPublisher.cpp index d6410f39fbc..24b6a033e9e 100644 --- a/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorldPublisher.cpp +++ b/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorldPublisher.cpp @@ -18,15 +18,14 @@ */ #include "HelloWorldPublisher.h" -#include -#include + +#include + #include -#include -#include #include +#include #include - -#include +#include using namespace eprosima::fastdds::dds; diff --git a/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorldSubscriber.cpp b/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorldSubscriber.cpp index 4e0e1fa9c58..690cdfdab64 100644 --- a/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorldSubscriber.cpp +++ b/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorldSubscriber.cpp @@ -27,8 +27,6 @@ #include #include #include -#include -#include using namespace eprosima::fastdds::dds; @@ -131,7 +129,7 @@ void HelloWorldSubscriber::SubListener::on_data_available( DataReader* reader) { SampleInfo info; - if (reader->take_next_sample(&hello_, &info) == ReturnCode_t::RETCODE_OK) + if (reader->take_next_sample(&hello_, &info) == RETCODE_OK) { if (info.instance_state == ALIVE_INSTANCE_STATE) { diff --git a/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorldSubscriber.h b/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorldSubscriber.h index c2cd03b7ebc..4d700a8cab2 100644 --- a/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorldSubscriber.h +++ b/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorldSubscriber.h @@ -20,12 +20,12 @@ #ifndef HELLOWORLDSUBSCRIBER_H_ #define HELLOWORLDSUBSCRIBER_H_ -#include "HelloWorldPubSubTypes.h" - +#include #include #include -#include -#include +#include + +#include "HelloWorldPubSubTypes.h" class HelloWorldSubscriber { diff --git a/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorldTypeObjectSupport.cxx b/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorldTypeObjectSupport.cxx new file mode 100644 index 00000000000..7049f02b87e --- /dev/null +++ b/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorldTypeObjectSupport.cxx @@ -0,0 +1,248 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file HelloWorldTypeObjectSupport.cxx + * Source file containing the implementation to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#include "HelloWorldTypeObjectSupport.hpp" + +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include + +#include "HelloWorld.hpp" + + +using namespace eprosima::fastdds::dds::xtypes; + +void register_HelloWorld_type_objects() +{ + static std::once_flag once_flag; + std::call_once(once_flag, []() + { + register_HelloWorld_type_identifier(); + + }); +} + +void register_HelloWorld_type_identifier() +{ + { + StructTypeFlag struct_flags_HelloWorld = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::NOT_APPLIED, + false, false); + ReturnCode_t return_code_HelloWorld; + TypeIdentifierPair type_ids_HelloWorld; + QualifiedTypeName type_name_HelloWorld = "HelloWorld"; + eprosima::fastcdr::optional type_ann_builtin_HelloWorld; + eprosima::fastcdr::optional ann_custom_HelloWorld; + CompleteTypeDetail detail_HelloWorld = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_HelloWorld, ann_custom_HelloWorld, type_name_HelloWorld.to_string()); + CompleteStructHeader header_HelloWorld; + header_HelloWorld = TypeObjectUtils::build_complete_struct_header(TypeIdentifier(), detail_HelloWorld); + CompleteStructMemberSeq member_seq_HelloWorld; + { + return_code_HelloWorld = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_uint32_t", type_ids_HelloWorld); + + if (return_code_HelloWorld != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "index Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_index = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_index; + MemberId member_id_index = 0x00000000; + if (EK_COMPLETE == type_ids_HelloWorld.type_identifier1()._d() || TK_NONE == type_ids_HelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_HelloWorld.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_HelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_HelloWorld.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure index member TypeIdentifier inconsistent."); + return; + } + MemberName name_index = "index"; + eprosima::fastcdr::optional member_ann_builtin_index; + ann_custom_HelloWorld.reset(); + CompleteMemberDetail detail_index = TypeObjectUtils::build_complete_member_detail(name_index, member_ann_builtin_index, ann_custom_HelloWorld); + CompleteStructMember member_index = TypeObjectUtils::build_complete_struct_member(common_index, detail_index); + TypeObjectUtils::add_complete_struct_member(member_seq_HelloWorld, member_index); + } + { + return_code_HelloWorld = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_string_20", type_ids_HelloWorld); + + if (return_code_HelloWorld != eprosima::fastdds::dds::RETCODE_OK) + { + std::string type_id_kind_anonymous_string_20("TI_STRING8_SMALL"); + if (type_id_kind_anonymous_string_20 == "TI_STRING8_SMALL") + { + SBound bound = static_cast(20); + StringSTypeDefn string_sdefn = TypeObjectUtils::build_string_s_type_defn(bound); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_string_type_identifier(string_sdefn, + "anonymous_string_20")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_20 already registered in TypeObjectRegistry for a different type."); + } + } + else if (type_id_kind_anonymous_string_20 == "TI_STRING8_LARGE") + { + LBound bound = 20; + StringLTypeDefn string_ldefn = TypeObjectUtils::build_string_l_type_defn(bound); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_string_type_identifier(string_ldefn, + "anonymous_string_20")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_20 already registered in TypeObjectRegistry for a different type."); + } + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_20: Unknown String kind."); + return; + } + return_code_HelloWorld = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_string_20", type_ids_HelloWorld); + if (return_code_HelloWorld != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_20: Given String TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_message = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_message; + MemberId member_id_message = 0x00000001; + if (EK_COMPLETE == type_ids_HelloWorld.type_identifier1()._d() || TK_NONE == type_ids_HelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_message = TypeObjectUtils::build_common_struct_member(member_id_message, member_flags_message, type_ids_HelloWorld.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_HelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_message = TypeObjectUtils::build_common_struct_member(member_id_message, member_flags_message, type_ids_HelloWorld.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure message member TypeIdentifier inconsistent."); + return; + } + MemberName name_message = "message"; + eprosima::fastcdr::optional member_ann_builtin_message; + ann_custom_HelloWorld.reset(); + CompleteMemberDetail detail_message = TypeObjectUtils::build_complete_member_detail(name_message, member_ann_builtin_message, ann_custom_HelloWorld); + CompleteStructMember member_message = TypeObjectUtils::build_complete_struct_member(common_message, detail_message); + TypeObjectUtils::add_complete_struct_member(member_seq_HelloWorld, member_message); + } + CompleteStructType struct_type_HelloWorld = TypeObjectUtils::build_complete_struct_type(struct_flags_HelloWorld, header_HelloWorld, member_seq_HelloWorld); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_struct_type_object(struct_type_HelloWorld, type_name_HelloWorld.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "HelloWorld already registered in TypeObjectRegistry for a different type."); + } + return_code_HelloWorld = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "HelloWorld", type_ids_HelloWorld); + if (return_code_HelloWorld != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "HelloWorld: Given Struct TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } +} + diff --git a/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorldTypeObjectSupport.hpp b/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorldTypeObjectSupport.hpp new file mode 100644 index 00000000000..8650fc061e0 --- /dev/null +++ b/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorldTypeObjectSupport.hpp @@ -0,0 +1,54 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file HelloWorldTypeObjectSupport.hpp + * Header file containing the API required to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#ifndef _FAST_DDS_GENERATED_HELLOWORLD_TYPE_OBJECT_SUPPORT_HPP_ +#define _FAST_DDS_GENERATED_HELLOWORLD_TYPE_OBJECT_SUPPORT_HPP_ + + +#if defined(_WIN32) +#if defined(EPROSIMA_USER_DLL_EXPORT) +#define eProsima_user_DllExport __declspec( dllexport ) +#else +#define eProsima_user_DllExport +#endif // EPROSIMA_USER_DLL_EXPORT +#else +#define eProsima_user_DllExport +#endif // _WIN32 + +/** + * @brief Register every TypeObject representation defined in the IDL file in Fast DDS TypeObjectRegistry. + */ +eProsima_user_DllExport void register_HelloWorld_type_objects(); + +#ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +/** + * @brief Register HelloWorld related TypeIdentifier. + * Fully-descriptive TypeIdentifiers are directly registered. + * Hash TypeIdentifiers require to fill the TypeObject information and hash it, consequently, the TypeObject is + * indirectly registered as well. + */ +void register_HelloWorld_type_identifier(); + + +#endif // DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +#endif // _FAST_DDS_GENERATED_HELLOWORLD_TYPE_OBJECT_SUPPORT_HPP_ diff --git a/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorld_main.cpp b/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorld_main.cpp index 12bfa578b4d..f7ff24627db 100644 --- a/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorld_main.cpp +++ b/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorld_main.cpp @@ -17,12 +17,11 @@ * */ -#include "HelloWorldPublisher.h" -#include "HelloWorldSubscriber.h" - #include +#include -#include +#include "HelloWorldPublisher.h" +#include "HelloWorldSubscriber.h" using eprosima::fastdds::dds::Log; diff --git a/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorldv1.cxx b/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorldv1.cxx deleted file mode 100644 index 27e02c6c6d3..00000000000 --- a/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorldv1.cxx +++ /dev/null @@ -1,290 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file HelloWorld.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "HelloWorld.h" - -#if FASTCDR_VERSION_MAJOR == 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - -namespace helper { namespace internal { - -enum class Size { - UInt8, - UInt16, - UInt32, - UInt64, -}; - -constexpr Size get_size(int s) { - return (s <= 8 ) ? Size::UInt8: - (s <= 16) ? Size::UInt16: - (s <= 32) ? Size::UInt32: Size::UInt64; -} - -template -struct FindTypeH; - -template<> -struct FindTypeH { - using type = std::uint8_t; -}; - -template<> -struct FindTypeH { - using type = std::uint16_t; -}; - -template<> -struct FindTypeH { - using type = std::uint32_t; -}; - -template<> -struct FindTypeH { - using type = std::uint64_t; -}; -} - -template -struct FindType { - using type = typename internal::FindTypeH::type; -}; -} - -#define HelloWorld_max_cdr_typesize 33ULL; - - - - -HelloWorld::HelloWorld() -{ - // unsigned long m_index - m_index = 0; - // /type_d() m_message - - -} - -HelloWorld::~HelloWorld() -{ -} - -HelloWorld::HelloWorld( - const HelloWorld& x) -{ - m_index = x.m_index; - - - m_message = x.m_message; - -} - -HelloWorld::HelloWorld( - HelloWorld&& x) noexcept -{ - m_index = x.m_index; - - - m_message = std::move(x.m_message); - -} - -HelloWorld& HelloWorld::operator =( - const HelloWorld& x) -{ - m_index = x.m_index; - - - m_message = x.m_message; - - return *this; -} - -HelloWorld& HelloWorld::operator =( - HelloWorld&& x) noexcept -{ - m_index = x.m_index; - - - m_message = std::move(x.m_message); - - return *this; -} - -bool HelloWorld::operator ==( - const HelloWorld& x) const -{ - return (m_index == x.m_index && - m_message == x.m_message); -} - -bool HelloWorld::operator !=( - const HelloWorld& x) const -{ - return !(*this == x); -} - -size_t HelloWorld::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return HelloWorld_max_cdr_typesize; -} - -size_t HelloWorld::getCdrSerializedSize( - const HelloWorld& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + data.message().size() + 1; - - - return current_alignment - initial_alignment; -} - - -void HelloWorld::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_index; - - scdr << m_message.c_str(); - -} - -void HelloWorld::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_index; - - - - { - std::string aux; - dcdr >> aux; - m_message = aux.c_str(); - } - - -} - - -bool HelloWorld::isKeyDefined() -{ - return false; -} - -void HelloWorld::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void HelloWorld::index( - uint32_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint32_t HelloWorld::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint32_t& HelloWorld::index() -{ - return m_index; -} - - -/*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ -void HelloWorld::message( - const eprosima::fastrtps::fixed_string<20>& _message) -{ - m_message = _message; -} - -/*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ -void HelloWorld::message( - eprosima::fastrtps::fixed_string<20>&& _message) -{ - m_message = std::move(_message); -} - -/*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ -const eprosima::fastrtps::fixed_string<20>& HelloWorld::message() const -{ - return m_message; -} - -/*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ -eprosima::fastrtps::fixed_string<20>& HelloWorld::message() -{ - return m_message; -} - - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorldv1.h b/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorldv1.h deleted file mode 100644 index 00281b09128..00000000000 --- a/examples/cpp/dds/HelloWorldExampleDataSharing/HelloWorldv1.h +++ /dev/null @@ -1,244 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file HelloWorld.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#include - -#if FASTCDR_VERSION_MAJOR == 1 - -#ifndef _FAST_DDS_GENERATED_HELLOWORLD_H_ -#define _FAST_DDS_GENERATED_HELLOWORLD_H_ - - -#include - -#include -#include -#include -#include -#include -#include -#include - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define eProsima_user_DllExport -#endif // _WIN32 - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(HELLOWORLD_SOURCE) -#define HELLOWORLD_DllAPI __declspec( dllexport ) -#else -#define HELLOWORLD_DllAPI __declspec( dllimport ) -#endif // HELLOWORLD_SOURCE -#else -#define HELLOWORLD_DllAPI -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define HELLOWORLD_DllAPI -#endif // _WIN32 - -namespace eprosima { -namespace fastcdr { -class Cdr; -} // namespace fastcdr -} // namespace eprosima - - - - - -/*! - * @brief This class represents the structure HelloWorld defined by the user in the IDL file. - * @ingroup HelloWorld - */ -class HelloWorld -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport HelloWorld(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~HelloWorld(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object HelloWorld that will be copied. - */ - eProsima_user_DllExport HelloWorld( - const HelloWorld& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object HelloWorld that will be copied. - */ - eProsima_user_DllExport HelloWorld( - HelloWorld&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object HelloWorld that will be copied. - */ - eProsima_user_DllExport HelloWorld& operator =( - const HelloWorld& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object HelloWorld that will be copied. - */ - eProsima_user_DllExport HelloWorld& operator =( - HelloWorld&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x HelloWorld object to compare. - */ - eProsima_user_DllExport bool operator ==( - const HelloWorld& x) const; - - /*! - * @brief Comparison operator. - * @param x HelloWorld object to compare. - */ - eProsima_user_DllExport bool operator !=( - const HelloWorld& x) const; - - /*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ - eProsima_user_DllExport void index( - uint32_t _index); - - /*! - * @brief This function returns the value of member index - * @return Value of member index - */ - eProsima_user_DllExport uint32_t index() const; - - /*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ - eProsima_user_DllExport uint32_t& index(); - - - /*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ - eProsima_user_DllExport void message( - const eprosima::fastrtps::fixed_string<20>& _message); - - /*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ - eProsima_user_DllExport void message( - eprosima::fastrtps::fixed_string<20>&& _message); - - /*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ - eProsima_user_DllExport const eprosima::fastrtps::fixed_string<20>& message() const; - - /*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ - eProsima_user_DllExport eprosima::fastrtps::fixed_string<20>& message(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const HelloWorld& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - uint32_t m_index; - eprosima::fastrtps::fixed_string<20> m_message; - -}; - - -#endif // _FAST_DDS_GENERATED_HELLOWORLD_H_ - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/HelloWorldExampleSharedMem/CMakeLists.txt b/examples/cpp/dds/HelloWorldExampleSharedMem/CMakeLists.txt index d7d8d045222..057b67e1e89 100644 --- a/examples/cpp/dds/HelloWorldExampleSharedMem/CMakeLists.txt +++ b/examples/cpp/dds/HelloWorldExampleSharedMem/CMakeLists.txt @@ -25,8 +25,8 @@ if(NOT foonathan_memory_FOUND) find_package(foonathan_memory REQUIRED) endif() -if(NOT fastrtps_FOUND) - find_package(fastrtps 2.12 REQUIRED) +if(NOT fastdds_FOUND) + find_package(fastdds 3 REQUIRED) endif() #Check C++11 @@ -51,6 +51,6 @@ target_compile_definitions(DDSHelloWorldExampleSharedMem PRIVATE $<$>,$>:__DEBUG> $<$:__INTERNALDEBUG> # Internal debug activated. ) -target_link_libraries(DDSHelloWorldExampleSharedMem fastrtps fastcdr foonathan_memory) +target_link_libraries(DDSHelloWorldExampleSharedMem fastdds fastcdr foonathan_memory) install(TARGETS DDSHelloWorldExampleSharedMem RUNTIME DESTINATION examples/cpp/dds/HelloWorldExampleSharedMem/${BIN_INSTALL_DIR}) diff --git a/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorld.cxx b/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorld.cxx deleted file mode 100644 index 68c604b6588..00000000000 --- a/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorld.cxx +++ /dev/null @@ -1,212 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file HelloWorld.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "HelloWorld.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - - - - -HelloWorld::HelloWorld() -{ -} - -HelloWorld::~HelloWorld() -{ -} - -HelloWorld::HelloWorld( - const HelloWorld& x) -{ - m_index = x.m_index; - m_message = x.m_message; - m_data = x.m_data; -} - -HelloWorld::HelloWorld( - HelloWorld&& x) noexcept -{ - m_index = x.m_index; - m_message = std::move(x.m_message); - m_data = std::move(x.m_data); -} - -HelloWorld& HelloWorld::operator =( - const HelloWorld& x) -{ - - m_index = x.m_index; - m_message = x.m_message; - m_data = x.m_data; - return *this; -} - -HelloWorld& HelloWorld::operator =( - HelloWorld&& x) noexcept -{ - - m_index = x.m_index; - m_message = std::move(x.m_message); - m_data = std::move(x.m_data); - return *this; -} - -bool HelloWorld::operator ==( - const HelloWorld& x) const -{ - return (m_index == x.m_index && - m_message == x.m_message && - m_data == x.m_data); -} - -bool HelloWorld::operator !=( - const HelloWorld& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void HelloWorld::index( - uint32_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint32_t HelloWorld::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint32_t& HelloWorld::index() -{ - return m_index; -} - - -/*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ -void HelloWorld::message( - const std::string& _message) -{ - m_message = _message; -} - -/*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ -void HelloWorld::message( - std::string&& _message) -{ - m_message = std::move(_message); -} - -/*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ -const std::string& HelloWorld::message() const -{ - return m_message; -} - -/*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ -std::string& HelloWorld::message() -{ - return m_message; -} - - -/*! - * @brief This function copies the value in member data - * @param _data New value to be copied in member data - */ -void HelloWorld::data( - const std::array& _data) -{ - m_data = _data; -} - -/*! - * @brief This function moves the value in member data - * @param _data New value to be moved in member data - */ -void HelloWorld::data( - std::array&& _data) -{ - m_data = std::move(_data); -} - -/*! - * @brief This function returns a constant reference to member data - * @return Constant reference to member data - */ -const std::array& HelloWorld::data() const -{ - return m_data; -} - -/*! - * @brief This function returns a reference to member data - * @return Reference to member data - */ -std::array& HelloWorld::data() -{ - return m_data; -} - - -// Include auxiliary functions like for serializing/deserializing. -#include "HelloWorldCdrAux.ipp" - -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorld.h b/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorld.hpp similarity index 66% rename from examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorld.h rename to examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorld.hpp index deb44d359b1..7fbb251328b 100644 --- a/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorld.h +++ b/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorld.hpp @@ -13,32 +13,20 @@ // limitations under the License. /*! - * @file HelloWorld.h + * @file HelloWorld.hpp * This header file contains the declaration of the described types in the IDL file. * * This file was generated by the tool fastddsgen. */ -#include -#include "HelloWorldv1.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#ifndef _FAST_DDS_GENERATED_HELLOWORLD_H_ -#define _FAST_DDS_GENERATED_HELLOWORLD_H_ +#ifndef _FAST_DDS_GENERATED_HELLOWORLD_HPP_ +#define _FAST_DDS_GENERATED_HELLOWORLD_HPP_ #include -#include #include -#include #include -#include - +#include #include -#include -#include - - #if defined(_WIN32) #if defined(EPROSIMA_USER_DLL_EXPORT) @@ -64,17 +52,6 @@ #define HELLOWORLD_DllAPI #endif // _WIN32 -namespace eprosima { -namespace fastcdr { -class Cdr; -class CdrSizeCalculator; -} // namespace fastcdr -} // namespace eprosima - - - - - /*! * @brief This class represents the structure HelloWorld defined by the user in the IDL file. * @ingroup HelloWorld @@ -86,73 +63,124 @@ class HelloWorld /*! * @brief Default constructor. */ - eProsima_user_DllExport HelloWorld(); + eProsima_user_DllExport HelloWorld() + { + } /*! * @brief Default destructor. */ - eProsima_user_DllExport ~HelloWorld(); + eProsima_user_DllExport ~HelloWorld() + { + } /*! * @brief Copy constructor. * @param x Reference to the object HelloWorld that will be copied. */ eProsima_user_DllExport HelloWorld( - const HelloWorld& x); + const HelloWorld& x) + { + m_index = x.m_index; + + m_message = x.m_message; + + m_data = x.m_data; + + } /*! * @brief Move constructor. * @param x Reference to the object HelloWorld that will be copied. */ eProsima_user_DllExport HelloWorld( - HelloWorld&& x) noexcept; + HelloWorld&& x) noexcept + { + m_index = x.m_index; + m_message = std::move(x.m_message); + m_data = std::move(x.m_data); + } /*! * @brief Copy assignment. * @param x Reference to the object HelloWorld that will be copied. */ eProsima_user_DllExport HelloWorld& operator =( - const HelloWorld& x); + const HelloWorld& x) + { + + m_index = x.m_index; + + m_message = x.m_message; + + m_data = x.m_data; + + return *this; + } /*! * @brief Move assignment. * @param x Reference to the object HelloWorld that will be copied. */ eProsima_user_DllExport HelloWorld& operator =( - HelloWorld&& x) noexcept; + HelloWorld&& x) noexcept + { + + m_index = x.m_index; + m_message = std::move(x.m_message); + m_data = std::move(x.m_data); + return *this; + } /*! * @brief Comparison operator. * @param x HelloWorld object to compare. */ eProsima_user_DllExport bool operator ==( - const HelloWorld& x) const; + const HelloWorld& x) const + { + return (m_index == x.m_index && + m_message == x.m_message && + m_data == x.m_data); + } /*! * @brief Comparison operator. * @param x HelloWorld object to compare. */ eProsima_user_DllExport bool operator !=( - const HelloWorld& x) const; + const HelloWorld& x) const + { + return !(*this == x); + } /*! * @brief This function sets a value in member index * @param _index New value for member index */ eProsima_user_DllExport void index( - uint32_t _index); + uint32_t _index) + { + m_index = _index; + } /*! * @brief This function returns the value of member index * @return Value of member index */ - eProsima_user_DllExport uint32_t index() const; + eProsima_user_DllExport uint32_t index() const + { + return m_index; + } /*! * @brief This function returns a reference to member index * @return Reference to member index */ - eProsima_user_DllExport uint32_t& index(); + eProsima_user_DllExport uint32_t& index() + { + return m_index; + } /*! @@ -160,26 +188,38 @@ class HelloWorld * @param _message New value to be copied in member message */ eProsima_user_DllExport void message( - const std::string& _message); + const std::string& _message) + { + m_message = _message; + } /*! * @brief This function moves the value in member message * @param _message New value to be moved in member message */ eProsima_user_DllExport void message( - std::string&& _message); + std::string&& _message) + { + m_message = std::move(_message); + } /*! * @brief This function returns a constant reference to member message * @return Constant reference to member message */ - eProsima_user_DllExport const std::string& message() const; + eProsima_user_DllExport const std::string& message() const + { + return m_message; + } /*! * @brief This function returns a reference to member message * @return Reference to member message */ - eProsima_user_DllExport std::string& message(); + eProsima_user_DllExport std::string& message() + { + return m_message; + } /*! @@ -187,37 +227,49 @@ class HelloWorld * @param _data New value to be copied in member data */ eProsima_user_DllExport void data( - const std::array& _data); + const std::array& _data) + { + m_data = _data; + } /*! * @brief This function moves the value in member data * @param _data New value to be moved in member data */ eProsima_user_DllExport void data( - std::array&& _data); + std::array&& _data) + { + m_data = std::move(_data); + } /*! * @brief This function returns a constant reference to member data * @return Constant reference to member data */ - eProsima_user_DllExport const std::array& data() const; + eProsima_user_DllExport const std::array& data() const + { + return m_data; + } /*! * @brief This function returns a reference to member data * @return Reference to member data */ - eProsima_user_DllExport std::array& data(); + eProsima_user_DllExport std::array& data() + { + return m_data; + } + + private: uint32_t m_index{0}; std::string m_message; - std::array m_data; + std::array m_data{0}; }; -#endif // _FAST_DDS_GENERATED_HELLOWORLD_H_ - +#endif // _FAST_DDS_GENERATED_HELLOWORLD_HPP_ -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorldCdrAux.hpp b/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorldCdrAux.hpp index 77b8e2a63aa..2755baecef9 100644 --- a/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorldCdrAux.hpp +++ b/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorldCdrAux.hpp @@ -22,7 +22,7 @@ #ifndef _FAST_DDS_GENERATED_HELLOWORLDCDRAUX_HPP_ #define _FAST_DDS_GENERATED_HELLOWORLDCDRAUX_HPP_ -#include "HelloWorld.h" +#include "HelloWorld.hpp" constexpr uint32_t HelloWorld_max_cdr_typesize {1048844UL}; constexpr uint32_t HelloWorld_max_key_cdr_typesize {0UL}; @@ -34,8 +34,6 @@ namespace fastcdr { class Cdr; class CdrSizeCalculator; - - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const HelloWorld& data); diff --git a/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorldCdrAux.ipp b/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorldCdrAux.ipp index 2243fe1af8d..bcdc3a4d321 100644 --- a/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorldCdrAux.ipp +++ b/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorldCdrAux.ipp @@ -34,8 +34,6 @@ using namespace eprosima::fastcdr::exception; namespace eprosima { namespace fastcdr { - - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, diff --git a/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorldPubSubTypes.cxx b/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorldPubSubTypes.cxx index 85cb477896e..db018e69782 100644 --- a/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorldPubSubTypes.cxx +++ b/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorldPubSubTypes.cxx @@ -19,18 +19,18 @@ * This file was generated by the tool fastddsgen. */ +#include "HelloWorldPubSubTypes.h" +#include #include -#include "HelloWorldPubSubTypes.h" #include "HelloWorldCdrAux.hpp" +#include "HelloWorldTypeObjectSupport.hpp" using SerializedPayload_t = eprosima::fastrtps::rtps::SerializedPayload_t; using InstanceHandle_t = eprosima::fastrtps::rtps::InstanceHandle_t; using DataRepresentationId_t = eprosima::fastdds::dds::DataRepresentationId_t; - - HelloWorldPubSubType::HelloWorldPubSubType() { setName("HelloWorld"); @@ -219,3 +219,11 @@ bool HelloWorldPubSubType::getKey( return true; } +void HelloWorldPubSubType::register_type_object_representation() const +{ + register_HelloWorld_type_objects(); +} + + +// Include auxiliary functions like for serializing/deserializing. +#include "HelloWorldCdrAux.ipp" diff --git a/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorldPubSubTypes.h b/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorldPubSubTypes.h index cb61cd6ba23..a9b4ac119e0 100644 --- a/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorldPubSubTypes.h +++ b/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorldPubSubTypes.h @@ -27,9 +27,9 @@ #include #include #include -#include +#include -#include "HelloWorld.h" +#include "HelloWorld.hpp" #if !defined(GEN_API_VER) || (GEN_API_VER != 2) @@ -38,8 +38,6 @@ #endif // GEN_API_VER - - /*! * @brief This class represents the TopicDataType of the type HelloWorld defined by the user in the IDL file. * @ingroup HelloWorld @@ -90,6 +88,9 @@ class HelloWorldPubSubType : public eprosima::fastdds::dds::TopicDataType eProsima_user_DllExport void deleteData( void* data) override; + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + #ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED eProsima_user_DllExport inline bool is_bounded() const override { diff --git a/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorldPublisher.h b/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorldPublisher.h index b3728ca47ad..ef37aa5f383 100644 --- a/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorldPublisher.h +++ b/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorldPublisher.h @@ -28,7 +28,7 @@ #include #include -#include "HelloWorld.h" +#include "HelloWorld.hpp" class HelloWorldPublisher { diff --git a/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorldSubscriber.cpp b/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorldSubscriber.cpp index 9afd1360353..77a438830bf 100644 --- a/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorldSubscriber.cpp +++ b/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorldSubscriber.cpp @@ -146,7 +146,7 @@ void HelloWorldSubscriber::SubListener::on_data_available( DataReader* reader) { SampleInfo info; - if (reader->take_next_sample(hello_.get(), &info) == ReturnCode_t::RETCODE_OK) + if (reader->take_next_sample(hello_.get(), &info) == RETCODE_OK) { if (info.valid_data) { diff --git a/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorldSubscriber.h b/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorldSubscriber.h index d6be44aaf28..706ca6ada3d 100644 --- a/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorldSubscriber.h +++ b/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorldSubscriber.h @@ -28,7 +28,7 @@ #include #include -#include "HelloWorld.h" +#include "HelloWorld.hpp" class HelloWorldSubscriber { diff --git a/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorldTypeObjectSupport.cxx b/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorldTypeObjectSupport.cxx new file mode 100644 index 00000000000..afeb68f5251 --- /dev/null +++ b/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorldTypeObjectSupport.cxx @@ -0,0 +1,407 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file HelloWorldTypeObjectSupport.cxx + * Source file containing the implementation to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#include "HelloWorldTypeObjectSupport.hpp" + +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include + +#include "HelloWorld.hpp" + + +using namespace eprosima::fastdds::dds::xtypes; + +void register_HelloWorld_type_objects() +{ + static std::once_flag once_flag; + std::call_once(once_flag, []() + { + register_HelloWorld_type_identifier(); + + }); +} + +void register_HelloWorld_type_identifier() +{ + { + StructTypeFlag struct_flags_HelloWorld = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::NOT_APPLIED, + false, false); + ReturnCode_t return_code_HelloWorld; + TypeIdentifierPair type_ids_HelloWorld; + QualifiedTypeName type_name_HelloWorld = "HelloWorld"; + eprosima::fastcdr::optional type_ann_builtin_HelloWorld; + eprosima::fastcdr::optional ann_custom_HelloWorld; + CompleteTypeDetail detail_HelloWorld = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_HelloWorld, ann_custom_HelloWorld, type_name_HelloWorld.to_string()); + CompleteStructHeader header_HelloWorld; + header_HelloWorld = TypeObjectUtils::build_complete_struct_header(TypeIdentifier(), detail_HelloWorld); + CompleteStructMemberSeq member_seq_HelloWorld; + { + return_code_HelloWorld = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_uint32_t", type_ids_HelloWorld); + + if (return_code_HelloWorld != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "index Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_index = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_index; + MemberId member_id_index = 0x00000000; + if (EK_COMPLETE == type_ids_HelloWorld.type_identifier1()._d() || TK_NONE == type_ids_HelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_HelloWorld.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_HelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_HelloWorld.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure index member TypeIdentifier inconsistent."); + return; + } + MemberName name_index = "index"; + eprosima::fastcdr::optional member_ann_builtin_index; + ann_custom_HelloWorld.reset(); + CompleteMemberDetail detail_index = TypeObjectUtils::build_complete_member_detail(name_index, member_ann_builtin_index, ann_custom_HelloWorld); + CompleteStructMember member_index = TypeObjectUtils::build_complete_struct_member(common_index, detail_index); + TypeObjectUtils::add_complete_struct_member(member_seq_HelloWorld, member_index); + } + { + return_code_HelloWorld = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_string_unbounded", type_ids_HelloWorld); + + if (return_code_HelloWorld != eprosima::fastdds::dds::RETCODE_OK) + { + std::string type_id_kind_anonymous_string_unbounded("TI_STRING8_SMALL"); + if (type_id_kind_anonymous_string_unbounded == "TI_STRING8_SMALL") + { + SBound bound = 0; + StringSTypeDefn string_sdefn = TypeObjectUtils::build_string_s_type_defn(bound); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_string_type_identifier(string_sdefn, + "anonymous_string_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else if (type_id_kind_anonymous_string_unbounded == "TI_STRING8_LARGE") + { + LBound bound = 255; + StringLTypeDefn string_ldefn = TypeObjectUtils::build_string_l_type_defn(bound); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_string_type_identifier(string_ldefn, + "anonymous_string_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded: Unknown String kind."); + return; + } + return_code_HelloWorld = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_string_unbounded", type_ids_HelloWorld); + if (return_code_HelloWorld != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded: Given String TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_message = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_message; + MemberId member_id_message = 0x00000001; + if (EK_COMPLETE == type_ids_HelloWorld.type_identifier1()._d() || TK_NONE == type_ids_HelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_message = TypeObjectUtils::build_common_struct_member(member_id_message, member_flags_message, type_ids_HelloWorld.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_HelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_message = TypeObjectUtils::build_common_struct_member(member_id_message, member_flags_message, type_ids_HelloWorld.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure message member TypeIdentifier inconsistent."); + return; + } + MemberName name_message = "message"; + eprosima::fastcdr::optional member_ann_builtin_message; + ann_custom_HelloWorld.reset(); + CompleteMemberDetail detail_message = TypeObjectUtils::build_complete_member_detail(name_message, member_ann_builtin_message, ann_custom_HelloWorld); + CompleteStructMember member_message = TypeObjectUtils::build_complete_struct_member(common_message, detail_message); + TypeObjectUtils::add_complete_struct_member(member_seq_HelloWorld, member_message); + } + { + return_code_HelloWorld = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_array_char_1048576", type_ids_HelloWorld); + + if (return_code_HelloWorld != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_HelloWorld = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_char", type_ids_HelloWorld); + + if (return_code_HelloWorld != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Array element TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + TypeIdentifier* element_identifier_anonymous_array_char_1048576 {nullptr}; + if (EK_COMPLETE == type_ids_HelloWorld.type_identifier1()._d() || TK_NONE == type_ids_HelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_array_char_1048576 = new TypeIdentifier(type_ids_HelloWorld.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_HelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_array_char_1048576 = new TypeIdentifier(type_ids_HelloWorld.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Array element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_array_char_1048576 = EK_COMPLETE; + if (TK_NONE == type_ids_HelloWorld.type_identifier2()._d()) + { + equiv_kind_anonymous_array_char_1048576 = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_array_char_1048576 = 0; + PlainCollectionHeader header_anonymous_array_char_1048576 = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_array_char_1048576, element_flags_anonymous_array_char_1048576); + std::string type_id_kind_anonymous_array_char_1048576("TI_PLAIN_ARRAY_LARGE"); + if (type_id_kind_anonymous_array_char_1048576 == "TI_PLAIN_ARRAY_SMALL") + { + SBoundSeq array_bound_seq; + TypeObjectUtils::add_array_dimension(array_bound_seq, static_cast(1048576)); + + PlainArraySElemDefn array_sdefn = TypeObjectUtils::build_plain_array_s_elem_defn(header_anonymous_array_char_1048576, array_bound_seq, + eprosima::fastcdr::external(element_identifier_anonymous_array_char_1048576)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_array_type_identifier(array_sdefn, "anonymous_array_char_1048576")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_char_1048576 already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBoundSeq array_bound_seq; + TypeObjectUtils::add_array_dimension(array_bound_seq, static_cast(1048576)); + + PlainArrayLElemDefn array_ldefn = TypeObjectUtils::build_plain_array_l_elem_defn(header_anonymous_array_char_1048576, array_bound_seq, + eprosima::fastcdr::external(element_identifier_anonymous_array_char_1048576)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_array_type_identifier(array_ldefn, "anonymous_array_char_1048576")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_char_1048576 already registered in TypeObjectRegistry for a different type."); + } + } + return_code_HelloWorld = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_array_char_1048576", type_ids_HelloWorld); + if (return_code_HelloWorld != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_char_1048576: Given Array TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_data = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_data; + MemberId member_id_data = 0x00000002; + if (EK_COMPLETE == type_ids_HelloWorld.type_identifier1()._d() || TK_NONE == type_ids_HelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_data = TypeObjectUtils::build_common_struct_member(member_id_data, member_flags_data, type_ids_HelloWorld.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_HelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_data = TypeObjectUtils::build_common_struct_member(member_id_data, member_flags_data, type_ids_HelloWorld.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure data member TypeIdentifier inconsistent."); + return; + } + MemberName name_data = "data"; + eprosima::fastcdr::optional member_ann_builtin_data; + ann_custom_HelloWorld.reset(); + CompleteMemberDetail detail_data = TypeObjectUtils::build_complete_member_detail(name_data, member_ann_builtin_data, ann_custom_HelloWorld); + CompleteStructMember member_data = TypeObjectUtils::build_complete_struct_member(common_data, detail_data); + TypeObjectUtils::add_complete_struct_member(member_seq_HelloWorld, member_data); + } + CompleteStructType struct_type_HelloWorld = TypeObjectUtils::build_complete_struct_type(struct_flags_HelloWorld, header_HelloWorld, member_seq_HelloWorld); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_struct_type_object(struct_type_HelloWorld, type_name_HelloWorld.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "HelloWorld already registered in TypeObjectRegistry for a different type."); + } + return_code_HelloWorld = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "HelloWorld", type_ids_HelloWorld); + if (return_code_HelloWorld != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "HelloWorld: Given Struct TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } +} + diff --git a/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorldTypeObjectSupport.hpp b/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorldTypeObjectSupport.hpp new file mode 100644 index 00000000000..8650fc061e0 --- /dev/null +++ b/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorldTypeObjectSupport.hpp @@ -0,0 +1,54 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file HelloWorldTypeObjectSupport.hpp + * Header file containing the API required to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#ifndef _FAST_DDS_GENERATED_HELLOWORLD_TYPE_OBJECT_SUPPORT_HPP_ +#define _FAST_DDS_GENERATED_HELLOWORLD_TYPE_OBJECT_SUPPORT_HPP_ + + +#if defined(_WIN32) +#if defined(EPROSIMA_USER_DLL_EXPORT) +#define eProsima_user_DllExport __declspec( dllexport ) +#else +#define eProsima_user_DllExport +#endif // EPROSIMA_USER_DLL_EXPORT +#else +#define eProsima_user_DllExport +#endif // _WIN32 + +/** + * @brief Register every TypeObject representation defined in the IDL file in Fast DDS TypeObjectRegistry. + */ +eProsima_user_DllExport void register_HelloWorld_type_objects(); + +#ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +/** + * @brief Register HelloWorld related TypeIdentifier. + * Fully-descriptive TypeIdentifiers are directly registered. + * Hash TypeIdentifiers require to fill the TypeObject information and hash it, consequently, the TypeObject is + * indirectly registered as well. + */ +void register_HelloWorld_type_identifier(); + + +#endif // DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +#endif // _FAST_DDS_GENERATED_HELLOWORLD_TYPE_OBJECT_SUPPORT_HPP_ diff --git a/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorld_main.cpp b/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorld_main.cpp index 04339bba607..979be73bef1 100644 --- a/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorld_main.cpp +++ b/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorld_main.cpp @@ -17,17 +17,18 @@ * */ -#include "HelloWorldPublisher.h" -#include "HelloWorldSubscriber.h" - #include -#include -#include +#include + +#include "HelloWorldPublisher.h" +#include "HelloWorldSubscriber.h" using namespace eprosima; using namespace fastrtps; using namespace rtps; +using namespace eprosima::fastdds::dds; + int main( int argc, char** argv) @@ -112,7 +113,6 @@ int main( break; } } - Domain::stopAll(); Log::Reset(); return 0; } diff --git a/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorldv1.cxx b/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorldv1.cxx deleted file mode 100644 index 0136d21e4c7..00000000000 --- a/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorldv1.cxx +++ /dev/null @@ -1,351 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file HelloWorld.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "HelloWorld.h" - -#if FASTCDR_VERSION_MAJOR == 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - -namespace helper { namespace internal { - -enum class Size { - UInt8, - UInt16, - UInt32, - UInt64, -}; - -constexpr Size get_size(int s) { - return (s <= 8 ) ? Size::UInt8: - (s <= 16) ? Size::UInt16: - (s <= 32) ? Size::UInt32: Size::UInt64; -} - -template -struct FindTypeH; - -template<> -struct FindTypeH { - using type = std::uint8_t; -}; - -template<> -struct FindTypeH { - using type = std::uint16_t; -}; - -template<> -struct FindTypeH { - using type = std::uint32_t; -}; - -template<> -struct FindTypeH { - using type = std::uint64_t; -}; -} - -template -struct FindType { - using type = typename internal::FindTypeH::type; -}; -} - -#define HelloWorld_max_cdr_typesize 1048844ULL; - - - - -HelloWorld::HelloWorld() -{ - // unsigned long m_index - m_index = 0; - // /type_d() m_message - - // char m_data - memset(&m_data, 0, ((1024*1024)) * 1); - -} - -HelloWorld::~HelloWorld() -{ -} - -HelloWorld::HelloWorld( - const HelloWorld& x) -{ - m_index = x.m_index; - - - m_message = x.m_message; - - - m_data = x.m_data; - -} - -HelloWorld::HelloWorld( - HelloWorld&& x) noexcept -{ - m_index = x.m_index; - - - m_message = std::move(x.m_message); - - - m_data = std::move(x.m_data); - -} - -HelloWorld& HelloWorld::operator =( - const HelloWorld& x) -{ - m_index = x.m_index; - - - m_message = x.m_message; - - - m_data = x.m_data; - - return *this; -} - -HelloWorld& HelloWorld::operator =( - HelloWorld&& x) noexcept -{ - m_index = x.m_index; - - - m_message = std::move(x.m_message); - - - m_data = std::move(x.m_data); - - return *this; -} - -bool HelloWorld::operator ==( - const HelloWorld& x) const -{ - return (m_index == x.m_index && - m_message == x.m_message && - m_data == x.m_data); -} - -bool HelloWorld::operator !=( - const HelloWorld& x) const -{ - return !(*this == x); -} - -size_t HelloWorld::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return HelloWorld_max_cdr_typesize; -} - -size_t HelloWorld::getCdrSerializedSize( - const HelloWorld& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + data.message().size() + 1; - - - current_alignment += (((1024*1024)) * 1) + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - - return current_alignment - initial_alignment; -} - - -void HelloWorld::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_index; - - scdr << m_message.c_str(); - - scdr << m_data; - - -} - -void HelloWorld::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_index; - - - - dcdr >> m_message; - - - - dcdr >> m_data; - - -} - - -bool HelloWorld::isKeyDefined() -{ - return false; -} - -void HelloWorld::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void HelloWorld::index( - uint32_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint32_t HelloWorld::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint32_t& HelloWorld::index() -{ - return m_index; -} - - -/*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ -void HelloWorld::message( - const std::string& _message) -{ - m_message = _message; -} - -/*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ -void HelloWorld::message( - std::string&& _message) -{ - m_message = std::move(_message); -} - -/*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ -const std::string& HelloWorld::message() const -{ - return m_message; -} - -/*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ -std::string& HelloWorld::message() -{ - return m_message; -} - - -/*! - * @brief This function copies the value in member data - * @param _data New value to be copied in member data - */ -void HelloWorld::data( - const std::array& _data) -{ - m_data = _data; -} - -/*! - * @brief This function moves the value in member data - * @param _data New value to be moved in member data - */ -void HelloWorld::data( - std::array&& _data) -{ - m_data = std::move(_data); -} - -/*! - * @brief This function returns a constant reference to member data - * @return Constant reference to member data - */ -const std::array& HelloWorld::data() const -{ - return m_data; -} - -/*! - * @brief This function returns a reference to member data - * @return Reference to member data - */ -std::array& HelloWorld::data() -{ - return m_data; -} - - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorldv1.h b/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorldv1.h deleted file mode 100644 index 8221e3d9fbe..00000000000 --- a/examples/cpp/dds/HelloWorldExampleSharedMem/HelloWorldv1.h +++ /dev/null @@ -1,272 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file HelloWorld.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#include - -#if FASTCDR_VERSION_MAJOR == 1 - -#ifndef _FAST_DDS_GENERATED_HELLOWORLD_H_ -#define _FAST_DDS_GENERATED_HELLOWORLD_H_ - - -#include - -#include -#include -#include -#include -#include -#include -#include - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define eProsima_user_DllExport -#endif // _WIN32 - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(HELLOWORLD_SOURCE) -#define HELLOWORLD_DllAPI __declspec( dllexport ) -#else -#define HELLOWORLD_DllAPI __declspec( dllimport ) -#endif // HELLOWORLD_SOURCE -#else -#define HELLOWORLD_DllAPI -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define HELLOWORLD_DllAPI -#endif // _WIN32 - -namespace eprosima { -namespace fastcdr { -class Cdr; -} // namespace fastcdr -} // namespace eprosima - - - - - -/*! - * @brief This class represents the structure HelloWorld defined by the user in the IDL file. - * @ingroup HelloWorld - */ -class HelloWorld -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport HelloWorld(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~HelloWorld(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object HelloWorld that will be copied. - */ - eProsima_user_DllExport HelloWorld( - const HelloWorld& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object HelloWorld that will be copied. - */ - eProsima_user_DllExport HelloWorld( - HelloWorld&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object HelloWorld that will be copied. - */ - eProsima_user_DllExport HelloWorld& operator =( - const HelloWorld& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object HelloWorld that will be copied. - */ - eProsima_user_DllExport HelloWorld& operator =( - HelloWorld&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x HelloWorld object to compare. - */ - eProsima_user_DllExport bool operator ==( - const HelloWorld& x) const; - - /*! - * @brief Comparison operator. - * @param x HelloWorld object to compare. - */ - eProsima_user_DllExport bool operator !=( - const HelloWorld& x) const; - - /*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ - eProsima_user_DllExport void index( - uint32_t _index); - - /*! - * @brief This function returns the value of member index - * @return Value of member index - */ - eProsima_user_DllExport uint32_t index() const; - - /*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ - eProsima_user_DllExport uint32_t& index(); - - - /*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ - eProsima_user_DllExport void message( - const std::string& _message); - - /*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ - eProsima_user_DllExport void message( - std::string&& _message); - - /*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ - eProsima_user_DllExport const std::string& message() const; - - /*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ - eProsima_user_DllExport std::string& message(); - - - /*! - * @brief This function copies the value in member data - * @param _data New value to be copied in member data - */ - eProsima_user_DllExport void data( - const std::array& _data); - - /*! - * @brief This function moves the value in member data - * @param _data New value to be moved in member data - */ - eProsima_user_DllExport void data( - std::array&& _data); - - /*! - * @brief This function returns a constant reference to member data - * @return Constant reference to member data - */ - eProsima_user_DllExport const std::array& data() const; - - /*! - * @brief This function returns a reference to member data - * @return Reference to member data - */ - eProsima_user_DllExport std::array& data(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const HelloWorld& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - uint32_t m_index; - std::string m_message; - std::array m_data; - -}; - - -#endif // _FAST_DDS_GENERATED_HELLOWORLD_H_ - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/HelloWorldExampleTCP/CMakeLists.txt b/examples/cpp/dds/HelloWorldExampleTCP/CMakeLists.txt index e98a20ff119..28cc54d5d2f 100644 --- a/examples/cpp/dds/HelloWorldExampleTCP/CMakeLists.txt +++ b/examples/cpp/dds/HelloWorldExampleTCP/CMakeLists.txt @@ -25,8 +25,8 @@ if(NOT foonathan_memory_FOUND) find_package(foonathan_memory REQUIRED) endif() -if(NOT fastrtps_FOUND) - find_package(fastrtps 2.12 REQUIRED) +if(NOT fastdds_FOUND) + find_package(fastdds 3 REQUIRED) endif() #Check C++11 @@ -55,6 +55,6 @@ target_compile_definitions(DDSHelloWorldExampleTCP PRIVATE $<$>,$>:__DEBUG> $<$:__INTERNALDEBUG> # Internal debug activated. ) -target_link_libraries(DDSHelloWorldExampleTCP fastrtps fastcdr foonathan_memory fastdds::optionparser) +target_link_libraries(DDSHelloWorldExampleTCP fastdds fastcdr foonathan_memory fastdds::optionparser) install(TARGETS DDSHelloWorldExampleTCP RUNTIME DESTINATION examples/cpp/dds/HelloWorldExampleTCP/${BIN_INSTALL_DIR}) diff --git a/examples/cpp/dds/HelloWorldExampleTCP/HelloWorld.cxx b/examples/cpp/dds/HelloWorldExampleTCP/HelloWorld.cxx deleted file mode 100644 index 4b415d67769..00000000000 --- a/examples/cpp/dds/HelloWorldExampleTCP/HelloWorld.cxx +++ /dev/null @@ -1,168 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file HelloWorld.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "HelloWorld.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - - - - -HelloWorld::HelloWorld() -{ -} - -HelloWorld::~HelloWorld() -{ -} - -HelloWorld::HelloWorld( - const HelloWorld& x) -{ - m_index = x.m_index; - m_message = x.m_message; -} - -HelloWorld::HelloWorld( - HelloWorld&& x) noexcept -{ - m_index = x.m_index; - m_message = std::move(x.m_message); -} - -HelloWorld& HelloWorld::operator =( - const HelloWorld& x) -{ - - m_index = x.m_index; - m_message = x.m_message; - return *this; -} - -HelloWorld& HelloWorld::operator =( - HelloWorld&& x) noexcept -{ - - m_index = x.m_index; - m_message = std::move(x.m_message); - return *this; -} - -bool HelloWorld::operator ==( - const HelloWorld& x) const -{ - return (m_index == x.m_index && - m_message == x.m_message); -} - -bool HelloWorld::operator !=( - const HelloWorld& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void HelloWorld::index( - uint32_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint32_t HelloWorld::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint32_t& HelloWorld::index() -{ - return m_index; -} - - -/*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ -void HelloWorld::message( - const std::string& _message) -{ - m_message = _message; -} - -/*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ -void HelloWorld::message( - std::string&& _message) -{ - m_message = std::move(_message); -} - -/*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ -const std::string& HelloWorld::message() const -{ - return m_message; -} - -/*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ -std::string& HelloWorld::message() -{ - return m_message; -} - - -// Include auxiliary functions like for serializing/deserializing. -#include "HelloWorldCdrAux.ipp" - -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/HelloWorldExampleTCP/HelloWorld.h b/examples/cpp/dds/HelloWorldExampleTCP/HelloWorld.hpp similarity index 69% rename from examples/cpp/dds/HelloWorldExampleTCP/HelloWorld.h rename to examples/cpp/dds/HelloWorldExampleTCP/HelloWorld.hpp index 5cd0ddba511..971fea8d920 100644 --- a/examples/cpp/dds/HelloWorldExampleTCP/HelloWorld.h +++ b/examples/cpp/dds/HelloWorldExampleTCP/HelloWorld.hpp @@ -13,32 +13,19 @@ // limitations under the License. /*! - * @file HelloWorld.h + * @file HelloWorld.hpp * This header file contains the declaration of the described types in the IDL file. * * This file was generated by the tool fastddsgen. */ -#include -#include "HelloWorldv1.h" +#ifndef _FAST_DDS_GENERATED_HELLOWORLD_HPP_ +#define _FAST_DDS_GENERATED_HELLOWORLD_HPP_ -#if FASTCDR_VERSION_MAJOR > 1 - -#ifndef _FAST_DDS_GENERATED_HELLOWORLD_H_ -#define _FAST_DDS_GENERATED_HELLOWORLD_H_ - -#include -#include #include -#include #include -#include - +#include #include -#include -#include - - #if defined(_WIN32) #if defined(EPROSIMA_USER_DLL_EXPORT) @@ -64,17 +51,6 @@ #define HELLOWORLD_DllAPI #endif // _WIN32 -namespace eprosima { -namespace fastcdr { -class Cdr; -class CdrSizeCalculator; -} // namespace fastcdr -} // namespace eprosima - - - - - /*! * @brief This class represents the structure HelloWorld defined by the user in the IDL file. * @ingroup HelloWorld @@ -86,73 +62,117 @@ class HelloWorld /*! * @brief Default constructor. */ - eProsima_user_DllExport HelloWorld(); + eProsima_user_DllExport HelloWorld() + { + } /*! * @brief Default destructor. */ - eProsima_user_DllExport ~HelloWorld(); + eProsima_user_DllExport ~HelloWorld() + { + } /*! * @brief Copy constructor. * @param x Reference to the object HelloWorld that will be copied. */ eProsima_user_DllExport HelloWorld( - const HelloWorld& x); + const HelloWorld& x) + { + m_index = x.m_index; + + m_message = x.m_message; + + } /*! * @brief Move constructor. * @param x Reference to the object HelloWorld that will be copied. */ eProsima_user_DllExport HelloWorld( - HelloWorld&& x) noexcept; + HelloWorld&& x) noexcept + { + m_index = x.m_index; + m_message = std::move(x.m_message); + } /*! * @brief Copy assignment. * @param x Reference to the object HelloWorld that will be copied. */ eProsima_user_DllExport HelloWorld& operator =( - const HelloWorld& x); + const HelloWorld& x) + { + + m_index = x.m_index; + + m_message = x.m_message; + + return *this; + } /*! * @brief Move assignment. * @param x Reference to the object HelloWorld that will be copied. */ eProsima_user_DllExport HelloWorld& operator =( - HelloWorld&& x) noexcept; + HelloWorld&& x) noexcept + { + + m_index = x.m_index; + m_message = std::move(x.m_message); + return *this; + } /*! * @brief Comparison operator. * @param x HelloWorld object to compare. */ eProsima_user_DllExport bool operator ==( - const HelloWorld& x) const; + const HelloWorld& x) const + { + return (m_index == x.m_index && + m_message == x.m_message); + } /*! * @brief Comparison operator. * @param x HelloWorld object to compare. */ eProsima_user_DllExport bool operator !=( - const HelloWorld& x) const; + const HelloWorld& x) const + { + return !(*this == x); + } /*! * @brief This function sets a value in member index * @param _index New value for member index */ eProsima_user_DllExport void index( - uint32_t _index); + uint32_t _index) + { + m_index = _index; + } /*! * @brief This function returns the value of member index * @return Value of member index */ - eProsima_user_DllExport uint32_t index() const; + eProsima_user_DllExport uint32_t index() const + { + return m_index; + } /*! * @brief This function returns a reference to member index * @return Reference to member index */ - eProsima_user_DllExport uint32_t& index(); + eProsima_user_DllExport uint32_t& index() + { + return m_index; + } /*! @@ -160,26 +180,40 @@ class HelloWorld * @param _message New value to be copied in member message */ eProsima_user_DllExport void message( - const std::string& _message); + const std::string& _message) + { + m_message = _message; + } /*! * @brief This function moves the value in member message * @param _message New value to be moved in member message */ eProsima_user_DllExport void message( - std::string&& _message); + std::string&& _message) + { + m_message = std::move(_message); + } /*! * @brief This function returns a constant reference to member message * @return Constant reference to member message */ - eProsima_user_DllExport const std::string& message() const; + eProsima_user_DllExport const std::string& message() const + { + return m_message; + } /*! * @brief This function returns a reference to member message * @return Reference to member message */ - eProsima_user_DllExport std::string& message(); + eProsima_user_DllExport std::string& message() + { + return m_message; + } + + private: @@ -188,8 +222,6 @@ class HelloWorld }; -#endif // _FAST_DDS_GENERATED_HELLOWORLD_H_ - +#endif // _FAST_DDS_GENERATED_HELLOWORLD_HPP_ -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/HelloWorldExampleTCP/HelloWorldCdrAux.hpp b/examples/cpp/dds/HelloWorldExampleTCP/HelloWorldCdrAux.hpp index 9f346d306be..6feb8a9da15 100644 --- a/examples/cpp/dds/HelloWorldExampleTCP/HelloWorldCdrAux.hpp +++ b/examples/cpp/dds/HelloWorldExampleTCP/HelloWorldCdrAux.hpp @@ -22,7 +22,7 @@ #ifndef _FAST_DDS_GENERATED_HELLOWORLDCDRAUX_HPP_ #define _FAST_DDS_GENERATED_HELLOWORLDCDRAUX_HPP_ -#include "HelloWorld.h" +#include "HelloWorld.hpp" constexpr uint32_t HelloWorld_max_cdr_typesize {268UL}; constexpr uint32_t HelloWorld_max_key_cdr_typesize {0UL}; @@ -34,8 +34,6 @@ namespace fastcdr { class Cdr; class CdrSizeCalculator; - - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const HelloWorld& data); diff --git a/examples/cpp/dds/HelloWorldExampleTCP/HelloWorldCdrAux.ipp b/examples/cpp/dds/HelloWorldExampleTCP/HelloWorldCdrAux.ipp index 42e91f3cc38..97df3fe9d9e 100644 --- a/examples/cpp/dds/HelloWorldExampleTCP/HelloWorldCdrAux.ipp +++ b/examples/cpp/dds/HelloWorldExampleTCP/HelloWorldCdrAux.ipp @@ -34,8 +34,6 @@ using namespace eprosima::fastcdr::exception; namespace eprosima { namespace fastcdr { - - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, diff --git a/examples/cpp/dds/HelloWorldExampleTCP/HelloWorldPubSubTypes.cxx b/examples/cpp/dds/HelloWorldExampleTCP/HelloWorldPubSubTypes.cxx index 85cb477896e..db018e69782 100644 --- a/examples/cpp/dds/HelloWorldExampleTCP/HelloWorldPubSubTypes.cxx +++ b/examples/cpp/dds/HelloWorldExampleTCP/HelloWorldPubSubTypes.cxx @@ -19,18 +19,18 @@ * This file was generated by the tool fastddsgen. */ +#include "HelloWorldPubSubTypes.h" +#include #include -#include "HelloWorldPubSubTypes.h" #include "HelloWorldCdrAux.hpp" +#include "HelloWorldTypeObjectSupport.hpp" using SerializedPayload_t = eprosima::fastrtps::rtps::SerializedPayload_t; using InstanceHandle_t = eprosima::fastrtps::rtps::InstanceHandle_t; using DataRepresentationId_t = eprosima::fastdds::dds::DataRepresentationId_t; - - HelloWorldPubSubType::HelloWorldPubSubType() { setName("HelloWorld"); @@ -219,3 +219,11 @@ bool HelloWorldPubSubType::getKey( return true; } +void HelloWorldPubSubType::register_type_object_representation() const +{ + register_HelloWorld_type_objects(); +} + + +// Include auxiliary functions like for serializing/deserializing. +#include "HelloWorldCdrAux.ipp" diff --git a/examples/cpp/dds/HelloWorldExampleTCP/HelloWorldPubSubTypes.h b/examples/cpp/dds/HelloWorldExampleTCP/HelloWorldPubSubTypes.h index cb61cd6ba23..a9b4ac119e0 100644 --- a/examples/cpp/dds/HelloWorldExampleTCP/HelloWorldPubSubTypes.h +++ b/examples/cpp/dds/HelloWorldExampleTCP/HelloWorldPubSubTypes.h @@ -27,9 +27,9 @@ #include #include #include -#include +#include -#include "HelloWorld.h" +#include "HelloWorld.hpp" #if !defined(GEN_API_VER) || (GEN_API_VER != 2) @@ -38,8 +38,6 @@ #endif // GEN_API_VER - - /*! * @brief This class represents the TopicDataType of the type HelloWorld defined by the user in the IDL file. * @ingroup HelloWorld @@ -90,6 +88,9 @@ class HelloWorldPubSubType : public eprosima::fastdds::dds::TopicDataType eProsima_user_DllExport void deleteData( void* data) override; + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + #ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED eProsima_user_DllExport inline bool is_bounded() const override { diff --git a/examples/cpp/dds/HelloWorldExampleTCP/HelloWorldPublisher.cpp b/examples/cpp/dds/HelloWorldExampleTCP/HelloWorldPublisher.cpp index 846e72e262b..ceb7fb25de3 100644 --- a/examples/cpp/dds/HelloWorldExampleTCP/HelloWorldPublisher.cpp +++ b/examples/cpp/dds/HelloWorldExampleTCP/HelloWorldPublisher.cpp @@ -20,7 +20,7 @@ #include "HelloWorldPublisher.h" #include #include -#include +#include #include diff --git a/examples/cpp/dds/HelloWorldExampleTCP/HelloWorldPublisher.h b/examples/cpp/dds/HelloWorldExampleTCP/HelloWorldPublisher.h index 1301ec490dd..63a228fe286 100644 --- a/examples/cpp/dds/HelloWorldExampleTCP/HelloWorldPublisher.h +++ b/examples/cpp/dds/HelloWorldExampleTCP/HelloWorldPublisher.h @@ -28,7 +28,7 @@ #include #include -#include "HelloWorld.h" +#include "HelloWorld.hpp" #include diff --git a/examples/cpp/dds/HelloWorldExampleTCP/HelloWorldSubscriber.cpp b/examples/cpp/dds/HelloWorldExampleTCP/HelloWorldSubscriber.cpp index 4e63d3587da..df49a3d256d 100644 --- a/examples/cpp/dds/HelloWorldExampleTCP/HelloWorldSubscriber.cpp +++ b/examples/cpp/dds/HelloWorldExampleTCP/HelloWorldSubscriber.cpp @@ -25,7 +25,7 @@ #include #include #include -#include +#include using namespace eprosima::fastdds::dds; using namespace eprosima::fastdds::rtps; @@ -179,7 +179,7 @@ void HelloWorldSubscriber::SubListener::on_data_available( DataReader* reader) { SampleInfo info; - if (reader->take_next_sample(&hello_, &info) == ReturnCode_t::RETCODE_OK) + if (reader->take_next_sample(&hello_, &info) == RETCODE_OK) { if (info.valid_data) { diff --git a/examples/cpp/dds/HelloWorldExampleTCP/HelloWorldSubscriber.h b/examples/cpp/dds/HelloWorldExampleTCP/HelloWorldSubscriber.h index 9f3c4c2eb10..15133e2ba63 100644 --- a/examples/cpp/dds/HelloWorldExampleTCP/HelloWorldSubscriber.h +++ b/examples/cpp/dds/HelloWorldExampleTCP/HelloWorldSubscriber.h @@ -28,7 +28,7 @@ #include #include -#include "HelloWorld.h" +#include "HelloWorld.hpp" #include diff --git a/examples/cpp/dds/HelloWorldExampleTCP/HelloWorldTypeObjectSupport.cxx b/examples/cpp/dds/HelloWorldExampleTCP/HelloWorldTypeObjectSupport.cxx new file mode 100644 index 00000000000..bfae95694f4 --- /dev/null +++ b/examples/cpp/dds/HelloWorldExampleTCP/HelloWorldTypeObjectSupport.cxx @@ -0,0 +1,248 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file HelloWorldTypeObjectSupport.cxx + * Source file containing the implementation to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#include "HelloWorldTypeObjectSupport.hpp" + +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include + +#include "HelloWorld.hpp" + + +using namespace eprosima::fastdds::dds::xtypes; + +void register_HelloWorld_type_objects() +{ + static std::once_flag once_flag; + std::call_once(once_flag, []() + { + register_HelloWorld_type_identifier(); + + }); +} + +void register_HelloWorld_type_identifier() +{ + { + StructTypeFlag struct_flags_HelloWorld = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::NOT_APPLIED, + false, false); + ReturnCode_t return_code_HelloWorld; + TypeIdentifierPair type_ids_HelloWorld; + QualifiedTypeName type_name_HelloWorld = "HelloWorld"; + eprosima::fastcdr::optional type_ann_builtin_HelloWorld; + eprosima::fastcdr::optional ann_custom_HelloWorld; + CompleteTypeDetail detail_HelloWorld = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_HelloWorld, ann_custom_HelloWorld, type_name_HelloWorld.to_string()); + CompleteStructHeader header_HelloWorld; + header_HelloWorld = TypeObjectUtils::build_complete_struct_header(TypeIdentifier(), detail_HelloWorld); + CompleteStructMemberSeq member_seq_HelloWorld; + { + return_code_HelloWorld = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_uint32_t", type_ids_HelloWorld); + + if (return_code_HelloWorld != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "index Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_index = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_index; + MemberId member_id_index = 0x00000000; + if (EK_COMPLETE == type_ids_HelloWorld.type_identifier1()._d() || TK_NONE == type_ids_HelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_HelloWorld.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_HelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_HelloWorld.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure index member TypeIdentifier inconsistent."); + return; + } + MemberName name_index = "index"; + eprosima::fastcdr::optional member_ann_builtin_index; + ann_custom_HelloWorld.reset(); + CompleteMemberDetail detail_index = TypeObjectUtils::build_complete_member_detail(name_index, member_ann_builtin_index, ann_custom_HelloWorld); + CompleteStructMember member_index = TypeObjectUtils::build_complete_struct_member(common_index, detail_index); + TypeObjectUtils::add_complete_struct_member(member_seq_HelloWorld, member_index); + } + { + return_code_HelloWorld = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_string_unbounded", type_ids_HelloWorld); + + if (return_code_HelloWorld != eprosima::fastdds::dds::RETCODE_OK) + { + std::string type_id_kind_anonymous_string_unbounded("TI_STRING8_SMALL"); + if (type_id_kind_anonymous_string_unbounded == "TI_STRING8_SMALL") + { + SBound bound = 0; + StringSTypeDefn string_sdefn = TypeObjectUtils::build_string_s_type_defn(bound); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_string_type_identifier(string_sdefn, + "anonymous_string_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else if (type_id_kind_anonymous_string_unbounded == "TI_STRING8_LARGE") + { + LBound bound = 255; + StringLTypeDefn string_ldefn = TypeObjectUtils::build_string_l_type_defn(bound); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_string_type_identifier(string_ldefn, + "anonymous_string_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded: Unknown String kind."); + return; + } + return_code_HelloWorld = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_string_unbounded", type_ids_HelloWorld); + if (return_code_HelloWorld != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded: Given String TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_message = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_message; + MemberId member_id_message = 0x00000001; + if (EK_COMPLETE == type_ids_HelloWorld.type_identifier1()._d() || TK_NONE == type_ids_HelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_message = TypeObjectUtils::build_common_struct_member(member_id_message, member_flags_message, type_ids_HelloWorld.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_HelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_message = TypeObjectUtils::build_common_struct_member(member_id_message, member_flags_message, type_ids_HelloWorld.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure message member TypeIdentifier inconsistent."); + return; + } + MemberName name_message = "message"; + eprosima::fastcdr::optional member_ann_builtin_message; + ann_custom_HelloWorld.reset(); + CompleteMemberDetail detail_message = TypeObjectUtils::build_complete_member_detail(name_message, member_ann_builtin_message, ann_custom_HelloWorld); + CompleteStructMember member_message = TypeObjectUtils::build_complete_struct_member(common_message, detail_message); + TypeObjectUtils::add_complete_struct_member(member_seq_HelloWorld, member_message); + } + CompleteStructType struct_type_HelloWorld = TypeObjectUtils::build_complete_struct_type(struct_flags_HelloWorld, header_HelloWorld, member_seq_HelloWorld); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_struct_type_object(struct_type_HelloWorld, type_name_HelloWorld.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "HelloWorld already registered in TypeObjectRegistry for a different type."); + } + return_code_HelloWorld = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "HelloWorld", type_ids_HelloWorld); + if (return_code_HelloWorld != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "HelloWorld: Given Struct TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } +} + diff --git a/examples/cpp/dds/HelloWorldExampleTCP/HelloWorldTypeObjectSupport.hpp b/examples/cpp/dds/HelloWorldExampleTCP/HelloWorldTypeObjectSupport.hpp new file mode 100644 index 00000000000..8650fc061e0 --- /dev/null +++ b/examples/cpp/dds/HelloWorldExampleTCP/HelloWorldTypeObjectSupport.hpp @@ -0,0 +1,54 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file HelloWorldTypeObjectSupport.hpp + * Header file containing the API required to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#ifndef _FAST_DDS_GENERATED_HELLOWORLD_TYPE_OBJECT_SUPPORT_HPP_ +#define _FAST_DDS_GENERATED_HELLOWORLD_TYPE_OBJECT_SUPPORT_HPP_ + + +#if defined(_WIN32) +#if defined(EPROSIMA_USER_DLL_EXPORT) +#define eProsima_user_DllExport __declspec( dllexport ) +#else +#define eProsima_user_DllExport +#endif // EPROSIMA_USER_DLL_EXPORT +#else +#define eProsima_user_DllExport +#endif // _WIN32 + +/** + * @brief Register every TypeObject representation defined in the IDL file in Fast DDS TypeObjectRegistry. + */ +eProsima_user_DllExport void register_HelloWorld_type_objects(); + +#ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +/** + * @brief Register HelloWorld related TypeIdentifier. + * Fully-descriptive TypeIdentifiers are directly registered. + * Hash TypeIdentifiers require to fill the TypeObject information and hash it, consequently, the TypeObject is + * indirectly registered as well. + */ +void register_HelloWorld_type_identifier(); + + +#endif // DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +#endif // _FAST_DDS_GENERATED_HELLOWORLD_TYPE_OBJECT_SUPPORT_HPP_ diff --git a/examples/cpp/dds/HelloWorldExampleTCP/HelloWorld_main.cpp b/examples/cpp/dds/HelloWorldExampleTCP/HelloWorld_main.cpp index 94a00bf20c2..f1b1677e472 100644 --- a/examples/cpp/dds/HelloWorldExampleTCP/HelloWorld_main.cpp +++ b/examples/cpp/dds/HelloWorldExampleTCP/HelloWorld_main.cpp @@ -17,16 +17,13 @@ * */ -#include "HelloWorldPublisher.h" -#include "HelloWorldSubscriber.h" - -#include -#include - #include #include +#include "HelloWorldPublisher.h" +#include "HelloWorldSubscriber.h" + namespace option = eprosima::option; struct Arg : public option::Arg @@ -311,6 +308,5 @@ int main( break; } } - Domain::stopAll(); return 0; } diff --git a/examples/cpp/dds/HelloWorldExampleTCP/HelloWorldv1.cxx b/examples/cpp/dds/HelloWorldExampleTCP/HelloWorldv1.cxx deleted file mode 100644 index 90e82ea88a7..00000000000 --- a/examples/cpp/dds/HelloWorldExampleTCP/HelloWorldv1.cxx +++ /dev/null @@ -1,286 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file HelloWorld.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "HelloWorld.h" - -#if FASTCDR_VERSION_MAJOR == 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - -namespace helper { namespace internal { - -enum class Size { - UInt8, - UInt16, - UInt32, - UInt64, -}; - -constexpr Size get_size(int s) { - return (s <= 8 ) ? Size::UInt8: - (s <= 16) ? Size::UInt16: - (s <= 32) ? Size::UInt32: Size::UInt64; -} - -template -struct FindTypeH; - -template<> -struct FindTypeH { - using type = std::uint8_t; -}; - -template<> -struct FindTypeH { - using type = std::uint16_t; -}; - -template<> -struct FindTypeH { - using type = std::uint32_t; -}; - -template<> -struct FindTypeH { - using type = std::uint64_t; -}; -} - -template -struct FindType { - using type = typename internal::FindTypeH::type; -}; -} - -#define HelloWorld_max_cdr_typesize 268ULL; - - - - -HelloWorld::HelloWorld() -{ - // unsigned long m_index - m_index = 0; - // /type_d() m_message - - -} - -HelloWorld::~HelloWorld() -{ -} - -HelloWorld::HelloWorld( - const HelloWorld& x) -{ - m_index = x.m_index; - - - m_message = x.m_message; - -} - -HelloWorld::HelloWorld( - HelloWorld&& x) noexcept -{ - m_index = x.m_index; - - - m_message = std::move(x.m_message); - -} - -HelloWorld& HelloWorld::operator =( - const HelloWorld& x) -{ - m_index = x.m_index; - - - m_message = x.m_message; - - return *this; -} - -HelloWorld& HelloWorld::operator =( - HelloWorld&& x) noexcept -{ - m_index = x.m_index; - - - m_message = std::move(x.m_message); - - return *this; -} - -bool HelloWorld::operator ==( - const HelloWorld& x) const -{ - return (m_index == x.m_index && - m_message == x.m_message); -} - -bool HelloWorld::operator !=( - const HelloWorld& x) const -{ - return !(*this == x); -} - -size_t HelloWorld::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return HelloWorld_max_cdr_typesize; -} - -size_t HelloWorld::getCdrSerializedSize( - const HelloWorld& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + data.message().size() + 1; - - - return current_alignment - initial_alignment; -} - - -void HelloWorld::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_index; - - scdr << m_message.c_str(); - -} - -void HelloWorld::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_index; - - - - dcdr >> m_message; - - -} - - -bool HelloWorld::isKeyDefined() -{ - return false; -} - -void HelloWorld::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void HelloWorld::index( - uint32_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint32_t HelloWorld::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint32_t& HelloWorld::index() -{ - return m_index; -} - - -/*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ -void HelloWorld::message( - const std::string& _message) -{ - m_message = _message; -} - -/*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ -void HelloWorld::message( - std::string&& _message) -{ - m_message = std::move(_message); -} - -/*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ -const std::string& HelloWorld::message() const -{ - return m_message; -} - -/*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ -std::string& HelloWorld::message() -{ - return m_message; -} - - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/HelloWorldExampleTCP/HelloWorldv1.h b/examples/cpp/dds/HelloWorldExampleTCP/HelloWorldv1.h deleted file mode 100644 index 9f6f726e0ab..00000000000 --- a/examples/cpp/dds/HelloWorldExampleTCP/HelloWorldv1.h +++ /dev/null @@ -1,244 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file HelloWorld.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#include - -#if FASTCDR_VERSION_MAJOR == 1 - -#ifndef _FAST_DDS_GENERATED_HELLOWORLD_H_ -#define _FAST_DDS_GENERATED_HELLOWORLD_H_ - - -#include - -#include -#include -#include -#include -#include -#include -#include - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define eProsima_user_DllExport -#endif // _WIN32 - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(HELLOWORLD_SOURCE) -#define HELLOWORLD_DllAPI __declspec( dllexport ) -#else -#define HELLOWORLD_DllAPI __declspec( dllimport ) -#endif // HELLOWORLD_SOURCE -#else -#define HELLOWORLD_DllAPI -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define HELLOWORLD_DllAPI -#endif // _WIN32 - -namespace eprosima { -namespace fastcdr { -class Cdr; -} // namespace fastcdr -} // namespace eprosima - - - - - -/*! - * @brief This class represents the structure HelloWorld defined by the user in the IDL file. - * @ingroup HelloWorld - */ -class HelloWorld -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport HelloWorld(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~HelloWorld(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object HelloWorld that will be copied. - */ - eProsima_user_DllExport HelloWorld( - const HelloWorld& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object HelloWorld that will be copied. - */ - eProsima_user_DllExport HelloWorld( - HelloWorld&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object HelloWorld that will be copied. - */ - eProsima_user_DllExport HelloWorld& operator =( - const HelloWorld& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object HelloWorld that will be copied. - */ - eProsima_user_DllExport HelloWorld& operator =( - HelloWorld&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x HelloWorld object to compare. - */ - eProsima_user_DllExport bool operator ==( - const HelloWorld& x) const; - - /*! - * @brief Comparison operator. - * @param x HelloWorld object to compare. - */ - eProsima_user_DllExport bool operator !=( - const HelloWorld& x) const; - - /*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ - eProsima_user_DllExport void index( - uint32_t _index); - - /*! - * @brief This function returns the value of member index - * @return Value of member index - */ - eProsima_user_DllExport uint32_t index() const; - - /*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ - eProsima_user_DllExport uint32_t& index(); - - - /*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ - eProsima_user_DllExport void message( - const std::string& _message); - - /*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ - eProsima_user_DllExport void message( - std::string&& _message); - - /*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ - eProsima_user_DllExport const std::string& message() const; - - /*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ - eProsima_user_DllExport std::string& message(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const HelloWorld& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - uint32_t m_index; - std::string m_message; - -}; - - -#endif // _FAST_DDS_GENERATED_HELLOWORLD_H_ - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/HistoryKind/CMakeLists.txt b/examples/cpp/dds/HistoryKind/CMakeLists.txt index 9f6462776c9..217442c05fc 100644 --- a/examples/cpp/dds/HistoryKind/CMakeLists.txt +++ b/examples/cpp/dds/HistoryKind/CMakeLists.txt @@ -25,8 +25,8 @@ if(NOT foonathan_memory_FOUND) find_package(foonathan_memory REQUIRED) endif() -if(NOT fastrtps_FOUND) - find_package(fastrtps 2.12 REQUIRED) +if(NOT fastdds_FOUND) + find_package(fastdds 2.12 REQUIRED) endif() #Check C++11 @@ -46,7 +46,7 @@ target_compile_definitions(DDSHistoryKind PRIVATE $<$>,$>:__DEBUG> $<$:__INTERNALDEBUG> # Internal debug activated. ) -target_link_libraries(DDSHistoryKind fastrtps fastcdr foonathan_memory) +target_link_libraries(DDSHistoryKind fastdds fastcdr foonathan_memory) install(TARGETS DDSHistoryKind RUNTIME DESTINATION examples/cpp/dds/HistoryKind/${BIN_INSTALL_DIR} ) diff --git a/examples/cpp/dds/HistoryKind/pastsamples.cpp b/examples/cpp/dds/HistoryKind/pastsamples.cpp index 6561d835ede..25937ac9182 100644 --- a/examples/cpp/dds/HistoryKind/pastsamples.cpp +++ b/examples/cpp/dds/HistoryKind/pastsamples.cpp @@ -193,14 +193,14 @@ void pastsamples() //Read the contents of both histories: std::cout << "The Keep All Subscriber holds: " << std::endl; - while (myReader1->read_next_sample(&my_sample, &sample_info) == ReturnCode_t::RETCODE_OK) + while (myReader1->read_next_sample(&my_sample, &sample_info) == RETCODE_OK) { std::cout << std::to_string(my_sample.index()) << " "; } std::cout << std::endl; std::cout << "The Keep Last (Depth 10) Subscriber holds: " << std::endl; - while (myReader2->read_next_sample(&my_sample, &sample_info) == ReturnCode_t::RETCODE_OK) + while (myReader2->read_next_sample(&my_sample, &sample_info) == RETCODE_OK) { std::cout << std::to_string(my_sample.index()) << " "; } diff --git a/examples/cpp/dds/HistoryKind/sample.cxx b/examples/cpp/dds/HistoryKind/sample.cxx deleted file mode 100644 index 360d4a1b2b2..00000000000 --- a/examples/cpp/dds/HistoryKind/sample.cxx +++ /dev/null @@ -1,158 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file sample.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "sample.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - - - - -sample::sample() -{ -} - -sample::~sample() -{ -} - -sample::sample( - const sample& x) -{ - m_index = x.m_index; - m_key_value = x.m_key_value; -} - -sample::sample( - sample&& x) noexcept -{ - m_index = x.m_index; - m_key_value = x.m_key_value; -} - -sample& sample::operator =( - const sample& x) -{ - - m_index = x.m_index; - m_key_value = x.m_key_value; - return *this; -} - -sample& sample::operator =( - sample&& x) noexcept -{ - - m_index = x.m_index; - m_key_value = x.m_key_value; - return *this; -} - -bool sample::operator ==( - const sample& x) const -{ - return (m_index == x.m_index && - m_key_value == x.m_key_value); -} - -bool sample::operator !=( - const sample& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void sample::index( - uint8_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint8_t sample::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint8_t& sample::index() -{ - return m_index; -} - - -/*! - * @brief This function sets a value in member key_value - * @param _key_value New value for member key_value - */ -void sample::key_value( - uint8_t _key_value) -{ - m_key_value = _key_value; -} - -/*! - * @brief This function returns the value of member key_value - * @return Value of member key_value - */ -uint8_t sample::key_value() const -{ - return m_key_value; -} - -/*! - * @brief This function returns a reference to member key_value - * @return Reference to member key_value - */ -uint8_t& sample::key_value() -{ - return m_key_value; -} - - -// Include auxiliary functions like for serializing/deserializing. -#include "sampleCdrAux.ipp" - -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/Keys/sample.h b/examples/cpp/dds/HistoryKind/sample.hpp similarity index 69% rename from examples/cpp/dds/Keys/sample.h rename to examples/cpp/dds/HistoryKind/sample.hpp index c050c8527cc..3023a792269 100644 --- a/examples/cpp/dds/Keys/sample.h +++ b/examples/cpp/dds/HistoryKind/sample.hpp @@ -13,32 +13,17 @@ // limitations under the License. /*! - * @file sample.h + * @file sample.hpp * This header file contains the declaration of the described types in the IDL file. * * This file was generated by the tool fastddsgen. */ -#include -#include "samplev1.h" +#ifndef _FAST_DDS_GENERATED_SAMPLE_HPP_ +#define _FAST_DDS_GENERATED_SAMPLE_HPP_ -#if FASTCDR_VERSION_MAJOR > 1 - -#ifndef _FAST_DDS_GENERATED_SAMPLE_H_ -#define _FAST_DDS_GENERATED_SAMPLE_H_ - -#include -#include #include -#include -#include -#include - -#include -#include -#include - - +#include #if defined(_WIN32) #if defined(EPROSIMA_USER_DLL_EXPORT) @@ -64,17 +49,6 @@ #define SAMPLE_DllAPI #endif // _WIN32 -namespace eprosima { -namespace fastcdr { -class Cdr; -class CdrSizeCalculator; -} // namespace fastcdr -} // namespace eprosima - - - - - /*! * @brief This class represents the structure sample defined by the user in the IDL file. * @ingroup sample @@ -86,73 +60,117 @@ class sample /*! * @brief Default constructor. */ - eProsima_user_DllExport sample(); + eProsima_user_DllExport sample() + { + } /*! * @brief Default destructor. */ - eProsima_user_DllExport ~sample(); + eProsima_user_DllExport ~sample() + { + } /*! * @brief Copy constructor. * @param x Reference to the object sample that will be copied. */ eProsima_user_DllExport sample( - const sample& x); + const sample& x) + { + m_index = x.m_index; + + m_key_value = x.m_key_value; + + } /*! * @brief Move constructor. * @param x Reference to the object sample that will be copied. */ eProsima_user_DllExport sample( - sample&& x) noexcept; + sample&& x) noexcept + { + m_index = x.m_index; + m_key_value = x.m_key_value; + } /*! * @brief Copy assignment. * @param x Reference to the object sample that will be copied. */ eProsima_user_DllExport sample& operator =( - const sample& x); + const sample& x) + { + + m_index = x.m_index; + + m_key_value = x.m_key_value; + + return *this; + } /*! * @brief Move assignment. * @param x Reference to the object sample that will be copied. */ eProsima_user_DllExport sample& operator =( - sample&& x) noexcept; + sample&& x) noexcept + { + + m_index = x.m_index; + m_key_value = x.m_key_value; + return *this; + } /*! * @brief Comparison operator. * @param x sample object to compare. */ eProsima_user_DllExport bool operator ==( - const sample& x) const; + const sample& x) const + { + return (m_index == x.m_index && + m_key_value == x.m_key_value); + } /*! * @brief Comparison operator. * @param x sample object to compare. */ eProsima_user_DllExport bool operator !=( - const sample& x) const; + const sample& x) const + { + return !(*this == x); + } /*! * @brief This function sets a value in member index * @param _index New value for member index */ eProsima_user_DllExport void index( - uint8_t _index); + uint8_t _index) + { + m_index = _index; + } /*! * @brief This function returns the value of member index * @return Value of member index */ - eProsima_user_DllExport uint8_t index() const; + eProsima_user_DllExport uint8_t index() const + { + return m_index; + } /*! * @brief This function returns a reference to member index * @return Reference to member index */ - eProsima_user_DllExport uint8_t& index(); + eProsima_user_DllExport uint8_t& index() + { + return m_index; + } /*! @@ -160,19 +178,30 @@ class sample * @param _key_value New value for member key_value */ eProsima_user_DllExport void key_value( - uint8_t _key_value); + uint8_t _key_value) + { + m_key_value = _key_value; + } /*! * @brief This function returns the value of member key_value * @return Value of member key_value */ - eProsima_user_DllExport uint8_t key_value() const; + eProsima_user_DllExport uint8_t key_value() const + { + return m_key_value; + } /*! * @brief This function returns a reference to member key_value * @return Reference to member key_value */ - eProsima_user_DllExport uint8_t& key_value(); + eProsima_user_DllExport uint8_t& key_value() + { + return m_key_value; + } + + private: @@ -181,8 +210,6 @@ class sample }; -#endif // _FAST_DDS_GENERATED_SAMPLE_H_ - +#endif // _FAST_DDS_GENERATED_SAMPLE_HPP_ -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/HistoryKind/sampleCdrAux.hpp b/examples/cpp/dds/HistoryKind/sampleCdrAux.hpp index 18ed5857add..b80dff31248 100644 --- a/examples/cpp/dds/HistoryKind/sampleCdrAux.hpp +++ b/examples/cpp/dds/HistoryKind/sampleCdrAux.hpp @@ -22,7 +22,7 @@ #ifndef _FAST_DDS_GENERATED_SAMPLECDRAUX_HPP_ #define _FAST_DDS_GENERATED_SAMPLECDRAUX_HPP_ -#include "sample.h" +#include "sample.hpp" constexpr uint32_t sample_max_cdr_typesize {6UL}; constexpr uint32_t sample_max_key_cdr_typesize {1UL}; @@ -34,8 +34,6 @@ namespace fastcdr { class Cdr; class CdrSizeCalculator; - - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const sample& data); diff --git a/examples/cpp/dds/HistoryKind/sampleCdrAux.ipp b/examples/cpp/dds/HistoryKind/sampleCdrAux.ipp index 11bc4709a6e..17a3d1025fc 100644 --- a/examples/cpp/dds/HistoryKind/sampleCdrAux.ipp +++ b/examples/cpp/dds/HistoryKind/sampleCdrAux.ipp @@ -34,8 +34,6 @@ using namespace eprosima::fastcdr::exception; namespace eprosima { namespace fastcdr { - - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, diff --git a/examples/cpp/dds/HistoryKind/samplePubSubTypes.cxx b/examples/cpp/dds/HistoryKind/samplePubSubTypes.cxx index 9095d77083a..cae143a08ca 100644 --- a/examples/cpp/dds/HistoryKind/samplePubSubTypes.cxx +++ b/examples/cpp/dds/HistoryKind/samplePubSubTypes.cxx @@ -19,18 +19,18 @@ * This file was generated by the tool fastddsgen. */ +#include "samplePubSubTypes.h" +#include #include -#include "samplePubSubTypes.h" #include "sampleCdrAux.hpp" +#include "sampleTypeObjectSupport.hpp" using SerializedPayload_t = eprosima::fastrtps::rtps::SerializedPayload_t; using InstanceHandle_t = eprosima::fastrtps::rtps::InstanceHandle_t; using DataRepresentationId_t = eprosima::fastdds::dds::DataRepresentationId_t; - - samplePubSubType::samplePubSubType() { setName("sample"); @@ -219,3 +219,11 @@ bool samplePubSubType::getKey( return true; } +void samplePubSubType::register_type_object_representation() const +{ + register_sample_type_objects(); +} + + +// Include auxiliary functions like for serializing/deserializing. +#include "sampleCdrAux.ipp" diff --git a/examples/cpp/dds/HistoryKind/samplePubSubTypes.h b/examples/cpp/dds/HistoryKind/samplePubSubTypes.h index ec881115211..9e59aa58042 100644 --- a/examples/cpp/dds/HistoryKind/samplePubSubTypes.h +++ b/examples/cpp/dds/HistoryKind/samplePubSubTypes.h @@ -27,9 +27,9 @@ #include #include #include -#include +#include -#include "sample.h" +#include "sample.hpp" #if !defined(GEN_API_VER) || (GEN_API_VER != 2) @@ -38,8 +38,6 @@ #endif // GEN_API_VER - - /*! * @brief This class represents the TopicDataType of the type sample defined by the user in the IDL file. * @ingroup sample @@ -90,6 +88,9 @@ class samplePubSubType : public eprosima::fastdds::dds::TopicDataType eProsima_user_DllExport void deleteData( void* data) override; + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + #ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED eProsima_user_DllExport inline bool is_bounded() const override { diff --git a/examples/cpp/dds/HistoryKind/sampleTypeObjectSupport.cxx b/examples/cpp/dds/HistoryKind/sampleTypeObjectSupport.cxx new file mode 100644 index 00000000000..3719bbf77e6 --- /dev/null +++ b/examples/cpp/dds/HistoryKind/sampleTypeObjectSupport.cxx @@ -0,0 +1,224 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file sampleTypeObjectSupport.cxx + * Source file containing the implementation to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#include "sampleTypeObjectSupport.hpp" + +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include + +#include "sample.hpp" + + +using namespace eprosima::fastdds::dds::xtypes; + +void register_sample_type_objects() +{ + static std::once_flag once_flag; + std::call_once(once_flag, []() + { + register_sample_type_identifier(); + + }); +} + +void register_sample_type_identifier() +{ + { + StructTypeFlag struct_flags_sample = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::NOT_APPLIED, + false, false); + ReturnCode_t return_code_sample; + TypeIdentifierPair type_ids_sample; + QualifiedTypeName type_name_sample = "sample"; + eprosima::fastcdr::optional type_ann_builtin_sample; + eprosima::fastcdr::optional ann_custom_sample; + CompleteTypeDetail detail_sample = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_sample, ann_custom_sample, type_name_sample.to_string()); + CompleteStructHeader header_sample; + header_sample = TypeObjectUtils::build_complete_struct_header(TypeIdentifier(), detail_sample); + CompleteStructMemberSeq member_seq_sample; + { + return_code_sample = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_byte", type_ids_sample); + + if (return_code_sample != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "index Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_index = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_index; + MemberId member_id_index = 0x00000000; + if (EK_COMPLETE == type_ids_sample.type_identifier1()._d() || TK_NONE == type_ids_sample.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_sample.type_identifier1()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_sample.type_identifier1()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_sample.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_sample.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_sample.type_identifier2()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_sample.type_identifier2()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_sample.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure index member TypeIdentifier inconsistent."); + return; + } + MemberName name_index = "index"; + eprosima::fastcdr::optional member_ann_builtin_index; + ann_custom_sample.reset(); + CompleteMemberDetail detail_index = TypeObjectUtils::build_complete_member_detail(name_index, member_ann_builtin_index, ann_custom_sample); + CompleteStructMember member_index = TypeObjectUtils::build_complete_struct_member(common_index, detail_index); + TypeObjectUtils::add_complete_struct_member(member_seq_sample, member_index); + } + { + return_code_sample = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_byte", type_ids_sample); + + if (return_code_sample != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "key_value Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_key_value = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, true, false); + CommonStructMember common_key_value; + MemberId member_id_key_value = 0x00000001; + if (EK_COMPLETE == type_ids_sample.type_identifier1()._d() || TK_NONE == type_ids_sample.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_sample.type_identifier1()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_sample.type_identifier1()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_key_value = TypeObjectUtils::build_common_struct_member(member_id_key_value, member_flags_key_value, type_ids_sample.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_sample.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_sample.type_identifier2()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_sample.type_identifier2()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_key_value = TypeObjectUtils::build_common_struct_member(member_id_key_value, member_flags_key_value, type_ids_sample.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure key_value member TypeIdentifier inconsistent."); + return; + } + MemberName name_key_value = "key_value"; + eprosima::fastcdr::optional member_ann_builtin_key_value; + ann_custom_sample.reset(); + AppliedAnnotationSeq tmp_ann_custom_key_value; + eprosima::fastcdr::optional unit_key_value; + eprosima::fastcdr::optional min_key_value; + eprosima::fastcdr::optional max_key_value; + eprosima::fastcdr::optional hash_id_key_value; + if (unit_key_value.has_value() || min_key_value.has_value() || max_key_value.has_value() || hash_id_key_value.has_value()) + { + member_ann_builtin_key_value = TypeObjectUtils::build_applied_builtin_member_annotations(unit_key_value, min_key_value, max_key_value, hash_id_key_value); + } + if (!tmp_ann_custom_key_value.empty()) + { + ann_custom_sample = tmp_ann_custom_key_value; + } + CompleteMemberDetail detail_key_value = TypeObjectUtils::build_complete_member_detail(name_key_value, member_ann_builtin_key_value, ann_custom_sample); + CompleteStructMember member_key_value = TypeObjectUtils::build_complete_struct_member(common_key_value, detail_key_value); + TypeObjectUtils::add_complete_struct_member(member_seq_sample, member_key_value); + } + CompleteStructType struct_type_sample = TypeObjectUtils::build_complete_struct_type(struct_flags_sample, header_sample, member_seq_sample); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_struct_type_object(struct_type_sample, type_name_sample.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "sample already registered in TypeObjectRegistry for a different type."); + } + return_code_sample = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "sample", type_ids_sample); + if (return_code_sample != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "sample: Given Struct TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } +} + diff --git a/examples/cpp/dds/HistoryKind/sampleTypeObjectSupport.hpp b/examples/cpp/dds/HistoryKind/sampleTypeObjectSupport.hpp new file mode 100644 index 00000000000..5ad7f2e5e07 --- /dev/null +++ b/examples/cpp/dds/HistoryKind/sampleTypeObjectSupport.hpp @@ -0,0 +1,54 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file sampleTypeObjectSupport.hpp + * Header file containing the API required to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#ifndef _FAST_DDS_GENERATED_SAMPLE_TYPE_OBJECT_SUPPORT_HPP_ +#define _FAST_DDS_GENERATED_SAMPLE_TYPE_OBJECT_SUPPORT_HPP_ + + +#if defined(_WIN32) +#if defined(EPROSIMA_USER_DLL_EXPORT) +#define eProsima_user_DllExport __declspec( dllexport ) +#else +#define eProsima_user_DllExport +#endif // EPROSIMA_USER_DLL_EXPORT +#else +#define eProsima_user_DllExport +#endif // _WIN32 + +/** + * @brief Register every TypeObject representation defined in the IDL file in Fast DDS TypeObjectRegistry. + */ +eProsima_user_DllExport void register_sample_type_objects(); + +#ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +/** + * @brief Register sample related TypeIdentifier. + * Fully-descriptive TypeIdentifiers are directly registered. + * Hash TypeIdentifiers require to fill the TypeObject information and hash it, consequently, the TypeObject is + * indirectly registered as well. + */ +void register_sample_type_identifier(); + + +#endif // DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +#endif // _FAST_DDS_GENERATED_SAMPLE_TYPE_OBJECT_SUPPORT_HPP_ diff --git a/examples/cpp/dds/HistoryKind/samplev1.cxx b/examples/cpp/dds/HistoryKind/samplev1.cxx deleted file mode 100644 index 3b735befaf8..00000000000 --- a/examples/cpp/dds/HistoryKind/samplev1.cxx +++ /dev/null @@ -1,280 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file sample.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "sample.h" - -#if FASTCDR_VERSION_MAJOR == 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - -namespace helper { namespace internal { - -enum class Size { - UInt8, - UInt16, - UInt32, - UInt64, -}; - -constexpr Size get_size(int s) { - return (s <= 8 ) ? Size::UInt8: - (s <= 16) ? Size::UInt16: - (s <= 32) ? Size::UInt32: Size::UInt64; -} - -template -struct FindTypeH; - -template<> -struct FindTypeH { - using type = std::uint8_t; -}; - -template<> -struct FindTypeH { - using type = std::uint16_t; -}; - -template<> -struct FindTypeH { - using type = std::uint32_t; -}; - -template<> -struct FindTypeH { - using type = std::uint64_t; -}; -} - -template -struct FindType { - using type = typename internal::FindTypeH::type; -}; -} - -#define sample_max_cdr_typesize 6ULL; - - - - -sample::sample() -{ - // octet m_index - m_index = 0; - // octet m_key_value - m_key_value = 0; - -} - -sample::~sample() -{ -} - -sample::sample( - const sample& x) -{ - m_index = x.m_index; - - - m_key_value = x.m_key_value; - -} - -sample::sample( - sample&& x) noexcept -{ - m_index = x.m_index; - - - m_key_value = x.m_key_value; - -} - -sample& sample::operator =( - const sample& x) -{ - m_index = x.m_index; - - - m_key_value = x.m_key_value; - - return *this; -} - -sample& sample::operator =( - sample&& x) noexcept -{ - m_index = x.m_index; - - - m_key_value = x.m_key_value; - - return *this; -} - -bool sample::operator ==( - const sample& x) const -{ - return (m_index == x.m_index && - m_key_value == x.m_key_value); -} - -bool sample::operator !=( - const sample& x) const -{ - return !(*this == x); -} - -size_t sample::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return sample_max_cdr_typesize; -} - -size_t sample::getCdrSerializedSize( - const sample& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - return current_alignment - initial_alignment; -} - - -void sample::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_index; - - scdr << m_key_value; - -} - -void sample::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_index; - - - - dcdr >> m_key_value; - - -} - - -bool sample::isKeyDefined() -{ - return true; -} - -void sample::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; - - - scdr << m_key_value; - -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void sample::index( - uint8_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint8_t sample::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint8_t& sample::index() -{ - return m_index; -} - - -/*! - * @brief This function sets a value in member key_value - * @param _key_value New value for member key_value - */ -void sample::key_value( - uint8_t _key_value) -{ - m_key_value = _key_value; -} - -/*! - * @brief This function returns the value of member key_value - * @return Value of member key_value - */ -uint8_t sample::key_value() const -{ - return m_key_value; -} - -/*! - * @brief This function returns a reference to member key_value - * @return Reference to member key_value - */ -uint8_t& sample::key_value() -{ - return m_key_value; -} - - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/HistoryKind/samplev1.h b/examples/cpp/dds/HistoryKind/samplev1.h deleted file mode 100644 index 4fa288d1bc9..00000000000 --- a/examples/cpp/dds/HistoryKind/samplev1.h +++ /dev/null @@ -1,237 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file sample.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#include - -#if FASTCDR_VERSION_MAJOR == 1 - -#ifndef _FAST_DDS_GENERATED_SAMPLE_H_ -#define _FAST_DDS_GENERATED_SAMPLE_H_ - - -#include - -#include -#include -#include -#include -#include -#include -#include - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define eProsima_user_DllExport -#endif // _WIN32 - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(SAMPLE_SOURCE) -#define SAMPLE_DllAPI __declspec( dllexport ) -#else -#define SAMPLE_DllAPI __declspec( dllimport ) -#endif // SAMPLE_SOURCE -#else -#define SAMPLE_DllAPI -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define SAMPLE_DllAPI -#endif // _WIN32 - -namespace eprosima { -namespace fastcdr { -class Cdr; -} // namespace fastcdr -} // namespace eprosima - - - - - -/*! - * @brief This class represents the structure sample defined by the user in the IDL file. - * @ingroup sample - */ -class sample -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport sample(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~sample(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object sample that will be copied. - */ - eProsima_user_DllExport sample( - const sample& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object sample that will be copied. - */ - eProsima_user_DllExport sample( - sample&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object sample that will be copied. - */ - eProsima_user_DllExport sample& operator =( - const sample& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object sample that will be copied. - */ - eProsima_user_DllExport sample& operator =( - sample&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x sample object to compare. - */ - eProsima_user_DllExport bool operator ==( - const sample& x) const; - - /*! - * @brief Comparison operator. - * @param x sample object to compare. - */ - eProsima_user_DllExport bool operator !=( - const sample& x) const; - - /*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ - eProsima_user_DllExport void index( - uint8_t _index); - - /*! - * @brief This function returns the value of member index - * @return Value of member index - */ - eProsima_user_DllExport uint8_t index() const; - - /*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ - eProsima_user_DllExport uint8_t& index(); - - - /*! - * @brief This function sets a value in member key_value - * @param _key_value New value for member key_value - */ - eProsima_user_DllExport void key_value( - uint8_t _key_value); - - /*! - * @brief This function returns the value of member key_value - * @return Value of member key_value - */ - eProsima_user_DllExport uint8_t key_value() const; - - /*! - * @brief This function returns a reference to member key_value - * @return Reference to member key_value - */ - eProsima_user_DllExport uint8_t& key_value(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const sample& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - uint8_t m_index; - uint8_t m_key_value; - -}; - - -#endif // _FAST_DDS_GENERATED_SAMPLE_H_ - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/Keys/CMakeLists.txt b/examples/cpp/dds/Keys/CMakeLists.txt index 2cb9c151b80..8bee7df7fa0 100644 --- a/examples/cpp/dds/Keys/CMakeLists.txt +++ b/examples/cpp/dds/Keys/CMakeLists.txt @@ -25,8 +25,8 @@ if(NOT foonathan_memory_FOUND) find_package(foonathan_memory REQUIRED) endif() -if(NOT fastrtps_FOUND) - find_package(fastrtps 2.12 REQUIRED) +if(NOT fastdds_FOUND) + find_package(fastdds 3 REQUIRED) endif() #Check C++11 @@ -46,7 +46,7 @@ target_compile_definitions(DDSKeys PRIVATE $<$>,$>:__DEBUG> $<$:__INTERNALDEBUG> # Internal debug activated. ) -target_link_libraries(DDSKeys fastrtps fastcdr foonathan_memory) +target_link_libraries(DDSKeys fastdds fastcdr foonathan_memory) install(TARGETS DDSKeys RUNTIME DESTINATION examples/cpp/dds/Keys/${BIN_INSTALL_DIR} ) diff --git a/examples/cpp/dds/Keys/keys.cpp b/examples/cpp/dds/Keys/keys.cpp index d32c03e1513..9faba4e251d 100644 --- a/examples/cpp/dds/Keys/keys.cpp +++ b/examples/cpp/dds/Keys/keys.cpp @@ -141,7 +141,7 @@ class SubListener : public eprosima::fastdds::dds::DataReaderListener DataReader* reader) override { SampleInfo info; - if (reader->take_next_sample(&m_sample, &info) == ReturnCode_t::RETCODE_OK) + if (reader->take_next_sample(&m_sample, &info) == RETCODE_OK) { if (info.valid_data) { @@ -365,7 +365,7 @@ void keys() //Read the contents of both histories: std::vector< std::pair> sampleList; std::cout << "The Subscriber holds: " << std::endl; - while (myReader->read_next_sample(&my_sample, &sample_info) == ReturnCode_t::RETCODE_OK) + while (myReader->read_next_sample(&my_sample, &sample_info) == RETCODE_OK) { sampleList.push_back(std::pair(my_sample.index(), my_sample.key_value())); } diff --git a/examples/cpp/dds/Keys/sample.cxx b/examples/cpp/dds/Keys/sample.cxx deleted file mode 100644 index 360d4a1b2b2..00000000000 --- a/examples/cpp/dds/Keys/sample.cxx +++ /dev/null @@ -1,158 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file sample.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "sample.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - - - - -sample::sample() -{ -} - -sample::~sample() -{ -} - -sample::sample( - const sample& x) -{ - m_index = x.m_index; - m_key_value = x.m_key_value; -} - -sample::sample( - sample&& x) noexcept -{ - m_index = x.m_index; - m_key_value = x.m_key_value; -} - -sample& sample::operator =( - const sample& x) -{ - - m_index = x.m_index; - m_key_value = x.m_key_value; - return *this; -} - -sample& sample::operator =( - sample&& x) noexcept -{ - - m_index = x.m_index; - m_key_value = x.m_key_value; - return *this; -} - -bool sample::operator ==( - const sample& x) const -{ - return (m_index == x.m_index && - m_key_value == x.m_key_value); -} - -bool sample::operator !=( - const sample& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void sample::index( - uint8_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint8_t sample::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint8_t& sample::index() -{ - return m_index; -} - - -/*! - * @brief This function sets a value in member key_value - * @param _key_value New value for member key_value - */ -void sample::key_value( - uint8_t _key_value) -{ - m_key_value = _key_value; -} - -/*! - * @brief This function returns the value of member key_value - * @return Value of member key_value - */ -uint8_t sample::key_value() const -{ - return m_key_value; -} - -/*! - * @brief This function returns a reference to member key_value - * @return Reference to member key_value - */ -uint8_t& sample::key_value() -{ - return m_key_value; -} - - -// Include auxiliary functions like for serializing/deserializing. -#include "sampleCdrAux.ipp" - -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/LateJoiners/sample.h b/examples/cpp/dds/Keys/sample.hpp similarity index 69% rename from examples/cpp/dds/LateJoiners/sample.h rename to examples/cpp/dds/Keys/sample.hpp index c050c8527cc..3023a792269 100644 --- a/examples/cpp/dds/LateJoiners/sample.h +++ b/examples/cpp/dds/Keys/sample.hpp @@ -13,32 +13,17 @@ // limitations under the License. /*! - * @file sample.h + * @file sample.hpp * This header file contains the declaration of the described types in the IDL file. * * This file was generated by the tool fastddsgen. */ -#include -#include "samplev1.h" +#ifndef _FAST_DDS_GENERATED_SAMPLE_HPP_ +#define _FAST_DDS_GENERATED_SAMPLE_HPP_ -#if FASTCDR_VERSION_MAJOR > 1 - -#ifndef _FAST_DDS_GENERATED_SAMPLE_H_ -#define _FAST_DDS_GENERATED_SAMPLE_H_ - -#include -#include #include -#include -#include -#include - -#include -#include -#include - - +#include #if defined(_WIN32) #if defined(EPROSIMA_USER_DLL_EXPORT) @@ -64,17 +49,6 @@ #define SAMPLE_DllAPI #endif // _WIN32 -namespace eprosima { -namespace fastcdr { -class Cdr; -class CdrSizeCalculator; -} // namespace fastcdr -} // namespace eprosima - - - - - /*! * @brief This class represents the structure sample defined by the user in the IDL file. * @ingroup sample @@ -86,73 +60,117 @@ class sample /*! * @brief Default constructor. */ - eProsima_user_DllExport sample(); + eProsima_user_DllExport sample() + { + } /*! * @brief Default destructor. */ - eProsima_user_DllExport ~sample(); + eProsima_user_DllExport ~sample() + { + } /*! * @brief Copy constructor. * @param x Reference to the object sample that will be copied. */ eProsima_user_DllExport sample( - const sample& x); + const sample& x) + { + m_index = x.m_index; + + m_key_value = x.m_key_value; + + } /*! * @brief Move constructor. * @param x Reference to the object sample that will be copied. */ eProsima_user_DllExport sample( - sample&& x) noexcept; + sample&& x) noexcept + { + m_index = x.m_index; + m_key_value = x.m_key_value; + } /*! * @brief Copy assignment. * @param x Reference to the object sample that will be copied. */ eProsima_user_DllExport sample& operator =( - const sample& x); + const sample& x) + { + + m_index = x.m_index; + + m_key_value = x.m_key_value; + + return *this; + } /*! * @brief Move assignment. * @param x Reference to the object sample that will be copied. */ eProsima_user_DllExport sample& operator =( - sample&& x) noexcept; + sample&& x) noexcept + { + + m_index = x.m_index; + m_key_value = x.m_key_value; + return *this; + } /*! * @brief Comparison operator. * @param x sample object to compare. */ eProsima_user_DllExport bool operator ==( - const sample& x) const; + const sample& x) const + { + return (m_index == x.m_index && + m_key_value == x.m_key_value); + } /*! * @brief Comparison operator. * @param x sample object to compare. */ eProsima_user_DllExport bool operator !=( - const sample& x) const; + const sample& x) const + { + return !(*this == x); + } /*! * @brief This function sets a value in member index * @param _index New value for member index */ eProsima_user_DllExport void index( - uint8_t _index); + uint8_t _index) + { + m_index = _index; + } /*! * @brief This function returns the value of member index * @return Value of member index */ - eProsima_user_DllExport uint8_t index() const; + eProsima_user_DllExport uint8_t index() const + { + return m_index; + } /*! * @brief This function returns a reference to member index * @return Reference to member index */ - eProsima_user_DllExport uint8_t& index(); + eProsima_user_DllExport uint8_t& index() + { + return m_index; + } /*! @@ -160,19 +178,30 @@ class sample * @param _key_value New value for member key_value */ eProsima_user_DllExport void key_value( - uint8_t _key_value); + uint8_t _key_value) + { + m_key_value = _key_value; + } /*! * @brief This function returns the value of member key_value * @return Value of member key_value */ - eProsima_user_DllExport uint8_t key_value() const; + eProsima_user_DllExport uint8_t key_value() const + { + return m_key_value; + } /*! * @brief This function returns a reference to member key_value * @return Reference to member key_value */ - eProsima_user_DllExport uint8_t& key_value(); + eProsima_user_DllExport uint8_t& key_value() + { + return m_key_value; + } + + private: @@ -181,8 +210,6 @@ class sample }; -#endif // _FAST_DDS_GENERATED_SAMPLE_H_ - +#endif // _FAST_DDS_GENERATED_SAMPLE_HPP_ -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/Keys/sampleCdrAux.hpp b/examples/cpp/dds/Keys/sampleCdrAux.hpp index 18ed5857add..b80dff31248 100644 --- a/examples/cpp/dds/Keys/sampleCdrAux.hpp +++ b/examples/cpp/dds/Keys/sampleCdrAux.hpp @@ -22,7 +22,7 @@ #ifndef _FAST_DDS_GENERATED_SAMPLECDRAUX_HPP_ #define _FAST_DDS_GENERATED_SAMPLECDRAUX_HPP_ -#include "sample.h" +#include "sample.hpp" constexpr uint32_t sample_max_cdr_typesize {6UL}; constexpr uint32_t sample_max_key_cdr_typesize {1UL}; @@ -34,8 +34,6 @@ namespace fastcdr { class Cdr; class CdrSizeCalculator; - - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const sample& data); diff --git a/examples/cpp/dds/Keys/sampleCdrAux.ipp b/examples/cpp/dds/Keys/sampleCdrAux.ipp index 11bc4709a6e..17a3d1025fc 100644 --- a/examples/cpp/dds/Keys/sampleCdrAux.ipp +++ b/examples/cpp/dds/Keys/sampleCdrAux.ipp @@ -34,8 +34,6 @@ using namespace eprosima::fastcdr::exception; namespace eprosima { namespace fastcdr { - - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, diff --git a/examples/cpp/dds/Keys/samplePubSubTypes.cxx b/examples/cpp/dds/Keys/samplePubSubTypes.cxx index 9095d77083a..cae143a08ca 100644 --- a/examples/cpp/dds/Keys/samplePubSubTypes.cxx +++ b/examples/cpp/dds/Keys/samplePubSubTypes.cxx @@ -19,18 +19,18 @@ * This file was generated by the tool fastddsgen. */ +#include "samplePubSubTypes.h" +#include #include -#include "samplePubSubTypes.h" #include "sampleCdrAux.hpp" +#include "sampleTypeObjectSupport.hpp" using SerializedPayload_t = eprosima::fastrtps::rtps::SerializedPayload_t; using InstanceHandle_t = eprosima::fastrtps::rtps::InstanceHandle_t; using DataRepresentationId_t = eprosima::fastdds::dds::DataRepresentationId_t; - - samplePubSubType::samplePubSubType() { setName("sample"); @@ -219,3 +219,11 @@ bool samplePubSubType::getKey( return true; } +void samplePubSubType::register_type_object_representation() const +{ + register_sample_type_objects(); +} + + +// Include auxiliary functions like for serializing/deserializing. +#include "sampleCdrAux.ipp" diff --git a/examples/cpp/dds/Keys/samplePubSubTypes.h b/examples/cpp/dds/Keys/samplePubSubTypes.h index ec881115211..9e59aa58042 100644 --- a/examples/cpp/dds/Keys/samplePubSubTypes.h +++ b/examples/cpp/dds/Keys/samplePubSubTypes.h @@ -27,9 +27,9 @@ #include #include #include -#include +#include -#include "sample.h" +#include "sample.hpp" #if !defined(GEN_API_VER) || (GEN_API_VER != 2) @@ -38,8 +38,6 @@ #endif // GEN_API_VER - - /*! * @brief This class represents the TopicDataType of the type sample defined by the user in the IDL file. * @ingroup sample @@ -90,6 +88,9 @@ class samplePubSubType : public eprosima::fastdds::dds::TopicDataType eProsima_user_DllExport void deleteData( void* data) override; + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + #ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED eProsima_user_DllExport inline bool is_bounded() const override { diff --git a/examples/cpp/dds/Keys/sampleTypeObjectSupport.cxx b/examples/cpp/dds/Keys/sampleTypeObjectSupport.cxx new file mode 100644 index 00000000000..3719bbf77e6 --- /dev/null +++ b/examples/cpp/dds/Keys/sampleTypeObjectSupport.cxx @@ -0,0 +1,224 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file sampleTypeObjectSupport.cxx + * Source file containing the implementation to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#include "sampleTypeObjectSupport.hpp" + +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include + +#include "sample.hpp" + + +using namespace eprosima::fastdds::dds::xtypes; + +void register_sample_type_objects() +{ + static std::once_flag once_flag; + std::call_once(once_flag, []() + { + register_sample_type_identifier(); + + }); +} + +void register_sample_type_identifier() +{ + { + StructTypeFlag struct_flags_sample = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::NOT_APPLIED, + false, false); + ReturnCode_t return_code_sample; + TypeIdentifierPair type_ids_sample; + QualifiedTypeName type_name_sample = "sample"; + eprosima::fastcdr::optional type_ann_builtin_sample; + eprosima::fastcdr::optional ann_custom_sample; + CompleteTypeDetail detail_sample = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_sample, ann_custom_sample, type_name_sample.to_string()); + CompleteStructHeader header_sample; + header_sample = TypeObjectUtils::build_complete_struct_header(TypeIdentifier(), detail_sample); + CompleteStructMemberSeq member_seq_sample; + { + return_code_sample = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_byte", type_ids_sample); + + if (return_code_sample != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "index Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_index = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_index; + MemberId member_id_index = 0x00000000; + if (EK_COMPLETE == type_ids_sample.type_identifier1()._d() || TK_NONE == type_ids_sample.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_sample.type_identifier1()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_sample.type_identifier1()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_sample.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_sample.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_sample.type_identifier2()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_sample.type_identifier2()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_sample.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure index member TypeIdentifier inconsistent."); + return; + } + MemberName name_index = "index"; + eprosima::fastcdr::optional member_ann_builtin_index; + ann_custom_sample.reset(); + CompleteMemberDetail detail_index = TypeObjectUtils::build_complete_member_detail(name_index, member_ann_builtin_index, ann_custom_sample); + CompleteStructMember member_index = TypeObjectUtils::build_complete_struct_member(common_index, detail_index); + TypeObjectUtils::add_complete_struct_member(member_seq_sample, member_index); + } + { + return_code_sample = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_byte", type_ids_sample); + + if (return_code_sample != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "key_value Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_key_value = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, true, false); + CommonStructMember common_key_value; + MemberId member_id_key_value = 0x00000001; + if (EK_COMPLETE == type_ids_sample.type_identifier1()._d() || TK_NONE == type_ids_sample.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_sample.type_identifier1()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_sample.type_identifier1()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_key_value = TypeObjectUtils::build_common_struct_member(member_id_key_value, member_flags_key_value, type_ids_sample.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_sample.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_sample.type_identifier2()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_sample.type_identifier2()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_key_value = TypeObjectUtils::build_common_struct_member(member_id_key_value, member_flags_key_value, type_ids_sample.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure key_value member TypeIdentifier inconsistent."); + return; + } + MemberName name_key_value = "key_value"; + eprosima::fastcdr::optional member_ann_builtin_key_value; + ann_custom_sample.reset(); + AppliedAnnotationSeq tmp_ann_custom_key_value; + eprosima::fastcdr::optional unit_key_value; + eprosima::fastcdr::optional min_key_value; + eprosima::fastcdr::optional max_key_value; + eprosima::fastcdr::optional hash_id_key_value; + if (unit_key_value.has_value() || min_key_value.has_value() || max_key_value.has_value() || hash_id_key_value.has_value()) + { + member_ann_builtin_key_value = TypeObjectUtils::build_applied_builtin_member_annotations(unit_key_value, min_key_value, max_key_value, hash_id_key_value); + } + if (!tmp_ann_custom_key_value.empty()) + { + ann_custom_sample = tmp_ann_custom_key_value; + } + CompleteMemberDetail detail_key_value = TypeObjectUtils::build_complete_member_detail(name_key_value, member_ann_builtin_key_value, ann_custom_sample); + CompleteStructMember member_key_value = TypeObjectUtils::build_complete_struct_member(common_key_value, detail_key_value); + TypeObjectUtils::add_complete_struct_member(member_seq_sample, member_key_value); + } + CompleteStructType struct_type_sample = TypeObjectUtils::build_complete_struct_type(struct_flags_sample, header_sample, member_seq_sample); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_struct_type_object(struct_type_sample, type_name_sample.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "sample already registered in TypeObjectRegistry for a different type."); + } + return_code_sample = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "sample", type_ids_sample); + if (return_code_sample != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "sample: Given Struct TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } +} + diff --git a/examples/cpp/dds/Keys/sampleTypeObjectSupport.hpp b/examples/cpp/dds/Keys/sampleTypeObjectSupport.hpp new file mode 100644 index 00000000000..5ad7f2e5e07 --- /dev/null +++ b/examples/cpp/dds/Keys/sampleTypeObjectSupport.hpp @@ -0,0 +1,54 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file sampleTypeObjectSupport.hpp + * Header file containing the API required to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#ifndef _FAST_DDS_GENERATED_SAMPLE_TYPE_OBJECT_SUPPORT_HPP_ +#define _FAST_DDS_GENERATED_SAMPLE_TYPE_OBJECT_SUPPORT_HPP_ + + +#if defined(_WIN32) +#if defined(EPROSIMA_USER_DLL_EXPORT) +#define eProsima_user_DllExport __declspec( dllexport ) +#else +#define eProsima_user_DllExport +#endif // EPROSIMA_USER_DLL_EXPORT +#else +#define eProsima_user_DllExport +#endif // _WIN32 + +/** + * @brief Register every TypeObject representation defined in the IDL file in Fast DDS TypeObjectRegistry. + */ +eProsima_user_DllExport void register_sample_type_objects(); + +#ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +/** + * @brief Register sample related TypeIdentifier. + * Fully-descriptive TypeIdentifiers are directly registered. + * Hash TypeIdentifiers require to fill the TypeObject information and hash it, consequently, the TypeObject is + * indirectly registered as well. + */ +void register_sample_type_identifier(); + + +#endif // DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +#endif // _FAST_DDS_GENERATED_SAMPLE_TYPE_OBJECT_SUPPORT_HPP_ diff --git a/examples/cpp/dds/Keys/samplev1.cxx b/examples/cpp/dds/Keys/samplev1.cxx deleted file mode 100644 index 3b735befaf8..00000000000 --- a/examples/cpp/dds/Keys/samplev1.cxx +++ /dev/null @@ -1,280 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file sample.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "sample.h" - -#if FASTCDR_VERSION_MAJOR == 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - -namespace helper { namespace internal { - -enum class Size { - UInt8, - UInt16, - UInt32, - UInt64, -}; - -constexpr Size get_size(int s) { - return (s <= 8 ) ? Size::UInt8: - (s <= 16) ? Size::UInt16: - (s <= 32) ? Size::UInt32: Size::UInt64; -} - -template -struct FindTypeH; - -template<> -struct FindTypeH { - using type = std::uint8_t; -}; - -template<> -struct FindTypeH { - using type = std::uint16_t; -}; - -template<> -struct FindTypeH { - using type = std::uint32_t; -}; - -template<> -struct FindTypeH { - using type = std::uint64_t; -}; -} - -template -struct FindType { - using type = typename internal::FindTypeH::type; -}; -} - -#define sample_max_cdr_typesize 6ULL; - - - - -sample::sample() -{ - // octet m_index - m_index = 0; - // octet m_key_value - m_key_value = 0; - -} - -sample::~sample() -{ -} - -sample::sample( - const sample& x) -{ - m_index = x.m_index; - - - m_key_value = x.m_key_value; - -} - -sample::sample( - sample&& x) noexcept -{ - m_index = x.m_index; - - - m_key_value = x.m_key_value; - -} - -sample& sample::operator =( - const sample& x) -{ - m_index = x.m_index; - - - m_key_value = x.m_key_value; - - return *this; -} - -sample& sample::operator =( - sample&& x) noexcept -{ - m_index = x.m_index; - - - m_key_value = x.m_key_value; - - return *this; -} - -bool sample::operator ==( - const sample& x) const -{ - return (m_index == x.m_index && - m_key_value == x.m_key_value); -} - -bool sample::operator !=( - const sample& x) const -{ - return !(*this == x); -} - -size_t sample::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return sample_max_cdr_typesize; -} - -size_t sample::getCdrSerializedSize( - const sample& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - return current_alignment - initial_alignment; -} - - -void sample::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_index; - - scdr << m_key_value; - -} - -void sample::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_index; - - - - dcdr >> m_key_value; - - -} - - -bool sample::isKeyDefined() -{ - return true; -} - -void sample::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; - - - scdr << m_key_value; - -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void sample::index( - uint8_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint8_t sample::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint8_t& sample::index() -{ - return m_index; -} - - -/*! - * @brief This function sets a value in member key_value - * @param _key_value New value for member key_value - */ -void sample::key_value( - uint8_t _key_value) -{ - m_key_value = _key_value; -} - -/*! - * @brief This function returns the value of member key_value - * @return Value of member key_value - */ -uint8_t sample::key_value() const -{ - return m_key_value; -} - -/*! - * @brief This function returns a reference to member key_value - * @return Reference to member key_value - */ -uint8_t& sample::key_value() -{ - return m_key_value; -} - - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/Keys/samplev1.h b/examples/cpp/dds/Keys/samplev1.h deleted file mode 100644 index 4fa288d1bc9..00000000000 --- a/examples/cpp/dds/Keys/samplev1.h +++ /dev/null @@ -1,237 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file sample.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#include - -#if FASTCDR_VERSION_MAJOR == 1 - -#ifndef _FAST_DDS_GENERATED_SAMPLE_H_ -#define _FAST_DDS_GENERATED_SAMPLE_H_ - - -#include - -#include -#include -#include -#include -#include -#include -#include - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define eProsima_user_DllExport -#endif // _WIN32 - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(SAMPLE_SOURCE) -#define SAMPLE_DllAPI __declspec( dllexport ) -#else -#define SAMPLE_DllAPI __declspec( dllimport ) -#endif // SAMPLE_SOURCE -#else -#define SAMPLE_DllAPI -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define SAMPLE_DllAPI -#endif // _WIN32 - -namespace eprosima { -namespace fastcdr { -class Cdr; -} // namespace fastcdr -} // namespace eprosima - - - - - -/*! - * @brief This class represents the structure sample defined by the user in the IDL file. - * @ingroup sample - */ -class sample -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport sample(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~sample(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object sample that will be copied. - */ - eProsima_user_DllExport sample( - const sample& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object sample that will be copied. - */ - eProsima_user_DllExport sample( - sample&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object sample that will be copied. - */ - eProsima_user_DllExport sample& operator =( - const sample& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object sample that will be copied. - */ - eProsima_user_DllExport sample& operator =( - sample&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x sample object to compare. - */ - eProsima_user_DllExport bool operator ==( - const sample& x) const; - - /*! - * @brief Comparison operator. - * @param x sample object to compare. - */ - eProsima_user_DllExport bool operator !=( - const sample& x) const; - - /*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ - eProsima_user_DllExport void index( - uint8_t _index); - - /*! - * @brief This function returns the value of member index - * @return Value of member index - */ - eProsima_user_DllExport uint8_t index() const; - - /*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ - eProsima_user_DllExport uint8_t& index(); - - - /*! - * @brief This function sets a value in member key_value - * @param _key_value New value for member key_value - */ - eProsima_user_DllExport void key_value( - uint8_t _key_value); - - /*! - * @brief This function returns the value of member key_value - * @return Value of member key_value - */ - eProsima_user_DllExport uint8_t key_value() const; - - /*! - * @brief This function returns a reference to member key_value - * @return Reference to member key_value - */ - eProsima_user_DllExport uint8_t& key_value(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const sample& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - uint8_t m_index; - uint8_t m_key_value; - -}; - - -#endif // _FAST_DDS_GENERATED_SAMPLE_H_ - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/LateJoiners/CMakeLists.txt b/examples/cpp/dds/LateJoiners/CMakeLists.txt index fd683dc6d23..f289f626014 100644 --- a/examples/cpp/dds/LateJoiners/CMakeLists.txt +++ b/examples/cpp/dds/LateJoiners/CMakeLists.txt @@ -25,8 +25,8 @@ if(NOT foonathan_memory_FOUND) find_package(foonathan_memory REQUIRED) endif() -if(NOT fastrtps_FOUND) - find_package(fastrtps 2.12 REQUIRED) +if(NOT fastdds_FOUND) + find_package(fastdds 2.12 REQUIRED) endif() #Check C++11 @@ -46,7 +46,7 @@ target_compile_definitions(DDSLateJoiners PRIVATE $<$>,$>:__DEBUG> $<$:__INTERNALDEBUG> # Internal debug activated. ) -target_link_libraries(DDSLateJoiners fastrtps fastcdr foonathan_memory) +target_link_libraries(DDSLateJoiners fastdds fastcdr foonathan_memory) install(TARGETS DDSLateJoiners RUNTIME DESTINATION examples/cpp/dds/LateJoiners/${BIN_INSTALL_DIR} ) diff --git a/examples/cpp/dds/LateJoiners/latejoiners.cpp b/examples/cpp/dds/LateJoiners/latejoiners.cpp index 4566c146b45..4209ea5e835 100644 --- a/examples/cpp/dds/LateJoiners/latejoiners.cpp +++ b/examples/cpp/dds/LateJoiners/latejoiners.cpp @@ -177,13 +177,13 @@ void latejoiners() //Read the contents of both histories: std::cout << "The Transient Local Subscriber holds: " << std::endl; - while (myReader1->read_next_sample(&my_sample, &sample_info) == ReturnCode_t::RETCODE_OK) + while (myReader1->read_next_sample(&my_sample, &sample_info) == RETCODE_OK) { std::cout << std::to_string(my_sample.index()) << " "; } std::cout << std::endl; std::cout << "The Volatile Subscriber holds: " << std::endl; - while (myReader2->read_next_sample(&my_sample, &sample_info) == ReturnCode_t::RETCODE_OK) + while (myReader2->read_next_sample(&my_sample, &sample_info) == RETCODE_OK) { std::cout << std::to_string(my_sample.index()) << " "; } diff --git a/examples/cpp/dds/LateJoiners/sample.cxx b/examples/cpp/dds/LateJoiners/sample.cxx deleted file mode 100644 index 360d4a1b2b2..00000000000 --- a/examples/cpp/dds/LateJoiners/sample.cxx +++ /dev/null @@ -1,158 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file sample.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "sample.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - - - - -sample::sample() -{ -} - -sample::~sample() -{ -} - -sample::sample( - const sample& x) -{ - m_index = x.m_index; - m_key_value = x.m_key_value; -} - -sample::sample( - sample&& x) noexcept -{ - m_index = x.m_index; - m_key_value = x.m_key_value; -} - -sample& sample::operator =( - const sample& x) -{ - - m_index = x.m_index; - m_key_value = x.m_key_value; - return *this; -} - -sample& sample::operator =( - sample&& x) noexcept -{ - - m_index = x.m_index; - m_key_value = x.m_key_value; - return *this; -} - -bool sample::operator ==( - const sample& x) const -{ - return (m_index == x.m_index && - m_key_value == x.m_key_value); -} - -bool sample::operator !=( - const sample& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void sample::index( - uint8_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint8_t sample::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint8_t& sample::index() -{ - return m_index; -} - - -/*! - * @brief This function sets a value in member key_value - * @param _key_value New value for member key_value - */ -void sample::key_value( - uint8_t _key_value) -{ - m_key_value = _key_value; -} - -/*! - * @brief This function returns the value of member key_value - * @return Value of member key_value - */ -uint8_t sample::key_value() const -{ - return m_key_value; -} - -/*! - * @brief This function returns a reference to member key_value - * @return Reference to member key_value - */ -uint8_t& sample::key_value() -{ - return m_key_value; -} - - -// Include auxiliary functions like for serializing/deserializing. -#include "sampleCdrAux.ipp" - -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/Configurability/sample.h b/examples/cpp/dds/LateJoiners/sample.hpp similarity index 69% rename from examples/cpp/dds/Configurability/sample.h rename to examples/cpp/dds/LateJoiners/sample.hpp index c050c8527cc..3023a792269 100644 --- a/examples/cpp/dds/Configurability/sample.h +++ b/examples/cpp/dds/LateJoiners/sample.hpp @@ -13,32 +13,17 @@ // limitations under the License. /*! - * @file sample.h + * @file sample.hpp * This header file contains the declaration of the described types in the IDL file. * * This file was generated by the tool fastddsgen. */ -#include -#include "samplev1.h" +#ifndef _FAST_DDS_GENERATED_SAMPLE_HPP_ +#define _FAST_DDS_GENERATED_SAMPLE_HPP_ -#if FASTCDR_VERSION_MAJOR > 1 - -#ifndef _FAST_DDS_GENERATED_SAMPLE_H_ -#define _FAST_DDS_GENERATED_SAMPLE_H_ - -#include -#include #include -#include -#include -#include - -#include -#include -#include - - +#include #if defined(_WIN32) #if defined(EPROSIMA_USER_DLL_EXPORT) @@ -64,17 +49,6 @@ #define SAMPLE_DllAPI #endif // _WIN32 -namespace eprosima { -namespace fastcdr { -class Cdr; -class CdrSizeCalculator; -} // namespace fastcdr -} // namespace eprosima - - - - - /*! * @brief This class represents the structure sample defined by the user in the IDL file. * @ingroup sample @@ -86,73 +60,117 @@ class sample /*! * @brief Default constructor. */ - eProsima_user_DllExport sample(); + eProsima_user_DllExport sample() + { + } /*! * @brief Default destructor. */ - eProsima_user_DllExport ~sample(); + eProsima_user_DllExport ~sample() + { + } /*! * @brief Copy constructor. * @param x Reference to the object sample that will be copied. */ eProsima_user_DllExport sample( - const sample& x); + const sample& x) + { + m_index = x.m_index; + + m_key_value = x.m_key_value; + + } /*! * @brief Move constructor. * @param x Reference to the object sample that will be copied. */ eProsima_user_DllExport sample( - sample&& x) noexcept; + sample&& x) noexcept + { + m_index = x.m_index; + m_key_value = x.m_key_value; + } /*! * @brief Copy assignment. * @param x Reference to the object sample that will be copied. */ eProsima_user_DllExport sample& operator =( - const sample& x); + const sample& x) + { + + m_index = x.m_index; + + m_key_value = x.m_key_value; + + return *this; + } /*! * @brief Move assignment. * @param x Reference to the object sample that will be copied. */ eProsima_user_DllExport sample& operator =( - sample&& x) noexcept; + sample&& x) noexcept + { + + m_index = x.m_index; + m_key_value = x.m_key_value; + return *this; + } /*! * @brief Comparison operator. * @param x sample object to compare. */ eProsima_user_DllExport bool operator ==( - const sample& x) const; + const sample& x) const + { + return (m_index == x.m_index && + m_key_value == x.m_key_value); + } /*! * @brief Comparison operator. * @param x sample object to compare. */ eProsima_user_DllExport bool operator !=( - const sample& x) const; + const sample& x) const + { + return !(*this == x); + } /*! * @brief This function sets a value in member index * @param _index New value for member index */ eProsima_user_DllExport void index( - uint8_t _index); + uint8_t _index) + { + m_index = _index; + } /*! * @brief This function returns the value of member index * @return Value of member index */ - eProsima_user_DllExport uint8_t index() const; + eProsima_user_DllExport uint8_t index() const + { + return m_index; + } /*! * @brief This function returns a reference to member index * @return Reference to member index */ - eProsima_user_DllExport uint8_t& index(); + eProsima_user_DllExport uint8_t& index() + { + return m_index; + } /*! @@ -160,19 +178,30 @@ class sample * @param _key_value New value for member key_value */ eProsima_user_DllExport void key_value( - uint8_t _key_value); + uint8_t _key_value) + { + m_key_value = _key_value; + } /*! * @brief This function returns the value of member key_value * @return Value of member key_value */ - eProsima_user_DllExport uint8_t key_value() const; + eProsima_user_DllExport uint8_t key_value() const + { + return m_key_value; + } /*! * @brief This function returns a reference to member key_value * @return Reference to member key_value */ - eProsima_user_DllExport uint8_t& key_value(); + eProsima_user_DllExport uint8_t& key_value() + { + return m_key_value; + } + + private: @@ -181,8 +210,6 @@ class sample }; -#endif // _FAST_DDS_GENERATED_SAMPLE_H_ - +#endif // _FAST_DDS_GENERATED_SAMPLE_HPP_ -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/LateJoiners/sampleCdrAux.hpp b/examples/cpp/dds/LateJoiners/sampleCdrAux.hpp index 18ed5857add..b80dff31248 100644 --- a/examples/cpp/dds/LateJoiners/sampleCdrAux.hpp +++ b/examples/cpp/dds/LateJoiners/sampleCdrAux.hpp @@ -22,7 +22,7 @@ #ifndef _FAST_DDS_GENERATED_SAMPLECDRAUX_HPP_ #define _FAST_DDS_GENERATED_SAMPLECDRAUX_HPP_ -#include "sample.h" +#include "sample.hpp" constexpr uint32_t sample_max_cdr_typesize {6UL}; constexpr uint32_t sample_max_key_cdr_typesize {1UL}; @@ -34,8 +34,6 @@ namespace fastcdr { class Cdr; class CdrSizeCalculator; - - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const sample& data); diff --git a/examples/cpp/dds/LateJoiners/sampleCdrAux.ipp b/examples/cpp/dds/LateJoiners/sampleCdrAux.ipp index 11bc4709a6e..17a3d1025fc 100644 --- a/examples/cpp/dds/LateJoiners/sampleCdrAux.ipp +++ b/examples/cpp/dds/LateJoiners/sampleCdrAux.ipp @@ -34,8 +34,6 @@ using namespace eprosima::fastcdr::exception; namespace eprosima { namespace fastcdr { - - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, diff --git a/examples/cpp/dds/LateJoiners/samplePubSubTypes.cxx b/examples/cpp/dds/LateJoiners/samplePubSubTypes.cxx index 9095d77083a..cae143a08ca 100644 --- a/examples/cpp/dds/LateJoiners/samplePubSubTypes.cxx +++ b/examples/cpp/dds/LateJoiners/samplePubSubTypes.cxx @@ -19,18 +19,18 @@ * This file was generated by the tool fastddsgen. */ +#include "samplePubSubTypes.h" +#include #include -#include "samplePubSubTypes.h" #include "sampleCdrAux.hpp" +#include "sampleTypeObjectSupport.hpp" using SerializedPayload_t = eprosima::fastrtps::rtps::SerializedPayload_t; using InstanceHandle_t = eprosima::fastrtps::rtps::InstanceHandle_t; using DataRepresentationId_t = eprosima::fastdds::dds::DataRepresentationId_t; - - samplePubSubType::samplePubSubType() { setName("sample"); @@ -219,3 +219,11 @@ bool samplePubSubType::getKey( return true; } +void samplePubSubType::register_type_object_representation() const +{ + register_sample_type_objects(); +} + + +// Include auxiliary functions like for serializing/deserializing. +#include "sampleCdrAux.ipp" diff --git a/examples/cpp/dds/LateJoiners/samplePubSubTypes.h b/examples/cpp/dds/LateJoiners/samplePubSubTypes.h index ec881115211..9e59aa58042 100644 --- a/examples/cpp/dds/LateJoiners/samplePubSubTypes.h +++ b/examples/cpp/dds/LateJoiners/samplePubSubTypes.h @@ -27,9 +27,9 @@ #include #include #include -#include +#include -#include "sample.h" +#include "sample.hpp" #if !defined(GEN_API_VER) || (GEN_API_VER != 2) @@ -38,8 +38,6 @@ #endif // GEN_API_VER - - /*! * @brief This class represents the TopicDataType of the type sample defined by the user in the IDL file. * @ingroup sample @@ -90,6 +88,9 @@ class samplePubSubType : public eprosima::fastdds::dds::TopicDataType eProsima_user_DllExport void deleteData( void* data) override; + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + #ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED eProsima_user_DllExport inline bool is_bounded() const override { diff --git a/examples/cpp/dds/LateJoiners/sampleTypeObjectSupport.cxx b/examples/cpp/dds/LateJoiners/sampleTypeObjectSupport.cxx new file mode 100644 index 00000000000..3719bbf77e6 --- /dev/null +++ b/examples/cpp/dds/LateJoiners/sampleTypeObjectSupport.cxx @@ -0,0 +1,224 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file sampleTypeObjectSupport.cxx + * Source file containing the implementation to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#include "sampleTypeObjectSupport.hpp" + +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include + +#include "sample.hpp" + + +using namespace eprosima::fastdds::dds::xtypes; + +void register_sample_type_objects() +{ + static std::once_flag once_flag; + std::call_once(once_flag, []() + { + register_sample_type_identifier(); + + }); +} + +void register_sample_type_identifier() +{ + { + StructTypeFlag struct_flags_sample = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::NOT_APPLIED, + false, false); + ReturnCode_t return_code_sample; + TypeIdentifierPair type_ids_sample; + QualifiedTypeName type_name_sample = "sample"; + eprosima::fastcdr::optional type_ann_builtin_sample; + eprosima::fastcdr::optional ann_custom_sample; + CompleteTypeDetail detail_sample = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_sample, ann_custom_sample, type_name_sample.to_string()); + CompleteStructHeader header_sample; + header_sample = TypeObjectUtils::build_complete_struct_header(TypeIdentifier(), detail_sample); + CompleteStructMemberSeq member_seq_sample; + { + return_code_sample = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_byte", type_ids_sample); + + if (return_code_sample != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "index Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_index = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_index; + MemberId member_id_index = 0x00000000; + if (EK_COMPLETE == type_ids_sample.type_identifier1()._d() || TK_NONE == type_ids_sample.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_sample.type_identifier1()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_sample.type_identifier1()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_sample.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_sample.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_sample.type_identifier2()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_sample.type_identifier2()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_sample.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure index member TypeIdentifier inconsistent."); + return; + } + MemberName name_index = "index"; + eprosima::fastcdr::optional member_ann_builtin_index; + ann_custom_sample.reset(); + CompleteMemberDetail detail_index = TypeObjectUtils::build_complete_member_detail(name_index, member_ann_builtin_index, ann_custom_sample); + CompleteStructMember member_index = TypeObjectUtils::build_complete_struct_member(common_index, detail_index); + TypeObjectUtils::add_complete_struct_member(member_seq_sample, member_index); + } + { + return_code_sample = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_byte", type_ids_sample); + + if (return_code_sample != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "key_value Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_key_value = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, true, false); + CommonStructMember common_key_value; + MemberId member_id_key_value = 0x00000001; + if (EK_COMPLETE == type_ids_sample.type_identifier1()._d() || TK_NONE == type_ids_sample.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_sample.type_identifier1()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_sample.type_identifier1()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_key_value = TypeObjectUtils::build_common_struct_member(member_id_key_value, member_flags_key_value, type_ids_sample.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_sample.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_sample.type_identifier2()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_sample.type_identifier2()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_key_value = TypeObjectUtils::build_common_struct_member(member_id_key_value, member_flags_key_value, type_ids_sample.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure key_value member TypeIdentifier inconsistent."); + return; + } + MemberName name_key_value = "key_value"; + eprosima::fastcdr::optional member_ann_builtin_key_value; + ann_custom_sample.reset(); + AppliedAnnotationSeq tmp_ann_custom_key_value; + eprosima::fastcdr::optional unit_key_value; + eprosima::fastcdr::optional min_key_value; + eprosima::fastcdr::optional max_key_value; + eprosima::fastcdr::optional hash_id_key_value; + if (unit_key_value.has_value() || min_key_value.has_value() || max_key_value.has_value() || hash_id_key_value.has_value()) + { + member_ann_builtin_key_value = TypeObjectUtils::build_applied_builtin_member_annotations(unit_key_value, min_key_value, max_key_value, hash_id_key_value); + } + if (!tmp_ann_custom_key_value.empty()) + { + ann_custom_sample = tmp_ann_custom_key_value; + } + CompleteMemberDetail detail_key_value = TypeObjectUtils::build_complete_member_detail(name_key_value, member_ann_builtin_key_value, ann_custom_sample); + CompleteStructMember member_key_value = TypeObjectUtils::build_complete_struct_member(common_key_value, detail_key_value); + TypeObjectUtils::add_complete_struct_member(member_seq_sample, member_key_value); + } + CompleteStructType struct_type_sample = TypeObjectUtils::build_complete_struct_type(struct_flags_sample, header_sample, member_seq_sample); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_struct_type_object(struct_type_sample, type_name_sample.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "sample already registered in TypeObjectRegistry for a different type."); + } + return_code_sample = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "sample", type_ids_sample); + if (return_code_sample != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "sample: Given Struct TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } +} + diff --git a/examples/cpp/dds/LateJoiners/sampleTypeObjectSupport.hpp b/examples/cpp/dds/LateJoiners/sampleTypeObjectSupport.hpp new file mode 100644 index 00000000000..5ad7f2e5e07 --- /dev/null +++ b/examples/cpp/dds/LateJoiners/sampleTypeObjectSupport.hpp @@ -0,0 +1,54 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file sampleTypeObjectSupport.hpp + * Header file containing the API required to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#ifndef _FAST_DDS_GENERATED_SAMPLE_TYPE_OBJECT_SUPPORT_HPP_ +#define _FAST_DDS_GENERATED_SAMPLE_TYPE_OBJECT_SUPPORT_HPP_ + + +#if defined(_WIN32) +#if defined(EPROSIMA_USER_DLL_EXPORT) +#define eProsima_user_DllExport __declspec( dllexport ) +#else +#define eProsima_user_DllExport +#endif // EPROSIMA_USER_DLL_EXPORT +#else +#define eProsima_user_DllExport +#endif // _WIN32 + +/** + * @brief Register every TypeObject representation defined in the IDL file in Fast DDS TypeObjectRegistry. + */ +eProsima_user_DllExport void register_sample_type_objects(); + +#ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +/** + * @brief Register sample related TypeIdentifier. + * Fully-descriptive TypeIdentifiers are directly registered. + * Hash TypeIdentifiers require to fill the TypeObject information and hash it, consequently, the TypeObject is + * indirectly registered as well. + */ +void register_sample_type_identifier(); + + +#endif // DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +#endif // _FAST_DDS_GENERATED_SAMPLE_TYPE_OBJECT_SUPPORT_HPP_ diff --git a/examples/cpp/dds/LateJoiners/samplev1.cxx b/examples/cpp/dds/LateJoiners/samplev1.cxx deleted file mode 100644 index 3b735befaf8..00000000000 --- a/examples/cpp/dds/LateJoiners/samplev1.cxx +++ /dev/null @@ -1,280 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file sample.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "sample.h" - -#if FASTCDR_VERSION_MAJOR == 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - -namespace helper { namespace internal { - -enum class Size { - UInt8, - UInt16, - UInt32, - UInt64, -}; - -constexpr Size get_size(int s) { - return (s <= 8 ) ? Size::UInt8: - (s <= 16) ? Size::UInt16: - (s <= 32) ? Size::UInt32: Size::UInt64; -} - -template -struct FindTypeH; - -template<> -struct FindTypeH { - using type = std::uint8_t; -}; - -template<> -struct FindTypeH { - using type = std::uint16_t; -}; - -template<> -struct FindTypeH { - using type = std::uint32_t; -}; - -template<> -struct FindTypeH { - using type = std::uint64_t; -}; -} - -template -struct FindType { - using type = typename internal::FindTypeH::type; -}; -} - -#define sample_max_cdr_typesize 6ULL; - - - - -sample::sample() -{ - // octet m_index - m_index = 0; - // octet m_key_value - m_key_value = 0; - -} - -sample::~sample() -{ -} - -sample::sample( - const sample& x) -{ - m_index = x.m_index; - - - m_key_value = x.m_key_value; - -} - -sample::sample( - sample&& x) noexcept -{ - m_index = x.m_index; - - - m_key_value = x.m_key_value; - -} - -sample& sample::operator =( - const sample& x) -{ - m_index = x.m_index; - - - m_key_value = x.m_key_value; - - return *this; -} - -sample& sample::operator =( - sample&& x) noexcept -{ - m_index = x.m_index; - - - m_key_value = x.m_key_value; - - return *this; -} - -bool sample::operator ==( - const sample& x) const -{ - return (m_index == x.m_index && - m_key_value == x.m_key_value); -} - -bool sample::operator !=( - const sample& x) const -{ - return !(*this == x); -} - -size_t sample::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return sample_max_cdr_typesize; -} - -size_t sample::getCdrSerializedSize( - const sample& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - return current_alignment - initial_alignment; -} - - -void sample::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_index; - - scdr << m_key_value; - -} - -void sample::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_index; - - - - dcdr >> m_key_value; - - -} - - -bool sample::isKeyDefined() -{ - return true; -} - -void sample::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; - - - scdr << m_key_value; - -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void sample::index( - uint8_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint8_t sample::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint8_t& sample::index() -{ - return m_index; -} - - -/*! - * @brief This function sets a value in member key_value - * @param _key_value New value for member key_value - */ -void sample::key_value( - uint8_t _key_value) -{ - m_key_value = _key_value; -} - -/*! - * @brief This function returns the value of member key_value - * @return Value of member key_value - */ -uint8_t sample::key_value() const -{ - return m_key_value; -} - -/*! - * @brief This function returns a reference to member key_value - * @return Reference to member key_value - */ -uint8_t& sample::key_value() -{ - return m_key_value; -} - - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/LateJoiners/samplev1.h b/examples/cpp/dds/LateJoiners/samplev1.h deleted file mode 100644 index 4fa288d1bc9..00000000000 --- a/examples/cpp/dds/LateJoiners/samplev1.h +++ /dev/null @@ -1,237 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file sample.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#include - -#if FASTCDR_VERSION_MAJOR == 1 - -#ifndef _FAST_DDS_GENERATED_SAMPLE_H_ -#define _FAST_DDS_GENERATED_SAMPLE_H_ - - -#include - -#include -#include -#include -#include -#include -#include -#include - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define eProsima_user_DllExport -#endif // _WIN32 - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(SAMPLE_SOURCE) -#define SAMPLE_DllAPI __declspec( dllexport ) -#else -#define SAMPLE_DllAPI __declspec( dllimport ) -#endif // SAMPLE_SOURCE -#else -#define SAMPLE_DllAPI -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define SAMPLE_DllAPI -#endif // _WIN32 - -namespace eprosima { -namespace fastcdr { -class Cdr; -} // namespace fastcdr -} // namespace eprosima - - - - - -/*! - * @brief This class represents the structure sample defined by the user in the IDL file. - * @ingroup sample - */ -class sample -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport sample(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~sample(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object sample that will be copied. - */ - eProsima_user_DllExport sample( - const sample& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object sample that will be copied. - */ - eProsima_user_DllExport sample( - sample&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object sample that will be copied. - */ - eProsima_user_DllExport sample& operator =( - const sample& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object sample that will be copied. - */ - eProsima_user_DllExport sample& operator =( - sample&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x sample object to compare. - */ - eProsima_user_DllExport bool operator ==( - const sample& x) const; - - /*! - * @brief Comparison operator. - * @param x sample object to compare. - */ - eProsima_user_DllExport bool operator !=( - const sample& x) const; - - /*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ - eProsima_user_DllExport void index( - uint8_t _index); - - /*! - * @brief This function returns the value of member index - * @return Value of member index - */ - eProsima_user_DllExport uint8_t index() const; - - /*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ - eProsima_user_DllExport uint8_t& index(); - - - /*! - * @brief This function sets a value in member key_value - * @param _key_value New value for member key_value - */ - eProsima_user_DllExport void key_value( - uint8_t _key_value); - - /*! - * @brief This function returns the value of member key_value - * @return Value of member key_value - */ - eProsima_user_DllExport uint8_t key_value() const; - - /*! - * @brief This function returns a reference to member key_value - * @return Reference to member key_value - */ - eProsima_user_DllExport uint8_t& key_value(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const sample& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - uint8_t m_index; - uint8_t m_key_value; - -}; - - -#endif // _FAST_DDS_GENERATED_SAMPLE_H_ - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/LifespanQoSExample/CMakeLists.txt b/examples/cpp/dds/LifespanQoSExample/CMakeLists.txt index 0e9f9ce97d6..15146b63341 100644 --- a/examples/cpp/dds/LifespanQoSExample/CMakeLists.txt +++ b/examples/cpp/dds/LifespanQoSExample/CMakeLists.txt @@ -21,8 +21,8 @@ if(NOT fastcdr_FOUND) find_package(fastcdr 2 REQUIRED) endif() -if(NOT fastrtps_FOUND) - find_package(fastrtps 2.12 REQUIRED) +if(NOT fastdds_FOUND) + find_package(fastdds 2.12 REQUIRED) endif() #Check C++11 @@ -43,6 +43,6 @@ target_compile_definitions(DDSLifespanQoSExample PRIVATE $<$>,$>:__DEBUG> $<$:__INTERNALDEBUG> # Internal debug activated. ) -target_link_libraries(DDSLifespanQoSExample fastrtps fastcdr) +target_link_libraries(DDSLifespanQoSExample fastdds fastcdr) install(TARGETS DDSLifespanQoSExample RUNTIME DESTINATION examples/cpp/dds/LifespanQoSExample/${BIN_INSTALL_DIR}) diff --git a/examples/cpp/dds/LifespanQoSExample/Lifespan.cxx b/examples/cpp/dds/LifespanQoSExample/Lifespan.cxx deleted file mode 100644 index 66c85b61161..00000000000 --- a/examples/cpp/dds/LifespanQoSExample/Lifespan.cxx +++ /dev/null @@ -1,168 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file Lifespan.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "Lifespan.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - - - - -Lifespan::Lifespan() -{ -} - -Lifespan::~Lifespan() -{ -} - -Lifespan::Lifespan( - const Lifespan& x) -{ - m_index = x.m_index; - m_message = x.m_message; -} - -Lifespan::Lifespan( - Lifespan&& x) noexcept -{ - m_index = x.m_index; - m_message = std::move(x.m_message); -} - -Lifespan& Lifespan::operator =( - const Lifespan& x) -{ - - m_index = x.m_index; - m_message = x.m_message; - return *this; -} - -Lifespan& Lifespan::operator =( - Lifespan&& x) noexcept -{ - - m_index = x.m_index; - m_message = std::move(x.m_message); - return *this; -} - -bool Lifespan::operator ==( - const Lifespan& x) const -{ - return (m_index == x.m_index && - m_message == x.m_message); -} - -bool Lifespan::operator !=( - const Lifespan& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void Lifespan::index( - uint32_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint32_t Lifespan::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint32_t& Lifespan::index() -{ - return m_index; -} - - -/*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ -void Lifespan::message( - const std::string& _message) -{ - m_message = _message; -} - -/*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ -void Lifespan::message( - std::string&& _message) -{ - m_message = std::move(_message); -} - -/*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ -const std::string& Lifespan::message() const -{ - return m_message; -} - -/*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ -std::string& Lifespan::message() -{ - return m_message; -} - - -// Include auxiliary functions like for serializing/deserializing. -#include "LifespanCdrAux.ipp" - -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/LifespanQoSExample/Lifespan.h b/examples/cpp/dds/LifespanQoSExample/Lifespan.hpp similarity index 69% rename from examples/cpp/dds/LifespanQoSExample/Lifespan.h rename to examples/cpp/dds/LifespanQoSExample/Lifespan.hpp index 5d6e5da9c5c..2d2668b9996 100644 --- a/examples/cpp/dds/LifespanQoSExample/Lifespan.h +++ b/examples/cpp/dds/LifespanQoSExample/Lifespan.hpp @@ -13,32 +13,19 @@ // limitations under the License. /*! - * @file Lifespan.h + * @file Lifespan.hpp * This header file contains the declaration of the described types in the IDL file. * * This file was generated by the tool fastddsgen. */ -#include -#include "Lifespanv1.h" +#ifndef _FAST_DDS_GENERATED_LIFESPAN_HPP_ +#define _FAST_DDS_GENERATED_LIFESPAN_HPP_ -#if FASTCDR_VERSION_MAJOR > 1 - -#ifndef _FAST_DDS_GENERATED_LIFESPAN_H_ -#define _FAST_DDS_GENERATED_LIFESPAN_H_ - -#include -#include #include -#include #include -#include - +#include #include -#include -#include - - #if defined(_WIN32) #if defined(EPROSIMA_USER_DLL_EXPORT) @@ -64,17 +51,6 @@ #define LIFESPAN_DllAPI #endif // _WIN32 -namespace eprosima { -namespace fastcdr { -class Cdr; -class CdrSizeCalculator; -} // namespace fastcdr -} // namespace eprosima - - - - - /*! * @brief This class represents the structure Lifespan defined by the user in the IDL file. * @ingroup Lifespan @@ -86,73 +62,117 @@ class Lifespan /*! * @brief Default constructor. */ - eProsima_user_DllExport Lifespan(); + eProsima_user_DllExport Lifespan() + { + } /*! * @brief Default destructor. */ - eProsima_user_DllExport ~Lifespan(); + eProsima_user_DllExport ~Lifespan() + { + } /*! * @brief Copy constructor. * @param x Reference to the object Lifespan that will be copied. */ eProsima_user_DllExport Lifespan( - const Lifespan& x); + const Lifespan& x) + { + m_index = x.m_index; + + m_message = x.m_message; + + } /*! * @brief Move constructor. * @param x Reference to the object Lifespan that will be copied. */ eProsima_user_DllExport Lifespan( - Lifespan&& x) noexcept; + Lifespan&& x) noexcept + { + m_index = x.m_index; + m_message = std::move(x.m_message); + } /*! * @brief Copy assignment. * @param x Reference to the object Lifespan that will be copied. */ eProsima_user_DllExport Lifespan& operator =( - const Lifespan& x); + const Lifespan& x) + { + + m_index = x.m_index; + + m_message = x.m_message; + + return *this; + } /*! * @brief Move assignment. * @param x Reference to the object Lifespan that will be copied. */ eProsima_user_DllExport Lifespan& operator =( - Lifespan&& x) noexcept; + Lifespan&& x) noexcept + { + + m_index = x.m_index; + m_message = std::move(x.m_message); + return *this; + } /*! * @brief Comparison operator. * @param x Lifespan object to compare. */ eProsima_user_DllExport bool operator ==( - const Lifespan& x) const; + const Lifespan& x) const + { + return (m_index == x.m_index && + m_message == x.m_message); + } /*! * @brief Comparison operator. * @param x Lifespan object to compare. */ eProsima_user_DllExport bool operator !=( - const Lifespan& x) const; + const Lifespan& x) const + { + return !(*this == x); + } /*! * @brief This function sets a value in member index * @param _index New value for member index */ eProsima_user_DllExport void index( - uint32_t _index); + uint32_t _index) + { + m_index = _index; + } /*! * @brief This function returns the value of member index * @return Value of member index */ - eProsima_user_DllExport uint32_t index() const; + eProsima_user_DllExport uint32_t index() const + { + return m_index; + } /*! * @brief This function returns a reference to member index * @return Reference to member index */ - eProsima_user_DllExport uint32_t& index(); + eProsima_user_DllExport uint32_t& index() + { + return m_index; + } /*! @@ -160,26 +180,40 @@ class Lifespan * @param _message New value to be copied in member message */ eProsima_user_DllExport void message( - const std::string& _message); + const std::string& _message) + { + m_message = _message; + } /*! * @brief This function moves the value in member message * @param _message New value to be moved in member message */ eProsima_user_DllExport void message( - std::string&& _message); + std::string&& _message) + { + m_message = std::move(_message); + } /*! * @brief This function returns a constant reference to member message * @return Constant reference to member message */ - eProsima_user_DllExport const std::string& message() const; + eProsima_user_DllExport const std::string& message() const + { + return m_message; + } /*! * @brief This function returns a reference to member message * @return Reference to member message */ - eProsima_user_DllExport std::string& message(); + eProsima_user_DllExport std::string& message() + { + return m_message; + } + + private: @@ -188,8 +222,6 @@ class Lifespan }; -#endif // _FAST_DDS_GENERATED_LIFESPAN_H_ - +#endif // _FAST_DDS_GENERATED_LIFESPAN_HPP_ -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/LifespanQoSExample/LifespanCdrAux.hpp b/examples/cpp/dds/LifespanQoSExample/LifespanCdrAux.hpp index 770a53f6a14..590d3f48c33 100644 --- a/examples/cpp/dds/LifespanQoSExample/LifespanCdrAux.hpp +++ b/examples/cpp/dds/LifespanQoSExample/LifespanCdrAux.hpp @@ -22,7 +22,7 @@ #ifndef _FAST_DDS_GENERATED_LIFESPANCDRAUX_HPP_ #define _FAST_DDS_GENERATED_LIFESPANCDRAUX_HPP_ -#include "Lifespan.h" +#include "Lifespan.hpp" constexpr uint32_t Lifespan_max_cdr_typesize {268UL}; constexpr uint32_t Lifespan_max_key_cdr_typesize {0UL}; @@ -34,8 +34,6 @@ namespace fastcdr { class Cdr; class CdrSizeCalculator; - - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const Lifespan& data); diff --git a/examples/cpp/dds/LifespanQoSExample/LifespanCdrAux.ipp b/examples/cpp/dds/LifespanQoSExample/LifespanCdrAux.ipp index 59e8f99cfd7..b890d727220 100644 --- a/examples/cpp/dds/LifespanQoSExample/LifespanCdrAux.ipp +++ b/examples/cpp/dds/LifespanQoSExample/LifespanCdrAux.ipp @@ -34,8 +34,6 @@ using namespace eprosima::fastcdr::exception; namespace eprosima { namespace fastcdr { - - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, diff --git a/examples/cpp/dds/LifespanQoSExample/LifespanPubSubTypes.cxx b/examples/cpp/dds/LifespanQoSExample/LifespanPubSubTypes.cxx index 05b7ea5970c..bddbe31e7d4 100644 --- a/examples/cpp/dds/LifespanQoSExample/LifespanPubSubTypes.cxx +++ b/examples/cpp/dds/LifespanQoSExample/LifespanPubSubTypes.cxx @@ -19,18 +19,18 @@ * This file was generated by the tool fastddsgen. */ +#include "LifespanPubSubTypes.h" +#include #include -#include "LifespanPubSubTypes.h" #include "LifespanCdrAux.hpp" +#include "LifespanTypeObjectSupport.hpp" using SerializedPayload_t = eprosima::fastrtps::rtps::SerializedPayload_t; using InstanceHandle_t = eprosima::fastrtps::rtps::InstanceHandle_t; using DataRepresentationId_t = eprosima::fastdds::dds::DataRepresentationId_t; - - LifespanPubSubType::LifespanPubSubType() { setName("Lifespan"); @@ -219,3 +219,11 @@ bool LifespanPubSubType::getKey( return true; } +void LifespanPubSubType::register_type_object_representation() const +{ + register_Lifespan_type_objects(); +} + + +// Include auxiliary functions like for serializing/deserializing. +#include "LifespanCdrAux.ipp" diff --git a/examples/cpp/dds/LifespanQoSExample/LifespanPubSubTypes.h b/examples/cpp/dds/LifespanQoSExample/LifespanPubSubTypes.h index 01b48528ed9..8c936d6dc6f 100644 --- a/examples/cpp/dds/LifespanQoSExample/LifespanPubSubTypes.h +++ b/examples/cpp/dds/LifespanQoSExample/LifespanPubSubTypes.h @@ -27,9 +27,9 @@ #include #include #include -#include +#include -#include "Lifespan.h" +#include "Lifespan.hpp" #if !defined(GEN_API_VER) || (GEN_API_VER != 2) @@ -38,8 +38,6 @@ #endif // GEN_API_VER - - /*! * @brief This class represents the TopicDataType of the type Lifespan defined by the user in the IDL file. * @ingroup Lifespan @@ -90,6 +88,9 @@ class LifespanPubSubType : public eprosima::fastdds::dds::TopicDataType eProsima_user_DllExport void deleteData( void* data) override; + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + #ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED eProsima_user_DllExport inline bool is_bounded() const override { diff --git a/examples/cpp/dds/LifespanQoSExample/LifespanPublisher.h b/examples/cpp/dds/LifespanQoSExample/LifespanPublisher.h index cb0db6fab53..a737941258e 100644 --- a/examples/cpp/dds/LifespanQoSExample/LifespanPublisher.h +++ b/examples/cpp/dds/LifespanQoSExample/LifespanPublisher.h @@ -20,7 +20,7 @@ #ifndef HELLOWORLDPUBLISHER_H_ #define HELLOWORLDPUBLISHER_H_ -#include "Lifespan.h" +#include "Lifespan.hpp" #include "LifespanPubSubTypes.h" #include diff --git a/examples/cpp/dds/LifespanQoSExample/LifespanSubscriber.cpp b/examples/cpp/dds/LifespanQoSExample/LifespanSubscriber.cpp index 737f92b99f2..e7d9b96571f 100644 --- a/examples/cpp/dds/LifespanQoSExample/LifespanSubscriber.cpp +++ b/examples/cpp/dds/LifespanQoSExample/LifespanSubscriber.cpp @@ -130,7 +130,7 @@ void LifespanSubscriber::SubListener::on_data_available( DataReader* reader) { SampleInfo info; - if (reader->read_next_sample(&hello, &info) == ReturnCode_t::RETCODE_OK) + if (reader->read_next_sample(&hello, &info) == RETCODE_OK) { if (info.valid_data) { @@ -160,7 +160,7 @@ void LifespanSubscriber::run( for ( uint32_t i = 0; i < listener.n_samples; i++ ) { - if (reader_->take_next_sample((void*) &data, &info) == ReturnCode_t::RETCODE_OK) + if (reader_->take_next_sample((void*) &data, &info) == RETCODE_OK) { std::cout << "Message " << data.message() << " " << data.index() << " read from history" << std::endl; } diff --git a/examples/cpp/dds/LifespanQoSExample/LifespanSubscriber.h b/examples/cpp/dds/LifespanQoSExample/LifespanSubscriber.h index 64434c34bc9..2ba5f0392b9 100644 --- a/examples/cpp/dds/LifespanQoSExample/LifespanSubscriber.h +++ b/examples/cpp/dds/LifespanQoSExample/LifespanSubscriber.h @@ -20,8 +20,8 @@ #ifndef HELLOWORLDSUBSCRIBER_H_ #define HELLOWORLDSUBSCRIBER_H_ +#include "Lifespan.hpp" #include "LifespanPubSubTypes.h" -#include "Lifespan.h" #include #include diff --git a/examples/cpp/dds/LifespanQoSExample/LifespanTypeObjectSupport.cxx b/examples/cpp/dds/LifespanQoSExample/LifespanTypeObjectSupport.cxx new file mode 100644 index 00000000000..52d6afa027c --- /dev/null +++ b/examples/cpp/dds/LifespanQoSExample/LifespanTypeObjectSupport.cxx @@ -0,0 +1,248 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file LifespanTypeObjectSupport.cxx + * Source file containing the implementation to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#include "LifespanTypeObjectSupport.hpp" + +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include + +#include "Lifespan.hpp" + + +using namespace eprosima::fastdds::dds::xtypes; + +void register_Lifespan_type_objects() +{ + static std::once_flag once_flag; + std::call_once(once_flag, []() + { + register_Lifespan_type_identifier(); + + }); +} + +void register_Lifespan_type_identifier() +{ + { + StructTypeFlag struct_flags_Lifespan = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::NOT_APPLIED, + false, false); + ReturnCode_t return_code_Lifespan; + TypeIdentifierPair type_ids_Lifespan; + QualifiedTypeName type_name_Lifespan = "Lifespan"; + eprosima::fastcdr::optional type_ann_builtin_Lifespan; + eprosima::fastcdr::optional ann_custom_Lifespan; + CompleteTypeDetail detail_Lifespan = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_Lifespan, ann_custom_Lifespan, type_name_Lifespan.to_string()); + CompleteStructHeader header_Lifespan; + header_Lifespan = TypeObjectUtils::build_complete_struct_header(TypeIdentifier(), detail_Lifespan); + CompleteStructMemberSeq member_seq_Lifespan; + { + return_code_Lifespan = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_uint32_t", type_ids_Lifespan); + + if (return_code_Lifespan != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "index Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_index = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_index; + MemberId member_id_index = 0x00000000; + if (EK_COMPLETE == type_ids_Lifespan.type_identifier1()._d() || TK_NONE == type_ids_Lifespan.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_Lifespan.type_identifier1()._d() && + EK_COMPLETE == type_ids_Lifespan.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_Lifespan.type_identifier1()._d() && + EK_COMPLETE == type_ids_Lifespan.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_Lifespan.type_identifier1()._d() && + EK_COMPLETE == type_ids_Lifespan.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_Lifespan.type_identifier1()._d() && + EK_COMPLETE == type_ids_Lifespan.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_Lifespan.type_identifier1()._d() && + (EK_COMPLETE == type_ids_Lifespan.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_Lifespan.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_Lifespan.type_identifier1()._d() && + (EK_COMPLETE == type_ids_Lifespan.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_Lifespan.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_Lifespan.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_Lifespan.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_Lifespan.type_identifier2()._d() && + EK_COMPLETE == type_ids_Lifespan.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_Lifespan.type_identifier2()._d() && + EK_COMPLETE == type_ids_Lifespan.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_Lifespan.type_identifier2()._d() && + EK_COMPLETE == type_ids_Lifespan.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_Lifespan.type_identifier2()._d() && + EK_COMPLETE == type_ids_Lifespan.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_Lifespan.type_identifier2()._d() && + (EK_COMPLETE == type_ids_Lifespan.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_Lifespan.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_Lifespan.type_identifier2()._d() && + (EK_COMPLETE == type_ids_Lifespan.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_Lifespan.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_Lifespan.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure index member TypeIdentifier inconsistent."); + return; + } + MemberName name_index = "index"; + eprosima::fastcdr::optional member_ann_builtin_index; + ann_custom_Lifespan.reset(); + CompleteMemberDetail detail_index = TypeObjectUtils::build_complete_member_detail(name_index, member_ann_builtin_index, ann_custom_Lifespan); + CompleteStructMember member_index = TypeObjectUtils::build_complete_struct_member(common_index, detail_index); + TypeObjectUtils::add_complete_struct_member(member_seq_Lifespan, member_index); + } + { + return_code_Lifespan = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_string_unbounded", type_ids_Lifespan); + + if (return_code_Lifespan != eprosima::fastdds::dds::RETCODE_OK) + { + std::string type_id_kind_anonymous_string_unbounded("TI_STRING8_SMALL"); + if (type_id_kind_anonymous_string_unbounded == "TI_STRING8_SMALL") + { + SBound bound = 0; + StringSTypeDefn string_sdefn = TypeObjectUtils::build_string_s_type_defn(bound); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_string_type_identifier(string_sdefn, + "anonymous_string_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else if (type_id_kind_anonymous_string_unbounded == "TI_STRING8_LARGE") + { + LBound bound = 255; + StringLTypeDefn string_ldefn = TypeObjectUtils::build_string_l_type_defn(bound); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_string_type_identifier(string_ldefn, + "anonymous_string_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded: Unknown String kind."); + return; + } + return_code_Lifespan = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_string_unbounded", type_ids_Lifespan); + if (return_code_Lifespan != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded: Given String TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_message = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_message; + MemberId member_id_message = 0x00000001; + if (EK_COMPLETE == type_ids_Lifespan.type_identifier1()._d() || TK_NONE == type_ids_Lifespan.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_Lifespan.type_identifier1()._d() && + EK_COMPLETE == type_ids_Lifespan.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_Lifespan.type_identifier1()._d() && + EK_COMPLETE == type_ids_Lifespan.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_Lifespan.type_identifier1()._d() && + EK_COMPLETE == type_ids_Lifespan.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_Lifespan.type_identifier1()._d() && + EK_COMPLETE == type_ids_Lifespan.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_Lifespan.type_identifier1()._d() && + (EK_COMPLETE == type_ids_Lifespan.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_Lifespan.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_Lifespan.type_identifier1()._d() && + (EK_COMPLETE == type_ids_Lifespan.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_Lifespan.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_message = TypeObjectUtils::build_common_struct_member(member_id_message, member_flags_message, type_ids_Lifespan.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_Lifespan.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_Lifespan.type_identifier2()._d() && + EK_COMPLETE == type_ids_Lifespan.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_Lifespan.type_identifier2()._d() && + EK_COMPLETE == type_ids_Lifespan.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_Lifespan.type_identifier2()._d() && + EK_COMPLETE == type_ids_Lifespan.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_Lifespan.type_identifier2()._d() && + EK_COMPLETE == type_ids_Lifespan.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_Lifespan.type_identifier2()._d() && + (EK_COMPLETE == type_ids_Lifespan.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_Lifespan.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_Lifespan.type_identifier2()._d() && + (EK_COMPLETE == type_ids_Lifespan.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_Lifespan.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_message = TypeObjectUtils::build_common_struct_member(member_id_message, member_flags_message, type_ids_Lifespan.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure message member TypeIdentifier inconsistent."); + return; + } + MemberName name_message = "message"; + eprosima::fastcdr::optional member_ann_builtin_message; + ann_custom_Lifespan.reset(); + CompleteMemberDetail detail_message = TypeObjectUtils::build_complete_member_detail(name_message, member_ann_builtin_message, ann_custom_Lifespan); + CompleteStructMember member_message = TypeObjectUtils::build_complete_struct_member(common_message, detail_message); + TypeObjectUtils::add_complete_struct_member(member_seq_Lifespan, member_message); + } + CompleteStructType struct_type_Lifespan = TypeObjectUtils::build_complete_struct_type(struct_flags_Lifespan, header_Lifespan, member_seq_Lifespan); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_struct_type_object(struct_type_Lifespan, type_name_Lifespan.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Lifespan already registered in TypeObjectRegistry for a different type."); + } + return_code_Lifespan = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "Lifespan", type_ids_Lifespan); + if (return_code_Lifespan != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Lifespan: Given Struct TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } +} + diff --git a/examples/cpp/dds/LifespanQoSExample/LifespanTypeObjectSupport.hpp b/examples/cpp/dds/LifespanQoSExample/LifespanTypeObjectSupport.hpp new file mode 100644 index 00000000000..c0b2e0b9327 --- /dev/null +++ b/examples/cpp/dds/LifespanQoSExample/LifespanTypeObjectSupport.hpp @@ -0,0 +1,54 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file LifespanTypeObjectSupport.hpp + * Header file containing the API required to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#ifndef _FAST_DDS_GENERATED_LIFESPAN_TYPE_OBJECT_SUPPORT_HPP_ +#define _FAST_DDS_GENERATED_LIFESPAN_TYPE_OBJECT_SUPPORT_HPP_ + + +#if defined(_WIN32) +#if defined(EPROSIMA_USER_DLL_EXPORT) +#define eProsima_user_DllExport __declspec( dllexport ) +#else +#define eProsima_user_DllExport +#endif // EPROSIMA_USER_DLL_EXPORT +#else +#define eProsima_user_DllExport +#endif // _WIN32 + +/** + * @brief Register every TypeObject representation defined in the IDL file in Fast DDS TypeObjectRegistry. + */ +eProsima_user_DllExport void register_Lifespan_type_objects(); + +#ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +/** + * @brief Register Lifespan related TypeIdentifier. + * Fully-descriptive TypeIdentifiers are directly registered. + * Hash TypeIdentifiers require to fill the TypeObject information and hash it, consequently, the TypeObject is + * indirectly registered as well. + */ +void register_Lifespan_type_identifier(); + + +#endif // DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +#endif // _FAST_DDS_GENERATED_LIFESPAN_TYPE_OBJECT_SUPPORT_HPP_ diff --git a/examples/cpp/dds/LifespanQoSExample/Lifespan_main.cpp b/examples/cpp/dds/LifespanQoSExample/Lifespan_main.cpp index e0d2e4a395f..8b50afb30ce 100644 --- a/examples/cpp/dds/LifespanQoSExample/Lifespan_main.cpp +++ b/examples/cpp/dds/LifespanQoSExample/Lifespan_main.cpp @@ -17,15 +17,16 @@ * */ +#include + #include "LifespanPublisher.h" #include "LifespanSubscriber.h" -#include -#include - using namespace eprosima; using namespace fastrtps; using namespace rtps; +using namespace eprosima::fastdds::dds; + int main( int argc, char** argv) @@ -104,7 +105,6 @@ int main( break; } } - Domain::stopAll(); Log::Reset(); return 0; } diff --git a/examples/cpp/dds/LifespanQoSExample/Lifespanv1.cxx b/examples/cpp/dds/LifespanQoSExample/Lifespanv1.cxx deleted file mode 100644 index 81eaa4dd19b..00000000000 --- a/examples/cpp/dds/LifespanQoSExample/Lifespanv1.cxx +++ /dev/null @@ -1,286 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file Lifespan.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "Lifespan.h" - -#if FASTCDR_VERSION_MAJOR == 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - -namespace helper { namespace internal { - -enum class Size { - UInt8, - UInt16, - UInt32, - UInt64, -}; - -constexpr Size get_size(int s) { - return (s <= 8 ) ? Size::UInt8: - (s <= 16) ? Size::UInt16: - (s <= 32) ? Size::UInt32: Size::UInt64; -} - -template -struct FindTypeH; - -template<> -struct FindTypeH { - using type = std::uint8_t; -}; - -template<> -struct FindTypeH { - using type = std::uint16_t; -}; - -template<> -struct FindTypeH { - using type = std::uint32_t; -}; - -template<> -struct FindTypeH { - using type = std::uint64_t; -}; -} - -template -struct FindType { - using type = typename internal::FindTypeH::type; -}; -} - -#define Lifespan_max_cdr_typesize 268ULL; - - - - -Lifespan::Lifespan() -{ - // unsigned long m_index - m_index = 0; - // /type_d() m_message - - -} - -Lifespan::~Lifespan() -{ -} - -Lifespan::Lifespan( - const Lifespan& x) -{ - m_index = x.m_index; - - - m_message = x.m_message; - -} - -Lifespan::Lifespan( - Lifespan&& x) noexcept -{ - m_index = x.m_index; - - - m_message = std::move(x.m_message); - -} - -Lifespan& Lifespan::operator =( - const Lifespan& x) -{ - m_index = x.m_index; - - - m_message = x.m_message; - - return *this; -} - -Lifespan& Lifespan::operator =( - Lifespan&& x) noexcept -{ - m_index = x.m_index; - - - m_message = std::move(x.m_message); - - return *this; -} - -bool Lifespan::operator ==( - const Lifespan& x) const -{ - return (m_index == x.m_index && - m_message == x.m_message); -} - -bool Lifespan::operator !=( - const Lifespan& x) const -{ - return !(*this == x); -} - -size_t Lifespan::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return Lifespan_max_cdr_typesize; -} - -size_t Lifespan::getCdrSerializedSize( - const Lifespan& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + data.message().size() + 1; - - - return current_alignment - initial_alignment; -} - - -void Lifespan::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_index; - - scdr << m_message.c_str(); - -} - -void Lifespan::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_index; - - - - dcdr >> m_message; - - -} - - -bool Lifespan::isKeyDefined() -{ - return false; -} - -void Lifespan::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void Lifespan::index( - uint32_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint32_t Lifespan::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint32_t& Lifespan::index() -{ - return m_index; -} - - -/*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ -void Lifespan::message( - const std::string& _message) -{ - m_message = _message; -} - -/*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ -void Lifespan::message( - std::string&& _message) -{ - m_message = std::move(_message); -} - -/*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ -const std::string& Lifespan::message() const -{ - return m_message; -} - -/*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ -std::string& Lifespan::message() -{ - return m_message; -} - - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/LifespanQoSExample/Lifespanv1.h b/examples/cpp/dds/LifespanQoSExample/Lifespanv1.h deleted file mode 100644 index ad92ec390df..00000000000 --- a/examples/cpp/dds/LifespanQoSExample/Lifespanv1.h +++ /dev/null @@ -1,244 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file Lifespan.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#include - -#if FASTCDR_VERSION_MAJOR == 1 - -#ifndef _FAST_DDS_GENERATED_LIFESPAN_H_ -#define _FAST_DDS_GENERATED_LIFESPAN_H_ - - -#include - -#include -#include -#include -#include -#include -#include -#include - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define eProsima_user_DllExport -#endif // _WIN32 - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(LIFESPAN_SOURCE) -#define LIFESPAN_DllAPI __declspec( dllexport ) -#else -#define LIFESPAN_DllAPI __declspec( dllimport ) -#endif // LIFESPAN_SOURCE -#else -#define LIFESPAN_DllAPI -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define LIFESPAN_DllAPI -#endif // _WIN32 - -namespace eprosima { -namespace fastcdr { -class Cdr; -} // namespace fastcdr -} // namespace eprosima - - - - - -/*! - * @brief This class represents the structure Lifespan defined by the user in the IDL file. - * @ingroup Lifespan - */ -class Lifespan -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport Lifespan(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~Lifespan(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object Lifespan that will be copied. - */ - eProsima_user_DllExport Lifespan( - const Lifespan& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object Lifespan that will be copied. - */ - eProsima_user_DllExport Lifespan( - Lifespan&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object Lifespan that will be copied. - */ - eProsima_user_DllExport Lifespan& operator =( - const Lifespan& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object Lifespan that will be copied. - */ - eProsima_user_DllExport Lifespan& operator =( - Lifespan&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x Lifespan object to compare. - */ - eProsima_user_DllExport bool operator ==( - const Lifespan& x) const; - - /*! - * @brief Comparison operator. - * @param x Lifespan object to compare. - */ - eProsima_user_DllExport bool operator !=( - const Lifespan& x) const; - - /*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ - eProsima_user_DllExport void index( - uint32_t _index); - - /*! - * @brief This function returns the value of member index - * @return Value of member index - */ - eProsima_user_DllExport uint32_t index() const; - - /*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ - eProsima_user_DllExport uint32_t& index(); - - - /*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ - eProsima_user_DllExport void message( - const std::string& _message); - - /*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ - eProsima_user_DllExport void message( - std::string&& _message); - - /*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ - eProsima_user_DllExport const std::string& message() const; - - /*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ - eProsima_user_DllExport std::string& message(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const Lifespan& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - uint32_t m_index; - std::string m_message; - -}; - - -#endif // _FAST_DDS_GENERATED_LIFESPAN_H_ - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/LivelinessQoS/CMakeLists.txt b/examples/cpp/dds/LivelinessQoS/CMakeLists.txt index 6e9a89e4de7..a49536c22b5 100644 --- a/examples/cpp/dds/LivelinessQoS/CMakeLists.txt +++ b/examples/cpp/dds/LivelinessQoS/CMakeLists.txt @@ -21,8 +21,8 @@ if(NOT fastcdr_FOUND) find_package(fastcdr 2 REQUIRED) endif() -if(NOT fastrtps_FOUND) - find_package(fastrtps 2.12 REQUIRED) +if(NOT fastdds_FOUND) + find_package(fastdds 3 REQUIRED) endif() #Check C++11 @@ -43,6 +43,6 @@ target_compile_definitions(DDSLivelinessQoS PRIVATE $<$>,$>:__DEBUG> $<$:__INTERNALDEBUG> # Internal debug activated. ) -target_link_libraries(DDSLivelinessQoS fastrtps fastcdr) +target_link_libraries(DDSLivelinessQoS fastdds fastcdr) install(TARGETS DDSLivelinessQoS RUNTIME DESTINATION examples/cpp/dds/LivelinessQoS/${BIN_INSTALL_DIR}) diff --git a/examples/cpp/dds/LivelinessQoS/LivelinessPublisher.h b/examples/cpp/dds/LivelinessQoS/LivelinessPublisher.h index 5efec3fec94..f3cfca53c7b 100644 --- a/examples/cpp/dds/LivelinessQoS/LivelinessPublisher.h +++ b/examples/cpp/dds/LivelinessQoS/LivelinessPublisher.h @@ -20,16 +20,16 @@ #ifndef LivelinessPublisher_H_ #define LivelinessPublisher_H_ -#include "TopicPubSubTypes.h" -#include "Topic.h" +#include #include -#include #include #include +#include #include -#include +#include "TopicPubSubTypes.h" +#include "Topic.hpp" class LivelinessPublisher { @@ -43,7 +43,7 @@ class LivelinessPublisher //! Initialize bool init( - eprosima::fastrtps::LivelinessQosPolicyKind kind, + eprosima::fastdds::dds::LivelinessQosPolicyKind kind, int liveliness_ms); //! Publish a sample @@ -90,7 +90,7 @@ class LivelinessPublisher void on_liveliness_lost( eprosima::fastdds::dds::DataWriter* writer, - const eprosima::fastrtps::LivelinessLostStatus& status) override; + const eprosima::fastdds::dds::LivelinessLostStatus& status) override; int n_matched; diff --git a/examples/cpp/dds/LivelinessQoS/LivelinessSubscriber.cpp b/examples/cpp/dds/LivelinessQoS/LivelinessSubscriber.cpp index 6e94d9570e6..e18664904ad 100644 --- a/examples/cpp/dds/LivelinessQoS/LivelinessSubscriber.cpp +++ b/examples/cpp/dds/LivelinessQoS/LivelinessSubscriber.cpp @@ -138,7 +138,7 @@ void LivelinessSubscriber::SubListener::on_data_available( DataReader* reader) { SampleInfo info; - if (reader->take_next_sample(&topic, &info) == ReturnCode_t::RETCODE_OK) + if (reader->take_next_sample(&topic, &info) == RETCODE_OK) { if (info.valid_data) { @@ -182,8 +182,10 @@ void LivelinessSubscriber::run( void LivelinessSubscriber::PartListener::on_participant_discovery( DomainParticipant*, - ParticipantDiscoveryInfo&& info) + ParticipantDiscoveryInfo&& info, + bool& should_be_ignored) { + static_cast(should_be_ignored); if (info.status == ParticipantDiscoveryInfo::DISCOVERED_PARTICIPANT) { std::cout << "Participant discovered" << std::endl; diff --git a/examples/cpp/dds/LivelinessQoS/LivelinessSubscriber.h b/examples/cpp/dds/LivelinessQoS/LivelinessSubscriber.h index 154decdf689..fc3f2065053 100644 --- a/examples/cpp/dds/LivelinessQoS/LivelinessSubscriber.h +++ b/examples/cpp/dds/LivelinessQoS/LivelinessSubscriber.h @@ -20,17 +20,17 @@ #ifndef LIVELINESSSUBSCRIBER_H_ #define LIVELINESSSUBSCRIBER_H_ -#include "TopicPubSubTypes.h" -#include "Topic.h" - #include #include -#include #include #include +#include #include #include +#include "TopicPubSubTypes.h" +#include "Topic.hpp" + class LivelinessSubscriber { public: @@ -43,7 +43,7 @@ class LivelinessSubscriber //! Initialize the subscriber bool init( - eprosima::fastrtps::LivelinessQosPolicyKind kind, + eprosima::fastdds::dds::LivelinessQosPolicyKind kind, int liveliness_ms); //! RUN the subscriber @@ -105,7 +105,8 @@ class LivelinessSubscriber virtual void on_participant_discovery( eprosima::fastdds::dds::DomainParticipant* participant, - eprosima::fastrtps::rtps::ParticipantDiscoveryInfo&& info) override; + eprosima::fastrtps::rtps::ParticipantDiscoveryInfo&& info, + bool& should_be_ignored) override; private: diff --git a/examples/cpp/dds/LivelinessQoS/Liveliness_main.cpp b/examples/cpp/dds/LivelinessQoS/Liveliness_main.cpp index 2c3c28f0514..93ece7e9990 100644 --- a/examples/cpp/dds/LivelinessQoS/Liveliness_main.cpp +++ b/examples/cpp/dds/LivelinessQoS/Liveliness_main.cpp @@ -17,16 +17,16 @@ * */ +#include +#include + #include "LivelinessPublisher.h" #include "LivelinessSubscriber.h" -#include -#include -#include - using namespace eprosima; using namespace fastrtps; using namespace rtps; +using namespace eprosima::fastdds::dds; //! //! \brief Parses command line artuments @@ -57,7 +57,7 @@ int main( int sleep_ms = 1000; int count = 10; - eprosima::fastrtps::LivelinessQosPolicyKind kind = eprosima::fastrtps::AUTOMATIC_LIVELINESS_QOS; + LivelinessQosPolicyKind kind = LivelinessQosPolicyKind::AUTOMATIC_LIVELINESS_QOS; if (!parse_arguments( argc, @@ -109,7 +109,6 @@ int main( break; } } - Domain::stopAll(); Log::Reset(); return 0; } @@ -119,7 +118,7 @@ bool parse_arguments( char** argv, int& type, int& lease_duration_ms, - eprosima::fastrtps::LivelinessQosPolicyKind& kind, + LivelinessQosPolicyKind& kind, int& sleep_ms, int& samples) { @@ -153,15 +152,15 @@ bool parse_arguments( { if (!strcmp(argv[count + 1], "AUTOMATIC")) { - kind = eprosima::fastrtps::LivelinessQosPolicyKind::AUTOMATIC_LIVELINESS_QOS; + kind = LivelinessQosPolicyKind::AUTOMATIC_LIVELINESS_QOS; } else if (!strcmp(argv[count + 1], "MANUAL_BY_PARTICIPANT")) { - kind = eprosima::fastrtps::LivelinessQosPolicyKind::MANUAL_BY_PARTICIPANT_LIVELINESS_QOS; + kind = LivelinessQosPolicyKind::MANUAL_BY_PARTICIPANT_LIVELINESS_QOS; } else if (!strcmp(argv[count + 1], "MANUAL_BY_TOPIC")) { - kind = eprosima::fastrtps::LivelinessQosPolicyKind::MANUAL_BY_TOPIC_LIVELINESS_QOS; + kind = LivelinessQosPolicyKind::MANUAL_BY_TOPIC_LIVELINESS_QOS; } else { @@ -201,15 +200,15 @@ bool parse_arguments( { if (!strcmp(argv[count + 1], "AUTOMATIC")) { - kind = eprosima::fastrtps::LivelinessQosPolicyKind::AUTOMATIC_LIVELINESS_QOS; + kind = LivelinessQosPolicyKind::AUTOMATIC_LIVELINESS_QOS; } else if (!strcmp(argv[count + 1], "MANUAL_BY_PARTICIPANT")) { - kind = eprosima::fastrtps::LivelinessQosPolicyKind::MANUAL_BY_PARTICIPANT_LIVELINESS_QOS; + kind = LivelinessQosPolicyKind::MANUAL_BY_PARTICIPANT_LIVELINESS_QOS; } else if (!strcmp(argv[count + 1], "MANUAL_BY_TOPIC")) { - kind = eprosima::fastrtps::LivelinessQosPolicyKind::MANUAL_BY_TOPIC_LIVELINESS_QOS; + kind = LivelinessQosPolicyKind::MANUAL_BY_TOPIC_LIVELINESS_QOS; } else { diff --git a/examples/cpp/dds/LivelinessQoS/Topic.cxx b/examples/cpp/dds/LivelinessQoS/Topic.cxx deleted file mode 100644 index ca86d176ba1..00000000000 --- a/examples/cpp/dds/LivelinessQoS/Topic.cxx +++ /dev/null @@ -1,168 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file Topic.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "Topic.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - - - - -Topic::Topic() -{ -} - -Topic::~Topic() -{ -} - -Topic::Topic( - const Topic& x) -{ - m_index = x.m_index; - m_message = x.m_message; -} - -Topic::Topic( - Topic&& x) noexcept -{ - m_index = x.m_index; - m_message = std::move(x.m_message); -} - -Topic& Topic::operator =( - const Topic& x) -{ - - m_index = x.m_index; - m_message = x.m_message; - return *this; -} - -Topic& Topic::operator =( - Topic&& x) noexcept -{ - - m_index = x.m_index; - m_message = std::move(x.m_message); - return *this; -} - -bool Topic::operator ==( - const Topic& x) const -{ - return (m_index == x.m_index && - m_message == x.m_message); -} - -bool Topic::operator !=( - const Topic& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void Topic::index( - uint32_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint32_t Topic::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint32_t& Topic::index() -{ - return m_index; -} - - -/*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ -void Topic::message( - const std::string& _message) -{ - m_message = _message; -} - -/*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ -void Topic::message( - std::string&& _message) -{ - m_message = std::move(_message); -} - -/*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ -const std::string& Topic::message() const -{ - return m_message; -} - -/*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ -std::string& Topic::message() -{ - return m_message; -} - - -// Include auxiliary functions like for serializing/deserializing. -#include "TopicCdrAux.ipp" - -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/DisablePositiveACKs/Topic.h b/examples/cpp/dds/LivelinessQoS/Topic.hpp similarity index 69% rename from examples/cpp/dds/DisablePositiveACKs/Topic.h rename to examples/cpp/dds/LivelinessQoS/Topic.hpp index 2596f317a1e..8f86884c2b8 100644 --- a/examples/cpp/dds/DisablePositiveACKs/Topic.h +++ b/examples/cpp/dds/LivelinessQoS/Topic.hpp @@ -13,32 +13,19 @@ // limitations under the License. /*! - * @file Topic.h + * @file Topic.hpp * This header file contains the declaration of the described types in the IDL file. * * This file was generated by the tool fastddsgen. */ -#include -#include "Topicv1.h" +#ifndef _FAST_DDS_GENERATED_TOPIC_HPP_ +#define _FAST_DDS_GENERATED_TOPIC_HPP_ -#if FASTCDR_VERSION_MAJOR > 1 - -#ifndef _FAST_DDS_GENERATED_TOPIC_H_ -#define _FAST_DDS_GENERATED_TOPIC_H_ - -#include -#include #include -#include #include -#include - +#include #include -#include -#include - - #if defined(_WIN32) #if defined(EPROSIMA_USER_DLL_EXPORT) @@ -64,17 +51,6 @@ #define TOPIC_DllAPI #endif // _WIN32 -namespace eprosima { -namespace fastcdr { -class Cdr; -class CdrSizeCalculator; -} // namespace fastcdr -} // namespace eprosima - - - - - /*! * @brief This class represents the structure Topic defined by the user in the IDL file. * @ingroup Topic @@ -86,73 +62,117 @@ class Topic /*! * @brief Default constructor. */ - eProsima_user_DllExport Topic(); + eProsima_user_DllExport Topic() + { + } /*! * @brief Default destructor. */ - eProsima_user_DllExport ~Topic(); + eProsima_user_DllExport ~Topic() + { + } /*! * @brief Copy constructor. * @param x Reference to the object Topic that will be copied. */ eProsima_user_DllExport Topic( - const Topic& x); + const Topic& x) + { + m_index = x.m_index; + + m_message = x.m_message; + + } /*! * @brief Move constructor. * @param x Reference to the object Topic that will be copied. */ eProsima_user_DllExport Topic( - Topic&& x) noexcept; + Topic&& x) noexcept + { + m_index = x.m_index; + m_message = std::move(x.m_message); + } /*! * @brief Copy assignment. * @param x Reference to the object Topic that will be copied. */ eProsima_user_DllExport Topic& operator =( - const Topic& x); + const Topic& x) + { + + m_index = x.m_index; + + m_message = x.m_message; + + return *this; + } /*! * @brief Move assignment. * @param x Reference to the object Topic that will be copied. */ eProsima_user_DllExport Topic& operator =( - Topic&& x) noexcept; + Topic&& x) noexcept + { + + m_index = x.m_index; + m_message = std::move(x.m_message); + return *this; + } /*! * @brief Comparison operator. * @param x Topic object to compare. */ eProsima_user_DllExport bool operator ==( - const Topic& x) const; + const Topic& x) const + { + return (m_index == x.m_index && + m_message == x.m_message); + } /*! * @brief Comparison operator. * @param x Topic object to compare. */ eProsima_user_DllExport bool operator !=( - const Topic& x) const; + const Topic& x) const + { + return !(*this == x); + } /*! * @brief This function sets a value in member index * @param _index New value for member index */ eProsima_user_DllExport void index( - uint32_t _index); + uint32_t _index) + { + m_index = _index; + } /*! * @brief This function returns the value of member index * @return Value of member index */ - eProsima_user_DllExport uint32_t index() const; + eProsima_user_DllExport uint32_t index() const + { + return m_index; + } /*! * @brief This function returns a reference to member index * @return Reference to member index */ - eProsima_user_DllExport uint32_t& index(); + eProsima_user_DllExport uint32_t& index() + { + return m_index; + } /*! @@ -160,26 +180,40 @@ class Topic * @param _message New value to be copied in member message */ eProsima_user_DllExport void message( - const std::string& _message); + const std::string& _message) + { + m_message = _message; + } /*! * @brief This function moves the value in member message * @param _message New value to be moved in member message */ eProsima_user_DllExport void message( - std::string&& _message); + std::string&& _message) + { + m_message = std::move(_message); + } /*! * @brief This function returns a constant reference to member message * @return Constant reference to member message */ - eProsima_user_DllExport const std::string& message() const; + eProsima_user_DllExport const std::string& message() const + { + return m_message; + } /*! * @brief This function returns a reference to member message * @return Reference to member message */ - eProsima_user_DllExport std::string& message(); + eProsima_user_DllExport std::string& message() + { + return m_message; + } + + private: @@ -188,8 +222,6 @@ class Topic }; -#endif // _FAST_DDS_GENERATED_TOPIC_H_ - +#endif // _FAST_DDS_GENERATED_TOPIC_HPP_ -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/LivelinessQoS/TopicCdrAux.hpp b/examples/cpp/dds/LivelinessQoS/TopicCdrAux.hpp index 619cdbbb7b8..7b60c44c7b4 100644 --- a/examples/cpp/dds/LivelinessQoS/TopicCdrAux.hpp +++ b/examples/cpp/dds/LivelinessQoS/TopicCdrAux.hpp @@ -22,7 +22,7 @@ #ifndef _FAST_DDS_GENERATED_TOPICCDRAUX_HPP_ #define _FAST_DDS_GENERATED_TOPICCDRAUX_HPP_ -#include "Topic.h" +#include "Topic.hpp" constexpr uint32_t Topic_max_cdr_typesize {268UL}; constexpr uint32_t Topic_max_key_cdr_typesize {0UL}; @@ -34,8 +34,6 @@ namespace fastcdr { class Cdr; class CdrSizeCalculator; - - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const Topic& data); diff --git a/examples/cpp/dds/LivelinessQoS/TopicCdrAux.ipp b/examples/cpp/dds/LivelinessQoS/TopicCdrAux.ipp index ac5a8c39ef9..37570c8a6b2 100644 --- a/examples/cpp/dds/LivelinessQoS/TopicCdrAux.ipp +++ b/examples/cpp/dds/LivelinessQoS/TopicCdrAux.ipp @@ -34,8 +34,6 @@ using namespace eprosima::fastcdr::exception; namespace eprosima { namespace fastcdr { - - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, diff --git a/examples/cpp/dds/LivelinessQoS/TopicPubSubTypes.cxx b/examples/cpp/dds/LivelinessQoS/TopicPubSubTypes.cxx index ce688064a0e..8d6d0b195c9 100644 --- a/examples/cpp/dds/LivelinessQoS/TopicPubSubTypes.cxx +++ b/examples/cpp/dds/LivelinessQoS/TopicPubSubTypes.cxx @@ -19,18 +19,18 @@ * This file was generated by the tool fastddsgen. */ +#include "TopicPubSubTypes.h" +#include #include -#include "TopicPubSubTypes.h" #include "TopicCdrAux.hpp" +#include "TopicTypeObjectSupport.hpp" using SerializedPayload_t = eprosima::fastrtps::rtps::SerializedPayload_t; using InstanceHandle_t = eprosima::fastrtps::rtps::InstanceHandle_t; using DataRepresentationId_t = eprosima::fastdds::dds::DataRepresentationId_t; - - TopicPubSubType::TopicPubSubType() { setName("Topic"); @@ -219,3 +219,11 @@ bool TopicPubSubType::getKey( return true; } +void TopicPubSubType::register_type_object_representation() const +{ + register_Topic_type_objects(); +} + + +// Include auxiliary functions like for serializing/deserializing. +#include "TopicCdrAux.ipp" diff --git a/examples/cpp/dds/LivelinessQoS/TopicPubSubTypes.h b/examples/cpp/dds/LivelinessQoS/TopicPubSubTypes.h index b9100bacbe9..0b37b3746f3 100644 --- a/examples/cpp/dds/LivelinessQoS/TopicPubSubTypes.h +++ b/examples/cpp/dds/LivelinessQoS/TopicPubSubTypes.h @@ -27,9 +27,9 @@ #include #include #include -#include +#include -#include "Topic.h" +#include "Topic.hpp" #if !defined(GEN_API_VER) || (GEN_API_VER != 2) @@ -38,8 +38,6 @@ #endif // GEN_API_VER - - /*! * @brief This class represents the TopicDataType of the type Topic defined by the user in the IDL file. * @ingroup Topic @@ -90,6 +88,9 @@ class TopicPubSubType : public eprosima::fastdds::dds::TopicDataType eProsima_user_DllExport void deleteData( void* data) override; + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + #ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED eProsima_user_DllExport inline bool is_bounded() const override { diff --git a/examples/cpp/dds/LivelinessQoS/TopicTypeObjectSupport.cxx b/examples/cpp/dds/LivelinessQoS/TopicTypeObjectSupport.cxx new file mode 100644 index 00000000000..067fd08a822 --- /dev/null +++ b/examples/cpp/dds/LivelinessQoS/TopicTypeObjectSupport.cxx @@ -0,0 +1,248 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file TopicTypeObjectSupport.cxx + * Source file containing the implementation to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#include "TopicTypeObjectSupport.hpp" + +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include + +#include "Topic.hpp" + + +using namespace eprosima::fastdds::dds::xtypes; + +void register_Topic_type_objects() +{ + static std::once_flag once_flag; + std::call_once(once_flag, []() + { + register_Topic_type_identifier(); + + }); +} + +void register_Topic_type_identifier() +{ + { + StructTypeFlag struct_flags_Topic = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::NOT_APPLIED, + false, false); + ReturnCode_t return_code_Topic; + TypeIdentifierPair type_ids_Topic; + QualifiedTypeName type_name_Topic = "Topic"; + eprosima::fastcdr::optional type_ann_builtin_Topic; + eprosima::fastcdr::optional ann_custom_Topic; + CompleteTypeDetail detail_Topic = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_Topic, ann_custom_Topic, type_name_Topic.to_string()); + CompleteStructHeader header_Topic; + header_Topic = TypeObjectUtils::build_complete_struct_header(TypeIdentifier(), detail_Topic); + CompleteStructMemberSeq member_seq_Topic; + { + return_code_Topic = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_uint32_t", type_ids_Topic); + + if (return_code_Topic != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "index Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_index = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_index; + MemberId member_id_index = 0x00000000; + if (EK_COMPLETE == type_ids_Topic.type_identifier1()._d() || TK_NONE == type_ids_Topic.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_Topic.type_identifier1()._d() && + EK_COMPLETE == type_ids_Topic.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_Topic.type_identifier1()._d() && + EK_COMPLETE == type_ids_Topic.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_Topic.type_identifier1()._d() && + EK_COMPLETE == type_ids_Topic.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_Topic.type_identifier1()._d() && + EK_COMPLETE == type_ids_Topic.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_Topic.type_identifier1()._d() && + (EK_COMPLETE == type_ids_Topic.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_Topic.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_Topic.type_identifier1()._d() && + (EK_COMPLETE == type_ids_Topic.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_Topic.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_Topic.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_Topic.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_Topic.type_identifier2()._d() && + EK_COMPLETE == type_ids_Topic.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_Topic.type_identifier2()._d() && + EK_COMPLETE == type_ids_Topic.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_Topic.type_identifier2()._d() && + EK_COMPLETE == type_ids_Topic.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_Topic.type_identifier2()._d() && + EK_COMPLETE == type_ids_Topic.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_Topic.type_identifier2()._d() && + (EK_COMPLETE == type_ids_Topic.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_Topic.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_Topic.type_identifier2()._d() && + (EK_COMPLETE == type_ids_Topic.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_Topic.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_Topic.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure index member TypeIdentifier inconsistent."); + return; + } + MemberName name_index = "index"; + eprosima::fastcdr::optional member_ann_builtin_index; + ann_custom_Topic.reset(); + CompleteMemberDetail detail_index = TypeObjectUtils::build_complete_member_detail(name_index, member_ann_builtin_index, ann_custom_Topic); + CompleteStructMember member_index = TypeObjectUtils::build_complete_struct_member(common_index, detail_index); + TypeObjectUtils::add_complete_struct_member(member_seq_Topic, member_index); + } + { + return_code_Topic = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_string_unbounded", type_ids_Topic); + + if (return_code_Topic != eprosima::fastdds::dds::RETCODE_OK) + { + std::string type_id_kind_anonymous_string_unbounded("TI_STRING8_SMALL"); + if (type_id_kind_anonymous_string_unbounded == "TI_STRING8_SMALL") + { + SBound bound = 0; + StringSTypeDefn string_sdefn = TypeObjectUtils::build_string_s_type_defn(bound); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_string_type_identifier(string_sdefn, + "anonymous_string_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else if (type_id_kind_anonymous_string_unbounded == "TI_STRING8_LARGE") + { + LBound bound = 255; + StringLTypeDefn string_ldefn = TypeObjectUtils::build_string_l_type_defn(bound); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_string_type_identifier(string_ldefn, + "anonymous_string_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded: Unknown String kind."); + return; + } + return_code_Topic = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_string_unbounded", type_ids_Topic); + if (return_code_Topic != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded: Given String TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_message = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_message; + MemberId member_id_message = 0x00000001; + if (EK_COMPLETE == type_ids_Topic.type_identifier1()._d() || TK_NONE == type_ids_Topic.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_Topic.type_identifier1()._d() && + EK_COMPLETE == type_ids_Topic.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_Topic.type_identifier1()._d() && + EK_COMPLETE == type_ids_Topic.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_Topic.type_identifier1()._d() && + EK_COMPLETE == type_ids_Topic.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_Topic.type_identifier1()._d() && + EK_COMPLETE == type_ids_Topic.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_Topic.type_identifier1()._d() && + (EK_COMPLETE == type_ids_Topic.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_Topic.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_Topic.type_identifier1()._d() && + (EK_COMPLETE == type_ids_Topic.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_Topic.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_message = TypeObjectUtils::build_common_struct_member(member_id_message, member_flags_message, type_ids_Topic.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_Topic.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_Topic.type_identifier2()._d() && + EK_COMPLETE == type_ids_Topic.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_Topic.type_identifier2()._d() && + EK_COMPLETE == type_ids_Topic.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_Topic.type_identifier2()._d() && + EK_COMPLETE == type_ids_Topic.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_Topic.type_identifier2()._d() && + EK_COMPLETE == type_ids_Topic.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_Topic.type_identifier2()._d() && + (EK_COMPLETE == type_ids_Topic.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_Topic.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_Topic.type_identifier2()._d() && + (EK_COMPLETE == type_ids_Topic.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_Topic.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_message = TypeObjectUtils::build_common_struct_member(member_id_message, member_flags_message, type_ids_Topic.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure message member TypeIdentifier inconsistent."); + return; + } + MemberName name_message = "message"; + eprosima::fastcdr::optional member_ann_builtin_message; + ann_custom_Topic.reset(); + CompleteMemberDetail detail_message = TypeObjectUtils::build_complete_member_detail(name_message, member_ann_builtin_message, ann_custom_Topic); + CompleteStructMember member_message = TypeObjectUtils::build_complete_struct_member(common_message, detail_message); + TypeObjectUtils::add_complete_struct_member(member_seq_Topic, member_message); + } + CompleteStructType struct_type_Topic = TypeObjectUtils::build_complete_struct_type(struct_flags_Topic, header_Topic, member_seq_Topic); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_struct_type_object(struct_type_Topic, type_name_Topic.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Topic already registered in TypeObjectRegistry for a different type."); + } + return_code_Topic = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "Topic", type_ids_Topic); + if (return_code_Topic != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Topic: Given Struct TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } +} + diff --git a/examples/cpp/dds/LivelinessQoS/TopicTypeObjectSupport.hpp b/examples/cpp/dds/LivelinessQoS/TopicTypeObjectSupport.hpp new file mode 100644 index 00000000000..f0576f9b948 --- /dev/null +++ b/examples/cpp/dds/LivelinessQoS/TopicTypeObjectSupport.hpp @@ -0,0 +1,54 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file TopicTypeObjectSupport.hpp + * Header file containing the API required to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#ifndef _FAST_DDS_GENERATED_TOPIC_TYPE_OBJECT_SUPPORT_HPP_ +#define _FAST_DDS_GENERATED_TOPIC_TYPE_OBJECT_SUPPORT_HPP_ + + +#if defined(_WIN32) +#if defined(EPROSIMA_USER_DLL_EXPORT) +#define eProsima_user_DllExport __declspec( dllexport ) +#else +#define eProsima_user_DllExport +#endif // EPROSIMA_USER_DLL_EXPORT +#else +#define eProsima_user_DllExport +#endif // _WIN32 + +/** + * @brief Register every TypeObject representation defined in the IDL file in Fast DDS TypeObjectRegistry. + */ +eProsima_user_DllExport void register_Topic_type_objects(); + +#ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +/** + * @brief Register Topic related TypeIdentifier. + * Fully-descriptive TypeIdentifiers are directly registered. + * Hash TypeIdentifiers require to fill the TypeObject information and hash it, consequently, the TypeObject is + * indirectly registered as well. + */ +void register_Topic_type_identifier(); + + +#endif // DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +#endif // _FAST_DDS_GENERATED_TOPIC_TYPE_OBJECT_SUPPORT_HPP_ diff --git a/examples/cpp/dds/LivelinessQoS/Topicv1.cxx b/examples/cpp/dds/LivelinessQoS/Topicv1.cxx deleted file mode 100644 index a3e85584242..00000000000 --- a/examples/cpp/dds/LivelinessQoS/Topicv1.cxx +++ /dev/null @@ -1,286 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file Topic.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "Topic.h" - -#if FASTCDR_VERSION_MAJOR == 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - -namespace helper { namespace internal { - -enum class Size { - UInt8, - UInt16, - UInt32, - UInt64, -}; - -constexpr Size get_size(int s) { - return (s <= 8 ) ? Size::UInt8: - (s <= 16) ? Size::UInt16: - (s <= 32) ? Size::UInt32: Size::UInt64; -} - -template -struct FindTypeH; - -template<> -struct FindTypeH { - using type = std::uint8_t; -}; - -template<> -struct FindTypeH { - using type = std::uint16_t; -}; - -template<> -struct FindTypeH { - using type = std::uint32_t; -}; - -template<> -struct FindTypeH { - using type = std::uint64_t; -}; -} - -template -struct FindType { - using type = typename internal::FindTypeH::type; -}; -} - -#define Topic_max_cdr_typesize 268ULL; - - - - -Topic::Topic() -{ - // unsigned long m_index - m_index = 0; - // /type_d() m_message - - -} - -Topic::~Topic() -{ -} - -Topic::Topic( - const Topic& x) -{ - m_index = x.m_index; - - - m_message = x.m_message; - -} - -Topic::Topic( - Topic&& x) noexcept -{ - m_index = x.m_index; - - - m_message = std::move(x.m_message); - -} - -Topic& Topic::operator =( - const Topic& x) -{ - m_index = x.m_index; - - - m_message = x.m_message; - - return *this; -} - -Topic& Topic::operator =( - Topic&& x) noexcept -{ - m_index = x.m_index; - - - m_message = std::move(x.m_message); - - return *this; -} - -bool Topic::operator ==( - const Topic& x) const -{ - return (m_index == x.m_index && - m_message == x.m_message); -} - -bool Topic::operator !=( - const Topic& x) const -{ - return !(*this == x); -} - -size_t Topic::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return Topic_max_cdr_typesize; -} - -size_t Topic::getCdrSerializedSize( - const Topic& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + data.message().size() + 1; - - - return current_alignment - initial_alignment; -} - - -void Topic::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_index; - - scdr << m_message.c_str(); - -} - -void Topic::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_index; - - - - dcdr >> m_message; - - -} - - -bool Topic::isKeyDefined() -{ - return false; -} - -void Topic::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void Topic::index( - uint32_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint32_t Topic::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint32_t& Topic::index() -{ - return m_index; -} - - -/*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ -void Topic::message( - const std::string& _message) -{ - m_message = _message; -} - -/*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ -void Topic::message( - std::string&& _message) -{ - m_message = std::move(_message); -} - -/*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ -const std::string& Topic::message() const -{ - return m_message; -} - -/*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ -std::string& Topic::message() -{ - return m_message; -} - - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/LivelinessQoS/Topicv1.h b/examples/cpp/dds/LivelinessQoS/Topicv1.h deleted file mode 100644 index e06f22b7e2b..00000000000 --- a/examples/cpp/dds/LivelinessQoS/Topicv1.h +++ /dev/null @@ -1,244 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file Topic.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#include - -#if FASTCDR_VERSION_MAJOR == 1 - -#ifndef _FAST_DDS_GENERATED_TOPIC_H_ -#define _FAST_DDS_GENERATED_TOPIC_H_ - - -#include - -#include -#include -#include -#include -#include -#include -#include - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define eProsima_user_DllExport -#endif // _WIN32 - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(TOPIC_SOURCE) -#define TOPIC_DllAPI __declspec( dllexport ) -#else -#define TOPIC_DllAPI __declspec( dllimport ) -#endif // TOPIC_SOURCE -#else -#define TOPIC_DllAPI -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define TOPIC_DllAPI -#endif // _WIN32 - -namespace eprosima { -namespace fastcdr { -class Cdr; -} // namespace fastcdr -} // namespace eprosima - - - - - -/*! - * @brief This class represents the structure Topic defined by the user in the IDL file. - * @ingroup Topic - */ -class Topic -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport Topic(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~Topic(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object Topic that will be copied. - */ - eProsima_user_DllExport Topic( - const Topic& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object Topic that will be copied. - */ - eProsima_user_DllExport Topic( - Topic&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object Topic that will be copied. - */ - eProsima_user_DllExport Topic& operator =( - const Topic& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object Topic that will be copied. - */ - eProsima_user_DllExport Topic& operator =( - Topic&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x Topic object to compare. - */ - eProsima_user_DllExport bool operator ==( - const Topic& x) const; - - /*! - * @brief Comparison operator. - * @param x Topic object to compare. - */ - eProsima_user_DllExport bool operator !=( - const Topic& x) const; - - /*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ - eProsima_user_DllExport void index( - uint32_t _index); - - /*! - * @brief This function returns the value of member index - * @return Value of member index - */ - eProsima_user_DllExport uint32_t index() const; - - /*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ - eProsima_user_DllExport uint32_t& index(); - - - /*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ - eProsima_user_DllExport void message( - const std::string& _message); - - /*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ - eProsima_user_DllExport void message( - std::string&& _message); - - /*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ - eProsima_user_DllExport const std::string& message() const; - - /*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ - eProsima_user_DllExport std::string& message(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const Topic& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - uint32_t m_index; - std::string m_message; - -}; - - -#endif // _FAST_DDS_GENERATED_TOPIC_H_ - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/OwnershipStrengthQoSExample/CMakeLists.txt b/examples/cpp/dds/OwnershipStrengthQoSExample/CMakeLists.txt index f26d31984dd..4f77e0747a9 100644 --- a/examples/cpp/dds/OwnershipStrengthQoSExample/CMakeLists.txt +++ b/examples/cpp/dds/OwnershipStrengthQoSExample/CMakeLists.txt @@ -25,8 +25,8 @@ if(NOT foonathan_memory_FOUND) find_package(foonathan_memory REQUIRED) endif() -if(NOT fastrtps_FOUND) - find_package(fastrtps 2.12 REQUIRED) +if(NOT fastdds_FOUND) + find_package(fastdds 3 REQUIRED) endif() #Check C++11 @@ -46,7 +46,7 @@ target_compile_definitions(DDSOwnershipStrengthQoSExample PRIVATE $<$>,$>:__DEBUG> $<$:__INTERNALDEBUG> # Internal debug activated. ) -target_link_libraries(DDSOwnershipStrengthQoSExample fastrtps fastcdr foonathan_memory) +target_link_libraries(DDSOwnershipStrengthQoSExample fastdds fastcdr foonathan_memory) install(TARGETS DDSOwnershipStrengthQoSExample RUNTIME DESTINATION examples/cpp/dds/OwnershipStrengthQoSExample/${BIN_INSTALL_DIR} ) diff --git a/examples/cpp/dds/OwnershipStrengthQoSExample/OwnershipStrength.cxx b/examples/cpp/dds/OwnershipStrengthQoSExample/OwnershipStrength.cxx deleted file mode 100644 index c566d2aa145..00000000000 --- a/examples/cpp/dds/OwnershipStrengthQoSExample/OwnershipStrength.cxx +++ /dev/null @@ -1,202 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file OwnershipStrength.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "OwnershipStrength.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - - - - -ExampleMessage::ExampleMessage() -{ -} - -ExampleMessage::~ExampleMessage() -{ -} - -ExampleMessage::ExampleMessage( - const ExampleMessage& x) -{ - m_index = x.m_index; - m_ownershipStrength = x.m_ownershipStrength; - m_message = x.m_message; -} - -ExampleMessage::ExampleMessage( - ExampleMessage&& x) noexcept -{ - m_index = x.m_index; - m_ownershipStrength = x.m_ownershipStrength; - m_message = std::move(x.m_message); -} - -ExampleMessage& ExampleMessage::operator =( - const ExampleMessage& x) -{ - - m_index = x.m_index; - m_ownershipStrength = x.m_ownershipStrength; - m_message = x.m_message; - return *this; -} - -ExampleMessage& ExampleMessage::operator =( - ExampleMessage&& x) noexcept -{ - - m_index = x.m_index; - m_ownershipStrength = x.m_ownershipStrength; - m_message = std::move(x.m_message); - return *this; -} - -bool ExampleMessage::operator ==( - const ExampleMessage& x) const -{ - return (m_index == x.m_index && - m_ownershipStrength == x.m_ownershipStrength && - m_message == x.m_message); -} - -bool ExampleMessage::operator !=( - const ExampleMessage& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void ExampleMessage::index( - uint32_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint32_t ExampleMessage::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint32_t& ExampleMessage::index() -{ - return m_index; -} - - -/*! - * @brief This function sets a value in member ownershipStrength - * @param _ownershipStrength New value for member ownershipStrength - */ -void ExampleMessage::ownershipStrength( - uint32_t _ownershipStrength) -{ - m_ownershipStrength = _ownershipStrength; -} - -/*! - * @brief This function returns the value of member ownershipStrength - * @return Value of member ownershipStrength - */ -uint32_t ExampleMessage::ownershipStrength() const -{ - return m_ownershipStrength; -} - -/*! - * @brief This function returns a reference to member ownershipStrength - * @return Reference to member ownershipStrength - */ -uint32_t& ExampleMessage::ownershipStrength() -{ - return m_ownershipStrength; -} - - -/*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ -void ExampleMessage::message( - const std::string& _message) -{ - m_message = _message; -} - -/*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ -void ExampleMessage::message( - std::string&& _message) -{ - m_message = std::move(_message); -} - -/*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ -const std::string& ExampleMessage::message() const -{ - return m_message; -} - -/*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ -std::string& ExampleMessage::message() -{ - return m_message; -} - - -// Include auxiliary functions like for serializing/deserializing. -#include "OwnershipStrengthCdrAux.ipp" - -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/OwnershipStrengthQoSExample/OwnershipStrength.h b/examples/cpp/dds/OwnershipStrengthQoSExample/OwnershipStrength.hpp similarity index 65% rename from examples/cpp/dds/OwnershipStrengthQoSExample/OwnershipStrength.h rename to examples/cpp/dds/OwnershipStrengthQoSExample/OwnershipStrength.hpp index 2ce1eddefa3..7b2459abfca 100644 --- a/examples/cpp/dds/OwnershipStrengthQoSExample/OwnershipStrength.h +++ b/examples/cpp/dds/OwnershipStrengthQoSExample/OwnershipStrength.hpp @@ -13,32 +13,19 @@ // limitations under the License. /*! - * @file OwnershipStrength.h + * @file OwnershipStrength.hpp * This header file contains the declaration of the described types in the IDL file. * * This file was generated by the tool fastddsgen. */ -#include -#include "OwnershipStrengthv1.h" +#ifndef _FAST_DDS_GENERATED_OWNERSHIPSTRENGTH_HPP_ +#define _FAST_DDS_GENERATED_OWNERSHIPSTRENGTH_HPP_ -#if FASTCDR_VERSION_MAJOR > 1 - -#ifndef _FAST_DDS_GENERATED_OWNERSHIPSTRENGTH_H_ -#define _FAST_DDS_GENERATED_OWNERSHIPSTRENGTH_H_ - -#include -#include #include -#include #include -#include - +#include #include -#include -#include - - #if defined(_WIN32) #if defined(EPROSIMA_USER_DLL_EXPORT) @@ -64,17 +51,6 @@ #define OWNERSHIPSTRENGTH_DllAPI #endif // _WIN32 -namespace eprosima { -namespace fastcdr { -class Cdr; -class CdrSizeCalculator; -} // namespace fastcdr -} // namespace eprosima - - - - - /*! * @brief This class represents the structure ExampleMessage defined by the user in the IDL file. * @ingroup OwnershipStrength @@ -86,73 +62,124 @@ class ExampleMessage /*! * @brief Default constructor. */ - eProsima_user_DllExport ExampleMessage(); + eProsima_user_DllExport ExampleMessage() + { + } /*! * @brief Default destructor. */ - eProsima_user_DllExport ~ExampleMessage(); + eProsima_user_DllExport ~ExampleMessage() + { + } /*! * @brief Copy constructor. * @param x Reference to the object ExampleMessage that will be copied. */ eProsima_user_DllExport ExampleMessage( - const ExampleMessage& x); + const ExampleMessage& x) + { + m_index = x.m_index; + + m_ownershipStrength = x.m_ownershipStrength; + + m_message = x.m_message; + + } /*! * @brief Move constructor. * @param x Reference to the object ExampleMessage that will be copied. */ eProsima_user_DllExport ExampleMessage( - ExampleMessage&& x) noexcept; + ExampleMessage&& x) noexcept + { + m_index = x.m_index; + m_ownershipStrength = x.m_ownershipStrength; + m_message = std::move(x.m_message); + } /*! * @brief Copy assignment. * @param x Reference to the object ExampleMessage that will be copied. */ eProsima_user_DllExport ExampleMessage& operator =( - const ExampleMessage& x); + const ExampleMessage& x) + { + + m_index = x.m_index; + + m_ownershipStrength = x.m_ownershipStrength; + + m_message = x.m_message; + + return *this; + } /*! * @brief Move assignment. * @param x Reference to the object ExampleMessage that will be copied. */ eProsima_user_DllExport ExampleMessage& operator =( - ExampleMessage&& x) noexcept; + ExampleMessage&& x) noexcept + { + + m_index = x.m_index; + m_ownershipStrength = x.m_ownershipStrength; + m_message = std::move(x.m_message); + return *this; + } /*! * @brief Comparison operator. * @param x ExampleMessage object to compare. */ eProsima_user_DllExport bool operator ==( - const ExampleMessage& x) const; + const ExampleMessage& x) const + { + return (m_index == x.m_index && + m_ownershipStrength == x.m_ownershipStrength && + m_message == x.m_message); + } /*! * @brief Comparison operator. * @param x ExampleMessage object to compare. */ eProsima_user_DllExport bool operator !=( - const ExampleMessage& x) const; + const ExampleMessage& x) const + { + return !(*this == x); + } /*! * @brief This function sets a value in member index * @param _index New value for member index */ eProsima_user_DllExport void index( - uint32_t _index); + uint32_t _index) + { + m_index = _index; + } /*! * @brief This function returns the value of member index * @return Value of member index */ - eProsima_user_DllExport uint32_t index() const; + eProsima_user_DllExport uint32_t index() const + { + return m_index; + } /*! * @brief This function returns a reference to member index * @return Reference to member index */ - eProsima_user_DllExport uint32_t& index(); + eProsima_user_DllExport uint32_t& index() + { + return m_index; + } /*! @@ -160,19 +187,28 @@ class ExampleMessage * @param _ownershipStrength New value for member ownershipStrength */ eProsima_user_DllExport void ownershipStrength( - uint32_t _ownershipStrength); + uint32_t _ownershipStrength) + { + m_ownershipStrength = _ownershipStrength; + } /*! * @brief This function returns the value of member ownershipStrength * @return Value of member ownershipStrength */ - eProsima_user_DllExport uint32_t ownershipStrength() const; + eProsima_user_DllExport uint32_t ownershipStrength() const + { + return m_ownershipStrength; + } /*! * @brief This function returns a reference to member ownershipStrength * @return Reference to member ownershipStrength */ - eProsima_user_DllExport uint32_t& ownershipStrength(); + eProsima_user_DllExport uint32_t& ownershipStrength() + { + return m_ownershipStrength; + } /*! @@ -180,26 +216,40 @@ class ExampleMessage * @param _message New value to be copied in member message */ eProsima_user_DllExport void message( - const std::string& _message); + const std::string& _message) + { + m_message = _message; + } /*! * @brief This function moves the value in member message * @param _message New value to be moved in member message */ eProsima_user_DllExport void message( - std::string&& _message); + std::string&& _message) + { + m_message = std::move(_message); + } /*! * @brief This function returns a constant reference to member message * @return Constant reference to member message */ - eProsima_user_DllExport const std::string& message() const; + eProsima_user_DllExport const std::string& message() const + { + return m_message; + } /*! * @brief This function returns a reference to member message * @return Reference to member message */ - eProsima_user_DllExport std::string& message(); + eProsima_user_DllExport std::string& message() + { + return m_message; + } + + private: @@ -209,8 +259,6 @@ class ExampleMessage }; -#endif // _FAST_DDS_GENERATED_OWNERSHIPSTRENGTH_H_ - +#endif // _FAST_DDS_GENERATED_OWNERSHIPSTRENGTH_HPP_ -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/OwnershipStrengthQoSExample/OwnershipStrengthCdrAux.hpp b/examples/cpp/dds/OwnershipStrengthQoSExample/OwnershipStrengthCdrAux.hpp index d0eed4b0f5f..b13a1e7de3e 100644 --- a/examples/cpp/dds/OwnershipStrengthQoSExample/OwnershipStrengthCdrAux.hpp +++ b/examples/cpp/dds/OwnershipStrengthQoSExample/OwnershipStrengthCdrAux.hpp @@ -22,7 +22,7 @@ #ifndef _FAST_DDS_GENERATED_OWNERSHIPSTRENGTHCDRAUX_HPP_ #define _FAST_DDS_GENERATED_OWNERSHIPSTRENGTHCDRAUX_HPP_ -#include "OwnershipStrength.h" +#include "OwnershipStrength.hpp" constexpr uint32_t ExampleMessage_max_cdr_typesize {272UL}; constexpr uint32_t ExampleMessage_max_key_cdr_typesize {0UL}; @@ -34,8 +34,6 @@ namespace fastcdr { class Cdr; class CdrSizeCalculator; - - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const ExampleMessage& data); diff --git a/examples/cpp/dds/OwnershipStrengthQoSExample/OwnershipStrengthCdrAux.ipp b/examples/cpp/dds/OwnershipStrengthQoSExample/OwnershipStrengthCdrAux.ipp index 5adb5bdd0a1..d4beca7dd09 100644 --- a/examples/cpp/dds/OwnershipStrengthQoSExample/OwnershipStrengthCdrAux.ipp +++ b/examples/cpp/dds/OwnershipStrengthQoSExample/OwnershipStrengthCdrAux.ipp @@ -34,8 +34,6 @@ using namespace eprosima::fastcdr::exception; namespace eprosima { namespace fastcdr { - - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, diff --git a/examples/cpp/dds/OwnershipStrengthQoSExample/OwnershipStrengthPubSubMain.cxx b/examples/cpp/dds/OwnershipStrengthQoSExample/OwnershipStrengthPubSubMain.cxx index 454d3b1dca3..73749ab9a04 100644 --- a/examples/cpp/dds/OwnershipStrengthQoSExample/OwnershipStrengthPubSubMain.cxx +++ b/examples/cpp/dds/OwnershipStrengthQoSExample/OwnershipStrengthPubSubMain.cxx @@ -19,16 +19,16 @@ * This file was generated by the tool fastcdrgen. */ -#include "OwnershipStrengthPublisher.h" -#include "OwnershipStrengthSubscriber.h" +#include +#include -#include -#include -#include +#include "OwnershipStrengthPublisher.h" +#include "OwnershipStrengthSubscriber.h" using namespace eprosima; using namespace eprosima::fastrtps; +using namespace eprosima::fastdds::dds; int main(int argc, char** argv) { diff --git a/examples/cpp/dds/OwnershipStrengthQoSExample/OwnershipStrengthPubSubTypes.cxx b/examples/cpp/dds/OwnershipStrengthQoSExample/OwnershipStrengthPubSubTypes.cxx index 279bcd498c4..ea56a8eeb1a 100644 --- a/examples/cpp/dds/OwnershipStrengthQoSExample/OwnershipStrengthPubSubTypes.cxx +++ b/examples/cpp/dds/OwnershipStrengthQoSExample/OwnershipStrengthPubSubTypes.cxx @@ -19,18 +19,18 @@ * This file was generated by the tool fastddsgen. */ +#include "OwnershipStrengthPubSubTypes.h" +#include #include -#include "OwnershipStrengthPubSubTypes.h" #include "OwnershipStrengthCdrAux.hpp" +#include "OwnershipStrengthTypeObjectSupport.hpp" using SerializedPayload_t = eprosima::fastrtps::rtps::SerializedPayload_t; using InstanceHandle_t = eprosima::fastrtps::rtps::InstanceHandle_t; using DataRepresentationId_t = eprosima::fastdds::dds::DataRepresentationId_t; - - ExampleMessagePubSubType::ExampleMessagePubSubType() { setName("ExampleMessage"); @@ -219,3 +219,11 @@ bool ExampleMessagePubSubType::getKey( return true; } +void ExampleMessagePubSubType::register_type_object_representation() const +{ + register_OwnershipStrength_type_objects(); +} + + +// Include auxiliary functions like for serializing/deserializing. +#include "OwnershipStrengthCdrAux.ipp" diff --git a/examples/cpp/dds/OwnershipStrengthQoSExample/OwnershipStrengthPubSubTypes.h b/examples/cpp/dds/OwnershipStrengthQoSExample/OwnershipStrengthPubSubTypes.h index 0ab6652c4ee..02d1733e97d 100644 --- a/examples/cpp/dds/OwnershipStrengthQoSExample/OwnershipStrengthPubSubTypes.h +++ b/examples/cpp/dds/OwnershipStrengthQoSExample/OwnershipStrengthPubSubTypes.h @@ -27,9 +27,9 @@ #include #include #include -#include +#include -#include "OwnershipStrength.h" +#include "OwnershipStrength.hpp" #if !defined(GEN_API_VER) || (GEN_API_VER != 2) @@ -38,8 +38,6 @@ #endif // GEN_API_VER - - /*! * @brief This class represents the TopicDataType of the type ExampleMessage defined by the user in the IDL file. * @ingroup OwnershipStrength @@ -90,6 +88,9 @@ class ExampleMessagePubSubType : public eprosima::fastdds::dds::TopicDataType eProsima_user_DllExport void deleteData( void* data) override; + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + #ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED eProsima_user_DllExport inline bool is_bounded() const override { diff --git a/examples/cpp/dds/OwnershipStrengthQoSExample/OwnershipStrengthSubscriber.cxx b/examples/cpp/dds/OwnershipStrengthQoSExample/OwnershipStrengthSubscriber.cxx index 32fa0d9193d..ca8ae3cedb9 100644 --- a/examples/cpp/dds/OwnershipStrengthQoSExample/OwnershipStrengthSubscriber.cxx +++ b/examples/cpp/dds/OwnershipStrengthQoSExample/OwnershipStrengthSubscriber.cxx @@ -90,7 +90,7 @@ bool OwnershipStrengthSubscriber::init() //Create DataReader DataReaderQos rqos; - rqos.reliability().kind = eprosima::fastrtps::RELIABLE_RELIABILITY_QOS; + rqos.reliability().kind = ReliabilityQosPolicyKind::RELIABLE_RELIABILITY_QOS; reader_ = subscriber_->create_datareader(topic_, rqos, &m_listener); @@ -174,7 +174,7 @@ void OwnershipStrengthSubscriber::SubListener::on_data_available( { SampleInfo info; ExampleMessage st; - if (reader->take_next_sample(&st, &info) == ReturnCode_t::RETCODE_OK) + if (reader->take_next_sample(&st, &info) == RETCODE_OK) { if (info.valid_data && m_hierarchy.IsMessageStrong(st, info)) { diff --git a/examples/cpp/dds/OwnershipStrengthQoSExample/OwnershipStrengthTypeObjectSupport.cxx b/examples/cpp/dds/OwnershipStrengthQoSExample/OwnershipStrengthTypeObjectSupport.cxx new file mode 100644 index 00000000000..2af3cdeeeff --- /dev/null +++ b/examples/cpp/dds/OwnershipStrengthQoSExample/OwnershipStrengthTypeObjectSupport.cxx @@ -0,0 +1,312 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file OwnershipStrengthTypeObjectSupport.cxx + * Source file containing the implementation to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#include "OwnershipStrengthTypeObjectSupport.hpp" + +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include + +#include "OwnershipStrength.hpp" + + +using namespace eprosima::fastdds::dds::xtypes; + +void register_OwnershipStrength_type_objects() +{ + static std::once_flag once_flag; + std::call_once(once_flag, []() + { + register_ExampleMessage_type_identifier(); + + }); +} + +void register_ExampleMessage_type_identifier() +{ + { + StructTypeFlag struct_flags_ExampleMessage = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::NOT_APPLIED, + false, false); + ReturnCode_t return_code_ExampleMessage; + TypeIdentifierPair type_ids_ExampleMessage; + QualifiedTypeName type_name_ExampleMessage = "ExampleMessage"; + eprosima::fastcdr::optional type_ann_builtin_ExampleMessage; + eprosima::fastcdr::optional ann_custom_ExampleMessage; + CompleteTypeDetail detail_ExampleMessage = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_ExampleMessage, ann_custom_ExampleMessage, type_name_ExampleMessage.to_string()); + CompleteStructHeader header_ExampleMessage; + header_ExampleMessage = TypeObjectUtils::build_complete_struct_header(TypeIdentifier(), detail_ExampleMessage); + CompleteStructMemberSeq member_seq_ExampleMessage; + { + return_code_ExampleMessage = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_uint32_t", type_ids_ExampleMessage); + + if (return_code_ExampleMessage != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "index Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_index = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_index; + MemberId member_id_index = 0x00000000; + if (EK_COMPLETE == type_ids_ExampleMessage.type_identifier1()._d() || TK_NONE == type_ids_ExampleMessage.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ExampleMessage.type_identifier1()._d() && + EK_COMPLETE == type_ids_ExampleMessage.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ExampleMessage.type_identifier1()._d() && + EK_COMPLETE == type_ids_ExampleMessage.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ExampleMessage.type_identifier1()._d() && + EK_COMPLETE == type_ids_ExampleMessage.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ExampleMessage.type_identifier1()._d() && + EK_COMPLETE == type_ids_ExampleMessage.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ExampleMessage.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ExampleMessage.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ExampleMessage.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ExampleMessage.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ExampleMessage.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ExampleMessage.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_ExampleMessage.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ExampleMessage.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ExampleMessage.type_identifier2()._d() && + EK_COMPLETE == type_ids_ExampleMessage.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ExampleMessage.type_identifier2()._d() && + EK_COMPLETE == type_ids_ExampleMessage.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ExampleMessage.type_identifier2()._d() && + EK_COMPLETE == type_ids_ExampleMessage.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ExampleMessage.type_identifier2()._d() && + EK_COMPLETE == type_ids_ExampleMessage.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ExampleMessage.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ExampleMessage.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ExampleMessage.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ExampleMessage.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ExampleMessage.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ExampleMessage.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_ExampleMessage.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure index member TypeIdentifier inconsistent."); + return; + } + MemberName name_index = "index"; + eprosima::fastcdr::optional member_ann_builtin_index; + ann_custom_ExampleMessage.reset(); + CompleteMemberDetail detail_index = TypeObjectUtils::build_complete_member_detail(name_index, member_ann_builtin_index, ann_custom_ExampleMessage); + CompleteStructMember member_index = TypeObjectUtils::build_complete_struct_member(common_index, detail_index); + TypeObjectUtils::add_complete_struct_member(member_seq_ExampleMessage, member_index); + } + { + return_code_ExampleMessage = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_uint32_t", type_ids_ExampleMessage); + + if (return_code_ExampleMessage != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "ownershipStrength Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_ownershipStrength = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_ownershipStrength; + MemberId member_id_ownershipStrength = 0x00000001; + if (EK_COMPLETE == type_ids_ExampleMessage.type_identifier1()._d() || TK_NONE == type_ids_ExampleMessage.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ExampleMessage.type_identifier1()._d() && + EK_COMPLETE == type_ids_ExampleMessage.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ExampleMessage.type_identifier1()._d() && + EK_COMPLETE == type_ids_ExampleMessage.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ExampleMessage.type_identifier1()._d() && + EK_COMPLETE == type_ids_ExampleMessage.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ExampleMessage.type_identifier1()._d() && + EK_COMPLETE == type_ids_ExampleMessage.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ExampleMessage.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ExampleMessage.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ExampleMessage.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ExampleMessage.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ExampleMessage.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ExampleMessage.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_ownershipStrength = TypeObjectUtils::build_common_struct_member(member_id_ownershipStrength, member_flags_ownershipStrength, type_ids_ExampleMessage.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ExampleMessage.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ExampleMessage.type_identifier2()._d() && + EK_COMPLETE == type_ids_ExampleMessage.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ExampleMessage.type_identifier2()._d() && + EK_COMPLETE == type_ids_ExampleMessage.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ExampleMessage.type_identifier2()._d() && + EK_COMPLETE == type_ids_ExampleMessage.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ExampleMessage.type_identifier2()._d() && + EK_COMPLETE == type_ids_ExampleMessage.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ExampleMessage.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ExampleMessage.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ExampleMessage.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ExampleMessage.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ExampleMessage.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ExampleMessage.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_ownershipStrength = TypeObjectUtils::build_common_struct_member(member_id_ownershipStrength, member_flags_ownershipStrength, type_ids_ExampleMessage.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure ownershipStrength member TypeIdentifier inconsistent."); + return; + } + MemberName name_ownershipStrength = "ownershipStrength"; + eprosima::fastcdr::optional member_ann_builtin_ownershipStrength; + ann_custom_ExampleMessage.reset(); + CompleteMemberDetail detail_ownershipStrength = TypeObjectUtils::build_complete_member_detail(name_ownershipStrength, member_ann_builtin_ownershipStrength, ann_custom_ExampleMessage); + CompleteStructMember member_ownershipStrength = TypeObjectUtils::build_complete_struct_member(common_ownershipStrength, detail_ownershipStrength); + TypeObjectUtils::add_complete_struct_member(member_seq_ExampleMessage, member_ownershipStrength); + } + { + return_code_ExampleMessage = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_string_unbounded", type_ids_ExampleMessage); + + if (return_code_ExampleMessage != eprosima::fastdds::dds::RETCODE_OK) + { + std::string type_id_kind_anonymous_string_unbounded("TI_STRING8_SMALL"); + if (type_id_kind_anonymous_string_unbounded == "TI_STRING8_SMALL") + { + SBound bound = 0; + StringSTypeDefn string_sdefn = TypeObjectUtils::build_string_s_type_defn(bound); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_string_type_identifier(string_sdefn, + "anonymous_string_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else if (type_id_kind_anonymous_string_unbounded == "TI_STRING8_LARGE") + { + LBound bound = 255; + StringLTypeDefn string_ldefn = TypeObjectUtils::build_string_l_type_defn(bound); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_string_type_identifier(string_ldefn, + "anonymous_string_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded: Unknown String kind."); + return; + } + return_code_ExampleMessage = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_string_unbounded", type_ids_ExampleMessage); + if (return_code_ExampleMessage != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded: Given String TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_message = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_message; + MemberId member_id_message = 0x00000002; + if (EK_COMPLETE == type_ids_ExampleMessage.type_identifier1()._d() || TK_NONE == type_ids_ExampleMessage.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ExampleMessage.type_identifier1()._d() && + EK_COMPLETE == type_ids_ExampleMessage.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ExampleMessage.type_identifier1()._d() && + EK_COMPLETE == type_ids_ExampleMessage.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ExampleMessage.type_identifier1()._d() && + EK_COMPLETE == type_ids_ExampleMessage.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ExampleMessage.type_identifier1()._d() && + EK_COMPLETE == type_ids_ExampleMessage.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ExampleMessage.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ExampleMessage.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ExampleMessage.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ExampleMessage.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ExampleMessage.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ExampleMessage.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_message = TypeObjectUtils::build_common_struct_member(member_id_message, member_flags_message, type_ids_ExampleMessage.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ExampleMessage.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ExampleMessage.type_identifier2()._d() && + EK_COMPLETE == type_ids_ExampleMessage.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ExampleMessage.type_identifier2()._d() && + EK_COMPLETE == type_ids_ExampleMessage.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ExampleMessage.type_identifier2()._d() && + EK_COMPLETE == type_ids_ExampleMessage.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ExampleMessage.type_identifier2()._d() && + EK_COMPLETE == type_ids_ExampleMessage.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ExampleMessage.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ExampleMessage.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ExampleMessage.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ExampleMessage.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ExampleMessage.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ExampleMessage.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_message = TypeObjectUtils::build_common_struct_member(member_id_message, member_flags_message, type_ids_ExampleMessage.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure message member TypeIdentifier inconsistent."); + return; + } + MemberName name_message = "message"; + eprosima::fastcdr::optional member_ann_builtin_message; + ann_custom_ExampleMessage.reset(); + CompleteMemberDetail detail_message = TypeObjectUtils::build_complete_member_detail(name_message, member_ann_builtin_message, ann_custom_ExampleMessage); + CompleteStructMember member_message = TypeObjectUtils::build_complete_struct_member(common_message, detail_message); + TypeObjectUtils::add_complete_struct_member(member_seq_ExampleMessage, member_message); + } + CompleteStructType struct_type_ExampleMessage = TypeObjectUtils::build_complete_struct_type(struct_flags_ExampleMessage, header_ExampleMessage, member_seq_ExampleMessage); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_struct_type_object(struct_type_ExampleMessage, type_name_ExampleMessage.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "ExampleMessage already registered in TypeObjectRegistry for a different type."); + } + return_code_ExampleMessage = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "ExampleMessage", type_ids_ExampleMessage); + if (return_code_ExampleMessage != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "ExampleMessage: Given Struct TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } +} + diff --git a/examples/cpp/dds/OwnershipStrengthQoSExample/OwnershipStrengthTypeObjectSupport.hpp b/examples/cpp/dds/OwnershipStrengthQoSExample/OwnershipStrengthTypeObjectSupport.hpp new file mode 100644 index 00000000000..e16f4b42995 --- /dev/null +++ b/examples/cpp/dds/OwnershipStrengthQoSExample/OwnershipStrengthTypeObjectSupport.hpp @@ -0,0 +1,54 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file OwnershipStrengthTypeObjectSupport.hpp + * Header file containing the API required to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#ifndef _FAST_DDS_GENERATED_OWNERSHIPSTRENGTH_TYPE_OBJECT_SUPPORT_HPP_ +#define _FAST_DDS_GENERATED_OWNERSHIPSTRENGTH_TYPE_OBJECT_SUPPORT_HPP_ + + +#if defined(_WIN32) +#if defined(EPROSIMA_USER_DLL_EXPORT) +#define eProsima_user_DllExport __declspec( dllexport ) +#else +#define eProsima_user_DllExport +#endif // EPROSIMA_USER_DLL_EXPORT +#else +#define eProsima_user_DllExport +#endif // _WIN32 + +/** + * @brief Register every TypeObject representation defined in the IDL file in Fast DDS TypeObjectRegistry. + */ +eProsima_user_DllExport void register_OwnershipStrength_type_objects(); + +#ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +/** + * @brief Register ExampleMessage related TypeIdentifier. + * Fully-descriptive TypeIdentifiers are directly registered. + * Hash TypeIdentifiers require to fill the TypeObject information and hash it, consequently, the TypeObject is + * indirectly registered as well. + */ +void register_ExampleMessage_type_identifier(); + + +#endif // DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +#endif // _FAST_DDS_GENERATED_OWNERSHIPSTRENGTH_TYPE_OBJECT_SUPPORT_HPP_ diff --git a/examples/cpp/dds/OwnershipStrengthQoSExample/OwnershipStrengthv1.cxx b/examples/cpp/dds/OwnershipStrengthQoSExample/OwnershipStrengthv1.cxx deleted file mode 100644 index b98d38c3f26..00000000000 --- a/examples/cpp/dds/OwnershipStrengthQoSExample/OwnershipStrengthv1.cxx +++ /dev/null @@ -1,339 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file OwnershipStrength.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "OwnershipStrength.h" - -#if FASTCDR_VERSION_MAJOR == 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - -namespace helper { namespace internal { - -enum class Size { - UInt8, - UInt16, - UInt32, - UInt64, -}; - -constexpr Size get_size(int s) { - return (s <= 8 ) ? Size::UInt8: - (s <= 16) ? Size::UInt16: - (s <= 32) ? Size::UInt32: Size::UInt64; -} - -template -struct FindTypeH; - -template<> -struct FindTypeH { - using type = std::uint8_t; -}; - -template<> -struct FindTypeH { - using type = std::uint16_t; -}; - -template<> -struct FindTypeH { - using type = std::uint32_t; -}; - -template<> -struct FindTypeH { - using type = std::uint64_t; -}; -} - -template -struct FindType { - using type = typename internal::FindTypeH::type; -}; -} - -#define ExampleMessage_max_cdr_typesize 272ULL; - - - - -ExampleMessage::ExampleMessage() -{ - // unsigned long m_index - m_index = 0; - // unsigned long m_ownershipStrength - m_ownershipStrength = 0; - // /type_d() m_message - - -} - -ExampleMessage::~ExampleMessage() -{ -} - -ExampleMessage::ExampleMessage( - const ExampleMessage& x) -{ - m_index = x.m_index; - - - m_ownershipStrength = x.m_ownershipStrength; - - - m_message = x.m_message; - -} - -ExampleMessage::ExampleMessage( - ExampleMessage&& x) noexcept -{ - m_index = x.m_index; - - - m_ownershipStrength = x.m_ownershipStrength; - - - m_message = std::move(x.m_message); - -} - -ExampleMessage& ExampleMessage::operator =( - const ExampleMessage& x) -{ - m_index = x.m_index; - - - m_ownershipStrength = x.m_ownershipStrength; - - - m_message = x.m_message; - - return *this; -} - -ExampleMessage& ExampleMessage::operator =( - ExampleMessage&& x) noexcept -{ - m_index = x.m_index; - - - m_ownershipStrength = x.m_ownershipStrength; - - - m_message = std::move(x.m_message); - - return *this; -} - -bool ExampleMessage::operator ==( - const ExampleMessage& x) const -{ - return (m_index == x.m_index && - m_ownershipStrength == x.m_ownershipStrength && - m_message == x.m_message); -} - -bool ExampleMessage::operator !=( - const ExampleMessage& x) const -{ - return !(*this == x); -} - -size_t ExampleMessage::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return ExampleMessage_max_cdr_typesize; -} - -size_t ExampleMessage::getCdrSerializedSize( - const ExampleMessage& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + data.message().size() + 1; - - - return current_alignment - initial_alignment; -} - - -void ExampleMessage::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_index; - - scdr << m_ownershipStrength; - - scdr << m_message.c_str(); - -} - -void ExampleMessage::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_index; - - - - dcdr >> m_ownershipStrength; - - - - dcdr >> m_message; - - -} - - -bool ExampleMessage::isKeyDefined() -{ - return false; -} - -void ExampleMessage::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void ExampleMessage::index( - uint32_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint32_t ExampleMessage::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint32_t& ExampleMessage::index() -{ - return m_index; -} - - -/*! - * @brief This function sets a value in member ownershipStrength - * @param _ownershipStrength New value for member ownershipStrength - */ -void ExampleMessage::ownershipStrength( - uint32_t _ownershipStrength) -{ - m_ownershipStrength = _ownershipStrength; -} - -/*! - * @brief This function returns the value of member ownershipStrength - * @return Value of member ownershipStrength - */ -uint32_t ExampleMessage::ownershipStrength() const -{ - return m_ownershipStrength; -} - -/*! - * @brief This function returns a reference to member ownershipStrength - * @return Reference to member ownershipStrength - */ -uint32_t& ExampleMessage::ownershipStrength() -{ - return m_ownershipStrength; -} - - -/*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ -void ExampleMessage::message( - const std::string& _message) -{ - m_message = _message; -} - -/*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ -void ExampleMessage::message( - std::string&& _message) -{ - m_message = std::move(_message); -} - -/*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ -const std::string& ExampleMessage::message() const -{ - return m_message; -} - -/*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ -std::string& ExampleMessage::message() -{ - return m_message; -} - - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/OwnershipStrengthQoSExample/OwnershipStrengthv1.h b/examples/cpp/dds/OwnershipStrengthQoSExample/OwnershipStrengthv1.h deleted file mode 100644 index ce63f631f87..00000000000 --- a/examples/cpp/dds/OwnershipStrengthQoSExample/OwnershipStrengthv1.h +++ /dev/null @@ -1,265 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file OwnershipStrength.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#include - -#if FASTCDR_VERSION_MAJOR == 1 - -#ifndef _FAST_DDS_GENERATED_OWNERSHIPSTRENGTH_H_ -#define _FAST_DDS_GENERATED_OWNERSHIPSTRENGTH_H_ - - -#include - -#include -#include -#include -#include -#include -#include -#include - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define eProsima_user_DllExport -#endif // _WIN32 - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(OWNERSHIPSTRENGTH_SOURCE) -#define OWNERSHIPSTRENGTH_DllAPI __declspec( dllexport ) -#else -#define OWNERSHIPSTRENGTH_DllAPI __declspec( dllimport ) -#endif // OWNERSHIPSTRENGTH_SOURCE -#else -#define OWNERSHIPSTRENGTH_DllAPI -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define OWNERSHIPSTRENGTH_DllAPI -#endif // _WIN32 - -namespace eprosima { -namespace fastcdr { -class Cdr; -} // namespace fastcdr -} // namespace eprosima - - - - - -/*! - * @brief This class represents the structure ExampleMessage defined by the user in the IDL file. - * @ingroup OwnershipStrength - */ -class ExampleMessage -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport ExampleMessage(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~ExampleMessage(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object ExampleMessage that will be copied. - */ - eProsima_user_DllExport ExampleMessage( - const ExampleMessage& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object ExampleMessage that will be copied. - */ - eProsima_user_DllExport ExampleMessage( - ExampleMessage&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object ExampleMessage that will be copied. - */ - eProsima_user_DllExport ExampleMessage& operator =( - const ExampleMessage& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object ExampleMessage that will be copied. - */ - eProsima_user_DllExport ExampleMessage& operator =( - ExampleMessage&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x ExampleMessage object to compare. - */ - eProsima_user_DllExport bool operator ==( - const ExampleMessage& x) const; - - /*! - * @brief Comparison operator. - * @param x ExampleMessage object to compare. - */ - eProsima_user_DllExport bool operator !=( - const ExampleMessage& x) const; - - /*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ - eProsima_user_DllExport void index( - uint32_t _index); - - /*! - * @brief This function returns the value of member index - * @return Value of member index - */ - eProsima_user_DllExport uint32_t index() const; - - /*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ - eProsima_user_DllExport uint32_t& index(); - - - /*! - * @brief This function sets a value in member ownershipStrength - * @param _ownershipStrength New value for member ownershipStrength - */ - eProsima_user_DllExport void ownershipStrength( - uint32_t _ownershipStrength); - - /*! - * @brief This function returns the value of member ownershipStrength - * @return Value of member ownershipStrength - */ - eProsima_user_DllExport uint32_t ownershipStrength() const; - - /*! - * @brief This function returns a reference to member ownershipStrength - * @return Reference to member ownershipStrength - */ - eProsima_user_DllExport uint32_t& ownershipStrength(); - - - /*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ - eProsima_user_DllExport void message( - const std::string& _message); - - /*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ - eProsima_user_DllExport void message( - std::string&& _message); - - /*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ - eProsima_user_DllExport const std::string& message() const; - - /*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ - eProsima_user_DllExport std::string& message(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const ExampleMessage& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - uint32_t m_index; - uint32_t m_ownershipStrength; - std::string m_message; - -}; - - -#endif // _FAST_DDS_GENERATED_OWNERSHIPSTRENGTH_H_ - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/RequestReplyExample/CMakeLists.txt b/examples/cpp/dds/RequestReplyExample/CMakeLists.txt index 654db9d07b6..a3efdf02707 100644 --- a/examples/cpp/dds/RequestReplyExample/CMakeLists.txt +++ b/examples/cpp/dds/RequestReplyExample/CMakeLists.txt @@ -21,8 +21,8 @@ if(NOT fastcdr_FOUND) find_package(fastcdr 2 REQUIRED) endif() -if(NOT fastrtps_FOUND) - find_package(fastrtps 2.12 REQUIRED) +if(NOT fastdds_FOUND) + find_package(fastdds 3 REQUIRED) endif() #Check C++11 @@ -36,9 +36,8 @@ endif() message(STATUS "Configuring Request-Reply example...") set(DDS_REQUEST_REPLY_EXAMPLE_COMMON_SOURCES - Calculator.cxx - Calculatorv1.cxx CalculatorPubSubTypes.cxx + CalculatorTypeObjectSupport.cxx ) set( DDS_REQUEST_REPLY_EXAMPLE_CLIENT_SOURCES CalculatorClient.cpp @@ -55,7 +54,7 @@ target_compile_definitions(DDSCalculatorClient PRIVATE $<$>,$>:__DEBUG> $<$:__INTERNALDEBUG> # Internal debug activated. ) -target_link_libraries(DDSCalculatorClient fastrtps fastcdr) +target_link_libraries(DDSCalculatorClient fastdds fastcdr) install(TARGETS DDSCalculatorClient RUNTIME DESTINATION examples/cpp/dds/RequestReplyExample/${BIN_INSTALL_DIR}) @@ -67,6 +66,6 @@ target_compile_definitions(DDSCalculatorServer PRIVATE $<$>,$>:__DEBUG> $<$:__INTERNALDEBUG> # Internal debug activated. ) -target_link_libraries(DDSCalculatorServer fastrtps fastcdr) +target_link_libraries(DDSCalculatorServer fastdds fastcdr) install(TARGETS DDSCalculatorServer RUNTIME DESTINATION examples/cpp/dds/RequestReplyExample/${BIN_INSTALL_DIR}) diff --git a/examples/cpp/dds/RequestReplyExample/Calculator.cxx b/examples/cpp/dds/RequestReplyExample/Calculator.cxx deleted file mode 100644 index 664663c6180..00000000000 --- a/examples/cpp/dds/RequestReplyExample/Calculator.cxx +++ /dev/null @@ -1,271 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file Calculator.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "Calculator.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - - - - -RequestType::RequestType() -{ -} - -RequestType::~RequestType() -{ -} - -RequestType::RequestType( - const RequestType& x) -{ - m_operation = x.m_operation; - m_x = x.m_x; - m_y = x.m_y; -} - -RequestType::RequestType( - RequestType&& x) noexcept -{ - m_operation = x.m_operation; - m_x = x.m_x; - m_y = x.m_y; -} - -RequestType& RequestType::operator =( - const RequestType& x) -{ - - m_operation = x.m_operation; - m_x = x.m_x; - m_y = x.m_y; - return *this; -} - -RequestType& RequestType::operator =( - RequestType&& x) noexcept -{ - - m_operation = x.m_operation; - m_x = x.m_x; - m_y = x.m_y; - return *this; -} - -bool RequestType::operator ==( - const RequestType& x) const -{ - return (m_operation == x.m_operation && - m_x == x.m_x && - m_y == x.m_y); -} - -bool RequestType::operator !=( - const RequestType& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member operation - * @param _operation New value for member operation - */ -void RequestType::operation( - OperationType _operation) -{ - m_operation = _operation; -} - -/*! - * @brief This function returns the value of member operation - * @return Value of member operation - */ -OperationType RequestType::operation() const -{ - return m_operation; -} - -/*! - * @brief This function returns a reference to member operation - * @return Reference to member operation - */ -OperationType& RequestType::operation() -{ - return m_operation; -} - - -/*! - * @brief This function sets a value in member x - * @param _x New value for member x - */ -void RequestType::x( - int32_t _x) -{ - m_x = _x; -} - -/*! - * @brief This function returns the value of member x - * @return Value of member x - */ -int32_t RequestType::x() const -{ - return m_x; -} - -/*! - * @brief This function returns a reference to member x - * @return Reference to member x - */ -int32_t& RequestType::x() -{ - return m_x; -} - - -/*! - * @brief This function sets a value in member y - * @param _y New value for member y - */ -void RequestType::y( - int32_t _y) -{ - m_y = _y; -} - -/*! - * @brief This function returns the value of member y - * @return Value of member y - */ -int32_t RequestType::y() const -{ - return m_y; -} - -/*! - * @brief This function returns a reference to member y - * @return Reference to member y - */ -int32_t& RequestType::y() -{ - return m_y; -} - - - - -ReplyType::ReplyType() -{ -} - -ReplyType::~ReplyType() -{ -} - -ReplyType::ReplyType( - const ReplyType& x) -{ - m_z = x.m_z; -} - -ReplyType::ReplyType( - ReplyType&& x) noexcept -{ - m_z = x.m_z; -} - -ReplyType& ReplyType::operator =( - const ReplyType& x) -{ - - m_z = x.m_z; - return *this; -} - -ReplyType& ReplyType::operator =( - ReplyType&& x) noexcept -{ - - m_z = x.m_z; - return *this; -} - -bool ReplyType::operator ==( - const ReplyType& x) const -{ - return (m_z == x.m_z); -} - -bool ReplyType::operator !=( - const ReplyType& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member z - * @param _z New value for member z - */ -void ReplyType::z( - int64_t _z) -{ - m_z = _z; -} - -/*! - * @brief This function returns the value of member z - * @return Value of member z - */ -int64_t ReplyType::z() const -{ - return m_z; -} - -/*! - * @brief This function returns a reference to member z - * @return Reference to member z - */ -int64_t& ReplyType::z() -{ - return m_z; -} - - -// Include auxiliary functions like for serializing/deserializing. -#include "CalculatorCdrAux.ipp" - -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/RequestReplyExample/Calculator.h b/examples/cpp/dds/RequestReplyExample/Calculator.hpp similarity index 67% rename from examples/cpp/dds/RequestReplyExample/Calculator.h rename to examples/cpp/dds/RequestReplyExample/Calculator.hpp index 945af396175..f6404b6bfdd 100644 --- a/examples/cpp/dds/RequestReplyExample/Calculator.h +++ b/examples/cpp/dds/RequestReplyExample/Calculator.hpp @@ -13,32 +13,17 @@ // limitations under the License. /*! - * @file Calculator.h + * @file Calculator.hpp * This header file contains the declaration of the described types in the IDL file. * * This file was generated by the tool fastddsgen. */ -#include -#include "Calculatorv1.h" +#ifndef _FAST_DDS_GENERATED_CALCULATOR_HPP_ +#define _FAST_DDS_GENERATED_CALCULATOR_HPP_ -#if FASTCDR_VERSION_MAJOR > 1 - -#ifndef _FAST_DDS_GENERATED_CALCULATOR_H_ -#define _FAST_DDS_GENERATED_CALCULATOR_H_ - -#include -#include #include -#include -#include -#include - -#include -#include -#include - - +#include #if defined(_WIN32) #if defined(EPROSIMA_USER_DLL_EXPORT) @@ -64,28 +49,17 @@ #define CALCULATOR_DllAPI #endif // _WIN32 -namespace eprosima { -namespace fastcdr { -class Cdr; -class CdrSizeCalculator; -} // namespace fastcdr -} // namespace eprosima - - - /*! * @brief This class represents the enumeration OperationType defined by the user in the IDL file. * @ingroup Calculator */ -enum OperationType : uint32_t +enum class OperationType : uint32_t { ADDITION, SUBTRACTION, MULTIPLICATION, DIVISION }; - - /*! * @brief This class represents the structure RequestType defined by the user in the IDL file. * @ingroup Calculator @@ -97,73 +71,124 @@ class RequestType /*! * @brief Default constructor. */ - eProsima_user_DllExport RequestType(); + eProsima_user_DllExport RequestType() + { + } /*! * @brief Default destructor. */ - eProsima_user_DllExport ~RequestType(); + eProsima_user_DllExport ~RequestType() + { + } /*! * @brief Copy constructor. * @param x Reference to the object RequestType that will be copied. */ eProsima_user_DllExport RequestType( - const RequestType& x); + const RequestType& x) + { + m_operation = x.m_operation; + + m_x = x.m_x; + + m_y = x.m_y; + + } /*! * @brief Move constructor. * @param x Reference to the object RequestType that will be copied. */ eProsima_user_DllExport RequestType( - RequestType&& x) noexcept; + RequestType&& x) noexcept + { + m_operation = x.m_operation; + m_x = x.m_x; + m_y = x.m_y; + } /*! * @brief Copy assignment. * @param x Reference to the object RequestType that will be copied. */ eProsima_user_DllExport RequestType& operator =( - const RequestType& x); + const RequestType& x) + { + + m_operation = x.m_operation; + + m_x = x.m_x; + + m_y = x.m_y; + + return *this; + } /*! * @brief Move assignment. * @param x Reference to the object RequestType that will be copied. */ eProsima_user_DllExport RequestType& operator =( - RequestType&& x) noexcept; + RequestType&& x) noexcept + { + + m_operation = x.m_operation; + m_x = x.m_x; + m_y = x.m_y; + return *this; + } /*! * @brief Comparison operator. * @param x RequestType object to compare. */ eProsima_user_DllExport bool operator ==( - const RequestType& x) const; + const RequestType& x) const + { + return (m_operation == x.m_operation && + m_x == x.m_x && + m_y == x.m_y); + } /*! * @brief Comparison operator. * @param x RequestType object to compare. */ eProsima_user_DllExport bool operator !=( - const RequestType& x) const; + const RequestType& x) const + { + return !(*this == x); + } /*! * @brief This function sets a value in member operation * @param _operation New value for member operation */ eProsima_user_DllExport void operation( - OperationType _operation); + OperationType _operation) + { + m_operation = _operation; + } /*! * @brief This function returns the value of member operation * @return Value of member operation */ - eProsima_user_DllExport OperationType operation() const; + eProsima_user_DllExport OperationType operation() const + { + return m_operation; + } /*! * @brief This function returns a reference to member operation * @return Reference to member operation */ - eProsima_user_DllExport OperationType& operation(); + eProsima_user_DllExport OperationType& operation() + { + return m_operation; + } /*! @@ -171,19 +196,28 @@ class RequestType * @param _x New value for member x */ eProsima_user_DllExport void x( - int32_t _x); + int32_t _x) + { + m_x = _x; + } /*! * @brief This function returns the value of member x * @return Value of member x */ - eProsima_user_DllExport int32_t x() const; + eProsima_user_DllExport int32_t x() const + { + return m_x; + } /*! * @brief This function returns a reference to member x * @return Reference to member x */ - eProsima_user_DllExport int32_t& x(); + eProsima_user_DllExport int32_t& x() + { + return m_x; + } /*! @@ -191,29 +225,38 @@ class RequestType * @param _y New value for member y */ eProsima_user_DllExport void y( - int32_t _y); + int32_t _y) + { + m_y = _y; + } /*! * @brief This function returns the value of member y * @return Value of member y */ - eProsima_user_DllExport int32_t y() const; + eProsima_user_DllExport int32_t y() const + { + return m_y; + } /*! * @brief This function returns a reference to member y * @return Reference to member y */ - eProsima_user_DllExport int32_t& y(); + eProsima_user_DllExport int32_t& y() + { + return m_y; + } + + private: - OperationType m_operation{::ADDITION}; + OperationType m_operation{OperationType::ADDITION}; int32_t m_x{0}; int32_t m_y{0}; }; - - /*! * @brief This class represents the structure ReplyType defined by the user in the IDL file. * @ingroup Calculator @@ -225,73 +268,112 @@ class ReplyType /*! * @brief Default constructor. */ - eProsima_user_DllExport ReplyType(); + eProsima_user_DllExport ReplyType() + { + } /*! * @brief Default destructor. */ - eProsima_user_DllExport ~ReplyType(); + eProsima_user_DllExport ~ReplyType() + { + } /*! * @brief Copy constructor. * @param x Reference to the object ReplyType that will be copied. */ eProsima_user_DllExport ReplyType( - const ReplyType& x); + const ReplyType& x) + { + m_z = x.m_z; + + } /*! * @brief Move constructor. * @param x Reference to the object ReplyType that will be copied. */ eProsima_user_DllExport ReplyType( - ReplyType&& x) noexcept; + ReplyType&& x) noexcept + { + m_z = x.m_z; + } /*! * @brief Copy assignment. * @param x Reference to the object ReplyType that will be copied. */ eProsima_user_DllExport ReplyType& operator =( - const ReplyType& x); + const ReplyType& x) + { + + m_z = x.m_z; + + return *this; + } /*! * @brief Move assignment. * @param x Reference to the object ReplyType that will be copied. */ eProsima_user_DllExport ReplyType& operator =( - ReplyType&& x) noexcept; + ReplyType&& x) noexcept + { + + m_z = x.m_z; + return *this; + } /*! * @brief Comparison operator. * @param x ReplyType object to compare. */ eProsima_user_DllExport bool operator ==( - const ReplyType& x) const; + const ReplyType& x) const + { + return (m_z == x.m_z); + } /*! * @brief Comparison operator. * @param x ReplyType object to compare. */ eProsima_user_DllExport bool operator !=( - const ReplyType& x) const; + const ReplyType& x) const + { + return !(*this == x); + } /*! * @brief This function sets a value in member z * @param _z New value for member z */ eProsima_user_DllExport void z( - int64_t _z); + int64_t _z) + { + m_z = _z; + } /*! * @brief This function returns the value of member z * @return Value of member z */ - eProsima_user_DllExport int64_t z() const; + eProsima_user_DllExport int64_t z() const + { + return m_z; + } /*! * @brief This function returns a reference to member z * @return Reference to member z */ - eProsima_user_DllExport int64_t& z(); + eProsima_user_DllExport int64_t& z() + { + return m_z; + } + + private: @@ -299,8 +381,6 @@ class ReplyType }; -#endif // _FAST_DDS_GENERATED_CALCULATOR_H_ - +#endif // _FAST_DDS_GENERATED_CALCULATOR_HPP_ -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/RequestReplyExample/CalculatorCdrAux.hpp b/examples/cpp/dds/RequestReplyExample/CalculatorCdrAux.hpp index ca610452fdb..203f46ff5ec 100644 --- a/examples/cpp/dds/RequestReplyExample/CalculatorCdrAux.hpp +++ b/examples/cpp/dds/RequestReplyExample/CalculatorCdrAux.hpp @@ -22,7 +22,7 @@ #ifndef _FAST_DDS_GENERATED_CALCULATORCDRAUX_HPP_ #define _FAST_DDS_GENERATED_CALCULATORCDRAUX_HPP_ -#include "Calculator.h" +#include "Calculator.hpp" constexpr uint32_t ReplyType_max_cdr_typesize {16UL}; constexpr uint32_t ReplyType_max_key_cdr_typesize {0UL}; @@ -37,14 +37,10 @@ namespace fastcdr { class Cdr; class CdrSizeCalculator; - - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const RequestType& data); - - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const ReplyType& data); diff --git a/examples/cpp/dds/RequestReplyExample/CalculatorCdrAux.ipp b/examples/cpp/dds/RequestReplyExample/CalculatorCdrAux.ipp index 4930387fbbd..011ade654b9 100644 --- a/examples/cpp/dds/RequestReplyExample/CalculatorCdrAux.ipp +++ b/examples/cpp/dds/RequestReplyExample/CalculatorCdrAux.ipp @@ -34,8 +34,6 @@ using namespace eprosima::fastcdr::exception; namespace eprosima { namespace fastcdr { - - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, @@ -128,8 +126,6 @@ void serialize_key( } - - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, diff --git a/examples/cpp/dds/RequestReplyExample/CalculatorClient.cpp b/examples/cpp/dds/RequestReplyExample/CalculatorClient.cpp index b5a56e12735..3c6aa796f9a 100644 --- a/examples/cpp/dds/RequestReplyExample/CalculatorClient.cpp +++ b/examples/cpp/dds/RequestReplyExample/CalculatorClient.cpp @@ -16,13 +16,14 @@ #include #include -#include #include -#include +#include #include -#include +#include #include -#include +#include +#include + #include "CalculatorPubSubTypes.h" class CalculatorClient diff --git a/examples/cpp/dds/RequestReplyExample/CalculatorPubSubTypes.cxx b/examples/cpp/dds/RequestReplyExample/CalculatorPubSubTypes.cxx index e928e28c98d..8c8a2588d31 100644 --- a/examples/cpp/dds/RequestReplyExample/CalculatorPubSubTypes.cxx +++ b/examples/cpp/dds/RequestReplyExample/CalculatorPubSubTypes.cxx @@ -19,18 +19,18 @@ * This file was generated by the tool fastddsgen. */ +#include "CalculatorPubSubTypes.h" +#include #include -#include "CalculatorPubSubTypes.h" #include "CalculatorCdrAux.hpp" +#include "CalculatorTypeObjectSupport.hpp" using SerializedPayload_t = eprosima::fastrtps::rtps::SerializedPayload_t; using InstanceHandle_t = eprosima::fastrtps::rtps::InstanceHandle_t; using DataRepresentationId_t = eprosima::fastdds::dds::DataRepresentationId_t; - - RequestTypePubSubType::RequestTypePubSubType() { setName("RequestType"); @@ -219,7 +219,10 @@ bool RequestTypePubSubType::getKey( return true; } - +void RequestTypePubSubType::register_type_object_representation() const +{ + register_Calculator_type_objects(); +} ReplyTypePubSubType::ReplyTypePubSubType() { @@ -409,3 +412,11 @@ bool ReplyTypePubSubType::getKey( return true; } +void ReplyTypePubSubType::register_type_object_representation() const +{ + register_Calculator_type_objects(); +} + + +// Include auxiliary functions like for serializing/deserializing. +#include "CalculatorCdrAux.ipp" diff --git a/examples/cpp/dds/RequestReplyExample/CalculatorPubSubTypes.h b/examples/cpp/dds/RequestReplyExample/CalculatorPubSubTypes.h index ae4b2b39e8d..eac5b5c2a6e 100644 --- a/examples/cpp/dds/RequestReplyExample/CalculatorPubSubTypes.h +++ b/examples/cpp/dds/RequestReplyExample/CalculatorPubSubTypes.h @@ -27,9 +27,9 @@ #include #include #include -#include +#include -#include "Calculator.h" +#include "Calculator.hpp" #if !defined(GEN_API_VER) || (GEN_API_VER != 2) @@ -38,8 +38,6 @@ #endif // GEN_API_VER - - /*! * @brief This class represents the TopicDataType of the type RequestType defined by the user in the IDL file. * @ingroup Calculator @@ -90,6 +88,9 @@ class RequestTypePubSubType : public eprosima::fastdds::dds::TopicDataType eProsima_user_DllExport void deleteData( void* data) override; + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + #ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED eProsima_user_DllExport inline bool is_bounded() const override { @@ -128,8 +129,6 @@ class RequestTypePubSubType : public eprosima::fastdds::dds::TopicDataType }; - - /*! * @brief This class represents the TopicDataType of the type ReplyType defined by the user in the IDL file. * @ingroup Calculator @@ -180,6 +179,9 @@ class ReplyTypePubSubType : public eprosima::fastdds::dds::TopicDataType eProsima_user_DllExport void deleteData( void* data) override; + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + #ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED eProsima_user_DllExport inline bool is_bounded() const override { diff --git a/examples/cpp/dds/RequestReplyExample/CalculatorServer.cpp b/examples/cpp/dds/RequestReplyExample/CalculatorServer.cpp index 4a9df742374..59f933e5c96 100644 --- a/examples/cpp/dds/RequestReplyExample/CalculatorServer.cpp +++ b/examples/cpp/dds/RequestReplyExample/CalculatorServer.cpp @@ -16,13 +16,14 @@ #include #include -#include #include -#include +#include #include -#include +#include #include -#include +#include +#include + #include "CalculatorPubSubTypes.h" class CalculatorServer diff --git a/examples/cpp/dds/RequestReplyExample/CalculatorTypeObjectSupport.cxx b/examples/cpp/dds/RequestReplyExample/CalculatorTypeObjectSupport.cxx new file mode 100644 index 00000000000..5d358352dc6 --- /dev/null +++ b/examples/cpp/dds/RequestReplyExample/CalculatorTypeObjectSupport.cxx @@ -0,0 +1,436 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file CalculatorTypeObjectSupport.cxx + * Source file containing the implementation to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#include "CalculatorTypeObjectSupport.hpp" + +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include + +#include "Calculator.hpp" + + +using namespace eprosima::fastdds::dds::xtypes; + +void register_Calculator_type_objects() +{ + static std::once_flag once_flag; + std::call_once(once_flag, []() + { + register_RequestType_type_identifier(); + + register_ReplyType_type_identifier(); + + }); +} + +void register_RequestType_type_identifier() +{ + { + StructTypeFlag struct_flags_RequestType = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::NOT_APPLIED, + false, false); + ReturnCode_t return_code_RequestType; + TypeIdentifierPair type_ids_RequestType; + QualifiedTypeName type_name_RequestType = "RequestType"; + eprosima::fastcdr::optional type_ann_builtin_RequestType; + eprosima::fastcdr::optional ann_custom_RequestType; + CompleteTypeDetail detail_RequestType = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_RequestType, ann_custom_RequestType, type_name_RequestType.to_string()); + CompleteStructHeader header_RequestType; + header_RequestType = TypeObjectUtils::build_complete_struct_header(TypeIdentifier(), detail_RequestType); + CompleteStructMemberSeq member_seq_RequestType; + { + return_code_RequestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "OperationType", type_ids_RequestType); + + if (return_code_RequestType != eprosima::fastdds::dds::RETCODE_OK) + { + EnumTypeFlag enum_flags_OperationType = 0; + BitBound bit_bound_OperationType = 32; + CommonEnumeratedHeader common_OperationType = TypeObjectUtils::build_common_enumerated_header(bit_bound_OperationType); + QualifiedTypeName type_name_OperationType = "OperationType"; + eprosima::fastcdr::optional type_ann_builtin_OperationType; + eprosima::fastcdr::optional ann_custom_OperationType; + CompleteTypeDetail detail_OperationType = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_OperationType, ann_custom_OperationType, type_name_OperationType.to_string()); + CompleteEnumeratedHeader header_OperationType = TypeObjectUtils::build_complete_enumerated_header(common_OperationType, detail_OperationType); + CompleteEnumeratedLiteralSeq literal_seq_OperationType; + { + EnumeratedLiteralFlag flags_ADDITION = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_ADDITION = TypeObjectUtils::build_common_enumerated_literal(0, flags_ADDITION); + eprosima::fastcdr::optional member_ann_builtin_ADDITION; + ann_custom_OperationType.reset(); + MemberName name_ADDITION = "ADDITION"; + CompleteMemberDetail detail_ADDITION = TypeObjectUtils::build_complete_member_detail(name_ADDITION, member_ann_builtin_ADDITION, ann_custom_OperationType); + CompleteEnumeratedLiteral literal_ADDITION = TypeObjectUtils::build_complete_enumerated_literal(common_ADDITION, detail_ADDITION); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_OperationType, literal_ADDITION); + } + { + EnumeratedLiteralFlag flags_SUBTRACTION = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_SUBTRACTION = TypeObjectUtils::build_common_enumerated_literal(1, flags_SUBTRACTION); + eprosima::fastcdr::optional member_ann_builtin_SUBTRACTION; + ann_custom_OperationType.reset(); + MemberName name_SUBTRACTION = "SUBTRACTION"; + CompleteMemberDetail detail_SUBTRACTION = TypeObjectUtils::build_complete_member_detail(name_SUBTRACTION, member_ann_builtin_SUBTRACTION, ann_custom_OperationType); + CompleteEnumeratedLiteral literal_SUBTRACTION = TypeObjectUtils::build_complete_enumerated_literal(common_SUBTRACTION, detail_SUBTRACTION); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_OperationType, literal_SUBTRACTION); + } + { + EnumeratedLiteralFlag flags_MULTIPLICATION = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_MULTIPLICATION = TypeObjectUtils::build_common_enumerated_literal(2, flags_MULTIPLICATION); + eprosima::fastcdr::optional member_ann_builtin_MULTIPLICATION; + ann_custom_OperationType.reset(); + MemberName name_MULTIPLICATION = "MULTIPLICATION"; + CompleteMemberDetail detail_MULTIPLICATION = TypeObjectUtils::build_complete_member_detail(name_MULTIPLICATION, member_ann_builtin_MULTIPLICATION, ann_custom_OperationType); + CompleteEnumeratedLiteral literal_MULTIPLICATION = TypeObjectUtils::build_complete_enumerated_literal(common_MULTIPLICATION, detail_MULTIPLICATION); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_OperationType, literal_MULTIPLICATION); + } + { + EnumeratedLiteralFlag flags_DIVISION = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_DIVISION = TypeObjectUtils::build_common_enumerated_literal(3, flags_DIVISION); + eprosima::fastcdr::optional member_ann_builtin_DIVISION; + ann_custom_OperationType.reset(); + MemberName name_DIVISION = "DIVISION"; + CompleteMemberDetail detail_DIVISION = TypeObjectUtils::build_complete_member_detail(name_DIVISION, member_ann_builtin_DIVISION, ann_custom_OperationType); + CompleteEnumeratedLiteral literal_DIVISION = TypeObjectUtils::build_complete_enumerated_literal(common_DIVISION, detail_DIVISION); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_OperationType, literal_DIVISION); + } + CompleteEnumeratedType enumerated_type_OperationType = TypeObjectUtils::build_complete_enumerated_type(enum_flags_OperationType, header_OperationType, + literal_seq_OperationType); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_enumerated_type_object(enumerated_type_OperationType, type_name_OperationType.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "OperationType already registered in TypeObjectRegistry for a different type."); + } + return_code_RequestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "OperationType", type_ids_RequestType); + if (return_code_RequestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "OperationType: Given Enum TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_operation = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_operation; + MemberId member_id_operation = 0x00000000; + if (EK_COMPLETE == type_ids_RequestType.type_identifier1()._d() || TK_NONE == type_ids_RequestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_RequestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_RequestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_RequestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_RequestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_RequestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_RequestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_RequestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_RequestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_RequestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_RequestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_RequestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_RequestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_RequestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_RequestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_operation = TypeObjectUtils::build_common_struct_member(member_id_operation, member_flags_operation, type_ids_RequestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_RequestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_RequestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_RequestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_RequestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_RequestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_RequestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_RequestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_RequestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_RequestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_RequestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_RequestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_RequestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_RequestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_RequestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_RequestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_operation = TypeObjectUtils::build_common_struct_member(member_id_operation, member_flags_operation, type_ids_RequestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure operation member TypeIdentifier inconsistent."); + return; + } + MemberName name_operation = "operation"; + eprosima::fastcdr::optional member_ann_builtin_operation; + ann_custom_RequestType.reset(); + CompleteMemberDetail detail_operation = TypeObjectUtils::build_complete_member_detail(name_operation, member_ann_builtin_operation, ann_custom_RequestType); + CompleteStructMember member_operation = TypeObjectUtils::build_complete_struct_member(common_operation, detail_operation); + TypeObjectUtils::add_complete_struct_member(member_seq_RequestType, member_operation); + } + { + return_code_RequestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_int32_t", type_ids_RequestType); + + if (return_code_RequestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "x Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_x = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_x; + MemberId member_id_x = 0x00000001; + if (EK_COMPLETE == type_ids_RequestType.type_identifier1()._d() || TK_NONE == type_ids_RequestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_RequestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_RequestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_RequestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_RequestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_RequestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_RequestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_RequestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_RequestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_RequestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_RequestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_RequestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_RequestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_RequestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_RequestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_x = TypeObjectUtils::build_common_struct_member(member_id_x, member_flags_x, type_ids_RequestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_RequestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_RequestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_RequestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_RequestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_RequestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_RequestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_RequestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_RequestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_RequestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_RequestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_RequestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_RequestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_RequestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_RequestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_RequestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_x = TypeObjectUtils::build_common_struct_member(member_id_x, member_flags_x, type_ids_RequestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure x member TypeIdentifier inconsistent."); + return; + } + MemberName name_x = "x"; + eprosima::fastcdr::optional member_ann_builtin_x; + ann_custom_RequestType.reset(); + CompleteMemberDetail detail_x = TypeObjectUtils::build_complete_member_detail(name_x, member_ann_builtin_x, ann_custom_RequestType); + CompleteStructMember member_x = TypeObjectUtils::build_complete_struct_member(common_x, detail_x); + TypeObjectUtils::add_complete_struct_member(member_seq_RequestType, member_x); + } + { + return_code_RequestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_int32_t", type_ids_RequestType); + + if (return_code_RequestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "y Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_y = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_y; + MemberId member_id_y = 0x00000002; + if (EK_COMPLETE == type_ids_RequestType.type_identifier1()._d() || TK_NONE == type_ids_RequestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_RequestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_RequestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_RequestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_RequestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_RequestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_RequestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_RequestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_RequestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_RequestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_RequestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_RequestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_RequestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_RequestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_RequestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_y = TypeObjectUtils::build_common_struct_member(member_id_y, member_flags_y, type_ids_RequestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_RequestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_RequestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_RequestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_RequestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_RequestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_RequestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_RequestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_RequestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_RequestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_RequestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_RequestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_RequestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_RequestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_RequestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_RequestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_y = TypeObjectUtils::build_common_struct_member(member_id_y, member_flags_y, type_ids_RequestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure y member TypeIdentifier inconsistent."); + return; + } + MemberName name_y = "y"; + eprosima::fastcdr::optional member_ann_builtin_y; + ann_custom_RequestType.reset(); + CompleteMemberDetail detail_y = TypeObjectUtils::build_complete_member_detail(name_y, member_ann_builtin_y, ann_custom_RequestType); + CompleteStructMember member_y = TypeObjectUtils::build_complete_struct_member(common_y, detail_y); + TypeObjectUtils::add_complete_struct_member(member_seq_RequestType, member_y); + } + CompleteStructType struct_type_RequestType = TypeObjectUtils::build_complete_struct_type(struct_flags_RequestType, header_RequestType, member_seq_RequestType); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_struct_type_object(struct_type_RequestType, type_name_RequestType.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "RequestType already registered in TypeObjectRegistry for a different type."); + } + return_code_RequestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "RequestType", type_ids_RequestType); + if (return_code_RequestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "RequestType: Given Struct TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } +} +void register_ReplyType_type_identifier() +{ + { + StructTypeFlag struct_flags_ReplyType = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::NOT_APPLIED, + false, false); + ReturnCode_t return_code_ReplyType; + TypeIdentifierPair type_ids_ReplyType; + QualifiedTypeName type_name_ReplyType = "ReplyType"; + eprosima::fastcdr::optional type_ann_builtin_ReplyType; + eprosima::fastcdr::optional ann_custom_ReplyType; + CompleteTypeDetail detail_ReplyType = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_ReplyType, ann_custom_ReplyType, type_name_ReplyType.to_string()); + CompleteStructHeader header_ReplyType; + header_ReplyType = TypeObjectUtils::build_complete_struct_header(TypeIdentifier(), detail_ReplyType); + CompleteStructMemberSeq member_seq_ReplyType; + { + return_code_ReplyType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_int64_t", type_ids_ReplyType); + + if (return_code_ReplyType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "z Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_z = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_z; + MemberId member_id_z = 0x00000000; + if (EK_COMPLETE == type_ids_ReplyType.type_identifier1()._d() || TK_NONE == type_ids_ReplyType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ReplyType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ReplyType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ReplyType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ReplyType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ReplyType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ReplyType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ReplyType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ReplyType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ReplyType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ReplyType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ReplyType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ReplyType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ReplyType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ReplyType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_z = TypeObjectUtils::build_common_struct_member(member_id_z, member_flags_z, type_ids_ReplyType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ReplyType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ReplyType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ReplyType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ReplyType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ReplyType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ReplyType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ReplyType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ReplyType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ReplyType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ReplyType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ReplyType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ReplyType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ReplyType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ReplyType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ReplyType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_z = TypeObjectUtils::build_common_struct_member(member_id_z, member_flags_z, type_ids_ReplyType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure z member TypeIdentifier inconsistent."); + return; + } + MemberName name_z = "z"; + eprosima::fastcdr::optional member_ann_builtin_z; + ann_custom_ReplyType.reset(); + CompleteMemberDetail detail_z = TypeObjectUtils::build_complete_member_detail(name_z, member_ann_builtin_z, ann_custom_ReplyType); + CompleteStructMember member_z = TypeObjectUtils::build_complete_struct_member(common_z, detail_z); + TypeObjectUtils::add_complete_struct_member(member_seq_ReplyType, member_z); + } + CompleteStructType struct_type_ReplyType = TypeObjectUtils::build_complete_struct_type(struct_flags_ReplyType, header_ReplyType, member_seq_ReplyType); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_struct_type_object(struct_type_ReplyType, type_name_ReplyType.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "ReplyType already registered in TypeObjectRegistry for a different type."); + } + return_code_ReplyType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "ReplyType", type_ids_ReplyType); + if (return_code_ReplyType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "ReplyType: Given Struct TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } +} + diff --git a/examples/cpp/dds/RequestReplyExample/CalculatorTypeObjectSupport.hpp b/examples/cpp/dds/RequestReplyExample/CalculatorTypeObjectSupport.hpp new file mode 100644 index 00000000000..fa71b03f7d9 --- /dev/null +++ b/examples/cpp/dds/RequestReplyExample/CalculatorTypeObjectSupport.hpp @@ -0,0 +1,61 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file CalculatorTypeObjectSupport.hpp + * Header file containing the API required to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#ifndef _FAST_DDS_GENERATED_CALCULATOR_TYPE_OBJECT_SUPPORT_HPP_ +#define _FAST_DDS_GENERATED_CALCULATOR_TYPE_OBJECT_SUPPORT_HPP_ + + +#if defined(_WIN32) +#if defined(EPROSIMA_USER_DLL_EXPORT) +#define eProsima_user_DllExport __declspec( dllexport ) +#else +#define eProsima_user_DllExport +#endif // EPROSIMA_USER_DLL_EXPORT +#else +#define eProsima_user_DllExport +#endif // _WIN32 + +/** + * @brief Register every TypeObject representation defined in the IDL file in Fast DDS TypeObjectRegistry. + */ +eProsima_user_DllExport void register_Calculator_type_objects(); + +#ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +/** + * @brief Register RequestType related TypeIdentifier. + * Fully-descriptive TypeIdentifiers are directly registered. + * Hash TypeIdentifiers require to fill the TypeObject information and hash it, consequently, the TypeObject is + * indirectly registered as well. + */ +void register_RequestType_type_identifier(); +/** + * @brief Register ReplyType related TypeIdentifier. + * Fully-descriptive TypeIdentifiers are directly registered. + * Hash TypeIdentifiers require to fill the TypeObject information and hash it, consequently, the TypeObject is + * indirectly registered as well. + */ +void register_ReplyType_type_identifier(); + + +#endif // DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +#endif // _FAST_DDS_GENERATED_CALCULATOR_TYPE_OBJECT_SUPPORT_HPP_ diff --git a/examples/cpp/dds/RequestReplyExample/Calculatorv1.cxx b/examples/cpp/dds/RequestReplyExample/Calculatorv1.cxx deleted file mode 100644 index 50874dc3bc9..00000000000 --- a/examples/cpp/dds/RequestReplyExample/Calculatorv1.cxx +++ /dev/null @@ -1,467 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file Calculator.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "Calculator.h" - -#if FASTCDR_VERSION_MAJOR == 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - -namespace helper { namespace internal { - -enum class Size { - UInt8, - UInt16, - UInt32, - UInt64, -}; - -constexpr Size get_size(int s) { - return (s <= 8 ) ? Size::UInt8: - (s <= 16) ? Size::UInt16: - (s <= 32) ? Size::UInt32: Size::UInt64; -} - -template -struct FindTypeH; - -template<> -struct FindTypeH { - using type = std::uint8_t; -}; - -template<> -struct FindTypeH { - using type = std::uint16_t; -}; - -template<> -struct FindTypeH { - using type = std::uint32_t; -}; - -template<> -struct FindTypeH { - using type = std::uint64_t; -}; -} - -template -struct FindType { - using type = typename internal::FindTypeH::type; -}; -} - -#define ReplyType_max_cdr_typesize 16ULL; -#define RequestType_max_cdr_typesize 16ULL; - - - - -RequestType::RequestType() -{ - // OperationType m_operation - m_operation = ::ADDITION; - // long m_x - m_x = 0; - // long m_y - m_y = 0; - -} - -RequestType::~RequestType() -{ -} - -RequestType::RequestType( - const RequestType& x) -{ - m_operation = x.m_operation; - - - m_x = x.m_x; - - - m_y = x.m_y; - -} - -RequestType::RequestType( - RequestType&& x) noexcept -{ - m_operation = x.m_operation; - - - m_x = x.m_x; - - - m_y = x.m_y; - -} - -RequestType& RequestType::operator =( - const RequestType& x) -{ - m_operation = x.m_operation; - - - m_x = x.m_x; - - - m_y = x.m_y; - - return *this; -} - -RequestType& RequestType::operator =( - RequestType&& x) noexcept -{ - m_operation = x.m_operation; - - - m_x = x.m_x; - - - m_y = x.m_y; - - return *this; -} - -bool RequestType::operator ==( - const RequestType& x) const -{ - return (m_operation == x.m_operation && - m_x == x.m_x && - m_y == x.m_y); -} - -bool RequestType::operator !=( - const RequestType& x) const -{ - return !(*this == x); -} - -size_t RequestType::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return RequestType_max_cdr_typesize; -} - -size_t RequestType::getCdrSerializedSize( - const RequestType& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - return current_alignment - initial_alignment; -} - - -void RequestType::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << (uint32_t)m_operation; - - scdr << m_x; - - scdr << m_y; - -} - -void RequestType::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - { - uint32_t enum_value = 0; - dcdr >> enum_value; - m_operation = (OperationType)enum_value; - } - - - - dcdr >> m_x; - - - - dcdr >> m_y; - - -} - - -bool RequestType::isKeyDefined() -{ - return false; -} - -void RequestType::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member operation - * @param _operation New value for member operation - */ -void RequestType::operation( - OperationType _operation) -{ - m_operation = _operation; -} - -/*! - * @brief This function returns the value of member operation - * @return Value of member operation - */ -OperationType RequestType::operation() const -{ - return m_operation; -} - -/*! - * @brief This function returns a reference to member operation - * @return Reference to member operation - */ -OperationType& RequestType::operation() -{ - return m_operation; -} - - -/*! - * @brief This function sets a value in member x - * @param _x New value for member x - */ -void RequestType::x( - int32_t _x) -{ - m_x = _x; -} - -/*! - * @brief This function returns the value of member x - * @return Value of member x - */ -int32_t RequestType::x() const -{ - return m_x; -} - -/*! - * @brief This function returns a reference to member x - * @return Reference to member x - */ -int32_t& RequestType::x() -{ - return m_x; -} - - -/*! - * @brief This function sets a value in member y - * @param _y New value for member y - */ -void RequestType::y( - int32_t _y) -{ - m_y = _y; -} - -/*! - * @brief This function returns the value of member y - * @return Value of member y - */ -int32_t RequestType::y() const -{ - return m_y; -} - -/*! - * @brief This function returns a reference to member y - * @return Reference to member y - */ -int32_t& RequestType::y() -{ - return m_y; -} - - - - - -ReplyType::ReplyType() -{ - // long long m_z - m_z = 0; - -} - -ReplyType::~ReplyType() -{ -} - -ReplyType::ReplyType( - const ReplyType& x) -{ - m_z = x.m_z; - -} - -ReplyType::ReplyType( - ReplyType&& x) noexcept -{ - m_z = x.m_z; - -} - -ReplyType& ReplyType::operator =( - const ReplyType& x) -{ - m_z = x.m_z; - - return *this; -} - -ReplyType& ReplyType::operator =( - ReplyType&& x) noexcept -{ - m_z = x.m_z; - - return *this; -} - -bool ReplyType::operator ==( - const ReplyType& x) const -{ - return (m_z == x.m_z); -} - -bool ReplyType::operator !=( - const ReplyType& x) const -{ - return !(*this == x); -} - -size_t ReplyType::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return ReplyType_max_cdr_typesize; -} - -size_t ReplyType::getCdrSerializedSize( - const ReplyType& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 8 + eprosima::fastcdr::Cdr::alignment(current_alignment, 8); - - - return current_alignment - initial_alignment; -} - - -void ReplyType::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_z; - -} - -void ReplyType::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_z; - - -} - - -bool ReplyType::isKeyDefined() -{ - return false; -} - -void ReplyType::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member z - * @param _z New value for member z - */ -void ReplyType::z( - int64_t _z) -{ - m_z = _z; -} - -/*! - * @brief This function returns the value of member z - * @return Value of member z - */ -int64_t ReplyType::z() const -{ - return m_z; -} - -/*! - * @brief This function returns a reference to member z - * @return Reference to member z - */ -int64_t& ReplyType::z() -{ - return m_z; -} - - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/RequestReplyExample/Calculatorv1.h b/examples/cpp/dds/RequestReplyExample/Calculatorv1.h deleted file mode 100644 index af2bccef6ca..00000000000 --- a/examples/cpp/dds/RequestReplyExample/Calculatorv1.h +++ /dev/null @@ -1,408 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file Calculator.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#include - -#if FASTCDR_VERSION_MAJOR == 1 - -#ifndef _FAST_DDS_GENERATED_CALCULATOR_H_ -#define _FAST_DDS_GENERATED_CALCULATOR_H_ - - -#include - -#include -#include -#include -#include -#include -#include -#include - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define eProsima_user_DllExport -#endif // _WIN32 - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(CALCULATOR_SOURCE) -#define CALCULATOR_DllAPI __declspec( dllexport ) -#else -#define CALCULATOR_DllAPI __declspec( dllimport ) -#endif // CALCULATOR_SOURCE -#else -#define CALCULATOR_DllAPI -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define CALCULATOR_DllAPI -#endif // _WIN32 - -namespace eprosima { -namespace fastcdr { -class Cdr; -} // namespace fastcdr -} // namespace eprosima - - - -/*! - * @brief This class represents the enumeration OperationType defined by the user in the IDL file. - * @ingroup Calculator - */ -enum OperationType : uint32_t -{ - ADDITION, - SUBTRACTION, - MULTIPLICATION, - DIVISION -}; - - -/*! - * @brief This class represents the structure RequestType defined by the user in the IDL file. - * @ingroup Calculator - */ -class RequestType -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport RequestType(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~RequestType(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object RequestType that will be copied. - */ - eProsima_user_DllExport RequestType( - const RequestType& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object RequestType that will be copied. - */ - eProsima_user_DllExport RequestType( - RequestType&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object RequestType that will be copied. - */ - eProsima_user_DllExport RequestType& operator =( - const RequestType& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object RequestType that will be copied. - */ - eProsima_user_DllExport RequestType& operator =( - RequestType&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x RequestType object to compare. - */ - eProsima_user_DllExport bool operator ==( - const RequestType& x) const; - - /*! - * @brief Comparison operator. - * @param x RequestType object to compare. - */ - eProsima_user_DllExport bool operator !=( - const RequestType& x) const; - - /*! - * @brief This function sets a value in member operation - * @param _operation New value for member operation - */ - eProsima_user_DllExport void operation( - OperationType _operation); - - /*! - * @brief This function returns the value of member operation - * @return Value of member operation - */ - eProsima_user_DllExport OperationType operation() const; - - /*! - * @brief This function returns a reference to member operation - * @return Reference to member operation - */ - eProsima_user_DllExport OperationType& operation(); - - - /*! - * @brief This function sets a value in member x - * @param _x New value for member x - */ - eProsima_user_DllExport void x( - int32_t _x); - - /*! - * @brief This function returns the value of member x - * @return Value of member x - */ - eProsima_user_DllExport int32_t x() const; - - /*! - * @brief This function returns a reference to member x - * @return Reference to member x - */ - eProsima_user_DllExport int32_t& x(); - - - /*! - * @brief This function sets a value in member y - * @param _y New value for member y - */ - eProsima_user_DllExport void y( - int32_t _y); - - /*! - * @brief This function returns the value of member y - * @return Value of member y - */ - eProsima_user_DllExport int32_t y() const; - - /*! - * @brief This function returns a reference to member y - * @return Reference to member y - */ - eProsima_user_DllExport int32_t& y(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const RequestType& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - OperationType m_operation; - int32_t m_x; - int32_t m_y; - -}; - - - -/*! - * @brief This class represents the structure ReplyType defined by the user in the IDL file. - * @ingroup Calculator - */ -class ReplyType -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport ReplyType(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~ReplyType(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object ReplyType that will be copied. - */ - eProsima_user_DllExport ReplyType( - const ReplyType& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object ReplyType that will be copied. - */ - eProsima_user_DllExport ReplyType( - ReplyType&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object ReplyType that will be copied. - */ - eProsima_user_DllExport ReplyType& operator =( - const ReplyType& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object ReplyType that will be copied. - */ - eProsima_user_DllExport ReplyType& operator =( - ReplyType&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x ReplyType object to compare. - */ - eProsima_user_DllExport bool operator ==( - const ReplyType& x) const; - - /*! - * @brief Comparison operator. - * @param x ReplyType object to compare. - */ - eProsima_user_DllExport bool operator !=( - const ReplyType& x) const; - - /*! - * @brief This function sets a value in member z - * @param _z New value for member z - */ - eProsima_user_DllExport void z( - int64_t _z); - - /*! - * @brief This function returns the value of member z - * @return Value of member z - */ - eProsima_user_DllExport int64_t z() const; - - /*! - * @brief This function returns a reference to member z - * @return Reference to member z - */ - eProsima_user_DllExport int64_t& z(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const ReplyType& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - int64_t m_z; - -}; - - -#endif // _FAST_DDS_GENERATED_CALCULATOR_H_ - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/SampleConfig_Controller/CMakeLists.txt b/examples/cpp/dds/SampleConfig_Controller/CMakeLists.txt index b806afaca8a..bfe106ab4a3 100644 --- a/examples/cpp/dds/SampleConfig_Controller/CMakeLists.txt +++ b/examples/cpp/dds/SampleConfig_Controller/CMakeLists.txt @@ -25,8 +25,8 @@ if(NOT foonathan_memory_FOUND) find_package(foonathan_memory REQUIRED) endif() -if(NOT fastrtps_FOUND) - find_package(fastrtps 2.12 REQUIRED) +if(NOT fastdds_FOUND) + find_package(fastdds 3 REQUIRED) endif() #Check C++11 @@ -46,7 +46,7 @@ target_compile_definitions(DDSSampleConfig_Controller PRIVATE $<$>,$>:__DEBUG> $<$:__INTERNALDEBUG> # Internal debug activated. ) -target_link_libraries(DDSSampleConfig_Controller fastrtps fastcdr foonathan_memory) +target_link_libraries(DDSSampleConfig_Controller fastdds fastcdr foonathan_memory) install(TARGETS DDSSampleConfig_Controller RUNTIME DESTINATION examples/cpp/dds/SampleConfig_Controller/${BIN_INSTALL_DIR} ) diff --git a/examples/cpp/dds/SampleConfig_Controller/sample.cxx b/examples/cpp/dds/SampleConfig_Controller/sample.cxx deleted file mode 100644 index 360d4a1b2b2..00000000000 --- a/examples/cpp/dds/SampleConfig_Controller/sample.cxx +++ /dev/null @@ -1,158 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file sample.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "sample.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - - - - -sample::sample() -{ -} - -sample::~sample() -{ -} - -sample::sample( - const sample& x) -{ - m_index = x.m_index; - m_key_value = x.m_key_value; -} - -sample::sample( - sample&& x) noexcept -{ - m_index = x.m_index; - m_key_value = x.m_key_value; -} - -sample& sample::operator =( - const sample& x) -{ - - m_index = x.m_index; - m_key_value = x.m_key_value; - return *this; -} - -sample& sample::operator =( - sample&& x) noexcept -{ - - m_index = x.m_index; - m_key_value = x.m_key_value; - return *this; -} - -bool sample::operator ==( - const sample& x) const -{ - return (m_index == x.m_index && - m_key_value == x.m_key_value); -} - -bool sample::operator !=( - const sample& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void sample::index( - uint8_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint8_t sample::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint8_t& sample::index() -{ - return m_index; -} - - -/*! - * @brief This function sets a value in member key_value - * @param _key_value New value for member key_value - */ -void sample::key_value( - uint8_t _key_value) -{ - m_key_value = _key_value; -} - -/*! - * @brief This function returns the value of member key_value - * @return Value of member key_value - */ -uint8_t sample::key_value() const -{ - return m_key_value; -} - -/*! - * @brief This function returns a reference to member key_value - * @return Reference to member key_value - */ -uint8_t& sample::key_value() -{ - return m_key_value; -} - - -// Include auxiliary functions like for serializing/deserializing. -#include "sampleCdrAux.ipp" - -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/SampleConfig_Controller/sample.h b/examples/cpp/dds/SampleConfig_Controller/sample.h deleted file mode 100644 index c050c8527cc..00000000000 --- a/examples/cpp/dds/SampleConfig_Controller/sample.h +++ /dev/null @@ -1,188 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file sample.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#include -#include "samplev1.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#ifndef _FAST_DDS_GENERATED_SAMPLE_H_ -#define _FAST_DDS_GENERATED_SAMPLE_H_ - -#include -#include -#include -#include -#include -#include - -#include -#include -#include - - - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define eProsima_user_DllExport -#endif // _WIN32 - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(SAMPLE_SOURCE) -#define SAMPLE_DllAPI __declspec( dllexport ) -#else -#define SAMPLE_DllAPI __declspec( dllimport ) -#endif // SAMPLE_SOURCE -#else -#define SAMPLE_DllAPI -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define SAMPLE_DllAPI -#endif // _WIN32 - -namespace eprosima { -namespace fastcdr { -class Cdr; -class CdrSizeCalculator; -} // namespace fastcdr -} // namespace eprosima - - - - - -/*! - * @brief This class represents the structure sample defined by the user in the IDL file. - * @ingroup sample - */ -class sample -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport sample(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~sample(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object sample that will be copied. - */ - eProsima_user_DllExport sample( - const sample& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object sample that will be copied. - */ - eProsima_user_DllExport sample( - sample&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object sample that will be copied. - */ - eProsima_user_DllExport sample& operator =( - const sample& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object sample that will be copied. - */ - eProsima_user_DllExport sample& operator =( - sample&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x sample object to compare. - */ - eProsima_user_DllExport bool operator ==( - const sample& x) const; - - /*! - * @brief Comparison operator. - * @param x sample object to compare. - */ - eProsima_user_DllExport bool operator !=( - const sample& x) const; - - /*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ - eProsima_user_DllExport void index( - uint8_t _index); - - /*! - * @brief This function returns the value of member index - * @return Value of member index - */ - eProsima_user_DllExport uint8_t index() const; - - /*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ - eProsima_user_DllExport uint8_t& index(); - - - /*! - * @brief This function sets a value in member key_value - * @param _key_value New value for member key_value - */ - eProsima_user_DllExport void key_value( - uint8_t _key_value); - - /*! - * @brief This function returns the value of member key_value - * @return Value of member key_value - */ - eProsima_user_DllExport uint8_t key_value() const; - - /*! - * @brief This function returns a reference to member key_value - * @return Reference to member key_value - */ - eProsima_user_DllExport uint8_t& key_value(); - -private: - - uint8_t m_index{0}; - uint8_t m_key_value{0}; - -}; - -#endif // _FAST_DDS_GENERATED_SAMPLE_H_ - - - -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/SampleConfig_Controller/sample.hpp b/examples/cpp/dds/SampleConfig_Controller/sample.hpp new file mode 100644 index 00000000000..3023a792269 --- /dev/null +++ b/examples/cpp/dds/SampleConfig_Controller/sample.hpp @@ -0,0 +1,215 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file sample.hpp + * This header file contains the declaration of the described types in the IDL file. + * + * This file was generated by the tool fastddsgen. + */ + +#ifndef _FAST_DDS_GENERATED_SAMPLE_HPP_ +#define _FAST_DDS_GENERATED_SAMPLE_HPP_ + +#include +#include + +#if defined(_WIN32) +#if defined(EPROSIMA_USER_DLL_EXPORT) +#define eProsima_user_DllExport __declspec( dllexport ) +#else +#define eProsima_user_DllExport +#endif // EPROSIMA_USER_DLL_EXPORT +#else +#define eProsima_user_DllExport +#endif // _WIN32 + +#if defined(_WIN32) +#if defined(EPROSIMA_USER_DLL_EXPORT) +#if defined(SAMPLE_SOURCE) +#define SAMPLE_DllAPI __declspec( dllexport ) +#else +#define SAMPLE_DllAPI __declspec( dllimport ) +#endif // SAMPLE_SOURCE +#else +#define SAMPLE_DllAPI +#endif // EPROSIMA_USER_DLL_EXPORT +#else +#define SAMPLE_DllAPI +#endif // _WIN32 + +/*! + * @brief This class represents the structure sample defined by the user in the IDL file. + * @ingroup sample + */ +class sample +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport sample() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~sample() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object sample that will be copied. + */ + eProsima_user_DllExport sample( + const sample& x) + { + m_index = x.m_index; + + m_key_value = x.m_key_value; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object sample that will be copied. + */ + eProsima_user_DllExport sample( + sample&& x) noexcept + { + m_index = x.m_index; + m_key_value = x.m_key_value; + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object sample that will be copied. + */ + eProsima_user_DllExport sample& operator =( + const sample& x) + { + + m_index = x.m_index; + + m_key_value = x.m_key_value; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object sample that will be copied. + */ + eProsima_user_DllExport sample& operator =( + sample&& x) noexcept + { + + m_index = x.m_index; + m_key_value = x.m_key_value; + return *this; + } + + /*! + * @brief Comparison operator. + * @param x sample object to compare. + */ + eProsima_user_DllExport bool operator ==( + const sample& x) const + { + return (m_index == x.m_index && + m_key_value == x.m_key_value); + } + + /*! + * @brief Comparison operator. + * @param x sample object to compare. + */ + eProsima_user_DllExport bool operator !=( + const sample& x) const + { + return !(*this == x); + } + + /*! + * @brief This function sets a value in member index + * @param _index New value for member index + */ + eProsima_user_DllExport void index( + uint8_t _index) + { + m_index = _index; + } + + /*! + * @brief This function returns the value of member index + * @return Value of member index + */ + eProsima_user_DllExport uint8_t index() const + { + return m_index; + } + + /*! + * @brief This function returns a reference to member index + * @return Reference to member index + */ + eProsima_user_DllExport uint8_t& index() + { + return m_index; + } + + + /*! + * @brief This function sets a value in member key_value + * @param _key_value New value for member key_value + */ + eProsima_user_DllExport void key_value( + uint8_t _key_value) + { + m_key_value = _key_value; + } + + /*! + * @brief This function returns the value of member key_value + * @return Value of member key_value + */ + eProsima_user_DllExport uint8_t key_value() const + { + return m_key_value; + } + + /*! + * @brief This function returns a reference to member key_value + * @return Reference to member key_value + */ + eProsima_user_DllExport uint8_t& key_value() + { + return m_key_value; + } + + + +private: + + uint8_t m_index{0}; + uint8_t m_key_value{0}; + +}; + +#endif // _FAST_DDS_GENERATED_SAMPLE_HPP_ + + diff --git a/examples/cpp/dds/SampleConfig_Controller/sampleCdrAux.hpp b/examples/cpp/dds/SampleConfig_Controller/sampleCdrAux.hpp index 18ed5857add..b80dff31248 100644 --- a/examples/cpp/dds/SampleConfig_Controller/sampleCdrAux.hpp +++ b/examples/cpp/dds/SampleConfig_Controller/sampleCdrAux.hpp @@ -22,7 +22,7 @@ #ifndef _FAST_DDS_GENERATED_SAMPLECDRAUX_HPP_ #define _FAST_DDS_GENERATED_SAMPLECDRAUX_HPP_ -#include "sample.h" +#include "sample.hpp" constexpr uint32_t sample_max_cdr_typesize {6UL}; constexpr uint32_t sample_max_key_cdr_typesize {1UL}; @@ -34,8 +34,6 @@ namespace fastcdr { class Cdr; class CdrSizeCalculator; - - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const sample& data); diff --git a/examples/cpp/dds/SampleConfig_Controller/sampleCdrAux.ipp b/examples/cpp/dds/SampleConfig_Controller/sampleCdrAux.ipp index 11bc4709a6e..17a3d1025fc 100644 --- a/examples/cpp/dds/SampleConfig_Controller/sampleCdrAux.ipp +++ b/examples/cpp/dds/SampleConfig_Controller/sampleCdrAux.ipp @@ -34,8 +34,6 @@ using namespace eprosima::fastcdr::exception; namespace eprosima { namespace fastcdr { - - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, diff --git a/examples/cpp/dds/SampleConfig_Controller/samplePubSubTypes.cxx b/examples/cpp/dds/SampleConfig_Controller/samplePubSubTypes.cxx index 9095d77083a..cae143a08ca 100644 --- a/examples/cpp/dds/SampleConfig_Controller/samplePubSubTypes.cxx +++ b/examples/cpp/dds/SampleConfig_Controller/samplePubSubTypes.cxx @@ -19,18 +19,18 @@ * This file was generated by the tool fastddsgen. */ +#include "samplePubSubTypes.h" +#include #include -#include "samplePubSubTypes.h" #include "sampleCdrAux.hpp" +#include "sampleTypeObjectSupport.hpp" using SerializedPayload_t = eprosima::fastrtps::rtps::SerializedPayload_t; using InstanceHandle_t = eprosima::fastrtps::rtps::InstanceHandle_t; using DataRepresentationId_t = eprosima::fastdds::dds::DataRepresentationId_t; - - samplePubSubType::samplePubSubType() { setName("sample"); @@ -219,3 +219,11 @@ bool samplePubSubType::getKey( return true; } +void samplePubSubType::register_type_object_representation() const +{ + register_sample_type_objects(); +} + + +// Include auxiliary functions like for serializing/deserializing. +#include "sampleCdrAux.ipp" diff --git a/examples/cpp/dds/SampleConfig_Controller/samplePubSubTypes.h b/examples/cpp/dds/SampleConfig_Controller/samplePubSubTypes.h index ec881115211..9e59aa58042 100644 --- a/examples/cpp/dds/SampleConfig_Controller/samplePubSubTypes.h +++ b/examples/cpp/dds/SampleConfig_Controller/samplePubSubTypes.h @@ -27,9 +27,9 @@ #include #include #include -#include +#include -#include "sample.h" +#include "sample.hpp" #if !defined(GEN_API_VER) || (GEN_API_VER != 2) @@ -38,8 +38,6 @@ #endif // GEN_API_VER - - /*! * @brief This class represents the TopicDataType of the type sample defined by the user in the IDL file. * @ingroup sample @@ -90,6 +88,9 @@ class samplePubSubType : public eprosima::fastdds::dds::TopicDataType eProsima_user_DllExport void deleteData( void* data) override; + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + #ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED eProsima_user_DllExport inline bool is_bounded() const override { diff --git a/examples/cpp/dds/SampleConfig_Controller/sampleTypeObjectSupport.cxx b/examples/cpp/dds/SampleConfig_Controller/sampleTypeObjectSupport.cxx new file mode 100644 index 00000000000..3719bbf77e6 --- /dev/null +++ b/examples/cpp/dds/SampleConfig_Controller/sampleTypeObjectSupport.cxx @@ -0,0 +1,224 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file sampleTypeObjectSupport.cxx + * Source file containing the implementation to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#include "sampleTypeObjectSupport.hpp" + +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include + +#include "sample.hpp" + + +using namespace eprosima::fastdds::dds::xtypes; + +void register_sample_type_objects() +{ + static std::once_flag once_flag; + std::call_once(once_flag, []() + { + register_sample_type_identifier(); + + }); +} + +void register_sample_type_identifier() +{ + { + StructTypeFlag struct_flags_sample = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::NOT_APPLIED, + false, false); + ReturnCode_t return_code_sample; + TypeIdentifierPair type_ids_sample; + QualifiedTypeName type_name_sample = "sample"; + eprosima::fastcdr::optional type_ann_builtin_sample; + eprosima::fastcdr::optional ann_custom_sample; + CompleteTypeDetail detail_sample = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_sample, ann_custom_sample, type_name_sample.to_string()); + CompleteStructHeader header_sample; + header_sample = TypeObjectUtils::build_complete_struct_header(TypeIdentifier(), detail_sample); + CompleteStructMemberSeq member_seq_sample; + { + return_code_sample = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_byte", type_ids_sample); + + if (return_code_sample != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "index Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_index = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_index; + MemberId member_id_index = 0x00000000; + if (EK_COMPLETE == type_ids_sample.type_identifier1()._d() || TK_NONE == type_ids_sample.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_sample.type_identifier1()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_sample.type_identifier1()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_sample.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_sample.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_sample.type_identifier2()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_sample.type_identifier2()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_sample.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure index member TypeIdentifier inconsistent."); + return; + } + MemberName name_index = "index"; + eprosima::fastcdr::optional member_ann_builtin_index; + ann_custom_sample.reset(); + CompleteMemberDetail detail_index = TypeObjectUtils::build_complete_member_detail(name_index, member_ann_builtin_index, ann_custom_sample); + CompleteStructMember member_index = TypeObjectUtils::build_complete_struct_member(common_index, detail_index); + TypeObjectUtils::add_complete_struct_member(member_seq_sample, member_index); + } + { + return_code_sample = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_byte", type_ids_sample); + + if (return_code_sample != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "key_value Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_key_value = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, true, false); + CommonStructMember common_key_value; + MemberId member_id_key_value = 0x00000001; + if (EK_COMPLETE == type_ids_sample.type_identifier1()._d() || TK_NONE == type_ids_sample.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_sample.type_identifier1()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_sample.type_identifier1()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_key_value = TypeObjectUtils::build_common_struct_member(member_id_key_value, member_flags_key_value, type_ids_sample.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_sample.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_sample.type_identifier2()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_sample.type_identifier2()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_key_value = TypeObjectUtils::build_common_struct_member(member_id_key_value, member_flags_key_value, type_ids_sample.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure key_value member TypeIdentifier inconsistent."); + return; + } + MemberName name_key_value = "key_value"; + eprosima::fastcdr::optional member_ann_builtin_key_value; + ann_custom_sample.reset(); + AppliedAnnotationSeq tmp_ann_custom_key_value; + eprosima::fastcdr::optional unit_key_value; + eprosima::fastcdr::optional min_key_value; + eprosima::fastcdr::optional max_key_value; + eprosima::fastcdr::optional hash_id_key_value; + if (unit_key_value.has_value() || min_key_value.has_value() || max_key_value.has_value() || hash_id_key_value.has_value()) + { + member_ann_builtin_key_value = TypeObjectUtils::build_applied_builtin_member_annotations(unit_key_value, min_key_value, max_key_value, hash_id_key_value); + } + if (!tmp_ann_custom_key_value.empty()) + { + ann_custom_sample = tmp_ann_custom_key_value; + } + CompleteMemberDetail detail_key_value = TypeObjectUtils::build_complete_member_detail(name_key_value, member_ann_builtin_key_value, ann_custom_sample); + CompleteStructMember member_key_value = TypeObjectUtils::build_complete_struct_member(common_key_value, detail_key_value); + TypeObjectUtils::add_complete_struct_member(member_seq_sample, member_key_value); + } + CompleteStructType struct_type_sample = TypeObjectUtils::build_complete_struct_type(struct_flags_sample, header_sample, member_seq_sample); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_struct_type_object(struct_type_sample, type_name_sample.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "sample already registered in TypeObjectRegistry for a different type."); + } + return_code_sample = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "sample", type_ids_sample); + if (return_code_sample != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "sample: Given Struct TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } +} + diff --git a/examples/cpp/dds/SampleConfig_Controller/sampleTypeObjectSupport.hpp b/examples/cpp/dds/SampleConfig_Controller/sampleTypeObjectSupport.hpp new file mode 100644 index 00000000000..5ad7f2e5e07 --- /dev/null +++ b/examples/cpp/dds/SampleConfig_Controller/sampleTypeObjectSupport.hpp @@ -0,0 +1,54 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file sampleTypeObjectSupport.hpp + * Header file containing the API required to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#ifndef _FAST_DDS_GENERATED_SAMPLE_TYPE_OBJECT_SUPPORT_HPP_ +#define _FAST_DDS_GENERATED_SAMPLE_TYPE_OBJECT_SUPPORT_HPP_ + + +#if defined(_WIN32) +#if defined(EPROSIMA_USER_DLL_EXPORT) +#define eProsima_user_DllExport __declspec( dllexport ) +#else +#define eProsima_user_DllExport +#endif // EPROSIMA_USER_DLL_EXPORT +#else +#define eProsima_user_DllExport +#endif // _WIN32 + +/** + * @brief Register every TypeObject representation defined in the IDL file in Fast DDS TypeObjectRegistry. + */ +eProsima_user_DllExport void register_sample_type_objects(); + +#ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +/** + * @brief Register sample related TypeIdentifier. + * Fully-descriptive TypeIdentifiers are directly registered. + * Hash TypeIdentifiers require to fill the TypeObject information and hash it, consequently, the TypeObject is + * indirectly registered as well. + */ +void register_sample_type_identifier(); + + +#endif // DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +#endif // _FAST_DDS_GENERATED_SAMPLE_TYPE_OBJECT_SUPPORT_HPP_ diff --git a/examples/cpp/dds/SampleConfig_Controller/sampleconfig_safest.cpp b/examples/cpp/dds/SampleConfig_Controller/sampleconfig_safest.cpp index 9d3580e9a88..80fa6a39ab8 100644 --- a/examples/cpp/dds/SampleConfig_Controller/sampleconfig_safest.cpp +++ b/examples/cpp/dds/SampleConfig_Controller/sampleconfig_safest.cpp @@ -151,7 +151,7 @@ void safest() //Read the contents of both histories: std::cout << "The Reliable Subscriber holds: " << std::endl; - while (myReader->read_next_sample(&my_sample, &sample_info) == ReturnCode_t::RETCODE_OK) + while (myReader->read_next_sample(&my_sample, &sample_info) == RETCODE_OK) { std::cout << std::to_string(my_sample.index()) << " (key " << static_cast(my_sample.key_value()) << ")" << std::endl; diff --git a/examples/cpp/dds/SampleConfig_Controller/samplev1.cxx b/examples/cpp/dds/SampleConfig_Controller/samplev1.cxx deleted file mode 100644 index 3b735befaf8..00000000000 --- a/examples/cpp/dds/SampleConfig_Controller/samplev1.cxx +++ /dev/null @@ -1,280 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file sample.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "sample.h" - -#if FASTCDR_VERSION_MAJOR == 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - -namespace helper { namespace internal { - -enum class Size { - UInt8, - UInt16, - UInt32, - UInt64, -}; - -constexpr Size get_size(int s) { - return (s <= 8 ) ? Size::UInt8: - (s <= 16) ? Size::UInt16: - (s <= 32) ? Size::UInt32: Size::UInt64; -} - -template -struct FindTypeH; - -template<> -struct FindTypeH { - using type = std::uint8_t; -}; - -template<> -struct FindTypeH { - using type = std::uint16_t; -}; - -template<> -struct FindTypeH { - using type = std::uint32_t; -}; - -template<> -struct FindTypeH { - using type = std::uint64_t; -}; -} - -template -struct FindType { - using type = typename internal::FindTypeH::type; -}; -} - -#define sample_max_cdr_typesize 6ULL; - - - - -sample::sample() -{ - // octet m_index - m_index = 0; - // octet m_key_value - m_key_value = 0; - -} - -sample::~sample() -{ -} - -sample::sample( - const sample& x) -{ - m_index = x.m_index; - - - m_key_value = x.m_key_value; - -} - -sample::sample( - sample&& x) noexcept -{ - m_index = x.m_index; - - - m_key_value = x.m_key_value; - -} - -sample& sample::operator =( - const sample& x) -{ - m_index = x.m_index; - - - m_key_value = x.m_key_value; - - return *this; -} - -sample& sample::operator =( - sample&& x) noexcept -{ - m_index = x.m_index; - - - m_key_value = x.m_key_value; - - return *this; -} - -bool sample::operator ==( - const sample& x) const -{ - return (m_index == x.m_index && - m_key_value == x.m_key_value); -} - -bool sample::operator !=( - const sample& x) const -{ - return !(*this == x); -} - -size_t sample::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return sample_max_cdr_typesize; -} - -size_t sample::getCdrSerializedSize( - const sample& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - return current_alignment - initial_alignment; -} - - -void sample::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_index; - - scdr << m_key_value; - -} - -void sample::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_index; - - - - dcdr >> m_key_value; - - -} - - -bool sample::isKeyDefined() -{ - return true; -} - -void sample::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; - - - scdr << m_key_value; - -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void sample::index( - uint8_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint8_t sample::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint8_t& sample::index() -{ - return m_index; -} - - -/*! - * @brief This function sets a value in member key_value - * @param _key_value New value for member key_value - */ -void sample::key_value( - uint8_t _key_value) -{ - m_key_value = _key_value; -} - -/*! - * @brief This function returns the value of member key_value - * @return Value of member key_value - */ -uint8_t sample::key_value() const -{ - return m_key_value; -} - -/*! - * @brief This function returns a reference to member key_value - * @return Reference to member key_value - */ -uint8_t& sample::key_value() -{ - return m_key_value; -} - - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/SampleConfig_Controller/samplev1.h b/examples/cpp/dds/SampleConfig_Controller/samplev1.h deleted file mode 100644 index 4fa288d1bc9..00000000000 --- a/examples/cpp/dds/SampleConfig_Controller/samplev1.h +++ /dev/null @@ -1,237 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file sample.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#include - -#if FASTCDR_VERSION_MAJOR == 1 - -#ifndef _FAST_DDS_GENERATED_SAMPLE_H_ -#define _FAST_DDS_GENERATED_SAMPLE_H_ - - -#include - -#include -#include -#include -#include -#include -#include -#include - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define eProsima_user_DllExport -#endif // _WIN32 - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(SAMPLE_SOURCE) -#define SAMPLE_DllAPI __declspec( dllexport ) -#else -#define SAMPLE_DllAPI __declspec( dllimport ) -#endif // SAMPLE_SOURCE -#else -#define SAMPLE_DllAPI -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define SAMPLE_DllAPI -#endif // _WIN32 - -namespace eprosima { -namespace fastcdr { -class Cdr; -} // namespace fastcdr -} // namespace eprosima - - - - - -/*! - * @brief This class represents the structure sample defined by the user in the IDL file. - * @ingroup sample - */ -class sample -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport sample(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~sample(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object sample that will be copied. - */ - eProsima_user_DllExport sample( - const sample& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object sample that will be copied. - */ - eProsima_user_DllExport sample( - sample&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object sample that will be copied. - */ - eProsima_user_DllExport sample& operator =( - const sample& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object sample that will be copied. - */ - eProsima_user_DllExport sample& operator =( - sample&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x sample object to compare. - */ - eProsima_user_DllExport bool operator ==( - const sample& x) const; - - /*! - * @brief Comparison operator. - * @param x sample object to compare. - */ - eProsima_user_DllExport bool operator !=( - const sample& x) const; - - /*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ - eProsima_user_DllExport void index( - uint8_t _index); - - /*! - * @brief This function returns the value of member index - * @return Value of member index - */ - eProsima_user_DllExport uint8_t index() const; - - /*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ - eProsima_user_DllExport uint8_t& index(); - - - /*! - * @brief This function sets a value in member key_value - * @param _key_value New value for member key_value - */ - eProsima_user_DllExport void key_value( - uint8_t _key_value); - - /*! - * @brief This function returns the value of member key_value - * @return Value of member key_value - */ - eProsima_user_DllExport uint8_t key_value() const; - - /*! - * @brief This function returns a reference to member key_value - * @return Reference to member key_value - */ - eProsima_user_DllExport uint8_t& key_value(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const sample& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - uint8_t m_index; - uint8_t m_key_value; - -}; - - -#endif // _FAST_DDS_GENERATED_SAMPLE_H_ - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/SampleConfig_Events/CMakeLists.txt b/examples/cpp/dds/SampleConfig_Events/CMakeLists.txt index 58ce865c015..b13077c1140 100644 --- a/examples/cpp/dds/SampleConfig_Events/CMakeLists.txt +++ b/examples/cpp/dds/SampleConfig_Events/CMakeLists.txt @@ -25,8 +25,8 @@ if(NOT foonathan_memory_FOUND) find_package(foonathan_memory REQUIRED) endif() -if(NOT fastrtps_FOUND) - find_package(fastrtps 2.12 REQUIRED) +if(NOT fastdds_FOUND) + find_package(fastdds 3 REQUIRED) endif() #Check C++11 @@ -46,7 +46,7 @@ target_compile_definitions(DDSSampleConfig_Events PRIVATE $<$>,$>:__DEBUG> $<$:__INTERNALDEBUG> # Internal debug activated. ) -target_link_libraries(DDSSampleConfig_Events fastrtps fastcdr foonathan_memory) +target_link_libraries(DDSSampleConfig_Events fastdds fastcdr foonathan_memory) install(TARGETS DDSSampleConfig_Events RUNTIME DESTINATION examples/cpp/dds/SampleConfig_Events/${BIN_INSTALL_DIR} ) diff --git a/examples/cpp/dds/SampleConfig_Events/README.txt b/examples/cpp/dds/SampleConfig_Events/README.txt index 885f13760b3..57515f0c7b0 100644 --- a/examples/cpp/dds/SampleConfig_Events/README.txt +++ b/examples/cpp/dds/SampleConfig_Events/README.txt @@ -80,7 +80,7 @@ Audio and Video transmission have a common characteristic: Having a stable, high - Distributed measurement: Controllers -Lets say we have a factory with a network of distributed temperature sensors and we want to use eProsima Fast RTPS to send data from said sensors to an automation computer which +Lets say we have a factory with a network of distributed temperature sensors and we want to use eProsima Fast DDS to send data from said sensors to an automation computer which makes decisions based on the temperature distribution. We would group all sensors within one single topic, Reliability: Reliable. We want to make sure samples are not lost. Furthermore, since reliable more ensures data delivery, it allows us to detect hardware problems when a sensor becomes silent diff --git a/examples/cpp/dds/SampleConfig_Events/sample.cxx b/examples/cpp/dds/SampleConfig_Events/sample.cxx deleted file mode 100644 index 360d4a1b2b2..00000000000 --- a/examples/cpp/dds/SampleConfig_Events/sample.cxx +++ /dev/null @@ -1,158 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file sample.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "sample.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - - - - -sample::sample() -{ -} - -sample::~sample() -{ -} - -sample::sample( - const sample& x) -{ - m_index = x.m_index; - m_key_value = x.m_key_value; -} - -sample::sample( - sample&& x) noexcept -{ - m_index = x.m_index; - m_key_value = x.m_key_value; -} - -sample& sample::operator =( - const sample& x) -{ - - m_index = x.m_index; - m_key_value = x.m_key_value; - return *this; -} - -sample& sample::operator =( - sample&& x) noexcept -{ - - m_index = x.m_index; - m_key_value = x.m_key_value; - return *this; -} - -bool sample::operator ==( - const sample& x) const -{ - return (m_index == x.m_index && - m_key_value == x.m_key_value); -} - -bool sample::operator !=( - const sample& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void sample::index( - uint8_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint8_t sample::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint8_t& sample::index() -{ - return m_index; -} - - -/*! - * @brief This function sets a value in member key_value - * @param _key_value New value for member key_value - */ -void sample::key_value( - uint8_t _key_value) -{ - m_key_value = _key_value; -} - -/*! - * @brief This function returns the value of member key_value - * @return Value of member key_value - */ -uint8_t sample::key_value() const -{ - return m_key_value; -} - -/*! - * @brief This function returns a reference to member key_value - * @return Reference to member key_value - */ -uint8_t& sample::key_value() -{ - return m_key_value; -} - - -// Include auxiliary functions like for serializing/deserializing. -#include "sampleCdrAux.ipp" - -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/SampleConfig_Events/sample.h b/examples/cpp/dds/SampleConfig_Events/sample.h deleted file mode 100644 index c050c8527cc..00000000000 --- a/examples/cpp/dds/SampleConfig_Events/sample.h +++ /dev/null @@ -1,188 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file sample.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#include -#include "samplev1.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#ifndef _FAST_DDS_GENERATED_SAMPLE_H_ -#define _FAST_DDS_GENERATED_SAMPLE_H_ - -#include -#include -#include -#include -#include -#include - -#include -#include -#include - - - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define eProsima_user_DllExport -#endif // _WIN32 - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(SAMPLE_SOURCE) -#define SAMPLE_DllAPI __declspec( dllexport ) -#else -#define SAMPLE_DllAPI __declspec( dllimport ) -#endif // SAMPLE_SOURCE -#else -#define SAMPLE_DllAPI -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define SAMPLE_DllAPI -#endif // _WIN32 - -namespace eprosima { -namespace fastcdr { -class Cdr; -class CdrSizeCalculator; -} // namespace fastcdr -} // namespace eprosima - - - - - -/*! - * @brief This class represents the structure sample defined by the user in the IDL file. - * @ingroup sample - */ -class sample -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport sample(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~sample(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object sample that will be copied. - */ - eProsima_user_DllExport sample( - const sample& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object sample that will be copied. - */ - eProsima_user_DllExport sample( - sample&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object sample that will be copied. - */ - eProsima_user_DllExport sample& operator =( - const sample& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object sample that will be copied. - */ - eProsima_user_DllExport sample& operator =( - sample&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x sample object to compare. - */ - eProsima_user_DllExport bool operator ==( - const sample& x) const; - - /*! - * @brief Comparison operator. - * @param x sample object to compare. - */ - eProsima_user_DllExport bool operator !=( - const sample& x) const; - - /*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ - eProsima_user_DllExport void index( - uint8_t _index); - - /*! - * @brief This function returns the value of member index - * @return Value of member index - */ - eProsima_user_DllExport uint8_t index() const; - - /*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ - eProsima_user_DllExport uint8_t& index(); - - - /*! - * @brief This function sets a value in member key_value - * @param _key_value New value for member key_value - */ - eProsima_user_DllExport void key_value( - uint8_t _key_value); - - /*! - * @brief This function returns the value of member key_value - * @return Value of member key_value - */ - eProsima_user_DllExport uint8_t key_value() const; - - /*! - * @brief This function returns a reference to member key_value - * @return Reference to member key_value - */ - eProsima_user_DllExport uint8_t& key_value(); - -private: - - uint8_t m_index{0}; - uint8_t m_key_value{0}; - -}; - -#endif // _FAST_DDS_GENERATED_SAMPLE_H_ - - - -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/SampleConfig_Events/sample.hpp b/examples/cpp/dds/SampleConfig_Events/sample.hpp new file mode 100644 index 00000000000..3023a792269 --- /dev/null +++ b/examples/cpp/dds/SampleConfig_Events/sample.hpp @@ -0,0 +1,215 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file sample.hpp + * This header file contains the declaration of the described types in the IDL file. + * + * This file was generated by the tool fastddsgen. + */ + +#ifndef _FAST_DDS_GENERATED_SAMPLE_HPP_ +#define _FAST_DDS_GENERATED_SAMPLE_HPP_ + +#include +#include + +#if defined(_WIN32) +#if defined(EPROSIMA_USER_DLL_EXPORT) +#define eProsima_user_DllExport __declspec( dllexport ) +#else +#define eProsima_user_DllExport +#endif // EPROSIMA_USER_DLL_EXPORT +#else +#define eProsima_user_DllExport +#endif // _WIN32 + +#if defined(_WIN32) +#if defined(EPROSIMA_USER_DLL_EXPORT) +#if defined(SAMPLE_SOURCE) +#define SAMPLE_DllAPI __declspec( dllexport ) +#else +#define SAMPLE_DllAPI __declspec( dllimport ) +#endif // SAMPLE_SOURCE +#else +#define SAMPLE_DllAPI +#endif // EPROSIMA_USER_DLL_EXPORT +#else +#define SAMPLE_DllAPI +#endif // _WIN32 + +/*! + * @brief This class represents the structure sample defined by the user in the IDL file. + * @ingroup sample + */ +class sample +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport sample() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~sample() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object sample that will be copied. + */ + eProsima_user_DllExport sample( + const sample& x) + { + m_index = x.m_index; + + m_key_value = x.m_key_value; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object sample that will be copied. + */ + eProsima_user_DllExport sample( + sample&& x) noexcept + { + m_index = x.m_index; + m_key_value = x.m_key_value; + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object sample that will be copied. + */ + eProsima_user_DllExport sample& operator =( + const sample& x) + { + + m_index = x.m_index; + + m_key_value = x.m_key_value; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object sample that will be copied. + */ + eProsima_user_DllExport sample& operator =( + sample&& x) noexcept + { + + m_index = x.m_index; + m_key_value = x.m_key_value; + return *this; + } + + /*! + * @brief Comparison operator. + * @param x sample object to compare. + */ + eProsima_user_DllExport bool operator ==( + const sample& x) const + { + return (m_index == x.m_index && + m_key_value == x.m_key_value); + } + + /*! + * @brief Comparison operator. + * @param x sample object to compare. + */ + eProsima_user_DllExport bool operator !=( + const sample& x) const + { + return !(*this == x); + } + + /*! + * @brief This function sets a value in member index + * @param _index New value for member index + */ + eProsima_user_DllExport void index( + uint8_t _index) + { + m_index = _index; + } + + /*! + * @brief This function returns the value of member index + * @return Value of member index + */ + eProsima_user_DllExport uint8_t index() const + { + return m_index; + } + + /*! + * @brief This function returns a reference to member index + * @return Reference to member index + */ + eProsima_user_DllExport uint8_t& index() + { + return m_index; + } + + + /*! + * @brief This function sets a value in member key_value + * @param _key_value New value for member key_value + */ + eProsima_user_DllExport void key_value( + uint8_t _key_value) + { + m_key_value = _key_value; + } + + /*! + * @brief This function returns the value of member key_value + * @return Value of member key_value + */ + eProsima_user_DllExport uint8_t key_value() const + { + return m_key_value; + } + + /*! + * @brief This function returns a reference to member key_value + * @return Reference to member key_value + */ + eProsima_user_DllExport uint8_t& key_value() + { + return m_key_value; + } + + + +private: + + uint8_t m_index{0}; + uint8_t m_key_value{0}; + +}; + +#endif // _FAST_DDS_GENERATED_SAMPLE_HPP_ + + diff --git a/examples/cpp/dds/SampleConfig_Events/sampleCdrAux.hpp b/examples/cpp/dds/SampleConfig_Events/sampleCdrAux.hpp index 18ed5857add..b80dff31248 100644 --- a/examples/cpp/dds/SampleConfig_Events/sampleCdrAux.hpp +++ b/examples/cpp/dds/SampleConfig_Events/sampleCdrAux.hpp @@ -22,7 +22,7 @@ #ifndef _FAST_DDS_GENERATED_SAMPLECDRAUX_HPP_ #define _FAST_DDS_GENERATED_SAMPLECDRAUX_HPP_ -#include "sample.h" +#include "sample.hpp" constexpr uint32_t sample_max_cdr_typesize {6UL}; constexpr uint32_t sample_max_key_cdr_typesize {1UL}; @@ -34,8 +34,6 @@ namespace fastcdr { class Cdr; class CdrSizeCalculator; - - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const sample& data); diff --git a/examples/cpp/dds/SampleConfig_Events/sampleCdrAux.ipp b/examples/cpp/dds/SampleConfig_Events/sampleCdrAux.ipp index 11bc4709a6e..17a3d1025fc 100644 --- a/examples/cpp/dds/SampleConfig_Events/sampleCdrAux.ipp +++ b/examples/cpp/dds/SampleConfig_Events/sampleCdrAux.ipp @@ -34,8 +34,6 @@ using namespace eprosima::fastcdr::exception; namespace eprosima { namespace fastcdr { - - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, diff --git a/examples/cpp/dds/SampleConfig_Events/samplePubSubTypes.cxx b/examples/cpp/dds/SampleConfig_Events/samplePubSubTypes.cxx index 9095d77083a..cae143a08ca 100644 --- a/examples/cpp/dds/SampleConfig_Events/samplePubSubTypes.cxx +++ b/examples/cpp/dds/SampleConfig_Events/samplePubSubTypes.cxx @@ -19,18 +19,18 @@ * This file was generated by the tool fastddsgen. */ +#include "samplePubSubTypes.h" +#include #include -#include "samplePubSubTypes.h" #include "sampleCdrAux.hpp" +#include "sampleTypeObjectSupport.hpp" using SerializedPayload_t = eprosima::fastrtps::rtps::SerializedPayload_t; using InstanceHandle_t = eprosima::fastrtps::rtps::InstanceHandle_t; using DataRepresentationId_t = eprosima::fastdds::dds::DataRepresentationId_t; - - samplePubSubType::samplePubSubType() { setName("sample"); @@ -219,3 +219,11 @@ bool samplePubSubType::getKey( return true; } +void samplePubSubType::register_type_object_representation() const +{ + register_sample_type_objects(); +} + + +// Include auxiliary functions like for serializing/deserializing. +#include "sampleCdrAux.ipp" diff --git a/examples/cpp/dds/SampleConfig_Events/samplePubSubTypes.h b/examples/cpp/dds/SampleConfig_Events/samplePubSubTypes.h index ec881115211..9e59aa58042 100644 --- a/examples/cpp/dds/SampleConfig_Events/samplePubSubTypes.h +++ b/examples/cpp/dds/SampleConfig_Events/samplePubSubTypes.h @@ -27,9 +27,9 @@ #include #include #include -#include +#include -#include "sample.h" +#include "sample.hpp" #if !defined(GEN_API_VER) || (GEN_API_VER != 2) @@ -38,8 +38,6 @@ #endif // GEN_API_VER - - /*! * @brief This class represents the TopicDataType of the type sample defined by the user in the IDL file. * @ingroup sample @@ -90,6 +88,9 @@ class samplePubSubType : public eprosima::fastdds::dds::TopicDataType eProsima_user_DllExport void deleteData( void* data) override; + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + #ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED eProsima_user_DllExport inline bool is_bounded() const override { diff --git a/examples/cpp/dds/SampleConfig_Events/sampleTypeObjectSupport.cxx b/examples/cpp/dds/SampleConfig_Events/sampleTypeObjectSupport.cxx new file mode 100644 index 00000000000..3719bbf77e6 --- /dev/null +++ b/examples/cpp/dds/SampleConfig_Events/sampleTypeObjectSupport.cxx @@ -0,0 +1,224 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file sampleTypeObjectSupport.cxx + * Source file containing the implementation to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#include "sampleTypeObjectSupport.hpp" + +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include + +#include "sample.hpp" + + +using namespace eprosima::fastdds::dds::xtypes; + +void register_sample_type_objects() +{ + static std::once_flag once_flag; + std::call_once(once_flag, []() + { + register_sample_type_identifier(); + + }); +} + +void register_sample_type_identifier() +{ + { + StructTypeFlag struct_flags_sample = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::NOT_APPLIED, + false, false); + ReturnCode_t return_code_sample; + TypeIdentifierPair type_ids_sample; + QualifiedTypeName type_name_sample = "sample"; + eprosima::fastcdr::optional type_ann_builtin_sample; + eprosima::fastcdr::optional ann_custom_sample; + CompleteTypeDetail detail_sample = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_sample, ann_custom_sample, type_name_sample.to_string()); + CompleteStructHeader header_sample; + header_sample = TypeObjectUtils::build_complete_struct_header(TypeIdentifier(), detail_sample); + CompleteStructMemberSeq member_seq_sample; + { + return_code_sample = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_byte", type_ids_sample); + + if (return_code_sample != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "index Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_index = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_index; + MemberId member_id_index = 0x00000000; + if (EK_COMPLETE == type_ids_sample.type_identifier1()._d() || TK_NONE == type_ids_sample.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_sample.type_identifier1()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_sample.type_identifier1()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_sample.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_sample.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_sample.type_identifier2()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_sample.type_identifier2()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_sample.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure index member TypeIdentifier inconsistent."); + return; + } + MemberName name_index = "index"; + eprosima::fastcdr::optional member_ann_builtin_index; + ann_custom_sample.reset(); + CompleteMemberDetail detail_index = TypeObjectUtils::build_complete_member_detail(name_index, member_ann_builtin_index, ann_custom_sample); + CompleteStructMember member_index = TypeObjectUtils::build_complete_struct_member(common_index, detail_index); + TypeObjectUtils::add_complete_struct_member(member_seq_sample, member_index); + } + { + return_code_sample = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_byte", type_ids_sample); + + if (return_code_sample != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "key_value Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_key_value = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, true, false); + CommonStructMember common_key_value; + MemberId member_id_key_value = 0x00000001; + if (EK_COMPLETE == type_ids_sample.type_identifier1()._d() || TK_NONE == type_ids_sample.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_sample.type_identifier1()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_sample.type_identifier1()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_key_value = TypeObjectUtils::build_common_struct_member(member_id_key_value, member_flags_key_value, type_ids_sample.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_sample.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_sample.type_identifier2()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_sample.type_identifier2()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_key_value = TypeObjectUtils::build_common_struct_member(member_id_key_value, member_flags_key_value, type_ids_sample.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure key_value member TypeIdentifier inconsistent."); + return; + } + MemberName name_key_value = "key_value"; + eprosima::fastcdr::optional member_ann_builtin_key_value; + ann_custom_sample.reset(); + AppliedAnnotationSeq tmp_ann_custom_key_value; + eprosima::fastcdr::optional unit_key_value; + eprosima::fastcdr::optional min_key_value; + eprosima::fastcdr::optional max_key_value; + eprosima::fastcdr::optional hash_id_key_value; + if (unit_key_value.has_value() || min_key_value.has_value() || max_key_value.has_value() || hash_id_key_value.has_value()) + { + member_ann_builtin_key_value = TypeObjectUtils::build_applied_builtin_member_annotations(unit_key_value, min_key_value, max_key_value, hash_id_key_value); + } + if (!tmp_ann_custom_key_value.empty()) + { + ann_custom_sample = tmp_ann_custom_key_value; + } + CompleteMemberDetail detail_key_value = TypeObjectUtils::build_complete_member_detail(name_key_value, member_ann_builtin_key_value, ann_custom_sample); + CompleteStructMember member_key_value = TypeObjectUtils::build_complete_struct_member(common_key_value, detail_key_value); + TypeObjectUtils::add_complete_struct_member(member_seq_sample, member_key_value); + } + CompleteStructType struct_type_sample = TypeObjectUtils::build_complete_struct_type(struct_flags_sample, header_sample, member_seq_sample); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_struct_type_object(struct_type_sample, type_name_sample.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "sample already registered in TypeObjectRegistry for a different type."); + } + return_code_sample = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "sample", type_ids_sample); + if (return_code_sample != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "sample: Given Struct TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } +} + diff --git a/examples/cpp/dds/SampleConfig_Events/sampleTypeObjectSupport.hpp b/examples/cpp/dds/SampleConfig_Events/sampleTypeObjectSupport.hpp new file mode 100644 index 00000000000..5ad7f2e5e07 --- /dev/null +++ b/examples/cpp/dds/SampleConfig_Events/sampleTypeObjectSupport.hpp @@ -0,0 +1,54 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file sampleTypeObjectSupport.hpp + * Header file containing the API required to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#ifndef _FAST_DDS_GENERATED_SAMPLE_TYPE_OBJECT_SUPPORT_HPP_ +#define _FAST_DDS_GENERATED_SAMPLE_TYPE_OBJECT_SUPPORT_HPP_ + + +#if defined(_WIN32) +#if defined(EPROSIMA_USER_DLL_EXPORT) +#define eProsima_user_DllExport __declspec( dllexport ) +#else +#define eProsima_user_DllExport +#endif // EPROSIMA_USER_DLL_EXPORT +#else +#define eProsima_user_DllExport +#endif // _WIN32 + +/** + * @brief Register every TypeObject representation defined in the IDL file in Fast DDS TypeObjectRegistry. + */ +eProsima_user_DllExport void register_sample_type_objects(); + +#ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +/** + * @brief Register sample related TypeIdentifier. + * Fully-descriptive TypeIdentifiers are directly registered. + * Hash TypeIdentifiers require to fill the TypeObject information and hash it, consequently, the TypeObject is + * indirectly registered as well. + */ +void register_sample_type_identifier(); + + +#endif // DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +#endif // _FAST_DDS_GENERATED_SAMPLE_TYPE_OBJECT_SUPPORT_HPP_ diff --git a/examples/cpp/dds/SampleConfig_Events/sampleconfig_triggers.cpp b/examples/cpp/dds/SampleConfig_Events/sampleconfig_triggers.cpp index 97641f71866..72059ffa468 100644 --- a/examples/cpp/dds/SampleConfig_Events/sampleconfig_triggers.cpp +++ b/examples/cpp/dds/SampleConfig_Events/sampleconfig_triggers.cpp @@ -156,7 +156,7 @@ void triggers() //Read the contents of both histories: std::cout << "The Subscriber holds: " << std::endl; - while (myReader->take_next_sample(&my_sample, &sample_info) == ReturnCode_t::RETCODE_OK) + while (myReader->take_next_sample(&my_sample, &sample_info) == RETCODE_OK) { std::cout << std::to_string(my_sample.index()) << " "; } diff --git a/examples/cpp/dds/SampleConfig_Events/samplev1.cxx b/examples/cpp/dds/SampleConfig_Events/samplev1.cxx deleted file mode 100644 index 3b735befaf8..00000000000 --- a/examples/cpp/dds/SampleConfig_Events/samplev1.cxx +++ /dev/null @@ -1,280 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file sample.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "sample.h" - -#if FASTCDR_VERSION_MAJOR == 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - -namespace helper { namespace internal { - -enum class Size { - UInt8, - UInt16, - UInt32, - UInt64, -}; - -constexpr Size get_size(int s) { - return (s <= 8 ) ? Size::UInt8: - (s <= 16) ? Size::UInt16: - (s <= 32) ? Size::UInt32: Size::UInt64; -} - -template -struct FindTypeH; - -template<> -struct FindTypeH { - using type = std::uint8_t; -}; - -template<> -struct FindTypeH { - using type = std::uint16_t; -}; - -template<> -struct FindTypeH { - using type = std::uint32_t; -}; - -template<> -struct FindTypeH { - using type = std::uint64_t; -}; -} - -template -struct FindType { - using type = typename internal::FindTypeH::type; -}; -} - -#define sample_max_cdr_typesize 6ULL; - - - - -sample::sample() -{ - // octet m_index - m_index = 0; - // octet m_key_value - m_key_value = 0; - -} - -sample::~sample() -{ -} - -sample::sample( - const sample& x) -{ - m_index = x.m_index; - - - m_key_value = x.m_key_value; - -} - -sample::sample( - sample&& x) noexcept -{ - m_index = x.m_index; - - - m_key_value = x.m_key_value; - -} - -sample& sample::operator =( - const sample& x) -{ - m_index = x.m_index; - - - m_key_value = x.m_key_value; - - return *this; -} - -sample& sample::operator =( - sample&& x) noexcept -{ - m_index = x.m_index; - - - m_key_value = x.m_key_value; - - return *this; -} - -bool sample::operator ==( - const sample& x) const -{ - return (m_index == x.m_index && - m_key_value == x.m_key_value); -} - -bool sample::operator !=( - const sample& x) const -{ - return !(*this == x); -} - -size_t sample::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return sample_max_cdr_typesize; -} - -size_t sample::getCdrSerializedSize( - const sample& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - return current_alignment - initial_alignment; -} - - -void sample::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_index; - - scdr << m_key_value; - -} - -void sample::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_index; - - - - dcdr >> m_key_value; - - -} - - -bool sample::isKeyDefined() -{ - return true; -} - -void sample::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; - - - scdr << m_key_value; - -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void sample::index( - uint8_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint8_t sample::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint8_t& sample::index() -{ - return m_index; -} - - -/*! - * @brief This function sets a value in member key_value - * @param _key_value New value for member key_value - */ -void sample::key_value( - uint8_t _key_value) -{ - m_key_value = _key_value; -} - -/*! - * @brief This function returns the value of member key_value - * @return Value of member key_value - */ -uint8_t sample::key_value() const -{ - return m_key_value; -} - -/*! - * @brief This function returns a reference to member key_value - * @return Reference to member key_value - */ -uint8_t& sample::key_value() -{ - return m_key_value; -} - - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/SampleConfig_Events/samplev1.h b/examples/cpp/dds/SampleConfig_Events/samplev1.h deleted file mode 100644 index 4fa288d1bc9..00000000000 --- a/examples/cpp/dds/SampleConfig_Events/samplev1.h +++ /dev/null @@ -1,237 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file sample.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#include - -#if FASTCDR_VERSION_MAJOR == 1 - -#ifndef _FAST_DDS_GENERATED_SAMPLE_H_ -#define _FAST_DDS_GENERATED_SAMPLE_H_ - - -#include - -#include -#include -#include -#include -#include -#include -#include - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define eProsima_user_DllExport -#endif // _WIN32 - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(SAMPLE_SOURCE) -#define SAMPLE_DllAPI __declspec( dllexport ) -#else -#define SAMPLE_DllAPI __declspec( dllimport ) -#endif // SAMPLE_SOURCE -#else -#define SAMPLE_DllAPI -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define SAMPLE_DllAPI -#endif // _WIN32 - -namespace eprosima { -namespace fastcdr { -class Cdr; -} // namespace fastcdr -} // namespace eprosima - - - - - -/*! - * @brief This class represents the structure sample defined by the user in the IDL file. - * @ingroup sample - */ -class sample -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport sample(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~sample(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object sample that will be copied. - */ - eProsima_user_DllExport sample( - const sample& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object sample that will be copied. - */ - eProsima_user_DllExport sample( - sample&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object sample that will be copied. - */ - eProsima_user_DllExport sample& operator =( - const sample& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object sample that will be copied. - */ - eProsima_user_DllExport sample& operator =( - sample&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x sample object to compare. - */ - eProsima_user_DllExport bool operator ==( - const sample& x) const; - - /*! - * @brief Comparison operator. - * @param x sample object to compare. - */ - eProsima_user_DllExport bool operator !=( - const sample& x) const; - - /*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ - eProsima_user_DllExport void index( - uint8_t _index); - - /*! - * @brief This function returns the value of member index - * @return Value of member index - */ - eProsima_user_DllExport uint8_t index() const; - - /*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ - eProsima_user_DllExport uint8_t& index(); - - - /*! - * @brief This function sets a value in member key_value - * @param _key_value New value for member key_value - */ - eProsima_user_DllExport void key_value( - uint8_t _key_value); - - /*! - * @brief This function returns the value of member key_value - * @return Value of member key_value - */ - eProsima_user_DllExport uint8_t key_value() const; - - /*! - * @brief This function returns a reference to member key_value - * @return Reference to member key_value - */ - eProsima_user_DllExport uint8_t& key_value(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const sample& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - uint8_t m_index; - uint8_t m_key_value; - -}; - - -#endif // _FAST_DDS_GENERATED_SAMPLE_H_ - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/SampleConfig_Multimedia/CMakeLists.txt b/examples/cpp/dds/SampleConfig_Multimedia/CMakeLists.txt index 19862018d38..22d59bfdaac 100644 --- a/examples/cpp/dds/SampleConfig_Multimedia/CMakeLists.txt +++ b/examples/cpp/dds/SampleConfig_Multimedia/CMakeLists.txt @@ -25,8 +25,8 @@ if(NOT foonathan_memory_FOUND) find_package(foonathan_memory REQUIRED) endif() -if(NOT fastrtps_FOUND) - find_package(fastrtps 2.12 REQUIRED) +if(NOT fastdds_FOUND) + find_package(fastdds 3 REQUIRED) endif() #Check C++11 @@ -46,7 +46,7 @@ target_compile_definitions(DDSSampleConfig_Multimedia PRIVATE $<$>,$>:__DEBUG> $<$:__INTERNALDEBUG> # Internal debug activated. ) -target_link_libraries(DDSSampleConfig_Multimedia fastrtps fastcdr foonathan_memory) +target_link_libraries(DDSSampleConfig_Multimedia fastdds fastcdr foonathan_memory) install(TARGETS DDSSampleConfig_Multimedia RUNTIME DESTINATION examples/cpp/dds/SampleConfig_Multimedia/${BIN_INSTALL_DIR} ) diff --git a/examples/cpp/dds/SampleConfig_Multimedia/README.txt b/examples/cpp/dds/SampleConfig_Multimedia/README.txt index 59c6346b9cf..542a16db64f 100644 --- a/examples/cpp/dds/SampleConfig_Multimedia/README.txt +++ b/examples/cpp/dds/SampleConfig_Multimedia/README.txt @@ -80,7 +80,7 @@ Audio and Video transmission have a common characteristic: Having a stable, high - Distributed measurement: Controllers -Lets say we have a factory with a network of distributed temperature sensors and we want to use eProsima Fast RTPS to send data from said sensors to an automation computer which +Lets say we have a factory with a network of distributed temperature sensors and we want to use eProsima Fast DDS to send data from said sensors to an automation computer which makes decisions based on the temperature distribution. We would group all sensors within one single topic, Reliability: Reliable. We want to make sure samples are not lost. Furthermore, since reliable more ensures data delivery, it allows us to detect hardware problems when a sensor becomes silent diff --git a/examples/cpp/dds/SampleConfig_Multimedia/sample.cxx b/examples/cpp/dds/SampleConfig_Multimedia/sample.cxx deleted file mode 100644 index 360d4a1b2b2..00000000000 --- a/examples/cpp/dds/SampleConfig_Multimedia/sample.cxx +++ /dev/null @@ -1,158 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file sample.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "sample.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - - - - -sample::sample() -{ -} - -sample::~sample() -{ -} - -sample::sample( - const sample& x) -{ - m_index = x.m_index; - m_key_value = x.m_key_value; -} - -sample::sample( - sample&& x) noexcept -{ - m_index = x.m_index; - m_key_value = x.m_key_value; -} - -sample& sample::operator =( - const sample& x) -{ - - m_index = x.m_index; - m_key_value = x.m_key_value; - return *this; -} - -sample& sample::operator =( - sample&& x) noexcept -{ - - m_index = x.m_index; - m_key_value = x.m_key_value; - return *this; -} - -bool sample::operator ==( - const sample& x) const -{ - return (m_index == x.m_index && - m_key_value == x.m_key_value); -} - -bool sample::operator !=( - const sample& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void sample::index( - uint8_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint8_t sample::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint8_t& sample::index() -{ - return m_index; -} - - -/*! - * @brief This function sets a value in member key_value - * @param _key_value New value for member key_value - */ -void sample::key_value( - uint8_t _key_value) -{ - m_key_value = _key_value; -} - -/*! - * @brief This function returns the value of member key_value - * @return Value of member key_value - */ -uint8_t sample::key_value() const -{ - return m_key_value; -} - -/*! - * @brief This function returns a reference to member key_value - * @return Reference to member key_value - */ -uint8_t& sample::key_value() -{ - return m_key_value; -} - - -// Include auxiliary functions like for serializing/deserializing. -#include "sampleCdrAux.ipp" - -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/SampleConfig_Multimedia/sample.h b/examples/cpp/dds/SampleConfig_Multimedia/sample.h deleted file mode 100644 index c050c8527cc..00000000000 --- a/examples/cpp/dds/SampleConfig_Multimedia/sample.h +++ /dev/null @@ -1,188 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file sample.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#include -#include "samplev1.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#ifndef _FAST_DDS_GENERATED_SAMPLE_H_ -#define _FAST_DDS_GENERATED_SAMPLE_H_ - -#include -#include -#include -#include -#include -#include - -#include -#include -#include - - - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define eProsima_user_DllExport -#endif // _WIN32 - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(SAMPLE_SOURCE) -#define SAMPLE_DllAPI __declspec( dllexport ) -#else -#define SAMPLE_DllAPI __declspec( dllimport ) -#endif // SAMPLE_SOURCE -#else -#define SAMPLE_DllAPI -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define SAMPLE_DllAPI -#endif // _WIN32 - -namespace eprosima { -namespace fastcdr { -class Cdr; -class CdrSizeCalculator; -} // namespace fastcdr -} // namespace eprosima - - - - - -/*! - * @brief This class represents the structure sample defined by the user in the IDL file. - * @ingroup sample - */ -class sample -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport sample(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~sample(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object sample that will be copied. - */ - eProsima_user_DllExport sample( - const sample& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object sample that will be copied. - */ - eProsima_user_DllExport sample( - sample&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object sample that will be copied. - */ - eProsima_user_DllExport sample& operator =( - const sample& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object sample that will be copied. - */ - eProsima_user_DllExport sample& operator =( - sample&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x sample object to compare. - */ - eProsima_user_DllExport bool operator ==( - const sample& x) const; - - /*! - * @brief Comparison operator. - * @param x sample object to compare. - */ - eProsima_user_DllExport bool operator !=( - const sample& x) const; - - /*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ - eProsima_user_DllExport void index( - uint8_t _index); - - /*! - * @brief This function returns the value of member index - * @return Value of member index - */ - eProsima_user_DllExport uint8_t index() const; - - /*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ - eProsima_user_DllExport uint8_t& index(); - - - /*! - * @brief This function sets a value in member key_value - * @param _key_value New value for member key_value - */ - eProsima_user_DllExport void key_value( - uint8_t _key_value); - - /*! - * @brief This function returns the value of member key_value - * @return Value of member key_value - */ - eProsima_user_DllExport uint8_t key_value() const; - - /*! - * @brief This function returns a reference to member key_value - * @return Reference to member key_value - */ - eProsima_user_DllExport uint8_t& key_value(); - -private: - - uint8_t m_index{0}; - uint8_t m_key_value{0}; - -}; - -#endif // _FAST_DDS_GENERATED_SAMPLE_H_ - - - -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/SampleConfig_Multimedia/sample.hpp b/examples/cpp/dds/SampleConfig_Multimedia/sample.hpp new file mode 100644 index 00000000000..3023a792269 --- /dev/null +++ b/examples/cpp/dds/SampleConfig_Multimedia/sample.hpp @@ -0,0 +1,215 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file sample.hpp + * This header file contains the declaration of the described types in the IDL file. + * + * This file was generated by the tool fastddsgen. + */ + +#ifndef _FAST_DDS_GENERATED_SAMPLE_HPP_ +#define _FAST_DDS_GENERATED_SAMPLE_HPP_ + +#include +#include + +#if defined(_WIN32) +#if defined(EPROSIMA_USER_DLL_EXPORT) +#define eProsima_user_DllExport __declspec( dllexport ) +#else +#define eProsima_user_DllExport +#endif // EPROSIMA_USER_DLL_EXPORT +#else +#define eProsima_user_DllExport +#endif // _WIN32 + +#if defined(_WIN32) +#if defined(EPROSIMA_USER_DLL_EXPORT) +#if defined(SAMPLE_SOURCE) +#define SAMPLE_DllAPI __declspec( dllexport ) +#else +#define SAMPLE_DllAPI __declspec( dllimport ) +#endif // SAMPLE_SOURCE +#else +#define SAMPLE_DllAPI +#endif // EPROSIMA_USER_DLL_EXPORT +#else +#define SAMPLE_DllAPI +#endif // _WIN32 + +/*! + * @brief This class represents the structure sample defined by the user in the IDL file. + * @ingroup sample + */ +class sample +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport sample() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~sample() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object sample that will be copied. + */ + eProsima_user_DllExport sample( + const sample& x) + { + m_index = x.m_index; + + m_key_value = x.m_key_value; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object sample that will be copied. + */ + eProsima_user_DllExport sample( + sample&& x) noexcept + { + m_index = x.m_index; + m_key_value = x.m_key_value; + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object sample that will be copied. + */ + eProsima_user_DllExport sample& operator =( + const sample& x) + { + + m_index = x.m_index; + + m_key_value = x.m_key_value; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object sample that will be copied. + */ + eProsima_user_DllExport sample& operator =( + sample&& x) noexcept + { + + m_index = x.m_index; + m_key_value = x.m_key_value; + return *this; + } + + /*! + * @brief Comparison operator. + * @param x sample object to compare. + */ + eProsima_user_DllExport bool operator ==( + const sample& x) const + { + return (m_index == x.m_index && + m_key_value == x.m_key_value); + } + + /*! + * @brief Comparison operator. + * @param x sample object to compare. + */ + eProsima_user_DllExport bool operator !=( + const sample& x) const + { + return !(*this == x); + } + + /*! + * @brief This function sets a value in member index + * @param _index New value for member index + */ + eProsima_user_DllExport void index( + uint8_t _index) + { + m_index = _index; + } + + /*! + * @brief This function returns the value of member index + * @return Value of member index + */ + eProsima_user_DllExport uint8_t index() const + { + return m_index; + } + + /*! + * @brief This function returns a reference to member index + * @return Reference to member index + */ + eProsima_user_DllExport uint8_t& index() + { + return m_index; + } + + + /*! + * @brief This function sets a value in member key_value + * @param _key_value New value for member key_value + */ + eProsima_user_DllExport void key_value( + uint8_t _key_value) + { + m_key_value = _key_value; + } + + /*! + * @brief This function returns the value of member key_value + * @return Value of member key_value + */ + eProsima_user_DllExport uint8_t key_value() const + { + return m_key_value; + } + + /*! + * @brief This function returns a reference to member key_value + * @return Reference to member key_value + */ + eProsima_user_DllExport uint8_t& key_value() + { + return m_key_value; + } + + + +private: + + uint8_t m_index{0}; + uint8_t m_key_value{0}; + +}; + +#endif // _FAST_DDS_GENERATED_SAMPLE_HPP_ + + diff --git a/examples/cpp/dds/SampleConfig_Multimedia/sampleCdrAux.hpp b/examples/cpp/dds/SampleConfig_Multimedia/sampleCdrAux.hpp index 18ed5857add..b80dff31248 100644 --- a/examples/cpp/dds/SampleConfig_Multimedia/sampleCdrAux.hpp +++ b/examples/cpp/dds/SampleConfig_Multimedia/sampleCdrAux.hpp @@ -22,7 +22,7 @@ #ifndef _FAST_DDS_GENERATED_SAMPLECDRAUX_HPP_ #define _FAST_DDS_GENERATED_SAMPLECDRAUX_HPP_ -#include "sample.h" +#include "sample.hpp" constexpr uint32_t sample_max_cdr_typesize {6UL}; constexpr uint32_t sample_max_key_cdr_typesize {1UL}; @@ -34,8 +34,6 @@ namespace fastcdr { class Cdr; class CdrSizeCalculator; - - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const sample& data); diff --git a/examples/cpp/dds/SampleConfig_Multimedia/sampleCdrAux.ipp b/examples/cpp/dds/SampleConfig_Multimedia/sampleCdrAux.ipp index 11bc4709a6e..17a3d1025fc 100644 --- a/examples/cpp/dds/SampleConfig_Multimedia/sampleCdrAux.ipp +++ b/examples/cpp/dds/SampleConfig_Multimedia/sampleCdrAux.ipp @@ -34,8 +34,6 @@ using namespace eprosima::fastcdr::exception; namespace eprosima { namespace fastcdr { - - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, diff --git a/examples/cpp/dds/SampleConfig_Multimedia/samplePubSubTypes.cxx b/examples/cpp/dds/SampleConfig_Multimedia/samplePubSubTypes.cxx index 9095d77083a..cae143a08ca 100644 --- a/examples/cpp/dds/SampleConfig_Multimedia/samplePubSubTypes.cxx +++ b/examples/cpp/dds/SampleConfig_Multimedia/samplePubSubTypes.cxx @@ -19,18 +19,18 @@ * This file was generated by the tool fastddsgen. */ +#include "samplePubSubTypes.h" +#include #include -#include "samplePubSubTypes.h" #include "sampleCdrAux.hpp" +#include "sampleTypeObjectSupport.hpp" using SerializedPayload_t = eprosima::fastrtps::rtps::SerializedPayload_t; using InstanceHandle_t = eprosima::fastrtps::rtps::InstanceHandle_t; using DataRepresentationId_t = eprosima::fastdds::dds::DataRepresentationId_t; - - samplePubSubType::samplePubSubType() { setName("sample"); @@ -219,3 +219,11 @@ bool samplePubSubType::getKey( return true; } +void samplePubSubType::register_type_object_representation() const +{ + register_sample_type_objects(); +} + + +// Include auxiliary functions like for serializing/deserializing. +#include "sampleCdrAux.ipp" diff --git a/examples/cpp/dds/SampleConfig_Multimedia/samplePubSubTypes.h b/examples/cpp/dds/SampleConfig_Multimedia/samplePubSubTypes.h index ec881115211..9e59aa58042 100644 --- a/examples/cpp/dds/SampleConfig_Multimedia/samplePubSubTypes.h +++ b/examples/cpp/dds/SampleConfig_Multimedia/samplePubSubTypes.h @@ -27,9 +27,9 @@ #include #include #include -#include +#include -#include "sample.h" +#include "sample.hpp" #if !defined(GEN_API_VER) || (GEN_API_VER != 2) @@ -38,8 +38,6 @@ #endif // GEN_API_VER - - /*! * @brief This class represents the TopicDataType of the type sample defined by the user in the IDL file. * @ingroup sample @@ -90,6 +88,9 @@ class samplePubSubType : public eprosima::fastdds::dds::TopicDataType eProsima_user_DllExport void deleteData( void* data) override; + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + #ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED eProsima_user_DllExport inline bool is_bounded() const override { diff --git a/examples/cpp/dds/SampleConfig_Multimedia/sampleTypeObjectSupport.cxx b/examples/cpp/dds/SampleConfig_Multimedia/sampleTypeObjectSupport.cxx new file mode 100644 index 00000000000..3719bbf77e6 --- /dev/null +++ b/examples/cpp/dds/SampleConfig_Multimedia/sampleTypeObjectSupport.cxx @@ -0,0 +1,224 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file sampleTypeObjectSupport.cxx + * Source file containing the implementation to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#include "sampleTypeObjectSupport.hpp" + +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include + +#include "sample.hpp" + + +using namespace eprosima::fastdds::dds::xtypes; + +void register_sample_type_objects() +{ + static std::once_flag once_flag; + std::call_once(once_flag, []() + { + register_sample_type_identifier(); + + }); +} + +void register_sample_type_identifier() +{ + { + StructTypeFlag struct_flags_sample = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::NOT_APPLIED, + false, false); + ReturnCode_t return_code_sample; + TypeIdentifierPair type_ids_sample; + QualifiedTypeName type_name_sample = "sample"; + eprosima::fastcdr::optional type_ann_builtin_sample; + eprosima::fastcdr::optional ann_custom_sample; + CompleteTypeDetail detail_sample = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_sample, ann_custom_sample, type_name_sample.to_string()); + CompleteStructHeader header_sample; + header_sample = TypeObjectUtils::build_complete_struct_header(TypeIdentifier(), detail_sample); + CompleteStructMemberSeq member_seq_sample; + { + return_code_sample = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_byte", type_ids_sample); + + if (return_code_sample != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "index Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_index = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_index; + MemberId member_id_index = 0x00000000; + if (EK_COMPLETE == type_ids_sample.type_identifier1()._d() || TK_NONE == type_ids_sample.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_sample.type_identifier1()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_sample.type_identifier1()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_sample.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_sample.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_sample.type_identifier2()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_sample.type_identifier2()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_sample.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure index member TypeIdentifier inconsistent."); + return; + } + MemberName name_index = "index"; + eprosima::fastcdr::optional member_ann_builtin_index; + ann_custom_sample.reset(); + CompleteMemberDetail detail_index = TypeObjectUtils::build_complete_member_detail(name_index, member_ann_builtin_index, ann_custom_sample); + CompleteStructMember member_index = TypeObjectUtils::build_complete_struct_member(common_index, detail_index); + TypeObjectUtils::add_complete_struct_member(member_seq_sample, member_index); + } + { + return_code_sample = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_byte", type_ids_sample); + + if (return_code_sample != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "key_value Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_key_value = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, true, false); + CommonStructMember common_key_value; + MemberId member_id_key_value = 0x00000001; + if (EK_COMPLETE == type_ids_sample.type_identifier1()._d() || TK_NONE == type_ids_sample.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_sample.type_identifier1()._d() && + EK_COMPLETE == type_ids_sample.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_sample.type_identifier1()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_sample.type_identifier1()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_key_value = TypeObjectUtils::build_common_struct_member(member_id_key_value, member_flags_key_value, type_ids_sample.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_sample.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_sample.type_identifier2()._d() && + EK_COMPLETE == type_ids_sample.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_sample.type_identifier2()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_sample.type_identifier2()._d() && + (EK_COMPLETE == type_ids_sample.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_sample.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_key_value = TypeObjectUtils::build_common_struct_member(member_id_key_value, member_flags_key_value, type_ids_sample.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure key_value member TypeIdentifier inconsistent."); + return; + } + MemberName name_key_value = "key_value"; + eprosima::fastcdr::optional member_ann_builtin_key_value; + ann_custom_sample.reset(); + AppliedAnnotationSeq tmp_ann_custom_key_value; + eprosima::fastcdr::optional unit_key_value; + eprosima::fastcdr::optional min_key_value; + eprosima::fastcdr::optional max_key_value; + eprosima::fastcdr::optional hash_id_key_value; + if (unit_key_value.has_value() || min_key_value.has_value() || max_key_value.has_value() || hash_id_key_value.has_value()) + { + member_ann_builtin_key_value = TypeObjectUtils::build_applied_builtin_member_annotations(unit_key_value, min_key_value, max_key_value, hash_id_key_value); + } + if (!tmp_ann_custom_key_value.empty()) + { + ann_custom_sample = tmp_ann_custom_key_value; + } + CompleteMemberDetail detail_key_value = TypeObjectUtils::build_complete_member_detail(name_key_value, member_ann_builtin_key_value, ann_custom_sample); + CompleteStructMember member_key_value = TypeObjectUtils::build_complete_struct_member(common_key_value, detail_key_value); + TypeObjectUtils::add_complete_struct_member(member_seq_sample, member_key_value); + } + CompleteStructType struct_type_sample = TypeObjectUtils::build_complete_struct_type(struct_flags_sample, header_sample, member_seq_sample); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_struct_type_object(struct_type_sample, type_name_sample.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "sample already registered in TypeObjectRegistry for a different type."); + } + return_code_sample = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "sample", type_ids_sample); + if (return_code_sample != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "sample: Given Struct TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } +} + diff --git a/examples/cpp/dds/SampleConfig_Multimedia/sampleTypeObjectSupport.hpp b/examples/cpp/dds/SampleConfig_Multimedia/sampleTypeObjectSupport.hpp new file mode 100644 index 00000000000..5ad7f2e5e07 --- /dev/null +++ b/examples/cpp/dds/SampleConfig_Multimedia/sampleTypeObjectSupport.hpp @@ -0,0 +1,54 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file sampleTypeObjectSupport.hpp + * Header file containing the API required to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#ifndef _FAST_DDS_GENERATED_SAMPLE_TYPE_OBJECT_SUPPORT_HPP_ +#define _FAST_DDS_GENERATED_SAMPLE_TYPE_OBJECT_SUPPORT_HPP_ + + +#if defined(_WIN32) +#if defined(EPROSIMA_USER_DLL_EXPORT) +#define eProsima_user_DllExport __declspec( dllexport ) +#else +#define eProsima_user_DllExport +#endif // EPROSIMA_USER_DLL_EXPORT +#else +#define eProsima_user_DllExport +#endif // _WIN32 + +/** + * @brief Register every TypeObject representation defined in the IDL file in Fast DDS TypeObjectRegistry. + */ +eProsima_user_DllExport void register_sample_type_objects(); + +#ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +/** + * @brief Register sample related TypeIdentifier. + * Fully-descriptive TypeIdentifiers are directly registered. + * Hash TypeIdentifiers require to fill the TypeObject information and hash it, consequently, the TypeObject is + * indirectly registered as well. + */ +void register_sample_type_identifier(); + + +#endif // DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +#endif // _FAST_DDS_GENERATED_SAMPLE_TYPE_OBJECT_SUPPORT_HPP_ diff --git a/examples/cpp/dds/SampleConfig_Multimedia/sampleconfig_fastest.cpp b/examples/cpp/dds/SampleConfig_Multimedia/sampleconfig_fastest.cpp index 65e979b8bb7..f503f0daa63 100644 --- a/examples/cpp/dds/SampleConfig_Multimedia/sampleconfig_fastest.cpp +++ b/examples/cpp/dds/SampleConfig_Multimedia/sampleconfig_fastest.cpp @@ -149,7 +149,7 @@ void fastest() //Read the contents of both histories: std::cout << "The Reliable Subscriber (with a history depth of 5) holds: " << std::endl; - while (myReader->read_next_sample(&my_sample, &sample_info) == ReturnCode_t::RETCODE_OK) + while (myReader->read_next_sample(&my_sample, &sample_info) == RETCODE_OK) { std::cout << std::to_string(my_sample.index()) << " "; } diff --git a/examples/cpp/dds/SampleConfig_Multimedia/samplev1.cxx b/examples/cpp/dds/SampleConfig_Multimedia/samplev1.cxx deleted file mode 100644 index 3b735befaf8..00000000000 --- a/examples/cpp/dds/SampleConfig_Multimedia/samplev1.cxx +++ /dev/null @@ -1,280 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file sample.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "sample.h" - -#if FASTCDR_VERSION_MAJOR == 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - -namespace helper { namespace internal { - -enum class Size { - UInt8, - UInt16, - UInt32, - UInt64, -}; - -constexpr Size get_size(int s) { - return (s <= 8 ) ? Size::UInt8: - (s <= 16) ? Size::UInt16: - (s <= 32) ? Size::UInt32: Size::UInt64; -} - -template -struct FindTypeH; - -template<> -struct FindTypeH { - using type = std::uint8_t; -}; - -template<> -struct FindTypeH { - using type = std::uint16_t; -}; - -template<> -struct FindTypeH { - using type = std::uint32_t; -}; - -template<> -struct FindTypeH { - using type = std::uint64_t; -}; -} - -template -struct FindType { - using type = typename internal::FindTypeH::type; -}; -} - -#define sample_max_cdr_typesize 6ULL; - - - - -sample::sample() -{ - // octet m_index - m_index = 0; - // octet m_key_value - m_key_value = 0; - -} - -sample::~sample() -{ -} - -sample::sample( - const sample& x) -{ - m_index = x.m_index; - - - m_key_value = x.m_key_value; - -} - -sample::sample( - sample&& x) noexcept -{ - m_index = x.m_index; - - - m_key_value = x.m_key_value; - -} - -sample& sample::operator =( - const sample& x) -{ - m_index = x.m_index; - - - m_key_value = x.m_key_value; - - return *this; -} - -sample& sample::operator =( - sample&& x) noexcept -{ - m_index = x.m_index; - - - m_key_value = x.m_key_value; - - return *this; -} - -bool sample::operator ==( - const sample& x) const -{ - return (m_index == x.m_index && - m_key_value == x.m_key_value); -} - -bool sample::operator !=( - const sample& x) const -{ - return !(*this == x); -} - -size_t sample::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return sample_max_cdr_typesize; -} - -size_t sample::getCdrSerializedSize( - const sample& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - return current_alignment - initial_alignment; -} - - -void sample::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_index; - - scdr << m_key_value; - -} - -void sample::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_index; - - - - dcdr >> m_key_value; - - -} - - -bool sample::isKeyDefined() -{ - return true; -} - -void sample::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; - - - scdr << m_key_value; - -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void sample::index( - uint8_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint8_t sample::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint8_t& sample::index() -{ - return m_index; -} - - -/*! - * @brief This function sets a value in member key_value - * @param _key_value New value for member key_value - */ -void sample::key_value( - uint8_t _key_value) -{ - m_key_value = _key_value; -} - -/*! - * @brief This function returns the value of member key_value - * @return Value of member key_value - */ -uint8_t sample::key_value() const -{ - return m_key_value; -} - -/*! - * @brief This function returns a reference to member key_value - * @return Reference to member key_value - */ -uint8_t& sample::key_value() -{ - return m_key_value; -} - - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/SampleConfig_Multimedia/samplev1.h b/examples/cpp/dds/SampleConfig_Multimedia/samplev1.h deleted file mode 100644 index 4fa288d1bc9..00000000000 --- a/examples/cpp/dds/SampleConfig_Multimedia/samplev1.h +++ /dev/null @@ -1,237 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file sample.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#include - -#if FASTCDR_VERSION_MAJOR == 1 - -#ifndef _FAST_DDS_GENERATED_SAMPLE_H_ -#define _FAST_DDS_GENERATED_SAMPLE_H_ - - -#include - -#include -#include -#include -#include -#include -#include -#include - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define eProsima_user_DllExport -#endif // _WIN32 - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(SAMPLE_SOURCE) -#define SAMPLE_DllAPI __declspec( dllexport ) -#else -#define SAMPLE_DllAPI __declspec( dllimport ) -#endif // SAMPLE_SOURCE -#else -#define SAMPLE_DllAPI -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define SAMPLE_DllAPI -#endif // _WIN32 - -namespace eprosima { -namespace fastcdr { -class Cdr; -} // namespace fastcdr -} // namespace eprosima - - - - - -/*! - * @brief This class represents the structure sample defined by the user in the IDL file. - * @ingroup sample - */ -class sample -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport sample(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~sample(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object sample that will be copied. - */ - eProsima_user_DllExport sample( - const sample& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object sample that will be copied. - */ - eProsima_user_DllExport sample( - sample&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object sample that will be copied. - */ - eProsima_user_DllExport sample& operator =( - const sample& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object sample that will be copied. - */ - eProsima_user_DllExport sample& operator =( - sample&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x sample object to compare. - */ - eProsima_user_DllExport bool operator ==( - const sample& x) const; - - /*! - * @brief Comparison operator. - * @param x sample object to compare. - */ - eProsima_user_DllExport bool operator !=( - const sample& x) const; - - /*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ - eProsima_user_DllExport void index( - uint8_t _index); - - /*! - * @brief This function returns the value of member index - * @return Value of member index - */ - eProsima_user_DllExport uint8_t index() const; - - /*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ - eProsima_user_DllExport uint8_t& index(); - - - /*! - * @brief This function sets a value in member key_value - * @param _key_value New value for member key_value - */ - eProsima_user_DllExport void key_value( - uint8_t _key_value); - - /*! - * @brief This function returns the value of member key_value - * @return Value of member key_value - */ - eProsima_user_DllExport uint8_t key_value() const; - - /*! - * @brief This function returns a reference to member key_value - * @return Reference to member key_value - */ - eProsima_user_DllExport uint8_t& key_value(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const sample& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - uint8_t m_index; - uint8_t m_key_value; - -}; - - -#endif // _FAST_DDS_GENERATED_SAMPLE_H_ - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/SecureHelloWorldExample/CMakeLists.txt b/examples/cpp/dds/SecureHelloWorldExample/CMakeLists.txt index a06592719d7..237263af779 100644 --- a/examples/cpp/dds/SecureHelloWorldExample/CMakeLists.txt +++ b/examples/cpp/dds/SecureHelloWorldExample/CMakeLists.txt @@ -25,8 +25,8 @@ if(NOT foonathan_memory_FOUND) find_package(foonathan_memory REQUIRED) endif() -if(NOT fastrtps_FOUND) - find_package(fastrtps 2.12 REQUIRED) +if(NOT fastdds_FOUND) + find_package(fastdds 3 REQUIRED) endif() #Check C++11 @@ -48,7 +48,7 @@ target_compile_definitions(DDSSecureHelloWorldExample PRIVATE $<$:__INTERNALDEBUG> # Internal debug activated. ) target_include_directories(DDSSecureHelloWorldExample PRIVATE) -target_link_libraries(DDSSecureHelloWorldExample fastrtps fastcdr foonathan_memory) +target_link_libraries(DDSSecureHelloWorldExample fastdds fastcdr foonathan_memory) install(TARGETS DDSSecureHelloWorldExample RUNTIME DESTINATION examples/cpp/dds/SecureHelloWorldExample/${BIN_INSTALL_DIR}) install(DIRECTORY ${PROJECT_SOURCE_DIR}/certs diff --git a/examples/cpp/dds/SecureHelloWorldExample/HelloWorld.cxx b/examples/cpp/dds/SecureHelloWorldExample/HelloWorld.cxx deleted file mode 100644 index 4b415d67769..00000000000 --- a/examples/cpp/dds/SecureHelloWorldExample/HelloWorld.cxx +++ /dev/null @@ -1,168 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file HelloWorld.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "HelloWorld.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - - - - -HelloWorld::HelloWorld() -{ -} - -HelloWorld::~HelloWorld() -{ -} - -HelloWorld::HelloWorld( - const HelloWorld& x) -{ - m_index = x.m_index; - m_message = x.m_message; -} - -HelloWorld::HelloWorld( - HelloWorld&& x) noexcept -{ - m_index = x.m_index; - m_message = std::move(x.m_message); -} - -HelloWorld& HelloWorld::operator =( - const HelloWorld& x) -{ - - m_index = x.m_index; - m_message = x.m_message; - return *this; -} - -HelloWorld& HelloWorld::operator =( - HelloWorld&& x) noexcept -{ - - m_index = x.m_index; - m_message = std::move(x.m_message); - return *this; -} - -bool HelloWorld::operator ==( - const HelloWorld& x) const -{ - return (m_index == x.m_index && - m_message == x.m_message); -} - -bool HelloWorld::operator !=( - const HelloWorld& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void HelloWorld::index( - uint32_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint32_t HelloWorld::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint32_t& HelloWorld::index() -{ - return m_index; -} - - -/*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ -void HelloWorld::message( - const std::string& _message) -{ - m_message = _message; -} - -/*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ -void HelloWorld::message( - std::string&& _message) -{ - m_message = std::move(_message); -} - -/*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ -const std::string& HelloWorld::message() const -{ - return m_message; -} - -/*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ -std::string& HelloWorld::message() -{ - return m_message; -} - - -// Include auxiliary functions like for serializing/deserializing. -#include "HelloWorldCdrAux.ipp" - -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/SecureHelloWorldExample/HelloWorld.h b/examples/cpp/dds/SecureHelloWorldExample/HelloWorld.h deleted file mode 100644 index 5cd0ddba511..00000000000 --- a/examples/cpp/dds/SecureHelloWorldExample/HelloWorld.h +++ /dev/null @@ -1,195 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file HelloWorld.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#include -#include "HelloWorldv1.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#ifndef _FAST_DDS_GENERATED_HELLOWORLD_H_ -#define _FAST_DDS_GENERATED_HELLOWORLD_H_ - -#include -#include -#include -#include -#include -#include - -#include -#include -#include - - - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define eProsima_user_DllExport -#endif // _WIN32 - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(HELLOWORLD_SOURCE) -#define HELLOWORLD_DllAPI __declspec( dllexport ) -#else -#define HELLOWORLD_DllAPI __declspec( dllimport ) -#endif // HELLOWORLD_SOURCE -#else -#define HELLOWORLD_DllAPI -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define HELLOWORLD_DllAPI -#endif // _WIN32 - -namespace eprosima { -namespace fastcdr { -class Cdr; -class CdrSizeCalculator; -} // namespace fastcdr -} // namespace eprosima - - - - - -/*! - * @brief This class represents the structure HelloWorld defined by the user in the IDL file. - * @ingroup HelloWorld - */ -class HelloWorld -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport HelloWorld(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~HelloWorld(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object HelloWorld that will be copied. - */ - eProsima_user_DllExport HelloWorld( - const HelloWorld& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object HelloWorld that will be copied. - */ - eProsima_user_DllExport HelloWorld( - HelloWorld&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object HelloWorld that will be copied. - */ - eProsima_user_DllExport HelloWorld& operator =( - const HelloWorld& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object HelloWorld that will be copied. - */ - eProsima_user_DllExport HelloWorld& operator =( - HelloWorld&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x HelloWorld object to compare. - */ - eProsima_user_DllExport bool operator ==( - const HelloWorld& x) const; - - /*! - * @brief Comparison operator. - * @param x HelloWorld object to compare. - */ - eProsima_user_DllExport bool operator !=( - const HelloWorld& x) const; - - /*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ - eProsima_user_DllExport void index( - uint32_t _index); - - /*! - * @brief This function returns the value of member index - * @return Value of member index - */ - eProsima_user_DllExport uint32_t index() const; - - /*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ - eProsima_user_DllExport uint32_t& index(); - - - /*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ - eProsima_user_DllExport void message( - const std::string& _message); - - /*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ - eProsima_user_DllExport void message( - std::string&& _message); - - /*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ - eProsima_user_DllExport const std::string& message() const; - - /*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ - eProsima_user_DllExport std::string& message(); - -private: - - uint32_t m_index{0}; - std::string m_message; - -}; - -#endif // _FAST_DDS_GENERATED_HELLOWORLD_H_ - - - -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/SecureHelloWorldExample/HelloWorld.hpp b/examples/cpp/dds/SecureHelloWorldExample/HelloWorld.hpp new file mode 100644 index 00000000000..971fea8d920 --- /dev/null +++ b/examples/cpp/dds/SecureHelloWorldExample/HelloWorld.hpp @@ -0,0 +1,227 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file HelloWorld.hpp + * This header file contains the declaration of the described types in the IDL file. + * + * This file was generated by the tool fastddsgen. + */ + +#ifndef _FAST_DDS_GENERATED_HELLOWORLD_HPP_ +#define _FAST_DDS_GENERATED_HELLOWORLD_HPP_ + +#include +#include +#include +#include + +#if defined(_WIN32) +#if defined(EPROSIMA_USER_DLL_EXPORT) +#define eProsima_user_DllExport __declspec( dllexport ) +#else +#define eProsima_user_DllExport +#endif // EPROSIMA_USER_DLL_EXPORT +#else +#define eProsima_user_DllExport +#endif // _WIN32 + +#if defined(_WIN32) +#if defined(EPROSIMA_USER_DLL_EXPORT) +#if defined(HELLOWORLD_SOURCE) +#define HELLOWORLD_DllAPI __declspec( dllexport ) +#else +#define HELLOWORLD_DllAPI __declspec( dllimport ) +#endif // HELLOWORLD_SOURCE +#else +#define HELLOWORLD_DllAPI +#endif // EPROSIMA_USER_DLL_EXPORT +#else +#define HELLOWORLD_DllAPI +#endif // _WIN32 + +/*! + * @brief This class represents the structure HelloWorld defined by the user in the IDL file. + * @ingroup HelloWorld + */ +class HelloWorld +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport HelloWorld() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~HelloWorld() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object HelloWorld that will be copied. + */ + eProsima_user_DllExport HelloWorld( + const HelloWorld& x) + { + m_index = x.m_index; + + m_message = x.m_message; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object HelloWorld that will be copied. + */ + eProsima_user_DllExport HelloWorld( + HelloWorld&& x) noexcept + { + m_index = x.m_index; + m_message = std::move(x.m_message); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object HelloWorld that will be copied. + */ + eProsima_user_DllExport HelloWorld& operator =( + const HelloWorld& x) + { + + m_index = x.m_index; + + m_message = x.m_message; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object HelloWorld that will be copied. + */ + eProsima_user_DllExport HelloWorld& operator =( + HelloWorld&& x) noexcept + { + + m_index = x.m_index; + m_message = std::move(x.m_message); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x HelloWorld object to compare. + */ + eProsima_user_DllExport bool operator ==( + const HelloWorld& x) const + { + return (m_index == x.m_index && + m_message == x.m_message); + } + + /*! + * @brief Comparison operator. + * @param x HelloWorld object to compare. + */ + eProsima_user_DllExport bool operator !=( + const HelloWorld& x) const + { + return !(*this == x); + } + + /*! + * @brief This function sets a value in member index + * @param _index New value for member index + */ + eProsima_user_DllExport void index( + uint32_t _index) + { + m_index = _index; + } + + /*! + * @brief This function returns the value of member index + * @return Value of member index + */ + eProsima_user_DllExport uint32_t index() const + { + return m_index; + } + + /*! + * @brief This function returns a reference to member index + * @return Reference to member index + */ + eProsima_user_DllExport uint32_t& index() + { + return m_index; + } + + + /*! + * @brief This function copies the value in member message + * @param _message New value to be copied in member message + */ + eProsima_user_DllExport void message( + const std::string& _message) + { + m_message = _message; + } + + /*! + * @brief This function moves the value in member message + * @param _message New value to be moved in member message + */ + eProsima_user_DllExport void message( + std::string&& _message) + { + m_message = std::move(_message); + } + + /*! + * @brief This function returns a constant reference to member message + * @return Constant reference to member message + */ + eProsima_user_DllExport const std::string& message() const + { + return m_message; + } + + /*! + * @brief This function returns a reference to member message + * @return Reference to member message + */ + eProsima_user_DllExport std::string& message() + { + return m_message; + } + + + +private: + + uint32_t m_index{0}; + std::string m_message; + +}; + +#endif // _FAST_DDS_GENERATED_HELLOWORLD_HPP_ + + diff --git a/examples/cpp/dds/SecureHelloWorldExample/HelloWorldCdrAux.hpp b/examples/cpp/dds/SecureHelloWorldExample/HelloWorldCdrAux.hpp index 9f346d306be..6feb8a9da15 100644 --- a/examples/cpp/dds/SecureHelloWorldExample/HelloWorldCdrAux.hpp +++ b/examples/cpp/dds/SecureHelloWorldExample/HelloWorldCdrAux.hpp @@ -22,7 +22,7 @@ #ifndef _FAST_DDS_GENERATED_HELLOWORLDCDRAUX_HPP_ #define _FAST_DDS_GENERATED_HELLOWORLDCDRAUX_HPP_ -#include "HelloWorld.h" +#include "HelloWorld.hpp" constexpr uint32_t HelloWorld_max_cdr_typesize {268UL}; constexpr uint32_t HelloWorld_max_key_cdr_typesize {0UL}; @@ -34,8 +34,6 @@ namespace fastcdr { class Cdr; class CdrSizeCalculator; - - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const HelloWorld& data); diff --git a/examples/cpp/dds/SecureHelloWorldExample/HelloWorldCdrAux.ipp b/examples/cpp/dds/SecureHelloWorldExample/HelloWorldCdrAux.ipp index 42e91f3cc38..97df3fe9d9e 100644 --- a/examples/cpp/dds/SecureHelloWorldExample/HelloWorldCdrAux.ipp +++ b/examples/cpp/dds/SecureHelloWorldExample/HelloWorldCdrAux.ipp @@ -34,8 +34,6 @@ using namespace eprosima::fastcdr::exception; namespace eprosima { namespace fastcdr { - - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, diff --git a/examples/cpp/dds/SecureHelloWorldExample/HelloWorldPubSubTypes.cxx b/examples/cpp/dds/SecureHelloWorldExample/HelloWorldPubSubTypes.cxx index 85cb477896e..db018e69782 100644 --- a/examples/cpp/dds/SecureHelloWorldExample/HelloWorldPubSubTypes.cxx +++ b/examples/cpp/dds/SecureHelloWorldExample/HelloWorldPubSubTypes.cxx @@ -19,18 +19,18 @@ * This file was generated by the tool fastddsgen. */ +#include "HelloWorldPubSubTypes.h" +#include #include -#include "HelloWorldPubSubTypes.h" #include "HelloWorldCdrAux.hpp" +#include "HelloWorldTypeObjectSupport.hpp" using SerializedPayload_t = eprosima::fastrtps::rtps::SerializedPayload_t; using InstanceHandle_t = eprosima::fastrtps::rtps::InstanceHandle_t; using DataRepresentationId_t = eprosima::fastdds::dds::DataRepresentationId_t; - - HelloWorldPubSubType::HelloWorldPubSubType() { setName("HelloWorld"); @@ -219,3 +219,11 @@ bool HelloWorldPubSubType::getKey( return true; } +void HelloWorldPubSubType::register_type_object_representation() const +{ + register_HelloWorld_type_objects(); +} + + +// Include auxiliary functions like for serializing/deserializing. +#include "HelloWorldCdrAux.ipp" diff --git a/examples/cpp/dds/SecureHelloWorldExample/HelloWorldPubSubTypes.h b/examples/cpp/dds/SecureHelloWorldExample/HelloWorldPubSubTypes.h index cb61cd6ba23..a9b4ac119e0 100644 --- a/examples/cpp/dds/SecureHelloWorldExample/HelloWorldPubSubTypes.h +++ b/examples/cpp/dds/SecureHelloWorldExample/HelloWorldPubSubTypes.h @@ -27,9 +27,9 @@ #include #include #include -#include +#include -#include "HelloWorld.h" +#include "HelloWorld.hpp" #if !defined(GEN_API_VER) || (GEN_API_VER != 2) @@ -38,8 +38,6 @@ #endif // GEN_API_VER - - /*! * @brief This class represents the TopicDataType of the type HelloWorld defined by the user in the IDL file. * @ingroup HelloWorld @@ -90,6 +88,9 @@ class HelloWorldPubSubType : public eprosima::fastdds::dds::TopicDataType eProsima_user_DllExport void deleteData( void* data) override; + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + #ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED eProsima_user_DllExport inline bool is_bounded() const override { diff --git a/examples/cpp/dds/SecureHelloWorldExample/HelloWorldPublisher.h b/examples/cpp/dds/SecureHelloWorldExample/HelloWorldPublisher.h index ca01551f3c3..220e10338ce 100644 --- a/examples/cpp/dds/SecureHelloWorldExample/HelloWorldPublisher.h +++ b/examples/cpp/dds/SecureHelloWorldExample/HelloWorldPublisher.h @@ -29,7 +29,7 @@ #include #include -#include "HelloWorld.h" +#include "HelloWorld.hpp" class HelloWorldPublisher { diff --git a/examples/cpp/dds/SecureHelloWorldExample/HelloWorldSubscriber.cpp b/examples/cpp/dds/SecureHelloWorldExample/HelloWorldSubscriber.cpp index 175eb640873..5d505897f4d 100644 --- a/examples/cpp/dds/SecureHelloWorldExample/HelloWorldSubscriber.cpp +++ b/examples/cpp/dds/SecureHelloWorldExample/HelloWorldSubscriber.cpp @@ -143,7 +143,7 @@ void HelloWorldSubscriber::SubListener::on_data_available( DataReader* reader) { SampleInfo info; - if (reader->take_next_sample(&hello_, &info) == ReturnCode_t::RETCODE_OK) + if (reader->take_next_sample(&hello_, &info) == RETCODE_OK) { if (info.instance_state == ALIVE_INSTANCE_STATE) { diff --git a/examples/cpp/dds/SecureHelloWorldExample/HelloWorldSubscriber.h b/examples/cpp/dds/SecureHelloWorldExample/HelloWorldSubscriber.h index 1c5c45faa0d..0d5cb38bfae 100644 --- a/examples/cpp/dds/SecureHelloWorldExample/HelloWorldSubscriber.h +++ b/examples/cpp/dds/SecureHelloWorldExample/HelloWorldSubscriber.h @@ -28,7 +28,7 @@ #include #include -#include "HelloWorld.h" +#include "HelloWorld.hpp" class HelloWorldSubscriber { diff --git a/examples/cpp/dds/SecureHelloWorldExample/HelloWorldTypeObjectSupport.cxx b/examples/cpp/dds/SecureHelloWorldExample/HelloWorldTypeObjectSupport.cxx new file mode 100644 index 00000000000..bfae95694f4 --- /dev/null +++ b/examples/cpp/dds/SecureHelloWorldExample/HelloWorldTypeObjectSupport.cxx @@ -0,0 +1,248 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file HelloWorldTypeObjectSupport.cxx + * Source file containing the implementation to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#include "HelloWorldTypeObjectSupport.hpp" + +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include + +#include "HelloWorld.hpp" + + +using namespace eprosima::fastdds::dds::xtypes; + +void register_HelloWorld_type_objects() +{ + static std::once_flag once_flag; + std::call_once(once_flag, []() + { + register_HelloWorld_type_identifier(); + + }); +} + +void register_HelloWorld_type_identifier() +{ + { + StructTypeFlag struct_flags_HelloWorld = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::NOT_APPLIED, + false, false); + ReturnCode_t return_code_HelloWorld; + TypeIdentifierPair type_ids_HelloWorld; + QualifiedTypeName type_name_HelloWorld = "HelloWorld"; + eprosima::fastcdr::optional type_ann_builtin_HelloWorld; + eprosima::fastcdr::optional ann_custom_HelloWorld; + CompleteTypeDetail detail_HelloWorld = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_HelloWorld, ann_custom_HelloWorld, type_name_HelloWorld.to_string()); + CompleteStructHeader header_HelloWorld; + header_HelloWorld = TypeObjectUtils::build_complete_struct_header(TypeIdentifier(), detail_HelloWorld); + CompleteStructMemberSeq member_seq_HelloWorld; + { + return_code_HelloWorld = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_uint32_t", type_ids_HelloWorld); + + if (return_code_HelloWorld != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "index Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_index = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_index; + MemberId member_id_index = 0x00000000; + if (EK_COMPLETE == type_ids_HelloWorld.type_identifier1()._d() || TK_NONE == type_ids_HelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_HelloWorld.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_HelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_HelloWorld.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure index member TypeIdentifier inconsistent."); + return; + } + MemberName name_index = "index"; + eprosima::fastcdr::optional member_ann_builtin_index; + ann_custom_HelloWorld.reset(); + CompleteMemberDetail detail_index = TypeObjectUtils::build_complete_member_detail(name_index, member_ann_builtin_index, ann_custom_HelloWorld); + CompleteStructMember member_index = TypeObjectUtils::build_complete_struct_member(common_index, detail_index); + TypeObjectUtils::add_complete_struct_member(member_seq_HelloWorld, member_index); + } + { + return_code_HelloWorld = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_string_unbounded", type_ids_HelloWorld); + + if (return_code_HelloWorld != eprosima::fastdds::dds::RETCODE_OK) + { + std::string type_id_kind_anonymous_string_unbounded("TI_STRING8_SMALL"); + if (type_id_kind_anonymous_string_unbounded == "TI_STRING8_SMALL") + { + SBound bound = 0; + StringSTypeDefn string_sdefn = TypeObjectUtils::build_string_s_type_defn(bound); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_string_type_identifier(string_sdefn, + "anonymous_string_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else if (type_id_kind_anonymous_string_unbounded == "TI_STRING8_LARGE") + { + LBound bound = 255; + StringLTypeDefn string_ldefn = TypeObjectUtils::build_string_l_type_defn(bound); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_string_type_identifier(string_ldefn, + "anonymous_string_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded: Unknown String kind."); + return; + } + return_code_HelloWorld = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_string_unbounded", type_ids_HelloWorld); + if (return_code_HelloWorld != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded: Given String TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_message = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_message; + MemberId member_id_message = 0x00000001; + if (EK_COMPLETE == type_ids_HelloWorld.type_identifier1()._d() || TK_NONE == type_ids_HelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_message = TypeObjectUtils::build_common_struct_member(member_id_message, member_flags_message, type_ids_HelloWorld.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_HelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_message = TypeObjectUtils::build_common_struct_member(member_id_message, member_flags_message, type_ids_HelloWorld.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure message member TypeIdentifier inconsistent."); + return; + } + MemberName name_message = "message"; + eprosima::fastcdr::optional member_ann_builtin_message; + ann_custom_HelloWorld.reset(); + CompleteMemberDetail detail_message = TypeObjectUtils::build_complete_member_detail(name_message, member_ann_builtin_message, ann_custom_HelloWorld); + CompleteStructMember member_message = TypeObjectUtils::build_complete_struct_member(common_message, detail_message); + TypeObjectUtils::add_complete_struct_member(member_seq_HelloWorld, member_message); + } + CompleteStructType struct_type_HelloWorld = TypeObjectUtils::build_complete_struct_type(struct_flags_HelloWorld, header_HelloWorld, member_seq_HelloWorld); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_struct_type_object(struct_type_HelloWorld, type_name_HelloWorld.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "HelloWorld already registered in TypeObjectRegistry for a different type."); + } + return_code_HelloWorld = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "HelloWorld", type_ids_HelloWorld); + if (return_code_HelloWorld != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "HelloWorld: Given Struct TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } +} + diff --git a/examples/cpp/dds/SecureHelloWorldExample/HelloWorldTypeObjectSupport.hpp b/examples/cpp/dds/SecureHelloWorldExample/HelloWorldTypeObjectSupport.hpp new file mode 100644 index 00000000000..8650fc061e0 --- /dev/null +++ b/examples/cpp/dds/SecureHelloWorldExample/HelloWorldTypeObjectSupport.hpp @@ -0,0 +1,54 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file HelloWorldTypeObjectSupport.hpp + * Header file containing the API required to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#ifndef _FAST_DDS_GENERATED_HELLOWORLD_TYPE_OBJECT_SUPPORT_HPP_ +#define _FAST_DDS_GENERATED_HELLOWORLD_TYPE_OBJECT_SUPPORT_HPP_ + + +#if defined(_WIN32) +#if defined(EPROSIMA_USER_DLL_EXPORT) +#define eProsima_user_DllExport __declspec( dllexport ) +#else +#define eProsima_user_DllExport +#endif // EPROSIMA_USER_DLL_EXPORT +#else +#define eProsima_user_DllExport +#endif // _WIN32 + +/** + * @brief Register every TypeObject representation defined in the IDL file in Fast DDS TypeObjectRegistry. + */ +eProsima_user_DllExport void register_HelloWorld_type_objects(); + +#ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +/** + * @brief Register HelloWorld related TypeIdentifier. + * Fully-descriptive TypeIdentifiers are directly registered. + * Hash TypeIdentifiers require to fill the TypeObject information and hash it, consequently, the TypeObject is + * indirectly registered as well. + */ +void register_HelloWorld_type_identifier(); + + +#endif // DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +#endif // _FAST_DDS_GENERATED_HELLOWORLD_TYPE_OBJECT_SUPPORT_HPP_ diff --git a/examples/cpp/dds/SecureHelloWorldExample/HelloWorld_main.cpp b/examples/cpp/dds/SecureHelloWorldExample/HelloWorld_main.cpp index 9294faf0f43..215766a17e2 100644 --- a/examples/cpp/dds/SecureHelloWorldExample/HelloWorld_main.cpp +++ b/examples/cpp/dds/SecureHelloWorldExample/HelloWorld_main.cpp @@ -17,15 +17,16 @@ * */ +#include + #include "HelloWorldPublisher.h" #include "HelloWorldSubscriber.h" -#include -#include - using namespace eprosima; using namespace fastrtps; using namespace rtps; +using namespace eprosima::fastdds::dds; + int main( int argc, char** argv) @@ -71,7 +72,6 @@ int main( break; } } - Domain::stopAll(); Log::Reset(); return 0; } diff --git a/examples/cpp/dds/SecureHelloWorldExample/HelloWorldv1.cxx b/examples/cpp/dds/SecureHelloWorldExample/HelloWorldv1.cxx deleted file mode 100644 index 90e82ea88a7..00000000000 --- a/examples/cpp/dds/SecureHelloWorldExample/HelloWorldv1.cxx +++ /dev/null @@ -1,286 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file HelloWorld.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "HelloWorld.h" - -#if FASTCDR_VERSION_MAJOR == 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - -namespace helper { namespace internal { - -enum class Size { - UInt8, - UInt16, - UInt32, - UInt64, -}; - -constexpr Size get_size(int s) { - return (s <= 8 ) ? Size::UInt8: - (s <= 16) ? Size::UInt16: - (s <= 32) ? Size::UInt32: Size::UInt64; -} - -template -struct FindTypeH; - -template<> -struct FindTypeH { - using type = std::uint8_t; -}; - -template<> -struct FindTypeH { - using type = std::uint16_t; -}; - -template<> -struct FindTypeH { - using type = std::uint32_t; -}; - -template<> -struct FindTypeH { - using type = std::uint64_t; -}; -} - -template -struct FindType { - using type = typename internal::FindTypeH::type; -}; -} - -#define HelloWorld_max_cdr_typesize 268ULL; - - - - -HelloWorld::HelloWorld() -{ - // unsigned long m_index - m_index = 0; - // /type_d() m_message - - -} - -HelloWorld::~HelloWorld() -{ -} - -HelloWorld::HelloWorld( - const HelloWorld& x) -{ - m_index = x.m_index; - - - m_message = x.m_message; - -} - -HelloWorld::HelloWorld( - HelloWorld&& x) noexcept -{ - m_index = x.m_index; - - - m_message = std::move(x.m_message); - -} - -HelloWorld& HelloWorld::operator =( - const HelloWorld& x) -{ - m_index = x.m_index; - - - m_message = x.m_message; - - return *this; -} - -HelloWorld& HelloWorld::operator =( - HelloWorld&& x) noexcept -{ - m_index = x.m_index; - - - m_message = std::move(x.m_message); - - return *this; -} - -bool HelloWorld::operator ==( - const HelloWorld& x) const -{ - return (m_index == x.m_index && - m_message == x.m_message); -} - -bool HelloWorld::operator !=( - const HelloWorld& x) const -{ - return !(*this == x); -} - -size_t HelloWorld::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return HelloWorld_max_cdr_typesize; -} - -size_t HelloWorld::getCdrSerializedSize( - const HelloWorld& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + data.message().size() + 1; - - - return current_alignment - initial_alignment; -} - - -void HelloWorld::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_index; - - scdr << m_message.c_str(); - -} - -void HelloWorld::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_index; - - - - dcdr >> m_message; - - -} - - -bool HelloWorld::isKeyDefined() -{ - return false; -} - -void HelloWorld::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void HelloWorld::index( - uint32_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint32_t HelloWorld::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint32_t& HelloWorld::index() -{ - return m_index; -} - - -/*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ -void HelloWorld::message( - const std::string& _message) -{ - m_message = _message; -} - -/*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ -void HelloWorld::message( - std::string&& _message) -{ - m_message = std::move(_message); -} - -/*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ -const std::string& HelloWorld::message() const -{ - return m_message; -} - -/*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ -std::string& HelloWorld::message() -{ - return m_message; -} - - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/SecureHelloWorldExample/HelloWorldv1.h b/examples/cpp/dds/SecureHelloWorldExample/HelloWorldv1.h deleted file mode 100644 index 9f6f726e0ab..00000000000 --- a/examples/cpp/dds/SecureHelloWorldExample/HelloWorldv1.h +++ /dev/null @@ -1,244 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file HelloWorld.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#include - -#if FASTCDR_VERSION_MAJOR == 1 - -#ifndef _FAST_DDS_GENERATED_HELLOWORLD_H_ -#define _FAST_DDS_GENERATED_HELLOWORLD_H_ - - -#include - -#include -#include -#include -#include -#include -#include -#include - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define eProsima_user_DllExport -#endif // _WIN32 - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(HELLOWORLD_SOURCE) -#define HELLOWORLD_DllAPI __declspec( dllexport ) -#else -#define HELLOWORLD_DllAPI __declspec( dllimport ) -#endif // HELLOWORLD_SOURCE -#else -#define HELLOWORLD_DllAPI -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define HELLOWORLD_DllAPI -#endif // _WIN32 - -namespace eprosima { -namespace fastcdr { -class Cdr; -} // namespace fastcdr -} // namespace eprosima - - - - - -/*! - * @brief This class represents the structure HelloWorld defined by the user in the IDL file. - * @ingroup HelloWorld - */ -class HelloWorld -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport HelloWorld(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~HelloWorld(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object HelloWorld that will be copied. - */ - eProsima_user_DllExport HelloWorld( - const HelloWorld& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object HelloWorld that will be copied. - */ - eProsima_user_DllExport HelloWorld( - HelloWorld&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object HelloWorld that will be copied. - */ - eProsima_user_DllExport HelloWorld& operator =( - const HelloWorld& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object HelloWorld that will be copied. - */ - eProsima_user_DllExport HelloWorld& operator =( - HelloWorld&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x HelloWorld object to compare. - */ - eProsima_user_DllExport bool operator ==( - const HelloWorld& x) const; - - /*! - * @brief Comparison operator. - * @param x HelloWorld object to compare. - */ - eProsima_user_DllExport bool operator !=( - const HelloWorld& x) const; - - /*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ - eProsima_user_DllExport void index( - uint32_t _index); - - /*! - * @brief This function returns the value of member index - * @return Value of member index - */ - eProsima_user_DllExport uint32_t index() const; - - /*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ - eProsima_user_DllExport uint32_t& index(); - - - /*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ - eProsima_user_DllExport void message( - const std::string& _message); - - /*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ - eProsima_user_DllExport void message( - std::string&& _message); - - /*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ - eProsima_user_DllExport const std::string& message() const; - - /*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ - eProsima_user_DllExport std::string& message(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const HelloWorld& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - uint32_t m_index; - std::string m_message; - -}; - - -#endif // _FAST_DDS_GENERATED_HELLOWORLD_H_ - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/StaticHelloWorldExample/CMakeLists.txt b/examples/cpp/dds/StaticHelloWorldExample/CMakeLists.txt index cbe65f36bc6..f9c95e72240 100644 --- a/examples/cpp/dds/StaticHelloWorldExample/CMakeLists.txt +++ b/examples/cpp/dds/StaticHelloWorldExample/CMakeLists.txt @@ -25,8 +25,8 @@ if(NOT foonathan_memory_FOUND) find_package(foonathan_memory REQUIRED) endif() -if(NOT fastrtps_FOUND) - find_package(fastrtps 2.12 REQUIRED) +if(NOT fastdds_FOUND) + find_package(fastdds 3 REQUIRED) endif() #Check C++11 @@ -52,7 +52,7 @@ target_compile_definitions(DDSStaticHelloWorldExample PRIVATE $<$>,$>:__DEBUG> $<$:__INTERNALDEBUG> # Internal debug activated. ) -target_link_libraries(DDSStaticHelloWorldExample fastrtps fastcdr foonathan_memory) +target_link_libraries(DDSStaticHelloWorldExample fastdds fastcdr foonathan_memory) install(TARGETS DDSStaticHelloWorldExample RUNTIME DESTINATION examples/cpp/dds/StaticHelloWorldExample/${BIN_INSTALL_DIR}) install(FILES ${CMAKE_CURRENT_SOURCE_DIR}/HelloWorldPublisher_static_disc.xml diff --git a/examples/cpp/dds/StaticHelloWorldExample/HelloWorld.cxx b/examples/cpp/dds/StaticHelloWorldExample/HelloWorld.cxx deleted file mode 100644 index 4b415d67769..00000000000 --- a/examples/cpp/dds/StaticHelloWorldExample/HelloWorld.cxx +++ /dev/null @@ -1,168 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file HelloWorld.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "HelloWorld.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - - - - -HelloWorld::HelloWorld() -{ -} - -HelloWorld::~HelloWorld() -{ -} - -HelloWorld::HelloWorld( - const HelloWorld& x) -{ - m_index = x.m_index; - m_message = x.m_message; -} - -HelloWorld::HelloWorld( - HelloWorld&& x) noexcept -{ - m_index = x.m_index; - m_message = std::move(x.m_message); -} - -HelloWorld& HelloWorld::operator =( - const HelloWorld& x) -{ - - m_index = x.m_index; - m_message = x.m_message; - return *this; -} - -HelloWorld& HelloWorld::operator =( - HelloWorld&& x) noexcept -{ - - m_index = x.m_index; - m_message = std::move(x.m_message); - return *this; -} - -bool HelloWorld::operator ==( - const HelloWorld& x) const -{ - return (m_index == x.m_index && - m_message == x.m_message); -} - -bool HelloWorld::operator !=( - const HelloWorld& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void HelloWorld::index( - uint32_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint32_t HelloWorld::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint32_t& HelloWorld::index() -{ - return m_index; -} - - -/*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ -void HelloWorld::message( - const std::string& _message) -{ - m_message = _message; -} - -/*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ -void HelloWorld::message( - std::string&& _message) -{ - m_message = std::move(_message); -} - -/*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ -const std::string& HelloWorld::message() const -{ - return m_message; -} - -/*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ -std::string& HelloWorld::message() -{ - return m_message; -} - - -// Include auxiliary functions like for serializing/deserializing. -#include "HelloWorldCdrAux.ipp" - -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/StaticHelloWorldExample/HelloWorld.h b/examples/cpp/dds/StaticHelloWorldExample/HelloWorld.h deleted file mode 100644 index 5cd0ddba511..00000000000 --- a/examples/cpp/dds/StaticHelloWorldExample/HelloWorld.h +++ /dev/null @@ -1,195 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file HelloWorld.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#include -#include "HelloWorldv1.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#ifndef _FAST_DDS_GENERATED_HELLOWORLD_H_ -#define _FAST_DDS_GENERATED_HELLOWORLD_H_ - -#include -#include -#include -#include -#include -#include - -#include -#include -#include - - - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define eProsima_user_DllExport -#endif // _WIN32 - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(HELLOWORLD_SOURCE) -#define HELLOWORLD_DllAPI __declspec( dllexport ) -#else -#define HELLOWORLD_DllAPI __declspec( dllimport ) -#endif // HELLOWORLD_SOURCE -#else -#define HELLOWORLD_DllAPI -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define HELLOWORLD_DllAPI -#endif // _WIN32 - -namespace eprosima { -namespace fastcdr { -class Cdr; -class CdrSizeCalculator; -} // namespace fastcdr -} // namespace eprosima - - - - - -/*! - * @brief This class represents the structure HelloWorld defined by the user in the IDL file. - * @ingroup HelloWorld - */ -class HelloWorld -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport HelloWorld(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~HelloWorld(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object HelloWorld that will be copied. - */ - eProsima_user_DllExport HelloWorld( - const HelloWorld& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object HelloWorld that will be copied. - */ - eProsima_user_DllExport HelloWorld( - HelloWorld&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object HelloWorld that will be copied. - */ - eProsima_user_DllExport HelloWorld& operator =( - const HelloWorld& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object HelloWorld that will be copied. - */ - eProsima_user_DllExport HelloWorld& operator =( - HelloWorld&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x HelloWorld object to compare. - */ - eProsima_user_DllExport bool operator ==( - const HelloWorld& x) const; - - /*! - * @brief Comparison operator. - * @param x HelloWorld object to compare. - */ - eProsima_user_DllExport bool operator !=( - const HelloWorld& x) const; - - /*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ - eProsima_user_DllExport void index( - uint32_t _index); - - /*! - * @brief This function returns the value of member index - * @return Value of member index - */ - eProsima_user_DllExport uint32_t index() const; - - /*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ - eProsima_user_DllExport uint32_t& index(); - - - /*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ - eProsima_user_DllExport void message( - const std::string& _message); - - /*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ - eProsima_user_DllExport void message( - std::string&& _message); - - /*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ - eProsima_user_DllExport const std::string& message() const; - - /*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ - eProsima_user_DllExport std::string& message(); - -private: - - uint32_t m_index{0}; - std::string m_message; - -}; - -#endif // _FAST_DDS_GENERATED_HELLOWORLD_H_ - - - -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/StaticHelloWorldExample/HelloWorld.hpp b/examples/cpp/dds/StaticHelloWorldExample/HelloWorld.hpp new file mode 100644 index 00000000000..971fea8d920 --- /dev/null +++ b/examples/cpp/dds/StaticHelloWorldExample/HelloWorld.hpp @@ -0,0 +1,227 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file HelloWorld.hpp + * This header file contains the declaration of the described types in the IDL file. + * + * This file was generated by the tool fastddsgen. + */ + +#ifndef _FAST_DDS_GENERATED_HELLOWORLD_HPP_ +#define _FAST_DDS_GENERATED_HELLOWORLD_HPP_ + +#include +#include +#include +#include + +#if defined(_WIN32) +#if defined(EPROSIMA_USER_DLL_EXPORT) +#define eProsima_user_DllExport __declspec( dllexport ) +#else +#define eProsima_user_DllExport +#endif // EPROSIMA_USER_DLL_EXPORT +#else +#define eProsima_user_DllExport +#endif // _WIN32 + +#if defined(_WIN32) +#if defined(EPROSIMA_USER_DLL_EXPORT) +#if defined(HELLOWORLD_SOURCE) +#define HELLOWORLD_DllAPI __declspec( dllexport ) +#else +#define HELLOWORLD_DllAPI __declspec( dllimport ) +#endif // HELLOWORLD_SOURCE +#else +#define HELLOWORLD_DllAPI +#endif // EPROSIMA_USER_DLL_EXPORT +#else +#define HELLOWORLD_DllAPI +#endif // _WIN32 + +/*! + * @brief This class represents the structure HelloWorld defined by the user in the IDL file. + * @ingroup HelloWorld + */ +class HelloWorld +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport HelloWorld() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~HelloWorld() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object HelloWorld that will be copied. + */ + eProsima_user_DllExport HelloWorld( + const HelloWorld& x) + { + m_index = x.m_index; + + m_message = x.m_message; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object HelloWorld that will be copied. + */ + eProsima_user_DllExport HelloWorld( + HelloWorld&& x) noexcept + { + m_index = x.m_index; + m_message = std::move(x.m_message); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object HelloWorld that will be copied. + */ + eProsima_user_DllExport HelloWorld& operator =( + const HelloWorld& x) + { + + m_index = x.m_index; + + m_message = x.m_message; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object HelloWorld that will be copied. + */ + eProsima_user_DllExport HelloWorld& operator =( + HelloWorld&& x) noexcept + { + + m_index = x.m_index; + m_message = std::move(x.m_message); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x HelloWorld object to compare. + */ + eProsima_user_DllExport bool operator ==( + const HelloWorld& x) const + { + return (m_index == x.m_index && + m_message == x.m_message); + } + + /*! + * @brief Comparison operator. + * @param x HelloWorld object to compare. + */ + eProsima_user_DllExport bool operator !=( + const HelloWorld& x) const + { + return !(*this == x); + } + + /*! + * @brief This function sets a value in member index + * @param _index New value for member index + */ + eProsima_user_DllExport void index( + uint32_t _index) + { + m_index = _index; + } + + /*! + * @brief This function returns the value of member index + * @return Value of member index + */ + eProsima_user_DllExport uint32_t index() const + { + return m_index; + } + + /*! + * @brief This function returns a reference to member index + * @return Reference to member index + */ + eProsima_user_DllExport uint32_t& index() + { + return m_index; + } + + + /*! + * @brief This function copies the value in member message + * @param _message New value to be copied in member message + */ + eProsima_user_DllExport void message( + const std::string& _message) + { + m_message = _message; + } + + /*! + * @brief This function moves the value in member message + * @param _message New value to be moved in member message + */ + eProsima_user_DllExport void message( + std::string&& _message) + { + m_message = std::move(_message); + } + + /*! + * @brief This function returns a constant reference to member message + * @return Constant reference to member message + */ + eProsima_user_DllExport const std::string& message() const + { + return m_message; + } + + /*! + * @brief This function returns a reference to member message + * @return Reference to member message + */ + eProsima_user_DllExport std::string& message() + { + return m_message; + } + + + +private: + + uint32_t m_index{0}; + std::string m_message; + +}; + +#endif // _FAST_DDS_GENERATED_HELLOWORLD_HPP_ + + diff --git a/examples/cpp/dds/StaticHelloWorldExample/HelloWorldCdrAux.hpp b/examples/cpp/dds/StaticHelloWorldExample/HelloWorldCdrAux.hpp index 9f346d306be..6feb8a9da15 100644 --- a/examples/cpp/dds/StaticHelloWorldExample/HelloWorldCdrAux.hpp +++ b/examples/cpp/dds/StaticHelloWorldExample/HelloWorldCdrAux.hpp @@ -22,7 +22,7 @@ #ifndef _FAST_DDS_GENERATED_HELLOWORLDCDRAUX_HPP_ #define _FAST_DDS_GENERATED_HELLOWORLDCDRAUX_HPP_ -#include "HelloWorld.h" +#include "HelloWorld.hpp" constexpr uint32_t HelloWorld_max_cdr_typesize {268UL}; constexpr uint32_t HelloWorld_max_key_cdr_typesize {0UL}; @@ -34,8 +34,6 @@ namespace fastcdr { class Cdr; class CdrSizeCalculator; - - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const HelloWorld& data); diff --git a/examples/cpp/dds/StaticHelloWorldExample/HelloWorldCdrAux.ipp b/examples/cpp/dds/StaticHelloWorldExample/HelloWorldCdrAux.ipp index 42e91f3cc38..97df3fe9d9e 100644 --- a/examples/cpp/dds/StaticHelloWorldExample/HelloWorldCdrAux.ipp +++ b/examples/cpp/dds/StaticHelloWorldExample/HelloWorldCdrAux.ipp @@ -34,8 +34,6 @@ using namespace eprosima::fastcdr::exception; namespace eprosima { namespace fastcdr { - - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, diff --git a/examples/cpp/dds/StaticHelloWorldExample/HelloWorldPubSubTypes.cxx b/examples/cpp/dds/StaticHelloWorldExample/HelloWorldPubSubTypes.cxx index 85cb477896e..db018e69782 100644 --- a/examples/cpp/dds/StaticHelloWorldExample/HelloWorldPubSubTypes.cxx +++ b/examples/cpp/dds/StaticHelloWorldExample/HelloWorldPubSubTypes.cxx @@ -19,18 +19,18 @@ * This file was generated by the tool fastddsgen. */ +#include "HelloWorldPubSubTypes.h" +#include #include -#include "HelloWorldPubSubTypes.h" #include "HelloWorldCdrAux.hpp" +#include "HelloWorldTypeObjectSupport.hpp" using SerializedPayload_t = eprosima::fastrtps::rtps::SerializedPayload_t; using InstanceHandle_t = eprosima::fastrtps::rtps::InstanceHandle_t; using DataRepresentationId_t = eprosima::fastdds::dds::DataRepresentationId_t; - - HelloWorldPubSubType::HelloWorldPubSubType() { setName("HelloWorld"); @@ -219,3 +219,11 @@ bool HelloWorldPubSubType::getKey( return true; } +void HelloWorldPubSubType::register_type_object_representation() const +{ + register_HelloWorld_type_objects(); +} + + +// Include auxiliary functions like for serializing/deserializing. +#include "HelloWorldCdrAux.ipp" diff --git a/examples/cpp/dds/StaticHelloWorldExample/HelloWorldPubSubTypes.h b/examples/cpp/dds/StaticHelloWorldExample/HelloWorldPubSubTypes.h index cb61cd6ba23..a9b4ac119e0 100644 --- a/examples/cpp/dds/StaticHelloWorldExample/HelloWorldPubSubTypes.h +++ b/examples/cpp/dds/StaticHelloWorldExample/HelloWorldPubSubTypes.h @@ -27,9 +27,9 @@ #include #include #include -#include +#include -#include "HelloWorld.h" +#include "HelloWorld.hpp" #if !defined(GEN_API_VER) || (GEN_API_VER != 2) @@ -38,8 +38,6 @@ #endif // GEN_API_VER - - /*! * @brief This class represents the TopicDataType of the type HelloWorld defined by the user in the IDL file. * @ingroup HelloWorld @@ -90,6 +88,9 @@ class HelloWorldPubSubType : public eprosima::fastdds::dds::TopicDataType eProsima_user_DllExport void deleteData( void* data) override; + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + #ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED eProsima_user_DllExport inline bool is_bounded() const override { diff --git a/examples/cpp/dds/StaticHelloWorldExample/HelloWorldPublisher.h b/examples/cpp/dds/StaticHelloWorldExample/HelloWorldPublisher.h index 6f37d220749..ec1b5312bcc 100644 --- a/examples/cpp/dds/StaticHelloWorldExample/HelloWorldPublisher.h +++ b/examples/cpp/dds/StaticHelloWorldExample/HelloWorldPublisher.h @@ -26,8 +26,7 @@ #include #include - -#include "HelloWorld.h" +#include "HelloWorld.hpp" class HelloWorldPublisher { diff --git a/examples/cpp/dds/StaticHelloWorldExample/HelloWorldSubscriber.cpp b/examples/cpp/dds/StaticHelloWorldExample/HelloWorldSubscriber.cpp index 278d65536c4..7b38e634fd5 100644 --- a/examples/cpp/dds/StaticHelloWorldExample/HelloWorldSubscriber.cpp +++ b/examples/cpp/dds/StaticHelloWorldExample/HelloWorldSubscriber.cpp @@ -128,7 +128,7 @@ void HelloWorldSubscriber::SubListener::on_data_available( DataReader* reader) { SampleInfo info; - if (reader->take_next_sample(&hello_, &info) == ReturnCode_t::RETCODE_OK) + if (reader->take_next_sample(&hello_, &info) == RETCODE_OK) { if (info.instance_state == ALIVE_INSTANCE_STATE) { diff --git a/examples/cpp/dds/StaticHelloWorldExample/HelloWorldSubscriber.h b/examples/cpp/dds/StaticHelloWorldExample/HelloWorldSubscriber.h index 6d45aadc167..5395d10e642 100644 --- a/examples/cpp/dds/StaticHelloWorldExample/HelloWorldSubscriber.h +++ b/examples/cpp/dds/StaticHelloWorldExample/HelloWorldSubscriber.h @@ -27,7 +27,7 @@ #include #include -#include "HelloWorld.h" +#include "HelloWorld.hpp" class HelloWorldSubscriber { diff --git a/examples/cpp/dds/StaticHelloWorldExample/HelloWorldTypeObjectSupport.cxx b/examples/cpp/dds/StaticHelloWorldExample/HelloWorldTypeObjectSupport.cxx new file mode 100644 index 00000000000..bfae95694f4 --- /dev/null +++ b/examples/cpp/dds/StaticHelloWorldExample/HelloWorldTypeObjectSupport.cxx @@ -0,0 +1,248 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file HelloWorldTypeObjectSupport.cxx + * Source file containing the implementation to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#include "HelloWorldTypeObjectSupport.hpp" + +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include + +#include "HelloWorld.hpp" + + +using namespace eprosima::fastdds::dds::xtypes; + +void register_HelloWorld_type_objects() +{ + static std::once_flag once_flag; + std::call_once(once_flag, []() + { + register_HelloWorld_type_identifier(); + + }); +} + +void register_HelloWorld_type_identifier() +{ + { + StructTypeFlag struct_flags_HelloWorld = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::NOT_APPLIED, + false, false); + ReturnCode_t return_code_HelloWorld; + TypeIdentifierPair type_ids_HelloWorld; + QualifiedTypeName type_name_HelloWorld = "HelloWorld"; + eprosima::fastcdr::optional type_ann_builtin_HelloWorld; + eprosima::fastcdr::optional ann_custom_HelloWorld; + CompleteTypeDetail detail_HelloWorld = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_HelloWorld, ann_custom_HelloWorld, type_name_HelloWorld.to_string()); + CompleteStructHeader header_HelloWorld; + header_HelloWorld = TypeObjectUtils::build_complete_struct_header(TypeIdentifier(), detail_HelloWorld); + CompleteStructMemberSeq member_seq_HelloWorld; + { + return_code_HelloWorld = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_uint32_t", type_ids_HelloWorld); + + if (return_code_HelloWorld != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "index Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_index = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_index; + MemberId member_id_index = 0x00000000; + if (EK_COMPLETE == type_ids_HelloWorld.type_identifier1()._d() || TK_NONE == type_ids_HelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_HelloWorld.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_HelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_HelloWorld.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure index member TypeIdentifier inconsistent."); + return; + } + MemberName name_index = "index"; + eprosima::fastcdr::optional member_ann_builtin_index; + ann_custom_HelloWorld.reset(); + CompleteMemberDetail detail_index = TypeObjectUtils::build_complete_member_detail(name_index, member_ann_builtin_index, ann_custom_HelloWorld); + CompleteStructMember member_index = TypeObjectUtils::build_complete_struct_member(common_index, detail_index); + TypeObjectUtils::add_complete_struct_member(member_seq_HelloWorld, member_index); + } + { + return_code_HelloWorld = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_string_unbounded", type_ids_HelloWorld); + + if (return_code_HelloWorld != eprosima::fastdds::dds::RETCODE_OK) + { + std::string type_id_kind_anonymous_string_unbounded("TI_STRING8_SMALL"); + if (type_id_kind_anonymous_string_unbounded == "TI_STRING8_SMALL") + { + SBound bound = 0; + StringSTypeDefn string_sdefn = TypeObjectUtils::build_string_s_type_defn(bound); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_string_type_identifier(string_sdefn, + "anonymous_string_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else if (type_id_kind_anonymous_string_unbounded == "TI_STRING8_LARGE") + { + LBound bound = 255; + StringLTypeDefn string_ldefn = TypeObjectUtils::build_string_l_type_defn(bound); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_string_type_identifier(string_ldefn, + "anonymous_string_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded: Unknown String kind."); + return; + } + return_code_HelloWorld = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_string_unbounded", type_ids_HelloWorld); + if (return_code_HelloWorld != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded: Given String TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_message = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_message; + MemberId member_id_message = 0x00000001; + if (EK_COMPLETE == type_ids_HelloWorld.type_identifier1()._d() || TK_NONE == type_ids_HelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_HelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_HelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_message = TypeObjectUtils::build_common_struct_member(member_id_message, member_flags_message, type_ids_HelloWorld.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_HelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_HelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_HelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_HelloWorld.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_message = TypeObjectUtils::build_common_struct_member(member_id_message, member_flags_message, type_ids_HelloWorld.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure message member TypeIdentifier inconsistent."); + return; + } + MemberName name_message = "message"; + eprosima::fastcdr::optional member_ann_builtin_message; + ann_custom_HelloWorld.reset(); + CompleteMemberDetail detail_message = TypeObjectUtils::build_complete_member_detail(name_message, member_ann_builtin_message, ann_custom_HelloWorld); + CompleteStructMember member_message = TypeObjectUtils::build_complete_struct_member(common_message, detail_message); + TypeObjectUtils::add_complete_struct_member(member_seq_HelloWorld, member_message); + } + CompleteStructType struct_type_HelloWorld = TypeObjectUtils::build_complete_struct_type(struct_flags_HelloWorld, header_HelloWorld, member_seq_HelloWorld); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_struct_type_object(struct_type_HelloWorld, type_name_HelloWorld.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "HelloWorld already registered in TypeObjectRegistry for a different type."); + } + return_code_HelloWorld = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "HelloWorld", type_ids_HelloWorld); + if (return_code_HelloWorld != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "HelloWorld: Given Struct TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } +} + diff --git a/examples/cpp/dds/StaticHelloWorldExample/HelloWorldTypeObjectSupport.hpp b/examples/cpp/dds/StaticHelloWorldExample/HelloWorldTypeObjectSupport.hpp new file mode 100644 index 00000000000..8650fc061e0 --- /dev/null +++ b/examples/cpp/dds/StaticHelloWorldExample/HelloWorldTypeObjectSupport.hpp @@ -0,0 +1,54 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file HelloWorldTypeObjectSupport.hpp + * Header file containing the API required to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#ifndef _FAST_DDS_GENERATED_HELLOWORLD_TYPE_OBJECT_SUPPORT_HPP_ +#define _FAST_DDS_GENERATED_HELLOWORLD_TYPE_OBJECT_SUPPORT_HPP_ + + +#if defined(_WIN32) +#if defined(EPROSIMA_USER_DLL_EXPORT) +#define eProsima_user_DllExport __declspec( dllexport ) +#else +#define eProsima_user_DllExport +#endif // EPROSIMA_USER_DLL_EXPORT +#else +#define eProsima_user_DllExport +#endif // _WIN32 + +/** + * @brief Register every TypeObject representation defined in the IDL file in Fast DDS TypeObjectRegistry. + */ +eProsima_user_DllExport void register_HelloWorld_type_objects(); + +#ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +/** + * @brief Register HelloWorld related TypeIdentifier. + * Fully-descriptive TypeIdentifiers are directly registered. + * Hash TypeIdentifiers require to fill the TypeObject information and hash it, consequently, the TypeObject is + * indirectly registered as well. + */ +void register_HelloWorld_type_identifier(); + + +#endif // DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +#endif // _FAST_DDS_GENERATED_HELLOWORLD_TYPE_OBJECT_SUPPORT_HPP_ diff --git a/examples/cpp/dds/StaticHelloWorldExample/HelloWorld_main.cpp b/examples/cpp/dds/StaticHelloWorldExample/HelloWorld_main.cpp index d6806155bda..954b0f91ae8 100644 --- a/examples/cpp/dds/StaticHelloWorldExample/HelloWorld_main.cpp +++ b/examples/cpp/dds/StaticHelloWorldExample/HelloWorld_main.cpp @@ -17,15 +17,16 @@ * */ +#include + #include "HelloWorldPublisher.h" #include "HelloWorldSubscriber.h" -#include -#include - using namespace eprosima; using namespace fastrtps; using namespace rtps; +using namespace eprosima::fastdds::dds; + int main( int argc, char** argv) @@ -72,7 +73,6 @@ int main( break; } } - Domain::stopAll(); Log::Reset(); return 0; } diff --git a/examples/cpp/dds/StaticHelloWorldExample/HelloWorldv1.cxx b/examples/cpp/dds/StaticHelloWorldExample/HelloWorldv1.cxx deleted file mode 100644 index 90e82ea88a7..00000000000 --- a/examples/cpp/dds/StaticHelloWorldExample/HelloWorldv1.cxx +++ /dev/null @@ -1,286 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file HelloWorld.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "HelloWorld.h" - -#if FASTCDR_VERSION_MAJOR == 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - -namespace helper { namespace internal { - -enum class Size { - UInt8, - UInt16, - UInt32, - UInt64, -}; - -constexpr Size get_size(int s) { - return (s <= 8 ) ? Size::UInt8: - (s <= 16) ? Size::UInt16: - (s <= 32) ? Size::UInt32: Size::UInt64; -} - -template -struct FindTypeH; - -template<> -struct FindTypeH { - using type = std::uint8_t; -}; - -template<> -struct FindTypeH { - using type = std::uint16_t; -}; - -template<> -struct FindTypeH { - using type = std::uint32_t; -}; - -template<> -struct FindTypeH { - using type = std::uint64_t; -}; -} - -template -struct FindType { - using type = typename internal::FindTypeH::type; -}; -} - -#define HelloWorld_max_cdr_typesize 268ULL; - - - - -HelloWorld::HelloWorld() -{ - // unsigned long m_index - m_index = 0; - // /type_d() m_message - - -} - -HelloWorld::~HelloWorld() -{ -} - -HelloWorld::HelloWorld( - const HelloWorld& x) -{ - m_index = x.m_index; - - - m_message = x.m_message; - -} - -HelloWorld::HelloWorld( - HelloWorld&& x) noexcept -{ - m_index = x.m_index; - - - m_message = std::move(x.m_message); - -} - -HelloWorld& HelloWorld::operator =( - const HelloWorld& x) -{ - m_index = x.m_index; - - - m_message = x.m_message; - - return *this; -} - -HelloWorld& HelloWorld::operator =( - HelloWorld&& x) noexcept -{ - m_index = x.m_index; - - - m_message = std::move(x.m_message); - - return *this; -} - -bool HelloWorld::operator ==( - const HelloWorld& x) const -{ - return (m_index == x.m_index && - m_message == x.m_message); -} - -bool HelloWorld::operator !=( - const HelloWorld& x) const -{ - return !(*this == x); -} - -size_t HelloWorld::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return HelloWorld_max_cdr_typesize; -} - -size_t HelloWorld::getCdrSerializedSize( - const HelloWorld& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + data.message().size() + 1; - - - return current_alignment - initial_alignment; -} - - -void HelloWorld::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_index; - - scdr << m_message.c_str(); - -} - -void HelloWorld::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_index; - - - - dcdr >> m_message; - - -} - - -bool HelloWorld::isKeyDefined() -{ - return false; -} - -void HelloWorld::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void HelloWorld::index( - uint32_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint32_t HelloWorld::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint32_t& HelloWorld::index() -{ - return m_index; -} - - -/*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ -void HelloWorld::message( - const std::string& _message) -{ - m_message = _message; -} - -/*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ -void HelloWorld::message( - std::string&& _message) -{ - m_message = std::move(_message); -} - -/*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ -const std::string& HelloWorld::message() const -{ - return m_message; -} - -/*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ -std::string& HelloWorld::message() -{ - return m_message; -} - - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/StaticHelloWorldExample/HelloWorldv1.h b/examples/cpp/dds/StaticHelloWorldExample/HelloWorldv1.h deleted file mode 100644 index 9f6f726e0ab..00000000000 --- a/examples/cpp/dds/StaticHelloWorldExample/HelloWorldv1.h +++ /dev/null @@ -1,244 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file HelloWorld.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#include - -#if FASTCDR_VERSION_MAJOR == 1 - -#ifndef _FAST_DDS_GENERATED_HELLOWORLD_H_ -#define _FAST_DDS_GENERATED_HELLOWORLD_H_ - - -#include - -#include -#include -#include -#include -#include -#include -#include - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define eProsima_user_DllExport -#endif // _WIN32 - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(HELLOWORLD_SOURCE) -#define HELLOWORLD_DllAPI __declspec( dllexport ) -#else -#define HELLOWORLD_DllAPI __declspec( dllimport ) -#endif // HELLOWORLD_SOURCE -#else -#define HELLOWORLD_DllAPI -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define HELLOWORLD_DllAPI -#endif // _WIN32 - -namespace eprosima { -namespace fastcdr { -class Cdr; -} // namespace fastcdr -} // namespace eprosima - - - - - -/*! - * @brief This class represents the structure HelloWorld defined by the user in the IDL file. - * @ingroup HelloWorld - */ -class HelloWorld -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport HelloWorld(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~HelloWorld(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object HelloWorld that will be copied. - */ - eProsima_user_DllExport HelloWorld( - const HelloWorld& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object HelloWorld that will be copied. - */ - eProsima_user_DllExport HelloWorld( - HelloWorld&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object HelloWorld that will be copied. - */ - eProsima_user_DllExport HelloWorld& operator =( - const HelloWorld& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object HelloWorld that will be copied. - */ - eProsima_user_DllExport HelloWorld& operator =( - HelloWorld&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x HelloWorld object to compare. - */ - eProsima_user_DllExport bool operator ==( - const HelloWorld& x) const; - - /*! - * @brief Comparison operator. - * @param x HelloWorld object to compare. - */ - eProsima_user_DllExport bool operator !=( - const HelloWorld& x) const; - - /*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ - eProsima_user_DllExport void index( - uint32_t _index); - - /*! - * @brief This function returns the value of member index - * @return Value of member index - */ - eProsima_user_DllExport uint32_t index() const; - - /*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ - eProsima_user_DllExport uint32_t& index(); - - - /*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ - eProsima_user_DllExport void message( - const std::string& _message); - - /*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ - eProsima_user_DllExport void message( - std::string&& _message); - - /*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ - eProsima_user_DllExport const std::string& message() const; - - /*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ - eProsima_user_DllExport std::string& message(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const HelloWorld& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - uint32_t m_index; - std::string m_message; - -}; - - -#endif // _FAST_DDS_GENERATED_HELLOWORLD_H_ - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/TypeLookupService/CMakeLists.txt b/examples/cpp/dds/TypeLookupService/CMakeLists.txt deleted file mode 100644 index b53eb6cdae0..00000000000 --- a/examples/cpp/dds/TypeLookupService/CMakeLists.txt +++ /dev/null @@ -1,53 +0,0 @@ -# Copyright 2019 Proyectos y Sistemas de Mantenimiento SL (eProsima). -# -# Licensed 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 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -cmake_minimum_required(VERSION 3.20) - -project(TypeLookupExample VERSION 1 LANGUAGES CXX) - -# Find requirements -if(NOT fastcdr_FOUND) - find_package(fastcdr 2 REQUIRED) -endif() - -if(NOT fastrtps_FOUND) - find_package(fastrtps 2.12 REQUIRED) -endif() - -#Check C++11 -include(CheckCXXCompilerFlag) -if(CMAKE_CXX_COMPILER_ID MATCHES "GNU|Clang") - check_cxx_compiler_flag(-std=c++11 SUPPORTS_CXX11) - if(NOT SUPPORTS_CXX11) - message(FATAL_ERROR "Compiler doesn't support C++11") - endif() -endif() - -message(STATUS "Configuring TypeLookup example...") -file(GLOB DDS_TYPELOOKUP_EXAMPLE_SOURCES_CPP "*.cpp") - -add_executable(TypeLookupExample - ${DDS_TYPELOOKUP_EXAMPLE_SOURCES_CPP}) - -target_compile_definitions(TypeLookupExample PRIVATE - $<$>,$>:__DEBUG> - $<$:__INTERNALDEBUG> # Internal debug activated. -) -target_link_libraries(TypeLookupExample fastrtps fastcdr) -install(TARGETS TypeLookupExample - RUNTIME DESTINATION examples/cpp/dds/TypeLookupService/${BIN_INSTALL_DIR}) -install(FILES ${CMAKE_CURRENT_SOURCE_DIR}/example_type_profile.xml - DESTINATION examples/cpp/dds/TypeLookupService/${BIN_INSTALL_DIR}) - -file(COPY example_type_profile.xml DESTINATION ${PROJECT_BINARY_DIR}) diff --git a/examples/cpp/dds/TypeLookupService/README.txt b/examples/cpp/dds/TypeLookupService/README.txt deleted file mode 100644 index 69b047bf282..00000000000 --- a/examples/cpp/dds/TypeLookupService/README.txt +++ /dev/null @@ -1,17 +0,0 @@ -To launch this test open two different consoles: - -In the first one launch: ./TypeLookupExample publisher -(or TypeLookupExample.exe publisher on windows). -In the second one: ./TypeLookupExample subscriber -(or TypeLookupExample.exe subscriber on windows). - -In this example, the publisher loads a type from the XML file "example_type_profile.xml". -The publisher shares the TypeInformation so other participants can discover it. - -After retrieving the type using the TypeLookup service, -the subscriber will discover the type and introspecting it will show the received messages from the publisher. - -The type defined in the XML file can be modified to see how the subscriber notices the changes automatically, -but take into account that the publisher should be modified to understand the changes. - -For this example, the root type must be a structure. diff --git a/examples/cpp/dds/TypeLookupService/TypeLookupPublisher.cpp b/examples/cpp/dds/TypeLookupService/TypeLookupPublisher.cpp deleted file mode 100644 index 47e1e554712..00000000000 --- a/examples/cpp/dds/TypeLookupService/TypeLookupPublisher.cpp +++ /dev/null @@ -1,234 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file TypeLookupPublisher.cpp - * - */ - -#include "TypeLookupPublisher.h" -#include -#include -#include -#include -#include -#include -#include - -#include - -#include - -#include - -using namespace eprosima::fastdds::dds; -using namespace eprosima::fastrtps; -using namespace eprosima::fastrtps::rtps; - -TypeLookupPublisher::TypeLookupPublisher() - : mp_participant(nullptr) - , mp_publisher(nullptr) -{ -} - -bool TypeLookupPublisher::init() -{ - if (xmlparser::XMLP_ret::XML_OK != - xmlparser::XMLProfileManager::loadXMLFile("example_type_profile.xml")) - { - std::cout << "Cannot open XML file \"example_type_profile.xml\". Please, run the publisher from the folder " - << "that contatins this XML file." << std::endl; - return false; - } - - types::DynamicType_ptr dyn_type = xmlparser::XMLProfileManager::getDynamicTypeByName("TypeLookup")->build(); - TypeSupport m_type(new types::DynamicPubSubType(dyn_type)); - m_Hello = types::DynamicDataFactory::get_instance()->create_data(dyn_type); - - m_Hello->set_string_value("Hello DDS Dynamic World", 0); - m_Hello->set_uint32_value(0, 1); - types::DynamicData* inner = m_Hello->loan_value(2); - inner->set_byte_value(10, 0); - m_Hello->return_loaned_value(inner); - - DomainParticipantQos pqos; - pqos.wire_protocol().builtin.discovery_config.discoveryProtocol = SIMPLE; - pqos.wire_protocol().builtin.discovery_config.use_SIMPLE_EndpointDiscoveryProtocol = true; - pqos.wire_protocol().builtin.discovery_config.m_simpleEDP.use_PublicationReaderANDSubscriptionWriter = true; - pqos.wire_protocol().builtin.discovery_config.m_simpleEDP.use_PublicationWriterANDSubscriptionReader = true; - pqos.wire_protocol().builtin.typelookup_config.use_server = true; - pqos.wire_protocol().builtin.use_WriterLivelinessProtocol = false; - pqos.wire_protocol().builtin.discovery_config.leaseDuration = c_TimeInfinite; - pqos.name("Participant_pub"); - mp_participant = DomainParticipantFactory::get_instance()->create_participant(0, pqos); - - if (mp_participant == nullptr) - { - return false; - } - - //REGISTER THE TYPE - m_type.get()->auto_fill_type_information(true); - m_type.get()->auto_fill_type_object(false); - m_type.register_type(mp_participant); - - //CREATE THE PUBLISHER - mp_publisher = mp_participant->create_publisher(PUBLISHER_QOS_DEFAULT, nullptr); - - if (mp_publisher == nullptr) - { - return false; - } - - topic_ = mp_participant->create_topic("TypeLookupTopic", "TypeLookup", TOPIC_QOS_DEFAULT); - - if (topic_ == nullptr) - { - return false; - } - - // CREATE THE WRITER - DataWriterQos wqos; - wqos.history().kind = eprosima::fastdds::dds::KEEP_LAST_HISTORY_QOS; - wqos.history().depth = 30; - wqos.resource_limits().max_samples = 50; - wqos.resource_limits().allocated_samples = 20; - wqos.reliable_writer_qos().times.heartbeatPeriod.seconds = 2; - wqos.reliable_writer_qos().times.heartbeatPeriod.nanosec = 200 * 1000 * 1000; - writer_ = mp_publisher->create_datawriter(topic_, wqos, &m_listener); - - if (writer_ == nullptr) - { - return false; - } - - return true; - -} - -TypeLookupPublisher::~TypeLookupPublisher() -{ - if (writer_ != nullptr) - { - mp_publisher->delete_datawriter(writer_); - } - if (mp_publisher != nullptr) - { - mp_participant->delete_publisher(mp_publisher); - } - if (topic_ != nullptr) - { - mp_participant->delete_topic(topic_); - } - DomainParticipantFactory::get_instance()->delete_participant(mp_participant); -} - -void TypeLookupPublisher::PubListener::on_publication_matched( - eprosima::fastdds::dds::DataWriter*, - const eprosima::fastdds::dds::PublicationMatchedStatus& info) -{ - if (info.current_count_change == 1) - { - n_matched++; - firstConnected = true; - std::cout << "Publisher matched" << std::endl; - } - else if (info.current_count_change == -1) - { - n_matched--; - std::cout << "Publisher unmatched" << std::endl; - } - else - { - std::cout << "Publisher received an invalid value for PublicationMatchedStatus." << std::endl; - } -} - -void TypeLookupPublisher::runThread( - uint32_t samples, - uint32_t sleep) -{ - if (samples == 0) - { - while (!stop) - { - if (publish(false)) - { - std::string message; - m_Hello->get_string_value(message, 0); - uint32_t index; - m_Hello->get_uint32_value(index, 1); - std::cout << "Message: " << message << " with index: " << index << " SENT" << std::endl; - } - std::this_thread::sleep_for(std::chrono::milliseconds(sleep)); - } - } - else - { - for (uint32_t i = 0; i < samples; ++i) - { - if (!publish()) - { - --i; - } - else - { - std::string message; - m_Hello->get_string_value(message, 0); - uint32_t index; - m_Hello->get_uint32_value(index, 1); - std::cout << "Message: " << message << " with index: " << index << " SENT" << std::endl; - } - std::this_thread::sleep_for(std::chrono::milliseconds(sleep)); - } - } -} - -void TypeLookupPublisher::run( - uint32_t samples, - uint32_t sleep) -{ - stop = false; - std::thread thread(&TypeLookupPublisher::runThread, this, samples, sleep); - if (samples == 0) - { - std::cout << "Publisher running. Please press enter to stop the Publisher at any time." << std::endl; - std::cin.ignore(); - stop = true; - } - else - { - std::cout << "Publisher running " << samples << " samples." << std::endl; - } - thread.join(); -} - -bool TypeLookupPublisher::publish( - bool waitForListener) -{ - if (m_listener.firstConnected || !waitForListener || m_listener.n_matched > 0) - { - uint32_t index; - m_Hello->get_uint32_value(index, 1); - m_Hello->set_uint32_value(index + 1, 1); - types::DynamicData* inner = m_Hello->loan_value(2); - octet inner_count; - inner->get_byte_value(inner_count, 0); - inner->set_byte_value(inner_count + 1, 0); - m_Hello->return_loaned_value(inner); - writer_->write(m_Hello.get()); - return true; - } - return false; -} diff --git a/examples/cpp/dds/TypeLookupService/TypeLookupPublisher.h b/examples/cpp/dds/TypeLookupService/TypeLookupPublisher.h deleted file mode 100644 index 567ac872c1e..00000000000 --- a/examples/cpp/dds/TypeLookupService/TypeLookupPublisher.h +++ /dev/null @@ -1,94 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file TypeLookupPublisher.h - * - */ - -#ifndef HELLOWORLDPUBLISHER_H_ -#define HELLOWORLDPUBLISHER_H_ - -#include -#include - -#include -#include - -class TypeLookupPublisher -{ -public: - - TypeLookupPublisher(); - - virtual ~TypeLookupPublisher(); - - //!Initialize - bool init(); - - //!Publish a sample - bool publish( - bool waitForListener = true); - - //!Run for number samples - void run( - uint32_t number, - uint32_t sleep); - -private: - - eprosima::fastrtps::types::DynamicData_ptr m_Hello; - - eprosima::fastdds::dds::DomainParticipant* mp_participant; - - eprosima::fastdds::dds::Publisher* mp_publisher; - - eprosima::fastdds::dds::Topic* topic_; - - eprosima::fastdds::dds::DataWriter* writer_; - - bool stop; - - class PubListener : public eprosima::fastdds::dds::DataWriterListener - { - public: - - PubListener() - : n_matched(0) - , firstConnected(false) - { - } - - ~PubListener() override - { - } - - void on_publication_matched( - eprosima::fastdds::dds::DataWriter* writer, - const eprosima::fastdds::dds::PublicationMatchedStatus& info) override; - - int n_matched; - - bool firstConnected; - } - m_listener; - - void runThread( - uint32_t number, - uint32_t sleep); -}; - - - -#endif /* HELLOWORLDPUBLISHER_H_ */ diff --git a/examples/cpp/dds/TypeLookupService/TypeLookupSubscriber.cpp b/examples/cpp/dds/TypeLookupService/TypeLookupSubscriber.cpp deleted file mode 100644 index 108822411d0..00000000000 --- a/examples/cpp/dds/TypeLookupService/TypeLookupSubscriber.cpp +++ /dev/null @@ -1,267 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file TypeLookupSubscriber.cpp - * - */ - -#include "TypeLookupSubscriber.h" - -#include -#include - -#include -#include -#include -#include -#include -#include -#include -#include -#include - -using namespace eprosima::fastdds::dds; -using namespace eprosima::fastrtps; -using namespace eprosima::fastrtps::rtps; - -TypeLookupSubscriber::TypeLookupSubscriber() - : mp_participant(nullptr) - , mp_subscriber(nullptr) - , m_listener(this) -{ -} - -bool TypeLookupSubscriber::init() -{ - DomainParticipantQos pqos; - pqos.wire_protocol().builtin.discovery_config.discoveryProtocol = SIMPLE; - pqos.wire_protocol().builtin.discovery_config.use_SIMPLE_EndpointDiscoveryProtocol = true; - pqos.wire_protocol().builtin.discovery_config.m_simpleEDP.use_PublicationReaderANDSubscriptionWriter = true; - pqos.wire_protocol().builtin.discovery_config.m_simpleEDP.use_PublicationWriterANDSubscriptionReader = true; - pqos.wire_protocol().builtin.typelookup_config.use_client = true; - pqos.wire_protocol().builtin.use_WriterLivelinessProtocol = false; - pqos.wire_protocol().builtin.discovery_config.leaseDuration = c_TimeInfinite; - pqos.name("Participant_sub"); - - //Do not enable entities on creation - DomainParticipantFactoryQos factory_qos; - factory_qos.entity_factory().autoenable_created_entities = false; - DomainParticipantFactory::get_instance()->set_qos(factory_qos); - - StatusMask par_mask = StatusMask::subscription_matched() << StatusMask::data_available(); - mp_participant = DomainParticipantFactory::get_instance()->create_participant(0, pqos, &m_listener, par_mask); - if (mp_participant == nullptr) - { - return false; - } - if (mp_participant->enable() != ReturnCode_t::RETCODE_OK) - { - DomainParticipantFactory::get_instance()->delete_participant(mp_participant); - return false; - } - - // CREATE THE COMMON READER ATTRIBUTES - qos_ = DATAREADER_QOS_DEFAULT; - qos_.durability().kind = eprosima::fastdds::dds::TRANSIENT_LOCAL_DURABILITY_QOS; - qos_.reliability().kind = eprosima::fastdds::dds::RELIABLE_RELIABILITY_QOS; - qos_.history().kind = eprosima::fastdds::dds::KEEP_LAST_HISTORY_QOS; - qos_.history().depth = 30; - qos_.resource_limits().max_samples = 50; - qos_.resource_limits().allocated_samples = 20; - - return true; -} - -TypeLookupSubscriber::~TypeLookupSubscriber() -{ - for (const auto& it : topics_) - { - mp_subscriber->delete_datareader(it.first); - mp_participant->delete_topic(it.second); - } - if (mp_subscriber != nullptr) - { - mp_participant->delete_subscriber(mp_subscriber); - } - - DomainParticipantFactory::get_instance()->delete_participant(mp_participant); - topics_.clear(); - readers_.clear(); - datas_.clear(); -} - -void TypeLookupSubscriber::SubListener::on_subscription_matched( - eprosima::fastdds::dds::DataReader* reader, - const eprosima::fastdds::dds::SubscriptionMatchedStatus& info) -{ - if (info.current_count_change == 1) - { - n_matched++; - std::cout << "Subscriber matched" << std::endl; - } - else if (info.current_count_change == -1) - { - n_matched--; - std::cout << "Subscriber unmatched" << std::endl; - auto itr = subscriber_->readers_.find(reader); - if (itr != subscriber_->readers_.end()) - { - subscriber_->readers_.erase(itr); - } - - auto itd = subscriber_->datas_.find(reader); - if (itd != subscriber_->datas_.end()) - { - subscriber_->datas_.erase(itd); - } - - if (subscriber_->mp_subscriber != nullptr) - { - subscriber_->mp_subscriber->delete_datareader(reader); - } - } - else - { - std::cout << "Subscriber received an invalid value for SubscriptionMatchedStatus." << std::endl; - } -} - -void TypeLookupSubscriber::SubListener::on_data_available( - eprosima::fastdds::dds::DataReader* reader) -{ - auto dit = subscriber_->datas_.find(reader); - - if (dit != subscriber_->datas_.end()) - { - types::DynamicData_ptr data = dit->second; - SampleInfo info; - if (reader->take_next_sample(data.get(), &info) == ReturnCode_t::RETCODE_OK) - { - if (info.valid_data) - { - types::DynamicType_ptr type = subscriber_->readers_[reader]; - this->n_samples++; - std::cout << "Received data of type " << type->get_name() << std::endl; - types::DynamicDataHelper::print(data); - } - } - } -} - -void TypeLookupSubscriber::SubListener::on_type_information_received( - eprosima::fastdds::dds::DomainParticipant*, - const eprosima::fastrtps::string_255 topic_name, - const eprosima::fastrtps::string_255 type_name, - const eprosima::fastrtps::types::TypeInformation& type_information) -{ - std::function callback = - [this, topic_name](const std::string& name, const types::DynamicType_ptr type) - { - std::cout << "Discovered type: " << name << " from topic " << topic_name << std::endl; - - if (subscriber_->mp_subscriber == nullptr) - { - //SubscriberAttributes Rparam; - //Rparam = subscriber_->att_; - //Rparam.topic = subscriber_->topic_; - //Rparam.topic.topicName = topic_name; - //Rparam.qos = subscriber_->qos_; - subscriber_->mp_subscriber = subscriber_->mp_participant->create_subscriber( - SUBSCRIBER_QOS_DEFAULT, nullptr); - - if (subscriber_->mp_subscriber == nullptr) - { - return; - } - } - - //CREATE THE TOPIC - eprosima::fastdds::dds::Topic* topic = subscriber_->mp_participant->create_topic( - "TypeLookupTopic", - name, - TOPIC_QOS_DEFAULT); - - if (topic == nullptr) - { - return; - } - - StatusMask sub_mask = StatusMask::subscription_matched() << StatusMask::data_available(); - DataReader* reader = subscriber_->mp_subscriber->create_datareader( - topic, - subscriber_->qos_, - &subscriber_->m_listener, - sub_mask); - - if (type == nullptr) - { - const types::TypeIdentifier* ident = - types::TypeObjectFactory::get_instance()->get_type_identifier_trying_complete(name); - - if (nullptr != ident) - { - const types::TypeObject* obj = - types::TypeObjectFactory::get_instance()->get_type_object(ident); - - types::DynamicType_ptr dyn_type = - types::TypeObjectFactory::get_instance()->build_dynamic_type(name, ident, obj); - - if (nullptr != dyn_type) - { - subscriber_->readers_[reader] = dyn_type; - types::DynamicData_ptr data( - types::DynamicDataFactory::get_instance()->create_data(dyn_type)); - subscriber_->datas_[reader] = data; - } - else - { - std::cout << "ERROR: DynamicType cannot be created for type: " << name << std::endl; - } - } - else - { - std::cout << "ERROR: TypeIdentifier cannot be retrieved for type: " << name << std::endl; - } - } - else - { - subscriber_->topics_[reader] = topic; - subscriber_->readers_[reader] = type; - types::DynamicData_ptr data(types::DynamicDataFactory::get_instance()->create_data(type)); - subscriber_->datas_[reader] = data; - } - }; - - subscriber_->mp_participant->register_remote_type( - type_information, - type_name.to_string(), - callback); -} - -void TypeLookupSubscriber::run() -{ - std::cout << "Subscriber running. Please press enter to stop the Subscriber" << std::endl; - std::cin.ignore(); -} - -void TypeLookupSubscriber::run( - uint32_t number) -{ - std::cout << "Subscriber running until " << number << " samples have been received" << std::endl; - while (number > this->m_listener.n_samples) - { - std::this_thread::sleep_for(std::chrono::milliseconds(500)); - } -} diff --git a/examples/cpp/dds/TypeLookupService/TypeLookupSubscriber.h b/examples/cpp/dds/TypeLookupService/TypeLookupSubscriber.h deleted file mode 100644 index 07654ce8019..00000000000 --- a/examples/cpp/dds/TypeLookupService/TypeLookupSubscriber.h +++ /dev/null @@ -1,120 +0,0 @@ -// Copyright 2019 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file TypeLookupSubscriber.h - * - */ - -#ifndef HELLOWORLDSUBSCRIBER_H_ -#define HELLOWORLDSUBSCRIBER_H_ - -#include -#include -#include -#include -#include -#include - -#include -#include - -#include - -#include - -class TypeLookupSubscriber -{ -public: - - TypeLookupSubscriber(); - - virtual ~TypeLookupSubscriber(); - - //!Initialize the subscriber - bool init(); - - //!RUN the subscriber - void run(); - - //!Run the subscriber until number samples have been received. - void run( - uint32_t number); - -private: - - eprosima::fastdds::dds::DomainParticipant* mp_participant; - - eprosima::fastdds::dds::Subscriber* mp_subscriber; - - std::map topics_; - - std::map readers_; - - std::map datas_; - - eprosima::fastrtps::SubscriberAttributes att_; - - eprosima::fastdds::dds::DataReaderQos qos_; - -public: - - class SubListener - : public eprosima::fastdds::dds::DomainParticipantListener - { - public: - - SubListener( - TypeLookupSubscriber* sub) - : n_matched(0) - , n_samples(0) - , subscriber_(sub) - { - } - - ~SubListener() override - { - } - - void on_data_available( - eprosima::fastdds::dds::DataReader* reader) override; - - void on_subscription_matched( - eprosima::fastdds::dds::DataReader* reader, - const eprosima::fastdds::dds::SubscriptionMatchedStatus& info) override; - - void on_type_information_received( - eprosima::fastdds::dds::DomainParticipant* participant, - const eprosima::fastrtps::string_255 topic_name, - const eprosima::fastrtps::string_255 type_name, - const eprosima::fastrtps::types::TypeInformation& type_information) override; - - int n_matched; - - uint32_t n_samples; - - TypeLookupSubscriber* subscriber_; - - std::map topic_type_map_; - - eprosima::fastrtps::types::TypeInformation type_info_; - } - m_listener; - -private: - - eprosima::fastrtps::types::DynamicPubSubType m_type; -}; - -#endif /* HELLOWORLDSUBSCRIBER_H_ */ diff --git a/examples/cpp/dds/TypeLookupService/TypeLookup_main.cpp b/examples/cpp/dds/TypeLookupService/TypeLookup_main.cpp deleted file mode 100644 index cf11cf2a71c..00000000000 --- a/examples/cpp/dds/TypeLookupService/TypeLookup_main.cpp +++ /dev/null @@ -1,84 +0,0 @@ -// Copyright 2019 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file TypeLookup_main.cpp - * - */ - -#include "TypeLookupPublisher.h" -#include "TypeLookupSubscriber.h" - -#include - -using namespace eprosima::fastrtps; - -int main( - int argc, - char** argv) -{ - std::cout << "Starting " << std::endl; - int type = 1; - int count = 5; - long sleep = 100; - if (argc > 1) - { - if (strcmp(argv[1], "publisher") == 0) - { - type = 1; - if (argc >= 3) - { - count = atoi(argv[2]); - if (argc == 4) - { - sleep = atoi(argv[3]); - } - } - } - else if (strcmp(argv[1], "subscriber") == 0) - { - type = 2; - } - } - else - { - std::cout << "publisher OR subscriber argument needed" << std::endl; - Log::Reset(); - return 0; - } - - switch (type) - { - case 1: - { - TypeLookupPublisher mypub; - if (mypub.init()) - { - mypub.run(count, sleep); - } - break; - } - case 2: - { - TypeLookupSubscriber mysub; - if (mysub.init()) - { - mysub.run(); - } - break; - } - } - Log::Reset(); - return 0; -} diff --git a/examples/cpp/dds/TypeLookupService/example_type_profile.xml b/examples/cpp/dds/TypeLookupService/example_type_profile.xml deleted file mode 100644 index d11369f1e39..00000000000 --- a/examples/cpp/dds/TypeLookupService/example_type_profile.xml +++ /dev/null @@ -1,15 +0,0 @@ - - - - - - - - - - - - - - - diff --git a/examples/cpp/dds/WriterLoansExample/CMakeLists.txt b/examples/cpp/dds/WriterLoansExample/CMakeLists.txt index 4aceabc3907..7acc8fa94ac 100644 --- a/examples/cpp/dds/WriterLoansExample/CMakeLists.txt +++ b/examples/cpp/dds/WriterLoansExample/CMakeLists.txt @@ -21,8 +21,8 @@ if(NOT fastcdr_FOUND) find_package(fastcdr 2 REQUIRED) endif() -if(NOT fastrtps_FOUND) - find_package(fastrtps 2.12 REQUIRED) +if(NOT fastdds_FOUND) + find_package(fastdds 3 REQUIRED) endif() #Check C++11 @@ -43,6 +43,6 @@ target_compile_definitions(DDSWriterLoansExample PRIVATE $<$>,$>:__DEBUG> $<$:__INTERNALDEBUG> # Internal debug activated. ) -target_link_libraries(DDSWriterLoansExample fastrtps fastcdr) +target_link_libraries(DDSWriterLoansExample fastdds fastcdr) install(TARGETS DDSWriterLoansExample RUNTIME DESTINATION examples/cpp/dds/WriterLoansExample/${BIN_INSTALL_DIR}) diff --git a/examples/cpp/dds/WriterLoansExample/LoanableHelloWorld.cxx b/examples/cpp/dds/WriterLoansExample/LoanableHelloWorld.cxx deleted file mode 100644 index 54ca2b05ab0..00000000000 --- a/examples/cpp/dds/WriterLoansExample/LoanableHelloWorld.cxx +++ /dev/null @@ -1,168 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file LoanableHelloWorld.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "LoanableHelloWorld.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - - - - -LoanableHelloWorld::LoanableHelloWorld() -{ -} - -LoanableHelloWorld::~LoanableHelloWorld() -{ -} - -LoanableHelloWorld::LoanableHelloWorld( - const LoanableHelloWorld& x) -{ - m_index = x.m_index; - m_message = x.m_message; -} - -LoanableHelloWorld::LoanableHelloWorld( - LoanableHelloWorld&& x) noexcept -{ - m_index = x.m_index; - m_message = std::move(x.m_message); -} - -LoanableHelloWorld& LoanableHelloWorld::operator =( - const LoanableHelloWorld& x) -{ - - m_index = x.m_index; - m_message = x.m_message; - return *this; -} - -LoanableHelloWorld& LoanableHelloWorld::operator =( - LoanableHelloWorld&& x) noexcept -{ - - m_index = x.m_index; - m_message = std::move(x.m_message); - return *this; -} - -bool LoanableHelloWorld::operator ==( - const LoanableHelloWorld& x) const -{ - return (m_index == x.m_index && - m_message == x.m_message); -} - -bool LoanableHelloWorld::operator !=( - const LoanableHelloWorld& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void LoanableHelloWorld::index( - uint32_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint32_t LoanableHelloWorld::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint32_t& LoanableHelloWorld::index() -{ - return m_index; -} - - -/*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ -void LoanableHelloWorld::message( - const std::array& _message) -{ - m_message = _message; -} - -/*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ -void LoanableHelloWorld::message( - std::array&& _message) -{ - m_message = std::move(_message); -} - -/*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ -const std::array& LoanableHelloWorld::message() const -{ - return m_message; -} - -/*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ -std::array& LoanableHelloWorld::message() -{ - return m_message; -} - - -// Include auxiliary functions like for serializing/deserializing. -#include "LoanableHelloWorldCdrAux.ipp" - -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/WriterLoansExample/LoanableHelloWorld.h b/examples/cpp/dds/WriterLoansExample/LoanableHelloWorld.hpp similarity index 69% rename from examples/cpp/dds/WriterLoansExample/LoanableHelloWorld.h rename to examples/cpp/dds/WriterLoansExample/LoanableHelloWorld.hpp index 80d8feaca9b..1567811078c 100644 --- a/examples/cpp/dds/WriterLoansExample/LoanableHelloWorld.h +++ b/examples/cpp/dds/WriterLoansExample/LoanableHelloWorld.hpp @@ -13,32 +13,18 @@ // limitations under the License. /*! - * @file LoanableHelloWorld.h + * @file LoanableHelloWorld.hpp * This header file contains the declaration of the described types in the IDL file. * * This file was generated by the tool fastddsgen. */ -#include -#include "LoanableHelloWorldv1.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#ifndef _FAST_DDS_GENERATED_LOANABLEHELLOWORLD_H_ -#define _FAST_DDS_GENERATED_LOANABLEHELLOWORLD_H_ +#ifndef _FAST_DDS_GENERATED_LOANABLEHELLOWORLD_HPP_ +#define _FAST_DDS_GENERATED_LOANABLEHELLOWORLD_HPP_ #include -#include #include -#include -#include -#include - -#include -#include -#include - - +#include #if defined(_WIN32) #if defined(EPROSIMA_USER_DLL_EXPORT) @@ -64,17 +50,6 @@ #define LOANABLEHELLOWORLD_DllAPI #endif // _WIN32 -namespace eprosima { -namespace fastcdr { -class Cdr; -class CdrSizeCalculator; -} // namespace fastcdr -} // namespace eprosima - - - - - /*! * @brief This class represents the structure LoanableHelloWorld defined by the user in the IDL file. * @ingroup LoanableHelloWorld @@ -86,73 +61,117 @@ class LoanableHelloWorld /*! * @brief Default constructor. */ - eProsima_user_DllExport LoanableHelloWorld(); + eProsima_user_DllExport LoanableHelloWorld() + { + } /*! * @brief Default destructor. */ - eProsima_user_DllExport ~LoanableHelloWorld(); + eProsima_user_DllExport ~LoanableHelloWorld() + { + } /*! * @brief Copy constructor. * @param x Reference to the object LoanableHelloWorld that will be copied. */ eProsima_user_DllExport LoanableHelloWorld( - const LoanableHelloWorld& x); + const LoanableHelloWorld& x) + { + m_index = x.m_index; + + m_message = x.m_message; + + } /*! * @brief Move constructor. * @param x Reference to the object LoanableHelloWorld that will be copied. */ eProsima_user_DllExport LoanableHelloWorld( - LoanableHelloWorld&& x) noexcept; + LoanableHelloWorld&& x) noexcept + { + m_index = x.m_index; + m_message = std::move(x.m_message); + } /*! * @brief Copy assignment. * @param x Reference to the object LoanableHelloWorld that will be copied. */ eProsima_user_DllExport LoanableHelloWorld& operator =( - const LoanableHelloWorld& x); + const LoanableHelloWorld& x) + { + + m_index = x.m_index; + + m_message = x.m_message; + + return *this; + } /*! * @brief Move assignment. * @param x Reference to the object LoanableHelloWorld that will be copied. */ eProsima_user_DllExport LoanableHelloWorld& operator =( - LoanableHelloWorld&& x) noexcept; + LoanableHelloWorld&& x) noexcept + { + + m_index = x.m_index; + m_message = std::move(x.m_message); + return *this; + } /*! * @brief Comparison operator. * @param x LoanableHelloWorld object to compare. */ eProsima_user_DllExport bool operator ==( - const LoanableHelloWorld& x) const; + const LoanableHelloWorld& x) const + { + return (m_index == x.m_index && + m_message == x.m_message); + } /*! * @brief Comparison operator. * @param x LoanableHelloWorld object to compare. */ eProsima_user_DllExport bool operator !=( - const LoanableHelloWorld& x) const; + const LoanableHelloWorld& x) const + { + return !(*this == x); + } /*! * @brief This function sets a value in member index * @param _index New value for member index */ eProsima_user_DllExport void index( - uint32_t _index); + uint32_t _index) + { + m_index = _index; + } /*! * @brief This function returns the value of member index * @return Value of member index */ - eProsima_user_DllExport uint32_t index() const; + eProsima_user_DllExport uint32_t index() const + { + return m_index; + } /*! * @brief This function returns a reference to member index * @return Reference to member index */ - eProsima_user_DllExport uint32_t& index(); + eProsima_user_DllExport uint32_t& index() + { + return m_index; + } /*! @@ -160,26 +179,40 @@ class LoanableHelloWorld * @param _message New value to be copied in member message */ eProsima_user_DllExport void message( - const std::array& _message); + const std::array& _message) + { + m_message = _message; + } /*! * @brief This function moves the value in member message * @param _message New value to be moved in member message */ eProsima_user_DllExport void message( - std::array&& _message); + std::array&& _message) + { + m_message = std::move(_message); + } /*! * @brief This function returns a constant reference to member message * @return Constant reference to member message */ - eProsima_user_DllExport const std::array& message() const; + eProsima_user_DllExport const std::array& message() const + { + return m_message; + } /*! * @brief This function returns a reference to member message * @return Reference to member message */ - eProsima_user_DllExport std::array& message(); + eProsima_user_DllExport std::array& message() + { + return m_message; + } + + private: @@ -188,8 +221,6 @@ class LoanableHelloWorld }; -#endif // _FAST_DDS_GENERATED_LOANABLEHELLOWORLD_H_ - +#endif // _FAST_DDS_GENERATED_LOANABLEHELLOWORLD_HPP_ -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/WriterLoansExample/LoanableHelloWorldCdrAux.hpp b/examples/cpp/dds/WriterLoansExample/LoanableHelloWorldCdrAux.hpp index c29aaedaaff..8fc200fee77 100644 --- a/examples/cpp/dds/WriterLoansExample/LoanableHelloWorldCdrAux.hpp +++ b/examples/cpp/dds/WriterLoansExample/LoanableHelloWorldCdrAux.hpp @@ -22,7 +22,7 @@ #ifndef _FAST_DDS_GENERATED_LOANABLEHELLOWORLDCDRAUX_HPP_ #define _FAST_DDS_GENERATED_LOANABLEHELLOWORLDCDRAUX_HPP_ -#include "LoanableHelloWorld.h" +#include "LoanableHelloWorld.hpp" constexpr uint32_t LoanableHelloWorld_max_cdr_typesize {260UL}; constexpr uint32_t LoanableHelloWorld_max_key_cdr_typesize {0UL}; @@ -34,8 +34,6 @@ namespace fastcdr { class Cdr; class CdrSizeCalculator; - - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const LoanableHelloWorld& data); diff --git a/examples/cpp/dds/WriterLoansExample/LoanableHelloWorldCdrAux.ipp b/examples/cpp/dds/WriterLoansExample/LoanableHelloWorldCdrAux.ipp index 640061e832c..2c932b2b441 100644 --- a/examples/cpp/dds/WriterLoansExample/LoanableHelloWorldCdrAux.ipp +++ b/examples/cpp/dds/WriterLoansExample/LoanableHelloWorldCdrAux.ipp @@ -34,8 +34,6 @@ using namespace eprosima::fastcdr::exception; namespace eprosima { namespace fastcdr { - - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, diff --git a/examples/cpp/dds/WriterLoansExample/LoanableHelloWorldPubSubTypes.cxx b/examples/cpp/dds/WriterLoansExample/LoanableHelloWorldPubSubTypes.cxx index 668ff484ea0..5ce26c2a2ed 100644 --- a/examples/cpp/dds/WriterLoansExample/LoanableHelloWorldPubSubTypes.cxx +++ b/examples/cpp/dds/WriterLoansExample/LoanableHelloWorldPubSubTypes.cxx @@ -19,18 +19,18 @@ * This file was generated by the tool fastddsgen. */ +#include "LoanableHelloWorldPubSubTypes.h" +#include #include -#include "LoanableHelloWorldPubSubTypes.h" #include "LoanableHelloWorldCdrAux.hpp" +#include "LoanableHelloWorldTypeObjectSupport.hpp" using SerializedPayload_t = eprosima::fastrtps::rtps::SerializedPayload_t; using InstanceHandle_t = eprosima::fastrtps::rtps::InstanceHandle_t; using DataRepresentationId_t = eprosima::fastdds::dds::DataRepresentationId_t; - - LoanableHelloWorldPubSubType::LoanableHelloWorldPubSubType() { setName("LoanableHelloWorld"); @@ -219,3 +219,11 @@ bool LoanableHelloWorldPubSubType::getKey( return true; } +void LoanableHelloWorldPubSubType::register_type_object_representation() const +{ + register_LoanableHelloWorld_type_objects(); +} + + +// Include auxiliary functions like for serializing/deserializing. +#include "LoanableHelloWorldCdrAux.ipp" diff --git a/examples/cpp/dds/WriterLoansExample/LoanableHelloWorldPubSubTypes.h b/examples/cpp/dds/WriterLoansExample/LoanableHelloWorldPubSubTypes.h index 06ba8663ef8..33525ee7726 100644 --- a/examples/cpp/dds/WriterLoansExample/LoanableHelloWorldPubSubTypes.h +++ b/examples/cpp/dds/WriterLoansExample/LoanableHelloWorldPubSubTypes.h @@ -27,9 +27,9 @@ #include #include #include -#include +#include -#include "LoanableHelloWorld.h" +#include "LoanableHelloWorld.hpp" #if !defined(GEN_API_VER) || (GEN_API_VER != 2) @@ -38,8 +38,6 @@ #endif // GEN_API_VER - - #ifndef SWIG namespace detail { @@ -123,6 +121,9 @@ class LoanableHelloWorldPubSubType : public eprosima::fastdds::dds::TopicDataTyp eProsima_user_DllExport void deleteData( void* data) override; + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + #ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED eProsima_user_DllExport inline bool is_bounded() const override { diff --git a/examples/cpp/dds/WriterLoansExample/LoanableHelloWorldPublisher.cxx b/examples/cpp/dds/WriterLoansExample/LoanableHelloWorldPublisher.cxx index 44ec5a404fd..9407dce4f3d 100644 --- a/examples/cpp/dds/WriterLoansExample/LoanableHelloWorldPublisher.cxx +++ b/examples/cpp/dds/WriterLoansExample/LoanableHelloWorldPublisher.cxx @@ -140,7 +140,7 @@ void LoanableHelloWorldPublisher::run() if (ch == 'y') { void* sample = nullptr; - if (ReturnCode_t::RETCODE_OK == writer_->loan_sample(sample)) + if (RETCODE_OK == writer_->loan_sample(sample)) { LoanableHelloWorld* data = static_cast(sample); data->index() = msgsent + 1; diff --git a/examples/cpp/dds/WriterLoansExample/LoanableHelloWorldSubscriber.cxx b/examples/cpp/dds/WriterLoansExample/LoanableHelloWorldSubscriber.cxx index 6ebf7a6f077..dfa87a321bb 100644 --- a/examples/cpp/dds/WriterLoansExample/LoanableHelloWorldSubscriber.cxx +++ b/examples/cpp/dds/WriterLoansExample/LoanableHelloWorldSubscriber.cxx @@ -127,7 +127,7 @@ void LoanableHelloWorldSubscriber::SubListener::on_data_available( LoanableHelloWorld st; SampleInfo info; - if (reader->take_next_sample(&st, &info) == ReturnCode_t::RETCODE_OK) + if (reader->take_next_sample(&st, &info) == RETCODE_OK) { if (info.instance_state == ALIVE_INSTANCE_STATE) { diff --git a/examples/cpp/dds/WriterLoansExample/LoanableHelloWorldTypeObjectSupport.cxx b/examples/cpp/dds/WriterLoansExample/LoanableHelloWorldTypeObjectSupport.cxx new file mode 100644 index 00000000000..212eb4a6d62 --- /dev/null +++ b/examples/cpp/dds/WriterLoansExample/LoanableHelloWorldTypeObjectSupport.cxx @@ -0,0 +1,313 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file LoanableHelloWorldTypeObjectSupport.cxx + * Source file containing the implementation to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#include "LoanableHelloWorldTypeObjectSupport.hpp" + +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include + +#include "LoanableHelloWorld.hpp" + + +using namespace eprosima::fastdds::dds::xtypes; + +void register_LoanableHelloWorld_type_objects() +{ + static std::once_flag once_flag; + std::call_once(once_flag, []() + { + register_LoanableHelloWorld_type_identifier(); + + }); +} + +void register_LoanableHelloWorld_type_identifier() +{ + { + StructTypeFlag struct_flags_LoanableHelloWorld = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::FINAL, + false, false); + ReturnCode_t return_code_LoanableHelloWorld; + TypeIdentifierPair type_ids_LoanableHelloWorld; + QualifiedTypeName type_name_LoanableHelloWorld = "LoanableHelloWorld"; + eprosima::fastcdr::optional type_ann_builtin_LoanableHelloWorld; + eprosima::fastcdr::optional ann_custom_LoanableHelloWorld; + AppliedAnnotationSeq tmp_ann_custom_LoanableHelloWorld; + eprosima::fastcdr::optional verbatim_LoanableHelloWorld; + if (!tmp_ann_custom_LoanableHelloWorld.empty()) + { + ann_custom_LoanableHelloWorld = tmp_ann_custom_LoanableHelloWorld; + } + + CompleteTypeDetail detail_LoanableHelloWorld = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_LoanableHelloWorld, ann_custom_LoanableHelloWorld, type_name_LoanableHelloWorld.to_string()); + CompleteStructHeader header_LoanableHelloWorld; + header_LoanableHelloWorld = TypeObjectUtils::build_complete_struct_header(TypeIdentifier(), detail_LoanableHelloWorld); + CompleteStructMemberSeq member_seq_LoanableHelloWorld; + { + return_code_LoanableHelloWorld = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_uint32_t", type_ids_LoanableHelloWorld); + + if (return_code_LoanableHelloWorld != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "index Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_index = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_index; + MemberId member_id_index = 0x00000000; + if (EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1()._d() || TK_NONE == type_ids_LoanableHelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_LoanableHelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_LoanableHelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_LoanableHelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_LoanableHelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_LoanableHelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_LoanableHelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_LoanableHelloWorld.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_LoanableHelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_LoanableHelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_LoanableHelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_LoanableHelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_LoanableHelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_LoanableHelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_LoanableHelloWorld.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure index member TypeIdentifier inconsistent."); + return; + } + MemberName name_index = "index"; + eprosima::fastcdr::optional member_ann_builtin_index; + ann_custom_LoanableHelloWorld.reset(); + CompleteMemberDetail detail_index = TypeObjectUtils::build_complete_member_detail(name_index, member_ann_builtin_index, ann_custom_LoanableHelloWorld); + CompleteStructMember member_index = TypeObjectUtils::build_complete_struct_member(common_index, detail_index); + TypeObjectUtils::add_complete_struct_member(member_seq_LoanableHelloWorld, member_index); + } + { + return_code_LoanableHelloWorld = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_array_char_256", type_ids_LoanableHelloWorld); + + if (return_code_LoanableHelloWorld != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_LoanableHelloWorld = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_char", type_ids_LoanableHelloWorld); + + if (return_code_LoanableHelloWorld != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Array element TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + TypeIdentifier* element_identifier_anonymous_array_char_256 {nullptr}; + if (EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1()._d() || TK_NONE == type_ids_LoanableHelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_LoanableHelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_LoanableHelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_LoanableHelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_LoanableHelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_LoanableHelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_LoanableHelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_array_char_256 = new TypeIdentifier(type_ids_LoanableHelloWorld.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_LoanableHelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_LoanableHelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_LoanableHelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_LoanableHelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_LoanableHelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_LoanableHelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_array_char_256 = new TypeIdentifier(type_ids_LoanableHelloWorld.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Array element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_array_char_256 = EK_COMPLETE; + if (TK_NONE == type_ids_LoanableHelloWorld.type_identifier2()._d()) + { + equiv_kind_anonymous_array_char_256 = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_array_char_256 = 0; + PlainCollectionHeader header_anonymous_array_char_256 = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_array_char_256, element_flags_anonymous_array_char_256); + std::string type_id_kind_anonymous_array_char_256("TI_PLAIN_ARRAY_LARGE"); + if (type_id_kind_anonymous_array_char_256 == "TI_PLAIN_ARRAY_SMALL") + { + SBoundSeq array_bound_seq; + TypeObjectUtils::add_array_dimension(array_bound_seq, static_cast(256)); + + PlainArraySElemDefn array_sdefn = TypeObjectUtils::build_plain_array_s_elem_defn(header_anonymous_array_char_256, array_bound_seq, + eprosima::fastcdr::external(element_identifier_anonymous_array_char_256)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_array_type_identifier(array_sdefn, "anonymous_array_char_256")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_char_256 already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBoundSeq array_bound_seq; + TypeObjectUtils::add_array_dimension(array_bound_seq, static_cast(256)); + + PlainArrayLElemDefn array_ldefn = TypeObjectUtils::build_plain_array_l_elem_defn(header_anonymous_array_char_256, array_bound_seq, + eprosima::fastcdr::external(element_identifier_anonymous_array_char_256)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_array_type_identifier(array_ldefn, "anonymous_array_char_256")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_char_256 already registered in TypeObjectRegistry for a different type."); + } + } + return_code_LoanableHelloWorld = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_array_char_256", type_ids_LoanableHelloWorld); + if (return_code_LoanableHelloWorld != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_char_256: Given Array TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_message = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_message; + MemberId member_id_message = 0x00000001; + if (EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1()._d() || TK_NONE == type_ids_LoanableHelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_LoanableHelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_LoanableHelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_LoanableHelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_LoanableHelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_LoanableHelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_LoanableHelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_message = TypeObjectUtils::build_common_struct_member(member_id_message, member_flags_message, type_ids_LoanableHelloWorld.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_LoanableHelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_LoanableHelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_LoanableHelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_LoanableHelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_LoanableHelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_LoanableHelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_message = TypeObjectUtils::build_common_struct_member(member_id_message, member_flags_message, type_ids_LoanableHelloWorld.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure message member TypeIdentifier inconsistent."); + return; + } + MemberName name_message = "message"; + eprosima::fastcdr::optional member_ann_builtin_message; + ann_custom_LoanableHelloWorld.reset(); + CompleteMemberDetail detail_message = TypeObjectUtils::build_complete_member_detail(name_message, member_ann_builtin_message, ann_custom_LoanableHelloWorld); + CompleteStructMember member_message = TypeObjectUtils::build_complete_struct_member(common_message, detail_message); + TypeObjectUtils::add_complete_struct_member(member_seq_LoanableHelloWorld, member_message); + } + CompleteStructType struct_type_LoanableHelloWorld = TypeObjectUtils::build_complete_struct_type(struct_flags_LoanableHelloWorld, header_LoanableHelloWorld, member_seq_LoanableHelloWorld); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_struct_type_object(struct_type_LoanableHelloWorld, type_name_LoanableHelloWorld.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "LoanableHelloWorld already registered in TypeObjectRegistry for a different type."); + } + return_code_LoanableHelloWorld = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "LoanableHelloWorld", type_ids_LoanableHelloWorld); + if (return_code_LoanableHelloWorld != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "LoanableHelloWorld: Given Struct TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } +} + diff --git a/examples/cpp/dds/WriterLoansExample/LoanableHelloWorldTypeObjectSupport.hpp b/examples/cpp/dds/WriterLoansExample/LoanableHelloWorldTypeObjectSupport.hpp new file mode 100644 index 00000000000..101fafc55f4 --- /dev/null +++ b/examples/cpp/dds/WriterLoansExample/LoanableHelloWorldTypeObjectSupport.hpp @@ -0,0 +1,54 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file LoanableHelloWorldTypeObjectSupport.hpp + * Header file containing the API required to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#ifndef _FAST_DDS_GENERATED_LOANABLEHELLOWORLD_TYPE_OBJECT_SUPPORT_HPP_ +#define _FAST_DDS_GENERATED_LOANABLEHELLOWORLD_TYPE_OBJECT_SUPPORT_HPP_ + + +#if defined(_WIN32) +#if defined(EPROSIMA_USER_DLL_EXPORT) +#define eProsima_user_DllExport __declspec( dllexport ) +#else +#define eProsima_user_DllExport +#endif // EPROSIMA_USER_DLL_EXPORT +#else +#define eProsima_user_DllExport +#endif // _WIN32 + +/** + * @brief Register every TypeObject representation defined in the IDL file in Fast DDS TypeObjectRegistry. + */ +eProsima_user_DllExport void register_LoanableHelloWorld_type_objects(); + +#ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +/** + * @brief Register LoanableHelloWorld related TypeIdentifier. + * Fully-descriptive TypeIdentifiers are directly registered. + * Hash TypeIdentifiers require to fill the TypeObject information and hash it, consequently, the TypeObject is + * indirectly registered as well. + */ +void register_LoanableHelloWorld_type_identifier(); + + +#endif // DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +#endif // _FAST_DDS_GENERATED_LOANABLEHELLOWORLD_TYPE_OBJECT_SUPPORT_HPP_ diff --git a/examples/cpp/dds/WriterLoansExample/LoanableHelloWorldv1.cxx b/examples/cpp/dds/WriterLoansExample/LoanableHelloWorldv1.cxx deleted file mode 100644 index 63da3dfddbc..00000000000 --- a/examples/cpp/dds/WriterLoansExample/LoanableHelloWorldv1.cxx +++ /dev/null @@ -1,288 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file LoanableHelloWorld.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "LoanableHelloWorld.h" - -#if FASTCDR_VERSION_MAJOR == 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - -namespace helper { namespace internal { - -enum class Size { - UInt8, - UInt16, - UInt32, - UInt64, -}; - -constexpr Size get_size(int s) { - return (s <= 8 ) ? Size::UInt8: - (s <= 16) ? Size::UInt16: - (s <= 32) ? Size::UInt32: Size::UInt64; -} - -template -struct FindTypeH; - -template<> -struct FindTypeH { - using type = std::uint8_t; -}; - -template<> -struct FindTypeH { - using type = std::uint16_t; -}; - -template<> -struct FindTypeH { - using type = std::uint32_t; -}; - -template<> -struct FindTypeH { - using type = std::uint64_t; -}; -} - -template -struct FindType { - using type = typename internal::FindTypeH::type; -}; -} - -#define LoanableHelloWorld_max_cdr_typesize 260ULL; - - - - -LoanableHelloWorld::LoanableHelloWorld() -{ - // unsigned long m_index - m_index = 0; - // char m_message - memset(&m_message, 0, ((256)) * 1); - -} - -LoanableHelloWorld::~LoanableHelloWorld() -{ -} - -LoanableHelloWorld::LoanableHelloWorld( - const LoanableHelloWorld& x) -{ - m_index = x.m_index; - - - m_message = x.m_message; - -} - -LoanableHelloWorld::LoanableHelloWorld( - LoanableHelloWorld&& x) noexcept -{ - m_index = x.m_index; - - - m_message = std::move(x.m_message); - -} - -LoanableHelloWorld& LoanableHelloWorld::operator =( - const LoanableHelloWorld& x) -{ - m_index = x.m_index; - - - m_message = x.m_message; - - return *this; -} - -LoanableHelloWorld& LoanableHelloWorld::operator =( - LoanableHelloWorld&& x) noexcept -{ - m_index = x.m_index; - - - m_message = std::move(x.m_message); - - return *this; -} - -bool LoanableHelloWorld::operator ==( - const LoanableHelloWorld& x) const -{ - return (m_index == x.m_index && - m_message == x.m_message); -} - -bool LoanableHelloWorld::operator !=( - const LoanableHelloWorld& x) const -{ - return !(*this == x); -} - -size_t LoanableHelloWorld::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return LoanableHelloWorld_max_cdr_typesize; -} - -size_t LoanableHelloWorld::getCdrSerializedSize( - const LoanableHelloWorld& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += (((256)) * 1) + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - - return current_alignment - initial_alignment; -} - - -void LoanableHelloWorld::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_index; - - scdr << m_message; - - -} - -void LoanableHelloWorld::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_index; - - - - dcdr >> m_message; - - -} - - -bool LoanableHelloWorld::isKeyDefined() -{ - return false; -} - -void LoanableHelloWorld::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void LoanableHelloWorld::index( - uint32_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint32_t LoanableHelloWorld::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint32_t& LoanableHelloWorld::index() -{ - return m_index; -} - - -/*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ -void LoanableHelloWorld::message( - const std::array& _message) -{ - m_message = _message; -} - -/*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ -void LoanableHelloWorld::message( - std::array&& _message) -{ - m_message = std::move(_message); -} - -/*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ -const std::array& LoanableHelloWorld::message() const -{ - return m_message; -} - -/*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ -std::array& LoanableHelloWorld::message() -{ - return m_message; -} - - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/WriterLoansExample/LoanableHelloWorldv1.h b/examples/cpp/dds/WriterLoansExample/LoanableHelloWorldv1.h deleted file mode 100644 index 1c13fed5575..00000000000 --- a/examples/cpp/dds/WriterLoansExample/LoanableHelloWorldv1.h +++ /dev/null @@ -1,244 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file LoanableHelloWorld.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#include - -#if FASTCDR_VERSION_MAJOR == 1 - -#ifndef _FAST_DDS_GENERATED_LOANABLEHELLOWORLD_H_ -#define _FAST_DDS_GENERATED_LOANABLEHELLOWORLD_H_ - - -#include - -#include -#include -#include -#include -#include -#include -#include - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define eProsima_user_DllExport -#endif // _WIN32 - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(LOANABLEHELLOWORLD_SOURCE) -#define LOANABLEHELLOWORLD_DllAPI __declspec( dllexport ) -#else -#define LOANABLEHELLOWORLD_DllAPI __declspec( dllimport ) -#endif // LOANABLEHELLOWORLD_SOURCE -#else -#define LOANABLEHELLOWORLD_DllAPI -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define LOANABLEHELLOWORLD_DllAPI -#endif // _WIN32 - -namespace eprosima { -namespace fastcdr { -class Cdr; -} // namespace fastcdr -} // namespace eprosima - - - - - -/*! - * @brief This class represents the structure LoanableHelloWorld defined by the user in the IDL file. - * @ingroup LoanableHelloWorld - */ -class LoanableHelloWorld -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport LoanableHelloWorld(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~LoanableHelloWorld(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object LoanableHelloWorld that will be copied. - */ - eProsima_user_DllExport LoanableHelloWorld( - const LoanableHelloWorld& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object LoanableHelloWorld that will be copied. - */ - eProsima_user_DllExport LoanableHelloWorld( - LoanableHelloWorld&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object LoanableHelloWorld that will be copied. - */ - eProsima_user_DllExport LoanableHelloWorld& operator =( - const LoanableHelloWorld& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object LoanableHelloWorld that will be copied. - */ - eProsima_user_DllExport LoanableHelloWorld& operator =( - LoanableHelloWorld&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x LoanableHelloWorld object to compare. - */ - eProsima_user_DllExport bool operator ==( - const LoanableHelloWorld& x) const; - - /*! - * @brief Comparison operator. - * @param x LoanableHelloWorld object to compare. - */ - eProsima_user_DllExport bool operator !=( - const LoanableHelloWorld& x) const; - - /*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ - eProsima_user_DllExport void index( - uint32_t _index); - - /*! - * @brief This function returns the value of member index - * @return Value of member index - */ - eProsima_user_DllExport uint32_t index() const; - - /*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ - eProsima_user_DllExport uint32_t& index(); - - - /*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ - eProsima_user_DllExport void message( - const std::array& _message); - - /*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ - eProsima_user_DllExport void message( - std::array&& _message); - - /*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ - eProsima_user_DllExport const std::array& message() const; - - /*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ - eProsima_user_DllExport std::array& message(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const LoanableHelloWorld& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - uint32_t m_index; - std::array m_message; - -}; - - -#endif // _FAST_DDS_GENERATED_LOANABLEHELLOWORLD_H_ - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/ZeroCopyExample/CMakeLists.txt b/examples/cpp/dds/ZeroCopyExample/CMakeLists.txt index 817e2028164..468ffbade99 100644 --- a/examples/cpp/dds/ZeroCopyExample/CMakeLists.txt +++ b/examples/cpp/dds/ZeroCopyExample/CMakeLists.txt @@ -21,8 +21,8 @@ if(NOT fastcdr_FOUND) find_package(fastcdr 2 REQUIRED) endif() -if(NOT fastrtps_FOUND) - find_package(fastrtps 2.12 REQUIRED) +if(NOT fastdds_FOUND) + find_package(fastdds 3 REQUIRED) endif() #Check C++11 @@ -43,6 +43,6 @@ target_compile_definitions(DDSZeroCopyExample PRIVATE $<$>,$>:__DEBUG> $<$:__INTERNALDEBUG> # Internal debug activated. ) -target_link_libraries(DDSZeroCopyExample fastrtps fastcdr) +target_link_libraries(DDSZeroCopyExample fastdds fastcdr) install(TARGETS DDSZeroCopyExample RUNTIME DESTINATION examples/cpp/dds/ZeroCopyExample/${BIN_INSTALL_DIR}) diff --git a/examples/cpp/dds/ZeroCopyExample/LoanableHelloWorld.cxx b/examples/cpp/dds/ZeroCopyExample/LoanableHelloWorld.cxx deleted file mode 100644 index 54ca2b05ab0..00000000000 --- a/examples/cpp/dds/ZeroCopyExample/LoanableHelloWorld.cxx +++ /dev/null @@ -1,168 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file LoanableHelloWorld.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "LoanableHelloWorld.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - - - - -LoanableHelloWorld::LoanableHelloWorld() -{ -} - -LoanableHelloWorld::~LoanableHelloWorld() -{ -} - -LoanableHelloWorld::LoanableHelloWorld( - const LoanableHelloWorld& x) -{ - m_index = x.m_index; - m_message = x.m_message; -} - -LoanableHelloWorld::LoanableHelloWorld( - LoanableHelloWorld&& x) noexcept -{ - m_index = x.m_index; - m_message = std::move(x.m_message); -} - -LoanableHelloWorld& LoanableHelloWorld::operator =( - const LoanableHelloWorld& x) -{ - - m_index = x.m_index; - m_message = x.m_message; - return *this; -} - -LoanableHelloWorld& LoanableHelloWorld::operator =( - LoanableHelloWorld&& x) noexcept -{ - - m_index = x.m_index; - m_message = std::move(x.m_message); - return *this; -} - -bool LoanableHelloWorld::operator ==( - const LoanableHelloWorld& x) const -{ - return (m_index == x.m_index && - m_message == x.m_message); -} - -bool LoanableHelloWorld::operator !=( - const LoanableHelloWorld& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void LoanableHelloWorld::index( - uint32_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint32_t LoanableHelloWorld::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint32_t& LoanableHelloWorld::index() -{ - return m_index; -} - - -/*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ -void LoanableHelloWorld::message( - const std::array& _message) -{ - m_message = _message; -} - -/*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ -void LoanableHelloWorld::message( - std::array&& _message) -{ - m_message = std::move(_message); -} - -/*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ -const std::array& LoanableHelloWorld::message() const -{ - return m_message; -} - -/*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ -std::array& LoanableHelloWorld::message() -{ - return m_message; -} - - -// Include auxiliary functions like for serializing/deserializing. -#include "LoanableHelloWorldCdrAux.ipp" - -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/ZeroCopyExample/LoanableHelloWorld.h b/examples/cpp/dds/ZeroCopyExample/LoanableHelloWorld.hpp similarity index 69% rename from examples/cpp/dds/ZeroCopyExample/LoanableHelloWorld.h rename to examples/cpp/dds/ZeroCopyExample/LoanableHelloWorld.hpp index 80d8feaca9b..1567811078c 100644 --- a/examples/cpp/dds/ZeroCopyExample/LoanableHelloWorld.h +++ b/examples/cpp/dds/ZeroCopyExample/LoanableHelloWorld.hpp @@ -13,32 +13,18 @@ // limitations under the License. /*! - * @file LoanableHelloWorld.h + * @file LoanableHelloWorld.hpp * This header file contains the declaration of the described types in the IDL file. * * This file was generated by the tool fastddsgen. */ -#include -#include "LoanableHelloWorldv1.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#ifndef _FAST_DDS_GENERATED_LOANABLEHELLOWORLD_H_ -#define _FAST_DDS_GENERATED_LOANABLEHELLOWORLD_H_ +#ifndef _FAST_DDS_GENERATED_LOANABLEHELLOWORLD_HPP_ +#define _FAST_DDS_GENERATED_LOANABLEHELLOWORLD_HPP_ #include -#include #include -#include -#include -#include - -#include -#include -#include - - +#include #if defined(_WIN32) #if defined(EPROSIMA_USER_DLL_EXPORT) @@ -64,17 +50,6 @@ #define LOANABLEHELLOWORLD_DllAPI #endif // _WIN32 -namespace eprosima { -namespace fastcdr { -class Cdr; -class CdrSizeCalculator; -} // namespace fastcdr -} // namespace eprosima - - - - - /*! * @brief This class represents the structure LoanableHelloWorld defined by the user in the IDL file. * @ingroup LoanableHelloWorld @@ -86,73 +61,117 @@ class LoanableHelloWorld /*! * @brief Default constructor. */ - eProsima_user_DllExport LoanableHelloWorld(); + eProsima_user_DllExport LoanableHelloWorld() + { + } /*! * @brief Default destructor. */ - eProsima_user_DllExport ~LoanableHelloWorld(); + eProsima_user_DllExport ~LoanableHelloWorld() + { + } /*! * @brief Copy constructor. * @param x Reference to the object LoanableHelloWorld that will be copied. */ eProsima_user_DllExport LoanableHelloWorld( - const LoanableHelloWorld& x); + const LoanableHelloWorld& x) + { + m_index = x.m_index; + + m_message = x.m_message; + + } /*! * @brief Move constructor. * @param x Reference to the object LoanableHelloWorld that will be copied. */ eProsima_user_DllExport LoanableHelloWorld( - LoanableHelloWorld&& x) noexcept; + LoanableHelloWorld&& x) noexcept + { + m_index = x.m_index; + m_message = std::move(x.m_message); + } /*! * @brief Copy assignment. * @param x Reference to the object LoanableHelloWorld that will be copied. */ eProsima_user_DllExport LoanableHelloWorld& operator =( - const LoanableHelloWorld& x); + const LoanableHelloWorld& x) + { + + m_index = x.m_index; + + m_message = x.m_message; + + return *this; + } /*! * @brief Move assignment. * @param x Reference to the object LoanableHelloWorld that will be copied. */ eProsima_user_DllExport LoanableHelloWorld& operator =( - LoanableHelloWorld&& x) noexcept; + LoanableHelloWorld&& x) noexcept + { + + m_index = x.m_index; + m_message = std::move(x.m_message); + return *this; + } /*! * @brief Comparison operator. * @param x LoanableHelloWorld object to compare. */ eProsima_user_DllExport bool operator ==( - const LoanableHelloWorld& x) const; + const LoanableHelloWorld& x) const + { + return (m_index == x.m_index && + m_message == x.m_message); + } /*! * @brief Comparison operator. * @param x LoanableHelloWorld object to compare. */ eProsima_user_DllExport bool operator !=( - const LoanableHelloWorld& x) const; + const LoanableHelloWorld& x) const + { + return !(*this == x); + } /*! * @brief This function sets a value in member index * @param _index New value for member index */ eProsima_user_DllExport void index( - uint32_t _index); + uint32_t _index) + { + m_index = _index; + } /*! * @brief This function returns the value of member index * @return Value of member index */ - eProsima_user_DllExport uint32_t index() const; + eProsima_user_DllExport uint32_t index() const + { + return m_index; + } /*! * @brief This function returns a reference to member index * @return Reference to member index */ - eProsima_user_DllExport uint32_t& index(); + eProsima_user_DllExport uint32_t& index() + { + return m_index; + } /*! @@ -160,26 +179,40 @@ class LoanableHelloWorld * @param _message New value to be copied in member message */ eProsima_user_DllExport void message( - const std::array& _message); + const std::array& _message) + { + m_message = _message; + } /*! * @brief This function moves the value in member message * @param _message New value to be moved in member message */ eProsima_user_DllExport void message( - std::array&& _message); + std::array&& _message) + { + m_message = std::move(_message); + } /*! * @brief This function returns a constant reference to member message * @return Constant reference to member message */ - eProsima_user_DllExport const std::array& message() const; + eProsima_user_DllExport const std::array& message() const + { + return m_message; + } /*! * @brief This function returns a reference to member message * @return Reference to member message */ - eProsima_user_DllExport std::array& message(); + eProsima_user_DllExport std::array& message() + { + return m_message; + } + + private: @@ -188,8 +221,6 @@ class LoanableHelloWorld }; -#endif // _FAST_DDS_GENERATED_LOANABLEHELLOWORLD_H_ - +#endif // _FAST_DDS_GENERATED_LOANABLEHELLOWORLD_HPP_ -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/examples/cpp/dds/ZeroCopyExample/LoanableHelloWorldCdrAux.hpp b/examples/cpp/dds/ZeroCopyExample/LoanableHelloWorldCdrAux.hpp index c29aaedaaff..8fc200fee77 100644 --- a/examples/cpp/dds/ZeroCopyExample/LoanableHelloWorldCdrAux.hpp +++ b/examples/cpp/dds/ZeroCopyExample/LoanableHelloWorldCdrAux.hpp @@ -22,7 +22,7 @@ #ifndef _FAST_DDS_GENERATED_LOANABLEHELLOWORLDCDRAUX_HPP_ #define _FAST_DDS_GENERATED_LOANABLEHELLOWORLDCDRAUX_HPP_ -#include "LoanableHelloWorld.h" +#include "LoanableHelloWorld.hpp" constexpr uint32_t LoanableHelloWorld_max_cdr_typesize {260UL}; constexpr uint32_t LoanableHelloWorld_max_key_cdr_typesize {0UL}; @@ -34,8 +34,6 @@ namespace fastcdr { class Cdr; class CdrSizeCalculator; - - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const LoanableHelloWorld& data); diff --git a/examples/cpp/dds/ZeroCopyExample/LoanableHelloWorldCdrAux.ipp b/examples/cpp/dds/ZeroCopyExample/LoanableHelloWorldCdrAux.ipp index 640061e832c..2c932b2b441 100644 --- a/examples/cpp/dds/ZeroCopyExample/LoanableHelloWorldCdrAux.ipp +++ b/examples/cpp/dds/ZeroCopyExample/LoanableHelloWorldCdrAux.ipp @@ -34,8 +34,6 @@ using namespace eprosima::fastcdr::exception; namespace eprosima { namespace fastcdr { - - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, diff --git a/examples/cpp/dds/ZeroCopyExample/LoanableHelloWorldPubSubTypes.cxx b/examples/cpp/dds/ZeroCopyExample/LoanableHelloWorldPubSubTypes.cxx index 668ff484ea0..5ce26c2a2ed 100644 --- a/examples/cpp/dds/ZeroCopyExample/LoanableHelloWorldPubSubTypes.cxx +++ b/examples/cpp/dds/ZeroCopyExample/LoanableHelloWorldPubSubTypes.cxx @@ -19,18 +19,18 @@ * This file was generated by the tool fastddsgen. */ +#include "LoanableHelloWorldPubSubTypes.h" +#include #include -#include "LoanableHelloWorldPubSubTypes.h" #include "LoanableHelloWorldCdrAux.hpp" +#include "LoanableHelloWorldTypeObjectSupport.hpp" using SerializedPayload_t = eprosima::fastrtps::rtps::SerializedPayload_t; using InstanceHandle_t = eprosima::fastrtps::rtps::InstanceHandle_t; using DataRepresentationId_t = eprosima::fastdds::dds::DataRepresentationId_t; - - LoanableHelloWorldPubSubType::LoanableHelloWorldPubSubType() { setName("LoanableHelloWorld"); @@ -219,3 +219,11 @@ bool LoanableHelloWorldPubSubType::getKey( return true; } +void LoanableHelloWorldPubSubType::register_type_object_representation() const +{ + register_LoanableHelloWorld_type_objects(); +} + + +// Include auxiliary functions like for serializing/deserializing. +#include "LoanableHelloWorldCdrAux.ipp" diff --git a/examples/cpp/dds/ZeroCopyExample/LoanableHelloWorldPubSubTypes.h b/examples/cpp/dds/ZeroCopyExample/LoanableHelloWorldPubSubTypes.h index 06ba8663ef8..33525ee7726 100644 --- a/examples/cpp/dds/ZeroCopyExample/LoanableHelloWorldPubSubTypes.h +++ b/examples/cpp/dds/ZeroCopyExample/LoanableHelloWorldPubSubTypes.h @@ -27,9 +27,9 @@ #include #include #include -#include +#include -#include "LoanableHelloWorld.h" +#include "LoanableHelloWorld.hpp" #if !defined(GEN_API_VER) || (GEN_API_VER != 2) @@ -38,8 +38,6 @@ #endif // GEN_API_VER - - #ifndef SWIG namespace detail { @@ -123,6 +121,9 @@ class LoanableHelloWorldPubSubType : public eprosima::fastdds::dds::TopicDataTyp eProsima_user_DllExport void deleteData( void* data) override; + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + #ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED eProsima_user_DllExport inline bool is_bounded() const override { diff --git a/examples/cpp/dds/ZeroCopyExample/LoanableHelloWorldPublisher.cxx b/examples/cpp/dds/ZeroCopyExample/LoanableHelloWorldPublisher.cxx index 0854b6ebd47..e19c18d90ec 100644 --- a/examples/cpp/dds/ZeroCopyExample/LoanableHelloWorldPublisher.cxx +++ b/examples/cpp/dds/ZeroCopyExample/LoanableHelloWorldPublisher.cxx @@ -144,7 +144,7 @@ void LoanableHelloWorldPublisher::run() if (ch == 'y') { void* sample = nullptr; - if (ReturnCode_t::RETCODE_OK == writer_->loan_sample(sample)) + if (RETCODE_OK == writer_->loan_sample(sample)) { std::cout << "Preparing sample at address " << sample << std::endl; LoanableHelloWorld* data = static_cast(sample); diff --git a/examples/cpp/dds/ZeroCopyExample/LoanableHelloWorldSubscriber.cxx b/examples/cpp/dds/ZeroCopyExample/LoanableHelloWorldSubscriber.cxx index 67d9b286824..15fa0200bfd 100644 --- a/examples/cpp/dds/ZeroCopyExample/LoanableHelloWorldSubscriber.cxx +++ b/examples/cpp/dds/ZeroCopyExample/LoanableHelloWorldSubscriber.cxx @@ -130,7 +130,7 @@ void LoanableHelloWorldSubscriber::SubListener::on_data_available( DataSeq data; SampleInfoSeq infos; - while (ReturnCode_t::RETCODE_OK == reader->take(data, infos)) + while (RETCODE_OK == reader->take(data, infos)) { for (LoanableCollection::size_type i = 0; i < infos.length(); ++i) { diff --git a/examples/cpp/dds/ZeroCopyExample/LoanableHelloWorldTypeObjectSupport.cxx b/examples/cpp/dds/ZeroCopyExample/LoanableHelloWorldTypeObjectSupport.cxx new file mode 100644 index 00000000000..212eb4a6d62 --- /dev/null +++ b/examples/cpp/dds/ZeroCopyExample/LoanableHelloWorldTypeObjectSupport.cxx @@ -0,0 +1,313 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file LoanableHelloWorldTypeObjectSupport.cxx + * Source file containing the implementation to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#include "LoanableHelloWorldTypeObjectSupport.hpp" + +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include + +#include "LoanableHelloWorld.hpp" + + +using namespace eprosima::fastdds::dds::xtypes; + +void register_LoanableHelloWorld_type_objects() +{ + static std::once_flag once_flag; + std::call_once(once_flag, []() + { + register_LoanableHelloWorld_type_identifier(); + + }); +} + +void register_LoanableHelloWorld_type_identifier() +{ + { + StructTypeFlag struct_flags_LoanableHelloWorld = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::FINAL, + false, false); + ReturnCode_t return_code_LoanableHelloWorld; + TypeIdentifierPair type_ids_LoanableHelloWorld; + QualifiedTypeName type_name_LoanableHelloWorld = "LoanableHelloWorld"; + eprosima::fastcdr::optional type_ann_builtin_LoanableHelloWorld; + eprosima::fastcdr::optional ann_custom_LoanableHelloWorld; + AppliedAnnotationSeq tmp_ann_custom_LoanableHelloWorld; + eprosima::fastcdr::optional verbatim_LoanableHelloWorld; + if (!tmp_ann_custom_LoanableHelloWorld.empty()) + { + ann_custom_LoanableHelloWorld = tmp_ann_custom_LoanableHelloWorld; + } + + CompleteTypeDetail detail_LoanableHelloWorld = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_LoanableHelloWorld, ann_custom_LoanableHelloWorld, type_name_LoanableHelloWorld.to_string()); + CompleteStructHeader header_LoanableHelloWorld; + header_LoanableHelloWorld = TypeObjectUtils::build_complete_struct_header(TypeIdentifier(), detail_LoanableHelloWorld); + CompleteStructMemberSeq member_seq_LoanableHelloWorld; + { + return_code_LoanableHelloWorld = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_uint32_t", type_ids_LoanableHelloWorld); + + if (return_code_LoanableHelloWorld != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "index Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_index = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_index; + MemberId member_id_index = 0x00000000; + if (EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1()._d() || TK_NONE == type_ids_LoanableHelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_LoanableHelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_LoanableHelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_LoanableHelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_LoanableHelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_LoanableHelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_LoanableHelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_LoanableHelloWorld.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_LoanableHelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_LoanableHelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_LoanableHelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_LoanableHelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_LoanableHelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_LoanableHelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_LoanableHelloWorld.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure index member TypeIdentifier inconsistent."); + return; + } + MemberName name_index = "index"; + eprosima::fastcdr::optional member_ann_builtin_index; + ann_custom_LoanableHelloWorld.reset(); + CompleteMemberDetail detail_index = TypeObjectUtils::build_complete_member_detail(name_index, member_ann_builtin_index, ann_custom_LoanableHelloWorld); + CompleteStructMember member_index = TypeObjectUtils::build_complete_struct_member(common_index, detail_index); + TypeObjectUtils::add_complete_struct_member(member_seq_LoanableHelloWorld, member_index); + } + { + return_code_LoanableHelloWorld = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_array_char_256", type_ids_LoanableHelloWorld); + + if (return_code_LoanableHelloWorld != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_LoanableHelloWorld = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_char", type_ids_LoanableHelloWorld); + + if (return_code_LoanableHelloWorld != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Array element TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + TypeIdentifier* element_identifier_anonymous_array_char_256 {nullptr}; + if (EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1()._d() || TK_NONE == type_ids_LoanableHelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_LoanableHelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_LoanableHelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_LoanableHelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_LoanableHelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_LoanableHelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_LoanableHelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_array_char_256 = new TypeIdentifier(type_ids_LoanableHelloWorld.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_LoanableHelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_LoanableHelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_LoanableHelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_LoanableHelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_LoanableHelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_LoanableHelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_array_char_256 = new TypeIdentifier(type_ids_LoanableHelloWorld.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Array element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_array_char_256 = EK_COMPLETE; + if (TK_NONE == type_ids_LoanableHelloWorld.type_identifier2()._d()) + { + equiv_kind_anonymous_array_char_256 = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_array_char_256 = 0; + PlainCollectionHeader header_anonymous_array_char_256 = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_array_char_256, element_flags_anonymous_array_char_256); + std::string type_id_kind_anonymous_array_char_256("TI_PLAIN_ARRAY_LARGE"); + if (type_id_kind_anonymous_array_char_256 == "TI_PLAIN_ARRAY_SMALL") + { + SBoundSeq array_bound_seq; + TypeObjectUtils::add_array_dimension(array_bound_seq, static_cast(256)); + + PlainArraySElemDefn array_sdefn = TypeObjectUtils::build_plain_array_s_elem_defn(header_anonymous_array_char_256, array_bound_seq, + eprosima::fastcdr::external(element_identifier_anonymous_array_char_256)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_array_type_identifier(array_sdefn, "anonymous_array_char_256")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_char_256 already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBoundSeq array_bound_seq; + TypeObjectUtils::add_array_dimension(array_bound_seq, static_cast(256)); + + PlainArrayLElemDefn array_ldefn = TypeObjectUtils::build_plain_array_l_elem_defn(header_anonymous_array_char_256, array_bound_seq, + eprosima::fastcdr::external(element_identifier_anonymous_array_char_256)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_array_type_identifier(array_ldefn, "anonymous_array_char_256")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_char_256 already registered in TypeObjectRegistry for a different type."); + } + } + return_code_LoanableHelloWorld = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_array_char_256", type_ids_LoanableHelloWorld); + if (return_code_LoanableHelloWorld != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_char_256: Given Array TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_message = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_message; + MemberId member_id_message = 0x00000001; + if (EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1()._d() || TK_NONE == type_ids_LoanableHelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_LoanableHelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_LoanableHelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_LoanableHelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_LoanableHelloWorld.type_identifier1()._d() && + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_LoanableHelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_LoanableHelloWorld.type_identifier1()._d() && + (EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_message = TypeObjectUtils::build_common_struct_member(member_id_message, member_flags_message, type_ids_LoanableHelloWorld.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_LoanableHelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_LoanableHelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_LoanableHelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_LoanableHelloWorld.type_identifier2()._d() && + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_LoanableHelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_LoanableHelloWorld.type_identifier2()._d() && + (EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_LoanableHelloWorld.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_message = TypeObjectUtils::build_common_struct_member(member_id_message, member_flags_message, type_ids_LoanableHelloWorld.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure message member TypeIdentifier inconsistent."); + return; + } + MemberName name_message = "message"; + eprosima::fastcdr::optional member_ann_builtin_message; + ann_custom_LoanableHelloWorld.reset(); + CompleteMemberDetail detail_message = TypeObjectUtils::build_complete_member_detail(name_message, member_ann_builtin_message, ann_custom_LoanableHelloWorld); + CompleteStructMember member_message = TypeObjectUtils::build_complete_struct_member(common_message, detail_message); + TypeObjectUtils::add_complete_struct_member(member_seq_LoanableHelloWorld, member_message); + } + CompleteStructType struct_type_LoanableHelloWorld = TypeObjectUtils::build_complete_struct_type(struct_flags_LoanableHelloWorld, header_LoanableHelloWorld, member_seq_LoanableHelloWorld); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_struct_type_object(struct_type_LoanableHelloWorld, type_name_LoanableHelloWorld.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "LoanableHelloWorld already registered in TypeObjectRegistry for a different type."); + } + return_code_LoanableHelloWorld = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "LoanableHelloWorld", type_ids_LoanableHelloWorld); + if (return_code_LoanableHelloWorld != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "LoanableHelloWorld: Given Struct TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } +} + diff --git a/examples/cpp/dds/ZeroCopyExample/LoanableHelloWorldTypeObjectSupport.hpp b/examples/cpp/dds/ZeroCopyExample/LoanableHelloWorldTypeObjectSupport.hpp new file mode 100644 index 00000000000..101fafc55f4 --- /dev/null +++ b/examples/cpp/dds/ZeroCopyExample/LoanableHelloWorldTypeObjectSupport.hpp @@ -0,0 +1,54 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file LoanableHelloWorldTypeObjectSupport.hpp + * Header file containing the API required to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#ifndef _FAST_DDS_GENERATED_LOANABLEHELLOWORLD_TYPE_OBJECT_SUPPORT_HPP_ +#define _FAST_DDS_GENERATED_LOANABLEHELLOWORLD_TYPE_OBJECT_SUPPORT_HPP_ + + +#if defined(_WIN32) +#if defined(EPROSIMA_USER_DLL_EXPORT) +#define eProsima_user_DllExport __declspec( dllexport ) +#else +#define eProsima_user_DllExport +#endif // EPROSIMA_USER_DLL_EXPORT +#else +#define eProsima_user_DllExport +#endif // _WIN32 + +/** + * @brief Register every TypeObject representation defined in the IDL file in Fast DDS TypeObjectRegistry. + */ +eProsima_user_DllExport void register_LoanableHelloWorld_type_objects(); + +#ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +/** + * @brief Register LoanableHelloWorld related TypeIdentifier. + * Fully-descriptive TypeIdentifiers are directly registered. + * Hash TypeIdentifiers require to fill the TypeObject information and hash it, consequently, the TypeObject is + * indirectly registered as well. + */ +void register_LoanableHelloWorld_type_identifier(); + + +#endif // DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +#endif // _FAST_DDS_GENERATED_LOANABLEHELLOWORLD_TYPE_OBJECT_SUPPORT_HPP_ diff --git a/examples/cpp/dds/ZeroCopyExample/LoanableHelloWorldv1.cxx b/examples/cpp/dds/ZeroCopyExample/LoanableHelloWorldv1.cxx deleted file mode 100644 index 63da3dfddbc..00000000000 --- a/examples/cpp/dds/ZeroCopyExample/LoanableHelloWorldv1.cxx +++ /dev/null @@ -1,288 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file LoanableHelloWorld.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "LoanableHelloWorld.h" - -#if FASTCDR_VERSION_MAJOR == 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - -namespace helper { namespace internal { - -enum class Size { - UInt8, - UInt16, - UInt32, - UInt64, -}; - -constexpr Size get_size(int s) { - return (s <= 8 ) ? Size::UInt8: - (s <= 16) ? Size::UInt16: - (s <= 32) ? Size::UInt32: Size::UInt64; -} - -template -struct FindTypeH; - -template<> -struct FindTypeH { - using type = std::uint8_t; -}; - -template<> -struct FindTypeH { - using type = std::uint16_t; -}; - -template<> -struct FindTypeH { - using type = std::uint32_t; -}; - -template<> -struct FindTypeH { - using type = std::uint64_t; -}; -} - -template -struct FindType { - using type = typename internal::FindTypeH::type; -}; -} - -#define LoanableHelloWorld_max_cdr_typesize 260ULL; - - - - -LoanableHelloWorld::LoanableHelloWorld() -{ - // unsigned long m_index - m_index = 0; - // char m_message - memset(&m_message, 0, ((256)) * 1); - -} - -LoanableHelloWorld::~LoanableHelloWorld() -{ -} - -LoanableHelloWorld::LoanableHelloWorld( - const LoanableHelloWorld& x) -{ - m_index = x.m_index; - - - m_message = x.m_message; - -} - -LoanableHelloWorld::LoanableHelloWorld( - LoanableHelloWorld&& x) noexcept -{ - m_index = x.m_index; - - - m_message = std::move(x.m_message); - -} - -LoanableHelloWorld& LoanableHelloWorld::operator =( - const LoanableHelloWorld& x) -{ - m_index = x.m_index; - - - m_message = x.m_message; - - return *this; -} - -LoanableHelloWorld& LoanableHelloWorld::operator =( - LoanableHelloWorld&& x) noexcept -{ - m_index = x.m_index; - - - m_message = std::move(x.m_message); - - return *this; -} - -bool LoanableHelloWorld::operator ==( - const LoanableHelloWorld& x) const -{ - return (m_index == x.m_index && - m_message == x.m_message); -} - -bool LoanableHelloWorld::operator !=( - const LoanableHelloWorld& x) const -{ - return !(*this == x); -} - -size_t LoanableHelloWorld::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return LoanableHelloWorld_max_cdr_typesize; -} - -size_t LoanableHelloWorld::getCdrSerializedSize( - const LoanableHelloWorld& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += (((256)) * 1) + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - - return current_alignment - initial_alignment; -} - - -void LoanableHelloWorld::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_index; - - scdr << m_message; - - -} - -void LoanableHelloWorld::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_index; - - - - dcdr >> m_message; - - -} - - -bool LoanableHelloWorld::isKeyDefined() -{ - return false; -} - -void LoanableHelloWorld::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void LoanableHelloWorld::index( - uint32_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint32_t LoanableHelloWorld::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint32_t& LoanableHelloWorld::index() -{ - return m_index; -} - - -/*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ -void LoanableHelloWorld::message( - const std::array& _message) -{ - m_message = _message; -} - -/*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ -void LoanableHelloWorld::message( - std::array&& _message) -{ - m_message = std::move(_message); -} - -/*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ -const std::array& LoanableHelloWorld::message() const -{ - return m_message; -} - -/*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ -std::array& LoanableHelloWorld::message() -{ - return m_message; -} - - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/dds/ZeroCopyExample/LoanableHelloWorldv1.h b/examples/cpp/dds/ZeroCopyExample/LoanableHelloWorldv1.h deleted file mode 100644 index 1c13fed5575..00000000000 --- a/examples/cpp/dds/ZeroCopyExample/LoanableHelloWorldv1.h +++ /dev/null @@ -1,244 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file LoanableHelloWorld.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#include - -#if FASTCDR_VERSION_MAJOR == 1 - -#ifndef _FAST_DDS_GENERATED_LOANABLEHELLOWORLD_H_ -#define _FAST_DDS_GENERATED_LOANABLEHELLOWORLD_H_ - - -#include - -#include -#include -#include -#include -#include -#include -#include - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define eProsima_user_DllExport -#endif // _WIN32 - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(LOANABLEHELLOWORLD_SOURCE) -#define LOANABLEHELLOWORLD_DllAPI __declspec( dllexport ) -#else -#define LOANABLEHELLOWORLD_DllAPI __declspec( dllimport ) -#endif // LOANABLEHELLOWORLD_SOURCE -#else -#define LOANABLEHELLOWORLD_DllAPI -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define LOANABLEHELLOWORLD_DllAPI -#endif // _WIN32 - -namespace eprosima { -namespace fastcdr { -class Cdr; -} // namespace fastcdr -} // namespace eprosima - - - - - -/*! - * @brief This class represents the structure LoanableHelloWorld defined by the user in the IDL file. - * @ingroup LoanableHelloWorld - */ -class LoanableHelloWorld -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport LoanableHelloWorld(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~LoanableHelloWorld(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object LoanableHelloWorld that will be copied. - */ - eProsima_user_DllExport LoanableHelloWorld( - const LoanableHelloWorld& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object LoanableHelloWorld that will be copied. - */ - eProsima_user_DllExport LoanableHelloWorld( - LoanableHelloWorld&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object LoanableHelloWorld that will be copied. - */ - eProsima_user_DllExport LoanableHelloWorld& operator =( - const LoanableHelloWorld& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object LoanableHelloWorld that will be copied. - */ - eProsima_user_DllExport LoanableHelloWorld& operator =( - LoanableHelloWorld&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x LoanableHelloWorld object to compare. - */ - eProsima_user_DllExport bool operator ==( - const LoanableHelloWorld& x) const; - - /*! - * @brief Comparison operator. - * @param x LoanableHelloWorld object to compare. - */ - eProsima_user_DllExport bool operator !=( - const LoanableHelloWorld& x) const; - - /*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ - eProsima_user_DllExport void index( - uint32_t _index); - - /*! - * @brief This function returns the value of member index - * @return Value of member index - */ - eProsima_user_DllExport uint32_t index() const; - - /*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ - eProsima_user_DllExport uint32_t& index(); - - - /*! - * @brief This function copies the value in member message - * @param _message New value to be copied in member message - */ - eProsima_user_DllExport void message( - const std::array& _message); - - /*! - * @brief This function moves the value in member message - * @param _message New value to be moved in member message - */ - eProsima_user_DllExport void message( - std::array&& _message); - - /*! - * @brief This function returns a constant reference to member message - * @return Constant reference to member message - */ - eProsima_user_DllExport const std::array& message() const; - - /*! - * @brief This function returns a reference to member message - * @return Reference to member message - */ - eProsima_user_DllExport std::array& message(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const LoanableHelloWorld& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - uint32_t m_index; - std::array m_message; - -}; - - -#endif // _FAST_DDS_GENERATED_LOANABLEHELLOWORLD_H_ - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/examples/cpp/rtps/AsSocket/CMakeLists.txt b/examples/cpp/rtps/AsSocket/CMakeLists.txt index 27e868d53f0..5fcdcb79a42 100644 --- a/examples/cpp/rtps/AsSocket/CMakeLists.txt +++ b/examples/cpp/rtps/AsSocket/CMakeLists.txt @@ -25,8 +25,8 @@ if(NOT foonathan_memory_FOUND) find_package(foonathan_memory REQUIRED) endif() -if(NOT fastrtps_FOUND) - find_package(fastrtps 2.12 REQUIRED) +if(NOT fastdds_FOUND) + find_package(fastdds 3 REQUIRED) endif() #Check C++11 @@ -46,7 +46,7 @@ target_compile_definitions(AsSocket PRIVATE $<$>,$>:__DEBUG> $<$:__INTERNALDEBUG> # Internal debug activated. ) -target_link_libraries(AsSocket fastrtps fastcdr foonathan_memory) +target_link_libraries(AsSocket fastdds fastcdr foonathan_memory) install(TARGETS AsSocket RUNTIME DESTINATION examples/cpp/rtps/AsSocket/${BIN_INSTALL_DIR} ) diff --git a/examples/cpp/rtps/AsSocket/TestReaderSocket.cpp b/examples/cpp/rtps/AsSocket/TestReaderSocket.cpp index d2741a7e9be..32f08e6f877 100644 --- a/examples/cpp/rtps/AsSocket/TestReaderSocket.cpp +++ b/examples/cpp/rtps/AsSocket/TestReaderSocket.cpp @@ -19,16 +19,14 @@ #include "TestReaderSocket.h" -#include "fastrtps/rtps/reader/RTPSReader.h" -#include "fastrtps/rtps/participant/RTPSParticipant.h" -#include "fastrtps/rtps/RTPSDomain.h" - -#include "fastrtps/rtps/attributes/RTPSParticipantAttributes.h" -#include "fastrtps/rtps/attributes/ReaderAttributes.h" -#include "fastrtps/rtps/attributes/HistoryAttributes.h" - -#include "fastrtps/rtps/history/ReaderHistory.h" -#include "fastrtps/utils/IPLocator.h" +#include +#include +#include +#include +#include +#include +#include +#include using namespace eprosima::fastrtps; using namespace eprosima::fastrtps::rtps; diff --git a/examples/cpp/rtps/AsSocket/TestReaderSocket.h b/examples/cpp/rtps/AsSocket/TestReaderSocket.h index c7f815b48d5..6f562eb6c0f 100644 --- a/examples/cpp/rtps/AsSocket/TestReaderSocket.h +++ b/examples/cpp/rtps/AsSocket/TestReaderSocket.h @@ -20,10 +20,8 @@ #ifndef TESTREADERSOCKET_H_ #define TESTREADERSOCKET_H_ -#include "fastrtps/rtps/rtps_fwd.h" - - -#include "fastrtps/rtps/reader/ReaderListener.h" +#include +#include class TestReaderSocket { diff --git a/examples/cpp/rtps/AsSocket/TestWriterSocket.cpp b/examples/cpp/rtps/AsSocket/TestWriterSocket.cpp index 9579c7baecb..4b8b4f8a1ad 100644 --- a/examples/cpp/rtps/AsSocket/TestWriterSocket.cpp +++ b/examples/cpp/rtps/AsSocket/TestWriterSocket.cpp @@ -19,18 +19,15 @@ #include "TestWriterSocket.h" -#include "fastrtps/rtps/writer/RTPSWriter.h" -#include "fastrtps/rtps/participant/RTPSParticipant.h" -#include "fastrtps/rtps/RTPSDomain.h" - -#include "fastrtps/rtps/attributes/RTPSParticipantAttributes.h" -#include "fastrtps/rtps/attributes/WriterAttributes.h" -#include "fastrtps/rtps/attributes/HistoryAttributes.h" - -#include "fastrtps/rtps/builtin/data/ReaderProxyData.h" - -#include "fastrtps/rtps/history/WriterHistory.h" -#include "fastrtps/utils/IPLocator.h" +#include +#include +#include +#include +#include +#include +#include +#include +#include using namespace eprosima::fastrtps; using namespace eprosima::fastrtps::rtps; diff --git a/examples/cpp/rtps/AsSocket/TestWriterSocket.h b/examples/cpp/rtps/AsSocket/TestWriterSocket.h index 08202aacfe6..e3b1da2eaa5 100644 --- a/examples/cpp/rtps/AsSocket/TestWriterSocket.h +++ b/examples/cpp/rtps/AsSocket/TestWriterSocket.h @@ -20,12 +20,11 @@ #ifndef TESTWRITERSOCKET_H_ #define TESTWRITERSOCKET_H_ -#include "fastrtps/rtps/rtps_fwd.h" - - -#include -#include #include +#include +#include + +#include class TestWriterSocket { diff --git a/examples/cpp/rtps/AsSocket/main_RTPSTest.cpp b/examples/cpp/rtps/AsSocket/main_RTPSTest.cpp index 12a4046a076..1b15de7c479 100644 --- a/examples/cpp/rtps/AsSocket/main_RTPSTest.cpp +++ b/examples/cpp/rtps/AsSocket/main_RTPSTest.cpp @@ -12,16 +12,15 @@ // See the License for the specific language governing permissions and // limitations under the License. -#include -#include -#include -#include #include #include +#include +#include +#include #include +#include -#include "fastrtps/log/Log.h" -#include "fastrtps/rtps/RTPSDomain.h" +#include #include "TestWriterSocket.h" #include "TestReaderSocket.h" @@ -31,7 +30,6 @@ using namespace fastrtps; using namespace rtps; using namespace std; - int main( int argc, char** argv) diff --git a/examples/cpp/rtps/Persistent/CMakeLists.txt b/examples/cpp/rtps/Persistent/CMakeLists.txt index 0463dd49a79..4766274f096 100644 --- a/examples/cpp/rtps/Persistent/CMakeLists.txt +++ b/examples/cpp/rtps/Persistent/CMakeLists.txt @@ -25,8 +25,8 @@ if(NOT foonathan_memory_FOUND) find_package(foonathan_memory REQUIRED) endif() -if(NOT fastrtps_FOUND) - find_package(fastrtps 2.12 REQUIRED) +if(NOT fastdds_FOUND) + find_package(fastdds 3 REQUIRED) endif() #Check C++11 @@ -46,7 +46,7 @@ target_compile_definitions(Persistent PRIVATE $<$>,$>:__DEBUG> $<$:__INTERNALDEBUG> # Internal debug activated. ) -target_link_libraries(Persistent fastrtps fastcdr foonathan_memory) +target_link_libraries(Persistent fastdds fastcdr foonathan_memory) install(TARGETS Persistent RUNTIME DESTINATION examples/cpp/rtps/Persistent/${BIN_INSTALL_DIR} ) diff --git a/examples/cpp/rtps/Persistent/TestReaderPersistent.cpp b/examples/cpp/rtps/Persistent/TestReaderPersistent.cpp index d5335281463..533ca73bc64 100644 --- a/examples/cpp/rtps/Persistent/TestReaderPersistent.cpp +++ b/examples/cpp/rtps/Persistent/TestReaderPersistent.cpp @@ -19,18 +19,15 @@ #include "TestReaderPersistent.h" -#include -#include -#include - -#include -#include -#include - -#include - -#include -#include +#include +#include +#include +#include +#include +#include +#include +#include +#include using namespace eprosima::fastrtps; using namespace eprosima::fastrtps::rtps; @@ -94,7 +91,7 @@ bool TestReaderPersistent::reg() Tatt.topicKind = NO_KEY; Tatt.topicDataType = "string"; Tatt.topicName = "exampleTopic"; - ReaderQos Rqos; + eprosima::fastdds::dds::ReaderQos Rqos; return mp_participant->registerReader(mp_reader, Tatt, Rqos); } diff --git a/examples/cpp/rtps/Persistent/TestReaderPersistent.h b/examples/cpp/rtps/Persistent/TestReaderPersistent.h index b55f4aa9cdc..ce635e11f33 100644 --- a/examples/cpp/rtps/Persistent/TestReaderPersistent.h +++ b/examples/cpp/rtps/Persistent/TestReaderPersistent.h @@ -20,10 +20,8 @@ #ifndef TESTREADERPERSISTENT_H_ #define TESTREADERPERSISTENT_H_ -#include - - -#include +#include +#include class TestReaderPersistent { diff --git a/examples/cpp/rtps/Persistent/TestWriterPersistent.cpp b/examples/cpp/rtps/Persistent/TestWriterPersistent.cpp index 02be80fb581..0170d72bd9e 100644 --- a/examples/cpp/rtps/Persistent/TestWriterPersistent.cpp +++ b/examples/cpp/rtps/Persistent/TestWriterPersistent.cpp @@ -22,15 +22,15 @@ #include #include -#include -#include -#include -#include -#include -#include -#include -#include -#include +#include +#include +#include +#include +#include +#include +#include +#include +#include using namespace eprosima::fastrtps; using namespace eprosima::fastrtps::rtps; @@ -97,7 +97,7 @@ bool TestWriterPersistent::reg() Tatt.topicKind = NO_KEY; Tatt.topicDataType = "string"; Tatt.topicName = "exampleTopic"; - WriterQos Wqos; + eprosima::fastdds::dds::WriterQos Wqos; return mp_participant->registerWriter(mp_writer, Tatt, Wqos); } diff --git a/examples/cpp/rtps/Persistent/TestWriterPersistent.h b/examples/cpp/rtps/Persistent/TestWriterPersistent.h index 6ea3716369f..24eba95a982 100644 --- a/examples/cpp/rtps/Persistent/TestWriterPersistent.h +++ b/examples/cpp/rtps/Persistent/TestWriterPersistent.h @@ -20,10 +20,8 @@ #ifndef TESTWRITERPERSISTENT_H_ #define TESTWRITERPERSISTENT_H_ -#include - - -#include +#include +#include class TestWriterPersistent { diff --git a/examples/cpp/rtps/Persistent/main_RTPSTest.cpp b/examples/cpp/rtps/Persistent/main_RTPSTest.cpp index c3361bbb7f2..171675f3bef 100644 --- a/examples/cpp/rtps/Persistent/main_RTPSTest.cpp +++ b/examples/cpp/rtps/Persistent/main_RTPSTest.cpp @@ -12,26 +12,24 @@ // See the License for the specific language governing permissions and // limitations under the License. -#include -#include -#include -#include #include #include +#include +#include +#include #include +#include -#include -#include +#include -#include "TestWriterPersistent.h" #include "TestReaderPersistent.h" +#include "TestWriterPersistent.h" using namespace eprosima; using namespace fastrtps; using namespace rtps; using namespace std; - int main( int argc, char** argv) diff --git a/examples/cpp/rtps/Registered/CMakeLists.txt b/examples/cpp/rtps/Registered/CMakeLists.txt index 3cd10781e41..d28ff14cadd 100644 --- a/examples/cpp/rtps/Registered/CMakeLists.txt +++ b/examples/cpp/rtps/Registered/CMakeLists.txt @@ -25,8 +25,8 @@ if(NOT foonathan_memory_FOUND) find_package(foonathan_memory REQUIRED) endif() -if(NOT fastrtps_FOUND) - find_package(fastrtps 2.12 REQUIRED) +if(NOT fastdds_FOUND) + find_package(fastdds 3 REQUIRED) endif() #Check C++11 @@ -46,7 +46,7 @@ target_compile_definitions(Registered PRIVATE $<$>,$>:__DEBUG> $<$:__INTERNALDEBUG> # Internal debug activated. ) -target_link_libraries(Registered fastrtps fastcdr foonathan_memory) +target_link_libraries(Registered fastdds fastcdr foonathan_memory) install(TARGETS Registered RUNTIME DESTINATION examples/cpp/rtps/Registered/${BIN_INSTALL_DIR} ) diff --git a/examples/cpp/rtps/Registered/TestReaderRegistered.cpp b/examples/cpp/rtps/Registered/TestReaderRegistered.cpp index b0feb7c7755..e5cfb2ffd67 100644 --- a/examples/cpp/rtps/Registered/TestReaderRegistered.cpp +++ b/examples/cpp/rtps/Registered/TestReaderRegistered.cpp @@ -19,18 +19,15 @@ #include "TestReaderRegistered.h" -#include "fastrtps/rtps/reader/RTPSReader.h" -#include "fastrtps/rtps/participant/RTPSParticipant.h" -#include "fastrtps/rtps/RTPSDomain.h" - -#include "fastrtps/rtps/attributes/RTPSParticipantAttributes.h" -#include "fastrtps/rtps/attributes/ReaderAttributes.h" -#include "fastrtps/rtps/attributes/HistoryAttributes.h" - -#include "fastrtps/rtps/history/ReaderHistory.h" - -#include "fastrtps/attributes/TopicAttributes.h" -#include "fastrtps/qos/ReaderQos.h" +#include +#include +#include +#include +#include +#include +#include +#include +#include using namespace eprosima::fastrtps; using namespace eprosima::fastrtps::rtps; @@ -86,7 +83,7 @@ bool TestReaderRegistered::reg() Tatt.topicKind = NO_KEY; Tatt.topicDataType = "string"; Tatt.topicName = "exampleTopic"; - ReaderQos Rqos; + eprosima::fastdds::dds::ReaderQos Rqos; return mp_participant->registerReader(mp_reader, Tatt, Rqos); } diff --git a/examples/cpp/rtps/Registered/TestReaderRegistered.h b/examples/cpp/rtps/Registered/TestReaderRegistered.h index 3c1799b7654..860133aefd9 100644 --- a/examples/cpp/rtps/Registered/TestReaderRegistered.h +++ b/examples/cpp/rtps/Registered/TestReaderRegistered.h @@ -20,10 +20,8 @@ #ifndef TESTREADERREGISTERED_H_ #define TESTREADERREGISTERED_H_ -#include "fastrtps/rtps/rtps_fwd.h" - - -#include "fastrtps/rtps/reader/ReaderListener.h" +#include +#include class TestReaderRegistered { diff --git a/examples/cpp/rtps/Registered/TestWriterRegistered.cpp b/examples/cpp/rtps/Registered/TestWriterRegistered.cpp index 04155160eb0..05071191227 100644 --- a/examples/cpp/rtps/Registered/TestWriterRegistered.cpp +++ b/examples/cpp/rtps/Registered/TestWriterRegistered.cpp @@ -22,15 +22,15 @@ #include #include -#include "fastrtps/attributes/TopicAttributes.h" -#include "fastrtps/qos/WriterQos.h" -#include "fastrtps/rtps/attributes/HistoryAttributes.h" -#include "fastrtps/rtps/attributes/RTPSParticipantAttributes.h" -#include "fastrtps/rtps/attributes/WriterAttributes.h" -#include "fastrtps/rtps/history/WriterHistory.h" -#include "fastrtps/rtps/participant/RTPSParticipant.h" -#include "fastrtps/rtps/RTPSDomain.h" -#include "fastrtps/rtps/writer/RTPSWriter.h" +#include +#include +#include +#include +#include +#include +#include +#include +#include using namespace eprosima::fastrtps; using namespace eprosima::fastrtps::rtps; @@ -88,7 +88,7 @@ bool TestWriterRegistered::reg() Tatt.topicKind = NO_KEY; Tatt.topicDataType = "string"; Tatt.topicName = "exampleTopic"; - WriterQos Wqos; + eprosima::fastdds::dds::WriterQos Wqos; return mp_participant->registerWriter(mp_writer, Tatt, Wqos); } diff --git a/examples/cpp/rtps/Registered/TestWriterRegistered.h b/examples/cpp/rtps/Registered/TestWriterRegistered.h index 110d176e4a4..3e7776d080e 100644 --- a/examples/cpp/rtps/Registered/TestWriterRegistered.h +++ b/examples/cpp/rtps/Registered/TestWriterRegistered.h @@ -20,10 +20,8 @@ #ifndef TESTWRITERREGISTERED_H_ #define TESTWRITERREGISTERED_H_ -#include "fastrtps/rtps/rtps_fwd.h" - - -#include "fastrtps/rtps/writer/WriterListener.h" +#include +#include class TestWriterRegistered { diff --git a/examples/cpp/rtps/Registered/main_RTPSTest.cpp b/examples/cpp/rtps/Registered/main_RTPSTest.cpp index d66129c0ee9..cf444a2a450 100644 --- a/examples/cpp/rtps/Registered/main_RTPSTest.cpp +++ b/examples/cpp/rtps/Registered/main_RTPSTest.cpp @@ -12,26 +12,24 @@ // See the License for the specific language governing permissions and // limitations under the License. -#include -#include -#include -#include #include #include +#include +#include +#include #include +#include -#include "fastrtps/log/Log.h" -#include "fastrtps/rtps/RTPSDomain.h" +#include -#include "TestWriterRegistered.h" #include "TestReaderRegistered.h" +#include "TestWriterRegistered.h" using namespace eprosima; using namespace fastrtps; using namespace rtps; using namespace std; - int main( int argc, char** argv) diff --git a/fastrtps.repos b/fastdds.repos similarity index 85% rename from fastrtps.repos rename to fastdds.repos index 69dec7e99cd..0d5f2cd5217 100644 --- a/fastrtps.repos +++ b/fastdds.repos @@ -7,11 +7,11 @@ repositories: type: git url: https://github.com/eProsima/Fast-CDR.git version: master - fastrtps: + fastdds: type: git url: https://github.com/eProsima/Fast-DDS.git - version: master + version: 3.0.x-devel fastddsgen: type: git url: https://github.com/eProsima/Fast-DDS-Gen.git - version: master + version: 4.0.x-devel diff --git a/fuzz/C++/fuzz_XMLProfiles/CMakeLists.txt b/fuzz/C++/fuzz_XMLProfiles/CMakeLists.txt index f40256d20a4..e06af4c0bdf 100644 --- a/fuzz/C++/fuzz_XMLProfiles/CMakeLists.txt +++ b/fuzz/C++/fuzz_XMLProfiles/CMakeLists.txt @@ -25,12 +25,12 @@ if(NOT foonathan_memory_FOUND) find_package(foonathan_memory REQUIRED) endif() -if(NOT fastrtps_FOUND) - find_package(fastrtps 2.12 REQUIRED) +if(NOT fastdds_FOUND) + find_package(fastdds 3 REQUIRED) endif() message(STATUS "Configuring fuzz_XMLProfiles...") file(GLOB SOURCES_CXX "*.cxx") add_executable(fuzz_XMLProfiles ${SOURCES_CXX} ${SOURCES_CPP}) -target_link_libraries(fuzz_XMLProfiles fastrtps fastcdr foonathan_memory $ENV{LIB_FUZZING_ENGINE}) +target_link_libraries(fuzz_XMLProfiles fastdds fastcdr foonathan_memory $ENV{LIB_FUZZING_ENGINE}) diff --git a/fuzz/C++/fuzz_XMLProfiles/fuzz_XMLProfiles.cxx b/fuzz/C++/fuzz_XMLProfiles/fuzz_XMLProfiles.cxx index c5f953147f5..60dfb3fe62c 100644 --- a/fuzz/C++/fuzz_XMLProfiles/fuzz_XMLProfiles.cxx +++ b/fuzz/C++/fuzz_XMLProfiles/fuzz_XMLProfiles.cxx @@ -1,7 +1,7 @@ -#include - #include "fuzz_utils.h" +#include + using namespace eprosima; using namespace eprosima::fastrtps; diff --git a/fuzz/C++/fuzz_XMLProfiles/fuzz_XMLProfiles_seed_corpus/1c82a2c60044985396a5dbbe58ad7fcc5d852d38 b/fuzz/C++/fuzz_XMLProfiles/fuzz_XMLProfiles_seed_corpus/1c82a2c60044985396a5dbbe58ad7fcc5d852d38 index 3ed7cce679a..e807c4c68d8 100644 --- a/fuzz/C++/fuzz_XMLProfiles/fuzz_XMLProfiles_seed_corpus/1c82a2c60044985396a5dbbe58ad7fcc5d852d38 +++ b/fuzz/C++/fuzz_XMLProfiles/fuzz_XMLProfiles_seed_corpus/1c82a2c60044985396a5dbbe58ad7fcc5d852d38 @@ -1,5 +1,5 @@ - + 80 diff --git a/fuzz/C++/fuzz_processCDRMsg/CMakeLists.txt b/fuzz/C++/fuzz_processCDRMsg/CMakeLists.txt index 0cf01c3bbd4..ea93ded57f6 100644 --- a/fuzz/C++/fuzz_processCDRMsg/CMakeLists.txt +++ b/fuzz/C++/fuzz_processCDRMsg/CMakeLists.txt @@ -11,12 +11,13 @@ if(NOT foonathan_memory_FOUND) find_package(foonathan_memory REQUIRED) endif() -if(NOT fastrtps_FOUND) - find_package(fastrtps 2.12 REQUIRED) +if(NOT fastdds_FOUND) + find_package(fastdds 3 REQUIRED) endif() message(STATUS "Configuring fuzz_processCDRMsg...") file(GLOB SOURCES_CXX "fuzz_*.cxx") add_executable(fuzz_processCDRMsg ${SOURCES_CXX}) -target_link_libraries(fuzz_processCDRMsg fastrtps fastcdr foonathan_memory $ENV{LIB_FUZZING_ENGINE}) +target_include_directories(fuzz_processCDRMsg PRIVATE ${CMAKE_SOURCE_DIR}/src/cpp/rtps/messages) +target_link_libraries(fuzz_processCDRMsg fastdds fastcdr foonathan_memory $ENV{LIB_FUZZING_ENGINE}) diff --git a/fuzz/C++/fuzz_processCDRMsg/fuzz_processCDRMsg.cxx b/fuzz/C++/fuzz_processCDRMsg/fuzz_processCDRMsg.cxx index 88c26a5b475..cc1d1faa45c 100644 --- a/fuzz/C++/fuzz_processCDRMsg/fuzz_processCDRMsg.cxx +++ b/fuzz/C++/fuzz_processCDRMsg/fuzz_processCDRMsg.cxx @@ -4,9 +4,10 @@ #include #include -#include #include +#include + #define MIN_SIZE RTPSMESSAGE_HEADER_SIZE #define MAX_SIZE 64000 diff --git a/fuzz/CMakeLists.txt b/fuzz/CMakeLists.txt index d946f714f47..29c48a68c5b 100644 --- a/fuzz/CMakeLists.txt +++ b/fuzz/CMakeLists.txt @@ -12,7 +12,7 @@ # See the License for the specific language governing permissions and # limitations under the License. -set(fastrtps_FOUND TRUE) +set(fastdds_FOUND TRUE) add_subdirectory(C++/fuzz_XMLProfiles) add_subdirectory(C++/fuzz_processCDRMsg) \ No newline at end of file diff --git a/include/dds/core/BuiltinTopicTypes.hpp b/include/dds/core/BuiltinTopicTypes.hpp deleted file mode 100644 index 46bdcb9ef45..00000000000 --- a/include/dds/core/BuiltinTopicTypes.hpp +++ /dev/null @@ -1,220 +0,0 @@ -/* - * Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * All rights reserved. - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_CORE_BUILTIN_TOPIC_TYPES_HPP_ -#define OMG_DDS_CORE_BUILTIN_TOPIC_TYPES_HPP_ - -#include -#include - -#if defined (OMG_DDS_X_TYPES_BUILTIN_TOPIC_TYPES_SUPPORT) -namespace dds { -namespace core { - -/** - * @brief - * Class that is a built-in topic type that can be used to readily create Topics, - * DataReaders and DataWriters for this type without the need for code generation. - * - * This built-in type allows for easy transfer of vectors of bytes. - */ -template -class TBytesTopicType : public Value -{ -public: - - /** - * Creates topic type with an empty byte vector. - */ - TBytesTopicType(); - - /** - * Creates topic type with the given byte vector. - */ - TBytesTopicType( - const std::vector& data); - - /** - * Conversion operator to a vector of bytes. - */ - operator std::vector&() const; - - /** - * Getter function for the internal vector of bytes. - */ - const std::vector& data() const; - - /** - * Setter function for the internal vector of bytes. - */ - void data( - const std::vector& data); -}; - - -/** - * @brief - * Class that is a built-in topic type that can be used to readily create Topics, - * DataReaders and DataWriters for this type without the need for code generation. - * - * This built-in type allows for easy transfer of strings. - */ -template -class TStringTopicType : public Value -{ -public: - - /** - * Creates topic type with an empty data string. - */ - TStringTopicType(); - - /** - * Creates topic type with the given string. - */ - TStringTopicType( - const std::string& data); - - /** - * Conversion operator to a string. - */ - operator std::string& () const; - - /** - * Getter function for the internal data string. - */ - const std::string& data() const; - - /** - * Setter function for the internal data string. - */ - void data( - const std::string& data); -}; - -/** - * @brief - * Class that is a built-in topic type that can be used to readily create Topics, - * DataReaders and DataWriters for this type without the need for code generation. - * - * This built-in type allows for easy transfer of keyed strings. - */ -template -class TKeyedStringTopicType : public Value -{ -public: - - /** - * Creates topic type with an empty key and data strings. - */ - TKeyedStringTopicType(); - - /** - * Creates topic type with the given key and data strings. - */ - TKeyedStringTopicType( - const std::string& key, - const std::string& value); - - /** - * Getter function for the key string. - */ - const std::string& key() const; - - /** - * Setter function for the key string. - */ - void key( - const std::string& key); - - /** - * Getter function for the internal data string. - */ - const std::string& value() const; - - /** - * Setter function for the internal data string. - */ - void value( - const std::string& value); -}; - -/** - * @brief - * Class that is a built-in topic type that can be used to readily create Topics, - * DataReaders and DataWriters for this type without the need for code generation. - * - * This built-in type allows for easy transfer of keyed vectors of bytes. - */ -template -class TKeyedBytesTopicType : public Value -{ -public: - - /** - * Creates topic type with an empty key string and data vector. - */ - TKeyedBytesTopicType(); - - /** - * Creates topic type with given key string and data vector. - */ - TKeyedBytesTopicType( - const std::string& key, - const std::vector& value); - - /** - * Getter function for the key string. - */ - const std::string& key() const; - - /** - * Setter function for the key string. - */ - void key( - const std::string& key); - - /** - * Getter function for the internal vector of bytes. - */ - const std::vector& value() const; - - /** - * Setter function for the internal vector of bytes. - */ - void value( - const std::vector& value); -}; - -/** - * @file - * This file contains the type definitions for BuiltinTopicTypes - */ -typedef dds::core::detail::BytesTopicType BytesTopicType; -typedef dds::core::detail::StringTopicType StringTopicType; -typedef dds::core::detail::KeyedBytesTopicType KeyedBytesTopicType; -typedef dds::core::detail::KeyedStringTopicType KeyedStringTopicType; - -} //namespace core -} //namespace dds - -#endif //OMG_DDS_X_TYPES_BUILTIN_TOPIC_TYPES_SUPPORT - -#endif //OMG_DDS_CORE_BUILTIN_TOPIC_TYPES_HPP_ diff --git a/include/dds/core/Duration.hpp b/include/dds/core/Duration.hpp deleted file mode 100644 index ae7cbff1e73..00000000000 --- a/include/dds/core/Duration.hpp +++ /dev/null @@ -1,296 +0,0 @@ -/* - * Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * All rights reserved. - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_CORE_DURATION_HPP_ -#define OMG_DDS_CORE_DURATION_HPP_ - -#include - -namespace dds { -namespace core { - -/** - * @file - * This class represents a time interval. - */ - -/** - * Duration represents a time interval and - - * * Can be incremented by durations expressed as seconds, nanoseconds - * milliseconds, or Duration objects. - * - * * Can be converted to and from Durations expressed in - * milliseconds (or other units) as integer types. - */ -class OMG_DDS_API Duration -{ -public: - - /** - * Create a Duration elapsing zero seconds. - */ - static const Duration zero(); // {0, 0} - - /** - * Create an infinite Duration. - */ - static const Duration infinite(); // {0x7fffffff, 0x7fffffff} - - /** - * Create a Duration elapsing the default amount of time (zero seconds). - */ - Duration(); - - /** - * Create a Duration elapsing a specific amount of time. - * - * @param sec Amount of seconds for the Duration. - * @param nanosec Amount of nanoseconds for the Duration. - */ - explicit Duration( - int32_t sec, - uint32_t nanosec = 0); - -#if __cplusplus >= 199711L - /** @copydoc dds::core::Duration::Duration(int32_t sec, uint32_t nanosec = 0) */ - explicit Duration( - int64_t sec, - uint32_t nanosec = 0); -#endif - - /** - * Create a Duration from a number of microseconds - * @param microseconds number of microseconds - */ - static const Duration from_microsecs( - int64_t microseconds); - - /** - * Create a Duration from a number of milliseconds - * @param miliseconds number of milliseconds - */ - static const Duration from_millisecs( - int64_t milliseconds); - - /** - * Create a Duration from a number of seconds - * @param seconds number of seconds - */ - static const Duration from_secs( - double seconds); - - /** - * Get seconds part of the Duration. - * @return number of seconds - */ - int64_t sec() const; - /** - * Set number of seconds - * @param s number of seconds - */ - void sec( - int64_t s); - - /** - * Get nanoseconds part of the Duration. - * @return number of nanoseconds - */ - uint32_t nanosec() const; - /** - * Set number of nanoseconds - * @param ns number of nanoseconds - */ - void nanosec( - uint32_t ns); - - /** - * Returns an integer value for a comparison of two Durations: - * 1 if this Duration is greater than the comparator (that) - * -1 if the Duration is less than the comparator (that) - * 0 if the Duration matches the comparator (that) - * - * @param that Duration to compare - * - * @return comparison result - */ - int compare( - const Duration& that) const; - - /** - * Returns true if the Duration is greater than the comparator - * - * @param that Duration to compare - * @return comparison result - */ - bool operator >( - const Duration& that) const; - - /** - * Returns true if the Duration is greater than or equal to the comparator - * @param Duration &that - */ - bool operator >=( - const Duration& that) const; - - /** - * Returns true if the Duration is not equal to the comparator - * - * @param that Duration to compare - * @return comparison result - */ - bool operator !=( - const Duration& that) const; - - /** - * Returns true if the Duration is equal to the comparator - * - * @param that Duration to compare - * @return comparison result - */ - bool operator ==( - const Duration& that) const; - - /** - * Returns true if the Duration is less than or equal to the comparator - * - * @param that Duration to compare - * @return comparison result - */ - bool operator <=( - const Duration& that) const; - - /** - * Returns true if the Duration is less than the comparator - * - * @param that Duration to compare - * @return comparison result - */ - bool operator <( - const Duration& that) const; - - /** - * Add a Duration to this Duration - * - * @param a_ti Duration to add - * @return this Duration + a_ti - */ - Duration& operator +=( - const Duration& a_ti); - - /** - * Subtract a Duration from this Duration - * - * @param a_ti Duration to subtract - * @return this Duration - a_ti - */ - Duration& operator -=( - const Duration& a_ti); - - /** - * Multiply this Duration by a factor - * - * @param factor the factor to multiply this Duration by - * @return this Duration * factor - */ - Duration& operator *=( - uint64_t factor); - - /** - * Add a Duration to Duration - * - * @param other a Duration - * @return Duration + other - */ - const Duration operator +( - const Duration& other) const; - - /** - * Subtract a Duration from Duration - * - * @param other a Duration - * @return the Duration - other - */ - const Duration operator -( - const Duration& other) const; - /** - * Returns this Duration in milliseconds. - * - * @return the duration in milliseconds - */ - int64_t to_millisecs() const; - - /** - * Returns this Duration in micro-seconds. - * - * @return the duration in micro-seconds - */ - int64_t to_microsecs() const; - - /** - * Returns this Duration in seconds. - * - * @return the duration in seconds - */ - double to_secs() const; - -private: - - int32_t sec_ = 0; - uint32_t nsec_ = 0; -}; - -/** - * Multiply Duration by a factor - * - * @param lhs factor by which to multiply - * @param rhs Duration to multiply - * - * @return factor * Duration - */ -const Duration OMG_DDS_API operator *( - uint64_t lhs, - const Duration& rhs); - -/** - * Multiply Duration by a factor - * - * @param lhs Duration to multiply - * @param rhs factor by which to multiply - * - * @return Duration * factor - */ -const Duration OMG_DDS_API operator *( - const Duration& lhs, - uint64_t rhs); - -/** - * Divide Duration by a factor - * - * @param lhs Duration to divide - * @param rhs factor by which to divide - */ -const Duration OMG_DDS_API operator /( - const Duration& lhs, - uint64_t rhs); - -} //namespace core -} //namespace dds - -#endif //OMG_DDS_CORE_DURATION_HPP_ diff --git a/include/dds/core/Entity.hpp b/include/dds/core/Entity.hpp deleted file mode 100644 index db5c970b61d..00000000000 --- a/include/dds/core/Entity.hpp +++ /dev/null @@ -1,273 +0,0 @@ -/* - * Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * All rights reserved. - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_CORE_ENTITY_HPP_ -#define OMG_DDS_CORE_ENTITY_HPP_ - -#include -#include -#include - -#include - -namespace dds { -namespace core { - -/** - * @brief This class is the abstract base class for all the DCPS objects. - * - * This class is the abstract base class for all of the DCPS objects - * that support QoS policies a listener and a status condition: - * - * - dds::domain::DomainParticipant - * - dds::sub::Subscriber - * - dds::sub::DataReader - * - dds::pub::Publisher - * - dds::pub::DataWriter - * - dds::topic::Topic - * - * In the ISO C++ PSM each DDS entity behaves like a polymorphic reference - * in that it automatically manages its resource and it can be - * safely assigned up and down the DDS Entity type hierarchy. - * - */ -template -class TEntity : public virtual Reference -{ -public: - - OMG_DDS_REF_TYPE_PROTECTED_DC( - TEntity, - Reference, - DELEGATE) - - OMG_DDS_IMPLICIT_REF_BASE( - TEntity) - - /** @cond */ - virtual ~TEntity() - { - } - - /** @endcond */ - - /** - * Enable entity. - * - * This operation enables the Entity. Entity objects can be created - * either enabled or disabled. This is controlled by the value of - * the dds::core::policy::EntityFactory QoS policy on the corresponding - * factory for the Entity. - * - * Enabled entities are immediately activated at creation time meaning all their - * immutable QoS settings can no longer be changed. Disabled Entities are not yet - * activated, so it is still possible to change there immutable QoS settings. However, - * once activated the immutable QoS settings can no longer be changed. - * - * Creating disabled entities can make sense when the creator of the Entity does not - * yet know which QoS settings to apply, thus allowing another piece of code to set the - * QoS later on. - * - * The default setting of dds::core::policy::EntityFactory is such that, - * by default, it is not necessary to explicitly call enable on newly- - * created entities. - * - * The enable operation is idempotent. Calling enable on an already- - * enabled Entity does not raise exceptions and has no effect. - * - * If an Entity has not yet been enabled, the only operations that can be invoked on it - * are: the ones to set, get or copy the QosPolicy settings, the ones that set (or get) the - * listener, the ones that get the StatusCondition, the get_status_changes - * operation (although the status of a disabled entity never changes), and the ‘factory’ - * operations that create, delete or lookup other Entities. Other operations will - * throw the exception dds::core::NotEnabledError. - * - * Entities created from a factory that is disabled are created - * disabled regardless of the setting of the dds::core::policy::EntityFactory - * Qos policy. Calling enable on an Entity whose factory is not - * enabled will fail and throw an dds::core::PreconditionNotMetError - * exception. - * - * If the dds::core::policy::EntityFactory QoS policy has autoenable_created_entities - * set to TRUE, the enable operation on the factory will automatically - * enable all entities created from the factory. - * - * The Listeners associated with an entity are not called until - * the entity is enabled. Conditions associated with an entity that - * is not enabled are inactive; that is, they have a trigger_value==false - * (dds::core::cond::Condition and dds::core::cond::WaitSet). - * - * eg. - * @code{.cpp} - * dds::domain::qos::DomainParticipantQos dpq; - * dpq << dds::core::policy::EntityFactory::ManuallyEnable(); - * ... - * dds::sub::DataReader dr(dp, topic, drqos); - * dr.enable(); - * @endcode - * - * In addition to the general description, the enable operation on a dds::sub::Subscriber - * has special meaning in specific usecases. This applies only to Subscribers with PresentationQoS - * coherent-access set to true with access-scope set to group. - * - * In this case the subscriber is always created in a disabled state, regardless of the auto-enable - * created entities setting on the corresponding participant. While the subscriber remains disabled, - * DataReaders can be created that will participate in coherent transactions of the subscriber. - * - * See dds::sub::CoherentAccess for more information. - * - * All DataReaders will also be created in a disabled state. Coherency with group access-scope requires - * data to be delivered as a transaction, atomically, to all eligible readers. Therefore data should not be - * delivered to any single DataReader immediately after it's created, as usual, but only after the application - * has finished creating all DataReaders for a given Subscriber. At this point, the application should enable the - * Subscriber which in turn enables all its DataReaders. - * - * Note that for a dds::pub::DataWriter which has a corresponding dds::pub::Publisher - * with a PresentationQoS with coherent-access set to true and access-scope set to topic or group - * that the HistoryQoS of the dds::pub::DataWriter should be set to keep-all otherwise the enable operation - * will fail. - * - * See dds::pup::DataWriter for more information. - * - * @return void - * @throw dds::core::PreconditionNotMetError - * Entities' factory is not enabled. - */ - OMG_DDS_API void enable() - { - this->delegate()->enable(); - } - - /** - * This operation returns a mask with the communication statuses in the Entity that - * are “triggered”. - * - * This operation retrieves the list of communication statuses in the Entity - * that are triggered. That is the set of communication statuses whose value have changed - * since the last time the application called this operation. This operation shows - * whether a change has occurred even when the status seems unchanged because the - * status changed back to the original status. - * - * When the Entity is first created or if the Entity is not enabled, all - * communication statuses are in the “un-triggered” state so the mask returned by the - * operation is empty. - * - * The result value is a bit mask in which each bit shows which value has changed. The - * relevant bits represent one of the following statuses: - * - dds::core::status::StatusMask::inconsistent_topic() - * - dds::core::status::StatusMask::offered_deadline_missed() - * - dds::core::status::StatusMask::requested_deadline_missed() - * - dds::core::status::StatusMask::offered_incompatible_qos() - * - dds::core::status::StatusMask::requested_incompatible_qos() - * - dds::core::status::StatusMask::sample_lost() - * - dds::core::status::StatusMask::sample_rejected() - * - dds::core::status::StatusMask::data_on_readers() - * - dds::core::status::StatusMask::data_available() - * - dds::core::status::StatusMask::liveliness_lost() - * - dds::core::status::StatusMask::liveliness_changed() - * - dds::core::status::StatusMask::publication_matched() - * - dds::core::status::StatusMask::subscription_matched() - * - dds::core::status::StatusMask::all_data_disposed_topic() - * - * Each status bit is declared as a constant and can be used in an AND operation to - * check the status bit against the result of type StatusMask. Not all statuses are - * relevant to all Entity objects. See the respective Listener interfaces for each - * Entity for more information. - * - * The list of statuses returned by the status_changes operation refers - * to the statuses that are triggered on the Entity itself, and does not - * include statuses that apply to contained entities. - * - * @return dds::core::status::StatusMask - * a bit mask in which each bit shows which value has changed. - */ - OMG_DDS_API const dds::core::status::StatusMask status_changes() - { - return this->delegate()->get_status_changes(); - } - - /** - * This operation returns the InstanceHandle_t that represents the Entity. - * - * The relevant state of some Entity objects are distributed using built-in topics. - * Each built-in topic sample represents the state of a specific Entity and has a - * unique instance_handle. This operation returns the instance_handle of the - * built-in topic sample that represents the specified Entity.
    - * Some Entities (dds::pub::Publisher and dds::sub::Subscriber) do not have a corresponding - * built-in topic sample, but they still have an instance_handle that uniquely - * identifies the Entity. The instance_handles obtained this way can also be used - * to check whether a specific Entity is located in a specific DomainParticipant - * (dds::domain::DomainParticipant::contains_entity()). - * - * @return dds::core::InstanceHandle - * Result value is the instance_handle of the built-in topic - * sample that represents the state of this Entity. - */ - OMG_DDS_API const InstanceHandle instance_handle() const - { - return this->delegate()->get_instance_handle(); - } - - /** - * This function closes the entity and releases related resources. - * - * Resource management for some reference types might involve relatively heavyweight - * operating- system resources — such as e.g., threads, mutexes, and network sockets — - * in addition to memory. These objects therefore provide a method close() that shall - * halt network communication (in the case of entities) and dispose of any appropriate - * operating-system resources. - * - * Users of this PSM are recommended to call close on objects of all reference types once - * they are finished using them. In addition, implementations may automatically close - * objects that they deem to be no longer in use, subject to the following restrictions: - * - Any object to which the application has a direct reference is still in use. - * - Any object that has been explicitly retained is still in use - * - The creator of any object that is still in use is itself still in use. - * - * @return void - */ - OMG_DDS_API void close() - { - this->delegate()->close(); - } - - /** - * Retain the Entity, even when it goes out of scope. - * - * This function indicates that references to this object may go out of - * scope but that the application expects to look it up again later. - * Therefore the Service must consider this object to be still in use - * and may not close it automatically. - * - * @return void - */ - OMG_DDS_API void retain() - { - // this->delegate()->retain(); - } - -}; - -typedef dds::core::detail::Entity Entity; - -} //namespace core -} //namespace dds - -#endif //OMG_DDS_CORE_ENTITY_HPP_ diff --git a/include/dds/core/EntityQos.hpp b/include/dds/core/EntityQos.hpp deleted file mode 100644 index 026d0800d5b..00000000000 --- a/include/dds/core/EntityQos.hpp +++ /dev/null @@ -1,143 +0,0 @@ -/* - * Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * All rights reserved. - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_TDDS_CORE_QOS_ENTITY_QOS_HPP_ -#define OMG_TDDS_CORE_QOS_ENTITY_QOS_HPP_ - -#include - - -namespace dds { -namespace core { -template -class TEntityQos; - -/** - * @brief - * QoS Container - * - * Acts as a container for Qos policies allowing all the policies of - * an entity to be set and retrieved as a unit. - * - * For more information see \ref DCPS_Modules_Infrastructure "Infrastructure Module" - * and \ref DCPS_QoS "Supported Quality of Service" - */ -template -class TEntityQos : public Value -{ -public: - - /** - * Create default QoS. - */ - TEntityQos(); - - /** - * Create copied QoS. - * - * @param other the QoS to copy. - */ - TEntityQos( - const TEntityQos& other); - - /** - * Create/copy QoS from different QoS type. - * - * @param qos the QoS to copy policies from. - */ - template - TEntityQos( - const TEntityQos& qos); - -public: - - /** @cond */ - ~TEntityQos(); - /** @endcond */ - -public: - - /** - * Generic function for setting a policy applicable to this QoS object. - * Available policies depend on the actual instantiation of the template - * class, which might be DomainParticipantQos, TopicQos, PublisherQos, etc. - * - * @param p the policy to be set for this QoS instance. - */ - template - TEntityQos& policy( - const POLICY& p); - - /** - * Generic function for obtaining the value of a specific policy - * belonging to this QoS instance. - * - * @return policy - */ - template - const POLICY& policy() const; - - /** - * Generic function for obtaining the value of a specific policy - * belonging to this QoS instance. - * - * @return policy - */ - template - POLICY& policy(); - - /** - * Generic function for setting a policy applicable to this QoS object. - * Available policies depend on the actual instantiation of the template - * class, which might be DomainParticipantQos, TopicQos, PublisherQos, etc. - * - * @param p the policy to be set for this QoS instance. - */ - template - TEntityQos& operator <<( - const POLICY& p); - - /** - * Generic function for obtaining the value of a specific policy - * belonging to this QoS instance. - * - * @return policy - */ - template - const TEntityQos& operator >>( - POLICY& p) const; - - /** - * Generic function for setting a policy applicable to this QoS object. - * Available policies depend on the actual instantiation of the template - * class, which might be DomainParticipantQos, TopicQos, PublisherQos, etc. - * - * @param TEntityQos the TEntityQos to set - */ - template - TEntityQos& operator =( - const TEntityQos& other); - -}; - -} //namespace core -} //namespace dds - -#endif //OMG_TDDS_CORE_QOS_ENTITY_QOS_HPP_ diff --git a/include/dds/core/Exception.hpp b/include/dds/core/Exception.hpp deleted file mode 100644 index 003912179e8..00000000000 --- a/include/dds/core/Exception.hpp +++ /dev/null @@ -1,479 +0,0 @@ -/* - * Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_CORE_EXCEPTION_HPP_ -#define OMG_DDS_CORE_EXCEPTION_HPP_ - -#include - -#include -#include - -#if defined _MSC_VER -# pragma warning (push) -# pragma warning (disable:4275) // non dll-interface class 'std::foo_error' used as base for dll-interface class 'dds::core::BarError' -#endif - -namespace dds { -namespace core { - -/** - * @brief - * %Exception: base class for specified DDS Exceptions. - * - * DDS PIM Return Code | DDS-PSM-CXX Exception Class | std C++ Parent Exception - * ------------------- | --------------------------- | ------------------------ - * RETCODE_OK | Normal return; no exception | N/A - * RETCODE_NO_DATA | Normal return with informational state attached | N/A - * RETCODE_ERROR | Error | std::logic_error - * RETCODE_BAD_PARAMETER | InvalidArgumentError | std::invalid_argument - * RETCODE_TIMEOUT | TimeoutError | std::runtime_error - * RETCODE_UNSUPPORTED | UnsupportedError | std::logic_error - * RETCODE_ALREADY_DELETED | AlreadyClosedError | std::logic_error - * RETCODE_ILLEGAL_OPERATION | IllegalOperationError | std::logic_error - * RETCODE_NOT_ENABLED | NotEnabledError | std::logic_error - * RETCODE_PRECONDITION_NOT_MET | PreconditionNotMetError | std::logic_error - * RETCODE_IMMUTABLE_POLICY | ImmutablePolicyError | std::logic_error - * RETCODE_INCONSISTENT_POLICY | InconsistentPolicyError | std::logic_error - * RETCODE_OUT_OF_RESOURCES | OutOfResourcesError | std::runtime_error - * - * The DDS-PSM-Cxx maps error codes to C++ exceptions defined in the dds::core namespace and - * inheriting from a base Exception class and the appropriate standard C++ exception. - * Table 7.3 lists the mapping between error codes as defined in the DDS PIM and C++ exceptions - * as used in this specification. Exceptions have value semantics; this means that they must - * always have deep copy semantics. - * The full list of exceptions is included in the file dds/core/Exceptions.hpp. - * - */ -class Exception -{ -protected: - - OMG_DDS_API Exception() - { - } - -public: - - /** @cond */ - OMG_DDS_API virtual ~Exception() throw() - { - } - - /** @endcond */ - -public: - - /** - * Retrieve information about the exception that was thrown. - * - * Example - * @code{.cpp} - * try { - * // Do something that will trigger a dds exception, like: - * dds::domain::DomainParticipant participant = dds::core::null; - * participant.domain_id(); - * } catch (const dds::core::Exception& e) { - * std::cout << e.what() << std::endl; - * } - * @endcode - * %Exception information (of the NullReferenceError in this case) - * @code - * Null reference: Reference[157] == dds::core::null - * ======================================================================================== - * Context : dds::domain::DomainParticipant::domain_id - * Date : Wed Oct 21 19:28:00 CET 2015 - * Node : DeLorean - * Process : flux_capacitor <15423> - * Thread : mr_fusion b6f25700 - * Internals : ReferenceImpl.hpp/157/V6.6.0 - * ---------------------------------------------------------------------------------------- - * Report : Null reference: Reference[157] == dds::core::null - * Internals : dds::core::Reference::delegate/ReferenceImpl.hpp/157 - * @endcode - * - * @return Exception information - */ - OMG_DDS_API virtual const char* what() const throw() = 0; -}; - -/** - * @brief - * %Exception: Generic, unspecified error. - */ -class Error : public Exception, public std::logic_error -{ - /** @cond */ - -public: - - OMG_DDS_API explicit Error( - const std::string& msg); - - OMG_DDS_API Error( - const Error& src); - - OMG_DDS_API virtual ~Error() throw(); - -public: - - OMG_DDS_API virtual const char* what() const throw(); - /** @endcond */ -}; - -/** - * @brief - * %Exception: The object target of this operation has already been closed. - */ -class AlreadyClosedError : public Exception, public std::logic_error -{ - /** @cond */ - -public: - - OMG_DDS_API explicit AlreadyClosedError( - const std::string& msg); - - OMG_DDS_API AlreadyClosedError( - const AlreadyClosedError& src); - - OMG_DDS_API virtual ~AlreadyClosedError() throw(); - -public: - - OMG_DDS_API virtual const char* what() const throw(); - /** @endcond */ -}; - -/** - * @brief - * %Exception: An operation was invoked on an inappropriate object or at an inappropriate time. - * - * This is determined by policies set by the specification or the Service implementation. - * - * There is no precondition that could be changed to make the operation succeed. - */ -class IllegalOperationError : public Exception, public std::logic_error -{ - /** @cond */ - -public: - - OMG_DDS_API explicit IllegalOperationError( - const std::string& msg); - - OMG_DDS_API IllegalOperationError( - const IllegalOperationError& src); - - OMG_DDS_API virtual ~IllegalOperationError() throw(); - -public: - - OMG_DDS_API virtual const char* what() const throw(); - /** @endcond */ -}; - -/** - * @brief - * %Exception: Application attempted to modify an immutable QosPolicy. - */ -class ImmutablePolicyError : public Exception, public std::logic_error -{ - /** @cond */ - -public: - - OMG_DDS_API explicit ImmutablePolicyError( - const std::string& msg); - - OMG_DDS_API ImmutablePolicyError( - const ImmutablePolicyError& src); - - OMG_DDS_API virtual ~ImmutablePolicyError() throw(); - -public: - - OMG_DDS_API virtual const char* what() const throw(); - /** @endcond */ -}; - -/** - * @brief - * %Exception: Application specified a set of policies that are not - * consistent with each other. - */ -class InconsistentPolicyError : public Exception, public std::logic_error -{ - /** @cond */ - -public: - - OMG_DDS_API explicit InconsistentPolicyError( - const std::string& msg); - - OMG_DDS_API InconsistentPolicyError( - const InconsistentPolicyError& src); - - OMG_DDS_API virtual ~InconsistentPolicyError() throw(); - -public: - - OMG_DDS_API virtual const char* what() const throw(); - /** @endcond */ -}; - -/** - * @brief - * %Exception: Application is passing an invalid argument. - */ -class InvalidArgumentError : public Exception, public std::invalid_argument -{ - /** @cond */ - -public: - - OMG_DDS_API explicit InvalidArgumentError( - const std::string& msg); - - OMG_DDS_API InvalidArgumentError( - const InvalidArgumentError& src); - - OMG_DDS_API virtual ~InvalidArgumentError() throw(); - -public: - - OMG_DDS_API virtual const char* what() const throw(); - /** @endcond */ -}; - -/** - * @brief - * %Exception: Operation invoked on an Entity that is not yet enabled. - */ -class NotEnabledError : public Exception, public std::logic_error -{ - /** @cond */ - -public: - - OMG_DDS_API explicit NotEnabledError( - const std::string& msg); - - OMG_DDS_API NotEnabledError( - const NotEnabledError& src); - - OMG_DDS_API virtual ~NotEnabledError() throw(); - -public: - - OMG_DDS_API virtual const char* what() const throw(); - /** @endcond */ -}; - -/** - * @brief - * %Exception: Service ran out of the resources needed to complete the - * operation. - */ -class OutOfResourcesError : public Exception, public std::runtime_error -{ - /** @cond */ - -public: - - OMG_DDS_API explicit OutOfResourcesError( - const std::string& msg); - - OMG_DDS_API OutOfResourcesError( - const OutOfResourcesError& src); - - OMG_DDS_API virtual ~OutOfResourcesError() throw(); - -public: - - OMG_DDS_API virtual const char* what() const throw(); - /** @endcond */ -}; - - -/** - * @brief - * %Exception: A pre-condition for the operation was not met. - */ -class PreconditionNotMetError : public Exception, public std::logic_error -{ - /** @cond */ - -public: - - OMG_DDS_API explicit PreconditionNotMetError( - const std::string& msg); - - OMG_DDS_API PreconditionNotMetError( - const PreconditionNotMetError& src); - - OMG_DDS_API virtual ~PreconditionNotMetError() throw(); - -public: - - OMG_DDS_API virtual const char* what() const throw(); - /** @endcond */ -}; - -/** - * @brief - * %Exception: The operation timed out. - */ -class TimeoutError : public Exception, public std::runtime_error -{ - /** @cond */ - -public: - - OMG_DDS_API explicit TimeoutError( - const std::string& msg); - - OMG_DDS_API TimeoutError( - const TimeoutError& src); - - OMG_DDS_API virtual ~TimeoutError() throw(); - -public: - - OMG_DDS_API virtual const char* what() const throw(); - /** @endcond */ -}; - -/** - * @brief - * %Exception: Unsupported operation. - * - * This can only be thrown by operations that are optional. - */ -class UnsupportedError : public Exception, public std::logic_error -{ - /** @cond */ - -public: - - OMG_DDS_API explicit UnsupportedError( - const std::string& msg); - - OMG_DDS_API UnsupportedError( - const UnsupportedError& src); - - OMG_DDS_API virtual ~UnsupportedError() throw(); - -public: - - OMG_DDS_API virtual const char* what() const throw(); - /** @endcond */ -}; - -/** - * @brief - * %Exception: Application has attempted to cast incompatible types. - */ -class InvalidDowncastError : public Exception, public std::runtime_error -{ - /** @cond */ - -public: - - OMG_DDS_API explicit InvalidDowncastError( - const std::string& msg); - - OMG_DDS_API InvalidDowncastError( - const InvalidDowncastError& src); - - OMG_DDS_API virtual ~InvalidDowncastError() throw(); - -public: - - OMG_DDS_API virtual const char* what() const throw(); - /** @endcond */ -}; - -/** - * @brief - * %Exception: Application used a null reference. - * - * Very likely, the used DDS object is a dds::core::null object. - * @code{.cpp} - * dds::domain::DomainParticipant participant = dds::core::null; - * try { - * participant.domain_id(); - * } catch (const dds::core::NullReferenceError& e) { - * std::cout << e.what() << std::endl; - * } - * @endcode - */ -class NullReferenceError : public Exception, public std::runtime_error -{ - /** @cond */ - -public: - - OMG_DDS_API explicit NullReferenceError( - const std::string& msg); - - OMG_DDS_API NullReferenceError( - const NullReferenceError& src); - - OMG_DDS_API virtual ~NullReferenceError() throw(); - -public: - - OMG_DDS_API virtual const char* what() const throw(); - /** @endcond */ -}; - -/** - * @brief - * %Exception: Application provided invalid data - */ -class InvalidDataError : public Exception, public std::logic_error -{ - /** @cond */ - -public: - - OMG_DDS_API explicit InvalidDataError( - const std::string& msg); - - OMG_DDS_API InvalidDataError( - const InvalidDataError& src); - - OMG_DDS_API virtual ~InvalidDataError() throw(); - -public: - - OMG_DDS_API virtual const char* what() const throw(); - /** @endcond */ -}; - -} //namespace core -} //namespace dds - -#if defined _MSC_VER -# pragma warning (pop) -#endif - -#endif //OMG_DDS_CORE_EXCEPTION_HPP_ - diff --git a/include/dds/core/InstanceHandle.hpp b/include/dds/core/InstanceHandle.hpp deleted file mode 100644 index 50be1bcd824..00000000000 --- a/include/dds/core/InstanceHandle.hpp +++ /dev/null @@ -1,143 +0,0 @@ -/* - * Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * All rights reserved. - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_CORE_INSTANCE_HANDLE_HPP_ -#define OMG_DDS_CORE_INSTANCE_HANDLE_HPP_ - -#include -#include - -#include -#include - -#include - -namespace dds { -namespace core { - -/** - * @brief - * Class to hold the handle associated with in sample instance. - */ -class InstanceHandle : public Value -{ -public: - - /** - * Create an nil instance handle. - */ - OMG_DDS_API InstanceHandle(); - - /** - * Create an nil instance handle. - * - * @param nullHandle placeholder - */ - OMG_DDS_API InstanceHandle( - const null_type& nullHandle); - - - /** - * Copy an existing InstancHandle - * - * @param other InstanceHandle to copy - */ - OMG_DDS_API InstanceHandle( - const InstanceHandle& other); - - /** @cond */ - OMG_DDS_API ~InstanceHandle(); - /** @endcond */ - - /** - * @cond - * Parametric constructor for creating an instance-handle - * from some other type. This function is intended for internal - * usage. - */ - OMG_DDS_API InstanceHandle( - const detail::InstanceHandle& arg0); - /** @endcond */ - -public: - - /** - * Assign an existing InstancHandle to this InstancHandle - * - * @param that The InstanceHandle to assign to this - */ - OMG_DDS_API InstanceHandle& operator =( - const InstanceHandle& that); - - /** - * Compare this InstanceHandle to another InstanceHandle - * - * @param that The InstanceHandle to compare - * @return true if they match - */ - OMG_DDS_API bool operator ==( - const InstanceHandle& that) const; - - /** - * Compare this InstanceHandle to another InstanceHandle - * - * @param that The InstanceHandle to compare - * @return true if this is less than that - */ - OMG_DDS_API bool operator <( - const InstanceHandle& that) const; - - /** - * Compare this InstanceHandle to another InstanceHandle - * - * @param that The InstanceHandle to compare - * @return true if this is greater than that - */ - OMG_DDS_API bool operator >( - const InstanceHandle& that) const; - -public: - - /** - * Create an nil instance handle. - * - * @return a nil InstanceHandle - */ - OMG_DDS_API static const InstanceHandle nil(); - - /** - * Check if the InstanceHandle is nil. - * - * @return true if the InstanceHandle is nil - */ - OMG_DDS_API bool is_nil() const; -}; - -typedef std::vector InstanceHandleSeq; - -} //namespace core -} //namespace dds - -inline std::ostream& operator <<( - std::ostream& os, - const dds::core::InstanceHandle& h); - - -#endif //OMG_DDS_CORE_INSTANCE_HANDLE_HPP_ diff --git a/include/dds/core/LengthUnlimited.hpp b/include/dds/core/LengthUnlimited.hpp deleted file mode 100644 index 1199cdd2dda..00000000000 --- a/include/dds/core/LengthUnlimited.hpp +++ /dev/null @@ -1,34 +0,0 @@ -/* - * Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * All rights reserved. - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_CORE_LENGTH_UNLIMITED_HPP_ -#define OMG_DDS_CORE_LENGTH_UNLIMITED_HPP_ - -#include - -namespace dds { -namespace core { - -const uint32_t LENGTH_UNLIMITED = 0; - -} //namespace core -} //namespace dds - -#endif //OMG_DDS_CORE_LENGTH_UNLIMITED_HPP_ diff --git a/include/dds/core/Optional.hpp b/include/dds/core/Optional.hpp deleted file mode 100644 index 0225998cd43..00000000000 --- a/include/dds/core/Optional.hpp +++ /dev/null @@ -1,105 +0,0 @@ -/* - * Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * All rights reserved. - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_CORE_OPTIONAL_HPP_ -#define OMG_DDS_CORE_OPTIONAL_HPP_ - -#include - -namespace dds { -namespace core { - -/** - * The optional class is used to wrap attributes annotated in the idl with the - * \@optional annotation. This class provides a simple and safe way of - * accessing, setting and resetting the stored attribute. - * - * IDL: - * @code - * struct RadarTrack { - * string id; - * long x; - * long y; - * long z; //@Optional - * }; - * @endcode - * - * C++ Representation: - * @code{.cpp} - * class RadarTrack { - * public: - * RadarTrack(); - * RadarTrack(const std::string& id, - * int32_t x, - * int32_t y, - * int32_t z); - * public: - * std::string& id() const; - * void id(const std::string& s); - * - * int32_t x() const; - * void x(int32_t v); - * - * int32_t y() const; - * void y(int32_t v); - * - * dds::core::optional& z() const; - * void z(int32_t v); - * void z(const dds::core::optional& z) - * }; - * @endcode - */ -template< - typename T, - template class DELEGATE> -class optional : public dds::core::Value< DELEGATE > -{ -public: - - optional( - const T& t); - -public: - - /** - * Returns true only if the attribute is set. - */ - bool is_set() const; - - /** - * Reset the attribute. - */ - void reset(); - - /** - * Get the attribute. An exception is thrown if the attribute is not set. - */ - const T& get() const; - - /** - * Get the attribute. An exception is thrown if the attribute is not set. - */ - T& get(); -}; - -} //namespace core -} //namespace dds - -#endif //OMG_DDS_CORE_OPTIONAL_HPP_ diff --git a/include/dds/core/QosProvider.hpp b/include/dds/core/QosProvider.hpp deleted file mode 100644 index 9b22297e9da..00000000000 --- a/include/dds/core/QosProvider.hpp +++ /dev/null @@ -1,355 +0,0 @@ -/* - * Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * All rights reserved. - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_CORE_QOS_PROVIDER_HPP_ -#define OMG_DDS_CORE_QOS_PROVIDER_HPP_ - -#include - -//#include - -//#include - -//#include -//#include - -//#include -//#include - -#include - - -namespace dds { -namespace core { - -/** - * @brief - * The QosProvider API allows users to specify the QoS settings of their DCPS - * entities outside of application code in XML. - * - * The QosProvider is delivered as part of the DCPS API of Vortex OpenSplice. - * - * @see @ref DCPS_QoS_Provider "QoS Provider extensive information." - */ -template -class TQosProvider : public Reference -{ -public: - - /** - * Constructs a new QosProvider based on the provided uri and profile. - * - * A QosProvider instance that is instantiated with all profiles and/or QoS’s loaded - * from the location specified by the provided uri. - * - * Initialization of the QosProvider will fail under the following conditions:
    - * - No uri is provided. - * - The resource pointed to by uri cannot be found. - * - The content of the resource pointed to by uri is malformed (e.g., malformed XML). - * When initialization fails (for example, due to a parse error or when the resource - * identified by uri cannot be found), then PreconditionNotMetError will be thrown. - * - * Look @ref DCPS_QoS_Provider "here" for more information. - * - * @param uri A Uniform Resource Identifier (URI) that points to the location - * where the QoS profile needs to be loaded from. Currently only URI’s with a - * ‘file’ scheme that point to an XML file are supported. If profiles and/or QoS - * settings are not uniquely identifiable by name within the resource pointed to by - * uri, a random one of them will be stored. - * @param profile The name of the QoS profile within the xml file that serves as the default QoS - * profile for the get qos operations. - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::PreconditionNotMetError - * When multiple thread try to invoke the function concurrently. - */ - explicit TQosProvider( - const std::string& uri, - const std::string& profile); - - /** - * Constructs a new QosProvider based on the provided uri. - * - * A QosProvider instance that is instantiated with all profiles and/or QoS’s loaded - * from the location specified by the provided uri. - * - * Initialization of the QosProvider will fail under the following conditions:
    - * - No uri is provided. - * - The resource pointed to by uri cannot be found. - * - The content of the resource pointed to by uri is malformed (e.g., malformed XML). - * When initialization fails (for example, due to a parse error or when the resource - * identified by uri cannot be found), then PreconditionNotMetError will be thrown. - * - * Look @ref DCPS_QoS_Provider "here" for more information. - * - * @param uri A Uniform Resource Identifier (URI) that points to the location - * where the QoS profile needs to be loaded from. Currently only URI’s with a - * ‘file’ scheme that point to an XML file are supported. If profiles and/or QoS - * settings are not uniquely identifiable by name within the resource pointed to by - * uri, a random one of them will be stored. - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::PreconditionNotMetError - * When multiple thread try to invoke the function concurrently. - */ - explicit TQosProvider( - const std::string& uri); - - /** - * Resolves the DomainParticipantQos from the uri this QosProvider is associated with. - * - * @return DomainParticipantQos from the given URI (and profile) - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::PreconditionNotMetError - * If no DomainParticipantQos can be found within the uri associated - * with the QosProvider. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - dds::domain::qos::DomainParticipantQos participant_qos(); - - /** - * Resolves the DomainParticipantQos identified by the id from the uri this - * QosProvider is associated with. - * - * @param id The fully-qualified name that identifies a QoS within the uri - * associated with the QosProvider or a name that identifies a QoS within the - * uri associated with the QosProvider instance relative to its default QoS - * profile. Id’s starting with ‘::’ are interpreted as fully-qualified names and all - * others are interpreted as names relative to the default QoS profile of the - * QosProvider instance. When id is NULL it is interpreted as a non-named QoS - * within the default QoS profile associated with the QosProvider. - * @return DomainParticipantQos from the given URI (and profile) using the id - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::PreconditionNotMetError - * If no DomainParticipantQos that matches the provided id can be - * found within the uri associated with the QosProvider. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - dds::domain::qos::DomainParticipantQos participant_qos( - const std::string& id); - - /** - * Resolves the TopicQos from the uri this QosProvider is associated with. - * - * @return TopicQos from the given URI (and profile) - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::PreconditionNotMetError - * If no TopicQos can be found within the uri associated - * with the QosProvider. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - dds::topic::qos::TopicQos topic_qos(); - - /** - * Resolves the TopicQos identified by the id from the uri this - * QosProvider is associated with. - * - * @param id The fully-qualified name that identifies a QoS within the uri - * associated with the QosProvider or a name that identifies a QoS within the - * uri associated with the QosProvider instance relative to its default QoS - * profile. Id’s starting with ‘::’ are interpreted as fully-qualified names and all - * others are interpreted as names relative to the default QoS profile of the - * QosProvider instance. When id is NULL it is interpreted as a non-named QoS - * within the default QoS profile associated with the QosProvider. - * @return TopicQos from the given URI (and profile) using the id - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::PreconditionNotMetError - * If no TopicQos that matches the provided id can be - * found within the uri associated with the QosProvider. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - dds::topic::qos::TopicQos topic_qos( - const std::string& id); - - /** - * Resolves the SubscriberQos from the uri this QosProvider is associated with. - * - * @return SubscriberQos from the given URI (and profile) - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::PreconditionNotMetError - * If no SubscriberQos can be found within the uri associated - * with the QosProvider. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - dds::sub::qos::SubscriberQos subscriber_qos(); - - /** - * Resolves the SubscriberQos identified by the id from the uri this - * QosProvider is associated with. - * - * @param id The fully-qualified name that identifies a QoS within the uri - * associated with the QosProvider or a name that identifies a QoS within the - * uri associated with the QosProvider instance relative to its default QoS - * profile. Id’s starting with ‘::’ are interpreted as fully-qualified names and all - * others are interpreted as names relative to the default QoS profile of the - * QosProvider instance. When id is NULL it is interpreted as a non-named QoS - * within the default QoS profile associated with the QosProvider. - * @return SubscriberQos from the given URI (and profile) using the id - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::PreconditionNotMetError - * If no SubscriberQos that matches the provided id can be - * found within the uri associated with the QosProvider. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - dds::sub::qos::SubscriberQos subscriber_qos( - const std::string& id); - - /** - * Resolves the DataReaderQos from the uri this QosProvider is associated with. - * - * @return DataReadertQos from the given URI (and profile) - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::PreconditionNotMetError - * If no DataReaderQos can be found within the uri associated - * with the QosProvider. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - dds::sub::qos::DataReaderQos datareader_qos(); - - /** - * Resolves the DataReaderQos identified by the id from the uri this - * QosProvider is associated with. - * - * @param id The fully-qualified name that identifies a QoS within the uri - * associated with the QosProvider or a name that identifies a QoS within the - * uri associated with the QosProvider instance relative to its default QoS - * profile. Id’s starting with ‘::’ are interpreted as fully-qualified names and all - * others are interpreted as names relative to the default QoS profile of the - * QosProvider instance. When id is NULL it is interpreted as a non-named QoS - * within the default QoS profile associated with the QosProvider. - * @return DataReaderQos from the given URI (and profile) using the id - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::PreconditionNotMetError - * If no DataReaderQos that matches the provided id can be - * found within the uri associated with the QosProvider. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - dds::sub::qos::DataReaderQos datareader_qos( - const std::string& id); - - /** - * Resolves the PublisherQos from the uri this QosProvider is associated with. - * - * @return PublisherQos from the given URI (and profile) - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::PreconditionNotMetError - * If no PublisherQos can be found within the uri associated - * with the QosProvider. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - dds::pub::qos::PublisherQos publisher_qos(); - - /** - * Resolves the PublisherQos identified by the id from the uri this - * QosProvider is associated with. - * - * @param id The fully-qualified name that identifies a QoS within the uri - * associated with the QosProvider or a name that identifies a QoS within the - * uri associated with the QosProvider instance relative to its default QoS - * profile. Id’s starting with ‘::’ are interpreted as fully-qualified names and all - * others are interpreted as names relative to the default QoS profile of the - * QosProvider instance. When id is NULL it is interpreted as a non-named QoS - * within the default QoS profile associated with the QosProvider. - * @return PublisherQos from the given URI (and profile) using the id - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::PreconditionNotMetError - * If no PublisherQos that matches the provided id can be - * found within the uri associated with the QosProvider. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - dds::pub::qos::PublisherQos publisher_qos( - const std::string& id); - - /** - * Resolves the DataWriterQos from the uri this QosProvider is associated with. - * - * @return DataWriterQos from the given URI (and profile) - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::PreconditionNotMetError - * If no DataWriterQos can be found within the uri associated - * with the QosProvider. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - dds::pub::qos::DataWriterQos datawriter_qos(); - - /** - * Resolves the DataWriterQos identified by the id from the uri this - * QosProvider is associated with. - * - * @param id The fully-qualified name that identifies a QoS within the uri - * associated with the QosProvider or a name that identifies a QoS within the - * uri associated with the QosProvider instance relative to its default QoS - * profile. Id’s starting with ‘::’ are interpreted as fully-qualified names and all - * others are interpreted as names relative to the default QoS profile of the - * QosProvider instance. When id is NULL it is interpreted as a non-named QoS - * within the default QoS profile associated with the QosProvider. - * @return DataWriterQos from the given URI (and profile) using the id - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::PreconditionNotMetError - * If no DataWriterQos that matches the provided id can be - * found within the uri associated with the QosProvider. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - dds::pub::qos::DataWriterQos datawriter_qos( - const std::string& id); -}; - -typedef dds::core::detail::QosProvider QosProvider; - -} //namespace core -} //namespace dds - -#endif //OMG_DDS_CORE_QOS_PROVIDER_HPP_ diff --git a/include/dds/core/Reference.hpp b/include/dds/core/Reference.hpp deleted file mode 100644 index f93cdcdeae5..00000000000 --- a/include/dds/core/Reference.hpp +++ /dev/null @@ -1,485 +0,0 @@ -/* - * Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_CORE_REFERENCE_HPP_ -#define OMG_DDS_CORE_REFERENCE_HPP_ - -#include -#include -#include //used when macros of refmacros.hpp expand - -namespace dds { -namespace core { - -/** - * @brief - * Base class for reference-counted objects. - * - * All objects that have a reference-type have an associated shallow (polymorphic) - * assignment operator that simply changes the value of the reference. - * Furthermore, reference-types are safe, meaning that under no circumstances can - * a reference point to an invalid object. - * At any single point in time a reference can either refer to the null object or - * to a valid object. - * - * The semantics for Reference types is defined by the DDS-PSM-Cxx class - * dds::core::Reference. In the context of this specification the semantics implied - * by the ReferenceType is mandatory, yet the implementation supplied as part of - * this standard is provided to show one possible way of implementing this semantics. - * - * List of reference types: - * - * * Entity - * * Condition - * * GuardCondition - * * ReadCondition - * * QueryCondition - * * Waitset - * * DomainParticipant - * * AnyDataWriter - * * Publisher - * * DataWriter - * * AnyDataReader - * * Subscriber - * * DataReader - * * SharedSamples - * * AnyTopic - * * Topic - * - * Instances of reference types are created using C++ constructors. - * The trivial constructor is not defined for reference types; the only - * alternative to properly constructing a reference is to initialize it to a - * null reference by assigning dds::core::null. - * - * Resource management for some reference types might involve relatively - * heavyweight operating-system resources (such as threads, mutexes, - * and network sockets) in addition to memory. - * These objects therefore provide a function close() that shall halt network - * communication (in the case of entities) and dispose of any appropriate - * operating-system resources. - * - * Users of this PSM are recommended to call close on objects of all reference - * types once they are finished using them. In addition, implementations may - * automatically close objects that they deem to be no longer in use, - * subject to the following restrictions: - * - * * Any object to which the application has a direct reference - * (not including a WeakReference) is still in use. - * - * * Any object that has been explicitly retained is still in use. - * - * * The creator of any object that is still in use is itself still in use. - * - */ -template -class Reference -{ -public: - - DECLARE_TYPE_TRAITS( - DELEGATE) - - /** - * Creates a "null" Reference. - * - * @param null - */ - explicit Reference( - dds::core::null_type& n) - : impl_(n) - { - } - - /** - * Creates a Reference from another. - * - * @param ref the other reference - */ - explicit Reference( - const Reference& ref) - : impl_(ref.impl_) - { - } - - /** - * Assign a Reference from another. - * - * @param ref the other reference - */ - Reference& operator = ( - const Reference& ref) - { - impl_ = ref.impl_; - return *this; - } - - /** - * Creates a Reference from other Reference type safely. - * - * @param ref the other reference - */ - template - explicit Reference( - const Reference& ref) - { - impl_ = std::dynamic_pointer_cast(ref.impl_); - if (impl_ != ref.impl_) - { - throw - IllegalOperationError(std::string("Attempted invalid cast: ") + - typeid(ref).name() + " to " + typeid(*this).name()); - } - - } - - /** @cond - * The following two constructors create a dds Reference from a vendor - * specific delegate. - * - * They are public, because the implementation of other delegates may - * need to be able to create References in that manner. - * - * However, it shouldn't actually be part of the API. So, leave it from - * the doxygen generated API documentation. - */ - explicit Reference( - DELEGATE_T* p) - : impl_(p) - { - } - - explicit Reference( - const DELEGATE_REF_T& p) - : impl_(p) - { - } - - /** @endcond */ - - /** - * Destroys a Reference. - * - * There might be an associated garbage collection activity when - * the current reference is not empty. When the underlaying delegate - * is referenced by another Reference object as well, then that - * delegate will not be destroyed. - */ - ~Reference() - { - } - - /** @cond - * Function possibly needed for delegate implementation, but not recommended - * for application usage: exclude from the API documentation for clarity. - * - * Returns an object to the underlying delegate. - */ - operator DELEGATE_REF_T() const - { - return impl_; - } - /** @endcond */ - - /** - * Compares two Reference objects and returns true if they are equal. - * - * Equality is based on the referential equality of the object being - * pointed. - * - * @param ref the other Reference object - * @return true when equal - */ - template - bool operator ==( - const R& ref) const - { - bool equal = false; - if (this->is_nil() && ref.is_nil()) - { - /* Both delegates are null. */ - equal = true; - } - else if (!this->is_nil() && !ref.is_nil()) - { - /* Check delegates. */ - equal = (this->delegate() == ref.delegate()); - } - return equal; - } - - /** - * Compares two Reference objects and returns true if they are not - * equal. - * - * Inequality is based on the referential inequality of the object - * being pointed to. - * - * @param ref the other Reference object - * @return true when not equal - */ - template - bool operator !=( - const R& ref) const - { - // FRANAVA read something removing the this keyword. - return !(*this == ref); - } - - /** - * Assign new referenced object to this dds reference. - * - * There might be an associated garbage collection activity when - * the current reference is not empty. - * - * @return reference pointing to the new object. - */ - template - Reference& operator =( - const Reference& that) - { - //To implement - static_assert((is_base_of::value), "value error"); - if (this != (Reference*)&that) - { - *this = Reference(that); - } - return *this; - - } - - /** @copydoc dds::core::Reference::operator=(const Reference& that) */ - template - Reference& operator =( - const R& rhs) - { - static_assert( - is_base_of< DELEGATE_T, typename R::DELEGATE_T>::value, - "location: operator=()" ); - if (this != (Reference*)&rhs) - { - *this = Reference(rhs); - } - return *this; - - } - - /** - * Special assignment operators that takes care of assigning - * dds::core::null to this reference. - * - * When assigning null, there might be an associated garbage collection - * activity. - * - * @return reference pointing to a null object. - */ - - Reference& operator =( - const null_type nil) - { - this = nil; - return this; - } - - /** - * Check if the referenced object is nil. - * - * In other words, check if the reference is pointing to a null object. - * - * @return true if the referenced object is null. - */ - bool is_nil() const - { - return impl_.get() == 0; - } - - /** - * Special operator== used to check if this reference object - * equals the dds::core::null reference. - * - * The null-check can be done like this: - * @code{.cpp} - * if (r == dds::core::null) { - * // Do not use the dds reference object r in its current state - * } - * @endcode - * - * @return true if this reference is null. - */ - bool operator ==( - const null_type) const - { - return this->is_nil(); - } - - /** - * Special operator!= used to check if this reference object - * does not equal the dds::core::null reference. - * - * The non-null-check can be done like this: - * @code{.cpp} - * if (r != dds::core::null) { - * // Use the dds reference object r - * } - * @endcode - * - * @return true if this reference is not null. - */ - bool operator !=( - const null_type) const - { - return !(this->is_nil()); - } - -private: - - // -- disallow dynamic allocation for reference types - void* operator new( - size_t); - -public: - - /** @cond - * Functions possibly needed for delegate implementation, but not recommended - * for application usage: exclude from the API documentation for clarity. - * - * Returns an object to the underlying delegate. - */ - DELEGATE_REF_T& delegate() - { - return impl_; - } - - const DELEGATE_REF_T& delegate() const - { - return impl_; - } - - /** @endcond */ - - /** - * The operator->() is provided to be able to directly invoke - * functions on the delegate. - * - * The decision to provide direct access to - * the delegate was motivated by the need for providing a way that - * was not invasive with respect to the CXXDDS API and yet would allow - * for vendor-specific extension. - * Thus vendor-specific extensions can be invoked on the Reference - * and on all its subclasses as follows: - * @code{.cpp} - * my_dds_entity.standard_function(); - * my_dds_entity->vendor_specific_extension(); - * @endcode - * - * @return a reference to delegate. - */ - DELEGATE* operator ->() - { - return impl_.get(); - - } - - /** @copydoc dds::core::Reference::operator->() */ - const DELEGATE* operator ->() const - { - return impl_.get(); - } - - /** @cond - * Functions possibly needed for delegate implementation, but not recommended - * for application usage: exclude from the API documentation for clarity. - * - * Returns an object to the underlying delegate. - */ - operator DELEGATE_REF_T& () - { - return impl_; - } - - operator const DELEGATE_REF_T& () const - { - return impl_; - } - /** @endcond */ - -protected: - - Reference() - { - } - - void set_ref( - DELEGATE_T* p) - { - impl_.reset(p); - } - -protected: - - DELEGATE_REF_T impl_; -}; - - -} //namespace core -} //namespace dds - - -/** - * Special operator== used to check if this reference object - * does not equal the dds::core::null reference. - * - * The non-null-check can be done like this: - * @code{.cpp} - * if (dds::core::null == r) { - * // Do not use the dds reference object r in its current state - * } - * @endcode - * - * @return true if this reference is not null. - */ -template -bool operator ==( - dds::core::null_type, - const dds::core::Reference& r) -{ - return r.is_nil(); -} - -/** - * Special operator!= used to check if this reference object - * does not equal the dds::core::null reference. - * - * The non-null-check can be done like this: - * @code{.cpp} - * if (dds::core::null != r) { - * // Use the dds reference object r - * } - * @endcode - * - * @return true if this reference is not null. - */ -template -bool operator !=( - dds::core::null_type, - const dds::core::Reference& r) -{ - return !r.is_nil(); -} - -#endif // OMG_DDS_CORE_REFERENCE_HPP_ diff --git a/include/dds/core/SafeEnumeration.hpp b/include/dds/core/SafeEnumeration.hpp deleted file mode 100644 index 8dc6720dcb8..00000000000 --- a/include/dds/core/SafeEnumeration.hpp +++ /dev/null @@ -1,97 +0,0 @@ -/* - * Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_CORE_SAFEENUMERATION_HPP_ -#define OMG_DDS_CORE_SAFEENUMERATION_HPP_ - -namespace dds { -namespace core { - -/** - * SafeEnum provides a wrapper for enumerated types in a typesafe - * manner. - * - * SafeEnums allow specification of the underlying type, - * do not implictly convert to integers, and resolve scoping issues. - */ -template< - typename Def, - typename Inner = typename Def::Type> -class SafeEnum : public Def -{ -public: - - constexpr SafeEnum( - Inner v) - : val(v) - { - } - - Inner underlying() const - { - return val; - } - - bool operator ==( - const SafeEnum& s) const - { - return this->val == s.val; - } - - bool operator !=( - const SafeEnum& s) const - { - return this->val != s.val; - } - - bool operator <( - const SafeEnum& s) const - { - return this->val < s.val; - } - - bool operator <=( - const SafeEnum& s) const - { - return this->val <= s.val; - } - - bool operator >( - const SafeEnum& s) const - { - return this->val > s.val; - } - - bool operator >=( - const SafeEnum& s) const - { - return this->val >= s.val; - } - -private: - - Inner val; - -}; - -} //namespace core -} //namespace dds - -#endif //OMG_DDS_CORE_SAFEENUMERATION_HPP_ - diff --git a/include/dds/core/Time.hpp b/include/dds/core/Time.hpp deleted file mode 100644 index ba4f3439662..00000000000 --- a/include/dds/core/Time.hpp +++ /dev/null @@ -1,234 +0,0 @@ -/* - * Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * All rights reserved. - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_CORE_TIME_HPP_ -#define OMG_DDS_CORE_TIME_HPP_ - -#include - -namespace dds { -namespace core { - -class Duration; -class Time; - -/** - * Time represents a time value and can: - * - * * Be incremented by Duration expressed as seconds, - * nanoseconds, milliseconds, or Duration objects. - * - * * Be converted to and from Times expressed in - * milliseconds (or other units) as integer types. - */ -class OMG_DDS_API Time -{ -public: - - static const Time invalid(); // {-1, 0xffffffff} - - /** - * Create a Time from a number of microseconds - * - * @param microseconds number of microseconds - */ - static const Time from_microsecs( - int64_t microseconds); - - /** - * Create a Time from a number of milliseconds - * - * @param milliseconds number of miliseconds - */ - static const Time from_millisecs( - int64_t milliseconds); - - /** - * Create a Time from a number of seconds - * - * @param seconds number of seconds - */ - static const Time from_secs( - double seconds); - - /** - * Create a Time of zero seconds. - */ - Time(); - - /** - * Create a Time elapsing a specific amount of time. - */ - explicit Time( - int64_t sec, - uint32_t nanosec = 0); - - /** - * @return number of seconds - */ - int64_t sec() const; - - /** - * Set number of seconds - * @param s number of seconds - */ - void sec( - int64_t s); - - /** - * @return number of nanoseconds - */ - uint32_t nanosec() const; - - /** - * Set number of nanoseconds - * @param ns number of nanoseconds - */ - void nanosec( - uint32_t ns); - - /** - * Returns an integer indicating the result of a comparison - * of two Times: - * 1 if this Time is greater than the comparator (that) - * -1 if the Time is less than the comparator (that) - * 0 if the Time matches the comparator (that) - * - * @param that Time to compare - * @return comparison result - */ - int compare( - const Time& that) const; - - /** - * @param that Time to compare - * @return true if the Time is greater than the comparator - */ - bool operator >( - const Time& that) const; - - /** - * @param that Time to compare - * @return true if the Time is greater than or equal to the comparator - */ - bool operator >=( - const Time& that) const; - - /** - * @param that Time to compare - * @return true if the Time is not equal to the comparator - */ - bool operator !=( - const Time& that) const; - - /** - * @param that Time to compare - * @return true if the Time is equal to the comparator - */ - bool operator ==( - const Time& that) const; - /** - * @param that Time to compare - * @return true if the Time is less than or equal to the comparator - */ - bool operator <=( - const Time& that) const; - /** - * @param that Time to compare - * @return true if the Time is less than the comparator - */ - bool operator <( - const Time& that) const; - - /** - * @param a_ti Duration to add - * @return Time value + Duration - */ - Time& operator +=( - const Duration& a_ti); - /** - * @param a_ti Duration to subtract - * @return Time value - Duration - */ - Time& operator -=( - const Duration& a_ti); - - /** - * Returns this Time in milliseconds. - * - * @return this Time in milliseconds - */ - int64_t to_millisecs() const; - - /** - * Returns this Time in micro-seconds. - * - * @return this Time in micro-seconds - */ - int64_t to_microsecs() const; - - /** - * Returns this Time in seconds. - * - * @return this Time in seconds - */ - double to_secs() const; - -private: - - int64_t sec_ = 0; - uint32_t nsec_ = 0; -}; - -// Time arithmetic operators. -/** - * Add a Duration to a Time value - * @param lhs Time - * @param rhs Duration - * @return Time * Duration - */ -const Time OMG_DDS_API operator +( - const Time& lhs, - const Duration& rhs); - -/** - * Add a Duration to a Time value - * @param lhs Duration - * @param rhs Time - * @return Duration + Time - */ -const Time OMG_DDS_API operator +( - const Duration& lhs, - const Time& rhs); - -/** - * Subtract a Duration from a Time value - * @param lhs Time - * @param rhs Duration - * @return Time - Duration - */ -const Time OMG_DDS_API operator -( - const Time& lhs, - const Duration& rhs); - -} //namespace core -} //namespace dds - -#endif //OMG_DDS_CORE_TIME_HPP_ diff --git a/include/dds/core/Value.hpp b/include/dds/core/Value.hpp deleted file mode 100644 index 30aa7e42892..00000000000 --- a/include/dds/core/Value.hpp +++ /dev/null @@ -1,238 +0,0 @@ -/* - * Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * All rights reserved. - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_CORE_VALUE_HPP_ -#define OMG_DDS_CORE_VALUE_HPP_ - -namespace dds { -namespace core { - -/** - * @brief - * This class is the base for various value-type dds objects. - * - * QoS, Policy, Statuses, and Topic samples are all modeled as value-types. - * - * All objects that have a value-type have a deep-copy assignment and copy - * construction semantics. - * It should also be pointed out that value-types are not 'pure-value-types' in - * the sense that they are immutable (as in functional programming languages). - * - * The DDS-PSM-Cxx makes value-types mutable to limit the number of copies as well - * as to limit the time-overhead necessary to change a value-type - * (note that for immutable value-types the only form of change is to create a new - * value-type). - */ -template -class Value -{ -protected: - - Value(); - Value( - const Value& p); - -public: - - /** @cond - * The following Constructors are not really relevant for the API. - * So, leave them from the doxygen generated API documentation for clarity. - */ - - /** - * Create a value-type object of one internal value - * - * @param arg VALUETYPE value - */ - template - Value( - const ARG& arg); - - /** - * Create a value-type object of two internal value - * - * @param arg1 VALUETYPES value - * @param arg2 VALUETYPES value - */ - template< - typename ARG1, - typename ARG2> - Value( - const ARG1& arg1, - const ARG2& arg2); - - /** - * Create a value-type object of three internal value - * - * @param arg1 VALUETYPES value - * @param arg2 VALUETYPES value - * @param arg3 VALUETYPES value - */ - template< - typename ARG1, - typename ARG2, - typename ARG3> - Value( - const ARG1& arg1, - const ARG2& arg2, - const ARG3& arg3); - - /** - * Create a value-type object of four internal value - * - * @param arg1 VALUETYPES value - * @param arg2 VALUETYPES value - * @param arg3 VALUETYPES value - * @param arg4 VALUETYPES value - */ - template< - typename ARG1, - typename ARG2, - typename ARG3, - typename ARG4> - Value( - const ARG1& arg1, - const ARG2& arg2, - const ARG3& arg3, - const ARG4& arg4); - - /** - * Create a value-type object of five internal value - * - * @param arg1 VALUETYPES value - * @param arg2 VALUETYPES value - * @param arg3 VALUETYPES value - * @param arg4 VALUETYPES value - * @param arg5 VALUETYPES value - */ - template< - typename ARG1, - typename ARG2, - typename ARG3, - typename ARG4, - typename ARG5> - Value( - const ARG1& arg1, - const ARG2& arg2, - const ARG3& arg3, - const ARG4& arg4, - const ARG5& arg5); - - /** - * Create a value-type object of six internal value - * - * @param arg1 VALUETYPES value - * @param arg2 VALUETYPES value - * @param arg3 VALUETYPES value - * @param arg4 VALUETYPES value - * @param arg5 VALUETYPES value - * @param arg6 VALUETYPES value - */ - template< - typename ARG1, - typename ARG2, - typename ARG3, - typename ARG4, - typename ARG5, - typename ARG6> - Value( - const ARG1& arg1, - const ARG2& arg2, - const ARG3& arg3, - const ARG4& arg4, - const ARG5& arg5, - const ARG6& arg6); - /** @endcond */ - - /** @cond */ - ~Value(); - /** @endcond */ - - /** - * Assigns new delegate to this Value - * @param other Value - */ - Value& operator =( - const Value& other); - - /** - * Compare this Value with another Value - * - * @param other Value - * @return true if equal - */ - bool operator ==( - const Value& other) const; - - /** - * Compare this Value with another Value - * - * @param other Value - * @return true if not equal - */ - bool operator !=( - const Value& other) const; - - /** - * The operator->() is provided to be able to directly invoke - * functions on the delegate. - * - * The decision to provide direct access to - * the delegate was motivated by the need for providing a way that - * was not invasive with respect to the CXXDDS API and yet would allow - * for vendor-specific extension. - * Thus vendor-specific extensions can be invoked on the Value - * and on all its subclasses as follows: - * @code{.cpp} - * my_dds_value.standard_function(); - * my_dds_value->vendor_specific_extension(); - * @endcode - * - * @return a reference to delegate. - */ - D* operator ->(); - - /** @copydoc dds::core::Value::operator->() */ - const D* operator ->() const; - - /** @cond - * Functions possibly needed for delegate implementation, but not recommended - * for application usage: exclude from the API documentation for clarity. - * - * Returns an object to the underlying delegate. - */ - const D& delegate() const; - - D& delegate(); - - operator D& (); - - operator const D& () const; - /** @endcond */ - -protected: - - D d_; -}; - -} //namespace core -} //namespace dds - -#endif //OMG_DDS_CORE_VALUE_HPP_ diff --git a/include/dds/core/WeakReference.hpp b/include/dds/core/WeakReference.hpp deleted file mode 100644 index ffbc4c3e485..00000000000 --- a/include/dds/core/WeakReference.hpp +++ /dev/null @@ -1,87 +0,0 @@ -/* - * Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * All rights reserved. - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_CORE_WEAK_REFERENCE_HPP_ -#define OMG_DDS_CORE_WEAK_REFERENCE_HPP_ - -#include - -namespace dds { -namespace core { - -/** - * @brief - * The WeakReference class enables you to maintain a weak - * reference to a DDS reference type. - * - * The existence of a weak link will not prevent the garbage - * collection of the reference type. - */ -template -class WeakReference -{ -public: - - typedef T ReferenceType; - -public: - - /** - * Creates a weak reference without an referenced dds object. - */ - WeakReference(); - - /** - * Creates a weak reference for the reference type passed as argument. - * - * @tparam t dds object the new weak reference will refer to - */ - WeakReference( - const T& t); - - /** @cond */ - ~WeakReference(); - /** @endcond */ - - /** - * Checks whether the underlying reference has been deleted. - * - * @returns true if the underlying reference has expired, false otherwise - */ - bool expired(); - - /** - * Gives access to the underlying shared reference. - * - * If the reference has expired the returned object will be referencing 'dds::core::null'. - * - * @return referenced dds object - */ - T lock(); - -private: - - typename T::DELEGATE_WEAK_REF_T impl_; -}; - -} //namespace core -} //namespace dds - -#endif //OMG_DDS_CORE_WEAK_REFERENCE_HPP_ diff --git a/include/dds/core/array.hpp b/include/dds/core/array.hpp deleted file mode 100644 index 96055173a54..00000000000 --- a/include/dds/core/array.hpp +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef ORG_OMG_DDS_CORE_ARRAY_HPP_ -#define ORG_OMG_DDS_CORE_ARRAY_HPP_ - -#include - -namespace dds { -namespace core { - -using dds::core::detail::array; - -} //namespace core -} //namespace dds - -#endif //ORG_OMG_DDS_CORE_ARRAY_HPP_ diff --git a/include/dds/core/cond/Condition.hpp b/include/dds/core/cond/Condition.hpp deleted file mode 100644 index 54466aff8c9..00000000000 --- a/include/dds/core/cond/Condition.hpp +++ /dev/null @@ -1,148 +0,0 @@ -/* - * Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * All rights reserved. - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_CORE_COND_CONDITION_HPP_ -#define OMG_DDS_CORE_COND_CONDITION_HPP_ - -#include - -#include -#include -#include -//#include -//#include - -namespace dds { -namespace core { -namespace cond { - -/** - * @brief - * This class is the base class for all the conditions that may be attached to a dds::core::cond::WaitSet. - * - * This base class is specialized in three classes by the Data Distribution Service: - * - dds::core::cond::GuardCondition - * - dds::core::cond::StatusCondition - * - dds::sub::cond::ReadCondition - * - dds::sub::cond::QueryCondition - * - * Each Condition has a trigger_value that can be TRUE or FALSE and is set by - * the Data Distribution Service (except a GuardCondition) depending on the - * evaluation of the Condition. - * - * @see @ref DCPS_Modules_Infrastructure_Status "Status concept" - * @see @ref DCPS_Modules_Infrastructure_Waitset "WaitSet concept" - */ -template -class TCondition : public virtual Reference -{ -public: - - OMG_DDS_REF_TYPE_PROTECTED_DC( - TCondition, - dds::core::Reference, - DELEGATE) - - OMG_DDS_EXPLICIT_REF_BASE_DECL( - TCondition, - detail::StatusCondition) - - OMG_DDS_EXPLICIT_REF_BASE_DECL( - TCondition, - detail::GuardCondition) - - OMG_DDS_EXPLICIT_REF_BASE_DECL( - TCondition, - dds::sub::cond::detail::ReadCondition) - - OMG_DDS_EXPLICIT_REF_BASE_DECL( - TCondition, - dds::sub::cond::detail::QueryCondition) - - /** @cond */ - OMG_DDS_API ~TCondition(); - /** @endcond */ - - /** - * Registers a functor as custom handler with this Condition. - * - * The supplied functor will be called when this Condition is triggered - * and either the dds::core::cond::Condition::dispatch() is called or the - * dds::core::cond::WaitSet::dispatch() on the WaitSet to which this - * Condition is attached to. - * - * @tparam Functor The functor to be called when the StatusCondition triggers. - * @return void - * @throw dds::core::Exception - */ - template - OMG_DDS_API void handler( - Functor& func); - - /** @copydoc dds::core::cond::TCondition::handler(Functor& func) */ - template - OMG_DDS_API void handler( - const Functor& func); - - /** - * Resets the handler for this Condition. - * - * After the invocation of this function no handler will be registered with - * this Condition. - * - * @return void - * @throw dds::core::Exception - */ - OMG_DDS_API void reset_handler(); - - /** - * Dispatches the functor that have been registered with the Condition. - * - * The Condition has to have been triggered for the functor will be called - * by this function. - * - * @return void - * @throw dds::core::Exception - */ - OMG_DDS_API void dispatch(); - - /** - * This operation retrieves the trigger_value of the Condition. - * - * A Condition has a trigger_value that can be TRUE or FALSE and is set by the - * Data Distribution Service (except a GuardCondition). This operation returns the - * trigger_value of the Condition. - * - * @return bool The boolean value to which the Condition is set. - * @throw dds::core::Exception - */ - OMG_DDS_API bool trigger_value() const; - -}; - -typedef TCondition Condition; - -} //namespace cond -} //namespace core -} //namespace dds - -#include - -#endif //OMG_DDS_CORE_COND_CONDITION_HPP_ diff --git a/include/dds/core/cond/GuardCondition.hpp b/include/dds/core/cond/GuardCondition.hpp deleted file mode 100644 index e011040b64b..00000000000 --- a/include/dds/core/cond/GuardCondition.hpp +++ /dev/null @@ -1,142 +0,0 @@ -/* - * Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * All rights reserved. - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_CORE_COND_GUARDCONDITION_HPP_ -#define OMG_DDS_CORE_COND_GUARDCONDITION_HPP_ - -#include -#include - -namespace dds { -namespace core { -namespace cond { - -/** - * @brief - * A GuardCondition object is a specific Condition whose trigger_value is - * completely under the control of the application. - * - * When a GuardCondition is initially created, the trigger_value is FALSE. - * - * The purpose of the GuardCondition is to provide the means for the - * application to manually triggering a WaitSet to stop waiting. This is accomplished by - * attaching the GuardCondition to the WaitSet and then setting the - * trigger_value by means of the set trigger_value operation. - * - * @code{.cpp} - * dds::core::cond::GuardCondition guard; - * dds::core::cond::WaitSet waitset; - * waitset.attach_condition(guard); - * waitset.wait(); - * ... - * // To wakeup waitset, do in another thread: - * guard.trigger_value(true); - * @endcode - * See the @ref anchor_dds_core_cond_waitset_examples "WaitSet examples" for more examples.
    - * Although the WaitSet examples use the StatusCondition, the basic usage of this Condition - * with a WaitSet is the same. - * - * @see dds::core::cond::Condition - * @see @ref DCPS_Modules_Infrastructure_Waitset "WaitSet concept" - * @see @ref anchor_dds_core_cond_waitset_examples "WaitSet examples" - */ -template -class TGuardCondition : public TCondition -{ -public: - - OMG_DDS_REF_TYPE_NO_DC( - TGuardCondition, - TCondition, - DELEGATE) - - OMG_DDS_EXPLICIT_REF_BASE( - TGuardCondition, - dds::core::cond::Condition) - /** - * Create a dds::core::cond::GuardCondition. - * - * The GuardCondition can then be added to a dds::core::cond::WaitSet so that the - * application can manually wake up a thread that is blocked on that WaitSet. - * - * @throw dds::core::Exception - */ - TGuardCondition(); - - /** - * Create a dds::core::cond::GuardCondition. - * - * The GuardCondition can then be added to a dds::core::cond::WaitSet so that the - * application can manually wake up a thread that is blocked on that WaitSet. - * - * The supplied functor will be called when this GuardCondition is triggered - * and either the inherited dds::core::cond::Condition::dispatch() is called or the - * dds::core::cond::WaitSet::dispatch() on the WaitSet to which this GuardCondition is - * attached to. - * - * @tparam functor The functor to be called when the GuardCondition triggers. - * @throw dds::core::Exception - */ - template - TGuardCondition( - FUN& functor); - - /** - * @copydoc dds::core::cond::TGuardCondition::TGuardCondition(FUN& functor) - */ - template - TGuardCondition( - const FUN& functor); - - /** @cond */ - ~TGuardCondition(); - /** @endcond */ - - /** - * This operation sets the trigger_value of the GuardCondition. - * - * A GuardCondition object is a specific Condition which trigger_value is - * completely under the control of the application. This operation must be used by the - * application to manually wake-up a WaitSet. This operation sets the - * trigger_value of the GuardCondition to the parameter value. The - * GuardCondition is directly created using the GuardCondition constructor. - * When a GuardCondition is initially created, the trigger_value is FALSE. - * - * @param value The boolean value to which the GuardCondition is set. - * @throw dds::core::Exception - */ - void trigger_value( - bool value); - - /** - * @copydoc dds::core::cond::TCondition::trigger_value() - */ - bool trigger_value(); -}; - -typedef dds::core::cond::detail::GuardCondition GuardCondition; - -} //namespace cond -} //namespace core -} //namespace dds - -#include - -#endif //OMG_DDS_CORE_COND_GUARDCONDITION_HPP_ diff --git a/include/dds/core/cond/StatusCondition.hpp b/include/dds/core/cond/StatusCondition.hpp deleted file mode 100644 index 83829721137..00000000000 --- a/include/dds/core/cond/StatusCondition.hpp +++ /dev/null @@ -1,242 +0,0 @@ -/* - * Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * All rights reserved. - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_CORE_STATUSCONDITION_HPP_ -#define OMG_DDS_CORE_STATUSCONDITION_HPP_ - -#include -#include -#include - -namespace dds { -namespace core { -namespace cond { - -/** - * @brief - * A StatusCondition object is a specific Condition that is associated with each Entity. - * - * Entity objects that have status attributes also have a StatusCondition, access is - * provided to the application by the get_statuscondition operation. - * The communication statuses whose changes can be communicated to the application - * depend on the Entity. The following table shows the relevant statuses for each - * Entity. - * - * Entity | Status Name - * -------------------- | -------------------- - * dds::topic::Topic | dds::core::status::StatusMask::inconsistent_topic()
    dds::core::status::StatusMask::all_data_disposed_topic() - * dds::sub::Subscriber | dds::core::status::StatusMask::data_on_readers() - * dds::sub::DataReader | dds::core::status::StatusMask::sample_rejected()
    dds::core::status::StatusMask::liveliness_changed()
    dds::core::status::StatusMask::requested_deadline_missed()
    dds::core::status::StatusMask::requested_incompatible_qos()
    dds::core::status::StatusMask::data_available()
    dds::core::status::StatusMask::sample_lost()
    dds::core::status::StatusMask::subscription_matched() - * dds::pub::DataWriter | dds::core::status::StatusMask::liveliness_lost()
    dds::core::status::StatusMask::offered_deadline_missed()
    dds::core::status::StatusMask::offered_incompatible_qos()
    dds::core::status::StatusMask::publication_matched() - * - * The inherited dds::core::cond::Condition::trigger_value() of the StatusCondition - * depends on the communication statuses of that Entity (e.g., missed deadline) and - * also depends on the value of the dds::core::status::StatusMask. - * - * A StatusCondition can be attached to a WaitSet in order to allow an application - * to suspend until the trigger_value has become TRUE. - * - * The trigger_value of a StatusCondition will be TRUE if one of the enabled - * StatusChangedFlags is set. That is, trigger_value==FALSE only if all the - * values of the StatusChangedFlags are FALSE. - * - * The sensitivity of the StatusCondition to a particular communication status is - * controlled by the list of enabled_statuses set on the condition by means of - * dds::core::cond::StatusCondition::enabled_statuses(const ::dds::core::status::StatusMask& status) - * When the enabled_statuses are not changed by that - * operation, all statuses are enabled by default. - * - * See the @ref anchor_dds_core_cond_waitset_examples "WaitSet examples" for examples - * how to use this Condition. - * - * @see dds::core::cond::Condition - * @see @ref DCPS_Modules_Infrastructure_Status "Status concept" - * @see @ref DCPS_Modules_Infrastructure_Waitset "WaitSet concept" - * @see @ref anchor_dds_core_cond_waitset_examples "WaitSet examples" - */ -template -class TStatusCondition : public TCondition -{ -public: - - OMG_DDS_REF_TYPE_DELEGATE_C( - TStatusCondition, - TCondition, - DELEGATE) - - OMG_DDS_EXPLICIT_REF_BASE( - TStatusCondition, - dds::core::cond::Condition) - - /** - * Create a dds::core::cond::StatusCondition associated with an Entity. - * - * The StatusCondition can then be added to a dds::core::cond::WaitSet so that the - * application can wait for specific status changes that affect the Entity. - * - * @param e The Entity to associate with the StatusCondition. - * @throw dds::core::Exception - */ - TStatusCondition( - const dds::core::Entity& e); - - /** - * Create a dds::core::cond::StatusCondition associated with an Entity. - * - * The StatusCondition can then be added to a dds::core::cond::WaitSet so that the - * application can wait for specific status changes that affect the Entity. - * - * The supplied functor will be called when this StatusCondition is triggered - * and either the inherited dds::core::cond::Condition::dispatch() is called or the - * dds::core::cond::WaitSet::dispatch() on the WaitSet to which this StatusCondition is - * attached to. - * - * @param e The Entity to associate with the StatusCondition. - * @tparam functor The functor to be called when the StatusCondition triggers. - * @throw dds::core::Exception - */ - template - TStatusCondition( - const dds::core::Entity& e, - FUN& functor); - - /** @copydoc dds::core::cond::TStatusCondition::TStatusCondition(const dds::core::Entity& e, FUN& functor) */ - template - TStatusCondition( - const dds::core::Entity& e, - const FUN& functor); - - /** @cond */ - ~TStatusCondition(); - /** @endcond */ - - /** - * This operation sets the list of communication statuses that are taken into account to - * determine the trigger_value of the StatusCondition. - * - * The inherited dds::core::cond::Condition::trigger_value() of the StatusCondition - * depends on the communication status of that Entity (e.g., missed deadline, - * loss of information, etc.), ‘filtered’ by the set of enabled_statuses on the StatusCondition. - * - * This operation sets the list of communication statuses that are taken into account to - * determine the trigger_value of the StatusCondition. This operation may - * change the trigger_value of the StatusCondition. - * - * dds::core::cond::WaitSet objects behaviour depend on the changes of the trigger_value of - * their attached Conditions. Therefore, any WaitSet to which the StatusCondition - * is attached is potentially affected by this operation. - * If this function is not invoked, the default list of enabled_statuses includes all - * the statuses. - * - * The result value is a bit mask in which each bit shows which value has changed. The - * relevant bits represent one of the following statuses: - * - dds::core::status::StatusMask::inconsistent_topic() - * - dds::core::status::StatusMask::offered_deadline_missed() - * - dds::core::status::StatusMask::requested_deadline_missed() - * - dds::core::status::StatusMask::offered_incompatible_qos() - * - dds::core::status::StatusMask::requested_incompatible_qos() - * - dds::core::status::StatusMask::sample_lost() - * - dds::core::status::StatusMask::sample_rejected() - * - dds::core::status::StatusMask::data_on_readers() - * - dds::core::status::StatusMask::data_available() - * - dds::core::status::StatusMask::liveliness_lost() - * - dds::core::status::StatusMask::liveliness_changed() - * - dds::core::status::StatusMask::publication_matched() - * - dds::core::status::StatusMask::subscription_matched() - * - dds::core::status::StatusMask::all_data_disposed_topic() - * - * Each status bit is declared as a constant and can be used in an AND operation to - * check the status bit against the result of type StatusMask. Not all statuses are - * relevant to all Entity objects. See the respective Listener interfaces for each - * Entity for more information. - * - * @param status A bit mask in which each bit sets the status which is taken - * into account for the StatusCondition.the enabled statuses. - * @return void - * @throw dds::core::AlreadyClosedError - * @throw dds::core::Error - */ - void enabled_statuses( - const ::dds::core::status::StatusMask& status) const; - - /** - * This operation returns the list of enabled communication statuses of the - * StatusCondition. - * - * The inherited dds::core::cond::Condition::trigger_value() of the StatusCondition - * depends on the communication status of that Entity (e.g., missed deadline, - * loss of information, etc.), ‘filtered’ by the set of enabled_statuses on the StatusCondition. - * - * This operation returns the list of communication statuses that are taken into account - * to determine the trigger_value of the StatusCondition. This operation - * returns the statuses that were explicitly set on the last call to - * dds::core::cond::StatusCondition::enabled_statuses(const ::dds::core::status::StatusMask& status) const - * or, if enabled_statuses(status) was never called, the default list. - * - * The result value is a bit mask in which each bit shows which value has changed. The - * relevant bits represent one of the following statuses: - * - dds::core::status::StatusMask::inconsistent_topic() - * - dds::core::status::StatusMask::offered_deadline_missed() - * - dds::core::status::StatusMask::requested_deadline_missed() - * - dds::core::status::StatusMask::offered_incompatible_qos() - * - dds::core::status::StatusMask::requested_incompatible_qos() - * - dds::core::status::StatusMask::sample_lost() - * - dds::core::status::StatusMask::sample_rejected() - * - dds::core::status::StatusMask::data_on_readers() - * - dds::core::status::StatusMask::data_available() - * - dds::core::status::StatusMask::liveliness_lost() - * - dds::core::status::StatusMask::liveliness_changed() - * - dds::core::status::StatusMask::publication_matched() - * - dds::core::status::StatusMask::subscription_matched() - * - dds::core::status::StatusMask::all_data_disposed_topic() - * - * Each status bit is declared as a constant and can be used in an AND operation to - * check the status bit against the result of type StatusMask. Not all statuses are - * relevant to all Entity objects. See the respective Listener interfaces for each - * Entity for more information. - * - * @return dds::core::status::StatusMask - * A bit mask in which each bit shows which status is taken into - * account for the StatusCondition. - * @throw dds::core::Exception - */ - const ::dds::core::status::StatusMask enabled_statuses() const; - - /** - * This operation returns the Entity associated with the StatusCondition - * - * Note that there is exactly one Entity associated with each StatusCondition. - * - * @return dds::core::Entity The Entity associated with the StatusCondition. - * @throw dds::core::AlreadyClosedError - */ - const dds::core::Entity& entity() const; - -}; - -typedef detail::StatusCondition StatusCondition; - -} //namespace cond -} //namespace core -} //namespace dds - -#include - -#endif //OMG_DDS_CORE_STATUSCONDITION_HPP_ diff --git a/include/dds/core/cond/WaitSet.hpp b/include/dds/core/cond/WaitSet.hpp deleted file mode 100644 index 8550e0bb7da..00000000000 --- a/include/dds/core/cond/WaitSet.hpp +++ /dev/null @@ -1,427 +0,0 @@ -/* - * Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * All rights reserved. - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_CORE_WAITSET_HPP_ -#define OMG_DDS_CORE_WAITSET_HPP_ - -#include -#include -#include -#include - -namespace dds { -namespace core { -namespace cond { - -/** - * @brief - * A WaitSet object allows an application to wait until one or more of - * the attached Condition objects has a trigger_value of TRUE or else - * until the timeout expires. - * - * A WaitSet is not necessarily associated with a single DomainParticipant - * and could be used to wait for Condition objects associated with different - * DomainParticipant objects. - * - * @anchor anchor_dds_core_cond_waitset_examples - * Example with wait()
    - * When using the wait() operation, the triggered Conditions are returned in a list. - * @code{.cpp} - * // Create a Condition to attach to a Waitset - * dds::core::cond::StatusCondition readerSC = dds::core::cond::StatusCondition(reader); - * readerSC.enabled_statuses(dds::core::status::StatusMask::data_available()); - * - * // Create WaitSet and attach Condition - * dds::core::cond::WaitSet waitset; - * waitset.attach_condition(readerSC); // or waitset += readerSC; - * - * dds::core::cond::WaitSet::ConditionSeq conditions; - * while(true) { - * // Wait for any Condition to trigger. - * conditions = waitset.wait(); - * - * // Loop through the triggered conditions. - * for (int i=0; i < conditions.size(); i++) { - * // Handle data_available when right Condition triggered. - * if (conditions[i] == readerSC) { - * // Read samples from the DataReader - * } - * } - * } - * @endcode - - * Example with dispatch()
    - * When using the dispatch() operation, the Functors of the triggered Conditions - * will be called. - * @code{.cpp} - * // Functor to add to a Condition - * class FunctorStatusCondition { - * public: - * void operator()(const dds::core::cond::StatusCondition& condition) { - * // Possibly get reader from the condition and read some samples. - * } - * }; - * FunctorStatusCondition functor; - * - * // Create a Condition with functor to attach to a Waitset - * dds::core::cond::StatusCondition readerSC = dds::core::cond::StatusCondition(reader, functor); - * readerSC.enabled_statuses(dds::core::status::StatusMask::data_available()); - * - * // Create WaitSet and attach Condition - * dds::core::cond::WaitSet waitset; - * waitset.attach_condition(readerSC); // or waitset += readerSC; - * - * while(true) { - * // Wait for any Condition to trigger. - * // The functors of the Conditions are automatically called - * // when the Condition triggers. - * waitset.dispatch(); - * } - * @endcode - * - * @see @ref DCPS_Modules_Infrastructure_Waitset "WaitSet concept" - */ -template -class TWaitSet : public Reference -{ -public: - - typedef std::vector ConditionSeq; - -public: - - OMG_DDS_REF_TYPE_NO_DC( - TWaitSet, - Reference, - DELEGATE) - - OMG_DDS_IMPLICIT_REF_BASE( - TWaitSet) - - /** - * Create a WaitSet instance. - * - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - TWaitSet(); - - /** @cond */ - ~TWaitSet(); - /** @endcond */ - - /** - * This operation allows an application thread to wait for the occurrence - * of at least one of the conditions that is attached to the WaitSet. - * - * This operation allows an application thread to wait for the occurrence - * of certain Conditions. If none of the Conditions attached to the - * WaitSet have a trigger_value of TRUE, the wait operation will block - * suspending the calling thread. - * - * The wait operation takes a timeout argument that specifies the maximum - * duration for the wait. If this duration is exceeded and none of - * the attached Condition objects is true, a TimeoutError will be thrown. - * - * It is not allowed for more than one application thread to be waiting - * on the same WaitSet. If the wait operation is invoked on a WaitSet that - * already has a thread blocking on it, the operation will immediately - * raise a PreconditionNotMetError exception. - * - * The result of the wait operation is the list of all the attached - * Conditions that have a trigger_value of TRUE (i.e., the Conditions - * that unblocked the wait). - * - * @param timeout The maximum amount of time for which the wait - * should block while waiting for a Condition to be triggered. - * @return ConditionSeq - * A vector containing the triggered Conditions - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The WaitSet was not properly created and references to dds::core::null. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - * @throws dds::core::TimeoutError - * The timeout has elapsed without any of the attached - * conditions becoming TRUE. - * @throws dds::core::PreconditionNotMetError - * When multiple thread try to invoke the function concurrently. - */ - const ConditionSeq wait( - const dds::core::Duration& timeout); - - /** - * This operation allows an application thread to wait for the occurrence - * of at least one of the conditions that is attached to the WaitSet. - * - * This operation allows an application thread to wait for the occurrence - * of certain Conditions. If none of the Conditions attached to the - * WaitSet have a trigger_value of TRUE, the wait operation will block - * suspending the calling thread. - * - * It is not allowed for more than one application thread to be waiting - * on the same WaitSet. If the wait operation is invoked on a WaitSet that - * already has a thread blocking on it, the operation will immediately - * raise a PreconditionNotMetError exception. - * - * The result of the wait operation is the list of all the attached - * Conditions that have a trigger_value of TRUE (i.e., the Conditions - * that unblocked the wait). - * - * @return ConditionSeq - * A vector containing the triggered Conditions - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The WaitSet was not properly created and references to dds::core::null. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - * @throws dds::core::PreconditionNotMetError - * When multiple thread try to invoke the function concurrently. - */ - const ConditionSeq wait(); - - /** - * This operation allows an application thread to wait for the occurrence - * of at least one of the conditions that is attached to the WaitSet. - * - * This operation allows an application thread to wait for the occurrence - * of certain Conditions. If none of the Conditions attached to the - * WaitSet have a trigger_value of TRUE, the wait operation will block - * suspending the calling thread. - * - * The wait operation takes a timeout argument that specifies the maximum - * duration for the wait. If this duration is exceeded and none of - * the attached Condition objects is true, a TimeoutError will be thrown. - * - * It is not allowed for more than one application thread to be waiting - * on the same WaitSet. If the wait operation is invoked on a WaitSet that - * already has a thread blocking on it, the operation will immediately - * raise a PreconditionNotMetError exception. - * - * The result of the wait operation is the list of all the attached - * Conditions that have a trigger_value of TRUE (i.e., the Conditions - * that unblocked the wait). - * - * @param triggered A ConditionSeq in which to put Conditions that were - * triggered during the wait. - * @param timeout The maximum amount of time for which the wait should - * block while waiting for a Condition to be triggered. - * @return ConditionSeq - * A vector containing the triggered Conditions - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The WaitSet was not properly created and references to dds::core::null. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - * @throws dds::core::TimeoutError - * The timeout has elapsed without any of the attached - * conditions becoming TRUE. - * @throws dds::core::PreconditionNotMetError - * When multiple thread try to invoke the function concurrently. - */ - ConditionSeq& wait( - ConditionSeq& triggered, - const dds::core::Duration& timeout); - - /** - * This operation allows an application thread to wait for the occurrence - * of at least one of the conditions that is attached to the WaitSet. - * - * This operation allows an application thread to wait for the occurrence - * of certain Conditions. If none of the Conditions attached to the - * WaitSet have a trigger_value of TRUE, the wait operation will block - * suspending the calling thread. - * - * It is not allowed for more than one application thread to be waiting - * on the same WaitSet. If the wait operation is invoked on a WaitSet that - * already has a thread blocking on it, the operation will immediately - * raise a PreconditionNotMetError exception. - * - * The result of the wait operation is the list of all the attached - * Conditions that have a trigger_value of TRUE (i.e., the Conditions - * that unblocked the wait). - * - * @param triggered A ConditionSeq in which to put Conditions that were - * triggered during the wait. - * @return ConditionSeq - * A vector containing the triggered Conditions - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The WaitSet was not properly created and references to dds::core::null. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - * @throws dds::core::PreconditionNotMetError - * When multiple thread try to invoke the function concurrently. - */ - ConditionSeq& wait( - ConditionSeq& triggered); - - /** - * Waits for at least one of the attached Conditions to trigger and then - * dispatches the functor associated with the Condition. - * - * @return void - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The WaitSet was not properly created and references to dds::core::null. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - * @throws dds::core::PreconditionNotMetError - * When multiple thread try to invoke the function concurrently. - */ - void dispatch(); - - /** - * Waits for at least one of the attached Conditions to trigger and then - * dispatches the functor associated with the Condition, or, times - * out and throws a TimeoutError. - * - * @param timeout The maximum amount of time for which the dispatch should - * block while waiting for a Condition to be triggered. - * @return void - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The WaitSet was not properly created and references to dds::core::null. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - * @throws dds::core::TimeoutError - * The timeout has elapsed without any of the attached - * conditions becoming TRUE. - * @throws dds::core::PreconditionNotMetError - * When multiple thread try to invoke the function concurrently. - */ - void dispatch( - const dds::core::Duration& timeout); - - /** @copydoc dds::core::cond::TWaitSet::attach_condition(const dds::core::cond::Condition& cond) */ - TWaitSet& operator +=( - const Condition& cond); - - /** @copydoc dds::core::cond::TWaitSet::detach_condition(const dds::core::cond::Condition& cond) */ - TWaitSet& operator -=( - const Condition& cond); - - /** - * This operation attaches a Condition to the WaitSet. - * - * Attaches a Condition to the WaitSet. It is possible to attach a - * Condition on a WaitSet that is currently being waited upon - * (via the wait operation). In this case, if the Condition has a - * trigger_value of TRUE, then attaching the Condition will unblock - * the WaitSet. Adding a Condition that is already attached to the WaitSet - * has no effect. - * - * @param cond The Condition to be attached to this WaitSet. - * @return WaitSet The WaitSet itself so that attaching Conditions - * can be chained. - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The WaitSet was not properly created and references to dds::core::null. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - TWaitSet& attach_condition( - const Condition& cond); - - /** - * This operation detaches a Condition to the WaitSet. - * - * Detaches a Condition from the WaitSet. If the Condition was not - * attached to the WaitSet, the operation will return false. - * - * @param cond The Condition to detach from this WaitSet - * @return bool True if the Condition was found and detached, False - * if the Condition was not part of the WaitSet. - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The WaitSet was not properly created and references to dds::core::null. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - bool detach_condition( - const Condition& cond); - - /** - * This operation retrieves the list of attached Conditions. - * - * The resulting sequence will either be an empty sequence, meaning there were - * no conditions attached, or will contain a list of ReadCondition, - * QueryCondition, StatusCondition and GuardCondition. - * - * @return ConditionSeq - * The list of attached Conditions. - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The WaitSet was not properly created and references to dds::core::null. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - const ConditionSeq conditions() const; - - /** - * This operation retrieves the list of attached Conditions. - * - * The resulting sequence will either be an empty sequence, meaning there were - * no conditions attached, or will contain a list of ReadCondition, - * QueryCondition, StatusCondition and GuardCondition. - * - * @param conds A ConditionSeq in which to put the attached Conditions. - * @return ConditionSeq - * The list of attached Conditions. - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The WaitSet was not properly created and references to dds::core::null. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - ConditionSeq& conditions( - ConditionSeq& conds) const; -}; - -typedef dds::core::cond::detail::WaitSet WaitSet; - -} //namespace cond -} //namespace core -} //namespace dds - -#endif //OMG_DDS_CORE_DETAIL_WAITSET_HPP_ diff --git a/include/dds/core/cond/detail/Condition.hpp b/include/dds/core/cond/detail/Condition.hpp deleted file mode 100644 index 2762d81a5ab..00000000000 --- a/include/dds/core/cond/detail/Condition.hpp +++ /dev/null @@ -1,45 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_CORE_COND_DETAIL_CONDITION_HPP_ -#define EPROSIMA_DDS_CORE_COND_DETAIL_CONDITION_HPP_ - -/** - * @cond - * Ignore this file in the API - */ - -//#include - -namespace dds { -namespace core { -namespace cond { -namespace detail { - -//using Condition = eprosima::fastdds::dds::Condition; -class Condition -{ -}; - -} //namespace detail -} //namespace cond -} //namespace core -} //namespace dds - -/** @endcond */ - -#endif //EPROISMA_DDS_CORE_COND_DETAIL_CONDITION_HPP_ diff --git a/include/dds/core/cond/detail/ConditionImpl.hpp b/include/dds/core/cond/detail/ConditionImpl.hpp deleted file mode 100644 index 42f2b1b4a98..00000000000 --- a/include/dds/core/cond/detail/ConditionImpl.hpp +++ /dev/null @@ -1,92 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_CORE_COND_TCONDITION_IMPL_HPP_ -#define EPROSIMA_DDS_CORE_COND_TCONDITION_IMPL_HPP_ - -/** - * @file - */ - -/* - * OMG PSM class declaration - */ -#include -#include - -namespace dds { -namespace core { -namespace cond { - -template -TCondition::~TCondition() -{ -} - -/** @cond - * Somehow, these cause functions duplicates in doxygen documentation. - */ -template -template -void TCondition::handler( - Functor& func) -{ - //To implement - // ISOCPP_REPORT_STACK_DDS_BEGIN(*this); - // this->delegate()->set_handler(func); - -} - -template -template -void TCondition::handler( - const Functor& func) -{ - //To implement - // ISOCPP_REPORT_STACK_DDS_BEGIN(*this); - // this->delegate()->set_handler(func); -} - -/** @endcond */ - -template -void TCondition::reset_handler() -{ - //To implement - // ISOCPP_REPORT_STACK_DDS_BEGIN(*this); - // this->delegate()->reset_handler(); -} - -template -void TCondition::dispatch() -{ - //To implement - // ISOCPP_REPORT_STACK_DDS_BEGIN(*this); - // this->delegate()->dispatch(); -} - -template -bool TCondition::trigger_value() const -{ - // return this->delegate()->get_trigger_value(); -} - -} //namespace cond -} //namespace core -} //namespace dds - -#endif //EPROSIMA_DDS_CORE_COND_TCONDITION_IMPL_HPP_ diff --git a/include/dds/core/cond/detail/GuardCondition.hpp b/include/dds/core/cond/detail/GuardCondition.hpp deleted file mode 100644 index c698f86fadc..00000000000 --- a/include/dds/core/cond/detail/GuardCondition.hpp +++ /dev/null @@ -1,50 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_CORE_COND_DETAIL_GUARDCONDITION_HPP_ -#define EPROSIMA_DDS_CORE_COND_DETAIL_GUARDCONDITION_HPP_ - -/** - * @cond - * Ignore this file in the API - */ - -//#include - -namespace dds { -namespace core { -namespace cond { - -template -class TGuardCondition; - -namespace detail { - -//using GuardCondition = eprosima::fastdds::dds::GuardCondition; -class GuardCondition -{ -}; - -} //namespace detail -} //namespace cond -} //namespace core -} //namespace dds - - -/** @endcond */ - -#endif //EPROSIMA_DDS_CORE_COND_DETAIL_GUARDCONDITION_HPP_ diff --git a/include/dds/core/cond/detail/GuardConditionImpl.hpp b/include/dds/core/cond/detail/GuardConditionImpl.hpp deleted file mode 100644 index 4952d8a4095..00000000000 --- a/include/dds/core/cond/detail/GuardConditionImpl.hpp +++ /dev/null @@ -1,130 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_CORE_COND_TGUARDCONDITION_IMPL_HPP_ -#define EPROSIMA_DDS_CORE_COND_TGUARDCONDITION_IMPL_HPP_ - -/** - * @file - */ - -/* - * OMG PSM class declaration - */ -#include - -namespace dds { -namespace core { -namespace cond { - -template -TGuardCondition::TGuardCondition() -{ -} - -/** @cond - * Somehow, these cause functions duplicates in doxygen documentation. - */ -template -template -TGuardCondition::TGuardCondition( - FUN& functor) -{ - //To implement - // ISOCPP_REPORT_STACK_NC_BEGIN(); - // this->set_ref(new DELEGATE); - // this->delegate()->init(this->impl_); - // this->delegate()->set_handler(functor); -} - -template -template -TGuardCondition::TGuardCondition( - const FUN& functor) -{ - //To implement - // ISOCPP_REPORT_STACK_NC_BEGIN(); - // this->set_ref(new DELEGATE); - // this->delegate()->init(this->impl_); - // this->delegate()->set_handler(functor); -} - -/** @endcond */ - -template -TGuardCondition::~TGuardCondition() -{ -} - -template -void TGuardCondition::trigger_value( - bool /*value*/) -{ - // this->delegate()->set_trigger_value(value); -} - -template -bool TGuardCondition::trigger_value() -{ - return TCondition::trigger_value(); -} - -template -TCondition::TCondition( - /*const dds::core::cond::TGuardCondition& h*/) -{ - //To implement - // ISOCPP_REPORT_STACK_NC_BEGIN(); - // if (h.is_nil()) { - // /* We got a null object and are not really able to do a typecheck here. */ - // /* So, just set a null object. */ - // *this = dds::core::null; - // } else { - // this->::dds::core::Reference::impl_ = OSPL_CXX11_STD_MODULE::dynamic_pointer_cast(h.delegate()); - // if (h.delegate() != this->::dds::core::Reference::impl_) { - // throw dds::core::IllegalOperationError(std::string("Attempted invalid cast: ") + typeid(h).name() + " to " + typeid(*this).name()); - // } - // } -} - -template -TCondition& TCondition::operator =( - /*const dds::core::cond::TGuardCondition& rhs*/) -{ - //To implement - // ISOCPP_REPORT_STACK_NC_BEGIN(); - // if (this != (TCondition*)&rhs) { - // if (rhs.is_nil()) { - // /* We got a null object and are not really able to do a typecheck here. */ - // /* So, just set a null object. */ - // *this = dds::core::null; - // } else { - // TCondition other(rhs); - // /* Dont have to copy when the delegate is the same. */ - // if (other.delegate() != this->::dds::core::Reference::impl_) { - // *this = other; - // } - // } - // } - // return *this; -} - -} //namespace cond -} //namespace core -} //namespace dds - -#endif //EPROSIMA_DDS_CORE_COND_TGUARDCONDITION_IMPL_HPP_ diff --git a/include/dds/core/cond/detail/StatusCondition.hpp b/include/dds/core/cond/detail/StatusCondition.hpp deleted file mode 100644 index ef4fd1da47b..00000000000 --- a/include/dds/core/cond/detail/StatusCondition.hpp +++ /dev/null @@ -1,49 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_CORE_COND_DETAIL_STATUSCONDITION_HPP_ -#define EPROSIMA_DDS_CORE_COND_DETAIL_STATUSCONDITION_HPP_ - -/** - * @cond - * Ignore this file in the API - */ - -//#include - -namespace dds { -namespace core { -namespace cond { - -template -class TStatusCondition; - -namespace detail { - -//using StatusCondition = eprosima::fastdds::dds::StatusCondition; -class StatusCondition -{ -}; - -} //namespace detail -} //namespace cond -} //namespace core -} //namespace dds - -/** @endcond */ - -#endif //EPROSIMA_DDS_CORE_COND_DETAIL_STATUSCONDITION_HPP_ diff --git a/include/dds/core/cond/detail/StatusConditionImpl.hpp b/include/dds/core/cond/detail/StatusConditionImpl.hpp deleted file mode 100644 index 91824c86429..00000000000 --- a/include/dds/core/cond/detail/StatusConditionImpl.hpp +++ /dev/null @@ -1,132 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_CORE_COND_TSTATUSCONDITION_IMPL_HPP_ -#define EPROSIMA_DDS_CORE_COND_TSTATUSCONDITION_IMPL_HPP_ - -/** - * @file - */ - -/* - * OMG PSM class declaration - */ -#include - -namespace dds { -namespace core { -namespace cond { - -template -TStatusCondition::TStatusCondition( - const dds::core::Entity& /*e*/) -// : ::dds::core::cond::TCondition(new detail::StatusCondition(e)) -{ -} - -/** @cond - * Somehow, these cause functions duplicates in doxygen documentation. - */ -template -template -TStatusCondition::TStatusCondition( - const dds::core::Entity& /*e*/, - FUN& /*functor*/) -// : ::dds::core::cond::TCondition(new detail::StatusCondition(e, functor)) -{ -} - -template -template -TStatusCondition::TStatusCondition( - const dds::core::Entity& /*e*/, - const FUN& /*functor*/) -// : ::dds::core::cond::TCondition(new detail::StatusCondition(e, functor)) -{ -} - -/** @endcond */ - -template -TStatusCondition::~TStatusCondition() -{ -} - -template -void TStatusCondition::enabled_statuses( - const dds::core::status::StatusMask& /*status*/) const -{ - // this->delegate()->set_enabled_statuses(status); -} - -template -const dds::core::status::StatusMask TStatusCondition::enabled_statuses() const -{ - // return this->delegate()->get_enabled_statuses(); -} - -template -const dds::core::Entity& TStatusCondition::entity() const -{ - // return this->delegate()->get_entity(); -} - -template -TCondition::TCondition( - /*const TStatusCondition& h*/) -{ - //To implement - // if (h.is_nil()) { - // /* We got a null object and are not really able to do a typecheck here. */ - // /* So, just set a null object. */ - // *this = dds::core::null; - // } else { - // ISOCPP_REPORT_STACK_DDS_BEGIN(h); - - // this->::dds::core::Reference::impl_ = OSPL_CXX11_STD_MODULE::dynamic_pointer_cast(h.delegate()); - // if (h.delegate() != this->::dds::core::Reference::impl_) { - // throw dds::core::IllegalOperationError(std::string("Attempted invalid cast: ") + typeid(h).name() + " to " + typeid(*this).name()); - // } - // } -} - -template -TCondition& TCondition::operator =( - /*const dds::core::cond::TStatusCondition& rhs*/) -{ - //To implement - // if (this != (TCondition*)&rhs) { - // if (rhs.is_nil()) { - // /* We got a null object and are not really able to do a typecheck here. */ - // /* So, just set a null object. */ - // *this = dds::core::null; - // } else { - // TCondition other(rhs); - // /* Dont have to copy when the delegate is the same. */ - // if (other.delegate() != this->::dds::core::Reference::impl_) { - // *this = other; - // } - // } - // } - // return *this; -} - -} //namespace cond -} //namespace core -} //namespace dds - -#endif //EPROSIMA_DDS_CORE_COND_TSTATUSCONDITION_IMPL_HPP_ diff --git a/include/dds/core/cond/detail/WaitSet.hpp b/include/dds/core/cond/detail/WaitSet.hpp deleted file mode 100644 index 114341c6441..00000000000 --- a/include/dds/core/cond/detail/WaitSet.hpp +++ /dev/null @@ -1,44 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_CORE_COND_DETAIL_WAITSET_HPP_ -#define EPROSIMA_DDS_CORE_COND_DETAIL_WAITSET_HPP_ - -/** - * @cond - * Ignore this file in the API - */ -//#include - -namespace dds { -namespace core { -namespace cond { -namespace detail { - -//using WaitSet = eprosima::fastdds::dds::WaitSet; -class WaitSet -{ -}; - -} //namespace detail -} //namespace cond -} //namespace core -} //namespace dds - -/** @endcond */ - -#endif //EPROSIMA_DDS_CORE_COND_DETAIL_WAITSET_HPP_ diff --git a/include/dds/core/cond/detail/WaitSetImpl.hpp b/include/dds/core/cond/detail/WaitSetImpl.hpp deleted file mode 100644 index 59f26f34961..00000000000 --- a/include/dds/core/cond/detail/WaitSetImpl.hpp +++ /dev/null @@ -1,149 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_CORE_COND_TWAITSET_HPP_ -#define EPROSIMA_DDS_CORE_COND_TWAITSET_HPP_ - -/** - * @file - */ - -/* - * OMG PSM class declaration - */ -#include - -namespace dds { -namespace core { -namespace cond { - -template -TWaitSet::TWaitSet() -{ -} - -template -TWaitSet::~TWaitSet() -{ -} - -template -const typename TWaitSet::ConditionSeq TWaitSet::wait( - const dds::core::Duration& timeout) -{ - ConditionSeq triggered; - return this->wait(triggered, timeout); -} - -template -const typename TWaitSet::ConditionSeq TWaitSet::wait() -{ - ConditionSeq triggered; - return this->wait(triggered, dds::core::Duration::infinite()); -} - -template -typename TWaitSet::ConditionSeq& TWaitSet::wait( - ConditionSeq& /*triggered*/, - const dds::core::Duration& /*timeout*/) -{ - // this->delegate()->wait(triggered, timeout); - // return triggered; -} - -template -typename TWaitSet::ConditionSeq& TWaitSet::wait( - ConditionSeq & triggered) -{ - this->wait(triggered, dds::core::Duration::infinite()); - return triggered; -} - -template -void TWaitSet::dispatch() -{ - //To implement - // ISOCPP_REPORT_STACK_DDS_BEGIN(*this); - // this->dispatch(dds::core::Duration::infinite()); -} - -template -void TWaitSet::dispatch( - const dds::core::Duration& timeout) -{ - //To implement - // ISOCPP_REPORT_STACK_DDS_BEGIN(*this); - // this->delegate()->dispatch(timeout); -} - -template -TWaitSet& TWaitSet::operator +=( - const Condition& cond) -{ - this->attach_condition(cond); - return *this; -} - -template -TWaitSet& TWaitSet::operator -=( - const Condition& cond) -{ - this->detach_condition(cond); - return *this; -} - -template -TWaitSet& TWaitSet::attach_condition( - const Condition& /*cond*/) -{ - // this->delegate()->attach_condition(cond); - // return *this; -} - -template -bool TWaitSet::detach_condition( - const Condition& /*cond*/) -{ - // if (this->delegate()->detach_condition(cond.delegate().get()) == - // eprosima::fastrtps::types::ReturnCode_t::RETCODE_OK) - // { - // return true; - // } - // return false; -} - -template -const typename TWaitSet::ConditionSeq TWaitSet::conditions() const -{ - ConditionSeq conds; - return this->conditions(conds); -} - -template -typename TWaitSet::ConditionSeq& TWaitSet::conditions( - ConditionSeq& /*conds*/) const -{ - // this->delegate()->get_conditions(conds); - // return conds; -} - -} //namespace cond -} //namespace core -} //namespace dds - - -#endif //EPROSIMA_DDS_CORE_COND_TWAITSET_HPP_ diff --git a/include/dds/core/conformance.hpp b/include/dds/core/conformance.hpp deleted file mode 100644 index 5fa6404ff3a..00000000000 --- a/include/dds/core/conformance.hpp +++ /dev/null @@ -1,25 +0,0 @@ -/* - * Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_CORE_CONFORMANCE_HPP_ -#define OMG_DDS_CORE_CONFORMANCE_HPP_ - -#include - -#endif //OMG_DDS_CORE_CONFORMANCE_HPP_ diff --git a/include/dds/core/ddscore.hpp b/include/dds/core/ddscore.hpp deleted file mode 100644 index e0e2ef93823..00000000000 --- a/include/dds/core/ddscore.hpp +++ /dev/null @@ -1,38 +0,0 @@ -/* - * Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * All rights reserved. - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_CORE_PACKAGE_INCLUDE_HPP_ -#define OMG_DDS_CORE_PACKAGE_INCLUDE_HPP_ - -#include -#include -#include -#include -#include -#include - -#include -#include -#include -#include - -#include - -#endif //OMG_DDS_CORE_PACKAGE_INCLUDE_HPP_ \ No newline at end of file diff --git a/include/dds/core/detail/BuiltinTopicTypes.hpp b/include/dds/core/detail/BuiltinTopicTypes.hpp deleted file mode 100644 index f0ad0a0fa29..00000000000 --- a/include/dds/core/detail/BuiltinTopicTypes.hpp +++ /dev/null @@ -1,236 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_CORE_DELEGATE_BUILTIN_TOPIC_TYPES_HPP_ -#define EPROSIMA_DDS_CORE_DELEGATE_BUILTIN_TOPIC_TYPES_HPP_ - -//#include -//TODO: Fix when BuiltinTopicDelegate and BuiltinTopic are implemented -//#include -//#include - -#if defined (OMG_DDS_X_TYPES_BUILTIN_TOPIC_TYPES_SUPPORT) - -namespace dds { -namespace core { -namespace detail { - -//TODO: Fix when BuiltinTopicDelegate and BuiltinTopic are implemented -//typedef dds::core::TBytesTopicType BytesTopicType; -class BytesTopicType -{ -}; - -//TODO: Fix when BuiltinTopicDelegate and BuiltinTopic are implemented -//typedef dds::core::TStringTopicType StringTopicType; -class StringTopicType -{ -}; - -//TODO: Fix when BuiltinTopicDelegate and BuiltinTopic are implemented -//typedef dds::core::TKeyedBytesTopicType KeyedBytesTopicType; -class KeyedBytesTopicType -{ -}; - -//TODO: Fix when BuiltinTopicDelegate and BuiltinTopic are implemented -//typedef dds::core::TKeyedStringTopicType KeyedStringTopicType; -class KeyedStringTopicType -{ -}; - -} //namespace detail - - -//============================================================================== -// Bytes Template -//============================================================================== - -template -TBytesTopicType::TBytesTopicType() - : Value( - std::vector()) -{ -} - -template -TBytesTopicType::TBytesTopicType( - const std::vector& data) - : dds::core::Value( - data) -{ -} - -template -TBytesTopicType::operator std::vector&() const -{ - return this->delegate().value(); -} - -template -const std::vector& TBytesTopicType::data() const -{ - return this->delegate().value(); -} - -template -void TBytesTopicType::data( - const std::vector& data) -{ - this->delegate().value(data); -} - -//============================================================================== -// String Template -//============================================================================== - -template -TStringTopicType::TStringTopicType() - : Value( - std::string()) -{ -} - -template -TStringTopicType::TStringTopicType( - const std::string& data) - : dds::core::Value( - data) -{ -} - -template -TStringTopicType::operator std::string& () const -{ - return this->delegate().value(); -} - -template -const std::string& TStringTopicType::data() const -{ - return this->delegate().value(); -} - -template -void TStringTopicType::data( - const std::string& data) -{ - this->delegate().value(data); -} - -//============================================================================== -// KeyedBytes Template -//============================================================================== - -template -TKeyedBytesTopicType::TKeyedBytesTopicType() - : Value( - std::string(), - std::vector()) -{ -} - -template -TKeyedBytesTopicType::TKeyedBytesTopicType( - const std::string& key, - const std::vector& value) - : Value( - key, - value) -{ -} - -template -const std::string& TKeyedBytesTopicType::key() const -{ - return this->delegate().key(); -} - -template -void TKeyedBytesTopicType::key( - const std::string& key) -{ - this->delegate().key(key); -} - -template -const std::vector& TKeyedBytesTopicType::value() const -{ - return this->delegate().value(); -} - -template -void TKeyedBytesTopicType::value( - const std::vector& value) -{ - this->delegate().value(value); -} - -//============================================================================== -// KeyedString Template -//============================================================================== - -template -TKeyedStringTopicType::TKeyedStringTopicType() - : Value( - std::string(), - std::string()) -{ -} - -template -TKeyedStringTopicType::TKeyedStringTopicType( - const std::string& key, - const std::string& value) - : Value( - key, - value) -{ -} - -template -const std::string& TKeyedStringTopicType::key() const -{ - return this->delegate().key(); -} - -template -void TKeyedStringTopicType::key( - const std::string& key) -{ - this->delegate().key(key); -} - -template -const std::string& TKeyedStringTopicType::value() const -{ - return this->delegate().value(); -} - -template -void TKeyedStringTopicType::value( - const std::string& value) -{ - this->delegate().value(value); -} - -} //namespace core -} //namespace dds - -#endif //OMG_DDS_X_TYPES_BUILTIN_TOPIC_TYPES_SUPPORT - -#endif //EPROSIMA_DDS_CORE_DELEGATE_BUILTIN_TOPIC_TYPES_HPP_ diff --git a/include/dds/core/detail/Entity.hpp b/include/dds/core/detail/Entity.hpp deleted file mode 100644 index 8f6a74ab48e..00000000000 --- a/include/dds/core/detail/Entity.hpp +++ /dev/null @@ -1,40 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_CORE_DETAIL_ENTITY_IMPL_HPP_ -#define EPROSIMA_DDS_CORE_DETAIL_ENTITY_IMPL_HPP_ - -#include - -/** - * @cond - * Ignore this file in the API - */ - -namespace dds { -namespace core { -namespace detail { - -using Entity = eprosima::fastdds::dds::Entity; - -} //namespace detail -} //namespace core -} //namespace dds - -/** @endcond */ - -#endif //EPROSIMA_DDS_CORE_DETAIL_ENTITY_IMPL_HPP_ diff --git a/include/dds/core/detail/EntityQosImpl.hpp b/include/dds/core/detail/EntityQosImpl.hpp deleted file mode 100644 index 9c3773001d4..00000000000 --- a/include/dds/core/detail/EntityQosImpl.hpp +++ /dev/null @@ -1,131 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_CORE_TENTITYQOS_IMPL_HPP_ -#define EPROSIMA_DDS_CORE_TENTITYQOS_IMPL_HPP_ - -/** - * @file - */ - -/* - * OMG PSM class declaration - */ -#include - -namespace dds { -namespace core { - -template -TEntityQos::TEntityQos() - : dds::core::Value() -{ -} - -template -TEntityQos::TEntityQos( - const TEntityQos& other) - : dds::core::Value(other.delegate()) -{ -} - -/** @cond - * Somehow, these cause functions duplicates in doxygen documentation. - */ -template -template -TEntityQos::TEntityQos( - const TEntityQos& qos) - : dds::core::Value(qos.delegate()) -{ -} - -/** @endcond */ - -template -TEntityQos::~TEntityQos() -{ -} - -/** @cond - * Somehow, these cause functions duplicates in doxygen documentation. - */ -template -template -TEntityQos& TEntityQos::policy( - const POLICY& p) -{ - //To implement - // this->dds::core::Value::delegate().policy(p); - // return *this; -} - -template -template -const POLICY& TEntityQos::policy() const -{ - //To implement - // return this->delegate().template policy(); -} - -template -template -POLICY& TEntityQos::policy() -{ - //To implement - // return this->delegate().template policy(); -} - -template -template -TEntityQos& TEntityQos::operator <<( - const POLICY& p) -{ - //To implement - // this->policy(p); - // return *this; -} - -template -template -const TEntityQos& TEntityQos::operator >>( - POLICY& p) const -{ - //To implement - // p = this->policy(); - // return *this; -} - -template -template -TEntityQos& TEntityQos::operator =( - const TEntityQos& other) -{ - //To implement - // if(this != (TEntityQos*)&other) - // { - // this->d_ = other.delegate(); - // } - // return *this; -} - -/** @endcond */ - -} //namespace core -} //namespace dds - -#endif //EPROSIMA_DDS_CORE_TENTITYQOS_IMPL_HPP_ diff --git a/include/dds/core/detail/InstanceHandle.hpp b/include/dds/core/detail/InstanceHandle.hpp deleted file mode 100644 index 62a14389a31..00000000000 --- a/include/dds/core/detail/InstanceHandle.hpp +++ /dev/null @@ -1,40 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_CORE_DETAIL_INSTANCE_HANDLE_HPP_ -#define EPROSIMA_DDS_CORE_DETAIL_INSTANCE_HANDLE_HPP_ - -#include - -/** - * @cond - * Ignore this file in the API - */ - -namespace dds { -namespace core { -namespace detail { - -using InstanceHandle = eprosima::fastdds::dds::InstanceHandle_t; - -} //namespace detail -} //namespace core -} //namespace dds - -/** @endcond */ - -#endif //EPROSIMA_DDS_CORE_DETAIL_INSTANCE_HANDLE_HPP_ diff --git a/include/dds/core/detail/QosProvider.hpp b/include/dds/core/detail/QosProvider.hpp deleted file mode 100644 index 62eb2529a5b..00000000000 --- a/include/dds/core/detail/QosProvider.hpp +++ /dev/null @@ -1,43 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_CORE_DETAIL_QOS_PROVIDER_HPP_ -#define EPROSIMA_DDS_CORE_DETAIL_QOS_PROVIDER_HPP_ - -//#include - -/** - * @cond - * Ignore this file in the API - */ - -namespace dds { -namespace core { -namespace detail { - -//TODO: Fix when QosProviderDelegate is implemented -class QosProvider -{ -}; - -} //namespace detail -} //namespace core -} //namespace dds - -/** @endcond */ - -#endif //EPROSIMA_DDS_CORE_DETAIL_QOS_PROVIDER_HPP_ diff --git a/include/dds/core/detail/QosProviderImpl.hpp b/include/dds/core/detail/QosProviderImpl.hpp deleted file mode 100644 index ee015cde06e..00000000000 --- a/include/dds/core/detail/QosProviderImpl.hpp +++ /dev/null @@ -1,153 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_CORE_DETAIL_TQOSPROVIDERIMPL_HPP_ -#define EPROSIMA_DDS_CORE_DETAIL_TQOSPROVIDERIMPL_HPP_ - -/** - * @file - */ - -/* - * OMG PSM class declaration - */ -#include - -namespace dds { -namespace core { - -template -TQosProvider::TQosProvider( - const std::string& uri, - const std::string& profile) - : Reference(new DELEGATE(uri, profile)) -{ -} - -template -TQosProvider::TQosProvider( - const std::string& uri) - : Reference(new DELEGATE(uri)) -{ -} - -template -dds::domain::qos::DomainParticipantQos TQosProvider::participant_qos() -{ - //To implement - // ISOCPP_REPORT_STACK_NC_BEGIN(); - // return this->delegate()->participant_qos(NULL); -} - -template -dds::domain::qos::DomainParticipantQos TQosProvider::participant_qos( - const std::string& id) -{ - //To implement - // ISOCPP_REPORT_STACK_NC_BEGIN(); - // return this->delegate()->participant_qos(id.c_str()); -} - -template -dds::topic::qos::TopicQos TQosProvider::topic_qos() -{ - //To implement - // ISOCPP_REPORT_STACK_NC_BEGIN(); - // return this->delegate()->topic_qos(NULL); -} - -template -dds::topic::qos::TopicQos TQosProvider::topic_qos( - const std::string& id) -{ - //To implement - // ISOCPP_REPORT_STACK_NC_BEGIN(); - // return this->delegate()->topic_qos(id.c_str()); -} - -template -dds::sub::qos::SubscriberQos TQosProvider::subscriber_qos() -{ - //To implement - // ISOCPP_REPORT_STACK_NC_BEGIN(); - // return this->delegate()->subscriber_qos(NULL); -} - -template -dds::sub::qos::SubscriberQos TQosProvider::subscriber_qos( - const std::string& id) -{ - //To implement - // ISOCPP_REPORT_STACK_NC_BEGIN(); - // return this->delegate()->subscriber_qos(id.c_str()); -} - -template -dds::sub::qos::DataReaderQos TQosProvider::datareader_qos() -{ - //To implement - // ISOCPP_REPORT_STACK_NC_BEGIN(); - // return this->delegate()->datareader_qos(NULL); -} - -template -dds::sub::qos::DataReaderQos TQosProvider::datareader_qos( - const std::string& id) -{ - //To implement - // ISOCPP_REPORT_STACK_NC_BEGIN(); - // return this->delegate()->datareader_qos(id.c_str()); -} - -template -dds::pub::qos::PublisherQos TQosProvider::publisher_qos() -{ - //To implement - // ISOCPP_REPORT_STACK_NC_BEGIN(); - // return this->delegate()->publisher_qos(NULL); -} - -template -dds::pub::qos::PublisherQos TQosProvider::publisher_qos( - const std::string& id) -{ - //To implement - // ISOCPP_REPORT_STACK_NC_BEGIN(); - // return this->delegate()->publisher_qos(id.c_str()); -} - -template -dds::pub::qos::DataWriterQos TQosProvider::datawriter_qos() -{ - //To implement - // ISOCPP_REPORT_STACK_NC_BEGIN(); - // return this->delegate()->datawriter_qos(NULL); -} - -template -dds::pub::qos::DataWriterQos TQosProvider::datawriter_qos( - const std::string& id) -{ - //To implement - // ISOCPP_REPORT_STACK_NC_BEGIN(); - // return this->delegate()->datawriter_qos(id.c_str()); -} - -} //namespace core -} //namespace dds - -#endif //EPROSIMA_DDS_CORE_DETAIL_TQOSPROVIDERIMPL_HPP_ diff --git a/include/dds/core/detail/ReferenceImpl.hpp b/include/dds/core/detail/ReferenceImpl.hpp deleted file mode 100644 index 05f20625264..00000000000 --- a/include/dds/core/detail/ReferenceImpl.hpp +++ /dev/null @@ -1,257 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_CORE_REFERENCE_IMPL_HPP_ -#define EPROSIMA_DDS_CORE_REFERENCE_IMPL_HPP_ - -/** - * @file - */ - -/* - * OMG PSM class declaration - */ -#include - -namespace dds { -namespace core { - -// Implementation -template -Reference::Reference( - null_type&) - : impl_() -{ -} - -template -Reference::Reference( - const Reference& ref) - : impl_(ref.impl_) -{ -} - -template -template -Reference::Reference( - const Reference& ref) -{ - //To Implement - // ISOCPP_REPORT_STACK_DDS_BEGIN(*this); - // impl_ = OSPL_CXX11_STD_MODULE::dynamic_pointer_cast(ref.impl_); - // if (impl_ != ref.impl_) { - // throw dds::core::IllegalOperationError(std::string("Attempted invalid cast: ") + typeid(ref).name() + " to " + typeid(*this).name()); - // } - -} - -template -Reference::Reference( - DELEGATE_T* p) - : impl_(p) -{ -} - -template -Reference::Reference( - const DELEGATE_REF_T& p) - : impl_(p) -{ - //OMG_DDS_LOG("MM", "Reference(DELEGATE_REF_T& p)"); -} - -template -Reference::~Reference() -{ -} - -template -Reference::operator DELEGATE_REF_T() const -{ - //To implement - // ISOCPP_REPORT_STACK_NC_BEGIN(); - // ISOCPP_BOOL_CHECK_AND_THROW(impl_, ISOCPP_NULL_REFERENCE_ERROR, "Reference[%d] == dds::core::null", __LINE__); - // return impl_; -} - -template -template -bool Reference::operator ==( - const R& ref) const -{ - //To implement - // ISOCPP_REPORT_STACK_DDS_BEGIN(*this); - // bool equal = false; - // if (this->is_nil() && ref.is_nil()) { - // /* Both delegates are null. */ - // equal = true; - // } else if (!this->is_nil() && !ref.is_nil()) { - // /* Check delegates. */ - // equal = (this->delegate() == ref.delegate()); - // } - // return equal; -} - -template -template -bool Reference::operator !=( - const R& ref) const -{ - //To implement - // ISOCPP_REPORT_STACK_DDS_BEGIN(*this); - // return !(*this == ref); -} - -template -template -Reference& Reference::operator =( - const Reference& that) -{ - //To implement - // OMG_DDS_STATIC_ASSERT((dds::core::is_base_of::value)); - // if(this != (Reference*)&that) - // { - // *this = Reference(that); - // } - // return *this; -} - -template -template -Reference& Reference::operator =( - const R& rhs) -{ - //To implement - // OMG_DDS_STATIC_ASSERT((dds::core::is_base_of< DELEGATE_T, typename R::DELEGATE_T>::value)); - // if(this != (Reference*)&rhs) - // { - // *this = Reference(rhs); - // } - // return *this; -} - -template -Reference& Reference::operator =( - const null_type) -{ - //To implement - // DELEGATE_REF_T tmp; - // impl_ = tmp; - // return *this; -} - -template -bool Reference::is_nil() const -{ - //To implement - // return impl_.get() == 0; -} - -template -bool Reference::operator ==( - const null_type) const -{ - //To implement - // return this->is_nil(); -} - -template -bool Reference::operator !=( - const null_type) const -{ - //To implement - // return !(this->is_nil()); -} - -template -const typename Reference::DELEGATE_REF_T& Reference::delegate() const -{ - //To implement - // ISOCPP_BOOL_CHECK_AND_THROW(impl_, ISOCPP_NULL_REFERENCE_ERROR, "Reference[%d] == dds::core::null", __LINE__); - // return impl_; -} - -template -typename Reference::DELEGATE_REF_T& Reference::delegate() -{ - //To implement - // ISOCPP_BOOL_CHECK_AND_THROW(impl_, ISOCPP_NULL_REFERENCE_ERROR, "Reference[%d] == dds::core::null", __LINE__); - // return impl_; -} - -template -DELEGATE* Reference::operator ->() -{ - //To implement - // ISOCPP_BOOL_CHECK_AND_THROW(impl_, ISOCPP_NULL_REFERENCE_ERROR, "Reference[%d] == dds::core::null", __LINE__); - // return impl_.get(); -} - -template -const DELEGATE* Reference::operator ->() const -{ - //To implement - // ISOCPP_BOOL_CHECK_AND_THROW(impl_, ISOCPP_NULL_REFERENCE_ERROR, "Reference[%d] == dds::core::null", __LINE__); - // return impl_.get(); -} - -template -Reference::operator const typename Reference::DELEGATE_REF_T& () const -{ - //To implement - // ISOCPP_BOOL_CHECK_AND_THROW(impl_, ISOCPP_NULL_REFERENCE_ERROR, "Reference[%d] == dds::core::null", __LINE__); - // return impl_; -} - -template -Reference::operator typename Reference::DELEGATE_REF_T& () -{ - //To implement - // ISOCPP_BOOL_CHECK_AND_THROW(impl_, ISOCPP_NULL_REFERENCE_ERROR, "Reference[%d] == dds::core::null", __LINE__); - // return impl_; -} - -template -void Reference::set_ref( - DELEGATE_T* p) -{ - //To implement - // impl_.reset(p); -} - -template -bool operator ==( - null_type, - const Reference& r) -{ - //To implement - // return r.is_nil(); -} - -template -bool operator !=( - null_type, - const Reference& r) -{ - //To implement - // return !r.is_nil(); -} - -} //namespace core -} //namespace dds - -#endif //EPROSIMA_DDS_CORE_REFERENCE_IMPL_HPP_ diff --git a/include/dds/core/detail/Value.hpp b/include/dds/core/detail/Value.hpp deleted file mode 100644 index 4da652d4851..00000000000 --- a/include/dds/core/detail/Value.hpp +++ /dev/null @@ -1,203 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_CORE_DETAIL_VALUE_HPP_ -#define EPROSIMA_DDS_CORE_DETAIL_VALUE_HPP_ - -/** - * @file - */ - -/* - * OMG PSM class declaration - */ -#include - -namespace dds { -namespace core { - -/** - * @internal @todo We can't assume that the compiler supports variadic templates, yet. - * This code should be refactored to take advantage of compilers that do support variadic - * templates. - */ - -template -Value::Value() -{ -} - -template -Value::Value( - const Value& p) - : d_(p.d_) -{ -} - -template -template -Value::Value( - const ARG& arg) - : d_(arg) -{ -} - -template -template< - typename ARG1, - typename ARG2> -Value::Value( - const ARG1& arg1, - const ARG2& arg2) - : d_(arg1, arg2) -{ -} - -template -template< - typename ARG1, - typename ARG2, - typename ARG3> -Value::Value( - const ARG1& arg1, - const ARG2& arg2, - const ARG3& arg3) - : d_(arg1, arg2, arg3) -{ -} - -template -template< - typename ARG1, - typename ARG2, - typename ARG3, - typename ARG4> -Value::Value( - const ARG1& arg1, - const ARG2& arg2, - const ARG3& arg3, - const ARG4& arg4) - : d_(arg1, arg2, arg3, arg4) -{ -} - -template -template< - typename ARG1, - typename ARG2, - typename ARG3, - typename ARG4, - typename ARG5> -Value::Value( - const ARG1& arg1, - const ARG2& arg2, - const ARG3& arg3, - const ARG4& arg4, - const ARG5& arg5) - : d_(arg1, arg2, arg3, arg4, arg5) -{ -} - -template -template< - typename ARG1, - typename ARG2, - typename ARG3, - typename ARG4, - typename ARG5, - typename ARG6> -Value::Value( - const ARG1& arg1, - const ARG2& arg2, - const ARG3& arg3, - const ARG4& arg4, - const ARG5& arg5, - const ARG6& arg6) - : d_(arg1, arg2, arg3, arg4, arg5, arg6) -{ -} - -template -Value::~Value() -{ -} - -template -Value& Value::operator =( - const Value& other) -{ - if (this != &other) - { - d_ = other.d_; - } - return *this; -} - -template -bool Value::operator ==( - const Value& other) const -{ - return (d_ == other.d_); -} - -template -bool Value::operator !=( - const Value& other) const -{ - return !(d_ == other.d_); -} - -template -const D* Value::operator ->() const -{ - return &d_; -} - -template -D* Value::operator ->() -{ - return &d_; -} - -template -const D& Value::delegate() const -{ - return d_; -} - -template -D& Value::delegate() -{ - return d_; -} - -template -Value::operator D& () -{ - return d_; -} - -template -Value::operator const D& () const -{ - return d_; -} - -} //namespace core -} //namespace dds - -#endif //EPROSIMA_DDS_CORE_DETAIL_VALUE_HPP_ diff --git a/include/dds/core/detail/WeakReferenceImpl.hpp b/include/dds/core/detail/WeakReferenceImpl.hpp deleted file mode 100644 index 63d79b61833..00000000000 --- a/include/dds/core/detail/WeakReferenceImpl.hpp +++ /dev/null @@ -1,71 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_CORE_WEAK_REFERENCE_IMPL_HPP_ -#define EPROSIMA_DDS_CORE_WEAK_REFERENCE_IMPL_HPP_ - -/** - * @file - */ - -/* - * OMG PSM class declaration - */ -#include -#include - -namespace dds { -namespace core { - -template -WeakReference::WeakReference() -{ -} - -template -WeakReference::WeakReference( - const T& t) -{ - //To implement - // if (!t.is_nil()) { - // impl_ = t.delegate(); - // } -} - -template -WeakReference::~WeakReference() -{ -} - -template -bool WeakReference::expired() -{ - //To implement - // return impl_.expired(); -} - -template -T WeakReference::lock() -{ - //To implement - // return T(impl_.lock()); -} - -} //namespace core -} //namespace dds - -#endif //EPROSIMA_DDS_CORE_WEAK_REFERENCE_IMPL_HPP_ diff --git a/include/dds/core/detail/array.hpp b/include/dds/core/detail/array.hpp deleted file mode 100644 index 285d53960ae..00000000000 --- a/include/dds/core/detail/array.hpp +++ /dev/null @@ -1,34 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_CORE_DETAIL_ARRAY_HPP_ -#define EPROSIMA_DDS_CORE_DETAIL_ARRAY_HPP_ - -#include - -namespace dds { -namespace core { -namespace detail { - -using ::std::array; - -} //namespace detail -} //namespace core -} //namespace dds - -#endif //EPROSIMA_DDS_CORE_DETAIL_ARRAY_HPP_ - diff --git a/include/dds/core/detail/conformance.hpp b/include/dds/core/detail/conformance.hpp deleted file mode 100644 index f33f7d997e6..00000000000 --- a/include/dds/core/detail/conformance.hpp +++ /dev/null @@ -1,44 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_CORE_DETAIL_CONFORMANCE_HPP_ -#define EPROSIMA_DDS_CORE_DETAIL_CONFORMANCE_HPP_ - -/* The following macros correspond to the compliance "profiles" of the DDS - * specification. Implementations shall modify this header to indicate their - * level of support: - * - An implementation fully implementing a given profile shall define - * the corresponding macro to "FULL". - * - An implementation partially supporting a given profile shall define - * the corresponding macro to "PARTIAL". - * - And implementation with no support for a given profile shall leave - * the corresponding macro undefined. - * - * DDS Minimum Profile support is required of all DDS implementations; - * therefore no corresponding macro is provided. - */ - -//#define OMG_DDS_CONTENT_SUBSCRIPTION_SUPPORT FULL -//#define OMG_DDS_MULTI_TOPIC_SUPPORT FULL -#define OMG_DDS_PERSISTENCE_SUPPORT FULL -#define OMG_DDS_OWNERSHIP_SUPPORT PARTIAL -#define OMG_DDS_OBJECT_MODEL_SUPPORT PARTIAL -#define OMG_DDS_EXTENSIBLE_AND_DYNAMIC_TOPIC_TYPE_SUPPORT PARTIAL -#define OMG_DDS_X_TYPES_DYNAMIC_TYPE_SUPPORT FULL -//#define OMG_DDS_HAS_PRETTY_PRINT_COUT 1 - -#endif //EPROSIMA_DDS_CORE_DETAIL_CONFORMANCE_HPP_ diff --git a/include/dds/core/detail/dds_builtinTopics.h b/include/dds/core/detail/dds_builtinTopics.h deleted file mode 100644 index 36acc130aca..00000000000 --- a/include/dds/core/detail/dds_builtinTopics.h +++ /dev/null @@ -1,98 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_BUILTINTOPICS_H_ -#define EPROSIMA_DDS_BUILTINTOPICS_H_ - -#include -#include -//TODO: Fix when DataRepresentation and TypeHash are implemented -//#include -//#include - -namespace DDS { - -typedef dds::core::ByteSeq octSeq; - -typedef dds::topic::BuiltinTopicKey BuiltinTopicKey_t; -typedef dds::core::StringSeq StringSeq; - -//TODO: Fix when DataRepresentation and TypeHash are implemented -// using org::opensplice::topic::DataRepresentationId_t; -// using org::opensplice::topic::XCDR_REPRESENTATION; -// using org::opensplice::topic::XML_REPRESENTATION; -// using org::opensplice::topic::OSPL_REPRESENTATION; -// using org::opensplice::topic::GPB_REPRESENTATION; -// using org::opensplice::topic::INVALID_REPRESENTATION; - -typedef dds::core::Duration Duration_t; - -typedef dds::core::policy::UserData UserDataQosPolicy; -typedef dds::core::policy::TopicData TopicDataQosPolicy; -typedef dds::core::policy::GroupData GroupDataQosPolicy; -typedef dds::core::policy::TransportPriority TransportPriorityQosPolicy; -typedef dds::core::policy::Lifespan LifespanQosPolicy; -typedef dds::core::policy::DurabilityKind DurabilityQosPolicyKind; -typedef dds::core::policy::Durability DurabilityQosPolicy; -typedef dds::core::policy::PresentationAccessScopeKind PresentationQosPolicyAccessScopeKind; -typedef dds::core::policy::Presentation PresentationQosPolicy; -typedef dds::core::policy::Deadline DeadlineQosPolicy; -typedef dds::core::policy::LatencyBudget LatencyBudgetQosPolicy; -typedef dds::core::policy::OwnershipKind OwnershipQosPolicyKind; -typedef dds::core::policy::Ownership OwnershipQosPolicy; -#ifdef OMG_DDS_OWNERSHIP_SUPPORT -typedef dds::core::policy::OwnershipStrength OwnershipStrengthQosPolicy; -#endif //OMG_DDS_OWNERSHIP_SUPPORT -typedef dds::core::policy::LivelinessKind LivelinessQosPolicyKind; -typedef dds::core::policy::Liveliness LivelinessQosPolicy; -typedef dds::core::policy::TimeBasedFilter TimeBasedFilterQosPolicy; -typedef dds::core::policy::Partition PartitionQosPolicy; -typedef dds::core::policy::ReliabilityKind ReliabilityQosPolicyKind; -typedef dds::core::policy::Reliability ReliabilityQosPolicy; -typedef dds::core::policy::DestinationOrderKind DestinationOrderQosPolicyKind; -typedef dds::core::policy::DestinationOrder DestinationOrderQosPolicy; -typedef dds::core::policy::HistoryKind HistoryQosPolicyKind; -typedef dds::core::policy::History HistoryQosPolicy; -typedef dds::core::policy::ResourceLimits ResourceLimitsQosPolicy; -#ifdef OMG_DDS_PERSISTENCE_SUPPORT -typedef dds::core::policy::DurabilityService DurabilityServiceQosPolicy; -#endif //OMG_DDS_PERSISTENCE_SUPPORT -//TODO: Fix when DataRepresentation and TypeHash are implemented -// typedef org::opensplice::core::policy::ProductData ProductDataQosPolicy; -typedef dds::core::policy::EntityFactory EntityFactoryQosPolicy; -// typedef org::opensplice::core::policy::Share ShareQosPolicy; -typedef dds::core::policy::WriterDataLifecycle WriterDataLifecycleQosPolicy; -// typedef org::opensplice::core::policy::InvalidSampleVisibility InvalidSampleVisibilityQosPolicyKind; -// typedef org::opensplice::core::policy::SubscriptionKey SubscriptionKeyQosPolicy; -typedef dds::core::policy::ReaderDataLifecycle ReaderDataLifecycleQosPolicy; -// typedef org::opensplice::core::policy::SubscriptionKey UserKeyQosPolicy; -// typedef org::opensplice::core::policy::ReaderLifespan ReaderLifespanQosPolicy; -// typedef org::opensplice::topic::TypeHash TypeHash; -typedef dds::topic::ParticipantBuiltinTopicData ParticipantBuiltinTopicData; -typedef dds::topic::TopicBuiltinTopicData TopicBuiltinTopicData; -// typedef org::opensplice::topic::TypeBuiltinTopicData TypeBuiltinTopicData; -typedef dds::topic::PublicationBuiltinTopicData PublicationBuiltinTopicData; -typedef dds::topic::SubscriptionBuiltinTopicData SubscriptionBuiltinTopicData; -// typedef org::opensplice::topic::CMParticipantBuiltinTopicData CMParticipantBuiltinTopicData; -// typedef org::opensplice::topic::CMPublisherBuiltinTopicData CMPublisherBuiltinTopicData; -// typedef org::opensplice::topic::CMSubscriberBuiltinTopicData CMSubscriberBuiltinTopicData; -// typedef org::opensplice::topic::CMDataWriterBuiltinTopicData CMDataWriterBuiltinTopicData; -// typedef org::opensplice::topic::CMDataReaderBuiltinTopicData CMDataReaderBuiltinTopicData; - -} //namespace DDS - -#endif //EPROSIMA_DDS_BUILTINTOPICS_H_ diff --git a/include/dds/core/detail/dds_builtinTopicsSplDcps.h b/include/dds/core/detail/dds_builtinTopicsSplDcps.h deleted file mode 100644 index 34f0ef970ca..00000000000 --- a/include/dds/core/detail/dds_builtinTopicsSplDcps.h +++ /dev/null @@ -1,577 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_BUILTINTOPICSSPLTYPES_H_ -#define EPROSIMA_DDS_BUILTINTOPICSSPLTYPES_H_ - -//#include -//#include -//#include -//#include -//#include -#include -#include -//#include -//#include "v_copyIn.h" - -//typedef os_uchar *_DDS_octSeq; -//v_copyin_result -//__DDS_octSeq__copyIn( -// c_type dbType, -// const dds::core::ByteSeq *from, -// _DDS_octSeq *to); - - -//typedef c_long _DDS_BuiltinTopicKey_t[3]; -//v_copyin_result -//__DDS_BuiltinTopicKey_t__copyIn( -// c_type dbType, -// const dds::topic::BuiltinTopicKey *from, -// _DDS_BuiltinTopicKey_t *to); - -//typedef c_sequence _DDS_StringSeq; -//v_copyin_result -//__DDS_StringSeq__copyIn( -// c_type dbType, -// const dds::core::StringSeq *from, -// _DDS_StringSeq *to); - -//typedef c_short _DDS_DataRepresentationId_t; - -struct _DDS_Duration_t; -//OMG_DDS_API v_copyin_result __DDS_Duration_t__copyIn(c_type dbType, const struct dds::core::Duration *from, struct _DDS_Duration_t *to); -OMG_DDS_API void __DDS_Duration_t__copyOut( - const void* _from, - void* _to); -//struct _DDS_Duration_t { -// c_long sec; -// c_ulong nanosec; -//}; - - -struct _DDS_UserDataQosPolicy; -//OMG_DDS_API v_copyin_result __DDS_UserDataQosPolicy__copyIn(c_type dbType, const dds::core::policy::UserData *from, struct _DDS_UserDataQosPolicy *to); -OMG_DDS_API void __DDS_UserDataQosPolicy__copyOut( - const void* _from, - void* _to); -//struct _DDS_UserDataQosPolicy { -// _DDS_octSeq value; -//}; - -struct _DDS_TopicDataQosPolicy; -//OMG_DDS_API v_copyin_result __DDS_TopicDataQosPolicy__copyIn(c_type dbType, const dds::core::policy::TopicData *from, struct _DDS_TopicDataQosPolicy *to); -OMG_DDS_API void __DDS_TopicDataQosPolicy__copyOut( - const void* _from, - void* _to); -//struct _DDS_TopicDataQosPolicy { -// _DDS_octSeq value; -//}; - -struct _DDS_GroupDataQosPolicy; -//OMG_DDS_API v_copyin_result __DDS_GroupDataQosPolicy__copyIn(c_type dbType, const dds::core::policy::GroupData *from, struct _DDS_GroupDataQosPolicy *to); -OMG_DDS_API void __DDS_GroupDataQosPolicy__copyOut( - const void* _from, - void* _to); -//struct _DDS_GroupDataQosPolicy { -// _DDS_octSeq value; -//}; - -struct _DDS_TransportPriorityQosPolicy; -//OMG_DDS_API v_copyin_result __DDS_TransportPriorityQosPolicy__copyIn(c_type dbType, const dds::core::policy::TransportPriority *from, struct _DDS_TransportPriorityQosPolicy *to); -OMG_DDS_API void __DDS_TransportPriorityQosPolicy__copyOut( - const void* _from, - void* _to); -//struct _DDS_TransportPriorityQosPolicy { -// c_long value; -//}; - -struct _DDS_LifespanQosPolicy; -//OMG_DDS_API v_copyin_result __DDS_LifespanQosPolicy__copyIn(c_type dbType, const dds::core::policy::Lifespan *from, struct _DDS_LifespanQosPolicy *to); -OMG_DDS_API void __DDS_LifespanQosPolicy__copyOut( - const void* _from, - void* _to); -//struct _DDS_LifespanQosPolicy { -// struct _DDS_Duration_t duration; -//}; - -enum _DDS_DurabilityQosPolicyKind -{ - _DDS_VOLATILE_DURABILITY_QOS, - _DDS_TRANSIENT_LOCAL_DURABILITY_QOS, - _DDS_TRANSIENT_DURABILITY_QOS, - _DDS_PERSISTENT_DURABILITY_QOS -}; -struct _DDS_DurabilityQosPolicy; -//OMG_DDS_API v_copyin_result __DDS_DurabilityQosPolicy__copyIn(c_type dbType, const dds::core::policy::Durability *from, struct _DDS_DurabilityQosPolicy *to); -OMG_DDS_API void __DDS_DurabilityQosPolicy__copyOut( - const void* _from, - void* _to); -struct _DDS_DurabilityQosPolicy -{ - enum _DDS_DurabilityQosPolicyKind kind; -}; - -enum _DDS_PresentationQosPolicyAccessScopeKind -{ - _DDS_INSTANCE_PRESENTATION_QOS, - _DDS_TOPIC_PRESENTATION_QOS, - _DDS_GROUP_PRESENTATION_QOS -}; -struct _DDS_PresentationQosPolicy; -//OMG_DDS_API v_copyin_result __DDS_PresentationQosPolicy__copyIn(c_type dbType, const dds::core::policy::Presentation *from, struct _DDS_PresentationQosPolicy *to); -OMG_DDS_API void __DDS_PresentationQosPolicy__copyOut( - const void* _from, - void* _to); -//struct _DDS_PresentationQosPolicy { -// enum _DDS_PresentationQosPolicyAccessScopeKind access_scope; -// c_bool coherent_access; -// c_bool ordered_access; -//}; - -struct _DDS_DeadlineQosPolicy; -//OMG_DDS_API v_copyin_result __DDS_DeadlineQosPolicy__copyIn(c_type dbType, const dds::core::policy::Deadline *from, struct _DDS_DeadlineQosPolicy *to); -OMG_DDS_API void __DDS_DeadlineQosPolicy__copyOut( - const void* _from, - void* _to); -//struct _DDS_DeadlineQosPolicy { -// struct _DDS_Duration_t period; -//}; - -struct _DDS_LatencyBudgetQosPolicy; -//OMG_DDS_API v_copyin_result __DDS_LatencyBudgetQosPolicy__copyIn(c_type dbType, const dds::core::policy::LatencyBudget *from, struct _DDS_LatencyBudgetQosPolicy *to); -OMG_DDS_API void __DDS_LatencyBudgetQosPolicy__copyOut( - const void* _from, - void* _to); -//struct _DDS_LatencyBudgetQosPolicy { -// struct _DDS_Duration_t duration; -//}; - -enum _DDS_OwnershipQosPolicyKind -{ - _DDS_SHARED_OWNERSHIP_QOS, - _DDS_EXCLUSIVE_OWNERSHIP_QOS -}; -struct _DDS_OwnershipQosPolicy; -//OMG_DDS_API v_copyin_result __DDS_OwnershipQosPolicy__copyIn(c_type dbType, const dds::core::policy::Ownership *from, struct _DDS_OwnershipQosPolicy *to); -OMG_DDS_API void __DDS_OwnershipQosPolicy__copyOut( - const void* _from, - void* _to); -struct _DDS_OwnershipQosPolicy -{ - enum _DDS_OwnershipQosPolicyKind kind; -}; - -#ifdef OMG_DDS_OWNERSHIP_SUPPORT -struct _DDS_OwnershipStrengthQosPolicy; -//OMG_DDS_API v_copyin_result __DDS_OwnershipStrengthQosPolicy__copyIn(c_type dbType, const dds::core::policy::OwnershipStrength *from, struct _DDS_OwnershipStrengthQosPolicy *to); -OMG_DDS_API void __DDS_OwnershipStrengthQosPolicy__copyOut( - const void* _from, - void* _to); -//struct _DDS_OwnershipStrengthQosPolicy { -// c_long value; -//}; -#endif // OMG_DDS_OWNERSHIP_SUPPORT - -enum _DDS_LivelinessQosPolicyKind -{ - _DDS_AUTOMATIC_LIVELINESS_QOS, - _DDS_MANUAL_BY_PARTICIPANT_LIVELINESS_QOS, - _DDS_MANUAL_BY_TOPIC_LIVELINESS_QOS -}; -struct _DDS_LivelinessQosPolicy; -//OMG_DDS_API v_copyin_result __DDS_LivelinessQosPolicy__copyIn(c_type dbType, const dds::core::policy::Liveliness *from, struct _DDS_LivelinessQosPolicy *to); -OMG_DDS_API void __DDS_LivelinessQosPolicy__copyOut( - const void* _from, - void* _to); -//struct _DDS_LivelinessQosPolicy { -// enum _DDS_LivelinessQosPolicyKind kind; -// struct _DDS_Duration_t lease_duration; -//}; - -struct _DDS_TimeBasedFilterQosPolicy; -//OMG_DDS_API v_copyin_result __DDS_TimeBasedFilterQosPolicy__copyIn(c_type dbType, const dds::core::policy::TimeBasedFilter *from, struct _DDS_TimeBasedFilterQosPolicy *to); -OMG_DDS_API void __DDS_TimeBasedFilterQosPolicy__copyOut( - const void* _from, - void* _to); -//struct _DDS_TimeBasedFilterQosPolicy { -// struct _DDS_Duration_t minimum_separation; -//}; - -struct _DDS_PartitionQosPolicy; -//OMG_DDS_API v_copyin_result __DDS_PartitionQosPolicy__copyIn(c_type dbType, const dds::core::policy::Partition *from, struct _DDS_PartitionQosPolicy *to); -OMG_DDS_API void __DDS_PartitionQosPolicy__copyOut( - const void* _from, - void* _to); -//struct _DDS_PartitionQosPolicy { -// _DDS_StringSeq name; -//}; - -enum _DDS_ReliabilityQosPolicyKind -{ - _DDS_BEST_EFFORT_RELIABILITY_QOS, - _DDS_RELIABLE_RELIABILITY_QOS -}; -struct _DDS_ReliabilityQosPolicy; -//OMG_DDS_API v_copyin_result __DDS_ReliabilityQosPolicy__copyIn(c_type dbType, const dds::core::policy::Reliability *from, struct _DDS_ReliabilityQosPolicy *to); -OMG_DDS_API void __DDS_ReliabilityQosPolicy__copyOut( - const void* _from, - void* _to); -//struct _DDS_ReliabilityQosPolicy { -// enum _DDS_ReliabilityQosPolicyKind kind; -// struct _DDS_Duration_t max_blocking_time; -// c_bool synchronous; -//}; - -enum _DDS_DestinationOrderQosPolicyKind -{ - _DDS_BY_RECEPTION_TIMESTAMP_DESTINATIONORDER_QOS, - _DDS_BY_SOURCE_TIMESTAMP_DESTINATIONORDER_QOS -}; -struct _DDS_DestinationOrderQosPolicy; -//OMG_DDS_API v_copyin_result __DDS_DestinationOrderQosPolicy__copyIn(c_type dbType, const dds::core::policy::DestinationOrder *from, struct _DDS_DestinationOrderQosPolicy *to); -OMG_DDS_API void __DDS_DestinationOrderQosPolicy__copyOut( - const void* _from, - void* _to); -struct _DDS_DestinationOrderQosPolicy -{ - enum _DDS_DestinationOrderQosPolicyKind kind; -}; - -enum _DDS_HistoryQosPolicyKind -{ - _DDS_KEEP_LAST_HISTORY_QOS, - _DDS_KEEP_ALL_HISTORY_QOS -}; -struct _DDS_HistoryQosPolicy; -//OMG_DDS_API v_copyin_result __DDS_HistoryQosPolicy__copyIn(c_type dbType, const dds::core::policy::History *from, struct _DDS_HistoryQosPolicy *to); -OMG_DDS_API void __DDS_HistoryQosPolicy__copyOut( - const void* _from, - void* _to); -//struct _DDS_HistoryQosPolicy { -// enum _DDS_HistoryQosPolicyKind kind; -// c_long depth; -//}; - -struct _DDS_ResourceLimitsQosPolicy; -//OMG_DDS_API v_copyin_result __DDS_ResourceLimitsQosPolicy__copyIn(c_type dbType, const dds::core::policy::ResourceLimits *from, struct _DDS_ResourceLimitsQosPolicy *to); -OMG_DDS_API void __DDS_ResourceLimitsQosPolicy__copyOut( - const void* _from, - void* _to); -//struct _DDS_ResourceLimitsQosPolicy { -// c_long max_samples; -// c_long max_instances; -// c_long max_samples_per_instance; -//}; - -#ifdef OMG_DDS_PERSISTENCE_SUPPORT -struct _DDS_DurabilityServiceQosPolicy; -//OMG_DDS_API v_copyin_result __DDS_DurabilityServiceQosPolicy__copyIn(c_type dbType, const dds::core::policy::DurabilityService *from, struct _DDS_DurabilityServiceQosPolicy *to); -OMG_DDS_API void __DDS_DurabilityServiceQosPolicy__copyOut( - const void* _from, - void* _to); -//struct _DDS_DurabilityServiceQosPolicy { -// struct _DDS_Duration_t service_cleanup_delay; -// enum _DDS_HistoryQosPolicyKind history_kind; -// c_long history_depth; -// c_long max_samples; -// c_long max_instances; -// c_long max_samples_per_instance; -//}; -#endif // OMG_DDS_PERSISTENCE_SUPPORT - -struct _DDS_ProductDataQosPolicy; -//OMG_DDS_API v_copyin_result __DDS_ProductDataQosPolicy__copyIn(c_type dbType, const org::opensplice::core::policy::ProductData *from, struct _DDS_ProductDataQosPolicy *to); -OMG_DDS_API void __DDS_ProductDataQosPolicy__copyOut( - const void* _from, - void* _to); -//struct _DDS_ProductDataQosPolicy { -// c_string value; -//}; - -struct _DDS_EntityFactoryQosPolicy; -//OMG_DDS_API v_copyin_result __DDS_EntityFactoryQosPolicy__copyIn(c_type dbType, const dds::core::policy::EntityFactory *from, struct _DDS_EntityFactoryQosPolicy *to); -OMG_DDS_API void __DDS_EntityFactoryQosPolicy__copyOut( - const void* _from, - void* _to); -//struct _DDS_EntityFactoryQosPolicy { -// c_bool autoenable_created_entities; -//}; - -struct _DDS_ShareQosPolicy; -//OMG_DDS_API v_copyin_result __DDS_ShareQosPolicy__copyIn(c_type dbType, const org::opensplice::core::policy::Share *from, struct _DDS_ShareQosPolicy *to); -OMG_DDS_API void __DDS_ShareQosPolicy__copyOut( - const void* _from, - void* _to); -//struct _DDS_ShareQosPolicy { -// c_string name; -// c_bool enable; -//}; - -struct _DDS_WriterDataLifecycleQosPolicy; -//OMG_DDS_API v_copyin_result __DDS_WriterDataLifecycleQosPolicy__copyIn(c_type dbType, const dds::core::policy::WriterDataLifecycle *from, struct _DDS_WriterDataLifecycleQosPolicy *to); -OMG_DDS_API void __DDS_WriterDataLifecycleQosPolicy__copyOut( - const void* _from, - void* _to); -//struct _DDS_WriterDataLifecycleQosPolicy { -// c_bool autodispose_unregistered_instances; -// struct _DDS_Duration_t autopurge_suspended_samples_delay; -// struct _DDS_Duration_t autounregister_instance_delay; -//}; - -enum _DDS_InvalidSampleVisibilityQosPolicyKind -{ - _DDS_NO_INVALID_SAMPLES, - _DDS_MINIMUM_INVALID_SAMPLES, - _DDS_ALL_INVALID_SAMPLES -}; -struct _DDS_InvalidSampleVisibilityQosPolicy; -//OMG_DDS_API v_copyin_result __DDS_InvalidSampleVisibilityQosPolicy__copyIn(c_type dbType, const org::opensplice::core::policy::InvalidSampleVisibility *from, struct _DDS_InvalidSampleVisibilityQosPolicy *to); -OMG_DDS_API void __DDS_InvalidSampleVisibilityQosPolicy__copyOut( - const void* _from, - void* _to); -struct _DDS_InvalidSampleVisibilityQosPolicy -{ - enum _DDS_InvalidSampleVisibilityQosPolicyKind kind; -}; - -struct _DDS_SubscriptionKeyQosPolicy; -//OMG_DDS_API v_copyin_result __DDS_SubscriptionKeyQosPolicy__copyIn(c_type dbType, const org::opensplice::core::policy::SubscriptionKey *from, struct _DDS_SubscriptionKeyQosPolicy *to); -OMG_DDS_API void __DDS_SubscriptionKeyQosPolicy__copyOut( - const void* _from, - void* _to); -//struct _DDS_SubscriptionKeyQosPolicy { -// c_bool use_key_list; -// _DDS_StringSeq key_list; -//}; - -struct _DDS_ReaderDataLifecycleQosPolicy; -//OMG_DDS_API v_copyin_result __DDS_ReaderDataLifecycleQosPolicy__copyIn(c_type dbType, const dds::core::policy::ReaderDataLifecycle *from, struct _DDS_ReaderDataLifecycleQosPolicy *to); -OMG_DDS_API void __DDS_ReaderDataLifecycleQosPolicy__copyOut( - const void* _from, - void* _to); -//struct _DDS_ReaderDataLifecycleQosPolicy { -// struct _DDS_Duration_t autopurge_nowriter_samples_delay; -// struct _DDS_Duration_t autopurge_disposed_samples_delay; -// c_bool autopurge_dispose_all; -// c_bool enable_invalid_samples; -// struct _DDS_InvalidSampleVisibilityQosPolicy invalid_sample_visibility; -//}; - -struct _DDS_UserKeyQosPolicy; -//OMG_DDS_API v_copyin_result __DDS_UserKeyQosPolicy__copyIn(c_type dbType, const org::opensplice::core::policy::SubscriptionKey *from, struct _DDS_UserKeyQosPolicy *to); -OMG_DDS_API void __DDS_UserKeyQosPolicy__copyOut( - const void* _from, - void* _to); -//struct _DDS_UserKeyQosPolicy { -// c_bool enable; -// c_string expression; -//}; - -struct _DDS_ReaderLifespanQosPolicy; -//OMG_DDS_API v_copyin_result __DDS_ReaderLifespanQosPolicy__copyIn(c_type dbType, const org::opensplice::core::policy::ReaderLifespan *from, struct _DDS_ReaderLifespanQosPolicy *to); -OMG_DDS_API void __DDS_ReaderLifespanQosPolicy__copyOut( - const void* _from, - void* _to); -//struct _DDS_ReaderLifespanQosPolicy { -// c_bool use_lifespan; -// struct _DDS_Duration_t duration; -//}; - -struct _DDS_TypeHash; -//OMG_DDS_API v_copyin_result __DDS_TypeHash__copyIn(c_type dbType, const class org::opensplice::topic::TypeHash *from, struct _DDS_TypeHash *to); -OMG_DDS_API void __DDS_TypeHash__copyOut( - const void* _from, - void* _to); -//struct _DDS_TypeHash { -// c_ulonglong msb; -// c_ulonglong lsb; -//}; - -struct _DDS_ParticipantBuiltinTopicData; -//OMG_DDS_API v_copyin_result __DDS_ParticipantBuiltinTopicData__copyIn(c_type dbType, const dds::topic::ParticipantBuiltinTopicData *from, struct _DDS_ParticipantBuiltinTopicData *to); -OMG_DDS_API void __DDS_ParticipantBuiltinTopicData__copyOut( - const void* _from, - void* _to); -//struct _DDS_ParticipantBuiltinTopicData { -// _DDS_BuiltinTopicKey_t key; -// struct _DDS_UserDataQosPolicy user_data; -//}; - -struct _DDS_TopicBuiltinTopicData; -//OMG_DDS_API v_copyin_result __DDS_TopicBuiltinTopicData__copyIn(c_type dbType, const dds::topic::TopicBuiltinTopicData *from, struct _DDS_TopicBuiltinTopicData *to); -OMG_DDS_API void __DDS_TopicBuiltinTopicData__copyOut( - const void* _from, - void* _to); -//struct _DDS_TopicBuiltinTopicData { -// _DDS_BuiltinTopicKey_t key; -// c_string name; -// c_string type_name; -// struct _DDS_DurabilityQosPolicy durability; -// struct _DDS_DurabilityServiceQosPolicy durability_service; -// struct _DDS_DeadlineQosPolicy deadline; -// struct _DDS_LatencyBudgetQosPolicy latency_budget; -// struct _DDS_LivelinessQosPolicy liveliness; -// struct _DDS_ReliabilityQosPolicy reliability; -// struct _DDS_TransportPriorityQosPolicy transport_priority; -// struct _DDS_LifespanQosPolicy lifespan; -// struct _DDS_DestinationOrderQosPolicy destination_order; -// struct _DDS_HistoryQosPolicy history; -// struct _DDS_ResourceLimitsQosPolicy resource_limits; -// struct _DDS_OwnershipQosPolicy ownership; -// struct _DDS_TopicDataQosPolicy topic_data; -//}; - -struct _DDS_TypeBuiltinTopicData; -//OMG_DDS_API v_copyin_result __DDS_TypeBuiltinTopicData__copyIn(c_type dbType, const org::opensplice::topic::TypeBuiltinTopicData *from, struct _DDS_TypeBuiltinTopicData *to); -OMG_DDS_API void __DDS_TypeBuiltinTopicData__copyOut( - const void* _from, - void* _to); -//struct _DDS_TypeBuiltinTopicData { -// c_string name; -// _DDS_DataRepresentationId_t data_representation_id; -// struct _DDS_TypeHash type_hash; -// _DDS_octSeq meta_data; -// _DDS_octSeq extentions; -//}; - -struct _DDS_PublicationBuiltinTopicData; -//OMG_DDS_API v_copyin_result __DDS_PublicationBuiltinTopicData__copyIn(c_type dbType, const dds::topic::PublicationBuiltinTopicData *from, struct _DDS_PublicationBuiltinTopicData *to); -OMG_DDS_API void __DDS_PublicationBuiltinTopicData__copyOut( - const void* _from, - void* _to); -//struct _DDS_PublicationBuiltinTopicData { -// _DDS_BuiltinTopicKey_t key; -// _DDS_BuiltinTopicKey_t participant_key; -// c_string topic_name; -// c_string type_name; -// struct _DDS_DurabilityQosPolicy durability; -// struct _DDS_DeadlineQosPolicy deadline; -// struct _DDS_LatencyBudgetQosPolicy latency_budget; -// struct _DDS_LivelinessQosPolicy liveliness; -// struct _DDS_ReliabilityQosPolicy reliability; -// struct _DDS_LifespanQosPolicy lifespan; -// struct _DDS_DestinationOrderQosPolicy destination_order; -// struct _DDS_UserDataQosPolicy user_data; -// struct _DDS_OwnershipQosPolicy ownership; -// struct _DDS_OwnershipStrengthQosPolicy ownership_strength; -// struct _DDS_PresentationQosPolicy presentation; -// struct _DDS_PartitionQosPolicy partition; -// struct _DDS_TopicDataQosPolicy topic_data; -// struct _DDS_GroupDataQosPolicy group_data; -//}; - -struct _DDS_SubscriptionBuiltinTopicData; -//OMG_DDS_API v_copyin_result __DDS_SubscriptionBuiltinTopicData__copyIn(c_type dbType, const dds::topic::SubscriptionBuiltinTopicData *from, struct _DDS_SubscriptionBuiltinTopicData *to); -OMG_DDS_API void __DDS_SubscriptionBuiltinTopicData__copyOut( - const void* _from, - void* _to); -//struct _DDS_SubscriptionBuiltinTopicData { -// _DDS_BuiltinTopicKey_t key; -// _DDS_BuiltinTopicKey_t participant_key; -// c_string topic_name; -// c_string type_name; -// struct _DDS_DurabilityQosPolicy durability; -// struct _DDS_DeadlineQosPolicy deadline; -// struct _DDS_LatencyBudgetQosPolicy latency_budget; -// struct _DDS_LivelinessQosPolicy liveliness; -// struct _DDS_ReliabilityQosPolicy reliability; -// struct _DDS_OwnershipQosPolicy ownership; -// struct _DDS_DestinationOrderQosPolicy destination_order; -// struct _DDS_UserDataQosPolicy user_data; -// struct _DDS_TimeBasedFilterQosPolicy time_based_filter; -// struct _DDS_PresentationQosPolicy presentation; -// struct _DDS_PartitionQosPolicy partition; -// struct _DDS_TopicDataQosPolicy topic_data; -// struct _DDS_GroupDataQosPolicy group_data; -//}; - -struct _DDS_CMParticipantBuiltinTopicData; -//OMG_DDS_API v_copyin_result __DDS_CMParticipantBuiltinTopicData__copyIn(c_type dbType, const org::opensplice::topic::CMParticipantBuiltinTopicData *from, struct _DDS_CMParticipantBuiltinTopicData *to); -OMG_DDS_API void __DDS_CMParticipantBuiltinTopicData__copyOut( - const void* _from, - void* _to); -//struct _DDS_CMParticipantBuiltinTopicData { -// _DDS_BuiltinTopicKey_t key; -// struct _DDS_ProductDataQosPolicy product; -//}; - - -struct _DDS_CMPublisherBuiltinTopicData; -//OMG_DDS_API v_copyin_result __DDS_CMPublisherBuiltinTopicData__copyIn(c_type dbType, const org::opensplice::topic::CMPublisherBuiltinTopicData *from, struct _DDS_CMPublisherBuiltinTopicData *to); -OMG_DDS_API void __DDS_CMPublisherBuiltinTopicData__copyOut( - const void* _from, - void* _to); -//struct _DDS_CMPublisherBuiltinTopicData { -// _DDS_BuiltinTopicKey_t key; -// struct _DDS_ProductDataQosPolicy product; -// _DDS_BuiltinTopicKey_t participant_key; -// c_string name; -// struct _DDS_EntityFactoryQosPolicy entity_factory; -// struct _DDS_PartitionQosPolicy partition; -//}; - -struct _DDS_CMSubscriberBuiltinTopicData; -//OMG_DDS_API v_copyin_result __DDS_CMSubscriberBuiltinTopicData__copyIn(c_type dbType, const org::opensplice::topic::CMSubscriberBuiltinTopicData *from, struct _DDS_CMSubscriberBuiltinTopicData *to); -OMG_DDS_API void __DDS_CMSubscriberBuiltinTopicData__copyOut( - const void* _from, - void* _to); -//struct _DDS_CMSubscriberBuiltinTopicData { -// _DDS_BuiltinTopicKey_t key; -// struct _DDS_ProductDataQosPolicy product; -// _DDS_BuiltinTopicKey_t participant_key; -// c_string name; -// struct _DDS_EntityFactoryQosPolicy entity_factory; -// struct _DDS_ShareQosPolicy share; -// struct _DDS_PartitionQosPolicy partition; -//}; - -struct _DDS_CMDataWriterBuiltinTopicData; -//OMG_DDS_API v_copyin_result __DDS_CMDataWriterBuiltinTopicData__copyIn(c_type dbType, const org::opensplice::topic::CMDataWriterBuiltinTopicData *from, struct _DDS_CMDataWriterBuiltinTopicData *to); -OMG_DDS_API void __DDS_CMDataWriterBuiltinTopicData__copyOut( - const void* _from, - void* _to); -//struct _DDS_CMDataWriterBuiltinTopicData { -// _DDS_BuiltinTopicKey_t key; -// struct _DDS_ProductDataQosPolicy product; -// _DDS_BuiltinTopicKey_t publisher_key; -// c_string name; -// struct _DDS_HistoryQosPolicy history; -// struct _DDS_ResourceLimitsQosPolicy resource_limits; -// struct _DDS_WriterDataLifecycleQosPolicy writer_data_lifecycle; -//}; - -struct _DDS_CMDataReaderBuiltinTopicData; -//OMG_DDS_API v_copyin_result __DDS_CMDataReaderBuiltinTopicData__copyIn(c_type dbType, const org::opensplice::topic::CMDataReaderBuiltinTopicData *from, struct _DDS_CMDataReaderBuiltinTopicData *to); -OMG_DDS_API void __DDS_CMDataReaderBuiltinTopicData__copyOut( - const void* _from, - void* _to); -//struct _DDS_CMDataReaderBuiltinTopicData { -// _DDS_BuiltinTopicKey_t key; -// struct _DDS_ProductDataQosPolicy product; -// _DDS_BuiltinTopicKey_t subscriber_key; -// c_string name; -// struct _DDS_HistoryQosPolicy history; -// struct _DDS_ResourceLimitsQosPolicy resource_limits; -// struct _DDS_ReaderDataLifecycleQosPolicy reader_data_lifecycle; -// struct _DDS_UserKeyQosPolicy subscription_keys; -// struct _DDS_ReaderLifespanQosPolicy reader_lifespan; -// struct _DDS_ShareQosPolicy share; -//}; - - - -#endif //EPROSIMA_DDS_BUILTINTOPICSSPLTYPES_H_ diff --git a/include/dds/core/detail/dds_builtinTopics_DCPS.hpp b/include/dds/core/detail/dds_builtinTopics_DCPS.hpp deleted file mode 100644 index f0b769b667e..00000000000 --- a/include/dds/core/detail/dds_builtinTopics_DCPS.hpp +++ /dev/null @@ -1,26 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_BUILTINTOPICS_HPP_ -#define EPROSIMA_DDS_BUILTINTOPICS_HPP_ - -#include "dds/dds.hpp" - -#include "dds/core/detail/dds_builtinTopics.h" -#include "dds/core/detail/dds_builtinTopicsSplDcps.h" - -#endif //EPROSIMA_DDS_BUILTINTOPICS_HPP_ diff --git a/include/dds/core/detail/dds_dcps_builtintopics.h b/include/dds/core/detail/dds_dcps_builtintopics.h deleted file mode 100644 index d6281dedd16..00000000000 --- a/include/dds/core/detail/dds_dcps_builtintopics.h +++ /dev/null @@ -1,41 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_DCPS_BUILTINTOPICS_H_ -#define EPROSIMA_DDS_DCPS_BUILTINTOPICS_H_ - -#include - -namespace DDS { -typedef dds::core::Time Time_t; - -// typedef org::opensplice::core::policy::SchedulingKind::Type SchedulingClassQosPolicyKind; -// typedef org::opensplice::core::policy::SchedulingKind::Type SchedulingClassQosPolicy; -// typedef org::opensplice::core::policy::SchedulingPriorityKind::Type SchedulingPriorityQosPolicyKind; -// typedef org::opensplice::core::policy::SchedulingPriorityKind::Type SchedulingPriorityQosPolicy; -// typedef org::opensplice::core::policy::TScheduling< -// org::opensplice::core::policy::SchedulingDelegate> SchedulingQosPolicy; - -typedef dds::domain::qos::DomainParticipantQos DomainParticipantQos; -typedef dds::topic::qos::TopicQos TopicQos; -typedef dds::pub::qos::DataWriterQos DataWriterQos; -typedef dds::pub::qos::PublisherQos PublisherQos; -typedef dds::sub::qos::DataReaderQos DataReaderQos; -typedef dds::sub::qos::SubscriberQos SubscriberQos; -} //namespace DDS - -#endif //EPROSIMA_DDS_DCPS_BUILTINTOPICS_H_ diff --git a/include/dds/core/detail/dds_dcps_builtintopicsSplDcps.h b/include/dds/core/detail/dds_dcps_builtintopicsSplDcps.h deleted file mode 100644 index f06a177d5b0..00000000000 --- a/include/dds/core/detail/dds_dcps_builtintopicsSplDcps.h +++ /dev/null @@ -1,178 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_DCPS_BUILTINTOPICSSPLTYPES_H_ -#define EPROSIMA_DDS_DCPS_BUILTINTOPICSSPLTYPES_H_ - -#include - -struct _DDS_Time_t; -//OMG_DDS_API v_copyin_result __DDS_Time_t__copyIn(c_type dbType, const dds::core::Time *from, struct _DDS_Time_t *to); -OMG_DDS_API void __DDS_Time_t__copyOut( - const void* _from, - void* _to); -//struct _DDS_Time_t { -// c_long sec; -// c_ulong nanosec; -//}; - -enum _DDS_SchedulingClassQosPolicyKind -{ - _DDS_SCHEDULE_DEFAULT, - _DDS_SCHEDULE_TIMESHARING, - _DDS_SCHEDULE_REALTIME -}; - -struct _DDS_SchedulingClassQosPolicy; -//OMG_DDS_API v_copyin_result __DDS_SchedulingClassQosPolicy__copyIn(c_type dbType, const org::opensplice::core::policy::SchedulingKind *from, struct _DDS_SchedulingClassQosPolicy *to); -OMG_DDS_API void __DDS_SchedulingClassQosPolicy__copyOut( - const void* _from, - void* _to); -//struct _DDS_SchedulingClassQosPolicy { -// enum _DDS_SchedulingClassQosPolicyKind kind; -//}; - -enum _DDS_SchedulingPriorityQosPolicyKind -{ - _DDS_PRIORITY_RELATIVE, - _DDS_PRIORITY_ABSOLUTE -}; - -struct _DDS_SchedulingPriorityQosPolicy; -//OMG_DDS_API v_copyin_result __DDS_SchedulingPriorityQosPolicy__copyIn(c_type dbType, const org::opensplice::core::policy::SchedulingPriorityKind *from, struct _DDS_SchedulingPriorityQosPolicy *to); -OMG_DDS_API void __DDS_SchedulingPriorityQosPolicy__copyOut( - const void* _from, - void* _to); -//struct _DDS_SchedulingPriorityQosPolicy { -// enum _DDS_SchedulingPriorityQosPolicyKind kind; -//}; - -struct _DDS_SchedulingQosPolicy; -//OMG_DDS_API v_copyin_result __DDS_SchedulingQosPolicy__copyIn(c_type dbType, const DDS::SchedulingQosPolicy *from, struct _DDS_SchedulingQosPolicy *to); -OMG_DDS_API void __DDS_SchedulingQosPolicy__copyOut( - const void* _from, - void* _to); -//struct _DDS_SchedulingQosPolicy { -// struct _DDS_SchedulingClassQosPolicy scheduling_class; -// struct _DDS_SchedulingPriorityQosPolicy scheduling_priority_kind; -// c_long scheduling_priority; -//}; - -struct _DDS_DomainParticipantQos; -//OMG_DDS_API v_copyin_result __DDS_DomainParticipantQos__copyIn(c_type dbType, const dds::domain::qos::DomainParticipantQos *from, struct _DDS_DomainParticipantQos *to); -OMG_DDS_API void __DDS_DomainParticipantQos__copyOut( - const void* _from, - void* _to); -//struct _DDS_DomainParticipantQos { -// struct _DDS_UserDataQosPolicy user_data; -// struct _DDS_EntityFactoryQosPolicy entity_factory; -// struct _DDS_SchedulingQosPolicy watchdog_scheduling; -// struct _DDS_SchedulingQosPolicy listener_scheduling; -//}; - -struct _DDS_TopicQos; -//OMG_DDS_API v_copyin_result __DDS_TopicQos__copyIn(c_type dbType, const dds::topic::qos::TopicQos *from, struct _DDS_TopicQos *to); -OMG_DDS_API void __DDS_TopicQos__copyOut( - const void* _from, - void* _to); -//struct _DDS_TopicQos { -// struct _DDS_TopicDataQosPolicy topic_data; -// struct _DDS_DurabilityQosPolicy durability; -// struct _DDS_DurabilityServiceQosPolicy durability_service; -// struct _DDS_DeadlineQosPolicy deadline; -// struct _DDS_LatencyBudgetQosPolicy latency_budget; -// struct _DDS_LivelinessQosPolicy liveliness; -// struct _DDS_ReliabilityQosPolicy reliability; -// struct _DDS_DestinationOrderQosPolicy destination_order; -// struct _DDS_HistoryQosPolicy history; -// struct _DDS_ResourceLimitsQosPolicy resource_limits; -// struct _DDS_TransportPriorityQosPolicy transport_priority; -// struct _DDS_LifespanQosPolicy lifespan; -// struct _DDS_OwnershipQosPolicy ownership; -//}; - -struct _DDS_DataWriterQos; -//OMG_DDS_API v_copyin_result __DDS_DataWriterQos__copyIn(c_type dbType, const dds::pub::qos::DataWriterQos *from, struct _DDS_DataWriterQos *to); -OMG_DDS_API void __DDS_DataWriterQos__copyOut( - const void* _from, - void* _to); -//struct _DDS_DataWriterQos { -// struct _DDS_DurabilityQosPolicy durability; -// struct _DDS_DeadlineQosPolicy deadline; -// struct _DDS_LatencyBudgetQosPolicy latency_budget; -// struct _DDS_LivelinessQosPolicy liveliness; -// struct _DDS_ReliabilityQosPolicy reliability; -// struct _DDS_DestinationOrderQosPolicy destination_order; -// struct _DDS_HistoryQosPolicy history; -// struct _DDS_ResourceLimitsQosPolicy resource_limits; -// struct _DDS_TransportPriorityQosPolicy transport_priority; -// struct _DDS_LifespanQosPolicy lifespan; -// struct _DDS_UserDataQosPolicy user_data; -// struct _DDS_OwnershipQosPolicy ownership; -// struct _DDS_OwnershipStrengthQosPolicy ownership_strength; -// struct _DDS_WriterDataLifecycleQosPolicy writer_data_lifecycle; -//}; - -struct _DDS_PublisherQos; -//OMG_DDS_API v_copyin_result __DDS_PublisherQos__copyIn(c_type dbType, const dds::pub::qos::PublisherQos *from, struct _DDS_PublisherQos *to); -OMG_DDS_API void __DDS_PublisherQos__copyOut( - const void* _from, - void* _to); -//struct _DDS_PublisherQos { -// struct _DDS_PresentationQosPolicy presentation; -// struct _DDS_PartitionQosPolicy partition; -// struct _DDS_GroupDataQosPolicy group_data; -// struct _DDS_EntityFactoryQosPolicy entity_factory; -//}; - -struct _DDS_DataReaderQos; -//OMG_DDS_API v_copyin_result __DDS_DataReaderQos__copyIn(c_type dbType, const dds::sub::qos::DataReaderQos *from, struct _DDS_DataReaderQos *to); -OMG_DDS_API void __DDS_DataReaderQos__copyOut( - const void* _from, - void* _to); -//struct _DDS_DataReaderQos { -// struct _DDS_DurabilityQosPolicy durability; -// struct _DDS_DeadlineQosPolicy deadline; -// struct _DDS_LatencyBudgetQosPolicy latency_budget; -// struct _DDS_LivelinessQosPolicy liveliness; -// struct _DDS_ReliabilityQosPolicy reliability; -// struct _DDS_DestinationOrderQosPolicy destination_order; -// struct _DDS_HistoryQosPolicy history; -// struct _DDS_ResourceLimitsQosPolicy resource_limits; -// struct _DDS_UserDataQosPolicy user_data; -// struct _DDS_OwnershipQosPolicy ownership; -// struct _DDS_TimeBasedFilterQosPolicy time_based_filter; -// struct _DDS_ReaderDataLifecycleQosPolicy reader_data_lifecycle; -// struct _DDS_SubscriptionKeyQosPolicy subscription_keys; -// struct _DDS_ReaderLifespanQosPolicy reader_lifespan; -// struct _DDS_ShareQosPolicy share; -//}; - -struct _DDS_SubscriberQos; -//OMG_DDS_API v_copyin_result __DDS_SubscriberQos__copyIn(c_type dbType, const dds::sub::qos::SubscriberQos *from, struct _DDS_SubscriberQos *to); -OMG_DDS_API void __DDS_SubscriberQos__copyOut( - const void* _from, - void* _to); -//struct _DDS_SubscriberQos { -// struct _DDS_PresentationQosPolicy presentation; -// struct _DDS_PartitionQosPolicy partition; -// struct _DDS_GroupDataQosPolicy group_data; -// struct _DDS_EntityFactoryQosPolicy entity_factory; -// struct _DDS_ShareQosPolicy share; -//}; - -#endif //EPROSIMA_DDS_DCPS_BUILTINTOPICSSPLTYPES_H_ diff --git a/include/dds/core/detail/dds_dcps_builtintopics_DCPS.hpp b/include/dds/core/detail/dds_dcps_builtintopics_DCPS.hpp deleted file mode 100644 index d6a2c5c0837..00000000000 --- a/include/dds/core/detail/dds_dcps_builtintopics_DCPS.hpp +++ /dev/null @@ -1,24 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_DCPS_BUILTINTOPICS_DCPS_HPP_ -#define EPROSIMA_DDS_DCPS_BUILTINTOPICS_DCPS_HPP_ - -#include "dds/core/detail/dds_dcps_builtintopics.h" -#include "dds/core/detail/dds_dcps_builtintopicsSplDcps.h" - -#endif //EPROSIMA_DDS_DCPS_BUILTINTOPICS_DCPS_HPP_ diff --git a/include/dds/core/detail/ddscore.hpp b/include/dds/core/detail/ddscore.hpp deleted file mode 100644 index 25aaf457bf5..00000000000 --- a/include/dds/core/detail/ddscore.hpp +++ /dev/null @@ -1,23 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_CORE_PACKAGE_DETAIL_INCLUDE_HPP_ -#define EPROSIMA_DDS_CORE_PACKAGE_DETAIL_INCLUDE_HPP_ - -/* Nothing to 'post' include. */ - -#endif //EPROSIMA_DDS_CORE_PACKAGE_DETAIL_INCLUDE_HPP_ diff --git a/include/dds/core/detail/inttypes.hpp b/include/dds/core/detail/inttypes.hpp deleted file mode 100644 index 226a0a409aa..00000000000 --- a/include/dds/core/detail/inttypes.hpp +++ /dev/null @@ -1,24 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_CORE_DETAIL_INTTYPES_HPP_ -#define EPROSIMA_DDS_CORE_DETAIL_INTTYPES_HPP_ - -#include - -#endif //EPROSIMA_DDS_CORE_DETAIL_INTTYPES_HPP_ - diff --git a/include/dds/core/detail/macros.hpp b/include/dds/core/detail/macros.hpp deleted file mode 100644 index 5c1446be7bd..00000000000 --- a/include/dds/core/detail/macros.hpp +++ /dev/null @@ -1,44 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_CORE_DETAIL_MACROS_HPP_ -#define EPROSIMA_DDS_CORE_DETAIL_MACROS_HPP_ - -#include - -#include - -// Constants -#define OMG_DDS_DEFAULT_STATE_BIT_COUNT_DETAIL size_t(16) -#define OMG_DDS_DEFAULT_STATUS_COUNT_DETAIL size_t(16) -// ========================================================================== - -// Static Assert -#define OMG_DDS_STATIC_ASSERT_DETAIL(...) static_assert(__VA_ARGS__, #__VA_ARGS__) -// ========================================================================== - -// Logging Macros -#define OMG_DDS_LOG_DETAIL(kind, msg) \ - std::cout << "[" << kind << "]: " << msg << std::endl; -// ========================================================================== - - -#define OMG_DDS_API_DETAIL RTPS_DllAPI -// ========================================================================== - - -#endif //EPROSIMA_DDS_CORE_DETAIL_MACROS_HPP_ diff --git a/include/dds/core/detail/module_docs.hpp b/include/dds/core/detail/module_docs.hpp deleted file mode 100644 index 534e274d0f9..00000000000 --- a/include/dds/core/detail/module_docs.hpp +++ /dev/null @@ -1,165 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_CORE_DETAIL_MODULE_DOCS_HPP_ -#define EPROSIMA_DDS_CORE_DETAIL_MODULE_DOCS_HPP_ - -/** - * @file - * This file exists only to be fed to doxygen. There is quite - * literally nothing else to see here. - */ - -/** - * @addtogroup isocpp2_dcps ISO/IEC C++ 2 API for DDS Data-centric Publish-Subscribe (DCPS) - */ -/** @{*/ -/** @dir dds */ -/** @}*/ - -/** - * @addtogroup isocpp2_dcps_domain Domain Module - ::dds::domain - * @ingroup isocpp2_dcps */ -/** @{*/ -/** @dir dds/domain */ -/** @}*/ - - -/** - * @addtogroup isocpp2_dcps_topic Topic Module- ::dds::topic - * @ingroup isocpp2_dcps */ -/** @{*/ -/** @dir dds/topic */ -/** @}*/ - -/** - * @addtogroup isocpp2_dcps_pub Publication Module - ::dds::pub - * @ingroup isocpp2_dcps */ -/** @{*/ -/** @dir dds/pub */ -/** @}*/ - - -/** - * @addtogroup isocpp2_dcps_sub Subscription Module - ::dds::sub - * @ingroup isocpp2_dcps */ -/** @{*/ -/** @dir dds/sub */ -/** @}*/ - -/** - * @addtogroup isocpp2_dcps_core Core / Common Module - ::dds::core - * @ingroup isocpp2_dcps */ -/** @{*/ -/** @dir dds/core */ -/** @}*/ - - -/** - * @addtogroup examplesdcpsisocpp ISO/IEC C++ DCPS PSM Examples - */ -/** @{*/ -/** @dir examples/common */ -/** @}*/ - - - -/** - * @ingroup isocpp2_dcps - */ -namespace dds { -/** - * @ingroup isocpp2_dcps_domain - * @ingroup isocpp2_dcps */ -namespace domain { -/** @ingroup isocpp2_dcps_domain - * @ingroup isocpp2_dcps */ -namespace qos { -namespace detail {} -} //namespace qos -namespace detail {} -} //namespace domain -/** - * @ingroup isocpp2_dcps_topic - * @ingroup isocpp2_dcps */ -namespace topic { -/** @ingroup isocpp2_dcps_topic - * @ingroup isocpp2_dcps */ -namespace qos { -namespace detail {} -} //namespace qos -namespace detail {} -} //namespace topic -/** - * @ingroup isocpp2_dcps_pub - * @ingroup isocpp2_dcps */ -namespace pub { -/** @ingroup isocpp2_dcps_pub - * @ingroup isocpp2_dcps */ -namespace qos { -namespace detail {} -} //namespace qos -namespace detail {} -} //namespace pub -/** - * @ingroup isocpp2_dcps_sub - * @ingroup isocpp2_dcps */ -namespace sub { -/** @ingroup isocpp2_dcps_sub - * @ingroup isocpp2_dcps */ -namespace cond { -namespace detail {} -} //namespace cond -/** @ingroup isocpp2_dcps_sub - * @ingroup isocpp2_dcps */ -namespace functors { -namespace detail {} -} //namespace functors -/** @ingroup isocpp2_dcps_sub - * @ingroup isocpp2_dcps */ -namespace status {} -/** @ingroup isocpp2_dcps_sub - * @ingroup isocpp2_dcps */ -namespace qos { -namespace detail {} -} //namespace qos -} //namespace sub -/** - * @ingroup isocpp2_dcps_core - * @ingroup isocpp2_dcps */ -namespace core { -/** @ingroup isocpp2_dcps_core - * @ingroup isocpp2_dcps */ -namespace policy { -namespace detail {} -} //namespace policy -/** @ingroup isocpp2_dcps_core - * @ingroup isocpp2_dcps */ -namespace cond { -namespace detail {} -} //namespace cond -/** @ingroup isocpp2_dcps_core - * @ingroup isocpp2_dcps */ -namespace status { -namespace detail {} -} //namespace status -namespace detail {} -} //namespace core -} //namespace dds - - -#endif //EPROSIMA_DDS_CORE_DETAIL_MODULE_DOCS_HPP_ diff --git a/include/dds/core/detail/old_win_stdint.h b/include/dds/core/detail/old_win_stdint.h deleted file mode 100644 index 26fa0a1b7b3..00000000000 --- a/include/dds/core/detail/old_win_stdint.h +++ /dev/null @@ -1,247 +0,0 @@ -/** - * @file - * This file provides definitions for stdint header types for versions of - * Windows that didn't have it. It was discovered on the intahwebs at - * http://snipplr.com/view/18199/stdinth/ where it was described thus: - * "A public domain stdint.h. Original code is from a public domain version - * in the MinGW distribution. This one has been modified to fix a couple bugs - * (to make some macros 64-bit aware) and to make it compatible with VC6." - * It was published there on 08/12/09 - * @see dds/core/detail/inttypes.h - */ - -/* ISO C9x 7.18 Integer types - * Based on ISO/IEC SC22/WG14 9899 Committee draft (SC22 N2794) - * - * THIS SOFTWARE IS NOT COPYRIGHTED - * - * Contributor: Danny Smith - * - * This source code is offered for use in the public domain. You may - * use, modify or distribute it freely. - * - * This code is distributed in the hope that it will be useful but - * WITHOUT ANY WARRANTY. ALL WARRANTIES, EXPRESS OR IMPLIED ARE HEREBY - * DISCLAIMED. This includes but is not limited to warranties of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. - * - * Date: 2000-12-02 - * - * mwb: This was modified in the following ways: - * - * - make it compatible with Visual C++ 6 (which uses - * non-standard keywords and suffixes for 64-bit types) - * - some environments need stddef.h included (for wchar stuff?) - * - handle the fact that Microsoft's limits.h header defines - * SIZE_MAX - * - make corrections for SIZE_MAX, INTPTR_MIN, INTPTR_MAX, UINTPTR_MAX, - * PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, and SIG_ATOMIC_MAX - * to be 64-bit aware. - */ - - -#ifndef _STDINT_H -#define _STDINT_H -#define __need_wint_t -#define __need_wchar_t -#include -#include - -#if _MSC_VER && (_MSC_VER < 1300) -/* using MSVC 6 or earlier - no "long long" type, but might have _int64 type */ -#define __STDINT_LONGLONG __int64 -#define __STDINT_LONGLONG_SUFFIX i64 -#else -#define __STDINT_LONGLONG long long -#define __STDINT_LONGLONG_SUFFIX LL -#endif - -#if !defined( PASTE) -#define PASTE2( x, y) x ## y -#define PASTE( x, y) PASTE2( x, y) -#endif /* PASTE */ - - -/* 7.18.1.1 Exact-width integer types */ -typedef signed char int8_t; -typedef unsigned char uint8_t; -typedef short int16_t; -typedef unsigned short uint16_t; -typedef int int32_t; -typedef unsigned uint32_t; -typedef __STDINT_LONGLONG int64_t; -typedef unsigned __STDINT_LONGLONG uint64_t; - -/* 7.18.1.2 Minimum-width integer types */ -typedef signed char int_least8_t; -typedef unsigned char uint_least8_t; -typedef short int_least16_t; -typedef unsigned short uint_least16_t; -typedef int int_least32_t; -typedef unsigned uint_least32_t; -typedef __STDINT_LONGLONG int_least64_t; -typedef unsigned __STDINT_LONGLONG uint_least64_t; - -/* 7.18.1.3 Fastest minimum-width integer types - * Not actually guaranteed to be fastest for all purposes - * Here we use the exact-width types for 8 and 16-bit ints. - */ -typedef char int_fast8_t; -typedef unsigned char uint_fast8_t; -typedef short int_fast16_t; -typedef unsigned short uint_fast16_t; -typedef int int_fast32_t; -typedef unsigned int uint_fast32_t; -typedef __STDINT_LONGLONG int_fast64_t; -typedef unsigned __STDINT_LONGLONG uint_fast64_t; - -/* 7.18.1.4 Integer types capable of holding object pointers */ -#ifndef _INTPTR_T_DEFINED -#define _INTPTR_T_DEFINED -#ifdef _WIN64 -typedef __STDINT_LONGLONG intptr_t -#else -typedef int intptr_t; -#endif /* _WIN64 */ -#endif /* _INTPTR_T_DEFINED */ - -#ifndef _UINTPTR_T_DEFINED -#define _UINTPTR_T_DEFINED -#ifdef _WIN64 -typedef unsigned __STDINT_LONGLONG uintptr_t -#else -typedef unsigned int uintptr_t; -#endif /* _WIN64 */ -#endif /* _UINTPTR_T_DEFINED */ - -/* 7.18.1.5 Greatest-width integer types */ -typedef __STDINT_LONGLONG intmax_t; -typedef unsigned __STDINT_LONGLONG uintmax_t; - -/* 7.18.2 Limits of specified-width integer types */ -#if !defined ( __cplusplus) || defined (__STDC_LIMIT_MACROS) - -/* 7.18.2.1 Limits of exact-width integer types */ -#define INT8_MIN (-128) -#define INT16_MIN (-32768) -#define INT32_MIN (-2147483647 - 1) -#define INT64_MIN (PASTE( -9223372036854775807, __STDINT_LONGLONG_SUFFIX) - 1) - -#define INT8_MAX 127 -#define INT16_MAX 32767 -#define INT32_MAX 2147483647 -#define INT64_MAX (PASTE( 9223372036854775807, __STDINT_LONGLONG_SUFFIX)) - -#define UINT8_MAX 0xff /* 255U */ -#define UINT16_MAX 0xffff /* 65535U */ -#define UINT32_MAX 0xffffffff /* 4294967295U */ -#define UINT64_MAX (PASTE( 0xffffffffffffffffU, __STDINT_LONGLONG_SUFFIX)) /* 18446744073709551615ULL */ - -/* 7.18.2.2 Limits of minimum-width integer types */ -#define INT_LEAST8_MIN INT8_MIN -#define INT_LEAST16_MIN INT16_MIN -#define INT_LEAST32_MIN INT32_MIN -#define INT_LEAST64_MIN INT64_MIN - -#define INT_LEAST8_MAX INT8_MAX -#define INT_LEAST16_MAX INT16_MAX -#define INT_LEAST32_MAX INT32_MAX -#define INT_LEAST64_MAX INT64_MAX - -#define UINT_LEAST8_MAX UINT8_MAX -#define UINT_LEAST16_MAX UINT16_MAX -#define UINT_LEAST32_MAX UINT32_MAX -#define UINT_LEAST64_MAX UINT64_MAX - -/* 7.18.2.3 Limits of fastest minimum-width integer types */ -#define INT_FAST8_MIN INT8_MIN -#define INT_FAST16_MIN INT16_MIN -#define INT_FAST32_MIN INT32_MIN -#define INT_FAST64_MIN INT64_MIN - -#define INT_FAST8_MAX INT8_MAX -#define INT_FAST16_MAX INT16_MAX -#define INT_FAST32_MAX INT32_MAX -#define INT_FAST64_MAX INT64_MAX - -#define UINT_FAST8_MAX UINT8_MAX -#define UINT_FAST16_MAX UINT16_MAX -#define UINT_FAST32_MAX UINT32_MAX -#define UINT_FAST64_MAX UINT64_MAX - -/* 7.18.2.4 Limits of integer types capable of holding - object pointers */ -#ifdef _WIN64 -#define INTPTR_MIN INT64_MIN -#define INTPTR_MAX INT64_MAX -#define UINTPTR_MAX UINT64_MAX -#else -#define INTPTR_MIN INT32_MIN -#define INTPTR_MAX INT32_MAX -#define UINTPTR_MAX UINT32_MAX -#endif /* _WIN64 */ - -/* 7.18.2.5 Limits of greatest-width integer types */ -#define INTMAX_MIN INT64_MIN -#define INTMAX_MAX INT64_MAX -#define UINTMAX_MAX UINT64_MAX - -/* 7.18.3 Limits of other integer types */ -#define PTRDIFF_MIN INTPTR_MIN -#define PTRDIFF_MAX INTPTR_MAX - -#define SIG_ATOMIC_MIN INTPTR_MIN -#define SIG_ATOMIC_MAX INTPTR_MAX - -/* we need to check for SIZE_MAX already defined because MS defines it in limits.h */ -#ifndef SIZE_MAX -#define SIZE_MAX UINTPTR_MAX -#endif - -#ifndef WCHAR_MIN /* also in wchar.h */ -#define WCHAR_MIN 0 -#define WCHAR_MAX ((wchar_t)-1) /* UINT16_MAX */ -#endif - -/* - * wint_t is unsigned short for compatibility with MS runtime - */ -#define WINT_MIN 0 -#define WINT_MAX ((wint_t)-1) /* UINT16_MAX */ - -#endif /* !defined ( __cplusplus) || defined __STDC_LIMIT_MACROS */ - - -/* 7.18.4 Macros for integer constants */ -#if !defined ( __cplusplus) || defined (__STDC_CONSTANT_MACROS) - -/* 7.18.4.1 Macros for minimum-width integer constants - - Accoding to Douglas Gwyn : - "This spec was changed in ISO/IEC 9899:1999 TC1; in ISO/IEC - 9899:1999 as initially published, the expansion was required - to be an integer constant of precisely matching type, which - is impossible to accomplish for the shorter types on most - platforms, because C99 provides no standard way to designate - an integer constant with width less than that of type int. - TC1 changed this to require just an integer constant - * expression* with *promoted* type." - */ - -#define INT8_C(val) ((int8_t) + (val)) -#define UINT8_C(val) ((uint8_t) + (val ## U)) -#define INT16_C(val) ((int16_t) + (val)) -#define UINT16_C(val) ((uint16_t) + (val ## U)) - -#define INT32_C(val) val ## L -#define UINT32_C(val) val ## UL -#define INT64_C(val) (PASTE( val, __STDINT_LONGLONG_SUFFIX)) -#define UINT64_C(val)(PASTE( PASTE( val, U), __STDINT_LONGLONG_SUFFIX)) - -/* 7.18.4.2 Macros for greatest-width integer constants */ -#define INTMAX_C(val) INT64_C(val) -#define UINTMAX_C(val) UINT64_C(val) - -#endif /* !defined ( __cplusplus) || defined __STDC_CONSTANT_MACROS */ - -#endif diff --git a/include/dds/core/detail/ref_traits.hpp b/include/dds/core/detail/ref_traits.hpp deleted file mode 100644 index 831eac10456..00000000000 --- a/include/dds/core/detail/ref_traits.hpp +++ /dev/null @@ -1,67 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_CORE_DETAIL_REF_TRAITS_HPP_ -#define EPROSIMA_DDS_CORE_DETAIL_REF_TRAITS_HPP_ - -#include //null -#include //InvalidDowncastError - -#include -#include - -namespace dds { -namespace core { - -template< - typename T1, - typename T2> -struct is_base_of : public ::std::is_base_of { }; - -template< - typename T1, - typename T2> -struct is_same : public ::std::is_same { }; - -template -struct smart_ptr_traits -{ - typedef ::std::shared_ptr ref_type; - typedef ::std::weak_ptr weak_ref_type; -}; - -template< - typename TO, - typename FROM> -TO polymorphic_cast( - FROM& from) -{ - - typename TO::DELEGATE_REF_T dr = ::std::dynamic_pointer_cast(from.delegate()); - - TO to(dr); - if (to == null) - { - throw InvalidDowncastError("Attempted invalid downcast."); - } - return to; -} - -} //namespace core -} //namespace dds - -#endif //EPROSIMA_DDS_CORE_DETAIL_REF_TRAITS_HPP_ diff --git a/include/dds/core/macros.hpp b/include/dds/core/macros.hpp deleted file mode 100644 index d8065397f6b..00000000000 --- a/include/dds/core/macros.hpp +++ /dev/null @@ -1,56 +0,0 @@ -/* - * Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_CORE_MACROS_HPP_ -#define OMG_DDS_CORE_MACROS_HPP_ - -#include - -// == Static Assert ========================================================= -#define OMG_DDS_STATIC_ASSERT OMG_DDS_STATIC_ASSERT_DETAIL -// ========================================================================== - - -// == Logging Macros ======================================================== -#define OMG_DDS_LOG(kind, msg) OMG_DDS_LOG_DETAIL(kind, msg) -// ========================================================================== - - -// == State Width Constants ================================================= -/* By default, there can be up to 32 unique statuses. However, a - * DDS implementation may extend this number if necessary. - */ -#define OMG_DDS_DEFAULT_STATE_BIT_COUNT OMG_DDS_DEFAULT_STATE_BIT_COUNT_DETAIL -#define OMG_DDS_DEFAULT_STATUS_COUNT OMG_DDS_DEFAULT_STATUS_COUNT_DETAIL - -#ifndef OMG_DDS_STATE_BIT_COUNT -#define OMG_DDS_STATE_BIT_COUNT OMG_DDS_DEFAULT_STATE_BIT_COUNT -#endif // !defined(OMG_DDS_STATE_BIT_COUNT) - -#ifndef OMG_DDS_STATUS_COUNT -#define OMG_DDS_STATUS_COUNT OMG_DDS_DEFAULT_STATUS_COUNT -#endif // !defined(OMG_DDS_STATUS_COUNT) -// ========================================================================== - - -// == DLL Export Macros ===================================================== -#define OMG_DDS_API OMG_DDS_API_DETAIL -// ========================================================================== - -#endif //OMG_DDS_CORE_MACROS_HPP_ diff --git a/include/dds/core/policy/CorePolicy.hpp b/include/dds/core/policy/CorePolicy.hpp deleted file mode 100644 index c21dd817aa8..00000000000 --- a/include/dds/core/policy/CorePolicy.hpp +++ /dev/null @@ -1,1705 +0,0 @@ -/* - * Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * All rights reserved. - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_CORE_POLICY_CORE_POLICY_HPP_ -#define OMG_DDS_CORE_POLICY_CORE_POLICY_HPP_ - -#include -#include -#include - -#include -#include -#include -#include -#include - -//============================================================================== -// MACROS -// *INDENT-OFF* -#define OMG_DDS_POLICY_TRAITS(POLICY, ID) \ - template<> \ - class policy_id { \ - public: \ - static const dds::core::policy::QosPolicyId value = ID; \ - }; \ - template<> \ - class policy_name { \ - public: \ - static const std::string& name(); \ - }; - -#define OMG_DDS_DEFINE_POLICY_TRAITS(POLICY, NAME) \ - const std::string& dds::core::policy::policy_name::name() { \ - static std::string name = #NAME; \ - return name; \ - } -// *INDENT-OFF* - - -namespace dds { -namespace core { -namespace policy { - -//============================================================================== -/** - * \copydoc DCPS_QoS_UserData - */ -class UserData : public dds::core::Value -{ -public: - - /** - * Creates a UserData QoS instance with an empty UserData - */ - UserData(); - - /** - * Creates a UserData QoS instance - * - * @param sequence the sequence of octets - */ - explicit UserData( - const dds::core::ByteSeq& sequence); - - /** - * Creates a UserData QoS instance - * - * @param value_begin a pointer to the beginning of a sequence - * of octets - * @param value_end a pointer to the end of a sequence - * of octets - */ - UserData( - const uint8_t* value_begin, - const uint8_t* value_end); - - /** - * Copies a UserData QoS instance - * - * @param other the UserData QoS instance to copy - */ - UserData( - const UserData& other); - - /** - * Sets the sequence - * - * @param sequence a sequence of octets - */ - UserData& value( - const dds::core::ByteSeq& sequence); - - /** - * Sets the sequence - * - * @param begin an iterator pointing to the beginning of a sequence - * of octets - * @param end an iterator pointing to the end of a sequence of octets - */ - template - UserData& value( - OCTET_ITER begin, - OCTET_ITER end); - - /** - * Gets the sequence - * - * @return a sequence of octets - */ - const dds::core::ByteSeq value() const; - - /** - * Gets a pointer to the first octet in the sequence - * - * @return a pointer to the first octet in the sequence - */ - const uint8_t* begin() const; - - /** - * Gets a pointer to the last octet in the sequence - * - * @return a pointer to the first octet in the sequence - */ - const uint8_t* end() const; -}; - -//============================================================================== - -/** - * \copydoc DCPS_QoS_GroupData - */ -class GroupData : public dds::core::Value -{ -public: - - /** - * Creates a GroupData QoS instance - */ - GroupData(); - - /** - * Creates a GroupData QoS instance - * - * @param sequence the sequence of octets representing the GroupData - */ - explicit GroupData( - const dds::core::ByteSeq& sequence); - - /** - * Copies a GroupData QoS instance - * - * @param other the GroupData QoS instance to copy - */ - GroupData( - const GroupData& other); - - /** - * Creates a GroupData QoS instance - * - * @param value_begin a pointer to the beginning of a sequence - * of octets - * @param value_end a pointer to the end of a sequence - * of octets - */ - GroupData( - const uint8_t* value_begin, - const uint8_t* value_end); - - /** - * Set the sequence - * - * @param sequence a sequence of octets - */ - GroupData& value( - const dds::core::ByteSeq& sequence); - - /** - * Set the sequence - * - * @param begin an iterator pointing to the beginning of a sequence - * of octets - * @param end an iterator pointing to the end of a sequence of octets - */ - template - GroupData& value( - OCTET_ITER begin, - OCTET_ITER end); - - /** - * Get the sequence - * - * @return a sequence of octets - */ - const dds::core::ByteSeq value() const; - - /** - * Gets a pointer to the first octet in the sequence - * - * @return a pointer to the first octet in the sequence - */ - const uint8_t* begin() const; - - /** - * Gets a pointer to the last octet in the sequence - * - * @return a pointer to the last octet in the sequence - */ - const uint8_t* end() const; -}; - -//============================================================================== - -/** - * \copydoc DCPS_QoS_TopicData - */ -class TopicData : public dds::core::Value -{ -public: - - /** - * Creates a TopicData QoS instance - */ - TopicData(); - - /** - * Creates a TopicData QoS instance - * - * @param sequence the sequence of octets representing the TopicData - */ - explicit TopicData( - const dds::core::ByteSeq& sequence); - - /** - * Copies a TopicData QoS instance - * - * @param other the TopicData QoS instance to copy - */ - TopicData( - const TopicData& other); - - /** - * Creates a TopicData QoS instance - * - * @param value_begin a pointer to the beginning of a sequence - * of octets - * @param value_end a pointer to the end of a sequence - * of octets - */ - TopicData( - const uint8_t* value_begin, - const uint8_t* value_end); - - /** - * Set the sequence - * - * @param sequence a sequence of octets - */ - TopicData& value( - const dds::core::ByteSeq& sequence); - - /** - * Set the sequence - * - * @param begin an iterator pointing to the beginning of a sequence - * of octets - * @param end an iterator pointing to the end of a sequence of octets - */ - template - TopicData& value( - OCTET_ITER begin, - OCTET_ITER end); - - /** - * Get the sequence - * - * @return a sequence of octets - */ - const dds::core::ByteSeq value() const; - - /** - * Gets a pointer to the first octet in the sequence - * - * @return a pointer to the first octet in the sequence - */ - const uint8_t* begin() const; - - /** - * Gets a pointer to the last octet in the sequence - * - * @return a pointer to the last octet in the sequence - */ - const uint8_t* end() const; -}; - - -//============================================================================== - -/** - * \copydoc DCPS_QoS_EntityFactory - */ -class EntityFactory : public dds::core::Value -{ -public: - - /** - * Creates an EntityFactory QoS instance - * - * @param autoenable_created_entities boolean indicating whether - * created Entities should be automatically enabled - */ - explicit EntityFactory( - bool autoenable_created_entities = true); - - /** - * Copies an EntityFactory QoS instance - * - * @param other the EntityFactory QoS instance to copy - */ - EntityFactory( - const EntityFactory& other); - - /** - * Sets a boolean indicating whether created Entities should be - * automatically enabled - * - * @param autoenable_created_entities boolean indicating whether - * created Entities should be automatically enabled - */ - EntityFactory& autoenable_created_entities( - bool autoenable_created_entities); - - /** - * Gets a boolean indicating whether Entities should be automatically enabled - * - * @return boolean indicating whether created Entities should be automatically - * enabled - */ - bool autoenable_created_entities() const; - - /** - * @return an EntityFactory QoS instance with autoenable_created_entities - * set to true - */ - static EntityFactory AutoEnable(); - - /** - * @return an EntityFactory QoS instance with autoenable_created_entities - * set to false - */ - static EntityFactory ManuallyEnable(); -}; - -//============================================================================== - -/** - * \copydoc DCPS_QoS_TransportPriority - */ -class TransportPriority : public dds::core::Value -{ -public: - - /** - * Creates a TransportPriority QoS instance - * - * @param priority the priority value - */ - explicit TransportPriority( - int32_t priority = 0); - - /** - * Copies a TransportPriority QoS instance - * - * @param other the TransportPriority QoS instance to copy - */ - TransportPriority( - const TransportPriority& other); - - /** - * Sets the priority value - * - * @param priority the priority value - */ - TransportPriority& value( - int32_t priority); - - /** - * Gets the priority value - * - * @return the priority value - */ - int32_t value() const; -}; - -//============================================================================== - -/** - * \copydoc DCPS_QoS_Lifespan - */ -class Lifespan : public dds::core::Value -{ -public: - - /** - * Creates a Lifespan QoS instance - * - * @param duration Lifespan expiration duration - */ - explicit Lifespan( - const dds::core::Duration& duration = dds::core::Duration::infinite()); - - /** - * Copies a Lifespan QoS instance - * - * @param other the Lifespan QoS instance to copy - */ - Lifespan( - const Lifespan& other); - - /** - * Sets the expiration duration - * - * @param duration expiration duration - */ - Lifespan& duration( - const dds::core::Duration& duration); - - /** - * Gets the expiration duration - * - * @return expiration duration - */ - const dds::core::Duration duration() const; -}; - -//============================================================================== - -/** - * \copydoc DCPS_QoS_Deadline - */ -class Deadline : public dds::core::Value -{ -public: - - /** - * Creates a Deadline QoS instance - * - * @param period deadline period - */ - explicit Deadline( - const dds::core::Duration& period = dds::core::Duration::infinite()); - - /** - * Copies a Deadline QoS instance - * - * @param other the Deadline QoS instance to copy - */ - Deadline( - const Deadline& other); - - /** - * Sets the deadline period - * - * @param period deadline period - */ - Deadline& period( - const dds::core::Duration& period); - - /** - * Gets the deadline period - * - * @return deadline period - */ - const dds::core::Duration period() const; -}; - -//============================================================================== - -/** - * \copydoc DCPS_QoS_LatencyBudget - */ -class LatencyBudget : public dds::core::Value -{ -public: - - /** - * Creates a LatencyBudget QoS instance - * - * @param duration duration - */ - explicit LatencyBudget( - const dds::core::Duration& duration = dds::core::Duration::zero()); - - /** - * Copies a LatencyBudget QoS instance - * - * @param other the LatencyBudget QoS instance to copy - */ - LatencyBudget( - const LatencyBudget& other); - - /** - * Sets the duration - * - * @param duration duration - */ - LatencyBudget& duration( - const dds::core::Duration& duration); - - /** - * Gets the duration - * - * @return duration - */ - const dds::core::Duration duration() const; -}; - -//============================================================================== - -/** - * \copydoc DCPS_QoS_TimeBasedFilter - */ -class TimeBasedFilter : public dds::core::Value -{ -public: - - /** - * Creates a TimeBasedFilter QoS instance - * - * @param period minimum separation period - */ - explicit TimeBasedFilter( - const dds::core::Duration& period = dds::core::Duration::zero()); - - /** - * Copies a TimeBasedFilter QoS instance - * - * @param other the TimeBasedFilter QoS instance to copy - */ - TimeBasedFilter( - const TimeBasedFilter& other); - - /** - * Sets the minimum separation period - * - * @param period minimum separation period - */ - TimeBasedFilter& minimum_separation( - const dds::core::Duration& period); - - /** - * Gets the minimum separation period - * - * @return minimum separation period - */ - const dds::core::Duration minimum_separation() const; -}; - - -//============================================================================== - -/** - * \copydoc DCPS_QoS_Partition - */ -class Partition : public dds::core::Value -{ -public: - - Partition(); - - /** - * Creates a Partition QoS instance - * - * @param in_length partition length - */ - explicit Partition( - uint16_t in_length); - - /** - * Copies a Partition QoS instance - * - * @param other the Partition QoS instance to copy - */ - Partition( - const Partition& other); - - /** - * Sets the partition name - * - * @param name the partition name - */ - Partition& name( - const std::string& name); - - /** - * Sets multiple partition names - * - * @param names a sequence containing multiple partition names - */ - Partition& names( - dds::core::StringSeq& names); - - /** - * Gets the partition names - * - * @return a sequence containing the partition names - */ - const dds::core::StringSeq names() const; - - /** - * Appends a name to the list of partition names. - * @param name Name to append. - */ - void push_back( - const char* name); - - void clear(); -}; - -//============================================================================== -//#ifdef OMG_DDS_OWNERSHIP_SUPPORT - -/** - * \copydoc DCPS_QoS_Ownership - */ -class Ownership : public dds::core::Value -{ -public: - - # if defined (__SUNPRO_CC) && defined(SHARED) - # undef SHARED - # endif // if defined (__SUNPRO_CC) && defined(SHARED) - /** - * Creates an Ownership QoS instance - * - * @param kind the kind - */ - explicit Ownership( - dds::core::policy::OwnershipKind::Type kind = dds::core::policy::OwnershipKind::SHARED); - - /** - * Copies an Ownership QoS instance - * - * @param other the Ownership QoS instance to copy - */ - Ownership( - const Ownership& other); - - /** - * Set the kind - * - * @param kind the kind - */ - Ownership& kind( - dds::core::policy::OwnershipKind::Type kind); - - /** - * Get the kind - * - * @param kind the kind - */ - dds::core::policy::OwnershipKind::Type kind() const; - - /** - * @return an Ownership QoS instance with the kind set to EXCLUSIVE - */ - static Ownership Exclusive(); - - /** - * @return an Ownership QoS instance with the kind set to SHARED - */ - static Ownership Shared(); - -private: - - static eprosima::fastdds::dds::OwnershipQosPolicyKind to_native( - OwnershipKind::Type kind); - - static OwnershipKind::Type from_native( - eprosima::fastdds::dds::OwnershipQosPolicyKind kind); -}; - - -//============================================================================== - -/** - * \copydoc DCPS_QoS_OwnershipStrength - */ -class OwnershipStrength : public dds::core::Value -{ -public: - - /** - * Creates an OwnershipStrength QoS instance - * - * @param strength ownership strength - */ - explicit OwnershipStrength( - int32_t strength = 0); - - /** - * Copies an OwnershipStrength QoS instance - * - * @param other the OwnershipStrength QoS instance to copy - */ - OwnershipStrength( - const OwnershipStrength& other); - - /** - * Gets the ownership strength value - * - * @return the ownership strength value - */ - int32_t value() const; - - /** - * Sets the ownership strength value - * - * @param strength the ownership strength value - */ - OwnershipStrength& value( - int32_t strength); -}; - -//#endif // OMG_DDS_OWNERSHIP_SUPPORT -//============================================================================== - -/** - * \copydoc DCPS_QoS_WriterDataLifecycle - */ -class WriterDataLifecycle : public dds::core::Value -{ -public: - - /** - * Creates a WriterDataLifecycle QoS instance - * - * @param autodispose_unregistered_instances Specifies the behavior of the DataWriter - * with regards to the lifecycle of the data-instances it manages. - */ - explicit WriterDataLifecycle( - bool autodispose_unregistered_instances = true); - - /** - * Copies a WriterDataLifecycle QoS instance - * - * @param other the WriterDataLifecycle QoS instance to copy - */ - WriterDataLifecycle( - const WriterDataLifecycle& other); - - /** - * Gets a boolean indicating if unregistered instances should be autodisposed - * - * @return a boolean indicating if unregistered instances should be autodisposed - */ - bool autodispose_unregistered_instances() const; - - /** - * Sets a boolean indicating if unregistered instances should be autodisposed - * - * @param autodispose_unregistered_instances a boolean indicating if unregistered - * instances should be autodisposed - */ - WriterDataLifecycle& autodispose_unregistered_instances( - bool autodispose_unregistered_instances); - - /** - * @return a WriterDataLifecycle QoS instance with autodispose_unregistered_instances - * set to true - */ - static WriterDataLifecycle AutoDisposeUnregisteredInstances(); - - /** - * @return a WriterDataLifecycle QoS instance with autodispose_unregistered_instances - * set to false - */ - static WriterDataLifecycle ManuallyDisposeUnregisteredInstances(); - -}; - -//============================================================================== - -/** - * \copydoc DCPS_QoS_ReaderDataLifecycle - */ -class ReaderDataLifecycle : public dds::core::Value -{ -public: - - /** - * Creates a ReaderDataLifecycle QoS instance - * - * @param autopurge_nowriter_samples_delay the autopurge nowriter samples delay - * @param autopurge_disposed_samples_delay the autopurge disposed samples delay - */ - ReaderDataLifecycle( - const dds::core::Duration& autopurge_nowriter_samples_delay = dds::core::Duration::infinite(), - const dds::core::Duration& autopurge_disposed_samples_delay = dds::core::Duration::infinite()); - - /** - * Copies a ReaderDataLifecycle QoS instance - * - * @param other the ReaderDataLifecycle QoS instance to copy - */ - ReaderDataLifecycle( - const ReaderDataLifecycle& other); - /** - * Gets the autopurge nowriter samples delay - * - * @return the autopurge nowriter samples delay - */ - const dds::core::Duration autopurge_nowriter_samples_delay() const; - - /** - * Sets the autopurge nowriter samples delay - * - * @param autopurge_nowriter_samples_delay the autopurge nowriter samples delay - */ - ReaderDataLifecycle& autopurge_nowriter_samples_delay( - const dds::core::Duration& autopurge_nowriter_samples_delay); - - /** - * Gets the autopurge_disposed_samples_delay - * - * @return the autopurge disposed samples delay - */ - const dds::core::Duration autopurge_disposed_samples_delay() const; - - /** - * Sets the autopurge_disposed_samples_delay - * - * @return the autopurge disposed samples delay - */ - ReaderDataLifecycle& autopurge_disposed_samples_delay( - const dds::core::Duration& autopurge_disposed_samples_delay); - - /** - * @return a ReaderDataLifecycle QoS instance which will not autopurge disposed - * samples - */ - static ReaderDataLifecycle NoAutoPurgeDisposedSamples(); - - /** - * @param autopurge_disposed_samples_delay the autopurge disposed samples delay - * @return a ReaderDataLifecycle QoS instance with autopurge_disposed_samples_delay - * set to a specified value - */ - static ReaderDataLifecycle AutoPurgeDisposedSamples( - const dds::core::Duration& autopurge_disposed_samples_delay); - -}; - -//============================================================================== - -/** - * \copydoc DCPS_QoS_Durability - */ -class Durability : public dds::core::Value -{ -public: - - /** - * Creates a Durability QoS instance - * - * @param kind the kind - */ - explicit Durability( - dds::core::policy::DurabilityKind::Type kind = dds::core::policy::DurabilityKind::VOLATILE); - - /** - * Copies a Durability QoS instance - * - * @param other the Durability QoS instance to copy - */ - Durability( - const Durability& other); - - /** - * Set the kind - * - * @param kind the kind - */ - Durability& kind( - dds::core::policy::DurabilityKind::Type kind); - - /** - * Get the kind - * - * @param kind the kind - */ - dds::core::policy::DurabilityKind::Type kind() const; - - /** - * @return a Durability QoS instance with the kind set to VOLATILE - */ - static Durability Volatile(); - - /** - * @return a Durability QoS instance with the kind set to TRANSIENT_LOCAL - */ - static Durability TransientLocal(); - - /** - * @return a Durability QoS instance with the kind set to TRANSIENT - */ - static Durability Transient(); - - /** - * @return a Durability QoS instance with the kind set to PERSISTENT - */ - static Durability Persistent(); - -private: - - static eprosima::fastdds::dds::DurabilityQosPolicyKind to_native( - DurabilityKind::Type kind); - - static DurabilityKind::Type from_native( - eprosima::fastdds::dds::DurabilityQosPolicyKind kind); - -}; - -//============================================================================== - -/** - * \copydoc DCPS_QoS_Presentation - */ -class Presentation : public dds::core::Value -{ -public: - - /** - * Creates a Presentation QoS instance - * - * @param access_scope the access_scope kind - * @param coherent_access the coherent_access setting - * @param ordered_access the ordered_access setting - */ - Presentation( - dds::core::policy::PresentationAccessScopeKind::Type access_scope = - dds::core::policy::PresentationAccessScopeKind::INSTANCE, - bool coherent_access = false, - bool ordered_access = false); - - /** - * Copies a Presentation QoS instance - * - * @param other the Presentation QoS instance to copy - */ - Presentation( - const Presentation& other); - - /** - * Sets the access_scope kind - * - * @param access_scope the access_scope kind - */ - Presentation& access_scope( - dds::core::policy::PresentationAccessScopeKind::Type access_scope); - - /** - * Gets the access_scope kind - * - * @return the access_scope kind - */ - dds::core::policy::PresentationAccessScopeKind::Type access_scope() const; - - /** - * Sets the coherent_access setting - * - * @param coherent_access the coherent_access setting - */ - Presentation& coherent_access( - bool coherent_access); - - /** - * Gets the coherent_access setting - * - * @return the coherent_access setting - */ - bool coherent_access() const; - - /** - * Sets the ordered_access setting - * - * @param ordered_access the ordered_access setting - */ - Presentation& ordered_access( - bool ordered_access); - - /** - * Gets the ordered_access setting - * - * @return the ordered_access setting - */ - bool ordered_access() const; - - /** - * @param coherent_access the coherent_access setting - * @param ordered_access the ordered_access setting - * - * @return a Presentation QoS instance with a GROUP access_score and coherent_access - * and ordered_access set to the specified values - */ - static Presentation GroupAccessScope( - bool coherent_access = false, - bool ordered_access = false); - - /** - * @param coherent_access the coherent_access setting - * @param ordered_access the ordered_access setting - * - * @return a Presentation QoS instance with a INSTANCE access_score and coherent_access - * and ordered_access set to the specified values - */ - static Presentation InstanceAccessScope( - bool coherent_access = false, - bool ordered_access = false); - - /** - * @param coherent_access the coherent_access setting - * @param ordered_access the ordered_access setting - * - * @return a Presentation QoS instance with a TOPIC access_score and coherent_access - * and ordered_access set to the specified values - */ - static Presentation TopicAccessScope( - bool coherent_access = false, - bool ordered_access = false); - -private: - - static eprosima::fastdds::dds::PresentationQosPolicyAccessScopeKind to_native( - PresentationAccessScopeKind::Type kind); - - static PresentationAccessScopeKind::Type from_native( - eprosima::fastdds::dds::PresentationQosPolicyAccessScopeKind kind); -}; - -//============================================================================== - -/** - * \copydoc DCPS_QoS_Reliability - */ -class Reliability : public dds::core::Value -{ -public: - - /** - * Creates a Reliability QoS instance - * - * @param kind the kind - * @param max_blocking_time the max_blocking_time - */ - Reliability( - dds::core::policy::ReliabilityKind::Type kind = dds::core::policy::ReliabilityKind::BEST_EFFORT, - const dds::core::Duration& max_blocking_time = dds::core::Duration::from_millisecs(100)); - - /** - * Copies a Reliability QoS instance - * - * @param other the Reliability QoS instance to copy - */ - Reliability( - const Reliability& other); - - /** - * Sets the kind - * - * @param kind the kind - */ - Reliability& kind( - dds::core::policy::ReliabilityKind::Type kind); - - /** - * Gets the kind - * - * @return the kind - */ - dds::core::policy::ReliabilityKind::Type kind() const; - - /** - * Sets the max_blocking_time - * - * @param max_blocking_time the max_blocking_time - */ - Reliability& max_blocking_time( - const dds::core::Duration& max_blocking_time); - - /** - * Gets the max_blocking_time - * - * @return the max_blocking_time - */ - const dds::core::Duration max_blocking_time() const; - - /** - * @param the max_blocking_time - * @return a Reliability QoS instance with the kind set to RELIABLE and the max_blocking_time - * set to the supplied value - */ - static OMG_DDS_API Reliability Reliable( - const dds::core::Duration& max_blocking_time = dds::core::Duration::from_millisecs(100)); - - /** - * @return a Reliability QoS instance with the kind set to BEST_EFFORT - */ - static Reliability BestEffort( - const dds::core::Duration& max_blocking_time = dds::core::Duration::from_millisecs(100)); - -private: - - static ReliabilityKind::Type from_native( - eprosima::fastdds::dds::ReliabilityQosPolicyKind kind); - - static eprosima::fastdds::dds::ReliabilityQosPolicyKind to_native( - ReliabilityKind::Type kind); - -}; - -//============================================================================== - -/** - * \copydoc DCPS_QoS_DestinationOrder - */ -class DestinationOrder : public dds::core::Value -{ -public: - - /** - * Creates a DestinationOrder QoS instance - * - * @param kind the kind - */ - explicit DestinationOrder( - dds::core::policy::DestinationOrderKind::Type kind = - dds::core::policy::DestinationOrderKind::BY_RECEPTION_TIMESTAMP); - - /** - * Copies a DestinationOrder QoS instance - * - * @param other the Reliability QoS instance to copy - */ - DestinationOrder( - const DestinationOrder& other); - - /** - * Sets the kind - * - * @param kind the kind - */ - DestinationOrder& kind( - dds::core::policy::DestinationOrderKind::Type kind); - - /** - * Gets the kind - * - * @return the kind - */ - dds::core::policy::DestinationOrderKind::Type kind() const; - - /** - * @return a DestinationOrder QoS instance with the kind set to BY_SOURCE_TIMESTAMP - */ - static DestinationOrder SourceTimestamp(); - - /** - * @return a DestinationOrder QoS instance with the kind set to BY_RECEPTION_TIMESTAMP - */ - static DestinationOrder ReceptionTimestamp(); - -private: - - static eprosima::fastdds::dds::DestinationOrderQosPolicyKind to_native( - DestinationOrderKind::Type kind); - - static DestinationOrderKind::Type from_native( - eprosima::fastdds::dds::DestinationOrderQosPolicyKind kind); - -}; - -//============================================================================== - -/** - * \copydoc DCPS_QoS_History - */ -class History : public dds::core::Value -{ -public: - - /** - * Creates a History QoS instance - * - * @param kind the kind - * @param depth the history depth - */ - History( - dds::core::policy::HistoryKind::Type kind = dds::core::policy::HistoryKind::KEEP_LAST, - int32_t depth = 1); - - /** - * Copies a History QoS instance - * - * @param other the History QoS instance to copy - */ - History( - const History& other); - - /** - * Gets the kind - * - * @return the kind - */ - dds::core::policy::HistoryKind::Type kind() const; - - /** - * Sets the kind - * - * @param kind the kind - */ - History& kind( - dds::core::policy::HistoryKind::Type kind); - - /** - * Gets the history depth - * - * @return the history depth - */ - int32_t depth() const; - - /** - * Sets the history depth - * - * @param the history depth - */ - History& depth( - int32_t depth); - - /** - * @return a History QoS instance with the kind set to KEEP_ALL - */ - static History KeepAll(); - - /** - * @param depth the history depth - * @return a History QoS instance with the kind set to KEEP_LAST and the - * depth set to the supplied value - */ - static History KeepLast( - uint32_t depth); - -private: - - friend class DurabilityService; - - static eprosima::fastdds::dds::HistoryQosPolicyKind to_native( - HistoryKind::Type kind); - - static HistoryKind::Type from_native( - eprosima::fastdds::dds::HistoryQosPolicyKind kind); - -}; - -//============================================================================== - -/** - * \copydoc DCPS_QoS_ResourceLimits - */ -class ResourceLimits : public dds::core::Value -{ -public: - - /** - * Creates a ResourceLimits QoS instance - * - * @param max_samples the max_samples value - * @param max_instances the max_instances value - * @param max_samples_per_instance the max_samples_per_instance value - */ - ResourceLimits( - uint32_t max_samples = dds::core::LENGTH_UNLIMITED, - uint32_t max_instances = dds::core::LENGTH_UNLIMITED, - uint32_t max_samples_per_instance = dds::core::LENGTH_UNLIMITED); - - /** - * Copies a ResourceLimits QoS instance - * - * @param other the ResourceLimits QoS instance to copy - */ - ResourceLimits( - const ResourceLimits& other); - -public: - - /** - * Sets the max_samples value - * - * @param max_samples the max_samples value - */ - ResourceLimits& max_samples( - int32_t max_samples); - - /** - * Gets the max_samples value - * - * @return the max_samples value - */ - int32_t max_samples() const; - - /** - * Sets the max_instances value - * - * @param max_instances the max_instances value - */ - ResourceLimits& max_instances( - int32_t max_instances); - - /** - * Gets the max_instances value - * - * @return the max_instances value - */ - int32_t max_instances() const; - - /** - * Sets the max_samples_per_instance value - * - * @param max_samples_per_instance the max_samples_per_instance value - */ - ResourceLimits& max_samples_per_instance( - int32_t max_samples_per_instance); - - /** - * Gets the max_samples_per_instance value - * - * @return the max_samples_per_instance value - */ - int32_t max_samples_per_instance() const; -}; - -//============================================================================== - -/** - * \copydoc DCPS_QoS_Liveliness - */ -class Liveliness : public dds::core::Value -{ -public: - - /** - * Creates a Liveliness QoS instance - * - * @param kind the kind - * @param lease_duration the lease_duration - */ - Liveliness( - dds::core::policy::LivelinessKind::Type kind = dds::core::policy::LivelinessKind::AUTOMATIC, - const dds::core::Duration& lease_duration = dds::core::Duration::infinite()); - - /** - * Copies a Liveliness QoS instance - * - * @param other the Liveliness QoS instance to copy - */ - Liveliness( - const Liveliness& other); - - /** - * Sets the kind - * - * @param kind the kind - */ - Liveliness& kind( - dds::core::policy::LivelinessKind::Type kind); - - /** - * Gets the kind - * - * @return the kind - */ - dds::core::policy::LivelinessKind::Type kind() const; - - /** - * Sets the lease_duration - * - * @return the lease_duration - */ - Liveliness& lease_duration( - const dds::core::Duration& lease_duration); - - /** - * Gets the lease_duration - * - * @return the lease_duration - */ - const dds::core::Duration lease_duration() const; - - /** - * @return a Liveliness QoS instance with the kind set to AUTOMATIC - */ - static Liveliness Automatic(); - - /** - * @return a Liveliness QoS instance with the kind set to MANUAL_BY_PARTICIPANT - * and the lease_duration set to the supplied value - */ - static Liveliness ManualByParticipant( - const dds::core::Duration& lease_duration = dds::core::Duration::infinite()); - - /** - * @return a Liveliness QoS instance with the kind set to MANUAL_BY_TOPIC - * and the lease_duration set to the supplied value - */ - static Liveliness ManualByTopic( - const dds::core::Duration& lease_duration = dds::core::Duration::infinite()); - -private: - - static eprosima::fastdds::dds::LivelinessQosPolicyKind to_native( - LivelinessKind::Type kind); - - static LivelinessKind::Type from_native( - eprosima::fastdds::dds::LivelinessQosPolicyKind kind); - -}; - - -//============================================================================== -//#ifdef OMG_DDS_PERSISTENCE_SUPPORT - -/** - * \copydoc DCPS_QoS_DurabilityService - */ -class DurabilityService : public dds::core::Value -{ -public: - - /** - * Creates a DurabilityService QoS instance - * - * @param service_cleanup_delay the service_cleanup_delay - * @param history_kind the history_kind value - * @param history_depth the history_depth value - * @param max_samples the max_samples value - * @param max_instances the max_instances value - * @param max_samples_per_instance the max_samples_per_instance value - */ - DurabilityService( - const dds::core::Duration& service_cleanup_delay = dds::core::Duration::zero(), - dds::core::policy::HistoryKind::Type history_kind = dds::core::policy::HistoryKind::KEEP_LAST, - int32_t history_depth = 1, - int32_t max_samples = dds::core::LENGTH_UNLIMITED, - int32_t max_instances = dds::core::LENGTH_UNLIMITED, - int32_t max_samples_per_instance = dds::core::LENGTH_UNLIMITED); - - /** - * Copies a DurabilityService QoS instance - * - * @param other the DurabilityService QoS instance to copy - */ - DurabilityService( - const DurabilityService& other); - - /** - * Sets the service_cleanup_delay value - * - * @param service_cleanup_delay the service_cleanup_delay value - */ - DurabilityService& service_cleanup_delay( - const dds::core::Duration& service_cleanup_delay); - - /** - * Gets the service_cleanup_delay value - * - * @return the service_cleanup_delay - */ - const dds::core::Duration service_cleanup_delay() const; - - /** - * Sets the history_kind - * - * @param the history_kind - */ - DurabilityService& history_kind( - dds::core::policy::HistoryKind::Type history_kind); - - /** - * Gets the history_kind - * - * @return history_kind - */ - dds::core::policy::HistoryKind::Type history_kind() const; - - /** - * Sets the history_depth value - * - * @param history_depth the history_depth value - */ - DurabilityService& history_depth( - int32_t history_depth); - - /** - * Gets the history_depth value - * - * @return history_depth - */ - int32_t history_depth() const; - - /** - * Sets the max_samples value - * - * @param max_samples the max_samples value - */ - DurabilityService& max_samples( - int32_t max_samples); - - /** - * Gets the max_samples value - * - * @return the max_samples value - */ - int32_t max_samples() const; - - /** - * Sets the max_instances value - * - * @param max_instances the max_instances value - */ - DurabilityService& max_instances( - int32_t max_instances); - - /** Gets the max_instances value - * - * @return the max_instances value - */ - int32_t max_instances() const; - - /** - * Sets the max_samples_per_instance value - * - * @param max_samples_per_instance the max_samples_per_instance value - */ - DurabilityService& max_samples_per_instance( - int32_t max_samples_per_instance); - - /** - * Gets the max_samples_per_instance value - * - * @return the max_samples_per_instance value - */ - int32_t max_samples_per_instance() const; -}; - -//#endif //OMG_DDS_PERSISTENCE_SUPPORT - -//============================================================================== - -//#ifdef OMG_DDS_EXTENSIBLE_AND_DYNAMIC_TOPIC_TYPE_SUPPORT - -typedef uint16_t DataRepresentationId; - -typedef std::vector DataRepresentationIdSeq; - -class DataRepresentation : public dds::core::Value -{ - -public: - - explicit DataRepresentation( - const dds::core::policy::DataRepresentationIdSeq& value); - - DataRepresentation( - const DataRepresentation& other) - : dds::core::Value(other) - { - } - - DataRepresentation& value( - const dds::core::policy::DataRepresentationIdSeq& value); - - const dds::core::policy::DataRepresentationIdSeq value() const; - - dds::core::policy::DataRepresentationIdSeq& value(); - -private: - - static std::vector to_native( - const DataRepresentationIdSeq& seq); - -}; - -//#endif //OMG_DDS_EXTENSIBLE_AND_DYNAMIC_TOPIC_TYPE_SUPPORT - - -//============================================================================ - -//#ifdef OMG_DDS_EXTENSIBLE_AND_DYNAMIC_TOPIC_TYPE_SUPPORT - -class TypeConsistencyEnforcement : public dds::core::Value -{ -public: - - explicit TypeConsistencyEnforcement( - dds::core::policy::TypeConsistencyEnforcementKind::Type kind); - - TypeConsistencyEnforcement& kind( - dds::core::policy::TypeConsistencyEnforcementKind::Type kind); - - dds::core::policy::TypeConsistencyEnforcementKind::Type kind() const; - - TypeConsistencyEnforcement& ignore_sequence_bounds( - bool ignore_sequence_bounds); - - TypeConsistencyEnforcement& ignore_string_bounds( - bool ignore_string_bounds); - - TypeConsistencyEnforcement& ignore_member_names( - bool ignore_member_names); - - TypeConsistencyEnforcement& prevent_type_widening( - bool prevent_type_widening); - - TypeConsistencyEnforcement& force_type_validation( - bool force_type_validation); - - bool ignore_sequence_bounds(); - - bool ignore_string_bounds(); - - bool ignore_member_names(); - - bool prevent_type_widening(); - - bool force_type_validation(); - -}; - -//#endif //OMG_DDS_EXTENSIBLE_AND_DYNAMIC_TOPIC_TYPE_SUPPORT - -//============================================================================== -// Policy Trait Classes - -template -class policy_id; - -template -class policy_name; - -#ifdef OMG_DDS_EXTENSIBLE_AND_DYNAMIC_TOPIC_TYPE_SUPPORT -/** @todo - Known issue. */ -#endif // ifdef OMG_DDS_EXTENSIBLE_AND_DYNAMIC_TOPIC_TYPE_SUPPORT - -OMG_DDS_POLICY_TRAITS(UserData, eprosima::fastdds::dds::USERDATA_QOS_POLICY_ID) -OMG_DDS_POLICY_TRAITS(Durability, eprosima::fastdds::dds::DURABILITY_QOS_POLICY_ID) -OMG_DDS_POLICY_TRAITS(Presentation, eprosima::fastdds::dds::PRESENTATION_QOS_POLICY_ID) -OMG_DDS_POLICY_TRAITS(Deadline, eprosima::fastdds::dds::DEADLINE_QOS_POLICY_ID) -OMG_DDS_POLICY_TRAITS(LatencyBudget, eprosima::fastdds::dds::LATENCYBUDGET_QOS_POLICY_ID) -OMG_DDS_POLICY_TRAITS(Ownership, eprosima::fastdds::dds::OWNERSHIP_QOS_POLICY_ID) - -//#ifdef OMG_DDS_OWNERSHIP_SUPPORT -OMG_DDS_POLICY_TRAITS(OwnershipStrength, eprosima::fastdds::dds::OWNERSHIPSTRENGTH_QOS_POLICY_ID) -//#endif //OMG_DDS_OWNERSHIP_SUPPORT - -OMG_DDS_POLICY_TRAITS(Liveliness, eprosima::fastdds::dds::LIVELINESS_QOS_POLICY_ID) -OMG_DDS_POLICY_TRAITS(TimeBasedFilter, eprosima::fastdds::dds::TIMEBASEDFILTER_QOS_POLICY_ID) -OMG_DDS_POLICY_TRAITS(Partition, eprosima::fastdds::dds::PARTITION_QOS_POLICY_ID) -OMG_DDS_POLICY_TRAITS(Reliability, eprosima::fastdds::dds::RELIABILITY_QOS_POLICY_ID) -OMG_DDS_POLICY_TRAITS(DestinationOrder, eprosima::fastdds::dds::DESTINATIONORDER_QOS_POLICY_ID) -OMG_DDS_POLICY_TRAITS(History, eprosima::fastdds::dds::HISTORY_QOS_POLICY_ID) -OMG_DDS_POLICY_TRAITS(ResourceLimits, eprosima::fastdds::dds::RESOURCELIMITS_QOS_POLICY_ID) -OMG_DDS_POLICY_TRAITS(EntityFactory, eprosima::fastdds::dds::ENTITYFACTORY_QOS_POLICY_ID) -OMG_DDS_POLICY_TRAITS(WriterDataLifecycle, eprosima::fastdds::dds::WRITERDATALIFECYCLE_QOS_POLICY_ID) -OMG_DDS_POLICY_TRAITS(ReaderDataLifecycle, eprosima::fastdds::dds::READERDATALIFECYCLE_QOS_POLICY_ID) -OMG_DDS_POLICY_TRAITS(TopicData, eprosima::fastdds::dds::TOPICDATA_QOS_POLICY_ID) -OMG_DDS_POLICY_TRAITS(GroupData, eprosima::fastdds::dds::GROUPDATA_QOS_POLICY_ID) -OMG_DDS_POLICY_TRAITS(TransportPriority, eprosima::fastdds::dds::TRANSPORTPRIORITY_QOS_POLICY_ID) -OMG_DDS_POLICY_TRAITS(Lifespan, eprosima::fastdds::dds::LIFESPAN_QOS_POLICY_ID) - -//#ifdef OMG_DDS_PERSISTENCE_SUPPORT -OMG_DDS_POLICY_TRAITS(DurabilityService, eprosima::fastdds::dds::DURABILITYSERVICE_QOS_POLICY_ID) -//#endif //OMG_DDS_PERSISTENCE_SUPPORT - -} //namespace policy -} //namespace core -} //namespace dds - - -#endif //OMG_DDS_CORE_POLICY_CORE_POLICY_HPP_ diff --git a/include/dds/core/policy/PolicyKind.hpp b/include/dds/core/policy/PolicyKind.hpp deleted file mode 100644 index d09d312adc9..00000000000 --- a/include/dds/core/policy/PolicyKind.hpp +++ /dev/null @@ -1,255 +0,0 @@ -/* - * Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * All rights reserved. - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_CORE_POLICY_POLICYKIND_HPP_ -#define OMG_DDS_CORE_POLICY_POLICYKIND_HPP_ - -#include -#include - -#include - -namespace dds { -namespace core { -namespace policy { - -#if defined (__SUNPRO_CC) && defined(SHARED) -#undef SHARED -#endif -struct OwnershipKind_def -{ - enum Type - { - SHARED /**< The same instance can be written by - * multiple DataWriter objects. All updates will be made available to the - * DataReader objects. In other words it does not have a specific owner. - */ - #ifdef OMG_DDS_OWNERSHIP_SUPPORT - , - EXCLUSIVE /**< The instance will only be accepted from one - * DataWriter which is the only one whose modifications will be visible to the - * DataReader objects. - */ - #endif //OMG_DDS_OWNERSHIP_SUPPORT - }; -}; - -typedef dds::core::SafeEnum OwnershipKind; - -struct DurabilityKind_def -{ - enum Type - { - VOLATILE, /**< The samples are not available to late-joining - * DataReaders. In other words, only DataReaders, which were present at the - * time of the writing and have subscribed to this Topic, will receive the sample. - * When a DataReader subscribes afterwards (late-joining), it will only be able to - * read the next written sample. This setting is typically used for data, which is - * updated quickly. - */ - TRANSIENT_LOCAL /**< Currently behaves identically to the - * TRANSIENT_DURABILITY_QOS, except for its RxO properties. The desired - * behaviour of TRANSIENT_LOCAL_DURABILITY_QOS can be achieved from the - * TRANSIENT_DURABILITY_QOS with the default (TRUE) setting of the - * autodispose_unregistered_instances flag on the DataWriter and the - * service_cleanup_delay set to 0 on the durability service. This is because for - * TRANSIENT_LOCAL, the data should only remain available for late-joining - * readers during the lifetime of its source writer, so it is not required to survive after - * its source writer has been deleted. Since the deletion of a writer implicitly - * unregisters all its instances, an autodispose_unregistered_instances - * value of TRUE will also dispose the affected data from the durability store, and - * thus prevent it from remaining available to late joining readers. - */ - #ifdef OMG_DDS_PERSISTENCE_SUPPORT - , - TRANSIENT, /**< Some samples are available to late-joining - * DataReaders (stored in memory). This means that the late-joining - * DataReaders are able to read these previously written samples. The - * DataReader does not necessarily have to exist at the time of writing. Not all - * samples are stored (depending on QosPolicy History and QosPolicy - * resource_limits). The storage does not depend on the DataWriter and will - * outlive the DataWriter. This may be used to implement reallocation of - * applications because the data is saved in the Data Distribution Service (not in the - * DataWriter). This setting is typically used for state related information of an - * application. In this case also the DurabilityServiceQosPolicy settings are - * relevant for the behaviour of the Data Distribution Service. - */ - PERSISTENT /**< The data is stored in permanent storage (e.g. - * hard disk). This means that the samples are also available after a system restart. - * The samples not only outlives the DataWriters, but even the Data Distribution - * Service and the system. This setting is typically used for attributes and settings for - * an application or the system. In this case also the - * DurabilityServiceQosPolicy settings are relevant for the behaviour of the - * Data Distribution Service. - */ - #endif //OMG_DDS_PERSISTENCE_SUPPORT - }; -}; -typedef dds::core::SafeEnum DurabilityKind; - -struct PresentationAccessScopeKind_def -{ - enum Type - { - INSTANCE, /**< Presentation Access Scope is per instance. */ - TOPIC /**< Presentation Access Scope is per topic. */ - - #ifdef OMG_DDS_OBJECT_MODEL_SUPPORT - , - GROUP /**< Presentation Access Scope is per group. */ - #endif // OMG_DDS_OBJECT_MODEL_SUPPORT - }; -}; -typedef dds::core::SafeEnum PresentationAccessScopeKind; - - -struct ReliabilityKind_def -{ - enum Type - { - BEST_EFFORT, /**< The Data Distribution Service will only - * attempt to deliver the data; no arrival-checks are being performed and any lost - * data is not re-transmitted (non-reliable). Presumably new values for the samples - * are generated often enough by the application so that it is not necessary to resent - * or acknowledge any samples. - */ - RELIABLE /**< The Data Distribution Service will attempt to - * deliver all samples in the DataWriters history; arrival-checks are performed - * and data may get re-transmitted in case of lost data. In the steady-state (no - * modifications communicated via the DataWriter) the Data Distribution Service - * guarantees that all samples in the DataWriter history will eventually be - * delivered to the all DataReader objects. Outside the steady-state the - * HistoryQosPolicy and ResourceLimitsQosPolicy determine how - * samples become part of the history and whether samples can be discarded from it. - * In this case also the max_blocking_time must be set. - */ - }; -}; -typedef dds::core::SafeEnum ReliabilityKind; - - -struct DestinationOrderKind_def -{ - enum Type - { - BY_RECEPTION_TIMESTAMP, /**< The order is based on the timestamp, at the moment the sample was - * received by the DataReader. - */ - BY_SOURCE_TIMESTAMP /**< The order is based on the timestamp, which was set by the - * DataWriter. This means that the system needs some time synchronization. - */ - }; -}; - -typedef dds::core::SafeEnum DestinationOrderKind; - -struct HistoryKind_def -{ - enum Type - { - KEEP_LAST, /**< The Data Distribution Service will only attempt to - * keep the latest values of the instance and discard the older ones. The attribute - * “depth” determines how many samples in history will be stored. In other words, - * only the most recent samples in history are stored. On the publishing side, the - * Data Distribution Service will only keep the most recent “depth” samples of each - * instance of data (identified by its key) managed by the DataWriter. On the - * subscribing side, the DataReader will only keep the most recent “depth” - * samples received for each instance (identified by its key) until the application - * “takes” them via the DataReader::take operation. - * KEEP_LAST_HISTORY_QOS - is the default kind. The default value of depth is - * 1, indicating that only the most recent value should be delivered. If a depth other - * than 1 is specified, it should be compatible with the settings of the - * ResourcelimitsQosPolicy max_samples_per_instance. For these two - * QosPolicy settings to be compatible, they must verify that depth <= - * max_samples_per_instance, otherwise a - * RETCODE_INCONSISTENT_POLICY is generated on relevant operations. - */ - KEEP_ALL /**< All samples are stored, provided, the resources are - * available. On the publishing side, the Data Distribution Service will attempt to - * keep all samples (representing each value written) of each instance of data - * (identified by its key) managed by the DataWriter until they can be delivered to - * all subscribers. On the subscribing side, the Data Distribution Service will - * attempt to keep all samples of each instance of data (identified by its key) - * managed by the DataReader. These samples are kept until the application - * “takes” them from the Data Distribution Service via the DataReader::take - * operation. The setting of depth has no effect. Its implied value is - * LENGTH_UNLIMITED. The resources that the Data Distribution Service can use to - * keep this history are limited by the settings of the ResourceLimitsQosPolicy. - * If the limit is reached, the behaviour of the Data Distribution Service will depend - * on the ReliabilityQosPolicy. If the ReliabilityQosPolicy is - * BEST_EFFORT_RELIABILITY_QOS, the old values are discarded. If - * ReliabilityQosPolicy is RELIABLE_RELIABILITY_QOS, the Data - * Distribution Service will block the DataWriter until it can deliver the necessary - * old values to all subscribers. - */ - }; -}; - -typedef dds::core::SafeEnum HistoryKind; - -struct LivelinessKind_def -{ - enum Type - { - AUTOMATIC, /**< The Data Distribution Service will take care of - * reporting the Liveliness automatically with a rate determined by the - * lease_duration. - */ - MANUAL_BY_PARTICIPANT, /**< The application must take care - * of reporting the liveliness before the lease_duration expires. If an Entity - * reports its liveliness, all Entities within the same DomainParticipant that - * have their liveliness kind set to MANUAL_BY_PARTICIPANT_LIVELINESS_QOS, - * can be considered alive by the Data Distribution Service. Liveliness can reported - * explicitly by calling the operation assert_liveliness on the - * DomainParticipant or implicitly by writing some data. - */ - MANUAL_BY_TOPIC /**< The application must take care of - * reporting the liveliness before the lease_duration expires. This can explicitly - * be done by calling the operation assert_liveliness on the DataWriter or - * implicitly by writing some data. - */ - }; -}; -typedef dds::core::SafeEnum LivelinessKind; - -/* This isn't standard! -struct TypeConsistencyEnforcementKind_def -{ - enum Type - { - EXACT_TYPE_TYPE_CONSISTENCY, - EXACT_NAME_TYPE_CONSISTENCY, - DECLARED_TYPE_CONSISTENCY, - ASSIGNABLE_TYPE_CONSISTENCY - }; -}; -*/ -struct TypeConsistencyEnforcementKind_def -{ - using Type = eprosima::fastdds::dds::TypeConsistencyKind; -}; - -typedef dds::core::SafeEnum TypeConsistencyEnforcementKind; - -} //namespace policy -} //namespace core -} //namespace dds - -#endif //OMG_DDS_CORE_POLICY_POLICYKIND_HPP_ diff --git a/include/dds/core/policy/QosPolicyCount.hpp b/include/dds/core/policy/QosPolicyCount.hpp deleted file mode 100644 index 5ab1e2256c3..00000000000 --- a/include/dds/core/policy/QosPolicyCount.hpp +++ /dev/null @@ -1,93 +0,0 @@ -/* Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * All rights reserved. - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_CORE_POLICY_QOS_POLICY_COUNT_HPP_ -#define OMG_DDS_CORE_POLICY_QOS_POLICY_COUNT_HPP_ - -#include -#include - -namespace dds { -namespace core { -namespace policy { - -using QosPolicyId = detail::QosPolicyId; -using QosPolicyCountSeq = detail::QosPolicyCountSeq; - -/** - * The QosPolicyCount object shows, for a QosPolicy, the total number of - * times that the concerned DataWriter discovered a DataReader for the - * same Topic and a requested DataReaderQos that is incompatible with - * the one offered by the DataWriter. - */ -class QosPolicyCount : public dds::core::Value -{ -public: - - /** - * Creates a QosPolicyCount instance - * - * @param policy_id the policy_id - * @param count the count - */ - QosPolicyCount( - QosPolicyId policy_id, - int32_t count) - : dds::core::Value(policy_id, count) - { - } - - /** - * Copies a QosPolicyCount instance - * - * @param other the QosPolicyCount instance to copy - */ - QosPolicyCount( - const QosPolicyCount& other) - : dds::core::Value(other.policy_id(), other.count()) - { - } - - /** - * Gets the policy_id - * - * @return the policy_id - */ - QosPolicyId policy_id() const - { - return this->delegate().policy_id; - } - - /** - * Gets the count - * - * @return the count - */ - int32_t count() const - { - return this->delegate().count; - } - -}; - -} //namespace policy -} //namespace core -} //namespace dds - -#endif //OMG_DDS_CORE_POLICY_QOS_POLICY_COUNT_HPP_ diff --git a/include/dds/core/policy/detail/CorePolicy.hpp b/include/dds/core/policy/detail/CorePolicy.hpp deleted file mode 100644 index 69ced6d4c3d..00000000000 --- a/include/dds/core/policy/detail/CorePolicy.hpp +++ /dev/null @@ -1,98 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_CORE_POLICY_DETAIL_CORE_POLICY_HPP_ -#define EPROSIMA_DDS_CORE_POLICY_DETAIL_CORE_POLICY_HPP_ - -#include -#include -#include - -/** - * @cond - * Ignore this file in the API - */ - -namespace dds { -namespace core { -namespace policy { -namespace detail { - -// #ifdef OMG_DDS_EXTENSIBLE_AND_DYNAMIC_TOPIC_TYPE_SUPPORT -using DataRepresentation = eprosima::fastdds::dds::DataRepresentationQosPolicy; -// #endif // OMG_DDS_EXTENSIBLE_AND_DYNAMIC_TOPIC_TYPE_SUPPORT - -using Deadline = eprosima::fastdds::dds::DeadlineQosPolicy; - -using DestinationOrder = eprosima::fastdds::dds::DestinationOrderQosPolicy; - -using Durability = eprosima::fastdds::dds::DurabilityQosPolicy; - -// #ifdef OMG_DDS_PERSISTENCE_SUPPORT -using DurabilityService = eprosima::fastdds::dds::DurabilityServiceQosPolicy; -// #endif // OMG_DDS_PERSISTENCE_SUPPORT - -using EntityFactory = eprosima::fastdds::dds::EntityFactoryQosPolicy; - -using GroupData = eprosima::fastdds::dds::GroupDataQosPolicy; - -using History = eprosima::fastdds::dds::HistoryQosPolicy; - -using LatencyBudget = eprosima::fastdds::dds::LatencyBudgetQosPolicy; - -using Lifespan = eprosima::fastdds::dds::LifespanQosPolicy; - -using Liveliness = eprosima::fastdds::dds::LivelinessQosPolicy; - -using Ownership = eprosima::fastdds::dds::OwnershipQosPolicy; - -// #ifdef OMG_DDS_OWNERSHIP_SUPPORT -using OwnershipStrength = eprosima::fastdds::dds::OwnershipStrengthQosPolicy; -// #endif //OMG_DDS_OWNERSHIP_SUPPORT - -using Partition = eprosima::fastdds::dds::PartitionQosPolicy; - -using Presentation = eprosima::fastdds::dds::PresentationQosPolicy; - -using ReaderDataLifecycle = eprosima::fastdds::dds::ReaderDataLifecycleQosPolicy; - -using Reliability = eprosima::fastdds::dds::ReliabilityQosPolicy; - -using ResourceLimits = eprosima::fastdds::dds::ResourceLimitsQosPolicy; - -using TimeBasedFilter = eprosima::fastdds::dds::TimeBasedFilterQosPolicy; - -using TopicData = eprosima::fastdds::dds::TopicDataQosPolicy; - -using TransportPriority = eprosima::fastdds::dds::TransportPriorityQosPolicy; - -// #ifdef OMG_DDS_EXTENSIBLE_AND_DYNAMIC_TOPIC_TYPE_SUPPORT -using TypeConsistencyEnforcement = eprosima::fastdds::dds::TypeConsistencyEnforcementQosPolicy; -// #endif //OMG_DDS_EXTENSIBLE_AND_DYNAMIC_TOPIC_TYPE_SUPPORT - -using UserData = eprosima::fastdds::dds::UserDataQosPolicy; - -using WriterDataLifecycle = eprosima::fastdds::dds::WriterDataLifecycleQosPolicy; - -} //namespace detail -} //namespace policy -} //namespace core -} //namespace dds - -/** @endcond */ - -#endif //EPROSIMA_DDS_CORE_POLICY_DETAIL_CORE_POLICY_HPP_ diff --git a/include/dds/core/policy/detail/CorePolicyImpl.hpp b/include/dds/core/policy/detail/CorePolicyImpl.hpp deleted file mode 100644 index 66b95039c63..00000000000 --- a/include/dds/core/policy/detail/CorePolicyImpl.hpp +++ /dev/null @@ -1,1424 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_CORE_POLICY_TCOREPOLICY_IMPL_HPP_ -#define EPROSIMA_DDS_CORE_POLICY_TCOREPOLICY_IMPL_HPP_ - -/** - * @file - */ - -/* - * OMG PSM class declaration - */ -#include - -namespace dds { -namespace core { -namespace policy { - -//TUserData - -template -TUserData::TUserData() - : dds::core::Value() -{ -} - -template -TUserData::TUserData( - const dds::core::ByteSeq& sequence) - : dds::core::Value(sequence) -{ -} - -/** @internal @bug OSPL-1746 Implementation required */ -template -TUserData::TUserData( - const uint8_t* value_begin, - const uint8_t* value_end) -{ - //To implement -} - -template -TUserData::TUserData( - const TUserData& other) - : dds::core::Value(other.delegate()) -{ -} - -template -TUserData& TUserData::value( - const dds::core::ByteSeq& sequence) -{ - //To implement - // this->delegate().value(sequence); - // return *this; -} - -/** @internal @bug OSPL-1746 Implementation required */ -template -template -TUserData& TUserData::value( - OCTET_ITER begin, - OCTET_ITER end) -{ - //To implement - //#ifdef _WIN32 - //#pragma warning( push ) - //#pragma warning( disable : 4702 ) //disable warning caused by temporary exception, remove later - //#endif - // ISOCPP_THROW_EXCEPTION(ISOCPP_ERROR, "Function not currently supported"); - //#ifdef _WIN32 - //#pragma warning ( pop ) //re-enable warning to prevent leaking to user code, remove later - //#endif - // return *this; -} - -template -const dds::core::ByteSeq TUserData::value() const -{ - //To implement - // return this->delegate().value(); -} - -/** @internal @bug OSPL-1746 Implementation required */ -template -const uint8_t* TUserData::begin() const -{ - //To implement - //#ifdef _WIN32 - //#pragma warning( push ) - //#pragma warning( disable : 4702 ) //disable warning caused by temporary exception, remove later - //#endif - // ISOCPP_THROW_EXCEPTION(ISOCPP_ERROR, "Function not currently supported"); - //#ifdef _WIN32 - //#pragma warning ( pop ) //re-enable warning to prevent leaking to user code, remove later - //#endif - // return NULL; -} - -/** @internal @bug OSPL-1746 Implementation required */ -template -const uint8_t* TUserData::end() const -{ - //To implement - //#ifdef _WIN32 - //#pragma warning( push ) - //#pragma warning( disable : 4702 ) //disable warning caused by temporary exception, remove later - //#endif - // ISOCPP_THROW_EXCEPTION(ISOCPP_ERROR, "Function not currently supported"); - //#ifdef _WIN32 - //#pragma warning ( pop ) //re-enable warning to prevent leaking to user code, remove later - //#endif - // return NULL; -} - -//TGroupData - -template -TGroupData::TGroupData() - : dds::core::Value() -{ -} - -template -TGroupData::TGroupData( - const dds::core::ByteSeq& sequence) - : dds::core::Value(sequence) -{ -} - -template -TGroupData::TGroupData( - const TGroupData& other) - : dds::core::Value(other.delegate()) -{ -} - -template -TGroupData::TGroupData( - const uint8_t* value_begin, - const uint8_t* value_end) -{ - //To implement - //#ifdef _WIN32 - //#pragma warning( push ) - //#pragma warning( disable : 4702 ) //disable warning caused by temporary exception, remove later - //#endif - // ISOCPP_THROW_EXCEPTION(ISOCPP_ERROR, "Function not currently supported"); - //#ifdef _WIN32 - //#pragma warning ( pop ) //re-enable warning to prevent leaking to user code, remove later - //#endif -} - -template -TGroupData& TGroupData::value( - const dds::core::ByteSeq& sequence) -{ - //To implement - // this->delegate().value(sequence); - // return *this; -} - -/** @internal @bug OSPL-1746 Implementation required */ -template -template -TGroupData& TGroupData::value( - OCTET_ITER begin, - OCTET_ITER end) -{ - //To implement - //#ifdef _WIN32 - //#pragma warning( push ) - //#pragma warning( disable : 4702 ) //disable warning caused by temporary exception, remove later - //#endif - // ISOCPP_THROW_EXCEPTION(ISOCPP_ERROR, "Function not currently supported"); - //#ifdef _WIN32 - //#pragma warning ( pop ) //re-enable warning to prevent leaking to user code, remove later - //#endif - // return *this; -} - -template -const dds::core::ByteSeq TGroupData::value() const -{ - //To implement - // return this->delegate().value(); -} - -/** @internal @bug OSPL-1746 Implementation required */ -template -const uint8_t* TGroupData::begin() const -{ - //To implement - //#ifdef _WIN32 - //#pragma warning( push ) - //#pragma warning( disable : 4702 ) //disable warning caused by temporary exception, remove later - //#endif - // ISOCPP_THROW_EXCEPTION(ISOCPP_ERROR, "Function not currently supported"); - //#ifdef _WIN32 - //#pragma warning ( pop ) //re-enable warning to prevent leaking to user code, remove later - //#endif - // return NULL; -} - -/** @internal @bug OSPL-1746 Implementation required */ -template -const uint8_t* TGroupData::end() const -{ - //To implement - //#ifdef _WIN32 - //#pragma warning( push ) - //#pragma warning( disable : 4702 ) //disable warning caused by temporary exception, remove later - //#endif - // ISOCPP_THROW_EXCEPTION(ISOCPP_ERROR, "Function not currently supported"); - //#ifdef _WIN32 - //#pragma warning ( pop ) //re-enable warning to prevent leaking to user code, remove later - //#endif - // return NULL; -} - -//TTopicData - -template -TTopicData::TTopicData() - : dds::core::Value() -{ -} - -template -TTopicData::TTopicData( - const dds::core::ByteSeq& sequence) - : dds::core::Value(sequence) -{ -} - -template -TTopicData::TTopicData( - const TTopicData& other) - : dds::core::Value(other.delegate()) -{ -} - -/** @internal @bug OSPL-1746 Implementation required */ -template -TTopicData::TTopicData( - const uint8_t* value_begin, - const uint8_t* value_end) -{ - //To implement - -} - -template -TTopicData& TTopicData::value( - const dds::core::ByteSeq& sequence) -{ - //To implement - // this->delegate().value(sequence); - // return *this; -} - -/** @internal @bug OSPL-1746 Implementation required */ -template -template -TTopicData& TTopicData::value( - OCTET_ITER begin, - OCTET_ITER end) -{ - //To implement - //#ifdef _WIN32 - //#pragma warning( push ) - //#pragma warning( disable : 4702 ) //disable warning caused by temporary exception, remove later - //#endif - // ISOCPP_THROW_EXCEPTION(ISOCPP_ERROR, "Function not currently supported"); - //#ifdef _WIN32 - //#pragma warning ( pop ) //re-enable warning to prevent leaking to user code, remove later - //#endif - // return *this; -} - -template -const dds::core::ByteSeq TTopicData::value() const -{ - //To implement - // return this->delegate().value(); -} - -/** @internal @bug OSPL-1746 Implementation required */ -template -const uint8_t* TTopicData::begin() const -{ - //To implement - //#ifdef _WIN32 - //#pragma warning( push ) - //#pragma warning( disable : 4702 ) //disable warning caused by temporary exception, remove later - //#endif - // ISOCPP_THROW_EXCEPTION(ISOCPP_ERROR, "Function not currently supported"); - //#ifdef _WIN32 - //#pragma warning ( pop ) //re-enable warning to prevent leaking to user code, remove later - //#endif - // return NULL; -} - -/** @internal @bug OSPL-1746 Implementation required */ -template -const uint8_t* TTopicData::end() const -{ - //To implement - //#ifdef _WIN32 - //#pragma warning( push ) - //#pragma warning( disable : 4702 ) //disable warning caused by temporary exception, remove later - //#endif - // ISOCPP_THROW_EXCEPTION(ISOCPP_ERROR, "Function not currently supported"); - //#ifdef _WIN32 - //#pragma warning ( pop ) //re-enable warning to prevent leaking to user code, remove later - //#endif - // return NULL; -} - -//TEntityFactory - -template -TEntityFactory::TEntityFactory( - bool autoenable_created_entities) - : dds::core::Value(autoenable_created_entities) -{ -} - -template -TEntityFactory::TEntityFactory( - const TEntityFactory& other) - : dds::core::Value(other.delegate()) -{ -} - -template -TEntityFactory& TEntityFactory::autoenable_created_entities( - bool autoenable_created_entities) -{ - //To implement - // this->delegate().auto_enable(autoenable_created_entities); - // return *this; -} - -template -bool TEntityFactory::autoenable_created_entities() const -{ - //To implement - // return this->delegate().auto_enable(); -} - -template -TEntityFactory TEntityFactory::AutoEnable() -{ - //To implement - // return TEntityFactory(true); -} - -template -TEntityFactory TEntityFactory::ManuallyEnable() -{ - //To implement - // return TEntityFactory(false); -} - -//TTransportPriority - -template -TTransportPriority::TTransportPriority( - int32_t priority) - : dds::core::Value(priority) -{ -} - -template -TTransportPriority::TTransportPriority( - const TTransportPriority& other) - : dds::core::Value(other.delegate()) -{ -} - -template -TTransportPriority& TTransportPriority::value( - int32_t priority) -{ - //To implement - // this->delegate().value(priority); - // return *this; -} - -template -int32_t TTransportPriority::value() const -{ - //To implement - // return this->delegate().value(); -} - -//TLifeSpan - -template -TLifespan::TLifespan( - const dds::core::Duration& duration) - : dds::core::Value(duration) -{ -} - -template -TLifespan::TLifespan( - const TLifespan& other) - : dds::core::Value(other.delegate()) -{ -} - -template -TLifespan& TLifespan::duration( - const dds::core::Duration& duration) -{ - //To implement - // this->delegate().duration(duration); - // return *this; -} - -template -const dds::core::Duration TLifespan::duration() const -{ - //To implement - // return this->delegate().duration(); -} - -//TDeadline - -template -TDeadline::TDeadline( - const dds::core::Duration& period) - : dds::core::Value(period) -{ -} - -template -TDeadline::TDeadline( - const TDeadline& other) - : dds::core::Value(other.delegate()) -{ -} - -template -TDeadline& TDeadline::period( - const dds::core::Duration& period) -{ - //To implement - // this->delegate().period(period); - // return *this; -} - -template -const dds::core::Duration TDeadline::period() const -{ - //To implement - // return this->delegate().period(); -} - -//TLatencyBudget - -template -TLatencyBudget::TLatencyBudget( - const dds::core::Duration& duration) - : dds::core::Value(duration) -{ -} - -template -TLatencyBudget::TLatencyBudget( - const TLatencyBudget& other) - : dds::core::Value(other.delegate()) -{ -} - -template -TLatencyBudget& TLatencyBudget::duration( - const dds::core::Duration& duration) -{ - //To implement - // this->delegate().duration(duration); - // return *this; -} - -template -const dds::core::Duration TLatencyBudget::duration() const -{ - //To implement - // return this->delegate().duration(); -} - -//TTimeBasedFilter -template -TTimeBasedFilter::TTimeBasedFilter( - const dds::core::Duration& minimum_separation) - : dds::core::Value(minimum_separation) -{ -} - -template -TTimeBasedFilter::TTimeBasedFilter( - const TTimeBasedFilter& other) - : dds::core::Value(other.delegate()) -{ -} - -template -TTimeBasedFilter& TTimeBasedFilter::minimum_separation( - const dds::core::Duration& minimum_separation) -{ - //To implement - // this->delegate().min_separation(minimum_separation); - // return *this; - -} - -template -const dds::core::Duration TTimeBasedFilter::minimum_separation() const -{ - //To implement - // return this->delegate().min_separation(); -} - -//TPartition - -template -TPartition::TPartition( - const std::string& name) - : dds::core::Value(name) -{ -} - -template -TPartition::TPartition( - const dds::core::StringSeq& names) - : dds::core::Value(names) -{ -} - -template -TPartition::TPartition( - const TPartition& other) - : dds::core::Value(other.delegate()) -{ -} - -template -TPartition& TPartition::name( - const std::string& name) -{ - //To implement - // this->delegate().name(name); - // return *this; -} - -template -TPartition& TPartition::name( - const dds::core::StringSeq& names) -{ - //To implement - // this->delegate().name(names); - // return *this; -} - -template -const dds::core::StringSeq TPartition::name() const -{ - //To implement - // return this->delegate().name(); -} - -#ifdef OMG_DDS_OWNERSHIP_SUPPORT - -//TOwnership - -template -TOwnership::TOwnership( - dds::core::policy::OwnershipKind::Type kind) - : dds::core::Value(kind) -{ -} - -template -TOwnership::TOwnership( - const TOwnership& other) - : dds::core::Value(other.delegate()) -{ -} - -template -TOwnership& TOwnership::kind( - dds::core::policy::OwnershipKind::Type kind) -{ - //To implement - // this->delegate().kind(kind); - // return *this; -} - -template -dds::core::policy::OwnershipKind::Type TOwnership::kind() const -{ - //To implement - // return this->delegate().kind(); -} - -template -TOwnership TOwnership::Exclusive() -{ - //To implement - // return TOwnership(dds::core::policy::OwnershipKind::EXCLUSIVE); -} - -template -TOwnership TOwnership::Shared() -{ - //To implement - // return TOwnership(dds::core::policy::OwnershipKind::SHARED); -} - -//TOwnershipStrength -template -TOwnershipStrength::TOwnershipStrength( - int32_t strength) - : dds::core::Value(strength) -{ -} - -template -TOwnershipStrength::TOwnershipStrength( - const TOwnershipStrength& other) - : dds::core::Value(other.delegate()) -{ -} - -template -int32_t TOwnershipStrength::value() const -{ - //To implement - // return this->delegate().strength(); -} - -template -TOwnershipStrength& TOwnershipStrength::value( - int32_t strength) -{ - //To implement - // this->delegate().strength(strength); - // return *this; -} - -#endif //OMG_DDS_OWNERSHIP_SUPPORT - -//TWriterDataLifeCycle -template -TWriterDataLifecycle::TWriterDataLifecycle( - bool autodispose_unregistered_instances) - : dds::core::Value(autodispose_unregistered_instances) -{ -} - -template -TWriterDataLifecycle::TWriterDataLifecycle( - const TWriterDataLifecycle& other) - : dds::core::Value(other.delegate()) -{ -} - -template -bool TWriterDataLifecycle::autodispose_unregistered_instances() const -{ - //To implement - // return this->delegate().autodispose(); -} - -template -TWriterDataLifecycle& TWriterDataLifecycle::autodispose_unregistered_instances( - bool autodispose_unregistered_instances) -{ - //To implement - // this->delegate().autodispose(autodispose_unregistered_instances); - // return *this; -} - -template -TWriterDataLifecycle TWriterDataLifecycle::AutoDisposeUnregisteredInstances() -{ - //To implement - // return TWriterDataLifecycle(true); -} - -template -TWriterDataLifecycle TWriterDataLifecycle::ManuallyDisposeUnregisteredInstances() -{ - //To implement - // return TWriterDataLifecycle(false); -} - -//TReaderDataLifecycle -template -TReaderDataLifecycle::TReaderDataLifecycle( - const dds::core::Duration& autopurge_nowriter_samples_delay, - const dds::core::Duration& autopurge_disposed_samples_delay) - : dds::core::Value(autopurge_nowriter_samples_delay, autopurge_disposed_samples_delay) -{ -} - -template -TReaderDataLifecycle::TReaderDataLifecycle( - const TReaderDataLifecycle& other) - : dds::core::Value(other.delegate()) -{ -} - -template -const dds::core::Duration TReaderDataLifecycle::autopurge_nowriter_samples_delay() const -{ - //To implement - // return this->delegate().autopurge_nowriter_samples_delay(); -} - -template -TReaderDataLifecycle& TReaderDataLifecycle::autopurge_nowriter_samples_delay( - const dds::core::Duration& autopurge_nowriter_samples_delay) -{ - //To implement - // this->delegate().autopurge_nowriter_samples_delay(autopurge_nowriter_samples_delay); - // return *this; -} - -template -const dds::core::Duration TReaderDataLifecycle::autopurge_disposed_samples_delay() const -{ - //To implement - // return this->delegate().autopurge_disposed_samples_delay(); -} - -template -TReaderDataLifecycle& TReaderDataLifecycle::autopurge_disposed_samples_delay( - const dds::core::Duration& autopurge_disposed_samples_delay) -{ - //To implement - // this->delegate().autopurge_disposed_samples_delay(autopurge_disposed_samples_delay); - // return *this; -} - -template -TReaderDataLifecycle TReaderDataLifecycle::NoAutoPurgeDisposedSamples() -{ - //To implement - // return TReaderDataLifecycle(); -} - -template -TReaderDataLifecycle TReaderDataLifecycle::AutoPurgeDisposedSamples( - const dds::core::Duration& autopurge_disposed_samples_delay) -{ - //To implement - // return TReaderDataLifecycle().autopurge_disposed_samples_delay(autopurge_disposed_samples_delay); -} - -//TDurability - -template -TDurability::TDurability( - dds::core::policy::DurabilityKind::Type kind) - : dds::core::Value(kind) -{ -} - -template -TDurability::TDurability( - const TDurability& other) - : dds::core::Value(other.delegate()) -{ -} - -template -TDurability& TDurability::kind( - dds::core::policy::DurabilityKind::Type kind) -{ - //To implement - // this->delegate().kind(kind); - // return *this; -} - -template -dds::core::policy::DurabilityKind::Type TDurability::kind() const -{ - //To implement - // return this->delegate().kind(); -} - -template -TDurability TDurability::Volatile() -{ - //To implement - // return TDurability(dds::core::policy::DurabilityKind::VOLATILE); -} - -template -TDurability TDurability::TransientLocal() -{ - //To implement - // return TDurability(dds::core::policy::DurabilityKind::TRANSIENT_LOCAL); -} - -template -TDurability TDurability::Transient() -{ - //To implement - // return TDurability(dds::core::policy::DurabilityKind::TRANSIENT); -} - -template -TDurability TDurability::Persistent() -{ - //To implement - // return TDurability(dds::core::policy::DurabilityKind::PERSISTENT); -} - -//TPresentation -template -TPresentation::TPresentation( - dds::core::policy::PresentationAccessScopeKind::Type access_scope, - bool coherent_access, - bool ordered_access) - : dds::core::Value(access_scope, coherent_access, ordered_access) -{ -} - -template -TPresentation::TPresentation( - const TPresentation& other) - : dds::core::Value(other.delegate()) -{ -} - -template -TPresentation& TPresentation::access_scope( - dds::core::policy::PresentationAccessScopeKind::Type access_scope) -{ - //To implement - // this->delegate().access_scope(access_scope); - // return *this; -} - -template -dds::core::policy::PresentationAccessScopeKind::Type TPresentation::access_scope() const -{ - //To implement - // return this->delegate().access_scope(); -} - -template -TPresentation& TPresentation::coherent_access( - bool coherent_access) -{ - //To implement - // this->delegate().coherent_access(coherent_access); - // return *this; -} - -template -bool TPresentation::coherent_access() const -{ - //To implement - // return this->delegate().coherent_access(); -} - -template -TPresentation& TPresentation::ordered_access( - bool ordered_access) -{ - //To implement - // this->delegate().ordered_access(ordered_access); - // return *this; -} - -template -bool TPresentation::ordered_access() const -{ - //To implement - // return this->delegate().ordered_access(); -} - -template -TPresentation TPresentation::GroupAccessScope( - bool coherent_access, - bool ordered_access) -{ - //To implement - // return TPresentation(dds::core::policy::PresentationAccessScopeKind::GROUP, coherent_access, ordered_access); -} - -template -TPresentation TPresentation::InstanceAccessScope( - bool coherent_access, - bool ordered_access) -{ - //To implement - // return TPresentation(dds::core::policy::PresentationAccessScopeKind::INSTANCE, coherent_access, ordered_access); -} - -template -TPresentation TPresentation::TopicAccessScope( - bool coherent_access, - bool ordered_access) -{ - //To implement - // return TPresentation(dds::core::policy::PresentationAccessScopeKind::TOPIC, coherent_access, ordered_access); -} - -//TReliability -template -TReliability::TReliability( - dds::core::policy::ReliabilityKind::Type kind, - const dds::core::Duration& max_blocking_time) - : dds::core::Value(kind, max_blocking_time) -{ -} - -template -TReliability::TReliability( - const TReliability& other) - : dds::core::Value(other.delegate()) -{ -} - -template -TReliability& TReliability::kind( - dds::core::policy::ReliabilityKind::Type kind) -{ - //To implement - // this->delegate().kind(kind); - // return *this; -} - -template -dds::core::policy::ReliabilityKind::Type TReliability::kind() const -{ - //To implement - // return this->delegate().kind(); -} - -template -TReliability& TReliability::max_blocking_time( - const dds::core::Duration& max_blocking_time) -{ - //To implement - // this->delegate().max_blocking_time(max_blocking_time); - // return *this; -} - -template -const dds::core::Duration TReliability::max_blocking_time() const -{ - //To implement - // return this->delegate().max_blocking_time(); -} - -template -TReliability TReliability::Reliable( - const dds::core::Duration& max_blocking_time) -{ - //To implement - // return TReliability(dds::core::policy::ReliabilityKind::RELIABLE, max_blocking_time); -} - -template -TReliability TReliability::BestEffort( - const dds::core::Duration& max_blocking_time) -{ - //To implement - // return TReliability(dds::core::policy::ReliabilityKind::BEST_EFFORT, max_blocking_time); -} - -//TDestinationOrder - -template -TDestinationOrder::TDestinationOrder( - dds::core::policy::DestinationOrderKind::Type kind) - : dds::core::Value(kind) -{ -} - -template -TDestinationOrder::TDestinationOrder( - const TDestinationOrder& other) - : dds::core::Value(other.delegate()) -{ -} - -template -TDestinationOrder& TDestinationOrder::kind( - dds::core::policy::DestinationOrderKind::Type kind) -{ - //To implement - // this->delegate().kind(kind); - // return *this; -} - -template -dds::core::policy::DestinationOrderKind::Type TDestinationOrder::kind() const -{ - //To implement - // return this->delegate().kind(); -} - -template -TDestinationOrder TDestinationOrder::SourceTimestamp() -{ - //To implement - // return TDestinationOrder(dds::core::policy::DestinationOrderKind::BY_SOURCE_TIMESTAMP); -} - -template -TDestinationOrder TDestinationOrder::ReceptionTimestamp() -{ - //To implement - // return TDestinationOrder(dds::core::policy::DestinationOrderKind::BY_RECEPTION_TIMESTAMP); -} - -//THistory -template -THistory::THistory( - dds::core::policy::HistoryKind::Type kind, - int32_t depth) - : dds::core::Value(kind, depth) -{ -} - -template -THistory::THistory( - const THistory& other) - : dds::core::Value(other.delegate()) -{ -} - -template -dds::core::policy::HistoryKind::Type THistory::kind() const -{ - //To implement - // return this->delegate().kind(); -} - -template -THistory& THistory::kind( - dds::core::policy::HistoryKind::Type kind) -{ - //To implement - // this->delegate().kind(kind); - // return *this; -} - -template -int32_t THistory::depth() const -{ - //To implement - // return this->delegate().depth(); -} - -template -THistory& THistory::depth( - int32_t depth) -{ - //To implement - // this->delegate().depth(depth); - // return *this; -} - -template -THistory THistory::KeepAll() -{ - //To implement - // return THistory(dds::core::policy::HistoryKind::KEEP_ALL, 1); -} - -template -THistory THistory::KeepLast( - uint32_t depth) -{ - //To implement - // return THistory(dds::core::policy::HistoryKind::KEEP_LAST, depth); -} - -//TResourceLimits -template -TResourceLimits::TResourceLimits( - int32_t max_samples, - int32_t max_instances, - int32_t max_samples_per_instance) - : dds::core::Value(max_samples, max_instances, max_samples_per_instance) -{ -} - -template -TResourceLimits::TResourceLimits( - const TResourceLimits& other) - : dds::core::Value(other.delegate()) -{ -} - -template -TResourceLimits& TResourceLimits::max_samples( - int32_t max_samples) -{ - //To implement - // this->delegate().max_samples(max_samples); - // return *this; -} - -template -int32_t TResourceLimits::max_samples() const -{ - //To implement - // return this->delegate().max_samples(); -} - -template -TResourceLimits& TResourceLimits::max_instances( - int32_t max_instances) -{ - //To implement - // this->delegate().max_instances(max_instances); - // return *this; -} - -template -int32_t TResourceLimits::max_instances() const -{ - //To implement - // return this->delegate().max_instances(); -} - -template -TResourceLimits& TResourceLimits::max_samples_per_instance( - int32_t max_samples_per_instance) -{ - //To implement - // this->delegate().max_samples_per_instance(max_samples_per_instance); - // return *this; -} - -template -int32_t TResourceLimits::max_samples_per_instance() const -{ - //To implement - // return this->delegate().max_samples_per_instance(); -} - -//TLiveliness -template -TLiveliness::TLiveliness( - dds::core::policy::LivelinessKind::Type kind, - const dds::core::Duration& lease_duration) - : dds::core::Value(kind, lease_duration) -{ -} - -template -TLiveliness::TLiveliness( - const TLiveliness& other) - : dds::core::Value(other.delegate()) -{ -} - -template -TLiveliness& TLiveliness::kind( - dds::core::policy::LivelinessKind::Type kind) -{ - //To implement - // this->delegate().kind(kind); - // return *this; -} - -template -dds::core::policy::LivelinessKind::Type TLiveliness::kind() const -{ - //To implement - // return this->delegate().kind(); -} - -template -TLiveliness& TLiveliness::lease_duration( - const dds::core::Duration& lease_duration) -{ - //To implement - // this->delegate().lease_duration(lease_duration); - // return *this; -} - -template -const dds::core::Duration TLiveliness::lease_duration() const -{ - //To implement - // return this->delegate().lease_duration(); -} - -template -TLiveliness TLiveliness::Automatic() -{ - //To implement - // return TLiveliness(dds::core::policy::LivelinessKind::AUTOMATIC, dds::core::Duration::infinite()); -} - -template -TLiveliness TLiveliness::ManualByParticipant( - const dds::core::Duration& lease_duration) -{ - //To implement - // return TLiveliness(dds::core::policy::LivelinessKind::MANUAL_BY_PARTICIPANT, lease_duration); -} - -template -TLiveliness TLiveliness::ManualByTopic( - const dds::core::Duration& lease_duration) -{ - //To implement - // return TLiveliness(dds::core::policy::LivelinessKind::MANUAL_BY_TOPIC, lease_duration); -} - -#ifdef OMG_DDS_PERSISTENCE_SUPPORT - -//TDurabilityService - -template -TDurabilityService::TDurabilityService( - const dds::core::Duration& service_cleanup_delay, - dds::core::policy::HistoryKind::Type history_kind, - int32_t history_depth, - int32_t max_samples, - int32_t max_instances, - int32_t max_samples_per_instance) - : dds::core::Value(service_cleanup_delay, - history_kind, - history_depth, - max_samples, - max_instances, - max_samples_per_instance) -{ -} - -template -TDurabilityService::TDurabilityService( - const TDurabilityService& other) - : dds::core::Value(other.delegate()) -{ -} - -template -TDurabilityService& TDurabilityService::service_cleanup_delay( - const dds::core::Duration& service_cleanup_delay) -{ - //To implement - // this->delegate().service_cleanup_delay(service_cleanup_delay); - // return *this; -} - -template -const dds::core::Duration TDurabilityService::service_cleanup_delay() const -{ - //To implement - return this->delegate().service_cleanup_delay(); -} - -template -TDurabilityService& TDurabilityService::history_kind( - dds::core::policy::HistoryKind::Type kind) -{ - //To implement - // this->delegate().history_kind(kind); - // return *this; -} - -template -dds::core::policy::HistoryKind::Type TDurabilityService::history_kind() const -{ - //To implement - // return this->delegate().history_kind(); -} - -template -TDurabilityService& TDurabilityService::history_depth( - int32_t history_depth) -{ - //To implement - // this->delegate().history_depth(history_depth); - // return *this; -} - -template -int32_t TDurabilityService::history_depth() const -{ - //To implement - // return this->delegate().history_depth(); -} - -template -TDurabilityService& TDurabilityService::max_samples( - int32_t max_samples) -{ - //To implement - // this->delegate().max_samples(max_samples); - // return *this; -} - -template -int32_t TDurabilityService::max_samples() const -{ - //To implement - // return this->delegate().max_samples(); -} - -template -TDurabilityService& TDurabilityService::max_instances( - int32_t max_instances) -{ - //To implement - // this->delegate().max_instances(max_instances); - // return *this; -} - -template -int32_t TDurabilityService::max_instances() const -{ - //To implement - // return this->delegate().max_instances(); -} - -template -TDurabilityService& TDurabilityService::max_samples_per_instance( - int32_t max_samples_per_instance) -{ - //To implement - // this->delegate().max_samples_per_instance(max_samples_per_instance); - // return *this; -} - -template -int32_t TDurabilityService::max_samples_per_instance() const -{ - //To implement - // return this->delegate().max_samples_per_instance(); -} - -#endif // OMG_DDS_PERSISTENCE_SUPPORT - - -#ifdef OMG_DDS_EXTENSIBLE_AND_DYNAMIC_TOPIC_TYPE_SUPPORT - -//TDataRepresentation - -/** @internal @bug OSPL-1746 Implementation required */ -template -TDataRepresentation::TDataRepresentation( - const dds::core::policy::DataRepresentationIdSeq& value); - -template -TDataRepresentation::TDataRepresentation( - const TDataRepresentation& other) - : dds::core::Value(other.delegate()) -{ -} - -/** @internal @bug OSPL-1746 Implementation required */ -template -TDataRepresentation& TDataRepresentation::value( - const dds::core::policy::DataRepresentationIdSeq& value); - -/** @internal @bug OSPL-1746 Implementation required */ -template -const dds::core::policy::DataRepresentationIdSeq TDataRepresentation::value() const; - -#endif //OMG_DDS_EXTENSIBLE_AND_DYNAMIC_TOPIC_TYPE_SUPPORT - -#ifdef OMG_DDS_EXTENSIBLE_AND_DYNAMIC_TOPIC_TYPE_SUPPORT - -//TTypeConsistencyEnforcement - -/** @internal @bug OSPL-1746 Implementation required */ -template -TTypeConsistencyEnforcement::TTypeConsistencyEnforcement( - dds::core::policy::TypeConsistencyEnforcementKind::Type kind) -{ -} - -/** @internal @bug OSPL-1746 Implementation required */ -template -TTypeConsistencyEnforcement& TTypeConsistencyEnforcement::kind( - dds::core::policy::TypeConsistencyEnforcementKind::Typekind) -{ -} - -/** @internal @bug OSPL-1746 Implementation required */ -template -dds::core::policy::TypeConsistencyEnforcementKind::Type TTypeConsistencyEnforcement::kind() const -{ -} - -#endif //OMG_DDS_EXTENSIBLE_AND_DYNAMIC_TOPIC_TYPE_SUPPORT - -} //namespace policy -} //namespace core -} //namespace dds - -#endif //EPROSIMA_DDS_CORE_POLICY_TCOREPOLICY_IMPL_HPP_ diff --git a/include/dds/core/policy/detail/QosPolicyCount.hpp b/include/dds/core/policy/detail/QosPolicyCount.hpp deleted file mode 100644 index b384edd470c..00000000000 --- a/include/dds/core/policy/detail/QosPolicyCount.hpp +++ /dev/null @@ -1,46 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_CORE_POLICY_DETAIL_QOS_POLICY_COUNT_HPP_ -#define EPROSIMA_DDS_CORE_POLICY_DETAIL_QOS_POLICY_COUNT_HPP_ - -#include - -/** - * @cond - * Ignore this file in the API - */ - -namespace dds { -namespace core { -namespace policy { -namespace detail { - -using QosPolicyId = eprosima::fastdds::dds::QosPolicyId_t; - -using QosPolicyCount = eprosima::fastdds::dds::QosPolicyCount; - -using QosPolicyCountSeq = eprosima::fastdds::dds::QosPolicyCountSeq; - -} //namespace detail -} //namespace policy -} //namespace core -} //namespace dds - -/** @endcond */ - -#endif //EPROSIMA_DDS_CORE_POLICY_DETAIL_QOS_POLICY_COUNT_HPP_ diff --git a/include/dds/core/ref_traits.hpp b/include/dds/core/ref_traits.hpp deleted file mode 100644 index 8c93fcf439f..00000000000 --- a/include/dds/core/ref_traits.hpp +++ /dev/null @@ -1,59 +0,0 @@ -/* - * Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_CORE_REF_TRAITS_H_ -#define OMG_DDS_CORE_REF_TRAITS_H_ - -namespace dds { -namespace core { - -/** @cond - * These traits must be provided by compliant implementations - * to enable safe polymorphic casts. - */ - -template< - typename T1, - typename T2> -struct is_base_of; - -template< - typename T1, - typename T2> -struct is_same; - -template -struct smart_ptr_traits; - -template< - typename TO, - typename FROM> -TO polymorphic_cast( - FROM& from); - -/** @endcond */ - -} //namespace core -} //namespace dds - -// This include should stay here as it provides implementations -// for the declaration immediately above. -#include - -#endif //OMG_DDS_CORE_REF_TRAITS_H diff --git a/include/dds/core/refmacros.hpp b/include/dds/core/refmacros.hpp deleted file mode 100644 index f7589b0c2b9..00000000000 --- a/include/dds/core/refmacros.hpp +++ /dev/null @@ -1,186 +0,0 @@ -/* - * Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_CORE_REFMACROS_HPP_ -#define OMG_DDS_CORE_REFMACROS_HPP_ - -//////////////////////////////////////////////////////////////////////////////// -// Macros -//////////////////////////////////////////////////////////////////////////////// - -#define DECLARE_TYPE_TRAITS(TYPE) \ - typedef TYPE TYPE ## _T; \ - typedef typename ::dds::core::smart_ptr_traits::ref_type TYPE ## _REF_T; \ - typedef typename ::dds::core::smart_ptr_traits::weak_ref_type TYPE ## _WEAK_REF_T; - - -/* - * This macro defines all the functions that Reference Types have to implement. - */ -//////////////////////////////////////////////////////////////////////////////// -// Defines all the types, functions and attributes required for a Reference type -// without default ctor. -// - -#define OMG_DDS_REF_TYPE_BASE(TYPE, BASE, DELEGATE) \ -public: \ - typedef typename ::dds::core::smart_ptr_traits< DELEGATE >::ref_type DELEGATE_REF_T; \ - typedef typename ::dds::core::smart_ptr_traits< DELEGATE >::weak_ref_type DELEGATE_WEAK_REF_T; \ - \ -protected: \ - const typename ::dds::core::Reference< DELEGATE >::DELEGATE_REF_T& impl() const \ - { return ::dds::core::Reference< DELEGATE >::impl_; } \ - typename ::dds::core::Reference< DELEGATE >::DELEGATE_REF_T& impl() \ - { return ::dds::core::Reference< DELEGATE >::impl_; } \ - \ -public: \ - typedef BASE< DELEGATE > BASE_T; \ - \ -public: \ - TYPE(const dds::core::null_type&) : dds::core::Reference< DELEGATE >(static_cast(NULL)) { } \ - \ - TYPE& operator =( \ - const dds::core::null_type& rhs) { \ - *this = TYPE(rhs); \ - return *this; \ - } \ - \ -public: \ - TYPE(const DELEGATE_REF_T &ref) \ - : dds::core::Reference< DELEGATE >(ref) \ - { } - -#define OMG_DDS_IMPLICIT_REF_BASE(TYPE) \ -public: \ - template \ - TYPE(const H__ &h) \ - { \ - if (h.is_nil()){ \ - /* We got a null object and are not really able to do a typecheck here. */ \ - /* So, just set a null object. */ \ - *this = dds::core::null; \ - } else { \ - this->impl_ = h.delegate(); \ - if (h.delegate() != this->::dds::core::Reference< DELEGATE_T >::impl_){ \ - throw dds::core::IllegalOperationError(std::string( \ - "Attempted invalid cast: ") + typeid(h).name() + " to " + typeid(*this).name()); \ - } \ - } \ - } \ - \ - template \ - TYPE& \ - operator =( \ - const T__& rhs) { \ - if (this != (TYPE*)&rhs){ \ - if (rhs.is_nil()){ \ - /* We got a null object and are not really able to do a typecheck here. */ \ - /* So, just set a null object. */ \ - *this = dds::core::null; \ - } else { \ - TYPE other(rhs); \ - /* Dont have to copy when the delegate impl is the same. */ \ - if (other.delegate() != this->::dds::core::Reference< DELEGATE_T >::impl_){ \ - *this = other; \ - } \ - } \ - } \ - return *this; \ - } - -#define OMG_DDS_EXPLICIT_REF_BASE_DECL(TYPE, FROM) \ -public: \ - TYPE(const FROM &h); \ - \ - TYPE& \ - operator =( \ - const FROM& rhs); - -#define OMG_DDS_EXPLICIT_REF_BASE(TYPE, FROM) \ -public: \ - /* We need to support both const and non-const conversion explicitly, because it could */ \ - /* be that the class has a constructor that takes a single non-const template argument. */ \ - /* That non-const templated constructor is a closer match than TYPE(const FROM& h); when */ \ - /* creating the TYPE class from a non-const FROM object. */ \ - TYPE(FROM & h) { this->explicit_conversion(const_cast(h)); } \ - TYPE(const FROM &h) { this->explicit_conversion(h); } \ -private: \ - void explicit_conversion(const FROM &h) \ - { \ - if (h.is_nil()){ \ - /* We got a null object and are not really able to do a typecheck here. */ \ - /* So, just set a null object. */ \ - *this = dds::core::null; \ - } else { \ - this->impl_ = h.delegate(); \ - if (h.delegate() != this->::dds::core::Reference< DELEGATE_T >::impl_){ \ - throw dds::core::IllegalOperationError(std::string( \ - "Attempted invalid cast: ") + typeid(h).name() + " to " + typeid(*this).name()); \ - } \ - } \ - } \ - \ -public: \ - TYPE& \ - operator =( \ - const FROM& rhs) { \ - if (this != (TYPE*)&rhs){ \ - if (rhs.is_nil()){ \ - /* We got a null object and are not really able to do a typecheck here. */ \ - /* So, just set a null object. */ \ - *this = dds::core::null; \ - } else { \ - TYPE other(rhs); \ - /* Dont have to copy when the delegate is the same. */ \ - if (other.delegate() != this->::dds::core::Reference< DELEGATE_T >::impl_){ \ - *this = other; \ - } \ - } \ - } \ - return *this; \ - } - -//////////////////////////////////////////////////////////////////////////////// -// Declares a reference type equipped with a default ctor. -// -#define OMG_DDS_REF_TYPE_PROTECTED_DC(TYPE, BASE, DELEGATE) \ -public: \ - typedef DELEGATE DELEGATE_T; \ - OMG_DDS_REF_TYPE_BASE(TYPE, BASE, DELEGATE_T) \ -protected: \ - TYPE() { } - -#define OMG_DDS_REF_TYPE_PROTECTED_DC_T(TYPE, BASE, T_PARAM, DELEGATE) \ -public: \ - typedef DELEGATE DELEGATE_T; \ - OMG_DDS_REF_TYPE_BASE(TYPE, BASE, DELEGATE_T) \ -protected: \ - TYPE() { } - -#define OMG_DDS_REF_TYPE_NO_DC(TYPE, BASE, DELEGATE) \ -public: \ - typedef DELEGATE DELEGATE_T; \ - OMG_DDS_REF_TYPE_BASE(TYPE, BASE, DELEGATE_T) - -#define OMG_DDS_REF_TYPE_DELEGATE_C(TYPE, BASE, DELEGATE) \ - OMG_DDS_REF_TYPE_PROTECTED_DC(TYPE, BASE, DELEGATE) \ -public: \ - TYPE(DELEGATE_T * impl) : dds::core::Reference< DELEGATE_T >(impl) { } - -#endif //OMG_DDS_CORE_REFMACROS_HPP_ diff --git a/include/dds/core/status/State.hpp b/include/dds/core/status/State.hpp deleted file mode 100644 index 0f62dfc9912..00000000000 --- a/include/dds/core/status/State.hpp +++ /dev/null @@ -1,168 +0,0 @@ -/* - * Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * All rights reserved. - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_CORE_STATUS_STATE_HPP_ -#define OMG_DDS_CORE_STATUS_STATE_HPP_ - -#include -#include -#include - -#include - - -namespace dds { -namespace core { -namespace status { - -/** - * @brief - * Class to contain the statistics about samples that have been rejected. - * - * @see @ref DCPS_Modules_Subscription_SampleInfo "SampleInfo" for more information - */ -class OMG_DDS_API SampleRejectedState : public std::bitset -{ -public: - - /** - * Convenience typedef for std::bitset. - */ - typedef std::bitset MaskType; - - /** - * Construct an empty SampleRejectedState. - */ - SampleRejectedState() - : std::bitset() - { - } - - /** - * Copy constructor. - * - * Construct an SampleRejectedState with existing SampleRejectedState. - * - * @param src the SampleRejectedState to copy from - */ - SampleRejectedState( - const SampleRejectedState& src) - : std::bitset(src) - { - } - - /** - * Construct a SampleRejectedState with existing MaskType. - * - * @param src the MaskType to copy from - */ - SampleRejectedState( - const MaskType& src) - : std::bitset(src) - { - } - - /** - * Get the NOT_REJECTED. - * - *not_rejected - * - No sample has been rejected yet. - * - * @return the not_rejected SampleRejectedState - */ - inline static SampleRejectedState not_rejected() - { - return SampleRejectedState(0u); - } - - /** - * Get the REJECTED_BY_SAMPLES_LIMIT. - * - *rejected_by_samples_limit - * - The sample was rejected because it would - * exceed the maximum number of samples set by the ResourceLimits - * QosPolicy. - * - * @return the rejected_by_samples_limit SampleRejectedState - */ - inline static SampleRejectedState rejected_by_samples_limit() - { - return SampleRejectedState(0x0001 << 1u); - } - - /** - * Get the REJECTED_BY_INSTANCES_LIMIT. - * - *rejected_by_instances_limit - * - The sample was rejected because it would - * exceed the maximum number of instances set by the - * ResourceLimits QosPolicy. - * - * @return the rejected_by_instances_limit SampleRejectedState - */ - inline static SampleRejectedState rejected_by_instances_limit() - { - return SampleRejectedState(0x0001 << 0u); - } - - /** - * Get the REJECTED_BY_SAMPLES_PER_INSTANCE_LIMIT. - * - *rejected_by_samples_per_instance_limit - * - The sample was rejected - * because it would exceed the maximum number of samples per - * instance set by the ResourceLimits QosPolicy. - * - * @return the rejected_by_samples_per_instance_limit SampleRejectedState - */ - inline static SampleRejectedState rejected_by_samples_per_instance_limit() - { - return SampleRejectedState(0x0001 << 2u); - } - -private: - - SampleRejectedState( - uint32_t s) - : std::bitset(s) - { - } - -}; - -/** - * @brief - * StatusMask is a bitmap or bitset field. - * - * This bitset is used to: - * - determine which listener functions to call - * - set conditions in dds::core::cond::StatusCondition - * - indicate status changes when calling dds::core::Entity::status_changes - * - * @see @ref DCPS_Modules_Infrastructure_Status "Status concept" - */ -using StatusMask = eprosima::fastdds::dds::StatusMask; - -} //namespace status -} //namespace core -} //namespace dds - - -#endif //OMG_DDS_CORE_STATUS_STATE_HPP_ diff --git a/include/dds/core/status/Status.hpp b/include/dds/core/status/Status.hpp deleted file mode 100644 index 57171463ee3..00000000000 --- a/include/dds/core/status/Status.hpp +++ /dev/null @@ -1,449 +0,0 @@ -/* - * Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * All rights reserved. - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_CORE_STATUS_STATUS_HPP_ -#define OMG_DDS_CORE_STATUS_STATUS_HPP_ - -#include - -#include -#include -#include -#include - -#include - -namespace dds { -namespace core { -namespace status { - -/** - * \copydoc DCPS_Status_InconsistentTopic - */ -class InconsistentTopicStatus : public dds::core::Value -{ -public: - - OMG_DDS_API InconsistentTopicStatus(); - - /** - * @return Total cumulative count of all inconsistent topics detected. - */ - OMG_DDS_API int32_t total_count() const; - - /** - * @return The incremental number of inconsistent topics since the last time - * the listener was called or the status was read. - */ - OMG_DDS_API int32_t total_count_change() const; -}; - -/** - * \copydoc DCPS_Status_SampleLost - */ -class SampleLostStatus : public dds::core::Value -{ -public: - - OMG_DDS_API SampleLostStatus(); - - /** - * @return Total cumulative count of all samples lost across of instances of data - * published under the Topic. - */ - OMG_DDS_API int32_t total_count() const; - - /** - * @return The incremental number of samples lost since the last time the listener - * was called or the status was read. - */ - OMG_DDS_API int32_t total_count_change() const; -}; - - -/** - * \copydoc DCPS_Status_SampleRejected - */ -class SampleRejectedStatus : public dds::core::Value -{ -public: - - SampleRejectedStatus(); - - /** - * @return Total cumulative count of samples rejected by the DataReader. - */ - OMG_DDS_API int32_t total_count() const; - - /** - * @return The incremental number of samples rejected since the last time the - * listener was called or the status was read. - */ - OMG_DDS_API int32_t total_count_change() const; - - /** - * @return Reason for rejecting the last sample rejected. If no samples have been - * rejected, the reason is the special value NOT_REJECTED. - */ - OMG_DDS_API const dds::core::status::SampleRejectedState last_reason() const; - - /** - * @return Handle to the instance being updated by the last sample that was - * rejected. - */ - OMG_DDS_API const dds::core::InstanceHandle last_instance_handle() const; -}; - -/** - * \copydoc DCPS_Status_LivelinessLost - */ -class LivelinessLostStatus : public dds::core::Value -{ -public: - - OMG_DDS_API LivelinessLostStatus(); - - /** - * @return Total cumulative number of times that a previously-alive DataWriter - * became 'not alive' due to a failure to actively signal its liveliness within - * its offered liveliness period. This count does not change when an - * already not alive DataWriter simply remains not alive for another - * liveliness period. - */ - OMG_DDS_API int32_t total_count() const; - - /** - * @return The change in total_count since the last time the listener was called or - * the status was read. - */ - OMG_DDS_API int32_t total_count_change() const; -}; - -/** - * \copydoc DCPS_Status_LivelinessChanged - */ -class LivelinessChangedStatus : public dds::core::Value -{ -public: - - OMG_DDS_API LivelinessChangedStatus(); - - /** - * @return The total number of currently active DataWriters that write the Topic - * read by the DataReader. This count increases when a newly-matched - * DataWriter asserts its liveliness for the first time or when a DataWriter - * previously considered to be not alive reasserts its liveliness. The count - * decreases when a DataWriter considered alive fails to assert its - * liveliness and becomes not alive, whether because it was deleted - * normally or for some other reason. - */ - OMG_DDS_API int32_t alive_count() const; - - /** - * @return The total count of currently DataWriters that write the Topic read by - * the DataReader that are no longer asserting their liveliness. This count - * increases when a DataWriter considered alive fails to assert its - * liveliness and becomes not alive for some reason other than the normal - * deletion of that DataWriter. It decreases when a previously not alive - * DataWriter either reasserts its liveliness or is deleted normally. - */ - OMG_DDS_API int32_t not_alive_count() const; - - /** - * @return The change in the alive_count since the last time the listener was - * called or the status was read. - */ - OMG_DDS_API int32_t alive_count_change() const; - - /** - * @return The change in the not_alive_count since the last time the listener was - * called or the status was read. - */ - OMG_DDS_API int32_t not_alive_count_change() const; - - /** - * @return Handle to the last DataWriter whose change in liveliness caused this - * status to change. - */ - OMG_DDS_API const dds::core::InstanceHandle last_publication_handle() const; -}; - -/** - * \copydoc DCPS_Status_OfferedDeadlineMissed - */ -class OfferedDeadlineMissedStatus : public dds::core::Value -{ -public: - - OMG_DDS_API OfferedDeadlineMissedStatus(); - - /** - * @return Total cumulative number of offered deadline periods elapsed during - * which a DataWriter failed to provide data. Missed deadlines - * accumulate; that is, each deadline period the total_count will be - * incremented by one. - */ - OMG_DDS_API int32_t total_count() const; - - /** - * @return The change in total_count since the last time the listener was called or - * the status was read. - */ - OMG_DDS_API int32_t total_count_change() const; - - /** - * @return Handle to the last instance in the DataWriter for which an offered - * deadline was missed. - */ - OMG_DDS_API const dds::core::InstanceHandle last_instance_handle() const; -}; - -/** - * \copydoc DCPS_Status_RequestedDeadlineMissed - */ -class RequestedDeadlineMissedStatus : public dds::core::Value -{ -public: - - OMG_DDS_API RequestedDeadlineMissedStatus(); - - /** - * @return Total cumulative number of missed deadlines detected for any instance - * read by the DataReader. Missed deadlines accumulate; that is, each - * deadline period the total_count will be incremented by one for each - * instance for which data was not received. - */ - OMG_DDS_API int32_t total_count() const; - - /** - * @return The incremental number of deadlines detected since the last time the - * listener was called or the status was read. - */ - OMG_DDS_API int32_t total_count_change() const; - - /** - * @return Handle to the last instance in the DataReader for which a deadline was - * detected. - */ - OMG_DDS_API const dds::core::InstanceHandle last_instance_handle() const; -}; - - -/** - * \copydoc DCPS_Status_OfferedIncompatibleQoS - */ -class OfferedIncompatibleQosStatus : public dds::core::Value -{ -public: - - OMG_DDS_API OfferedIncompatibleQosStatus(); - - /** - * @return Total cumulative number of times the concerned DataWriter - * discovered a DataReader for the same Topic with a requested QoS that - * is incompatible with that offered by the DataWriter. - */ - OMG_DDS_API int32_t total_count() const; - - /** - * @return The change in total_count since the last time the listener was called or - * the status was read. - */ - OMG_DDS_API int32_t total_count_change() const; - - /** - * @return The PolicyId of one of the policies that was found to be - * incompatible the last time an incompatibility was detected. - */ - OMG_DDS_API dds::core::policy::QosPolicyId last_policy_id() const; - - /** - * @return A list containing for each policy the total number of times that the - * concerned DataWriter discovered a DataReader for the same Topic - * with a requested QoS that is incompatible with that offered by the - * DataWriter. - */ - OMG_DDS_API const dds::core::policy::QosPolicyCountSeq policies() const; - - /** - * @return A list containing for each policy the total number of times that the - * concerned DataWriter discovered a DataReader for the same Topic - * with a requested QoS that is incompatible with that offered by the - * DataWriter. - * - * @param dst The destination QosPolicyCountSeq the policies will be returned to - */ - OMG_DDS_API const dds::core::policy::QosPolicyCountSeq& policies( - dds::core::policy::QosPolicyCountSeq& dst) const; -}; - -/** - * \copydoc DCPS_Status_RequestedIncompatibleQoS - */ -class RequestedIncompatibleQosStatus : public dds::core::Value -{ -public: - - OMG_DDS_API RequestedIncompatibleQosStatus(); - - /** - * @return Total cumulative number of times the concerned DataReader - * discovered a DataWriter for the same Topic with an offered QoS that - * was incompatible with that requested by the DataReader. - */ - OMG_DDS_API int32_t total_count() const; - - /** - * @return The change in total_count since the last time the listener was called or - * the status was read. - */ - OMG_DDS_API int32_t total_count_change() const; - - /** - * @return The QosPolicyId of one of the policies that was found to be - * incompatible the last time an incompatibility was detected. - */ - OMG_DDS_API dds::core::policy::QosPolicyId last_policy_id() const; - - /** - * @return A list containing for each policy the total number of times that the - * concerned DataReader discovered a DataWriter for the same Topic - * with an offered QoS that is incompatible with that requested by the - * DataReader. - */ - OMG_DDS_API const dds::core::policy::QosPolicyCountSeq policies() const; - - /** - * @return A list containing for each policy the total number of times that the - * concerned DataReader discovered a DataWriter for the same Topic - * with an offered QoS that is incompatible with that requested by the - * DataReader. - * - * @param dst The destination QosPolicyCountSeq the policies will be returned to - */ - OMG_DDS_API const dds::core::policy::QosPolicyCountSeq& policies( - dds::core::policy::QosPolicyCountSeq& dst) const; -}; - -/** - * \copydoc DCPS_Status_PublicationMatched - */ -class PublicationMatchedStatus : public dds::core::Value -{ -public: - - OMG_DDS_API PublicationMatchedStatus(); - - /** - * @return Total cumulative count the concerned DataWriter discovered a - * "match" with a DataReader. That is, it found a DataReader for the - * same Topic with a requested QoS that is compatible with that offered - * by the DataWriter. - */ - OMG_DDS_API int32_t total_count() const; - - /** - * @return The change in total_count since the last time the listener was called or - * the status was read. - */ - OMG_DDS_API int32_t total_count_change() const; - - /** - * @return The number of DataReaders currently matched to the concerned - * DataWriter. - */ - OMG_DDS_API int32_t current_count() const; - - /** - * @return The change in current_count since the last time the listener was called - * or the status was read. - */ - OMG_DDS_API int32_t current_count_change() const; - - /** - * @return Handle to the last DataReader that matched the DataWriter causing the - * status to change. - */ - OMG_DDS_API const dds::core::InstanceHandle last_subscription_handle() const; -}; - -/** - * \copydoc DCPS_Status_SubscriptionMatched - */ -class SubscriptionMatchedStatus : public dds::core::Value -{ -public: - - OMG_DDS_API SubscriptionMatchedStatus(); - - /** - * @return Total cumulative count the concerned DataReader discovered a - * "match" with a DataWriter. That is, it found a DataWriter for the same - * Topic with a requested QoS that is compatible with that offered by the - * DataReader. - */ - OMG_DDS_API int32_t total_count() const; - - /** - * @return The change in total_count since the last time the listener was called or - * the status was read. - */ - OMG_DDS_API int32_t total_count_change() const; - - /** - * @return The number of DataWriters currently matched to the concerned - * DataReader. - */ - OMG_DDS_API int32_t current_count() const; - - /** - * @return The change in current_count since the last time the listener was called - * or the status was read. - */ - OMG_DDS_API int32_t current_count_change() const; - - /** - * @return Handle to the last DataWriter that matched the DataReader causing the - * status to change. - */ - OMG_DDS_API const dds::core::InstanceHandle last_publication_handle() const; -}; - - -class DataAvailableStatus -{ - // empty -}; - - -class DataOnReadersStatus -{ - // empty -}; - -// This trait is used to get the state associated with each status -template -StatusMask get_status(); - -} //namespace status -} //namespace core -} //namespace dds - -#endif //OMG_DDS_CORE_STATUS_STATUS_HPP_ diff --git a/include/dds/core/status/detail/Status.hpp b/include/dds/core/status/detail/Status.hpp deleted file mode 100644 index 8282d822af4..00000000000 --- a/include/dds/core/status/detail/Status.hpp +++ /dev/null @@ -1,68 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_CORE_STATUS_DETAIL_STATUS_HPP_ -#define EPROSIMA_DDS_CORE_STATUS_DETAIL_STATUS_HPP_ - -#include -#include -#include -#include -#include -#include -#include - -/** - * @cond - * Ignore this file in the API - */ - -namespace dds { -namespace core { -namespace status { -namespace detail { - -using InconsistentTopicStatus = eprosima::fastdds::dds::InconsistentTopicStatus; - -using LivelinessChangedStatus = eprosima::fastdds::dds::LivelinessChangedStatus; - -using LivelinessLostStatus = eprosima::fastdds::dds::LivelinessLostStatus; - -using OfferedDeadlineMissedStatus = eprosima::fastdds::dds::OfferedDeadlineMissedStatus; - -using OfferedIncompatibleQosStatus = eprosima::fastdds::dds::OfferedIncompatibleQosStatus; - -using PublicationMatchedStatus = eprosima::fastdds::dds::PublicationMatchedStatus; - -using SampleRejectedStatus = eprosima::fastdds::dds::SampleRejectedStatus; - -using RequestedDeadlineMissedStatus = eprosima::fastdds::dds::RequestedDeadlineMissedStatus; - -using RequestedIncompatibleQosStatus = eprosima::fastdds::dds::RequestedIncompatibleQosStatus; - -using SampleLostStatus = eprosima::fastdds::dds::SampleLostStatus; - -using SubscriptionMatchedStatus = eprosima::fastdds::dds::SubscriptionMatchedStatus; - -} //namespace detail -} //namespace status -} //namespace core -} //namespace dds - -/** @endcond */ - -#endif //EPROSIMA_DDS_CORE_STATUS_DETAIL_STATUS_HPP_ diff --git a/include/dds/core/status/detail/StatusImpl.hpp b/include/dds/core/status/detail/StatusImpl.hpp deleted file mode 100644 index c83ab09383a..00000000000 --- a/include/dds/core/status/detail/StatusImpl.hpp +++ /dev/null @@ -1,414 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_CORE_STATUS_TSTATUS_IMPL_HPP_ -#define EPROSIMA_DDS_CORE_STATUS_TSTATUS_IMPL_HPP_ - -/** - * @file - */ - -/* - * OMG PSM class declaration - */ -#include - -namespace dds { -namespace core { -namespace status { - -//TInconsistentTopicStatus - -template -TInconsistentTopicStatus::TInconsistentTopicStatus() - : dds::core::Value() -{ -} - -template -int32_t TInconsistentTopicStatus::total_count() const -{ - //To implement - // return this->delegate().total_count(); -} - -template -int32_t TInconsistentTopicStatus::total_count_change() const -{ - //To implement - // return this->delegate().total_count_change(); -} - -//TSampleLostStatus - -template -TSampleLostStatus::TSampleLostStatus() - : dds::core::Value() -{ -} - -template -int32_t TSampleLostStatus::total_count() const -{ - //To implement - // return this->delegate().total_count(); -} - -template -int32_t TSampleLostStatus::total_count_change() const -{ - //To implement - // return this->delegate().total_count_change(); -} - -//TSampleRejectedStatus - -template -TSampleRejectedStatus::TSampleRejectedStatus() - : dds::core::Value() -{ -} - -template -int32_t TSampleRejectedStatus::total_count() const -{ - //To implement - // return this->delegate().total_count(); -} - -template -int32_t TSampleRejectedStatus::total_count_change() const -{ - //To implement - // return this->delegate().total_count_change(); -} - -template -const dds::core::status::SampleRejectedState TSampleRejectedStatus::last_reason() const -{ - //To implement - // return this->delegate().last_reason(); -} - -template -const dds::core::InstanceHandle TSampleRejectedStatus::last_instance_handle() const -{ - //To implement - // return this->delegate().last_instance_handle(); -} - -//TLivelinessLostStatus -template -TLivelinessLostStatus::TLivelinessLostStatus() - : dds::core::Value() -{ -} - -template -int32_t TLivelinessLostStatus::total_count() const -{ - //To implement - // return this->delegate().total_count(); -} - -template -int32_t TLivelinessLostStatus::total_count_change() const -{ - //To implement - // return this->delegate().total_count_change(); -} - -//TLivelinessChangedStatus - -template -TLivelinessChangedStatus::TLivelinessChangedStatus() - : dds::core::Value() -{ -} - -template -int32_t TLivelinessChangedStatus::alive_count() const -{ - //To implement - // return this->delegate().alive_count(); -} - -template -int32_t TLivelinessChangedStatus::not_alive_count() const -{ - //To implement - // return this->delegate().not_alive_count(); -} - -template -int32_t TLivelinessChangedStatus::alive_count_change() const -{ - //To implement - // return this->delegate().alive_count(); -} - -template -int32_t TLivelinessChangedStatus::not_alive_count_change() const -{ - //To implement - // return this->delegate().not_alive_count(); -} - -template -const dds::core::InstanceHandle TLivelinessChangedStatus::last_publication_handle() const -{ - //To implement - // return this->delegate().last_publication_handle(); -} - -//TOfferedDeadlineMissedStatus - -template -TOfferedDeadlineMissedStatus::TOfferedDeadlineMissedStatus() - : dds::core::Value() -{ -} - -template -int32_t TOfferedDeadlineMissedStatus::total_count() const -{ - //To implement - // return this->delegate().total_count(); -} - -template -int32_t TOfferedDeadlineMissedStatus::total_count_change() const -{ - //To implement - // return this->delegate().total_count_change(); -} - -template -const dds::core::InstanceHandle TOfferedDeadlineMissedStatus::last_instance_handle() const -{ - //To implement - // return this->delegate().last_instance_handle(); -} - -//TRequestedDeadlineMissedStatus - -template -TRequestedDeadlineMissedStatus::TRequestedDeadlineMissedStatus() - : dds::core::Value() -{ -} - -template -int32_t TRequestedDeadlineMissedStatus::total_count() const -{ - //To implement - // return this->delegate().total_count(); -} - -template -int32_t TRequestedDeadlineMissedStatus::total_count_change() const -{ - //To implement - // return this->delegate().total_count_change(); -} - -template -const dds::core::InstanceHandle TRequestedDeadlineMissedStatus::last_instance_handle() const -{ - //To implement - // return this->delegate().last_instance_handle(); -} - -//TOfferedIncompatibleQosStatus - -template -TOfferedIncompatibleQosStatus::TOfferedIncompatibleQosStatus() - : dds::core::Value() -{ -} - -template -int32_t TOfferedIncompatibleQosStatus::total_count() const -{ - //To implement - // return this->delegate().total_count(); -} - -template -int32_t TOfferedIncompatibleQosStatus::total_count_change() const -{ - //To implement - // return this->delegate().total_count_change(); -} - -template -dds::core::policy::QosPolicyId TOfferedIncompatibleQosStatus::last_policy_id() const -{ - //To implement - // return this->delegate().last_policy_id(); -} - -template -const dds::core::policy::QosPolicyCountSeq TOfferedIncompatibleQosStatus::policies() const -{ - //To implement - // return this->delegate().policies(); -} - -template -const dds::core::policy::QosPolicyCountSeq& TOfferedIncompatibleQosStatus::policies( - dds::core::policy::QosPolicyCountSeq& dst) const -{ - //To implement - // return this->delegate().policies(dst); -} - -//TRequestedIncompatibleQosStatus - -template -TRequestedIncompatibleQosStatus::TRequestedIncompatibleQosStatus() - : dds::core::Value() -{ -} - -template -int32_t TRequestedIncompatibleQosStatus::total_count() const -{ - //To implement - // return this->delegate().total_count(); -} - -template -int32_t TRequestedIncompatibleQosStatus::total_count_change() const -{ - //To implement - // return this->delegate().total_count_change(); -} - -template -dds::core::policy::QosPolicyId TRequestedIncompatibleQosStatus::last_policy_id() const -{ - //To implement - // return this->delegate().last_policy_id(); -} - -template -const dds::core::policy::QosPolicyCountSeq TRequestedIncompatibleQosStatus::policies() const -{ - //To implement - // return this->delegate().policies(); -} - -template -const dds::core::policy::QosPolicyCountSeq& TRequestedIncompatibleQosStatus::policies( - dds::core::policy::QosPolicyCountSeq& dst) const -{ - //To implement - // return this->delegate().policies(dst); -} - -//TPublicationMatchedStatus - -template -TPublicationMatchedStatus::TPublicationMatchedStatus() - : dds::core::Value() -{ -} - -template -int32_t TPublicationMatchedStatus::total_count() const -{ - //To implement - // return this->delegate().total_count(); -} - -template -int32_t TPublicationMatchedStatus::total_count_change() const -{ - //To implement - // return this->delegate().total_count_change(); -} - -template -int32_t TPublicationMatchedStatus::current_count() const -{ - //To implement - // return this->delegate().current_count(); -} - -template -int32_t TPublicationMatchedStatus::current_count_change() const -{ - //To implement - // return this->delegate().current_count_change(); -} - -template -const dds::core::InstanceHandle TPublicationMatchedStatus::last_subscription_handle() const -{ - //To implement - // return this->delegate().last_subscription_handle(); -} - -//TSubscriptionMatchedStatus - -template -TSubscriptionMatchedStatus::TSubscriptionMatchedStatus() - : dds::core::Value() -{ -} - -template -int32_t TSubscriptionMatchedStatus::total_count() const -{ - //To implement - // return this->delegate().total_count(); -} - -template -int32_t TSubscriptionMatchedStatus::total_count_change() const -{ - //To implement - // return this->delegate().total_count_change(); -} - -template -int32_t TSubscriptionMatchedStatus::current_count() const -{ - //To implement - // return this->delegate().current_count(); -} - -template -int32_t TSubscriptionMatchedStatus::current_count_change() const -{ - //To implement - // return this->delegate().current_count_change(); -} - -template -const dds::core::InstanceHandle TSubscriptionMatchedStatus::last_publication_handle() const -{ - //To implement - // return this->delegate().last_publication_handle(); -} - -} //namespace status -} //namespace core -} //namespace dds - -#endif //EPROSIMA_DDS_CORE_STATUS_TSTATUS_IMPL_HPP_ diff --git a/include/dds/core/types.hpp b/include/dds/core/types.hpp deleted file mode 100644 index 0f973ee8839..00000000000 --- a/include/dds/core/types.hpp +++ /dev/null @@ -1,67 +0,0 @@ -/* - * Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_CORE_TYPES_HPP_ -#define OMG_DDS_CORE_TYPES_HPP_ - -#include -#include -#include - -#include -#include - -namespace dds { -namespace core { - -/** - * Use a std::vector to hold a sequence of bytes. - */ -typedef std::vector ByteSeq; - -/** - * Use a std::vector to hold a sequence of bytes. - */ -typedef std::vector StringSeq; - -/** - * @brief This class is used to create dds::core::null objects. - */ -class OMG_DDS_API null_type -{ -}; - -/** - * This is the DDS Null-Reference.
    - * A dds reference object that doesn't reference to anything can be compared with this object. - * @code{.cpp} - * dds::domain::DomainParticipant participant = dds::core::null; - * ... - * if (participant == dds::core::null) { - * // The participant is not yet properly created. - * // Using it now will trigger the dds::core::NullReferenceError exception. - * } - * @endcode - */ -extern const null_type OMG_DDS_API null; - -} //namespace core -} //namespace dds - -#endif // OMG_DDS_CORE_TYPES_HPP_ diff --git a/include/dds/core/xtypes/Annotation.hpp b/include/dds/core/xtypes/Annotation.hpp deleted file mode 100644 index 0cfa3c71730..00000000000 --- a/include/dds/core/xtypes/Annotation.hpp +++ /dev/null @@ -1,283 +0,0 @@ -/* - * Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_CORE_XTYPES_ANNOTATION_HPP_ -#define OMG_DDS_CORE_XTYPES_ANNOTATION_HPP_ -#ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC - -#include -#include -#include -#include - -namespace dds { -namespace core { -namespace xtypes { - -template -class TIdAnnotation; - -template -class TAnnotation : public Reference -{ - - OMG_DDS_REF_TYPE_BASE( - TAnnotation, - dds::core::Reference, - DELEGATE) - -public: - - virtual ~TAnnotation(); - - TypeKind kind() const; - - template class K> - operator K&() - { - return reinterpret_cast&>(*this); - } - - const AnnotationKind& akind() const - { - return impl()->akind(); - } - -protected: - - TAnnotation( - const TypeKind& kind); -}; - -template -class TIdAnnotation : public TAnnotation -{ - using TAnnotation::impl; - -public: - - TIdAnnotation( - uint32_t id) - : TAnnotation(TypeKind::ANNOTATION_TYPE) - { - impl()->id(id); - } - - uint32_t id() const - { - return impl()->id(); - } - -}; - -template -class TKeyAnnotation : public TAnnotation -{ - using TAnnotation::impl; - -public: - - TKeyAnnotation() - { - } - -}; - -template -class TSharedAnnotation : public TAnnotation -{ -public: - - TSharedAnnotation() - { - } - -}; - -template -class TNestedAnnotation : public TAnnotation -{ -public: - - TNestedAnnotation() - { - } - -}; - -template -class TExtensibilityAnnotation : public TAnnotation -{ - using TAnnotation::impl; - -public: - - TExtensibilityAnnotation( - ExtensibilityKind xkind) - { - impl()->xKind(); - } - - ExtensibilityKind extensibility_kind() const - { - return impl()->xKind(); - } - -}; - -template -class TMustUnderstandAnnotation : public TAnnotation -{ -public: - - TMustUnderstandAnnotation() - { - } - -}; - -template -class TVerbatimAnnotation : public TAnnotation -{ - using TAnnotation::impl; - -public: - - TVerbatimAnnotation( - const std::string& text) - { - impl()->vbt(text); - } - - const std::string& verbatim_text() const - { - return impl()->vbt(); - } - -}; - -template -class TBitsetAnnotation : public TAnnotation -{ -public: - - TBitsetAnnotation() - { - } - -}; - -template -class TBitBoundAnnotation : public TAnnotation -{ - using TAnnotation::impl; - -public: - - TBitBoundAnnotation( - uint32_t bound) - { - impl()->bsb(bound); - } - - virtual uint32_t bound() const - { - return impl()->bsb(); - } - - void bound( - uint32_t bound) - { - impl()->bsb(bound); - } - -}; - -typedef TAnnotation Annotation; - -typedef TIdAnnotation IdAnnotation; - -typedef TKeyAnnotation KeyAnnotation; - -typedef TSharedAnnotation SharedAnnotation; - -typedef TNestedAnnotation NestedAnnotation; - -typedef TExtensibilityAnnotation ExtensibilityAnnotation; - -typedef TMustUnderstandAnnotation MustUnderstandAnnotation; - -typedef TVerbatimAnnotation VerbatimAnnotation; - -typedef TBitsetAnnotation BitsetAnnotation; - -typedef TBitBoundAnnotation BitBoundAnnotation; - -//FRANAVA We must think about the fact that previous API has a way of creating a -//dynamically defined Annotation. -/* - namespace converter - { - IdAnnotation convert(const Annotation& a) - { - uint32_t idav = reinterpret_cast(a).id(); - return IdAnnotation(idav); - } - } - */ -namespace annotation { - -// These functions can be used to get cached instances, -// to avoid the proliferation of small annotation objects. -IdAnnotation id( - uint32_t); - -KeyAnnotation key(); - -SharedAnnotation shared(); - -NestedAnnotation nested(); - -ExtensibilityAnnotation extensibility( - ExtensibilityKind kind); - -ExtensibilityAnnotation get_final(); - -ExtensibilityAnnotation extensible(); - -ExtensibilityAnnotation get_mutable(); - -MustUnderstandAnnotation must_understand(); - -VerbatimAnnotation verbatim( - const std::string& text); - -BitsetAnnotation bitset(); - -BitsetAnnotation bit_bound( - uint32_t bound); - -} //namespace annotation -} //namespace xtypes -} //namespace core -} //namespace dds - -#endif -#endif //OMG_DDS_CORE_XTYPES_TANNOTATION_HPP_ diff --git a/include/dds/core/xtypes/AnnotationKind.hpp b/include/dds/core/xtypes/AnnotationKind.hpp deleted file mode 100644 index cd2f04cad65..00000000000 --- a/include/dds/core/xtypes/AnnotationKind.hpp +++ /dev/null @@ -1,47 +0,0 @@ -#ifndef OMG_DDS_CORE_ANNOTATIONKIND_H -#define OMG_DDS_CORE_ANNOTATIONKIND_H - - -#include - -namespace dds { -namespace core { -namespace xtypes { - -struct AnnotationKind_def -{ - enum Type - { - ID_ANNOTATION_TYPE, - OPTIONAL_ANNOTATION_TYPE, - KEY_ANNOTATION_TYPE, - SHARED_ANNOTATION_TYPE, - NESTED_ANNOTATION_TYPE, - EXTENSIBILITY_ANNOTATION_TYPE, - MUST_UNDERSTAND_ANNOTATION_TYPE, - VERBATIM_ANNOTATION_TYPE, - BITSET_ANNOTATION_TYPE, - BITSETBOUND_ANNOTATION_TYPE - }; -}; - -typedef dds::core::SafeEnum AnnotationKind; - -struct ExtensibilityKind_def -{ - enum Type - { - FINAL, - EXTENSIBLE, - MUTABLE - }; -}; - -typedef dds::core::SafeEnum ExtensibilityKind; - -} //xtypes -} //core -} //dds - -#endif //OMG_DDS_CORE_ANNOTATIONKIND_H - diff --git a/include/dds/core/xtypes/CollectionTypes.hpp b/include/dds/core/xtypes/CollectionTypes.hpp deleted file mode 100644 index 4efc50d4ae4..00000000000 --- a/include/dds/core/xtypes/CollectionTypes.hpp +++ /dev/null @@ -1,142 +0,0 @@ -/* - * Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_CORE_XTYPES_COLLECTION_TYPES_HPP_ -#define OMG_DDS_CORE_XTYPES_COLLECTION_TYPES_HPP_ - -#include -#include - -namespace dds { -namespace core { -namespace xtypes { - - -template -class TCollectionType : public TDynamicType -{ -public: - - constexpr static uint32_t UNBOUNDED = 0xFFFFFFFF; - - uint32_t bounds() const - { - throw "Not implemented"; - } - -protected: - - TCollectionType( - const std::string& name, - TypeKind kind) - { - throw "Not implemented"; - } - -}; - -template< - typename DELEGATE, - typename DELEGATE_K, - typename DELEGATE_V> -class TMapType : public TCollectionType -{ -public: - - TMapType( - const TDynamicType& key_type, - const TDynamicType& value_type) - { - throw "Not implemented"; - } - - TMapType( - const TDynamicType& key_type, - const TDynamicType& value_type, - uint32_t bounds) - { - throw "Not implemented"; - } - - const TDynamicType& key_type() - { - throw "Not implemented"; - } - - const TDynamicType& value_type() - { - throw "Not implemented"; - } - -}; - - -template< - typename DELEGATE, - typename DELEGATE_T> -class TSequenceType : public TCollectionType -{ -public: - - TSequenceType( - const TDynamicType& type) - { - throw "Not implemented"; - } - - TSequenceType( - const TDynamicType& type, - uint32_t bounds) - { - throw "Not implemented"; - } - -public: - - const TDynamicType& key_type() const - { - throw "Not implemented"; - } - -}; - - -template -class TStringType : public TCollectionType -{ -public: - - TStringType( - uint32_t bounds) - { - throw "Not implemented"; - } - -}; - -typedef TCollectionType CollectionType; -typedef TMapType TypeMap; -typedef TSequenceType SequenceType; -typedef TStringType StringType; - -} //namespace xtypes -} //namespace core -} //namespace dds - -#endif //OMG_DDS_CORE_XTYPES_COLLECTION_TYPES_HPP_ diff --git a/include/dds/core/xtypes/DynamicData.hpp b/include/dds/core/xtypes/DynamicData.hpp deleted file mode 100644 index d18b6241883..00000000000 --- a/include/dds/core/xtypes/DynamicData.hpp +++ /dev/null @@ -1,118 +0,0 @@ -/* - * Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_CORE_XTYPES_DYNAMIC_DATA_HPP_ -#define OMG_DDS_CORE_XTYPES_DYNAMIC_DATA_HPP_ - -#include - -#include -#include - -#include - -namespace dds { -namespace core { -namespace xtypes { - -/** - * This class is used to read/write data for DynamicTypes. It allows reading and - * writing of samples in a type-safe manner but without any compile-time knowledge - * of the type being read or written. - */ -template< - typename DELEGATE, - typename DELEGATE_TYPE> -class TDynamicData : Reference -{ - OMG_DDS_REF_TYPE_PROTECTED_DC( - TDynamicData, - Reference, - DELEGATE) - -public: - - TDynamicData( - const TDynamicType& type) - { - throw "Not implemented"; - } - - template - void value( - uint32_t mid, - const T& v) const - { - throw "Not implemented"; - } - - template - T value( - const std::string& mid, - const T& v) const - { - throw "Not implemented"; - } - - template - T value( - uint32_t mid) const - { - throw "Not implemented"; - } - - template - T value( - const std::string& mid) const - { - throw "Not implemented"; - } - - TDynamicType type() const - { - throw "Not implemented"; - } - - MemberType member_type( - uint32_t id) const - { - throw "Not implemented"; - } - - MemberType member_type( - const std::string& name) const - { - throw "Not implemented"; - } - - uint32_t member_id( - const std::string& name) const - { - throw "Not implemented"; - } - -}; - -typedef TDynamicData DynamicData; - -} //namespace xtypes -} //namespace core -} //namespace dds - -#endif //OMG_DDS_CORE_XTYPES_DYNAMIC_DATA_HPP_ diff --git a/include/dds/core/xtypes/DynamicType.hpp b/include/dds/core/xtypes/DynamicType.hpp deleted file mode 100644 index 8a90e572957..00000000000 --- a/include/dds/core/xtypes/DynamicType.hpp +++ /dev/null @@ -1,171 +0,0 @@ -/* - * Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_CORE_XTYPES_DYNAMIC_TYPE_HPP_ -#define OMG_DDS_CORE_XTYPES_DYNAMIC_TYPE_HPP_ - -#include - -#include -#include - -namespace dds { -namespace core { -namespace xtypes { - -template -class TDynamicType : public Reference -{ - OMG_DDS_REF_TYPE_PROTECTED_DC( - TDynamicType, - Reference, - DELEGATE) - -public: - - const std::string& name() const - { - return impl()->name(); - } - - TypeKind kind() const - { - return impl()->kind(); - } - - const std::vector& annotations() const - { - return impl()->annotations(); - } - - bool operator ==( - const TDynamicType& that) const - { - return *(impl()) == *(that.impl()); - } - - bool operator !=( - const TDynamicType& that) const - { - return !(*this == that); - } - - bool is_primitive_type() - { - return (impl()->kind().underlying() & 0x4000 ) != 0; - } - - bool is_collection_type() - { - return (impl()->kind().underlying() & 0x0200 ) != 0; - } - - bool is_aggregation_type() - { - return (impl()->kind().underlying() & 0x0100 ) != 0; - } - - bool is_constructed_type() - { - return (impl()->kind().underlying() & 0x8000 ) != 0; - } - -protected: - - TDynamicType( - const std::string& name, - TypeKind kind) - { - impl()->name(name); - impl()->kind(kind); - } - - TDynamicType( - const std::string& name, - TypeKind kind, - const Annotation& annotation) - { - impl()->name(name); - impl()->kind(kind); - impl()->annotation(annotation); - } - - TDynamicType( - const std::string& name, - TypeKind kind, - const std::vector& annotations) - { - impl()->name(name); - impl()->kind(kind); - impl()->annotation(annotations); - } - - template - TDynamicType( - const std::string& name, - TypeKind kind, - const AnnotationIter& begin, - const AnnotationIter& end) - { - impl()->name(name); - impl()->kind(kind); - impl()->annotation(begin, end); - } - -public: - - TDynamicType( - const TDynamicType& other) = default; -}; - -template -bool is_primitive_type( - const TDynamicType& t) -{ - return t.is_primitive_type(); -} - -template -bool is_constructed_type( - const TDynamicType& t) -{ - return t.is_constructed_type(); -} - -template -bool is_collection_type( - const TDynamicType& t) -{ - return t.is_collection_type(); -} - -template -bool is_aggregation_type( - const TDynamicType& t) -{ - return t.is_aggregation_type(); -} - -typedef TDynamicType DynamicType; - -} //namespace xtypes -} //namespace core -} //namespace dds - -#endif //OMG_DDS_CORE_XTYPES_DYNAMIC_TYPE_HPP_ diff --git a/include/dds/core/xtypes/MemberType.hpp b/include/dds/core/xtypes/MemberType.hpp deleted file mode 100644 index 5b3815c4fda..00000000000 --- a/include/dds/core/xtypes/MemberType.hpp +++ /dev/null @@ -1,165 +0,0 @@ -/* - * Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_CORE_XTYPES_MEMBER_TYPE_HPP -#define OMG_DDS_CORE_XTYPES_MEMBER_TYPE_HPP - -#include -#include - -#include -#include - - - -namespace dds { -namespace core { -namespace xtypes { - -template< - typename DELEGATE, - typename OTHER_DELEGATE> -class TMemberType : public Reference -{ - OMG_DDS_REF_TYPE_PROTECTED_DC( - TMemberType, - Reference, - DELEGATE) - -public: - - TMemberType( - const std::string& name, - const TDynamicType& type) - { - impl()->name(name); - impl()->dt(type); - } - - TMemberType( - const std::string& name, - const xtypes::DynamicType& type, - const Annotation& annotation) - { - impl()->name(name); - impl()->dt(type); - impl()->annotation(annotation); - } - - TMemberType( - const std::string& name, - const TDynamicType& type, - const std::vector& annotations) - { - impl()->name(name); - impl()->dt(type); - impl()->annotation(annotations); - } - - template - TMemberType( - const std::string& name, - const TDynamicType& type, - const AnnotationIter& begin, - const AnnotationIter& end) - { - impl()->name(name); - impl()->dt(type); - impl()->annotation(begin, end); - } - - const std::string& name() const - { - return impl()->name(); - } - - const TDynamicType& type() const - { - return impl()->dt(); - } - - TMemberType add_annotation( - const Annotation& annotation) - { - impl()->annotation(annotation); - return *this; - } - - TMemberType remove_annotation( - const Annotation& annotation) - { - impl().remove_annotation(annotation); - return *this; - } - - bool is_optional() const - { - return impl()->is_optional(); - } - - bool is_shared() const - { - return impl()->is_shared(); - } - - bool is_key() const - { - return impl()->is_key(); - } - - bool is_must_understand() const - { - return impl()->is_must_understand(); - } - - bool is_bitset() const - { - return impl()->is_bitset(); - } - - bool has_bitbound() const - { - return impl()->has_bitbound(); - } - - uint32_t get_bitbound() const - { - return impl()->get_bitbound(); - } - - bool has_id() const - { - return impl()->has_id(); - } - - uint32_t get_id() const - { - return impl()->get_bitbound(); - } - -}; - -typedef TMemberType MemberType; -typedef MemberType Member; - -} //namespace xtypes -} //namespace core -} //namespace dds - -#endif //OMG_DDS_CORE_XTYPES_MEMBER_TYPE_HPP diff --git a/include/dds/core/xtypes/PrimitiveTypes.hpp b/include/dds/core/xtypes/PrimitiveTypes.hpp deleted file mode 100644 index 5eeb634a2f9..00000000000 --- a/include/dds/core/xtypes/PrimitiveTypes.hpp +++ /dev/null @@ -1,74 +0,0 @@ -/* - * Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_CORE_XTYPES_PRIMITIVE_TYPES_HPP_ -#define OMG_DDS_CORE_XTYPES_PRIMITIVE_TYPES_HPP_ - -#include -#include - -namespace dds { -namespace core { -namespace xtypes { - -template -struct dynamic_type_traits -{ - static constexpr TypeKind TYPE_ID = TypeKind::NO_TYPE; - static constexpr const char* const NAME = "no_type"; -}; - -template< - typename T, - typename DELEGATE> -class TPrimitiveType : public TDynamicType -{ -public: - - TPrimitiveType() - : TDynamicType( - dynamic_type_traits::NAME, - dynamic_type_traits::TYPE_ID) - { - } - -}; - - -/** - * Primitive type constructor. This function can be used - * as follows: - * - * DynamicType int16Type = primitive_type(); - */ -template -TPrimitiveType primitive_type() -{ - throw "Not implemented"; -} - -} //namespace xtypes -} //namespace core -} //namespace dds - -// This include should be at the end since it provides -// template specializations. -#include - -#endif //OMG_DDS_CORE_XTYPES_PRIMITIVE_TYPES_HPP_ diff --git a/include/dds/core/xtypes/StructType.hpp b/include/dds/core/xtypes/StructType.hpp deleted file mode 100644 index da61706f918..00000000000 --- a/include/dds/core/xtypes/StructType.hpp +++ /dev/null @@ -1,203 +0,0 @@ -/* - * Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_CORE_XTYPES_STRUCT_TYPE_HPP_ -#define OMG_DDS_CORE_XTYPES_STRUCT_TYPE_HPP_ - -#include - -#include -#include - -namespace dds { -namespace core { -namespace xtypes { - -template -class TStructForwardDeclaration : public TDynamicType -{ -public: - - TStructForwardDeclaration( - const std::string& name) - { - throw "Not implemented"; - } - -}; - -/** - * Create a dynamic structure type. If the members don't have Id associated - * explicitly, then their ID will be the same as the ordinal position on the - * members vector. - */ -template -class TStructType : public TDynamicType -{ - - TStructType& parent_ts_; - -public: - - explicit TStructType( - const std::string& name) - { - throw "Not implemented"; - } - - TStructType( - const std::string& name, - const std::vector& members) - { - TDynamicType::impl()->name(name); - } - - TStructType( - const std::string& name, - const TStructType& parent, - const std::vector& members) - { - TDynamicType::impl()->name(name); - parent_ts_ = parent; - TDynamicType::impl()->members(members); - } - - template - TStructType( - const std::string& name, - const TStructType& parent, - const MemberIter& begin, - const MemberIter& end) - { - TDynamicType::impl()->name(name); - parent_ts_ = parent; - TDynamicType::impl()->members(begin, end); - } - - TStructType( - const std::string& name, - const TStructType& parent, - const std::vector& members, - const Annotation& annotation) - { - TDynamicType::impl()->name(name); - parent_ts_ = parent; - TDynamicType::impl()->members(members); - TDynamicType::impl()->annotation(annotation); - } - - TStructType( - const std::string& name, - const TStructType& parent, - const std::vector& members, - const std::vector& annotations) - { - TDynamicType::impl()->name(name); - parent_ts_ = parent; - TDynamicType::impl()->members(members); - TDynamicType::impl()->annotations(annotations); - } - - template< - typename AnnotationIter, - typename MemberIter> - TStructType( - const std::string& name, - const TStructType& parent, - const MemberIter& member_begin, - const MemberIter& member_end, - const AnnotationIter& annotation_begin, - const AnnotationIter& annotation_end) - { - TDynamicType::impl()->name(name); - parent_ts_ = parent; - TDynamicType::impl()->members(member_begin, member_end); - TDynamicType::impl()->annotations(annotation_begin, annotation_end); - } - - template - operator TDynamicType() const - { - throw "Not implemented"; - } - - TStructType parent() const - { - return parent_ts_; - } - - const std::vector& members() const - { - return TDynamicType::impl()->members(); - } - - const MemberType& member( - uint32_t id) const - { - return TDynamicType::impl()->member(id); - } - - const MemberType& member( - const std::string& name) const - { - return TDynamicType::impl()->member(name); - } - - const std::vector& annotations() const - { - return TDynamicType::impl()->annotations(); - } - - TStructType add_member( - const MemberType& member) const - { - TDynamicType::impl()->member(member); - return *this; - } - - TStructType remove_member( - const MemberType& member) const - { - TDynamicType::impl()->remove_member(); - return *this; - } - - TStructType add_annotation( - const Annotation& annotation) const - { - TDynamicType::impl()->annotation(annotation); - return *this; - } - - TStructType remove_annotation( - const Annotation& annotation) const - { - TDynamicType::impl()->remove_annotation(annotation); - return *this; - } - -}; - -typedef TStructType StructType; - -} //namespace xtypes -} //namespace core -} //namespace dds - -#endif //OMG_DDS_CORE_XTYPES_STRUCT_TYPE_HPP_ diff --git a/include/dds/core/xtypes/TypeKind.hpp b/include/dds/core/xtypes/TypeKind.hpp deleted file mode 100644 index bea53d35bc4..00000000000 --- a/include/dds/core/xtypes/TypeKind.hpp +++ /dev/null @@ -1,79 +0,0 @@ -/* - * Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_XTYPES_TYPE_KIND_HPP_ -#define OMG_DDS_XTYPES_TYPE_KIND_HPP_ - -#include -#include - -#include - -#if defined(OMG_DDS_X_TYPES_DYNAMIC_TYPE_SUPPORT) - -namespace dds { -namespace core { -namespace xtypes { - -enum class TypeKind -{ - NO_TYPE = 0, // sentinel indicating "null" value - PRIMITIVE_TYPE = 0x4000, - CONSTRUCTED_TYPE = 0x8000, - COLLECTION_TYPE = 0x0200, - AGGREGATION_TYPE = 0x0100, - ANNOTATION_TYPE = 0x0080, - - BOOLEAN_TYPE = PRIMITIVE_TYPE | 0x0001, - UINT_8_TYPE = PRIMITIVE_TYPE | 0x0002, - INT_16_TYPE = PRIMITIVE_TYPE | 0x0003, - UINT_16_TYPE = PRIMITIVE_TYPE | 0x0004, - INT_32_TYPE = PRIMITIVE_TYPE | 0x0005, - UINT_32_TYPE = PRIMITIVE_TYPE | 0x0006, - INT_64_TYPE = PRIMITIVE_TYPE | 0x0007, - UINT_64_TYPE = PRIMITIVE_TYPE | 0x0008, - FLOAT_32_TYPE = PRIMITIVE_TYPE | 0x0009, - FLOAT_64_TYPE = PRIMITIVE_TYPE | 0x000A, - FLOAT_128_TYPE = PRIMITIVE_TYPE | 0x000B, - CHAR_8_TYPE = PRIMITIVE_TYPE | 0x000C, - CHAR_32_TYPE = PRIMITIVE_TYPE | 0x000D, - - ENUMERATION_TYPE = CONSTRUCTED_TYPE | 0x0001, - BITSET_TYPE = CONSTRUCTED_TYPE | 0x0002, - ALIAS_TYPE = CONSTRUCTED_TYPE | 0x0003, - - ARRAY_TYPE = CONSTRUCTED_TYPE | COLLECTION_TYPE | 0x0004, - SEQUENCE_TYPE = CONSTRUCTED_TYPE | COLLECTION_TYPE | 0x0005, - STRING_TYPE = CONSTRUCTED_TYPE | COLLECTION_TYPE | 0x0006, - MAP_TYPE = CONSTRUCTED_TYPE | COLLECTION_TYPE | 0x0007, - - UNION_TYPE = CONSTRUCTED_TYPE | AGGREGATION_TYPE | 0x0008, - STRUCTURE_TYPE = CONSTRUCTED_TYPE | AGGREGATION_TYPE | 0x0009, - UNION_FWD_DECL_TYPE = CONSTRUCTED_TYPE | AGGREGATION_TYPE | 0x000A, - STRUCTURE_FWD_DECL_TYPE = CONSTRUCTED_TYPE | AGGREGATION_TYPE | 0x000B -}; - -} //namespace xtypes -} //namespace core -} //namespace dds - -#endif //OMG_DDS_X_TYPES_DYNAMIC_TYPE_SUPPORT - -#endif //OMG_DDS_XTYPES_TYPE_KIND_HPP_ - diff --git a/include/dds/core/xtypes/TypeProvider.hpp b/include/dds/core/xtypes/TypeProvider.hpp deleted file mode 100644 index 81542677af9..00000000000 --- a/include/dds/core/xtypes/TypeProvider.hpp +++ /dev/null @@ -1,77 +0,0 @@ -/* - * Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_CORE_XTYPES_TYPE_PROVIDER_HPP_ -#define OMG_DDS_CORE_XTYPES_TYPE_PROVIDER_HPP_ - -#include - -#include - -namespace dds { -namespace core { -namespace xtypes { - -/** - * TypeProvider that allows creation of types from external representations. - */ -template -class TTypeProvider -{ -public: - - /** - * Load a type from the specified URI. If multiple types are defined - * only the first one is returned. - */ - static TDynamicType load_type( - const std::string& uri) - { - throw "Not implemented"; - } - - /** - * Load a type from the specified URI. If multiple types are defined - * only the first one is returned. - */ - static std::vector > load_types( - const std::string& uri) - { - throw "Not implemented"; - } - - /** - * Load a named type from the specified URI. - */ - static TDynamicType load_type( - const std::string& uri, - const std::string& name) - { - throw "Not implemented"; - } - -}; - -typedef TTypeProvider TypeProvider; - -} //namespace xtypes -} //namespace core -} //namespace dds - -#endif //OMG_DDS_CORE_XTYPES_TYPE_PROVIDER_HPP_ diff --git a/include/dds/core/xtypes/UnionCase.hpp b/include/dds/core/xtypes/UnionCase.hpp deleted file mode 100644 index 75d682041a6..00000000000 --- a/include/dds/core/xtypes/UnionCase.hpp +++ /dev/null @@ -1,69 +0,0 @@ -/* - * Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_CORE_XTYPES_UNION_CASE_HPP_ -#define OMG_DDS_CORE_XTYPES_UNION_CASE_HPP_ - -#include -#include - -#include - -namespace dds { -namespace core { -namespace xtypes { - -template< - typename T, - template class DELEGATE> -class TUnionCase : public Reference< DELEGATE > -{ -public: - - TUnionCase() - { - } - - TUnionCase( - T discriminator, - const MemberType& member) - { - throw "Not implemented"; - } - - T discriminator() - { - throw "Not implemented"; - } - - const MemberType& member() - { - throw "Not implemented"; - } - -}; - -template -struct UnionCase : public TUnionCase {}; - -} //namespace xtypes -} //namespace core -} //namespace dds - -#endif //OMG_DDS_CORE_XTYPES_T_UNION_CASE_HPP_ diff --git a/include/dds/core/xtypes/UnionType.hpp b/include/dds/core/xtypes/UnionType.hpp deleted file mode 100644 index 88d1170914f..00000000000 --- a/include/dds/core/xtypes/UnionType.hpp +++ /dev/null @@ -1,141 +0,0 @@ -/* - * Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_CORE_XTYPES_T_UNION_TYPE_HPP_ -#define OMG_DDS_CORE_XTYPES_T_UNION_TYPE_HPP_ - -#include - -#include -#include -#include - -#include - -namespace dds { -namespace core { -namespace xtypes { - -/** - * Declares a forward declaration for a union type. - */ -template -class TUnionForwardDeclaration : public TDynamicType -{ -public: - - TUnionForwardDeclaration( - const std::string& name) - { - throw "Not implemented"; - } - -}; - -template< - typename T, - template class DELEGATE> -class TUnionType : public TDynamicType > -{ -public: - - TUnionType( - const std::string& name, - const TPrimitiveType >& discriminator_type, - const std::vector >& cases) - { - throw "Not implemented"; - } - - TUnionType( - const std::string& name, - const TPrimitiveType >& discriminator_type, - const std::vector >& cases, - const Annotation& annotation) - { - throw "Not implemented"; - } - - TUnionType( - const std::string& name, - const TPrimitiveType >& discriminator_type, - const std::vector >& cases, - const std::vector& annotations) - { - throw "Not implemented"; - } - - const std::vector >& members() const - { - throw "Not implemented"; - } - - const MemberType& member( - uint32_t id) const - { - throw "Not implemented"; - } - - const MemberType& member( - const std::string& name) const - { - throw "Not implemented"; - } - - const std::vector& annotations() const - { - throw "Not implemented"; - } - - TUnionType add_member( - const UnionCase& member) const - { - throw "Not implemented"; - } - - TUnionType remove_member( - const UnionCase& member) const - { - throw "Not implemented"; - } - - TUnionType add_annotation( - const Annotation& annotation) const - { - throw "Not implemented"; - } - - TUnionType remove_annotation( - const Annotation& annotation) const - { - throw "Not implemented"; - } - -}; - -template -class UnionType : public TUnionType -{ -}; - -} //namespace xtypes -} //namespace core -} //namespace dds - -#endif //OMG_DDS_CORE_XTYPES_T_STRUCT_TYPE_HPP_ diff --git a/include/dds/core/xtypes/detail/Annotation.hpp b/include/dds/core/xtypes/detail/Annotation.hpp deleted file mode 100644 index a7a4e0515b6..00000000000 --- a/include/dds/core/xtypes/detail/Annotation.hpp +++ /dev/null @@ -1,226 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_CORE_XTYPES_DETAIL_ANNOTATION_HPP_ -#define EPROSIMA_DDS_CORE_XTYPES_DETAIL_ANNOTATION_HPP_ -#include -#include -#include - -namespace dds { -namespace core { -namespace xtypes { -namespace detail { - -class Annotation -{ -public: - - Annotation( - AnnotationKind ak) - : ak_(ak) - { - } - - const AnnotationKind& akind() - { - return ak_; - } - -private: - - AnnotationKind ak_; -}; - -class IdAnnotation : public Annotation -{ -public: - - IdAnnotation() - : Annotation(AnnotationKind::OPTIONAL_ANNOTATION_TYPE) - , id_() - { - } - - void id( - uint32_t id ) - { - id_ = id; - } - - uint32_t id() const noexcept - { - return id_; - } - - template class K> - operator K&() - { - return reinterpret_cast&>(*this); - } - - IdAnnotation( - Annotation& a) - : Annotation(AnnotationKind::ID_ANNOTATION_TYPE) - , id_(static_cast(a).id()) - { - } - -private: - - uint32_t id_; -}; - -class KeyAnnotation : public Annotation -{ -public: - - KeyAnnotation() - : Annotation(AnnotationKind::KEY_ANNOTATION_TYPE) - { - } - -}; - -class SharedAnnotation : public Annotation -{ -public: - - SharedAnnotation() - : Annotation(AnnotationKind::SHARED_ANNOTATION_TYPE) - { - } - -}; - -class NestedAnnotation : public Annotation -{ -public: - - NestedAnnotation() - : Annotation(AnnotationKind::NESTED_ANNOTATION_TYPE) - { - } - -}; - -class ExtensibilityAnnotation : public Annotation -{ -public: - - ExtensibilityAnnotation( - ExtensibilityKind xkind) - : Annotation(AnnotationKind::EXTENSIBILITY_ANNOTATION_TYPE) - , xk_(xkind) - { - } - - const ExtensibilityKind& xKind() const noexcept - { - return xk_; - } - - void xKind( - ExtensibilityKind xk) - { - xk_ = xk; - } - -private: - - ExtensibilityKind xk_; - -}; - -class MustUnderstandAnnotation : public Annotation -{ - MustUnderstandAnnotation() - : Annotation(AnnotationKind::MUST_UNDERSTAND_ANNOTATION_TYPE) - { - } - -}; - -class VerbatimAnnotation : public Annotation -{ -public: - - VerbatimAnnotation( - const std::string& vbt) - : Annotation(AnnotationKind::VERBATIM_ANNOTATION_TYPE) - , vbt_(vbt) - { - } - - void vbt( - const std::string& vbt) - { - vbt_ = vbt; - } - - const std::string& vbt() const noexcept - { - return vbt_; - } - -private: - - std::string vbt_; -}; - - -class BitsetAnnotation : public Annotation -{ - BitsetAnnotation() - : Annotation(AnnotationKind::BITSET_ANNOTATION_TYPE) - { - } - -}; - -class BitBoundAnnotation : public Annotation -{ - BitBoundAnnotation( - uint32_t bsb ) - : Annotation(AnnotationKind::BITSETBOUND_ANNOTATION_TYPE) - , bsb_(bsb) - { - } - - uint32_t bsb() const noexcept - { - return bsb_; - } - - void bsb( - uint32_t bsb) - { - bsb_ = bsb; - } - -private: - - uint32_t bsb_; -}; - -} //namespace detail -} //namespace xtypes -} //namespace core -} //namespace dds - -#endif //EPROSIMA_DDS_CORE_XTYPES_DETAIL_ANNOTATION_HPP_ diff --git a/include/dds/core/xtypes/detail/CollectionTypes.hpp b/include/dds/core/xtypes/detail/CollectionTypes.hpp deleted file mode 100644 index c7fa286a3fe..00000000000 --- a/include/dds/core/xtypes/detail/CollectionTypes.hpp +++ /dev/null @@ -1,47 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_CORE_XTYPES_DETAIL_COLLECTION_TYPES_HPP_ -#define EPROSIMA_DDS_CORE_XTYPES_DETAIL_COLLECTION_TYPES_HPP_ - -#include - -namespace dds { -namespace core { -namespace xtypes { -namespace detail { - -class CollectionType : public DynamicType -{ -}; -class MapType : public CollectionType -{ -}; -class SequenceType : public CollectionType -{ -}; -class StringType : public CollectionType -{ -}; - -} //namespace detail -} //namespace xtypes -} //namespace core -} //namespace dds - -#endif //EPROSIMA_DDS_CORE_XTYPES_DETAIL_COLLECTION_TYPES_HPP_ - diff --git a/include/dds/core/xtypes/detail/DynamicData.hpp b/include/dds/core/xtypes/detail/DynamicData.hpp deleted file mode 100644 index accccbce86a..00000000000 --- a/include/dds/core/xtypes/detail/DynamicData.hpp +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_CORE_XTYPES_DETAIL_DYNAMICDATA_HPP_ -#define EPROSIMA_DDS_CORE_XTYPES_DETAIL_DYNAMICDATA_HPP_ - -namespace dds { -namespace core { -namespace xtypes { -namespace detail { - -class DynamicData -{ -}; - -} //namespace detail -} //namespace xtypes -} //namespace core -} //namespace dds - -#endif //EPROSIMA_DDS_CORE_XTYPES_DETAIL_DYNAMICDATA_HPP_ diff --git a/include/dds/core/xtypes/detail/DynamicType.hpp b/include/dds/core/xtypes/detail/DynamicType.hpp deleted file mode 100644 index 13eca3b1024..00000000000 --- a/include/dds/core/xtypes/detail/DynamicType.hpp +++ /dev/null @@ -1,101 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ -#ifndef EPROSIMA_DDS_CORE_XTYPES_DETAIL_DYNAMIC_TYPE_HPP_ -#define EPROSIMA_DDS_CORE_XTYPES_DETAIL_DYNAMIC_TYPE_HPP_ - -#include -#include -#include -#include - -namespace dds { -namespace core { -namespace xtypes { -namespace detail { - -class DynamicType -{ -public: - - const std::string& name() const noexcept - { - return name_; - } - - const TypeKind& kind() const noexcept - { - return kind_; - } - - void name( - const std::string& name) - { - name_ = name; - } - - void kind( - const TypeKind& kind) - { - kind_ = kind; - } - - void annotation( - xtypes::Annotation& a) - { - ann_.push_back(a); - } - - void annotation( - const std::vector& annotations) - { - ann_.reserve(annotations.size() + ann_.size()); - for (auto it = annotations.begin(); it != annotations.end(); ++it) - { - ann_.emplace_back(*it); - } - } - - template - void annotation( - AnnoIter begin, - AnnoIter end) - { - ann_.reserve(ann_.size() + ( end - begin) ); - for (auto it = begin; it != end; ++it) - { - ann_.emplace_back(*it); - } - } - - const std::vector& annotations() const - { - return ann_; - } - -private: - - std::string name_; - TypeKind kind_; - std::vector ann_; -}; - -} //namespace detail -} //namespace xtypes -} //namespace core -} //namespace dds - -#endif //EPROSIMA_DDS_CORE_XTYPES_DETAIL_DYNAMIC_TYPE_HPP_ diff --git a/include/dds/core/xtypes/detail/MemberType.hpp b/include/dds/core/xtypes/detail/MemberType.hpp deleted file mode 100644 index df02f4d6884..00000000000 --- a/include/dds/core/xtypes/detail/MemberType.hpp +++ /dev/null @@ -1,245 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_CORE_XTYPES_DETAIL_MEMBER_TYPE_HPP_ -#define EPROSIMA_DDS_CORE_XTYPES_DETAIL_MEMBER_TYPE_HPP_ - -#include -#include - -#include -#include -#include - -namespace dds { -namespace core { -namespace xtypes { -namespace detail { - -class MemberType -{ -public: - - MemberType( - const std::string& name, - xtypes::DynamicType& dt) - : name_(name) -#if (0) - , dt_(dt.name(), dt.kind(), dt.annotations()) -#else - , dt_(dt) -#endif - , ann_() - { - } - - MemberType( - const std::string& name, - xtypes::DynamicType& dt, - xtypes::Annotation& a) - : name_(name) - , dt_(dt) - , ann_() - { - ann_.push_back(a); - } - - void name( - const std::string& name) - { - name_ = name; - } - - void dt( - const xtypes::DynamicType& dt) - { - dt_ = dt; - } - - void annotations( - std::vector& ann) - { - ann_.reserve(ann.size() + ann_.size()); - for (auto it = ann.begin(); it != ann.end(); ++it) - { - ann_.emplace_back(*it); - } - } - - template - void annotations( - AnnoIter begin, - AnnoIter end) - { - ann_.reserve(ann_.size() + ( end - begin) ); - for (auto it = begin; it != end; ++it) - { - ann_.emplace_back(*it); - } - } - - void annotation( - xtypes::Annotation& ann) - { - ann_.push_back(ann); - } - - const std::string& name() const noexcept - { - return name_; - } - - const xtypes::DynamicType& dynamic_type() const noexcept - { - return dt_; - } - - const std::vector& annotations() - { - return ann_; - } - - void remove_annotation( - const xtypes::Annotation& a) - { - auto rem = std::find_if( - ann_.begin(), - ann_.end(), - [&]( xtypes::Annotation& b) - { - return b.akind() == a.akind(); - } - ); - if ( rem != ann_.end() ) - { - ann_.erase(rem); - } - } - - bool annotation_iterator( - AnnotationKind& annotation_kind, - xtypes::Annotation& retAnn) - { - auto retVal = std::find_if( - ann_.begin(), - ann_.end(), - [&]( xtypes::Annotation& a) - { - return (a.akind() == annotation_kind); - } - ); - - if (retVal == ann_.end()) - { - return false; - } - retAnn = *retVal; - return true; - } - - bool find_annotation( - AnnotationKind& annotation_kind) - { - return ann_.end() != std::find_if( - ann_.begin(), - ann_.end(), - [&]( xtypes::Annotation& a) - { - return (a.akind() == annotation_kind); - } - ); - } - - bool is_optional() - { - AnnotationKind a = AnnotationKind_def::Type::OPTIONAL_ANNOTATION_TYPE; - return find_annotation(a); - } - - bool is_shared() - { - AnnotationKind a = AnnotationKind_def::Type::SHARED_ANNOTATION_TYPE; - return find_annotation(a); - } - - bool is_key() - { - AnnotationKind a = AnnotationKind_def::Type::KEY_ANNOTATION_TYPE; - return find_annotation(a); - } - - bool is_must_understand() - { - AnnotationKind a = AnnotationKind_def::Type::MUST_UNDERSTAND_ANNOTATION_TYPE; - return find_annotation(a); - } - - bool is_bitset() - { - AnnotationKind a = AnnotationKind_def::Type::BITSET_ANNOTATION_TYPE; - return find_annotation(a); - } - - bool has_bitbound() - { - AnnotationKind a = AnnotationKind_def::Type::BITSETBOUND_ANNOTATION_TYPE; - return find_annotation(a); - } - - /* - uint32_t get_bitbound() - { - if(false == has_bitbound()) - { - throw IllegalOperationError("No Bitsetbound Annotation found"); - } - AnnotationKind a = AnnotationKind_def::Type::BITSETBOUND_ANNOTATION_TYPE; - return annIt(a)->bound(); - } - */ - bool has_id() - { - AnnotationKind a = AnnotationKind_def::Type::ID_ANNOTATION_TYPE; - return find_annotation(a); - } - - uint32_t get_id() - { - AnnotationKind a = AnnotationKind_def::Type::ID_ANNOTATION_TYPE; - - // creting a generic IdAnnotation that will be filled by annotation_iterator() - xtypes::IdAnnotation ida(0); - if (not annotation_iterator(a, ida)) - { - throw IllegalOperationError("No Id Annotation found"); - } - return ida->id(); - } - -private: - - std::string name_; - xtypes::DynamicType dt_; - std::vector ann_; -}; - -} //namespace detail -} //namespace xtypes -} //namespace core -} //namespace dds - -#endif //EPROSIMA_DDS_CORE_XTYPES_DETAIL_MEMBER_TYPE_HPP_ diff --git a/include/dds/core/xtypes/detail/PrimitiveTypes.hpp b/include/dds/core/xtypes/detail/PrimitiveTypes.hpp deleted file mode 100644 index 6c2e225dd19..00000000000 --- a/include/dds/core/xtypes/detail/PrimitiveTypes.hpp +++ /dev/null @@ -1,131 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_CORE_XTYPES_DETAIL_PRIMITIVE_TYPES_HPP_ -#define EPROSIMA_DDS_CORE_XTYPES_DETAIL_PRIMITIVE_TYPES_HPP_ - -#include - -// This template specialization have the intent to provide guidelines -// implementors of this specification. Notice that this define only a subset -// of primitive types, thus more work for you to do... - -namespace dds { -namespace core { -namespace xtypes { - -// Notice that const char* const is used instead of std::string -// to limit initialization issues with ctors. - -template<> -struct dynamic_type_traits -{ - static constexpr TypeKind TYPE_ID = TypeKind::BOOLEAN_TYPE; - static constexpr const char* NAME = "bool"; -}; - - -template<> -struct dynamic_type_traits -{ - static constexpr TypeKind TYPE_ID = TypeKind::UINT_8_TYPE; - static constexpr const char* NAME = "uint8_t"; -}; - -template<> -struct dynamic_type_traits -{ - static constexpr TypeKind TYPE_ID = TypeKind::INT_16_TYPE; - static constexpr const char* NAME = "int16_t"; -}; - -template<> -struct dynamic_type_traits -{ - static constexpr TypeKind TYPE_ID = TypeKind::UINT_16_TYPE; - static constexpr const char* NAME = "uint16_t"; -}; - -template<> -struct dynamic_type_traits -{ - static constexpr TypeKind TYPE_ID = TypeKind::INT_32_TYPE; - static constexpr const char* NAME = "int32_t"; -}; - -template<> -struct dynamic_type_traits -{ - static constexpr TypeKind TYPE_ID = TypeKind::UINT_32_TYPE; - static constexpr const char* NAME = "uint32_t"; -}; - -template<> -struct dynamic_type_traits -{ - static constexpr TypeKind TYPE_ID = TypeKind::INT_64_TYPE; - static constexpr const char* NAME = "int64_t"; -}; - -template<> -struct dynamic_type_traits -{ - static constexpr TypeKind TYPE_ID = TypeKind::UINT_64_TYPE; - static constexpr const char* NAME = "uint64_t"; -}; - -template<> -struct dynamic_type_traits -{ - static constexpr TypeKind TYPE_ID = TypeKind::FLOAT_32_TYPE; - static constexpr const char* NAME = "float"; -}; - -template<> -struct dynamic_type_traits -{ - static constexpr TypeKind TYPE_ID = TypeKind::FLOAT_64_TYPE; - static constexpr const char* NAME = "double"; -}; - -template<> -struct dynamic_type_traits -{ - static constexpr TypeKind TYPE_ID = TypeKind::FLOAT_128_TYPE; - static constexpr const char* NAME = "longdouble"; -}; - -template<> -struct dynamic_type_traits -{ - static constexpr TypeKind TYPE_ID = TypeKind::CHAR_8_TYPE; - static constexpr const char* NAME = "char"; -}; - -template<> -struct dynamic_type_traits -{ - static constexpr TypeKind TYPE_ID = TypeKind::CHAR_32_TYPE; - static constexpr const char* NAME = "char32_t"; -}; - - -} //namespace xtypes -} //namespace core -} //namespace dds - -#endif //EPROSIMA_DDS_CORE_XTYPES_DETAIL_PRIMITIVE_TYPES_HPP_ diff --git a/include/dds/core/xtypes/detail/StructType.hpp b/include/dds/core/xtypes/detail/StructType.hpp deleted file mode 100644 index a8682b1a526..00000000000 --- a/include/dds/core/xtypes/detail/StructType.hpp +++ /dev/null @@ -1,187 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_CORE_XTYPES_DETAIL_STRUCT_TYPE_HPP_ -#define EPROSIMA_DDS_CORE_XTYPES_DETAIL_STRUCT_TYPE_HPP_ - -#include -#include - -#define COND_EXCEP_THROW(EXPR, CONT) if (EXPR){ \ - throw IllegalOperationError(CONT); \ -} - - -namespace dds { -namespace core { -namespace xtypes { -namespace detail { - - -class StructType -{ -public: - - StructType() - { - } - - void name( - const std::string& s) - { - name_ = s; - } - - void member( - const xtypes::MemberType& m) - { - members_.push_back(m); - } - - void members( - std::vector& v) - { - members_.reserve( v.size() + members_.size() ); - - for (auto it = v.begin(); v.end() != it; ++it) - { - members_.emplace_back(*it); - } - } - - template - void members( - MemberIter& begin, - MemberIter& end) - { - members_.reserve( (end - begin) + members_.size() ); - - for (auto it = begin; end != it; ++it) - { - members_.emplace_back(*it); - } - } - - void annotation( - xtypes::Annotation& a ) - { - annotations_.emplace_back(a); - } - - void annotations( - std::vector& v) - { - annotations_.reserve( v.size() + annotations_.size() ); - - for (auto it = v.begin(); v.end() != it; ++it) - { - annotations_.emplace_back(*it); - } - } - - template - void annotations( - AnnotationIter& begin, - AnnotationIter& end) - { - annotations_.reserve( (end - begin) + annotations_.size() ); - - for (auto it = begin; end != it; ++it) - { - annotations_.emplace_back(*it); - } - } - - const std::vector& members() const noexcept - { - return members_; - } - - const xtypes::MemberType& member( - uint32_t id) const - { - COND_EXCEP_THROW(id >= members_.size(), "no such member_id could be found"); - - return members_[id]; - } - - const xtypes::MemberType& member( - const std::string& s) const - { - auto retval = find_if( - members_.begin(), - members_.end(), - [&](const xtypes::MemberType& m) - { - return m.name() == s; - } - ); - - COND_EXCEP_THROW(retval == members_.end(), "member" + s + "not found"); - return *retval; - } - - const std::vector& annotations() - { - return annotations_; - } - - void remove_member( - const xtypes::MemberType& m) - { - auto rv = find_if( - members_.begin(), - members_.end(), - [&](xtypes::MemberType& t) - { - return t.name() == m.name(); - } - ); - - COND_EXCEP_THROW(rv == members_.end(), "could not find " + m.name() + " member"); - members_.erase(rv); - } - - void remove_annotation( - const xtypes::Annotation& a) - { - auto rv = find_if( - annotations_.begin(), - annotations_.end(), - [&]( xtypes::Annotation& aa) - { - return aa.akind() == a.akind(); - } - ); - - COND_EXCEP_THROW(rv == annotations_.end(), "could not find such annotation"); - annotations_.erase(rv); - } - -private: - - std::string name_; - std::vector members_; - std::vector annotations_; -}; - -} //namespace detail -} //namespace xtypes -} //namespace core -} //namespace dds - -#endif //EPROSIMA_DDS_CORE_XTYPES_DETAIL_STRUCT_TYPE_HPP_ diff --git a/include/dds/core/xtypes/detail/TypeProvider.hpp b/include/dds/core/xtypes/detail/TypeProvider.hpp deleted file mode 100644 index e818fde4c77..00000000000 --- a/include/dds/core/xtypes/detail/TypeProvider.hpp +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_CORE_XTYPES_DETAIL_TYPE_PROVIDER_HPP_ -#define EPROSIMA_DDS_CORE_XTYPES_DETAIL_TYPE_PROVIDER_HPP_ - -namespace dds { -namespace core { -namespace xtypes { -namespace detail { - -class TypeProvider -{ -}; - -} //namespace detail -} //namespace xtypes -} //namespace core -} //namespace dds - -#endif //EPROSIMA_DDS_CORE_XTYPES_DETAIL_TYPE_PROVIDER_HPP_ diff --git a/include/dds/core/xtypes/detail/UnionCase.hpp b/include/dds/core/xtypes/detail/UnionCase.hpp deleted file mode 100644 index 3eb31999aff..00000000000 --- a/include/dds/core/xtypes/detail/UnionCase.hpp +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_CORE_XTYPES_DETAIL_UNION_CASE_HPP_ -#define EPROSIMA_DDS_CORE_XTYPES_DETAIL_UNION_CASE_HPP_ - -namespace dds { -namespace core { -namespace xtypes { -namespace detail { - -template -class UnionCase -{ -}; - -} //namespace detail -} //namespace xtypes -} //namespace core -} //namespace dds - -#endif //EPROSIMA_DDS_CORE_XTYPES_DELEGATE_UNION_CASE_HPP_ diff --git a/include/dds/core/xtypes/detail/UnionType.hpp b/include/dds/core/xtypes/detail/UnionType.hpp deleted file mode 100644 index cbf9400e0e2..00000000000 --- a/include/dds/core/xtypes/detail/UnionType.hpp +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_CORE_XTYPES_DETAIL_UNION_TYPE_HPP_ -#define EPROSIMA_DDS_CORE_XTYPES_DETAIL_UNION_TYPE_HPP_ - -namespace dds { -namespace core { -namespace xtypes { -namespace detail { - -template -class UnionType -{ -}; - -} //namespace detail -} //namespace xtypes -} //namespace core -} //namespace dds - -#endif //EPROSIMA_DDS_CORE_XTYPES_DETAIL_UNION_TYPE_HPP_ diff --git a/include/dds/domain/DomainParticipant.hpp b/include/dds/domain/DomainParticipant.hpp deleted file mode 100644 index 4bcbe58b218..00000000000 --- a/include/dds/domain/DomainParticipant.hpp +++ /dev/null @@ -1,505 +0,0 @@ -/* - * Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * All rights reserved. - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_DOMAIN_DOMAINPARTICIPANT_HPP_ -#define OMG_DDS_DOMAIN_DOMAINPARTICIPANT_HPP_ - -#include - -#include -#include -#include -#include -#include -#include - -#include -#include -#include - -#include - -namespace dds { -namespace domain { - -class DomainParticipantListener; - -/** - * @brief - * A DomainParticipant represents the local membership of the application in a - * Domain. - * - * The DomainParticipant represents the participation of the application on - * a communication plane that isolates applications running on the same - * set of physical computers from each other. A domain establishes a virtual - * network linking all applications that share the same domainId and isolating - * them from applications running on different domains. In this way, several - * independent distributed applications can coexist in the same physical - * network without interfering, or even being aware of each other. - * - * @see @ref DCPS_Modules_DomainParticipant "Domain Participant" - */ -class DomainParticipant : public ::dds::core::TEntity -{ -public: - - /** - * Local representation of the dds::domain::DomainParticipantListener - */ - using Listener = DomainParticipantListener; - -public: - - OMG_DDS_REF_TYPE_PROTECTED_DC( - DomainParticipant, - dds::core::TEntity, - detail::DomainParticipant) - OMG_DDS_EXPLICIT_REF_BASE_DECL( - DomainParticipant, - dds::core::Entity) - - /** - * Creates a new DomainParticipant object. The DomainParticipant signifies - * that the calling application intends to join the Domain identified by - * the domain_id argument. - * - * The DomainParticipant will be created with the QoS values specified on the last - * successful call to - * @link dds::domain::DomainParticipant::default_participant_qos(const ::dds::domain::qos::DomainParticipantQos& qos) - * DomainParticipant::default_publisher_qos(qos) @endlink or, if the call was never - * made, the @ref anchor_dds_domain_domainparticipant_qos_defaults "default" values. - * - * @param id the id of the domain joined by the new DomainParticipant - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - OMG_DDS_API DomainParticipant( - uint32_t id); - - /** - * Creates a new DomainParticipant object. The DomainParticipant signifies - * that the calling application intends to join the Domain identified by - * the domain_id argument. - * - * The DomainParticipant will be created with the DomainParticipantQos - * passed as an argument. - * - * @param id the id of the domain joined by the new DomainParticipant - * @param qos the QoS settings for the new DomainParticipant - * @param listener the listener - * @param event_mask the mask defining the events for which the listener - * will be notified. - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - OMG_DDS_API DomainParticipant( - uint32_t id, - const dds::domain::qos::DomainParticipantQos& qos, - dds::domain::DomainParticipantListener* listener = NULL, - const dds::core::status::StatusMask& event_mask = dds::core::status::StatusMask::all()); - - /** @cond */ - virtual OMG_DDS_API ~DomainParticipant(); - /** @endcond */ - - /** - * Register a listener with the DomainParticipant. - * - * The notifications received by the listener depend on the - * status mask with which it was registered. - * - * Listener un-registration is performed by setting the listener to NULL. - * - * See also @ref DCPS_Modules_Infrastructure_Listener "listener information". - * - * @param listener the listener - * @param event_mask the mask defining the events for which the listener - * will be notified. - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::UnsupportedError - * A status was selected that cannot be supported because - * the infrastructure does not maintain the required connectivity information. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - OMG_DDS_API void listener( - Listener* listener, - const ::dds::core::status::StatusMask& event_mask); - - /** - * Get the listener of this DomainParticipant. - * - * See also @ref DCPS_Modules_Infrastructure_Listener "listener information". - * - * @return the listener - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - */ - OMG_DDS_API Listener* listener() const; - - /** - * Gets the DomainParticipantQos setting for this instance. - * - * @return the qos - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - OMG_DDS_API const qos::DomainParticipantQos& qos() const; - - /** - * Sets the DomainParticipantQos setting for this instance. - * - * @param qos the qos - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - OMG_DDS_API void qos( - const qos::DomainParticipantQos& qos); - - /** - * This operation retrieves the domain_id used to create the - * DomainParticipant. The domain_id identifies the DDS domain - * to which the DomainParticipant belongs. - * - * Each DDS domain represents a separate data communication - * plane isolated from other domains. - * - * @return the domain id - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - */ - OMG_DDS_API uint32_t domain_id() const; - - - /** - * This operation will manually assert the liveliness for the DomainParticipant. - * - * This way, the Data Distribution Service is informed that the DomainParticipant - * is still alive. This operation only needs to be used when the DomainParticipant - * contains DataWriters with the dds:core::policy::LivelinessQosPolicy::ManualByParticipant(), - * and it will only affect the liveliness of those DataWriters. - * - * Writing data via the write operation of a DataWriter will assert the liveliness on - * the DataWriter itself and its DomainParticipant. Therefore, - * assert_liveliness is only needed when not writing regularly. - * The liveliness should be asserted by the application, depending on the - * LivelinessQosPolicy. - * - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - */ - OMG_DDS_API void assert_liveliness(); - - - /** - * This operation checks whether or not the given handle represents - * an Entity that was created by using this DomainParticipant. - * - * The containment applies recursively. That is, it applies both to - * entities (TopicDescription, Publisher, or Subscriber) created directly - * using the DomainParticipant as well as entities created using a - * contained Publisher, or Subscriber as the factory, and so forth. - * - * @param handle the instance handle for which the containement - * relationship has to be checked - * @return true if the handle belongs to an Entity belonging - * to this DomainParticipant - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - */ - OMG_DDS_API bool contains_entity( - const ::dds::core::InstanceHandle& handle); - - /** - * This operation returns the current value of the time that the service - * uses to time-stamp data writes and to set the reception timestamp - * for the data updates it receives. - * - * @return the current time - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - */ - OMG_DDS_API dds::core::Time current_time() const; - - /** @copydoc dds::domain::DomainParticipant::qos(const dds::domain::qos::DomainParticipantQos& qos) */ - OMG_DDS_API DomainParticipant& operator <<( - const qos::DomainParticipantQos& qos); - - /** @copydoc dds::domain::DomainParticipant::qos() */ - OMG_DDS_API const DomainParticipant& operator >>( - qos::DomainParticipantQos& qos) const; - - /** - * Gets the default DomainParticipantQos. - * - * This operation gets an object with the default global DomainParticipant - * QosPolicy settings which is used for newly - * created DomainParticipant objects, in case no QoS was provided during the creation. - * - * The values retrieved by this operation match the set of values specified on the last - * successful call to - * dds::domain::DomainParticipant::default_participant_qos(const ::dds::domain::qos::DomainParticipantQos& qos), - * or, if the call was never made, the @ref anchor_dds_domain_domainparticipant_qos_defaults "default" values. - * - * @return the default DomainParticipantQos - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - OMG_DDS_API static qos::DomainParticipantQos default_participant_qos(); - - /** - * Sets the default DomainParticipantQos. - * - * This QoS will be used by all following DomainParticipant creations when no - * QoS was given during those creations or the QoS is given that was returned - * by dds::domain::DomainParticipant::default_participant_qos(). - * - * @param qos the default DomainParticipantQos - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - OMG_DDS_API static void default_participant_qos( - const ::dds::domain::qos::DomainParticipantQos& qos); - - /** - * Gets the default PublisherQos of the DomainParticipant. - * - * This operation gets an object with the default Publisher QosPolicy settings of - * the DomainParticipant (that is the PublisherQos) which is used for newly - * created Publisher objects, in case no QoS was provided during the creation. - * - * The values retrieved by this operation match the set of values specified on the last - * successful call to - * dds::domain::DomainParticipant::default_publisher_qos(const ::dds::pub::qos::PublisherQos& qos), - * or, if the call was never made, the @ref anchor_dds_pub_publisher_qos_defaults "default" values. - * - * @return the default PublisherQos - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - OMG_DDS_API dds::pub::qos::PublisherQos default_publisher_qos() const; - - /** - * Sets the default PublisherQos of the DomainParticipant. - * - * This operation sets the default PublisherQos of the DomainParticipant which - * is used for newly created Publisher objects, when no QoS is provided. - * - * The PublisherQos is always self consistent, because its policies do not depend on each - * other. This means that this operation never throws dds::core::InconsistentPolicyError. - * - * The values set by this operation are returned by dds::domain::DomainParticipant::default_publisher_qos(). - * - * @param qos the default PublisherQos - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::UnsupportedError - * One or more of the selected QosPolicy values are - * currently not supported by OpenSplice. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - OMG_DDS_API DomainParticipant& default_publisher_qos( - const ::dds::pub::qos::PublisherQos& qos); - - /** - * Gets the default SubscriberQos of the DomainParticipant. - * - * This operation gets an object with the default Subscriber QosPolicy settings of - * the DomainParticipant (that is the SubscriberQos) which is used for newly - * created Subscriber objects, in case no QoS was provided during the creation. - * - * The values retrieved by this operation match the set of values specified on the last - * successful call to - * dds::domain::DomainParticipant::default_subscriber_qos(const :dds::sub::qos::SubscriberQos& qos), - * or, if the call was never made, the @ref anchor_dds_sub_subscriber_qos_defaults "default" values. - * - * @return the default SubscriberQos - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - OMG_DDS_API dds::sub::qos::SubscriberQos default_subscriber_qos() const; - - /** - * Sets the default SubscriberQos of the DomainParticipant. - * - * This operation sets the default SubscriberQos of the DomainParticipant which - * is used for newly created Subscriber objects, when no QoS is provided. - * - * The SubscriberQos is always self consistent, because its policies do not depend on each - * other. This means that this operation never throws dds::core::InconsistentPolicyError. - * - * The values set by this operation are returned by dds::domain::DomainParticipant::default_subscriber_qos(). - * - * @param qos the default SubscriberQos - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::UnsupportedError - * One or more of the selected QosPolicy values are - * currently not supported by OpenSplice. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - OMG_DDS_API DomainParticipant& default_subscriber_qos( - const ::dds::sub::qos::SubscriberQos& qos); - - /** - * Gets the default TopicQos of the DomainParticipant. - * - * This operation gets an object with the default Topic QosPolicy settings of - * the DomainParticipant (that is the TopicQos) which is used for newly - * created Topic objects, in case no QoS was provided during the creation. - * - * The values retrieved by this operation match the set of values specified on the last - * successful call to - * dds::domain::DomainParticipant::default_topic_qos(const dds::topic::qos::TopicQos& qos), - * or, if the call was never made, the @ref anchor_dds_topic_qos_defaults "default" values. - * - * @return the default TopicQos - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - OMG_DDS_API dds::topic::qos::TopicQos default_topic_qos() const; - - /** - * Sets the default TopicQos of the DomainParticipant. - * - * This operation sets the default SubscriberQos of the DomainParticipant which - * is used for newly created Subscriber objects, when no QoS is provided. - * - * This operation checks if the TopicQos is self consistent. If it is not, the - * operation has no effect and throws dds::core::InconsistentPolicyError. - * - * The values set by this operation are returned by dds::domain::DomainParticipant::default_topic_qos(). - * - * @param qos the default TopicQos - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::UnsupportedError - * One or more of the selected QosPolicy values are - * currently not supported by OpenSplice. - * @throws dds::core::InconsistentPolicyError - * The parameter qos contains conflicting QosPolicy settings, - * e.g. a history depth that is higher than the specified resource limits. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - OMG_DDS_API DomainParticipant& default_topic_qos( - const dds::topic::qos::TopicQos& qos); - - //============================================================================= -}; - -} //namespace domain -} //namespace dds - -#endif //OMG_DDS_DOMAIN_DOMAINPARTICIPANT_HPP_ diff --git a/include/dds/domain/DomainParticipantListener.hpp b/include/dds/domain/DomainParticipantListener.hpp deleted file mode 100644 index 2d3581082b0..00000000000 --- a/include/dds/domain/DomainParticipantListener.hpp +++ /dev/null @@ -1,236 +0,0 @@ -/* - * Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * All rights reserved. - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_DOMAIN_DOMAINPARTICIPANT_LISTENER_HPP_ -#define OMG_DDS_DOMAIN_DOMAINPARTICIPANT_LISTENER_HPP_ - -// TODO Remove when PSM DDS Listeners are ready to be used. -#include - -// TODO uncomment when PSM DDS Listeners are ready to be used. -/* -#include -#include -#include -*/ - -namespace dds { -namespace domain { - -/** - * @brief - * DomainParticipant events Listener - * - * Since a DomainParticipant is an Entity, it has the ability to have a Listener - * associated with it. In this case, the associated Listener should be of type - * DomainParticipantListener. This interface must be implemented by the - * application. A user-defined class must be provided by the application which must - * extend from the DomainParticipantListener class. - * - * - * All operations for this interface must be implemented in the user-defined class, it is - * up to the application whether an operation is empty or contains some functionality. - * - * - * The DomainParticipantListener provides a generic mechanism (actually a - * callback function) for the Data Distribution Service to notify the application of - * relevant asynchronous status change events, such as a missed deadline, violation of - * a QosPolicy setting, etc. The DomainParticipantListener is related to - * changes in communication status StatusConditions. - * - * @code{.cpp} - * // Application example listener - * class ExampleListener : - * public virtual dds::domain::DomainParticipantListener - * { - * public: - * virtual void on_inconsistent_topic ( - * dds::topic::AnyTopic& topic, - * const dds::core::status::InconsistentTopicStatus& status) - * { - * std::cout << "on_inconsistent_topic" << std::endl; - * } - * - * virtual void on_offered_deadline_missed ( - * dds::pub::AnyDataWriter& writer, - * const dds::core::status::OfferedDeadlineMissedStatus& status) - * { - * std::cout << "on_offered_deadline_missed" << std::endl; - * } - * - * virtual void on_offered_incompatible_qos ( - * dds::pub::AnyDataWriter& writer, - * const dds::core::status::OfferedIncompatibleQosStatus& status) - * { - * std::cout << "on_offered_incompatible_qos" << std::endl; - * } - * - * virtual void on_liveliness_lost ( - * dds::pub::AnyDataWriter& writer, - * const dds::core::status::LivelinessLostStatus& status) - * { - * std::cout << "on_liveliness_lost" << std::endl; - * } - * - * virtual void on_publication_matched ( - * dds::pub::AnyDataWriter& writer, - * const dds::core::status::PublicationMatchedStatus& status) - * { - * std::cout << "on_publication_matched" << std::endl; - * } - * - * virtual void on_requested_deadline_missed ( - * dds::sub::AnyDataReader& reader, - * const dds::core::status::RequestedDeadlineMissedStatus & status) - * { - * std::cout << "on_requested_deadline_missed" << std::endl; - * } - * - * virtual void on_requested_incompatible_qos ( - * dds::sub::AnyDataReader& reader, - * const dds::core::status::RequestedIncompatibleQosStatus & status) - * { - * std::cout << "on_requested_incompatible_qos" << std::endl; - * } - * - * virtual void on_sample_rejected ( - * dds::sub::AnyDataReader& reader, - * const dds::core::status::SampleRejectedStatus & status) - * { - * std::cout << "on_sample_rejected" << std::endl; - * } - * - * virtual void on_liveliness_changed ( - * dds::sub::AnyDataReader& reader, - * const dds::core::status::LivelinessChangedStatus & status) - * { - * std::cout << "on_liveliness_changed" << std::endl; - * } - * - * virtual void on_data_available ( - * dds::sub::AnyDataReader& reader) - * { - * std::cout << "on_data_available" << std::endl; - * } - * - * virtual void on_subscription_matched ( - * dds::sub::AnyDataReader& reader, - * const dds::core::status::SubscriptionMatchedStatus & status) - * { - * std::cout << "on_subscription_matched" << std::endl; - * } - * - * virtual void on_sample_lost ( - * dds::sub::AnyDataReader& reader, - * const dds::core::status::SampleLostStatus & status) - * { - * std::cout << "on_sample_lost" << std::endl; - * } - * - * virtual void on_data_on_readers ( - * dds::sub::Subscriber& subs) - * { - * std::cout << "on_data_on_readers" << std::endl; - * } - * }; - * - * // Create DomainParticipant with the listener - * dds::domain::DomainParticipant participant(org::opensplice::domain::default_id(), - * dds::domain::DomainParticipant::default_participant_qos(), - * new ExampleListener(), - * dds::core::status::StatusMask::all()); - * - * @endcode - * - * @see @ref DCPS_Modules_DomainParticipant "Domain Participant" - * @see @ref DCPS_Modules_Infrastructure_Listener "Listener information" - */ - -// TODO Uncomment when PSM DDS listeners are ready to be used -/* -class OMG_DDS_API DomainParticipantListener : - public virtual dds::pub::PublisherListener, - public virtual dds::sub::SubscriberListener, - public virtual dds::topic::AnyTopicListener -{ -public: - - virtual ~DomainParticipantListener() - { - } - -}; -*/ -class DomainParticipantListener : public eprosima::fastdds::dds::DomainParticipantListener -{ -public: - - virtual ~DomainParticipantListener() - { - } - -}; - - -/** - * @brief - * DomainParticipant events Listener - * - * This listener is just like DomainParticipantListener, except - * that the application doesn't have to implement all operations. - * - * @code{.cpp} - * class ExampleListener : - * public virtual dds::domain::NoOpDomainParticipantListener - * { - * // Not necessary to implement any Listener operations. - * }; - * @endcode - * - * @see dds::domain::DomainParticipantListener - */ -// TODO Uncomment when PSM DDS listeners are ready to be used -/* -class OMG_DDS_API NoOpDomainParticipantListener : - public virtual DomainParticipantListener, - public virtual dds::pub::NoOpPublisherListener, - public virtual dds::sub::NoOpSubscriberListener, - public virtual dds::topic::NoOpAnyTopicListener -{ -public: - - virtual ~NoOpDomainParticipantListener() - { - } - -}; -*/ -class NoOpDomainParticipantListener : public eprosima::fastdds::dds::DomainParticipantListener -{ -public: - ~NoOpDomainParticipantListener() - { - } -}; - -} //namespace domain -} //namespace dds - -#endif //OMG_DDS_DOMAIN_DOMAINPARTICIPANT_LISTENER_HPP_ diff --git a/include/dds/domain/detail/DomainParticipant.hpp b/include/dds/domain/detail/DomainParticipant.hpp deleted file mode 100644 index 97f857f4be9..00000000000 --- a/include/dds/domain/detail/DomainParticipant.hpp +++ /dev/null @@ -1,34 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_DOMAIN_DETAIL_DOMAINPARTICIPANT_HPP_ -#define EPROSIMA_DDS_DOMAIN_DETAIL_DOMAINPARTICIPANT_HPP_ - -#include - -namespace dds { -namespace domain { -namespace detail { - -using DomainParticipant = eprosima::fastdds::dds::DomainParticipant; - -} //namespace detail -} //namespace domain -} //namespace dds - - -#endif //EPROSIMA_DDS_DOMAIN_DETAIL_DOMAINPARTICIPANT_HPP_ diff --git a/include/dds/domain/qos/DomainParticipantQos.hpp b/include/dds/domain/qos/DomainParticipantQos.hpp deleted file mode 100644 index 6f7b111e2ee..00000000000 --- a/include/dds/domain/qos/DomainParticipantQos.hpp +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * All rights reserved. - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_DOMAIN_QOS_DOMAINPARTICIPANTQOS_HPP_ -#define OMG_DDS_DOMAIN_QOS_DOMAINPARTICIPANTQOS_HPP_ - -#include - -namespace dds { -namespace domain { -namespace qos { - -using DomainParticipantQos = dds::domain::qos::detail::DomainParticipantQos; - -} //namespace qos -} //namespace domain -} //namespace dds - -#endif //OMG_DDS_DOMAIN_QOS_DOMAINPARTICIPANTQOS_HPP_ diff --git a/include/dds/domain/qos/detail/DomainParticipantQos.hpp b/include/dds/domain/qos/detail/DomainParticipantQos.hpp deleted file mode 100644 index e3c5de2d0a2..00000000000 --- a/include/dds/domain/qos/detail/DomainParticipantQos.hpp +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_DOMAIN_QOS_DETAIL_DOMAINPARTICIPANTQOS_HPP_ -#define EPROSIMA_DDS_DOMAIN_QOS_DETAIL_DOMAINPARTICIPANTQOS_HPP_ - -#include - -namespace dds { -namespace domain { -namespace qos { -namespace detail { - -using DomainParticipantQos = eprosima::fastdds::dds::DomainParticipantQos; - -} //namespace detail -} //namespace qos -} //namespace domain -} //namespace dds - -#endif //EPROSIMA_DDS_DOMAIN_QOS_DETAIL_DOMAINPARTICIPANTQOS_HPP_ diff --git a/include/dds/pub/AnyDataWriter.hpp b/include/dds/pub/AnyDataWriter.hpp deleted file mode 100644 index 126c52ed5aa..00000000000 --- a/include/dds/pub/AnyDataWriter.hpp +++ /dev/null @@ -1,373 +0,0 @@ -/* - * Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_PUB_ANY_DATA_WRITER_HPP_ -#define OMG_DDS_PUB_ANY_DATA_WRITER_HPP_ - -#include - -#include -#include - -#include -//#include - -namespace dds { -namespace pub { - -/** - * @brief - * Typeless base class for the typed DataWriter. - * - * DataWriters are created type specific (fi DataWriter writer). However, there - * are many places in the API (and possibly application) where the type can not be known - * while still some DataWriter has to be passed around, stored or even typeless functionality - * called.
    - * Main examples in the API that need typeless DataWriter are: Publisher, PublisherListener - * and DomainParticipantListener. - * - */ -template -class TAnyDataWriter : public dds::core::TEntity -{ -public: - - OMG_DDS_REF_TYPE_PROTECTED_DC( - TAnyDataWriter, - dds::core::TEntity, - DELEGATE) - - OMG_DDS_IMPLICIT_REF_BASE( - TAnyDataWriter) - - /** @cond */ - virtual ~TAnyDataWriter(); - /** @endcond */ - - //========================================================================== - //== Entity Navigation - - /** - * Get the Publisher that owns this DataWriter. - * - * @return the Publisher - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - */ - OMG_DDS_API const Publisher& publisher() const; - - /** - * Get the TopicDescription associated with this DataWriter. - * - * @return the TopicDescription - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - */ - // const dds::topic::TopicDescription& topic_description() const; - - - - //========================================================================== - //== QoS Management - - /** - * Gets the DataWriterQos setting for this instance. - * - * @return the qos - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - OMG_DDS_API qos::DataWriterQos qos() const; - - /** - * This operation replaces the existing set of QosPolicy settings for a DataWriter. - * - * The parameter qos contains the object with the QosPolicy settings which is - * checked for self-consistency and mutability. - * - * When the application tries to change a - * QosPolicy setting for an enabled DataWriter, which can only be set before the - * DataWriter is enabled, the operation will fail and a - * ImmutablePolicyError is thrown. In other words, the application must - * provide the presently set QosPolicy settings in case of the immutable QosPolicy - * settings. Only the mutable QosPolicy settings can be changed. - * - * When the qos contains conflicting QosPolicy settings (not self-consistent), - * the operation will fail and an InconsistentPolicyError is thrown. - * - * @param qos the qos - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - * @throws dds::core::ImmutablePolicyError - * The parameter qos contains an immutable QosPolicy setting with a - * different value than set during enabling of the DataWriter. - * @throws dds::core::InconsistentPolicyError - * The parameter qos contains conflicting QosPolicy settings, - */ - OMG_DDS_API void qos( - const qos::DataWriterQos& qos); - - /** @copydoc dds::pub::TAnyDataWriter::qos(const dds::pub::qos::DataWriterQos& qos) */ - OMG_DDS_API TAnyDataWriter& operator <<( - const qos::DataWriterQos& qos); - - /** @copydoc dds::pub::TAnyDataWriter::qos() */ - OMG_DDS_API const TAnyDataWriter& operator >>( - qos::DataWriterQos& qos) const; - - - //========================================================================== - //== ACKs - - /** - * This operation blocks the calling thread until either all data written - * by the DataWriter is acknowledged by the local infrastructure, or until - * the duration specified by the timeout parameter elapses, - * whichever happens first. - * - * Data is acknowledged by the local infrastructure when it does not need to be stored - * in its DataWriter’s local history. When a locally-connected subscription (including - * the networking service) has no more resources to store incoming samples it will start - * to reject these samples, resulting in their source DataWriters to store them - * temporarily in their own local history to be retransmitted at a later moment in time.
    - * In such scenarios, the wait_for_acknowledgments operation will block until the - * DataWriter has retransmitted its entire history, which is therefore effectively - * empty, or until the timeout expires, whichever happens first. In the latter - * case, this operation will throw a TimeoutError. - * - * - * Be aware that in case the operation returns normally, the data has only been - * acknowledged by the local infrastructure: it does not mean all remote subscriptions - * have already received the data. However, delivering the data to remote nodes is then - * the sole responsibility of the networking service: even when the publishing - * application would terminate, all data that has not yet been received may be - * considered ‘on-route’ and will therefore eventually arrive (unless the networking - * service itself will crash). In contrast, if a DataWriter would still have data in it’s - * local history buffer when it terminates, this data is considered ‘lost’. - * - * - * This operation is intended to be used only if one or more of the contained - * DataWriters has its ReliabilityQosPolicyKind set to RELIABLE. - * Otherwise the operation will return immediately, since best-effort DataWriters will - * never store rejected samples in their local history: - * they will just drop them and continue business as usual. - * - * @param timeout the time out duration - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::TimeoutError - * Not all data is acknowledged before timeout elapsed. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - OMG_DDS_API void wait_for_acknowledgments( - const dds::core::Duration& timeout); - - //========================================================================== - //== Status Management - - /** - * This operation obtains the LivelinessLostStatus object of the DataWriter. - * - * The LivelinessLostStatus contains the information whether the liveliness (that the - * DataWriter has committed through its Liveliness QosPolicy) was respected. - * This means that the status represents whether the DataWriter failed to actively - * signal its liveliness within the offered liveliness period. If the liveliness is lost, the - * DataReader objects will consider the DataWriter as no longer “alive”. - * - * The LivelinessLostStatus can also be monitored using a - * DataWriterListener or by using the associated StatusCondition. - * - * @return the LivelinessLostStatus - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - OMG_DDS_API const dds::core::status::LivelinessLostStatus liveliness_lost_status(); - - /** - * This operation obtains the OfferedDeadlineMissedStatus object of the DataWriter. - * - * The OfferedDeadlineMissedStatus contains the information whether the deadline (that the - * DataWriter has committed through its Deadline QosPolicy) was respected for - * each instance. - * - * The OfferedDeadlineMissedStatus can also be monitored using a - * DataWriterListener or by using the associated StatusCondition. - * - * @return the OfferedDeadlineMissedStatus - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - OMG_DDS_API const dds::core::status::OfferedDeadlineMissedStatus offered_deadline_missed_status(); - - /** - * This operation obtains the OfferedIncompatibleQosStatus object of the DataWriter. - * - * The OfferedIncompatibleQosStatus contains the information whether a QosPolicy setting - * was incompatible with the requested QosPolicy setting. - * - * This means that the status represents whether a DataReader object has been - * discovered by the DataWriter with the same Topic and a requested - * DataReaderQos that was incompatible with the one offered by the DataWriter. - * - * The OfferedIncompatibleQosStatus can also be monitored using a - * DataWriterListener or by using the associated StatusCondition. - * - * @return the OfferedIncompatibleQosStatus - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - OMG_DDS_API const dds::core::status::OfferedIncompatibleQosStatus offered_incompatible_qos_status(); - - /** - * This operation obtains the PublicationMatchedStatus object of the DataWriter. - * - * The PublicationMatchedStatus contains the information whether a new match has been - * discovered for the current publication, or whether an existing match has ceased to - * exist. - * - * This means that the status represents that either a DataReader object has been - * discovered by the DataWriter with the same Topic and a compatible Qos, or that a - * previously discovered DataReader has ceased to be matched to the current - * DataWriter. A DataReader may cease to match when it gets deleted, when it - * changes its Qos to a value that is incompatible with the current DataWriter or - * when either the DataWriter or the DataReader has chosen to put its matching - * counterpart on its ignore-list using the dds::sub::ignore or - * dds::pub::ignore operations. - * - * The operation may fail if the infrastructure does not hold the information necessary - * to fill in the PublicationMatchedStatus. This is the case when OpenSplice is - * configured not to maintain discovery information in the Networking Service. (See - * the description for the NetworkingService/Discovery/enabled property in - * the Deployment Manual for more information about this subject.) In this case the - * operation will throw UnsupportedError. - * - * The PublicationMatchedStatus can also be monitored using a - * DataWriterListener or by using the associated StatusCondition. - * - * @return the PublicationMatchedStatus - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::UnsupportedError - * OpenSplice is configured not to maintain the information - * about “associated” subscriptions. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - OMG_DDS_API const dds::core::status::PublicationMatchedStatus publication_matched_status(); - - - //========================================================================== - //== Liveliness Management - - /** - * This operation asserts the liveliness for the DataWriter. - * - * This operation will manually assert the liveliness for the DataWriter. This way, - * the Data Distribution Service is informed that the corresponding DataWriter is - * still alive. This operation is used in combination with the Liveliness QosPolicy - * set to Liveliness::ManualByParticipant or Liveliness::ManualByTopic. - * - * Writing data via the write operation of a DataWriter will assert the liveliness on - * the DataWriter itself and its containing DomainParticipant. Therefore, - * assert_liveliness is only needed when not writing regularly. - * - * The liveliness should be asserted by the application, depending on the - * LivelinessQosPolicy. Asserting the liveliness for this DataWriter can also - * be achieved by asserting the liveliness to the DomainParticipant. - * - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - * @throws dds::core::NotEnabledError - * The entity has not yet been enabled. - */ - OMG_DDS_API void assert_liveliness(); - -protected: - - const Publisher* publisher_; - -}; - -typedef ::dds::pub::detail::AnyDataWriter AnyDataWriter; - -} //namespace pub -} //namespace dds - -#endif //OMG_DDS_PUB_ANY_DATA_WRITER_HPP_ diff --git a/include/dds/pub/DataWriter.hpp b/include/dds/pub/DataWriter.hpp deleted file mode 100644 index a28d6b2c2b2..00000000000 --- a/include/dds/pub/DataWriter.hpp +++ /dev/null @@ -1,1611 +0,0 @@ -/* - * Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_PUB_DATA_WRITER_HPP_ -#define OMG_DDS_PUB_DATA_WRITER_HPP_ - -#include -//#include -//#include -#include -#include - -#include - -/** @cond */ -namespace dds { -namespace pub { - -template -class DataWriter; - -template -class DataWriterListener; - -/** @endcond */ - -/** - * @brief - * DataWriter allows the application to set the value of the sample to be published - * under a given Topic. - * - * A DataWriter is attached to exactly one Publisher. - * - * A DataWriter is bound to exactly one Topic and therefore to exactly one data - * type. The Topic must exist prior to the DataWriter's creation. - * DataWriter is an abstract class. It must be specialized for each particular - * application data type. For a fictional application data type Bar (defined in the - * module Foo) the specialized class would be dds::pub::DataWriter. - * - * The pre-processor generates from IDL type descriptions the application - * DataWriter classes. For each application data type that is used as Topic - * data type, a typed class DataWriter is derived from the AnyDataWriter - * class. - * - * For instance, for an application, the definitions are located in the Foo.idl file. - * The pre-processor will generate a ccpp_Foo.h include file. - * - * General note: The name ccpp_Foo.h is derived from the IDL file Foo.idl, - * that defines Foo::Bar, for all relevant DataWriter operations. - * - * @note Apart from idl files, Google protocol buffers are also supported. For the - * API itself, it doesn't matter if the type header files were generated from - * idl or protocol buffers. The resulting API usage and includes remain the same. - * - * @code{.cpp} - * // Default creation of a DataWriter - * dds::domain::DomainParticipant participant(org::opensplice::domain::default_id()); - * dds::topic::Topic topic(participant, "TopicName"); - * dds::pub::Publisher publisher(participant); - * dds::pub::DataWriter writer(publisher, topic); - * - * // Default write of a sample on the DataWriter - * Foo::Bar sample; - * writer.write(sample); - * @endcode - * - * @see @ref DCPS_Modules_Publication "Publication concept" - * @see @ref DCPS_Modules_Publication_DataWriter "DataWriter concept" - */ -template -class DataWriter : public TAnyDataWriter -{ -public: - - /** - * Local convenience typedef for dds::pub::DataWriterListener. - */ - using Listener = DataWriterListener; - - OMG_DDS_REF_TYPE_PROTECTED_DC( - DataWriter, - dds::pub::TAnyDataWriter, - detail::DataWriter) - - OMG_DDS_IMPLICIT_REF_BASE( - DataWriter) - - /** - * Create a new DataWriter for the desired Topic, using the given Publisher. - * - * The DataWriter will be created with the QoS values specified on the last - * successful call to @link dds::pub::Publisher::default_datawriter_qos(const dds::pub::qos::DataWriterQos& qos) - * pub.default_datawriter_qos(qos) @endlink or, if the call was never made, the - * @ref anchor_dds_pub_datawriter_qos_defaults "default" values. - * - * Implicit Publisher
    - * It is expected to provide a Publisher when creating a DataWriter. However, it is - * allowed to provide dds::core::null. When dds::core::null is provided, then an implicit - * Publisher is created with a default QoS and the DomainParticipant from the provided - * Topic. - * - * @param pub the Publisher that will contain this DataWriter - * (or dds::core::null for an implicit publisher) - * @param topic the Topic associated with this DataWriter - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - // DataWriter( - // const Publisher& pub, - // const ::dds::topic::Topic& topic); - - /** - * Create a new DataWriter for the desired Topic, using the given Publisher and - * DataWriterQos and attaches the optionally specified DataWriterListener to it. - * - * QoS
    - * A possible application pattern to construct the DataWriterQos for the - * DataWriter is to: - * @code{.cpp} - * // 1) Retrieve the QosPolicy settings on the associated Topic - * dds::topic::qos::TopicQos topicQos = topic.qos(); - * // 2) Retrieve the default DataWriterQos from the related Publisher - * dds::pub::qos::DataWriterQos writerQos = publisher.default_datawriter_qos(); - * // 3) Combine those two lists of QosPolicy settings by overwriting DataWriterQos - * // policies that are also present TopicQos - * writerQos = topicQos; - * // 4) Selectively modify QosPolicy settings as desired. - * writerQos << dds::core::policy::WriterDataLifecycle::ManuallyDisposeUnregisteredInstances(); - * // 5) Use the resulting QoS to construct the DataWriter. - * dds::pub::DataWriter writer(publisher, topic, writerQos); - * @endcode - * - * Restictions on QoS policies - * For a coherent writer there exists a constraint on the setting of the History QoS policy. - * When a writer is created with publisher that has a presentation QosPolicy with - * coherent_access enabled and where the access_scope is either TOPIC or GROUP - * then the History QoS policy of the coherent writer should be set to KEEP_ALL. - * Applying this constraint is necessary because in case of a keep-last writer the - * samples in the writers history could be pushed out by a new sample which causes that - * the transaction would not become complete. - * - * Implicit Publisher
    - * It is expected to provide a Publisher when creating a DataWriter. However, it is - * allowed to provide dds::core::null. When dds::core::null is provided, then an implicit - * Publisher is created with a default QoS and the DomainParticipant from the provided - * Topic. - * - * Listener
    - * The following statuses are applicable to the DataWriterListener: - * - dds::core::status::StatusMask::offered_deadline_missed() - * - dds::core::status::StatusMask::offered_incompatible_qos() - * - dds::core::status::StatusMask::liveliness_lost() - * - dds::core::status::StatusMask::publication_matched() - * - * See @ref DCPS_Modules_Infrastructure_Listener "listener concept", - * @ref anchor_dds_pub_datawriter_commstatus "communication status" and - * @ref anchor_dds_pub_datawriter_commpropagation "communication propagation" - * for more information. - * - * @param pub the Publisher that will contain this DataWriter - * (or dds::core::null for an implicit publisher) - * @param topic the Topic associated with this DataWriter - * @param qos the DataWriter qos. - * @param listener the DataWriter listener. - * @param mask the listener event mask. - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - * @throws dds::core::InconsistentPolicyError - * The parameter qos contains conflicting QosPolicy settings. - * @throws dds::core::PreconditionNotMetError - * The History QosPolicy is not KEEP_ALL when applied to a coherent writer. - */ - // DataWriter( - // const Publisher& pub, - // const ::dds::topic::Topic& topic, - // const qos::DataWriterQos& qos, - // DataWriterListener* listener = nullptr, - // const dds::core::status::StatusMask& mask = ::dds::core::status::StatusMask::all()); - - /** @cond */ - virtual ~DataWriter(); - /** @endcond */ - - //========================================================================== - //== Write API - - /** - * This operation modifies the value of a data instance. - * - * Detailed Description
    - * This operation modifies the value of a data instance. When this operation is used, - * the Data Distribution Service will automatically supply the value of the - * source_timestamp that is made available to connected DataReader objects.
    - * This timestamp is important for the interpretation of the - * dds::core::policy::DestinationOrder QosPolicy. - * - * As a side effect, this operation asserts liveliness on the DataWriter itself and on - * the containing DomainParticipant. - * - * @anchor anchor_dds_pub_datawriter_write_blocking - * Blocking
    - * If the dds::core::policy::History QosPolicy is set to KEEP_ALL, the write - * operation on the DataWriter may block if the modification would cause data to be - * lost because one of the limits, specified in the dds::core::policy::ResourceLimits, is - * exceeded. In case the synchronous attribute value of the - * dds::core::policy::Reliability is set to TRUE for communicating DataWriters and - * DataReaders then the DataWriter will wait until all synchronous - * DataReaders have acknowledged the data. Under these circumstances, the - * max_blocking_time attribute of the dds::core::policy::Reliability configures the - * maximum time the write operation may block (either waiting for space to become - * available or data to be acknowledged). If max_blocking_time elapses before the - * DataWriter is able to store the modification without exceeding the limits and all - * expected acknowledgements are received, the write operation will fail and throw - * TimeoutError. - * - * @param sample the sample to be written - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - * @throws dds::core::NotEnabledError - * The DataWriter has not yet been enabled. - * @throws dds::core::TimeoutError - * Either the current action overflowed the available resources - * as specified by the combination of the Reliability QosPolicy, - * History QosPolicy and ResourceLimits QosPolicy, or the current action - * was waiting for data delivery acknowledgement by synchronous DataReaders. - * This caused blocking of the write operation, which could not be resolved before - * max_blocking_time of the Reliability QosPolicy elapsed. - */ - OMG_DDS_API void write( - const T& sample); - - /** - * This operation modifies the value of a data instance and provides a value for the - * source_timestamp explicitly. - * - * Detailed Description
    - * It modifies the values of the given data instances. When this operation is used, - * the application provides the value for the parameter source_timestamp that is made - * available to connected DataReader objects.
    - * This timestamp is important for the interpretation of the - * dds::core::policy::DestinationOrder QosPolicy. - * - * As a side effect, this operation asserts liveliness on the DataWriter itself and on - * the containing DomainParticipant. - * - * Blocking
    - * This operation can be blocked (see @ref anchor_dds_pub_datawriter_write_blocking "write blocking"). - * - * @param sample the sample to be written - * @param timestamp the timestamp used for this sample - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - * @throws dds::core::NotEnabledError - * The DataWriter has not yet been enabled. - * @throws dds::core::TimeoutError - * Either the current action overflowed the available resources - * as specified by the combination of the Reliability QosPolicy, - * History QosPolicy and ResourceLimits QosPolicy, or the current action - * was waiting for data delivery acknowledgement by synchronous DataReaders. - * This caused blocking of the write operation, which could not be resolved before - * max_blocking_time of the Reliability QosPolicy elapsed. - */ - OMG_DDS_API void write( - const T& sample, - const dds::core::Time& timestamp); - - /** - * This operation modifies the value of a data instance. - * - * Detailed Description
    - * This operation modifies the value of a data instance. When this operation is used, - * the Data Distribution Service will automatically supply the value of the - * source_timestamp that is made available to connected DataReader objects.
    - * This timestamp is important for the interpretation of the - * dds::core::policy::DestinationOrder QosPolicy. - * - * As a side effect, this operation asserts liveliness on the DataWriter itself and on - * the containing DomainParticipant. - * - * Before writing data to an instance, the instance may be registered with the - * @ref dds::pub::DataWriter::register_instance(const T& key) "\"register_instance\"" or - * @ref dds::pub::DataWriter::register_instance(const T& key, const dds::core::Time& timestamp) "\"register_instance_w_timestamp\"" - * The handle returned by one of the register_instance operations can be supplied to - * the parameter handle of the write operation. However, it is also possible to - * supply a default InstanceHandle (InstanceHandle.is_nil() == true), which means - * that the identity of the instance is automatically deduced from the instance_data - * (identified by the key). - * - * @anchor anchor_dds_pub_datawriter_write_instance_handle - * Instance Handle
    - * The default InstanceHandle (InstanceHandle.is_nil() == true) can be used for the - * parameter handle. This indicates the identity of the instance is automatically deduced - * from the instance_data (by means of the key). - * - * If handle is not nil, it must correspond to the value returned by - * @ref dds::pub::DataWriter::register_instance(const T& key) "\"register_instance\"" or - * @ref dds::pub::DataWriter::register_instance(const T& key, const dds::core::Time& timestamp) "\"register_instance_w_timestamp\"" - * when the instance (identified by its key) was registered. Passing such a registered - * handle helps the Data Distribution Service to process the sample more efficiently.
    - * If there is no correspondence between handle and sample, the result of the operation - * is unspecified. - * - * Blocking
    - * This operation can be blocked (see @ref anchor_dds_pub_datawriter_write_blocking "write blocking"). - * - * @param sample the sample to be written - * @param instance the handle representing the instance written - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - * @throws dds::core::NotEnabledError - * The DataWriter has not yet been enabled. - * @throws dds::core::PreconditionNotMetError - * The handle has not been registered with this DataWriter. - * @throws dds::core::TimeoutError - * Either the current action overflowed the available resources - * as specified by the combination of the Reliability QosPolicy, - * History QosPolicy and ResourceLimits QosPolicy, or the current action - * was waiting for data delivery acknowledgement by synchronous DataReaders. - * This caused blocking of the write operation, which could not be resolved before - * max_blocking_time of the Reliability QosPolicy elapsed. - */ - OMG_DDS_API void write( - const T& sample, - const ::dds::core::InstanceHandle& instance); - - /** - * This operation modifies the value of a data instance and provides a value for the - * source_timestamp explicitly. - * - * Detailed Description
    - * It modifies the values of the given data instances. When this operation is used, - * the application provides the value for the parameter source_timestamp that is made - * available to connected DataReader objects.
    - * This timestamp is important for the interpretation of the - * dds::core::policy::DestinationOrder QosPolicy. - * - * As a side effect, this operation asserts liveliness on the DataWriter itself and on - * the containing DomainParticipant. - * - * Instance Handle
    - * See @ref anchor_dds_pub_datawriter_write_instance_handle "write instance handle". - * - * Blocking
    - * This operation can be blocked (see @ref anchor_dds_pub_datawriter_write_blocking "write blocking"). - * - * @param sample the sample to be written - * @param instance the handle representing the instance written - * @param timestamp the timestamp to use for this sample - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - * @throws dds::core::NotEnabledError - * The DataWriter has not yet been enabled. - * @throws dds::core::PreconditionNotMetError - * The handle has not been registered with this DataWriter. - * @throws dds::core::TimeoutError - * Either the current action overflowed the available resources - * as specified by the combination of the Reliability QosPolicy, - * History QosPolicy and ResourceLimits QosPolicy, or the current action - * was waiting for data delivery acknowledgement by synchronous DataReaders. - * This caused blocking of the write operation, which could not be resolved before - * max_blocking_time of the Reliability QosPolicy elapsed. - */ - OMG_DDS_API void write( - const T& data, - const ::dds::core::InstanceHandle& instance, - const dds::core::Time& timestamp); - - - /** - * This operation modifies the value of a data instance. - * - * Detailed Description
    - * This operation modifies the value of a data instance. When this operation is used, - * the Data Distribution Service will automatically supply the value of the - * source_timestamp that is made available to connected DataReader objects.
    - * This timestamp is important for the interpretation of the - * dds::core::policy::DestinationOrder QosPolicy. - * - * As a side effect, this operation asserts liveliness on the DataWriter itself and on - * the containing DomainParticipant. - * - * Topic Instance
    - * A TopicInstance encapsulates a sample and its associated - * @ref anchor_dds_pub_datawriter_write_instance_handle "instance handle". - * - * - * @param i the instance to write - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - * @throws dds::core::NotEnabledError - * The DataWriter has not yet been enabled. - * @throws dds::core::PreconditionNotMetError - * The handle has not been registered with this DataWriter. - * @throws dds::core::TimeoutError - * Either the current action overflowed the available resources - * as specified by the combination of the Reliability QosPolicy, - * History QosPolicy and ResourceLimits QosPolicy, or the current action - * was waiting for data delivery acknowledgement by synchronous DataReaders. - * This caused blocking of the write operation, which could not be resolved before - * max_blocking_time of the Reliability QosPolicy elapsed. - */ - // void write( - // const dds::topic::TopicInstance& i); - - /** - * This operation modifies the value of a data instance and provides a value for the - * source_timestamp explicitly. - * - * Detailed Description
    - * It modifies the values of the given data instances. When this operation is used, - * the application provides the value for the parameter source_timestamp that is made - * available to connected DataReader objects.
    - * This timestamp is important for the interpretation of the - * dds::core::policy::DestinationOrder QosPolicy. - * - * As a side effect, this operation asserts liveliness on the DataWriter itself and on - * the containing DomainParticipant. - * - * Topic Instance
    - * A TopicInstance encapsulates a sample and its associated - * @ref anchor_dds_pub_datawriter_write_instance_handle "instance handle". - * - * Blocking
    - * This operation can be blocked (see @ref anchor_dds_pub_datawriter_write_blocking "write blocking"). - * - * @param i the instance to write - * @param timestamp the timestamp for this sample - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - * @throws dds::core::NotEnabledError - * The DataWriter has not yet been enabled. - * @throws dds::core::PreconditionNotMetError - * The handle has not been registered with this DataWriter. - * @throws dds::core::TimeoutError - * Either the current action overflowed the available resources - * as specified by the combination of the Reliability QosPolicy, - * History QosPolicy and ResourceLimits QosPolicy, or the current action - * was waiting for data delivery acknowledgement by synchronous DataReaders. - * This caused blocking of the write operation, which could not be resolved before - * max_blocking_time of the Reliability QosPolicy elapsed. - */ - // void write( - // const dds::topic::TopicInstance& i, - // const dds::core::Time& timestamp); - - /** - * This operation writes a series of typed Samples or TopicInstances. - * - * Detailed Description
    - * This operation takes a sequence of typed Samples or TopicInstances, which - * is determined by the template specialization. - * - * It modifies the values of the given data instances. When this operation is used, - * the Data Distribution Service will automatically supply the value of the - * source_timestamp that is made available to connected DataReader objects.
    - * This timestamp is important for the interpretation of the - * dds::core::policy::DestinationOrder QosPolicy. - * - * As a side effect, this operation asserts liveliness on the DataWriter itself and on - * the containing DomainParticipant. - * - * Topic Instance
    - * A TopicInstance encapsulates a typed Sample and its associated - * @ref anchor_dds_pub_datawriter_write_instance_handle "instance handle". - * - * Blocking
    - * This operation can be blocked (see @ref anchor_dds_pub_datawriter_write_blocking "write blocking"). - * - * @param begin An iterator pointing to the beginning of a sequence of - * Samples or a sequence of TopicInstances - * @param end An iterator pointing to the end of a sequence of - * Samples or a sequence of TopicInstances - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - * @throws dds::core::NotEnabledError - * The DataWriter has not yet been enabled. - * @throws dds::core::PreconditionNotMetError - * The handle has not been registered with this DataWriter. - * @throws dds::core::TimeoutError - * Either the current action overflowed the available resources - * as specified by the combination of the Reliability QosPolicy, - * History QosPolicy and ResourceLimits QosPolicy, or the current action - * was waiting for data delivery acknowledgement by synchronous DataReaders. - * This caused blocking of the write operation, which could not be resolved before - * max_blocking_time of the Reliability QosPolicy elapsed. - */ - template - OMG_DDS_API void write( - const FWIterator& begin, - const FWIterator& end); - - /** - * This operation writes a series of typed Samples or TopicInstances and provides - * a value for the source_timestamp for these samples explicitly. - * - * Detailed Description
    - * This operation takes a sequence of typed Samples or TopicInstances, which - * is determined by the template specialization. - * - * It modifies the values of the given data instances. When this operation is used, - * the application provides the value for the parameter source_timestamp that is made - * available to connected DataReader objects.
    - * This timestamp is important for the interpretation of the - * dds::core::policy::DestinationOrder QosPolicy. - * - * As a side effect, this operation asserts liveliness on the DataWriter itself and on - * the containing DomainParticipant. - * - * Topic Instance
    - * A TopicInstance encapsulates a sample and its associated - * @ref anchor_dds_pub_datawriter_write_instance_handle "instance handle". - * - * Blocking
    - * This operation can be blocked (see @ref anchor_dds_pub_datawriter_write_blocking "write blocking"). - * - * @param begin an iterator pointing to the beginning of a sequence of - * TopicInstances - * @param end an iterator pointing to the end of a sequence of - * TopicInstances - * @param timestamp the time stamp - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - * @throws dds::core::NotEnabledError - * The DataWriter has not yet been enabled. - * @throws dds::core::PreconditionNotMetError - * The handle has not been registered with this DataWriter. - * @throws dds::core::TimeoutError - * Either the current action overflowed the available resources - * as specified by the combination of the Reliability QosPolicy, - * History QosPolicy and ResourceLimits QosPolicy, or the current action - * was waiting for data delivery acknowledgement by synchronous DataReaders. - * This caused blocking of the write operation, which could not be resolved before - * max_blocking_time of the Reliability QosPolicy elapsed. - */ - template - OMG_DDS_API void write( - const FWIterator& begin, - const FWIterator& end, - const dds::core::Time& timestamp); - - /** - * This operation writes a series of typed Samples and their parallel instance handles. - * - * Detailed Description
    - * It modifies the values of the given data instances. When this operation is used, - * the Data Distribution Service will automatically supply the value of the - * source_timestamp that is made available to connected DataReader objects.
    - * This timestamp is important for the interpretation of the - * dds::core::policy::DestinationOrder QosPolicy. - * - * As a side effect, this operation asserts liveliness on the DataWriter itself and on - * the containing DomainParticipant. - * - * Instance Handle
    - * See @ref anchor_dds_pub_datawriter_write_instance_handle "write instance handle". - * - * Blocking
    - * This operation can be blocked (see @ref anchor_dds_pub_datawriter_write_blocking "write blocking"). - * - * @param data_begin an iterator pointing to the beginning of a sequence of samples - * @param data_end an iterator pointing to the end of a sequence of samples - * @param handle_begin an iterator pointing to the beginning of a sequence of InstanceHandles - * @param handle_end an iterator pointing to the end of a sequence of InstanceHandles - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - * @throws dds::core::NotEnabledError - * The DataWriter has not yet been enabled. - * @throws dds::core::PreconditionNotMetError - * The handle has not been registered with this DataWriter. - * @throws dds::core::TimeoutError - * Either the current action overflowed the available resources - * as specified by the combination of the Reliability QosPolicy, - * History QosPolicy and ResourceLimits QosPolicy, or the current action - * was waiting for data delivery acknowledgement by synchronous DataReaders. - * This caused blocking of the write operation, which could not be resolved before - * max_blocking_time of the Reliability QosPolicy elapsed. - */ - template< - typename SamplesFWIterator, - typename HandlesFWIterator> - OMG_DDS_API void write( - const SamplesFWIterator& data_begin, - const SamplesFWIterator& data_end, - const HandlesFWIterator& handle_begin, - const HandlesFWIterator& handle_end); - - /** - * This operation writes a series of typed Samples or TopicInstances and provides - * a value for the source_timestamp for these samples explicitly. - * - * Detailed Description
    - * It modifies the values of the given data instances. When this operation is used, - * the application provides the value for the parameter source_timestamp that is made - * available to connected DataReader objects.
    - * This timestamp is important for the interpretation of the - * dds::core::policy::DestinationOrder QosPolicy. - * - * As a side effect, this operation asserts liveliness on the DataWriter itself and on - * the containing DomainParticipant. - * - * Instance Handle
    - * See @ref anchor_dds_pub_datawriter_write_instance_handle "write instance handle". - * - * Blocking
    - * This operation can be blocked (see @ref anchor_dds_pub_datawriter_write_blocking "write blocking"). - * - * @param data_begin an iterator pointing to the beginning of a sequence of samples - * @param data_end an iterator pointing to the end of a sequence of samples - * @param handle_begin an iterator pointing to the beginning of a sequence of InstanceHandles - * @param handle_end an iterator pointing to the end of a sequence of InstanceHandles - * @param timestamp the time stamp - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - * @throws dds::core::NotEnabledError - * The DataWriter has not yet been enabled. - * @throws dds::core::PreconditionNotMetError - * The handle has not been registered with this DataWriter. - * @throws dds::core::TimeoutError - * Either the current action overflowed the available resources - * as specified by the combination of the Reliability QosPolicy, - * History QosPolicy and ResourceLimits QosPolicy, or the current action - * was waiting for data delivery acknowledgement by synchronous DataReaders. - * This caused blocking of the write operation, which could not be resolved before - * max_blocking_time of the Reliability QosPolicy elapsed. - */ - template< - typename SamplesFWIterator, - typename HandlesFWIterator> - OMG_DDS_API void write( - const SamplesFWIterator& data_begin, - const SamplesFWIterator& data_end, - const HandlesFWIterator& handle_begin, - const HandlesFWIterator& handle_end, - const dds::core::Time& timestamp); - - - /** @copydoc dds::pub::DataWriter::write(const T& data) */ - OMG_DDS_API DataWriter& operator <<( - const T& data); - - /** @copydoc dds::pub::DataWriter::write(const T& sample, const dds::core::Time& timestamp) */ - OMG_DDS_API DataWriter& operator <<( - const std::pair& data); - - /** @copydoc dds::pub::DataWriter::write(const T& sample, const ::dds::core::InstanceHandle& instance) */ - OMG_DDS_API DataWriter& operator <<( - const std::pair& data); - - /** @cond - * This can be useful for the DataReader (see fi MaxSamplesManipulatorFunctor), but not - * really for the DataWriter. Leave it from the API documentation for clarity. - */ - OMG_DDS_API DataWriter& operator <<( - DataWriter& (*manipulator)(DataWriter&)); - /** @endcond */ - - //========================================================================== - //== Instance Management - - /** - * This operation informs the Data Distribution Service that the application will be - * modifying a particular instance. - * - * Detailed Description
    - * This operation informs the Data Distribution Service that the application will be - * modifying a particular instance. This operation may be invoked prior to calling any - * operation that modifies the instance, such as write, unregister_instance or - * dispose_instance.
    - * When the application does register the instance before modifying, the Data - * Distribution Service will handle the instance more efficiently. It takes as a parameter - * (instance_data) an instance (to get the key value) and returns a handle that can - * be used in successive DataWriter operations. In case of an error, a HANDLE_NIL - * handle (InstanceHandle.is_nil() == true) is returned. - * - * The explicit use of this operation is optional as the application can directly call the - * write, unregister_instance or dispose_instance operations without InstanceHandle, - * which indicate that the sample should be examined to identify the instance. - * - * When this operation is used, the Data Distribution Service will automatically supply - * the value of the source_timestamp that is made available to connected - * DataReader objects.
    - * This timestamp is important for the interpretation of the - * dds::core::policy::DestinationOrder QosPolicy. - * - * @anchor anchor_dds_pub_datawriter_register_blocking - * Blocking
    - * If the dds::core::policy::History QosPolicy is set to KEEP_ALL, the register_instance - * operation on the DataWriter may block if the modification would cause data to be - * lost because one of the limits, specified in the dds::core::policy::ResourceLimits, is - * exceeded. In case the synchronous attribute value of the - * dds::core::policy::Reliability is set to TRUE for communicating DataWriters and - * DataReaders then the DataWriter will wait until all synchronous - * DataReaders have acknowledged the data. Under these circumstances, the - * max_blocking_time attribute of the dds::core::policy::Reliability configures the - * maximum time the register operation may block (either waiting for space to become - * available or data to be acknowledged). If max_blocking_time elapses before the - * DataWriter is able to store the modification without exceeding the limits and all - * expected acknowledgements are received, the register_instance operation will fail - * will return a nil InstanceHandle. - * - * Multiple Calls
    - * If this operation is called for an already registered instance, it just returns the already - * allocated instance handle. This may be used to look up and retrieve the handle - * allocated to a given instance. - * - * Key
    - * The key is a typed Sample of which the key fields are set so that the instance - * can be identified. - * - * @param key the key of the instance to register - * @return the instance handle - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - * @throws dds::core::NotEnabledError - * The DataWriter has not yet been enabled. - * @throws dds::core::PreconditionNotMetError - * The handle has not been registered with this DataWriter. - */ - OMG_DDS_API const ::dds::core::InstanceHandle register_instance( - const T& key); - - /** - * This operation will inform the Data Distribution Service that the application will be - * modifying a particular instance and provides a value for the source_timestamp - * explicitly. - * - * Detailed Description
    - * This operation informs the Data Distribution Service that the application will be - * modifying a particular instance. This operation may be invoked prior to calling any - * operation that modifies the instance, such as write, unregister_instance or - * dispose_instance.
    - * When the application does register the instance before modifying, the Data - * Distribution Service will handle the instance more efficiently. It takes as a parameter - * (instance_data) an instance (to get the key value) and returns a handle that can - * be used in successive DataWriter operations. In case of an error, a HANDLE_NIL - * handle (InstanceHandle.is_nil() == true) is returned. - * - * The explicit use of this operation is optional as the application can directly call the - * write, unregister_instance or dispose_instance operations without InstanceHandle, - * which indicate that the sample should be examined to identify the instance. - * - * When this operation is used, the application provides the value for the parameter - * source_timestamp that is made available to connected DataReader objects.
    - * This timestamp is important for the interpretation of the - * dds::core::policy::DestinationOrder QosPolicy. - * - * Blocking
    - * This operation can be blocked (see @ref anchor_dds_pub_datawriter_register_blocking "register blocking"). - * - * Multiple Calls
    - * If this operation is called for an already registered instance, it just returns the already - * allocated instance handle. The source_timestamp is ignored in that case. - * - * Key
    - * The key is a typed Sample of which the key fields are set so that the instance - * can be identified. - * - * @param key the key of the instance to register - * @param timestamp the timestamp used for registration - * @return the instance handle - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - * @throws dds::core::NotEnabledError - * The DataWriter has not yet been enabled. - * @throws dds::core::PreconditionNotMetError - * The handle has not been registered with this DataWriter. - */ - OMG_DDS_API const ::dds::core::InstanceHandle register_instance( - const T& key, - const dds::core::Time& timestamp); - - /** - * This operation informs the Data Distribution Service that the application will not be - * modifying a particular instance any more. - * - * Detailed Description
    - * This operation informs the Data Distribution Service that the application will not be - * modifying a particular instance any more. Therefore, this operation reverses the - * action of @ref dds::pub::DataWriter::register_instance(const T& key) "\"register_instance\"" or - * @ref dds::pub::DataWriter::register_instance(const T& key, const dds::core::Time& timestamp) "\"register_instance_w_timestamp\"". - * register_instance or register_instance_w_timestamp.
    - * It should only be called on an instance that is currently registered. This operation - * should be called just once per instance, regardless of how many times - * @ref dds::pub::DataWriter::register_instance(const T& key) "register_instance" was called - * for that instance.
    - * This operation also indicates - * that the Data Distribution Service can locally remove all information regarding that - * instance. The application should not attempt to use the handle, previously - * allocated to that instance, after calling this operation. - * - * When this operation is used, the Data Distribution Service will automatically supply - * the value of the source_timestamp that is made available to connected - * DataReader objects. This timestamp is important for the interpretation of the - * dds::core::policy::DestinationOrder QosPolicy. - * - * @anchor anchor_dds_pub_datawriter_unregister_effects - * Effects
    - * If, after unregistering, the application wants to modify (write or dispose) the - * instance, it has to register the instance again, or it has to use the default - * instance handle (InstanceHandle.is_nil() == true). - * This operation does not indicate that the instance should be deleted (that is the - * purpose of the @ref dds::pub::DataWriter::dispose_instance(const T& key) "dispose". - * This operation just indicates that the DataWriter no longer - * has “anything to say” about the instance. If there is no other DataWriter that - * has registered the instance as well, then the dds::sub::status::InstanceState in all - * connected DataReaders will be changed to not_alive_no_writers, provided this - * InstanceState was not already set to not_alive_disposed. In the last case the - * InstanceState will not be effected by the unregister_instance call, - * see also @ref DCPS_Modules_Subscription_SampleInfo "Sample info concept". - * - * This operation can affect the ownership of the data instance. If the - * DataWriter was the exclusive owner of the instance, calling this operation will - * release that ownership, meaning ownership may be transferred to another, - * possibly lower strength, DataWriter. - * - * The operation must be called only on registered instances. Otherwise the operation - * trow PreconditionNotMetError. - * - * @anchor anchor_dds_pub_datawriter_unregister_blocking - * Blocking
    - * If the dds::core::policy::History QosPolicy is set to KEEP_ALL, the unregister_instance - * operation on the DataWriter may block if the modification would cause data to be - * lost because one of the limits, specified in the dds::core::policy::ResourceLimits, is - * exceeded. In case the synchronous attribute value of the - * dds::core::policy::Reliability is set to TRUE for communicating DataWriters and - * DataReaders then the DataWriter will wait until all synchronous - * DataReaders have acknowledged the data. Under these circumstances, the - * max_blocking_time attribute of the dds::core::policy::Reliability configures the - * maximum time the unregister operation may block (either waiting for space to become - * available or data to be acknowledged). If max_blocking_time elapses before the - * DataWriter is able to store the modification without exceeding the limits and all - * expected acknowledgements are received, the unregister_instance operation will fail - * and throw TimeoutError. - * - * @param i the instance to unregister - * @return a reference to the DataWriter - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::NotEnabledError - * The DataWriter has not yet been enabled. - * @throws dds::core::PreconditionNotMetError - * The handle has not been registered with this DataWriter. - * @throws dds::core::TimeoutError - * Either the current action overflowed the available resources - * as specified by the combination of the Reliability QosPolicy, - * History QosPolicy and ResourceLimits QosPolicy, or the current action - * was waiting for data delivery acknowledgement by synchronous DataReaders. - * This caused blocking of the write operation, which could not be resolved before - * max_blocking_time of the Reliability QosPolicy elapsed. - */ - OMG_DDS_API DataWriter& unregister_instance( - const ::dds::core::InstanceHandle& i); - - /** - * This operation will inform the Data Distribution Service that the application will not - * be modifying a particular instance any more and provides a value for the - * source_timestamp explicitly. - * - * Detailed Description
    - * This operation informs the Data Distribution Service that the application will not be - * modifying a particular instance any more. Therefore, this operation reverses the - * action of @ref dds::pub::DataWriter::register_instance(const T& key) "\"register_instance\"" or - * @ref dds::pub::DataWriter::register_instance(const T& key, const dds::core::Time& timestamp) "\"register_instance_w_timestamp\"". - * register_instance or register_instance_w_timestamp.
    - * It should only be called on an instance that is currently registered. This operation - * should be called just once per instance, regardless of how many times - * @ref dds::pub::DataWriter::register_instance(const T& key) "register_instance" was called - * for that instance.
    - * This operation also indicates - * that the Data Distribution Service can locally remove all information regarding that - * instance. The application should not attempt to use the handle, previously - * allocated to that instance, after calling this operation. - * - * When this operation is used, the application itself supplied - * the value of the source_timestamp that is made available to connected - * DataReader objects. This timestamp is important for the interpretation of the - * dds::core::policy::DestinationOrder QosPolicy. - * - * Effects
    - * See @ref anchor_dds_pub_datawriter_unregister_effects "here" for the unregister effects. - * - * Blocking
    - * This operation can be blocked (see @ref anchor_dds_pub_datawriter_unregister_blocking "unregister blocking"). - * - * @param i the instance to unregister - * @param timestamp the timestamp - * @return a reference to the DataWriter - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::NotEnabledError - * The DataWriter has not yet been enabled. - * @throws dds::core::PreconditionNotMetError - * The handle has not been registered with this DataWriter. - * @throws dds::core::TimeoutError - * Either the current action overflowed the available resources - * as specified by the combination of the Reliability QosPolicy, - * History QosPolicy and ResourceLimits QosPolicy, or the current action - * was waiting for data delivery acknowledgement by synchronous DataReaders. - * This caused blocking of the write operation, which could not be resolved before - * max_blocking_time of the Reliability QosPolicy elapsed. - */ - OMG_DDS_API DataWriter& unregister_instance( - const ::dds::core::InstanceHandle& i, - const dds::core::Time& timestamp); - - /** - * This operation informs the Data Distribution Service that the application will not be - * modifying a particular instance any more. - * - * Detailed Description
    - * This operation informs the Data Distribution Service that the application will not be - * modifying a particular instance any more. Therefore, this operation reverses the - * action of @ref dds::pub::DataWriter::register_instance(const T& key) "\"register_instance\"" or - * @ref dds::pub::DataWriter::register_instance(const T& key, const dds::core::Time& timestamp) "\"register_instance_w_timestamp\"". - * register_instance or register_instance_w_timestamp.
    - * It should only be called on an instance that is currently registered. This operation - * should be called just once per instance, regardless of how many times - * @ref dds::pub::DataWriter::register_instance(const T& key) "register_instance" was called - * for that instance.
    - * This operation also indicates - * that the Data Distribution Service can locally remove all information regarding that - * instance. The application should not attempt to use the handle, previously - * allocated to that instance, after calling this operation. - * - * When this operation is used, the Data Distribution Service will automatically supply - * the value of the source_timestamp that is made available to connected - * DataReader objects. This timestamp is important for the interpretation of the - * dds::core::policy::DestinationOrder QosPolicy. - * - * Effects
    - * See @ref anchor_dds_pub_datawriter_unregister_effects "here" for the unregister effects. - * - * Blocking
    - * This operation can be blocked (see @ref anchor_dds_pub_datawriter_unregister_blocking "unregister blocking"). - * - * Instance
    - * The instance is identified by the key fields of the given typed data sample, instead - * of an InstanceHandle. - * - * @param key sample of the instance to dispose - * @return a reference to the DataWriter - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::NotEnabledError - * The DataWriter has not yet been enabled. - * @throws dds::core::PreconditionNotMetError - * The handle has not been registered with this DataWriter. - * @throws dds::core::TimeoutError - * Either the current action overflowed the available resources - * as specified by the combination of the Reliability QosPolicy, - * History QosPolicy and ResourceLimits QosPolicy, or the current action - * was waiting for data delivery acknowledgement by synchronous DataReaders. - * This caused blocking of the write operation, which could not be resolved before - * max_blocking_time of the Reliability QosPolicy elapsed. - */ - OMG_DDS_API DataWriter& unregister_instance( - const T& key); - - /** - * This operation will inform the Data Distribution Service that the application will not - * be modifying a particular instance any more and provides a value for the - * source_timestamp explicitly. - * - * Detailed Description
    - * This operation informs the Data Distribution Service that the application will not be - * modifying a particular instance any more. Therefore, this operation reverses the - * action of @ref dds::pub::DataWriter::register_instance(const T& key) "\"register_instance\"" or - * @ref dds::pub::DataWriter::register_instance(const T& key, const dds::core::Time& timestamp) "\"register_instance_w_timestamp\"". - * register_instance or register_instance_w_timestamp.
    - * It should only be called on an instance that is currently registered. This operation - * should be called just once per instance, regardless of how many times - * @ref dds::pub::DataWriter::register_instance(const T& key) "register_instance" was called - * for that instance.
    - * This operation also indicates - * that the Data Distribution Service can locally remove all information regarding that - * instance. The application should not attempt to use the handle, previously - * allocated to that instance, after calling this operation. - * - * When this operation is used, the application itself supplied - * the value of the source_timestamp that is made available to connected - * DataReader objects. This timestamp is important for the interpretation of the - * dds::core::policy::DestinationOrder QosPolicy. - * - * Effects
    - * See @ref anchor_dds_pub_datawriter_unregister_effects "here" for the unregister effects. - * - * Blocking
    - * This operation can be blocked (see @ref anchor_dds_pub_datawriter_unregister_blocking "unregister blocking"). - * - * Instance
    - * The instance is identified by the key fields of the given typed data sample, instead - * of an InstanceHandle. - * - * @param key sample of the instance to dispose - * @param timestamp the timestamp - * @return a reference to the DataWriter - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::NotEnabledError - * The DataWriter has not yet been enabled. - * @throws dds::core::PreconditionNotMetError - * The handle has not been registered with this DataWriter. - * @throws dds::core::TimeoutError - * Either the current action overflowed the available resources - * as specified by the combination of the Reliability QosPolicy, - * History QosPolicy and ResourceLimits QosPolicy, or the current action - * was waiting for data delivery acknowledgement by synchronous DataReaders. - * This caused blocking of the write operation, which could not be resolved before - * max_blocking_time of the Reliability QosPolicy elapsed. - */ - OMG_DDS_API DataWriter& unregister_instance( - const T& key, - const dds::core::Time& timestamp); - - /** - * This operation requests the Data Distribution Service to mark the instance for - * deletion. - * - * Detailed Description
    - * This operation requests the Data Distribution Service to mark the instance for - * deletion. Copies of the instance and its corresponding samples, which are stored in - * every connected DataReader and, dependent on the QosPolicy settings, also in - * the Transient and Persistent stores, will be marked for deletion by setting their - * dds::sub::status::InstanceState to not_alive_disposed state. - * - * When this operation is used, the Data Distribution Service will automatically supply - * the value of the source_timestamp that is made available to connected - * DataReader objects. This timestamp is important for the interpretation of the - * dds::core::policy::DestinationOrder QosPolicy. - * - * As a side effect, this operation asserts liveliness on the DataWriter itself and on - * the containing DomainParticipant. - * - * @anchor anchor_dds_pub_datawriter_dispose_effect_readers - * Effects on DataReaders
    - * Actual deletion of the instance administration in a connected DataReader will be - * postponed until the following conditions have been met: - * - the instance must be unregistered (either implicitly or explicitly) by all connected - * DataWriters that have previously registered it. - * - A DataWriter can register an instance explicitly by using the special - * register_instance operations. - * - A DataWriter can register an instance implicitly by using no or the default (nil) - * InstanceHandle in any of the other DataWriter operations. - * - A DataWriter can unregister an instance explicitly by using one of the special - * unregister_instance operations. - * - A DataWriter will unregister all its contained instances implicitly when it is - * deleted. - * - When a DataReader detects a loss of liveliness in one of its connected - * DataWriters, it will consider all instances registered by that DataWriter as - * being implicitly unregistered. - * - and the application must have consumed all samples belonging to the instance, - * either implicitly or explicitly. - * - An application can consume samples explicitly by invoking the take operation, - * or one of its variants, on its DataReaders. - * - The DataReader can consume disposed samples implicitly when the - * autopurge_disposed_samples_delay of the ReaderData - * Lifecycle QosPolicy has expired. - * - * The DataReader may also remove instances that haven’t been disposed first: this - * happens when the autopurge_nowriter_samples_delay of the - * ReaderDataLifecycle QosPolicy has expired after the instance is considered - * unregistered by all connected DataWriters (i.e. when it has a - * InstanceState of not_alive_no_writers.
    - * See also dds::core::policy::ReaderDataLifecycle QosPolicy. - * - * @anchor anchor_dds_pub_datawriter_dispose_effect_stores - * Effects on Transient/Persistent Stores
    - * Actual deletion of the instance administration in the connected Transient and - * Persistent stores will be postponed until the following conditions have been met: - * - the instance must be unregistered (either implicitly or explicitly) by all connected - * DataWriters that have previously registered it. (See above.) - * - and the period of time specified by the service_cleanup_delay attribute in - * the DurabilityServiceQosPolicy on the Topic must have elapsed after the - * instance is considered unregistered by all connected DataWriters. - * - * See also dds::core::policy::Durability QosPolicy. - * - * Instance Handle
    - * If handle is not nil, it must correspond to the value returned by - * @ref dds::pub::DataWriter::register_instance(const T& key) "\"register_instance\"" or - * @ref dds::pub::DataWriter::register_instance(const T& key, const dds::core::Time& timestamp) "\"register_instance_w_timestamp\"" - * when the instance (identified by its key) was registered. Passing such a registered - * handle helps the Data Distribution Service to process the sample more efficiently. - * - * @anchor anchor_dds_pub_datawriter_dispose_blocking - * Blocking
    - * If the dds::core::policy::History QosPolicy is set to KEEP_ALL, the dispose - * operation on the DataWriter may block if the modification would cause data to be - * lost because one of the limits, specified in the dds::core::policy::ResourceLimits, is - * exceeded. In case the synchronous attribute value of the - * dds::core::policy::Reliability is set to TRUE for communicating DataWriters and - * DataReaders then the DataWriter will wait until all synchronous - * DataReaders have acknowledged the data. Under these circumstances, the - * max_blocking_time attribute of the dds::core::policy::Reliability configures the - * maximum time the dispose operation may block (either waiting for space to become - * available or data to be acknowledged). If max_blocking_time elapses before the - * DataWriter is able to store the modification without exceeding the limits and all - * expected acknowledgements are received, the dispose operation will fail and throw - * TimeoutError. - * - * @param i the instance to dispose - * @return a reference to the DataWriter - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::NotEnabledError - * The DataWriter has not yet been enabled. - * @throws dds::core::PreconditionNotMetError - * The handle has not been registered with this DataWriter. - * @throws dds::core::TimeoutError - * Either the current action overflowed the available resources - * as specified by the combination of the Reliability QosPolicy, - * History QosPolicy and ResourceLimits QosPolicy, or the current action - * was waiting for data delivery acknowledgement by synchronous DataReaders. - * This caused blocking of the write operation, which could not be resolved before - * max_blocking_time of the Reliability QosPolicy elapsed. - */ - OMG_DDS_API DataWriter& dispose_instance( - const ::dds::core::InstanceHandle& i); - - /** - * This operation requests the Data Distribution Service to mark the instance for - * deletion and provides a value for the source_timestamp explicitly. - * - * Detailed Description
    - * This operation requests the Data Distribution Service to mark the instance for - * deletion. Copies of the instance and its corresponding samples, which are stored in - * every connected DataReader and, dependent on the QosPolicy settings, also in - * the Transient and Persistent stores, will be marked for deletion by setting their - * dds::sub::status::InstanceState to not_alive_disposed state. - * - * When this operation is used, the application explicitly supplies - * the value of the source_timestamp that is made available to connected - * DataReader objects. This timestamp is important for the interpretation of the - * dds::core::policy::DestinationOrder QosPolicy. - * - * As a side effect, this operation asserts liveliness on the DataWriter itself and on - * the containing DomainParticipant. - * - * Effects
    - * This operation @ref anchor_dds_pub_datawriter_dispose_effect_readers "effects DataReaders" - * and @ref anchor_dds_pub_datawriter_dispose_effect_stores "effects Transient/Persistent Stores". - * - * Instance Handle
    - * If handle is not nil, it must correspond to the value returned by - * @ref dds::pub::DataWriter::register_instance(const T& key) "\"register_instance\"" or - * @ref dds::pub::DataWriter::register_instance(const T& key, const dds::core::Time& timestamp) "\"register_instance_w_timestamp\"" - * when the instance (identified by its key) was registered. Passing such a registered - * handle helps the Data Distribution Service to process the sample more efficiently. - * - * Blocking
    - * This operation can be blocked (see @ref anchor_dds_pub_datawriter_dispose_blocking "dispose blocking"). - * - * - * @param i the instance to dispose - * @param timestamp the timestamp - * @return a reference to the DataWriter - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::NotEnabledError - * The DataWriter has not yet been enabled. - * @throws dds::core::PreconditionNotMetError - * The handle has not been registered with this DataWriter. - * @throws dds::core::TimeoutError - * Either the current action overflowed the available resources - * as specified by the combination of the Reliability QosPolicy, - * History QosPolicy and ResourceLimits QosPolicy, or the current action - * was waiting for data delivery acknowledgement by synchronous DataReaders. - * This caused blocking of the write operation, which could not be resolved before - * max_blocking_time of the Reliability QosPolicy elapsed. - */ - OMG_DDS_API DataWriter& dispose_instance( - const ::dds::core::InstanceHandle& i, - const dds::core::Time& timestamp); - - /** - * This operation requests the Data Distribution Service to mark the instance for - * deletion. - * - * Detailed Description
    - * This operation requests the Data Distribution Service to mark the instance for - * deletion. Copies of the instance and its corresponding samples, which are stored in - * every connected DataReader and, dependent on the QosPolicy settings, also in - * the Transient and Persistent stores, will be marked for deletion by setting their - * dds::sub::status::InstanceState to not_alive_disposed state. - * - * When this operation is used, the Data Distribution Service will automatically supply - * the value of the source_timestamp that is made available to connected - * DataReader objects. This timestamp is important for the interpretation of the - * dds::core::policy::DestinationOrder QosPolicy. - * - * As a side effect, this operation asserts liveliness on the DataWriter itself and on - * the containing DomainParticipant. - * - * Effects
    - * This operation @ref anchor_dds_pub_datawriter_dispose_effect_readers "effects DataReaders" - * and @ref anchor_dds_pub_datawriter_dispose_effect_stores "effects Transient/Persistent Stores". - * - * Instance
    - * The instance is identified by the key fields of the given typed data sample, instead - * of an InstanceHandle. - * - * Blocking
    - * This operation can be blocked (see @ref anchor_dds_pub_datawriter_dispose_blocking "dispose blocking"). - * - * @param key sample of the instance to dispose - * @return a reference to the DataWriter - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::NotEnabledError - * The DataWriter has not yet been enabled. - * @throws dds::core::PreconditionNotMetError - * The handle has not been registered with this DataWriter. - * @throws dds::core::TimeoutError - * Either the current action overflowed the available resources - * as specified by the combination of the Reliability QosPolicy, - * History QosPolicy and ResourceLimits QosPolicy, or the current action - * was waiting for data delivery acknowledgement by synchronous DataReaders. - * This caused blocking of the write operation, which could not be resolved before - * max_blocking_time of the Reliability QosPolicy elapsed. - */ - OMG_DDS_API DataWriter& dispose_instance( - const T& key); - - /** - * This operation requests the Data Distribution Service to mark the instance for - * deletion and provides a value for the source_timestamp explicitly. - * - * Detailed Description
    - * This operation requests the Data Distribution Service to mark the instance for - * deletion. Copies of the instance and its corresponding samples, which are stored in - * every connected DataReader and, dependent on the QosPolicy settings, also in - * the Transient and Persistent stores, will be marked for deletion by setting their - * dds::sub::status::InstanceState to not_alive_disposed state. - * - * When this operation is used, the application explicitly supplies - * the value of the source_timestamp that is made available to connected - * DataReader objects. This timestamp is important for the interpretation of the - * dds::core::policy::DestinationOrder QosPolicy. - * - * As a side effect, this operation asserts liveliness on the DataWriter itself and on - * the containing DomainParticipant. - * - * Effects
    - * This operation @ref anchor_dds_pub_datawriter_dispose_effect_readers "effects DataReaders" - * and @ref anchor_dds_pub_datawriter_dispose_effect_stores "effects Transient/Persistent Stores". - * - * Instance
    - * The instance is identified by the key fields of the given typed data sample, instead - * of an InstanceHandle. - * - * Blocking
    - * This operation can be blocked (see @ref anchor_dds_pub_datawriter_dispose_blocking "dispose blocking"). - * - * @param key sample of the instance to dispose - * @param timestamp the timestamp - * @return a reference to the DataWriter - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::NotEnabledError - * The DataWriter has not yet been enabled. - * @throws dds::core::PreconditionNotMetError - * The handle has not been registered with this DataWriter. - * @throws dds::core::TimeoutError - * Either the current action overflowed the available resources - * as specified by the combination of the Reliability QosPolicy, - * History QosPolicy and ResourceLimits QosPolicy, or the current action - * was waiting for data delivery acknowledgement by synchronous DataReaders. - * This caused blocking of the write operation, which could not be resolved before - * max_blocking_time of the Reliability QosPolicy elapsed. - */ - OMG_DDS_API DataWriter& dispose_instance( - const T& key, - const dds::core::Time& timestamp); - - /** - * This operation retrieves the key value of a specific instance. - * - * This operation can be used to retrieve the instance key that corresponds - * to an instance_handle. The operation will only fill the fields that form - * the key inside the sample instance. - * - * This operation may raise a InvalidArgumentError exception if the InstanceHandle - * does not correspond to an existing data-object known to the DataWriter. - * If the implementation is not able to check invalid handles, then the - * result in this situation is unspecified. - * - * The TopicInstance is added as parameter to be able to overload this operation. - * - * @param[out] i A topic instance to set the handle and sample key fields of - * @param[in] h The instance handle - * @return The given topic instance with the handle and key fields set - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::InvalidArgumentError - * The InstanceHandle is not a valid handle. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - * @throws dds::core::NotEnabledError - * The DataWriter has not yet been enabled. - * @throws dds::core::PreconditionNotMetError - * The handle has not been registered with this DataWriter. - */ - // dds::topic::TopicInstance& key_value( - // dds::topic::TopicInstance& i, - // const ::dds::core::InstanceHandle& h); - - /** - * This operation retrieves the key value of a specific instance. - * - * This operation can be used to retrieve the instance key that corresponds - * to an instance_handle. The operation will only fill the fields that form - * the key inside the sample instance. - * - * This operation may raise a InvalidArgumentError exception if the InstanceHandle - * does not correspond to an existing data-object known to the DataWriter. - * If the implementation is not able to check invalid handles, then the - * result in this situation is unspecified. - * - * The Sample is added as parameter to be able to overload this operation. - * - * @param[out] sample A sample to set the key fields of - * @param[in] h The instance handle - * @return The given sample with the key fields set - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::InvalidArgumentError - * The InstanceHandle is not a valid handle. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - * @throws dds::core::NotEnabledError - * The DataWriter has not yet been enabled. - * @throws dds::core::PreconditionNotMetError - * The handle has not been registered with this DataWriter. - */ - OMG_DDS_API T& key_value( - T& sample, - const ::dds::core::InstanceHandle& h); - - /** - * This operation returns the value of the instance handle which corresponds - * to the instance_data. - * - * The instance_data parameter is only used for the purpose of - * examining the fields that define the key. The instance handle can be used in any - * write, dispose or unregister operations (or their time stamped variants) that - * operate on a specific instance. Note that DataWriter instance handles are local, - * and are not interchangeable with DataReader instance handles nor with instance - * handles of an other DataWriter. - * - * This operation does not register the instance in question. If the instance has not been - * previously registered or if for any other - * reason the Service is unable to provide an instance handle, the Service will return - * the default nil handle (InstanceHandle.is_nil() == true). - * - * @param key the sample - * @return the instance handle - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - */ - OMG_DDS_API dds::core::InstanceHandle lookup_instance( - const T& key); - - //========================================================================== - //== QoS Management - - /** @copydoc dds::pub::TAnyDataWriter::qos(const dds::pub::qos::DataWriterQos& qos) */ - OMG_DDS_API DataWriter& operator <<( - const qos::DataWriterQos& qos); - - - //========================================================================== - //== Entity Navigation - - /** - * Get the Topic associated with this DataWriter. - * - * @return the Topic - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - */ - // const dds::topic::Topic& topic() const; - - //========================================================================== - //== Listeners Management - - /** - * Register a listener with the DataWriter. - * - * This operation attaches a DataWriterListener to the DataWriter. Only one - * DataWriterListener can be attached to each DataWriter. If a - * DataWriterListener was already attached, the operation will replace it with the - * new one. When the listener is the NULL pointer, it represents a listener that is - * treated as a NOOP for all statuses activated in the bit mask. - * - * Listener un-registration is performed by setting the listener to NULL and mask none(). - * - * @anchor anchor_dds_pub_datawriter_commstatus - * Communication Status
    - * For each communication status, the StatusChangedFlag flag is initially set to - * FALSE. It becomes TRUE whenever that communication status changes. For each - * communication status activated in the mask, the associated DataWriterListener - * operation is invoked and the communication status is reset to FALSE, as the listener - * implicitly accesses the status which is passed as a parameter to that operation. The - * status is reset prior to calling the listener, so if the application calls the - * get__status from inside the listener it will see the status - * already reset. An exception to this rule is the NULL listener, which does not reset the - * communication statuses for which it is invoked. - * - * The following statuses are applicable to the DataWriterListener: - * - dds::core::status::StatusMask::offered_deadline_missed() - * - dds::core::status::StatusMask::offered_incompatible_qos() - * - dds::core::status::StatusMask::liveliness_lost() - * - dds::core::status::StatusMask::publication_matched() - * - * Be aware that the PUBLICATION_MATCHED_STATUS is not applicable when the - * infrastructure does not have the information available to determine connectivity. - * This is the case when OpenSplice is configured not to maintain discovery - * information in the Networking Service. (See the description for the - * NetworkingService/Discovery/enabled property in the Deployment - * Manual for more information about this subject.) In this case the operation will - * throw UnsupportedError. - * - * Status bits are declared as a constant and can be used by the application in an OR - * operation to create a tailored mask. The special constant dds::core::status::StatusMask::none() - * can be used to indicate that the created entity should not respond to any of its available - * statuses. The DDS will therefore attempt to propagate these statuses to its factory. - * The special constant dds::core::status::StatusMask::all() can be used to select all applicable - * statuses specified in the “Data Distribution Service for Real-time Systems Version - * 1.2” specification which are applicable to the PublisherListener. - * - * @anchor anchor_dds_pub_datawriter_commpropagation - * Status Propagation
    - * In case a communication status is not activated in the mask of the - * DataWriterListener, the PublisherListener of the containing Publisher - * is invoked (if attached and activated for the status that occurred). This allows the - * application to set a default behaviour in the PublisherListener of the containing - * Publisher and a DataWriter specific behaviour when needed. In case the - * communication status is not activated in the mask of the PublisherListener as - * well, the communication status will be propagated to the - * DomainParticipantListener of the containing DomainParticipant. In case - * the DomainParticipantListener is also not attached or the communication - * status is not activated in its mask, the application is not notified of the change. - * - * See also @ref DCPS_Modules_Infrastructure_Listener "listener information". - * - * @param listener the listener - * @param mask the mask defining the events for which the listener - * will be notified. - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::UnsupportedError - * A status was selected that cannot be supported because - * the infrastructure does not maintain the required connectivity information. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - OMG_DDS_API void listener( - DataWriterListener* listener, - const ::dds::core::status::StatusMask& mask); - - /** - * Get the listener of this DataWriter. - * - * See also @ref DCPS_Modules_Infrastructure_Listener "listener information". - * - * @return the listener - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - */ - OMG_DDS_API DataWriterListener* listener() const; -}; - -} //namespace pub -} //namespace dds - -#endif //OMG_DDS_PUB_DATA_WRITER_HPP_ diff --git a/include/dds/pub/Publisher.hpp b/include/dds/pub/Publisher.hpp deleted file mode 100644 index 9b1bd7a6444..00000000000 --- a/include/dds/pub/Publisher.hpp +++ /dev/null @@ -1,331 +0,0 @@ -/* - * Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_PUB_PUBLISHER_HPP_ -#define OMG_DDS_PUB_PUBLISHER_HPP_ - -#include - -#include -#include -#include -#include - -namespace dds { -namespace pub { - -class PublisherListener; - -/** - * @brief - * The Publisher acts on the behalf of one or several DataWriter objects - * that belong to it. - * - * When it is informed of a change to the data associated - * with one of its DataWriter objects, it decides when it is appropriate - * to actually send the data-update message. In making this decision, it - * considers any extra information that goes with the data (timestamp, - * writer, etc.) as well as the QoS of the Publisher and the DataWriter. - * - * @see @ref DCPS_Modules_Publisher "Publisher" - */ -class Publisher : public dds::core::TEntity -{ -public: - - /** - * Local convenience typedef for dds::pub::PublisherListener. - */ - typedef PublisherListener Listener; - - OMG_DDS_REF_TYPE_PROTECTED_DC( - Publisher, - dds::core::TEntity, - detail::Publisher) - - OMG_DDS_IMPLICIT_REF_BASE( - Publisher) - - /** - * Create a new Publisher. - * - * The Publisher will be created with the QoS values specified on the last - * successful call to @link dds::domain::DomainParticipant::default_publisher_qos(const ::dds::pub::qos::PublisherQos& qos) - * dp.default_publisher_qos(qos) @endlink or, if the call was never made, the - * @ref anchor_dds_pub_publisher_qos_defaults "default" values. - * - * @param dp the domain participant - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - OMG_DDS_API Publisher( - const dds::domain::DomainParticipant& dp); - - /** - * Create a new Publisher. - * - * The Publisher will be created with the given QosPolicy settings and if - * applicable, attaches the optionally specified PublisherListener to it. - * - * See @ref DCPS_Modules_Infrastructure_Listener "listener" for more information - * about listeners and possible status propagation to other entities. - * - * @param dp the domain participant to create the Publisher with. - * @param qos a collection of QosPolicy settings for the new Publisher. In case - * these settings are not self consistent, no Publisher is created. - * @param listener the publisher listener - * @param mask the mask of events notified to the listener - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - * @throws dds::core::InconsistentPolicyError - * The parameter qos contains conflicting QosPolicy settings. - */ - OMG_DDS_API Publisher( - const dds::domain::DomainParticipant& dp, - const qos::PublisherQos& qos, - PublisherListener* listener = NULL, - const dds::core::status::StatusMask& mask = dds::core::status::StatusMask::none()); - - /** @cond */ - virtual OMG_DDS_API ~Publisher(); - /** @endcond */ - - //========================================================================== - - /** - * Gets the PublisherQos setting for this instance. - * - * @return the qos - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - OMG_DDS_API const qos::PublisherQos& qos() const; - - - /** - * Sets the PublisherQos setting for this instance. - * - * @param qos the qos - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - OMG_DDS_API void qos( - const qos::PublisherQos& qos); - - /** @copydoc dds::pub::Publisher::qos(const dds::pub::qos::PublisherQos& qos) */ - OMG_DDS_API Publisher& operator <<( - const qos::PublisherQos& qos); - - /** @copydoc dds::pub::Publisher::qos() */ - OMG_DDS_API Publisher& operator >>( - qos::PublisherQos& qos); - - /** - * Sets the default DataWriterQos of the Publisher. - * - * This operation sets the default SubscriberQos of the Publisher which - * is used for newly created Subscriber objects, when no QoS is provided. - * - * This operation checks if the DataWriterQos is self consistent. If it is not, the - * operation has no effect and throws dds::core::InconsistentPolicyError. - * - * The values set by this operation are returned by dds::pub::Publisher::default_datawriter_qos(). - * - * @param qos the default DataWriterQos - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::UnsupportedError - * One or more of the selected QosPolicy values are - * currently not supported by OpenSplice. - * @throws dds::core::InconsistentPolicyError - * The parameter qos contains conflicting QosPolicy settings, - * e.g. a history depth that is higher than the specified resource limits. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - OMG_DDS_API Publisher& default_datawriter_qos( - const qos::DataWriterQos& qos); - - /** - * Gets the default DataWriterQos of the Publisher. - * - * This operation gets an object with the default DataWriter QosPolicy settings of - * the Publisher (that is the DataWriterQos) which is used for newly - * created DataWriter objects, in case no QoS was provided during the creation. - * - * The values retrieved by this operation match the set of values specified on the last - * successful call to - * dds::pub::Publisher::default_datawriter_qos(const dds::pub::qos::DataWriterQos& qos), - * or, if the call was never made, the @ref anchor_dds_pub_datawriter_qos_defaults "default" values. - * - * @return the default DataWriterQos - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - OMG_DDS_API qos::DataWriterQos default_datawriter_qos() const; - - //========================================================================== - - /** - * Register a listener with the Publisher. - * - * The notifications received by the listener depend on the - * status mask with which it was registered. - * - * Listener un-registration is performed by setting the listener to NULL. - * - * See also @ref DCPS_Modules_Infrastructure_Listener "listener information". - * - * @param plistener the listener - * @param mask the mask defining the events for which the listener - * will be notified. - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::UnsupportedError - * A status was selected that cannot be supported because - * the infrastructure does not maintain the required connectivity information. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - OMG_DDS_API void listener( - Listener* plistener, - const dds::core::status::StatusMask& mask); - - /** - * Get the listener of this Publisher. - * - * See also @ref DCPS_Modules_Infrastructure_Listener "listener information". - * - * @return the listener - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - */ - OMG_DDS_API Listener* listener() const; - - //========================================================================== - - /** - * This operation blocks the calling thread until either all data written - * by the reliable DataWriter entities is acknowledged by all matched - * reliable DataReader entities, or else the duration specified by the - * timeout parameter elapses, whichever happens first. - * - * Data is acknowledged by the local infrastructure when it does not need to be stored - * in its DataWriter’s local history. When a locally-connected subscription (including - * the networking service) has no more resources to store incoming samples it will start - * to reject these samples, resulting in their source DataWriters to store them - * temporarily in their own local history to be retransmitted at a later moment in time.
    - * In such scenarios, the wait_for_acknowledgments operation will block until all - * contained DataWriters have retransmitted their entire history, which is therefore - * effectively empty, or until the max_wait timeout expires, whichever happens first. - * In the latter case it will throw dds::core::TimeoutError. - * - * - * Be aware that in case the operation returns normally, the data has only been - * acknowledged by the local infrastructure: it does not mean all remote subscriptions - * have already received the data. However, delivering the data to remote nodes is then - * the sole responsibility of the networking service: even when the publishing - * application would terminate, all data that has not yet been received may be - * considered ‘on-route’ and will therefore eventually arrive (unless the networking - * service itself will crash). In contrast, if a DataWriter would still have data in it’s - * local history buffer when it terminates, this data is considered ‘lost’. - * - * - * This operation is intended to be used only if one or more of the contained - * DataWriters has its ReliabilityQosPolicyKind set to RELIABLE. - * Otherwise the operation will return immediately, since best-effort DataWriters will - * never store rejected samples in their local history: - * they will just drop them and continue business as usual. - * - * @param timeout the time out duration - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::TimeoutError - * Not all data is acknowledged before timeout elapsed. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - OMG_DDS_API void wait_for_acknowledgments( - const dds::core::Duration& timeout); - - //========================================================================== - - /** - * Return the DomainParticipant that owns this Publisher. - * - * @return the DomainParticipant - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - */ - OMG_DDS_API const dds::domain::DomainParticipant& participant() const; - - const dds::domain::DomainParticipant* participant_; - -}; - -} //namespace pub -} //namespace dds - -#endif //OMG_DDS_PUB_PUBLISHER_HPP_ diff --git a/include/dds/pub/PublisherListener.hpp b/include/dds/pub/PublisherListener.hpp deleted file mode 100644 index 271c9455358..00000000000 --- a/include/dds/pub/PublisherListener.hpp +++ /dev/null @@ -1,157 +0,0 @@ -/* - * Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_PUB_PUBLISHER_LISTENER_HPP_ -#define OMG_DDS_PUB_PUBLISHER_LISTENER_HPP_ - -// TODO Remove when PSM DDS Listeners are ready to be used. -#include - -// TODO uncomment when PSM DDS Listeners are ready to be used. -//#include - -namespace dds { -namespace pub { - -class PublisherListener; -class NoOpPublisherListener; - -/** - * @brief - * Publisher events Listener - * - * Since a Publisher is an Entity, it has the ability to have a Listener - * associated with it. In this case, the associated Listener should be of type - * PublisherListener. This interface must be implemented by the - * application. A user-defined class must be provided by the application which must - * extend from the PublisherListener class. - * - * - * All operations for this interface must be implemented in the user-defined class, it is - * up to the application whether an operation is empty or contains some functionality. - * - * - * The PublisherListener provides a generic mechanism (actually a - * callback function) for the Data Distribution Service to notify the application of - * relevant asynchronous status change events, such as a missed deadline, violation of - * a QosPolicy setting, etc. The PublisherListener is related to - * changes in communication status StatusConditions. - * - * @code{.cpp} - * // Application example listener - * class ExampleListener : - * public virtual dds::pub::PublisherListener - * { - * public: - * virtual void on_offered_deadline_missed ( - * dds::pub::AnyDataWriter& writer, - * const dds::core::status::OfferedDeadlineMissedStatus& status) - * { - * std::cout << "on_offered_deadline_missed" << std::endl; - * } - * - * virtual void on_offered_incompatible_qos ( - * dds::pub::AnyDataWriter& writer, - * const dds::core::status::OfferedIncompatibleQosStatus& status) - * { - * std::cout << "on_offered_incompatible_qos" << std::endl; - * } - * - * virtual void on_liveliness_lost ( - * dds::pub::AnyDataWriter& writer, - * const dds::core::status::LivelinessLostStatus& status) - * { - * std::cout << "on_liveliness_lost" << std::endl; - * } - * - * virtual void on_publication_matched ( - * dds::pub::AnyDataWriter& writer, - * const dds::core::status::PublicationMatchedStatus& status) - * { - * std::cout << "on_publication_matched" << std::endl; - * } - * }; - * - * // Create Publisher with the listener - * dds::domain::DomainParticipant participant(org::opensplice::domain::default_id()); - * dds::pub::Publisher publisher(participant, - * participant.default_publisher_qos(), - * new ExampleListener(), - * dds::core::status::StatusMask::all()); - * - * @endcode - * - * @see @ref DCPS_Modules_Publisher "Publisher" - * @see @ref DCPS_Modules_Infrastructure_Listener "Listener information" - */ -// TODO Uncomment when PSM listeners are implemented. -//class OMG_DDS_API PublisherListener : public virtual AnyDataWriterListener -// TODO Remove the PSM listeners are implemented. -class PublisherListener : public eprosima::fastdds::dds::PublisherListener -{ -public: - - /** @cond */ - virtual ~PublisherListener() - { - } - - /** @endcond */ -}; - -/** - * @brief - * Publisher events Listener - * - * This listener is just like PublisherListener, except - * that the application doesn't have to implement all operations. - * - * @code{.cpp} - * class ExampleListener : public virtual dds::pub::NoOpPublisherListener - * { - * // Not necessary to implement any Listener operations. - * }; - * @endcode - * - * @see dds::pub::PublisherListener - */ - -// TODO Uncomment when PSM DDS listeners are ready to be used -/* - class OMG_DDS_API NoOpPublisherListener : - public virtual PublisherListener, - public virtual NoOpAnyDataWriterListener - */ -// TODO Remove the PSM listeners are implemented. -class NoOpPublisherListener : public virtual PublisherListener -{ -public: - - /** @cond */ - virtual ~NoOpPublisherListener() - { - } - - /** @endcond */ -}; - -} //namespace pub -} //namespace dds - -#endif //OMG_DDS_PUB_PUBLISHER_LISTENER_HPP_ diff --git a/include/dds/pub/detail/AnyDataWriter.hpp b/include/dds/pub/detail/AnyDataWriter.hpp deleted file mode 100644 index 1a992ebd2d2..00000000000 --- a/include/dds/pub/detail/AnyDataWriter.hpp +++ /dev/null @@ -1,41 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_PUB_DETAIL_ANYDATAWRITER_HPP_ -#define EPROSIMA_DDS_PUB_DETAIL_ANYDATAWRITER_HPP_ - -//TODO Remove this include when AnyDataWriter is implemented. -#include - -/** - * @cond - * Ignore this file in the API - */ - -namespace dds { -namespace pub { -namespace detail { - -using AnyDataWriter = eprosima::fastdds::dds::DataWriter; - -} //namespace detail -} //namespace pub -} //namespace dds - -/** @endcond */ - -#endif //EPROSIMA_DDS_PUB_DETAIL_ANYDATAWRITER_HPP_ diff --git a/include/dds/pub/detail/DataWriter.hpp b/include/dds/pub/detail/DataWriter.hpp deleted file mode 100644 index 18fae527578..00000000000 --- a/include/dds/pub/detail/DataWriter.hpp +++ /dev/null @@ -1,41 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_PUB_DETAIL_DATA_WRITER_HPP_ -#define EPROSIMA_DDS_PUB_DETAIL_DATA_WRITER_HPP_ - -#include - -/** - * @cond - * Ignore this file in the API - */ - -namespace dds { -namespace pub { -namespace detail { - -using DataWriter = eprosima::fastdds::dds::DataWriter; - -} //namespace detail -} //namespace pub -} //namespace dds - -/** @endcond */ - - -#endif //EPROSIMA_DDS_PUB_DETAIL_DATA_WRITER_HPP_ diff --git a/include/dds/pub/detail/Publisher.hpp b/include/dds/pub/detail/Publisher.hpp deleted file mode 100644 index 1ebe827764e..00000000000 --- a/include/dds/pub/detail/Publisher.hpp +++ /dev/null @@ -1,48 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_PUB_DETAIL_PUBLISHER_HPP_ -#define EPROSIMA_DDS_PUB_DETAIL_PUBLISHER_HPP_ - -#include - -/** - * @cond - * Ignore this file in the API - */ - -namespace eprosima { -namespace fastdds { -namespace dds { -class Publisher; -} -} -} - -namespace dds { -namespace pub { -namespace detail { - -using Publisher = eprosima::fastdds::dds::Publisher; - -} //namespace detail -} //namespace pub -} //namespace dds - -/** @endcond */ - -#endif //EPROSIMA_DDS_PUB_DETAIL_PUBLISHER_HPP_ diff --git a/include/dds/pub/qos/DataWriterQos.hpp b/include/dds/pub/qos/DataWriterQos.hpp deleted file mode 100644 index 857c43e8284..00000000000 --- a/include/dds/pub/qos/DataWriterQos.hpp +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_QOS_DATA_WRITER_QOS_HPP_ -#define OMG_DDS_QOS_DATA_WRITER_QOS_HPP_ - -#include - -namespace dds { -namespace pub { -namespace qos { - -typedef dds::pub::qos::detail::DataWriterQos DataWriterQos; - -} //namespace qos -} //namespace pub -} //namespace dds - -#endif //OMG_DDS_QOS_DATA_WRITER_QOS_HPP_ diff --git a/include/dds/pub/qos/PublisherQos.hpp b/include/dds/pub/qos/PublisherQos.hpp deleted file mode 100644 index adc2384054d..00000000000 --- a/include/dds/pub/qos/PublisherQos.hpp +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_QOS_PUBLISER_QOS_HPP_ -#define OMG_DDS_QOS_PUBLISER_QOS_HPP_ - -#include - -namespace dds { -namespace pub { -namespace qos { - -typedef dds::pub::qos::detail::PublisherQos PublisherQos; - -} //namespace qos -} //namespace pub -} //namespace dds - -#endif //OMG_DDS_QOS_PUBLISER_QOS_HPP_ diff --git a/include/dds/pub/qos/detail/DataWriterQos.hpp b/include/dds/pub/qos/detail/DataWriterQos.hpp deleted file mode 100644 index 7fe983c50b3..00000000000 --- a/include/dds/pub/qos/detail/DataWriterQos.hpp +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_PUB_QOS_DETAIL_DATAWRITER_QOS_HPP_ -#define EPROSIMA_DDS_PUB_QOS_DETAIL_DATAWRITER_QOS_HPP_ - -#include - -namespace dds { -namespace pub { -namespace qos { -namespace detail { - -using DataWriterQos = eprosima::fastdds::dds::DataWriterQos; - -} //namespace detail -} //namespace qos -} //namespace pub -} //namespace dds - -#endif //EPROSIMA_DDS_PUB_QOS_DETAIL_DATAWRITER_QOS_HPP_ diff --git a/include/dds/pub/qos/detail/PublisherQos.hpp b/include/dds/pub/qos/detail/PublisherQos.hpp deleted file mode 100644 index 666b871109d..00000000000 --- a/include/dds/pub/qos/detail/PublisherQos.hpp +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_PUB_QOS_DETAIL_PUBLISER_QOS_HPP_ -#define EPROSIMA_DDS_PUB_QOS_DETAIL_PUBLISER_QOS_HPP_ - -#include - -namespace dds { -namespace pub { -namespace qos { -namespace detail { - -using PublisherQos = eprosima::fastdds::dds::PublisherQos; - -} //namespace detail -} //namespace qos -} //namespace pub -} //namespace detail - -#endif //EPROSIMA_DDS_PUB_QOS_DETAIL_PUBLISER_QOS_HPP_ diff --git a/include/dds/sub/DataReader.hpp b/include/dds/sub/DataReader.hpp deleted file mode 100644 index 0ef7bb4e1d5..00000000000 --- a/include/dds/sub/DataReader.hpp +++ /dev/null @@ -1,217 +0,0 @@ -/* - * Copyright 2020, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_SUB_DATAREADER_HPP_ -#define OMG_DDS_SUB_DATAREADER_HPP_ - -#include - -#include -#include -#include - -namespace dds { -namespace sub { - -class DataReaderListener; - -//TODO: [ILG] Decide if we need to templatize the DataReader and derive from a AnyDataReader - -/** - * @brief - * A DataReader allows the application to declare the data it wishes to receive. - * - * @see @ref DCPS_Modules_Datareader "Datareader" - */ -class DataReader : public dds::core::TEntity -{ -public: - - /** - * Local convenience typedef for dds::pub::DataReaderListener. - */ - typedef DataReaderListener Listener; - - OMG_DDS_REF_TYPE_PROTECTED_DC( - DataReader, - dds::core::TEntity, - detail::DataReader) - - OMG_DDS_IMPLICIT_REF_BASE( - DataReader) - - /** - * Create a new DataReader. - * - * The DataReader will be created with the QoS values specified on the last - * successful call to @link dds::sub::Subscriber::default_DataReader_qos(const ::dds::sub::qos::DataReaderQos& qos) - * sub.default_DataReader_qos(qos) @endlink or, if the call was never made, the - * @ref anchor_dds_sub_DataReader_qos_defaults "default" values. - * - * @param sub the subscriber - * @param topic the topic the DataReader will be listening. - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - OMG_DDS_API DataReader( - const dds::sub::Subscriber& sub, - const dds::topic::Topic& topic); - - /** - * Create a new DataReader. - * - * The DataReader will be created with the given QosPolicy settings and if - * applicable, attaches the optionally specified DataReaderListener to it. - * - * See @ref DCPS_Modules_Infrastructure_Listener "listener" for more information - * about listeners and possible status propagation to other entities. - * - * @param sub the subscriber to create the DataReader with. - * @param topic the topic the DataReader will be listening. - * @param qos a collection of QosPolicy settings for the new DataReader. In case - * these settings are not self consistent, no DataReader is created. - * @param listener the DataReader listener - * @param mask the mask of events notified to the listener - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - * @throws dds::core::InconsistentPolicyError - * The parameter qos contains conflicting QosPolicy settings. - */ - OMG_DDS_API DataReader( - const dds::sub::Subscriber& sub, - const dds::topic::Topic& topic, - const qos::DataReaderQos& qos, - DataReaderListener* listener = NULL, - const dds::core::status::StatusMask& mask = dds::core::status::StatusMask::none()); - - /** @cond */ - virtual OMG_DDS_API ~DataReader(); - /** @endcond */ - - //========================================================================== - - /** - * Gets the DataReaderQos setting for this instance. - * - * @return the qos - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - OMG_DDS_API const qos::DataReaderQos& qos() const; - - - /** - * Sets the DataReaderQos setting for this instance. - * - * @param qos the qos - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - OMG_DDS_API void qos( - const qos::DataReaderQos& qos); - - /** @copydoc dds::pub::DataReader::qos(const dds::pub::qos::DataReaderQos& qos) */ - OMG_DDS_API DataReader& operator <<( - const qos::DataReaderQos& qos); - - /** @copydoc dds::pub::DataReader::qos() */ - OMG_DDS_API DataReader& operator >>( - qos::DataReaderQos& qos); - - //========================================================================== - - /** - * Register a listener with the DataReader. - * - * The notifications received by the listener depend on the - * status mask with which it was registered. - * - * Listener un-registration is performed by setting the listener to NULL. - * - * See also @ref DCPS_Modules_Infrastructure_Listener "listener information". - * - * @param plistener the listener - * @param mask the mask defining the events for which the listener - * will be notified. - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::UnsupportedError - * A status was selected that cannot be supported because - * the infrastructure does not maintain the required connectivity information. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - OMG_DDS_API void listener( - Listener* plistener, - const dds::core::status::StatusMask& mask); - - /** - * Get the listener of this DataReader. - * - * See also @ref DCPS_Modules_Infrastructure_Listener "listener information". - * - * @return the listener - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - */ - OMG_DDS_API Listener* listener() const; - - /** - * Return the Subscriber that owns this DataReader. - * - * @return the Subscriber - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - */ - OMG_DDS_API const dds::sub::Subscriber& subscriber() const; - - dds::sub::Subscriber* subscriber_; - -}; - -} //namespace sub -} //namespace dds - -#endif //OMG_DDS_SUB_DATAREADER_HPP_ diff --git a/include/dds/sub/DataReaderListener.hpp b/include/dds/sub/DataReaderListener.hpp deleted file mode 100644 index a4a7f95728c..00000000000 --- a/include/dds/sub/DataReaderListener.hpp +++ /dev/null @@ -1,107 +0,0 @@ -/* - * Copyright 2020, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_SUB_DATAREADER_LISTENER_HPP_ -#define OMG_DDS_SUB_DATAREADER_LISTENER_HPP_ - -// TODO Remove when PSM DDS Listeners are ready to be used. -#include - -// TODO uncomment when PSM DDS Listeners are ready to be used. -//#include - -namespace dds { -namespace sub { - -class SubscriberListener; -class NoOpSubscriberListener; - -/** - * @brief - * DataReader events Listener - * - * Since a DataReader is an Entity, it has the ability to have a Listener - * associated with it. In this case, the associated Listener should be of type - * DataReaderListener. This interface must be implemented by the - * application. A user-defined class must be provided by the application which must - * extend from the DataReaderListener class. - * - * - * All operations for this interface must be implemented in the user-defined class, it is - * up to the application whether an operation is empty or contains some functionality. - * - * - * The DataReaderListener provides a generic mechanism (actually a - * callback function) for the Data Distribution Service to notify the application of - * relevant asynchronous status change events, such as a missed deadline, violation of - * a QosPolicy setting, etc. The DataReaderListener is related to - * changes in communication status StatusConditions. - */ -// TODO Uncomment when PSM listeners are implemented. -//class OMG_DDS_API DataReaderListener : public virtual AnyDataReaderListener -// TODO Remove the PSM listeners are implemented. -class DataReaderListener : public eprosima::fastdds::dds::DataReaderListener -{ -public: - - /** @cond */ - virtual ~DataReaderListener() - { - } - - /** @endcond */ -}; - -/** - * @brief - * DataReader events Listener - * - * This listener is just like DataReaderListener, except - * that the application doesn't have to implement all operations. - * - * @code{.cpp} - * class ExampleListener : public virtual dds::sub::NoOpDataReaderListener - * { - * // Not necessary to implement any Listener operations. - * }; - * @endcode - * - * @see dds::pub::DataReaderListener - */ - -// TODO Uncomment when PSM DDS listeners are ready to be used -/* - class OMG_DDS_API NoOpDataReaderListener : - public virtual DataReaderListener, - public virtual NoOpAnyDataReaderListener - */ -// TODO Remove the PSM listeners are implemented. -class NoOpDataReaderListener : public virtual DataReaderListener -{ -public: - - /** @cond */ - virtual ~NoOpDataReaderListener() - { - } - - /** @endcond */ -}; - -} //namespace sub -} //namespace dds - -#endif //OMG_DDS_SUB_DATAREADER_LISTENER_HPP_ diff --git a/include/dds/sub/Subscriber.hpp b/include/dds/sub/Subscriber.hpp deleted file mode 100644 index 38377d736a2..00000000000 --- a/include/dds/sub/Subscriber.hpp +++ /dev/null @@ -1,268 +0,0 @@ -/* - * Copyright 2020, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_SUB_SUBSCRIBER_HPP_ -#define OMG_DDS_SUB_SUBSCRIBER_HPP_ - -#include - -#include -#include -#include -#include - -namespace dds { -namespace sub { - -class SubscriberListener; - -/** - * @brief - * The Subscriber acts on the behalf of one or several DataReader objects - * that belong to it. - * - * @see @ref DCPS_Modules_Subscriber "Subscriber" - */ -class Subscriber : public dds::core::TEntity -{ -public: - - /** - * Local convenience typedef for dds::pub::SubscriberListener. - */ - typedef SubscriberListener Listener; - - OMG_DDS_REF_TYPE_PROTECTED_DC( - Subscriber, - dds::core::TEntity, - detail::Subscriber) - - OMG_DDS_IMPLICIT_REF_BASE( - Subscriber) - - /** - * Create a new Subscriber. - * - * The Subscriber will be created with the QoS values specified on the last - * successful call to @link dds::domain::DomainParticipant::default_subscriber_qos(const ::dds::pub::qos::SubscriberQos& qos) - * dp.default_subscriber_qos(qos) @endlink or, if the call was never made, the - * @ref anchor_dds_pub_subscriber_qos_defaults "default" values. - * - * @param dp the domain participant - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - OMG_DDS_API Subscriber( - const dds::domain::DomainParticipant& dp); - - /** - * Create a new Subscriber. - * - * The Subscriber will be created with the given QosPolicy settings and if - * applicable, attaches the optionally specified SubscriberListener to it. - * - * See @ref DCPS_Modules_Infrastructure_Listener "listener" for more information - * about listeners and possible status propagation to other entities. - * - * @param dp the domain participant to create the Subscriber with. - * @param qos a collection of QosPolicy settings for the new Subscriber. In case - * these settings are not self consistent, no Subscriber is created. - * @param listener the subscriber listener - * @param mask the mask of events notified to the listener - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - * @throws dds::core::InconsistentPolicyError - * The parameter qos contains conflicting QosPolicy settings. - */ - OMG_DDS_API Subscriber( - const dds::domain::DomainParticipant& dp, - const qos::SubscriberQos& qos, - SubscriberListener* listener = NULL, - const dds::core::status::StatusMask& mask = dds::core::status::StatusMask::none()); - - /** @cond */ - virtual OMG_DDS_API ~Subscriber(); - /** @endcond */ - - //========================================================================== - - /** - * Gets the SubscriberQos setting for this instance. - * - * @return the qos - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - OMG_DDS_API const qos::SubscriberQos& qos() const; - - - /** - * Sets the SubscriberQos setting for this instance. - * - * @param qos the qos - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - OMG_DDS_API void qos( - const qos::SubscriberQos& qos); - - /** @copydoc dds::pub::Subscriber::qos(const dds::pub::qos::SubscriberQos& qos) */ - OMG_DDS_API Subscriber& operator <<( - const qos::SubscriberQos& qos); - - /** @copydoc dds::pub::Subscriber::qos() */ - OMG_DDS_API Subscriber& operator >>( - qos::SubscriberQos& qos); - - /** - * Sets the default DataWriterQos of the Subscriber. - * - * This operation sets the default SubscriberQos of the Subscriber which - * is used for newly created Subscriber objects, when no QoS is provided. - * - * This operation checks if the DataReaderQos is self consistent. If it is not, the - * operation has no effect and throws dds::core::InconsistentPolicyError. - * - * The values set by this operation are returned by dds::pub::Subscriber::default_datareader_qos(). - * - * @param qos the default DataReaderQos - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::UnsupportedError - * One or more of the selected QosPolicy values are - * currently not supported. - * @throws dds::core::InconsistentPolicyError - * The parameter qos contains conflicting QosPolicy settings, - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - OMG_DDS_API Subscriber& default_datareader_qos( - const qos::DataReaderQos& qos); - - /** - * Gets the default DataReaderQos of the Subscriber. - * - * This operation gets an object with the default DataReader QosPolicy settings of - * the Subscriber (that is the DataReaderQos) which is used for newly - * created DataReader objects, in case no QoS was provided during the creation. - * - * The values retrieved by this operation match the set of values specified on the last - * successful call to - * dds::pub::Subscriber::default_datareader_qos(const dds::pub::qos::DataReaderQos& qos), - * or, if the call was never made, the @ref anchor_dds_pub_datareader_qos_defaults "default" values. - * - * @return the default DataReaderQos - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - OMG_DDS_API qos::DataReaderQos default_datareader_qos() const; - - //========================================================================== - - /** - * Register a listener with the Subscriber. - * - * The notifications received by the listener depend on the - * status mask with which it was registered. - * - * Listener un-registration is performed by setting the listener to NULL. - * - * See also @ref DCPS_Modules_Infrastructure_Listener "listener information". - * - * @param plistener the listener - * @param mask the mask defining the events for which the listener - * will be notified. - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - * @throws dds::core::UnsupportedError - * A status was selected that cannot be supported because - * the infrastructure does not maintain the required connectivity information. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - OMG_DDS_API void listener( - Listener* plistener, - const dds::core::status::StatusMask& mask); - - /** - * Get the listener of this Subscriber. - * - * See also @ref DCPS_Modules_Infrastructure_Listener "listener information". - * - * @return the listener - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - */ - OMG_DDS_API Listener* listener() const; - - /** - * Return the DomainParticipant that owns this Subscriber. - * - * @return the DomainParticipant - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::NullReferenceError - * The entity was not properly created and references to dds::core::null. - * @throws dds::core::AlreadyClosedError - * The entity has already been closed. - */ - OMG_DDS_API const dds::domain::DomainParticipant& participant() const; - - const dds::domain::DomainParticipant* participant_; - -}; - -} //namespace sub -} //namespace dds - -#endif //OMG_DDS_SUB_SUBSCRIBER_HPP_ diff --git a/include/dds/sub/SubscriberListener.hpp b/include/dds/sub/SubscriberListener.hpp deleted file mode 100644 index 2bea6ddca13..00000000000 --- a/include/dds/sub/SubscriberListener.hpp +++ /dev/null @@ -1,154 +0,0 @@ -/* - * Copyright 2020, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_SUB_SUBSCRIBER_LISTENER_HPP_ -#define OMG_DDS_SUB_SUBSCRIBER_LISTENER_HPP_ - -// TODO Remove when PSM DDS Listeners are ready to be used. -#include - -// TODO uncomment when PSM DDS Listeners are ready to be used. -//#include - -namespace dds { -namespace sub { - -class SubscriberListener; -class NoOpSubscriberListener; - -/** - * @brief - * Subscriber events Listener - * - * Since a Subscriber is an Entity, it has the ability to have a Listener - * associated with it. In this case, the associated Listener should be of type - * SubscriberListener. This interface must be implemented by the - * application. A user-defined class must be provided by the application which must - * extend from the SubscriberListener class. - * - * - * All operations for this interface must be implemented in the user-defined class, it is - * up to the application whether an operation is empty or contains some functionality. - * - * - * The SubscriberListener provides a generic mechanism (actually a - * callback function) for the Data Distribution Service to notify the application of - * relevant asynchronous status change events, such as a missed deadline, violation of - * a QosPolicy setting, etc. The SubscriberListener is related to - * changes in communication status StatusConditions. - * - * @code{.cpp} - * // Application example listener - * class ExampleListener : - * public virtual dds::sub::SubscriberListener - * { - * public: - * virtual void on_new_data_message ( - * dds::pub::AnyDataReader& reader, - * const dds::core::status::NewDataMessageStatus& status) - * { - * std::cout << "on_new_data_message" << std::endl; - * } - * - * virtual void on_subscription_matched ( - * dds::pub::AnyDataReader& reader, - * const dds::core::status::SubscriptionMatchedStatus& status) - * { - * std::cout << "on_subscription_matched" << std::endl; - * } - * - * virtual void on_requested_deadline_missed ( - * dds::pub::AnyDataReader& reader, - * const dds::core::status::RequestedDeadlineMissedStatus& status) - * { - * std::cout << "on_requested_deadline_missed" << std::endl; - * } - * - * virtual void on_liveliness_changed ( - * dds::pub::AnyDataReader& reader, - * const dds::core::status::LivelinessChangedStatus& status) - * { - * std::cout << "on_liveliness_changed" << std::endl; - * } - * }; - * - * // Create Publisher with the listener - * dds::domain::DomainParticipant participant(org::opensplice::domain::default_id()); - * dds::sub::Subscriber subscriber(participant, - * participant.default_Subscriber_qos(), - * new ExampleListener(), - * dds::core::status::StatusMask::all()); - * - * @endcode - * - * @see @ref DCPS_Modules_Subscriber "Subscriber" - * @see @ref DCPS_Modules_Infrastructure_Listener "Listener information" - */ -// TODO Uncomment when PSM listeners are implemented. -//class OMG_DDS_API SubscriberListener : public virtual AnyDataReaderListener -// TODO Remove the PSM listeners are implemented. -class SubscriberListener : public eprosima::fastdds::dds::SubscriberListener -{ -public: - - /** @cond */ - virtual ~SubscriberListener() - { - } - - /** @endcond */ -}; - -/** - * @brief - * Subscriber events Listener - * - * This listener is just like SubscriberListener, except - * that the application doesn't have to implement all operations. - * - * @code{.cpp} - * class ExampleListener : public virtual dds::sub::NoOpSubscriberListener - * { - * // Not necessary to implement any Listener operations. - * }; - * @endcode - * - * @see dds::pub::SubscriberListener - */ - -// TODO Uncomment when PSM DDS listeners are ready to be used -/* - class OMG_DDS_API NoOpSubscriberListener : - public virtual SubscriberListener, - public virtual NoOpAnySubscriberListener - */ -// TODO Remove the PSM listeners are implemented. -class NoOpSubscriberListener : public virtual SubscriberListener -{ -public: - - /** @cond */ - virtual ~NoOpSubscriberListener() - { - } - - /** @endcond */ -}; - -} //namespace sub -} //namespace dds - -#endif //OMG_DDS_SUB_SUBSCRIBER_LISTENER_HPP_ diff --git a/include/dds/sub/detail/DataReader.hpp b/include/dds/sub/detail/DataReader.hpp deleted file mode 100644 index d8ca18c75a2..00000000000 --- a/include/dds/sub/detail/DataReader.hpp +++ /dev/null @@ -1,40 +0,0 @@ -/* - * Copyright 2020, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_SUB_DETAIL_DATAREADER_HPP_ -#define EPROSIMA_DDS_SUB_DETAIL_DATAREADER_HPP_ - -#include - -/** - * @cond - * Ignore this file in the API - */ - -namespace dds { -namespace sub { -namespace detail { - -using DataReader = eprosima::fastdds::dds::DataReader; - -} //namespace detail -} //namespace sub -} //namespace dds - -/** @endcond */ - -#endif //EPROSIMA_DDS_SUB_DETAIL_DATAREADER_HPP_ diff --git a/include/dds/sub/detail/Subscriber.hpp b/include/dds/sub/detail/Subscriber.hpp deleted file mode 100644 index 9a7a7fbb0e9..00000000000 --- a/include/dds/sub/detail/Subscriber.hpp +++ /dev/null @@ -1,48 +0,0 @@ -/* - * Copyright 2020, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_SUB_DETAIL_SUBSCRIBER_HPP_ -#define EPROSIMA_DDS_SUB_DETAIL_SUBSCRIBER_HPP_ - -#include - -/** - * @cond - * Ignore this file in the API - */ - -namespace eprosima { -namespace fastdds { -namespace dds { -class Subscriber; -} -} -} - -namespace dds { -namespace sub { -namespace detail { - -using Subscriber = eprosima::fastdds::dds::Subscriber; - -} //namespace detail -} //namespace sub -} //namespace dds - -/** @endcond */ - -#endif //EPROSIMA_DDS_SUB_DETAIL_SUBSCRIBER_HPP_ diff --git a/include/dds/sub/qos/DataReaderQos.hpp b/include/dds/sub/qos/DataReaderQos.hpp deleted file mode 100644 index 1c601ea3d92..00000000000 --- a/include/dds/sub/qos/DataReaderQos.hpp +++ /dev/null @@ -1,32 +0,0 @@ -/* - * Copyright 2020, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_QOS_DATA_READER_QOS_HPP_ -#define OMG_DDS_QOS_DATA_READER_QOS_HPP_ - -#include - -namespace dds { -namespace sub { -namespace qos { - -typedef detail::DataReaderQos DataReaderQos; - -} //namespace qos -} //namespace sub -} //namespace dds - -#endif //OMG_DDS_QOS_DATA_READER_QOS_HPP_ diff --git a/include/dds/sub/qos/SubscriberQos.hpp b/include/dds/sub/qos/SubscriberQos.hpp deleted file mode 100644 index 350c8998b9e..00000000000 --- a/include/dds/sub/qos/SubscriberQos.hpp +++ /dev/null @@ -1,32 +0,0 @@ -/* - * Copyright 2020, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_QOS_SUBSCRIBER_QOS_HPP_ -#define OMG_DDS_QOS_SUBSCRIBER_QOS_HPP_ - -#include - -namespace dds { -namespace sub { -namespace qos { - -typedef dds::sub::qos::detail::SubscriberQos SubscriberQos; - -} //namespace qos -} //namespace sub -} //namespace dds - -#endif //OMG_DDS_QOS_SUBSCRIBER_QOS_HPP_ diff --git a/include/dds/sub/qos/detail/DataReaderQos.hpp b/include/dds/sub/qos/detail/DataReaderQos.hpp deleted file mode 100644 index e89b554ef86..00000000000 --- a/include/dds/sub/qos/detail/DataReaderQos.hpp +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright 2020, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_PUB_QOS_DETAIL_DATAREADER_QOS_HPP_ -#define EPROSIMA_DDS_PUB_QOS_DETAIL_DATAREADER_QOS_HPP_ - -#include - -namespace dds { -namespace sub { -namespace qos { -namespace detail { - -using DataReaderQos = eprosima::fastdds::dds::DataReaderQos; - -} //namespace detail -} //namespace qos -} //namespace sub -} //namespace dds - -#endif //EPROSIMA_DDS_PUB_QOS_DETAIL_DATAREADER_QOS_HPP_ diff --git a/include/dds/sub/qos/detail/SubscriberQos.hpp b/include/dds/sub/qos/detail/SubscriberQos.hpp deleted file mode 100644 index dd679721242..00000000000 --- a/include/dds/sub/qos/detail/SubscriberQos.hpp +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright 2020, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_SUB_QOS_DETAIL_SUBSCRIBER_QOS_HPP_ -#define EPROSIMA_DDS_SUB_QOS_DETAIL_SUBSCRIBER_QOS_HPP_ - -#include - -namespace dds { -namespace sub { -namespace qos { -namespace detail { - -using SubscriberQos = eprosima::fastdds::dds::SubscriberQos; - -} //namespace detail -} //namespace qos -} //namespace sub -} //namespace detail - -#endif //EPROSIMA_DDS_SUB_QOS_DETAIL_SUBSCRIBER_QOS_HPP_ diff --git a/include/dds/topic/Topic.hpp b/include/dds/topic/Topic.hpp deleted file mode 100644 index 068ef0643d9..00000000000 --- a/include/dds/topic/Topic.hpp +++ /dev/null @@ -1,111 +0,0 @@ -// Copyright 2020 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file Topic.hpp - */ - -#ifndef OMG_DDS_TOPIC_HPP_ -#define OMG_DDS_TOPIC_HPP_ - - -#include -#include -#include -#include - -namespace dds { -namespace topic { - -class TopicListener; - - -class Topic : public dds::core::TEntity -{ - friend class DomainParticipantImpl; - -public: - - OMG_DDS_REF_TYPE_PROTECTED_DC( - Topic, - dds::core::TEntity, - detail::Topic) - - OMG_DDS_IMPLICIT_REF_BASE( - Topic) - - /** - * Create a new Topic. - * - * The Topic will be created with the QoS values specified on the last - * successful call to @link dds::domain::DomainParticipant::default_topic_qos(const ::dds::pub::qos::TopicQos& qos) - * dp.default_topic_qos(qos) @endlink or, if the call was never made, the - * @ref anchor_dds_pub_topic_qos_defaults "default" values. - * - * @param dp the domain participant - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - */ - OMG_DDS_API Topic( - const dds::domain::DomainParticipant& dp, - const std::string& topic_name, - const std::string& type_name); - - /** - * Create a new Topic. - * - * The Topic will be created with the given QosPolicy settings and if - * applicable, attaches the optionally specified TopicListener to it. - * - * See @ref DCPS_Modules_Infrastructure_Listener "listener" for more information - * about listeners and possible status propagation to other entities. - * - * @param dp the domain participant to create the Topic with. - * @param qos a collection of QosPolicy settings for the new Topic. In case - * these settings are not self consistent, no Topic is created. - * @param listener the Topic listener - * @param mask the mask of events notified to the listener - * @throws dds::core::Error - * An internal error has occurred. - * @throws dds::core::OutOfResourcesError - * The Data Distribution Service ran out of resources to - * complete this operation. - * @throws dds::core::InconsistentPolicyError - * The parameter qos contains conflicting QosPolicy settings. - */ - OMG_DDS_API Topic( - const dds::domain::DomainParticipant& dp, - const std::string& topic_name, - const std::string& type_name, - const qos::TopicQos& qos, - TopicListener* listener = nullptr, - const dds::core::status::StatusMask& mask = dds::core::status::StatusMask::none()); - - /** @cond */ - virtual OMG_DDS_API ~Topic(); - /** @endcond */ - -private: - - dds::domain::DomainParticipant* participant_; - -}; - -} /* namespace topic */ -} /* namespace dds */ - -#endif /* OMG_DDS_TOPIC_HPP_ */ diff --git a/include/dds/topic/TopicListener.hpp b/include/dds/topic/TopicListener.hpp deleted file mode 100644 index e0a5d9ca663..00000000000 --- a/include/dds/topic/TopicListener.hpp +++ /dev/null @@ -1,107 +0,0 @@ -/* - * Copyright 2020, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_SUB_TOPIC_LISTENER_HPP_ -#define OMG_DDS_SUB_TOPIC_LISTENER_HPP_ - -// TODO Remove when PSM DDS Listeners are ready to be used. -#include - -// TODO uncomment when PSM DDS Listeners are ready to be used. -//#include - -namespace dds { -namespace topic { - -/** - * @brief - * Topic events Listener - * - * Since a Topic is an Entity, it has the ability to have a Listener - * associated with it. In this case, the associated Listener should be of type - * TopicListener. This interface must be implemented by the - * application. A user-defined class must be provided by the application which must - * extend from the TopicListener class. - * - * - * All operations for this interface must be implemented in the user-defined class, it is - * up to the application whether an operation is empty or contains some functionality. - * - * - * The TopicListener provides a generic mechanism (actually a - * callback function) for the Data Distribution Service to notify the application of - * relevant asynchronous status change events, such as a missed deadline, violation of - * a QosPolicy setting, etc. The TopicListener is related to - * changes in communication status StatusConditions. - * - * @see @ref DCPS_Modules_Topic "Topic" - * @see @ref DCPS_Modules_Infrastructure_Listener "Listener information" - */ -// TODO Uncomment when PSM listeners are implemented. -//class OMG_DDS_API TopicListener : public virtual AnyDataReaderListener -// TODO Remove the PSM listeners are implemented. -class TopicListener : public eprosima::fastdds::dds::TopicListener -{ -public: - - /** @cond */ - virtual ~TopicListener() - { - } - - /** @endcond */ -}; - -/** - * @brief - * Topic events Listener - * - * This listener is just like TopicListener, except - * that the application doesn't have to implement all operations. - * - * @code{.cpp} - * class ExampleListener : public virtual dds::pub::NoOpTopicListener - * { - * // Not necessary to implement any Listener operations. - * }; - * @endcode - * - * @see dds::pub::TopicListener - */ - -// TODO Uncomment when PSM DDS listeners are ready to be used -/* - class OMG_DDS_API NoOpTopicListener : - public virtual TopicListener, - public virtual NoOpAnyDataReaderListener - */ -// TODO Remove the PSM listeners are implemented. -class NoOpTopicListener : public virtual TopicListener -{ -public: - - /** @cond */ - virtual ~NoOpTopicListener() - { - } - - /** @endcond */ -}; - -} //namespace topic -} //namespace dds - -#endif //OMG_DDS_SUB_TOPIC_LISTENER_HPP_ diff --git a/include/dds/topic/detail/Topic.hpp b/include/dds/topic/detail/Topic.hpp deleted file mode 100644 index a2a606d1a3e..00000000000 --- a/include/dds/topic/detail/Topic.hpp +++ /dev/null @@ -1,40 +0,0 @@ -/* - * Copyright 2020, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_TOPIC_DETAIL_TOPIC_HPP_ -#define EPROSIMA_DDS_TOPIC_DETAIL_TOPIC_HPP_ - -#include - -/** - * @cond - * Ignore this file in the API - */ - -namespace dds { -namespace topic { -namespace detail { - -using Topic = eprosima::fastdds::dds::Topic; - -} //namespace detail -} //namespace topic -} //namespace dds - -/** @endcond */ - -#endif //EPROSIMA_DDS_TOPIC_DETAIL_TOPIC_HPP_ diff --git a/include/dds/topic/qos/TopicQos.hpp b/include/dds/topic/qos/TopicQos.hpp deleted file mode 100644 index d105d470709..00000000000 --- a/include/dds/topic/qos/TopicQos.hpp +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Copyright 2010, Object Management Group, Inc. - * Copyright 2010, PrismTech, Corp. - * Copyright 2010, Real-Time Innovations, Inc. - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef OMG_DDS_TOPIC_QOS_TOPIC_QOS_HPP_ -#define OMG_DDS_TOPIC_QOS_TOPIC_QOS_HPP_ - -#include - -namespace dds { -namespace topic { -namespace qos { - -typedef dds::topic::qos::detail::TopicQos TopicQos; - -} //namespace qos -} //namespace topic -} //namespace dds - - -#endif //OMG_DDS_TOPIC_QOS_TOPIC_QOS_HPP_ diff --git a/include/dds/topic/qos/detail/TopicQos.hpp b/include/dds/topic/qos/detail/TopicQos.hpp deleted file mode 100644 index 120c37714dd..00000000000 --- a/include/dds/topic/qos/detail/TopicQos.hpp +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright 2019, Proyectos y Sistemas de Mantenimiento SL (eProsima). - * - * Licensed 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 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -#ifndef EPROSIMA_DDS_TOPIC_QOS_DETAIL_TOPIC_QOS_HPP_ -#define EPROSIMA_DDS_TOPIC_QOS_DETAIL_TOPIC_QOS_HPP_ - -#include - -namespace dds { -namespace topic { -namespace qos { -namespace detail { - -using TopicQos = eprosima::fastdds::dds::TopicQos; - -} //namespace detail -} //namespace qos -} //namespace topic -} //namespace dds - -#endif //EPROSIMA_DDS_TOPIC_QOS_DETAIL_TOPIC_QOS_HPP_ diff --git a/include/fastdds/LibrarySettings.hpp b/include/fastdds/LibrarySettings.hpp new file mode 100644 index 00000000000..a84dd5eb96d --- /dev/null +++ b/include/fastdds/LibrarySettings.hpp @@ -0,0 +1,66 @@ +// Copyright 2024 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/** + * @file LibrarySettings.hpp + * + */ + +#ifndef _FASTDDS_LIBRARY_SETTINGS_HPP_ +#define _FASTDDS_LIBRARY_SETTINGS_HPP_ + +namespace eprosima { +namespace fastdds { + +enum IntraprocessDeliveryType +{ + INTRAPROCESS_OFF, + INTRAPROCESS_USER_DATA_ONLY, + INTRAPROCESS_FULL +}; + +/** + * Class LibraySettings, used by the user to define the Fast DDS library behaviour + * @ingroup FASTDDS_MODULE + */ +class LibrarySettings +{ +public: + + LibrarySettings() + { + } + + virtual ~LibrarySettings() + { + } + + bool operator ==( + const LibrarySettings& b) const + { + return (intraprocess_delivery == b.intraprocess_delivery); + } + + IntraprocessDeliveryType intraprocess_delivery = +#if HAVE_STRICT_REALTIME + INTRAPROCESS_OFF; +#else + INTRAPROCESS_FULL; +#endif // if HAVE_STRICT_REALTIME +}; + +} // namespace fastdds +} // namespace eprosima + +#endif /* _FASTDDS_LIBRARY_SETTINGS_HPP_ */ diff --git a/include/fastrtps/config.h.in b/include/fastdds/config.h.in similarity index 76% rename from include/fastrtps/config.h.in rename to include/fastdds/config.h.in index 9c380a933f9..8b3d118edfb 100644 --- a/include/fastrtps/config.h.in +++ b/include/fastdds/config.h.in @@ -12,13 +12,13 @@ // See the License for the specific language governing permissions and // limitations under the License. -#ifndef _FASTRTPS_CONFIG_H_ -#define _FASTRTPS_CONFIG_H_ +#ifndef _FASTDDS_CONFIG_H_ +#define _FASTDDS_CONFIG_H_ -#define FASTRTPS_VERSION_MAJOR @PROJECT_VERSION_MAJOR@ -#define FASTRTPS_VERSION_MINOR @PROJECT_VERSION_MINOR@ -#define FASTRTPS_VERSION_MICRO @PROJECT_VERSION_PATCH@ -#define FASTRTPS_VERSION_STR "@PROJECT_VERSION@" +#define FASTDDS_VERSION_MAJOR @PROJECT_VERSION_MAJOR@ +#define FASTDDS_VERSION_MINOR @PROJECT_VERSION_MINOR@ +#define FASTDDS_VERSION_MICRO @PROJECT_VERSION_PATCH@ +#define FASTDDS_VERSION_STR "@PROJECT_VERSION@" #define GEN_API_VER 2 @@ -85,7 +85,7 @@ // Log Info #ifndef FASTDDS_ENFORCE_LOG_INFO #cmakedefine FASTDDS_ENFORCE_LOG_INFO -#endif +#endif // ifndef FASTDDS_ENFORCE_LOG_INFO #ifndef HAVE_LOG_NO_INFO #define HAVE_LOG_NO_INFO @HAVE_LOG_NO_INFO@ #endif /* ifndef HAVE_LOG_NO_INFO */ @@ -105,29 +105,29 @@ // Deprecated macro #if __cplusplus >= 201402L -#define FASTRTPS_DEPRECATED(msg) [[ deprecated(msg) ]] +#define FASTDDS_DEPRECATED(msg) [[ deprecated(msg) ]] #elif defined(__GNUC__) || defined(__clang__) -#define FASTRTPS_DEPRECATED(msg) __attribute__ ((deprecated(msg))) +#define FASTDDS_DEPRECATED(msg) __attribute__ ((deprecated(msg))) #elif defined(_MSC_VER) -#define FASTRTPS_DEPRECATED(msg) __declspec(deprecated(msg)) +#define FASTDDS_DEPRECATED(msg) __declspec(deprecated(msg)) #else -#define FASTRTPS_DEPRECATED(msg) +#define FASTDDS_DEPRECATED(msg) #endif /* if __cplusplus >= 201402L */ // Deprecation with version #define FASTDDS_DEPRECATED_UNTIL(major, entity_name, msg) \ - static_assert(FASTRTPS_VERSION_MAJOR < major, #entity_name " reached deprecation version " #major); \ - FASTRTPS_DEPRECATED(#entity_name " has been deprecated and will be removed on major version " #major ". " msg) + static_assert(FASTDDS_VERSION_MAJOR < major, #entity_name " reached deprecation version " #major); \ + FASTDDS_DEPRECATED(#entity_name " has been deprecated and will be removed on major version " #major ". " msg) #define FASTDDS_TODO_BEFORE(major, minor, msg) \ - static_assert((FASTRTPS_VERSION_MAJOR < major) || \ - (FASTRTPS_VERSION_MAJOR == major && FASTRTPS_VERSION_MINOR < minor), \ + static_assert((FASTDDS_VERSION_MAJOR < major) || \ + (FASTDDS_VERSION_MAJOR == major && FASTDDS_VERSION_MINOR < minor), \ "TODO before version " #major "." #minor " : " #msg) #if FASTCDR_VERSION_MAJOR > 1 #define FASTDDS_SER_METHOD_DEPRECATED(major, entity_name, msg) FASTDDS_DEPRECATED_UNTIL(major, entity_name, msg) #else #define FASTDDS_SER_METHOD_DEPRECATED(major, entity_name, msg) -#endif +#endif // if FASTCDR_VERSION_MAJOR > 1 -#endif // _FASTRTPS_CONFIG_H_ +#endif // _FASTDDS_CONFIG_H_ diff --git a/include/fastdds/dds/builtin/common/ReplyHeader.hpp b/include/fastdds/dds/builtin/common/ReplyHeader.hpp deleted file mode 100644 index f643a5789eb..00000000000 --- a/include/fastdds/dds/builtin/common/ReplyHeader.hpp +++ /dev/null @@ -1,72 +0,0 @@ -// Copyright 2019 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file RequestHeader.hpp - * - */ - -#ifndef REPLYHEADER_HPP -#define REPLYHEADER_HPP - -#include -#include - -namespace eprosima { - -namespace fastcdr { -class Cdr; -} // fastcdr - -namespace fastdds { -namespace dds { -namespace rpc { - -struct ReplyHeader -{ - fastrtps::rtps::SampleIdentity relatedRequestId; - - RemoteExceptionCode_t remoteEx; - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastdds::dds::rpc::ReplyHeader::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const ReplyHeader& data, - size_t current_alignment = 0); - - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastdds::dds::rpc::ReplyHeader::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastdds::dds::rpc::ReplyHeader::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI static bool isKeyDefined() - { - return false; - } - -}; - -} // namespace rpc -} // namespace dds -} // namespace fastdds -} // namespace eprosima - -#endif // REPLYHEADER_HPP diff --git a/include/fastdds/dds/builtin/common/RequestHeader.hpp b/include/fastdds/dds/builtin/common/RequestHeader.hpp deleted file mode 100644 index bf7edd4fb8f..00000000000 --- a/include/fastdds/dds/builtin/common/RequestHeader.hpp +++ /dev/null @@ -1,72 +0,0 @@ -// Copyright 2019 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file RequestHeader.hpp - * - */ - -#ifndef REQUESTHEADER_HPP -#define REQUESTHEADER_HPP - -#include -#include - -namespace eprosima { - -namespace fastcdr { -class Cdr; -} // fastcdr - -namespace fastdds { -namespace dds { -namespace rpc { - -struct RequestHeader -{ - eprosima::fastrtps::rtps::SampleIdentity requestId; - - InstanceName instanceName; - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastdds::dds::rpc::RequestHeader::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const RequestHeader& data, - size_t current_alignment = 0); - - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastdds::dds::rpc::RequestHeader::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastdds::dds::rpc::RequestHeader::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI static bool isKeyDefined() - { - return false; - } - -}; - -} // namespace rpc -} // namespace dds -} // namespace fastdds -} // namespace eprosima - -#endif // REQUESTHEADER_HPP diff --git a/include/fastdds/dds/builtin/common/Types.hpp b/include/fastdds/dds/builtin/common/Types.hpp deleted file mode 100644 index b7e1e02b34a..00000000000 --- a/include/fastdds/dds/builtin/common/Types.hpp +++ /dev/null @@ -1,57 +0,0 @@ -// Copyright 2019 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file Types.hpp - * - */ - -#ifndef TYPES_HPP -#define TYPES_HPP - -#include -#if FASTCDR_VERSION_MAJOR == 1 -#include -#else -#include -#endif // FASTCDR_VERSION_MAJOR == 1 - -namespace eprosima { -namespace fastdds { -namespace dds { -namespace rpc { - -using InstanceName = -#if FASTCDR_VERSION_MAJOR == 1 - fastrtps::string_255; -#else - fastcdr::string_255; -#endif // FASTCDR_VERSION_MAJOR == 1 - -enum RemoteExceptionCode_t -{ - REMOTE_EX_OK, - REMOTE_EX_UNSUPPORTED, - REMOTE_EX_INVALID_ARGUMENT, - REMOTE_EX_OUT_OF_RESOURCES, - REMOTE_EX_UNKNOWN_OPERATION, - REMOTE_EX_UNKNOWN_EXCEPTION -}; - -} // namespace rpc -} // namespace dds -} // namespace fastdds -} // namespace eprosima - -#endif // TYPES_HPP diff --git a/include/fastdds/dds/builtin/typelookup/TypeLookupManager.hpp b/include/fastdds/dds/builtin/typelookup/TypeLookupManager.hpp deleted file mode 100644 index c6465905c80..00000000000 --- a/include/fastdds/dds/builtin/typelookup/TypeLookupManager.hpp +++ /dev/null @@ -1,302 +0,0 @@ -// Copyright 2019 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file TypeLookupManager.hpp - * - */ - -#ifndef _FASTDDS_TYPELOOKUP_SERVICE_MANAGER_HPP -#define _FASTDDS_TYPELOOKUP_SERVICE_MANAGER_HPP -#ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC - -#include -#include - -#include -#include -#include - -#include -#include - -namespace eprosima { -namespace fastrtps { - -namespace rtps { - -class BuiltinProtocols; -class ReaderHistory; -class RTPSParticipantImpl; -class StatefulReader; -class StatefulWriter; -class ParticipantProxyData; -class WriterHistory; - -} // namespace rtps -} // namespace fastrtps - -namespace fastdds { -namespace dds { -namespace builtin { - -extern const fastrtps::rtps::SampleIdentity INVALID_SAMPLE_IDENTITY; - -/** - * Class TypeLookupManager that implements the TypeLookup Service described in the DDS-XTYPES 1.2 specification. - * @ingroup XTYPES - */ -class TypeLookupManager -{ - friend class TypeLookupRequestListener; - friend class TypeLookupReplyListener; - -public: - - /** - * Constructor - * @param prot Pointer to the BuiltinProtocols object. - */ - TypeLookupManager( - fastrtps::rtps::BuiltinProtocols* prot); - - virtual ~TypeLookupManager(); - - /** - * Initialize the TypeLookupManager protocol. - * @param p Pointer to the RTPS participant implementation. - * @return true if the initialziacion was successful. - */ - bool init_typelookup_service( - fastrtps::rtps::RTPSParticipantImpl* p); - - /** - * Assign the remote endpoints for a newly discovered RTPSParticipant. - * @param pdata Pointer to the RTPSParticipantProxyData object. - * @return True if correct. - */ - bool assign_remote_endpoints( - const fastrtps::rtps::ParticipantProxyData& pdata); - - /** - * Remove remote endpoints from the typelookup service. - * @param pdata Pointer to the ParticipantProxyData to remove - */ - void remove_remote_endpoints( - fastrtps::rtps::ParticipantProxyData* pdata); - - /** - * Get the builtin protocols - * @return Builtin protocols - */ - fastrtps::rtps::BuiltinProtocols* get_builtin_protocols() - { - return builtin_protocols_; - } - - /** - * Get the builtin request writer - * @return stateful writer - */ - fastrtps::rtps::StatefulWriter* get_builtin_request_writer(); - - /** - * Get the builtin reply writer - * @return stateful writer - */ - fastrtps::rtps::StatefulWriter* get_builtin_reply_writer(); - - /** - * Get the builtin request writer's history - * @return writer history - */ - fastrtps::rtps::WriterHistory* get_builtin_request_writer_history(); - - /** - * Get the builtin reply writer's history - * @return writer history - */ - fastrtps::rtps::WriterHistory* get_builtin_reply_writer_history(); - - /** - * Get the builtin request reader - * @return stateful reader - */ - fastrtps::rtps::StatefulReader* get_builtin_request_reader(); - - /** - * Get the builtin reply reader - * @return stateful reader - */ - fastrtps::rtps::StatefulReader* get_builtin_reply_reader(); - - /** - * Get the builtin request reader's history - * @return reader history - */ - fastrtps::rtps::ReaderHistory* get_builtin_request_reader_history(); - - /** - * Get the builtin reply reader's history - * @return reader history - */ - fastrtps::rtps::ReaderHistory* get_builtin_reply_reader_history(); - - /* TODO Uncomment if security is implemented. - #if HAVE_SECURITY - bool pairing_remote_reader_with_local_writer_after_security( - const fastrtps::rtps::GUID_t& local_writer, - const fastrtps::rtps::ReaderProxyData& remote_reader_data); - - bool pairing_remote_writer_with_local_reader_after_security( - const fastrtps::rtps::GUID_t& local_reader, - const fastrtps::rtps::WriterProxyData& remote_writer_data); - #endif - */ - - fastrtps::rtps::SampleIdentity get_type_dependencies( - const fastrtps::types::TypeIdentifierSeq& in) const; - - fastrtps::rtps::SampleIdentity get_types( - const fastrtps::types::TypeIdentifierSeq& in) const; - -private: - - /** - * Create the endpoints used in the TypeLookupManager. - * @return true if correct. - */ - bool create_endpoints(); - - /** - * Get the RTPS participant - * @return RTPS participant - */ - inline fastrtps::rtps::RTPSParticipantImpl* get_RTPS_participant() - { - return participant_; - } - - //! Get out instanceName as defined in 7.6.2.3.4 of the XTypes 1.2 document - std::string get_instanceName() const; - - //! Aux method to send requests - bool send_request( - TypeLookup_Request& req) const; - - //! Aux method to send replies - bool send_reply( - TypeLookup_Reply& rep) const; - - //! Aux method to received requests - bool recv_request( - fastrtps::rtps::CacheChange_t& change, - TypeLookup_Request& req) const; - - //! Aux method to received replies - bool recv_reply( - fastrtps::rtps::CacheChange_t& change, - TypeLookup_Reply& rep) const; - - const fastrtps::rtps::GUID_t& get_builtin_request_writer_guid() const; - - //!Pointer to the local RTPSParticipant. - fastrtps::rtps::RTPSParticipantImpl* participant_; - - //!Pointer to the builtinprotocol class. - fastrtps::rtps::BuiltinProtocols* builtin_protocols_; - - //!Pointer to the builtinRTPSParticipantMEssageWriter. - fastrtps::rtps::StatefulWriter* builtin_request_writer_; - - //!Pointer to the builtinRTPSParticipantMEssageReader. - fastrtps::rtps::StatefulReader* builtin_request_reader_; - - //!Pointer to the builtinRTPSParticipantMEssageWriter. - fastrtps::rtps::StatefulWriter* builtin_reply_writer_; - - //!Pointer to the builtinRTPSParticipantMEssageReader. - fastrtps::rtps::StatefulReader* builtin_reply_reader_; - - //!Writer History - fastrtps::rtps::WriterHistory* builtin_request_writer_history_; - - //!Writer History - fastrtps::rtps::WriterHistory* builtin_reply_writer_history_; - - //!Reader History - fastrtps::rtps::ReaderHistory* builtin_request_reader_history_; - - //!Reader History - fastrtps::rtps::ReaderHistory* builtin_reply_reader_history_; - - //!Request Listener object. - TypeLookupRequestListener* request_listener_; - - //!Reply Listener object. - TypeLookupReplyListener* reply_listener_; - - std::mutex temp_data_lock_; - fastrtps::rtps::ReaderProxyData temp_reader_proxy_data_; - fastrtps::rtps::WriterProxyData temp_writer_proxy_data_; - - mutable fastrtps::rtps::SequenceNumber_t request_seq_number_; - - mutable TypeLookup_RequestTypeSupport request_type_; - - mutable TypeLookup_ReplyTypeSupport reply_type_; - - /* TODO Uncomment if security is implemented. - #if HAVE_SECURITY - //!Pointer to the builtinRTPSParticipantMEssageWriter. - fastrtps::rtps::StatefulWriter* builtin_request_writer_secure_; - - //!Pointer to the builtinRTPSParticipantMEssageWriter. - fastrtps::rtps::StatefulWriter* builtin_reply_writer_secure_; - - //!Pointer to the builtinRTPSParticipantMEssageReader. - fastrtps::rtps::StatefulReader* builtin_request_reader_secure_; - - //!Pointer to the builtinRTPSParticipantMEssageReader. - fastrtps::rtps::StatefulReader* builtin_reply_reader_secure_; - - //!Writer History - fastrtps::rtps::WriterHistory* builtin_request_writer_secure_history_; - - //!Writer History - fastrtps::rtps::WriterHistory* builtin_reply_writer_secure_history_; - - //!Reader History - fastrtps::rtps::ReaderHistory* builtin_request_reader_secure_history_; - - //!Reader History - fastrtps::rtps::ReaderHistory* builtin_reply_reader_secure_history_; - - bool create_secure_endpoints(); - #endif - */ - - void request_cache_change_acked( - fastrtps::rtps::CacheChange_t* change); - - void reply_cache_change_acked( - fastrtps::rtps::CacheChange_t* change); -}; - -} /* namespace builtin */ -} /* namespace dds */ -} /* namespace fastdds */ -} /* namespace eprosima */ -#endif // ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC -#endif /* _FASTDDS_TYPELOOKUP_SERVICE_MANAGER_HPP */ diff --git a/include/fastdds/dds/builtin/typelookup/TypeLookupReplyListener.hpp b/include/fastdds/dds/builtin/typelookup/TypeLookupReplyListener.hpp deleted file mode 100644 index adc4b6c6499..00000000000 --- a/include/fastdds/dds/builtin/typelookup/TypeLookupReplyListener.hpp +++ /dev/null @@ -1,100 +0,0 @@ -// Copyright 2019 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file TypeLookupReplyListener.hpp - * - */ - -#ifndef TYPELOOKUP_REPLY_LISTENER_HPP_ -#define TYPELOOKUP_REPLY_LISTENER_HPP_ -#ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC -#include -#include - - -namespace eprosima { -namespace fastrtps { - -namespace types { -class TypeObjectFactory; -} // namespace types - -namespace rtps { - -class RTPSReader; -struct CacheChange_t; - -} // namespace rtps -} // namespace fastrtp - -namespace fastdds { -namespace dds { -namespace builtin { - -class TypeLookupManager; - -/** - * Class TypeLookupReplyListener that receives the typelookup request messages of remote endpoints. - * @ingroup TYPES_MODULE - */ -class TypeLookupReplyListener : public fastrtps::rtps::ReaderListener, public fastrtps::rtps::WriterListener -{ -public: - - /** - * @brief Constructor - * @param pwlp Pointer to the writer liveliness protocol - */ - TypeLookupReplyListener( - TypeLookupManager* pwlp); - - /** - * @brief Destructor - */ - virtual ~TypeLookupReplyListener() override; - - /** - * @brief Method call when this class is notified of a new cache change - * @param reader The reader receiving the cache change - * @param change The cache change - */ - void onNewCacheChangeAdded( - fastrtps::rtps::RTPSReader* reader, - const fastrtps::rtps::CacheChange_t* const change) override; - - /** - * @brief This method is called when all the readers matched with this Writer acknowledge that a cache - * change has been received. - * @param change The cache change - */ - void onWriterChangeReceivedByAll( - fastrtps::rtps::RTPSWriter*, - fastrtps::rtps::CacheChange_t* change) override; - -private: - - //! A pointer to the typelookup manager - TypeLookupManager* tlm_; - - //! A pointer to the TypeObject factory. - fastrtps::types::TypeObjectFactory* factory_; -}; - -} /* namespace builtin */ -} /* namespace dds */ -} /* namespace fastdds */ -} /* namespace eprosima */ -#endif // ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC -#endif /* TYPELOOKUP_REPLY_LISTENER_HPP_*/ diff --git a/include/fastdds/dds/builtin/typelookup/TypeLookupRequestListener.hpp b/include/fastdds/dds/builtin/typelookup/TypeLookupRequestListener.hpp deleted file mode 100644 index 87741fc84c5..00000000000 --- a/include/fastdds/dds/builtin/typelookup/TypeLookupRequestListener.hpp +++ /dev/null @@ -1,101 +0,0 @@ -// Copyright 2019 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file TypeLookupRequestListener.hpp - * - */ - -#ifndef TYPELOOKUP_REQUEST_LISTENER_HPP_ -#define TYPELOOKUP_REQUEST_LISTENER_HPP_ -#ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC -#include -#include - - -namespace eprosima { -namespace fastrtps { - -namespace types { -class TypeObjectFactory; -} // namespace types - -namespace rtps { - -class RTPSReader; -struct CacheChange_t; - -} // namespace rtps -} // namespace fastrtp - -namespace fastdds { -namespace dds { -namespace builtin { - -class TypeLookupManager; - -/** - * Class TypeLookupRequestListener that receives the typelookup request messages of remote endpoints. - * @ingroup TYPES_MODULE - */ -class TypeLookupRequestListener : public fastrtps::rtps::ReaderListener, public fastrtps::rtps::WriterListener -{ -public: - - /** - * @brief Constructor - * @param pwlp Pointer to the writer liveliness protocol - */ - TypeLookupRequestListener( - TypeLookupManager* pwlp); - - /** - * @brief Destructor - */ - virtual ~TypeLookupRequestListener() override; - - /** - * @brief Method call when this class is notified of a new cache change - * @param reader The reader receiving the cache change - * @param change The cache change - */ - void onNewCacheChangeAdded( - fastrtps::rtps::RTPSReader* reader, - const fastrtps::rtps::CacheChange_t* const change) override; - - /** - * @brief This method is called when all the readers matched with this Writer acknowledge that a cache - * change has been received. - * @param change The cache change - */ - void onWriterChangeReceivedByAll( - fastrtps::rtps::RTPSWriter*, - fastrtps::rtps::CacheChange_t* change) override; - -private: - - //! A pointer to the typelookup manager - TypeLookupManager* tlm_; - - //! A pointer to the TypeObject factory. - fastrtps::types::TypeObjectFactory* factory_; - -}; - -} /* namespace builtin */ -} /* namespace dds */ -} /* namespace fastdds */ -} /* namespace eprosima */ -#endif // ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC -#endif /* TYPELOOKUP_REQUEST_LISTENER_HPP_*/ diff --git a/include/fastdds/dds/builtin/typelookup/common/TypeLookupTypes.hpp b/include/fastdds/dds/builtin/typelookup/common/TypeLookupTypes.hpp deleted file mode 100644 index 23ebf8ec020..00000000000 --- a/include/fastdds/dds/builtin/typelookup/common/TypeLookupTypes.hpp +++ /dev/null @@ -1,645 +0,0 @@ -// Copyright 2019 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file TypeLookupTypes.hpp - * - */ - -#ifndef TYPELOOKUPTYPES_HPP -#define TYPELOOKUPTYPES_HPP - -#include -#include - -#include -#include -#include - -namespace eprosima { - -namespace fastcdr { -class Cdr; -} // namespace fastcdr - -namespace fastdds { -namespace dds { -namespace builtin { - -const int32_t TypeLookup_getTypes_Hash = static_cast(0xd35282d1); -const int32_t TypeLookup_getDependencies_Hash = static_cast(0x31fbaa35); - -struct TypeLookup_getTypes_In -{ - std::vector type_ids; - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastdds::dds::builtin::TypeLookup_getTypes_In::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const TypeLookup_getTypes_In& data, - size_t current_alignment = 0); - - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastdds::dds::builtin::TypeLookup_getTypes_In::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastdds::dds::builtin::TypeLookup_getTypes_In::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI static bool isKeyDefined() - { - return false; - } - -}; - -struct TypeLookup_getTypes_Out -{ - std::vector types; - - std::vector complete_to_minimal; - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastdds::dds::builtin::TypeLookup_getTypes_Out::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const TypeLookup_getTypes_Out& data, - size_t current_alignment = 0); - - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastdds::dds::builtin::TypeLookup_getTypes_Out::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastdds::dds::builtin::TypeLookup_getTypes_Out::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI static bool isKeyDefined() - { - return false; - } - -}; - -class TypeLookup_getTypes_Result -{ -public: - - RTPS_DllAPI TypeLookup_getTypes_Result(); - - RTPS_DllAPI ~TypeLookup_getTypes_Result(); - - RTPS_DllAPI TypeLookup_getTypes_Result( - const TypeLookup_getTypes_Result& x); - - RTPS_DllAPI TypeLookup_getTypes_Result( - TypeLookup_getTypes_Result&& x); - - RTPS_DllAPI TypeLookup_getTypes_Result& operator =( - const TypeLookup_getTypes_Result& x); - - RTPS_DllAPI TypeLookup_getTypes_Result& operator =( - TypeLookup_getTypes_Result&& x); - - RTPS_DllAPI void _d( - int32_t __d); - - RTPS_DllAPI int32_t _d() const; - - RTPS_DllAPI int32_t& _d(); - - RTPS_DllAPI void result( - const TypeLookup_getTypes_Out& _result); - - RTPS_DllAPI void result( - TypeLookup_getTypes_Out&& _result); - - RTPS_DllAPI const TypeLookup_getTypes_Out& result() const; - - RTPS_DllAPI TypeLookup_getTypes_Out& result(); - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastdds::dds::builtin::TypeLookup_getTypes_Result::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const TypeLookup_getTypes_Result& data, - size_t current_alignment = 0); - - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastdds::dds::builtin::TypeLookup_getTypes_Result::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastdds::dds::builtin::TypeLookup_getTypes_Result::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI static bool isKeyDefined() - { - return false; - } - -private: - - int32_t m__d; - TypeLookup_getTypes_Out m_result; -}; - -class TypeLookup_getTypeDependencies_In -{ -public: - - std::vector type_ids; - - std::vector continuation_point; - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, - "eprosima::fastdds::dds::builtin::TypeLookup_getTypeDependencies_In::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const TypeLookup_getTypeDependencies_In& data, - size_t current_alignment = 0); - - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastdds::dds::builtin::TypeLookup_getTypeDependencies_In::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastdds::dds::builtin::TypeLookup_getTypeDependencies_In::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI static bool isKeyDefined() - { - return false; - } - -}; - -class TypeLookup_getTypeDependencies_Out -{ -public: - - std::vector dependent_typeids; - - std::vector continuation_point; - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, - "eprosima::fastdds::dds::builtin::TypeLookup_getTypeDependencies_Out::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const TypeLookup_getTypeDependencies_Out& data, - size_t current_alignment = 0); - - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastdds::dds::builtin::TypeLookup_getTypeDependencies_Out::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastdds::dds::builtin::TypeLookup_getTypeDependencies_Out::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI static bool isKeyDefined() - { - return false; - } - -}; - -class TypeLookup_getTypeDependencies_Result -{ -public: - - RTPS_DllAPI TypeLookup_getTypeDependencies_Result(); - - RTPS_DllAPI ~TypeLookup_getTypeDependencies_Result(); - - RTPS_DllAPI TypeLookup_getTypeDependencies_Result( - const TypeLookup_getTypeDependencies_Result& x); - - RTPS_DllAPI TypeLookup_getTypeDependencies_Result( - TypeLookup_getTypeDependencies_Result&& x); - - RTPS_DllAPI TypeLookup_getTypeDependencies_Result& operator =( - const TypeLookup_getTypeDependencies_Result& x); - - RTPS_DllAPI TypeLookup_getTypeDependencies_Result& operator =( - TypeLookup_getTypeDependencies_Result&& x); - - RTPS_DllAPI void _d( - int32_t __d); - - RTPS_DllAPI int32_t _d() const; - - RTPS_DllAPI int32_t& _d(); - - RTPS_DllAPI void result( - const TypeLookup_getTypeDependencies_Out& _result); - - RTPS_DllAPI void result( - TypeLookup_getTypeDependencies_Out&& _result); - - RTPS_DllAPI const TypeLookup_getTypeDependencies_Out& result() const; - - RTPS_DllAPI TypeLookup_getTypeDependencies_Out& result(); - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, - "eprosima::fastdds::dds::builtin::TypeLookup_getTypeDependencies_Result::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const TypeLookup_getTypeDependencies_Result& data, - size_t current_alignment = 0); - - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastdds::dds::builtin::TypeLookup_getTypeDependencies_Result::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastdds::dds::builtin::TypeLookup_getTypeDependencies_Result::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI static bool isKeyDefined() - { - return false; - } - -private: - - int32_t m__d; - - TypeLookup_getTypeDependencies_Out m_result; -}; -class TypeLookup_Call -{ -public: - - RTPS_DllAPI TypeLookup_Call(); - - RTPS_DllAPI ~TypeLookup_Call(); - - RTPS_DllAPI TypeLookup_Call( - const TypeLookup_Call& x); - - RTPS_DllAPI TypeLookup_Call( - TypeLookup_Call&& x); - - RTPS_DllAPI TypeLookup_Call& operator =( - const TypeLookup_Call& x); - - RTPS_DllAPI TypeLookup_Call& operator =( - TypeLookup_Call&& x); - - RTPS_DllAPI void _d( - int32_t __d); - - RTPS_DllAPI int32_t _d() const; - - RTPS_DllAPI int32_t& _d(); - - RTPS_DllAPI void getTypes( - const TypeLookup_getTypes_In& _getTypes); - - RTPS_DllAPI void getTypes( - TypeLookup_getTypes_In&& _getTypes); - - RTPS_DllAPI const TypeLookup_getTypes_In& getTypes() const; - - RTPS_DllAPI TypeLookup_getTypes_In& getTypes(); - - RTPS_DllAPI void getTypeDependencies( - const TypeLookup_getTypeDependencies_In& _getTypeDependencies); - - RTPS_DllAPI void getTypeDependencies( - TypeLookup_getTypeDependencies_In&& _getTypeDependencies); - - RTPS_DllAPI const TypeLookup_getTypeDependencies_In& getTypeDependencies() const; - - RTPS_DllAPI TypeLookup_getTypeDependencies_In& getTypeDependencies(); - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastdds::dds::builtin::TypeLookup_Call::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const TypeLookup_Call& data, - size_t current_alignment = 0); - - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastdds::dds::builtin::TypeLookup_Call::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastdds::dds::builtin::TypeLookup_Call::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI static bool isKeyDefined() - { - return false; - } - -private: - - int32_t m__d; - - TypeLookup_getTypes_In m_getTypes; - TypeLookup_getTypeDependencies_In m_getTypeDependencies; -}; - -class TypeLookup_Request -{ -public: - - rpc::RequestHeader header; - - TypeLookup_Call data; - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastdds::dds::builtin::TypeLookup_Request::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const TypeLookup_Request& data, - size_t current_alignment = 0); - - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastdds::dds::builtin::TypeLookup_Request::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastdds::dds::builtin::TypeLookup_Request::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI static bool isKeyDefined() - { - return false; - } - -}; - -class TypeLookup_Return -{ -public: - - RTPS_DllAPI TypeLookup_Return(); - - RTPS_DllAPI ~TypeLookup_Return(); - - RTPS_DllAPI TypeLookup_Return( - const TypeLookup_Return& x); - - RTPS_DllAPI TypeLookup_Return( - TypeLookup_Return&& x); - - RTPS_DllAPI TypeLookup_Return& operator =( - const TypeLookup_Return& x); - - RTPS_DllAPI TypeLookup_Return& operator =( - TypeLookup_Return&& x); - - RTPS_DllAPI void _d( - int32_t __d); - - RTPS_DllAPI int32_t _d() const; - - RTPS_DllAPI int32_t& _d(); - - RTPS_DllAPI void getType( - const TypeLookup_getTypes_Result& _getType); - - RTPS_DllAPI void getType( - TypeLookup_getTypes_Result&& _getType); - - RTPS_DllAPI const TypeLookup_getTypes_Result& getType() const; - - RTPS_DllAPI TypeLookup_getTypes_Result& getType(); - - RTPS_DllAPI void getTypeDependencies( - const TypeLookup_getTypeDependencies_Result& _getTypeDependencies); - - RTPS_DllAPI void getTypeDependencies( - TypeLookup_getTypeDependencies_Result&& _getTypeDependencies); - - RTPS_DllAPI const TypeLookup_getTypeDependencies_Result& getTypeDependencies() const; - - RTPS_DllAPI TypeLookup_getTypeDependencies_Result& getTypeDependencies(); - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastdds::dds::builtin::TypeLookup_Return::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const TypeLookup_Return& data, - size_t current_alignment = 0); - - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastdds::dds::builtin::TypeLookup_Return::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastdds::dds::builtin::TypeLookup_Return::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI static bool isKeyDefined() - { - return false; - } - -private: - - int32_t m__d; - - TypeLookup_getTypes_Result m_getType; - TypeLookup_getTypeDependencies_Result m_getTypeDependencies; -}; - -class TypeLookup_Reply -{ -public: - - rpc::RequestHeader header; - - TypeLookup_Return return_value; - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastdds::dds::builtin::TypeLookup_Reply::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const TypeLookup_Reply& data, - size_t current_alignment = 0); - - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastdds::dds::builtin::TypeLookup_Reply::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastdds::dds::builtin::TypeLookup_Reply::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI static bool isKeyDefined() - { - return false; - } - -}; - -// TypeSupports -class TypeLookup_RequestPubSubType : public TopicDataType -{ -public: - - TypeLookup_RequestPubSubType(); - - virtual ~TypeLookup_RequestPubSubType() override; - - bool serialize( - void* data, - fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, fastdds::dds::DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - } - - bool serialize( - void* data, - fastrtps::rtps::SerializedPayload_t* payload, - fastdds::dds::DataRepresentationId_t data_representation) override; - - bool deserialize( - fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - void* createData() override; - - void deleteData( - void* data) override; -}; - -class TypeLookup_ReplyPubSubType : public TopicDataType -{ -public: - - TypeLookup_ReplyPubSubType(); - - virtual ~TypeLookup_ReplyPubSubType() override; - - bool serialize( - void* data, - fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, fastdds::dds::DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - } - - bool serialize( - void* data, - fastrtps::rtps::SerializedPayload_t* payload, - fastdds::dds::DataRepresentationId_t data_representation) override; - - bool deserialize( - fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - void* createData() override; - - void deleteData( - void* data) override; -}; - -class TypeLookup_RequestTypeSupport : public TypeSupport -{ -public: - - RTPS_DllAPI bool serialize( - void* data, - fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, fastdds::dds::DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - } - - RTPS_DllAPI bool serialize( - void* data, - fastrtps::rtps::SerializedPayload_t* payload, - fastdds::dds::DataRepresentationId_t data_representation) override; - - RTPS_DllAPI bool deserialize( - fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - RTPS_DllAPI void* create_data() override; - - RTPS_DllAPI void delete_data( - void* data) override; -}; - -class TypeLookup_ReplyTypeSupport : public TypeSupport -{ -public: - - RTPS_DllAPI bool serialize( - void* data, - fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, fastdds::dds::DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - } - - RTPS_DllAPI bool serialize( - void* data, - fastrtps::rtps::SerializedPayload_t* payload, - fastdds::dds::DataRepresentationId_t data_representation) override; - - RTPS_DllAPI bool deserialize( - fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - RTPS_DllAPI void* create_data() override; - - RTPS_DllAPI void delete_data( - void* data) override; -}; - - -} // namespace builtin -} // namespace dds -} // namespace fastdds -} // namespace eprosima - -#endif // TYPELOOKUPTYPES_HPP diff --git a/include/fastdds/dds/common/InstanceHandle.hpp b/include/fastdds/dds/common/InstanceHandle.hpp index 144af61e0dd..8f55182cb21 100644 --- a/include/fastdds/dds/common/InstanceHandle.hpp +++ b/include/fastdds/dds/common/InstanceHandle.hpp @@ -21,7 +21,7 @@ #define _FASTDDS_DDS_COMMON_INSTANCEHANDLE_HPP_ #include -#include +#include namespace eprosima { @@ -30,7 +30,7 @@ namespace dds { using InstanceHandle_t = eprosima::fastrtps::rtps::InstanceHandle_t; -extern RTPS_DllAPI const InstanceHandle_t HANDLE_NIL; +extern FASTDDS_EXPORTED_API const InstanceHandle_t HANDLE_NIL; } // namespace dds } // namespace fastdds diff --git a/include/fastdds/dds/core/Entity.hpp b/include/fastdds/dds/core/Entity.hpp index e4399624e80..c1d22d9269e 100644 --- a/include/fastdds/dds/core/Entity.hpp +++ b/include/fastdds/dds/core/Entity.hpp @@ -22,8 +22,8 @@ #include #include +#include #include -#include namespace eprosima { namespace fastdds { @@ -43,7 +43,7 @@ class Entity * * @param mask StatusMask (default: all) */ - RTPS_DllAPI Entity( + FASTDDS_EXPORTED_API Entity( const StatusMask& mask = StatusMask::all()) : status_mask_(mask) , status_condition_(this) @@ -56,10 +56,10 @@ class Entity * * @return RETCODE_OK */ - virtual fastrtps::types::ReturnCode_t enable() + virtual ReturnCode_t enable() { enable_ = true; - return fastrtps::types::ReturnCode_t::RETCODE_OK; + return RETCODE_OK; } /** @@ -75,7 +75,7 @@ class Entity * * @return Reference to the StatusMask with the relevant statuses set to 1 */ - RTPS_DllAPI const StatusMask& get_status_mask() const + FASTDDS_EXPORTED_API const StatusMask& get_status_mask() const { return status_mask_; } @@ -94,7 +94,7 @@ class Entity * * @return const reference to the StatusMask with the triggered statuses set to 1 */ - RTPS_DllAPI const StatusMask& get_status_changes() const; + FASTDDS_EXPORTED_API const StatusMask& get_status_changes() const; /** * @brief Retrieves the instance handler that represents the Entity @@ -111,12 +111,12 @@ class Entity * * @return true if enabled, false if not */ - RTPS_DllAPI bool is_enabled() const + FASTDDS_EXPORTED_API bool is_enabled() const { return enable_; } - RTPS_DllAPI bool operator ==( + FASTDDS_EXPORTED_API bool operator ==( const Entity& other) const { return (this->instance_handle_ == other.instance_handle_); @@ -127,7 +127,7 @@ class Entity * * @return Reference to StatusCondition object */ - RTPS_DllAPI StatusCondition& get_statuscondition() + FASTDDS_EXPORTED_API StatusCondition& get_statuscondition() { return status_condition_; } @@ -139,7 +139,7 @@ class Entity * * @param handle Instance Handle */ - RTPS_DllAPI void set_instance_handle( + FASTDDS_EXPORTED_API void set_instance_handle( const InstanceHandle_t& handle) { instance_handle_ = handle; diff --git a/include/fastrtps/rtps/messages/MessageReceiver.h b/include/fastdds/dds/core/ReturnCode.hpp similarity index 65% rename from include/fastrtps/rtps/messages/MessageReceiver.h rename to include/fastdds/dds/core/ReturnCode.hpp index 3ee6062aae8..607e091c670 100644 --- a/include/fastrtps/rtps/messages/MessageReceiver.h +++ b/include/fastdds/dds/core/ReturnCode.hpp @@ -1,4 +1,4 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// Copyright 2023 Proyectos y Sistemas de Mantenimiento SL (eProsima). // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. @@ -12,15 +12,15 @@ // See the License for the specific language governing permissions and // limitations under the License. -/** - * @file MessageReceiver.h +/*! + * @file ReturnCode.hpp */ +#ifndef _FASTDDS_DDS_CORE_RETURNCODE_HPP_ +#define _FASTDDS_DDS_CORE_RETURNCODE_HPP_ +#include "detail/DDSReturnCode.hpp" +#include "detail/DDSSecurityReturnCode.hpp" -#ifndef MESSAGERECEIVER_H_ -#define MESSAGERECEIVER_H_ +#endif // _FASTDDS_DDS_CORE_RETURNCODE_HPP_ -#include - -#endif /* MESSAGERECEIVER_H_ */ diff --git a/src/cpp/utils/System.cpp b/include/fastdds/dds/core/Types.hpp similarity index 64% rename from src/cpp/utils/System.cpp rename to include/fastdds/dds/core/Types.hpp index 955bf618e11..8f24af6545b 100644 --- a/src/cpp/utils/System.cpp +++ b/include/fastdds/dds/core/Types.hpp @@ -1,4 +1,4 @@ -// Copyright 2018 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// Copyright 2023 Proyectos y Sistemas de Mantenimiento SL (eProsima). // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. @@ -12,21 +12,21 @@ // See the License for the specific language governing permissions and // limitations under the License. -/** - * @file System.cpp - */ +#ifndef FASTDDS_DDS_CORE_TYPES_HPP +#define FASTDDS_DDS_CORE_TYPES_HPP -#include - -#include +#include namespace eprosima { -namespace fastrtps { +namespace fastdds { +namespace dds { + +typedef uint32_t DomainId_t; -int System::GetPID() -{ - return SystemInfo::instance().process_id(); -} +const int32_t LENGTH_UNLIMITED = -1; -} // namespace fastrtps +} // namespace dds +} // namespace fastdds } // namespace eprosima + +#endif // FASTDDS_DDS_CORE_TYPES_HPP diff --git a/include/fastdds/dds/core/condition/Condition.hpp b/include/fastdds/dds/core/condition/Condition.hpp index ef364c418b3..3879bef7880 100644 --- a/include/fastdds/dds/core/condition/Condition.hpp +++ b/include/fastdds/dds/core/condition/Condition.hpp @@ -24,7 +24,7 @@ #include #include -#include +#include namespace eprosima { namespace fastdds { @@ -46,7 +46,7 @@ class Condition * @brief Retrieves the trigger_value of the Condition * @return true if trigger_value is set to 'true', 'false' otherwise */ - RTPS_DllAPI virtual bool get_trigger_value() const + FASTDDS_EXPORTED_API virtual bool get_trigger_value() const { EPROSIMA_LOG_WARNING(CONDITION, "get_trigger_value public member function not implemented"); return false; // TODO return trigger value diff --git a/include/fastdds/dds/core/condition/GuardCondition.hpp b/include/fastdds/dds/core/condition/GuardCondition.hpp index 1912fb8c92f..e4329556a6b 100644 --- a/include/fastdds/dds/core/condition/GuardCondition.hpp +++ b/include/fastdds/dds/core/condition/GuardCondition.hpp @@ -23,10 +23,8 @@ #include #include -#include -#include - -using eprosima::fastrtps::types::ReturnCode_t; +#include +#include namespace eprosima { namespace fastdds { @@ -45,18 +43,18 @@ class GuardCondition : public Condition { public: - RTPS_DllAPI GuardCondition(); + FASTDDS_EXPORTED_API GuardCondition(); - RTPS_DllAPI ~GuardCondition(); + FASTDDS_EXPORTED_API ~GuardCondition(); - RTPS_DllAPI bool get_trigger_value() const override; + FASTDDS_EXPORTED_API bool get_trigger_value() const override; /** * @brief Set the trigger_value * @param value new value for trigger * @return RETURN_OK */ - RTPS_DllAPI ReturnCode_t set_trigger_value( + FASTDDS_EXPORTED_API ReturnCode_t set_trigger_value( bool value); private: diff --git a/include/fastdds/dds/core/condition/StatusCondition.hpp b/include/fastdds/dds/core/condition/StatusCondition.hpp index 49fd0adc920..a3d1b1ca285 100644 --- a/include/fastdds/dds/core/condition/StatusCondition.hpp +++ b/include/fastdds/dds/core/condition/StatusCondition.hpp @@ -21,11 +21,9 @@ #define _FASTDDS_STATUS_CONDITION_HPP_ #include +#include #include -#include -#include - -using eprosima::fastrtps::types::ReturnCode_t; +#include namespace eprosima { namespace fastdds { @@ -68,27 +66,27 @@ class StatusCondition final : public Condition * @brief Retrieves the trigger_value of the Condition * @return true if trigger_value is set to 'true', 'false' otherwise */ - RTPS_DllAPI bool get_trigger_value() const override; + FASTDDS_EXPORTED_API bool get_trigger_value() const override; /** * @brief Defines the list of communication statuses that are taken into account to determine the trigger_value * @param mask defines the mask for the status * @return RETCODE_OK with everything ok, error code otherwise */ - RTPS_DllAPI ReturnCode_t set_enabled_statuses( + FASTDDS_EXPORTED_API ReturnCode_t set_enabled_statuses( const StatusMask& mask); /** * @brief Retrieves the list of communication statuses that are taken into account to determine the trigger_value * @return Status set or default status if it has not been set */ - RTPS_DllAPI const StatusMask& get_enabled_statuses() const; + FASTDDS_EXPORTED_API const StatusMask& get_enabled_statuses() const; /** * @brief Returns the Entity associated * @return Entity */ - RTPS_DllAPI Entity* get_entity() const; + FASTDDS_EXPORTED_API Entity* get_entity() const; detail::StatusConditionImpl* get_impl() const { diff --git a/include/fastdds/dds/core/condition/WaitSet.hpp b/include/fastdds/dds/core/condition/WaitSet.hpp index 2066aaede7f..367fd591ce2 100644 --- a/include/fastdds/dds/core/condition/WaitSet.hpp +++ b/include/fastdds/dds/core/condition/WaitSet.hpp @@ -23,11 +23,9 @@ #include #include +#include #include -#include -#include - -using eprosima::fastrtps::types::ReturnCode_t; +#include namespace eprosima { namespace fastdds { @@ -47,9 +45,9 @@ class WaitSet { public: - RTPS_DllAPI WaitSet(); + FASTDDS_EXPORTED_API WaitSet(); - RTPS_DllAPI ~WaitSet(); + FASTDDS_EXPORTED_API ~WaitSet(); WaitSet( const WaitSet&) = delete; @@ -65,7 +63,7 @@ class WaitSet * @param cond Condition * @return RETCODE_OK if attached correctly, error code otherwise */ - RTPS_DllAPI ReturnCode_t attach_condition( + FASTDDS_EXPORTED_API ReturnCode_t attach_condition( const Condition& cond); @@ -74,7 +72,7 @@ class WaitSet * @param cond Condition * @return RETCODE_OK if detached correctly, PRECONDITION_NOT_MET if condition was not attached */ - RTPS_DllAPI ReturnCode_t detach_condition( + FASTDDS_EXPORTED_API ReturnCode_t detach_condition( const Condition& cond); /** @@ -86,7 +84,7 @@ class WaitSet * @return RETCODE_OK if everything correct, PRECONDITION_NOT_MET if WaitSet already waiting, TIMEOUT if maximum * time expired, error code otherwise */ - RTPS_DllAPI ReturnCode_t wait( + FASTDDS_EXPORTED_API ReturnCode_t wait( ConditionSeq& active_conditions, const fastrtps::Duration_t timeout) const; @@ -95,7 +93,7 @@ class WaitSet * @param attached_conditions Reference to the collection of attached conditions * @return RETCODE_OK if everything correct, error code otherwise */ - RTPS_DllAPI ReturnCode_t get_conditions( + FASTDDS_EXPORTED_API ReturnCode_t get_conditions( ConditionSeq& attached_conditions) const; private: diff --git a/test/blackbox/types/TestIncludeRegression3361.h b/include/fastdds/dds/core/detail/DDSReturnCode.hpp similarity index 52% rename from test/blackbox/types/TestIncludeRegression3361.h rename to include/fastdds/dds/core/detail/DDSReturnCode.hpp index 9f0c54030ed..24c32e8e8e8 100644 --- a/test/blackbox/types/TestIncludeRegression3361.h +++ b/include/fastdds/dds/core/detail/DDSReturnCode.hpp @@ -13,32 +13,17 @@ // limitations under the License. /*! - * @file TestIncludeRegression3361.h + * @file DDSReturnCode.hpp * This header file contains the declaration of the described types in the IDL file. * * This file was generated by the tool fastddsgen. */ -#include -#include "TestIncludeRegression3361v1.h" +#ifndef _FAST_DDS_GENERATED_DDSRETURNCODE_HPP_ +#define _FAST_DDS_GENERATED_DDSRETURNCODE_HPP_ -#if FASTCDR_VERSION_MAJOR > 1 - -#ifndef _FAST_DDS_GENERATED_TESTINCLUDEREGRESSION3361_H_ -#define _FAST_DDS_GENERATED_TESTINCLUDEREGRESSION3361_H_ - -#include -#include #include -#include -#include -#include - -#include -#include -#include - - +#include #if defined(_WIN32) #if defined(EPROSIMA_USER_DLL_EXPORT) @@ -52,36 +37,48 @@ #if defined(_WIN32) #if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(TESTINCLUDEREGRESSION3361_SOURCE) -#define TESTINCLUDEREGRESSION3361_DllAPI __declspec( dllexport ) +#if defined(DDSRETURNCODE_SOURCE) +#define DDSRETURNCODE_DllAPI __declspec( dllexport ) #else -#define TESTINCLUDEREGRESSION3361_DllAPI __declspec( dllimport ) -#endif // TESTINCLUDEREGRESSION3361_SOURCE +#define DDSRETURNCODE_DllAPI __declspec( dllimport ) +#endif // DDSRETURNCODE_SOURCE #else -#define TESTINCLUDEREGRESSION3361_DllAPI +#define DDSRETURNCODE_DllAPI #endif // EPROSIMA_USER_DLL_EXPORT #else -#define TESTINCLUDEREGRESSION3361_DllAPI +#define DDSRETURNCODE_DllAPI #endif // _WIN32 namespace eprosima { -namespace fastcdr { -class Cdr; -class CdrSizeCalculator; -} // namespace fastcdr -} // namespace eprosima +namespace fastdds { + +namespace dds { -namespace TestModule { +typedef int32_t ReturnCode_t; -typedef std::string MACHINEID; +const ReturnCode_t RETCODE_OK = 0; +const ReturnCode_t RETCODE_ERROR = 1; +const ReturnCode_t RETCODE_UNSUPPORTED = 2; +const ReturnCode_t RETCODE_BAD_PARAMETER = 3; +const ReturnCode_t RETCODE_PRECONDITION_NOT_MET = 4; +const ReturnCode_t RETCODE_OUT_OF_RESOURCES = 5; +const ReturnCode_t RETCODE_NOT_ENABLED = 6; +const ReturnCode_t RETCODE_IMMUTABLE_POLICY = 7; +const ReturnCode_t RETCODE_INCONSISTENT_POLICY = 8; +const ReturnCode_t RETCODE_ALREADY_DELETED = 9; +const ReturnCode_t RETCODE_TIMEOUT = 10; +const ReturnCode_t RETCODE_NO_DATA = 11; +const ReturnCode_t RETCODE_ILLEGAL_OPERATION = 12; +} // namespace dds -} // namespace TestModule +} // namespace fastdds + +} // namespace eprosima -#endif // _FAST_DDS_GENERATED_TESTINCLUDEREGRESSION3361_H_ +#endif // _FAST_DDS_GENERATED_DDSRETURNCODE_HPP_ -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/include/fastdds/dds/core/detail/DDSReturnCode.idl b/include/fastdds/dds/core/detail/DDSReturnCode.idl new file mode 100644 index 00000000000..0d286676f0c --- /dev/null +++ b/include/fastdds/dds/core/detail/DDSReturnCode.idl @@ -0,0 +1,25 @@ +// The content of this file, related to the DDS's return code values, was extracted from the omg idl +// https://www.omg.org/spec/DDS/20140501/dds_dcps.idl + +module DDS { + + typedef long ReturnCode_t; + + // ---------------------------------------------------------------------- + // Return codes + // ---------------------------------------------------------------------- + const ReturnCode_t RETCODE_OK = 0; + const ReturnCode_t RETCODE_ERROR = 1; + const ReturnCode_t RETCODE_UNSUPPORTED = 2; + const ReturnCode_t RETCODE_BAD_PARAMETER = 3; + const ReturnCode_t RETCODE_PRECONDITION_NOT_MET = 4; + const ReturnCode_t RETCODE_OUT_OF_RESOURCES = 5; + const ReturnCode_t RETCODE_NOT_ENABLED = 6; + const ReturnCode_t RETCODE_IMMUTABLE_POLICY = 7; + const ReturnCode_t RETCODE_INCONSISTENT_POLICY = 8; + const ReturnCode_t RETCODE_ALREADY_DELETED = 9; + const ReturnCode_t RETCODE_TIMEOUT = 10; + const ReturnCode_t RETCODE_NO_DATA = 11; + const ReturnCode_t RETCODE_ILLEGAL_OPERATION = 12; + +}; diff --git a/test/blackbox/types/HelloWorldTypeObject.h b/include/fastdds/dds/core/detail/DDSSecurityReturnCode.hpp similarity index 55% rename from test/blackbox/types/HelloWorldTypeObject.h rename to include/fastdds/dds/core/detail/DDSSecurityReturnCode.hpp index 76b2a621eb7..36955743934 100644 --- a/test/blackbox/types/HelloWorldTypeObject.h +++ b/include/fastdds/dds/core/detail/DDSSecurityReturnCode.hpp @@ -13,53 +13,59 @@ // limitations under the License. /*! - * @file HelloWorldTypeObject.h + * @file DDSSecurityReturnCode.hpp * This header file contains the declaration of the described types in the IDL file. * * This file was generated by the tool fastddsgen. */ -#ifndef _FAST_DDS_GENERATED_HELLOWORLD_TYPE_OBJECT_H_ -#define _FAST_DDS_GENERATED_HELLOWORLD_TYPE_OBJECT_H_ +#ifndef _FAST_DDS_GENERATED_DDSSECURITYRETURNCODE_HPP_ +#define _FAST_DDS_GENERATED_DDSSECURITYRETURNCODE_HPP_ - -#include -#include +#include +#include +#include "DDSReturnCode.hpp" #if defined(_WIN32) #if defined(EPROSIMA_USER_DLL_EXPORT) #define eProsima_user_DllExport __declspec( dllexport ) #else #define eProsima_user_DllExport -#endif +#endif // EPROSIMA_USER_DLL_EXPORT #else #define eProsima_user_DllExport -#endif +#endif // _WIN32 #if defined(_WIN32) #if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(HelloWorld_SOURCE) -#define HelloWorld_DllAPI __declspec( dllexport ) +#if defined(DDSSECURITYRETURNCODE_SOURCE) +#define DDSSECURITYRETURNCODE_DllAPI __declspec( dllexport ) #else -#define HelloWorld_DllAPI __declspec( dllimport ) -#endif // HelloWorld_SOURCE +#define DDSSECURITYRETURNCODE_DllAPI __declspec( dllimport ) +#endif // DDSSECURITYRETURNCODE_SOURCE #else -#define HelloWorld_DllAPI -#endif +#define DDSSECURITYRETURNCODE_DllAPI +#endif // EPROSIMA_USER_DLL_EXPORT #else -#define HelloWorld_DllAPI +#define DDSSECURITYRETURNCODE_DllAPI #endif // _WIN32 -using namespace eprosima::fastrtps::types; +namespace eprosima { + +namespace fastdds { + +namespace dds { + + +const ReturnCode_t RETCODE_NOT_ALLOWED_BY_SECURITY = 1000; + +} // namespace dds -eProsima_user_DllExport void registerHelloWorldTypes(); +} // namespace fastdds +} // namespace eprosima -eProsima_user_DllExport const TypeIdentifier* GetHelloWorldIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetHelloWorldObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalHelloWorldObject(); -eProsima_user_DllExport const TypeObject* GetCompleteHelloWorldObject(); +#endif // _FAST_DDS_GENERATED_DDSSECURITYRETURNCODE_HPP_ -#endif // _FAST_DDS_GENERATED_HELLOWORLD_TYPE_OBJECT_H_ \ No newline at end of file diff --git a/include/fastdds/dds/core/detail/DDSSecurityReturnCode.idl b/include/fastdds/dds/core/detail/DDSSecurityReturnCode.idl new file mode 100644 index 00000000000..3248239741c --- /dev/null +++ b/include/fastdds/dds/core/detail/DDSSecurityReturnCode.idl @@ -0,0 +1,10 @@ +// The content of this file, related to the DDS Security's return code values, was extracted from the omg idl +// https://www.omg.org/spec/DDS-SECURITY/20170901/dds_security_plugins_spis.idl +#include "DDSReturnCode.idl" + +module DDS { + + // DDSSEC11-24 + const ReturnCode_t RETCODE_NOT_ALLOWED_BY_SECURITY = 1000; + +}; diff --git a/include/fastdds/dds/core/policy/ParameterTypes.hpp b/include/fastdds/dds/core/policy/ParameterTypes.hpp index ba68867dcb1..3fc0a760456 100644 --- a/include/fastdds/dds/core/policy/ParameterTypes.hpp +++ b/include/fastdds/dds/core/policy/ParameterTypes.hpp @@ -21,20 +21,20 @@ #ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC +#include +#include + +#include + #include #include #include -#include - #if HAVE_SECURITY #include #include #endif // if HAVE_SECURITY -#include -#include - namespace eprosima { namespace fastrtps { @@ -174,7 +174,7 @@ class Parameter_t /** * @brief Constructor without parameters */ - RTPS_DllAPI Parameter_t() + FASTDDS_EXPORTED_API Parameter_t() : Pid(PID_PAD) , length(0) { @@ -186,7 +186,7 @@ class Parameter_t * @param pid Pid of the parameter * @param length Its associated length */ - RTPS_DllAPI Parameter_t( + FASTDDS_EXPORTED_API Parameter_t( ParameterId_t pid, uint16_t length) : Pid(pid) @@ -197,7 +197,7 @@ class Parameter_t /** * @brief Destructor */ - virtual RTPS_DllAPI ~Parameter_t() + virtual FASTDDS_EXPORTED_API ~Parameter_t() { } @@ -352,7 +352,7 @@ class ParameterString_t : public Parameter_t ParameterString_t( ParameterId_t pid, uint16_t in_length, - const fastrtps::string_255& strin) + const fastcdr::string_255& strin) : Parameter_t(pid, in_length) , string_(strin) { @@ -392,7 +392,7 @@ class ParameterString_t : public Parameter_t private: //!Name.
    By default, empty string. - fastrtps::string_255 string_; + fastcdr::string_255 string_; }; /** diff --git a/include/fastdds/dds/core/policy/QosPolicies.hpp b/include/fastdds/dds/core/policy/QosPolicies.hpp index 26b5c0b6ac9..b28c77f6137 100644 --- a/include/fastdds/dds/core/policy/QosPolicies.hpp +++ b/include/fastdds/dds/core/policy/QosPolicies.hpp @@ -20,9 +20,12 @@ #ifndef _FASTDDS_DDS_QOS_QOSPOLICIES_HPP_ #define _FASTDDS_DDS_QOS_QOSPOLICIES_HPP_ +#include #include #include +#include +#include #include #include #include @@ -35,8 +38,7 @@ #include #include -#include -#include +#include namespace eprosima { namespace fastdds { @@ -195,7 +197,7 @@ class EntityFactoryQosPolicy /** * @brief Constructor without parameters */ - RTPS_DllAPI EntityFactoryQosPolicy() + FASTDDS_EXPORTED_API EntityFactoryQosPolicy() : autoenable_created_entities(true) { } @@ -205,7 +207,7 @@ class EntityFactoryQosPolicy * * @param autoenable Value for the autoenable_created_entities boolean */ - RTPS_DllAPI EntityFactoryQosPolicy( + FASTDDS_EXPORTED_API EntityFactoryQosPolicy( bool autoenable) : autoenable_created_entities(autoenable) { @@ -214,7 +216,7 @@ class EntityFactoryQosPolicy /** * @brief Destructor */ - virtual RTPS_DllAPI ~EntityFactoryQosPolicy() + virtual FASTDDS_EXPORTED_API ~EntityFactoryQosPolicy() { } @@ -277,7 +279,7 @@ class DurabilityQosPolicy : public Parameter_t, public QosPolicy /** * @brief Constructor */ - RTPS_DllAPI DurabilityQosPolicy() + FASTDDS_EXPORTED_API DurabilityQosPolicy() : Parameter_t(PID_DURABILITY, PARAMETER_KIND_LENGTH) , QosPolicy(true) , kind(VOLATILE_DURABILITY_QOS) @@ -287,7 +289,7 @@ class DurabilityQosPolicy : public Parameter_t, public QosPolicy /** * @brief Destructor */ - virtual RTPS_DllAPI ~DurabilityQosPolicy() = default; + virtual FASTDDS_EXPORTED_API ~DurabilityQosPolicy() = default; /** * Translates kind to rtps layer equivalent @@ -362,7 +364,7 @@ class DeadlineQosPolicy : public Parameter_t, public QosPolicy /** * @brief Constructor */ - RTPS_DllAPI DeadlineQosPolicy() + FASTDDS_EXPORTED_API DeadlineQosPolicy() : Parameter_t(PID_DEADLINE, PARAMETER_TIME_LENGTH) , QosPolicy(true) , period(TIME_T_INFINITE_SECONDS, TIME_T_INFINITE_NANOSECONDS) @@ -372,7 +374,7 @@ class DeadlineQosPolicy : public Parameter_t, public QosPolicy /** * @brief Destructor */ - virtual RTPS_DllAPI ~DeadlineQosPolicy() = default; + virtual FASTDDS_EXPORTED_API ~DeadlineQosPolicy() = default; bool operator ==( const DeadlineQosPolicy& b) const @@ -415,7 +417,7 @@ class LatencyBudgetQosPolicy : public Parameter_t, public QosPolicy /** * @brief Constructor */ - RTPS_DllAPI LatencyBudgetQosPolicy() + FASTDDS_EXPORTED_API LatencyBudgetQosPolicy() : Parameter_t(PID_LATENCY_BUDGET, PARAMETER_TIME_LENGTH) , QosPolicy(true) , duration(0, 0) @@ -425,7 +427,7 @@ class LatencyBudgetQosPolicy : public Parameter_t, public QosPolicy /** * @brief Destructor */ - virtual RTPS_DllAPI ~LatencyBudgetQosPolicy() = default; + virtual FASTDDS_EXPORTED_API ~LatencyBudgetQosPolicy() = default; bool operator ==( const LatencyBudgetQosPolicy& b) const @@ -487,7 +489,7 @@ class LivelinessQosPolicy : public Parameter_t, public QosPolicy /** * @brief Constructor */ - RTPS_DllAPI LivelinessQosPolicy() + FASTDDS_EXPORTED_API LivelinessQosPolicy() : Parameter_t(PID_LIVELINESS, PARAMETER_KIND_LENGTH + PARAMETER_TIME_LENGTH) , QosPolicy(true) , kind(AUTOMATIC_LIVELINESS_QOS) @@ -499,7 +501,7 @@ class LivelinessQosPolicy : public Parameter_t, public QosPolicy /** * @brief Destructor */ - virtual RTPS_DllAPI ~LivelinessQosPolicy() = default; + virtual FASTDDS_EXPORTED_API ~LivelinessQosPolicy() = default; bool operator ==( const LivelinessQosPolicy& b) const @@ -569,7 +571,7 @@ class ReliabilityQosPolicy : public Parameter_t, public QosPolicy /** * @brief Constructor */ - RTPS_DllAPI ReliabilityQosPolicy() + FASTDDS_EXPORTED_API ReliabilityQosPolicy() : Parameter_t(PID_RELIABILITY, PARAMETER_KIND_LENGTH + PARAMETER_TIME_LENGTH) , QosPolicy(true) //indicate send always , kind(BEST_EFFORT_RELIABILITY_QOS) @@ -580,7 +582,7 @@ class ReliabilityQosPolicy : public Parameter_t, public QosPolicy /** * @brief Destructor */ - virtual RTPS_DllAPI ~ReliabilityQosPolicy() = default; + virtual FASTDDS_EXPORTED_API ~ReliabilityQosPolicy() = default; bool operator ==( const ReliabilityQosPolicy& b) const @@ -651,7 +653,7 @@ class OwnershipQosPolicy : public Parameter_t, public QosPolicy /** * @brief Constructor */ - RTPS_DllAPI OwnershipQosPolicy() + FASTDDS_EXPORTED_API OwnershipQosPolicy() : Parameter_t(PID_OWNERSHIP, PARAMETER_KIND_LENGTH) , QosPolicy(true) , kind(SHARED_OWNERSHIP_QOS) @@ -661,7 +663,7 @@ class OwnershipQosPolicy : public Parameter_t, public QosPolicy /** * @brief Destructor */ - virtual RTPS_DllAPI ~OwnershipQosPolicy() = default; + virtual FASTDDS_EXPORTED_API ~OwnershipQosPolicy() = default; bool operator ==( const OwnershipQosPolicy& b) const @@ -718,7 +720,7 @@ class DestinationOrderQosPolicy : public Parameter_t, public QosPolicy /** * @brief Constructor */ - RTPS_DllAPI DestinationOrderQosPolicy() + FASTDDS_EXPORTED_API DestinationOrderQosPolicy() : Parameter_t(PID_DESTINATION_ORDER, PARAMETER_KIND_LENGTH) , QosPolicy(true) , kind(BY_RECEPTION_TIMESTAMP_DESTINATIONORDER_QOS) @@ -728,7 +730,7 @@ class DestinationOrderQosPolicy : public Parameter_t, public QosPolicy /** * @brief Destructor */ - virtual RTPS_DllAPI ~DestinationOrderQosPolicy() = default; + virtual FASTDDS_EXPORTED_API ~DestinationOrderQosPolicy() = default; bool operator ==( const DestinationOrderQosPolicy& b) const @@ -761,7 +763,7 @@ class GenericDataQosPolicy : public Parameter_t, public QosPolicy, public: - RTPS_DllAPI GenericDataQosPolicy( + FASTDDS_EXPORTED_API GenericDataQosPolicy( ParameterId_t pid) : Parameter_t(pid, 0) , QosPolicy(false) @@ -769,7 +771,7 @@ class GenericDataQosPolicy : public Parameter_t, public QosPolicy, { } - RTPS_DllAPI GenericDataQosPolicy( + FASTDDS_EXPORTED_API GenericDataQosPolicy( ParameterId_t pid, uint16_t in_length) : Parameter_t(pid, in_length) @@ -786,7 +788,7 @@ class GenericDataQosPolicy : public Parameter_t, public QosPolicy, * * @param data data to copy in the newly created object */ - RTPS_DllAPI GenericDataQosPolicy( + FASTDDS_EXPORTED_API GenericDataQosPolicy( const GenericDataQosPolicy& data) : Parameter_t(data.Pid, data.length) , QosPolicy(false) @@ -803,7 +805,7 @@ class GenericDataQosPolicy : public Parameter_t, public QosPolicy, * @param pid Id of the parameter * @param data data to copy in the newly created object */ - RTPS_DllAPI GenericDataQosPolicy( + FASTDDS_EXPORTED_API GenericDataQosPolicy( ParameterId_t pid, const collection_type& data) : Parameter_t(pid, 0) @@ -814,7 +816,7 @@ class GenericDataQosPolicy : public Parameter_t, public QosPolicy, length = static_cast((size() + 7u) & ~3u); } - virtual RTPS_DllAPI ~GenericDataQosPolicy() = default; + virtual FASTDDS_EXPORTED_API ~GenericDataQosPolicy() = default; /** * Copies data from underlying collection type. @@ -919,7 +921,7 @@ class GenericDataQosPolicy : public Parameter_t, public QosPolicy, * * @return raw data as vector of octets. * */ - RTPS_DllAPI inline const collection_type& data_vec() const + FASTDDS_EXPORTED_API inline const collection_type& data_vec() const { return collection_; } @@ -929,7 +931,7 @@ class GenericDataQosPolicy : public Parameter_t, public QosPolicy, * * @return raw data as vector of octets. * */ - RTPS_DllAPI inline collection_type& data_vec() + FASTDDS_EXPORTED_API inline collection_type& data_vec() { return collection_; } @@ -939,7 +941,7 @@ class GenericDataQosPolicy : public Parameter_t, public QosPolicy, * * @param vec raw data to set. * */ - RTPS_DllAPI inline void data_vec( + FASTDDS_EXPORTED_API inline void data_vec( const collection_type& vec) { if (collection_ != vec) @@ -955,7 +957,7 @@ class GenericDataQosPolicy : public Parameter_t, public QosPolicy, * * @return raw data as vector of octets. * */ - RTPS_DllAPI inline const collection_type& getValue() const + FASTDDS_EXPORTED_API inline const collection_type& getValue() const { return collection_; } @@ -965,7 +967,7 @@ class GenericDataQosPolicy : public Parameter_t, public QosPolicy, * * @param vec raw data to set. * */ - RTPS_DllAPI inline void setValue( + FASTDDS_EXPORTED_API inline void setValue( const collection_type& vec) { data_vec(vec); @@ -986,12 +988,12 @@ class GenericDataQosPolicy : public Parameter_t, public QosPolicy, { \ public: \ \ - RTPS_DllAPI TClassName() \ + FASTDDS_EXPORTED_API TClassName() \ : GenericDataQosPolicy(TPid) \ { \ } \ \ - RTPS_DllAPI TClassName( \ + FASTDDS_EXPORTED_API TClassName( \ uint16_t in_length) \ : GenericDataQosPolicy(TPid, in_length) \ { \ @@ -1005,7 +1007,7 @@ class GenericDataQosPolicy : public Parameter_t, public QosPolicy, * \ * @param data data to copy in the newly created object \ */ \ - RTPS_DllAPI TClassName( \ + FASTDDS_EXPORTED_API TClassName( \ const TClassName &data) = default; \ \ /** \ @@ -1016,13 +1018,13 @@ class GenericDataQosPolicy : public Parameter_t, public QosPolicy, * \ * @param data data to copy in the newly created object \ */ \ - RTPS_DllAPI TClassName( \ + FASTDDS_EXPORTED_API TClassName( \ const collection_type &data) \ : GenericDataQosPolicy(TPid, data) \ { \ } \ \ - virtual RTPS_DllAPI ~TClassName() = default; \ + virtual FASTDDS_EXPORTED_API ~TClassName() = default; \ \ /** \ * Copies another TClassName. \ @@ -1103,7 +1105,7 @@ class TimeBasedFilterQosPolicy : public Parameter_t, public QosPolicy /** * @brief Constructor */ - RTPS_DllAPI TimeBasedFilterQosPolicy() + FASTDDS_EXPORTED_API TimeBasedFilterQosPolicy() : Parameter_t(PID_TIME_BASED_FILTER, PARAMETER_TIME_LENGTH) , QosPolicy(false) , minimum_separation(0, 0) @@ -1113,7 +1115,7 @@ class TimeBasedFilterQosPolicy : public Parameter_t, public QosPolicy /** * @brief Destructor */ - virtual RTPS_DllAPI ~TimeBasedFilterQosPolicy() = default; + virtual FASTDDS_EXPORTED_API ~TimeBasedFilterQosPolicy() = default; bool operator ==( const TimeBasedFilterQosPolicy& b) const @@ -1177,7 +1179,7 @@ class PresentationQosPolicy : public Parameter_t, public QosPolicy /** * @brief Constructor without parameters */ - RTPS_DllAPI PresentationQosPolicy() + FASTDDS_EXPORTED_API PresentationQosPolicy() : Parameter_t(PID_PRESENTATION, PARAMETER_PRESENTATION_LENGTH) , QosPolicy(false) , access_scope(INSTANCE_PRESENTATION_QOS) @@ -1189,7 +1191,7 @@ class PresentationQosPolicy : public Parameter_t, public QosPolicy /** * @brief Destructor */ - virtual RTPS_DllAPI ~PresentationQosPolicy() = default; + virtual FASTDDS_EXPORTED_API ~PresentationQosPolicy() = default; bool operator ==( const PresentationQosPolicy& b) const @@ -1390,7 +1392,7 @@ class PartitionQosPolicy : public Parameter_t, public QosPolicy /** * @brief Constructor without parameters */ - RTPS_DllAPI PartitionQosPolicy() + FASTDDS_EXPORTED_API PartitionQosPolicy() : Parameter_t(PID_PARTITION, 0) , QosPolicy(false) , max_size_ (0) @@ -1403,7 +1405,7 @@ class PartitionQosPolicy : public Parameter_t, public QosPolicy * * @param in_length Length of the parameter */ - RTPS_DllAPI PartitionQosPolicy( + FASTDDS_EXPORTED_API PartitionQosPolicy( uint16_t in_length) : Parameter_t(PID_PARTITION, in_length) , QosPolicy(false) @@ -1418,7 +1420,7 @@ class PartitionQosPolicy : public Parameter_t, public QosPolicy * * @param b Another PartitionQosPolicy instance */ - RTPS_DllAPI PartitionQosPolicy( + FASTDDS_EXPORTED_API PartitionQosPolicy( const PartitionQosPolicy& b) : Parameter_t(b) , QosPolicy(b) @@ -1434,7 +1436,7 @@ class PartitionQosPolicy : public Parameter_t, public QosPolicy /** * @brief Destructor */ - virtual RTPS_DllAPI ~PartitionQosPolicy() = default; + virtual FASTDDS_EXPORTED_API ~PartitionQosPolicy() = default; bool operator ==( const PartitionQosPolicy& b) const @@ -1528,7 +1530,7 @@ class PartitionQosPolicy : public Parameter_t, public QosPolicy * * @param name Name to append. */ - RTPS_DllAPI inline void push_back( + FASTDDS_EXPORTED_API inline void push_back( const char* name) { //Realloc if needed; @@ -1560,7 +1562,7 @@ class PartitionQosPolicy : public Parameter_t, public QosPolicy /** * Clears list of partition names */ - RTPS_DllAPI inline void clear() override + FASTDDS_EXPORTED_API inline void clear() override { partitions_.length = 0; Npartitions_ = 0; @@ -1572,7 +1574,7 @@ class PartitionQosPolicy : public Parameter_t, public QosPolicy * * @return Vector of partition name strings. */ - RTPS_DllAPI inline const std::vector getNames() const + FASTDDS_EXPORTED_API inline const std::vector getNames() const { return names(); } @@ -1582,7 +1584,7 @@ class PartitionQosPolicy : public Parameter_t, public QosPolicy * * @param nam Vector of partition name strings. */ - RTPS_DllAPI inline void setNames( + FASTDDS_EXPORTED_API inline void setNames( std::vector& nam) { names(nam); @@ -1593,7 +1595,7 @@ class PartitionQosPolicy : public Parameter_t, public QosPolicy * * @return Vector of partition name strings. */ - RTPS_DllAPI inline const std::vector names() const + FASTDDS_EXPORTED_API inline const std::vector names() const { std::vector names; if (Npartitions_ > 0) @@ -1611,7 +1613,7 @@ class PartitionQosPolicy : public Parameter_t, public QosPolicy * * @param nam Vector of partition name strings. */ - RTPS_DllAPI inline void names( + FASTDDS_EXPORTED_API inline void names( std::vector& nam) { clear(); @@ -1672,7 +1674,7 @@ class HistoryQosPolicy : public Parameter_t, public QosPolicy /** * @brief Constructor */ - RTPS_DllAPI HistoryQosPolicy() + FASTDDS_EXPORTED_API HistoryQosPolicy() : Parameter_t(PID_HISTORY, PARAMETER_KIND_LENGTH + 4) , QosPolicy(true) , kind(KEEP_LAST_HISTORY_QOS) @@ -1683,7 +1685,7 @@ class HistoryQosPolicy : public Parameter_t, public QosPolicy /** * @brief Destructor */ - virtual RTPS_DllAPI ~HistoryQosPolicy() = default; + virtual FASTDDS_EXPORTED_API ~HistoryQosPolicy() = default; bool operator ==( const HistoryQosPolicy& b) const @@ -1712,9 +1714,6 @@ class HistoryQosPolicy : public Parameter_t, public QosPolicy int32_t depth; }; -//! A special value indicating an unlimited quantity -constexpr int32_t LENGTH_UNLIMITED = -1; - /** * Specifies the resources that the Service can consume in order to meet the requested QoS * @@ -1761,7 +1760,7 @@ class ResourceLimitsQosPolicy : public Parameter_t, public QosPolicy /** * @brief Constructor */ - RTPS_DllAPI ResourceLimitsQosPolicy() + FASTDDS_EXPORTED_API ResourceLimitsQosPolicy() : Parameter_t(PID_RESOURCE_LIMITS, 4 + 4 + 4) , QosPolicy(false) , max_samples(5000) @@ -1775,7 +1774,7 @@ class ResourceLimitsQosPolicy : public Parameter_t, public QosPolicy /** * @brief Destructor */ - virtual RTPS_DllAPI ~ResourceLimitsQosPolicy() = default; + virtual FASTDDS_EXPORTED_API ~ResourceLimitsQosPolicy() = default; bool operator ==( const ResourceLimitsQosPolicy& b) const @@ -1813,7 +1812,7 @@ class DurabilityServiceQosPolicy : public Parameter_t, public QosPolicy /** * @brief Constructor */ - RTPS_DllAPI DurabilityServiceQosPolicy() + FASTDDS_EXPORTED_API DurabilityServiceQosPolicy() : Parameter_t(PID_DURABILITY_SERVICE, PARAMETER_TIME_LENGTH + PARAMETER_KIND_LENGTH + 4 + 4 + 4 + 4) , QosPolicy(false) , history_kind(KEEP_LAST_HISTORY_QOS) @@ -1827,7 +1826,7 @@ class DurabilityServiceQosPolicy : public Parameter_t, public QosPolicy /** * @brief Destructor */ - virtual RTPS_DllAPI ~DurabilityServiceQosPolicy() = default; + virtual FASTDDS_EXPORTED_API ~DurabilityServiceQosPolicy() = default; bool operator ==( const DurabilityServiceQosPolicy& b) const @@ -1901,7 +1900,7 @@ class LifespanQosPolicy : public Parameter_t, public QosPolicy /** * @brief Constructor */ - RTPS_DllAPI LifespanQosPolicy() + FASTDDS_EXPORTED_API LifespanQosPolicy() : Parameter_t(PID_LIFESPAN, PARAMETER_TIME_LENGTH) , QosPolicy(true) , duration(TIME_T_INFINITE_SECONDS, TIME_T_INFINITE_NANOSECONDS) @@ -1911,7 +1910,7 @@ class LifespanQosPolicy : public Parameter_t, public QosPolicy /** * @brief Destructor */ - virtual RTPS_DllAPI ~LifespanQosPolicy() = default; + virtual FASTDDS_EXPORTED_API ~LifespanQosPolicy() = default; bool operator ==( const LifespanQosPolicy& b) const @@ -1947,7 +1946,7 @@ class OwnershipStrengthQosPolicy : public Parameter_t, public QosPolicy /** * @brief Constructor */ - RTPS_DllAPI OwnershipStrengthQosPolicy() + FASTDDS_EXPORTED_API OwnershipStrengthQosPolicy() : Parameter_t(PID_OWNERSHIP_STRENGTH, 4) , QosPolicy(false) , value(0) @@ -1957,7 +1956,7 @@ class OwnershipStrengthQosPolicy : public Parameter_t, public QosPolicy /** * @brief Destructor */ - virtual RTPS_DllAPI ~OwnershipStrengthQosPolicy() = default; + virtual FASTDDS_EXPORTED_API ~OwnershipStrengthQosPolicy() = default; bool operator ==( const OwnershipStrengthQosPolicy& b) const @@ -1997,7 +1996,7 @@ class TransportPriorityQosPolicy : public Parameter_t, public QosPolicy /** * @brief Constructor */ - RTPS_DllAPI TransportPriorityQosPolicy() + FASTDDS_EXPORTED_API TransportPriorityQosPolicy() : Parameter_t(PID_TRANSPORT_PRIORITY, 4) , QosPolicy(false) , value(0) @@ -2007,7 +2006,7 @@ class TransportPriorityQosPolicy : public Parameter_t, public QosPolicy /** * @brief Destructor */ - virtual RTPS_DllAPI ~TransportPriorityQosPolicy() = default; + virtual FASTDDS_EXPORTED_API ~TransportPriorityQosPolicy() = default; bool operator ==( const TransportPriorityQosPolicy& b) const @@ -2099,7 +2098,7 @@ class DataRepresentationQosPolicy : public Parameter_t, public QosPolicy /** * @brief Constructor */ - RTPS_DllAPI DataRepresentationQosPolicy() + FASTDDS_EXPORTED_API DataRepresentationQosPolicy() : Parameter_t(PID_DATA_REPRESENTATION, 0) , QosPolicy(false) { @@ -2108,7 +2107,7 @@ class DataRepresentationQosPolicy : public Parameter_t, public QosPolicy /** * @brief Destructor */ - virtual RTPS_DllAPI ~DataRepresentationQosPolicy() override = default; + virtual FASTDDS_EXPORTED_API ~DataRepresentationQosPolicy() override = default; /** * Compares the given policy to check if it's equal. @@ -2198,7 +2197,7 @@ class TypeConsistencyEnforcementQosPolicy : public Parameter_t, public QosPolicy /** * @brief Constructor */ - RTPS_DllAPI TypeConsistencyEnforcementQosPolicy() + FASTDDS_EXPORTED_API TypeConsistencyEnforcementQosPolicy() : Parameter_t(PID_TYPE_CONSISTENCY_ENFORCEMENT, 8) // 2 + 5 + 1 alignment byte , QosPolicy(true) { @@ -2213,7 +2212,7 @@ class TypeConsistencyEnforcementQosPolicy : public Parameter_t, public QosPolicy /** * @brief Destructor */ - virtual RTPS_DllAPI ~TypeConsistencyEnforcementQosPolicy() override = default; + virtual FASTDDS_EXPORTED_API ~TypeConsistencyEnforcementQosPolicy() override = default; bool operator ==( const TypeConsistencyEnforcementQosPolicy& b) const @@ -2248,7 +2247,7 @@ class DisablePositiveACKsQosPolicy : public Parameter_t, public QosPolicy /** * @brief Constructor */ - RTPS_DllAPI DisablePositiveACKsQosPolicy() + FASTDDS_EXPORTED_API DisablePositiveACKsQosPolicy() : Parameter_t(PID_DISABLE_POSITIVE_ACKS, PARAMETER_BOOL_LENGTH) , QosPolicy(true) , enabled(false) @@ -2259,7 +2258,7 @@ class DisablePositiveACKsQosPolicy : public Parameter_t, public QosPolicy /** * @brief Destructor */ - virtual RTPS_DllAPI ~DisablePositiveACKsQosPolicy() = default; + virtual FASTDDS_EXPORTED_API ~DisablePositiveACKsQosPolicy() = default; bool operator ==( const DisablePositiveACKsQosPolicy& b) const @@ -2292,13 +2291,13 @@ class TypeIdV1 : public Parameter_t, public QosPolicy public: //!Type Identifier - fastrtps::types::TypeIdentifier m_type_identifier; + xtypes::TypeIdentifier m_type_identifier; /** * @brief Constructor without parameters */ - RTPS_DllAPI TypeIdV1() + FASTDDS_EXPORTED_API TypeIdV1() : Parameter_t(PID_TYPE_IDV1, 0) , QosPolicy(false) , m_type_identifier() @@ -2310,7 +2309,7 @@ class TypeIdV1 : public Parameter_t, public QosPolicy * * @param type Another instance of TypeIdV1 */ - RTPS_DllAPI TypeIdV1( + FASTDDS_EXPORTED_API TypeIdV1( const TypeIdV1& type) : Parameter_t(type.Pid, type.length) , QosPolicy(type.send_always_) @@ -2323,8 +2322,8 @@ class TypeIdV1 : public Parameter_t, public QosPolicy * * @param identifier TypeIdentifier to be set */ - RTPS_DllAPI TypeIdV1( - const fastrtps::types::TypeIdentifier& identifier) + FASTDDS_EXPORTED_API TypeIdV1( + const xtypes::TypeIdentifier& identifier) : Parameter_t(PID_TYPE_IDV1, 0) , QosPolicy(false) , m_type_identifier(identifier) @@ -2336,7 +2335,7 @@ class TypeIdV1 : public Parameter_t, public QosPolicy * * @param type Another instance of TypeIdV1 */ - RTPS_DllAPI TypeIdV1( + FASTDDS_EXPORTED_API TypeIdV1( TypeIdV1&& type) : Parameter_t(type.Pid, type.length) , QosPolicy(type.send_always_) @@ -2344,7 +2343,7 @@ class TypeIdV1 : public Parameter_t, public QosPolicy { } - RTPS_DllAPI TypeIdV1& operator =( + FASTDDS_EXPORTED_API TypeIdV1& operator =( const TypeIdV1& type) { Pid = type.Pid; @@ -2356,7 +2355,7 @@ class TypeIdV1 : public Parameter_t, public QosPolicy return *this; } - RTPS_DllAPI TypeIdV1& operator =( + FASTDDS_EXPORTED_API TypeIdV1& operator =( TypeIdV1&& type) { Pid = type.Pid; @@ -2371,15 +2370,15 @@ class TypeIdV1 : public Parameter_t, public QosPolicy /** * @brief Destructor */ - virtual RTPS_DllAPI ~TypeIdV1() override = default; + virtual FASTDDS_EXPORTED_API ~TypeIdV1() override = default; inline void clear() override { *this = TypeIdV1(); } - RTPS_DllAPI TypeIdV1& operator =( - const fastrtps::types::TypeIdentifier& type_id) + FASTDDS_EXPORTED_API TypeIdV1& operator =( + const xtypes::TypeIdentifier& type_id) { m_type_identifier = type_id; return *this; @@ -2390,7 +2389,7 @@ class TypeIdV1 : public Parameter_t, public QosPolicy * * @return TypeIdentifier reference */ - RTPS_DllAPI const fastrtps::types::TypeIdentifier& get() const + FASTDDS_EXPORTED_API const xtypes::TypeIdentifier& get() const { return m_type_identifier; } @@ -2405,12 +2404,12 @@ class TypeObjectV1 : public Parameter_t, public QosPolicy public: //!Type Object - fastrtps::types::TypeObject m_type_object; + xtypes::TypeObject m_type_object; /** * @brief Constructor */ - RTPS_DllAPI TypeObjectV1() + FASTDDS_EXPORTED_API TypeObjectV1() : Parameter_t(PID_TYPE_OBJECTV1, 0) , QosPolicy(false) , m_type_object() @@ -2422,7 +2421,7 @@ class TypeObjectV1 : public Parameter_t, public QosPolicy * * @param type Another instance of TypeObjectV1 */ - RTPS_DllAPI TypeObjectV1( + FASTDDS_EXPORTED_API TypeObjectV1( const TypeObjectV1& type) : Parameter_t(type.Pid, type.length) , QosPolicy(type.send_always_) @@ -2435,8 +2434,8 @@ class TypeObjectV1 : public Parameter_t, public QosPolicy * * @param type TypeObject to be set */ - RTPS_DllAPI TypeObjectV1( - const fastrtps::types::TypeObject& type) + FASTDDS_EXPORTED_API TypeObjectV1( + const xtypes::TypeObject& type) : Parameter_t(PID_TYPE_OBJECTV1, 0) , QosPolicy(false) , m_type_object(type) @@ -2448,7 +2447,7 @@ class TypeObjectV1 : public Parameter_t, public QosPolicy * * @param type Another instance of TypeObjectV1 */ - RTPS_DllAPI TypeObjectV1( + FASTDDS_EXPORTED_API TypeObjectV1( TypeObjectV1&& type) : Parameter_t(type.Pid, type.length) , QosPolicy(type.send_always_) @@ -2456,7 +2455,7 @@ class TypeObjectV1 : public Parameter_t, public QosPolicy { } - RTPS_DllAPI TypeObjectV1& operator =( + FASTDDS_EXPORTED_API TypeObjectV1& operator =( const TypeObjectV1& type) { Pid = type.Pid; @@ -2468,7 +2467,7 @@ class TypeObjectV1 : public Parameter_t, public QosPolicy return *this; } - RTPS_DllAPI TypeObjectV1& operator =( + FASTDDS_EXPORTED_API TypeObjectV1& operator =( TypeObjectV1&& type) { Pid = type.Pid; @@ -2483,15 +2482,15 @@ class TypeObjectV1 : public Parameter_t, public QosPolicy /** * @brief Destructor */ - virtual RTPS_DllAPI ~TypeObjectV1() override = default; + virtual FASTDDS_EXPORTED_API ~TypeObjectV1() override = default; inline void clear() override { *this = TypeObjectV1(); } - RTPS_DllAPI TypeObjectV1& operator =( - const fastrtps::types::TypeObject& type_object) + FASTDDS_EXPORTED_API TypeObjectV1& operator =( + const xtypes::TypeObject& type_object) { m_type_object = type_object; return *this; @@ -2502,7 +2501,7 @@ class TypeObjectV1 : public Parameter_t, public QosPolicy * * @return TypeObject reference */ - RTPS_DllAPI const fastrtps::types::TypeObject& get() const + FASTDDS_EXPORTED_API const xtypes::TypeObject& get() const { return m_type_object; } @@ -2512,19 +2511,19 @@ class TypeObjectV1 : public Parameter_t, public QosPolicy namespace xtypes { /** - * Class xtypes::TypeInformation + * Class xtypes::TypeInformationParameter */ -class TypeInformation : public Parameter_t, public QosPolicy +class TypeInformationParameter : public Parameter_t, public QosPolicy { public: //!Type Information - fastrtps::types::TypeInformation type_information; + eprosima::fastdds::dds::xtypes::TypeInformation type_information; /** * @brief Constructor */ - RTPS_DllAPI TypeInformation() + FASTDDS_EXPORTED_API TypeInformationParameter() : Parameter_t(PID_TYPE_INFORMATION, 0) , QosPolicy(false) , type_information() @@ -2535,10 +2534,10 @@ class TypeInformation : public Parameter_t, public QosPolicy /** * @brief Copy constructor * - * @param type Another instance of TypeInformation + * @param type Another instance of TypeInformationParameter */ - RTPS_DllAPI TypeInformation( - const TypeInformation& type) + FASTDDS_EXPORTED_API TypeInformationParameter( + const TypeInformationParameter& type) : Parameter_t(type.Pid, type.length) , QosPolicy(type.send_always_) , type_information(type.type_information) @@ -2547,12 +2546,12 @@ class TypeInformation : public Parameter_t, public QosPolicy } /** - * @brief Constructor using a fastrtps::types::TypeInformation + * @brief Constructor using a TypeInformation * - * @param info fastrtps::types::TypeInformation to be set + * @param info TypeInformation to be set */ - RTPS_DllAPI TypeInformation( - const fastrtps::types::TypeInformation& info) + FASTDDS_EXPORTED_API TypeInformationParameter( + const eprosima::fastdds::dds::xtypes::TypeInformation& info) : Parameter_t(PID_TYPE_INFORMATION, 0) , QosPolicy(false) , type_information(info) @@ -2563,10 +2562,10 @@ class TypeInformation : public Parameter_t, public QosPolicy /** * @brief Move Constructor * - * @param type Another instance of TypeInformation + * @param type Another instance of TypeInformationParameter */ - RTPS_DllAPI TypeInformation( - TypeInformation&& type) + FASTDDS_EXPORTED_API TypeInformationParameter( + TypeInformationParameter&& type) : Parameter_t(type.Pid, type.length) , QosPolicy(type.send_always_) , type_information(std::move(type.type_information)) @@ -2574,8 +2573,8 @@ class TypeInformation : public Parameter_t, public QosPolicy { } - RTPS_DllAPI TypeInformation& operator =( - const TypeInformation& type) + FASTDDS_EXPORTED_API TypeInformationParameter& operator =( + const TypeInformationParameter& type) { Pid = type.Pid; length = type.length; @@ -2587,8 +2586,8 @@ class TypeInformation : public Parameter_t, public QosPolicy return *this; } - RTPS_DllAPI TypeInformation& operator =( - TypeInformation&& type) + FASTDDS_EXPORTED_API TypeInformationParameter& operator =( + TypeInformationParameter&& type) { Pid = type.Pid; length = type.length; @@ -2603,11 +2602,11 @@ class TypeInformation : public Parameter_t, public QosPolicy /** * @brief Destructor */ - virtual RTPS_DllAPI ~TypeInformation() override = default; + virtual FASTDDS_EXPORTED_API ~TypeInformationParameter() override = default; inline void clear() override { - *this = TypeInformation(); + *this = TypeInformationParameter(); } /** @@ -2615,7 +2614,7 @@ class TypeInformation : public Parameter_t, public QosPolicy * * @return true if assigned, false if not */ - RTPS_DllAPI bool assigned() const + FASTDDS_EXPORTED_API bool assigned() const { return assigned_; } @@ -2625,14 +2624,14 @@ class TypeInformation : public Parameter_t, public QosPolicy * * @param value Boolean to be set */ - RTPS_DllAPI void assigned( + FASTDDS_EXPORTED_API void assigned( bool value) { assigned_ = value; } - RTPS_DllAPI TypeInformation& operator =( - const fastrtps::types::TypeInformation& type_info) + FASTDDS_EXPORTED_API TypeInformationParameter& operator =( + const TypeInformation& type_info) { type_information = type_info; assigned_ = true; @@ -2641,7 +2640,7 @@ class TypeInformation : public Parameter_t, public QosPolicy private: - //!Boolean that states if the TypeInformation has been asigned manually or not. + //!Boolean that states if the TypeInformationParameter has been asigned manually or not. bool assigned_; }; @@ -2662,7 +2661,7 @@ class WireProtocolConfigQos : public QosPolicy /** * @brief Constructor */ - RTPS_DllAPI WireProtocolConfigQos() + FASTDDS_EXPORTED_API WireProtocolConfigQos() : QosPolicy(false) , participant_id(-1) { @@ -2671,7 +2670,7 @@ class WireProtocolConfigQos : public QosPolicy /** * @brief Destructor */ - virtual RTPS_DllAPI ~WireProtocolConfigQos() = default; + virtual FASTDDS_EXPORTED_API ~WireProtocolConfigQos() = default; bool operator ==( const WireProtocolConfigQos& b) const @@ -2744,7 +2743,7 @@ class TransportConfigQos : public QosPolicy /** * @brief Constructor */ - RTPS_DllAPI TransportConfigQos() + FASTDDS_EXPORTED_API TransportConfigQos() : QosPolicy(false) , use_builtin_transports(true) , send_socket_buffer_size(0) @@ -2757,7 +2756,7 @@ class TransportConfigQos : public QosPolicy /** * @brief Destructor */ - virtual RTPS_DllAPI ~TransportConfigQos() = default; + virtual FASTDDS_EXPORTED_API ~TransportConfigQos() = default; bool operator ==( const TransportConfigQos& b) const @@ -2798,8 +2797,10 @@ class TransportConfigQos : public QosPolicy //! Thread settings for the builtin transports reception threads rtps::ThreadSettings builtin_transports_reception_threads_; - /*! Maximum message size used to avoid fragmentation, set ONLY in LARGE_DATA. If this value is - * not zero, the network factory will allow the initialization of UDP transports with maxMessageSize + /*! + * @brief Maximum message size used to avoid fragmentation, set ONLY in LARGE_DATA. + * + * If this value is not zero, the network factory will allow the initialization of UDP transports with maxMessageSize * higher than 65500K. */ uint32_t max_msg_size_no_frag; @@ -2813,9 +2814,9 @@ class RTPSEndpointQos { public: - RTPS_DllAPI RTPSEndpointQos() = default; + FASTDDS_EXPORTED_API RTPSEndpointQos() = default; - virtual RTPS_DllAPI ~RTPSEndpointQos() = default; + virtual FASTDDS_EXPORTED_API ~RTPSEndpointQos() = default; bool operator ==( const RTPSEndpointQos& b) const @@ -2864,7 +2865,7 @@ class WriterResourceLimitsQos /** * @brief Constructor */ - RTPS_DllAPI WriterResourceLimitsQos() + FASTDDS_EXPORTED_API WriterResourceLimitsQos() : matched_subscriber_allocation() , reader_filters_allocation(0, 32u, 1u) { @@ -2873,7 +2874,7 @@ class WriterResourceLimitsQos /** * @brief Destructor */ - virtual RTPS_DllAPI ~WriterResourceLimitsQos() = default; + virtual FASTDDS_EXPORTED_API ~WriterResourceLimitsQos() = default; bool operator ==( const WriterResourceLimitsQos& b) const @@ -2922,7 +2923,7 @@ class DataSharingQosPolicy : public Parameter_t, public QosPolicy /** * @brief Constructor */ - RTPS_DllAPI DataSharingQosPolicy() + FASTDDS_EXPORTED_API DataSharingQosPolicy() : Parameter_t(PID_DATASHARING, 0) , QosPolicy(true) { @@ -2933,14 +2934,14 @@ class DataSharingQosPolicy : public Parameter_t, public QosPolicy /** * @brief Destructor */ - virtual RTPS_DllAPI ~DataSharingQosPolicy() = default; + virtual FASTDDS_EXPORTED_API ~DataSharingQosPolicy() = default; /** * @brief Copy constructor * * @param b Another DataSharingQosPolicy instance */ - RTPS_DllAPI DataSharingQosPolicy( + FASTDDS_EXPORTED_API DataSharingQosPolicy( const DataSharingQosPolicy& b) : Parameter_t(b) , QosPolicy(b) @@ -2954,7 +2955,7 @@ class DataSharingQosPolicy : public Parameter_t, public QosPolicy domain_ids_ = b.domain_ids(); } - RTPS_DllAPI DataSharingQosPolicy& operator =( + FASTDDS_EXPORTED_API DataSharingQosPolicy& operator =( const DataSharingQosPolicy& b) { QosPolicy::operator =(b); @@ -2991,7 +2992,7 @@ class DataSharingQosPolicy : public Parameter_t, public QosPolicy /** * @return the current DataSharing configuration mode */ - RTPS_DllAPI const DataSharingKind& kind() const + FASTDDS_EXPORTED_API const DataSharingKind& kind() const { return kind_; } @@ -2999,7 +3000,7 @@ class DataSharingQosPolicy : public Parameter_t, public QosPolicy /** * @return the current DataSharing shared memory directory */ - RTPS_DllAPI const std::string& shm_directory() const + FASTDDS_EXPORTED_API const std::string& shm_directory() const { return shm_directory_; } @@ -3017,7 +3018,7 @@ class DataSharingQosPolicy : public Parameter_t, public QosPolicy * * @return the current DataSharing domain IDs */ - RTPS_DllAPI const std::vector& domain_ids() const + FASTDDS_EXPORTED_API const std::vector& domain_ids() const { return domain_ids_; } @@ -3025,7 +3026,7 @@ class DataSharingQosPolicy : public Parameter_t, public QosPolicy /** * @param size the new maximum number of domain IDs */ - RTPS_DllAPI void set_max_domains( + FASTDDS_EXPORTED_API void set_max_domains( uint32_t size) { domain_ids_.reserve(size); @@ -3035,7 +3036,7 @@ class DataSharingQosPolicy : public Parameter_t, public QosPolicy /** * @return the current configured maximum number of domain IDs */ - RTPS_DllAPI const uint32_t& max_domains() const + FASTDDS_EXPORTED_API const uint32_t& max_domains() const { return max_domains_; } @@ -3046,7 +3047,7 @@ class DataSharingQosPolicy : public Parameter_t, public QosPolicy * The default shared memory directory of the OS is used. * A default domain ID is automatically computed. */ - RTPS_DllAPI void automatic() + FASTDDS_EXPORTED_API void automatic() { setup (AUTO, "", std::vector()); } @@ -3058,7 +3059,7 @@ class DataSharingQosPolicy : public Parameter_t, public QosPolicy * * @param domain_ids the user configured DataSharing domain IDs (16 bits). */ - RTPS_DllAPI void automatic( + FASTDDS_EXPORTED_API void automatic( const std::vector& domain_ids) { setup (AUTO, "", domain_ids); @@ -3071,7 +3072,7 @@ class DataSharingQosPolicy : public Parameter_t, public QosPolicy * * @param directory The shared memory directory to use. */ - RTPS_DllAPI void automatic( + FASTDDS_EXPORTED_API void automatic( const std::string& directory) { setup (AUTO, directory, std::vector()); @@ -3083,7 +3084,7 @@ class DataSharingQosPolicy : public Parameter_t, public QosPolicy * @param directory The shared memory directory to use. * @param domain_ids the user configured DataSharing domain IDs (16 bits). */ - RTPS_DllAPI void automatic( + FASTDDS_EXPORTED_API void automatic( const std::string& directory, const std::vector& domain_ids) { @@ -3098,7 +3099,7 @@ class DataSharingQosPolicy : public Parameter_t, public QosPolicy * @param directory The shared memory directory to use. * It is mandatory to provide a non-empty name or the creation of endpoints will fail. */ - RTPS_DllAPI void on( + FASTDDS_EXPORTED_API void on( const std::string& directory) { // TODO [ILG]: This parameter is unused right now. Activate the assert once it is used @@ -3113,7 +3114,7 @@ class DataSharingQosPolicy : public Parameter_t, public QosPolicy * It is mandatory to provide a non-empty name or the creation of endpoints will fail. * @param domain_ids the user configured DataSharing domain IDs (16 bits). */ - RTPS_DllAPI void on( + FASTDDS_EXPORTED_API void on( const std::string& directory, const std::vector& domain_ids) { @@ -3125,7 +3126,7 @@ class DataSharingQosPolicy : public Parameter_t, public QosPolicy /** * @brief Configures the DataSharing in disabled mode */ - RTPS_DllAPI void off() + FASTDDS_EXPORTED_API void off() { setup (OFF, "", std::vector()); } @@ -3135,7 +3136,7 @@ class DataSharingQosPolicy : public Parameter_t, public QosPolicy * * @param id 16 bit identifier */ - RTPS_DllAPI void add_domain_id( + FASTDDS_EXPORTED_API void add_domain_id( uint16_t id) { if (max_domains_ == 0 || domain_ids_.size() < max_domains_) diff --git a/include/fastdds/dds/core/policy/ReaderDataLifecycleQosPolicy.hpp b/include/fastdds/dds/core/policy/ReaderDataLifecycleQosPolicy.hpp index 9e848d80068..2a3dd9f2a98 100644 --- a/include/fastdds/dds/core/policy/ReaderDataLifecycleQosPolicy.hpp +++ b/include/fastdds/dds/core/policy/ReaderDataLifecycleQosPolicy.hpp @@ -48,7 +48,7 @@ class ReaderDataLifecycleQosPolicy /** * @brief Destructor */ - virtual RTPS_DllAPI ~ReaderDataLifecycleQosPolicy() + virtual FASTDDS_EXPORTED_API ~ReaderDataLifecycleQosPolicy() { } diff --git a/include/fastdds/dds/core/policy/WriterDataLifecycleQosPolicy.hpp b/include/fastdds/dds/core/policy/WriterDataLifecycleQosPolicy.hpp index d4d075bfab1..6f412f513c1 100644 --- a/include/fastdds/dds/core/policy/WriterDataLifecycleQosPolicy.hpp +++ b/include/fastdds/dds/core/policy/WriterDataLifecycleQosPolicy.hpp @@ -41,7 +41,7 @@ class WriterDataLifecycleQosPolicy /** * @brief Destructor */ - virtual RTPS_DllAPI ~WriterDataLifecycleQosPolicy() + virtual FASTDDS_EXPORTED_API ~WriterDataLifecycleQosPolicy() { } diff --git a/include/fastdds/dds/core/status/IncompatibleQosStatus.hpp b/include/fastdds/dds/core/status/IncompatibleQosStatus.hpp index c5ee4908d34..d9c1dbd216b 100644 --- a/include/fastdds/dds/core/status/IncompatibleQosStatus.hpp +++ b/include/fastdds/dds/core/status/IncompatibleQosStatus.hpp @@ -16,14 +16,14 @@ * @file IncompatibleQosStatus.hpp */ -#ifndef _FASTRTPS_INCOMPATIBLE_QOS_STATUS_HPP_ -#define _FASTRTPS_INCOMPATIBLE_QOS_STATUS_HPP_ - -#include +#ifndef _FASTDDS_INCOMPATIBLE_QOS_STATUS_HPP_ +#define _FASTDDS_INCOMPATIBLE_QOS_STATUS_HPP_ #include #include +#include + namespace eprosima { namespace fastdds { namespace dds { @@ -93,4 +93,4 @@ using OfferedIncompatibleQosStatus = IncompatibleQosStatus; } //end of namespace fastdds } //end of namespace eprosima -#endif // _FASTRTPS_INCOMPATIBLE_QOS_STATUS_HPP_ +#endif // _FASTDDS_INCOMPATIBLE_QOS_STATUS_HPP_ diff --git a/include/fastdds/dds/core/status/StatusMask.hpp b/include/fastdds/dds/core/status/StatusMask.hpp index 2718869d75c..6e21b87ca9f 100644 --- a/include/fastdds/dds/core/status/StatusMask.hpp +++ b/include/fastdds/dds/core/status/StatusMask.hpp @@ -21,7 +21,7 @@ #ifndef _FASTDDS_STATUSMASK_HPP_ #define _FASTDDS_STATUSMASK_HPP_ -#include +#include #include #include @@ -44,7 +44,7 @@ namespace dds { * - indicate status changes when calling dds::core::Entity::status_changes */ -class RTPS_DllAPI StatusMask : public std::bitset +class FASTDDS_EXPORTED_API StatusMask : public std::bitset { public: diff --git a/include/fastdds/dds/domain/DomainParticipant.hpp b/include/fastdds/dds/domain/DomainParticipant.hpp index 7ac5f4b8998..fb6b3be24d2 100644 --- a/include/fastdds/dds/domain/DomainParticipant.hpp +++ b/include/fastdds/dds/domain/DomainParticipant.hpp @@ -27,22 +27,20 @@ #include #include -#include #include +#include +#include #include +#include +#include #include #include -#include #include #include -#include +#include #include #include #include -#include -#include - -using eprosima::fastrtps::types::ReturnCode_t; namespace dds { namespace domain { @@ -55,15 +53,6 @@ namespace fastrtps { namespace rtps { class ResourceEvent; } // namespace rtps - -namespace types { -class TypeInformation; -} // namespace types - -class ParticipantAttributes; -class PublisherAttributes; -class SubscriberAttributes; - } //namespace fastrtps namespace fastdds { @@ -104,7 +93,7 @@ class DomainParticipant : public Entity * @param qos DomainParticipantQos reference where the qos is going to be returned * @return RETCODE_OK */ - RTPS_DllAPI ReturnCode_t get_qos( + FASTDDS_EXPORTED_API ReturnCode_t get_qos( DomainParticipantQos& qos) const; /** @@ -112,7 +101,7 @@ class DomainParticipant : public Entity * * @return A reference to the DomainParticipantQos */ - RTPS_DllAPI const DomainParticipantQos& get_qos() const; + FASTDDS_EXPORTED_API const DomainParticipantQos& get_qos() const; /** * This operation sets the value of the DomainParticipant QoS policies. @@ -121,7 +110,7 @@ class DomainParticipant : public Entity * @return RETCODE_IMMUTABLE_POLICY if any of the Qos cannot be changed, RETCODE_INCONSISTENT_POLICY if the Qos is not * self consistent and RETCODE_OK if the qos is changed correctly. */ - RTPS_DllAPI ReturnCode_t set_qos( + FASTDDS_EXPORTED_API ReturnCode_t set_qos( const DomainParticipantQos& qos) const; /** @@ -129,7 +118,7 @@ class DomainParticipant : public Entity * * @return DomainParticipantListener pointer */ - RTPS_DllAPI const DomainParticipantListener* get_listener() const; + FASTDDS_EXPORTED_API const DomainParticipantListener* get_listener() const; /** * Modifies the DomainParticipantListener, sets the mask to StatusMask::all() @@ -138,7 +127,7 @@ class DomainParticipant : public Entity * @return RETCODE_OK if successful, RETCODE_ERROR otherwise. * @warning Do not call this method from a \c DomainParticipantListener callback. */ - RTPS_DllAPI ReturnCode_t set_listener( + FASTDDS_EXPORTED_API ReturnCode_t set_listener( DomainParticipantListener* listener); /** @@ -149,7 +138,7 @@ class DomainParticipant : public Entity * @return RETCODE_OK if successful, RETCODE_ERROR if failed (timeout expired). * @warning Do not call this method from a \c DomainParticipantListener callback. */ - RTPS_DllAPI ReturnCode_t set_listener( + FASTDDS_EXPORTED_API ReturnCode_t set_listener( DomainParticipantListener* listener, const std::chrono::seconds timeout); @@ -161,7 +150,7 @@ class DomainParticipant : public Entity * @return RETCODE_OK if successful, RETCODE_ERROR otherwise. * @warning Do not call this method from a \c DomainParticipantListener callback. */ - RTPS_DllAPI ReturnCode_t set_listener( + FASTDDS_EXPORTED_API ReturnCode_t set_listener( DomainParticipantListener* listener, const StatusMask& mask); @@ -174,7 +163,7 @@ class DomainParticipant : public Entity * @return RETCODE_OK if successful, RETCODE_ERROR if failed (timeout expired) * @warning Do not call this method from a \c DomainParticipantListener callback. */ - RTPS_DllAPI ReturnCode_t set_listener( + FASTDDS_EXPORTED_API ReturnCode_t set_listener( DomainParticipantListener* listener, const StatusMask& mask, const std::chrono::seconds timeout); @@ -184,7 +173,7 @@ class DomainParticipant : public Entity * * @return RETCODE_OK */ - RTPS_DllAPI ReturnCode_t enable() override; + FASTDDS_EXPORTED_API ReturnCode_t enable() override; // DomainParticipant specific methods from DDS API @@ -196,7 +185,7 @@ class DomainParticipant : public Entity * @param mask StatusMask that holds statuses the listener responds to (default: all) * @return Pointer to the created Publisher. */ - RTPS_DllAPI Publisher* create_publisher( + FASTDDS_EXPORTED_API Publisher* create_publisher( const PublisherQos& qos, PublisherListener* listener = nullptr, const StatusMask& mask = StatusMask::all()); @@ -209,7 +198,7 @@ class DomainParticipant : public Entity * @param mask StatusMask that holds statuses the listener responds to (default: all) * @return Pointer to the created Publisher. */ - RTPS_DllAPI Publisher* create_publisher_with_profile( + FASTDDS_EXPORTED_API Publisher* create_publisher_with_profile( const std::string& profile_name, PublisherListener* listener = nullptr, const StatusMask& mask = StatusMask::all()); @@ -221,7 +210,7 @@ class DomainParticipant : public Entity * @return RETCODE_PRECONDITION_NOT_MET if the publisher does not belong to this participant or if it has active DataWriters, * RETCODE_OK if it is correctly deleted and RETCODE_ERROR otherwise. */ - RTPS_DllAPI ReturnCode_t delete_publisher( + FASTDDS_EXPORTED_API ReturnCode_t delete_publisher( const Publisher* publisher); /** @@ -232,7 +221,7 @@ class DomainParticipant : public Entity * @param mask StatusMask that holds statuses the listener responds to (default: all) * @return Pointer to the created Subscriber. */ - RTPS_DllAPI Subscriber* create_subscriber( + FASTDDS_EXPORTED_API Subscriber* create_subscriber( const SubscriberQos& qos, SubscriberListener* listener = nullptr, const StatusMask& mask = StatusMask::all()); @@ -245,7 +234,7 @@ class DomainParticipant : public Entity * @param mask StatusMask that holds statuses the listener responds to (default: all) * @return Pointer to the created Subscriber. */ - RTPS_DllAPI Subscriber* create_subscriber_with_profile( + FASTDDS_EXPORTED_API Subscriber* create_subscriber_with_profile( const std::string& profile_name, SubscriberListener* listener = nullptr, const StatusMask& mask = StatusMask::all()); @@ -257,7 +246,7 @@ class DomainParticipant : public Entity * @return RETCODE_PRECONDITION_NOT_MET if the subscriber does not belong to this participant or if it has active DataReaders, * RETCODE_OK if it is correctly deleted and RETCODE_ERROR otherwise. */ - RTPS_DllAPI ReturnCode_t delete_subscriber( + FASTDDS_EXPORTED_API ReturnCode_t delete_subscriber( const Subscriber* subscriber); /** @@ -270,7 +259,7 @@ class DomainParticipant : public Entity * @param mask StatusMask that holds statuses the listener responds to (default: all) * @return Pointer to the created Topic. */ - RTPS_DllAPI Topic* create_topic( + FASTDDS_EXPORTED_API Topic* create_topic( const std::string& topic_name, const std::string& type_name, const TopicQos& qos, @@ -287,7 +276,7 @@ class DomainParticipant : public Entity * @param mask StatusMask that holds statuses the listener responds to (default: all) * @return Pointer to the created Topic. */ - RTPS_DllAPI Topic* create_topic_with_profile( + FASTDDS_EXPORTED_API Topic* create_topic_with_profile( const std::string& topic_name, const std::string& type_name, const std::string& profile_name, @@ -301,7 +290,7 @@ class DomainParticipant : public Entity * @return RETCODE_BAD_PARAMETER if the topic passed is a nullptr, RETCODE_PRECONDITION_NOT_MET if the topic does not belong to * this participant or if it is referenced by any entity and RETCODE_OK if the Topic was deleted. */ - RTPS_DllAPI ReturnCode_t delete_topic( + FASTDDS_EXPORTED_API ReturnCode_t delete_topic( const Topic* topic); /** @@ -317,7 +306,7 @@ class DomainParticipant : public Entity * @return nullptr if a filter cannot be created with the specified @c filter_expression and * @c expression_parameters. */ - RTPS_DllAPI ContentFilteredTopic* create_contentfilteredtopic( + FASTDDS_EXPORTED_API ContentFilteredTopic* create_contentfilteredtopic( const std::string& name, Topic* related_topic, const std::string& filter_expression, @@ -339,7 +328,7 @@ class DomainParticipant : public Entity * @c expression_parameters. * @return nullptr if the specified @c filter_class_name has not been registered. */ - RTPS_DllAPI ContentFilteredTopic* create_contentfilteredtopic( + FASTDDS_EXPORTED_API ContentFilteredTopic* create_contentfilteredtopic( const std::string& name, Topic* related_topic, const std::string& filter_expression, @@ -353,7 +342,7 @@ class DomainParticipant : public Entity * @return RETCODE_BAD_PARAMETER if the topic passed is a nullptr, RETCODE_PRECONDITION_NOT_MET if the topic does not belong to * this participant or if it is referenced by any entity and RETCODE_OK if the ContentFilteredTopic was deleted. */ - RTPS_DllAPI ReturnCode_t delete_contentfilteredtopic( + FASTDDS_EXPORTED_API ReturnCode_t delete_contentfilteredtopic( const ContentFilteredTopic* a_contentfilteredtopic); /** @@ -365,7 +354,7 @@ class DomainParticipant : public Entity * @param expression_parameters Parameters to subscription content * @return Pointer to the created ContentFilteredTopic, nullptr in error case */ - RTPS_DllAPI MultiTopic* create_multitopic( + FASTDDS_EXPORTED_API MultiTopic* create_multitopic( const std::string& name, const std::string& type_name, const std::string& subscription_expression, @@ -381,7 +370,7 @@ class DomainParticipant : public Entity * @warning Not supported yet. Currently returns RETCODE_UNSUPPORTED * */ - RTPS_DllAPI ReturnCode_t delete_multitopic( + FASTDDS_EXPORTED_API ReturnCode_t delete_multitopic( const MultiTopic* a_multitopic); /** @@ -397,7 +386,7 @@ class DomainParticipant : public Entity * @param timeout Maximum time to wait for the Topic * @return Pointer to the existing Topic, nullptr in case of error or timeout */ - RTPS_DllAPI Topic* find_topic( + FASTDDS_EXPORTED_API Topic* find_topic( const std::string& topic_name, const fastrtps::Duration_t& timeout); @@ -410,7 +399,7 @@ class DomainParticipant : public Entity * * @remark UNSAFE. It is unsafe to lookup a topic description while another thread is creating a topic. */ - RTPS_DllAPI TopicDescription* lookup_topicdescription( + FASTDDS_EXPORTED_API TopicDescription* lookup_topicdescription( const std::string& topic_name) const; /** @@ -418,7 +407,7 @@ class DomainParticipant : public Entity * * @return Pointer to the builtin Subscriber, nullptr in error case */ - RTPS_DllAPI const Subscriber* get_builtin_subscriber() const; + FASTDDS_EXPORTED_API const Subscriber* get_builtin_subscriber() const; /** * Locally ignore a remote domain participant. @@ -429,7 +418,7 @@ class DomainParticipant : public Entity * @return RETURN_OK code if everything correct, RETCODE_BAD_PARAMENTER otherwise * */ - RTPS_DllAPI ReturnCode_t ignore_participant( + FASTDDS_EXPORTED_API ReturnCode_t ignore_participant( const InstanceHandle_t& handle); /** @@ -443,7 +432,7 @@ class DomainParticipant : public Entity * @warning Not supported yet. Currently returns RETCODE_UNSUPPORTED * */ - RTPS_DllAPI ReturnCode_t ignore_topic( + FASTDDS_EXPORTED_API ReturnCode_t ignore_topic( const InstanceHandle_t& handle); /** @@ -457,7 +446,7 @@ class DomainParticipant : public Entity * @warning Not supported yet. Currently returns RETCODE_UNSUPPORTED * */ - RTPS_DllAPI ReturnCode_t ignore_publication( + FASTDDS_EXPORTED_API ReturnCode_t ignore_publication( const InstanceHandle_t& handle); /** @@ -471,7 +460,7 @@ class DomainParticipant : public Entity * @warning Not supported yet. Currently returns RETCODE_UNSUPPORTED * */ - RTPS_DllAPI ReturnCode_t ignore_subscription( + FASTDDS_EXPORTED_API ReturnCode_t ignore_subscription( const InstanceHandle_t& handle); /** @@ -480,14 +469,14 @@ class DomainParticipant : public Entity * * @return The Participant's domain_id */ - RTPS_DllAPI DomainId_t get_domain_id() const; + FASTDDS_EXPORTED_API DomainId_t get_domain_id() const; /** * Deletes all the entities that were created by means of the “create” methods * * @return RETURN_OK code if everything correct, error code otherwise */ - RTPS_DllAPI ReturnCode_t delete_contained_entities(); + FASTDDS_EXPORTED_API ReturnCode_t delete_contained_entities(); /** * This operation manually asserts the liveliness of the DomainParticipant. @@ -504,7 +493,7 @@ class DomainParticipant : public Entity * * @return RETCODE_OK if the liveliness was asserted, RETCODE_ERROR otherwise. */ - RTPS_DllAPI ReturnCode_t assert_liveliness(); + FASTDDS_EXPORTED_API ReturnCode_t assert_liveliness(); /** * This operation sets a default value of the Publisher QoS policies which will be used for newly created @@ -520,7 +509,7 @@ class DomainParticipant : public Entity * @param qos PublisherQos to be set * @return RETCODE_INCONSISTENT_POLICY if the Qos is not self consistent and RETCODE_OK if the qos is changed correctly. */ - RTPS_DllAPI ReturnCode_t set_default_publisher_qos( + FASTDDS_EXPORTED_API ReturnCode_t set_default_publisher_qos( const PublisherQos& qos); /** @@ -533,7 +522,7 @@ class DomainParticipant : public Entity * * @return Current default publisher qos. */ - RTPS_DllAPI const PublisherQos& get_default_publisher_qos() const; + FASTDDS_EXPORTED_API const PublisherQos& get_default_publisher_qos() const; /** * This operation retrieves the default value of the Publisher QoS, that is, the QoS policies which will be used @@ -546,7 +535,7 @@ class DomainParticipant : public Entity * @param qos PublisherQos reference where the default_publisher_qos is returned * @return RETCODE_OK */ - RTPS_DllAPI ReturnCode_t get_default_publisher_qos( + FASTDDS_EXPORTED_API ReturnCode_t get_default_publisher_qos( PublisherQos& qos) const; /** @@ -556,7 +545,7 @@ class DomainParticipant : public Entity * @param qos PublisherQos object where the qos is returned. * @return RETCODE_OK if the profile exists. RETCODE_BAD_PARAMETER otherwise. */ - RTPS_DllAPI ReturnCode_t get_publisher_qos_from_profile( + FASTDDS_EXPORTED_API ReturnCode_t get_publisher_qos_from_profile( const std::string& profile_name, PublisherQos& qos) const; @@ -574,7 +563,7 @@ class DomainParticipant : public Entity * @param qos SubscriberQos to be set * @return RETCODE_INCONSISTENT_POLICY if the Qos is not self consistent and RETCODE_OK if the qos is changed correctly. */ - RTPS_DllAPI ReturnCode_t set_default_subscriber_qos( + FASTDDS_EXPORTED_API ReturnCode_t set_default_subscriber_qos( const SubscriberQos& qos); /** @@ -587,7 +576,7 @@ class DomainParticipant : public Entity * * @return Current default subscriber qos. */ - RTPS_DllAPI const SubscriberQos& get_default_subscriber_qos() const; + FASTDDS_EXPORTED_API const SubscriberQos& get_default_subscriber_qos() const; /** * This operation retrieves the default value of the Subscriber QoS, that is, the QoS policies which will be used @@ -600,7 +589,7 @@ class DomainParticipant : public Entity * @param qos SubscriberQos reference where the default_subscriber_qos is returned * @return RETCODE_OK */ - RTPS_DllAPI ReturnCode_t get_default_subscriber_qos( + FASTDDS_EXPORTED_API ReturnCode_t get_default_subscriber_qos( SubscriberQos& qos) const; /** @@ -610,7 +599,7 @@ class DomainParticipant : public Entity * @param qos SubscriberQos object where the qos is returned. * @return RETCODE_OK if the profile exists. RETCODE_BAD_PARAMETER otherwise. */ - RTPS_DllAPI ReturnCode_t get_subscriber_qos_from_profile( + FASTDDS_EXPORTED_API ReturnCode_t get_subscriber_qos_from_profile( const std::string& profile_name, SubscriberQos& qos) const; @@ -628,7 +617,7 @@ class DomainParticipant : public Entity * @param qos TopicQos to be set * @return RETCODE_INCONSISTENT_POLICY if the Qos is not self consistent and RETCODE_OK if the qos is changed correctly. */ - RTPS_DllAPI ReturnCode_t set_default_topic_qos( + FASTDDS_EXPORTED_API ReturnCode_t set_default_topic_qos( const TopicQos& qos); /** @@ -641,7 +630,7 @@ class DomainParticipant : public Entity * * @return Current default topic qos. */ - RTPS_DllAPI const TopicQos& get_default_topic_qos() const; + FASTDDS_EXPORTED_API const TopicQos& get_default_topic_qos() const; /** * This operation retrieves the default value of the Topic QoS, that is, the QoS policies that will be used @@ -654,7 +643,7 @@ class DomainParticipant : public Entity * @param qos TopicQos reference where the default_topic_qos is returned * @return RETCODE_OK */ - RTPS_DllAPI ReturnCode_t get_default_topic_qos( + FASTDDS_EXPORTED_API ReturnCode_t get_default_topic_qos( TopicQos& qos) const; /** @@ -664,18 +653,41 @@ class DomainParticipant : public Entity * @param qos TopicQos object where the qos is returned. * @return RETCODE_OK if the profile exists. RETCODE_BAD_PARAMETER otherwise. */ - RTPS_DllAPI ReturnCode_t get_topic_qos_from_profile( + FASTDDS_EXPORTED_API ReturnCode_t get_topic_qos_from_profile( const std::string& profile_name, TopicQos& qos) const; + /** + * Fills the ReplierQos with the values of the XML profile. + * + * @param profile_name Replier profile name. + * @param qos ReplierQos object where the qos is returned. + * @return RETCODE_OK if the profile exists. RETCODE_BAD_PARAMETER otherwise. + */ + FASTDDS_EXPORTED_API ReturnCode_t get_replier_qos_from_profile( + const std::string& profile_name, + ReplierQos& qos) const; + + /** + * Fills the RequesterQos with the values of the XML profile. + * + * @param profile_name Requester profile name. + * @param qos RequesterQos object where the qos is returned. + * @return RETCODE_OK if the profile exists. RETCODE_BAD_PARAMETER otherwise. + */ + FASTDDS_EXPORTED_API ReturnCode_t get_requester_qos_from_profile( + const std::string& profile_name, + RequesterQos& qos) const; + /** * Retrieves the list of DomainParticipants that have been discovered in the domain and are not "ignored". * * @param[out] participant_handles Reference to the vector where discovered participants will be returned * @return RETCODE_OK if everything correct, error code otherwise + * * @warning Not supported yet. Currently returns RETCODE_UNSUPPORTED */ - RTPS_DllAPI ReturnCode_t get_discovered_participants( + FASTDDS_EXPORTED_API ReturnCode_t get_discovered_participants( std::vector& participant_handles) const; /** @@ -684,9 +696,10 @@ class DomainParticipant : public Entity * @param[out] participant_data Reference to the ParticipantBuiltinTopicData object to return the data * @param participant_handle InstanceHandle of DomainParticipant to retrieve the data from * @return RETCODE_OK if everything correct, PRECONDITION_NOT_MET if participant does not exist + * * @warning Not supported yet. Currently returns RETCODE_UNSUPPORTED */ - RTPS_DllAPI ReturnCode_t get_discovered_participant_data( + FASTDDS_EXPORTED_API ReturnCode_t get_discovered_participant_data( builtin::ParticipantBuiltinTopicData& participant_data, const InstanceHandle_t& participant_handle) const; @@ -695,9 +708,10 @@ class DomainParticipant : public Entity * * @param[out] topic_handles Reference to the vector where discovered topics will be returned * @return RETCODE_OK if everything correct, error code otherwise + * * @warning Not supported yet. Currently returns RETCODE_UNSUPPORTED */ - RTPS_DllAPI ReturnCode_t get_discovered_topics( + FASTDDS_EXPORTED_API ReturnCode_t get_discovered_topics( std::vector& topic_handles) const; /** @@ -709,7 +723,7 @@ class DomainParticipant : public Entity * * @warning Not supported yet. Currently returns RETCODE_UNSUPPORTED */ - RTPS_DllAPI ReturnCode_t get_discovered_topic_data( + FASTDDS_EXPORTED_API ReturnCode_t get_discovered_topic_data( builtin::TopicBuiltinTopicData& topic_data, const InstanceHandle_t& topic_handle) const; @@ -723,7 +737,7 @@ class DomainParticipant : public Entity * entities created using a contained Publisher, or Subscriber as the factory, and so forth. (default: true) * @return True if entity is contained. False otherwise. */ - RTPS_DllAPI bool contains_entity( + FASTDDS_EXPORTED_API bool contains_entity( const InstanceHandle_t& a_handle, bool recursive = true) const; @@ -734,10 +748,10 @@ class DomainParticipant : public Entity * @param current_time Time_t reference where the current time is returned * @return RETCODE_OK */ - RTPS_DllAPI ReturnCode_t get_current_time( + FASTDDS_EXPORTED_API ReturnCode_t get_current_time( fastrtps::Time_t& current_time) const; - // DomainParticipant methods specific from Fast-DDS + // DomainParticipant methods specific from Fast DDS /** * Register a type in this participant. @@ -747,7 +761,7 @@ class DomainParticipant : public Entity * @return RETCODE_BAD_PARAMETER if the size of the name is 0, RERCODE_PRECONDITION_NOT_MET if there is another TypeSupport * with the same name and RETCODE_OK if it is correctly registered. */ - RTPS_DllAPI ReturnCode_t register_type( + FASTDDS_EXPORTED_API ReturnCode_t register_type( TypeSupport type, const std::string& type_name); @@ -758,7 +772,7 @@ class DomainParticipant : public Entity * @return RETCODE_BAD_PARAMETER if the size of the name is 0, RERCODE_PRECONDITION_NOT_MET if there is another TypeSupport * with the same name and RETCODE_OK if it is correctly registered. */ - RTPS_DllAPI ReturnCode_t register_type( + FASTDDS_EXPORTED_API ReturnCode_t register_type( TypeSupport type); /** @@ -768,7 +782,7 @@ class DomainParticipant : public Entity * @return RETCODE_BAD_PARAMETER if the size of the name is 0, RERCODE_PRECONDITION_NOT_MET if there are entities using that * TypeSupport and RETCODE_OK if it is correctly unregistered. */ - RTPS_DllAPI ReturnCode_t unregister_type( + FASTDDS_EXPORTED_API ReturnCode_t unregister_type( const std::string& typeName); /** @@ -777,7 +791,7 @@ class DomainParticipant : public Entity * @param type_name Name of the type * @return TypeSupport corresponding to the type_name */ - RTPS_DllAPI TypeSupport find_type( + FASTDDS_EXPORTED_API TypeSupport find_type( const std::string& type_name) const; /** @@ -785,7 +799,7 @@ class DomainParticipant : public Entity * * @return InstanceHandle of this DomainParticipant. */ - RTPS_DllAPI const InstanceHandle_t& get_instance_handle() const; + FASTDDS_EXPORTED_API const InstanceHandle_t& get_instance_handle() const; // From here legacy RTPS methods. @@ -794,14 +808,14 @@ class DomainParticipant : public Entity * * @return A reference to the GUID */ - RTPS_DllAPI const fastrtps::rtps::GUID_t& guid() const; + FASTDDS_EXPORTED_API const fastrtps::rtps::GUID_t& guid() const; /** * @brief Getter for the participant names * * @return Vector with the names */ - RTPS_DllAPI std::vector get_participant_names() const; + FASTDDS_EXPORTED_API std::vector get_participant_names() const; /** * This method can be used when using a StaticEndpointDiscovery mechanism different that the one @@ -814,7 +828,7 @@ class DomainParticipant : public Entity * @param kind EndpointKind (WRITER or READER) * @return True if correctly found and activated. */ - RTPS_DllAPI bool new_remote_endpoint_discovered( + FASTDDS_EXPORTED_API bool new_remote_endpoint_discovered( const fastrtps::rtps::GUID_t& partguid, uint16_t userId, fastrtps::rtps::EndpointKind_t kind); @@ -826,50 +840,7 @@ class DomainParticipant : public Entity * * @return A reference to the resource event */ - RTPS_DllAPI fastrtps::rtps::ResourceEvent& get_resource_event() const; - - /** - * When a DomainParticipant receives an incomplete list of TypeIdentifiers in a - * PublicationBuiltinTopicData or SubscriptionBuiltinTopicData, it may request the additional type - * dependencies by invoking the getTypeDependencies operation. - * - * @param in TypeIdentifier sequence - * @return SampleIdentity - */ - RTPS_DllAPI fastrtps::rtps::SampleIdentity get_type_dependencies( - const fastrtps::types::TypeIdentifierSeq& in) const; - - /** - * A DomainParticipant may invoke the operation getTypes to retrieve the TypeObjects associated with a - * list of TypeIdentifiers. - * - * @param in TypeIdentifier sequence - * @return SampleIdentity - */ - RTPS_DllAPI fastrtps::rtps::SampleIdentity get_types( - const fastrtps::types::TypeIdentifierSeq& in) const; - - /** - * Helps the user to solve all dependencies calling internally to the type lookup service and - * registers the resulting dynamic type. - * The registration may be perform asynchronously, case in which the user will be notified - * through the given callback, which receives the type_name as unique argument. - * - * @param type_information - * @param type_name - * @param callback - * @return RETCODE_OK If the given type_information is enough to build the type without using - * the typelookup service (callback will not be called). - * @return RETCODE_OK if the given type is already available (callback will not be called). - * @return RETCODE_NO_DATA if type is not available yet (the callback will be called if - * negotiation is success, and ignored in other case). - * @return RETCODE_NOT_ENABLED if the DomainParticipant is not enabled. - * @return RETCODE_PRECONDITION_NOT_MET if the DomainParticipant type lookup service is disabled. - */ - RTPS_DllAPI ReturnCode_t register_remote_type( - const fastrtps::types::TypeInformation& type_information, - const std::string& type_name, - std::function& callback); + FASTDDS_EXPORTED_API fastrtps::rtps::ResourceEvent& get_resource_event() const; /** * Register a custom content filter factory, which can be used to create a ContentFilteredTopic. @@ -901,7 +872,7 @@ class DomainParticipant : public Entity * @return RETCODE_PRECONDITION_NOT_MET if filter_class_name is FASTDDS_SQLFILTER_NAME. * @return RETCODE_OK if the filter is correctly registered. */ - RTPS_DllAPI ReturnCode_t register_content_filter_factory( + FASTDDS_EXPORTED_API ReturnCode_t register_content_filter_factory( const char* filter_class_name, IContentFilterFactory* const filter_factory); @@ -913,7 +884,7 @@ class DomainParticipant : public Entity * @return nullptr if the given filter_class_name has not been previously registered on this DomainParticipant. * Otherwise, the content filter factory previously registered with the given filter_class_name. */ - RTPS_DllAPI IContentFilterFactory* lookup_content_filter_factory( + FASTDDS_EXPORTED_API IContentFilterFactory* lookup_content_filter_factory( const char* filter_class_name); /** @@ -935,7 +906,7 @@ class DomainParticipant : public Entity * @return RERCODE_PRECONDITION_NOT_MET if there is any ContentFilteredTopic referencing the filter. * @return RETCODE_OK if the filter is correctly unregistered. */ - RTPS_DllAPI ReturnCode_t unregister_content_filter_factory( + FASTDDS_EXPORTED_API ReturnCode_t unregister_content_filter_factory( const char* filter_class_name); /** diff --git a/include/fastdds/dds/domain/DomainParticipantFactory.hpp b/include/fastdds/dds/domain/DomainParticipantFactory.hpp index 475b36a8a54..09df4a26027 100644 --- a/include/fastdds/dds/domain/DomainParticipantFactory.hpp +++ b/include/fastdds/dds/domain/DomainParticipantFactory.hpp @@ -17,20 +17,20 @@ * */ -#ifndef _FASTDDS_DOMAINPARTICIPANT_HPP_ -#define _FASTDDS_DOMAINPARTICIPANT_HPP_ - -#include -#include -#include -#include -#include +#ifndef _FASTDDS_DDS_DOMAIN_DOMAINPARTICIPANT_FACTORY_HPP_ +#define _FASTDDS_DDS_DOMAIN_DOMAINPARTICIPANT_FACTORY_HPP_ #include #include #include -using eprosima::fastrtps::types::ReturnCode_t; +#include +#include +#include +#include +#include +#include +#include namespace eprosima { @@ -71,14 +71,14 @@ class DomainParticipantFactory * * @return A raw pointer to the DomainParticipantFactory singleton instance. */ - RTPS_DllAPI static DomainParticipantFactory* get_instance(); + FASTDDS_EXPORTED_API static DomainParticipantFactory* get_instance(); /** * Returns the DomainParticipantFactory singleton instance. * * @return A shared pointer to the DomainParticipantFactory singleton instance. */ - RTPS_DllAPI static std::shared_ptr get_shared_instance(); + FASTDDS_EXPORTED_API static std::shared_ptr get_shared_instance(); /** * Create a Participant. @@ -89,12 +89,31 @@ class DomainParticipantFactory * @param mask StatusMask Reference (default: all) * @return DomainParticipant pointer. (nullptr if not created.) */ - RTPS_DllAPI DomainParticipant* create_participant( + FASTDDS_EXPORTED_API DomainParticipant* create_participant( DomainId_t domain_id, const DomainParticipantQos& qos, DomainParticipantListener* listener = nullptr, const StatusMask& mask = StatusMask::all()); + /** + * Create a Participant with default domain id and qos. + * + * @return DomainParticipant pointer. (nullptr if not created.) + */ + FASTDDS_EXPORTED_API DomainParticipant* create_participant_with_default_profile(); + + + /** + * Create a Participant with default domain id and qos. + * + * @return DomainParticipant pointer. (nullptr if not created.) + * @param listener DomainParticipantListener Pointer + * @param mask StatusMask Reference + */ + FASTDDS_EXPORTED_API DomainParticipant* create_participant_with_default_profile( + DomainParticipantListener* listener, + const StatusMask& mask); + /** * Create a Participant. * @@ -104,7 +123,7 @@ class DomainParticipantFactory * @param mask StatusMask Reference (default: all) * @return DomainParticipant pointer. (nullptr if not created.) */ - RTPS_DllAPI DomainParticipant* create_participant_with_profile( + FASTDDS_EXPORTED_API DomainParticipant* create_participant_with_profile( DomainId_t domain_id, const std::string& profile_name, DomainParticipantListener* listener = nullptr, @@ -118,7 +137,7 @@ class DomainParticipantFactory * @param mask StatusMask Reference (default: all) * @return DomainParticipant pointer. (nullptr if not created.) */ - RTPS_DllAPI DomainParticipant* create_participant_with_profile( + FASTDDS_EXPORTED_API DomainParticipant* create_participant_with_profile( const std::string& profile_name, DomainParticipantListener* listener = nullptr, const StatusMask& mask = StatusMask::all()); @@ -132,7 +151,7 @@ class DomainParticipantFactory * @param domain_id * @return previously created DomainParticipant within the specified domain */ - RTPS_DllAPI DomainParticipant* lookup_participant( + FASTDDS_EXPORTED_API DomainParticipant* lookup_participant( DomainId_t domain_id) const; /** @@ -141,7 +160,7 @@ class DomainParticipantFactory * @param domain_id * @return previously created DomainParticipants within the specified domain */ - RTPS_DllAPI std::vector lookup_participants( + FASTDDS_EXPORTED_API std::vector lookup_participants( DomainId_t domain_id) const; /** @@ -154,7 +173,7 @@ class DomainParticipantFactory * @param qos DomainParticipantQos where the qos is returned * @return RETCODE_OK */ - RTPS_DllAPI ReturnCode_t get_default_participant_qos( + FASTDDS_EXPORTED_API ReturnCode_t get_default_participant_qos( DomainParticipantQos& qos) const; /** @@ -166,7 +185,7 @@ class DomainParticipantFactory * * @return A reference to the default DomainParticipantQos */ - RTPS_DllAPI const DomainParticipantQos& get_default_participant_qos() const; + FASTDDS_EXPORTED_API const DomainParticipantQos& get_default_participant_qos() const; /** * @brief This operation sets a default value of the DomainParticipant QoS policies which will be used for @@ -183,7 +202,7 @@ class DomainParticipantFactory * @param qos DomainParticipantQos to be set * @return RETCODE_INCONSISTENT_POLICY if the Qos is not self consistent and RETCODE_OK if the qos is changed correctly. */ - RTPS_DllAPI ReturnCode_t set_default_participant_qos( + FASTDDS_EXPORTED_API ReturnCode_t set_default_participant_qos( const DomainParticipantQos& qos); /** @@ -193,7 +212,7 @@ class DomainParticipantFactory * @param qos DomainParticipantQos object where the qos is returned. * @return RETCODE_OK if the profile exists. RETCODE_BAD_PARAMETER otherwise. */ - RTPS_DllAPI ReturnCode_t get_participant_qos_from_profile( + FASTDDS_EXPORTED_API ReturnCode_t get_participant_qos_from_profile( const std::string& profile_name, DomainParticipantQos& qos) const; @@ -204,7 +223,7 @@ class DomainParticipantFactory * @return RETCODE_PRECONDITION_NOT_MET if the participant has active entities, RETCODE_OK if the participant is correctly * deleted and RETCODE_ERROR otherwise. */ - RTPS_DllAPI ReturnCode_t delete_participant( + FASTDDS_EXPORTED_API ReturnCode_t delete_participant( DomainParticipant* part); /** @@ -212,7 +231,7 @@ class DomainParticipantFactory * * @return RETCODE_OK */ - RTPS_DllAPI ReturnCode_t load_profiles(); + FASTDDS_EXPORTED_API ReturnCode_t load_profiles(); /** * Load profiles from XML file. @@ -220,7 +239,7 @@ class DomainParticipantFactory * @param xml_profile_file XML profile file. * @return RETCODE_OK if it is correctly loaded, RETCODE_ERROR otherwise. */ - RTPS_DllAPI ReturnCode_t load_XML_profiles_file( + FASTDDS_EXPORTED_API ReturnCode_t load_XML_profiles_file( const std::string& xml_profile_file); /** @@ -230,7 +249,7 @@ class DomainParticipantFactory * @param length length of data * @return RETCODE_OK if it is correctly loaded, RETCODE_ERROR otherwise. */ - RTPS_DllAPI ReturnCode_t load_XML_profiles_string( + FASTDDS_EXPORTED_API ReturnCode_t load_XML_profiles_string( const char* data, size_t length); @@ -240,7 +259,7 @@ class DomainParticipantFactory * @param xml_file xml file path * @return RETCODE_OK if the validation is successful, RETCODE_ERROR otherwise. */ - RTPS_DllAPI ReturnCode_t check_xml_static_discovery( + FASTDDS_EXPORTED_API ReturnCode_t check_xml_static_discovery( std::string& xml_file); /** @@ -249,7 +268,7 @@ class DomainParticipantFactory * @param qos DomaParticipantFactoryQos reference where the qos is returned * @return RETCODE_OK */ - RTPS_DllAPI ReturnCode_t get_qos( + FASTDDS_EXPORTED_API ReturnCode_t get_qos( DomainParticipantFactoryQos& qos) const; /** @@ -265,9 +284,52 @@ class DomainParticipantFactory * @return RETCODE_IMMUTABLE_POLICY if any of the Qos cannot be changed, RETCODE_INCONSISTENT_POLICY if the Qos is not * self consistent and RETCODE_OK if the qos is changed correctly. */ - RTPS_DllAPI ReturnCode_t set_qos( + FASTDDS_EXPORTED_API ReturnCode_t set_qos( const DomainParticipantFactoryQos& qos); + /** + * @brief This operation returns the value of the DomainParticipant library settings. + * + * @param library_settings LibrarySettings reference where the settings are returned. + * @return RETCODE_OK + */ + FASTDDS_EXPORTED_API ReturnCode_t get_library_settings( + LibrarySettings& library_settings) const; + + /** + * @brief This operation sets the library settings. + * + * Library settings must be set before enabling the DomainParticipants. + * Otherwise, failure of the setting operation is expected. + * + * @param library_settings LibrarySettings to be set. + * @return RETCODE_PRECONDITION_NOT_MET if any DomainParticipant is already enabled. + * RETCODE_OK otherwise. + */ + FASTDDS_EXPORTED_API ReturnCode_t set_library_settings( + const LibrarySettings& library_settings); + + /** + * @brief Get the @ref DynamicType defined in XML file. + * The XML file shall be previously loaded. + * + * @param type_name Dynamic type name. + * @param type Reference where the Dynamic type builder is returned. + * @return RETCODE_BAD_PARAMETER if type_name is empty. + * RETCODE_NO_DATA if type_name is unknown. + * RETCODE_OK otherwise. + */ + FASTDDS_EXPORTED_API ReturnCode_t get_dynamic_type_builder_from_xml_by_name( + const std::string& type_name, + DynamicType::_ref_type& type); + + /** + * @brief Return the TypeObjectRegistry member to access the public API. + * + * @return const xtypes::TypeObjectRegistry reference. + */ + FASTDDS_EXPORTED_API xtypes::ITypeObjectRegistry& type_object_registry(); + protected: friend class DomainParticipant; @@ -305,6 +367,8 @@ class DomainParticipantFactory mutable bool default_xml_profiles_loaded; + DomainId_t default_domain_id_; + DomainParticipantFactoryQos factory_qos_; DomainParticipantQos default_participant_qos_; @@ -327,4 +391,4 @@ class DomainParticipantFactory } // namespace fastdds } // namespace eprosima -#endif /* _FASTDDS_DOMAINPARTICIPANT_HPP_*/ +#endif /* _FASTDDS_DDS_DOMAIN_DOMAINPARTICIPANT_FACTORY_HPP_*/ diff --git a/include/fastdds/dds/domain/DomainParticipantListener.hpp b/include/fastdds/dds/domain/DomainParticipantListener.hpp index 4d6c98c8131..9455729d6e5 100644 --- a/include/fastdds/dds/domain/DomainParticipantListener.hpp +++ b/include/fastdds/dds/domain/DomainParticipantListener.hpp @@ -20,16 +20,12 @@ #ifndef __FASTDDS__PARTICIPANT_PARTICIPANTLISTENER_HPP__ #define __FASTDDS__PARTICIPANT_PARTICIPANTLISTENER_HPP__ -#include -#include -#include #include #include #include - -#include -#include -#include +#include +#include +#include namespace eprosima { namespace fastdds { @@ -63,22 +59,6 @@ class DomainParticipantListener : { } - /*! - * This method is called when a new Participant is discovered, or a previously discovered participant changes - * its QOS or is removed. - * - * @param[out] participant Pointer to the Participant which discovered the remote participant. - * @param[out] info Remote participant information. User can take ownership of the object. - */ - FASTDDS_TODO_BEFORE(3, 0, "Remove this overload"); - virtual void on_participant_discovery( - DomainParticipant* participant, - fastrtps::rtps::ParticipantDiscoveryInfo&& info) - { - static_cast(participant); - static_cast(info); - } - /*! * This method is called when a new Participant is discovered, or a previously discovered participant changes * its QOS or is removed. @@ -120,26 +100,9 @@ class DomainParticipantListener : * * @param[out] participant Pointer to the Participant which discovered the remote DataReader. * @param[out] info Remote DataReader information. User can take ownership of the object. - */ - virtual void on_subscriber_discovery( - DomainParticipant* participant, - fastrtps::rtps::ReaderDiscoveryInfo&& info) - { - static_cast(participant); - static_cast(info); - } - - /*! - * This method is called when a new DataReader is discovered, or a previously discovered DataReader changes - * its QOS or is removed. - * - * @warning Not Supported. This callback will never be called in the current version. - * - * @param[out] participant Pointer to the Participant which discovered the remote DataReader. - * @param[out] info Remote DataReader information. User can take ownership of the object. * @param[out] should_be_ignored Flag to indicate the library to automatically ignore the discovered DataReader. */ - virtual void on_subscriber_discovery( + virtual void on_data_reader_discovery( DomainParticipant* participant, fastrtps::rtps::ReaderDiscoveryInfo&& info, bool& should_be_ignored) @@ -155,26 +118,9 @@ class DomainParticipantListener : * * @param[out] participant Pointer to the Participant which discovered the remote DataWriter. * @param[out] info Remote DataWriter information. User can take ownership of the object. - */ - virtual void on_publisher_discovery( - DomainParticipant* participant, - fastrtps::rtps::WriterDiscoveryInfo&& info) - { - static_cast(participant); - static_cast(info); - } - - /*! - * This method is called when a new DataWriter is discovered, or a previously discovered DataWriter changes - * its QOS or is removed. - * - * @warning Not Supported. This callback will never be called in the current version. - * - * @param[out] participant Pointer to the Participant which discovered the remote DataWriter. - * @param[out] info Remote DataWriter information. User can take ownership of the object. * @param[out] should_be_ignored Flag to indicate the library to automatically ignore the discovered DataWriter. */ - virtual void on_publisher_discovery( + virtual void on_data_writer_discovery( DomainParticipant* participant, fastrtps::rtps::WriterDiscoveryInfo&& info, bool& should_be_ignored) @@ -184,59 +130,6 @@ class DomainParticipantListener : static_cast(should_be_ignored); } - /*! - * This method is called when a participant discovers a new Type - * The ownership of all object belongs to the caller so if needs to be used after the - * method ends, a full copy should be perform (except for dyn_type due to its shared_ptr nature. - * For example: - * fastrtps::types::TypeIdentifier new_type_id = \*identifier; - */ - virtual void on_type_discovery( - DomainParticipant* participant, - const fastrtps::rtps::SampleIdentity& request_sample_id, - const fastrtps::string_255& topic, - const fastrtps::types::TypeIdentifier* identifier, - const fastrtps::types::TypeObject* object, - fastrtps::types::DynamicType_ptr dyn_type) - { - static_cast(participant); - static_cast(request_sample_id); - static_cast(topic); - static_cast(identifier); - static_cast(object); - static_cast(dyn_type); - } - - /*! - * This method is called when the typelookup client received a reply to a getTypeDependencies request. - * The user may want to retrieve these new types using the getTypes request and create a new - * DynamicType using the retrieved TypeObject. - */ - virtual void on_type_dependencies_reply( - DomainParticipant* participant, - const fastrtps::rtps::SampleIdentity& request_sample_id, - const fastrtps::types::TypeIdentifierWithSizeSeq& dependencies) - { - static_cast(participant); - static_cast(request_sample_id); - static_cast(dependencies); - } - - /*! - * This method is called when a participant receives a TypeInformation while discovering another participant. - */ - virtual void on_type_information_received( - DomainParticipant* participant, - const fastrtps::string_255 topic_name, - const fastrtps::string_255 type_name, - const fastrtps::types::TypeInformation& type_information) - { - static_cast(participant); - static_cast(topic_name); - static_cast(type_name); - static_cast(type_information); - } - // TODO: Methods in DomainParticipantListener (p.33 - DDS) }; diff --git a/include/fastdds/dds/domain/qos/DomainParticipantFactoryQos.hpp b/include/fastdds/dds/domain/qos/DomainParticipantFactoryQos.hpp index 12e46cc1535..be0c1c1ccef 100644 --- a/include/fastdds/dds/domain/qos/DomainParticipantFactoryQos.hpp +++ b/include/fastdds/dds/domain/qos/DomainParticipantFactoryQos.hpp @@ -22,7 +22,7 @@ #include #include -#include +#include namespace eprosima { namespace fastdds { @@ -40,14 +40,14 @@ class DomainParticipantFactoryQos /** * @brief Constructor */ - RTPS_DllAPI DomainParticipantFactoryQos() + FASTDDS_EXPORTED_API DomainParticipantFactoryQos() { } /** * @brief Destructor */ - RTPS_DllAPI virtual ~DomainParticipantFactoryQos() + FASTDDS_EXPORTED_API virtual ~DomainParticipantFactoryQos() { } @@ -162,7 +162,7 @@ class DomainParticipantFactoryQos }; -RTPS_DllAPI extern const DomainParticipantFactoryQos PARTICIPANT_FACTORY_QOS_DEFAULT; +FASTDDS_EXPORTED_API extern const DomainParticipantFactoryQos PARTICIPANT_FACTORY_QOS_DEFAULT; } /* namespace dds */ } /* namespace fastdds */ diff --git a/include/fastdds/dds/domain/qos/DomainParticipantQos.hpp b/include/fastdds/dds/domain/qos/DomainParticipantQos.hpp index 4397791390e..9fdb758501a 100644 --- a/include/fastdds/dds/domain/qos/DomainParticipantQos.hpp +++ b/include/fastdds/dds/domain/qos/DomainParticipantQos.hpp @@ -26,7 +26,7 @@ #include #include #include -#include +#include namespace eprosima { namespace fastdds { @@ -52,7 +52,7 @@ class DomainParticipantQos /** * @brief Constructor */ - RTPS_DllAPI DomainParticipantQos() + FASTDDS_EXPORTED_API DomainParticipantQos() { #ifdef FASTDDS_STATISTICS /* @@ -69,7 +69,7 @@ class DomainParticipantQos /** * @brief Destructor */ - RTPS_DllAPI virtual ~DomainParticipantQos() + FASTDDS_EXPORTED_API virtual ~DomainParticipantQos() { } @@ -86,6 +86,7 @@ class DomainParticipantQos (this->builtin_controllers_sender_thread_ == b.builtin_controllers_sender_thread()) && (this->timed_events_thread_ == b.timed_events_thread()) && (this->discovery_server_thread_ == b.discovery_server_thread()) && + (this->typelookup_service_thread_ == b.typelookup_service_thread()) && #if HAVE_SECURITY (this->security_log_thread_ == b.security_log_thread()) && #endif // if HAVE_SECURITY @@ -283,7 +284,7 @@ class DomainParticipantQos * * @return name */ - const fastrtps::string_255& name() const + const fastcdr::string_255& name() const { return name_; } @@ -293,7 +294,7 @@ class DomainParticipantQos * * @return name */ - fastrtps::string_255& name() + fastcdr::string_255& name() { return name_; } @@ -304,7 +305,7 @@ class DomainParticipantQos * @param value New name to be set */ void name( - const fastrtps::string_255& value) + const fastcdr::string_255& value) { name_ = value; } @@ -356,7 +357,7 @@ class DomainParticipantQos * @param transports Defines the transport configuration scenario to setup. * @param options Defines the options to be used in the transport configuration. */ - RTPS_DllAPI void setup_transports( + FASTDDS_EXPORTED_API void setup_transports( rtps::BuiltinTransports transports, const rtps::BuiltinTransportsOptions& options = rtps::BuiltinTransportsOptions()); @@ -433,6 +434,37 @@ class DomainParticipantQos discovery_server_thread_ = value; } + /** + * Getter for TypeLookup service ThreadSettings + * + * @return rtps::ThreadSettings reference + */ + rtps::ThreadSettings& typelookup_service_thread() + { + return typelookup_service_thread_; + } + + /** + * Getter for TypeLookup service ThreadSettings + * + * @return rtps::ThreadSettings reference + */ + const rtps::ThreadSettings& typelookup_service_thread() const + { + return typelookup_service_thread_; + } + + /** + * Setter for the TypeLookup service ThreadSettings + * + * @param value New ThreadSettings to be set + */ + void typelookup_service_thread( + const rtps::ThreadSettings& value) + { + typelookup_service_thread_ = value; + } + #if HAVE_SECURITY /** * Getter for security log ThreadSettings @@ -488,7 +520,7 @@ class DomainParticipantQos TransportConfigQos transport_; //!Name of the participant. - fastrtps::string_255 name_ = "RTPSParticipant"; + fastcdr::string_255 name_ = "RTPSParticipant"; /*! User defined flow controller to use alongside. * @@ -505,6 +537,9 @@ class DomainParticipantQos //! Thread settings for the discovery server thread rtps::ThreadSettings discovery_server_thread_; + //! Thread settings for the builtin TypeLookup service requests and replies threads + rtps::ThreadSettings typelookup_service_thread_; + #if HAVE_SECURITY //! Thread settings for the security log thread rtps::ThreadSettings security_log_thread_; @@ -512,7 +547,7 @@ class DomainParticipantQos }; -RTPS_DllAPI extern const DomainParticipantQos PARTICIPANT_QOS_DEFAULT; +FASTDDS_EXPORTED_API extern const DomainParticipantQos PARTICIPANT_QOS_DEFAULT; } /* namespace dds */ diff --git a/include/fastdds/dds/domain/qos/ReplierQos.hpp b/include/fastdds/dds/domain/qos/ReplierQos.hpp new file mode 100644 index 00000000000..3b992a202b3 --- /dev/null +++ b/include/fastdds/dds/domain/qos/ReplierQos.hpp @@ -0,0 +1,80 @@ +// Copyright 2024 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/** + * @file ReplierQos.hpp + */ + +#ifndef _FASTDDS_REPLIERQOS_HPP_ +#define _FASTDDS_REPLIERQOS_HPP_ + +#include + +#include +#include +#include + +namespace eprosima { +namespace fastdds { +namespace dds { + +class ReplierQos +{ +public: + + /** + * @brief Constructor + */ + FASTDDS_EXPORTED_API ReplierQos() = default; + + /** + * @brief Equal comparison operator + */ + FASTDDS_EXPORTED_API bool operator ==( + const ReplierQos& b) const + { + return (this->service_name == b.service_name) && + (this->request_topic_name == b.request_topic_name) && + (this->reply_topic_name == b.reply_topic_name) && + (this->writer_qos == b.writer_qos) && + (this->reader_qos == b.reader_qos); + } + + //! Service name + std::string service_name; + + //! Request type + std::string request_type; + + //! Reply type + std::string reply_type; + + //! Request topic name + std::string request_topic_name; + + //! Reply topic name + std::string reply_topic_name; + + //! DataWriter QoS for the reply writer + DataWriterQos writer_qos; + + //! DataReader QoS for the reply reader + DataReaderQos reader_qos; +}; + +} /* namespace dds */ +} /* namespace fastdds */ +} /* namespace eprosima */ + +#endif /* _FASTDDS_REPLIERQOS_HPP_ */ diff --git a/include/fastdds/dds/domain/qos/RequesterQos.hpp b/include/fastdds/dds/domain/qos/RequesterQos.hpp new file mode 100644 index 00000000000..fb31447c4bc --- /dev/null +++ b/include/fastdds/dds/domain/qos/RequesterQos.hpp @@ -0,0 +1,80 @@ +// Copyright 2024 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/** + * @file RequesterQos.hpp + */ + +#ifndef _FASTDDS_REQUESTERQOS_HPP_ +#define _FASTDDS_REQUESTERQOS_HPP_ + +#include + +#include +#include +#include + +namespace eprosima { +namespace fastdds { +namespace dds { + +class RequesterQos +{ +public: + + /** + * @brief Constructor + */ + FASTDDS_EXPORTED_API RequesterQos() = default; + + /** + * @brief Equal comparison operator + */ + FASTDDS_EXPORTED_API bool operator ==( + const RequesterQos& b) const + { + return (this->service_name == b.service_name) && + (this->request_topic_name == b.request_topic_name) && + (this->reply_topic_name == b.reply_topic_name) && + (this->writer_qos == b.writer_qos) && + (this->reader_qos == b.reader_qos); + } + + //! Service name + std::string service_name; + + //! Request type + std::string request_type; + + //! Reply type + std::string reply_type; + + //! Request topic name + std::string request_topic_name; + + //! Reply topic name + std::string reply_topic_name; + + //! DataWriter QoS for the request writer + DataWriterQos writer_qos; + + //! DataReader QoS for the request reader + DataReaderQos reader_qos; +}; + +} /* namespace dds */ +} /* namespace fastdds */ +} /* namespace eprosima */ + +#endif /* _FASTDDS_REQUESTERQOS_HPP_ */ diff --git a/include/fastdds/dds/log/FileConsumer.hpp b/include/fastdds/dds/log/FileConsumer.hpp index a8f0e3a76b3..7bafbe1844a 100644 --- a/include/fastdds/dds/log/FileConsumer.hpp +++ b/include/fastdds/dds/log/FileConsumer.hpp @@ -39,13 +39,13 @@ class FileConsumer : public OStreamConsumer public: //! Default constructor: filename = "output.log", append = false. - RTPS_DllAPI FileConsumer(); + FASTDDS_EXPORTED_API FileConsumer(); /** Constructor with parameters. * @param filename path of the output file where the log will be wrote. * @param append indicates if the consumer must append the content in the filename. */ - RTPS_DllAPI FileConsumer( + FASTDDS_EXPORTED_API FileConsumer( const std::string& filename, bool append = false); @@ -57,7 +57,7 @@ class FileConsumer : public OStreamConsumer * Called by Log consume to get the correct stream * @param entry Log::Entry to consume. */ - RTPS_DllAPI virtual std::ostream& get_stream( + FASTDDS_EXPORTED_API virtual std::ostream& get_stream( const Log::Entry& entry) override; std::string output_file_; diff --git a/include/fastdds/dds/log/Log.hpp b/include/fastdds/dds/log/Log.hpp index 3ad9e655201..51c9bb68b02 100644 --- a/include/fastdds/dds/log/Log.hpp +++ b/include/fastdds/dds/log/Log.hpp @@ -19,7 +19,7 @@ #include #include -#include +#include /** * eProsima log layer. Logging categories and verbosity can be specified dynamically at runtime. @@ -98,51 +98,60 @@ class Log * There is a default stdout consumer active as default. * @param consumer r-value to a consumer unique_ptr. It will be invalidated after the call. */ - RTPS_DllAPI static void RegisterConsumer( + FASTDDS_EXPORTED_API static void RegisterConsumer( std::unique_ptr&& consumer); //! Removes all registered consumers, including the default stdout. - RTPS_DllAPI static void ClearConsumers(); + FASTDDS_EXPORTED_API static void ClearConsumers(); //! Enables the reporting of filenames in log entries. Disabled by default. - RTPS_DllAPI static void ReportFilenames( + FASTDDS_EXPORTED_API static void ReportFilenames( bool); //! Enables the reporting of function names in log entries. Enabled by default when supported. - RTPS_DllAPI static void ReportFunctions( + FASTDDS_EXPORTED_API static void ReportFunctions( bool); //! Sets the verbosity level, allowing for messages equal or under that priority to be logged. - RTPS_DllAPI static void SetVerbosity( + FASTDDS_EXPORTED_API static void SetVerbosity( Log::Kind); //! Returns the current verbosity level. - RTPS_DllAPI static Log::Kind GetVerbosity(); + FASTDDS_EXPORTED_API static Log::Kind GetVerbosity(); //! Sets a filter that will pattern-match against log categories, dropping any unmatched categories. - RTPS_DllAPI static void SetCategoryFilter( + FASTDDS_EXPORTED_API static void SetCategoryFilter( const std::regex&); + //! Returns a copy of the current category filter or an empty object otherwise + FASTDDS_EXPORTED_API static std::regex GetCategoryFilter(); + //! Sets a filter that will pattern-match against filenames, dropping any unmatched categories. - RTPS_DllAPI static void SetFilenameFilter( + FASTDDS_EXPORTED_API static void SetFilenameFilter( const std::regex&); + //! Returns a copy of the current filename filter or an empty object otherwise + FASTDDS_EXPORTED_API static std::regex GetFilenameFilter(); + //! Sets a filter that will pattern-match against the provided error string, dropping any unmatched categories. - RTPS_DllAPI static void SetErrorStringFilter( + FASTDDS_EXPORTED_API static void SetErrorStringFilter( const std::regex&); //! Sets thread configuration for the logging thread. - RTPS_DllAPI static void SetThreadConfig( + FASTDDS_EXPORTED_API static void SetThreadConfig( const rtps::ThreadSettings&); + //! Returns a copy of the current error string filter or an empty object otherwise + FASTDDS_EXPORTED_API static std::regex GetErrorStringFilter(); + //! Returns the logging engine to configuration defaults. - RTPS_DllAPI static void Reset(); + FASTDDS_EXPORTED_API static void Reset(); //! Waits until all info logged up to the call time is consumed - RTPS_DllAPI static void Flush(); + FASTDDS_EXPORTED_API static void Flush(); //! Stops the logging thread. It will re-launch on the next call to a successful log macro. - RTPS_DllAPI static void KillThread(); + FASTDDS_EXPORTED_API static void KillThread(); // Note: In VS2013, if you're linking this class statically, you will have to call KillThread before leaving // main, due to an unsolved MSVC bug. @@ -172,7 +181,7 @@ class Log * @todo this method takes 2 mutexes (same mutex) internally. * This is a very high sensible point of the code and it should be refactored to be as efficient as possible. */ - RTPS_DllAPI static void QueueLog( + FASTDDS_EXPORTED_API static void QueueLog( const std::string& message, const Log::Context&, Log::Kind); @@ -218,27 +227,27 @@ class LogConsumer protected: - RTPS_DllAPI void print_timestamp( + FASTDDS_EXPORTED_API void print_timestamp( std::ostream& stream, const Log::Entry&, bool color) const; - RTPS_DllAPI void print_header( + FASTDDS_EXPORTED_API void print_header( std::ostream& stream, const Log::Entry&, bool color) const; - RTPS_DllAPI void print_context( + FASTDDS_EXPORTED_API void print_context( std::ostream& stream, const Log::Entry&, bool color) const; - RTPS_DllAPI void print_message( + FASTDDS_EXPORTED_API void print_message( std::ostream& stream, const Log::Entry&, bool color) const; - RTPS_DllAPI void print_new_line( + FASTDDS_EXPORTED_API void print_new_line( std::ostream& stream, bool color) const; }; @@ -273,17 +282,18 @@ class LogConsumer // Name of variables inside macros must be unique, or it could produce an error with external variables #if !HAVE_LOG_NO_ERROR -#define EPROSIMA_LOG_ERROR_IMPL_(cat, msg) \ +#define EPROSIMA_LOG_ERROR_IMPL_(cat, msg) \ do { \ - using namespace eprosima::fastdds::dds; \ std::stringstream fastdds_log_ss_tmp__; \ fastdds_log_ss_tmp__ << msg; \ - Log::QueueLog(fastdds_log_ss_tmp__.str(), Log::Context{__FILE__, __LINE__, __func__, #cat}, Log::Kind::Error); \ + eprosima::fastdds::dds::Log::QueueLog( \ + fastdds_log_ss_tmp__.str(), eprosima::fastdds::dds::Log::Context{__FILE__, __LINE__, __func__, #cat}, \ + eprosima::fastdds::dds::Log::Kind::Error); \ } while (0) #elif (__INTERNALDEBUG || _INTERNALDEBUG) -#define EPROSIMA_LOG_ERROR_IMPL_(cat, msg) \ +#define EPROSIMA_LOG_ERROR_IMPL_(cat, msg) \ do { \ auto fastdds_log_lambda_tmp__ = [&]() \ { \ @@ -303,21 +313,21 @@ class LogConsumer ***********/ #if !HAVE_LOG_NO_WARNING -#define EPROSIMA_LOG_WARNING_IMPL_(cat, msg) \ - do { \ - using namespace eprosima::fastdds::dds; \ - if (Log::GetVerbosity() >= Log::Kind::Warning) \ - { \ - std::stringstream fastdds_log_ss_tmp__; \ - fastdds_log_ss_tmp__ << msg; \ - Log::QueueLog( \ - fastdds_log_ss_tmp__.str(), Log::Context{__FILE__, __LINE__, __func__, #cat}, Log::Kind::Warning); \ - } \ +#define EPROSIMA_LOG_WARNING_IMPL_(cat, msg) \ + do { \ + if (eprosima::fastdds::dds::Log::GetVerbosity() >= eprosima::fastdds::dds::Log::Kind::Warning) \ + { \ + std::stringstream fastdds_log_ss_tmp__; \ + fastdds_log_ss_tmp__ << msg; \ + eprosima::fastdds::dds::Log::QueueLog( \ + fastdds_log_ss_tmp__.str(), eprosima::fastdds::dds::Log::Context{__FILE__, __LINE__, __func__, #cat}, \ + eprosima::fastdds::dds::Log::Kind::Warning); \ + } \ } while (0) #elif (__INTERNALDEBUG || _INTERNALDEBUG) -#define EPROSIMA_LOG_WARNING_IMPL_(cat, msg) \ +#define EPROSIMA_LOG_WARNING_IMPL_(cat, msg) \ do { \ auto fastdds_log_lambda_tmp__ = [&]() \ { \ @@ -342,16 +352,16 @@ class LogConsumer ((defined(__INTERNALDEBUG) || defined(_INTERNALDEBUG)) && (defined(_DEBUG) || defined(__DEBUG) || \ !defined(NDEBUG)))) -#define EPROSIMA_LOG_INFO_IMPL_(cat, msg) \ - do { \ - using namespace eprosima::fastdds::dds; \ - if (Log::GetVerbosity() >= Log::Kind::Info) \ - { \ - std::stringstream fastdds_log_ss_tmp__; \ - fastdds_log_ss_tmp__ << msg; \ - Log::QueueLog(fastdds_log_ss_tmp__.str(), Log::Context{__FILE__, __LINE__, __func__, #cat}, \ - Log::Kind::Info); \ - } \ +#define EPROSIMA_LOG_INFO_IMPL_(cat, msg) \ + do { \ + if (eprosima::fastdds::dds::Log::GetVerbosity() >= eprosima::fastdds::dds::Log::Kind::Info) \ + { \ + std::stringstream fastdds_log_ss_tmp__; \ + fastdds_log_ss_tmp__ << msg; \ + eprosima::fastdds::dds::Log::QueueLog( \ + fastdds_log_ss_tmp__.str(), eprosima::fastdds::dds::Log::Context{__FILE__, __LINE__, __func__, #cat}, \ + eprosima::fastdds::dds::Log::Kind::Info); \ + } \ } while (0) #elif (__INTERNALDEBUG || _INTERNALDEBUG) diff --git a/include/fastdds/dds/log/OStreamConsumer.hpp b/include/fastdds/dds/log/OStreamConsumer.hpp index b8a5a1c1cda..50550671b28 100644 --- a/include/fastdds/dds/log/OStreamConsumer.hpp +++ b/include/fastdds/dds/log/OStreamConsumer.hpp @@ -38,7 +38,7 @@ class OStreamConsumer : public LogConsumer * Called by Log to ask us to consume the Entry. * @param Log::Entry to consume. */ - RTPS_DllAPI void Consume( + FASTDDS_EXPORTED_API void Consume( const Log::Entry& entry) override; protected: @@ -47,7 +47,7 @@ class OStreamConsumer : public LogConsumer * Called by Log consume to get the correct stream * @param Log::Entry to consume. */ - RTPS_DllAPI virtual std::ostream& get_stream( + FASTDDS_EXPORTED_API virtual std::ostream& get_stream( const Log::Entry& entry) = 0; }; diff --git a/include/fastdds/dds/log/StdoutConsumer.hpp b/include/fastdds/dds/log/StdoutConsumer.hpp index 1c7e304a6ac..f1a73f443a7 100644 --- a/include/fastdds/dds/log/StdoutConsumer.hpp +++ b/include/fastdds/dds/log/StdoutConsumer.hpp @@ -34,7 +34,7 @@ class StdoutConsumer : public OStreamConsumer * Called by Log consume to get the correct stream * @param Log::Entry to consume. */ - RTPS_DllAPI virtual std::ostream& get_stream( + FASTDDS_EXPORTED_API virtual std::ostream& get_stream( const Log::Entry& entry) override; }; diff --git a/include/fastdds/dds/log/StdoutErrConsumer.hpp b/include/fastdds/dds/log/StdoutErrConsumer.hpp index 1464645058a..1f71506f420 100644 --- a/include/fastdds/dds/log/StdoutErrConsumer.hpp +++ b/include/fastdds/dds/log/StdoutErrConsumer.hpp @@ -44,14 +44,14 @@ class StdoutErrConsumer : public OStreamConsumer * std::cout. * @param kind The Log::Kind to which stderr_threshold is set. */ - RTPS_DllAPI virtual void stderr_threshold( + FASTDDS_EXPORTED_API virtual void stderr_threshold( const Log::Kind& kind); /** * @brief Retrieve the stderr_threshold. * @return The Log::Kind to which stderr_threshold is set. */ - RTPS_DllAPI virtual Log::Kind stderr_threshold() const; + FASTDDS_EXPORTED_API virtual Log::Kind stderr_threshold() const; /** * @brief Default value of stderr_threshold. @@ -64,7 +64,7 @@ class StdoutErrConsumer : public OStreamConsumer * Called by Log consume to get the correct stream * @param Log::Entry to consume. */ - RTPS_DllAPI virtual std::ostream& get_stream( + FASTDDS_EXPORTED_API virtual std::ostream& get_stream( const Log::Entry& entry) override; private: diff --git a/include/fastdds/dds/publisher/DataWriter.hpp b/include/fastdds/dds/publisher/DataWriter.hpp index 239e9ee5851..58e0c9b64c0 100644 --- a/include/fastdds/dds/publisher/DataWriter.hpp +++ b/include/fastdds/dds/publisher/DataWriter.hpp @@ -21,21 +21,16 @@ #include #include +#include #include +#include #include #include #include #include - #include #include - -#include - -#include -#include - -using eprosima::fastrtps::types::ReturnCode_t; +#include namespace eprosima { namespace fastrtps { @@ -129,7 +124,7 @@ class DataWriter : public DomainEntity * @return RETCODE_OK is successfully enabled. RETCODE_PRECONDITION_NOT_MET if the Publisher creating this * DataWriter is not enabled. */ - RTPS_DllAPI ReturnCode_t enable() override; + FASTDDS_EXPORTED_API ReturnCode_t enable() override; /** * Write data to the topic. @@ -137,7 +132,7 @@ class DataWriter : public DomainEntity * @param data Pointer to the data * @return True if correct, false otherwise */ - RTPS_DllAPI bool write( + FASTDDS_EXPORTED_API bool write( void* data); /** @@ -147,7 +142,7 @@ class DataWriter : public DomainEntity * @param params Extra write parameters. * @return True if correct, false otherwise */ - RTPS_DllAPI bool write( + FASTDDS_EXPORTED_API bool write( void* data, fastrtps::rtps::WriteParams& params); @@ -162,7 +157,7 @@ class DataWriter : public DomainEntity * @return RETCODE_PRECONDITION_NOT_MET if the handle introduced does not match with the one associated to the data, * RETCODE_OK if the data is correctly sent and RETCODE_ERROR otherwise. */ - RTPS_DllAPI ReturnCode_t write( + FASTDDS_EXPORTED_API ReturnCode_t write( void* data, const InstanceHandle_t& handle); @@ -182,20 +177,11 @@ class DataWriter : public DomainEntity * @param timestamp Time_t used to set the source_timestamp. * @return Any of the standard return codes. */ - RTPS_DllAPI ReturnCode_t write_w_timestamp( + FASTDDS_EXPORTED_API ReturnCode_t write_w_timestamp( void* data, const InstanceHandle_t& handle, const fastrtps::Time_t& timestamp); -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_DEPRECATED_UNTIL(3, "eprosima::fastdds::dds:DataWriter::write_w_timestamp()", - "In favor of version using eprosima::fastrtps::Time_t.") - RTPS_DllAPI ReturnCode_t write_w_timestamp( - void* data, - const InstanceHandle_t& handle, - const fastrtps::rtps::Time_t& timestamp); -#endif // DOXYGEN_SHOULD_SKIP_THIS - /*! * @brief Informs that the application will be modifying a particular instance. * It gives an opportunity to the middleware to pre-configure itself to improve performance. @@ -205,7 +191,7 @@ class DataWriter : public DomainEntity * This handle could be used in successive `write` or `dispose` operations. * In case of error, HANDLE_NIL will be returned. */ - RTPS_DllAPI InstanceHandle_t register_instance( + FASTDDS_EXPORTED_API InstanceHandle_t register_instance( void* instance); /** @@ -226,18 +212,10 @@ class DataWriter : public DomainEntity * @param timestamp Time_t used to set the source_timestamp. * @return Handle containing the instance's key. */ - RTPS_DllAPI InstanceHandle_t register_instance_w_timestamp( + FASTDDS_EXPORTED_API InstanceHandle_t register_instance_w_timestamp( void* instance, const fastrtps::Time_t& timestamp); -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_DEPRECATED_UNTIL(3, "eprosima::fastdds::dds:DataWriter::register_instance_w_timestamp()", - "In favor of version using eprosima::fastrtps::Time_t.") - RTPS_DllAPI InstanceHandle_t register_instance_w_timestamp( - void* instance, - const fastrtps::rtps::Time_t& timestamp); -#endif // DOXYGEN_SHOULD_SKIP_THIS - /*! * @brief This operation reverses the action of `register_instance`. * It should only be called on an instance that is currently registered. @@ -247,9 +225,9 @@ class DataWriter : public DomainEntity * @param[in] instance Sample used to deduce instance's key in case of `handle` parameter is HANDLE_NIL. * @param[in] handle Instance's key to be unregistered. * @return Returns the operation's result. - * If the operation finishes successfully, ReturnCode_t::RETCODE_OK is returned. + * If the operation finishes successfully, RETCODE_OK is returned. */ - RTPS_DllAPI ReturnCode_t unregister_instance( + FASTDDS_EXPORTED_API ReturnCode_t unregister_instance( void* instance, const InstanceHandle_t& handle); @@ -272,20 +250,11 @@ class DataWriter : public DomainEntity * @param timestamp Time_t used to set the source_timestamp. * @return Handle containing the instance's key. */ - RTPS_DllAPI ReturnCode_t unregister_instance_w_timestamp( + FASTDDS_EXPORTED_API ReturnCode_t unregister_instance_w_timestamp( void* instance, const InstanceHandle_t& handle, const fastrtps::Time_t& timestamp); -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_DEPRECATED_UNTIL(3, "eprosima::fastdds::dds:DataWriter::unregister_instance_w_timestamp()", - "In favor of version using eprosima::fastrtps::Time_t.") - RTPS_DllAPI ReturnCode_t unregister_instance_w_timestamp( - void* instance, - const InstanceHandle_t& handle, - const fastrtps::rtps::Time_t& timestamp); -#endif // DOXYGEN_SHOULD_SKIP_THIS - /** * This operation can be used to retrieve the instance key that corresponds to an * @ref eprosima::fastdds::dds::Entity::instance_handle_ "instance_handle". @@ -300,7 +269,7 @@ class DataWriter : public DomainEntity * * @return Any of the standard return codes. */ - RTPS_DllAPI ReturnCode_t get_key_value( + FASTDDS_EXPORTED_API ReturnCode_t get_key_value( void* key_holder, const InstanceHandle_t& handle); @@ -315,7 +284,7 @@ class DataWriter : public DomainEntity * * @return handle of the given instance */ - RTPS_DllAPI InstanceHandle_t lookup_instance( + FASTDDS_EXPORTED_API InstanceHandle_t lookup_instance( const void* instance) const; /** @@ -323,21 +292,21 @@ class DataWriter : public DomainEntity * * @return Reference to the DataWriter GUID */ - RTPS_DllAPI const fastrtps::rtps::GUID_t& guid() const; + FASTDDS_EXPORTED_API const fastrtps::rtps::GUID_t& guid() const; /** * Returns the DataWriter's InstanceHandle * * @return Copy of the DataWriter InstanceHandle */ - RTPS_DllAPI InstanceHandle_t get_instance_handle() const; + FASTDDS_EXPORTED_API InstanceHandle_t get_instance_handle() const; /** * Get data type associated to the DataWriter * * @return Copy of the TypeSupport */ - RTPS_DllAPI TypeSupport get_type() const; + FASTDDS_EXPORTED_API TypeSupport get_type() const; /** * Waits the current thread until all writers have received their acknowledgments. @@ -345,7 +314,7 @@ class DataWriter : public DomainEntity * @param max_wait Maximum blocking time for this operation * @return RETCODE_OK if the DataWriter receive the acknowledgments before the time expires and RETCODE_ERROR otherwise */ - RTPS_DllAPI ReturnCode_t wait_for_acknowledgments( + FASTDDS_EXPORTED_API ReturnCode_t wait_for_acknowledgments( const fastrtps::Duration_t& max_wait); /** @@ -354,7 +323,7 @@ class DataWriter : public DomainEntity * @param[out] status Deadline missed status struct * @return RETCODE_OK */ - RTPS_DllAPI ReturnCode_t get_offered_deadline_missed_status( + FASTDDS_EXPORTED_API ReturnCode_t get_offered_deadline_missed_status( OfferedDeadlineMissedStatus& status); /** @@ -363,7 +332,7 @@ class DataWriter : public DomainEntity * @param[out] status Offered incompatible qos status struct * @return RETCODE_OK */ - RTPS_DllAPI ReturnCode_t get_offered_incompatible_qos_status( + FASTDDS_EXPORTED_API ReturnCode_t get_offered_incompatible_qos_status( OfferedIncompatibleQosStatus& status); /** @@ -372,7 +341,7 @@ class DataWriter : public DomainEntity * @param[out] status publication matched status struct * @return RETCODE_OK */ - RTPS_DllAPI ReturnCode_t get_publication_matched_status( + FASTDDS_EXPORTED_API ReturnCode_t get_publication_matched_status( PublicationMatchedStatus& status) const; /** @@ -382,7 +351,7 @@ class DataWriter : public DomainEntity * @return RETCODE_IMMUTABLE_POLICY if any of the Qos cannot be changed, RETCODE_INCONSISTENT_POLICY if the Qos is not * self consistent and RETCODE_OK if the qos is changed correctly. */ - RTPS_DllAPI ReturnCode_t set_qos( + FASTDDS_EXPORTED_API ReturnCode_t set_qos( const DataWriterQos& qos); /** @@ -390,7 +359,7 @@ class DataWriter : public DomainEntity * * @return Reference to the current DataWriterQos */ - RTPS_DllAPI const DataWriterQos& get_qos() const; + FASTDDS_EXPORTED_API const DataWriterQos& get_qos() const; /** * Fills the DataWriterQos with the values of this DataWriter. @@ -398,7 +367,7 @@ class DataWriter : public DomainEntity * @param qos DataWriterQos object where the qos is returned. * @return RETCODE_OK */ - RTPS_DllAPI ReturnCode_t get_qos( + FASTDDS_EXPORTED_API ReturnCode_t get_qos( DataWriterQos& qos) const; /** @@ -406,14 +375,14 @@ class DataWriter : public DomainEntity * * @return Pointer to the associated Topic */ - RTPS_DllAPI Topic* get_topic() const; + FASTDDS_EXPORTED_API Topic* get_topic() const; /** * Retrieves the listener for this DataWriter. * * @return Pointer to the DataWriterListener */ - RTPS_DllAPI const DataWriterListener* get_listener() const; + FASTDDS_EXPORTED_API const DataWriterListener* get_listener() const; /** * Modifies the DataWriterListener, sets the mask to StatusMask::all() @@ -421,7 +390,7 @@ class DataWriter : public DomainEntity * @param listener new value for the DataWriterListener * @return RETCODE_OK */ - RTPS_DllAPI ReturnCode_t set_listener( + FASTDDS_EXPORTED_API ReturnCode_t set_listener( DataWriterListener* listener); /** @@ -431,7 +400,7 @@ class DataWriter : public DomainEntity * @param mask StatusMask that holds statuses the listener responds to (default: all). * @return RETCODE_OK */ - RTPS_DllAPI ReturnCode_t set_listener( + FASTDDS_EXPORTED_API ReturnCode_t set_listener( DataWriterListener* listener, const StatusMask& mask); @@ -450,7 +419,7 @@ class DataWriter : public DomainEntity * @return RETCODE_PRECONDITION_NOT_MET if the handle introduced does not match with the one associated to the data, * RETCODE_OK if the data is correctly sent and RETCODE_ERROR otherwise. */ - RTPS_DllAPI ReturnCode_t dispose( + FASTDDS_EXPORTED_API ReturnCode_t dispose( void* data, const InstanceHandle_t& handle); @@ -472,9 +441,9 @@ class DataWriter : public DomainEntity * @param instance Sample used to deduce instance's key in case of `handle` parameter is HANDLE_NIL. * @param handle Instance's key to be disposed. * @param timestamp Time_t used to set the source_timestamp. - * @return RTPS_DllAPI + * @return FASTDDS_EXPORTED_API */ - RTPS_DllAPI ReturnCode_t dispose_w_timestamp( + FASTDDS_EXPORTED_API ReturnCode_t dispose_w_timestamp( void* instance, const InstanceHandle_t& handle, const fastrtps::Time_t& timestamp); @@ -484,7 +453,7 @@ class DataWriter : public DomainEntity * @param status Liveliness lost status struct * @return RETCODE_OK */ - RTPS_DllAPI ReturnCode_t get_liveliness_lost_status( + FASTDDS_EXPORTED_API ReturnCode_t get_liveliness_lost_status( LivelinessLostStatus& status); /** @@ -492,7 +461,7 @@ class DataWriter : public DomainEntity * * @return Pointer to the Publisher */ - RTPS_DllAPI const Publisher* get_publisher() const; + FASTDDS_EXPORTED_API const Publisher* get_publisher() const; /** * @brief This operation manually asserts the liveliness of the DataWriter. This is used in combination with the @@ -506,7 +475,7 @@ class DataWriter : public DomainEntity * * @return RETCODE_OK if asserted, RETCODE_ERROR otherwise */ - RTPS_DllAPI ReturnCode_t assert_liveliness(); + FASTDDS_EXPORTED_API ReturnCode_t assert_liveliness(); /** * @brief Retrieves in a subscription associated with the DataWriter @@ -514,9 +483,10 @@ class DataWriter : public DomainEntity * @param[out] subscription_data subscription data struct * @param subscription_handle InstanceHandle_t of the subscription * @return RETCODE_OK + * * @warning Not supported yet. Currently returns RETCODE_UNSUPPORTED */ - RTPS_DllAPI ReturnCode_t get_matched_subscription_data( + FASTDDS_EXPORTED_API ReturnCode_t get_matched_subscription_data( builtin::SubscriptionBuiltinTopicData& subscription_data, const InstanceHandle_t& subscription_handle) const; @@ -525,25 +495,19 @@ class DataWriter : public DomainEntity * * @param[out] subscription_handles Vector where the InstanceHandle_t are returned * @return RETCODE_OK + * * @warning Not supported yet. Currently returns RETCODE_UNSUPPORTED */ - RTPS_DllAPI ReturnCode_t get_matched_subscriptions( + FASTDDS_EXPORTED_API ReturnCode_t get_matched_subscriptions( std::vector& subscription_handles) const; -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_DEPRECATED_UNTIL(3, "eprosima::fastdds::dds:DataWriter::get_matched_subscriptions()", - "In favor of version using std::vector.") - RTPS_DllAPI ReturnCode_t get_matched_subscriptions( - std::vector& subscription_handles) const; -#endif // DOXYGEN_SHOULD_SKIP_THIS - /** * @brief Clears the DataWriter history * * @param removed size_t pointer to return the size of the data removed * @return RETCODE_OK if the samples are removed and RETCODE_ERROR otherwise */ - RTPS_DllAPI ReturnCode_t clear_history( + FASTDDS_EXPORTED_API ReturnCode_t clear_history( size_t* removed); /** @@ -566,12 +530,12 @@ class DataWriter : public DomainEntity * @param [out] sample Pointer to the sample on the internal pool. * @param [in] initialization How to initialize the loaned sample. * - * @return ReturnCode_t::RETCODE_ILLEGAL_OPERATION when the data type does not support loans. - * @return ReturnCode_t::RETCODE_NOT_ENABLED if the writer has not been enabled. - * @return ReturnCode_t::RETCODE_OUT_OF_RESOURCES if the pool has been exhausted. - * @return ReturnCode_t::RETCODE_OK if a pointer to a sample is successfully obtained. + * @return RETCODE_ILLEGAL_OPERATION when the data type does not support loans. + * @return RETCODE_NOT_ENABLED if the writer has not been enabled. + * @return RETCODE_OUT_OF_RESOURCES if the pool has been exhausted. + * @return RETCODE_OK if a pointer to a sample is successfully obtained. */ - RTPS_DllAPI ReturnCode_t loan_sample( + FASTDDS_EXPORTED_API ReturnCode_t loan_sample( void*& sample, LoanInitializationKind initialization = LoanInitializationKind::NO_LOAN_INITIALIZATION); @@ -582,12 +546,12 @@ class DataWriter : public DomainEntity * * @param [in,out] sample Pointer to the previously loaned sample. * - * @return ReturnCode_t::RETCODE_ILLEGAL_OPERATION when the data type does not support loans. - * @return ReturnCode_t::RETCODE_NOT_ENABLED if the writer has not been enabled. - * @return ReturnCode_t::RETCODE_BAD_PARAMETER if the pointer does not correspond to a loaned sample. - * @return ReturnCode_t::RETCODE_OK if the loan is successfully discarded. + * @return RETCODE_ILLEGAL_OPERATION when the data type does not support loans. + * @return RETCODE_NOT_ENABLED if the writer has not been enabled. + * @return RETCODE_BAD_PARAMETER if the pointer does not correspond to a loaned sample. + * @return RETCODE_OK if the loan is successfully discarded. */ - RTPS_DllAPI ReturnCode_t discard_loan( + FASTDDS_EXPORTED_API ReturnCode_t discard_loan( void*& sample); /** @@ -598,7 +562,7 @@ class DataWriter : public DomainEntity * @return NOT_ENABLED if the reader has not been enabled. * @return OK if a list of locators is returned. */ - RTPS_DllAPI ReturnCode_t get_sending_locators( + FASTDDS_EXPORTED_API ReturnCode_t get_sending_locators( rtps::LocatorList& locators) const; /** @@ -617,7 +581,7 @@ class DataWriter : public DomainEntity * @return RETCODE_OK if the DataWriter received the acknowledgments before the time expired. * @return RETCODE_TIMEOUT otherwise. */ - RTPS_DllAPI ReturnCode_t wait_for_acknowledgments( + FASTDDS_EXPORTED_API ReturnCode_t wait_for_acknowledgments( void* instance, const InstanceHandle_t& handle, const fastrtps::Duration_t& max_wait); diff --git a/include/fastdds/dds/publisher/DataWriterListener.hpp b/include/fastdds/dds/publisher/DataWriterListener.hpp index db0f6723968..b75bf6bbcc1 100644 --- a/include/fastdds/dds/publisher/DataWriterListener.hpp +++ b/include/fastdds/dds/publisher/DataWriterListener.hpp @@ -16,8 +16,8 @@ * @file DataWriterListener.hpp */ -#ifndef _FASTRTPS_DATAWRITERLISTENER_HPP_ -#define _FASTRTPS_DATAWRITERLISTENER_HPP_ +#ifndef _FASTDDS_DATAWRITERLISTENER_HPP_ +#define _FASTDDS_DATAWRITERLISTENER_HPP_ #include #include @@ -35,7 +35,7 @@ class DataWriter; * Class DataWriterListener, allows the end user to implement callbacks triggered by certain events. * @ingroup FASTDDS_MODULE */ -class RTPS_DllAPI DataWriterListener +class FASTDDS_EXPORTED_API DataWriterListener { public: @@ -129,4 +129,4 @@ class RTPS_DllAPI DataWriterListener } /* namespace fastdds */ } /* namespace eprosima */ -#endif /* _FASTRTPS_DATAWRITERLISTENER_HPP_ */ +#endif /* _FASTDDS_DATAWRITERLISTENER_HPP_ */ diff --git a/include/fastdds/dds/publisher/Publisher.hpp b/include/fastdds/dds/publisher/Publisher.hpp index 326add33f17..867d15134b7 100644 --- a/include/fastdds/dds/publisher/Publisher.hpp +++ b/include/fastdds/dds/publisher/Publisher.hpp @@ -21,15 +21,13 @@ #define _FASTDDS_PUBLISHER_HPP_ #include +#include #include #include #include #include -#include -#include - -using eprosima::fastrtps::types::ReturnCode_t; +#include namespace dds { namespace pub { @@ -93,21 +91,21 @@ class Publisher : public DomainEntity * @return RETCODE_OK is successfully enabled. RETCODE_PRECONDITION_NOT_MET if the participant creating this * Publisher is not enabled. */ - RTPS_DllAPI ReturnCode_t enable() override; + FASTDDS_EXPORTED_API ReturnCode_t enable() override; /** * Allows accessing the Publisher Qos. * * @return PublisherQos reference */ - RTPS_DllAPI const PublisherQos& get_qos() const; + FASTDDS_EXPORTED_API const PublisherQos& get_qos() const; /** * Retrieves the Publisher Qos. * * @return RETCODE_OK */ - RTPS_DllAPI ReturnCode_t get_qos( + FASTDDS_EXPORTED_API ReturnCode_t get_qos( PublisherQos& qos) const; /** @@ -118,7 +116,7 @@ class Publisher : public DomainEntity * @return RETCODE_IMMUTABLE_POLICY if any of the Qos cannot be changed, RETCODE_INCONSISTENT_POLICY if the Qos is not * self consistent and RETCODE_OK if the qos is changed correctly. */ - RTPS_DllAPI ReturnCode_t set_qos( + FASTDDS_EXPORTED_API ReturnCode_t set_qos( const PublisherQos& qos); /** @@ -126,7 +124,7 @@ class Publisher : public DomainEntity * * @return PublisherListener pointer */ - RTPS_DllAPI const PublisherListener* get_listener() const; + FASTDDS_EXPORTED_API const PublisherListener* get_listener() const; /** * Modifies the PublisherListener, sets the mask to StatusMask::all() @@ -134,7 +132,7 @@ class Publisher : public DomainEntity * @param listener new value for the PublisherListener * @return RETCODE_OK */ - RTPS_DllAPI ReturnCode_t set_listener( + FASTDDS_EXPORTED_API ReturnCode_t set_listener( PublisherListener* listener); /** @@ -144,7 +142,7 @@ class Publisher : public DomainEntity * @param mask StatusMask that holds statuses the listener responds to * @return RETCODE_OK */ - RTPS_DllAPI ReturnCode_t set_listener( + FASTDDS_EXPORTED_API ReturnCode_t set_listener( PublisherListener* listener, const StatusMask& mask); @@ -158,7 +156,7 @@ class Publisher : public DomainEntity * @param payload_pool IPayloadPool shared pointer that defines writer payload (default: nullptr). * @return Pointer to the created DataWriter. nullptr if failed. */ - RTPS_DllAPI DataWriter* create_datawriter( + FASTDDS_EXPORTED_API DataWriter* create_datawriter( Topic* topic, const DataWriterQos& qos, DataWriterListener* listener = nullptr, @@ -175,7 +173,7 @@ class Publisher : public DomainEntity * @param payload_pool IPayloadPool shared pointer that defines writer payload (default: nullptr). * @return Pointer to the created DataWriter. nullptr if failed. */ - RTPS_DllAPI DataWriter* create_datawriter_with_profile( + FASTDDS_EXPORTED_API DataWriter* create_datawriter_with_profile( Topic* topic, const std::string& profile_name, DataWriterListener* listener = nullptr, @@ -197,7 +195,7 @@ class Publisher : public DomainEntity * @return RETCODE_PRECONDITION_NOT_MET if it does not belong to this Publisher, RETCODE_OK if it is correctly deleted and * RETCODE_ERROR otherwise. */ - RTPS_DllAPI ReturnCode_t delete_datawriter( + FASTDDS_EXPORTED_API ReturnCode_t delete_datawriter( const DataWriter* writer); /** @@ -210,40 +208,44 @@ class Publisher : public DomainEntity * @param topic_name Name of the Topic * @return Pointer to a previously created DataWriter associated to a Topic with the requested topic_name */ - RTPS_DllAPI DataWriter* lookup_datawriter( + FASTDDS_EXPORTED_API DataWriter* lookup_datawriter( const std::string& topic_name) const; /** * @brief Indicates to FastDDS that the contained DataWriters are about to be modified * * @return RETCODE_OK if successful, an error code otherwise + * * @warning Not supported yet. Currently returns RETCODE_UNSUPPORTED */ - RTPS_DllAPI ReturnCode_t suspend_publications(); + FASTDDS_EXPORTED_API ReturnCode_t suspend_publications(); /** * @brief Indicates to FastDDS that the modifications to the DataWriters are complete. * * @return RETCODE_OK if successful, an error code otherwise + * * @warning Not supported yet. Currently returns RETCODE_UNSUPPORTED */ - RTPS_DllAPI ReturnCode_t resume_publications(); + FASTDDS_EXPORTED_API ReturnCode_t resume_publications(); /** * @brief Signals the beginning of a set of coherent cache changes using the Datawriters attached to the publisher * * @return RETCODE_OK if successful, an error code otherwise + * * @warning Not supported yet. Currently returns RETCODE_UNSUPPORTED */ - RTPS_DllAPI ReturnCode_t begin_coherent_changes(); + FASTDDS_EXPORTED_API ReturnCode_t begin_coherent_changes(); /** * @brief Signals the end of a set of coherent cache changes * * @return RETCODE_OK if successful, an error code otherwise + * * @warning Not supported yet. Currently returns RETCODE_UNSUPPORTED */ - RTPS_DllAPI ReturnCode_t end_coherent_changes(); + FASTDDS_EXPORTED_API ReturnCode_t end_coherent_changes(); /** * This operation blocks the calling thread until either all data written by the reliable DataWriter entities @@ -256,7 +258,7 @@ class Publisher : public DomainEntity * @return RETCODE_TIMEOUT if the function takes more than the maximum blocking time established, RETCODE_OK if the * Publisher receives the acknowledgments and RETCODE_ERROR otherwise. */ - RTPS_DllAPI ReturnCode_t wait_for_acknowledgments( + FASTDDS_EXPORTED_API ReturnCode_t wait_for_acknowledgments( const fastrtps::Duration_t& max_wait); /** @@ -264,14 +266,14 @@ class Publisher : public DomainEntity * * @return Pointer to the DomainParticipant */ - RTPS_DllAPI const DomainParticipant* get_participant() const; + FASTDDS_EXPORTED_API const DomainParticipant* get_participant() const; /** * @brief Deletes all contained DataWriters * * @return RETCODE_OK if successful, an error code otherwise */ - RTPS_DllAPI ReturnCode_t delete_contained_entities(); + FASTDDS_EXPORTED_API ReturnCode_t delete_contained_entities(); /** * This operation sets a default value of the DataWriter QoS policies which will be used for newly created @@ -287,7 +289,7 @@ class Publisher : public DomainEntity * @param qos DataWriterQos to be set * @return RETCODE_INCONSISTENT_POLICY if the Qos is not self consistent and RETCODE_OK if the qos is changed correctly. */ - RTPS_DllAPI ReturnCode_t set_default_datawriter_qos( + FASTDDS_EXPORTED_API ReturnCode_t set_default_datawriter_qos( const DataWriterQos& qos); /** @@ -300,7 +302,7 @@ class Publisher : public DomainEntity * * @return Current default WriterQos */ - RTPS_DllAPI const DataWriterQos& get_default_datawriter_qos() const; + FASTDDS_EXPORTED_API const DataWriterQos& get_default_datawriter_qos() const; /** * This operation retrieves the default value of the DataWriter QoS, that is, the QoS policies which will be used @@ -313,7 +315,7 @@ class Publisher : public DomainEntity * @param qos Reference to the current default WriterQos. * @return RETCODE_OK */ - RTPS_DllAPI ReturnCode_t get_default_datawriter_qos( + FASTDDS_EXPORTED_API ReturnCode_t get_default_datawriter_qos( DataWriterQos& qos) const; /** @@ -322,8 +324,10 @@ class Publisher : public DomainEntity * @param[out] writer_qos * @param[in] topic_qos * @return RETCODE_OK if successful, an error code otherwise + * + * @warning Not supported yet. Currently returns RETCODE_UNSUPPORTED */ - RTPS_DllAPI static ReturnCode_t copy_from_topic_qos( + FASTDDS_EXPORTED_API static ReturnCode_t copy_from_topic_qos( fastdds::dds::DataWriterQos& writer_qos, const fastdds::dds::TopicQos& topic_qos); @@ -334,7 +338,7 @@ class Publisher : public DomainEntity * @param qos DataWriterQos object where the qos is returned. * @return RETCODE_OK if the profile exists. RETCODE_BAD_PARAMETER otherwise. */ - RTPS_DllAPI ReturnCode_t get_datawriter_qos_from_profile( + FASTDDS_EXPORTED_API ReturnCode_t get_datawriter_qos_from_profile( const std::string& profile_name, DataWriterQos& qos) const; @@ -343,7 +347,7 @@ class Publisher : public DomainEntity * * @return InstanceHandle of this Publisher. */ - RTPS_DllAPI const InstanceHandle_t& get_instance_handle() const; + FASTDDS_EXPORTED_API const InstanceHandle_t& get_instance_handle() const; /** * Fills the given vector with all the datawriters of this publisher. @@ -351,7 +355,7 @@ class Publisher : public DomainEntity * @param writers Vector where the DataWriters are returned * @return true */ - RTPS_DllAPI bool get_datawriters( + FASTDDS_EXPORTED_API bool get_datawriters( std::vector& writers) const; /** @@ -359,7 +363,7 @@ class Publisher : public DomainEntity * * @return true if the publisher has one or several DataWriters, false otherwise */ - RTPS_DllAPI bool has_datawriters() const; + FASTDDS_EXPORTED_API bool has_datawriters() const; protected: diff --git a/include/fastdds/dds/publisher/PublisherListener.hpp b/include/fastdds/dds/publisher/PublisherListener.hpp index 1045c544a2c..2a27ae26d57 100644 --- a/include/fastdds/dds/publisher/PublisherListener.hpp +++ b/include/fastdds/dds/publisher/PublisherListener.hpp @@ -19,8 +19,8 @@ #ifndef _FASTDDS_PUBLISHERLISTENER_HPP_ #define _FASTDDS_PUBLISHERLISTENER_HPP_ -#include #include +#include #include #include @@ -42,14 +42,14 @@ class PublisherListener : public DataWriterListener /** * @brief Constructor */ - RTPS_DllAPI PublisherListener() + FASTDDS_EXPORTED_API PublisherListener() { } /** * @brief Destructor */ - RTPS_DllAPI virtual ~PublisherListener() + FASTDDS_EXPORTED_API virtual ~PublisherListener() { } diff --git a/include/fastdds/dds/publisher/qos/DataWriterQos.hpp b/include/fastdds/dds/publisher/qos/DataWriterQos.hpp index d14ba2ea9f5..291982d6829 100644 --- a/include/fastdds/dds/publisher/qos/DataWriterQos.hpp +++ b/include/fastdds/dds/publisher/qos/DataWriterQos.hpp @@ -41,14 +41,14 @@ class RTPSReliableWriterQos /** * @brief Constructor */ - RTPS_DllAPI RTPSReliableWriterQos() + FASTDDS_EXPORTED_API RTPSReliableWriterQos() { } /** * @brief Destructor */ - virtual RTPS_DllAPI ~RTPSReliableWriterQos() = default; + virtual FASTDDS_EXPORTED_API ~RTPSReliableWriterQos() = default; bool operator ==( const RTPSReliableWriterQos& b) const @@ -83,14 +83,14 @@ class DataWriterQos /** * @brief Constructor */ - RTPS_DllAPI DataWriterQos(); + FASTDDS_EXPORTED_API DataWriterQos(); /** * @brief Destructor */ - RTPS_DllAPI ~DataWriterQos() = default; + FASTDDS_EXPORTED_API ~DataWriterQos() = default; - RTPS_DllAPI bool operator ==( + FASTDDS_EXPORTED_API bool operator ==( const DataWriterQos& b) const { return (this->durability_ == b.durability()) && @@ -118,7 +118,7 @@ class DataWriterQos (this->data_sharing_ == b.data_sharing()); } - RTPS_DllAPI WriterQos get_writerqos( + FASTDDS_EXPORTED_API WriterQos get_writerqos( const PublisherQos& pqos, const TopicQos& tqos) const; @@ -127,7 +127,7 @@ class DataWriterQos * * @return DurabilityQosPolicy reference */ - RTPS_DllAPI DurabilityQosPolicy& durability() + FASTDDS_EXPORTED_API DurabilityQosPolicy& durability() { return durability_; } @@ -137,7 +137,7 @@ class DataWriterQos * * @return DurabilityQosPolicy reference */ - RTPS_DllAPI const DurabilityQosPolicy& durability() const + FASTDDS_EXPORTED_API const DurabilityQosPolicy& durability() const { return durability_; } @@ -147,7 +147,7 @@ class DataWriterQos * * @param durability new value for the DurabilityQosPolicy */ - RTPS_DllAPI void durability( + FASTDDS_EXPORTED_API void durability( const DurabilityQosPolicy& durability) { durability_ = durability; @@ -158,7 +158,7 @@ class DataWriterQos * * @return DurabilityServiceQosPolicy reference */ - RTPS_DllAPI DurabilityServiceQosPolicy& durability_service() + FASTDDS_EXPORTED_API DurabilityServiceQosPolicy& durability_service() { return durability_service_; } @@ -168,7 +168,7 @@ class DataWriterQos * * @return DurabilityServiceQosPolicy reference */ - RTPS_DllAPI const DurabilityServiceQosPolicy& durability_service() const + FASTDDS_EXPORTED_API const DurabilityServiceQosPolicy& durability_service() const { return durability_service_; } @@ -178,7 +178,7 @@ class DataWriterQos * * @param durability_service new value for the DurabilityServiceQosPolicy */ - RTPS_DllAPI void durability_service( + FASTDDS_EXPORTED_API void durability_service( const DurabilityServiceQosPolicy& durability_service) { durability_service_ = durability_service; @@ -189,7 +189,7 @@ class DataWriterQos * * @return DeadlineQosPolicy reference */ - RTPS_DllAPI DeadlineQosPolicy& deadline() + FASTDDS_EXPORTED_API DeadlineQosPolicy& deadline() { return deadline_; } @@ -199,7 +199,7 @@ class DataWriterQos * * @return DeadlineQosPolicy reference */ - RTPS_DllAPI const DeadlineQosPolicy& deadline() const + FASTDDS_EXPORTED_API const DeadlineQosPolicy& deadline() const { return deadline_; } @@ -209,7 +209,7 @@ class DataWriterQos * * @param deadline new value for the DeadlineQosPolicy */ - RTPS_DllAPI void deadline( + FASTDDS_EXPORTED_API void deadline( const DeadlineQosPolicy& deadline) { deadline_ = deadline; @@ -220,7 +220,7 @@ class DataWriterQos * * @return LatencyBudgetQosPolicy reference */ - RTPS_DllAPI LatencyBudgetQosPolicy& latency_budget() + FASTDDS_EXPORTED_API LatencyBudgetQosPolicy& latency_budget() { return latency_budget_; } @@ -230,7 +230,7 @@ class DataWriterQos * * @return LatencyBudgetQosPolicy reference */ - RTPS_DllAPI const LatencyBudgetQosPolicy& latency_budget() const + FASTDDS_EXPORTED_API const LatencyBudgetQosPolicy& latency_budget() const { return latency_budget_; } @@ -240,7 +240,7 @@ class DataWriterQos * * @param latency_budget new value for the LatencyBudgetQosPolicy */ - RTPS_DllAPI void latency_budget( + FASTDDS_EXPORTED_API void latency_budget( const LatencyBudgetQosPolicy& latency_budget) { latency_budget_ = latency_budget; @@ -251,7 +251,7 @@ class DataWriterQos * * @return LivelinessQosPolicy reference */ - RTPS_DllAPI LivelinessQosPolicy& liveliness() + FASTDDS_EXPORTED_API LivelinessQosPolicy& liveliness() { return liveliness_; } @@ -261,7 +261,7 @@ class DataWriterQos * * @return LivelinessQosPolicy reference */ - RTPS_DllAPI const LivelinessQosPolicy& liveliness() const + FASTDDS_EXPORTED_API const LivelinessQosPolicy& liveliness() const { return liveliness_; } @@ -271,7 +271,7 @@ class DataWriterQos * * @param liveliness new value for the LivelinessQosPolicy */ - RTPS_DllAPI void liveliness( + FASTDDS_EXPORTED_API void liveliness( const LivelinessQosPolicy& liveliness) { liveliness_ = liveliness; @@ -282,7 +282,7 @@ class DataWriterQos * * @return ReliabilityQosPolicy reference */ - RTPS_DllAPI ReliabilityQosPolicy& reliability() + FASTDDS_EXPORTED_API ReliabilityQosPolicy& reliability() { return reliability_; } @@ -292,7 +292,7 @@ class DataWriterQos * * @return ReliabilityQosPolicy reference */ - RTPS_DllAPI const ReliabilityQosPolicy& reliability() const + FASTDDS_EXPORTED_API const ReliabilityQosPolicy& reliability() const { return reliability_; } @@ -302,7 +302,7 @@ class DataWriterQos * * @param reliability new value for the ReliabilityQosPolicy */ - RTPS_DllAPI void reliability( + FASTDDS_EXPORTED_API void reliability( const ReliabilityQosPolicy& reliability) { reliability_ = reliability; @@ -313,7 +313,7 @@ class DataWriterQos * * @return DestinationOrderQosPolicy reference */ - RTPS_DllAPI DestinationOrderQosPolicy& destination_order() + FASTDDS_EXPORTED_API DestinationOrderQosPolicy& destination_order() { return destination_order_; } @@ -323,7 +323,7 @@ class DataWriterQos * * @return DestinationOrderQosPolicy reference */ - RTPS_DllAPI const DestinationOrderQosPolicy& destination_order() const + FASTDDS_EXPORTED_API const DestinationOrderQosPolicy& destination_order() const { return destination_order_; } @@ -333,7 +333,7 @@ class DataWriterQos * * @param destination_order new value for the DestinationOrderQosPolicy */ - RTPS_DllAPI void destination_order( + FASTDDS_EXPORTED_API void destination_order( const DestinationOrderQosPolicy& destination_order) { destination_order_ = destination_order; @@ -344,7 +344,7 @@ class DataWriterQos * * @return HistoryQosPolicy reference */ - RTPS_DllAPI HistoryQosPolicy& history() + FASTDDS_EXPORTED_API HistoryQosPolicy& history() { return history_; } @@ -354,7 +354,7 @@ class DataWriterQos * * @return HistoryQosPolicy reference */ - RTPS_DllAPI const HistoryQosPolicy& history() const + FASTDDS_EXPORTED_API const HistoryQosPolicy& history() const { return history_; } @@ -364,7 +364,7 @@ class DataWriterQos * * @param history new value for the HistoryQosPolicy */ - RTPS_DllAPI void history( + FASTDDS_EXPORTED_API void history( const HistoryQosPolicy& history) { history_ = history; @@ -375,7 +375,7 @@ class DataWriterQos * * @return ResourceLimitsQosPolicy reference */ - RTPS_DllAPI ResourceLimitsQosPolicy& resource_limits() + FASTDDS_EXPORTED_API ResourceLimitsQosPolicy& resource_limits() { return resource_limits_; } @@ -385,7 +385,7 @@ class DataWriterQos * * @return ResourceLimitsQosPolicy reference */ - RTPS_DllAPI const ResourceLimitsQosPolicy& resource_limits() const + FASTDDS_EXPORTED_API const ResourceLimitsQosPolicy& resource_limits() const { return resource_limits_; } @@ -395,7 +395,7 @@ class DataWriterQos * * @param resource_limits new value for the ResourceLimitsQosPolicy */ - RTPS_DllAPI void resource_limits( + FASTDDS_EXPORTED_API void resource_limits( const ResourceLimitsQosPolicy& resource_limits) { resource_limits_ = resource_limits; @@ -406,7 +406,7 @@ class DataWriterQos * * @return TransportPriorityQosPolicy reference */ - RTPS_DllAPI TransportPriorityQosPolicy& transport_priority() + FASTDDS_EXPORTED_API TransportPriorityQosPolicy& transport_priority() { return transport_priority_; } @@ -416,7 +416,7 @@ class DataWriterQos * * @return TransportPriorityQosPolicy reference */ - RTPS_DllAPI const TransportPriorityQosPolicy& transport_priority() const + FASTDDS_EXPORTED_API const TransportPriorityQosPolicy& transport_priority() const { return transport_priority_; } @@ -426,7 +426,7 @@ class DataWriterQos * * @param transport_priority new value for the TransportPriorityQosPolicy */ - RTPS_DllAPI void transport_priority( + FASTDDS_EXPORTED_API void transport_priority( const TransportPriorityQosPolicy& transport_priority) { transport_priority_ = transport_priority; @@ -437,7 +437,7 @@ class DataWriterQos * * @return LifespanQosPolicy reference */ - RTPS_DllAPI LifespanQosPolicy& lifespan() + FASTDDS_EXPORTED_API LifespanQosPolicy& lifespan() { return lifespan_; } @@ -447,7 +447,7 @@ class DataWriterQos * * @return LifespanQosPolicy reference */ - RTPS_DllAPI const LifespanQosPolicy& lifespan() const + FASTDDS_EXPORTED_API const LifespanQosPolicy& lifespan() const { return lifespan_; } @@ -457,7 +457,7 @@ class DataWriterQos * * @param lifespan new value for the LifespanQosPolicy */ - RTPS_DllAPI void lifespan( + FASTDDS_EXPORTED_API void lifespan( const LifespanQosPolicy& lifespan) { lifespan_ = lifespan; @@ -468,7 +468,7 @@ class DataWriterQos * * @return UserDataQosPolicy reference */ - RTPS_DllAPI UserDataQosPolicy& user_data() + FASTDDS_EXPORTED_API UserDataQosPolicy& user_data() { return user_data_; } @@ -478,7 +478,7 @@ class DataWriterQos * * @return UserDataQosPolicy reference */ - RTPS_DllAPI const UserDataQosPolicy& user_data() const + FASTDDS_EXPORTED_API const UserDataQosPolicy& user_data() const { return user_data_; } @@ -488,7 +488,7 @@ class DataWriterQos * * @param user_data new value for the UserDataQosPolicy */ - RTPS_DllAPI void user_data( + FASTDDS_EXPORTED_API void user_data( const UserDataQosPolicy& user_data) { user_data_ = user_data; @@ -499,7 +499,7 @@ class DataWriterQos * * @return OwnershipQosPolicy reference */ - RTPS_DllAPI OwnershipQosPolicy& ownership() + FASTDDS_EXPORTED_API OwnershipQosPolicy& ownership() { return ownership_; } @@ -509,7 +509,7 @@ class DataWriterQos * * @return OwnershipQosPolicy reference */ - RTPS_DllAPI const OwnershipQosPolicy& ownership() const + FASTDDS_EXPORTED_API const OwnershipQosPolicy& ownership() const { return ownership_; } @@ -519,7 +519,7 @@ class DataWriterQos * * @param ownership new value for the OwnershipQosPolicy */ - RTPS_DllAPI void ownership( + FASTDDS_EXPORTED_API void ownership( const OwnershipQosPolicy& ownership) { ownership_ = ownership; @@ -530,7 +530,7 @@ class DataWriterQos * * @return OwnershipStrengthQosPolicy reference */ - RTPS_DllAPI OwnershipStrengthQosPolicy& ownership_strength() + FASTDDS_EXPORTED_API OwnershipStrengthQosPolicy& ownership_strength() { return ownership_strength_; } @@ -540,7 +540,7 @@ class DataWriterQos * * @return OwnershipStrengthQosPolicy reference */ - RTPS_DllAPI const OwnershipStrengthQosPolicy& ownership_strength() const + FASTDDS_EXPORTED_API const OwnershipStrengthQosPolicy& ownership_strength() const { return ownership_strength_; } @@ -550,7 +550,7 @@ class DataWriterQos * * @param ownership_strength new value for the OwnershipStrengthQosPolicy */ - RTPS_DllAPI void ownership_strength( + FASTDDS_EXPORTED_API void ownership_strength( const OwnershipStrengthQosPolicy& ownership_strength) { ownership_strength_ = ownership_strength; @@ -561,7 +561,7 @@ class DataWriterQos * * @return WriterDataLifecycleQosPolicy reference */ - RTPS_DllAPI WriterDataLifecycleQosPolicy& writer_data_lifecycle() + FASTDDS_EXPORTED_API WriterDataLifecycleQosPolicy& writer_data_lifecycle() { return writer_data_lifecycle_; } @@ -571,7 +571,7 @@ class DataWriterQos * * @return WriterDataLifecycleQosPolicy reference */ - RTPS_DllAPI const WriterDataLifecycleQosPolicy& writer_data_lifecycle() const + FASTDDS_EXPORTED_API const WriterDataLifecycleQosPolicy& writer_data_lifecycle() const { return writer_data_lifecycle_; } @@ -581,7 +581,7 @@ class DataWriterQos * * @param writer_data_lifecycle new value for the WriterDataLifecycleQosPolicy */ - RTPS_DllAPI void writer_data_lifecycle( + FASTDDS_EXPORTED_API void writer_data_lifecycle( const WriterDataLifecycleQosPolicy& writer_data_lifecycle) { writer_data_lifecycle_ = writer_data_lifecycle; @@ -592,7 +592,7 @@ class DataWriterQos * * @return PublishModeQosPolicy reference */ - RTPS_DllAPI PublishModeQosPolicy& publish_mode() + FASTDDS_EXPORTED_API PublishModeQosPolicy& publish_mode() { return publish_mode_; } @@ -602,7 +602,7 @@ class DataWriterQos * * @return PublishModeQosPolicy reference */ - RTPS_DllAPI const PublishModeQosPolicy& publish_mode() const + FASTDDS_EXPORTED_API const PublishModeQosPolicy& publish_mode() const { return publish_mode_; } @@ -612,7 +612,7 @@ class DataWriterQos * * @param publish_mode new value for the PublishModeQosPolicy */ - RTPS_DllAPI void publish_mode( + FASTDDS_EXPORTED_API void publish_mode( const PublishModeQosPolicy& publish_mode) { publish_mode_ = publish_mode; @@ -623,7 +623,7 @@ class DataWriterQos * * @return DataRepresentationQosPolicy reference */ - RTPS_DllAPI DataRepresentationQosPolicy& representation() + FASTDDS_EXPORTED_API DataRepresentationQosPolicy& representation() { return representation_; } @@ -633,7 +633,7 @@ class DataWriterQos * * @return DataRepresentationQosPolicy reference */ - RTPS_DllAPI const DataRepresentationQosPolicy& representation() const + FASTDDS_EXPORTED_API const DataRepresentationQosPolicy& representation() const { return representation_; } @@ -643,7 +643,7 @@ class DataWriterQos * * @param representation new value for the DataRepresentationQosPolicy */ - RTPS_DllAPI void representation( + FASTDDS_EXPORTED_API void representation( const DataRepresentationQosPolicy& representation) { representation_ = representation; @@ -654,7 +654,7 @@ class DataWriterQos * * @return PropertyPolicyQos reference */ - RTPS_DllAPI PropertyPolicyQos& properties() + FASTDDS_EXPORTED_API PropertyPolicyQos& properties() { return properties_; } @@ -664,7 +664,7 @@ class DataWriterQos * * @return PropertyPolicyQos reference */ - RTPS_DllAPI const PropertyPolicyQos& properties() const + FASTDDS_EXPORTED_API const PropertyPolicyQos& properties() const { return properties_; } @@ -674,7 +674,7 @@ class DataWriterQos * * @param properties new value for the PropertyPolicyQos */ - RTPS_DllAPI void properties( + FASTDDS_EXPORTED_API void properties( const PropertyPolicyQos& properties) { properties_ = properties; @@ -685,7 +685,7 @@ class DataWriterQos * * @return RTPSReliableWriterQos reference */ - RTPS_DllAPI RTPSReliableWriterQos& reliable_writer_qos() + FASTDDS_EXPORTED_API RTPSReliableWriterQos& reliable_writer_qos() { return reliable_writer_qos_; } @@ -695,7 +695,7 @@ class DataWriterQos * * @return RTPSReliableWriterQos reference */ - RTPS_DllAPI const RTPSReliableWriterQos& reliable_writer_qos() const + FASTDDS_EXPORTED_API const RTPSReliableWriterQos& reliable_writer_qos() const { return reliable_writer_qos_; } @@ -705,7 +705,7 @@ class DataWriterQos * * @param reliable_writer_qos new value for the RTPSReliableWriterQos */ - RTPS_DllAPI void reliable_writer_qos( + FASTDDS_EXPORTED_API void reliable_writer_qos( const RTPSReliableWriterQos& reliable_writer_qos) { reliable_writer_qos_ = reliable_writer_qos; @@ -716,7 +716,7 @@ class DataWriterQos * * @return RTPSEndpointQos reference */ - RTPS_DllAPI RTPSEndpointQos& endpoint() + FASTDDS_EXPORTED_API RTPSEndpointQos& endpoint() { return endpoint_; } @@ -725,7 +725,7 @@ class DataWriterQos * Getter for RTPSEndpointQos * @return RTPSEndpointQos reference */ - RTPS_DllAPI const RTPSEndpointQos& endpoint() const + FASTDDS_EXPORTED_API const RTPSEndpointQos& endpoint() const { return endpoint_; } @@ -735,7 +735,7 @@ class DataWriterQos * * @param endpoint new value for the RTPSEndpointQos */ - RTPS_DllAPI void endpoint( + FASTDDS_EXPORTED_API void endpoint( const RTPSEndpointQos& endpoint) { endpoint_ = endpoint; @@ -746,7 +746,7 @@ class DataWriterQos * * @return WriterResourceLimitsQos reference */ - RTPS_DllAPI WriterResourceLimitsQos& writer_resource_limits() + FASTDDS_EXPORTED_API WriterResourceLimitsQos& writer_resource_limits() { return writer_resource_limits_; } @@ -756,7 +756,7 @@ class DataWriterQos * * @return WriterResourceLimitsQos reference */ - RTPS_DllAPI const WriterResourceLimitsQos& writer_resource_limits() const + FASTDDS_EXPORTED_API const WriterResourceLimitsQos& writer_resource_limits() const { return writer_resource_limits_; } @@ -766,7 +766,7 @@ class DataWriterQos * * @param writer_resource_limits new value for the WriterResourceLimitsQos */ - RTPS_DllAPI void writer_resource_limits( + FASTDDS_EXPORTED_API void writer_resource_limits( const WriterResourceLimitsQos& writer_resource_limits) { writer_resource_limits_ = writer_resource_limits; @@ -778,7 +778,7 @@ class DataWriterQos * @return ThroughputControllerDescriptor reference * @deprecated Use flow_controllers() on DomainParticipantQoS */ - RTPS_DllAPI fastrtps::rtps::ThroughputControllerDescriptor& throughput_controller() + FASTDDS_EXPORTED_API fastrtps::rtps::ThroughputControllerDescriptor& throughput_controller() { return throughput_controller_; } @@ -789,7 +789,7 @@ class DataWriterQos * @return ThroughputControllerDescriptor reference * @deprecated Use flow_controllers() on DomainParticipantQoS */ - RTPS_DllAPI const fastrtps::rtps::ThroughputControllerDescriptor& throughput_controller() const + FASTDDS_EXPORTED_API const fastrtps::rtps::ThroughputControllerDescriptor& throughput_controller() const { return throughput_controller_; } @@ -800,7 +800,7 @@ class DataWriterQos * @param throughput_controller new value for the ThroughputControllerDescriptor * @deprecated Use flow_controllers() on DomainParticipantQoS */ - RTPS_DllAPI void throughput_controller( + FASTDDS_EXPORTED_API void throughput_controller( const fastrtps::rtps::ThroughputControllerDescriptor& throughput_controller) { throughput_controller_ = throughput_controller; @@ -811,7 +811,7 @@ class DataWriterQos * * @return DataSharingQosPolicy reference */ - RTPS_DllAPI DataSharingQosPolicy& data_sharing() + FASTDDS_EXPORTED_API DataSharingQosPolicy& data_sharing() { return data_sharing_; } @@ -821,7 +821,7 @@ class DataWriterQos * * @return DataSharingQosPolicy reference */ - RTPS_DllAPI const DataSharingQosPolicy& data_sharing() const + FASTDDS_EXPORTED_API const DataSharingQosPolicy& data_sharing() const { return data_sharing_; } @@ -831,7 +831,7 @@ class DataWriterQos * * @param data_sharing new value for the DataSharingQosPolicy */ - RTPS_DllAPI void data_sharing( + FASTDDS_EXPORTED_API void data_sharing( const DataSharingQosPolicy& data_sharing) { data_sharing_ = data_sharing; @@ -909,8 +909,8 @@ class DataWriterQos DataSharingQosPolicy data_sharing_; }; -RTPS_DllAPI extern const DataWriterQos DATAWRITER_QOS_DEFAULT; -RTPS_DllAPI extern const DataWriterQos DATAWRITER_QOS_USE_TOPIC_QOS; +FASTDDS_EXPORTED_API extern const DataWriterQos DATAWRITER_QOS_DEFAULT; +FASTDDS_EXPORTED_API extern const DataWriterQos DATAWRITER_QOS_USE_TOPIC_QOS; } // namespace dds } // namespace fastdds diff --git a/include/fastdds/dds/publisher/qos/PublisherQos.hpp b/include/fastdds/dds/publisher/qos/PublisherQos.hpp index 52151c4cbdc..42e12a8e0ad 100644 --- a/include/fastdds/dds/publisher/qos/PublisherQos.hpp +++ b/include/fastdds/dds/publisher/qos/PublisherQos.hpp @@ -21,7 +21,6 @@ #define _FASTDDS_PUBLISHERQOS_HPP_ #include -#include namespace eprosima { namespace fastdds { @@ -43,14 +42,14 @@ class PublisherQos /** * @brief Constructor */ - RTPS_DllAPI PublisherQos() + FASTDDS_EXPORTED_API PublisherQos() { } /** * @brief Destructor */ - RTPS_DllAPI virtual ~PublisherQos() = default; + FASTDDS_EXPORTED_API virtual ~PublisherQos() = default; bool operator ==( const PublisherQos& b) const @@ -201,7 +200,7 @@ class PublisherQos }; -RTPS_DllAPI extern const PublisherQos PUBLISHER_QOS_DEFAULT; +FASTDDS_EXPORTED_API extern const PublisherQos PUBLISHER_QOS_DEFAULT; } // namespace dds } // namespace fastdds diff --git a/include/fastdds/dds/publisher/qos/WriterQos.hpp b/include/fastdds/dds/publisher/qos/WriterQos.hpp index 9178fda89b0..337f44769ea 100644 --- a/include/fastdds/dds/publisher/qos/WriterQos.hpp +++ b/include/fastdds/dds/publisher/qos/WriterQos.hpp @@ -31,14 +31,14 @@ namespace dds { * Although these values can be set and are transmitted * during the Endpoint Discovery Protocol, not all of the behaviour associated with them has been implemented in the library. * Please consult each of them to check for implementation details and default values. - * @ingroup FASTRTPS_ATTRIBUTES_MODULE + * @ingroup FASTDDS_QOS_MODULE */ class WriterQos { public: - RTPS_DllAPI WriterQos(); - RTPS_DllAPI virtual ~WriterQos(); + FASTDDS_EXPORTED_API WriterQos(); + FASTDDS_EXPORTED_API virtual ~WriterQos(); bool operator ==( const WriterQos& b) const @@ -133,7 +133,7 @@ class WriterQos * @param qos Reference from a WriterQos object. * @param first_time Boolean indicating whether is the first time (If not some parameters cannot be set). */ - RTPS_DllAPI void setQos( + FASTDDS_EXPORTED_API void setQos( const WriterQos& qos, bool first_time); @@ -141,15 +141,15 @@ class WriterQos * Check if the Qos values are compatible between each other. * @return True if correct. */ - RTPS_DllAPI bool checkQos() const; + FASTDDS_EXPORTED_API bool checkQos() const; - RTPS_DllAPI bool canQosBeUpdated( + FASTDDS_EXPORTED_API bool canQosBeUpdated( const WriterQos& qos) const; void clear(); }; -//RTPS_DllAPI extern const WriterQos DATAWRITER_QOS_DEFAULT; +//FASTDDS_EXPORTED_API extern const WriterQos DATAWRITER_QOS_DEFAULT; } //namespace dds } //namespace fastdds diff --git a/include/fastdds/dds/subscriber/DataReader.hpp b/include/fastdds/dds/subscriber/DataReader.hpp index 61846b6a91b..107800c1e5f 100644 --- a/include/fastdds/dds/subscriber/DataReader.hpp +++ b/include/fastdds/dds/subscriber/DataReader.hpp @@ -27,6 +27,7 @@ #include #include #include +#include #include #include #include @@ -37,15 +38,11 @@ #include #include -#include +#include #include #include -#include - -using eprosima::fastrtps::types::ReturnCode_t; - namespace dds { namespace sub { @@ -117,7 +114,7 @@ class DataReader : public DomainEntity * @return RETCODE_OK is successfully enabled. RETCODE_PRECONDITION_NOT_MET if the Subscriber creating this * DataReader is not enabled. */ - RTPS_DllAPI ReturnCode_t enable() override; + FASTDDS_EXPORTED_API ReturnCode_t enable() override; /** * Method to block the current thread until an unread message is available. @@ -126,7 +123,7 @@ class DataReader : public DomainEntity * * @return true if there is new unread message, false if timeout */ - RTPS_DllAPI bool wait_for_unread_message( + FASTDDS_EXPORTED_API bool wait_for_unread_message( const fastrtps::Duration_t& timeout); /** @@ -135,10 +132,11 @@ class DataReader : public DomainEntity * @brief Method to block the current thread until an unread message is available. * * @param[in] max_wait Max blocking time for this operation. - * @return RETCODE_OK if there is new unread message, ReturnCode_t::RETCODE_TIMEOUT if timeout + * @return RETCODE_OK if there is new unread message, RETCODE_TIMEOUT if timeout + * * @warning Not supported yet. Currently returns RETCODE_UNSUPPORTED */ - RTPS_DllAPI ReturnCode_t wait_for_historical_data( + FASTDDS_EXPORTED_API ReturnCode_t wait_for_historical_data( const fastrtps::Duration_t& max_wait) const; @@ -305,7 +303,7 @@ class DataReader : public DomainEntity * * @return Any of the standard return codes. */ - RTPS_DllAPI ReturnCode_t read( + FASTDDS_EXPORTED_API ReturnCode_t read( LoanableCollection& data_values, SampleInfoSeq& sample_infos, int32_t max_samples = LENGTH_UNLIMITED, @@ -336,7 +334,7 @@ class DataReader : public DomainEntity * * @return Any of the standard return codes. */ - RTPS_DllAPI ReturnCode_t read_w_condition( + FASTDDS_EXPORTED_API ReturnCode_t read_w_condition( LoanableCollection& data_values, SampleInfoSeq& sample_infos, int32_t max_samples, @@ -376,7 +374,7 @@ class DataReader : public DomainEntity * * @return Any of the standard return codes. */ - RTPS_DllAPI ReturnCode_t read_instance( + FASTDDS_EXPORTED_API ReturnCode_t read_instance( LoanableCollection& data_values, SampleInfoSeq& sample_infos, int32_t max_samples = LENGTH_UNLIMITED, @@ -441,7 +439,7 @@ class DataReader : public DomainEntity * * @return Any of the standard return codes. */ - RTPS_DllAPI ReturnCode_t read_next_instance( + FASTDDS_EXPORTED_API ReturnCode_t read_next_instance( LoanableCollection& data_values, SampleInfoSeq& sample_infos, int32_t max_samples = LENGTH_UNLIMITED, @@ -479,7 +477,7 @@ class DataReader : public DomainEntity * * @return Any of the standard return codes. */ - RTPS_DllAPI ReturnCode_t read_next_instance_w_condition( + FASTDDS_EXPORTED_API ReturnCode_t read_next_instance_w_condition( LoanableCollection& data_values, SampleInfoSeq& sample_infos, int32_t max_samples, @@ -505,7 +503,7 @@ class DataReader : public DomainEntity * * @return Any of the standard return codes. */ - RTPS_DllAPI ReturnCode_t read_next_sample( + FASTDDS_EXPORTED_API ReturnCode_t read_next_sample( void* data, SampleInfo* info); @@ -540,7 +538,7 @@ class DataReader : public DomainEntity * * @return Any of the standard return codes. */ - RTPS_DllAPI ReturnCode_t take( + FASTDDS_EXPORTED_API ReturnCode_t take( LoanableCollection& data_values, SampleInfoSeq& sample_infos, int32_t max_samples = LENGTH_UNLIMITED, @@ -569,7 +567,7 @@ class DataReader : public DomainEntity * * @return Any of the standard return codes. */ - RTPS_DllAPI ReturnCode_t take_w_condition( + FASTDDS_EXPORTED_API ReturnCode_t take_w_condition( LoanableCollection& data_values, SampleInfoSeq& sample_infos, int32_t max_samples, @@ -603,7 +601,7 @@ class DataReader : public DomainEntity * * @return Any of the standard return codes. */ - RTPS_DllAPI ReturnCode_t take_instance( + FASTDDS_EXPORTED_API ReturnCode_t take_instance( LoanableCollection& data_values, SampleInfoSeq& sample_infos, int32_t max_samples = LENGTH_UNLIMITED, @@ -642,7 +640,7 @@ class DataReader : public DomainEntity * * @return Any of the standard return codes. */ - RTPS_DllAPI ReturnCode_t take_next_instance( + FASTDDS_EXPORTED_API ReturnCode_t take_next_instance( LoanableCollection& data_values, SampleInfoSeq& sample_infos, int32_t max_samples = LENGTH_UNLIMITED, @@ -679,7 +677,7 @@ class DataReader : public DomainEntity * * @return Any of the standard return codes. */ - RTPS_DllAPI ReturnCode_t take_next_instance_w_condition( + FASTDDS_EXPORTED_API ReturnCode_t take_next_instance_w_condition( LoanableCollection& data_values, SampleInfoSeq& sample_infos, int32_t max_samples, @@ -707,7 +705,7 @@ class DataReader : public DomainEntity * * @return Any of the standard return codes. */ - RTPS_DllAPI ReturnCode_t take_next_sample( + FASTDDS_EXPORTED_API ReturnCode_t take_next_sample( void* data, SampleInfo* info); @@ -733,9 +731,9 @@ class DataReader : public DomainEntity * * The use of the @ref return_loan operation is only necessary if the read or take calls "loaned" buffers to the * application. This only occurs if the @c data_values and @c sample_infos collections had max_len == 0 - * at the time read or take was called. The application may also examine the @c owns property of the collection to - * determine if there is an outstanding loan. However, calling @ref return_loan on a collection that does not have - * a loan is safe and has no side effects. + * at the time read or take was called. The application may also examine the @c has_ownership property of the + * collection to determine if there is an outstanding loan. However, calling @ref return_loan on a collection that + * does not have a loan is safe, has no side effects, and returns RETCODE_OK. * * If the collections had a loan, upon return from return_loan the collections will have max_len == 0 . * @@ -746,7 +744,7 @@ class DataReader : public DomainEntity * * @return Any of the standard return codes. */ - RTPS_DllAPI ReturnCode_t return_loan( + FASTDDS_EXPORTED_API ReturnCode_t return_loan( LoanableCollection& data_values, SampleInfoSeq& sample_infos); @@ -764,9 +762,10 @@ class DataReader : public DomainEntity * @param[in] handle * * @return Any of the standard return codes. + * * @warning Not supported yet. Currently returns RETCODE_UNSUPPORTED */ - RTPS_DllAPI ReturnCode_t get_key_value( + FASTDDS_EXPORTED_API ReturnCode_t get_key_value( void* key_holder, const InstanceHandle_t& handle); @@ -781,7 +780,7 @@ class DataReader : public DomainEntity * @return HANDLE_NIL if @c instance is nullptr. * @return HANDLE_NIL if there is no instance on the DataReader's history with the same key as @c instance. */ - RTPS_DllAPI InstanceHandle_t lookup_instance( + FASTDDS_EXPORTED_API InstanceHandle_t lookup_instance( const void* instance) const; /** @@ -793,7 +792,7 @@ class DataReader : public DomainEntity * * @return RETCODE_OK if sample info was returned. RETCODE_NO_DATA if there is no sample to take. */ - RTPS_DllAPI ReturnCode_t get_first_untaken_info( + FASTDDS_EXPORTED_API ReturnCode_t get_first_untaken_info( SampleInfo* info); /** @@ -803,7 +802,7 @@ class DataReader : public DomainEntity * * @return the number of samples on the reader history that have never been read. */ - RTPS_DllAPI uint64_t get_unread_count() const; + FASTDDS_EXPORTED_API uint64_t get_unread_count() const; /** * Get the number of samples pending to be read. @@ -812,7 +811,7 @@ class DataReader : public DomainEntity * * @return the number of samples on the reader history that have never been read. */ - RTPS_DllAPI uint64_t get_unread_count( + FASTDDS_EXPORTED_API uint64_t get_unread_count( bool mark_as_read) const; /** @@ -820,42 +819,42 @@ class DataReader : public DomainEntity * * @return Associated GUID */ - RTPS_DllAPI const fastrtps::rtps::GUID_t& guid(); + FASTDDS_EXPORTED_API const fastrtps::rtps::GUID_t& guid(); /** * Get associated GUID. * * @return Associated GUID */ - RTPS_DllAPI const fastrtps::rtps::GUID_t& guid() const; + FASTDDS_EXPORTED_API const fastrtps::rtps::GUID_t& guid() const; /** * @brief Getter for the associated InstanceHandle. * * @return Copy of the InstanceHandle */ - RTPS_DllAPI InstanceHandle_t get_instance_handle() const; + FASTDDS_EXPORTED_API InstanceHandle_t get_instance_handle() const; /** * Getter for the data type. * * @return TypeSupport associated to the DataReader. */ - RTPS_DllAPI TypeSupport type(); + FASTDDS_EXPORTED_API TypeSupport type(); /** * Get TopicDescription. * * @return TopicDescription pointer. */ - RTPS_DllAPI const TopicDescription* get_topicdescription() const; + FASTDDS_EXPORTED_API const TopicDescription* get_topicdescription() const; /** * @brief Get the requested deadline missed status. * * @return The deadline missed status. */ - RTPS_DllAPI ReturnCode_t get_requested_deadline_missed_status( + FASTDDS_EXPORTED_API ReturnCode_t get_requested_deadline_missed_status( RequestedDeadlineMissedStatus& status); /** @@ -865,7 +864,7 @@ class DataReader : public DomainEntity * * @return RETCODE_OK */ - RTPS_DllAPI ReturnCode_t get_requested_incompatible_qos_status( + FASTDDS_EXPORTED_API ReturnCode_t get_requested_incompatible_qos_status( RequestedIncompatibleQosStatus& status); /** @@ -876,7 +875,7 @@ class DataReader : public DomainEntity * @return RETCODE_IMMUTABLE_POLICY if any of the Qos cannot be changed, RETCODE_INCONSISTENT_POLICY if the Qos is * not self consistent and RETCODE_OK if the qos is changed correctly. */ - RTPS_DllAPI ReturnCode_t set_qos( + FASTDDS_EXPORTED_API ReturnCode_t set_qos( const DataReaderQos& qos); /** @@ -884,7 +883,7 @@ class DataReader : public DomainEntity * * @return Pointer to the DataReaderQos. */ - RTPS_DllAPI const DataReaderQos& get_qos() const; + FASTDDS_EXPORTED_API const DataReaderQos& get_qos() const; /** * @brief Getter for the DataReaderQos. @@ -893,7 +892,7 @@ class DataReader : public DomainEntity * * @return RETCODE_OK */ - RTPS_DllAPI ReturnCode_t get_qos( + FASTDDS_EXPORTED_API ReturnCode_t get_qos( DataReaderQos& qos) const; /** @@ -903,7 +902,7 @@ class DataReader : public DomainEntity * * @return RETCODE_OK */ - RTPS_DllAPI ReturnCode_t set_listener( + FASTDDS_EXPORTED_API ReturnCode_t set_listener( DataReaderListener* listener); /** @@ -914,7 +913,7 @@ class DataReader : public DomainEntity * * @return RETCODE_OK */ - RTPS_DllAPI ReturnCode_t set_listener( + FASTDDS_EXPORTED_API ReturnCode_t set_listener( DataReaderListener* listener, const StatusMask& mask); /** @@ -922,10 +921,10 @@ class DataReader : public DomainEntity * * @return Pointer to the DataReaderListener */ - RTPS_DllAPI const DataReaderListener* get_listener() const; + FASTDDS_EXPORTED_API const DataReaderListener* get_listener() const; /* TODO - RTPS_DllAPI bool get_key_value( + FASTDDS_EXPORTED_API bool get_key_value( void* data, const InstanceHandle_t& handle); */ @@ -937,7 +936,7 @@ class DataReader : public DomainEntity * * @return RETCODE_OK */ - RTPS_DllAPI ReturnCode_t get_liveliness_changed_status( + FASTDDS_EXPORTED_API ReturnCode_t get_liveliness_changed_status( LivelinessChangedStatus& status) const; @@ -948,7 +947,7 @@ class DataReader : public DomainEntity * * @return RETCODE_OK */ - RTPS_DllAPI ReturnCode_t get_sample_lost_status( + FASTDDS_EXPORTED_API ReturnCode_t get_sample_lost_status( SampleLostStatus& status) const; /** @@ -958,7 +957,7 @@ class DataReader : public DomainEntity * * @return RETCODE_OK */ - RTPS_DllAPI ReturnCode_t get_sample_rejected_status( + FASTDDS_EXPORTED_API ReturnCode_t get_sample_rejected_status( SampleRejectedStatus& status) const; /** @@ -967,7 +966,7 @@ class DataReader : public DomainEntity * @param[out] status subscription matched status struct * @return RETCODE_OK */ - RTPS_DllAPI ReturnCode_t get_subscription_matched_status( + FASTDDS_EXPORTED_API ReturnCode_t get_subscription_matched_status( SubscriptionMatchedStatus& status) const; /** @@ -976,9 +975,10 @@ class DataReader : public DomainEntity * @param[out] publication_data publication data struct * @param publication_handle InstanceHandle_t of the publication * @return RETCODE_OK + * * @warning Not supported yet. Currently returns RETCODE_UNSUPPORTED */ - RTPS_DllAPI ReturnCode_t get_matched_publication_data( + FASTDDS_EXPORTED_API ReturnCode_t get_matched_publication_data( builtin::PublicationBuiltinTopicData& publication_data, const fastrtps::rtps::InstanceHandle_t& publication_handle) const; @@ -987,9 +987,10 @@ class DataReader : public DomainEntity * * @param[out] publication_handles Vector where the InstanceHandle_t are returned * @return RETCODE_OK + * * @warning Not supported yet. Currently returns RETCODE_UNSUPPORTED */ - RTPS_DllAPI ReturnCode_t get_matched_publications( + FASTDDS_EXPORTED_API ReturnCode_t get_matched_publications( std::vector& publication_handles) const; /** @@ -1002,7 +1003,7 @@ class DataReader : public DomainEntity * * @return pointer to the created ReadCondition, nullptr in case of error. */ - RTPS_DllAPI ReadCondition* create_readcondition( + FASTDDS_EXPORTED_API ReadCondition* create_readcondition( SampleStateMask sample_states, ViewStateMask view_states, InstanceStateMask instance_states); @@ -1019,7 +1020,7 @@ class DataReader : public DomainEntity * * @return pointer to the created QueryCondition, nullptr in case of error. */ - RTPS_DllAPI QueryCondition* create_querycondition( + FASTDDS_EXPORTED_API QueryCondition* create_querycondition( SampleStateMask sample_states, ViewStateMask view_states, InstanceStateMask instance_states, @@ -1032,14 +1033,14 @@ class DataReader : public DomainEntity * @param a_condition pointer to a ReadCondition belonging to the DataReader * @return RETCODE_OK */ - RTPS_DllAPI ReturnCode_t delete_readcondition( + FASTDDS_EXPORTED_API ReturnCode_t delete_readcondition( ReadCondition* a_condition); /** * @brief Getter for the Subscriber * @return Subscriber pointer */ - RTPS_DllAPI const Subscriber* get_subscriber() const; + FASTDDS_EXPORTED_API const Subscriber* get_subscriber() const; /** * This operation deletes all the entities that were created by means of the “create” operations on the DataReader. @@ -1050,7 +1051,7 @@ class DataReader : public DomainEntity * * @return Any of the standard return codes. */ - RTPS_DllAPI ReturnCode_t delete_contained_entities(); + FASTDDS_EXPORTED_API ReturnCode_t delete_contained_entities(); /** * Checks whether a loaned sample is still valid or is corrupted. @@ -1062,7 +1063,7 @@ class DataReader : public DomainEntity * * @return true if the sample is valid */ - RTPS_DllAPI bool is_sample_valid( + FASTDDS_EXPORTED_API bool is_sample_valid( const void* data, const SampleInfo* info) const; @@ -1074,7 +1075,7 @@ class DataReader : public DomainEntity * @return NOT_ENABLED if the reader has not been enabled. * @return OK if a list of locators is returned. */ - RTPS_DllAPI ReturnCode_t get_listening_locators( + FASTDDS_EXPORTED_API ReturnCode_t get_listening_locators( rtps::LocatorList& locators) const; protected: diff --git a/include/fastdds/dds/subscriber/DataReaderListener.hpp b/include/fastdds/dds/subscriber/DataReaderListener.hpp index 0c6dbcbe903..aad9d3c3574 100644 --- a/include/fastdds/dds/subscriber/DataReaderListener.hpp +++ b/include/fastdds/dds/subscriber/DataReaderListener.hpp @@ -16,16 +16,16 @@ * @file DataReaderListener.hpp */ -#ifndef _FASTRTPS_DATAREADERLISTENER_HPP_ -#define _FASTRTPS_DATAREADERLISTENER_HPP_ +#ifndef _FASTDDS_DATAREADERLISTENER_HPP_ +#define _FASTDDS_DATAREADERLISTENER_HPP_ -#include -#include -#include -#include -#include #include +#include +#include +#include +#include #include +#include namespace eprosima { namespace fastdds { @@ -44,14 +44,14 @@ class DataReaderListener /** * @brief Constructor */ - RTPS_DllAPI DataReaderListener() + FASTDDS_EXPORTED_API DataReaderListener() { } /** * @brief Destructor */ - RTPS_DllAPI virtual ~DataReaderListener() + FASTDDS_EXPORTED_API virtual ~DataReaderListener() { } @@ -60,7 +60,7 @@ class DataReaderListener * * @param reader DataReader */ - RTPS_DllAPI virtual void on_data_available( + FASTDDS_EXPORTED_API virtual void on_data_available( DataReader* reader) { (void)reader; @@ -72,7 +72,7 @@ class DataReaderListener * @param reader DataReader * @param info The subscription matched status */ - RTPS_DllAPI virtual void on_subscription_matched( + FASTDDS_EXPORTED_API virtual void on_subscription_matched( DataReader* reader, const fastdds::dds::SubscriptionMatchedStatus& info) { @@ -86,9 +86,9 @@ class DataReaderListener * @param reader DataReader * @param status The requested deadline missed status */ - RTPS_DllAPI virtual void on_requested_deadline_missed( + FASTDDS_EXPORTED_API virtual void on_requested_deadline_missed( DataReader* reader, - const fastrtps::RequestedDeadlineMissedStatus& status) + const RequestedDeadlineMissedStatus& status) { (void)reader; (void)status; @@ -100,9 +100,9 @@ class DataReaderListener * @param reader The DataReader * @param status The liveliness changed status */ - RTPS_DllAPI virtual void on_liveliness_changed( + FASTDDS_EXPORTED_API virtual void on_liveliness_changed( DataReader* reader, - const fastrtps::LivelinessChangedStatus& status) + const LivelinessChangedStatus& status) { (void)reader; (void)status; @@ -114,9 +114,9 @@ class DataReaderListener * @param reader The DataReader * @param status The rejected status */ - RTPS_DllAPI virtual void on_sample_rejected( + FASTDDS_EXPORTED_API virtual void on_sample_rejected( DataReader* reader, - const fastrtps::SampleRejectedStatus& status) + const SampleRejectedStatus& status) { (void)reader; (void)status; @@ -128,7 +128,7 @@ class DataReaderListener * @param reader The DataReader * @param status The requested incompatible QoS status */ - RTPS_DllAPI virtual void on_requested_incompatible_qos( + FASTDDS_EXPORTED_API virtual void on_requested_incompatible_qos( DataReader* reader, const RequestedIncompatibleQosStatus& status) { @@ -142,7 +142,7 @@ class DataReaderListener * @param reader The DataReader * @param status The sample lost status */ - RTPS_DllAPI virtual void on_sample_lost( + FASTDDS_EXPORTED_API virtual void on_sample_lost( DataReader* reader, const SampleLostStatus& status) { @@ -156,4 +156,4 @@ class DataReaderListener } /* namespace fastdds */ } /* namespace eprosima */ -#endif /* _FASTRTPS_DATAREADERLISTENER_HPP_ */ +#endif /* _FASTDDS_DATAREADERLISTENER_HPP_ */ diff --git a/include/fastdds/dds/subscriber/ReadCondition.hpp b/include/fastdds/dds/subscriber/ReadCondition.hpp index b4d530efdc9..7e79732b308 100644 --- a/include/fastdds/dds/subscriber/ReadCondition.hpp +++ b/include/fastdds/dds/subscriber/ReadCondition.hpp @@ -25,7 +25,7 @@ #include #include #include -#include +#include namespace eprosima { namespace fastdds { @@ -74,7 +74,7 @@ class ReadCondition : public Condition * @brief Retrieves the trigger_value of the Condition * @return true if trigger_value is set to 'true', 'false' otherwise */ - RTPS_DllAPI bool get_trigger_value() const noexcept override; + FASTDDS_EXPORTED_API bool get_trigger_value() const noexcept override; /** * @brief Retrieves the DataReader associated with the ReadCondition. @@ -83,28 +83,28 @@ class ReadCondition : public Condition * * @return pointer to the DataReader associated with this ReadCondition. */ - RTPS_DllAPI DataReader* get_datareader() const noexcept; + FASTDDS_EXPORTED_API DataReader* get_datareader() const noexcept; /** * @brief Retrieves the set of sample_states taken into account to determine the trigger_value of this condition. * * @return the sample_states specified when the ReadCondition was created. */ - RTPS_DllAPI SampleStateMask get_sample_state_mask() const noexcept; + FASTDDS_EXPORTED_API SampleStateMask get_sample_state_mask() const noexcept; /** * @brief Retrieves the set of view_states taken into account to determine the trigger_value of this condition. * * @return the view_states specified when the ReadCondition was created. */ - RTPS_DllAPI ViewStateMask get_view_state_mask() const noexcept; + FASTDDS_EXPORTED_API ViewStateMask get_view_state_mask() const noexcept; /** * @brief Retrieves the set of instance_states taken into account to determine the trigger_value of this condition. * * @return the instance_states specified when the ReadCondition was created. */ - RTPS_DllAPI InstanceStateMask get_instance_state_mask() const noexcept; + FASTDDS_EXPORTED_API InstanceStateMask get_instance_state_mask() const noexcept; detail::ReadConditionImpl* get_impl() const noexcept { diff --git a/include/fastdds/dds/subscriber/SampleInfo.hpp b/include/fastdds/dds/subscriber/SampleInfo.hpp index 4c1f2354495..ccc173fc78c 100644 --- a/include/fastdds/dds/subscriber/SampleInfo.hpp +++ b/include/fastdds/dds/subscriber/SampleInfo.hpp @@ -34,34 +34,6 @@ namespace eprosima { namespace fastdds { namespace dds { -FASTDDS_DEPRECATED_UNTIL(3, "eprosima::fastdds::dds::READ", - "Use eprosima::fastdds::dds::READ_SAMPLE_STATE instead.") -constexpr SampleStateKind READ = READ_SAMPLE_STATE; - -FASTDDS_DEPRECATED_UNTIL(3, "eprosima::fastdds::dds::NOT_READ", - "Use eprosima::fastdds::dds::NOT_READ_SAMPLE_STATE instead.") -constexpr SampleStateKind NOT_READ = NOT_READ_SAMPLE_STATE; - -FASTDDS_DEPRECATED_UNTIL(3, "eprosima::fastdds::dds::NEW", - "Use eprosima::fastdds::dds::NEW_VIEW_STATE instead.") -constexpr ViewStateKind NEW = NEW_VIEW_STATE; - -FASTDDS_DEPRECATED_UNTIL(3, "eprosima::fastdds::dds::NOT_NEW", - "Use eprosima::fastdds::dds::NOT_NEW_VIEW_STATE instead.") -constexpr ViewStateKind NOT_NEW = NOT_NEW_VIEW_STATE; - -FASTDDS_DEPRECATED_UNTIL(3, "eprosima::fastdds::dds::ALIVE", - "Use eprosima::fastdds::dds::ALIVE_INSTANCE_STATE instead.") -constexpr InstanceStateKind ALIVE = ALIVE_INSTANCE_STATE; - -FASTDDS_DEPRECATED_UNTIL(3, "eprosima::fastdds::dds::NOT_ALIVE_DISPOSED", - "Use eprosima::fastdds::dds::NOT_ALIVE_DISPOSED_INSTANCE_STATE instead.") -constexpr InstanceStateKind NOT_ALIVE_DISPOSED = NOT_ALIVE_DISPOSED_INSTANCE_STATE; - -FASTDDS_DEPRECATED_UNTIL(3, "eprosima::fastdds::dds::NOT_ALIVE_NO_WRITERS", - "Use eprosima::fastdds::dds::NOT_ALIVE_NO_WRITERS_INSTANCE_STATE instead.") -constexpr InstanceStateKind NOT_ALIVE_NO_WRITERS = NOT_ALIVE_NO_WRITERS_INSTANCE_STATE; - /*! * @brief SampleInfo is the information that accompanies each sample that is ‘read’ or ‘taken.’ */ diff --git a/include/fastdds/dds/subscriber/Subscriber.hpp b/include/fastdds/dds/subscriber/Subscriber.hpp index 265a7bb16d1..15d900c8d95 100644 --- a/include/fastdds/dds/subscriber/Subscriber.hpp +++ b/include/fastdds/dds/subscriber/Subscriber.hpp @@ -20,6 +20,7 @@ #define _FASTDDS_SUBSCRIBER_HPP_ #include +#include #include #include #include @@ -28,9 +29,6 @@ #include #include #include -#include - -using eprosima::fastrtps::types::ReturnCode_t; namespace dds { namespace sub { @@ -100,14 +98,14 @@ class Subscriber : public DomainEntity * @return RETCODE_OK is successfully enabled. RETCODE_PRECONDITION_NOT_MET if the participant creating this * Subscriber is not enabled. */ - RTPS_DllAPI ReturnCode_t enable() override; + FASTDDS_EXPORTED_API ReturnCode_t enable() override; /** * Allows accessing the Subscriber Qos. * * @return SubscriberQos reference */ - RTPS_DllAPI const SubscriberQos& get_qos() const; + FASTDDS_EXPORTED_API const SubscriberQos& get_qos() const; /** * Retrieves the Subscriber Qos. @@ -115,7 +113,7 @@ class Subscriber : public DomainEntity * @param qos SubscriberQos where the qos is returned * @return RETCODE_OK */ - RTPS_DllAPI ReturnCode_t get_qos( + FASTDDS_EXPORTED_API ReturnCode_t get_qos( SubscriberQos& qos) const; /** @@ -126,7 +124,7 @@ class Subscriber : public DomainEntity * @return RETCODE_IMMUTABLE_POLICY if any of the Qos cannot be changed, RETCODE_INCONSISTENT_POLICY if the Qos is not * self consistent and RETCODE_OK if the qos is changed correctly. */ - RTPS_DllAPI ReturnCode_t set_qos( + FASTDDS_EXPORTED_API ReturnCode_t set_qos( const SubscriberQos& qos); /** @@ -134,7 +132,7 @@ class Subscriber : public DomainEntity * * @return Pointer to the SubscriberListener */ - RTPS_DllAPI const SubscriberListener* get_listener() const; + FASTDDS_EXPORTED_API const SubscriberListener* get_listener() const; /** * Modifies the SubscriberListener, sets the mask to StatusMask::all() @@ -142,7 +140,7 @@ class Subscriber : public DomainEntity * @param listener new value for SubscriberListener * @return RETCODE_OK */ - RTPS_DllAPI ReturnCode_t set_listener( + FASTDDS_EXPORTED_API ReturnCode_t set_listener( SubscriberListener* listener); /** @@ -152,7 +150,7 @@ class Subscriber : public DomainEntity * @param mask StatusMask that holds statuses the listener responds to. * @return RETCODE_OK */ - RTPS_DllAPI ReturnCode_t set_listener( + FASTDDS_EXPORTED_API ReturnCode_t set_listener( SubscriberListener* listener, const StatusMask& mask); /** @@ -165,7 +163,7 @@ class Subscriber : public DomainEntity * @param payload_pool IPayloadPool shared pointer that defines reader payload (default: nullptr). * @return Pointer to the created DataReader. nullptr if failed. */ - RTPS_DllAPI DataReader* create_datareader( + FASTDDS_EXPORTED_API DataReader* create_datareader( TopicDescription* topic, const DataReaderQos& reader_qos, DataReaderListener* listener = nullptr, @@ -182,7 +180,7 @@ class Subscriber : public DomainEntity * @param payload_pool IPayloadPool shared pointer that defines reader payload (default: nullptr). * @return Pointer to the created DataReader. nullptr if failed. */ - RTPS_DllAPI DataReader* create_datareader_with_profile( + FASTDDS_EXPORTED_API DataReader* create_datareader_with_profile( TopicDescription* topic, const std::string& profile_name, DataReaderListener* listener = nullptr, @@ -200,7 +198,7 @@ class Subscriber : public DomainEntity * @return RETCODE_PRECONDITION_NOT_MET if the datareader does not belong to this subscriber, RETCODE_OK if it is correctly * deleted and RETCODE_ERROR otherwise. */ - RTPS_DllAPI ReturnCode_t delete_datareader( + FASTDDS_EXPORTED_API ReturnCode_t delete_datareader( const DataReader* reader); /** @@ -213,7 +211,7 @@ class Subscriber : public DomainEntity * @param topic_name Name of the topic associated to the DataReader * @return Pointer to a previously created DataReader created on a Topic with that topic_name */ - RTPS_DllAPI DataReader* lookup_datareader( + FASTDDS_EXPORTED_API DataReader* lookup_datareader( const std::string& topic_name) const; /** @@ -222,7 +220,7 @@ class Subscriber : public DomainEntity * @param readers Vector of DataReader where the list of existing readers is returned * @return RETCODE_OK */ - RTPS_DllAPI ReturnCode_t get_datareaders( + FASTDDS_EXPORTED_API ReturnCode_t get_datareaders( std::vector& readers) const; /** @@ -234,9 +232,10 @@ class Subscriber : public DomainEntity * @param view_states Vector of ViewStateKind * @param instance_states Vector of InstanceStateKind * @return RETCODE_OK + * * @warning Not supported yet. Currently returns RETCODE_UNSUPPORTED */ - RTPS_DllAPI ReturnCode_t get_datareaders( + FASTDDS_EXPORTED_API ReturnCode_t get_datareaders( std::vector& readers, const std::vector& sample_states, const std::vector& view_states, @@ -247,25 +246,27 @@ class Subscriber : public DomainEntity * * @return true if the subscriber has one or several DataReaders, false in other case */ - RTPS_DllAPI bool has_datareaders() const; + FASTDDS_EXPORTED_API bool has_datareaders() const; /** * @brief Indicates that the application is about to access the data samples in any of the DataReader objects * attached to the Subscriber. * * @return RETCODE_OK + * * @warning Not supported yet. Currently returns RETCODE_UNSUPPORTED */ - RTPS_DllAPI ReturnCode_t begin_access(); + FASTDDS_EXPORTED_API ReturnCode_t begin_access(); /** * @brief Indicates that the application has finished accessing the data samples in DataReader objects managed by * the Subscriber. * * @return RETCODE_OK + * * @warning Not supported yet. Currently returns RETCODE_UNSUPPORTED */ - RTPS_DllAPI ReturnCode_t end_access(); + FASTDDS_EXPORTED_API ReturnCode_t end_access(); /** @@ -277,7 +278,7 @@ class Subscriber : public DomainEntity * * @return RETCODE_OK */ - RTPS_DllAPI ReturnCode_t notify_datareaders() const; + FASTDDS_EXPORTED_API ReturnCode_t notify_datareaders() const; /** * @brief Deletes all contained DataReaders. If the DataReaders have any QueryCondition or ReadCondition, they are @@ -285,7 +286,7 @@ class Subscriber : public DomainEntity * * @return RETCODE_OK if successful, an error code otherwise */ - RTPS_DllAPI ReturnCode_t delete_contained_entities(); + FASTDDS_EXPORTED_API ReturnCode_t delete_contained_entities(); /** * This operation sets a default value of the DataReader QoS policies which will be used for newly created @@ -301,7 +302,7 @@ class Subscriber : public DomainEntity * @param qos new value for DataReaderQos to set as default * @return RETCODE_INCONSISTENT_POLICY if the Qos is not self consistent and RETCODE_OK if the qos is changed correctly. */ - RTPS_DllAPI ReturnCode_t set_default_datareader_qos( + FASTDDS_EXPORTED_API ReturnCode_t set_default_datareader_qos( const DataReaderQos& qos); /** @@ -314,7 +315,7 @@ class Subscriber : public DomainEntity * * @return Current default DataReaderQos. */ - RTPS_DllAPI const DataReaderQos& get_default_datareader_qos() const; + FASTDDS_EXPORTED_API const DataReaderQos& get_default_datareader_qos() const; /** @@ -327,7 +328,7 @@ class Subscriber : public DomainEntity * * @return Current default DataReaderQos. */ - RTPS_DllAPI DataReaderQos& get_default_datareader_qos(); + FASTDDS_EXPORTED_API DataReaderQos& get_default_datareader_qos(); /** * This operation retrieves the default value of the DataReader QoS, that is, the QoS policies which will be @@ -340,7 +341,7 @@ class Subscriber : public DomainEntity * @param qos DataReaderQos where the default_qos is returned * @return RETCODE_OK */ - RTPS_DllAPI ReturnCode_t get_default_datareader_qos( + FASTDDS_EXPORTED_API ReturnCode_t get_default_datareader_qos( DataReaderQos& qos) const; /** @@ -350,7 +351,7 @@ class Subscriber : public DomainEntity * @param qos DataReaderQos object where the qos is returned. * @return RETCODE_OK if the profile exists. RETCODE_BAD_PARAMETER otherwise. */ - RTPS_DllAPI ReturnCode_t get_datareader_qos_from_profile( + FASTDDS_EXPORTED_API ReturnCode_t get_datareader_qos_from_profile( const std::string& profile_name, DataReaderQos& qos) const; @@ -360,8 +361,10 @@ class Subscriber : public DomainEntity * @param[in, out] reader_qos * @param[in] topic_qos * @return RETCODE_OK if successful, an error code otherwise + * + * @warning Not supported yet. Currently returns RETCODE_UNSUPPORTED */ - RTPS_DllAPI static ReturnCode_t copy_from_topic_qos( + FASTDDS_EXPORTED_API static ReturnCode_t copy_from_topic_qos( DataReaderQos& reader_qos, const TopicQos& topic_qos); @@ -370,14 +373,14 @@ class Subscriber : public DomainEntity * * @return DomainParticipant Pointer */ - RTPS_DllAPI const DomainParticipant* get_participant() const; + FASTDDS_EXPORTED_API const DomainParticipant* get_participant() const; /** * Returns the Subscriber's handle. * * @return InstanceHandle of this Subscriber. */ - RTPS_DllAPI const InstanceHandle_t& get_instance_handle() const; + FASTDDS_EXPORTED_API const InstanceHandle_t& get_instance_handle() const; protected: diff --git a/include/fastdds/dds/subscriber/SubscriberListener.hpp b/include/fastdds/dds/subscriber/SubscriberListener.hpp index 080921f06a5..c70af5f5f8e 100644 --- a/include/fastdds/dds/subscriber/SubscriberListener.hpp +++ b/include/fastdds/dds/subscriber/SubscriberListener.hpp @@ -19,11 +19,11 @@ #ifndef _FASTDDS_SUBLISTENER_HPP_ #define _FASTDDS_SUBLISTENER_HPP_ -#include -#include -#include +#include +#include #include #include +#include namespace eprosima { namespace fastdds { @@ -44,14 +44,14 @@ class SubscriberListener : public DataReaderListener /** * @brief Constructor */ - RTPS_DllAPI SubscriberListener() + FASTDDS_EXPORTED_API SubscriberListener() { } /** * @brief Destructor */ - RTPS_DllAPI virtual ~SubscriberListener() + FASTDDS_EXPORTED_API virtual ~SubscriberListener() { } @@ -61,7 +61,7 @@ class SubscriberListener : public DataReaderListener * * @param sub Subscriber */ - RTPS_DllAPI virtual void on_data_on_readers( + FASTDDS_EXPORTED_API virtual void on_data_on_readers( Subscriber* sub) { (void)sub; diff --git a/include/fastdds/dds/subscriber/qos/DataReaderQos.hpp b/include/fastdds/dds/subscriber/qos/DataReaderQos.hpp index b5a8e005ae9..44cee767427 100644 --- a/include/fastdds/dds/subscriber/qos/DataReaderQos.hpp +++ b/include/fastdds/dds/subscriber/qos/DataReaderQos.hpp @@ -25,8 +25,8 @@ #include #include #include -#include -#include +#include +#include namespace eprosima { namespace fastdds { @@ -42,14 +42,14 @@ class RTPSReliableReaderQos /** * @brief Constructor */ - RTPS_DllAPI RTPSReliableReaderQos() + FASTDDS_EXPORTED_API RTPSReliableReaderQos() { } /** * @brief Destructor */ - virtual RTPS_DllAPI ~RTPSReliableReaderQos() = default; + virtual FASTDDS_EXPORTED_API ~RTPSReliableReaderQos() = default; bool operator ==( const RTPSReliableReaderQos& b) const @@ -83,12 +83,12 @@ class ReaderResourceLimitsQos /** * @brief Constructor */ - RTPS_DllAPI ReaderResourceLimitsQos() = default; + FASTDDS_EXPORTED_API ReaderResourceLimitsQos() = default; /** * @brief Destructor */ - virtual RTPS_DllAPI ~ReaderResourceLimitsQos() = default; + virtual FASTDDS_EXPORTED_API ~ReaderResourceLimitsQos() = default; bool operator ==( const ReaderResourceLimitsQos& b) const @@ -134,7 +134,7 @@ class TypeConsistencyQos : public QosPolicy /** * @brief Constructor */ - RTPS_DllAPI TypeConsistencyQos() + FASTDDS_EXPORTED_API TypeConsistencyQos() : QosPolicy(false) { } @@ -142,7 +142,7 @@ class TypeConsistencyQos : public QosPolicy /** * @brief Destructor */ - virtual RTPS_DllAPI ~TypeConsistencyQos() = default; + virtual FASTDDS_EXPORTED_API ~TypeConsistencyQos() = default; bool operator ==( const TypeConsistencyQos& b) const @@ -179,12 +179,12 @@ class DataReaderQos /** * @brief Constructor */ - RTPS_DllAPI DataReaderQos() + FASTDDS_EXPORTED_API DataReaderQos() : expects_inline_qos_(false) { } - RTPS_DllAPI bool operator ==( + FASTDDS_EXPORTED_API bool operator ==( const DataReaderQos& b) const { return (durability_ == b.durability()) && @@ -210,7 +210,7 @@ class DataReaderQos (data_sharing_ == b.data_sharing()); } - RTPS_DllAPI ReaderQos get_readerqos( + FASTDDS_EXPORTED_API ReaderQos get_readerqos( const SubscriberQos& sqos) const; /** @@ -218,7 +218,7 @@ class DataReaderQos * * @return DurabilityQosPolicy reference */ - RTPS_DllAPI DurabilityQosPolicy& durability() + FASTDDS_EXPORTED_API DurabilityQosPolicy& durability() { return durability_; } @@ -228,7 +228,7 @@ class DataReaderQos * * @return DurabilityQosPolicy const reference */ - RTPS_DllAPI const DurabilityQosPolicy& durability() const + FASTDDS_EXPORTED_API const DurabilityQosPolicy& durability() const { return durability_; } @@ -238,7 +238,7 @@ class DataReaderQos * * @param new_value new value for the DurabilityQosPolicy */ - RTPS_DllAPI void durability( + FASTDDS_EXPORTED_API void durability( const DurabilityQosPolicy& new_value) { durability_ = new_value; @@ -249,7 +249,7 @@ class DataReaderQos * * @return DeadlineQosPolicy reference */ - RTPS_DllAPI DeadlineQosPolicy& deadline() + FASTDDS_EXPORTED_API DeadlineQosPolicy& deadline() { return deadline_; } @@ -259,7 +259,7 @@ class DataReaderQos * * @return DeadlineQosPolicy const reference */ - RTPS_DllAPI const DeadlineQosPolicy& deadline() const + FASTDDS_EXPORTED_API const DeadlineQosPolicy& deadline() const { return deadline_; } @@ -269,7 +269,7 @@ class DataReaderQos * * @param new_value new value for the DeadlineQosPolicy */ - RTPS_DllAPI void deadline( + FASTDDS_EXPORTED_API void deadline( const DeadlineQosPolicy& new_value) { deadline_ = new_value; @@ -280,7 +280,7 @@ class DataReaderQos * * @return LatencyBudgetQosPolicy reference */ - RTPS_DllAPI LatencyBudgetQosPolicy& latency_budget() + FASTDDS_EXPORTED_API LatencyBudgetQosPolicy& latency_budget() { return latency_budget_; } @@ -290,7 +290,7 @@ class DataReaderQos * * @return LatencyBudgetQosPolicy const reference */ - RTPS_DllAPI const LatencyBudgetQosPolicy& latency_budget() const + FASTDDS_EXPORTED_API const LatencyBudgetQosPolicy& latency_budget() const { return latency_budget_; } @@ -300,7 +300,7 @@ class DataReaderQos * * @param new_value new value for the LatencyBudgetQosPolicy */ - RTPS_DllAPI void latency_budget( + FASTDDS_EXPORTED_API void latency_budget( const LatencyBudgetQosPolicy& new_value) { latency_budget_ = new_value; @@ -311,7 +311,7 @@ class DataReaderQos * * @return LivelinessQosPolicy reference */ - RTPS_DllAPI LivelinessQosPolicy& liveliness() + FASTDDS_EXPORTED_API LivelinessQosPolicy& liveliness() { return liveliness_; } @@ -321,7 +321,7 @@ class DataReaderQos * * @return LivelinessQosPolicy const reference */ - RTPS_DllAPI const LivelinessQosPolicy& liveliness() const + FASTDDS_EXPORTED_API const LivelinessQosPolicy& liveliness() const { return liveliness_; } @@ -331,7 +331,7 @@ class DataReaderQos * * @param new_value new value for the LivelinessQosPolicy */ - RTPS_DllAPI void liveliness( + FASTDDS_EXPORTED_API void liveliness( const LivelinessQosPolicy& new_value) { liveliness_ = new_value; @@ -342,7 +342,7 @@ class DataReaderQos * * @return ReliabilityQosPolicy reference */ - RTPS_DllAPI ReliabilityQosPolicy& reliability() + FASTDDS_EXPORTED_API ReliabilityQosPolicy& reliability() { return reliability_; } @@ -352,7 +352,7 @@ class DataReaderQos * * @return ReliabilityQosPolicy const reference */ - RTPS_DllAPI const ReliabilityQosPolicy& reliability() const + FASTDDS_EXPORTED_API const ReliabilityQosPolicy& reliability() const { return reliability_; } @@ -362,7 +362,7 @@ class DataReaderQos * * @param new_value new value for the ReliabilityQosPolicy */ - RTPS_DllAPI void reliability( + FASTDDS_EXPORTED_API void reliability( const ReliabilityQosPolicy& new_value) { reliability_ = new_value; @@ -373,7 +373,7 @@ class DataReaderQos * * @return DestinationOrderQosPolicy reference */ - RTPS_DllAPI DestinationOrderQosPolicy& destination_order() + FASTDDS_EXPORTED_API DestinationOrderQosPolicy& destination_order() { return destination_order_; } @@ -383,7 +383,7 @@ class DataReaderQos * * @return DestinationOrderQosPolicy const reference */ - RTPS_DllAPI const DestinationOrderQosPolicy& destination_order() const + FASTDDS_EXPORTED_API const DestinationOrderQosPolicy& destination_order() const { return destination_order_; } @@ -393,7 +393,7 @@ class DataReaderQos * * @param new_value new value for the DestinationOrderQosPolicy */ - RTPS_DllAPI void destination_order( + FASTDDS_EXPORTED_API void destination_order( const DestinationOrderQosPolicy& new_value) { destination_order_ = new_value; @@ -404,7 +404,7 @@ class DataReaderQos * * @return HistoryQosPolicy reference */ - RTPS_DllAPI HistoryQosPolicy& history() + FASTDDS_EXPORTED_API HistoryQosPolicy& history() { return history_; } @@ -414,7 +414,7 @@ class DataReaderQos * * @return HistoryQosPolicy const reference */ - RTPS_DllAPI const HistoryQosPolicy& history() const + FASTDDS_EXPORTED_API const HistoryQosPolicy& history() const { return history_; } @@ -424,7 +424,7 @@ class DataReaderQos * * @param new_value new value for the HistoryQosPolicy */ - RTPS_DllAPI void history( + FASTDDS_EXPORTED_API void history( const HistoryQosPolicy& new_value) { history_ = new_value; @@ -435,7 +435,7 @@ class DataReaderQos * * @return ResourceLimitsQosPolicy reference */ - RTPS_DllAPI ResourceLimitsQosPolicy& resource_limits() + FASTDDS_EXPORTED_API ResourceLimitsQosPolicy& resource_limits() { return resource_limits_; } @@ -445,7 +445,7 @@ class DataReaderQos * * @return ResourceLimitsQosPolicy const reference */ - RTPS_DllAPI const ResourceLimitsQosPolicy& resource_limits() const + FASTDDS_EXPORTED_API const ResourceLimitsQosPolicy& resource_limits() const { return resource_limits_; } @@ -455,7 +455,7 @@ class DataReaderQos * * @param new_value new value for the ResourceLimitsQosPolicy */ - RTPS_DllAPI void resource_limits( + FASTDDS_EXPORTED_API void resource_limits( const ResourceLimitsQosPolicy& new_value) { resource_limits_ = new_value; @@ -466,7 +466,7 @@ class DataReaderQos * * @return UserDataQosPolicy reference */ - RTPS_DllAPI UserDataQosPolicy& user_data() + FASTDDS_EXPORTED_API UserDataQosPolicy& user_data() { return user_data_; } @@ -476,7 +476,7 @@ class DataReaderQos * * @return UserDataQosPolicy const reference */ - RTPS_DllAPI const UserDataQosPolicy& user_data() const + FASTDDS_EXPORTED_API const UserDataQosPolicy& user_data() const { return user_data_; } @@ -486,7 +486,7 @@ class DataReaderQos * * @param new_value new value for the UserDataQosPolicy */ - RTPS_DllAPI void user_data( + FASTDDS_EXPORTED_API void user_data( const UserDataQosPolicy& new_value) { user_data_ = new_value; @@ -497,7 +497,7 @@ class DataReaderQos * * @return OwnershipQosPolicy reference */ - RTPS_DllAPI OwnershipQosPolicy& ownership() + FASTDDS_EXPORTED_API OwnershipQosPolicy& ownership() { return ownership_; } @@ -507,7 +507,7 @@ class DataReaderQos * * @return OwnershipQosPolicy const reference */ - RTPS_DllAPI const OwnershipQosPolicy& ownership() const + FASTDDS_EXPORTED_API const OwnershipQosPolicy& ownership() const { return ownership_; } @@ -517,7 +517,7 @@ class DataReaderQos * * @param new_value new value for the OwnershipQosPolicy */ - RTPS_DllAPI void ownership( + FASTDDS_EXPORTED_API void ownership( const OwnershipQosPolicy& new_value) { ownership_ = new_value; @@ -528,7 +528,7 @@ class DataReaderQos * * @return TimeBasedFilterQosPolicy reference */ - RTPS_DllAPI TimeBasedFilterQosPolicy& time_based_filter() + FASTDDS_EXPORTED_API TimeBasedFilterQosPolicy& time_based_filter() { return time_based_filter_; } @@ -538,7 +538,7 @@ class DataReaderQos * * @return TimeBasedFilterQosPolicy const reference */ - RTPS_DllAPI const TimeBasedFilterQosPolicy& time_based_filter() const + FASTDDS_EXPORTED_API const TimeBasedFilterQosPolicy& time_based_filter() const { return time_based_filter_; } @@ -548,7 +548,7 @@ class DataReaderQos * * @param new_value new value for the TimeBasedFilterQosPolicy */ - RTPS_DllAPI void time_based_filter( + FASTDDS_EXPORTED_API void time_based_filter( const TimeBasedFilterQosPolicy& new_value) { time_based_filter_ = new_value; @@ -559,7 +559,7 @@ class DataReaderQos * * @return ReaderDataLifecycleQosPolicy reference */ - RTPS_DllAPI ReaderDataLifecycleQosPolicy& reader_data_lifecycle() + FASTDDS_EXPORTED_API ReaderDataLifecycleQosPolicy& reader_data_lifecycle() { return reader_data_lifecycle_; } @@ -569,7 +569,7 @@ class DataReaderQos * * @return ReaderDataLifecycleQosPolicy const reference */ - RTPS_DllAPI const ReaderDataLifecycleQosPolicy& reader_data_lifecycle() const + FASTDDS_EXPORTED_API const ReaderDataLifecycleQosPolicy& reader_data_lifecycle() const { return reader_data_lifecycle_; } @@ -579,7 +579,7 @@ class DataReaderQos * * @param new_value new value for the ReaderDataLifecycleQosPolicy */ - RTPS_DllAPI void reader_data_lifecycle( + FASTDDS_EXPORTED_API void reader_data_lifecycle( const ReaderDataLifecycleQosPolicy& new_value) { reader_data_lifecycle_ = new_value; @@ -590,7 +590,7 @@ class DataReaderQos * * @return LifespanQosPolicy reference */ - RTPS_DllAPI LifespanQosPolicy& lifespan() + FASTDDS_EXPORTED_API LifespanQosPolicy& lifespan() { return lifespan_; } @@ -600,7 +600,7 @@ class DataReaderQos * * @return LifespanQosPolicy const reference */ - RTPS_DllAPI const LifespanQosPolicy& lifespan() const + FASTDDS_EXPORTED_API const LifespanQosPolicy& lifespan() const { return lifespan_; } @@ -610,7 +610,7 @@ class DataReaderQos * * @param new_value new value for the LifespanQosPolicy */ - RTPS_DllAPI void lifespan( + FASTDDS_EXPORTED_API void lifespan( const LifespanQosPolicy& new_value) { lifespan_ = new_value; @@ -621,7 +621,7 @@ class DataReaderQos * * @return DurabilityServiceQosPolicy reference */ - RTPS_DllAPI DurabilityServiceQosPolicy& durability_service() + FASTDDS_EXPORTED_API DurabilityServiceQosPolicy& durability_service() { return durability_service_; } @@ -631,7 +631,7 @@ class DataReaderQos * * @return DurabilityServiceQosPolicy const reference */ - RTPS_DllAPI const DurabilityServiceQosPolicy& durability_service() const + FASTDDS_EXPORTED_API const DurabilityServiceQosPolicy& durability_service() const { return durability_service_; } @@ -641,7 +641,7 @@ class DataReaderQos * * @param new_value new value for the DurabilityServiceQosPolicy */ - RTPS_DllAPI void durability_service( + FASTDDS_EXPORTED_API void durability_service( const DurabilityServiceQosPolicy& new_value) { durability_service_ = new_value; @@ -652,7 +652,7 @@ class DataReaderQos * * @return RTPSReliableReaderQos reference */ - RTPS_DllAPI RTPSReliableReaderQos& reliable_reader_qos() + FASTDDS_EXPORTED_API RTPSReliableReaderQos& reliable_reader_qos() { return reliable_reader_qos_; } @@ -662,7 +662,7 @@ class DataReaderQos * * @return RTPSReliableReaderQos const reference */ - RTPS_DllAPI const RTPSReliableReaderQos& reliable_reader_qos() const + FASTDDS_EXPORTED_API const RTPSReliableReaderQos& reliable_reader_qos() const { return reliable_reader_qos_; } @@ -672,7 +672,7 @@ class DataReaderQos * * @param new_value new value for the RTPSReliableReaderQos */ - RTPS_DllAPI void reliable_reader_qos( + FASTDDS_EXPORTED_API void reliable_reader_qos( const RTPSReliableReaderQos& new_value) { reliable_reader_qos_ = new_value; @@ -683,7 +683,7 @@ class DataReaderQos * * @return TypeConsistencyQos reference */ - RTPS_DllAPI TypeConsistencyQos& type_consistency() + FASTDDS_EXPORTED_API TypeConsistencyQos& type_consistency() { return type_consistency_; } @@ -693,7 +693,7 @@ class DataReaderQos * * @return TypeConsistencyQos const reference */ - RTPS_DllAPI const TypeConsistencyQos& type_consistency() const + FASTDDS_EXPORTED_API const TypeConsistencyQos& type_consistency() const { return type_consistency_; } @@ -703,7 +703,7 @@ class DataReaderQos * * @param new_value new value for the TypeConsistencyQos */ - RTPS_DllAPI void type_consistency( + FASTDDS_EXPORTED_API void type_consistency( const TypeConsistencyQos& new_value) { type_consistency_ = new_value; @@ -714,7 +714,7 @@ class DataReaderQos * * @return expectsInlineQos */ - RTPS_DllAPI bool expects_inline_qos() const + FASTDDS_EXPORTED_API bool expects_inline_qos() const { return expects_inline_qos_; } @@ -724,7 +724,7 @@ class DataReaderQos * * @param new_value new value for the expectsInlineQos */ - RTPS_DllAPI void expects_inline_qos( + FASTDDS_EXPORTED_API void expects_inline_qos( bool new_value) { expects_inline_qos_ = new_value; @@ -735,7 +735,7 @@ class DataReaderQos * * @return PropertyPolicyQos reference */ - RTPS_DllAPI PropertyPolicyQos& properties() + FASTDDS_EXPORTED_API PropertyPolicyQos& properties() { return properties_; } @@ -745,7 +745,7 @@ class DataReaderQos * * @return PropertyPolicyQos const reference */ - RTPS_DllAPI const PropertyPolicyQos& properties() const + FASTDDS_EXPORTED_API const PropertyPolicyQos& properties() const { return properties_; } @@ -755,7 +755,7 @@ class DataReaderQos * * @param new_value new value for the PropertyPolicyQos */ - RTPS_DllAPI void properties( + FASTDDS_EXPORTED_API void properties( const PropertyPolicyQos& new_value) { properties_ = new_value; @@ -766,7 +766,7 @@ class DataReaderQos * * @return RTPSEndpointQos reference */ - RTPS_DllAPI RTPSEndpointQos& endpoint() + FASTDDS_EXPORTED_API RTPSEndpointQos& endpoint() { return endpoint_; } @@ -776,7 +776,7 @@ class DataReaderQos * * @return RTPSEndpointQos const reference */ - RTPS_DllAPI const RTPSEndpointQos& endpoint() const + FASTDDS_EXPORTED_API const RTPSEndpointQos& endpoint() const { return endpoint_; } @@ -786,7 +786,7 @@ class DataReaderQos * * @param new_value new value for the RTPSEndpointQos */ - RTPS_DllAPI void endpoint( + FASTDDS_EXPORTED_API void endpoint( const RTPSEndpointQos& new_value) { endpoint_ = new_value; @@ -797,7 +797,7 @@ class DataReaderQos * * @return ReaderResourceLimitsQos reference */ - RTPS_DllAPI ReaderResourceLimitsQos& reader_resource_limits() + FASTDDS_EXPORTED_API ReaderResourceLimitsQos& reader_resource_limits() { return reader_resource_limits_; } @@ -807,7 +807,7 @@ class DataReaderQos * * @return ReaderResourceLimitsQos const reference */ - RTPS_DllAPI const ReaderResourceLimitsQos& reader_resource_limits() const + FASTDDS_EXPORTED_API const ReaderResourceLimitsQos& reader_resource_limits() const { return reader_resource_limits_; } @@ -817,7 +817,7 @@ class DataReaderQos * * @param new_value new value for the ReaderResourceLimitsQos */ - RTPS_DllAPI void reader_resource_limits( + FASTDDS_EXPORTED_API void reader_resource_limits( const ReaderResourceLimitsQos& new_value) { reader_resource_limits_ = new_value; @@ -828,7 +828,7 @@ class DataReaderQos * * @return DataSharingQosPolicy reference */ - RTPS_DllAPI DataSharingQosPolicy& data_sharing() + FASTDDS_EXPORTED_API DataSharingQosPolicy& data_sharing() { return data_sharing_; } @@ -838,7 +838,7 @@ class DataReaderQos * * @return DataSharingQosPolicy reference */ - RTPS_DllAPI const DataSharingQosPolicy& data_sharing() const + FASTDDS_EXPORTED_API const DataSharingQosPolicy& data_sharing() const { return data_sharing_; } @@ -848,7 +848,7 @@ class DataReaderQos * * @param data_sharing new value for the DataSharingQosPolicy */ - RTPS_DllAPI void data_sharing( + FASTDDS_EXPORTED_API void data_sharing( const DataSharingQosPolicy& data_sharing) { data_sharing_ = data_sharing; @@ -920,8 +920,8 @@ class DataReaderQos DataSharingQosPolicy data_sharing_; }; -RTPS_DllAPI extern const DataReaderQos DATAREADER_QOS_DEFAULT; -RTPS_DllAPI extern const DataReaderQos DATAREADER_QOS_USE_TOPIC_QOS; +FASTDDS_EXPORTED_API extern const DataReaderQos DATAREADER_QOS_DEFAULT; +FASTDDS_EXPORTED_API extern const DataReaderQos DATAREADER_QOS_USE_TOPIC_QOS; } // namespace dds } // namespace fastdds diff --git a/include/fastdds/dds/subscriber/qos/ReaderQos.hpp b/include/fastdds/dds/subscriber/qos/ReaderQos.hpp index 84b3e8154d2..ac8a42a9126 100644 --- a/include/fastdds/dds/subscriber/qos/ReaderQos.hpp +++ b/include/fastdds/dds/subscriber/qos/ReaderQos.hpp @@ -31,17 +31,17 @@ namespace dds { * Although these values can be set and are transmitted * during the Endpoint Discovery Protocol, not all of the behaviour associated with them has been implemented in the library. * Please consult each of them to check for implementation details and default values. - * @ingroup FASTRTPS_ATTRIBUTES_MODULE + * @ingroup FASTDDS_QOS_MODULE */ class ReaderQos { public: - RTPS_DllAPI ReaderQos() + FASTDDS_EXPORTED_API ReaderQos() { } - RTPS_DllAPI virtual ~ReaderQos() + FASTDDS_EXPORTED_API virtual ~ReaderQos() { } @@ -131,7 +131,7 @@ class ReaderQos * @param readerqos Reference from a ReaderQos object. * @param first_time Boolean indicating whether is the first time (If not some parameters cannot be set). */ - RTPS_DllAPI void setQos( + FASTDDS_EXPORTED_API void setQos( const ReaderQos& readerqos, bool first_time); @@ -139,14 +139,14 @@ class ReaderQos * Check if the Qos values are compatible between each other. * @return True if correct. */ - RTPS_DllAPI bool checkQos() const; + FASTDDS_EXPORTED_API bool checkQos() const; /** * Check if the Qos can be update with the values provided. This method DOES NOT update anything. * @param qos Reference to the new qos. * @return True if they can be updated. */ - RTPS_DllAPI bool canQosBeUpdated( + FASTDDS_EXPORTED_API bool canQosBeUpdated( const ReaderQos& qos) const; void clear(); diff --git a/include/fastdds/dds/subscriber/qos/SubscriberQos.hpp b/include/fastdds/dds/subscriber/qos/SubscriberQos.hpp index 3f1e029d65c..11c74a871c9 100644 --- a/include/fastdds/dds/subscriber/qos/SubscriberQos.hpp +++ b/include/fastdds/dds/subscriber/qos/SubscriberQos.hpp @@ -21,7 +21,6 @@ #define _FASTDDS_SUBSCRIBERQOS_HPP_ #include -#include namespace eprosima { namespace fastdds { @@ -42,14 +41,14 @@ class SubscriberQos /** * @brief Constructor */ - RTPS_DllAPI SubscriberQos() + FASTDDS_EXPORTED_API SubscriberQos() { } /** * @brief Destructor */ - RTPS_DllAPI virtual ~SubscriberQos() + FASTDDS_EXPORTED_API virtual ~SubscriberQos() { } @@ -201,7 +200,7 @@ class SubscriberQos EntityFactoryQosPolicy entity_factory_; }; -RTPS_DllAPI extern const SubscriberQos SUBSCRIBER_QOS_DEFAULT; +FASTDDS_EXPORTED_API extern const SubscriberQos SUBSCRIBER_QOS_DEFAULT; } /* namespace dds */ diff --git a/include/fastdds/dds/topic/ContentFilteredTopic.hpp b/include/fastdds/dds/topic/ContentFilteredTopic.hpp index 0935c408a48..bda635de270 100644 --- a/include/fastdds/dds/topic/ContentFilteredTopic.hpp +++ b/include/fastdds/dds/topic/ContentFilteredTopic.hpp @@ -19,14 +19,13 @@ #ifndef _FASTDDS_DDS_TOPIC_CONTENTFILTEREDTOPIC_HPP_ #define _FASTDDS_DDS_TOPIC_CONTENTFILTEREDTOPIC_HPP_ -#include +#include #include #include +#include #define FASTDDS_SQLFILTER_NAME eprosima::fastdds::dds::sqlfilter_name -using eprosima::fastrtps::types::ReturnCode_t; - namespace eprosima { namespace fastdds { namespace dds { @@ -64,7 +63,7 @@ class ContentFilteredTopic : public TopicDescription * This operation returns the Topic associated with the ContentFilteredTopic. * That is, the Topic specified when the ContentFilteredTopic was created. */ - RTPS_DllAPI Topic* get_related_topic() const; + FASTDDS_EXPORTED_API Topic* get_related_topic() const; /** * @brief Get the filter expression. @@ -75,7 +74,7 @@ class ContentFilteredTopic : public TopicDescription * * @return the @c filter_expression. */ - RTPS_DllAPI const std::string& get_filter_expression() const; + FASTDDS_EXPORTED_API const std::string& get_filter_expression() const; /** * @brief Get the expression parameters. @@ -91,7 +90,7 @@ class ContentFilteredTopic : public TopicDescription * * @return RETCODE_OK */ - RTPS_DllAPI ReturnCode_t get_expression_parameters( + FASTDDS_EXPORTED_API ReturnCode_t get_expression_parameters( std::vector& expression_parameters) const; /** @@ -104,7 +103,7 @@ class ContentFilteredTopic : public TopicDescription * @return RETCODE_OK if the expression parameters where correctly updated. * @return RETCODE_BAD_PARAMETER if the expression parameters do not match with the current @c filter_expression. */ - RTPS_DllAPI ReturnCode_t set_expression_parameters( + FASTDDS_EXPORTED_API ReturnCode_t set_expression_parameters( const std::vector& expression_parameters); /** @@ -120,7 +119,7 @@ class ContentFilteredTopic : public TopicDescription * @return RETCODE_BAD_PARAMETER if @c filter_expression is not valid for this ContentFilteredTopic. * @return RETCODE_BAD_PARAMETER if the expression parameters do not match with the @c filter_expression. */ - RTPS_DllAPI ReturnCode_t set_filter_expression( + FASTDDS_EXPORTED_API ReturnCode_t set_filter_expression( const std::string& filter_expression, const std::vector& expression_parameters); @@ -128,7 +127,7 @@ class ContentFilteredTopic : public TopicDescription * @brief Getter for the DomainParticipant * @return DomainParticipant pointer */ - RTPS_DllAPI DomainParticipant* get_participant() const override; + FASTDDS_EXPORTED_API DomainParticipant* get_participant() const override; TopicDescriptionImpl* get_impl() const override; diff --git a/include/fastdds/dds/topic/IContentFilter.hpp b/include/fastdds/dds/topic/IContentFilter.hpp index 62449bc68f9..aef9f387a59 100644 --- a/include/fastdds/dds/topic/IContentFilter.hpp +++ b/include/fastdds/dds/topic/IContentFilter.hpp @@ -19,17 +19,12 @@ #ifndef _FASTDDS_DDS_TOPIC_ICONTENTFILTER_HPP_ #define _FASTDDS_DDS_TOPIC_ICONTENTFILTER_HPP_ -#include - -#include +#include #include #include #include -#include -#include - namespace eprosima { namespace fastdds { namespace dds { diff --git a/include/fastdds/dds/topic/IContentFilterFactory.hpp b/include/fastdds/dds/topic/IContentFilterFactory.hpp index 598767b1b81..b61219d4151 100644 --- a/include/fastdds/dds/topic/IContentFilterFactory.hpp +++ b/include/fastdds/dds/topic/IContentFilterFactory.hpp @@ -19,14 +19,13 @@ #ifndef _FASTDDS_DDS_TOPIC_ICONTENTFILTERFACTORY_HPP_ #define _FASTDDS_DDS_TOPIC_ICONTENTFILTERFACTORY_HPP_ -#include +#include #include +#include #include #include -#include - namespace eprosima { namespace fastdds { namespace dds { @@ -36,9 +35,7 @@ namespace dds { */ struct IContentFilterFactory { - using ReturnCode_t = eprosima::fastrtps::types::ReturnCode_t; using ParameterSeq = LoanableTypedCollection; - using TypeDescriptor = eprosima::fastrtps::types::TypeDescriptor; /** * Create or update an IContentFilter instance. diff --git a/include/fastdds/dds/topic/Topic.hpp b/include/fastdds/dds/topic/Topic.hpp index e44afb4e605..c10e34f9793 100644 --- a/include/fastdds/dds/topic/Topic.hpp +++ b/include/fastdds/dds/topic/Topic.hpp @@ -19,14 +19,13 @@ #ifndef _FASTDDS_TOPIC_HPP_ #define _FASTDDS_TOPIC_HPP_ -#include +#include #include +#include #include #include #include -using eprosima::fastrtps::types::ReturnCode_t; - namespace dds { namespace topic { @@ -91,7 +90,7 @@ class Topic : public DomainEntity, public TopicDescription * @return RETCODE_OK * @warning Not supported yet. Currently returns RETCODE_UNSUPPORTED */ - RTPS_DllAPI ReturnCode_t get_inconsistent_topic_status( + FASTDDS_EXPORTED_API ReturnCode_t get_inconsistent_topic_status( InconsistentTopicStatus& status); /** @@ -99,7 +98,7 @@ class Topic : public DomainEntity, public TopicDescription * * @return reference to TopicQos */ - RTPS_DllAPI const TopicQos& get_qos() const; + FASTDDS_EXPORTED_API const TopicQos& get_qos() const; /** * Retrieves the Topic Qos. @@ -107,7 +106,7 @@ class Topic : public DomainEntity, public TopicDescription * @param qos TopicQos where the qos is returned * @return RETCODE_OK */ - RTPS_DllAPI ReturnCode_t get_qos( + FASTDDS_EXPORTED_API ReturnCode_t get_qos( TopicQos& qos) const; /** @@ -119,7 +118,7 @@ class Topic : public DomainEntity, public TopicDescription * @retval RETCODE_INCONSISTENT_POLICY if new qos has inconsistent values. * @retval RETCODE_OK if qos was updated. */ - RTPS_DllAPI ReturnCode_t set_qos( + FASTDDS_EXPORTED_API ReturnCode_t set_qos( const TopicQos& qos); /** @@ -127,7 +126,7 @@ class Topic : public DomainEntity, public TopicDescription * * @return pointer to TopicListener */ - RTPS_DllAPI const TopicListener* get_listener() const; + FASTDDS_EXPORTED_API const TopicListener* get_listener() const; /** * Modifies the TopicListener. @@ -136,7 +135,7 @@ class Topic : public DomainEntity, public TopicDescription * @param mask StatusMask that holds statuses the listener responds to (default: all). * @return RETCODE_OK */ - RTPS_DllAPI ReturnCode_t set_listener( + FASTDDS_EXPORTED_API ReturnCode_t set_listener( TopicListener* listener, const StatusMask& mask = StatusMask::all()); diff --git a/include/fastdds/dds/topic/TopicDataType.hpp b/include/fastdds/dds/topic/TopicDataType.hpp index 3bd5072444a..3262574fd78 100644 --- a/include/fastdds/dds/topic/TopicDataType.hpp +++ b/include/fastdds/dds/topic/TopicDataType.hpp @@ -24,12 +24,11 @@ #include #include +#include #include #include #include - -#include -#include +#include // This version of TypeSupport has `is_bounded()` #define TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED @@ -57,7 +56,7 @@ class TypeSupport; /** * Class TopicDataType used to provide the DomainRTPSParticipant with the methods to serialize, deserialize and get the key of a specific data type. * The user should created a class that inherits from this one, where Serialize and deserialize methods MUST be implemented. - * @ingroup FASTRTPS_MODULE, FASTDDS_MODULE + * @ingroup FASTDDS_MODULE */ class TopicDataType { @@ -66,12 +65,12 @@ class TopicDataType /** * @brief Constructor */ - RTPS_DllAPI TopicDataType(); + FASTDDS_EXPORTED_API TopicDataType(); /** * @brief Destructor */ - RTPS_DllAPI virtual ~TopicDataType(); + FASTDDS_EXPORTED_API virtual ~TopicDataType(); /** * Serialize method, it should be implemented by the user, since it is abstract. @@ -81,8 +80,9 @@ class TopicDataType * @param[out] payload Pointer to the payload * @return True if correct. */ + // TODO(jlbueno) Remove when Fast DDS-Gen is updated // FASTDDS_TODO_BEFORE(3, 0, "Remove this overload") - RTPS_DllAPI virtual bool serialize( + FASTDDS_EXPORTED_API virtual bool serialize( void* data, fastrtps::rtps::SerializedPayload_t* payload) = 0; @@ -96,7 +96,7 @@ class TopicDataType * @param[in] data_representation Representation that should be used to encode the data into the payload. * @return True if correct. */ - RTPS_DllAPI virtual bool serialize( + FASTDDS_EXPORTED_API virtual bool serialize( void* data, fastrtps::rtps::SerializedPayload_t* payload, DataRepresentationId_t data_representation); @@ -108,7 +108,7 @@ class TopicDataType * @param[out] data Pointer to the data * @return True if correct. */ - RTPS_DllAPI virtual bool deserialize( + FASTDDS_EXPORTED_API virtual bool deserialize( fastrtps::rtps::SerializedPayload_t* payload, void* data) = 0; @@ -118,7 +118,8 @@ class TopicDataType * @param[in] data Pointer to data. * @return Functor which calculates the serialized size of the data. */ - RTPS_DllAPI virtual std::function getSerializedSizeProvider( + // FASTDDS_TODO_BEFORE(3, 0, "Remove this overload") + FASTDDS_EXPORTED_API virtual std::function getSerializedSizeProvider( void* data) = 0; /*! @@ -128,7 +129,7 @@ class TopicDataType * @param[in] data_representation Representation that should be used for calculating the serialized size. * @return Functor which calculates the serialized size of the data. */ - RTPS_DllAPI virtual std::function getSerializedSizeProvider( + FASTDDS_EXPORTED_API virtual std::function getSerializedSizeProvider( void* data, DataRepresentationId_t data_representation); @@ -137,13 +138,13 @@ class TopicDataType * * @return Void pointer to the created object. */ - RTPS_DllAPI virtual void* createData() = 0; + FASTDDS_EXPORTED_API virtual void* createData() = 0; /** * Remove a previously created object. * * @param data Pointer to the created Data. */ - RTPS_DllAPI virtual void deleteData( + FASTDDS_EXPORTED_API virtual void deleteData( void* data) = 0; /** @@ -154,7 +155,7 @@ class TopicDataType * @param[in] force_md5 Force MD5 checking. * @return True if correct. */ - RTPS_DllAPI virtual bool getKey( + FASTDDS_EXPORTED_API virtual bool getKey( void* data, fastrtps::rtps::InstanceHandle_t* ihandle, bool force_md5 = false) = 0; @@ -164,7 +165,7 @@ class TopicDataType * * @param nam Topic data type name */ - RTPS_DllAPI inline void setName( + FASTDDS_EXPORTED_API inline void setName( const char* nam) { m_topicDataTypeName = std::string(nam); @@ -175,38 +176,17 @@ class TopicDataType * * @return Topic data type name */ - RTPS_DllAPI inline const char* getName() const + FASTDDS_EXPORTED_API inline const char* getName() const { return m_topicDataTypeName.c_str(); } - /** - * Get the type object auto-fill configuration - * - * @return true if the type object should be auto-filled - */ - RTPS_DllAPI inline bool auto_fill_type_object() const - { - return auto_fill_type_object_; - } - - /** - * Set the type object auto-fill configuration - * - * @param auto_fill_type_object new value to set - */ - RTPS_DllAPI inline void auto_fill_type_object( - bool auto_fill_type_object) - { - auto_fill_type_object_ = auto_fill_type_object; - } - /** * Get the type information auto-fill configuration * * @return true if the type information should be auto-filled */ - RTPS_DllAPI inline bool auto_fill_type_information() const + FASTDDS_EXPORTED_API inline bool auto_fill_type_information() const { return auto_fill_type_information_; } @@ -216,7 +196,7 @@ class TopicDataType * * @param auto_fill_type_information new value to set */ - RTPS_DllAPI inline void auto_fill_type_information( + FASTDDS_EXPORTED_API inline void auto_fill_type_information( bool auto_fill_type_information) { auto_fill_type_information_ = auto_fill_type_information; @@ -227,7 +207,7 @@ class TopicDataType * * @return TypeIdV1 */ - RTPS_DllAPI inline const std::shared_ptr type_identifier() const + FASTDDS_EXPORTED_API inline const std::shared_ptr type_identifier() const { return type_identifier_; } @@ -237,7 +217,7 @@ class TopicDataType * * @param id new value for TypeIdV1 */ - RTPS_DllAPI inline void type_identifier( + FASTDDS_EXPORTED_API inline void type_identifier( const TypeIdV1& id) { type_identifier_ = std::make_shared(id); @@ -248,7 +228,7 @@ class TopicDataType * * @param id shared pointer to TypeIdV1 */ - RTPS_DllAPI inline void type_identifier( + FASTDDS_EXPORTED_API inline void type_identifier( const std::shared_ptr id) { type_identifier_ = std::move(id); @@ -259,7 +239,7 @@ class TopicDataType * * @return TypeObjectV1 */ - RTPS_DllAPI inline const std::shared_ptr type_object() const + FASTDDS_EXPORTED_API inline const std::shared_ptr type_object() const { return type_object_; } @@ -269,7 +249,7 @@ class TopicDataType * * @param object new value for TypeObjectV1 */ - RTPS_DllAPI inline void type_object( + FASTDDS_EXPORTED_API inline void type_object( const TypeObjectV1& object) { type_object_ = std::make_shared(object); @@ -280,7 +260,7 @@ class TopicDataType * * @param object shared pointer to TypeObjectV1 */ - RTPS_DllAPI inline void type_object( + FASTDDS_EXPORTED_API inline void type_object( std::shared_ptr object) { type_object_ = std::move(object); @@ -289,9 +269,9 @@ class TopicDataType /** * Get the type information * - * @return TypeInformation + * @return TypeInformationParameter */ - RTPS_DllAPI inline const std::shared_ptr type_information() const + FASTDDS_EXPORTED_API inline const std::shared_ptr type_information() const { return type_information_; } @@ -299,21 +279,21 @@ class TopicDataType /** * Set type information * - * @param info new value for TypeInformation + * @param info new value for TypeInformationParameter */ - RTPS_DllAPI inline void type_information( - const xtypes::TypeInformation& info) + FASTDDS_EXPORTED_API inline void type_information( + const xtypes::TypeInformationParameter& info) { - type_information_ = std::make_shared(info); + type_information_ = std::make_shared(info); } /** * Set type information * - * @param info shared pointer to TypeInformation + * @param info shared pointer to TypeInformationParameter */ - RTPS_DllAPI inline void type_information( - std::shared_ptr info) + FASTDDS_EXPORTED_API inline void type_information( + std::shared_ptr info) { type_information_ = std::move(info); } @@ -321,7 +301,7 @@ class TopicDataType /** * Checks if the type is bounded. */ - RTPS_DllAPI virtual inline bool is_bounded() const + FASTDDS_EXPORTED_API virtual inline bool is_bounded() const { return false; } @@ -329,7 +309,7 @@ class TopicDataType /** * Checks if the type is plain when using default encoding. */ - RTPS_DllAPI virtual inline bool is_plain() const + FASTDDS_EXPORTED_API virtual inline bool is_plain() const { return false; } @@ -337,7 +317,7 @@ class TopicDataType /** * Checks if the type is plain when using a specific encoding. */ - RTPS_DllAPI virtual inline bool is_plain( + FASTDDS_EXPORTED_API virtual inline bool is_plain( DataRepresentationId_t) const { return false; @@ -350,13 +330,20 @@ class TopicDataType * * @return whether this type supports in-place construction or not. */ - RTPS_DllAPI virtual inline bool construct_sample( + FASTDDS_EXPORTED_API virtual inline bool construct_sample( void* memory) const { static_cast(memory); return false; } + /** + * @brief Register TypeObject type representation + */ + FASTDDS_EXPORTED_API virtual inline void register_type_object_representation() const + { + } + //! Maximum serialized size of the type in bytes. //! If the type has unbounded fields, and therefore cannot have a maximum size, use 0. uint32_t m_typeSize; @@ -371,14 +358,13 @@ class TopicDataType //!Type Object XTYPES 1.1 std::shared_ptr type_object_; //!XTYPES 1.2 - std::shared_ptr type_information_; + std::shared_ptr type_information_; private: //! Data Type Name. std::string m_topicDataTypeName; - - bool auto_fill_type_object_; + //TODO(XTypes) bool auto_fill_type_information_; friend class fastdds::dds::TypeSupport; diff --git a/include/fastdds/dds/topic/TopicListener.hpp b/include/fastdds/dds/topic/TopicListener.hpp index 61344fc52fd..6f5dd31a482 100644 --- a/include/fastdds/dds/topic/TopicListener.hpp +++ b/include/fastdds/dds/topic/TopicListener.hpp @@ -19,7 +19,7 @@ #ifndef _FASTDDS_TOPICLISTENER_HPP_ #define _FASTDDS_TOPICLISTENER_HPP_ -#include +#include #include namespace eprosima { @@ -33,7 +33,7 @@ class Topic; * * @ingroup FASTDDS_MODULE */ -class RTPS_DllAPI TopicListener +class FASTDDS_EXPORTED_API TopicListener { public: diff --git a/include/fastdds/dds/topic/TypeSupport.hpp b/include/fastdds/dds/topic/TypeSupport.hpp index 549dcd03e79..e2b3b9c0d56 100644 --- a/include/fastdds/dds/topic/TypeSupport.hpp +++ b/include/fastdds/dds/topic/TypeSupport.hpp @@ -19,15 +19,16 @@ #ifndef _FASTDDS_TYPE_SUPPORT_HPP_ #define _FASTDDS_TYPE_SUPPORT_HPP_ -#include -#include -#include -#include - #include #include #include +#include +#include +#include +#include +#include + namespace eprosima { namespace fastdds { namespace dds { @@ -42,25 +43,23 @@ class DomainParticipant; * where Serialize and deserialize methods MUST be implemented. * @ingroup FASTDDS_MODULE */ -class TypeSupport : public std::shared_ptr +class TypeSupport : public std::shared_ptr { public: - using ReturnCode_t = eprosima::fastrtps::types::ReturnCode_t; - - using Base = std::shared_ptr; + using Base = std::shared_ptr; /** * @brief Constructor */ - RTPS_DllAPI TypeSupport() noexcept = default; + FASTDDS_EXPORTED_API TypeSupport() noexcept = default; /** * @brief Copy Constructor * * @param type Another instance of TypeSupport */ - RTPS_DllAPI TypeSupport( + FASTDDS_EXPORTED_API TypeSupport( const TypeSupport& type) noexcept = default; /** @@ -68,7 +67,7 @@ class TypeSupport : public std::shared_ptr * * @param type Another instance of TypeSupport */ - RTPS_DllAPI TypeSupport( + FASTDDS_EXPORTED_API TypeSupport( TypeSupport&& type) noexcept = default; /** @@ -76,7 +75,7 @@ class TypeSupport : public std::shared_ptr * * @param type Another instance of TypeSupport */ - RTPS_DllAPI TypeSupport& operator = ( + FASTDDS_EXPORTED_API TypeSupport& operator = ( const TypeSupport& type) noexcept = default; /** @@ -84,7 +83,7 @@ class TypeSupport : public std::shared_ptr * * @param type Another instance of TypeSupport */ - RTPS_DllAPI TypeSupport& operator = ( + FASTDDS_EXPORTED_API TypeSupport& operator = ( TypeSupport&& type) noexcept = default; /*! @@ -94,9 +93,9 @@ class TypeSupport : public std::shared_ptr * * @param ptr */ - RTPS_DllAPI explicit TypeSupport( - fastdds::dds::TopicDataType* ptr) - : std::shared_ptr(ptr) + FASTDDS_EXPORTED_API explicit TypeSupport( + TopicDataType* ptr) + : std::shared_ptr(ptr) { } @@ -106,10 +105,9 @@ class TypeSupport : public std::shared_ptr * * @param ptr */ - RTPS_DllAPI TypeSupport( - fastrtps::types::DynamicPubSubType ptr) - : std::shared_ptr(std::make_shared(std::move( - ptr))) + FASTDDS_EXPORTED_API TypeSupport( + DynamicPubSubType ptr) + : std::shared_ptr(std::make_shared(std::move(ptr))) { } @@ -120,7 +118,7 @@ class TypeSupport : public std::shared_ptr * @return RETCODE_BAD_PARAMETER if the type name is empty, RETCODE_PRECONDITION_NOT_MET if there is another type with * the same name registered on the DomainParticipant and RETCODE_OK if it is registered correctly */ - RTPS_DllAPI virtual ReturnCode_t register_type( + FASTDDS_EXPORTED_API virtual ReturnCode_t register_type( DomainParticipant* participant) const; /** @@ -131,7 +129,7 @@ class TypeSupport : public std::shared_ptr * @return RETCODE_BAD_PARAMETER if the type name is empty, RETCODE_PRECONDITION_NOT_MET if there is another type with * the same name registered on the DomainParticipant and RETCODE_OK if it is registered correctly */ - RTPS_DllAPI virtual ReturnCode_t register_type( + FASTDDS_EXPORTED_API virtual ReturnCode_t register_type( DomainParticipant* participant, std::string type_name) const; @@ -140,7 +138,7 @@ class TypeSupport : public std::shared_ptr * * @return name of the data type */ - RTPS_DllAPI virtual const std::string& get_type_name() const + FASTDDS_EXPORTED_API virtual const std::string& get_type_name() const { return get()->m_topicDataTypeName; } @@ -153,7 +151,7 @@ class TypeSupport : public std::shared_ptr * @return true if it is serialized correctly, false if not */ - RTPS_DllAPI virtual bool serialize( + FASTDDS_EXPORTED_API virtual bool serialize( void* data, fastrtps::rtps::SerializedPayload_t* payload) { @@ -168,7 +166,7 @@ class TypeSupport : public std::shared_ptr * @param[in] data_representation Representation that should be used to encode the data into the payload. * @return true if it is serialized correctly, false if not */ - RTPS_DllAPI virtual bool serialize( + FASTDDS_EXPORTED_API virtual bool serialize( void* data, fastrtps::rtps::SerializedPayload_t* payload, DataRepresentationId_t data_representation); @@ -180,7 +178,7 @@ class TypeSupport : public std::shared_ptr * @param data Pointer to data * @return true if it is deserialized correctly, false if not */ - RTPS_DllAPI virtual bool deserialize( + FASTDDS_EXPORTED_API virtual bool deserialize( fastrtps::rtps::SerializedPayload_t* payload, void* data); @@ -190,7 +188,7 @@ class TypeSupport : public std::shared_ptr * @param[in] data Pointer to data. * @return Functor which calculates the serialized size of the data. */ - RTPS_DllAPI virtual std::function get_serialized_size_provider( + FASTDDS_EXPORTED_API virtual std::function get_serialized_size_provider( void* data) { return get_serialized_size_provider(data, DEFAULT_DATA_REPRESENTATION); @@ -203,7 +201,7 @@ class TypeSupport : public std::shared_ptr * @param[in] data_representation Representation that should be used for calculating the serialized size. * @return Functor which calculates the serialized size of the data. */ - RTPS_DllAPI virtual std::function get_serialized_size_provider( + FASTDDS_EXPORTED_API virtual std::function get_serialized_size_provider( void* data, DataRepresentationId_t data_representation) { @@ -215,7 +213,7 @@ class TypeSupport : public std::shared_ptr * * @return Pointer to the data */ - RTPS_DllAPI virtual void* create_data() + FASTDDS_EXPORTED_API virtual void* create_data() { return get()->createData(); } @@ -225,7 +223,7 @@ class TypeSupport : public std::shared_ptr * * @param data Pointer to the data to delete */ - RTPS_DllAPI virtual void delete_data( + FASTDDS_EXPORTED_API virtual void delete_data( void* data) { return get()->deleteData(data); @@ -239,7 +237,7 @@ class TypeSupport : public std::shared_ptr * @param force_md5 boolean to force md5 (default: false) * @return true if the key is returned, false if not */ - RTPS_DllAPI virtual bool get_key( + FASTDDS_EXPORTED_API virtual bool get_key( void* data, InstanceHandle_t* i_handle, bool force_md5 = false) @@ -247,7 +245,7 @@ class TypeSupport : public std::shared_ptr return get()->getKey(data, i_handle, force_md5); } - RTPS_DllAPI virtual bool operator ==( + FASTDDS_EXPORTED_API virtual bool operator ==( const TypeSupport& type_support) { return get()->m_typeSize == type_support->m_typeSize @@ -263,7 +261,7 @@ class TypeSupport : public std::shared_ptr * * @return true if empty, false if not */ - RTPS_DllAPI bool empty() const + FASTDDS_EXPORTED_API bool empty() const { return get() == nullptr; } @@ -271,7 +269,7 @@ class TypeSupport : public std::shared_ptr /** * Checks if the type is bounded. */ - RTPS_DllAPI virtual inline bool is_bounded() const + FASTDDS_EXPORTED_API virtual inline bool is_bounded() const { return get()->is_bounded(); } @@ -279,7 +277,7 @@ class TypeSupport : public std::shared_ptr /** * Checks if the type is plain when using default encoding. */ - RTPS_DllAPI virtual inline bool is_plain() const + FASTDDS_EXPORTED_API virtual inline bool is_plain() const { return is_plain(DataRepresentationId_t::XCDR_DATA_REPRESENTATION); } @@ -287,19 +285,19 @@ class TypeSupport : public std::shared_ptr /** * Checks if the type is plain when using a specific encoding. */ - RTPS_DllAPI virtual inline bool is_plain( + FASTDDS_EXPORTED_API virtual inline bool is_plain( DataRepresentationId_t data_representation) const { return get()->is_plain(data_representation); } - RTPS_DllAPI bool operator !=( + FASTDDS_EXPORTED_API bool operator !=( std::nullptr_t) const { return bool(*this); } - RTPS_DllAPI bool operator ==( + FASTDDS_EXPORTED_API bool operator ==( std::nullptr_t) const { return !*this; diff --git a/include/fastdds/dds/topic/qos/TopicQos.hpp b/include/fastdds/dds/topic/qos/TopicQos.hpp index 0c64050bd35..7970e1af73d 100644 --- a/include/fastdds/dds/topic/qos/TopicQos.hpp +++ b/include/fastdds/dds/topic/qos/TopicQos.hpp @@ -21,7 +21,7 @@ #define _FASTDDS_TOPICQOS_HPP #include -#include +#include #include @@ -44,7 +44,7 @@ class TopicQos /** * @brief Constructor */ - RTPS_DllAPI TopicQos(); + FASTDDS_EXPORTED_API TopicQos(); bool operator ==( const TopicQos& b) const @@ -543,7 +543,7 @@ class TopicQos DataRepresentationQosPolicy representation_; }; -RTPS_DllAPI extern const TopicQos TOPIC_QOS_DEFAULT; +FASTDDS_EXPORTED_API extern const TopicQos TOPIC_QOS_DEFAULT; } // namespace dds } // namespace fastdds diff --git a/include/fastdds/dds/xtypes/common.hpp b/include/fastdds/dds/xtypes/common.hpp new file mode 100644 index 00000000000..3a2032fb38b --- /dev/null +++ b/include/fastdds/dds/xtypes/common.hpp @@ -0,0 +1,114 @@ +// Copyright 2023 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file common.hpp + * This file contains common definitions for the different XTypes modules. + */ + +#ifndef _FASTDDS_DDS_XTYPES_COMMON_HPP_ +#define _FASTDDS_DDS_XTYPES_COMMON_HPP_ + +#include + +namespace eprosima { +namespace fastdds { +namespace dds { +namespace xtypes { + +enum class ExtensibilityKind : uint32_t +{ + NOT_APPLIED, + FINAL, + APPENDABLE, + MUTABLE +}; + +enum class TryConstructKind : uint32_t +{ + NOT_APPLIED, + USE_DEFAULT, + DISCARD, + TRIM +}; + +/*! + * @brief PlacementKind values (verbatim annotation) + */ +enum class PlacementKind : uint32_t +{ + BEGIN_FILE, + BEFORE_DECLARATION, + BEGIN_DECLARATION, + END_DECLARATION, + AFTER_DECLARATION, + END_FILE +}; + +// Primitive type names +constexpr const char* boolean_type_name = "_bool"; +constexpr const char* byte_type_name = "_byte"; +constexpr const char* int16_type_name = "_int16_t"; +constexpr const char* int32_type_name = "_int32_t"; +constexpr const char* int64_type_name = "_int64_t"; +constexpr const char* uint16_type_name = "_uint16_t"; +constexpr const char* uint32_type_name = "_uint32_t"; +constexpr const char* uint64_type_name = "_uint64_t"; +constexpr const char* float32_type_name = "_float"; +constexpr const char* float64_type_name = "_double"; +constexpr const char* float128_type_name = "_longdouble"; +constexpr const char* int8_type_name = "_int8_t"; +constexpr const char* uint8_type_name = "_uint8_t"; +constexpr const char* char8_type_name = "_char"; +constexpr const char* char16_type_name = "_wchar_t"; + +// Builtin annotation names +constexpr const char* id_annotation_name = "id"; +constexpr const char* autoid_annotation_name = "autoid"; +constexpr const char* optional_annotation_name = "optional"; +constexpr const char* position_annotation_name = "position"; +constexpr const char* value_annotation_name = "value"; // Pending implementation +constexpr const char* extensibility_annotation_name = "extensibility"; +constexpr const char* final_annotation_name = "final"; +constexpr const char* appendable_annotation_name = "appendable"; +constexpr const char* mutable_annotation_name = "mutable"; +constexpr const char* key_annotation_name = "key"; +constexpr const char* must_understand_annotation_name = "must_understand"; +constexpr const char* default_literal_annotation_name = "default_literal"; +constexpr const char* default_annotation_name = "default"; // Pending implementation +constexpr const char* range_annotation_name = "range"; // Pending implementation +constexpr const char* min_annotation_name = "min"; // Pending implementation +constexpr const char* max_annotation_name = "max"; // Pending implementation +constexpr const char* unit_annotation_name = "unit"; +constexpr const char* bit_bound_annotation_name = "bit_bound"; +constexpr const char* external_annotation_name = "external"; +constexpr const char* nested_annotation_name = "nested"; +constexpr const char* verbatim_annotation_name = "verbatim"; +constexpr const char* service_annotation_name = "service"; +constexpr const char* oneway_annotation_name = "oneway"; +constexpr const char* ami_annotation_name = "ami"; +constexpr const char* hashid_annotation_name = "hashid"; +constexpr const char* default_nested_annotation_name = "default_nested"; +constexpr const char* ignore_literal_names_annotation_name = "ignore_literal_names"; +constexpr const char* try_construct_annotation_name = "try_construct"; +constexpr const char* non_serialized_annotation_name = "non_serialized"; +constexpr const char* data_representation_annotation_name = "data_representation"; +constexpr const char* topic_annotation_name = "topic"; + +} // xtypes +} // dds +} // fastdds +} // eprosima + +#endif // _FASTDDS_DDS_XTYPES_COMMON_HPP_ diff --git a/include/fastdds/dds/xtypes/dynamic_types/AnnotationDescriptor.hpp b/include/fastdds/dds/xtypes/dynamic_types/AnnotationDescriptor.hpp new file mode 100644 index 00000000000..781bed34cf9 --- /dev/null +++ b/include/fastdds/dds/xtypes/dynamic_types/AnnotationDescriptor.hpp @@ -0,0 +1,131 @@ +// Copyright 2023 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +#ifndef FASTDDS_DDS_XTYPES_DYNAMIC_TYPES_ANNOTATION_DESCRIPTOR_HPP +#define FASTDDS_DDS_XTYPES_DYNAMIC_TYPES_ANNOTATION_DESCRIPTOR_HPP + +#include +#include +#include + +namespace eprosima { +namespace fastdds { +namespace dds { + +class DynamicType; + +class FASTDDS_EXPORTED_API AnnotationDescriptor +{ +public: + + using _ref_type = typename traits::ref_type; + + /*! + * Returns a reference to the type. The reference can be nil. + * @return @ref DynamicType reference. + */ + virtual traits::ref_type type() const = 0; + + /*! + * Returns a reference to the type. The reference can be nil. + * @return @ref DynamicType reference. + */ + virtual traits::ref_type& type() = 0; + + /*! + * Modifies the underlying type reference. + * @param[in] type @ref DynamicType reference. + */ + virtual void type( + traits::ref_type type) = 0; + + /** + * Getter given a key for the @b value property. + * @param[inout] value The value. + * @param[in] key Key used to retrieve the value. + * @return @ref ReturnCode_t returns operation success + */ + virtual ReturnCode_t get_value( + ObjectName& value, + const ObjectName& key) = 0; + + /** + * Getter for all the values. + * @param[inout] value @ref Parameters interface to the strings map. + * @return @ref ReturnCode_t returns operation success. + */ + virtual ReturnCode_t get_all_value( + Parameters& value) = 0; + + /** + * Setter given a key for the @b value property. + * @param[in] key null terminated string + * @param[in] value null terminated string + * @return @ref ReturnCode_t returns operation success + */ + virtual ReturnCode_t set_value( + const ObjectName& key, + const ObjectName& value) = 0; + + /** + * Overwrites the contents of this descriptor with those of another descriptor (see [standard] 7.5.2.3.1) + * @param[in] descriptor object + * @return standard @ref ReturnCode_t + * @retval RETCODE_OK when the copy was successful. + * @retval RETCODE_BAD_PARAMETER when descriptor reference is nil. + */ + virtual ReturnCode_t copy_from( + traits::ref_type descriptor) = 0; + + /** + * State comparison according with the [standard] sections \b 7.5.2.3.2 + * @param[in] descriptor reference. + * @return \b bool `true` on equality + */ + virtual bool equals( + traits::ref_type descriptor) = 0; + + /*! + * Indicates whether the states of all of this descriptor's properties are consistent according with the [standard] + * section \b 7.5.2.3.3. + * @return \b bool `true` if consistent. + */ + virtual bool is_consistent() = 0; + +protected: + + AnnotationDescriptor() = default; + + AnnotationDescriptor( + const AnnotationDescriptor&) = default; + + AnnotationDescriptor( + AnnotationDescriptor&&) = default; + + virtual ~AnnotationDescriptor() = default; + +private: + + AnnotationDescriptor& operator =( + const AnnotationDescriptor&) = delete; + + AnnotationDescriptor& operator =( + AnnotationDescriptor&&) = delete; +}; + +} // namespace dds +} // namespace fastdds +} // namespace eprosima + +#endif // FASTDDS_DDS_XTYPES_DYNAMIC_TYPES_ANNOTATION_DESCRIPTOR_HPP diff --git a/include/fastdds/dds/xtypes/dynamic_types/DynamicData.hpp b/include/fastdds/dds/xtypes/dynamic_types/DynamicData.hpp new file mode 100644 index 00000000000..d1c29039eb3 --- /dev/null +++ b/include/fastdds/dds/xtypes/dynamic_types/DynamicData.hpp @@ -0,0 +1,1042 @@ +// Copyright 2023 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +#ifndef FASTDDS_DDS_XTYPES_DYNAMIC_TYPES_DYNAMIC_DATA_HPP +#define FASTDDS_DDS_XTYPES_DYNAMIC_TYPES_DYNAMIC_DATA_HPP + +#include +#include + +#include +#include +#include +#include +#include + +namespace eprosima { +namespace fastdds { +namespace dds { + +class DynamicData : public std::enable_shared_from_this +{ +public: + + using _ref_type = typename traits::ref_type; + + /*! + * Retrieve the @ref DynamicType reference associated to this @ref DynamicData + * @return Non-nil @ref DynamicType reference + */ + FASTDDS_EXPORTED_API virtual traits::ref_type type() = 0; + + /*! + * Retrieves the @ref MemberDescriptor associated to a member. + * @param[inout] value Non-nil @ref MemberDescriptor reference where the information is copied. + * @param[in] id Identifier of the member to be retrieved. + * @retval RETCODE_OK when the copy was successful. + * @retval RETCODE_BAD_PARAMETER when descriptor reference is nil or member identifier is not found. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_descriptor( + traits::ref_type& value, + MemberId id) = 0; + + /*! + * Compares two @ref DynamicData, equality requires: + * - Their respective type definitions are equal + * - All contained values are equal and occur in the same order + * - If the samples' type is an aggregated type, previous rule shall be amended as follows: + * -# Members shall be compared without regard to their order. + * @param [in] other @ref DynamicData reference to compare to + * @return `true` on equality + */ + FASTDDS_EXPORTED_API virtual bool equals( + traits::ref_type other) = 0; + + /*! + * Queries @ref MemberId by name. + * The query result depends on the type of the sample. + * Only next types support accessing by name. + * @li Aggregated type. + * @li Map type. + * @li Bitmask type. + * @param[in] name string + * @return MemberId or MEMBER_ID_INVALID on failure + */ + FASTDDS_EXPORTED_API virtual MemberId get_member_id_by_name( + const ObjectName& name) = 0; + + /*! + * Queries @ref MemberId by index + * The query result depends on the type of the sample. + * Only next types support accessing by index. + * @li Aggregated type. + * @li Sequence type. + * @li String type. + * @li Map type. + * @li Array type. + * @li Bitmask type. + * @param[in] index Index. + * @return MemberId or MEMBER_ID_INVALID on failure + */ + FASTDDS_EXPORTED_API virtual MemberId get_member_id_at_index( + uint32_t index) = 0; + + /*! + * Provides the @b item @b count of the data and depends on the type of object: + * @li If the object is of a collection type, returns the number of elements currently in the collection. + * In the case of an array type, this value will always be equal to the product of the bounds of all array + * dimensions. + * @li If the object is of a bitmask type, return the number of named flags that are currently set in the bitmask. + * @li If the object is of a structure or annotation type, return the number of members in the object. + * This value may be different than the number of members in the corresponding @ref DynamicType. + * @li If the object is of a union type, return the number of members in the object. This number will be two if the + * discriminator value selects a member and one otherwise. + * @li if the object is of a primitive or enumerated type, it is atomic: return one. + * @li if the object is of an alias type, return the value appropriate for the alias base type. + * @return count as defined above + */ + FASTDDS_EXPORTED_API virtual uint32_t get_item_count() = 0; + + /*! + * Clear all members associated to the object. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the cleaning was successful. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t clear_all_values() = 0; + + /*! + * Clear all members not associated to the key + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the cleaning was successful. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t clear_nonkey_values() = 0; + + /*! + * Clear a member. + * The meaning of "clearing" depends on the type of the sample: + * @li If aggregated type, set it to its default value. + * @li If variable-length collection type, remove the indicated element, shifting any subsequence elements to the + * next-lowest index. + * @li If array type, set the indicated element to its default value. + * @li If bitmask type, clear the indicated bit. + * @li If enumerated type, set it to the first value of the enumerated type. + * @li If primitive type, set it to its default value. + * @param[in] id Identifier of the member to purge + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the cleaning was successful. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t clear_value( + MemberId id) = 0; + + /*! + * \b Loans a @ref DynamicData reference within the sample + * @remarks This loan shall be returned by the @ref DynamicData::return_loaned_value operation + * @param[in] id identifier of the object to retrieve + * @return @ref DynamicData reference loaned or \b nil on outstanding loaned data + */ + FASTDDS_EXPORTED_API virtual traits::ref_type loan_value( + MemberId id) = 0; + + /*! + * Returns a loan retrieved using @ref DynamicData::loan_value. + * @param[in] value @ref DynamicData reference previously loaned + * @retval RETCODE_OK when the loan was returned successfully. + * @retval RETCODE_PRECONDITION_NOT_MET when the loan is invalid. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t return_loaned_value( + traits::ref_type value) = 0; + + /*! + * Creates and returns a new data sample with the same contents as this one. + * A comparison of this object and the clone using equals immediately following this call will return `true`. + * @return @ref DynamicData reference + */ + FASTDDS_EXPORTED_API virtual traits::ref_type clone() = 0; + + /*! + * Retrieves an \b int32 value associated to an identifier. + * @param[inout] value \b int32 to populate + * @param[in] id identifier of the member to query. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was retrieved successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to \b int32. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_int32_value( + int32_t& value, + MemberId id) = 0; + + /*! + * Sets an \b int32 value associated to an identifier. + * @param[in] id Identifier of the member to set. + * @param[in] value \b int32 to set + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was set successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to \b int32. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t set_int32_value( + MemberId id, + int32_t value) = 0; + + /*! + * Retrieves an \b uint32 value associated to an identifier. + * @param[inout] value \b uint32 to populate + * @param[in] id Identifier of the member to query. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was retrieved successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to \b uint32. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_uint32_value( + uint32_t& value, + MemberId id) = 0; + + /*! + * Sets an \b uint32 value associated to an identifier. + * @param[in] id Identifier of the member to set. + * @param[in] value \b uint32 to set. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was set successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to \b uint32. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t set_uint32_value( + MemberId id, + uint32_t value) = 0; + + /*! + * Retrieves an \b int8 value associated to an identifier. + * @param[inout] value \b int8 to populate. + * @param[in] id Identifier of the member to query. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was retrieved successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to \b int8. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_int8_value( + int8_t& value, + MemberId id) = 0; + + /*! + * Sets an \b int8 value associated to an identifier. + * @param[in] id Identifier of the member to set. + * @param[in] value \b int8 to set. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was set successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to \b int8. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t set_int8_value( + MemberId id, + int8_t value) = 0; + + /*! + * Retrieves an \b uint8 value associated to an identifier. + * @param[inout] value \b uint8 to populate. + * @param[in] id Identifier of the member to query. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was retrieved successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to \b uint8. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_uint8_value( + uint8_t& value, + MemberId id) = 0; + + /*! + * Sets an \b uint8 value associated to an identifier. + * @param[in] id Identifier of the member to set. + * @param[in] value \b uint8 to set. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was set successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to \b uint8. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t set_uint8_value( + MemberId id, + uint8_t value) = 0; + + /*! + * Retrieves an \b int16 value associated to an identifier. + * @param[inout] value \b int16 to populate. + * @param [in] id Identifier of the member to query. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was retrieved successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to \b int16. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_int16_value( + int16_t& value, + MemberId id) = 0; + + /*! + * Sets an \b int16 value associated to an identifier. + * @param[in] id Identifier of the member to set. + * @param[in] value \b int16 to set. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was set successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to \b int16. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t set_int16_value( + MemberId id, + int16_t value) = 0; + + /*! + * Retrieves an \b uint16 value associated to an identifier. + * @param[inout] value \b uint16 to populate. + * @param[in] id Identifier of the member to query. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was retrieved successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to \b uint16. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_uint16_value( + uint16_t& value, + MemberId id) = 0; + + /*! + * Sets an \b uint16 value associated to an identifier. + * @param[in] id Identifier of the member to set. + * @param[in] value \b uint16 to set. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was set successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to \b uint16. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t set_uint16_value( + MemberId id, + uint16_t value) = 0; + + /*! + * Retrieves an \b int64 value associated to an identifier. + * @param[inout] value \b int64 to populate. + * @param[in] id Identifier of the member to query. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was retrieved successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to \b int64. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_int64_value( + int64_t& value, + MemberId id) = 0; + + /*! + * Sets an \b int64 value associated to an identifier. + * @param[in] id Identifier of the member to set. + * @param[in] value \b int64 to set. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was set successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to \b int64. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t set_int64_value( + MemberId id, + int64_t value) = 0; + + /*! + * Retrieves an \b uint64 value associated to an identifier. + * @param[inout] value \b uint64 to populate. + * @param[in] id Identifier of the member to query. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was retrieved successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to \b uint64. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_uint64_value( + uint64_t& value, + MemberId id) = 0; + + /*! + * Sets an \b uint64 value associated to an identifier. + * @param[in] id Identifier of the member to set. + * @param[in] value \b uint64 to set. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was set successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to \b uint64. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t set_uint64_value( + MemberId id, + uint64_t value) = 0; + + /*! + * Retrieves an \b float32 value associated to an identifier. + * @param[inout] value \b float32 to populate. + * @param[in] id Identifier of the member to query. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was retrieved successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to \b float32. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_float32_value( + float& value, + MemberId id) = 0; + + /*! + * Sets an \b float32 value associated to an identifier. + * @param[in] id Identifier of the member to set. + * @param[in] value \b float32 to set. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was set successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to \b float32. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t set_float32_value( + MemberId id, + float value) = 0; + + /*! + * Retrieves an \b float64 value associated to an identifier. + * @param[inout] value \b float64 to populate. + * @param[in] id Identifier of the member to query. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was retrieved successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to \b float64. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_float64_value( + double& value, + MemberId id) = 0; + + /*! + * Sets an \b float64 value associated to an identifier. + * @param[in] id Identifier of the member to set. + * @param[in] value \b float64 to set. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was set successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to \b float64. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t set_float64_value( + MemberId id, + double value) = 0; + + /*! + * Retrieves an \b float128 value associated to an identifier. + * @param[inout] value \b float128 to populate. + * @param[in] id Identifier of the member to query. + * @remarks Only available on platforms supporting long double + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was retrieved successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to \b float128. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_float128_value( + long double& value, + MemberId id) = 0; + + /*! + * Sets an \b float128 value associated to an identifier. + * @param[in] id Identifier of the member to set. + * @param[in] value \b float128 to set. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was set successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to \b float128. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t set_float128_value( + MemberId id, + long double value) = 0; + + /*! + * Retrieves an \b char8 value associated to an identifier. + * @param[inout] value \b char8 to populate. + * @param[in] id Identifier of the member to query. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was retrieved successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to \b char8. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_char8_value( + char& value, + MemberId id) = 0; + + /*! + * Sets an \b char8 value associated to an identifier + * @param[in] id Identifier of the member to set. + * @param[in] value \b char8 to set. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was set successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to \b char8. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t set_char8_value( + MemberId id, + char value) = 0; + + /*! + * Retrieves an \b char16 value associated to an identifier. + * @param[inout] value \b char16 to populate. + * @param[in] id Identifier of the member to query. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was retrieved successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to \b char16. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_char16_value( + wchar_t& value, + MemberId id) = 0; + + /*! + * Sets an \b char16 value associated to an identifier. + * @param[in] id Identifier of the member to set. + * @param[in] value \b char16 to set. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was set successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to \b char16. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t set_char16_value( + MemberId id, + wchar_t value) = 0; + + /*! + * Retrieves an \b byte value associated to an identifier. + * @param[inout] value \b byte to populate. + * @param[in] id Identifier of the member to query. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was retrieved successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to \b byte. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_byte_value( + eprosima::fastrtps::rtps::octet& value, + MemberId id) = 0; + + /*! + * Sets an \b byte value associated to an identifier. + * @param[in] id Identifier of the member to set. + * @param[in] value \b byte to set. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was set successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to \b byte. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t set_byte_value( + MemberId id, + eprosima::fastrtps::rtps::octet value) = 0; + + /*! + * Retrieves an \b bool value associated to an identifier. + * @param[in] id Identifier of the member to query. + * @param[inout] value \b bool to populate. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was retrieved successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to \b bool. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_boolean_value( + bool& value, + MemberId id) = 0; + + /*! + * Sets an \b bool value associated to an identifier + * @param[in] id identifier of the member to set. + * @param[in] value \b bool to set. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was set successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to \b bool. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t set_boolean_value( + MemberId id, + bool value) = 0; + + /*! + * Retrieves an \b string value associated to an identifier. + * @param[inout] value \b string to populate. + * @param[in] id Identifier of the member to query. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was retrieved successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to \b string. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_string_value( + std::string& value, + MemberId id) = 0; + + /*! + * Sets an \b string value associated to an identifier. + * @param[in] id Identifier of the member to set. + * @param[in] value \b string to set. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was set successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to \b string + * or the string length is greater than the string bound. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t set_string_value( + MemberId id, + const std::string& value) = 0; + + /*! + * Retrieves an \b wstring value associated to an identifier. + * @param[inout] value \b wstring to populate. + * @param[in] id Identifier of the member to query. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was retrieved successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to \b wstring. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_wstring_value( + std::wstring& value, + MemberId id) = 0; + + /*! + * Sets an \b wstring value associated to an identifier. + * @param[in] id Identifier of the member to set. + * @param[in] value \b wstring to set. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was set successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to \b wstring + * or the string length is greater than the string bound. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t set_wstring_value( + MemberId id, + const std::wstring& value) = 0; + + /*! + * Retrieves a \b complex value associated to an identifier. + * @param[inout] value @ref DynamicData reference to populate + * @param[in] id Identifier of the member to query. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was retrieved successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to \b complex. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_complex_value( + traits::ref_type& value, + MemberId id) = 0; + + /*! + * Sets a \b complex value associated to an identifier. + * @param[in] id Identifier of the member to set. + * @param[in] value @ref DynamicData reference to set + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was set successfully. + * @retval RETCODE_BAD_PARAMETER when the value reference is nil or @ref MemberId is invalid or the member type is + * not promotable to \b complex. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t set_complex_value( + MemberId id, + traits::ref_type value) = 0; + + /*! + * Retrieves a sequence of \b int32 values associated to an identifier. + * @param[inout] value \b Sequence of \b int32 to populate. + * @param[in] id Identifier of the member to query. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was retrieved successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to sequence of \b int32. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_int32_values( + Int32Seq& value, + MemberId id) = 0; + + /*! + * Sets a sequence of \b int32 values associated to an identifier. + * @param[in] id Identifier of the member to set. + * @param[in] value Sequence of \b int32 to set + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was set successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to sequence of \b int32. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t set_int32_values( + MemberId id, + const Int32Seq& value) = 0; + + /*! + * Retrieves a sequence of \b uint32 values associated to an identifier. + * @param[inout] value \b Sequence of \b uint32 to populate. + * @param[in] id Identifier of the member to query. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was retrieved successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to sequence of \b uint32. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_uint32_values( + UInt32Seq& value, + MemberId id) = 0; + + /*! + * Sets a sequence of \b uint32 values associated to an identifier. + * @param[in] id Identifier of the member to set. + * @param[in] value Sequence of \b uint32 to set + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was set successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to sequence of \b uint32. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t set_uint32_values( + MemberId id, + const UInt32Seq& value) = 0; + + /*! + * Retrieves a sequence of \b int8 values associated to an identifier. + * @param[inout] value \b Sequence of \b int8 to populate. + * @param[in] id Identifier of the member to query. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was retrieved successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to sequence of \b int8. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_int8_values( + Int8Seq& value, + MemberId id) = 0; + + /*! + * Sets a sequence of \b int8 values associated to an identifier. + * @param[in] id Identifier of the member to set. + * @param[in] value Sequence of \b int8 to set + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was set successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to sequence of \b int8. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t set_int8_values( + MemberId id, + const Int8Seq& value) = 0; + + /*! + * Retrieves a sequence of \b uint8 values associated to an identifier. + * @param[inout] value \b Sequence of \b uint8 to populate. + * @param[in] id Identifier of the member to query. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was retrieved successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to sequence of \b uint8. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_uint8_values( + UInt8Seq& value, + MemberId id) = 0; + + /*! + * Sets a sequence of \b uint8 values associated to an identifier. + * @param[in] id Identifier of the member to set. + * @param[in] value Sequence of \b uint8 to set + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was set successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to sequence of \b uint8. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t set_uint8_values( + MemberId id, + const UInt8Seq& value) = 0; + + /*! + * Retrieves a sequence of \b int16 values associated to an identifier. + * @param[inout] value \b Sequence of \b int16 to populate. + * @param[in] id Identifier of the member to query. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was retrieved successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to sequence of \b int16. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_int16_values( + Int16Seq& value, + MemberId id) = 0; + + /*! + * Sets a sequence of \b int16 values associated to an identifier. + * @param[in] id Identifier of the member to set. + * @param[in] value Sequence of \b int16 to set + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was set successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to sequence of \b int16. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t set_int16_values( + MemberId id, + const Int16Seq& value) = 0; + + /*! + * Retrieves a sequence of \b uint16 values associated to an identifier. + * @param[inout] value \b Sequence of \b uint16 to populate. + * @param[in] id Identifier of the member to query. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was retrieved successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to sequence of \b uint16. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_uint16_values( + UInt16Seq& value, + MemberId id) = 0; + + /*! + * Sets a sequence of \b uint16 values associated to an identifier. + * @param[in] id Identifier of the member to set. + * @param[in] value Sequence of \b uint16 to set + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was set successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to sequence of \b uint16. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t set_uint16_values( + MemberId id, + const UInt16Seq& value) = 0; + + /*! + * Retrieves a sequence of \b int64 values associated to an identifier. + * @param[inout] value \b Sequence of \b int64 to populate. + * @param[in] id Identifier of the member to query. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was retrieved successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to sequence of \b int64. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_int64_values( + Int64Seq& value, + MemberId id) = 0; + + /*! + * Sets a sequence of \b int64 values associated to an identifier. + * @param[in] id Identifier of the member to set. + * @param[in] value Sequence of \b int64 to set + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was set successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to sequence of \b int64. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t set_int64_values( + MemberId id, + const Int64Seq& value) = 0; + + /*! + * Retrieves a sequence of \b uint64 values associated to an identifier. + * @param[inout] value \b Sequence of \b uint64 to populate. + * @param[in] id Identifier of the member to query. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was retrieved successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to sequence of \b uint64. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_uint64_values( + UInt64Seq& value, + MemberId id) = 0; + + /*! + * Sets a sequence of \b uint64 values associated to an identifier. + * @param[in] id Identifier of the member to set. + * @param[in] value Sequence of \b uint64 to set + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was set successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to sequence of \b uint64. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t set_uint64_values( + MemberId id, + const UInt64Seq& value) = 0; + + /*! + * Retrieves a sequence of \b float32 values associated to an identifier. + * @param[inout] value \b Sequence of \b float32 to populate. + * @param[in] id Identifier of the member to query. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was retrieved successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to sequence of \b float32. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_float32_values( + Float32Seq& value, + MemberId id) = 0; + + /*! + * Sets a sequence of \b float32 values associated to an identifier. + * @param[in] id Identifier of the member to set. + * @param[in] value Sequence of \b float32 to set + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was set successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to sequence of \b float32. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t set_float32_values( + MemberId id, + const Float32Seq& value) = 0; + + /*! + * Retrieves a sequence of \b float64 values associated to an identifier. + * @param[inout] value \b Sequence of \b float64 to populate. + * @param[in] id Identifier of the member to query. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was retrieved successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to sequence of \b float64. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_float64_values( + Float64Seq& value, + MemberId id) = 0; + + /*! + * Sets a sequence of \b float64 values associated to an identifier. + * @param[in] id Identifier of the member to set. + * @param[in] value Sequence of \b float64 to set + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was set successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to sequence of \b float64. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t set_float64_values( + MemberId id, + const Float64Seq& value) = 0; + + /*! + * Retrieves a sequence of \b float128 values associated to an identifier. + * @param[inout] value \b Sequence of \b float128 to populate. + * @param[in] id Identifier of the member to query. + * @remarks Only available on platforms supporting long double + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was retrieved successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to sequence of \b + * float128. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_float128_values( + Float128Seq& value, + MemberId id) = 0; + + /*! + * Sets a sequence of \b float128 values associated to an identifier. + * @param[in] id Identifier of the member to set. + * @param[in] value Sequence of \b float128 to set + * @remarks Only available on platforms supporting long double + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was set successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to sequence of \b float128. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t set_float128_values( + MemberId id, + const Float128Seq& value) = 0; + + /*! + * Retrieves a sequence of \b char8 values associated to an identifier. + * @param[inout] value \b Sequence of \b char8 to populate. + * @param[in] id Identifier of the member to query. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was retrieved successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to sequence of \b char8. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_char8_values( + CharSeq& value, + MemberId id) = 0; + + /*! + * Sets a sequence of \b char8 values associated to an identifier. + * @param[in] id Identifier of the member to set. + * @param[in] value Sequence of \b char8 to set + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was set successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to sequence of \b char8. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t set_char8_values( + MemberId id, + const CharSeq& value) = 0; + + /*! + * Retrieves a sequence of \b char16 values associated to an identifier. + * @param[inout] value \b Sequence of \b char16 to populate. + * @param[in] id Identifier of the member to query. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was retrieved successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to sequence of \b char16. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_char16_values( + WcharSeq& value, + MemberId id) = 0; + + /*! + * Sets a sequence of \b char16 values associated to an identifier. + * @param[in] id Identifier of the member to set. + * @param[in] value Sequence of \b char16 to set + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was set successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to sequence of \b char16. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t set_char16_values( + MemberId id, + const WcharSeq& value) = 0; + + /*! + * Retrieves a sequence of \b byte values associated to an identifier. + * @param[inout] value \b Sequence of \b byte to populate. + * @param[in] id Identifier of the member to query. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was retrieved successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to sequence of \b byte. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_byte_values( + ByteSeq& value, + MemberId id) = 0; + + /*! + * Sets a sequence of \b byte values associated to an identifier. + * @param[in] id Identifier of the member to set. + * @param[in] value Sequence of \b byte to set + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was set successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to sequence of \b byte. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t set_byte_values( + MemberId id, + const ByteSeq& value) = 0; + + /*! + * Retrieves a sequence of \b bool values associated to an identifier. + * @param[inout] value \b Sequence of \b bool to populate. + * @param[in] id Identifier of the member to query. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was retrieved successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to sequence of \b bool. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_boolean_values( + BooleanSeq& value, + MemberId id) = 0; + + /*! + * Sets a sequence of \b bool values associated to an identifier. + * @param[in] id Identifier of the member to set. + * @param[in] value Sequence of \b bool to set + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was set successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to sequence of \b bool. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t set_boolean_values( + MemberId id, + const BooleanSeq& value) = 0; + + /*! + * Retrieves a sequence of \b string values associated to an identifier. + * @param[inout] value \b Sequence of \b string to populate. + * @param[in] id Identifier of the member to query. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was retrieved successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to sequence of \b string. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_string_values( + StringSeq& value, + MemberId id) = 0; + + /*! + * Sets a sequence of \b string values associated to an identifier. + * @param[in] id Identifier of the member to set. + * @param[in] value Sequence of \b string to set + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was set successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to sequence of \b string. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t set_string_values( + MemberId id, + const StringSeq& value) = 0; + + /*! + * Retrieves a sequence of \b wstring values associated to an identifier. + * @param[inout] value \b Sequence of \b wstring to populate. + * @param[in] id Identifier of the member to query. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was retrieved successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to sequence of \b wstring. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_wstring_values( + WstringSeq& value, + MemberId id) = 0; + + /*! + * Sets a sequence of \b wstring values associated to an identifier. + * @param[in] id Identifier of the member to set. + * @param[in] value Sequence of \b wstring to set + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the value was set successfully. + * @retval RETCODE_BAD_PARAMETER when the @ref MemberId is invalid or the member type is not promotable to sequence of \b wstring. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t set_wstring_values( + MemberId id, + const WstringSeq& value) = 0; + +protected: + + DynamicData() = default; + + virtual ~DynamicData() = default; + + traits::ref_type _this(); + +private: + + DynamicData( + const DynamicData&) = delete; + + DynamicData( + DynamicData&&) = delete; + + DynamicData& operator =( + const DynamicData&) = delete; + + DynamicData& operator =( + DynamicData&&) = delete; +}; + +} // namespace dds +} // namespace fastdds +} // namespace eprosima + +#endif // FASTDDS_DDS_XTYPES_DYNAMIC_TYPES_DYNAMIC_DATA_HPP diff --git a/include/fastdds/dds/xtypes/dynamic_types/DynamicDataFactory.hpp b/include/fastdds/dds/xtypes/dynamic_types/DynamicDataFactory.hpp new file mode 100644 index 00000000000..688363347e8 --- /dev/null +++ b/include/fastdds/dds/xtypes/dynamic_types/DynamicDataFactory.hpp @@ -0,0 +1,78 @@ +// Copyright 2023 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +#ifndef FASTDDS_DDS_XTYPES_DYNAMIC_TYPES_DYNAMIC_DATA_FACTORY_HPP +#define FASTDDS_DDS_XTYPES_DYNAMIC_TYPES_DYNAMIC_DATA_FACTORY_HPP + +#include + +#include +#include +#include + +namespace eprosima { +namespace fastdds { +namespace dds { + +class DynamicDataFactory : public std::enable_shared_from_this +{ +public: + + using _ref_type = typename traits::ref_type; + + /*! + * Returns the singleton factory object + * @remark This method is non thread-safe. + * @return @ref DynamicDataFactory reference. + */ + FASTDDS_EXPORTED_API static traits::ref_type get_instance(); + + /*! + * Resets the singleton reference. + * @return @ref ReturnCode_t + * @retval RETCODE_BAD_PARAMETER if singleton reference is currently nil. + * @retval RETCODE_OK otherwise. + */ + FASTDDS_EXPORTED_API static ReturnCode_t delete_instance(); + + /** + * Creates a new @ref DynamicData reference based on the given @ref DynamicType reference. + * All objects returned by this operation should eventually be deleted by calling delete_data. + * @param[in] type @ref DynamicType reference associated. + * @return new @ref DynamicData reference + */ + FASTDDS_EXPORTED_API virtual traits::ref_type create_data( + traits::ref_type type) = 0; + + /** + * Resets the internal reference if it is cached. + * @param[in] data @ref DynamicData reference whose internal cached reference to reset. + * @return standard ReturnCode_t + * @retval RETCODE_BAD_PARAMETER if reference is nil. + * @retval RETCODE_OK is otherwise returned. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t delete_data( + traits::ref_type& data) = 0; + +protected: + + virtual ~DynamicDataFactory() = default; + +}; + +} // namespace dds +} // namespace fastdds +} // namespace eprosima + +#endif // FASTDDS_DDS_XTYPES_DYNAMIC_TYPES_DYNAMIC_DATA_FACTORY_HPP diff --git a/include/fastdds/dds/xtypes/dynamic_types/DynamicPubSubType.hpp b/include/fastdds/dds/xtypes/dynamic_types/DynamicPubSubType.hpp new file mode 100644 index 00000000000..2b76b316162 --- /dev/null +++ b/include/fastdds/dds/xtypes/dynamic_types/DynamicPubSubType.hpp @@ -0,0 +1,154 @@ +// Copyright 2023 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +#ifndef FASTDDS_DDS_XTYPES_DYNAMIC_TYPES_DYNAMIC_PUB_SUB_TYPE_HPP +#define FASTDDS_DDS_XTYPES_DYNAMIC_TYPES_DYNAMIC_PUB_SUB_TYPE_HPP + +#include +#include +#include +#include + +namespace eprosima { +namespace fastdds { +namespace dds { + +class DynamicType; +class DynamicData; + +class DynamicPubSubType : public virtual eprosima::fastdds::dds::TopicDataType +{ + traits::ref_type dynamic_type_; + + unsigned char* key_buffer_ {nullptr}; + + MD5 md5_; + +public: + + //{{{ Public functions + + FASTDDS_EXPORTED_API DynamicPubSubType() = default; + + /* + * Constructs a @ref DynamicPubSubType from a @ref DynamicType + * @param type @ref DynamicType object associated to the data + * @remark Ownership is not transferred. + */ + FASTDDS_EXPORTED_API DynamicPubSubType( + traits::ref_type type); + + FASTDDS_EXPORTED_API virtual ~DynamicPubSubType(); + + /* + * Create a new data object of the specified type + * @return pointer to the new object + * @remark Ownership is transferred. This object must be removed using @ref deleteData + */ + FASTDDS_EXPORTED_API void* createData() override; + + /* + * Deletes an object previously allocated via @ref createData + * @param data pointer to the object to be deleted + * @remark Ownership is transferred. This object must be allocated using @ref createData + */ + FASTDDS_EXPORTED_API void deleteData ( + void* data) override; + + /* + * Deserialize an object from the given payload + * @param payload @ref eprosima::fastrtps::rtps::SerializedPayload_t to parse + * @param data object to fill in with payload data + * @return bool specifying success + */ + FASTDDS_EXPORTED_API bool deserialize ( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + /* + * Returns a copy of the internal @ref DynamicType object + * @return pointer to the new object + */ + FASTDDS_EXPORTED_API traits::ref_type get_dynamic_type() const noexcept; + + /* + * Calculate the key associated to a given object + * @param data object whose key is calculated + * @param ihandle @ref eprosima::fastrtps::rtps::InstanceHandle_t to fill in + * @param force_md5 use always md5 even if key payload footprint is smaller than the hash + * @return bool specifying success + */ + FASTDDS_EXPORTED_API bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + /* + * Provide a functor that calculates a specified object serialized size + * @param data object whose payload footprint to calculate + * @return functor that calculates the size + */ + // FASTDDS_TODO_BEFORE(3, 0, "Remove this overload") + FASTDDS_EXPORTED_API std::function getSerializedSizeProvider( + void* data) override; + + FASTDDS_EXPORTED_API std::function getSerializedSizeProvider( + void* data, + DataRepresentationId_t data_representation) override; + + /* + * Serialize an object into a given payload + * @param data object to serialize + * @param payload @ref eprosima::fastrtps::rtps::SerializedPayload_t to fill in + * @return bool specifying success + */ + FASTDDS_EXPORTED_API bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + /* + * Serialize an object into a given payload + * @param data object to serialize + * @param payload @ref eprosima::fastrtps::rtps::SerializedPayload_t to fill in + * @return bool specifying success + */ + FASTDDS_EXPORTED_API bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + fastdds::dds::DataRepresentationId_t data_representation) override; + + /* + * Sets up the internal @ref DynamicType object + * @param @ref DynamicType to copy + * @return @ref ReturnCode_t with operation status + * @remark Ownership is not transferred. + */ + FASTDDS_EXPORTED_API ReturnCode_t set_dynamic_type( + traits::ref_type type); + + //}}} + +private: + + void update_dynamic_type(); +}; + +} // namespace dds +} // namespace fastdds +} // namespace eprosima + +#endif // FASTDDS_DDS_XTYPES_DYNAMIC_TYPES_DYNAMIC_PUB_SUB_TYPE_HPP diff --git a/include/fastdds/dds/xtypes/dynamic_types/DynamicType.hpp b/include/fastdds/dds/xtypes/dynamic_types/DynamicType.hpp new file mode 100644 index 00000000000..f9082159f40 --- /dev/null +++ b/include/fastdds/dds/xtypes/dynamic_types/DynamicType.hpp @@ -0,0 +1,191 @@ +// Copyright 2023 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +#ifndef FASTDDS_DDS_XTYPES_DYNAMIC_TYPES_DYNAMIC_TYPE_HPP +#define FASTDDS_DDS_XTYPES_DYNAMIC_TYPES_DYNAMIC_TYPE_HPP + +#include + +#include +#include +#include +#include +#include +#include +#include + +namespace eprosima { +namespace fastdds { +namespace dds { + +class DynamicType : public std::enable_shared_from_this +{ +public: + + using _ref_type = typename traits::ref_type; + + /*! + * Provides a summary of the state of this type overwriting a provided object (see [standard] 7.5.2.8.7) + * @param[inout] descriptor @ref TypeDescriptor reference where copied the information. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the copy was successful. + * @retval RETCODE_BAD_PARAMETER when descriptor reference is nil. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_descriptor( + traits::ref_type& descriptor) = 0; + + /*! + * Returns the fully qualified name of this type + * @return Type name. + */ + FASTDDS_EXPORTED_API virtual ObjectName get_name() = 0; + + /*! + * Returns the @ref TypeKind associated + * @return @ref TypeKind + */ + FASTDDS_EXPORTED_API virtual TypeKind get_kind() = 0; + + /*! + * Returns the member that corresponds to the specified name. + * @param[inout] member @ref DynamicTypeMember reference used to return the reference to the member. + * @param[in] name Member name of the member being queried. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the member was found. + * @retval RETCODE_BAD_PARAMETER when the member doesn't exist. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_member_by_name( + traits::ref_type& member, + const ObjectName& name) = 0; + + /*! + * Returns all members by @ref ObjectName. + * @param[inout] member @ref DynamicTypeMembersByName reference where the information is copied. + * @return @ref ReturnCode_t + * @retval RETCODE_OK + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_all_members_by_name( + DynamicTypeMembersByName& member) = 0; + + /*! + * Returns the member that corresponds to the specified @ref MemberId. + * @param[inout] member @ref DynamicTypeMember reference used to return the reference to the member. + * @param[in] id @ref MemberId + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the member was found. + * @retval RETCODE_BAD_PARAMETER when the member doesn't exist. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_member( + traits::ref_type& member, + MemberId id) = 0; + + /*! + * Returns all members by @ref MemberId. + * @param[inout] member @ref DynamicTypeMembersById reference where the information is copied. + * @return @ref ReturnCode_t + * @retval RETCODE_OK + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_all_members( + DynamicTypeMembersById& member) = 0; + + /*! + * This operation returns the current number of members. + * @return Current number of members + */ + FASTDDS_EXPORTED_API virtual uint32_t get_member_count() = 0; + + /** + * This operation returns the member that corresponds to the specified index. + * @param[inout] member @ref DynamicTypeMember reference used to return the reference to the member. + * @param[in] index Index + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the member was found. + * @retval RETCODE_BAD_PARAMETER when the index is out-of-range. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_member_by_index( + traits::ref_type& member, + uint32_t index) = 0; + + /*! + * Returns the number of applied annotations to the type. + * @return Number of annotations. + */ + FASTDDS_EXPORTED_API virtual uint32_t get_annotation_count() = 0; + + /*! + * Returns an applied annotation by index. + * @param[inout] descriptor @ref AnnotationDescriptor reference where the information is copied. + * @param[in] idx Index. + * @return standard @ref ReturnCode_t + * @retval RETCODE_OK when the copy was successful. + * @retval RETCODE_BAD_PARAMETER when descriptor reference is nil or index is out-of-range. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_annotation( + traits::ref_type& descriptor, + uint32_t idx) = 0; + + /*! + * Returns the number of applied verbatim text to the type. + * @return Number of verbatim texts. + */ + FASTDDS_EXPORTED_API virtual uint32_t get_verbatim_text_count() = 0; + + /*! + * Returns an applied verbatim text by index. + * @param[inout] descriptor @ref VerbatimTextDescriptor reference where the information is copied. + * @param[in] idx Index. + * @return standard @ref ReturnCode_t + * @retval RETCODE_OK when the copy was successful. + * @retval RETCODE_BAD_PARAMETER when descriptor reference is nil or index is out-of-range. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_verbatim_text( + traits::ref_type& descriptor, + uint32_t idx) = 0; + + /** + * State comparison according with the [standard] sections \b 7.5.2.8.4 + * @param[in] other @ref DynamicType reference to compare to + * @return \b bool `true` on equality + */ + FASTDDS_EXPORTED_API virtual bool equals( + traits::ref_type other) = 0; + +protected: + + DynamicType() = default; + + virtual ~DynamicType() = default; + + traits::ref_type _this(); + +private: + + DynamicType( + const DynamicType&) = delete; + + DynamicType( + DynamicType&&) = delete; + + DynamicType& operator =( + const DynamicType&) = delete; + + DynamicType& operator =( + DynamicType&&) = delete; +}; + +} // namespace dds +} // namespace fastdds +} // namespace eprosima + +#endif // FASTDDS_DDS_XTYPES_DYNAMIC_TYPES_DYNAMIC_TYPE_HPP diff --git a/include/fastdds/dds/xtypes/dynamic_types/DynamicTypeBuilder.hpp b/include/fastdds/dds/xtypes/dynamic_types/DynamicTypeBuilder.hpp new file mode 100644 index 00000000000..dcda644b415 --- /dev/null +++ b/include/fastdds/dds/xtypes/dynamic_types/DynamicTypeBuilder.hpp @@ -0,0 +1,211 @@ +// Copyright 2023 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +#ifndef FASTDDS_DDS_XTYPES_DYNAMIC_TYPES_DYNAMIC_TYPE_BUILDER_HPP +#define FASTDDS_DDS_XTYPES_DYNAMIC_TYPES_DYNAMIC_TYPE_BUILDER_HPP + +#include + +#include +#include +#include +#include +#include +#include + +namespace eprosima { +namespace fastdds { +namespace dds { + +class DynamicTypeBuilder : public std::enable_shared_from_this +{ +public: + + using _ref_type = typename traits::ref_type; + + /*! + * Provides a summary of the state of this type overwriting a provided object. + * @param[inout] descriptor @ref TypeDescriptor + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the copy was successful. + * @retval RETCODE_BAD_PARAMETER when descriptor reference is nil. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_descriptor( + traits::ref_type& descriptor) = 0; + + /*! + * Returns the fully qualified name of this type + * @return Type name. + */ + FASTDDS_EXPORTED_API virtual ObjectName get_name() = 0; + + /*! + * Returns the @ref TypeKind associated + * @return @ref TypeKind + */ + FASTDDS_EXPORTED_API virtual TypeKind get_kind() = 0; + + /*! + * Returns a member looked for by name. + * @param[inout] member @ref DynamicTypeMember reference used to return the member. + * @param[in] name Member name. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when member was found. + * @retval RETCODE_BAD_PARAMETER when member wasn't found. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_member_by_name( + traits::ref_type& member, + const ObjectName& name) = 0; + + /*! + * Returns all members sorted by name. + * @param[inout] member DynamicTypeMemberByName reference used to return all members. + * @return @ref ReturnCode_t + * @retval RETCODE_OK always. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_all_members_by_name( + DynamicTypeMembersByName& member) = 0; + /*! + * Returns a member looked for by @ref MemberId. + * @param[inout] member @ref DynamicTypeMember reference used to return the member. + * @param[in] id Member identifier. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when member was found. + * @retval RETCODE_BAD_PARAMETER when member wasn't found. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_member( + traits::ref_type& member, + MemberId id) = 0; + + /*! + * Returns all members sorted by MemberId. + * @param[inout] member DynamicTypeMemberById reference used to return all members. + * @return @ref ReturnCode_t + * @retval RETCODE_OK always. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_all_members( + DynamicTypeMembersById& member) = 0; + + /*! + * This operation returns the current number of members. + * @return Current number of members + */ + FASTDDS_EXPORTED_API virtual uint32_t get_member_count() = 0; + + /*! + * This operation returns the member that corresponds to the specified index. + * @param[inout] member @ref DynamicTypeMember reference used to return the member. + * @param[in] index Index + * @return @ref ReturnCode_t + * @retval RETCODE_OK when member was found. + * @retval RETCODE_BAD_PARAMETER when index is out-of-range. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_member_by_index( + traits::ref_type& member, + uint32_t index) = 0; + + /*! + * This operation returns the current number of annotations to the type. + * @return Current number of annotations + */ + FASTDDS_EXPORTED_API virtual uint32_t get_annotation_count() = 0; + + /*! + * This operation returns the annotation that corresponds to the specified index. + * @param[inout] descriptor @ref AnnotationDescriptor reference where information is copied. + * @param[in] idx Index + * @return @ref ReturnCode_t + * @retval RETCODE_OK when member was found. + * @retval RETCODE_BAD_PARAMETER when reference is nil or index is out-of-range. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_annotation( + traits::ref_type& descriptor, + uint32_t idx) = 0; + + /*! + * Compares current state against a @ref DynamicType reference. + * @param[in] other @ref DynamicType reference to compare to. + * @return \b bool `true` on equality + */ + FASTDDS_EXPORTED_API virtual bool equals( + traits::ref_type other) = 0; + + /*! + * Adds a 'member' to this type, where the new 'member' has the meaning defined in the specification of + * the DynamicTypeMember class. + * @param[in] descriptor @ref MemberDescriptor reference used for the new member. + * @return ReturnCode_t + * @retval RETCODE_OK when the member was created successfully. + * @retval RETCODE_BAD_PARAMETER when there is an inconsistency. + * @retval RETCODE_PRECONDITION_NOT_MET when the type does not have members. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t add_member( + traits::ref_type descriptor) = 0; + + /*! + * Apply the given annotation to this type. + * @param[in] descriptor @ref AnnotationDescriptor reference to be applied. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the annotation was applied successful. + * @retval RETCODE_BAD_PARAMETER when there is an inconsistency. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t apply_annotation( + traits::ref_type descriptor) = 0; + + /*! + * Apply the given annotation to a member of this type. + * @param[in] member_id Member identifier. + * @param[in] descriptor @ref AnnotationDescriptor reference to be applied. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the annotation was applied successful. + * @retval RETCODE_BAD_PARAMETER when there is an inconsistency. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t apply_annotation_to_member( + MemberId member_id, + traits::ref_type descriptor) = 0; + + /*! + * Create an immutable DynamicType object containing a snapshot of this builder's current state. + * @return @ref DynamicType reference. + */ + FASTDDS_EXPORTED_API virtual traits::ref_type build() = 0; + +protected: + + DynamicTypeBuilder() = default; + + virtual ~DynamicTypeBuilder() = default; + + traits::ref_type _this(); + +private: + + DynamicTypeBuilder( + const DynamicTypeBuilder&) = delete; + + DynamicTypeBuilder( + DynamicTypeBuilder&&) = delete; + + DynamicTypeBuilder& operator =( + const DynamicTypeBuilder&) = delete; + + DynamicTypeBuilder& operator =( + DynamicTypeBuilder&&) = delete; +}; + +} // namespace dds +} // namespace fastdds +} // namespace eprosima + +#endif // FASTDDS_DDS_XTYPES_DYNAMIC_TYPES_DYNAMIC_TYPE_BUILDER_HPP diff --git a/include/fastdds/dds/xtypes/dynamic_types/DynamicTypeBuilderFactory.hpp b/include/fastdds/dds/xtypes/dynamic_types/DynamicTypeBuilderFactory.hpp new file mode 100644 index 00000000000..dce68614534 --- /dev/null +++ b/include/fastdds/dds/xtypes/dynamic_types/DynamicTypeBuilderFactory.hpp @@ -0,0 +1,213 @@ +// Copyright 2023 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +#ifndef FASTDDS_DDS_XTYPES_DYNAMIC_TYPES_DYNAMIC_TYPE_BUILDER_FACTORY_HPP +#define FASTDDS_DDS_XTYPES_DYNAMIC_TYPES_DYNAMIC_TYPE_BUILDER_FACTORY_HPP + +#include +#include + +#include +#include +#include +#include +#include + +namespace eprosima { +namespace fastdds { +namespace dds { + +namespace xtypes { +class TypeObject; +} // namespace xtypes + +class DynamicTypeBuilderFactory : public std::enable_shared_from_this +{ +public: + + using _ref_type = typename traits::ref_type; + + /*! + * Returns the singleton factory object + * @remark This method is non thread-safe. + * @return @ref DynamicTypeBuilderFactory reference. + */ + FASTDDS_EXPORTED_API static traits::ref_type get_instance(); + + /*! + * Resets the singleton reference. + * @return @ref ReturnCode_t + * @retval RETCODE_BAD_PARAMETER if singleton reference is currently nil. + * @retval RETCODE_OK otherwise. + */ + FASTDDS_EXPORTED_API static ReturnCode_t delete_instance(); + + /*! + * Retrieves the cached @ref DynamicType reference associated to a given primitive + * @param[in] kind Type identifying the primitive type to retrieve. + * @return @ref DynamicType reference. Nil reference returned in error case. + */ + FASTDDS_EXPORTED_API virtual traits::ref_type get_primitive_type( + TypeKind kind) = 0; + + /*! + * Creates a new @ref DynamicTypeBuilder reference based on the given @ref TypeDescriptor state. + * @param[in] descriptor @ref TypeDescriptor to be copied. + * @return New @ref DynamicTypeBuilder reference. Nil reference returned in error case. + */ + FASTDDS_EXPORTED_API virtual traits::ref_type create_type( + traits::ref_type descriptor) = 0; + + /*! + * Creates a new @ref DynamicTypeBuilder reference based on the given @ref DynamicType reference. + * @param[in] type @ref DynamicType reference to be used. + * @return New @ref DynamicTypeBuilder reference. Nil reference returned in error case. + */ + FASTDDS_EXPORTED_API virtual traits::ref_type create_type_copy( + traits::ref_type type) = 0; + + /*! + * Creates a new @ref DynamicTypeBuilder reference based on the given @ref xtypes::TypeObject instance. + * @param[in] type_object @ref xtypes::TypeObject instance to be used. + * @return New @ref DynamicTypeBuilder reference. Nil reference returned in error case. + */ + FASTDDS_EXPORTED_API virtual traits::ref_type create_type_w_type_object( + const xtypes::TypeObject& type_object) = 0; + + /*! + * Creates a new @ref DynamicTypeBuilder reference representing a bounded string type. + * @param[in] bound `uint32_t` representing the maximum number of elements that may be stored. + * If the value is equal to LENGTH_UNLIMITED, the string type shall be considered to be unbounded. + * @return new @ref DynamicTypeBuilder reference.. Nil reference returned in error case. + */ + FASTDDS_EXPORTED_API virtual traits::ref_type create_string_type( + uint32_t bound) = 0; + + /*! + * Creates a new @ref DynamicTypeBuilder reference representing a bounded wstring type. + * @param[in] bound `uint32_t` representing the maximum number of elements that may be stored. + * If the value is equal to LENGTH_UNLIMITED, the wstring type shall be considered to be unbounded. + * @return new @ref DynamicTypeBuilder reference.. Nil reference returned in error case. + */ + FASTDDS_EXPORTED_API virtual traits::ref_type create_wstring_type( + uint32_t bound) = 0; + + /*! + * Creates a new @ref DynamicTypeBuilder reference representing a sequence. + * @param[in] element_type @ref DynamicType reference which becomes the element type + * @param[in] bound `uint32_t` representing the maximum number of elements that may be stored. + * If the value is equal to LENGTH_UNLIMITED, the sequence type shall be considered to be unbounded. + * @return new @ref DynamicTypeBuilder reference. Nil reference returned in error case. + */ + FASTDDS_EXPORTED_API virtual traits::ref_type create_sequence_type( + traits::ref_type element_type, + uint32_t bound) = 0; + + /*! + * Creates a new @ref DynamicTypeBuilder reference representing an array. + * @param[in] element_type @ref DynamicType reference which becomes the element type + * @param[in] bound `uint32_t` sequence representing the desired dimensions. + * @return new @ref DynamicTypeBuilder reference. Nil reference returned in error case. + */ + FASTDDS_EXPORTED_API virtual traits::ref_type create_array_type( + traits::ref_type element_type, + const BoundSeq& bound) = 0; + + /*! + * Creates a new @ref DynamicTypeBuilder reference representing a map. + * @param[in] key_element_type @ref DynamicType reference which becomes the map's key type + * @param[in] element_type @ref DynamicType reference which becomes the map's value type + * @param[in] bound `uint32_t` representing the maximum number of elements that may be stored. + * If the value is equal to LENGTH_UNLIMITED, the map type shall be considered to be unbounded. + * @return new @ref DynamicTypeBuilder reference. Nil reference returned in error case. + */ + FASTDDS_EXPORTED_API virtual traits::ref_type create_map_type( + traits::ref_type key_element_type, + traits::ref_type element_type, + uint32_t bound) = 0; + + /*! + * Creates a new @ref DynamicTypeBuilder reference representing a bitmask + * @param[in] bound `uint32_t` representing the maximum number of elements that may be stored. + * @return new @ref DynamicTypeBuilder reference. Nil reference returned in error case. + */ + FASTDDS_EXPORTED_API virtual traits::ref_type create_bitmask_type( + uint32_t bound) = 0; + + /*! + * Creates a new @ref DynamicTypeBuilder reference by parsing the type description at the given URL. + * @remark Not implemented yet. + * @param[in] document_url pointing to the url containing the type description. + * @param[in] type_name Fully qualified name of the type to be loaded from the document. + * @param[in] include_paths A collection of URLs to directories to be searched for additional type description + * documents. + * @return new @ref DynamicTypeBuilder reference. Nil reference returned in error case. + */ + FASTDDS_EXPORTED_API virtual traits::ref_type create_type_w_uri( + const std::string& document_url, + const std::string& type_name, + const IncludePathSeq& include_paths) = 0; + + /*! + * Creates a new @ref DynamicTypeBuilder reference by parsing the type description contained in the given string. + * @remark Not implemented yet. + * @param[in] document containing the type description. + * @param[in] type_name Fully qualified name of the type to be loaded from the string. + * @param[in] include_paths A collection of URLs to directories to be searched for additional type description + * documents. + * @return new @ref DynamicTypeBuilder reference. Nil reference returned in error case. + */ + FASTDDS_EXPORTED_API virtual traits::ref_type create_type_w_document( + const std::string& document, + const std::string& type_name, + const IncludePathSeq& include_paths) = 0; + + /*! + * Resets the internal reference if it is cached. + * @param[in] type @ref DynamicType reference whose internal cached reference to reset. + * @return standard ReturnCode_t + * @retval RETCODE_OK is always returned. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t delete_type( + traits::ref_type type) = 0; + +protected: + + DynamicTypeBuilderFactory() = default; + + virtual ~DynamicTypeBuilderFactory() = default; + + traits::ref_type _this(); + +private: + + DynamicTypeBuilderFactory( + const DynamicTypeBuilderFactory&) = delete; + + DynamicTypeBuilderFactory( + DynamicTypeBuilderFactory&&) = delete; + + DynamicTypeBuilderFactory& operator =( + const DynamicTypeBuilderFactory&) = delete; + + DynamicTypeBuilderFactory& operator =( + DynamicTypeBuilderFactory&&) = delete; + +}; + +} // namespace dds +} // namespace fastdds +} // namespace eprosima + +#endif // FASTDDS_DDS_XTYPES_DYNAMIC_TYPES_DYNAMIC_TYPE_BUILDER_FACTORY_HPP diff --git a/include/fastdds/dds/xtypes/dynamic_types/DynamicTypeMember.hpp b/include/fastdds/dds/xtypes/dynamic_types/DynamicTypeMember.hpp new file mode 100644 index 00000000000..e1c3c9fadb9 --- /dev/null +++ b/include/fastdds/dds/xtypes/dynamic_types/DynamicTypeMember.hpp @@ -0,0 +1,139 @@ +// Copyright 2023 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +#ifndef FASTDDS_DDS_XTYPES_DYNAMIC_TYPES_DYNAMIC_TYPE_MEMBER_HPP +#define FASTDDS_DDS_XTYPES_DYNAMIC_TYPES_DYNAMIC_TYPE_MEMBER_HPP + +#include +#include + +#include +#include +#include +#include +#include +#include + +namespace eprosima { +namespace fastdds { +namespace dds { + +/*! + * Represents a "member" of a type. A "member" in this sense may be a member of an aggregated type, a constant within an + * enumeration, or some other type substructure. + */ +class DynamicTypeMember : public std::enable_shared_from_this +{ +public: + + using _ref_type = typename traits::ref_type; + + /*! + * Provides a summary of the state of this type overwriting a provided object (see [standard] 7.5.2.6.2) + * @param[inout] descriptor @ref MemberDescriptor reference where the information is copied. + * @return standard @ref ReturnCode_t + * @retval RETCODE_OK when the copy was successful. + * @retval RETCODE_BAD_PARAMETER when descriptor reference is nil. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_descriptor( + traits::ref_type& descriptor) = 0; + + /*! + * Returns the number of applied annotations to the member. + * @return Number of annotations. + */ + FASTDDS_EXPORTED_API virtual uint32_t get_annotation_count() = 0; + + /*! + * Returns an applied annotation by index. + * @param[inout] descriptor @ref AnnotationDescriptor reference where the information is copied. + * @param[in] idx Index. + * @return standard @ref ReturnCode_t + * @retval RETCODE_OK when the copy was successful. + * @retval RETCODE_BAD_PARAMETER when descriptor reference is nil or index is out-of-range. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_annotation( + traits::ref_type& descriptor, + uint32_t idx) = 0; + + /*! + * Returns the number of applied verbatim text to the member. + * @return Number of verbatim texts. + */ + FASTDDS_EXPORTED_API virtual uint32_t get_verbatim_text_count() = 0; + + /*! + * Returns an applied verbatim text by index. + * @param[inout] descriptor @ref VerbatimTextDescriptor reference where the information is copied. + * @param[in] idx Index. + * @return standard @ref ReturnCode_t + * @retval RETCODE_OK when the copy was successful. + * @retval RETCODE_BAD_PARAMETER when descriptor reference is nil or index is out-of-range. + */ + FASTDDS_EXPORTED_API virtual ReturnCode_t get_verbatim_text( + traits::ref_type& descriptor, + uint32_t idx) = 0; + + /** + * State comparison according with the [standard] sections \b 7.5.2.6.3 + * @param[in] other @ref DynamicTypeMember reference to compare to + * @return \b bool `true` on equality + */ + FASTDDS_EXPORTED_API virtual bool equals( + traits::ref_type other) = 0; + + /** + * Getter for @b id property according with the [standard] section \b 7.5.2.6.4 + * @return @ref MemberId + */ + FASTDDS_EXPORTED_API virtual MemberId get_id() = 0; + + /** + * Returns the name of this member. + * @return Member name. + */ + FASTDDS_EXPORTED_API virtual ObjectName get_name() = 0; + +protected: + + DynamicTypeMember() = default; + + virtual ~DynamicTypeMember() = default; + + traits::ref_type _this(); + +private: + + DynamicTypeMember( + const DynamicTypeMember&) = delete; + + DynamicTypeMember( + DynamicTypeMember&&) = delete; + + DynamicTypeMember& operator =( + const DynamicTypeMember&) = delete; + + DynamicTypeMember& operator =( + DynamicTypeMember&&) = delete; +}; + +typedef std::map::ref_type> DynamicTypeMembersByName; + +typedef std::map::ref_type> DynamicTypeMembersById; + +} // namespace dds +} // namespace fastdds +} // namespace eprosima + +#endif // FASTDDS_DDS_XTYPES_DYNAMIC_TYPES_DYNAMIC_TYPE_MEMBER_HPP diff --git a/include/fastdds/dds/xtypes/dynamic_types/MemberDescriptor.hpp b/include/fastdds/dds/xtypes/dynamic_types/MemberDescriptor.hpp new file mode 100644 index 00000000000..9c6f7b111ee --- /dev/null +++ b/include/fastdds/dds/xtypes/dynamic_types/MemberDescriptor.hpp @@ -0,0 +1,331 @@ +// Copyright 2023 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +#ifndef FASTDDS_DDS_XTYPES_DYNAMIC_TYPES_MEMBER_DESCRIPTOR_HPP +#define FASTDDS_DDS_XTYPES_DYNAMIC_TYPES_MEMBER_DESCRIPTOR_HPP + +#include +#include +#include + +#include +#include +#include + +namespace eprosima { +namespace fastdds { +namespace dds { + +class DynamicType; + +class FASTDDS_EXPORTED_API MemberDescriptor +{ +public: + + using _ref_type = typename traits::ref_type; + + /*! + * Returns the name of this member. + * @return Member's name. + */ + virtual ObjectName& name() = 0; + + /*! + * Returns the name of this member. + * @return Member's name. + */ + virtual const ObjectName& name() const = 0; + + /*! + * Modifies the underlying member's name by copy. + * @param[in] name Member's name. + */ + virtual void name( + const ObjectName& name) = 0; + + /*! + * Modifies the underlying member's name by move. + * @param[in] name Member's name. + */ + virtual void name( + ObjectName&& name) = 0; + + /*! + * Returns the @ref MemberId of the member. + * @return @ref MemberId. + */ + virtual MemberId id() const = 0; + + /*! + * Returns the @ref MemberId of the member. + * @return @ref MemberId. + */ + virtual MemberId& id() = 0; + + /*! + * Modifies the underlying @ref MemberId. + * @param[in] id @ref MemberId to be set. + */ + virtual void id( + MemberId id) = 0; + + /*! + * Returns a reference to the member's type. + * @return @ref DynamicType reference. + */ + virtual traits::ref_type type() const = 0; + + /*! + * Returns a reference to the member's type. + * @return @ref DynamicType reference. + */ + virtual traits::ref_type& type() = 0; + + /*! + * Modifies the underlying member's type reference. + * @param[in] type @ref DynamicType reference. + */ + virtual void type( + traits::ref_type type) = 0; + + /*! + * Returns the default value. + * @return Default value. + */ + virtual std::string& default_value() = 0; + + /*! + * Returns the default value. + * @return Default value. + */ + virtual const std::string& default_value() const = 0; + + /*! + * Modifies the underlying default value by copy. + * @param[in] default_value Default value. + */ + virtual void default_value( + const std::string& default_value) = 0; + + /*! + * Modifies the underlying default value by move. + * @param[in] default_value Default value. + */ + virtual void default_value( + std::string&& default_value) = 0; + + /*! + * Returns the order of definition of the member. + * @return Order of definition. + */ + virtual uint32_t& index() = 0; + + /*! + * Returns the order of definition of the member. + * @return Order of definition. + */ + virtual uint32_t index() const = 0; + + /*! + * Returns the labels the member belongs to. + * @return @ref UnionCaseLabelSeq. + */ + virtual const UnionCaseLabelSeq& label() const = 0; + + /*! + * Returns the labels the member belongs to. + * @return @ref UnionCaseLabelSeq. + */ + virtual UnionCaseLabelSeq& label() = 0; + + /*! + * Modifies the labels the member belongs to by copy. + * @param[in] label @ref UnionCaseLabelSeq + */ + virtual void label( + const UnionCaseLabelSeq& label) = 0; + + /*! + * Modifies the labels the member belongs to by move. + * @param[in] label @ref UnionCaseLabelSeq + */ + virtual void label( + UnionCaseLabelSeq&& label) = 0; + + /*! + * Returns the @ref TryConstructKind of the member. + * @return @ref TryConstructKind. + */ + virtual TryConstructKind try_construct_kind() const = 0; + + /*! + * Returns the @ref TryConstructKind of the member. + * @return @ref TryConstructKind. + */ + virtual TryConstructKind& try_construct_kind() = 0; + + /*! + * Modifies the @ref TryConstructKind of the member. + * @param[in] try_construct_kind @ref TryConstructKind. + */ + virtual void try_construct_kind( + TryConstructKind try_construct_kind) = 0; + + /*! + * Returns the if the member is key. + * @return If the member is key. + */ + virtual bool is_key() const = 0; + + /*! + * Returns the if the member is key. + * @return If the member is key. + */ + virtual bool& is_key() = 0; + + /*! + * Modifies if the member is key. + * @param[in] is_key Boolean + */ + virtual void is_key( + bool is_key) = 0; + + /*! + * Returns the if the member is optional. + * @return If the member is optional. + */ + virtual bool is_optional() const = 0; + + /*! + * Returns the if the member is optional. + * @return If the member is optional. + */ + virtual bool& is_optional() = 0; + + /*! + * Modifies if the member is optional. + * @param[in] is_optional Boolean + */ + virtual void is_optional( + bool is_optional) = 0; + + /*! + * Returns the if the member is must_understand. + * @return If the member is must_understand. + */ + virtual bool is_must_understand() const = 0; + + /*! + * Returns the if the member is must_understand. + * @return If the member is must_understand. + */ + virtual bool& is_must_understand() = 0; + + /*! + * Modifies if the member is must_understand. + * @param[in] is_must_understand Boolean + */ + virtual void is_must_understand( + bool is_must_understand) = 0; + + /*! + * Returns the if the member is shared. + * @return If the member is shared. + */ + virtual bool is_shared() const = 0; + + /*! + * Returns the if the member is shared. + * @return If the member is shared. + */ + virtual bool& is_shared() = 0; + + /*! + * Modifies if the member is shared. + * @param[in] is_shared Boolean + */ + virtual void is_shared( + bool is_shared) = 0; + + /*! + * Returns the if the member is default_label. + * @return If the member is default_label. + */ + virtual bool is_default_label() const = 0; + + /*! + * Returns the if the member is default_label. + * @return If the member is default_label. + */ + virtual bool& is_default_label() = 0; + + /*! + * Modifies if the member is default_label. + * @param[in] is_default_label Boolean + */ + virtual void is_default_label( + bool is_default_label) = 0; + + /*! + * Overwrites the contents of this descriptor with those of another descriptor (see [standard] 7.5.2.7.1). + * @param[in] descriptor reference. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the copy was successful. + * @retval RETCODE_BAD_PARAMETER when descriptor reference is nil. + */ + virtual ReturnCode_t copy_from( + traits::ref_type descriptor) = 0; + + /*! + * Compares according with the [standard] section \b 7.5.2.7.4. + * @param[in] descriptor reference to compare to. + * @return \b bool `true` on equality + */ + virtual bool equals( + traits::ref_type descriptor) = 0; + + /*! + * Indicates whether the states of all of this descriptor's properties are consistent according with the [standard] + * section \b 7.5.2.7.7. + * @return \b bool `true` if consistent. + */ + virtual bool is_consistent() = 0; + +protected: + + MemberDescriptor() = default; + + MemberDescriptor( + const MemberDescriptor& type) = default; + + MemberDescriptor( + MemberDescriptor&& type) = default; + + virtual ~MemberDescriptor() = default; + +private: + + MemberDescriptor& operator =( + const MemberDescriptor& type) = delete; + + MemberDescriptor& operator =( + MemberDescriptor&& type) = delete; + +}; + +} // namespace dds +} // namespace fastdds +} // namespace eprosima + +#endif // FASTDDS_DDS_XTYPES_DYNAMIC_TYPES_MEMBER_DESCRIPTOR_HPP diff --git a/include/fastdds/dds/xtypes/dynamic_types/TypeDescriptor.hpp b/include/fastdds/dds/xtypes/dynamic_types/TypeDescriptor.hpp new file mode 100644 index 00000000000..b7a5b10b6d7 --- /dev/null +++ b/include/fastdds/dds/xtypes/dynamic_types/TypeDescriptor.hpp @@ -0,0 +1,274 @@ +// Copyright 2023 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +#ifndef FASTDDS_DDS_XTYPES_DYNAMIC_TYPES_TYPE_DESCRIPTOR_HPP +#define FASTDDS_DDS_XTYPES_DYNAMIC_TYPES_TYPE_DESCRIPTOR_HPP + +#include +#include +#include + +namespace eprosima { +namespace fastdds { +namespace dds { + +class DynamicType; + +/*! + * TypeDescriptor definition according to [standard] section \b 7.5.2.4. + */ +class FASTDDS_EXPORTED_API TypeDescriptor +{ +public: + + using _ref_type = typename traits::ref_type; + + /*! + * Returns the @ref TypeKind associated. + * @return standard @ref TypeKind. + */ + virtual TypeKind kind() const = 0; + + /*! + * Returns the @ref TypeKind associated. + * @return standard @ref TypeKind. + */ + virtual TypeKind& kind() = 0; + + /*! + * Modifies the underlying @ref TypeKind. + * @param[in] kind @ref TypeKind to be set. + */ + virtual void kind( + TypeKind kind) = 0; + + /*! + * Returns the fully qualified name of this type. + * @return Fully qualified name. + */ + virtual ObjectName& name() = 0; + + /*! + * Returns the fully qualified name of this type. + * @return Fully qualified name. + */ + virtual const ObjectName& name() const = 0; + + /*! + * Modifies the underlying type name by copy. + * @param[in] name Fully qualified name. + */ + virtual void name( + const ObjectName& name) = 0; + + /*! + * Modifies the underlying type name by move. + * @param[in] name Fully qualified name. + */ + virtual void name( + ObjectName&& name) = 0; + + /*! + * Returns a reference to the base type. The reference can be nil. + * @return @ref DynamicType reference. + */ + virtual traits::ref_type base_type() const = 0; + + /*! + * Returns a reference to the base type. The reference can be nil. + * @return @ref DynamicType reference. + */ + virtual traits::ref_type& base_type() = 0; + + /*! + * Modifies the underlying base type reference. + * @param[in] type @ref DynamicType reference. + */ + virtual void base_type( + traits::ref_type type) = 0; + + /*! + * Returns a reference discriminator type. The reference can be nil. + * @return @ref DynamicType reference. + */ + virtual traits::ref_type discriminator_type() const = 0; + + /*! + * Returns a reference discriminator type. The reference can be nil. + * @return @ref DynamicType reference. + */ + virtual traits::ref_type& discriminator_type() = 0; + + /*! + * Modifies the underlying discriminator type reference. + * @param[in] type @ref DynamicType reference. + */ + virtual void discriminator_type( + traits::ref_type type) = 0; + + /*! + * Returns the bound. + * @return @ref BoundSeq. + */ + virtual const BoundSeq& bound() const = 0; + + /*! + * Returns the bound. + * @return @ref BoundSeq. + */ + virtual BoundSeq& bound() = 0; + + /*! + * Modifies the underlying bound by copy. + * @param[in] bound @ref BoundSeq + */ + virtual void bound( + const BoundSeq& bound) = 0; + + /*! + * Modifies the underlying bound by move. + * @param[in] bound @ref BoundSeq + */ + virtual void bound( + BoundSeq&& bound) = 0; + + /*! + * Returns a reference element type. The reference can be nil. + * @return @ref DynamicType reference. + */ + virtual traits::ref_type element_type() const = 0; + + /*! + * Returns a reference element type. The reference can be nil. + * @return @ref DynamicType reference. + */ + virtual traits::ref_type& element_type() = 0; + + /*! + * Modifies the underlying element type reference. + * @param[in] type @ref DynamicType reference. + */ + virtual void element_type( + traits::ref_type type) = 0; + + /*! + * Returns a reference key element type. The reference can be nil. + * @return @ref DynamicType reference. + */ + virtual traits::ref_type key_element_type() const = 0; + + /*! + * Returns a reference key element type. The reference can be nil. + * @return @ref DynamicType reference. + */ + virtual traits::ref_type& key_element_type() = 0; + + /*! + * Modifies the underlying key element type reference. + * @param[in] type @ref DynamicType reference. + */ + virtual void key_element_type( + traits::ref_type type) = 0; + + + /*! + * Returns the extensibility kind. + * return @ref ExtensibilityKind + */ + virtual ExtensibilityKind extensibility_kind() const = 0; + + /*! + * Returns the extensibility kind. + * return @ref ExtensibilityKind + */ + virtual ExtensibilityKind& extensibility_kind() = 0; + + /*! + * Modifies the extensibility kind. + * @param[in] extensibility_kind @ref ExtensibilityKind + */ + virtual void extensibility_kind( + ExtensibilityKind extensibility_kind) = 0; + + /*! + * Returns the is_nested property. + * return Boolean + */ + virtual bool is_nested() const = 0; + + /*! + * Returns the is_nested property. + * return Boolean + */ + virtual bool& is_nested() = 0; + + /*! + * Modifies the is_nested property. + * @param[in] is_nested Boolean value to be set. + */ + virtual void is_nested( + bool is_nested) = 0; + + /*! + * Overwrites the contents of this descriptor with those of another descriptor (see [standard] 7.5.2.4.3). + * @param[in] descriptor reference. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the copy was successful. + * @retval RETCODE_BAD_PARAMETER when descriptor reference is nil. + */ + virtual ReturnCode_t copy_from( + traits::ref_type descriptor) = 0; + + /*! + * Compares according with the [standard] section \b 7.5.2.4.6. + * @param[in] descriptor reference to compare to. + * @return \b bool `true` on equality + */ + virtual bool equals( + traits::ref_type descriptor) = 0; + + /*! + * Indicates whether the states of all of this descriptor's properties are consistent according with the [standard] + * section \b 7.5.2.4.7. + * @return \b bool `true` if consistent. + */ + virtual bool is_consistent() = 0; + +protected: + + TypeDescriptor() = default; + + TypeDescriptor( + const TypeDescriptor& type) = default; + + TypeDescriptor( + TypeDescriptor&& type) = default; + + virtual ~TypeDescriptor() = default; + +private: + + TypeDescriptor& operator =( + const TypeDescriptor& type) = delete; + + TypeDescriptor& operator =( + TypeDescriptor&& type) = delete; + +}; + +} // namespace dds +} // namespace fastdds +} // namespace eprosima + +#endif // FASTDDS_DDS_XTYPES_DYNAMIC_TYPES_TYPE_DESCRIPTOR_HPP diff --git a/include/fastdds/dds/xtypes/dynamic_types/Types.hpp b/include/fastdds/dds/xtypes/dynamic_types/Types.hpp new file mode 100644 index 00000000000..544fa49427a --- /dev/null +++ b/include/fastdds/dds/xtypes/dynamic_types/Types.hpp @@ -0,0 +1,83 @@ +// Copyright 2023 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file Types.hpp + */ + +#ifndef _FASTDDS_DDS_XTYPES_DYNAMIC_TYPES_TYPES_HPP_ +#define _FASTDDS_DDS_XTYPES_DYNAMIC_TYPES_TYPES_HPP_ + +#include "detail/dynamic_language_binding.hpp" +#include "type_traits.hpp" + +namespace eprosima { +namespace fastdds { +namespace dds { + +constexpr MemberId MEMBER_ID_INVALID {0x0FFFFFFF}; + +class DynamicData; + +template<> +struct traits : public object_traits +{ + using base_type = DynamicData; +}; + +class DynamicDataFactory; + +template<> +struct traits : public object_traits +{ + using base_type = DynamicDataFactory; +}; + +class DynamicType; + +template<> +struct traits : public object_traits +{ + using base_type = DynamicType; +}; + +class DynamicTypeBuilder; + +template<> +struct traits : public object_traits +{ + using base_type = DynamicTypeBuilder; +}; + +class DynamicTypeBuilderFactory; + +template<> +struct traits : public object_traits +{ + using base_type = DynamicTypeBuilderFactory; +}; + +class DynamicTypeMember; + +template<> +struct traits : public object_traits +{ + using base_type = DynamicTypeMember; +}; + +} // namespace dds +} // namespace fastdds +} // namespace eprosima + +#endif // _FASTDDS_DDS_XTYPES_DYNAMIC_TYPES_TYPES_HPP_ diff --git a/include/fastdds/dds/xtypes/dynamic_types/VerbatimTextDescriptor.hpp b/include/fastdds/dds/xtypes/dynamic_types/VerbatimTextDescriptor.hpp new file mode 100644 index 00000000000..7b38ccf8b31 --- /dev/null +++ b/include/fastdds/dds/xtypes/dynamic_types/VerbatimTextDescriptor.hpp @@ -0,0 +1,133 @@ +// Copyright 2023 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +#ifndef FASTDDS_DDS_XTYPES_DYNAMIC_TYPES_VERBATIM_TEXT_DESCRIPTOR_HPP +#define FASTDDS_DDS_XTYPES_DYNAMIC_TYPES_VERBATIM_TEXT_DESCRIPTOR_HPP + +#include + +#include +#include +#include + +namespace eprosima { +namespace fastdds { +namespace dds { + +class FASTDDS_EXPORTED_API VerbatimTextDescriptor +{ +public: + + /*! + * Returns the location within the generated output at which the output text should be inserted. + * @return The location. + */ + virtual std::string& placement() = 0; + + /*! + * Returns the location within the generated output at which the output text should be inserted. + * @return The location. + */ + virtual const std::string& placement() const = 0; + + /*! + * Sets the location within the generated output at which the output text should be inserted. + * @param[in] placement The location. + */ + virtual void placement( + const std::string& placement) = 0; + + /*! + * Sets the location within the generated output at which the output text should be inserted. + * @param[in] placement The location. + */ + virtual void placement( + std::string&& placement) = 0; + + /*! + * Returns the literal output text. + * @return The text. + */ + virtual std::string& text() = 0; + + /*! + * Returns the literal output text. + * @return The text. + */ + virtual const std::string& text() const = 0; + + /*! + * Sets the literal output text. + * @param[in] text The text. + */ + virtual void text( + const std::string& text) = 0; + + /*! + * Sets the literal output text. + * @param[in] text The text. + */ + virtual void text( + std::string&& text) = 0; + + /*! + * Overwrites the contents of this descriptor with those of another descriptor. + * @param[in] descriptor reference. + * @return @ref ReturnCode_t + * @retval RETCODE_OK when the copy was successful. + * @retval RETCODE_BAD_PARAMETER when descriptor reference is nil. + */ + virtual ReturnCode_t copy_from( + traits::ref_type descriptor) = 0; + + /*! + * Compares. + * @param[in] descriptor reference to compare to. + * @return \b bool `true` on equality + */ + virtual bool equals( + traits::ref_type descriptor) = 0; + + /*! + * Indicates whether the states of all of this descriptor's properties are consistent. + * @return \b bool `true` if consistent. + */ + virtual bool is_consistent() = 0; + +protected: + + VerbatimTextDescriptor() = default; + + VerbatimTextDescriptor( + const VerbatimTextDescriptor& type) = default; + + VerbatimTextDescriptor( + VerbatimTextDescriptor&& type) = default; + + virtual ~VerbatimTextDescriptor() = default; + +private: + + VerbatimTextDescriptor& operator =( + const VerbatimTextDescriptor& type) = delete; + + VerbatimTextDescriptor& operator =( + VerbatimTextDescriptor&& type) = delete; +}; + +} // namespace dds +} // namespace fastdds +} // namespace eprosima + +#endif // FASTDDS_DDS_XTYPES_DYNAMIC_TYPES_VERBATIM_TEXT_DESCRIPTOR_HPP diff --git a/include/fastdds/dds/xtypes/dynamic_types/detail/dynamic_language_binding.hpp b/include/fastdds/dds/xtypes/dynamic_types/detail/dynamic_language_binding.hpp new file mode 100644 index 00000000000..fb0d0fdea46 --- /dev/null +++ b/include/fastdds/dds/xtypes/dynamic_types/detail/dynamic_language_binding.hpp @@ -0,0 +1,170 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file dynamic_language_binding.hpp + * This header file contains the declaration of the described types in the IDL file. + * + * This file was generated by the tool fastddsgen. + */ + +#ifndef _FAST_DDS_GENERATED_DYNAMIC_LANGUAGE_BINDING_HPP_ +#define _FAST_DDS_GENERATED_DYNAMIC_LANGUAGE_BINDING_HPP_ + +#include +#include +#include +#include +#include + +#include + +#if defined(_WIN32) +#if defined(EPROSIMA_USER_DLL_EXPORT) +#define eProsima_user_DllExport __declspec( dllexport ) +#else +#define eProsima_user_DllExport +#endif // EPROSIMA_USER_DLL_EXPORT +#else +#define eProsima_user_DllExport +#endif // _WIN32 + +#if defined(_WIN32) +#if defined(EPROSIMA_USER_DLL_EXPORT) +#if defined(DYNAMIC_LANGUAGE_BINDING_SOURCE) +#define DYNAMIC_LANGUAGE_BINDING_DllAPI __declspec( dllexport ) +#else +#define DYNAMIC_LANGUAGE_BINDING_DllAPI __declspec( dllimport ) +#endif // DYNAMIC_LANGUAGE_BINDING_SOURCE +#else +#define DYNAMIC_LANGUAGE_BINDING_DllAPI +#endif // EPROSIMA_USER_DLL_EXPORT +#else +#define DYNAMIC_LANGUAGE_BINDING_DllAPI +#endif // _WIN32 + +namespace eprosima { + +namespace fastdds { + +namespace dds { + + +typedef std::vector IncludePathSeq; + +typedef eprosima::fastcdr::fixed_string<256> ObjectName; + +typedef std::vector BoundSeq; + +typedef uint8_t TypeKind; + +const TypeKind TK_NONE = 0x00; +const TypeKind TK_BOOLEAN = 0x01; +const TypeKind TK_BYTE = 0x02; +const TypeKind TK_INT16 = 0x03; +const TypeKind TK_INT32 = 0x04; +const TypeKind TK_INT64 = 0x05; +const TypeKind TK_UINT16 = 0x06; +const TypeKind TK_UINT32 = 0x07; +const TypeKind TK_UINT64 = 0x08; +const TypeKind TK_FLOAT32 = 0x09; +const TypeKind TK_FLOAT64 = 0x0A; +const TypeKind TK_FLOAT128 = 0x0B; +const TypeKind TK_INT8 = 0x0C; +const TypeKind TK_UINT8 = 0x0D; +const TypeKind TK_CHAR8 = 0x10; +const TypeKind TK_CHAR16 = 0x11; +const TypeKind TK_STRING8 = 0x20; +const TypeKind TK_STRING16 = 0x21; +const TypeKind TK_ALIAS = 0x30; +const TypeKind TK_ENUM = 0x40; +const TypeKind TK_BITMASK = 0x41; +const TypeKind TK_ANNOTATION = 0x50; +const TypeKind TK_STRUCTURE = 0x51; +const TypeKind TK_UNION = 0x52; +const TypeKind TK_BITSET = 0x53; +const TypeKind TK_SEQUENCE = 0x60; +const TypeKind TK_ARRAY = 0x61; +const TypeKind TK_MAP = 0x62; +typedef std::map Parameters; + +/*! + * @brief This class represents the enumeration ExtensibilityKind defined by the user in the IDL file. + * @ingroup dynamic_language_binding + */ +enum class ExtensibilityKind : uint32_t +{ + FINAL, + APPENDABLE, + MUTABLE +}; +/*! + * @brief This class represents the enumeration TryConstructKind defined by the user in the IDL file. + * @ingroup dynamic_language_binding + */ +enum class TryConstructKind : uint32_t +{ + USE_DEFAULT, + DISCARD, + TRIM +}; +typedef uint32_t MemberId; + +typedef std::vector UnionCaseLabelSeq; + +typedef std::vector Int32Seq; + +typedef std::vector UInt32Seq; + +typedef std::vector Int8Seq; + +typedef std::vector UInt8Seq; + +typedef std::vector Int16Seq; + +typedef std::vector UInt16Seq; + +typedef std::vector Int64Seq; + +typedef std::vector UInt64Seq; + +typedef std::vector Float32Seq; + +typedef std::vector Float64Seq; + +typedef std::vector Float128Seq; + +typedef std::vector CharSeq; + +typedef std::vector WcharSeq; + +typedef std::vector BooleanSeq; + +typedef std::vector ByteSeq; + +typedef std::vector StringSeq; + +typedef std::vector WstringSeq; + + +} // namespace dds + +} // namespace fastdds + +} // namespace eprosima + + +#endif // _FAST_DDS_GENERATED_DYNAMIC_LANGUAGE_BINDING_HPP_ + + diff --git a/include/fastdds/dds/xtypes/dynamic_types/detail/dynamic_language_binding.idl b/include/fastdds/dds/xtypes/dynamic_types/detail/dynamic_language_binding.idl new file mode 100644 index 00000000000..c36032ad8db --- /dev/null +++ b/include/fastdds/dds/xtypes/dynamic_types/detail/dynamic_language_binding.idl @@ -0,0 +1,89 @@ +// The content of this file, was extracted from DDS-XTypes v1.3 standard. + +module DDS +{ + typedef sequence IncludePathSeq; + typedef string<256> ObjectName; + + // Inserted until defined in standard. + typedef sequence BoundSeq; + + // ---------- TypeKinds (begin) ------------------- + typedef octet TypeKind; + + // Primitive TKs + const TypeKind TK_NONE= 0x00; + const TypeKind TK_BOOLEAN= 0x01; + const TypeKind TK_BYTE= 0x02; + const TypeKind TK_INT16= 0x03; + const TypeKind TK_INT32= 0x04; + const TypeKind TK_INT64= 0x05; + const TypeKind TK_UINT16= 0x06; + const TypeKind TK_UINT32= 0x07; + const TypeKind TK_UINT64= 0x08; + const TypeKind TK_FLOAT32= 0x09; + const TypeKind TK_FLOAT64= 0x0A; + const TypeKind TK_FLOAT128= 0x0B; + const TypeKind TK_INT8= 0x0C; + const TypeKind TK_UINT8= 0x0D; + const TypeKind TK_CHAR8= 0x10; + const TypeKind TK_CHAR16= 0x11; + + // String TKs + const TypeKind TK_STRING8= 0x20; + const TypeKind TK_STRING16= 0x21; + + // Constructed/Named types + const TypeKind TK_ALIAS = 0x30; + + // Enumerated TKs + const TypeKind TK_ENUM= 0x40; + const TypeKind TK_BITMASK= 0x41; + + // Structured TKs + const TypeKind TK_ANNOTATION = 0x50; + const TypeKind TK_STRUCTURE= 0x51; + const TypeKind TK_UNION= 0x52; + const TypeKind TK_BITSET= 0x53; + + // Collection TKs + const TypeKind TK_SEQUENCE= 0x60; + const TypeKind TK_ARRAY= 0x61; + const TypeKind TK_MAP= 0x62; + // ---------- TypeKinds (end) ------------------- + + typedef map Parameters; + + enum ExtensibilityKind { + FINAL, + APPENDABLE, + MUTABLE + }; + + enum TryConstructKind { + USE_DEFAULT, + DISCARD, + TRIM + }; + + typedef unsigned long MemberId; + typedef sequence UnionCaseLabelSeq; + + typedef sequenceInt32Seq; + typedef sequenceUInt32Seq; + typedef sequenceInt8Seq; + typedef sequenceUInt8Seq; + typedef sequenceInt16Seq; + typedef sequenceUInt16Seq; + typedef sequenceInt64Seq; + typedef sequenceUInt64Seq; + typedef sequenceFloat32Seq; + typedef sequenceFloat64Seq; + typedef sequenceFloat128Seq; + typedef sequenceCharSeq; + typedef sequenceWcharSeq; + typedef sequenceBooleanSeq; + typedef sequenceByteSeq; + typedef sequenceStringSeq; + typedef sequenceWstringSeq; +}; diff --git a/include/fastdds/dds/xtypes/dynamic_types/detail/type_traits.hpp b/include/fastdds/dds/xtypes/dynamic_types/detail/type_traits.hpp new file mode 100644 index 00000000000..d3b4dbddd39 --- /dev/null +++ b/include/fastdds/dds/xtypes/dynamic_types/detail/type_traits.hpp @@ -0,0 +1,65 @@ +// Copyright 2023 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +#ifndef _FASTDDS_DDS_XTYPES_DYNAMIC_TYPES_DETAIL_TYPE_TRAITS_HPP_ +#define _FASTDDS_DDS_XTYPES_DYNAMIC_TYPES_DETAIL_TYPE_TRAITS_HPP_ + +#include + +#include + +namespace eprosima { +namespace fastdds { +namespace dds { + +template +struct traits +{ + using ref_type = typename ::std::shared_ptr; + using weak_ref_type = typename ::std::weak_ptr; + + template::value>::type> + inline static std::shared_ptr<_Tp> narrow ( + ref_type obj) + { + return std::dynamic_pointer_cast<_Tp>(obj); + } + + FASTDDS_EXPORTED_API static std::shared_ptr make_shared(); + +}; + +template +struct object_traits +{ + using ref_type = typename ::std::shared_ptr; + using weak_ref_type = typename ::std::weak_ptr; + + template::value>::type> + inline static std::shared_ptr<_Tp> narrow ( + ref_type obj) + { + return std::dynamic_pointer_cast<_Tp>(obj); + } + +}; + +} // namespace dds +} // namespace fastdds +} // namespace eprosima + +#endif // _FASTDDS_DDS_XTYPES_DYNAMIC_TYPES_DETAIL_TYPE_TRAITS_HPP_ + diff --git a/src/cpp/dynamic-types/DynamicTypeBuilderPtr.cpp b/include/fastdds/dds/xtypes/dynamic_types/type_traits.hpp similarity index 55% rename from src/cpp/dynamic-types/DynamicTypeBuilderPtr.cpp rename to include/fastdds/dds/xtypes/dynamic_types/type_traits.hpp index d0e7477ac19..5ce20f7cda8 100644 --- a/src/cpp/dynamic-types/DynamicTypeBuilderPtr.cpp +++ b/include/fastdds/dds/xtypes/dynamic_types/type_traits.hpp @@ -1,4 +1,4 @@ -// Copyright 2018 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// Copyright 2023 Proyectos y Sistemas de Mantenimiento SL (eProsima). // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. @@ -12,22 +12,23 @@ // See the License for the specific language governing permissions and // limitations under the License. -#include -#include -#include +#ifndef _FASTDDS_DDS_XTYPES_DYNAMIC_TYPES_TYPE_TRAITS_HPP_ +#define _FASTDDS_DDS_XTYPES_DYNAMIC_TYPES_TYPE_TRAITS_HPP_ namespace eprosima { -namespace fastrtps { -namespace types { +namespace fastdds { +namespace dds { -DynamicTypeBuilder_ptr::DynamicTypeBuilder_ptr(DynamicTypeBuilder* pType) - : Base(pType, [](DynamicTypeBuilder* pType) -{ - DynamicTypeBuilderFactory::get_instance()->delete_builder(pType); -}) -{ -} +template +struct traits; -} // namespace types -} // namespace fastrtps +template +struct object_traits; + +} // namespace dds +} // namespace fastdds } // namespace eprosima + +#include "detail/type_traits.hpp" + +#endif // _FASTDDS_DDS_XTYPES_DYNAMIC_TYPES_TYPE_TRAITS_HPP_ diff --git a/include/fastdds/dds/xtypes/exception/Exception.hpp b/include/fastdds/dds/xtypes/exception/Exception.hpp new file mode 100644 index 00000000000..31d15ffc2c7 --- /dev/null +++ b/include/fastdds/dds/xtypes/exception/Exception.hpp @@ -0,0 +1,79 @@ +// Copyright 2023 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file + * This file is based on the DDS-PSM-CXX Exception.hpp file. + */ + +#ifndef _FASTDDS_DDS_XTYPES_EXCEPTION_EXCEPTION_HPP_ +#define _FASTDDS_DDS_XTYPES_EXCEPTION_EXCEPTION_HPP_ + +#include +#include + +#include + +namespace eprosima { +namespace fastdds { +namespace dds { +namespace xtypes { + +/** + * @brief Exception: base class for specified DDS Exceptions. + */ +class Exception +{ +protected: + + Exception() = default; + +public: + + FASTDDS_EXPORTED_API virtual ~Exception() throw() = default; + + /** + * @brief Retrieve information about the exception that was thrown. + * + * @return Exception information. + */ + FASTDDS_EXPORTED_API virtual const char* what() const throw() = 0; + +}; + +/** + * @brief Application is passing an invalid argument. + */ +class InvalidArgumentError : public Exception, public std::invalid_argument +{ +public: + + FASTDDS_EXPORTED_API explicit InvalidArgumentError( + const std::string& msg); + + FASTDDS_EXPORTED_API InvalidArgumentError( + const InvalidArgumentError& src); + + FASTDDS_EXPORTED_API virtual ~InvalidArgumentError() throw(); + + FASTDDS_EXPORTED_API virtual const char* what() const throw(); + +}; + +} // xtypes +} // dds +} // fastdds +} // eprosima + +#endif // _FASTDDS_DDS_XTYPES_EXCEPTION_EXCEPTION_HPP_ diff --git a/include/fastdds/dds/xtypes/type_representation/ITypeObjectRegistry.hpp b/include/fastdds/dds/xtypes/type_representation/ITypeObjectRegistry.hpp new file mode 100644 index 00000000000..287ce381f90 --- /dev/null +++ b/include/fastdds/dds/xtypes/type_representation/ITypeObjectRegistry.hpp @@ -0,0 +1,144 @@ +// Copyright 2023 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file + * This file contains the required classes to keep a TypeObject/TypeIdentifier registry. + */ + +#ifndef _FASTDDS_DDS_XTYPES_TYPE_REPRESENTATION_ITYPEOBJECTREGISTRY_HPP_ +#define _FASTDDS_DDS_XTYPES_TYPE_REPRESENTATION_ITYPEOBJECTREGISTRY_HPP_ + +#include + +#include +#include +#include + +namespace eprosima { +namespace fastdds { +namespace dds { + +namespace xtypes { + +struct TypeObjectPair +{ + // Minimal TypeObject + TypeObject minimal_type_object; + // Complete TypeObject + TypeObject complete_type_object; +}; + +class ITypeObjectRegistry +{ +public: + + /** + * @brief Register a local TypeObject. + * The MinimalTypeObject is generated from the CompleteTypeObject, and both are registered into the registry + * with the corresponding TypeIdentifiers and TypeObject serialized sizes. + * + * @pre type_name must not be empty. + * @pre complete_type_object must be consistent (only checked in Debug build mode). + * + * @param[in] type_name Name of the type being registered. + * @param[in] complete_type_object CompleteTypeObject related to the given type name. + * @return ReturnCode_t RETCODE_OK if correctly registered in TypeObjectRegistry. + * RETCODE_BAD_PARAMETER if there is already another different TypeObject registered with the + * given type_name. + * RETCODE_PRECONDITION_NOT_MET if the given type_name is empty or if the type_object + * is inconsistent. + */ + virtual FASTDDS_EXPORTED_API ReturnCode_t register_type_object( + const std::string& type_name, + const CompleteTypeObject& complete_type_object) = 0; + + /** + * @brief Register an indirect hash TypeIdentifier. + * + * @pre TypeIdentifier must not be a direct hash TypeIdentifier. + * @pre TypeIdentifier must be consistent (only checked in Debug build mode). + * @pre type_name must not be empty. + * + * @param[in] type_name Name of the type being registered. + * @param[in] type_identifier TypeIdentier related to the given type name. + * @return ReturnCode_t RETCODE_OK if correctly registered in TypeObjectRegistry. + * RETCODE_BAD_PARAMETER if there is already another different TypeIdentifier registered with + * the given type_name. + * RETCODE_PRECONDITION_NOT_MET if the given TypeIdentifier is inconsistent or a direct hash + * TypeIdentifier or if the given type_name is empty. + */ + virtual FASTDDS_EXPORTED_API ReturnCode_t register_type_identifier( + const std::string& type_name, + const TypeIdentifier& type_identifier) = 0; + + /** + * @brief Get the TypeObjects related to the given type name. + * + * @pre type_name must not be empty. + * + * @param[in] type_name Name of the type being queried. + * @param[out] type_objects Both complete and minimal TypeObjects related with the given type_name. + * @return ReturnCode_t RETCODE_OK if the TypeObjects are found in the registry. + * RETCODE_NO_DATA if the given type_name has not been registered. + * RETCODE_BAD_PARAMETER if the type_name correspond to a indirect hash TypeIdentifier. + * RETCODE_PRECONDITION_NOT_MET if the type_name is empty. + */ + virtual FASTDDS_EXPORTED_API ReturnCode_t get_type_objects( + const std::string& type_name, + TypeObjectPair& type_objects) = 0; + + /** + * @brief Get the TypeIdentifiers related to the given type name. + * + * @pre type_name must not be empty. + * + * @param[in] type_name Name of the type being queried. + * @param[out] type_identifiers For direct hash TypeIdentifiers, both minimal and complete TypeIdentifiers are + * returned. + * For indirect hash TypeIdentifiers, only the corresponding TypeIdentifier is returned + * @return ReturnCode_t RETCODE_OK if the TypeIdentifiers are found in the registry. + * RETCODE_NO_DATA if the type_name has not been registered. + * RETCODE_PRECONDITION_NOT_MET if the type_name is empty. + */ + virtual FASTDDS_EXPORTED_API ReturnCode_t get_type_identifiers( + const std::string& type_name, + TypeIdentifierPair& type_identifiers) = 0; + + /** + * @brief Get the TypeObject related to the given TypeIdentifier. + * + * @pre TypeIdentifier must be a direct hash TypeIdentifier. + * + * @param[in] type_identifier TypeIdentifier being queried. + * @param[out] type_object TypeObject related with the given TypeIdentifier. + * @return ReturnCode_t RETCODE_OK if the TypeObject is found within the registry. + * RETCODE_NO_DATA if the given TypeIdentifier is not found in the registry. + * RETCODE_PRECONDITION_NOT_MET if the TypeIdentifier is not a direct hash. + */ + virtual FASTDDS_EXPORTED_API ReturnCode_t get_type_object( + const TypeIdentifier& type_identifier, + TypeObject& type_object) = 0; + +}; + + +} // xtypes +} // dds +} // fastdds +} // eprosima + +#endif // _FASTDDS_DDS_XTYPES_TYPE_REPRESENTATION_ITYPEOBJECTREGISTRY_HPP_ + + diff --git a/test/blackbox/types/TestIncludeRegression3361.cxx b/include/fastdds/dds/xtypes/type_representation/TypeObject.hpp similarity index 53% rename from test/blackbox/types/TestIncludeRegression3361.cxx rename to include/fastdds/dds/xtypes/type_representation/TypeObject.hpp index bd999acb638..3be6383ca03 100644 --- a/test/blackbox/types/TestIncludeRegression3361.cxx +++ b/include/fastdds/dds/xtypes/type_representation/TypeObject.hpp @@ -13,36 +13,18 @@ // limitations under the License. /*! - * @file TestIncludeRegression3361.cpp - * This source file contains the implementation of the described types in the IDL file. + * @file TypeObject.hpp + * This header file contains the declaration of the described types in the IDL file. * * This file was generated by the tool fastddsgen. */ -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 +#ifndef _FASTDDS_DDS_XTYPES_TYPE_REPRESENTATION_TYPEOBJECT_HPP_ +#define _FASTDDS_DDS_XTYPES_TYPE_REPRESENTATION_TYPEOBJECT_HPP_ -#include "TestIncludeRegression3361.h" +#include +#include +#include -#if FASTCDR_VERSION_MAJOR > 1 +#endif // _FASTDDS_DDS_XTYPES_TYPE_REPRESENTATION_TYPEOBJECT_HPP_ -#include "TestIncludeRegression3361TypeObject.h" - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - - -namespace TestModule { - - -} // namespace TestModule -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/include/fastdds/dds/xtypes/type_representation/TypeObjectUtils.hpp b/include/fastdds/dds/xtypes/type_representation/TypeObjectUtils.hpp new file mode 100644 index 00000000000..960bd72b36a --- /dev/null +++ b/include/fastdds/dds/xtypes/type_representation/TypeObjectUtils.hpp @@ -0,0 +1,3056 @@ +// Copyright 2023 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file + * This file contains static functions to help build a TypeObject. + */ + +#ifndef _FASTDDS_DDS_XTYPES_TYPE_REPRESENTATION_TYPEOBJECTUTILS_HPP_ +#define _FASTDDS_DDS_XTYPES_TYPE_REPRESENTATION_TYPEOBJECTUTILS_HPP_ + +#include + +#include +#include + +#include +#include +#include +#include +#include +#include + +namespace eprosima { +namespace fastdds { +namespace dds { + +class DynamicTypeBuilderFactoryImpl; + +namespace xtypes { + +class TypeObjectRegistry; + +using ReturnCode_t = eprosima::fastdds::dds::ReturnCode_t; + +class TypeObjectUtils +{ +public: + + /** + * @brief Build TypeObjectHashId instance. + * + * @param[in] discriminator TypeObjectHashId discriminator to be set. + * @param[in] hash StronglyConnectedComponent equivalence hash to be set. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given discriminator is not + * EK_COMPLETE/EK_MINIMAL. + * @return const TypeObjectHashId instance. + */ + FASTDDS_EXPORTED_API static const TypeObjectHashId build_type_object_hash_id( + uint8_t discriminator, + const EquivalenceHash& hash); + + /** + * @brief Build CollectionElementFlag instance. + * + * @param[in] try_construct_kind try_construct annotation value. + * @param[in] external external annotation value. + * @return CollectionElementFlag instance. + */ + FASTDDS_EXPORTED_API static CollectionElementFlag build_collection_element_flag( + TryConstructKind try_construct_kind, + bool external); + + /** + * @brief Build StructMemberFlag instance. + * + * @param[in] try_construct_kind try_construct annotation value. + * @param[in] optional optional annotation value. + * @param[in] must_understand must_understand annotation value. + * @param[in] key key annotation value. + * @param[in] external external annotation value. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if both key and optional flags are + * enabled. + * @return StructMemberFlag instance. + */ + FASTDDS_EXPORTED_API static StructMemberFlag build_struct_member_flag( + TryConstructKind try_construct_kind, + bool optional, + bool must_understand, + bool key, + bool external); + + /** + * @brief Build UnionMemberFlag instance. + * + * @param[in] try_construct_kind try_construct annotation value. + * @param[in] default_member is default member. + * @param[in] external external annotation value. + * @return UnionMemberFlag instance. + */ + FASTDDS_EXPORTED_API static UnionMemberFlag build_union_member_flag( + TryConstructKind try_construct_kind, + bool default_member, + bool external); + + /** + * @brief Build UnionDiscriminatorFlag instance. + * + * @param[in] try_construct_kind try_construct annotation value. + * @param[in] key key annotation value. + * @return UnionDiscriminatorFlag instance. + */ + FASTDDS_EXPORTED_API static UnionDiscriminatorFlag build_union_discriminator_flag( + TryConstructKind try_construct_kind, + bool key); + + /** + * @brief Build EnumeratedLiteralFlag instance. + * + * @param[in] default_literal default_literal annotation value. + * @return EnumeratedLiteralFlag instance. + */ + FASTDDS_EXPORTED_API static EnumeratedLiteralFlag build_enumerated_literal_flag( + bool default_literal); + + /** + * AnnotationParameterFlag: Unused. No flags apply. + * AliasMemberFlag: Unused. No flags apply. + * BitflagFlag: Unused. No flags apply. + * BitsetMemberFlag: Unused. No flags apply. + */ + + /** + * @brief Build StructTypeFlag instance. + * + * @param[in] extensibility_kind extensibility annotation value. + * @param[in] nested nested annotation value. + * @param[in] autoid_hash autoid annotation has HASH value. + * @return StructTypeFlag instance. + */ + FASTDDS_EXPORTED_API static StructTypeFlag build_struct_type_flag( + ExtensibilityKind extensibility_kind, + bool nested, + bool autoid_hash); + + /** + * @brief Build UnionTypeFlag instance. + * + * @param[in] extensibility_kind extensibility annotation value. + * @param[in] nested nested annotation value. + * @param[in] autoid_hash autoid annotation has HASH value. + * @return UnionTypeFlag instance. + */ + FASTDDS_EXPORTED_API static UnionTypeFlag build_union_type_flag( + ExtensibilityKind extensibility_kind, + bool nested, + bool autoid_hash); + + /** + * CollectionTypeFlag: Unused. No flags apply. + * AnnotationTypeFlag: Unused. No flags apply. + * AliasTypeFlag: Unused. No flags apply. + * EnumTypeFlag: Unused. No flags apply. + * BitmaskTypeFlag: Unused. No flags apply. + * BitsetTypeFlag: Unused. No flags apply. + */ + + /*************** Indirect Hash TypeIdentifiers ***************************/ + + /** + * @brief Build StringSTypeDefn instance. + * + * @pre bound > 0 (INVALID_SBOUND) + * @param[in] bound Bound for the small string/wstring. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if bound is 0. + * @return const StringSTypeDefn instance. + */ + FASTDDS_EXPORTED_API static const StringSTypeDefn build_string_s_type_defn( + SBound bound); + + /** + * @brief Build StringLTypeDefn instance. + * + * @pre bound > 255 + * @param[in] bound Bound for the large string/wstring. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if bound is lower than 256. + * @return const StringLTypeDefn instance. + */ + FASTDDS_EXPORTED_API static const StringLTypeDefn build_string_l_type_defn( + LBound bound); + + /** + * @brief Build PlainCollectionHeader instance. + * + * @param[in] equiv_kind EquivalenceKind: EK_MINIMAL/EK_COMPLETE/EK_BOTH + * @param[in] element_flags CollectionElementFlags to be set. This element must be constructed with the corresponding + * builder to ensure its consistency. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError if the given element_flags are inconsistent. + * This exception is only thrown in Debug build mode. + * @return const PlainCollectionHeader instance. + */ + FASTDDS_EXPORTED_API static const PlainCollectionHeader build_plain_collection_header( + EquivalenceKind equiv_kind, + CollectionElementFlag element_flags); + + /** + * @brief Build PlainSequenceSElemDefn instance. + * + * @pre bound > 0 (INVALID_SBOUND) + * @pre element_identifier has been initialized. + * @param[in] header PlainCollectionHeader to be set. + * @param[in] s_bound Sequence bound. + * @param[in] element_identifier Sequence element TypeIdentifier. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception + * 1. The given bound is 0. + * 2. The given TypeIdentifier EquivalenceKind is not consistent with the one contained in the header. + * 3. Inconsistent header (only in Debug build mode). + * 4. Inconsistent element_identifier (only in Debug build mode). + * @return const PlainSequenceSElemDefn instance. + */ + FASTDDS_EXPORTED_API static const PlainSequenceSElemDefn build_plain_sequence_s_elem_defn( + const PlainCollectionHeader& header, + SBound s_bound, + const eprosima::fastcdr::external& element_identifier); + + /** + * @brief Build PlainSequenceLElemDefn instance. + * + * @pre bound > 255 + * @pre element_identifier has been initialized. + * @param[in] header PlainCollectionHeader to be set. + * @param[in] l_bound Sequence bound. + * @param[in] element_identifier Sequence element TypeIdentifier. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception + * 1. Bound lower than 256. + * 2. The given TypeIdentifier EquivalenceKind is not consistent with the one contained in the header. + * 3. Inconsistent header (only in Debug build mode). + * 4. Inconsistent element_identifier (only in Debug build mode). + * @return const PlainSequenceLElemDefn instance. + */ + FASTDDS_EXPORTED_API static const PlainSequenceLElemDefn build_plain_sequence_l_elem_defn( + const PlainCollectionHeader& header, + LBound l_bound, + const eprosima::fastcdr::external& element_identifier); + + /** + * @brief Add dimension bound to the array bound sequence. + * + * @tparam array Either a SBoundSeq or LBoundSeq. + * @tparam element Either a SBound or LBound. + * @param[in out] array_bound_seq Sequence with the array bounds. + * @param[in] dimension_bound Dimension bound to be added into the sequence. + */ + template + static void add_array_dimension( + std::vector& array_bound_seq, + element dimension_bound) + { + if (dimension_bound == INVALID_LBOUND) + { + throw InvalidArgumentError("bound parameter must be greater than 0"); + } + array_bound_seq.push_back(dimension_bound); + } + + /** + * @brief Build PlainArraySElemDefn instance. + * + * @pre Any element in array_bound_seq must be greater than 0 (INVALID_SBOUND) + * @pre element_identifier has been initialized. + * @param[in] header PlainCollectionHeader to be set. + * @param[in] array_bound_seq Bounds for the array dimensions. + * @param[in] element_identifier Array element TypeIdentifier. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception + * 1. Any given bound in array_bound_seq is 0. + * 2. The given TypeIdentifier EquivalenceKind is not consistent with the one contained in the header. + * 3. Inconsistent header (only in Debug build mode). + * 4. Inconsistent element_identifier (only in Debug build mode). + * @return const PlainArraySElemDefn instance. + */ + FASTDDS_EXPORTED_API static const PlainArraySElemDefn build_plain_array_s_elem_defn( + const PlainCollectionHeader& header, + const SBoundSeq& array_bound_seq, + const eprosima::fastcdr::external& element_identifier); + + /** + * @brief Build PlainArrayLElemDefn instance. + * + * @pre At least one element of array_bound_seq must be greater than 255 and no element must be 0 (INVALID_SBOUND) + * @pre element_identifier has been initialized. + * @param[in] header PlainCollectionHeader to be set. + * @param[in] array_bound_seq Bounds for the array dimensions. + * @param[in] element_identifier Array element TypeIdentifier. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception + * 1. Any given bound in array_bound_seq is 0. + * 2. There is no dimension with a bound greater than 255. + * 3. The given TypeIdentifier EquivalenceKind is not consistent with the one contained in the header. + * 4. Inconsistent header (only in Debug build mode). + * 5. Inconsistent element_identifier (only in Debug build mode). + * @return const PlainArrayLElemDefn instance. + */ + FASTDDS_EXPORTED_API static const PlainArrayLElemDefn build_plain_array_l_elem_defn( + const PlainCollectionHeader& header, + const LBoundSeq& array_bound_seq, + const eprosima::fastcdr::external& element_identifier); + + /** + * @brief Build PlainMapSTypeDefn instance. + * + * @pre bound > 0 (INVALID_SBOUND) + * @pre Both element_identifier and key_identifier have been initialized. + * @param[in] header PlainCollectionHeader to be set. + * @param[in] bound Map bound. + * @param[in] element_identifier Map element TypeIdentifier. + * @param[in] key_flags Flags applying to map key. + * @param[in] key_identifier Map key TypeIdentifier. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception + * 1. Given bound is zero (INVALID_SBOUND) + * 2. Inconsistent element_identifier EquivalenceKind with the one contained in the header. + * 3. Direct hash key_identifier or indirect hash TypeIdentifier with exception to string/wstring. + * XTypes v1.3 Clause 7.2.2.4.3: Implementers of this specification need only support key elements + * of signed and unsigned integer types and of narrow and wide string types. + * 4. Inconsistent key_flags. + * 5. Inconsistent header (only in Debug build mode). + * 6. Inconsistent element_identifier or key_identifier (only in Debug build mode). + * @return const PlainMapSTypeDefn instance. + */ + FASTDDS_EXPORTED_API static const PlainMapSTypeDefn build_plain_map_s_type_defn( + const PlainCollectionHeader& header, + const SBound bound, + const eprosima::fastcdr::external& element_identifier, + const CollectionElementFlag key_flags, + const eprosima::fastcdr::external& key_identifier); + + /** + * @brief Build PlainMapLTypeDefn instance. + * + * @pre bound > 255 + * @pre Both element_identifier and key_identifier have been initialized. + * @param[in] header PlainCollectionHeader to be set. + * @param[in] bound Map bound. + * @param[in] element_identifier Map element TypeIdentifier. + * @param[in] key_flags Flags applying to map key. + * @param[in] key_identifier Map key TypeIdentifier. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception + * 1. Given bound is lower than 256 + * 2. Inconsistent element_identifier EquivalenceKind with the one contained in the header. + * 3. Direct hash key_identifier or indirect hash TypeIdentifier with exception to string/wstring. + * XTypes v1.3 Clause 7.2.2.4.3: Implementers of this specification need only support key elements + * of signed and unsigned integer types and of narrow and wide string types. + * 4. Inconsistent key_flags. + * 5. Inconsistent header (only in Debug build mode). + * 6. Inconsistent element_identifier or key_identifier (only in Debug build mode). + * @return const PlainMapLTypeDefn instance. + */ + FASTDDS_EXPORTED_API static const PlainMapLTypeDefn build_plain_map_l_type_defn( + const PlainCollectionHeader& header, + const LBound bound, + const eprosima::fastcdr::external& element_identifier, + const CollectionElementFlag key_flags, + const eprosima::fastcdr::external& key_identifier); + + /** + * @brief Build StronglyConnectedComponentId instance. + * + * @param[in] sc_component_id Strongly Connected Component (SCC) ID. + * @param[in] scc_length Number of components within SCC. + * @param[in] scc_index Identify specific component within SCC. + * @return const StronglyConnectedComponentId instance. + */ + FASTDDS_EXPORTED_API static const StronglyConnectedComponentId build_strongly_connected_component_id( + const TypeObjectHashId& sc_component_id, + int32_t scc_length, + int32_t scc_index); + + /** + * @brief Build ExtendedTypeDefn instance (empty. Available for future extension). + * + * @return const ExtendedTypeDefn instance. + */ + FASTDDS_EXPORTED_API static const ExtendedTypeDefn build_extended_type_defn(); + + /*************** Register Indirect Hash TypeIdentifiers ***************************/ + /** + * Primitive types are registered when TypeObjectRegistry is instantiated. + */ + + /** + * @brief Register small string/wstring TypeIdentifier into TypeObjectRegistry. + * + * @param[in] string StringSTypeDefn union member to set. + * @param[in] type_name Type name to be registered. + * @param[in] wstring Flag to build a wstring. Default false. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given member is inconsistent + * (only in Debug build mode). + * @return ReturnCode_t RETCODE_OK if correctly registered in TypeObjectRegistry. + * RETCODE_BAD_PARAMETER if there is already another different TypeIdentifier registered with + * the given type_name. + * RETCODE_BAD_PARAMETER if type_name is empty. + */ + FASTDDS_EXPORTED_API static ReturnCode_t build_and_register_s_string_type_identifier( + const StringSTypeDefn& string, + const std::string& type_name, + bool wstring = false); + + /** + * @brief Register large string/wstring TypeIdentifier into TypeObjectRegistry. + * + * @param[in] string StringLTypeDefn union member to set. + * @param[in] type_name Type name to be registered. + * @param[in] wstring Flag to build a wstring. Default false. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given member is inconsistent + * (only in Debug build mode). + * @return ReturnCode_t RETCODE_OK if correctly registered in TypeObjectRegistry. + * RETCODE_BAD_PARAMETER if there is already another different TypeIdentifier registered with + * the given type_name. + * RETCODE_BAD_PARAMETER if type_name is empty. + */ + FASTDDS_EXPORTED_API static ReturnCode_t build_and_register_l_string_type_identifier( + const StringLTypeDefn& string, + const std::string& type_name, + bool wstring = false); + + /** + * @brief Register small sequence TypeIdentifier into TypeObjectRegistry. + * + * @param[in] plain_seq PlainSequenceSElemDefn union member to set. + * @param[in] type_name Type name to be registered. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given member is inconsistent + * (only in Debug build mode). + * @return ReturnCode_t RETCODE_OK if correctly registered in TypeObjectRegistry. + * RETCODE_BAD_PARAMETER if there is already another different TypeIdentifier registered with + * the given type_name. + * RETCODE_BAD_PARAMETER if type_name is empty. + */ + FASTDDS_EXPORTED_API static ReturnCode_t build_and_register_s_sequence_type_identifier( + const PlainSequenceSElemDefn& plain_seq, + const std::string& type_name); + + /** + * @brief Register large sequence TypeIdentifier into TypeObjectRegistry. + * + * @param[in] plain_seq PlainSequenceLElemDefn union member to set. + * @param[in] type_name Type name to be registered. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given member is inconsistent + * (only in Debug build mode). + * @return ReturnCode_t RETCODE_OK if correctly registered in TypeObjectRegistry. + * RETCODE_BAD_PARAMETER if there is already another different TypeIdentifier registered with + * the given type_name. + * RETCODE_BAD_PARAMETER if type_name is empty. + */ + FASTDDS_EXPORTED_API static ReturnCode_t build_and_register_l_sequence_type_identifier( + const PlainSequenceLElemDefn& plain_seq, + const std::string& type_name); + + /** + * @brief Register small array TypeIdentifier into TypeObjectRegistry. + * + * @param[in] plain_array PlainArraySElemDefn union member to set. + * @param[in] type_name Type name to be registered. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given member is inconsistent + * (only in Debug build mode). + * @return ReturnCode_t RETCODE_OK if correctly registered in TypeObjectRegistry. + * RETCODE_BAD_PARAMETER if there is already another different TypeIdentifier registered with + * the given type_name. + * RETCODE_BAD_PARAMETER if type_name is empty. + */ + FASTDDS_EXPORTED_API static ReturnCode_t build_and_register_s_array_type_identifier( + const PlainArraySElemDefn& plain_array, + const std::string& type_name); + + /** + * @brief Register large array TypeIdentifier into TypeObjectRegistry. + * + * @param[in] plain_array PlainArrayLElemDefn union member to set. + * @param[in] type_name Type name to be registered. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given member is inconsistent + * (only in Debug build mode). + * @return ReturnCode_t RETCODE_OK if correctly registered in TypeObjectRegistry. + * RETCODE_BAD_PARAMETER if there is already another different TypeIdentifier registered with + * the given type_name. + * RETCODE_BAD_PARAMETER if type_name is empty. + */ + FASTDDS_EXPORTED_API static ReturnCode_t build_and_register_l_array_type_identifier( + const PlainArrayLElemDefn& plain_array, + const std::string& type_name); + + /** + * @brief Register small map TypeIdentifier into TypeObjectRegistry. + * + * @param[in] plain_map PlainMapSTypeDefn union member to set. + * @param[in] type_name Type name to be registered. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given member is inconsistent + * (only in Debug build mode). + * @return ReturnCode_t RETCODE_OK if correctly registered in TypeObjectRegistry. + * RETCODE_BAD_PARAMETER if there is already another different TypeIdentifier registered with + * the given type_name. + * RETCODE_BAD_PARAMETER if type_name is empty. + */ + FASTDDS_EXPORTED_API static ReturnCode_t build_and_register_s_map_type_identifier( + const PlainMapSTypeDefn& plain_map, + const std::string& type_name); + + /** + * @brief Register large map TypeIdentifier into TypeObjectRegistry. + * + * @param[in] plain_map PlainMapLTypeDefn union member to set. + * @param[in] type_name Type name to be registered. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given member is inconsistent + * (only in Debug build mode). + * @return ReturnCode_t RETCODE_OK if correctly registered in TypeObjectRegistry. + * RETCODE_BAD_PARAMETER if there is already another different TypeIdentifier registered with + * the given type_name. + * RETCODE_BAD_PARAMETER if type_name is empty. + */ + FASTDDS_EXPORTED_API static ReturnCode_t build_and_register_l_map_type_identifier( + const PlainMapLTypeDefn& plain_map, + const std::string& type_name); + + /** + * @brief Register StronglyConnectedComponent TypeIdentifier into TypeObjectRegistry. + * + * @param[in] scc StronglyConnectedComponent union member to set. + * @param[in] type_name Type name to be registered. + * @return ReturnCode_t RETCODE_OK if correctly registered in TypeObjectRegistry. + * RETCODE_BAD_PARAMETER if there is already another different TypeIdentifier registered with + * the given type_name. + * RETCODE_BAD_PARAMETER if type_name is empty. + */ + FASTDDS_EXPORTED_API static ReturnCode_t build_and_register_scc_type_identifier( + const StronglyConnectedComponentId& scc, + const std::string& type_name); + + /*************** Annotation usage ***************************/ + /** + * @brief Build ExtendedAnnotationParameterValue instance (empty. Available for future extension). + * + * @return const ExtendedAnnotationParameterValue instance. + */ + FASTDDS_EXPORTED_API static const ExtendedAnnotationParameterValue build_extended_annotation_parameter_value(); + + /** + * @brief Build AnnotationParameterValue instance. + * + * @param[in] boolean_value Boolean value to set in the union. + * @return const AnnotationParameterValue instance. + */ + FASTDDS_EXPORTED_API static const AnnotationParameterValue build_annotation_parameter_value( + bool boolean_value); + + /** + * @brief Build AnnotationParameterValue instance. + * + * @param[in] byte_value Byte value to set in the union. + * @return const AnnotationParameterValue instance. + */ + FASTDDS_EXPORTED_API static const AnnotationParameterValue build_annotation_parameter_value_byte( + uint8_t byte_value); + + /** + * @brief Build AnnotationParameterValue instance. + * + * @param[in] int8_value Int8 value to set in the union. + * @return const AnnotationParameterValue instance. + */ + FASTDDS_EXPORTED_API static const AnnotationParameterValue build_annotation_parameter_value( + int8_t int8_value); + + /** + * @brief Build AnnotationParameterValue instance. + * + * @param[in] uint8_value Unsigned int8 value to set in the union. + * @return const AnnotationParameterValue instance. + */ + FASTDDS_EXPORTED_API static const AnnotationParameterValue build_annotation_parameter_value( + uint8_t uint8_value); + + /** + * @brief Build AnnotationParameterValue instance. + * + * @param[in] int16_value Short value to set in the union. + * @return const AnnotationParameterValue instance. + */ + FASTDDS_EXPORTED_API static const AnnotationParameterValue build_annotation_parameter_value( + int16_t int16_value); + + /** + * @brief Build AnnotationParameterValue instance. + * + * @param[in] uint16_value Unsigned short value to set in the union. + * @return const AnnotationParameterValue instance. + */ + FASTDDS_EXPORTED_API static const AnnotationParameterValue build_annotation_parameter_value( + uint16_t uint16_value); + + /** + * @brief Build AnnotationParameterValue instance. + * + * @param[in] int32_value Long value to set in the union. + * @return const AnnotationParameterValue instance. + */ + FASTDDS_EXPORTED_API static const AnnotationParameterValue build_annotation_parameter_value( + int32_t int32_value); + + /** + * @brief Build AnnotationParameterValue instance. + * + * @param[in] uint32_value Unsigned long value to set in the union. + * @return const AnnotationParameterValue instance. + */ + FASTDDS_EXPORTED_API static const AnnotationParameterValue build_annotation_parameter_value( + uint32_t uint32_value); + + /** + * @brief Build AnnotationParameterValue instance. + * + * @param[in] int64_value Long long value to set in the union. + * @return const AnnotationParameterValue instance. + */ + FASTDDS_EXPORTED_API static const AnnotationParameterValue build_annotation_parameter_value( + int64_t int64_value); + + /** + * @brief Build AnnotationParameterValue instance. + * + * @param[in] uint64_value Unsigned long long value to set in the union. + * @return const AnnotationParameterValue instance. + */ + FASTDDS_EXPORTED_API static const AnnotationParameterValue build_annotation_parameter_value( + uint64_t uint64_value); + + /** + * @brief Build AnnotationParameterValue instance. + * + * @param[in] float32_value Float value to set in the union. + * @return const AnnotationParameterValue instance. + */ + FASTDDS_EXPORTED_API static const AnnotationParameterValue build_annotation_parameter_value( + float float32_value); + + /** + * @brief Build AnnotationParameterValue instance. + * + * @param[in] float64_value Double value to set in the union. + * @return const AnnotationParameterValue instance. + */ + FASTDDS_EXPORTED_API static const AnnotationParameterValue build_annotation_parameter_value( + double float64_value); + + /** + * @brief Build AnnotationParameterValue instance. + * + * @param[in] float128_value Long double value to set in the union. + * @return const AnnotationParameterValue instance. + */ + FASTDDS_EXPORTED_API static const AnnotationParameterValue build_annotation_parameter_value( + long double float128_value); + + /** + * @brief Build AnnotationParameterValue instance. + * + * @param[in] char_value Char value to set in the union. + * @return const AnnotationParameterValue instance. + */ + FASTDDS_EXPORTED_API static const AnnotationParameterValue build_annotation_parameter_value( + char char_value); + + /** + * @brief Build AnnotationParameterValue instance. + * + * @param[in] wchar_value Wide char value to set in the union. + * @return const AnnotationParameterValue instance. + */ + FASTDDS_EXPORTED_API static const AnnotationParameterValue build_annotation_parameter_value( + wchar_t wchar_value); + + /** + * @brief Build AnnotationParameterValue instance. + * + * @param[in] enumerated_value Enumerated value to set in the union. + * @return const AnnotationParameterValue instance. + */ + FASTDDS_EXPORTED_API static const AnnotationParameterValue build_annotation_parameter_value_enum( + int32_t enumerated_value); + + /** + * @brief Build AnnotationParameterValue instance. + * + * @param[in] string8_value String value to set in the union. + * @return const AnnotationParameterValue instance. + */ + FASTDDS_EXPORTED_API static const AnnotationParameterValue build_annotation_parameter_value( + const eprosima::fastcdr::fixed_string<128>& string8_value); + + /** + * @brief Build AnnotationParameterValue instance. + * + * @param[in] string16_value Wide string value to set in the union. + * @return const AnnotationParameterValue instance. + */ + FASTDDS_EXPORTED_API static const AnnotationParameterValue build_annotation_parameter_value( + const std::wstring& string16_value); + + /** + * @brief Build AppliedAnnotationParameter instance. + * + * @param[in] paramname_hash Parameter name hash. + * @param[in] value Parameter value. + * @return const AppliedAnnotationParameter instance. + */ + FASTDDS_EXPORTED_API static const AppliedAnnotationParameter build_applied_annotation_parameter( + const NameHash& paramname_hash, + const AnnotationParameterValue& value); + + /** + * @brief Add AppliedAnnotationParameter to the sequence. + * + * @param[in out] param_seq AppliedAnnotationParameter sequence to be modified. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the parameter being added has + * already been included in the sequence. + * @param[in] param AppliedAnnotationParameter to be added. + */ + FASTDDS_EXPORTED_API static void add_applied_annotation_parameter( + AppliedAnnotationParameterSeq& param_seq, + const AppliedAnnotationParameter& param); + + /** + * @brief Build AppliedAnnotation instance. + * + * @param[in] annotation_typeid Annotation TypeIdentifier. + * @param[in] param_seq Annotation parameters. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if: + * 1. Given annotation_typeid TypeIdentifier does not correspond to an annotation TypeObject (only in + * Debug build mode). + * 2. Given AppliedAnnotationParameterSeq is inconsistent (only in Debug build mode). + * 3. Given annotation TypeIdentifier corresponds to a builtin annotation and the given parameters are + * inconsistent (only in Debug build mode). + * @return const AppliedAnnotation instance. + */ + FASTDDS_EXPORTED_API static const AppliedAnnotation build_applied_annotation( + const TypeIdentifier& annotation_typeid, + const eprosima::fastcdr::optional& param_seq); + + /** + * @brief Add AppliedAnnotation to the sequence. + * + * @param[in out] ann_custom_seq AppliedAnnotation sequence to be modified. + * @param[in] ann_custom AppliedAnnotation to be added. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if: + * 1. Given AppliedAnnotation is not consistent (only in Debug build mode). + * 2. Given AppliedAnnotation is already present in the sequence. + */ + FASTDDS_EXPORTED_API static void add_applied_annotation( + AppliedAnnotationSeq& ann_custom_seq, + const AppliedAnnotation& ann_custom); + + /** + * @brief Build AppliedVerbatimAnnotation instance. + * + * @param[in] placement Verbatim annotation placement parameter. + * @param[in] language Verbatim annotation language parameter. + * @param[in] text Verbatim annotation text parameter. + * @return const AppliedVerbatimAnnotation instance. + */ + FASTDDS_EXPORTED_API static const AppliedVerbatimAnnotation build_applied_verbatim_annotation( + PlacementKind placement, + const eprosima::fastcdr::fixed_string<32>& language, + const std::string& text); + + /*************** Aggregate types: ***************************/ + /** + * @brief Build AppliedBuiltinMemberAnnotations instance. + * + * @param[in] unit Unit annotation value. + * @param[in] min Min annotation value. + * @param[in] max Max annotation value. + * @param[in] hash_id Hashid annotation value. + * @return const AppliedBuiltinMemberAnnotations instance. + */ + FASTDDS_EXPORTED_API static const AppliedBuiltinMemberAnnotations build_applied_builtin_member_annotations( + const eprosima::fastcdr::optional& unit, + const eprosima::fastcdr::optional& min, + const eprosima::fastcdr::optional& max, + const eprosima::fastcdr::optional& hash_id); + + /** + * @brief Build CommonStructMember instance. + * + * @param[in] member_id Member identifier. + * @param[in] member_flags Member flags: optional, must_understand, key, and external. + * @param[in] member_type_id Member TypeIdentifier. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception: + * 1. The given flags are not consistent (only in Debug build mode). + * 2. The given TypeIdentifier is not consistent (only in Debug build mode). + * @return const CommonStructMember instance. + */ + FASTDDS_EXPORTED_API static const CommonStructMember build_common_struct_member( + MemberId member_id, + StructMemberFlag member_flags, + const TypeIdentifier& member_type_id); + + /** + * @brief Build CompleteMemberDetail instance. + * + * @param[in] name Member name. + * @param[in] ann_builtin Member builtin annotations. + * @param[in] ann_custom Member custom annotations. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if: + * 1. Empty member name. + * 2. Given AppliedAnnotationSeq is not consistent (only Debug build mode). + * @return const CompleteMemberDetail instance. + */ + FASTDDS_EXPORTED_API static const CompleteMemberDetail build_complete_member_detail( + const MemberName& name, + const eprosima::fastcdr::optional& ann_builtin, + const eprosima::fastcdr::optional& ann_custom); + + /** + * MinimalMemberDetail constructed from CompleteMemberDetail + */ + + /** + * @brief Build CompleteStructMember instance. + * + * @param[in] common CommonStructMember to be set. + * @param[in] detail CompleteMemberDetail to be set. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if: + * 1. Given CommonStructMember is inconsistent (only Debug build mode). + * 2. Given CompleteMemberDetail is inconsistent (only Debug build mode). + * @return const CompleteMemberDetail instance. + */ + FASTDDS_EXPORTED_API static const CompleteStructMember build_complete_struct_member( + const CommonStructMember& common, + const CompleteMemberDetail& detail); + + /** + * @brief Add CompleteStructMember to the sequence. + * + * @param[in out] member_seq CompleteStructMember sequence to be modified. + * @param[in] member CompleteStructMember to be added. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if: + * 1. Given CompleteStructMember is not consistent (only in Debug build mode). + * 2. There is already another member in the sequence with the same member id or the same member name + * (only in Debug build mode). + */ + FASTDDS_EXPORTED_API static void add_complete_struct_member( + CompleteStructMemberSeq& member_seq, + const CompleteStructMember& member); + + /** + * MinimalStructMember constructed from CompleteStructMember + */ + + /** + * @brief Build AppliedBuiltinTypeAnnotations instance. + * + * @param[in] verbatim AppliedVerbatimAnnotation to be set. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given verbatim annotation + * is inconsistent (only in Debug build mode). + * @return const AppliedBuiltinTypeAnnotations instance. + */ + FASTDDS_EXPORTED_API static const AppliedBuiltinTypeAnnotations build_applied_builtin_type_annotations( + const eprosima::fastcdr::optional& verbatim); + + /** + * MinimalTypeDetail constructed from CompleteTypeDetail: empty. Available for future extension. + */ + + /** + * @brief Build CompleteTypeDetail instance. + * + * @param[in] ann_builtin Verbatim annotation. + * @param[in] ann_custom Applied annotations. + * @param[in] type_name Name of the type. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if: + * 1. Given type_name is empty. + * 2. any applied annotation is not consistent (only Debug build mode). + * @return const CompleteTypeDetail instance. + */ + FASTDDS_EXPORTED_API static const CompleteTypeDetail build_complete_type_detail( + const eprosima::fastcdr::optional& ann_builtin, + const eprosima::fastcdr::optional& ann_custom, + const QualifiedTypeName& type_name); + + /** + * @brief Build CompleteStructHeader instance. + * + * @param[in] base_type TypeIdentifier of the parent structure (inheritance). + * @param[in] detail CompleteTypeDetail. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if: + * 1. Given TypeIdentifier is not consistent (direct HASH or empty TypeIdentifier). In Debug build + * mode the corresponding TypeObject is also checked in case of direct HASH TypeIdentifier. + * 2. Given CompleteTypeDetail is not consistent (only in Debug build mode). + * @return const CompleteStructHeader instance. + */ + FASTDDS_EXPORTED_API static const CompleteStructHeader build_complete_struct_header( + const TypeIdentifier& base_type, + const CompleteTypeDetail& detail); + + /** + * MinimalStructHeader constructed from CompleteStructHeader. + */ + + /** + * @brief Build CompleteStructType instance. + * + * @param[in] struct_flags StructTypeFlags. + * @param[in] header CompleteStructHeader. + * @param[in] member_seq Sequence of CompleteStructMembers. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if: + * 1. Given StructTypeFlag is not consistent (only in Debug build mode). + * 2. Given CompleteStructHeader is not consistent (only in Debug build mode). + * 3. Given CompleteStructMemberSeq is not consistent (only in Debug build mode). + * 4. Given flags are not consistent with the builtin annotations. + * @return const CompleteStructType instance. + */ + FASTDDS_EXPORTED_API static const CompleteStructType build_complete_struct_type( + StructTypeFlag struct_flags, + const CompleteStructHeader& header, + const CompleteStructMemberSeq& member_seq); + + /** + * MinimalStructType constructed from CompleteStructType. + */ + + /*************** Union: *********************************************/ + + /** + * @brief Add label to the union case label sequence. + * + * @param[in out] label_seq Sequence to be modified. + * @param[in] label Label to be added. + */ + FASTDDS_EXPORTED_API static void add_union_case_label( + UnionCaseLabelSeq& label_seq, + int32_t label); + + /** + * @brief Build CommonUnionMember instance. + * + * @param[in] member_id Member identifier. + * @param[in] member_flags Member flags. + * @param[in] type_id Member TypeIdentifier. + * @param[in] label_seq Member applicable case labels. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if: + * 1. Given UnionMemberFlags are not consistent (only Debug build mode). + * 2. Given TypeIdentifier is not consistent (only Debug build mode). + * @return const CommonUnionMember instance. + */ + FASTDDS_EXPORTED_API static const CommonUnionMember build_common_union_member( + MemberId member_id, + UnionMemberFlag member_flags, + const TypeIdentifier& type_id, + const UnionCaseLabelSeq& label_seq); + + /** + * @brief Build CompleteUnionMember instance. + * + * @param[in] common CommonUnionMember. + * @param[in] detail CompleteMemberDetail. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if: + * 1. Given CommonUnionMember is not consistent (only in Debug build mode). + * 2. Given CompleteMemberDetail is not consistent (only in Debug build mode). + * @return const CompleteUnionMember instance. + */ + FASTDDS_EXPORTED_API static const CompleteUnionMember build_complete_union_member( + const CommonUnionMember& common, + const CompleteMemberDetail& detail); + + /** + * @brief Add CompleteUnionMember to sequence. + * + * @param[in out] complete_union_member_seq Sequence to be modified. + * @param[in] member Complete union member to be added. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if: + * 1. Given CompleteUnionMember is not consistent (only in Debug build mode). + * 2. There is already another member in the sequence with the same member id or the same member name + * (only in Debug build mode). + * 3. If the given member is marked as default, if there is already another member marked as default + * (only in Debug build mode). + * 4. There are repeated union case labels (only in Debug build mode). + * 5. Member name is protected ("discriminator"). + */ + FASTDDS_EXPORTED_API static void add_complete_union_member( + CompleteUnionMemberSeq& complete_union_member_seq, + const CompleteUnionMember& member); + + /** + * MinimalUnionMember constructed from CompleteUnionMember. + */ + + /** + * @brief Build CommonDiscriminatorMember instance. + * + * @param[in] member_flags Discriminator flags. + * @param[in] type_id Discriminator TypeIdentifier. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if: + * 1. Given discriminator flags are inconsistent (only in Debug build mode). + * 2. Given TypeIdentifier is not consistent. + * XTypes v1.3 Clause 7.2.2.4.4.3 The discriminator of a union must be one of the following types: + * Boolean, Byte, Char8, Char16, Int8, Uint8, Int16, Uint16, Int32, Uint32, Int64, Uint64, any + * enumerated type, any alias type that resolves, directly or indirectly, to one of the + * aforementioned types. + * @return const CommonDiscriminatorMember instance. + */ + FASTDDS_EXPORTED_API static const CommonDiscriminatorMember build_common_discriminator_member( + UnionDiscriminatorFlag member_flags, + const TypeIdentifier& type_id); + + /** + * @brief Build CompleteDiscriminatorMember instance. + * + * @param[in] common CommonDiscriminatorMember. + * @param[in] ann_builtin Verbatim annotation. + * @param[in] ann_custom Applied annotations. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if: + * 1. Given CommonDiscriminatorMember is inconsistent (only in Debug build mode). + * 2. AppliedBuiltinTypeAnnotation is inconsistent (only in Debug build mode). + * 3. Any given AppliedAnnotation is inconsistent (only in Debug build mode). + * 4. CommonDiscriminatorMember is inconsistent with given builtin annotations. + * @return const CompleteDiscriminatorMember instance. + */ + FASTDDS_EXPORTED_API static const CompleteDiscriminatorMember build_complete_discriminator_member( + const CommonDiscriminatorMember& common, + const eprosima::fastcdr::optional& ann_builtin, + const eprosima::fastcdr::optional& ann_custom); + + /** + * MinimalDiscriminatorMember constructed from CompleteDiscriminatorMember. + */ + + /** + * @brief Build CompleteUnionHeader instance. + * + * @param detail CompleteTypeDetail. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given CompleteTypeDetail is + * not consistent (only in Debug build mode). + * @return const CompleteUnionHeader instance. + */ + FASTDDS_EXPORTED_API static const CompleteUnionHeader build_complete_union_header( + const CompleteTypeDetail& detail); + + /** + * MinimalUnionHeader constructed from CompleteUnionHeader. + */ + + /** + * @brief Build CompleteUnionType instance. + * + * @param[in] union_flags + * @param[in] header + * @param[in] discriminator + * @param[in] member_seq + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if: + * 1. Given UnionTypeFlags are not consistent (only in Debug build mode). + * 2. Given CompleteUnionHeader is not consistent (only in Debug build mode). + * 3. Given CompleteDiscriminatorMember inconsistent (only in Debug build mode). + * 4. Given CompleteUnionMemberSeq is not consistent (only in Debug build mode). + * 5. Given flags are not consistent with the builtin annotations. + * @return const CompleteUnionType instance. + */ + FASTDDS_EXPORTED_API static const CompleteUnionType build_complete_union_type( + UnionTypeFlag union_flags, + const CompleteUnionHeader& header, + const CompleteDiscriminatorMember& discriminator, + const CompleteUnionMemberSeq& member_seq); + + /** + * MinimalUnionType constructed from CompleteUnionType. + */ + + /*************** Annotation: ****************************************/ + + /** + * @brief Build CommonAnnotationParameter instance. + * + * @param[in] member_flags AnnotationParameterFlag: empty. No flags apply. It must be zero. + * @param[in] member_type_id Member TypeIdentifier. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if: + * 1. Given AnnotationParameterFlag are not empty. + * 2. Given TypeIdentifier is not consistent (only in Debug build mode). + * @return const CommonAnnotationParameter instance. + */ + FASTDDS_EXPORTED_API static const CommonAnnotationParameter build_common_annotation_parameter( + AnnotationParameterFlag member_flags, + const TypeIdentifier& member_type_id); + + /** + * @brief Build CompleteAnnotationParameter instance. + * + * @param[in] common CommonAnnotationParameter. + * @param[in] name Member name. + * @param[in] default_value Annotation default value. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if: + * 1. Given CommonAnnotationParameter is inconsistent (only in Debug build mode). + * 2. CommonAnnotationParameter TypeIdentifier is inconsistent with AnnotationParameterValue type. + * 3. Given parameter name is empty. + * @return const CompleteAnnotationParameter instance. + */ + FASTDDS_EXPORTED_API static const CompleteAnnotationParameter build_complete_annotation_parameter( + const CommonAnnotationParameter& common, + const MemberName& name, + const AnnotationParameterValue& default_value); + + /** + * @brief Add CompleteAnnotationParameter to sequence. + * + * @param[in out] sequence Sequence to be modified. + * @param[in] param Complete annotation parameter to be added. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if: + * 1. Given CompleteAnnotationParameter is not consistent (only in Debug build mode). + * 2. There is already another member in the sequence with the same member id or the same member name + * (only in Debug build mode). + */ + FASTDDS_EXPORTED_API static void add_complete_annotation_parameter( + CompleteAnnotationParameterSeq& sequence, + const CompleteAnnotationParameter& param); + + /** + * MinimalAnnotationParameter constructed from CompleteAnnotationParameter. + */ + + /** + * @brief Build CompleteAnnotationHeader instance. + * + * @param[in] annotation_name Qualified annotation type name. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError if the annotation_name is empty. + * @return const CompleteAnnotationHeader instance. + */ + FASTDDS_EXPORTED_API static const CompleteAnnotationHeader build_complete_annotation_header( + const QualifiedTypeName& annotation_name); + + /** + * MinimalAnnotationHeader constructed from CompleteAnnotationHeader: empty. Available for future extension. + */ + + /** + * @brief Build CompleteAnnotationType instance. + * + * @param[in] annotation_flag Unused. No flags apply. It must be 0. + * @param[in] header CompleteAnnotationHeader. + * @param[in] member_seq CompleteAnnotationParameter sequence. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if: + * 1. Any annotation flag is set. + * 2. Given header is inconsistent (only in Debug build mode). + * 3. Any CompleteAnnotationParameter in the sequence is inconsistent (only in Debug build mode). + * @return const CompleteAnnotationType instance. + */ + FASTDDS_EXPORTED_API static const CompleteAnnotationType build_complete_annotation_type( + AnnotationTypeFlag annotation_flag, + const CompleteAnnotationHeader& header, + const CompleteAnnotationParameterSeq& member_seq); + + /** + * MinimalAnnotationType constructed from CompleteAnnotationType. + */ + + /*************** Alias: *********************************************/ + + /** + * @brief Build CommonAliasBody instance. + * + * @param[in] related_flags AliasMemberFlag: unused. No flags apply. It must be 0. + * @param[in] related_type Related TypeIdentifier. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if: + * 1. Any alias member flag is set. + * 2. Non-consistent TypeIdentifier (only in Debug build mode). + * @return const CommonAliasBody instance. + */ + FASTDDS_EXPORTED_API static const CommonAliasBody build_common_alias_body( + AliasMemberFlag related_flags, + const TypeIdentifier& related_type); + + /** + * @brief Build CompleteAliasBody instance. + * + * @param[in] common CommonAliasBody. + * @param[in] ann_builtin Applied builtin member annotations: unit, max, min, range, hashid + * @param[in] ann_custom Applied custom annotations + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if: + * 1. Given CommonAliasBody is inconsistent (only Debug build mode). + * 2. AppliedAnnotationSeq is inconsistent (only Debug build mode). + * 3. hashid builtin annotation is set. + * @return const CompleteAliasBody instance. + */ + FASTDDS_EXPORTED_API static const CompleteAliasBody build_complete_alias_body( + const CommonAliasBody& common, + const eprosima::fastcdr::optional& ann_builtin, + const eprosima::fastcdr::optional& ann_custom); + + /** + * MinimalAliasBody constructed from CompleteAliasBody. + */ + + /** + * @brief Build CompleteAliasHeader instance. + * + * @param[in] detail Complete type detail. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given CompleteTypeDetail is + * inconsistent (only in Debug build mode). + * @return const CompleteAliasHeader instance. + */ + FASTDDS_EXPORTED_API static const CompleteAliasHeader build_complete_alias_header( + const CompleteTypeDetail& detail); + + /** + * MinimalAliasHeader constructed from CompleteAliasHeader: empty. Available for future extension. + */ + + /** + * @brief Build CompleteAliasType instance. + * + * @param[in] alias_flags Alias type flags: unused. No flags apply. It must be zero. + * @param[in] header CompleteAliasHeader. + * @param[in] body CompleteAliasBody. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if: + * 1. Any alias type flag is set. + * 2. Inconsistent header and/or body (only in Debug build mode). + * @return const CompleteAliasType instance. + */ + FASTDDS_EXPORTED_API static const CompleteAliasType build_complete_alias_type( + AliasTypeFlag alias_flags, + const CompleteAliasHeader& header, + const CompleteAliasBody& body); + + /** + * MinimalAliasType constructed from CompleteAliasType. + */ + + /*************** Collections: ***************************************/ + + /** + * @brief Build CompleteElementDetail instance. + * + * @param[in] ann_builtin Applied builtin member annotations: unit, max, min, range, hashid + * @param[in] ann_custom Applied custom annotations + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if: + * 1. AppliedAnnotationSeq is inconsistent (only Debug build mode). + * 2. hashid builtin annotation is applied. + * @return const CompleteElementDetail instance. + */ + FASTDDS_EXPORTED_API static const CompleteElementDetail build_complete_element_detail( + const eprosima::fastcdr::optional& ann_builtin, + const eprosima::fastcdr::optional& ann_custom); + + /** + * @brief Build CommonCollectionElement instance. + * + * @param[in] element_flags CollectionElementFlag. + * @param[in] type TypeIdentifier. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if: + * 1. Given collection element flags are not consistent (only in Debug build mode). + * 2. Given TypeIdentifier is not consistent (only in Debug build mode). + * @return const CommonCollectionElement instance + */ + FASTDDS_EXPORTED_API static const CommonCollectionElement build_common_collection_element( + CollectionElementFlag element_flags, + const TypeIdentifier& type); + + /** + * @brief Build CompleteCollectionElement instance. + * + * @param[in] common CommonCollectionElement. + * @param[in] detail CompleteElementDetail. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if: + * 1. Given CommonCollectionElement is not consistent (only in Debug build mode). + * 2. Given CompleteElementDetail is not consistent (only in Debug build mode). + * @return const CompleteCollectionElement instance + */ + FASTDDS_EXPORTED_API static const CompleteCollectionElement build_complete_collection_element( + const CommonCollectionElement& common, + const CompleteElementDetail& detail); + + /** + * MinimalCollectionElement constructed from CompleteCollectionElement. + */ + + /** + * @brief Build CommonCollectionHeader instance. + * + * @param[in] bound Collection bound. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given bound is not + * consistent. + * @return const CommonCollectionHeader instance. + */ + FASTDDS_EXPORTED_API static const CommonCollectionHeader build_common_collection_header( + LBound bound); + + /** + * @brief Build CompleteCollectionHeader instance. + * + * @param[in] common CommonCollectionHeader + * @param[in] detail CompleteTypeDetail + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if: + * 1. Given CommonCollectionHeader is inconsistent (only in Debug build mode). + * 2. Given CompleteTypeDetail is inconsistent (only in Debug build mode). + * @return const CompleteCollectionHeader instance. + */ + FASTDDS_EXPORTED_API static const CompleteCollectionHeader build_complete_collection_header( + const CommonCollectionHeader& common, + const eprosima::fastcdr::optional& detail); + + /** + * MinimalCollectionHeader constructed from CompleteCollectionHeader. + */ + + /*************** Sequence: ******************************************/ + + /** + * @brief Build CompleteSequenceType instance. + * + * @param[in] collection_flag collection type flag: unused. No flags apply. It must be 0. + * @param[in] header CompleteCollectionHeader. + * @param[in] element CompleteCollectionElement. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if: + * 1. Any collection flag is set. + * 2. Given header is inconsistent (only in Debug build mode). + * 3. Given element is inconsistent (only in Debug build mode). + * @return const CompleteSequenceType instance + */ + FASTDDS_EXPORTED_API static const CompleteSequenceType build_complete_sequence_type( + CollectionTypeFlag collection_flag, + const CompleteCollectionHeader& header, + const CompleteCollectionElement& element); + + /** + * MinimalSequenceType constructed from CompleteSequenceType. + */ + + /*************** Array: *********************************************/ + + /** + * @brief Build CommonArrayHeader instance. + * + * @param[in] bound_seq Sequence of the dimension's bounds. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if any given bound is 0 (invalid). + * @return const CommonArrayHeader instance. + */ + FASTDDS_EXPORTED_API static const CommonArrayHeader build_common_array_header( + const LBoundSeq& bound_seq); + + /** + * @brief Build CompleteArrayHeader instance. + * + * @param[in] common CommonArrayHeader. + * @param[in] detail CompleteTypeDetail. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if: + * 1. Given CommonArrayHeader is inconsistent (only in Debug build mode). + * 2. Given CompleteTypeDetail is inconsistent (only in Debug build mode). + * @return const CompleteArrayHeader instance. + */ + FASTDDS_EXPORTED_API static const CompleteArrayHeader build_complete_array_header( + const CommonArrayHeader& common, + const CompleteTypeDetail& detail); + + /** + * MinimalArrayHeader constructed from CompleteArrayHeader. + */ + + /** + * @brief Build CompleteArrayType instance. + * + * @param[in] collection_flag collection type flag: unused. No flags apply. It must be 0. + * @param[in] header CompleteArrayHeader. + * @param[in] element CompleteCollectionElement. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if: + * 1. Any collection flag is set. + * 2. Given header is inconsistent (only in Debug build mode). + * 3. Given element is inconsistent (only in Debug build mode). + * @return const CompleteArrayType instance. + */ + FASTDDS_EXPORTED_API static const CompleteArrayType build_complete_array_type( + CollectionTypeFlag collection_flag, + const CompleteArrayHeader& header, + const CompleteCollectionElement& element); + + /** + * MinimalArrayType constructed from CompleteArrayType. + */ + + /*************** Map: ***********************************************/ + + /** + * @brief Build CompleteMapType instance. + * + * @param[in] collection_flag collection type flag: unused. No flags apply. It must be 0. + * @param[in] header CompleteArrayHeader. + * @param[in] key CompleteCollectionElement describing map key. + * @param[in] element CompleteCollectionElement describing map element. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if: + * 1. Any collection flag is set. + * 2. Given header is inconsistent (only in Debug build mode). + * 3. Given key TypeIdentifier is inconsistent. + * 4. Given key description is inconsistent (only in Debug build mode). + * 5. Given element is inconsistent (only in Debug build mode). + * @return const CompleteMapType instance. + */ + FASTDDS_EXPORTED_API static const CompleteMapType build_complete_map_type( + CollectionTypeFlag collection_flag, + const CompleteCollectionHeader& header, + const CompleteCollectionElement& key, + const CompleteCollectionElement& element); + + /** + * MinimalMapType constructed from CompleteMapType. + */ + + /*************** Enumeration: **************************************/ + + /** + * @brief Build CommonEnumeratedLiteral instance. + * + * @param[in] value Enumerated literal value. + * @param[in] flags Enumerated literal flags: only default flag apply. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if any other flag different from + * default is set (only in Debug build mode). + * @return const CommonEnumeratedLiteral instance. + */ + FASTDDS_EXPORTED_API static const CommonEnumeratedLiteral build_common_enumerated_literal( + int32_t value, + EnumeratedLiteralFlag flags); + + /** + * @brief Build CompleteEnumeratedLiteral instance. + * + * @param[in] common CommonEnumeratedLiteral. + * @param[in] detail CompleteMemberDetail. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if: + * 1. Given CommonEnumeratedLiteral is inconsistent (only in Debug build mode). + * 2. Given CompleteMemberDetail is inconsistent (only in Debug build mode). + * @return const CompleteEnumeratedLiteral instance. + */ + FASTDDS_EXPORTED_API static const CompleteEnumeratedLiteral build_complete_enumerated_literal( + const CommonEnumeratedLiteral& common, + const CompleteMemberDetail& detail); + + /** + * @brief Add CompleteEnumeratedLiteral to sequence. + * + * @param[in] sequence Sequence to be modified. + * @param[in out] enum_literal CompleteEnumeratedLiteral to be added. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if: + * 1. Given CommonEnumeratedLiteral is not consistent (only in Debug build mode). + * 2. There is already another literal in the sequence with the same value or the same member name + * (only in Debug build mode). + */ + FASTDDS_EXPORTED_API static void add_complete_enumerated_literal( + CompleteEnumeratedLiteralSeq& sequence, + const CompleteEnumeratedLiteral& enum_literal); + + /** + * MinimalEnumeratedLiteral constructed from CompleteEnumeratedLiteral. + */ + + /** + * @brief Build CommonEnumeratedHeader instance. + * + * @param[in] bit_bound XTypes v1.3 Clause 7.3.1.2.1.5 It is important to note that the value member of the + * [bit_bound] annotation may take any value from 1 to 32, inclusive, when this annotation is + * applied to an enumerated type. + * @param[in] bitmask Flag in case that the header being built corresponds to a Bitmask. By default is false. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given bit_bound is not + * consistent. + * @return const CommonEnumeratedHeader instance. + */ + FASTDDS_EXPORTED_API static const CommonEnumeratedHeader build_common_enumerated_header( + BitBound bit_bound, + bool bitmask = false); + + /** + * @brief Build CompleteEnumeratedHeader instance. + * + * @param[in] common CommonEnumeratedHeader. + * @param[in] detail CompleteTypeDetail. + * @param[in] bitmask flag set if the given header corresponds to a bitmask. Only required in Debug build mode. + * Set to false by default. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if: + * 1. Given CommonEnumeratedHeader is inconsistent (only in Debug build mode). + * 2. Given CompleteTypeDetail is inconsistent (only in Debug build mode). + * @return const CompleteEnumeratedHeader instance. + */ + FASTDDS_EXPORTED_API static const CompleteEnumeratedHeader build_complete_enumerated_header( + const CommonEnumeratedHeader& common, + const CompleteTypeDetail& detail, + bool bitmask = false); + + /** + * MinimalEnumeratedHeader constructed from CompleteEnumeratedHeader. + */ + + /** + * @brief Build CompleteEnumeratedType instance. + * + * @param[in] enum_flags Enumeration flags: unused. No flags apply. It must be 0. + * @param[in] header CompleteEnumeratedHeader. + * @param[in] literal_seq Sequence of CompleteEnumeratedLiterals. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if: + * 1. Any flag is set. + * 2. Given CompleteEnumeratedHeader is inconsistent (only in Debug build mode). + * 3. Given CompleteEnumeratedLiteralSeq is inconsistent (only in Debug build mode). + * @return const CompleteEnumeratedType instance. + */ + FASTDDS_EXPORTED_API static const CompleteEnumeratedType build_complete_enumerated_type( + EnumTypeFlag enum_flags, + const CompleteEnumeratedHeader& header, + const CompleteEnumeratedLiteralSeq& literal_seq); + + /** + * MinimalEnumeratedType constructed from CompleteEnumeratedType. + */ + + /*************** Bitmask: *******************************************/ + + /** + * @brief Build CommonBitflag instance. + * + * @param[in] position Bit position in the bitmask. + * @param[in] flags Bit flags: unused. No flags apply. It must be 0. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if: + * 1. any given flag is set. + * 2. given position is inconsistent. XTypes v1.3 Clause 7.2.2.4.1.2 Each bit in this subset is + * identified by name and by an index, numbered from 0 to (bound-1). The bound must be greater than + * zero and no greater than 64. + * @return const CommonBitflag instance. + */ + FASTDDS_EXPORTED_API static const CommonBitflag build_common_bitflag( + uint16_t position, + BitflagFlag flags); + + /** + * @brief Build CompleteBitflag instance. + * + * @param[in] common CommonBitflag. + * @param[in] detail CompleteMemberDetail. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if: + * 1. Given CommonBitflag is inconsistent (only in Debug build mode). + * 2. Given CompleteMemberDetail is inconsistent (only in Debug build mode). + * 3. Non-applicable builtin annotations applied. + * @return const CompleteBitflag instance. + */ + FASTDDS_EXPORTED_API static const CompleteBitflag build_complete_bitflag( + const CommonBitflag& common, + const CompleteMemberDetail& detail); + + /** + * @brief Add complete bitflag to the sequence. + * + * @param[in out] sequence Sequence to be modified. + * @param[in] bitflag CompleteBitflag to be added. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if: + * 1. Given bitflag is inconsistent (only in Debug build mode). + * 2. There is already another bitflag in the sequence with the same position or the same name + * (only in Debug build mode). + */ + FASTDDS_EXPORTED_API static void add_complete_bitflag( + CompleteBitflagSeq& sequence, + const CompleteBitflag& bitflag); + + /** + * MinimalBitflag constructed from CompleteBitflag. + */ + + /** + * CommonBitmaskHeader is not used. + * CompleteBitmaskHeader is defined as CompleteEnumeratedHeader. + * MinimalBitmaskHeader is defined as MinimalEnumeratedHeader. + */ + + /** + * @brief Build CompleteBitmaskType instance. + * + * @param[in] bitmask_flags Bitmask flags: unused. No flags apply. It must be 0. + * @param[in] header CompleteBitmaskHeader/CompleteEnumeratedHeader + * @param[in] flag_seq Sequence of CompleteBitflag. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if: + * 1. any given flag is set. + * 2. Given header is inconsistent (only in Debug build mode). + * 3. Given Bitflag sequence is inconsistent (only in Debug build mode). + * @return const CompleteBitmaskType instance. + */ + FASTDDS_EXPORTED_API static const CompleteBitmaskType build_complete_bitmask_type( + BitmaskTypeFlag bitmask_flags, + const CompleteBitmaskHeader& header, + const CompleteBitflagSeq& flag_seq); + + /*************** Bitset: ********************************************/ + + /** + * @brief Build CommonBitfield instance. + * + * @param[in] position Bitfield starting position bit. + * @param[in] flags Bitfield flags: unused. No flags apply. It must be 0. + * @param[in] bitcount Bitfield number of bits. IDL v4.2 Clause 7.4.13.4.3.2 The first one (positive_int_const) is + * the number of bits that can be stored (its [bitfield] size). The maximum value is 64. + * @param[in] holder_type Type used to manipulate the bitfield. IDL v4.2 Clause 7.4.13.4.3.2 The second optional one + * (destination_type) specifies the type that will be used to manipulate the bit field as a + * whole. This type can be boolean, octet or any integer type either signed or unsigned. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if: + * 1. Given position is not consistent. + * 2. Any flag is set. + * 3. Given bitcount is not consistent. + * 4. Given holder_type is not consistent. + * @return const CommonBitfield instance. + */ + FASTDDS_EXPORTED_API static const CommonBitfield build_common_bitfield( + uint16_t position, + BitsetMemberFlag flags, + uint8_t bitcount, + TypeKind holder_type); + + /** + * @brief Build CompleteBitfield instance. + * + * @param[in] common CommonBitfield. + * @param[in] detail CompleteMemberDetail. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if: + * 1. Given CommonBitfield is inconsistent (only Debug build mode). + * 2. Give CompleteMemberDetail is inconsistent (only Debug build mode). + * 3. Non-applicable builtin annotations are applied. + * @return const CompleteBitfield instance. + */ + FASTDDS_EXPORTED_API static const CompleteBitfield build_complete_bitfield( + const CommonBitfield& common, + const CompleteMemberDetail& detail); + + /** + * @brief Add complete bitfield to the sequence. + * + * @param[in out] sequence Sequence to be modified. + * @param[in] bitfield CompleteBitfield to be added. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if: + * 1. Given bitfield is inconsistent (only in Debug build mode). + * 2. There is another bitfield with the same name and/or the same position. + */ + FASTDDS_EXPORTED_API static void add_complete_bitfield( + CompleteBitfieldSeq& sequence, + const CompleteBitfield& bitfield); + + /** + * MinimalBitfield constructed from CompleteBitfield. + */ + + /** + * @brief Build CompleteBitsetHeader instance. + * + * @param[in] detail CompleteTypeDetail + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given CompleteTypeDetail is + * inconsistent (only in Debug build mode). + * @return const CompleteBitsetHeader instance. + */ + FASTDDS_EXPORTED_API static const CompleteBitsetHeader build_complete_bitset_header( + const CompleteTypeDetail& detail); + + /** + * MinimalBitsetHeader constructed from CompleteBitsetHeader. + */ + + /** + * @brief Build CompleteBitsetType instance. + * + * @param[in] bitset_flags Bitset flags: unused. No flags apply. It must be 0. + * @param[in] header CompleteBitsetHeader. + * @param[in] field_seq Sequence of complete bitfields. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if: + * 1. Any given flag is set. + * 2. Given header is inconsistent (only in Debug build mode). + * 3. Given bitfield sequence is inconsistent (only in Debug build mode). + * @return const CompleteBitsetType instance. + */ + FASTDDS_EXPORTED_API static const CompleteBitsetType build_complete_bitset_type( + BitsetTypeFlag bitset_flags, + const CompleteBitsetHeader& header, + const CompleteBitfieldSeq& field_seq); + + /** + * MinimalBitsetType constructed from CompleteBitsetType. + */ + + /*************** Type Object: ***************************************/ + + /** + * @brief Build CompleteExtendedType instance. (empty. Available for future extension) + * + * @return const CompleteExtendedType instance. + */ + FASTDDS_EXPORTED_API static const CompleteExtendedType build_complete_extended_type(); + + /** + * @brief Register alias TypeObject into TypeObjectRegistry. + * CompleteAliasType is provided and the minimal TypeObject is constructed from the complete one. + * + * @param[in] alias_type CompleteAliasType. + * @param[in] type_name Name to be registered in the registry. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given type is inconsistent + * (only in Debug build mode). + * @return ReturnCode_t RETCODE_OK if correctly registered in TypeObjectRegistry. + * RETCODE_BAD_PARAMETER if there is already another different TypeObject registered with + * the given type_name. + * RETCODE_BAD_PARAMETER if type_name is empty. + */ + FASTDDS_EXPORTED_API static ReturnCode_t build_and_register_alias_type_object( + const CompleteAliasType& alias_type, + const std::string& type_name); + + /** + * @brief Register annotation TypeObject into TypeObjectRegistry. + * CompleteAnnotationType is provided and the minimal TypeObject is constructed from the complete one. + * + * @param[in] annotation_type CompleteAnnotationType. + * @param[in] type_name Name to be registered in the registry. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given type is inconsistent + * (only in Debug build mode). + * @return ReturnCode_t RETCODE_OK if correctly registered in TypeObjectRegistry. + * RETCODE_BAD_PARAMETER if there is already another different TypeObject registered with + * the given type_name. + * RETCODE_BAD_PARAMETER if type_name is empty. + */ + FASTDDS_EXPORTED_API static ReturnCode_t build_and_register_annotation_type_object( + const CompleteAnnotationType& annotation_type, + const std::string& type_name); + + /** + * @brief Register structure TypeObject into TypeObjectRegistry. + * CompleteStructType is provided and the minimal TypeObject is constructed from the complete one. + * + * @param[in] struct_type CompleteStructType. + * @param[in] type_name Name to be registered in the registry. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given type is inconsistent + * (only in Debug build mode). + * @return ReturnCode_t RETCODE_OK if correctly registered in TypeObjectRegistry. + * RETCODE_BAD_PARAMETER if there is already another different TypeObject registered with + * the given type_name. + * RETCODE_BAD_PARAMETER if type_name is empty. + */ + FASTDDS_EXPORTED_API static ReturnCode_t build_and_register_struct_type_object( + const CompleteStructType& struct_type, + const std::string& type_name); + + /** + * @brief Register union TypeObject into TypeObjectRegistry. + * CompleteUnionType is provided and the minimal TypeObject is constructed from the complete one. + * + * @param[in] union_type CompleteUnionType. + * @param[in] type_name Name to be registered in the registry. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given type is inconsistent + * (only in Debug build mode). + * @return ReturnCode_t RETCODE_OK if correctly registered in TypeObjectRegistry. + * RETCODE_BAD_PARAMETER if there is already another different TypeObject registered with + * the given type_name. + * RETCODE_BAD_PARAMETER if type_name is empty. + */ + FASTDDS_EXPORTED_API static ReturnCode_t build_and_register_union_type_object( + const CompleteUnionType& union_type, + const std::string& type_name); + + /** + * @brief Register bitset TypeObject into TypeObjectRegistry. + * CompleteBitsetType is provided and the minimal TypeObject is constructed from the complete one. + * + * @param[in] bitset_type CompleteBitsetType. + * @param[in] type_name Name to be registered in the registry. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given type is inconsistent + * (only in Debug build mode). + * @return ReturnCode_t RETCODE_OK if correctly registered in TypeObjectRegistry. + * RETCODE_BAD_PARAMETER if there is already another different TypeObject registered with + * the given type_name. + * RETCODE_BAD_PARAMETER if type_name is empty. + */ + FASTDDS_EXPORTED_API static ReturnCode_t build_and_register_bitset_type_object( + const CompleteBitsetType& bitset_type, + const std::string& type_name); + + /** + * @brief Register sequence TypeObject into TypeObjectRegistry. + * CompleteSequenceType is provided and the minimal TypeObject is constructed from the complete one. + * + * @param[in] sequence_type CompleteSequenceType. + * @param[in] type_name Name to be registered in the registry. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given type is inconsistent + * (only in Debug build mode). + * @return ReturnCode_t RETCODE_OK if correctly registered in TypeObjectRegistry. + * RETCODE_BAD_PARAMETER if there is already another different TypeObject registered with + * the given type_name. + * RETCODE_BAD_PARAMETER if type_name is empty. + */ + FASTDDS_EXPORTED_API static ReturnCode_t build_and_register_sequence_type_object( + const CompleteSequenceType& sequence_type, + const std::string& type_name); + + /** + * @brief Register array TypeObject into TypeObjectRegistry. + * CompleteArrayType is provided and the minimal TypeObject is constructed from the complete one. + * + * @param[in] array_type CompleteArrayType. + * @param[in] type_name Name to be registered in the registry. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given type is inconsistent + * (only in Debug build mode). + * @return ReturnCode_t RETCODE_OK if correctly registered in TypeObjectRegistry. + * RETCODE_BAD_PARAMETER if there is already another different TypeObject registered with + * the given type_name. + * RETCODE_BAD_PARAMETER if type_name is empty. + */ + FASTDDS_EXPORTED_API static ReturnCode_t build_and_register_array_type_object( + const CompleteArrayType& array_type, + const std::string& type_name); + + /** + * @brief Register map TypeObject into TypeObjectRegistry. + * CompleteMapType is provided and the minimal TypeObject is constructed from the complete one. + * + * @param[in] map_type CompleteMapType. + * @param[in] type_name Name to be registered in the registry. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given type is inconsistent + * (only in Debug build mode). + * @return ReturnCode_t RETCODE_OK if correctly registered in TypeObjectRegistry. + * RETCODE_BAD_PARAMETER if there is already another different TypeObject registered with + * the given type_name. + * RETCODE_BAD_PARAMETER if type_name is empty. + */ + FASTDDS_EXPORTED_API static ReturnCode_t build_and_register_map_type_object( + const CompleteMapType& map_type, + const std::string& type_name); + + /** + * @brief Register enumeration TypeObject into TypeObjectRegistry. + * CompleteEnumeratedType is provided and the minimal TypeObject is constructed from the complete one. + * + * @param[in] enumerated_type CompleteEnumeratedType. + * @param[in] type_name Name to be registered in the registry. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given type is inconsistent + * (only in Debug build mode). + * @return ReturnCode_t RETCODE_OK if correctly registered in TypeObjectRegistry. + * RETCODE_BAD_PARAMETER if there is already another different TypeObject registered with + * the given type_name. + * RETCODE_BAD_PARAMETER if type_name is empty. + */ + FASTDDS_EXPORTED_API static ReturnCode_t build_and_register_enumerated_type_object( + const CompleteEnumeratedType& enumerated_type, + const std::string& type_name); + + /** + * @brief Register bitmask TypeObject into TypeObjectRegistry. + * CompleteBitmaskType is provided and the minimal TypeObject is constructed from the complete one. + * + * @param[in] bitmask_type CompleteBitmaskType. + * @param[in] type_name Name to be registered in the registry. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given type is inconsistent + * (only in Debug build mode). + * @return ReturnCode_t RETCODE_OK if correctly registered in TypeObjectRegistry. + * RETCODE_BAD_PARAMETER if there is already another different TypeObject registered with + * the given type_name. + * RETCODE_BAD_PARAMETER if type_name is empty. + */ + FASTDDS_EXPORTED_API static ReturnCode_t build_and_register_bitmask_type_object( + const CompleteBitmaskType& bitmask_type, + const std::string& type_name); + + /*************** Auxiliary public methods ***************************/ + + /** + * @brief Calculate the MD5 hash of the provided name. + * + * @param[in] name String which hash is calculated. + * @return const NameHash Hash of the given string. + */ + FASTDDS_EXPORTED_API static const NameHash name_hash( + const std::string& name); + + /** + * @brief Check TypeObject consistency. + * + * @param[in] type_object Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * TypeObject is not consistent. + */ + static void type_object_consistency( + const TypeObject& type_object); + +private: + + friend class TypeObjectRegistry; + friend class eprosima::fastdds::dds::DynamicTypeBuilderFactoryImpl; + + // Class with only static methods + TypeObjectUtils() = delete; + ~TypeObjectUtils() = delete; + +protected: + + /*************** Auxiliary methods ***************************/ + + /** + * @brief Set the try construct behavior in a given MemberFlag + * + * @param[in out] member_flag Bitmask to be set. + * @param[in] try_construct_kind TryConstructKind. + */ + static void set_try_construct_behavior( + MemberFlag& member_flag, + TryConstructKind try_construct_kind); + + /** + * @brief Set the TypeFlag object. + * + * @param[in out] type_flag Bitmask to be set. + * @param[in] extensibility_kind ExtensibilityKind + * @param[in] nested nested annotation value. + * @param[in] autoid_hash autoid annotation has HASH value. + */ + static void set_type_flag( + TypeFlag& type_flag, + ExtensibilityKind extensibility_kind, + bool nested, + bool autoid_hash); + + /** + * @brief Set the extensibility kind in a given TypeFlag. + * + * @param[in out] type_flag Bitmask to be set. + * @param[in] extensibility_kind ExtensibilityKind. + */ + static void set_extensibility_kind( + TypeFlag& type_flag, + ExtensibilityKind extensibility_kind); + + /** + * @brief Check if a given TypeIdentifier is fully-descriptive. + * XTypes v1.3 Clause 7.3.4.6.1 Fully-descriptive TypeIdentifiers + * Some TypeIdentifiers do not involve computing the Hash of any TypeObject. These are called + * Fully-descriptive TypeIdentifiers because they fully describe the Type. These are: + * - The TypeIdentifiers for Primitive and String types. + * - The TypeIdentifiers of plain collections where the element (and key) TypeIdentifier is a fully + * descriptive TypeIdentifier. They are recognized by the contained PlainCollectionHeader having + * EquivalenceKind set to EK_BOTH. + * + * @param[in] type_identifier TypeIdentifier to check. + * @return true if the given TypeIdentifier is fully-descriptive. false otherwise. + */ + static bool is_fully_descriptive_type_identifier( + const TypeIdentifier& type_identifier); + + /** + * @brief Check if a given TypeIdentifier is direct hash. + * XTypes v1.3 Clause 7.3.4.6.3 + * These are HASH TypeIdentifiers with discriminator EK_MINIMAL, EK_COMPLETE or + * TI_STRONGLY_CONNECTED_COMPONENT. + * + * @param[in] type_identifier TypeIdentifier to check. + * @return true if the given TypeIdentifier is direct hash. false otherwise. + */ + static bool is_direct_hash_type_identifier( + const TypeIdentifier& type_identifier); + + /** + * @brief Check if a given TypeIdentifier is indirect hash. + * XTypes v1.3 Clause 7.3.4.6.4 + * These are the TypeIdentifiers for plain collections with the element type identified using a HASH + * TypeIdentifier. They are distinguished by: + * 1. Having discriminator TI_PLAIN_SEQUENCE_SMALL, TI_PLAIN_SEQUENCE_LARGE, TI_PLAIN_ARRAY_SMALL, + * TI_PLAIN_ARRAY_LARGE, TI_PLAIN_MAP_SMALL, or TI_PLAIN_MAP_LARGE. + * 2. Having the contained PlainCollectionHeader with EquivalenceKind EK_MINIMAL or EK_COMPLETE. + * + * @param[in] type_identifier TypeIdentifier to check. + * @return true if the given TypeIdentifier is indirect hash. false otherwise. + */ + static bool is_indirect_hash_type_identifier( + const TypeIdentifier& type_identifier); + + /*************** Consistency methods (Debug) ***************************/ + + /** + * TypeObjectHashId is always consistent. Default constructor already sets the discriminator to one valid value. + * Union setters prevent changing the discriminator value without setting the corresponding union member. + */ + + /** + * @brief Check LBound consistency: must be greater than 255. + * + * @param[in] bound LBound to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given LBound is not + * consistent. + */ + static void l_bound_consistency( + LBound bound); + + /** + * @brief Check that the array_bound_seq is consistent: non-empty. + * + * @tparam T Either SBoundSeq or LBoundSeq + * @param[in] array Sequence to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given array is not + * consistent. + */ + template + static void array_bound_seq_consistency( + const T& array) + { + if (array.empty()) + { + throw InvalidArgumentError("array_bound_seq parameter must not be empty"); + } + for (auto bound : array) + { + if (INVALID_LBOUND == bound) + { + throw InvalidArgumentError("bound parameter must be greater than 0"); + } + } + } + + /** + * @brief Check LBoundSeq consistency. + * + * @param[in] bound_seq Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given LBoundSeq is + * not consistent. + */ + static void l_bound_seq_consistency( + const LBoundSeq& bound_seq); + + /** + * @brief Check CollectionElementFlag consistency. + * + * @param[in] collection_element_flag CollectionElementFlag to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given CollectionElementFlag + * is not consistent. + */ + static void collection_element_flag_consistency( + CollectionElementFlag collection_element_flag); + + /** + * @brief Check StructMemberFlag consistency: MemberFlag consistency (try construct annotation). + * XTypes v1.3 Clause 7.2.2.4.4.4.8 Key members shall never be optional, and they shall always have their + * "must understand" attribute set to true. + * + * @param[in] member_flags MemberFlag to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given StructMemberFlag is not + * consistent. + */ + static void struct_member_flag_consistency( + StructMemberFlag member_flags); + + /** + * @brief Check UnionMemberFlag consistency. + * + * @param[in] union_member_flag UnionMemberFlag to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given UnionMemberFlag + * is not consistent. + */ + static void union_member_flag_consistency( + UnionMemberFlag union_member_flag); + + /** + * @brief Check UnionDiscriminatorFlag consistency. + * + * @param[in] union_discriminator_flag UnionDiscriminatorFlag to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given UnionDiscriminatorFlag + * is not consistent. + */ + static void union_discriminator_flag_consistency( + UnionDiscriminatorFlag union_discriminator_flag); + + /** + * @brief Check EnumeratedLiteralFlag consistency: any flag different from default are not set. + * + * @param[in] enumerated_literal_flag Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given EnumeratedLiteralFlag + * is not consistent. + */ + static void enumerated_literal_flag_consistency( + EnumeratedLiteralFlag enumerated_literal_flag); + + /** + * @brief Check TypeFlag consistency: exactly one extensibility flag is set. + * + * @param[in] type_flag Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given TypeFlag + * is not consistent. + */ + static void type_flag_consistency( + TypeFlag type_flag); + + /** + * @brief Check empty flags consistency. + * + * @tparam T Either MemberFlag or TypeFlag. + * @param[in] flags Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * flags are not consistent: empty (0). + */ + template + static void empty_flags_consistency( + T flags) + { + if (flags != 0) + { + throw InvalidArgumentError("Flags should be empty. No flags apply"); + } + } + + /** + * @brief Check EquivalenceKind consistency. + * + * @param[in] equiv_kind Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given EquivalenceKind + * is not consistent. + */ + static void equivalence_kind_consistency( + EquivalenceKind equiv_kind); + + /** + * @brief Check PlainCollectionHeader consistency: + * - CollectionElementFlag consistent + * - Consistent EquivalenceKind + * + * @param[in] header PlainCollectionHeader to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given PlainCollectionHeader + * is not consistent. + */ + static void plain_collection_header_consistency( + const PlainCollectionHeader& header); + + /** + * @brief Check consistency between a given PlainCollectionHeader and the related TypeIdentifier: + * 1. TypeIdentifier initialized + * 2. Consistency of EquivalenceKinds + * + * @param[in] header PlainCollectionHeader to be checked. + * @param[in] element_identifier TypeIdentifier to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given parameters are not + * consistent. + */ + static void plain_collection_type_identifier_header_consistency( + const PlainCollectionHeader& header, + const TypeIdentifier& element_identifier); + + /** + * @brief Retrieves the equivalence kind of a component within a map. + * + * @param[in] identifier TypeIdentifier of the component to be checked. + * @return EK_COMPLETE if the component equivalence kind is EK_COMPLETE. + * @return EK_MINIMAL if the component equivalence kind is EK_MINIMAL. + * @return EK_BOTH if the component equivalence kind is EK_BOTH. + * @return TK_NONE if the component type is invalid. + */ + static EquivalenceKind get_map_component_equiv_kind_for_consistency( + const TypeIdentifier& identifier); + + /** + * @brief Check consistency between a given PlainCollectionHeader of a map and the related TypeIdentifier: + * 1. Key TypeIdentifier is valid + * 2. TypeIdentifier initialized + * 3. Consistency of EquivalenceKinds + * + * @param[in] header PlainCollectionHeader of the map to be checked. + * @param[in] type_identifier TypeIdentifier to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given parameters are not + * consistent. + */ + static void plain_map_type_components_consistency( + const PlainCollectionHeader& header, + const TypeIdentifier& type_identifier); + + /** + * @brief Check map key_identifier consistency. + * XTypes v1.3 Clause 7.2.2.4.3: Implementers of this specification need only support key elements of signed + * and unsigned integer types and of narrow and wide string types. + * In Debug build mode, this method also checks that the string/wstring bound is consistent. + * + * @param[in] key_identifier TypeIdentifier to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given TypeIdentifier is not + * consistent. + */ + static void map_key_type_identifier_consistency( + const TypeIdentifier& key_identifier); + + /** + * @brief Check StringLTypeDefn consistency. + * + * @param[in] string Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given StringLTypeDefn is not + * consistent. + */ + static void string_ldefn_consistency( + const StringLTypeDefn& string); + + /** + * @brief Check PlainSequenceSElemDefn consistency. + * + * @param[in] plain_seq Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given PlainSequenceSElemDefn + * is not consistent. + */ + static void seq_sdefn_consistency( + const PlainSequenceSElemDefn& plain_seq); + + /** + * @brief Check PlainSequenceLElemDefn consistency. + * + * @param[in] plain_seq Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given PlainSequenceLElemDefn + * is not consistent. + */ + static void seq_ldefn_consistency( + const PlainSequenceLElemDefn& plain_seq); + + /** + * @brief Check PlainArraySElemDefn consistency. + * + * @param[in] plain_array Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given PlainArraySElemDefn is + * not consistent. + */ + static void array_sdefn_consistency( + const PlainArraySElemDefn& plain_array); + + /** + * @brief Check PlainArrayLElemDefn consistency. + * + * @param[in] plain_array Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given PlainArrayLElemDefn is + * not consistent. + */ + static void array_ldefn_consistency( + const PlainArrayLElemDefn& plain_array); + + /** + * @brief Check PlainMapSTypeDefn consistency. + * + * @param[in] plain_map Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given PlainMapSTypeDefn is + * not consistent. + */ + static void map_sdefn_consistency( + const PlainMapSTypeDefn& plain_map); + + /** + * @brief Check PlainMapLTypeDefn consistency. + * + * @param[in] plain_map Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given PlainMapLTypeDefn is + * not consistent. + */ + static void map_ldefn_consistency( + const PlainMapLTypeDefn& plain_map); + + /** + * @brief Check direct hash TypeIdentifier consistency. + * + * @param[in] type_id Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given TypeIdentifier is + * not consistent. + */ + static void direct_hash_type_identifier_consistency( + const TypeIdentifier& type_id); + + /** + * @brief Check TypeIdentifier consistency. + * + * @param[in] type_identifier Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given TypeIdentifier is + * not consistent. + */ + static void type_identifier_consistency( + const TypeIdentifier& type_identifier); + + /** + * @brief Check AppliedAnnotationParameterSeq consistency. + * + * @param[in] applied_annotation_parameter_seq Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * AppliedAnnotationParameterSeq is not consistent. + */ + static void applied_annotation_parameter_seq_consistency( + const AppliedAnnotationParameterSeq& applied_annotation_parameter_seq); + + /** + * @brief Check AppliedAnnotation TypeIdentifier consistency. + * + * @param[in] annotation_type_id Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * AppliedAnnotation TypeIdentifier is not consistent. + */ + static void applied_annotation_type_identifier_consistency( + const TypeIdentifier& annotation_type_id); + + /** + * @brief Check AppliedAnnotation consistency. + * + * @param[in] applied_annotation Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given AppliedAnnotation is + * not consistent. + */ + static void applied_annotation_consistency( + const AppliedAnnotation& applied_annotation); + + /** + * @brief Check AppliedAnnotationSeq consistency. + * + * @param[in] applied_annotation_seq Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given AppliedAnnotationSeq is + * not consistent. + */ + static void applied_annotation_seq_consistency( + const AppliedAnnotationSeq& applied_annotation_seq); + + /** + * @brief Check AppliedVerbatimAnnotation consistency. + * + * @param[in] applied_verbatim_annotation Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * AppliedVerbatimAnnotation is not consistent. + */ + static void applied_verbatim_annotation_consistency( + const AppliedVerbatimAnnotation& applied_verbatim_annotation); + + /** + * @brief Check CommonStructMember consistency. + * + * @param[in] common_struct_member Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given CommonStructMember is + * not consistent. + */ + static void common_struct_member_consistency( + const CommonStructMember& common_struct_member); + + /** + * @brief Check CompleteMemberDetail consistency. + * + * @param[in] complete_member_detail Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given CompleteMemberDetail is + * not consistent. + */ + static void complete_member_detail_consistency( + const CompleteMemberDetail& complete_member_detail); + + /** + * @brief Check cross-consistency between CommonStructMember and CompleteMemberDetail. + * + * @param[in] common_struct_member CommonStructMember to be checked. + * @param[in] complete_member_detail CompleteMemberDetail to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the hashid builtin applied + * annotation is set and inconsistent with the member id. + */ + static void common_struct_member_and_complete_member_detail_consistency( + const CommonStructMember& common_struct_member, + const CompleteMemberDetail& complete_member_detail); + + /** + * @brief Check consistency between a string value and the MemberId (algorithm XTypes v1.3 Clause 7.3.1.2.1.1) + * + * @param[in] member_id MemberId to be checked. + * @param[in] string_value String provided with either hashid annotation or the member name. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given data is inconsistent. + */ + static void string_member_id_consistency( + MemberId member_id, + const std::string& string_value); + + /** + * @brief Check CompleteStructMember consistency. + * + * @param[in] complete_struct_member Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given CompleteStructMember is + * not consistent. + */ + static void complete_struct_member_consistency( + const CompleteStructMember& complete_struct_member); + + /** + * @brief Check CompleteStructMemberSeq consistency. + * + * @param[in] complete_struct_member_seq Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given CompleteStructMemberSeq + * is not consistent. + */ + static void complete_struct_member_seq_consistency( + const CompleteStructMemberSeq& complete_struct_member_seq); + + /** + * @brief Check AppliedBuiltinTypeAnnotations consistency. + * + * @param[in] applied_builtin_type_annotations Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * AppliedBuiltinTypeAnnotations is not consistent. + */ + static void applied_builtin_type_annotations_consistency( + const AppliedBuiltinTypeAnnotations& applied_builtin_type_annotations); + + /** + * @brief Check CompleteTypeDetail consistency. + * + * @param[in] complete_type_detail Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given CompleteTypeDetail is + * not consistent. + */ + static void complete_type_detail_consistency( + const CompleteTypeDetail& complete_type_detail); + + /** + * @brief Check CompleteStructHeader base_type TypeIdentifier consistency. + * + * @param[in] base_type Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given TypeIdentifier is + * not consistent. + */ + static void structure_base_type_consistency( + const TypeIdentifier& base_type); + + /** + * @brief Check CompleteStructHeader consistency. + * + * @param[in] complete_struct_header Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given CompleteStructHeader + * is not consistent. + */ + static void complete_struct_header_consistency( + const CompleteStructHeader& complete_struct_header); + + /** + * @brief Check CompleteStructType consistency. + * + * @param[in] complete_struct_type Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given CompleteStructType + * is not consistent. + */ + static void complete_struct_type_consistency( + const CompleteStructType& complete_struct_type); + + /** + * @brief Check MinimalStructType consistency. + * + * @param[in] minimal_struct_type Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given MinimalStructType + * is not consistent. + */ + static void minimal_struct_type_consistency( + const MinimalStructType& minimal_struct_type); + + /** + * @brief Check UnionCaseLabelSeq consistency. + * + * @param[in] union_case_label_seq Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given UnionCaseLabelSeq + * is not consistent. + */ + static void union_case_label_seq_consistency( + const UnionCaseLabelSeq& union_case_label_seq); + + /** + * @brief Check CommonUnionMember consistency. + * + * @param[in] common_union_member Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given CommonUnionMember + * is not consistent. + */ + static void common_union_member_consistency( + const CommonUnionMember& common_union_member); + + /** + * @brief Check cross-consistency between CommonStructMember and CompleteMemberDetail. + * + * @param[in] common_union_member CommonStructMember to be checked. + * @param[in] complete_member_detail CompleteMemberDetail to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the hashid builtin annotation is + * set and the member id is not consistent. + */ + static void common_union_member_complete_member_detail_consistency( + const CommonUnionMember& common_union_member, + const CompleteMemberDetail& complete_member_detail); + + /** + * @brief Check CompleteUnionMember consistency. + * + * @param[in] complete_union_member Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given CompleteUnionMember + * is not consistent. + */ + static void complete_union_member_consistency( + const CompleteUnionMember& complete_union_member); + + /** + * @brief Check CompleteUnionMemberSeq consistency. + * + * @param[in] complete_union_member_seq Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given CompleteUnionMemberSeq + * is not consistent. + */ + static void complete_union_member_seq_consistency( + const CompleteUnionMemberSeq& complete_union_member_seq); + + /** + * @brief Check discriminator TypeIdentifier consistency. + * + * @param[in] type_id Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given TypeIdentifier + * is not consistent. + */ + static void common_discriminator_member_type_identifier_consistency( + const TypeIdentifier& type_id); + + /** + * @brief Check CommonDiscriminatorMember consistency. + * + * @param[in] common_discriminator_member Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * CommonDiscriminatorMember is not consistent. + */ + static void common_discriminator_member_consistency( + const CommonDiscriminatorMember& common_discriminator_member); + + /** + * @brief Check CompleteDiscriminatorMember consistency. + * + * @param[in] complete_discriminator_member Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * CompleteDiscriminatorMember is not consistent. + */ + static void complete_discriminator_member_consistency( + const CompleteDiscriminatorMember& complete_discriminator_member); + + /** + * @brief Check CompleteUnionHeader consistency. + * + * @param[in] complete_union_header Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * CompleteUnionHeader is not consistent. + */ + static void complete_union_header_consistency( + const CompleteUnionHeader& complete_union_header); + + /** + * @brief Check CompleteUnionType consistency. + * + * @param[in] complete_union_type Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * CompleteUnionType is not consistent. + */ + static void complete_union_type_consistency( + const CompleteUnionType& complete_union_type); + + /** + * @brief Check MinimalUnionType consistency. + * + * @param[in] minimal_union_type Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * MinimalUnionType is not consistent. + */ + static void minimal_union_type_consistency( + const MinimalUnionType& minimal_union_type); + + /** + * @brief Check that the annotation value is of the same type as the given TypeIdentifier. + * + * @param type_id TypeIdentifier. + * @param value AnnotationParameterValue. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given TypeIdentifier is not + * consistent with the given value. + */ + static void common_annotation_parameter_type_identifier_default_value_consistency( + const TypeIdentifier& type_id, + const AnnotationParameterValue& value); + + /** + * @brief Check CommonAnnotationParameter consistency. + * + * @param[in] common_annotation_parameter Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * CommonAnnotationParameter is not consistent. + */ + static void common_annotation_parameter_consistency( + const CommonAnnotationParameter& common_annotation_parameter); + + /** + * @brief Check CompleteAnnotationParameter consistency. + * + * @param[in] complete_annotation_parameter Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * CompleteAnnotationParameter is not consistent. + */ + static void complete_annotation_parameter_consistency( + const CompleteAnnotationParameter& complete_annotation_parameter); + + /** + * @brief Check CompleteAnnotationParameterSeq consistency. + * + * @param[in] complete_annotation_parameter_seq Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * CompleteAnnotationParameterSeq is not consistent. + */ + static void complete_annotation_parameter_seq_consistency( + const CompleteAnnotationParameterSeq& complete_annotation_parameter_seq); + + /** + * @brief Check CompleteAnnotationHeader consistency. + * + * @param[in] complete_annotation_header Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * CompleteAnnotationHeader is not consistent. + */ + static void complete_annotation_header_consistency( + const CompleteAnnotationHeader& complete_annotation_header); + + /** + * @brief Check CompleteAnnotationType consistency. + * + * @param[in] complete_annotation_type Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * CompleteAnnotationType is not consistent. + */ + static void complete_annotation_type_consistency( + const CompleteAnnotationType& complete_annotation_type); + + /** + * @brief Check MinimalAnnotationType consistency. + * + * @param[in] minimal_annotation_type Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * MinimalAnnotationType is not consistent. + */ + static void minimal_annotation_type_consistency( + const MinimalAnnotationType& minimal_annotation_type); + + /** + * @brief Check CommonAliasBody consistency. + * + * @param[in] common_alias_body Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * CommonAliasBody is not consistent. + */ + static void common_alias_body_consistency( + const CommonAliasBody& common_alias_body); + + /** + * @brief Check that hashid builtin annotation has not been set. + * + * @param[in] ann_builtin Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * AppliedBuiltinMemberAnnotations is not consistent. + */ + static void hashid_builtin_annotation_not_applied_consistency( + const eprosima::fastcdr::optional& ann_builtin); + + /** + * @brief Check CompleteAliasBody consistency. + * + * @param[in] complete_alias_body Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * CompleteAliasBody is not consistent. + */ + static void complete_alias_body_consistency( + const CompleteAliasBody& complete_alias_body); + + /** + * @brief Check CompleteAliasHeader consistency. + * + * @param[in] complete_alias_header Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * CompleteAliasHeader is not consistent. + */ + static void complete_alias_header_consistency( + const CompleteAliasHeader& complete_alias_header); + + /** + * @brief Check CompleteAliasType consistency. + * + * @param[in] complete_alias_type Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * CompleteAliasType is not consistent. + */ + static void complete_alias_type_consistency( + const CompleteAliasType& complete_alias_type); + + /** + * @brief Check MinimalAliasType consistency. + * + * @param[in] minimal_alias_type Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * MinimalAliasType is not consistent. + */ + static void minimal_alias_type_consistency( + const MinimalAliasType& minimal_alias_type); + + /** + * @brief Check CompleteElementDetail consistency. + * + * @param[in] complete_element_detail Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * CompleteElementDetail is not consistent. + */ + static void complete_element_detail_consistency( + const CompleteElementDetail& complete_element_detail); + + /** + * @brief Check CommonCollectionElement consistency. + * + * @param[in] common_collection_element Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * CommonCollectionElement is not consistent. + */ + static void common_collection_element_consistency( + const CommonCollectionElement& common_collection_element); + + /** + * @brief Check CompleteCollectionElement consistency. + * + * @param[in] complete_collection_element Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * CompleteCollectionElement is not consistent. + */ + static void complete_collection_element_consistency( + const CompleteCollectionElement& complete_collection_element); + + /** + * @brief Check CompleteCollectionHeader consistency. + * + * @param[in] complete_collection_header Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * CompleteCollectionHeader is not consistent. + */ + static void complete_collection_header_consistency( + const CompleteCollectionHeader& complete_collection_header); + + /** + * @brief Check CompleteSequenceType consistency. + * + * @param[in] complete_sequence_type Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * CompleteSequenceType is not consistent. + */ + static void complete_sequence_type_consistency( + const CompleteSequenceType& complete_sequence_type); + + /** + * @brief Check MinimalSequenceType consistency. + * + * @param[in] minimal_sequence_type Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * MinimalSequenceType is not consistent. + */ + static void minimal_sequence_type_consistency( + const MinimalSequenceType& minimal_sequence_type); + + /** + * @brief Check CommonArrayHeader consistency. + * + * @param[in] common_array_header Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * CommonArrayHeader is not consistent. + */ + static void common_array_header_consistency( + const CommonArrayHeader& common_array_header); + + /** + * @brief Check CompleteArrayHeader consistency. + * + * @param[in] complete_array_header Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * CompleteArrayHeader is not consistent. + */ + static void complete_array_header_consistency( + const CompleteArrayHeader& complete_array_header); + + /** + * @brief Check CompleteArrayType consistency. + * + * @param[in] complete_array_type Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * CompleteArrayType is not consistent. + */ + static void complete_array_type_consistency( + const CompleteArrayType& complete_array_type); + + /** + * @brief Check MinimalArrayType consistency. + * + * @param[in] minimal_array_type Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * MinimalArrayType is not consistent. + */ + static void minimal_array_type_consistency( + const MinimalArrayType& minimal_array_type); + + /** + * @brief Check CompleteMapType consistency. + * + * @param[in] complete_map_type Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * CompleteMapType is not consistent. + */ + static void complete_map_type_consistency( + const CompleteMapType& complete_map_type); + + /** + * @brief Check MinimalMapType consistency. + * + * @param[in] minimal_map_type Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * MinimalMapType is not consistent. + */ + static void minimal_map_type_consistency( + const MinimalMapType& minimal_map_type); + + /** + * @brief Check CommonEnumeratedLiteral consistency. + * + * @param[in] common_enumerated_literal Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * CommonEnumeratedLiteral is not consistent. + */ + static void common_enumerated_literal_consistency( + const CommonEnumeratedLiteral& common_enumerated_literal); + + /** + * @brief Check CompleteEnumeratedLiteral consistency. + * + * @param[in] complete_enumerated_literal Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * CompleteEnumeratedLiteral is not consistent. + */ + static void complete_enumerated_literal_consistency( + const CompleteEnumeratedLiteral& complete_enumerated_literal); + + /** + * @brief Check CompleteEnumeratedLiteralSeq consistency. + * + * @param[in] complete_enumerated_literal_seq Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * CompleteEnumeratedLiteralSeq is not consistent. + */ + static void complete_enumerated_literal_seq_consistency( + const CompleteEnumeratedLiteralSeq& complete_enumerated_literal_seq); + + /** + * @brief Check enumeration BitBound consistency. + * + * @param[in] bit_bound Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * BitBound is not consistent. + */ + static void enum_bit_bound_consistency( + BitBound bit_bound); + + /** + * @brief Check bitmask BitBound consistency. + * + * @param[in] bit_bound Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * BitBound is not consistent. + */ + static void bitmask_bit_bound_consistency( + BitBound bit_bound); + + /** + * @brief Check CommonEnumeratedHeader consistency. + * + * @param[in] common_enumerated_header Instance to be checked. + * @param[in] bitmask flag in case that the header corresponds to a Bitmask. By default is false. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * CommonEnumeratedHeader is not consistent. + */ + static void common_enumerated_header_consistency( + const CommonEnumeratedHeader& common_enumerated_header, + bool bitmask = false); + + /** + * @brief Check CompleteEnumeratedHeader consistency. + * + * @param[in] complete_enumerated_header Instance to be checked. + * @param[in] bitmask Flag in case that the header corresponds to a Bitmask. By default is false. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * CompleteEnumeratedHeader is not consistent. + */ + static void complete_enumerated_header_consistency( + const CompleteEnumeratedHeader& complete_enumerated_header, + bool bitmask = false); + + /** + * @brief Check CompleteEnumeratedType consistency. + * + * @param[in] complete_enumerated_type Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * CompleteEnumeratedType is not consistent. + */ + static void complete_enumerated_type_consistency( + const CompleteEnumeratedType& complete_enumerated_type); + + /** + * @brief Check MinimalEnumeratedType consistency. + * + * @param[in] minimal_enumerated_type Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * MinimalEnumeratedType is not consistent. + */ + static void minimal_enumerated_type_consistency( + const MinimalEnumeratedType& minimal_enumerated_type); + + /** + * @brief Check bitflag position consistency. + * + * @param[in] position Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * bitflag position is not consistent. + */ + static void bit_position_consistency( + uint16_t position); + + /** + * @brief Check CommonBitflag consistency. + * + * @param[in] common_bitflag Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * CommonBitflag is not consistent. + */ + static void common_bitflag_consistency( + const CommonBitflag& common_bitflag); + + /** + * @brief Check CompleteBitflag consistency. + * + * @param[in] complete_bitflag Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * CompleteBitflag is not consistent. + */ + static void complete_bitflag_consistency( + const CompleteBitflag& complete_bitflag); + + /** + * @brief Check CompleteBitflagSeq consistency. + * + * @param[in] complete_bitflag_seq Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * CompleteBitflagSeq is not consistent. + */ + static void complete_bitflag_seq_consistency( + const CompleteBitflagSeq& complete_bitflag_seq); + + /** + * @brief Check CompleteBitmaskType consistency. + * + * @param[in] complete_bitmask_type Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * CompleteBitmaskType is not consistent. + */ + static void complete_bitmask_type_consistency( + const CompleteBitmaskType& complete_bitmask_type); + + /** + * @brief Check MinimalBitmaskType consistency. + * + * @param[in] minimal_bitmask_type Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * MinimalBitmaskType is not consistent. + */ + static void minimal_bitmask_type_consistency( + const MinimalBitmaskType& minimal_bitmask_type); + + /** + * @brief Check consistency between the holder type and the bitcount. + * + * @param[in] holder_type TypeKind of the bitfield holder type. + * @param[in] bitcount Bitfield number of bits. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given data is inconsistent. + */ + static void bitfield_holder_type_consistency( + TypeKind holder_type, + uint8_t bitcount); + + /** + * @brief Check CommonBitfield consistency. + * + * @param[in] common_bitfield Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * CommonBitfield is not consistent. + */ + static void common_bitfield_consistency( + const CommonBitfield& common_bitfield); + + /** + * @brief Check CompleteBitfield consistency. + * + * @param[in] complete_bitfield Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * CompleteBitfield is not consistent. + */ + static void complete_bitfield_consistency( + const CompleteBitfield& complete_bitfield); + + /** + * @brief Check CompleteBitfieldSeq consistency. + * + * @param[in] complete_bitfield_seq Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * CompleteBitfieldSeq is not consistent. + */ + static void complete_bitfield_seq_consistency( + const CompleteBitfieldSeq& complete_bitfield_seq); + + /** + * @brief Check CompleteBitsetHeader consistency. + * + * @param[in] complete_bitset_header Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * CompleteBitsetHeader is not consistent. + */ + static void complete_bitset_header_consistency( + const CompleteBitsetHeader& complete_bitset_header); + + /** + * @brief Check CompleteBitsetType consistency. + * + * @param[in] complete_bitset_type Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * CompleteBitsetType is not consistent. + */ + static void complete_bitset_type_consistency( + const CompleteBitsetType& complete_bitset_type); + + /** + * @brief Check MinimalBitsetType consistency. + * + * @param[in] minimal_bitset_type Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * MinimalBitsetType is not consistent. + */ + static void minimal_bitset_type_consistency( + const MinimalBitsetType& minimal_bitset_type); + + /** + * @brief Check CompleteTypeObject consistency. + * + * @param[in] complete_type_object Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * CompleteTypeObject is not consistent. + */ + static void complete_type_object_consistency( + const CompleteTypeObject& complete_type_object); + + /** + * @brief Check MinimalTypeObject consistency. + * + * @param[in] minimal_type_object Instance to be checked. + * @exception eprosima::fastdds::dds::xtypes::InvalidArgumentError exception if the given + * MinimalTypeObject is not consistent. + */ + static void minimal_type_object_consistency( + const MinimalTypeObject& minimal_type_object); +}; + +} // xtypes +} // dds +} // fastdds +} // eprosima + +#endif // _FASTDDS_DDS_XTYPES_TYPE_REPRESENTATION_TYPEOBJECTUTILS_HPP_ diff --git a/include/fastdds/dds/xtypes/type_representation/detail/dds-xtypes_typeobject.idl b/include/fastdds/dds/xtypes/type_representation/detail/dds-xtypes_typeobject.idl new file mode 100644 index 00000000000..0d4b5798529 --- /dev/null +++ b/include/fastdds/dds/xtypes/type_representation/detail/dds-xtypes_typeobject.idl @@ -0,0 +1,1077 @@ +/* dds-xtypes_typeobject.idl */ + +// The types in this file shall be serialized with XCDR encoding version 2 +module DDS { module XTypes { + + // ---------- Equivalence Kinds ------------------- + typedef octet EquivalenceKind; + const octet EK_MINIMAL = 0xF1; // 0x1111 0001 + const octet EK_COMPLETE = 0xF2; // 0x1111 0010 + const octet EK_BOTH = 0xF3; // 0x1111 0011 + + // ---------- TypeKinds (begin) ------------------- + typedef octet TypeKind; + + // Primitive TKs + const octet TK_NONE = 0x00; + const octet TK_BOOLEAN = 0x01; + const octet TK_BYTE = 0x02; + const octet TK_INT16 = 0x03; + const octet TK_INT32 = 0x04; + const octet TK_INT64 = 0x05; + const octet TK_UINT16 = 0x06; + const octet TK_UINT32 = 0x07; + const octet TK_UINT64 = 0x08; + const octet TK_FLOAT32 = 0x09; + const octet TK_FLOAT64 = 0x0A; + const octet TK_FLOAT128 = 0x0B; + const octet TK_INT8 = 0x0C; + const octet TK_UINT8 = 0x0D; + const octet TK_CHAR8 = 0x10; + const octet TK_CHAR16 = 0x11; + + // String TKs + const octet TK_STRING8 = 0x20; + const octet TK_STRING16 = 0x21; + + // Constructed/Named types + const octet TK_ALIAS = 0x30; + + // Enumerated TKs + const octet TK_ENUM = 0x40; + const octet TK_BITMASK = 0x41; + + // Structured TKs + const octet TK_ANNOTATION = 0x50; + const octet TK_STRUCTURE = 0x51; + const octet TK_UNION = 0x52; + const octet TK_BITSET = 0x53; + + // Collection TKs + const octet TK_SEQUENCE = 0x60; + const octet TK_ARRAY = 0x61; + const octet TK_MAP = 0x62; + // ---------- TypeKinds (end) ------------------- + + // ---------- Extra TypeIdentifiers (begin) ------------ + typedef octet TypeIdentiferKind; + const octet TI_STRING8_SMALL = 0x70; + const octet TI_STRING8_LARGE = 0x71; + const octet TI_STRING16_SMALL = 0x72; + const octet TI_STRING16_LARGE = 0x73; + + const octet TI_PLAIN_SEQUENCE_SMALL = 0x80; + const octet TI_PLAIN_SEQUENCE_LARGE = 0x81; + + const octet TI_PLAIN_ARRAY_SMALL = 0x90; + const octet TI_PLAIN_ARRAY_LARGE = 0x91; + + const octet TI_PLAIN_MAP_SMALL = 0xA0; + const octet TI_PLAIN_MAP_LARGE = 0xA1; + + const octet TI_STRONGLY_CONNECTED_COMPONENT = 0xB0; + // ---------- Extra TypeIdentifiers (end) -------------- + + // The name of some element (e.g. type, type member, module) + // Valid characters are alphanumeric plus the "_" cannot start with digit + const long MEMBER_NAME_MAX_LENGTH = 256; + typedef string MemberName; + + // Qualified type name includes the name of containing modules + // using "::" as separator. No leading "::". E.g. "MyModule::MyType" + const long TYPE_NAME_MAX_LENGTH = 256; + typedef string QualifiedTypeName; + + // Every type has an ID. Those of the primitive types are pre-defined. + typedef octet PrimitiveTypeId; + + // First 14 bytes of MD5 of the serialized TypeObject using XCDR + // version 2 with Little Endian encoding + typedef octet EquivalenceHash[14]; + + // First 4 bytes of MD5 of of a member name converted to bytes + // using UTF-8 encoding and without a 'nul' terminator. + // Example: the member name "color" has NameHash {0x70, 0xDD, 0xA5, 0xDF} + typedef octet NameHash[4]; + + // Long Bound of a collection type + typedef unsigned long LBound; + typedef sequence LBoundSeq; + const LBound INVALID_LBOUND = 0; + + // Short Bound of a collection type + typedef octet SBound; + typedef sequence SBoundSeq; + const SBound INVALID_SBOUND = 0; + + @extensibility(FINAL) @nested + union TypeObjectHashId switch (octet) { + case EK_COMPLETE: + case EK_MINIMAL: + EquivalenceHash hash; + }; + + // Flags that apply to struct/union/collection/enum/bitmask/bitset + // members/elements and DO affect type assignability + // Depending on the flag it may not apply to members of all types + // When not all, the applicable member types are listed + @bit_bound(16) + bitmask MemberFlag { + @position(0) TRY_CONSTRUCT1, // T1 | 00 = INVALID, 01 = DISCARD + @position(1) TRY_CONSTRUCT2, // T2 | 10 = USE_DEFAULT, 11 = TRIM + @position(2) IS_EXTERNAL, // X StructMember, UnionMember, + // CollectionElement + @position(3) IS_OPTIONAL, // O StructMember + @position(4) IS_MUST_UNDERSTAND, // M StructMember + @position(5) IS_KEY, // K StructMember, UnionDiscriminator + @position(6) IS_DEFAULT // D UnionMember, EnumerationLiteral + }; + typedef MemberFlag CollectionElementFlag; // T1, T2, X + typedef MemberFlag StructMemberFlag; // T1, T2, O, M, K, X + typedef MemberFlag UnionMemberFlag; // T1, T2, D, X + typedef MemberFlag UnionDiscriminatorFlag; // T1, T2, K + typedef MemberFlag EnumeratedLiteralFlag; // D + typedef MemberFlag AnnotationParameterFlag; // Unused. No flags apply + typedef MemberFlag AliasMemberFlag; // Unused. No flags apply + typedef MemberFlag BitflagFlag; // Unused. No flags apply + typedef MemberFlag BitsetMemberFlag; // Unused. No flags apply + + // Mask used to remove the flags that do no affect assignability + // Selects T1, T2, O, M, K, D + const unsigned short MemberFlagMinimalMask = 0x003f; + + // Flags that apply to type declarationa and DO affect assignability + // Depending on the flag it may not apply to all types + // When not all, the applicable types are listed + @bit_bound(16) + bitmask TypeFlag { + @position(0) IS_FINAL, // F | + @position(1) IS_APPENDABLE, // A |- Struct, Union + @position(2) IS_MUTABLE, // M | (exactly one flag) + + @position(3) IS_NESTED, // N Struct, Union + @position(4) IS_AUTOID_HASH // H Struct + }; + typedef TypeFlag StructTypeFlag; // All flags apply + typedef TypeFlag UnionTypeFlag; // All flags apply + typedef TypeFlag CollectionTypeFlag; // Unused. No flags apply + typedef TypeFlag AnnotationTypeFlag; // Unused. No flags apply + typedef TypeFlag AliasTypeFlag; // Unused. No flags apply + typedef TypeFlag EnumTypeFlag; // Unused. No flags apply + typedef TypeFlag BitmaskTypeFlag; // Unused. No flags apply + typedef TypeFlag BitsetTypeFlag; // Unused. No flags apply + + // Mask used to remove the flags that do no affect assignability + const unsigned short TypeFlagMinimalMask = 0x0007; // Selects M, A, F + + // Forward declaration + union TypeIdentifier; + + // 1 Byte + @extensibility(FINAL) @nested + struct StringSTypeDefn { + SBound bound; + }; + + // 4 Bytes + @extensibility(FINAL) @nested + struct StringLTypeDefn { + LBound bound; + }; + + @extensibility(FINAL) @nested + struct PlainCollectionHeader { + EquivalenceKind equiv_kind; + CollectionElementFlag element_flags; + }; + + @extensibility(FINAL) @nested + struct PlainSequenceSElemDefn { + PlainCollectionHeader header; + SBound bound; + @external TypeIdentifier element_identifier; + }; + + @extensibility(FINAL) @nested + struct PlainSequenceLElemDefn { + PlainCollectionHeader header; + LBound bound; + @external TypeIdentifier element_identifier; + }; + + @extensibility(FINAL) @nested + struct PlainArraySElemDefn { + PlainCollectionHeader header; + SBoundSeq array_bound_seq; + @external TypeIdentifier element_identifier; + }; + + @extensibility(FINAL) @nested + struct PlainArrayLElemDefn { + PlainCollectionHeader header; + LBoundSeq array_bound_seq; + @external TypeIdentifier element_identifier; + }; + + @extensibility(FINAL) @nested + struct PlainMapSTypeDefn { + PlainCollectionHeader header; + SBound bound; + @external TypeIdentifier element_identifier; + CollectionElementFlag key_flags; + @external TypeIdentifier key_identifier; + }; + + @extensibility(FINAL) @nested + struct PlainMapLTypeDefn { + PlainCollectionHeader header; + LBound bound; + @external TypeIdentifier element_identifier; + CollectionElementFlag key_flags; + @external TypeIdentifier key_identifier; + }; + + // Used for Types that have cyclic depencencies with other types + @extensibility(APPENDABLE) @nested + struct StronglyConnectedComponentId { + TypeObjectHashId sc_component_id; // Hash StronglyConnectedComponent + long scc_length; // StronglyConnectedComponent.length + long scc_index ; // identify type in Strongly Connected Comp. + }; + + // Future extensibility + @extensibility(MUTABLE) @nested + struct ExtendedTypeDefn { + // Empty. Available for future extension + }; + + + + // The TypeIdentifier uniquely identifies a type (a set of equivalent + // types according to an equivalence relationship: COMPLETE, MNIMAL). + // + // In some cases (primitive types, strings, plain types) the identifier + // is a explicit description of the type. + // In other cases the Identifier is a Hash of the type description + // + // In the case of primitive types and strings the implied equivalence + // relation is the identity. + // + // For Plain Types and Hash-defined TypeIdentifiers there are three + // possibilities: MINIMAL, COMPLETE, and COMMON: + // - MINIMAL indicates the TypeIdentifier identifies equivalent types + // according to the MINIMAL equivalence relation + // - COMPLETE indicates the TypeIdentifier identifies equivalent types + // according to the COMPLETE equivalence relation + // - COMMON indicates the TypeIdentifier identifies equivalent types + // according to both the MINIMAL and the COMMON equivalence relation. + // This means the TypeIdentifier is the same for both relationships + // + @extensibility(FINAL) @nested + union TypeIdentifier switch (octet) { + // ============ Primitive types - use TypeKind ==================== + // All primitive types fall here. + // Commented-out because Unions cannot have cases with no member. + /* + case TK_NONE: + case TK_BOOLEAN: + case TK_BYTE_TYPE: + case TK_INT8_TYPE: + case TK_INT16_TYPE: + case TK_INT32_TYPE: + case TK_INT64_TYPE: + case TK_UINT8_TYPE: + case TK_UINT16_TYPE: + case TK_UINT32_TYPE: + case TK_UINT64_TYPE: + case TK_FLOAT32_TYPE: + case TK_FLOAT64_TYPE: + case TK_FLOAT128_TYPE: + case TK_CHAR8_TYPE: + case TK_CHAR16_TYPE: + // No Value + */ + + // ============ Strings - use TypeIdentifierKind =================== + case TI_STRING8_SMALL: + case TI_STRING16_SMALL: + StringSTypeDefn string_sdefn; + + case TI_STRING8_LARGE: + case TI_STRING16_LARGE: + StringLTypeDefn string_ldefn; + + // ============ Plain collectios - use TypeIdentifierKind ========= + case TI_PLAIN_SEQUENCE_SMALL: + PlainSequenceSElemDefn seq_sdefn; + case TI_PLAIN_SEQUENCE_LARGE: + PlainSequenceLElemDefn seq_ldefn; + + case TI_PLAIN_ARRAY_SMALL: + PlainArraySElemDefn array_sdefn; + case TI_PLAIN_ARRAY_LARGE: + PlainArrayLElemDefn array_ldefn; + + case TI_PLAIN_MAP_SMALL: + PlainMapSTypeDefn map_sdefn; + case TI_PLAIN_MAP_LARGE: + PlainMapLTypeDefn map_ldefn; + + // ============ Types that are mutually dependent on each other === + case TI_STRONGLY_CONNECTED_COMPONENT: + StronglyConnectedComponentId sc_component_id; + + // ============ The remaining cases - use EquivalenceKind ========= + case EK_COMPLETE: + case EK_MINIMAL: + EquivalenceHash equivalence_hash; + + // =================== Future extensibility ============ + // Future extensions + default: + ExtendedTypeDefn extended_defn; + }; + typedef sequence TypeIdentifierSeq; + + + // --- Annotation usage: ----------------------------------------------- + + // ID of a type member + typedef unsigned long MemberId; + const unsigned long ANNOTATION_STR_VALUE_MAX_LEN = 128; + const unsigned long ANNOTATION_OCTETSEC_VALUE_MAX_LEN = 128; + + @extensibility(MUTABLE) @nested + struct ExtendedAnnotationParameterValue { + // Empty. Available for future extension + }; + + /* Literal value of an annotation member: either the default value in its + * definition or the value applied in its usage. + */ + @extensibility(FINAL) @nested + union AnnotationParameterValue switch (octet) { + case TK_BOOLEAN: + boolean boolean_value; + case TK_BYTE: + octet byte_value; + case TK_INT8: + int8 int8_value; + case TK_UINT8: + uint8 uint8_value; + case TK_INT16: + short int16_value; + case TK_UINT16: + unsigned short uint_16_value; + case TK_INT32: + long int32_value; + case TK_UINT32: + unsigned long uint32_value; + case TK_INT64: + long long int64_value; + case TK_UINT64: + unsigned long long uint64_value; + case TK_FLOAT32: + float float32_value; + case TK_FLOAT64: + double float64_value; + case TK_FLOAT128: + long double float128_value; + case TK_CHAR8: + char char_value; + case TK_CHAR16: + wchar wchar_value; + case TK_ENUM: + long enumerated_value; + case TK_STRING8: + string string8_value; + case TK_STRING16: + wstring string16_value; + default: + ExtendedAnnotationParameterValue extended_value; + }; + + // The application of an annotation to some type or type member + @extensibility(APPENDABLE) @nested + struct AppliedAnnotationParameter { + NameHash paramname_hash; + AnnotationParameterValue value; + }; + // Sorted by AppliedAnnotationParameter.paramname_hash + typedef + sequence AppliedAnnotationParameterSeq; + + @extensibility(APPENDABLE) @nested + struct AppliedAnnotation { + TypeIdentifier annotation_typeid; + @optional AppliedAnnotationParameterSeq param_seq; + }; + // Sorted by AppliedAnnotation.annotation_typeid + typedef sequence AppliedAnnotationSeq; + + // @verbatim(placement="", language="", text="") + @extensibility(FINAL) @nested + struct AppliedVerbatimAnnotation { + string<32> placement; + string<32> language; + string text; + }; + + + // --- Aggregate types: ------------------------------------------------ + @extensibility(APPENDABLE) @nested + struct AppliedBuiltinMemberAnnotations { + @optional string unit; // @unit("") + @optional AnnotationParameterValue min; // @min , @range + @optional AnnotationParameterValue max; // @max , @range + @optional string hash_id; // @hash_id("") + }; + + @extensibility(FINAL) @nested + struct CommonStructMember { + MemberId member_id; + StructMemberFlag member_flags; + TypeIdentifier member_type_id; + }; + + // COMPLETE Details for a member of an aggregate type + @extensibility(FINAL) @nested + struct CompleteMemberDetail { + MemberName name; + @optional AppliedBuiltinMemberAnnotations ann_builtin; + @optional AppliedAnnotationSeq ann_custom; + }; + + // MINIMAL Details for a member of an aggregate type + @extensibility(FINAL) @nested + struct MinimalMemberDetail { + NameHash name_hash; + }; + + // Member of an aggregate type + @extensibility(APPENDABLE) @nested + struct CompleteStructMember { + CommonStructMember common; + CompleteMemberDetail detail; + }; + // Ordered by the member_index + typedef sequence CompleteStructMemberSeq; + + // Member of an aggregate type + @extensibility(APPENDABLE) @nested + struct MinimalStructMember { + CommonStructMember common; + MinimalMemberDetail detail; + }; + // Ordered by common.member_id + typedef sequence MinimalStructMemberSeq; + + + @extensibility(APPENDABLE) @nested + struct AppliedBuiltinTypeAnnotations { + @optional AppliedVerbatimAnnotation verbatim; // @verbatim(...) + }; + + @extensibility(FINAL) @nested + struct MinimalTypeDetail { + // Empty. Available for future extension + }; + + @extensibility(FINAL) @nested + struct CompleteTypeDetail { + @optional AppliedBuiltinTypeAnnotations ann_builtin; + @optional AppliedAnnotationSeq ann_custom; + QualifiedTypeName type_name; + }; + + @extensibility(APPENDABLE) @nested + struct CompleteStructHeader { + TypeIdentifier base_type; + CompleteTypeDetail detail; + }; + + @extensibility(APPENDABLE) @nested + struct MinimalStructHeader { + TypeIdentifier base_type; + MinimalTypeDetail detail; + }; + + @extensibility(FINAL) @nested + struct CompleteStructType { + StructTypeFlag struct_flags; + CompleteStructHeader header; + CompleteStructMemberSeq member_seq; + }; + + @extensibility(FINAL) @nested + struct MinimalStructType { + StructTypeFlag struct_flags; + MinimalStructHeader header; + MinimalStructMemberSeq member_seq; + }; + + // --- Union: ---------------------------------------------------------- + + // Case labels that apply to a member of a union type + // Ordered by their values + typedef sequence UnionCaseLabelSeq; + + @extensibility(FINAL) @nested + struct CommonUnionMember { + MemberId member_id; + UnionMemberFlag member_flags; + TypeIdentifier type_id; + UnionCaseLabelSeq label_seq; + }; + + // Member of a union type + @extensibility(APPENDABLE) @nested + struct CompleteUnionMember { + CommonUnionMember common; + CompleteMemberDetail detail; + }; + // Ordered by member_index + typedef sequence CompleteUnionMemberSeq; + + // Member of a union type + @extensibility(APPENDABLE) @nested + struct MinimalUnionMember { + CommonUnionMember common; + MinimalMemberDetail detail; + }; + // Ordered by MinimalUnionMember.common.member_id + typedef sequence MinimalUnionMemberSeq; + + @extensibility(FINAL) @nested + struct CommonDiscriminatorMember { + UnionDiscriminatorFlag member_flags; + TypeIdentifier type_id; + }; + + // Member of a union type + @extensibility(APPENDABLE) @nested + struct CompleteDiscriminatorMember { + CommonDiscriminatorMember common; + @optional AppliedBuiltinTypeAnnotations ann_builtin; + @optional AppliedAnnotationSeq ann_custom; + }; + + // Member of a union type + @extensibility(APPENDABLE) @nested + struct MinimalDiscriminatorMember { + CommonDiscriminatorMember common; + }; + + @extensibility(APPENDABLE) @nested + struct CompleteUnionHeader { + CompleteTypeDetail detail; + }; + + @extensibility(APPENDABLE) @nested + struct MinimalUnionHeader { + MinimalTypeDetail detail; + }; + + @extensibility(FINAL) @nested + struct CompleteUnionType { + UnionTypeFlag union_flags; + CompleteUnionHeader header; + CompleteDiscriminatorMember discriminator; + CompleteUnionMemberSeq member_seq; + }; + + @extensibility(FINAL) @nested + struct MinimalUnionType { + UnionTypeFlag union_flags; + MinimalUnionHeader header; + MinimalDiscriminatorMember discriminator; + MinimalUnionMemberSeq member_seq; + }; + + // --- Annotation: ---------------------------------------------------- + @extensibility(FINAL) @nested + struct CommonAnnotationParameter { + AnnotationParameterFlag member_flags; + TypeIdentifier member_type_id; + }; + + // Member of an annotation type + @extensibility(APPENDABLE) @nested + struct CompleteAnnotationParameter { + CommonAnnotationParameter common; + MemberName name; + AnnotationParameterValue default_value; + }; + // Ordered by CompleteAnnotationParameter.name + typedef + sequence CompleteAnnotationParameterSeq; + + @extensibility(APPENDABLE) @nested + struct MinimalAnnotationParameter { + CommonAnnotationParameter common; + NameHash name_hash; + AnnotationParameterValue default_value; + }; + // Ordered by MinimalAnnotationParameter.name_hash + typedef + sequence MinimalAnnotationParameterSeq; + + @extensibility(APPENDABLE) @nested + struct CompleteAnnotationHeader { + QualifiedTypeName annotation_name; + }; + + @extensibility(APPENDABLE) @nested + struct MinimalAnnotationHeader { + // Empty. Available for future extension + }; + + @extensibility(FINAL) @nested + struct CompleteAnnotationType { + AnnotationTypeFlag annotation_flag; + CompleteAnnotationHeader header; + CompleteAnnotationParameterSeq member_seq; + }; + + @extensibility(FINAL) @nested + struct MinimalAnnotationType { + AnnotationTypeFlag annotation_flag; + MinimalAnnotationHeader header; + MinimalAnnotationParameterSeq member_seq; + }; + + + // --- Alias: ---------------------------------------------------------- + @extensibility(FINAL) @nested + struct CommonAliasBody { + AliasMemberFlag related_flags; + TypeIdentifier related_type; + }; + + @extensibility(APPENDABLE) @nested + struct CompleteAliasBody { + CommonAliasBody common; + @optional AppliedBuiltinMemberAnnotations ann_builtin; + @optional AppliedAnnotationSeq ann_custom; + }; + + @extensibility(APPENDABLE) @nested + struct MinimalAliasBody { + CommonAliasBody common; + }; + + @extensibility(APPENDABLE) @nested + struct CompleteAliasHeader { + CompleteTypeDetail detail; + }; + + @extensibility(APPENDABLE) @nested + struct MinimalAliasHeader { + // Empty. Available for future extension + }; + + @extensibility(FINAL) @nested + struct CompleteAliasType { + AliasTypeFlag alias_flags; + CompleteAliasHeader header; + CompleteAliasBody body; + }; + + @extensibility(FINAL) @nested + struct MinimalAliasType { + AliasTypeFlag alias_flags; + MinimalAliasHeader header; + MinimalAliasBody body; + }; + + // --- Collections: ---------------------------------------------------- + @extensibility(FINAL) @nested + struct CompleteElementDetail { + @optional AppliedBuiltinMemberAnnotations ann_builtin; + @optional AppliedAnnotationSeq ann_custom; + }; + + @extensibility(FINAL) @nested + struct CommonCollectionElement { + CollectionElementFlag element_flags; + TypeIdentifier type; + }; + + @extensibility(APPENDABLE) @nested + struct CompleteCollectionElement { + CommonCollectionElement common; + CompleteElementDetail detail; + }; + + @extensibility(APPENDABLE) @nested + struct MinimalCollectionElement { + CommonCollectionElement common; + }; + + @extensibility(FINAL) @nested + struct CommonCollectionHeader { + LBound bound; + }; + + @extensibility(APPENDABLE) @nested + struct CompleteCollectionHeader { + CommonCollectionHeader common; + @optional CompleteTypeDetail detail; // not present for anonymous + }; + + @extensibility(APPENDABLE) @nested + struct MinimalCollectionHeader { + CommonCollectionHeader common; + }; + + // --- Sequence: ------------------------------------------------------ + @extensibility(FINAL) @nested + struct CompleteSequenceType { + CollectionTypeFlag collection_flag; + CompleteCollectionHeader header; + CompleteCollectionElement element; + }; + + @extensibility(FINAL) @nested + struct MinimalSequenceType { + CollectionTypeFlag collection_flag; + MinimalCollectionHeader header; + MinimalCollectionElement element; + }; + + // --- Array: ------------------------------------------------------ + @extensibility(FINAL) @nested + struct CommonArrayHeader { + LBoundSeq bound_seq; + }; + + @extensibility(APPENDABLE) @nested + struct CompleteArrayHeader { + CommonArrayHeader common; + CompleteTypeDetail detail; + }; + + @extensibility(APPENDABLE) @nested + struct MinimalArrayHeader { + CommonArrayHeader common; + }; + + @extensibility(APPENDABLE) @nested + struct CompleteArrayType { + CollectionTypeFlag collection_flag; + CompleteArrayHeader header; + CompleteCollectionElement element; + }; + + @extensibility(FINAL) @nested + struct MinimalArrayType { + CollectionTypeFlag collection_flag; + MinimalArrayHeader header; + MinimalCollectionElement element; + }; + + // --- Map: ------------------------------------------------------ + @extensibility(FINAL) @nested + struct CompleteMapType { + CollectionTypeFlag collection_flag; + CompleteCollectionHeader header; + CompleteCollectionElement key; + CompleteCollectionElement element; + }; + + @extensibility(FINAL) @nested + struct MinimalMapType { + CollectionTypeFlag collection_flag; + MinimalCollectionHeader header; + MinimalCollectionElement key; + MinimalCollectionElement element; + }; + + // --- Enumeration: ---------------------------------------------------- + typedef unsigned short BitBound; + + // Constant in an enumerated type + @extensibility(APPENDABLE) @nested + struct CommonEnumeratedLiteral { + long value; + EnumeratedLiteralFlag flags; + }; + + // Constant in an enumerated type + @extensibility(APPENDABLE) @nested + struct CompleteEnumeratedLiteral { + CommonEnumeratedLiteral common; + CompleteMemberDetail detail; + }; + // Ordered by EnumeratedLiteral.common.value + typedef sequence CompleteEnumeratedLiteralSeq; + + // Constant in an enumerated type + @extensibility(APPENDABLE) @nested + struct MinimalEnumeratedLiteral { + CommonEnumeratedLiteral common; + MinimalMemberDetail detail; + }; + // Ordered by EnumeratedLiteral.common.value + typedef sequence MinimalEnumeratedLiteralSeq; + + @extensibility(FINAL) @nested + struct CommonEnumeratedHeader { + BitBound bit_bound; + }; + + @extensibility(APPENDABLE) @nested + struct CompleteEnumeratedHeader { + CommonEnumeratedHeader common; + CompleteTypeDetail detail; + }; + + @extensibility(APPENDABLE) @nested + struct MinimalEnumeratedHeader { + CommonEnumeratedHeader common; + }; + + // Enumerated type + @extensibility(FINAL) @nested + struct CompleteEnumeratedType { + EnumTypeFlag enum_flags; // unused + CompleteEnumeratedHeader header; + CompleteEnumeratedLiteralSeq literal_seq; + }; + + // Enumerated type + @extensibility(FINAL) @nested + struct MinimalEnumeratedType { + EnumTypeFlag enum_flags; // unused + MinimalEnumeratedHeader header; + MinimalEnumeratedLiteralSeq literal_seq; + }; + + // --- Bitmask: -------------------------------------------------------- + // Bit in a bit mask + @extensibility(FINAL) @nested + struct CommonBitflag { + unsigned short position; + BitflagFlag flags; + }; + + @extensibility(APPENDABLE) @nested + struct CompleteBitflag { + CommonBitflag common; + CompleteMemberDetail detail; + }; + // Ordered by Bitflag.position + typedef sequence CompleteBitflagSeq; + + @extensibility(APPENDABLE) @nested + struct MinimalBitflag { + CommonBitflag common; + MinimalMemberDetail detail; + }; + // Ordered by Bitflag.position + typedef sequence MinimalBitflagSeq; + + @extensibility(FINAL) @nested + struct CommonBitmaskHeader { + BitBound bit_bound; + }; + + typedef CompleteEnumeratedHeader CompleteBitmaskHeader; + + typedef MinimalEnumeratedHeader MinimalBitmaskHeader; + + @extensibility(APPENDABLE) @nested + struct CompleteBitmaskType { + BitmaskTypeFlag bitmask_flags; // unused + CompleteBitmaskHeader header; + CompleteBitflagSeq flag_seq; + }; + + @extensibility(APPENDABLE) @nested + struct MinimalBitmaskType { + BitmaskTypeFlag bitmask_flags; // unused + MinimalBitmaskHeader header; + MinimalBitflagSeq flag_seq; + }; + + // --- Bitset: ---------------------------------------------------------- + @extensibility(FINAL) @nested + struct CommonBitfield { + unsigned short position; + BitsetMemberFlag flags; + octet bitcount; + TypeKind holder_type; // Must be primitive integer type + }; + + @extensibility(APPENDABLE) @nested + struct CompleteBitfield { + CommonBitfield common; + CompleteMemberDetail detail; + }; + // Ordered by Bitfield.position + typedef sequence CompleteBitfieldSeq; + + @extensibility(APPENDABLE) @nested + struct MinimalBitfield { + CommonBitfield common; + NameHash name_hash; + }; + // Ordered by Bitfield.position + typedef sequence MinimalBitfieldSeq; + + @extensibility(APPENDABLE) @nested + struct CompleteBitsetHeader { + CompleteTypeDetail detail; + }; + + @extensibility(APPENDABLE) @nested + struct MinimalBitsetHeader { + // Empty. Available for future extension + }; + + @extensibility(APPENDABLE) @nested + struct CompleteBitsetType { + BitsetTypeFlag bitset_flags; // unused + CompleteBitsetHeader header; + CompleteBitfieldSeq field_seq; + }; + + @extensibility(APPENDABLE) @nested + struct MinimalBitsetType { + BitsetTypeFlag bitset_flags; // unused + MinimalBitsetHeader header; + MinimalBitfieldSeq field_seq; + }; + + // --- Type Object: --------------------------------------------------- + // The types associated with each case selection must have extensibility + // kind APPENDABLE or MUTABLE so that they can be extended in the future + + @extensibility(MUTABLE) @nested + struct CompleteExtendedType { + // Empty. Available for future extension + }; + + @extensibility(FINAL) @nested + union CompleteTypeObject switch (octet) { + case TK_ALIAS: + CompleteAliasType alias_type; + case TK_ANNOTATION: + CompleteAnnotationType annotation_type; + case TK_STRUCTURE: + CompleteStructType struct_type; + case TK_UNION: + CompleteUnionType union_type; + case TK_BITSET: + CompleteBitsetType bitset_type; + case TK_SEQUENCE: + CompleteSequenceType sequence_type; + case TK_ARRAY: + CompleteArrayType array_type; + case TK_MAP: + CompleteMapType map_type; + case TK_ENUM: + CompleteEnumeratedType enumerated_type; + case TK_BITMASK: + CompleteBitmaskType bitmask_type; + + // =================== Future extensibility ============ + default: + CompleteExtendedType extended_type; + }; + + @extensibility(MUTABLE) @nested + struct MinimalExtendedType { + // Empty. Available for future extension + }; + + + @extensibility(FINAL) @nested + union MinimalTypeObject switch (octet) { + case TK_ALIAS: + MinimalAliasType alias_type; + case TK_ANNOTATION: + MinimalAnnotationType annotation_type; + case TK_STRUCTURE: + MinimalStructType struct_type; + case TK_UNION: + MinimalUnionType union_type; + case TK_BITSET: + MinimalBitsetType bitset_type; + case TK_SEQUENCE: + MinimalSequenceType sequence_type; + case TK_ARRAY: + MinimalArrayType array_type; + case TK_MAP: + MinimalMapType map_type; + case TK_ENUM: + MinimalEnumeratedType enumerated_type; + case TK_BITMASK: + MinimalBitmaskType bitmask_type; + + // =================== Future extensibility ============ + default: + MinimalExtendedType extended_type; + }; + + @extensibility(APPENDABLE) @nested + union TypeObject switch (octet) { // EquivalenceKind + case EK_COMPLETE: + CompleteTypeObject complete; + case EK_MINIMAL: + MinimalTypeObject minimal; + }; + typedef sequence TypeObjectSeq; + + // Set of TypeObjects representing a strong component: Equivalence class + // for the Strong Connectivity relationship (mutual reachability between + // types). + // Ordered by fully qualified typename lexicographic order + typedef TypeObjectSeq StronglyConnectedComponent; + + @extensibility(FINAL) @nested + struct TypeIdentifierTypeObjectPair { + TypeIdentifier type_identifier; + TypeObject type_object; + }; + typedef + sequence TypeIdentifierTypeObjectPairSeq; + + @extensibility(FINAL) @nested + struct TypeIdentifierPair { + TypeIdentifier type_identifier1; + TypeIdentifier type_identifier2; + }; + typedef sequence TypeIdentifierPairSeq; + + @extensibility(APPENDABLE) @nested + struct TypeIdentfierWithSize { + DDS::XTypes::TypeIdentifier type_id; + unsigned long typeobject_serialized_size; + }; + typedef sequence TypeIdentfierWithSizeSeq; + + @extensibility(APPENDABLE) @nested + struct TypeIdentifierWithDependencies { + TypeIdentfierWithSize typeid_with_size; + // The total additional types related to minimal_type + long dependent_typeid_count; + sequence dependent_typeids; + }; + typedef + sequence TypeIdentifierWithDependenciesSeq; + + // This appears in the builtin DDS topics PublicationBuiltinTopicData + // and SubscriptionBuiltinTopicData + @extensibility(MUTABLE) @nested + struct TypeInformation { + @id(0x1001) TypeIdentifierWithDependencies minimal; + @id(0x1002) TypeIdentifierWithDependencies complete; + }; + typedef sequence TypeInformationSeq; + +}; // end of module XTypes +}; // end module DDS + + + diff --git a/include/fastdds/dds/xtypes/type_representation/detail/dds_xtypes_typeobject.hpp b/include/fastdds/dds/xtypes/type_representation/detail/dds_xtypes_typeobject.hpp new file mode 100644 index 00000000000..e230483cdce --- /dev/null +++ b/include/fastdds/dds/xtypes/type_representation/detail/dds_xtypes_typeobject.hpp @@ -0,0 +1,24387 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file dds_xtypes_typeobject.hpp + * This header file contains the declaration of the described types in the IDL file. + * + * This file was generated by the tool fastddsgen. + */ + +#ifndef _FAST_DDS_GENERATED_EPROSIMA_FASTDDS_DDS_XTYPES_DDS_XTYPES_TYPEOBJECT_HPP_ +#define _FAST_DDS_GENERATED_EPROSIMA_FASTDDS_DDS_XTYPES_DDS_XTYPES_TYPEOBJECT_HPP_ + +#include +#include +#include +#include +#include +#include + +#include +#include +#include +#include + + +#if defined(_WIN32) +#if defined(EPROSIMA_USER_DLL_EXPORT) +#define eProsima_user_DllExport __declspec( dllexport ) +#else +#define eProsima_user_DllExport +#endif // EPROSIMA_USER_DLL_EXPORT +#else +#define eProsima_user_DllExport +#endif // _WIN32 + +#if defined(_WIN32) +#if defined(EPROSIMA_USER_DLL_EXPORT) +#if defined(DDS_XTYPES_TYPEOBJECT_SOURCE) +#define DDS_XTYPES_TYPEOBJECT_DllAPI __declspec( dllexport ) +#else +#define DDS_XTYPES_TYPEOBJECT_DllAPI __declspec( dllimport ) +#endif // DDS_XTYPES_TYPEOBJECT_SOURCE +#else +#define DDS_XTYPES_TYPEOBJECT_DllAPI +#endif // EPROSIMA_USER_DLL_EXPORT +#else +#define DDS_XTYPES_TYPEOBJECT_DllAPI +#endif // _WIN32 + +namespace eprosima { + +namespace fastdds { + +namespace dds { + + +namespace xtypes { + + +typedef uint8_t EquivalenceKind; + +const uint8_t EK_MINIMAL = 0xF1; +const uint8_t EK_COMPLETE = 0xF2; +const uint8_t EK_BOTH = 0xF3; +typedef uint8_t TypeKind; + +const uint8_t TK_NONE = 0x00; +const uint8_t TK_BOOLEAN = 0x01; +const uint8_t TK_BYTE = 0x02; +const uint8_t TK_INT16 = 0x03; +const uint8_t TK_INT32 = 0x04; +const uint8_t TK_INT64 = 0x05; +const uint8_t TK_UINT16 = 0x06; +const uint8_t TK_UINT32 = 0x07; +const uint8_t TK_UINT64 = 0x08; +const uint8_t TK_FLOAT32 = 0x09; +const uint8_t TK_FLOAT64 = 0x0A; +const uint8_t TK_FLOAT128 = 0x0B; +const uint8_t TK_INT8 = 0x0C; +const uint8_t TK_UINT8 = 0x0D; +const uint8_t TK_CHAR8 = 0x10; +const uint8_t TK_CHAR16 = 0x11; +const uint8_t TK_STRING8 = 0x20; +const uint8_t TK_STRING16 = 0x21; +const uint8_t TK_ALIAS = 0x30; +const uint8_t TK_ENUM = 0x40; +const uint8_t TK_BITMASK = 0x41; +const uint8_t TK_ANNOTATION = 0x50; +const uint8_t TK_STRUCTURE = 0x51; +const uint8_t TK_UNION = 0x52; +const uint8_t TK_BITSET = 0x53; +const uint8_t TK_SEQUENCE = 0x60; +const uint8_t TK_ARRAY = 0x61; +const uint8_t TK_MAP = 0x62; +typedef uint8_t TypeIdentiferKind; + +const uint8_t TI_STRING8_SMALL = 0x70; +const uint8_t TI_STRING8_LARGE = 0x71; +const uint8_t TI_STRING16_SMALL = 0x72; +const uint8_t TI_STRING16_LARGE = 0x73; +const uint8_t TI_PLAIN_SEQUENCE_SMALL = 0x80; +const uint8_t TI_PLAIN_SEQUENCE_LARGE = 0x81; +const uint8_t TI_PLAIN_ARRAY_SMALL = 0x90; +const uint8_t TI_PLAIN_ARRAY_LARGE = 0x91; +const uint8_t TI_PLAIN_MAP_SMALL = 0xA0; +const uint8_t TI_PLAIN_MAP_LARGE = 0xA1; +const uint8_t TI_STRONGLY_CONNECTED_COMPONENT = 0xB0; +const int32_t MEMBER_NAME_MAX_LENGTH = 256; +typedef eprosima::fastcdr::fixed_string MemberName; + +const int32_t TYPE_NAME_MAX_LENGTH = 256; +typedef eprosima::fastcdr::fixed_string QualifiedTypeName; + +typedef uint8_t PrimitiveTypeId; + +typedef std::array EquivalenceHash; + +typedef std::array NameHash; + +typedef uint32_t LBound; + +typedef std::vector LBoundSeq; + +const LBound INVALID_LBOUND = 0; +typedef uint8_t SBound; + +typedef std::vector SBoundSeq; + +const SBound INVALID_SBOUND = 0; +/*! + * @brief This class represents the union TypeObjectHashId defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class TypeObjectHashId +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport TypeObjectHashId() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~TypeObjectHashId() + { + if (member_destructor_) + { + member_destructor_(); + } + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object TypeObjectHashId that will be copied. + */ + eProsima_user_DllExport TypeObjectHashId( + const TypeObjectHashId& x) + { + m__d = x.m__d; + + switch (x.selected_member_) + { + case 0x00000001: + hash_() = x.m_hash; + break; + + } + } + + /*! + * @brief Move constructor. + * @param x Reference to the object TypeObjectHashId that will be copied. + */ + eProsima_user_DllExport TypeObjectHashId( + TypeObjectHashId&& x) noexcept + { + m__d = x.m__d; + + switch (x.selected_member_) + { + case 0x00000001: + hash_() = std::move(x.m_hash); + break; + + } + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object TypeObjectHashId that will be copied. + */ + eProsima_user_DllExport TypeObjectHashId& operator =( + const TypeObjectHashId& x) + { + m__d = x.m__d; + + switch (x.selected_member_) + { + case 0x00000001: + hash_() = x.m_hash; + break; + + } + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object TypeObjectHashId that will be copied. + */ + eProsima_user_DllExport TypeObjectHashId& operator =( + TypeObjectHashId&& x) noexcept + { + m__d = x.m__d; + + switch (x.selected_member_) + { + case 0x00000001: + hash_() = std::move(x.m_hash); + break; + + } + + return *this; + } + + /*! + * @brief Comparison operator. + * @param x TypeObjectHashId object to compare. + */ + eProsima_user_DllExport bool operator ==( + const TypeObjectHashId& x) const + { + bool ret_value {false}; + + if (m__d == x.m__d && + selected_member_ == x.selected_member_) + { + switch (selected_member_) + { + case 0x00000001: + ret_value = (m_hash == x.m_hash); + break; + + } + } + + return ret_value; + } + + /*! + * @brief Comparison operator. + * @param x TypeObjectHashId object to compare. + */ + eProsima_user_DllExport bool operator !=( + const TypeObjectHashId& x) const + { + return !(*this == x); + } + + /*! + * @brief This function sets the discriminator value. + * @param __d New value for the discriminator. + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the new value doesn't correspond to the selected union member. + */ + eProsima_user_DllExport void _d( + uint8_t __d) + { + bool valid_discriminator = false; + + switch (__d) + { + case EK_COMPLETE: + case EK_MINIMAL: + if (0x00000001 == selected_member_) + { + valid_discriminator = true; + } + break; + + } + + if (!valid_discriminator) + { + throw eprosima::fastcdr::exception::BadParamException("Discriminator doesn't correspond with the selected union member"); + } + + m__d = __d; + } + + /*! + * @brief This function returns the value of the discriminator. + * @return Value of the discriminator + */ + eProsima_user_DllExport uint8_t _d() const + { + return m__d; + } + + /*! + * @brief This function copies the value in member hash + * @param _hash New value to be copied in member hash + */ + eProsima_user_DllExport void hash( + const EquivalenceHash& _hash) + { + hash_() = _hash; + m__d = EK_COMPLETE; + } + + /*! + * @brief This function moves the value in member hash + * @param _hash New value to be moved in member hash + */ + eProsima_user_DllExport void hash( + EquivalenceHash&& _hash) + { + hash_() = _hash; + m__d = EK_COMPLETE; + } + + /*! + * @brief This function returns a constant reference to member hash + * @return Constant reference to member hash + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport const EquivalenceHash& hash() const + { + if (0x00000001 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_hash; + } + + /*! + * @brief This function returns a reference to member hash + * @return Reference to member hash + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport EquivalenceHash& hash() + { + if (0x00000001 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_hash; + } + + + void _default() + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x0FFFFFFFu; + } + + +private: + + EquivalenceHash& hash_() + { + if (0x00000001 != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x00000001; + member_destructor_ = [&]() {m_hash.~EquivalenceHash();}; + new(&m_hash) EquivalenceHash(); + ; + } + + return m_hash; + } + + + uint8_t m__d {0}; + + union + { + EquivalenceHash m_hash; + }; + + uint32_t selected_member_ {0x0FFFFFFFu}; + + std::function member_destructor_; +}; +/*! + * @brief This enumeration represents the MemberFlag bitflags defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +enum MemberFlagBits : uint16_t +{ + TRY_CONSTRUCT1 = 0x01ull << 0, + TRY_CONSTRUCT2 = 0x01ull << 1, + IS_EXTERNAL = 0x01ull << 2, + IS_OPTIONAL = 0x01ull << 3, + IS_MUST_UNDERSTAND = 0x01ull << 4, + IS_KEY = 0x01ull << 5, + IS_DEFAULT = 0x01ull << 6 +}; +typedef uint16_t MemberFlag; +typedef MemberFlag CollectionElementFlag; + +typedef MemberFlag StructMemberFlag; + +typedef MemberFlag UnionMemberFlag; + +typedef MemberFlag UnionDiscriminatorFlag; + +typedef MemberFlag EnumeratedLiteralFlag; + +typedef MemberFlag AnnotationParameterFlag; + +typedef MemberFlag AliasMemberFlag; + +typedef MemberFlag BitflagFlag; + +typedef MemberFlag BitsetMemberFlag; + +const uint16_t MemberFlagMinimalMask = 0x003f; +/*! + * @brief This enumeration represents the TypeFlag bitflags defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +enum TypeFlagBits : uint16_t +{ + IS_FINAL = 0x01ull << 0, + IS_APPENDABLE = 0x01ull << 1, + IS_MUTABLE = 0x01ull << 2, + IS_NESTED = 0x01ull << 3, + IS_AUTOID_HASH = 0x01ull << 4 +}; +typedef uint16_t TypeFlag; +typedef TypeFlag StructTypeFlag; + +typedef TypeFlag UnionTypeFlag; + +typedef TypeFlag CollectionTypeFlag; + +typedef TypeFlag AnnotationTypeFlag; + +typedef TypeFlag AliasTypeFlag; + +typedef TypeFlag EnumTypeFlag; + +typedef TypeFlag BitmaskTypeFlag; + +typedef TypeFlag BitsetTypeFlag; + +const uint16_t TypeFlagMinimalMask = 0x0007; +class TypeIdentifier; + +/*! + * @brief This class represents the structure StringSTypeDefn defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class StringSTypeDefn +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport StringSTypeDefn() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~StringSTypeDefn() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object StringSTypeDefn that will be copied. + */ + eProsima_user_DllExport StringSTypeDefn( + const StringSTypeDefn& x) + { + m_bound = x.m_bound; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object StringSTypeDefn that will be copied. + */ + eProsima_user_DllExport StringSTypeDefn( + StringSTypeDefn&& x) noexcept + { + m_bound = x.m_bound; + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object StringSTypeDefn that will be copied. + */ + eProsima_user_DllExport StringSTypeDefn& operator =( + const StringSTypeDefn& x) + { + + m_bound = x.m_bound; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object StringSTypeDefn that will be copied. + */ + eProsima_user_DllExport StringSTypeDefn& operator =( + StringSTypeDefn&& x) noexcept + { + + m_bound = x.m_bound; + return *this; + } + + /*! + * @brief Comparison operator. + * @param x StringSTypeDefn object to compare. + */ + eProsima_user_DllExport bool operator ==( + const StringSTypeDefn& x) const + { + return (m_bound == x.m_bound); + } + + /*! + * @brief Comparison operator. + * @param x StringSTypeDefn object to compare. + */ + eProsima_user_DllExport bool operator !=( + const StringSTypeDefn& x) const + { + return !(*this == x); + } + + /*! + * @brief This function sets a value in member bound + * @param _bound New value for member bound + */ + eProsima_user_DllExport void bound( + SBound _bound) + { + m_bound = _bound; + } + + /*! + * @brief This function returns the value of member bound + * @return Value of member bound + */ + eProsima_user_DllExport SBound bound() const + { + return m_bound; + } + + /*! + * @brief This function returns a reference to member bound + * @return Reference to member bound + */ + eProsima_user_DllExport SBound& bound() + { + return m_bound; + } + + + +private: + + SBound m_bound{0}; + +}; +/*! + * @brief This class represents the structure StringLTypeDefn defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class StringLTypeDefn +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport StringLTypeDefn() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~StringLTypeDefn() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object StringLTypeDefn that will be copied. + */ + eProsima_user_DllExport StringLTypeDefn( + const StringLTypeDefn& x) + { + m_bound = x.m_bound; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object StringLTypeDefn that will be copied. + */ + eProsima_user_DllExport StringLTypeDefn( + StringLTypeDefn&& x) noexcept + { + m_bound = x.m_bound; + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object StringLTypeDefn that will be copied. + */ + eProsima_user_DllExport StringLTypeDefn& operator =( + const StringLTypeDefn& x) + { + + m_bound = x.m_bound; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object StringLTypeDefn that will be copied. + */ + eProsima_user_DllExport StringLTypeDefn& operator =( + StringLTypeDefn&& x) noexcept + { + + m_bound = x.m_bound; + return *this; + } + + /*! + * @brief Comparison operator. + * @param x StringLTypeDefn object to compare. + */ + eProsima_user_DllExport bool operator ==( + const StringLTypeDefn& x) const + { + return (m_bound == x.m_bound); + } + + /*! + * @brief Comparison operator. + * @param x StringLTypeDefn object to compare. + */ + eProsima_user_DllExport bool operator !=( + const StringLTypeDefn& x) const + { + return !(*this == x); + } + + /*! + * @brief This function sets a value in member bound + * @param _bound New value for member bound + */ + eProsima_user_DllExport void bound( + LBound _bound) + { + m_bound = _bound; + } + + /*! + * @brief This function returns the value of member bound + * @return Value of member bound + */ + eProsima_user_DllExport LBound bound() const + { + return m_bound; + } + + /*! + * @brief This function returns a reference to member bound + * @return Reference to member bound + */ + eProsima_user_DllExport LBound& bound() + { + return m_bound; + } + + + +private: + + LBound m_bound{0}; + +}; +/*! + * @brief This class represents the structure PlainCollectionHeader defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class PlainCollectionHeader +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport PlainCollectionHeader() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~PlainCollectionHeader() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object PlainCollectionHeader that will be copied. + */ + eProsima_user_DllExport PlainCollectionHeader( + const PlainCollectionHeader& x) + { + m_equiv_kind = x.m_equiv_kind; + + m_element_flags = x.m_element_flags; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object PlainCollectionHeader that will be copied. + */ + eProsima_user_DllExport PlainCollectionHeader( + PlainCollectionHeader&& x) noexcept + { + m_equiv_kind = x.m_equiv_kind; + m_element_flags = std::move(x.m_element_flags); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object PlainCollectionHeader that will be copied. + */ + eProsima_user_DllExport PlainCollectionHeader& operator =( + const PlainCollectionHeader& x) + { + + m_equiv_kind = x.m_equiv_kind; + + m_element_flags = x.m_element_flags; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object PlainCollectionHeader that will be copied. + */ + eProsima_user_DllExport PlainCollectionHeader& operator =( + PlainCollectionHeader&& x) noexcept + { + + m_equiv_kind = x.m_equiv_kind; + m_element_flags = std::move(x.m_element_flags); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x PlainCollectionHeader object to compare. + */ + eProsima_user_DllExport bool operator ==( + const PlainCollectionHeader& x) const + { + return (m_equiv_kind == x.m_equiv_kind && + m_element_flags == x.m_element_flags); + } + + /*! + * @brief Comparison operator. + * @param x PlainCollectionHeader object to compare. + */ + eProsima_user_DllExport bool operator !=( + const PlainCollectionHeader& x) const + { + return !(*this == x); + } + + /*! + * @brief This function sets a value in member equiv_kind + * @param _equiv_kind New value for member equiv_kind + */ + eProsima_user_DllExport void equiv_kind( + EquivalenceKind _equiv_kind) + { + m_equiv_kind = _equiv_kind; + } + + /*! + * @brief This function returns the value of member equiv_kind + * @return Value of member equiv_kind + */ + eProsima_user_DllExport EquivalenceKind equiv_kind() const + { + return m_equiv_kind; + } + + /*! + * @brief This function returns a reference to member equiv_kind + * @return Reference to member equiv_kind + */ + eProsima_user_DllExport EquivalenceKind& equiv_kind() + { + return m_equiv_kind; + } + + + /*! + * @brief This function copies the value in member element_flags + * @param _element_flags New value to be copied in member element_flags + */ + eProsima_user_DllExport void element_flags( + const CollectionElementFlag& _element_flags) + { + m_element_flags = _element_flags; + } + + /*! + * @brief This function moves the value in member element_flags + * @param _element_flags New value to be moved in member element_flags + */ + eProsima_user_DllExport void element_flags( + CollectionElementFlag&& _element_flags) + { + m_element_flags = std::move(_element_flags); + } + + /*! + * @brief This function returns a constant reference to member element_flags + * @return Constant reference to member element_flags + */ + eProsima_user_DllExport const CollectionElementFlag& element_flags() const + { + return m_element_flags; + } + + /*! + * @brief This function returns a reference to member element_flags + * @return Reference to member element_flags + */ + eProsima_user_DllExport CollectionElementFlag& element_flags() + { + return m_element_flags; + } + + + +private: + + EquivalenceKind m_equiv_kind{0}; + CollectionElementFlag m_element_flags{0}; + +}; +/*! + * @brief This class represents the structure PlainSequenceSElemDefn defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class PlainSequenceSElemDefn +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport PlainSequenceSElemDefn() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~PlainSequenceSElemDefn() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object PlainSequenceSElemDefn that will be copied. + */ + eProsima_user_DllExport PlainSequenceSElemDefn( + const PlainSequenceSElemDefn& x) + { + m_header = x.m_header; + + m_bound = x.m_bound; + + m_element_identifier = x.m_element_identifier; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object PlainSequenceSElemDefn that will be copied. + */ + eProsima_user_DllExport PlainSequenceSElemDefn( + PlainSequenceSElemDefn&& x) noexcept + { + m_header = std::move(x.m_header); + m_bound = x.m_bound; + m_element_identifier = std::move(x.m_element_identifier); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object PlainSequenceSElemDefn that will be copied. + */ + eProsima_user_DllExport PlainSequenceSElemDefn& operator =( + const PlainSequenceSElemDefn& x) + { + + m_header = x.m_header; + + m_bound = x.m_bound; + + m_element_identifier = x.m_element_identifier; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object PlainSequenceSElemDefn that will be copied. + */ + eProsima_user_DllExport PlainSequenceSElemDefn& operator =( + PlainSequenceSElemDefn&& x) noexcept + { + + m_header = std::move(x.m_header); + m_bound = x.m_bound; + m_element_identifier = std::move(x.m_element_identifier); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x PlainSequenceSElemDefn object to compare. + */ + eProsima_user_DllExport bool operator ==( + const PlainSequenceSElemDefn& x) const + { + return (m_header == x.m_header && + m_bound == x.m_bound && + m_element_identifier == x.m_element_identifier); + } + + /*! + * @brief Comparison operator. + * @param x PlainSequenceSElemDefn object to compare. + */ + eProsima_user_DllExport bool operator !=( + const PlainSequenceSElemDefn& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member header + * @param _header New value to be copied in member header + */ + eProsima_user_DllExport void header( + const PlainCollectionHeader& _header) + { + m_header = _header; + } + + /*! + * @brief This function moves the value in member header + * @param _header New value to be moved in member header + */ + eProsima_user_DllExport void header( + PlainCollectionHeader&& _header) + { + m_header = std::move(_header); + } + + /*! + * @brief This function returns a constant reference to member header + * @return Constant reference to member header + */ + eProsima_user_DllExport const PlainCollectionHeader& header() const + { + return m_header; + } + + /*! + * @brief This function returns a reference to member header + * @return Reference to member header + */ + eProsima_user_DllExport PlainCollectionHeader& header() + { + return m_header; + } + + + /*! + * @brief This function sets a value in member bound + * @param _bound New value for member bound + */ + eProsima_user_DllExport void bound( + SBound _bound) + { + m_bound = _bound; + } + + /*! + * @brief This function returns the value of member bound + * @return Value of member bound + */ + eProsima_user_DllExport SBound bound() const + { + return m_bound; + } + + /*! + * @brief This function returns a reference to member bound + * @return Reference to member bound + */ + eProsima_user_DllExport SBound& bound() + { + return m_bound; + } + + + /*! + * @brief This function copies the value in member element_identifier + * @param _element_identifier New value to be copied in member element_identifier + */ + eProsima_user_DllExport void element_identifier( + const eprosima::fastcdr::external& _element_identifier) + { + m_element_identifier = _element_identifier; + } + + /*! + * @brief This function moves the value in member element_identifier + * @param _element_identifier New value to be moved in member element_identifier + */ + eProsima_user_DllExport void element_identifier( + eprosima::fastcdr::external&& _element_identifier) + { + m_element_identifier = std::move(_element_identifier); + } + + /*! + * @brief This function returns a constant reference to member element_identifier + * @return Constant reference to member element_identifier + */ + eProsima_user_DllExport const eprosima::fastcdr::external& element_identifier() const + { + return m_element_identifier; + } + + /*! + * @brief This function returns a reference to member element_identifier + * @return Reference to member element_identifier + */ + eProsima_user_DllExport eprosima::fastcdr::external& element_identifier() + { + return m_element_identifier; + } + + + +private: + + PlainCollectionHeader m_header; + SBound m_bound{0}; + eprosima::fastcdr::external m_element_identifier; + +}; +/*! + * @brief This class represents the structure PlainSequenceLElemDefn defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class PlainSequenceLElemDefn +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport PlainSequenceLElemDefn() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~PlainSequenceLElemDefn() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object PlainSequenceLElemDefn that will be copied. + */ + eProsima_user_DllExport PlainSequenceLElemDefn( + const PlainSequenceLElemDefn& x) + { + m_header = x.m_header; + + m_bound = x.m_bound; + + m_element_identifier = x.m_element_identifier; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object PlainSequenceLElemDefn that will be copied. + */ + eProsima_user_DllExport PlainSequenceLElemDefn( + PlainSequenceLElemDefn&& x) noexcept + { + m_header = std::move(x.m_header); + m_bound = x.m_bound; + m_element_identifier = std::move(x.m_element_identifier); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object PlainSequenceLElemDefn that will be copied. + */ + eProsima_user_DllExport PlainSequenceLElemDefn& operator =( + const PlainSequenceLElemDefn& x) + { + + m_header = x.m_header; + + m_bound = x.m_bound; + + m_element_identifier = x.m_element_identifier; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object PlainSequenceLElemDefn that will be copied. + */ + eProsima_user_DllExport PlainSequenceLElemDefn& operator =( + PlainSequenceLElemDefn&& x) noexcept + { + + m_header = std::move(x.m_header); + m_bound = x.m_bound; + m_element_identifier = std::move(x.m_element_identifier); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x PlainSequenceLElemDefn object to compare. + */ + eProsima_user_DllExport bool operator ==( + const PlainSequenceLElemDefn& x) const + { + return (m_header == x.m_header && + m_bound == x.m_bound && + m_element_identifier == x.m_element_identifier); + } + + /*! + * @brief Comparison operator. + * @param x PlainSequenceLElemDefn object to compare. + */ + eProsima_user_DllExport bool operator !=( + const PlainSequenceLElemDefn& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member header + * @param _header New value to be copied in member header + */ + eProsima_user_DllExport void header( + const PlainCollectionHeader& _header) + { + m_header = _header; + } + + /*! + * @brief This function moves the value in member header + * @param _header New value to be moved in member header + */ + eProsima_user_DllExport void header( + PlainCollectionHeader&& _header) + { + m_header = std::move(_header); + } + + /*! + * @brief This function returns a constant reference to member header + * @return Constant reference to member header + */ + eProsima_user_DllExport const PlainCollectionHeader& header() const + { + return m_header; + } + + /*! + * @brief This function returns a reference to member header + * @return Reference to member header + */ + eProsima_user_DllExport PlainCollectionHeader& header() + { + return m_header; + } + + + /*! + * @brief This function sets a value in member bound + * @param _bound New value for member bound + */ + eProsima_user_DllExport void bound( + LBound _bound) + { + m_bound = _bound; + } + + /*! + * @brief This function returns the value of member bound + * @return Value of member bound + */ + eProsima_user_DllExport LBound bound() const + { + return m_bound; + } + + /*! + * @brief This function returns a reference to member bound + * @return Reference to member bound + */ + eProsima_user_DllExport LBound& bound() + { + return m_bound; + } + + + /*! + * @brief This function copies the value in member element_identifier + * @param _element_identifier New value to be copied in member element_identifier + */ + eProsima_user_DllExport void element_identifier( + const eprosima::fastcdr::external& _element_identifier) + { + m_element_identifier = _element_identifier; + } + + /*! + * @brief This function moves the value in member element_identifier + * @param _element_identifier New value to be moved in member element_identifier + */ + eProsima_user_DllExport void element_identifier( + eprosima::fastcdr::external&& _element_identifier) + { + m_element_identifier = std::move(_element_identifier); + } + + /*! + * @brief This function returns a constant reference to member element_identifier + * @return Constant reference to member element_identifier + */ + eProsima_user_DllExport const eprosima::fastcdr::external& element_identifier() const + { + return m_element_identifier; + } + + /*! + * @brief This function returns a reference to member element_identifier + * @return Reference to member element_identifier + */ + eProsima_user_DllExport eprosima::fastcdr::external& element_identifier() + { + return m_element_identifier; + } + + + +private: + + PlainCollectionHeader m_header; + LBound m_bound{0}; + eprosima::fastcdr::external m_element_identifier; + +}; +/*! + * @brief This class represents the structure PlainArraySElemDefn defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class PlainArraySElemDefn +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport PlainArraySElemDefn() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~PlainArraySElemDefn() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object PlainArraySElemDefn that will be copied. + */ + eProsima_user_DllExport PlainArraySElemDefn( + const PlainArraySElemDefn& x) + { + m_header = x.m_header; + + m_array_bound_seq = x.m_array_bound_seq; + + m_element_identifier = x.m_element_identifier; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object PlainArraySElemDefn that will be copied. + */ + eProsima_user_DllExport PlainArraySElemDefn( + PlainArraySElemDefn&& x) noexcept + { + m_header = std::move(x.m_header); + m_array_bound_seq = std::move(x.m_array_bound_seq); + m_element_identifier = std::move(x.m_element_identifier); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object PlainArraySElemDefn that will be copied. + */ + eProsima_user_DllExport PlainArraySElemDefn& operator =( + const PlainArraySElemDefn& x) + { + + m_header = x.m_header; + + m_array_bound_seq = x.m_array_bound_seq; + + m_element_identifier = x.m_element_identifier; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object PlainArraySElemDefn that will be copied. + */ + eProsima_user_DllExport PlainArraySElemDefn& operator =( + PlainArraySElemDefn&& x) noexcept + { + + m_header = std::move(x.m_header); + m_array_bound_seq = std::move(x.m_array_bound_seq); + m_element_identifier = std::move(x.m_element_identifier); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x PlainArraySElemDefn object to compare. + */ + eProsima_user_DllExport bool operator ==( + const PlainArraySElemDefn& x) const + { + return (m_header == x.m_header && + m_array_bound_seq == x.m_array_bound_seq && + m_element_identifier == x.m_element_identifier); + } + + /*! + * @brief Comparison operator. + * @param x PlainArraySElemDefn object to compare. + */ + eProsima_user_DllExport bool operator !=( + const PlainArraySElemDefn& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member header + * @param _header New value to be copied in member header + */ + eProsima_user_DllExport void header( + const PlainCollectionHeader& _header) + { + m_header = _header; + } + + /*! + * @brief This function moves the value in member header + * @param _header New value to be moved in member header + */ + eProsima_user_DllExport void header( + PlainCollectionHeader&& _header) + { + m_header = std::move(_header); + } + + /*! + * @brief This function returns a constant reference to member header + * @return Constant reference to member header + */ + eProsima_user_DllExport const PlainCollectionHeader& header() const + { + return m_header; + } + + /*! + * @brief This function returns a reference to member header + * @return Reference to member header + */ + eProsima_user_DllExport PlainCollectionHeader& header() + { + return m_header; + } + + + /*! + * @brief This function copies the value in member array_bound_seq + * @param _array_bound_seq New value to be copied in member array_bound_seq + */ + eProsima_user_DllExport void array_bound_seq( + const SBoundSeq& _array_bound_seq) + { + m_array_bound_seq = _array_bound_seq; + } + + /*! + * @brief This function moves the value in member array_bound_seq + * @param _array_bound_seq New value to be moved in member array_bound_seq + */ + eProsima_user_DllExport void array_bound_seq( + SBoundSeq&& _array_bound_seq) + { + m_array_bound_seq = std::move(_array_bound_seq); + } + + /*! + * @brief This function returns a constant reference to member array_bound_seq + * @return Constant reference to member array_bound_seq + */ + eProsima_user_DllExport const SBoundSeq& array_bound_seq() const + { + return m_array_bound_seq; + } + + /*! + * @brief This function returns a reference to member array_bound_seq + * @return Reference to member array_bound_seq + */ + eProsima_user_DllExport SBoundSeq& array_bound_seq() + { + return m_array_bound_seq; + } + + + /*! + * @brief This function copies the value in member element_identifier + * @param _element_identifier New value to be copied in member element_identifier + */ + eProsima_user_DllExport void element_identifier( + const eprosima::fastcdr::external& _element_identifier) + { + m_element_identifier = _element_identifier; + } + + /*! + * @brief This function moves the value in member element_identifier + * @param _element_identifier New value to be moved in member element_identifier + */ + eProsima_user_DllExport void element_identifier( + eprosima::fastcdr::external&& _element_identifier) + { + m_element_identifier = std::move(_element_identifier); + } + + /*! + * @brief This function returns a constant reference to member element_identifier + * @return Constant reference to member element_identifier + */ + eProsima_user_DllExport const eprosima::fastcdr::external& element_identifier() const + { + return m_element_identifier; + } + + /*! + * @brief This function returns a reference to member element_identifier + * @return Reference to member element_identifier + */ + eProsima_user_DllExport eprosima::fastcdr::external& element_identifier() + { + return m_element_identifier; + } + + + +private: + + PlainCollectionHeader m_header; + SBoundSeq m_array_bound_seq; + eprosima::fastcdr::external m_element_identifier; + +}; +/*! + * @brief This class represents the structure PlainArrayLElemDefn defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class PlainArrayLElemDefn +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport PlainArrayLElemDefn() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~PlainArrayLElemDefn() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object PlainArrayLElemDefn that will be copied. + */ + eProsima_user_DllExport PlainArrayLElemDefn( + const PlainArrayLElemDefn& x) + { + m_header = x.m_header; + + m_array_bound_seq = x.m_array_bound_seq; + + m_element_identifier = x.m_element_identifier; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object PlainArrayLElemDefn that will be copied. + */ + eProsima_user_DllExport PlainArrayLElemDefn( + PlainArrayLElemDefn&& x) noexcept + { + m_header = std::move(x.m_header); + m_array_bound_seq = std::move(x.m_array_bound_seq); + m_element_identifier = std::move(x.m_element_identifier); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object PlainArrayLElemDefn that will be copied. + */ + eProsima_user_DllExport PlainArrayLElemDefn& operator =( + const PlainArrayLElemDefn& x) + { + + m_header = x.m_header; + + m_array_bound_seq = x.m_array_bound_seq; + + m_element_identifier = x.m_element_identifier; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object PlainArrayLElemDefn that will be copied. + */ + eProsima_user_DllExport PlainArrayLElemDefn& operator =( + PlainArrayLElemDefn&& x) noexcept + { + + m_header = std::move(x.m_header); + m_array_bound_seq = std::move(x.m_array_bound_seq); + m_element_identifier = std::move(x.m_element_identifier); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x PlainArrayLElemDefn object to compare. + */ + eProsima_user_DllExport bool operator ==( + const PlainArrayLElemDefn& x) const + { + return (m_header == x.m_header && + m_array_bound_seq == x.m_array_bound_seq && + m_element_identifier == x.m_element_identifier); + } + + /*! + * @brief Comparison operator. + * @param x PlainArrayLElemDefn object to compare. + */ + eProsima_user_DllExport bool operator !=( + const PlainArrayLElemDefn& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member header + * @param _header New value to be copied in member header + */ + eProsima_user_DllExport void header( + const PlainCollectionHeader& _header) + { + m_header = _header; + } + + /*! + * @brief This function moves the value in member header + * @param _header New value to be moved in member header + */ + eProsima_user_DllExport void header( + PlainCollectionHeader&& _header) + { + m_header = std::move(_header); + } + + /*! + * @brief This function returns a constant reference to member header + * @return Constant reference to member header + */ + eProsima_user_DllExport const PlainCollectionHeader& header() const + { + return m_header; + } + + /*! + * @brief This function returns a reference to member header + * @return Reference to member header + */ + eProsima_user_DllExport PlainCollectionHeader& header() + { + return m_header; + } + + + /*! + * @brief This function copies the value in member array_bound_seq + * @param _array_bound_seq New value to be copied in member array_bound_seq + */ + eProsima_user_DllExport void array_bound_seq( + const LBoundSeq& _array_bound_seq) + { + m_array_bound_seq = _array_bound_seq; + } + + /*! + * @brief This function moves the value in member array_bound_seq + * @param _array_bound_seq New value to be moved in member array_bound_seq + */ + eProsima_user_DllExport void array_bound_seq( + LBoundSeq&& _array_bound_seq) + { + m_array_bound_seq = std::move(_array_bound_seq); + } + + /*! + * @brief This function returns a constant reference to member array_bound_seq + * @return Constant reference to member array_bound_seq + */ + eProsima_user_DllExport const LBoundSeq& array_bound_seq() const + { + return m_array_bound_seq; + } + + /*! + * @brief This function returns a reference to member array_bound_seq + * @return Reference to member array_bound_seq + */ + eProsima_user_DllExport LBoundSeq& array_bound_seq() + { + return m_array_bound_seq; + } + + + /*! + * @brief This function copies the value in member element_identifier + * @param _element_identifier New value to be copied in member element_identifier + */ + eProsima_user_DllExport void element_identifier( + const eprosima::fastcdr::external& _element_identifier) + { + m_element_identifier = _element_identifier; + } + + /*! + * @brief This function moves the value in member element_identifier + * @param _element_identifier New value to be moved in member element_identifier + */ + eProsima_user_DllExport void element_identifier( + eprosima::fastcdr::external&& _element_identifier) + { + m_element_identifier = std::move(_element_identifier); + } + + /*! + * @brief This function returns a constant reference to member element_identifier + * @return Constant reference to member element_identifier + */ + eProsima_user_DllExport const eprosima::fastcdr::external& element_identifier() const + { + return m_element_identifier; + } + + /*! + * @brief This function returns a reference to member element_identifier + * @return Reference to member element_identifier + */ + eProsima_user_DllExport eprosima::fastcdr::external& element_identifier() + { + return m_element_identifier; + } + + + +private: + + PlainCollectionHeader m_header; + LBoundSeq m_array_bound_seq; + eprosima::fastcdr::external m_element_identifier; + +}; +/*! + * @brief This class represents the structure PlainMapSTypeDefn defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class PlainMapSTypeDefn +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport PlainMapSTypeDefn() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~PlainMapSTypeDefn() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object PlainMapSTypeDefn that will be copied. + */ + eProsima_user_DllExport PlainMapSTypeDefn( + const PlainMapSTypeDefn& x) + { + m_header = x.m_header; + + m_bound = x.m_bound; + + m_element_identifier = x.m_element_identifier; + + m_key_flags = x.m_key_flags; + + m_key_identifier = x.m_key_identifier; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object PlainMapSTypeDefn that will be copied. + */ + eProsima_user_DllExport PlainMapSTypeDefn( + PlainMapSTypeDefn&& x) noexcept + { + m_header = std::move(x.m_header); + m_bound = x.m_bound; + m_element_identifier = std::move(x.m_element_identifier); + m_key_flags = std::move(x.m_key_flags); + m_key_identifier = std::move(x.m_key_identifier); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object PlainMapSTypeDefn that will be copied. + */ + eProsima_user_DllExport PlainMapSTypeDefn& operator =( + const PlainMapSTypeDefn& x) + { + + m_header = x.m_header; + + m_bound = x.m_bound; + + m_element_identifier = x.m_element_identifier; + + m_key_flags = x.m_key_flags; + + m_key_identifier = x.m_key_identifier; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object PlainMapSTypeDefn that will be copied. + */ + eProsima_user_DllExport PlainMapSTypeDefn& operator =( + PlainMapSTypeDefn&& x) noexcept + { + + m_header = std::move(x.m_header); + m_bound = x.m_bound; + m_element_identifier = std::move(x.m_element_identifier); + m_key_flags = std::move(x.m_key_flags); + m_key_identifier = std::move(x.m_key_identifier); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x PlainMapSTypeDefn object to compare. + */ + eProsima_user_DllExport bool operator ==( + const PlainMapSTypeDefn& x) const + { + return (m_header == x.m_header && + m_bound == x.m_bound && + m_element_identifier == x.m_element_identifier && + m_key_flags == x.m_key_flags && + m_key_identifier == x.m_key_identifier); + } + + /*! + * @brief Comparison operator. + * @param x PlainMapSTypeDefn object to compare. + */ + eProsima_user_DllExport bool operator !=( + const PlainMapSTypeDefn& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member header + * @param _header New value to be copied in member header + */ + eProsima_user_DllExport void header( + const PlainCollectionHeader& _header) + { + m_header = _header; + } + + /*! + * @brief This function moves the value in member header + * @param _header New value to be moved in member header + */ + eProsima_user_DllExport void header( + PlainCollectionHeader&& _header) + { + m_header = std::move(_header); + } + + /*! + * @brief This function returns a constant reference to member header + * @return Constant reference to member header + */ + eProsima_user_DllExport const PlainCollectionHeader& header() const + { + return m_header; + } + + /*! + * @brief This function returns a reference to member header + * @return Reference to member header + */ + eProsima_user_DllExport PlainCollectionHeader& header() + { + return m_header; + } + + + /*! + * @brief This function sets a value in member bound + * @param _bound New value for member bound + */ + eProsima_user_DllExport void bound( + SBound _bound) + { + m_bound = _bound; + } + + /*! + * @brief This function returns the value of member bound + * @return Value of member bound + */ + eProsima_user_DllExport SBound bound() const + { + return m_bound; + } + + /*! + * @brief This function returns a reference to member bound + * @return Reference to member bound + */ + eProsima_user_DllExport SBound& bound() + { + return m_bound; + } + + + /*! + * @brief This function copies the value in member element_identifier + * @param _element_identifier New value to be copied in member element_identifier + */ + eProsima_user_DllExport void element_identifier( + const eprosima::fastcdr::external& _element_identifier) + { + m_element_identifier = _element_identifier; + } + + /*! + * @brief This function moves the value in member element_identifier + * @param _element_identifier New value to be moved in member element_identifier + */ + eProsima_user_DllExport void element_identifier( + eprosima::fastcdr::external&& _element_identifier) + { + m_element_identifier = std::move(_element_identifier); + } + + /*! + * @brief This function returns a constant reference to member element_identifier + * @return Constant reference to member element_identifier + */ + eProsima_user_DllExport const eprosima::fastcdr::external& element_identifier() const + { + return m_element_identifier; + } + + /*! + * @brief This function returns a reference to member element_identifier + * @return Reference to member element_identifier + */ + eProsima_user_DllExport eprosima::fastcdr::external& element_identifier() + { + return m_element_identifier; + } + + + /*! + * @brief This function copies the value in member key_flags + * @param _key_flags New value to be copied in member key_flags + */ + eProsima_user_DllExport void key_flags( + const CollectionElementFlag& _key_flags) + { + m_key_flags = _key_flags; + } + + /*! + * @brief This function moves the value in member key_flags + * @param _key_flags New value to be moved in member key_flags + */ + eProsima_user_DllExport void key_flags( + CollectionElementFlag&& _key_flags) + { + m_key_flags = std::move(_key_flags); + } + + /*! + * @brief This function returns a constant reference to member key_flags + * @return Constant reference to member key_flags + */ + eProsima_user_DllExport const CollectionElementFlag& key_flags() const + { + return m_key_flags; + } + + /*! + * @brief This function returns a reference to member key_flags + * @return Reference to member key_flags + */ + eProsima_user_DllExport CollectionElementFlag& key_flags() + { + return m_key_flags; + } + + + /*! + * @brief This function copies the value in member key_identifier + * @param _key_identifier New value to be copied in member key_identifier + */ + eProsima_user_DllExport void key_identifier( + const eprosima::fastcdr::external& _key_identifier) + { + m_key_identifier = _key_identifier; + } + + /*! + * @brief This function moves the value in member key_identifier + * @param _key_identifier New value to be moved in member key_identifier + */ + eProsima_user_DllExport void key_identifier( + eprosima::fastcdr::external&& _key_identifier) + { + m_key_identifier = std::move(_key_identifier); + } + + /*! + * @brief This function returns a constant reference to member key_identifier + * @return Constant reference to member key_identifier + */ + eProsima_user_DllExport const eprosima::fastcdr::external& key_identifier() const + { + return m_key_identifier; + } + + /*! + * @brief This function returns a reference to member key_identifier + * @return Reference to member key_identifier + */ + eProsima_user_DllExport eprosima::fastcdr::external& key_identifier() + { + return m_key_identifier; + } + + + +private: + + PlainCollectionHeader m_header; + SBound m_bound{0}; + eprosima::fastcdr::external m_element_identifier; + CollectionElementFlag m_key_flags{0}; + eprosima::fastcdr::external m_key_identifier; + +}; +/*! + * @brief This class represents the structure PlainMapLTypeDefn defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class PlainMapLTypeDefn +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport PlainMapLTypeDefn() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~PlainMapLTypeDefn() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object PlainMapLTypeDefn that will be copied. + */ + eProsima_user_DllExport PlainMapLTypeDefn( + const PlainMapLTypeDefn& x) + { + m_header = x.m_header; + + m_bound = x.m_bound; + + m_element_identifier = x.m_element_identifier; + + m_key_flags = x.m_key_flags; + + m_key_identifier = x.m_key_identifier; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object PlainMapLTypeDefn that will be copied. + */ + eProsima_user_DllExport PlainMapLTypeDefn( + PlainMapLTypeDefn&& x) noexcept + { + m_header = std::move(x.m_header); + m_bound = x.m_bound; + m_element_identifier = std::move(x.m_element_identifier); + m_key_flags = std::move(x.m_key_flags); + m_key_identifier = std::move(x.m_key_identifier); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object PlainMapLTypeDefn that will be copied. + */ + eProsima_user_DllExport PlainMapLTypeDefn& operator =( + const PlainMapLTypeDefn& x) + { + + m_header = x.m_header; + + m_bound = x.m_bound; + + m_element_identifier = x.m_element_identifier; + + m_key_flags = x.m_key_flags; + + m_key_identifier = x.m_key_identifier; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object PlainMapLTypeDefn that will be copied. + */ + eProsima_user_DllExport PlainMapLTypeDefn& operator =( + PlainMapLTypeDefn&& x) noexcept + { + + m_header = std::move(x.m_header); + m_bound = x.m_bound; + m_element_identifier = std::move(x.m_element_identifier); + m_key_flags = std::move(x.m_key_flags); + m_key_identifier = std::move(x.m_key_identifier); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x PlainMapLTypeDefn object to compare. + */ + eProsima_user_DllExport bool operator ==( + const PlainMapLTypeDefn& x) const + { + return (m_header == x.m_header && + m_bound == x.m_bound && + m_element_identifier == x.m_element_identifier && + m_key_flags == x.m_key_flags && + m_key_identifier == x.m_key_identifier); + } + + /*! + * @brief Comparison operator. + * @param x PlainMapLTypeDefn object to compare. + */ + eProsima_user_DllExport bool operator !=( + const PlainMapLTypeDefn& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member header + * @param _header New value to be copied in member header + */ + eProsima_user_DllExport void header( + const PlainCollectionHeader& _header) + { + m_header = _header; + } + + /*! + * @brief This function moves the value in member header + * @param _header New value to be moved in member header + */ + eProsima_user_DllExport void header( + PlainCollectionHeader&& _header) + { + m_header = std::move(_header); + } + + /*! + * @brief This function returns a constant reference to member header + * @return Constant reference to member header + */ + eProsima_user_DllExport const PlainCollectionHeader& header() const + { + return m_header; + } + + /*! + * @brief This function returns a reference to member header + * @return Reference to member header + */ + eProsima_user_DllExport PlainCollectionHeader& header() + { + return m_header; + } + + + /*! + * @brief This function sets a value in member bound + * @param _bound New value for member bound + */ + eProsima_user_DllExport void bound( + LBound _bound) + { + m_bound = _bound; + } + + /*! + * @brief This function returns the value of member bound + * @return Value of member bound + */ + eProsima_user_DllExport LBound bound() const + { + return m_bound; + } + + /*! + * @brief This function returns a reference to member bound + * @return Reference to member bound + */ + eProsima_user_DllExport LBound& bound() + { + return m_bound; + } + + + /*! + * @brief This function copies the value in member element_identifier + * @param _element_identifier New value to be copied in member element_identifier + */ + eProsima_user_DllExport void element_identifier( + const eprosima::fastcdr::external& _element_identifier) + { + m_element_identifier = _element_identifier; + } + + /*! + * @brief This function moves the value in member element_identifier + * @param _element_identifier New value to be moved in member element_identifier + */ + eProsima_user_DllExport void element_identifier( + eprosima::fastcdr::external&& _element_identifier) + { + m_element_identifier = std::move(_element_identifier); + } + + /*! + * @brief This function returns a constant reference to member element_identifier + * @return Constant reference to member element_identifier + */ + eProsima_user_DllExport const eprosima::fastcdr::external& element_identifier() const + { + return m_element_identifier; + } + + /*! + * @brief This function returns a reference to member element_identifier + * @return Reference to member element_identifier + */ + eProsima_user_DllExport eprosima::fastcdr::external& element_identifier() + { + return m_element_identifier; + } + + + /*! + * @brief This function copies the value in member key_flags + * @param _key_flags New value to be copied in member key_flags + */ + eProsima_user_DllExport void key_flags( + const CollectionElementFlag& _key_flags) + { + m_key_flags = _key_flags; + } + + /*! + * @brief This function moves the value in member key_flags + * @param _key_flags New value to be moved in member key_flags + */ + eProsima_user_DllExport void key_flags( + CollectionElementFlag&& _key_flags) + { + m_key_flags = std::move(_key_flags); + } + + /*! + * @brief This function returns a constant reference to member key_flags + * @return Constant reference to member key_flags + */ + eProsima_user_DllExport const CollectionElementFlag& key_flags() const + { + return m_key_flags; + } + + /*! + * @brief This function returns a reference to member key_flags + * @return Reference to member key_flags + */ + eProsima_user_DllExport CollectionElementFlag& key_flags() + { + return m_key_flags; + } + + + /*! + * @brief This function copies the value in member key_identifier + * @param _key_identifier New value to be copied in member key_identifier + */ + eProsima_user_DllExport void key_identifier( + const eprosima::fastcdr::external& _key_identifier) + { + m_key_identifier = _key_identifier; + } + + /*! + * @brief This function moves the value in member key_identifier + * @param _key_identifier New value to be moved in member key_identifier + */ + eProsima_user_DllExport void key_identifier( + eprosima::fastcdr::external&& _key_identifier) + { + m_key_identifier = std::move(_key_identifier); + } + + /*! + * @brief This function returns a constant reference to member key_identifier + * @return Constant reference to member key_identifier + */ + eProsima_user_DllExport const eprosima::fastcdr::external& key_identifier() const + { + return m_key_identifier; + } + + /*! + * @brief This function returns a reference to member key_identifier + * @return Reference to member key_identifier + */ + eProsima_user_DllExport eprosima::fastcdr::external& key_identifier() + { + return m_key_identifier; + } + + + +private: + + PlainCollectionHeader m_header; + LBound m_bound{0}; + eprosima::fastcdr::external m_element_identifier; + CollectionElementFlag m_key_flags{0}; + eprosima::fastcdr::external m_key_identifier; + +}; +/*! + * @brief This class represents the structure StronglyConnectedComponentId defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class StronglyConnectedComponentId +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport StronglyConnectedComponentId() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~StronglyConnectedComponentId() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object StronglyConnectedComponentId that will be copied. + */ + eProsima_user_DllExport StronglyConnectedComponentId( + const StronglyConnectedComponentId& x) + { + m_sc_component_id = x.m_sc_component_id; + + m_scc_length = x.m_scc_length; + + m_scc_index = x.m_scc_index; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object StronglyConnectedComponentId that will be copied. + */ + eProsima_user_DllExport StronglyConnectedComponentId( + StronglyConnectedComponentId&& x) noexcept + { + m_sc_component_id = std::move(x.m_sc_component_id); + m_scc_length = x.m_scc_length; + m_scc_index = x.m_scc_index; + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object StronglyConnectedComponentId that will be copied. + */ + eProsima_user_DllExport StronglyConnectedComponentId& operator =( + const StronglyConnectedComponentId& x) + { + + m_sc_component_id = x.m_sc_component_id; + + m_scc_length = x.m_scc_length; + + m_scc_index = x.m_scc_index; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object StronglyConnectedComponentId that will be copied. + */ + eProsima_user_DllExport StronglyConnectedComponentId& operator =( + StronglyConnectedComponentId&& x) noexcept + { + + m_sc_component_id = std::move(x.m_sc_component_id); + m_scc_length = x.m_scc_length; + m_scc_index = x.m_scc_index; + return *this; + } + + /*! + * @brief Comparison operator. + * @param x StronglyConnectedComponentId object to compare. + */ + eProsima_user_DllExport bool operator ==( + const StronglyConnectedComponentId& x) const + { + return (m_sc_component_id == x.m_sc_component_id && + m_scc_length == x.m_scc_length && + m_scc_index == x.m_scc_index); + } + + /*! + * @brief Comparison operator. + * @param x StronglyConnectedComponentId object to compare. + */ + eProsima_user_DllExport bool operator !=( + const StronglyConnectedComponentId& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member sc_component_id + * @param _sc_component_id New value to be copied in member sc_component_id + */ + eProsima_user_DllExport void sc_component_id( + const TypeObjectHashId& _sc_component_id) + { + m_sc_component_id = _sc_component_id; + } + + /*! + * @brief This function moves the value in member sc_component_id + * @param _sc_component_id New value to be moved in member sc_component_id + */ + eProsima_user_DllExport void sc_component_id( + TypeObjectHashId&& _sc_component_id) + { + m_sc_component_id = std::move(_sc_component_id); + } + + /*! + * @brief This function returns a constant reference to member sc_component_id + * @return Constant reference to member sc_component_id + */ + eProsima_user_DllExport const TypeObjectHashId& sc_component_id() const + { + return m_sc_component_id; + } + + /*! + * @brief This function returns a reference to member sc_component_id + * @return Reference to member sc_component_id + */ + eProsima_user_DllExport TypeObjectHashId& sc_component_id() + { + return m_sc_component_id; + } + + + /*! + * @brief This function sets a value in member scc_length + * @param _scc_length New value for member scc_length + */ + eProsima_user_DllExport void scc_length( + int32_t _scc_length) + { + m_scc_length = _scc_length; + } + + /*! + * @brief This function returns the value of member scc_length + * @return Value of member scc_length + */ + eProsima_user_DllExport int32_t scc_length() const + { + return m_scc_length; + } + + /*! + * @brief This function returns a reference to member scc_length + * @return Reference to member scc_length + */ + eProsima_user_DllExport int32_t& scc_length() + { + return m_scc_length; + } + + + /*! + * @brief This function sets a value in member scc_index + * @param _scc_index New value for member scc_index + */ + eProsima_user_DllExport void scc_index( + int32_t _scc_index) + { + m_scc_index = _scc_index; + } + + /*! + * @brief This function returns the value of member scc_index + * @return Value of member scc_index + */ + eProsima_user_DllExport int32_t scc_index() const + { + return m_scc_index; + } + + /*! + * @brief This function returns a reference to member scc_index + * @return Reference to member scc_index + */ + eProsima_user_DllExport int32_t& scc_index() + { + return m_scc_index; + } + + + +private: + + TypeObjectHashId m_sc_component_id; + int32_t m_scc_length{0}; + int32_t m_scc_index{0}; + +}; +/*! + * @brief This class represents the structure ExtendedTypeDefn defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class ExtendedTypeDefn +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport ExtendedTypeDefn() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~ExtendedTypeDefn() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object ExtendedTypeDefn that will be copied. + */ + eProsima_user_DllExport ExtendedTypeDefn( + const ExtendedTypeDefn& x) + { + static_cast(x); + } + + /*! + * @brief Move constructor. + * @param x Reference to the object ExtendedTypeDefn that will be copied. + */ + eProsima_user_DllExport ExtendedTypeDefn( + ExtendedTypeDefn&& x) noexcept + { + static_cast(x); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object ExtendedTypeDefn that will be copied. + */ + eProsima_user_DllExport ExtendedTypeDefn& operator =( + const ExtendedTypeDefn& x) + { + + static_cast(x); + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object ExtendedTypeDefn that will be copied. + */ + eProsima_user_DllExport ExtendedTypeDefn& operator =( + ExtendedTypeDefn&& x) noexcept + { + + static_cast(x); + + return *this; + } + + /*! + * @brief Comparison operator. + * @param x ExtendedTypeDefn object to compare. + */ + eProsima_user_DllExport bool operator ==( + const ExtendedTypeDefn& x) const + { + static_cast(x); + return true; + } + + /*! + * @brief Comparison operator. + * @param x ExtendedTypeDefn object to compare. + */ + eProsima_user_DllExport bool operator !=( + const ExtendedTypeDefn& x) const + { + return !(*this == x); + } + + + +private: + + +}; +/*! + * @brief This class represents the union TypeIdentifier defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class TypeIdentifier +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport TypeIdentifier() + { + extended_defn_(); + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~TypeIdentifier() + { + if (member_destructor_) + { + member_destructor_(); + } + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object TypeIdentifier that will be copied. + */ + eProsima_user_DllExport TypeIdentifier( + const TypeIdentifier& x) + { + m__d = x.m__d; + + switch (x.selected_member_) + { + case 0x00000001: + string_sdefn_() = x.m_string_sdefn; + break; + + case 0x00000002: + string_ldefn_() = x.m_string_ldefn; + break; + + case 0x00000003: + seq_sdefn_() = x.m_seq_sdefn; + break; + + case 0x00000004: + seq_ldefn_() = x.m_seq_ldefn; + break; + + case 0x00000005: + array_sdefn_() = x.m_array_sdefn; + break; + + case 0x00000006: + array_ldefn_() = x.m_array_ldefn; + break; + + case 0x00000007: + map_sdefn_() = x.m_map_sdefn; + break; + + case 0x00000008: + map_ldefn_() = x.m_map_ldefn; + break; + + case 0x00000009: + sc_component_id_() = x.m_sc_component_id; + break; + + case 0x0000000a: + equivalence_hash_() = x.m_equivalence_hash; + break; + + case 0x0000000b: + extended_defn_() = x.m_extended_defn; + break; + + } + } + + /*! + * @brief Move constructor. + * @param x Reference to the object TypeIdentifier that will be copied. + */ + eProsima_user_DllExport TypeIdentifier( + TypeIdentifier&& x) noexcept + { + m__d = x.m__d; + + switch (x.selected_member_) + { + case 0x00000001: + string_sdefn_() = std::move(x.m_string_sdefn); + break; + + case 0x00000002: + string_ldefn_() = std::move(x.m_string_ldefn); + break; + + case 0x00000003: + seq_sdefn_() = std::move(x.m_seq_sdefn); + break; + + case 0x00000004: + seq_ldefn_() = std::move(x.m_seq_ldefn); + break; + + case 0x00000005: + array_sdefn_() = std::move(x.m_array_sdefn); + break; + + case 0x00000006: + array_ldefn_() = std::move(x.m_array_ldefn); + break; + + case 0x00000007: + map_sdefn_() = std::move(x.m_map_sdefn); + break; + + case 0x00000008: + map_ldefn_() = std::move(x.m_map_ldefn); + break; + + case 0x00000009: + sc_component_id_() = std::move(x.m_sc_component_id); + break; + + case 0x0000000a: + equivalence_hash_() = std::move(x.m_equivalence_hash); + break; + + case 0x0000000b: + extended_defn_() = std::move(x.m_extended_defn); + break; + + } + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object TypeIdentifier that will be copied. + */ + eProsima_user_DllExport TypeIdentifier& operator =( + const TypeIdentifier& x) + { + m__d = x.m__d; + + switch (x.selected_member_) + { + case 0x00000001: + string_sdefn_() = x.m_string_sdefn; + break; + + case 0x00000002: + string_ldefn_() = x.m_string_ldefn; + break; + + case 0x00000003: + seq_sdefn_() = x.m_seq_sdefn; + break; + + case 0x00000004: + seq_ldefn_() = x.m_seq_ldefn; + break; + + case 0x00000005: + array_sdefn_() = x.m_array_sdefn; + break; + + case 0x00000006: + array_ldefn_() = x.m_array_ldefn; + break; + + case 0x00000007: + map_sdefn_() = x.m_map_sdefn; + break; + + case 0x00000008: + map_ldefn_() = x.m_map_ldefn; + break; + + case 0x00000009: + sc_component_id_() = x.m_sc_component_id; + break; + + case 0x0000000a: + equivalence_hash_() = x.m_equivalence_hash; + break; + + case 0x0000000b: + extended_defn_() = x.m_extended_defn; + break; + + } + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object TypeIdentifier that will be copied. + */ + eProsima_user_DllExport TypeIdentifier& operator =( + TypeIdentifier&& x) noexcept + { + m__d = x.m__d; + + switch (x.selected_member_) + { + case 0x00000001: + string_sdefn_() = std::move(x.m_string_sdefn); + break; + + case 0x00000002: + string_ldefn_() = std::move(x.m_string_ldefn); + break; + + case 0x00000003: + seq_sdefn_() = std::move(x.m_seq_sdefn); + break; + + case 0x00000004: + seq_ldefn_() = std::move(x.m_seq_ldefn); + break; + + case 0x00000005: + array_sdefn_() = std::move(x.m_array_sdefn); + break; + + case 0x00000006: + array_ldefn_() = std::move(x.m_array_ldefn); + break; + + case 0x00000007: + map_sdefn_() = std::move(x.m_map_sdefn); + break; + + case 0x00000008: + map_ldefn_() = std::move(x.m_map_ldefn); + break; + + case 0x00000009: + sc_component_id_() = std::move(x.m_sc_component_id); + break; + + case 0x0000000a: + equivalence_hash_() = std::move(x.m_equivalence_hash); + break; + + case 0x0000000b: + extended_defn_() = std::move(x.m_extended_defn); + break; + + } + + return *this; + } + + /*! + * @brief Comparison operator. + * @param x TypeIdentifier object to compare. + */ + eProsima_user_DllExport bool operator ==( + const TypeIdentifier& x) const + { + bool ret_value {false}; + + if (m__d == x.m__d && + selected_member_ == x.selected_member_) + { + switch (selected_member_) + { + case 0x00000001: + ret_value = (m_string_sdefn == x.m_string_sdefn); + break; + + case 0x00000002: + ret_value = (m_string_ldefn == x.m_string_ldefn); + break; + + case 0x00000003: + ret_value = (m_seq_sdefn == x.m_seq_sdefn); + break; + + case 0x00000004: + ret_value = (m_seq_ldefn == x.m_seq_ldefn); + break; + + case 0x00000005: + ret_value = (m_array_sdefn == x.m_array_sdefn); + break; + + case 0x00000006: + ret_value = (m_array_ldefn == x.m_array_ldefn); + break; + + case 0x00000007: + ret_value = (m_map_sdefn == x.m_map_sdefn); + break; + + case 0x00000008: + ret_value = (m_map_ldefn == x.m_map_ldefn); + break; + + case 0x00000009: + ret_value = (m_sc_component_id == x.m_sc_component_id); + break; + + case 0x0000000a: + ret_value = (m_equivalence_hash == x.m_equivalence_hash); + break; + + case 0x0000000b: + ret_value = (m_extended_defn == x.m_extended_defn); + break; + + } + } + + return ret_value; + } + + /*! + * @brief Comparison operator. + * @param x TypeIdentifier object to compare. + */ + eProsima_user_DllExport bool operator !=( + const TypeIdentifier& x) const + { + return !(*this == x); + } + + /*! + * @brief This function sets the discriminator value. + * @param __d New value for the discriminator. + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the new value doesn't correspond to the selected union member. + */ + eProsima_user_DllExport void _d( + uint8_t __d) + { + bool valid_discriminator = false; + + switch (__d) + { + case TI_STRING8_SMALL: + case TI_STRING16_SMALL: + if (0x00000001 == selected_member_) + { + valid_discriminator = true; + } + break; + + case TI_STRING8_LARGE: + case TI_STRING16_LARGE: + if (0x00000002 == selected_member_) + { + valid_discriminator = true; + } + break; + + case TI_PLAIN_SEQUENCE_SMALL: + if (0x00000003 == selected_member_) + { + valid_discriminator = true; + } + break; + + case TI_PLAIN_SEQUENCE_LARGE: + if (0x00000004 == selected_member_) + { + valid_discriminator = true; + } + break; + + case TI_PLAIN_ARRAY_SMALL: + if (0x00000005 == selected_member_) + { + valid_discriminator = true; + } + break; + + case TI_PLAIN_ARRAY_LARGE: + if (0x00000006 == selected_member_) + { + valid_discriminator = true; + } + break; + + case TI_PLAIN_MAP_SMALL: + if (0x00000007 == selected_member_) + { + valid_discriminator = true; + } + break; + + case TI_PLAIN_MAP_LARGE: + if (0x00000008 == selected_member_) + { + valid_discriminator = true; + } + break; + + case TI_STRONGLY_CONNECTED_COMPONENT: + if (0x00000009 == selected_member_) + { + valid_discriminator = true; + } + break; + + case EK_COMPLETE: + case EK_MINIMAL: + if (0x0000000a == selected_member_) + { + valid_discriminator = true; + } + break; + + default: + if (0x0000000b == selected_member_) + { + valid_discriminator = true; + } + break; + + } + + if (!valid_discriminator) + { + throw eprosima::fastcdr::exception::BadParamException("Discriminator doesn't correspond with the selected union member"); + } + + m__d = __d; + } + + /*! + * @brief This function returns the value of the discriminator. + * @return Value of the discriminator + */ + eProsima_user_DllExport uint8_t _d() const + { + return m__d; + } + + /*! + * @brief This function copies the value in member string_sdefn + * @param _string_sdefn New value to be copied in member string_sdefn + */ + eProsima_user_DllExport void string_sdefn( + const StringSTypeDefn& _string_sdefn) + { + string_sdefn_() = _string_sdefn; + m__d = TI_STRING8_SMALL; + } + + /*! + * @brief This function moves the value in member string_sdefn + * @param _string_sdefn New value to be moved in member string_sdefn + */ + eProsima_user_DllExport void string_sdefn( + StringSTypeDefn&& _string_sdefn) + { + string_sdefn_() = _string_sdefn; + m__d = TI_STRING8_SMALL; + } + + /*! + * @brief This function returns a constant reference to member string_sdefn + * @return Constant reference to member string_sdefn + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport const StringSTypeDefn& string_sdefn() const + { + if (0x00000001 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_string_sdefn; + } + + /*! + * @brief This function returns a reference to member string_sdefn + * @return Reference to member string_sdefn + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport StringSTypeDefn& string_sdefn() + { + if (0x00000001 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_string_sdefn; + } + + + /*! + * @brief This function copies the value in member string_ldefn + * @param _string_ldefn New value to be copied in member string_ldefn + */ + eProsima_user_DllExport void string_ldefn( + const StringLTypeDefn& _string_ldefn) + { + string_ldefn_() = _string_ldefn; + m__d = TI_STRING8_LARGE; + } + + /*! + * @brief This function moves the value in member string_ldefn + * @param _string_ldefn New value to be moved in member string_ldefn + */ + eProsima_user_DllExport void string_ldefn( + StringLTypeDefn&& _string_ldefn) + { + string_ldefn_() = _string_ldefn; + m__d = TI_STRING8_LARGE; + } + + /*! + * @brief This function returns a constant reference to member string_ldefn + * @return Constant reference to member string_ldefn + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport const StringLTypeDefn& string_ldefn() const + { + if (0x00000002 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_string_ldefn; + } + + /*! + * @brief This function returns a reference to member string_ldefn + * @return Reference to member string_ldefn + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport StringLTypeDefn& string_ldefn() + { + if (0x00000002 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_string_ldefn; + } + + + /*! + * @brief This function copies the value in member seq_sdefn + * @param _seq_sdefn New value to be copied in member seq_sdefn + */ + eProsima_user_DllExport void seq_sdefn( + const PlainSequenceSElemDefn& _seq_sdefn) + { + seq_sdefn_() = _seq_sdefn; + m__d = TI_PLAIN_SEQUENCE_SMALL; + } + + /*! + * @brief This function moves the value in member seq_sdefn + * @param _seq_sdefn New value to be moved in member seq_sdefn + */ + eProsima_user_DllExport void seq_sdefn( + PlainSequenceSElemDefn&& _seq_sdefn) + { + seq_sdefn_() = _seq_sdefn; + m__d = TI_PLAIN_SEQUENCE_SMALL; + } + + /*! + * @brief This function returns a constant reference to member seq_sdefn + * @return Constant reference to member seq_sdefn + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport const PlainSequenceSElemDefn& seq_sdefn() const + { + if (0x00000003 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_seq_sdefn; + } + + /*! + * @brief This function returns a reference to member seq_sdefn + * @return Reference to member seq_sdefn + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport PlainSequenceSElemDefn& seq_sdefn() + { + if (0x00000003 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_seq_sdefn; + } + + + /*! + * @brief This function copies the value in member seq_ldefn + * @param _seq_ldefn New value to be copied in member seq_ldefn + */ + eProsima_user_DllExport void seq_ldefn( + const PlainSequenceLElemDefn& _seq_ldefn) + { + seq_ldefn_() = _seq_ldefn; + m__d = TI_PLAIN_SEQUENCE_LARGE; + } + + /*! + * @brief This function moves the value in member seq_ldefn + * @param _seq_ldefn New value to be moved in member seq_ldefn + */ + eProsima_user_DllExport void seq_ldefn( + PlainSequenceLElemDefn&& _seq_ldefn) + { + seq_ldefn_() = _seq_ldefn; + m__d = TI_PLAIN_SEQUENCE_LARGE; + } + + /*! + * @brief This function returns a constant reference to member seq_ldefn + * @return Constant reference to member seq_ldefn + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport const PlainSequenceLElemDefn& seq_ldefn() const + { + if (0x00000004 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_seq_ldefn; + } + + /*! + * @brief This function returns a reference to member seq_ldefn + * @return Reference to member seq_ldefn + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport PlainSequenceLElemDefn& seq_ldefn() + { + if (0x00000004 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_seq_ldefn; + } + + + /*! + * @brief This function copies the value in member array_sdefn + * @param _array_sdefn New value to be copied in member array_sdefn + */ + eProsima_user_DllExport void array_sdefn( + const PlainArraySElemDefn& _array_sdefn) + { + array_sdefn_() = _array_sdefn; + m__d = TI_PLAIN_ARRAY_SMALL; + } + + /*! + * @brief This function moves the value in member array_sdefn + * @param _array_sdefn New value to be moved in member array_sdefn + */ + eProsima_user_DllExport void array_sdefn( + PlainArraySElemDefn&& _array_sdefn) + { + array_sdefn_() = _array_sdefn; + m__d = TI_PLAIN_ARRAY_SMALL; + } + + /*! + * @brief This function returns a constant reference to member array_sdefn + * @return Constant reference to member array_sdefn + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport const PlainArraySElemDefn& array_sdefn() const + { + if (0x00000005 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_array_sdefn; + } + + /*! + * @brief This function returns a reference to member array_sdefn + * @return Reference to member array_sdefn + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport PlainArraySElemDefn& array_sdefn() + { + if (0x00000005 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_array_sdefn; + } + + + /*! + * @brief This function copies the value in member array_ldefn + * @param _array_ldefn New value to be copied in member array_ldefn + */ + eProsima_user_DllExport void array_ldefn( + const PlainArrayLElemDefn& _array_ldefn) + { + array_ldefn_() = _array_ldefn; + m__d = TI_PLAIN_ARRAY_LARGE; + } + + /*! + * @brief This function moves the value in member array_ldefn + * @param _array_ldefn New value to be moved in member array_ldefn + */ + eProsima_user_DllExport void array_ldefn( + PlainArrayLElemDefn&& _array_ldefn) + { + array_ldefn_() = _array_ldefn; + m__d = TI_PLAIN_ARRAY_LARGE; + } + + /*! + * @brief This function returns a constant reference to member array_ldefn + * @return Constant reference to member array_ldefn + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport const PlainArrayLElemDefn& array_ldefn() const + { + if (0x00000006 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_array_ldefn; + } + + /*! + * @brief This function returns a reference to member array_ldefn + * @return Reference to member array_ldefn + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport PlainArrayLElemDefn& array_ldefn() + { + if (0x00000006 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_array_ldefn; + } + + + /*! + * @brief This function copies the value in member map_sdefn + * @param _map_sdefn New value to be copied in member map_sdefn + */ + eProsima_user_DllExport void map_sdefn( + const PlainMapSTypeDefn& _map_sdefn) + { + map_sdefn_() = _map_sdefn; + m__d = TI_PLAIN_MAP_SMALL; + } + + /*! + * @brief This function moves the value in member map_sdefn + * @param _map_sdefn New value to be moved in member map_sdefn + */ + eProsima_user_DllExport void map_sdefn( + PlainMapSTypeDefn&& _map_sdefn) + { + map_sdefn_() = _map_sdefn; + m__d = TI_PLAIN_MAP_SMALL; + } + + /*! + * @brief This function returns a constant reference to member map_sdefn + * @return Constant reference to member map_sdefn + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport const PlainMapSTypeDefn& map_sdefn() const + { + if (0x00000007 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_map_sdefn; + } + + /*! + * @brief This function returns a reference to member map_sdefn + * @return Reference to member map_sdefn + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport PlainMapSTypeDefn& map_sdefn() + { + if (0x00000007 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_map_sdefn; + } + + + /*! + * @brief This function copies the value in member map_ldefn + * @param _map_ldefn New value to be copied in member map_ldefn + */ + eProsima_user_DllExport void map_ldefn( + const PlainMapLTypeDefn& _map_ldefn) + { + map_ldefn_() = _map_ldefn; + m__d = TI_PLAIN_MAP_LARGE; + } + + /*! + * @brief This function moves the value in member map_ldefn + * @param _map_ldefn New value to be moved in member map_ldefn + */ + eProsima_user_DllExport void map_ldefn( + PlainMapLTypeDefn&& _map_ldefn) + { + map_ldefn_() = _map_ldefn; + m__d = TI_PLAIN_MAP_LARGE; + } + + /*! + * @brief This function returns a constant reference to member map_ldefn + * @return Constant reference to member map_ldefn + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport const PlainMapLTypeDefn& map_ldefn() const + { + if (0x00000008 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_map_ldefn; + } + + /*! + * @brief This function returns a reference to member map_ldefn + * @return Reference to member map_ldefn + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport PlainMapLTypeDefn& map_ldefn() + { + if (0x00000008 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_map_ldefn; + } + + + /*! + * @brief This function copies the value in member sc_component_id + * @param _sc_component_id New value to be copied in member sc_component_id + */ + eProsima_user_DllExport void sc_component_id( + const StronglyConnectedComponentId& _sc_component_id) + { + sc_component_id_() = _sc_component_id; + m__d = TI_STRONGLY_CONNECTED_COMPONENT; + } + + /*! + * @brief This function moves the value in member sc_component_id + * @param _sc_component_id New value to be moved in member sc_component_id + */ + eProsima_user_DllExport void sc_component_id( + StronglyConnectedComponentId&& _sc_component_id) + { + sc_component_id_() = _sc_component_id; + m__d = TI_STRONGLY_CONNECTED_COMPONENT; + } + + /*! + * @brief This function returns a constant reference to member sc_component_id + * @return Constant reference to member sc_component_id + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport const StronglyConnectedComponentId& sc_component_id() const + { + if (0x00000009 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_sc_component_id; + } + + /*! + * @brief This function returns a reference to member sc_component_id + * @return Reference to member sc_component_id + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport StronglyConnectedComponentId& sc_component_id() + { + if (0x00000009 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_sc_component_id; + } + + + /*! + * @brief This function copies the value in member equivalence_hash + * @param _equivalence_hash New value to be copied in member equivalence_hash + */ + eProsima_user_DllExport void equivalence_hash( + const EquivalenceHash& _equivalence_hash) + { + equivalence_hash_() = _equivalence_hash; + m__d = EK_COMPLETE; + } + + /*! + * @brief This function moves the value in member equivalence_hash + * @param _equivalence_hash New value to be moved in member equivalence_hash + */ + eProsima_user_DllExport void equivalence_hash( + EquivalenceHash&& _equivalence_hash) + { + equivalence_hash_() = _equivalence_hash; + m__d = EK_COMPLETE; + } + + /*! + * @brief This function returns a constant reference to member equivalence_hash + * @return Constant reference to member equivalence_hash + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport const EquivalenceHash& equivalence_hash() const + { + if (0x0000000a != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_equivalence_hash; + } + + /*! + * @brief This function returns a reference to member equivalence_hash + * @return Reference to member equivalence_hash + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport EquivalenceHash& equivalence_hash() + { + if (0x0000000a != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_equivalence_hash; + } + + + /*! + * @brief This function copies the value in member extended_defn + * @param _extended_defn New value to be copied in member extended_defn + */ + eProsima_user_DllExport void extended_defn( + const ExtendedTypeDefn& _extended_defn) + { + extended_defn_() = _extended_defn; + m__d = 0; + } + + /*! + * @brief This function moves the value in member extended_defn + * @param _extended_defn New value to be moved in member extended_defn + */ + eProsima_user_DllExport void extended_defn( + ExtendedTypeDefn&& _extended_defn) + { + extended_defn_() = _extended_defn; + m__d = 0; + } + + /*! + * @brief This function returns a constant reference to member extended_defn + * @return Constant reference to member extended_defn + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport const ExtendedTypeDefn& extended_defn() const + { + if (0x0000000b != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_extended_defn; + } + + /*! + * @brief This function returns a reference to member extended_defn + * @return Reference to member extended_defn + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport ExtendedTypeDefn& extended_defn() + { + if (0x0000000b != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_extended_defn; + } + + + +private: + + StringSTypeDefn& string_sdefn_() + { + if (0x00000001 != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x00000001; + member_destructor_ = [&]() {m_string_sdefn.~StringSTypeDefn();}; + new(&m_string_sdefn) StringSTypeDefn(); + ; + } + + return m_string_sdefn; + } + + StringLTypeDefn& string_ldefn_() + { + if (0x00000002 != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x00000002; + member_destructor_ = [&]() {m_string_ldefn.~StringLTypeDefn();}; + new(&m_string_ldefn) StringLTypeDefn(); + ; + } + + return m_string_ldefn; + } + + PlainSequenceSElemDefn& seq_sdefn_() + { + if (0x00000003 != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x00000003; + member_destructor_ = [&]() {m_seq_sdefn.~PlainSequenceSElemDefn();}; + new(&m_seq_sdefn) PlainSequenceSElemDefn(); + ; + } + + return m_seq_sdefn; + } + + PlainSequenceLElemDefn& seq_ldefn_() + { + if (0x00000004 != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x00000004; + member_destructor_ = [&]() {m_seq_ldefn.~PlainSequenceLElemDefn();}; + new(&m_seq_ldefn) PlainSequenceLElemDefn(); + ; + } + + return m_seq_ldefn; + } + + PlainArraySElemDefn& array_sdefn_() + { + if (0x00000005 != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x00000005; + member_destructor_ = [&]() {m_array_sdefn.~PlainArraySElemDefn();}; + new(&m_array_sdefn) PlainArraySElemDefn(); + ; + } + + return m_array_sdefn; + } + + PlainArrayLElemDefn& array_ldefn_() + { + if (0x00000006 != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x00000006; + member_destructor_ = [&]() {m_array_ldefn.~PlainArrayLElemDefn();}; + new(&m_array_ldefn) PlainArrayLElemDefn(); + ; + } + + return m_array_ldefn; + } + + PlainMapSTypeDefn& map_sdefn_() + { + if (0x00000007 != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x00000007; + member_destructor_ = [&]() {m_map_sdefn.~PlainMapSTypeDefn();}; + new(&m_map_sdefn) PlainMapSTypeDefn(); + ; + } + + return m_map_sdefn; + } + + PlainMapLTypeDefn& map_ldefn_() + { + if (0x00000008 != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x00000008; + member_destructor_ = [&]() {m_map_ldefn.~PlainMapLTypeDefn();}; + new(&m_map_ldefn) PlainMapLTypeDefn(); + ; + } + + return m_map_ldefn; + } + + StronglyConnectedComponentId& sc_component_id_() + { + if (0x00000009 != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x00000009; + member_destructor_ = [&]() {m_sc_component_id.~StronglyConnectedComponentId();}; + new(&m_sc_component_id) StronglyConnectedComponentId(); + ; + } + + return m_sc_component_id; + } + + EquivalenceHash& equivalence_hash_() + { + if (0x0000000a != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x0000000a; + member_destructor_ = [&]() {m_equivalence_hash.~EquivalenceHash();}; + new(&m_equivalence_hash) EquivalenceHash(); + ; + } + + return m_equivalence_hash; + } + + ExtendedTypeDefn& extended_defn_() + { + if (0x0000000b != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x0000000b; + member_destructor_ = [&]() {m_extended_defn.~ExtendedTypeDefn();}; + new(&m_extended_defn) ExtendedTypeDefn(); + ; + } + + return m_extended_defn; + } + + + uint8_t m__d {0}; + + union + { + StringSTypeDefn m_string_sdefn; + StringLTypeDefn m_string_ldefn; + PlainSequenceSElemDefn m_seq_sdefn; + PlainSequenceLElemDefn m_seq_ldefn; + PlainArraySElemDefn m_array_sdefn; + PlainArrayLElemDefn m_array_ldefn; + PlainMapSTypeDefn m_map_sdefn; + PlainMapLTypeDefn m_map_ldefn; + StronglyConnectedComponentId m_sc_component_id; + EquivalenceHash m_equivalence_hash; + ExtendedTypeDefn m_extended_defn; + }; + + uint32_t selected_member_ {0x0FFFFFFFu}; + + std::function member_destructor_; +}; +typedef std::vector TypeIdentifierSeq; + +typedef uint32_t MemberId; + +const uint32_t ANNOTATION_STR_VALUE_MAX_LEN = 128; +const uint32_t ANNOTATION_OCTETSEC_VALUE_MAX_LEN = 128; +/*! + * @brief This class represents the structure ExtendedAnnotationParameterValue defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class ExtendedAnnotationParameterValue +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport ExtendedAnnotationParameterValue() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~ExtendedAnnotationParameterValue() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object ExtendedAnnotationParameterValue that will be copied. + */ + eProsima_user_DllExport ExtendedAnnotationParameterValue( + const ExtendedAnnotationParameterValue& x) + { + static_cast(x); + } + + /*! + * @brief Move constructor. + * @param x Reference to the object ExtendedAnnotationParameterValue that will be copied. + */ + eProsima_user_DllExport ExtendedAnnotationParameterValue( + ExtendedAnnotationParameterValue&& x) noexcept + { + static_cast(x); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object ExtendedAnnotationParameterValue that will be copied. + */ + eProsima_user_DllExport ExtendedAnnotationParameterValue& operator =( + const ExtendedAnnotationParameterValue& x) + { + + static_cast(x); + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object ExtendedAnnotationParameterValue that will be copied. + */ + eProsima_user_DllExport ExtendedAnnotationParameterValue& operator =( + ExtendedAnnotationParameterValue&& x) noexcept + { + + static_cast(x); + + return *this; + } + + /*! + * @brief Comparison operator. + * @param x ExtendedAnnotationParameterValue object to compare. + */ + eProsima_user_DllExport bool operator ==( + const ExtendedAnnotationParameterValue& x) const + { + static_cast(x); + return true; + } + + /*! + * @brief Comparison operator. + * @param x ExtendedAnnotationParameterValue object to compare. + */ + eProsima_user_DllExport bool operator !=( + const ExtendedAnnotationParameterValue& x) const + { + return !(*this == x); + } + + + +private: + + +}; +/*! + * @brief This class represents the union AnnotationParameterValue defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class AnnotationParameterValue +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport AnnotationParameterValue() + { + extended_value_(); + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~AnnotationParameterValue() + { + if (member_destructor_) + { + member_destructor_(); + } + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object AnnotationParameterValue that will be copied. + */ + eProsima_user_DllExport AnnotationParameterValue( + const AnnotationParameterValue& x) + { + m__d = x.m__d; + + switch (x.selected_member_) + { + case 0x00000001: + boolean_value_() = x.m_boolean_value; + break; + + case 0x00000002: + byte_value_() = x.m_byte_value; + break; + + case 0x00000003: + int8_value_() = x.m_int8_value; + break; + + case 0x00000004: + uint8_value_() = x.m_uint8_value; + break; + + case 0x00000005: + int16_value_() = x.m_int16_value; + break; + + case 0x00000006: + uint_16_value_() = x.m_uint_16_value; + break; + + case 0x00000007: + int32_value_() = x.m_int32_value; + break; + + case 0x00000008: + uint32_value_() = x.m_uint32_value; + break; + + case 0x00000009: + int64_value_() = x.m_int64_value; + break; + + case 0x0000000a: + uint64_value_() = x.m_uint64_value; + break; + + case 0x0000000b: + float32_value_() = x.m_float32_value; + break; + + case 0x0000000c: + float64_value_() = x.m_float64_value; + break; + + case 0x0000000d: + float128_value_() = x.m_float128_value; + break; + + case 0x0000000e: + char_value_() = x.m_char_value; + break; + + case 0x0000000f: + wchar_value_() = x.m_wchar_value; + break; + + case 0x00000010: + enumerated_value_() = x.m_enumerated_value; + break; + + case 0x00000011: + string8_value_() = x.m_string8_value; + break; + + case 0x00000012: + string16_value_() = x.m_string16_value; + break; + + case 0x00000013: + extended_value_() = x.m_extended_value; + break; + + } + } + + /*! + * @brief Move constructor. + * @param x Reference to the object AnnotationParameterValue that will be copied. + */ + eProsima_user_DllExport AnnotationParameterValue( + AnnotationParameterValue&& x) noexcept + { + m__d = x.m__d; + + switch (x.selected_member_) + { + case 0x00000001: + boolean_value_() = std::move(x.m_boolean_value); + break; + + case 0x00000002: + byte_value_() = std::move(x.m_byte_value); + break; + + case 0x00000003: + int8_value_() = std::move(x.m_int8_value); + break; + + case 0x00000004: + uint8_value_() = std::move(x.m_uint8_value); + break; + + case 0x00000005: + int16_value_() = std::move(x.m_int16_value); + break; + + case 0x00000006: + uint_16_value_() = std::move(x.m_uint_16_value); + break; + + case 0x00000007: + int32_value_() = std::move(x.m_int32_value); + break; + + case 0x00000008: + uint32_value_() = std::move(x.m_uint32_value); + break; + + case 0x00000009: + int64_value_() = std::move(x.m_int64_value); + break; + + case 0x0000000a: + uint64_value_() = std::move(x.m_uint64_value); + break; + + case 0x0000000b: + float32_value_() = std::move(x.m_float32_value); + break; + + case 0x0000000c: + float64_value_() = std::move(x.m_float64_value); + break; + + case 0x0000000d: + float128_value_() = std::move(x.m_float128_value); + break; + + case 0x0000000e: + char_value_() = std::move(x.m_char_value); + break; + + case 0x0000000f: + wchar_value_() = std::move(x.m_wchar_value); + break; + + case 0x00000010: + enumerated_value_() = std::move(x.m_enumerated_value); + break; + + case 0x00000011: + string8_value_() = std::move(x.m_string8_value); + break; + + case 0x00000012: + string16_value_() = std::move(x.m_string16_value); + break; + + case 0x00000013: + extended_value_() = std::move(x.m_extended_value); + break; + + } + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object AnnotationParameterValue that will be copied. + */ + eProsima_user_DllExport AnnotationParameterValue& operator =( + const AnnotationParameterValue& x) + { + m__d = x.m__d; + + switch (x.selected_member_) + { + case 0x00000001: + boolean_value_() = x.m_boolean_value; + break; + + case 0x00000002: + byte_value_() = x.m_byte_value; + break; + + case 0x00000003: + int8_value_() = x.m_int8_value; + break; + + case 0x00000004: + uint8_value_() = x.m_uint8_value; + break; + + case 0x00000005: + int16_value_() = x.m_int16_value; + break; + + case 0x00000006: + uint_16_value_() = x.m_uint_16_value; + break; + + case 0x00000007: + int32_value_() = x.m_int32_value; + break; + + case 0x00000008: + uint32_value_() = x.m_uint32_value; + break; + + case 0x00000009: + int64_value_() = x.m_int64_value; + break; + + case 0x0000000a: + uint64_value_() = x.m_uint64_value; + break; + + case 0x0000000b: + float32_value_() = x.m_float32_value; + break; + + case 0x0000000c: + float64_value_() = x.m_float64_value; + break; + + case 0x0000000d: + float128_value_() = x.m_float128_value; + break; + + case 0x0000000e: + char_value_() = x.m_char_value; + break; + + case 0x0000000f: + wchar_value_() = x.m_wchar_value; + break; + + case 0x00000010: + enumerated_value_() = x.m_enumerated_value; + break; + + case 0x00000011: + string8_value_() = x.m_string8_value; + break; + + case 0x00000012: + string16_value_() = x.m_string16_value; + break; + + case 0x00000013: + extended_value_() = x.m_extended_value; + break; + + } + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object AnnotationParameterValue that will be copied. + */ + eProsima_user_DllExport AnnotationParameterValue& operator =( + AnnotationParameterValue&& x) noexcept + { + m__d = x.m__d; + + switch (x.selected_member_) + { + case 0x00000001: + boolean_value_() = std::move(x.m_boolean_value); + break; + + case 0x00000002: + byte_value_() = std::move(x.m_byte_value); + break; + + case 0x00000003: + int8_value_() = std::move(x.m_int8_value); + break; + + case 0x00000004: + uint8_value_() = std::move(x.m_uint8_value); + break; + + case 0x00000005: + int16_value_() = std::move(x.m_int16_value); + break; + + case 0x00000006: + uint_16_value_() = std::move(x.m_uint_16_value); + break; + + case 0x00000007: + int32_value_() = std::move(x.m_int32_value); + break; + + case 0x00000008: + uint32_value_() = std::move(x.m_uint32_value); + break; + + case 0x00000009: + int64_value_() = std::move(x.m_int64_value); + break; + + case 0x0000000a: + uint64_value_() = std::move(x.m_uint64_value); + break; + + case 0x0000000b: + float32_value_() = std::move(x.m_float32_value); + break; + + case 0x0000000c: + float64_value_() = std::move(x.m_float64_value); + break; + + case 0x0000000d: + float128_value_() = std::move(x.m_float128_value); + break; + + case 0x0000000e: + char_value_() = std::move(x.m_char_value); + break; + + case 0x0000000f: + wchar_value_() = std::move(x.m_wchar_value); + break; + + case 0x00000010: + enumerated_value_() = std::move(x.m_enumerated_value); + break; + + case 0x00000011: + string8_value_() = std::move(x.m_string8_value); + break; + + case 0x00000012: + string16_value_() = std::move(x.m_string16_value); + break; + + case 0x00000013: + extended_value_() = std::move(x.m_extended_value); + break; + + } + + return *this; + } + + /*! + * @brief Comparison operator. + * @param x AnnotationParameterValue object to compare. + */ + eProsima_user_DllExport bool operator ==( + const AnnotationParameterValue& x) const + { + bool ret_value {false}; + + if (m__d == x.m__d && + selected_member_ == x.selected_member_) + { + switch (selected_member_) + { + case 0x00000001: + ret_value = (m_boolean_value == x.m_boolean_value); + break; + + case 0x00000002: + ret_value = (m_byte_value == x.m_byte_value); + break; + + case 0x00000003: + ret_value = (m_int8_value == x.m_int8_value); + break; + + case 0x00000004: + ret_value = (m_uint8_value == x.m_uint8_value); + break; + + case 0x00000005: + ret_value = (m_int16_value == x.m_int16_value); + break; + + case 0x00000006: + ret_value = (m_uint_16_value == x.m_uint_16_value); + break; + + case 0x00000007: + ret_value = (m_int32_value == x.m_int32_value); + break; + + case 0x00000008: + ret_value = (m_uint32_value == x.m_uint32_value); + break; + + case 0x00000009: + ret_value = (m_int64_value == x.m_int64_value); + break; + + case 0x0000000a: + ret_value = (m_uint64_value == x.m_uint64_value); + break; + + case 0x0000000b: + ret_value = (m_float32_value == x.m_float32_value); + break; + + case 0x0000000c: + ret_value = (m_float64_value == x.m_float64_value); + break; + + case 0x0000000d: + ret_value = (m_float128_value == x.m_float128_value); + break; + + case 0x0000000e: + ret_value = (m_char_value == x.m_char_value); + break; + + case 0x0000000f: + ret_value = (m_wchar_value == x.m_wchar_value); + break; + + case 0x00000010: + ret_value = (m_enumerated_value == x.m_enumerated_value); + break; + + case 0x00000011: + ret_value = (m_string8_value == x.m_string8_value); + break; + + case 0x00000012: + ret_value = (m_string16_value == x.m_string16_value); + break; + + case 0x00000013: + ret_value = (m_extended_value == x.m_extended_value); + break; + + } + } + + return ret_value; + } + + /*! + * @brief Comparison operator. + * @param x AnnotationParameterValue object to compare. + */ + eProsima_user_DllExport bool operator !=( + const AnnotationParameterValue& x) const + { + return !(*this == x); + } + + /*! + * @brief This function sets the discriminator value. + * @param __d New value for the discriminator. + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the new value doesn't correspond to the selected union member. + */ + eProsima_user_DllExport void _d( + uint8_t __d) + { + bool valid_discriminator = false; + + switch (__d) + { + case TK_BOOLEAN: + if (0x00000001 == selected_member_) + { + valid_discriminator = true; + } + break; + + case TK_BYTE: + if (0x00000002 == selected_member_) + { + valid_discriminator = true; + } + break; + + case TK_INT8: + if (0x00000003 == selected_member_) + { + valid_discriminator = true; + } + break; + + case TK_UINT8: + if (0x00000004 == selected_member_) + { + valid_discriminator = true; + } + break; + + case TK_INT16: + if (0x00000005 == selected_member_) + { + valid_discriminator = true; + } + break; + + case TK_UINT16: + if (0x00000006 == selected_member_) + { + valid_discriminator = true; + } + break; + + case TK_INT32: + if (0x00000007 == selected_member_) + { + valid_discriminator = true; + } + break; + + case TK_UINT32: + if (0x00000008 == selected_member_) + { + valid_discriminator = true; + } + break; + + case TK_INT64: + if (0x00000009 == selected_member_) + { + valid_discriminator = true; + } + break; + + case TK_UINT64: + if (0x0000000a == selected_member_) + { + valid_discriminator = true; + } + break; + + case TK_FLOAT32: + if (0x0000000b == selected_member_) + { + valid_discriminator = true; + } + break; + + case TK_FLOAT64: + if (0x0000000c == selected_member_) + { + valid_discriminator = true; + } + break; + + case TK_FLOAT128: + if (0x0000000d == selected_member_) + { + valid_discriminator = true; + } + break; + + case TK_CHAR8: + if (0x0000000e == selected_member_) + { + valid_discriminator = true; + } + break; + + case TK_CHAR16: + if (0x0000000f == selected_member_) + { + valid_discriminator = true; + } + break; + + case TK_ENUM: + if (0x00000010 == selected_member_) + { + valid_discriminator = true; + } + break; + + case TK_STRING8: + if (0x00000011 == selected_member_) + { + valid_discriminator = true; + } + break; + + case TK_STRING16: + if (0x00000012 == selected_member_) + { + valid_discriminator = true; + } + break; + + default: + if (0x00000013 == selected_member_) + { + valid_discriminator = true; + } + break; + + } + + if (!valid_discriminator) + { + throw eprosima::fastcdr::exception::BadParamException("Discriminator doesn't correspond with the selected union member"); + } + + m__d = __d; + } + + /*! + * @brief This function returns the value of the discriminator. + * @return Value of the discriminator + */ + eProsima_user_DllExport uint8_t _d() const + { + return m__d; + } + + /*! + * @brief This function sets a value in member boolean_value + * @param _boolean_value New value for member boolean_value + */ + eProsima_user_DllExport void boolean_value( + bool _boolean_value) + { + boolean_value_() = _boolean_value; + m__d = TK_BOOLEAN; + } + + /*! + * @brief This function returns the value of member boolean_value + * @return Value of member boolean_value + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport bool boolean_value() const + { + if (0x00000001 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_boolean_value; + } + + /*! + * @brief This function returns a reference to member boolean_value + * @return Reference to member boolean_value + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport bool& boolean_value() + { + if (0x00000001 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_boolean_value; + } + + + /*! + * @brief This function sets a value in member byte_value + * @param _byte_value New value for member byte_value + */ + eProsima_user_DllExport void byte_value( + uint8_t _byte_value) + { + byte_value_() = _byte_value; + m__d = TK_BYTE; + } + + /*! + * @brief This function returns the value of member byte_value + * @return Value of member byte_value + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport uint8_t byte_value() const + { + if (0x00000002 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_byte_value; + } + + /*! + * @brief This function returns a reference to member byte_value + * @return Reference to member byte_value + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport uint8_t& byte_value() + { + if (0x00000002 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_byte_value; + } + + + /*! + * @brief This function sets a value in member int8_value + * @param _int8_value New value for member int8_value + */ + eProsima_user_DllExport void int8_value( + int8_t _int8_value) + { + int8_value_() = _int8_value; + m__d = TK_INT8; + } + + /*! + * @brief This function returns the value of member int8_value + * @return Value of member int8_value + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport int8_t int8_value() const + { + if (0x00000003 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_int8_value; + } + + /*! + * @brief This function returns a reference to member int8_value + * @return Reference to member int8_value + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport int8_t& int8_value() + { + if (0x00000003 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_int8_value; + } + + + /*! + * @brief This function sets a value in member uint8_value + * @param _uint8_value New value for member uint8_value + */ + eProsima_user_DllExport void uint8_value( + uint8_t _uint8_value) + { + uint8_value_() = _uint8_value; + m__d = TK_UINT8; + } + + /*! + * @brief This function returns the value of member uint8_value + * @return Value of member uint8_value + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport uint8_t uint8_value() const + { + if (0x00000004 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_uint8_value; + } + + /*! + * @brief This function returns a reference to member uint8_value + * @return Reference to member uint8_value + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport uint8_t& uint8_value() + { + if (0x00000004 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_uint8_value; + } + + + /*! + * @brief This function sets a value in member int16_value + * @param _int16_value New value for member int16_value + */ + eProsima_user_DllExport void int16_value( + int16_t _int16_value) + { + int16_value_() = _int16_value; + m__d = TK_INT16; + } + + /*! + * @brief This function returns the value of member int16_value + * @return Value of member int16_value + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport int16_t int16_value() const + { + if (0x00000005 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_int16_value; + } + + /*! + * @brief This function returns a reference to member int16_value + * @return Reference to member int16_value + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport int16_t& int16_value() + { + if (0x00000005 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_int16_value; + } + + + /*! + * @brief This function sets a value in member uint_16_value + * @param _uint_16_value New value for member uint_16_value + */ + eProsima_user_DllExport void uint_16_value( + uint16_t _uint_16_value) + { + uint_16_value_() = _uint_16_value; + m__d = TK_UINT16; + } + + /*! + * @brief This function returns the value of member uint_16_value + * @return Value of member uint_16_value + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport uint16_t uint_16_value() const + { + if (0x00000006 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_uint_16_value; + } + + /*! + * @brief This function returns a reference to member uint_16_value + * @return Reference to member uint_16_value + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport uint16_t& uint_16_value() + { + if (0x00000006 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_uint_16_value; + } + + + /*! + * @brief This function sets a value in member int32_value + * @param _int32_value New value for member int32_value + */ + eProsima_user_DllExport void int32_value( + int32_t _int32_value) + { + int32_value_() = _int32_value; + m__d = TK_INT32; + } + + /*! + * @brief This function returns the value of member int32_value + * @return Value of member int32_value + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport int32_t int32_value() const + { + if (0x00000007 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_int32_value; + } + + /*! + * @brief This function returns a reference to member int32_value + * @return Reference to member int32_value + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport int32_t& int32_value() + { + if (0x00000007 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_int32_value; + } + + + /*! + * @brief This function sets a value in member uint32_value + * @param _uint32_value New value for member uint32_value + */ + eProsima_user_DllExport void uint32_value( + uint32_t _uint32_value) + { + uint32_value_() = _uint32_value; + m__d = TK_UINT32; + } + + /*! + * @brief This function returns the value of member uint32_value + * @return Value of member uint32_value + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport uint32_t uint32_value() const + { + if (0x00000008 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_uint32_value; + } + + /*! + * @brief This function returns a reference to member uint32_value + * @return Reference to member uint32_value + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport uint32_t& uint32_value() + { + if (0x00000008 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_uint32_value; + } + + + /*! + * @brief This function sets a value in member int64_value + * @param _int64_value New value for member int64_value + */ + eProsima_user_DllExport void int64_value( + int64_t _int64_value) + { + int64_value_() = _int64_value; + m__d = TK_INT64; + } + + /*! + * @brief This function returns the value of member int64_value + * @return Value of member int64_value + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport int64_t int64_value() const + { + if (0x00000009 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_int64_value; + } + + /*! + * @brief This function returns a reference to member int64_value + * @return Reference to member int64_value + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport int64_t& int64_value() + { + if (0x00000009 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_int64_value; + } + + + /*! + * @brief This function sets a value in member uint64_value + * @param _uint64_value New value for member uint64_value + */ + eProsima_user_DllExport void uint64_value( + uint64_t _uint64_value) + { + uint64_value_() = _uint64_value; + m__d = TK_UINT64; + } + + /*! + * @brief This function returns the value of member uint64_value + * @return Value of member uint64_value + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport uint64_t uint64_value() const + { + if (0x0000000a != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_uint64_value; + } + + /*! + * @brief This function returns a reference to member uint64_value + * @return Reference to member uint64_value + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport uint64_t& uint64_value() + { + if (0x0000000a != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_uint64_value; + } + + + /*! + * @brief This function sets a value in member float32_value + * @param _float32_value New value for member float32_value + */ + eProsima_user_DllExport void float32_value( + float _float32_value) + { + float32_value_() = _float32_value; + m__d = TK_FLOAT32; + } + + /*! + * @brief This function returns the value of member float32_value + * @return Value of member float32_value + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport float float32_value() const + { + if (0x0000000b != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_float32_value; + } + + /*! + * @brief This function returns a reference to member float32_value + * @return Reference to member float32_value + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport float& float32_value() + { + if (0x0000000b != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_float32_value; + } + + + /*! + * @brief This function sets a value in member float64_value + * @param _float64_value New value for member float64_value + */ + eProsima_user_DllExport void float64_value( + double _float64_value) + { + float64_value_() = _float64_value; + m__d = TK_FLOAT64; + } + + /*! + * @brief This function returns the value of member float64_value + * @return Value of member float64_value + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport double float64_value() const + { + if (0x0000000c != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_float64_value; + } + + /*! + * @brief This function returns a reference to member float64_value + * @return Reference to member float64_value + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport double& float64_value() + { + if (0x0000000c != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_float64_value; + } + + + /*! + * @brief This function sets a value in member float128_value + * @param _float128_value New value for member float128_value + */ + eProsima_user_DllExport void float128_value( + long double _float128_value) + { + float128_value_() = _float128_value; + m__d = TK_FLOAT128; + } + + /*! + * @brief This function returns the value of member float128_value + * @return Value of member float128_value + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport long double float128_value() const + { + if (0x0000000d != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_float128_value; + } + + /*! + * @brief This function returns a reference to member float128_value + * @return Reference to member float128_value + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport long double& float128_value() + { + if (0x0000000d != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_float128_value; + } + + + /*! + * @brief This function sets a value in member char_value + * @param _char_value New value for member char_value + */ + eProsima_user_DllExport void char_value( + char _char_value) + { + char_value_() = _char_value; + m__d = TK_CHAR8; + } + + /*! + * @brief This function returns the value of member char_value + * @return Value of member char_value + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport char char_value() const + { + if (0x0000000e != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_char_value; + } + + /*! + * @brief This function returns a reference to member char_value + * @return Reference to member char_value + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport char& char_value() + { + if (0x0000000e != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_char_value; + } + + + /*! + * @brief This function sets a value in member wchar_value + * @param _wchar_value New value for member wchar_value + */ + eProsima_user_DllExport void wchar_value( + wchar_t _wchar_value) + { + wchar_value_() = _wchar_value; + m__d = TK_CHAR16; + } + + /*! + * @brief This function returns the value of member wchar_value + * @return Value of member wchar_value + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport wchar_t wchar_value() const + { + if (0x0000000f != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_wchar_value; + } + + /*! + * @brief This function returns a reference to member wchar_value + * @return Reference to member wchar_value + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport wchar_t& wchar_value() + { + if (0x0000000f != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_wchar_value; + } + + + /*! + * @brief This function sets a value in member enumerated_value + * @param _enumerated_value New value for member enumerated_value + */ + eProsima_user_DllExport void enumerated_value( + int32_t _enumerated_value) + { + enumerated_value_() = _enumerated_value; + m__d = TK_ENUM; + } + + /*! + * @brief This function returns the value of member enumerated_value + * @return Value of member enumerated_value + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport int32_t enumerated_value() const + { + if (0x00000010 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_enumerated_value; + } + + /*! + * @brief This function returns a reference to member enumerated_value + * @return Reference to member enumerated_value + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport int32_t& enumerated_value() + { + if (0x00000010 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_enumerated_value; + } + + + /*! + * @brief This function copies the value in member string8_value + * @param _string8_value New value to be copied in member string8_value + */ + eProsima_user_DllExport void string8_value( + const eprosima::fastcdr::fixed_string& _string8_value) + { + string8_value_() = _string8_value; + m__d = TK_STRING8; + } + + /*! + * @brief This function moves the value in member string8_value + * @param _string8_value New value to be moved in member string8_value + */ + eProsima_user_DllExport void string8_value( + eprosima::fastcdr::fixed_string&& _string8_value) + { + string8_value_() = _string8_value; + m__d = TK_STRING8; + } + + /*! + * @brief This function returns a constant reference to member string8_value + * @return Constant reference to member string8_value + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport const eprosima::fastcdr::fixed_string& string8_value() const + { + if (0x00000011 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_string8_value; + } + + /*! + * @brief This function returns a reference to member string8_value + * @return Reference to member string8_value + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport eprosima::fastcdr::fixed_string& string8_value() + { + if (0x00000011 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_string8_value; + } + + + /*! + * @brief This function copies the value in member string16_value + * @param _string16_value New value to be copied in member string16_value + */ + eProsima_user_DllExport void string16_value( + const std::wstring& _string16_value) + { + string16_value_() = _string16_value; + m__d = TK_STRING16; + } + + /*! + * @brief This function moves the value in member string16_value + * @param _string16_value New value to be moved in member string16_value + */ + eProsima_user_DllExport void string16_value( + std::wstring&& _string16_value) + { + string16_value_() = _string16_value; + m__d = TK_STRING16; + } + + /*! + * @brief This function returns a constant reference to member string16_value + * @return Constant reference to member string16_value + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport const std::wstring& string16_value() const + { + if (0x00000012 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_string16_value; + } + + /*! + * @brief This function returns a reference to member string16_value + * @return Reference to member string16_value + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport std::wstring& string16_value() + { + if (0x00000012 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_string16_value; + } + + + /*! + * @brief This function copies the value in member extended_value + * @param _extended_value New value to be copied in member extended_value + */ + eProsima_user_DllExport void extended_value( + const ExtendedAnnotationParameterValue& _extended_value) + { + extended_value_() = _extended_value; + m__d = 0; + } + + /*! + * @brief This function moves the value in member extended_value + * @param _extended_value New value to be moved in member extended_value + */ + eProsima_user_DllExport void extended_value( + ExtendedAnnotationParameterValue&& _extended_value) + { + extended_value_() = _extended_value; + m__d = 0; + } + + /*! + * @brief This function returns a constant reference to member extended_value + * @return Constant reference to member extended_value + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport const ExtendedAnnotationParameterValue& extended_value() const + { + if (0x00000013 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_extended_value; + } + + /*! + * @brief This function returns a reference to member extended_value + * @return Reference to member extended_value + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport ExtendedAnnotationParameterValue& extended_value() + { + if (0x00000013 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_extended_value; + } + + + +private: + + bool& boolean_value_() + { + if (0x00000001 != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x00000001; + member_destructor_ = nullptr; + m_boolean_value = {false}; + ; + } + + return m_boolean_value; + } + + uint8_t& byte_value_() + { + if (0x00000002 != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x00000002; + member_destructor_ = nullptr; + m_byte_value = {0}; + ; + } + + return m_byte_value; + } + + int8_t& int8_value_() + { + if (0x00000003 != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x00000003; + member_destructor_ = nullptr; + m_int8_value = {0}; + ; + } + + return m_int8_value; + } + + uint8_t& uint8_value_() + { + if (0x00000004 != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x00000004; + member_destructor_ = nullptr; + m_uint8_value = {0}; + ; + } + + return m_uint8_value; + } + + int16_t& int16_value_() + { + if (0x00000005 != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x00000005; + member_destructor_ = nullptr; + m_int16_value = {0}; + ; + } + + return m_int16_value; + } + + uint16_t& uint_16_value_() + { + if (0x00000006 != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x00000006; + member_destructor_ = nullptr; + m_uint_16_value = {0}; + ; + } + + return m_uint_16_value; + } + + int32_t& int32_value_() + { + if (0x00000007 != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x00000007; + member_destructor_ = nullptr; + m_int32_value = {0}; + ; + } + + return m_int32_value; + } + + uint32_t& uint32_value_() + { + if (0x00000008 != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x00000008; + member_destructor_ = nullptr; + m_uint32_value = {0}; + ; + } + + return m_uint32_value; + } + + int64_t& int64_value_() + { + if (0x00000009 != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x00000009; + member_destructor_ = nullptr; + m_int64_value = {0}; + ; + } + + return m_int64_value; + } + + uint64_t& uint64_value_() + { + if (0x0000000a != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x0000000a; + member_destructor_ = nullptr; + m_uint64_value = {0}; + ; + } + + return m_uint64_value; + } + + float& float32_value_() + { + if (0x0000000b != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x0000000b; + member_destructor_ = nullptr; + m_float32_value = {0.0}; + ; + } + + return m_float32_value; + } + + double& float64_value_() + { + if (0x0000000c != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x0000000c; + member_destructor_ = nullptr; + m_float64_value = {0.0}; + ; + } + + return m_float64_value; + } + + long double& float128_value_() + { + if (0x0000000d != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x0000000d; + member_destructor_ = nullptr; + m_float128_value = {0.0}; + ; + } + + return m_float128_value; + } + + char& char_value_() + { + if (0x0000000e != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x0000000e; + member_destructor_ = nullptr; + m_char_value = {0}; + ; + } + + return m_char_value; + } + + wchar_t& wchar_value_() + { + if (0x0000000f != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x0000000f; + member_destructor_ = nullptr; + m_wchar_value = {0}; + ; + } + + return m_wchar_value; + } + + int32_t& enumerated_value_() + { + if (0x00000010 != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x00000010; + member_destructor_ = nullptr; + m_enumerated_value = {0}; + ; + } + + return m_enumerated_value; + } + + eprosima::fastcdr::fixed_string& string8_value_() + { + if (0x00000011 != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x00000011; + member_destructor_ = [&]() {m_string8_value.~fixed_string();}; + new(&m_string8_value) eprosima::fastcdr::fixed_string(); + ; + } + + return m_string8_value; + } + + std::wstring& string16_value_() + { + if (0x00000012 != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x00000012; + member_destructor_ = [&]() {m_string16_value.~basic_string();}; + new(&m_string16_value) std::wstring(); + ; + } + + return m_string16_value; + } + + ExtendedAnnotationParameterValue& extended_value_() + { + if (0x00000013 != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x00000013; + member_destructor_ = [&]() {m_extended_value.~ExtendedAnnotationParameterValue();}; + new(&m_extended_value) ExtendedAnnotationParameterValue(); + ; + } + + return m_extended_value; + } + + + uint8_t m__d {0}; + + union + { + bool m_boolean_value; + uint8_t m_byte_value; + int8_t m_int8_value; + uint8_t m_uint8_value; + int16_t m_int16_value; + uint16_t m_uint_16_value; + int32_t m_int32_value; + uint32_t m_uint32_value; + int64_t m_int64_value; + uint64_t m_uint64_value; + float m_float32_value; + double m_float64_value; + long double m_float128_value; + char m_char_value; + wchar_t m_wchar_value; + int32_t m_enumerated_value; + eprosima::fastcdr::fixed_string m_string8_value; + std::wstring m_string16_value; + ExtendedAnnotationParameterValue m_extended_value; + }; + + uint32_t selected_member_ {0x0FFFFFFFu}; + + std::function member_destructor_; +}; +/*! + * @brief This class represents the structure AppliedAnnotationParameter defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class AppliedAnnotationParameter +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport AppliedAnnotationParameter() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~AppliedAnnotationParameter() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object AppliedAnnotationParameter that will be copied. + */ + eProsima_user_DllExport AppliedAnnotationParameter( + const AppliedAnnotationParameter& x) + { + m_paramname_hash = x.m_paramname_hash; + + m_value = x.m_value; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object AppliedAnnotationParameter that will be copied. + */ + eProsima_user_DllExport AppliedAnnotationParameter( + AppliedAnnotationParameter&& x) noexcept + { + m_paramname_hash = std::move(x.m_paramname_hash); + m_value = std::move(x.m_value); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object AppliedAnnotationParameter that will be copied. + */ + eProsima_user_DllExport AppliedAnnotationParameter& operator =( + const AppliedAnnotationParameter& x) + { + + m_paramname_hash = x.m_paramname_hash; + + m_value = x.m_value; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object AppliedAnnotationParameter that will be copied. + */ + eProsima_user_DllExport AppliedAnnotationParameter& operator =( + AppliedAnnotationParameter&& x) noexcept + { + + m_paramname_hash = std::move(x.m_paramname_hash); + m_value = std::move(x.m_value); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x AppliedAnnotationParameter object to compare. + */ + eProsima_user_DllExport bool operator ==( + const AppliedAnnotationParameter& x) const + { + return (m_paramname_hash == x.m_paramname_hash && + m_value == x.m_value); + } + + /*! + * @brief Comparison operator. + * @param x AppliedAnnotationParameter object to compare. + */ + eProsima_user_DllExport bool operator !=( + const AppliedAnnotationParameter& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member paramname_hash + * @param _paramname_hash New value to be copied in member paramname_hash + */ + eProsima_user_DllExport void paramname_hash( + const NameHash& _paramname_hash) + { + m_paramname_hash = _paramname_hash; + } + + /*! + * @brief This function moves the value in member paramname_hash + * @param _paramname_hash New value to be moved in member paramname_hash + */ + eProsima_user_DllExport void paramname_hash( + NameHash&& _paramname_hash) + { + m_paramname_hash = std::move(_paramname_hash); + } + + /*! + * @brief This function returns a constant reference to member paramname_hash + * @return Constant reference to member paramname_hash + */ + eProsima_user_DllExport const NameHash& paramname_hash() const + { + return m_paramname_hash; + } + + /*! + * @brief This function returns a reference to member paramname_hash + * @return Reference to member paramname_hash + */ + eProsima_user_DllExport NameHash& paramname_hash() + { + return m_paramname_hash; + } + + + /*! + * @brief This function copies the value in member value + * @param _value New value to be copied in member value + */ + eProsima_user_DllExport void value( + const AnnotationParameterValue& _value) + { + m_value = _value; + } + + /*! + * @brief This function moves the value in member value + * @param _value New value to be moved in member value + */ + eProsima_user_DllExport void value( + AnnotationParameterValue&& _value) + { + m_value = std::move(_value); + } + + /*! + * @brief This function returns a constant reference to member value + * @return Constant reference to member value + */ + eProsima_user_DllExport const AnnotationParameterValue& value() const + { + return m_value; + } + + /*! + * @brief This function returns a reference to member value + * @return Reference to member value + */ + eProsima_user_DllExport AnnotationParameterValue& value() + { + return m_value; + } + + + +private: + + NameHash m_paramname_hash{0}; + AnnotationParameterValue m_value; + +}; +typedef std::vector AppliedAnnotationParameterSeq; + +/*! + * @brief This class represents the structure AppliedAnnotation defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class AppliedAnnotation +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport AppliedAnnotation() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~AppliedAnnotation() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object AppliedAnnotation that will be copied. + */ + eProsima_user_DllExport AppliedAnnotation( + const AppliedAnnotation& x) + { + m_annotation_typeid = x.m_annotation_typeid; + + m_param_seq = x.m_param_seq; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object AppliedAnnotation that will be copied. + */ + eProsima_user_DllExport AppliedAnnotation( + AppliedAnnotation&& x) noexcept + { + m_annotation_typeid = std::move(x.m_annotation_typeid); + m_param_seq = std::move(x.m_param_seq); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object AppliedAnnotation that will be copied. + */ + eProsima_user_DllExport AppliedAnnotation& operator =( + const AppliedAnnotation& x) + { + + m_annotation_typeid = x.m_annotation_typeid; + + m_param_seq = x.m_param_seq; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object AppliedAnnotation that will be copied. + */ + eProsima_user_DllExport AppliedAnnotation& operator =( + AppliedAnnotation&& x) noexcept + { + + m_annotation_typeid = std::move(x.m_annotation_typeid); + m_param_seq = std::move(x.m_param_seq); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x AppliedAnnotation object to compare. + */ + eProsima_user_DllExport bool operator ==( + const AppliedAnnotation& x) const + { + return (m_annotation_typeid == x.m_annotation_typeid && + m_param_seq == x.m_param_seq); + } + + /*! + * @brief Comparison operator. + * @param x AppliedAnnotation object to compare. + */ + eProsima_user_DllExport bool operator !=( + const AppliedAnnotation& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member annotation_typeid + * @param _annotation_typeid New value to be copied in member annotation_typeid + */ + eProsima_user_DllExport void annotation_typeid( + const TypeIdentifier& _annotation_typeid) + { + m_annotation_typeid = _annotation_typeid; + } + + /*! + * @brief This function moves the value in member annotation_typeid + * @param _annotation_typeid New value to be moved in member annotation_typeid + */ + eProsima_user_DllExport void annotation_typeid( + TypeIdentifier&& _annotation_typeid) + { + m_annotation_typeid = std::move(_annotation_typeid); + } + + /*! + * @brief This function returns a constant reference to member annotation_typeid + * @return Constant reference to member annotation_typeid + */ + eProsima_user_DllExport const TypeIdentifier& annotation_typeid() const + { + return m_annotation_typeid; + } + + /*! + * @brief This function returns a reference to member annotation_typeid + * @return Reference to member annotation_typeid + */ + eProsima_user_DllExport TypeIdentifier& annotation_typeid() + { + return m_annotation_typeid; + } + + + /*! + * @brief This function copies the value in member param_seq + * @param _param_seq New value to be copied in member param_seq + */ + eProsima_user_DllExport void param_seq( + const eprosima::fastcdr::optional& _param_seq) + { + m_param_seq = _param_seq; + } + + /*! + * @brief This function moves the value in member param_seq + * @param _param_seq New value to be moved in member param_seq + */ + eProsima_user_DllExport void param_seq( + eprosima::fastcdr::optional&& _param_seq) + { + m_param_seq = std::move(_param_seq); + } + + /*! + * @brief This function returns a constant reference to member param_seq + * @return Constant reference to member param_seq + */ + eProsima_user_DllExport const eprosima::fastcdr::optional& param_seq() const + { + return m_param_seq; + } + + /*! + * @brief This function returns a reference to member param_seq + * @return Reference to member param_seq + */ + eProsima_user_DllExport eprosima::fastcdr::optional& param_seq() + { + return m_param_seq; + } + + + +private: + + TypeIdentifier m_annotation_typeid; + eprosima::fastcdr::optional m_param_seq; + +}; +typedef std::vector AppliedAnnotationSeq; + +/*! + * @brief This class represents the structure AppliedVerbatimAnnotation defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class AppliedVerbatimAnnotation +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport AppliedVerbatimAnnotation() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~AppliedVerbatimAnnotation() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object AppliedVerbatimAnnotation that will be copied. + */ + eProsima_user_DllExport AppliedVerbatimAnnotation( + const AppliedVerbatimAnnotation& x) + { + m_placement = x.m_placement; + + m_language = x.m_language; + + m_text = x.m_text; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object AppliedVerbatimAnnotation that will be copied. + */ + eProsima_user_DllExport AppliedVerbatimAnnotation( + AppliedVerbatimAnnotation&& x) noexcept + { + m_placement = std::move(x.m_placement); + m_language = std::move(x.m_language); + m_text = std::move(x.m_text); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object AppliedVerbatimAnnotation that will be copied. + */ + eProsima_user_DllExport AppliedVerbatimAnnotation& operator =( + const AppliedVerbatimAnnotation& x) + { + + m_placement = x.m_placement; + + m_language = x.m_language; + + m_text = x.m_text; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object AppliedVerbatimAnnotation that will be copied. + */ + eProsima_user_DllExport AppliedVerbatimAnnotation& operator =( + AppliedVerbatimAnnotation&& x) noexcept + { + + m_placement = std::move(x.m_placement); + m_language = std::move(x.m_language); + m_text = std::move(x.m_text); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x AppliedVerbatimAnnotation object to compare. + */ + eProsima_user_DllExport bool operator ==( + const AppliedVerbatimAnnotation& x) const + { + return (m_placement == x.m_placement && + m_language == x.m_language && + m_text == x.m_text); + } + + /*! + * @brief Comparison operator. + * @param x AppliedVerbatimAnnotation object to compare. + */ + eProsima_user_DllExport bool operator !=( + const AppliedVerbatimAnnotation& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member placement + * @param _placement New value to be copied in member placement + */ + eProsima_user_DllExport void placement( + const eprosima::fastcdr::fixed_string<32>& _placement) + { + m_placement = _placement; + } + + /*! + * @brief This function moves the value in member placement + * @param _placement New value to be moved in member placement + */ + eProsima_user_DllExport void placement( + eprosima::fastcdr::fixed_string<32>&& _placement) + { + m_placement = std::move(_placement); + } + + /*! + * @brief This function returns a constant reference to member placement + * @return Constant reference to member placement + */ + eProsima_user_DllExport const eprosima::fastcdr::fixed_string<32>& placement() const + { + return m_placement; + } + + /*! + * @brief This function returns a reference to member placement + * @return Reference to member placement + */ + eProsima_user_DllExport eprosima::fastcdr::fixed_string<32>& placement() + { + return m_placement; + } + + + /*! + * @brief This function copies the value in member language + * @param _language New value to be copied in member language + */ + eProsima_user_DllExport void language( + const eprosima::fastcdr::fixed_string<32>& _language) + { + m_language = _language; + } + + /*! + * @brief This function moves the value in member language + * @param _language New value to be moved in member language + */ + eProsima_user_DllExport void language( + eprosima::fastcdr::fixed_string<32>&& _language) + { + m_language = std::move(_language); + } + + /*! + * @brief This function returns a constant reference to member language + * @return Constant reference to member language + */ + eProsima_user_DllExport const eprosima::fastcdr::fixed_string<32>& language() const + { + return m_language; + } + + /*! + * @brief This function returns a reference to member language + * @return Reference to member language + */ + eProsima_user_DllExport eprosima::fastcdr::fixed_string<32>& language() + { + return m_language; + } + + + /*! + * @brief This function copies the value in member text + * @param _text New value to be copied in member text + */ + eProsima_user_DllExport void text( + const std::string& _text) + { + m_text = _text; + } + + /*! + * @brief This function moves the value in member text + * @param _text New value to be moved in member text + */ + eProsima_user_DllExport void text( + std::string&& _text) + { + m_text = std::move(_text); + } + + /*! + * @brief This function returns a constant reference to member text + * @return Constant reference to member text + */ + eProsima_user_DllExport const std::string& text() const + { + return m_text; + } + + /*! + * @brief This function returns a reference to member text + * @return Reference to member text + */ + eProsima_user_DllExport std::string& text() + { + return m_text; + } + + + +private: + + eprosima::fastcdr::fixed_string<32> m_placement; + eprosima::fastcdr::fixed_string<32> m_language; + std::string m_text; + +}; +/*! + * @brief This class represents the structure AppliedBuiltinMemberAnnotations defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class AppliedBuiltinMemberAnnotations +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport AppliedBuiltinMemberAnnotations() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~AppliedBuiltinMemberAnnotations() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object AppliedBuiltinMemberAnnotations that will be copied. + */ + eProsima_user_DllExport AppliedBuiltinMemberAnnotations( + const AppliedBuiltinMemberAnnotations& x) + { + m_unit = x.m_unit; + + m_min = x.m_min; + + m_max = x.m_max; + + m_hash_id = x.m_hash_id; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object AppliedBuiltinMemberAnnotations that will be copied. + */ + eProsima_user_DllExport AppliedBuiltinMemberAnnotations( + AppliedBuiltinMemberAnnotations&& x) noexcept + { + m_unit = std::move(x.m_unit); + m_min = std::move(x.m_min); + m_max = std::move(x.m_max); + m_hash_id = std::move(x.m_hash_id); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object AppliedBuiltinMemberAnnotations that will be copied. + */ + eProsima_user_DllExport AppliedBuiltinMemberAnnotations& operator =( + const AppliedBuiltinMemberAnnotations& x) + { + + m_unit = x.m_unit; + + m_min = x.m_min; + + m_max = x.m_max; + + m_hash_id = x.m_hash_id; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object AppliedBuiltinMemberAnnotations that will be copied. + */ + eProsima_user_DllExport AppliedBuiltinMemberAnnotations& operator =( + AppliedBuiltinMemberAnnotations&& x) noexcept + { + + m_unit = std::move(x.m_unit); + m_min = std::move(x.m_min); + m_max = std::move(x.m_max); + m_hash_id = std::move(x.m_hash_id); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x AppliedBuiltinMemberAnnotations object to compare. + */ + eProsima_user_DllExport bool operator ==( + const AppliedBuiltinMemberAnnotations& x) const + { + return (m_unit == x.m_unit && + m_min == x.m_min && + m_max == x.m_max && + m_hash_id == x.m_hash_id); + } + + /*! + * @brief Comparison operator. + * @param x AppliedBuiltinMemberAnnotations object to compare. + */ + eProsima_user_DllExport bool operator !=( + const AppliedBuiltinMemberAnnotations& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member unit + * @param _unit New value to be copied in member unit + */ + eProsima_user_DllExport void unit( + const eprosima::fastcdr::optional& _unit) + { + m_unit = _unit; + } + + /*! + * @brief This function moves the value in member unit + * @param _unit New value to be moved in member unit + */ + eProsima_user_DllExport void unit( + eprosima::fastcdr::optional&& _unit) + { + m_unit = std::move(_unit); + } + + /*! + * @brief This function returns a constant reference to member unit + * @return Constant reference to member unit + */ + eProsima_user_DllExport const eprosima::fastcdr::optional& unit() const + { + return m_unit; + } + + /*! + * @brief This function returns a reference to member unit + * @return Reference to member unit + */ + eProsima_user_DllExport eprosima::fastcdr::optional& unit() + { + return m_unit; + } + + + /*! + * @brief This function copies the value in member min + * @param _min New value to be copied in member min + */ + eProsima_user_DllExport void min( + const eprosima::fastcdr::optional& _min) + { + m_min = _min; + } + + /*! + * @brief This function moves the value in member min + * @param _min New value to be moved in member min + */ + eProsima_user_DllExport void min( + eprosima::fastcdr::optional&& _min) + { + m_min = std::move(_min); + } + + /*! + * @brief This function returns a constant reference to member min + * @return Constant reference to member min + */ + eProsima_user_DllExport const eprosima::fastcdr::optional& min() const + { + return m_min; + } + + /*! + * @brief This function returns a reference to member min + * @return Reference to member min + */ + eProsima_user_DllExport eprosima::fastcdr::optional& min() + { + return m_min; + } + + + /*! + * @brief This function copies the value in member max + * @param _max New value to be copied in member max + */ + eProsima_user_DllExport void max( + const eprosima::fastcdr::optional& _max) + { + m_max = _max; + } + + /*! + * @brief This function moves the value in member max + * @param _max New value to be moved in member max + */ + eProsima_user_DllExport void max( + eprosima::fastcdr::optional&& _max) + { + m_max = std::move(_max); + } + + /*! + * @brief This function returns a constant reference to member max + * @return Constant reference to member max + */ + eProsima_user_DllExport const eprosima::fastcdr::optional& max() const + { + return m_max; + } + + /*! + * @brief This function returns a reference to member max + * @return Reference to member max + */ + eProsima_user_DllExport eprosima::fastcdr::optional& max() + { + return m_max; + } + + + /*! + * @brief This function copies the value in member hash_id + * @param _hash_id New value to be copied in member hash_id + */ + eProsima_user_DllExport void hash_id( + const eprosima::fastcdr::optional& _hash_id) + { + m_hash_id = _hash_id; + } + + /*! + * @brief This function moves the value in member hash_id + * @param _hash_id New value to be moved in member hash_id + */ + eProsima_user_DllExport void hash_id( + eprosima::fastcdr::optional&& _hash_id) + { + m_hash_id = std::move(_hash_id); + } + + /*! + * @brief This function returns a constant reference to member hash_id + * @return Constant reference to member hash_id + */ + eProsima_user_DllExport const eprosima::fastcdr::optional& hash_id() const + { + return m_hash_id; + } + + /*! + * @brief This function returns a reference to member hash_id + * @return Reference to member hash_id + */ + eProsima_user_DllExport eprosima::fastcdr::optional& hash_id() + { + return m_hash_id; + } + + + +private: + + eprosima::fastcdr::optional m_unit; + eprosima::fastcdr::optional m_min; + eprosima::fastcdr::optional m_max; + eprosima::fastcdr::optional m_hash_id; + +}; +/*! + * @brief This class represents the structure CommonStructMember defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CommonStructMember +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport CommonStructMember() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~CommonStructMember() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object CommonStructMember that will be copied. + */ + eProsima_user_DllExport CommonStructMember( + const CommonStructMember& x) + { + m_member_id = x.m_member_id; + + m_member_flags = x.m_member_flags; + + m_member_type_id = x.m_member_type_id; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object CommonStructMember that will be copied. + */ + eProsima_user_DllExport CommonStructMember( + CommonStructMember&& x) noexcept + { + m_member_id = x.m_member_id; + m_member_flags = std::move(x.m_member_flags); + m_member_type_id = std::move(x.m_member_type_id); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object CommonStructMember that will be copied. + */ + eProsima_user_DllExport CommonStructMember& operator =( + const CommonStructMember& x) + { + + m_member_id = x.m_member_id; + + m_member_flags = x.m_member_flags; + + m_member_type_id = x.m_member_type_id; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object CommonStructMember that will be copied. + */ + eProsima_user_DllExport CommonStructMember& operator =( + CommonStructMember&& x) noexcept + { + + m_member_id = x.m_member_id; + m_member_flags = std::move(x.m_member_flags); + m_member_type_id = std::move(x.m_member_type_id); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x CommonStructMember object to compare. + */ + eProsima_user_DllExport bool operator ==( + const CommonStructMember& x) const + { + return (m_member_id == x.m_member_id && + m_member_flags == x.m_member_flags && + m_member_type_id == x.m_member_type_id); + } + + /*! + * @brief Comparison operator. + * @param x CommonStructMember object to compare. + */ + eProsima_user_DllExport bool operator !=( + const CommonStructMember& x) const + { + return !(*this == x); + } + + /*! + * @brief This function sets a value in member member_id + * @param _member_id New value for member member_id + */ + eProsima_user_DllExport void member_id( + MemberId _member_id) + { + m_member_id = _member_id; + } + + /*! + * @brief This function returns the value of member member_id + * @return Value of member member_id + */ + eProsima_user_DllExport MemberId member_id() const + { + return m_member_id; + } + + /*! + * @brief This function returns a reference to member member_id + * @return Reference to member member_id + */ + eProsima_user_DllExport MemberId& member_id() + { + return m_member_id; + } + + + /*! + * @brief This function copies the value in member member_flags + * @param _member_flags New value to be copied in member member_flags + */ + eProsima_user_DllExport void member_flags( + const StructMemberFlag& _member_flags) + { + m_member_flags = _member_flags; + } + + /*! + * @brief This function moves the value in member member_flags + * @param _member_flags New value to be moved in member member_flags + */ + eProsima_user_DllExport void member_flags( + StructMemberFlag&& _member_flags) + { + m_member_flags = std::move(_member_flags); + } + + /*! + * @brief This function returns a constant reference to member member_flags + * @return Constant reference to member member_flags + */ + eProsima_user_DllExport const StructMemberFlag& member_flags() const + { + return m_member_flags; + } + + /*! + * @brief This function returns a reference to member member_flags + * @return Reference to member member_flags + */ + eProsima_user_DllExport StructMemberFlag& member_flags() + { + return m_member_flags; + } + + + /*! + * @brief This function copies the value in member member_type_id + * @param _member_type_id New value to be copied in member member_type_id + */ + eProsima_user_DllExport void member_type_id( + const TypeIdentifier& _member_type_id) + { + m_member_type_id = _member_type_id; + } + + /*! + * @brief This function moves the value in member member_type_id + * @param _member_type_id New value to be moved in member member_type_id + */ + eProsima_user_DllExport void member_type_id( + TypeIdentifier&& _member_type_id) + { + m_member_type_id = std::move(_member_type_id); + } + + /*! + * @brief This function returns a constant reference to member member_type_id + * @return Constant reference to member member_type_id + */ + eProsima_user_DllExport const TypeIdentifier& member_type_id() const + { + return m_member_type_id; + } + + /*! + * @brief This function returns a reference to member member_type_id + * @return Reference to member member_type_id + */ + eProsima_user_DllExport TypeIdentifier& member_type_id() + { + return m_member_type_id; + } + + + +private: + + MemberId m_member_id{0}; + StructMemberFlag m_member_flags{0}; + TypeIdentifier m_member_type_id; + +}; +/*! + * @brief This class represents the structure CompleteMemberDetail defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteMemberDetail +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport CompleteMemberDetail() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~CompleteMemberDetail() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object CompleteMemberDetail that will be copied. + */ + eProsima_user_DllExport CompleteMemberDetail( + const CompleteMemberDetail& x) + { + m_name = x.m_name; + + m_ann_builtin = x.m_ann_builtin; + + m_ann_custom = x.m_ann_custom; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object CompleteMemberDetail that will be copied. + */ + eProsima_user_DllExport CompleteMemberDetail( + CompleteMemberDetail&& x) noexcept + { + m_name = std::move(x.m_name); + m_ann_builtin = std::move(x.m_ann_builtin); + m_ann_custom = std::move(x.m_ann_custom); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object CompleteMemberDetail that will be copied. + */ + eProsima_user_DllExport CompleteMemberDetail& operator =( + const CompleteMemberDetail& x) + { + + m_name = x.m_name; + + m_ann_builtin = x.m_ann_builtin; + + m_ann_custom = x.m_ann_custom; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object CompleteMemberDetail that will be copied. + */ + eProsima_user_DllExport CompleteMemberDetail& operator =( + CompleteMemberDetail&& x) noexcept + { + + m_name = std::move(x.m_name); + m_ann_builtin = std::move(x.m_ann_builtin); + m_ann_custom = std::move(x.m_ann_custom); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x CompleteMemberDetail object to compare. + */ + eProsima_user_DllExport bool operator ==( + const CompleteMemberDetail& x) const + { + return (m_name == x.m_name && + m_ann_builtin == x.m_ann_builtin && + m_ann_custom == x.m_ann_custom); + } + + /*! + * @brief Comparison operator. + * @param x CompleteMemberDetail object to compare. + */ + eProsima_user_DllExport bool operator !=( + const CompleteMemberDetail& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member name + * @param _name New value to be copied in member name + */ + eProsima_user_DllExport void name( + const MemberName& _name) + { + m_name = _name; + } + + /*! + * @brief This function moves the value in member name + * @param _name New value to be moved in member name + */ + eProsima_user_DllExport void name( + MemberName&& _name) + { + m_name = std::move(_name); + } + + /*! + * @brief This function returns a constant reference to member name + * @return Constant reference to member name + */ + eProsima_user_DllExport const MemberName& name() const + { + return m_name; + } + + /*! + * @brief This function returns a reference to member name + * @return Reference to member name + */ + eProsima_user_DllExport MemberName& name() + { + return m_name; + } + + + /*! + * @brief This function copies the value in member ann_builtin + * @param _ann_builtin New value to be copied in member ann_builtin + */ + eProsima_user_DllExport void ann_builtin( + const eprosima::fastcdr::optional& _ann_builtin) + { + m_ann_builtin = _ann_builtin; + } + + /*! + * @brief This function moves the value in member ann_builtin + * @param _ann_builtin New value to be moved in member ann_builtin + */ + eProsima_user_DllExport void ann_builtin( + eprosima::fastcdr::optional&& _ann_builtin) + { + m_ann_builtin = std::move(_ann_builtin); + } + + /*! + * @brief This function returns a constant reference to member ann_builtin + * @return Constant reference to member ann_builtin + */ + eProsima_user_DllExport const eprosima::fastcdr::optional& ann_builtin() const + { + return m_ann_builtin; + } + + /*! + * @brief This function returns a reference to member ann_builtin + * @return Reference to member ann_builtin + */ + eProsima_user_DllExport eprosima::fastcdr::optional& ann_builtin() + { + return m_ann_builtin; + } + + + /*! + * @brief This function copies the value in member ann_custom + * @param _ann_custom New value to be copied in member ann_custom + */ + eProsima_user_DllExport void ann_custom( + const eprosima::fastcdr::optional& _ann_custom) + { + m_ann_custom = _ann_custom; + } + + /*! + * @brief This function moves the value in member ann_custom + * @param _ann_custom New value to be moved in member ann_custom + */ + eProsima_user_DllExport void ann_custom( + eprosima::fastcdr::optional&& _ann_custom) + { + m_ann_custom = std::move(_ann_custom); + } + + /*! + * @brief This function returns a constant reference to member ann_custom + * @return Constant reference to member ann_custom + */ + eProsima_user_DllExport const eprosima::fastcdr::optional& ann_custom() const + { + return m_ann_custom; + } + + /*! + * @brief This function returns a reference to member ann_custom + * @return Reference to member ann_custom + */ + eProsima_user_DllExport eprosima::fastcdr::optional& ann_custom() + { + return m_ann_custom; + } + + + +private: + + MemberName m_name; + eprosima::fastcdr::optional m_ann_builtin; + eprosima::fastcdr::optional m_ann_custom; + +}; +/*! + * @brief This class represents the structure MinimalMemberDetail defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalMemberDetail +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport MinimalMemberDetail() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~MinimalMemberDetail() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object MinimalMemberDetail that will be copied. + */ + eProsima_user_DllExport MinimalMemberDetail( + const MinimalMemberDetail& x) + { + m_name_hash = x.m_name_hash; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object MinimalMemberDetail that will be copied. + */ + eProsima_user_DllExport MinimalMemberDetail( + MinimalMemberDetail&& x) noexcept + { + m_name_hash = std::move(x.m_name_hash); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object MinimalMemberDetail that will be copied. + */ + eProsima_user_DllExport MinimalMemberDetail& operator =( + const MinimalMemberDetail& x) + { + + m_name_hash = x.m_name_hash; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object MinimalMemberDetail that will be copied. + */ + eProsima_user_DllExport MinimalMemberDetail& operator =( + MinimalMemberDetail&& x) noexcept + { + + m_name_hash = std::move(x.m_name_hash); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x MinimalMemberDetail object to compare. + */ + eProsima_user_DllExport bool operator ==( + const MinimalMemberDetail& x) const + { + return (m_name_hash == x.m_name_hash); + } + + /*! + * @brief Comparison operator. + * @param x MinimalMemberDetail object to compare. + */ + eProsima_user_DllExport bool operator !=( + const MinimalMemberDetail& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member name_hash + * @param _name_hash New value to be copied in member name_hash + */ + eProsima_user_DllExport void name_hash( + const NameHash& _name_hash) + { + m_name_hash = _name_hash; + } + + /*! + * @brief This function moves the value in member name_hash + * @param _name_hash New value to be moved in member name_hash + */ + eProsima_user_DllExport void name_hash( + NameHash&& _name_hash) + { + m_name_hash = std::move(_name_hash); + } + + /*! + * @brief This function returns a constant reference to member name_hash + * @return Constant reference to member name_hash + */ + eProsima_user_DllExport const NameHash& name_hash() const + { + return m_name_hash; + } + + /*! + * @brief This function returns a reference to member name_hash + * @return Reference to member name_hash + */ + eProsima_user_DllExport NameHash& name_hash() + { + return m_name_hash; + } + + + +private: + + NameHash m_name_hash{0}; + +}; +/*! + * @brief This class represents the structure CompleteStructMember defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteStructMember +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport CompleteStructMember() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~CompleteStructMember() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object CompleteStructMember that will be copied. + */ + eProsima_user_DllExport CompleteStructMember( + const CompleteStructMember& x) + { + m_common = x.m_common; + + m_detail = x.m_detail; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object CompleteStructMember that will be copied. + */ + eProsima_user_DllExport CompleteStructMember( + CompleteStructMember&& x) noexcept + { + m_common = std::move(x.m_common); + m_detail = std::move(x.m_detail); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object CompleteStructMember that will be copied. + */ + eProsima_user_DllExport CompleteStructMember& operator =( + const CompleteStructMember& x) + { + + m_common = x.m_common; + + m_detail = x.m_detail; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object CompleteStructMember that will be copied. + */ + eProsima_user_DllExport CompleteStructMember& operator =( + CompleteStructMember&& x) noexcept + { + + m_common = std::move(x.m_common); + m_detail = std::move(x.m_detail); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x CompleteStructMember object to compare. + */ + eProsima_user_DllExport bool operator ==( + const CompleteStructMember& x) const + { + return (m_common == x.m_common && + m_detail == x.m_detail); + } + + /*! + * @brief Comparison operator. + * @param x CompleteStructMember object to compare. + */ + eProsima_user_DllExport bool operator !=( + const CompleteStructMember& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member common + * @param _common New value to be copied in member common + */ + eProsima_user_DllExport void common( + const CommonStructMember& _common) + { + m_common = _common; + } + + /*! + * @brief This function moves the value in member common + * @param _common New value to be moved in member common + */ + eProsima_user_DllExport void common( + CommonStructMember&& _common) + { + m_common = std::move(_common); + } + + /*! + * @brief This function returns a constant reference to member common + * @return Constant reference to member common + */ + eProsima_user_DllExport const CommonStructMember& common() const + { + return m_common; + } + + /*! + * @brief This function returns a reference to member common + * @return Reference to member common + */ + eProsima_user_DllExport CommonStructMember& common() + { + return m_common; + } + + + /*! + * @brief This function copies the value in member detail + * @param _detail New value to be copied in member detail + */ + eProsima_user_DllExport void detail( + const CompleteMemberDetail& _detail) + { + m_detail = _detail; + } + + /*! + * @brief This function moves the value in member detail + * @param _detail New value to be moved in member detail + */ + eProsima_user_DllExport void detail( + CompleteMemberDetail&& _detail) + { + m_detail = std::move(_detail); + } + + /*! + * @brief This function returns a constant reference to member detail + * @return Constant reference to member detail + */ + eProsima_user_DllExport const CompleteMemberDetail& detail() const + { + return m_detail; + } + + /*! + * @brief This function returns a reference to member detail + * @return Reference to member detail + */ + eProsima_user_DllExport CompleteMemberDetail& detail() + { + return m_detail; + } + + + +private: + + CommonStructMember m_common; + CompleteMemberDetail m_detail; + +}; +typedef std::vector CompleteStructMemberSeq; + +/*! + * @brief This class represents the structure MinimalStructMember defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalStructMember +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport MinimalStructMember() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~MinimalStructMember() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object MinimalStructMember that will be copied. + */ + eProsima_user_DllExport MinimalStructMember( + const MinimalStructMember& x) + { + m_common = x.m_common; + + m_detail = x.m_detail; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object MinimalStructMember that will be copied. + */ + eProsima_user_DllExport MinimalStructMember( + MinimalStructMember&& x) noexcept + { + m_common = std::move(x.m_common); + m_detail = std::move(x.m_detail); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object MinimalStructMember that will be copied. + */ + eProsima_user_DllExport MinimalStructMember& operator =( + const MinimalStructMember& x) + { + + m_common = x.m_common; + + m_detail = x.m_detail; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object MinimalStructMember that will be copied. + */ + eProsima_user_DllExport MinimalStructMember& operator =( + MinimalStructMember&& x) noexcept + { + + m_common = std::move(x.m_common); + m_detail = std::move(x.m_detail); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x MinimalStructMember object to compare. + */ + eProsima_user_DllExport bool operator ==( + const MinimalStructMember& x) const + { + return (m_common == x.m_common && + m_detail == x.m_detail); + } + + /*! + * @brief Comparison operator. + * @param x MinimalStructMember object to compare. + */ + eProsima_user_DllExport bool operator !=( + const MinimalStructMember& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member common + * @param _common New value to be copied in member common + */ + eProsima_user_DllExport void common( + const CommonStructMember& _common) + { + m_common = _common; + } + + /*! + * @brief This function moves the value in member common + * @param _common New value to be moved in member common + */ + eProsima_user_DllExport void common( + CommonStructMember&& _common) + { + m_common = std::move(_common); + } + + /*! + * @brief This function returns a constant reference to member common + * @return Constant reference to member common + */ + eProsima_user_DllExport const CommonStructMember& common() const + { + return m_common; + } + + /*! + * @brief This function returns a reference to member common + * @return Reference to member common + */ + eProsima_user_DllExport CommonStructMember& common() + { + return m_common; + } + + + /*! + * @brief This function copies the value in member detail + * @param _detail New value to be copied in member detail + */ + eProsima_user_DllExport void detail( + const MinimalMemberDetail& _detail) + { + m_detail = _detail; + } + + /*! + * @brief This function moves the value in member detail + * @param _detail New value to be moved in member detail + */ + eProsima_user_DllExport void detail( + MinimalMemberDetail&& _detail) + { + m_detail = std::move(_detail); + } + + /*! + * @brief This function returns a constant reference to member detail + * @return Constant reference to member detail + */ + eProsima_user_DllExport const MinimalMemberDetail& detail() const + { + return m_detail; + } + + /*! + * @brief This function returns a reference to member detail + * @return Reference to member detail + */ + eProsima_user_DllExport MinimalMemberDetail& detail() + { + return m_detail; + } + + + +private: + + CommonStructMember m_common; + MinimalMemberDetail m_detail; + +}; +typedef std::vector MinimalStructMemberSeq; + +/*! + * @brief This class represents the structure AppliedBuiltinTypeAnnotations defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class AppliedBuiltinTypeAnnotations +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport AppliedBuiltinTypeAnnotations() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~AppliedBuiltinTypeAnnotations() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object AppliedBuiltinTypeAnnotations that will be copied. + */ + eProsima_user_DllExport AppliedBuiltinTypeAnnotations( + const AppliedBuiltinTypeAnnotations& x) + { + m_verbatim = x.m_verbatim; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object AppliedBuiltinTypeAnnotations that will be copied. + */ + eProsima_user_DllExport AppliedBuiltinTypeAnnotations( + AppliedBuiltinTypeAnnotations&& x) noexcept + { + m_verbatim = std::move(x.m_verbatim); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object AppliedBuiltinTypeAnnotations that will be copied. + */ + eProsima_user_DllExport AppliedBuiltinTypeAnnotations& operator =( + const AppliedBuiltinTypeAnnotations& x) + { + + m_verbatim = x.m_verbatim; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object AppliedBuiltinTypeAnnotations that will be copied. + */ + eProsima_user_DllExport AppliedBuiltinTypeAnnotations& operator =( + AppliedBuiltinTypeAnnotations&& x) noexcept + { + + m_verbatim = std::move(x.m_verbatim); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x AppliedBuiltinTypeAnnotations object to compare. + */ + eProsima_user_DllExport bool operator ==( + const AppliedBuiltinTypeAnnotations& x) const + { + return (m_verbatim == x.m_verbatim); + } + + /*! + * @brief Comparison operator. + * @param x AppliedBuiltinTypeAnnotations object to compare. + */ + eProsima_user_DllExport bool operator !=( + const AppliedBuiltinTypeAnnotations& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member verbatim + * @param _verbatim New value to be copied in member verbatim + */ + eProsima_user_DllExport void verbatim( + const eprosima::fastcdr::optional& _verbatim) + { + m_verbatim = _verbatim; + } + + /*! + * @brief This function moves the value in member verbatim + * @param _verbatim New value to be moved in member verbatim + */ + eProsima_user_DllExport void verbatim( + eprosima::fastcdr::optional&& _verbatim) + { + m_verbatim = std::move(_verbatim); + } + + /*! + * @brief This function returns a constant reference to member verbatim + * @return Constant reference to member verbatim + */ + eProsima_user_DllExport const eprosima::fastcdr::optional& verbatim() const + { + return m_verbatim; + } + + /*! + * @brief This function returns a reference to member verbatim + * @return Reference to member verbatim + */ + eProsima_user_DllExport eprosima::fastcdr::optional& verbatim() + { + return m_verbatim; + } + + + +private: + + eprosima::fastcdr::optional m_verbatim; + +}; +/*! + * @brief This class represents the structure MinimalTypeDetail defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalTypeDetail +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport MinimalTypeDetail() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~MinimalTypeDetail() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object MinimalTypeDetail that will be copied. + */ + eProsima_user_DllExport MinimalTypeDetail( + const MinimalTypeDetail& x) + { + static_cast(x); + } + + /*! + * @brief Move constructor. + * @param x Reference to the object MinimalTypeDetail that will be copied. + */ + eProsima_user_DllExport MinimalTypeDetail( + MinimalTypeDetail&& x) noexcept + { + static_cast(x); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object MinimalTypeDetail that will be copied. + */ + eProsima_user_DllExport MinimalTypeDetail& operator =( + const MinimalTypeDetail& x) + { + + static_cast(x); + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object MinimalTypeDetail that will be copied. + */ + eProsima_user_DllExport MinimalTypeDetail& operator =( + MinimalTypeDetail&& x) noexcept + { + + static_cast(x); + + return *this; + } + + /*! + * @brief Comparison operator. + * @param x MinimalTypeDetail object to compare. + */ + eProsima_user_DllExport bool operator ==( + const MinimalTypeDetail& x) const + { + static_cast(x); + return true; + } + + /*! + * @brief Comparison operator. + * @param x MinimalTypeDetail object to compare. + */ + eProsima_user_DllExport bool operator !=( + const MinimalTypeDetail& x) const + { + return !(*this == x); + } + + + +private: + + +}; +/*! + * @brief This class represents the structure CompleteTypeDetail defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteTypeDetail +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport CompleteTypeDetail() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~CompleteTypeDetail() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object CompleteTypeDetail that will be copied. + */ + eProsima_user_DllExport CompleteTypeDetail( + const CompleteTypeDetail& x) + { + m_ann_builtin = x.m_ann_builtin; + + m_ann_custom = x.m_ann_custom; + + m_type_name = x.m_type_name; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object CompleteTypeDetail that will be copied. + */ + eProsima_user_DllExport CompleteTypeDetail( + CompleteTypeDetail&& x) noexcept + { + m_ann_builtin = std::move(x.m_ann_builtin); + m_ann_custom = std::move(x.m_ann_custom); + m_type_name = std::move(x.m_type_name); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object CompleteTypeDetail that will be copied. + */ + eProsima_user_DllExport CompleteTypeDetail& operator =( + const CompleteTypeDetail& x) + { + + m_ann_builtin = x.m_ann_builtin; + + m_ann_custom = x.m_ann_custom; + + m_type_name = x.m_type_name; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object CompleteTypeDetail that will be copied. + */ + eProsima_user_DllExport CompleteTypeDetail& operator =( + CompleteTypeDetail&& x) noexcept + { + + m_ann_builtin = std::move(x.m_ann_builtin); + m_ann_custom = std::move(x.m_ann_custom); + m_type_name = std::move(x.m_type_name); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x CompleteTypeDetail object to compare. + */ + eProsima_user_DllExport bool operator ==( + const CompleteTypeDetail& x) const + { + return (m_ann_builtin == x.m_ann_builtin && + m_ann_custom == x.m_ann_custom && + m_type_name == x.m_type_name); + } + + /*! + * @brief Comparison operator. + * @param x CompleteTypeDetail object to compare. + */ + eProsima_user_DllExport bool operator !=( + const CompleteTypeDetail& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member ann_builtin + * @param _ann_builtin New value to be copied in member ann_builtin + */ + eProsima_user_DllExport void ann_builtin( + const eprosima::fastcdr::optional& _ann_builtin) + { + m_ann_builtin = _ann_builtin; + } + + /*! + * @brief This function moves the value in member ann_builtin + * @param _ann_builtin New value to be moved in member ann_builtin + */ + eProsima_user_DllExport void ann_builtin( + eprosima::fastcdr::optional&& _ann_builtin) + { + m_ann_builtin = std::move(_ann_builtin); + } + + /*! + * @brief This function returns a constant reference to member ann_builtin + * @return Constant reference to member ann_builtin + */ + eProsima_user_DllExport const eprosima::fastcdr::optional& ann_builtin() const + { + return m_ann_builtin; + } + + /*! + * @brief This function returns a reference to member ann_builtin + * @return Reference to member ann_builtin + */ + eProsima_user_DllExport eprosima::fastcdr::optional& ann_builtin() + { + return m_ann_builtin; + } + + + /*! + * @brief This function copies the value in member ann_custom + * @param _ann_custom New value to be copied in member ann_custom + */ + eProsima_user_DllExport void ann_custom( + const eprosima::fastcdr::optional& _ann_custom) + { + m_ann_custom = _ann_custom; + } + + /*! + * @brief This function moves the value in member ann_custom + * @param _ann_custom New value to be moved in member ann_custom + */ + eProsima_user_DllExport void ann_custom( + eprosima::fastcdr::optional&& _ann_custom) + { + m_ann_custom = std::move(_ann_custom); + } + + /*! + * @brief This function returns a constant reference to member ann_custom + * @return Constant reference to member ann_custom + */ + eProsima_user_DllExport const eprosima::fastcdr::optional& ann_custom() const + { + return m_ann_custom; + } + + /*! + * @brief This function returns a reference to member ann_custom + * @return Reference to member ann_custom + */ + eProsima_user_DllExport eprosima::fastcdr::optional& ann_custom() + { + return m_ann_custom; + } + + + /*! + * @brief This function copies the value in member type_name + * @param _type_name New value to be copied in member type_name + */ + eProsima_user_DllExport void type_name( + const QualifiedTypeName& _type_name) + { + m_type_name = _type_name; + } + + /*! + * @brief This function moves the value in member type_name + * @param _type_name New value to be moved in member type_name + */ + eProsima_user_DllExport void type_name( + QualifiedTypeName&& _type_name) + { + m_type_name = std::move(_type_name); + } + + /*! + * @brief This function returns a constant reference to member type_name + * @return Constant reference to member type_name + */ + eProsima_user_DllExport const QualifiedTypeName& type_name() const + { + return m_type_name; + } + + /*! + * @brief This function returns a reference to member type_name + * @return Reference to member type_name + */ + eProsima_user_DllExport QualifiedTypeName& type_name() + { + return m_type_name; + } + + + +private: + + eprosima::fastcdr::optional m_ann_builtin; + eprosima::fastcdr::optional m_ann_custom; + QualifiedTypeName m_type_name; + +}; +/*! + * @brief This class represents the structure CompleteStructHeader defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteStructHeader +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport CompleteStructHeader() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~CompleteStructHeader() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object CompleteStructHeader that will be copied. + */ + eProsima_user_DllExport CompleteStructHeader( + const CompleteStructHeader& x) + { + m_base_type = x.m_base_type; + + m_detail = x.m_detail; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object CompleteStructHeader that will be copied. + */ + eProsima_user_DllExport CompleteStructHeader( + CompleteStructHeader&& x) noexcept + { + m_base_type = std::move(x.m_base_type); + m_detail = std::move(x.m_detail); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object CompleteStructHeader that will be copied. + */ + eProsima_user_DllExport CompleteStructHeader& operator =( + const CompleteStructHeader& x) + { + + m_base_type = x.m_base_type; + + m_detail = x.m_detail; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object CompleteStructHeader that will be copied. + */ + eProsima_user_DllExport CompleteStructHeader& operator =( + CompleteStructHeader&& x) noexcept + { + + m_base_type = std::move(x.m_base_type); + m_detail = std::move(x.m_detail); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x CompleteStructHeader object to compare. + */ + eProsima_user_DllExport bool operator ==( + const CompleteStructHeader& x) const + { + return (m_base_type == x.m_base_type && + m_detail == x.m_detail); + } + + /*! + * @brief Comparison operator. + * @param x CompleteStructHeader object to compare. + */ + eProsima_user_DllExport bool operator !=( + const CompleteStructHeader& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member base_type + * @param _base_type New value to be copied in member base_type + */ + eProsima_user_DllExport void base_type( + const TypeIdentifier& _base_type) + { + m_base_type = _base_type; + } + + /*! + * @brief This function moves the value in member base_type + * @param _base_type New value to be moved in member base_type + */ + eProsima_user_DllExport void base_type( + TypeIdentifier&& _base_type) + { + m_base_type = std::move(_base_type); + } + + /*! + * @brief This function returns a constant reference to member base_type + * @return Constant reference to member base_type + */ + eProsima_user_DllExport const TypeIdentifier& base_type() const + { + return m_base_type; + } + + /*! + * @brief This function returns a reference to member base_type + * @return Reference to member base_type + */ + eProsima_user_DllExport TypeIdentifier& base_type() + { + return m_base_type; + } + + + /*! + * @brief This function copies the value in member detail + * @param _detail New value to be copied in member detail + */ + eProsima_user_DllExport void detail( + const CompleteTypeDetail& _detail) + { + m_detail = _detail; + } + + /*! + * @brief This function moves the value in member detail + * @param _detail New value to be moved in member detail + */ + eProsima_user_DllExport void detail( + CompleteTypeDetail&& _detail) + { + m_detail = std::move(_detail); + } + + /*! + * @brief This function returns a constant reference to member detail + * @return Constant reference to member detail + */ + eProsima_user_DllExport const CompleteTypeDetail& detail() const + { + return m_detail; + } + + /*! + * @brief This function returns a reference to member detail + * @return Reference to member detail + */ + eProsima_user_DllExport CompleteTypeDetail& detail() + { + return m_detail; + } + + + +private: + + TypeIdentifier m_base_type; + CompleteTypeDetail m_detail; + +}; +/*! + * @brief This class represents the structure MinimalStructHeader defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalStructHeader +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport MinimalStructHeader() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~MinimalStructHeader() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object MinimalStructHeader that will be copied. + */ + eProsima_user_DllExport MinimalStructHeader( + const MinimalStructHeader& x) + { + m_base_type = x.m_base_type; + + m_detail = x.m_detail; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object MinimalStructHeader that will be copied. + */ + eProsima_user_DllExport MinimalStructHeader( + MinimalStructHeader&& x) noexcept + { + m_base_type = std::move(x.m_base_type); + m_detail = std::move(x.m_detail); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object MinimalStructHeader that will be copied. + */ + eProsima_user_DllExport MinimalStructHeader& operator =( + const MinimalStructHeader& x) + { + + m_base_type = x.m_base_type; + + m_detail = x.m_detail; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object MinimalStructHeader that will be copied. + */ + eProsima_user_DllExport MinimalStructHeader& operator =( + MinimalStructHeader&& x) noexcept + { + + m_base_type = std::move(x.m_base_type); + m_detail = std::move(x.m_detail); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x MinimalStructHeader object to compare. + */ + eProsima_user_DllExport bool operator ==( + const MinimalStructHeader& x) const + { + return (m_base_type == x.m_base_type && + m_detail == x.m_detail); + } + + /*! + * @brief Comparison operator. + * @param x MinimalStructHeader object to compare. + */ + eProsima_user_DllExport bool operator !=( + const MinimalStructHeader& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member base_type + * @param _base_type New value to be copied in member base_type + */ + eProsima_user_DllExport void base_type( + const TypeIdentifier& _base_type) + { + m_base_type = _base_type; + } + + /*! + * @brief This function moves the value in member base_type + * @param _base_type New value to be moved in member base_type + */ + eProsima_user_DllExport void base_type( + TypeIdentifier&& _base_type) + { + m_base_type = std::move(_base_type); + } + + /*! + * @brief This function returns a constant reference to member base_type + * @return Constant reference to member base_type + */ + eProsima_user_DllExport const TypeIdentifier& base_type() const + { + return m_base_type; + } + + /*! + * @brief This function returns a reference to member base_type + * @return Reference to member base_type + */ + eProsima_user_DllExport TypeIdentifier& base_type() + { + return m_base_type; + } + + + /*! + * @brief This function copies the value in member detail + * @param _detail New value to be copied in member detail + */ + eProsima_user_DllExport void detail( + const MinimalTypeDetail& _detail) + { + m_detail = _detail; + } + + /*! + * @brief This function moves the value in member detail + * @param _detail New value to be moved in member detail + */ + eProsima_user_DllExport void detail( + MinimalTypeDetail&& _detail) + { + m_detail = std::move(_detail); + } + + /*! + * @brief This function returns a constant reference to member detail + * @return Constant reference to member detail + */ + eProsima_user_DllExport const MinimalTypeDetail& detail() const + { + return m_detail; + } + + /*! + * @brief This function returns a reference to member detail + * @return Reference to member detail + */ + eProsima_user_DllExport MinimalTypeDetail& detail() + { + return m_detail; + } + + + +private: + + TypeIdentifier m_base_type; + MinimalTypeDetail m_detail; + +}; +/*! + * @brief This class represents the structure CompleteStructType defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteStructType +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport CompleteStructType() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~CompleteStructType() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object CompleteStructType that will be copied. + */ + eProsima_user_DllExport CompleteStructType( + const CompleteStructType& x) + { + m_struct_flags = x.m_struct_flags; + + m_header = x.m_header; + + m_member_seq = x.m_member_seq; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object CompleteStructType that will be copied. + */ + eProsima_user_DllExport CompleteStructType( + CompleteStructType&& x) noexcept + { + m_struct_flags = std::move(x.m_struct_flags); + m_header = std::move(x.m_header); + m_member_seq = std::move(x.m_member_seq); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object CompleteStructType that will be copied. + */ + eProsima_user_DllExport CompleteStructType& operator =( + const CompleteStructType& x) + { + + m_struct_flags = x.m_struct_flags; + + m_header = x.m_header; + + m_member_seq = x.m_member_seq; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object CompleteStructType that will be copied. + */ + eProsima_user_DllExport CompleteStructType& operator =( + CompleteStructType&& x) noexcept + { + + m_struct_flags = std::move(x.m_struct_flags); + m_header = std::move(x.m_header); + m_member_seq = std::move(x.m_member_seq); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x CompleteStructType object to compare. + */ + eProsima_user_DllExport bool operator ==( + const CompleteStructType& x) const + { + return (m_struct_flags == x.m_struct_flags && + m_header == x.m_header && + m_member_seq == x.m_member_seq); + } + + /*! + * @brief Comparison operator. + * @param x CompleteStructType object to compare. + */ + eProsima_user_DllExport bool operator !=( + const CompleteStructType& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member struct_flags + * @param _struct_flags New value to be copied in member struct_flags + */ + eProsima_user_DllExport void struct_flags( + const StructTypeFlag& _struct_flags) + { + m_struct_flags = _struct_flags; + } + + /*! + * @brief This function moves the value in member struct_flags + * @param _struct_flags New value to be moved in member struct_flags + */ + eProsima_user_DllExport void struct_flags( + StructTypeFlag&& _struct_flags) + { + m_struct_flags = std::move(_struct_flags); + } + + /*! + * @brief This function returns a constant reference to member struct_flags + * @return Constant reference to member struct_flags + */ + eProsima_user_DllExport const StructTypeFlag& struct_flags() const + { + return m_struct_flags; + } + + /*! + * @brief This function returns a reference to member struct_flags + * @return Reference to member struct_flags + */ + eProsima_user_DllExport StructTypeFlag& struct_flags() + { + return m_struct_flags; + } + + + /*! + * @brief This function copies the value in member header + * @param _header New value to be copied in member header + */ + eProsima_user_DllExport void header( + const CompleteStructHeader& _header) + { + m_header = _header; + } + + /*! + * @brief This function moves the value in member header + * @param _header New value to be moved in member header + */ + eProsima_user_DllExport void header( + CompleteStructHeader&& _header) + { + m_header = std::move(_header); + } + + /*! + * @brief This function returns a constant reference to member header + * @return Constant reference to member header + */ + eProsima_user_DllExport const CompleteStructHeader& header() const + { + return m_header; + } + + /*! + * @brief This function returns a reference to member header + * @return Reference to member header + */ + eProsima_user_DllExport CompleteStructHeader& header() + { + return m_header; + } + + + /*! + * @brief This function copies the value in member member_seq + * @param _member_seq New value to be copied in member member_seq + */ + eProsima_user_DllExport void member_seq( + const CompleteStructMemberSeq& _member_seq) + { + m_member_seq = _member_seq; + } + + /*! + * @brief This function moves the value in member member_seq + * @param _member_seq New value to be moved in member member_seq + */ + eProsima_user_DllExport void member_seq( + CompleteStructMemberSeq&& _member_seq) + { + m_member_seq = std::move(_member_seq); + } + + /*! + * @brief This function returns a constant reference to member member_seq + * @return Constant reference to member member_seq + */ + eProsima_user_DllExport const CompleteStructMemberSeq& member_seq() const + { + return m_member_seq; + } + + /*! + * @brief This function returns a reference to member member_seq + * @return Reference to member member_seq + */ + eProsima_user_DllExport CompleteStructMemberSeq& member_seq() + { + return m_member_seq; + } + + + +private: + + StructTypeFlag m_struct_flags{0}; + CompleteStructHeader m_header; + CompleteStructMemberSeq m_member_seq; + +}; +/*! + * @brief This class represents the structure MinimalStructType defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalStructType +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport MinimalStructType() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~MinimalStructType() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object MinimalStructType that will be copied. + */ + eProsima_user_DllExport MinimalStructType( + const MinimalStructType& x) + { + m_struct_flags = x.m_struct_flags; + + m_header = x.m_header; + + m_member_seq = x.m_member_seq; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object MinimalStructType that will be copied. + */ + eProsima_user_DllExport MinimalStructType( + MinimalStructType&& x) noexcept + { + m_struct_flags = std::move(x.m_struct_flags); + m_header = std::move(x.m_header); + m_member_seq = std::move(x.m_member_seq); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object MinimalStructType that will be copied. + */ + eProsima_user_DllExport MinimalStructType& operator =( + const MinimalStructType& x) + { + + m_struct_flags = x.m_struct_flags; + + m_header = x.m_header; + + m_member_seq = x.m_member_seq; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object MinimalStructType that will be copied. + */ + eProsima_user_DllExport MinimalStructType& operator =( + MinimalStructType&& x) noexcept + { + + m_struct_flags = std::move(x.m_struct_flags); + m_header = std::move(x.m_header); + m_member_seq = std::move(x.m_member_seq); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x MinimalStructType object to compare. + */ + eProsima_user_DllExport bool operator ==( + const MinimalStructType& x) const + { + return (m_struct_flags == x.m_struct_flags && + m_header == x.m_header && + m_member_seq == x.m_member_seq); + } + + /*! + * @brief Comparison operator. + * @param x MinimalStructType object to compare. + */ + eProsima_user_DllExport bool operator !=( + const MinimalStructType& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member struct_flags + * @param _struct_flags New value to be copied in member struct_flags + */ + eProsima_user_DllExport void struct_flags( + const StructTypeFlag& _struct_flags) + { + m_struct_flags = _struct_flags; + } + + /*! + * @brief This function moves the value in member struct_flags + * @param _struct_flags New value to be moved in member struct_flags + */ + eProsima_user_DllExport void struct_flags( + StructTypeFlag&& _struct_flags) + { + m_struct_flags = std::move(_struct_flags); + } + + /*! + * @brief This function returns a constant reference to member struct_flags + * @return Constant reference to member struct_flags + */ + eProsima_user_DllExport const StructTypeFlag& struct_flags() const + { + return m_struct_flags; + } + + /*! + * @brief This function returns a reference to member struct_flags + * @return Reference to member struct_flags + */ + eProsima_user_DllExport StructTypeFlag& struct_flags() + { + return m_struct_flags; + } + + + /*! + * @brief This function copies the value in member header + * @param _header New value to be copied in member header + */ + eProsima_user_DllExport void header( + const MinimalStructHeader& _header) + { + m_header = _header; + } + + /*! + * @brief This function moves the value in member header + * @param _header New value to be moved in member header + */ + eProsima_user_DllExport void header( + MinimalStructHeader&& _header) + { + m_header = std::move(_header); + } + + /*! + * @brief This function returns a constant reference to member header + * @return Constant reference to member header + */ + eProsima_user_DllExport const MinimalStructHeader& header() const + { + return m_header; + } + + /*! + * @brief This function returns a reference to member header + * @return Reference to member header + */ + eProsima_user_DllExport MinimalStructHeader& header() + { + return m_header; + } + + + /*! + * @brief This function copies the value in member member_seq + * @param _member_seq New value to be copied in member member_seq + */ + eProsima_user_DllExport void member_seq( + const MinimalStructMemberSeq& _member_seq) + { + m_member_seq = _member_seq; + } + + /*! + * @brief This function moves the value in member member_seq + * @param _member_seq New value to be moved in member member_seq + */ + eProsima_user_DllExport void member_seq( + MinimalStructMemberSeq&& _member_seq) + { + m_member_seq = std::move(_member_seq); + } + + /*! + * @brief This function returns a constant reference to member member_seq + * @return Constant reference to member member_seq + */ + eProsima_user_DllExport const MinimalStructMemberSeq& member_seq() const + { + return m_member_seq; + } + + /*! + * @brief This function returns a reference to member member_seq + * @return Reference to member member_seq + */ + eProsima_user_DllExport MinimalStructMemberSeq& member_seq() + { + return m_member_seq; + } + + + +private: + + StructTypeFlag m_struct_flags{0}; + MinimalStructHeader m_header; + MinimalStructMemberSeq m_member_seq; + +}; +typedef std::vector UnionCaseLabelSeq; + +/*! + * @brief This class represents the structure CommonUnionMember defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CommonUnionMember +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport CommonUnionMember() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~CommonUnionMember() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object CommonUnionMember that will be copied. + */ + eProsima_user_DllExport CommonUnionMember( + const CommonUnionMember& x) + { + m_member_id = x.m_member_id; + + m_member_flags = x.m_member_flags; + + m_type_id = x.m_type_id; + + m_label_seq = x.m_label_seq; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object CommonUnionMember that will be copied. + */ + eProsima_user_DllExport CommonUnionMember( + CommonUnionMember&& x) noexcept + { + m_member_id = x.m_member_id; + m_member_flags = std::move(x.m_member_flags); + m_type_id = std::move(x.m_type_id); + m_label_seq = std::move(x.m_label_seq); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object CommonUnionMember that will be copied. + */ + eProsima_user_DllExport CommonUnionMember& operator =( + const CommonUnionMember& x) + { + + m_member_id = x.m_member_id; + + m_member_flags = x.m_member_flags; + + m_type_id = x.m_type_id; + + m_label_seq = x.m_label_seq; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object CommonUnionMember that will be copied. + */ + eProsima_user_DllExport CommonUnionMember& operator =( + CommonUnionMember&& x) noexcept + { + + m_member_id = x.m_member_id; + m_member_flags = std::move(x.m_member_flags); + m_type_id = std::move(x.m_type_id); + m_label_seq = std::move(x.m_label_seq); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x CommonUnionMember object to compare. + */ + eProsima_user_DllExport bool operator ==( + const CommonUnionMember& x) const + { + return (m_member_id == x.m_member_id && + m_member_flags == x.m_member_flags && + m_type_id == x.m_type_id && + m_label_seq == x.m_label_seq); + } + + /*! + * @brief Comparison operator. + * @param x CommonUnionMember object to compare. + */ + eProsima_user_DllExport bool operator !=( + const CommonUnionMember& x) const + { + return !(*this == x); + } + + /*! + * @brief This function sets a value in member member_id + * @param _member_id New value for member member_id + */ + eProsima_user_DllExport void member_id( + MemberId _member_id) + { + m_member_id = _member_id; + } + + /*! + * @brief This function returns the value of member member_id + * @return Value of member member_id + */ + eProsima_user_DllExport MemberId member_id() const + { + return m_member_id; + } + + /*! + * @brief This function returns a reference to member member_id + * @return Reference to member member_id + */ + eProsima_user_DllExport MemberId& member_id() + { + return m_member_id; + } + + + /*! + * @brief This function copies the value in member member_flags + * @param _member_flags New value to be copied in member member_flags + */ + eProsima_user_DllExport void member_flags( + const UnionMemberFlag& _member_flags) + { + m_member_flags = _member_flags; + } + + /*! + * @brief This function moves the value in member member_flags + * @param _member_flags New value to be moved in member member_flags + */ + eProsima_user_DllExport void member_flags( + UnionMemberFlag&& _member_flags) + { + m_member_flags = std::move(_member_flags); + } + + /*! + * @brief This function returns a constant reference to member member_flags + * @return Constant reference to member member_flags + */ + eProsima_user_DllExport const UnionMemberFlag& member_flags() const + { + return m_member_flags; + } + + /*! + * @brief This function returns a reference to member member_flags + * @return Reference to member member_flags + */ + eProsima_user_DllExport UnionMemberFlag& member_flags() + { + return m_member_flags; + } + + + /*! + * @brief This function copies the value in member type_id + * @param _type_id New value to be copied in member type_id + */ + eProsima_user_DllExport void type_id( + const TypeIdentifier& _type_id) + { + m_type_id = _type_id; + } + + /*! + * @brief This function moves the value in member type_id + * @param _type_id New value to be moved in member type_id + */ + eProsima_user_DllExport void type_id( + TypeIdentifier&& _type_id) + { + m_type_id = std::move(_type_id); + } + + /*! + * @brief This function returns a constant reference to member type_id + * @return Constant reference to member type_id + */ + eProsima_user_DllExport const TypeIdentifier& type_id() const + { + return m_type_id; + } + + /*! + * @brief This function returns a reference to member type_id + * @return Reference to member type_id + */ + eProsima_user_DllExport TypeIdentifier& type_id() + { + return m_type_id; + } + + + /*! + * @brief This function copies the value in member label_seq + * @param _label_seq New value to be copied in member label_seq + */ + eProsima_user_DllExport void label_seq( + const UnionCaseLabelSeq& _label_seq) + { + m_label_seq = _label_seq; + } + + /*! + * @brief This function moves the value in member label_seq + * @param _label_seq New value to be moved in member label_seq + */ + eProsima_user_DllExport void label_seq( + UnionCaseLabelSeq&& _label_seq) + { + m_label_seq = std::move(_label_seq); + } + + /*! + * @brief This function returns a constant reference to member label_seq + * @return Constant reference to member label_seq + */ + eProsima_user_DllExport const UnionCaseLabelSeq& label_seq() const + { + return m_label_seq; + } + + /*! + * @brief This function returns a reference to member label_seq + * @return Reference to member label_seq + */ + eProsima_user_DllExport UnionCaseLabelSeq& label_seq() + { + return m_label_seq; + } + + + +private: + + MemberId m_member_id{0}; + UnionMemberFlag m_member_flags{0}; + TypeIdentifier m_type_id; + UnionCaseLabelSeq m_label_seq; + +}; +/*! + * @brief This class represents the structure CompleteUnionMember defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteUnionMember +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport CompleteUnionMember() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~CompleteUnionMember() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object CompleteUnionMember that will be copied. + */ + eProsima_user_DllExport CompleteUnionMember( + const CompleteUnionMember& x) + { + m_common = x.m_common; + + m_detail = x.m_detail; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object CompleteUnionMember that will be copied. + */ + eProsima_user_DllExport CompleteUnionMember( + CompleteUnionMember&& x) noexcept + { + m_common = std::move(x.m_common); + m_detail = std::move(x.m_detail); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object CompleteUnionMember that will be copied. + */ + eProsima_user_DllExport CompleteUnionMember& operator =( + const CompleteUnionMember& x) + { + + m_common = x.m_common; + + m_detail = x.m_detail; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object CompleteUnionMember that will be copied. + */ + eProsima_user_DllExport CompleteUnionMember& operator =( + CompleteUnionMember&& x) noexcept + { + + m_common = std::move(x.m_common); + m_detail = std::move(x.m_detail); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x CompleteUnionMember object to compare. + */ + eProsima_user_DllExport bool operator ==( + const CompleteUnionMember& x) const + { + return (m_common == x.m_common && + m_detail == x.m_detail); + } + + /*! + * @brief Comparison operator. + * @param x CompleteUnionMember object to compare. + */ + eProsima_user_DllExport bool operator !=( + const CompleteUnionMember& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member common + * @param _common New value to be copied in member common + */ + eProsima_user_DllExport void common( + const CommonUnionMember& _common) + { + m_common = _common; + } + + /*! + * @brief This function moves the value in member common + * @param _common New value to be moved in member common + */ + eProsima_user_DllExport void common( + CommonUnionMember&& _common) + { + m_common = std::move(_common); + } + + /*! + * @brief This function returns a constant reference to member common + * @return Constant reference to member common + */ + eProsima_user_DllExport const CommonUnionMember& common() const + { + return m_common; + } + + /*! + * @brief This function returns a reference to member common + * @return Reference to member common + */ + eProsima_user_DllExport CommonUnionMember& common() + { + return m_common; + } + + + /*! + * @brief This function copies the value in member detail + * @param _detail New value to be copied in member detail + */ + eProsima_user_DllExport void detail( + const CompleteMemberDetail& _detail) + { + m_detail = _detail; + } + + /*! + * @brief This function moves the value in member detail + * @param _detail New value to be moved in member detail + */ + eProsima_user_DllExport void detail( + CompleteMemberDetail&& _detail) + { + m_detail = std::move(_detail); + } + + /*! + * @brief This function returns a constant reference to member detail + * @return Constant reference to member detail + */ + eProsima_user_DllExport const CompleteMemberDetail& detail() const + { + return m_detail; + } + + /*! + * @brief This function returns a reference to member detail + * @return Reference to member detail + */ + eProsima_user_DllExport CompleteMemberDetail& detail() + { + return m_detail; + } + + + +private: + + CommonUnionMember m_common; + CompleteMemberDetail m_detail; + +}; +typedef std::vector CompleteUnionMemberSeq; + +/*! + * @brief This class represents the structure MinimalUnionMember defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalUnionMember +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport MinimalUnionMember() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~MinimalUnionMember() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object MinimalUnionMember that will be copied. + */ + eProsima_user_DllExport MinimalUnionMember( + const MinimalUnionMember& x) + { + m_common = x.m_common; + + m_detail = x.m_detail; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object MinimalUnionMember that will be copied. + */ + eProsima_user_DllExport MinimalUnionMember( + MinimalUnionMember&& x) noexcept + { + m_common = std::move(x.m_common); + m_detail = std::move(x.m_detail); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object MinimalUnionMember that will be copied. + */ + eProsima_user_DllExport MinimalUnionMember& operator =( + const MinimalUnionMember& x) + { + + m_common = x.m_common; + + m_detail = x.m_detail; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object MinimalUnionMember that will be copied. + */ + eProsima_user_DllExport MinimalUnionMember& operator =( + MinimalUnionMember&& x) noexcept + { + + m_common = std::move(x.m_common); + m_detail = std::move(x.m_detail); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x MinimalUnionMember object to compare. + */ + eProsima_user_DllExport bool operator ==( + const MinimalUnionMember& x) const + { + return (m_common == x.m_common && + m_detail == x.m_detail); + } + + /*! + * @brief Comparison operator. + * @param x MinimalUnionMember object to compare. + */ + eProsima_user_DllExport bool operator !=( + const MinimalUnionMember& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member common + * @param _common New value to be copied in member common + */ + eProsima_user_DllExport void common( + const CommonUnionMember& _common) + { + m_common = _common; + } + + /*! + * @brief This function moves the value in member common + * @param _common New value to be moved in member common + */ + eProsima_user_DllExport void common( + CommonUnionMember&& _common) + { + m_common = std::move(_common); + } + + /*! + * @brief This function returns a constant reference to member common + * @return Constant reference to member common + */ + eProsima_user_DllExport const CommonUnionMember& common() const + { + return m_common; + } + + /*! + * @brief This function returns a reference to member common + * @return Reference to member common + */ + eProsima_user_DllExport CommonUnionMember& common() + { + return m_common; + } + + + /*! + * @brief This function copies the value in member detail + * @param _detail New value to be copied in member detail + */ + eProsima_user_DllExport void detail( + const MinimalMemberDetail& _detail) + { + m_detail = _detail; + } + + /*! + * @brief This function moves the value in member detail + * @param _detail New value to be moved in member detail + */ + eProsima_user_DllExport void detail( + MinimalMemberDetail&& _detail) + { + m_detail = std::move(_detail); + } + + /*! + * @brief This function returns a constant reference to member detail + * @return Constant reference to member detail + */ + eProsima_user_DllExport const MinimalMemberDetail& detail() const + { + return m_detail; + } + + /*! + * @brief This function returns a reference to member detail + * @return Reference to member detail + */ + eProsima_user_DllExport MinimalMemberDetail& detail() + { + return m_detail; + } + + + +private: + + CommonUnionMember m_common; + MinimalMemberDetail m_detail; + +}; +typedef std::vector MinimalUnionMemberSeq; + +/*! + * @brief This class represents the structure CommonDiscriminatorMember defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CommonDiscriminatorMember +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport CommonDiscriminatorMember() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~CommonDiscriminatorMember() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object CommonDiscriminatorMember that will be copied. + */ + eProsima_user_DllExport CommonDiscriminatorMember( + const CommonDiscriminatorMember& x) + { + m_member_flags = x.m_member_flags; + + m_type_id = x.m_type_id; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object CommonDiscriminatorMember that will be copied. + */ + eProsima_user_DllExport CommonDiscriminatorMember( + CommonDiscriminatorMember&& x) noexcept + { + m_member_flags = std::move(x.m_member_flags); + m_type_id = std::move(x.m_type_id); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object CommonDiscriminatorMember that will be copied. + */ + eProsima_user_DllExport CommonDiscriminatorMember& operator =( + const CommonDiscriminatorMember& x) + { + + m_member_flags = x.m_member_flags; + + m_type_id = x.m_type_id; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object CommonDiscriminatorMember that will be copied. + */ + eProsima_user_DllExport CommonDiscriminatorMember& operator =( + CommonDiscriminatorMember&& x) noexcept + { + + m_member_flags = std::move(x.m_member_flags); + m_type_id = std::move(x.m_type_id); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x CommonDiscriminatorMember object to compare. + */ + eProsima_user_DllExport bool operator ==( + const CommonDiscriminatorMember& x) const + { + return (m_member_flags == x.m_member_flags && + m_type_id == x.m_type_id); + } + + /*! + * @brief Comparison operator. + * @param x CommonDiscriminatorMember object to compare. + */ + eProsima_user_DllExport bool operator !=( + const CommonDiscriminatorMember& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member member_flags + * @param _member_flags New value to be copied in member member_flags + */ + eProsima_user_DllExport void member_flags( + const UnionDiscriminatorFlag& _member_flags) + { + m_member_flags = _member_flags; + } + + /*! + * @brief This function moves the value in member member_flags + * @param _member_flags New value to be moved in member member_flags + */ + eProsima_user_DllExport void member_flags( + UnionDiscriminatorFlag&& _member_flags) + { + m_member_flags = std::move(_member_flags); + } + + /*! + * @brief This function returns a constant reference to member member_flags + * @return Constant reference to member member_flags + */ + eProsima_user_DllExport const UnionDiscriminatorFlag& member_flags() const + { + return m_member_flags; + } + + /*! + * @brief This function returns a reference to member member_flags + * @return Reference to member member_flags + */ + eProsima_user_DllExport UnionDiscriminatorFlag& member_flags() + { + return m_member_flags; + } + + + /*! + * @brief This function copies the value in member type_id + * @param _type_id New value to be copied in member type_id + */ + eProsima_user_DllExport void type_id( + const TypeIdentifier& _type_id) + { + m_type_id = _type_id; + } + + /*! + * @brief This function moves the value in member type_id + * @param _type_id New value to be moved in member type_id + */ + eProsima_user_DllExport void type_id( + TypeIdentifier&& _type_id) + { + m_type_id = std::move(_type_id); + } + + /*! + * @brief This function returns a constant reference to member type_id + * @return Constant reference to member type_id + */ + eProsima_user_DllExport const TypeIdentifier& type_id() const + { + return m_type_id; + } + + /*! + * @brief This function returns a reference to member type_id + * @return Reference to member type_id + */ + eProsima_user_DllExport TypeIdentifier& type_id() + { + return m_type_id; + } + + + +private: + + UnionDiscriminatorFlag m_member_flags{0}; + TypeIdentifier m_type_id; + +}; +/*! + * @brief This class represents the structure CompleteDiscriminatorMember defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteDiscriminatorMember +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport CompleteDiscriminatorMember() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~CompleteDiscriminatorMember() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object CompleteDiscriminatorMember that will be copied. + */ + eProsima_user_DllExport CompleteDiscriminatorMember( + const CompleteDiscriminatorMember& x) + { + m_common = x.m_common; + + m_ann_builtin = x.m_ann_builtin; + + m_ann_custom = x.m_ann_custom; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object CompleteDiscriminatorMember that will be copied. + */ + eProsima_user_DllExport CompleteDiscriminatorMember( + CompleteDiscriminatorMember&& x) noexcept + { + m_common = std::move(x.m_common); + m_ann_builtin = std::move(x.m_ann_builtin); + m_ann_custom = std::move(x.m_ann_custom); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object CompleteDiscriminatorMember that will be copied. + */ + eProsima_user_DllExport CompleteDiscriminatorMember& operator =( + const CompleteDiscriminatorMember& x) + { + + m_common = x.m_common; + + m_ann_builtin = x.m_ann_builtin; + + m_ann_custom = x.m_ann_custom; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object CompleteDiscriminatorMember that will be copied. + */ + eProsima_user_DllExport CompleteDiscriminatorMember& operator =( + CompleteDiscriminatorMember&& x) noexcept + { + + m_common = std::move(x.m_common); + m_ann_builtin = std::move(x.m_ann_builtin); + m_ann_custom = std::move(x.m_ann_custom); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x CompleteDiscriminatorMember object to compare. + */ + eProsima_user_DllExport bool operator ==( + const CompleteDiscriminatorMember& x) const + { + return (m_common == x.m_common && + m_ann_builtin == x.m_ann_builtin && + m_ann_custom == x.m_ann_custom); + } + + /*! + * @brief Comparison operator. + * @param x CompleteDiscriminatorMember object to compare. + */ + eProsima_user_DllExport bool operator !=( + const CompleteDiscriminatorMember& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member common + * @param _common New value to be copied in member common + */ + eProsima_user_DllExport void common( + const CommonDiscriminatorMember& _common) + { + m_common = _common; + } + + /*! + * @brief This function moves the value in member common + * @param _common New value to be moved in member common + */ + eProsima_user_DllExport void common( + CommonDiscriminatorMember&& _common) + { + m_common = std::move(_common); + } + + /*! + * @brief This function returns a constant reference to member common + * @return Constant reference to member common + */ + eProsima_user_DllExport const CommonDiscriminatorMember& common() const + { + return m_common; + } + + /*! + * @brief This function returns a reference to member common + * @return Reference to member common + */ + eProsima_user_DllExport CommonDiscriminatorMember& common() + { + return m_common; + } + + + /*! + * @brief This function copies the value in member ann_builtin + * @param _ann_builtin New value to be copied in member ann_builtin + */ + eProsima_user_DllExport void ann_builtin( + const eprosima::fastcdr::optional& _ann_builtin) + { + m_ann_builtin = _ann_builtin; + } + + /*! + * @brief This function moves the value in member ann_builtin + * @param _ann_builtin New value to be moved in member ann_builtin + */ + eProsima_user_DllExport void ann_builtin( + eprosima::fastcdr::optional&& _ann_builtin) + { + m_ann_builtin = std::move(_ann_builtin); + } + + /*! + * @brief This function returns a constant reference to member ann_builtin + * @return Constant reference to member ann_builtin + */ + eProsima_user_DllExport const eprosima::fastcdr::optional& ann_builtin() const + { + return m_ann_builtin; + } + + /*! + * @brief This function returns a reference to member ann_builtin + * @return Reference to member ann_builtin + */ + eProsima_user_DllExport eprosima::fastcdr::optional& ann_builtin() + { + return m_ann_builtin; + } + + + /*! + * @brief This function copies the value in member ann_custom + * @param _ann_custom New value to be copied in member ann_custom + */ + eProsima_user_DllExport void ann_custom( + const eprosima::fastcdr::optional& _ann_custom) + { + m_ann_custom = _ann_custom; + } + + /*! + * @brief This function moves the value in member ann_custom + * @param _ann_custom New value to be moved in member ann_custom + */ + eProsima_user_DllExport void ann_custom( + eprosima::fastcdr::optional&& _ann_custom) + { + m_ann_custom = std::move(_ann_custom); + } + + /*! + * @brief This function returns a constant reference to member ann_custom + * @return Constant reference to member ann_custom + */ + eProsima_user_DllExport const eprosima::fastcdr::optional& ann_custom() const + { + return m_ann_custom; + } + + /*! + * @brief This function returns a reference to member ann_custom + * @return Reference to member ann_custom + */ + eProsima_user_DllExport eprosima::fastcdr::optional& ann_custom() + { + return m_ann_custom; + } + + + +private: + + CommonDiscriminatorMember m_common; + eprosima::fastcdr::optional m_ann_builtin; + eprosima::fastcdr::optional m_ann_custom; + +}; +/*! + * @brief This class represents the structure MinimalDiscriminatorMember defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalDiscriminatorMember +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport MinimalDiscriminatorMember() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~MinimalDiscriminatorMember() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object MinimalDiscriminatorMember that will be copied. + */ + eProsima_user_DllExport MinimalDiscriminatorMember( + const MinimalDiscriminatorMember& x) + { + m_common = x.m_common; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object MinimalDiscriminatorMember that will be copied. + */ + eProsima_user_DllExport MinimalDiscriminatorMember( + MinimalDiscriminatorMember&& x) noexcept + { + m_common = std::move(x.m_common); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object MinimalDiscriminatorMember that will be copied. + */ + eProsima_user_DllExport MinimalDiscriminatorMember& operator =( + const MinimalDiscriminatorMember& x) + { + + m_common = x.m_common; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object MinimalDiscriminatorMember that will be copied. + */ + eProsima_user_DllExport MinimalDiscriminatorMember& operator =( + MinimalDiscriminatorMember&& x) noexcept + { + + m_common = std::move(x.m_common); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x MinimalDiscriminatorMember object to compare. + */ + eProsima_user_DllExport bool operator ==( + const MinimalDiscriminatorMember& x) const + { + return (m_common == x.m_common); + } + + /*! + * @brief Comparison operator. + * @param x MinimalDiscriminatorMember object to compare. + */ + eProsima_user_DllExport bool operator !=( + const MinimalDiscriminatorMember& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member common + * @param _common New value to be copied in member common + */ + eProsima_user_DllExport void common( + const CommonDiscriminatorMember& _common) + { + m_common = _common; + } + + /*! + * @brief This function moves the value in member common + * @param _common New value to be moved in member common + */ + eProsima_user_DllExport void common( + CommonDiscriminatorMember&& _common) + { + m_common = std::move(_common); + } + + /*! + * @brief This function returns a constant reference to member common + * @return Constant reference to member common + */ + eProsima_user_DllExport const CommonDiscriminatorMember& common() const + { + return m_common; + } + + /*! + * @brief This function returns a reference to member common + * @return Reference to member common + */ + eProsima_user_DllExport CommonDiscriminatorMember& common() + { + return m_common; + } + + + +private: + + CommonDiscriminatorMember m_common; + +}; +/*! + * @brief This class represents the structure CompleteUnionHeader defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteUnionHeader +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport CompleteUnionHeader() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~CompleteUnionHeader() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object CompleteUnionHeader that will be copied. + */ + eProsima_user_DllExport CompleteUnionHeader( + const CompleteUnionHeader& x) + { + m_detail = x.m_detail; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object CompleteUnionHeader that will be copied. + */ + eProsima_user_DllExport CompleteUnionHeader( + CompleteUnionHeader&& x) noexcept + { + m_detail = std::move(x.m_detail); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object CompleteUnionHeader that will be copied. + */ + eProsima_user_DllExport CompleteUnionHeader& operator =( + const CompleteUnionHeader& x) + { + + m_detail = x.m_detail; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object CompleteUnionHeader that will be copied. + */ + eProsima_user_DllExport CompleteUnionHeader& operator =( + CompleteUnionHeader&& x) noexcept + { + + m_detail = std::move(x.m_detail); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x CompleteUnionHeader object to compare. + */ + eProsima_user_DllExport bool operator ==( + const CompleteUnionHeader& x) const + { + return (m_detail == x.m_detail); + } + + /*! + * @brief Comparison operator. + * @param x CompleteUnionHeader object to compare. + */ + eProsima_user_DllExport bool operator !=( + const CompleteUnionHeader& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member detail + * @param _detail New value to be copied in member detail + */ + eProsima_user_DllExport void detail( + const CompleteTypeDetail& _detail) + { + m_detail = _detail; + } + + /*! + * @brief This function moves the value in member detail + * @param _detail New value to be moved in member detail + */ + eProsima_user_DllExport void detail( + CompleteTypeDetail&& _detail) + { + m_detail = std::move(_detail); + } + + /*! + * @brief This function returns a constant reference to member detail + * @return Constant reference to member detail + */ + eProsima_user_DllExport const CompleteTypeDetail& detail() const + { + return m_detail; + } + + /*! + * @brief This function returns a reference to member detail + * @return Reference to member detail + */ + eProsima_user_DllExport CompleteTypeDetail& detail() + { + return m_detail; + } + + + +private: + + CompleteTypeDetail m_detail; + +}; +/*! + * @brief This class represents the structure MinimalUnionHeader defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalUnionHeader +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport MinimalUnionHeader() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~MinimalUnionHeader() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object MinimalUnionHeader that will be copied. + */ + eProsima_user_DllExport MinimalUnionHeader( + const MinimalUnionHeader& x) + { + m_detail = x.m_detail; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object MinimalUnionHeader that will be copied. + */ + eProsima_user_DllExport MinimalUnionHeader( + MinimalUnionHeader&& x) noexcept + { + m_detail = std::move(x.m_detail); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object MinimalUnionHeader that will be copied. + */ + eProsima_user_DllExport MinimalUnionHeader& operator =( + const MinimalUnionHeader& x) + { + + m_detail = x.m_detail; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object MinimalUnionHeader that will be copied. + */ + eProsima_user_DllExport MinimalUnionHeader& operator =( + MinimalUnionHeader&& x) noexcept + { + + m_detail = std::move(x.m_detail); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x MinimalUnionHeader object to compare. + */ + eProsima_user_DllExport bool operator ==( + const MinimalUnionHeader& x) const + { + return (m_detail == x.m_detail); + } + + /*! + * @brief Comparison operator. + * @param x MinimalUnionHeader object to compare. + */ + eProsima_user_DllExport bool operator !=( + const MinimalUnionHeader& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member detail + * @param _detail New value to be copied in member detail + */ + eProsima_user_DllExport void detail( + const MinimalTypeDetail& _detail) + { + m_detail = _detail; + } + + /*! + * @brief This function moves the value in member detail + * @param _detail New value to be moved in member detail + */ + eProsima_user_DllExport void detail( + MinimalTypeDetail&& _detail) + { + m_detail = std::move(_detail); + } + + /*! + * @brief This function returns a constant reference to member detail + * @return Constant reference to member detail + */ + eProsima_user_DllExport const MinimalTypeDetail& detail() const + { + return m_detail; + } + + /*! + * @brief This function returns a reference to member detail + * @return Reference to member detail + */ + eProsima_user_DllExport MinimalTypeDetail& detail() + { + return m_detail; + } + + + +private: + + MinimalTypeDetail m_detail; + +}; +/*! + * @brief This class represents the structure CompleteUnionType defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteUnionType +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport CompleteUnionType() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~CompleteUnionType() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object CompleteUnionType that will be copied. + */ + eProsima_user_DllExport CompleteUnionType( + const CompleteUnionType& x) + { + m_union_flags = x.m_union_flags; + + m_header = x.m_header; + + m_discriminator = x.m_discriminator; + + m_member_seq = x.m_member_seq; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object CompleteUnionType that will be copied. + */ + eProsima_user_DllExport CompleteUnionType( + CompleteUnionType&& x) noexcept + { + m_union_flags = std::move(x.m_union_flags); + m_header = std::move(x.m_header); + m_discriminator = std::move(x.m_discriminator); + m_member_seq = std::move(x.m_member_seq); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object CompleteUnionType that will be copied. + */ + eProsima_user_DllExport CompleteUnionType& operator =( + const CompleteUnionType& x) + { + + m_union_flags = x.m_union_flags; + + m_header = x.m_header; + + m_discriminator = x.m_discriminator; + + m_member_seq = x.m_member_seq; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object CompleteUnionType that will be copied. + */ + eProsima_user_DllExport CompleteUnionType& operator =( + CompleteUnionType&& x) noexcept + { + + m_union_flags = std::move(x.m_union_flags); + m_header = std::move(x.m_header); + m_discriminator = std::move(x.m_discriminator); + m_member_seq = std::move(x.m_member_seq); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x CompleteUnionType object to compare. + */ + eProsima_user_DllExport bool operator ==( + const CompleteUnionType& x) const + { + return (m_union_flags == x.m_union_flags && + m_header == x.m_header && + m_discriminator == x.m_discriminator && + m_member_seq == x.m_member_seq); + } + + /*! + * @brief Comparison operator. + * @param x CompleteUnionType object to compare. + */ + eProsima_user_DllExport bool operator !=( + const CompleteUnionType& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member union_flags + * @param _union_flags New value to be copied in member union_flags + */ + eProsima_user_DllExport void union_flags( + const UnionTypeFlag& _union_flags) + { + m_union_flags = _union_flags; + } + + /*! + * @brief This function moves the value in member union_flags + * @param _union_flags New value to be moved in member union_flags + */ + eProsima_user_DllExport void union_flags( + UnionTypeFlag&& _union_flags) + { + m_union_flags = std::move(_union_flags); + } + + /*! + * @brief This function returns a constant reference to member union_flags + * @return Constant reference to member union_flags + */ + eProsima_user_DllExport const UnionTypeFlag& union_flags() const + { + return m_union_flags; + } + + /*! + * @brief This function returns a reference to member union_flags + * @return Reference to member union_flags + */ + eProsima_user_DllExport UnionTypeFlag& union_flags() + { + return m_union_flags; + } + + + /*! + * @brief This function copies the value in member header + * @param _header New value to be copied in member header + */ + eProsima_user_DllExport void header( + const CompleteUnionHeader& _header) + { + m_header = _header; + } + + /*! + * @brief This function moves the value in member header + * @param _header New value to be moved in member header + */ + eProsima_user_DllExport void header( + CompleteUnionHeader&& _header) + { + m_header = std::move(_header); + } + + /*! + * @brief This function returns a constant reference to member header + * @return Constant reference to member header + */ + eProsima_user_DllExport const CompleteUnionHeader& header() const + { + return m_header; + } + + /*! + * @brief This function returns a reference to member header + * @return Reference to member header + */ + eProsima_user_DllExport CompleteUnionHeader& header() + { + return m_header; + } + + + /*! + * @brief This function copies the value in member discriminator + * @param _discriminator New value to be copied in member discriminator + */ + eProsima_user_DllExport void discriminator( + const CompleteDiscriminatorMember& _discriminator) + { + m_discriminator = _discriminator; + } + + /*! + * @brief This function moves the value in member discriminator + * @param _discriminator New value to be moved in member discriminator + */ + eProsima_user_DllExport void discriminator( + CompleteDiscriminatorMember&& _discriminator) + { + m_discriminator = std::move(_discriminator); + } + + /*! + * @brief This function returns a constant reference to member discriminator + * @return Constant reference to member discriminator + */ + eProsima_user_DllExport const CompleteDiscriminatorMember& discriminator() const + { + return m_discriminator; + } + + /*! + * @brief This function returns a reference to member discriminator + * @return Reference to member discriminator + */ + eProsima_user_DllExport CompleteDiscriminatorMember& discriminator() + { + return m_discriminator; + } + + + /*! + * @brief This function copies the value in member member_seq + * @param _member_seq New value to be copied in member member_seq + */ + eProsima_user_DllExport void member_seq( + const CompleteUnionMemberSeq& _member_seq) + { + m_member_seq = _member_seq; + } + + /*! + * @brief This function moves the value in member member_seq + * @param _member_seq New value to be moved in member member_seq + */ + eProsima_user_DllExport void member_seq( + CompleteUnionMemberSeq&& _member_seq) + { + m_member_seq = std::move(_member_seq); + } + + /*! + * @brief This function returns a constant reference to member member_seq + * @return Constant reference to member member_seq + */ + eProsima_user_DllExport const CompleteUnionMemberSeq& member_seq() const + { + return m_member_seq; + } + + /*! + * @brief This function returns a reference to member member_seq + * @return Reference to member member_seq + */ + eProsima_user_DllExport CompleteUnionMemberSeq& member_seq() + { + return m_member_seq; + } + + + +private: + + UnionTypeFlag m_union_flags{0}; + CompleteUnionHeader m_header; + CompleteDiscriminatorMember m_discriminator; + CompleteUnionMemberSeq m_member_seq; + +}; +/*! + * @brief This class represents the structure MinimalUnionType defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalUnionType +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport MinimalUnionType() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~MinimalUnionType() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object MinimalUnionType that will be copied. + */ + eProsima_user_DllExport MinimalUnionType( + const MinimalUnionType& x) + { + m_union_flags = x.m_union_flags; + + m_header = x.m_header; + + m_discriminator = x.m_discriminator; + + m_member_seq = x.m_member_seq; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object MinimalUnionType that will be copied. + */ + eProsima_user_DllExport MinimalUnionType( + MinimalUnionType&& x) noexcept + { + m_union_flags = std::move(x.m_union_flags); + m_header = std::move(x.m_header); + m_discriminator = std::move(x.m_discriminator); + m_member_seq = std::move(x.m_member_seq); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object MinimalUnionType that will be copied. + */ + eProsima_user_DllExport MinimalUnionType& operator =( + const MinimalUnionType& x) + { + + m_union_flags = x.m_union_flags; + + m_header = x.m_header; + + m_discriminator = x.m_discriminator; + + m_member_seq = x.m_member_seq; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object MinimalUnionType that will be copied. + */ + eProsima_user_DllExport MinimalUnionType& operator =( + MinimalUnionType&& x) noexcept + { + + m_union_flags = std::move(x.m_union_flags); + m_header = std::move(x.m_header); + m_discriminator = std::move(x.m_discriminator); + m_member_seq = std::move(x.m_member_seq); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x MinimalUnionType object to compare. + */ + eProsima_user_DllExport bool operator ==( + const MinimalUnionType& x) const + { + return (m_union_flags == x.m_union_flags && + m_header == x.m_header && + m_discriminator == x.m_discriminator && + m_member_seq == x.m_member_seq); + } + + /*! + * @brief Comparison operator. + * @param x MinimalUnionType object to compare. + */ + eProsima_user_DllExport bool operator !=( + const MinimalUnionType& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member union_flags + * @param _union_flags New value to be copied in member union_flags + */ + eProsima_user_DllExport void union_flags( + const UnionTypeFlag& _union_flags) + { + m_union_flags = _union_flags; + } + + /*! + * @brief This function moves the value in member union_flags + * @param _union_flags New value to be moved in member union_flags + */ + eProsima_user_DllExport void union_flags( + UnionTypeFlag&& _union_flags) + { + m_union_flags = std::move(_union_flags); + } + + /*! + * @brief This function returns a constant reference to member union_flags + * @return Constant reference to member union_flags + */ + eProsima_user_DllExport const UnionTypeFlag& union_flags() const + { + return m_union_flags; + } + + /*! + * @brief This function returns a reference to member union_flags + * @return Reference to member union_flags + */ + eProsima_user_DllExport UnionTypeFlag& union_flags() + { + return m_union_flags; + } + + + /*! + * @brief This function copies the value in member header + * @param _header New value to be copied in member header + */ + eProsima_user_DllExport void header( + const MinimalUnionHeader& _header) + { + m_header = _header; + } + + /*! + * @brief This function moves the value in member header + * @param _header New value to be moved in member header + */ + eProsima_user_DllExport void header( + MinimalUnionHeader&& _header) + { + m_header = std::move(_header); + } + + /*! + * @brief This function returns a constant reference to member header + * @return Constant reference to member header + */ + eProsima_user_DllExport const MinimalUnionHeader& header() const + { + return m_header; + } + + /*! + * @brief This function returns a reference to member header + * @return Reference to member header + */ + eProsima_user_DllExport MinimalUnionHeader& header() + { + return m_header; + } + + + /*! + * @brief This function copies the value in member discriminator + * @param _discriminator New value to be copied in member discriminator + */ + eProsima_user_DllExport void discriminator( + const MinimalDiscriminatorMember& _discriminator) + { + m_discriminator = _discriminator; + } + + /*! + * @brief This function moves the value in member discriminator + * @param _discriminator New value to be moved in member discriminator + */ + eProsima_user_DllExport void discriminator( + MinimalDiscriminatorMember&& _discriminator) + { + m_discriminator = std::move(_discriminator); + } + + /*! + * @brief This function returns a constant reference to member discriminator + * @return Constant reference to member discriminator + */ + eProsima_user_DllExport const MinimalDiscriminatorMember& discriminator() const + { + return m_discriminator; + } + + /*! + * @brief This function returns a reference to member discriminator + * @return Reference to member discriminator + */ + eProsima_user_DllExport MinimalDiscriminatorMember& discriminator() + { + return m_discriminator; + } + + + /*! + * @brief This function copies the value in member member_seq + * @param _member_seq New value to be copied in member member_seq + */ + eProsima_user_DllExport void member_seq( + const MinimalUnionMemberSeq& _member_seq) + { + m_member_seq = _member_seq; + } + + /*! + * @brief This function moves the value in member member_seq + * @param _member_seq New value to be moved in member member_seq + */ + eProsima_user_DllExport void member_seq( + MinimalUnionMemberSeq&& _member_seq) + { + m_member_seq = std::move(_member_seq); + } + + /*! + * @brief This function returns a constant reference to member member_seq + * @return Constant reference to member member_seq + */ + eProsima_user_DllExport const MinimalUnionMemberSeq& member_seq() const + { + return m_member_seq; + } + + /*! + * @brief This function returns a reference to member member_seq + * @return Reference to member member_seq + */ + eProsima_user_DllExport MinimalUnionMemberSeq& member_seq() + { + return m_member_seq; + } + + + +private: + + UnionTypeFlag m_union_flags{0}; + MinimalUnionHeader m_header; + MinimalDiscriminatorMember m_discriminator; + MinimalUnionMemberSeq m_member_seq; + +}; +/*! + * @brief This class represents the structure CommonAnnotationParameter defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CommonAnnotationParameter +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport CommonAnnotationParameter() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~CommonAnnotationParameter() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object CommonAnnotationParameter that will be copied. + */ + eProsima_user_DllExport CommonAnnotationParameter( + const CommonAnnotationParameter& x) + { + m_member_flags = x.m_member_flags; + + m_member_type_id = x.m_member_type_id; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object CommonAnnotationParameter that will be copied. + */ + eProsima_user_DllExport CommonAnnotationParameter( + CommonAnnotationParameter&& x) noexcept + { + m_member_flags = std::move(x.m_member_flags); + m_member_type_id = std::move(x.m_member_type_id); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object CommonAnnotationParameter that will be copied. + */ + eProsima_user_DllExport CommonAnnotationParameter& operator =( + const CommonAnnotationParameter& x) + { + + m_member_flags = x.m_member_flags; + + m_member_type_id = x.m_member_type_id; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object CommonAnnotationParameter that will be copied. + */ + eProsima_user_DllExport CommonAnnotationParameter& operator =( + CommonAnnotationParameter&& x) noexcept + { + + m_member_flags = std::move(x.m_member_flags); + m_member_type_id = std::move(x.m_member_type_id); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x CommonAnnotationParameter object to compare. + */ + eProsima_user_DllExport bool operator ==( + const CommonAnnotationParameter& x) const + { + return (m_member_flags == x.m_member_flags && + m_member_type_id == x.m_member_type_id); + } + + /*! + * @brief Comparison operator. + * @param x CommonAnnotationParameter object to compare. + */ + eProsima_user_DllExport bool operator !=( + const CommonAnnotationParameter& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member member_flags + * @param _member_flags New value to be copied in member member_flags + */ + eProsima_user_DllExport void member_flags( + const AnnotationParameterFlag& _member_flags) + { + m_member_flags = _member_flags; + } + + /*! + * @brief This function moves the value in member member_flags + * @param _member_flags New value to be moved in member member_flags + */ + eProsima_user_DllExport void member_flags( + AnnotationParameterFlag&& _member_flags) + { + m_member_flags = std::move(_member_flags); + } + + /*! + * @brief This function returns a constant reference to member member_flags + * @return Constant reference to member member_flags + */ + eProsima_user_DllExport const AnnotationParameterFlag& member_flags() const + { + return m_member_flags; + } + + /*! + * @brief This function returns a reference to member member_flags + * @return Reference to member member_flags + */ + eProsima_user_DllExport AnnotationParameterFlag& member_flags() + { + return m_member_flags; + } + + + /*! + * @brief This function copies the value in member member_type_id + * @param _member_type_id New value to be copied in member member_type_id + */ + eProsima_user_DllExport void member_type_id( + const TypeIdentifier& _member_type_id) + { + m_member_type_id = _member_type_id; + } + + /*! + * @brief This function moves the value in member member_type_id + * @param _member_type_id New value to be moved in member member_type_id + */ + eProsima_user_DllExport void member_type_id( + TypeIdentifier&& _member_type_id) + { + m_member_type_id = std::move(_member_type_id); + } + + /*! + * @brief This function returns a constant reference to member member_type_id + * @return Constant reference to member member_type_id + */ + eProsima_user_DllExport const TypeIdentifier& member_type_id() const + { + return m_member_type_id; + } + + /*! + * @brief This function returns a reference to member member_type_id + * @return Reference to member member_type_id + */ + eProsima_user_DllExport TypeIdentifier& member_type_id() + { + return m_member_type_id; + } + + + +private: + + AnnotationParameterFlag m_member_flags{0}; + TypeIdentifier m_member_type_id; + +}; +/*! + * @brief This class represents the structure CompleteAnnotationParameter defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteAnnotationParameter +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport CompleteAnnotationParameter() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~CompleteAnnotationParameter() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object CompleteAnnotationParameter that will be copied. + */ + eProsima_user_DllExport CompleteAnnotationParameter( + const CompleteAnnotationParameter& x) + { + m_common = x.m_common; + + m_name = x.m_name; + + m_default_value = x.m_default_value; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object CompleteAnnotationParameter that will be copied. + */ + eProsima_user_DllExport CompleteAnnotationParameter( + CompleteAnnotationParameter&& x) noexcept + { + m_common = std::move(x.m_common); + m_name = std::move(x.m_name); + m_default_value = std::move(x.m_default_value); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object CompleteAnnotationParameter that will be copied. + */ + eProsima_user_DllExport CompleteAnnotationParameter& operator =( + const CompleteAnnotationParameter& x) + { + + m_common = x.m_common; + + m_name = x.m_name; + + m_default_value = x.m_default_value; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object CompleteAnnotationParameter that will be copied. + */ + eProsima_user_DllExport CompleteAnnotationParameter& operator =( + CompleteAnnotationParameter&& x) noexcept + { + + m_common = std::move(x.m_common); + m_name = std::move(x.m_name); + m_default_value = std::move(x.m_default_value); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x CompleteAnnotationParameter object to compare. + */ + eProsima_user_DllExport bool operator ==( + const CompleteAnnotationParameter& x) const + { + return (m_common == x.m_common && + m_name == x.m_name && + m_default_value == x.m_default_value); + } + + /*! + * @brief Comparison operator. + * @param x CompleteAnnotationParameter object to compare. + */ + eProsima_user_DllExport bool operator !=( + const CompleteAnnotationParameter& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member common + * @param _common New value to be copied in member common + */ + eProsima_user_DllExport void common( + const CommonAnnotationParameter& _common) + { + m_common = _common; + } + + /*! + * @brief This function moves the value in member common + * @param _common New value to be moved in member common + */ + eProsima_user_DllExport void common( + CommonAnnotationParameter&& _common) + { + m_common = std::move(_common); + } + + /*! + * @brief This function returns a constant reference to member common + * @return Constant reference to member common + */ + eProsima_user_DllExport const CommonAnnotationParameter& common() const + { + return m_common; + } + + /*! + * @brief This function returns a reference to member common + * @return Reference to member common + */ + eProsima_user_DllExport CommonAnnotationParameter& common() + { + return m_common; + } + + + /*! + * @brief This function copies the value in member name + * @param _name New value to be copied in member name + */ + eProsima_user_DllExport void name( + const MemberName& _name) + { + m_name = _name; + } + + /*! + * @brief This function moves the value in member name + * @param _name New value to be moved in member name + */ + eProsima_user_DllExport void name( + MemberName&& _name) + { + m_name = std::move(_name); + } + + /*! + * @brief This function returns a constant reference to member name + * @return Constant reference to member name + */ + eProsima_user_DllExport const MemberName& name() const + { + return m_name; + } + + /*! + * @brief This function returns a reference to member name + * @return Reference to member name + */ + eProsima_user_DllExport MemberName& name() + { + return m_name; + } + + + /*! + * @brief This function copies the value in member default_value + * @param _default_value New value to be copied in member default_value + */ + eProsima_user_DllExport void default_value( + const AnnotationParameterValue& _default_value) + { + m_default_value = _default_value; + } + + /*! + * @brief This function moves the value in member default_value + * @param _default_value New value to be moved in member default_value + */ + eProsima_user_DllExport void default_value( + AnnotationParameterValue&& _default_value) + { + m_default_value = std::move(_default_value); + } + + /*! + * @brief This function returns a constant reference to member default_value + * @return Constant reference to member default_value + */ + eProsima_user_DllExport const AnnotationParameterValue& default_value() const + { + return m_default_value; + } + + /*! + * @brief This function returns a reference to member default_value + * @return Reference to member default_value + */ + eProsima_user_DllExport AnnotationParameterValue& default_value() + { + return m_default_value; + } + + + +private: + + CommonAnnotationParameter m_common; + MemberName m_name; + AnnotationParameterValue m_default_value; + +}; +typedef std::vector CompleteAnnotationParameterSeq; + +/*! + * @brief This class represents the structure MinimalAnnotationParameter defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalAnnotationParameter +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport MinimalAnnotationParameter() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~MinimalAnnotationParameter() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object MinimalAnnotationParameter that will be copied. + */ + eProsima_user_DllExport MinimalAnnotationParameter( + const MinimalAnnotationParameter& x) + { + m_common = x.m_common; + + m_name_hash = x.m_name_hash; + + m_default_value = x.m_default_value; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object MinimalAnnotationParameter that will be copied. + */ + eProsima_user_DllExport MinimalAnnotationParameter( + MinimalAnnotationParameter&& x) noexcept + { + m_common = std::move(x.m_common); + m_name_hash = std::move(x.m_name_hash); + m_default_value = std::move(x.m_default_value); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object MinimalAnnotationParameter that will be copied. + */ + eProsima_user_DllExport MinimalAnnotationParameter& operator =( + const MinimalAnnotationParameter& x) + { + + m_common = x.m_common; + + m_name_hash = x.m_name_hash; + + m_default_value = x.m_default_value; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object MinimalAnnotationParameter that will be copied. + */ + eProsima_user_DllExport MinimalAnnotationParameter& operator =( + MinimalAnnotationParameter&& x) noexcept + { + + m_common = std::move(x.m_common); + m_name_hash = std::move(x.m_name_hash); + m_default_value = std::move(x.m_default_value); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x MinimalAnnotationParameter object to compare. + */ + eProsima_user_DllExport bool operator ==( + const MinimalAnnotationParameter& x) const + { + return (m_common == x.m_common && + m_name_hash == x.m_name_hash && + m_default_value == x.m_default_value); + } + + /*! + * @brief Comparison operator. + * @param x MinimalAnnotationParameter object to compare. + */ + eProsima_user_DllExport bool operator !=( + const MinimalAnnotationParameter& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member common + * @param _common New value to be copied in member common + */ + eProsima_user_DllExport void common( + const CommonAnnotationParameter& _common) + { + m_common = _common; + } + + /*! + * @brief This function moves the value in member common + * @param _common New value to be moved in member common + */ + eProsima_user_DllExport void common( + CommonAnnotationParameter&& _common) + { + m_common = std::move(_common); + } + + /*! + * @brief This function returns a constant reference to member common + * @return Constant reference to member common + */ + eProsima_user_DllExport const CommonAnnotationParameter& common() const + { + return m_common; + } + + /*! + * @brief This function returns a reference to member common + * @return Reference to member common + */ + eProsima_user_DllExport CommonAnnotationParameter& common() + { + return m_common; + } + + + /*! + * @brief This function copies the value in member name_hash + * @param _name_hash New value to be copied in member name_hash + */ + eProsima_user_DllExport void name_hash( + const NameHash& _name_hash) + { + m_name_hash = _name_hash; + } + + /*! + * @brief This function moves the value in member name_hash + * @param _name_hash New value to be moved in member name_hash + */ + eProsima_user_DllExport void name_hash( + NameHash&& _name_hash) + { + m_name_hash = std::move(_name_hash); + } + + /*! + * @brief This function returns a constant reference to member name_hash + * @return Constant reference to member name_hash + */ + eProsima_user_DllExport const NameHash& name_hash() const + { + return m_name_hash; + } + + /*! + * @brief This function returns a reference to member name_hash + * @return Reference to member name_hash + */ + eProsima_user_DllExport NameHash& name_hash() + { + return m_name_hash; + } + + + /*! + * @brief This function copies the value in member default_value + * @param _default_value New value to be copied in member default_value + */ + eProsima_user_DllExport void default_value( + const AnnotationParameterValue& _default_value) + { + m_default_value = _default_value; + } + + /*! + * @brief This function moves the value in member default_value + * @param _default_value New value to be moved in member default_value + */ + eProsima_user_DllExport void default_value( + AnnotationParameterValue&& _default_value) + { + m_default_value = std::move(_default_value); + } + + /*! + * @brief This function returns a constant reference to member default_value + * @return Constant reference to member default_value + */ + eProsima_user_DllExport const AnnotationParameterValue& default_value() const + { + return m_default_value; + } + + /*! + * @brief This function returns a reference to member default_value + * @return Reference to member default_value + */ + eProsima_user_DllExport AnnotationParameterValue& default_value() + { + return m_default_value; + } + + + +private: + + CommonAnnotationParameter m_common; + NameHash m_name_hash{0}; + AnnotationParameterValue m_default_value; + +}; +typedef std::vector MinimalAnnotationParameterSeq; + +/*! + * @brief This class represents the structure CompleteAnnotationHeader defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteAnnotationHeader +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport CompleteAnnotationHeader() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~CompleteAnnotationHeader() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object CompleteAnnotationHeader that will be copied. + */ + eProsima_user_DllExport CompleteAnnotationHeader( + const CompleteAnnotationHeader& x) + { + m_annotation_name = x.m_annotation_name; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object CompleteAnnotationHeader that will be copied. + */ + eProsima_user_DllExport CompleteAnnotationHeader( + CompleteAnnotationHeader&& x) noexcept + { + m_annotation_name = std::move(x.m_annotation_name); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object CompleteAnnotationHeader that will be copied. + */ + eProsima_user_DllExport CompleteAnnotationHeader& operator =( + const CompleteAnnotationHeader& x) + { + + m_annotation_name = x.m_annotation_name; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object CompleteAnnotationHeader that will be copied. + */ + eProsima_user_DllExport CompleteAnnotationHeader& operator =( + CompleteAnnotationHeader&& x) noexcept + { + + m_annotation_name = std::move(x.m_annotation_name); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x CompleteAnnotationHeader object to compare. + */ + eProsima_user_DllExport bool operator ==( + const CompleteAnnotationHeader& x) const + { + return (m_annotation_name == x.m_annotation_name); + } + + /*! + * @brief Comparison operator. + * @param x CompleteAnnotationHeader object to compare. + */ + eProsima_user_DllExport bool operator !=( + const CompleteAnnotationHeader& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member annotation_name + * @param _annotation_name New value to be copied in member annotation_name + */ + eProsima_user_DllExport void annotation_name( + const QualifiedTypeName& _annotation_name) + { + m_annotation_name = _annotation_name; + } + + /*! + * @brief This function moves the value in member annotation_name + * @param _annotation_name New value to be moved in member annotation_name + */ + eProsima_user_DllExport void annotation_name( + QualifiedTypeName&& _annotation_name) + { + m_annotation_name = std::move(_annotation_name); + } + + /*! + * @brief This function returns a constant reference to member annotation_name + * @return Constant reference to member annotation_name + */ + eProsima_user_DllExport const QualifiedTypeName& annotation_name() const + { + return m_annotation_name; + } + + /*! + * @brief This function returns a reference to member annotation_name + * @return Reference to member annotation_name + */ + eProsima_user_DllExport QualifiedTypeName& annotation_name() + { + return m_annotation_name; + } + + + +private: + + QualifiedTypeName m_annotation_name; + +}; +/*! + * @brief This class represents the structure MinimalAnnotationHeader defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalAnnotationHeader +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport MinimalAnnotationHeader() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~MinimalAnnotationHeader() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object MinimalAnnotationHeader that will be copied. + */ + eProsima_user_DllExport MinimalAnnotationHeader( + const MinimalAnnotationHeader& x) + { + static_cast(x); + } + + /*! + * @brief Move constructor. + * @param x Reference to the object MinimalAnnotationHeader that will be copied. + */ + eProsima_user_DllExport MinimalAnnotationHeader( + MinimalAnnotationHeader&& x) noexcept + { + static_cast(x); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object MinimalAnnotationHeader that will be copied. + */ + eProsima_user_DllExport MinimalAnnotationHeader& operator =( + const MinimalAnnotationHeader& x) + { + + static_cast(x); + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object MinimalAnnotationHeader that will be copied. + */ + eProsima_user_DllExport MinimalAnnotationHeader& operator =( + MinimalAnnotationHeader&& x) noexcept + { + + static_cast(x); + + return *this; + } + + /*! + * @brief Comparison operator. + * @param x MinimalAnnotationHeader object to compare. + */ + eProsima_user_DllExport bool operator ==( + const MinimalAnnotationHeader& x) const + { + static_cast(x); + return true; + } + + /*! + * @brief Comparison operator. + * @param x MinimalAnnotationHeader object to compare. + */ + eProsima_user_DllExport bool operator !=( + const MinimalAnnotationHeader& x) const + { + return !(*this == x); + } + + + +private: + + +}; +/*! + * @brief This class represents the structure CompleteAnnotationType defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteAnnotationType +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport CompleteAnnotationType() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~CompleteAnnotationType() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object CompleteAnnotationType that will be copied. + */ + eProsima_user_DllExport CompleteAnnotationType( + const CompleteAnnotationType& x) + { + m_annotation_flag = x.m_annotation_flag; + + m_header = x.m_header; + + m_member_seq = x.m_member_seq; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object CompleteAnnotationType that will be copied. + */ + eProsima_user_DllExport CompleteAnnotationType( + CompleteAnnotationType&& x) noexcept + { + m_annotation_flag = std::move(x.m_annotation_flag); + m_header = std::move(x.m_header); + m_member_seq = std::move(x.m_member_seq); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object CompleteAnnotationType that will be copied. + */ + eProsima_user_DllExport CompleteAnnotationType& operator =( + const CompleteAnnotationType& x) + { + + m_annotation_flag = x.m_annotation_flag; + + m_header = x.m_header; + + m_member_seq = x.m_member_seq; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object CompleteAnnotationType that will be copied. + */ + eProsima_user_DllExport CompleteAnnotationType& operator =( + CompleteAnnotationType&& x) noexcept + { + + m_annotation_flag = std::move(x.m_annotation_flag); + m_header = std::move(x.m_header); + m_member_seq = std::move(x.m_member_seq); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x CompleteAnnotationType object to compare. + */ + eProsima_user_DllExport bool operator ==( + const CompleteAnnotationType& x) const + { + return (m_annotation_flag == x.m_annotation_flag && + m_header == x.m_header && + m_member_seq == x.m_member_seq); + } + + /*! + * @brief Comparison operator. + * @param x CompleteAnnotationType object to compare. + */ + eProsima_user_DllExport bool operator !=( + const CompleteAnnotationType& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member annotation_flag + * @param _annotation_flag New value to be copied in member annotation_flag + */ + eProsima_user_DllExport void annotation_flag( + const AnnotationTypeFlag& _annotation_flag) + { + m_annotation_flag = _annotation_flag; + } + + /*! + * @brief This function moves the value in member annotation_flag + * @param _annotation_flag New value to be moved in member annotation_flag + */ + eProsima_user_DllExport void annotation_flag( + AnnotationTypeFlag&& _annotation_flag) + { + m_annotation_flag = std::move(_annotation_flag); + } + + /*! + * @brief This function returns a constant reference to member annotation_flag + * @return Constant reference to member annotation_flag + */ + eProsima_user_DllExport const AnnotationTypeFlag& annotation_flag() const + { + return m_annotation_flag; + } + + /*! + * @brief This function returns a reference to member annotation_flag + * @return Reference to member annotation_flag + */ + eProsima_user_DllExport AnnotationTypeFlag& annotation_flag() + { + return m_annotation_flag; + } + + + /*! + * @brief This function copies the value in member header + * @param _header New value to be copied in member header + */ + eProsima_user_DllExport void header( + const CompleteAnnotationHeader& _header) + { + m_header = _header; + } + + /*! + * @brief This function moves the value in member header + * @param _header New value to be moved in member header + */ + eProsima_user_DllExport void header( + CompleteAnnotationHeader&& _header) + { + m_header = std::move(_header); + } + + /*! + * @brief This function returns a constant reference to member header + * @return Constant reference to member header + */ + eProsima_user_DllExport const CompleteAnnotationHeader& header() const + { + return m_header; + } + + /*! + * @brief This function returns a reference to member header + * @return Reference to member header + */ + eProsima_user_DllExport CompleteAnnotationHeader& header() + { + return m_header; + } + + + /*! + * @brief This function copies the value in member member_seq + * @param _member_seq New value to be copied in member member_seq + */ + eProsima_user_DllExport void member_seq( + const CompleteAnnotationParameterSeq& _member_seq) + { + m_member_seq = _member_seq; + } + + /*! + * @brief This function moves the value in member member_seq + * @param _member_seq New value to be moved in member member_seq + */ + eProsima_user_DllExport void member_seq( + CompleteAnnotationParameterSeq&& _member_seq) + { + m_member_seq = std::move(_member_seq); + } + + /*! + * @brief This function returns a constant reference to member member_seq + * @return Constant reference to member member_seq + */ + eProsima_user_DllExport const CompleteAnnotationParameterSeq& member_seq() const + { + return m_member_seq; + } + + /*! + * @brief This function returns a reference to member member_seq + * @return Reference to member member_seq + */ + eProsima_user_DllExport CompleteAnnotationParameterSeq& member_seq() + { + return m_member_seq; + } + + + +private: + + AnnotationTypeFlag m_annotation_flag{0}; + CompleteAnnotationHeader m_header; + CompleteAnnotationParameterSeq m_member_seq; + +}; +/*! + * @brief This class represents the structure MinimalAnnotationType defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalAnnotationType +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport MinimalAnnotationType() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~MinimalAnnotationType() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object MinimalAnnotationType that will be copied. + */ + eProsima_user_DllExport MinimalAnnotationType( + const MinimalAnnotationType& x) + { + m_annotation_flag = x.m_annotation_flag; + + m_header = x.m_header; + + m_member_seq = x.m_member_seq; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object MinimalAnnotationType that will be copied. + */ + eProsima_user_DllExport MinimalAnnotationType( + MinimalAnnotationType&& x) noexcept + { + m_annotation_flag = std::move(x.m_annotation_flag); + m_header = std::move(x.m_header); + m_member_seq = std::move(x.m_member_seq); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object MinimalAnnotationType that will be copied. + */ + eProsima_user_DllExport MinimalAnnotationType& operator =( + const MinimalAnnotationType& x) + { + + m_annotation_flag = x.m_annotation_flag; + + m_header = x.m_header; + + m_member_seq = x.m_member_seq; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object MinimalAnnotationType that will be copied. + */ + eProsima_user_DllExport MinimalAnnotationType& operator =( + MinimalAnnotationType&& x) noexcept + { + + m_annotation_flag = std::move(x.m_annotation_flag); + m_header = std::move(x.m_header); + m_member_seq = std::move(x.m_member_seq); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x MinimalAnnotationType object to compare. + */ + eProsima_user_DllExport bool operator ==( + const MinimalAnnotationType& x) const + { + return (m_annotation_flag == x.m_annotation_flag && + m_header == x.m_header && + m_member_seq == x.m_member_seq); + } + + /*! + * @brief Comparison operator. + * @param x MinimalAnnotationType object to compare. + */ + eProsima_user_DllExport bool operator !=( + const MinimalAnnotationType& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member annotation_flag + * @param _annotation_flag New value to be copied in member annotation_flag + */ + eProsima_user_DllExport void annotation_flag( + const AnnotationTypeFlag& _annotation_flag) + { + m_annotation_flag = _annotation_flag; + } + + /*! + * @brief This function moves the value in member annotation_flag + * @param _annotation_flag New value to be moved in member annotation_flag + */ + eProsima_user_DllExport void annotation_flag( + AnnotationTypeFlag&& _annotation_flag) + { + m_annotation_flag = std::move(_annotation_flag); + } + + /*! + * @brief This function returns a constant reference to member annotation_flag + * @return Constant reference to member annotation_flag + */ + eProsima_user_DllExport const AnnotationTypeFlag& annotation_flag() const + { + return m_annotation_flag; + } + + /*! + * @brief This function returns a reference to member annotation_flag + * @return Reference to member annotation_flag + */ + eProsima_user_DllExport AnnotationTypeFlag& annotation_flag() + { + return m_annotation_flag; + } + + + /*! + * @brief This function copies the value in member header + * @param _header New value to be copied in member header + */ + eProsima_user_DllExport void header( + const MinimalAnnotationHeader& _header) + { + m_header = _header; + } + + /*! + * @brief This function moves the value in member header + * @param _header New value to be moved in member header + */ + eProsima_user_DllExport void header( + MinimalAnnotationHeader&& _header) + { + m_header = std::move(_header); + } + + /*! + * @brief This function returns a constant reference to member header + * @return Constant reference to member header + */ + eProsima_user_DllExport const MinimalAnnotationHeader& header() const + { + return m_header; + } + + /*! + * @brief This function returns a reference to member header + * @return Reference to member header + */ + eProsima_user_DllExport MinimalAnnotationHeader& header() + { + return m_header; + } + + + /*! + * @brief This function copies the value in member member_seq + * @param _member_seq New value to be copied in member member_seq + */ + eProsima_user_DllExport void member_seq( + const MinimalAnnotationParameterSeq& _member_seq) + { + m_member_seq = _member_seq; + } + + /*! + * @brief This function moves the value in member member_seq + * @param _member_seq New value to be moved in member member_seq + */ + eProsima_user_DllExport void member_seq( + MinimalAnnotationParameterSeq&& _member_seq) + { + m_member_seq = std::move(_member_seq); + } + + /*! + * @brief This function returns a constant reference to member member_seq + * @return Constant reference to member member_seq + */ + eProsima_user_DllExport const MinimalAnnotationParameterSeq& member_seq() const + { + return m_member_seq; + } + + /*! + * @brief This function returns a reference to member member_seq + * @return Reference to member member_seq + */ + eProsima_user_DllExport MinimalAnnotationParameterSeq& member_seq() + { + return m_member_seq; + } + + + +private: + + AnnotationTypeFlag m_annotation_flag{0}; + MinimalAnnotationHeader m_header; + MinimalAnnotationParameterSeq m_member_seq; + +}; +/*! + * @brief This class represents the structure CommonAliasBody defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CommonAliasBody +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport CommonAliasBody() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~CommonAliasBody() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object CommonAliasBody that will be copied. + */ + eProsima_user_DllExport CommonAliasBody( + const CommonAliasBody& x) + { + m_related_flags = x.m_related_flags; + + m_related_type = x.m_related_type; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object CommonAliasBody that will be copied. + */ + eProsima_user_DllExport CommonAliasBody( + CommonAliasBody&& x) noexcept + { + m_related_flags = std::move(x.m_related_flags); + m_related_type = std::move(x.m_related_type); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object CommonAliasBody that will be copied. + */ + eProsima_user_DllExport CommonAliasBody& operator =( + const CommonAliasBody& x) + { + + m_related_flags = x.m_related_flags; + + m_related_type = x.m_related_type; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object CommonAliasBody that will be copied. + */ + eProsima_user_DllExport CommonAliasBody& operator =( + CommonAliasBody&& x) noexcept + { + + m_related_flags = std::move(x.m_related_flags); + m_related_type = std::move(x.m_related_type); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x CommonAliasBody object to compare. + */ + eProsima_user_DllExport bool operator ==( + const CommonAliasBody& x) const + { + return (m_related_flags == x.m_related_flags && + m_related_type == x.m_related_type); + } + + /*! + * @brief Comparison operator. + * @param x CommonAliasBody object to compare. + */ + eProsima_user_DllExport bool operator !=( + const CommonAliasBody& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member related_flags + * @param _related_flags New value to be copied in member related_flags + */ + eProsima_user_DllExport void related_flags( + const AliasMemberFlag& _related_flags) + { + m_related_flags = _related_flags; + } + + /*! + * @brief This function moves the value in member related_flags + * @param _related_flags New value to be moved in member related_flags + */ + eProsima_user_DllExport void related_flags( + AliasMemberFlag&& _related_flags) + { + m_related_flags = std::move(_related_flags); + } + + /*! + * @brief This function returns a constant reference to member related_flags + * @return Constant reference to member related_flags + */ + eProsima_user_DllExport const AliasMemberFlag& related_flags() const + { + return m_related_flags; + } + + /*! + * @brief This function returns a reference to member related_flags + * @return Reference to member related_flags + */ + eProsima_user_DllExport AliasMemberFlag& related_flags() + { + return m_related_flags; + } + + + /*! + * @brief This function copies the value in member related_type + * @param _related_type New value to be copied in member related_type + */ + eProsima_user_DllExport void related_type( + const TypeIdentifier& _related_type) + { + m_related_type = _related_type; + } + + /*! + * @brief This function moves the value in member related_type + * @param _related_type New value to be moved in member related_type + */ + eProsima_user_DllExport void related_type( + TypeIdentifier&& _related_type) + { + m_related_type = std::move(_related_type); + } + + /*! + * @brief This function returns a constant reference to member related_type + * @return Constant reference to member related_type + */ + eProsima_user_DllExport const TypeIdentifier& related_type() const + { + return m_related_type; + } + + /*! + * @brief This function returns a reference to member related_type + * @return Reference to member related_type + */ + eProsima_user_DllExport TypeIdentifier& related_type() + { + return m_related_type; + } + + + +private: + + AliasMemberFlag m_related_flags{0}; + TypeIdentifier m_related_type; + +}; +/*! + * @brief This class represents the structure CompleteAliasBody defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteAliasBody +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport CompleteAliasBody() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~CompleteAliasBody() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object CompleteAliasBody that will be copied. + */ + eProsima_user_DllExport CompleteAliasBody( + const CompleteAliasBody& x) + { + m_common = x.m_common; + + m_ann_builtin = x.m_ann_builtin; + + m_ann_custom = x.m_ann_custom; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object CompleteAliasBody that will be copied. + */ + eProsima_user_DllExport CompleteAliasBody( + CompleteAliasBody&& x) noexcept + { + m_common = std::move(x.m_common); + m_ann_builtin = std::move(x.m_ann_builtin); + m_ann_custom = std::move(x.m_ann_custom); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object CompleteAliasBody that will be copied. + */ + eProsima_user_DllExport CompleteAliasBody& operator =( + const CompleteAliasBody& x) + { + + m_common = x.m_common; + + m_ann_builtin = x.m_ann_builtin; + + m_ann_custom = x.m_ann_custom; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object CompleteAliasBody that will be copied. + */ + eProsima_user_DllExport CompleteAliasBody& operator =( + CompleteAliasBody&& x) noexcept + { + + m_common = std::move(x.m_common); + m_ann_builtin = std::move(x.m_ann_builtin); + m_ann_custom = std::move(x.m_ann_custom); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x CompleteAliasBody object to compare. + */ + eProsima_user_DllExport bool operator ==( + const CompleteAliasBody& x) const + { + return (m_common == x.m_common && + m_ann_builtin == x.m_ann_builtin && + m_ann_custom == x.m_ann_custom); + } + + /*! + * @brief Comparison operator. + * @param x CompleteAliasBody object to compare. + */ + eProsima_user_DllExport bool operator !=( + const CompleteAliasBody& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member common + * @param _common New value to be copied in member common + */ + eProsima_user_DllExport void common( + const CommonAliasBody& _common) + { + m_common = _common; + } + + /*! + * @brief This function moves the value in member common + * @param _common New value to be moved in member common + */ + eProsima_user_DllExport void common( + CommonAliasBody&& _common) + { + m_common = std::move(_common); + } + + /*! + * @brief This function returns a constant reference to member common + * @return Constant reference to member common + */ + eProsima_user_DllExport const CommonAliasBody& common() const + { + return m_common; + } + + /*! + * @brief This function returns a reference to member common + * @return Reference to member common + */ + eProsima_user_DllExport CommonAliasBody& common() + { + return m_common; + } + + + /*! + * @brief This function copies the value in member ann_builtin + * @param _ann_builtin New value to be copied in member ann_builtin + */ + eProsima_user_DllExport void ann_builtin( + const eprosima::fastcdr::optional& _ann_builtin) + { + m_ann_builtin = _ann_builtin; + } + + /*! + * @brief This function moves the value in member ann_builtin + * @param _ann_builtin New value to be moved in member ann_builtin + */ + eProsima_user_DllExport void ann_builtin( + eprosima::fastcdr::optional&& _ann_builtin) + { + m_ann_builtin = std::move(_ann_builtin); + } + + /*! + * @brief This function returns a constant reference to member ann_builtin + * @return Constant reference to member ann_builtin + */ + eProsima_user_DllExport const eprosima::fastcdr::optional& ann_builtin() const + { + return m_ann_builtin; + } + + /*! + * @brief This function returns a reference to member ann_builtin + * @return Reference to member ann_builtin + */ + eProsima_user_DllExport eprosima::fastcdr::optional& ann_builtin() + { + return m_ann_builtin; + } + + + /*! + * @brief This function copies the value in member ann_custom + * @param _ann_custom New value to be copied in member ann_custom + */ + eProsima_user_DllExport void ann_custom( + const eprosima::fastcdr::optional& _ann_custom) + { + m_ann_custom = _ann_custom; + } + + /*! + * @brief This function moves the value in member ann_custom + * @param _ann_custom New value to be moved in member ann_custom + */ + eProsima_user_DllExport void ann_custom( + eprosima::fastcdr::optional&& _ann_custom) + { + m_ann_custom = std::move(_ann_custom); + } + + /*! + * @brief This function returns a constant reference to member ann_custom + * @return Constant reference to member ann_custom + */ + eProsima_user_DllExport const eprosima::fastcdr::optional& ann_custom() const + { + return m_ann_custom; + } + + /*! + * @brief This function returns a reference to member ann_custom + * @return Reference to member ann_custom + */ + eProsima_user_DllExport eprosima::fastcdr::optional& ann_custom() + { + return m_ann_custom; + } + + + +private: + + CommonAliasBody m_common; + eprosima::fastcdr::optional m_ann_builtin; + eprosima::fastcdr::optional m_ann_custom; + +}; +/*! + * @brief This class represents the structure MinimalAliasBody defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalAliasBody +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport MinimalAliasBody() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~MinimalAliasBody() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object MinimalAliasBody that will be copied. + */ + eProsima_user_DllExport MinimalAliasBody( + const MinimalAliasBody& x) + { + m_common = x.m_common; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object MinimalAliasBody that will be copied. + */ + eProsima_user_DllExport MinimalAliasBody( + MinimalAliasBody&& x) noexcept + { + m_common = std::move(x.m_common); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object MinimalAliasBody that will be copied. + */ + eProsima_user_DllExport MinimalAliasBody& operator =( + const MinimalAliasBody& x) + { + + m_common = x.m_common; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object MinimalAliasBody that will be copied. + */ + eProsima_user_DllExport MinimalAliasBody& operator =( + MinimalAliasBody&& x) noexcept + { + + m_common = std::move(x.m_common); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x MinimalAliasBody object to compare. + */ + eProsima_user_DllExport bool operator ==( + const MinimalAliasBody& x) const + { + return (m_common == x.m_common); + } + + /*! + * @brief Comparison operator. + * @param x MinimalAliasBody object to compare. + */ + eProsima_user_DllExport bool operator !=( + const MinimalAliasBody& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member common + * @param _common New value to be copied in member common + */ + eProsima_user_DllExport void common( + const CommonAliasBody& _common) + { + m_common = _common; + } + + /*! + * @brief This function moves the value in member common + * @param _common New value to be moved in member common + */ + eProsima_user_DllExport void common( + CommonAliasBody&& _common) + { + m_common = std::move(_common); + } + + /*! + * @brief This function returns a constant reference to member common + * @return Constant reference to member common + */ + eProsima_user_DllExport const CommonAliasBody& common() const + { + return m_common; + } + + /*! + * @brief This function returns a reference to member common + * @return Reference to member common + */ + eProsima_user_DllExport CommonAliasBody& common() + { + return m_common; + } + + + +private: + + CommonAliasBody m_common; + +}; +/*! + * @brief This class represents the structure CompleteAliasHeader defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteAliasHeader +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport CompleteAliasHeader() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~CompleteAliasHeader() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object CompleteAliasHeader that will be copied. + */ + eProsima_user_DllExport CompleteAliasHeader( + const CompleteAliasHeader& x) + { + m_detail = x.m_detail; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object CompleteAliasHeader that will be copied. + */ + eProsima_user_DllExport CompleteAliasHeader( + CompleteAliasHeader&& x) noexcept + { + m_detail = std::move(x.m_detail); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object CompleteAliasHeader that will be copied. + */ + eProsima_user_DllExport CompleteAliasHeader& operator =( + const CompleteAliasHeader& x) + { + + m_detail = x.m_detail; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object CompleteAliasHeader that will be copied. + */ + eProsima_user_DllExport CompleteAliasHeader& operator =( + CompleteAliasHeader&& x) noexcept + { + + m_detail = std::move(x.m_detail); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x CompleteAliasHeader object to compare. + */ + eProsima_user_DllExport bool operator ==( + const CompleteAliasHeader& x) const + { + return (m_detail == x.m_detail); + } + + /*! + * @brief Comparison operator. + * @param x CompleteAliasHeader object to compare. + */ + eProsima_user_DllExport bool operator !=( + const CompleteAliasHeader& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member detail + * @param _detail New value to be copied in member detail + */ + eProsima_user_DllExport void detail( + const CompleteTypeDetail& _detail) + { + m_detail = _detail; + } + + /*! + * @brief This function moves the value in member detail + * @param _detail New value to be moved in member detail + */ + eProsima_user_DllExport void detail( + CompleteTypeDetail&& _detail) + { + m_detail = std::move(_detail); + } + + /*! + * @brief This function returns a constant reference to member detail + * @return Constant reference to member detail + */ + eProsima_user_DllExport const CompleteTypeDetail& detail() const + { + return m_detail; + } + + /*! + * @brief This function returns a reference to member detail + * @return Reference to member detail + */ + eProsima_user_DllExport CompleteTypeDetail& detail() + { + return m_detail; + } + + + +private: + + CompleteTypeDetail m_detail; + +}; +/*! + * @brief This class represents the structure MinimalAliasHeader defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalAliasHeader +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport MinimalAliasHeader() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~MinimalAliasHeader() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object MinimalAliasHeader that will be copied. + */ + eProsima_user_DllExport MinimalAliasHeader( + const MinimalAliasHeader& x) + { + static_cast(x); + } + + /*! + * @brief Move constructor. + * @param x Reference to the object MinimalAliasHeader that will be copied. + */ + eProsima_user_DllExport MinimalAliasHeader( + MinimalAliasHeader&& x) noexcept + { + static_cast(x); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object MinimalAliasHeader that will be copied. + */ + eProsima_user_DllExport MinimalAliasHeader& operator =( + const MinimalAliasHeader& x) + { + + static_cast(x); + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object MinimalAliasHeader that will be copied. + */ + eProsima_user_DllExport MinimalAliasHeader& operator =( + MinimalAliasHeader&& x) noexcept + { + + static_cast(x); + + return *this; + } + + /*! + * @brief Comparison operator. + * @param x MinimalAliasHeader object to compare. + */ + eProsima_user_DllExport bool operator ==( + const MinimalAliasHeader& x) const + { + static_cast(x); + return true; + } + + /*! + * @brief Comparison operator. + * @param x MinimalAliasHeader object to compare. + */ + eProsima_user_DllExport bool operator !=( + const MinimalAliasHeader& x) const + { + return !(*this == x); + } + + + +private: + + +}; +/*! + * @brief This class represents the structure CompleteAliasType defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteAliasType +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport CompleteAliasType() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~CompleteAliasType() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object CompleteAliasType that will be copied. + */ + eProsima_user_DllExport CompleteAliasType( + const CompleteAliasType& x) + { + m_alias_flags = x.m_alias_flags; + + m_header = x.m_header; + + m_body = x.m_body; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object CompleteAliasType that will be copied. + */ + eProsima_user_DllExport CompleteAliasType( + CompleteAliasType&& x) noexcept + { + m_alias_flags = std::move(x.m_alias_flags); + m_header = std::move(x.m_header); + m_body = std::move(x.m_body); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object CompleteAliasType that will be copied. + */ + eProsima_user_DllExport CompleteAliasType& operator =( + const CompleteAliasType& x) + { + + m_alias_flags = x.m_alias_flags; + + m_header = x.m_header; + + m_body = x.m_body; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object CompleteAliasType that will be copied. + */ + eProsima_user_DllExport CompleteAliasType& operator =( + CompleteAliasType&& x) noexcept + { + + m_alias_flags = std::move(x.m_alias_flags); + m_header = std::move(x.m_header); + m_body = std::move(x.m_body); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x CompleteAliasType object to compare. + */ + eProsima_user_DllExport bool operator ==( + const CompleteAliasType& x) const + { + return (m_alias_flags == x.m_alias_flags && + m_header == x.m_header && + m_body == x.m_body); + } + + /*! + * @brief Comparison operator. + * @param x CompleteAliasType object to compare. + */ + eProsima_user_DllExport bool operator !=( + const CompleteAliasType& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member alias_flags + * @param _alias_flags New value to be copied in member alias_flags + */ + eProsima_user_DllExport void alias_flags( + const AliasTypeFlag& _alias_flags) + { + m_alias_flags = _alias_flags; + } + + /*! + * @brief This function moves the value in member alias_flags + * @param _alias_flags New value to be moved in member alias_flags + */ + eProsima_user_DllExport void alias_flags( + AliasTypeFlag&& _alias_flags) + { + m_alias_flags = std::move(_alias_flags); + } + + /*! + * @brief This function returns a constant reference to member alias_flags + * @return Constant reference to member alias_flags + */ + eProsima_user_DllExport const AliasTypeFlag& alias_flags() const + { + return m_alias_flags; + } + + /*! + * @brief This function returns a reference to member alias_flags + * @return Reference to member alias_flags + */ + eProsima_user_DllExport AliasTypeFlag& alias_flags() + { + return m_alias_flags; + } + + + /*! + * @brief This function copies the value in member header + * @param _header New value to be copied in member header + */ + eProsima_user_DllExport void header( + const CompleteAliasHeader& _header) + { + m_header = _header; + } + + /*! + * @brief This function moves the value in member header + * @param _header New value to be moved in member header + */ + eProsima_user_DllExport void header( + CompleteAliasHeader&& _header) + { + m_header = std::move(_header); + } + + /*! + * @brief This function returns a constant reference to member header + * @return Constant reference to member header + */ + eProsima_user_DllExport const CompleteAliasHeader& header() const + { + return m_header; + } + + /*! + * @brief This function returns a reference to member header + * @return Reference to member header + */ + eProsima_user_DllExport CompleteAliasHeader& header() + { + return m_header; + } + + + /*! + * @brief This function copies the value in member body + * @param _body New value to be copied in member body + */ + eProsima_user_DllExport void body( + const CompleteAliasBody& _body) + { + m_body = _body; + } + + /*! + * @brief This function moves the value in member body + * @param _body New value to be moved in member body + */ + eProsima_user_DllExport void body( + CompleteAliasBody&& _body) + { + m_body = std::move(_body); + } + + /*! + * @brief This function returns a constant reference to member body + * @return Constant reference to member body + */ + eProsima_user_DllExport const CompleteAliasBody& body() const + { + return m_body; + } + + /*! + * @brief This function returns a reference to member body + * @return Reference to member body + */ + eProsima_user_DllExport CompleteAliasBody& body() + { + return m_body; + } + + + +private: + + AliasTypeFlag m_alias_flags{0}; + CompleteAliasHeader m_header; + CompleteAliasBody m_body; + +}; +/*! + * @brief This class represents the structure MinimalAliasType defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalAliasType +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport MinimalAliasType() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~MinimalAliasType() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object MinimalAliasType that will be copied. + */ + eProsima_user_DllExport MinimalAliasType( + const MinimalAliasType& x) + { + m_alias_flags = x.m_alias_flags; + + m_header = x.m_header; + + m_body = x.m_body; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object MinimalAliasType that will be copied. + */ + eProsima_user_DllExport MinimalAliasType( + MinimalAliasType&& x) noexcept + { + m_alias_flags = std::move(x.m_alias_flags); + m_header = std::move(x.m_header); + m_body = std::move(x.m_body); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object MinimalAliasType that will be copied. + */ + eProsima_user_DllExport MinimalAliasType& operator =( + const MinimalAliasType& x) + { + + m_alias_flags = x.m_alias_flags; + + m_header = x.m_header; + + m_body = x.m_body; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object MinimalAliasType that will be copied. + */ + eProsima_user_DllExport MinimalAliasType& operator =( + MinimalAliasType&& x) noexcept + { + + m_alias_flags = std::move(x.m_alias_flags); + m_header = std::move(x.m_header); + m_body = std::move(x.m_body); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x MinimalAliasType object to compare. + */ + eProsima_user_DllExport bool operator ==( + const MinimalAliasType& x) const + { + return (m_alias_flags == x.m_alias_flags && + m_header == x.m_header && + m_body == x.m_body); + } + + /*! + * @brief Comparison operator. + * @param x MinimalAliasType object to compare. + */ + eProsima_user_DllExport bool operator !=( + const MinimalAliasType& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member alias_flags + * @param _alias_flags New value to be copied in member alias_flags + */ + eProsima_user_DllExport void alias_flags( + const AliasTypeFlag& _alias_flags) + { + m_alias_flags = _alias_flags; + } + + /*! + * @brief This function moves the value in member alias_flags + * @param _alias_flags New value to be moved in member alias_flags + */ + eProsima_user_DllExport void alias_flags( + AliasTypeFlag&& _alias_flags) + { + m_alias_flags = std::move(_alias_flags); + } + + /*! + * @brief This function returns a constant reference to member alias_flags + * @return Constant reference to member alias_flags + */ + eProsima_user_DllExport const AliasTypeFlag& alias_flags() const + { + return m_alias_flags; + } + + /*! + * @brief This function returns a reference to member alias_flags + * @return Reference to member alias_flags + */ + eProsima_user_DllExport AliasTypeFlag& alias_flags() + { + return m_alias_flags; + } + + + /*! + * @brief This function copies the value in member header + * @param _header New value to be copied in member header + */ + eProsima_user_DllExport void header( + const MinimalAliasHeader& _header) + { + m_header = _header; + } + + /*! + * @brief This function moves the value in member header + * @param _header New value to be moved in member header + */ + eProsima_user_DllExport void header( + MinimalAliasHeader&& _header) + { + m_header = std::move(_header); + } + + /*! + * @brief This function returns a constant reference to member header + * @return Constant reference to member header + */ + eProsima_user_DllExport const MinimalAliasHeader& header() const + { + return m_header; + } + + /*! + * @brief This function returns a reference to member header + * @return Reference to member header + */ + eProsima_user_DllExport MinimalAliasHeader& header() + { + return m_header; + } + + + /*! + * @brief This function copies the value in member body + * @param _body New value to be copied in member body + */ + eProsima_user_DllExport void body( + const MinimalAliasBody& _body) + { + m_body = _body; + } + + /*! + * @brief This function moves the value in member body + * @param _body New value to be moved in member body + */ + eProsima_user_DllExport void body( + MinimalAliasBody&& _body) + { + m_body = std::move(_body); + } + + /*! + * @brief This function returns a constant reference to member body + * @return Constant reference to member body + */ + eProsima_user_DllExport const MinimalAliasBody& body() const + { + return m_body; + } + + /*! + * @brief This function returns a reference to member body + * @return Reference to member body + */ + eProsima_user_DllExport MinimalAliasBody& body() + { + return m_body; + } + + + +private: + + AliasTypeFlag m_alias_flags{0}; + MinimalAliasHeader m_header; + MinimalAliasBody m_body; + +}; +/*! + * @brief This class represents the structure CompleteElementDetail defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteElementDetail +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport CompleteElementDetail() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~CompleteElementDetail() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object CompleteElementDetail that will be copied. + */ + eProsima_user_DllExport CompleteElementDetail( + const CompleteElementDetail& x) + { + m_ann_builtin = x.m_ann_builtin; + + m_ann_custom = x.m_ann_custom; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object CompleteElementDetail that will be copied. + */ + eProsima_user_DllExport CompleteElementDetail( + CompleteElementDetail&& x) noexcept + { + m_ann_builtin = std::move(x.m_ann_builtin); + m_ann_custom = std::move(x.m_ann_custom); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object CompleteElementDetail that will be copied. + */ + eProsima_user_DllExport CompleteElementDetail& operator =( + const CompleteElementDetail& x) + { + + m_ann_builtin = x.m_ann_builtin; + + m_ann_custom = x.m_ann_custom; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object CompleteElementDetail that will be copied. + */ + eProsima_user_DllExport CompleteElementDetail& operator =( + CompleteElementDetail&& x) noexcept + { + + m_ann_builtin = std::move(x.m_ann_builtin); + m_ann_custom = std::move(x.m_ann_custom); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x CompleteElementDetail object to compare. + */ + eProsima_user_DllExport bool operator ==( + const CompleteElementDetail& x) const + { + return (m_ann_builtin == x.m_ann_builtin && + m_ann_custom == x.m_ann_custom); + } + + /*! + * @brief Comparison operator. + * @param x CompleteElementDetail object to compare. + */ + eProsima_user_DllExport bool operator !=( + const CompleteElementDetail& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member ann_builtin + * @param _ann_builtin New value to be copied in member ann_builtin + */ + eProsima_user_DllExport void ann_builtin( + const eprosima::fastcdr::optional& _ann_builtin) + { + m_ann_builtin = _ann_builtin; + } + + /*! + * @brief This function moves the value in member ann_builtin + * @param _ann_builtin New value to be moved in member ann_builtin + */ + eProsima_user_DllExport void ann_builtin( + eprosima::fastcdr::optional&& _ann_builtin) + { + m_ann_builtin = std::move(_ann_builtin); + } + + /*! + * @brief This function returns a constant reference to member ann_builtin + * @return Constant reference to member ann_builtin + */ + eProsima_user_DllExport const eprosima::fastcdr::optional& ann_builtin() const + { + return m_ann_builtin; + } + + /*! + * @brief This function returns a reference to member ann_builtin + * @return Reference to member ann_builtin + */ + eProsima_user_DllExport eprosima::fastcdr::optional& ann_builtin() + { + return m_ann_builtin; + } + + + /*! + * @brief This function copies the value in member ann_custom + * @param _ann_custom New value to be copied in member ann_custom + */ + eProsima_user_DllExport void ann_custom( + const eprosima::fastcdr::optional& _ann_custom) + { + m_ann_custom = _ann_custom; + } + + /*! + * @brief This function moves the value in member ann_custom + * @param _ann_custom New value to be moved in member ann_custom + */ + eProsima_user_DllExport void ann_custom( + eprosima::fastcdr::optional&& _ann_custom) + { + m_ann_custom = std::move(_ann_custom); + } + + /*! + * @brief This function returns a constant reference to member ann_custom + * @return Constant reference to member ann_custom + */ + eProsima_user_DllExport const eprosima::fastcdr::optional& ann_custom() const + { + return m_ann_custom; + } + + /*! + * @brief This function returns a reference to member ann_custom + * @return Reference to member ann_custom + */ + eProsima_user_DllExport eprosima::fastcdr::optional& ann_custom() + { + return m_ann_custom; + } + + + +private: + + eprosima::fastcdr::optional m_ann_builtin; + eprosima::fastcdr::optional m_ann_custom; + +}; +/*! + * @brief This class represents the structure CommonCollectionElement defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CommonCollectionElement +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport CommonCollectionElement() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~CommonCollectionElement() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object CommonCollectionElement that will be copied. + */ + eProsima_user_DllExport CommonCollectionElement( + const CommonCollectionElement& x) + { + m_element_flags = x.m_element_flags; + + m_type = x.m_type; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object CommonCollectionElement that will be copied. + */ + eProsima_user_DllExport CommonCollectionElement( + CommonCollectionElement&& x) noexcept + { + m_element_flags = std::move(x.m_element_flags); + m_type = std::move(x.m_type); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object CommonCollectionElement that will be copied. + */ + eProsima_user_DllExport CommonCollectionElement& operator =( + const CommonCollectionElement& x) + { + + m_element_flags = x.m_element_flags; + + m_type = x.m_type; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object CommonCollectionElement that will be copied. + */ + eProsima_user_DllExport CommonCollectionElement& operator =( + CommonCollectionElement&& x) noexcept + { + + m_element_flags = std::move(x.m_element_flags); + m_type = std::move(x.m_type); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x CommonCollectionElement object to compare. + */ + eProsima_user_DllExport bool operator ==( + const CommonCollectionElement& x) const + { + return (m_element_flags == x.m_element_flags && + m_type == x.m_type); + } + + /*! + * @brief Comparison operator. + * @param x CommonCollectionElement object to compare. + */ + eProsima_user_DllExport bool operator !=( + const CommonCollectionElement& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member element_flags + * @param _element_flags New value to be copied in member element_flags + */ + eProsima_user_DllExport void element_flags( + const CollectionElementFlag& _element_flags) + { + m_element_flags = _element_flags; + } + + /*! + * @brief This function moves the value in member element_flags + * @param _element_flags New value to be moved in member element_flags + */ + eProsima_user_DllExport void element_flags( + CollectionElementFlag&& _element_flags) + { + m_element_flags = std::move(_element_flags); + } + + /*! + * @brief This function returns a constant reference to member element_flags + * @return Constant reference to member element_flags + */ + eProsima_user_DllExport const CollectionElementFlag& element_flags() const + { + return m_element_flags; + } + + /*! + * @brief This function returns a reference to member element_flags + * @return Reference to member element_flags + */ + eProsima_user_DllExport CollectionElementFlag& element_flags() + { + return m_element_flags; + } + + + /*! + * @brief This function copies the value in member type + * @param _type New value to be copied in member type + */ + eProsima_user_DllExport void type( + const TypeIdentifier& _type) + { + m_type = _type; + } + + /*! + * @brief This function moves the value in member type + * @param _type New value to be moved in member type + */ + eProsima_user_DllExport void type( + TypeIdentifier&& _type) + { + m_type = std::move(_type); + } + + /*! + * @brief This function returns a constant reference to member type + * @return Constant reference to member type + */ + eProsima_user_DllExport const TypeIdentifier& type() const + { + return m_type; + } + + /*! + * @brief This function returns a reference to member type + * @return Reference to member type + */ + eProsima_user_DllExport TypeIdentifier& type() + { + return m_type; + } + + + +private: + + CollectionElementFlag m_element_flags{0}; + TypeIdentifier m_type; + +}; +/*! + * @brief This class represents the structure CompleteCollectionElement defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteCollectionElement +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport CompleteCollectionElement() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~CompleteCollectionElement() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object CompleteCollectionElement that will be copied. + */ + eProsima_user_DllExport CompleteCollectionElement( + const CompleteCollectionElement& x) + { + m_common = x.m_common; + + m_detail = x.m_detail; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object CompleteCollectionElement that will be copied. + */ + eProsima_user_DllExport CompleteCollectionElement( + CompleteCollectionElement&& x) noexcept + { + m_common = std::move(x.m_common); + m_detail = std::move(x.m_detail); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object CompleteCollectionElement that will be copied. + */ + eProsima_user_DllExport CompleteCollectionElement& operator =( + const CompleteCollectionElement& x) + { + + m_common = x.m_common; + + m_detail = x.m_detail; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object CompleteCollectionElement that will be copied. + */ + eProsima_user_DllExport CompleteCollectionElement& operator =( + CompleteCollectionElement&& x) noexcept + { + + m_common = std::move(x.m_common); + m_detail = std::move(x.m_detail); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x CompleteCollectionElement object to compare. + */ + eProsima_user_DllExport bool operator ==( + const CompleteCollectionElement& x) const + { + return (m_common == x.m_common && + m_detail == x.m_detail); + } + + /*! + * @brief Comparison operator. + * @param x CompleteCollectionElement object to compare. + */ + eProsima_user_DllExport bool operator !=( + const CompleteCollectionElement& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member common + * @param _common New value to be copied in member common + */ + eProsima_user_DllExport void common( + const CommonCollectionElement& _common) + { + m_common = _common; + } + + /*! + * @brief This function moves the value in member common + * @param _common New value to be moved in member common + */ + eProsima_user_DllExport void common( + CommonCollectionElement&& _common) + { + m_common = std::move(_common); + } + + /*! + * @brief This function returns a constant reference to member common + * @return Constant reference to member common + */ + eProsima_user_DllExport const CommonCollectionElement& common() const + { + return m_common; + } + + /*! + * @brief This function returns a reference to member common + * @return Reference to member common + */ + eProsima_user_DllExport CommonCollectionElement& common() + { + return m_common; + } + + + /*! + * @brief This function copies the value in member detail + * @param _detail New value to be copied in member detail + */ + eProsima_user_DllExport void detail( + const CompleteElementDetail& _detail) + { + m_detail = _detail; + } + + /*! + * @brief This function moves the value in member detail + * @param _detail New value to be moved in member detail + */ + eProsima_user_DllExport void detail( + CompleteElementDetail&& _detail) + { + m_detail = std::move(_detail); + } + + /*! + * @brief This function returns a constant reference to member detail + * @return Constant reference to member detail + */ + eProsima_user_DllExport const CompleteElementDetail& detail() const + { + return m_detail; + } + + /*! + * @brief This function returns a reference to member detail + * @return Reference to member detail + */ + eProsima_user_DllExport CompleteElementDetail& detail() + { + return m_detail; + } + + + +private: + + CommonCollectionElement m_common; + CompleteElementDetail m_detail; + +}; +/*! + * @brief This class represents the structure MinimalCollectionElement defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalCollectionElement +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport MinimalCollectionElement() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~MinimalCollectionElement() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object MinimalCollectionElement that will be copied. + */ + eProsima_user_DllExport MinimalCollectionElement( + const MinimalCollectionElement& x) + { + m_common = x.m_common; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object MinimalCollectionElement that will be copied. + */ + eProsima_user_DllExport MinimalCollectionElement( + MinimalCollectionElement&& x) noexcept + { + m_common = std::move(x.m_common); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object MinimalCollectionElement that will be copied. + */ + eProsima_user_DllExport MinimalCollectionElement& operator =( + const MinimalCollectionElement& x) + { + + m_common = x.m_common; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object MinimalCollectionElement that will be copied. + */ + eProsima_user_DllExport MinimalCollectionElement& operator =( + MinimalCollectionElement&& x) noexcept + { + + m_common = std::move(x.m_common); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x MinimalCollectionElement object to compare. + */ + eProsima_user_DllExport bool operator ==( + const MinimalCollectionElement& x) const + { + return (m_common == x.m_common); + } + + /*! + * @brief Comparison operator. + * @param x MinimalCollectionElement object to compare. + */ + eProsima_user_DllExport bool operator !=( + const MinimalCollectionElement& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member common + * @param _common New value to be copied in member common + */ + eProsima_user_DllExport void common( + const CommonCollectionElement& _common) + { + m_common = _common; + } + + /*! + * @brief This function moves the value in member common + * @param _common New value to be moved in member common + */ + eProsima_user_DllExport void common( + CommonCollectionElement&& _common) + { + m_common = std::move(_common); + } + + /*! + * @brief This function returns a constant reference to member common + * @return Constant reference to member common + */ + eProsima_user_DllExport const CommonCollectionElement& common() const + { + return m_common; + } + + /*! + * @brief This function returns a reference to member common + * @return Reference to member common + */ + eProsima_user_DllExport CommonCollectionElement& common() + { + return m_common; + } + + + +private: + + CommonCollectionElement m_common; + +}; +/*! + * @brief This class represents the structure CommonCollectionHeader defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CommonCollectionHeader +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport CommonCollectionHeader() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~CommonCollectionHeader() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object CommonCollectionHeader that will be copied. + */ + eProsima_user_DllExport CommonCollectionHeader( + const CommonCollectionHeader& x) + { + m_bound = x.m_bound; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object CommonCollectionHeader that will be copied. + */ + eProsima_user_DllExport CommonCollectionHeader( + CommonCollectionHeader&& x) noexcept + { + m_bound = x.m_bound; + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object CommonCollectionHeader that will be copied. + */ + eProsima_user_DllExport CommonCollectionHeader& operator =( + const CommonCollectionHeader& x) + { + + m_bound = x.m_bound; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object CommonCollectionHeader that will be copied. + */ + eProsima_user_DllExport CommonCollectionHeader& operator =( + CommonCollectionHeader&& x) noexcept + { + + m_bound = x.m_bound; + return *this; + } + + /*! + * @brief Comparison operator. + * @param x CommonCollectionHeader object to compare. + */ + eProsima_user_DllExport bool operator ==( + const CommonCollectionHeader& x) const + { + return (m_bound == x.m_bound); + } + + /*! + * @brief Comparison operator. + * @param x CommonCollectionHeader object to compare. + */ + eProsima_user_DllExport bool operator !=( + const CommonCollectionHeader& x) const + { + return !(*this == x); + } + + /*! + * @brief This function sets a value in member bound + * @param _bound New value for member bound + */ + eProsima_user_DllExport void bound( + LBound _bound) + { + m_bound = _bound; + } + + /*! + * @brief This function returns the value of member bound + * @return Value of member bound + */ + eProsima_user_DllExport LBound bound() const + { + return m_bound; + } + + /*! + * @brief This function returns a reference to member bound + * @return Reference to member bound + */ + eProsima_user_DllExport LBound& bound() + { + return m_bound; + } + + + +private: + + LBound m_bound{0}; + +}; +/*! + * @brief This class represents the structure CompleteCollectionHeader defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteCollectionHeader +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport CompleteCollectionHeader() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~CompleteCollectionHeader() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object CompleteCollectionHeader that will be copied. + */ + eProsima_user_DllExport CompleteCollectionHeader( + const CompleteCollectionHeader& x) + { + m_common = x.m_common; + + m_detail = x.m_detail; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object CompleteCollectionHeader that will be copied. + */ + eProsima_user_DllExport CompleteCollectionHeader( + CompleteCollectionHeader&& x) noexcept + { + m_common = std::move(x.m_common); + m_detail = std::move(x.m_detail); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object CompleteCollectionHeader that will be copied. + */ + eProsima_user_DllExport CompleteCollectionHeader& operator =( + const CompleteCollectionHeader& x) + { + + m_common = x.m_common; + + m_detail = x.m_detail; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object CompleteCollectionHeader that will be copied. + */ + eProsima_user_DllExport CompleteCollectionHeader& operator =( + CompleteCollectionHeader&& x) noexcept + { + + m_common = std::move(x.m_common); + m_detail = std::move(x.m_detail); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x CompleteCollectionHeader object to compare. + */ + eProsima_user_DllExport bool operator ==( + const CompleteCollectionHeader& x) const + { + return (m_common == x.m_common && + m_detail == x.m_detail); + } + + /*! + * @brief Comparison operator. + * @param x CompleteCollectionHeader object to compare. + */ + eProsima_user_DllExport bool operator !=( + const CompleteCollectionHeader& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member common + * @param _common New value to be copied in member common + */ + eProsima_user_DllExport void common( + const CommonCollectionHeader& _common) + { + m_common = _common; + } + + /*! + * @brief This function moves the value in member common + * @param _common New value to be moved in member common + */ + eProsima_user_DllExport void common( + CommonCollectionHeader&& _common) + { + m_common = std::move(_common); + } + + /*! + * @brief This function returns a constant reference to member common + * @return Constant reference to member common + */ + eProsima_user_DllExport const CommonCollectionHeader& common() const + { + return m_common; + } + + /*! + * @brief This function returns a reference to member common + * @return Reference to member common + */ + eProsima_user_DllExport CommonCollectionHeader& common() + { + return m_common; + } + + + /*! + * @brief This function copies the value in member detail + * @param _detail New value to be copied in member detail + */ + eProsima_user_DllExport void detail( + const eprosima::fastcdr::optional& _detail) + { + m_detail = _detail; + } + + /*! + * @brief This function moves the value in member detail + * @param _detail New value to be moved in member detail + */ + eProsima_user_DllExport void detail( + eprosima::fastcdr::optional&& _detail) + { + m_detail = std::move(_detail); + } + + /*! + * @brief This function returns a constant reference to member detail + * @return Constant reference to member detail + */ + eProsima_user_DllExport const eprosima::fastcdr::optional& detail() const + { + return m_detail; + } + + /*! + * @brief This function returns a reference to member detail + * @return Reference to member detail + */ + eProsima_user_DllExport eprosima::fastcdr::optional& detail() + { + return m_detail; + } + + + +private: + + CommonCollectionHeader m_common; + eprosima::fastcdr::optional m_detail; + +}; +/*! + * @brief This class represents the structure MinimalCollectionHeader defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalCollectionHeader +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport MinimalCollectionHeader() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~MinimalCollectionHeader() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object MinimalCollectionHeader that will be copied. + */ + eProsima_user_DllExport MinimalCollectionHeader( + const MinimalCollectionHeader& x) + { + m_common = x.m_common; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object MinimalCollectionHeader that will be copied. + */ + eProsima_user_DllExport MinimalCollectionHeader( + MinimalCollectionHeader&& x) noexcept + { + m_common = std::move(x.m_common); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object MinimalCollectionHeader that will be copied. + */ + eProsima_user_DllExport MinimalCollectionHeader& operator =( + const MinimalCollectionHeader& x) + { + + m_common = x.m_common; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object MinimalCollectionHeader that will be copied. + */ + eProsima_user_DllExport MinimalCollectionHeader& operator =( + MinimalCollectionHeader&& x) noexcept + { + + m_common = std::move(x.m_common); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x MinimalCollectionHeader object to compare. + */ + eProsima_user_DllExport bool operator ==( + const MinimalCollectionHeader& x) const + { + return (m_common == x.m_common); + } + + /*! + * @brief Comparison operator. + * @param x MinimalCollectionHeader object to compare. + */ + eProsima_user_DllExport bool operator !=( + const MinimalCollectionHeader& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member common + * @param _common New value to be copied in member common + */ + eProsima_user_DllExport void common( + const CommonCollectionHeader& _common) + { + m_common = _common; + } + + /*! + * @brief This function moves the value in member common + * @param _common New value to be moved in member common + */ + eProsima_user_DllExport void common( + CommonCollectionHeader&& _common) + { + m_common = std::move(_common); + } + + /*! + * @brief This function returns a constant reference to member common + * @return Constant reference to member common + */ + eProsima_user_DllExport const CommonCollectionHeader& common() const + { + return m_common; + } + + /*! + * @brief This function returns a reference to member common + * @return Reference to member common + */ + eProsima_user_DllExport CommonCollectionHeader& common() + { + return m_common; + } + + + +private: + + CommonCollectionHeader m_common; + +}; +/*! + * @brief This class represents the structure CompleteSequenceType defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteSequenceType +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport CompleteSequenceType() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~CompleteSequenceType() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object CompleteSequenceType that will be copied. + */ + eProsima_user_DllExport CompleteSequenceType( + const CompleteSequenceType& x) + { + m_collection_flag = x.m_collection_flag; + + m_header = x.m_header; + + m_element = x.m_element; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object CompleteSequenceType that will be copied. + */ + eProsima_user_DllExport CompleteSequenceType( + CompleteSequenceType&& x) noexcept + { + m_collection_flag = std::move(x.m_collection_flag); + m_header = std::move(x.m_header); + m_element = std::move(x.m_element); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object CompleteSequenceType that will be copied. + */ + eProsima_user_DllExport CompleteSequenceType& operator =( + const CompleteSequenceType& x) + { + + m_collection_flag = x.m_collection_flag; + + m_header = x.m_header; + + m_element = x.m_element; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object CompleteSequenceType that will be copied. + */ + eProsima_user_DllExport CompleteSequenceType& operator =( + CompleteSequenceType&& x) noexcept + { + + m_collection_flag = std::move(x.m_collection_flag); + m_header = std::move(x.m_header); + m_element = std::move(x.m_element); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x CompleteSequenceType object to compare. + */ + eProsima_user_DllExport bool operator ==( + const CompleteSequenceType& x) const + { + return (m_collection_flag == x.m_collection_flag && + m_header == x.m_header && + m_element == x.m_element); + } + + /*! + * @brief Comparison operator. + * @param x CompleteSequenceType object to compare. + */ + eProsima_user_DllExport bool operator !=( + const CompleteSequenceType& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member collection_flag + * @param _collection_flag New value to be copied in member collection_flag + */ + eProsima_user_DllExport void collection_flag( + const CollectionTypeFlag& _collection_flag) + { + m_collection_flag = _collection_flag; + } + + /*! + * @brief This function moves the value in member collection_flag + * @param _collection_flag New value to be moved in member collection_flag + */ + eProsima_user_DllExport void collection_flag( + CollectionTypeFlag&& _collection_flag) + { + m_collection_flag = std::move(_collection_flag); + } + + /*! + * @brief This function returns a constant reference to member collection_flag + * @return Constant reference to member collection_flag + */ + eProsima_user_DllExport const CollectionTypeFlag& collection_flag() const + { + return m_collection_flag; + } + + /*! + * @brief This function returns a reference to member collection_flag + * @return Reference to member collection_flag + */ + eProsima_user_DllExport CollectionTypeFlag& collection_flag() + { + return m_collection_flag; + } + + + /*! + * @brief This function copies the value in member header + * @param _header New value to be copied in member header + */ + eProsima_user_DllExport void header( + const CompleteCollectionHeader& _header) + { + m_header = _header; + } + + /*! + * @brief This function moves the value in member header + * @param _header New value to be moved in member header + */ + eProsima_user_DllExport void header( + CompleteCollectionHeader&& _header) + { + m_header = std::move(_header); + } + + /*! + * @brief This function returns a constant reference to member header + * @return Constant reference to member header + */ + eProsima_user_DllExport const CompleteCollectionHeader& header() const + { + return m_header; + } + + /*! + * @brief This function returns a reference to member header + * @return Reference to member header + */ + eProsima_user_DllExport CompleteCollectionHeader& header() + { + return m_header; + } + + + /*! + * @brief This function copies the value in member element + * @param _element New value to be copied in member element + */ + eProsima_user_DllExport void element( + const CompleteCollectionElement& _element) + { + m_element = _element; + } + + /*! + * @brief This function moves the value in member element + * @param _element New value to be moved in member element + */ + eProsima_user_DllExport void element( + CompleteCollectionElement&& _element) + { + m_element = std::move(_element); + } + + /*! + * @brief This function returns a constant reference to member element + * @return Constant reference to member element + */ + eProsima_user_DllExport const CompleteCollectionElement& element() const + { + return m_element; + } + + /*! + * @brief This function returns a reference to member element + * @return Reference to member element + */ + eProsima_user_DllExport CompleteCollectionElement& element() + { + return m_element; + } + + + +private: + + CollectionTypeFlag m_collection_flag{0}; + CompleteCollectionHeader m_header; + CompleteCollectionElement m_element; + +}; +/*! + * @brief This class represents the structure MinimalSequenceType defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalSequenceType +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport MinimalSequenceType() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~MinimalSequenceType() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object MinimalSequenceType that will be copied. + */ + eProsima_user_DllExport MinimalSequenceType( + const MinimalSequenceType& x) + { + m_collection_flag = x.m_collection_flag; + + m_header = x.m_header; + + m_element = x.m_element; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object MinimalSequenceType that will be copied. + */ + eProsima_user_DllExport MinimalSequenceType( + MinimalSequenceType&& x) noexcept + { + m_collection_flag = std::move(x.m_collection_flag); + m_header = std::move(x.m_header); + m_element = std::move(x.m_element); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object MinimalSequenceType that will be copied. + */ + eProsima_user_DllExport MinimalSequenceType& operator =( + const MinimalSequenceType& x) + { + + m_collection_flag = x.m_collection_flag; + + m_header = x.m_header; + + m_element = x.m_element; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object MinimalSequenceType that will be copied. + */ + eProsima_user_DllExport MinimalSequenceType& operator =( + MinimalSequenceType&& x) noexcept + { + + m_collection_flag = std::move(x.m_collection_flag); + m_header = std::move(x.m_header); + m_element = std::move(x.m_element); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x MinimalSequenceType object to compare. + */ + eProsima_user_DllExport bool operator ==( + const MinimalSequenceType& x) const + { + return (m_collection_flag == x.m_collection_flag && + m_header == x.m_header && + m_element == x.m_element); + } + + /*! + * @brief Comparison operator. + * @param x MinimalSequenceType object to compare. + */ + eProsima_user_DllExport bool operator !=( + const MinimalSequenceType& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member collection_flag + * @param _collection_flag New value to be copied in member collection_flag + */ + eProsima_user_DllExport void collection_flag( + const CollectionTypeFlag& _collection_flag) + { + m_collection_flag = _collection_flag; + } + + /*! + * @brief This function moves the value in member collection_flag + * @param _collection_flag New value to be moved in member collection_flag + */ + eProsima_user_DllExport void collection_flag( + CollectionTypeFlag&& _collection_flag) + { + m_collection_flag = std::move(_collection_flag); + } + + /*! + * @brief This function returns a constant reference to member collection_flag + * @return Constant reference to member collection_flag + */ + eProsima_user_DllExport const CollectionTypeFlag& collection_flag() const + { + return m_collection_flag; + } + + /*! + * @brief This function returns a reference to member collection_flag + * @return Reference to member collection_flag + */ + eProsima_user_DllExport CollectionTypeFlag& collection_flag() + { + return m_collection_flag; + } + + + /*! + * @brief This function copies the value in member header + * @param _header New value to be copied in member header + */ + eProsima_user_DllExport void header( + const MinimalCollectionHeader& _header) + { + m_header = _header; + } + + /*! + * @brief This function moves the value in member header + * @param _header New value to be moved in member header + */ + eProsima_user_DllExport void header( + MinimalCollectionHeader&& _header) + { + m_header = std::move(_header); + } + + /*! + * @brief This function returns a constant reference to member header + * @return Constant reference to member header + */ + eProsima_user_DllExport const MinimalCollectionHeader& header() const + { + return m_header; + } + + /*! + * @brief This function returns a reference to member header + * @return Reference to member header + */ + eProsima_user_DllExport MinimalCollectionHeader& header() + { + return m_header; + } + + + /*! + * @brief This function copies the value in member element + * @param _element New value to be copied in member element + */ + eProsima_user_DllExport void element( + const MinimalCollectionElement& _element) + { + m_element = _element; + } + + /*! + * @brief This function moves the value in member element + * @param _element New value to be moved in member element + */ + eProsima_user_DllExport void element( + MinimalCollectionElement&& _element) + { + m_element = std::move(_element); + } + + /*! + * @brief This function returns a constant reference to member element + * @return Constant reference to member element + */ + eProsima_user_DllExport const MinimalCollectionElement& element() const + { + return m_element; + } + + /*! + * @brief This function returns a reference to member element + * @return Reference to member element + */ + eProsima_user_DllExport MinimalCollectionElement& element() + { + return m_element; + } + + + +private: + + CollectionTypeFlag m_collection_flag{0}; + MinimalCollectionHeader m_header; + MinimalCollectionElement m_element; + +}; +/*! + * @brief This class represents the structure CommonArrayHeader defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CommonArrayHeader +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport CommonArrayHeader() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~CommonArrayHeader() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object CommonArrayHeader that will be copied. + */ + eProsima_user_DllExport CommonArrayHeader( + const CommonArrayHeader& x) + { + m_bound_seq = x.m_bound_seq; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object CommonArrayHeader that will be copied. + */ + eProsima_user_DllExport CommonArrayHeader( + CommonArrayHeader&& x) noexcept + { + m_bound_seq = std::move(x.m_bound_seq); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object CommonArrayHeader that will be copied. + */ + eProsima_user_DllExport CommonArrayHeader& operator =( + const CommonArrayHeader& x) + { + + m_bound_seq = x.m_bound_seq; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object CommonArrayHeader that will be copied. + */ + eProsima_user_DllExport CommonArrayHeader& operator =( + CommonArrayHeader&& x) noexcept + { + + m_bound_seq = std::move(x.m_bound_seq); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x CommonArrayHeader object to compare. + */ + eProsima_user_DllExport bool operator ==( + const CommonArrayHeader& x) const + { + return (m_bound_seq == x.m_bound_seq); + } + + /*! + * @brief Comparison operator. + * @param x CommonArrayHeader object to compare. + */ + eProsima_user_DllExport bool operator !=( + const CommonArrayHeader& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member bound_seq + * @param _bound_seq New value to be copied in member bound_seq + */ + eProsima_user_DllExport void bound_seq( + const LBoundSeq& _bound_seq) + { + m_bound_seq = _bound_seq; + } + + /*! + * @brief This function moves the value in member bound_seq + * @param _bound_seq New value to be moved in member bound_seq + */ + eProsima_user_DllExport void bound_seq( + LBoundSeq&& _bound_seq) + { + m_bound_seq = std::move(_bound_seq); + } + + /*! + * @brief This function returns a constant reference to member bound_seq + * @return Constant reference to member bound_seq + */ + eProsima_user_DllExport const LBoundSeq& bound_seq() const + { + return m_bound_seq; + } + + /*! + * @brief This function returns a reference to member bound_seq + * @return Reference to member bound_seq + */ + eProsima_user_DllExport LBoundSeq& bound_seq() + { + return m_bound_seq; + } + + + +private: + + LBoundSeq m_bound_seq; + +}; +/*! + * @brief This class represents the structure CompleteArrayHeader defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteArrayHeader +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport CompleteArrayHeader() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~CompleteArrayHeader() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object CompleteArrayHeader that will be copied. + */ + eProsima_user_DllExport CompleteArrayHeader( + const CompleteArrayHeader& x) + { + m_common = x.m_common; + + m_detail = x.m_detail; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object CompleteArrayHeader that will be copied. + */ + eProsima_user_DllExport CompleteArrayHeader( + CompleteArrayHeader&& x) noexcept + { + m_common = std::move(x.m_common); + m_detail = std::move(x.m_detail); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object CompleteArrayHeader that will be copied. + */ + eProsima_user_DllExport CompleteArrayHeader& operator =( + const CompleteArrayHeader& x) + { + + m_common = x.m_common; + + m_detail = x.m_detail; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object CompleteArrayHeader that will be copied. + */ + eProsima_user_DllExport CompleteArrayHeader& operator =( + CompleteArrayHeader&& x) noexcept + { + + m_common = std::move(x.m_common); + m_detail = std::move(x.m_detail); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x CompleteArrayHeader object to compare. + */ + eProsima_user_DllExport bool operator ==( + const CompleteArrayHeader& x) const + { + return (m_common == x.m_common && + m_detail == x.m_detail); + } + + /*! + * @brief Comparison operator. + * @param x CompleteArrayHeader object to compare. + */ + eProsima_user_DllExport bool operator !=( + const CompleteArrayHeader& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member common + * @param _common New value to be copied in member common + */ + eProsima_user_DllExport void common( + const CommonArrayHeader& _common) + { + m_common = _common; + } + + /*! + * @brief This function moves the value in member common + * @param _common New value to be moved in member common + */ + eProsima_user_DllExport void common( + CommonArrayHeader&& _common) + { + m_common = std::move(_common); + } + + /*! + * @brief This function returns a constant reference to member common + * @return Constant reference to member common + */ + eProsima_user_DllExport const CommonArrayHeader& common() const + { + return m_common; + } + + /*! + * @brief This function returns a reference to member common + * @return Reference to member common + */ + eProsima_user_DllExport CommonArrayHeader& common() + { + return m_common; + } + + + /*! + * @brief This function copies the value in member detail + * @param _detail New value to be copied in member detail + */ + eProsima_user_DllExport void detail( + const CompleteTypeDetail& _detail) + { + m_detail = _detail; + } + + /*! + * @brief This function moves the value in member detail + * @param _detail New value to be moved in member detail + */ + eProsima_user_DllExport void detail( + CompleteTypeDetail&& _detail) + { + m_detail = std::move(_detail); + } + + /*! + * @brief This function returns a constant reference to member detail + * @return Constant reference to member detail + */ + eProsima_user_DllExport const CompleteTypeDetail& detail() const + { + return m_detail; + } + + /*! + * @brief This function returns a reference to member detail + * @return Reference to member detail + */ + eProsima_user_DllExport CompleteTypeDetail& detail() + { + return m_detail; + } + + + +private: + + CommonArrayHeader m_common; + CompleteTypeDetail m_detail; + +}; +/*! + * @brief This class represents the structure MinimalArrayHeader defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalArrayHeader +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport MinimalArrayHeader() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~MinimalArrayHeader() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object MinimalArrayHeader that will be copied. + */ + eProsima_user_DllExport MinimalArrayHeader( + const MinimalArrayHeader& x) + { + m_common = x.m_common; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object MinimalArrayHeader that will be copied. + */ + eProsima_user_DllExport MinimalArrayHeader( + MinimalArrayHeader&& x) noexcept + { + m_common = std::move(x.m_common); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object MinimalArrayHeader that will be copied. + */ + eProsima_user_DllExport MinimalArrayHeader& operator =( + const MinimalArrayHeader& x) + { + + m_common = x.m_common; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object MinimalArrayHeader that will be copied. + */ + eProsima_user_DllExport MinimalArrayHeader& operator =( + MinimalArrayHeader&& x) noexcept + { + + m_common = std::move(x.m_common); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x MinimalArrayHeader object to compare. + */ + eProsima_user_DllExport bool operator ==( + const MinimalArrayHeader& x) const + { + return (m_common == x.m_common); + } + + /*! + * @brief Comparison operator. + * @param x MinimalArrayHeader object to compare. + */ + eProsima_user_DllExport bool operator !=( + const MinimalArrayHeader& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member common + * @param _common New value to be copied in member common + */ + eProsima_user_DllExport void common( + const CommonArrayHeader& _common) + { + m_common = _common; + } + + /*! + * @brief This function moves the value in member common + * @param _common New value to be moved in member common + */ + eProsima_user_DllExport void common( + CommonArrayHeader&& _common) + { + m_common = std::move(_common); + } + + /*! + * @brief This function returns a constant reference to member common + * @return Constant reference to member common + */ + eProsima_user_DllExport const CommonArrayHeader& common() const + { + return m_common; + } + + /*! + * @brief This function returns a reference to member common + * @return Reference to member common + */ + eProsima_user_DllExport CommonArrayHeader& common() + { + return m_common; + } + + + +private: + + CommonArrayHeader m_common; + +}; +/*! + * @brief This class represents the structure CompleteArrayType defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteArrayType +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport CompleteArrayType() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~CompleteArrayType() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object CompleteArrayType that will be copied. + */ + eProsima_user_DllExport CompleteArrayType( + const CompleteArrayType& x) + { + m_collection_flag = x.m_collection_flag; + + m_header = x.m_header; + + m_element = x.m_element; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object CompleteArrayType that will be copied. + */ + eProsima_user_DllExport CompleteArrayType( + CompleteArrayType&& x) noexcept + { + m_collection_flag = std::move(x.m_collection_flag); + m_header = std::move(x.m_header); + m_element = std::move(x.m_element); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object CompleteArrayType that will be copied. + */ + eProsima_user_DllExport CompleteArrayType& operator =( + const CompleteArrayType& x) + { + + m_collection_flag = x.m_collection_flag; + + m_header = x.m_header; + + m_element = x.m_element; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object CompleteArrayType that will be copied. + */ + eProsima_user_DllExport CompleteArrayType& operator =( + CompleteArrayType&& x) noexcept + { + + m_collection_flag = std::move(x.m_collection_flag); + m_header = std::move(x.m_header); + m_element = std::move(x.m_element); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x CompleteArrayType object to compare. + */ + eProsima_user_DllExport bool operator ==( + const CompleteArrayType& x) const + { + return (m_collection_flag == x.m_collection_flag && + m_header == x.m_header && + m_element == x.m_element); + } + + /*! + * @brief Comparison operator. + * @param x CompleteArrayType object to compare. + */ + eProsima_user_DllExport bool operator !=( + const CompleteArrayType& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member collection_flag + * @param _collection_flag New value to be copied in member collection_flag + */ + eProsima_user_DllExport void collection_flag( + const CollectionTypeFlag& _collection_flag) + { + m_collection_flag = _collection_flag; + } + + /*! + * @brief This function moves the value in member collection_flag + * @param _collection_flag New value to be moved in member collection_flag + */ + eProsima_user_DllExport void collection_flag( + CollectionTypeFlag&& _collection_flag) + { + m_collection_flag = std::move(_collection_flag); + } + + /*! + * @brief This function returns a constant reference to member collection_flag + * @return Constant reference to member collection_flag + */ + eProsima_user_DllExport const CollectionTypeFlag& collection_flag() const + { + return m_collection_flag; + } + + /*! + * @brief This function returns a reference to member collection_flag + * @return Reference to member collection_flag + */ + eProsima_user_DllExport CollectionTypeFlag& collection_flag() + { + return m_collection_flag; + } + + + /*! + * @brief This function copies the value in member header + * @param _header New value to be copied in member header + */ + eProsima_user_DllExport void header( + const CompleteArrayHeader& _header) + { + m_header = _header; + } + + /*! + * @brief This function moves the value in member header + * @param _header New value to be moved in member header + */ + eProsima_user_DllExport void header( + CompleteArrayHeader&& _header) + { + m_header = std::move(_header); + } + + /*! + * @brief This function returns a constant reference to member header + * @return Constant reference to member header + */ + eProsima_user_DllExport const CompleteArrayHeader& header() const + { + return m_header; + } + + /*! + * @brief This function returns a reference to member header + * @return Reference to member header + */ + eProsima_user_DllExport CompleteArrayHeader& header() + { + return m_header; + } + + + /*! + * @brief This function copies the value in member element + * @param _element New value to be copied in member element + */ + eProsima_user_DllExport void element( + const CompleteCollectionElement& _element) + { + m_element = _element; + } + + /*! + * @brief This function moves the value in member element + * @param _element New value to be moved in member element + */ + eProsima_user_DllExport void element( + CompleteCollectionElement&& _element) + { + m_element = std::move(_element); + } + + /*! + * @brief This function returns a constant reference to member element + * @return Constant reference to member element + */ + eProsima_user_DllExport const CompleteCollectionElement& element() const + { + return m_element; + } + + /*! + * @brief This function returns a reference to member element + * @return Reference to member element + */ + eProsima_user_DllExport CompleteCollectionElement& element() + { + return m_element; + } + + + +private: + + CollectionTypeFlag m_collection_flag{0}; + CompleteArrayHeader m_header; + CompleteCollectionElement m_element; + +}; +/*! + * @brief This class represents the structure MinimalArrayType defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalArrayType +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport MinimalArrayType() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~MinimalArrayType() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object MinimalArrayType that will be copied. + */ + eProsima_user_DllExport MinimalArrayType( + const MinimalArrayType& x) + { + m_collection_flag = x.m_collection_flag; + + m_header = x.m_header; + + m_element = x.m_element; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object MinimalArrayType that will be copied. + */ + eProsima_user_DllExport MinimalArrayType( + MinimalArrayType&& x) noexcept + { + m_collection_flag = std::move(x.m_collection_flag); + m_header = std::move(x.m_header); + m_element = std::move(x.m_element); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object MinimalArrayType that will be copied. + */ + eProsima_user_DllExport MinimalArrayType& operator =( + const MinimalArrayType& x) + { + + m_collection_flag = x.m_collection_flag; + + m_header = x.m_header; + + m_element = x.m_element; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object MinimalArrayType that will be copied. + */ + eProsima_user_DllExport MinimalArrayType& operator =( + MinimalArrayType&& x) noexcept + { + + m_collection_flag = std::move(x.m_collection_flag); + m_header = std::move(x.m_header); + m_element = std::move(x.m_element); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x MinimalArrayType object to compare. + */ + eProsima_user_DllExport bool operator ==( + const MinimalArrayType& x) const + { + return (m_collection_flag == x.m_collection_flag && + m_header == x.m_header && + m_element == x.m_element); + } + + /*! + * @brief Comparison operator. + * @param x MinimalArrayType object to compare. + */ + eProsima_user_DllExport bool operator !=( + const MinimalArrayType& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member collection_flag + * @param _collection_flag New value to be copied in member collection_flag + */ + eProsima_user_DllExport void collection_flag( + const CollectionTypeFlag& _collection_flag) + { + m_collection_flag = _collection_flag; + } + + /*! + * @brief This function moves the value in member collection_flag + * @param _collection_flag New value to be moved in member collection_flag + */ + eProsima_user_DllExport void collection_flag( + CollectionTypeFlag&& _collection_flag) + { + m_collection_flag = std::move(_collection_flag); + } + + /*! + * @brief This function returns a constant reference to member collection_flag + * @return Constant reference to member collection_flag + */ + eProsima_user_DllExport const CollectionTypeFlag& collection_flag() const + { + return m_collection_flag; + } + + /*! + * @brief This function returns a reference to member collection_flag + * @return Reference to member collection_flag + */ + eProsima_user_DllExport CollectionTypeFlag& collection_flag() + { + return m_collection_flag; + } + + + /*! + * @brief This function copies the value in member header + * @param _header New value to be copied in member header + */ + eProsima_user_DllExport void header( + const MinimalArrayHeader& _header) + { + m_header = _header; + } + + /*! + * @brief This function moves the value in member header + * @param _header New value to be moved in member header + */ + eProsima_user_DllExport void header( + MinimalArrayHeader&& _header) + { + m_header = std::move(_header); + } + + /*! + * @brief This function returns a constant reference to member header + * @return Constant reference to member header + */ + eProsima_user_DllExport const MinimalArrayHeader& header() const + { + return m_header; + } + + /*! + * @brief This function returns a reference to member header + * @return Reference to member header + */ + eProsima_user_DllExport MinimalArrayHeader& header() + { + return m_header; + } + + + /*! + * @brief This function copies the value in member element + * @param _element New value to be copied in member element + */ + eProsima_user_DllExport void element( + const MinimalCollectionElement& _element) + { + m_element = _element; + } + + /*! + * @brief This function moves the value in member element + * @param _element New value to be moved in member element + */ + eProsima_user_DllExport void element( + MinimalCollectionElement&& _element) + { + m_element = std::move(_element); + } + + /*! + * @brief This function returns a constant reference to member element + * @return Constant reference to member element + */ + eProsima_user_DllExport const MinimalCollectionElement& element() const + { + return m_element; + } + + /*! + * @brief This function returns a reference to member element + * @return Reference to member element + */ + eProsima_user_DllExport MinimalCollectionElement& element() + { + return m_element; + } + + + +private: + + CollectionTypeFlag m_collection_flag{0}; + MinimalArrayHeader m_header; + MinimalCollectionElement m_element; + +}; +/*! + * @brief This class represents the structure CompleteMapType defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteMapType +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport CompleteMapType() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~CompleteMapType() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object CompleteMapType that will be copied. + */ + eProsima_user_DllExport CompleteMapType( + const CompleteMapType& x) + { + m_collection_flag = x.m_collection_flag; + + m_header = x.m_header; + + m_key = x.m_key; + + m_element = x.m_element; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object CompleteMapType that will be copied. + */ + eProsima_user_DllExport CompleteMapType( + CompleteMapType&& x) noexcept + { + m_collection_flag = std::move(x.m_collection_flag); + m_header = std::move(x.m_header); + m_key = std::move(x.m_key); + m_element = std::move(x.m_element); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object CompleteMapType that will be copied. + */ + eProsima_user_DllExport CompleteMapType& operator =( + const CompleteMapType& x) + { + + m_collection_flag = x.m_collection_flag; + + m_header = x.m_header; + + m_key = x.m_key; + + m_element = x.m_element; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object CompleteMapType that will be copied. + */ + eProsima_user_DllExport CompleteMapType& operator =( + CompleteMapType&& x) noexcept + { + + m_collection_flag = std::move(x.m_collection_flag); + m_header = std::move(x.m_header); + m_key = std::move(x.m_key); + m_element = std::move(x.m_element); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x CompleteMapType object to compare. + */ + eProsima_user_DllExport bool operator ==( + const CompleteMapType& x) const + { + return (m_collection_flag == x.m_collection_flag && + m_header == x.m_header && + m_key == x.m_key && + m_element == x.m_element); + } + + /*! + * @brief Comparison operator. + * @param x CompleteMapType object to compare. + */ + eProsima_user_DllExport bool operator !=( + const CompleteMapType& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member collection_flag + * @param _collection_flag New value to be copied in member collection_flag + */ + eProsima_user_DllExport void collection_flag( + const CollectionTypeFlag& _collection_flag) + { + m_collection_flag = _collection_flag; + } + + /*! + * @brief This function moves the value in member collection_flag + * @param _collection_flag New value to be moved in member collection_flag + */ + eProsima_user_DllExport void collection_flag( + CollectionTypeFlag&& _collection_flag) + { + m_collection_flag = std::move(_collection_flag); + } + + /*! + * @brief This function returns a constant reference to member collection_flag + * @return Constant reference to member collection_flag + */ + eProsima_user_DllExport const CollectionTypeFlag& collection_flag() const + { + return m_collection_flag; + } + + /*! + * @brief This function returns a reference to member collection_flag + * @return Reference to member collection_flag + */ + eProsima_user_DllExport CollectionTypeFlag& collection_flag() + { + return m_collection_flag; + } + + + /*! + * @brief This function copies the value in member header + * @param _header New value to be copied in member header + */ + eProsima_user_DllExport void header( + const CompleteCollectionHeader& _header) + { + m_header = _header; + } + + /*! + * @brief This function moves the value in member header + * @param _header New value to be moved in member header + */ + eProsima_user_DllExport void header( + CompleteCollectionHeader&& _header) + { + m_header = std::move(_header); + } + + /*! + * @brief This function returns a constant reference to member header + * @return Constant reference to member header + */ + eProsima_user_DllExport const CompleteCollectionHeader& header() const + { + return m_header; + } + + /*! + * @brief This function returns a reference to member header + * @return Reference to member header + */ + eProsima_user_DllExport CompleteCollectionHeader& header() + { + return m_header; + } + + + /*! + * @brief This function copies the value in member key + * @param _key New value to be copied in member key + */ + eProsima_user_DllExport void key( + const CompleteCollectionElement& _key) + { + m_key = _key; + } + + /*! + * @brief This function moves the value in member key + * @param _key New value to be moved in member key + */ + eProsima_user_DllExport void key( + CompleteCollectionElement&& _key) + { + m_key = std::move(_key); + } + + /*! + * @brief This function returns a constant reference to member key + * @return Constant reference to member key + */ + eProsima_user_DllExport const CompleteCollectionElement& key() const + { + return m_key; + } + + /*! + * @brief This function returns a reference to member key + * @return Reference to member key + */ + eProsima_user_DllExport CompleteCollectionElement& key() + { + return m_key; + } + + + /*! + * @brief This function copies the value in member element + * @param _element New value to be copied in member element + */ + eProsima_user_DllExport void element( + const CompleteCollectionElement& _element) + { + m_element = _element; + } + + /*! + * @brief This function moves the value in member element + * @param _element New value to be moved in member element + */ + eProsima_user_DllExport void element( + CompleteCollectionElement&& _element) + { + m_element = std::move(_element); + } + + /*! + * @brief This function returns a constant reference to member element + * @return Constant reference to member element + */ + eProsima_user_DllExport const CompleteCollectionElement& element() const + { + return m_element; + } + + /*! + * @brief This function returns a reference to member element + * @return Reference to member element + */ + eProsima_user_DllExport CompleteCollectionElement& element() + { + return m_element; + } + + + +private: + + CollectionTypeFlag m_collection_flag{0}; + CompleteCollectionHeader m_header; + CompleteCollectionElement m_key; + CompleteCollectionElement m_element; + +}; +/*! + * @brief This class represents the structure MinimalMapType defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalMapType +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport MinimalMapType() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~MinimalMapType() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object MinimalMapType that will be copied. + */ + eProsima_user_DllExport MinimalMapType( + const MinimalMapType& x) + { + m_collection_flag = x.m_collection_flag; + + m_header = x.m_header; + + m_key = x.m_key; + + m_element = x.m_element; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object MinimalMapType that will be copied. + */ + eProsima_user_DllExport MinimalMapType( + MinimalMapType&& x) noexcept + { + m_collection_flag = std::move(x.m_collection_flag); + m_header = std::move(x.m_header); + m_key = std::move(x.m_key); + m_element = std::move(x.m_element); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object MinimalMapType that will be copied. + */ + eProsima_user_DllExport MinimalMapType& operator =( + const MinimalMapType& x) + { + + m_collection_flag = x.m_collection_flag; + + m_header = x.m_header; + + m_key = x.m_key; + + m_element = x.m_element; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object MinimalMapType that will be copied. + */ + eProsima_user_DllExport MinimalMapType& operator =( + MinimalMapType&& x) noexcept + { + + m_collection_flag = std::move(x.m_collection_flag); + m_header = std::move(x.m_header); + m_key = std::move(x.m_key); + m_element = std::move(x.m_element); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x MinimalMapType object to compare. + */ + eProsima_user_DllExport bool operator ==( + const MinimalMapType& x) const + { + return (m_collection_flag == x.m_collection_flag && + m_header == x.m_header && + m_key == x.m_key && + m_element == x.m_element); + } + + /*! + * @brief Comparison operator. + * @param x MinimalMapType object to compare. + */ + eProsima_user_DllExport bool operator !=( + const MinimalMapType& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member collection_flag + * @param _collection_flag New value to be copied in member collection_flag + */ + eProsima_user_DllExport void collection_flag( + const CollectionTypeFlag& _collection_flag) + { + m_collection_flag = _collection_flag; + } + + /*! + * @brief This function moves the value in member collection_flag + * @param _collection_flag New value to be moved in member collection_flag + */ + eProsima_user_DllExport void collection_flag( + CollectionTypeFlag&& _collection_flag) + { + m_collection_flag = std::move(_collection_flag); + } + + /*! + * @brief This function returns a constant reference to member collection_flag + * @return Constant reference to member collection_flag + */ + eProsima_user_DllExport const CollectionTypeFlag& collection_flag() const + { + return m_collection_flag; + } + + /*! + * @brief This function returns a reference to member collection_flag + * @return Reference to member collection_flag + */ + eProsima_user_DllExport CollectionTypeFlag& collection_flag() + { + return m_collection_flag; + } + + + /*! + * @brief This function copies the value in member header + * @param _header New value to be copied in member header + */ + eProsima_user_DllExport void header( + const MinimalCollectionHeader& _header) + { + m_header = _header; + } + + /*! + * @brief This function moves the value in member header + * @param _header New value to be moved in member header + */ + eProsima_user_DllExport void header( + MinimalCollectionHeader&& _header) + { + m_header = std::move(_header); + } + + /*! + * @brief This function returns a constant reference to member header + * @return Constant reference to member header + */ + eProsima_user_DllExport const MinimalCollectionHeader& header() const + { + return m_header; + } + + /*! + * @brief This function returns a reference to member header + * @return Reference to member header + */ + eProsima_user_DllExport MinimalCollectionHeader& header() + { + return m_header; + } + + + /*! + * @brief This function copies the value in member key + * @param _key New value to be copied in member key + */ + eProsima_user_DllExport void key( + const MinimalCollectionElement& _key) + { + m_key = _key; + } + + /*! + * @brief This function moves the value in member key + * @param _key New value to be moved in member key + */ + eProsima_user_DllExport void key( + MinimalCollectionElement&& _key) + { + m_key = std::move(_key); + } + + /*! + * @brief This function returns a constant reference to member key + * @return Constant reference to member key + */ + eProsima_user_DllExport const MinimalCollectionElement& key() const + { + return m_key; + } + + /*! + * @brief This function returns a reference to member key + * @return Reference to member key + */ + eProsima_user_DllExport MinimalCollectionElement& key() + { + return m_key; + } + + + /*! + * @brief This function copies the value in member element + * @param _element New value to be copied in member element + */ + eProsima_user_DllExport void element( + const MinimalCollectionElement& _element) + { + m_element = _element; + } + + /*! + * @brief This function moves the value in member element + * @param _element New value to be moved in member element + */ + eProsima_user_DllExport void element( + MinimalCollectionElement&& _element) + { + m_element = std::move(_element); + } + + /*! + * @brief This function returns a constant reference to member element + * @return Constant reference to member element + */ + eProsima_user_DllExport const MinimalCollectionElement& element() const + { + return m_element; + } + + /*! + * @brief This function returns a reference to member element + * @return Reference to member element + */ + eProsima_user_DllExport MinimalCollectionElement& element() + { + return m_element; + } + + + +private: + + CollectionTypeFlag m_collection_flag{0}; + MinimalCollectionHeader m_header; + MinimalCollectionElement m_key; + MinimalCollectionElement m_element; + +}; +typedef uint16_t BitBound; + +/*! + * @brief This class represents the structure CommonEnumeratedLiteral defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CommonEnumeratedLiteral +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport CommonEnumeratedLiteral() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~CommonEnumeratedLiteral() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object CommonEnumeratedLiteral that will be copied. + */ + eProsima_user_DllExport CommonEnumeratedLiteral( + const CommonEnumeratedLiteral& x) + { + m_value = x.m_value; + + m_flags = x.m_flags; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object CommonEnumeratedLiteral that will be copied. + */ + eProsima_user_DllExport CommonEnumeratedLiteral( + CommonEnumeratedLiteral&& x) noexcept + { + m_value = x.m_value; + m_flags = std::move(x.m_flags); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object CommonEnumeratedLiteral that will be copied. + */ + eProsima_user_DllExport CommonEnumeratedLiteral& operator =( + const CommonEnumeratedLiteral& x) + { + + m_value = x.m_value; + + m_flags = x.m_flags; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object CommonEnumeratedLiteral that will be copied. + */ + eProsima_user_DllExport CommonEnumeratedLiteral& operator =( + CommonEnumeratedLiteral&& x) noexcept + { + + m_value = x.m_value; + m_flags = std::move(x.m_flags); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x CommonEnumeratedLiteral object to compare. + */ + eProsima_user_DllExport bool operator ==( + const CommonEnumeratedLiteral& x) const + { + return (m_value == x.m_value && + m_flags == x.m_flags); + } + + /*! + * @brief Comparison operator. + * @param x CommonEnumeratedLiteral object to compare. + */ + eProsima_user_DllExport bool operator !=( + const CommonEnumeratedLiteral& x) const + { + return !(*this == x); + } + + /*! + * @brief This function sets a value in member value + * @param _value New value for member value + */ + eProsima_user_DllExport void value( + int32_t _value) + { + m_value = _value; + } + + /*! + * @brief This function returns the value of member value + * @return Value of member value + */ + eProsima_user_DllExport int32_t value() const + { + return m_value; + } + + /*! + * @brief This function returns a reference to member value + * @return Reference to member value + */ + eProsima_user_DllExport int32_t& value() + { + return m_value; + } + + + /*! + * @brief This function copies the value in member flags + * @param _flags New value to be copied in member flags + */ + eProsima_user_DllExport void flags( + const EnumeratedLiteralFlag& _flags) + { + m_flags = _flags; + } + + /*! + * @brief This function moves the value in member flags + * @param _flags New value to be moved in member flags + */ + eProsima_user_DllExport void flags( + EnumeratedLiteralFlag&& _flags) + { + m_flags = std::move(_flags); + } + + /*! + * @brief This function returns a constant reference to member flags + * @return Constant reference to member flags + */ + eProsima_user_DllExport const EnumeratedLiteralFlag& flags() const + { + return m_flags; + } + + /*! + * @brief This function returns a reference to member flags + * @return Reference to member flags + */ + eProsima_user_DllExport EnumeratedLiteralFlag& flags() + { + return m_flags; + } + + + +private: + + int32_t m_value{0}; + EnumeratedLiteralFlag m_flags{0}; + +}; +/*! + * @brief This class represents the structure CompleteEnumeratedLiteral defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteEnumeratedLiteral +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport CompleteEnumeratedLiteral() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~CompleteEnumeratedLiteral() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object CompleteEnumeratedLiteral that will be copied. + */ + eProsima_user_DllExport CompleteEnumeratedLiteral( + const CompleteEnumeratedLiteral& x) + { + m_common = x.m_common; + + m_detail = x.m_detail; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object CompleteEnumeratedLiteral that will be copied. + */ + eProsima_user_DllExport CompleteEnumeratedLiteral( + CompleteEnumeratedLiteral&& x) noexcept + { + m_common = std::move(x.m_common); + m_detail = std::move(x.m_detail); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object CompleteEnumeratedLiteral that will be copied. + */ + eProsima_user_DllExport CompleteEnumeratedLiteral& operator =( + const CompleteEnumeratedLiteral& x) + { + + m_common = x.m_common; + + m_detail = x.m_detail; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object CompleteEnumeratedLiteral that will be copied. + */ + eProsima_user_DllExport CompleteEnumeratedLiteral& operator =( + CompleteEnumeratedLiteral&& x) noexcept + { + + m_common = std::move(x.m_common); + m_detail = std::move(x.m_detail); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x CompleteEnumeratedLiteral object to compare. + */ + eProsima_user_DllExport bool operator ==( + const CompleteEnumeratedLiteral& x) const + { + return (m_common == x.m_common && + m_detail == x.m_detail); + } + + /*! + * @brief Comparison operator. + * @param x CompleteEnumeratedLiteral object to compare. + */ + eProsima_user_DllExport bool operator !=( + const CompleteEnumeratedLiteral& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member common + * @param _common New value to be copied in member common + */ + eProsima_user_DllExport void common( + const CommonEnumeratedLiteral& _common) + { + m_common = _common; + } + + /*! + * @brief This function moves the value in member common + * @param _common New value to be moved in member common + */ + eProsima_user_DllExport void common( + CommonEnumeratedLiteral&& _common) + { + m_common = std::move(_common); + } + + /*! + * @brief This function returns a constant reference to member common + * @return Constant reference to member common + */ + eProsima_user_DllExport const CommonEnumeratedLiteral& common() const + { + return m_common; + } + + /*! + * @brief This function returns a reference to member common + * @return Reference to member common + */ + eProsima_user_DllExport CommonEnumeratedLiteral& common() + { + return m_common; + } + + + /*! + * @brief This function copies the value in member detail + * @param _detail New value to be copied in member detail + */ + eProsima_user_DllExport void detail( + const CompleteMemberDetail& _detail) + { + m_detail = _detail; + } + + /*! + * @brief This function moves the value in member detail + * @param _detail New value to be moved in member detail + */ + eProsima_user_DllExport void detail( + CompleteMemberDetail&& _detail) + { + m_detail = std::move(_detail); + } + + /*! + * @brief This function returns a constant reference to member detail + * @return Constant reference to member detail + */ + eProsima_user_DllExport const CompleteMemberDetail& detail() const + { + return m_detail; + } + + /*! + * @brief This function returns a reference to member detail + * @return Reference to member detail + */ + eProsima_user_DllExport CompleteMemberDetail& detail() + { + return m_detail; + } + + + +private: + + CommonEnumeratedLiteral m_common; + CompleteMemberDetail m_detail; + +}; +typedef std::vector CompleteEnumeratedLiteralSeq; + +/*! + * @brief This class represents the structure MinimalEnumeratedLiteral defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalEnumeratedLiteral +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport MinimalEnumeratedLiteral() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~MinimalEnumeratedLiteral() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object MinimalEnumeratedLiteral that will be copied. + */ + eProsima_user_DllExport MinimalEnumeratedLiteral( + const MinimalEnumeratedLiteral& x) + { + m_common = x.m_common; + + m_detail = x.m_detail; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object MinimalEnumeratedLiteral that will be copied. + */ + eProsima_user_DllExport MinimalEnumeratedLiteral( + MinimalEnumeratedLiteral&& x) noexcept + { + m_common = std::move(x.m_common); + m_detail = std::move(x.m_detail); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object MinimalEnumeratedLiteral that will be copied. + */ + eProsima_user_DllExport MinimalEnumeratedLiteral& operator =( + const MinimalEnumeratedLiteral& x) + { + + m_common = x.m_common; + + m_detail = x.m_detail; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object MinimalEnumeratedLiteral that will be copied. + */ + eProsima_user_DllExport MinimalEnumeratedLiteral& operator =( + MinimalEnumeratedLiteral&& x) noexcept + { + + m_common = std::move(x.m_common); + m_detail = std::move(x.m_detail); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x MinimalEnumeratedLiteral object to compare. + */ + eProsima_user_DllExport bool operator ==( + const MinimalEnumeratedLiteral& x) const + { + return (m_common == x.m_common && + m_detail == x.m_detail); + } + + /*! + * @brief Comparison operator. + * @param x MinimalEnumeratedLiteral object to compare. + */ + eProsima_user_DllExport bool operator !=( + const MinimalEnumeratedLiteral& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member common + * @param _common New value to be copied in member common + */ + eProsima_user_DllExport void common( + const CommonEnumeratedLiteral& _common) + { + m_common = _common; + } + + /*! + * @brief This function moves the value in member common + * @param _common New value to be moved in member common + */ + eProsima_user_DllExport void common( + CommonEnumeratedLiteral&& _common) + { + m_common = std::move(_common); + } + + /*! + * @brief This function returns a constant reference to member common + * @return Constant reference to member common + */ + eProsima_user_DllExport const CommonEnumeratedLiteral& common() const + { + return m_common; + } + + /*! + * @brief This function returns a reference to member common + * @return Reference to member common + */ + eProsima_user_DllExport CommonEnumeratedLiteral& common() + { + return m_common; + } + + + /*! + * @brief This function copies the value in member detail + * @param _detail New value to be copied in member detail + */ + eProsima_user_DllExport void detail( + const MinimalMemberDetail& _detail) + { + m_detail = _detail; + } + + /*! + * @brief This function moves the value in member detail + * @param _detail New value to be moved in member detail + */ + eProsima_user_DllExport void detail( + MinimalMemberDetail&& _detail) + { + m_detail = std::move(_detail); + } + + /*! + * @brief This function returns a constant reference to member detail + * @return Constant reference to member detail + */ + eProsima_user_DllExport const MinimalMemberDetail& detail() const + { + return m_detail; + } + + /*! + * @brief This function returns a reference to member detail + * @return Reference to member detail + */ + eProsima_user_DllExport MinimalMemberDetail& detail() + { + return m_detail; + } + + + +private: + + CommonEnumeratedLiteral m_common; + MinimalMemberDetail m_detail; + +}; +typedef std::vector MinimalEnumeratedLiteralSeq; + +/*! + * @brief This class represents the structure CommonEnumeratedHeader defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CommonEnumeratedHeader +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport CommonEnumeratedHeader() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~CommonEnumeratedHeader() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object CommonEnumeratedHeader that will be copied. + */ + eProsima_user_DllExport CommonEnumeratedHeader( + const CommonEnumeratedHeader& x) + { + m_bit_bound = x.m_bit_bound; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object CommonEnumeratedHeader that will be copied. + */ + eProsima_user_DllExport CommonEnumeratedHeader( + CommonEnumeratedHeader&& x) noexcept + { + m_bit_bound = x.m_bit_bound; + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object CommonEnumeratedHeader that will be copied. + */ + eProsima_user_DllExport CommonEnumeratedHeader& operator =( + const CommonEnumeratedHeader& x) + { + + m_bit_bound = x.m_bit_bound; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object CommonEnumeratedHeader that will be copied. + */ + eProsima_user_DllExport CommonEnumeratedHeader& operator =( + CommonEnumeratedHeader&& x) noexcept + { + + m_bit_bound = x.m_bit_bound; + return *this; + } + + /*! + * @brief Comparison operator. + * @param x CommonEnumeratedHeader object to compare. + */ + eProsima_user_DllExport bool operator ==( + const CommonEnumeratedHeader& x) const + { + return (m_bit_bound == x.m_bit_bound); + } + + /*! + * @brief Comparison operator. + * @param x CommonEnumeratedHeader object to compare. + */ + eProsima_user_DllExport bool operator !=( + const CommonEnumeratedHeader& x) const + { + return !(*this == x); + } + + /*! + * @brief This function sets a value in member bit_bound + * @param _bit_bound New value for member bit_bound + */ + eProsima_user_DllExport void bit_bound( + BitBound _bit_bound) + { + m_bit_bound = _bit_bound; + } + + /*! + * @brief This function returns the value of member bit_bound + * @return Value of member bit_bound + */ + eProsima_user_DllExport BitBound bit_bound() const + { + return m_bit_bound; + } + + /*! + * @brief This function returns a reference to member bit_bound + * @return Reference to member bit_bound + */ + eProsima_user_DllExport BitBound& bit_bound() + { + return m_bit_bound; + } + + + +private: + + BitBound m_bit_bound{0}; + +}; +/*! + * @brief This class represents the structure CompleteEnumeratedHeader defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteEnumeratedHeader +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport CompleteEnumeratedHeader() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~CompleteEnumeratedHeader() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object CompleteEnumeratedHeader that will be copied. + */ + eProsima_user_DllExport CompleteEnumeratedHeader( + const CompleteEnumeratedHeader& x) + { + m_common = x.m_common; + + m_detail = x.m_detail; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object CompleteEnumeratedHeader that will be copied. + */ + eProsima_user_DllExport CompleteEnumeratedHeader( + CompleteEnumeratedHeader&& x) noexcept + { + m_common = std::move(x.m_common); + m_detail = std::move(x.m_detail); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object CompleteEnumeratedHeader that will be copied. + */ + eProsima_user_DllExport CompleteEnumeratedHeader& operator =( + const CompleteEnumeratedHeader& x) + { + + m_common = x.m_common; + + m_detail = x.m_detail; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object CompleteEnumeratedHeader that will be copied. + */ + eProsima_user_DllExport CompleteEnumeratedHeader& operator =( + CompleteEnumeratedHeader&& x) noexcept + { + + m_common = std::move(x.m_common); + m_detail = std::move(x.m_detail); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x CompleteEnumeratedHeader object to compare. + */ + eProsima_user_DllExport bool operator ==( + const CompleteEnumeratedHeader& x) const + { + return (m_common == x.m_common && + m_detail == x.m_detail); + } + + /*! + * @brief Comparison operator. + * @param x CompleteEnumeratedHeader object to compare. + */ + eProsima_user_DllExport bool operator !=( + const CompleteEnumeratedHeader& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member common + * @param _common New value to be copied in member common + */ + eProsima_user_DllExport void common( + const CommonEnumeratedHeader& _common) + { + m_common = _common; + } + + /*! + * @brief This function moves the value in member common + * @param _common New value to be moved in member common + */ + eProsima_user_DllExport void common( + CommonEnumeratedHeader&& _common) + { + m_common = std::move(_common); + } + + /*! + * @brief This function returns a constant reference to member common + * @return Constant reference to member common + */ + eProsima_user_DllExport const CommonEnumeratedHeader& common() const + { + return m_common; + } + + /*! + * @brief This function returns a reference to member common + * @return Reference to member common + */ + eProsima_user_DllExport CommonEnumeratedHeader& common() + { + return m_common; + } + + + /*! + * @brief This function copies the value in member detail + * @param _detail New value to be copied in member detail + */ + eProsima_user_DllExport void detail( + const CompleteTypeDetail& _detail) + { + m_detail = _detail; + } + + /*! + * @brief This function moves the value in member detail + * @param _detail New value to be moved in member detail + */ + eProsima_user_DllExport void detail( + CompleteTypeDetail&& _detail) + { + m_detail = std::move(_detail); + } + + /*! + * @brief This function returns a constant reference to member detail + * @return Constant reference to member detail + */ + eProsima_user_DllExport const CompleteTypeDetail& detail() const + { + return m_detail; + } + + /*! + * @brief This function returns a reference to member detail + * @return Reference to member detail + */ + eProsima_user_DllExport CompleteTypeDetail& detail() + { + return m_detail; + } + + + +private: + + CommonEnumeratedHeader m_common; + CompleteTypeDetail m_detail; + +}; +/*! + * @brief This class represents the structure MinimalEnumeratedHeader defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalEnumeratedHeader +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport MinimalEnumeratedHeader() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~MinimalEnumeratedHeader() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object MinimalEnumeratedHeader that will be copied. + */ + eProsima_user_DllExport MinimalEnumeratedHeader( + const MinimalEnumeratedHeader& x) + { + m_common = x.m_common; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object MinimalEnumeratedHeader that will be copied. + */ + eProsima_user_DllExport MinimalEnumeratedHeader( + MinimalEnumeratedHeader&& x) noexcept + { + m_common = std::move(x.m_common); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object MinimalEnumeratedHeader that will be copied. + */ + eProsima_user_DllExport MinimalEnumeratedHeader& operator =( + const MinimalEnumeratedHeader& x) + { + + m_common = x.m_common; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object MinimalEnumeratedHeader that will be copied. + */ + eProsima_user_DllExport MinimalEnumeratedHeader& operator =( + MinimalEnumeratedHeader&& x) noexcept + { + + m_common = std::move(x.m_common); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x MinimalEnumeratedHeader object to compare. + */ + eProsima_user_DllExport bool operator ==( + const MinimalEnumeratedHeader& x) const + { + return (m_common == x.m_common); + } + + /*! + * @brief Comparison operator. + * @param x MinimalEnumeratedHeader object to compare. + */ + eProsima_user_DllExport bool operator !=( + const MinimalEnumeratedHeader& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member common + * @param _common New value to be copied in member common + */ + eProsima_user_DllExport void common( + const CommonEnumeratedHeader& _common) + { + m_common = _common; + } + + /*! + * @brief This function moves the value in member common + * @param _common New value to be moved in member common + */ + eProsima_user_DllExport void common( + CommonEnumeratedHeader&& _common) + { + m_common = std::move(_common); + } + + /*! + * @brief This function returns a constant reference to member common + * @return Constant reference to member common + */ + eProsima_user_DllExport const CommonEnumeratedHeader& common() const + { + return m_common; + } + + /*! + * @brief This function returns a reference to member common + * @return Reference to member common + */ + eProsima_user_DllExport CommonEnumeratedHeader& common() + { + return m_common; + } + + + +private: + + CommonEnumeratedHeader m_common; + +}; +/*! + * @brief This class represents the structure CompleteEnumeratedType defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteEnumeratedType +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport CompleteEnumeratedType() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~CompleteEnumeratedType() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object CompleteEnumeratedType that will be copied. + */ + eProsima_user_DllExport CompleteEnumeratedType( + const CompleteEnumeratedType& x) + { + m_enum_flags = x.m_enum_flags; + + m_header = x.m_header; + + m_literal_seq = x.m_literal_seq; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object CompleteEnumeratedType that will be copied. + */ + eProsima_user_DllExport CompleteEnumeratedType( + CompleteEnumeratedType&& x) noexcept + { + m_enum_flags = std::move(x.m_enum_flags); + m_header = std::move(x.m_header); + m_literal_seq = std::move(x.m_literal_seq); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object CompleteEnumeratedType that will be copied. + */ + eProsima_user_DllExport CompleteEnumeratedType& operator =( + const CompleteEnumeratedType& x) + { + + m_enum_flags = x.m_enum_flags; + + m_header = x.m_header; + + m_literal_seq = x.m_literal_seq; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object CompleteEnumeratedType that will be copied. + */ + eProsima_user_DllExport CompleteEnumeratedType& operator =( + CompleteEnumeratedType&& x) noexcept + { + + m_enum_flags = std::move(x.m_enum_flags); + m_header = std::move(x.m_header); + m_literal_seq = std::move(x.m_literal_seq); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x CompleteEnumeratedType object to compare. + */ + eProsima_user_DllExport bool operator ==( + const CompleteEnumeratedType& x) const + { + return (m_enum_flags == x.m_enum_flags && + m_header == x.m_header && + m_literal_seq == x.m_literal_seq); + } + + /*! + * @brief Comparison operator. + * @param x CompleteEnumeratedType object to compare. + */ + eProsima_user_DllExport bool operator !=( + const CompleteEnumeratedType& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member enum_flags + * @param _enum_flags New value to be copied in member enum_flags + */ + eProsima_user_DllExport void enum_flags( + const EnumTypeFlag& _enum_flags) + { + m_enum_flags = _enum_flags; + } + + /*! + * @brief This function moves the value in member enum_flags + * @param _enum_flags New value to be moved in member enum_flags + */ + eProsima_user_DllExport void enum_flags( + EnumTypeFlag&& _enum_flags) + { + m_enum_flags = std::move(_enum_flags); + } + + /*! + * @brief This function returns a constant reference to member enum_flags + * @return Constant reference to member enum_flags + */ + eProsima_user_DllExport const EnumTypeFlag& enum_flags() const + { + return m_enum_flags; + } + + /*! + * @brief This function returns a reference to member enum_flags + * @return Reference to member enum_flags + */ + eProsima_user_DllExport EnumTypeFlag& enum_flags() + { + return m_enum_flags; + } + + + /*! + * @brief This function copies the value in member header + * @param _header New value to be copied in member header + */ + eProsima_user_DllExport void header( + const CompleteEnumeratedHeader& _header) + { + m_header = _header; + } + + /*! + * @brief This function moves the value in member header + * @param _header New value to be moved in member header + */ + eProsima_user_DllExport void header( + CompleteEnumeratedHeader&& _header) + { + m_header = std::move(_header); + } + + /*! + * @brief This function returns a constant reference to member header + * @return Constant reference to member header + */ + eProsima_user_DllExport const CompleteEnumeratedHeader& header() const + { + return m_header; + } + + /*! + * @brief This function returns a reference to member header + * @return Reference to member header + */ + eProsima_user_DllExport CompleteEnumeratedHeader& header() + { + return m_header; + } + + + /*! + * @brief This function copies the value in member literal_seq + * @param _literal_seq New value to be copied in member literal_seq + */ + eProsima_user_DllExport void literal_seq( + const CompleteEnumeratedLiteralSeq& _literal_seq) + { + m_literal_seq = _literal_seq; + } + + /*! + * @brief This function moves the value in member literal_seq + * @param _literal_seq New value to be moved in member literal_seq + */ + eProsima_user_DllExport void literal_seq( + CompleteEnumeratedLiteralSeq&& _literal_seq) + { + m_literal_seq = std::move(_literal_seq); + } + + /*! + * @brief This function returns a constant reference to member literal_seq + * @return Constant reference to member literal_seq + */ + eProsima_user_DllExport const CompleteEnumeratedLiteralSeq& literal_seq() const + { + return m_literal_seq; + } + + /*! + * @brief This function returns a reference to member literal_seq + * @return Reference to member literal_seq + */ + eProsima_user_DllExport CompleteEnumeratedLiteralSeq& literal_seq() + { + return m_literal_seq; + } + + + +private: + + EnumTypeFlag m_enum_flags{0}; + CompleteEnumeratedHeader m_header; + CompleteEnumeratedLiteralSeq m_literal_seq; + +}; +/*! + * @brief This class represents the structure MinimalEnumeratedType defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalEnumeratedType +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport MinimalEnumeratedType() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~MinimalEnumeratedType() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object MinimalEnumeratedType that will be copied. + */ + eProsima_user_DllExport MinimalEnumeratedType( + const MinimalEnumeratedType& x) + { + m_enum_flags = x.m_enum_flags; + + m_header = x.m_header; + + m_literal_seq = x.m_literal_seq; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object MinimalEnumeratedType that will be copied. + */ + eProsima_user_DllExport MinimalEnumeratedType( + MinimalEnumeratedType&& x) noexcept + { + m_enum_flags = std::move(x.m_enum_flags); + m_header = std::move(x.m_header); + m_literal_seq = std::move(x.m_literal_seq); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object MinimalEnumeratedType that will be copied. + */ + eProsima_user_DllExport MinimalEnumeratedType& operator =( + const MinimalEnumeratedType& x) + { + + m_enum_flags = x.m_enum_flags; + + m_header = x.m_header; + + m_literal_seq = x.m_literal_seq; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object MinimalEnumeratedType that will be copied. + */ + eProsima_user_DllExport MinimalEnumeratedType& operator =( + MinimalEnumeratedType&& x) noexcept + { + + m_enum_flags = std::move(x.m_enum_flags); + m_header = std::move(x.m_header); + m_literal_seq = std::move(x.m_literal_seq); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x MinimalEnumeratedType object to compare. + */ + eProsima_user_DllExport bool operator ==( + const MinimalEnumeratedType& x) const + { + return (m_enum_flags == x.m_enum_flags && + m_header == x.m_header && + m_literal_seq == x.m_literal_seq); + } + + /*! + * @brief Comparison operator. + * @param x MinimalEnumeratedType object to compare. + */ + eProsima_user_DllExport bool operator !=( + const MinimalEnumeratedType& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member enum_flags + * @param _enum_flags New value to be copied in member enum_flags + */ + eProsima_user_DllExport void enum_flags( + const EnumTypeFlag& _enum_flags) + { + m_enum_flags = _enum_flags; + } + + /*! + * @brief This function moves the value in member enum_flags + * @param _enum_flags New value to be moved in member enum_flags + */ + eProsima_user_DllExport void enum_flags( + EnumTypeFlag&& _enum_flags) + { + m_enum_flags = std::move(_enum_flags); + } + + /*! + * @brief This function returns a constant reference to member enum_flags + * @return Constant reference to member enum_flags + */ + eProsima_user_DllExport const EnumTypeFlag& enum_flags() const + { + return m_enum_flags; + } + + /*! + * @brief This function returns a reference to member enum_flags + * @return Reference to member enum_flags + */ + eProsima_user_DllExport EnumTypeFlag& enum_flags() + { + return m_enum_flags; + } + + + /*! + * @brief This function copies the value in member header + * @param _header New value to be copied in member header + */ + eProsima_user_DllExport void header( + const MinimalEnumeratedHeader& _header) + { + m_header = _header; + } + + /*! + * @brief This function moves the value in member header + * @param _header New value to be moved in member header + */ + eProsima_user_DllExport void header( + MinimalEnumeratedHeader&& _header) + { + m_header = std::move(_header); + } + + /*! + * @brief This function returns a constant reference to member header + * @return Constant reference to member header + */ + eProsima_user_DllExport const MinimalEnumeratedHeader& header() const + { + return m_header; + } + + /*! + * @brief This function returns a reference to member header + * @return Reference to member header + */ + eProsima_user_DllExport MinimalEnumeratedHeader& header() + { + return m_header; + } + + + /*! + * @brief This function copies the value in member literal_seq + * @param _literal_seq New value to be copied in member literal_seq + */ + eProsima_user_DllExport void literal_seq( + const MinimalEnumeratedLiteralSeq& _literal_seq) + { + m_literal_seq = _literal_seq; + } + + /*! + * @brief This function moves the value in member literal_seq + * @param _literal_seq New value to be moved in member literal_seq + */ + eProsima_user_DllExport void literal_seq( + MinimalEnumeratedLiteralSeq&& _literal_seq) + { + m_literal_seq = std::move(_literal_seq); + } + + /*! + * @brief This function returns a constant reference to member literal_seq + * @return Constant reference to member literal_seq + */ + eProsima_user_DllExport const MinimalEnumeratedLiteralSeq& literal_seq() const + { + return m_literal_seq; + } + + /*! + * @brief This function returns a reference to member literal_seq + * @return Reference to member literal_seq + */ + eProsima_user_DllExport MinimalEnumeratedLiteralSeq& literal_seq() + { + return m_literal_seq; + } + + + +private: + + EnumTypeFlag m_enum_flags{0}; + MinimalEnumeratedHeader m_header; + MinimalEnumeratedLiteralSeq m_literal_seq; + +}; +/*! + * @brief This class represents the structure CommonBitflag defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CommonBitflag +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport CommonBitflag() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~CommonBitflag() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object CommonBitflag that will be copied. + */ + eProsima_user_DllExport CommonBitflag( + const CommonBitflag& x) + { + m_position = x.m_position; + + m_flags = x.m_flags; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object CommonBitflag that will be copied. + */ + eProsima_user_DllExport CommonBitflag( + CommonBitflag&& x) noexcept + { + m_position = x.m_position; + m_flags = std::move(x.m_flags); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object CommonBitflag that will be copied. + */ + eProsima_user_DllExport CommonBitflag& operator =( + const CommonBitflag& x) + { + + m_position = x.m_position; + + m_flags = x.m_flags; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object CommonBitflag that will be copied. + */ + eProsima_user_DllExport CommonBitflag& operator =( + CommonBitflag&& x) noexcept + { + + m_position = x.m_position; + m_flags = std::move(x.m_flags); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x CommonBitflag object to compare. + */ + eProsima_user_DllExport bool operator ==( + const CommonBitflag& x) const + { + return (m_position == x.m_position && + m_flags == x.m_flags); + } + + /*! + * @brief Comparison operator. + * @param x CommonBitflag object to compare. + */ + eProsima_user_DllExport bool operator !=( + const CommonBitflag& x) const + { + return !(*this == x); + } + + /*! + * @brief This function sets a value in member position + * @param _position New value for member position + */ + eProsima_user_DllExport void position( + uint16_t _position) + { + m_position = _position; + } + + /*! + * @brief This function returns the value of member position + * @return Value of member position + */ + eProsima_user_DllExport uint16_t position() const + { + return m_position; + } + + /*! + * @brief This function returns a reference to member position + * @return Reference to member position + */ + eProsima_user_DllExport uint16_t& position() + { + return m_position; + } + + + /*! + * @brief This function copies the value in member flags + * @param _flags New value to be copied in member flags + */ + eProsima_user_DllExport void flags( + const BitflagFlag& _flags) + { + m_flags = _flags; + } + + /*! + * @brief This function moves the value in member flags + * @param _flags New value to be moved in member flags + */ + eProsima_user_DllExport void flags( + BitflagFlag&& _flags) + { + m_flags = std::move(_flags); + } + + /*! + * @brief This function returns a constant reference to member flags + * @return Constant reference to member flags + */ + eProsima_user_DllExport const BitflagFlag& flags() const + { + return m_flags; + } + + /*! + * @brief This function returns a reference to member flags + * @return Reference to member flags + */ + eProsima_user_DllExport BitflagFlag& flags() + { + return m_flags; + } + + + +private: + + uint16_t m_position{0}; + BitflagFlag m_flags{0}; + +}; +/*! + * @brief This class represents the structure CompleteBitflag defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteBitflag +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport CompleteBitflag() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~CompleteBitflag() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object CompleteBitflag that will be copied. + */ + eProsima_user_DllExport CompleteBitflag( + const CompleteBitflag& x) + { + m_common = x.m_common; + + m_detail = x.m_detail; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object CompleteBitflag that will be copied. + */ + eProsima_user_DllExport CompleteBitflag( + CompleteBitflag&& x) noexcept + { + m_common = std::move(x.m_common); + m_detail = std::move(x.m_detail); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object CompleteBitflag that will be copied. + */ + eProsima_user_DllExport CompleteBitflag& operator =( + const CompleteBitflag& x) + { + + m_common = x.m_common; + + m_detail = x.m_detail; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object CompleteBitflag that will be copied. + */ + eProsima_user_DllExport CompleteBitflag& operator =( + CompleteBitflag&& x) noexcept + { + + m_common = std::move(x.m_common); + m_detail = std::move(x.m_detail); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x CompleteBitflag object to compare. + */ + eProsima_user_DllExport bool operator ==( + const CompleteBitflag& x) const + { + return (m_common == x.m_common && + m_detail == x.m_detail); + } + + /*! + * @brief Comparison operator. + * @param x CompleteBitflag object to compare. + */ + eProsima_user_DllExport bool operator !=( + const CompleteBitflag& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member common + * @param _common New value to be copied in member common + */ + eProsima_user_DllExport void common( + const CommonBitflag& _common) + { + m_common = _common; + } + + /*! + * @brief This function moves the value in member common + * @param _common New value to be moved in member common + */ + eProsima_user_DllExport void common( + CommonBitflag&& _common) + { + m_common = std::move(_common); + } + + /*! + * @brief This function returns a constant reference to member common + * @return Constant reference to member common + */ + eProsima_user_DllExport const CommonBitflag& common() const + { + return m_common; + } + + /*! + * @brief This function returns a reference to member common + * @return Reference to member common + */ + eProsima_user_DllExport CommonBitflag& common() + { + return m_common; + } + + + /*! + * @brief This function copies the value in member detail + * @param _detail New value to be copied in member detail + */ + eProsima_user_DllExport void detail( + const CompleteMemberDetail& _detail) + { + m_detail = _detail; + } + + /*! + * @brief This function moves the value in member detail + * @param _detail New value to be moved in member detail + */ + eProsima_user_DllExport void detail( + CompleteMemberDetail&& _detail) + { + m_detail = std::move(_detail); + } + + /*! + * @brief This function returns a constant reference to member detail + * @return Constant reference to member detail + */ + eProsima_user_DllExport const CompleteMemberDetail& detail() const + { + return m_detail; + } + + /*! + * @brief This function returns a reference to member detail + * @return Reference to member detail + */ + eProsima_user_DllExport CompleteMemberDetail& detail() + { + return m_detail; + } + + + +private: + + CommonBitflag m_common; + CompleteMemberDetail m_detail; + +}; +typedef std::vector CompleteBitflagSeq; + +/*! + * @brief This class represents the structure MinimalBitflag defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalBitflag +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport MinimalBitflag() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~MinimalBitflag() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object MinimalBitflag that will be copied. + */ + eProsima_user_DllExport MinimalBitflag( + const MinimalBitflag& x) + { + m_common = x.m_common; + + m_detail = x.m_detail; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object MinimalBitflag that will be copied. + */ + eProsima_user_DllExport MinimalBitflag( + MinimalBitflag&& x) noexcept + { + m_common = std::move(x.m_common); + m_detail = std::move(x.m_detail); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object MinimalBitflag that will be copied. + */ + eProsima_user_DllExport MinimalBitflag& operator =( + const MinimalBitflag& x) + { + + m_common = x.m_common; + + m_detail = x.m_detail; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object MinimalBitflag that will be copied. + */ + eProsima_user_DllExport MinimalBitflag& operator =( + MinimalBitflag&& x) noexcept + { + + m_common = std::move(x.m_common); + m_detail = std::move(x.m_detail); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x MinimalBitflag object to compare. + */ + eProsima_user_DllExport bool operator ==( + const MinimalBitflag& x) const + { + return (m_common == x.m_common && + m_detail == x.m_detail); + } + + /*! + * @brief Comparison operator. + * @param x MinimalBitflag object to compare. + */ + eProsima_user_DllExport bool operator !=( + const MinimalBitflag& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member common + * @param _common New value to be copied in member common + */ + eProsima_user_DllExport void common( + const CommonBitflag& _common) + { + m_common = _common; + } + + /*! + * @brief This function moves the value in member common + * @param _common New value to be moved in member common + */ + eProsima_user_DllExport void common( + CommonBitflag&& _common) + { + m_common = std::move(_common); + } + + /*! + * @brief This function returns a constant reference to member common + * @return Constant reference to member common + */ + eProsima_user_DllExport const CommonBitflag& common() const + { + return m_common; + } + + /*! + * @brief This function returns a reference to member common + * @return Reference to member common + */ + eProsima_user_DllExport CommonBitflag& common() + { + return m_common; + } + + + /*! + * @brief This function copies the value in member detail + * @param _detail New value to be copied in member detail + */ + eProsima_user_DllExport void detail( + const MinimalMemberDetail& _detail) + { + m_detail = _detail; + } + + /*! + * @brief This function moves the value in member detail + * @param _detail New value to be moved in member detail + */ + eProsima_user_DllExport void detail( + MinimalMemberDetail&& _detail) + { + m_detail = std::move(_detail); + } + + /*! + * @brief This function returns a constant reference to member detail + * @return Constant reference to member detail + */ + eProsima_user_DllExport const MinimalMemberDetail& detail() const + { + return m_detail; + } + + /*! + * @brief This function returns a reference to member detail + * @return Reference to member detail + */ + eProsima_user_DllExport MinimalMemberDetail& detail() + { + return m_detail; + } + + + +private: + + CommonBitflag m_common; + MinimalMemberDetail m_detail; + +}; +typedef std::vector MinimalBitflagSeq; + +/*! + * @brief This class represents the structure CommonBitmaskHeader defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CommonBitmaskHeader +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport CommonBitmaskHeader() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~CommonBitmaskHeader() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object CommonBitmaskHeader that will be copied. + */ + eProsima_user_DllExport CommonBitmaskHeader( + const CommonBitmaskHeader& x) + { + m_bit_bound = x.m_bit_bound; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object CommonBitmaskHeader that will be copied. + */ + eProsima_user_DllExport CommonBitmaskHeader( + CommonBitmaskHeader&& x) noexcept + { + m_bit_bound = x.m_bit_bound; + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object CommonBitmaskHeader that will be copied. + */ + eProsima_user_DllExport CommonBitmaskHeader& operator =( + const CommonBitmaskHeader& x) + { + + m_bit_bound = x.m_bit_bound; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object CommonBitmaskHeader that will be copied. + */ + eProsima_user_DllExport CommonBitmaskHeader& operator =( + CommonBitmaskHeader&& x) noexcept + { + + m_bit_bound = x.m_bit_bound; + return *this; + } + + /*! + * @brief Comparison operator. + * @param x CommonBitmaskHeader object to compare. + */ + eProsima_user_DllExport bool operator ==( + const CommonBitmaskHeader& x) const + { + return (m_bit_bound == x.m_bit_bound); + } + + /*! + * @brief Comparison operator. + * @param x CommonBitmaskHeader object to compare. + */ + eProsima_user_DllExport bool operator !=( + const CommonBitmaskHeader& x) const + { + return !(*this == x); + } + + /*! + * @brief This function sets a value in member bit_bound + * @param _bit_bound New value for member bit_bound + */ + eProsima_user_DllExport void bit_bound( + BitBound _bit_bound) + { + m_bit_bound = _bit_bound; + } + + /*! + * @brief This function returns the value of member bit_bound + * @return Value of member bit_bound + */ + eProsima_user_DllExport BitBound bit_bound() const + { + return m_bit_bound; + } + + /*! + * @brief This function returns a reference to member bit_bound + * @return Reference to member bit_bound + */ + eProsima_user_DllExport BitBound& bit_bound() + { + return m_bit_bound; + } + + + +private: + + BitBound m_bit_bound{0}; + +}; +typedef CompleteEnumeratedHeader CompleteBitmaskHeader; + +typedef MinimalEnumeratedHeader MinimalBitmaskHeader; + +/*! + * @brief This class represents the structure CompleteBitmaskType defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteBitmaskType +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport CompleteBitmaskType() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~CompleteBitmaskType() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object CompleteBitmaskType that will be copied. + */ + eProsima_user_DllExport CompleteBitmaskType( + const CompleteBitmaskType& x) + { + m_bitmask_flags = x.m_bitmask_flags; + + m_header = x.m_header; + + m_flag_seq = x.m_flag_seq; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object CompleteBitmaskType that will be copied. + */ + eProsima_user_DllExport CompleteBitmaskType( + CompleteBitmaskType&& x) noexcept + { + m_bitmask_flags = std::move(x.m_bitmask_flags); + m_header = std::move(x.m_header); + m_flag_seq = std::move(x.m_flag_seq); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object CompleteBitmaskType that will be copied. + */ + eProsima_user_DllExport CompleteBitmaskType& operator =( + const CompleteBitmaskType& x) + { + + m_bitmask_flags = x.m_bitmask_flags; + + m_header = x.m_header; + + m_flag_seq = x.m_flag_seq; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object CompleteBitmaskType that will be copied. + */ + eProsima_user_DllExport CompleteBitmaskType& operator =( + CompleteBitmaskType&& x) noexcept + { + + m_bitmask_flags = std::move(x.m_bitmask_flags); + m_header = std::move(x.m_header); + m_flag_seq = std::move(x.m_flag_seq); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x CompleteBitmaskType object to compare. + */ + eProsima_user_DllExport bool operator ==( + const CompleteBitmaskType& x) const + { + return (m_bitmask_flags == x.m_bitmask_flags && + m_header == x.m_header && + m_flag_seq == x.m_flag_seq); + } + + /*! + * @brief Comparison operator. + * @param x CompleteBitmaskType object to compare. + */ + eProsima_user_DllExport bool operator !=( + const CompleteBitmaskType& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member bitmask_flags + * @param _bitmask_flags New value to be copied in member bitmask_flags + */ + eProsima_user_DllExport void bitmask_flags( + const BitmaskTypeFlag& _bitmask_flags) + { + m_bitmask_flags = _bitmask_flags; + } + + /*! + * @brief This function moves the value in member bitmask_flags + * @param _bitmask_flags New value to be moved in member bitmask_flags + */ + eProsima_user_DllExport void bitmask_flags( + BitmaskTypeFlag&& _bitmask_flags) + { + m_bitmask_flags = std::move(_bitmask_flags); + } + + /*! + * @brief This function returns a constant reference to member bitmask_flags + * @return Constant reference to member bitmask_flags + */ + eProsima_user_DllExport const BitmaskTypeFlag& bitmask_flags() const + { + return m_bitmask_flags; + } + + /*! + * @brief This function returns a reference to member bitmask_flags + * @return Reference to member bitmask_flags + */ + eProsima_user_DllExport BitmaskTypeFlag& bitmask_flags() + { + return m_bitmask_flags; + } + + + /*! + * @brief This function copies the value in member header + * @param _header New value to be copied in member header + */ + eProsima_user_DllExport void header( + const CompleteBitmaskHeader& _header) + { + m_header = _header; + } + + /*! + * @brief This function moves the value in member header + * @param _header New value to be moved in member header + */ + eProsima_user_DllExport void header( + CompleteBitmaskHeader&& _header) + { + m_header = std::move(_header); + } + + /*! + * @brief This function returns a constant reference to member header + * @return Constant reference to member header + */ + eProsima_user_DllExport const CompleteBitmaskHeader& header() const + { + return m_header; + } + + /*! + * @brief This function returns a reference to member header + * @return Reference to member header + */ + eProsima_user_DllExport CompleteBitmaskHeader& header() + { + return m_header; + } + + + /*! + * @brief This function copies the value in member flag_seq + * @param _flag_seq New value to be copied in member flag_seq + */ + eProsima_user_DllExport void flag_seq( + const CompleteBitflagSeq& _flag_seq) + { + m_flag_seq = _flag_seq; + } + + /*! + * @brief This function moves the value in member flag_seq + * @param _flag_seq New value to be moved in member flag_seq + */ + eProsima_user_DllExport void flag_seq( + CompleteBitflagSeq&& _flag_seq) + { + m_flag_seq = std::move(_flag_seq); + } + + /*! + * @brief This function returns a constant reference to member flag_seq + * @return Constant reference to member flag_seq + */ + eProsima_user_DllExport const CompleteBitflagSeq& flag_seq() const + { + return m_flag_seq; + } + + /*! + * @brief This function returns a reference to member flag_seq + * @return Reference to member flag_seq + */ + eProsima_user_DllExport CompleteBitflagSeq& flag_seq() + { + return m_flag_seq; + } + + + +private: + + BitmaskTypeFlag m_bitmask_flags{0}; + CompleteBitmaskHeader m_header; + CompleteBitflagSeq m_flag_seq; + +}; +/*! + * @brief This class represents the structure MinimalBitmaskType defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalBitmaskType +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport MinimalBitmaskType() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~MinimalBitmaskType() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object MinimalBitmaskType that will be copied. + */ + eProsima_user_DllExport MinimalBitmaskType( + const MinimalBitmaskType& x) + { + m_bitmask_flags = x.m_bitmask_flags; + + m_header = x.m_header; + + m_flag_seq = x.m_flag_seq; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object MinimalBitmaskType that will be copied. + */ + eProsima_user_DllExport MinimalBitmaskType( + MinimalBitmaskType&& x) noexcept + { + m_bitmask_flags = std::move(x.m_bitmask_flags); + m_header = std::move(x.m_header); + m_flag_seq = std::move(x.m_flag_seq); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object MinimalBitmaskType that will be copied. + */ + eProsima_user_DllExport MinimalBitmaskType& operator =( + const MinimalBitmaskType& x) + { + + m_bitmask_flags = x.m_bitmask_flags; + + m_header = x.m_header; + + m_flag_seq = x.m_flag_seq; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object MinimalBitmaskType that will be copied. + */ + eProsima_user_DllExport MinimalBitmaskType& operator =( + MinimalBitmaskType&& x) noexcept + { + + m_bitmask_flags = std::move(x.m_bitmask_flags); + m_header = std::move(x.m_header); + m_flag_seq = std::move(x.m_flag_seq); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x MinimalBitmaskType object to compare. + */ + eProsima_user_DllExport bool operator ==( + const MinimalBitmaskType& x) const + { + return (m_bitmask_flags == x.m_bitmask_flags && + m_header == x.m_header && + m_flag_seq == x.m_flag_seq); + } + + /*! + * @brief Comparison operator. + * @param x MinimalBitmaskType object to compare. + */ + eProsima_user_DllExport bool operator !=( + const MinimalBitmaskType& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member bitmask_flags + * @param _bitmask_flags New value to be copied in member bitmask_flags + */ + eProsima_user_DllExport void bitmask_flags( + const BitmaskTypeFlag& _bitmask_flags) + { + m_bitmask_flags = _bitmask_flags; + } + + /*! + * @brief This function moves the value in member bitmask_flags + * @param _bitmask_flags New value to be moved in member bitmask_flags + */ + eProsima_user_DllExport void bitmask_flags( + BitmaskTypeFlag&& _bitmask_flags) + { + m_bitmask_flags = std::move(_bitmask_flags); + } + + /*! + * @brief This function returns a constant reference to member bitmask_flags + * @return Constant reference to member bitmask_flags + */ + eProsima_user_DllExport const BitmaskTypeFlag& bitmask_flags() const + { + return m_bitmask_flags; + } + + /*! + * @brief This function returns a reference to member bitmask_flags + * @return Reference to member bitmask_flags + */ + eProsima_user_DllExport BitmaskTypeFlag& bitmask_flags() + { + return m_bitmask_flags; + } + + + /*! + * @brief This function copies the value in member header + * @param _header New value to be copied in member header + */ + eProsima_user_DllExport void header( + const MinimalBitmaskHeader& _header) + { + m_header = _header; + } + + /*! + * @brief This function moves the value in member header + * @param _header New value to be moved in member header + */ + eProsima_user_DllExport void header( + MinimalBitmaskHeader&& _header) + { + m_header = std::move(_header); + } + + /*! + * @brief This function returns a constant reference to member header + * @return Constant reference to member header + */ + eProsima_user_DllExport const MinimalBitmaskHeader& header() const + { + return m_header; + } + + /*! + * @brief This function returns a reference to member header + * @return Reference to member header + */ + eProsima_user_DllExport MinimalBitmaskHeader& header() + { + return m_header; + } + + + /*! + * @brief This function copies the value in member flag_seq + * @param _flag_seq New value to be copied in member flag_seq + */ + eProsima_user_DllExport void flag_seq( + const MinimalBitflagSeq& _flag_seq) + { + m_flag_seq = _flag_seq; + } + + /*! + * @brief This function moves the value in member flag_seq + * @param _flag_seq New value to be moved in member flag_seq + */ + eProsima_user_DllExport void flag_seq( + MinimalBitflagSeq&& _flag_seq) + { + m_flag_seq = std::move(_flag_seq); + } + + /*! + * @brief This function returns a constant reference to member flag_seq + * @return Constant reference to member flag_seq + */ + eProsima_user_DllExport const MinimalBitflagSeq& flag_seq() const + { + return m_flag_seq; + } + + /*! + * @brief This function returns a reference to member flag_seq + * @return Reference to member flag_seq + */ + eProsima_user_DllExport MinimalBitflagSeq& flag_seq() + { + return m_flag_seq; + } + + + +private: + + BitmaskTypeFlag m_bitmask_flags{0}; + MinimalBitmaskHeader m_header; + MinimalBitflagSeq m_flag_seq; + +}; +/*! + * @brief This class represents the structure CommonBitfield defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CommonBitfield +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport CommonBitfield() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~CommonBitfield() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object CommonBitfield that will be copied. + */ + eProsima_user_DllExport CommonBitfield( + const CommonBitfield& x) + { + m_position = x.m_position; + + m_flags = x.m_flags; + + m_bitcount = x.m_bitcount; + + m_holder_type = x.m_holder_type; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object CommonBitfield that will be copied. + */ + eProsima_user_DllExport CommonBitfield( + CommonBitfield&& x) noexcept + { + m_position = x.m_position; + m_flags = std::move(x.m_flags); + m_bitcount = x.m_bitcount; + m_holder_type = x.m_holder_type; + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object CommonBitfield that will be copied. + */ + eProsima_user_DllExport CommonBitfield& operator =( + const CommonBitfield& x) + { + + m_position = x.m_position; + + m_flags = x.m_flags; + + m_bitcount = x.m_bitcount; + + m_holder_type = x.m_holder_type; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object CommonBitfield that will be copied. + */ + eProsima_user_DllExport CommonBitfield& operator =( + CommonBitfield&& x) noexcept + { + + m_position = x.m_position; + m_flags = std::move(x.m_flags); + m_bitcount = x.m_bitcount; + m_holder_type = x.m_holder_type; + return *this; + } + + /*! + * @brief Comparison operator. + * @param x CommonBitfield object to compare. + */ + eProsima_user_DllExport bool operator ==( + const CommonBitfield& x) const + { + return (m_position == x.m_position && + m_flags == x.m_flags && + m_bitcount == x.m_bitcount && + m_holder_type == x.m_holder_type); + } + + /*! + * @brief Comparison operator. + * @param x CommonBitfield object to compare. + */ + eProsima_user_DllExport bool operator !=( + const CommonBitfield& x) const + { + return !(*this == x); + } + + /*! + * @brief This function sets a value in member position + * @param _position New value for member position + */ + eProsima_user_DllExport void position( + uint16_t _position) + { + m_position = _position; + } + + /*! + * @brief This function returns the value of member position + * @return Value of member position + */ + eProsima_user_DllExport uint16_t position() const + { + return m_position; + } + + /*! + * @brief This function returns a reference to member position + * @return Reference to member position + */ + eProsima_user_DllExport uint16_t& position() + { + return m_position; + } + + + /*! + * @brief This function copies the value in member flags + * @param _flags New value to be copied in member flags + */ + eProsima_user_DllExport void flags( + const BitsetMemberFlag& _flags) + { + m_flags = _flags; + } + + /*! + * @brief This function moves the value in member flags + * @param _flags New value to be moved in member flags + */ + eProsima_user_DllExport void flags( + BitsetMemberFlag&& _flags) + { + m_flags = std::move(_flags); + } + + /*! + * @brief This function returns a constant reference to member flags + * @return Constant reference to member flags + */ + eProsima_user_DllExport const BitsetMemberFlag& flags() const + { + return m_flags; + } + + /*! + * @brief This function returns a reference to member flags + * @return Reference to member flags + */ + eProsima_user_DllExport BitsetMemberFlag& flags() + { + return m_flags; + } + + + /*! + * @brief This function sets a value in member bitcount + * @param _bitcount New value for member bitcount + */ + eProsima_user_DllExport void bitcount( + uint8_t _bitcount) + { + m_bitcount = _bitcount; + } + + /*! + * @brief This function returns the value of member bitcount + * @return Value of member bitcount + */ + eProsima_user_DllExport uint8_t bitcount() const + { + return m_bitcount; + } + + /*! + * @brief This function returns a reference to member bitcount + * @return Reference to member bitcount + */ + eProsima_user_DllExport uint8_t& bitcount() + { + return m_bitcount; + } + + + /*! + * @brief This function sets a value in member holder_type + * @param _holder_type New value for member holder_type + */ + eProsima_user_DllExport void holder_type( + TypeKind _holder_type) + { + m_holder_type = _holder_type; + } + + /*! + * @brief This function returns the value of member holder_type + * @return Value of member holder_type + */ + eProsima_user_DllExport TypeKind holder_type() const + { + return m_holder_type; + } + + /*! + * @brief This function returns a reference to member holder_type + * @return Reference to member holder_type + */ + eProsima_user_DllExport TypeKind& holder_type() + { + return m_holder_type; + } + + + +private: + + uint16_t m_position{0}; + BitsetMemberFlag m_flags{0}; + uint8_t m_bitcount{0}; + TypeKind m_holder_type{0}; + +}; +/*! + * @brief This class represents the structure CompleteBitfield defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteBitfield +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport CompleteBitfield() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~CompleteBitfield() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object CompleteBitfield that will be copied. + */ + eProsima_user_DllExport CompleteBitfield( + const CompleteBitfield& x) + { + m_common = x.m_common; + + m_detail = x.m_detail; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object CompleteBitfield that will be copied. + */ + eProsima_user_DllExport CompleteBitfield( + CompleteBitfield&& x) noexcept + { + m_common = std::move(x.m_common); + m_detail = std::move(x.m_detail); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object CompleteBitfield that will be copied. + */ + eProsima_user_DllExport CompleteBitfield& operator =( + const CompleteBitfield& x) + { + + m_common = x.m_common; + + m_detail = x.m_detail; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object CompleteBitfield that will be copied. + */ + eProsima_user_DllExport CompleteBitfield& operator =( + CompleteBitfield&& x) noexcept + { + + m_common = std::move(x.m_common); + m_detail = std::move(x.m_detail); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x CompleteBitfield object to compare. + */ + eProsima_user_DllExport bool operator ==( + const CompleteBitfield& x) const + { + return (m_common == x.m_common && + m_detail == x.m_detail); + } + + /*! + * @brief Comparison operator. + * @param x CompleteBitfield object to compare. + */ + eProsima_user_DllExport bool operator !=( + const CompleteBitfield& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member common + * @param _common New value to be copied in member common + */ + eProsima_user_DllExport void common( + const CommonBitfield& _common) + { + m_common = _common; + } + + /*! + * @brief This function moves the value in member common + * @param _common New value to be moved in member common + */ + eProsima_user_DllExport void common( + CommonBitfield&& _common) + { + m_common = std::move(_common); + } + + /*! + * @brief This function returns a constant reference to member common + * @return Constant reference to member common + */ + eProsima_user_DllExport const CommonBitfield& common() const + { + return m_common; + } + + /*! + * @brief This function returns a reference to member common + * @return Reference to member common + */ + eProsima_user_DllExport CommonBitfield& common() + { + return m_common; + } + + + /*! + * @brief This function copies the value in member detail + * @param _detail New value to be copied in member detail + */ + eProsima_user_DllExport void detail( + const CompleteMemberDetail& _detail) + { + m_detail = _detail; + } + + /*! + * @brief This function moves the value in member detail + * @param _detail New value to be moved in member detail + */ + eProsima_user_DllExport void detail( + CompleteMemberDetail&& _detail) + { + m_detail = std::move(_detail); + } + + /*! + * @brief This function returns a constant reference to member detail + * @return Constant reference to member detail + */ + eProsima_user_DllExport const CompleteMemberDetail& detail() const + { + return m_detail; + } + + /*! + * @brief This function returns a reference to member detail + * @return Reference to member detail + */ + eProsima_user_DllExport CompleteMemberDetail& detail() + { + return m_detail; + } + + + +private: + + CommonBitfield m_common; + CompleteMemberDetail m_detail; + +}; +typedef std::vector CompleteBitfieldSeq; + +/*! + * @brief This class represents the structure MinimalBitfield defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalBitfield +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport MinimalBitfield() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~MinimalBitfield() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object MinimalBitfield that will be copied. + */ + eProsima_user_DllExport MinimalBitfield( + const MinimalBitfield& x) + { + m_common = x.m_common; + + m_name_hash = x.m_name_hash; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object MinimalBitfield that will be copied. + */ + eProsima_user_DllExport MinimalBitfield( + MinimalBitfield&& x) noexcept + { + m_common = std::move(x.m_common); + m_name_hash = std::move(x.m_name_hash); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object MinimalBitfield that will be copied. + */ + eProsima_user_DllExport MinimalBitfield& operator =( + const MinimalBitfield& x) + { + + m_common = x.m_common; + + m_name_hash = x.m_name_hash; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object MinimalBitfield that will be copied. + */ + eProsima_user_DllExport MinimalBitfield& operator =( + MinimalBitfield&& x) noexcept + { + + m_common = std::move(x.m_common); + m_name_hash = std::move(x.m_name_hash); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x MinimalBitfield object to compare. + */ + eProsima_user_DllExport bool operator ==( + const MinimalBitfield& x) const + { + return (m_common == x.m_common && + m_name_hash == x.m_name_hash); + } + + /*! + * @brief Comparison operator. + * @param x MinimalBitfield object to compare. + */ + eProsima_user_DllExport bool operator !=( + const MinimalBitfield& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member common + * @param _common New value to be copied in member common + */ + eProsima_user_DllExport void common( + const CommonBitfield& _common) + { + m_common = _common; + } + + /*! + * @brief This function moves the value in member common + * @param _common New value to be moved in member common + */ + eProsima_user_DllExport void common( + CommonBitfield&& _common) + { + m_common = std::move(_common); + } + + /*! + * @brief This function returns a constant reference to member common + * @return Constant reference to member common + */ + eProsima_user_DllExport const CommonBitfield& common() const + { + return m_common; + } + + /*! + * @brief This function returns a reference to member common + * @return Reference to member common + */ + eProsima_user_DllExport CommonBitfield& common() + { + return m_common; + } + + + /*! + * @brief This function copies the value in member name_hash + * @param _name_hash New value to be copied in member name_hash + */ + eProsima_user_DllExport void name_hash( + const NameHash& _name_hash) + { + m_name_hash = _name_hash; + } + + /*! + * @brief This function moves the value in member name_hash + * @param _name_hash New value to be moved in member name_hash + */ + eProsima_user_DllExport void name_hash( + NameHash&& _name_hash) + { + m_name_hash = std::move(_name_hash); + } + + /*! + * @brief This function returns a constant reference to member name_hash + * @return Constant reference to member name_hash + */ + eProsima_user_DllExport const NameHash& name_hash() const + { + return m_name_hash; + } + + /*! + * @brief This function returns a reference to member name_hash + * @return Reference to member name_hash + */ + eProsima_user_DllExport NameHash& name_hash() + { + return m_name_hash; + } + + + +private: + + CommonBitfield m_common; + NameHash m_name_hash{0}; + +}; +typedef std::vector MinimalBitfieldSeq; + +/*! + * @brief This class represents the structure CompleteBitsetHeader defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteBitsetHeader +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport CompleteBitsetHeader() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~CompleteBitsetHeader() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object CompleteBitsetHeader that will be copied. + */ + eProsima_user_DllExport CompleteBitsetHeader( + const CompleteBitsetHeader& x) + { + m_detail = x.m_detail; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object CompleteBitsetHeader that will be copied. + */ + eProsima_user_DllExport CompleteBitsetHeader( + CompleteBitsetHeader&& x) noexcept + { + m_detail = std::move(x.m_detail); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object CompleteBitsetHeader that will be copied. + */ + eProsima_user_DllExport CompleteBitsetHeader& operator =( + const CompleteBitsetHeader& x) + { + + m_detail = x.m_detail; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object CompleteBitsetHeader that will be copied. + */ + eProsima_user_DllExport CompleteBitsetHeader& operator =( + CompleteBitsetHeader&& x) noexcept + { + + m_detail = std::move(x.m_detail); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x CompleteBitsetHeader object to compare. + */ + eProsima_user_DllExport bool operator ==( + const CompleteBitsetHeader& x) const + { + return (m_detail == x.m_detail); + } + + /*! + * @brief Comparison operator. + * @param x CompleteBitsetHeader object to compare. + */ + eProsima_user_DllExport bool operator !=( + const CompleteBitsetHeader& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member detail + * @param _detail New value to be copied in member detail + */ + eProsima_user_DllExport void detail( + const CompleteTypeDetail& _detail) + { + m_detail = _detail; + } + + /*! + * @brief This function moves the value in member detail + * @param _detail New value to be moved in member detail + */ + eProsima_user_DllExport void detail( + CompleteTypeDetail&& _detail) + { + m_detail = std::move(_detail); + } + + /*! + * @brief This function returns a constant reference to member detail + * @return Constant reference to member detail + */ + eProsima_user_DllExport const CompleteTypeDetail& detail() const + { + return m_detail; + } + + /*! + * @brief This function returns a reference to member detail + * @return Reference to member detail + */ + eProsima_user_DllExport CompleteTypeDetail& detail() + { + return m_detail; + } + + + +private: + + CompleteTypeDetail m_detail; + +}; +/*! + * @brief This class represents the structure MinimalBitsetHeader defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalBitsetHeader +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport MinimalBitsetHeader() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~MinimalBitsetHeader() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object MinimalBitsetHeader that will be copied. + */ + eProsima_user_DllExport MinimalBitsetHeader( + const MinimalBitsetHeader& x) + { + static_cast(x); + } + + /*! + * @brief Move constructor. + * @param x Reference to the object MinimalBitsetHeader that will be copied. + */ + eProsima_user_DllExport MinimalBitsetHeader( + MinimalBitsetHeader&& x) noexcept + { + static_cast(x); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object MinimalBitsetHeader that will be copied. + */ + eProsima_user_DllExport MinimalBitsetHeader& operator =( + const MinimalBitsetHeader& x) + { + + static_cast(x); + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object MinimalBitsetHeader that will be copied. + */ + eProsima_user_DllExport MinimalBitsetHeader& operator =( + MinimalBitsetHeader&& x) noexcept + { + + static_cast(x); + + return *this; + } + + /*! + * @brief Comparison operator. + * @param x MinimalBitsetHeader object to compare. + */ + eProsima_user_DllExport bool operator ==( + const MinimalBitsetHeader& x) const + { + static_cast(x); + return true; + } + + /*! + * @brief Comparison operator. + * @param x MinimalBitsetHeader object to compare. + */ + eProsima_user_DllExport bool operator !=( + const MinimalBitsetHeader& x) const + { + return !(*this == x); + } + + + +private: + + +}; +/*! + * @brief This class represents the structure CompleteBitsetType defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteBitsetType +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport CompleteBitsetType() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~CompleteBitsetType() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object CompleteBitsetType that will be copied. + */ + eProsima_user_DllExport CompleteBitsetType( + const CompleteBitsetType& x) + { + m_bitset_flags = x.m_bitset_flags; + + m_header = x.m_header; + + m_field_seq = x.m_field_seq; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object CompleteBitsetType that will be copied. + */ + eProsima_user_DllExport CompleteBitsetType( + CompleteBitsetType&& x) noexcept + { + m_bitset_flags = std::move(x.m_bitset_flags); + m_header = std::move(x.m_header); + m_field_seq = std::move(x.m_field_seq); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object CompleteBitsetType that will be copied. + */ + eProsima_user_DllExport CompleteBitsetType& operator =( + const CompleteBitsetType& x) + { + + m_bitset_flags = x.m_bitset_flags; + + m_header = x.m_header; + + m_field_seq = x.m_field_seq; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object CompleteBitsetType that will be copied. + */ + eProsima_user_DllExport CompleteBitsetType& operator =( + CompleteBitsetType&& x) noexcept + { + + m_bitset_flags = std::move(x.m_bitset_flags); + m_header = std::move(x.m_header); + m_field_seq = std::move(x.m_field_seq); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x CompleteBitsetType object to compare. + */ + eProsima_user_DllExport bool operator ==( + const CompleteBitsetType& x) const + { + return (m_bitset_flags == x.m_bitset_flags && + m_header == x.m_header && + m_field_seq == x.m_field_seq); + } + + /*! + * @brief Comparison operator. + * @param x CompleteBitsetType object to compare. + */ + eProsima_user_DllExport bool operator !=( + const CompleteBitsetType& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member bitset_flags + * @param _bitset_flags New value to be copied in member bitset_flags + */ + eProsima_user_DllExport void bitset_flags( + const BitsetTypeFlag& _bitset_flags) + { + m_bitset_flags = _bitset_flags; + } + + /*! + * @brief This function moves the value in member bitset_flags + * @param _bitset_flags New value to be moved in member bitset_flags + */ + eProsima_user_DllExport void bitset_flags( + BitsetTypeFlag&& _bitset_flags) + { + m_bitset_flags = std::move(_bitset_flags); + } + + /*! + * @brief This function returns a constant reference to member bitset_flags + * @return Constant reference to member bitset_flags + */ + eProsima_user_DllExport const BitsetTypeFlag& bitset_flags() const + { + return m_bitset_flags; + } + + /*! + * @brief This function returns a reference to member bitset_flags + * @return Reference to member bitset_flags + */ + eProsima_user_DllExport BitsetTypeFlag& bitset_flags() + { + return m_bitset_flags; + } + + + /*! + * @brief This function copies the value in member header + * @param _header New value to be copied in member header + */ + eProsima_user_DllExport void header( + const CompleteBitsetHeader& _header) + { + m_header = _header; + } + + /*! + * @brief This function moves the value in member header + * @param _header New value to be moved in member header + */ + eProsima_user_DllExport void header( + CompleteBitsetHeader&& _header) + { + m_header = std::move(_header); + } + + /*! + * @brief This function returns a constant reference to member header + * @return Constant reference to member header + */ + eProsima_user_DllExport const CompleteBitsetHeader& header() const + { + return m_header; + } + + /*! + * @brief This function returns a reference to member header + * @return Reference to member header + */ + eProsima_user_DllExport CompleteBitsetHeader& header() + { + return m_header; + } + + + /*! + * @brief This function copies the value in member field_seq + * @param _field_seq New value to be copied in member field_seq + */ + eProsima_user_DllExport void field_seq( + const CompleteBitfieldSeq& _field_seq) + { + m_field_seq = _field_seq; + } + + /*! + * @brief This function moves the value in member field_seq + * @param _field_seq New value to be moved in member field_seq + */ + eProsima_user_DllExport void field_seq( + CompleteBitfieldSeq&& _field_seq) + { + m_field_seq = std::move(_field_seq); + } + + /*! + * @brief This function returns a constant reference to member field_seq + * @return Constant reference to member field_seq + */ + eProsima_user_DllExport const CompleteBitfieldSeq& field_seq() const + { + return m_field_seq; + } + + /*! + * @brief This function returns a reference to member field_seq + * @return Reference to member field_seq + */ + eProsima_user_DllExport CompleteBitfieldSeq& field_seq() + { + return m_field_seq; + } + + + +private: + + BitsetTypeFlag m_bitset_flags{0}; + CompleteBitsetHeader m_header; + CompleteBitfieldSeq m_field_seq; + +}; +/*! + * @brief This class represents the structure MinimalBitsetType defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalBitsetType +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport MinimalBitsetType() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~MinimalBitsetType() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object MinimalBitsetType that will be copied. + */ + eProsima_user_DllExport MinimalBitsetType( + const MinimalBitsetType& x) + { + m_bitset_flags = x.m_bitset_flags; + + m_header = x.m_header; + + m_field_seq = x.m_field_seq; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object MinimalBitsetType that will be copied. + */ + eProsima_user_DllExport MinimalBitsetType( + MinimalBitsetType&& x) noexcept + { + m_bitset_flags = std::move(x.m_bitset_flags); + m_header = std::move(x.m_header); + m_field_seq = std::move(x.m_field_seq); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object MinimalBitsetType that will be copied. + */ + eProsima_user_DllExport MinimalBitsetType& operator =( + const MinimalBitsetType& x) + { + + m_bitset_flags = x.m_bitset_flags; + + m_header = x.m_header; + + m_field_seq = x.m_field_seq; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object MinimalBitsetType that will be copied. + */ + eProsima_user_DllExport MinimalBitsetType& operator =( + MinimalBitsetType&& x) noexcept + { + + m_bitset_flags = std::move(x.m_bitset_flags); + m_header = std::move(x.m_header); + m_field_seq = std::move(x.m_field_seq); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x MinimalBitsetType object to compare. + */ + eProsima_user_DllExport bool operator ==( + const MinimalBitsetType& x) const + { + return (m_bitset_flags == x.m_bitset_flags && + m_header == x.m_header && + m_field_seq == x.m_field_seq); + } + + /*! + * @brief Comparison operator. + * @param x MinimalBitsetType object to compare. + */ + eProsima_user_DllExport bool operator !=( + const MinimalBitsetType& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member bitset_flags + * @param _bitset_flags New value to be copied in member bitset_flags + */ + eProsima_user_DllExport void bitset_flags( + const BitsetTypeFlag& _bitset_flags) + { + m_bitset_flags = _bitset_flags; + } + + /*! + * @brief This function moves the value in member bitset_flags + * @param _bitset_flags New value to be moved in member bitset_flags + */ + eProsima_user_DllExport void bitset_flags( + BitsetTypeFlag&& _bitset_flags) + { + m_bitset_flags = std::move(_bitset_flags); + } + + /*! + * @brief This function returns a constant reference to member bitset_flags + * @return Constant reference to member bitset_flags + */ + eProsima_user_DllExport const BitsetTypeFlag& bitset_flags() const + { + return m_bitset_flags; + } + + /*! + * @brief This function returns a reference to member bitset_flags + * @return Reference to member bitset_flags + */ + eProsima_user_DllExport BitsetTypeFlag& bitset_flags() + { + return m_bitset_flags; + } + + + /*! + * @brief This function copies the value in member header + * @param _header New value to be copied in member header + */ + eProsima_user_DllExport void header( + const MinimalBitsetHeader& _header) + { + m_header = _header; + } + + /*! + * @brief This function moves the value in member header + * @param _header New value to be moved in member header + */ + eProsima_user_DllExport void header( + MinimalBitsetHeader&& _header) + { + m_header = std::move(_header); + } + + /*! + * @brief This function returns a constant reference to member header + * @return Constant reference to member header + */ + eProsima_user_DllExport const MinimalBitsetHeader& header() const + { + return m_header; + } + + /*! + * @brief This function returns a reference to member header + * @return Reference to member header + */ + eProsima_user_DllExport MinimalBitsetHeader& header() + { + return m_header; + } + + + /*! + * @brief This function copies the value in member field_seq + * @param _field_seq New value to be copied in member field_seq + */ + eProsima_user_DllExport void field_seq( + const MinimalBitfieldSeq& _field_seq) + { + m_field_seq = _field_seq; + } + + /*! + * @brief This function moves the value in member field_seq + * @param _field_seq New value to be moved in member field_seq + */ + eProsima_user_DllExport void field_seq( + MinimalBitfieldSeq&& _field_seq) + { + m_field_seq = std::move(_field_seq); + } + + /*! + * @brief This function returns a constant reference to member field_seq + * @return Constant reference to member field_seq + */ + eProsima_user_DllExport const MinimalBitfieldSeq& field_seq() const + { + return m_field_seq; + } + + /*! + * @brief This function returns a reference to member field_seq + * @return Reference to member field_seq + */ + eProsima_user_DllExport MinimalBitfieldSeq& field_seq() + { + return m_field_seq; + } + + + +private: + + BitsetTypeFlag m_bitset_flags{0}; + MinimalBitsetHeader m_header; + MinimalBitfieldSeq m_field_seq; + +}; +/*! + * @brief This class represents the structure CompleteExtendedType defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteExtendedType +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport CompleteExtendedType() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~CompleteExtendedType() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object CompleteExtendedType that will be copied. + */ + eProsima_user_DllExport CompleteExtendedType( + const CompleteExtendedType& x) + { + static_cast(x); + } + + /*! + * @brief Move constructor. + * @param x Reference to the object CompleteExtendedType that will be copied. + */ + eProsima_user_DllExport CompleteExtendedType( + CompleteExtendedType&& x) noexcept + { + static_cast(x); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object CompleteExtendedType that will be copied. + */ + eProsima_user_DllExport CompleteExtendedType& operator =( + const CompleteExtendedType& x) + { + + static_cast(x); + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object CompleteExtendedType that will be copied. + */ + eProsima_user_DllExport CompleteExtendedType& operator =( + CompleteExtendedType&& x) noexcept + { + + static_cast(x); + + return *this; + } + + /*! + * @brief Comparison operator. + * @param x CompleteExtendedType object to compare. + */ + eProsima_user_DllExport bool operator ==( + const CompleteExtendedType& x) const + { + static_cast(x); + return true; + } + + /*! + * @brief Comparison operator. + * @param x CompleteExtendedType object to compare. + */ + eProsima_user_DllExport bool operator !=( + const CompleteExtendedType& x) const + { + return !(*this == x); + } + + + +private: + + +}; +/*! + * @brief This class represents the union CompleteTypeObject defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteTypeObject +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport CompleteTypeObject() + { + extended_type_(); + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~CompleteTypeObject() + { + if (member_destructor_) + { + member_destructor_(); + } + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object CompleteTypeObject that will be copied. + */ + eProsima_user_DllExport CompleteTypeObject( + const CompleteTypeObject& x) + { + m__d = x.m__d; + + switch (x.selected_member_) + { + case 0x00000001: + alias_type_() = x.m_alias_type; + break; + + case 0x00000002: + annotation_type_() = x.m_annotation_type; + break; + + case 0x00000003: + struct_type_() = x.m_struct_type; + break; + + case 0x00000004: + union_type_() = x.m_union_type; + break; + + case 0x00000005: + bitset_type_() = x.m_bitset_type; + break; + + case 0x00000006: + sequence_type_() = x.m_sequence_type; + break; + + case 0x00000007: + array_type_() = x.m_array_type; + break; + + case 0x00000008: + map_type_() = x.m_map_type; + break; + + case 0x00000009: + enumerated_type_() = x.m_enumerated_type; + break; + + case 0x0000000a: + bitmask_type_() = x.m_bitmask_type; + break; + + case 0x0000000b: + extended_type_() = x.m_extended_type; + break; + + } + } + + /*! + * @brief Move constructor. + * @param x Reference to the object CompleteTypeObject that will be copied. + */ + eProsima_user_DllExport CompleteTypeObject( + CompleteTypeObject&& x) noexcept + { + m__d = x.m__d; + + switch (x.selected_member_) + { + case 0x00000001: + alias_type_() = std::move(x.m_alias_type); + break; + + case 0x00000002: + annotation_type_() = std::move(x.m_annotation_type); + break; + + case 0x00000003: + struct_type_() = std::move(x.m_struct_type); + break; + + case 0x00000004: + union_type_() = std::move(x.m_union_type); + break; + + case 0x00000005: + bitset_type_() = std::move(x.m_bitset_type); + break; + + case 0x00000006: + sequence_type_() = std::move(x.m_sequence_type); + break; + + case 0x00000007: + array_type_() = std::move(x.m_array_type); + break; + + case 0x00000008: + map_type_() = std::move(x.m_map_type); + break; + + case 0x00000009: + enumerated_type_() = std::move(x.m_enumerated_type); + break; + + case 0x0000000a: + bitmask_type_() = std::move(x.m_bitmask_type); + break; + + case 0x0000000b: + extended_type_() = std::move(x.m_extended_type); + break; + + } + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object CompleteTypeObject that will be copied. + */ + eProsima_user_DllExport CompleteTypeObject& operator =( + const CompleteTypeObject& x) + { + m__d = x.m__d; + + switch (x.selected_member_) + { + case 0x00000001: + alias_type_() = x.m_alias_type; + break; + + case 0x00000002: + annotation_type_() = x.m_annotation_type; + break; + + case 0x00000003: + struct_type_() = x.m_struct_type; + break; + + case 0x00000004: + union_type_() = x.m_union_type; + break; + + case 0x00000005: + bitset_type_() = x.m_bitset_type; + break; + + case 0x00000006: + sequence_type_() = x.m_sequence_type; + break; + + case 0x00000007: + array_type_() = x.m_array_type; + break; + + case 0x00000008: + map_type_() = x.m_map_type; + break; + + case 0x00000009: + enumerated_type_() = x.m_enumerated_type; + break; + + case 0x0000000a: + bitmask_type_() = x.m_bitmask_type; + break; + + case 0x0000000b: + extended_type_() = x.m_extended_type; + break; + + } + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object CompleteTypeObject that will be copied. + */ + eProsima_user_DllExport CompleteTypeObject& operator =( + CompleteTypeObject&& x) noexcept + { + m__d = x.m__d; + + switch (x.selected_member_) + { + case 0x00000001: + alias_type_() = std::move(x.m_alias_type); + break; + + case 0x00000002: + annotation_type_() = std::move(x.m_annotation_type); + break; + + case 0x00000003: + struct_type_() = std::move(x.m_struct_type); + break; + + case 0x00000004: + union_type_() = std::move(x.m_union_type); + break; + + case 0x00000005: + bitset_type_() = std::move(x.m_bitset_type); + break; + + case 0x00000006: + sequence_type_() = std::move(x.m_sequence_type); + break; + + case 0x00000007: + array_type_() = std::move(x.m_array_type); + break; + + case 0x00000008: + map_type_() = std::move(x.m_map_type); + break; + + case 0x00000009: + enumerated_type_() = std::move(x.m_enumerated_type); + break; + + case 0x0000000a: + bitmask_type_() = std::move(x.m_bitmask_type); + break; + + case 0x0000000b: + extended_type_() = std::move(x.m_extended_type); + break; + + } + + return *this; + } + + /*! + * @brief Comparison operator. + * @param x CompleteTypeObject object to compare. + */ + eProsima_user_DllExport bool operator ==( + const CompleteTypeObject& x) const + { + bool ret_value {false}; + + if (m__d == x.m__d && + selected_member_ == x.selected_member_) + { + switch (selected_member_) + { + case 0x00000001: + ret_value = (m_alias_type == x.m_alias_type); + break; + + case 0x00000002: + ret_value = (m_annotation_type == x.m_annotation_type); + break; + + case 0x00000003: + ret_value = (m_struct_type == x.m_struct_type); + break; + + case 0x00000004: + ret_value = (m_union_type == x.m_union_type); + break; + + case 0x00000005: + ret_value = (m_bitset_type == x.m_bitset_type); + break; + + case 0x00000006: + ret_value = (m_sequence_type == x.m_sequence_type); + break; + + case 0x00000007: + ret_value = (m_array_type == x.m_array_type); + break; + + case 0x00000008: + ret_value = (m_map_type == x.m_map_type); + break; + + case 0x00000009: + ret_value = (m_enumerated_type == x.m_enumerated_type); + break; + + case 0x0000000a: + ret_value = (m_bitmask_type == x.m_bitmask_type); + break; + + case 0x0000000b: + ret_value = (m_extended_type == x.m_extended_type); + break; + + } + } + + return ret_value; + } + + /*! + * @brief Comparison operator. + * @param x CompleteTypeObject object to compare. + */ + eProsima_user_DllExport bool operator !=( + const CompleteTypeObject& x) const + { + return !(*this == x); + } + + /*! + * @brief This function sets the discriminator value. + * @param __d New value for the discriminator. + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the new value doesn't correspond to the selected union member. + */ + eProsima_user_DllExport void _d( + uint8_t __d) + { + bool valid_discriminator = false; + + switch (__d) + { + case TK_ALIAS: + if (0x00000001 == selected_member_) + { + valid_discriminator = true; + } + break; + + case TK_ANNOTATION: + if (0x00000002 == selected_member_) + { + valid_discriminator = true; + } + break; + + case TK_STRUCTURE: + if (0x00000003 == selected_member_) + { + valid_discriminator = true; + } + break; + + case TK_UNION: + if (0x00000004 == selected_member_) + { + valid_discriminator = true; + } + break; + + case TK_BITSET: + if (0x00000005 == selected_member_) + { + valid_discriminator = true; + } + break; + + case TK_SEQUENCE: + if (0x00000006 == selected_member_) + { + valid_discriminator = true; + } + break; + + case TK_ARRAY: + if (0x00000007 == selected_member_) + { + valid_discriminator = true; + } + break; + + case TK_MAP: + if (0x00000008 == selected_member_) + { + valid_discriminator = true; + } + break; + + case TK_ENUM: + if (0x00000009 == selected_member_) + { + valid_discriminator = true; + } + break; + + case TK_BITMASK: + if (0x0000000a == selected_member_) + { + valid_discriminator = true; + } + break; + + default: + if (0x0000000b == selected_member_) + { + valid_discriminator = true; + } + break; + + } + + if (!valid_discriminator) + { + throw eprosima::fastcdr::exception::BadParamException("Discriminator doesn't correspond with the selected union member"); + } + + m__d = __d; + } + + /*! + * @brief This function returns the value of the discriminator. + * @return Value of the discriminator + */ + eProsima_user_DllExport uint8_t _d() const + { + return m__d; + } + + /*! + * @brief This function copies the value in member alias_type + * @param _alias_type New value to be copied in member alias_type + */ + eProsima_user_DllExport void alias_type( + const CompleteAliasType& _alias_type) + { + alias_type_() = _alias_type; + m__d = TK_ALIAS; + } + + /*! + * @brief This function moves the value in member alias_type + * @param _alias_type New value to be moved in member alias_type + */ + eProsima_user_DllExport void alias_type( + CompleteAliasType&& _alias_type) + { + alias_type_() = _alias_type; + m__d = TK_ALIAS; + } + + /*! + * @brief This function returns a constant reference to member alias_type + * @return Constant reference to member alias_type + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport const CompleteAliasType& alias_type() const + { + if (0x00000001 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_alias_type; + } + + /*! + * @brief This function returns a reference to member alias_type + * @return Reference to member alias_type + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport CompleteAliasType& alias_type() + { + if (0x00000001 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_alias_type; + } + + + /*! + * @brief This function copies the value in member annotation_type + * @param _annotation_type New value to be copied in member annotation_type + */ + eProsima_user_DllExport void annotation_type( + const CompleteAnnotationType& _annotation_type) + { + annotation_type_() = _annotation_type; + m__d = TK_ANNOTATION; + } + + /*! + * @brief This function moves the value in member annotation_type + * @param _annotation_type New value to be moved in member annotation_type + */ + eProsima_user_DllExport void annotation_type( + CompleteAnnotationType&& _annotation_type) + { + annotation_type_() = _annotation_type; + m__d = TK_ANNOTATION; + } + + /*! + * @brief This function returns a constant reference to member annotation_type + * @return Constant reference to member annotation_type + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport const CompleteAnnotationType& annotation_type() const + { + if (0x00000002 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_annotation_type; + } + + /*! + * @brief This function returns a reference to member annotation_type + * @return Reference to member annotation_type + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport CompleteAnnotationType& annotation_type() + { + if (0x00000002 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_annotation_type; + } + + + /*! + * @brief This function copies the value in member struct_type + * @param _struct_type New value to be copied in member struct_type + */ + eProsima_user_DllExport void struct_type( + const CompleteStructType& _struct_type) + { + struct_type_() = _struct_type; + m__d = TK_STRUCTURE; + } + + /*! + * @brief This function moves the value in member struct_type + * @param _struct_type New value to be moved in member struct_type + */ + eProsima_user_DllExport void struct_type( + CompleteStructType&& _struct_type) + { + struct_type_() = _struct_type; + m__d = TK_STRUCTURE; + } + + /*! + * @brief This function returns a constant reference to member struct_type + * @return Constant reference to member struct_type + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport const CompleteStructType& struct_type() const + { + if (0x00000003 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_struct_type; + } + + /*! + * @brief This function returns a reference to member struct_type + * @return Reference to member struct_type + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport CompleteStructType& struct_type() + { + if (0x00000003 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_struct_type; + } + + + /*! + * @brief This function copies the value in member union_type + * @param _union_type New value to be copied in member union_type + */ + eProsima_user_DllExport void union_type( + const CompleteUnionType& _union_type) + { + union_type_() = _union_type; + m__d = TK_UNION; + } + + /*! + * @brief This function moves the value in member union_type + * @param _union_type New value to be moved in member union_type + */ + eProsima_user_DllExport void union_type( + CompleteUnionType&& _union_type) + { + union_type_() = _union_type; + m__d = TK_UNION; + } + + /*! + * @brief This function returns a constant reference to member union_type + * @return Constant reference to member union_type + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport const CompleteUnionType& union_type() const + { + if (0x00000004 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_union_type; + } + + /*! + * @brief This function returns a reference to member union_type + * @return Reference to member union_type + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport CompleteUnionType& union_type() + { + if (0x00000004 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_union_type; + } + + + /*! + * @brief This function copies the value in member bitset_type + * @param _bitset_type New value to be copied in member bitset_type + */ + eProsima_user_DllExport void bitset_type( + const CompleteBitsetType& _bitset_type) + { + bitset_type_() = _bitset_type; + m__d = TK_BITSET; + } + + /*! + * @brief This function moves the value in member bitset_type + * @param _bitset_type New value to be moved in member bitset_type + */ + eProsima_user_DllExport void bitset_type( + CompleteBitsetType&& _bitset_type) + { + bitset_type_() = _bitset_type; + m__d = TK_BITSET; + } + + /*! + * @brief This function returns a constant reference to member bitset_type + * @return Constant reference to member bitset_type + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport const CompleteBitsetType& bitset_type() const + { + if (0x00000005 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_bitset_type; + } + + /*! + * @brief This function returns a reference to member bitset_type + * @return Reference to member bitset_type + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport CompleteBitsetType& bitset_type() + { + if (0x00000005 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_bitset_type; + } + + + /*! + * @brief This function copies the value in member sequence_type + * @param _sequence_type New value to be copied in member sequence_type + */ + eProsima_user_DllExport void sequence_type( + const CompleteSequenceType& _sequence_type) + { + sequence_type_() = _sequence_type; + m__d = TK_SEQUENCE; + } + + /*! + * @brief This function moves the value in member sequence_type + * @param _sequence_type New value to be moved in member sequence_type + */ + eProsima_user_DllExport void sequence_type( + CompleteSequenceType&& _sequence_type) + { + sequence_type_() = _sequence_type; + m__d = TK_SEQUENCE; + } + + /*! + * @brief This function returns a constant reference to member sequence_type + * @return Constant reference to member sequence_type + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport const CompleteSequenceType& sequence_type() const + { + if (0x00000006 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_sequence_type; + } + + /*! + * @brief This function returns a reference to member sequence_type + * @return Reference to member sequence_type + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport CompleteSequenceType& sequence_type() + { + if (0x00000006 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_sequence_type; + } + + + /*! + * @brief This function copies the value in member array_type + * @param _array_type New value to be copied in member array_type + */ + eProsima_user_DllExport void array_type( + const CompleteArrayType& _array_type) + { + array_type_() = _array_type; + m__d = TK_ARRAY; + } + + /*! + * @brief This function moves the value in member array_type + * @param _array_type New value to be moved in member array_type + */ + eProsima_user_DllExport void array_type( + CompleteArrayType&& _array_type) + { + array_type_() = _array_type; + m__d = TK_ARRAY; + } + + /*! + * @brief This function returns a constant reference to member array_type + * @return Constant reference to member array_type + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport const CompleteArrayType& array_type() const + { + if (0x00000007 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_array_type; + } + + /*! + * @brief This function returns a reference to member array_type + * @return Reference to member array_type + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport CompleteArrayType& array_type() + { + if (0x00000007 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_array_type; + } + + + /*! + * @brief This function copies the value in member map_type + * @param _map_type New value to be copied in member map_type + */ + eProsima_user_DllExport void map_type( + const CompleteMapType& _map_type) + { + map_type_() = _map_type; + m__d = TK_MAP; + } + + /*! + * @brief This function moves the value in member map_type + * @param _map_type New value to be moved in member map_type + */ + eProsima_user_DllExport void map_type( + CompleteMapType&& _map_type) + { + map_type_() = _map_type; + m__d = TK_MAP; + } + + /*! + * @brief This function returns a constant reference to member map_type + * @return Constant reference to member map_type + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport const CompleteMapType& map_type() const + { + if (0x00000008 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_map_type; + } + + /*! + * @brief This function returns a reference to member map_type + * @return Reference to member map_type + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport CompleteMapType& map_type() + { + if (0x00000008 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_map_type; + } + + + /*! + * @brief This function copies the value in member enumerated_type + * @param _enumerated_type New value to be copied in member enumerated_type + */ + eProsima_user_DllExport void enumerated_type( + const CompleteEnumeratedType& _enumerated_type) + { + enumerated_type_() = _enumerated_type; + m__d = TK_ENUM; + } + + /*! + * @brief This function moves the value in member enumerated_type + * @param _enumerated_type New value to be moved in member enumerated_type + */ + eProsima_user_DllExport void enumerated_type( + CompleteEnumeratedType&& _enumerated_type) + { + enumerated_type_() = _enumerated_type; + m__d = TK_ENUM; + } + + /*! + * @brief This function returns a constant reference to member enumerated_type + * @return Constant reference to member enumerated_type + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport const CompleteEnumeratedType& enumerated_type() const + { + if (0x00000009 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_enumerated_type; + } + + /*! + * @brief This function returns a reference to member enumerated_type + * @return Reference to member enumerated_type + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport CompleteEnumeratedType& enumerated_type() + { + if (0x00000009 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_enumerated_type; + } + + + /*! + * @brief This function copies the value in member bitmask_type + * @param _bitmask_type New value to be copied in member bitmask_type + */ + eProsima_user_DllExport void bitmask_type( + const CompleteBitmaskType& _bitmask_type) + { + bitmask_type_() = _bitmask_type; + m__d = TK_BITMASK; + } + + /*! + * @brief This function moves the value in member bitmask_type + * @param _bitmask_type New value to be moved in member bitmask_type + */ + eProsima_user_DllExport void bitmask_type( + CompleteBitmaskType&& _bitmask_type) + { + bitmask_type_() = _bitmask_type; + m__d = TK_BITMASK; + } + + /*! + * @brief This function returns a constant reference to member bitmask_type + * @return Constant reference to member bitmask_type + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport const CompleteBitmaskType& bitmask_type() const + { + if (0x0000000a != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_bitmask_type; + } + + /*! + * @brief This function returns a reference to member bitmask_type + * @return Reference to member bitmask_type + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport CompleteBitmaskType& bitmask_type() + { + if (0x0000000a != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_bitmask_type; + } + + + /*! + * @brief This function copies the value in member extended_type + * @param _extended_type New value to be copied in member extended_type + */ + eProsima_user_DllExport void extended_type( + const CompleteExtendedType& _extended_type) + { + extended_type_() = _extended_type; + m__d = 0; + } + + /*! + * @brief This function moves the value in member extended_type + * @param _extended_type New value to be moved in member extended_type + */ + eProsima_user_DllExport void extended_type( + CompleteExtendedType&& _extended_type) + { + extended_type_() = _extended_type; + m__d = 0; + } + + /*! + * @brief This function returns a constant reference to member extended_type + * @return Constant reference to member extended_type + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport const CompleteExtendedType& extended_type() const + { + if (0x0000000b != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_extended_type; + } + + /*! + * @brief This function returns a reference to member extended_type + * @return Reference to member extended_type + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport CompleteExtendedType& extended_type() + { + if (0x0000000b != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_extended_type; + } + + + +private: + + CompleteAliasType& alias_type_() + { + if (0x00000001 != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x00000001; + member_destructor_ = [&]() {m_alias_type.~CompleteAliasType();}; + new(&m_alias_type) CompleteAliasType(); + ; + } + + return m_alias_type; + } + + CompleteAnnotationType& annotation_type_() + { + if (0x00000002 != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x00000002; + member_destructor_ = [&]() {m_annotation_type.~CompleteAnnotationType();}; + new(&m_annotation_type) CompleteAnnotationType(); + ; + } + + return m_annotation_type; + } + + CompleteStructType& struct_type_() + { + if (0x00000003 != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x00000003; + member_destructor_ = [&]() {m_struct_type.~CompleteStructType();}; + new(&m_struct_type) CompleteStructType(); + ; + } + + return m_struct_type; + } + + CompleteUnionType& union_type_() + { + if (0x00000004 != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x00000004; + member_destructor_ = [&]() {m_union_type.~CompleteUnionType();}; + new(&m_union_type) CompleteUnionType(); + ; + } + + return m_union_type; + } + + CompleteBitsetType& bitset_type_() + { + if (0x00000005 != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x00000005; + member_destructor_ = [&]() {m_bitset_type.~CompleteBitsetType();}; + new(&m_bitset_type) CompleteBitsetType(); + ; + } + + return m_bitset_type; + } + + CompleteSequenceType& sequence_type_() + { + if (0x00000006 != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x00000006; + member_destructor_ = [&]() {m_sequence_type.~CompleteSequenceType();}; + new(&m_sequence_type) CompleteSequenceType(); + ; + } + + return m_sequence_type; + } + + CompleteArrayType& array_type_() + { + if (0x00000007 != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x00000007; + member_destructor_ = [&]() {m_array_type.~CompleteArrayType();}; + new(&m_array_type) CompleteArrayType(); + ; + } + + return m_array_type; + } + + CompleteMapType& map_type_() + { + if (0x00000008 != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x00000008; + member_destructor_ = [&]() {m_map_type.~CompleteMapType();}; + new(&m_map_type) CompleteMapType(); + ; + } + + return m_map_type; + } + + CompleteEnumeratedType& enumerated_type_() + { + if (0x00000009 != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x00000009; + member_destructor_ = [&]() {m_enumerated_type.~CompleteEnumeratedType();}; + new(&m_enumerated_type) CompleteEnumeratedType(); + ; + } + + return m_enumerated_type; + } + + CompleteBitmaskType& bitmask_type_() + { + if (0x0000000a != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x0000000a; + member_destructor_ = [&]() {m_bitmask_type.~CompleteBitmaskType();}; + new(&m_bitmask_type) CompleteBitmaskType(); + ; + } + + return m_bitmask_type; + } + + CompleteExtendedType& extended_type_() + { + if (0x0000000b != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x0000000b; + member_destructor_ = [&]() {m_extended_type.~CompleteExtendedType();}; + new(&m_extended_type) CompleteExtendedType(); + ; + } + + return m_extended_type; + } + + + uint8_t m__d {0}; + + union + { + CompleteAliasType m_alias_type; + CompleteAnnotationType m_annotation_type; + CompleteStructType m_struct_type; + CompleteUnionType m_union_type; + CompleteBitsetType m_bitset_type; + CompleteSequenceType m_sequence_type; + CompleteArrayType m_array_type; + CompleteMapType m_map_type; + CompleteEnumeratedType m_enumerated_type; + CompleteBitmaskType m_bitmask_type; + CompleteExtendedType m_extended_type; + }; + + uint32_t selected_member_ {0x0FFFFFFFu}; + + std::function member_destructor_; +}; +/*! + * @brief This class represents the structure MinimalExtendedType defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalExtendedType +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport MinimalExtendedType() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~MinimalExtendedType() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object MinimalExtendedType that will be copied. + */ + eProsima_user_DllExport MinimalExtendedType( + const MinimalExtendedType& x) + { + static_cast(x); + } + + /*! + * @brief Move constructor. + * @param x Reference to the object MinimalExtendedType that will be copied. + */ + eProsima_user_DllExport MinimalExtendedType( + MinimalExtendedType&& x) noexcept + { + static_cast(x); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object MinimalExtendedType that will be copied. + */ + eProsima_user_DllExport MinimalExtendedType& operator =( + const MinimalExtendedType& x) + { + + static_cast(x); + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object MinimalExtendedType that will be copied. + */ + eProsima_user_DllExport MinimalExtendedType& operator =( + MinimalExtendedType&& x) noexcept + { + + static_cast(x); + + return *this; + } + + /*! + * @brief Comparison operator. + * @param x MinimalExtendedType object to compare. + */ + eProsima_user_DllExport bool operator ==( + const MinimalExtendedType& x) const + { + static_cast(x); + return true; + } + + /*! + * @brief Comparison operator. + * @param x MinimalExtendedType object to compare. + */ + eProsima_user_DllExport bool operator !=( + const MinimalExtendedType& x) const + { + return !(*this == x); + } + + + +private: + + +}; +/*! + * @brief This class represents the union MinimalTypeObject defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalTypeObject +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport MinimalTypeObject() + { + extended_type_(); + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~MinimalTypeObject() + { + if (member_destructor_) + { + member_destructor_(); + } + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object MinimalTypeObject that will be copied. + */ + eProsima_user_DllExport MinimalTypeObject( + const MinimalTypeObject& x) + { + m__d = x.m__d; + + switch (x.selected_member_) + { + case 0x00000001: + alias_type_() = x.m_alias_type; + break; + + case 0x00000002: + annotation_type_() = x.m_annotation_type; + break; + + case 0x00000003: + struct_type_() = x.m_struct_type; + break; + + case 0x00000004: + union_type_() = x.m_union_type; + break; + + case 0x00000005: + bitset_type_() = x.m_bitset_type; + break; + + case 0x00000006: + sequence_type_() = x.m_sequence_type; + break; + + case 0x00000007: + array_type_() = x.m_array_type; + break; + + case 0x00000008: + map_type_() = x.m_map_type; + break; + + case 0x00000009: + enumerated_type_() = x.m_enumerated_type; + break; + + case 0x0000000a: + bitmask_type_() = x.m_bitmask_type; + break; + + case 0x0000000b: + extended_type_() = x.m_extended_type; + break; + + } + } + + /*! + * @brief Move constructor. + * @param x Reference to the object MinimalTypeObject that will be copied. + */ + eProsima_user_DllExport MinimalTypeObject( + MinimalTypeObject&& x) noexcept + { + m__d = x.m__d; + + switch (x.selected_member_) + { + case 0x00000001: + alias_type_() = std::move(x.m_alias_type); + break; + + case 0x00000002: + annotation_type_() = std::move(x.m_annotation_type); + break; + + case 0x00000003: + struct_type_() = std::move(x.m_struct_type); + break; + + case 0x00000004: + union_type_() = std::move(x.m_union_type); + break; + + case 0x00000005: + bitset_type_() = std::move(x.m_bitset_type); + break; + + case 0x00000006: + sequence_type_() = std::move(x.m_sequence_type); + break; + + case 0x00000007: + array_type_() = std::move(x.m_array_type); + break; + + case 0x00000008: + map_type_() = std::move(x.m_map_type); + break; + + case 0x00000009: + enumerated_type_() = std::move(x.m_enumerated_type); + break; + + case 0x0000000a: + bitmask_type_() = std::move(x.m_bitmask_type); + break; + + case 0x0000000b: + extended_type_() = std::move(x.m_extended_type); + break; + + } + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object MinimalTypeObject that will be copied. + */ + eProsima_user_DllExport MinimalTypeObject& operator =( + const MinimalTypeObject& x) + { + m__d = x.m__d; + + switch (x.selected_member_) + { + case 0x00000001: + alias_type_() = x.m_alias_type; + break; + + case 0x00000002: + annotation_type_() = x.m_annotation_type; + break; + + case 0x00000003: + struct_type_() = x.m_struct_type; + break; + + case 0x00000004: + union_type_() = x.m_union_type; + break; + + case 0x00000005: + bitset_type_() = x.m_bitset_type; + break; + + case 0x00000006: + sequence_type_() = x.m_sequence_type; + break; + + case 0x00000007: + array_type_() = x.m_array_type; + break; + + case 0x00000008: + map_type_() = x.m_map_type; + break; + + case 0x00000009: + enumerated_type_() = x.m_enumerated_type; + break; + + case 0x0000000a: + bitmask_type_() = x.m_bitmask_type; + break; + + case 0x0000000b: + extended_type_() = x.m_extended_type; + break; + + } + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object MinimalTypeObject that will be copied. + */ + eProsima_user_DllExport MinimalTypeObject& operator =( + MinimalTypeObject&& x) noexcept + { + m__d = x.m__d; + + switch (x.selected_member_) + { + case 0x00000001: + alias_type_() = std::move(x.m_alias_type); + break; + + case 0x00000002: + annotation_type_() = std::move(x.m_annotation_type); + break; + + case 0x00000003: + struct_type_() = std::move(x.m_struct_type); + break; + + case 0x00000004: + union_type_() = std::move(x.m_union_type); + break; + + case 0x00000005: + bitset_type_() = std::move(x.m_bitset_type); + break; + + case 0x00000006: + sequence_type_() = std::move(x.m_sequence_type); + break; + + case 0x00000007: + array_type_() = std::move(x.m_array_type); + break; + + case 0x00000008: + map_type_() = std::move(x.m_map_type); + break; + + case 0x00000009: + enumerated_type_() = std::move(x.m_enumerated_type); + break; + + case 0x0000000a: + bitmask_type_() = std::move(x.m_bitmask_type); + break; + + case 0x0000000b: + extended_type_() = std::move(x.m_extended_type); + break; + + } + + return *this; + } + + /*! + * @brief Comparison operator. + * @param x MinimalTypeObject object to compare. + */ + eProsima_user_DllExport bool operator ==( + const MinimalTypeObject& x) const + { + bool ret_value {false}; + + if (m__d == x.m__d && + selected_member_ == x.selected_member_) + { + switch (selected_member_) + { + case 0x00000001: + ret_value = (m_alias_type == x.m_alias_type); + break; + + case 0x00000002: + ret_value = (m_annotation_type == x.m_annotation_type); + break; + + case 0x00000003: + ret_value = (m_struct_type == x.m_struct_type); + break; + + case 0x00000004: + ret_value = (m_union_type == x.m_union_type); + break; + + case 0x00000005: + ret_value = (m_bitset_type == x.m_bitset_type); + break; + + case 0x00000006: + ret_value = (m_sequence_type == x.m_sequence_type); + break; + + case 0x00000007: + ret_value = (m_array_type == x.m_array_type); + break; + + case 0x00000008: + ret_value = (m_map_type == x.m_map_type); + break; + + case 0x00000009: + ret_value = (m_enumerated_type == x.m_enumerated_type); + break; + + case 0x0000000a: + ret_value = (m_bitmask_type == x.m_bitmask_type); + break; + + case 0x0000000b: + ret_value = (m_extended_type == x.m_extended_type); + break; + + } + } + + return ret_value; + } + + /*! + * @brief Comparison operator. + * @param x MinimalTypeObject object to compare. + */ + eProsima_user_DllExport bool operator !=( + const MinimalTypeObject& x) const + { + return !(*this == x); + } + + /*! + * @brief This function sets the discriminator value. + * @param __d New value for the discriminator. + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the new value doesn't correspond to the selected union member. + */ + eProsima_user_DllExport void _d( + uint8_t __d) + { + bool valid_discriminator = false; + + switch (__d) + { + case TK_ALIAS: + if (0x00000001 == selected_member_) + { + valid_discriminator = true; + } + break; + + case TK_ANNOTATION: + if (0x00000002 == selected_member_) + { + valid_discriminator = true; + } + break; + + case TK_STRUCTURE: + if (0x00000003 == selected_member_) + { + valid_discriminator = true; + } + break; + + case TK_UNION: + if (0x00000004 == selected_member_) + { + valid_discriminator = true; + } + break; + + case TK_BITSET: + if (0x00000005 == selected_member_) + { + valid_discriminator = true; + } + break; + + case TK_SEQUENCE: + if (0x00000006 == selected_member_) + { + valid_discriminator = true; + } + break; + + case TK_ARRAY: + if (0x00000007 == selected_member_) + { + valid_discriminator = true; + } + break; + + case TK_MAP: + if (0x00000008 == selected_member_) + { + valid_discriminator = true; + } + break; + + case TK_ENUM: + if (0x00000009 == selected_member_) + { + valid_discriminator = true; + } + break; + + case TK_BITMASK: + if (0x0000000a == selected_member_) + { + valid_discriminator = true; + } + break; + + default: + if (0x0000000b == selected_member_) + { + valid_discriminator = true; + } + break; + + } + + if (!valid_discriminator) + { + throw eprosima::fastcdr::exception::BadParamException("Discriminator doesn't correspond with the selected union member"); + } + + m__d = __d; + } + + /*! + * @brief This function returns the value of the discriminator. + * @return Value of the discriminator + */ + eProsima_user_DllExport uint8_t _d() const + { + return m__d; + } + + /*! + * @brief This function copies the value in member alias_type + * @param _alias_type New value to be copied in member alias_type + */ + eProsima_user_DllExport void alias_type( + const MinimalAliasType& _alias_type) + { + alias_type_() = _alias_type; + m__d = TK_ALIAS; + } + + /*! + * @brief This function moves the value in member alias_type + * @param _alias_type New value to be moved in member alias_type + */ + eProsima_user_DllExport void alias_type( + MinimalAliasType&& _alias_type) + { + alias_type_() = _alias_type; + m__d = TK_ALIAS; + } + + /*! + * @brief This function returns a constant reference to member alias_type + * @return Constant reference to member alias_type + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport const MinimalAliasType& alias_type() const + { + if (0x00000001 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_alias_type; + } + + /*! + * @brief This function returns a reference to member alias_type + * @return Reference to member alias_type + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport MinimalAliasType& alias_type() + { + if (0x00000001 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_alias_type; + } + + + /*! + * @brief This function copies the value in member annotation_type + * @param _annotation_type New value to be copied in member annotation_type + */ + eProsima_user_DllExport void annotation_type( + const MinimalAnnotationType& _annotation_type) + { + annotation_type_() = _annotation_type; + m__d = TK_ANNOTATION; + } + + /*! + * @brief This function moves the value in member annotation_type + * @param _annotation_type New value to be moved in member annotation_type + */ + eProsima_user_DllExport void annotation_type( + MinimalAnnotationType&& _annotation_type) + { + annotation_type_() = _annotation_type; + m__d = TK_ANNOTATION; + } + + /*! + * @brief This function returns a constant reference to member annotation_type + * @return Constant reference to member annotation_type + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport const MinimalAnnotationType& annotation_type() const + { + if (0x00000002 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_annotation_type; + } + + /*! + * @brief This function returns a reference to member annotation_type + * @return Reference to member annotation_type + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport MinimalAnnotationType& annotation_type() + { + if (0x00000002 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_annotation_type; + } + + + /*! + * @brief This function copies the value in member struct_type + * @param _struct_type New value to be copied in member struct_type + */ + eProsima_user_DllExport void struct_type( + const MinimalStructType& _struct_type) + { + struct_type_() = _struct_type; + m__d = TK_STRUCTURE; + } + + /*! + * @brief This function moves the value in member struct_type + * @param _struct_type New value to be moved in member struct_type + */ + eProsima_user_DllExport void struct_type( + MinimalStructType&& _struct_type) + { + struct_type_() = _struct_type; + m__d = TK_STRUCTURE; + } + + /*! + * @brief This function returns a constant reference to member struct_type + * @return Constant reference to member struct_type + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport const MinimalStructType& struct_type() const + { + if (0x00000003 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_struct_type; + } + + /*! + * @brief This function returns a reference to member struct_type + * @return Reference to member struct_type + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport MinimalStructType& struct_type() + { + if (0x00000003 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_struct_type; + } + + + /*! + * @brief This function copies the value in member union_type + * @param _union_type New value to be copied in member union_type + */ + eProsima_user_DllExport void union_type( + const MinimalUnionType& _union_type) + { + union_type_() = _union_type; + m__d = TK_UNION; + } + + /*! + * @brief This function moves the value in member union_type + * @param _union_type New value to be moved in member union_type + */ + eProsima_user_DllExport void union_type( + MinimalUnionType&& _union_type) + { + union_type_() = _union_type; + m__d = TK_UNION; + } + + /*! + * @brief This function returns a constant reference to member union_type + * @return Constant reference to member union_type + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport const MinimalUnionType& union_type() const + { + if (0x00000004 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_union_type; + } + + /*! + * @brief This function returns a reference to member union_type + * @return Reference to member union_type + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport MinimalUnionType& union_type() + { + if (0x00000004 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_union_type; + } + + + /*! + * @brief This function copies the value in member bitset_type + * @param _bitset_type New value to be copied in member bitset_type + */ + eProsima_user_DllExport void bitset_type( + const MinimalBitsetType& _bitset_type) + { + bitset_type_() = _bitset_type; + m__d = TK_BITSET; + } + + /*! + * @brief This function moves the value in member bitset_type + * @param _bitset_type New value to be moved in member bitset_type + */ + eProsima_user_DllExport void bitset_type( + MinimalBitsetType&& _bitset_type) + { + bitset_type_() = _bitset_type; + m__d = TK_BITSET; + } + + /*! + * @brief This function returns a constant reference to member bitset_type + * @return Constant reference to member bitset_type + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport const MinimalBitsetType& bitset_type() const + { + if (0x00000005 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_bitset_type; + } + + /*! + * @brief This function returns a reference to member bitset_type + * @return Reference to member bitset_type + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport MinimalBitsetType& bitset_type() + { + if (0x00000005 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_bitset_type; + } + + + /*! + * @brief This function copies the value in member sequence_type + * @param _sequence_type New value to be copied in member sequence_type + */ + eProsima_user_DllExport void sequence_type( + const MinimalSequenceType& _sequence_type) + { + sequence_type_() = _sequence_type; + m__d = TK_SEQUENCE; + } + + /*! + * @brief This function moves the value in member sequence_type + * @param _sequence_type New value to be moved in member sequence_type + */ + eProsima_user_DllExport void sequence_type( + MinimalSequenceType&& _sequence_type) + { + sequence_type_() = _sequence_type; + m__d = TK_SEQUENCE; + } + + /*! + * @brief This function returns a constant reference to member sequence_type + * @return Constant reference to member sequence_type + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport const MinimalSequenceType& sequence_type() const + { + if (0x00000006 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_sequence_type; + } + + /*! + * @brief This function returns a reference to member sequence_type + * @return Reference to member sequence_type + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport MinimalSequenceType& sequence_type() + { + if (0x00000006 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_sequence_type; + } + + + /*! + * @brief This function copies the value in member array_type + * @param _array_type New value to be copied in member array_type + */ + eProsima_user_DllExport void array_type( + const MinimalArrayType& _array_type) + { + array_type_() = _array_type; + m__d = TK_ARRAY; + } + + /*! + * @brief This function moves the value in member array_type + * @param _array_type New value to be moved in member array_type + */ + eProsima_user_DllExport void array_type( + MinimalArrayType&& _array_type) + { + array_type_() = _array_type; + m__d = TK_ARRAY; + } + + /*! + * @brief This function returns a constant reference to member array_type + * @return Constant reference to member array_type + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport const MinimalArrayType& array_type() const + { + if (0x00000007 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_array_type; + } + + /*! + * @brief This function returns a reference to member array_type + * @return Reference to member array_type + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport MinimalArrayType& array_type() + { + if (0x00000007 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_array_type; + } + + + /*! + * @brief This function copies the value in member map_type + * @param _map_type New value to be copied in member map_type + */ + eProsima_user_DllExport void map_type( + const MinimalMapType& _map_type) + { + map_type_() = _map_type; + m__d = TK_MAP; + } + + /*! + * @brief This function moves the value in member map_type + * @param _map_type New value to be moved in member map_type + */ + eProsima_user_DllExport void map_type( + MinimalMapType&& _map_type) + { + map_type_() = _map_type; + m__d = TK_MAP; + } + + /*! + * @brief This function returns a constant reference to member map_type + * @return Constant reference to member map_type + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport const MinimalMapType& map_type() const + { + if (0x00000008 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_map_type; + } + + /*! + * @brief This function returns a reference to member map_type + * @return Reference to member map_type + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport MinimalMapType& map_type() + { + if (0x00000008 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_map_type; + } + + + /*! + * @brief This function copies the value in member enumerated_type + * @param _enumerated_type New value to be copied in member enumerated_type + */ + eProsima_user_DllExport void enumerated_type( + const MinimalEnumeratedType& _enumerated_type) + { + enumerated_type_() = _enumerated_type; + m__d = TK_ENUM; + } + + /*! + * @brief This function moves the value in member enumerated_type + * @param _enumerated_type New value to be moved in member enumerated_type + */ + eProsima_user_DllExport void enumerated_type( + MinimalEnumeratedType&& _enumerated_type) + { + enumerated_type_() = _enumerated_type; + m__d = TK_ENUM; + } + + /*! + * @brief This function returns a constant reference to member enumerated_type + * @return Constant reference to member enumerated_type + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport const MinimalEnumeratedType& enumerated_type() const + { + if (0x00000009 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_enumerated_type; + } + + /*! + * @brief This function returns a reference to member enumerated_type + * @return Reference to member enumerated_type + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport MinimalEnumeratedType& enumerated_type() + { + if (0x00000009 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_enumerated_type; + } + + + /*! + * @brief This function copies the value in member bitmask_type + * @param _bitmask_type New value to be copied in member bitmask_type + */ + eProsima_user_DllExport void bitmask_type( + const MinimalBitmaskType& _bitmask_type) + { + bitmask_type_() = _bitmask_type; + m__d = TK_BITMASK; + } + + /*! + * @brief This function moves the value in member bitmask_type + * @param _bitmask_type New value to be moved in member bitmask_type + */ + eProsima_user_DllExport void bitmask_type( + MinimalBitmaskType&& _bitmask_type) + { + bitmask_type_() = _bitmask_type; + m__d = TK_BITMASK; + } + + /*! + * @brief This function returns a constant reference to member bitmask_type + * @return Constant reference to member bitmask_type + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport const MinimalBitmaskType& bitmask_type() const + { + if (0x0000000a != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_bitmask_type; + } + + /*! + * @brief This function returns a reference to member bitmask_type + * @return Reference to member bitmask_type + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport MinimalBitmaskType& bitmask_type() + { + if (0x0000000a != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_bitmask_type; + } + + + /*! + * @brief This function copies the value in member extended_type + * @param _extended_type New value to be copied in member extended_type + */ + eProsima_user_DllExport void extended_type( + const MinimalExtendedType& _extended_type) + { + extended_type_() = _extended_type; + m__d = 0; + } + + /*! + * @brief This function moves the value in member extended_type + * @param _extended_type New value to be moved in member extended_type + */ + eProsima_user_DllExport void extended_type( + MinimalExtendedType&& _extended_type) + { + extended_type_() = _extended_type; + m__d = 0; + } + + /*! + * @brief This function returns a constant reference to member extended_type + * @return Constant reference to member extended_type + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport const MinimalExtendedType& extended_type() const + { + if (0x0000000b != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_extended_type; + } + + /*! + * @brief This function returns a reference to member extended_type + * @return Reference to member extended_type + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport MinimalExtendedType& extended_type() + { + if (0x0000000b != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_extended_type; + } + + + +private: + + MinimalAliasType& alias_type_() + { + if (0x00000001 != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x00000001; + member_destructor_ = [&]() {m_alias_type.~MinimalAliasType();}; + new(&m_alias_type) MinimalAliasType(); + ; + } + + return m_alias_type; + } + + MinimalAnnotationType& annotation_type_() + { + if (0x00000002 != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x00000002; + member_destructor_ = [&]() {m_annotation_type.~MinimalAnnotationType();}; + new(&m_annotation_type) MinimalAnnotationType(); + ; + } + + return m_annotation_type; + } + + MinimalStructType& struct_type_() + { + if (0x00000003 != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x00000003; + member_destructor_ = [&]() {m_struct_type.~MinimalStructType();}; + new(&m_struct_type) MinimalStructType(); + ; + } + + return m_struct_type; + } + + MinimalUnionType& union_type_() + { + if (0x00000004 != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x00000004; + member_destructor_ = [&]() {m_union_type.~MinimalUnionType();}; + new(&m_union_type) MinimalUnionType(); + ; + } + + return m_union_type; + } + + MinimalBitsetType& bitset_type_() + { + if (0x00000005 != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x00000005; + member_destructor_ = [&]() {m_bitset_type.~MinimalBitsetType();}; + new(&m_bitset_type) MinimalBitsetType(); + ; + } + + return m_bitset_type; + } + + MinimalSequenceType& sequence_type_() + { + if (0x00000006 != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x00000006; + member_destructor_ = [&]() {m_sequence_type.~MinimalSequenceType();}; + new(&m_sequence_type) MinimalSequenceType(); + ; + } + + return m_sequence_type; + } + + MinimalArrayType& array_type_() + { + if (0x00000007 != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x00000007; + member_destructor_ = [&]() {m_array_type.~MinimalArrayType();}; + new(&m_array_type) MinimalArrayType(); + ; + } + + return m_array_type; + } + + MinimalMapType& map_type_() + { + if (0x00000008 != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x00000008; + member_destructor_ = [&]() {m_map_type.~MinimalMapType();}; + new(&m_map_type) MinimalMapType(); + ; + } + + return m_map_type; + } + + MinimalEnumeratedType& enumerated_type_() + { + if (0x00000009 != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x00000009; + member_destructor_ = [&]() {m_enumerated_type.~MinimalEnumeratedType();}; + new(&m_enumerated_type) MinimalEnumeratedType(); + ; + } + + return m_enumerated_type; + } + + MinimalBitmaskType& bitmask_type_() + { + if (0x0000000a != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x0000000a; + member_destructor_ = [&]() {m_bitmask_type.~MinimalBitmaskType();}; + new(&m_bitmask_type) MinimalBitmaskType(); + ; + } + + return m_bitmask_type; + } + + MinimalExtendedType& extended_type_() + { + if (0x0000000b != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x0000000b; + member_destructor_ = [&]() {m_extended_type.~MinimalExtendedType();}; + new(&m_extended_type) MinimalExtendedType(); + ; + } + + return m_extended_type; + } + + + uint8_t m__d {0}; + + union + { + MinimalAliasType m_alias_type; + MinimalAnnotationType m_annotation_type; + MinimalStructType m_struct_type; + MinimalUnionType m_union_type; + MinimalBitsetType m_bitset_type; + MinimalSequenceType m_sequence_type; + MinimalArrayType m_array_type; + MinimalMapType m_map_type; + MinimalEnumeratedType m_enumerated_type; + MinimalBitmaskType m_bitmask_type; + MinimalExtendedType m_extended_type; + }; + + uint32_t selected_member_ {0x0FFFFFFFu}; + + std::function member_destructor_; +}; +/*! + * @brief This class represents the union TypeObject defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class TypeObject +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport TypeObject() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~TypeObject() + { + if (member_destructor_) + { + member_destructor_(); + } + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object TypeObject that will be copied. + */ + eProsima_user_DllExport TypeObject( + const TypeObject& x) + { + m__d = x.m__d; + + switch (x.selected_member_) + { + case 0x00000001: + complete_() = x.m_complete; + break; + + case 0x00000002: + minimal_() = x.m_minimal; + break; + + } + } + + /*! + * @brief Move constructor. + * @param x Reference to the object TypeObject that will be copied. + */ + eProsima_user_DllExport TypeObject( + TypeObject&& x) noexcept + { + m__d = x.m__d; + + switch (x.selected_member_) + { + case 0x00000001: + complete_() = std::move(x.m_complete); + break; + + case 0x00000002: + minimal_() = std::move(x.m_minimal); + break; + + } + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object TypeObject that will be copied. + */ + eProsima_user_DllExport TypeObject& operator =( + const TypeObject& x) + { + m__d = x.m__d; + + switch (x.selected_member_) + { + case 0x00000001: + complete_() = x.m_complete; + break; + + case 0x00000002: + minimal_() = x.m_minimal; + break; + + } + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object TypeObject that will be copied. + */ + eProsima_user_DllExport TypeObject& operator =( + TypeObject&& x) noexcept + { + m__d = x.m__d; + + switch (x.selected_member_) + { + case 0x00000001: + complete_() = std::move(x.m_complete); + break; + + case 0x00000002: + minimal_() = std::move(x.m_minimal); + break; + + } + + return *this; + } + + /*! + * @brief Comparison operator. + * @param x TypeObject object to compare. + */ + eProsima_user_DllExport bool operator ==( + const TypeObject& x) const + { + bool ret_value {false}; + + if (m__d == x.m__d && + selected_member_ == x.selected_member_) + { + switch (selected_member_) + { + case 0x00000001: + ret_value = (m_complete == x.m_complete); + break; + + case 0x00000002: + ret_value = (m_minimal == x.m_minimal); + break; + + } + } + + return ret_value; + } + + /*! + * @brief Comparison operator. + * @param x TypeObject object to compare. + */ + eProsima_user_DllExport bool operator !=( + const TypeObject& x) const + { + return !(*this == x); + } + + /*! + * @brief This function sets the discriminator value. + * @param __d New value for the discriminator. + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the new value doesn't correspond to the selected union member. + */ + eProsima_user_DllExport void _d( + uint8_t __d) + { + bool valid_discriminator = false; + + switch (__d) + { + case EK_COMPLETE: + if (0x00000001 == selected_member_) + { + valid_discriminator = true; + } + break; + + case EK_MINIMAL: + if (0x00000002 == selected_member_) + { + valid_discriminator = true; + } + break; + + } + + if (!valid_discriminator) + { + throw eprosima::fastcdr::exception::BadParamException("Discriminator doesn't correspond with the selected union member"); + } + + m__d = __d; + } + + /*! + * @brief This function returns the value of the discriminator. + * @return Value of the discriminator + */ + eProsima_user_DllExport uint8_t _d() const + { + return m__d; + } + + /*! + * @brief This function copies the value in member complete + * @param _complete New value to be copied in member complete + */ + eProsima_user_DllExport void complete( + const CompleteTypeObject& _complete) + { + complete_() = _complete; + m__d = EK_COMPLETE; + } + + /*! + * @brief This function moves the value in member complete + * @param _complete New value to be moved in member complete + */ + eProsima_user_DllExport void complete( + CompleteTypeObject&& _complete) + { + complete_() = _complete; + m__d = EK_COMPLETE; + } + + /*! + * @brief This function returns a constant reference to member complete + * @return Constant reference to member complete + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport const CompleteTypeObject& complete() const + { + if (0x00000001 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_complete; + } + + /*! + * @brief This function returns a reference to member complete + * @return Reference to member complete + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport CompleteTypeObject& complete() + { + if (0x00000001 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_complete; + } + + + /*! + * @brief This function copies the value in member minimal + * @param _minimal New value to be copied in member minimal + */ + eProsima_user_DllExport void minimal( + const MinimalTypeObject& _minimal) + { + minimal_() = _minimal; + m__d = EK_MINIMAL; + } + + /*! + * @brief This function moves the value in member minimal + * @param _minimal New value to be moved in member minimal + */ + eProsima_user_DllExport void minimal( + MinimalTypeObject&& _minimal) + { + minimal_() = _minimal; + m__d = EK_MINIMAL; + } + + /*! + * @brief This function returns a constant reference to member minimal + * @return Constant reference to member minimal + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport const MinimalTypeObject& minimal() const + { + if (0x00000002 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_minimal; + } + + /*! + * @brief This function returns a reference to member minimal + * @return Reference to member minimal + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport MinimalTypeObject& minimal() + { + if (0x00000002 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_minimal; + } + + + void _default() + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x0FFFFFFFu; + } + + +private: + + CompleteTypeObject& complete_() + { + if (0x00000001 != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x00000001; + member_destructor_ = [&]() {m_complete.~CompleteTypeObject();}; + new(&m_complete) CompleteTypeObject(); + ; + } + + return m_complete; + } + + MinimalTypeObject& minimal_() + { + if (0x00000002 != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x00000002; + member_destructor_ = [&]() {m_minimal.~MinimalTypeObject();}; + new(&m_minimal) MinimalTypeObject(); + ; + } + + return m_minimal; + } + + + uint8_t m__d {0}; + + union + { + CompleteTypeObject m_complete; + MinimalTypeObject m_minimal; + }; + + uint32_t selected_member_ {0x0FFFFFFFu}; + + std::function member_destructor_; +}; +typedef std::vector TypeObjectSeq; + +typedef TypeObjectSeq StronglyConnectedComponent; + +/*! + * @brief This class represents the structure TypeIdentifierTypeObjectPair defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class TypeIdentifierTypeObjectPair +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport TypeIdentifierTypeObjectPair() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~TypeIdentifierTypeObjectPair() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object TypeIdentifierTypeObjectPair that will be copied. + */ + eProsima_user_DllExport TypeIdentifierTypeObjectPair( + const TypeIdentifierTypeObjectPair& x) + { + m_type_identifier = x.m_type_identifier; + + m_type_object = x.m_type_object; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object TypeIdentifierTypeObjectPair that will be copied. + */ + eProsima_user_DllExport TypeIdentifierTypeObjectPair( + TypeIdentifierTypeObjectPair&& x) noexcept + { + m_type_identifier = std::move(x.m_type_identifier); + m_type_object = std::move(x.m_type_object); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object TypeIdentifierTypeObjectPair that will be copied. + */ + eProsima_user_DllExport TypeIdentifierTypeObjectPair& operator =( + const TypeIdentifierTypeObjectPair& x) + { + + m_type_identifier = x.m_type_identifier; + + m_type_object = x.m_type_object; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object TypeIdentifierTypeObjectPair that will be copied. + */ + eProsima_user_DllExport TypeIdentifierTypeObjectPair& operator =( + TypeIdentifierTypeObjectPair&& x) noexcept + { + + m_type_identifier = std::move(x.m_type_identifier); + m_type_object = std::move(x.m_type_object); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x TypeIdentifierTypeObjectPair object to compare. + */ + eProsima_user_DllExport bool operator ==( + const TypeIdentifierTypeObjectPair& x) const + { + return (m_type_identifier == x.m_type_identifier && + m_type_object == x.m_type_object); + } + + /*! + * @brief Comparison operator. + * @param x TypeIdentifierTypeObjectPair object to compare. + */ + eProsima_user_DllExport bool operator !=( + const TypeIdentifierTypeObjectPair& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member type_identifier + * @param _type_identifier New value to be copied in member type_identifier + */ + eProsima_user_DllExport void type_identifier( + const TypeIdentifier& _type_identifier) + { + m_type_identifier = _type_identifier; + } + + /*! + * @brief This function moves the value in member type_identifier + * @param _type_identifier New value to be moved in member type_identifier + */ + eProsima_user_DllExport void type_identifier( + TypeIdentifier&& _type_identifier) + { + m_type_identifier = std::move(_type_identifier); + } + + /*! + * @brief This function returns a constant reference to member type_identifier + * @return Constant reference to member type_identifier + */ + eProsima_user_DllExport const TypeIdentifier& type_identifier() const + { + return m_type_identifier; + } + + /*! + * @brief This function returns a reference to member type_identifier + * @return Reference to member type_identifier + */ + eProsima_user_DllExport TypeIdentifier& type_identifier() + { + return m_type_identifier; + } + + + /*! + * @brief This function copies the value in member type_object + * @param _type_object New value to be copied in member type_object + */ + eProsima_user_DllExport void type_object( + const TypeObject& _type_object) + { + m_type_object = _type_object; + } + + /*! + * @brief This function moves the value in member type_object + * @param _type_object New value to be moved in member type_object + */ + eProsima_user_DllExport void type_object( + TypeObject&& _type_object) + { + m_type_object = std::move(_type_object); + } + + /*! + * @brief This function returns a constant reference to member type_object + * @return Constant reference to member type_object + */ + eProsima_user_DllExport const TypeObject& type_object() const + { + return m_type_object; + } + + /*! + * @brief This function returns a reference to member type_object + * @return Reference to member type_object + */ + eProsima_user_DllExport TypeObject& type_object() + { + return m_type_object; + } + + + +private: + + TypeIdentifier m_type_identifier; + TypeObject m_type_object; + +}; +typedef std::vector TypeIdentifierTypeObjectPairSeq; + +/*! + * @brief This class represents the structure TypeIdentifierPair defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class TypeIdentifierPair +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport TypeIdentifierPair() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~TypeIdentifierPair() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object TypeIdentifierPair that will be copied. + */ + eProsima_user_DllExport TypeIdentifierPair( + const TypeIdentifierPair& x) + { + m_type_identifier1 = x.m_type_identifier1; + + m_type_identifier2 = x.m_type_identifier2; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object TypeIdentifierPair that will be copied. + */ + eProsima_user_DllExport TypeIdentifierPair( + TypeIdentifierPair&& x) noexcept + { + m_type_identifier1 = std::move(x.m_type_identifier1); + m_type_identifier2 = std::move(x.m_type_identifier2); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object TypeIdentifierPair that will be copied. + */ + eProsima_user_DllExport TypeIdentifierPair& operator =( + const TypeIdentifierPair& x) + { + + m_type_identifier1 = x.m_type_identifier1; + + m_type_identifier2 = x.m_type_identifier2; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object TypeIdentifierPair that will be copied. + */ + eProsima_user_DllExport TypeIdentifierPair& operator =( + TypeIdentifierPair&& x) noexcept + { + + m_type_identifier1 = std::move(x.m_type_identifier1); + m_type_identifier2 = std::move(x.m_type_identifier2); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x TypeIdentifierPair object to compare. + */ + eProsima_user_DllExport bool operator ==( + const TypeIdentifierPair& x) const + { + return (m_type_identifier1 == x.m_type_identifier1 && + m_type_identifier2 == x.m_type_identifier2); + } + + /*! + * @brief Comparison operator. + * @param x TypeIdentifierPair object to compare. + */ + eProsima_user_DllExport bool operator !=( + const TypeIdentifierPair& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member type_identifier1 + * @param _type_identifier1 New value to be copied in member type_identifier1 + */ + eProsima_user_DllExport void type_identifier1( + const TypeIdentifier& _type_identifier1) + { + m_type_identifier1 = _type_identifier1; + } + + /*! + * @brief This function moves the value in member type_identifier1 + * @param _type_identifier1 New value to be moved in member type_identifier1 + */ + eProsima_user_DllExport void type_identifier1( + TypeIdentifier&& _type_identifier1) + { + m_type_identifier1 = std::move(_type_identifier1); + } + + /*! + * @brief This function returns a constant reference to member type_identifier1 + * @return Constant reference to member type_identifier1 + */ + eProsima_user_DllExport const TypeIdentifier& type_identifier1() const + { + return m_type_identifier1; + } + + /*! + * @brief This function returns a reference to member type_identifier1 + * @return Reference to member type_identifier1 + */ + eProsima_user_DllExport TypeIdentifier& type_identifier1() + { + return m_type_identifier1; + } + + + /*! + * @brief This function copies the value in member type_identifier2 + * @param _type_identifier2 New value to be copied in member type_identifier2 + */ + eProsima_user_DllExport void type_identifier2( + const TypeIdentifier& _type_identifier2) + { + m_type_identifier2 = _type_identifier2; + } + + /*! + * @brief This function moves the value in member type_identifier2 + * @param _type_identifier2 New value to be moved in member type_identifier2 + */ + eProsima_user_DllExport void type_identifier2( + TypeIdentifier&& _type_identifier2) + { + m_type_identifier2 = std::move(_type_identifier2); + } + + /*! + * @brief This function returns a constant reference to member type_identifier2 + * @return Constant reference to member type_identifier2 + */ + eProsima_user_DllExport const TypeIdentifier& type_identifier2() const + { + return m_type_identifier2; + } + + /*! + * @brief This function returns a reference to member type_identifier2 + * @return Reference to member type_identifier2 + */ + eProsima_user_DllExport TypeIdentifier& type_identifier2() + { + return m_type_identifier2; + } + + + +private: + + TypeIdentifier m_type_identifier1; + TypeIdentifier m_type_identifier2; + +}; +typedef std::vector TypeIdentifierPairSeq; + +/*! + * @brief This class represents the structure TypeIdentfierWithSize defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class TypeIdentfierWithSize +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport TypeIdentfierWithSize() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~TypeIdentfierWithSize() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object TypeIdentfierWithSize that will be copied. + */ + eProsima_user_DllExport TypeIdentfierWithSize( + const TypeIdentfierWithSize& x) + { + m_type_id = x.m_type_id; + + m_typeobject_serialized_size = x.m_typeobject_serialized_size; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object TypeIdentfierWithSize that will be copied. + */ + eProsima_user_DllExport TypeIdentfierWithSize( + TypeIdentfierWithSize&& x) noexcept + { + m_type_id = std::move(x.m_type_id); + m_typeobject_serialized_size = x.m_typeobject_serialized_size; + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object TypeIdentfierWithSize that will be copied. + */ + eProsima_user_DllExport TypeIdentfierWithSize& operator =( + const TypeIdentfierWithSize& x) + { + + m_type_id = x.m_type_id; + + m_typeobject_serialized_size = x.m_typeobject_serialized_size; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object TypeIdentfierWithSize that will be copied. + */ + eProsima_user_DllExport TypeIdentfierWithSize& operator =( + TypeIdentfierWithSize&& x) noexcept + { + + m_type_id = std::move(x.m_type_id); + m_typeobject_serialized_size = x.m_typeobject_serialized_size; + return *this; + } + + /*! + * @brief Comparison operator. + * @param x TypeIdentfierWithSize object to compare. + */ + eProsima_user_DllExport bool operator ==( + const TypeIdentfierWithSize& x) const + { + return (m_type_id == x.m_type_id && + m_typeobject_serialized_size == x.m_typeobject_serialized_size); + } + + /*! + * @brief Comparison operator. + * @param x TypeIdentfierWithSize object to compare. + */ + eProsima_user_DllExport bool operator !=( + const TypeIdentfierWithSize& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member type_id + * @param _type_id New value to be copied in member type_id + */ + eProsima_user_DllExport void type_id( + const TypeIdentifier& _type_id) + { + m_type_id = _type_id; + } + + /*! + * @brief This function moves the value in member type_id + * @param _type_id New value to be moved in member type_id + */ + eProsima_user_DllExport void type_id( + TypeIdentifier&& _type_id) + { + m_type_id = std::move(_type_id); + } + + /*! + * @brief This function returns a constant reference to member type_id + * @return Constant reference to member type_id + */ + eProsima_user_DllExport const TypeIdentifier& type_id() const + { + return m_type_id; + } + + /*! + * @brief This function returns a reference to member type_id + * @return Reference to member type_id + */ + eProsima_user_DllExport TypeIdentifier& type_id() + { + return m_type_id; + } + + + /*! + * @brief This function sets a value in member typeobject_serialized_size + * @param _typeobject_serialized_size New value for member typeobject_serialized_size + */ + eProsima_user_DllExport void typeobject_serialized_size( + uint32_t _typeobject_serialized_size) + { + m_typeobject_serialized_size = _typeobject_serialized_size; + } + + /*! + * @brief This function returns the value of member typeobject_serialized_size + * @return Value of member typeobject_serialized_size + */ + eProsima_user_DllExport uint32_t typeobject_serialized_size() const + { + return m_typeobject_serialized_size; + } + + /*! + * @brief This function returns a reference to member typeobject_serialized_size + * @return Reference to member typeobject_serialized_size + */ + eProsima_user_DllExport uint32_t& typeobject_serialized_size() + { + return m_typeobject_serialized_size; + } + + + +private: + + TypeIdentifier m_type_id; + uint32_t m_typeobject_serialized_size{0}; + +}; +typedef std::vector TypeIdentfierWithSizeSeq; + +/*! + * @brief This class represents the structure TypeIdentifierWithDependencies defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class TypeIdentifierWithDependencies +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport TypeIdentifierWithDependencies() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~TypeIdentifierWithDependencies() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object TypeIdentifierWithDependencies that will be copied. + */ + eProsima_user_DllExport TypeIdentifierWithDependencies( + const TypeIdentifierWithDependencies& x) + { + m_typeid_with_size = x.m_typeid_with_size; + + m_dependent_typeid_count = x.m_dependent_typeid_count; + + m_dependent_typeids = x.m_dependent_typeids; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object TypeIdentifierWithDependencies that will be copied. + */ + eProsima_user_DllExport TypeIdentifierWithDependencies( + TypeIdentifierWithDependencies&& x) noexcept + { + m_typeid_with_size = std::move(x.m_typeid_with_size); + m_dependent_typeid_count = x.m_dependent_typeid_count; + m_dependent_typeids = std::move(x.m_dependent_typeids); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object TypeIdentifierWithDependencies that will be copied. + */ + eProsima_user_DllExport TypeIdentifierWithDependencies& operator =( + const TypeIdentifierWithDependencies& x) + { + + m_typeid_with_size = x.m_typeid_with_size; + + m_dependent_typeid_count = x.m_dependent_typeid_count; + + m_dependent_typeids = x.m_dependent_typeids; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object TypeIdentifierWithDependencies that will be copied. + */ + eProsima_user_DllExport TypeIdentifierWithDependencies& operator =( + TypeIdentifierWithDependencies&& x) noexcept + { + + m_typeid_with_size = std::move(x.m_typeid_with_size); + m_dependent_typeid_count = x.m_dependent_typeid_count; + m_dependent_typeids = std::move(x.m_dependent_typeids); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x TypeIdentifierWithDependencies object to compare. + */ + eProsima_user_DllExport bool operator ==( + const TypeIdentifierWithDependencies& x) const + { + return (m_typeid_with_size == x.m_typeid_with_size && + m_dependent_typeid_count == x.m_dependent_typeid_count && + m_dependent_typeids == x.m_dependent_typeids); + } + + /*! + * @brief Comparison operator. + * @param x TypeIdentifierWithDependencies object to compare. + */ + eProsima_user_DllExport bool operator !=( + const TypeIdentifierWithDependencies& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member typeid_with_size + * @param _typeid_with_size New value to be copied in member typeid_with_size + */ + eProsima_user_DllExport void typeid_with_size( + const TypeIdentfierWithSize& _typeid_with_size) + { + m_typeid_with_size = _typeid_with_size; + } + + /*! + * @brief This function moves the value in member typeid_with_size + * @param _typeid_with_size New value to be moved in member typeid_with_size + */ + eProsima_user_DllExport void typeid_with_size( + TypeIdentfierWithSize&& _typeid_with_size) + { + m_typeid_with_size = std::move(_typeid_with_size); + } + + /*! + * @brief This function returns a constant reference to member typeid_with_size + * @return Constant reference to member typeid_with_size + */ + eProsima_user_DllExport const TypeIdentfierWithSize& typeid_with_size() const + { + return m_typeid_with_size; + } + + /*! + * @brief This function returns a reference to member typeid_with_size + * @return Reference to member typeid_with_size + */ + eProsima_user_DllExport TypeIdentfierWithSize& typeid_with_size() + { + return m_typeid_with_size; + } + + + /*! + * @brief This function sets a value in member dependent_typeid_count + * @param _dependent_typeid_count New value for member dependent_typeid_count + */ + eProsima_user_DllExport void dependent_typeid_count( + int32_t _dependent_typeid_count) + { + m_dependent_typeid_count = _dependent_typeid_count; + } + + /*! + * @brief This function returns the value of member dependent_typeid_count + * @return Value of member dependent_typeid_count + */ + eProsima_user_DllExport int32_t dependent_typeid_count() const + { + return m_dependent_typeid_count; + } + + /*! + * @brief This function returns a reference to member dependent_typeid_count + * @return Reference to member dependent_typeid_count + */ + eProsima_user_DllExport int32_t& dependent_typeid_count() + { + return m_dependent_typeid_count; + } + + + /*! + * @brief This function copies the value in member dependent_typeids + * @param _dependent_typeids New value to be copied in member dependent_typeids + */ + eProsima_user_DllExport void dependent_typeids( + const std::vector& _dependent_typeids) + { + m_dependent_typeids = _dependent_typeids; + } + + /*! + * @brief This function moves the value in member dependent_typeids + * @param _dependent_typeids New value to be moved in member dependent_typeids + */ + eProsima_user_DllExport void dependent_typeids( + std::vector&& _dependent_typeids) + { + m_dependent_typeids = std::move(_dependent_typeids); + } + + /*! + * @brief This function returns a constant reference to member dependent_typeids + * @return Constant reference to member dependent_typeids + */ + eProsima_user_DllExport const std::vector& dependent_typeids() const + { + return m_dependent_typeids; + } + + /*! + * @brief This function returns a reference to member dependent_typeids + * @return Reference to member dependent_typeids + */ + eProsima_user_DllExport std::vector& dependent_typeids() + { + return m_dependent_typeids; + } + + + +private: + + TypeIdentfierWithSize m_typeid_with_size; + int32_t m_dependent_typeid_count{0}; + std::vector m_dependent_typeids; + +}; +typedef std::vector TypeIdentifierWithDependenciesSeq; + +/*! + * @brief This class represents the structure TypeInformation defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class TypeInformation +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport TypeInformation() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~TypeInformation() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object TypeInformation that will be copied. + */ + eProsima_user_DllExport TypeInformation( + const TypeInformation& x) + { + m_minimal = x.m_minimal; + + m_complete = x.m_complete; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object TypeInformation that will be copied. + */ + eProsima_user_DllExport TypeInformation( + TypeInformation&& x) noexcept + { + m_minimal = std::move(x.m_minimal); + m_complete = std::move(x.m_complete); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object TypeInformation that will be copied. + */ + eProsima_user_DllExport TypeInformation& operator =( + const TypeInformation& x) + { + + m_minimal = x.m_minimal; + + m_complete = x.m_complete; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object TypeInformation that will be copied. + */ + eProsima_user_DllExport TypeInformation& operator =( + TypeInformation&& x) noexcept + { + + m_minimal = std::move(x.m_minimal); + m_complete = std::move(x.m_complete); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x TypeInformation object to compare. + */ + eProsima_user_DllExport bool operator ==( + const TypeInformation& x) const + { + return (m_minimal == x.m_minimal && + m_complete == x.m_complete); + } + + /*! + * @brief Comparison operator. + * @param x TypeInformation object to compare. + */ + eProsima_user_DllExport bool operator !=( + const TypeInformation& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member minimal + * @param _minimal New value to be copied in member minimal + */ + eProsima_user_DllExport void minimal( + const TypeIdentifierWithDependencies& _minimal) + { + m_minimal = _minimal; + } + + /*! + * @brief This function moves the value in member minimal + * @param _minimal New value to be moved in member minimal + */ + eProsima_user_DllExport void minimal( + TypeIdentifierWithDependencies&& _minimal) + { + m_minimal = std::move(_minimal); + } + + /*! + * @brief This function returns a constant reference to member minimal + * @return Constant reference to member minimal + */ + eProsima_user_DllExport const TypeIdentifierWithDependencies& minimal() const + { + return m_minimal; + } + + /*! + * @brief This function returns a reference to member minimal + * @return Reference to member minimal + */ + eProsima_user_DllExport TypeIdentifierWithDependencies& minimal() + { + return m_minimal; + } + + + /*! + * @brief This function copies the value in member complete + * @param _complete New value to be copied in member complete + */ + eProsima_user_DllExport void complete( + const TypeIdentifierWithDependencies& _complete) + { + m_complete = _complete; + } + + /*! + * @brief This function moves the value in member complete + * @param _complete New value to be moved in member complete + */ + eProsima_user_DllExport void complete( + TypeIdentifierWithDependencies&& _complete) + { + m_complete = std::move(_complete); + } + + /*! + * @brief This function returns a constant reference to member complete + * @return Constant reference to member complete + */ + eProsima_user_DllExport const TypeIdentifierWithDependencies& complete() const + { + return m_complete; + } + + /*! + * @brief This function returns a reference to member complete + * @return Reference to member complete + */ + eProsima_user_DllExport TypeIdentifierWithDependencies& complete() + { + return m_complete; + } + + + +private: + + TypeIdentifierWithDependencies m_minimal; + TypeIdentifierWithDependencies m_complete; + +}; +typedef std::vector TypeInformationSeq; + + +} // namespace xtypes + + +} // namespace dds + +} // namespace fastdds + +} // namespace eprosima + + +#endif // _FAST_DDS_GENERATED_EPROSIMA_FASTDDS_DDS_XTYPES_DDS_XTYPES_TYPEOBJECT_HPP_ + + diff --git a/include/fastdds/dds/xtypes/type_representation/detail/dds_xtypes_typeobjectCdrAux.hpp b/include/fastdds/dds/xtypes/type_representation/detail/dds_xtypes_typeobjectCdrAux.hpp new file mode 100644 index 00000000000..4a9d0b5e4da --- /dev/null +++ b/include/fastdds/dds/xtypes/type_representation/detail/dds_xtypes_typeobjectCdrAux.hpp @@ -0,0 +1,808 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file dds_xtypes_typeobjectCdrAux.hpp + * This source file contains some definitions of CDR related functions. + * + * This file was generated by the tool fastddsgen. + */ + +#ifndef _FAST_DDS_GENERATED_EPROSIMA_FASTDDS_DDS_XTYPES_DDS_XTYPES_TYPEOBJECTCDRAUX_HPP_ +#define _FAST_DDS_GENERATED_EPROSIMA_FASTDDS_DDS_XTYPES_DDS_XTYPES_TYPEOBJECTCDRAUX_HPP_ + +#include "dds_xtypes_typeobject.hpp" + +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteStructMember_max_cdr_typesize {1436UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteStructMember_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteBitflag_max_cdr_typesize {1404UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteBitflag_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_PlainArraySElemDefn_max_cdr_typesize {40UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_PlainArraySElemDefn_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_CommonEnumeratedLiteral_max_cdr_typesize {10UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_CommonEnumeratedLiteral_max_key_cdr_typesize {0UL}; + + +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalBitsetType_max_cdr_typesize {20UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalBitsetType_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_CommonBitflag_max_cdr_typesize {4UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_CommonBitflag_max_key_cdr_typesize {0UL}; + + +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalAliasType_max_cdr_typesize {44UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalAliasType_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteEnumeratedType_max_cdr_typesize {672UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteEnumeratedType_max_key_cdr_typesize {0UL}; + + + + +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteUnionHeader_max_cdr_typesize {653UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteUnionHeader_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalDiscriminatorMember_max_cdr_typesize {36UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalDiscriminatorMember_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteAliasHeader_max_cdr_typesize {653UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteAliasHeader_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteStructType_max_cdr_typesize {700UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteStructType_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_CommonCollectionElement_max_cdr_typesize {32UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_CommonCollectionElement_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalCollectionElement_max_cdr_typesize {36UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalCollectionElement_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_PlainCollectionHeader_max_cdr_typesize {4UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_PlainCollectionHeader_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_ExtendedAnnotationParameterValue_max_cdr_typesize {4UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_ExtendedAnnotationParameterValue_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalUnionHeader_max_cdr_typesize {4UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalUnionHeader_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalCollectionHeader_max_cdr_typesize {8UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalCollectionHeader_max_key_cdr_typesize {0UL}; + + + +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalAnnotationType_max_cdr_typesize {16UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalAnnotationType_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalAliasHeader_max_cdr_typesize {4UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalAliasHeader_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_CommonUnionMember_max_cdr_typesize {40UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_CommonUnionMember_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_CommonCollectionHeader_max_cdr_typesize {4UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_CommonCollectionHeader_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalArrayType_max_cdr_typesize {48UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalArrayType_max_key_cdr_typesize {0UL}; + + +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteBitsetType_max_cdr_typesize {672UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteBitsetType_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_PlainArrayLElemDefn_max_cdr_typesize {40UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_PlainArrayLElemDefn_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_CommonAliasBody_max_cdr_typesize {32UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_CommonAliasBody_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_CommonBitfield_max_cdr_typesize {6UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_CommonBitfield_max_key_cdr_typesize {0UL}; + + + + +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalStructHeader_max_cdr_typesize {36UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalStructHeader_max_key_cdr_typesize {0UL}; + + + + +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalAnnotationParameter_max_cdr_typesize {304UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalAnnotationParameter_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteExtendedType_max_cdr_typesize {4UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteExtendedType_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteAnnotationHeader_max_cdr_typesize {265UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteAnnotationHeader_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalEnumeratedLiteral_max_cdr_typesize {18UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalEnumeratedLiteral_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteAliasType_max_cdr_typesize {1828UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteAliasType_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_CommonBitmaskHeader_max_cdr_typesize {2UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_CommonBitmaskHeader_max_key_cdr_typesize {0UL}; + + + + + +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalStructMember_max_cdr_typesize {44UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalStructMember_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteTypeDetail_max_cdr_typesize {649UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteTypeDetail_max_key_cdr_typesize {0UL}; + + + + +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalBitmaskType_max_cdr_typesize {24UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalBitmaskType_max_key_cdr_typesize {0UL}; + + +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteArrayHeader_max_cdr_typesize {657UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteArrayHeader_max_key_cdr_typesize {0UL}; + + +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalStructType_max_cdr_typesize {48UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalStructType_max_key_cdr_typesize {0UL}; + + + +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteMapType_max_cdr_typesize {3012UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteMapType_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteEnumeratedHeader_max_cdr_typesize {657UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteEnumeratedHeader_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteBitsetHeader_max_cdr_typesize {653UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteBitsetHeader_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteBitfield_max_cdr_typesize {1408UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteBitfield_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_TypeIdentifierPair_max_cdr_typesize {64UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_TypeIdentifierPair_max_key_cdr_typesize {0UL}; + + +constexpr uint32_t eprosima_fastdds_dds_xtypes_AppliedBuiltinMemberAnnotations_max_cdr_typesize {1100UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_AppliedBuiltinMemberAnnotations_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalMemberDetail_max_cdr_typesize {4UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalMemberDetail_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_AppliedBuiltinTypeAnnotations_max_cdr_typesize {356UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_AppliedBuiltinTypeAnnotations_max_key_cdr_typesize {0UL}; + + + +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteCollectionHeader_max_cdr_typesize {669UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteCollectionHeader_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalMapType_max_cdr_typesize {84UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalMapType_max_key_cdr_typesize {0UL}; + + + + +constexpr uint32_t eprosima_fastdds_dds_xtypes_TypeInformation_max_cdr_typesize {140UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_TypeInformation_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteEnumeratedLiteral_max_cdr_typesize {1412UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteEnumeratedLiteral_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteCollectionElement_max_cdr_typesize {1168UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteCollectionElement_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalAnnotationHeader_max_cdr_typesize {4UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalAnnotationHeader_max_key_cdr_typesize {0UL}; + + + + + +constexpr uint32_t eprosima_fastdds_dds_xtypes_TypeIdentifierWithDependencies_max_cdr_typesize {56UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_TypeIdentifierWithDependencies_max_key_cdr_typesize {0UL}; + + +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalEnumeratedType_max_cdr_typesize {20UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalEnumeratedType_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteArrayType_max_cdr_typesize {1836UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteArrayType_max_key_cdr_typesize {0UL}; + + + + +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteStructHeader_max_cdr_typesize {685UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteStructHeader_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteAnnotationType_max_cdr_typesize {280UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteAnnotationType_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_AppliedAnnotationParameter_max_cdr_typesize {272UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_AppliedAnnotationParameter_max_key_cdr_typesize {0UL}; + + + +constexpr uint32_t eprosima_fastdds_dds_xtypes_PlainMapSTypeDefn_max_cdr_typesize {68UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_PlainMapSTypeDefn_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalAliasBody_max_cdr_typesize {36UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalAliasBody_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_PlainSequenceLElemDefn_max_cdr_typesize {40UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_PlainSequenceLElemDefn_max_key_cdr_typesize {0UL}; + + + +constexpr uint32_t eprosima_fastdds_dds_xtypes_StringSTypeDefn_max_cdr_typesize {1UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_StringSTypeDefn_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_ExtendedTypeDefn_max_cdr_typesize {4UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_ExtendedTypeDefn_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteElementDetail_max_cdr_typesize {1132UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteElementDetail_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteAliasBody_max_cdr_typesize {1168UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteAliasBody_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_StringLTypeDefn_max_cdr_typesize {4UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_StringLTypeDefn_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteSequenceType_max_cdr_typesize {1844UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteSequenceType_max_key_cdr_typesize {0UL}; + + +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteBitmaskType_max_cdr_typesize {676UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteBitmaskType_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_CommonDiscriminatorMember_max_cdr_typesize {32UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_CommonDiscriminatorMember_max_key_cdr_typesize {0UL}; + + +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalUnionMember_max_cdr_typesize {48UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalUnionMember_max_key_cdr_typesize {0UL}; + + + + + +constexpr uint32_t eprosima_fastdds_dds_xtypes_CommonAnnotationParameter_max_cdr_typesize {32UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_CommonAnnotationParameter_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_PlainMapLTypeDefn_max_cdr_typesize {72UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_PlainMapLTypeDefn_max_key_cdr_typesize {0UL}; + + +constexpr uint32_t eprosima_fastdds_dds_xtypes_CommonEnumeratedHeader_max_cdr_typesize {2UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_CommonEnumeratedHeader_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_TypeIdentifierTypeObjectPair_max_cdr_typesize {3048UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_TypeIdentifierTypeObjectPair_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalSequenceType_max_cdr_typesize {48UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalSequenceType_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalBitflag_max_cdr_typesize {12UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalBitflag_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalBitsetHeader_max_cdr_typesize {4UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalBitsetHeader_max_key_cdr_typesize {0UL}; + + + + +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteAnnotationParameter_max_cdr_typesize {560UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteAnnotationParameter_max_key_cdr_typesize {0UL}; + + + + +constexpr uint32_t eprosima_fastdds_dds_xtypes_AppliedAnnotation_max_cdr_typesize {56UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_AppliedAnnotation_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_CommonStructMember_max_cdr_typesize {36UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_CommonStructMember_max_key_cdr_typesize {0UL}; + + + +constexpr uint32_t eprosima_fastdds_dds_xtypes_CommonArrayHeader_max_cdr_typesize {4UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_CommonArrayHeader_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalEnumeratedHeader_max_cdr_typesize {6UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalEnumeratedHeader_max_key_cdr_typesize {0UL}; + + + + +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalTypeDetail_max_cdr_typesize {0UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalTypeDetail_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteDiscriminatorMember_max_cdr_typesize {424UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteDiscriminatorMember_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalUnionType_max_cdr_typesize {52UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalUnionType_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalBitfield_max_cdr_typesize {14UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalBitfield_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalExtendedType_max_cdr_typesize {4UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalExtendedType_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_StronglyConnectedComponentId_max_cdr_typesize {28UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_StronglyConnectedComponentId_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_TypeIdentfierWithSize_max_cdr_typesize {40UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_TypeIdentfierWithSize_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalArrayHeader_max_cdr_typesize {8UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_MinimalArrayHeader_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_PlainSequenceSElemDefn_max_cdr_typesize {36UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_PlainSequenceSElemDefn_max_key_cdr_typesize {0UL}; + + +constexpr uint32_t eprosima_fastdds_dds_xtypes_AppliedVerbatimAnnotation_max_cdr_typesize {340UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_AppliedVerbatimAnnotation_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteMemberDetail_max_cdr_typesize {1396UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteMemberDetail_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteUnionMember_max_cdr_typesize {1440UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteUnionMember_max_key_cdr_typesize {0UL}; + +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteUnionType_max_cdr_typesize {1092UL}; +constexpr uint32_t eprosima_fastdds_dds_xtypes_CompleteUnionType_max_key_cdr_typesize {0UL}; + + + +namespace eprosima { +namespace fastcdr { + +class Cdr; +class CdrSizeCalculator; + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::StringSTypeDefn& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::StringLTypeDefn& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::PlainCollectionHeader& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::PlainSequenceSElemDefn& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::PlainSequenceLElemDefn& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::PlainArraySElemDefn& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::PlainArrayLElemDefn& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::PlainMapSTypeDefn& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::PlainMapLTypeDefn& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::StronglyConnectedComponentId& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::ExtendedTypeDefn& data); + + + + + + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::ExtendedAnnotationParameterValue& data); + + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::AppliedAnnotationParameter& data); + + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::AppliedAnnotation& data); + + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::AppliedVerbatimAnnotation& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::AppliedBuiltinMemberAnnotations& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::CommonStructMember& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::CompleteMemberDetail& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::MinimalMemberDetail& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::CompleteStructMember& data); + + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::MinimalStructMember& data); + + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::AppliedBuiltinTypeAnnotations& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::MinimalTypeDetail& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::CompleteTypeDetail& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::CompleteStructHeader& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::MinimalStructHeader& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::CompleteStructType& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::MinimalStructType& data); + + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::CommonUnionMember& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::CompleteUnionMember& data); + + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::MinimalUnionMember& data); + + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::CommonDiscriminatorMember& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::CompleteDiscriminatorMember& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::MinimalDiscriminatorMember& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::CompleteUnionHeader& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::MinimalUnionHeader& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::CompleteUnionType& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::MinimalUnionType& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::CommonAnnotationParameter& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::CompleteAnnotationParameter& data); + + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::MinimalAnnotationParameter& data); + + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::CompleteAnnotationHeader& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::MinimalAnnotationHeader& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::CompleteAnnotationType& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::MinimalAnnotationType& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::CommonAliasBody& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::CompleteAliasBody& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::MinimalAliasBody& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::CompleteAliasHeader& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::MinimalAliasHeader& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::CompleteAliasType& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::MinimalAliasType& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::CompleteElementDetail& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::CommonCollectionElement& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::CompleteCollectionElement& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::MinimalCollectionElement& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::CommonCollectionHeader& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::CompleteCollectionHeader& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::MinimalCollectionHeader& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::CompleteSequenceType& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::MinimalSequenceType& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::CommonArrayHeader& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::CompleteArrayHeader& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::MinimalArrayHeader& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::CompleteArrayType& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::MinimalArrayType& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::CompleteMapType& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::MinimalMapType& data); + + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::CommonEnumeratedLiteral& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::CompleteEnumeratedLiteral& data); + + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::MinimalEnumeratedLiteral& data); + + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::CommonEnumeratedHeader& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::CompleteEnumeratedHeader& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::MinimalEnumeratedHeader& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::CompleteEnumeratedType& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::MinimalEnumeratedType& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::CommonBitflag& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::CompleteBitflag& data); + + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::MinimalBitflag& data); + + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::CommonBitmaskHeader& data); + + + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::CompleteBitmaskType& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::MinimalBitmaskType& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::CommonBitfield& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::CompleteBitfield& data); + + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::MinimalBitfield& data); + + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::CompleteBitsetHeader& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::MinimalBitsetHeader& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::CompleteBitsetType& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::MinimalBitsetType& data); + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::CompleteExtendedType& data); + + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::MinimalExtendedType& data); + + + + + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::TypeIdentifierTypeObjectPair& data); + + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::TypeIdentifierPair& data); + + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::TypeIdentfierWithSize& data); + + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::TypeIdentifierWithDependencies& data); + + +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const eprosima::fastdds::dds::xtypes::TypeInformation& data); + + + +} // namespace fastcdr +} // namespace eprosima + +#endif // _FAST_DDS_GENERATED_EPROSIMA_FASTDDS_DDS_XTYPES_DDS_XTYPES_TYPEOBJECTCDRAUX_HPP_ + diff --git a/include/fastdds/dds/xtypes/type_representation/detail/dds_xtypes_typeobjectPubSubTypes.h b/include/fastdds/dds/xtypes/type_representation/detail/dds_xtypes_typeobjectPubSubTypes.h new file mode 100644 index 00000000000..e0ab20d2983 --- /dev/null +++ b/include/fastdds/dds/xtypes/type_representation/detail/dds_xtypes_typeobjectPubSubTypes.h @@ -0,0 +1,9261 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file dds_xtypes_typeobjectPubSubTypes.h + * This header file contains the declaration of the serialization functions. + * + * This file was generated by the tool fastddsgen. + */ + + +#ifndef _FAST_DDS_GENERATED_EPROSIMA_FASTDDS_DDS_XTYPES_DDS_XTYPES_TYPEOBJECT_PUBSUBTYPES_H_ +#define _FAST_DDS_GENERATED_EPROSIMA_FASTDDS_DDS_XTYPES_DDS_XTYPES_TYPEOBJECT_PUBSUBTYPES_H_ + +#include +#include +#include +#include +#include + +#include "dds_xtypes_typeobject.hpp" + + +#if !defined(GEN_API_VER) || (GEN_API_VER != 2) +#error \ + Generated dds_xtypes_typeobject is not compatible with current installed Fast DDS. Please, regenerate it with fastddsgen. +#endif // GEN_API_VER + +namespace eprosima { + +namespace fastdds { + +namespace dds { + + +namespace xtypes { + + +typedef uint8_t EquivalenceKind; + + + +typedef uint8_t TypeKind; + + + + + + + + + + + + + + + + + + + + + + + + + + + + +typedef uint8_t TypeIdentiferKind; + + + + + + + + + + + + +typedef eprosima::fastcdr::fixed_string MemberName; + +typedef eprosima::fastcdr::fixed_string QualifiedTypeName; +typedef uint8_t PrimitiveTypeId; +typedef std::array EquivalenceHash; +typedef std::array NameHash; +typedef uint32_t LBound; +typedef std::vector LBoundSeq; + +typedef uint8_t SBound; +typedef std::vector SBoundSeq; + + + +typedef eprosima::fastdds::dds::xtypes::MemberFlag CollectionElementFlag; +typedef eprosima::fastdds::dds::xtypes::MemberFlag StructMemberFlag; +typedef eprosima::fastdds::dds::xtypes::MemberFlag UnionMemberFlag; +typedef eprosima::fastdds::dds::xtypes::MemberFlag UnionDiscriminatorFlag; +typedef eprosima::fastdds::dds::xtypes::MemberFlag EnumeratedLiteralFlag; +typedef eprosima::fastdds::dds::xtypes::MemberFlag AnnotationParameterFlag; +typedef eprosima::fastdds::dds::xtypes::MemberFlag AliasMemberFlag; +typedef eprosima::fastdds::dds::xtypes::MemberFlag BitflagFlag; +typedef eprosima::fastdds::dds::xtypes::MemberFlag BitsetMemberFlag; + + +typedef eprosima::fastdds::dds::xtypes::TypeFlag StructTypeFlag; +typedef eprosima::fastdds::dds::xtypes::TypeFlag UnionTypeFlag; +typedef eprosima::fastdds::dds::xtypes::TypeFlag CollectionTypeFlag; +typedef eprosima::fastdds::dds::xtypes::TypeFlag AnnotationTypeFlag; +typedef eprosima::fastdds::dds::xtypes::TypeFlag AliasTypeFlag; +typedef eprosima::fastdds::dds::xtypes::TypeFlag EnumTypeFlag; +typedef eprosima::fastdds::dds::xtypes::TypeFlag BitmaskTypeFlag; +typedef eprosima::fastdds::dds::xtypes::TypeFlag BitsetTypeFlag; + + + +#ifndef SWIG +namespace detail { + +template +struct StringSTypeDefn_rob +{ + friend constexpr typename Tag::type get( + Tag) + { + return M; + } + +}; + +struct StringSTypeDefn_f +{ + typedef eprosima::fastdds::dds::xtypes::SBound StringSTypeDefn::* type; + friend constexpr type get( + StringSTypeDefn_f); +}; + +template struct StringSTypeDefn_rob; + +template +inline size_t constexpr StringSTypeDefn_offset_of() +{ + return ((::size_t) &reinterpret_cast((((T*)0)->*get(Tag())))); +} + +} // namespace detail +#endif // ifndef SWIG + + +/*! + * @brief This class represents the TopicDataType of the type StringSTypeDefn defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class StringSTypeDefnPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef StringSTypeDefn type; + + eProsima_user_DllExport StringSTypeDefnPubSubType(); + + eProsima_user_DllExport ~StringSTypeDefnPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return true; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return is_plain_xcdrv1_impl(); + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + if(data_representation == eprosima::fastdds::dds::DataRepresentationId_t::XCDR2_DATA_REPRESENTATION) + { + return is_plain_xcdrv2_impl(); + } + else + { + return is_plain_xcdrv1_impl(); + } + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + new (memory) StringSTypeDefn(); + return true; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +private: + + static constexpr bool is_plain_xcdrv1_impl() + { + return 1ULL == + (detail::StringSTypeDefn_offset_of() + + sizeof(eprosima::fastdds::dds::xtypes::SBound)); + } + + static constexpr bool is_plain_xcdrv2_impl() + { + return 1ULL == + (detail::StringSTypeDefn_offset_of() + + sizeof(eprosima::fastdds::dds::xtypes::SBound)); + } + +}; + +#ifndef SWIG +namespace detail { + +template +struct StringLTypeDefn_rob +{ + friend constexpr typename Tag::type get( + Tag) + { + return M; + } + +}; + +struct StringLTypeDefn_f +{ + typedef eprosima::fastdds::dds::xtypes::LBound StringLTypeDefn::* type; + friend constexpr type get( + StringLTypeDefn_f); +}; + +template struct StringLTypeDefn_rob; + +template +inline size_t constexpr StringLTypeDefn_offset_of() +{ + return ((::size_t) &reinterpret_cast((((T*)0)->*get(Tag())))); +} + +} // namespace detail +#endif // ifndef SWIG + + +/*! + * @brief This class represents the TopicDataType of the type StringLTypeDefn defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class StringLTypeDefnPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef StringLTypeDefn type; + + eProsima_user_DllExport StringLTypeDefnPubSubType(); + + eProsima_user_DllExport ~StringLTypeDefnPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return true; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return is_plain_xcdrv1_impl(); + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + if(data_representation == eprosima::fastdds::dds::DataRepresentationId_t::XCDR2_DATA_REPRESENTATION) + { + return is_plain_xcdrv2_impl(); + } + else + { + return is_plain_xcdrv1_impl(); + } + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + new (memory) StringLTypeDefn(); + return true; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +private: + + static constexpr bool is_plain_xcdrv1_impl() + { + return 4ULL == + (detail::StringLTypeDefn_offset_of() + + sizeof(eprosima::fastdds::dds::xtypes::LBound)); + } + + static constexpr bool is_plain_xcdrv2_impl() + { + return 4ULL == + (detail::StringLTypeDefn_offset_of() + + sizeof(eprosima::fastdds::dds::xtypes::LBound)); + } + +}; + +/*! + * @brief This class represents the TopicDataType of the type PlainCollectionHeader defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class PlainCollectionHeaderPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef PlainCollectionHeader type; + + eProsima_user_DllExport PlainCollectionHeaderPubSubType(); + + eProsima_user_DllExport ~PlainCollectionHeaderPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return true; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type PlainSequenceSElemDefn defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class PlainSequenceSElemDefnPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef PlainSequenceSElemDefn type; + + eProsima_user_DllExport PlainSequenceSElemDefnPubSubType(); + + eProsima_user_DllExport ~PlainSequenceSElemDefnPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return true; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type PlainSequenceLElemDefn defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class PlainSequenceLElemDefnPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef PlainSequenceLElemDefn type; + + eProsima_user_DllExport PlainSequenceLElemDefnPubSubType(); + + eProsima_user_DllExport ~PlainSequenceLElemDefnPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return true; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type PlainArraySElemDefn defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class PlainArraySElemDefnPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef PlainArraySElemDefn type; + + eProsima_user_DllExport PlainArraySElemDefnPubSubType(); + + eProsima_user_DllExport ~PlainArraySElemDefnPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type PlainArrayLElemDefn defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class PlainArrayLElemDefnPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef PlainArrayLElemDefn type; + + eProsima_user_DllExport PlainArrayLElemDefnPubSubType(); + + eProsima_user_DllExport ~PlainArrayLElemDefnPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type PlainMapSTypeDefn defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class PlainMapSTypeDefnPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef PlainMapSTypeDefn type; + + eProsima_user_DllExport PlainMapSTypeDefnPubSubType(); + + eProsima_user_DllExport ~PlainMapSTypeDefnPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return true; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type PlainMapLTypeDefn defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class PlainMapLTypeDefnPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef PlainMapLTypeDefn type; + + eProsima_user_DllExport PlainMapLTypeDefnPubSubType(); + + eProsima_user_DllExport ~PlainMapLTypeDefnPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return true; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type StronglyConnectedComponentId defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class StronglyConnectedComponentIdPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef StronglyConnectedComponentId type; + + eProsima_user_DllExport StronglyConnectedComponentIdPubSubType(); + + eProsima_user_DllExport ~StronglyConnectedComponentIdPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return true; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type ExtendedTypeDefn defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class ExtendedTypeDefnPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef ExtendedTypeDefn type; + + eProsima_user_DllExport ExtendedTypeDefnPubSubType(); + + eProsima_user_DllExport ~ExtendedTypeDefnPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return true; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +typedef std::vector TypeIdentifierSeq; +typedef uint32_t MemberId; + + + +/*! + * @brief This class represents the TopicDataType of the type ExtendedAnnotationParameterValue defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class ExtendedAnnotationParameterValuePubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef ExtendedAnnotationParameterValue type; + + eProsima_user_DllExport ExtendedAnnotationParameterValuePubSubType(); + + eProsima_user_DllExport ~ExtendedAnnotationParameterValuePubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return true; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + + +/*! + * @brief This class represents the TopicDataType of the type AppliedAnnotationParameter defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class AppliedAnnotationParameterPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef AppliedAnnotationParameter type; + + eProsima_user_DllExport AppliedAnnotationParameterPubSubType(); + + eProsima_user_DllExport ~AppliedAnnotationParameterPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return true; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; +typedef std::vector AppliedAnnotationParameterSeq; + +/*! + * @brief This class represents the TopicDataType of the type AppliedAnnotation defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class AppliedAnnotationPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef AppliedAnnotation type; + + eProsima_user_DllExport AppliedAnnotationPubSubType(); + + eProsima_user_DllExport ~AppliedAnnotationPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; +typedef std::vector AppliedAnnotationSeq; + +/*! + * @brief This class represents the TopicDataType of the type AppliedVerbatimAnnotation defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class AppliedVerbatimAnnotationPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef AppliedVerbatimAnnotation type; + + eProsima_user_DllExport AppliedVerbatimAnnotationPubSubType(); + + eProsima_user_DllExport ~AppliedVerbatimAnnotationPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type AppliedBuiltinMemberAnnotations defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class AppliedBuiltinMemberAnnotationsPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef AppliedBuiltinMemberAnnotations type; + + eProsima_user_DllExport AppliedBuiltinMemberAnnotationsPubSubType(); + + eProsima_user_DllExport ~AppliedBuiltinMemberAnnotationsPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type CommonStructMember defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CommonStructMemberPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef CommonStructMember type; + + eProsima_user_DllExport CommonStructMemberPubSubType(); + + eProsima_user_DllExport ~CommonStructMemberPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type CompleteMemberDetail defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteMemberDetailPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef CompleteMemberDetail type; + + eProsima_user_DllExport CompleteMemberDetailPubSubType(); + + eProsima_user_DllExport ~CompleteMemberDetailPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +#ifndef SWIG +namespace detail { + +template +struct MinimalMemberDetail_rob +{ + friend constexpr typename Tag::type get( + Tag) + { + return M; + } + +}; + +struct MinimalMemberDetail_f +{ + typedef eprosima::fastdds::dds::xtypes::NameHash MinimalMemberDetail::* type; + friend constexpr type get( + MinimalMemberDetail_f); +}; + +template struct MinimalMemberDetail_rob; + +template +inline size_t constexpr MinimalMemberDetail_offset_of() +{ + return ((::size_t) &reinterpret_cast((((T*)0)->*get(Tag())))); +} + +} // namespace detail +#endif // ifndef SWIG + + +/*! + * @brief This class represents the TopicDataType of the type MinimalMemberDetail defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalMemberDetailPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef MinimalMemberDetail type; + + eProsima_user_DllExport MinimalMemberDetailPubSubType(); + + eProsima_user_DllExport ~MinimalMemberDetailPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return true; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return is_plain_xcdrv1_impl(); + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + if(data_representation == eprosima::fastdds::dds::DataRepresentationId_t::XCDR2_DATA_REPRESENTATION) + { + return is_plain_xcdrv2_impl(); + } + else + { + return is_plain_xcdrv1_impl(); + } + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + new (memory) MinimalMemberDetail(); + return true; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +private: + + static constexpr bool is_plain_xcdrv1_impl() + { + return 4ULL == + (detail::MinimalMemberDetail_offset_of() + + sizeof(eprosima::fastdds::dds::xtypes::NameHash)); + } + + static constexpr bool is_plain_xcdrv2_impl() + { + return 4ULL == + (detail::MinimalMemberDetail_offset_of() + + sizeof(eprosima::fastdds::dds::xtypes::NameHash)); + } + +}; + +/*! + * @brief This class represents the TopicDataType of the type CompleteStructMember defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteStructMemberPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef CompleteStructMember type; + + eProsima_user_DllExport CompleteStructMemberPubSubType(); + + eProsima_user_DllExport ~CompleteStructMemberPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; +typedef std::vector CompleteStructMemberSeq; + +/*! + * @brief This class represents the TopicDataType of the type MinimalStructMember defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalStructMemberPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef MinimalStructMember type; + + eProsima_user_DllExport MinimalStructMemberPubSubType(); + + eProsima_user_DllExport ~MinimalStructMemberPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; +typedef std::vector MinimalStructMemberSeq; + +/*! + * @brief This class represents the TopicDataType of the type AppliedBuiltinTypeAnnotations defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class AppliedBuiltinTypeAnnotationsPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef AppliedBuiltinTypeAnnotations type; + + eProsima_user_DllExport AppliedBuiltinTypeAnnotationsPubSubType(); + + eProsima_user_DllExport ~AppliedBuiltinTypeAnnotationsPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type MinimalTypeDetail defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalTypeDetailPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef MinimalTypeDetail type; + + eProsima_user_DllExport MinimalTypeDetailPubSubType(); + + eProsima_user_DllExport ~MinimalTypeDetailPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return true; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return is_plain_xcdrv1_impl(); + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + if(data_representation == eprosima::fastdds::dds::DataRepresentationId_t::XCDR2_DATA_REPRESENTATION) + { + return is_plain_xcdrv2_impl(); + } + else + { + return is_plain_xcdrv1_impl(); + } + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + new (memory) MinimalTypeDetail(); + return true; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +private: + + static constexpr bool is_plain_xcdrv1_impl() + { + return true; + } + + static constexpr bool is_plain_xcdrv2_impl() + { + return true; + } + +}; + +/*! + * @brief This class represents the TopicDataType of the type CompleteTypeDetail defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteTypeDetailPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef CompleteTypeDetail type; + + eProsima_user_DllExport CompleteTypeDetailPubSubType(); + + eProsima_user_DllExport ~CompleteTypeDetailPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type CompleteStructHeader defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteStructHeaderPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef CompleteStructHeader type; + + eProsima_user_DllExport CompleteStructHeaderPubSubType(); + + eProsima_user_DllExport ~CompleteStructHeaderPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type MinimalStructHeader defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalStructHeaderPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef MinimalStructHeader type; + + eProsima_user_DllExport MinimalStructHeaderPubSubType(); + + eProsima_user_DllExport ~MinimalStructHeaderPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type CompleteStructType defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteStructTypePubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef CompleteStructType type; + + eProsima_user_DllExport CompleteStructTypePubSubType(); + + eProsima_user_DllExport ~CompleteStructTypePubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type MinimalStructType defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalStructTypePubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef MinimalStructType type; + + eProsima_user_DllExport MinimalStructTypePubSubType(); + + eProsima_user_DllExport ~MinimalStructTypePubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; +typedef std::vector UnionCaseLabelSeq; + +/*! + * @brief This class represents the TopicDataType of the type CommonUnionMember defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CommonUnionMemberPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef CommonUnionMember type; + + eProsima_user_DllExport CommonUnionMemberPubSubType(); + + eProsima_user_DllExport ~CommonUnionMemberPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type CompleteUnionMember defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteUnionMemberPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef CompleteUnionMember type; + + eProsima_user_DllExport CompleteUnionMemberPubSubType(); + + eProsima_user_DllExport ~CompleteUnionMemberPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; +typedef std::vector CompleteUnionMemberSeq; + +/*! + * @brief This class represents the TopicDataType of the type MinimalUnionMember defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalUnionMemberPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef MinimalUnionMember type; + + eProsima_user_DllExport MinimalUnionMemberPubSubType(); + + eProsima_user_DllExport ~MinimalUnionMemberPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; +typedef std::vector MinimalUnionMemberSeq; + +/*! + * @brief This class represents the TopicDataType of the type CommonDiscriminatorMember defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CommonDiscriminatorMemberPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef CommonDiscriminatorMember type; + + eProsima_user_DllExport CommonDiscriminatorMemberPubSubType(); + + eProsima_user_DllExport ~CommonDiscriminatorMemberPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type CompleteDiscriminatorMember defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteDiscriminatorMemberPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef CompleteDiscriminatorMember type; + + eProsima_user_DllExport CompleteDiscriminatorMemberPubSubType(); + + eProsima_user_DllExport ~CompleteDiscriminatorMemberPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type MinimalDiscriminatorMember defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalDiscriminatorMemberPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef MinimalDiscriminatorMember type; + + eProsima_user_DllExport MinimalDiscriminatorMemberPubSubType(); + + eProsima_user_DllExport ~MinimalDiscriminatorMemberPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type CompleteUnionHeader defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteUnionHeaderPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef CompleteUnionHeader type; + + eProsima_user_DllExport CompleteUnionHeaderPubSubType(); + + eProsima_user_DllExport ~CompleteUnionHeaderPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type MinimalUnionHeader defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalUnionHeaderPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef MinimalUnionHeader type; + + eProsima_user_DllExport MinimalUnionHeaderPubSubType(); + + eProsima_user_DllExport ~MinimalUnionHeaderPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return true; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type CompleteUnionType defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteUnionTypePubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef CompleteUnionType type; + + eProsima_user_DllExport CompleteUnionTypePubSubType(); + + eProsima_user_DllExport ~CompleteUnionTypePubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type MinimalUnionType defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalUnionTypePubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef MinimalUnionType type; + + eProsima_user_DllExport MinimalUnionTypePubSubType(); + + eProsima_user_DllExport ~MinimalUnionTypePubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type CommonAnnotationParameter defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CommonAnnotationParameterPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef CommonAnnotationParameter type; + + eProsima_user_DllExport CommonAnnotationParameterPubSubType(); + + eProsima_user_DllExport ~CommonAnnotationParameterPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type CompleteAnnotationParameter defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteAnnotationParameterPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef CompleteAnnotationParameter type; + + eProsima_user_DllExport CompleteAnnotationParameterPubSubType(); + + eProsima_user_DllExport ~CompleteAnnotationParameterPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; +typedef std::vector CompleteAnnotationParameterSeq; + +/*! + * @brief This class represents the TopicDataType of the type MinimalAnnotationParameter defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalAnnotationParameterPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef MinimalAnnotationParameter type; + + eProsima_user_DllExport MinimalAnnotationParameterPubSubType(); + + eProsima_user_DllExport ~MinimalAnnotationParameterPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; +typedef std::vector MinimalAnnotationParameterSeq; + +/*! + * @brief This class represents the TopicDataType of the type CompleteAnnotationHeader defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteAnnotationHeaderPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef CompleteAnnotationHeader type; + + eProsima_user_DllExport CompleteAnnotationHeaderPubSubType(); + + eProsima_user_DllExport ~CompleteAnnotationHeaderPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return true; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type MinimalAnnotationHeader defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalAnnotationHeaderPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef MinimalAnnotationHeader type; + + eProsima_user_DllExport MinimalAnnotationHeaderPubSubType(); + + eProsima_user_DllExport ~MinimalAnnotationHeaderPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return true; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type CompleteAnnotationType defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteAnnotationTypePubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef CompleteAnnotationType type; + + eProsima_user_DllExport CompleteAnnotationTypePubSubType(); + + eProsima_user_DllExport ~CompleteAnnotationTypePubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type MinimalAnnotationType defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalAnnotationTypePubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef MinimalAnnotationType type; + + eProsima_user_DllExport MinimalAnnotationTypePubSubType(); + + eProsima_user_DllExport ~MinimalAnnotationTypePubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type CommonAliasBody defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CommonAliasBodyPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef CommonAliasBody type; + + eProsima_user_DllExport CommonAliasBodyPubSubType(); + + eProsima_user_DllExport ~CommonAliasBodyPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type CompleteAliasBody defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteAliasBodyPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef CompleteAliasBody type; + + eProsima_user_DllExport CompleteAliasBodyPubSubType(); + + eProsima_user_DllExport ~CompleteAliasBodyPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type MinimalAliasBody defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalAliasBodyPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef MinimalAliasBody type; + + eProsima_user_DllExport MinimalAliasBodyPubSubType(); + + eProsima_user_DllExport ~MinimalAliasBodyPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type CompleteAliasHeader defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteAliasHeaderPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef CompleteAliasHeader type; + + eProsima_user_DllExport CompleteAliasHeaderPubSubType(); + + eProsima_user_DllExport ~CompleteAliasHeaderPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type MinimalAliasHeader defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalAliasHeaderPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef MinimalAliasHeader type; + + eProsima_user_DllExport MinimalAliasHeaderPubSubType(); + + eProsima_user_DllExport ~MinimalAliasHeaderPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return true; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type CompleteAliasType defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteAliasTypePubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef CompleteAliasType type; + + eProsima_user_DllExport CompleteAliasTypePubSubType(); + + eProsima_user_DllExport ~CompleteAliasTypePubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type MinimalAliasType defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalAliasTypePubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef MinimalAliasType type; + + eProsima_user_DllExport MinimalAliasTypePubSubType(); + + eProsima_user_DllExport ~MinimalAliasTypePubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type CompleteElementDetail defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteElementDetailPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef CompleteElementDetail type; + + eProsima_user_DllExport CompleteElementDetailPubSubType(); + + eProsima_user_DllExport ~CompleteElementDetailPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type CommonCollectionElement defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CommonCollectionElementPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef CommonCollectionElement type; + + eProsima_user_DllExport CommonCollectionElementPubSubType(); + + eProsima_user_DllExport ~CommonCollectionElementPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type CompleteCollectionElement defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteCollectionElementPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef CompleteCollectionElement type; + + eProsima_user_DllExport CompleteCollectionElementPubSubType(); + + eProsima_user_DllExport ~CompleteCollectionElementPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type MinimalCollectionElement defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalCollectionElementPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef MinimalCollectionElement type; + + eProsima_user_DllExport MinimalCollectionElementPubSubType(); + + eProsima_user_DllExport ~MinimalCollectionElementPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +#ifndef SWIG +namespace detail { + +template +struct CommonCollectionHeader_rob +{ + friend constexpr typename Tag::type get( + Tag) + { + return M; + } + +}; + +struct CommonCollectionHeader_f +{ + typedef eprosima::fastdds::dds::xtypes::LBound CommonCollectionHeader::* type; + friend constexpr type get( + CommonCollectionHeader_f); +}; + +template struct CommonCollectionHeader_rob; + +template +inline size_t constexpr CommonCollectionHeader_offset_of() +{ + return ((::size_t) &reinterpret_cast((((T*)0)->*get(Tag())))); +} + +} // namespace detail +#endif // ifndef SWIG + + +/*! + * @brief This class represents the TopicDataType of the type CommonCollectionHeader defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CommonCollectionHeaderPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef CommonCollectionHeader type; + + eProsima_user_DllExport CommonCollectionHeaderPubSubType(); + + eProsima_user_DllExport ~CommonCollectionHeaderPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return true; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return is_plain_xcdrv1_impl(); + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + if(data_representation == eprosima::fastdds::dds::DataRepresentationId_t::XCDR2_DATA_REPRESENTATION) + { + return is_plain_xcdrv2_impl(); + } + else + { + return is_plain_xcdrv1_impl(); + } + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + new (memory) CommonCollectionHeader(); + return true; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +private: + + static constexpr bool is_plain_xcdrv1_impl() + { + return 4ULL == + (detail::CommonCollectionHeader_offset_of() + + sizeof(eprosima::fastdds::dds::xtypes::LBound)); + } + + static constexpr bool is_plain_xcdrv2_impl() + { + return 4ULL == + (detail::CommonCollectionHeader_offset_of() + + sizeof(eprosima::fastdds::dds::xtypes::LBound)); + } + +}; + +/*! + * @brief This class represents the TopicDataType of the type CompleteCollectionHeader defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteCollectionHeaderPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef CompleteCollectionHeader type; + + eProsima_user_DllExport CompleteCollectionHeaderPubSubType(); + + eProsima_user_DllExport ~CompleteCollectionHeaderPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type MinimalCollectionHeader defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalCollectionHeaderPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef MinimalCollectionHeader type; + + eProsima_user_DllExport MinimalCollectionHeaderPubSubType(); + + eProsima_user_DllExport ~MinimalCollectionHeaderPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return true; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type CompleteSequenceType defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteSequenceTypePubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef CompleteSequenceType type; + + eProsima_user_DllExport CompleteSequenceTypePubSubType(); + + eProsima_user_DllExport ~CompleteSequenceTypePubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type MinimalSequenceType defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalSequenceTypePubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef MinimalSequenceType type; + + eProsima_user_DllExport MinimalSequenceTypePubSubType(); + + eProsima_user_DllExport ~MinimalSequenceTypePubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type CommonArrayHeader defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CommonArrayHeaderPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef CommonArrayHeader type; + + eProsima_user_DllExport CommonArrayHeaderPubSubType(); + + eProsima_user_DllExport ~CommonArrayHeaderPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type CompleteArrayHeader defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteArrayHeaderPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef CompleteArrayHeader type; + + eProsima_user_DllExport CompleteArrayHeaderPubSubType(); + + eProsima_user_DllExport ~CompleteArrayHeaderPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type MinimalArrayHeader defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalArrayHeaderPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef MinimalArrayHeader type; + + eProsima_user_DllExport MinimalArrayHeaderPubSubType(); + + eProsima_user_DllExport ~MinimalArrayHeaderPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type CompleteArrayType defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteArrayTypePubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef CompleteArrayType type; + + eProsima_user_DllExport CompleteArrayTypePubSubType(); + + eProsima_user_DllExport ~CompleteArrayTypePubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type MinimalArrayType defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalArrayTypePubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef MinimalArrayType type; + + eProsima_user_DllExport MinimalArrayTypePubSubType(); + + eProsima_user_DllExport ~MinimalArrayTypePubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type CompleteMapType defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteMapTypePubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef CompleteMapType type; + + eProsima_user_DllExport CompleteMapTypePubSubType(); + + eProsima_user_DllExport ~CompleteMapTypePubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type MinimalMapType defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalMapTypePubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef MinimalMapType type; + + eProsima_user_DllExport MinimalMapTypePubSubType(); + + eProsima_user_DllExport ~MinimalMapTypePubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; +typedef uint16_t BitBound; + +/*! + * @brief This class represents the TopicDataType of the type CommonEnumeratedLiteral defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CommonEnumeratedLiteralPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef CommonEnumeratedLiteral type; + + eProsima_user_DllExport CommonEnumeratedLiteralPubSubType(); + + eProsima_user_DllExport ~CommonEnumeratedLiteralPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return true; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type CompleteEnumeratedLiteral defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteEnumeratedLiteralPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef CompleteEnumeratedLiteral type; + + eProsima_user_DllExport CompleteEnumeratedLiteralPubSubType(); + + eProsima_user_DllExport ~CompleteEnumeratedLiteralPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; +typedef std::vector CompleteEnumeratedLiteralSeq; + +/*! + * @brief This class represents the TopicDataType of the type MinimalEnumeratedLiteral defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalEnumeratedLiteralPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef MinimalEnumeratedLiteral type; + + eProsima_user_DllExport MinimalEnumeratedLiteralPubSubType(); + + eProsima_user_DllExport ~MinimalEnumeratedLiteralPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return true; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; +typedef std::vector MinimalEnumeratedLiteralSeq; + +#ifndef SWIG +namespace detail { + +template +struct CommonEnumeratedHeader_rob +{ + friend constexpr typename Tag::type get( + Tag) + { + return M; + } + +}; + +struct CommonEnumeratedHeader_f +{ + typedef eprosima::fastdds::dds::xtypes::BitBound CommonEnumeratedHeader::* type; + friend constexpr type get( + CommonEnumeratedHeader_f); +}; + +template struct CommonEnumeratedHeader_rob; + +template +inline size_t constexpr CommonEnumeratedHeader_offset_of() +{ + return ((::size_t) &reinterpret_cast((((T*)0)->*get(Tag())))); +} + +} // namespace detail +#endif // ifndef SWIG + + +/*! + * @brief This class represents the TopicDataType of the type CommonEnumeratedHeader defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CommonEnumeratedHeaderPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef CommonEnumeratedHeader type; + + eProsima_user_DllExport CommonEnumeratedHeaderPubSubType(); + + eProsima_user_DllExport ~CommonEnumeratedHeaderPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return true; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return is_plain_xcdrv1_impl(); + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + if(data_representation == eprosima::fastdds::dds::DataRepresentationId_t::XCDR2_DATA_REPRESENTATION) + { + return is_plain_xcdrv2_impl(); + } + else + { + return is_plain_xcdrv1_impl(); + } + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + new (memory) CommonEnumeratedHeader(); + return true; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +private: + + static constexpr bool is_plain_xcdrv1_impl() + { + return 2ULL == + (detail::CommonEnumeratedHeader_offset_of() + + sizeof(eprosima::fastdds::dds::xtypes::BitBound)); + } + + static constexpr bool is_plain_xcdrv2_impl() + { + return 2ULL == + (detail::CommonEnumeratedHeader_offset_of() + + sizeof(eprosima::fastdds::dds::xtypes::BitBound)); + } + +}; + +/*! + * @brief This class represents the TopicDataType of the type CompleteEnumeratedHeader defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteEnumeratedHeaderPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef CompleteEnumeratedHeader type; + + eProsima_user_DllExport CompleteEnumeratedHeaderPubSubType(); + + eProsima_user_DllExport ~CompleteEnumeratedHeaderPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type MinimalEnumeratedHeader defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalEnumeratedHeaderPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef MinimalEnumeratedHeader type; + + eProsima_user_DllExport MinimalEnumeratedHeaderPubSubType(); + + eProsima_user_DllExport ~MinimalEnumeratedHeaderPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return true; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type CompleteEnumeratedType defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteEnumeratedTypePubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef CompleteEnumeratedType type; + + eProsima_user_DllExport CompleteEnumeratedTypePubSubType(); + + eProsima_user_DllExport ~CompleteEnumeratedTypePubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type MinimalEnumeratedType defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalEnumeratedTypePubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef MinimalEnumeratedType type; + + eProsima_user_DllExport MinimalEnumeratedTypePubSubType(); + + eProsima_user_DllExport ~MinimalEnumeratedTypePubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type CommonBitflag defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CommonBitflagPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef CommonBitflag type; + + eProsima_user_DllExport CommonBitflagPubSubType(); + + eProsima_user_DllExport ~CommonBitflagPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return true; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type CompleteBitflag defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteBitflagPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef CompleteBitflag type; + + eProsima_user_DllExport CompleteBitflagPubSubType(); + + eProsima_user_DllExport ~CompleteBitflagPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; +typedef std::vector CompleteBitflagSeq; + +/*! + * @brief This class represents the TopicDataType of the type MinimalBitflag defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalBitflagPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef MinimalBitflag type; + + eProsima_user_DllExport MinimalBitflagPubSubType(); + + eProsima_user_DllExport ~MinimalBitflagPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return true; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; +typedef std::vector MinimalBitflagSeq; + +#ifndef SWIG +namespace detail { + +template +struct CommonBitmaskHeader_rob +{ + friend constexpr typename Tag::type get( + Tag) + { + return M; + } + +}; + +struct CommonBitmaskHeader_f +{ + typedef eprosima::fastdds::dds::xtypes::BitBound CommonBitmaskHeader::* type; + friend constexpr type get( + CommonBitmaskHeader_f); +}; + +template struct CommonBitmaskHeader_rob; + +template +inline size_t constexpr CommonBitmaskHeader_offset_of() +{ + return ((::size_t) &reinterpret_cast((((T*)0)->*get(Tag())))); +} + +} // namespace detail +#endif // ifndef SWIG + + +/*! + * @brief This class represents the TopicDataType of the type CommonBitmaskHeader defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CommonBitmaskHeaderPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef CommonBitmaskHeader type; + + eProsima_user_DllExport CommonBitmaskHeaderPubSubType(); + + eProsima_user_DllExport ~CommonBitmaskHeaderPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return true; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return is_plain_xcdrv1_impl(); + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + if(data_representation == eprosima::fastdds::dds::DataRepresentationId_t::XCDR2_DATA_REPRESENTATION) + { + return is_plain_xcdrv2_impl(); + } + else + { + return is_plain_xcdrv1_impl(); + } + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + new (memory) CommonBitmaskHeader(); + return true; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +private: + + static constexpr bool is_plain_xcdrv1_impl() + { + return 2ULL == + (detail::CommonBitmaskHeader_offset_of() + + sizeof(eprosima::fastdds::dds::xtypes::BitBound)); + } + + static constexpr bool is_plain_xcdrv2_impl() + { + return 2ULL == + (detail::CommonBitmaskHeader_offset_of() + + sizeof(eprosima::fastdds::dds::xtypes::BitBound)); + } + +}; +typedef eprosima::fastdds::dds::xtypes::CompleteEnumeratedHeader CompleteBitmaskHeader; +typedef eprosima::fastdds::dds::xtypes::MinimalEnumeratedHeader MinimalBitmaskHeader; + +/*! + * @brief This class represents the TopicDataType of the type CompleteBitmaskType defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteBitmaskTypePubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef CompleteBitmaskType type; + + eProsima_user_DllExport CompleteBitmaskTypePubSubType(); + + eProsima_user_DllExport ~CompleteBitmaskTypePubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type MinimalBitmaskType defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalBitmaskTypePubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef MinimalBitmaskType type; + + eProsima_user_DllExport MinimalBitmaskTypePubSubType(); + + eProsima_user_DllExport ~MinimalBitmaskTypePubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type CommonBitfield defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CommonBitfieldPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef CommonBitfield type; + + eProsima_user_DllExport CommonBitfieldPubSubType(); + + eProsima_user_DllExport ~CommonBitfieldPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return true; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type CompleteBitfield defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteBitfieldPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef CompleteBitfield type; + + eProsima_user_DllExport CompleteBitfieldPubSubType(); + + eProsima_user_DllExport ~CompleteBitfieldPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; +typedef std::vector CompleteBitfieldSeq; + +/*! + * @brief This class represents the TopicDataType of the type MinimalBitfield defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalBitfieldPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef MinimalBitfield type; + + eProsima_user_DllExport MinimalBitfieldPubSubType(); + + eProsima_user_DllExport ~MinimalBitfieldPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return true; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; +typedef std::vector MinimalBitfieldSeq; + +/*! + * @brief This class represents the TopicDataType of the type CompleteBitsetHeader defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteBitsetHeaderPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef CompleteBitsetHeader type; + + eProsima_user_DllExport CompleteBitsetHeaderPubSubType(); + + eProsima_user_DllExport ~CompleteBitsetHeaderPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type MinimalBitsetHeader defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalBitsetHeaderPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef MinimalBitsetHeader type; + + eProsima_user_DllExport MinimalBitsetHeaderPubSubType(); + + eProsima_user_DllExport ~MinimalBitsetHeaderPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return true; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type CompleteBitsetType defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteBitsetTypePubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef CompleteBitsetType type; + + eProsima_user_DllExport CompleteBitsetTypePubSubType(); + + eProsima_user_DllExport ~CompleteBitsetTypePubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type MinimalBitsetType defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalBitsetTypePubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef MinimalBitsetType type; + + eProsima_user_DllExport MinimalBitsetTypePubSubType(); + + eProsima_user_DllExport ~MinimalBitsetTypePubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + +/*! + * @brief This class represents the TopicDataType of the type CompleteExtendedType defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class CompleteExtendedTypePubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef CompleteExtendedType type; + + eProsima_user_DllExport CompleteExtendedTypePubSubType(); + + eProsima_user_DllExport ~CompleteExtendedTypePubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return true; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + + +/*! + * @brief This class represents the TopicDataType of the type MinimalExtendedType defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class MinimalExtendedTypePubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef MinimalExtendedType type; + + eProsima_user_DllExport MinimalExtendedTypePubSubType(); + + eProsima_user_DllExport ~MinimalExtendedTypePubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return true; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; + + +typedef std::vector TypeObjectSeq; +typedef eprosima::fastdds::dds::xtypes::TypeObjectSeq StronglyConnectedComponent; + +/*! + * @brief This class represents the TopicDataType of the type TypeIdentifierTypeObjectPair defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class TypeIdentifierTypeObjectPairPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef TypeIdentifierTypeObjectPair type; + + eProsima_user_DllExport TypeIdentifierTypeObjectPairPubSubType(); + + eProsima_user_DllExport ~TypeIdentifierTypeObjectPairPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; +typedef std::vector TypeIdentifierTypeObjectPairSeq; + +/*! + * @brief This class represents the TopicDataType of the type TypeIdentifierPair defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class TypeIdentifierPairPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef TypeIdentifierPair type; + + eProsima_user_DllExport TypeIdentifierPairPubSubType(); + + eProsima_user_DllExport ~TypeIdentifierPairPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; +typedef std::vector TypeIdentifierPairSeq; + +/*! + * @brief This class represents the TopicDataType of the type TypeIdentfierWithSize defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class TypeIdentfierWithSizePubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef TypeIdentfierWithSize type; + + eProsima_user_DllExport TypeIdentfierWithSizePubSubType(); + + eProsima_user_DllExport ~TypeIdentfierWithSizePubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; +typedef std::vector TypeIdentfierWithSizeSeq; + +/*! + * @brief This class represents the TopicDataType of the type TypeIdentifierWithDependencies defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class TypeIdentifierWithDependenciesPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef TypeIdentifierWithDependencies type; + + eProsima_user_DllExport TypeIdentifierWithDependenciesPubSubType(); + + eProsima_user_DllExport ~TypeIdentifierWithDependenciesPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; +typedef std::vector TypeIdentifierWithDependenciesSeq; + +/*! + * @brief This class represents the TopicDataType of the type TypeInformation defined by the user in the IDL file. + * @ingroup dds_xtypes_typeobject + */ +class TypeInformationPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef TypeInformation type; + + eProsima_user_DllExport TypeInformationPubSubType(); + + eProsima_user_DllExport ~TypeInformationPubSubType() override; + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override + { + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data) override + { + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); + } + + eProsima_user_DllExport std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool getKey( + void* data, + eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* createData() override; + + eProsima_user_DllExport void deleteData( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + eProsima_user_DllExport inline bool is_plain() const override + { + return false; + } + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + + MD5 m_md5; + unsigned char* m_keyBuffer; + +}; +typedef std::vector TypeInformationSeq; + +} // namespace xtypes + + +} // namespace dds + +} // namespace fastdds + +} // namespace eprosima + + +#endif // _FAST_DDS_GENERATED_EPROSIMA_FASTDDS_DDS_XTYPES_DDS_XTYPES_TYPEOBJECT_PUBSUBTYPES_H_ + diff --git a/include/fastrtps/eProsima_auto_link.h b/include/fastdds/fastdds_auto_link.hpp similarity index 62% rename from include/fastrtps/eProsima_auto_link.h rename to include/fastdds/fastdds_auto_link.hpp index 9819c40bfee..ba102ea87b7 100644 --- a/include/fastrtps/eProsima_auto_link.h +++ b/include/fastdds/fastdds_auto_link.hpp @@ -13,12 +13,12 @@ // limitations under the License. /* - Expected defines. + Expected defines. - - EPROSIMA_LIB_NAME - - FASTRTPS_VERSION_MAJOR - - FASTRTPS_VERSION_MINOR -*/ + - EPROSIMA_LIB_NAME + - FASTDDS_VERSION_MAJOR + - FASTDDS_VERSION_MINOR + */ #if defined(_MSC_VER) #define EPROSIMA_STRINGIZE(X) EPROSIMA_DO_STRINGIZE(X) @@ -30,37 +30,38 @@ #define EPROSIMA_LIB_DEBUG_TAG #endif // _DEBUG - // Select linkage option. +// Select linkage option. #if (defined(_DLL) || defined(_RTLDLL)) && defined(EPROSIMA_DYN_LINK) #define EPROSIMA_LIB_PREFIX #elif defined(EPROSIMA_DYN_LINK) #error "Mixing a dll eprosima library with a static runtime is a bad idea" #else #define EPROSIMA_LIB_PREFIX "lib" - #endif + #endif // if (defined(_DLL) || defined(_RTLDLL)) && defined(EPROSIMA_DYN_LINK) - // Include library +// Include library #if defined(EPROSIMA_LIB_NAME) \ - && defined(EPROSIMA_LIB_PREFIX) \ - && defined(EPROSIMA_LIB_DEBUG_TAG) \ - && defined(FASTRTPS_VERSION_MAJOR) \ - && defined(FASTRTPS_VERSION_MINOR) - #pragma comment(lib, EPROSIMA_LIB_PREFIX EPROSIMA_STRINGIZE(EPROSIMA_LIB_NAME) EPROSIMA_LIB_DEBUG_TAG "-" EPROSIMA_STRINGIZE(FASTRTPS_VERSION_MAJOR) "." EPROSIMA_STRINGIZE(FASTRTPS_VERSION_MINOR) ".lib") + && defined(EPROSIMA_LIB_PREFIX) \ + && defined(EPROSIMA_LIB_DEBUG_TAG) \ + && defined(FASTDDS_VERSION_MAJOR) \ + && defined(FASTDDS_VERSION_MINOR) + #pragma \ + comment(lib, EPROSIMA_LIB_PREFIX EPROSIMA_STRINGIZE(EPROSIMA_LIB_NAME) EPROSIMA_LIB_DEBUG_TAG "-" EPROSIMA_STRINGIZE(FASTDDS_VERSION_MAJOR) "." EPROSIMA_STRINGIZE(FASTDDS_VERSION_MINOR) ".lib") #else #error "Some required macros where not defined" - #endif + #endif // if defined(EPROSIMA_LIB_NAME) && defined(EPROSIMA_LIB_PREFIX) && defined(EPROSIMA_LIB_DEBUG_TAG) && defined(FASTDDS_VERSION_MAJOR) && defined(FASTDDS_VERSION_MINOR) #endif // _MSC_VER - + // Undef macros #ifdef EPROSIMA_LIB_PREFIX #undef EPROSIMA_LIB_PREFIX -#endif +#endif // ifdef EPROSIMA_LIB_PREFIX #ifdef EPROSIMA_LIB_NAME #undef EPROSIMA_LIB_NAME -#endif +#endif // ifdef EPROSIMA_LIB_NAME #ifdef EPROSIMA_LIB_DEBUG_TAG #undef EPROSIMA_LIB_DEBUG_TAG -#endif +#endif // ifdef EPROSIMA_LIB_DEBUG_TAG diff --git a/include/fastdds/fastdds_dll.hpp b/include/fastdds/fastdds_dll.hpp new file mode 100644 index 00000000000..7e1d58bc5a7 --- /dev/null +++ b/include/fastdds/fastdds_dll.hpp @@ -0,0 +1,69 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +#ifndef _FASTDDS_FASTDDS_DLL_H_ +#define _FASTDDS_FASTDDS_DLL_H_ + +#include + +// normalize macros +#if !defined(FASTDDS_DYN_LINK) && !defined(FASTDDS_STATIC_LINK) \ + && !defined(EPROSIMA_ALL_DYN_LINK) && !defined(EPROSIMA_ALL_STATIC_LINK) +#define FASTDDS_STATIC_LINK +#endif // if !defined(FASTDDS_DYN_LINK) && !defined(FASTDDS_STATIC_LINK) && !defined(EPROSIMA_ALL_DYN_LINK) && !defined(EPROSIMA_ALL_STATIC_LINK) + +#if defined(EPROSIMA_ALL_DYN_LINK) && !defined(FASTDDS_DYN_LINK) +#define FASTDDS_DYN_LINK +#endif // if defined(EPROSIMA_ALL_DYN_LINK) && !defined(FASTDDS_DYN_LINK) + +#if defined(FASTDDS_DYN_LINK) && defined(FASTDDS_STATIC_LINK) +#error Must not define both FASTDDS_DYN_LINK and FASTDDS_STATIC_LINK +#endif // if defined(FASTDDS_DYN_LINK) && defined(FASTDDS_STATIC_LINK) + +#if defined(EPROSIMA_ALL_NO_LIB) && !defined(FASTDDS_NO_LIB) +#define FASTDDS_NO_LIB +#endif // if defined(EPROSIMA_ALL_NO_LIB) && !defined(FASTDDS_NO_LIB) + +// enable dynamic linking + +#if defined(_WIN32) +#if defined(EPROSIMA_ALL_DYN_LINK) || defined(FASTDDS_DYN_LINK) +#if defined(fastdds_EXPORTS) +#define FASTDDS_EXPORTED_API __declspec( dllexport ) +#else +#define FASTDDS_EXPORTED_API __declspec( dllimport ) +#endif // FASTDDS_SOURCE +#else +#define FASTDDS_EXPORTED_API +#endif // if defined(EPROSIMA_ALL_DYN_LINK) || defined(FASTDDS_DYN_LINK) +#else +#define FASTDDS_EXPORTED_API +#endif // _WIN32 + +// Auto linking. + +#if !defined(FASTDDS_SOURCE) && !defined(EPROSIMA_ALL_NO_LIB) \ + && !defined(FASTDDS_NO_LIB) + +// Set properties. +#define EPROSIMA_LIB_NAME fastdds + +#if defined(EPROSIMA_ALL_DYN_LINK) || defined(FASTDDS_DYN_LINK) +#define EPROSIMA_DYN_LINK +#endif // if defined(EPROSIMA_ALL_DYN_LINK) || defined(FASTDDS_DYN_LINK) + +#include +#endif // auto-linking disabled + +#endif // _FASTDDS_FASTDDS_DLL_H_ diff --git a/include/fastdds/rtps/Endpoint.h b/include/fastdds/rtps/Endpoint.h index e33588c0b14..fd34fc14b72 100644 --- a/include/fastdds/rtps/Endpoint.h +++ b/include/fastdds/rtps/Endpoint.h @@ -20,15 +20,12 @@ #define _FASTDDS_RTPS_ENDPOINT_H_ #include - #include #include #include - #include #include - -#include +#include namespace eprosima { namespace fastrtps { @@ -78,7 +75,7 @@ class Endpoint * Get associated GUID * @return Associated GUID */ - RTPS_DllAPI inline const GUID_t& getGuid() const + FASTDDS_EXPORTED_API inline const GUID_t& getGuid() const { return m_guid; } @@ -87,7 +84,7 @@ class Endpoint * Get mutex * @return Associated Mutex */ - RTPS_DllAPI inline RecursiveTimedMutex& getMutex() + FASTDDS_EXPORTED_API inline RecursiveTimedMutex& getMutex() { return mp_mutex; } @@ -96,7 +93,7 @@ class Endpoint * Get associated attributes * @return Endpoint attributes */ - RTPS_DllAPI inline EndpointAttributes& getAttributes() + FASTDDS_EXPORTED_API inline EndpointAttributes& getAttributes() { return m_att; } diff --git a/include/fastdds/rtps/RTPSDomain.h b/include/fastdds/rtps/RTPSDomain.h index 401a1d1a6b3..ac2da360cc0 100644 --- a/include/fastdds/rtps/RTPSDomain.h +++ b/include/fastdds/rtps/RTPSDomain.h @@ -23,11 +23,13 @@ #include #include +#include #include #include #include #include #include +#include namespace eprosima { namespace fastrtps { @@ -63,7 +65,7 @@ class RTPSDomain * @param watch_thread Settings for the thread watching the environment file. * @param callback_thread Settings for the thread executing the callback when the environment file changed. */ - RTPS_DllAPI static void set_filewatch_thread_config( + FASTDDS_EXPORTED_API static void set_filewatch_thread_config( const fastdds::rtps::ThreadSettings& watch_thread, const fastdds::rtps::ThreadSettings& callback_thread); @@ -75,7 +77,7 @@ class RTPSDomain * \post After this call, all the pointers to RTPS entities are invalidated and their use may * result in undefined behaviour. */ - RTPS_DllAPI static void stopAll(); + FASTDDS_EXPORTED_API static void stopAll(); /** * @brief Create a RTPSParticipant. @@ -87,7 +89,7 @@ class RTPSDomain * \warning The returned pointer is invalidated after a call to removeRTPSParticipant() or stopAll(), * so its use may result in undefined behaviour. */ - RTPS_DllAPI static RTPSParticipant* createParticipant( + FASTDDS_EXPORTED_API static RTPSParticipant* createParticipant( uint32_t domain_id, const RTPSParticipantAttributes& attrs, RTPSParticipantListener* plisten = nullptr); @@ -103,7 +105,7 @@ class RTPSDomain * \warning The returned pointer is invalidated after a call to removeRTPSParticipant() or stopAll(), * so its use may result in undefined behaviour. */ - RTPS_DllAPI static RTPSParticipant* createParticipant( + FASTDDS_EXPORTED_API static RTPSParticipant* createParticipant( uint32_t domain_id, bool enabled, const RTPSParticipantAttributes& attrs, @@ -120,7 +122,7 @@ class RTPSDomain * \warning The returned pointer is invalidated after a call to removeRTPSWriter() or stopAll(), * so its use may result in undefined behaviour. */ - RTPS_DllAPI static RTPSWriter* createRTPSWriter( + FASTDDS_EXPORTED_API static RTPSWriter* createRTPSWriter( RTPSParticipant* p, WriterAttributes& watt, WriterHistory* hist, @@ -138,7 +140,7 @@ class RTPSDomain * \warning The returned pointer is invalidated after a call to removeRTPSWriter() or stopAll(), * so its use may result in undefined behaviour. */ - RTPS_DllAPI static RTPSWriter* createRTPSWriter( + FASTDDS_EXPORTED_API static RTPSWriter* createRTPSWriter( RTPSParticipant* p, WriterAttributes& watt, const std::shared_ptr& payload_pool, @@ -158,7 +160,7 @@ class RTPSDomain * \warning The returned pointer is invalidated after a call to removeRTPSWriter() or stopAll(), * so its use may result in undefined behaviour. */ - RTPS_DllAPI static RTPSWriter* createRTPSWriter( + FASTDDS_EXPORTED_API static RTPSWriter* createRTPSWriter( RTPSParticipant* p, WriterAttributes& watt, const std::shared_ptr& payload_pool, @@ -180,7 +182,7 @@ class RTPSDomain * \warning The returned pointer is invalidated after a call to removeRTPSWriter() or stopAll(), * so its use may result in undefined behaviour. */ - RTPS_DllAPI static RTPSWriter* createRTPSWriter( + FASTDDS_EXPORTED_API static RTPSWriter* createRTPSWriter( RTPSParticipant* p, const EntityId_t& entity_id, WriterAttributes& watt, @@ -202,7 +204,7 @@ class RTPSDomain * \warning The returned pointer is invalidated after a call to removeRTPSWriter() or stopAll(), * so its use may result in undefined behaviour. */ - RTPS_DllAPI static RTPSWriter* createRTPSWriter( + FASTDDS_EXPORTED_API static RTPSWriter* createRTPSWriter( RTPSParticipant* p, const EntityId_t& entity_id, WriterAttributes& watt, @@ -215,7 +217,7 @@ class RTPSDomain * @param writer Pointer to the writer you want to remove. * @return True if correctly removed. */ - RTPS_DllAPI static bool removeRTPSWriter( + FASTDDS_EXPORTED_API static bool removeRTPSWriter( RTPSWriter* writer); /** @@ -229,7 +231,7 @@ class RTPSDomain * \warning The returned pointer is invalidated after a call to removeRTPSReader() or stopAll(), * so its use may result in undefined behaviour. */ - RTPS_DllAPI static RTPSReader* createRTPSReader( + FASTDDS_EXPORTED_API static RTPSReader* createRTPSReader( RTPSParticipant* p, ReaderAttributes& ratt, ReaderHistory* hist, @@ -247,7 +249,7 @@ class RTPSDomain * \warning The returned pointer is invalidated after a call to removeRTPSReader() or stopAll(), * so its use may result in undefined behaviour. */ - RTPS_DllAPI static RTPSReader* createRTPSReader( + FASTDDS_EXPORTED_API static RTPSReader* createRTPSReader( RTPSParticipant* p, ReaderAttributes& ratt, const std::shared_ptr& payload_pool, @@ -267,7 +269,7 @@ class RTPSDomain * \warning The returned pointer is invalidated after a call to removeRTPSReader() or stopAll(), * so its use may result in undefined behaviour. */ - RTPS_DllAPI static RTPSReader* createRTPSReader( + FASTDDS_EXPORTED_API static RTPSReader* createRTPSReader( RTPSParticipant* p, const EntityId_t& entity_id, ReaderAttributes& ratt, @@ -280,7 +282,7 @@ class RTPSDomain * @param reader Pointer to the reader you want to remove. * @return True if correctly removed. */ - RTPS_DllAPI static bool removeRTPSReader( + FASTDDS_EXPORTED_API static bool removeRTPSReader( RTPSReader* reader); /** @@ -288,9 +290,40 @@ class RTPSDomain * @param[in] p Pointer to the RTPSParticipant; * @return True if correct. */ - RTPS_DllAPI static bool removeRTPSParticipant( + FASTDDS_EXPORTED_API static bool removeRTPSParticipant( RTPSParticipant* p); + /** + * @brief Get the library settings. + * + * @param library_settings LibrarySettings reference where the settings are returned. + * @return True. + */ + FASTDDS_EXPORTED_API static bool get_library_settings( + fastdds::LibrarySettings& library_settings); + + /** + * @brief Set the library settings- + * + * @param library_settings LibrarySettings to be set. + * @return False if there is any RTPSParticipant already created. + * True if correctly set. + */ + FASTDDS_EXPORTED_API static bool set_library_settings( + const fastdds::LibrarySettings& library_settings); + + /** + * @brief Get the TopicAttributes from XML profile. + * + * @param profile_name Topic profile name. + * @param topic_att TopicAttributes object where the attributes are returned. + * @return bool true if the profile exists. + * false otherwise. + */ + FASTDDS_EXPORTED_API static bool get_topic_attributes_from_profile( + const std::string& profile_name, + TopicAttributes& topic_att); + private: RTPSDomain() = delete; diff --git a/include/fastdds/rtps/attributes/BuiltinTransports.hpp b/include/fastdds/rtps/attributes/BuiltinTransports.hpp index c3038cb618e..fe38051ccb7 100644 --- a/include/fastdds/rtps/attributes/BuiltinTransports.hpp +++ b/include/fastdds/rtps/attributes/BuiltinTransports.hpp @@ -21,9 +21,9 @@ #include #include -#include -#include +#include +#include namespace eprosima { namespace fastdds { @@ -33,7 +33,7 @@ namespace rtps { /** * @brief Options for configuring the built-in transports when using LARGE_DATA mode. */ -struct RTPS_DllAPI BuiltinTransportsOptions +struct FASTDDS_EXPORTED_API BuiltinTransportsOptions { //! Whether to use non-blocking send operation. bool non_blocking_send = false; diff --git a/include/fastdds/rtps/attributes/EndpointAttributes.h b/include/fastdds/rtps/attributes/EndpointAttributes.h index 7317b4b4379..09ff7d02ee2 100644 --- a/include/fastdds/rtps/attributes/EndpointAttributes.h +++ b/include/fastdds/rtps/attributes/EndpointAttributes.h @@ -19,12 +19,11 @@ #ifndef _FASTDDS_ENDPOINTATTRIBUTES_H_ #define _FASTDDS_ENDPOINTATTRIBUTES_H_ +#include #include #include -#include - #include -#include +#include #include #if HAVE_SECURITY @@ -77,7 +76,7 @@ class EndpointAttributes PropertyPolicy properties; //!Ownership - OwnershipQosPolicyKind ownershipKind = SHARED_OWNERSHIP_QOS; + fastdds::dds::OwnershipQosPolicyKind ownershipKind = fastdds::dds::OwnershipQosPolicyKind::SHARED_OWNERSHIP_QOS; EndpointAttributes() { @@ -129,7 +128,7 @@ class EndpointAttributes * @param cfg Configuration to be set */ inline void set_data_sharing_configuration( - DataSharingQosPolicy cfg) + fastdds::dds::DataSharingQosPolicy cfg) { datasharing_ = cfg; } @@ -138,7 +137,7 @@ class EndpointAttributes * Get the DataSharing configuration * @return Configuration of data sharing */ - inline const DataSharingQosPolicy& data_sharing_configuration() const + inline const fastdds::dds::DataSharingQosPolicy& data_sharing_configuration() const { return datasharing_; } @@ -170,7 +169,7 @@ class EndpointAttributes #endif // HAVE_SECURITY //! Settings for datasharing - DataSharingQosPolicy datasharing_; + fastdds::dds::DataSharingQosPolicy datasharing_; }; } /* namespace rtps */ diff --git a/include/fastdds/rtps/attributes/HistoryAttributes.h b/include/fastdds/rtps/attributes/HistoryAttributes.h index be1c6fccc36..1f45ec99ae2 100644 --- a/include/fastdds/rtps/attributes/HistoryAttributes.h +++ b/include/fastdds/rtps/attributes/HistoryAttributes.h @@ -21,7 +21,7 @@ #define _FASTDDS_HISTORYATTRIBUTES_H_ #include -#include +#include #include @@ -35,7 +35,7 @@ namespace rtps { * The Publisher-Subscriber API has other fields to define this values (HistoryQosPolicy and ResourceLimitsQosPolicy). * @ingroup RTPS_ATTRIBUTES_MODULE */ -class RTPS_DllAPI HistoryAttributes +class FASTDDS_EXPORTED_API HistoryAttributes { public: diff --git a/include/fastdds/rtps/attributes/PropertyPolicy.h b/include/fastdds/rtps/attributes/PropertyPolicy.h index 92f78e9c769..c38e495b8a7 100644 --- a/include/fastdds/rtps/attributes/PropertyPolicy.h +++ b/include/fastdds/rtps/attributes/PropertyPolicy.h @@ -20,7 +20,7 @@ #include #include -#include +#include namespace eprosima { namespace fastrtps { @@ -30,25 +30,25 @@ class PropertyPolicy { public: - RTPS_DllAPI PropertyPolicy() + FASTDDS_EXPORTED_API PropertyPolicy() { } - RTPS_DllAPI PropertyPolicy( + FASTDDS_EXPORTED_API PropertyPolicy( const PropertyPolicy& property_policy) : properties_(property_policy.properties_) , binary_properties_(property_policy.binary_properties_) { } - RTPS_DllAPI PropertyPolicy( + FASTDDS_EXPORTED_API PropertyPolicy( PropertyPolicy&& property_policy) : properties_(std::move(property_policy.properties_)) , binary_properties_(std::move(property_policy.binary_properties_)) { } - RTPS_DllAPI PropertyPolicy& operator =( + FASTDDS_EXPORTED_API PropertyPolicy& operator =( const PropertyPolicy& property_policy) { properties_ = property_policy.properties_; @@ -56,7 +56,7 @@ class PropertyPolicy return *this; } - RTPS_DllAPI PropertyPolicy& operator =( + FASTDDS_EXPORTED_API PropertyPolicy& operator =( PropertyPolicy&& property_policy) { properties_ = std::move(property_policy.properties_); @@ -64,7 +64,7 @@ class PropertyPolicy return *this; } - RTPS_DllAPI bool operator ==( + FASTDDS_EXPORTED_API bool operator ==( const PropertyPolicy& b) const { return (this->properties_ == b.properties_) && @@ -72,25 +72,25 @@ class PropertyPolicy } //!Get properties - RTPS_DllAPI const PropertySeq& properties() const + FASTDDS_EXPORTED_API const PropertySeq& properties() const { return properties_; } //!Set properties - RTPS_DllAPI PropertySeq& properties() + FASTDDS_EXPORTED_API PropertySeq& properties() { return properties_; } //!Get binary_properties - RTPS_DllAPI const BinaryPropertySeq& binary_properties() const + FASTDDS_EXPORTED_API const BinaryPropertySeq& binary_properties() const { return binary_properties_; } //!Set binary_properties - RTPS_DllAPI BinaryPropertySeq& binary_properties() + FASTDDS_EXPORTED_API BinaryPropertySeq& binary_properties() { return binary_properties_; } @@ -113,21 +113,21 @@ class PropertyPolicyHelper * @param prefix Prefix used to search properties. * @return A copy of properties whose name starts with the prefix. */ - RTPS_DllAPI static PropertyPolicy get_properties_with_prefix( + FASTDDS_EXPORTED_API static PropertyPolicy get_properties_with_prefix( const PropertyPolicy& property_policy, const std::string& prefix); //!Get the length of the property_policy - RTPS_DllAPI static size_t length( + FASTDDS_EXPORTED_API static size_t length( const PropertyPolicy& property_policy); //!Look for a property_policy by name - RTPS_DllAPI static std::string* find_property( + FASTDDS_EXPORTED_API static std::string* find_property( PropertyPolicy& property_policy, const std::string& name); //!Retrieves a property_policy by name - RTPS_DllAPI static const std::string* find_property( + FASTDDS_EXPORTED_API static const std::string* find_property( const PropertyPolicy& property_policy, const std::string& name); @@ -137,7 +137,7 @@ class PropertyPolicyHelper * @param name Name of the property to be searched. * @return A pointer to the property if found, nullptr otherwise. */ - RTPS_DllAPI static const Property* get_property( + FASTDDS_EXPORTED_API static const Property* get_property( const PropertyPolicy& property_policy, const std::string& name); }; diff --git a/include/fastdds/rtps/attributes/RTPSParticipantAllocationAttributes.hpp b/include/fastdds/rtps/attributes/RTPSParticipantAllocationAttributes.hpp index 5472aefad86..5d3019b6eb5 100644 --- a/include/fastdds/rtps/attributes/RTPSParticipantAllocationAttributes.hpp +++ b/include/fastdds/rtps/attributes/RTPSParticipantAllocationAttributes.hpp @@ -21,7 +21,7 @@ #include -#include +#include namespace eprosima { namespace fastrtps { diff --git a/include/fastdds/rtps/attributes/RTPSParticipantAttributes.h b/include/fastdds/rtps/attributes/RTPSParticipantAttributes.h index 9a826b3933c..307f8f6d4d0 100644 --- a/include/fastdds/rtps/attributes/RTPSParticipantAttributes.h +++ b/include/fastdds/rtps/attributes/RTPSParticipantAttributes.h @@ -22,6 +22,8 @@ #include #include +#include + #include #include #include @@ -37,8 +39,7 @@ #include #include #include -#include -#include +#include namespace eprosima { namespace fastdds { @@ -301,28 +302,6 @@ class DiscoverySettings (this->ignoreParticipantFlags == b.ignoreParticipantFlags); } - /** - * Get the static endpoint XML filename - * @return Static endpoint XML filename - */ - FASTRTPS_DEPRECATED("Use static_edp_xml_config()") - const char* getStaticEndpointXMLFilename() const - { - return static_edp_xml_config(); - } - - /** - * Set the static endpoint XML filename - * @param str Static endpoint XML filename - * @deprecated - */ - FASTRTPS_DEPRECATED("Use static_edp_xml_config()") - void setStaticEndpointXMLFilename( - const char* str) - { - static_edp_xml_config_ = "file://" + std::string(str); - } - /** * Set the static endpoint XML configuration. * @param str URI specifying the static endpoint XML configuration. @@ -351,21 +330,6 @@ class DiscoverySettings std::string static_edp_xml_config_ = ""; }; -/** - * TypeLookupService settings. - */ -class TypeLookupSettings -{ -public: - - //!Indicates to use the TypeLookup Service client endpoints - bool use_client = false; - - //!Indicates to use the TypeLookup Service server endpoints - bool use_server = false; - -}; - /** * Class BuiltinAttributes, to define the behavior of the RTPSParticipant builtin protocols. * @ingroup RTPS_ATTRIBUTES_MODULE @@ -380,9 +344,6 @@ class BuiltinAttributes //! Indicates to use the WriterLiveliness protocol. bool use_WriterLivelinessProtocol = true; - //! TypeLookup Service settings - TypeLookupSettings typelookup_config; - //! Network Configuration NetworkConfigSet_t network_configuration = 0; @@ -427,8 +388,6 @@ class BuiltinAttributes { return (this->discovery_config == b.discovery_config) && (this->use_WriterLivelinessProtocol == b.use_WriterLivelinessProtocol) && - (typelookup_config.use_client == b.typelookup_config.use_client) && - (typelookup_config.use_server == b.typelookup_config.use_server) && (this->network_configuration == b.network_configuration) && (this->metatrafficUnicastLocatorList == b.metatrafficUnicastLocatorList) && (this->metatrafficMulticastLocatorList == b.metatrafficMulticastLocatorList) && @@ -484,6 +443,7 @@ class RTPSParticipantAttributes (this->security_log_thread == b.security_log_thread) && #endif // if HAVE_SECURITY (this->discovery_server_thread == b.discovery_server_thread) && + (this->typelookup_service_thread == b.typelookup_service_thread) && (this->builtin_transports_reception_threads == b.builtin_transports_reception_threads); } @@ -495,7 +455,7 @@ class RTPSParticipantAttributes * @param transports Defines the transport configuration scenario to setup. * @param options Defines the options to be used in the transport configuration. */ - RTPS_DllAPI void setup_transports( + FASTDDS_EXPORTED_API void setup_transports( fastdds::rtps::BuiltinTransports transports, const fastdds::rtps::BuiltinTransportsOptions& options = fastdds::rtps::BuiltinTransportsOptions()); @@ -538,7 +498,7 @@ class RTPSParticipantAttributes //! Optionally allows user to define the GuidPrefix_t GuidPrefix_t prefix; - RTPS_DllAPI inline bool ReadguidPrefix( + FASTDDS_EXPORTED_API inline bool ReadguidPrefix( const char* pfx) { return bool(std::istringstream(pfx) >> prefix); @@ -600,6 +560,9 @@ class RTPSParticipantAttributes //! Thread settings for the discovery server thread fastdds::rtps::ThreadSettings discovery_server_thread; + //! Thread settings for the builtin TypeLookup service requests and replies threads + fastdds::rtps::ThreadSettings typelookup_service_thread; + //! Thread settings for the builtin transports reception threads fastdds::rtps::ThreadSettings builtin_transports_reception_threads; @@ -617,7 +580,7 @@ class RTPSParticipantAttributes private: //! Name of the participant. - string_255 name{"RTPSParticipant"}; + fastcdr::string_255 name{"RTPSParticipant"}; }; } // namespace rtps diff --git a/include/fastdds/rtps/attributes/ReaderAttributes.h b/include/fastdds/rtps/attributes/ReaderAttributes.h index 890623425eb..4c0d5e67f61 100644 --- a/include/fastdds/rtps/attributes/ReaderAttributes.h +++ b/include/fastdds/rtps/attributes/ReaderAttributes.h @@ -20,11 +20,11 @@ #ifndef _FASTDDS_RTPS_ATTRIBUTES_READERATTRIBUTES_H_ #define _FASTDDS_RTPS_ATTRIBUTES_READERATTRIBUTES_H_ +#include #include #include #include -#include -#include +#include namespace eprosima { namespace fastrtps { @@ -70,7 +70,7 @@ class ReaderAttributes public: ReaderAttributes() - : liveliness_kind_(AUTOMATIC_LIVELINESS_QOS) + : liveliness_kind_(fastdds::dds::LivelinessQosPolicyKind::AUTOMATIC_LIVELINESS_QOS) , liveliness_lease_duration(TIME_T_INFINITE_SECONDS, TIME_T_INFINITE_NANOSECONDS) , expectsInlineQos(false) , disable_positive_acks(false) @@ -91,7 +91,7 @@ class ReaderAttributes ReaderTimes times; //! Liveliness kind - LivelinessQosPolicyKind liveliness_kind_; + fastdds::dds::LivelinessQosPolicyKind liveliness_kind_; //! Liveliness lease duration Duration_t liveliness_lease_duration; diff --git a/include/fastdds/rtps/attributes/ServerAttributes.h b/include/fastdds/rtps/attributes/ServerAttributes.h index 13f58753c43..4076cba29e2 100644 --- a/include/fastdds/rtps/attributes/ServerAttributes.h +++ b/include/fastdds/rtps/attributes/ServerAttributes.h @@ -22,7 +22,7 @@ #ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC #include -#include +#include #include #include @@ -48,7 +48,7 @@ class RemoteServerAttributes { public: - RTPS_DllAPI inline bool operator ==( + FASTDDS_EXPORTED_API inline bool operator ==( const RemoteServerAttributes& r) const { return guidPrefix == r.guidPrefix @@ -56,7 +56,7 @@ class RemoteServerAttributes && metatrafficMulticastLocatorList == r.metatrafficMulticastLocatorList; } - RTPS_DllAPI void clear() + FASTDDS_EXPORTED_API void clear() { guidPrefix = fastrtps::rtps::GuidPrefix_t::unknown(); metatrafficUnicastLocatorList.clear(); @@ -64,28 +64,12 @@ class RemoteServerAttributes is_connected = false; } - RTPS_DllAPI fastrtps::rtps::GUID_t GetParticipant() const; + FASTDDS_EXPORTED_API fastrtps::rtps::GUID_t GetParticipant() const; - RTPS_DllAPI fastrtps::rtps::GUID_t GetPDPReader() const; - RTPS_DllAPI fastrtps::rtps::GUID_t GetPDPWriter() const; + FASTDDS_EXPORTED_API fastrtps::rtps::GUID_t GetPDPReader() const; + FASTDDS_EXPORTED_API fastrtps::rtps::GUID_t GetPDPWriter() const; -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_DEPRECATED_UNTIL(3, "eprosima::fastrtps::rtps:GetEDPPublicationsReader()", - "Not implemented nor used functions.") - RTPS_DllAPI fastrtps::rtps::GUID_t GetEDPPublicationsReader() const; - FASTDDS_DEPRECATED_UNTIL(3, "eprosima::fastrtps::rtps:GetEDPSubscriptionsWriter()", - "Not implemented nor used functions.") - RTPS_DllAPI fastrtps::rtps::GUID_t GetEDPSubscriptionsWriter() const; - - FASTDDS_DEPRECATED_UNTIL(3, "eprosima::fastrtps::rtps:GetEDPPublicationsWriter()", - "Not implemented nor used functions.") - RTPS_DllAPI fastrtps::rtps::GUID_t GetEDPPublicationsWriter() const; - FASTDDS_DEPRECATED_UNTIL(3, "eprosima::fastrtps::rtps:GetEDPSubscriptionsReader()", - "Not implemented nor used functions.") - RTPS_DllAPI fastrtps::rtps::GUID_t GetEDPSubscriptionsReader() const; -#endif // ifndef DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI inline bool ReadguidPrefix( + FASTDDS_EXPORTED_API inline bool ReadguidPrefix( const char* pfx) { return bool(std::istringstream(pfx) >> guidPrefix); @@ -117,8 +101,8 @@ typedef std::list RemoteServerList_t; template struct server_ostream_separators { - RTPS_DllAPI static const charT* list_separator; - RTPS_DllAPI static const charT* locator_separator; + FASTDDS_EXPORTED_API static const charT* list_separator; + FASTDDS_EXPORTED_API static const charT* locator_separator; }; #ifndef _MSC_VER @@ -195,7 +179,7 @@ const char* const ROS_SUPER_CLIENT = "ROS_SUPER_CLIENT"; * @param[out] attributes reference to a RemoteServerList_t to populate. * @return true if parsing succeeds, false otherwise (or if the list is empty) */ -RTPS_DllAPI bool load_environment_server_info( +FASTDDS_EXPORTED_API bool load_environment_server_info( const std::string& list, RemoteServerList_t& attributes); @@ -212,20 +196,20 @@ RTPS_DllAPI bool load_environment_server_info( * @param[out] attributes reference to a RemoteServerList_t to populate. * @return true if parsing succeeds, false otherwise */ -RTPS_DllAPI bool load_environment_server_info( +FASTDDS_EXPORTED_API bool load_environment_server_info( RemoteServerList_t& attributes); /** * Get the value of environment variable DEFAULT_ROS2_MASTER_URI * @return The value of environment variable DEFAULT_ROS2_MASTER_URI. Empty string if the variable is not defined. */ -RTPS_DllAPI const std::string& ros_discovery_server_env(); +FASTDDS_EXPORTED_API const std::string& ros_discovery_server_env(); /** * Get the value of environment variable ROS_SUPER_CLIENT * @return The value of environment variable ROS_SUPER_CLIENT. False if the variable is not defined. */ -RTPS_DllAPI bool ros_super_client_env(); +FASTDDS_EXPORTED_API bool ros_super_client_env(); /** * Returns the guidPrefix associated to the given server id @@ -233,7 +217,7 @@ RTPS_DllAPI bool ros_super_client_env(); * @param[out] guid reference to the guidPrefix to modify * @return true if the server guid can be delivered */ -RTPS_DllAPI bool get_server_client_default_guidPrefix( +FASTDDS_EXPORTED_API bool get_server_client_default_guidPrefix( int id, fastrtps::rtps::GuidPrefix_t& guid); diff --git a/include/fastdds/rtps/attributes/ThreadSettings.hpp b/include/fastdds/rtps/attributes/ThreadSettings.hpp index ed2a85f0b9b..d6d39524ee3 100644 --- a/include/fastdds/rtps/attributes/ThreadSettings.hpp +++ b/include/fastdds/rtps/attributes/ThreadSettings.hpp @@ -19,7 +19,7 @@ #include #include -#include +#include #ifndef _FASTDDS_THREADSETTINGS_HPP_ #define _FASTDDS_THREADSETTINGS_HPP_ @@ -33,7 +33,7 @@ namespace rtps { * This class is used to define attributes across a wide set of Qos and APIs. * @ingroup RTPS_ATTRIBUTES_MODULE */ -struct RTPS_DllAPI ThreadSettings +struct FASTDDS_EXPORTED_API ThreadSettings { /** * @brief The scheduling policy used for this thread. diff --git a/include/fastdds/rtps/attributes/TopicAttributes.h b/include/fastdds/rtps/attributes/TopicAttributes.h new file mode 100644 index 00000000000..7234ce4242c --- /dev/null +++ b/include/fastdds/rtps/attributes/TopicAttributes.h @@ -0,0 +1,156 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/** + * @file TopicAttributes.h + */ + +#ifndef TOPICPARAMETERS_H_ +#define TOPICPARAMETERS_H_ + +#include + +#include +#include + + +namespace eprosima { +namespace fastrtps { + +/** + * Class TopicAttributes, used by the user to define the attributes of the topic associated with a Publisher or Subscriber. + * @ingroup FASTRTPS_ATTRIBUTES_MODULE + */ +class TopicAttributes +{ +public: + + /** + * Default constructor + */ + TopicAttributes() + : topicKind(rtps::NO_KEY) + , topicName("UNDEF") + , topicDataType("UNDEF") + , auto_fill_type_information(true) + { + } + + //!Constructor, you need to provide the topic name and the topic data type. + TopicAttributes( + const char* name, + const char* dataType, + rtps::TopicKind_t tKind = rtps::NO_KEY) + { + topicKind = tKind; + topicName = name; + topicDataType = dataType; + auto_fill_type_information = true; + } + + virtual ~TopicAttributes() + { + } + + bool operator ==( + const TopicAttributes& b) const + { + return (this->topicKind == b.topicKind) && + (this->topicName == b.topicName) && + (this->topicDataType == b.topicDataType) && + (this->historyQos == b.historyQos); + } + + /** + * Get the topic data type + * @return Topic data type + */ + const fastcdr::string_255& getTopicDataType() const + { + return topicDataType; + } + + /** + * Get the topic kind + * @return Topic kind + */ + rtps::TopicKind_t getTopicKind() const + { + return topicKind; + } + + /** + * Get the topic name + * @return Topic name + */ + const fastcdr::string_255& getTopicName() const + { + return topicName; + } + + //! TopicKind_t, default value NO_KEY. + rtps::TopicKind_t topicKind; + //! Topic Name. + fastcdr::string_255 topicName; + //!Topic Data Type. + fastcdr::string_255 topicDataType; + //!QOS Regarding the History to be saved. + HistoryQosPolicy historyQos; + //!QOS Regarding the resources to allocate. + ResourceLimitsQosPolicy resourceLimitsQos; + //!Type Identifier XTYPES 1.1 + TypeIdV1 type_id; + //!Type Object XTYPES 1.1 + TypeObjectV1 type; + //!XTYPES 1.2 + xtypes::TypeInformationParameter type_information; + //!Tries to complete type information (TypeObjectV2) + bool auto_fill_type_information; + + /** + * Method to check whether the defined QOS are correct. + * @return True if they are valid. + */ + bool checkQos() const; +}; + +#ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +/** + * Check if two topic attributes are not equal + * @param t1 First instance of TopicAttributes to compare + * @param t2 Second instance of TopicAttributes to compare + * @return True if the instances are not equal. False if the instances are equal. + */ +bool inline operator !=( + const TopicAttributes& t1, + const TopicAttributes& t2) +{ + if (t1.topicKind != t2.topicKind + || t1.topicName != t2.topicName + || t1.topicDataType != t2.topicDataType + || t1.historyQos.kind != t2.historyQos.kind + || (t1.historyQos.kind == KEEP_LAST_HISTORY_QOS && t1.historyQos.depth != t2.historyQos.depth)) + { + return true; + } + return false; +} + +#endif // ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +} /* namespace fastrtps */ +} /* namespace eprosima */ + +#endif /* TOPICPARAMETERS_H_ */ diff --git a/include/fastdds/rtps/attributes/WriterAttributes.h b/include/fastdds/rtps/attributes/WriterAttributes.h index 7c9dd2d5ac1..adf951ee14e 100644 --- a/include/fastdds/rtps/attributes/WriterAttributes.h +++ b/include/fastdds/rtps/attributes/WriterAttributes.h @@ -19,15 +19,15 @@ #ifndef _FASTDDS_WRITERATTRIBUTES_H_ #define _FASTDDS_WRITERATTRIBUTES_H_ -#include -#include -#include +#include + +#include #include +#include +#include #include -#include -#include - -#include +#include +#include namespace eprosima { namespace fastrtps { @@ -88,7 +88,7 @@ class WriterAttributes public: WriterAttributes() - : liveliness_kind(AUTOMATIC_LIVELINESS_QOS) + : liveliness_kind(fastdds::dds::LivelinessQosPolicyKind::AUTOMATIC_LIVELINESS_QOS) , liveliness_lease_duration(TIME_T_INFINITE_SECONDS, TIME_T_INFINITE_NANOSECONDS) , liveliness_announcement_period(TIME_T_INFINITE_SECONDS, TIME_T_INFINITE_NANOSECONDS) , mode(SYNCHRONOUS_WRITER) @@ -112,7 +112,7 @@ class WriterAttributes WriterTimes times; //! Liveliness kind - fastrtps::LivelinessQosPolicyKind liveliness_kind; + fastdds::dds::LivelinessQosPolicyKind liveliness_kind; //! Liveliness lease duration Duration_t liveliness_lease_duration; diff --git a/include/fastdds/rtps/builtin/data/ContentFilterProperty.hpp b/include/fastdds/rtps/builtin/data/ContentFilterProperty.hpp index 2a23a32d278..ec174f85cea 100644 --- a/include/fastdds/rtps/builtin/data/ContentFilterProperty.hpp +++ b/include/fastdds/rtps/builtin/data/ContentFilterProperty.hpp @@ -21,9 +21,9 @@ #include -#include -#include -#include +#include +#include +#include namespace eprosima { namespace fastdds { @@ -62,17 +62,17 @@ class ContentFilterProperty } /// Name of the content filtered topic on which the reader was created - fastrtps::string_255 content_filtered_topic_name; + fastcdr::string_255 content_filtered_topic_name; /// Name of the related topic being filtered - fastrtps::string_255 related_topic_name; + fastcdr::string_255 related_topic_name; /// Class name of the filter being used. /// May be empty to indicate the ContentFilterProperty is not present. - fastrtps::string_255 filter_class_name; + fastcdr::string_255 filter_class_name; /// Filter expression indicating which content the reader wants to receive. /// May be empty to indicate the ContentFilterProperty is not present. std::string filter_expression; /// List of values for the parameters present on the filter expression - fastrtps::ResourceLimitedVector expression_parameters; + fastrtps::ResourceLimitedVector expression_parameters; }; } // namespace rtps diff --git a/include/fastdds/rtps/builtin/data/ParticipantProxyData.h b/include/fastdds/rtps/builtin/data/ParticipantProxyData.h index 101d0249c9b..3b87103de14 100644 --- a/include/fastdds/rtps/builtin/data/ParticipantProxyData.h +++ b/include/fastdds/rtps/builtin/data/ParticipantProxyData.h @@ -21,6 +21,10 @@ #define _FASTDDS_RTPS_BUILTIN_DATA_PARTICIPANTPROXYDATA_H_ #ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +#include + +#include #include #include #include @@ -31,10 +35,6 @@ #if HAVE_SECURITY #include #endif // if HAVE_SECURITY -#include - - -#include #define BUILTIN_PARTICIPANT_DATA_MAX_SIZE 100 #define TYPELOOKUP_DATA_MAX_SIZE 5000 @@ -63,13 +63,13 @@ class ParticipantProxyData { public: - RTPS_DllAPI ParticipantProxyData( + FASTDDS_EXPORTED_API ParticipantProxyData( const RTPSParticipantAllocationAttributes& allocation); - RTPS_DllAPI ParticipantProxyData( + FASTDDS_EXPORTED_API ParticipantProxyData( const ParticipantProxyData& pdata); - RTPS_DllAPI virtual ~ParticipantProxyData(); + FASTDDS_EXPORTED_API virtual ~ParticipantProxyData(); //!Protocol version ProtocolVersion_t m_protocolVersion; @@ -90,7 +90,7 @@ class ParticipantProxyData //!Manual liveliness count Count_t m_manualLivelinessCount; //!Participant name - string_255 m_participantName; + fastcdr::string_255 m_participantName; //! InstanceHandle_t m_key; //! @@ -108,9 +108,9 @@ class ParticipantProxyData //! bool isAlive; //! - ParameterPropertyList_t m_properties; + fastdds::dds::ParameterPropertyList_t m_properties; //! - UserDataQosPolicy m_userData; + fastdds::dds::UserDataQosPolicy m_userData; //! TimedEvent* lease_duration_event; //! @@ -127,7 +127,7 @@ class ParticipantProxyData * @param pdata Object to copy the data from * @return True on success */ - RTPS_DllAPI bool updateData( + FASTDDS_EXPORTED_API bool updateData( ParticipantProxyData& pdata); /** @@ -135,14 +135,14 @@ class ParticipantProxyData * @param include_encapsulation Whether to include the size of the encapsulation info. * @return size in bytes of the CDR serialization. */ - RTPS_DllAPI uint32_t get_serialized_size( + FASTDDS_EXPORTED_API uint32_t get_serialized_size( bool include_encapsulation) const; /** * Write as a parameter list on a CDRMessage_t * @return True on success */ - RTPS_DllAPI bool writeToCDRMessage( + FASTDDS_EXPORTED_API bool writeToCDRMessage( CDRMessage_t* msg, bool write_encapsulation); @@ -150,7 +150,7 @@ class ParticipantProxyData * Read the parameter list from a received CDRMessage_t * @return True on success */ - RTPS_DllAPI bool readFromCDRMessage( + FASTDDS_EXPORTED_API bool readFromCDRMessage( CDRMessage_t* msg, bool use_encapsulation, const NetworkFactory& network, @@ -159,62 +159,62 @@ class ParticipantProxyData fastdds::rtps::VendorId_t source_vendor_id = c_VendorId_eProsima); //! Clear the data (restore to default state). - RTPS_DllAPI void clear(); + FASTDDS_EXPORTED_API void clear(); /** * Copy the data from another object. * @param pdata Object to copy the data from */ - RTPS_DllAPI void copy( + FASTDDS_EXPORTED_API void copy( const ParticipantProxyData& pdata); /** * Set participant persistent GUID_t * @param guid valid GUID_t */ - RTPS_DllAPI void set_persistence_guid( + FASTDDS_EXPORTED_API void set_persistence_guid( const GUID_t& guid); /** * Retrieve participant persistent GUID_t * @return guid persistent GUID_t or c_Guid_Unknown */ - RTPS_DllAPI GUID_t get_persistence_guid() const; + FASTDDS_EXPORTED_API GUID_t get_persistence_guid() const; /** * Set participant client server sample identity * @param sid valid SampleIdentity */ - RTPS_DllAPI void set_sample_identity( + FASTDDS_EXPORTED_API void set_sample_identity( const SampleIdentity& sid); /** * Retrieve participant SampleIdentity * @return SampleIdentity */ - RTPS_DllAPI SampleIdentity get_sample_identity() const; + FASTDDS_EXPORTED_API SampleIdentity get_sample_identity() const; /** * Identifies the participant as client of the given server * @param guid valid backup server GUID */ - RTPS_DllAPI void set_backup_stamp( + FASTDDS_EXPORTED_API void set_backup_stamp( const GUID_t& guid); /** * Retrieves BACKUP server stamp. On deserialization hints if lease duration must be enforced * @return GUID */ - RTPS_DllAPI GUID_t get_backup_stamp() const; + FASTDDS_EXPORTED_API GUID_t get_backup_stamp() const; - RTPS_DllAPI void assert_liveliness(); + FASTDDS_EXPORTED_API void assert_liveliness(); - RTPS_DllAPI const std::chrono::steady_clock::time_point& last_received_message_tm() const + FASTDDS_EXPORTED_API const std::chrono::steady_clock::time_point& last_received_message_tm() const { return last_received_message_tm_; } - RTPS_DllAPI const std::chrono::microseconds& lease_duration() const + FASTDDS_EXPORTED_API const std::chrono::microseconds& lease_duration() const { return lease_duration_; } diff --git a/include/fastdds/rtps/builtin/data/ReaderProxyData.h b/include/fastdds/rtps/builtin/data/ReaderProxyData.h index ba3fa8e0013..774b78625e8 100644 --- a/include/fastdds/rtps/builtin/data/ReaderProxyData.h +++ b/include/fastdds/rtps/builtin/data/ReaderProxyData.h @@ -21,6 +21,7 @@ #define _FASTDDS_RTPS_BUILTIN_DATA_READERPROXYDATA_H_ #ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC +#include #include #include #include @@ -29,10 +30,7 @@ #if HAVE_SECURITY #include #endif // if HAVE_SECURITY -#include -#include - - +#include namespace eprosima { namespace fastrtps { @@ -50,80 +48,80 @@ class ReaderProxyData { public: - RTPS_DllAPI ReaderProxyData( + FASTDDS_EXPORTED_API ReaderProxyData( const size_t max_unicast_locators, const size_t max_multicast_locators, const fastdds::rtps::ContentFilterProperty::AllocationConfiguration& content_filter_limits = {}); - RTPS_DllAPI ReaderProxyData( + FASTDDS_EXPORTED_API ReaderProxyData( const size_t max_unicast_locators, const size_t max_multicast_locators, const VariableLengthDataLimits& data_limits, const fastdds::rtps::ContentFilterProperty::AllocationConfiguration& content_filter_limits = {}); - RTPS_DllAPI virtual ~ReaderProxyData(); + FASTDDS_EXPORTED_API virtual ~ReaderProxyData(); - RTPS_DllAPI ReaderProxyData( + FASTDDS_EXPORTED_API ReaderProxyData( const ReaderProxyData& readerInfo); - RTPS_DllAPI ReaderProxyData& operator =( + FASTDDS_EXPORTED_API ReaderProxyData& operator =( const ReaderProxyData& readerInfo); - RTPS_DllAPI void guid( + FASTDDS_EXPORTED_API void guid( const GUID_t& guid) { m_guid = guid; } - RTPS_DllAPI void guid( + FASTDDS_EXPORTED_API void guid( GUID_t&& guid) { m_guid = std::move(guid); } - RTPS_DllAPI const GUID_t& guid() const + FASTDDS_EXPORTED_API const GUID_t& guid() const { return m_guid; } - RTPS_DllAPI GUID_t& guid() + FASTDDS_EXPORTED_API GUID_t& guid() { return m_guid; } - RTPS_DllAPI void networkConfiguration( + FASTDDS_EXPORTED_API void networkConfiguration( const NetworkConfigSet_t& networkConfiguration) { m_networkConfiguration = networkConfiguration; } - RTPS_DllAPI void networkConfiguration( + FASTDDS_EXPORTED_API void networkConfiguration( NetworkConfigSet_t&& networkConfiguration) { m_networkConfiguration = std::move(networkConfiguration); } - RTPS_DllAPI const NetworkConfigSet_t& networkConfiguration() const + FASTDDS_EXPORTED_API const NetworkConfigSet_t& networkConfiguration() const { return m_networkConfiguration; } - RTPS_DllAPI NetworkConfigSet_t& networkConfiguration() + FASTDDS_EXPORTED_API NetworkConfigSet_t& networkConfiguration() { return m_networkConfiguration; } - RTPS_DllAPI bool has_locators() const + FASTDDS_EXPORTED_API bool has_locators() const { return !remote_locators_.unicast.empty() || !remote_locators_.multicast.empty(); } - RTPS_DllAPI const RemoteLocatorList& remote_locators() const + FASTDDS_EXPORTED_API const RemoteLocatorList& remote_locators() const { return remote_locators_; } - RTPS_DllAPI void add_unicast_locator( + FASTDDS_EXPORTED_API void add_unicast_locator( const Locator_t& locator); void set_announced_unicast_locators( @@ -133,7 +131,7 @@ class ReaderProxyData const LocatorList_t& locators, const NetworkFactory& network); - RTPS_DllAPI void add_multicast_locator( + FASTDDS_EXPORTED_API void add_multicast_locator( const Locator_t& locator); void set_multicast_locators( @@ -148,177 +146,177 @@ class ReaderProxyData const NetworkFactory& network, bool use_multicast_locators); - RTPS_DllAPI void key( + FASTDDS_EXPORTED_API void key( const InstanceHandle_t& key) { m_key = key; } - RTPS_DllAPI void key( + FASTDDS_EXPORTED_API void key( InstanceHandle_t&& key) { m_key = std::move(key); } - RTPS_DllAPI InstanceHandle_t key() const + FASTDDS_EXPORTED_API InstanceHandle_t key() const { return m_key; } - RTPS_DllAPI InstanceHandle_t& key() + FASTDDS_EXPORTED_API InstanceHandle_t& key() { return m_key; } - RTPS_DllAPI void RTPSParticipantKey( + FASTDDS_EXPORTED_API void RTPSParticipantKey( const InstanceHandle_t& RTPSParticipantKey) { m_RTPSParticipantKey = RTPSParticipantKey; } - RTPS_DllAPI void RTPSParticipantKey( + FASTDDS_EXPORTED_API void RTPSParticipantKey( InstanceHandle_t&& RTPSParticipantKey) { m_RTPSParticipantKey = std::move(RTPSParticipantKey); } - RTPS_DllAPI InstanceHandle_t RTPSParticipantKey() const + FASTDDS_EXPORTED_API InstanceHandle_t RTPSParticipantKey() const { return m_RTPSParticipantKey; } - RTPS_DllAPI InstanceHandle_t& RTPSParticipantKey() + FASTDDS_EXPORTED_API InstanceHandle_t& RTPSParticipantKey() { return m_RTPSParticipantKey; } - RTPS_DllAPI void typeName( - const string_255& typeName) + FASTDDS_EXPORTED_API void typeName( + const fastcdr::string_255& typeName) { m_typeName = typeName; } - RTPS_DllAPI void typeName( - string_255&& typeName) + FASTDDS_EXPORTED_API void typeName( + fastcdr::string_255&& typeName) { m_typeName = std::move(typeName); } - RTPS_DllAPI const string_255& typeName() const + FASTDDS_EXPORTED_API const fastcdr::string_255& typeName() const { return m_typeName; } - RTPS_DllAPI string_255& typeName() + FASTDDS_EXPORTED_API fastcdr::string_255& typeName() { return m_typeName; } - RTPS_DllAPI void topicName( - const string_255& topicName) + FASTDDS_EXPORTED_API void topicName( + const fastcdr::string_255& topicName) { m_topicName = topicName; } - RTPS_DllAPI void topicName( - string_255&& topicName) + FASTDDS_EXPORTED_API void topicName( + fastcdr::string_255&& topicName) { m_topicName = std::move(topicName); } - RTPS_DllAPI const string_255& topicName() const + FASTDDS_EXPORTED_API const fastcdr::string_255& topicName() const { return m_topicName; } - RTPS_DllAPI string_255& topicName() + FASTDDS_EXPORTED_API fastcdr::string_255& topicName() { return m_topicName; } - RTPS_DllAPI void userDefinedId( + FASTDDS_EXPORTED_API void userDefinedId( uint16_t userDefinedId) { m_userDefinedId = userDefinedId; } - RTPS_DllAPI uint16_t userDefinedId() const + FASTDDS_EXPORTED_API uint16_t userDefinedId() const { return m_userDefinedId; } - RTPS_DllAPI uint16_t& userDefinedId() + FASTDDS_EXPORTED_API uint16_t& userDefinedId() { return m_userDefinedId; } - RTPS_DllAPI void content_filter( + FASTDDS_EXPORTED_API void content_filter( const fastdds::rtps::ContentFilterProperty& filter) { content_filter_ = filter; } - RTPS_DllAPI void content_filter( + FASTDDS_EXPORTED_API void content_filter( fastdds::rtps::ContentFilterProperty&& filter) { content_filter_ = std::move(filter); } - RTPS_DllAPI const fastdds::rtps::ContentFilterProperty& content_filter() const + FASTDDS_EXPORTED_API const fastdds::rtps::ContentFilterProperty& content_filter() const { return content_filter_; } - RTPS_DllAPI fastdds::rtps::ContentFilterProperty& content_filter() + FASTDDS_EXPORTED_API fastdds::rtps::ContentFilterProperty& content_filter() { return content_filter_; } - RTPS_DllAPI void isAlive( + FASTDDS_EXPORTED_API void isAlive( bool isAlive) { m_isAlive = isAlive; } - RTPS_DllAPI bool isAlive() const + FASTDDS_EXPORTED_API bool isAlive() const { return m_isAlive; } - RTPS_DllAPI bool& isAlive() + FASTDDS_EXPORTED_API bool& isAlive() { return m_isAlive; } - RTPS_DllAPI void topicKind( + FASTDDS_EXPORTED_API void topicKind( TopicKind_t topicKind) { m_topicKind = topicKind; } - RTPS_DllAPI TopicKind_t topicKind() const + FASTDDS_EXPORTED_API TopicKind_t topicKind() const { return m_topicKind; } - RTPS_DllAPI TopicKind_t& topicKind() + FASTDDS_EXPORTED_API TopicKind_t& topicKind() { return m_topicKind; } - RTPS_DllAPI void type_id( + FASTDDS_EXPORTED_API void type_id( const TypeIdV1& other_type_id) { type_id() = other_type_id; } - RTPS_DllAPI const TypeIdV1& type_id() const + FASTDDS_EXPORTED_API const TypeIdV1& type_id() const { assert(m_type_id != nullptr); return *m_type_id; } - RTPS_DllAPI TypeIdV1& type_id() + FASTDDS_EXPORTED_API TypeIdV1& type_id() { if (m_type_id == nullptr) { @@ -327,24 +325,24 @@ class ReaderProxyData return *m_type_id; } - RTPS_DllAPI bool has_type_id() const + FASTDDS_EXPORTED_API bool has_type_id() const { return m_type_id != nullptr; } - RTPS_DllAPI void type( + FASTDDS_EXPORTED_API void type( const TypeObjectV1& other_type) { type() = other_type; } - RTPS_DllAPI const TypeObjectV1& type() const + FASTDDS_EXPORTED_API const TypeObjectV1& type() const { assert(m_type != nullptr); return *m_type; } - RTPS_DllAPI TypeObjectV1& type() + FASTDDS_EXPORTED_API TypeObjectV1& type() { if (m_type == nullptr) { @@ -353,33 +351,33 @@ class ReaderProxyData return *m_type; } - RTPS_DllAPI bool has_type() const + FASTDDS_EXPORTED_API bool has_type() const { return m_type != nullptr; } - RTPS_DllAPI void type_information( - const xtypes::TypeInformation& other_type_information) + FASTDDS_EXPORTED_API void type_information( + const xtypes::TypeInformationParameter& other_type_information) { type_information() = other_type_information; } - RTPS_DllAPI const xtypes::TypeInformation& type_information() const + FASTDDS_EXPORTED_API const xtypes::TypeInformationParameter& type_information() const { assert(m_type_information != nullptr); return *m_type_information; } - RTPS_DllAPI xtypes::TypeInformation& type_information() + FASTDDS_EXPORTED_API xtypes::TypeInformationParameter& type_information() { if (m_type_information == nullptr) { - m_type_information = new xtypes::TypeInformation(); + m_type_information = new xtypes::TypeInformationParameter(); } return *m_type_information; } - RTPS_DllAPI bool has_type_information() const + FASTDDS_EXPORTED_API bool has_type_information() const { return m_type_information != nullptr; } @@ -444,7 +442,7 @@ class ReaderProxyData //! bool m_expectsInlineQos; //!Reader Qos - ReaderQos m_qos; + fastdds::dds::ReaderQos m_qos; #if HAVE_SECURITY //!EndpointSecurityInfo.endpoint_security_attributes @@ -494,9 +492,9 @@ class ReaderProxyData //!GUID_t of the participant converted to InstanceHandle InstanceHandle_t m_RTPSParticipantKey; //!Type name - string_255 m_typeName; + fastcdr::string_255 m_typeName; //!Topic name - string_255 m_topicName; + fastcdr::string_255 m_topicName; //!User defined ID uint16_t m_userDefinedId; //!Field to indicate if the Reader is Alive. @@ -508,7 +506,7 @@ class ReaderProxyData //!Type Object TypeObjectV1* m_type; //!Type Information - xtypes::TypeInformation* m_type_information; + xtypes::TypeInformationParameter* m_type_information; //! ParameterPropertyList_t m_properties; //!Information on the content filter applied by the reader. diff --git a/include/fastdds/rtps/builtin/data/WriterProxyData.h b/include/fastdds/rtps/builtin/data/WriterProxyData.h index 14ffcb079ed..f538232dbfd 100644 --- a/include/fastdds/rtps/builtin/data/WriterProxyData.h +++ b/include/fastdds/rtps/builtin/data/WriterProxyData.h @@ -21,15 +21,18 @@ #define _FASTDDS_RTPS_BUILTIN_DATA_WRITERPROXYDATA_H_ #ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC +#include + +#include #include +#include +#include #include #include #if HAVE_SECURITY #include #endif // if HAVE_SECURITY -#include -#include -#include +#include namespace eprosima { namespace fastrtps { @@ -46,106 +49,106 @@ class WriterProxyData { public: - RTPS_DllAPI WriterProxyData( + FASTDDS_EXPORTED_API WriterProxyData( const size_t max_unicast_locators, const size_t max_multicast_locators); - RTPS_DllAPI WriterProxyData( + FASTDDS_EXPORTED_API WriterProxyData( const size_t max_unicast_locators, const size_t max_multicast_locators, const VariableLengthDataLimits& data_limits); - virtual RTPS_DllAPI ~WriterProxyData(); + virtual FASTDDS_EXPORTED_API ~WriterProxyData(); - RTPS_DllAPI WriterProxyData( + FASTDDS_EXPORTED_API WriterProxyData( const WriterProxyData& writerInfo); - RTPS_DllAPI WriterProxyData& operator =( + FASTDDS_EXPORTED_API WriterProxyData& operator =( const WriterProxyData& writerInfo); - RTPS_DllAPI void guid( + FASTDDS_EXPORTED_API void guid( const GUID_t& guid) { m_guid = guid; } - RTPS_DllAPI void guid( + FASTDDS_EXPORTED_API void guid( GUID_t&& guid) { m_guid = std::move(guid); } - RTPS_DllAPI const GUID_t& guid() const + FASTDDS_EXPORTED_API const GUID_t& guid() const { return m_guid; } - RTPS_DllAPI GUID_t& guid() + FASTDDS_EXPORTED_API GUID_t& guid() { return m_guid; } - RTPS_DllAPI void networkConfiguration( + FASTDDS_EXPORTED_API void networkConfiguration( const NetworkConfigSet_t& networkConfiguration) { m_networkConfiguration = networkConfiguration; } - RTPS_DllAPI void networkConfiguration( + FASTDDS_EXPORTED_API void networkConfiguration( NetworkConfigSet_t&& networkConfiguration) { m_networkConfiguration = std::move(networkConfiguration); } - RTPS_DllAPI const NetworkConfigSet_t& networkConfiguration() const + FASTDDS_EXPORTED_API const NetworkConfigSet_t& networkConfiguration() const { return m_networkConfiguration; } - RTPS_DllAPI NetworkConfigSet_t& networkConfiguration() + FASTDDS_EXPORTED_API NetworkConfigSet_t& networkConfiguration() { return m_networkConfiguration; } - RTPS_DllAPI void persistence_guid( + FASTDDS_EXPORTED_API void persistence_guid( const GUID_t& guid) { persistence_guid_ = guid; } - RTPS_DllAPI void persistence_guid( + FASTDDS_EXPORTED_API void persistence_guid( GUID_t&& guid) { persistence_guid_ = std::move(guid); } - RTPS_DllAPI GUID_t persistence_guid() const + FASTDDS_EXPORTED_API GUID_t persistence_guid() const { return persistence_guid_; } - RTPS_DllAPI GUID_t& persistence_guid() + FASTDDS_EXPORTED_API GUID_t& persistence_guid() { return persistence_guid_; } - RTPS_DllAPI void set_persistence_entity_id( + FASTDDS_EXPORTED_API void set_persistence_entity_id( const EntityId_t& nid) { persistence_guid_.entityId = persistence_guid_.guidPrefix != c_GuidPrefix_Unknown ? nid : c_EntityId_Unknown; } - RTPS_DllAPI bool has_locators() const + FASTDDS_EXPORTED_API bool has_locators() const { return !remote_locators_.unicast.empty() || !remote_locators_.multicast.empty(); } - RTPS_DllAPI const RemoteLocatorList& remote_locators() const + FASTDDS_EXPORTED_API const RemoteLocatorList& remote_locators() const { return remote_locators_; } - RTPS_DllAPI void add_unicast_locator( + FASTDDS_EXPORTED_API void add_unicast_locator( const Locator_t& locator); void set_announced_unicast_locators( @@ -155,7 +158,7 @@ class WriterProxyData const LocatorList_t& locators, const NetworkFactory& network); - RTPS_DllAPI void add_multicast_locator( + FASTDDS_EXPORTED_API void add_multicast_locator( const Locator_t& locator); void set_multicast_locators( @@ -170,155 +173,155 @@ class WriterProxyData const NetworkFactory& network, bool use_multicast_locators); - RTPS_DllAPI void key( + FASTDDS_EXPORTED_API void key( const InstanceHandle_t& key) { m_key = key; } - RTPS_DllAPI void key( + FASTDDS_EXPORTED_API void key( InstanceHandle_t&& key) { m_key = std::move(key); } - RTPS_DllAPI InstanceHandle_t key() const + FASTDDS_EXPORTED_API InstanceHandle_t key() const { return m_key; } - RTPS_DllAPI InstanceHandle_t& key() + FASTDDS_EXPORTED_API InstanceHandle_t& key() { return m_key; } - RTPS_DllAPI void RTPSParticipantKey( + FASTDDS_EXPORTED_API void RTPSParticipantKey( const InstanceHandle_t& RTPSParticipantKey) { m_RTPSParticipantKey = RTPSParticipantKey; } - RTPS_DllAPI void RTPSParticipantKey( + FASTDDS_EXPORTED_API void RTPSParticipantKey( InstanceHandle_t&& RTPSParticipantKey) { m_RTPSParticipantKey = std::move(RTPSParticipantKey); } - RTPS_DllAPI InstanceHandle_t RTPSParticipantKey() const + FASTDDS_EXPORTED_API InstanceHandle_t RTPSParticipantKey() const { return m_RTPSParticipantKey; } - RTPS_DllAPI InstanceHandle_t& RTPSParticipantKey() + FASTDDS_EXPORTED_API InstanceHandle_t& RTPSParticipantKey() { return m_RTPSParticipantKey; } - RTPS_DllAPI void typeName( - const string_255& typeName) + FASTDDS_EXPORTED_API void typeName( + const fastcdr::string_255& typeName) { m_typeName = typeName; } - RTPS_DllAPI void typeName( - string_255&& typeName) + FASTDDS_EXPORTED_API void typeName( + fastcdr::string_255&& typeName) { m_typeName = std::move(typeName); } - RTPS_DllAPI const string_255& typeName() const + FASTDDS_EXPORTED_API const fastcdr::string_255& typeName() const { return m_typeName; } - RTPS_DllAPI string_255& typeName() + FASTDDS_EXPORTED_API fastcdr::string_255& typeName() { return m_typeName; } - RTPS_DllAPI void topicName( - const string_255& topicName) + FASTDDS_EXPORTED_API void topicName( + const fastcdr::string_255& topicName) { m_topicName = topicName; } - RTPS_DllAPI void topicName( - string_255&& topicName) + FASTDDS_EXPORTED_API void topicName( + fastcdr::string_255&& topicName) { m_topicName = std::move(topicName); } - RTPS_DllAPI const string_255& topicName() const + FASTDDS_EXPORTED_API const fastcdr::string_255& topicName() const { return m_topicName; } - RTPS_DllAPI string_255& topicName() + FASTDDS_EXPORTED_API fastcdr::string_255& topicName() { return m_topicName; } - RTPS_DllAPI void userDefinedId( + FASTDDS_EXPORTED_API void userDefinedId( uint16_t userDefinedId) { m_userDefinedId = userDefinedId; } - RTPS_DllAPI uint16_t userDefinedId() const + FASTDDS_EXPORTED_API uint16_t userDefinedId() const { return m_userDefinedId; } - RTPS_DllAPI uint16_t& userDefinedId() + FASTDDS_EXPORTED_API uint16_t& userDefinedId() { return m_userDefinedId; } - RTPS_DllAPI void typeMaxSerialized( + FASTDDS_EXPORTED_API void typeMaxSerialized( uint32_t typeMaxSerialized) { m_typeMaxSerialized = typeMaxSerialized; } - RTPS_DllAPI uint32_t typeMaxSerialized() const + FASTDDS_EXPORTED_API uint32_t typeMaxSerialized() const { return m_typeMaxSerialized; } - RTPS_DllAPI uint32_t& typeMaxSerialized() + FASTDDS_EXPORTED_API uint32_t& typeMaxSerialized() { return m_typeMaxSerialized; } - RTPS_DllAPI void topicKind( + FASTDDS_EXPORTED_API void topicKind( TopicKind_t topicKind) { m_topicKind = topicKind; } - RTPS_DllAPI TopicKind_t topicKind() const + FASTDDS_EXPORTED_API TopicKind_t topicKind() const { return m_topicKind; } - RTPS_DllAPI TopicKind_t& topicKind() + FASTDDS_EXPORTED_API TopicKind_t& topicKind() { return m_topicKind; } - RTPS_DllAPI void type_id( + FASTDDS_EXPORTED_API void type_id( const TypeIdV1& other_type_id) { type_id() = other_type_id; } - RTPS_DllAPI const TypeIdV1& type_id() const + FASTDDS_EXPORTED_API const TypeIdV1& type_id() const { assert(m_type_id != nullptr); return *m_type_id; } - RTPS_DllAPI TypeIdV1& type_id() + FASTDDS_EXPORTED_API TypeIdV1& type_id() { if (m_type_id == nullptr) { @@ -327,24 +330,24 @@ class WriterProxyData return *m_type_id; } - RTPS_DllAPI bool has_type_id() const + FASTDDS_EXPORTED_API bool has_type_id() const { return m_type_id != nullptr; } - RTPS_DllAPI void type( + FASTDDS_EXPORTED_API void type( const TypeObjectV1& other_type) { type() = other_type; } - RTPS_DllAPI const TypeObjectV1& type() const + FASTDDS_EXPORTED_API const TypeObjectV1& type() const { assert(m_type != nullptr); return *m_type; } - RTPS_DllAPI TypeObjectV1& type() + FASTDDS_EXPORTED_API TypeObjectV1& type() { if (m_type == nullptr) { @@ -353,39 +356,39 @@ class WriterProxyData return *m_type; } - RTPS_DllAPI bool has_type() const + FASTDDS_EXPORTED_API bool has_type() const { return m_type != nullptr; } - RTPS_DllAPI void type_information( - const xtypes::TypeInformation& other_type_information) + FASTDDS_EXPORTED_API void type_information( + const xtypes::TypeInformationParameter& other_type_information) { type_information() = other_type_information; } - RTPS_DllAPI const xtypes::TypeInformation& type_information() const + FASTDDS_EXPORTED_API const xtypes::TypeInformationParameter& type_information() const { assert(m_type_information != nullptr); return *m_type_information; } - RTPS_DllAPI xtypes::TypeInformation& type_information() + FASTDDS_EXPORTED_API xtypes::TypeInformationParameter& type_information() { if (m_type_information == nullptr) { - m_type_information = new xtypes::TypeInformation(); + m_type_information = new xtypes::TypeInformationParameter(); } return *m_type_information; } - RTPS_DllAPI bool has_type_information() const + FASTDDS_EXPORTED_API bool has_type_information() const { return m_type_information != nullptr; } //!WriterQOS - WriterQos m_qos; + fastdds::dds::WriterQos m_qos; /** * Set participant client server sample identity @@ -475,10 +478,10 @@ class WriterProxyData InstanceHandle_t m_RTPSParticipantKey; //!Type name - string_255 m_typeName; + fastcdr::string_255 m_typeName; //!Topic name - string_255 m_topicName; + fastcdr::string_255 m_topicName; //!User defined ID uint16_t m_userDefinedId; @@ -499,7 +502,7 @@ class WriterProxyData TypeObjectV1* m_type; //!Type Information - xtypes::TypeInformation* m_type_information; + xtypes::TypeInformationParameter* m_type_information; //! ParameterPropertyList_t m_properties; diff --git a/include/fastdds/rtps/common/CDRMessage_t.h b/include/fastdds/rtps/common/CDRMessage_t.h index 567f4e314bd..d5e6e1f934a 100644 --- a/include/fastdds/rtps/common/CDRMessage_t.h +++ b/include/fastdds/rtps/common/CDRMessage_t.h @@ -47,7 +47,7 @@ namespace rtps { * @brief Structure CDRMessage_t, contains a serialized message. * @ingroup COMMON_MODULE */ -struct RTPS_DllAPI CDRMessage_t final +struct FASTDDS_EXPORTED_API CDRMessage_t final { // TODO(Miguel C): Deprecate when not used in mocks CDRMessage_t() diff --git a/include/fastdds/rtps/common/CacheChange.h b/include/fastdds/rtps/common/CacheChange.h index 3c0d30d19f7..cb88c738d38 100644 --- a/include/fastdds/rtps/common/CacheChange.h +++ b/include/fastdds/rtps/common/CacheChange.h @@ -72,7 +72,7 @@ struct CacheChangeReaderInfo_t * Structure CacheChange_t, contains information on a specific CacheChange. * @ingroup COMMON_MODULE */ -struct RTPS_DllAPI CacheChange_t +struct FASTDDS_EXPORTED_API CacheChange_t { //!Kind of change, default value ALIVE. ChangeKind_t kind = ALIVE; diff --git a/include/fastdds/rtps/common/CdrSerialization.hpp b/include/fastdds/rtps/common/CdrSerialization.hpp index 33f30ec5699..0547a46f6d8 100644 --- a/include/fastdds/rtps/common/CdrSerialization.hpp +++ b/include/fastdds/rtps/common/CdrSerialization.hpp @@ -24,7 +24,7 @@ #if FASTCDR_VERSION_MAJOR == 1 #include -#include +#include namespace eprosima { namespace fastcdr { @@ -74,7 +74,7 @@ class CdrSizeCalculator }; template -using fixed_string = eprosima::fastrtps::fixed_string; +using fastcdr::fixed_string = eprosima::fastcdr::fixed_string; } // namespace fastcdr } // namespace eprosima diff --git a/include/fastdds/rtps/common/ChangeKind_t.hpp b/include/fastdds/rtps/common/ChangeKind_t.hpp index 5ffbceb385b..69a500eeb04 100644 --- a/include/fastdds/rtps/common/ChangeKind_t.hpp +++ b/include/fastdds/rtps/common/ChangeKind_t.hpp @@ -19,7 +19,7 @@ #ifndef _FASTDDS_RTPS_COMMON_CHANGEKINDT_HPP_ #define _FASTDDS_RTPS_COMMON_CHANGEKINDT_HPP_ -#include +#include namespace eprosima { namespace fastrtps { @@ -29,7 +29,7 @@ namespace rtps { * @enum ChangeKind_t, different types of CacheChange_t. * @ingroup COMMON_MODULE */ -enum RTPS_DllAPI ChangeKind_t +enum FASTDDS_EXPORTED_API ChangeKind_t { ALIVE, //!< ALIVE NOT_ALIVE_DISPOSED, //!< NOT_ALIVE_DISPOSED diff --git a/include/fastdds/rtps/common/EntityId_t.hpp b/include/fastdds/rtps/common/EntityId_t.hpp index 5a2a5754a68..fbbc675bdde 100644 --- a/include/fastdds/rtps/common/EntityId_t.hpp +++ b/include/fastdds/rtps/common/EntityId_t.hpp @@ -19,7 +19,7 @@ #ifndef _FASTDDS_RTPS_COMMON_ENTITYID_T_HPP_ #define _FASTDDS_RTPS_COMMON_ENTITYID_T_HPP_ -#include +#include #include #include @@ -73,7 +73,7 @@ namespace rtps { //!@brief Structure EntityId_t, entity id part of GUID_t. //!@ingroup COMMON_MODULE -struct RTPS_DllAPI EntityId_t +struct FASTDDS_EXPORTED_API EntityId_t { static constexpr unsigned int size = 4; octet value[size]; diff --git a/include/fastdds/rtps/common/FragmentNumber.h b/include/fastdds/rtps/common/FragmentNumber.h index a1b5d1dcef0..99a90caf5f4 100644 --- a/include/fastdds/rtps/common/FragmentNumber.h +++ b/include/fastdds/rtps/common/FragmentNumber.h @@ -19,17 +19,17 @@ #ifndef _FASTDDS_RTPS_RPTS_ELEM_FRAGNUM_H_ #define _FASTDDS_RTPS_RPTS_ELEM_FRAGNUM_H_ -#include -#include +#include #include +#include #include #include #include -namespace eprosima{ -namespace fastrtps{ -namespace rtps{ +namespace eprosima { +namespace fastrtps { +namespace rtps { using FragmentNumber_t = uint32_t; @@ -37,19 +37,21 @@ using FragmentNumber_t = uint32_t; //!@ingroup COMMON_MODULE using FragmentNumberSet_t = BitmapRange; -inline std::ostream& operator<<(std::ostream& output, const FragmentNumberSet_t& fns) +inline std::ostream& operator <<( + std::ostream& output, + const FragmentNumberSet_t& fns) { output << fns.base() << ":"; fns.for_each([&](FragmentNumber_t it) - { - output << it << "-"; - }); + { + output << it << "-"; + }); return output; } -} -} -} +} // namespace rtps +} // namespace fastrtps +} // namespace eprosima #endif /* _FASTDDS_RTPS_RPTS_ELEM_FRAGNUM_H_ */ diff --git a/include/fastdds/rtps/common/Guid.h b/include/fastdds/rtps/common/Guid.h index b82caac24bc..985466ae1d3 100644 --- a/include/fastdds/rtps/common/Guid.h +++ b/include/fastdds/rtps/common/Guid.h @@ -19,7 +19,7 @@ #ifndef _FASTDDS_RTPS_RTPS_GUID_H_ #define _FASTDDS_RTPS_RTPS_GUID_H_ -#include +#include #include #include #include @@ -36,7 +36,7 @@ struct InstanceHandle_t; //!@brief Structure GUID_t, entity identifier, unique in DDS-RTPS Domain. //!@ingroup COMMON_MODULE -struct RTPS_DllAPI GUID_t +struct FASTDDS_EXPORTED_API GUID_t { //!Guid prefix GuidPrefix_t guidPrefix; diff --git a/include/fastdds/rtps/common/GuidPrefix_t.hpp b/include/fastdds/rtps/common/GuidPrefix_t.hpp index b7a0be73d4e..2174a0c5585 100644 --- a/include/fastdds/rtps/common/GuidPrefix_t.hpp +++ b/include/fastdds/rtps/common/GuidPrefix_t.hpp @@ -19,7 +19,7 @@ #ifndef _FASTDDS_RTPS_COMMON_GUIDPREFIX_T_HPP_ #define _FASTDDS_RTPS_COMMON_GUIDPREFIX_T_HPP_ -#include +#include #include #include @@ -33,7 +33,7 @@ namespace rtps { //!@brief Structure GuidPrefix_t, Guid Prefix of GUID_t. //!@ingroup COMMON_MODULE -struct RTPS_DllAPI GuidPrefix_t +struct FASTDDS_EXPORTED_API GuidPrefix_t { static constexpr unsigned int size = 12; octet value[size]; diff --git a/include/fastdds/rtps/common/InstanceHandle.h b/include/fastdds/rtps/common/InstanceHandle.h index c7dfab81880..0697af118e3 100644 --- a/include/fastdds/rtps/common/InstanceHandle.h +++ b/include/fastdds/rtps/common/InstanceHandle.h @@ -21,7 +21,7 @@ #include -#include +#include #include #include @@ -31,7 +31,7 @@ namespace rtps { using KeyHash_t = std::array; -struct RTPS_DllAPI InstanceHandleValue_t +struct FASTDDS_EXPORTED_API InstanceHandleValue_t { /** * Write access indexing operator. @@ -148,7 +148,7 @@ struct RTPS_DllAPI InstanceHandleValue_t * Struct InstanceHandle_t, used to contain the key for WITH_KEY topics. * @ingroup COMMON_MODULE */ -struct RTPS_DllAPI InstanceHandle_t +struct FASTDDS_EXPORTED_API InstanceHandle_t { //!Value InstanceHandleValue_t value; diff --git a/include/fastdds/rtps/common/Locator.h b/include/fastdds/rtps/common/Locator.h index 3b670d5e797..f19a558f83d 100644 --- a/include/fastdds/rtps/common/Locator.h +++ b/include/fastdds/rtps/common/Locator.h @@ -19,10 +19,10 @@ #ifndef _FASTDDS_RTPS_ELEM_LOCATOR_H_ #define _FASTDDS_RTPS_ELEM_LOCATOR_H_ -#include +#include #include -#include +#include #include @@ -68,7 +68,7 @@ namespace rtps { * For example, an address + port combination in the case of UDP. * @ingroup COMMON_MODULE */ -class RTPS_DllAPI Locator_t +class FASTDDS_EXPORTED_API Locator_t { public: @@ -523,19 +523,4 @@ using Locator = eprosima::fastrtps::rtps::Locator_t; } // namespace fastdds } // namespace eprosima -#include -#include - -namespace eprosima { -namespace fastrtps { -namespace rtps { - -using LocatorsIterator = eprosima::fastdds::rtps::LocatorsIterator; -using Locators = eprosima::fastdds::rtps::Locators; -using LocatorList_t = eprosima::fastdds::rtps::LocatorList; - -} // namespace rtps -} // namespace fastrtps -} // namespace eprosima - #endif /* _FASTDDS_RTPS_ELEM_LOCATOR_H_ */ diff --git a/include/fastdds/rtps/common/LocatorList.hpp b/include/fastdds/rtps/common/LocatorList.hpp index 9801fb9426d..ce28a0c04fe 100644 --- a/include/fastdds/rtps/common/LocatorList.hpp +++ b/include/fastdds/rtps/common/LocatorList.hpp @@ -19,7 +19,7 @@ #ifndef _FASTDDS_RTPS_COMMON_LOCATORLIST_HPP_ #define _FASTDDS_RTPS_COMMON_LOCATORLIST_HPP_ -#include +#include #include #include @@ -99,31 +99,31 @@ class LocatorList using value_type = typename std::vector::value_type; /// Constructor - RTPS_DllAPI LocatorList() + FASTDDS_EXPORTED_API LocatorList() { } /// Destructor - RTPS_DllAPI ~LocatorList() + FASTDDS_EXPORTED_API ~LocatorList() { } /// Copy constructor - RTPS_DllAPI LocatorList( + FASTDDS_EXPORTED_API LocatorList( const LocatorList& list) : m_locators(list.m_locators) { } /// Move constructor - RTPS_DllAPI LocatorList( + FASTDDS_EXPORTED_API LocatorList( LocatorList&& list) : m_locators(std::move(list.m_locators)) { } /// Copy assignment - RTPS_DllAPI LocatorList& operator =( + FASTDDS_EXPORTED_API LocatorList& operator =( const LocatorList& list) { m_locators = list.m_locators; @@ -131,7 +131,7 @@ class LocatorList } /// Move assignment - RTPS_DllAPI LocatorList& operator =( + FASTDDS_EXPORTED_API LocatorList& operator =( LocatorList&& list) { m_locators = std::move(list.m_locators); @@ -139,7 +139,7 @@ class LocatorList } /// Equal to operator - RTPS_DllAPI bool operator ==( + FASTDDS_EXPORTED_API bool operator ==( const LocatorList& locator_list) const { if (locator_list.m_locators.size() == m_locators.size()) @@ -171,7 +171,7 @@ class LocatorList * * @return LocatorListIterator iterator to the first locator. */ - RTPS_DllAPI LocatorListIterator begin() + FASTDDS_EXPORTED_API LocatorListIterator begin() { return m_locators.begin(); } @@ -181,7 +181,7 @@ class LocatorList * * @return LocatorListIterator iterator to the element following the last element. */ - RTPS_DllAPI LocatorListIterator end() + FASTDDS_EXPORTED_API LocatorListIterator end() { return m_locators.end(); } @@ -191,7 +191,7 @@ class LocatorList * * @return LocatorListConstIterator iterator to the first locator. */ - RTPS_DllAPI LocatorListConstIterator begin() const + FASTDDS_EXPORTED_API LocatorListConstIterator begin() const { return m_locators.begin(); } @@ -201,7 +201,7 @@ class LocatorList * * @return LocatorListConstIterator iterator to the element following the last element. */ - RTPS_DllAPI LocatorListConstIterator end() const + FASTDDS_EXPORTED_API LocatorListConstIterator end() const { return m_locators.end(); } @@ -211,7 +211,7 @@ class LocatorList * * @return size_t The number of locators in the container. */ - RTPS_DllAPI size_t size() const + FASTDDS_EXPORTED_API size_t size() const { return m_locators.size(); } @@ -222,7 +222,7 @@ class LocatorList * @param list New content to be saved into the container. * @return LocatorList& reference to the container with the replaced content. */ - RTPS_DllAPI LocatorList& assign( + FASTDDS_EXPORTED_API LocatorList& assign( const LocatorList& list) { if (!(*this == list)) @@ -235,7 +235,7 @@ class LocatorList /** * @brief Erase all locators from the container. */ - RTPS_DllAPI void clear() + FASTDDS_EXPORTED_API void clear() { return m_locators.clear(); } @@ -245,7 +245,7 @@ class LocatorList * * @param num new capacity of the vector, in number of elements. */ - RTPS_DllAPI void reserve( + FASTDDS_EXPORTED_API void reserve( size_t num) { return m_locators.reserve(num); @@ -258,7 +258,7 @@ class LocatorList * * @param num new size of the container. */ - RTPS_DllAPI void resize( + FASTDDS_EXPORTED_API void resize( size_t num) { return m_locators.resize(num); @@ -269,7 +269,7 @@ class LocatorList * * @param loc locator to be appended. */ - RTPS_DllAPI void push_back( + FASTDDS_EXPORTED_API void push_back( const Locator& loc) { bool already = false; @@ -292,7 +292,7 @@ class LocatorList * * @param locList LocatorList with the locators to be appended. */ - RTPS_DllAPI void push_back( + FASTDDS_EXPORTED_API void push_back( const LocatorList& locList) { for (auto it = locList.m_locators.begin(); it != locList.m_locators.end(); ++it) @@ -306,7 +306,7 @@ class LocatorList * * @return true if the container is empty. False otherwise. */ - RTPS_DllAPI bool empty() const + FASTDDS_EXPORTED_API bool empty() const { return m_locators.empty(); } @@ -316,7 +316,7 @@ class LocatorList * * @param loc Locator to be removed. */ - RTPS_DllAPI void erase( + FASTDDS_EXPORTED_API void erase( const Locator& loc) { auto it = std::find(m_locators.begin(), m_locators.end(), loc); @@ -326,38 +326,12 @@ class LocatorList } } - FASTDDS_DEPRECATED_UNTIL(3, "eprosima::fastrtps::rtps::LocatorList::contains(const Locator&)", - "Unused method.") - RTPS_DllAPI bool contains( - const Locator& loc) - { - for (LocatorListIterator it = this->begin(); it != this->end(); ++it) - { - if (IsAddressDefined(*it)) - { - if (loc == *it) - { - return true; - } - } - else - { - if (loc.kind == (*it).kind && loc.port == (*it).port) - { - return true; - } - } - } - - return false; - } - /** * @brief Check that every locator contained in the list is not LOCATOR_KIND_INVALID. * * @return true if all locators are valid. False otherwise. */ - RTPS_DllAPI bool isValid() const + FASTDDS_EXPORTED_API bool isValid() const { for (LocatorListConstIterator it = this->begin(); it != this->end(); ++it) { @@ -374,7 +348,7 @@ class LocatorList * * @param locatorList container to exchange the contents with. */ - RTPS_DllAPI void swap( + FASTDDS_EXPORTED_API void swap( LocatorList& locatorList) { this->m_locators.swap(locatorList.m_locators); @@ -484,6 +458,15 @@ inline std::istream& operator >>( } // namespace rtps } // namespace fastdds + +namespace fastrtps { +namespace rtps { + +using Locators = eprosima::fastdds::rtps::Locators; +using LocatorList_t = eprosima::fastdds::rtps::LocatorList; + +} // namespace rtps +} // namespace fastrtps } // namespace eprosima #endif /* _FASTDDS_RTPS_COMMON_LOCATORLIST_HPP_ */ diff --git a/include/fastdds/rtps/common/LocatorListComparisons.hpp b/include/fastdds/rtps/common/LocatorListComparisons.hpp index baf0456d83f..59591c3400d 100644 --- a/include/fastdds/rtps/common/LocatorListComparisons.hpp +++ b/include/fastdds/rtps/common/LocatorListComparisons.hpp @@ -20,7 +20,7 @@ #define _FASTDDS_RTPS_COMMON_LOCATORLISTCOMPARISONS_HPP_ #include -#include +#include #include namespace eprosima { diff --git a/include/fastdds/rtps/common/LocatorSelector.hpp b/include/fastdds/rtps/common/LocatorSelector.hpp index 399d104d3cc..0ed3418e9bd 100644 --- a/include/fastdds/rtps/common/LocatorSelector.hpp +++ b/include/fastdds/rtps/common/LocatorSelector.hpp @@ -22,8 +22,9 @@ #include #include #include -#include -#include +#include +#include +#include #include diff --git a/include/fastdds/rtps/common/LocatorSelectorEntry.hpp b/include/fastdds/rtps/common/LocatorSelectorEntry.hpp index 75c59df0458..b2b209d6cec 100644 --- a/include/fastdds/rtps/common/LocatorSelectorEntry.hpp +++ b/include/fastdds/rtps/common/LocatorSelectorEntry.hpp @@ -23,7 +23,8 @@ #include #include -#include +#include +#include namespace eprosima { namespace fastrtps { diff --git a/include/fastdds/rtps/common/LocatorWithMask.hpp b/include/fastdds/rtps/common/LocatorWithMask.hpp index cc311c9b7a3..acba981f778 100644 --- a/include/fastdds/rtps/common/LocatorWithMask.hpp +++ b/include/fastdds/rtps/common/LocatorWithMask.hpp @@ -21,8 +21,7 @@ #include -#include - +#include #include namespace eprosima { @@ -32,7 +31,7 @@ namespace rtps { /** * A Locator with a mask that defines the number of significant bits of its address. */ -class RTPS_DllAPI LocatorWithMask : public Locator +class FASTDDS_EXPORTED_API LocatorWithMask : public Locator { public: @@ -70,7 +69,7 @@ class RTPS_DllAPI LocatorWithMask : public Locator uint8_t mask_ = 24; }; -RTPS_DllAPI std::ostream& operator <<( +FASTDDS_EXPORTED_API std::ostream& operator <<( std::ostream& output, const LocatorWithMask& loc); diff --git a/include/fastdds/rtps/common/LocatorsIterator.hpp b/include/fastdds/rtps/common/LocatorsIterator.hpp index b9480237f49..3d880e8db7b 100644 --- a/include/fastdds/rtps/common/LocatorsIterator.hpp +++ b/include/fastdds/rtps/common/LocatorsIterator.hpp @@ -65,6 +65,14 @@ struct LocatorsIterator } // namespace rtps } // namespace fastdds + +namespace fastrtps { +namespace rtps { + +using LocatorsIterator = eprosima::fastdds::rtps::LocatorsIterator; + +} // namespace rtps +} // namespace fastrtps } // namespace eprosima #endif /* _FASTDDS_RTPS_COMMON_LOCATORSITERATOR_HPP_ */ diff --git a/include/fastdds/rtps/common/MatchingInfo.h b/include/fastdds/rtps/common/MatchingInfo.h index f572b44f2b6..50025f870f9 100644 --- a/include/fastdds/rtps/common/MatchingInfo.h +++ b/include/fastdds/rtps/common/MatchingInfo.h @@ -22,9 +22,9 @@ #include -namespace eprosima{ -namespace fastrtps{ -namespace rtps{ +namespace eprosima { +namespace fastrtps { +namespace rtps { /** * @enum MatchingStatus, indicates whether the matched publication/subscription method of the PublisherListener or SubscriberListener has @@ -32,10 +32,12 @@ namespace rtps{ * @ingroup COMMON_MODULE */ #if defined(_WIN32) - enum RTPS_DllAPI MatchingStatus{ +enum FASTDDS_EXPORTED_API MatchingStatus +{ #else - enum MatchingStatus{ -#endif +enum MatchingStatus +{ +#endif // if defined(_WIN32) MATCHED_MATCHING,//!< MATCHED_MATCHING, new publisher/subscriber found REMOVED_MATCHING //!< REMOVED_MATCHING, publisher/subscriber removed @@ -45,24 +47,39 @@ namespace rtps{ * Class MatchingInfo contains information about the matching between two endpoints. * @ingroup COMMON_MODULE */ -class RTPS_DllAPI MatchingInfo +class FASTDDS_EXPORTED_API MatchingInfo { public: + //!Default constructor - MatchingInfo():status(MATCHED_MATCHING){}; + MatchingInfo() + : status(MATCHED_MATCHING) + { + } + /** - * @param stat Status - * @param guid GUID - */ - MatchingInfo(MatchingStatus stat,const GUID_t&guid):status(stat),remoteEndpointGuid(guid){}; - ~MatchingInfo(){}; + * @param stat Status + * @param guid GUID + */ + MatchingInfo( + MatchingStatus stat, + const GUID_t& guid) + : status(stat) + , remoteEndpointGuid(guid) + { + } + + ~MatchingInfo() + { + } + //!Status MatchingStatus status; //!Remote endpoint GUID GUID_t remoteEndpointGuid; }; -} -} -} +} // namespace rtps +} // namespace fastrtps +} // namespace eprosima #endif /* _FASTDDS_RTPS_MATCHINGINFO_H_ */ diff --git a/include/fastdds/rtps/common/RemoteLocators.hpp b/include/fastdds/rtps/common/RemoteLocators.hpp index ea8d9c1c47f..8ef8eeb0058 100644 --- a/include/fastdds/rtps/common/RemoteLocators.hpp +++ b/include/fastdds/rtps/common/RemoteLocators.hpp @@ -20,7 +20,7 @@ #define _FASTDDS_RTPS_COMMON_REMOTELOCATORS_HPP_ #include -#include +#include #include namespace eprosima { diff --git a/include/fastdds/rtps/common/SampleIdentity.h b/include/fastdds/rtps/common/SampleIdentity.h index 2eb763cf187..d5657dcb8b5 100644 --- a/include/fastdds/rtps/common/SampleIdentity.h +++ b/include/fastdds/rtps/common/SampleIdentity.h @@ -30,7 +30,7 @@ namespace rtps { * @brief This class is used to specify a sample * @ingroup COMMON_MODULE */ -class RTPS_DllAPI SampleIdentity +class FASTDDS_EXPORTED_API SampleIdentity { public: diff --git a/include/fastdds/rtps/common/SequenceNumber.h b/include/fastdds/rtps/common/SequenceNumber.h index 90f737a1a56..a529ea0368d 100644 --- a/include/fastdds/rtps/common/SequenceNumber.h +++ b/include/fastdds/rtps/common/SequenceNumber.h @@ -24,9 +24,9 @@ #include #include -#include -#include +#include #include +#include namespace eprosima { namespace fastrtps { @@ -35,7 +35,7 @@ namespace rtps { //!@brief Structure SequenceNumber_t, different for each change in the same writer. //!@ingroup COMMON_MODULE -struct RTPS_DllAPI SequenceNumber_t +struct FASTDDS_EXPORTED_API SequenceNumber_t { //! int32_t high = 0; diff --git a/include/fastdds/rtps/common/SerializedPayload.h b/include/fastdds/rtps/common/SerializedPayload.h index 1125b1318b5..5b9d9e69847 100644 --- a/include/fastdds/rtps/common/SerializedPayload.h +++ b/include/fastdds/rtps/common/SerializedPayload.h @@ -25,7 +25,7 @@ #include #include -#include +#include #include /*! @@ -53,7 +53,7 @@ namespace rtps { //!@brief Structure SerializedPayload_t. //!@ingroup COMMON_MODULE -struct RTPS_DllAPI SerializedPayload_t +struct FASTDDS_EXPORTED_API SerializedPayload_t { //!Size in bytes of the representation header as specified in the RTPS 2.3 specification chapter 10. static constexpr size_t representation_header_size = 4u; diff --git a/include/fastdds/rtps/common/Time_t.h b/include/fastdds/rtps/common/Time_t.h index 16f120fb7bb..24e21f36f29 100644 --- a/include/fastdds/rtps/common/Time_t.h +++ b/include/fastdds/rtps/common/Time_t.h @@ -19,7 +19,7 @@ #ifndef _FASTDDS_RTPS_TIME_T_H_ #define _FASTDDS_RTPS_TIME_T_H_ -#include +#include #include #include @@ -32,7 +32,7 @@ namespace fastrtps { * Structure Time_t, used to describe times. * @ingroup COMMON_MODULE */ -struct RTPS_DllAPI Time_t +struct FASTDDS_EXPORTED_API Time_t { static constexpr int32_t INFINITE_SECONDS = 0x7fffffff; static constexpr uint32_t INFINITE_NANOSECONDS = 0xffffffffu; @@ -96,7 +96,7 @@ namespace rtps { * Structure Time_t, used to describe times at RTPS protocol. * @ingroup COMMON_MODULE */ -class RTPS_DllAPI Time_t +class FASTDDS_EXPORTED_API Time_t { public: diff --git a/include/fastdds/rtps/common/Token.h b/include/fastdds/rtps/common/Token.h index c2787378482..3f4bebc7b37 100644 --- a/include/fastdds/rtps/common/Token.h +++ b/include/fastdds/rtps/common/Token.h @@ -18,7 +18,7 @@ #ifndef _FASTDDS_RTPS_COMMON_TOKEN_H_ #define _FASTDDS_RTPS_COMMON_TOKEN_H_ -#include +#include #include #include @@ -28,90 +28,102 @@ namespace rtps { class DataHolder { - public: - - DataHolder() {} - - DataHolder(const DataHolder& data_holder) : - class_id_(data_holder.class_id_), - properties_(data_holder.properties_), - binary_properties_(data_holder.binary_properties_) {} - - DataHolder(DataHolder&& data_holder) : - class_id_(data_holder.class_id_), - properties_(data_holder.properties_), - binary_properties_(data_holder.binary_properties_) {} - - DataHolder& operator=(const DataHolder& data_holder) - { - class_id_ = data_holder.class_id_; - properties_ = data_holder.properties_; - binary_properties_ = data_holder.binary_properties_; - - return *this; - } - - DataHolder& operator=(DataHolder&& data_holder) - { - class_id_ = std::move(data_holder.class_id_); - properties_ = std::move(data_holder.properties_); - binary_properties_ = std::move(data_holder.binary_properties_); - - return *this; - } - - bool is_nil() const - { - return class_id_.empty(); - } - - void class_id(const std::string& class_id) - { - class_id_ = class_id; - } - - void class_id(std::string&& class_id) - { - class_id_ = std::move(class_id); - } - - std::string& class_id() - { - return class_id_; - } - - const std::string& class_id() const - { - return class_id_; - } - - const PropertySeq& properties() const - { - return properties_; - } - - PropertySeq& properties() - { - return properties_; - } - - const BinaryPropertySeq& binary_properties() const - { - return binary_properties_; - } - - BinaryPropertySeq& binary_properties() - { - return binary_properties_; - } - - private: - - std::string class_id_; - - PropertySeq properties_; - - BinaryPropertySeq binary_properties_; +public: + + DataHolder() + { + } + + DataHolder( + const DataHolder& data_holder) + : class_id_(data_holder.class_id_) + , properties_(data_holder.properties_) + , binary_properties_(data_holder.binary_properties_) + { + } + + DataHolder( + DataHolder&& data_holder) + : class_id_(data_holder.class_id_) + , properties_(data_holder.properties_) + , binary_properties_(data_holder.binary_properties_) + { + } + + DataHolder& operator =( + const DataHolder& data_holder) + { + class_id_ = data_holder.class_id_; + properties_ = data_holder.properties_; + binary_properties_ = data_holder.binary_properties_; + + return *this; + } + + DataHolder& operator =( + DataHolder&& data_holder) + { + class_id_ = std::move(data_holder.class_id_); + properties_ = std::move(data_holder.properties_); + binary_properties_ = std::move(data_holder.binary_properties_); + + return *this; + } + + bool is_nil() const + { + return class_id_.empty(); + } + + void class_id( + const std::string& class_id) + { + class_id_ = class_id; + } + + void class_id( + std::string&& class_id) + { + class_id_ = std::move(class_id); + } + + std::string& class_id() + { + return class_id_; + } + + const std::string& class_id() const + { + return class_id_; + } + + const PropertySeq& properties() const + { + return properties_; + } + + PropertySeq& properties() + { + return properties_; + } + + const BinaryPropertySeq& binary_properties() const + { + return binary_properties_; + } + + BinaryPropertySeq& binary_properties() + { + return binary_properties_; + } + +private: + + std::string class_id_; + + PropertySeq properties_; + + BinaryPropertySeq binary_properties_; }; typedef std::vector DataHolderSeq; @@ -124,31 +136,57 @@ typedef Token PermissionsCredentialToken; class DataHolderHelper { - public: +public: - static std::string* find_property_value(DataHolder& data_holder, const std::string& name); + static std::string* find_property_value( + DataHolder& data_holder, + const std::string& name); - static const std::string* find_property_value(const DataHolder& data_holder, const std::string& name); + static const std::string* find_property_value( + const DataHolder& data_holder, + const std::string& name); - static Property* find_property(DataHolder& data_holder, const std::string& name); + static Property* find_property( + DataHolder& data_holder, + const std::string& name); - static const Property* find_property(const DataHolder& data_holder, const std::string& name); + static const Property* find_property( + const DataHolder& data_holder, + const std::string& name); - static std::vector* find_binary_property_value(DataHolder& data_holder, const std::string& name); + static std::vector* find_binary_property_value( + DataHolder& data_holder, + const std::string& name); - static const std::vector* find_binary_property_value(const DataHolder& data_holder, const std::string& name); + static const std::vector* find_binary_property_value( + const DataHolder& data_holder, + const std::string& name); - static BinaryProperty* find_binary_property(DataHolder& data_holder, const std::string& name); + static BinaryProperty* find_binary_property( + DataHolder& data_holder, + const std::string& name); - static const BinaryProperty* find_binary_property(const DataHolder& data_holder, const std::string& name); + static const BinaryProperty* find_binary_property( + const DataHolder& data_holder, + const std::string& name); - static size_t serialized_size(const DataHolder& data_holder, size_t current_alignment = 0); + static size_t serialized_size( + const DataHolder& data_holder, + size_t current_alignment = 0); - static size_t serialized_size(const DataHolderSeq& data_holders, size_t current_alignment = 0); + static size_t serialized_size( + const DataHolderSeq& data_holders, + size_t current_alignment = 0); - private: +private: + + inline static size_t alignment( + size_t current_alignment, + size_t dataSize) + { + return (dataSize - (current_alignment % dataSize)) & (dataSize - 1); + } - inline static size_t alignment(size_t current_alignment, size_t dataSize) { return (dataSize - (current_alignment % dataSize)) & (dataSize-1);} }; } //namespace rtps diff --git a/include/fastdds/rtps/common/Types.h b/include/fastdds/rtps/common/Types.h index 7219bdd77a6..2834d1d7446 100644 --- a/include/fastdds/rtps/common/Types.h +++ b/include/fastdds/rtps/common/Types.h @@ -24,7 +24,7 @@ #include #include -#include +#include #include @@ -103,7 +103,7 @@ using Count_t = uint32_t; #define BIT(i) (1U << static_cast(i)) //!@brief Structure ProtocolVersion_t, contains the protocol version. -struct RTPS_DllAPI ProtocolVersion_t +struct FASTDDS_EXPORTED_API ProtocolVersion_t { octet m_major; octet m_minor; @@ -163,7 +163,7 @@ const ProtocolVersion_t c_ProtocolVersion_2_3{2, 3}; const ProtocolVersion_t c_ProtocolVersion; //!@brief Structure VendorId_t, specifying the vendor Id of the implementation. -FASTDDS_TODO_BEFORE(3, 0, "Remove eprosima::fastrtps::rtps::VendorId_t usings"); +// FASTDDS_TODO_BEFORE(3, 0, "Remove eprosima::fastrtps::rtps::VendorId_t usings"); using VendorId_t = eprosima::fastdds::rtps::VendorId_t; using eprosima::fastdds::rtps::c_VendorId_Unknown; using eprosima::fastdds::rtps::c_VendorId_eProsima; diff --git a/include/fastdds/rtps/common/WriteParams.h b/include/fastdds/rtps/common/WriteParams.h index be7d2d66ab0..3214da72a48 100644 --- a/include/fastdds/rtps/common/WriteParams.h +++ b/include/fastdds/rtps/common/WriteParams.h @@ -30,7 +30,7 @@ namespace rtps { * * @ingroup COMMON_MODULE */ -class RTPS_DllAPI WriteParams +class FASTDDS_EXPORTED_API WriteParams { public: diff --git a/include/fastdds/rtps/exceptions/Exception.h b/include/fastdds/rtps/exceptions/Exception.h index db0b6ce1716..81eefd68ed7 100644 --- a/include/fastdds/rtps/exceptions/Exception.h +++ b/include/fastdds/rtps/exceptions/Exception.h @@ -15,7 +15,7 @@ #ifndef _FASTDDS_RTPS_EXCEPTIONS_EXCEPTION_H_ #define _FASTDDS_RTPS_EXCEPTIONS_EXCEPTION_H_ -#include +#include #include #include #include @@ -32,77 +32,87 @@ namespace rtps { */ class Exception : public std::exception { - public: - - RTPS_DllAPI Exception(){}; - - /// @brief Default destructor. - virtual RTPS_DllAPI ~Exception() throw(); - - /** - * @brief This function returns the number associated with the system exception. - * @return The number associated with the system exception. - */ - RTPS_DllAPI const int32_t& minor() const; - - /** - * @brief This function sets the number that will be associated with the system exception. - * @param minor The number that will be associated with the system exception. - */ - RTPS_DllAPI void minor(const int32_t &minor); - - /// @brief This function throws the object as exception. - virtual RTPS_DllAPI void raise() const = 0; - - /** - * @brief This function returns the error message. - * @return The error message. - */ - virtual RTPS_DllAPI const char* what() const throw(); - - protected: - - /** - * @brief Default constructor. - */ - RTPS_DllAPI explicit Exception(const char* const& message); - - /** - * @brief Default copy constructor. - * @param ex Exception that will be copied. - */ - RTPS_DllAPI Exception(const Exception &ex); - - /** - * @brief Default move constructor. - * @param ex Exception that will be moved. - */ - RTPS_DllAPI Exception(Exception&& ex); - - /** - * @brief Constructor. - * @param message An error message. This message is copied. - * @param minor The number that will be associated with the system exception. - */ - RTPS_DllAPI explicit Exception(const char* const& message, const int32_t minor); - - /** - * @brief Assigment operation. - * @param ex Exception that will be copied. - */ - RTPS_DllAPI Exception& operator=(const Exception& ex); - - /** - * @brief Assigment operation. - * @param ex Exception that will be moved. - */ - RTPS_DllAPI Exception& operator=(Exception&& ex); - - private: - - std::string message_; - - int32_t minor_; +public: + + FASTDDS_EXPORTED_API Exception() + { + } + + /// @brief Default destructor. + virtual FASTDDS_EXPORTED_API ~Exception() throw(); + + /** + * @brief This function returns the number associated with the system exception. + * @return The number associated with the system exception. + */ + FASTDDS_EXPORTED_API const int32_t& minor() const; + + /** + * @brief This function sets the number that will be associated with the system exception. + * @param minor The number that will be associated with the system exception. + */ + FASTDDS_EXPORTED_API void minor( + const int32_t& minor); + + /// @brief This function throws the object as exception. + virtual FASTDDS_EXPORTED_API void raise() const = 0; + + /** + * @brief This function returns the error message. + * @return The error message. + */ + virtual FASTDDS_EXPORTED_API const char* what() const throw(); + +protected: + + /** + * @brief Default constructor. + */ + FASTDDS_EXPORTED_API explicit Exception( + const char* const& message); + + /** + * @brief Default copy constructor. + * @param ex Exception that will be copied. + */ + FASTDDS_EXPORTED_API Exception( + const Exception& ex); + + /** + * @brief Default move constructor. + * @param ex Exception that will be moved. + */ + FASTDDS_EXPORTED_API Exception( + Exception&& ex); + + /** + * @brief Constructor. + * @param message An error message. This message is copied. + * @param minor The number that will be associated with the system exception. + */ + FASTDDS_EXPORTED_API explicit Exception( + const char* const& message, + const int32_t minor); + + /** + * @brief Assigment operation. + * @param ex Exception that will be copied. + */ + FASTDDS_EXPORTED_API Exception& operator =( + const Exception& ex); + + /** + * @brief Assigment operation. + * @param ex Exception that will be moved. + */ + FASTDDS_EXPORTED_API Exception& operator =( + Exception&& ex); + +private: + + std::string message_; + + int32_t minor_; }; } // namespace rtps diff --git a/include/fastdds/rtps/flowcontrol/FlowControllerConsts.hpp b/include/fastdds/rtps/flowcontrol/FlowControllerConsts.hpp index 88ceb6cb2eb..37bd42941c0 100644 --- a/include/fastdds/rtps/flowcontrol/FlowControllerConsts.hpp +++ b/include/fastdds/rtps/flowcontrol/FlowControllerConsts.hpp @@ -15,16 +15,16 @@ #ifndef FASTDDS_RTPS_FLOWCONTROL_FLOWCONTROLLERCONSTS_HPP #define FASTDDS_RTPS_FLOWCONTROL_FLOWCONTROLLERCONSTS_HPP -#include +#include namespace eprosima { namespace fastdds { namespace rtps { //! Name of the default flow controller. -extern RTPS_DllAPI const char* const FASTDDS_FLOW_CONTROLLER_DEFAULT; +extern FASTDDS_EXPORTED_API const char* const FASTDDS_FLOW_CONTROLLER_DEFAULT; //! Name of the default flow controller for statistics writers. -extern RTPS_DllAPI const char* const FASTDDS_STATISTICS_FLOW_CONTROLLER_DEFAULT; +extern FASTDDS_EXPORTED_API const char* const FASTDDS_STATISTICS_FLOW_CONTROLLER_DEFAULT; } // namespace rtps } // namespace fastdds diff --git a/include/fastdds/rtps/flowcontrol/ThroughputControllerDescriptor.h b/include/fastdds/rtps/flowcontrol/ThroughputControllerDescriptor.h index aa51c077026..cc6ddbaa13e 100644 --- a/include/fastdds/rtps/flowcontrol/ThroughputControllerDescriptor.h +++ b/include/fastdds/rtps/flowcontrol/ThroughputControllerDescriptor.h @@ -15,7 +15,7 @@ #ifndef _FASTDDS_RTPS_THROUGHPUT_CONTROLLER_DESCRIPTOR_H #define _FASTDDS_RTPS_THROUGHPUT_CONTROLLER_DESCRIPTOR_H -#include +#include #include namespace eprosima { @@ -35,8 +35,8 @@ struct ThroughputControllerDescriptor //! Window of time in which no more than 'bytesPerPeriod' bytes are allowed. uint32_t periodMillisecs; - RTPS_DllAPI ThroughputControllerDescriptor(); - RTPS_DllAPI ThroughputControllerDescriptor( + FASTDDS_EXPORTED_API ThroughputControllerDescriptor(); + FASTDDS_EXPORTED_API ThroughputControllerDescriptor( uint32_t size, uint32_t time); diff --git a/include/fastdds/rtps/history/History.h b/include/fastdds/rtps/history/History.h index 2270cc8802d..883d9c701bb 100644 --- a/include/fastdds/rtps/history/History.h +++ b/include/fastdds/rtps/history/History.h @@ -20,15 +20,13 @@ #ifndef _FASTDDS_RTPS_HISTORY_H_ #define _FASTDDS_RTPS_HISTORY_H_ -#include - +#include #include #include - #include #include #include -#include +#include #include #include @@ -64,53 +62,11 @@ class History //!Attributes of the History HistoryAttributes m_att; - /** - * Reserve a CacheChange_t from the CacheChange pool. - * @param[out] change Pointer to pointer to the CacheChange_t to reserve - * @param[in] calculateSizeFunc Function to calculate the size of the payload. - * @return True if reserved - * @warning This method has been deprecated and will be removed on v3.0.0 - */ - FASTRTPS_DEPRECATED("Use new_change on RTPSWriter or reserveCache on RTPSReader") - RTPS_DllAPI inline bool reserve_Cache( - CacheChange_t** change, - const std::function& calculateSizeFunc) - { - return do_reserve_cache(change, calculateSizeFunc()); - } - - /** - * Reserve a CacheChange_t from the CacheChange pool. - * @param[out] change Pointer to pointer to the CacheChange_t to reserve - * @param[in] dataSize Required size for the payload. - * @return True if reserved - * @warning This method has been deprecated and will be removed on v3.0.0 - */ - FASTRTPS_DEPRECATED("Use new_change on RTPSWriter or reserveCache on RTPSReader") - RTPS_DllAPI inline bool reserve_Cache( - CacheChange_t** change, - uint32_t dataSize) - { - return do_reserve_cache(change, dataSize); - } - - /** - * release a previously reserved CacheChange_t. - * @param ch Pointer to the CacheChange_t. - * @warning This method has been deprecated and will be removed on v3.0.0 - */ - FASTRTPS_DEPRECATED("Use release_change on RTPSWriter or releaseCache on RTPSReader") - RTPS_DllAPI inline void release_Cache( - CacheChange_t* ch) - { - do_release_cache(ch); - } - /** * Check if the history is full * @return true if the History is full. */ - RTPS_DllAPI bool isFull() + FASTDDS_EXPORTED_API bool isFull() { return m_isHistoryFull; } @@ -119,7 +75,7 @@ class History * Get the History size. * @return Size of the history. */ - RTPS_DllAPI size_t getHistorySize() + FASTDDS_EXPORTED_API size_t getHistorySize() { std::lock_guard guard(*mp_mutex); return m_changes.size(); @@ -131,7 +87,7 @@ class History * @param ch Pointer to the CacheChange_t to search for. * @return an iterator if a suitable change is found */ - RTPS_DllAPI const_iterator find_change_nts( + FASTDDS_EXPORTED_API const_iterator find_change_nts( CacheChange_t* ch); /** @@ -141,7 +97,7 @@ class History * @param release defaults to true and hints if the CacheChange_t should return to the pool * @return iterator to the next CacheChange_t or end iterator. */ - RTPS_DllAPI virtual iterator remove_change_nts( + FASTDDS_EXPORTED_API virtual iterator remove_change_nts( const_iterator removal, bool release = true); @@ -153,7 +109,7 @@ class History * @param release defaults to true and hints if the CacheChange_t should return to the pool * @return iterator to the next CacheChange_t or end iterator. */ - RTPS_DllAPI virtual iterator remove_change_nts( + FASTDDS_EXPORTED_API virtual iterator remove_change_nts( const_iterator removal, const std::chrono::time_point& max_blocking_time, bool release = true); @@ -162,14 +118,14 @@ class History * Remove all changes from the History * @return True if everything was correctly removed. */ - RTPS_DllAPI bool remove_all_changes(); + FASTDDS_EXPORTED_API bool remove_all_changes(); /** * Remove a specific change from the history. * @param ch Pointer to the CacheChange_t. * @return True if removed. */ - RTPS_DllAPI bool remove_change( + FASTDDS_EXPORTED_API bool remove_change( CacheChange_t* ch); /** @@ -178,7 +134,7 @@ class History * @param[in] max_blocking_time Maximum time this method has to complete the task. * @return True if removed. */ - RTPS_DllAPI bool remove_change( + FASTDDS_EXPORTED_API bool remove_change( CacheChange_t* ch, const std::chrono::time_point& max_blocking_time); @@ -187,7 +143,7 @@ class History * @param ch Pointer to the CacheChange_t to search for. * @return an iterator if a suitable change is found */ - RTPS_DllAPI const_iterator find_change( + FASTDDS_EXPORTED_API const_iterator find_change( CacheChange_t* ch) { std::lock_guard guard(*mp_mutex); @@ -201,7 +157,7 @@ class History * @param ch_outer Pointer to the CacheChange_t to identify. * @return true if the iterator identifies this change. */ - RTPS_DllAPI virtual bool matches_change( + FASTDDS_EXPORTED_API virtual bool matches_change( const CacheChange_t* ch_inner, CacheChange_t* ch_outer); @@ -211,7 +167,7 @@ class History * @param release defaults to true and hints if the CacheChange_t should return to the pool * @return iterator to the next CacheChange_t or end iterator. */ - RTPS_DllAPI iterator remove_change( + FASTDDS_EXPORTED_API iterator remove_change( const_iterator removal, bool release = true) { @@ -223,12 +179,12 @@ class History * Get the beginning of the changes history iterator. * @return Iterator to the beginning of the vector. */ - RTPS_DllAPI iterator changesBegin() + FASTDDS_EXPORTED_API iterator changesBegin() { return m_changes.begin(); } - RTPS_DllAPI reverse_iterator changesRbegin() + FASTDDS_EXPORTED_API reverse_iterator changesRbegin() { return m_changes.rbegin(); } @@ -237,12 +193,12 @@ class History * Get the end of the changes history iterator. * @return Iterator to the end of the vector. */ - RTPS_DllAPI iterator changesEnd() + FASTDDS_EXPORTED_API iterator changesEnd() { return m_changes.end(); } - RTPS_DllAPI reverse_iterator changesRend() + FASTDDS_EXPORTED_API reverse_iterator changesRend() { return m_changes.rend(); } @@ -252,7 +208,7 @@ class History * @param min_change Pointer to pointer to the minimum change. * @return True if correct. */ - RTPS_DllAPI bool get_min_change( + FASTDDS_EXPORTED_API bool get_min_change( CacheChange_t** min_change); /** @@ -260,14 +216,14 @@ class History * @param max_change Pointer to pointer to the maximum change. * @return True if correct. */ - RTPS_DllAPI bool get_max_change( + FASTDDS_EXPORTED_API bool get_max_change( CacheChange_t** max_change); /** * Get the maximum serialized payload size * @return Maximum serialized payload size */ - RTPS_DllAPI inline uint32_t getTypeMaxSerialized() + FASTDDS_EXPORTED_API inline uint32_t getTypeMaxSerialized() { return m_att.payloadMaxSize; } @@ -276,13 +232,13 @@ class History * Get the mutex * @return Mutex */ - RTPS_DllAPI inline RecursiveTimedMutex* getMutex() const + FASTDDS_EXPORTED_API inline RecursiveTimedMutex* getMutex() const { assert(mp_mutex != nullptr); return mp_mutex; } - RTPS_DllAPI bool get_change( + FASTDDS_EXPORTED_API bool get_change( const SequenceNumber_t& seq, const GUID_t& guid, CacheChange_t** change) const; @@ -315,11 +271,11 @@ class History //!Print the seqNum of the changes in the History (for debuggisi, mng purposes). void print_changes_seqNum2(); - RTPS_DllAPI virtual bool do_reserve_cache( + FASTDDS_EXPORTED_API virtual bool do_reserve_cache( CacheChange_t** change, uint32_t size) = 0; - RTPS_DllAPI virtual void do_release_cache( + FASTDDS_EXPORTED_API virtual void do_release_cache( CacheChange_t* ch) = 0; /** diff --git a/include/fastdds/rtps/history/ReaderHistory.h b/include/fastdds/rtps/history/ReaderHistory.h index 0625915264f..7ec05496277 100644 --- a/include/fastdds/rtps/history/ReaderHistory.h +++ b/include/fastdds/rtps/history/ReaderHistory.h @@ -49,9 +49,9 @@ class ReaderHistory : public History /** * Constructor of the ReaderHistory. It needs a HistoryAttributes. */ - RTPS_DllAPI ReaderHistory( + FASTDDS_EXPORTED_API ReaderHistory( const HistoryAttributes& att); - RTPS_DllAPI ~ReaderHistory() override; + FASTDDS_EXPORTED_API ~ReaderHistory() override; /** * Check if a new change can be added to this history. @@ -67,7 +67,7 @@ class ReaderHistory : public History * * @return Whether a call to received_change will succeed when called with the same arguments. */ - RTPS_DllAPI virtual bool can_change_be_added_nts( + FASTDDS_EXPORTED_API virtual bool can_change_be_added_nts( const GUID_t& writer_guid, uint32_t total_payload_size, size_t unknown_missing_changes_up_to, @@ -82,7 +82,7 @@ class ReaderHistory : public History * could potentially be received in the future. * @return True if added. */ - RTPS_DllAPI virtual bool received_change( + FASTDDS_EXPORTED_API virtual bool received_change( CacheChange_t* change, size_t unknown_missing_changes_up_to); @@ -96,7 +96,7 @@ class ReaderHistory : public History * @param[out] rejection_reason In case of been rejected the sample, it will contain the reason of the rejection. * @return True if added. */ - RTPS_DllAPI virtual bool received_change( + FASTDDS_EXPORTED_API virtual bool received_change( CacheChange_t* change, size_t unknown_missing_changes_up_to, fastdds::dds::SampleRejectedStatusKind& rejection_reason) @@ -111,7 +111,7 @@ class ReaderHistory : public History * @param[in] change The received change * @return */ - RTPS_DllAPI bool virtual completed_change( + FASTDDS_EXPORTED_API bool virtual completed_change( rtps::CacheChange_t* change) { (void)change; @@ -126,7 +126,7 @@ class ReaderHistory : public History * @param[out] rejection_reason In case of been rejected the sample, it will contain the reason of the rejection. * @return */ - RTPS_DllAPI virtual bool completed_change( + FASTDDS_EXPORTED_API virtual bool completed_change( CacheChange_t* change, size_t unknown_missing_changes_up_to, fastdds::dds::SampleRejectedStatusKind& rejection_reason) @@ -142,7 +142,7 @@ class ReaderHistory : public History * @param a_change Pointer to the CacheChange to add. * @return True if added. */ - RTPS_DllAPI bool add_change( + FASTDDS_EXPORTED_API bool add_change( CacheChange_t* a_change); /** @@ -152,7 +152,7 @@ class ReaderHistory : public History * @param release specifies if the change must be returned to the pool * @return iterator to the next change if any */ - RTPS_DllAPI iterator remove_change_nts( + FASTDDS_EXPORTED_API iterator remove_change_nts( const_iterator removal, bool release = true) override; @@ -164,7 +164,7 @@ class ReaderHistory : public History * @param release specifies if the change must be returned to the pool * @return iterator to the next change if any */ - RTPS_DllAPI iterator remove_change_nts( + FASTDDS_EXPORTED_API iterator remove_change_nts( const_iterator removal, const std::chrono::time_point& max_blocking_time, bool release = true) override; @@ -175,7 +175,7 @@ class ReaderHistory : public History * @param outer change for comparison * @return true if inner matches outer criteria */ - RTPS_DllAPI bool matches_change( + FASTDDS_EXPORTED_API bool matches_change( const CacheChange_t* inner, CacheChange_t* outer) override; @@ -187,7 +187,7 @@ class ReaderHistory : public History * @param a_guid Pointer to the target guid to search for. * @return True if successful, even if no changes have been removed. * */ - RTPS_DllAPI bool remove_changes_with_guid( + FASTDDS_EXPORTED_API bool remove_changes_with_guid( const GUID_t& a_guid); /** @@ -200,7 +200,7 @@ class ReaderHistory : public History const SequenceNumber_t& seq_num, const GUID_t& writer_guid); - RTPS_DllAPI bool get_min_change_from( + FASTDDS_EXPORTED_API bool get_min_change_from( CacheChange_t** min_change, const GUID_t& writerGuid); @@ -213,7 +213,7 @@ class ReaderHistory : public History * @param writer_guid GUID of the writer being unmatched. * @param last_notified_seq Last sequence number from the specified writer that was notified to the user. */ - RTPS_DllAPI virtual void writer_unmatched( + FASTDDS_EXPORTED_API virtual void writer_unmatched( const GUID_t& writer_guid, const SequenceNumber_t& last_notified_seq); @@ -223,7 +223,7 @@ class ReaderHistory : public History * @param[in] writer_guid Guid of the writer which changes its ownership strength. * @param[out] ownership_strength New value of the writer's Ownership strength. */ - RTPS_DllAPI virtual void writer_update_its_ownership_strength_nts( + FASTDDS_EXPORTED_API virtual void writer_update_its_ownership_strength_nts( const GUID_t& writer_guid, const uint32_t ownership_strength) { @@ -233,11 +233,11 @@ class ReaderHistory : public History protected: - RTPS_DllAPI bool do_reserve_cache( + FASTDDS_EXPORTED_API bool do_reserve_cache( CacheChange_t** change, uint32_t size) override; - RTPS_DllAPI void do_release_cache( + FASTDDS_EXPORTED_API void do_release_cache( CacheChange_t* ch) override; template diff --git a/include/fastdds/rtps/history/WriterHistory.h b/include/fastdds/rtps/history/WriterHistory.h index 74423a7f05b..031035fe255 100644 --- a/include/fastdds/rtps/history/WriterHistory.h +++ b/include/fastdds/rtps/history/WriterHistory.h @@ -50,16 +50,16 @@ class WriterHistory : public rtps::History /** * Constructor of the WriterHistory. */ - RTPS_DllAPI WriterHistory( + FASTDDS_EXPORTED_API WriterHistory( const HistoryAttributes& att); - RTPS_DllAPI virtual ~WriterHistory() override; + FASTDDS_EXPORTED_API virtual ~WriterHistory() override; /** * Add a CacheChange_t to the WriterHistory. * @param a_change Pointer to the CacheChange_t to be added. * @return True if added. */ - RTPS_DllAPI bool add_change( + FASTDDS_EXPORTED_API bool add_change( CacheChange_t* a_change); /** @@ -68,7 +68,7 @@ class WriterHistory : public rtps::History * @param wparams Extra write parameters. * @return True if added. */ - RTPS_DllAPI bool add_change( + FASTDDS_EXPORTED_API bool add_change( CacheChange_t* a_change, WriteParams& wparams); @@ -79,7 +79,7 @@ class WriterHistory : public rtps::History * @param release specifies if the change should be return to the pool * @return iterator to the next change if any */ - RTPS_DllAPI iterator remove_change_nts( + FASTDDS_EXPORTED_API iterator remove_change_nts( const_iterator removal, bool release = true) override; @@ -91,7 +91,7 @@ class WriterHistory : public rtps::History * @param[in] max_blocking_time Maximum time this method has to complete the task. * @return iterator to the next change if any */ - RTPS_DllAPI iterator remove_change_nts( + FASTDDS_EXPORTED_API iterator remove_change_nts( const_iterator removal, const std::chrono::time_point& max_blocking_time, bool release = true) override; @@ -102,52 +102,52 @@ class WriterHistory : public rtps::History * @param outer change for comparison * @return true if inner matches outer criteria */ - RTPS_DllAPI bool matches_change( + FASTDDS_EXPORTED_API bool matches_change( const CacheChange_t* inner, CacheChange_t* outer) override; //! Introduce base class method into scope using History::remove_change; - RTPS_DllAPI virtual bool remove_change_g( + FASTDDS_EXPORTED_API virtual bool remove_change_g( CacheChange_t* a_change); - RTPS_DllAPI virtual bool remove_change_g( + FASTDDS_EXPORTED_API virtual bool remove_change_g( CacheChange_t* a_change, const std::chrono::time_point& max_blocking_time); - RTPS_DllAPI bool remove_change( + FASTDDS_EXPORTED_API bool remove_change( const SequenceNumber_t& sequence_number); - RTPS_DllAPI CacheChange_t* remove_change_and_reuse( + FASTDDS_EXPORTED_API CacheChange_t* remove_change_and_reuse( const SequenceNumber_t& sequence_number); /** * Remove the CacheChange_t with the minimum sequenceNumber. * @return True if correctly removed. */ - RTPS_DllAPI bool remove_min_change(); + FASTDDS_EXPORTED_API bool remove_min_change(); /** * Remove the CacheChange_t with the minimum sequenceNumber. * @param[in] max_blocking_time Maximum time this method has to complete the task. * @return True if correctly removed. */ - RTPS_DllAPI bool remove_min_change( + FASTDDS_EXPORTED_API bool remove_min_change( const std::chrono::time_point& max_blocking_time); - RTPS_DllAPI SequenceNumber_t next_sequence_number() const + FASTDDS_EXPORTED_API SequenceNumber_t next_sequence_number() const { return m_lastCacheChangeSeqNum + 1; } protected: - RTPS_DllAPI bool do_reserve_cache( + FASTDDS_EXPORTED_API bool do_reserve_cache( CacheChange_t** change, uint32_t size) override; - RTPS_DllAPI void do_release_cache( + FASTDDS_EXPORTED_API void do_release_cache( CacheChange_t* ch) override; /** diff --git a/include/fastdds/rtps/messages/CDRMessage.h b/include/fastdds/rtps/messages/CDRMessage.h index cb6e73b3db3..d5fb563e08e 100644 --- a/include/fastdds/rtps/messages/CDRMessage.h +++ b/include/fastdds/rtps/messages/CDRMessage.h @@ -20,6 +20,8 @@ #define _FASTDDS_RTPS_CDRMESSAGE_H_ #ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC +#include + #include #include #include @@ -28,7 +30,6 @@ #include #include #include -#include #include @@ -124,7 +125,7 @@ inline bool readString( inline bool readString( CDRMessage_t* msg, - string_255* stri); + fastcdr::string_255* stri); inline bool readOctetVector( CDRMessage_t* msg, @@ -281,7 +282,7 @@ inline bool add_string( inline bool add_string( CDRMessage_t* msg, - const string_255& in_str); + const fastcdr::string_255& in_str); inline bool addOctetVector( CDRMessage_t* msg, diff --git a/include/fastdds/rtps/messages/CDRMessage.hpp b/include/fastdds/rtps/messages/CDRMessage.hpp index 4618dc361cb..414ec888f44 100644 --- a/include/fastdds/rtps/messages/CDRMessage.hpp +++ b/include/fastdds/rtps/messages/CDRMessage.hpp @@ -449,7 +449,7 @@ inline bool CDRMessage::readString( inline bool CDRMessage::readString( CDRMessage_t* msg, - string_255* stri) + fastcdr::string_255* stri) { uint32_t str_size = 1; bool valid = true; @@ -738,7 +738,7 @@ inline bool CDRMessage::add_string( inline bool CDRMessage::add_string( CDRMessage_t* msg, - const string_255& in_str) + const fastcdr::string_255& in_str) { return add_string(msg, in_str.c_str()); } diff --git a/include/fastdds/rtps/participant/ParticipantDiscoveryInfo.h b/include/fastdds/rtps/participant/ParticipantDiscoveryInfo.h index ef0acb9752e..0e91d7f1388 100644 --- a/include/fastdds/rtps/participant/ParticipantDiscoveryInfo.h +++ b/include/fastdds/rtps/participant/ParticipantDiscoveryInfo.h @@ -20,7 +20,7 @@ #ifndef _FASTDDS_RTPS_PARTICIPANT_PARTICIPANTDISCOVERYINFO_H__ #define _FASTDDS_RTPS_PARTICIPANT_PARTICIPANTDISCOVERYINFO_H__ -#include +#include #include namespace eprosima { @@ -36,7 +36,7 @@ struct ParticipantDiscoveryInfo //!Enum DISCOVERY_STATUS, four different status for discovered participants. //!@ingroup RTPS_MODULE #if defined(_WIN32) - enum RTPS_DllAPI DISCOVERY_STATUS + enum FASTDDS_EXPORTED_API DISCOVERY_STATUS #else enum DISCOVERY_STATUS #endif // if defined(_WIN32) @@ -74,7 +74,7 @@ struct ParticipantDiscoveryInfo #if HAVE_SECURITY struct ParticipantAuthenticationInfo { - enum RTPS_DllAPI AUTHENTICATION_STATUS + enum FASTDDS_EXPORTED_API AUTHENTICATION_STATUS { AUTHORIZED_PARTICIPANT, UNAUTHORIZED_PARTICIPANT diff --git a/include/fastdds/rtps/participant/RTPSParticipant.h b/include/fastdds/rtps/participant/RTPSParticipant.h index 1b3a19abd56..df880e79b89 100644 --- a/include/fastdds/rtps/participant/RTPSParticipant.h +++ b/include/fastdds/rtps/participant/RTPSParticipant.h @@ -23,23 +23,23 @@ #include #include -#include +#include +#include #include #include +#include #include -#include -#include -#include +#include namespace eprosima { -namespace fastdds { - #ifdef FASTDDS_STATISTICS +namespace fastdds { namespace statistics { class MonitorServiceStatusData; + namespace rtps { struct IStatusQueryable; @@ -47,18 +47,10 @@ struct IStatusObserver; } // namespace rtps } // namespace statistics +} // namespace fastdds #endif //FASTDDS_STATISTICS -namespace dds { -namespace builtin { - -class TypeLookupManager; - -} // namespace builtin -} // namespace dds -} // namespace fastdds - namespace fastrtps { class TopicAttributes; @@ -81,7 +73,7 @@ class WLP; * @brief Class RTPSParticipant, contains the public API for a RTPSParticipant. * @ingroup RTPS_MODULE */ -class RTPS_DllAPI RTPSParticipant +class FASTDDS_EXPORTED_API RTPSParticipant { friend class RTPSParticipantImpl; friend class RTPSDomain; @@ -155,7 +147,7 @@ class RTPS_DllAPI RTPSParticipant bool registerWriter( RTPSWriter* Writer, const TopicAttributes& topicAtt, - const WriterQos& wqos); + const fastdds::dds::WriterQos& wqos); /** * Register a RTPSReader in the builtin Protocols. @@ -168,7 +160,7 @@ class RTPS_DllAPI RTPSParticipant bool registerReader( RTPSReader* Reader, const TopicAttributes& topicAtt, - const ReaderQos& rqos, + const fastdds::dds::ReaderQos& rqos, const fastdds::rtps::ContentFilterProperty* content_filter = nullptr); /** @@ -188,7 +180,7 @@ class RTPS_DllAPI RTPSParticipant bool updateWriter( RTPSWriter* Writer, const TopicAttributes& topicAtt, - const WriterQos& wqos); + const fastdds::dds::WriterQos& wqos); /** * Update reader QOS @@ -201,7 +193,7 @@ class RTPS_DllAPI RTPSParticipant bool updateReader( RTPSReader* Reader, const TopicAttributes& topicAtt, - const ReaderQos& rqos, + const fastdds::dds::ReaderQos& rqos, const fastdds::rtps::ContentFilterProperty* content_filter = nullptr); /** @@ -249,12 +241,6 @@ class RTPS_DllAPI RTPSParticipant void set_check_type_function( std::function&& check_type); - /** - * @brief Retrieves the built-in typelookup service manager. - * @return - */ - fastdds::dds::builtin::TypeLookupManager* typelookup_manager() const; - /** * @brief Modifies the participant listener * @param listener diff --git a/include/fastdds/rtps/participant/RTPSParticipantListener.h b/include/fastdds/rtps/participant/RTPSParticipantListener.h index deb8f7234ee..0e7406261e3 100644 --- a/include/fastdds/rtps/participant/RTPSParticipantListener.h +++ b/include/fastdds/rtps/participant/RTPSParticipantListener.h @@ -24,10 +24,6 @@ #include #include -#include -#include -#include - namespace eprosima { namespace fastrtps { namespace rtps { @@ -38,7 +34,7 @@ class RTPSParticipant; * Class RTPSParticipantListener with virtual method that the user can overload to respond to certain events. * @ingroup RTPS_MODULE */ -class RTPS_DllAPI RTPSParticipantListener +class FASTDDS_EXPORTED_API RTPSParticipantListener { public: @@ -159,63 +155,6 @@ class RTPS_DllAPI RTPSParticipantListener static_cast(should_be_ignored); } - /*! - * This method is called when a participant discovers a new Type - * The ownership of all object belongs to the caller so if needs to be used after the - * method ends, a full copy should be perform (except for dyn_type due to its shared_ptr nature. - * The field "topic" it is only available if the type was discovered using "Discovery-Time Data Typing", - * in which case the field request_sample_id will contain INVALID_SAMPLE_IDENTITY. - * If the type was discovered using TypeLookup Service then "topic" will be empty, but will have - * the request_sample_id of the petition that caused the discovery. - * For example: - * fastrtps::types::TypeIdentifier new_type_id = *identifier; - */ - virtual void on_type_discovery( - RTPSParticipant* participant, - const SampleIdentity& request_sample_id, - const string_255& topic, - const types::TypeIdentifier* identifier, - const types::TypeObject* object, - types::DynamicType_ptr dyn_type) - { - static_cast(participant); - static_cast(request_sample_id); - static_cast(topic); - static_cast(identifier); - static_cast(object); - static_cast(dyn_type); - } - - /*! - * This method is called when the typelookup client received a reply to a getTypeDependencies request. - * The user may want to retrieve these new types using the getTypes request and create a new - * DynamicType using the retrieved TypeObject. - */ - virtual void on_type_dependencies_reply( - RTPSParticipant* participant, - const SampleIdentity& request_sample_id, - const types::TypeIdentifierWithSizeSeq& dependencies) - { - static_cast(participant); - static_cast(request_sample_id); - static_cast(dependencies); - } - - /*! - * This method is called when a participant receives a TypeInformation while discovering another participant. - */ - virtual void on_type_information_received( - RTPSParticipant* participant, - const string_255& topic_name, - const string_255& type_name, - const types::TypeInformation& type_information) - { - static_cast(participant); - static_cast(topic_name); - static_cast(type_name); - static_cast(type_information); - } - }; } // namespace rtps diff --git a/include/fastdds/rtps/reader/RTPSReader.h b/include/fastdds/rtps/reader/RTPSReader.h index 6db4528e617..0a6de1de600 100644 --- a/include/fastdds/rtps/reader/RTPSReader.h +++ b/include/fastdds/rtps/reader/RTPSReader.h @@ -21,6 +21,7 @@ #include +#include #include #include #include @@ -31,8 +32,7 @@ #include #include #include -#include -#include +#include namespace eprosima { namespace fastrtps { @@ -96,7 +96,7 @@ class RTPSReader * @param wdata Attributes of the writer to add. * @return True if correctly added. */ - RTPS_DllAPI virtual bool matched_writer_add( + FASTDDS_EXPORTED_API virtual bool matched_writer_add( const WriterProxyData& wdata) = 0; /** @@ -105,7 +105,7 @@ class RTPSReader * @param removed_by_lease Whether the writer is being unmatched due to a participant drop. * @return True if correctly removed. */ - RTPS_DllAPI virtual bool matched_writer_remove( + FASTDDS_EXPORTED_API virtual bool matched_writer_remove( const GUID_t& writer_guid, bool removed_by_lease = false) = 0; @@ -114,7 +114,7 @@ class RTPSReader * @param writer_guid GUID of the writer to check. * @return True if it is matched. */ - RTPS_DllAPI virtual bool matched_writer_is_matched( + FASTDDS_EXPORTED_API virtual bool matched_writer_is_matched( const GUID_t& writer_guid) = 0; /** @@ -123,7 +123,7 @@ class RTPSReader * @param change Pointer to the CacheChange_t. * @return true if the reader accepts messages from the. */ - RTPS_DllAPI virtual bool processDataMsg( + FASTDDS_EXPORTED_API virtual bool processDataMsg( CacheChange_t* change) = 0; /** @@ -135,7 +135,7 @@ class RTPSReader * @param fragmentsInSubmessage Number of fragments on this particular message. * @return true if the reader accepts message. */ - RTPS_DllAPI virtual bool processDataFragMsg( + FASTDDS_EXPORTED_API virtual bool processDataFragMsg( CacheChange_t* change, uint32_t sampleSize, uint32_t fragmentStartingNum, @@ -152,7 +152,7 @@ class RTPSReader * @param origin_vendor_id * @return true if the reader accepts messages from the. */ - RTPS_DllAPI virtual bool processHeartbeatMsg( + FASTDDS_EXPORTED_API virtual bool processHeartbeatMsg( const GUID_t& writerGUID, uint32_t hbCount, const SequenceNumber_t& firstSN, @@ -169,7 +169,7 @@ class RTPSReader * @param origin_vendor_id * @return true if the reader accepts messages from the. */ - RTPS_DllAPI virtual bool processGapMsg( + FASTDDS_EXPORTED_API virtual bool processGapMsg( const GUID_t& writerGUID, const SequenceNumber_t& gapStart, const SequenceNumberSet_t& gapList, @@ -181,7 +181,7 @@ class RTPSReader * @param prox Pointer to the WriterProxy. * @return True if correctly removed. */ - RTPS_DllAPI virtual bool change_removed_by_history( + FASTDDS_EXPORTED_API virtual bool change_removed_by_history( CacheChange_t* change, WriterProxy* prox = nullptr) = 0; @@ -189,7 +189,7 @@ class RTPSReader * Get the associated listener, secondary attached Listener in case it is of compound type * @return Pointer to the associated reader listener. */ - RTPS_DllAPI ReaderListener* getListener() const; + FASTDDS_EXPORTED_API ReaderListener* getListener() const; /** * Switch the ReaderListener kind for the Reader. @@ -199,7 +199,7 @@ class RTPSReader * @param target Pointed to ReaderLister to attach * @return True is correctly set. */ - RTPS_DllAPI bool setListener( + FASTDDS_EXPORTED_API bool setListener( ReaderListener* target); /** @@ -208,14 +208,14 @@ class RTPSReader * @param dataCdrSerializedSize Size of the Cache. * @return True if correctly reserved. */ - RTPS_DllAPI bool reserveCache( + FASTDDS_EXPORTED_API bool reserveCache( CacheChange_t** change, uint32_t dataCdrSerializedSize); /** * Release a cacheChange. */ - RTPS_DllAPI void releaseCache( + FASTDDS_EXPORTED_API void releaseCache( CacheChange_t* change); /** @@ -224,7 +224,7 @@ class RTPSReader * @param wp Pointer to pointer to the WriterProxy * @return True if read. */ - RTPS_DllAPI virtual bool nextUnreadCache( + FASTDDS_EXPORTED_API virtual bool nextUnreadCache( CacheChange_t** change, WriterProxy** wp) = 0; @@ -234,34 +234,34 @@ class RTPSReader * @param wp Pointer to pointer to the WriterProxy. * @return True if read. */ - RTPS_DllAPI virtual bool nextUntakenCache( + FASTDDS_EXPORTED_API virtual bool nextUntakenCache( CacheChange_t** change, WriterProxy** wp) = 0; - RTPS_DllAPI bool wait_for_unread_cache( + FASTDDS_EXPORTED_API bool wait_for_unread_cache( const eprosima::fastrtps::Duration_t& timeout); - RTPS_DllAPI uint64_t get_unread_count() const; + FASTDDS_EXPORTED_API uint64_t get_unread_count() const; - RTPS_DllAPI uint64_t get_unread_count( + FASTDDS_EXPORTED_API uint64_t get_unread_count( bool mark_as_read); /** * @return True if the reader expects Inline QOS. */ - RTPS_DllAPI inline bool expectsInlineQos() + FASTDDS_EXPORTED_API inline bool expectsInlineQos() { return m_expectsInlineQos; } //! Returns a pointer to the associated History. - RTPS_DllAPI inline ReaderHistory* getHistory() + FASTDDS_EXPORTED_API inline ReaderHistory* getHistory() { return mp_history; } //! @return The content filter associated to this reader. - RTPS_DllAPI eprosima::fastdds::rtps::IReaderDataFilter* get_content_filter() const + FASTDDS_EXPORTED_API eprosima::fastdds::rtps::IReaderDataFilter* get_content_filter() const { std::lock_guard guard(mp_mutex); return data_filter_; @@ -269,7 +269,7 @@ class RTPSReader //! Set the content filter associated to this reader. //! @param filter Pointer to the content filter to associate to this reader. - RTPS_DllAPI void set_content_filter( + FASTDDS_EXPORTED_API void set_content_filter( eprosima::fastdds::rtps::IReaderDataFilter* filter) { std::lock_guard guard(mp_mutex); @@ -285,7 +285,7 @@ class RTPSReader virtual bool isInCleanState() = 0; //! The liveliness changed status struct as defined in the DDS - LivelinessChangedStatus liveliness_changed_status_; + fastdds::dds::LivelinessChangedStatus liveliness_changed_status_; inline void enableMessagesFromUnkownWriters( bool enable) @@ -354,7 +354,7 @@ class RTPSReader * * @return true if the sample is valid */ - RTPS_DllAPI bool is_sample_valid( + FASTDDS_EXPORTED_API bool is_sample_valid( const void* data, const GUID_t& writer, const SequenceNumber_t& sn) const; @@ -371,7 +371,7 @@ class RTPSReader * @param listener * @return true if successfully added */ - RTPS_DllAPI bool add_statistics_listener( + FASTDDS_EXPORTED_API bool add_statistics_listener( std::shared_ptr listener); /** @@ -379,7 +379,7 @@ class RTPSReader * @param listener * @return true if successfully removed */ - RTPS_DllAPI bool remove_statistics_listener( + FASTDDS_EXPORTED_API bool remove_statistics_listener( std::shared_ptr listener); /** @@ -387,7 +387,7 @@ class RTPSReader * * @param enabled_writers The new mask to set */ - RTPS_DllAPI void set_enabled_statistics_writers_mask( + FASTDDS_EXPORTED_API void set_enabled_statistics_writers_mask( uint32_t enabled_writers); /** @@ -396,7 +396,7 @@ class RTPSReader * @param [out] connection_list of the reader * @return True if could be retrieved */ - RTPS_DllAPI virtual bool get_connections( + FASTDDS_EXPORTED_API virtual bool get_connections( fastdds::statistics::rtps::ConnectionList& connection_list) = 0; #endif // FASTDDS_STATISTICS diff --git a/include/fastdds/rtps/reader/ReaderDiscoveryInfo.h b/include/fastdds/rtps/reader/ReaderDiscoveryInfo.h index b71fd8c217b..6fc5f52d359 100644 --- a/include/fastdds/rtps/reader/ReaderDiscoveryInfo.h +++ b/include/fastdds/rtps/reader/ReaderDiscoveryInfo.h @@ -20,7 +20,7 @@ #ifndef _FASTDDS_RTPS_READER_READERDISCOVERYINFO_H__ #define _FASTDDS_RTPS_READER_READERDISCOVERYINFO_H__ -#include +#include #include namespace eprosima { @@ -38,7 +38,7 @@ struct ReaderDiscoveryInfo //!Enum DISCOVERY_STATUS, four different status for discovered readers. //!@ingroup RTPS_MODULE #if defined(_WIN32) - enum RTPS_DllAPI DISCOVERY_STATUS + enum FASTDDS_EXPORTED_API DISCOVERY_STATUS #else enum DISCOVERY_STATUS #endif // if defined(_WIN32) diff --git a/include/fastdds/rtps/reader/ReaderListener.h b/include/fastdds/rtps/reader/ReaderListener.h index 5ebf826e62d..d579f93f78f 100644 --- a/include/fastdds/rtps/reader/ReaderListener.h +++ b/include/fastdds/rtps/reader/ReaderListener.h @@ -40,7 +40,7 @@ struct CacheChange_t; * certain events. * @ingroup READER_MODULE */ -class RTPS_DllAPI ReaderListener +class FASTDDS_EXPORTED_API ReaderListener { public: diff --git a/include/fastdds/rtps/reader/StatefulReader.h b/include/fastdds/rtps/reader/StatefulReader.h index 42790d1ce16..97cc36f91e9 100644 --- a/include/fastdds/rtps/reader/StatefulReader.h +++ b/include/fastdds/rtps/reader/StatefulReader.h @@ -27,7 +27,7 @@ #include #include #include -#include +#include namespace eprosima { namespace fastrtps { diff --git a/include/fastdds/rtps/reader/StatelessReader.h b/include/fastdds/rtps/reader/StatelessReader.h index 6db00fa24dd..82cf03ab77c 100644 --- a/include/fastdds/rtps/reader/StatelessReader.h +++ b/include/fastdds/rtps/reader/StatelessReader.h @@ -27,7 +27,7 @@ #include #include -#include +#include namespace eprosima { namespace fastrtps { diff --git a/include/fastdds/rtps/resources/ResourceEvent.h b/include/fastdds/rtps/resources/ResourceEvent.h index 33be690b67d..6016232d1e7 100644 --- a/include/fastdds/rtps/resources/ResourceEvent.h +++ b/include/fastdds/rtps/resources/ResourceEvent.h @@ -28,8 +28,8 @@ #include #include -#include -#include +#include +#include namespace eprosima { diff --git a/include/fastdds/rtps/rtps_all.h b/include/fastdds/rtps/rtps_all.h deleted file mode 100644 index 02c9f8af78d..00000000000 --- a/include/fastdds/rtps/rtps_all.h +++ /dev/null @@ -1,47 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file rtps_all.h - * - */ - -#ifndef _FASTDDS_RTPS_ALL_H_ -#define _FASTDDS_RTPS_ALL_H_ - -#include - -#include -#include - -#include - -#include -#include -#include -#include -#include - -#include -#include -#include - -#include -#include - -#include - -#include - -#endif /* _FASTDDS_RTPS_ALL_H_ */ diff --git a/include/fastdds/rtps/security/exceptions/SecurityException.h b/include/fastdds/rtps/security/exceptions/SecurityException.h index e638f1d2174..0838f4035fd 100644 --- a/include/fastdds/rtps/security/exceptions/SecurityException.h +++ b/include/fastdds/rtps/security/exceptions/SecurityException.h @@ -31,45 +31,55 @@ namespace security { */ class SecurityException : public Exception { - public: +public: - RTPS_DllAPI SecurityException() {} + FASTDDS_EXPORTED_API SecurityException() + { + } - /** - * @brief Default constructor. - * @param message An error message. This message is copied. - */ - RTPS_DllAPI SecurityException(const std::string& message) : Exception(message.c_str(), 1) {} + /** + * @brief Default constructor. + * @param message An error message. This message is copied. + */ + FASTDDS_EXPORTED_API SecurityException( + const std::string& message) + : Exception(message.c_str(), 1) + { + } - /** - * @brief Default copy constructor. - * @param ex SecurityException that will be copied. - */ - RTPS_DllAPI SecurityException(const SecurityException &ex); + /** + * @brief Default copy constructor. + * @param ex SecurityException that will be copied. + */ + FASTDDS_EXPORTED_API SecurityException( + const SecurityException& ex); - /** - * @brief Default move constructor. - * @param ex SecurityException that will be moved. - */ - RTPS_DllAPI SecurityException(SecurityException&& ex); + /** + * @brief Default move constructor. + * @param ex SecurityException that will be moved. + */ + FASTDDS_EXPORTED_API SecurityException( + SecurityException&& ex); - /** - * @brief Assigment operation. - * @param ex SecurityException that will be copied. - */ - RTPS_DllAPI SecurityException& operator=(const SecurityException &ex); + /** + * @brief Assigment operation. + * @param ex SecurityException that will be copied. + */ + FASTDDS_EXPORTED_API SecurityException& operator =( + const SecurityException& ex); - /** - * @brief Assigment operation. - * @param ex SecurityException that will be moved. - */ - RTPS_DllAPI SecurityException& operator=(SecurityException&& ex); + /** + * @brief Assigment operation. + * @param ex SecurityException that will be moved. + */ + FASTDDS_EXPORTED_API SecurityException& operator =( + SecurityException&& ex); - /// \brief Default constructor - virtual RTPS_DllAPI ~SecurityException() throw(); + /// \brief Default constructor + virtual FASTDDS_EXPORTED_API ~SecurityException() throw(); - /// \brief This function throws the object as an exception. - virtual RTPS_DllAPI void raise() const; + /// \brief This function throws the object as an exception. + virtual FASTDDS_EXPORTED_API void raise() const; }; } // namespace security } // namespace rtps diff --git a/include/fastdds/rtps/security/logging/Logging.h b/include/fastdds/rtps/security/logging/Logging.h index 340d5bf9a43..7e684b4faad 100644 --- a/include/fastdds/rtps/security/logging/Logging.h +++ b/include/fastdds/rtps/security/logging/Logging.h @@ -233,9 +233,9 @@ bool Logging::compose_header( // gcc expands __VA_ARGS___ before passing it into the macro. // Visual Studio expands __VA_ARGS__ after passing it. // This macro is a workaround to support both -#define __FASTRTPS_EXPAND(x) x +#define __FASTDDS_EXPAND(x) x -#define __FASTRTPS_SECURITY_LOGGING(LEVEL, CLASS, MESSAGE, EXCEPTION) \ +#define __FASTDDS_SECURITY_LOGGING(LEVEL, CLASS, MESSAGE, EXCEPTION) \ do { \ auto logger = get_logger(); \ if (logger){ \ @@ -243,40 +243,40 @@ bool Logging::compose_header( MESSAGE, \ std::string(CLASS ",") + __func__, \ EXCEPTION); \ - } \ - else { \ + } \ + else { \ switch (LEVEL){ \ case LoggingLevel::EMERGENCY_LEVEL: \ case LoggingLevel::ALERT_LEVEL: \ case LoggingLevel::CRITICAL_LEVEL: \ case LoggingLevel::ERROR_LEVEL: \ - EPROSIMA_LOG_ERROR(SECURITY, MESSAGE); \ + EPROSIMA_LOG_ERROR(SECURITY, MESSAGE); \ break; \ case LoggingLevel::WARNING_LEVEL: \ - EPROSIMA_LOG_WARNING(SECURITY, MESSAGE); \ + EPROSIMA_LOG_WARNING(SECURITY, MESSAGE); \ break; \ case LoggingLevel::NOTICE_LEVEL: \ case LoggingLevel::INFORMATIONAL_LEVEL: \ case LoggingLevel::DEBUG_LEVEL: \ - EPROSIMA_LOG_INFO(SECURITY, MESSAGE); \ + EPROSIMA_LOG_INFO(SECURITY, MESSAGE); \ break; \ } \ } \ } while (0); -#define __FASTRTPS_SECURITY_LOGGING_EX(LEVEL, CLASS, MESSAGE) \ +#define __FASTDDS_SECURITY_LOGGING_EX(LEVEL, CLASS, MESSAGE) \ do { \ eprosima::fastrtps::rtps::security::SecurityException lexception; \ - __FASTRTPS_SECURITY_LOGGING(LEVEL, CLASS, MESSAGE, lexception); \ + __FASTDDS_SECURITY_LOGGING(LEVEL, CLASS, MESSAGE, lexception); \ } while (0); -#define __FASTRTPS_MACRO_SELECTOR(_1, _2, _3, _4, NAME, ...) NAME +#define __FASTDDS_MACRO_SELECTOR(_1, _2, _3, _4, NAME, ...) NAME #define SECURITY_LOGGING(...) \ - __FASTRTPS_EXPAND( \ - __FASTRTPS_MACRO_SELECTOR(__VA_ARGS__, \ - __FASTRTPS_SECURITY_LOGGING, \ - __FASTRTPS_SECURITY_LOGGING_EX, \ + __FASTDDS_EXPAND( \ + __FASTDDS_MACRO_SELECTOR(__VA_ARGS__, \ + __FASTDDS_SECURITY_LOGGING, \ + __FASTDDS_SECURITY_LOGGING_EX, \ _UNUSED)(__VA_ARGS__)) #define EMERGENCY_SECURITY_LOGGING(...) SECURITY_LOGGING(LoggingLevel::EMERGENCY_LEVEL, __VA_ARGS__) diff --git a/include/fastdds/rtps/transport/ChainingTransport.h b/include/fastdds/rtps/transport/ChainingTransport.h index da3094ab958..364718c5499 100644 --- a/include/fastdds/rtps/transport/ChainingTransport.h +++ b/include/fastdds/rtps/transport/ChainingTransport.h @@ -56,7 +56,7 @@ class ChainingTransport : public TransportInterface public: //! Constructor - RTPS_DllAPI ChainingTransport( + FASTDDS_EXPORTED_API ChainingTransport( const ChainingTransportDescriptor& t) : TransportInterface(0) , low_level_transport_(t.low_level_descriptor->create_transport()) @@ -65,7 +65,7 @@ class ChainingTransport : public TransportInterface } //! Destructor - RTPS_DllAPI virtual ~ChainingTransport() = default; + FASTDDS_EXPORTED_API virtual ~ChainingTransport() = default; /*! * Initialize the low-level transport. This method will prepare all the internals of the transport. @@ -73,7 +73,7 @@ class ChainingTransport : public TransportInterface * @param max_msg_size_no_frag Optional maximum message size to avoid 65500 KB fragmentation limit. * @return True when the transport was correctly initialized. */ - RTPS_DllAPI bool init( + FASTDDS_EXPORTED_API bool init( const fastrtps::rtps::PropertyPolicy* properties = nullptr, const uint32_t& max_msg_size_no_frag = 0) override { @@ -85,7 +85,7 @@ class ChainingTransport : public TransportInterface * Must report whether the input channel associated to this locator is open. Channels must either be * fully closed or fully open, so that "open" and "close" operations are whole and definitive. */ - RTPS_DllAPI bool IsInputChannelOpen( + FASTDDS_EXPORTED_API bool IsInputChannelOpen( const fastrtps::rtps::Locator_t& loc) const override { return low_level_transport_->IsInputChannelOpen(loc); @@ -95,7 +95,7 @@ class ChainingTransport : public TransportInterface * Call the low-level transport `IsLocatorSupported()`. * Must report whether the given locator is supported by this transport (typically inspecting its "kind" value). */ - RTPS_DllAPI bool IsLocatorSupported( + FASTDDS_EXPORTED_API bool IsLocatorSupported( const fastrtps::rtps::Locator_t& loc) const override { return low_level_transport_->IsLocatorSupported(loc); @@ -105,7 +105,7 @@ class ChainingTransport : public TransportInterface * Call the low-level transport `RemoteToMainLocal()`. * Returns the locator describing the main (most general) channel that can write to the provided remote locator. */ - RTPS_DllAPI fastrtps::rtps::Locator_t RemoteToMainLocal( + FASTDDS_EXPORTED_API fastrtps::rtps::Locator_t RemoteToMainLocal( const fastrtps::rtps::Locator_t& loc) const override { return low_level_transport_->RemoteToMainLocal(loc); @@ -116,7 +116,7 @@ class ChainingTransport : public TransportInterface * Opens an input channel to receive incoming connections. * If there is an existing channel it registers the receiver interface. */ - RTPS_DllAPI bool OpenInputChannel( + FASTDDS_EXPORTED_API bool OpenInputChannel( const fastrtps::rtps::Locator_t& loc, TransportReceiverInterface* receiver_interface, uint32_t max_message_size) override; @@ -126,7 +126,7 @@ class ChainingTransport : public TransportInterface * Must open the channel that maps to/from the given locator. This method must allocate, reserve and mark * any resources that are needed for said channel. */ - RTPS_DllAPI bool OpenOutputChannel( + FASTDDS_EXPORTED_API bool OpenOutputChannel( SendResourceList& sender_resource_list, const fastrtps::rtps::Locator_t& loc) override; @@ -136,7 +136,7 @@ class ChainingTransport : public TransportInterface * IMPORTANT: It MUST be safe to call this method even during a Receive operation on another thread. You must implement * any necessary mutual exclusion and timeout mechanisms to make sure the channel can be closed without damage. */ - RTPS_DllAPI bool CloseInputChannel( + FASTDDS_EXPORTED_API bool CloseInputChannel( const fastrtps::rtps::Locator_t& loc) override { return low_level_transport_->CloseInputChannel(loc); @@ -146,7 +146,7 @@ class ChainingTransport : public TransportInterface * Call the low-level transport `NormalizeLocator()`. * Performs locator normalization (assign valid IP if not defined by user) */ - RTPS_DllAPI fastrtps::rtps::LocatorList_t NormalizeLocator( + FASTDDS_EXPORTED_API fastrtps::rtps::LocatorList_t NormalizeLocator( const fastrtps::rtps::Locator_t& locator) override { return low_level_transport_->NormalizeLocator(locator); @@ -156,7 +156,7 @@ class ChainingTransport : public TransportInterface * Call the low-level transport `is_local_locator()`. * Must report whether the given locator is from the local host */ - RTPS_DllAPI bool is_local_locator( + FASTDDS_EXPORTED_API bool is_local_locator( const fastrtps::rtps::Locator_t& locator) const override { return low_level_transport_->is_local_locator(locator); @@ -166,7 +166,7 @@ class ChainingTransport : public TransportInterface * Call the low-level transport `is_localhost_allowed()`. * Must report whether localhost locator is allowed */ - RTPS_DllAPI bool is_localhost_allowed() const override + FASTDDS_EXPORTED_API bool is_localhost_allowed() const override { return low_level_transport_->is_localhost_allowed(); } @@ -175,7 +175,7 @@ class ChainingTransport : public TransportInterface * Call the low-level transport `netmask_filter_info()`. * Returns netmask filter information (transport's netmask filter kind and allowlist) */ - RTPS_DllAPI NetmaskFilterInfo netmask_filter_info() const override + FASTDDS_EXPORTED_API NetmaskFilterInfo netmask_filter_info() const override { return low_level_transport_->netmask_filter_info(); } @@ -184,7 +184,7 @@ class ChainingTransport : public TransportInterface * Call the low-level transport `DoInputLocatorsMatch()`. * Must report whether two locators map to the same internal channel. */ - RTPS_DllAPI bool DoInputLocatorsMatch( + FASTDDS_EXPORTED_API bool DoInputLocatorsMatch( const fastrtps::rtps::Locator_t& locator_1, const fastrtps::rtps::Locator_t& locator_2) const override { @@ -195,7 +195,7 @@ class ChainingTransport : public TransportInterface * Call the low-level transport `select_locators()`. * Performs the locator selection algorithm for this transport. */ - RTPS_DllAPI void select_locators( + FASTDDS_EXPORTED_API void select_locators( fastrtps::rtps::LocatorSelector& selector) const override { return low_level_transport_->select_locators(selector); @@ -205,7 +205,7 @@ class ChainingTransport : public TransportInterface * Call the low-level transport `AddDefaultOutputLocator()`. * Add default output locator to the locator list */ - RTPS_DllAPI void AddDefaultOutputLocator( + FASTDDS_EXPORTED_API void AddDefaultOutputLocator( fastrtps::rtps::LocatorList_t& defaultList) override { return low_level_transport_->AddDefaultOutputLocator(defaultList); @@ -215,7 +215,7 @@ class ChainingTransport : public TransportInterface * Call the low-level transport `getDefaultMetatrafficMulticastLocators()`. * Add metatraffic multicast locator with the given port */ - RTPS_DllAPI bool getDefaultMetatrafficMulticastLocators( + FASTDDS_EXPORTED_API bool getDefaultMetatrafficMulticastLocators( fastrtps::rtps::LocatorList_t& locators, uint32_t metatraffic_multicast_port) const override { @@ -226,7 +226,7 @@ class ChainingTransport : public TransportInterface * Call the low-level transport `getDefaultMetatrafficUnicastLocators()`. * Add metatraffic unicast locator with the given port */ - RTPS_DllAPI bool getDefaultMetatrafficUnicastLocators( + FASTDDS_EXPORTED_API bool getDefaultMetatrafficUnicastLocators( fastrtps::rtps::LocatorList_t& locators, uint32_t metatraffic_unicast_port) const override { @@ -237,7 +237,7 @@ class ChainingTransport : public TransportInterface * Call the low-level transport `getDefaultUnicastLocators()`. * Add unicast locator with the given port */ - RTPS_DllAPI bool getDefaultUnicastLocators( + FASTDDS_EXPORTED_API bool getDefaultUnicastLocators( fastrtps::rtps::LocatorList_t& locators, uint32_t unicast_port) const override { @@ -248,7 +248,7 @@ class ChainingTransport : public TransportInterface * Call the low-level transport `fillMetatrafficMulticastLocator()`. * Assign port to the given metatraffic multicast locator if not already defined */ - RTPS_DllAPI bool fillMetatrafficMulticastLocator( + FASTDDS_EXPORTED_API bool fillMetatrafficMulticastLocator( fastrtps::rtps::Locator_t& locator, uint32_t metatraffic_multicast_port) const override { @@ -259,7 +259,7 @@ class ChainingTransport : public TransportInterface * Call the low-level transport `fillMetatrafficUnicastLocator()`. * Assign port to the given metatraffic unicast locator if not already defined */ - RTPS_DllAPI bool fillMetatrafficUnicastLocator( + FASTDDS_EXPORTED_API bool fillMetatrafficUnicastLocator( fastrtps::rtps::Locator_t& locator, uint32_t metatraffic_unicast_port) const override { @@ -270,7 +270,7 @@ class ChainingTransport : public TransportInterface * Call the low-level transport `configureInitialPeerLocator()`. * Configure the initial peer locators list */ - RTPS_DllAPI bool configureInitialPeerLocator( + FASTDDS_EXPORTED_API bool configureInitialPeerLocator( fastrtps::rtps::Locator_t& locator, const fastrtps::rtps::PortParameters& port_params, uint32_t domainId, @@ -283,7 +283,7 @@ class ChainingTransport : public TransportInterface * Call the low-level transport `fillUnicastLocator()`. * Assign port to the given unicast locator if not already defined */ - RTPS_DllAPI bool fillUnicastLocator( + FASTDDS_EXPORTED_API bool fillUnicastLocator( fastrtps::rtps::Locator_t& locator, uint32_t well_known_port) const override { @@ -292,7 +292,7 @@ class ChainingTransport : public TransportInterface //! Call the low-level transport `transform_remote_locator()`. //! Transforms a remote locator into a locator optimized for local communications. - RTPS_DllAPI bool transform_remote_locator( + FASTDDS_EXPORTED_API bool transform_remote_locator( const fastrtps::rtps::Locator_t& remote_locator, fastrtps::rtps::Locator_t& result_locator) const override { @@ -303,7 +303,7 @@ class ChainingTransport : public TransportInterface * Call the low-level transport `max_recv_buffer_size()`. * @return The maximum datagram size for reception supported by the transport */ - RTPS_DllAPI uint32_t max_recv_buffer_size() const override + FASTDDS_EXPORTED_API uint32_t max_recv_buffer_size() const override { return low_level_transport_->max_recv_buffer_size(); } @@ -326,7 +326,7 @@ class ChainingTransport : public TransportInterface * we're sending to. * @param timeout Maximum blocking time. */ - RTPS_DllAPI virtual bool send( + FASTDDS_EXPORTED_API virtual bool send( fastrtps::rtps::SenderResource* low_sender_resource, const fastrtps::rtps::octet* send_buffer, uint32_t send_buffer_size, @@ -349,14 +349,14 @@ class ChainingTransport : public TransportInterface * @param local_locator Locator mapping to the local channel we're listening to. * @param[out] remote_locator Locator describing the remote destination we received a packet from. */ - RTPS_DllAPI virtual void receive( + FASTDDS_EXPORTED_API virtual void receive( TransportReceiverInterface* next_receiver, const fastrtps::rtps::octet* receive_buffer, uint32_t receive_buffer_size, const fastrtps::rtps::Locator_t& local_locator, const fastrtps::rtps::Locator_t& remote_locator) = 0; - RTPS_DllAPI void update_network_interfaces() override + FASTDDS_EXPORTED_API void update_network_interfaces() override { low_level_transport_->update_network_interfaces(); } @@ -364,7 +364,7 @@ class ChainingTransport : public TransportInterface //! Call the low-level transport `transform_remote_locator()`. //! Transforms a remote locator into a locator optimized for local communications, //! if allowed by both local and remote transports. - RTPS_DllAPI bool transform_remote_locator( + FASTDDS_EXPORTED_API bool transform_remote_locator( const fastrtps::rtps::Locator_t& remote_locator, fastrtps::rtps::Locator_t& result_locator, bool allowed_remote_localhost, @@ -378,7 +378,7 @@ class ChainingTransport : public TransportInterface * Call the low-level transport `is_locator_allowed()`. * Must report whether the given locator is allowed by this transport. */ - RTPS_DllAPI bool is_locator_allowed( + FASTDDS_EXPORTED_API bool is_locator_allowed( const fastrtps::rtps::Locator_t& locator) const override { return low_level_transport_->is_locator_allowed(locator); diff --git a/include/fastdds/rtps/transport/ChainingTransportDescriptor.h b/include/fastdds/rtps/transport/ChainingTransportDescriptor.h index dad7bf74884..8cfddb57638 100644 --- a/include/fastdds/rtps/transport/ChainingTransportDescriptor.h +++ b/include/fastdds/rtps/transport/ChainingTransportDescriptor.h @@ -36,14 +36,14 @@ namespace rtps { */ typedef struct ChainingTransportDescriptor : public TransportDescriptorInterface { - RTPS_DllAPI ChainingTransportDescriptor( + FASTDDS_EXPORTED_API ChainingTransportDescriptor( std::shared_ptr low_level) : TransportDescriptorInterface(low_level->maxMessageSize, low_level->maxInitialPeersRange) , low_level_descriptor(low_level) { } - RTPS_DllAPI ChainingTransportDescriptor( + FASTDDS_EXPORTED_API ChainingTransportDescriptor( const ChainingTransportDescriptor& t) : TransportDescriptorInterface(t) , low_level_descriptor(t.low_level_descriptor) @@ -51,25 +51,25 @@ typedef struct ChainingTransportDescriptor : public TransportDescriptorInterface } //! Returns the minimum size required for a send operation. - RTPS_DllAPI virtual uint32_t min_send_buffer_size() const override + FASTDDS_EXPORTED_API virtual uint32_t min_send_buffer_size() const override { return low_level_descriptor->min_send_buffer_size(); } //! Returns the maximum size expected for received messages. - RTPS_DllAPI virtual uint32_t max_message_size() const override + FASTDDS_EXPORTED_API virtual uint32_t max_message_size() const override { return low_level_descriptor->max_message_size(); } - RTPS_DllAPI virtual ~ChainingTransportDescriptor() = default; + FASTDDS_EXPORTED_API virtual ~ChainingTransportDescriptor() = default; //! Descriptor for lower level transport std::shared_ptr low_level_descriptor; } ChainingTransportDescriptor; } // namespace rtps -} // namespace fastrtps +} // namespace fastdds } // namespace eprosima #endif // _FASTDDS_RTPS_TRANSPORT_CHAININGTRANSPORTDESCRIPTOR_H_ diff --git a/include/fastdds/rtps/transport/PortBasedTransportDescriptor.hpp b/include/fastdds/rtps/transport/PortBasedTransportDescriptor.hpp index 44f96e589f6..fa3714d9c52 100644 --- a/include/fastdds/rtps/transport/PortBasedTransportDescriptor.hpp +++ b/include/fastdds/rtps/transport/PortBasedTransportDescriptor.hpp @@ -20,7 +20,7 @@ #include #include -#include +#include namespace eprosima { namespace fastdds { @@ -41,23 +41,23 @@ class PortBasedTransportDescriptor : public TransportDescriptorInterface using ReceptionThreadsConfigMap = std::map; //! Constructor - RTPS_DllAPI PortBasedTransportDescriptor( + FASTDDS_EXPORTED_API PortBasedTransportDescriptor( uint32_t maximumMessageSize, uint32_t maximumInitialPeersRange); //! Copy constructor - RTPS_DllAPI PortBasedTransportDescriptor( + FASTDDS_EXPORTED_API PortBasedTransportDescriptor( const PortBasedTransportDescriptor& t) = default; //! Copy assignment - RTPS_DllAPI PortBasedTransportDescriptor& operator =( + FASTDDS_EXPORTED_API PortBasedTransportDescriptor& operator =( const PortBasedTransportDescriptor& t) = default; //! Destructor - virtual RTPS_DllAPI ~PortBasedTransportDescriptor() = default; + virtual FASTDDS_EXPORTED_API ~PortBasedTransportDescriptor() = default; //! Comparison operator - bool RTPS_DllAPI operator ==( + bool FASTDDS_EXPORTED_API operator ==( const PortBasedTransportDescriptor& t) const; /** @@ -76,25 +76,25 @@ class PortBasedTransportDescriptor : public TransportDescriptorInterface * * @return The ThreadSettings for the given port. */ - virtual RTPS_DllAPI const ThreadSettings& get_thread_config_for_port( + virtual FASTDDS_EXPORTED_API const ThreadSettings& get_thread_config_for_port( uint32_t port) const; - virtual RTPS_DllAPI bool set_thread_config_for_port( + virtual FASTDDS_EXPORTED_API bool set_thread_config_for_port( const uint32_t& port, const ThreadSettings& thread_settings); //! Returns the ThreadSettings for the default reception threads - RTPS_DllAPI const ThreadSettings& default_reception_threads() const; + FASTDDS_EXPORTED_API const ThreadSettings& default_reception_threads() const; //! Set the ThreadSettings for the default reception threads - virtual RTPS_DllAPI void default_reception_threads( + virtual FASTDDS_EXPORTED_API void default_reception_threads( const ThreadSettings& default_reception_threads); //! Returns the ThreadSettings for the user-configured reception threads - RTPS_DllAPI const ReceptionThreadsConfigMap& reception_threads() const; + FASTDDS_EXPORTED_API const ReceptionThreadsConfigMap& reception_threads() const; //! Set the ThreadSettings for the user-configured reception threads - virtual RTPS_DllAPI bool reception_threads( + virtual FASTDDS_EXPORTED_API bool reception_threads( const ReceptionThreadsConfigMap& reception_threads); protected: diff --git a/include/fastdds/rtps/transport/SenderResource.h b/include/fastdds/rtps/transport/SenderResource.h index b6a2b060bc1..4a2f272451d 100644 --- a/include/fastdds/rtps/transport/SenderResource.h +++ b/include/fastdds/rtps/transport/SenderResource.h @@ -21,7 +21,8 @@ #include #include -#include +#include +#include namespace eprosima { namespace fastrtps { diff --git a/include/fastdds/rtps/transport/SocketTransportDescriptor.h b/include/fastdds/rtps/transport/SocketTransportDescriptor.h index 80c5a3a6a19..421fde9f8be 100644 --- a/include/fastdds/rtps/transport/SocketTransportDescriptor.h +++ b/include/fastdds/rtps/transport/SocketTransportDescriptor.h @@ -47,7 +47,7 @@ constexpr uint8_t s_defaultTTL = 1; struct SocketTransportDescriptor : public PortBasedTransportDescriptor { //! Constructor - RTPS_DllAPI SocketTransportDescriptor( + FASTDDS_EXPORTED_API SocketTransportDescriptor( uint32_t maximumMessageSize, uint32_t maximumInitialPeersRange) : PortBasedTransportDescriptor(maximumMessageSize, maximumInitialPeersRange) @@ -59,23 +59,23 @@ struct SocketTransportDescriptor : public PortBasedTransportDescriptor } //! Copy constructor - RTPS_DllAPI SocketTransportDescriptor( + FASTDDS_EXPORTED_API SocketTransportDescriptor( const SocketTransportDescriptor& t) = default; //! Copy assignment - RTPS_DllAPI SocketTransportDescriptor& operator =( + FASTDDS_EXPORTED_API SocketTransportDescriptor& operator =( const SocketTransportDescriptor& t) = default; //! Destructor - virtual RTPS_DllAPI ~SocketTransportDescriptor() = default; + virtual FASTDDS_EXPORTED_API ~SocketTransportDescriptor() = default; - virtual RTPS_DllAPI uint32_t min_send_buffer_size() const override + virtual FASTDDS_EXPORTED_API uint32_t min_send_buffer_size() const override { return sendBufferSize; } //! Comparison operator - bool RTPS_DllAPI operator ==( + bool FASTDDS_EXPORTED_API operator ==( const SocketTransportDescriptor& t) const { return (this->sendBufferSize == t.min_send_buffer_size() && diff --git a/include/fastdds/rtps/transport/TCPTransportDescriptor.h b/include/fastdds/rtps/transport/TCPTransportDescriptor.h index d96a7d42903..c5cee7ae0b0 100644 --- a/include/fastdds/rtps/transport/TCPTransportDescriptor.h +++ b/include/fastdds/rtps/transport/TCPTransportDescriptor.h @@ -22,7 +22,7 @@ #include #include -#include +#include namespace eprosima { namespace fastdds { @@ -266,10 +266,6 @@ struct TCPTransportDescriptor : public SocketTransportDescriptor //! Enables the TCP_NODELAY socket option bool enable_tcp_nodelay; - - FASTDDS_TODO_BEFORE(3, 0, "Eliminate wait_for_tcp_negotiation, variable not in use."); - bool wait_for_tcp_negotiation; - //! Enables the calculation and sending of CRC on message headers bool calculate_crc; //! Enables checking the CRC of incoming message headers @@ -308,21 +304,21 @@ struct TCPTransportDescriptor : public SocketTransportDescriptor } //! Constructor - RTPS_DllAPI TCPTransportDescriptor(); + FASTDDS_EXPORTED_API TCPTransportDescriptor(); //! Copy constructor - RTPS_DllAPI TCPTransportDescriptor( + FASTDDS_EXPORTED_API TCPTransportDescriptor( const TCPTransportDescriptor& t); //! Copy assignment - RTPS_DllAPI TCPTransportDescriptor& operator =( + FASTDDS_EXPORTED_API TCPTransportDescriptor& operator =( const TCPTransportDescriptor& t); //! Destructor virtual ~TCPTransportDescriptor() = default; //! Comparison operator - RTPS_DllAPI bool operator ==( + FASTDDS_EXPORTED_API bool operator ==( const TCPTransportDescriptor& t) const; }; diff --git a/include/fastdds/rtps/transport/TCPv4TransportDescriptor.h b/include/fastdds/rtps/transport/TCPv4TransportDescriptor.h index f6f3c8e2c4f..6d33d0b40d5 100644 --- a/include/fastdds/rtps/transport/TCPv4TransportDescriptor.h +++ b/include/fastdds/rtps/transport/TCPv4TransportDescriptor.h @@ -81,18 +81,18 @@ struct TCPv4TransportDescriptor : public TCPTransportDescriptor } //! Constructor - RTPS_DllAPI TCPv4TransportDescriptor(); + FASTDDS_EXPORTED_API TCPv4TransportDescriptor(); //! Copy constructor - RTPS_DllAPI TCPv4TransportDescriptor( + FASTDDS_EXPORTED_API TCPv4TransportDescriptor( const TCPv4TransportDescriptor& t); //! Copy assignment - RTPS_DllAPI TCPv4TransportDescriptor& operator =( + FASTDDS_EXPORTED_API TCPv4TransportDescriptor& operator =( const TCPv4TransportDescriptor& t); //! Comparison operator - RTPS_DllAPI bool operator ==( + FASTDDS_EXPORTED_API bool operator ==( const TCPv4TransportDescriptor& t) const; }; diff --git a/include/fastdds/rtps/transport/TCPv6TransportDescriptor.h b/include/fastdds/rtps/transport/TCPv6TransportDescriptor.h index 43513cde0a8..ad73604d97e 100644 --- a/include/fastdds/rtps/transport/TCPv6TransportDescriptor.h +++ b/include/fastdds/rtps/transport/TCPv6TransportDescriptor.h @@ -35,18 +35,18 @@ struct TCPv6TransportDescriptor : public TCPTransportDescriptor virtual TransportInterface* create_transport() const override; //! Constructor - RTPS_DllAPI TCPv6TransportDescriptor(); + FASTDDS_EXPORTED_API TCPv6TransportDescriptor(); //! Copy constructor - RTPS_DllAPI TCPv6TransportDescriptor( + FASTDDS_EXPORTED_API TCPv6TransportDescriptor( const TCPv6TransportDescriptor& t); //! Copy assignment - RTPS_DllAPI TCPv6TransportDescriptor& operator =( + FASTDDS_EXPORTED_API TCPv6TransportDescriptor& operator =( const TCPv6TransportDescriptor& t) = default; //! Comparison operator - RTPS_DllAPI bool operator ==( + FASTDDS_EXPORTED_API bool operator ==( const TCPv6TransportDescriptor& t) const; }; diff --git a/include/fastdds/rtps/transport/TransportDescriptorInterface.h b/include/fastdds/rtps/transport/TransportDescriptorInterface.h index 255ac0c1e1b..2327566808c 100644 --- a/include/fastdds/rtps/transport/TransportDescriptorInterface.h +++ b/include/fastdds/rtps/transport/TransportDescriptorInterface.h @@ -19,7 +19,7 @@ #include #include -#include +#include namespace eprosima { namespace fastdds { @@ -42,7 +42,7 @@ class TransportInterface; struct TransportDescriptorInterface { //! Constructor - RTPS_DllAPI TransportDescriptorInterface( + FASTDDS_EXPORTED_API TransportDescriptorInterface( uint32_t maximumMessageSize, uint32_t maximumInitialPeersRange) : maxMessageSize(maximumMessageSize) @@ -51,7 +51,7 @@ struct TransportDescriptorInterface } //! Copy constructor - RTPS_DllAPI TransportDescriptorInterface( + FASTDDS_EXPORTED_API TransportDescriptorInterface( const TransportDescriptorInterface& t) : maxMessageSize(t.maxMessageSize) , maxInitialPeersRange(t.maxInitialPeersRange) @@ -59,7 +59,7 @@ struct TransportDescriptorInterface } //! Copy assignment - RTPS_DllAPI TransportDescriptorInterface& operator =( + FASTDDS_EXPORTED_API TransportDescriptorInterface& operator =( const TransportDescriptorInterface& t) { maxMessageSize = t.maxMessageSize; @@ -68,20 +68,20 @@ struct TransportDescriptorInterface } //! Destructor - virtual RTPS_DllAPI ~TransportDescriptorInterface() = default; + virtual FASTDDS_EXPORTED_API ~TransportDescriptorInterface() = default; /** * Factory method pattern. It will create and return a TransportInterface * corresponding to this descriptor. This provides an interface to the NetworkFactory * to create the transports without the need to know about their type */ - virtual RTPS_DllAPI TransportInterface* create_transport() const = 0; + virtual FASTDDS_EXPORTED_API TransportInterface* create_transport() const = 0; //! Returns the minimum size required for a send operation. - virtual RTPS_DllAPI uint32_t min_send_buffer_size() const = 0; + virtual FASTDDS_EXPORTED_API uint32_t min_send_buffer_size() const = 0; //! Returns the maximum size expected for received messages. - virtual RTPS_DllAPI uint32_t max_message_size() const + virtual FASTDDS_EXPORTED_API uint32_t max_message_size() const { return maxMessageSize; } @@ -89,13 +89,13 @@ struct TransportDescriptorInterface /** Returns the maximum number of opened channels for each initial remote peer * (maximum number of guessed initial peers to try to connect) */ - virtual RTPS_DllAPI uint32_t max_initial_peers_range() const + virtual FASTDDS_EXPORTED_API uint32_t max_initial_peers_range() const { return maxInitialPeersRange; } //! Comparison operator - RTPS_DllAPI bool operator ==( + FASTDDS_EXPORTED_API bool operator ==( const TransportDescriptorInterface& t) const { return (this->maxMessageSize == t.max_message_size() && @@ -103,13 +103,13 @@ struct TransportDescriptorInterface } //! Lock internal mutex (for Fast-DDS internal use) - RTPS_DllAPI void lock() + FASTDDS_EXPORTED_API void lock() { mtx_.lock(); } //! Unlock internal mutex (for Fast-DDS internal use) - RTPS_DllAPI void unlock() + FASTDDS_EXPORTED_API void unlock() { mtx_.unlock(); } diff --git a/include/fastdds/rtps/transport/TransportInterface.h b/include/fastdds/rtps/transport/TransportInterface.h index 8ff96ee76f7..b016492476b 100644 --- a/include/fastdds/rtps/transport/TransportInterface.h +++ b/include/fastdds/rtps/transport/TransportInterface.h @@ -20,6 +20,7 @@ #include #include +#include #include #include #include @@ -50,13 +51,13 @@ using NetmaskFilterInfo = std::pair; /** - * Interface against which to implement a transport layer, decoupled from FastRTPS internals. + * Interface against which to implement a transport layer, decoupled from Fast DDS internals. * TransportInterface expects the user to implement a logical equivalence between Locators and protocol-specific "channels". * This equivalence can be narrowing: For instance in UDP/IP, a port would take the role of channel, and several different * locators can map to the same port, and hence the same channel. * @ingroup TRANSPORT_MODULE * */ -class RTPS_DllAPI TransportInterface +class FASTDDS_EXPORTED_API TransportInterface { public: diff --git a/include/fastdds/rtps/transport/TransportReceiverInterface.h b/include/fastdds/rtps/transport/TransportReceiverInterface.h index 779266a31bc..1c7e5d6f4c0 100644 --- a/include/fastdds/rtps/transport/TransportReceiverInterface.h +++ b/include/fastdds/rtps/transport/TransportReceiverInterface.h @@ -25,7 +25,7 @@ namespace rtps { * Interface against which to implement a data receiver, decoupled from transport internals. * @ingroup TRANSPORT_MODULE * */ -class RTPS_DllAPI TransportReceiverInterface +class FASTDDS_EXPORTED_API TransportReceiverInterface { public: diff --git a/include/fastdds/rtps/transport/UDPTransportDescriptor.h b/include/fastdds/rtps/transport/UDPTransportDescriptor.h index 18efac6128d..c06ae15d22a 100644 --- a/include/fastdds/rtps/transport/UDPTransportDescriptor.h +++ b/include/fastdds/rtps/transport/UDPTransportDescriptor.h @@ -16,7 +16,7 @@ #define _FASTDDS_UDP_TRANSPORT_DESCRIPTOR_ #include -#include +#include namespace eprosima { namespace fastdds { @@ -39,18 +39,18 @@ struct UDPTransportDescriptor : public SocketTransportDescriptor virtual ~UDPTransportDescriptor() = default; //! Constructor - RTPS_DllAPI UDPTransportDescriptor(); + FASTDDS_EXPORTED_API UDPTransportDescriptor(); //! Copy constructor - RTPS_DllAPI UDPTransportDescriptor( + FASTDDS_EXPORTED_API UDPTransportDescriptor( const UDPTransportDescriptor& t) = default; //! Copy assignment - RTPS_DllAPI UDPTransportDescriptor& operator =( + FASTDDS_EXPORTED_API UDPTransportDescriptor& operator =( const UDPTransportDescriptor& t) = default; //! Comparison operator - RTPS_DllAPI bool operator ==( + FASTDDS_EXPORTED_API bool operator ==( const UDPTransportDescriptor& t) const; //! Source port to use for outgoing datagrams diff --git a/include/fastdds/rtps/transport/UDPv4TransportDescriptor.h b/include/fastdds/rtps/transport/UDPv4TransportDescriptor.h index d43f81160c6..7bdae6be2f4 100644 --- a/include/fastdds/rtps/transport/UDPv4TransportDescriptor.h +++ b/include/fastdds/rtps/transport/UDPv4TransportDescriptor.h @@ -35,17 +35,17 @@ struct UDPv4TransportDescriptor : public UDPTransportDescriptor virtual TransportInterface* create_transport() const override; //! Constructor - RTPS_DllAPI UDPv4TransportDescriptor(); + FASTDDS_EXPORTED_API UDPv4TransportDescriptor(); //! Copy constructor - RTPS_DllAPI UDPv4TransportDescriptor( + FASTDDS_EXPORTED_API UDPv4TransportDescriptor( const UDPv4TransportDescriptor& t) = default; //! Copy assignment - RTPS_DllAPI UDPv4TransportDescriptor& operator =( + FASTDDS_EXPORTED_API UDPv4TransportDescriptor& operator =( const UDPv4TransportDescriptor& t) = default; - RTPS_DllAPI bool operator ==( + FASTDDS_EXPORTED_API bool operator ==( const UDPv4TransportDescriptor& t) const; }; diff --git a/include/fastdds/rtps/transport/UDPv6TransportDescriptor.h b/include/fastdds/rtps/transport/UDPv6TransportDescriptor.h index 2fa2e730646..8ab8a970956 100644 --- a/include/fastdds/rtps/transport/UDPv6TransportDescriptor.h +++ b/include/fastdds/rtps/transport/UDPv6TransportDescriptor.h @@ -37,17 +37,17 @@ struct UDPv6TransportDescriptor : public UDPTransportDescriptor virtual TransportInterface* create_transport() const override; //! Constructor - RTPS_DllAPI UDPv6TransportDescriptor(); + FASTDDS_EXPORTED_API UDPv6TransportDescriptor(); //! Copy constructor - RTPS_DllAPI UDPv6TransportDescriptor( + FASTDDS_EXPORTED_API UDPv6TransportDescriptor( const UDPv6TransportDescriptor& t) = default; //! Copy assignment - RTPS_DllAPI UDPv6TransportDescriptor& operator =( + FASTDDS_EXPORTED_API UDPv6TransportDescriptor& operator =( const UDPv6TransportDescriptor& t) = default; - RTPS_DllAPI bool operator ==( + FASTDDS_EXPORTED_API bool operator ==( const UDPv6TransportDescriptor& t) const; }; diff --git a/include/fastdds/rtps/transport/network/AllowedNetworkInterface.hpp b/include/fastdds/rtps/transport/network/AllowedNetworkInterface.hpp index 3b832ff10ba..fee25c4e869 100644 --- a/include/fastdds/rtps/transport/network/AllowedNetworkInterface.hpp +++ b/include/fastdds/rtps/transport/network/AllowedNetworkInterface.hpp @@ -20,7 +20,7 @@ #define _FASTDDS_RTPS_TRANSPORT_NETWORK_ALLOWEDNETWORKINTERFACE_HPP_ #include -#include +#include namespace eprosima { namespace fastdds { @@ -37,22 +37,22 @@ struct AllowedNetworkInterface : public NetworkInterfaceWithFilter using NetworkInterfaceWithFilter::NetworkInterfaceWithFilter; //! Destructor - virtual RTPS_DllAPI ~AllowedNetworkInterface() = default; + virtual FASTDDS_EXPORTED_API ~AllowedNetworkInterface() = default; //! Copy constructor - RTPS_DllAPI AllowedNetworkInterface( + FASTDDS_EXPORTED_API AllowedNetworkInterface( const AllowedNetworkInterface& iface) = default; //! Copy assignment - RTPS_DllAPI AllowedNetworkInterface& operator =( + FASTDDS_EXPORTED_API AllowedNetworkInterface& operator =( const AllowedNetworkInterface& iface) = default; //! Move constructor - RTPS_DllAPI AllowedNetworkInterface( + FASTDDS_EXPORTED_API AllowedNetworkInterface( AllowedNetworkInterface&& iface) = default; //! Move assignment - RTPS_DllAPI AllowedNetworkInterface& operator =( + FASTDDS_EXPORTED_API AllowedNetworkInterface& operator =( AllowedNetworkInterface&& iface) = default; }; diff --git a/include/fastdds/rtps/transport/network/BlockedNetworkInterface.hpp b/include/fastdds/rtps/transport/network/BlockedNetworkInterface.hpp index b9ef6f7eb70..559bea4da90 100644 --- a/include/fastdds/rtps/transport/network/BlockedNetworkInterface.hpp +++ b/include/fastdds/rtps/transport/network/BlockedNetworkInterface.hpp @@ -20,7 +20,7 @@ #define _FASTDDS_RTPS_TRANSPORT_NETWORK_BLOCKEDNETWORKINTERFACE_HPP_ #include -#include +#include namespace eprosima { namespace fastdds { @@ -37,22 +37,22 @@ struct BlockedNetworkInterface : public NetworkInterface using NetworkInterface::NetworkInterface; //! Destructor - virtual RTPS_DllAPI ~BlockedNetworkInterface() = default; + virtual FASTDDS_EXPORTED_API ~BlockedNetworkInterface() = default; //! Copy constructor - RTPS_DllAPI BlockedNetworkInterface( + FASTDDS_EXPORTED_API BlockedNetworkInterface( const BlockedNetworkInterface& iface) = default; //! Copy assignment - RTPS_DllAPI BlockedNetworkInterface& operator =( + FASTDDS_EXPORTED_API BlockedNetworkInterface& operator =( const BlockedNetworkInterface& iface) = default; //! Move constructor - RTPS_DllAPI BlockedNetworkInterface( + FASTDDS_EXPORTED_API BlockedNetworkInterface( BlockedNetworkInterface&& iface) = default; //! Move assignment - RTPS_DllAPI BlockedNetworkInterface& operator =( + FASTDDS_EXPORTED_API BlockedNetworkInterface& operator =( BlockedNetworkInterface&& iface) = default; }; diff --git a/include/fastdds/rtps/transport/network/NetmaskFilterKind.hpp b/include/fastdds/rtps/transport/network/NetmaskFilterKind.hpp index f2ec8e67c32..09d0d8926cd 100644 --- a/include/fastdds/rtps/transport/network/NetmaskFilterKind.hpp +++ b/include/fastdds/rtps/transport/network/NetmaskFilterKind.hpp @@ -21,7 +21,7 @@ #include -#include +#include namespace eprosima { namespace fastdds { @@ -34,7 +34,7 @@ enum class NetmaskFilterKind ON }; -RTPS_DllAPI std::ostream& operator <<( +FASTDDS_EXPORTED_API std::ostream& operator <<( std::ostream& output, const NetmaskFilterKind& netmask_filter_kind); diff --git a/include/fastdds/rtps/transport/network/NetworkInterface.hpp b/include/fastdds/rtps/transport/network/NetworkInterface.hpp index 15fd5188827..be7c9c3cdf2 100644 --- a/include/fastdds/rtps/transport/network/NetworkInterface.hpp +++ b/include/fastdds/rtps/transport/network/NetworkInterface.hpp @@ -22,7 +22,7 @@ #include #include -#include +#include namespace eprosima { namespace fastdds { @@ -37,36 +37,36 @@ namespace rtps { struct NetworkInterface { //! Constructor by name - RTPS_DllAPI NetworkInterface( + FASTDDS_EXPORTED_API NetworkInterface( const std::string& name); //! Constructor by device name, IP address string and locator with mask - RTPS_DllAPI NetworkInterface( + FASTDDS_EXPORTED_API NetworkInterface( const std::string& device, const std::string& ip, const LocatorWithMask& locator); //! Destructor - virtual RTPS_DllAPI ~NetworkInterface() = default; + virtual FASTDDS_EXPORTED_API ~NetworkInterface() = default; //! Copy constructor - RTPS_DllAPI NetworkInterface( + FASTDDS_EXPORTED_API NetworkInterface( const NetworkInterface& iface) = default; //! Copy assignment - RTPS_DllAPI NetworkInterface& operator =( + FASTDDS_EXPORTED_API NetworkInterface& operator =( const NetworkInterface& iface) = default; //! Move constructor - RTPS_DllAPI NetworkInterface( + FASTDDS_EXPORTED_API NetworkInterface( NetworkInterface&& iface) = default; //! Move assignment - RTPS_DllAPI NetworkInterface& operator =( + FASTDDS_EXPORTED_API NetworkInterface& operator =( NetworkInterface&& iface) = default; //! Comparison operator - RTPS_DllAPI bool operator ==( + FASTDDS_EXPORTED_API bool operator ==( const NetworkInterface& iface) const; //! Interface device name or IP address in string format (to be filled by the user) diff --git a/include/fastdds/rtps/transport/network/NetworkInterfaceWithFilter.hpp b/include/fastdds/rtps/transport/network/NetworkInterfaceWithFilter.hpp index a37113b8e0d..bb428b58c3a 100644 --- a/include/fastdds/rtps/transport/network/NetworkInterfaceWithFilter.hpp +++ b/include/fastdds/rtps/transport/network/NetworkInterfaceWithFilter.hpp @@ -23,7 +23,7 @@ #include #include -#include +#include namespace eprosima { namespace fastdds { @@ -38,12 +38,12 @@ namespace rtps { struct NetworkInterfaceWithFilter : public NetworkInterface { //! Constructor by name and netmask filter - RTPS_DllAPI NetworkInterfaceWithFilter( + FASTDDS_EXPORTED_API NetworkInterfaceWithFilter( const std::string& name, NetmaskFilterKind netmask_filter); //! Constructor by name - RTPS_DllAPI NetworkInterfaceWithFilter( + FASTDDS_EXPORTED_API NetworkInterfaceWithFilter( const std::string& name); //! Constructor by device name, IP address string, locator with mask and netmask filter @@ -54,32 +54,32 @@ struct NetworkInterfaceWithFilter : public NetworkInterface NetmaskFilterKind netmask_filter); //! Constructor by device name, IP address string and locator with mask - RTPS_DllAPI NetworkInterfaceWithFilter( + FASTDDS_EXPORTED_API NetworkInterfaceWithFilter( const std::string& device, const std::string& ip, const LocatorWithMask& locator); //! Destructor - virtual RTPS_DllAPI ~NetworkInterfaceWithFilter() = default; + virtual FASTDDS_EXPORTED_API ~NetworkInterfaceWithFilter() = default; //! Copy constructor - RTPS_DllAPI NetworkInterfaceWithFilter( + FASTDDS_EXPORTED_API NetworkInterfaceWithFilter( const NetworkInterfaceWithFilter& iface) = default; //! Copy assignment - RTPS_DllAPI NetworkInterfaceWithFilter& operator =( + FASTDDS_EXPORTED_API NetworkInterfaceWithFilter& operator =( const NetworkInterfaceWithFilter& iface) = default; //! Move constructor - RTPS_DllAPI NetworkInterfaceWithFilter( + FASTDDS_EXPORTED_API NetworkInterfaceWithFilter( NetworkInterfaceWithFilter&& iface) = default; //! Move assignment - RTPS_DllAPI NetworkInterfaceWithFilter& operator =( + FASTDDS_EXPORTED_API NetworkInterfaceWithFilter& operator =( NetworkInterfaceWithFilter&& iface) = default; //! Comparison operator - RTPS_DllAPI bool operator ==( + FASTDDS_EXPORTED_API bool operator ==( const NetworkInterfaceWithFilter& iface) const; //! Netmask filter configuration diff --git a/include/fastdds/rtps/transport/shared_mem/SharedMemTransportDescriptor.h b/include/fastdds/rtps/transport/shared_mem/SharedMemTransportDescriptor.h index db8d1951607..54b0509bd1d 100644 --- a/include/fastdds/rtps/transport/shared_mem/SharedMemTransportDescriptor.h +++ b/include/fastdds/rtps/transport/shared_mem/SharedMemTransportDescriptor.h @@ -19,7 +19,7 @@ #include #include -#include +#include namespace eprosima { namespace fastdds { @@ -55,24 +55,24 @@ struct SharedMemTransportDescriptor : public PortBasedTransportDescriptor } //! Constructor - RTPS_DllAPI SharedMemTransportDescriptor(); + FASTDDS_EXPORTED_API SharedMemTransportDescriptor(); //! Copy constructor - RTPS_DllAPI SharedMemTransportDescriptor( + FASTDDS_EXPORTED_API SharedMemTransportDescriptor( const SharedMemTransportDescriptor& t) = default; //! Copy assignment - RTPS_DllAPI SharedMemTransportDescriptor& operator =( + FASTDDS_EXPORTED_API SharedMemTransportDescriptor& operator =( const SharedMemTransportDescriptor& t) = default; //! Return the size of the shared memory segment - RTPS_DllAPI uint32_t segment_size() const + FASTDDS_EXPORTED_API uint32_t segment_size() const { return segment_size_; } //! Set the size of the shared memory segment - RTPS_DllAPI void segment_size( + FASTDDS_EXPORTED_API void segment_size( uint32_t segment_size) { segment_size_ = segment_size; @@ -85,66 +85,66 @@ struct SharedMemTransportDescriptor : public PortBasedTransportDescriptor } //! Set the maximum size of a single message in the transport (in octets) - RTPS_DllAPI void max_message_size( + FASTDDS_EXPORTED_API void max_message_size( uint32_t max_message_size) { maxMessageSize = max_message_size; } //! Return the size of the listening port (in messages) - RTPS_DllAPI uint32_t port_queue_capacity() const + FASTDDS_EXPORTED_API uint32_t port_queue_capacity() const { return port_queue_capacity_; } //! Set the size of the listening port (in messages) - RTPS_DllAPI void port_queue_capacity( + FASTDDS_EXPORTED_API void port_queue_capacity( uint32_t port_queue_capacity) { port_queue_capacity_ = port_queue_capacity; } //! Return the timeout for the health check of ports (ms) - RTPS_DllAPI uint32_t healthy_check_timeout_ms() const + FASTDDS_EXPORTED_API uint32_t healthy_check_timeout_ms() const { return healthy_check_timeout_ms_; } //! Set the timeout for the health check of ports (ms) - RTPS_DllAPI void healthy_check_timeout_ms( + FASTDDS_EXPORTED_API void healthy_check_timeout_ms( uint32_t healthy_check_timeout_ms) { healthy_check_timeout_ms_ = healthy_check_timeout_ms; } //! Return the full path of the protocol dump file - RTPS_DllAPI std::string rtps_dump_file() const + FASTDDS_EXPORTED_API std::string rtps_dump_file() const { return rtps_dump_file_; } //! Set the full path of the protocol dump file - RTPS_DllAPI void rtps_dump_file( + FASTDDS_EXPORTED_API void rtps_dump_file( const std::string& rtps_dump_file) { rtps_dump_file_ = rtps_dump_file; } //! Return the thread settings for the transport dump thread - RTPS_DllAPI ThreadSettings dump_thread() const + FASTDDS_EXPORTED_API ThreadSettings dump_thread() const { return dump_thread_; } //! Set the thread settings for the transport dump thread - RTPS_DllAPI void dump_thread( + FASTDDS_EXPORTED_API void dump_thread( const ThreadSettings& dump_thread) { dump_thread_ = dump_thread; } //! Comparison operator - RTPS_DllAPI bool operator ==( + FASTDDS_EXPORTED_API bool operator ==( const SharedMemTransportDescriptor& t) const; private: diff --git a/include/fastdds/rtps/transport/test_UDPv4TransportDescriptor.h b/include/fastdds/rtps/transport/test_UDPv4TransportDescriptor.h index dafa7798ae8..79665530133 100644 --- a/include/fastdds/rtps/transport/test_UDPv4TransportDescriptor.h +++ b/include/fastdds/rtps/transport/test_UDPv4TransportDescriptor.h @@ -81,7 +81,7 @@ struct test_UDPv4TransportDescriptor : public SocketTransportDescriptor uint32_t dropLogLength; //! Constructor - RTPS_DllAPI test_UDPv4TransportDescriptor(); + FASTDDS_EXPORTED_API test_UDPv4TransportDescriptor(); //! Destructor virtual ~test_UDPv4TransportDescriptor() = default; @@ -90,24 +90,24 @@ struct test_UDPv4TransportDescriptor : public SocketTransportDescriptor virtual TransportInterface* create_transport() const override; //! Copy constructor - RTPS_DllAPI test_UDPv4TransportDescriptor( + FASTDDS_EXPORTED_API test_UDPv4TransportDescriptor( const test_UDPv4TransportDescriptor& t) = delete; //! Copy assignment - RTPS_DllAPI test_UDPv4TransportDescriptor& operator =( + FASTDDS_EXPORTED_API test_UDPv4TransportDescriptor& operator =( const test_UDPv4TransportDescriptor& t) = delete; //! Move constructor - RTPS_DllAPI test_UDPv4TransportDescriptor( + FASTDDS_EXPORTED_API test_UDPv4TransportDescriptor( test_UDPv4TransportDescriptor&& t) = delete; //! Move assignment - RTPS_DllAPI test_UDPv4TransportDescriptor& operator =( + FASTDDS_EXPORTED_API test_UDPv4TransportDescriptor& operator =( test_UDPv4TransportDescriptor&& t) = delete; //! Comparison operator // Filters are not included - RTPS_DllAPI bool operator ==( + FASTDDS_EXPORTED_API bool operator ==( const test_UDPv4TransportDescriptor& t) const; }; diff --git a/include/fastdds/rtps/writer/IReaderDataFilter.hpp b/include/fastdds/rtps/writer/IReaderDataFilter.hpp deleted file mode 100644 index 5331d7b8173..00000000000 --- a/include/fastdds/rtps/writer/IReaderDataFilter.hpp +++ /dev/null @@ -1,22 +0,0 @@ -// Copyright 2020 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file IReaderDataFilter.hpp - */ - -// This file was moved as part of the implementation of content filtered topics -#include - -FASTDDS_TODO_BEFORE(3, 0, "This header should be removed"); diff --git a/include/fastdds/rtps/writer/LocatorSelectorSender.hpp b/include/fastdds/rtps/writer/LocatorSelectorSender.hpp index 8e691dff09f..149d948912c 100644 --- a/include/fastdds/rtps/writer/LocatorSelectorSender.hpp +++ b/include/fastdds/rtps/writer/LocatorSelectorSender.hpp @@ -3,8 +3,8 @@ #include #include -#include -#include +#include +#include namespace eprosima { namespace fastrtps { diff --git a/include/fastdds/rtps/writer/RTPSWriter.h b/include/fastdds/rtps/writer/RTPSWriter.h index 6faad6b225a..1955bfafabf 100644 --- a/include/fastdds/rtps/writer/RTPSWriter.h +++ b/include/fastdds/rtps/writer/RTPSWriter.h @@ -25,6 +25,7 @@ #include #include +#include #include #include #include @@ -33,16 +34,12 @@ #include #include #include +#include +#include #include #include -#include - - -#include "DeliveryRetCode.hpp" -#include "LocatorSelectorSender.hpp" namespace eprosima { - namespace fastdds { namespace rtps { @@ -137,12 +134,12 @@ class RTPSWriter }, changeKind, handle); } - RTPS_DllAPI CacheChange_t* new_change( + FASTDDS_EXPORTED_API CacheChange_t* new_change( const std::function& dataCdrSerializedSize, ChangeKind_t changeKind, InstanceHandle_t handle = c_InstanceHandle_Unknown); - RTPS_DllAPI CacheChange_t* new_change( + FASTDDS_EXPORTED_API CacheChange_t* new_change( ChangeKind_t changeKind, InstanceHandle_t handle = c_InstanceHandle_Unknown); @@ -159,7 +156,7 @@ class RTPSWriter * * @post memory pointed to by @c change is not accessed */ - RTPS_DllAPI bool release_change( + FASTDDS_EXPORTED_API bool release_change( CacheChange_t* change); /** @@ -167,7 +164,7 @@ class RTPSWriter * @param data Pointer to the ReaderProxyData object added. * @return True if added. */ - RTPS_DllAPI virtual bool matched_reader_add( + FASTDDS_EXPORTED_API virtual bool matched_reader_add( const ReaderProxyData& data) = 0; /** @@ -175,7 +172,7 @@ class RTPSWriter * @param reader_guid GUID of the reader to remove. * @return True if removed. */ - RTPS_DllAPI virtual bool matched_reader_remove( + FASTDDS_EXPORTED_API virtual bool matched_reader_remove( const GUID_t& reader_guid) = 0; /** @@ -183,7 +180,7 @@ class RTPSWriter * @param reader_guid GUID of the reader to check. * @return True if it was matched. */ - RTPS_DllAPI virtual bool matched_reader_is_matched( + FASTDDS_EXPORTED_API virtual bool matched_reader_is_matched( const GUID_t& reader_guid) = 0; /** @@ -195,7 +192,7 @@ class RTPSWriter * @param filter The content filter to use on this writer. May be @c nullptr to remove the content filter * (i.e. treat all samples as relevant). */ - RTPS_DllAPI virtual void reader_data_filter( + FASTDDS_EXPORTED_API virtual void reader_data_filter( fastdds::rtps::IReaderDataFilter* filter) = 0; /** @@ -203,7 +200,7 @@ class RTPSWriter * * @return The content filter used on this writer. */ - RTPS_DllAPI virtual const fastdds::rtps::IReaderDataFilter* reader_data_filter() const = 0; + FASTDDS_EXPORTED_API virtual const fastdds::rtps::IReaderDataFilter* reader_data_filter() const = 0; /** * @brief Check if a specific change has been delivered to the transport layer of every matched remote RTPSReader @@ -212,7 +209,7 @@ class RTPSWriter * @param seq_num Sequence number of the change to check. * @return true if delivered. False otherwise. */ - RTPS_DllAPI virtual bool has_been_fully_delivered( + FASTDDS_EXPORTED_API virtual bool has_been_fully_delivered( const SequenceNumber_t& seq_num) const { static_cast(seq_num); @@ -224,7 +221,7 @@ class RTPSWriter * Is only useful in reliable Writer. In BE Writers returns false when pending to be sent. * @return True if acknowledged by all. */ - RTPS_DllAPI virtual bool is_acked_by_all( + FASTDDS_EXPORTED_API virtual bool is_acked_by_all( const CacheChange_t* /*a_change*/) const { return false; @@ -234,7 +231,7 @@ class RTPSWriter * Waits until all changes were acknowledged or max_wait. * @return True if all were acknowledged. */ - RTPS_DllAPI virtual bool wait_for_all_acked( + FASTDDS_EXPORTED_API virtual bool wait_for_all_acked( const Duration_t& /*max_wait*/) { return true; @@ -244,26 +241,26 @@ class RTPSWriter * Update the Attributes of the Writer. * @param att New attributes */ - RTPS_DllAPI virtual void updateAttributes( + FASTDDS_EXPORTED_API virtual void updateAttributes( const WriterAttributes& att) = 0; /** * Get Min Seq Num in History. * @return Minimum sequence number in history */ - RTPS_DllAPI SequenceNumber_t get_seq_num_min(); + FASTDDS_EXPORTED_API SequenceNumber_t get_seq_num_min(); /** * Get Max Seq Num in History. * @return Maximum sequence number in history */ - RTPS_DllAPI SequenceNumber_t get_seq_num_max(); + FASTDDS_EXPORTED_API SequenceNumber_t get_seq_num_max(); /** * Get maximum size of the serialized type * @return Maximum size of the serialized type */ - RTPS_DllAPI uint32_t getTypeMaxSerialized(); + FASTDDS_EXPORTED_API uint32_t getTypeMaxSerialized(); //!Get maximum size of the data uint32_t getMaxDataSize(); @@ -276,12 +273,12 @@ class RTPSWriter * Get listener * @return Listener */ - RTPS_DllAPI inline WriterListener* getListener() + FASTDDS_EXPORTED_API inline WriterListener* getListener() { return mp_listener; } - RTPS_DllAPI inline bool set_listener( + FASTDDS_EXPORTED_API inline bool set_listener( WriterListener* listener) { mp_listener = listener; @@ -292,7 +289,7 @@ class RTPSWriter * Get the publication mode * @return publication mode */ - RTPS_DllAPI inline bool isAsync() const + FASTDDS_EXPORTED_API inline bool isAsync() const { return is_async_; } @@ -302,7 +299,7 @@ class RTPSWriter * @param max Maximum number of changes to remove. * @return at least one change has been removed */ - RTPS_DllAPI bool remove_older_changes( + FASTDDS_EXPORTED_API bool remove_older_changes( unsigned int max = 0); /** @@ -311,7 +308,7 @@ class RTPSWriter * @return Best effort writers always return false. * Reliable writers override this method. */ - RTPS_DllAPI virtual bool get_disable_positive_acks() const + FASTDDS_EXPORTED_API virtual bool get_disable_positive_acks() const { return false; } @@ -345,7 +342,7 @@ class RTPSWriter * @param listener * @return true if successfully added */ - RTPS_DllAPI bool add_statistics_listener( + FASTDDS_EXPORTED_API bool add_statistics_listener( std::shared_ptr listener); /** @@ -353,7 +350,7 @@ class RTPSWriter * @param listener * @return true if successfully removed */ - RTPS_DllAPI bool remove_statistics_listener( + FASTDDS_EXPORTED_API bool remove_statistics_listener( std::shared_ptr listener); /** @@ -361,7 +358,7 @@ class RTPSWriter * * @param enabled_writers The new mask to set */ - RTPS_DllAPI void set_enabled_statistics_writers_mask( + FASTDDS_EXPORTED_API void set_enabled_statistics_writers_mask( uint32_t enabled_writers); /** @@ -370,7 +367,7 @@ class RTPSWriter * @param [out] connection_list of the writer * @return True if could be retrieved */ - RTPS_DllAPI virtual bool get_connections( + FASTDDS_EXPORTED_API virtual bool get_connections( fastdds::statistics::rtps::ConnectionList& connection_list) = 0; #endif // FASTDDS_STATISTICS diff --git a/include/fastdds/rtps/writer/ReaderProxy.h b/include/fastdds/rtps/writer/ReaderProxy.h index 2610e988ce2..39112baf6eb 100644 --- a/include/fastdds/rtps/writer/ReaderProxy.h +++ b/include/fastdds/rtps/writer/ReaderProxy.h @@ -34,7 +34,7 @@ #include #include -#include +#include #include #include diff --git a/include/fastdds/rtps/writer/StatefulWriter.h b/include/fastdds/rtps/writer/StatefulWriter.h index 04207f2838b..64e8599f15d 100644 --- a/include/fastdds/rtps/writer/StatefulWriter.h +++ b/include/fastdds/rtps/writer/StatefulWriter.h @@ -29,7 +29,7 @@ #include #include #include -#include +#include namespace eprosima { namespace fastrtps { diff --git a/include/fastdds/rtps/writer/StatelessWriter.h b/include/fastdds/rtps/writer/StatelessWriter.h index 9fdaa368852..98c117d95d4 100644 --- a/include/fastdds/rtps/writer/StatelessWriter.h +++ b/include/fastdds/rtps/writer/StatelessWriter.h @@ -27,7 +27,7 @@ #include #include #include -#include +#include #include #include diff --git a/include/fastdds/rtps/writer/WriterDiscoveryInfo.h b/include/fastdds/rtps/writer/WriterDiscoveryInfo.h index c3a1ae2b8b8..9167f72a09a 100644 --- a/include/fastdds/rtps/writer/WriterDiscoveryInfo.h +++ b/include/fastdds/rtps/writer/WriterDiscoveryInfo.h @@ -18,7 +18,7 @@ #ifndef _RTPS_WRITER_WRITERDISCOVERYINFO_H_ #define _RTPS_WRITER_WRITERDISCOVERYINFO_H_ -#include +#include #include namespace eprosima { @@ -36,7 +36,7 @@ struct WriterDiscoveryInfo //!Enum DISCOVERY_STATUS, four different status for discovered writers. //!@ingroup RTPS_MODULE #if defined(_WIN32) - enum RTPS_DllAPI DISCOVERY_STATUS + enum FASTDDS_EXPORTED_API DISCOVERY_STATUS #else enum DISCOVERY_STATUS #endif // if defined(_WIN32) @@ -65,8 +65,8 @@ struct WriterDiscoveryInfo const WriterProxyData& info; }; -} -} -} +} // namespace rtps +} // namespace fastrtps +} // namespace eprosima #endif // _RTPS_WRITER_WRITERDISCOVERYINFO_H_ diff --git a/include/fastdds/rtps/writer/WriterListener.h b/include/fastdds/rtps/writer/WriterListener.h index 4dbd52290de..8932c7d99b9 100644 --- a/include/fastdds/rtps/writer/WriterListener.h +++ b/include/fastdds/rtps/writer/WriterListener.h @@ -37,7 +37,7 @@ struct CacheChange_t; * Class WriterListener with virtual method so the user can implement callbacks to certain events. * @ingroup WRITER_MODULE */ -class RTPS_DllAPI WriterListener +class FASTDDS_EXPORTED_API WriterListener { public: diff --git a/include/fastdds/statistics/dds/domain/DomainParticipant.hpp b/include/fastdds/statistics/dds/domain/DomainParticipant.hpp index 5f254c9af36..e5ab3a6f559 100644 --- a/include/fastdds/statistics/dds/domain/DomainParticipant.hpp +++ b/include/fastdds/statistics/dds/domain/DomainParticipant.hpp @@ -22,12 +22,10 @@ #include +#include #include #include -#include -#include - -using eprosima::fastrtps::types::ReturnCode_t; +#include namespace eprosima { namespace fastrtps { @@ -66,7 +64,7 @@ class DomainParticipant : public eprosima::fastdds::dds::DomainParticipant * RETCODE_OK if the DataWriter has been created or if it has been created previously, * and RETCODE_ERROR otherwise */ - RTPS_DllAPI ReturnCode_t enable_statistics_datawriter( + FASTDDS_EXPORTED_API fastdds::dds::ReturnCode_t enable_statistics_datawriter( const std::string& topic_name, const eprosima::fastdds::dds::DataWriterQos& dwqos); @@ -81,7 +79,7 @@ class DomainParticipant : public eprosima::fastdds::dds::DomainParticipant * RETCODE_OK if the DataWriter has been created or if it has been created previously, * and RETCODE_ERROR otherwise */ - RTPS_DllAPI ReturnCode_t enable_statistics_datawriter_with_profile( + FASTDDS_EXPORTED_API fastdds::dds::ReturnCode_t enable_statistics_datawriter_with_profile( const std::string& profile_name, const std::string& topic_name); @@ -93,7 +91,7 @@ class DomainParticipant : public eprosima::fastdds::dds::DomainParticipant * RETCODE_OK if the DataWriter has been correctly deleted or does not exist, * and RETCODE_ERROR otherwise */ - RTPS_DllAPI ReturnCode_t disable_statistics_datawriter( + FASTDDS_EXPORTED_API fastdds::dds::ReturnCode_t disable_statistics_datawriter( const std::string& topic_name); /** @@ -102,7 +100,7 @@ class DomainParticipant : public eprosima::fastdds::dds::DomainParticipant * @return Reference to the Statistics DomainParticipant if successful. * nullptr otherwise. */ - RTPS_DllAPI static DomainParticipant* narrow( + FASTDDS_EXPORTED_API static DomainParticipant* narrow( eprosima::fastdds::dds::DomainParticipant* domain_participant); /** @@ -111,7 +109,7 @@ class DomainParticipant : public eprosima::fastdds::dds::DomainParticipant * @return Constant reference to the Statistics DomainParticipant if successful. * nullptr otherwise. */ - RTPS_DllAPI static const DomainParticipant* narrow( + FASTDDS_EXPORTED_API static const DomainParticipant* narrow( const eprosima::fastdds::dds::DomainParticipant* domain_participant); /** @@ -123,7 +121,7 @@ class DomainParticipant : public eprosima::fastdds::dds::DomainParticipant * * @note Not supported yet. Currently returns RETCODE_UNSUPPORTED */ - RTPS_DllAPI ReturnCode_t enable_monitor_service(); + FASTDDS_EXPORTED_API eprosima::fastdds::dds::ReturnCode_t enable_monitor_service(); /** * Disables the monitor service in this DomainParticipant. Does nothing if the service was not enabled before. @@ -135,7 +133,7 @@ class DomainParticipant : public eprosima::fastdds::dds::DomainParticipant * * @note Not supported yet. Currently returns RETCODE_UNSUPPORTED */ - RTPS_DllAPI ReturnCode_t disable_monitor_service(); + FASTDDS_EXPORTED_API eprosima::fastdds::dds::ReturnCode_t disable_monitor_service(); /** * fills in the ParticipantProxyData from a MonitorService Message @@ -146,7 +144,7 @@ class DomainParticipant : public eprosima::fastdds::dds::DomainParticipant * @return RETCODE_OK if the operation succeeds. * @return RETCODE_ERROR if the operation fails. */ - RTPS_DllAPI ReturnCode_t fill_discovery_data_from_cdr_message( + FASTDDS_EXPORTED_API eprosima::fastdds::dds::ReturnCode_t fill_discovery_data_from_cdr_message( fastrtps::rtps::ParticipantProxyData& data, statistics::MonitorServiceStatusData& msg); @@ -159,7 +157,7 @@ class DomainParticipant : public eprosima::fastdds::dds::DomainParticipant * @return RETCODE_OK if the operation succeeds. * @return RETCODE_ERROR if the operation fails. */ - RTPS_DllAPI ReturnCode_t fill_discovery_data_from_cdr_message( + FASTDDS_EXPORTED_API eprosima::fastdds::dds::ReturnCode_t fill_discovery_data_from_cdr_message( fastrtps::rtps::WriterProxyData& data, statistics::MonitorServiceStatusData& msg); @@ -172,7 +170,7 @@ class DomainParticipant : public eprosima::fastdds::dds::DomainParticipant * @return RETCODE_OK if the operation succeeds. * @return RETCODE_ERROR if the operation fails. */ - RTPS_DllAPI ReturnCode_t fill_discovery_data_from_cdr_message( + FASTDDS_EXPORTED_API eprosima::fastdds::dds::ReturnCode_t fill_discovery_data_from_cdr_message( fastrtps::rtps::ReaderProxyData& data, statistics::MonitorServiceStatusData& msg); @@ -185,7 +183,7 @@ class DomainParticipant : public eprosima::fastdds::dds::DomainParticipant * @return RETCODE_OK if the operation succeeds. * @return RETCODE_ERROR if the operation fails. */ - RTPS_DllAPI ReturnCode_t fill_discovery_data_from_cdr_message( + FASTDDS_EXPORTED_API eprosima::fastdds::dds::ReturnCode_t fill_discovery_data_from_cdr_message( fastrtps::rtps::ParticipantProxyData& data, const statistics::MonitorServiceStatusData& msg); @@ -198,7 +196,7 @@ class DomainParticipant : public eprosima::fastdds::dds::DomainParticipant * @return RETCODE_OK if the operation succeeds. * @return RETCODE_ERROR if the operation fails. */ - RTPS_DllAPI ReturnCode_t fill_discovery_data_from_cdr_message( + FASTDDS_EXPORTED_API eprosima::fastdds::dds::ReturnCode_t fill_discovery_data_from_cdr_message( fastrtps::rtps::WriterProxyData& data, const statistics::MonitorServiceStatusData& msg); @@ -211,7 +209,7 @@ class DomainParticipant : public eprosima::fastdds::dds::DomainParticipant * @return RETCODE_OK if the operation succeeds. * @return RETCODE_ERROR if the operation fails. */ - RTPS_DllAPI ReturnCode_t fill_discovery_data_from_cdr_message( + FASTDDS_EXPORTED_API eprosima::fastdds::dds::ReturnCode_t fill_discovery_data_from_cdr_message( fastrtps::rtps::ReaderProxyData& data, const statistics::MonitorServiceStatusData& msg); diff --git a/include/fastdds/statistics/dds/publisher/qos/DataWriterQos.hpp b/include/fastdds/statistics/dds/publisher/qos/DataWriterQos.hpp index 2e286b3269c..d09696544d8 100644 --- a/include/fastdds/statistics/dds/publisher/qos/DataWriterQos.hpp +++ b/include/fastdds/statistics/dds/publisher/qos/DataWriterQos.hpp @@ -20,7 +20,7 @@ #define _FASTDDS_STATISTICS_DDS_PUBLISHER_QOS_DATAWRITERQOS_HPP_ #include -#include +#include namespace eprosima { namespace fastdds { @@ -39,7 +39,7 @@ class DataWriterQos : public eprosima::fastdds::dds::DataWriterQos /** * @brief Constructor */ - RTPS_DllAPI DataWriterQos(); + FASTDDS_EXPORTED_API DataWriterQos(); }; //! Constant to access default Statistics DataWriter Qos diff --git a/include/fastdds/statistics/dds/subscriber/qos/DataReaderQos.hpp b/include/fastdds/statistics/dds/subscriber/qos/DataReaderQos.hpp index 82bc22f8abb..d5bcc23a3c6 100644 --- a/include/fastdds/statistics/dds/subscriber/qos/DataReaderQos.hpp +++ b/include/fastdds/statistics/dds/subscriber/qos/DataReaderQos.hpp @@ -38,7 +38,7 @@ class DataReaderQos : public eprosima::fastdds::dds::DataReaderQos /** * @brief Constructor */ - RTPS_DllAPI DataReaderQos(); + FASTDDS_EXPORTED_API DataReaderQos(); }; /** @@ -53,7 +53,7 @@ class MonitorServiceDataReaderQos : public eprosima::fastdds::dds::DataReaderQos /** * @brief Constructor */ - RTPS_DllAPI MonitorServiceDataReaderQos(); + FASTDDS_EXPORTED_API MonitorServiceDataReaderQos(); }; //! Constant to access default Statistics DataReader Qos diff --git a/include/fastdds/statistics/monitorservice_types.idl b/include/fastdds/statistics/monitorservice_types.idl index ff4bc1393ef..5ae98a8160b 100644 --- a/include/fastdds/statistics/monitorservice_types.idl +++ b/include/fastdds/statistics/monitorservice_types.idl @@ -74,49 +74,50 @@ module statistics { typedef BaseStatus_s InconsistentTopicStatus_s; typedef BaseStatus_s SampleLostStatus_s; - enum StatusKind + module StatusKind { - PROXY, - CONNECTION_LIST, - INCOMPATIBLE_QOS, - INCONSISTENT_TOPIC, - LIVELINESS_LOST, - LIVELINESS_CHANGED, - DEADLINE_MISSED, - SAMPLE_LOST, - STATUSES_SIZE - }; - - union MonitorServiceData switch(StatusKind) + typedef unsigned long StatusKind; + + const StatusKind PROXY = 0; + const StatusKind CONNECTION_LIST = 1; + const StatusKind INCOMPATIBLE_QOS = 2; + const StatusKind INCONSISTENT_TOPIC = 3; + const StatusKind LIVELINESS_LOST = 4; + const StatusKind LIVELINESS_CHANGED = 5; + const StatusKind DEADLINE_MISSED = 6; + const StatusKind SAMPLE_LOST = 7; + const StatusKind STATUSES_SIZE = 8; + }; // module StatusKind + + union MonitorServiceData switch(StatusKind::StatusKind) { - case PROXY: + case StatusKind::PROXY: sequence entity_proxy; - case CONNECTION_LIST: + case StatusKind::CONNECTION_LIST: sequence connection_list; - case INCOMPATIBLE_QOS: + case StatusKind::INCOMPATIBLE_QOS: IncompatibleQoSStatus_s incompatible_qos_status; - case INCONSISTENT_TOPIC: + case StatusKind::INCONSISTENT_TOPIC: InconsistentTopicStatus_s inconsistent_topic_status; - case LIVELINESS_LOST: + case StatusKind::LIVELINESS_LOST: LivelinessLostStatus_s liveliness_lost_status; - case LIVELINESS_CHANGED: + case StatusKind::LIVELINESS_CHANGED: LivelinessChangedStatus_s liveliness_changed_status; - case DEADLINE_MISSED: + case StatusKind::DEADLINE_MISSED: DeadlineMissedStatus_s deadline_missed_status; - case SAMPLE_LOST: + case StatusKind::SAMPLE_LOST: SampleLostStatus_s sample_lost_status; - case STATUSES_SIZE: + case StatusKind::STATUSES_SIZE: octet statuses_size; }; struct MonitorServiceStatusData { @Key detail::GUID_s local_entity; - @Key StatusKind status_kind; + @Key StatusKind::StatusKind status_kind; MonitorServiceData value; }; }; // namespace statisitcs }; // namespace fastdds }; // namespace eprosima - diff --git a/include/fastdds/statistics/rtps/StatisticsCommon.hpp b/include/fastdds/statistics/rtps/StatisticsCommon.hpp index 359bc9c70e2..c40a57e8da0 100644 --- a/include/fastdds/statistics/rtps/StatisticsCommon.hpp +++ b/include/fastdds/statistics/rtps/StatisticsCommon.hpp @@ -26,7 +26,7 @@ #include #include #include -#include +#include namespace eprosima { diff --git a/include/fastdds/statistics/types.idl b/include/fastdds/statistics/types.idl index 907a62d2544..96654a165b0 100644 --- a/include/fastdds/statistics/types.idl +++ b/include/fastdds/statistics/types.idl @@ -119,54 +119,53 @@ struct PhysicalData string process; }; -@bit_bound(32) -bitmask EventKind +module EventKind { - @position(0) HISTORY2HISTORY_LATENCY, - @position(1) NETWORK_LATENCY, - @position(2) PUBLICATION_THROUGHPUT, - @position(3) SUBSCRIPTION_THROUGHPUT, - @position(4) RTPS_SENT, - @position(5) RTPS_LOST, - @position(6) RESENT_DATAS, - @position(7) HEARTBEAT_COUNT, - @position(8) ACKNACK_COUNT, - @position(9) NACKFRAG_COUNT, - @position(10) GAP_COUNT, - @position(11) DATA_COUNT, - @position(12) PDP_PACKETS, - @position(13) EDP_PACKETS, - @position(14) DISCOVERED_ENTITY, - @position(15) SAMPLE_DATAS, - @position(16) PHYSICAL_DATA + const unsigned long HISTORY2HISTORY_LATENCY = 0x1; + const unsigned long NETWORK_LATENCY = 0x2; + const unsigned long PUBLICATION_THROUGHPUT = 0x4; + const unsigned long SUBSCRIPTION_THROUGHPUT = 0x8; + const unsigned long RTPS_SENT = 0x10; + const unsigned long RTPS_LOST = 0x20; + const unsigned long RESENT_DATAS = 0x40; + const unsigned long HEARTBEAT_COUNT = 0x80; + const unsigned long ACKNACK_COUNT = 0x100; + const unsigned long NACKFRAG_COUNT = 0x200; + const unsigned long GAP_COUNT = 0x400; + const unsigned long DATA_COUNT = 0x800; + const unsigned long PDP_PACKETS = 0x1000; + const unsigned long EDP_PACKETS = 0x2000; + const unsigned long DISCOVERED_ENTITY = 0x4000; + const unsigned long SAMPLE_DATAS = 0x8000; + const unsigned long PHYSICAL_DATA = 0x10000; }; -union Data switch(EventKind) +union Data switch(unsigned long) { - case HISTORY2HISTORY_LATENCY: + case EventKind::HISTORY2HISTORY_LATENCY: WriterReaderData writer_reader_data; - case NETWORK_LATENCY: + case EventKind::NETWORK_LATENCY: Locator2LocatorData locator2locator_data; - case PUBLICATION_THROUGHPUT: - case SUBSCRIPTION_THROUGHPUT: + case EventKind::PUBLICATION_THROUGHPUT: + case EventKind::SUBSCRIPTION_THROUGHPUT: EntityData entity_data; - case RTPS_SENT: - case RTPS_LOST: + case EventKind::RTPS_SENT: + case EventKind::RTPS_LOST: Entity2LocatorTraffic entity2locator_traffic; - case RESENT_DATAS: - case HEARTBEAT_COUNT: - case ACKNACK_COUNT: - case NACKFRAG_COUNT: - case GAP_COUNT: - case DATA_COUNT: - case PDP_PACKETS: - case EDP_PACKETS: + case EventKind::RESENT_DATAS: + case EventKind::HEARTBEAT_COUNT: + case EventKind::ACKNACK_COUNT: + case EventKind::NACKFRAG_COUNT: + case EventKind::GAP_COUNT: + case EventKind::DATA_COUNT: + case EventKind::PDP_PACKETS: + case EventKind::EDP_PACKETS: EntityCount entity_count; - case DISCOVERED_ENTITY: + case EventKind::DISCOVERED_ENTITY: DiscoveryTime discovery_time; - case SAMPLE_DATAS: + case EventKind::SAMPLE_DATAS: SampleIdentityCount sample_identity_count; - case PHYSICAL_DATA: + case EventKind::PHYSICAL_DATA: PhysicalData physical_data; }; diff --git a/include/fastrtps/utils/IPFinder.h b/include/fastdds/utils/IPFinder.h similarity index 86% rename from include/fastrtps/utils/IPFinder.h rename to include/fastdds/utils/IPFinder.h index c0ce5010975..1babd66fd4d 100644 --- a/include/fastrtps/utils/IPFinder.h +++ b/include/fastdds/utils/IPFinder.h @@ -20,12 +20,11 @@ #ifndef IPFINDER_H_ #define IPFINDER_H_ - - -#include #include +#include #include +#include #include namespace eprosima { @@ -81,7 +80,7 @@ class IPFinder IPFinder(); virtual ~IPFinder(); - RTPS_DllAPI static bool getIPs( + FASTDDS_EXPORTED_API static bool getIPs( std::vector* vec_name, bool return_loopback = false); @@ -89,36 +88,36 @@ class IPFinder * Get the IP4Adresses in all interfaces. * @param[out] locators List of locators to be populated with the IP4 addresses. */ - RTPS_DllAPI static bool getIP4Address( + FASTDDS_EXPORTED_API static bool getIP4Address( LocatorList_t* locators); /** * Get the IP6Adresses in all interfaces. * @param[out] locators List of locators to be populated with the IP6 addresses. */ - RTPS_DllAPI static bool getIP6Address( + FASTDDS_EXPORTED_API static bool getIP6Address( LocatorList_t* locators); /** * Get all IP Adresses in all interfaces. * @param[out] locators List of locators to be populated with the addresses. */ - RTPS_DllAPI static bool getAllIPAddress( + FASTDDS_EXPORTED_API static bool getAllIPAddress( LocatorList_t* locators); /** * Parses an IP4 string, populating a info_IP with its value. * @param[out] info info_IP to populate. * */ - RTPS_DllAPI static bool parseIP4( + FASTDDS_EXPORTED_API static bool parseIP4( info_IP& info); /** * Parses an IP6 string, populating a info_IP with its value. * @param[out] info info_IP to populate. * */ - RTPS_DllAPI static bool parseIP6( + FASTDDS_EXPORTED_API static bool parseIP6( info_IP& info); - RTPS_DllAPI static std::string getIPv4Address( + FASTDDS_EXPORTED_API static std::string getIPv4Address( const std::string& name); - RTPS_DllAPI static std::string getIPv6Address( + FASTDDS_EXPORTED_API static std::string getIPv6Address( const std::string& name); /** @@ -126,7 +125,7 @@ class IPFinder * Will return all unique MAC addresses for eadh of the interfaces returned by getAllIPAddress * @param[out] macs List of MAC addresses. */ - RTPS_DllAPI static bool getAllMACAddress( + FASTDDS_EXPORTED_API static bool getAllMACAddress( std::vector* macs); }; diff --git a/include/fastrtps/utils/IPLocator.h b/include/fastdds/utils/IPLocator.h similarity index 76% rename from include/fastrtps/utils/IPLocator.h rename to include/fastdds/utils/IPLocator.h index 656da36f3e7..d2df1cde930 100644 --- a/include/fastrtps/utils/IPLocator.h +++ b/include/fastdds/utils/IPLocator.h @@ -49,19 +49,19 @@ class IPLocator * @param portin Port of the locator. * @param locator Locator to be filled. */ - RTPS_DllAPI static void createLocator( + FASTDDS_EXPORTED_API static void createLocator( int32_t kindin, const std::string& address, uint32_t portin, Locator_t& locator); //! Sets locator's IPv4. - RTPS_DllAPI static bool setIPv4( + FASTDDS_EXPORTED_API static bool setIPv4( Locator_t& locator, const unsigned char* addr); //! Sets locator's IPv4. - RTPS_DllAPI static bool setIPv4( + FASTDDS_EXPORTED_API static bool setIPv4( Locator_t& locator, octet o1, octet o2, @@ -69,47 +69,47 @@ class IPLocator octet o4); //! Sets locator's IPv4. - RTPS_DllAPI static bool setIPv4( + FASTDDS_EXPORTED_API static bool setIPv4( Locator_t& locator, const std::string& ipv4); //! Copies locator's IPv4. - RTPS_DllAPI static bool setIPv4( + FASTDDS_EXPORTED_API static bool setIPv4( Locator_t& destlocator, const Locator_t& origlocator); //! Copies locator's IPv4. - RTPS_DllAPI static bool setIPv4address( + FASTDDS_EXPORTED_API static bool setIPv4address( Locator_t& destlocator, const std::string& lan, const std::string& wan, const std::string& ipv4); //! Retrieves locator's IPv4 as octet array. - RTPS_DllAPI static const octet* getIPv4( + FASTDDS_EXPORTED_API static const octet* getIPv4( const Locator_t& locator); //! Check if the locator has IPv4. - RTPS_DllAPI static bool hasIPv4( + FASTDDS_EXPORTED_API static bool hasIPv4( const Locator_t& locator); //! Returns a string representation of the locator's IPv4. - RTPS_DllAPI static std::string toIPv4string( + FASTDDS_EXPORTED_API static std::string toIPv4string( const Locator_t& locator); //! Copies locator's IPv4. - RTPS_DllAPI static bool copyIPv4( + FASTDDS_EXPORTED_API static bool copyIPv4( const Locator_t& locator, unsigned char* dest); // IPv6 //! Sets locator's IPv6. - RTPS_DllAPI static bool setIPv6( + FASTDDS_EXPORTED_API static bool setIPv6( Locator_t& locator, const unsigned char* addr); //! Sets locator's IPv6. - RTPS_DllAPI static bool setIPv6( + FASTDDS_EXPORTED_API static bool setIPv6( Locator_t& locator, uint16_t group0, uint16_t group1, @@ -121,63 +121,63 @@ class IPLocator uint16_t group7); //! Sets locator's IPv6. - RTPS_DllAPI static bool setIPv6( + FASTDDS_EXPORTED_API static bool setIPv6( Locator_t& locator, const std::string& ipv6); //! Copies locator's IPv6. - RTPS_DllAPI static bool setIPv6( + FASTDDS_EXPORTED_API static bool setIPv6( Locator_t& destlocator, const Locator_t& origlocator); //! Retrieves locator's IPv6 as octet array. - RTPS_DllAPI static const octet* getIPv6( + FASTDDS_EXPORTED_API static const octet* getIPv6( const Locator_t& locator); //! Check if the locator has IPv6. - RTPS_DllAPI static bool hasIPv6( + FASTDDS_EXPORTED_API static bool hasIPv6( const Locator_t& locator); //! Returns a string representation of the locator's IPv6 following RFC 5952 recommendation. - RTPS_DllAPI static std::string toIPv6string( + FASTDDS_EXPORTED_API static std::string toIPv6string( const Locator_t& locator); //! Copies locator's IPv6. - RTPS_DllAPI static bool copyIPv6( + FASTDDS_EXPORTED_API static bool copyIPv6( const Locator_t& locator, unsigned char* dest); //! Sets locator's IP - RTPS_DllAPI static bool ip( + FASTDDS_EXPORTED_API static bool ip( Locator_t& locator, const std::string& ip); //! Returns a string representation of the locator's IP. - RTPS_DllAPI static std::string ip_to_string( + FASTDDS_EXPORTED_API static std::string ip_to_string( const Locator_t& locator); // TCP //! Sets locator's logical port (as in RTCP protocol) - RTPS_DllAPI static bool setLogicalPort( + FASTDDS_EXPORTED_API static bool setLogicalPort( Locator_t& locator, uint16_t port); //! Gets locator's logical port (as in RTCP protocol) - RTPS_DllAPI static uint16_t getLogicalPort( + FASTDDS_EXPORTED_API static uint16_t getLogicalPort( const Locator_t& locator); //! Sets locator's physical port (as in RTCP protocol) - RTPS_DllAPI static bool setPhysicalPort( + FASTDDS_EXPORTED_API static bool setPhysicalPort( Locator_t& locator, uint16_t port); //! Gets locator's physical port (as in RTCP protocol) - RTPS_DllAPI static uint16_t getPhysicalPort( + FASTDDS_EXPORTED_API static uint16_t getPhysicalPort( const Locator_t& locator); // TCPv4 //! Sets locator's WAN address (as in RTCP protocol) - RTPS_DllAPI static bool setWan( + FASTDDS_EXPORTED_API static bool setWan( Locator_t& locator, octet o1, octet o2, @@ -185,96 +185,96 @@ class IPLocator octet o4); //! Sets locator's WAN address (as in RTCP protocol) - RTPS_DllAPI static bool setWan( + FASTDDS_EXPORTED_API static bool setWan( Locator_t& locator, const std::string& wan); //! Gets locator's WAN address (as in RTCP protocol) - RTPS_DllAPI static const octet* getWan( + FASTDDS_EXPORTED_API static const octet* getWan( const Locator_t& locator); //! Checks if the locator has WAN address (as in RTCP protocol) - RTPS_DllAPI static bool hasWan( + FASTDDS_EXPORTED_API static bool hasWan( const Locator_t& locator); //! Retrieves a string representation of the locator's WAN address (as in RTCP protocol) - RTPS_DllAPI static std::string toWanstring( + FASTDDS_EXPORTED_API static std::string toWanstring( const Locator_t& locator); //! This method is useful in the case of having a tcp client with an initial peer //! pointing to a WAN locator, and receiving a locator with LAN and WAN //! addresses (TCP Client from TCP Server) - RTPS_DllAPI static Locator_t WanToLanLocator( + FASTDDS_EXPORTED_API static Locator_t WanToLanLocator( const Locator_t& locator); //! Sets locator's LAN ID (as in RTCP protocol) - RTPS_DllAPI static bool setLanID( + FASTDDS_EXPORTED_API static bool setLanID( Locator_t& locator, const std::string& lanId); //! Gets locator's LAN ID (as in RTCP protocol) - RTPS_DllAPI static const octet* getLanID( + FASTDDS_EXPORTED_API static const octet* getLanID( const Locator_t& locator); //! Retrieves a string representation of the locator's LAN ID (as in RTCP protocol) - RTPS_DllAPI static std::string toLanIDstring( + FASTDDS_EXPORTED_API static std::string toLanIDstring( const Locator_t& locator); //! Returns a new locator without logical port (as in RTCP protocol). - RTPS_DllAPI static Locator_t toPhysicalLocator( + FASTDDS_EXPORTED_API static Locator_t toPhysicalLocator( const Locator_t& locator); //! Checks if a locator WAN address and IP address are the same (as in RTCP protocol). - RTPS_DllAPI static bool ip_equals_wan( + FASTDDS_EXPORTED_API static bool ip_equals_wan( const Locator_t& locator); // Common //! Sets locator's RTCP port. Physical for UDP and logical for TCP (as in RTCP protocol) - RTPS_DllAPI static bool setPortRTPS( + FASTDDS_EXPORTED_API static bool setPortRTPS( Locator_t& locator, uint16_t port); //! Gets locator's RTCP port. Physical for UDP and logical for TCP (as in RTCP protocol) - RTPS_DllAPI static uint16_t getPortRTPS( + FASTDDS_EXPORTED_API static uint16_t getPortRTPS( Locator_t& locator); //! Checks if a locator has local IP address. - RTPS_DllAPI static bool isLocal( + FASTDDS_EXPORTED_API static bool isLocal( const Locator_t& locator); //! Checks if a locator has any IP address. - RTPS_DllAPI static bool isAny( + FASTDDS_EXPORTED_API static bool isAny( const Locator_t& locator); //! Checks if both locators has the same IP address. - RTPS_DllAPI static bool compareAddress( + FASTDDS_EXPORTED_API static bool compareAddress( const Locator_t& loc1, const Locator_t& loc2, bool fullAddress = false); //! Checks if a both locators has the same IP address and physical port (as in RTCP protocol). - RTPS_DllAPI static bool compareAddressAndPhysicalPort( + FASTDDS_EXPORTED_API static bool compareAddressAndPhysicalPort( const Locator_t& loc1, const Locator_t& loc2); //! Returns a string representation of the given locator. - RTPS_DllAPI static std::string to_string( + FASTDDS_EXPORTED_API static std::string to_string( const Locator_t& locator); // UDP //! Checks if the locator has a multicast IP address. - RTPS_DllAPI static bool isMulticast( + FASTDDS_EXPORTED_API static bool isMulticast( const Locator_t& locator); //! Resolve an address name by a DNS request and return the IP that this address references by a DNS server - RTPS_DllAPI static std::pair, std::set> resolveNameDNS( + FASTDDS_EXPORTED_API static std::pair, std::set> resolveNameDNS( const std::string& address_name); //! Check whether a string contains an IPv4 format - RTPS_DllAPI static bool isIPv4( + FASTDDS_EXPORTED_API static bool isIPv4( const std::string& address); //! Check whether a string contains an IPv6 format - RTPS_DllAPI static bool isIPv6( + FASTDDS_EXPORTED_API static bool isIPv6( const std::string& address); protected: diff --git a/include/fastrtps/utils/TimedConditionVariable.hpp b/include/fastdds/utils/TimedConditionVariable.hpp similarity index 99% rename from include/fastrtps/utils/TimedConditionVariable.hpp rename to include/fastdds/utils/TimedConditionVariable.hpp index d2c4a795336..dbbb3e1267d 100644 --- a/include/fastrtps/utils/TimedConditionVariable.hpp +++ b/include/fastdds/utils/TimedConditionVariable.hpp @@ -18,7 +18,8 @@ #ifndef _UTILS_TIMEDCONDITIONVARIABLE_HPP_ #define _UTILS_TIMEDCONDITIONVARIABLE_HPP_ -#include + +#include /* NOTE: Windows implementation temporary disabled due to aleatory high CPU consumption when diff --git a/include/fastrtps/utils/TimedMutex.hpp b/include/fastdds/utils/TimedMutex.hpp similarity index 100% rename from include/fastrtps/utils/TimedMutex.hpp rename to include/fastdds/utils/TimedMutex.hpp diff --git a/include/fastrtps/utils/collections/ResourceLimitedContainerConfig.hpp b/include/fastdds/utils/collections/ResourceLimitedContainerConfig.hpp similarity index 100% rename from include/fastrtps/utils/collections/ResourceLimitedContainerConfig.hpp rename to include/fastdds/utils/collections/ResourceLimitedContainerConfig.hpp diff --git a/include/fastrtps/utils/collections/ResourceLimitedVector.hpp b/include/fastdds/utils/collections/ResourceLimitedVector.hpp similarity index 100% rename from include/fastrtps/utils/collections/ResourceLimitedVector.hpp rename to include/fastdds/utils/collections/ResourceLimitedVector.hpp diff --git a/include/fastrtps/utils/fixed_size_bitmap.hpp b/include/fastdds/utils/fixed_size_bitmap.hpp similarity index 100% rename from include/fastrtps/utils/fixed_size_bitmap.hpp rename to include/fastdds/utils/fixed_size_bitmap.hpp diff --git a/include/fastdds/utils/md5.h b/include/fastdds/utils/md5.h new file mode 100644 index 00000000000..20eda395745 --- /dev/null +++ b/include/fastdds/utils/md5.h @@ -0,0 +1,160 @@ +/* MD5 + converted to C++ class by Frank Thilo (thilo@unix-ag.org) + for bzflag (http://www.bzflag.org) + + based on: + + md5.h and md5.c + reference implementation of RFC 1321 + + Copyright (C) 1991-2, RSA Data Security, Inc. Created 1991. All + rights reserved. + + License to copy and use this software is granted provided that it + is identified as the "RSA Data Security, Inc. MD5 Message-Digest + Algorithm" in all material mentioning or referencing this software + or this function. + + License is also granted to make and use derivative works provided + that such works are identified as "derived from the RSA Data + Security, Inc. MD5 Message-Digest Algorithm" in all material + mentioning or referencing the derived work. + + RSA Data Security, Inc. makes no representations concerning either + the merchantability of this software or the suitability of this + software for any particular purpose. It is provided "as is" + without express or implied warranty of any kind. + + These notices must be retained in any copies of any part of this + documentation and/or software. + + */ + +#ifndef BZF_MD5_H +#define BZF_MD5_H + +#include +#include + +#include +/** + * Class MD5, for calculating MD5 hashes of strings or byte arrays + * it is not meant to be fast or secure + * + * usage: 1) feed it blocks of uchars with update() + * 2) finalize() + * 3) get hexdigest() string + * or + * MD5(std::string).hexdigest() + * + * assumes that char is 8 bit and int is 32 bit + * @ingroup UTILITIES_MODULE + */ +class FASTDDS_EXPORTED_API MD5 +{ +public: + + typedef unsigned char uint1; // 8bit + typedef unsigned int size_type; // must be 32bit + + MD5(); + MD5( + const std::string& text); + void update( + const unsigned char* buf, + size_type length); + void update( + const char* buf, + size_type length); + MD5& finalize(); + std::string hexdigest() const; + friend std::ostream& operator <<( + std::ostream&, + MD5& md5); + uint1 digest[16]; // the result + + void init(); + +private: + + typedef unsigned int uint4; // 32bit + enum + { + blocksize = 64 + }; // VC6 won't eat a const static int here + + void transform( + const uint1 block[blocksize]); + static void decode( + uint4 output[], + const uint1 input[], + size_type len); + static void encode( + uint1 output[], + const uint4 input[], + size_type len); + + bool finalized; + uint1 buffer[blocksize]; // bytes that didn't fit in last 64 byte chunk + uint4 count[2]; // 64bit counter for number of bits (lo, hi) + uint4 state[4]; // digest so far + + // low level logic operations + static inline uint4 F( + uint4 x, + uint4 y, + uint4 z); + static inline uint4 G( + uint4 x, + uint4 y, + uint4 z); + static inline uint4 H( + uint4 x, + uint4 y, + uint4 z); + static inline uint4 I( + uint4 x, + uint4 y, + uint4 z); + static inline uint4 rotate_left( + uint4 x, + int n); + static inline void FF( + uint4& a, + uint4 b, + uint4 c, + uint4 d, + uint4 x, + uint4 s, + uint4 ac); + static inline void GG( + uint4& a, + uint4 b, + uint4 c, + uint4 d, + uint4 x, + uint4 s, + uint4 ac); + static inline void HH( + uint4& a, + uint4 b, + uint4 c, + uint4 d, + uint4 x, + uint4 s, + uint4 ac); + static inline void II( + uint4& a, + uint4 b, + uint4 c, + uint4 d, + uint4 x, + uint4 s, + uint4 ac); +}; + +std::string md5( + const std::string str); + +#endif // ifndef BZF_MD5_H + diff --git a/include/fastrtps/Domain.h b/include/fastrtps/Domain.h deleted file mode 100644 index db99b55fcd4..00000000000 --- a/include/fastrtps/Domain.h +++ /dev/null @@ -1,251 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file Domain.h - * - */ - -#ifndef DOMAIN_H_ -#define DOMAIN_H_ - -#include -#include -#include - -#ifdef USE_DEPRECATION -#if defined(__GNUC__) || defined(__clang__) -#define DEPRECATED __attribute__ ((deprecated)) -#elif defined(_MSC_VER) -#define DEPRECATED __declspec(deprecated) -#else -#define DEPRECATED /** --Deprecated-- */ -#endif // if defined(__GNUC__) || defined(__clang__) -#else -#define DEPRECATED -#endif // ifdef USE_DEPRECATION - -namespace eprosima { -namespace fastrtps { - -class ParticipantListener; -class Participant; -class ParticipantImpl; -class Publisher; -class PublisherAttributes; -class PublisherListener; -class Subscriber; -class SubscriberAttributes; -class SubscriberListener; - -namespace types { -class DynamicPubSubType; -} // namespace types - -/** - * Class Domain, use to interact with the Publisher Subscriber API of the Fast RTPS implementation. - * @ingroup FASTRTPS_MODULE - */ -class Domain -{ -public: - - /** - * Create a Participant from a profile name. - * @param participant_profile Participant profile name. - * @param listen ParticipantListener Pointer. - * @return Participant pointer. (nullptr if not created.) - */ - RTPS_DllAPI DEPRECATED static Participant* createParticipant( - const std::string& participant_profile, - ParticipantListener* listen = nullptr); - - /** - * Create a Participant. - * @param att Participant Attributes. - * @param listen ParticipantListener Pointer. - * @return Participant pointer. (nullptr if not created.) - */ - RTPS_DllAPI DEPRECATED static Participant* createParticipant( - const ParticipantAttributes& att, - ParticipantListener* listen = nullptr); - - //!Fills participant_attributes with the default values. - RTPS_DllAPI static void getDefaultParticipantAttributes( - ParticipantAttributes& participant_attributes); - - /** - * Create a Publisher in a Participant from a profile name. - * @param part Pointer to the participant where you want to create the Publisher. - * @param publisher_profile Publisher profile name. - * @param listen Pointer to the PublisherListener. - * @return Pointer to the created Publisher (nullptr if not created). - */ - RTPS_DllAPI static Publisher* createPublisher( - Participant* part, - const std::string& publisher_profile, - PublisherListener* listen = nullptr); - - /** - * Create a Publisher in a Participant. - * @param part Pointer to the participant where you want to create the Publisher. - * @param att PublisherAttributes. - * @param listen Pointer to the PublisherListener. - * @return Pointer to the created Publisher (nullptr if not created). - */ - RTPS_DllAPI static Publisher* createPublisher( - Participant* part, - const PublisherAttributes& att, - PublisherListener* listen = nullptr); - - //!Fills publisher_attributes with the default values. - RTPS_DllAPI static void getDefaultPublisherAttributes( - PublisherAttributes& publisher_attributes); - - /** - * Create a Subscriber in a Participant from a profile name. - * @param part Pointer to the participant where you want to create the Publisher. - * @param subscriber_profile Subscriber profile name. - * @param listen Pointer to the SubscriberListener. - * @return Pointer to the created Subscriber (nullptr if not created). - */ - RTPS_DllAPI static Subscriber* createSubscriber( - Participant* part, - const std::string& subscriber_profile, - SubscriberListener* listen = nullptr); - - /** - * Create a Subscriber in a Participant. - * @param part Pointer to the participant where you want to create the Publisher. - * @param att SubscriberAttributes. - * @param listen Pointer to the SubscriberListener. - * @return Pointer to the created Subscriber (nullptr if not created). - */ - RTPS_DllAPI static Subscriber* createSubscriber( - Participant* part, - const SubscriberAttributes& att, - SubscriberListener* listen = nullptr); - - //!Fills subscriber_attributes with the default values. - RTPS_DllAPI static void getDefaultSubscriberAttributes( - SubscriberAttributes& subscriber_attributes); - - /** - * Remove a Participant and all associated publishers and subscribers. - * @param part Pointer to the participant. - * @return True if correctly removed. - */ - RTPS_DllAPI static bool removeParticipant( - Participant* part); - - /** - * Remove a Publisher. - * @param pub Pointer to the Publisher. - * @return True if correctly removed. - */ - RTPS_DllAPI static bool removePublisher( - Publisher* pub); - - /** - * Remove a Subscriber. - * @param sub Pointer to the Subscriber. - * @return True if correctly removed. - */ - RTPS_DllAPI static bool removeSubscriber( - Subscriber* sub); - - /** - * Return a registered type. - * @param part Pointer to the Participant. - * @param typeName Name of the type. - * @param type Returned type. - * @return True if type was found. - */ - RTPS_DllAPI static bool getRegisteredType( - Participant* part, - const char* typeName, - fastdds::dds::TopicDataType** type); - - /** - * Register a type in a participant. - * @param part Pointer to the Participant. - * @param type Pointer to the Type. - * @return True if correctly registered. - */ - RTPS_DllAPI static bool registerType( - Participant* part, - fastdds::dds::TopicDataType* type); - - /** - * Register a type in a participant. - * @param part Pointer to the Participant. - * @param type Pointer to the Type. - * @return True if correctly registered. - */ - RTPS_DllAPI static bool registerDynamicType( - Participant* part, - types::DynamicPubSubType* type); - - /** - * Unregister a type in a participant. - * @param part Pointer to the Participant. - * @param typeName Name of the type. - * @return True if correctly unregistered. - */ - RTPS_DllAPI static bool unregisterType( - Participant* part, - const char* typeName); - - /** - * Stop and remove all participants, publishers and subscribers in this Domain. - */ - RTPS_DllAPI static void stopAll(); - - /** - * Load profiles from XML file. - * @param xml_profile_file XML profile file. - * @return True if correctly loaded. - */ - RTPS_DllAPI static bool loadXMLProfilesFile( - const std::string& xml_profile_file); - - /** - * Load profiles from XML string. - * @param data buffer containing XML data. - * @param length length of data. - * @return True if correctly loaded. - */ - RTPS_DllAPI static bool loadXMLProfilesString( - const char* data, - size_t length); - -private: - - typedef std::pair t_p_Participant; - - Domain(); - - virtual ~Domain(); - - static std::mutex m_mutex; - - static std::vector m_participants; - - static bool default_xml_profiles_loaded; -}; - -} /* namespace */ -} /* namespace eprosima */ - -#endif /* DOMAIN_H_ */ diff --git a/include/fastrtps/attributes/TopicAttributes.h b/include/fastrtps/attributes/TopicAttributes.h deleted file mode 100644 index d02c082fe29..00000000000 --- a/include/fastrtps/attributes/TopicAttributes.h +++ /dev/null @@ -1,151 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file TopicAttributes.h - */ - -#ifndef TOPICPARAMETERS_H_ -#define TOPICPARAMETERS_H_ - -#include - -#include -#include - - -namespace eprosima { -namespace fastrtps{ - -/** - * Class TopicAttributes, used by the user to define the attributes of the topic associated with a Publisher or Subscriber. - * @ingroup FASTRTPS_ATTRIBUTES_MODULE - */ -class TopicAttributes -{ -public: - - /** - * Default constructor - */ - TopicAttributes() - : topicKind(rtps::NO_KEY) - , topicName("UNDEF") - , topicDataType("UNDEF") - , auto_fill_type_object(true) - , auto_fill_type_information(true) - { - } - - //!Constructor, you need to provide the topic name and the topic data type. - TopicAttributes( - const char* name, - const char* dataType, - rtps::TopicKind_t tKind= rtps::NO_KEY) - { - topicKind = tKind; - topicName = name; - topicDataType = dataType; - auto_fill_type_object = true; - auto_fill_type_information = true; - } - - virtual ~TopicAttributes() {} - - bool operator==(const TopicAttributes& b) const - { - return (this->topicKind == b.topicKind) && - (this->topicName == b.topicName) && - (this->topicDataType == b.topicDataType) && - (this->historyQos == b.historyQos); - } - - /** - * Get the topic data type - * @return Topic data type - */ - const string_255& getTopicDataType() const { - return topicDataType; - } - - /** - * Get the topic kind - * @return Topic kind - */ - rtps::TopicKind_t getTopicKind() const { - return topicKind; - } - - /** - * Get the topic name - * @return Topic name - */ - const string_255& getTopicName() const { - return topicName; - } - - //! TopicKind_t, default value NO_KEY. - rtps::TopicKind_t topicKind; - //! Topic Name. - string_255 topicName; - //!Topic Data Type. - string_255 topicDataType; - //!QOS Regarding the History to be saved. - HistoryQosPolicy historyQos; - //!QOS Regarding the resources to allocate. - ResourceLimitsQosPolicy resourceLimitsQos; - //!Type Identifier XTYPES 1.1 - TypeIdV1 type_id; - //!Type Object XTYPES 1.1 - TypeObjectV1 type; - //!XTYPES 1.2 - xtypes::TypeInformation type_information; - //!Tries to complete type identifier and type object (TypeObjectV1) - bool auto_fill_type_object; - //!Tries to complete type information (TypeObjectV2) - bool auto_fill_type_information; - - /** - * Method to check whether the defined QOS are correct. - * @return True if they are valid. - */ - bool checkQos() const; -}; - -#ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC - -/** - * Check if two topic attributes are not equal - * @param t1 First instance of TopicAttributes to compare - * @param t2 Second instance of TopicAttributes to compare - * @return True if the instances are not equal. False if the instances are equal. - */ -bool inline operator!=(const TopicAttributes& t1, const TopicAttributes& t2) -{ - if(t1.topicKind != t2.topicKind - || t1.topicName != t2.topicName - || t1.topicDataType != t2.topicDataType - || t1.historyQos.kind != t2.historyQos.kind - || (t1.historyQos.kind == KEEP_LAST_HISTORY_QOS && t1.historyQos.depth != t2.historyQos.depth)) - { - return true; - } - return false; -} -#endif - -} /* namespace fastrtps */ -} /* namespace eprosima */ - -#endif /* TOPICPARAMETERS_H_ */ diff --git a/include/fastrtps/attributes/all_attributes.h b/include/fastrtps/attributes/all_attributes.h deleted file mode 100644 index 6a4dfa84fba..00000000000 --- a/include/fastrtps/attributes/all_attributes.h +++ /dev/null @@ -1,29 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file all_attributes.h - */ - -#ifndef ALL_ATTRIBUTES_H_ -#define ALL_ATTRIBUTES_H_ - -#include -#include -#include -#include -#include -#include - -#endif /* ALL_ATTRIBUTES_H_ */ diff --git a/include/fastrtps/config/doxygen_modules.h b/include/fastrtps/config/doxygen_modules.h index 9df7c40aa50..de263a30fdc 100644 --- a/include/fastrtps/config/doxygen_modules.h +++ b/include/fastrtps/config/doxygen_modules.h @@ -22,30 +22,27 @@ //Description of doxygen modules, not used in actual code. /*! - * @defgroup FASTRTPS_GENERAL_API eProsima Fast RTPS API Reference - * @brief eProsima Fast RTPS API grouped in modules. + * @defgroup FASTDDS_GENERAL_API eProsima Fast DDS API Reference + * @brief eProsima Fast DDS API grouped in modules. */ - - /*! * @defgroup RTPS_MODULE RTPS - * @ingroup FASTRTPS_GENERAL_API + * @ingroup FASTDDS_GENERAL_API * @brief RTPS API * This is an implementation of the RTPS communication standard defined by the OMG. */ - /*! - * @defgroup FASTRTPS_MODULE Publisher Subscriber Public API - * @ingroup FASTRTPS_GENERAL_API - * @brief Publisher Subscriber Public API - * This Module contains the Publisher Subscriber Layer created to facilitate the use of the RTPS protocol. + * @defgroup FASTDDS_MODULE DDS Public API + * @ingroup FASTDDS_GENERAL_API + * @brief DDS Public API + * This Module contains the DDS Layer defined by the OMG. */ -/** @defgroup FASTRTPS_ATTRIBUTES_MODULE Fast RTPS Attributes Module. - * @ingroup FASTRTPS_MODULE - * @brief Attributes class used to define the public entities that the user should use to control this library. +/** @defgroup FASTDDS_QOS_MODULE Fast DDS Quality of Service (QoS) Module. + * @ingroup FASTDDS_MODULE + * @brief QOS class used to define the public entities that the user should use to control this library. */ /** @defgroup RTPS_ATTRIBUTES_MODULE RTPS Attributes Module. @@ -53,7 +50,6 @@ * @brief Attributes class used to define the public entities that the user should use to control this library. */ - /** @defgroup COMMON_MODULE Common Module. * @ingroup RTPS_MODULE * Common structures used by multiple elements. @@ -61,8 +57,7 @@ /** @defgroup NETWORK_MODULE Network Module * @ingroup RTPS_MODULE - * Includes the elements necessary to interface between the - * transport layer and the FastRTPS library. + * Includes the elements necessary to interface between the transport layer and the Fast DDS library. */ /** @defgroup TRANSPORT_MODULE Transport Module. @@ -98,9 +93,9 @@ */ /** @defgroup MANAGEMENT_MODULE Management Module - * @ingroup FASTRTPS_GENERAL_API - * This module contains classes and methods associated with the management of all other objects. The most important ones - * are the communication (ResourceSend and ResourceListen) and event (ResourceEvent) resources. + * @ingroup FASTDDS_GENERAL_API + * This module contains classes and methods associated with the management of all other objects. + * The most important ones are the communication (ResourceSend and ResourceListen) and event (ResourceEvent) resources. */ /** @defgroup BUILTIN_MODULE Builtin Protocols Module @@ -126,23 +121,18 @@ #endif // ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC /** @defgroup UTILITIES_MODULE Shared Utilities - * @ingroup FASTRTPS_GENERAL_API - * Shared utilities that can be used by one or more classes in different modules. They are not strictly part of the RTPS implementation - * but very useful to implement different functionalities. + * @ingroup FASTDDS_GENERAL_API + * Shared utilities that can be used by one or more classes in different modules. + * They are not strictly part of the RTPS implementation but very useful to implement different functionalities. */ /** * @namespace eprosima eProsima namespace. - * @ingroup FASTRTPS_GENERAL_API - */ - -/** - * @namespace eprosima::fastrtps Contains the publisher subscriber layer. - * @ingroup FASTRTPS_MODULE + * @ingroup FASTDDS_GENERAL_API */ /** - * @namespace eprosima::fastrtps::rtps Contains the RTPS protocol implementation + * @namespace eprosima::fastdds::rtps Contains the RTPS protocol implementation * @ingroup RTPS_MODULE */ diff --git a/include/fastrtps/fastrtps_all.h b/include/fastrtps/fastrtps_all.h deleted file mode 100644 index 7b63aa0ae72..00000000000 --- a/include/fastrtps/fastrtps_all.h +++ /dev/null @@ -1,54 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file rtps_all.h - * - */ - -#ifndef FASTRTPS_ALL_H_ -#define FASTRTPS_ALL_H_ - -//USER THIS HEADER TO CREATE RAPID PROTOTYPES AND TESTS -//DO NOT INCLUDE IN PROJETCTS WERE COMPILATION TIME OR SIZE IS REVELANT -//SINCE IT INCLUDES ALL NECESSARY HEADERS. - -#include - -#include - -#include -#include -#include -#include -#include -#include - - -#include -#include -#include - -#include -#include - -#include -#include - -#include - -#include - - -#endif /* FASTRTPS_ALL_H_ */ diff --git a/include/fastrtps/fastrtps_dll.h b/include/fastrtps/fastrtps_dll.h deleted file mode 100644 index b03190a9807..00000000000 --- a/include/fastrtps/fastrtps_dll.h +++ /dev/null @@ -1,69 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -#ifndef _FASTRTPS_FASTRTPS_DLL_H_ -#define _FASTRTPS_FASTRTPS_DLL_H_ - -#include - -// normalize macros -#if !defined(FASTRTPS_DYN_LINK) && !defined(FASTRTPS_STATIC_LINK) \ - && !defined(EPROSIMA_ALL_DYN_LINK) && !defined(EPROSIMA_ALL_STATIC_LINK) -#define FASTRTPS_STATIC_LINK -#endif - -#if defined(EPROSIMA_ALL_DYN_LINK) && !defined(FASTRTPS_DYN_LINK) -#define FASTRTPS_DYN_LINK -#endif - -#if defined(FASTRTPS_DYN_LINK) && defined(FASTRTPS_STATIC_LINK) -#error Must not define both FASTRTPS_DYN_LINK and FASTRTPS_STATIC_LINK -#endif - -#if defined(EPROSIMA_ALL_NO_LIB) && !defined(FASTRTPS_NO_LIB) -#define FASTRTPS_NO_LIB -#endif - -// enable dynamic linking - -#if defined(_WIN32) -#if defined(EPROSIMA_ALL_DYN_LINK) || defined(FASTRTPS_DYN_LINK) -#if defined(fastrtps_EXPORTS) -#define RTPS_DllAPI __declspec( dllexport ) -#else -#define RTPS_DllAPI __declspec( dllimport ) -#endif // FASTRTPS_SOURCE -#else -#define RTPS_DllAPI -#endif -#else -#define RTPS_DllAPI -#endif // _WIN32 - -// Auto linking. - -#if !defined(FASTRTPS_SOURCE) && !defined(EPROSIMA_ALL_NO_LIB) \ - && !defined(FASTRTPS_NO_LIB) - -// Set properties. -#define EPROSIMA_LIB_NAME fastrtps - -#if defined(EPROSIMA_ALL_DYN_LINK) || defined(FASTRTPS_DYN_LINK) -#define EPROSIMA_DYN_LINK -#endif - -#include -#endif // auto-linking disabled - -#endif // _fastrtps_fastrtps_DLL_H_ diff --git a/include/fastrtps/participant/Participant.h b/include/fastrtps/participant/Participant.h deleted file mode 100644 index cecd26f9aa0..00000000000 --- a/include/fastrtps/participant/Participant.h +++ /dev/null @@ -1,104 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file Participant.h - * - */ - -#ifndef PARTICIPANT_H_ -#define PARTICIPANT_H_ - -#include -#include - -#include - -namespace eprosima { -namespace fastrtps{ - -class ParticipantImpl; -class ParticipantAttributes; - -namespace rtps -{ - class WriterProxyData; - class ReaderProxyData; - class ResourceEvent; - class RTPSParticipant; -} - -/** - * Class Participant used to group Publishers and Subscribers into a single working unit. - * @ingroup FASTRTPS_MODULE - */ -class RTPS_DllAPI Participant -{ - public: - /** - * Get the rtps::GUID_t of the associated RTPSParticipant. - * @return rtps::GUID_t - */ - const rtps::GUID_t& getGuid() const; - - /** - * Get the ParticipantAttributes. - * @return ParticipantAttributes. - */ - const ParticipantAttributes& getAttributes() const; - - /** - * Called when using a StaticEndpointDiscovery mechanism different that the one - * included in FastRTPS, for example when communicating with other implementations. - * It indicates to the Participant that an Endpoint from the XML has been discovered and - * should be activated. - * @param partguid Participant rtps::GUID_t. - * @param userId User defined ID as shown in the XML file. - * @param kind EndpointKind (WRITER or READER) - * @return True if correctly found and activated. - */ - bool newRemoteEndpointDiscovered( - const rtps::GUID_t& partguid, - uint16_t userId, - rtps::EndpointKind_t kind); - - /** - * Returns a list with the participant names. - * @return list of participant names. - */ - std::vector getParticipantNames() const; - - /** - * @brief Asserts liveliness of manual by participant publishers - */ - void assert_liveliness(); - - rtps::ResourceEvent& get_resource_event() const; - - private: - Participant(); - - virtual ~Participant(); - - ParticipantImpl* mp_impl; - - friend class Domain; - - friend class ParticipantImpl; -}; - -} -} /* namespace eprosima */ - -#endif /* PARTICIPANT_H_ */ diff --git a/include/fastrtps/participant/ParticipantListener.h b/include/fastrtps/participant/ParticipantListener.h deleted file mode 100644 index cde1fec1602..00000000000 --- a/include/fastrtps/participant/ParticipantListener.h +++ /dev/null @@ -1,88 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file ParticipantListener.h - * - */ - -#ifndef __PARTICIPANT_PARTICIPANTLISTENER_H__ -#define __PARTICIPANT_PARTICIPANTLISTENER_H__ - -#include -#include -#include - -namespace eprosima { -namespace fastrtps { - -class Participant; - -/** - * Class ParticipantListener, overrides behaviour towards certain events. - * @ingroup FASTRTPS_MODULE - */ -class ParticipantListener -{ - public: - - ParticipantListener() {} - - virtual ~ParticipantListener() {} - - /*! - * This method is called when a new Participant is discovered, or a previously discovered participant changes - * its QOS or is removed. - * @param participant Pointer to the Participant which discovered the remote participant. - * @param info Remote participant information. User can take ownership of the object. - */ - virtual void onParticipantDiscovery(Participant* participant, rtps::ParticipantDiscoveryInfo&& info) - { - (void)participant, (void)info; - } - -#if HAVE_SECURITY - virtual void onParticipantAuthentication(Participant* participant, rtps::ParticipantAuthenticationInfo&& info) - { - (void)participant, (void)info; - } -#endif - - /*! - * This method is called when a new Subscriber is discovered, or a previously discovered subscriber changes - * its QOS or is removed. - * @param participant Pointer to the Participant which discovered the remote subscriber. - * @param info Remote subscriber information. User can take ownership of the object. - */ - virtual void onSubscriberDiscovery(Participant* participant, rtps::ReaderDiscoveryInfo&& info) - { - (void)participant, (void)info; - } - - /*! - * This method is called when a new Publisher is discovered, or a previously discovered publisher changes - * its QOS or is removed. - * @param participant Pointer to the Participant which discovered the remote publisher. - * @param info Remote publisher information. User can take ownership of the object. - */ - virtual void onPublisherDiscovery(Participant* participant, rtps::WriterDiscoveryInfo&& info) - { - (void)participant, (void)info; - } -}; - -} // namespace fastrtps -} // namespace eprosima - -#endif // __PARTICIPANT_PARTICIPANTLISTENER_H__ diff --git a/include/fastrtps/publisher/Publisher.h b/include/fastrtps/publisher/Publisher.h deleted file mode 100644 index 7f2ca22d864..00000000000 --- a/include/fastrtps/publisher/Publisher.h +++ /dev/null @@ -1,192 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file Publisher.h - * - */ - -#ifndef PUBLISHER_H_ -#define PUBLISHER_H_ - -#include -#include -#include -#include -#include -#include - -namespace eprosima { -namespace fastrtps { - -namespace rtps { -struct GUID_t; -class WriteParams; -class RTPSParticipant; -} // namespace rtps - -class Participant; -class PublisherImpl; - -/** - * Class Publisher, used to send data to associated subscribers. - * @ingroup FASTRTPS_MODULE - */ -class RTPS_DllAPI Publisher -{ - friend class PublisherImpl; - virtual ~Publisher(); - -public: - - /** - * Constructor from a PublisherImpl pointer - * @param pimpl Actual implementation of the publisher - */ - Publisher( - PublisherImpl* pimpl); - - /*! - * @brief Writes a sample of the topic. - * @param sample Pointer to the sample. - * @return true when operation works successfully. - * @note This method is blocked for a period of time. - * ReliabilityQosPolicy.max_blocking_time on PublisherAttributes defines this period of time. - * @par Calling example: - * @snippet fastrtps_example.cpp ex_PublisherWrite - */ - bool write( - void* sample); - - /*! - * @brief Writes a sample of the topic with additional options. - * @param sample Pointer to the sample. - * @param wparams Extra write parameters. - * @return true when operation works successfully. - * @note This method is blocked for a period of time. - * ReliabilityQosPolicy.max_blocking_time on PublisherAttributes defines this period of time. - * @par Calling example: - * @snippet fastrtps_example.cpp ex_PublisherWrite - */ - bool write( - void* sample, - rtps::WriteParams& wparams); - - /*! - * @brief Informs that the application will be modifying a particular instance. - * It gives and opportunity to the middleware to pre-configure itself to improve performance. - * @param[in] instance Sample used to get the instance's key. - * @return Handle containing the instance's key. - * This handle could be used in successive `write` or `dispose` operations. - * In case of error, HANDLE_NIL will be returned. - */ - fastrtps::rtps::InstanceHandle_t register_instance( - void* instance); - - /*! - * @brief Requests the middleware to delete the instance. - * Applications are made aware of the deletion through the DataReader objects. - * @param[in] data Sample used to deduce instance's key in case of `handle` parameter is HANDLE_NIL. - * @param[in] handle Instance's key to be unregistered. - * @return Returns the operation's result. - * If the operation finishes successfully, `true` is returned. - */ - bool dispose( - void* data, - const rtps::InstanceHandle_t& handle); - /*! - * @brief This operation reserves the action of `register_instance`. - * Informs the middleware that the DataWriter is not intending to modify any more of that data instance. - * Also indicates that the middleware can locally remove all information regarding that instance. - * @param[in] instance Sample used to deduce instance's key in case of `handle` parameter is HANDLE_NIL. - * @param[in] handle Instance's key to be unregistered. - * @return Returns the operation's result. - * If the operation finishes successfully, `true` is returned. - */ - bool unregister_instance( - void* instance, - const rtps::InstanceHandle_t& handle); - - /** - * Remove all the Changes in the associated RTPSWriter. - * @param[out] removed Number of elements removed - * @return True if all elements were removed. - */ - bool removeAllChange( - size_t* removed = nullptr); - - /** - * Waits until all changes were acknowledged or max_wait. - * @param max_wait Maximum time to wait until all changes are acknowledged. - * @return True if all were acknowledged. - */ - bool wait_for_all_acked( - const Duration_t& max_wait); - - /** - * Get the GUID_t of the associated RTPSWriter. - * @return GUID_t. - */ - const rtps::GUID_t& getGuid(); - - /** - * Get the Attributes of the Publisher. - * @return Attributes of the publisher - */ - const PublisherAttributes& getAttributes() const; - - /** - * Update the Attributes of the publisher. - * @param att Reference to a PublisherAttributes object to update the parameters. - * @return True if correctly updated, false if ANY of the updated parameters cannot be updated. - */ - bool updateAttributes( - const PublisherAttributes& att); - - /** - * @brief Returns the offered deadline missed status - * @param status missed status struct - */ - void get_offered_deadline_missed_status( - OfferedDeadlineMissedStatus& status); - - /** - * @brief Asserts liveliness - */ - void assert_liveliness(); - - /** - * @brief Returns the liveliness lost status - * @param status Liveliness lost status - */ - void get_liveliness_lost_status( - LivelinessLostStatus& status); - - /** - * Get the list of locators from which this publisher may send data. - * - * @param [out] locators LocatorList_t where the list of locators will be stored. - */ - void get_sending_locators( - rtps::LocatorList_t& locators) const; - -private: - - PublisherImpl* mp_impl; -}; - -} /* namespace fastrtps */ -} /* namespace eprosima */ - -#endif /* PUBLISHER_H_ */ diff --git a/include/fastrtps/publisher/PublisherHistory.h b/include/fastrtps/publisher/PublisherHistory.h deleted file mode 100644 index 3198b650d2d..00000000000 --- a/include/fastrtps/publisher/PublisherHistory.h +++ /dev/null @@ -1,206 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file PublisherHistory.h - * - */ - -#ifndef PUBLISHERHISTORY_H_ -#define PUBLISHERHISTORY_H_ -#ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC - -#include -#include - -#include -#include -#include -#include -#include -#include -#include - -namespace eprosima { -namespace fastrtps { - -/** - * Class PublisherHistory, implementing a WriterHistory with support for keyed topics and HistoryQOS. - * This class is created by the PublisherImpl and should not be used by the user directly. - * @ingroup FASTRTPS_MODULE - */ -class PublisherHistory : public rtps::WriterHistory -{ -public: - - /** - * Constructor of the PublisherHistory. - * @param topic_att TopicAttributed - * @param payloadMax Maximum payload size. - * @param mempolicy Set whether the payloads ccan dynamically resized or not. - */ - PublisherHistory( - const TopicAttributes& topic_att, - uint32_t payloadMax, - rtps::MemoryManagementPolicy_t mempolicy); - - virtual ~PublisherHistory(); - - /** - * Rebuild instances loaded from DB. Does nothing if the topic doesn't have key. - */ - void rebuild_instances(); - - /*! - * @brief Tries to reserve resources for the new instance. - * @param instance_handle Instance's key. - * @param lock Lock which should be unlock in case the operation has to wait. - * @param max_blocking_time Maximum time the operation should be waiting. - * @return True if resources was reserved successfully. - */ - bool register_instance( - const rtps::InstanceHandle_t& instance_handle, - std::unique_lock& lock, - const std::chrono::time_point& max_blocking_time); - - /** - * Add a change comming from the Publisher. - * @param change Pointer to the change - * @param wparams Extra write parameters. - * @param lock - * @param max_blocking_time - * @return True if added. - */ - bool add_pub_change( - rtps::CacheChange_t* change, - rtps::WriteParams& wparams, - std::unique_lock& lock, - const std::chrono::time_point& max_blocking_time); - - /** - * Remove all change from the associated history. - * @param removed Number of elements removed. - * @return True if all elements were removed. - */ - bool removeAllChange( - size_t* removed); - - /** - * Remove the change with the minimum sequence Number. - * @return True if removed. - */ - bool removeMinChange(); - - /** - * Remove a change by the publisher History. - * @param change Pointer to the CacheChange_t. - * @return True if removed. - */ - bool remove_change_pub( - rtps::CacheChange_t* change); - - bool remove_change_g( - rtps::CacheChange_t* a_change) override; - - bool remove_change_g( - rtps::CacheChange_t* a_change, - const std::chrono::time_point& max_blocking_time) override; - - bool remove_instance_changes( - const rtps::InstanceHandle_t& handle, - const rtps::SequenceNumber_t& seq_up_to); - - /** - * @brief Sets the next deadline for the given instance - * @param handle The instance handle - * @param next_deadline_us The time point when the deadline will occur - * @return True if deadline was set successfully - */ - bool set_next_deadline( - const rtps::InstanceHandle_t& handle, - const std::chrono::steady_clock::time_point& next_deadline_us); - - /** - * @brief Returns the deadline for the instance that is next going to 'expire' - * @param handle The handle for the instance that will next miss the deadline - * @param next_deadline_us The time point when the deadline will occur - * @return True if deadline could be retrieved for the given instance - */ - bool get_next_deadline( - rtps::InstanceHandle_t& handle, - std::chrono::steady_clock::time_point& next_deadline_us); - - /*! - * @brief Checks if the instance's key is registered. - * @param[in] handle Instance's key. - * return `true` if instance's key is registered in the history. - */ - bool is_key_registered( - const rtps::InstanceHandle_t& handle); - - /** - * Waits till the last change in the instance history has been acknowledged. - * @param handle Instance's handle. - * @param lock Lock which should be unlock in case the operation has to wait. - * @param max_blocking_time Maximum time the operation should be waiting. - * @return true when the last change of the instance history is acknowleged, false when timeout is reached. - */ - bool wait_for_acknowledgement_last_change( - const rtps::InstanceHandle_t& handle, - std::unique_lock& lock, - const std::chrono::time_point& max_blocking_time); - -private: - - typedef std::map t_m_Inst_Caches; - - //!Map where keys are instance handles and values are vectors of cache changes associated - t_m_Inst_Caches keyed_changes_; - //!Time point when the next deadline will occur (only used for topics with no key) - std::chrono::steady_clock::time_point next_deadline_us_; - //!HistoryQosPolicy values. - HistoryQosPolicy history_qos_; - //!ResourceLimitsQosPolicy values. - ResourceLimitsQosPolicy resource_limited_qos_; - //!Topic Attributes - TopicAttributes topic_att_; - - /** - * @brief Method that finds a key in m_keyedChanges or tries to add it if not found - * @param instance_handle Instance of the key. - * @param map_it A map iterator to the given key - * @return True if the key was found or could be added to the map - */ - bool find_or_add_key( - const rtps::InstanceHandle_t& instance_handle, - t_m_Inst_Caches::iterator* map_it); - - /** - * Add a change comming from the Publisher. - * @param change Pointer to the change - * @param lock - * @param max_blocking_time - * @return True if added. - */ - bool prepare_change( - rtps::CacheChange_t* change, - std::unique_lock& lock, - const std::chrono::time_point& max_blocking_time); -}; - -} /* namespace fastrtps */ -} /* namespace eprosima */ - -#endif // ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC -#endif // PUBLISHERHISTORY_H_ diff --git a/include/fastrtps/publisher/PublisherListener.h b/include/fastrtps/publisher/PublisherListener.h deleted file mode 100644 index 04107aa2dcf..00000000000 --- a/include/fastrtps/publisher/PublisherListener.h +++ /dev/null @@ -1,92 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file PublisherListener.h - */ - -#ifndef PUBLISHERLISTENER_H_ -#define PUBLISHERLISTENER_H_ - -#include -#include -#include - -namespace eprosima { -namespace fastrtps { - -class Publisher; - -/** - * Class PublisherListener, allows the end user to implement callbacks triggered by certain events. - * @ingroup FASTRTPS_MODULE - * @snippet fastrtps_example.cpp ex_PublisherListener - */ -class RTPS_DllAPI PublisherListener -{ -public: - - PublisherListener() - { - } - - virtual ~PublisherListener() - { - } - - /** - * This method is called when the Publisher is matched (or unmatched) against an endpoint. - * @param pub Pointer to the associated Publisher - * @param info Information regarding the matched subscriber - */ - virtual void onPublicationMatched( - Publisher* pub, - rtps::MatchingInfo& info) - { - (void)pub; - (void)info; - } - - /** - * A method called when a deadline is missed - * @param pub Pointer to the associated Publisher - * @param status The deadline missed status - */ - virtual void on_offered_deadline_missed( - Publisher* pub, - const OfferedDeadlineMissedStatus& status) - { - (void)pub; - (void)status; - } - - /** - * @brief Method called when the liveliness of a publisher is lost - * @param pub The publisher - * @param status The liveliness lost status - */ - virtual void on_liveliness_lost( - Publisher* pub, - const LivelinessLostStatus& status) - { - (void)pub; - (void)status; - } - -}; - -} /* namespace rtps */ -} /* namespace eprosima */ - -#endif /* PUBLISHERLISTENER_H_ */ diff --git a/include/fastrtps/qos/ParameterTypes.h b/include/fastrtps/qos/ParameterTypes.h index cdcf8d333c9..e48a319b42f 100644 --- a/include/fastrtps/qos/ParameterTypes.h +++ b/include/fastrtps/qos/ParameterTypes.h @@ -20,13 +20,12 @@ #define PARAMETERTYPES_H_ #ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC -#include +#include +#include #include #include -#include - #if HAVE_SECURITY #include #include diff --git a/include/fastrtps/qos/QosPolicies.h b/include/fastrtps/qos/QosPolicies.h index 940371b8c89..5c1348e16b1 100644 --- a/include/fastrtps/qos/QosPolicies.h +++ b/include/fastrtps/qos/QosPolicies.h @@ -103,7 +103,7 @@ using TypeIdV1 = fastdds::dds::TypeIdV1; using TypeObjectV1 = fastdds::dds::TypeObjectV1; namespace xtypes { -using TypeInformation = fastdds::dds::xtypes::TypeInformation; +using TypeInformationParameter = fastdds::dds::xtypes::TypeInformationParameter; } //namespace xtypes } // namespace fastrtps diff --git a/include/fastrtps/rtps/builtin/BuiltinProtocols.h b/include/fastrtps/rtps/builtin/BuiltinProtocols.h deleted file mode 100644 index ea38baed60e..00000000000 --- a/include/fastrtps/rtps/builtin/BuiltinProtocols.h +++ /dev/null @@ -1,25 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file BuiltinProtocols.h - * - */ - -#ifndef BUILTINPROTOCOLS_H_ -#define BUILTINPROTOCOLS_H_ - -#include - -#endif /* BUILTINPROTOCOLS_H_ */ diff --git a/include/fastrtps/rtps/builtin/discovery/endpoint/EDP.h b/include/fastrtps/rtps/builtin/discovery/endpoint/EDP.h deleted file mode 100644 index 4d125388162..00000000000 --- a/include/fastrtps/rtps/builtin/discovery/endpoint/EDP.h +++ /dev/null @@ -1,25 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file EDP.h - * - */ - -#ifndef EDP_H_ -#define EDP_H_ - -#include - -#endif /* EDP_H_ */ diff --git a/include/fastrtps/rtps/builtin/discovery/endpoint/EDPSimple.h b/include/fastrtps/rtps/builtin/discovery/endpoint/EDPSimple.h deleted file mode 100644 index 513ec92a66d..00000000000 --- a/include/fastrtps/rtps/builtin/discovery/endpoint/EDPSimple.h +++ /dev/null @@ -1,25 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file EDPSimple.h - * - */ - -#ifndef EDPSIMPLE_H_ -#define EDPSIMPLE_H_ - -#include - -#endif /* EDPSIMPLE_H_ */ diff --git a/include/fastrtps/rtps/builtin/discovery/endpoint/EDPStatic.h b/include/fastrtps/rtps/builtin/discovery/endpoint/EDPStatic.h deleted file mode 100644 index 86a1c8892ad..00000000000 --- a/include/fastrtps/rtps/builtin/discovery/endpoint/EDPStatic.h +++ /dev/null @@ -1,25 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file EDPStatic.h - * - */ - -#ifndef EDPSTATIC_H_ -#define EDPSTATIC_H_ - -#include - -#endif /* EDPSTATIC_H_ */ diff --git a/include/fastrtps/rtps/builtin/discovery/participant/PDP.h b/include/fastrtps/rtps/builtin/discovery/participant/PDP.h deleted file mode 100644 index 3b8a8f6c549..00000000000 --- a/include/fastrtps/rtps/builtin/discovery/participant/PDP.h +++ /dev/null @@ -1,25 +0,0 @@ -// Copyright 2019 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file PDP.h - * - */ - -#ifndef PDP_H_ -#define PDP_H_ - -#include - -#endif /* PDP_H_ */ diff --git a/include/fastrtps/rtps/builtin/discovery/participant/PDPListener.h b/include/fastrtps/rtps/builtin/discovery/participant/PDPListener.h deleted file mode 100644 index 277d1a8c2e8..00000000000 --- a/include/fastrtps/rtps/builtin/discovery/participant/PDPListener.h +++ /dev/null @@ -1,25 +0,0 @@ -// Copyright 2019 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file PDPListener.h - * - */ - -#ifndef PDPLISTENER_H_ -#define PDPLISTENER_H_ - -#include - -#endif /* PDPLISTENER_H_ */ diff --git a/include/fastrtps/rtps/builtin/discovery/participant/PDPSimple.h b/include/fastrtps/rtps/builtin/discovery/participant/PDPSimple.h deleted file mode 100644 index 55d338e9452..00000000000 --- a/include/fastrtps/rtps/builtin/discovery/participant/PDPSimple.h +++ /dev/null @@ -1,25 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file PDPSimple.h - * - */ - -#ifndef _RTPS_BUILTIN_DISCOVERY_PARTICIPANT_PDPSIMPLE_H_ -#define _RTPS_BUILTIN_DISCOVERY_PARTICIPANT_PDPSIMPLE_H_ - -#include - -#endif //_RTPS_BUILTIN_DISCOVERY_PARTICIPANT_PDPSIMPLE_H_ diff --git a/include/fastrtps/rtps/builtin/liveliness/WLP.h b/include/fastrtps/rtps/builtin/liveliness/WLP.h deleted file mode 100644 index 380a170e384..00000000000 --- a/include/fastrtps/rtps/builtin/liveliness/WLP.h +++ /dev/null @@ -1,25 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file WLP.h - * - */ - -#ifndef WLP_H_ -#define WLP_H_ - -#include - -#endif /* WLP_H_ */ diff --git a/include/fastrtps/rtps/builtin/liveliness/WLPListener.h b/include/fastrtps/rtps/builtin/liveliness/WLPListener.h deleted file mode 100644 index 49e76e8f8a8..00000000000 --- a/include/fastrtps/rtps/builtin/liveliness/WLPListener.h +++ /dev/null @@ -1,25 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file WLPListener.h - * - */ - -#ifndef WLPLISTENER_H_ -#define WLPLISTENER_H_ - -#include - -#endif /* WLPLISTENER_H_ */ diff --git a/include/fastrtps/rtps/rtps_all.h b/include/fastrtps/rtps/rtps_all.h deleted file mode 100644 index 78f0b99f7cf..00000000000 --- a/include/fastrtps/rtps/rtps_all.h +++ /dev/null @@ -1,25 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file rtps_all.h - * - */ - -#ifndef RTPS_ALL_H_ -#define RTPS_ALL_H_ - -#include - -#endif /* RTPS_ALL_H_ */ diff --git a/include/fastrtps/rtps/writer/LivelinessData.h b/include/fastrtps/rtps/writer/LivelinessData.h deleted file mode 100644 index 980e1dadebc..00000000000 --- a/include/fastrtps/rtps/writer/LivelinessData.h +++ /dev/null @@ -1,23 +0,0 @@ -// Copyright 2016-2019 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file LivelinessData.h - */ -#ifndef LIVELINESS_DATA_H_ -#define LIVELINESS_DATA_H_ - -#include - -#endif /* LIVELINESS_DATA_H_ */ diff --git a/include/fastrtps/rtps/writer/LivelinessManager.h b/include/fastrtps/rtps/writer/LivelinessManager.h deleted file mode 100644 index f2cafe2155c..00000000000 --- a/include/fastrtps/rtps/writer/LivelinessManager.h +++ /dev/null @@ -1,23 +0,0 @@ -// Copyright 2016-2019 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file LivelinessManager.h - */ -#ifndef LIVELINESS_MANAGER_H_ -#define LIVELINESS_MANAGER_H_ - -#include - -#endif /* LIVELINESS_MANAGER_H_ */ diff --git a/include/fastrtps/subscriber/SampleInfo.h b/include/fastrtps/subscriber/SampleInfo.h deleted file mode 100644 index 81556d92761..00000000000 --- a/include/fastrtps/subscriber/SampleInfo.h +++ /dev/null @@ -1,73 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file SampleInfo.h - */ - -#ifndef SAMPLEINFO_H_ -#define SAMPLEINFO_H_ - -#include - -#include -#include -#include -#include - -#include - -namespace eprosima { -namespace fastrtps { - -/** - * Class SampleInfo_t with information that is provided along a sample when reading data from a Subscriber. - * @ingroup FASTRTPS_MODULE - */ -class RTPS_DllAPI SampleInfo_t -{ -public: - - SampleInfo_t() - : sampleKind(rtps::ALIVE) - , ownershipStrength(0) - , sample_identity(rtps::SampleIdentity::unknown()) - , related_sample_identity(rtps::SampleIdentity::unknown()) - { - } - - virtual ~SampleInfo_t() - { - } - - //!Sample kind. - rtps::ChangeKind_t sampleKind; - //!Ownership Strength of the writer of the sample (0 if the ownership kind is set to SHARED_OWNERSHIP_QOS). - uint32_t ownershipStrength; - //!Source timestamp of the sample. - rtps::Time_t sourceTimestamp; - //!Reception timestamp of the sample. - rtps::Time_t receptionTimestamp; - //!InstanceHandle of the data - rtps::InstanceHandle_t iHandle; - - rtps::SampleIdentity sample_identity; - - rtps::SampleIdentity related_sample_identity; -}; - -} /* namespace fastrtps */ -} /* namespace eprosima */ - -#endif /* SAMPLEINFO_H_ */ diff --git a/include/fastrtps/subscriber/Subscriber.h b/include/fastrtps/subscriber/Subscriber.h deleted file mode 100644 index 30913ec7d7c..00000000000 --- a/include/fastrtps/subscriber/Subscriber.h +++ /dev/null @@ -1,190 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file Subscriber.h - */ - - -#ifndef SUBSCRIBER_H_ -#define SUBSCRIBER_H_ - -#include -#include -#include -#include -#include -#include - -namespace eprosima { -namespace fastrtps { - -class SubscriberImpl; -class SampleInfo_t; - -/** - * Class Subscriber, contains the public API that allows the user to control the reception of messages. - * This class should not be instantiated directly. - * DomainRTPSParticipant class should be used to correctly create this element. - * @ingroup FASTRTPS_MODULE - * @snippet fastrtps_example.cpp ex_Subscriber - */ -class RTPS_DllAPI Subscriber -{ - friend class SubscriberImpl; - - virtual ~Subscriber() - { - } - -public: - - /** - * Constructor from a SubscriberImpl pointer - * @param pimpl Actual implementation of the subscriber - */ - Subscriber( - SubscriberImpl* pimpl) - : mp_impl(pimpl) - { - } - - /** - * Get the associated GUID - * @return Associated GUID - */ - const rtps::GUID_t& getGuid(); - - /** - * Method to block the current thread until an unread message is available - */ - inline void waitForUnreadMessage() - { - const Duration_t one_day{ 24 * 3600, 0 }; - while (!wait_for_unread_samples(one_day)) - { - } - } - - /*! - * @brief Blocks the current thread until an unread sample is available. - * @param timeout Maximum time the function will be blocked if any sample is received. - * @return true in case unread samples are available. - * In other case, false. - */ - bool wait_for_unread_samples( - const Duration_t& timeout); - - /** - * @brief Reads next unread sample from the Subscriber. - * @param sample Pointer to the object where you want the sample stored. - * @param info Pointer to a SampleInfo_t structure that informs you about your sample. - * @return True if a sample was read. - * @note This method is blocked for a period of time. - * ReliabilityQosPolicy.max_blocking_time on SubscriberAttributes defines this period of time. - */ - bool readNextData( - void* sample, - SampleInfo_t* info); - - /** - * @brief Takes next sample from the Subscriber. The sample is removed from the subscriber. - * @param sample Pointer to the object where you want the sample stored. - * @param info Pointer to a SampleInfo_t structure that informs you about your sample. - * @return True if a sample was taken. - * @note This method is blocked for a period of time. - * ReliabilityQosPolicy.max_blocking_time on SubscriberAttributes defines this period of time. - */ - bool takeNextData( - void* sample, - SampleInfo_t* info); - - /** - * @brief Returns information about the first untaken sample. - * @param [out] info Pointer to a SampleInfo_t structure to store first untaken sample information. - * @return true if sample info was returned. false if there is no sample to take. - */ - bool get_first_untaken_info( - SampleInfo_t* info); - - /** - * Update the Attributes of the subscriber; - * @param att Reference to a SubscriberAttributes object to update the parameters; - * @return True if correctly updated, false if ANY of the updated parameters cannot be updated - */ - bool updateAttributes( - const SubscriberAttributes& att); - - /** - * Get the Attributes of the Subscriber. - * @return Attributes of the subscriber - */ - const SubscriberAttributes& getAttributes() const; - - /*! - * @brief Returns there is a clean state with all Publishers. - * It occurs when the Subscriber received all samples sent by Publishers. In other words, - * its WriterProxies are up to date. - * @return There is a clean state with all Publishers. - */ - bool isInCleanState() const; - - /** - * Get the unread count. - * @return Unread count - */ - inline uint64_t getUnreadCount() const - { - return get_unread_count(); - } - - /** - * Get the unread count. - * @return Unread count - */ - uint64_t get_unread_count() const; - - /** - * @brief Get the requested deadline missed status - * @param status The deadline missed status - */ - void get_requested_deadline_missed_status( - RequestedDeadlineMissedStatus& status); - - /** - * @brief Returns the liveliness changed status - * @param status Liveliness changed status - */ - void get_liveliness_changed_status( - LivelinessChangedStatus& status); - - /** - * Get the list of locators on which this subscriber is listening. - * - * @param [out] locators LocatorList_t where the list of locators will be stored. - */ - void get_listening_locators( - rtps::LocatorList_t& locators) const; - -private: - - SubscriberImpl* mp_impl; -}; - - - -} /* namespace pubsub */ -} /* namespace eprosima */ - -#endif /* SUBSCRIBER_H_ */ diff --git a/include/fastrtps/subscriber/SubscriberHistory.h b/include/fastrtps/subscriber/SubscriberHistory.h deleted file mode 100644 index eba33252b01..00000000000 --- a/include/fastrtps/subscriber/SubscriberHistory.h +++ /dev/null @@ -1,282 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file SubscriberHistory.h - * - */ - -#ifndef SUBSCRIBERHISTORY_H_ -#define SUBSCRIBERHISTORY_H_ -#ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC - -#include -#include -#include -#include -#include -#include -#include -#include - -#include -#include - -namespace eprosima { -namespace fastrtps { - -/** - * Class SubscriberHistory, container of the different CacheChanges of a subscriber - * @ingroup FASTRTPS_MODULE - */ -class SubscriberHistory : public rtps::ReaderHistory -{ -public: - - /** - * Constructor. Requires information about the subscriber. - * @param topic_att TopicAttributes. - * @param type TopicDataType. - * @param qos ReaderQoS policy. - * @param payloadMax Maximum payload size per change. - * @param mempolicy Set whether the payloads ccan dynamically resized or not. - */ - SubscriberHistory( - const TopicAttributes& topic_att, - fastdds::dds::TopicDataType* type, - const fastrtps::ReaderQos& qos, - uint32_t payloadMax, - rtps::MemoryManagementPolicy_t mempolicy); - - ~SubscriberHistory() override; - - /** - * Remove a specific change from the history. - * No Thread Safe - * @param removal iterator to the CacheChange_t to remove. - * @param release defaults to true and hints if the CacheChange_t should return to the pool - * @return iterator to the next CacheChange_t or end iterator. - */ - iterator remove_change_nts( - const_iterator removal, - bool release = true) override; - - /** - * Check if a new change can be added to this history. - * - * @param [in] writer_guid GUID of the writer where the change came from. - * @param [in] total_payload_size Total payload size of the incoming change. - * @param [in] unknown_missing_changes_up_to The number of changes from the same writer with a lower sequence - * number that could potentially be received in the future. - * @param [out] will_never_be_accepted When the method returns @c false, this parameter will inform - * whether the change could be accepted in the future or not. - * - * @pre change should not be present in the history - * - * @return Whether a call to received_change will succeed when called with the same arguments. - */ - bool can_change_be_added_nts( - const rtps::GUID_t& writer_guid, - uint32_t total_payload_size, - size_t unknown_missing_changes_up_to, - bool& will_never_be_accepted) const override; - - /** - * Called when a change is received by the Subscriber. Will add the change to the history. - * @pre Change should not be already present in the history. - * @param[in] change The received change - * @param unknown_missing_changes_up_to Number of missing changes before this one - * @return - */ - bool received_change( - rtps::CacheChange_t* change, - size_t unknown_missing_changes_up_to) override; - - /** - * Called when a fragmented change is received completely by the Subscriber. Will find its instance and store it. - * @pre Change should be already present in the history. - * @param[in] change The received change - * @return - */ - bool completed_change( - rtps::CacheChange_t* change) override; - - /** @name Read or take data methods. - * Methods to read or take data from the History. - * @param data Pointer to the object where you want to read or take the information. - * @param info Pointer to a SampleInfo_t object where you want - * @param max_blocking_time Maximum time the function can be blocked. - * to store the information about the retrieved data - */ - ///@{ - bool readNextData( - void* data, - SampleInfo_t* info, - std::chrono::steady_clock::time_point& max_blocking_time); - - bool takeNextData( - void* data, - SampleInfo_t* info, - std::chrono::steady_clock::time_point& max_blocking_time); - ///@} - - /** - * @brief Returns information about the first untaken sample. - * @param [out] info Pointer to a SampleInfo_t structure to store first untaken sample information. - * @return true if sample info was returned. false if there is no sample to take. - */ - bool get_first_untaken_info( - SampleInfo_t* info); - - /** - * This method is called to remove a change from the SubscriberHistory. - * @param change Pointer to the CacheChange_t. - * @return True if removed. - */ - bool remove_change_sub( - rtps::CacheChange_t* change); - - /** - * This method is called to remove a change from the SubscriberHistory. - * @param [in] change Pointer to the CacheChange_t. - * @param [in,out] it Iterator pointing to change on input. Will point to next valid change on output. - * @return True if removed. - */ - bool remove_change_sub( - rtps::CacheChange_t* change, - iterator& it); - - /** - * @brief A method to set the next deadline for the given instance - * @param handle The handle to the instance - * @param next_deadline_us The time point when the deadline will occur - * @return True if the deadline was set correctly - */ - bool set_next_deadline( - const rtps::InstanceHandle_t& handle, - const std::chrono::steady_clock::time_point& next_deadline_us); - - /** - * @brief A method to get the next instance handle that will miss the deadline and the time when the deadline will occur - * @param handle The handle to the instance - * @param next_deadline_us The time point when the instance will miss the deadline - * @return True if the deadline was retrieved successfully - */ - bool get_next_deadline( - rtps::InstanceHandle_t& handle, - std::chrono::steady_clock::time_point& next_deadline_us); - -private: - - using rtps::ReaderHistory::completed_change; - using rtps::ReaderHistory::received_change; - using rtps::ReaderHistory::remove_change_nts; - - using t_m_Inst_Caches = std::map; - - //!Map where keys are instance handles and values vectors of cache changes - t_m_Inst_Caches keyed_changes_; - //!Time point when the next deadline will occur (only used for topics with no key) - std::chrono::steady_clock::time_point next_deadline_us_; - //!HistoryQosPolicy values. - HistoryQosPolicy history_qos_; - //!ResourceLimitsQosPolicy values. - ResourceLimitsQosPolicy resource_limited_qos_; - //!Topic Attributes - TopicAttributes topic_att_; - //!TopicDataType - fastdds::dds::TopicDataType* type_; - //!ReaderQos - fastrtps::ReaderQos qos_; - - //!Type object to deserialize Key - void* get_key_object_; - - /// Function processing a received change - std::function receive_fn_; - - /// Function processing a completed fragmented change - std::function complete_fn_; - - /** - * @brief Method that finds a key in m_keyedChanges or tries to add it if not found - * @param a_change The change to get the key from - * @param[out] map_it A map iterator to the given key - * @return True if it was found or could be added to the map - */ - bool find_key( - rtps::CacheChange_t* a_change, - t_m_Inst_Caches::iterator& map_it); - - /** - * @brief Method that finds a key in m_keyedChanges or tries to add it if not found - * @param a_change The change to get the key from - * @param map_it A map iterator to the given key - * @return True if it was found or could be added to the map - */ - bool find_key_for_change( - rtps::CacheChange_t* a_change, - t_m_Inst_Caches::iterator& map_it); - - /** - * @name Variants of incoming change processing. - * Will be called with the history mutex taken. - * @param[in] change The received change - * @param unknown_missing_changes_up_to Number of missing changes before this one - * @return - */ - ///@{ - bool received_change_keep_all_no_key( - rtps::CacheChange_t* change, - size_t unknown_missing_changes_up_to); - - bool received_change_keep_last_no_key( - rtps::CacheChange_t* change, - size_t unknown_missing_changes_up_to); - - bool received_change_keep_all_with_key( - rtps::CacheChange_t* change, - size_t unknown_missing_changes_up_to); - - bool received_change_keep_last_with_key( - rtps::CacheChange_t* change, - size_t unknown_missing_changes_up_to); - - bool completed_change_keep_all_with_key( - rtps::CacheChange_t* change); - - bool completed_change_keep_last_with_key( - rtps::CacheChange_t* change); - ///@} - - bool add_received_change( - rtps::CacheChange_t* a_change); - - bool add_received_change_with_key( - rtps::CacheChange_t* a_change, - std::vector& instance_changes); - - bool deserialize_change( - rtps::CacheChange_t* change, - uint32_t ownership_strength, - void* data, - SampleInfo_t* info); -}; - -} // namespace fastrtps -} // namespace eprosima - -#endif // ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC - -#endif /* SUBSCRIBERHISTORY_H_ */ diff --git a/include/fastrtps/subscriber/SubscriberListener.h b/include/fastrtps/subscriber/SubscriberListener.h deleted file mode 100644 index 572c540d037..00000000000 --- a/include/fastrtps/subscriber/SubscriberListener.h +++ /dev/null @@ -1,101 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file SubscriberListener.h - */ - -#ifndef SUBLISTENER_H_ -#define SUBLISTENER_H_ - -#include -#include -#include - -namespace eprosima { -namespace fastrtps { - -namespace rtps { -class MatchingInfo; -} /* namespace rtps */ - -class Subscriber; - -/** - * Class SubscriberListener, it should be used by the end user to implement specific callbacks to certain actions. - * @ingroup FASTRTPS_MODULE - * @snippet fastrtps_example.cpp ex_SubscriberListener - */ -class RTPS_DllAPI SubscriberListener -{ - public: - - SubscriberListener(){} - - virtual ~SubscriberListener(){} - - /** - * Virtual function to be implemented by the user containing the actions to be performed when a new Data Message is received. - * @param sub Subscriber - */ - virtual void onNewDataMessage(Subscriber* sub) - { - (void)sub; - } - - /** - * Virtual method to be called when the subscriber is matched with a new Writer (or unmatched); i.e., when a writer publishing in the same topic is discovered. - * @param sub Subscriber - * @param info Matching information - */ - virtual void onSubscriptionMatched( - Subscriber* sub, - rtps::MatchingInfo& info) - { - (void)sub; - (void)info; - } - - /** - * Virtual method to be called when a topic misses the deadline period - * @param sub Subscriber - * @param status The requested deadline missed status - */ - virtual void on_requested_deadline_missed( - Subscriber* sub, - const RequestedDeadlineMissedStatus& status) - { - (void)sub; - (void)status; - } - - /** - * @brief Method called when the liveliness status associated to a subscriber changes - * @param sub The subscriber - * @param status The liveliness changed status - */ - virtual void on_liveliness_changed( - Subscriber* sub, - const LivelinessChangedStatus& status) - { - (void)sub; - (void)status; - } - -}; - -} /* namespace fastrtps */ -} /* namespace eprosima */ - -#endif /* LISTENER_H_ */ diff --git a/include/fastrtps/types/AnnotationDescriptor.h b/include/fastrtps/types/AnnotationDescriptor.h deleted file mode 100644 index 2e67622774d..00000000000 --- a/include/fastrtps/types/AnnotationDescriptor.h +++ /dev/null @@ -1,71 +0,0 @@ -// Copyright 2018 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -#ifndef TYPES_ANNOTATION_DESCRIPTOR_H -#define TYPES_ANNOTATION_DESCRIPTOR_H - -#include -#include - -namespace eprosima{ -namespace fastrtps{ -namespace types{ - -class MemberDescriptor; -class DynamicType; - -class AnnotationDescriptor -{ -protected: - friend class DynamicTypeBuilderFactory; - - DynamicType_ptr type_; - std::map value_; - -public: - AnnotationDescriptor(); - ~AnnotationDescriptor(); - AnnotationDescriptor(const AnnotationDescriptor* descriptor); - AnnotationDescriptor(DynamicType_ptr p_type); - - ReturnCode_t copy_from(const AnnotationDescriptor* other); - bool equals(const AnnotationDescriptor*) const; - bool is_consistent() const; - bool key_annotation() const; - - ReturnCode_t get_value( - std::string& value, - const std::string& key); - - ReturnCode_t get_value(std::string& value); // key = "value" - - ReturnCode_t get_all_value(std::map& value) const; - - ReturnCode_t set_value( - const std::string& key, - const std::string& value); - - void set_type(DynamicType_ptr pType); - - const DynamicType_ptr type() const - { - return type_; - } -}; - -} // namespace types -} // namespace fastrtps -} // namespace eprosima - -#endif // TYPES_ANNOTATION_DESCRIPTOR_H diff --git a/include/fastrtps/types/AnnotationParameterValue.h b/include/fastrtps/types/AnnotationParameterValue.h deleted file mode 100644 index 91f22781f8b..00000000000 --- a/include/fastrtps/types/AnnotationParameterValue.h +++ /dev/null @@ -1,1453 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file AnnotationParameterValue.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool gen. - */ - -#ifndef _ANNOTATIONPARAMETERVALUE_H_ -#define _ANNOTATIONPARAMETERVALUE_H_ - -#if _MSC_VER - -#if defined(max) -#pragma push_macro("max") -#undef max -#define FASTDDS_RESTORE_MAX -#endif // defined(max) - -#if defined(min) -#pragma push_macro("min") -#undef min -#define FASTDDS_RESTORE_MIN -#endif // defined(min) - -#endif // if _MSC_VER - -#include -#include -#include - -#include -#include -#include -#include - -namespace eprosima { -namespace fastcdr { -class Cdr; -} // namespace fastcdr -} // namespace eprosima -namespace eprosima { -namespace fastrtps { - -namespace types { - -/*! - * @brief This class represents the structure ExtendedAnnotationParameterValue defined by the user in the IDL file. - * @ingroup TYPES_MODULE - */ -class ExtendedAnnotationParameterValue -{ -public: - - /*! - * @brief Default constructor. - */ - RTPS_DllAPI ExtendedAnnotationParameterValue(); - - /*! - * @brief Default destructor. - */ - RTPS_DllAPI ~ExtendedAnnotationParameterValue(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object ExtendedAnnotationParameterValue that will be copied. - */ - RTPS_DllAPI ExtendedAnnotationParameterValue( - const ExtendedAnnotationParameterValue& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object ExtendedAnnotationParameterValue that will be copied. - */ - RTPS_DllAPI ExtendedAnnotationParameterValue( - ExtendedAnnotationParameterValue&& x); - - /*! - * @brief Copy assignment. - * @param x Reference to the object ExtendedAnnotationParameterValue that will be copied. - */ - RTPS_DllAPI ExtendedAnnotationParameterValue& operator =( - const ExtendedAnnotationParameterValue& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object ExtendedAnnotationParameterValue that will be copied. - */ - RTPS_DllAPI ExtendedAnnotationParameterValue& operator =( - ExtendedAnnotationParameterValue&& x); - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - FASTDDS_SER_METHOD_DEPRECATED(3, - "eprosima::fastrtps::types::ExtendedAnnotationParameterValue::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const ExtendedAnnotationParameterValue& data, - size_t current_alignment = 0); - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::ExtendedAnnotationParameterValue::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::ExtendedAnnotationParameterValue::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - /*! - * @brief This function returns the maximum serialized size of the Key of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - RTPS_DllAPI static size_t getKeyMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - RTPS_DllAPI static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - RTPS_DllAPI void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - RTPS_DllAPI bool operator ==( - const ExtendedAnnotationParameterValue&) const - { - return true; - } - -private: -}; -/*! - * @brief This class represents the union AnnotationParameterValue defined by the user in the IDL file. - * @ingroup TYPES_MODULE - */ -class AnnotationParameterValue -{ -public: - - /*! - * @brief Default constructor. - */ - RTPS_DllAPI AnnotationParameterValue(); - - /*! - * @brief Default destructor. - */ - RTPS_DllAPI ~AnnotationParameterValue(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object AnnotationParameterValue that will be copied. - */ - RTPS_DllAPI AnnotationParameterValue( - const AnnotationParameterValue& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object AnnotationParameterValue that will be copied. - */ - RTPS_DllAPI AnnotationParameterValue( - AnnotationParameterValue&& x); - - /*! - * @brief Copy assignment. - * @param x Reference to the object AnnotationParameterValue that will be copied. - */ - RTPS_DllAPI AnnotationParameterValue& operator =( - const AnnotationParameterValue& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object AnnotationParameterValue that will be copied. - */ - RTPS_DllAPI AnnotationParameterValue& operator =( - AnnotationParameterValue&& x); - - /*! - * @brief This function sets the discriminator value. - * @param __d New value for the discriminator. - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the new value doesn't correspond to the selected union member. - */ - RTPS_DllAPI void _d( - char __d); - - /*! - * @brief This function returns the value of the discriminator. - * @return Value of the discriminator - */ - RTPS_DllAPI char _d() const; - - /*! - * @brief This function returns a reference to the discriminator. - * @return Reference to the discriminator. - */ - RTPS_DllAPI char& _d(); - - /*! - * @brief This function sets a value in member boolean_value - * @param _boolean_value New value for member boolean_value - */ - RTPS_DllAPI void boolean_value( - bool _boolean_value); - - /*! - * @brief This function returns the value of member boolean_value - * @return Value of member boolean_value - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI bool boolean_value() const; - - /*! - * @brief This function returns a reference to member boolean_value - * @return Reference to member boolean_value - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI bool& boolean_value(); - /*! - * @brief This function sets a value in member byte_value - * @param _byte_value New value for member byte_value - */ - RTPS_DllAPI void byte_value( - uint8_t _byte_value); - - /*! - * @brief This function returns the value of member byte_value - * @return Value of member byte_value - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI uint8_t byte_value() const; - - /*! - * @brief This function returns a reference to member byte_value - * @return Reference to member byte_value - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI uint8_t& byte_value(); - /*! - * @brief This function sets a value in member int16_value - * @param _int16_value New value for member int16_value - */ - RTPS_DllAPI void int16_value( - int16_t _int16_value); - - /*! - * @brief This function returns the value of member int16_value - * @return Value of member int16_value - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI int16_t int16_value() const; - - /*! - * @brief This function returns a reference to member int16_value - * @return Reference to member int16_value - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI int16_t& int16_value(); - /*! - * @brief This function sets a value in member uint_16_value - * @param _uint_16_value New value for member uint_16_value - */ - RTPS_DllAPI void uint_16_value( - uint16_t _uint_16_value); - - /*! - * @brief This function returns the value of member uint_16_value - * @return Value of member uint_16_value - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI uint16_t uint_16_value() const; - - /*! - * @brief This function returns a reference to member uint_16_value - * @return Reference to member uint_16_value - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI uint16_t& uint_16_value(); - /*! - * @brief This function sets a value in member int32_value - * @param _int32_value New value for member int32_value - */ - RTPS_DllAPI void int32_value( - int32_t _int32_value); - - /*! - * @brief This function returns the value of member int32_value - * @return Value of member int32_value - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI int32_t int32_value() const; - - /*! - * @brief This function returns a reference to member int32_value - * @return Reference to member int32_value - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI int32_t& int32_value(); - /*! - * @brief This function sets a value in member uint32_value - * @param _uint32_value New value for member uint32_value - */ - RTPS_DllAPI void uint32_value( - uint32_t _uint32_value); - - /*! - * @brief This function returns the value of member uint32_value - * @return Value of member uint32_value - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI uint32_t uint32_value() const; - - /*! - * @brief This function returns a reference to member uint32_value - * @return Reference to member uint32_value - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI uint32_t& uint32_value(); - /*! - * @brief This function sets a value in member int64_value - * @param _int64_value New value for member int64_value - */ - RTPS_DllAPI void int64_value( - int64_t _int64_value); - - /*! - * @brief This function returns the value of member int64_value - * @return Value of member int64_value - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI int64_t int64_value() const; - - /*! - * @brief This function returns a reference to member int64_value - * @return Reference to member int64_value - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI int64_t& int64_value(); - - /*! - * @brief This function sets a value in member uint64_value - * @param _uint64_value New value for member uint64_value - */ - RTPS_DllAPI void uint64_value( - uint64_t _uint64_value); - - /*! - * @brief This function returns the value of member uint64_value - * @return Value of member uint64_value - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI uint64_t uint64_value() const; - - /*! - * @brief This function returns a reference to member uint64_value - * @return Reference to member uint64_value - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI uint64_t& uint64_value(); - /*! - * @brief This function sets a value in member float32_value - * @param _float32_value New value for member float32_value - */ - RTPS_DllAPI void float32_value( - float _float32_value); - - /*! - * @brief This function returns the value of member float32_value - * @return Value of member float32_value - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI float float32_value() const; - - /*! - * @brief This function returns a reference to member float32_value - * @return Reference to member float32_value - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI float& float32_value(); - /*! - * @brief This function sets a value in member float64_value - * @param _float64_value New value for member float64_value - */ - RTPS_DllAPI void float64_value( - double _float64_value); - - /*! - * @brief This function returns the value of member float64_value - * @return Value of member float64_value - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI double float64_value() const; - - /*! - * @brief This function returns a reference to member float64_value - * @return Reference to member float64_value - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI double& float64_value(); - - /*! - * @brief This function sets a value in member float128_value - * @param _float128_value New value for member float128_value - */ - RTPS_DllAPI void float128_value( - long double _float128_value); - - /*! - * @brief This function returns the value of member float128_value - * @return Value of member float128_value - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI long double float128_value() const; - - /*! - * @brief This function returns a reference to member float128_value - * @return Reference to member float128_value - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI long double& float128_value(); - /*! - * @brief This function sets a value in member char_value - * @param _char_value New value for member char_value - */ - RTPS_DllAPI void char_value( - char _char_value); - - /*! - * @brief This function returns the value of member char_value - * @return Value of member char_value - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI char char_value() const; - - /*! - * @brief This function returns a reference to member char_value - * @return Reference to member char_value - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI char& char_value(); - /*! - * @brief This function sets a value in member wchar_value - * @param _wchar_value New value for member wchar_value - */ - RTPS_DllAPI void wchar_value( - wchar_t _wchar_value); - - /*! - * @brief This function returns the value of member wchar_value - * @return Value of member wchar_value - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI wchar_t wchar_value() const; - - /*! - * @brief This function returns a reference to member wchar_value - * @return Reference to member wchar_value - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI wchar_t& wchar_value(); - /*! - * @brief This function sets a value in member enumerated_value - * @param _enumerated_value New value for member enumerated_value - */ - RTPS_DllAPI void enumerated_value( - int32_t _enumerated_value); - - /*! - * @brief This function returns the value of member enumerated_value - * @return Value of member enumerated_value - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI int32_t enumerated_value() const; - - /*! - * @brief This function returns a reference to member enumerated_value - * @return Reference to member enumerated_value - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI int32_t& enumerated_value(); - /*! - * @brief This function copies the value in member string8_value - * @param _string8_value New value to be copied in member string8_value - */ - RTPS_DllAPI void string8_value( - const std::string& _string8_value); - - /*! - * @brief This function moves the value in member string8_value - * @param _string8_value New value to be moved in member string8_value - */ - RTPS_DllAPI void string8_value( - std::string&& _string8_value); - - /*! - * @brief This function returns a constant reference to member string8_value - * @return Constant reference to member string8_value - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI const std::string& string8_value() const; - - /*! - * @brief This function returns a reference to member string8_value - * @return Reference to member string8_value - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI std::string& string8_value(); - /*! - * @brief This function copies the value in member string16_value - * @param _string16_value New value to be copied in member string16_value - */ - RTPS_DllAPI void string16_value( - const std::wstring& _string16_value); - - /*! - * @brief This function moves the value in member string16_value - * @param _string16_value New value to be moved in member string16_value - */ - RTPS_DllAPI void string16_value( - std::wstring&& _string16_value); - - /*! - * @brief This function returns a constant reference to member string16_value - * @return Constant reference to member string16_value - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI const std::wstring& string16_value() const; - - /*! - * @brief This function returns a reference to member string16_value - * @return Reference to member string16_value - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI std::wstring& string16_value(); - - /*! - * @brief This function copies the value in member extended_value - * @param _extended_value New value to be copied in member extended_value - */ - RTPS_DllAPI void extended_value( - const ExtendedAnnotationParameterValue& _extended_value); - - /*! - * @brief This function moves the value in member extended_value - * @param _extended_value New value to be moved in member extended_value - */ - RTPS_DllAPI void extended_value( - ExtendedAnnotationParameterValue&& _extended_value); - - /*! - * @brief This function returns a constant reference to member extended_value - * @return Constant reference to member extended_value - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI const ExtendedAnnotationParameterValue& extended_value() const; - - /*! - * @brief This function returns a reference to member extended_value - * @return Reference to member extended_value - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI ExtendedAnnotationParameterValue& extended_value(); - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::AnnotationParameterValue::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const AnnotationParameterValue& data, - size_t current_alignment = 0); - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::AnnotationParameterValue::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::AnnotationParameterValue::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - /*! - * @brief This function returns the maximum serialized size of the Key of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - RTPS_DllAPI static size_t getKeyMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - RTPS_DllAPI static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - RTPS_DllAPI void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - RTPS_DllAPI bool operator ==( - const AnnotationParameterValue& other) const; - - /** - * Aux method to return value as its string representation. - */ - RTPS_DllAPI std::string to_string() const - { - switch (m__d) - { - case TK_BOOLEAN: - return (m_boolean_value) ? "true" : "false"; - case TK_BYTE: - return std::to_string(m_byte_value); - case TK_INT16: - return std::to_string(m_int16_value); - case TK_UINT16: - return std::to_string(m_uint_16_value); - case TK_INT32: - return std::to_string(m_int32_value); - case TK_UINT32: - return std::to_string(m_uint32_value); - case TK_INT64: - return std::to_string(m_int64_value); - case TK_UINT64: - return std::to_string(m_uint64_value); - case TK_FLOAT32: - return std::to_string(m_float32_value); - case TK_FLOAT64: - return std::to_string(m_float64_value); - case TK_FLOAT128: - return std::to_string(m_float128_value); - case TK_CHAR8: - return std::to_string(m_char_value); - case TK_CHAR16: - return std::to_string(m_wchar_value); - case TK_ENUM: - return std::to_string(m_enumerated_value); - case TK_STRING16: - { - return wstring_to_bytes(m_string16_value); - } - case TK_STRING8: - case TK_NONE: // Cheat! - return m_string8_value; - default: - return ""; - } - } - - /** - * Aux method to set value from its string representation. - */ - RTPS_DllAPI void from_string( - const std::string& value) - { - switch (m__d) - { - case TK_BOOLEAN: - { - std::string val_ = value; - std::transform(val_.begin(), val_.end(), val_.begin(), - [](unsigned char c) - { - return static_cast(std::tolower(c)); - }); - boolean_value(val_.compare("0") != 0 || val_.compare(CONST_TRUE) == 0); - } - break; - case TK_BYTE: - { - byte_value(static_cast(std::stoul(value))); - } - break; - case TK_INT16: - { - int16_value(static_cast(std::stoi(value))); - } - break; - case TK_INT32: - { - int32_value(static_cast(std::stoi(value))); - } - break; - case TK_INT64: - { - int64_value(static_cast(std::stoll(value))); - } - break; - case TK_UINT16: - { - uint_16_value(static_cast(std::stoul(value))); - } - break; - case TK_UINT32: - { - uint32_value(static_cast(std::stoul(value))); - } - break; - case TK_UINT64: - { - uint64_value(static_cast(std::stoull(value))); - } - break; - case TK_FLOAT32: - { - float32_value(std::stof(value)); - } - break; - case TK_FLOAT64: - { - float64_value(std::stod(value)); - } - break; - case TK_FLOAT128: - { - float128_value(std::stold(value)); - } - break; - case TK_CHAR8: - { - char_value(value.c_str()[0]); - } - break; - case TK_CHAR16: - { - wchar_value(wstring_from_bytes(value).c_str()[0]); - } - break; - case TK_STRING8: - case TK_NONE: // Cheat! - { - string8_value(value); - } - break; - case TK_STRING16: - { - string16_value(wstring_from_bytes(value)); - } - break; - case TK_ENUM: - { - // TODO Translate from enum value name to integer value - enumerated_value(static_cast(std::stoul(value))); - } - break; - default: - break; - } - } - -private: - - char m__d; - - bool m_boolean_value; - uint8_t m_byte_value; - int16_t m_int16_value; - uint16_t m_uint_16_value; - int32_t m_int32_value; - uint32_t m_uint32_value; - int64_t m_int64_value; - uint64_t m_uint64_value; - float m_float32_value; - double m_float64_value; - long double m_float128_value; - char m_char_value; - wchar_t m_wchar_value; - int32_t m_enumerated_value; - std::string m_string8_value; - std::wstring m_string16_value; - ExtendedAnnotationParameterValue m_extended_value; -}; - -/*! - * @brief This class represents the structure AppliedAnnotationParameter defined by the user in the IDL file. - * @ingroup TYPES_MODULE - */ -class AppliedAnnotationParameter -{ -public: - - /*! - * @brief Default constructor. - */ - RTPS_DllAPI AppliedAnnotationParameter(); - - /*! - * @brief Default destructor. - */ - RTPS_DllAPI ~AppliedAnnotationParameter(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object AppliedAnnotationParameter that will be copied. - */ - RTPS_DllAPI AppliedAnnotationParameter( - const AppliedAnnotationParameter& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object AppliedAnnotationParameter that will be copied. - */ - RTPS_DllAPI AppliedAnnotationParameter( - AppliedAnnotationParameter&& x); - - /*! - * @brief Copy assignment. - * @param x Reference to the object AppliedAnnotationParameter that will be copied. - */ - RTPS_DllAPI AppliedAnnotationParameter& operator =( - const AppliedAnnotationParameter& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object AppliedAnnotationParameter that will be copied. - */ - RTPS_DllAPI AppliedAnnotationParameter& operator =( - AppliedAnnotationParameter&& x); - - /*! - * @brief This function copies the value in member paramname_hash - * @param _paramname_hash New value to be copied in member paramname_hash - */ - inline void paramname_hash( - const NameHash& _paramname_hash) - { - m_paramname_hash = _paramname_hash; - } - - /*! - * @brief This function moves the value in member paramname_hash - * @param _paramname_hash New value to be moved in member paramname_hash - */ - inline void paramname_hash( - NameHash&& _paramname_hash) - { - m_paramname_hash = std::move(_paramname_hash); - } - - /*! - * @brief This function returns a constant reference to member paramname_hash - * @return Constant reference to member paramname_hash - */ - inline const NameHash& paramname_hash() const - { - return m_paramname_hash; - } - - /*! - * @brief This function returns a reference to member paramname_hash - * @return Reference to member paramname_hash - */ - inline NameHash& paramname_hash() - { - return m_paramname_hash; - } - - /*! - * @brief This function copies the value in member value - * @param _value New value to be copied in member value - */ - inline void value( - const AnnotationParameterValue& _value) - { - m_value = _value; - } - - /*! - * @brief This function moves the value in member value - * @param _value New value to be moved in member value - */ - inline void value( - AnnotationParameterValue&& _value) - { - m_value = std::move(_value); - } - - /*! - * @brief This function returns a constant reference to member value - * @return Constant reference to member value - */ - inline const AnnotationParameterValue& value() const - { - return m_value; - } - - /*! - * @brief This function returns a reference to member value - * @return Reference to member value - */ - inline AnnotationParameterValue& value() - { - return m_value; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::AppliedAnnotationParameter::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const AppliedAnnotationParameter& data, - size_t current_alignment = 0); - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::AppliedAnnotationParameter::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::AppliedAnnotationParameter::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - /*! - * @brief This function returns the maximum serialized size of the Key of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - RTPS_DllAPI static size_t getKeyMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - RTPS_DllAPI static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - RTPS_DllAPI void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - RTPS_DllAPI bool operator ==( - const AppliedAnnotationParameter& other) const; - -private: - - NameHash m_paramname_hash; - AnnotationParameterValue m_value; -}; - - -// The application of an annotation to some type or type member -/*struct AppliedAnnotationParameter { - NameHash paramname_hash; - AnnotationParameterValue value; - };*/ -/* - class AppliedAnnotationParameter - { - public: - AppliedAnnotationParameter(); - ~AppliedAnnotationParameter(); - AppliedAnnotationParameter(const AppliedAnnotationParameter &x); - AppliedAnnotationParameter(AppliedAnnotationParameter &&x); - AppliedAnnotationParameter& operator=(const AppliedAnnotationParameter &x); - AppliedAnnotationParameter& operator=(AppliedAnnotationParameter &&x); - - inline void paramname_hash(const NameHash &_paramname_hash) { m_paramname_hash = _paramname_hash; } - inline void paramname_hash(NameHash &&_paramname_hash) { m_paramname_hash = std::move(_paramname_hash); } - inline const NameHash& paramname_hash() const { return m_paramname_hash; } - inline NameHash& paramname_hash() { return m_paramname_hash; } - - inline void value(const AnnotationParameterValue &_value) { m_value = _value; } - inline void value(AnnotationParameterValue &&_value) { m_value = std::move(_value); } - inline const AnnotationParameterValue& value() const { return m_value; } - inline AnnotationParameterValue& value() { return m_value; } - - static size_t getCdrSerializedSize(const AppliedAnnotationParameter& data, size_t current_alignment = 0); - void serialize(eprosima::fastcdr::Cdr &cdr) const; - void deserialize(eprosima::fastcdr::Cdr &cdr); - static size_t getKeyMaxCdrSerializedSize(size_t current_alignment = 0); - static bool isKeyDefined(); - void serializeKey(eprosima::fastcdr::Cdr &cdr) const; - - private: - NameHash m_paramname_hash; - AnnotationParameterValue m_value; - }; - */ -// Sorted by AppliedAnnotationParameter.paramname_hash -typedef std::vector AppliedAnnotationParameterSeq; - -/*struct AppliedAnnotation { - TypeIdentifier annotation_typeid; - AppliedAnnotationParameterSeq param_seq; // @Optional - };*/ -class AppliedAnnotation -{ -public: - - RTPS_DllAPI AppliedAnnotation(); - - RTPS_DllAPI ~AppliedAnnotation(); - - RTPS_DllAPI AppliedAnnotation( - const AppliedAnnotation& x); - - RTPS_DllAPI AppliedAnnotation( - AppliedAnnotation&& x); - RTPS_DllAPI AppliedAnnotation& operator =( - const AppliedAnnotation& x); - RTPS_DllAPI AppliedAnnotation& operator =( - AppliedAnnotation&& x); - - inline void annotation_typeid( - const TypeIdentifier& _annotation_typeid) - { - m_annotation_typeid = _annotation_typeid; - } - - inline void annotation_typeid( - TypeIdentifier&& _annotation_typeid) - { - m_annotation_typeid = std::move(_annotation_typeid); - } - - inline const TypeIdentifier& annotation_typeid() const - { - return m_annotation_typeid; - } - - inline TypeIdentifier& annotation_typeid() - { - return m_annotation_typeid; - } - - inline void param_seq( - const AppliedAnnotationParameterSeq& _param_seq) - { - m_param_seq = _param_seq; - } - - inline void param_seq( - AppliedAnnotationParameterSeq&& _param_seq) - { - m_param_seq = std::move(_param_seq); - } - - inline const AppliedAnnotationParameterSeq& param_seq() const - { - return m_param_seq; - } - - inline AppliedAnnotationParameterSeq& param_seq() - { - return m_param_seq; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::AppliedAnnotation::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const AppliedAnnotation& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::AppliedAnnotation::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::AppliedAnnotation::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI static size_t getKeyMaxCdrSerializedSize( - size_t current_alignment = 0); - RTPS_DllAPI static bool isKeyDefined(); - RTPS_DllAPI void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - RTPS_DllAPI bool operator ==( - const AppliedAnnotation& other) const; - -private: - - TypeIdentifier m_annotation_typeid; - AppliedAnnotationParameterSeq m_param_seq; -}; - -// Sorted by AppliedAnnotation.annotation_typeid -typedef std::vector AppliedAnnotationSeq; - -// @verbatim(placement="", language="", text="") -/*struct AppliedVerbatimAnnotation { - std::string placement; // 32 - std::string language; // 32 - std::string text; - };*/ -class AppliedVerbatimAnnotation -{ -public: - - RTPS_DllAPI AppliedVerbatimAnnotation(); - - RTPS_DllAPI ~AppliedVerbatimAnnotation(); - - RTPS_DllAPI AppliedVerbatimAnnotation( - const AppliedVerbatimAnnotation& x); - - RTPS_DllAPI AppliedVerbatimAnnotation( - AppliedVerbatimAnnotation&& x); - - RTPS_DllAPI AppliedVerbatimAnnotation& operator =( - const AppliedVerbatimAnnotation& x); - - RTPS_DllAPI AppliedVerbatimAnnotation& operator =( - AppliedVerbatimAnnotation&& x); - - inline void placement( - const std::string& _placement) - { - m_placement = _placement; - } - - inline void placement( - std::string&& _placement) - { - m_placement = std::move(_placement); - } - - inline const std::string& placement() const - { - return m_placement; - } - - inline std::string& placement() - { - return m_placement; - } - - inline void language( - const std::string& _language) - { - m_language = _language; - } - - inline void language( - std::string&& _language) - { - m_language = std::move(_language); - } - - inline const std::string& language() const - { - return m_language; - } - - inline std::string& language() - { - return m_language; - } - - inline void text( - const std::string& _text) - { - m_text = _text; - } - - inline void text( - std::string&& _text) - { - m_text = std::move(_text); - } - - inline const std::string& text() const - { - return m_text; - } - - inline std::string& text() - { - return m_text; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::AppliedVerbatimAnnotation::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const AppliedVerbatimAnnotation& data, - size_t current_alignment = 0); - - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::AppliedVerbatimAnnotation::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::AppliedVerbatimAnnotation::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI static size_t getKeyMaxCdrSerializedSize( - size_t current_alignment = 0); - - RTPS_DllAPI static bool isKeyDefined(); - - RTPS_DllAPI void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - RTPS_DllAPI bool operator ==( - const AppliedVerbatimAnnotation& other) const; - -private: - - std::string m_placement; - std::string m_language; - std::string m_text; -}; - -// --- Aggregate types: ----------------------------------------------- -/*struct AppliedBuiltinMemberAnnotations { - std::string unit; // @unit("") // @Optional - AnnotationParameterValue min; // @min , @range // @Optional - AnnotationParameterValue max; // @max , @range // @Optional - std::string hash_id; // @hash_id("") // @Optional - }; - */ -class AppliedBuiltinMemberAnnotations -{ -public: - - RTPS_DllAPI AppliedBuiltinMemberAnnotations(); - - RTPS_DllAPI ~AppliedBuiltinMemberAnnotations(); - - RTPS_DllAPI AppliedBuiltinMemberAnnotations( - const AppliedBuiltinMemberAnnotations& x); - - RTPS_DllAPI AppliedBuiltinMemberAnnotations( - AppliedBuiltinMemberAnnotations&& x); - - RTPS_DllAPI AppliedBuiltinMemberAnnotations& operator =( - const AppliedBuiltinMemberAnnotations& x); - - RTPS_DllAPI AppliedBuiltinMemberAnnotations& operator =( - AppliedBuiltinMemberAnnotations&& x); - - inline void unit( - const std::string& _unit) - { - m_unit = _unit; - } - - inline void unit( - std::string&& _unit) - { - m_unit = std::move(_unit); - } - - inline const std::string& unit() const - { - return m_unit; - } - - inline std::string& unit() - { - return m_unit; - } - - inline void min( - const AnnotationParameterValue& _min) - { - m_min = _min; - } - - inline void min( - AnnotationParameterValue&& _min) - { - m_min = std::move(_min); - } - - inline const AnnotationParameterValue& min() const - { - return m_min; - } - - inline AnnotationParameterValue& min() - { - return m_min; - } - - inline void max( - const AnnotationParameterValue& _max) - { - m_max = _max; - } - - inline void max( - AnnotationParameterValue&& _max) - { - m_max = std::move(_max); - } - - inline const AnnotationParameterValue& max() const - { - return m_max; - } - - inline AnnotationParameterValue& max() - { - return m_max; - } - - inline void hash_id( - const std::string& _hash_id) - { - m_hash_id = _hash_id; - } - - inline void hash_id( - std::string&& _hash_id) - { - m_hash_id = std::move(_hash_id); - } - - inline const std::string& hash_id() const - { - return m_hash_id; - } - - inline std::string& hash_id() - { - return m_hash_id; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, - "eprosima::fastrtps::types::AppliedBuiltinMemberAnnotations::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const AppliedBuiltinMemberAnnotations& data, - size_t current_alignment = 0); - - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::AppliedBuiltinMemberAnnotations::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::AppliedBuiltinMemberAnnotations::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI static size_t getKeyMaxCdrSerializedSize( - size_t current_alignment = 0); - - RTPS_DllAPI static bool isKeyDefined(); - - RTPS_DllAPI void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - RTPS_DllAPI bool operator ==( - const AppliedBuiltinMemberAnnotations& other) const; - -private: - - std::string m_unit; - AnnotationParameterValue m_min; - AnnotationParameterValue m_max; - std::string m_hash_id; -}; - - -} // namespace types -} // namespace fastrtps -} // namespace eprosima - -#if _MSC_VER - -#if defined(FASTDDS_RESTORE_MIN) -#pragma pop_macro("min") -#undef FASTDDS_RESTORE_MIN -#endif // defined(FASTDDS_RESTORE_MIN) - -#if defined(FASTDDS_RESTORE_MAX) -#pragma pop_macro("max") -#undef FASTDDS_RESTORE_MAX -#endif // defined(FASTDDS_RESTORE_MAX) - -#endif // if _MSC_VER - -#endif // _ANNOTATIONPARAMETERVALUE_H_ diff --git a/include/fastrtps/types/BuiltinAnnotationsTypeObject.h b/include/fastrtps/types/BuiltinAnnotationsTypeObject.h deleted file mode 100644 index 69364ca5181..00000000000 --- a/include/fastrtps/types/BuiltinAnnotationsTypeObject.h +++ /dev/null @@ -1,183 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file BuiltinAnnotationsTypeObject.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool gen. - */ - -#ifndef _BUILTIN_ANNOTATIONS_TYPE_OBJECT_H_ -#define _BUILTIN_ANNOTATIONS_TYPE_OBJECT_H_ - - -#include -#include -#include - -using namespace eprosima::fastrtps::types; - -void register_builtin_annotations_types(TypeObjectFactory* factory); - -const TypeIdentifier* GetidIdentifier(bool complete = false); -const TypeObject* GetidObject(bool complete = false); -const TypeObject* GetMinimalidObject(); -const TypeObject* GetCompleteidObject(); - -const TypeIdentifier* GetautoidIdentifier(bool complete = false); -const TypeObject* GetautoidObject(bool complete = false); -const TypeObject* GetMinimalautoidObject(); -const TypeObject* GetCompleteautoidObject(); - -namespace autoid -{ - const TypeIdentifier* GetAutoidKindIdentifier(bool complete = false); - const TypeObject* GetAutoidKindObject(bool complete = false); - const TypeObject* GetMinimalAutoidKindObject(); - const TypeObject* GetCompleteAutoidKindObject(); -} - -const TypeIdentifier* GetoptionalIdentifier(bool complete = false); -const TypeObject* GetoptionalObject(bool complete = false); -const TypeObject* GetMinimaloptionalObject(); -const TypeObject* GetCompleteoptionalObject(); - -const TypeIdentifier* GetpositionIdentifier(bool complete = false); -const TypeObject* GetpositionObject(bool complete = false); -const TypeObject* GetMinimalpositionObject(); -const TypeObject* GetCompletepositionObject(); - -const TypeIdentifier* GetvalueIdentifier(bool complete = false); -const TypeObject* GetvalueObject(bool complete = false); -const TypeObject* GetMinimalvalueObject(); -const TypeObject* GetCompletevalueObject(); - -const TypeIdentifier* GetextensibilityIdentifier(bool complete = false); -const TypeObject* GetextensibilityObject(bool complete = false); -const TypeObject* GetMinimalextensibilityObject(); -const TypeObject* GetCompleteextensibilityObject(); - -namespace extensibility -{ - const TypeIdentifier* GetExtensibilityKindIdentifier(bool complete = false); - const TypeObject* GetExtensibilityKindObject(bool complete = false); - const TypeObject* GetMinimalExtensibilityKindObject(); - const TypeObject* GetCompleteExtensibilityKindObject(); -} - -const TypeIdentifier* GetfinalIdentifier(bool complete = false); -const TypeObject* GetfinalObject(bool complete = false); -const TypeObject* GetMinimalfinalObject(); -const TypeObject* GetCompletefinalObject(); - -const TypeIdentifier* GetappendableIdentifier(bool complete = false); -const TypeObject* GetappendableObject(bool complete = false); -const TypeObject* GetMinimalappendableObject(); -const TypeObject* GetCompleteappendableObject(); - -const TypeIdentifier* GetmutableIdentifier(bool complete = false); -const TypeObject* GetmutableObject(bool complete = false); -const TypeObject* GetMinimalmutableObject(); -const TypeObject* GetCompletemutableObject(); - -const TypeIdentifier* GetkeyIdentifier(bool complete = false); -const TypeObject* GetkeyObject(bool complete = false); -const TypeObject* GetMinimalkeyObject(); -const TypeObject* GetCompletekeyObject(); - -const TypeIdentifier* Getmust_understandIdentifier(bool complete = false); -const TypeObject* Getmust_understandObject(bool complete = false); -const TypeObject* GetMinimalmust_understandObject(); -const TypeObject* GetCompletemust_understandObject(); - -const TypeIdentifier* Getdefault_literalIdentifier(bool complete = false); -const TypeObject* Getdefault_literalObject(bool complete = false); -const TypeObject* GetMinimaldefault_literalObject(); -const TypeObject* GetCompletedefault_literalObject(); - -const TypeIdentifier* GetdefaultIdentifier(bool complete = false); -const TypeObject* GetdefaultObject(bool complete = false); -const TypeObject* GetMinimaldefaultObject(); -const TypeObject* GetCompletedefaultObject(); - -const TypeIdentifier* GetrangeIdentifier(bool complete = false); -const TypeObject* GetrangeObject(bool complete = false); -const TypeObject* GetMinimalrangeObject(); -const TypeObject* GetCompleterangeObject(); - -const TypeIdentifier* GetminIdentifier(bool complete = false); -const TypeObject* GetminObject(bool complete = false); -const TypeObject* GetMinimalminObject(); -const TypeObject* GetCompleteminObject(); - -const TypeIdentifier* GetmaxIdentifier(bool complete = false); -const TypeObject* GetmaxObject(bool complete = false); -const TypeObject* GetMinimalmaxObject(); -const TypeObject* GetCompletemaxObject(); - -const TypeIdentifier* GetunitIdentifier(bool complete = false); -const TypeObject* GetunitObject(bool complete = false); -const TypeObject* GetMinimalunitObject(); -const TypeObject* GetCompleteunitObject(); - -const TypeIdentifier* Getbit_boundIdentifier(bool complete = false); -const TypeObject* Getbit_boundObject(bool complete = false); -const TypeObject* GetMinimalbit_boundObject(); -const TypeObject* GetCompletebit_boundObject(); - -const TypeIdentifier* GetexternalIdentifier(bool complete = false); -const TypeObject* GetexternalObject(bool complete = false); -const TypeObject* GetMinimalexternalObject(); -const TypeObject* GetCompleteexternalObject(); - -const TypeIdentifier* GetnestedIdentifier(bool complete = false); -const TypeObject* GetnestedObject(bool complete = false); -const TypeObject* GetMinimalnestedObject(); -const TypeObject* GetCompletenestedObject(); - -const TypeIdentifier* GetverbatimIdentifier(bool complete = false); -const TypeObject* GetverbatimObject(bool complete = false); -const TypeObject* GetMinimalverbatimObject(); -const TypeObject* GetCompleteverbatimObject(); - -namespace verbatim -{ - const TypeIdentifier* GetPlacementKindIdentifier(bool complete = false); - const TypeObject* GetPlacementKindObject(bool complete = false); - const TypeObject* GetMinimalPlacementKindObject(); - const TypeObject* GetCompletePlacementKindObject(); -} - -const TypeIdentifier* GetserviceIdentifier(bool complete = false); -const TypeObject* GetserviceObject(bool complete = false); -const TypeObject* GetMinimalserviceObject(); -const TypeObject* GetCompleteserviceObject(); - -const TypeIdentifier* GetonewayIdentifier(bool complete = false); -const TypeObject* GetonewayObject(bool complete = false); -const TypeObject* GetMinimalonewayObject(); -const TypeObject* GetCompleteonewayObject(); - -const TypeIdentifier* GetamiIdentifier(bool complete = false); -const TypeObject* GetamiObject(bool complete = false); -const TypeObject* GetMinimalamiObject(); -const TypeObject* GetCompleteamiObject(); - -const TypeIdentifier* Getnon_serializedIdentifier(bool complete = false); -const TypeObject* Getnon_serializedObject(bool complete = false); -const TypeObject* GetMinimalnon_serializedObject(); -const TypeObject* GetCompletenon_serializedObject(); - -#endif // _BUILTIN_ANNOTATIONS_TYPE_OBJECT_H_ \ No newline at end of file diff --git a/include/fastrtps/types/DynamicData.h b/include/fastrtps/types/DynamicData.h deleted file mode 100644 index 6020b46105f..00000000000 --- a/include/fastrtps/types/DynamicData.h +++ /dev/null @@ -1,788 +0,0 @@ -// Copyright 2018 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -#ifndef TYPES_DYNAMIC_DATA_H -#define TYPES_DYNAMIC_DATA_H - -#include -#include -#include - -//#define DYNAMIC_TYPES_CHECKING - -namespace eprosima { -namespace fastdds { -namespace dds { -namespace DDSSQLFilter { - -class DDSFilterExpression; - -} // namespace DDSSQLFilter -} // namespace dds -} // namespace fastdds -} // namespace eprosima - -namespace eprosima { -namespace fastrtps { -namespace types { - -class DynamicType; -class MemberDescriptor; - -class DynamicData -{ -protected: - - DynamicData(); - DynamicData( - const DynamicData* pData); - DynamicData( - DynamicType_ptr pType); - - ~DynamicData(); - - void add_value( - TypeKind kind, - MemberId id); - - void create_members( - DynamicType_ptr pType); - - void create_members( - const DynamicData* pData); - - void clean(); - - void clean_members(); - - void* clone_value( - MemberId id, - TypeKind kind) const; - - bool compare_values( - TypeKind kind, - void* left, - void* right) const; - - ReturnCode_t insert_array_data( - MemberId indexId); - - void serialize_empty_data( - const DynamicType_ptr pType, - eprosima::fastcdr::Cdr& cdr) const; - - void set_default_value( - MemberId id); - - void get_value( - std::string& sOutValue, - MemberId id = MEMBER_ID_INVALID) const; - - void set_value( - const std::string& sValue, - MemberId id = MEMBER_ID_INVALID); - - void set_type_name( - const std::string& name); - - MemberId get_union_id() const; - - ReturnCode_t set_union_id( - MemberId id); - - void update_union_discriminator(); - - void sort_member_ids( - MemberId startId); - - void set_union_discriminator( - DynamicData* pData); - - // Serializes and deserializes the Dynamic Data. - bool deserialize( - eprosima::fastcdr::Cdr& cdr); - - bool deserialize_discriminator( - eprosima::fastcdr::Cdr& cdr); - - static size_t getCdrSerializedSize( - const DynamicData* data, - size_t current_alignment = 0); - - static size_t getEmptyCdrSerializedSize( - const DynamicType* type, - size_t current_alignment = 0); - - static size_t getKeyMaxCdrSerializedSize( - const DynamicType_ptr type, - size_t current_alignment = 0); - - static size_t getMaxCdrSerializedSize( - const DynamicType_ptr type, - size_t current_alignment = 0); - - void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - void serialize_discriminator( - eprosima::fastcdr::Cdr& cdr) const; - - void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - DynamicType_ptr type_; - std::map descriptors_; - -#ifdef DYNAMIC_TYPES_CHECKING - int32_t int32_value_; - uint32_t uint32_value_; - int16_t int16_value_; - uint16_t uint16_value_; - int64_t int64_value_; - uint64_t uint64_value_; - float float32_value_; - double float64_value_; - long double float128_value_; - char char8_value_; - wchar_t char16_value_; - octet byte_value_; - bool bool_value_; - std::string string_value_; - std::wstring wstring_value_; - std::map complex_values_; -#else - std::map values_; -#endif // ifdef DYNAMIC_TYPES_CHECKING - std::vector loaned_values_; - bool key_element_; - DynamicData* default_array_value_; - uint64_t union_label_; - MemberId union_id_; - DynamicData* union_discriminator_; - uint64_t discriminator_value_; - - friend class DynamicDataFactory; - friend class DynamicPubSubType; - friend class DynamicDataHelper; - friend class eprosima::fastdds::dds::DDSSQLFilter::DDSFilterExpression; - -public: - - RTPS_DllAPI ReturnCode_t get_descriptor( - MemberDescriptor& value, - MemberId id); - - RTPS_DllAPI ReturnCode_t set_descriptor( - MemberId id, - const MemberDescriptor* value); - - RTPS_DllAPI ReturnCode_t clear_all_values(); - - RTPS_DllAPI ReturnCode_t clear_nonkey_values(); - - RTPS_DllAPI ReturnCode_t clear_value( - MemberId id); - - RTPS_DllAPI bool equals( - const DynamicData* other) const; - - RTPS_DllAPI TypeKind get_kind() const; - - RTPS_DllAPI uint32_t get_item_count() const; - - RTPS_DllAPI std::string get_name(); - - RTPS_DllAPI MemberId get_member_id_by_name( - const std::string& name) const; - - RTPS_DllAPI MemberId get_member_id_at_index( - uint32_t index) const; - - RTPS_DllAPI DynamicData* loan_value( - MemberId id); - - RTPS_DllAPI ReturnCode_t return_loaned_value( - const DynamicData* value); - - RTPS_DllAPI MemberId get_array_index( - const std::vector& position); - - RTPS_DllAPI ReturnCode_t insert_sequence_data( - MemberId& outId); - - RTPS_DllAPI ReturnCode_t insert_int32_value( - int32_t value, - MemberId& outId); - - RTPS_DllAPI ReturnCode_t insert_uint32_value( - uint32_t value, - MemberId& outId); - - RTPS_DllAPI ReturnCode_t insert_int16_value( - int16_t value, - MemberId& outId); - - RTPS_DllAPI ReturnCode_t insert_uint16_value( - uint16_t value, - MemberId& outId); - - RTPS_DllAPI ReturnCode_t insert_int64_value( - int64_t value, - MemberId& outId); - - RTPS_DllAPI ReturnCode_t insert_uint64_value( - uint64_t value, - MemberId& outId); - - RTPS_DllAPI ReturnCode_t insert_float32_value( - float value, - MemberId& outId); - - RTPS_DllAPI ReturnCode_t insert_float64_value( - double value, - MemberId& outId); - - RTPS_DllAPI ReturnCode_t insert_float128_value( - long double value, - MemberId& outId); - - RTPS_DllAPI ReturnCode_t insert_char8_value( - char value, - MemberId& outId); - - RTPS_DllAPI ReturnCode_t insert_char16_value( - wchar_t value, - MemberId& outId); - - RTPS_DllAPI ReturnCode_t insert_byte_value( - octet value, - MemberId& outId); - - RTPS_DllAPI ReturnCode_t insert_bool_value( - bool value, - MemberId& outId); - - RTPS_DllAPI ReturnCode_t insert_string_value( - const std::string& value, - MemberId& outId); - - RTPS_DllAPI ReturnCode_t insert_wstring_value( - const std::wstring& value, - MemberId& outId); - - RTPS_DllAPI ReturnCode_t insert_enum_value( - const std::string& value, - MemberId& outId); - - RTPS_DllAPI ReturnCode_t insert_complex_value( - const DynamicData* value, - MemberId& outId); - - RTPS_DllAPI ReturnCode_t insert_complex_value( - DynamicData* value, - MemberId& outId); - - RTPS_DllAPI ReturnCode_t insert_complex_value( - DynamicData_ptr value, - MemberId& outId); - - RTPS_DllAPI ReturnCode_t remove_sequence_data( - MemberId id); - - RTPS_DllAPI ReturnCode_t clear_data(); - - RTPS_DllAPI ReturnCode_t clear_array_data( - MemberId indexId); - - RTPS_DllAPI ReturnCode_t insert_map_data( - const DynamicData* key, - MemberId& outKeyId, - MemberId& outValueId); - - RTPS_DllAPI ReturnCode_t insert_map_data( - const DynamicData* key, - DynamicData* value, - MemberId& outKey, - MemberId& outValue); - - RTPS_DllAPI ReturnCode_t insert_map_data( - const DynamicData* key, - const DynamicData* value, - MemberId& outKey, - MemberId& outValue); - - RTPS_DllAPI ReturnCode_t insert_map_data( - const DynamicData* key, - DynamicData_ptr value, - MemberId& outKey, - MemberId& outValue); - - RTPS_DllAPI ReturnCode_t remove_map_data( - MemberId keyId); - - RTPS_DllAPI ReturnCode_t get_int32_value( - int32_t& value, - MemberId id) const; - - RTPS_DllAPI ReturnCode_t set_int32_value( - int32_t value, - MemberId id = MEMBER_ID_INVALID); - - RTPS_DllAPI ReturnCode_t get_uint32_value( - uint32_t& value, - MemberId id) const; - - RTPS_DllAPI ReturnCode_t set_uint32_value( - uint32_t value, - MemberId id = MEMBER_ID_INVALID); - - RTPS_DllAPI ReturnCode_t get_int16_value( - int16_t& value, - MemberId id) const; - - RTPS_DllAPI ReturnCode_t set_int16_value( - int16_t value, - MemberId id = MEMBER_ID_INVALID); - - RTPS_DllAPI ReturnCode_t get_uint16_value( - uint16_t& value, - MemberId id) const; - - RTPS_DllAPI ReturnCode_t set_uint16_value( - uint16_t value, - MemberId id = MEMBER_ID_INVALID); - - RTPS_DllAPI ReturnCode_t get_int64_value( - int64_t& value, - MemberId id) const; - - RTPS_DllAPI ReturnCode_t set_int64_value( - int64_t value, - MemberId id = MEMBER_ID_INVALID); - - RTPS_DllAPI ReturnCode_t get_uint64_value( - uint64_t& value, - MemberId id) const; - - RTPS_DllAPI ReturnCode_t set_uint64_value( - uint64_t value, - MemberId id = MEMBER_ID_INVALID); - - RTPS_DllAPI ReturnCode_t get_float32_value( - float& value, - MemberId id) const; - - RTPS_DllAPI ReturnCode_t set_float32_value( - float value, - MemberId id = MEMBER_ID_INVALID); - - RTPS_DllAPI ReturnCode_t get_float64_value( - double& value, - MemberId id) const; - - RTPS_DllAPI ReturnCode_t set_float64_value( - double value, - MemberId id = MEMBER_ID_INVALID); - - RTPS_DllAPI ReturnCode_t get_float128_value( - long double& value, - MemberId id) const; - - RTPS_DllAPI ReturnCode_t set_float128_value( - long double value, - MemberId id = MEMBER_ID_INVALID); - - RTPS_DllAPI ReturnCode_t get_char8_value( - char& value, - MemberId id) const; - - RTPS_DllAPI ReturnCode_t set_char8_value( - char value, - MemberId id = MEMBER_ID_INVALID); - - RTPS_DllAPI ReturnCode_t get_char16_value( - wchar_t& value, - MemberId id) const; - - RTPS_DllAPI ReturnCode_t set_char16_value( - wchar_t value, - MemberId id = MEMBER_ID_INVALID); - - RTPS_DllAPI ReturnCode_t get_byte_value( - octet& value, - MemberId id) const; - - RTPS_DllAPI ReturnCode_t set_byte_value( - octet value, - MemberId id = MEMBER_ID_INVALID); - - RTPS_DllAPI ReturnCode_t get_int8_value( - int8_t& value, - MemberId id) const - { - octet aux; - ReturnCode_t result = get_byte_value(aux, id); - value = static_cast(aux); - return result; - } - - RTPS_DllAPI ReturnCode_t set_int8_value( - int8_t value, - MemberId id = MEMBER_ID_INVALID) - { - return set_byte_value(static_cast(value), id); - } - - RTPS_DllAPI ReturnCode_t get_uint8_value( - uint8_t& value, - MemberId id) const - { - octet aux; - ReturnCode_t result = get_byte_value(aux, id); - value = static_cast(aux); - return result; - } - - RTPS_DllAPI ReturnCode_t set_uint8_value( - uint8_t value, - MemberId id = MEMBER_ID_INVALID) - { - return set_byte_value(static_cast(value), id); - } - - RTPS_DllAPI ReturnCode_t get_bool_value( - bool& value, - MemberId id) const; - - RTPS_DllAPI ReturnCode_t set_bool_value( - bool value, - MemberId id = MEMBER_ID_INVALID); - - RTPS_DllAPI ReturnCode_t set_bool_value( - bool value, - const std::string& name) - { - MemberId id = get_member_id_by_name(name); - if (id != MEMBER_ID_INVALID) - { - return set_bool_value(value, id); - } - return ReturnCode_t::RETCODE_BAD_PARAMETER; - } - - RTPS_DllAPI ReturnCode_t get_string_value( - std::string& value, - MemberId id) const; - - RTPS_DllAPI ReturnCode_t set_string_value( - const std::string& value, - MemberId id = MEMBER_ID_INVALID); - - RTPS_DllAPI ReturnCode_t get_wstring_value( - std::wstring& value, - MemberId id) const; - - RTPS_DllAPI ReturnCode_t set_wstring_value( - const std::wstring& value, - MemberId id = MEMBER_ID_INVALID); - - RTPS_DllAPI ReturnCode_t get_enum_value( - std::string& value, - MemberId id) const; - - RTPS_DllAPI ReturnCode_t set_enum_value( - const std::string& value, - MemberId id = MEMBER_ID_INVALID); - - RTPS_DllAPI ReturnCode_t get_enum_value( - uint32_t& value, - MemberId id) const; - - RTPS_DllAPI ReturnCode_t set_enum_value( - const uint32_t& value, - MemberId id = MEMBER_ID_INVALID); - - RTPS_DllAPI ReturnCode_t get_bitmask_value( - uint64_t& value) const; - - RTPS_DllAPI uint64_t get_bitmask_value() const - { - uint64_t value; - if (get_bitmask_value(value) != ReturnCode_t::RETCODE_OK) - { - throw ReturnCode_t::RETCODE_BAD_PARAMETER; - } - return value; - } - - RTPS_DllAPI ReturnCode_t set_bitmask_value( - uint64_t value); - - RTPS_DllAPI ReturnCode_t get_complex_value( - DynamicData** value, - MemberId id) const; - - RTPS_DllAPI ReturnCode_t set_complex_value( - DynamicData* value, - MemberId id = MEMBER_ID_INVALID); - - RTPS_DllAPI ReturnCode_t get_union_label( - uint64_t& value) const; - - // Basic types returns (copy) - RTPS_DllAPI int32_t get_int32_value( - MemberId id) const - { - int32_t value; - if (get_int32_value(value, id) != ReturnCode_t::RETCODE_OK) - { - throw ReturnCode_t::RETCODE_BAD_PARAMETER; - } - return value; - } - - RTPS_DllAPI uint32_t get_uint32_value( - MemberId id) const - { - uint32_t value; - if (get_uint32_value(value, id) != ReturnCode_t::RETCODE_OK) - { - throw ReturnCode_t::RETCODE_BAD_PARAMETER; - } - return value; - } - - RTPS_DllAPI int16_t get_int16_value( - MemberId id) const - { - int16_t value; - if (get_int16_value(value, id) != ReturnCode_t::RETCODE_OK) - { - throw ReturnCode_t::RETCODE_BAD_PARAMETER; - } - return value; - } - - RTPS_DllAPI uint16_t get_uint16_value( - MemberId id) const - { - uint16_t value; - if (get_uint16_value(value, id) != ReturnCode_t::RETCODE_OK) - { - throw ReturnCode_t::RETCODE_BAD_PARAMETER; - } - return value; - } - - RTPS_DllAPI int64_t get_int64_value( - MemberId id) const - { - int64_t value; - if (get_int64_value(value, id) != ReturnCode_t::RETCODE_OK) - { - throw ReturnCode_t::RETCODE_BAD_PARAMETER; - } - return value; - } - - RTPS_DllAPI uint64_t get_uint64_value( - MemberId id) const - { - uint64_t value; - if (get_uint64_value(value, id) != ReturnCode_t::RETCODE_OK) - { - throw ReturnCode_t::RETCODE_BAD_PARAMETER; - } - return value; - } - - RTPS_DllAPI float get_float32_value( - MemberId id) const - { - float value; - if (get_float32_value(value, id) != ReturnCode_t::RETCODE_OK) - { - throw ReturnCode_t::RETCODE_BAD_PARAMETER; - } - return value; - } - - RTPS_DllAPI double get_float64_value( - MemberId id) const - { - double value; - if (get_float64_value(value, id) != ReturnCode_t::RETCODE_OK) - { - throw ReturnCode_t::RETCODE_BAD_PARAMETER; - } - return value; - } - - RTPS_DllAPI long double get_float128_value( - MemberId id) const - { - long double value; - if (get_float128_value(value, id) != ReturnCode_t::RETCODE_OK) - { - throw ReturnCode_t::RETCODE_BAD_PARAMETER; - } - return value; - } - - RTPS_DllAPI char get_char8_value( - MemberId id) const - { - char value; - if (get_char8_value(value, id) != ReturnCode_t::RETCODE_OK) - { - throw ReturnCode_t::RETCODE_BAD_PARAMETER; - } - return value; - } - - RTPS_DllAPI wchar_t get_char16_value( - MemberId id) const - { - wchar_t value; - if (get_char16_value(value, id) != ReturnCode_t::RETCODE_OK) - { - throw ReturnCode_t::RETCODE_BAD_PARAMETER; - } - return value; - } - - RTPS_DllAPI octet get_byte_value( - MemberId id) const - { - octet value; - if (get_byte_value(value, id) != ReturnCode_t::RETCODE_OK) - { - throw ReturnCode_t::RETCODE_BAD_PARAMETER; - } - return value; - } - - RTPS_DllAPI int8_t get_int8_value( - MemberId id) const - { - int8_t value; - if (get_int8_value(value, id) != ReturnCode_t::RETCODE_OK) - { - throw ReturnCode_t::RETCODE_BAD_PARAMETER; - } - return value; - } - - RTPS_DllAPI uint8_t get_uint8_value( - MemberId id) const - { - uint8_t value; - if (get_uint8_value(value, id) != ReturnCode_t::RETCODE_OK) - { - throw ReturnCode_t::RETCODE_BAD_PARAMETER; - } - return value; - } - - RTPS_DllAPI bool get_bool_value( - MemberId id) const - { - bool value; - if (get_bool_value(value, id) != ReturnCode_t::RETCODE_OK) - { - throw ReturnCode_t::RETCODE_BAD_PARAMETER; - } - return value; - } - - RTPS_DllAPI bool get_bool_value( - const std::string& name) const - { - MemberId id = get_member_id_by_name(name); - bool value; - if (get_bool_value(value, id) != ReturnCode_t::RETCODE_OK) - { - throw ReturnCode_t::RETCODE_BAD_PARAMETER; - } - return value; - } - - RTPS_DllAPI std::string get_string_value( - MemberId id) const - { - std::string value; - if (get_string_value(value, id) != ReturnCode_t::RETCODE_OK) - { - throw ReturnCode_t::RETCODE_BAD_PARAMETER; - } - return value; - } - - RTPS_DllAPI std::wstring get_wstring_value( - MemberId id) const - { - std::wstring value; - if (get_wstring_value(value, id) != ReturnCode_t::RETCODE_OK) - { - throw ReturnCode_t::RETCODE_BAD_PARAMETER; - } - return value; - } - - RTPS_DllAPI std::string get_enum_value( - MemberId id) const - { - std::string value; - if (get_enum_value(value, id) != ReturnCode_t::RETCODE_OK) - { - throw ReturnCode_t::RETCODE_BAD_PARAMETER; - } - return value; - } - - RTPS_DllAPI uint64_t get_union_label() const - { - uint64_t value; - if (get_union_label(value) != ReturnCode_t::RETCODE_OK) - { - throw ReturnCode_t::RETCODE_BAD_PARAMETER; - } - return value; - } - - RTPS_DllAPI uint64_t get_discriminator_value() const - { - return discriminator_value_; - } - - RTPS_DllAPI void get_discriminator_value( - uint64_t& outValue) const - { - outValue = discriminator_value_; - } - - RTPS_DllAPI void set_discriminator_value( - uint64_t value) - { - discriminator_value_ = value; - } - -}; - - -} // namespace types -} // namespace fastrtps -} // namespace eprosima - -#endif // TYPES_DYNAMIC_DATA_H diff --git a/include/fastrtps/types/DynamicDataFactory.h b/include/fastrtps/types/DynamicDataFactory.h deleted file mode 100644 index db87510f51a..00000000000 --- a/include/fastrtps/types/DynamicDataFactory.h +++ /dev/null @@ -1,68 +0,0 @@ -// Copyright 2018 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -#ifndef TYPES_DYNAMIC_DATA_FACTORY_H -#define TYPES_DYNAMIC_DATA_FACTORY_H - -#include -#include -#include -#include -#include -#include - -//#define DISABLE_DYNAMIC_MEMORY_CHECK - -namespace eprosima { -namespace fastrtps { -namespace types { - -class DynamicDataFactory -{ -protected: - DynamicDataFactory(); - - ReturnCode_t create_members( - DynamicData* pData, - DynamicType_ptr pType); - -#ifndef DISABLE_DYNAMIC_MEMORY_CHECK - std::vector dynamic_datas_; - mutable std::recursive_mutex mutex_; -#endif - -public: - ~DynamicDataFactory(); - - RTPS_DllAPI static DynamicDataFactory* get_instance(); - - RTPS_DllAPI static ReturnCode_t delete_instance(); - - RTPS_DllAPI DynamicData* create_data(DynamicTypeBuilder* pBuilder); - - RTPS_DllAPI DynamicData* create_data(DynamicType_ptr pType); - - RTPS_DllAPI DynamicData* create_copy(const DynamicData* pData); - - RTPS_DllAPI ReturnCode_t delete_data(DynamicData* pData); - - RTPS_DllAPI bool is_empty() const; -}; - - -} // namespace types -} // namespace fastrtps -} // namespace eprosima - -#endif // TYPES_DYNAMIC_DATA_FACTORY_H diff --git a/include/fastrtps/types/DynamicDataHelper.hpp b/include/fastrtps/types/DynamicDataHelper.hpp deleted file mode 100644 index 9f1b17d28c0..00000000000 --- a/include/fastrtps/types/DynamicDataHelper.hpp +++ /dev/null @@ -1,127 +0,0 @@ -// Copyright 2019 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -#ifndef _FASTRTPS_TYPES_DYNAMICDATAHELPER_HPP_ -#define _FASTRTPS_TYPES_DYNAMICDATAHELPER_HPP_ - -#include -#include -#include -#include -#include -#include - -namespace eprosima { -namespace fastrtps { -namespace types { - -class DynamicDataHelper -{ -public: - - RTPS_DllAPI static void print( - const DynamicData_ptr& data); - - RTPS_DllAPI static std::ostream& print( - std::ostream& output, - const DynamicData_ptr& data); - - RTPS_DllAPI static void print( - const DynamicData* data); - - RTPS_DllAPI static std::ostream& print( - std::ostream& output, - const DynamicData* data); - -protected: - - static void print_basic_element( - DynamicData* data, - MemberId id, - TypeKind kind); - - static void print_basic_element( - DynamicData* data, - MemberId id, - TypeKind kind, - std::ostream& output); - - static void print_collection( - DynamicData* data, - const std::string& tabs = ""); - - static void print_collection( - DynamicData* data, - std::ostream& output, - const std::string& tabs = ""); - - static void fill_array_positions( - const std::vector& bounds, - std::vector>& positions); - - static void get_index_position( - uint32_t index, - const std::vector& bounds, - std::vector& position); - - static void aux_index_position( - uint32_t index, - uint32_t inner_index, - const std::vector& bounds, - std::vector& position); - - static void print_basic_collection( - DynamicData* data); - - static void print_basic_collection( - DynamicData* data, - std::ostream& output); - - static void print_complex_collection( - DynamicData* data, - const std::string& tabs = ""); - - static void print_complex_collection( - DynamicData* data, - std::ostream& output, - const std::string& tabs = ""); - - static void print_complex_element( - DynamicData* data, - MemberId id, - const std::string& tabs = ""); - - static void print_complex_element( - DynamicData* data, - MemberId id, - std::ostream& output, - const std::string& tabs = ""); - - static void print_member( - DynamicData* data, - const DynamicTypeMember* type, - const std::string& tabs = ""); - - static void print_member( - DynamicData* data, - std::ostream& output, - const DynamicTypeMember* type, - const std::string& tabs = ""); -}; - -} // namespace types -} // namespace fastrtps -} // namespace eprosima - -#endif // _FASTRTPS_TYPES_DYNAMICDATAHELPER_HPP_ diff --git a/include/fastrtps/types/DynamicDataPtr.h b/include/fastrtps/types/DynamicDataPtr.h deleted file mode 100644 index 342cd274f6d..00000000000 --- a/include/fastrtps/types/DynamicDataPtr.h +++ /dev/null @@ -1,63 +0,0 @@ -// Copyright 2018 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -#ifndef TYPES_DYNAMIC_DATA_PTR_H -#define TYPES_DYNAMIC_DATA_PTR_H - -#include - -namespace eprosima { -namespace fastrtps { -namespace types { - -class DynamicData; - -class DynamicData_ptr : public std::shared_ptr -{ -public: - - typedef std::shared_ptr Base; - - using Base::operator->; - using Base::operator*; - using Base::operator bool; - - RTPS_DllAPI DynamicData_ptr() - { - } - - RTPS_DllAPI explicit DynamicData_ptr( - DynamicData* pData); - - RTPS_DllAPI DynamicData_ptr( - const DynamicData_ptr& other) = default; - - RTPS_DllAPI DynamicData_ptr( - DynamicData_ptr&& other) = default; - - RTPS_DllAPI DynamicData_ptr& operator =( - const DynamicData_ptr&) = default; - - RTPS_DllAPI DynamicData_ptr& operator =( - DynamicData_ptr&&) = default; - - RTPS_DllAPI DynamicData_ptr& operator =( - DynamicData*); -}; - -} // namespace types -} // namespace fastrtps -} // namespace eprosima - -#endif // TYPES_DYNAMIC_DATA_PTR_H diff --git a/include/fastrtps/types/DynamicPubSubType.h b/include/fastrtps/types/DynamicPubSubType.h deleted file mode 100644 index e7ac0a8a80c..00000000000 --- a/include/fastrtps/types/DynamicPubSubType.h +++ /dev/null @@ -1,106 +0,0 @@ -// Copyright 2018 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -#ifndef TYPES_DYNAMIC_PUB_SUB_TYPE_H -#define TYPES_DYNAMIC_PUB_SUB_TYPE_H - -#include -#include -#include -#include -#include - -namespace eprosima { -namespace fastrtps { -namespace types { - -class DynamicPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -protected: - - void UpdateDynamicTypeInfo(); - - DynamicType_ptr dynamic_type_; - MD5 m_md5; - unsigned char* m_keyBuffer; - - enum - { - FINAL, - APPENDABLE, - MUTABLE - } - extensibility_ {APPENDABLE}; - -public: - - RTPS_DllAPI DynamicPubSubType(); - - RTPS_DllAPI DynamicPubSubType( - DynamicType_ptr pDynamicType); - - RTPS_DllAPI virtual ~DynamicPubSubType(); - - RTPS_DllAPI void* createData() override; - - RTPS_DllAPI void deleteData ( - void* data) override; - - RTPS_DllAPI bool deserialize ( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - RTPS_DllAPI bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - RTPS_DllAPI std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - RTPS_DllAPI std::function getSerializedSizeProvider( - void* data, - fastdds::dds::DataRepresentationId_t data_representation) override; - - RTPS_DllAPI bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - RTPS_DllAPI bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - fastdds::dds::DataRepresentationId_t data_representation) override; - - RTPS_DllAPI void CleanDynamicType(); - - RTPS_DllAPI DynamicType_ptr GetDynamicType() const; - - RTPS_DllAPI ReturnCode_t SetDynamicType( - DynamicData_ptr pData); - - RTPS_DllAPI ReturnCode_t SetDynamicType( - DynamicType_ptr pType); -}; - -} // namespace types -} // namespace fastrtps -} // namespace eprosima - -#endif // TYPES_DYNAMIC_PUB_SUB_TYPE_H diff --git a/include/fastrtps/types/DynamicType.h b/include/fastrtps/types/DynamicType.h deleted file mode 100644 index ab2e81fa938..00000000000 --- a/include/fastrtps/types/DynamicType.h +++ /dev/null @@ -1,180 +0,0 @@ -// Copyright 2018 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -#ifndef TYPES_DYNAMIC_TYPE_H -#define TYPES_DYNAMIC_TYPE_H - -#include -#include - -namespace eprosima { - -namespace fastdds { -namespace dds { -class DomainParticipantImpl; -} // namespace dds -} // namespace fastdds - -namespace fastrtps { -namespace types { - -class AnnotationDescriptor; -class TypeDescriptor; -class DynamicTypeMember; -class DynamicTypeBuilder; - -class DynamicType -{ -protected: - - friend class DynamicTypeBuilder; - friend class DynamicTypeBuilderFactory; - friend class MemberDescriptor; - friend class TypeDescriptor; - friend class DynamicData; - friend class DynamicDataFactory; - friend class AnnotationDescriptor; - friend class TypeObjectFactory; - friend class DynamicTypeMember; - friend class DynamicDataHelper; - friend class fastdds::dds::DomainParticipantImpl; - - DynamicType(); - - RTPS_DllAPI DynamicType( - const TypeDescriptor* descriptor); - - DynamicType( - const DynamicTypeBuilder* other); - - RTPS_DllAPI virtual ~DynamicType(); - - RTPS_DllAPI virtual void clear(); - - ReturnCode_t copy_from_builder( - const DynamicTypeBuilder* other); - - // Checks if there is a member with the given name. - bool exists_member_by_name( - const std::string& name) const; - - // This method is used by Dynamic Data to override the name of the types based on ALIAS. - void set_name( - const std::string& name); - - ReturnCode_t apply_annotation( - AnnotationDescriptor& descriptor); - - ReturnCode_t apply_annotation( - const std::string& annotation_name, - const std::string& key, - const std::string& value); - - ReturnCode_t apply_annotation_to_member( - MemberId id, - AnnotationDescriptor& descriptor); - - ReturnCode_t apply_annotation_to_member( - MemberId id, - const std::string& annotation_name, - const std::string& key, - const std::string& value); - - ReturnCode_t get_annotation( - AnnotationDescriptor& descriptor, - uint32_t idx); - - uint32_t get_annotation_count(); - - DynamicType_ptr get_base_type() const; - - DynamicType_ptr get_discriminator_type() const; - - DynamicType_ptr get_element_type() const; - - DynamicType_ptr get_key_element_type() const; - - ReturnCode_t get_member( - DynamicTypeMember& member, - MemberId id); - - ReturnCode_t get_member_by_name( - DynamicTypeMember& member, - const std::string& name); - - TypeDescriptor* descriptor_; - std::map member_by_id_; // Aggregated members - std::map member_by_name_; // Uses the pointers from "member_by_id_". - std::string name_; - TypeKind kind_; - bool is_key_defined_; - -public: - - RTPS_DllAPI bool equals( - const DynamicType* other) const; - - RTPS_DllAPI ReturnCode_t get_all_members( - std::map& members); - - RTPS_DllAPI ReturnCode_t get_all_members_by_name( - std::map& members); - - RTPS_DllAPI uint32_t get_bounds( - uint32_t index = 0) const; - - RTPS_DllAPI uint32_t get_bounds_size() const; - - RTPS_DllAPI ReturnCode_t get_descriptor( - TypeDescriptor* descriptor) const; - - RTPS_DllAPI const TypeDescriptor* get_descriptor() const; - - RTPS_DllAPI TypeDescriptor* get_descriptor(); - - RTPS_DllAPI bool key_annotation() const; - - RTPS_DllAPI inline TypeKind get_kind() const - { - return kind_; - } - - RTPS_DllAPI std::string get_name() const; - - RTPS_DllAPI MemberId get_members_count() const; - - RTPS_DllAPI uint32_t get_total_bounds() const; - - RTPS_DllAPI const TypeDescriptor* get_type_descriptor() const - { - return descriptor_; - } - - RTPS_DllAPI bool has_children() const; - - RTPS_DllAPI bool is_consistent() const; - - RTPS_DllAPI bool is_complex_kind() const; - - RTPS_DllAPI bool is_discriminator_type() const; - - RTPS_DllAPI size_t get_size() const; - -}; - -} // namespace types -} // namespace fastrtps -} // namespace eprosima - -#endif // TYPES_DYNAMIC_TYPE_H diff --git a/include/fastrtps/types/DynamicTypeBuilder.h b/include/fastrtps/types/DynamicTypeBuilder.h deleted file mode 100644 index 1d26ea66e19..00000000000 --- a/include/fastrtps/types/DynamicTypeBuilder.h +++ /dev/null @@ -1,167 +0,0 @@ -// Copyright 2018 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -#ifndef TYPES_DYNAMIC_TYPE_BUILDER_H -#define TYPES_DYNAMIC_TYPE_BUILDER_H - -#include -#include - -namespace eprosima { -namespace fastrtps { -namespace types { - -class AnnotationDescriptor; -class TypeDescriptor; -class MemberDescriptor; -class DynamicType; -class DynamicTypeMember; - -class DynamicTypeBuilder -{ -protected: - DynamicTypeBuilder(); - - DynamicTypeBuilder(const DynamicTypeBuilder* builder); - - DynamicTypeBuilder(const TypeDescriptor* descriptor); - - virtual ~DynamicTypeBuilder(); - - friend class DynamicType; - friend class DynamicTypeBuilderFactory; - - TypeDescriptor* descriptor_; - std::map member_by_id_; // Aggregated members - std::map member_by_name_; // Uses the pointers from "member_by_id_". - std::string name_; - TypeKind kind_; - MemberId current_member_id_; - uint32_t max_index_; - - ReturnCode_t _apply_annotation_to_member( - MemberId id, - AnnotationDescriptor& descriptor); - - ReturnCode_t _apply_annotation_to_member( - MemberId id, - const std::string& annotation_name, - const std::string& key, - const std::string& value); - - bool check_union_configuration(const MemberDescriptor* descriptor); - - // Checks if there is a member with the given name. - bool exists_member_by_name(const std::string& name) const; - - void refresh_member_ids(); - - void clear(); - - ReturnCode_t copy_from_builder(const DynamicTypeBuilder* other); - -public: - RTPS_DllAPI ReturnCode_t add_empty_member( - uint32_t index, - const std::string& name); - - RTPS_DllAPI ReturnCode_t add_member(const MemberDescriptor* descriptor); - - RTPS_DllAPI ReturnCode_t add_member( - MemberId id, - const std::string& name, - DynamicTypeBuilder* type_ = nullptr); - - RTPS_DllAPI ReturnCode_t add_member( - MemberId id, - const std::string& name, - DynamicTypeBuilder* type_, - const std::string& defaultValue); - - RTPS_DllAPI ReturnCode_t add_member( - MemberId id, - const std::string& name, - DynamicTypeBuilder* type_, - const std::string& defaultValue, - const std::vector& unionLabels, - bool isDefaultLabel); - - RTPS_DllAPI ReturnCode_t add_member( - MemberId id, - const std::string& name, - DynamicType_ptr type_ = DynamicType_ptr(nullptr)); - - RTPS_DllAPI ReturnCode_t add_member( - MemberId id, - const std::string& name, - DynamicType_ptr type_, - const std::string& defaultValue); - - RTPS_DllAPI ReturnCode_t add_member( - MemberId id, - const std::string& name, - DynamicType_ptr type_, - const std::string& defaultValue, - const std::vector& unionLabels, - bool isDefaultLabel); - - RTPS_DllAPI ReturnCode_t apply_annotation(AnnotationDescriptor& descriptor); - - RTPS_DllAPI ReturnCode_t apply_annotation( - const std::string& annotation_name, - const std::string& key, - const std::string& value); - - RTPS_DllAPI ReturnCode_t apply_annotation_to_member( - MemberId id, - AnnotationDescriptor& descriptor); - - RTPS_DllAPI ReturnCode_t apply_annotation_to_member( - MemberId id, - const std::string& annotation_name, - const std::string& key, - const std::string& value); - - RTPS_DllAPI DynamicType_ptr build(); - - RTPS_DllAPI ReturnCode_t copy_from(const DynamicTypeBuilder* other); - - ReturnCode_t get_all_members(std::map& members); - - RTPS_DllAPI inline TypeKind get_kind() const - { - return kind_; - } - - RTPS_DllAPI std::string get_name() const; - - RTPS_DllAPI MemberId get_member_id_by_name(const std::string& name) const; - - const TypeDescriptor* get_type_descriptor() const - { - return descriptor_; - } - - bool is_consistent() const; - - bool is_discriminator_type() const; - - RTPS_DllAPI ReturnCode_t set_name(const std::string& name); -}; - -} // namespace types -} // namespace fastrtps -} // namespace eprosima - -#endif // TYPES_DYNAMIC_TYPE_BUILDER_H diff --git a/include/fastrtps/types/DynamicTypeBuilderFactory.h b/include/fastrtps/types/DynamicTypeBuilderFactory.h deleted file mode 100644 index 3fa52ea39b8..00000000000 --- a/include/fastrtps/types/DynamicTypeBuilderFactory.h +++ /dev/null @@ -1,317 +0,0 @@ -// Copyright 2018 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -#ifndef TYPES_DYNAMIC_TYPE_BUILDER_FACTORY_H -#define TYPES_DYNAMIC_TYPE_BUILDER_FACTORY_H - -#include -#include -#include -#include - -//#define DISABLE_DYNAMIC_MEMORY_CHECK - -namespace eprosima { -namespace fastrtps { -namespace types { - -class AnnotationDescriptor; -class DynamicTypeBuilder; -class TypeDescriptor; -class TypeIdentifier; -class MemberDescriptor; -class TypeObject; -class DynamicType; -class DynamicType_ptr; -class AnnotationParameterValue; - -class DynamicTypeBuilderFactory -{ -protected: - - DynamicTypeBuilderFactory(); - - inline void add_builder_to_list( - DynamicTypeBuilder* pBuilder); - - DynamicType_ptr build_type( - DynamicType_ptr other); - - void build_alias_type_code( - const TypeDescriptor* descriptor, - TypeObject& object, - bool complete = true) const; - - void build_string8_type_code( - const TypeDescriptor* descriptor) const; - - void build_string16_type_code( - const TypeDescriptor* descriptor) const; - - void build_sequence_type_code( - const TypeDescriptor* descriptor, - TypeObject& object, - bool complete = true) const; - - void build_array_type_code( - const TypeDescriptor* descriptor, - TypeObject& object, - bool complete = true) const; - - void build_map_type_code( - const TypeDescriptor* descriptor, - TypeObject& object, - bool complete = true) const; - - void build_enum_type_code( - const TypeDescriptor* descriptor, - TypeObject& object, - const std::vector members, - bool complete = true) const; - - void build_struct_type_code( - const TypeDescriptor* descriptor, - TypeObject& object, - const std::vector members, - bool complete = true) const; - - void build_union_type_code( - const TypeDescriptor* descriptor, - TypeObject& object, - const std::vector members, - bool complete = true) const; - - void build_bitset_type_code( - const TypeDescriptor* descriptor, - TypeObject& object, - const std::vector members, - bool complete = true) const; - - void build_bitmask_type_code( - const TypeDescriptor* descriptor, - TypeObject& object, - const std::vector members, - bool complete = true) const; - - void build_annotation_type_code( - const TypeDescriptor* descriptor, - TypeObject& object, - const std::vector members, - bool complete = true) const; - - void set_annotation_default_value( - AnnotationParameterValue& apv, - const MemberDescriptor* member) const; - - void apply_type_annotations( - AppliedAnnotationSeq& annotations, - const TypeDescriptor* descriptor) const; - -#ifndef DISABLE_DYNAMIC_MEMORY_CHECK - std::vector builders_list_; - mutable std::recursive_mutex mutex_; -#endif // ifndef DISABLE_DYNAMIC_MEMORY_CHECK - -public: - - RTPS_DllAPI static DynamicTypeBuilderFactory* get_instance(); - - RTPS_DllAPI static ReturnCode_t delete_instance(); - - ~DynamicTypeBuilderFactory(); - - RTPS_DllAPI DynamicType_ptr get_primitive_type( - TypeKind kind); - - RTPS_DllAPI ReturnCode_t delete_builder( - DynamicTypeBuilder* builder); - - RTPS_DllAPI ReturnCode_t delete_type( - DynamicType* type); - - RTPS_DllAPI DynamicTypeBuilder* create_custom_builder( - const TypeDescriptor* descriptor, - const std::string& name = ""); - - RTPS_DllAPI DynamicTypeBuilder* create_builder_copy( - const DynamicTypeBuilder* type); - - RTPS_DllAPI DynamicTypeBuilder* create_int32_builder(); - - RTPS_DllAPI DynamicTypeBuilder* create_uint32_builder(); - - RTPS_DllAPI DynamicTypeBuilder* create_int16_builder(); - - RTPS_DllAPI DynamicTypeBuilder* create_uint16_builder(); - - RTPS_DllAPI DynamicTypeBuilder* create_int64_builder(); - - RTPS_DllAPI DynamicTypeBuilder* create_uint64_builder(); - - RTPS_DllAPI DynamicTypeBuilder* create_float32_builder(); - - RTPS_DllAPI DynamicTypeBuilder* create_float64_builder(); - - RTPS_DllAPI DynamicTypeBuilder* create_float128_builder(); - - RTPS_DllAPI DynamicTypeBuilder* create_char8_builder(); - - RTPS_DllAPI DynamicTypeBuilder* create_char16_builder(); - - RTPS_DllAPI DynamicTypeBuilder* create_bool_builder(); - - RTPS_DllAPI DynamicTypeBuilder* create_byte_builder(); - - RTPS_DllAPI DynamicTypeBuilder* create_string_builder( - uint32_t bound = MAX_STRING_LENGTH); - - RTPS_DllAPI DynamicTypeBuilder* create_wstring_builder( - uint32_t bound = MAX_STRING_LENGTH); - - RTPS_DllAPI DynamicTypeBuilder* create_sequence_builder( - const DynamicTypeBuilder* element_type, - uint32_t bound = MAX_ELEMENTS_COUNT); - - RTPS_DllAPI DynamicTypeBuilder* create_sequence_builder( - const DynamicType_ptr type, - uint32_t bound = MAX_ELEMENTS_COUNT); - - RTPS_DllAPI DynamicTypeBuilder* create_array_builder( - const DynamicTypeBuilder* element_type, - const std::vector& bounds); - - RTPS_DllAPI DynamicTypeBuilder* create_array_builder( - const DynamicType_ptr type, - const std::vector& bounds); - - RTPS_DllAPI DynamicTypeBuilder* create_map_builder( - DynamicTypeBuilder* key_element_type, - DynamicTypeBuilder* element_type, - uint32_t bound = MAX_ELEMENTS_COUNT); - - RTPS_DllAPI DynamicTypeBuilder* create_map_builder( - DynamicType_ptr key_type, - DynamicType_ptr value_type, - uint32_t bound = MAX_ELEMENTS_COUNT); - - RTPS_DllAPI DynamicTypeBuilder* create_bitmask_builder( - uint32_t bound); - - RTPS_DllAPI DynamicTypeBuilder* create_bitset_builder(); - - RTPS_DllAPI DynamicTypeBuilder* create_alias_builder( - DynamicTypeBuilder* base_type, - const std::string& sName); - - RTPS_DllAPI DynamicTypeBuilder* create_alias_builder( - DynamicType_ptr base_type, - const std::string& sName); - - RTPS_DllAPI DynamicTypeBuilder* create_enum_builder(); - - RTPS_DllAPI DynamicTypeBuilder* create_struct_builder(); - - RTPS_DllAPI DynamicTypeBuilder* create_child_struct_builder( - DynamicTypeBuilder* parent_type); - - RTPS_DllAPI DynamicTypeBuilder* create_union_builder( - DynamicTypeBuilder* discriminator_type); - - RTPS_DllAPI DynamicTypeBuilder* create_union_builder( - DynamicType_ptr discriminator_type); - - RTPS_DllAPI DynamicType_ptr create_annotation_primitive( - const std::string& name); - - RTPS_DllAPI DynamicType_ptr create_type( - const TypeDescriptor* descriptor, - const std::string& name = ""); - - RTPS_DllAPI DynamicType_ptr create_type( - const DynamicTypeBuilder* other); - - RTPS_DllAPI DynamicType_ptr create_alias_type( - DynamicTypeBuilder* base_type, - const std::string& sName); - - RTPS_DllAPI DynamicType_ptr create_alias_type( - DynamicType_ptr base_type, - const std::string& sName); - - RTPS_DllAPI DynamicType_ptr create_int32_type(); - - RTPS_DllAPI DynamicType_ptr create_uint32_type(); - - RTPS_DllAPI DynamicType_ptr create_int16_type(); - - RTPS_DllAPI DynamicType_ptr create_uint16_type(); - - RTPS_DllAPI DynamicType_ptr create_int64_type(); - - RTPS_DllAPI DynamicType_ptr create_uint64_type(); - - RTPS_DllAPI DynamicType_ptr create_float32_type(); - - RTPS_DllAPI DynamicType_ptr create_float64_type(); - - RTPS_DllAPI DynamicType_ptr create_float128_type(); - - RTPS_DllAPI DynamicType_ptr create_char8_type(); - - RTPS_DllAPI DynamicType_ptr create_char16_type(); - - RTPS_DllAPI DynamicType_ptr create_bool_type(); - - RTPS_DllAPI DynamicType_ptr create_byte_type(); - - RTPS_DllAPI DynamicType_ptr create_string_type( - uint32_t bound = MAX_STRING_LENGTH); - - RTPS_DllAPI DynamicType_ptr create_wstring_type( - uint32_t bound = MAX_STRING_LENGTH); - - RTPS_DllAPI DynamicType_ptr create_bitset_type( - uint32_t bound); - - RTPS_DllAPI void build_type_identifier( - const DynamicType_ptr type, - TypeIdentifier& identifier, - bool complete = true) const; - - RTPS_DllAPI void build_type_identifier( - const TypeDescriptor* descriptor, - TypeIdentifier& identifier, - bool complete = true) const; - - RTPS_DllAPI void build_type_object( - const DynamicType_ptr type, - TypeObject& object, - bool complete = true, - bool force = false) const; - - RTPS_DllAPI void build_type_object( - const TypeDescriptor* descriptor, - TypeObject& object, - const std::vector* members = nullptr, - bool complete = true, - bool force = false) const; - - RTPS_DllAPI bool is_empty() const; -}; - -} // namespace types -} // namespace fastrtps -} // namespace eprosima - -#endif // TYPES_DYNAMIC_TYPE_BUILDER_FACTORY_H diff --git a/include/fastrtps/types/DynamicTypeBuilderPtr.h b/include/fastrtps/types/DynamicTypeBuilderPtr.h deleted file mode 100644 index f3bb41e3fdb..00000000000 --- a/include/fastrtps/types/DynamicTypeBuilderPtr.h +++ /dev/null @@ -1,67 +0,0 @@ -// Copyright 2018 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -#ifndef TYPES_DYNAMIC_TYPE_BUILDER_PTR_H -#define TYPES_DYNAMIC_TYPE_BUILDER_PTR_H - -#include - -namespace eprosima { -namespace fastrtps { -namespace types { - -class DynamicTypeBuilder; - -class DynamicTypeBuilder_ptr : public std::shared_ptr -{ -public: - - typedef std::shared_ptr Base; - - using Base::operator ->; - using Base::operator *; - using Base::operator bool; - - RTPS_DllAPI DynamicTypeBuilder_ptr() - { - } - - RTPS_DllAPI DynamicTypeBuilder_ptr( - DynamicTypeBuilder* pType); - - RTPS_DllAPI DynamicTypeBuilder_ptr( - DynamicTypeBuilder_ptr&& other) = default; - - RTPS_DllAPI DynamicTypeBuilder_ptr& operator =( - DynamicTypeBuilder_ptr&&) = default; - - RTPS_DllAPI bool operator !=( - std::nullptr_t) const - { - return bool(*this); - } - - RTPS_DllAPI bool operator ==( - std::nullptr_t) const - { - return !*this; - } - -}; - -} // namespace types -} // namespace fastrtps -} // namespace eprosima - -#endif // TYPES_DYNAMIC_TYPE_BUILDER_PTR_H diff --git a/include/fastrtps/types/DynamicTypeMember.h b/include/fastrtps/types/DynamicTypeMember.h deleted file mode 100644 index 5cef28d9c32..00000000000 --- a/include/fastrtps/types/DynamicTypeMember.h +++ /dev/null @@ -1,102 +0,0 @@ -// Copyright 2018 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -#ifndef TYPES_DYNAMIC_TYPE_MEMBER_H -#define TYPES_DYNAMIC_TYPE_MEMBER_H - -#include -#include - -namespace eprosima { -namespace fastrtps { -namespace types { - -class AnnotationDescriptor; -class DynamicType; - -class DynamicTypeMember -{ -protected: - - DynamicType* parent_; - MemberDescriptor descriptor_; - MemberId id_; - - uint32_t get_index() const; - - void set_index( - uint32_t index); - - void set_parent( - DynamicType* pType); - - friend class DynamicTypeBuilder; - friend class DynamicType; - friend class DynamicData; - -public: - - RTPS_DllAPI DynamicTypeMember(); - - RTPS_DllAPI DynamicTypeMember( - const DynamicTypeMember* other); - - RTPS_DllAPI DynamicTypeMember( - const MemberDescriptor* descriptor, - MemberId id); - - ~DynamicTypeMember(); - - RTPS_DllAPI ReturnCode_t apply_annotation( - AnnotationDescriptor& descriptor); - - RTPS_DllAPI ReturnCode_t apply_annotation( - const std::string& annotation_name, - const std::string& key, - const std::string& value); - - RTPS_DllAPI bool equals( - const DynamicTypeMember*) const; - - RTPS_DllAPI ReturnCode_t get_annotation( - AnnotationDescriptor& descriptor, - uint32_t idx); - - RTPS_DllAPI uint32_t get_annotation_count(); - - RTPS_DllAPI bool key_annotation() const; - - RTPS_DllAPI std::vector get_union_labels() const; - - RTPS_DllAPI ReturnCode_t get_descriptor( - MemberDescriptor* descriptor) const; - - RTPS_DllAPI MemberId get_id() const; - - RTPS_DllAPI std::string get_name() const; - - RTPS_DllAPI bool is_default_union_value() const; - - RTPS_DllAPI const MemberDescriptor* get_descriptor() const - { - return &descriptor_; - } - -}; - -} // namespace types -} // namespace fastrtps -} // namespace eprosima - -#endif // TYPES_DYNAMIC_TYPE_MEMBER_H diff --git a/include/fastrtps/types/DynamicTypePtr.h b/include/fastrtps/types/DynamicTypePtr.h deleted file mode 100644 index b37119ccff8..00000000000 --- a/include/fastrtps/types/DynamicTypePtr.h +++ /dev/null @@ -1,76 +0,0 @@ -// Copyright 2018 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -#ifndef TYPES_DYNAMIC_TYPE_PTR_H -#define TYPES_DYNAMIC_TYPE_PTR_H - -#include - -namespace eprosima { -namespace fastrtps { -namespace types { - -class DynamicType; - -class DynamicType_ptr : public std::shared_ptr -{ -public: - - typedef std::shared_ptr Base; - - using Base::operator ->; - using Base::operator *; - using Base::operator bool; - - DynamicType_ptr() - { - } - - RTPS_DllAPI explicit DynamicType_ptr( - DynamicType* pType); - - RTPS_DllAPI DynamicType_ptr( - const DynamicType_ptr& other) = default; - - RTPS_DllAPI DynamicType_ptr( - DynamicType_ptr&& other) = default; - - RTPS_DllAPI DynamicType_ptr& operator =( - const DynamicType_ptr&) = default; - - RTPS_DllAPI DynamicType_ptr& operator =( - DynamicType_ptr&&) = default; - - RTPS_DllAPI DynamicType_ptr& operator =( - DynamicType*); - - RTPS_DllAPI bool operator !=( - std::nullptr_t) const - { - return bool(*this); - } - - RTPS_DllAPI bool operator ==( - std::nullptr_t) const - { - return !*this; - } - -}; - -} // namespace types -} // namespace fastrtps -} // namespace eprosima - -#endif // TYPES_DYNAMIC_TYPE_PTR_H diff --git a/include/fastrtps/types/MemberDescriptor.h b/include/fastrtps/types/MemberDescriptor.h deleted file mode 100644 index 5a52948a4c7..00000000000 --- a/include/fastrtps/types/MemberDescriptor.h +++ /dev/null @@ -1,223 +0,0 @@ -// Copyright 2018 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -#ifndef TYPES_MEMBER_DESCRIPTOR_H -#define TYPES_MEMBER_DESCRIPTOR_H - -#include -#include - -namespace eprosima { -namespace fastrtps { -namespace types { - -class DynamicType; -class AnnotationDescriptor; - -class MemberDescriptor -{ -protected: - - std::string name_; // Name of the member - MemberId id_; // MemberId, it should be filled automatically when the member is added. - DynamicType_ptr type_; // Member's Type. - std::string default_value_; // Default value of the member in string. - uint32_t index_; // Definition order of the member inside it's parent. - std::vector labels_; // Case Labels for unions. - bool default_label_; // TRUE if it's the default option of a union. - - std::vector annotation_; // Annotations to apply - - friend class DynamicTypeBuilderFactory; - friend class DynamicData; - friend class DynamicTypeMember; - friend class TypeObjectFactory; - - bool is_default_value_consistent( - const std::string& sDefaultValue) const; - - bool is_type_name_consistent( - const std::string& sName) const; - - void copy_annotations_from_type( - const DynamicType_ptr& type); - -public: - - RTPS_DllAPI MemberDescriptor(); - - RTPS_DllAPI MemberDescriptor( - uint32_t index, - const std::string& name); - - RTPS_DllAPI MemberDescriptor( - MemberId id, - const std::string& name, - DynamicType_ptr type); - - RTPS_DllAPI MemberDescriptor( - MemberId id, - const std::string& name, - DynamicType_ptr type, - const std::string& defaultValue); - - RTPS_DllAPI MemberDescriptor( - MemberId id, - const std::string& name, - DynamicType_ptr type, - const std::string& defaultValue, - const std::vector& unionLabels, - bool isDefaultLabel); - - RTPS_DllAPI MemberDescriptor( - const MemberDescriptor* descriptor); - - RTPS_DllAPI ~MemberDescriptor(); - - bool check_union_labels( - const std::vector& labels) const; - - RTPS_DllAPI ReturnCode_t copy_from( - const MemberDescriptor* other); - - RTPS_DllAPI bool equals( - const MemberDescriptor* other) const; - - RTPS_DllAPI TypeKind get_kind() const; - - RTPS_DllAPI MemberId get_id() const; - - RTPS_DllAPI uint32_t get_index() const; - - RTPS_DllAPI std::string get_name() const; - - RTPS_DllAPI std::vector get_union_labels() const; - - RTPS_DllAPI std::string get_default_value() const - { - if (!default_value_.empty()) - { - return default_value_; - } - // Try annotation - return annotation_get_default(); - } - - RTPS_DllAPI bool is_default_union_value() const; - - RTPS_DllAPI bool is_consistent( - TypeKind parentKind) const; - - RTPS_DllAPI void add_union_case_index( - uint64_t value); - - RTPS_DllAPI void set_id( - MemberId id); - - RTPS_DllAPI void set_index( - uint32_t index); - - RTPS_DllAPI void set_name( - const std::string& name); - - RTPS_DllAPI void set_type( - DynamicType_ptr type); - - RTPS_DllAPI DynamicType_ptr get_type() const - { - return type_; - } - - RTPS_DllAPI void set_default_union_value( - bool bDefault); - - RTPS_DllAPI void set_default_value( - const std::string& value) - { - default_value_ = value; - } - - // Annotations - ReturnCode_t apply_annotation( - AnnotationDescriptor& descriptor); - - ReturnCode_t apply_annotation( - const std::string& annotation_name, - const std::string& key, - const std::string& value); - - AnnotationDescriptor* get_annotation( - const std::string& name) const; - - // Annotations application - RTPS_DllAPI bool annotation_is_optional() const; - - RTPS_DllAPI bool annotation_is_key() const; - - RTPS_DllAPI bool annotation_is_must_understand() const; - - RTPS_DllAPI bool annotation_is_non_serialized() const; - - RTPS_DllAPI bool annotation_is_value() const; - - RTPS_DllAPI bool annotation_is_default_literal() const; - - RTPS_DllAPI bool annotation_is_position() const; - - RTPS_DllAPI bool annotation_is_bit_bound() const; - - // Annotations getters - RTPS_DllAPI bool annotation_get_key() const; - - RTPS_DllAPI std::string annotation_get_value() const; - - RTPS_DllAPI std::string annotation_get_default() const; - - RTPS_DllAPI uint16_t annotation_get_position() const; - - RTPS_DllAPI uint16_t annotation_get_bit_bound() const; - - // Annotations setters - RTPS_DllAPI void annotation_set_optional( - bool optional); - - RTPS_DllAPI void annotation_set_key( - bool key); - - RTPS_DllAPI void annotation_set_must_understand( - bool must_understand); - - RTPS_DllAPI void annotation_set_non_serialized( - bool non_serialized); - - RTPS_DllAPI void annotation_set_value( - const std::string& value); - - RTPS_DllAPI void annotation_set_default( - const std::string& default_value); - - RTPS_DllAPI void annotation_set_default_literal(); - - RTPS_DllAPI void annotation_set_position( - uint16_t position); - - RTPS_DllAPI void annotation_set_bit_bound( - uint16_t bit_bound); -}; - -} // namespace types -} // namespace fastrtps -} // namespace eprosima - -#endif // TYPES_MEMBER_DESCRIPTOR_H diff --git a/include/fastrtps/types/TypeDescriptor.h b/include/fastrtps/types/TypeDescriptor.h deleted file mode 100644 index c6f5654d896..00000000000 --- a/include/fastrtps/types/TypeDescriptor.h +++ /dev/null @@ -1,163 +0,0 @@ -// Copyright 2018 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -#ifndef TYPES_TYPE_DESCRIPTOR_H -#define TYPES_TYPE_DESCRIPTOR_H - -#include -#include -#include - -class MemberDescriptor; -class DynamicType; - -namespace eprosima { -namespace fastrtps { -namespace types { - -class TypeDescriptor -{ -protected: - - TypeKind kind_; // Type Kind. - std::string name_; // Type Name. - DynamicType_ptr base_type_; // SuperType of an structure or base type of an alias type. - DynamicType_ptr discriminator_type_; // Discrimination type for a union. - std::vector bound_; // Length for strings, arrays, sequences, maps and bitmasks. - DynamicType_ptr element_type_; // Value Type for arrays, sequences, maps, bitmasks. - DynamicType_ptr key_element_type_; // Key Type for maps. - std::vector annotation_; // Annotations to apply - - RTPS_DllAPI void clean(); - - static bool is_type_name_consistent( - const std::string& sName); - - friend class DynamicTypeBuilderFactory; - friend class TypeObjectFactory; - friend class DynamicType; - friend class MemberDescriptor; - friend class DynamicDataHelper; - -public: - - RTPS_DllAPI TypeDescriptor(); - - RTPS_DllAPI TypeDescriptor( - const TypeDescriptor* other); - - RTPS_DllAPI TypeDescriptor( - const std::string& name, - TypeKind kind); - - RTPS_DllAPI ~TypeDescriptor(); - - RTPS_DllAPI ReturnCode_t copy_from( - const TypeDescriptor* descriptor); - - RTPS_DllAPI bool equals( - const TypeDescriptor* descriptor) const; - - RTPS_DllAPI bool is_consistent() const; - - RTPS_DllAPI DynamicType_ptr get_base_type() const; - - RTPS_DllAPI uint32_t get_bounds( - uint32_t index = 0) const; - - RTPS_DllAPI uint32_t get_bounds_size() const; - - RTPS_DllAPI DynamicType_ptr get_discriminator_type() const; - - RTPS_DllAPI DynamicType_ptr get_element_type() const; - - RTPS_DllAPI DynamicType_ptr get_key_element_type() const; - - RTPS_DllAPI TypeKind get_kind() const; - - RTPS_DllAPI std::string get_name() const; - - RTPS_DllAPI uint32_t get_total_bounds() const; - - RTPS_DllAPI void set_kind( - TypeKind kind); - - RTPS_DllAPI void set_name( - std::string name); - - RTPS_DllAPI ReturnCode_t apply_annotation( - AnnotationDescriptor& descriptor); - - RTPS_DllAPI ReturnCode_t apply_annotation( - const std::string& annotation_name, - const std::string& key, - const std::string& value); - - RTPS_DllAPI AnnotationDescriptor* get_annotation( - const std::string& name) const; - - // Annotations application - RTPS_DllAPI bool annotation_is_extensibility() const; - - RTPS_DllAPI bool annotation_is_mutable() const; - - RTPS_DllAPI bool annotation_is_final() const; - - RTPS_DllAPI bool annotation_is_appendable() const; - - RTPS_DllAPI bool annotation_is_nested() const; - - RTPS_DllAPI bool annotation_is_bit_bound() const; - - RTPS_DllAPI bool annotation_is_key() const; - - RTPS_DllAPI bool annotation_is_non_serialized() const; - - // Annotation getters - RTPS_DllAPI std::string annotation_get_extensibility() const; - - RTPS_DllAPI bool annotation_get_nested() const; - - RTPS_DllAPI uint16_t annotation_get_bit_bound() const; - - RTPS_DllAPI bool annotation_get_key() const; - - // Annotation setters - RTPS_DllAPI void annotation_set_extensibility( - const std::string& extensibility); - - RTPS_DllAPI void annotation_set_mutable(); - - RTPS_DllAPI void annotation_set_final(); - - RTPS_DllAPI void annotation_set_appendable(); - - RTPS_DllAPI void annotation_set_nested( - bool nested); - - RTPS_DllAPI void annotation_set_bit_bound( - uint16_t bit_bound); - - RTPS_DllAPI void annotation_set_key( - bool key); - - RTPS_DllAPI void annotation_set_non_serialized( - bool non_serialized); -}; - -} // namespace types -} // namespace fastrtps -} // namespace eprosima - -#endif // TYPES_TYPE_DESCRIPTOR_H diff --git a/include/fastrtps/types/TypeIdentifier.h b/include/fastrtps/types/TypeIdentifier.h deleted file mode 100644 index b49cf48d396..00000000000 --- a/include/fastrtps/types/TypeIdentifier.h +++ /dev/null @@ -1,434 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file TypeIdentifier.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool gen. - */ - -#ifndef _TYPEIDENTIFIER_H_ -#define _TYPEIDENTIFIER_H_ - -#include -#include -#include -#include -#include -#include - -namespace eprosima { - -namespace fastcdr { -class Cdr; -} // namespace fastcdr - -namespace fastdds { -namespace dds { -class TypeConsistencyEnforcementQosPolicy; -} // namespace dds -} // namespace fastdds - -namespace fastrtps { -namespace types { - -typedef octet TypeIdentiferKind; -const octet TI_STRING8_SMALL = 0x70; -const octet TI_STRING8_LARGE = 0x71; -const octet TI_STRING16_SMALL = 0x72; -const octet TI_STRING16_LARGE = 0x73; -const octet TI_PLAIN_SEQUENCE_SMALL = 0x80; -const octet TI_PLAIN_SEQUENCE_LARGE = 0x81; -const octet TI_PLAIN_ARRAY_SMALL = 0x90; -const octet TI_PLAIN_ARRAY_LARGE = 0x91; -const octet TI_PLAIN_MAP_SMALL = 0xA0; -const octet TI_PLAIN_MAP_LARGE = 0xA1; -const octet TI_STRONGLY_CONNECTED_COMPONENT = 0xB0; - -// The TypeIdentifier uniquely identifies a type (a set of equivalent -// types according to an equivalence relationship: COMPLETE, MNIMAL). -// -// In some cases (primitive types, strings, plain types) the identifier -// is a explicit description of the type. -// In other cases the Identifier is a Hash of the type description -// -// In the case of primitive types and strings the implied equivalence -// relation is the identity. -// -// For Plain Types and Hash-defined TypeIdentifiers there are three -// possibilities: MINIMAL, COMPLETE, and COMMON: -// - MINIMAL indicates the TypeIdentifier identifies equivalent types -// according to the MINIMAL equivalence relation -// - COMPLETE indicates the TypeIdentifier identifies equivalent types -// according to the COMPLETE equivalence relation -// - COMMON indicates the TypeIdentifier identifies equivalent types -// according to both the MINIMAL and the COMMON equivalence relation. -// This means the TypeIdentifier is the same for both relationships -// -class TypeIdentifier -{ -public: - - /*! - * @brief Default constructor. - */ - RTPS_DllAPI TypeIdentifier(); - - /*! - * @brief Default destructor. - */ - RTPS_DllAPI ~TypeIdentifier(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object TypeIdentifier that will be copied. - */ - RTPS_DllAPI TypeIdentifier( - const TypeIdentifier& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object TypeIdentifier that will be copied. - */ - RTPS_DllAPI TypeIdentifier( - TypeIdentifier&& x); - - /*! - * @brief Copy assignment. - * @param x Reference to the object TypeIdentifier that will be copied. - */ - RTPS_DllAPI TypeIdentifier& operator =( - const TypeIdentifier& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object TypeIdentifier that will be copied. - */ - RTPS_DllAPI TypeIdentifier& operator =( - TypeIdentifier&& x); - - /*! - * @brief This function sets the discriminator value. - * @param __d New value for the discriminator. - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the new value doesn't correspond to the selected union member. - */ - RTPS_DllAPI void _d( - octet __d); - - /*! - * @brief This function returns the value of the discriminator. - * @return Value of the discriminator - */ - RTPS_DllAPI octet _d() const; - - /*! - * @brief This function returns a reference to the discriminator. - * @return Reference to the discriminator. - */ - RTPS_DllAPI octet& _d(); - - /*! - * @brief This function sets a value in member string_sdefn - * @param _string_sdefn New value for member string_sdefn - */ - RTPS_DllAPI void string_sdefn( - StringSTypeDefn _string_sdefn); - - /*! - * @brief This function returns the value of member string_sdefn - * @return Value of member string_sdefn - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI const StringSTypeDefn& string_sdefn() const; - - /*! - * @brief This function returns a reference to member string_sdefn - * @return Reference to member string_sdefn - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI StringSTypeDefn& string_sdefn(); - /*! - * @brief This function sets a value in member string_ldefn - * @param _string_ldefn New value for member string_ldefn - */ - RTPS_DllAPI void string_ldefn( - StringLTypeDefn _string_ldefn); - - /*! - * @brief This function returns the value of member string_ldefn - * @return Value of member string_ldefn - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI const StringLTypeDefn& string_ldefn() const; - - /*! - * @brief This function returns a reference to member string_ldefn - * @return Reference to member string_ldefn - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI StringLTypeDefn& string_ldefn(); - /*! - * @brief This function sets a value in member seq_sdefn - * @param _seq_sdefn New value for member seq_sdefn - */ - RTPS_DllAPI void seq_sdefn( - PlainSequenceSElemDefn _seq_sdefn); - - /*! - * @brief This function returns the value of member seq_sdefn - * @return Value of member seq_sdefn - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI const PlainSequenceSElemDefn& seq_sdefn() const; - - /*! - * @brief This function returns a reference to member seq_sdefn - * @return Reference to member seq_sdefn - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI PlainSequenceSElemDefn& seq_sdefn(); - /*! - * @brief This function sets a value in member seq_ldefn - * @param _seq_ldefn New value for member seq_ldefn - */ - RTPS_DllAPI void seq_ldefn( - PlainSequenceLElemDefn _seq_ldefn); - - /*! - * @brief This function returns the value of member seq_ldefn - * @return Value of member seq_ldefn - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI const PlainSequenceLElemDefn& seq_ldefn() const; - - /*! - * @brief This function returns a reference to member seq_ldefn - * @return Reference to member seq_ldefn - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI PlainSequenceLElemDefn& seq_ldefn(); - /*! - * @brief This function sets a value in member array_sdefn - * @param _array_sdefn New value for member array_sdefn - */ - RTPS_DllAPI void array_sdefn( - PlainArraySElemDefn _array_sdefn); - - /*! - * @brief This function returns the value of member array_sdefn - * @return Value of member array_sdefn - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI const PlainArraySElemDefn& array_sdefn() const; - - /*! - * @brief This function returns a reference to member array_sdefn - * @return Reference to member array_sdefn - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI PlainArraySElemDefn& array_sdefn(); - /*! - * @brief This function sets a value in member array_ldefn - * @param _array_ldefn New value for member array_ldefn - */ - RTPS_DllAPI void array_ldefn( - PlainArrayLElemDefn _array_ldefn); - - /*! - * @brief This function returns the value of member array_ldefn - * @return Value of member array_ldefn - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI const PlainArrayLElemDefn& array_ldefn() const; - - /*! - * @brief This function returns a reference to member array_ldefn - * @return Reference to member array_ldefn - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI PlainArrayLElemDefn& array_ldefn(); - /*! - * @brief This function sets a value in member map_sdefn - * @param _map_sdefn New value for member map_sdefn - */ - RTPS_DllAPI void map_sdefn( - PlainMapSTypeDefn _map_sdefn); - - /*! - * @brief This function returns the value of member map_sdefn - * @return Value of member map_sdefn - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI const PlainMapSTypeDefn& map_sdefn() const; - - /*! - * @brief This function returns a reference to member map_sdefn - * @return Reference to member map_sdefn - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI PlainMapSTypeDefn& map_sdefn(); - /*! - * @brief This function sets a value in member map_ldefn - * @param _map_ldefn New value for member map_ldefn - */ - RTPS_DllAPI void map_ldefn( - PlainMapLTypeDefn _map_ldefn); - - /*! - * @brief This function returns the value of member map_ldefn - * @return Value of member map_ldefn - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI const PlainMapLTypeDefn& map_ldefn() const; - - /*! - * @brief This function returns a reference to member map_ldefn - * @return Reference to member map_ldefn - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI PlainMapLTypeDefn& map_ldefn(); - /*! - * @brief This function sets a value in member sc_component_id - * @param _sc_component_id New value for member sc_component_id - */ - RTPS_DllAPI void sc_component_id( - StronglyConnectedComponentId _sc_component_id); - - /*! - * @brief This function returns the value of member sc_component_id - * @return Value of member sc_component_id - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI StronglyConnectedComponentId sc_component_id() const; - - /*! - * @brief This function returns a reference to member sc_component_id - * @return Reference to member sc_component_id - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI StronglyConnectedComponentId& sc_component_id(); - /*! - * @brief This function sets a value in member equivalence_hash - * @param _equivalence_hash New value for member equivalence_hash - */ - RTPS_DllAPI void equivalence_hash( - EquivalenceHash _equivalence_hash); - - /*! - * @brief This function returns the value of member equivalence_hash - * @return Value of member equivalence_hash - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI const octet* equivalence_hash() const; - - /*! - * @brief This function returns a reference to member equivalence_hash - * @return Reference to member equivalence_hash - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI octet* equivalence_hash(); - /*! - * @brief This function sets a value in member extended_defn - * @param _extended_defn New value for member extended_defn - */ - RTPS_DllAPI void extended_defn( - ExtendedTypeDefn _extended_defn); - - /*! - * @brief This function returns the value of member extended_defn - * @return Value of member extended_defn - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI const ExtendedTypeDefn& extended_defn() const; - - /*! - * @brief This function returns a reference to member extended_defn - * @return Reference to member extended_defn - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI ExtendedTypeDefn& extended_defn(); - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::TypeIdentifier::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const TypeIdentifier& data, - size_t current_alignment = 0); - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::TypeIdentifier::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::TypeIdentifier::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - /** - * Equals - * */ - bool operator ==( - const TypeIdentifier& other) const; - - RTPS_DllAPI bool consistent( - const TypeIdentifier& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - - /** - * @brief equivalence_hash_to_string - * @return string representation of the equivalence hash - */ - RTPS_DllAPI std::string equivalence_hash_to_string() const; - -private: - - octet m__d; - - StringSTypeDefn m_string_sdefn; - StringLTypeDefn m_string_ldefn; - PlainSequenceSElemDefn m_seq_sdefn; - PlainSequenceLElemDefn m_seq_ldefn; - PlainArraySElemDefn m_array_sdefn; - PlainArrayLElemDefn m_array_ldefn; - PlainMapSTypeDefn m_map_sdefn; - PlainMapLTypeDefn m_map_ldefn; - StronglyConnectedComponentId m_sc_component_id; - EquivalenceHash m_equivalence_hash; - ExtendedTypeDefn m_extended_defn; -}; - -typedef std::vector TypeIdentifierSeq; - -} // namespace types -} // namespace fastrtps -} // namespace eprosima - -#endif // _TYPEIDENTIFIER_H_ diff --git a/include/fastrtps/types/TypeIdentifierTypes.h b/include/fastrtps/types/TypeIdentifierTypes.h deleted file mode 100644 index 553c6eab8c8..00000000000 --- a/include/fastrtps/types/TypeIdentifierTypes.h +++ /dev/null @@ -1,1920 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file TypeIdentifierTypes.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool gen. - */ - -#ifndef _TYPEIDENTIFIERTYPES_H_ -#define _TYPEIDENTIFIERTYPES_H_ - -#include -#include -#include -#include - -#include -#include - -namespace eprosima { -namespace fastcdr { -class Cdr; -} // namespace fastcdr -} // namespace eprosima - -namespace eprosima { - -namespace fastdds { -namespace dds { -class TypeConsistencyEnforcementQosPolicy; -} // namespace dds -} // namespace fastdds - -namespace fastrtps { -namespace types { - - -// Forward declaration -class TypeIdentifier; -class StringLTypeDefn; - -/*! - * @brief This class represents the structure StringSTypeDefn defined by the user in the IDL file. - * @ingroup TYPES_MODULE - */ -class StringSTypeDefn final -{ -public: - - /*! - * @brief Default constructor. - */ - RTPS_DllAPI StringSTypeDefn(); - - /*! - * @brief Default destructor. - */ - RTPS_DllAPI ~StringSTypeDefn(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object StringSTypeDefn that will be copied. - */ - RTPS_DllAPI StringSTypeDefn( - const StringSTypeDefn& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object StringSTypeDefn that will be copied. - */ - RTPS_DllAPI StringSTypeDefn( - StringSTypeDefn&& x); - - /*! - * @brief Copy assignment. - * @param x Reference to the object StringSTypeDefn that will be copied. - */ - RTPS_DllAPI StringSTypeDefn& operator =( - const StringSTypeDefn& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object StringSTypeDefn that will be copied. - */ - RTPS_DllAPI StringSTypeDefn& operator =( - StringSTypeDefn&& x); - - /*! - * @brief This function sets a value in member bound - * @param _bound New value for member bound - */ - RTPS_DllAPI inline void bound( - SBound _bound) - { - m_bound = _bound; - } - - /*! - * @brief This function returns the value of member bound - * @return Value of member bound - */ - RTPS_DllAPI inline SBound bound() const - { - return m_bound; - } - - /*! - * @brief This function returns a reference to member bound - * @return Reference to member bound - */ - RTPS_DllAPI inline SBound& bound() - { - return m_bound; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::StringSTypeDefn::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const StringSTypeDefn& data, - size_t current_alignment = 0); - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::StringSTypeDefn::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::StringSTypeDefn::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool consistent( - const StringSTypeDefn& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - - RTPS_DllAPI bool consistent( - const StringLTypeDefn& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - SBound m_bound; -}; -/*! - * @brief This class represents the structure StringLTypeDefn defined by the user in the IDL file. - * @ingroup TYPES_MODULE - */ -class StringLTypeDefn final -{ -public: - - /*! - * @brief Default constructor. - */ - RTPS_DllAPI StringLTypeDefn(); - - /*! - * @brief Default destructor. - */ - RTPS_DllAPI ~StringLTypeDefn(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object StringLTypeDefn that will be copied. - */ - RTPS_DllAPI StringLTypeDefn( - const StringLTypeDefn& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object StringLTypeDefn that will be copied. - */ - RTPS_DllAPI StringLTypeDefn( - StringLTypeDefn&& x); - - /*! - * @brief Copy assignment. - * @param x Reference to the object StringLTypeDefn that will be copied. - */ - RTPS_DllAPI StringLTypeDefn& operator =( - const StringLTypeDefn& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object StringLTypeDefn that will be copied. - */ - RTPS_DllAPI StringLTypeDefn& operator =( - StringLTypeDefn&& x); - - /*! - * @brief This function sets a value in member bound - * @param _bound New value for member bound - */ - RTPS_DllAPI inline void bound( - LBound _bound) - { - m_bound = _bound; - } - - /*! - * @brief This function returns the value of member bound - * @return Value of member bound - */ - RTPS_DllAPI inline LBound bound() const - { - return m_bound; - } - - /*! - * @brief This function returns a reference to member bound - * @return Reference to member bound - */ - RTPS_DllAPI inline LBound& bound() - { - return m_bound; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::StringLTypeDefn::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const StringLTypeDefn& data, - size_t current_alignment = 0); - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::StringLTypeDefn::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::StringLTypeDefn::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool consistent( - const StringLTypeDefn& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - - RTPS_DllAPI bool consistent( - const StringSTypeDefn& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - LBound m_bound; -}; -/*! - * @brief This class represents the structure PlainCollectionHeader defined by the user in the IDL file. - * @ingroup TYPES_MODULE - */ -class PlainCollectionHeader final -{ -public: - - /*! - * @brief Default constructor. - */ - RTPS_DllAPI PlainCollectionHeader(); - - /*! - * @brief Default destructor. - */ - RTPS_DllAPI ~PlainCollectionHeader(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object PlainCollectionHeader that will be copied. - */ - RTPS_DllAPI PlainCollectionHeader( - const PlainCollectionHeader& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object PlainCollectionHeader that will be copied. - */ - RTPS_DllAPI PlainCollectionHeader( - PlainCollectionHeader&& x); - - /*! - * @brief Copy assignment. - * @param x Reference to the object PlainCollectionHeader that will be copied. - */ - RTPS_DllAPI PlainCollectionHeader& operator =( - const PlainCollectionHeader& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object PlainCollectionHeader that will be copied. - */ - RTPS_DllAPI PlainCollectionHeader& operator =( - PlainCollectionHeader&& x); - - /*! - * @brief This function sets a value in member equiv_kind - * @param _equiv_kind New value for member equiv_kind - */ - RTPS_DllAPI inline void equiv_kind( - EquivalenceKind _equiv_kind) - { - m_equiv_kind = _equiv_kind; - } - - /*! - * @brief This function returns the value of member equiv_kind - * @return Value of member equiv_kind - */ - RTPS_DllAPI inline EquivalenceKind equiv_kind() const - { - return m_equiv_kind; - } - - /*! - * @brief This function returns a reference to member equiv_kind - * @return Reference to member equiv_kind - */ - RTPS_DllAPI inline EquivalenceKind& equiv_kind() - { - return m_equiv_kind; - } - - /*! - * @brief This function sets a value in member element_flags - * @param _element_flags New value for member element_flags - */ - RTPS_DllAPI inline void element_flags( - CollectionElementFlag _element_flags) - { - m_element_flags = _element_flags; - } - - /*! - * @brief This function returns the value of member element_flags - * @return Value of member element_flags - */ - RTPS_DllAPI inline CollectionElementFlag element_flags() const - { - return m_element_flags; - } - - /*! - * @brief This function returns a reference to member element_flags - * @return Reference to member element_flags - */ - RTPS_DllAPI inline CollectionElementFlag& element_flags() - { - return m_element_flags; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::PlainCollectionHeader::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const PlainCollectionHeader& data, - size_t current_alignment = 0); - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::PlainCollectionHeader::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::PlainCollectionHeader::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool consistent( - const PlainCollectionHeader& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - EquivalenceKind m_equiv_kind; - CollectionElementFlag m_element_flags; -}; -/*! - * @brief This class represents the structure PlainSequenceSElemDefn defined by the user in the IDL file. - * @ingroup TYPES_MODULE - */ -class PlainSequenceSElemDefn final -{ -public: - - /*! - * @brief Default constructor. - */ - RTPS_DllAPI PlainSequenceSElemDefn(); - - /*! - * @brief Default destructor. - */ - RTPS_DllAPI ~PlainSequenceSElemDefn(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object PlainSequenceSElemDefn that will be copied. - */ - RTPS_DllAPI PlainSequenceSElemDefn( - const PlainSequenceSElemDefn& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object PlainSequenceSElemDefn that will be copied. - */ - RTPS_DllAPI PlainSequenceSElemDefn( - PlainSequenceSElemDefn&& x); - - /*! - * @brief Copy assignment. - * @param x Reference to the object PlainSequenceSElemDefn that will be copied. - */ - RTPS_DllAPI PlainSequenceSElemDefn& operator =( - const PlainSequenceSElemDefn& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object PlainSequenceSElemDefn that will be copied. - */ - RTPS_DllAPI PlainSequenceSElemDefn& operator =( - PlainSequenceSElemDefn&& x); - - /*! - * @brief This function copies the value in member header - * @param _header New value to be copied in member header - */ - RTPS_DllAPI inline void header( - const PlainCollectionHeader& _header) - { - m_header = _header; - } - - /*! - * @brief This function moves the value in member header - * @param _header New value to be moved in member header - */ - RTPS_DllAPI inline void header( - PlainCollectionHeader&& _header) - { - m_header = std::move(_header); - } - - /*! - * @brief This function returns a constant reference to member header - * @return Constant reference to member header - */ - RTPS_DllAPI inline const PlainCollectionHeader& header() const - { - return m_header; - } - - /*! - * @brief This function returns a reference to member header - * @return Reference to member header - */ - RTPS_DllAPI inline PlainCollectionHeader& header() - { - return m_header; - } - - /*! - * @brief This function sets a value in member bound - * @param _bound New value for member bound - */ - RTPS_DllAPI inline void bound( - SBound _bound) - { - m_bound = _bound; - } - - /*! - * @brief This function returns the value of member bound - * @return Value of member bound - */ - RTPS_DllAPI inline SBound bound() const - { - return m_bound; - } - - /*! - * @brief This function returns a reference to member bound - * @return Reference to member bound - */ - RTPS_DllAPI inline SBound& bound() - { - return m_bound; - } - - /*! - * @brief This function sets a value in member element_identifier - * @param _element_identifier New value for member element_identifier - */ - RTPS_DllAPI void element_identifier( - const TypeIdentifier* _element_identifier); - - /*! - * @brief This function returns the value of member element_identifier - * @return Value of member element_identifier - */ - RTPS_DllAPI inline const TypeIdentifier* element_identifier() const - { - return m_element_identifier; - } - - /*! - * @brief This function returns a reference to member element_identifier - * @return Reference to member element_identifier - */ - RTPS_DllAPI inline TypeIdentifier* element_identifier() - { - return m_element_identifier; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::PlainSequenceSElemDefn::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const PlainSequenceSElemDefn& data, - size_t current_alignment = 0); - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::PlainSequenceSElemDefn::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::PlainSequenceSElemDefn::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool consistent( - const PlainSequenceSElemDefn& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - PlainCollectionHeader m_header; - SBound m_bound; - TypeIdentifier* m_element_identifier; -}; -/*! - * @brief This class represents the structure PlainSequenceLElemDefn defined by the user in the IDL file. - * @ingroup TYPES_MODULE - */ -class PlainSequenceLElemDefn final -{ -public: - - /*! - * @brief Default constructor. - */ - RTPS_DllAPI PlainSequenceLElemDefn(); - - /*! - * @brief Default destructor. - */ - RTPS_DllAPI ~PlainSequenceLElemDefn(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object PlainSequenceLElemDefn that will be copied. - */ - RTPS_DllAPI PlainSequenceLElemDefn( - const PlainSequenceLElemDefn& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object PlainSequenceLElemDefn that will be copied. - */ - RTPS_DllAPI PlainSequenceLElemDefn( - PlainSequenceLElemDefn&& x); - - /*! - * @brief Copy assignment. - * @param x Reference to the object PlainSequenceLElemDefn that will be copied. - */ - RTPS_DllAPI PlainSequenceLElemDefn& operator =( - const PlainSequenceLElemDefn& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object PlainSequenceLElemDefn that will be copied. - */ - RTPS_DllAPI PlainSequenceLElemDefn& operator =( - PlainSequenceLElemDefn&& x); - - /*! - * @brief This function copies the value in member header - * @param _header New value to be copied in member header - */ - RTPS_DllAPI inline void header( - const PlainCollectionHeader& _header) - { - m_header = _header; - } - - /*! - * @brief This function moves the value in member header - * @param _header New value to be moved in member header - */ - RTPS_DllAPI inline void header( - PlainCollectionHeader&& _header) - { - m_header = std::move(_header); - } - - /*! - * @brief This function returns a constant reference to member header - * @return Constant reference to member header - */ - RTPS_DllAPI inline const PlainCollectionHeader& header() const - { - return m_header; - } - - /*! - * @brief This function returns a reference to member header - * @return Reference to member header - */ - RTPS_DllAPI inline PlainCollectionHeader& header() - { - return m_header; - } - - /*! - * @brief This function sets a value in member bound - * @param _bound New value for member bound - */ - RTPS_DllAPI inline void bound( - LBound _bound) - { - m_bound = _bound; - } - - /*! - * @brief This function returns the value of member bound - * @return Value of member bound - */ - RTPS_DllAPI inline LBound bound() const - { - return m_bound; - } - - /*! - * @brief This function returns a reference to member bound - * @return Reference to member bound - */ - RTPS_DllAPI inline LBound& bound() - { - return m_bound; - } - - /*! - * @brief This function sets a value in member element_identifier - * @param _element_identifier New value for member element_identifier - */ - RTPS_DllAPI void element_identifier( - const TypeIdentifier* _element_identifier); - - /*! - * @brief This function returns the value of member element_identifier - * @return Value of member element_identifier - */ - RTPS_DllAPI inline const TypeIdentifier* element_identifier() const - { - return m_element_identifier; - } - - /*! - * @brief This function returns a reference to member element_identifier - * @return Reference to member element_identifier - */ - RTPS_DllAPI inline TypeIdentifier* element_identifier() - { - return m_element_identifier; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::PlainSequenceLElemDefn::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const PlainSequenceLElemDefn& data, - size_t current_alignment = 0); - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::PlainSequenceLElemDefn::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::PlainSequenceLElemDefn::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool consistent( - const PlainSequenceLElemDefn& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - PlainCollectionHeader m_header; - LBound m_bound; - TypeIdentifier* m_element_identifier; -}; -/*! - * @brief This class represents the structure PlainArraySElemDefn defined by the user in the IDL file. - * @ingroup TYPES_MODULE - */ -class PlainArraySElemDefn final -{ -public: - - /*! - * @brief Default constructor. - */ - RTPS_DllAPI PlainArraySElemDefn(); - - /*! - * @brief Default destructor. - */ - RTPS_DllAPI ~PlainArraySElemDefn(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object PlainArraySElemDefn that will be copied. - */ - RTPS_DllAPI PlainArraySElemDefn( - const PlainArraySElemDefn& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object PlainArraySElemDefn that will be copied. - */ - RTPS_DllAPI PlainArraySElemDefn( - PlainArraySElemDefn&& x); - - /*! - * @brief Copy assignment. - * @param x Reference to the object PlainArraySElemDefn that will be copied. - */ - RTPS_DllAPI PlainArraySElemDefn& operator =( - const PlainArraySElemDefn& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object PlainArraySElemDefn that will be copied. - */ - RTPS_DllAPI PlainArraySElemDefn& operator =( - PlainArraySElemDefn&& x); - - /*! - * @brief This function copies the value in member header - * @param _header New value to be copied in member header - */ - RTPS_DllAPI inline void header( - const PlainCollectionHeader& _header) - { - m_header = _header; - } - - /*! - * @brief This function moves the value in member header - * @param _header New value to be moved in member header - */ - RTPS_DllAPI inline void header( - PlainCollectionHeader&& _header) - { - m_header = std::move(_header); - } - - /*! - * @brief This function returns a constant reference to member header - * @return Constant reference to member header - */ - RTPS_DllAPI inline const PlainCollectionHeader& header() const - { - return m_header; - } - - /*! - * @brief This function returns a reference to member header - * @return Reference to member header - */ - RTPS_DllAPI inline PlainCollectionHeader& header() - { - return m_header; - } - - /*! - * @brief This function copies the value in member array_bound_seq - * @param _array_bound_seq New value to be copied in member array_bound_seq - */ - RTPS_DllAPI inline void array_bound_seq( - const SBoundSeq& _array_bound_seq) - { - m_array_bound_seq = _array_bound_seq; - } - - /*! - * @brief This function moves the value in member array_bound_seq - * @param _array_bound_seq New value to be moved in member array_bound_seq - */ - RTPS_DllAPI inline void array_bound_seq( - SBoundSeq&& _array_bound_seq) - { - m_array_bound_seq = std::move(_array_bound_seq); - } - - /*! - * @brief This function returns a constant reference to member array_bound_seq - * @return Constant reference to member array_bound_seq - */ - RTPS_DllAPI inline const SBoundSeq& array_bound_seq() const - { - return m_array_bound_seq; - } - - /*! - * @brief This function returns a reference to member array_bound_seq - * @return Reference to member array_bound_seq - */ - RTPS_DllAPI inline SBoundSeq& array_bound_seq() - { - return m_array_bound_seq; - } - - /*! - * @brief This function sets a value in member element_identifier - * @param _element_identifier New value for member element_identifier - */ - RTPS_DllAPI void element_identifier( - const TypeIdentifier* _element_identifier); - - /*! - * @brief This function returns the value of member element_identifier - * @return Value of member element_identifier - */ - RTPS_DllAPI inline const TypeIdentifier* element_identifier() const - { - return m_element_identifier; - } - - /*! - * @brief This function returns a reference to member element_identifier - * @return Reference to member element_identifier - */ - RTPS_DllAPI inline TypeIdentifier* element_identifier() - { - return m_element_identifier; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::PlainArraySElemDefn::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const PlainArraySElemDefn& data, - size_t current_alignment = 0); - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::PlainArraySElemDefn::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::PlainArraySElemDefn::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool consistent( - const PlainArraySElemDefn& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - PlainCollectionHeader m_header; - SBoundSeq m_array_bound_seq; - TypeIdentifier* m_element_identifier; -}; -/*! - * @brief This class represents the structure PlainArrayLElemDefn defined by the user in the IDL file. - * @ingroup TYPES_MODULE - */ -class PlainArrayLElemDefn final -{ -public: - - /*! - * @brief Default constructor. - */ - RTPS_DllAPI PlainArrayLElemDefn(); - - /*! - * @brief Default destructor. - */ - RTPS_DllAPI ~PlainArrayLElemDefn(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object PlainArrayLElemDefn that will be copied. - */ - RTPS_DllAPI PlainArrayLElemDefn( - const PlainArrayLElemDefn& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object PlainArrayLElemDefn that will be copied. - */ - RTPS_DllAPI PlainArrayLElemDefn( - PlainArrayLElemDefn&& x); - - /*! - * @brief Copy assignment. - * @param x Reference to the object PlainArrayLElemDefn that will be copied. - */ - RTPS_DllAPI PlainArrayLElemDefn& operator =( - const PlainArrayLElemDefn& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object PlainArrayLElemDefn that will be copied. - */ - RTPS_DllAPI PlainArrayLElemDefn& operator =( - PlainArrayLElemDefn&& x); - - /*! - * @brief This function copies the value in member header - * @param _header New value to be copied in member header - */ - RTPS_DllAPI inline void header( - const PlainCollectionHeader& _header) - { - m_header = _header; - } - - /*! - * @brief This function moves the value in member header - * @param _header New value to be moved in member header - */ - RTPS_DllAPI inline void header( - PlainCollectionHeader&& _header) - { - m_header = std::move(_header); - } - - /*! - * @brief This function returns a constant reference to member header - * @return Constant reference to member header - */ - RTPS_DllAPI inline const PlainCollectionHeader& header() const - { - return m_header; - } - - /*! - * @brief This function returns a reference to member header - * @return Reference to member header - */ - RTPS_DllAPI inline PlainCollectionHeader& header() - { - return m_header; - } - - /*! - * @brief This function copies the value in member array_bound_seq - * @param _array_bound_seq New value to be copied in member array_bound_seq - */ - RTPS_DllAPI inline void array_bound_seq( - const LBoundSeq& _array_bound_seq) - { - m_array_bound_seq = _array_bound_seq; - } - - /*! - * @brief This function moves the value in member array_bound_seq - * @param _array_bound_seq New value to be moved in member array_bound_seq - */ - RTPS_DllAPI inline void array_bound_seq( - LBoundSeq&& _array_bound_seq) - { - m_array_bound_seq = std::move(_array_bound_seq); - } - - /*! - * @brief This function returns a constant reference to member array_bound_seq - * @return Constant reference to member array_bound_seq - */ - RTPS_DllAPI inline const LBoundSeq& array_bound_seq() const - { - return m_array_bound_seq; - } - - /*! - * @brief This function returns a reference to member array_bound_seq - * @return Reference to member array_bound_seq - */ - RTPS_DllAPI inline LBoundSeq& array_bound_seq() - { - return m_array_bound_seq; - } - - /*! - * @brief This function sets a value in member element_identifier - * @param _element_identifier New value for member element_identifier - */ - RTPS_DllAPI void element_identifier( - const TypeIdentifier* _element_identifier); - - /*! - * @brief This function returns the value of member element_identifier - * @return Value of member element_identifier - */ - RTPS_DllAPI inline const TypeIdentifier* element_identifier() const - { - return m_element_identifier; - } - - /*! - * @brief This function returns a reference to member element_identifier - * @return Reference to member element_identifier - */ - RTPS_DllAPI inline TypeIdentifier* element_identifier() - { - return m_element_identifier; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::PlainArrayLElemDefn::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const PlainArrayLElemDefn& data, - size_t current_alignment = 0); - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::PlainArrayLElemDefn::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::PlainArrayLElemDefn::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool consistent( - const PlainArrayLElemDefn& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - PlainCollectionHeader m_header; - LBoundSeq m_array_bound_seq; - TypeIdentifier* m_element_identifier; -}; -/*! - * @brief This class represents the structure PlainMapSTypeDefn defined by the user in the IDL file. - * @ingroup TYPES_MODULE - */ -class PlainMapSTypeDefn final -{ -public: - - /*! - * @brief Default constructor. - */ - RTPS_DllAPI PlainMapSTypeDefn(); - - /*! - * @brief Default destructor. - */ - RTPS_DllAPI ~PlainMapSTypeDefn(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object PlainMapSTypeDefn that will be copied. - */ - RTPS_DllAPI PlainMapSTypeDefn( - const PlainMapSTypeDefn& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object PlainMapSTypeDefn that will be copied. - */ - RTPS_DllAPI PlainMapSTypeDefn( - PlainMapSTypeDefn&& x); - - /*! - * @brief Copy assignment. - * @param x Reference to the object PlainMapSTypeDefn that will be copied. - */ - RTPS_DllAPI PlainMapSTypeDefn& operator =( - const PlainMapSTypeDefn& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object PlainMapSTypeDefn that will be copied. - */ - RTPS_DllAPI PlainMapSTypeDefn& operator =( - PlainMapSTypeDefn&& x); - - /*! - * @brief This function copies the value in member header - * @param _header New value to be copied in member header - */ - RTPS_DllAPI inline void header( - const PlainCollectionHeader& _header) - { - m_header = _header; - } - - /*! - * @brief This function moves the value in member header - * @param _header New value to be moved in member header - */ - RTPS_DllAPI inline void header( - PlainCollectionHeader&& _header) - { - m_header = std::move(_header); - } - - /*! - * @brief This function returns a constant reference to member header - * @return Constant reference to member header - */ - RTPS_DllAPI inline const PlainCollectionHeader& header() const - { - return m_header; - } - - /*! - * @brief This function returns a reference to member header - * @return Reference to member header - */ - RTPS_DllAPI inline PlainCollectionHeader& header() - { - return m_header; - } - - /*! - * @brief This function sets a value in member bound - * @param _bound New value for member bound - */ - RTPS_DllAPI inline void bound( - SBound _bound) - { - m_bound = _bound; - } - - /*! - * @brief This function returns the value of member bound - * @return Value of member bound - */ - RTPS_DllAPI inline SBound bound() const - { - return m_bound; - } - - /*! - * @brief This function returns a reference to member bound - * @return Reference to member bound - */ - RTPS_DllAPI inline SBound& bound() - { - return m_bound; - } - - /*! - * @brief This function sets a value in member element_identifier - * @param _element_identifier New value for member element_identifier - */ - RTPS_DllAPI void element_identifier( - const TypeIdentifier* _element_identifier); - - /*! - * @brief This function returns the value of member element_identifier - * @return Value of member element_identifier - */ - RTPS_DllAPI inline const TypeIdentifier* element_identifier() const - { - return m_element_identifier; - } - - /*! - * @brief This function returns a reference to member element_identifier - * @return Reference to member element_identifier - */ - RTPS_DllAPI inline TypeIdentifier* element_identifier() - { - return m_element_identifier; - } - - /*! - * @brief This function sets a value in member key_flags - * @param _key_flags New value for member key_flags - */ - RTPS_DllAPI inline void key_flags( - CollectionElementFlag _key_flags) - { - m_key_flags = _key_flags; - } - - /*! - * @brief This function returns the value of member key_flags - * @return Value of member key_flags - */ - RTPS_DllAPI inline CollectionElementFlag key_flags() const - { - return m_key_flags; - } - - /*! - * @brief This function returns a reference to member key_flags - * @return Reference to member key_flags - */ - RTPS_DllAPI inline CollectionElementFlag& key_flags() - { - return m_key_flags; - } - - /*! - * @brief This function sets a value in member key_identifier - * @param _key_identifier New value for member key_identifier - */ - RTPS_DllAPI void key_identifier( - const TypeIdentifier* _key_identifier); - - /*! - * @brief This function returns the value of member key_identifier - * @return Value of member key_identifier - */ - RTPS_DllAPI inline const TypeIdentifier* key_identifier() const - { - return m_key_identifier; - } - - /*! - * @brief This function returns a reference to member key_identifier - * @return Reference to member key_identifier - */ - RTPS_DllAPI inline TypeIdentifier* key_identifier() - { - return m_key_identifier; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::PlainMapSTypeDefn::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const PlainMapSTypeDefn& data, - size_t current_alignment = 0); - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::PlainMapSTypeDefn::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::PlainMapSTypeDefn::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool consistent( - const PlainMapSTypeDefn& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - PlainCollectionHeader m_header; - SBound m_bound; - TypeIdentifier* m_element_identifier; - CollectionElementFlag m_key_flags; - TypeIdentifier* m_key_identifier; -}; -/*! - * @brief This class represents the structure PlainMapLTypeDefn defined by the user in the IDL file. - * @ingroup TYPES_MODULE - */ -class PlainMapLTypeDefn final -{ -public: - - /*! - * @brief Default constructor. - */ - RTPS_DllAPI PlainMapLTypeDefn(); - - /*! - * @brief Default destructor. - */ - RTPS_DllAPI ~PlainMapLTypeDefn(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object PlainMapLTypeDefn that will be copied. - */ - RTPS_DllAPI PlainMapLTypeDefn( - const PlainMapLTypeDefn& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object PlainMapLTypeDefn that will be copied. - */ - RTPS_DllAPI PlainMapLTypeDefn( - PlainMapLTypeDefn&& x); - - /*! - * @brief Copy assignment. - * @param x Reference to the object PlainMapLTypeDefn that will be copied. - */ - RTPS_DllAPI PlainMapLTypeDefn& operator =( - const PlainMapLTypeDefn& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object PlainMapLTypeDefn that will be copied. - */ - RTPS_DllAPI PlainMapLTypeDefn& operator =( - PlainMapLTypeDefn&& x); - - /*! - * @brief This function copies the value in member header - * @param _header New value to be copied in member header - */ - RTPS_DllAPI inline void header( - const PlainCollectionHeader& _header) - { - m_header = _header; - } - - /*! - * @brief This function moves the value in member header - * @param _header New value to be moved in member header - */ - RTPS_DllAPI inline void header( - PlainCollectionHeader&& _header) - { - m_header = std::move(_header); - } - - /*! - * @brief This function returns a constant reference to member header - * @return Constant reference to member header - */ - RTPS_DllAPI inline const PlainCollectionHeader& header() const - { - return m_header; - } - - /*! - * @brief This function returns a reference to member header - * @return Reference to member header - */ - RTPS_DllAPI inline PlainCollectionHeader& header() - { - return m_header; - } - - /*! - * @brief This function sets a value in member bound - * @param _bound New value for member bound - */ - RTPS_DllAPI inline void bound( - LBound _bound) - { - m_bound = _bound; - } - - /*! - * @brief This function returns the value of member bound - * @return Value of member bound - */ - RTPS_DllAPI inline LBound bound() const - { - return m_bound; - } - - /*! - * @brief This function returns a reference to member bound - * @return Reference to member bound - */ - RTPS_DllAPI inline LBound& bound() - { - return m_bound; - } - - /*! - * @brief This function sets a value in member element_identifier - * @param _element_identifier New value for member element_identifier - */ - RTPS_DllAPI void element_identifier( - const TypeIdentifier* _element_identifier); - - /*! - * @brief This function returns the value of member element_identifier - * @return Value of member element_identifier - */ - RTPS_DllAPI inline const TypeIdentifier* element_identifier() const - { - return m_element_identifier; - } - - /*! - * @brief This function returns a reference to member element_identifier - * @return Reference to member element_identifier - */ - RTPS_DllAPI inline TypeIdentifier* element_identifier() - { - return m_element_identifier; - } - - /*! - * @brief This function sets a value in member key_flags - * @param _key_flags New value for member key_flags - */ - RTPS_DllAPI inline void key_flags( - CollectionElementFlag _key_flags) - { - m_key_flags = _key_flags; - } - - /*! - * @brief This function returns the value of member key_flags - * @return Value of member key_flags - */ - RTPS_DllAPI inline CollectionElementFlag key_flags() const - { - return m_key_flags; - } - - /*! - * @brief This function returns a reference to member key_flags - * @return Reference to member key_flags - */ - RTPS_DllAPI inline CollectionElementFlag& key_flags() - { - return m_key_flags; - } - - /*! - * @brief This function sets a value in member key_identifier - * @param _key_identifier New value for member key_identifier - */ - RTPS_DllAPI void key_identifier( - const TypeIdentifier* _key_identifier); - - /*! - * @brief This function returns the value of member key_identifier - * @return Value of member key_identifier - */ - RTPS_DllAPI inline const TypeIdentifier* key_identifier() const - { - return m_key_identifier; - } - - /*! - * @brief This function returns a reference to member key_identifier - * @return Reference to member key_identifier - */ - RTPS_DllAPI inline TypeIdentifier* key_identifier() - { - return m_key_identifier; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::PlainMapLTypeDefn::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const PlainMapLTypeDefn& data, - size_t current_alignment = 0); - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::PlainMapLTypeDefn::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::PlainMapLTypeDefn::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool consistent( - const PlainMapLTypeDefn& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - PlainCollectionHeader m_header; - LBound m_bound; - TypeIdentifier* m_element_identifier; - CollectionElementFlag m_key_flags; - TypeIdentifier* m_key_identifier; -}; -/*! - * @brief This class represents the structure StronglyConnectedComponentId defined by the user in the IDL file. - * @ingroup TYPES_MODULE - */ -class StronglyConnectedComponentId final -{ -public: - - /*! - * @brief Default constructor. - */ - RTPS_DllAPI StronglyConnectedComponentId(); - - /*! - * @brief Default destructor. - */ - RTPS_DllAPI ~StronglyConnectedComponentId(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object StronglyConnectedComponentId that will be copied. - */ - RTPS_DllAPI StronglyConnectedComponentId( - const StronglyConnectedComponentId& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object StronglyConnectedComponentId that will be copied. - */ - RTPS_DllAPI StronglyConnectedComponentId( - StronglyConnectedComponentId&& x); - - /*! - * @brief Copy assignment. - * @param x Reference to the object StronglyConnectedComponentId that will be copied. - */ - RTPS_DllAPI StronglyConnectedComponentId& operator =( - const StronglyConnectedComponentId& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object StronglyConnectedComponentId that will be copied. - */ - RTPS_DllAPI StronglyConnectedComponentId& operator =( - StronglyConnectedComponentId&& x); - - /*! - * @brief This function copies the value in member sc_component_id - * @param _sc_component_id New value to be copied in member sc_component_id - */ - RTPS_DllAPI inline void sc_component_id( - const TypeObjectHashId& _sc_component_id) - { - m_sc_component_id = _sc_component_id; - } - - /*! - * @brief This function moves the value in member sc_component_id - * @param _sc_component_id New value to be moved in member sc_component_id - */ - RTPS_DllAPI inline void sc_component_id( - TypeObjectHashId&& _sc_component_id) - { - m_sc_component_id = std::move(_sc_component_id); - } - - /*! - * @brief This function returns a constant reference to member sc_component_id - * @return Constant reference to member sc_component_id - */ - RTPS_DllAPI inline const TypeObjectHashId& sc_component_id() const - { - return m_sc_component_id; - } - - /*! - * @brief This function returns a reference to member sc_component_id - * @return Reference to member sc_component_id - */ - RTPS_DllAPI inline TypeObjectHashId& sc_component_id() - { - return m_sc_component_id; - } - - /*! - * @brief This function sets a value in member scc_length - * @param _scc_length New value for member scc_length - */ - RTPS_DllAPI inline void scc_length( - int32_t _scc_length) - { - m_scc_length = _scc_length; - } - - /*! - * @brief This function returns the value of member scc_length - * @return Value of member scc_length - */ - RTPS_DllAPI inline int32_t scc_length() const - { - return m_scc_length; - } - - /*! - * @brief This function returns a reference to member scc_length - * @return Reference to member scc_length - */ - RTPS_DllAPI inline int32_t& scc_length() - { - return m_scc_length; - } - - /*! - * @brief This function sets a value in member scc_index - * @param _scc_index New value for member scc_index - */ - RTPS_DllAPI inline void scc_index( - int32_t _scc_index) - { - m_scc_index = _scc_index; - } - - /*! - * @brief This function returns the value of member scc_index - * @return Value of member scc_index - */ - RTPS_DllAPI inline int32_t scc_index() const - { - return m_scc_index; - } - - /*! - * @brief This function returns a reference to member scc_index - * @return Reference to member scc_index - */ - RTPS_DllAPI inline int32_t& scc_index() - { - return m_scc_index; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::StronglyConnectedComponentId::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const StronglyConnectedComponentId& data, - size_t current_alignment = 0); - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::StronglyConnectedComponentId::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::StronglyConnectedComponentId::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool consistent( - const StronglyConnectedComponentId& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - TypeObjectHashId m_sc_component_id; - int32_t m_scc_length; - int32_t m_scc_index; -}; -/*! - * @brief This class represents the structure ExtendedTypeDefn defined by the user in the IDL file. - * @ingroup TYPES_MODULE - */ -class ExtendedTypeDefn final -{ -public: - - /*! - * @brief Default constructor. - */ - RTPS_DllAPI ExtendedTypeDefn(); - - /*! - * @brief Default destructor. - */ - RTPS_DllAPI virtual ~ExtendedTypeDefn(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object ExtendedTypeDefn that will be copied. - */ - RTPS_DllAPI ExtendedTypeDefn( - const ExtendedTypeDefn& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object ExtendedTypeDefn that will be copied. - */ - RTPS_DllAPI ExtendedTypeDefn( - ExtendedTypeDefn&& x); - - /*! - * @brief Copy assignment. - * @param x Reference to the object ExtendedTypeDefn that will be copied. - */ - RTPS_DllAPI virtual ExtendedTypeDefn& operator =( - const ExtendedTypeDefn& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object ExtendedTypeDefn that will be copied. - */ - RTPS_DllAPI virtual ExtendedTypeDefn& operator =( - ExtendedTypeDefn&& x); - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::ExtendedTypeDefn::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const ExtendedTypeDefn& data, - size_t current_alignment = 0); - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::ExtendedTypeDefn::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI virtual void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::ExtendedTypeDefn::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI virtual void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool consistent( - const ExtendedTypeDefn& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - - -}; - -} // namespace types -} // namespace fastrtps -} // namespace eprosima - -#endif // _TYPEIDENTIFIERTYPES_H_ diff --git a/include/fastrtps/types/TypeNamesGenerator.h b/include/fastrtps/types/TypeNamesGenerator.h deleted file mode 100644 index eeb3d195da9..00000000000 --- a/include/fastrtps/types/TypeNamesGenerator.h +++ /dev/null @@ -1,50 +0,0 @@ -#ifndef _TYPE_NAMES_GENERATOR_ -#define _TYPE_NAMES_GENERATOR_ - -#include - -#include -#include -#include - -namespace eprosima { -namespace fastrtps { -namespace types { - -class TypeNamesGenerator -{ -public: - - RTPS_DllAPI static std::string get_string_type_name( - uint32_t bound, - bool wide, - bool generate_identifier = true); - - RTPS_DllAPI static std::string get_sequence_type_name( - const std::string& type_name, - uint32_t bound, - bool generate_identifier = true); - - RTPS_DllAPI static std::string get_array_type_name( - const std::string& type_name, - const std::vector& bound, - bool generate_identifier = true); - - RTPS_DllAPI static std::string get_array_type_name( - const std::string& type_name, - const std::vector& bound, - uint32_t& ret_size, - bool generate_identifier = true); - - RTPS_DllAPI static std::string get_map_type_name( - const std::string& key_type_name, - const std::string& value_type_name, - uint32_t bound, - bool generate_identifier = true); -}; - -} // namespace types -} // namespace fastrtps -} // namespace eprosima - -#endif //_TYPE_NAMES_GENERATOR_ diff --git a/include/fastrtps/types/TypeObject.h b/include/fastrtps/types/TypeObject.h deleted file mode 100644 index a755ddac2dd..00000000000 --- a/include/fastrtps/types/TypeObject.h +++ /dev/null @@ -1,8075 +0,0 @@ -// Copyright 2018 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -#ifndef TYPES_TYPE_OBJECT_H -#define TYPES_TYPE_OBJECT_H - -#include -#include - -#include -#include -#include -#include - -namespace eprosima { -namespace fastcdr { -class Cdr; -} // namespace fastcdr -} // namespace eprosima - -// The types in this file shall be serialized with XCDR encoding version 2 -namespace eprosima { -namespace fastrtps { - -namespace types { - -/*struct CommonStructMember final { - MemberId member_id; - StructMemberFlag member_flags; - TypeIdentifier member_type_id; - };*/ -class CommonStructMember -{ -public: - - RTPS_DllAPI CommonStructMember(); - RTPS_DllAPI ~CommonStructMember(); - RTPS_DllAPI CommonStructMember( - const CommonStructMember& x); - RTPS_DllAPI CommonStructMember( - CommonStructMember&& x); - RTPS_DllAPI CommonStructMember& operator =( - const CommonStructMember& x); - RTPS_DllAPI CommonStructMember& operator =( - CommonStructMember&& x); - - RTPS_DllAPI inline void member_id( - const MemberId& _member_id) - { - m_member_id = _member_id; - } - - RTPS_DllAPI inline void member_id( - MemberId&& _member_id) - { - m_member_id = std::move(_member_id); - } - - RTPS_DllAPI inline const MemberId& member_id() const - { - return m_member_id; - } - - RTPS_DllAPI inline MemberId& member_id() - { - return m_member_id; - } - - RTPS_DllAPI inline void member_flags( - const StructMemberFlag& _member_flags) - { - m_member_flags = _member_flags; - } - - RTPS_DllAPI inline void member_flags( - StructMemberFlag&& _member_flags) - { - m_member_flags = std::move(_member_flags); - } - - RTPS_DllAPI inline const StructMemberFlag& member_flags() const - { - return m_member_flags; - } - - RTPS_DllAPI inline StructMemberFlag& member_flags() - { - return m_member_flags; - } - - RTPS_DllAPI inline void member_type_id( - const TypeIdentifier& _member_type_id) - { - m_member_type_id = _member_type_id; - } - - RTPS_DllAPI inline void member_type_id( - TypeIdentifier&& _member_type_id) - { - m_member_type_id = std::move(_member_type_id); - } - - RTPS_DllAPI inline const TypeIdentifier& member_type_id() const - { - return m_member_type_id; - } - - RTPS_DllAPI inline TypeIdentifier& member_type_id() - { - return m_member_type_id; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CommonStructMember::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const CommonStructMember& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CommonStructMember::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CommonStructMember::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const CommonStructMember& other) const; - - RTPS_DllAPI bool consistent( - const CommonStructMember& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - MemberId m_member_id; - StructMemberFlag m_member_flags; - TypeIdentifier m_member_type_id; -}; - -// COMPLETE Details for a member of an aggregate type -/*struct CompleteMemberDetail final{ - MemberName name; - AppliedBuiltinMemberAnnotations ann_builtin; // Optional - AppliedAnnotationSeq ann_custom; // Optional - };*/ -class CompleteMemberDetail -{ -public: - - RTPS_DllAPI CompleteMemberDetail(); - RTPS_DllAPI ~CompleteMemberDetail(); - RTPS_DllAPI CompleteMemberDetail( - const CompleteMemberDetail& x); - RTPS_DllAPI CompleteMemberDetail( - CompleteMemberDetail&& x); - RTPS_DllAPI CompleteMemberDetail& operator =( - const CompleteMemberDetail& x); - RTPS_DllAPI CompleteMemberDetail& operator =( - CompleteMemberDetail&& x); - - RTPS_DllAPI inline void name( - const MemberName& _name) - { - m_name = _name; - } - - RTPS_DllAPI inline void name( - MemberName&& _name) - { - m_name = std::move(_name); - } - - RTPS_DllAPI inline const MemberName& name() const - { - return m_name; - } - - RTPS_DllAPI inline MemberName& name() - { - return m_name; - } - - RTPS_DllAPI inline void ann_builtin( - const AppliedBuiltinMemberAnnotations& _ann_builtin) - { - m_ann_builtin = _ann_builtin; - } - - RTPS_DllAPI inline void ann_builtin( - AppliedBuiltinMemberAnnotations&& _ann_builtin) - { - m_ann_builtin = std::move(_ann_builtin); - } - - RTPS_DllAPI inline const AppliedBuiltinMemberAnnotations& ann_builtin() const - { - return m_ann_builtin; - } - - RTPS_DllAPI inline AppliedBuiltinMemberAnnotations& ann_builtin() - { - return m_ann_builtin; - } - - RTPS_DllAPI inline void ann_custom( - const AppliedAnnotationSeq& _ann_custom) - { - m_ann_custom = _ann_custom; - } - - RTPS_DllAPI inline void ann_custom( - AppliedAnnotationSeq&& _ann_custom) - { - m_ann_custom = std::move(_ann_custom); - } - - RTPS_DllAPI inline const AppliedAnnotationSeq& ann_custom() const - { - return m_ann_custom; - } - - RTPS_DllAPI inline AppliedAnnotationSeq& ann_custom() - { - return m_ann_custom; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteMemberDetail::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const CompleteMemberDetail& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteMemberDetail::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteMemberDetail::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const CompleteMemberDetail& other) const; - - RTPS_DllAPI bool consistent( - const CompleteMemberDetail& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - MemberName m_name; - AppliedBuiltinMemberAnnotations m_ann_builtin; - AppliedAnnotationSeq m_ann_custom; -}; - -// MINIMAL Details for a member of an aggregate type -/*struct MinimalMemberDetail final{ - NameHash name_hash; - };*/ - -class MinimalMemberDetail final -{ -public: - - RTPS_DllAPI MinimalMemberDetail(); - RTPS_DllAPI ~MinimalMemberDetail(); - RTPS_DllAPI MinimalMemberDetail( - const MinimalMemberDetail& x); - RTPS_DllAPI MinimalMemberDetail( - MinimalMemberDetail&& x); - RTPS_DllAPI MinimalMemberDetail& operator =( - const MinimalMemberDetail& x); - RTPS_DllAPI MinimalMemberDetail& operator =( - MinimalMemberDetail&& x); - - RTPS_DllAPI inline void name_hash( - const NameHash& _name_hash) - { - m_name_hash = _name_hash; - } - - RTPS_DllAPI inline void name_hash( - NameHash&& _name_hash) - { - m_name_hash = std::move(_name_hash); - } - - RTPS_DllAPI inline const NameHash& name_hash() const - { - return m_name_hash; - } - - RTPS_DllAPI inline NameHash& name_hash() - { - return m_name_hash; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalMemberDetail::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const MinimalMemberDetail& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalMemberDetail::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalMemberDetail::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const MinimalMemberDetail& other) const; - - RTPS_DllAPI bool consistent( - const MinimalMemberDetail& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - NameHash m_name_hash; -}; - -// Member of an aggregate type -/*struct CompleteStructMember { - CommonStructMember common; - CompleteMemberDetail detail; - };*/ -class CompleteStructMember -{ -public: - - RTPS_DllAPI CompleteStructMember(); - RTPS_DllAPI ~CompleteStructMember(); - RTPS_DllAPI CompleteStructMember( - const CompleteStructMember& x); - RTPS_DllAPI CompleteStructMember( - CompleteStructMember&& x); - RTPS_DllAPI CompleteStructMember& operator =( - const CompleteStructMember& x); - RTPS_DllAPI CompleteStructMember& operator =( - CompleteStructMember&& x); - - RTPS_DllAPI inline void common( - const CommonStructMember& _common) - { - m_common = _common; - } - - RTPS_DllAPI inline void common( - CommonStructMember&& _common) - { - m_common = std::move(_common); - } - - RTPS_DllAPI inline const CommonStructMember& common() const - { - return m_common; - } - - RTPS_DllAPI inline CommonStructMember& common() - { - return m_common; - } - - RTPS_DllAPI inline void detail( - const CompleteMemberDetail& _detail) - { - m_detail = _detail; - } - - RTPS_DllAPI inline void detail( - CompleteMemberDetail&& _detail) - { - m_detail = std::move(_detail); - } - - RTPS_DllAPI inline const CompleteMemberDetail& detail() const - { - return m_detail; - } - - RTPS_DllAPI inline CompleteMemberDetail& detail() - { - return m_detail; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteStructMember::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const CompleteStructMember& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteStructMember::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteStructMember::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const CompleteStructMember& other) const; - - RTPS_DllAPI bool consistent( - const CompleteStructMember& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - CommonStructMember m_common; - CompleteMemberDetail m_detail; -}; - -// Ordered by the member_index -typedef std::vector CompleteStructMemberSeq; - -// Member of an aggregate type -/*struct MinimalStructMember { - CommonStructMember common; - MinimalMemberDetail detail; - };*/ -class MinimalStructMember -{ -public: - - RTPS_DllAPI MinimalStructMember(); - RTPS_DllAPI ~MinimalStructMember(); - RTPS_DllAPI MinimalStructMember( - const MinimalStructMember& x); - RTPS_DllAPI MinimalStructMember( - MinimalStructMember&& x); - RTPS_DllAPI MinimalStructMember& operator =( - const MinimalStructMember& x); - RTPS_DllAPI MinimalStructMember& operator =( - MinimalStructMember&& x); - - RTPS_DllAPI inline void common( - const CommonStructMember& _common) - { - m_common = _common; - } - - RTPS_DllAPI inline void common( - CommonStructMember&& _common) - { - m_common = std::move(_common); - } - - RTPS_DllAPI inline const CommonStructMember& common() const - { - return m_common; - } - - RTPS_DllAPI inline CommonStructMember& common() - { - return m_common; - } - - RTPS_DllAPI inline void detail( - const MinimalMemberDetail& _detail) - { - m_detail = _detail; - } - - RTPS_DllAPI inline void detail( - MinimalMemberDetail&& _detail) - { - m_detail = std::move(_detail); - } - - RTPS_DllAPI inline const MinimalMemberDetail& detail() const - { - return m_detail; - } - - RTPS_DllAPI inline MinimalMemberDetail& detail() - { - return m_detail; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalStructMember::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const MinimalStructMember& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalStructMember::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalStructMember::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const MinimalStructMember& other) const; - - RTPS_DllAPI bool consistent( - const MinimalStructMember& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - CommonStructMember m_common; - MinimalMemberDetail m_detail; -}; - -// Ordered by common.member_id -typedef std::vector MinimalStructMemberSeq; - -/*struct AppliedBuiltinTypeAnnotations { - AppliedVerbatimAnnotation verbatim; // verbatim(...) // optional - };*/ -class AppliedBuiltinTypeAnnotations -{ -public: - - RTPS_DllAPI AppliedBuiltinTypeAnnotations(); - RTPS_DllAPI ~AppliedBuiltinTypeAnnotations(); - RTPS_DllAPI AppliedBuiltinTypeAnnotations( - const AppliedBuiltinTypeAnnotations& x); - RTPS_DllAPI AppliedBuiltinTypeAnnotations( - AppliedBuiltinTypeAnnotations&& x); - RTPS_DllAPI AppliedBuiltinTypeAnnotations& operator =( - const AppliedBuiltinTypeAnnotations& x); - RTPS_DllAPI AppliedBuiltinTypeAnnotations& operator =( - AppliedBuiltinTypeAnnotations&& x); - - RTPS_DllAPI inline void verbatim( - const AppliedVerbatimAnnotation& _verbatim) - { - m_verbatim = _verbatim; - } - - RTPS_DllAPI inline void verbatim( - AppliedVerbatimAnnotation&& _verbatim) - { - m_verbatim = std::move(_verbatim); - } - - RTPS_DllAPI inline const AppliedVerbatimAnnotation& verbatim() const - { - return m_verbatim; - } - - RTPS_DllAPI inline AppliedVerbatimAnnotation& verbatim() - { - return m_verbatim; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::AppliedBuiltinTypeAnnotations::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const AppliedBuiltinTypeAnnotations& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::AppliedBuiltinTypeAnnotations::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::AppliedBuiltinTypeAnnotations::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const AppliedBuiltinTypeAnnotations& other) const; - - RTPS_DllAPI bool consistent( - const AppliedBuiltinTypeAnnotations& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - AppliedVerbatimAnnotation m_verbatim; -}; - -/*struct MinimalTypeDetail final{ - // Empty. Available for future extension - };*/ -class MinimalTypeDetail -{ -public: - - RTPS_DllAPI MinimalTypeDetail(); - RTPS_DllAPI ~MinimalTypeDetail(); - RTPS_DllAPI MinimalTypeDetail( - const MinimalTypeDetail& x); - RTPS_DllAPI MinimalTypeDetail( - MinimalTypeDetail&& x); - RTPS_DllAPI MinimalTypeDetail& operator =( - const MinimalTypeDetail& x); - RTPS_DllAPI MinimalTypeDetail& operator =( - MinimalTypeDetail&& x); - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalTypeDetail::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const MinimalTypeDetail& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalTypeDetail::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalTypeDetail::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const MinimalTypeDetail&) const - { - return true; - } - - RTPS_DllAPI bool consistent( - const MinimalTypeDetail& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - -}; - -/*struct CompleteTypeDetail final{ - AppliedBuiltinTypeAnnotations ann_builtin; // optional - AppliedAnnotationSeq ann_custom; // optional - QualifiedTypeName type_name; - };*/ -class CompleteTypeDetail -{ -public: - - RTPS_DllAPI CompleteTypeDetail(); - RTPS_DllAPI ~CompleteTypeDetail(); - RTPS_DllAPI CompleteTypeDetail( - const CompleteTypeDetail& x); - RTPS_DllAPI CompleteTypeDetail( - CompleteTypeDetail&& x); - RTPS_DllAPI CompleteTypeDetail& operator =( - const CompleteTypeDetail& x); - RTPS_DllAPI CompleteTypeDetail& operator =( - CompleteTypeDetail&& x); - - RTPS_DllAPI inline void ann_builtin( - const AppliedBuiltinTypeAnnotations& _ann_builtin) - { - m_ann_builtin = _ann_builtin; - } - - RTPS_DllAPI inline void ann_builtin( - AppliedBuiltinTypeAnnotations&& _ann_builtin) - { - m_ann_builtin = std::move(_ann_builtin); - } - - RTPS_DllAPI inline const AppliedBuiltinTypeAnnotations& ann_builtin() const - { - return m_ann_builtin; - } - - RTPS_DllAPI inline AppliedBuiltinTypeAnnotations& ann_builtin() - { - return m_ann_builtin; - } - - RTPS_DllAPI inline void ann_custom( - const AppliedAnnotationSeq& _ann_custom) - { - m_ann_custom = _ann_custom; - } - - RTPS_DllAPI inline void ann_custom( - AppliedAnnotationSeq&& _ann_custom) - { - m_ann_custom = std::move(_ann_custom); - } - - RTPS_DllAPI inline const AppliedAnnotationSeq& ann_custom() const - { - return m_ann_custom; - } - - RTPS_DllAPI inline AppliedAnnotationSeq& ann_custom() - { - return m_ann_custom; - } - - RTPS_DllAPI inline void type_name( - const QualifiedTypeName& _type_name) - { - m_type_name = _type_name; - } - - RTPS_DllAPI inline void type_name( - QualifiedTypeName&& _type_name) - { - m_type_name = std::move(_type_name); - } - - RTPS_DllAPI inline const QualifiedTypeName& type_name() const - { - return m_type_name; - } - - RTPS_DllAPI inline QualifiedTypeName& type_name() - { - return m_type_name; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteTypeDetail::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const CompleteTypeDetail& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteTypeDetail::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteTypeDetail::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const CompleteTypeDetail& other) const; - - RTPS_DllAPI bool consistent( - const CompleteTypeDetail& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - AppliedBuiltinTypeAnnotations m_ann_builtin; - AppliedAnnotationSeq m_ann_custom; - QualifiedTypeName m_type_name; -}; -/*struct CompleteStructHeader { - TypeIdentifier base_type; - CompleteTypeDetail detail; - };*/ -class CompleteStructHeader -{ -public: - - RTPS_DllAPI CompleteStructHeader(); - RTPS_DllAPI ~CompleteStructHeader(); - RTPS_DllAPI CompleteStructHeader( - const CompleteStructHeader& x); - RTPS_DllAPI CompleteStructHeader( - CompleteStructHeader&& x); - RTPS_DllAPI CompleteStructHeader& operator =( - const CompleteStructHeader& x); - RTPS_DllAPI CompleteStructHeader& operator =( - CompleteStructHeader&& x); - - RTPS_DllAPI inline void base_type( - const TypeIdentifier& _base_type) - { - m_base_type = _base_type; - } - - RTPS_DllAPI inline void base_type( - TypeIdentifier&& _base_type) - { - m_base_type = std::move(_base_type); - } - - RTPS_DllAPI inline const TypeIdentifier& base_type() const - { - return m_base_type; - } - - RTPS_DllAPI inline TypeIdentifier& base_type() - { - return m_base_type; - } - - RTPS_DllAPI inline void detail( - const CompleteTypeDetail& _detail) - { - m_detail = _detail; - } - - RTPS_DllAPI inline void detail( - CompleteTypeDetail&& _detail) - { - m_detail = std::move(_detail); - } - - RTPS_DllAPI inline const CompleteTypeDetail& detail() const - { - return m_detail; - } - - RTPS_DllAPI inline CompleteTypeDetail& detail() - { - return m_detail; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteStructHeader::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const CompleteStructHeader& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteStructHeader::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteStructHeader::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const CompleteStructHeader& other) const; - - RTPS_DllAPI bool consistent( - const CompleteStructHeader& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - TypeIdentifier m_base_type; - CompleteTypeDetail m_detail; -}; -/*struct MinimalStructHeader { - TypeIdentifier base_type; - MinimalTypeDetail detail; - };*/ -class MinimalStructHeader -{ -public: - - RTPS_DllAPI MinimalStructHeader(); - RTPS_DllAPI ~MinimalStructHeader(); - RTPS_DllAPI MinimalStructHeader( - const MinimalStructHeader& x); - RTPS_DllAPI MinimalStructHeader( - MinimalStructHeader&& x); - RTPS_DllAPI MinimalStructHeader& operator =( - const MinimalStructHeader& x); - RTPS_DllAPI MinimalStructHeader& operator =( - MinimalStructHeader&& x); - - RTPS_DllAPI inline void base_type( - const TypeIdentifier& _base_type) - { - m_base_type = _base_type; - } - - RTPS_DllAPI inline void base_type( - TypeIdentifier&& _base_type) - { - m_base_type = std::move(_base_type); - } - - RTPS_DllAPI inline const TypeIdentifier& base_type() const - { - return m_base_type; - } - - RTPS_DllAPI inline TypeIdentifier& base_type() - { - return m_base_type; - } - - RTPS_DllAPI inline void detail( - const MinimalTypeDetail& _detail) - { - m_detail = _detail; - } - - RTPS_DllAPI inline void detail( - MinimalTypeDetail&& _detail) - { - m_detail = std::move(_detail); - } - - RTPS_DllAPI inline const MinimalTypeDetail& detail() const - { - return m_detail; - } - - RTPS_DllAPI inline MinimalTypeDetail& detail() - { - return m_detail; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalStructHeader::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const MinimalStructHeader& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalStructHeader::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalStructHeader::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const MinimalStructHeader& other) const; - - RTPS_DllAPI bool consistent( - const MinimalStructHeader& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - TypeIdentifier m_base_type; - MinimalTypeDetail m_detail; -}; - -/*struct CompleteStructType final{ - StructTypeFlag struct_flags; - CompleteStructHeader header; - CompleteStructMemberSeq member_seq; - };*/ -class CompleteStructType -{ -public: - - RTPS_DllAPI CompleteStructType(); - RTPS_DllAPI ~CompleteStructType(); - RTPS_DllAPI CompleteStructType( - const CompleteStructType& x); - RTPS_DllAPI CompleteStructType( - CompleteStructType&& x); - RTPS_DllAPI CompleteStructType& operator =( - const CompleteStructType& x); - RTPS_DllAPI CompleteStructType& operator =( - CompleteStructType&& x); - - RTPS_DllAPI inline void struct_flags( - const StructTypeFlag& _struct_flags) - { - m_struct_flags = _struct_flags; - } - - RTPS_DllAPI inline void struct_flags( - StructTypeFlag&& _struct_flags) - { - m_struct_flags = std::move(_struct_flags); - } - - RTPS_DllAPI inline const StructTypeFlag& struct_flags() const - { - return m_struct_flags; - } - - RTPS_DllAPI inline StructTypeFlag& struct_flags() - { - return m_struct_flags; - } - - RTPS_DllAPI inline void header( - const CompleteStructHeader& _header) - { - m_header = _header; - } - - RTPS_DllAPI inline void header( - CompleteStructHeader&& _header) - { - m_header = std::move(_header); - } - - RTPS_DllAPI inline const CompleteStructHeader& header() const - { - return m_header; - } - - RTPS_DllAPI inline CompleteStructHeader& header() - { - return m_header; - } - - RTPS_DllAPI inline void member_seq( - const CompleteStructMemberSeq& _member_seq) - { - m_member_seq = _member_seq; - } - - RTPS_DllAPI inline void member_seq( - CompleteStructMemberSeq&& _member_seq) - { - m_member_seq = std::move(_member_seq); - } - - RTPS_DllAPI inline const CompleteStructMemberSeq& member_seq() const - { - return m_member_seq; - } - - RTPS_DllAPI inline CompleteStructMemberSeq& member_seq() - { - return m_member_seq; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteStructType::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const CompleteStructType& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteStructType::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteStructType::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const CompleteStructType& other) const; - - RTPS_DllAPI bool consistent( - const CompleteStructType& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - StructTypeFlag m_struct_flags; - CompleteStructHeader m_header; - CompleteStructMemberSeq m_member_seq; -}; - -/*struct MinimalStructType final{ - StructTypeFlag struct_flags; - MinimalStructHeader header; - MinimalStructMemberSeq member_seq; - };*/ -class MinimalStructType -{ -public: - - RTPS_DllAPI MinimalStructType(); - RTPS_DllAPI ~MinimalStructType(); - RTPS_DllAPI MinimalStructType( - const MinimalStructType& x); - RTPS_DllAPI MinimalStructType( - MinimalStructType&& x); - RTPS_DllAPI MinimalStructType& operator =( - const MinimalStructType& x); - RTPS_DllAPI MinimalStructType& operator =( - MinimalStructType&& x); - - RTPS_DllAPI inline void struct_flags( - const StructTypeFlag& _struct_flags) - { - m_struct_flags = _struct_flags; - } - - RTPS_DllAPI inline void struct_flags( - StructTypeFlag&& _struct_flags) - { - m_struct_flags = std::move(_struct_flags); - } - - RTPS_DllAPI inline const StructTypeFlag& struct_flags() const - { - return m_struct_flags; - } - - RTPS_DllAPI inline StructTypeFlag& struct_flags() - { - return m_struct_flags; - } - - RTPS_DllAPI inline void header( - const MinimalStructHeader& _header) - { - m_header = _header; - } - - RTPS_DllAPI inline void header( - MinimalStructHeader&& _header) - { - m_header = std::move(_header); - } - - RTPS_DllAPI inline const MinimalStructHeader& header() const - { - return m_header; - } - - RTPS_DllAPI inline MinimalStructHeader& header() - { - return m_header; - } - - RTPS_DllAPI inline void member_seq( - const MinimalStructMemberSeq& _member_seq) - { - m_member_seq = _member_seq; - } - - RTPS_DllAPI inline void member_seq( - MinimalStructMemberSeq&& _member_seq) - { - m_member_seq = std::move(_member_seq); - } - - RTPS_DllAPI inline const MinimalStructMemberSeq& member_seq() const - { - return m_member_seq; - } - - RTPS_DllAPI inline MinimalStructMemberSeq& member_seq() - { - return m_member_seq; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalStructType::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const MinimalStructType& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalStructType::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalStructType::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const MinimalStructType& other) const; - - RTPS_DllAPI bool consistent( - const MinimalStructType& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - StructTypeFlag m_struct_flags; - MinimalStructHeader m_header; - MinimalStructMemberSeq m_member_seq; -}; - -// --- Union: --------------------------------------------------------- - -// Case labels that apply to a member of a union type -// Ordered by their values -typedef std::vector UnionCaseLabelSeq; - -/*struct CommonUnionMember final{ - MemberId member_id; - UnionMemberFlag member_flags; - TypeIdentifier type_id; - UnionCaseLabelSeq label_seq; - };*/ -class CommonUnionMember -{ -public: - - RTPS_DllAPI CommonUnionMember(); - RTPS_DllAPI ~CommonUnionMember(); - RTPS_DllAPI CommonUnionMember( - const CommonUnionMember& x); - RTPS_DllAPI CommonUnionMember( - CommonUnionMember&& x); - RTPS_DllAPI CommonUnionMember& operator =( - const CommonUnionMember& x); - RTPS_DllAPI CommonUnionMember& operator =( - CommonUnionMember&& x); - - RTPS_DllAPI inline void member_id( - const MemberId& _member_id) - { - m_member_id = _member_id; - } - - RTPS_DllAPI inline void member_id( - MemberId&& _member_id) - { - m_member_id = std::move(_member_id); - } - - RTPS_DllAPI inline const MemberId& member_id() const - { - return m_member_id; - } - - RTPS_DllAPI inline MemberId& member_id() - { - return m_member_id; - } - - RTPS_DllAPI inline void member_flags( - const UnionMemberFlag& _member_flags) - { - m_member_flags = _member_flags; - } - - RTPS_DllAPI inline void member_flags( - UnionMemberFlag&& _member_flags) - { - m_member_flags = std::move(_member_flags); - } - - RTPS_DllAPI inline const UnionMemberFlag& member_flags() const - { - return m_member_flags; - } - - RTPS_DllAPI inline UnionMemberFlag& member_flags() - { - return m_member_flags; - } - - RTPS_DllAPI inline void type_id( - const TypeIdentifier& _type_id) - { - m_type_id = _type_id; - } - - RTPS_DllAPI inline void type_id( - TypeIdentifier&& _type_id) - { - m_type_id = std::move(_type_id); - } - - RTPS_DllAPI inline const TypeIdentifier& type_id() const - { - return m_type_id; - } - - RTPS_DllAPI inline TypeIdentifier& type_id() - { - return m_type_id; - } - - RTPS_DllAPI inline void label_seq( - const UnionCaseLabelSeq& _label_seq) - { - m_label_seq = _label_seq; - } - - RTPS_DllAPI inline void label_seq( - UnionCaseLabelSeq&& _label_seq) - { - m_label_seq = std::move(_label_seq); - } - - RTPS_DllAPI inline const UnionCaseLabelSeq& label_seq() const - { - return m_label_seq; - } - - RTPS_DllAPI inline UnionCaseLabelSeq& label_seq() - { - return m_label_seq; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CommonUnionMember::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const CommonUnionMember& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CommonUnionMember::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CommonUnionMember::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const CommonUnionMember& other) const; - - RTPS_DllAPI bool consistent( - const CommonUnionMember& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - MemberId m_member_id; - UnionMemberFlag m_member_flags; - TypeIdentifier m_type_id; - UnionCaseLabelSeq m_label_seq; -}; - -// Member of a union type -/*struct CompleteUnionMember { - CommonUnionMember common; - CompleteMemberDetail detail; - };*/ -class CompleteUnionMember -{ -public: - - RTPS_DllAPI CompleteUnionMember(); - RTPS_DllAPI ~CompleteUnionMember(); - RTPS_DllAPI CompleteUnionMember( - const CompleteUnionMember& x); - RTPS_DllAPI CompleteUnionMember( - CompleteUnionMember&& x); - RTPS_DllAPI CompleteUnionMember& operator =( - const CompleteUnionMember& x); - RTPS_DllAPI CompleteUnionMember& operator =( - CompleteUnionMember&& x); - - RTPS_DllAPI inline void common( - const CommonUnionMember& _common) - { - m_common = _common; - } - - RTPS_DllAPI inline void common( - CommonUnionMember&& _common) - { - m_common = std::move(_common); - } - - RTPS_DllAPI inline const CommonUnionMember& common() const - { - return m_common; - } - - RTPS_DllAPI inline CommonUnionMember& common() - { - return m_common; - } - - RTPS_DllAPI inline void detail( - const CompleteMemberDetail& _detail) - { - m_detail = _detail; - } - - RTPS_DllAPI inline void detail( - CompleteMemberDetail&& _detail) - { - m_detail = std::move(_detail); - } - - RTPS_DllAPI inline const CompleteMemberDetail& detail() const - { - return m_detail; - } - - RTPS_DllAPI inline CompleteMemberDetail& detail() - { - return m_detail; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteUnionMember::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const CompleteUnionMember& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteUnionMember::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteUnionMember::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const CompleteUnionMember& other) const; - - RTPS_DllAPI bool consistent( - const CompleteUnionMember& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - CommonUnionMember m_common; - CompleteMemberDetail m_detail; -}; - -// Ordered by member_index -typedef std::vector CompleteUnionMemberSeq; - -// Member of a union type -/*struct MinimalUnionMember { - CommonUnionMember common; - MinimalMemberDetail detail; - };*/ -class MinimalUnionMember -{ -public: - - RTPS_DllAPI MinimalUnionMember(); - RTPS_DllAPI ~MinimalUnionMember(); - RTPS_DllAPI MinimalUnionMember( - const MinimalUnionMember& x); - RTPS_DllAPI MinimalUnionMember( - MinimalUnionMember&& x); - RTPS_DllAPI MinimalUnionMember& operator =( - const MinimalUnionMember& x); - RTPS_DllAPI MinimalUnionMember& operator =( - MinimalUnionMember&& x); - - RTPS_DllAPI inline void common( - const CommonUnionMember& _common) - { - m_common = _common; - } - - RTPS_DllAPI inline void common( - CommonUnionMember&& _common) - { - m_common = std::move(_common); - } - - RTPS_DllAPI inline const CommonUnionMember& common() const - { - return m_common; - } - - RTPS_DllAPI inline CommonUnionMember& common() - { - return m_common; - } - - RTPS_DllAPI inline void detail( - const MinimalMemberDetail& _detail) - { - m_detail = _detail; - } - - RTPS_DllAPI inline void detail( - MinimalMemberDetail&& _detail) - { - m_detail = std::move(_detail); - } - - RTPS_DllAPI inline const MinimalMemberDetail& detail() const - { - return m_detail; - } - - RTPS_DllAPI inline MinimalMemberDetail& detail() - { - return m_detail; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalUnionMember::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const MinimalUnionMember& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalUnionMember::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalUnionMember::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const MinimalUnionMember& other) const; - - RTPS_DllAPI bool consistent( - const MinimalUnionMember& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - CommonUnionMember m_common; - MinimalMemberDetail m_detail; -}; - -// Ordered by MinimalUnionMember.common.member_id -typedef std::vector MinimalUnionMemberSeq; - -/*struct CommonDiscriminatorMember final{ - UnionDiscriminatorFlag member_flags; - TypeIdentifier type_id; - };*/ -class CommonDiscriminatorMember -{ -public: - - RTPS_DllAPI CommonDiscriminatorMember(); - RTPS_DllAPI ~CommonDiscriminatorMember(); - RTPS_DllAPI CommonDiscriminatorMember( - const CommonDiscriminatorMember& x); - RTPS_DllAPI CommonDiscriminatorMember( - CommonDiscriminatorMember&& x); - RTPS_DllAPI CommonDiscriminatorMember& operator =( - const CommonDiscriminatorMember& x); - RTPS_DllAPI CommonDiscriminatorMember& operator =( - CommonDiscriminatorMember&& x); - - RTPS_DllAPI inline void member_flags( - const UnionDiscriminatorFlag& _member_flags) - { - m_member_flags = _member_flags; - } - - RTPS_DllAPI inline void member_flags( - UnionDiscriminatorFlag&& _member_flags) - { - m_member_flags = std::move(_member_flags); - } - - RTPS_DllAPI inline const UnionDiscriminatorFlag& member_flags() const - { - return m_member_flags; - } - - RTPS_DllAPI inline UnionDiscriminatorFlag& member_flags() - { - return m_member_flags; - } - - RTPS_DllAPI inline void type_id( - const TypeIdentifier& _type_id) - { - m_type_id = _type_id; - } - - RTPS_DllAPI inline void type_id( - TypeIdentifier&& _type_id) - { - m_type_id = std::move(_type_id); - } - - RTPS_DllAPI inline const TypeIdentifier& type_id() const - { - return m_type_id; - } - - RTPS_DllAPI inline TypeIdentifier& type_id() - { - return m_type_id; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CommonDiscriminatorMember::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const CommonDiscriminatorMember& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CommonDiscriminatorMember::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CommonDiscriminatorMember::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const CommonDiscriminatorMember& other) const; - - RTPS_DllAPI bool consistent( - const CommonDiscriminatorMember& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - UnionDiscriminatorFlag m_member_flags; - TypeIdentifier m_type_id; -}; - -// Member of a union type -/*struct CompleteDiscriminatorMember { - CommonDiscriminatorMember common; - AppliedBuiltinTypeAnnotations ann_builtin; // Optional - AppliedAnnotationSeq ann_custom; // Optional - };*/ -class CompleteDiscriminatorMember -{ -public: - - RTPS_DllAPI CompleteDiscriminatorMember(); - RTPS_DllAPI ~CompleteDiscriminatorMember(); - RTPS_DllAPI CompleteDiscriminatorMember( - const CompleteDiscriminatorMember& x); - RTPS_DllAPI CompleteDiscriminatorMember( - CompleteDiscriminatorMember&& x); - RTPS_DllAPI CompleteDiscriminatorMember& operator =( - const CompleteDiscriminatorMember& x); - RTPS_DllAPI CompleteDiscriminatorMember& operator =( - CompleteDiscriminatorMember&& x); - - RTPS_DllAPI inline void common( - const CommonDiscriminatorMember& _common) - { - m_common = _common; - } - - RTPS_DllAPI inline void common( - CommonDiscriminatorMember&& _common) - { - m_common = std::move(_common); - } - - RTPS_DllAPI inline const CommonDiscriminatorMember& common() const - { - return m_common; - } - - RTPS_DllAPI inline CommonDiscriminatorMember& common() - { - return m_common; - } - - RTPS_DllAPI inline void ann_builtin( - const AppliedBuiltinTypeAnnotations& _ann_builtin) - { - m_ann_builtin = _ann_builtin; - } - - RTPS_DllAPI inline void ann_builtin( - AppliedBuiltinTypeAnnotations&& _ann_builtin) - { - m_ann_builtin = std::move(_ann_builtin); - } - - RTPS_DllAPI inline const AppliedBuiltinTypeAnnotations& ann_builtin() const - { - return m_ann_builtin; - } - - RTPS_DllAPI inline AppliedBuiltinTypeAnnotations& ann_builtin() - { - return m_ann_builtin; - } - - RTPS_DllAPI inline void ann_custom( - const AppliedAnnotationSeq& _ann_custom) - { - m_ann_custom = _ann_custom; - } - - RTPS_DllAPI inline void ann_custom( - AppliedAnnotationSeq&& _ann_custom) - { - m_ann_custom = std::move(_ann_custom); - } - - RTPS_DllAPI inline const AppliedAnnotationSeq& ann_custom() const - { - return m_ann_custom; - } - - RTPS_DllAPI inline AppliedAnnotationSeq& ann_custom() - { - return m_ann_custom; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteDiscriminatorMember::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const CompleteDiscriminatorMember& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteDiscriminatorMember::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteDiscriminatorMember::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const CompleteDiscriminatorMember& other) const; - - RTPS_DllAPI bool consistent( - const CompleteDiscriminatorMember& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - CommonDiscriminatorMember m_common; - AppliedBuiltinTypeAnnotations m_ann_builtin; - AppliedAnnotationSeq m_ann_custom; -}; - -// Member of a union type -/*struct MinimalDiscriminatorMember { - CommonDiscriminatorMember common; - };*/ -class MinimalDiscriminatorMember -{ -public: - - RTPS_DllAPI MinimalDiscriminatorMember(); - RTPS_DllAPI ~MinimalDiscriminatorMember(); - RTPS_DllAPI MinimalDiscriminatorMember( - const MinimalDiscriminatorMember& x); - RTPS_DllAPI MinimalDiscriminatorMember( - MinimalDiscriminatorMember&& x); - RTPS_DllAPI MinimalDiscriminatorMember& operator =( - const MinimalDiscriminatorMember& x); - RTPS_DllAPI MinimalDiscriminatorMember& operator =( - MinimalDiscriminatorMember&& x); - - RTPS_DllAPI inline void common( - const CommonDiscriminatorMember& _common) - { - m_common = _common; - } - - RTPS_DllAPI inline void common( - CommonDiscriminatorMember&& _common) - { - m_common = std::move(_common); - } - - RTPS_DllAPI inline const CommonDiscriminatorMember& common() const - { - return m_common; - } - - RTPS_DllAPI inline CommonDiscriminatorMember& common() - { - return m_common; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalDiscriminatorMember::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const MinimalDiscriminatorMember& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalDiscriminatorMember::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalDiscriminatorMember::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const MinimalDiscriminatorMember& other) const; - - RTPS_DllAPI bool consistent( - const MinimalDiscriminatorMember& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - CommonDiscriminatorMember m_common; -}; - -/*struct CompleteUnionHeader { - CompleteTypeDetail detail; - };*/ -class CompleteUnionHeader -{ -public: - - RTPS_DllAPI CompleteUnionHeader(); - RTPS_DllAPI ~CompleteUnionHeader(); - RTPS_DllAPI CompleteUnionHeader( - const CompleteUnionHeader& x); - RTPS_DllAPI CompleteUnionHeader( - CompleteUnionHeader&& x); - RTPS_DllAPI CompleteUnionHeader& operator =( - const CompleteUnionHeader& x); - RTPS_DllAPI CompleteUnionHeader& operator =( - CompleteUnionHeader&& x); - - RTPS_DllAPI inline void detail( - const CompleteTypeDetail& _detail) - { - m_detail = _detail; - } - - RTPS_DllAPI inline void detail( - CompleteTypeDetail&& _detail) - { - m_detail = std::move(_detail); - } - - RTPS_DllAPI inline const CompleteTypeDetail& detail() const - { - return m_detail; - } - - RTPS_DllAPI inline CompleteTypeDetail& detail() - { - return m_detail; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteUnionHeader::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const CompleteUnionHeader& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteUnionHeader::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteUnionHeader::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const CompleteUnionHeader& other) const; - - RTPS_DllAPI bool consistent( - const CompleteUnionHeader& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - CompleteTypeDetail m_detail; -}; - -/*struct MinimalUnionHeader { - MinimalTypeDetail detail; - };*/ -class MinimalUnionHeader -{ -public: - - RTPS_DllAPI MinimalUnionHeader(); - RTPS_DllAPI ~MinimalUnionHeader(); - RTPS_DllAPI MinimalUnionHeader( - const MinimalUnionHeader& x); - RTPS_DllAPI MinimalUnionHeader( - MinimalUnionHeader&& x); - RTPS_DllAPI MinimalUnionHeader& operator =( - const MinimalUnionHeader& x); - RTPS_DllAPI MinimalUnionHeader& operator =( - MinimalUnionHeader&& x); - - RTPS_DllAPI inline void detail( - const MinimalTypeDetail& _detail) - { - m_detail = _detail; - } - - RTPS_DllAPI inline void detail( - MinimalTypeDetail&& _detail) - { - m_detail = std::move(_detail); - } - - RTPS_DllAPI inline const MinimalTypeDetail& detail() const - { - return m_detail; - } - - RTPS_DllAPI inline MinimalTypeDetail& detail() - { - return m_detail; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalUnionHeader::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const MinimalUnionHeader& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalUnionHeader::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalUnionHeader::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const MinimalUnionHeader& other) const; - - RTPS_DllAPI bool consistent( - const MinimalUnionHeader& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - MinimalTypeDetail m_detail; -}; - -/*struct CompleteUnionType final{ - UnionTypeFlag union_flags; - CompleteUnionHeader header; - CompleteDiscriminatorMember discriminator; - CompleteUnionMemberSeq member_seq; - };*/ -class CompleteUnionType -{ -public: - - RTPS_DllAPI CompleteUnionType(); - RTPS_DllAPI ~CompleteUnionType(); - RTPS_DllAPI CompleteUnionType( - const CompleteUnionType& x); - RTPS_DllAPI CompleteUnionType( - CompleteUnionType&& x); - RTPS_DllAPI CompleteUnionType& operator =( - const CompleteUnionType& x); - RTPS_DllAPI CompleteUnionType& operator =( - CompleteUnionType&& x); - - RTPS_DllAPI inline void union_flags( - const UnionTypeFlag& _union_flags) - { - m_union_flags = _union_flags; - } - - RTPS_DllAPI inline void union_flags( - UnionTypeFlag&& _union_flags) - { - m_union_flags = std::move(_union_flags); - } - - RTPS_DllAPI inline const UnionTypeFlag& union_flags() const - { - return m_union_flags; - } - - RTPS_DllAPI inline UnionTypeFlag& union_flags() - { - return m_union_flags; - } - - RTPS_DllAPI inline void header( - const CompleteUnionHeader& _header) - { - m_header = _header; - } - - RTPS_DllAPI inline void header( - CompleteUnionHeader&& _header) - { - m_header = std::move(_header); - } - - RTPS_DllAPI inline const CompleteUnionHeader& header() const - { - return m_header; - } - - RTPS_DllAPI inline CompleteUnionHeader& header() - { - return m_header; - } - - RTPS_DllAPI inline void discriminator( - const CompleteDiscriminatorMember& _discriminator) - { - m_discriminator = _discriminator; - } - - RTPS_DllAPI inline void discriminator( - CompleteDiscriminatorMember&& _discriminator) - { - m_discriminator = std::move(_discriminator); - } - - RTPS_DllAPI inline const CompleteDiscriminatorMember& discriminator() const - { - return m_discriminator; - } - - RTPS_DllAPI inline CompleteDiscriminatorMember& discriminator() - { - return m_discriminator; - } - - RTPS_DllAPI inline void member_seq( - const CompleteUnionMemberSeq& _member_seq) - { - m_member_seq = _member_seq; - } - - RTPS_DllAPI inline void member_seq( - CompleteUnionMemberSeq&& _member_seq) - { - m_member_seq = std::move(_member_seq); - } - - RTPS_DllAPI inline const CompleteUnionMemberSeq& member_seq() const - { - return m_member_seq; - } - - RTPS_DllAPI inline CompleteUnionMemberSeq& member_seq() - { - return m_member_seq; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteUnionType::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const CompleteUnionType& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteUnionType::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteUnionType::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const CompleteUnionType& other) const; - - RTPS_DllAPI bool consistent( - const CompleteUnionType& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - UnionTypeFlag m_union_flags; - CompleteUnionHeader m_header; - CompleteDiscriminatorMember m_discriminator; - CompleteUnionMemberSeq m_member_seq; -}; - -/*struct MinimalUnionType final{ - UnionTypeFlag union_flags; - MinimalUnionHeader header; - MinimalDiscriminatorMember discriminator; - MinimalUnionMemberSeq member_seq; - };*/ -class MinimalUnionType -{ -public: - - RTPS_DllAPI MinimalUnionType(); - RTPS_DllAPI ~MinimalUnionType(); - RTPS_DllAPI MinimalUnionType( - const MinimalUnionType& x); - RTPS_DllAPI MinimalUnionType( - MinimalUnionType&& x); - RTPS_DllAPI MinimalUnionType& operator =( - const MinimalUnionType& x); - RTPS_DllAPI MinimalUnionType& operator =( - MinimalUnionType&& x); - - RTPS_DllAPI inline void union_flags( - const UnionTypeFlag& _union_flags) - { - m_union_flags = _union_flags; - } - - RTPS_DllAPI inline void union_flags( - UnionTypeFlag&& _union_flags) - { - m_union_flags = std::move(_union_flags); - } - - RTPS_DllAPI inline const UnionTypeFlag& union_flags() const - { - return m_union_flags; - } - - RTPS_DllAPI inline UnionTypeFlag& union_flags() - { - return m_union_flags; - } - - RTPS_DllAPI inline void header( - const MinimalUnionHeader& _header) - { - m_header = _header; - } - - RTPS_DllAPI inline void header( - MinimalUnionHeader&& _header) - { - m_header = std::move(_header); - } - - RTPS_DllAPI inline const MinimalUnionHeader& header() const - { - return m_header; - } - - RTPS_DllAPI inline MinimalUnionHeader& header() - { - return m_header; - } - - RTPS_DllAPI inline void discriminator( - const MinimalDiscriminatorMember& _discriminator) - { - m_discriminator = _discriminator; - } - - RTPS_DllAPI inline void discriminator( - MinimalDiscriminatorMember&& _discriminator) - { - m_discriminator = std::move(_discriminator); - } - - RTPS_DllAPI inline const MinimalDiscriminatorMember& discriminator() const - { - return m_discriminator; - } - - RTPS_DllAPI inline MinimalDiscriminatorMember& discriminator() - { - return m_discriminator; - } - - RTPS_DllAPI inline void member_seq( - const MinimalUnionMemberSeq& _member_seq) - { - m_member_seq = _member_seq; - } - - RTPS_DllAPI inline void member_seq( - MinimalUnionMemberSeq&& _member_seq) - { - m_member_seq = std::move(_member_seq); - } - - RTPS_DllAPI inline const MinimalUnionMemberSeq& member_seq() const - { - return m_member_seq; - } - - RTPS_DllAPI inline MinimalUnionMemberSeq& member_seq() - { - return m_member_seq; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalUnionType::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const MinimalUnionType& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalUnionType::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalUnionType::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const MinimalUnionType& other) const; - - RTPS_DllAPI bool consistent( - const MinimalUnionType& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - UnionTypeFlag m_union_flags; - MinimalUnionHeader m_header; - MinimalDiscriminatorMember m_discriminator; - MinimalUnionMemberSeq m_member_seq; -}; - -// --- Annotation: --------------------------------------------------- -/*struct CommonAnnotationParameter final{ - AnnotationParameterFlag member_flags; - TypeIdentifier member_type_id; - };*/ -class CommonAnnotationParameter -{ -public: - - RTPS_DllAPI CommonAnnotationParameter(); - RTPS_DllAPI ~CommonAnnotationParameter(); - RTPS_DllAPI CommonAnnotationParameter( - const CommonAnnotationParameter& x); - RTPS_DllAPI CommonAnnotationParameter( - CommonAnnotationParameter&& x); - RTPS_DllAPI CommonAnnotationParameter& operator =( - const CommonAnnotationParameter& x); - RTPS_DllAPI CommonAnnotationParameter& operator =( - CommonAnnotationParameter&& x); - - RTPS_DllAPI inline void member_flags( - const AnnotationParameterFlag& _member_flags) - { - m_member_flags = _member_flags; - } - - RTPS_DllAPI inline void member_flags( - AnnotationParameterFlag&& _member_flags) - { - m_member_flags = std::move(_member_flags); - } - - RTPS_DllAPI inline const AnnotationParameterFlag& member_flags() const - { - return m_member_flags; - } - - RTPS_DllAPI inline AnnotationParameterFlag& member_flags() - { - return m_member_flags; - } - - RTPS_DllAPI inline void member_type_id( - const TypeIdentifier& _member_type_id) - { - m_member_type_id = _member_type_id; - } - - RTPS_DllAPI inline void member_type_id( - TypeIdentifier&& _member_type_id) - { - m_member_type_id = std::move(_member_type_id); - } - - RTPS_DllAPI inline const TypeIdentifier& member_type_id() const - { - return m_member_type_id; - } - - RTPS_DllAPI inline TypeIdentifier& member_type_id() - { - return m_member_type_id; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CommonAnnotationParameter::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const CommonAnnotationParameter& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CommonAnnotationParameter::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CommonAnnotationParameter::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const CommonAnnotationParameter& other) const; - - RTPS_DllAPI bool consistent( - const CommonAnnotationParameter& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - AnnotationParameterFlag m_member_flags; - TypeIdentifier m_member_type_id; -}; - -// Member of an annotation type - -/*struct CompleteAnnotationParameter { - CommonAnnotationParameter common; - MemberName name; - AnnotationParameterValue default_value; - };*/ -class CompleteAnnotationParameter -{ -public: - - RTPS_DllAPI CompleteAnnotationParameter(); - RTPS_DllAPI ~CompleteAnnotationParameter(); - RTPS_DllAPI CompleteAnnotationParameter( - const CompleteAnnotationParameter& x); - RTPS_DllAPI CompleteAnnotationParameter( - CompleteAnnotationParameter&& x); - RTPS_DllAPI CompleteAnnotationParameter& operator =( - const CompleteAnnotationParameter& x); - RTPS_DllAPI CompleteAnnotationParameter& operator =( - CompleteAnnotationParameter&& x); - - RTPS_DllAPI inline void common( - const CommonAnnotationParameter& _common) - { - m_common = _common; - } - - RTPS_DllAPI inline void common( - CommonAnnotationParameter&& _common) - { - m_common = std::move(_common); - } - - RTPS_DllAPI inline const CommonAnnotationParameter& common() const - { - return m_common; - } - - RTPS_DllAPI inline CommonAnnotationParameter& common() - { - return m_common; - } - - RTPS_DllAPI inline void name( - const MemberName& _name) - { - m_name = _name; - } - - RTPS_DllAPI inline void name( - MemberName&& _name) - { - m_name = std::move(_name); - } - - RTPS_DllAPI inline const MemberName& name() const - { - return m_name; - } - - RTPS_DllAPI inline MemberName& name() - { - return m_name; - } - - RTPS_DllAPI inline void default_value( - const AnnotationParameterValue& _default_value) - { - m_default_value = _default_value; - } - - RTPS_DllAPI inline void default_value( - AnnotationParameterValue&& _default_value) - { - m_default_value = std::move(_default_value); - } - - RTPS_DllAPI inline const AnnotationParameterValue& default_value() const - { - return m_default_value; - } - - RTPS_DllAPI inline AnnotationParameterValue& default_value() - { - return m_default_value; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteAnnotationParameter::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const CompleteAnnotationParameter& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteAnnotationParameter::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteAnnotationParameter::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const CompleteAnnotationParameter& other) const; - - RTPS_DllAPI bool consistent( - const CompleteAnnotationParameter& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - CommonAnnotationParameter m_common; - MemberName m_name; - AnnotationParameterValue m_default_value; -}; -// Ordered by CompleteAnnotationParameter.name -typedef std::vector CompleteAnnotationParameterSeq; -/*struct MinimalAnnotationParameter { - CommonAnnotationParameter common; - NameHash name_hash; - AnnotationParameterValue default_value; - };*/ -class MinimalAnnotationParameter -{ -public: - - RTPS_DllAPI MinimalAnnotationParameter(); - RTPS_DllAPI ~MinimalAnnotationParameter(); - RTPS_DllAPI MinimalAnnotationParameter( - const MinimalAnnotationParameter& x); - RTPS_DllAPI MinimalAnnotationParameter( - MinimalAnnotationParameter&& x); - RTPS_DllAPI MinimalAnnotationParameter& operator =( - const MinimalAnnotationParameter& x); - RTPS_DllAPI MinimalAnnotationParameter& operator =( - MinimalAnnotationParameter&& x); - - RTPS_DllAPI inline void common( - const CommonAnnotationParameter& _common) - { - m_common = _common; - } - - RTPS_DllAPI inline void common( - CommonAnnotationParameter&& _common) - { - m_common = std::move(_common); - } - - RTPS_DllAPI inline const CommonAnnotationParameter& common() const - { - return m_common; - } - - RTPS_DllAPI inline CommonAnnotationParameter& common() - { - return m_common; - } - - RTPS_DllAPI inline void name( - const MemberName& _name) - { - m_name = _name; - } - - RTPS_DllAPI inline void name( - MemberName&& _name) - { - m_name = std::move(_name); - } - - RTPS_DllAPI inline const MemberName& name() const - { - return m_name; - } - - RTPS_DllAPI inline MemberName& name() - { - return m_name; - } - - RTPS_DllAPI inline void default_value( - const AnnotationParameterValue& _default_value) - { - m_default_value = _default_value; - } - - RTPS_DllAPI inline void default_value( - AnnotationParameterValue&& _default_value) - { - m_default_value = std::move(_default_value); - } - - RTPS_DllAPI inline const AnnotationParameterValue& default_value() const - { - return m_default_value; - } - - RTPS_DllAPI inline AnnotationParameterValue& default_value() - { - return m_default_value; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalAnnotationParameter::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const MinimalAnnotationParameter& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalAnnotationParameter::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalAnnotationParameter::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const MinimalAnnotationParameter& other) const; - - RTPS_DllAPI bool consistent( - const MinimalAnnotationParameter& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - CommonAnnotationParameter m_common; - MemberName m_name; - AnnotationParameterValue m_default_value; -}; - -// Ordered by MinimalAnnotationParameter.name_hash -typedef std::vector MinimalAnnotationParameterSeq; -/*struct CompleteAnnotationHeader { - QualifiedTypeName annotation_name; - };*/ -class CompleteAnnotationHeader -{ -public: - - RTPS_DllAPI CompleteAnnotationHeader(); - RTPS_DllAPI ~CompleteAnnotationHeader(); - RTPS_DllAPI CompleteAnnotationHeader( - const CompleteAnnotationHeader& x); - RTPS_DllAPI CompleteAnnotationHeader( - CompleteAnnotationHeader&& x); - RTPS_DllAPI CompleteAnnotationHeader& operator =( - const CompleteAnnotationHeader& x); - RTPS_DllAPI CompleteAnnotationHeader& operator =( - CompleteAnnotationHeader&& x); - - RTPS_DllAPI inline void annotation_name( - const QualifiedTypeName& _annotation_name) - { - m_annotation_name = _annotation_name; - } - - RTPS_DllAPI inline void annotation_name( - QualifiedTypeName&& _annotation_name) - { - m_annotation_name = std::move(_annotation_name); - } - - RTPS_DllAPI inline const QualifiedTypeName& annotation_name() const - { - return m_annotation_name; - } - - RTPS_DllAPI inline QualifiedTypeName& annotation_name() - { - return m_annotation_name; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteAnnotationHeader::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const CompleteAnnotationHeader& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteAnnotationHeader::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteAnnotationHeader::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const CompleteAnnotationHeader& other) const; - - RTPS_DllAPI bool consistent( - const CompleteAnnotationHeader& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - QualifiedTypeName m_annotation_name; -}; - -/*struct MinimalAnnotationHeader { - // Empty. Available for future extension - };*/ -class MinimalAnnotationHeader -{ -public: - - RTPS_DllAPI MinimalAnnotationHeader(); - RTPS_DllAPI ~MinimalAnnotationHeader(); - RTPS_DllAPI MinimalAnnotationHeader( - const MinimalAnnotationHeader& x); - RTPS_DllAPI MinimalAnnotationHeader( - MinimalAnnotationHeader&& x); - RTPS_DllAPI MinimalAnnotationHeader& operator =( - const MinimalAnnotationHeader& x); - RTPS_DllAPI MinimalAnnotationHeader& operator =( - MinimalAnnotationHeader&& x); - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalAnnotationHeader::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const MinimalAnnotationHeader& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalAnnotationHeader::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalAnnotationHeader::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const MinimalAnnotationHeader&) const - { - return true; - } - - RTPS_DllAPI bool consistent( - const MinimalAnnotationHeader& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - -}; - -/*struct CompleteAnnotationType final{ - AnnotationTypeFlag annotation_flag; - CompleteAnnotationHeader header; - CompleteAnnotationParameterSeq member_seq; - };*/ -class CompleteAnnotationType final -{ -public: - - RTPS_DllAPI CompleteAnnotationType(); - RTPS_DllAPI ~CompleteAnnotationType(); - RTPS_DllAPI CompleteAnnotationType( - const CompleteAnnotationType& x); - RTPS_DllAPI CompleteAnnotationType( - CompleteAnnotationType&& x); - RTPS_DllAPI CompleteAnnotationType& operator =( - const CompleteAnnotationType& x); - RTPS_DllAPI CompleteAnnotationType& operator =( - CompleteAnnotationType&& x); - - RTPS_DllAPI inline void annotation_flag( - const AnnotationTypeFlag& _annotation_flag) - { - m_annotation_flag = _annotation_flag; - } - - RTPS_DllAPI inline void annotation_flag( - AnnotationTypeFlag&& _annotation_flag) - { - m_annotation_flag = std::move(_annotation_flag); - } - - RTPS_DllAPI inline const AnnotationTypeFlag& annotation_flag() const - { - return m_annotation_flag; - } - - RTPS_DllAPI inline AnnotationTypeFlag& annotation_flag() - { - return m_annotation_flag; - } - - RTPS_DllAPI inline void header( - const CompleteAnnotationHeader& _header) - { - m_header = _header; - } - - RTPS_DllAPI inline void header( - CompleteAnnotationHeader&& _header) - { - m_header = std::move(_header); - } - - RTPS_DllAPI inline const CompleteAnnotationHeader& header() const - { - return m_header; - } - - RTPS_DllAPI inline CompleteAnnotationHeader& header() - { - return m_header; - } - - RTPS_DllAPI inline void member_seq( - const CompleteAnnotationParameterSeq& _member_seq) - { - m_member_seq = _member_seq; - } - - RTPS_DllAPI inline void member_seq( - CompleteAnnotationParameterSeq&& _member_seq) - { - m_member_seq = std::move(_member_seq); - } - - RTPS_DllAPI inline const CompleteAnnotationParameterSeq& member_seq() const - { - return m_member_seq; - } - - RTPS_DllAPI inline CompleteAnnotationParameterSeq& member_seq() - { - return m_member_seq; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteAnnotationType::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const CompleteAnnotationType& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteAnnotationType::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteAnnotationType::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const CompleteAnnotationType& other) const; - - RTPS_DllAPI bool consistent( - const CompleteAnnotationType& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - AnnotationTypeFlag m_annotation_flag; - CompleteAnnotationHeader m_header; - CompleteAnnotationParameterSeq m_member_seq; -}; -/*struct MinimalAnnotationType final{ - AnnotationTypeFlag annotation_flag; - MinimalAnnotationHeader header; - MinimalAnnotationParameterSeq member_seq; - };*/ -class MinimalAnnotationType final -{ -public: - - RTPS_DllAPI MinimalAnnotationType(); - RTPS_DllAPI ~MinimalAnnotationType(); - RTPS_DllAPI MinimalAnnotationType( - const MinimalAnnotationType& x); - RTPS_DllAPI MinimalAnnotationType( - MinimalAnnotationType&& x); - RTPS_DllAPI MinimalAnnotationType& operator =( - const MinimalAnnotationType& x); - RTPS_DllAPI MinimalAnnotationType& operator =( - MinimalAnnotationType&& x); - - RTPS_DllAPI inline void annotation_flag( - const AnnotationTypeFlag& _annotation_flag) - { - m_annotation_flag = _annotation_flag; - } - - RTPS_DllAPI inline void annotation_flag( - AnnotationTypeFlag&& _annotation_flag) - { - m_annotation_flag = std::move(_annotation_flag); - } - - RTPS_DllAPI inline const AnnotationTypeFlag& annotation_flag() const - { - return m_annotation_flag; - } - - RTPS_DllAPI inline AnnotationTypeFlag& annotation_flag() - { - return m_annotation_flag; - } - - RTPS_DllAPI inline void header( - const MinimalAnnotationHeader& _header) - { - m_header = _header; - } - - RTPS_DllAPI inline void header( - MinimalAnnotationHeader&& _header) - { - m_header = std::move(_header); - } - - RTPS_DllAPI inline const MinimalAnnotationHeader& header() const - { - return m_header; - } - - RTPS_DllAPI inline MinimalAnnotationHeader& header() - { - return m_header; - } - - RTPS_DllAPI inline void member_seq( - const MinimalAnnotationParameterSeq& _member_seq) - { - m_member_seq = _member_seq; - } - - RTPS_DllAPI inline void member_seq( - MinimalAnnotationParameterSeq&& _member_seq) - { - m_member_seq = std::move(_member_seq); - } - - RTPS_DllAPI inline const MinimalAnnotationParameterSeq& member_seq() const - { - return m_member_seq; - } - - RTPS_DllAPI inline MinimalAnnotationParameterSeq& member_seq() - { - return m_member_seq; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalAnnotationType::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const MinimalAnnotationType& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalAnnotationType::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalAnnotationType::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const MinimalAnnotationType& other) const; - - RTPS_DllAPI bool consistent( - const MinimalAnnotationType& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - AnnotationTypeFlag m_annotation_flag; - MinimalAnnotationHeader m_header; - MinimalAnnotationParameterSeq m_member_seq; -}; - -// --- Alias: --------------------------------------------------------- -/*struct CommonAliasBody final{ - AliasMemberFlag related_flags; - TypeIdentifier related_type; - };*/ -class CommonAliasBody -{ -public: - - RTPS_DllAPI CommonAliasBody(); - RTPS_DllAPI ~CommonAliasBody(); - RTPS_DllAPI CommonAliasBody( - const CommonAliasBody& x); - RTPS_DllAPI CommonAliasBody( - CommonAliasBody&& x); - RTPS_DllAPI CommonAliasBody& operator =( - const CommonAliasBody& x); - RTPS_DllAPI CommonAliasBody& operator =( - CommonAliasBody&& x); - - RTPS_DllAPI inline void related_flags( - const AliasMemberFlag& _related_flags) - { - m_related_flags = _related_flags; - } - - RTPS_DllAPI inline void related_flags( - AliasMemberFlag&& _related_flags) - { - m_related_flags = std::move(_related_flags); - } - - RTPS_DllAPI inline const AliasMemberFlag& related_flags() const - { - return m_related_flags; - } - - RTPS_DllAPI inline AliasMemberFlag& related_flags() - { - return m_related_flags; - } - - RTPS_DllAPI inline void related_type( - const TypeIdentifier& _related_type) - { - m_related_type = _related_type; - } - - RTPS_DllAPI inline void related_type( - TypeIdentifier&& _related_type) - { - m_related_type = std::move(_related_type); - } - - RTPS_DllAPI inline const TypeIdentifier& related_type() const - { - return m_related_type; - } - - RTPS_DllAPI inline TypeIdentifier& related_type() - { - return m_related_type; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CommonAliasBody::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const CommonAliasBody& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CommonAliasBody::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CommonAliasBody::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const CommonAliasBody& other) const; - - // RTPS_DllAPI bool consistent(const CommonAliasBody &x, - // const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - AliasMemberFlag m_related_flags; - TypeIdentifier m_related_type; -}; - -/*struct CompleteAliasBody { - CommonAliasBody common; - AppliedBuiltinMemberAnnotations ann_builtin; // Optional - AppliedAnnotationSeq ann_custom; // Optional - };*/ -class CompleteAliasBody -{ -public: - - RTPS_DllAPI CompleteAliasBody(); - RTPS_DllAPI ~CompleteAliasBody(); - RTPS_DllAPI CompleteAliasBody( - const CompleteAliasBody& x); - RTPS_DllAPI CompleteAliasBody( - CompleteAliasBody&& x); - RTPS_DllAPI CompleteAliasBody& operator =( - const CompleteAliasBody& x); - RTPS_DllAPI CompleteAliasBody& operator =( - CompleteAliasBody&& x); - - RTPS_DllAPI inline void common( - const CommonAliasBody& _common) - { - m_common = _common; - } - - RTPS_DllAPI inline void common( - CommonAliasBody&& _common) - { - m_common = std::move(_common); - } - - RTPS_DllAPI inline const CommonAliasBody& common() const - { - return m_common; - } - - RTPS_DllAPI inline CommonAliasBody& common() - { - return m_common; - } - - RTPS_DllAPI inline void ann_builtin( - const AppliedBuiltinMemberAnnotations& _ann_builtin) - { - m_ann_builtin = _ann_builtin; - } - - RTPS_DllAPI inline void ann_builtin( - AppliedBuiltinMemberAnnotations&& _ann_builtin) - { - m_ann_builtin = std::move(_ann_builtin); - } - - RTPS_DllAPI inline const AppliedBuiltinMemberAnnotations& ann_builtin() const - { - return m_ann_builtin; - } - - RTPS_DllAPI inline AppliedBuiltinMemberAnnotations& ann_builtin() - { - return m_ann_builtin; - } - - RTPS_DllAPI inline void ann_custom( - const AppliedAnnotationSeq& _ann_custom) - { - m_ann_custom = _ann_custom; - } - - RTPS_DllAPI inline void ann_custom( - AppliedAnnotationSeq&& _ann_custom) - { - m_ann_custom = std::move(_ann_custom); - } - - RTPS_DllAPI inline const AppliedAnnotationSeq& ann_custom() const - { - return m_ann_custom; - } - - RTPS_DllAPI inline AppliedAnnotationSeq& ann_custom() - { - return m_ann_custom; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteAliasBody::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const CompleteAliasBody& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteAliasBody::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteAliasBody::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const CompleteAliasBody& other) const; - - // RTPS_DllAPI bool consistent(const CompleteAliasBody &x, - // const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - CommonAliasBody m_common; - AppliedBuiltinMemberAnnotations m_ann_builtin; - AppliedAnnotationSeq m_ann_custom; -}; - -/*struct MinimalAliasBody { - CommonAliasBody common; - };*/ -class MinimalAliasBody -{ -public: - - RTPS_DllAPI MinimalAliasBody(); - RTPS_DllAPI ~MinimalAliasBody(); - RTPS_DllAPI MinimalAliasBody( - const MinimalAliasBody& x); - RTPS_DllAPI MinimalAliasBody( - MinimalAliasBody&& x); - RTPS_DllAPI MinimalAliasBody& operator =( - const MinimalAliasBody& x); - RTPS_DllAPI MinimalAliasBody& operator =( - MinimalAliasBody&& x); - - RTPS_DllAPI inline void common( - const CommonAliasBody& _common) - { - m_common = _common; - } - - RTPS_DllAPI inline void common( - CommonAliasBody&& _common) - { - m_common = std::move(_common); - } - - RTPS_DllAPI inline const CommonAliasBody& common() const - { - return m_common; - } - - RTPS_DllAPI inline CommonAliasBody& common() - { - return m_common; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalAliasBody::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const MinimalAliasBody& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalAliasBody::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalAliasBody::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const MinimalAliasBody& other) const; - - // RTPS_DllAPI bool consistent(const MinimalAliasBody &x, - // const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - CommonAliasBody m_common; -}; - -/*struct CompleteAliasHeader { - CompleteTypeDetail detail; - };*/ -class CompleteAliasHeader -{ -public: - - RTPS_DllAPI CompleteAliasHeader(); - RTPS_DllAPI ~CompleteAliasHeader(); - RTPS_DllAPI CompleteAliasHeader( - const CompleteAliasHeader& x); - RTPS_DllAPI CompleteAliasHeader( - CompleteAliasHeader&& x); - RTPS_DllAPI CompleteAliasHeader& operator =( - const CompleteAliasHeader& x); - RTPS_DllAPI CompleteAliasHeader& operator =( - CompleteAliasHeader&& x); - - RTPS_DllAPI inline void detail( - const CompleteTypeDetail& _detail) - { - m_detail = _detail; - } - - RTPS_DllAPI inline void detail( - CompleteTypeDetail&& _detail) - { - m_detail = std::move(_detail); - } - - RTPS_DllAPI inline const CompleteTypeDetail& detail() const - { - return m_detail; - } - - RTPS_DllAPI inline CompleteTypeDetail& detail() - { - return m_detail; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteAliasHeader::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const CompleteAliasHeader& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteAliasHeader::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteAliasHeader::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const CompleteAliasHeader& other) const; - - // RTPS_DllAPI bool consistent(const CompleteAliasHeader &x, - // const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - CompleteTypeDetail m_detail; -}; - -/*struct MinimalAliasHeader { - // Empty. Available for future extension - };*/ -class MinimalAliasHeader -{ -public: - - RTPS_DllAPI MinimalAliasHeader(); - RTPS_DllAPI ~MinimalAliasHeader(); - RTPS_DllAPI MinimalAliasHeader( - const MinimalAliasHeader& x); - RTPS_DllAPI MinimalAliasHeader( - MinimalAliasHeader&& x); - RTPS_DllAPI MinimalAliasHeader& operator =( - const MinimalAliasHeader& x); - RTPS_DllAPI MinimalAliasHeader& operator =( - MinimalAliasHeader&& x); - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalAliasHeader::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const MinimalAliasHeader& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalAliasHeader::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalAliasHeader::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const MinimalAliasHeader&) const - { - return true; - } - - // RTPS_DllAPI bool consistent(const MinimalAliasHeader &x, - // const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - -}; - -/*struct CompleteAliasType final{ - AliasTypeFlag alias_flags; - CompleteAliasHeader header; - CompleteAliasBody body; - };*/ -class CompleteAliasType -{ -public: - - RTPS_DllAPI CompleteAliasType(); - RTPS_DllAPI ~CompleteAliasType(); - RTPS_DllAPI CompleteAliasType( - const CompleteAliasType& x); - RTPS_DllAPI CompleteAliasType( - CompleteAliasType&& x); - RTPS_DllAPI CompleteAliasType& operator =( - const CompleteAliasType& x); - RTPS_DllAPI CompleteAliasType& operator =( - CompleteAliasType&& x); - - RTPS_DllAPI inline void alias_flags( - const AliasTypeFlag& _alias_flags) - { - m_alias_flags = _alias_flags; - } - - RTPS_DllAPI inline void alias_flags( - AliasTypeFlag&& _alias_flags) - { - m_alias_flags = std::move(_alias_flags); - } - - RTPS_DllAPI inline const AliasTypeFlag& alias_flags() const - { - return m_alias_flags; - } - - RTPS_DllAPI inline AliasTypeFlag& alias_flags() - { - return m_alias_flags; - } - - RTPS_DllAPI inline void header( - const CompleteAliasHeader& _header) - { - m_header = _header; - } - - RTPS_DllAPI inline void header( - CompleteAliasHeader&& _header) - { - m_header = std::move(_header); - } - - RTPS_DllAPI inline const CompleteAliasHeader& header() const - { - return m_header; - } - - RTPS_DllAPI inline CompleteAliasHeader& header() - { - return m_header; - } - - RTPS_DllAPI inline void body( - const CompleteAliasBody& _body) - { - m_body = _body; - } - - RTPS_DllAPI inline void body( - CompleteAliasBody&& _body) - { - m_body = std::move(_body); - } - - RTPS_DllAPI inline const CompleteAliasBody& body() const - { - return m_body; - } - - RTPS_DllAPI inline CompleteAliasBody& body() - { - return m_body; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteAliasType::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const CompleteAliasType& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteAliasType::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteAliasType::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const CompleteAliasType& other) const; - - // RTPS_DllAPI bool consistent(const CompleteAliasType &x, - // const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - AliasTypeFlag m_alias_flags; - CompleteAliasHeader m_header; - CompleteAliasBody m_body; -}; -/*struct MinimalAliasType final{ - AliasTypeFlag alias_flags; - MinimalAliasHeader header; - MinimalAliasBody body; - };*/ -class MinimalAliasType -{ -public: - - RTPS_DllAPI MinimalAliasType(); - RTPS_DllAPI ~MinimalAliasType(); - RTPS_DllAPI MinimalAliasType( - const MinimalAliasType& x); - RTPS_DllAPI MinimalAliasType( - MinimalAliasType&& x); - RTPS_DllAPI MinimalAliasType& operator =( - const MinimalAliasType& x); - RTPS_DllAPI MinimalAliasType& operator =( - MinimalAliasType&& x); - - RTPS_DllAPI inline void alias_flags( - const AliasTypeFlag& _alias_flags) - { - m_alias_flags = _alias_flags; - } - - RTPS_DllAPI inline void alias_flags( - AliasTypeFlag&& _alias_flags) - { - m_alias_flags = std::move(_alias_flags); - } - - RTPS_DllAPI inline const AliasTypeFlag& alias_flags() const - { - return m_alias_flags; - } - - RTPS_DllAPI inline AliasTypeFlag& alias_flags() - { - return m_alias_flags; - } - - RTPS_DllAPI inline void header( - const MinimalAliasHeader& _header) - { - m_header = _header; - } - - RTPS_DllAPI inline void header( - MinimalAliasHeader&& _header) - { - m_header = std::move(_header); - } - - RTPS_DllAPI inline const MinimalAliasHeader& header() const - { - return m_header; - } - - RTPS_DllAPI inline MinimalAliasHeader& header() - { - return m_header; - } - - RTPS_DllAPI inline void body( - const MinimalAliasBody& _body) - { - m_body = _body; - } - - RTPS_DllAPI inline void body( - MinimalAliasBody&& _body) - { - m_body = std::move(_body); - } - - RTPS_DllAPI inline const MinimalAliasBody& body() const - { - return m_body; - } - - RTPS_DllAPI inline MinimalAliasBody& body() - { - return m_body; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalAliasType::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const MinimalAliasType& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalAliasType::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalAliasType::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const MinimalAliasType& other) const; - - // RTPS_DllAPI bool consistent(const MinimalAliasType &x, - // const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - AliasTypeFlag m_alias_flags; - MinimalAliasHeader m_header; - MinimalAliasBody m_body; -}; - -// --- Collections: --------------------------------------------------- -/*struct CompleteElementDetail final{ - AppliedBuiltinMemberAnnotations ann_builtin; // Optional - AppliedAnnotationSeq ann_custom; // Optional - };*/ -class CompleteElementDetail -{ -public: - - RTPS_DllAPI CompleteElementDetail(); - RTPS_DllAPI ~CompleteElementDetail(); - RTPS_DllAPI CompleteElementDetail( - const CompleteElementDetail& x); - RTPS_DllAPI CompleteElementDetail( - CompleteElementDetail&& x); - RTPS_DllAPI CompleteElementDetail& operator =( - const CompleteElementDetail& x); - RTPS_DllAPI CompleteElementDetail& operator =( - CompleteElementDetail&& x); - - RTPS_DllAPI inline void ann_builtin( - const AppliedBuiltinMemberAnnotations& _ann_builtin) - { - m_ann_builtin = _ann_builtin; - } - - RTPS_DllAPI inline void ann_builtin( - AppliedBuiltinMemberAnnotations&& _ann_builtin) - { - m_ann_builtin = std::move(_ann_builtin); - } - - RTPS_DllAPI inline const AppliedBuiltinMemberAnnotations& ann_builtin() const - { - return m_ann_builtin; - } - - RTPS_DllAPI inline AppliedBuiltinMemberAnnotations& ann_builtin() - { - return m_ann_builtin; - } - - RTPS_DllAPI inline void ann_custom( - const AppliedAnnotationSeq& _ann_custom) - { - m_ann_custom = _ann_custom; - } - - RTPS_DllAPI inline void ann_custom( - AppliedAnnotationSeq&& _ann_custom) - { - m_ann_custom = std::move(_ann_custom); - } - - RTPS_DllAPI inline const AppliedAnnotationSeq& ann_custom() const - { - return m_ann_custom; - } - - RTPS_DllAPI inline AppliedAnnotationSeq& ann_custom() - { - return m_ann_custom; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteElementDetail::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const CompleteElementDetail& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteElementDetail::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteElementDetail::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const CompleteElementDetail& other) const; - - RTPS_DllAPI bool consistent( - const CompleteElementDetail& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - AppliedBuiltinMemberAnnotations m_ann_builtin; - AppliedAnnotationSeq m_ann_custom; -}; -/*struct CommonCollectionElement final{ - CollectionElementFlag element_flags; - TypeIdentifier type; - };*/ -class CommonCollectionElement final -{ -public: - - RTPS_DllAPI CommonCollectionElement(); - RTPS_DllAPI ~CommonCollectionElement(); - RTPS_DllAPI CommonCollectionElement( - const CommonCollectionElement& x); - RTPS_DllAPI CommonCollectionElement( - CommonCollectionElement&& x); - RTPS_DllAPI CommonCollectionElement& operator =( - const CommonCollectionElement& x); - RTPS_DllAPI CommonCollectionElement& operator =( - CommonCollectionElement&& x); - - RTPS_DllAPI inline void element_flags( - const CollectionElementFlag& _element_flags) - { - m_element_flags = _element_flags; - } - - RTPS_DllAPI inline void element_flags( - CollectionElementFlag&& _element_flags) - { - m_element_flags = std::move(_element_flags); - } - - RTPS_DllAPI inline const CollectionElementFlag& element_flags() const - { - return m_element_flags; - } - - RTPS_DllAPI inline CollectionElementFlag& element_flags() - { - return m_element_flags; - } - - RTPS_DllAPI inline void type( - const TypeIdentifier& _type) - { - m_type = _type; - } - - RTPS_DllAPI inline void type( - TypeIdentifier&& _type) - { - m_type = std::move(_type); - } - - RTPS_DllAPI inline const TypeIdentifier& type() const - { - return m_type; - } - - RTPS_DllAPI inline TypeIdentifier& type() - { - return m_type; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CommonCollectionElement::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const CommonCollectionElement& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CommonCollectionElement::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CommonCollectionElement::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const CommonCollectionElement& other) const; - - RTPS_DllAPI bool consistent( - const CommonCollectionElement& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - CollectionElementFlag m_element_flags; - TypeIdentifier m_type; -}; - -/*struct CompleteCollectionElement { - CommonCollectionElement common; - CompleteElementDetail detail; - };*/ -class CompleteCollectionElement -{ -public: - - RTPS_DllAPI CompleteCollectionElement(); - RTPS_DllAPI ~CompleteCollectionElement(); - RTPS_DllAPI CompleteCollectionElement( - const CompleteCollectionElement& x); - RTPS_DllAPI CompleteCollectionElement( - CompleteCollectionElement&& x); - RTPS_DllAPI CompleteCollectionElement& operator =( - const CompleteCollectionElement& x); - RTPS_DllAPI CompleteCollectionElement& operator =( - CompleteCollectionElement&& x); - - RTPS_DllAPI inline void common( - const CommonCollectionElement& _common) - { - m_common = _common; - } - - RTPS_DllAPI inline void common( - CommonCollectionElement&& _common) - { - m_common = std::move(_common); - } - - RTPS_DllAPI inline const CommonCollectionElement& common() const - { - return m_common; - } - - RTPS_DllAPI inline CommonCollectionElement& common() - { - return m_common; - } - - RTPS_DllAPI inline void detail( - const CompleteElementDetail& _detail) - { - m_detail = _detail; - } - - RTPS_DllAPI inline void detail( - CompleteElementDetail&& _detail) - { - m_detail = std::move(_detail); - } - - RTPS_DllAPI inline const CompleteElementDetail& detail() const - { - return m_detail; - } - - RTPS_DllAPI inline CompleteElementDetail& detail() - { - return m_detail; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteCollectionElement::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const CompleteCollectionElement& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteCollectionElement::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteCollectionElement::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const CompleteCollectionElement& other) const; - - RTPS_DllAPI bool consistent( - const CompleteCollectionElement& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - CommonCollectionElement m_common; - CompleteElementDetail m_detail; -}; - -/*struct MinimalCollectionElement { - CommonCollectionElement common; - };*/ -class MinimalCollectionElement -{ -public: - - RTPS_DllAPI MinimalCollectionElement(); - RTPS_DllAPI ~MinimalCollectionElement(); - RTPS_DllAPI MinimalCollectionElement( - const MinimalCollectionElement& x); - RTPS_DllAPI MinimalCollectionElement( - MinimalCollectionElement&& x); - RTPS_DllAPI MinimalCollectionElement& operator =( - const MinimalCollectionElement& x); - RTPS_DllAPI MinimalCollectionElement& operator =( - MinimalCollectionElement&& x); - - RTPS_DllAPI inline void common( - const CommonCollectionElement& _common) - { - m_common = _common; - } - - RTPS_DllAPI inline void common( - CommonCollectionElement&& _common) - { - m_common = std::move(_common); - } - - RTPS_DllAPI inline const CommonCollectionElement& common() const - { - return m_common; - } - - RTPS_DllAPI inline CommonCollectionElement& common() - { - return m_common; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalCollectionElement::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const MinimalCollectionElement& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalCollectionElement::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalCollectionElement::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const MinimalCollectionElement& other) const; - - RTPS_DllAPI bool consistent( - const MinimalCollectionElement& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - CommonCollectionElement m_common; -}; - -/*struct CommonCollectionHeader final{ - LBound bound; - };*/ -class CommonCollectionHeader -{ -public: - - RTPS_DllAPI CommonCollectionHeader(); - RTPS_DllAPI ~CommonCollectionHeader(); - RTPS_DllAPI CommonCollectionHeader( - const CommonCollectionHeader& x); - RTPS_DllAPI CommonCollectionHeader( - CommonCollectionHeader&& x); - RTPS_DllAPI CommonCollectionHeader& operator =( - const CommonCollectionHeader& x); - RTPS_DllAPI CommonCollectionHeader& operator =( - CommonCollectionHeader&& x); - - RTPS_DllAPI inline void bound( - const LBound& _bound) - { - m_bound = _bound; - } - - RTPS_DllAPI inline void bound( - LBound&& _bound) - { - m_bound = std::move(_bound); - } - - RTPS_DllAPI inline const LBound& bound() const - { - return m_bound; - } - - RTPS_DllAPI inline LBound& bound() - { - return m_bound; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CommonCollectionHeader::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const CommonCollectionHeader& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CommonCollectionHeader::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CommonCollectionHeader::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const CommonCollectionHeader& other) const; - - RTPS_DllAPI bool consistent( - const CommonCollectionHeader& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - LBound m_bound; -}; - -/*struct CompleteCollectionHeader { - CommonCollectionHeader common; - CompleteTypeDetail detail; // Optional // not present for anonymous - };*/ -class CompleteCollectionHeader -{ -public: - - RTPS_DllAPI CompleteCollectionHeader(); - RTPS_DllAPI ~CompleteCollectionHeader(); - RTPS_DllAPI CompleteCollectionHeader( - const CompleteCollectionHeader& x); - RTPS_DllAPI CompleteCollectionHeader( - CompleteCollectionHeader&& x); - RTPS_DllAPI CompleteCollectionHeader& operator =( - const CompleteCollectionHeader& x); - RTPS_DllAPI CompleteCollectionHeader& operator =( - CompleteCollectionHeader&& x); - - RTPS_DllAPI inline void common( - const CommonCollectionHeader& _common) - { - m_common = _common; - } - - RTPS_DllAPI inline void common( - CommonCollectionHeader&& _common) - { - m_common = std::move(_common); - } - - RTPS_DllAPI inline const CommonCollectionHeader& common() const - { - return m_common; - } - - RTPS_DllAPI inline CommonCollectionHeader& common() - { - return m_common; - } - - RTPS_DllAPI inline void detail( - const CompleteTypeDetail& _detail) - { - m_detail = _detail; - } - - RTPS_DllAPI inline void detail( - CompleteTypeDetail&& _detail) - { - m_detail = std::move(_detail); - } - - RTPS_DllAPI inline const CompleteTypeDetail& detail() const - { - return m_detail; - } - - RTPS_DllAPI inline CompleteTypeDetail& detail() - { - return m_detail; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteCollectionHeader::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const CompleteCollectionHeader& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteCollectionHeader::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteCollectionHeader::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const CompleteCollectionHeader& other) const; - - RTPS_DllAPI bool consistent( - const CompleteCollectionHeader& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - CommonCollectionHeader m_common; - CompleteTypeDetail m_detail; -}; - -/*struct MinimalCollectionHeader { - CommonCollectionHeader common; - };*/ -class MinimalCollectionHeader -{ -public: - - RTPS_DllAPI MinimalCollectionHeader(); - RTPS_DllAPI ~MinimalCollectionHeader(); - RTPS_DllAPI MinimalCollectionHeader( - const MinimalCollectionHeader& x); - RTPS_DllAPI MinimalCollectionHeader( - MinimalCollectionHeader&& x); - RTPS_DllAPI MinimalCollectionHeader& operator =( - const MinimalCollectionHeader& x); - RTPS_DllAPI MinimalCollectionHeader& operator =( - MinimalCollectionHeader&& x); - - RTPS_DllAPI inline void common( - const CommonCollectionHeader& _common) - { - m_common = _common; - } - - RTPS_DllAPI inline void common( - CommonCollectionHeader&& _common) - { - m_common = std::move(_common); - } - - RTPS_DllAPI inline const CommonCollectionHeader& common() const - { - return m_common; - } - - RTPS_DllAPI inline CommonCollectionHeader& common() - { - return m_common; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalCollectionHeader::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const MinimalCollectionHeader& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalCollectionHeader::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalCollectionHeader::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const MinimalCollectionHeader& other) const; - - RTPS_DllAPI bool consistent( - const MinimalCollectionHeader& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - CommonCollectionHeader m_common; -}; - -// --- Sequence: ----------------------------------------------------- -/*struct CompleteSequenceType final{ - CollectionTypeFlag collection_flag; - CompleteCollectionHeader header; - CompleteCollectionElement element; - };*/ -class CompleteSequenceType -{ -public: - - RTPS_DllAPI CompleteSequenceType(); - RTPS_DllAPI ~CompleteSequenceType(); - RTPS_DllAPI CompleteSequenceType( - const CompleteSequenceType& x); - RTPS_DllAPI CompleteSequenceType( - CompleteSequenceType&& x); - RTPS_DllAPI CompleteSequenceType& operator =( - const CompleteSequenceType& x); - RTPS_DllAPI CompleteSequenceType& operator =( - CompleteSequenceType&& x); - - RTPS_DllAPI inline void collection_flag( - const CollectionTypeFlag& _collection_flag) - { - m_collection_flag = _collection_flag; - } - - RTPS_DllAPI inline void collection_flag( - CollectionTypeFlag&& _collection_flag) - { - m_collection_flag = std::move(_collection_flag); - } - - RTPS_DllAPI inline const CollectionTypeFlag& collection_flag() const - { - return m_collection_flag; - } - - RTPS_DllAPI inline CollectionTypeFlag& collection_flag() - { - return m_collection_flag; - } - - RTPS_DllAPI inline void header( - const CompleteCollectionHeader& _header) - { - m_header = _header; - } - - RTPS_DllAPI inline void header( - CompleteCollectionHeader&& _header) - { - m_header = std::move(_header); - } - - RTPS_DllAPI inline const CompleteCollectionHeader& header() const - { - return m_header; - } - - RTPS_DllAPI inline CompleteCollectionHeader& header() - { - return m_header; - } - - RTPS_DllAPI inline void element( - const CompleteCollectionElement& _element) - { - m_element = _element; - } - - RTPS_DllAPI inline void element( - CompleteCollectionElement&& _element) - { - m_element = std::move(_element); - } - - RTPS_DllAPI inline const CompleteCollectionElement& element() const - { - return m_element; - } - - RTPS_DllAPI inline CompleteCollectionElement& element() - { - return m_element; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteSequenceType::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const CompleteSequenceType& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteSequenceType::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteSequenceType::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const CompleteSequenceType& other) const; - - RTPS_DllAPI bool consistent( - const CompleteSequenceType& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - CollectionTypeFlag m_collection_flag; - CompleteCollectionHeader m_header; - CompleteCollectionElement m_element; -}; - -/*struct MinimalSequenceType final{ - CollectionTypeFlag collection_flag; - MinimalCollectionHeader header; - MinimalCollectionElement element; - };*/ -class MinimalSequenceType -{ -public: - - RTPS_DllAPI MinimalSequenceType(); - RTPS_DllAPI ~MinimalSequenceType(); - RTPS_DllAPI MinimalSequenceType( - const MinimalSequenceType& x); - RTPS_DllAPI MinimalSequenceType( - MinimalSequenceType&& x); - RTPS_DllAPI MinimalSequenceType& operator =( - const MinimalSequenceType& x); - RTPS_DllAPI MinimalSequenceType& operator =( - MinimalSequenceType&& x); - - RTPS_DllAPI inline void collection_flag( - const CollectionTypeFlag& _collection_flag) - { - m_collection_flag = _collection_flag; - } - - RTPS_DllAPI inline void collection_flag( - CollectionTypeFlag&& _collection_flag) - { - m_collection_flag = std::move(_collection_flag); - } - - RTPS_DllAPI inline const CollectionTypeFlag& collection_flag() const - { - return m_collection_flag; - } - - RTPS_DllAPI inline CollectionTypeFlag& collection_flag() - { - return m_collection_flag; - } - - RTPS_DllAPI inline void header( - const MinimalCollectionHeader& _header) - { - m_header = _header; - } - - RTPS_DllAPI inline void header( - MinimalCollectionHeader&& _header) - { - m_header = std::move(_header); - } - - RTPS_DllAPI inline const MinimalCollectionHeader& header() const - { - return m_header; - } - - RTPS_DllAPI inline MinimalCollectionHeader& header() - { - return m_header; - } - - RTPS_DllAPI inline void element( - const MinimalCollectionElement& _element) - { - m_element = _element; - } - - RTPS_DllAPI inline void element( - MinimalCollectionElement&& _element) - { - m_element = std::move(_element); - } - - RTPS_DllAPI inline const MinimalCollectionElement& element() const - { - return m_element; - } - - RTPS_DllAPI inline MinimalCollectionElement& element() - { - return m_element; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalSequenceType::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const MinimalSequenceType& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalSequenceType::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalSequenceType::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const MinimalSequenceType& other) const; - - RTPS_DllAPI bool consistent( - const MinimalSequenceType& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - CollectionTypeFlag m_collection_flag; - MinimalCollectionHeader m_header; - MinimalCollectionElement m_element; -}; - -// --- Array: ----------------------------------------------------- -/*struct CommonArrayHeader final{ - LBoundSeq bound_seq; - };*/ -class CommonArrayHeader -{ -public: - - RTPS_DllAPI CommonArrayHeader(); - RTPS_DllAPI ~CommonArrayHeader(); - RTPS_DllAPI CommonArrayHeader( - const CommonArrayHeader& x); - RTPS_DllAPI CommonArrayHeader( - CommonArrayHeader&& x); - RTPS_DllAPI CommonArrayHeader& operator =( - const CommonArrayHeader& x); - RTPS_DllAPI CommonArrayHeader& operator =( - CommonArrayHeader&& x); - - RTPS_DllAPI inline void bound_seq( - const LBoundSeq& _bound_seq) - { - m_bound_seq = _bound_seq; - } - - RTPS_DllAPI inline void bound_seq( - LBoundSeq&& _bound_seq) - { - m_bound_seq = std::move(_bound_seq); - } - - RTPS_DllAPI inline const LBoundSeq& bound_seq() const - { - return m_bound_seq; - } - - RTPS_DllAPI inline LBoundSeq& bound_seq() - { - return m_bound_seq; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CommonArrayHeader::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const CommonArrayHeader& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CommonArrayHeader::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CommonArrayHeader::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const CommonArrayHeader& other) const; - - RTPS_DllAPI bool consistent( - const CommonArrayHeader& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - LBoundSeq m_bound_seq; -}; - -/*struct CompleteArrayHeader { - CommonArrayHeader common; - CompleteTypeDetail detail; - };*/ -class CompleteArrayHeader -{ -public: - - RTPS_DllAPI CompleteArrayHeader(); - RTPS_DllAPI ~CompleteArrayHeader(); - RTPS_DllAPI CompleteArrayHeader( - const CompleteArrayHeader& x); - RTPS_DllAPI CompleteArrayHeader( - CompleteArrayHeader&& x); - RTPS_DllAPI CompleteArrayHeader& operator =( - const CompleteArrayHeader& x); - RTPS_DllAPI CompleteArrayHeader& operator =( - CompleteArrayHeader&& x); - - RTPS_DllAPI inline void common( - const CommonArrayHeader& _common) - { - m_common = _common; - } - - RTPS_DllAPI inline void common( - CommonArrayHeader&& _common) - { - m_common = std::move(_common); - } - - RTPS_DllAPI inline const CommonArrayHeader& common() const - { - return m_common; - } - - RTPS_DllAPI inline CommonArrayHeader& common() - { - return m_common; - } - - RTPS_DllAPI inline void detail( - const CompleteTypeDetail& _detail) - { - m_detail = _detail; - } - - RTPS_DllAPI inline void detail( - CompleteTypeDetail&& _detail) - { - m_detail = std::move(_detail); - } - - RTPS_DllAPI inline const CompleteTypeDetail& detail() const - { - return m_detail; - } - - RTPS_DllAPI inline CompleteTypeDetail& detail() - { - return m_detail; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteArrayHeader::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const CompleteArrayHeader& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteArrayHeader::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteArrayHeader::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const CompleteArrayHeader& other) const; - - RTPS_DllAPI bool consistent( - const CompleteArrayHeader& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - CommonArrayHeader m_common; - CompleteTypeDetail m_detail; -}; - -/*struct MinimalArrayHeader { - CommonArrayHeader common; - };*/ -class MinimalArrayHeader -{ -public: - - RTPS_DllAPI MinimalArrayHeader(); - RTPS_DllAPI ~MinimalArrayHeader(); - RTPS_DllAPI MinimalArrayHeader( - const MinimalArrayHeader& x); - RTPS_DllAPI MinimalArrayHeader( - MinimalArrayHeader&& x); - RTPS_DllAPI MinimalArrayHeader& operator =( - const MinimalArrayHeader& x); - RTPS_DllAPI MinimalArrayHeader& operator =( - MinimalArrayHeader&& x); - - RTPS_DllAPI inline void common( - const CommonArrayHeader& _common) - { - m_common = _common; - } - - RTPS_DllAPI inline void common( - CommonArrayHeader&& _common) - { - m_common = std::move(_common); - } - - RTPS_DllAPI inline const CommonArrayHeader& common() const - { - return m_common; - } - - RTPS_DllAPI inline CommonArrayHeader& common() - { - return m_common; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalArrayHeader::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const MinimalArrayHeader& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalArrayHeader::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalArrayHeader::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const MinimalArrayHeader& other) const; - - RTPS_DllAPI bool consistent( - const MinimalArrayHeader& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - CommonArrayHeader m_common; -}; - -/*struct CompleteArrayType { - CollectionTypeFlag collection_flag; - CompleteArrayHeader header; - CompleteCollectionElement element; - };*/ -class CompleteArrayType -{ -public: - - RTPS_DllAPI CompleteArrayType(); - RTPS_DllAPI ~CompleteArrayType(); - RTPS_DllAPI CompleteArrayType( - const CompleteArrayType& x); - RTPS_DllAPI CompleteArrayType( - CompleteArrayType&& x); - RTPS_DllAPI CompleteArrayType& operator =( - const CompleteArrayType& x); - RTPS_DllAPI CompleteArrayType& operator =( - CompleteArrayType&& x); - - RTPS_DllAPI inline void collection_flag( - const CollectionTypeFlag& _collection_flag) - { - m_collection_flag = _collection_flag; - } - - RTPS_DllAPI inline void collection_flag( - CollectionTypeFlag&& _collection_flag) - { - m_collection_flag = std::move(_collection_flag); - } - - RTPS_DllAPI inline const CollectionTypeFlag& collection_flag() const - { - return m_collection_flag; - } - - RTPS_DllAPI inline CollectionTypeFlag& collection_flag() - { - return m_collection_flag; - } - - RTPS_DllAPI inline void header( - const CompleteArrayHeader& _header) - { - m_header = _header; - } - - RTPS_DllAPI inline void header( - CompleteArrayHeader&& _header) - { - m_header = std::move(_header); - } - - RTPS_DllAPI inline const CompleteArrayHeader& header() const - { - return m_header; - } - - RTPS_DllAPI inline CompleteArrayHeader& header() - { - return m_header; - } - - RTPS_DllAPI inline void element( - const CompleteCollectionElement& _element) - { - m_element = _element; - } - - RTPS_DllAPI inline void element( - CompleteCollectionElement&& _element) - { - m_element = std::move(_element); - } - - RTPS_DllAPI inline const CompleteCollectionElement& element() const - { - return m_element; - } - - RTPS_DllAPI inline CompleteCollectionElement& element() - { - return m_element; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteArrayType::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const CompleteArrayType& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteArrayType::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteArrayType::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const CompleteArrayType& other) const; - - RTPS_DllAPI bool consistent( - const CompleteArrayType& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - CollectionTypeFlag m_collection_flag; - CompleteArrayHeader m_header; - CompleteCollectionElement m_element; -}; - -/*struct MinimalArrayType final{ - CollectionTypeFlag collection_flag; - MinimalArrayHeader header; - MinimalCollectionElement element; - };*/ -class MinimalArrayType -{ -public: - - RTPS_DllAPI MinimalArrayType(); - RTPS_DllAPI ~MinimalArrayType(); - RTPS_DllAPI MinimalArrayType( - const MinimalArrayType& x); - RTPS_DllAPI MinimalArrayType( - MinimalArrayType&& x); - RTPS_DllAPI MinimalArrayType& operator =( - const MinimalArrayType& x); - RTPS_DllAPI MinimalArrayType& operator =( - MinimalArrayType&& x); - - RTPS_DllAPI inline void collection_flag( - const CollectionTypeFlag& _collection_flag) - { - m_collection_flag = _collection_flag; - } - - RTPS_DllAPI inline void collection_flag( - CollectionTypeFlag&& _collection_flag) - { - m_collection_flag = std::move(_collection_flag); - } - - RTPS_DllAPI inline const CollectionTypeFlag& collection_flag() const - { - return m_collection_flag; - } - - RTPS_DllAPI inline CollectionTypeFlag& collection_flag() - { - return m_collection_flag; - } - - RTPS_DllAPI inline void header( - const MinimalArrayHeader& _header) - { - m_header = _header; - } - - RTPS_DllAPI inline void header( - MinimalArrayHeader&& _header) - { - m_header = std::move(_header); - } - - RTPS_DllAPI inline const MinimalArrayHeader& header() const - { - return m_header; - } - - RTPS_DllAPI inline MinimalArrayHeader& header() - { - return m_header; - } - - RTPS_DllAPI inline void element( - const MinimalCollectionElement& _element) - { - m_element = _element; - } - - RTPS_DllAPI inline void element( - MinimalCollectionElement&& _element) - { - m_element = std::move(_element); - } - - RTPS_DllAPI inline const MinimalCollectionElement& element() const - { - return m_element; - } - - RTPS_DllAPI inline MinimalCollectionElement& element() - { - return m_element; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalArrayType::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const MinimalArrayType& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalArrayType::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalArrayType::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const MinimalArrayType& other) const; - - RTPS_DllAPI bool consistent( - const MinimalArrayType& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - CollectionTypeFlag m_collection_flag; - MinimalArrayHeader m_header; - MinimalCollectionElement m_element; -}; - -// --- Map: ----------------------------------------------------- -/*struct CompleteMapType final{ - CollectionTypeFlag collection_flag; - CompleteCollectionHeader header; - CompleteCollectionElement key; - CompleteCollectionElement element; - };*/ -class CompleteMapType final -{ -public: - - RTPS_DllAPI CompleteMapType(); - RTPS_DllAPI ~CompleteMapType(); - RTPS_DllAPI CompleteMapType( - const CompleteMapType& x); - RTPS_DllAPI CompleteMapType( - CompleteMapType&& x); - RTPS_DllAPI CompleteMapType& operator =( - const CompleteMapType& x); - RTPS_DllAPI CompleteMapType& operator =( - CompleteMapType&& x); - - RTPS_DllAPI inline void collection_flag( - const CollectionTypeFlag& _collection_flag) - { - m_collection_flag = _collection_flag; - } - - RTPS_DllAPI inline void collection_flag( - CollectionTypeFlag&& _collection_flag) - { - m_collection_flag = std::move(_collection_flag); - } - - RTPS_DllAPI inline const CollectionTypeFlag& collection_flag() const - { - return m_collection_flag; - } - - RTPS_DllAPI inline CollectionTypeFlag& collection_flag() - { - return m_collection_flag; - } - - RTPS_DllAPI inline void header( - const CompleteCollectionHeader& _header) - { - m_header = _header; - } - - RTPS_DllAPI inline void header( - CompleteCollectionHeader&& _header) - { - m_header = std::move(_header); - } - - RTPS_DllAPI inline const CompleteCollectionHeader& header() const - { - return m_header; - } - - RTPS_DllAPI inline CompleteCollectionHeader& header() - { - return m_header; - } - - RTPS_DllAPI inline void key( - const CompleteCollectionElement& _key) - { - m_key = _key; - } - - RTPS_DllAPI inline void key( - CompleteCollectionElement&& _key) - { - m_key = std::move(_key); - } - - RTPS_DllAPI inline const CompleteCollectionElement& key() const - { - return m_key; - } - - RTPS_DllAPI inline CompleteCollectionElement& key() - { - return m_key; - } - - RTPS_DllAPI inline void element( - const CompleteCollectionElement& _element) - { - m_element = _element; - } - - RTPS_DllAPI inline void element( - CompleteCollectionElement&& _element) - { - m_element = std::move(_element); - } - - RTPS_DllAPI inline const CompleteCollectionElement& element() const - { - return m_element; - } - - RTPS_DllAPI inline CompleteCollectionElement& element() - { - return m_element; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteMapType::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const CompleteMapType& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteMapType::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteMapType::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const CompleteMapType& other) const; - - RTPS_DllAPI bool consistent( - const CompleteMapType& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - CollectionTypeFlag m_collection_flag; - CompleteCollectionHeader m_header; - CompleteCollectionElement m_key; - CompleteCollectionElement m_element; -}; -/*struct MinimalMapType final{ - CollectionTypeFlag collection_flag; - MinimalCollectionHeader header; - MinimalCollectionElement key; - MinimalCollectionElement element; - };*/ -class MinimalMapType final -{ -public: - - RTPS_DllAPI MinimalMapType(); - RTPS_DllAPI ~MinimalMapType(); - RTPS_DllAPI MinimalMapType( - const MinimalMapType& x); - RTPS_DllAPI MinimalMapType( - MinimalMapType&& x); - RTPS_DllAPI MinimalMapType& operator =( - const MinimalMapType& x); - RTPS_DllAPI MinimalMapType& operator =( - MinimalMapType&& x); - - RTPS_DllAPI inline void collection_flag( - const CollectionTypeFlag& _collection_flag) - { - m_collection_flag = _collection_flag; - } - - RTPS_DllAPI inline void collection_flag( - CollectionTypeFlag&& _collection_flag) - { - m_collection_flag = std::move(_collection_flag); - } - - RTPS_DllAPI inline const CollectionTypeFlag& collection_flag() const - { - return m_collection_flag; - } - - RTPS_DllAPI inline CollectionTypeFlag& collection_flag() - { - return m_collection_flag; - } - - RTPS_DllAPI inline void header( - const MinimalCollectionHeader& _header) - { - m_header = _header; - } - - RTPS_DllAPI inline void header( - MinimalCollectionHeader&& _header) - { - m_header = std::move(_header); - } - - RTPS_DllAPI inline const MinimalCollectionHeader& header() const - { - return m_header; - } - - RTPS_DllAPI inline MinimalCollectionHeader& header() - { - return m_header; - } - - RTPS_DllAPI inline void key( - const MinimalCollectionElement& _key) - { - m_key = _key; - } - - RTPS_DllAPI inline void key( - MinimalCollectionElement&& _key) - { - m_key = std::move(_key); - } - - RTPS_DllAPI inline const MinimalCollectionElement& key() const - { - return m_key; - } - - RTPS_DllAPI inline MinimalCollectionElement& key() - { - return m_key; - } - - RTPS_DllAPI inline void element( - const MinimalCollectionElement& _element) - { - m_element = _element; - } - - RTPS_DllAPI inline void element( - MinimalCollectionElement&& _element) - { - m_element = std::move(_element); - } - - RTPS_DllAPI inline const MinimalCollectionElement& element() const - { - return m_element; - } - - RTPS_DllAPI inline MinimalCollectionElement& element() - { - return m_element; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalMapType::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const MinimalMapType& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalMapType::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalMapType::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const MinimalMapType& other) const; - - RTPS_DllAPI bool consistent( - const MinimalMapType& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - CollectionTypeFlag m_collection_flag; - MinimalCollectionHeader m_header; - MinimalCollectionElement m_key; - MinimalCollectionElement m_element; -}; - -// --- Enumeration: --------------------------------------------------- -typedef uint16_t BitBound; - -// Constant in an enumerated type - -/*struct CommonEnumeratedLiteral { - int32_t value; - EnumeratedLiteralFlag flags; - };*/ -class CommonEnumeratedLiteral -{ -public: - - RTPS_DllAPI CommonEnumeratedLiteral(); - RTPS_DllAPI ~CommonEnumeratedLiteral(); - RTPS_DllAPI CommonEnumeratedLiteral( - const CommonEnumeratedLiteral& x); - RTPS_DllAPI CommonEnumeratedLiteral( - CommonEnumeratedLiteral&& x); - RTPS_DllAPI CommonEnumeratedLiteral& operator =( - const CommonEnumeratedLiteral& x); - RTPS_DllAPI CommonEnumeratedLiteral& operator =( - CommonEnumeratedLiteral&& x); - - RTPS_DllAPI inline void value( - const int32_t& _value) - { - m_value = _value; - } - - RTPS_DllAPI inline void value( - int32_t&& _value) - { - m_value = std::move(_value); - } - - RTPS_DllAPI inline const int32_t& value() const - { - return m_value; - } - - RTPS_DllAPI inline int32_t& value() - { - return m_value; - } - - RTPS_DllAPI inline void flags( - const EnumeratedLiteralFlag& _flags) - { - m_flags = _flags; - } - - RTPS_DllAPI inline void flags( - EnumeratedLiteralFlag&& _flags) - { - m_flags = std::move(_flags); - } - - RTPS_DllAPI inline const EnumeratedLiteralFlag& flags() const - { - return m_flags; - } - - RTPS_DllAPI inline EnumeratedLiteralFlag& flags() - { - return m_flags; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CommonEnumeratedLiteral::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const CommonEnumeratedLiteral& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CommonEnumeratedLiteral::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CommonEnumeratedLiteral::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const CommonEnumeratedLiteral& other) const; - - RTPS_DllAPI bool consistent( - const CommonEnumeratedLiteral& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - int32_t m_value; - EnumeratedLiteralFlag m_flags; -}; - -// Constant in an enumerated type - -/*struct CompleteEnumeratedLiteral { - CommonEnumeratedLiteral common; - CompleteMemberDetail detail; - };*/ -class CompleteEnumeratedLiteral -{ -public: - - RTPS_DllAPI CompleteEnumeratedLiteral(); - RTPS_DllAPI ~CompleteEnumeratedLiteral(); - RTPS_DllAPI CompleteEnumeratedLiteral( - const CompleteEnumeratedLiteral& x); - RTPS_DllAPI CompleteEnumeratedLiteral( - CompleteEnumeratedLiteral&& x); - RTPS_DllAPI CompleteEnumeratedLiteral& operator =( - const CompleteEnumeratedLiteral& x); - RTPS_DllAPI CompleteEnumeratedLiteral& operator =( - CompleteEnumeratedLiteral&& x); - - RTPS_DllAPI inline void common( - const CommonEnumeratedLiteral& _common) - { - m_common = _common; - } - - RTPS_DllAPI inline void common( - CommonEnumeratedLiteral&& _common) - { - m_common = std::move(_common); - } - - RTPS_DllAPI inline const CommonEnumeratedLiteral& common() const - { - return m_common; - } - - RTPS_DllAPI inline CommonEnumeratedLiteral& common() - { - return m_common; - } - - RTPS_DllAPI inline void detail( - const CompleteMemberDetail& _detail) - { - m_detail = _detail; - } - - RTPS_DllAPI inline void detail( - CompleteMemberDetail&& _detail) - { - m_detail = std::move(_detail); - } - - RTPS_DllAPI inline const CompleteMemberDetail& detail() const - { - return m_detail; - } - - RTPS_DllAPI inline CompleteMemberDetail& detail() - { - return m_detail; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteEnumeratedLiteral::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const CompleteEnumeratedLiteral& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteEnumeratedLiteral::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteEnumeratedLiteral::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const CompleteEnumeratedLiteral& other) const; - - RTPS_DllAPI bool consistent( - const CompleteEnumeratedLiteral& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - CommonEnumeratedLiteral m_common; - CompleteMemberDetail m_detail; -}; -// Ordered by EnumeratedLiteral.common.value -typedef std::vector CompleteEnumeratedLiteralSeq; - -// Constant in an enumerated type - -/*struct MinimalEnumeratedLiteral { - CommonEnumeratedLiteral common; - MinimalMemberDetail detail; - };*/ -class MinimalEnumeratedLiteral -{ -public: - - RTPS_DllAPI MinimalEnumeratedLiteral(); - RTPS_DllAPI ~MinimalEnumeratedLiteral(); - RTPS_DllAPI MinimalEnumeratedLiteral( - const MinimalEnumeratedLiteral& x); - RTPS_DllAPI MinimalEnumeratedLiteral( - MinimalEnumeratedLiteral&& x); - RTPS_DllAPI MinimalEnumeratedLiteral& operator =( - const MinimalEnumeratedLiteral& x); - RTPS_DllAPI MinimalEnumeratedLiteral& operator =( - MinimalEnumeratedLiteral&& x); - - RTPS_DllAPI inline void common( - const CommonEnumeratedLiteral& _common) - { - m_common = _common; - } - - RTPS_DllAPI inline void common( - CommonEnumeratedLiteral&& _common) - { - m_common = std::move(_common); - } - - RTPS_DllAPI inline const CommonEnumeratedLiteral& common() const - { - return m_common; - } - - RTPS_DllAPI inline CommonEnumeratedLiteral& common() - { - return m_common; - } - - RTPS_DllAPI inline void detail( - const MinimalMemberDetail& _detail) - { - m_detail = _detail; - } - - RTPS_DllAPI inline void detail( - MinimalMemberDetail&& _detail) - { - m_detail = std::move(_detail); - } - - RTPS_DllAPI inline const MinimalMemberDetail& detail() const - { - return m_detail; - } - - RTPS_DllAPI inline MinimalMemberDetail& detail() - { - return m_detail; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalEnumeratedLiteral::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const MinimalEnumeratedLiteral& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalEnumeratedLiteral::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalEnumeratedLiteral::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const MinimalEnumeratedLiteral& other) const; - - RTPS_DllAPI bool consistent( - const MinimalEnumeratedLiteral& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - CommonEnumeratedLiteral m_common; - MinimalMemberDetail m_detail; -}; - -// Ordered by EnumeratedLiteral.common.value -typedef std::vector MinimalEnumeratedLiteralSeq; - -/*struct CommonEnumeratedHeader final{ - BitBound bit_bound; - };*/ -class CommonEnumeratedHeader final -{ -public: - - RTPS_DllAPI CommonEnumeratedHeader(); - RTPS_DllAPI ~CommonEnumeratedHeader(); - RTPS_DllAPI CommonEnumeratedHeader( - const CommonEnumeratedHeader& x); - RTPS_DllAPI CommonEnumeratedHeader( - CommonEnumeratedHeader&& x); - RTPS_DllAPI CommonEnumeratedHeader& operator =( - const CommonEnumeratedHeader& x); - RTPS_DllAPI CommonEnumeratedHeader& operator =( - CommonEnumeratedHeader&& x); - - RTPS_DllAPI inline void bit_bound( - const BitBound& _bit_bound) - { - m_bit_bound = _bit_bound; - } - - RTPS_DllAPI inline void bit_bound( - BitBound&& _bit_bound) - { - m_bit_bound = std::move(_bit_bound); - } - - RTPS_DllAPI inline const BitBound& bit_bound() const - { - return m_bit_bound; - } - - RTPS_DllAPI inline BitBound& bit_bound() - { - return m_bit_bound; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CommonEnumeratedHeader::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const CommonEnumeratedHeader& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CommonEnumeratedHeader::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CommonEnumeratedHeader::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const CommonEnumeratedHeader& other) const; - - RTPS_DllAPI bool consistent( - const CommonEnumeratedHeader& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - BitBound m_bit_bound; -}; - -/*struct CompleteEnumeratedHeader { - CommonEnumeratedHeader common; - CompleteTypeDetail detail; - };*/ -class CompleteEnumeratedHeader -{ -public: - - RTPS_DllAPI CompleteEnumeratedHeader(); - RTPS_DllAPI ~CompleteEnumeratedHeader(); - RTPS_DllAPI CompleteEnumeratedHeader( - const CompleteEnumeratedHeader& x); - RTPS_DllAPI CompleteEnumeratedHeader( - CompleteEnumeratedHeader&& x); - RTPS_DllAPI CompleteEnumeratedHeader& operator =( - const CompleteEnumeratedHeader& x); - RTPS_DllAPI CompleteEnumeratedHeader& operator =( - CompleteEnumeratedHeader&& x); - - RTPS_DllAPI inline void common( - const CommonEnumeratedHeader& _common) - { - m_common = _common; - } - - RTPS_DllAPI inline void common( - CommonEnumeratedHeader&& _common) - { - m_common = std::move(_common); - } - - RTPS_DllAPI inline const CommonEnumeratedHeader& common() const - { - return m_common; - } - - RTPS_DllAPI inline CommonEnumeratedHeader& common() - { - return m_common; - } - - RTPS_DllAPI inline void detail( - const CompleteTypeDetail& _detail) - { - m_detail = _detail; - } - - RTPS_DllAPI inline void detail( - CompleteTypeDetail&& _detail) - { - m_detail = std::move(_detail); - } - - RTPS_DllAPI inline const CompleteTypeDetail& detail() const - { - return m_detail; - } - - RTPS_DllAPI inline CompleteTypeDetail& detail() - { - return m_detail; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteEnumeratedHeader::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const CompleteEnumeratedHeader& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteEnumeratedHeader::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteEnumeratedHeader::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const CompleteEnumeratedHeader& other) const; - - RTPS_DllAPI bool consistent( - const CompleteEnumeratedHeader& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - CommonEnumeratedHeader m_common; - CompleteTypeDetail m_detail; -}; - -/*struct MinimalEnumeratedHeader { - CommonEnumeratedHeader common; - };*/ -class MinimalEnumeratedHeader -{ -public: - - RTPS_DllAPI MinimalEnumeratedHeader(); - RTPS_DllAPI ~MinimalEnumeratedHeader(); - RTPS_DllAPI MinimalEnumeratedHeader( - const MinimalEnumeratedHeader& x); - RTPS_DllAPI MinimalEnumeratedHeader( - MinimalEnumeratedHeader&& x); - RTPS_DllAPI MinimalEnumeratedHeader& operator =( - const MinimalEnumeratedHeader& x); - RTPS_DllAPI MinimalEnumeratedHeader& operator =( - MinimalEnumeratedHeader&& x); - - RTPS_DllAPI inline void common( - const CommonEnumeratedHeader& _common) - { - m_common = _common; - } - - RTPS_DllAPI inline void common( - CommonEnumeratedHeader&& _common) - { - m_common = std::move(_common); - } - - RTPS_DllAPI inline const CommonEnumeratedHeader& common() const - { - return m_common; - } - - RTPS_DllAPI inline CommonEnumeratedHeader& common() - { - return m_common; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalEnumeratedHeader::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const MinimalEnumeratedHeader& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalEnumeratedHeader::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalEnumeratedHeader::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const MinimalEnumeratedHeader& other) const; - - RTPS_DllAPI bool consistent( - const MinimalEnumeratedHeader& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - CommonEnumeratedHeader m_common; -}; - -// Enumerated type -/*struct CompleteEnumeratedType final{ - EnumTypeFlag enum_flags; // unused - CompleteEnumeratedHeader header; - CompleteEnumeratedLiteralSeq literal_seq; - };*/ -class CompleteEnumeratedType -{ -public: - - RTPS_DllAPI CompleteEnumeratedType(); - RTPS_DllAPI ~CompleteEnumeratedType(); - RTPS_DllAPI CompleteEnumeratedType( - const CompleteEnumeratedType& x); - RTPS_DllAPI CompleteEnumeratedType( - CompleteEnumeratedType&& x); - RTPS_DllAPI CompleteEnumeratedType& operator =( - const CompleteEnumeratedType& x); - RTPS_DllAPI CompleteEnumeratedType& operator =( - CompleteEnumeratedType&& x); - - RTPS_DllAPI inline void enum_flags( - const EnumTypeFlag& _enum_flags) - { - m_enum_flags = _enum_flags; - } - - RTPS_DllAPI inline void enum_flags( - EnumTypeFlag&& _enum_flags) - { - m_enum_flags = std::move(_enum_flags); - } - - RTPS_DllAPI inline const EnumTypeFlag& enum_flags() const - { - return m_enum_flags; - } - - RTPS_DllAPI inline EnumTypeFlag& enum_flags() - { - return m_enum_flags; - } - - RTPS_DllAPI inline void header( - const CompleteEnumeratedHeader& _header) - { - m_header = _header; - } - - RTPS_DllAPI inline void header( - CompleteEnumeratedHeader&& _header) - { - m_header = std::move(_header); - } - - RTPS_DllAPI inline const CompleteEnumeratedHeader& header() const - { - return m_header; - } - - RTPS_DllAPI inline CompleteEnumeratedHeader& header() - { - return m_header; - } - - RTPS_DllAPI inline void literal_seq( - const CompleteEnumeratedLiteralSeq& _literal_seq) - { - m_literal_seq = _literal_seq; - } - - RTPS_DllAPI inline void literal_seq( - CompleteEnumeratedLiteralSeq&& _literal_seq) - { - m_literal_seq = std::move(_literal_seq); - } - - RTPS_DllAPI inline const CompleteEnumeratedLiteralSeq& literal_seq() const - { - return m_literal_seq; - } - - RTPS_DllAPI inline CompleteEnumeratedLiteralSeq& literal_seq() - { - return m_literal_seq; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteEnumeratedType::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const CompleteEnumeratedType& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteEnumeratedType::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteEnumeratedType::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const CompleteEnumeratedType& other) const; - - RTPS_DllAPI bool consistent( - const CompleteEnumeratedType& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - EnumTypeFlag m_enum_flags; - CompleteEnumeratedHeader m_header; - CompleteEnumeratedLiteralSeq m_literal_seq; -}; -// Enumerated type -/*struct MinimalEnumeratedType final{ - EnumTypeFlag enum_flags; // unused - MinimalEnumeratedHeader header; - MinimalEnumeratedLiteralSeq literal_seq; - };*/ -class MinimalEnumeratedType -{ -public: - - RTPS_DllAPI MinimalEnumeratedType(); - RTPS_DllAPI ~MinimalEnumeratedType(); - RTPS_DllAPI MinimalEnumeratedType( - const MinimalEnumeratedType& x); - RTPS_DllAPI MinimalEnumeratedType( - MinimalEnumeratedType&& x); - RTPS_DllAPI MinimalEnumeratedType& operator =( - const MinimalEnumeratedType& x); - RTPS_DllAPI MinimalEnumeratedType& operator =( - MinimalEnumeratedType&& x); - - RTPS_DllAPI inline void enum_flags( - const EnumTypeFlag& _enum_flags) - { - m_enum_flags = _enum_flags; - } - - RTPS_DllAPI inline void enum_flags( - EnumTypeFlag&& _enum_flags) - { - m_enum_flags = std::move(_enum_flags); - } - - RTPS_DllAPI inline const EnumTypeFlag& enum_flags() const - { - return m_enum_flags; - } - - RTPS_DllAPI inline EnumTypeFlag& enum_flags() - { - return m_enum_flags; - } - - RTPS_DllAPI inline void header( - const MinimalEnumeratedHeader& _header) - { - m_header = _header; - } - - RTPS_DllAPI inline void header( - MinimalEnumeratedHeader&& _header) - { - m_header = std::move(_header); - } - - RTPS_DllAPI inline const MinimalEnumeratedHeader& header() const - { - return m_header; - } - - RTPS_DllAPI inline MinimalEnumeratedHeader& header() - { - return m_header; - } - - RTPS_DllAPI inline void literal_seq( - const MinimalEnumeratedLiteralSeq& _literal_seq) - { - m_literal_seq = _literal_seq; - } - - RTPS_DllAPI inline void literal_seq( - MinimalEnumeratedLiteralSeq&& _literal_seq) - { - m_literal_seq = std::move(_literal_seq); - } - - RTPS_DllAPI inline const MinimalEnumeratedLiteralSeq& literal_seq() const - { - return m_literal_seq; - } - - RTPS_DllAPI inline MinimalEnumeratedLiteralSeq& literal_seq() - { - return m_literal_seq; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalEnumeratedType::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const MinimalEnumeratedType& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalEnumeratedType::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalEnumeratedType::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const MinimalEnumeratedType& other) const; - - RTPS_DllAPI bool consistent( - const MinimalEnumeratedType& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - EnumTypeFlag m_enum_flags; - MinimalEnumeratedHeader m_header; - MinimalEnumeratedLiteralSeq m_literal_seq; -}; - -// --- Bitmask: ------------------------------------------------------- -// Bit in a bit mask -/*struct CommonBitflag final{ - uint16_t position; - BitflagFlag flags; - };*/ -class CommonBitflag final -{ -public: - - RTPS_DllAPI CommonBitflag(); - RTPS_DllAPI ~CommonBitflag(); - RTPS_DllAPI CommonBitflag( - const CommonBitflag& x); - RTPS_DllAPI CommonBitflag( - CommonBitflag&& x); - RTPS_DllAPI CommonBitflag& operator =( - const CommonBitflag& x); - RTPS_DllAPI CommonBitflag& operator =( - CommonBitflag&& x); - - RTPS_DllAPI inline void position( - const uint16_t& _position) - { - m_position = _position; - } - - RTPS_DllAPI inline void position( - uint16_t&& _position) - { - m_position = std::move(_position); - } - - RTPS_DllAPI inline const uint16_t& position() const - { - return m_position; - } - - RTPS_DllAPI inline uint16_t& position() - { - return m_position; - } - - RTPS_DllAPI inline void flags( - const BitflagFlag& _flags) - { - m_flags = _flags; - } - - RTPS_DllAPI inline void flags( - BitflagFlag&& _flags) - { - m_flags = std::move(_flags); - } - - RTPS_DllAPI inline const BitflagFlag& flags() const - { - return m_flags; - } - - RTPS_DllAPI inline BitflagFlag& flags() - { - return m_flags; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CommonBitflag::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const CommonBitflag& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CommonBitflag::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CommonBitflag::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const CommonBitflag& other) const; - - RTPS_DllAPI bool consistent( - const CommonBitflag& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - uint16_t m_position; - BitflagFlag m_flags; -}; - -/*struct CompleteBitflag { - CommonBitflag common; - CompleteMemberDetail detail; - };*/ -class CompleteBitflag -{ -public: - - RTPS_DllAPI CompleteBitflag(); - RTPS_DllAPI ~CompleteBitflag(); - RTPS_DllAPI CompleteBitflag( - const CompleteBitflag& x); - RTPS_DllAPI CompleteBitflag( - CompleteBitflag&& x); - RTPS_DllAPI CompleteBitflag& operator =( - const CompleteBitflag& x); - RTPS_DllAPI CompleteBitflag& operator =( - CompleteBitflag&& x); - - RTPS_DllAPI inline void common( - const CommonBitflag& _common) - { - m_common = _common; - } - - RTPS_DllAPI inline void common( - CommonBitflag&& _common) - { - m_common = std::move(_common); - } - - RTPS_DllAPI inline const CommonBitflag& common() const - { - return m_common; - } - - RTPS_DllAPI inline CommonBitflag& common() - { - return m_common; - } - - RTPS_DllAPI inline void detail( - const CompleteMemberDetail& _detail) - { - m_detail = _detail; - } - - RTPS_DllAPI inline void detail( - CompleteMemberDetail&& _detail) - { - m_detail = std::move(_detail); - } - - RTPS_DllAPI inline const CompleteMemberDetail& detail() const - { - return m_detail; - } - - RTPS_DllAPI inline CompleteMemberDetail& detail() - { - return m_detail; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteBitflag::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const CompleteBitflag& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteBitflag::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteBitflag::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const CompleteBitflag& other) const; - - RTPS_DllAPI bool consistent( - const CompleteBitflag& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - CommonBitflag m_common; - CompleteMemberDetail m_detail; -}; -// Ordered by Bitflag.position -typedef std::vector CompleteBitflagSeq; -/*struct MinimalBitflag { - CommonBitflag common; - MinimalMemberDetail detail; - };*/ -class MinimalBitflag -{ -public: - - RTPS_DllAPI MinimalBitflag(); - RTPS_DllAPI ~MinimalBitflag(); - RTPS_DllAPI MinimalBitflag( - const MinimalBitflag& x); - RTPS_DllAPI MinimalBitflag( - MinimalBitflag&& x); - RTPS_DllAPI MinimalBitflag& operator =( - const MinimalBitflag& x); - RTPS_DllAPI MinimalBitflag& operator =( - MinimalBitflag&& x); - - RTPS_DllAPI inline void common( - const CommonBitflag& _common) - { - m_common = _common; - } - - RTPS_DllAPI inline void common( - CommonBitflag&& _common) - { - m_common = std::move(_common); - } - - RTPS_DllAPI inline const CommonBitflag& common() const - { - return m_common; - } - - RTPS_DllAPI inline CommonBitflag& common() - { - return m_common; - } - - RTPS_DllAPI inline void detail( - const MinimalMemberDetail& _detail) - { - m_detail = _detail; - } - - RTPS_DllAPI inline void detail( - MinimalMemberDetail&& _detail) - { - m_detail = std::move(_detail); - } - - RTPS_DllAPI inline const MinimalMemberDetail& detail() const - { - return m_detail; - } - - RTPS_DllAPI inline MinimalMemberDetail& detail() - { - return m_detail; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalBitflag::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const MinimalBitflag& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalBitflag::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalBitflag::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const MinimalBitflag& other) const; - - RTPS_DllAPI bool consistent( - const MinimalBitflag& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - CommonBitflag m_common; - MinimalMemberDetail m_detail; -}; - -// Ordered by Bitflag.position -typedef std::vector MinimalBitflagSeq; - -/*struct CommonBitmaskHeader final{ - BitBound bit_bound; - };*/ -class CommonBitmaskHeader final -{ -public: - - RTPS_DllAPI CommonBitmaskHeader(); - RTPS_DllAPI ~CommonBitmaskHeader(); - RTPS_DllAPI CommonBitmaskHeader( - const CommonBitmaskHeader& x); - RTPS_DllAPI CommonBitmaskHeader( - CommonBitmaskHeader&& x); - RTPS_DllAPI CommonBitmaskHeader& operator =( - const CommonBitmaskHeader& x); - RTPS_DllAPI CommonBitmaskHeader& operator =( - CommonBitmaskHeader&& x); - - RTPS_DllAPI inline void bit_bound( - const BitBound& _bit_bound) - { - m_bit_bound = _bit_bound; - } - - RTPS_DllAPI inline void bit_bound( - BitBound&& _bit_bound) - { - m_bit_bound = std::move(_bit_bound); - } - - RTPS_DllAPI inline const BitBound& bit_bound() const - { - return m_bit_bound; - } - - RTPS_DllAPI inline BitBound& bit_bound() - { - return m_bit_bound; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CommonBitmaskHeader::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const CommonBitmaskHeader& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CommonBitmaskHeader::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CommonBitmaskHeader::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const CommonBitmaskHeader& other) const; - - RTPS_DllAPI bool consistent( - const CommonBitmaskHeader& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - BitBound m_bit_bound; -}; -typedef CompleteEnumeratedHeader CompleteBitmaskHeader; - -typedef MinimalEnumeratedHeader MinimalBitmaskHeader; -/*struct CompleteBitmaskType { - BitmaskTypeFlag bitmask_flags; // unused - CompleteBitmaskHeader header; - CompleteBitflagSeq flag_seq; - };*/ -class CompleteBitmaskType -{ -public: - - RTPS_DllAPI CompleteBitmaskType(); - RTPS_DllAPI ~CompleteBitmaskType(); - RTPS_DllAPI CompleteBitmaskType( - const CompleteBitmaskType& x); - RTPS_DllAPI CompleteBitmaskType( - CompleteBitmaskType&& x); - RTPS_DllAPI CompleteBitmaskType& operator =( - const CompleteBitmaskType& x); - RTPS_DllAPI CompleteBitmaskType& operator =( - CompleteBitmaskType&& x); - - RTPS_DllAPI inline void bitmask_flags( - const BitmaskTypeFlag& _bitmask_flags) - { - m_bitmask_flags = _bitmask_flags; - } - - RTPS_DllAPI inline void bitmask_flags( - BitmaskTypeFlag&& _bitmask_flags) - { - m_bitmask_flags = std::move(_bitmask_flags); - } - - RTPS_DllAPI inline const BitmaskTypeFlag& bitmask_flags() const - { - return m_bitmask_flags; - } - - RTPS_DllAPI inline BitmaskTypeFlag& bitmask_flags() - { - return m_bitmask_flags; - } - - RTPS_DllAPI inline void header( - const CompleteBitmaskHeader& _header) - { - m_header = _header; - } - - RTPS_DllAPI inline void header( - CompleteBitmaskHeader&& _header) - { - m_header = std::move(_header); - } - - RTPS_DllAPI inline const CompleteBitmaskHeader& header() const - { - return m_header; - } - - RTPS_DllAPI inline CompleteBitmaskHeader& header() - { - return m_header; - } - - RTPS_DllAPI inline void flag_seq( - const CompleteBitflagSeq& _flag_seq) - { - m_flag_seq = _flag_seq; - } - - RTPS_DllAPI inline void flag_seq( - CompleteBitflagSeq&& _flag_seq) - { - m_flag_seq = std::move(_flag_seq); - } - - RTPS_DllAPI inline const CompleteBitflagSeq& flag_seq() const - { - return m_flag_seq; - } - - RTPS_DllAPI inline CompleteBitflagSeq& flag_seq() - { - return m_flag_seq; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteBitmaskType::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const CompleteBitmaskType& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteBitmaskType::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteBitmaskType::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const CompleteBitmaskType& other) const; - - RTPS_DllAPI bool consistent( - const CompleteBitmaskType& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - BitmaskTypeFlag m_bitmask_flags; - CompleteBitmaskHeader m_header; - CompleteBitflagSeq m_flag_seq; -}; - -/*struct MinimalBitmaskType { - BitmaskTypeFlag bitmask_flags; // unused - MinimalBitmaskHeader header; - MinimalBitflagSeq flag_seq; - };*/ -class MinimalBitmaskType -{ -public: - - RTPS_DllAPI MinimalBitmaskType(); - RTPS_DllAPI ~MinimalBitmaskType(); - RTPS_DllAPI MinimalBitmaskType( - const MinimalBitmaskType& x); - RTPS_DllAPI MinimalBitmaskType( - MinimalBitmaskType&& x); - RTPS_DllAPI MinimalBitmaskType& operator =( - const MinimalBitmaskType& x); - RTPS_DllAPI MinimalBitmaskType& operator =( - MinimalBitmaskType&& x); - - RTPS_DllAPI inline void bitmask_flags( - const BitmaskTypeFlag& _bitmask_flags) - { - m_bitmask_flags = _bitmask_flags; - } - - RTPS_DllAPI inline void bitmask_flags( - BitmaskTypeFlag&& _bitmask_flags) - { - m_bitmask_flags = std::move(_bitmask_flags); - } - - RTPS_DllAPI inline const BitmaskTypeFlag& bitmask_flags() const - { - return m_bitmask_flags; - } - - RTPS_DllAPI inline BitmaskTypeFlag& bitmask_flags() - { - return m_bitmask_flags; - } - - RTPS_DllAPI inline void header( - const MinimalBitmaskHeader& _header) - { - m_header = _header; - } - - RTPS_DllAPI inline void header( - MinimalBitmaskHeader&& _header) - { - m_header = std::move(_header); - } - - RTPS_DllAPI inline const MinimalBitmaskHeader& header() const - { - return m_header; - } - - RTPS_DllAPI inline MinimalBitmaskHeader& header() - { - return m_header; - } - - RTPS_DllAPI inline void flag_seq( - const MinimalBitflagSeq& _flag_seq) - { - m_flag_seq = _flag_seq; - } - - RTPS_DllAPI inline void flag_seq( - MinimalBitflagSeq&& _flag_seq) - { - m_flag_seq = std::move(_flag_seq); - } - - RTPS_DllAPI inline const MinimalBitflagSeq& flag_seq() const - { - return m_flag_seq; - } - - RTPS_DllAPI inline MinimalBitflagSeq& flag_seq() - { - return m_flag_seq; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalBitmaskType::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const MinimalBitmaskType& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalBitmaskType::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalBitmaskType::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const MinimalBitmaskType& other) const; - - RTPS_DllAPI bool consistent( - const MinimalBitmaskType& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - BitmaskTypeFlag m_bitmask_flags; - MinimalBitmaskHeader m_header; - MinimalBitflagSeq m_flag_seq; -}; - -// --- Bitset: --------------------------------------------------------- -/*struct CommonBitfield final{ - uint16_t position; - BitsetMemberFlag flags; - octet bitcount; - TypeKind holder_type; // Must be primitive integer type - };*/ -class CommonBitfield final -{ -public: - - RTPS_DllAPI CommonBitfield(); - RTPS_DllAPI ~CommonBitfield(); - RTPS_DllAPI CommonBitfield( - const CommonBitfield& x); - RTPS_DllAPI CommonBitfield( - CommonBitfield&& x); - RTPS_DllAPI CommonBitfield& operator =( - const CommonBitfield& x); - RTPS_DllAPI CommonBitfield& operator =( - CommonBitfield&& x); - - RTPS_DllAPI inline void position( - const uint16_t& _position) - { - m_position = _position; - } - - RTPS_DllAPI inline void position( - uint16_t&& _position) - { - m_position = std::move(_position); - } - - RTPS_DllAPI inline const uint16_t& position() const - { - return m_position; - } - - RTPS_DllAPI inline uint16_t& position() - { - return m_position; - } - - RTPS_DllAPI inline void flags( - const BitsetMemberFlag& _flags) - { - m_flags = _flags; - } - - RTPS_DllAPI inline void flags( - BitsetMemberFlag&& _flags) - { - m_flags = std::move(_flags); - } - - RTPS_DllAPI inline const BitsetMemberFlag& flags() const - { - return m_flags; - } - - RTPS_DllAPI inline BitsetMemberFlag& flags() - { - return m_flags; - } - - RTPS_DllAPI inline void bitcount( - const octet& _bitcount) - { - m_bitcount = _bitcount; - } - - RTPS_DllAPI inline void bitcount( - octet&& _bitcount) - { - m_bitcount = std::move(_bitcount); - } - - RTPS_DllAPI inline const octet& bitcount() const - { - return m_bitcount; - } - - RTPS_DllAPI inline octet& bitcount() - { - return m_bitcount; - } - - RTPS_DllAPI inline void holder_type( - const TypeKind& _holder_type) - { - m_holder_type = _holder_type; - } - - RTPS_DllAPI inline void holder_type( - TypeKind&& _holder_type) - { - m_holder_type = std::move(_holder_type); - } - - RTPS_DllAPI inline const TypeKind& holder_type() const - { - return m_holder_type; - } - - RTPS_DllAPI inline TypeKind& holder_type() - { - return m_holder_type; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CommonBitfield::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const CommonBitfield& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CommonBitfield::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CommonBitfield::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const CommonBitfield& other) const; - - RTPS_DllAPI bool consistent( - const CommonBitfield& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - uint16_t m_position; - BitsetMemberFlag m_flags; - octet m_bitcount; - TypeKind m_holder_type; -}; - -/*struct CompleteBitfield { - CommonBitfield common; - CompleteMemberDetail detail; - };*/ -class CompleteBitfield -{ -public: - - RTPS_DllAPI CompleteBitfield(); - RTPS_DllAPI ~CompleteBitfield(); - RTPS_DllAPI CompleteBitfield( - const CompleteBitfield& x); - RTPS_DllAPI CompleteBitfield( - CompleteBitfield&& x); - RTPS_DllAPI CompleteBitfield& operator =( - const CompleteBitfield& x); - RTPS_DllAPI CompleteBitfield& operator =( - CompleteBitfield&& x); - - RTPS_DllAPI inline void common( - const CommonBitfield& _common) - { - m_common = _common; - } - - RTPS_DllAPI inline void common( - CommonBitfield&& _common) - { - m_common = std::move(_common); - } - - RTPS_DllAPI inline const CommonBitfield& common() const - { - return m_common; - } - - RTPS_DllAPI inline CommonBitfield& common() - { - return m_common; - } - - RTPS_DllAPI inline void detail( - const CompleteMemberDetail& _detail) - { - m_detail = _detail; - } - - RTPS_DllAPI inline void detail( - CompleteMemberDetail&& _detail) - { - m_detail = std::move(_detail); - } - - RTPS_DllAPI inline const CompleteMemberDetail& detail() const - { - return m_detail; - } - - RTPS_DllAPI inline CompleteMemberDetail& detail() - { - return m_detail; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteBitfield::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const CompleteBitfield& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteBitfield::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteBitfielddeserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const CompleteBitfield& other) const; - - RTPS_DllAPI bool consistent( - const CompleteBitfield& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - CommonBitfield m_common; - CompleteMemberDetail m_detail; -}; -// Ordered by Bitfield.position -typedef std::vector CompleteBitfieldSeq; -/*struct MinimalBitfield { - CommonBitfield common; - NameHash name_hash; - };*/ -class MinimalBitfield -{ -public: - - RTPS_DllAPI MinimalBitfield(); - RTPS_DllAPI ~MinimalBitfield(); - RTPS_DllAPI MinimalBitfield( - const MinimalBitfield& x); - RTPS_DllAPI MinimalBitfield( - MinimalBitfield&& x); - RTPS_DllAPI MinimalBitfield& operator =( - const MinimalBitfield& x); - RTPS_DllAPI MinimalBitfield& operator =( - MinimalBitfield&& x); - - RTPS_DllAPI inline void name_hash( - const NameHash& _name_hash) - { - m_name_hash = _name_hash; - } - - RTPS_DllAPI inline void name_hash( - NameHash&& _name_hash) - { - m_name_hash = std::move(_name_hash); - } - - RTPS_DllAPI inline const NameHash& name_hash() const - { - return m_name_hash; - } - - RTPS_DllAPI inline NameHash& name_hash() - { - return m_name_hash; - } - - RTPS_DllAPI inline void common( - const CommonBitfield& _common) - { - m_common = _common; - } - - RTPS_DllAPI inline void common( - CommonBitfield&& _common) - { - m_common = std::move(_common); - } - - RTPS_DllAPI inline const CommonBitfield& common() const - { - return m_common; - } - - RTPS_DllAPI inline CommonBitfield& common() - { - return m_common; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalBitfield::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const MinimalBitfield& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalBitfield::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalBitfield::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const MinimalBitfield& other) const; - - RTPS_DllAPI bool consistent( - const MinimalBitfield& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - CommonBitfield m_common; - NameHash m_name_hash; -}; -// Ordered by Bitfield.position -typedef std::vector MinimalBitfieldSeq; -/*struct CompleteBitsetHeader { - CompleteTypeDetail detail; - };*/ -class CompleteBitsetHeader -{ -public: - - RTPS_DllAPI CompleteBitsetHeader(); - RTPS_DllAPI ~CompleteBitsetHeader(); - RTPS_DllAPI CompleteBitsetHeader( - const CompleteBitsetHeader& x); - RTPS_DllAPI CompleteBitsetHeader( - CompleteBitsetHeader&& x); - RTPS_DllAPI CompleteBitsetHeader& operator =( - const CompleteBitsetHeader& x); - RTPS_DllAPI CompleteBitsetHeader& operator =( - CompleteBitsetHeader&& x); - - RTPS_DllAPI inline void base_type( - const TypeIdentifier& _base_type) - { - m_base_type = _base_type; - } - - RTPS_DllAPI inline void base_type( - TypeIdentifier&& _base_type) - { - m_base_type = std::move(_base_type); - } - - RTPS_DllAPI inline const TypeIdentifier& base_type() const - { - return m_base_type; - } - - RTPS_DllAPI inline TypeIdentifier& base_type() - { - return m_base_type; - } - - RTPS_DllAPI inline void detail( - const CompleteTypeDetail& _detail) - { - m_detail = _detail; - } - - RTPS_DllAPI inline void detail( - CompleteTypeDetail&& _detail) - { - m_detail = std::move(_detail); - } - - RTPS_DllAPI inline const CompleteTypeDetail& detail() const - { - return m_detail; - } - - RTPS_DllAPI inline CompleteTypeDetail& detail() - { - return m_detail; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteBitsetHeader::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const CompleteBitsetHeader& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteBitsetHeader::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteBitsetHeader::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const CompleteBitsetHeader& other) const; - - RTPS_DllAPI bool consistent( - const CompleteBitsetHeader& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - TypeIdentifier m_base_type; - CompleteTypeDetail m_detail; -}; - -/*struct MinimalBitsetHeader { - // Empty. Available for future extension - };*/ -class MinimalBitsetHeader -{ -public: - - RTPS_DllAPI MinimalBitsetHeader(); - RTPS_DllAPI ~MinimalBitsetHeader(); - RTPS_DllAPI MinimalBitsetHeader( - const MinimalBitsetHeader& x); - RTPS_DllAPI MinimalBitsetHeader( - MinimalBitsetHeader&& x); - RTPS_DllAPI MinimalBitsetHeader& operator =( - const MinimalBitsetHeader& x); - RTPS_DllAPI MinimalBitsetHeader& operator =( - MinimalBitsetHeader&& x); - - RTPS_DllAPI inline void base_type( - const TypeIdentifier& _base_type) - { - m_base_type = _base_type; - } - - RTPS_DllAPI inline void base_type( - TypeIdentifier&& _base_type) - { - m_base_type = std::move(_base_type); - } - - RTPS_DllAPI inline const TypeIdentifier& base_type() const - { - return m_base_type; - } - - RTPS_DllAPI inline TypeIdentifier& base_type() - { - return m_base_type; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalBitsetHeader::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const MinimalBitsetHeader& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalBitsetHeader::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalBitsetHeader::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const MinimalBitsetHeader& other) const; - - RTPS_DllAPI bool consistent( - const MinimalBitsetHeader& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - TypeIdentifier m_base_type; -}; -/*struct CompleteBitsetType { - BitsetTypeFlag bitset_flags; // unused - CompleteBitsetHeader header; - CompleteBitfieldSeq field_seq; - };*/ -class CompleteBitsetType -{ -public: - - RTPS_DllAPI CompleteBitsetType(); - RTPS_DllAPI ~CompleteBitsetType(); - RTPS_DllAPI CompleteBitsetType( - const CompleteBitsetType& x); - RTPS_DllAPI CompleteBitsetType( - CompleteBitsetType&& x); - RTPS_DllAPI CompleteBitsetType& operator =( - const CompleteBitsetType& x); - RTPS_DllAPI CompleteBitsetType& operator =( - CompleteBitsetType&& x); - - RTPS_DllAPI inline void bitset_flags( - const BitsetTypeFlag& _bitset_flags) - { - m_bitset_flags = _bitset_flags; - } - - RTPS_DllAPI inline void bitset_flags( - BitsetTypeFlag&& _bitset_flags) - { - m_bitset_flags = std::move(_bitset_flags); - } - - RTPS_DllAPI inline const BitsetTypeFlag& bitset_flags() const - { - return m_bitset_flags; - } - - RTPS_DllAPI inline BitsetTypeFlag& bitset_flags() - { - return m_bitset_flags; - } - - RTPS_DllAPI inline void header( - const CompleteBitsetHeader& _header) - { - m_header = _header; - } - - RTPS_DllAPI inline void header( - CompleteBitsetHeader&& _header) - { - m_header = std::move(_header); - } - - RTPS_DllAPI inline const CompleteBitsetHeader& header() const - { - return m_header; - } - - RTPS_DllAPI inline CompleteBitsetHeader& header() - { - return m_header; - } - - RTPS_DllAPI inline void field_seq( - const CompleteBitfieldSeq& _field_seq) - { - m_field_seq = _field_seq; - } - - RTPS_DllAPI inline void field_seq( - CompleteBitfieldSeq&& _field_seq) - { - m_field_seq = std::move(_field_seq); - } - - RTPS_DllAPI inline const CompleteBitfieldSeq& field_seq() const - { - return m_field_seq; - } - - RTPS_DllAPI inline CompleteBitfieldSeq& field_seq() - { - return m_field_seq; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteBitsetType::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const CompleteBitsetType& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteBitsetType::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteBitsetType::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const CompleteBitsetType& other) const; - - RTPS_DllAPI bool consistent( - const CompleteBitsetType& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - BitsetTypeFlag m_bitset_flags; - CompleteBitsetHeader m_header; - CompleteBitfieldSeq m_field_seq; -}; - -/*struct MinimalBitsetType { - BitsetTypeFlag bitset_flags; // unused - MinimalBitsetHeader header; - MinimalBitfieldSeq field_seq; - };*/ -class MinimalBitsetType -{ -public: - - RTPS_DllAPI MinimalBitsetType(); - RTPS_DllAPI ~MinimalBitsetType(); - RTPS_DllAPI MinimalBitsetType( - const MinimalBitsetType& x); - RTPS_DllAPI MinimalBitsetType( - MinimalBitsetType&& x); - RTPS_DllAPI MinimalBitsetType& operator =( - const MinimalBitsetType& x); - RTPS_DllAPI MinimalBitsetType& operator =( - MinimalBitsetType&& x); - - RTPS_DllAPI inline void bitset_flags( - const BitsetTypeFlag& _bitset_flags) - { - m_bitset_flags = _bitset_flags; - } - - RTPS_DllAPI inline void bitset_flags( - BitsetTypeFlag&& _bitset_flags) - { - m_bitset_flags = std::move(_bitset_flags); - } - - RTPS_DllAPI inline const BitsetTypeFlag& bitset_flags() const - { - return m_bitset_flags; - } - - RTPS_DllAPI inline BitsetTypeFlag& bitset_flags() - { - return m_bitset_flags; - } - - RTPS_DllAPI inline void header( - const MinimalBitsetHeader& _header) - { - m_header = _header; - } - - RTPS_DllAPI inline void header( - MinimalBitsetHeader&& _header) - { - m_header = std::move(_header); - } - - RTPS_DllAPI inline const MinimalBitsetHeader& header() const - { - return m_header; - } - - RTPS_DllAPI inline MinimalBitsetHeader& header() - { - return m_header; - } - - RTPS_DllAPI inline void field_seq( - const MinimalBitfieldSeq& _field_seq) - { - m_field_seq = _field_seq; - } - - RTPS_DllAPI inline void field_seq( - MinimalBitfieldSeq&& _field_seq) - { - m_field_seq = std::move(_field_seq); - } - - RTPS_DllAPI inline const MinimalBitfieldSeq& field_seq() const - { - return m_field_seq; - } - - RTPS_DllAPI inline MinimalBitfieldSeq& field_seq() - { - return m_field_seq; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalBitsetType::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const MinimalBitsetType& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalBitsetType::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalBitsetType::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const MinimalBitsetType& other) const; - - RTPS_DllAPI bool consistent( - const MinimalBitsetType& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - BitsetTypeFlag m_bitset_flags; - MinimalBitsetHeader m_header; - MinimalBitfieldSeq m_field_seq; -}; - -// --- Type Object: -------------------------------------------------- -// The types associated with each case selection must have extensibility -// kind APPENDABLE or MUTABLE so that they can be extended in the future - -/*struct CompleteExtendedType { - // Empty. Available for future extension - };*/ -class CompleteExtendedType -{ -public: - - RTPS_DllAPI CompleteExtendedType(); - RTPS_DllAPI ~CompleteExtendedType(); - RTPS_DllAPI CompleteExtendedType( - const CompleteExtendedType& x); - RTPS_DllAPI CompleteExtendedType( - CompleteExtendedType&& x); - RTPS_DllAPI CompleteExtendedType& operator =( - const CompleteExtendedType& x); - RTPS_DllAPI CompleteExtendedType& operator =( - CompleteExtendedType&& x); - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteExtendedType::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const CompleteExtendedType& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteExtendedType::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteExtendedType::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const CompleteExtendedType&) const - { - return true; - } - - RTPS_DllAPI bool consistent( - const CompleteExtendedType& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - -}; - -/*struct MinimalExtendedType { - // Empty. Available for future extension - };*/ -class MinimalExtendedType -{ -public: - - RTPS_DllAPI MinimalExtendedType(); - RTPS_DllAPI ~MinimalExtendedType(); - RTPS_DllAPI MinimalExtendedType( - const MinimalExtendedType& x); - RTPS_DllAPI MinimalExtendedType( - MinimalExtendedType&& x); - RTPS_DllAPI MinimalExtendedType& operator =( - const MinimalExtendedType& x); - RTPS_DllAPI MinimalExtendedType& operator =( - MinimalExtendedType&& x); - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalExtendedType::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const MinimalExtendedType& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalExtendedType::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalExtendedType::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const MinimalExtendedType&) const - { - return true; - } - - RTPS_DllAPI bool consistent( - const MinimalExtendedType& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - -}; - -class CompleteTypeObject final -{ -public: - - RTPS_DllAPI CompleteTypeObject(); - RTPS_DllAPI ~CompleteTypeObject(); - RTPS_DllAPI CompleteTypeObject( - const CompleteTypeObject& x); - RTPS_DllAPI CompleteTypeObject( - CompleteTypeObject&& x); - RTPS_DllAPI CompleteTypeObject& operator =( - const CompleteTypeObject& x); - RTPS_DllAPI CompleteTypeObject& operator =( - CompleteTypeObject&& x); - RTPS_DllAPI void _d( - octet __d); - RTPS_DllAPI octet _d() const; - RTPS_DllAPI octet& _d(); - - RTPS_DllAPI void alias_type( - CompleteAliasType _alias_type); - RTPS_DllAPI const CompleteAliasType& alias_type() const; - RTPS_DllAPI CompleteAliasType& alias_type(); - - RTPS_DllAPI void annotation_type( - CompleteAnnotationType _annotation_type); - RTPS_DllAPI const CompleteAnnotationType& annotation_type() const; - RTPS_DllAPI CompleteAnnotationType& annotation_type(); - - RTPS_DllAPI void struct_type( - CompleteStructType _struct_type); - RTPS_DllAPI const CompleteStructType& struct_type() const; - RTPS_DllAPI CompleteStructType& struct_type(); - - RTPS_DllAPI void union_type( - CompleteUnionType _union_type); - RTPS_DllAPI const CompleteUnionType& union_type() const; - RTPS_DllAPI CompleteUnionType& union_type(); - - RTPS_DllAPI void bitset_type( - CompleteBitsetType _bitset_type); - RTPS_DllAPI const CompleteBitsetType& bitset_type() const; - RTPS_DllAPI CompleteBitsetType& bitset_type(); - - RTPS_DllAPI void sequence_type( - CompleteSequenceType _sequence_type); - RTPS_DllAPI const CompleteSequenceType& sequence_type() const; - RTPS_DllAPI CompleteSequenceType& sequence_type(); - - RTPS_DllAPI void array_type( - CompleteArrayType _array_type); - RTPS_DllAPI const CompleteArrayType& array_type() const; - RTPS_DllAPI CompleteArrayType& array_type(); - - RTPS_DllAPI void map_type( - CompleteMapType _map_type); - RTPS_DllAPI const CompleteMapType& map_type() const; - RTPS_DllAPI CompleteMapType& map_type(); - - RTPS_DllAPI void enumerated_type( - CompleteEnumeratedType _enumerated_type); - RTPS_DllAPI const CompleteEnumeratedType& enumerated_type() const; - RTPS_DllAPI CompleteEnumeratedType& enumerated_type(); - - RTPS_DllAPI void bitmask_type( - CompleteBitmaskType _bitmask_type); - RTPS_DllAPI const CompleteBitmaskType& bitmask_type() const; - RTPS_DllAPI CompleteBitmaskType& bitmask_type(); - - RTPS_DllAPI void extended_type( - CompleteExtendedType _extended_type); - RTPS_DllAPI const CompleteExtendedType& extended_type() const; - RTPS_DllAPI CompleteExtendedType& extended_type(); - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteTypeObject::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const CompleteTypeObject& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteTypeObject::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::CompleteTypeObject::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const CompleteTypeObject& other) const; - - RTPS_DllAPI bool consistent( - const CompleteTypeObject& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - octet m__d; - - CompleteAliasType m_alias_type; - CompleteAnnotationType m_annotation_type; - CompleteStructType m_struct_type; - CompleteUnionType m_union_type; - CompleteBitsetType m_bitset_type; - CompleteSequenceType m_sequence_type; - CompleteArrayType m_array_type; - CompleteMapType m_map_type; - CompleteEnumeratedType m_enumerated_type; - CompleteBitmaskType m_bitmask_type; - CompleteExtendedType m_extended_type; -}; - -class MinimalTypeObject final -{ -public: - - RTPS_DllAPI MinimalTypeObject(); - RTPS_DllAPI ~MinimalTypeObject(); - RTPS_DllAPI MinimalTypeObject( - const MinimalTypeObject& x); - RTPS_DllAPI MinimalTypeObject( - MinimalTypeObject&& x); - RTPS_DllAPI MinimalTypeObject& operator =( - const MinimalTypeObject& x); - RTPS_DllAPI MinimalTypeObject& operator =( - MinimalTypeObject&& x); - RTPS_DllAPI void _d( - octet __d); - RTPS_DllAPI octet _d() const; - RTPS_DllAPI octet& _d(); - - RTPS_DllAPI void alias_type( - MinimalAliasType _alias_type); - RTPS_DllAPI const MinimalAliasType& alias_type() const; - RTPS_DllAPI MinimalAliasType& alias_type(); - - RTPS_DllAPI void annotation_type( - MinimalAnnotationType _annotation_type); - RTPS_DllAPI const MinimalAnnotationType& annotation_type() const; - RTPS_DllAPI MinimalAnnotationType& annotation_type(); - - RTPS_DllAPI void struct_type( - MinimalStructType _struct_type); - RTPS_DllAPI const MinimalStructType& struct_type() const; - RTPS_DllAPI MinimalStructType& struct_type(); - - RTPS_DllAPI void union_type( - MinimalUnionType _union_type); - RTPS_DllAPI const MinimalUnionType& union_type() const; - RTPS_DllAPI MinimalUnionType& union_type(); - - RTPS_DllAPI void bitset_type( - MinimalBitsetType _bitset_type); - RTPS_DllAPI const MinimalBitsetType& bitset_type() const; - RTPS_DllAPI MinimalBitsetType& bitset_type(); - - RTPS_DllAPI void sequence_type( - MinimalSequenceType _sequence_type); - RTPS_DllAPI const MinimalSequenceType& sequence_type() const; - RTPS_DllAPI MinimalSequenceType& sequence_type(); - - RTPS_DllAPI void array_type( - MinimalArrayType _array_type); - RTPS_DllAPI const MinimalArrayType& array_type() const; - RTPS_DllAPI MinimalArrayType& array_type(); - - RTPS_DllAPI void map_type( - MinimalMapType _map_type); - RTPS_DllAPI const MinimalMapType& map_type() const; - RTPS_DllAPI MinimalMapType& map_type(); - - RTPS_DllAPI void enumerated_type( - MinimalEnumeratedType _enumerated_type); - RTPS_DllAPI const MinimalEnumeratedType& enumerated_type() const; - RTPS_DllAPI MinimalEnumeratedType& enumerated_type(); - - RTPS_DllAPI void bitmask_type( - MinimalBitmaskType _bitmask_type); - RTPS_DllAPI const MinimalBitmaskType& bitmask_type() const; - RTPS_DllAPI MinimalBitmaskType& bitmask_type(); - - RTPS_DllAPI void extended_type( - MinimalExtendedType _extended_type); - RTPS_DllAPI const MinimalExtendedType& extended_type() const; - RTPS_DllAPI MinimalExtendedType& extended_type(); - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalTypeObject::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const MinimalTypeObject& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalTypeObject::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::MinimalTypeObject::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const MinimalTypeObject& other) const; - - RTPS_DllAPI bool consistent( - const MinimalTypeObject& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - octet m__d; - - MinimalAliasType m_alias_type; - MinimalAnnotationType m_annotation_type; - MinimalStructType m_struct_type; - MinimalUnionType m_union_type; - MinimalBitsetType m_bitset_type; - MinimalSequenceType m_sequence_type; - MinimalArrayType m_array_type; - MinimalMapType m_map_type; - MinimalEnumeratedType m_enumerated_type; - MinimalBitmaskType m_bitmask_type; - MinimalExtendedType m_extended_type; -}; -class TypeObject -{ -public: - - /*! - * @brief Default constructor. - */ - RTPS_DllAPI TypeObject(); - - /*! - * @brief Default destructor. - */ - RTPS_DllAPI ~TypeObject(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object TypeObject that will be copied. - */ - RTPS_DllAPI TypeObject( - const TypeObject& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object TypeObject that will be copied. - */ - RTPS_DllAPI TypeObject( - TypeObject&& x); - - /*! - * @brief Copy assignment. - * @param x Reference to the object TypeObject that will be copied. - */ - RTPS_DllAPI TypeObject& operator =( - const TypeObject& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object TypeObject that will be copied. - */ - RTPS_DllAPI TypeObject& operator =( - TypeObject&& x); - - /*! - * @brief This function sets the discriminator value. - * @param __d New value for the discriminator. - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the new value doesn't correspond to the selected union member. - */ - RTPS_DllAPI void _d( - uint8_t __d); - - /*! - * @brief This function returns the value of the discriminator. - * @return Value of the discriminator - */ - RTPS_DllAPI uint8_t _d() const; - - /*! - * @brief This function returns a reference to the discriminator. - * @return Reference to the discriminator. - */ - RTPS_DllAPI uint8_t& _d(); - - /*! - * @brief This function copies the value in member complete - * @param _complete New value to be copied in member complete - */ - RTPS_DllAPI void complete( - const CompleteTypeObject& _complete); - - /*! - * @brief This function moves the value in member complete - * @param _complete New value to be moved in member complete - */ - RTPS_DllAPI void complete( - CompleteTypeObject&& _complete); - - /*! - * @brief This function returns a constant reference to member complete - * @return Constant reference to member complete - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI const CompleteTypeObject& complete() const; - - /*! - * @brief This function returns a reference to member complete - * @return Reference to member complete - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI CompleteTypeObject& complete(); - /*! - * @brief This function copies the value in member minimal - * @param _minimal New value to be copied in member minimal - */ - RTPS_DllAPI void minimal( - const MinimalTypeObject& _minimal); - - /*! - * @brief This function moves the value in member minimal - * @param _minimal New value to be moved in member minimal - */ - RTPS_DllAPI void minimal( - MinimalTypeObject&& _minimal); - - /*! - * @brief This function returns a constant reference to member minimal - * @return Constant reference to member minimal - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI const MinimalTypeObject& minimal() const; - - /*! - * @brief This function returns a reference to member minimal - * @return Reference to member minimal - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - RTPS_DllAPI MinimalTypeObject& minimal(); - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::TypeObject::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const TypeObject& data, - size_t current_alignment = 0); - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::TypeObject::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::TypeObject::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - - RTPS_DllAPI bool operator ==( - const TypeObject& other) const; - - /*! - * @brief This function check type consistency enforcement with the given TypeObject x. - * @param x TypeObject to check if can be assigned to the current instance. - * @param consistency fastdds::dds::TypeConsistencyEnforcementQoSPolicy to apply. - */ - RTPS_DllAPI bool consistent( - const TypeObject& x, - const fastdds::dds::TypeConsistencyEnforcementQosPolicy& consistency) const; - -private: - - uint8_t m__d; - - CompleteTypeObject m_complete; - MinimalTypeObject m_minimal; -}; - -typedef std::vector TypeObjectSeq; - -// Set of TypeObjects representing a strong component: Equivalence class -// for the Strong Connectivity relationship (mutual reachability between -// types). -// Ordered by fully qualified typename lexicographic order -typedef TypeObjectSeq StronglyConnectedComponent; - -/*struct TypeIdentifierTypeObjectPair final { - TypeIdentifier type_identifier; - TypeObject type_object; - };*/ -class TypeIdentifierTypeObjectPair final -{ -public: - - RTPS_DllAPI TypeIdentifierTypeObjectPair(); - RTPS_DllAPI ~TypeIdentifierTypeObjectPair(); - RTPS_DllAPI TypeIdentifierTypeObjectPair( - const TypeIdentifierTypeObjectPair& x); - RTPS_DllAPI TypeIdentifierTypeObjectPair( - TypeIdentifierTypeObjectPair&& x); - RTPS_DllAPI TypeIdentifierTypeObjectPair& operator =( - const TypeIdentifierTypeObjectPair& x); - RTPS_DllAPI TypeIdentifierTypeObjectPair& operator =( - TypeIdentifierTypeObjectPair&& x); - - RTPS_DllAPI inline void type_identifier( - const TypeIdentifier& _type_identifier) - { - m_type_identifier = _type_identifier; - } - - RTPS_DllAPI inline void type_identifier( - TypeIdentifier&& _type_identifier) - { - m_type_identifier = std::move(_type_identifier); - } - - RTPS_DllAPI inline const TypeIdentifier& type_identifier() const - { - return m_type_identifier; - } - - RTPS_DllAPI inline TypeIdentifier& type_identifier() - { - return m_type_identifier; - } - - RTPS_DllAPI inline void type_object( - const TypeObject& _type_object) - { - m_type_object = _type_object; - } - - RTPS_DllAPI inline void type_object( - TypeObject&& _type_object) - { - m_type_object = std::move(_type_object); - } - - RTPS_DllAPI inline const TypeObject& type_object() const - { - return m_type_object; - } - - RTPS_DllAPI inline TypeObject& type_object() - { - return m_type_object; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::TypeIdentifierTypeObjectPair::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const TypeIdentifierTypeObjectPair& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::TypeIdentifierTypeObjectPair::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::TypeIdentifierTypeObjectPair::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - -private: - - TypeIdentifier m_type_identifier; - TypeObject m_type_object; -}; -typedef std::vector TypeIdentifierTypeObjectPairSeq; - -/*struct TypeIdentifierPair final { - TypeIdentifier type_identifier1; - TypeIdentifier type_identifier2; - };*/ -class TypeIdentifierPair final -{ -public: - - RTPS_DllAPI TypeIdentifierPair(); - RTPS_DllAPI ~TypeIdentifierPair(); - RTPS_DllAPI TypeIdentifierPair( - const TypeIdentifierPair& x); - RTPS_DllAPI TypeIdentifierPair( - TypeIdentifierPair&& x); - RTPS_DllAPI TypeIdentifierPair& operator =( - const TypeIdentifierPair& x); - RTPS_DllAPI TypeIdentifierPair& operator =( - TypeIdentifierPair&& x); - - RTPS_DllAPI inline void type_identifier1( - const TypeIdentifier& _type_identifier1) - { - m_type_identifier1 = _type_identifier1; - } - - RTPS_DllAPI inline void type_identifier1( - TypeIdentifier&& _type_identifier1) - { - m_type_identifier1 = std::move(_type_identifier1); - } - - RTPS_DllAPI inline const TypeIdentifier& type_identifier1() const - { - return m_type_identifier1; - } - - RTPS_DllAPI inline TypeIdentifier& type_identifier1() - { - return m_type_identifier1; - } - - RTPS_DllAPI inline void type_identifier2( - const TypeIdentifier& _type_identifier2) - { - m_type_identifier2 = _type_identifier2; - } - - RTPS_DllAPI inline void type_identifier2( - TypeIdentifier&& _type_identifier2) - { - m_type_identifier2 = std::move(_type_identifier2); - } - - RTPS_DllAPI inline const TypeIdentifier& type_identifier2() const - { - return m_type_identifier2; - } - - RTPS_DllAPI inline TypeIdentifier& type_identifier2() - { - return m_type_identifier2; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::TypeIdentifierPair::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const TypeIdentifierPair& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::TypeIdentifierPair::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::TypeIdentifierPair::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - -private: - - TypeIdentifier m_type_identifier1; - TypeIdentifier m_type_identifier2; -}; - -typedef std::vector TypeIdentifierPairSeq; -/*struct TypeIdentifierWithSize { - TypeIdentifier type_id; - uint32_t typeobject_serialized_size; - };*/ -class TypeIdentifierWithSize -{ -public: - - RTPS_DllAPI TypeIdentifierWithSize(); - RTPS_DllAPI ~TypeIdentifierWithSize(); - RTPS_DllAPI TypeIdentifierWithSize( - const TypeIdentifierWithSize& x); - RTPS_DllAPI TypeIdentifierWithSize( - TypeIdentifierWithSize&& x); - RTPS_DllAPI TypeIdentifierWithSize& operator =( - const TypeIdentifierWithSize& x); - RTPS_DllAPI TypeIdentifierWithSize& operator =( - TypeIdentifierWithSize&& x); - - RTPS_DllAPI inline void type_id( - const TypeIdentifier& _type_id) - { - m_type_id = _type_id; - } - - RTPS_DllAPI inline void type_id( - TypeIdentifier&& _type_id) - { - m_type_id = std::move(_type_id); - } - - RTPS_DllAPI inline const TypeIdentifier& type_id() const - { - return m_type_id; - } - - RTPS_DllAPI inline TypeIdentifier& type_id() - { - return m_type_id; - } - - RTPS_DllAPI inline void typeobject_serialized_size( - const uint32_t& _typeobject_serialized_size) - { - m_typeobject_serialized_size = _typeobject_serialized_size; - } - - RTPS_DllAPI inline void typeobject_serialized_size( - uint32_t&& _typeobject_serialized_size) - { - m_typeobject_serialized_size = std::move(_typeobject_serialized_size); - } - - RTPS_DllAPI inline const uint32_t& typeobject_serialized_size() const - { - return m_typeobject_serialized_size; - } - - RTPS_DllAPI inline uint32_t& typeobject_serialized_size() - { - return m_typeobject_serialized_size; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::TypeIdentifierWithSize::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const TypeIdentifierWithSize& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::TypeIdentifierWithSize::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::TypeIdentifierWithSize::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - -private: - - TypeIdentifier m_type_id; - uint32_t m_typeobject_serialized_size; -}; - -typedef std::vector TypeIdentifierWithSizeSeq; - -/*struct TypeIdentifierWithDependencies { - TypeIdentifierWithSize typeid_with_size; - // The total additional types related to minimal_type - int32_t dependent_typeid_count; - TypeIdentifierWithSizeSeq dependent_typeids; - };*/ -class TypeIdentifierWithDependencies -{ -public: - - RTPS_DllAPI TypeIdentifierWithDependencies(); - RTPS_DllAPI ~TypeIdentifierWithDependencies(); - RTPS_DllAPI TypeIdentifierWithDependencies( - const TypeIdentifierWithDependencies& x); - RTPS_DllAPI TypeIdentifierWithDependencies( - TypeIdentifierWithDependencies&& x); - RTPS_DllAPI TypeIdentifierWithDependencies& operator =( - const TypeIdentifierWithDependencies& x); - RTPS_DllAPI TypeIdentifierWithDependencies& operator =( - TypeIdentifierWithDependencies&& x); - - RTPS_DllAPI inline void typeid_with_size( - const TypeIdentifierWithSize& _typeid_with_size) - { - m_typeid_with_size = _typeid_with_size; - } - - RTPS_DllAPI inline void typeid_with_size( - TypeIdentifierWithSize&& _typeid_with_size) - { - m_typeid_with_size = std::move(_typeid_with_size); - } - - RTPS_DllAPI inline const TypeIdentifierWithSize& typeid_with_size() const - { - return m_typeid_with_size; - } - - RTPS_DllAPI inline TypeIdentifierWithSize& typeid_with_size() - { - return m_typeid_with_size; - } - - RTPS_DllAPI inline void dependent_typeid_count( - const int32_t& _dependent_typeid_count) - { - m_dependent_typeid_count = _dependent_typeid_count; - } - - RTPS_DllAPI inline void dependent_typeid_count( - int32_t&& _dependent_typeid_count) - { - m_dependent_typeid_count = std::move(_dependent_typeid_count); - } - - RTPS_DllAPI inline const int32_t& dependent_typeid_count() const - { - return m_dependent_typeid_count; - } - - RTPS_DllAPI inline int32_t& dependent_typeid_count() - { - return m_dependent_typeid_count; - } - - RTPS_DllAPI inline void dependent_typeids( - const TypeIdentifierWithSizeSeq& _dependent_typeids) - { - m_dependent_typeids = _dependent_typeids; - } - - RTPS_DllAPI inline void dependent_typeids( - TypeIdentifierWithSizeSeq&& _dependent_typeids) - { - m_dependent_typeids = std::move(_dependent_typeids); - } - - RTPS_DllAPI inline const TypeIdentifierWithSizeSeq& dependent_typeids() const - { - return m_dependent_typeids; - } - - RTPS_DllAPI inline TypeIdentifierWithSizeSeq& dependent_typeids() - { - return m_dependent_typeids; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::TypeIdentifierWithDependencies::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const TypeIdentifierWithDependencies& data, - size_t current_alignment = 0); - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::TypeIdentifierWithDependencies::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::TypeIdentifierWithDependencies::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - -private: - - TypeIdentifierWithSize m_typeid_with_size; - int32_t m_dependent_typeid_count; - TypeIdentifierWithSizeSeq m_dependent_typeids; -}; - -typedef std::vector TypeIdentifierWithDependenciesSeq; -//////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -// This appears in the builtin DDS topics PublicationBuiltinTopicData -// and SubscriptionBuiltinTopicData - -/*struct TypeInformation { - TypeIdentifierWithDependencies minimal; // @id{0x1001} - TypeIdentifierWithDependencies complete; // @id{0x1002} - };*/ -class TypeInformation -{ -public: - - RTPS_DllAPI TypeInformation(); - RTPS_DllAPI ~TypeInformation(); - RTPS_DllAPI TypeInformation( - const TypeInformation& x); - RTPS_DllAPI TypeInformation( - TypeInformation&& x); - RTPS_DllAPI TypeInformation& operator =( - const TypeInformation& x); - RTPS_DllAPI TypeInformation& operator =( - TypeInformation&& x); - - RTPS_DllAPI inline void minimal( - const TypeIdentifierWithDependencies& _minimal) - { - m_minimal = _minimal; - } - - RTPS_DllAPI inline void minimal( - TypeIdentifierWithDependencies&& _minimal) - { - m_minimal = std::move(_minimal); - } - - RTPS_DllAPI inline const TypeIdentifierWithDependencies& minimal() const - { - return m_minimal; - } - - RTPS_DllAPI inline TypeIdentifierWithDependencies& minimal() - { - return m_minimal; - } - - RTPS_DllAPI inline void complete( - const TypeIdentifierWithDependencies& _complete) - { - m_complete = _complete; - } - - RTPS_DllAPI inline void complete( - TypeIdentifierWithDependencies&& _complete) - { - m_complete = std::move(_complete); - } - - RTPS_DllAPI inline const TypeIdentifierWithDependencies& complete() const - { - return m_complete; - } - - RTPS_DllAPI inline TypeIdentifierWithDependencies& complete() - { - return m_complete; - } - -#ifndef DOXYGEN_SHOULD_SKIP_THIS - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::TypeInformation::getCdrSerializedSize()", - "In favor of version using eprosima::fastcdr::calculate_serialized_size.") - RTPS_DllAPI static size_t getCdrSerializedSize( - const TypeInformation& data, - size_t current_alignment = 0); - - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::TypeInformation::serialize()", - "In favor of version using eprosima::fastcdr::serialize.") - RTPS_DllAPI void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - FASTDDS_SER_METHOD_DEPRECATED(3, "eprosima::fastrtps::types::TypeInformation::deserialize()", - "In favor of version using eprosima::fastcdr::deserialize.") - RTPS_DllAPI void deserialize( - eprosima::fastcdr::Cdr& cdr); -#endif // DOXYGEN_SHOULD_SKIP_THIS - -private: - - TypeIdentifierWithDependencies m_minimal; - TypeIdentifierWithDependencies m_complete; -}; - -typedef std::vector TypeInformationSeq; -///////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -} // namespace types -} // namespace fastrtps -} // namespace eprosima - -#endif // TYPES_TYPE_OBJECT_H diff --git a/include/fastrtps/types/TypeObjectFactory.h b/include/fastrtps/types/TypeObjectFactory.h deleted file mode 100644 index 33fd87ba9c4..00000000000 --- a/include/fastrtps/types/TypeObjectFactory.h +++ /dev/null @@ -1,274 +0,0 @@ -// Copyright 2018 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -#ifndef TYPE_OBJECT_TYPE_FACTORY_H -#define TYPE_OBJECT_TYPE_FACTORY_H - -#include -#include -#include -#include -#include - -namespace eprosima { -namespace fastrtps { -namespace types { - -class TypeObjectFactory -{ -private: - mutable std::recursive_mutex m_MutexIdentifiers; - mutable std::recursive_mutex m_MutexObjects; - mutable std::recursive_mutex m_MutexInformations; - -protected: - TypeObjectFactory(); - mutable std::map identifiers_; // Basic, builtin and EK_MINIMAL - std::map complete_identifiers_; // Only EK_COMPLETE - std::map objects_; // EK_MINIMAL - std::map complete_objects_; // EK_COMPLETE - mutable std::vector identifiers_created_; - mutable std::map informations_; - mutable std::vector informations_created_; - std::map aliases_; // Aliases - - DynamicType_ptr build_dynamic_type( - TypeDescriptor& descriptor, - const TypeObject* object, - const DynamicType_ptr annotation_member_type = DynamicType_ptr(nullptr)) const; - - const TypeIdentifier* try_get_complete( - const TypeIdentifier* identifier) const; - - const TypeIdentifier* get_stored_type_identifier( - const TypeIdentifier* identifier) const; - - std::string generate_name_and_store_type_identifier( - const TypeIdentifier* identifier) const; - - void nullify_all_entries( - const TypeIdentifier* identifier); - - void create_builtin_annotations(); - - void apply_type_annotations( - DynamicTypeBuilder_ptr& type_builder, - const AppliedAnnotationSeq& annotations) const; - - void apply_member_annotations( - DynamicTypeBuilder_ptr& parent_type_builder, - MemberId member_id, - const AppliedAnnotationSeq& annotations) const; - - std::string get_key_from_hash( - const DynamicType_ptr annotation_descriptor_type, - const NameHash& hash) const; - - /** - * @brief Fills the TypeInformation provided with the minimal TypeIdentifiers and its minimal dependencies. - * @param info - * @param ident - */ - void fill_minimal_information( - TypeInformation* info, - const TypeIdentifier* ident) const; - - /** - * @brief Fills the TypeInformation provided with the complete TypeIdentifiers and its complete dependencies - * if possible, or minimal ones in other case. - * @param info - * @param ident - */ - void fill_complete_information( - TypeInformation* info, - const TypeIdentifier* ident) const; - - /** - * @brief Auxiliar function to fill minimal dependencies. - * @param info - * @param identifier - */ - void fill_minimal_dependant_types( - TypeInformation* info, - const TypeIdentifier* identifier) const; - - /** - * @brief Auxiliar function to fill complete dependencies. - * @param info - * @param identifier - */ - void fill_complete_dependant_types( - TypeInformation* info, - const TypeIdentifier* identifier) const; - - /** - * @brief Auxiliar function to fill minimal information with complete dependencies. - * @param info - * @param identifier - */ - void fill_complete_minimal_dependant_types( - TypeInformation* info, - const TypeIdentifier* identifier) const; - -public: - RTPS_DllAPI static TypeObjectFactory* get_instance(); - - RTPS_DllAPI static ReturnCode_t delete_instance(); - - ~TypeObjectFactory(); - - /** - * @brief get_type_information Retrieves the TypeInformation of the named type. - * @param type_name - * @return - */ - RTPS_DllAPI const TypeInformation* get_type_information( - const std::string &type_name) const; - - /** - * @brief get_type_information Retrieves the TypeInformation of the given TypeIdentifier. - * @param identifier - * @return - */ - RTPS_DllAPI TypeInformation* get_type_information( - const TypeIdentifier* identifier) const; - - RTPS_DllAPI const TypeObject* get_type_object( - const std::string& type_name, - bool complete = false) const; - - RTPS_DllAPI const TypeObject* get_type_object( - const TypeIdentifier* identifier) const; - - RTPS_DllAPI TypeKind get_type_kind( - const std::string& type_name) const; - - RTPS_DllAPI std::string get_type_name( - const TypeKind kind) const; - - RTPS_DllAPI std::string get_type_name( - const TypeIdentifier* identifier) const; - - RTPS_DllAPI const TypeIdentifier* get_primitive_type_identifier( - TypeKind kind) const; - - RTPS_DllAPI const TypeIdentifier* get_type_identifier( - const std::string& type_name, - bool complete = false) const; - - RTPS_DllAPI const TypeIdentifier* get_type_identifier_trying_complete( - const std::string& type_name) const; - - RTPS_DllAPI const TypeIdentifier* get_string_identifier( - uint32_t bound, - bool wide = false); - - RTPS_DllAPI const TypeIdentifier* get_sequence_identifier( - const std::string& type_name, - uint32_t bound, - bool complete = false); - - RTPS_DllAPI const TypeIdentifier* get_array_identifier( - const std::string& type_name, - const std::vector &bound, - bool complete = false); - - RTPS_DllAPI const TypeIdentifier* get_map_identifier( - const std::string& key_type_name, - const std::string& value_type_name, - uint32_t bound, - bool complete = false); - - RTPS_DllAPI DynamicType_ptr build_dynamic_type( - const std::string& name, - const TypeIdentifier* identifier, - const TypeObject* object = nullptr) const; - - RTPS_DllAPI bool is_type_identifier_complete( - const TypeIdentifier* identifier) const; - - RTPS_DllAPI void add_type_identifier( - const std::string& type_name, - const TypeIdentifier* identifier); - - RTPS_DllAPI void add_type_object( - const std::string& type_name, - const TypeIdentifier* identifier, - const TypeObject* object); - - RTPS_DllAPI inline void add_alias( - const std::string& alias_name, - const std::string& target_type) - { - std::unique_lock scoped(m_MutexIdentifiers); - aliases_.emplace(std::pair(alias_name, target_type)); - } - - /** - * @brief Returns a TypeIdentifierWithSizeSeq object filled with the dependencies of the - * given identifiers. If continuation_point isn't empty, then it will skip the first - * (max_size * continuation_point) dependencies. - * @param identifiers - * @param in_continuation_point - * @param out_continuation_point - * @param max_size - * @return - */ - RTPS_DllAPI TypeIdentifierWithSizeSeq typelookup_get_type_dependencies( - const TypeIdentifierSeq& identifiers, - const OctetSeq& in_continuation_point, - OctetSeq& out_continuation_point, - size_t max_size) const; - - /** - * @brief Fills the given object with the complete version of the given identifier. - * If the given identifier was MINIMAL, then it will return the stored COMPLETE identifier pointer. - * Otherwise, it will return the given identifier address (to make comparision trivial). - * @param identifier - * @param object - * @return - */ - RTPS_DllAPI const TypeIdentifier* typelookup_get_type( - const TypeIdentifier& identifier, - TypeObject& object) const; - - /** - * @brief Checks if a TypeIdentifier is already known by the factory. - * @param identifier - * @return - */ - RTPS_DllAPI bool typelookup_check_type_identifier( - const TypeIdentifier& identifier) const; - - /** - * @brief Retrieves the CompleteTypeObject from the given TypeInformation. - * If it doesn't exist, it returns nullptr. - * A user that received a TypeInformation from TypeLookupService that calls this method and returns nullptr, - * must iterate through the TypeInformation dependencies calling recursively to getTypeDependencies method in - * its participant (which will call the correspondent method in the TypeLookupService), retrieving the - * TypeObject correspondent and registering the type into the Factory with a name using the add_type_object method, - * for each COMPLETE TypeIdentifier received in this way until all the hierarchy is registered, and then, - * the user may call again this method that should return the TypeObject. - * @param information - * @return - */ - RTPS_DllAPI const TypeObject* typelookup_get_type_object_from_information( - const TypeInformation& information) const; -}; - -} // namespace types -} // namespace fastrtps -} // namespace eprosima - -#endif // TYPE_OBJECT_TYPE_FACTORY_H diff --git a/include/fastrtps/types/TypeObjectHashId.h b/include/fastrtps/types/TypeObjectHashId.h deleted file mode 100644 index 180acb70ae6..00000000000 --- a/include/fastrtps/types/TypeObjectHashId.h +++ /dev/null @@ -1,187 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file TypeObjectHashId.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool gen and modified manually. - */ - -#ifndef _TYPEOBJECTHASHID_H_ -#define _TYPEOBJECTHASHID_H_ - -#include -#include -#include -#include -#include - -namespace eprosima { -namespace fastcdr { -class Cdr; -} // namespace fastcdr -} // namespace eprosima - -// The types in this file shall be serialized with XCDR encoding version 2 -namespace eprosima { -namespace fastrtps { - -namespace types { - -// First 14 bytes of MD5 of the serialized TypeObject using XCDR -// version 2 with Little Endian encoding -typedef octet EquivalenceHash[14]; - -/*! - * @brief This class represents the union TypeObjectHashId defined by the user in the IDL file. - * @ingroup TYPES_MODULE - */ -class TypeObjectHashId -{ -public: - - /*! - * @brief Default constructor. - */ - TypeObjectHashId(); - - /*! - * @brief Default destructor. - */ - ~TypeObjectHashId(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object TypeObjectHashId that will be copied. - */ - TypeObjectHashId( - const TypeObjectHashId& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object TypeObjectHashId that will be copied. - */ - TypeObjectHashId( - TypeObjectHashId&& x); - - /*! - * @brief Copy assignment. - * @param x Reference to the object TypeObjectHashId that will be copied. - */ - TypeObjectHashId& operator =( - const TypeObjectHashId& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object TypeObjectHashId that will be copied. - */ - TypeObjectHashId& operator =( - TypeObjectHashId&& x); - - /*! - * @brief This function sets the discriminator value. - * @param __d New value for the discriminator. - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the new value doesn't correspond to the selected union member. - */ - void _d( - uint8_t __d); - - /*! - * @brief This function returns the value of the discriminator. - * @return Value of the discriminator - */ - uint8_t _d() const; - - /*! - * @brief This function returns a reference to the discriminator. - * @return Reference to the discriminator. - */ - uint8_t& _d(); - - /*! - * @brief This function copies the value in member hash - * @param _hash New value to be copied in member hash - */ - void hash( - const EquivalenceHash& _hash); - - /*! - * @brief This function moves the value in member hash - * @param _hash New value to be moved in member hash - */ - void hash( - EquivalenceHash&& _hash); - - /*! - * @brief This function returns a constant reference to member hash - * @return Constant reference to member hash - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - const EquivalenceHash& hash() const; - - /*! - * @brief This function returns a reference to member hash - * @return Reference to member hash - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - EquivalenceHash& hash(); - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - void deserialize( - eprosima::fastcdr::Cdr& cdr); - - /*! - * @brief This function returns the maximum serialized size of the Key of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - static size_t getKeyMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - -private: - - uint8_t m__d; - - EquivalenceHash m_hash; -}; - -} // namespace types -} // namespace fastrtps -} // namespace eprosima - -#endif // _TYPEOBJECTHASHID_H_ diff --git a/include/fastrtps/types/TypesBase.h b/include/fastrtps/types/TypesBase.h deleted file mode 100644 index c5242e17ad6..00000000000 --- a/include/fastrtps/types/TypesBase.h +++ /dev/null @@ -1,647 +0,0 @@ -// Copyright 2018 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -#ifndef TYPES_BASE_H -#define TYPES_BASE_H - -#include -#include -#include -#include -#include -#include -#include -#include - -#include - -namespace eprosima { -namespace fastdds { -namespace dds { -using DomainId_t = uint32_t; -} // dds -} // namespace fastdds - -namespace fastcdr { -class Cdr; -} // namespace fastcdr -namespace fastrtps { -namespace types { - -//! A special value indicating an unlimited quantity -constexpr uint32_t BOUND_UNLIMITED = 0; - -using eprosima::fastrtps::rtps::octet; - -using OctetSeq = std::vector; - -OctetSeq& operator ++( - OctetSeq&); - -OctetSeq operator ++( - OctetSeq&, - int); - -size_t to_size_t( - const OctetSeq&); - -const std::string CONST_TRUE = "true"; -const std::string CONST_FALSE = "false"; - -const std::string ANNOTATION_KEY_ID = "key"; -const std::string ANNOTATION_EPKEY_ID = "Key"; -const std::string ANNOTATION_TOPIC_ID = "Topic"; -const std::string ANNOTATION_EXTENSIBILITY_ID = "extensibility"; -const std::string ANNOTATION_FINAL_ID = "final"; -const std::string ANNOTATION_APPENDABLE_ID = "appendable"; -const std::string ANNOTATION_MUTABLE_ID = "mutable"; -const std::string ANNOTATION_NESTED_ID = "nested"; -const std::string ANNOTATION_OPTIONAL_ID = "optional"; -const std::string ANNOTATION_MUST_UNDERSTAND_ID = "must_understand"; -const std::string ANNOTATION_NON_SERIALIZED_ID = "non_serialized"; -const std::string ANNOTATION_BIT_BOUND_ID = "bit_bound"; -const std::string ANNOTATION_DEFAULT_ID = "default"; -const std::string ANNOTATION_DEFAULT_LITERAL_ID = "default_literal"; -const std::string ANNOTATION_VALUE_ID = "value"; -const std::string ANNOTATION_POSITION_ID = "position"; - -const std::string EXTENSIBILITY_FINAL = "FINAL"; -const std::string EXTENSIBILITY_APPENDABLE = "APPENDABLE"; -const std::string EXTENSIBILITY_MUTABLE = "MUTABLE"; - -const std::string TKNAME_BOOLEAN = "bool"; -const std::string TKNAME_INT16 = "int16_t"; -const std::string TKNAME_UINT16 = "uint16_t"; -const std::string TKNAME_INT32 = "int32_t"; -const std::string TKNAME_UINT32 = "uint32_t"; -const std::string TKNAME_INT64 = "int64_t"; -const std::string TKNAME_UINT64 = "uint64_t"; -const std::string TKNAME_CHAR8 = "char"; -const std::string TKNAME_BYTE = "octet"; -const std::string TKNAME_INT8 = "int8_t"; -const std::string TKNAME_UINT8 = "uint8_t"; -const std::string TKNAME_CHAR16 = "wchar"; -const std::string TKNAME_CHAR16T = "wchar_t"; -const std::string TKNAME_FLOAT32 = "float"; -const std::string TKNAME_FLOAT64 = "double"; -const std::string TKNAME_FLOAT128 = "longdouble"; - -const std::string TKNAME_STRING8 = "string"; -const std::string TKNAME_STRING16 = "wstring"; -const std::string TKNAME_ALIAS = "alias"; -const std::string TKNAME_ENUM = "enum"; -const std::string TKNAME_BITMASK = "bitmask"; -const std::string TKNAME_ANNOTATION = "annotation"; -const std::string TKNAME_STRUCTURE = "structure"; -const std::string TKNAME_UNION = "union"; -const std::string TKNAME_BITSET = "bitset"; -const std::string TKNAME_SEQUENCE = "sequence"; -const std::string TKNAME_ARRAY = "array"; -const std::string TKNAME_MAP = "map"; - -// ---------- Equivalence Kinds ------------------ -typedef octet EquivalenceKind; -const octet EK_MINIMAL = 0xF1; // 0x1111 0001 -const octet EK_COMPLETE = 0xF2; // 0x1111 0010 -const octet EK_BOTH = 0xF3; // 0x1111 0011 - -// ---------- TypeKinds (begin) ------------------ -typedef octet TypeKind; // Primitive TKs - -const octet TK_NONE = 0x00; -const octet TK_BOOLEAN = 0x01; -const octet TK_BYTE = 0x02; -const octet TK_INT16 = 0x03; -const octet TK_INT32 = 0x04; -const octet TK_INT64 = 0x05; -const octet TK_UINT16 = 0x06; -const octet TK_UINT32 = 0x07; -const octet TK_UINT64 = 0x08; -const octet TK_FLOAT32 = 0x09; -const octet TK_FLOAT64 = 0x0A; -const octet TK_FLOAT128 = 0x0B; -const octet TK_CHAR8 = 0x10; -const octet TK_CHAR16 = 0x11; - -// String TKs -const octet TK_STRING8 = 0x20; -const octet TK_STRING16 = 0x21; - - -// Constructed/Named types -const octet TK_ALIAS = 0x30; - -// Enumerated TKs -const octet TK_ENUM = 0x40; -const octet TK_BITMASK = 0x41; - -// Structured TKs -const octet TK_ANNOTATION = 0x50; -const octet TK_STRUCTURE = 0x51; -const octet TK_UNION = 0x52; -const octet TK_BITSET = 0x53; - -// Collection TKs -const octet TK_SEQUENCE = 0x60; -const octet TK_ARRAY = 0x61; -const octet TK_MAP = 0x62; - -// ---------- TypeKinds (end) ------------------ - -// The name of some element (e.g. type, type member, module) -// Valid characters are alphanumeric plus the "_" cannot start with digit - -const int32_t MEMBER_NAME_MAX_LENGTH = 256; -typedef std::string MemberName; - -// Qualified type name includes the name of containing modules -// using "::" as separator. No leading "::". E.g. "MyModule::MyType" -const int32_t TYPE_NAME_MAX_LENGTH = 256; -typedef std::string QualifiedTypeName; - -// Every type has an ID. Those of the primitive types are pre-defined. -typedef octet PrimitiveTypeId; - -// First 4 bytes of MD5 of of a member name converted to bytes -// using UTF-8 encoding and without a 'nul' terminator. -// Example: the member name "color" has NameHash {0x70, 0xDD, 0xA5, 0xDF} -typedef std::array NameHash; - -// Mask used to remove the flags that do no affect assignability -// Selects T1, T2, O, M, K, D -const uint16_t MemberFlagMinimalMask = 0x003f; - -/*! - * @brief This class represents the enumeration ReturnCode_t. - */ - -class RTPS_DllAPI ReturnCode_t -{ - uint32_t value_; - -public: - - enum ReturnCodeValue - { - RETCODE_OK = 0, - RETCODE_ERROR = 1, - RETCODE_UNSUPPORTED = 2, - RETCODE_BAD_PARAMETER = 3, - RETCODE_PRECONDITION_NOT_MET = 4, - RETCODE_OUT_OF_RESOURCES = 5, - RETCODE_NOT_ENABLED = 6, - RETCODE_IMMUTABLE_POLICY = 7, - RETCODE_INCONSISTENT_POLICY = 8, - RETCODE_ALREADY_DELETED = 9, - RETCODE_TIMEOUT = 10, - RETCODE_NO_DATA = 11, - RETCODE_ILLEGAL_OPERATION = 12, - RETCODE_NOT_ALLOWED_BY_SECURITY = 13 - }; - - ReturnCode_t() - : value_(RETCODE_OK) - { - } - - ReturnCode_t( - uint32_t e) - { - value_ = e; - } - - bool operator ==( - const ReturnCode_t& c) const - { - return value_ == c.value_; - } - - bool operator !=( - const ReturnCode_t& c) const - { - return value_ != c.value_; - } - - explicit operator bool() = delete; - - uint32_t operator ()() const - { - return value_; - } - - bool operator !() const - { - return value_ != 0; - } - -}; - -RTPS_DllAPI inline bool operator ==( - ReturnCode_t::ReturnCodeValue a, - const ReturnCode_t& b) -{ - return b.operator ==( - a); -} - -RTPS_DllAPI inline bool operator !=( - ReturnCode_t::ReturnCodeValue a, - const ReturnCode_t& b) -{ - return b.operator !=( - a); -} - -RTPS_DllAPI inline bool operator ==( - uint32_t a, - const ReturnCode_t& b) -{ - return b.operator ==( - a); -} - -RTPS_DllAPI inline bool operator !=( - uint32_t a, - const ReturnCode_t& b) -{ - return b.operator !=( - a); -} - -// TODO Remove this alias when Fast-RTPS reaches version 2 -using ResponseCode = ReturnCode_t; - -typedef uint32_t MemberId; -constexpr uint32_t MEMBER_ID_INVALID {0X0FFFFFFF}; -#define INDEX_INVALID UINT32_MAX - -const int32_t MAX_BITMASK_LENGTH = 64; -const int32_t MAX_ELEMENTS_COUNT = 100; -const int32_t MAX_STRING_LENGTH = 255; - -// Long Bound of a collection type -typedef uint32_t LBound; -typedef std::vector LBoundSeq; -const LBound INVALID_LBOUND = 0; - -// Short Bound of a collection type -typedef octet SBound; -typedef std::vector SBoundSeq; -const SBound INVALID_SBOUND = 0; - -// Auxiliar function to compare sequences (std::vector) -template -bool compareSequence( - const std::vector& a, - const std::vector& b) -{ - if (a.size() == b.size()) - { - auto aIt = a.begin(); - auto bIt = b.begin(); - while (aIt != a.end() && bIt != b.end()) - { - if (*aIt == *bIt) - { - ++aIt; - ++bIt; - } - else - { - return false; - } - } - return true; - } - return false; -} - -// Flags that apply to struct/union/collection/enum/bitmask/bitset -// members/elements and DO affect type assignability -// Depending on the flag it may not apply to members of all types - -// When not all, the applicable member types are listed -class MemberFlag -{ -private: - - std::bitset<16> m_MemberFlag; - -public: - - MemberFlag() - { - } - - MemberFlag( - const MemberFlag& x) - : m_MemberFlag(x.m_MemberFlag) - { - } - - MemberFlag( - MemberFlag&& x) - : m_MemberFlag(std::move(x.m_MemberFlag)) - { - } - - MemberFlag& operator =( - const MemberFlag& x) - { - m_MemberFlag = x.m_MemberFlag; - return *this; - } - - MemberFlag& operator =( - MemberFlag&& x) - { - m_MemberFlag = std::move(x.m_MemberFlag); - return *this; - } - - // T1 | 00 = INVALID, 01 = DISCARD - bool TRY_CONSTRUCT1() const - { - return m_MemberFlag.test(0); - } - - void TRY_CONSTRUCT1( - bool b) - { - b ? m_MemberFlag.set(0) : m_MemberFlag.reset(0); - } - - // T2 | 10 = USE_DEFAULT, 11 = TRIM - bool TRY_CONSTRUCT2() const - { - return m_MemberFlag.test(1); - } - - void TRY_CONSTRUCT2( - bool b) - { - b ? m_MemberFlag.set(1) : m_MemberFlag.reset(1); - } - - // X StructMember, UnionMember, - // CollectionElement - bool IS_EXTERNAL() const - { - return m_MemberFlag.test(2); - } - - void IS_EXTERNAL( - bool b) - { - b ? m_MemberFlag.set(2) : m_MemberFlag.reset(2); - } - - // O StructMember - bool IS_OPTIONAL() const - { - return m_MemberFlag.test(3); - } - - void IS_OPTIONAL( - bool b) - { - b ? m_MemberFlag.set(3) : m_MemberFlag.reset(3); - } - - // M StructMember - bool IS_MUST_UNDERSTAND() const - { - return m_MemberFlag.test(4); - } - - void IS_MUST_UNDERSTAND( - bool b) - { - b ? m_MemberFlag.set(4) : m_MemberFlag.reset(4); - } - - // K StructMember, UnionDiscriminator - bool IS_KEY() const - { - return m_MemberFlag.test(5); - } - - void IS_KEY( - bool b) - { - b ? m_MemberFlag.set(5) : m_MemberFlag.reset(5); - } - - // D UnionMember, EnumerationLiteral - bool IS_DEFAULT() const - { - return m_MemberFlag.test(6); - } - - void IS_DEFAULT( - bool b) - { - b ? m_MemberFlag.set(6) : m_MemberFlag.reset(6); - } - - bool operator ==( - const MemberFlag& other) const - { - return m_MemberFlag == other.m_MemberFlag; - } - - std::bitset<16> bitset() const - { - std::string str_value; - - str_value = m_MemberFlag.to_string() + str_value; - - return std::bitset<16>(str_value); - } - - void bitset( - const std::bitset<16>& bitset) - { - std::string str_value {bitset.to_string()}; - size_t base_diff {0}; - size_t last_post {std::string::npos}; - - base_diff += 16; - m_MemberFlag = std::bitset<16>(str_value.substr(str_value.length() - base_diff, last_post)); - } - -}; - -typedef MemberFlag CollectionElementFlag; // T1, T2, X -typedef MemberFlag StructMemberFlag; // T1, T2, O, M, K, X -typedef MemberFlag UnionMemberFlag; // T1, T2, D, X -typedef MemberFlag UnionDiscriminatorFlag; // T1, T2, K -typedef MemberFlag EnumeratedLiteralFlag; // D -typedef MemberFlag AnnotationParameterFlag; // Unused. No flags apply -typedef MemberFlag AliasMemberFlag; // Unused. No flags apply -typedef MemberFlag BitflagFlag; // Unused. No flags apply -typedef MemberFlag BitsetMemberFlag; // Unused. No flags apply - -// Flags that apply to type declarationa and DO affect assignability -// Depending on the flag it may not apply to all types -// When not all, the applicable types are listed -class TypeFlag -{ -private: - - std::bitset<16> m_TypeFlag; - -public: - - TypeFlag() - { - } - - TypeFlag( - const TypeFlag& x) - : m_TypeFlag(x.m_TypeFlag) - { - } - - TypeFlag( - TypeFlag&& x) - : m_TypeFlag(std::move(x.m_TypeFlag)) - { - } - - TypeFlag& operator =( - const TypeFlag& x) - { - m_TypeFlag = x.m_TypeFlag; - return *this; - } - - TypeFlag& operator =( - TypeFlag&& x) - { - m_TypeFlag = std::move(x.m_TypeFlag); - return *this; - } - - // F | - bool IS_FINAL() const - { - return m_TypeFlag.test(0); - } - - void IS_FINAL( - bool b) - { - b ? m_TypeFlag.set(0) : m_TypeFlag.reset(0); - } - - // A |- Struct, Union - bool IS_APPENDABLE() const - { - return m_TypeFlag.test(1); - } - - void IS_APPENDABLE( - bool b) - { - b ? m_TypeFlag.set(1) : m_TypeFlag.reset(1); - } - - // M | (exactly one flag) - bool IS_MUTABLE() const - { - return m_TypeFlag.test(2); - } - - void IS_MUTABLE( - bool b) - { - b ? m_TypeFlag.set(2) : m_TypeFlag.reset(2); - } - - // N Struct, Union - bool IS_NESTED() const - { - return m_TypeFlag.test(3); - } - - void IS_NESTED( - bool b) - { - b ? m_TypeFlag.set(3) : m_TypeFlag.reset(3); - } - - // H Struct - bool IS_AUTOID_HASH() const - { - return m_TypeFlag.test(4); - } - - void IS_AUTOID_HASH( - bool b) - { - b ? m_TypeFlag.set(4) : m_TypeFlag.reset(4); - } - - bool operator ==( - const TypeFlag& other) const - { - return m_TypeFlag == other.m_TypeFlag; - } - - std::bitset<16> bitset() const - { - std::string str_value; - - str_value = m_TypeFlag.to_string() + str_value; - - return std::bitset<16>(str_value); - } - - void bitset( - const std::bitset<16>& bitset) - { - std::string str_value {bitset.to_string()}; - size_t base_diff {0}; - size_t last_post {std::string::npos}; - - base_diff += 16; - m_TypeFlag = std::bitset<16>(str_value.substr(str_value.length() - base_diff, last_post)); - } - -}; - -typedef TypeFlag StructTypeFlag; // All flags apply -typedef TypeFlag UnionTypeFlag; // All flags apply -typedef TypeFlag CollectionTypeFlag; // Unused. No flags apply -typedef TypeFlag AnnotationTypeFlag; // Unused. No flags apply -typedef TypeFlag AliasTypeFlag; // Unused. No flags apply -typedef TypeFlag EnumTypeFlag; // Unused. No flags apply -typedef TypeFlag BitmaskTypeFlag; // Unused. No flags apply -typedef TypeFlag BitsetTypeFlag; // Unused. No flags apply - -// Mask used to remove the flags that do no affect assignability -const uint16_t TypeFlagMinimalMask = 0x0007; // Selects M, A, F - -// --- Annotation usage: ---------------------------------------------- - -// ID of a type member -const uint32_t ANNOTATION_STR_VALUE_MAX_LEN = 128; -const uint32_t ANNOTATION_OCTETSEC_VALUE_MAX_LEN = 128; - -} // namespace types -} // namespace fastrtps -} // namespace eprosima - -#endif // TYPES_BASE_H diff --git a/include/fastrtps/types/dds-builtin_types.idl b/include/fastrtps/types/dds-builtin_types.idl deleted file mode 100644 index bf373a2a7e0..00000000000 --- a/include/fastrtps/types/dds-builtin_types.idl +++ /dev/null @@ -1,137 +0,0 @@ -module DDS { - @extensibility(APPENDABLE) - struct _String { - string value; - }; - - interface StringDataWriter : DataWriter { - /* This interface shall instantiate the type FooDataWriter defined by - * the DDS specification where "Foo" is an unbounded string. - */ - }; - - interface StringDataReader : DataReader { - /* This interface shall instantiate the type FooDataReader defined by - * the DDS specification where "Foo" is an unbounded string. - */ - }; - - interface StringTypeSupport : TypeSupport { - /* This interface shall instantiate the type FooTypeSupport - * defined by the DDS specification where "Foo" is an unbounded - * string. - */ - }; - - @extensibility(APPENDABLE) - struct KeyedString { - @key string key; - string value; - }; - - typedef sequence KeyedStringSeq; - - interface KeyedStringDataWriter : DataWriter { - /* This interface shall instantiate the type FooDataWriter defined by - * the DDS specification where "Foo" is KeyedString. It also defines - * the operations below. - */ - InstanceHandle_t register_instance_w_key( in string key); - InstanceHandle_t register_instance_w_key_w_timestamp( in string key, in Time_t source_timestamp); - - ReturnCode_t unregister_instance_w_key( in string key); - ReturnCode_t unregister_instance_w_key_w_timestamp( in string key, in Time_t source_timestamp); - - ReturnCode_t write_string_w_key( in string key, in string str, in InstanceHandle_t handle); - ReturnCode_t write_string_w_key_w_timestamp( in string key, in string str, in InstanceHandle_t handle, in Time_t source_timestamp); - - ReturnCode_t dispose_w_key( in string key); - ReturnCode_t dispose_w_key_w_timestamp( in string key, in Time_t source_timestamp); - - ReturnCode_t get_key_value_w_key( inout string key, in InstanceHandle_t handle); - - InstanceHandle_t lookup_instance_w_key( in string key); - }; - - interface KeyedStringDataReader : DataReader { - /* This interface shall instantiate the type FooDataReader defined by - * the DDS specification where "Foo" is KeyedString. - */ - }; - - interface KeyedStringTypeSupport : TypeSupport { - /* This interface shall instantiate the type FooTypeSupport - * defined by the DDS specification where "Foo" is KeyedString. - */ - }; - - - @extensibility(APPENDABLE) - struct Bytes { - ByteSeq value; - }; - typedef sequence BytesSeq; - - interface BytesDataWriter : DataWriter { - /* This interface shall instantiate the type FooDataWriter defined by - * the DDS specification where "Foo" is an unbounded sequence of - * bytes (octets). It also defines the operations below. - */ - ReturnCode_t write_w_bytes( in ByteArray bytes, in long offset, in long length, in InstanceHandle_t handle); - ReturnCode_t write_w_bytes_w_timestamp( in ByteArray bytes, in long offset, in long length, in InstanceHandle_t handle, in Time_t source_timestamp); - }; - - interface BytesDataReader : DataReader { - /* This interface shall instantiate the type FooDataReader defined by - * the DDS specification where "Foo" is Bytes. - */ - }; - - interface BytesTypeSupport : TypeSupport { - /* This interface shall instantiate the type FooTypeSupport - * defined by the DDS specification where "Foo" is Bytes. - */ - }; - - - @extensibility(APPENDABLE) - struct KeyedBytes { - @key string key; - ByteSeq value; - }; - typedef sequence KeyedBytesSeq; - - interface KeyedBytesDataWriter : DataWriter { - /* This interface shall instantiate the type FooDataWriter defined by - * the DDS specification where "Foo" is KeyedBytes. - * It also defines the operations below. - */ - InstanceHandle_t register_instance_w_key( in string key); - InstanceHandle_t register_instance_w_key_w_timestamp( in string key, in Time_t source_timestamp); - - ReturnCode_t unregister_instance_w_key( in string key); - ReturnCode_t unregister_instance_w_key_w_timestamp( in string key, in Time_t source_timestamp); - - ReturnCode_t write_bytes_w_key( in string key, in ByteArray bytes, in long offset, in long length, in InstanceHandle_t handle); - ReturnCode_t write_bytes_w_key_w_timestamp( in string key, in ByteArray bytes, in long offset, in long length, in InstanceHandle_t handle, in Time_t source_timestamp); - - ReturnCode_t dispose_w_key( in string key); - ReturnCode_t dispose_w_key_w_timestamp( in string key, in Time_t source_timestamp); - - ReturnCode_t get_key_value_w_key( inout string key, in InstanceHandle_t handle); - - InstanceHandle_t lookup_instance_w_key( in string key); - }; - - interface KeyedBytesDataReader : DataReader { - /* This interface shall instantiate the type FooDataReader defined by - * the DDS specification where "Foo" is KeyedBytes. - */ - }; - - interface KeyedBytesTypeSupport : TypeSupport { - /* This interface shall instantiate the type FooTypeSupport - * defined by the DDS specification where "Foo" is KeyedBytes. - */ - }; -}; // end module DDS \ No newline at end of file diff --git a/include/fastrtps/types/dds-language_binding.idl b/include/fastrtps/types/dds-language_binding.idl deleted file mode 100644 index f8d7c1fbbb7..00000000000 --- a/include/fastrtps/types/dds-language_binding.idl +++ /dev/null @@ -1,267 +0,0 @@ -module DDS { - local interface DynamicType; - local interface DynamicTypeBuilder; - valuetype TypeDescriptor; - - typedef sequence IncludePathSeq; - - local interface DynamicTypeBuilderFactory { - /*static*/ DynamicTypeBuilderFactory get_instance(); - /*static*/ DDS::ReturnCode_t delete_instance(); - - DynamicType get_primitive_type(in TypeKind kind); - DynamicTypeBuilder create_type(in TypeDescriptor descriptor); - DynamicTypeBuilder create_type_copy(in DynamicType type); - DynamicTypeBuilder create_type_w_type_object(in TypeObject type_object); - DynamicTypeBuilder create_string_type(in unsigned long bound); - DynamicTypeBuilder create_wstring_type(in unsigned long bound); - DynamicTypeBuilder create_sequence_type(in DynamicType element_type, in unsigned long bound); - DynamicTypeBuilder create_array_type(in DynamicType element_type, in BoundSeq bound); - DynamicTypeBuilder create_map_type(in DynamicType key_element_type, in DynamicType element_type, in unsigned long bound); - DynamicTypeBuilder create_bitmask_type(in unsigned long bound); - DynamicTypeBuilder create_type_w_uri( in string document_url, in string type_name, in IncludePathSeq include_paths); - DynamicTypeBuilder create_type_w_document( in string document, in string type_name, in IncludePathSeq include_paths); - DDS::ReturnCode_t delete_type(in DynamicType type); - }; - - interface TypeSupport { - // ReturnCode_t register_type( - // in DomainParticipant domain, - // in string type_name); - // string get_type_name(); - - // DynamicType get_type(); - }; - - /* Implied IDL for type "Foo": - interface FooTypeSupport : DDS::TypeSupport { - DDS::ReturnCode_t register_type( in DDS::DomainParticipant participant, in string type_name); - string get_type_name(); - DynamicType get_type(); - Foo create_sample(in DynamicData src); - DynamicData create_dynamic_sample(in Foo src); - }; */ - - interface DynamicTypeSupport : TypeSupport { - /* This interface shall instantiate the type FooTypeSupport - * defined by the DDS specification where "Foo" is DynamicData. - */ - - /*static*/ DynamicTypeSupport create_type_support( in DynamicType type); - /*static*/ DDS::ReturnCode_t delete_type_support( in DynamicTypeSupport type_support); - - DDS::ReturnCode_t register_type( in DDS::DomainParticipant participant, in ObjectName type_name); - ObjectName get_type_name(); - }; - - typedef map Parameters; - - valuetype AnnotationDescriptor { - public DynamicType type; - - DDS::ReturnCode_t get_value( inout ObjectName value, in ObjectName key); - DDS::ReturnCode_t get_all_value( inout Parameters value); - DDS::ReturnCode_t set_value( in ObjectName key, in ObjectName value); - DDS::ReturnCode_t copy_from(in AnnotationDescriptor other); - boolean equals(in AnnotationDescriptor other); - boolean is_consistent(); - }; - - valuetype TypeDescriptor { - public TypeKind kind; - public ObjectName name; - public DynamicType base_type; - public DynamicType discriminator_type; - public BoundSeq bound; - @optional public DynamicType element_type; - @optional public DynamicType key_element_type; - - DDS::ReturnCode_t copy_from(in TypeDescriptor other); - boolean equals(in TypeDescriptor other); - boolean is_consistent(); - }; - - valuetype MemberDescriptor { - public ObjectName name; - public MemberId id; - public DynamicType type; - public string default_value; - public unsigned long index; - public UnionCaseLabelSeq label; - public boolean default_label; - - DDS::ReturnCode_t copy_from(in MemberDescriptor descriptor); - boolean equals(in MemberDescriptor descriptor); - boolean is_consistent(); - }; - - local interface DynamicTypeMember { - DDS::ReturnCode_t get_descriptor( inout MemberDescriptor descriptor); - - unsigned long get_annotation_count(); - DDS::ReturnCode_t get_annotation( inout AnnotationDescriptor descriptor, in unsigned long idx); - - boolean equals(in DynamicTypeMember other); - - MemberId get_id(); - ObjectName get_name(); - }; - - typedef map DynamicTypeMembersByName; - typedef map DynamicTypeMembersById; - - local interface DynamicTypeBuilder { - DDS::ReturnCode_t get_descriptor( inout TypeDescriptor descriptor); - - ObjectName get_name(); - TypeKind get_kind(); - - DDS::ReturnCode_t get_member_by_name( inout DynamicTypeMember member, in ObjectName name); - DDS::ReturnCode_t get_all_members_by_name( inout DynamicTypeMembersByName member); - - DDS::ReturnCode_t get_member( inout DynamicTypeMember member, in MemberId id); - DDS::ReturnCode_t get_all_members( inout DynamicTypeMembersById member); - - unsigned long get_annotation_count(); - DDS::ReturnCode_t get_annotation( inout AnnotationDescriptor descriptor, in unsigned long idx); - - boolean equals(in DynamicType other); - DDS::ReturnCode_t add_member(in MemberDescriptor descriptor); - DDS::ReturnCode_t apply_annotation( in AnnotationDescriptor descriptor); - - DynamicType build(); - }; - - local interface DynamicType { - DDS::ReturnCode_t get_descriptor( inout TypeDescriptor descriptor); - - ObjectName get_name(); - TypeKind get_kind(); - - DDS::ReturnCode_t get_member_by_name( inout DynamicTypeMember member, in ObjectName name); - DDS::ReturnCode_t get_all_members_by_name( inout DynamicTypeMembersByName member); - - DDS::ReturnCode_t get_member( inout DynamicTypeMember member, in MemberId id); - DDS::ReturnCode_t get_all_members( inout DynamicTypeMembersById member); - - unsigned long get_annotation_count(); - DDS::ReturnCode_t get_annotation( inout AnnotationDescriptor descriptor, in unsigned long idx); - - boolean equals(in DynamicType other); - }; - - local interface DynamicData; - - local interface DynamicDataFactory { - /*static*/ DynamicDataFactory get_instance(); - /*static*/ DDS::ReturnCode_t delete_instance(); - - DynamicData create_data(); - DDS::ReturnCode_t delete_data(in DynamicData data); - }; - - typedef sequence Int32Seq; - typedef sequence UInt32Seq; - typedef sequence Int16Seq; - typedef sequence UInt16Seq; - typedef sequence Int64Seq; - typedef sequence UInt64Seq; - typedef sequence Float32Seq; - typedef sequence Float64Seq; - typedef sequence Float128Seq; - typedef sequence CharSeq; - typedef sequence WcharSeq; - typedef sequence BooleanSeq; - typedef sequence ByteSeq; - - // typedef sequence StringSeq; - typedef sequence WstringSeq; - - local interface DynamicData { - readonly attribute DynamicType type; - - DDS::ReturnCode_t get_descriptor( inout MemberDescriptor value, in MemberId id); - DDS::ReturnCode_t set_descriptor( in MemberId id, in MemberDescriptor value); - - boolean equals(in DynamicData other); - - MemberId get_member_id_by_name(in ObjectName name); - MemberId get_member_id_at_index(in unsigned long index); - - unsigned long get_item_count(); - - DDS::ReturnCode_t clear_all_values(); - DDS::ReturnCode_t clear_nonkey_values(); - DDS::ReturnCode_t clear_value(in MemberId id); - - DynamicData loan_value(in MemberId id); - DDS::ReturnCode_t return_loaned_value(in DynamicData value); - - DynamicData clone(); - - DDS::ReturnCode_t get_int32_value( inout long value, in MemberId id); - DDS::ReturnCode_t set_int32_value( in MemberId id, in long value); - DDS::ReturnCode_t get_uint32_value( inout unsigned long value, in MemberId id); - DDS::ReturnCode_t set_uint32_value( in MemberId id, in unsigned long value); - DDS::ReturnCode_t get_int16_value( inout short value, in MemberId id); - DDS::ReturnCode_t set_int16_value( in MemberId id, in short value); - DDS::ReturnCode_t get_uint16_value( inout unsigned short value, in MemberId id); - DDS::ReturnCode_t set_uint16_value( in MemberId id, in unsigned short value); - DDS::ReturnCode_t get_int64_value( inout long long value, in MemberId id); - DDS::ReturnCode_t set_int64_value( in MemberId id, in long long value); - DDS::ReturnCode_t get_uint64_value( inout unsigned long long value, in MemberId id); - DDS::ReturnCode_t set_uint64_value( in MemberId id, in unsigned long long value); - DDS::ReturnCode_t get_float32_value( inout float value, in MemberId id); - DDS::ReturnCode_t set_float32_value( in MemberId id, in float value); - DDS::ReturnCode_t get_float64_value( inout double value, in MemberId id); - DDS::ReturnCode_t set_float64_value( in MemberId id, in double value); - DDS::ReturnCode_t get_float128_value( inout long double value, in MemberId id); - DDS::ReturnCode_t set_float128_value( in MemberId id, in long double value); - DDS::ReturnCode_t get_char8_value( inout char value, in MemberId id); - DDS::ReturnCode_t set_char8_value( in MemberId id, in char value); - DDS::ReturnCode_t get_char16_value( inout wchar value, in MemberId id); - DDS::ReturnCode_t set_char16_value( in MemberId id, in wchar value); - DDS::ReturnCode_t get_byte_value( inout octet value, in MemberId id); - DDS::ReturnCode_t set_byte_value( in MemberId id, in octet value); - DDS::ReturnCode_t get_boolean_value( inout boolean value, in MemberId id); - DDS::ReturnCode_t set_boolean_value( in MemberId id, in boolean value); - DDS::ReturnCode_t get_string_value( inout string value, in MemberId id); - DDS::ReturnCode_t set_string_value( in MemberId id, in string value); - DDS::ReturnCode_t get_wstring_value( inout wstring value, in MemberId id); - DDS::ReturnCode_t set_wstring_value( in MemberId id, in wstring value); - - DDS::ReturnCode_t get_complex_value( inout DynamicData value, in MemberId id); - DDS::ReturnCode_t set_complex_value( in MemberId id, in DynamicData value); - - DDS::ReturnCode_t get_int32_values( inout Int32Seq value, in MemberId id); - DDS::ReturnCode_t set_int32_values( in MemberId id, in Int32Seq value); - DDS::ReturnCode_t get_uint32_values( inout UInt32Seq value, in MemberId id); - DDS::ReturnCode_t set_uint32_values( in MemberId id, in UInt32Seq value); - DDS::ReturnCode_t get_int16_values( inout Int16Seq value, in MemberId id); - DDS::ReturnCode_t set_int16_values( in MemberId id, in Int16Seq value); - DDS::ReturnCode_t get_uint16_values( inout UInt16Seq value, in MemberId id); - DDS::ReturnCode_t set_uint16_values( in MemberId id, in UInt16Seq value); - DDS::ReturnCode_t get_int64_values( inout Int64Seq value, in MemberId id); - DDS::ReturnCode_t set_int64_values( in MemberId id, in Int64Seq value); - DDS::ReturnCode_t get_uint64_values( inout UInt64Seq value, in MemberId id); - DDS::ReturnCode_t set_uint64_values( in MemberId id, in UInt64Seq value); - DDS::ReturnCode_t get_float32_values( inout Float32Seq value, in MemberId id); - DDS::ReturnCode_t set_float32_values( in MemberId id, in Float32Seq value); - DDS::ReturnCode_t get_float64_values( inout Float64Seq value, in MemberId id); - DDS::ReturnCode_t set_float64_values( in MemberId id, in Float64Seq value); - DDS::ReturnCode_t get_float128_values( inout Float128Seq value, in MemberId id); - DDS::ReturnCode_t set_float128_values( in MemberId id, in Float128Seq value); - DDS::ReturnCode_t get_char8_values( inout CharSeq value, in MemberId id); - DDS::ReturnCode_t set_char8_values( in MemberId id, in CharSeq value); - DDS::ReturnCode_t get_char16_values( inout WcharSeq value, in MemberId id); - DDS::ReturnCode_t set_char16_values( in MemberId id, in WcharSeq value); - DDS::ReturnCode_t get_byte_values( inout ByteSeq value, in MemberId id); - DDS::ReturnCode_t set_byte_values( in MemberId id, in ByteSeq value); - DDS::ReturnCode_t get_boolean_values( inout BooleanSeq value, in MemberId id); - DDS::ReturnCode_t set_boolean_values( in MemberId id, in BooleanSeq value); - DDS::ReturnCode_t get_string_values( inout StringSeq value, in MemberId id); - DDS::ReturnCode_t set_string_values( in MemberId id, in StringSeq value); - DDS::ReturnCode_t get_wstring_values( inout WstringSeq value, in MemberId id); - DDS::ReturnCode_t set_wstring_values( in MemberId id, in WstringSeq value); - }; // local interface DynamicData -}; // end module DDS diff --git a/include/fastrtps/types/dds-xtypes_discovery.idl b/include/fastrtps/types/dds-xtypes_discovery.idl deleted file mode 100644 index c9df7aba0e4..00000000000 --- a/include/fastrtps/types/dds-xtypes_discovery.idl +++ /dev/null @@ -1,298 +0,0 @@ -/* dds-xtypes_discovery.idl */ - -// The types in this file shall be serialized with XCDR encoding version 1 -module DDS { - @extensibility(APPENDABLE) @nested - struct BuiltinTopicKey_t { - octet value[16]; - }; - - @extensibility(FINAL) @nested - struct Duration_t { - long sec; unsigned long nanosec; - }; - - @extensibility(APPENDABLE) @nested - struct DeadlineQosPolicy { - Duration_t period; - }; - - enum DestinationOrderQosPolicyKind { - BY_RECEPTION_TIMESTAMP_DESTINATIONORDER_QOS, - BY_SOURCE_TIMESTAMP_DESTINATIONORDER_QOS - }; - - @extensibility(APPENDABLE) @nested - struct DestinationOrderQosPolicy { - DestinationOrderQosPolicyKind kind; - }; - - enum DurabilityQosPolicyKind { - VOLATILE_DURABILITY_QOS, - TRANSIENT_LOCAL_DURABILITY_QOS, - TRANSIENT_DURABILITY_QOS, - PERSISTENT_DURABILITY_QOS - }; - - @extensibility(APPENDABLE) @nested - struct DurabilityQosPolicy { - DurabilityQosPolicyKind kind; - }; - - enum HistoryQosPolicyKind { - KEEP_LAST_HISTORY_QOS, - KEEP_ALL_HISTORY_QOS - }; - - @extensibility(APPENDABLE) @nested - struct HistoryQosPolicy { - HistoryQosPolicyKind kind; - long depth; - }; - - @extensibility(APPENDABLE) @nested - struct DurabilityServiceQosPolicy { - Duration_t service_cleanup_delay; - HistoryQosPolicyKind history_kind; - long history_depth; - long max_samples; - long max_instances; - long max_samples_per_instance; - }; - - @extensibility(APPENDABLE) @nested - struct GroupDataQosPolicy { - ByteSeq value; - }; - - @extensibility(APPENDABLE) @nested - struct LatencyBudgetQosPolicy { - Duration_t duration; - }; - - @extensibility(APPENDABLE) @nested - struct LifespanQosPolicy { - Duration_t duration; - }; - - enum LivelinessQosPolicyKind { - AUTOMATIC_LIVELINESS_QOS, - MANUAL_BY_PARTICIPANT_LIVELINESS_QOS, - MANUAL_BY_TOPIC_LIVELINESS_QOS - }; - - @extensibility(APPENDABLE) @nested - struct LivelinessQosPolicy { - LivelinessQosPolicyKind kind; - Duration_t lease_duration; - }; - - enum OwnershipQosPolicyKind { - SHARED_OWNERSHIP_QOS, - EXCLUSIVE_OWNERSHIP_QOS - }; - - @extensibility(APPENDABLE) @nested - struct OwnershipQosPolicy { - OwnershipQosPolicyKind kind; - }; - - @extensibility(APPENDABLE) @nested - struct OwnershipStrengthQosPolicy { - long value; - }; - - @extensibility(APPENDABLE) @nested - struct PartitionQosPolicy { - StringSeq name; - }; - - enum PresentationQosPolicyAccessScopeKind { - INSTANCE_PRESENTATION_QOS, - TOPIC_PRESENTATION_QOS, - GROUP_PRESENTATION_QOS - }; - - @extensibility(APPENDABLE) @nested - struct PresentationQosPolicy { - PresentationQosPolicyAccessScopeKind access_scope; - boolean coherent_access; - boolean ordered_access; - }; - - enum ReliabilityQosPolicyKind { - BEST_EFFORT_RELIABILITY_QOS, - RELIABLE_RELIABILITY_QOS - }; - - @extensibility(APPENDABLE) @nested - struct ReliabilityQosPolicy { - ReliabilityQosPolicyKind kind; - Duration_t max_blocking_time; - }; - - @extensibility(APPENDABLE) @nested - struct ResourceLimitsQosPolicy { - long max_samples; - long max_instances; - long max_samples_per_instance; - }; - - @extensibility(APPENDABLE) @nested - struct TimeBasedFilterQosPolicy { - Duration_t minimum_separation; - }; - - @extensibility(APPENDABLE) @nested - struct TopicDataQosPolicy { - ByteSeq value; - }; - - @extensibility(APPENDABLE) @nested - struct TransportPriorityQosPolicy { - long value; - }; - - @extensibility(APPENDABLE) @nested - struct UserDataQosPolicy { - ByteSeq value; - }; - - @extensibility(MUTABLE) - struct ParticipantBuiltinTopicData { - @id(0x0050) @key BuiltinTopicKey_t key; - @id(0x002C) UserDataQosPolicy user_data; - }; - - typedef short DataRepresentationId_t; - - const DataRepresentationId_t XCDR_DATA_REPRESENTATION = 0; - const DataRepresentationId_t XML_DATA_REPRESENTATION = 1; - const DataRepresentationId_t XCDR2_DATA_REPRESENTATION = 2; - - typedef sequence DataRepresentationIdSeq; - - const QosPolicyId_t DATA_REPRESENTATION_QOS_POLICY_ID = 23; - const string DATA_REPRESENTATION_QOS_POLICY_NAME = "DataRepresentation"; - - @extensibility(APPENDABLE) @nested - struct DataRepresentationQosPolicy { - DataRepresentationIdSeq value; - }; - - @bit_bound(16) enum TypeConsistencyKind { - DISALLOW_TYPE_COERCION, - ALLOW_TYPE_COERCION - }; - - const QosPolicyId_t TYPE_CONSISTENCY_ENFORCEMENT_QOS_POLICY_ID = 24; - const string TYPE_CONSISTENCY_ENFORCEMENT_QOS_POLICY_NAME = "TypeConsistencyEnforcement"; - - @extensibility(APPENDABLE) @nested - struct TypeConsistencyEnforcementQosPolicy { - TypeConsistencyKind kind; - boolean ignore_sequence_bounds; - boolean ignore_string_bounds; - boolean ignore_member_names; - boolean prevent_type_widening; - boolean force_type_validation; - }; - - @extensibility(MUTABLE) - struct TopicBuiltinTopicData { - @id(0x005A) @key BuiltinTopicKey_t key; - @id(0x0005) ObjectName name; - @id(0x0007) ObjectName type_name; - @id(0x0069) @optional TypeIdV1 type_id; // XTYPES 1.1 - @id(0x0072) @optional TypeObjectV1 type; // XTYPES 1.1 - @id(0x0075) @optional XTypes::TypeInformation type_information; - // XTYPES 1.2 - @id(0x001D) DurabilityQosPolicy durability; - @id(0x001E) DurabilityServiceQosPolicy durability_service; - @id(0x0023) DeadlineQosPolicy deadline; - @id(0x0027) LatencyBudgetQosPolicy latency_budget; - @id(0x001B) LivelinessQosPolicy liveliness; - @id(0x001A) ReliabilityQosPolicy reliability; - @id(0x0049) TransportPriorityQosPolicy transport_priority; - @id(0x002B) LifespanQosPolicy lifespan; - @id(0x0025) DestinationOrderQosPolicy destination_order; - @id(0x0040) HistoryQosPolicy history; - @id(0x0041) ResourceLimitsQosPolicy resource_limits; - @id(0x001F) OwnershipQosPolicy ownership; - @id(0x002E) TopicDataQosPolicy topic_data; - @id(0x0073) DataRepresentationQosPolicy representation; - }; - - @extensibility(MUTABLE) struct TopicQos { - // ... - DataRepresentationQosPolicy representation; - }; - - @extensibility(MUTABLE) - struct PublicationBuiltinTopicData { - @id(0x005A) @key BuiltinTopicKey_t key; - @id(0x0050) BuiltinTopicKey_t participant_key; - @id(0x0005) ObjectName topic_name; - @id(0x0007) ObjectName type_name; - @id(0x0069) @optional TypeIdV1 type_id; // XTYPES 1.1 - @id(0x0072) @optional TypeObjectV1 type; // XTYPES 1.1 - @id(0x0075) @optional XTypes::TypeInformation type_information; - // XTYPES 1.2 - @id(0x001D) DurabilityQosPolicy durability; - @id(0x001E) DurabilityServiceQosPolicy durability_service; - @id(0x0023) DeadlineQosPolicy deadline; - @id(0x0027) LatencyBudgetQosPolicy latency_budget; - @id(0x001B) LivelinessQosPolicy liveliness; - @id(0x001A) ReliabilityQosPolicy reliability; - @id(0x002B) LifespanQosPolicy lifespan; - @id(0x002C) UserDataQosPolicy user_data; - @id(0x001F) OwnershipQosPolicy ownership; - @id(0x0006) OwnershipStrengthQosPolicy ownership_strength; - @id(0x0025) DestinationOrderQosPolicy destination_order; - @id(0x0021) PresentationQosPolicy presentation; - @id(0x0029) PartitionQosPolicy partition; - @id(0x002E) TopicDataQosPolicy topic_data; - @id(0x002D) GroupDataQosPolicy group_data; - @id(0x0073) DataRepresentationQosPolicy representation; - }; - - @extensibility(MUTABLE) - struct DataWriterQos { - // ... DataRepresentationQosPolicy representation; - }; - - @extensibility(MUTABLE) - struct SubscriptionBuiltinTopicData { - @id(0x005A) @key BuiltinTopicKey_t key; - @id(0x0050) BuiltinTopicKey_t participant_key; - @id(0x0005) ObjectName topic_name; - @id(0x0007) ObjectName type_name; - @id(0x0069) @optional TypeIdV1 type_id; // XTYPES 1.1 - @id(0x0072) @optional TypeObjectV1 type; // XTYPES 1.1 - @id(0x0075) @optional XTypes::TypeInformation type_information; - // XTYPES 1.2 - @id(0x001D) DurabilityQosPolicy durability; - @id(0x0023) DeadlineQosPolicy deadline; - @id(0x0027) LatencyBudgetQosPolicy latency_budget; - @id(0x001B) LivelinessQosPolicy liveliness; - @id(0x001A) ReliabilityQosPolicy reliability; - @id(0x001F) OwnershipQosPolicy ownership; - @id(0x0025) DestinationOrderQosPolicy destination_order; - @id(0x002C) UserDataQosPolicy user_data; - @id(0x0004) TimeBasedFilterQosPolicy time_based_filter; - @id(0x0021) PresentationQosPolicy presentation; - @id(0x0029) PartitionQosPolicy partition; - @id(0x002E) TopicDataQosPolicy topic_data; - @id(0x002D) GroupDataQosPolicy group_data; - @id(0x0073) DataRepresentationQosPolicy representation; - @id(0x0074) TypeConsistencyEnforcementQosPolicy type_consistency; - }; - - @extensibility(MUTABLE) - struct DataReaderQos { - // ... - DataRepresentationQosPolicy representation; - TypeConsistencyEnforcementQosPolicy type_consistency; - }; -}; // end module DDS - \ No newline at end of file diff --git a/include/fastrtps/types/dds-xtypes_typeobject.idl b/include/fastrtps/types/dds-xtypes_typeobject.idl deleted file mode 100644 index 465300a4c7b..00000000000 --- a/include/fastrtps/types/dds-xtypes_typeobject.idl +++ /dev/null @@ -1,1077 +0,0 @@ -/* dds-xtypes_typeobject.idl */ - -// The types in this file shall be serialized with XCDR encoding version 2 -module DDS { - module XTypes { - - // ---------- Equivalence Kinds ------------------ - typedef octet EquivalenceKind; - const octet EK_MINIMAL = 0xF1; // 0x1111 0001 - const octet EK_COMPLETE = 0xF2; // 0x1111 0010 - const octet EK_BOTH = 0xF3; // 0x1111 0011 - - // ---------- TypeKinds (begin) ------------------ - typedef octet TypeKind; // Primitive TKs - - const octet TK_NONE = 0x00; - const octet TK_BOOLEAN = 0x01; - const octet TK_BYTE = 0x02; - const octet TK_INT16 = 0x03; - const octet TK_INT32 = 0x04; - const octet TK_INT64 = 0x05; - const octet TK_UINT16 = 0x06; - const octet TK_UINT32 = 0x07; - const octet TK_UINT64 = 0x08; - const octet TK_FLOAT32 = 0x09; - const octet TK_FLOAT64 = 0x0A; - const octet TK_FLOAT128 = 0x0B; - const octet TK_CHAR8 = 0x10; - const octet TK_CHAR16 = 0x11; - - // String TKs - const octet TK_STRING8 = 0x20; - const octet TK_STRING16 = 0x21; - - - // Constructed/Named types - const octet TK_ALIAS = 0x30; - - // Enumerated TKs - const octet TK_ENUM = 0x40; - const octet TK_BITMASK = 0x41; - - // Structured TKs - const octet TK_ANNOTATION = 0x50; - const octet TK_STRUCTURE = 0x51; - const octet TK_UNION = 0x52; - const octet TK_BITSET = 0x53; - - // Collection TKs - const octet TK_SEQUENCE = 0x60; - const octet TK_ARRAY = 0x61; - const octet TK_MAP = 0x62; - - // ---------- TypeKinds (end) ------------------ - - // ---------- Extra TypeIdentifiers (begin) ----------- - typedef octet TypeIdentiferKind; - const octet TI_STRING8_SMALL = 0x70; - const octet TI_STRING8_LARGE = 0x71; - const octet TI_STRING16_SMALL = 0x72; - const octet TI_STRING16_LARGE = 0x73; - - const octet TI_PLAIN_SEQUENCE_SMALL = 0x80; - const octet TI_PLAIN_SEQUENCE_LARGE = 0x81; - const octet TI_PLAIN_ARRAY_SMALL = 0x90; - const octet TI_PLAIN_ARRAY_LARGE = 0x91; - const octet TI_PLAIN_MAP_SMALL = 0xA0; - const octet TI_PLAIN_MAP_LARGE = 0xA1; - - const octet TI_STRONGLY_CONNECTED_COMPONENT = 0xB0; - - // ---------- Extra TypeIdentifiers (end) ------------- - - // The name of some element (e.g. type, type member, module) - // Valid characters are alphanumeric plus the "_" cannot start with digit - - const long MEMBER_NAME_MAX_LENGTH = 256; typedef string MemberName; - - // Qualified type name includes the name of containing modules - // using "::" as separator. No leading "::". E.g. "MyModule::MyType" - const long TYPE_NAME_MAX_LENGTH = 256; - typedef string QualifiedTypeName; - - // Every type has an ID. Those of the primitive types are pre-defined. - typedef octet PrimitiveTypeId; - - // First 14 bytes of MD5 of the serialized TypeObject using XCDR - // version 2 with Little Endian encoding - typedef octet EquivalenceHash[14]; - - // First 4 bytes of MD5 of of a member name converted to bytes - // using UTF-8 encoding and without a 'nul' terminator. - // Example: the member name "color" has NameHash {0x70, 0xDD, 0xA5, 0xDF} - - typedef octet NameHash[4]; - - // Long Bound of a collection type - typedef unsigned long LBound; - typedef sequence LBoundSeq; - const LBound INVALID_LBOUND = 0; - - // Short Bound of a collection type - typedef octet SBound; - typedef sequence SBoundSeq; - const SBound INVALID_SBOUND = 0; - - @extensibility(FINAL) @nested - union TypeObjectHashId switch (octet) { - case EK_COMPLETE: - case EK_MINIMAL: - EquivalenceHash hash; - }; - - // Flags that apply to struct/union/collection/enum/bitmask/bitset - // members/elements and DO affect type assignability - // Depending on the flag it may not apply to members of all types - - // When not all, the applicable member types are listed - @bit_bound(16) - bitmask MemberFlag { - @position(0) TRY_CONSTRUCT1, // T1 | 00 = INVALID, 01 = DISCARD - @position(1) TRY_CONSTRUCT2, // T2 | 10 = USE_DEFAULT, 11 = TRIM - @position(2) IS_EXTERNAL, // X StructMember, UnionMember, - // CollectionElement - @position(3) IS_OPTIONAL, // O StructMember - @position(4) IS_MUST_UNDERSTAND, // M StructMember - @position(5) IS_KEY, // K StructMember, UnionDiscriminator - @position(6) IS_DEFAULT // D UnionMember, EnumerationLiteral - }; - - typedef MemberFlag CollectionElementFlag; // T1, T2, X - typedef MemberFlag StructMemberFlag; // T1, T2, O, M, K, X - typedef MemberFlag UnionMemberFlag; // T1, T2, D, X - typedef MemberFlag UnionDiscriminatorFlag; // T1, T2, K - typedef MemberFlag EnumeratedLiteralFlag; // D - typedef MemberFlag AnnotationParameterFlag; // Unused. No flags apply - typedef MemberFlag AliasMemberFlag; // Unused. No flags apply - typedef MemberFlag BitflagFlag; // Unused. No flags apply - typedef MemberFlag BitsetMemberFlag; // Unused. No flags apply - - // Mask used to remove the flags that do no affect assignability - // Selects T1, T2, O, M, K, D - const unsigned short MemberFlagMinimalMask = 0x003f; - - // Flags that apply to type declarationa and DO affect assignability - // Depending on the flag it may not apply to all types - // When not all, the applicable types are listed - @bit_bound(16) bitmask TypeFlag { - @position(0) IS_FINAL, // F | - @position(1) IS_APPENDABLE, // A |- Struct, Union - @position(2) IS_MUTABLE, // M | (exactly one flag) - @position(3) IS_NESTED, // N Struct, Union - @position(4) IS_AUTOID_HASH // H Struct - }; - - typedef TypeFlag StructTypeFlag; // All flags apply - typedef TypeFlag UnionTypeFlag; // All flags apply - typedef TypeFlag CollectionTypeFlag; // Unused. No flags apply - typedef TypeFlag AnnotationTypeFlag; // Unused. No flags apply - typedef TypeFlag AliasTypeFlag; // Unused. No flags apply - typedef TypeFlag EnumTypeFlag; // Unused. No flags apply - typedef TypeFlag BitmaskTypeFlag; // Unused. No flags apply - typedef TypeFlag BitsetTypeFlag; // Unused. No flags apply - - // Mask used to remove the flags that do no affect assignability - const unsigned short TypeFlagMinimalMask = 0x0007; // Selects M, A, F - - // Forward declaration - union TypeIdentifier; - - // 1 Byte - @extensibility(FINAL) @nested - struct StringSTypeDefn { - SBound bound; - }; - - // 4 Bytes - @extensibility(FINAL) @nested - struct StringLTypeDefn { - LBound bound; - }; - - @extensibility(FINAL) @nested - struct PlainCollectionHeader { - EquivalenceKind equiv_kind; - CollectionElementFlag element_flags; - }; - - @extensibility(FINAL) @nested - struct PlainSequenceSElemDefn { - PlainCollectionHeader header; - SBound bound; - @external TypeIdentifier element_identifier; - }; - - @extensibility(FINAL) @nested - struct PlainSequenceLElemDefn { - PlainCollectionHeader header; - LBound bound; - @external TypeIdentifier element_identifier; - }; - - @extensibility(FINAL) @nested - struct PlainArraySElemDefn { - PlainCollectionHeader header; - SBoundSeq array_bound_seq; - @external TypeIdentifier element_identifier; - }; - - @extensibility(FINAL) @nested - struct PlainArrayLElemDefn { - PlainCollectionHeader header; - LBoundSeq array_bound_seq; - @external TypeIdentifier element_identifier; - }; - - @extensibility(FINAL) @nested - struct PlainMapSTypeDefn { - PlainCollectionHeader header; - SBound bound; - @external TypeIdentifier element_identifier; - CollectionElementFlag key_flags; - @external TypeIdentifier key_identifier; - }; - - @extensibility(FINAL) @nested - struct PlainMapLTypeDefn { - PlainCollectionHeader header; - LBound bound; - @external TypeIdentifier element_identifier; - CollectionElementFlag key_flags; - @external TypeIdentifier key_identifier; - }; - - // Used for Types that have cyclic depencencies with other types - @extensibility(APPENDABLE) @nested - struct StronglyConnectedComponentId { - TypeObjectHashId sc_component_id; // Hash StronglyConnectedComponent - long scc_length; // StronglyConnectedComponent.length - long scc_index ; // identify type in Strongly Connected Comp. - }; - - // Future extensibility - @extensibility(MUTABLE) @nested - struct ExtendedTypeDefn { - // Empty. Available for future extension - }; - - - // The TypeIdentifier uniquely identifies a type (a set of equivalent - // types according to an equivalence relationship: COMPLETE, MNIMAL). - // - // In some cases (primitive types, strings, plain types) the identifier - // is a explicit description of the type. - // In other cases the Identifier is a Hash of the type description - // - // In the case of primitive types and strings the implied equivalence - // relation is the identity. - // - // For Plain Types and Hash-defined TypeIdentifiers there are three - // possibilities: MINIMAL, COMPLETE, and COMMON: - // - MINIMAL indicates the TypeIdentifier identifies equivalent types - // according to the MINIMAL equivalence relation - // - COMPLETE indicates the TypeIdentifier identifies equivalent types - // according to the COMPLETE equivalence relation - // - COMMON indicates the TypeIdentifier identifies equivalent types - // according to both the MINIMAL and the COMMON equivalence relation. - // This means the TypeIdentifier is the same for both relationships - // - - @extensibility(FINAL) @nested - union TypeIdentifier switch (octet) { - // ============ Primitive types - use TypeKind ==================== - // All primitive types fall here. - // Commented-out because Unions cannot have cases with no member. - /* case TK_NONE: - case TK_BOOLEAN: - case TK_BYTE_TYPE: - case TK_INT16_TYPE: - case TK_INT32_TYPE: - case TK_INT64_TYPE: - case TK_UINT16_TYPE: - case TK_UINT32_TYPE: - case TK_UINT64_TYPE: - case TK_FLOAT32_TYPE: - case TK_FLOAT64_TYPE: - case TK_FLOAT128_TYPE: - case TK_CHAR8_TYPE: - case TK_CHAR16_TYPE: - // No Value - */ - - // ============ Strings - use TypeIdentifierKind =================== - case TI_STRING8_SMALL: - case TI_STRING16_SMALL: - StringSTypeDefn string_sdefn; - - case TI_STRING8_LARGE: - case TI_STRING16_LARGE: - StringLTypeDefn string_ldefn; - - // ============ Plain collectios - use TypeIdentifierKind ========= - case TI_PLAIN_SEQUENCE_SMALL: - PlainSequenceSElemDefn seq_sdefn; - case TI_PLAIN_SEQUENCE_LARGE: - PlainSequenceLElemDefn seq_ldefn; - - case TI_PLAIN_ARRAY_SMALL: - PlainArraySElemDefn array_sdefn; - case TI_PLAIN_ARRAY_LARGE: - PlainArrayLElemDefn array_ldefn; - - case TI_PLAIN_MAP_SMALL: - PlainMapSTypeDefn map_sdefn; - case TI_PLAIN_MAP_LARGE: - PlainMapLTypeDefn map_ldefn; - - // ============ Types that are mutually dependent on each other === - case TI_STRONGLY_CONNECTED_COMPONENT: - StronglyConnectedComponentId sc_component_id; - - // ============ The remaining cases - use EquivalenceKind ========= - case EK_COMPLETE: - case EK_MINIMAL: - EquivalenceHash equivalence_hash; - - // =================== Future extensibility ============ - // Future extensions - default: ExtendedTypeDefn extended_defn; - }; - typedef sequence TypeIdentifierSeq; - - - // --- Annotation usage: ---------------------------------------------- - - // ID of a type member - typedef unsigned long MemberId; - const unsigned long ANNOTATION_STR_VALUE_MAX_LEN = 128; - const unsigned long ANNOTATION_OCTETSEC_VALUE_MAX_LEN = 128; - - @extensibility(MUTABLE) @nested - struct ExtendedAnnotationParameterValue { - // Empty. Available for future extension - }; - - /* Literal value of an annotation member: either the default value in its - * definition or the value applied in its usage. - */ - - @extensibility(FINAL) @nested - union AnnotationParameterValue switch (octet) { - case TK_BOOLEAN: - boolean boolean_value; - case TK_BYTE: - octet byte_value; - case TK_INT16: - short int16_value; - case TK_UINT16: - unsigned short uint_16_value; - case TK_INT32: - long int32_value; - case TK_UINT32: - unsigned long uint32_value; - case TK_INT64: - long long int64_value; - case TK_UINT64: - unsigned long long uint64_value; - case TK_FLOAT32: - float float32_value; - case TK_FLOAT64: - double float64_value; - case TK_FLOAT128: - long double float128_value; - case TK_CHAR8: - char char_value; - case TK_CHAR16: - wchar wchar_value; - case TK_ENUM: - long enumerated_value; - case TK_STRING8: - string string8_value; - case TK_STRING16: - wstring string16_value; - default: - ExtendedAnnotationParameterValue extended_value; - }; - - // The application of an annotation to some type or type member - @extensibility(APPENDABLE) @nested - struct AppliedAnnotationParameter { - NameHash paramname_hash; - AnnotationParameterValue value; - }; - - // Sorted by AppliedAnnotationParameter.paramname_hash - typedef - sequence AppliedAnnotationParameterSeq; - - @extensibility(APPENDABLE) @nested - struct AppliedAnnotation { - TypeIdentifier annotation_typeid; - @optional AppliedAnnotationParameterSeq param_seq; - }; - - // Sorted by AppliedAnnotation.annotation_typeid - typedef sequence AppliedAnnotationSeq; - - // @verbatim(placement="", language="", text="") - @extensibility(FINAL) @nested - struct AppliedVerbatimAnnotation { - string<32> placement; - string<32> language; - string text; - }; - - // --- Aggregate types: ----------------------------------------------- - @extensibility(APPENDABLE) @nested - struct AppliedBuiltinMemberAnnotations { - @optional string unit; // @unit("") - @optional AnnotationParameterValue min; // @min , @range - @optional AnnotationParameterValue max; // @max , @range - @optional string hash_id; // @hash_id("") - }; - - @extensibility(FINAL) @nested - struct CommonStructMember { - MemberId member_id; - StructMemberFlag member_flags; - TypeIdentifier member_type_id; - }; - - // COMPLETE Details for a member of an aggregate type - @extensibility(FINAL) @nested - struct CompleteMemberDetail { - MemberName name; - @optional AppliedBuiltinMemberAnnotations ann_builtin; - @optional AppliedAnnotationSeq ann_custom; - }; - - // MINIMAL Details for a member of an aggregate type - @extensibility(FINAL) @nested struct MinimalMemberDetail { - NameHash name_hash; - }; - - // Member of an aggregate type - @extensibility(APPENDABLE) @nested - struct CompleteStructMember { - CommonStructMember common; - CompleteMemberDetail detail; - }; - - // Ordered by the member_index - typedef sequence CompleteStructMemberSeq; - - // Member of an aggregate type - @extensibility(APPENDABLE) @nested - struct MinimalStructMember { - CommonStructMember common; - MinimalMemberDetail detail; - }; - - // Ordered by common.member_id - typedef sequence MinimalStructMemberSeq; - - @extensibility(APPENDABLE) @nested - struct AppliedBuiltinTypeAnnotations { - @optional AppliedVerbatimAnnotation verbatim; // @verbatim(...) - }; - - @extensibility(FINAL) @nested - struct MinimalTypeDetail { - // Empty. Available for future extension - }; - - @extensibility(FINAL) @nested - struct CompleteTypeDetail { - @optional AppliedBuiltinTypeAnnotations ann_builtin; - @optional AppliedAnnotationSeq ann_custom; - QualifiedTypeName type_name; - }; - - @extensibility(APPENDABLE) @nested - struct CompleteStructHeader { - TypeIdentifier base_type; - CompleteTypeDetail detail; - }; - - @extensibility(APPENDABLE) @nested - struct MinimalStructHeader { - TypeIdentifier base_type; - MinimalTypeDetail detail; - }; - - @extensibility(FINAL) @nested - struct CompleteStructType { - StructTypeFlag struct_flags; - CompleteStructHeader header; - CompleteStructMemberSeq member_seq; - }; - - @extensibility(FINAL) @nested - struct MinimalStructType { - StructTypeFlag struct_flags; - MinimalStructHeader header; - MinimalStructMemberSeq member_seq; - }; - - // --- Union: --------------------------------------------------------- - - // Case labels that apply to a member of a union type - // Ordered by their values - typedef sequence UnionCaseLabelSeq; - - @extensibility(FINAL) @nested - struct CommonUnionMember { - MemberId member_id; - UnionMemberFlag member_flags; - TypeIdentifier type_id; - UnionCaseLabelSeq label_seq; - }; - - // Member of a union type - @extensibility(APPENDABLE) @nested - struct CompleteUnionMember { - CommonUnionMember common; - CompleteMemberDetail detail; - }; - - // Ordered by member_index - typedef sequence CompleteUnionMemberSeq; - - // Member of a union type - @extensibility(APPENDABLE) @nested - struct MinimalUnionMember { - CommonUnionMember common; - MinimalMemberDetail detail; - }; - - // Ordered by MinimalUnionMember.common.member_id - typedef sequence MinimalUnionMemberSeq; - - @extensibility(FINAL) @nested - struct CommonDiscriminatorMember { - UnionDiscriminatorFlag member_flags; - TypeIdentifier type_id; - }; - - // Member of a union type - @extensibility(APPENDABLE) @nested - struct CompleteDiscriminatorMember { - CommonDiscriminatorMember common; - @optional AppliedBuiltinTypeAnnotations ann_builtin; - @optional AppliedAnnotationSeq ann_custom; - }; - - // Member of a union type - @extensibility(APPENDABLE) @nested - struct MinimalDiscriminatorMember { - CommonDiscriminatorMember common; - }; - - @extensibility(APPENDABLE) @nested - struct CompleteUnionHeader { - CompleteTypeDetail detail; - }; - - @extensibility(APPENDABLE) @nested - struct MinimalUnionHeader { - MinimalTypeDetail detail; - }; - - @extensibility(FINAL) @nested - struct CompleteUnionType { - UnionTypeFlag union_flags; - CompleteUnionHeader header; - CompleteDiscriminatorMember discriminator; - CompleteUnionMemberSeq member_seq; - }; - - @extensibility(FINAL) @nested - struct MinimalUnionType { - UnionTypeFlag union_flags; - MinimalUnionHeader header; - MinimalDiscriminatorMember discriminator; - MinimalUnionMemberSeq member_seq; - }; - - // --- Annotation: --------------------------------------------------- - @extensibility(FINAL) @nested - struct CommonAnnotationParameter { - AnnotationParameterFlag member_flags; - TypeIdentifier member_type_id; - }; - - // Member of an annotation type - @extensibility(APPENDABLE) @nested - struct CompleteAnnotationParameter { - CommonAnnotationParameter common; - MemberName name; - AnnotationParameterValue default_value; - }; - - // Ordered by CompleteAnnotationParameter.name - typedef sequence CompleteAnnotationParameterSeq; - - @extensibility(APPENDABLE) @nested - struct MinimalAnnotationParameter { - CommonAnnotationParameter common; - NameHash name_hash; - AnnotationParameterValue default_value; - }; - - // Ordered by MinimalAnnotationParameter.name_hash - typedef sequence MinimalAnnotationParameterSeq; - - @extensibility(APPENDABLE) @nested - struct CompleteAnnotationHeader { - QualifiedTypeName annotation_name; - }; - - @extensibility(APPENDABLE) @nested - struct MinimalAnnotationHeader { - // Empty. Available for future extension - }; - - @extensibility(FINAL) @nested - struct CompleteAnnotationType { - AnnotationTypeFlag annotation_flag; - CompleteAnnotationHeader header; - CompleteAnnotationParameterSeq member_seq; - }; - - @extensibility(FINAL) @nested - struct MinimalAnnotationType { - AnnotationTypeFlag annotation_flag; - MinimalAnnotationHeader header; - MinimalAnnotationParameterSeq member_seq; - }; - - // --- Alias: --------------------------------------------------------- - @extensibility(FINAL) @nested - struct CommonAliasBody { - AliasMemberFlag related_flags; - TypeIdentifier related_type; - }; - - @extensibility(APPENDABLE) @nested - struct CompleteAliasBody { - CommonAliasBody common; - @optional AppliedBuiltinMemberAnnotations ann_builtin; - @optional AppliedAnnotationSeq ann_custom; - }; - - @extensibility(APPENDABLE) @nested - struct MinimalAliasBody { - CommonAliasBody common; - }; - - @extensibility(APPENDABLE) @nested - struct CompleteAliasHeader { - CompleteTypeDetail detail; - }; - - @extensibility(APPENDABLE) @nested - struct MinimalAliasHeader { - // Empty. Available for future extension - }; - - @extensibility(FINAL) @nested - struct CompleteAliasType { - AliasTypeFlag alias_flags; - CompleteAliasHeader header; - CompleteAliasBody body; - }; - - @extensibility(FINAL) @nested - struct MinimalAliasType { - AliasTypeFlag alias_flags; - MinimalAliasHeader header; - MinimalAliasBody body; - }; - - // --- Collections: --------------------------------------------------- - @extensibility(FINAL) @nested - struct CompleteElementDetail { - @optional AppliedBuiltinMemberAnnotations ann_builtin; - @optional AppliedAnnotationSeq ann_custom; - }; - - @extensibility(FINAL) @nested - struct CommonCollectionElement { - CollectionElementFlag element_flags; - TypeIdentifier type; - }; - - @extensibility(APPENDABLE) @nested - struct CompleteCollectionElement { - CommonCollectionElement common; - CompleteElementDetail detail; - }; - - @extensibility(APPENDABLE) @nested - struct MinimalCollectionElement { - CommonCollectionElement common; - }; - - @extensibility(FINAL) @nested - struct CommonCollectionHeader { - LBound bound; - }; - - @extensibility(APPENDABLE) @nested - struct CompleteCollectionHeader { - CommonCollectionHeader common; - @optional CompleteTypeDetail detail; // not present for anonymous - }; - - @extensibility(APPENDABLE) @nested - struct MinimalCollectionHeader { - CommonCollectionHeader common; - }; - - // --- Sequence: ----------------------------------------------------- - @extensibility(FINAL) @nested - struct CompleteSequenceType { - CollectionTypeFlag collection_flag; - CompleteCollectionHeader header; - CompleteCollectionElement element; - }; - - - @extensibility(FINAL) @nested - struct MinimalSequenceType { - CollectionTypeFlag collection_flag; - MinimalCollectionHeader header; - MinimalCollectionElement element; - }; - - // --- Array: ----------------------------------------------------- - @extensibility(FINAL) @nested - struct CommonArrayHeader { - LBoundSeq bound_seq; - }; - - @extensibility(APPENDABLE) @nested - struct CompleteArrayHeader { - CommonArrayHeader common; - CompleteTypeDetail detail; - }; - - @extensibility(APPENDABLE) @nested - struct MinimalArrayHeader { - CommonArrayHeader common; - }; - - @extensibility(APPENDABLE) @nested - struct CompleteArrayType { - CollectionTypeFlag collection_flag; - CompleteArrayHeader header; - CompleteCollectionElement element; - }; - - @extensibility(FINAL) @nested - struct MinimalArrayType { - CollectionTypeFlag collection_flag; - MinimalArrayHeader header; - MinimalCollectionElement element; - }; - - // --- Map: ----------------------------------------------------- - @extensibility(FINAL) @nested - struct CompleteMapType { - CollectionTypeFlag collection_flag; - CompleteCollectionHeader header; - CompleteCollectionElement key; - CompleteCollectionElement element; - }; - - @extensibility(FINAL) @nested - struct MinimalMapType { - CollectionTypeFlag collection_flag; - MinimalCollectionHeader header; - MinimalCollectionElement key; - MinimalCollectionElement element; - }; - - // --- Enumeration: --------------------------------------------------- - typedef unsigned short BitBound; - - // Constant in an enumerated type - @extensibility(APPENDABLE) @nested - struct CommonEnumeratedLiteral { - long value; - EnumeratedLiteralFlag flags; - }; - - // Constant in an enumerated type - @extensibility(APPENDABLE) @nested - struct CompleteEnumeratedLiteral { - CommonEnumeratedLiteral common; - CompleteMemberDetail detail; - }; - - // Ordered by EnumeratedLiteral.common.value - typedef sequence CompleteEnumeratedLiteralSeq; - - // Constant in an enumerated type - @extensibility(APPENDABLE) @nested - struct MinimalEnumeratedLiteral { - CommonEnumeratedLiteral common; - MinimalMemberDetail detail; - }; - - // Ordered by EnumeratedLiteral.common.value - typedef sequence MinimalEnumeratedLiteralSeq; - - @extensibility(FINAL) @nested - struct CommonEnumeratedHeader { - BitBound bit_bound; - }; - - @extensibility(APPENDABLE) @nested - struct CompleteEnumeratedHeader { - CommonEnumeratedHeader common; - CompleteTypeDetail detail; - }; - - @extensibility(APPENDABLE) @nested - struct MinimalEnumeratedHeader { - CommonEnumeratedHeader common; - }; - - // Enumerated type - @extensibility(FINAL) @nested - struct CompleteEnumeratedType { - EnumTypeFlag enum_flags; // unused - CompleteEnumeratedHeader header; - CompleteEnumeratedLiteralSeq literal_seq; - }; - - // Enumerated type - @extensibility(FINAL) @nested - struct MinimalEnumeratedType { - EnumTypeFlag enum_flags; // unused - MinimalEnumeratedHeader header; - MinimalEnumeratedLiteralSeq literal_seq; - }; - - // --- Bitmask: ------------------------------------------------------- - // Bit in a bit mask - @extensibility(FINAL) @nested - struct CommonBitflag { - unsigned short position; - BitflagFlag flags; - }; - - @extensibility(APPENDABLE) @nested - struct CompleteBitflag { - CommonBitflag common; - CompleteMemberDetail detail; - }; - - // Ordered by Bitflag.position - typedef sequence CompleteBitflagSeq; - - @extensibility(APPENDABLE) @nested - struct MinimalBitflag { - CommonBitflag common; - MinimalMemberDetail detail; - }; - - // Ordered by Bitflag.position - typedef sequence MinimalBitflagSeq; - - @extensibility(FINAL) @nested - struct CommonBitmaskHeader { - BitBound bit_bound; - }; - - typedef CompleteEnumeratedHeader CompleteBitmaskHeader; - - typedef MinimalEnumeratedHeader MinimalBitmaskHeader; - - @extensibility(APPENDABLE) @nested - struct CompleteBitmaskType { - BitmaskTypeFlag bitmask_flags; // unused - CompleteBitmaskHeader header; - CompleteBitflagSeq flag_seq; - }; - - @extensibility(APPENDABLE) @nested - struct MinimalBitmaskType { - BitmaskTypeFlag bitmask_flags; // unused - MinimalBitmaskHeader header; - MinimalBitflagSeq flag_seq; - }; - - // --- Bitset: --------------------------------------------------------- - @extensibility(FINAL) @nested - struct CommonBitfield { - unsigned short position; - BitsetMemberFlag flags; - octet bitcount; - TypeKind holder_type; // Must be primitive integer type - }; - - @extensibility(APPENDABLE) @nested - struct CompleteBitfield { - CommonBitfield common; - CompleteMemberDetail detail; - }; - - // Ordered by Bitfield.position - typedef sequence CompleteBitfieldSeq; - - @extensibility(APPENDABLE) @nested - struct MinimalBitfield { - CommonBitfield common; - NameHash name_hash; - }; - - // Ordered by Bitfield.position - typedef sequence MinimalBitfieldSeq; - - @extensibility(APPENDABLE) @nested - struct CompleteBitsetHeader { - CompleteTypeDetail detail; - }; - - @extensibility(APPENDABLE) @nested - struct MinimalBitsetHeader { - // Empty. Available for future extension - }; - - @extensibility(APPENDABLE) @nested - struct CompleteBitsetType { - BitsetTypeFlag bitset_flags; // unused - CompleteBitsetHeader header; - CompleteBitfieldSeq field_seq; - }; - - @extensibility(APPENDABLE) @nested - struct MinimalBitsetType { - BitsetTypeFlag bitset_flags; // unused - MinimalBitsetHeader header; - MinimalBitfieldSeq field_seq; - }; - - // --- Type Object: -------------------------------------------------- - // The types associated with each case selection must have extensibility - // kind APPENDABLE or MUTABLE so that they can be extended in the future - - @extensibility(MUTABLE) @nested - struct CompleteExtendedType { - // Empty. Available for future extension - }; - - @extensibility(FINAL) @nested - union CompleteTypeObject switch (octet) { - case TK_ALIAS: - CompleteAliasType alias_type; - case TK_ANNOTATION: - CompleteAnnotationType annotation_type; - case TK_STRUCTURE: - CompleteStructType struct_type; - case TK_UNION: - CompleteUnionType union_type; - case TK_BITSET: - CompleteBitsetType bitset_type; - case TK_SEQUENCE: - CompleteSequenceType sequence_type; - case TK_ARRAY: - CompleteArrayType array_type; - case TK_MAP: - CompleteMapType map_type; - case TK_ENUM: - CompleteEnumeratedType enumerated_type; - case TK_BITMASK: - CompleteBitmaskType bitmask_type; - - // =================== Future extensibility ============ - default: - CompleteExtendedType extended_type; - }; - - @extensibility(MUTABLE) @nested - struct MinimalExtendedType { - // Empty. Available for future extension - }; - - - @extensibility(FINAL) @nested - union MinimalTypeObject switch (octet) { - case TK_ALIAS: - MinimalAliasType alias_type; - case TK_ANNOTATION: - MinimalAnnotationType annotation_type; - case TK_STRUCTURE: - MinimalStructType struct_type; - case TK_UNION: - MinimalUnionType union_type; - case TK_BITSET: - MinimalBitsetType bitset_type; - case TK_SEQUENCE: - MinimalSequenceType sequence_type; - case TK_ARRAY: - MinimalArrayType array_type; - case TK_MAP: - MinimalMapType map_type; - case TK_ENUM: - MinimalEnumeratedType enumerated_type; - case TK_BITMASK: - MinimalBitmaskType bitmask_type; - - // =================== Future extensibility ============ - default: - MinimalExtendedType extended_type; - }; - - @extensibility(APPENDABLE) @nested - union TypeObject switch (octet) { // EquivalenceKind - case EK_COMPLETE: - CompleteTypeObject complete; - case EK_MINIMAL: - MinimalTypeObject minimal; - }; - typedef sequence TypeObjectSeq; - - // Set of TypeObjects representing a strong component: Equivalence class - // for the Strong Connectivity relationship (mutual reachability between - // types). - // Ordered by fully qualified typename lexicographic order - typedef TypeObjectSeq StronglyConnectedComponent; - - @extensibility(FINAL) @nested - struct TypeIdentifierTypeObjectPair { - TypeIdentifier type_identifier; - TypeObject type_object; - }; - typedef - sequence TypeIdentifierTypeObjectPairSeq; - - @extensibility(FINAL) @nested - struct TypeIdentifierPair { - TypeIdentifier type_identifier1; - TypeIdentifier type_identifier2; - }; - typedef sequence TypeIdentifierPairSeq; - - @extensibility(APPENDABLE) @nested - struct TypeIdentifierWithSize { - DDS::Xtypes::TypeIdentifier type_id; - unsigned long typeobject_serialized_size; - }; - typedef sequence TypeIdentfierWithSizeSeq; - - @extensibility(APPENDABLE) @nested - struct TypeIdentifierWithDependencies { - TypeIdentifierWithSize typeid_with_size; - // The total additional types related to minimal_type - long dependent_typeid_count; - sequence dependent_typeids; - }; - typedef sequence TypeIdentifierWithDependenciesSeq; - - // This appears in the builtin DDS topics PublicationBuiltinTopicData - // and SubscriptionBuiltinTopicData - - @extensibility(MUTABLE) @nested - struct TypeInformation { - @id(0x1001) TypeIdentifierWithDependencies minimal; - @id(0x1002) TypeIdentifierWithDependencies complete; - }; - typedef sequence TypeInformationSeq; - - }; // end of module XTypes -}; // end module DDS diff --git a/include/fastrtps/utils/Semaphore.h b/include/fastrtps/utils/Semaphore.h deleted file mode 100644 index a2d20af4378..00000000000 --- a/include/fastrtps/utils/Semaphore.h +++ /dev/null @@ -1,100 +0,0 @@ -// Copyright 2016 Esteve Fernandez -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -#ifndef FASTRTPS_SEMAPHORE_H_ -#define FASTRTPS_SEMAPHORE_H_ - -#include -#include - -namespace eprosima { -namespace fastrtps { - -class Semaphore { -public: - explicit Semaphore(size_t count = 0); - Semaphore(const Semaphore&) = delete; - Semaphore& operator=(const Semaphore&) = delete; - - void post(); - void wait(); - void disable(); - void enable(); - void post(int n); - -private: - size_t count_; - std::mutex mutex_; - std::condition_variable cv_; - bool disable_; -}; - -inline Semaphore::Semaphore(size_t count) : count_(count), disable_(false) {} - -inline void Semaphore::post() { - std::lock_guard lock(mutex_); - if (!disable_) - { - ++count_; - cv_.notify_one(); - } -} - -inline void Semaphore::post(int n) { - std::lock_guard lock(mutex_); - if (!disable_) - { - count_ += n; - for (int i = 0; i < n; ++i) - { - cv_.notify_one(); - } - } -} - -inline void Semaphore::disable() { - std::lock_guard lock(mutex_); - if (!disable_) - { - count_ = (size_t)-1L; - cv_.notify_all(); - disable_ = true; - } -} - -inline void Semaphore::enable() { - std::lock_guard lock(mutex_); - if (disable_) - { - count_ = 0; - disable_ = false; - } -} - -inline void Semaphore::wait() { - std::unique_lock lock(mutex_); - if (!disable_) - { - cv_.wait(lock, [&] { - if (disable_) return true; - return count_ > 0; - }); - --count_; - } -} - -} // fastrtps -} // eprosima - -#endif // FASTRTPS_SEMAPHORE_H_ diff --git a/include/fastrtps/utils/System.h b/include/fastrtps/utils/System.h deleted file mode 100644 index 8a9e86b56ec..00000000000 --- a/include/fastrtps/utils/System.h +++ /dev/null @@ -1,44 +0,0 @@ -// Copyright 2018 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file System.h - * - */ - -#ifndef _EPROSIMA_SYSTEM_UTILS_H -#define _EPROSIMA_SYSTEM_UTILS_H - -#include "../fastrtps_dll.h" - -namespace eprosima { -namespace fastrtps { - -/** - * Class System, to provide helper functions to access system information. - * @ingroup UTILITIES_MODULE - */ -class System -{ -public: - - //! Returns current process identifier. - FASTDDS_DEPRECATED_UNTIL(3, "eprosima::fastrtps::System::GetPID", "") - RTPS_DllAPI static int GetPID(); -}; - -} /* namespace fastrtps */ -} /* namespace eprosima */ - -#endif /* _EPROSIMA_SYSTEM_UTILS_H */ diff --git a/include/fastrtps/utils/TimeConversion.h b/include/fastrtps/utils/TimeConversion.h deleted file mode 100644 index e5950a41f49..00000000000 --- a/include/fastrtps/utils/TimeConversion.h +++ /dev/null @@ -1,160 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file TimeConversion.h - * - */ - -#ifndef TIMECONVERSION_H_ -#define TIMECONVERSION_H_ - -#include -#include - -namespace eprosima { -namespace fastrtps{ -namespace rtps { - - -namespace TimeConv{ - -/** -* Convert Time_t to seconds as a double -*/ -inline double Time_t2SecondsDouble(const rtps::Time_t& t) -{ - return (double)t.seconds() + (double)(t.fraction()/pow(2.0,32)); -} - -/** -* Convert Time_t to seconds as an int64 -*/ -inline int64_t Time_t2MicroSecondsInt64(const rtps::Time_t& t) -{ - return (int64_t)(t.fraction()/pow(2.0,32)*pow(10.0,6)) + t.seconds()*(int64_t)pow(10.0,6); -} - -/** -* Convert Duration_t to seconds as an int64 -*/ -inline int64_t Duration_t2MicroSecondsInt64(const Duration_t& t) -{ - return (int64_t)(t.nanosec/1000.0)+t.seconds*(int64_t)pow(10.0,6); -} - -/** -* Convert Time_t to microseconds as a double -*/ -inline double Time_t2MicroSecondsDouble(const rtps::Time_t& t) -{ - return ((double)t.fraction()/pow(2.0,32)*pow(10.0,6)) + (double)t.seconds()*pow(10.0,6); -} - -/** -* Convert Time_t to milliseconds as an int64 -*/ -inline int64_t Time_t2MilliSecondsInt64(const rtps::Time_t& t) -{ - return (int64_t)(t.fraction()/pow(2.0,32)*pow(10.0,3)) + t.seconds()*(int64_t)pow(10.0,3); -} - -/** -* Convert Time_t to milliseconds as a double -*/ -inline double Time_t2MilliSecondsDouble(const rtps::Time_t& t) -{ - return ((double)t.fraction()/pow(2.0,32)*pow(10.0,3)) + (double)t.seconds()*pow(10.0,3); -} - -/** -* Convert Duration_t to milliseconds as a double -*/ -inline double Duration_t2MilliSecondsDouble(const Duration_t& t) -{ - return ((double)t.nanosec/1000000.0)+(double)t.seconds*pow(10.0,3); -} - -/** -* Convert milliseconds to Time_t -*/ -inline rtps::Time_t MilliSeconds2Time_t(double millisec) -{ - rtps::Time_t t; - t.seconds((int32_t)(millisec/pow(10.0,3))); - t.fraction((uint32_t)((millisec-(double)t.seconds()*pow(10.0,3))/pow(10.0,3)*pow(2.0,32))); - return t; -} - -/** -* Convert microseconds to Time_t -*/ -inline rtps::Time_t MicroSeconds2Time_t(double microsec) -{ - rtps::Time_t t; - t.seconds((int32_t)(microsec/pow(10.0,6))); - t.fraction((uint32_t)((microsec-(double)t.seconds()*pow(10.0,6))/pow(10.0,6)*pow(2.0,32))); - return t; -} - -/** -* Convert seconds to Time_t -*/ -inline rtps::Time_t Seconds2Time_t(double seconds) -{ - rtps::Time_t t; - t.seconds((int32_t)seconds); - t.fraction((uint32_t)((seconds-(double)t.seconds())*pow(2.0,32))); - return t; -} - -/** -* Get the absolute difference between two Time_t in milliseconds as double -*/ -inline double Time_tAbsDiff2DoubleMillisec(const rtps::Time_t& t1, const rtps::Time_t& t2) -{ - double result = 0; - result +=(double)abs((t2.seconds()-t1.seconds())*1000); - result +=(double)std::abs((t2.fraction()-t1.fraction())/pow(2.0,32)*1000); - return result; -} - -//! Create a random Time_t that is millisec + [-randoff,randoff] -inline rtps::Time_t MilliSecondsWithRandOffset2Time_t(double millisec, double randoff) -{ - randoff = std::abs(randoff); - millisec = millisec + (-randoff) + static_cast (rand()) /( static_cast (RAND_MAX/(2*randoff))); - return MilliSeconds2Time_t(millisec); -} -//! Create a random Time_t that is microsec + [-randoff,randoff] -inline rtps::Time_t MicroSecondsWithRandOffset2Time_t(double microsec, double randoff) -{ - randoff = std::abs(randoff); - microsec = microsec + (-randoff) + static_cast (rand()) /( static_cast (RAND_MAX/(2*randoff))); - return MicroSeconds2Time_t(microsec); -} -//! Create a random Time_t that is sec + [-randoff,randoff] -inline rtps::Time_t SecondsWithRandOffset2Time_t(double sec, double randoff) -{ - randoff = std::abs(randoff); - sec = sec + (-randoff) + static_cast (rand()) /( static_cast (RAND_MAX/(2*randoff))); - return Seconds2Time_t(sec); -} - -} -} -} /* namespace rtps */ -} /* namespace eprosima */ - -#endif /* TIMECONVERSION_H_ */ diff --git a/include/fastrtps/utils/collections/foonathan_memory_helpers.hpp b/include/fastrtps/utils/collections/foonathan_memory_helpers.hpp deleted file mode 100644 index 24b963f8d57..00000000000 --- a/include/fastrtps/utils/collections/foonathan_memory_helpers.hpp +++ /dev/null @@ -1,74 +0,0 @@ -// Copyright 2019 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file foonathan_memory_helpers.hpp - * - */ - -#ifndef FASTRTPS_UTILS_COLLECTIONS_FOONATHAN_MEMORY_HELPERS_HPP_ -#define FASTRTPS_UTILS_COLLECTIONS_FOONATHAN_MEMORY_HELPERS_HPP_ - -#include -#include - -#include "ResourceLimitedContainerConfig.hpp" -#include "fastrtps/config.h" - -namespace eprosima { -namespace fastrtps { - -/** - * A helper to calculate the block size of a memory pool given the size of the node and - * a resource limits configuration. - * - * @tparam MemoryPool memory_pool specialization - * - * @param node_size Size of the node for the memory pool - * @param limits Resource limits configuration of the container - * - * @return the block size to pass to the memory pool constructor - */ -template -std::size_t memory_pool_block_size( - std::size_t node_size, - const ResourceLimitedContainerConfig& limits) -{ - FASTDDS_DEPRECATED_UNTIL(3, "eprosima::fastrtps::memory_pool_block_size", "You should not use this method") - namespace fm = foonathan::memory; - - size_t num_elems = limits.increment > 0 ? limits.initial : limits.maximum; - if (num_elems < 1u) - { - num_elems = 1u; - } - - return num_elems - * ((node_size > MemoryPool::min_node_size ? node_size : MemoryPool::min_node_size) // Room for elements -#if FOONATHAN_MEMORY_DEBUG_DOUBLE_DEALLOC_CHECK - * (fm::detail::debug_fence_size ? 3 : 1)) // Room for debug info -#else - + (fm::detail::debug_fence_size ? 2 * fm::detail::max_alignment : 0)) // Room for debug info -#endif // if FOONATHAN_MEMORY_DEBUG_DOUBLE_DEALLOC_CHECK -#ifdef FOONATHAN_MEMORY_MEMORY_POOL_HAS_MIN_BLOCK_SIZE - + fm::detail::memory_block_stack::implementation_offset(); // Room for padding -#else - + fm::detail::memory_block_stack::implementation_offset; // Room for padding -#endif // FOONATHAN_MEMORY_MEMORY_POOL_HAS_MIN_BLOCK_SIZE -} - -} // namespace fastrtps -} // namespace eprosima - -#endif /* FASTRTPS_UTILS_COLLECTIONS_FOONATHAN_MEMORY_HELPERS_HPP_ */ diff --git a/include/fastrtps/utils/fixed_size_string.hpp b/include/fastrtps/utils/fixed_size_string.hpp deleted file mode 100644 index aa1c7c33147..00000000000 --- a/include/fastrtps/utils/fixed_size_string.hpp +++ /dev/null @@ -1,255 +0,0 @@ -// Copyright 2018 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file fixed_size_string.hpp - * - */ - -#ifndef FASTRTPS_UTILS_FIXED_SIZE_STRING_HPP_ -#define FASTRTPS_UTILS_FIXED_SIZE_STRING_HPP_ - -#include -#include - -#ifdef _WIN32 -#define MEMCCPY _memccpy -#else -#define MEMCCPY memccpy -#endif // ifdef _WIN32 - -#ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC -namespace eprosima { -namespace fastrtps { - -/** - * Template class for non-alloc strings. Will be truncated when assigned from a longer string. - * @tparam MAX_CHARS Maximum number of characters is specified as the template parameter. - * Space for an additional null terminator will be reserved. - * @ingroup UTILITIES_MODULE - */ -template -struct fixed_string -{ -public: - - static constexpr size_t max_size = MAX_CHARS; - - /// Default constructor. - fixed_string() noexcept - { - memset(string_data, 0, sizeof(string_data)); - string_len = 0; - } - - // We don't need to define copy/move constructors/assignment operators as the default ones would be enough - - // Construct / assign from a char array - fixed_string( - const char* c_array, - size_t n_chars) noexcept - { - assign(c_array, n_chars); - } - - fixed_string& assign( - const char* c_array, - size_t n_chars) noexcept - { - string_len = (nullptr == c_array) ? 0 : - (MAX_CHARS < n_chars) ? MAX_CHARS : n_chars; - if (0 < string_len) - { - memcpy(string_data, c_array, string_len); - } - return *this; - } - - // Construct / assign from a C string - fixed_string ( - const char* c_string) noexcept - : fixed_string() - { - set(c_string != nullptr ? c_string : ""); - } - - fixed_string& operator = ( - const char* c_string) noexcept - { - set(c_string != nullptr ? c_string : ""); - return *this; - } - - // Construct / assign from a std::string - fixed_string ( - const std::string& str) noexcept - : fixed_string() - { - set(str.c_str()); - } - - fixed_string& operator = ( - const std::string& str) noexcept - { - set(str.c_str()); return *this; - } - - // Assign from fixed_string of any size - template fixed_string& operator = ( - const fixed_string& rhs) noexcept - { - set(rhs.c_str()); return *this; - } - - // Converters to standard types - const char* c_str() const noexcept - { - return string_data; - } - - std::string to_string() const - { - return std::string(string_data); - } - - // Equality comparisons - bool operator == ( - const char* rhs) const noexcept - { - return strncmp(string_data, rhs, MAX_CHARS) == 0; - } - - bool operator == ( - const std::string& rhs) const noexcept - { - return strncmp(string_data, rhs.c_str(), MAX_CHARS) == 0; - } - - template bool operator == ( - const fixed_string& rhs) const noexcept - { - return strncmp(string_data, rhs.c_str(), MAX_CHARS) == 0; - } - - // Inequality comparisons - bool operator != ( - const char* rhs) const noexcept - { - return strncmp(string_data, rhs, MAX_CHARS) != 0; - } - - bool operator != ( - const std::string& rhs) const noexcept - { - return strncmp(string_data, rhs.c_str(), MAX_CHARS) != 0; - } - - template bool operator != ( - const fixed_string& rhs) const noexcept - { - return strncmp(string_data, rhs.c_str(), MAX_CHARS) != 0; - } - - template bool operator < ( - const fixed_string& rhs) const noexcept - { - return 0 > compare(rhs); - } - - template bool operator > ( - const fixed_string& rhs) const noexcept - { - return 0 < compare(rhs); - } - - bool operator < ( - const std::string& rhs) const noexcept - { - return 0 > compare(rhs); - } - - bool operator > ( - const std::string& rhs) const noexcept - { - return 0 < compare(rhs); - } - - operator const char* () const noexcept { - return c_str(); - } - - size_t size() const noexcept - { - return string_len; - } - - /*! - * Compare with a C string. - * - * @param str C string to be compared with. - * - * @return Integer value with the result of the comparison as described in `std::string::compare()`. - */ - int compare( - const char* str) const noexcept - { - return strncmp(string_data, str, MAX_CHARS); - } - - /*! - * Compare with a std::string. - * - * @param str std::string to be compared with. - * - * @return Integer value with the result of the comparison as described in `std::string::compare()`. - */ - int compare( - const std::string& str) const noexcept - { - return strncmp(string_data, str.c_str(), MAX_CHARS); - } - - /*! - * Compare with a fixed_string - * - * @param str fixed_string to be compared with. - * - * @return Integer value with the result of the comparison as described in `std::string::compare()`. - */ - template int compare( - const fixed_string& str) const noexcept - { - return strncmp(string_data, str.c_str(), MAX_CHARS); - } - -private: - - void set( - const char* c_string) noexcept - { - char* result = (char*) MEMCCPY(string_data, c_string, '\0', MAX_CHARS); - string_len = (result == nullptr) ? MAX_CHARS : (size_t)(result - string_data) - 1u; - } - - char string_data[MAX_CHARS + 1]; ///< Holds string data, including ending null character. - size_t string_len; ///< Holds current string length. -}; - -using string_255 = fixed_string<255>; - -} /* namespace fastrtps */ -} /* namespace eprosima */ -#endif // ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC - -#endif /* FASTRTPS_UTILS_FIXED_SIZE_STRING_HPP_ */ diff --git a/include/fastrtps/utils/md5.h b/include/fastrtps/utils/md5.h deleted file mode 100644 index b718947f6e6..00000000000 --- a/include/fastrtps/utils/md5.h +++ /dev/null @@ -1,101 +0,0 @@ -/* MD5 - converted to C++ class by Frank Thilo (thilo@unix-ag.org) - for bzflag (http://www.bzflag.org) - - based on: - - md5.h and md5.c - reference implementation of RFC 1321 - - Copyright (C) 1991-2, RSA Data Security, Inc. Created 1991. All -rights reserved. - -License to copy and use this software is granted provided that it -is identified as the "RSA Data Security, Inc. MD5 Message-Digest -Algorithm" in all material mentioning or referencing this software -or this function. - -License is also granted to make and use derivative works provided -that such works are identified as "derived from the RSA Data -Security, Inc. MD5 Message-Digest Algorithm" in all material -mentioning or referencing the derived work. - -RSA Data Security, Inc. makes no representations concerning either -the merchantability of this software or the suitability of this -software for any particular purpose. It is provided "as is" -without express or implied warranty of any kind. - -These notices must be retained in any copies of any part of this -documentation and/or software. - -*/ - -#ifndef BZF_MD5_H -#define BZF_MD5_H - -#include -#include - -#include "../fastrtps_dll.h" - -/** -* Class MD5, for calculating MD5 hashes of strings or byte arrays -* it is not meant to be fast or secure -* -* usage: 1) feed it blocks of uchars with update() -* 2) finalize() -* 3) get hexdigest() string -* or -* MD5(std::string).hexdigest() -* -* assumes that char is 8 bit and int is 32 bit - * @ingroup UTILITIES_MODULE -*/ -class RTPS_DllAPI MD5 -{ -public: - typedef unsigned char uint1; // 8bit - typedef unsigned int size_type; // must be 32bit - - MD5(); - MD5(const std::string& text); - void update(const unsigned char *buf, size_type length); - void update(const char *buf, size_type length); - MD5& finalize(); - std::string hexdigest() const; - friend std::ostream& operator<<(std::ostream&, MD5& md5); - uint1 digest[16]; // the result - - void init(); -private: - - - typedef unsigned int uint4; // 32bit - enum {blocksize = 64}; // VC6 won't eat a const static int here - - void transform(const uint1 block[blocksize]); - static void decode(uint4 output[], const uint1 input[], size_type len); - static void encode(uint1 output[], const uint4 input[], size_type len); - - bool finalized; - uint1 buffer[blocksize]; // bytes that didn't fit in last 64 byte chunk - uint4 count[2]; // 64bit counter for number of bits (lo, hi) - uint4 state[4]; // digest so far - - - // low level logic operations - static inline uint4 F(uint4 x, uint4 y, uint4 z); - static inline uint4 G(uint4 x, uint4 y, uint4 z); - static inline uint4 H(uint4 x, uint4 y, uint4 z); - static inline uint4 I(uint4 x, uint4 y, uint4 z); - static inline uint4 rotate_left(uint4 x, int n); - static inline void FF(uint4 &a, uint4 b, uint4 c, uint4 d, uint4 x, uint4 s, uint4 ac); - static inline void GG(uint4 &a, uint4 b, uint4 c, uint4 d, uint4 x, uint4 s, uint4 ac); - static inline void HH(uint4 &a, uint4 b, uint4 c, uint4 d, uint4 x, uint4 s, uint4 ac); - static inline void II(uint4 &a, uint4 b, uint4 c, uint4 d, uint4 x, uint4 s, uint4 ac); -}; - -std::string md5(const std::string str); - -#endif - diff --git a/m4/ax_check_openssl.m4 b/m4/ax_check_openssl.m4 deleted file mode 100644 index 28e48cbefb6..00000000000 --- a/m4/ax_check_openssl.m4 +++ /dev/null @@ -1,124 +0,0 @@ -# =========================================================================== -# https://www.gnu.org/software/autoconf-archive/ax_check_openssl.html -# =========================================================================== -# -# SYNOPSIS -# -# AX_CHECK_OPENSSL([action-if-found[, action-if-not-found]]) -# -# DESCRIPTION -# -# Look for OpenSSL in a number of default spots, or in a user-selected -# spot (via --with-openssl). Sets -# -# OPENSSL_INCLUDES to the include directives required -# OPENSSL_LIBS to the -l directives required -# OPENSSL_LDFLAGS to the -L or -R flags required -# -# and calls ACTION-IF-FOUND or ACTION-IF-NOT-FOUND appropriately -# -# This macro sets OPENSSL_INCLUDES such that source files should use the -# openssl/ directory in include directives: -# -# #include -# -# LICENSE -# -# Copyright (c) 2009,2010 Zmanda Inc. -# Copyright (c) 2009,2010 Dustin J. Mitchell -# -# Copying and distribution of this file, with or without modification, are -# permitted in any medium without royalty provided the copyright notice -# and this notice are preserved. This file is offered as-is, without any -# warranty. - -#serial 10 - -AU_ALIAS([CHECK_SSL], [AX_CHECK_OPENSSL]) -AC_DEFUN([AX_CHECK_OPENSSL], [ - found=false - AC_ARG_WITH([openssl], - [AS_HELP_STRING([--with-openssl=DIR], - [root of the OpenSSL directory])], - [ - case "$withval" in - "" | y | ye | yes | n | no) - AC_MSG_ERROR([Invalid --with-openssl value]) - ;; - *) ssldirs="$withval" - ;; - esac - ], [ - # if pkg-config is installed and openssl has installed a .pc file, - # then use that information and don't search ssldirs - AC_CHECK_TOOL([PKG_CONFIG], [pkg-config]) - if test x"$PKG_CONFIG" != x""; then - OPENSSL_LDFLAGS=`$PKG_CONFIG openssl --libs-only-L 2>/dev/null` - if test $? = 0; then - OPENSSL_LIBS=`$PKG_CONFIG openssl --libs-only-l 2>/dev/null` - OPENSSL_INCLUDES=`$PKG_CONFIG openssl --cflags-only-I 2>/dev/null` - found=true - fi - fi - - # no such luck; use some default ssldirs - if ! $found; then - ssldirs="/usr/local/ssl /usr/lib/ssl /usr/ssl /usr/pkg /usr/local /usr" - fi - ] - ) - - - # note that we #include , so the OpenSSL headers have to be in - # an 'openssl' subdirectory - - if ! $found; then - OPENSSL_INCLUDES= - for ssldir in $ssldirs; do - AC_MSG_CHECKING([for openssl/ssl.h in $ssldir]) - if test -f "$ssldir/include/openssl/ssl.h"; then - OPENSSL_INCLUDES="-I$ssldir/include" - OPENSSL_LDFLAGS="-L$ssldir/lib" - OPENSSL_LIBS="-lssl -lcrypto" - found=true - AC_MSG_RESULT([yes]) - break - else - AC_MSG_RESULT([no]) - fi - done - - # if the file wasn't found, well, go ahead and try the link anyway -- maybe - # it will just work! - fi - - # try the preprocessor and linker with our new flags, - # being careful not to pollute the global LIBS, LDFLAGS, and CPPFLAGS - - AC_MSG_CHECKING([whether compiling and linking against OpenSSL works]) - echo "Trying link with OPENSSL_LDFLAGS=$OPENSSL_LDFLAGS;" \ - "OPENSSL_LIBS=$OPENSSL_LIBS; OPENSSL_INCLUDES=$OPENSSL_INCLUDES" >&AS_MESSAGE_LOG_FD - - save_LIBS="$LIBS" - save_LDFLAGS="$LDFLAGS" - save_CPPFLAGS="$CPPFLAGS" - LDFLAGS="$LDFLAGS $OPENSSL_LDFLAGS" - LIBS="$OPENSSL_LIBS $LIBS" - CPPFLAGS="$OPENSSL_INCLUDES $CPPFLAGS" - AC_LINK_IFELSE( - [AC_LANG_PROGRAM([#include ], [SSL_new(NULL)])], - [ - AC_MSG_RESULT([yes]) - $1 - ], [ - AC_MSG_RESULT([no]) - $2 - ]) - CPPFLAGS="$save_CPPFLAGS" - LDFLAGS="$save_LDFLAGS" - LIBS="$save_LIBS" - - AC_SUBST([OPENSSL_INCLUDES]) - AC_SUBST([OPENSSL_LIBS]) - AC_SUBST([OPENSSL_LDFLAGS]) -]) diff --git a/m4/ax_cxx_compile_stdcxx_0x.m4 b/m4/ax_cxx_compile_stdcxx_0x.m4 deleted file mode 100644 index 719f92c62cf..00000000000 --- a/m4/ax_cxx_compile_stdcxx_0x.m4 +++ /dev/null @@ -1,109 +0,0 @@ -# ============================================================================ -# http://www.gnu.org/software/autoconf-archive/ax_cxx_compile_stdcxx_0x.html -# ============================================================================ -# -# SYNOPSIS -# -# AX_CXX_COMPILE_STDCXX_0X -# -# DESCRIPTION -# -# Check for baseline language coverage in the compiler for the C++0x -# standard. -# -# LICENSE -# -# Copyright (c) 2008 Benjamin Kosnik -# -# Copying and distribution of this file, with or without modification, are -# permitted in any medium without royalty provided the copyright notice -# and this notice are preserved. This file is offered as-is, without any -# warranty. - -#serial 8 - -AU_ALIAS([AC_CXX_COMPILE_STDCXX_0X], [AX_CXX_COMPILE_STDCXX_0X]) -AC_DEFUN([AX_CXX_COMPILE_STDCXX_0X], [ - AC_CACHE_CHECK(if g++ supports C++0x features without additional flags, - ax_cv_cxx_compile_cxx0x_native, - [AC_LANG_SAVE - AC_LANG_CPLUSPLUS - AC_TRY_COMPILE([ - template - struct check - { - static_assert(sizeof(int) <= sizeof(T), "not big enough"); - }; - - typedef check> right_angle_brackets; - - int a; - decltype(a) b; - - typedef check check_type; - check_type c; - check_type&& cr = static_cast(c);],, - ax_cv_cxx_compile_cxx0x_native=yes, ax_cv_cxx_compile_cxx0x_native=no) - AC_LANG_RESTORE - ]) - - AC_CACHE_CHECK(if g++ supports C++0x features with -std=c++0x, - ax_cv_cxx_compile_cxx0x_cxx, - [AC_LANG_SAVE - AC_LANG_CPLUSPLUS - ac_save_CXXFLAGS="$CXXFLAGS" - CXXFLAGS="$CXXFLAGS -std=c++0x" - AC_TRY_COMPILE([ - template - struct check - { - static_assert(sizeof(int) <= sizeof(T), "not big enough"); - }; - - typedef check> right_angle_brackets; - - int a; - decltype(a) b; - - typedef check check_type; - check_type c; - check_type&& cr = static_cast(c);],, - ax_cv_cxx_compile_cxx0x_cxx=yes, ax_cv_cxx_compile_cxx0x_cxx=no) - CXXFLAGS="$ac_save_CXXFLAGS" - AC_LANG_RESTORE - ]) - - AC_CACHE_CHECK(if g++ supports C++0x features with -std=gnu++0x, - ax_cv_cxx_compile_cxx0x_gxx, - [AC_LANG_SAVE - AC_LANG_CPLUSPLUS - ac_save_CXXFLAGS="$CXXFLAGS" - CXXFLAGS="$CXXFLAGS -std=gnu++0x" - AC_TRY_COMPILE([ - template - struct check - { - static_assert(sizeof(int) <= sizeof(T), "not big enough"); - }; - - typedef check> right_angle_brackets; - - int a; - decltype(a) b; - - typedef check check_type; - check_type c; - check_type&& cr = static_cast(c);],, - ax_cv_cxx_compile_cxx0x_gxx=yes, ax_cv_cxx_compile_cxx0x_gxx=no) - CXXFLAGS="$ac_save_CXXFLAGS" - AC_LANG_RESTORE - ]) - - if test "$ax_cv_cxx_compile_cxx0x_native" = yes || - test "$ax_cv_cxx_compile_cxx0x_cxx" = yes || - test "$ax_cv_cxx_compile_cxx0x_gxx" = yes; then - AC_DEFINE(HAVE_CXX0X, 1,[Define if g++ supports C++0x features. ]) - else - AC_DEFINE(HAVE_CXX0X, 0,[Define if g++ supports C++0x features. ]) - fi -]) diff --git a/m4/ax_cxx_compile_stdcxx_11.m4 b/m4/ax_cxx_compile_stdcxx_11.m4 deleted file mode 100644 index 395b13d2a6d..00000000000 --- a/m4/ax_cxx_compile_stdcxx_11.m4 +++ /dev/null @@ -1,167 +0,0 @@ -# ============================================================================ -# http://www.gnu.org/software/autoconf-archive/ax_cxx_compile_stdcxx_11.html -# ============================================================================ -# -# SYNOPSIS -# -# AX_CXX_COMPILE_STDCXX_11([ext|noext],[mandatory|optional]) -# -# DESCRIPTION -# -# Check for baseline language coverage in the compiler for the C++11 -# standard; if necessary, add switches to CXXFLAGS to enable support. -# -# The first argument, if specified, indicates whether you insist on an -# extended mode (e.g. -std=gnu++11) or a strict conformance mode (e.g. -# -std=c++11). If neither is specified, you get whatever works, with -# preference for an extended mode. -# -# The second argument, if specified 'mandatory' or if left unspecified, -# indicates that baseline C++11 support is required and that the macro -# should error out if no mode with that support is found. If specified -# 'optional', then configuration proceeds regardless, after defining -# HAVE_CXX11 if and only if a supporting mode is found. -# -# LICENSE -# -# Copyright (c) 2008 Benjamin Kosnik -# Copyright (c) 2012 Zack Weinberg -# Copyright (c) 2013 Roy Stogner -# Copyright (c) 2014, 2015 Google Inc.; contributed by Alexey Sokolov -# -# Copying and distribution of this file, with or without modification, are -# permitted in any medium without royalty provided the copyright notice -# and this notice are preserved. This file is offered as-is, without any -# warranty. - -#serial 11 - -m4_define([_AX_CXX_COMPILE_STDCXX_11_testbody], [[ - template - struct check - { - static_assert(sizeof(int) <= sizeof(T), "not big enough"); - }; - - struct Base { - virtual void f() {} - }; - struct Child : public Base { - virtual void f() override {} - }; - - typedef check> right_angle_brackets; - - int a; - decltype(a) b; - - typedef check check_type; - check_type c; - check_type&& cr = static_cast(c); - - auto d = a; - auto l = [](){}; - // Prevent Clang error: unused variable 'l' [-Werror,-Wunused-variable] - struct use_l { use_l() { l(); } }; - - // http://stackoverflow.com/questions/13728184/template-aliases-and-sfinae - // Clang 3.1 fails with headers of libstd++ 4.8.3 when using std::function because of this - namespace test_template_alias_sfinae { - struct foo {}; - - template - using member = typename T::member_type; - - template - void func(...) {} - - template - void func(member*) {} - - void test(); - - void test() { - func(0); - } - } -]]) - -AC_DEFUN([AX_CXX_COMPILE_STDCXX_11], [dnl - m4_if([$1], [], [], - [$1], [ext], [], - [$1], [noext], [], - [m4_fatal([invalid argument `$1' to AX_CXX_COMPILE_STDCXX_11])])dnl - m4_if([$2], [], [ax_cxx_compile_cxx11_required=true], - [$2], [mandatory], [ax_cxx_compile_cxx11_required=true], - [$2], [optional], [ax_cxx_compile_cxx11_required=false], - [m4_fatal([invalid second argument `$2' to AX_CXX_COMPILE_STDCXX_11])]) - AC_LANG_PUSH([C++])dnl - ac_success=no - AC_CACHE_CHECK(whether $CXX supports C++11 features by default, - ax_cv_cxx_compile_cxx11, - [AC_COMPILE_IFELSE([AC_LANG_SOURCE([_AX_CXX_COMPILE_STDCXX_11_testbody])], - [ax_cv_cxx_compile_cxx11=yes], - [ax_cv_cxx_compile_cxx11=no])]) - if test x$ax_cv_cxx_compile_cxx11 = xyes; then - ac_success=yes - fi - - m4_if([$1], [noext], [], [dnl - if test x$ac_success = xno; then - for switch in -std=gnu++11 -std=gnu++0x; do - cachevar=AS_TR_SH([ax_cv_cxx_compile_cxx11_$switch]) - AC_CACHE_CHECK(whether $CXX supports C++11 features with $switch, - $cachevar, - [ac_save_CXXFLAGS="$CXXFLAGS" - CXXFLAGS="$CXXFLAGS $switch" - AC_COMPILE_IFELSE([AC_LANG_SOURCE([_AX_CXX_COMPILE_STDCXX_11_testbody])], - [eval $cachevar=yes], - [eval $cachevar=no]) - CXXFLAGS="$ac_save_CXXFLAGS"]) - if eval test x\$$cachevar = xyes; then - CXXFLAGS="$CXXFLAGS $switch" - ac_success=yes - break - fi - done - fi]) - - m4_if([$1], [ext], [], [dnl - if test x$ac_success = xno; then - dnl HP's aCC needs +std=c++11 according to: - dnl http://h21007.www2.hp.com/portal/download/files/unprot/aCxx/PDF_Release_Notes/769149-001.pdf - for switch in -std=c++11 -std=c++0x +std=c++11; do - cachevar=AS_TR_SH([ax_cv_cxx_compile_cxx11_$switch]) - AC_CACHE_CHECK(whether $CXX supports C++11 features with $switch, - $cachevar, - [ac_save_CXXFLAGS="$CXXFLAGS" - CXXFLAGS="$CXXFLAGS $switch" - AC_COMPILE_IFELSE([AC_LANG_SOURCE([_AX_CXX_COMPILE_STDCXX_11_testbody])], - [eval $cachevar=yes], - [eval $cachevar=no]) - CXXFLAGS="$ac_save_CXXFLAGS"]) - if eval test x\$$cachevar = xyes; then - CXXFLAGS="$CXXFLAGS $switch" - ac_success=yes - break - fi - done - fi]) - AC_LANG_POP([C++]) - if test x$ax_cxx_compile_cxx11_required = xtrue; then - if test x$ac_success = xno; then - AC_MSG_ERROR([*** A compiler with support for C++11 language features is required.]) - fi - else - if test x$ac_success = xno; then - HAVE_CXX11=0 - AC_MSG_NOTICE([No compiler with C++11 support was found]) - else - HAVE_CXX11=1 - AC_DEFINE(HAVE_CXX11,1, - [define if the compiler supports basic C++11 syntax]) - fi - - AC_SUBST(HAVE_CXX11) - fi -]) diff --git a/package.xml b/package.xml index 138d7d371ec..c5d39b49c0c 100644 --- a/package.xml +++ b/package.xml @@ -1,10 +1,10 @@ - fastrtps - 2.14.1 + fastdds + 3.0.0 - *eprosima Fast DDS* (formerly Fast RTPS) is a C++ implementation of the DDS (Data Distribution Service) standard of the OMG (Object Management Group). eProsima Fast DDS implements the RTPS (Real Time Publish Subscribe) protocol, which provides publisher-subscriber communications over unreliable transports such as UDP, as defined and maintained by the Object Management Group (OMG) consortium. RTPS is also the wire interoperability protocol defined for the Data Distribution Service (DDS) standard. *eProsima Fast DDS* expose an API to access directly the RTPS protocol, giving the user full access to the protocol internals. + *eprosima Fast DDS* is a C++ implementation of the DDS (Data Distribution Service) standard of the OMG (Object Management Group). eProsima Fast DDS implements the RTPS (Real Time Publish Subscribe) protocol, which provides publisher-subscriber communications over unreliable transports such as UDP, as defined and maintained by the Object Management Group (OMG) consortium. RTPS is also the wire interoperability protocol defined for the Data Distribution Service (DDS) standard. *eProsima Fast DDS* expose an API to access directly the RTPS protocol, giving the user full access to the protocol internals. Miguel Company Eduardo Ponz diff --git a/doc/images/fastdds_github_banner.png b/resources/images/fastdds_github_banner.png similarity index 100% rename from doc/images/fastdds_github_banner.png rename to resources/images/fastdds_github_banner.png diff --git a/utils/images/logo/eProsimaLogo.jpg b/resources/images/logo/eProsimaLogo.jpg similarity index 100% rename from utils/images/logo/eProsimaLogo.jpg rename to resources/images/logo/eProsimaLogo.jpg diff --git a/utils/images/logo/eProsimaLogo.png b/resources/images/logo/eProsimaLogo.png similarity index 100% rename from utils/images/logo/eProsimaLogo.png rename to resources/images/logo/eProsimaLogo.png diff --git a/resources/xsd/fastRTPS_profiles.xsd b/resources/xsd/fastdds_profiles.xsd similarity index 96% rename from resources/xsd/fastRTPS_profiles.xsd rename to resources/xsd/fastdds_profiles.xsd index 17f28870206..aa1845d84d4 100644 --- a/resources/xsd/fastRTPS_profiles.xsd +++ b/resources/xsd/fastdds_profiles.xsd @@ -1,7 +1,7 @@ @@ -40,7 +40,9 @@ ├ data_writer [0~*], ├ data_reader [0~*], ├ transport_descriptors [0~1], - └ topic [0~*] --> + ├ topic [0~1], + ├ replier [0~1], + └ requester [0~*] --> @@ -50,6 +52,8 @@ + + @@ -138,6 +142,7 @@ ├ builtin_controllers_sender_thread [threadSettingsType], ├ timed_events_thread [threadSettingsType], ├ discovery_server_thread [threadSettingsType], + ├ typelookup_service_thread [threadSettingsType], ├ builtin_transports_reception_threads [threadSettingsType], └ security_log_thread [threadSettingsType]--> @@ -182,6 +187,7 @@ + @@ -211,10 +217,7 @@ - - + @@ -242,14 +245,34 @@ - - - + + + + + + + + + + - + @@ -279,8 +302,32 @@ - - + + + + + + + + + + + + + + + + + + + + + + + └ mutation_tries [uint32]--> @@ -665,7 +733,6 @@ - @@ -758,16 +825,6 @@ - - - - - - - - diff --git a/test/performance/latency/xml/latency_interprocess_best_effort_tcp_profile.xml b/test/performance/latency/xml/latency_interprocess_best_effort_tcp_profile.xml index a1c1034ac3f..a5e7c693e05 100644 --- a/test/performance/latency/xml/latency_interprocess_best_effort_tcp_profile.xml +++ b/test/performance/latency/xml/latency_interprocess_best_effort_tcp_profile.xml @@ -1,5 +1,5 @@ - + diff --git a/test/performance/latency/xml/latency_interprocess_best_effort_udp_profile.xml b/test/performance/latency/xml/latency_interprocess_best_effort_udp_profile.xml index a12534f93e9..f5c79a0deed 100644 --- a/test/performance/latency/xml/latency_interprocess_best_effort_udp_profile.xml +++ b/test/performance/latency/xml/latency_interprocess_best_effort_udp_profile.xml @@ -1,5 +1,5 @@ - + diff --git a/test/performance/latency/xml/latency_interprocess_reliable_shm_profile.xml b/test/performance/latency/xml/latency_interprocess_reliable_shm_profile.xml index e69f7eb1b54..a0be5e11182 100644 --- a/test/performance/latency/xml/latency_interprocess_reliable_shm_profile.xml +++ b/test/performance/latency/xml/latency_interprocess_reliable_shm_profile.xml @@ -1,5 +1,5 @@ - + diff --git a/test/performance/latency/xml/latency_interprocess_reliable_tcp_profile.xml b/test/performance/latency/xml/latency_interprocess_reliable_tcp_profile.xml index dd734a48dfc..e13bd704149 100644 --- a/test/performance/latency/xml/latency_interprocess_reliable_tcp_profile.xml +++ b/test/performance/latency/xml/latency_interprocess_reliable_tcp_profile.xml @@ -1,5 +1,5 @@ - + diff --git a/test/performance/latency/xml/latency_interprocess_reliable_udp_profile.xml b/test/performance/latency/xml/latency_interprocess_reliable_udp_profile.xml index b5446072dfb..c81ed2b82ec 100644 --- a/test/performance/latency/xml/latency_interprocess_reliable_udp_profile.xml +++ b/test/performance/latency/xml/latency_interprocess_reliable_udp_profile.xml @@ -1,5 +1,5 @@ - + diff --git a/test/performance/latency/xml/latency_intraprocess_best_effort_profile.xml b/test/performance/latency/xml/latency_intraprocess_best_effort_profile.xml index 14994632d77..69a2a43b9cf 100644 --- a/test/performance/latency/xml/latency_intraprocess_best_effort_profile.xml +++ b/test/performance/latency/xml/latency_intraprocess_best_effort_profile.xml @@ -1,5 +1,5 @@ - + diff --git a/test/performance/latency/xml/latency_intraprocess_reliable_profile.xml b/test/performance/latency/xml/latency_intraprocess_reliable_profile.xml index 63dea13e838..322f257c6c4 100644 --- a/test/performance/latency/xml/latency_intraprocess_reliable_profile.xml +++ b/test/performance/latency/xml/latency_intraprocess_reliable_profile.xml @@ -1,5 +1,5 @@ - + diff --git a/test/performance/throughput/CMakeLists.txt b/test/performance/throughput/CMakeLists.txt index 30cb02437d5..1949c2787e9 100644 --- a/test/performance/throughput/CMakeLists.txt +++ b/test/performance/throughput/CMakeLists.txt @@ -34,7 +34,7 @@ target_include_directories(ThroughputTest PRIVATE ${Asio_INCLUDE_DIR}) target_link_libraries( ThroughputTest - fastrtps + fastdds fastcdr foonathan_memory fastdds::optionparser diff --git a/test/performance/throughput/README.md b/test/performance/throughput/README.md index 1a11f020c30..e4d4c77f418 100644 --- a/test/performance/throughput/README.md +++ b/test/performance/throughput/README.md @@ -56,7 +56,7 @@ The columns show the next information: This utility can be enabled by using the CMake option `PERFORMANCE_TESTS`. Following the Fast DDS [*Installation from sources* guide](https://fast-dds.docs.eprosima.com/en/latest/installation/sources/sources_linux.html), - Fast-DDS and this utility can be compiled executing the next command. + Fast DDS and this utility can be compiled executing the next command. ``` colcon build --cmake-args -DPERFORMANCE_TESTS=ON @@ -65,7 +65,7 @@ colcon build --cmake-args -DPERFORMANCE_TESTS=ON The throughput test executable can be found in the `build` directory. ``` -build/fastrtps/test/performance/throughput +build/fastdds/test/performance/throughput ├── CMakeFiles ├── cmake_install.cmake ├── CTestTestfile.cmake @@ -98,9 +98,9 @@ The utility offers several options: | - | - | | --reliability=[reliable/besteffort] | Set the Reliability QoS of the DDS entity | | --domain \ | Set the DDS domain to be used. Default domain is a random one. If testing in separate processes, always set the domain using this argument | -| --data_sharing=[on/off] | Explicitly enable/disable Data Sharing feature. Fast-DDS default is *auto* | +| --data_sharing=[on/off] | Explicitly enable/disable Data Sharing feature. Fast DDS default is *auto* | | --data_load | Enables the use of Data Loans feature | -| --shared_memory | Explicitly enable/disable Shared Memory transport. Fast-DDS default is *on* | +| --shared_memory | Explicitly enable/disable Shared Memory transport. Fast DDS default is *on* | | --security=[true/false] | Enable/disable DDS security | | --certs=\ | Directory with the certificates. Used when security is enable | @@ -167,10 +167,10 @@ The directory also comes with a Python script which automates the execution of t ```batch # Indicate where is the utility executable -export THROUGHPUT_TEST_BIN=build/fastrtps/test/performance/throughtput/ThroughputTest +export THROUGHPUT_TEST_BIN=build/fastdds/test/performance/throughtput/ThroughputTest # Call python script to run tests. -python3 src/fastrtps/test/performance/throughput/throughput_tests.py +python3 src/fastdds/test/performance/throughput/throughput_tests.py ``` The python scripts offers several options: @@ -179,7 +179,7 @@ The python scripts offers several options: | - | - | | --reliability | Set the Reliability QoS of the DDS entities to reliable. Default Reliability is best-effort | | --data_loans | Enable the use of the loan sample API. Default is disable | -| --shared_memory [on/off] | Explicitly enable/disable shared memory transport. Fast-DDS default is *on* | +| --shared_memory [on/off] | Explicitly enable/disable shared memory transport. Fast DDS default is *on* | | --interprocess | Publisher and subscriber in separate processes. Default is both in the sample process and using intraprocess communications | | --security | Enable security. Default disable | | -t \ | Test time in seconds. Default is *1 second* | diff --git a/test/performance/throughput/ThroughputPublisher.cpp b/test/performance/throughput/ThroughputPublisher.cpp index 3e5a668d6cf..1395cf9747d 100644 --- a/test/performance/throughput/ThroughputPublisher.cpp +++ b/test/performance/throughput/ThroughputPublisher.cpp @@ -32,14 +32,16 @@ #include #include #include +#include +#include +#include +#include +#include #include #include -#include -#include using namespace eprosima::fastdds::dds; using namespace eprosima::fastrtps::rtps; -using namespace eprosima::fastrtps::types; // ******************************************************************************************* // ********************************* DATA WRITER LISTENER ************************************ @@ -155,7 +157,7 @@ bool ThroughputPublisher::init( // Load XML configuration if (xml_config_file_.length() > 0) { - if ( ReturnCode_t::RETCODE_OK != + if ( RETCODE_OK != DomainParticipantFactory::get_instance()-> get_participant_qos_from_profile( participant_profile_name, @@ -212,7 +214,7 @@ bool ThroughputPublisher::init( throughput_command_type_.reset(new ThroughputCommandDataType()); // Register the command data type - if (ReturnCode_t::RETCODE_OK + if (RETCODE_OK != throughput_command_type_.register_type(participant_)) { EPROSIMA_LOG_ERROR(THROUGHPUTPUBLISHER, "ERROR registering command type"); @@ -239,7 +241,7 @@ bool ThroughputPublisher::init( std::string profile_name = "publisher_profile"; if (xml_config_file_.length() > 0 - && ReturnCode_t::RETCODE_OK != publisher_->get_datawriter_qos_from_profile(profile_name, dw_qos_)) + && RETCODE_OK != publisher_->get_datawriter_qos_from_profile(profile_name, dw_qos_)) { EPROSIMA_LOG_ERROR(THROUGHPUTPUBLISHER, "ERROR unable to retrieve the " << profile_name); return false; @@ -252,7 +254,7 @@ bool ThroughputPublisher::init( ReliabilityQosPolicy rp; if (reliable_) { - rp.kind = eprosima::fastrtps::RELIABLE_RELIABILITY_QOS; + rp.kind = eprosima::fastdds::dds::RELIABLE_RELIABILITY_QOS; dw_qos_.reliability(rp); RTPSReliableWriterQos rw_qos; @@ -265,7 +267,7 @@ bool ThroughputPublisher::init( } else { - rp.kind = eprosima::fastrtps::BEST_EFFORT_RELIABILITY_QOS; + rp.kind = eprosima::fastdds::dds::BEST_EFFORT_RELIABILITY_QOS; dw_qos_.reliability(rp); } @@ -426,7 +428,7 @@ void ThroughputPublisher::run( uint32_t test_time, uint32_t recovery_time_ms, int demand, - int msg_size, + uint32_t msg_size, uint32_t subscribers) { subscribers_ = subscribers; @@ -547,26 +549,25 @@ void ThroughputPublisher::run( { assert(nullptr == dynamic_data_); // Create the data sample - MemberId id; - dynamic_data_ = static_cast(dynamic_pub_sub_type_->createData()); + dynamic_data_ = static_cast(dynamic_pub_sub_type_->createData()); if (nullptr == dynamic_data_) { - EPROSIMA_LOG_ERROR(THROUGHPUTPUBLISHER, "Iteration failed: Failed to create Dynamic Data"); + EPROSIMA_LOG_ERROR(THROUGHPUTPUBLISHER, + "Iteration failed: Failed to create Dynamic Data"); return; } // Modify the data Sample - dynamic_data_->set_uint32_value(0, 0); - DynamicData* member_data = dynamic_data_->loan_value( - dynamic_data_->get_member_id_at_index(1)); + (*dynamic_data_)->set_uint32_value(0, 0); + DynamicData::_ref_type member_data = (*dynamic_data_)->loan_value( + (*dynamic_data_)->get_member_id_at_index(1)); - for (int i = 0; i < msg_size; ++i) + for (uint32_t i = 0; i < msg_size; ++i) { - member_data->insert_sequence_data(id); - member_data->set_byte_value(0, id); + member_data->set_byte_value(i, 0); } - dynamic_data_->return_loaned_value(member_data); + (*dynamic_data_)->return_loaned_value(member_data); } else { @@ -641,7 +642,7 @@ void ThroughputPublisher::run( // Delete the Data Sample if (dynamic_types_) { - DynamicDataFactory::get_instance()->delete_data(dynamic_data_); + dynamic_pub_sub_type_.delete_data(dynamic_data_); dynamic_data_ = nullptr; } else @@ -683,7 +684,7 @@ void ThroughputPublisher::run( return; } - bool all_acked = command_writer_->wait_for_acknowledgments({20, 0}) == ReturnCode_t::RETCODE_OK; + bool all_acked = command_writer_->wait_for_acknowledgments({20, 0}) == RETCODE_OK; print_results(results_); if (!all_acked) @@ -716,7 +717,7 @@ bool ThroughputPublisher::test( // If the subscriber does not acknowledge the TEST_STARTS in time, we consider something went wrong. std::chrono::steady_clock::time_point test_start_sent_tp = std::chrono::steady_clock::now(); - if (ReturnCode_t::RETCODE_OK != command_writer_->wait_for_acknowledgments({20, 0})) + if (RETCODE_OK != command_writer_->wait_for_acknowledgments({20, 0})) { EPROSIMA_LOG_ERROR(THROUGHPUTPUBLISHER, "Something went wrong: The subscriber has not acknowledged the TEST_STARTS command."); @@ -738,14 +739,14 @@ bool ThroughputPublisher::test( { if (dynamic_types_) { - dynamic_data_->set_uint32_value(++seqnum, 0); + (*dynamic_data_)->set_uint32_value(0, ++seqnum); data_writer_->write(dynamic_data_); } else if (data_loans_) { // Try loan a sample void* data = nullptr; - if (ReturnCode_t::RETCODE_OK + if (RETCODE_OK == data_writer_->loan_sample( data, DataWriter::LoanInitializationKind::NO_LOAN_INITIALIZATION)) @@ -797,7 +798,7 @@ bool ThroughputPublisher::test( command_writer_->write(&command_sample); // If the subscriber does not acknowledge the TEST_ENDS in time, we consider something went wrong. - if (ReturnCode_t::RETCODE_OK + if (RETCODE_OK != command_writer_->wait_for_acknowledgments({20, 0})) { EPROSIMA_LOG_ERROR(THROUGHPUTPUBLISHER, @@ -811,7 +812,7 @@ bool ThroughputPublisher::test( while ( !results_error && num_results_received < subscribers_ ) { if (command_reader_->wait_for_unread_message({20, 0}) - && ReturnCode_t::RETCODE_OK == command_reader_->take_next_sample(&command_sample, &info) + && RETCODE_OK == command_reader_->take_next_sample(&command_sample, &info) && info.valid_data) { if (command_sample.m_command == TEST_RESULTS) @@ -1041,18 +1042,27 @@ bool ThroughputPublisher::init_dynamic_types() } // Dummy type registration + DynamicTypeBuilderFactory::_ref_type factory {DynamicTypeBuilderFactory::get_instance()}; // Create basic builders - DynamicTypeBuilder_ptr struct_type_builder(DynamicTypeBuilderFactory::get_instance()->create_struct_builder()); + TypeDescriptor::_ref_type type_descriptor {traits::make_shared()}; + type_descriptor->kind(TK_STRUCTURE); + type_descriptor->name(ThroughputDataType::type_name_); + + DynamicTypeBuilder::_ref_type struct_type_builder {factory->create_type(type_descriptor)}; // Add members to the struct. - struct_type_builder->add_member(0, "seqnum", DynamicTypeBuilderFactory::get_instance()->create_uint32_type()); - struct_type_builder->add_member(1, "data", DynamicTypeBuilderFactory::get_instance()->create_sequence_builder( - DynamicTypeBuilderFactory::get_instance()->create_byte_type(), BOUND_UNLIMITED)); - struct_type_builder->set_name(ThroughputDataType::type_name_); + MemberDescriptor::_ref_type member_descriptor {traits::make_shared()}; + member_descriptor->name("seqnum"); + member_descriptor->type(factory->get_primitive_type(TK_UINT32)); + struct_type_builder->add_member(member_descriptor); + member_descriptor->name("data"); + member_descriptor->type(factory->create_sequence_type( + factory->get_primitive_type(TK_BYTE), static_cast(LENGTH_UNLIMITED))->build()); + struct_type_builder->add_member(member_descriptor); dynamic_pub_sub_type_.reset(new DynamicPubSubType(struct_type_builder->build())); // Register the data type - if (ReturnCode_t::RETCODE_OK + if (RETCODE_OK != dynamic_pub_sub_type_.register_type(participant_)) { EPROSIMA_LOG_ERROR(THROUGHPUTPUBLISHER, "ERROR registering the DYNAMIC DATA topic"); @@ -1082,7 +1092,7 @@ bool ThroughputPublisher::init_static_types( // Create the static type throughput_data_type_.reset(new ThroughputDataType(payload)); // Register the static type - if (ReturnCode_t::RETCODE_OK + if (RETCODE_OK != throughput_data_type_.register_type(participant_)) { return false; @@ -1146,7 +1156,7 @@ bool ThroughputPublisher::destroy_data_endpoints() // Delete the endpoint if (nullptr == data_writer_ - || ReturnCode_t::RETCODE_OK != publisher_->delete_datawriter(data_writer_)) + || RETCODE_OK != publisher_->delete_datawriter(data_writer_)) { EPROSIMA_LOG_ERROR(THROUGHPUTPUBLISHER, "ERROR destroying the DataWriter"); return false; @@ -1156,7 +1166,7 @@ bool ThroughputPublisher::destroy_data_endpoints() // Delete the Topic if (nullptr == data_pub_topic_ - || ReturnCode_t::RETCODE_OK != participant_->delete_topic(data_pub_topic_)) + || RETCODE_OK != participant_->delete_topic(data_pub_topic_)) { EPROSIMA_LOG_ERROR(THROUGHPUTPUBLISHER, "ERROR destroying the DATA topic"); return false; @@ -1164,7 +1174,7 @@ bool ThroughputPublisher::destroy_data_endpoints() data_pub_topic_ = nullptr; // Delete the Type - if (ReturnCode_t::RETCODE_OK + if (RETCODE_OK != participant_->unregister_type(ThroughputDataType::type_name_)) { EPROSIMA_LOG_ERROR(THROUGHPUTPUBLISHER, "ERROR unregistering the DATA type"); diff --git a/test/performance/throughput/ThroughputPublisher.hpp b/test/performance/throughput/ThroughputPublisher.hpp index d9cd89f48b3..8505369a865 100644 --- a/test/performance/throughput/ThroughputPublisher.hpp +++ b/test/performance/throughput/ThroughputPublisher.hpp @@ -34,20 +34,11 @@ #include #include #include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include "ThroughputTypes.hpp" +#include +#include #include "../optionarg.hpp" +#include "ThroughputTypes.hpp" class ThroughputPublisher { @@ -79,7 +70,7 @@ class ThroughputPublisher uint32_t test_time, uint32_t recovery_time_ms, int demand, - int msg_size, + uint32_t msg_size, uint32_t subscribers); private: @@ -135,7 +126,7 @@ class ThroughputPublisher ThroughputType* throughput_data_ = nullptr; eprosima::fastdds::dds::TypeSupport throughput_data_type_; // Dynamic Data - eprosima::fastrtps::types::DynamicData* dynamic_data_ = nullptr; + eprosima::fastdds::dds::DynamicData::_ref_type* dynamic_data_ {nullptr}; eprosima::fastdds::dds::TypeSupport dynamic_pub_sub_type_; // QoS Profiles eprosima::fastdds::dds::DataWriterQos dw_qos_; diff --git a/test/performance/throughput/ThroughputSubscriber.cpp b/test/performance/throughput/ThroughputSubscriber.cpp index b0532bee28c..7481da82958 100644 --- a/test/performance/throughput/ThroughputSubscriber.cpp +++ b/test/performance/throughput/ThroughputSubscriber.cpp @@ -30,14 +30,16 @@ #include #include #include +#include +#include +#include +#include +#include #include #include -#include -#include using namespace eprosima::fastdds::dds; using namespace eprosima::fastrtps::rtps; -using namespace eprosima::fastrtps::types; // ******************************************************************************************* // ************************************ DATA SUB LISTENER ************************************ @@ -98,7 +100,7 @@ void ThroughputSubscriber::DataReaderListener::on_data_available( SampleInfoSeq infos; LoanableSequence data_seq; - if (ReturnCode_t::RETCODE_OK != reader->take(data_seq, infos)) + if (RETCODE_OK != reader->take(data_seq, infos)) { EPROSIMA_LOG_INFO(ThroughputTest, "Problem reading Subscriber echoed loaned test data"); return; @@ -132,7 +134,7 @@ void ThroughputSubscriber::DataReaderListener::on_data_available( last_seq_num_ = last_seq_num; // release the reader loan - if (ReturnCode_t::RETCODE_OK != reader->return_loan(data_seq, infos)) + if (RETCODE_OK != reader->return_loan(data_seq, infos)) { EPROSIMA_LOG_INFO(ThroughputTest, "Problem returning loaned test data"); return; @@ -143,13 +145,20 @@ void ThroughputSubscriber::DataReaderListener::on_data_available( void* data = sub.dynamic_types_ ? (void*)sub.dynamic_data_ : (void*)sub.throughput_data_; assert(nullptr != data); - while (ReturnCode_t::RETCODE_OK == reader->take_next_sample(data, &info_)) + while (RETCODE_OK == reader->take_next_sample(data, &info_)) { if (info_.valid_data) { - uint32_t seq_num = sub.dynamic_types_ - ? sub.dynamic_data_->get_uint32_value(0) - : sub.throughput_data_->seqnum; + uint32_t seq_num {0}; + + if (sub.dynamic_types_) + { + (*sub.dynamic_data_)->get_uint32_value(seq_num, 0); + } + else + { + seq_num = sub.throughput_data_->seqnum; + } if ((last_seq_num_ + 1) < seq_num) { @@ -296,7 +305,7 @@ bool ThroughputSubscriber::init( // Load XML configuration if (xml_config_file_.length() > 0) { - if ( ReturnCode_t::RETCODE_OK != + if ( RETCODE_OK != DomainParticipantFactory::get_instance()-> get_participant_qos_from_profile( participant_profile_name, @@ -352,7 +361,7 @@ bool ThroughputSubscriber::init( throughput_command_type_.reset(new ThroughputCommandDataType()); // Register the command data type - if (ReturnCode_t::RETCODE_OK + if (RETCODE_OK != throughput_command_type_.register_type(participant_)) { EPROSIMA_LOG_ERROR(THROUGHPUTSUBSCRIBER, "ERROR registering command type"); @@ -379,7 +388,7 @@ bool ThroughputSubscriber::init( std::string profile_name = "subscriber_profile"; if (xml_config_file_.length() > 0 - && ReturnCode_t::RETCODE_OK != subscriber_->get_datareader_qos_from_profile(profile_name, dr_qos_)) + && RETCODE_OK != subscriber_->get_datareader_qos_from_profile(profile_name, dr_qos_)) { EPROSIMA_LOG_ERROR(THROUGHPUTSUBSCRIBER, "ERROR unable to retrieve the " << profile_name); return false; @@ -390,7 +399,9 @@ bool ThroughputSubscriber::init( // Reliability ReliabilityQosPolicy rp; - rp.kind = reliable_ ? eprosima::fastrtps::RELIABLE_RELIABILITY_QOS: eprosima::fastrtps::BEST_EFFORT_RELIABILITY_QOS; + rp.kind = + reliable_ ? eprosima::fastdds::dds::RELIABLE_RELIABILITY_QOS: eprosima::fastdds::dds:: + BEST_EFFORT_RELIABILITY_QOS; dr_qos_.reliability(rp); // Set data sharing according with cli. Is disabled by default in all xml profiles @@ -523,7 +534,7 @@ int ThroughputSubscriber::process_message() if (command_reader_->wait_for_unread_message({100, 0})) { - if (ReturnCode_t::RETCODE_OK == command_reader_->take_next_sample( + if (RETCODE_OK == command_reader_->take_next_sample( (void*)&command, &info)) { @@ -546,25 +557,25 @@ int ThroughputSubscriber::process_message() assert(nullptr == dynamic_data_); // Create the data sample - MemberId id; - dynamic_data_ = static_cast(dynamic_pub_sub_type_->createData()); + dynamic_data_ = + static_cast(dynamic_pub_sub_type_->createData()); if (nullptr == dynamic_data_) { - EPROSIMA_LOG_ERROR(THROUGHPUTSUBSCRIBER, "Iteration failed: Failed to create Dynamic Data"); + EPROSIMA_LOG_ERROR(THROUGHPUTSUBSCRIBER, + "Iteration failed: Failed to create Dynamic Data"); return 2; } // Modify the data Sample - DynamicData* member_data = dynamic_data_->loan_value( - dynamic_data_->get_member_id_at_index(1)); + DynamicData::_ref_type member_data = (*dynamic_data_)->loan_value( + (*dynamic_data_)->get_member_id_at_index(1)); for (uint32_t i = 0; i < command.m_size; ++i) { - member_data->insert_sequence_data(id); - member_data->set_byte_value(0, id); + member_data->set_byte_value(i, 0); } - dynamic_data_->return_loaned_value(member_data); + (*dynamic_data_)->return_loaned_value(member_data); } else { @@ -640,9 +651,9 @@ int ThroughputSubscriber::process_message() // Consume history while (data_reader_->wait_for_unread_message({0, 1000000})) { - while (ReturnCode_t::RETCODE_OK == data_reader_->take(data_seq, infos)) + while (RETCODE_OK == data_reader_->take(data_seq, infos)) { - if (ReturnCode_t::RETCODE_OK != data_reader_->return_loan(data_seq, infos)) + if (RETCODE_OK != data_reader_->return_loan(data_seq, infos)) { EPROSIMA_LOG_INFO(ThroughputTest, "Problem returning loan"); } @@ -673,7 +684,7 @@ int ThroughputSubscriber::process_message() // Remove the dynamic_data_ object, protect form ongoing callbacks if (dynamic_types_) { - DynamicDataFactory::get_instance()->delete_data(dynamic_data_); + dynamic_pub_sub_type_.delete_data(dynamic_data_); dynamic_data_ = nullptr; } else @@ -815,18 +826,27 @@ bool ThroughputSubscriber::init_dynamic_types() } // Dummy type registration + DynamicTypeBuilderFactory::_ref_type factory {DynamicTypeBuilderFactory::get_instance()}; // Create basic builders - DynamicTypeBuilder_ptr struct_type_builder(DynamicTypeBuilderFactory::get_instance()->create_struct_builder()); + TypeDescriptor::_ref_type type_descriptor {traits::make_shared()}; + type_descriptor->kind(TK_STRUCTURE); + type_descriptor->name(ThroughputDataType::type_name_); + + DynamicTypeBuilder::_ref_type struct_type_builder {factory->create_type(type_descriptor)}; // Add members to the struct. - struct_type_builder->add_member(0, "seqnum", DynamicTypeBuilderFactory::get_instance()->create_uint32_type()); - struct_type_builder->add_member(1, "data", DynamicTypeBuilderFactory::get_instance()->create_sequence_builder( - DynamicTypeBuilderFactory::get_instance()->create_byte_type(), BOUND_UNLIMITED)); - struct_type_builder->set_name(ThroughputDataType::type_name_); + MemberDescriptor::_ref_type member_descriptor {traits::make_shared()}; + member_descriptor->name("seqnum"); + member_descriptor->type(factory->get_primitive_type(TK_UINT32)); + struct_type_builder->add_member(member_descriptor); + member_descriptor->name("data"); + member_descriptor->type(factory->create_sequence_type( + factory->get_primitive_type(TK_BYTE), static_cast(LENGTH_UNLIMITED))->build()); + struct_type_builder->add_member(member_descriptor); dynamic_pub_sub_type_.reset(new DynamicPubSubType(struct_type_builder->build())); // Register the data type - if (ReturnCode_t::RETCODE_OK + if (RETCODE_OK != dynamic_pub_sub_type_.register_type(participant_)) { EPROSIMA_LOG_ERROR(THROUGHPUTSUBSCRIBER, "ERROR registering the DYNAMIC DATA topic"); @@ -856,7 +876,7 @@ bool ThroughputSubscriber::init_static_types( // Create the static type throughput_data_type_.reset(new ThroughputDataType(payload)); // Register the static type - if (ReturnCode_t::RETCODE_OK + if (RETCODE_OK != throughput_data_type_.register_type(participant_)) { return false; @@ -920,7 +940,7 @@ bool ThroughputSubscriber::destroy_data_endpoints() // Delete the endpoint if (nullptr == data_reader_ - || ReturnCode_t::RETCODE_OK != subscriber_->delete_datareader(data_reader_)) + || RETCODE_OK != subscriber_->delete_datareader(data_reader_)) { EPROSIMA_LOG_ERROR(THROUGHPUTSUBSCRIBER, "ERROR destroying the DataWriter"); return false; @@ -930,7 +950,7 @@ bool ThroughputSubscriber::destroy_data_endpoints() // Delete the Topic if (nullptr == data_sub_topic_ - || ReturnCode_t::RETCODE_OK != participant_->delete_topic(data_sub_topic_)) + || RETCODE_OK != participant_->delete_topic(data_sub_topic_)) { EPROSIMA_LOG_ERROR(THROUGHPUTSUBSCRIBER, "ERROR destroying the DATA topic"); return false; @@ -938,7 +958,7 @@ bool ThroughputSubscriber::destroy_data_endpoints() data_sub_topic_ = nullptr; // Delete the Type - if (ReturnCode_t::RETCODE_OK + if (RETCODE_OK != participant_->unregister_type(ThroughputDataType::type_name_)) { EPROSIMA_LOG_ERROR(THROUGHPUTSUBSCRIBER, "ERROR unregistering the DATA type"); diff --git a/test/performance/throughput/ThroughputSubscriber.hpp b/test/performance/throughput/ThroughputSubscriber.hpp index 0587873fde3..be2f6b595d6 100644 --- a/test/performance/throughput/ThroughputSubscriber.hpp +++ b/test/performance/throughput/ThroughputSubscriber.hpp @@ -32,19 +32,12 @@ #include #include #include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include +#include +#include #include "ThroughputTypes.hpp" #include "../optionarg.hpp" +#include "ThroughputTypes.hpp" class ThroughputSubscriber { @@ -119,7 +112,7 @@ class ThroughputSubscriber ThroughputType* throughput_data_ = nullptr; eprosima::fastdds::dds::TypeSupport throughput_data_type_; // Dynamic Data - eprosima::fastrtps::types::DynamicData* dynamic_data_ = nullptr; + eprosima::fastdds::dds::DynamicData::_ref_type* dynamic_data_ {nullptr}; eprosima::fastdds::dds::TypeSupport dynamic_pub_sub_type_; // QoS Profiles eprosima::fastdds::dds::DataReaderQos dr_qos_; diff --git a/test/performance/throughput/ThroughputTypes.hpp b/test/performance/throughput/ThroughputTypes.hpp index dc5f48efc59..cf4b4b8c48c 100644 --- a/test/performance/throughput/ThroughputTypes.hpp +++ b/test/performance/throughput/ThroughputTypes.hpp @@ -20,12 +20,12 @@ #ifndef THROUGHPUTTYPES_H_ #define THROUGHPUTTYPES_H_ -#include -#include -#include - #include +#include +#include +#include + struct TroughputResults { uint32_t payload_size; @@ -113,7 +113,7 @@ typedef struct alignas(4) ThroughputType } ThroughputType; -class ThroughputDataType : public eprosima::fastrtps::TopicDataType +class ThroughputDataType : public eprosima::fastdds::dds::TopicDataType { // Buffer size for the manage type const uint32_t buffer_size_; @@ -197,7 +197,7 @@ class ThroughputDataType : public eprosima::fastrtps::TopicDataType private: - using eprosima::fastrtps::TopicDataType::is_plain; + using eprosima::fastdds::dds::TopicDataType::is_plain; }; enum e_Command : uint32_t @@ -251,7 +251,7 @@ inline std::ostream& operator <<( return output; } -class ThroughputCommandDataType : public eprosima::fastrtps::TopicDataType +class ThroughputCommandDataType : public eprosima::fastdds::dds::TopicDataType { public: diff --git a/test/performance/throughput/main_ThroughputTest.cpp b/test/performance/throughput/main_ThroughputTest.cpp index 09f299a323a..33b6dd01d1f 100644 --- a/test/performance/throughput/main_ThroughputTest.cpp +++ b/test/performance/throughput/main_ThroughputTest.cpp @@ -12,21 +12,19 @@ // See the License for the specific language governing permissions and // limitations under the License. -#include "ThroughputTypes.hpp" -#include "ThroughputPublisher.hpp" -#include "ThroughputSubscriber.hpp" - -#include "../optionarg.hpp" - -#include -#include -#include #include #include +#include +#include +#include +#include #include -#include -#include + +#include "../optionarg.hpp" +#include "ThroughputPublisher.hpp" +#include "ThroughputSubscriber.hpp" +#include "ThroughputTypes.hpp" #if defined(_MSC_VER) #pragma warning (push) @@ -156,7 +154,7 @@ int main( uint32_t test_time_sec = 5; uint32_t recovery_time_ms = 5; int demand = 10000; - int msg_size = 1024; + uint32_t msg_size = 1024; bool reliable = false; uint32_t seed = 80; bool hostname = false; @@ -264,7 +262,7 @@ int main( break; case MSG_SIZE: - msg_size = strtol(opt.arg, nullptr, 10); + msg_size = strtoul(opt.arg, nullptr, 10); break; case FILE_R: @@ -457,7 +455,7 @@ int main( // Load an XML file with predefined profiles for publisher and subscriber if (xml_config_file.length() > 0) { - xmlparser::XMLProfileManager::loadXMLFile(xml_config_file); + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->load_XML_profiles_file(xml_config_file); } uint8_t return_code = 0; diff --git a/test/performance/throughput/throughput_tests.py b/test/performance/throughput/throughput_tests.py index 57aa556116f..5c7bedbcfdb 100644 --- a/test/performance/throughput/throughput_tests.py +++ b/test/performance/throughput/throughput_tests.py @@ -24,7 +24,7 @@ parser.add_argument( '-x', '--xml_file', - help='A Fast-RTPS XML configuration file', + help='A Fast DDS XML configuration file', required=False ) parser.add_argument( @@ -66,7 +66,7 @@ '-d', '--data_sharing', choices=['on', 'off'], - help='Explicitly enable/disable data sharing. (Defaults: Fast-DDS default settings)', + help='Explicitly enable/disable data sharing. (Defaults: Fast DDS default settings)', required=False ) parser.add_argument( @@ -86,7 +86,7 @@ parser.add_argument( '--shared_memory', choices=['on', 'off'], - help='Explicitly enable/disable shared memory transport. (Defaults: Fast-DDS default settings)', + help='Explicitly enable/disable shared memory transport. (Defaults: Fast DDS default settings)', required=False ) diff --git a/test/performance/throughput/xml/throughput_interprocess_best_effort_shm_profile.xml b/test/performance/throughput/xml/throughput_interprocess_best_effort_shm_profile.xml index 938c11ba62f..c993627a446 100644 --- a/test/performance/throughput/xml/throughput_interprocess_best_effort_shm_profile.xml +++ b/test/performance/throughput/xml/throughput_interprocess_best_effort_shm_profile.xml @@ -1,5 +1,5 @@ - + OFF diff --git a/test/performance/throughput/xml/throughput_interprocess_best_effort_tcp_profile.xml b/test/performance/throughput/xml/throughput_interprocess_best_effort_tcp_profile.xml index 7308c76a146..8c50c9099e2 100644 --- a/test/performance/throughput/xml/throughput_interprocess_best_effort_tcp_profile.xml +++ b/test/performance/throughput/xml/throughput_interprocess_best_effort_tcp_profile.xml @@ -1,5 +1,5 @@ - + diff --git a/test/performance/throughput/xml/throughput_interprocess_best_effort_udp_profile.xml b/test/performance/throughput/xml/throughput_interprocess_best_effort_udp_profile.xml index e46c159d5d7..b19956384d9 100644 --- a/test/performance/throughput/xml/throughput_interprocess_best_effort_udp_profile.xml +++ b/test/performance/throughput/xml/throughput_interprocess_best_effort_udp_profile.xml @@ -1,5 +1,5 @@ - + diff --git a/test/performance/throughput/xml/throughput_interprocess_reliable_shm_profile.xml b/test/performance/throughput/xml/throughput_interprocess_reliable_shm_profile.xml index 413dffada21..81c077bd6d0 100644 --- a/test/performance/throughput/xml/throughput_interprocess_reliable_shm_profile.xml +++ b/test/performance/throughput/xml/throughput_interprocess_reliable_shm_profile.xml @@ -1,5 +1,5 @@ - + OFF diff --git a/test/performance/throughput/xml/throughput_interprocess_reliable_tcp_profile.xml b/test/performance/throughput/xml/throughput_interprocess_reliable_tcp_profile.xml index 4b4dbbc5e9e..00d0c59ecdc 100644 --- a/test/performance/throughput/xml/throughput_interprocess_reliable_tcp_profile.xml +++ b/test/performance/throughput/xml/throughput_interprocess_reliable_tcp_profile.xml @@ -1,5 +1,5 @@ - + diff --git a/test/performance/throughput/xml/throughput_interprocess_reliable_udp_profile.xml b/test/performance/throughput/xml/throughput_interprocess_reliable_udp_profile.xml index 64205fa54be..0709c1b2647 100644 --- a/test/performance/throughput/xml/throughput_interprocess_reliable_udp_profile.xml +++ b/test/performance/throughput/xml/throughput_interprocess_reliable_udp_profile.xml @@ -1,5 +1,5 @@ - + diff --git a/test/performance/throughput/xml/throughput_intraprocess_best_effort_profile.xml b/test/performance/throughput/xml/throughput_intraprocess_best_effort_profile.xml index 34b75392443..4459532b0c7 100644 --- a/test/performance/throughput/xml/throughput_intraprocess_best_effort_profile.xml +++ b/test/performance/throughput/xml/throughput_intraprocess_best_effort_profile.xml @@ -1,5 +1,5 @@ - + diff --git a/test/performance/throughput/xml/throughput_intraprocess_reliable_profile.xml b/test/performance/throughput/xml/throughput_intraprocess_reliable_profile.xml index 1b9df41a54d..0e371fde075 100644 --- a/test/performance/throughput/xml/throughput_intraprocess_reliable_profile.xml +++ b/test/performance/throughput/xml/throughput_intraprocess_reliable_profile.xml @@ -1,5 +1,5 @@ - + diff --git a/test/performance/video/CMakeLists.txt b/test/performance/video/CMakeLists.txt index 186df42e449..b0c54506756 100644 --- a/test/performance/video/CMakeLists.txt +++ b/test/performance/video/CMakeLists.txt @@ -108,7 +108,7 @@ if(GST_FOUND) if (WIN32) target_link_libraries( VideoTest - fastrtps + fastdds fastcdr foonathan_memory fastdds::optionparser @@ -125,7 +125,7 @@ if(GST_FOUND) else() target_link_libraries( VideoTest - fastrtps + fastdds fastcdr foonathan_memory fastdds::optionparser diff --git a/test/performance/video/VideoTestPublisher.cpp b/test/performance/video/VideoTestPublisher.cpp index 7f2456e7252..0cb7f67f516 100644 --- a/test/performance/video/VideoTestPublisher.cpp +++ b/test/performance/video/VideoTestPublisher.cpp @@ -23,11 +23,9 @@ #include #include -#include #include #include -#include -#include +#include #include #define TIME_LIMIT_US 10000 @@ -211,8 +209,8 @@ void VideoTestPublisher::init( TypeSupport type_command; type_video.reset(new VideoDataType()); type_command.reset(new TestCommandDataType()); - ASSERT_EQ(mp_participant->register_type(type_video), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(mp_participant->register_type(type_command), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(mp_participant->register_type(type_video), RETCODE_OK); + ASSERT_EQ(mp_participant->register_type(type_command), RETCODE_OK); // Create Data Publisher std::string profile_name = "publisher_profile"; @@ -415,7 +413,7 @@ void VideoTestPublisher::CommandSubListener::on_data_available( TestCommandType command; eprosima::fastdds::dds::SampleInfo info; - if (ReturnCode_t::RETCODE_OK == datareader->take_next_sample((void*)&command, &info)) + if (RETCODE_OK == datareader->take_next_sample((void*)&command, &info)) { if (info.valid_data) { diff --git a/test/performance/video/VideoTestSubscriber.cpp b/test/performance/video/VideoTestSubscriber.cpp index 59762423270..7f68e19589e 100644 --- a/test/performance/video/VideoTestSubscriber.cpp +++ b/test/performance/video/VideoTestSubscriber.cpp @@ -18,14 +18,15 @@ */ #include "VideoTestSubscriber.hpp" +#include "VideoTestSubscriber.hpp" + #include #include #include #include +#include #include -#include -#include #include using namespace eprosima; @@ -187,8 +188,8 @@ void VideoTestSubscriber::init( TypeSupport command_type; video_type.reset(new VideoDataType()); command_type.reset(new TestCommandDataType()); - ASSERT_EQ(mp_participant->register_type(video_type), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(mp_participant->register_type(command_type), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(mp_participant->register_type(video_type), RETCODE_OK); + ASSERT_EQ(mp_participant->register_type(command_type), RETCODE_OK); // Create Data Subscriber std::string profile_name = "subscriber_profile"; @@ -366,7 +367,7 @@ void VideoTestSubscriber::CommandSubListener::on_data_available( { SampleInfo info; TestCommandType command; - if (ReturnCode_t::RETCODE_OK == datareader->take_next_sample((void*)&command, &info)) + if (RETCODE_OK == datareader->take_next_sample((void*)&command, &info)) { if (info.valid_data) { diff --git a/test/performance/video/VideoTestTypes.hpp b/test/performance/video/VideoTestTypes.hpp index 77e6f4f0fbe..e6a2446c583 100644 --- a/test/performance/video/VideoTestTypes.hpp +++ b/test/performance/video/VideoTestTypes.hpp @@ -41,8 +41,7 @@ #include #include -#include -#include +#include diff --git a/test/performance/video/main_VideoTest.cpp b/test/performance/video/main_VideoTest.cpp index b09069dee7b..cf58c754886 100644 --- a/test/performance/video/main_VideoTest.cpp +++ b/test/performance/video/main_VideoTest.cpp @@ -20,15 +20,11 @@ #include #include +#include +#include #include - #include -#include -#include -#include -#include - #include "VideoTestPublisher.hpp" #include "VideoTestSubscriber.hpp" @@ -454,7 +450,6 @@ int main( // Load an XML file with predefined profiles for publisher and subscriber if (sXMLConfigFile.length() > 0) { - // xmlparser::XMLProfileManager::loadXMLFile(sXMLConfigFile); DomainParticipantFactory::get_instance()->load_XML_profiles_file(sXMLConfigFile); } diff --git a/test/performance/video/video_tests.py b/test/performance/video/video_tests.py index 6f49bb1b825..3d650306cb6 100644 --- a/test/performance/video/video_tests.py +++ b/test/performance/video/video_tests.py @@ -46,7 +46,7 @@ def assert_positive_int(str_number, str_name): parser.add_argument( '-x', '--xml_file', - help='A Fast-RTPS XML configuration file', + help='A Fast DDS XML configuration file', required=False ) parser.add_argument( diff --git a/test/performance/video/xml/video_interprocess_best_effort_profile.xml b/test/performance/video/xml/video_interprocess_best_effort_profile.xml index 8226f0e0667..6f9bcdc17b7 100644 --- a/test/performance/video/xml/video_interprocess_best_effort_profile.xml +++ b/test/performance/video/xml/video_interprocess_best_effort_profile.xml @@ -1,5 +1,5 @@ - + diff --git a/test/performance/video/xml/video_interprocess_best_effort_tcp_profile.xml b/test/performance/video/xml/video_interprocess_best_effort_tcp_profile.xml index ec1afc9dd00..021cf3fd857 100644 --- a/test/performance/video/xml/video_interprocess_best_effort_tcp_profile.xml +++ b/test/performance/video/xml/video_interprocess_best_effort_tcp_profile.xml @@ -1,5 +1,5 @@ - + diff --git a/test/performance/video/xml/video_interprocess_reliable_profile.xml b/test/performance/video/xml/video_interprocess_reliable_profile.xml index 9abaf6b101d..f325680610a 100644 --- a/test/performance/video/xml/video_interprocess_reliable_profile.xml +++ b/test/performance/video/xml/video_interprocess_reliable_profile.xml @@ -1,5 +1,5 @@ - + diff --git a/test/performance/video/xml/video_interprocess_reliable_tcp_profile.xml b/test/performance/video/xml/video_interprocess_reliable_tcp_profile.xml index bc1e06eaef7..96ea087ca0c 100644 --- a/test/performance/video/xml/video_interprocess_reliable_tcp_profile.xml +++ b/test/performance/video/xml/video_interprocess_reliable_tcp_profile.xml @@ -1,5 +1,5 @@ - + diff --git a/test/profiling/CMakeLists.txt b/test/profiling/CMakeLists.txt index 71a4092718d..d97b21d043f 100644 --- a/test/profiling/CMakeLists.txt +++ b/test/profiling/CMakeLists.txt @@ -42,7 +42,7 @@ set(MEMORYTEST_SOURCE MemoryTestPublisher.cpp ) add_executable(MemoryTest ${MEMORYTEST_SOURCE}) target_include_directories(MemoryTest PRIVATE ${Asio_INCLUDE_DIR}) -target_link_libraries(MemoryTest fastrtps foonathan_memory fastdds::optionparser ${CMAKE_THREAD_LIBS_INIT} ${CMAKE_DL_LIBS}) +target_link_libraries(MemoryTest fastdds foonathan_memory fastdds::optionparser ${CMAKE_THREAD_LIBS_INIT} ${CMAKE_DL_LIBS}) configure_file("cycles_tests.py" "cycles_tests.py") configure_file("memory_tests.py" "memory_tests.py") diff --git a/test/profiling/MemoryTestPublisher.cpp b/test/profiling/MemoryTestPublisher.cpp index 91b04e6dc60..7c8fa03c446 100644 --- a/test/profiling/MemoryTestPublisher.cpp +++ b/test/profiling/MemoryTestPublisher.cpp @@ -25,9 +25,15 @@ #include #include -#include +#include +#include +#include #include -#include +#include +#include +#include +#include +#include #ifndef _WIN32 #define localtime_s(X, Y) localtime_r(Y, X) @@ -35,42 +41,18 @@ #define TIME_LIMIT_US 10000 -using namespace eprosima; -using namespace eprosima::fastrtps; -using namespace eprosima::fastrtps::rtps; -using namespace eprosima::fastrtps::types; - -using std::cout; -using std::endl; +using namespace eprosima::fastdds::dds; MemoryTestPublisher::MemoryTestPublisher() - : mp_participant(nullptr) - , mp_datapub(nullptr) - , mp_commandpub(nullptr) - , mp_commandsub(nullptr) - , n_subscribers(0) - , n_samples(0) - , disc_count_(0) - , comm_count_(0) - , data_count_(0) - , m_status(0) - , n_received(0) - , m_datapublistener(nullptr) - , m_commandpublistener(nullptr) - , m_commandsublistener(nullptr) - , m_data_size(0) - , dynamic_data(false) - , mp_memory(nullptr) { - m_datapublistener.mp_up = this; - m_commandpublistener.mp_up = this; - m_commandsublistener.mp_up = this; - m_exportPrefix = ""; + m_datapublistener.up_ = this; + m_commandpublistener.up_ = this; + m_commandsublistener.up_ = this; } MemoryTestPublisher::~MemoryTestPublisher() { - Domain::removeParticipant(mp_participant); + participant_->delete_contained_entities(); } bool MemoryTestPublisher::init( @@ -81,8 +63,8 @@ bool MemoryTestPublisher::init( bool hostname, bool export_csv, const std::string& export_prefix, - const PropertyPolicy& part_property_policy, - const PropertyPolicy& property_policy, + const eprosima::fastrtps::rtps::PropertyPolicy& part_property_policy, + const eprosima::fastrtps::rtps::PropertyPolicy& property_policy, const std::string& sXMLConfigFile, uint32_t data_size, bool dynamic_types) @@ -94,102 +76,127 @@ bool MemoryTestPublisher::init( m_exportPrefix = export_prefix; reliable_ = reliable; m_data_size = data_size; - dynamic_data = dynamic_types; + dynamic_data_ = dynamic_types; - if (dynamic_data) // Dummy type registration + if (dynamic_data_) // Dummy type registration { + DynamicTypeBuilderFactory::_ref_type factory {DynamicTypeBuilderFactory::get_instance()}; + // Create basic builders - DynamicTypeBuilder_ptr struct_type_builder(DynamicTypeBuilderFactory::get_instance()->create_struct_builder()); + TypeDescriptor::_ref_type type_descriptor {traits::make_shared()}; + type_descriptor->kind(TK_STRUCTURE); + type_descriptor->name("MemoryType"); + DynamicTypeBuilder::_ref_type struct_type_builder(factory->create_type(type_descriptor)); // Add members to the struct. - struct_type_builder->add_member(0, "seqnum", DynamicTypeBuilderFactory::get_instance()->create_uint32_type()); - struct_type_builder->add_member(1, "data", - DynamicTypeBuilderFactory::get_instance()->create_sequence_builder( - DynamicTypeBuilderFactory::get_instance()->create_byte_type(), ::dds::core::LENGTH_UNLIMITED - )); - struct_type_builder->set_name("MemoryType"); + MemberDescriptor::_ref_type member_descriptor {traits::make_shared()}; + member_descriptor->type(factory->get_primitive_type(eprosima::fastdds::dds::TK_UINT32)); + member_descriptor->name("seqnum"); + struct_type_builder->add_member(member_descriptor); + member_descriptor = traits::make_shared(); + member_descriptor->type(factory->create_sequence_type(factory->get_primitive_type(eprosima::fastdds::dds:: + TK_BYTE), static_cast(LENGTH_UNLIMITED))->build()); + member_descriptor->name("data"); + struct_type_builder->add_member(member_descriptor); m_pDynType = struct_type_builder->build(); - m_DynType.SetDynamicType(m_pDynType); } // Create RTPSParticipant std::string participant_profile_name = "participant_profile"; - ParticipantAttributes PParam; - PParam.domainId = pid % 230; - PParam.rtps.properties = part_property_policy; - PParam.rtps.setName("Participant_pub"); + DomainParticipantQos participant_qos; + participant_qos.name("MemoryTest_Participant_Publisher"); + participant_qos.properties(part_property_policy); if (m_sXMLConfigFile.length() > 0) { - mp_participant = Domain::createParticipant(participant_profile_name); + participant_ = DomainParticipantFactory::get_instance()->create_participant_with_profile(pid % 230, + participant_profile_name); } else { - mp_participant = Domain::createParticipant(PParam); + participant_ = DomainParticipantFactory::get_instance()->create_participant(pid % 230, participant_qos); } - if (mp_participant == nullptr) + if (nullptr == participant_) { return false; } // Register the type - if (dynamic_data) + if (dynamic_data_) { - Domain::registerType(mp_participant, &m_DynType); + dynamic_type_support_ = new DynamicPubSubType(m_pDynType); + data_type_ = TypeSupport{dynamic_type_support_}; } else { - Domain::registerType(mp_participant, (TopicDataType*)&memory_t); + data_type_ = TypeSupport{new MemoryDataType()}; } - Domain::registerType(mp_participant, (TopicDataType*)&command_t); + participant_->register_type(data_type_); + participant_->register_type(command_type_); - // Create Sending Publisher - std::string profile_name = "publisher_profile"; - PublisherAttributes PubDataparam; - PubDataparam.topic.topicDataType = "MemoryType"; - PubDataparam.topic.topicKind = NO_KEY; - std::ostringstream pt; - pt << "MemoryTest_"; + publisher_ = participant_->create_publisher(PUBLISHER_QOS_DEFAULT); + + if (nullptr == publisher_) + { + return false; + } + + subscriber_ = participant_->create_subscriber(SUBSCRIBER_QOS_DEFAULT); + + if (nullptr == subscriber_) + { + return false; + } + + std::ostringstream st; + st << "MemoryTest_"; if (hostname) { - pt << asio::ip::host_name() << "_"; + st << asio::ip::host_name() << "_"; } - pt << pid << "_PUB2SUB"; - PubDataparam.topic.topicName = pt.str(); + st << pid << "_PUB2SUB"; + data_topic_ = participant_->create_topic(st.str(), "MemoryType", TOPIC_QOS_DEFAULT); + + if (nullptr == data_topic_) + { + return false; + } + + // Create Sending Publisher + std::string profile_name = "publisher_profile"; + DataWriterQos writer_qos; if (!reliable) { - PubDataparam.qos.m_reliability.kind = BEST_EFFORT_RELIABILITY_QOS; + writer_qos.reliability().kind = BEST_EFFORT_RELIABILITY_QOS; } - PubDataparam.properties = property_policy; + writer_qos.properties(property_policy); + if (m_data_size > 60000) { - PubDataparam.historyMemoryPolicy = eprosima::fastrtps::rtps::PREALLOCATED_WITH_REALLOC_MEMORY_MODE; - PubDataparam.qos.m_publishMode.kind = eprosima::fastrtps::ASYNCHRONOUS_PUBLISH_MODE; + writer_qos.endpoint().history_memory_policy = + eprosima::fastrtps::rtps::MemoryManagementPolicy::PREALLOCATED_WITH_REALLOC_MEMORY_MODE; + writer_qos.publish_mode().kind = ASYNCHRONOUS_PUBLISH_MODE; } if (m_sXMLConfigFile.length() > 0) { - mp_datapub = - Domain::createPublisher(mp_participant, profile_name, (PublisherListener*)&this->m_datapublistener); + data_writer_ = publisher_->create_datawriter_with_profile(data_topic_, profile_name, &this->m_datapublistener); } else { - mp_datapub = - Domain::createPublisher(mp_participant, PubDataparam, (PublisherListener*)&this->m_datapublistener); + data_writer_ = publisher_->create_datawriter(data_topic_, writer_qos, &this->m_datapublistener); } - if (mp_datapub == nullptr) + if (nullptr == data_writer_) { return false; } + std::cout << "Publisher created" << std::endl; //COMMAND PUBLISHER - PublisherAttributes PubCommandParam; - PubCommandParam.topic.topicDataType = "TestCommandType"; - PubCommandParam.topic.topicKind = NO_KEY; std::ostringstream pct; pct << "MemoryTest_Command_"; if (hostname) @@ -197,22 +204,26 @@ bool MemoryTestPublisher::init( pct << asio::ip::host_name() << "_"; } pct << pid << "_PUB2SUB"; - PubCommandParam.topic.topicName = pct.str(); - PubCommandParam.topic.historyQos.kind = KEEP_ALL_HISTORY_QOS; - PubCommandParam.qos.m_durability.kind = TRANSIENT_LOCAL_DURABILITY_QOS; - PubCommandParam.qos.m_reliability.kind = RELIABLE_RELIABILITY_QOS; - PubCommandParam.qos.m_publishMode.kind = eprosima::fastrtps::SYNCHRONOUS_PUBLISH_MODE; + command_pub_topic_ = participant_->create_topic(pct.str(), "TestCommandType", TOPIC_QOS_DEFAULT); + + if (nullptr == command_pub_topic_) + { + return false; + } + + DataWriterQos command_writer_qos; + command_writer_qos.history().kind = KEEP_ALL_HISTORY_QOS; + command_writer_qos.durability().kind = TRANSIENT_LOCAL_DURABILITY_QOS; + command_writer_qos.reliability().kind = RELIABLE_RELIABILITY_QOS; - mp_commandpub = Domain::createPublisher(mp_participant, PubCommandParam, &this->m_commandpublistener); + command_writer_ = publisher_->create_datawriter(command_pub_topic_, command_writer_qos, + &this->m_commandpublistener); - if (mp_commandpub == nullptr) + if (nullptr == command_writer_) { return false; } - SubscriberAttributes SubCommandParam; - SubCommandParam.topic.topicDataType = "TestCommandType"; - SubCommandParam.topic.topicKind = NO_KEY; std::ostringstream sct; sct << "MemoryTest_Command_"; if (hostname) @@ -220,140 +231,132 @@ bool MemoryTestPublisher::init( sct << asio::ip::host_name() << "_"; } sct << pid << "_SUB2PUB"; - SubCommandParam.topic.topicName = sct.str(); - SubCommandParam.topic.historyQos.kind = KEEP_ALL_HISTORY_QOS; - SubCommandParam.qos.m_reliability.kind = RELIABLE_RELIABILITY_QOS; - SubCommandParam.qos.m_durability.kind = TRANSIENT_LOCAL_DURABILITY_QOS; + command_sub_topic_ = participant_->create_topic(sct.str(), "TestCommandType", TOPIC_QOS_DEFAULT); - mp_commandsub = Domain::createSubscriber(mp_participant, SubCommandParam, &this->m_commandsublistener); - - if (mp_commandsub == nullptr) + if (nullptr == command_sub_topic_) { return false; } - if (dynamic_data) + DataReaderQos reader_qos; + reader_qos.history().kind = KEEP_ALL_HISTORY_QOS; + reader_qos.durability().kind = TRANSIENT_LOCAL_DURABILITY_QOS; + reader_qos.reliability().kind = RELIABLE_RELIABILITY_QOS; + + command_reader_ = subscriber_->create_datareader(command_sub_topic_, reader_qos, &this->m_commandsublistener); + + if (nullptr == command_reader_) { - DynamicTypeBuilderFactory::delete_instance(); - pubAttr = mp_datapub->getAttributes(); - Domain::removePublisher(mp_datapub); - Domain::unregisterType(mp_participant, "MemoryType"); // Unregister as we will register it later with correct size + return false; } return true; } -void MemoryTestPublisher::DataPubListener::onPublicationMatched( - Publisher* /*pub*/, - MatchingInfo& info) +void MemoryTestPublisher::DataPubListener::on_publication_matched( + DataWriter*, + const PublicationMatchedStatus& info) { - std::unique_lock lock(mp_up->mutex_); + std::unique_lock lock(up_->mutex_); - if (info.status == MATCHED_MATCHING) + if (0 < info.current_count_change) { - cout << C_MAGENTA << "Data Pub Matched " << C_DEF << endl; + std::cout << C_MAGENTA << "Data Pub Matched " << C_DEF << std::endl; - n_matched++; - if (n_matched > mp_up->n_subscribers) + n_matched = info.total_count; + if (n_matched > up_->n_subscribers) { std::cout << "More matched subscribers than expected" << std::endl; - mp_up->m_status = -1; + up_->m_status = -1; } - ++mp_up->disc_count_; } else { - cout << C_MAGENTA << "Data Pub Unmatched " << C_DEF << endl; - --mp_up->disc_count_; + std::cout << C_MAGENTA << "Data Pub Unmatched " << C_DEF << std::endl; } + up_->disc_count_ += info.current_count_change; lock.unlock(); - mp_up->disc_cond_.notify_one(); + up_->disc_cond_.notify_one(); } -void MemoryTestPublisher::CommandPubListener::onPublicationMatched( - Publisher* /*pub*/, - MatchingInfo& info) +void MemoryTestPublisher::CommandPubListener::on_publication_matched( + DataWriter*, + const PublicationMatchedStatus& info) { - std::unique_lock lock(mp_up->mutex_); + std::unique_lock lock(up_->mutex_); - if (info.status == MATCHED_MATCHING) + if (0 < info.current_count_change) { - cout << C_MAGENTA << "Command Pub Matched " << C_DEF << endl; + std::cout << C_MAGENTA << "Command Pub Matched " << C_DEF << std::endl; - n_matched++; - if (n_matched > mp_up->n_subscribers) + n_matched = info.total_count; + if (n_matched > up_->n_subscribers) { std::cout << "More matched subscribers than expected" << std::endl; - mp_up->m_status = -1; + up_->m_status = -1; } - - ++mp_up->disc_count_; } else { - cout << C_MAGENTA << "Command Pub unmatched " << C_DEF << endl; - --mp_up->disc_count_; + std::cout << C_MAGENTA << "Command Pub unmatched " << C_DEF << std::endl; } + up_->disc_count_ += info.current_count_change; lock.unlock(); - mp_up->disc_cond_.notify_one(); + up_->disc_cond_.notify_one(); } -void MemoryTestPublisher::CommandSubListener::onSubscriptionMatched( - Subscriber* /*sub*/, - MatchingInfo& info) +void MemoryTestPublisher::CommandSubListener::on_subscription_matched( + DataReader*, + const SubscriptionMatchedStatus& info) { - std::unique_lock lock(mp_up->mutex_); + std::unique_lock lock(up_->mutex_); - if (info.status == MATCHED_MATCHING) + if (0 < info.current_count_change) { - cout << C_MAGENTA << "Command Sub Matched " << C_DEF << endl; + std::cout << C_MAGENTA << "Command Sub Matched " << C_DEF << std::endl; - n_matched++; - if (n_matched > mp_up->n_subscribers) + n_matched = info.total_count; + if (n_matched > up_->n_subscribers) { std::cout << "More matched subscribers than expected" << std::endl; - mp_up->m_status = -1; + up_->m_status = -1; } - - ++mp_up->disc_count_; } else { - cout << C_MAGENTA << "Command Sub unmatched " << C_DEF << endl; - --mp_up->disc_count_; + std::cout << C_MAGENTA << "Command Sub unmatched " << C_DEF << std::endl; } + up_->disc_count_ += info.current_count_change; lock.unlock(); - mp_up->disc_cond_.notify_one(); + up_->disc_cond_.notify_one(); } -void MemoryTestPublisher::CommandSubListener::onNewDataMessage( - Subscriber* subscriber) +void MemoryTestPublisher::CommandSubListener::on_data_available( + DataReader* reader) { TestCommandType command; - SampleInfo_t info; - // cout << "COMMAND RECEIVED"<takeNextData((void*)&command, &info)) + SampleInfo info; + + if (RETCODE_OK == reader->take_next_sample((void*)&command, &info)) { - if (info.sampleKind == ALIVE) + if (ALIVE_INSTANCE_STATE == info.instance_state) { - //cout << "ALIVE "<mutex_.lock(); - ++mp_up->comm_count_; - mp_up->mutex_.unlock(); - mp_up->comm_cond_.notify_one(); + up_->mutex_.lock(); + ++up_->comm_count_; + up_->mutex_.unlock(); + up_->comm_cond_.notify_one(); } } } else { - cout << "Problem reading" << endl; + std::cout << "Problem reading" << std::endl; } } @@ -365,62 +368,37 @@ void MemoryTestPublisher::run( std::unique_lock disc_lock(mutex_); disc_cond_.wait(disc_lock, [&]() { + std::cout << "m = " << disc_count_ << " - su = " << n_subscribers << std::endl; return disc_count_ >= (n_subscribers * 3); }); disc_lock.unlock(); test(test_time, m_data_size); std::this_thread::sleep_for(std::chrono::milliseconds(100)); - - cout << "REMOVING PUBLISHER" << endl; - Domain::removePublisher(this->mp_commandpub); - cout << "REMOVING SUBSCRIBER" << endl; - Domain::removeSubscriber(mp_commandsub); } bool MemoryTestPublisher::test( uint32_t test_time, uint32_t datasize) { - //cout << "Beginning test of size: "<create_struct_builder()); - - // Add members to the struct. - struct_type_builder->add_member(0, "seqnum", DynamicTypeBuilderFactory::get_instance()->create_uint32_type()); - struct_type_builder->add_member(1, "data", - DynamicTypeBuilderFactory::get_instance()->create_sequence_builder( - DynamicTypeBuilderFactory::get_instance()->create_byte_type(), datasize - )); - struct_type_builder->set_name("MemoryType"); - - m_pDynType = struct_type_builder->build(); - m_DynType.CleanDynamicType(); - m_DynType.SetDynamicType(m_pDynType); - - Domain::registerType(mp_participant, &m_DynType); - - mp_datapub = Domain::createPublisher(mp_participant, pubAttr, &m_datapublistener); - m_DynData = DynamicDataFactory::get_instance()->create_data(m_pDynType); - MemberId id; - DynamicData* my_data = m_DynData->loan_value(m_DynData->get_member_id_at_index(1)); + DynamicData::_ref_type my_data = m_DynData->loan_value(m_DynData->get_member_id_at_index(1)); for (uint32_t i = 0; i < datasize; ++i) { - my_data->insert_sequence_data(id); - my_data->set_byte_value(0, id); + my_data->set_byte_value(i, 0); } m_DynData->return_loaned_value(my_data); } else { - mp_memory = new MemoryType(datasize); + memory_ = new MemoryType(datasize); } std::chrono::duration test_time_us = std::chrono::seconds(test_time); auto t_end_ = std::chrono::steady_clock::now(); @@ -432,13 +410,12 @@ bool MemoryTestPublisher::test( return disc_count_ >= (n_subscribers * 3); }); disc_lock.unlock(); - cout << C_B_MAGENTA << "DISCOVERY COMPLETE " << C_DEF << endl; + std::cout << C_B_MAGENTA << "DISCOVERY COMPLETE " << C_DEF << std::endl; TestCommandType command; command.m_command = READY; - mp_commandpub->write(&command); + command_writer_->write(&command); - //cout << "WAITING FOR COMMAND RESPONSES "< lock(mutex_); comm_cond_.wait(lock, [&]() { @@ -446,7 +423,6 @@ bool MemoryTestPublisher::test( }); --comm_count_; lock.unlock(); - //cout << endl; //BEGIN THE TEST: auto t_start_ = std::chrono::steady_clock::now(); @@ -455,44 +431,39 @@ bool MemoryTestPublisher::test( { for (unsigned int count = 1; count <= n_samples; ++count) { - if (dynamic_data) + if (dynamic_data_) { - m_DynData->set_uint32_value(count, 0); - mp_datapub->write((void*)m_DynData); + m_DynData->set_uint32_value(0, count); + data_writer_->write(&m_DynData); } else { - mp_memory->seqnum = count; - mp_datapub->write((void*)mp_memory); + memory_->seqnum = count; + data_writer_->write((void*)memory_); } } t_end_ = std::chrono::steady_clock::now(); } command.m_command = STOP; - mp_commandpub->write(&command); + command_writer_->write(&command); if (m_status != 0) { - cout << "Error in test " << endl; + std::cout << "Error in test " << std::endl; return false; } //TEST FINISHED: - size_t removed = 0; - mp_datapub->removeAllChange(&removed); - //cout << " REMOVED: "<< removed<clear_history(&removed); - if (dynamic_data) + if (dynamic_data_) { - DynamicTypeBuilderFactory::delete_instance(); DynamicDataFactory::get_instance()->delete_data(m_DynData); - pubAttr = mp_datapub->getAttributes(); - Domain::removePublisher(mp_datapub); - Domain::unregisterType(mp_participant, "MemoryType"); } else { - delete(mp_memory); + delete(memory_); } return true; diff --git a/test/profiling/MemoryTestPublisher.h b/test/profiling/MemoryTestPublisher.h index 869937fd9f8..4c33ff54bb3 100644 --- a/test/profiling/MemoryTestPublisher.h +++ b/test/profiling/MemoryTestPublisher.h @@ -20,100 +20,158 @@ #ifndef MEMORYPUBLISHER_H_ #define MEMORYPUBLISHER_H_ +#include +#include + #include -#include "MemoryTestTypes.h" -#include -#include -#include -#include -#include -#include -#include -#include -#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include -#include -#include +#include "MemoryTestTypes.h" -class MemoryTestPublisher { +class MemoryTestPublisher +{ public: + MemoryTestPublisher(); virtual ~MemoryTestPublisher(); - eprosima::fastrtps::Participant* mp_participant; - eprosima::fastrtps::Publisher* mp_datapub; - eprosima::fastrtps::Publisher* mp_commandpub; - eprosima::fastrtps::Subscriber* mp_commandsub; - int n_subscribers; - unsigned int n_samples; - eprosima::fastrtps::SampleInfo_t m_sampleinfo; + eprosima::fastdds::dds::DomainParticipant* participant_ {nullptr}; + eprosima::fastdds::dds::Publisher* publisher_ {nullptr}; + eprosima::fastdds::dds::Subscriber* subscriber_ {nullptr}; + eprosima::fastdds::dds::TypeSupport command_type_ {new TestCommandDataType()}; + eprosima::fastdds::dds::TypeSupport data_type_; + eprosima::fastdds::dds::Topic* command_pub_topic_ {nullptr}; + eprosima::fastdds::dds::Topic* command_sub_topic_ {nullptr}; + eprosima::fastdds::dds::Topic* data_topic_ {nullptr}; + eprosima::fastdds::dds::DataWriter* command_writer_ {nullptr}; + eprosima::fastdds::dds::DataWriter* data_writer_ {nullptr}; + eprosima::fastdds::dds::DataReader* command_reader_ {nullptr}; + int n_subscribers {0}; + unsigned int n_samples {0}; std::mutex mutex_; - int disc_count_; + int disc_count_ {0}; std::condition_variable disc_cond_; - int comm_count_; + int comm_count_ {0}; std::condition_variable comm_cond_; - int data_count_; + int data_count_ {0}; std::condition_variable data_cond_; - int m_status; - unsigned int n_received; - bool n_export_csv; + int m_status {0}; + unsigned int n_received {0}; + bool n_export_csv {false}; std::string m_exportPrefix; - bool init(int n_sub, int n_sam, bool reliable, uint32_t pid, bool hostname, bool export_csv, - const std::string& export_prefix, - const eprosima::fastrtps::rtps::PropertyPolicy& part_property_policy, - const eprosima::fastrtps::rtps::PropertyPolicy& property_policy, - const std::string& sXMLConfigFile, uint32_t data_size, bool dynamic_types); - void run(uint32_t test_time); - bool test(uint32_t test_time, uint32_t datasize); - - class DataPubListener : public eprosima::fastrtps::PublisherListener + + bool init( + int n_sub, + int n_sam, + bool reliable, + uint32_t pid, + bool hostname, + bool export_csv, + const std::string& export_prefix, + const eprosima::fastrtps::rtps::PropertyPolicy& part_property_policy, + const eprosima::fastrtps::rtps::PropertyPolicy& property_policy, + const std::string& sXMLConfigFile, + uint32_t data_size, + bool dynamic_types); + void run( + uint32_t test_time); + bool test( + uint32_t test_time, + uint32_t datasize); + + class DataPubListener : public eprosima::fastdds::dds::DataWriterListener { public: - DataPubListener(MemoryTestPublisher* up) :mp_up(up), n_matched(0) {} - ~DataPubListener() {} - void onPublicationMatched(eprosima::fastrtps::Publisher* pub, - eprosima::fastrtps::rtps::MatchingInfo& info); - MemoryTestPublisher* mp_up; - int n_matched; - } m_datapublistener; - - class CommandPubListener : public eprosima::fastrtps::PublisherListener + + DataPubListener( + MemoryTestPublisher* up) + : up_(up) + { + } + + ~DataPubListener() = default; + + void on_publication_matched( + eprosima::fastdds::dds::DataWriter* writer, + const eprosima::fastdds::dds::PublicationMatchedStatus& info) override; + + MemoryTestPublisher* up_ {nullptr}; + + int n_matched {0}; + } + m_datapublistener {nullptr}; + + class CommandPubListener : public eprosima::fastdds::dds::DataWriterListener { public: - CommandPubListener(MemoryTestPublisher* up) :mp_up(up), n_matched(0) {} - ~CommandPubListener() {} - void onPublicationMatched(eprosima::fastrtps::Publisher* pub, - eprosima::fastrtps::rtps::MatchingInfo& info); - MemoryTestPublisher* mp_up; - int n_matched; - } m_commandpublistener; - - class CommandSubListener : public eprosima::fastrtps::SubscriberListener + + CommandPubListener( + MemoryTestPublisher* up) + : up_(up) + { + } + + ~CommandPubListener() + { + } + + void on_publication_matched( + eprosima::fastdds::dds::DataWriter* writer, + const eprosima::fastdds::dds::PublicationMatchedStatus& info) override; + + MemoryTestPublisher* up_ {nullptr}; + int n_matched {0}; + } + m_commandpublistener {nullptr}; + + class CommandSubListener : public eprosima::fastdds::dds::DataReaderListener { public: - CommandSubListener(MemoryTestPublisher* up) :mp_up(up), n_matched(0) {} - ~CommandSubListener() {} - void onSubscriptionMatched(eprosima::fastrtps::Subscriber* sub, - eprosima::fastrtps::rtps::MatchingInfo& into); - void onNewDataMessage(eprosima::fastrtps::Subscriber* sub); - MemoryTestPublisher* mp_up; - int n_matched; - } m_commandsublistener; + + CommandSubListener( + MemoryTestPublisher* up) + : up_(up) + { + } + + ~CommandSubListener() + { + } + + void on_data_available( + eprosima::fastdds::dds::DataReader* reader) override; + + void on_subscription_matched( + eprosima::fastdds::dds::DataReader* reader, + const eprosima::fastdds::dds::SubscriptionMatchedStatus& info) override; + + MemoryTestPublisher* up_ {nullptr}; + int n_matched {0}; + } + m_commandsublistener {nullptr}; TestCommandDataType command_t; std::string m_sXMLConfigFile; bool reliable_; - uint32_t m_data_size; - bool dynamic_data = false; + uint32_t m_data_size {0}; + bool dynamic_data_ {false}; // Static Data - MemoryType* mp_memory; + MemoryType* memory_ {nullptr}; MemoryDataType memory_t; // Dynamic Data - eprosima::fastrtps::types::DynamicData* m_DynData; - eprosima::fastrtps::types::DynamicPubSubType m_DynType; - eprosima::fastrtps::types::DynamicType_ptr m_pDynType; - eprosima::fastrtps::PublisherAttributes pubAttr; + eprosima::fastdds::dds::DynamicData::_ref_type m_DynData; + eprosima::fastdds::dds::DynamicType::_ref_type m_pDynType; + eprosima::fastdds::dds::DynamicPubSubType* dynamic_type_support_ {nullptr}; }; diff --git a/test/profiling/MemoryTestSubscriber.cpp b/test/profiling/MemoryTestSubscriber.cpp index ac533d408f3..100d21842fd 100644 --- a/test/profiling/MemoryTestSubscriber.cpp +++ b/test/profiling/MemoryTestSubscriber.cpp @@ -21,45 +21,28 @@ #include -#include +#include +#include +#include #include -#include +#include +#include +#include +#include +#include -using namespace eprosima::fastrtps; -using namespace eprosima::fastrtps::rtps; -using namespace eprosima::fastrtps::types; - -using std::cout; -using std::endl; +using namespace eprosima::fastdds::dds; MemoryTestSubscriber::MemoryTestSubscriber() - : mp_participant(nullptr) - , mp_commandpub(nullptr) - , mp_datasub(nullptr) - , mp_commandsub(nullptr) - , disc_count_(0) - , comm_count_(0) - , data_count_(0) - , m_status(0) - , n_received(0) - , n_samples(0) - , m_datasublistener(nullptr) - , m_commandpublistener(nullptr) - , m_commandsublistener(nullptr) - , m_echo(true) - , dynamic_data(false) - , mp_memory(nullptr) { - m_datasublistener.mp_up = this; - m_commandpublistener.mp_up = this; - m_commandsublistener.mp_up = this; - - + m_datasublistener.up_ = this; + m_commandpublistener.up_ = this; + m_commandsublistener.up_ = this; } MemoryTestSubscriber::~MemoryTestSubscriber() { - Domain::removeParticipant(mp_participant); + participant_->delete_contained_entities(); } bool MemoryTestSubscriber::init( @@ -68,8 +51,8 @@ bool MemoryTestSubscriber::init( bool reliable, uint32_t pid, bool hostname, - const PropertyPolicy& part_property_policy, - const PropertyPolicy& property_policy, + const eprosima::fastrtps::rtps::PropertyPolicy& part_property_policy, + const eprosima::fastrtps::rtps::PropertyPolicy& property_policy, const std::string& sXMLConfigFile, uint32_t data_size, bool dynamic_types) @@ -78,61 +61,79 @@ bool MemoryTestSubscriber::init( m_echo = echo; n_samples = nsam; m_data_size = data_size; - dynamic_data = dynamic_types; + dynamic_data_ = dynamic_types; - if (dynamic_data) // Dummy type registration + if (dynamic_data_) // Dummy type registration { // Create basic builders - DynamicTypeBuilder_ptr struct_type_builder(DynamicTypeBuilderFactory::get_instance()->create_struct_builder()); + DynamicTypeBuilderFactory::_ref_type factory {DynamicTypeBuilderFactory::get_instance()}; - // Add members to the struct. - struct_type_builder->add_member(0, "seqnum", DynamicTypeBuilderFactory::get_instance()->create_uint32_type()); - struct_type_builder->add_member(1, "data", - DynamicTypeBuilderFactory::get_instance()->create_sequence_builder( - DynamicTypeBuilderFactory::get_instance()->create_byte_type(), ::dds::core::LENGTH_UNLIMITED - )); - struct_type_builder->set_name("MemoryType"); + // Create basic builders + TypeDescriptor::_ref_type type_descriptor {traits::make_shared()}; + type_descriptor->kind(TK_STRUCTURE); + type_descriptor->name("MemoryType"); + DynamicTypeBuilder::_ref_type struct_type_builder(factory->create_type(type_descriptor)); + // Add members to the struct. + MemberDescriptor::_ref_type member_descriptor {traits::make_shared()}; + member_descriptor->type(factory->get_primitive_type(eprosima::fastdds::dds::TK_UINT32)); + member_descriptor->name("seqnum"); + struct_type_builder->add_member(member_descriptor); + member_descriptor = traits::make_shared(); + member_descriptor->type(factory->create_sequence_type(factory->get_primitive_type(eprosima::fastdds::dds:: + TK_BYTE), static_cast(LENGTH_UNLIMITED))->build()); + member_descriptor->name("data"); + struct_type_builder->add_member(member_descriptor); m_pDynType = struct_type_builder->build(); - m_DynType.SetDynamicType(m_pDynType); } // Create RTPSParticipant std::string participant_profile_name = "participant_profile"; - ParticipantAttributes PParam; - PParam.domainId = pid % 230; - PParam.rtps.setName("Participant_sub"); - PParam.rtps.properties = part_property_policy; + DomainParticipantQos participant_qos; + participant_qos.name("MemoryTest_Participant_Subscriber"); + participant_qos.properties(part_property_policy); if (m_sXMLConfigFile.length() > 0) { - mp_participant = Domain::createParticipant(participant_profile_name); + participant_ = DomainParticipantFactory::get_instance()->create_participant_with_profile(pid % 230, + participant_profile_name); } else { - mp_participant = Domain::createParticipant(PParam); + participant_ = DomainParticipantFactory::get_instance()->create_participant(pid % 230, participant_qos); } - if (mp_participant == nullptr) + if (nullptr == participant_) { return false; } - if (dynamic_data) + if (dynamic_data_) { - Domain::registerType(mp_participant, &m_DynType); + dynamic_type_support_ = new DynamicPubSubType(m_pDynType); + data_type_ = TypeSupport{dynamic_type_support_}; } else { - Domain::registerType(mp_participant, (TopicDataType*)&memory_t); + data_type_ = TypeSupport{new MemoryDataType()}; + } + participant_->register_type(data_type_); + participant_->register_type(command_type_); + + publisher_ = participant_->create_publisher(PUBLISHER_QOS_DEFAULT); + + if (nullptr == publisher_) + { + return false; + } + + subscriber_ = participant_->create_subscriber(SUBSCRIBER_QOS_DEFAULT); + + if (nullptr == subscriber_) + { + return false; } - Domain::registerType(mp_participant, (TopicDataType*)&command_t); - // Create Data Subscriber - std::string profile_name = "subscriber_profile"; - SubscriberAttributes SubDataparam; - SubDataparam.topic.topicDataType = "MemoryType"; - SubDataparam.topic.topicKind = NO_KEY; std::ostringstream st; st << "MemoryTest_"; if (hostname) @@ -140,35 +141,37 @@ bool MemoryTestSubscriber::init( st << asio::ip::host_name() << "_"; } st << pid << "_PUB2SUB"; - SubDataparam.topic.topicName = st.str(); - if (reliable) + data_topic_ = participant_->create_topic(st.str(), "MemoryType", TOPIC_QOS_DEFAULT); + + if (nullptr == data_topic_) { - SubDataparam.qos.m_reliability.kind = RELIABLE_RELIABILITY_QOS; + return false; } - SubDataparam.properties = property_policy; - if (m_data_size > 60000) + + // Create Data Subscriber + std::string profile_name = "subscriber_profile"; + DataReaderQos reader_qos; + if (reliable) { - SubDataparam.historyMemoryPolicy = eprosima::fastrtps::rtps::PREALLOCATED_WITH_REALLOC_MEMORY_MODE; + reader_qos.reliability().kind = RELIABLE_RELIABILITY_QOS; } + reader_qos.properties(property_policy); if (m_sXMLConfigFile.length() > 0) { - mp_datasub = Domain::createSubscriber(mp_participant, profile_name, &this->m_datasublistener); + data_reader_ = subscriber_->create_datareader_with_profile(data_topic_, profile_name, &this->m_datasublistener); } else { - mp_datasub = Domain::createSubscriber(mp_participant, SubDataparam, &this->m_datasublistener); + data_reader_ = subscriber_->create_datareader(data_topic_, reader_qos, &this->m_datasublistener); } - if (mp_datasub == nullptr) + if (nullptr == data_reader_) { return false; } //COMMAND PUBLISHER - PublisherAttributes PubCommandParam; - PubCommandParam.topic.topicDataType = "TestCommandType"; - PubCommandParam.topic.topicKind = NO_KEY; std::ostringstream pct; pct << "MemoryTest_Command_"; if (hostname) @@ -176,22 +179,25 @@ bool MemoryTestSubscriber::init( pct << asio::ip::host_name() << "_"; } pct << pid << "_SUB2PUB"; - PubCommandParam.topic.topicName = pct.str(); - PubCommandParam.topic.historyQos.kind = KEEP_ALL_HISTORY_QOS; - PubCommandParam.qos.m_durability.kind = TRANSIENT_LOCAL_DURABILITY_QOS; - PubCommandParam.qos.m_reliability.kind = RELIABLE_RELIABILITY_QOS; - PubCommandParam.qos.m_publishMode.kind = eprosima::fastrtps::SYNCHRONOUS_PUBLISH_MODE; + command_pub_topic_ = participant_->create_topic(pct.str(), "TestCommandType", TOPIC_QOS_DEFAULT); - mp_commandpub = Domain::createPublisher(mp_participant, PubCommandParam, &this->m_commandpublistener); + if (nullptr == command_pub_topic_) + { + return false; + } + + DataWriterQos writer_qos; + writer_qos.history().kind = KEEP_ALL_HISTORY_QOS; + writer_qos.durability().kind = TRANSIENT_LOCAL_DURABILITY_QOS; + writer_qos.reliability().kind = RELIABLE_RELIABILITY_QOS; + + command_writer_ = publisher_->create_datawriter(command_pub_topic_, writer_qos, &this->m_commandpublistener); - if (mp_commandpub == nullptr) + if (nullptr == command_writer_) { return false; } - SubscriberAttributes SubCommandParam; - SubCommandParam.topic.topicDataType = "TestCommandType"; - SubCommandParam.topic.topicKind = NO_KEY; std::ostringstream sct; sct << "MemoryTest_Command_"; if (hostname) @@ -199,123 +205,120 @@ bool MemoryTestSubscriber::init( sct << asio::ip::host_name() << "_"; } sct << pid << "_PUB2SUB"; - SubCommandParam.topic.topicName = sct.str(); - SubCommandParam.topic.historyQos.kind = KEEP_ALL_HISTORY_QOS; - SubCommandParam.qos.m_reliability.kind = RELIABLE_RELIABILITY_QOS; - SubCommandParam.qos.m_durability.kind = TRANSIENT_LOCAL_DURABILITY_QOS; + command_sub_topic_ = participant_->create_topic(sct.str(), "TestCommandType", TOPIC_QOS_DEFAULT); - mp_commandsub = Domain::createSubscriber(mp_participant, SubCommandParam, &this->m_commandsublistener); - - if (mp_commandsub == nullptr) + if (nullptr == command_sub_topic_) { return false; } - if (dynamic_data) + DataReaderQos command_reader_qos; + command_reader_qos.history().kind = KEEP_ALL_HISTORY_QOS; + command_reader_qos.durability().kind = TRANSIENT_LOCAL_DURABILITY_QOS; + command_reader_qos.reliability().kind = RELIABLE_RELIABILITY_QOS; + + command_reader_ = subscriber_->create_datareader(command_sub_topic_, command_reader_qos, + &this->m_commandsublistener); + + if (nullptr == command_reader_) { - DynamicTypeBuilderFactory::delete_instance(); - subAttr = mp_datasub->getAttributes(); - Domain::removeSubscriber(mp_datasub); - Domain::unregisterType(mp_participant, "MemoryType"); // Unregister as we will register it later with correct size + return false; } return true; } -void MemoryTestSubscriber::DataSubListener::onSubscriptionMatched( - Subscriber* /*sub*/, - MatchingInfo& info) +void MemoryTestSubscriber::DataSubListener::on_subscription_matched( + DataReader*, + const SubscriptionMatchedStatus& info) { - std::unique_lock lock(mp_up->mutex_); + std::unique_lock lock(up_->mutex_); - if (info.status == MATCHED_MATCHING) + if (0 < info.current_count_change) { - cout << C_MAGENTA << "Data Sub Matched " << C_DEF << endl; - ++mp_up->disc_count_; + std::cout << C_MAGENTA << "Data Sub Matched " << C_DEF << std::endl; } else { - cout << C_MAGENTA << "Data Sub unmatched " << C_DEF << endl; - --mp_up->disc_count_; + std::cout << C_MAGENTA << "Data Sub unmatched " << C_DEF << std::endl; } + up_->disc_count_ += info.current_count_change; lock.unlock(); - mp_up->disc_cond_.notify_one(); + up_->disc_cond_.notify_one(); } -void MemoryTestSubscriber::CommandPubListener::onPublicationMatched( - Publisher* /*pub*/, - MatchingInfo& info) +void MemoryTestSubscriber::CommandPubListener::on_publication_matched( + DataWriter*, + const PublicationMatchedStatus& info) { - std::unique_lock lock(mp_up->mutex_); + std::unique_lock lock(up_->mutex_); - if (info.status == MATCHED_MATCHING) + if (0 < info.current_count_change) { - cout << C_MAGENTA << "Command Pub Matched " << C_DEF << endl; - ++mp_up->disc_count_; + std::cout << C_MAGENTA << "Command Pub Matched " << C_DEF << std::endl; } else { - cout << C_MAGENTA << "Command Pub unmatched " << C_DEF << endl; - --mp_up->disc_count_; + std::cout << C_MAGENTA << "Command Pub unmatched " << C_DEF << std::endl; } + up_->disc_count_ += info.current_count_change; lock.unlock(); - mp_up->disc_cond_.notify_one(); + up_->disc_cond_.notify_one(); } -void MemoryTestSubscriber::CommandSubListener::onSubscriptionMatched( - Subscriber* /*sub*/, - MatchingInfo& info) +void MemoryTestSubscriber::CommandSubListener::on_subscription_matched( + DataReader*, + const SubscriptionMatchedStatus& info) { - std::unique_lock lock(mp_up->mutex_); + std::unique_lock lock(up_->mutex_); - if (info.status == MATCHED_MATCHING) + if (0 < info.current_count_change) { - cout << C_MAGENTA << "Command Sub Matched " << C_DEF << endl; - ++mp_up->disc_count_; + std::cout << C_MAGENTA << "Command Sub Matched " << C_DEF << std::endl; } else { - cout << C_MAGENTA << "Command Sub unmatched " << C_DEF << endl; - --mp_up->disc_count_; + std::cout << C_MAGENTA << "Command Sub unmatched " << C_DEF << std::endl; } + up_->disc_count_ += info.current_count_change; lock.unlock(); - mp_up->disc_cond_.notify_one(); + up_->disc_cond_.notify_one(); } -void MemoryTestSubscriber::CommandSubListener::onNewDataMessage( - Subscriber* subscriber) +void MemoryTestSubscriber::CommandSubListener::on_data_available( + DataReader* reader) { TestCommandType command; - if (subscriber->takeNextData(&command, &mp_up->m_sampleinfo)) + if (RETCODE_OK == reader->take_next_sample(&command, &up_->m_sampleinfo)) { - cout << "RCOMMAND: " << command.m_command << endl; + std::cout << "RCOMMAND: " << command.m_command << std::endl; if (command.m_command == READY) { - cout << "Publisher has new test ready..." << endl; - mp_up->mutex_.lock(); - ++mp_up->comm_count_; - mp_up->mutex_.unlock(); - mp_up->comm_cond_.notify_one(); + std::cout << "Publisher has new test ready..." << std::endl; + up_->mutex_.lock(); + ++up_->comm_count_; + up_->mutex_.unlock(); + up_->comm_cond_.notify_one(); } else if (command.m_command == STOP) { - cout << "Publisher has stopped the test" << endl; - mp_up->mutex_.lock(); - ++mp_up->data_count_; - mp_up->mutex_.unlock(); - mp_up->data_cond_.notify_one(); + std::cout << "Publisher has stopped the test" << std::endl; + up_->mutex_.lock(); + ++up_->data_count_; + up_->mutex_.unlock(); + up_->data_cond_.notify_one(); } else if (command.m_command == STOP_ERROR) { - cout << "Publisher has canceled the test" << endl; - mp_up->m_status = -1; - mp_up->mutex_.lock(); - ++mp_up->data_count_; - mp_up->mutex_.unlock(); - mp_up->data_cond_.notify_one(); + std::cout << "Publisher has canceled the test" << std::endl; + up_->m_status = -1; + up_->mutex_.lock(); + ++up_->data_count_; + up_->mutex_.unlock(); + up_->data_cond_.notify_one(); } else if (command.m_command == DEFAULT) { @@ -324,26 +327,27 @@ void MemoryTestSubscriber::CommandSubListener::onNewDataMessage( } } -void MemoryTestSubscriber::DataSubListener::onNewDataMessage( - Subscriber* subscriber) +void MemoryTestSubscriber::DataSubListener::on_data_available( + DataReader* reader) { - if (mp_up->dynamic_data) + if (up_->dynamic_data_) { - subscriber->takeNextData((void*)mp_up->m_DynData, &mp_up->m_sampleinfo); - ++mp_up->n_received; - if (mp_up->m_echo) + reader->take_next_sample(&up_->m_DynData, &up_->m_sampleinfo); + ++up_->n_received; + if (up_->m_echo) { - std::cout << "Received data: " << mp_up->m_DynData->get_uint32_value(0) - << "(" << mp_up->n_received << ")" << std::endl; + uint32_t seq_num {0}; + up_->m_DynData->get_uint32_value(seq_num, 0); + std::cout << "Received data: " << seq_num << "(" << up_->n_received << ")" << std::endl; } } else { - subscriber->takeNextData((void*)mp_up->mp_memory, &mp_up->m_sampleinfo); - ++mp_up->n_received; - if (mp_up->m_echo) + reader->take_next_sample((void*)up_->memory_, &up_->m_sampleinfo); + ++up_->n_received; + if (up_->m_echo) { - std::cout << "Received data: " << mp_up->mp_memory->seqnum << "(" << mp_up->n_received << ")" << std::endl; + std::cout << "Received data: " << up_->memory_->seqnum << "(" << up_->n_received << ")" << std::endl; } } } @@ -365,37 +369,15 @@ void MemoryTestSubscriber::run() bool MemoryTestSubscriber::test( uint32_t datasize) { - cout << "Preparing test with data size: " << datasize + 4 << endl; + std::cout << "Preparing test with data size: " << datasize + 4 << std::endl; - //cout << "Ready to start data size: " << m_datasize << " and demand; "<create_struct_builder()); - - // Add members to the struct. - struct_type_builder->add_member(0, "seqnum", - DynamicTypeBuilderFactory::get_instance()->create_uint32_type()); - struct_type_builder->add_member(1, "data", - DynamicTypeBuilderFactory::get_instance()->create_sequence_builder( - DynamicTypeBuilderFactory::get_instance()->create_byte_type(), datasize - )); - struct_type_builder->set_name("MemoryType"); - - m_pDynType = struct_type_builder->build(); - m_DynType.CleanDynamicType(); - m_DynType.SetDynamicType(m_pDynType); - - Domain::registerType(mp_participant, &m_DynType); - - mp_datasub = Domain::createSubscriber(mp_participant, subAttr, &m_datasublistener); - m_DynData = DynamicDataFactory::get_instance()->create_data(m_pDynType); } else { - mp_memory = new MemoryType(datasize); + memory_ = new MemoryType(datasize); } // Finally data matching @@ -406,7 +388,7 @@ bool MemoryTestSubscriber::test( }); disc_lock.unlock(); - cout << C_B_MAGENTA << "DISCOVERY COMPLETE " << C_DEF << endl; + std::cout << C_B_MAGENTA << "DISCOVERY COMPLETE " << C_DEF << std::endl; std::unique_lock lock(mutex_); if (comm_count_ == 0) @@ -420,8 +402,8 @@ bool MemoryTestSubscriber::test( n_received = 0; TestCommandType command; command.m_command = BEGIN; - cout << "Testing with data size: " << datasize + 4 << endl; - mp_commandpub->write(&command); + std::cout << "Testing with data size: " << datasize + 4 << std::endl; + command_writer_->write(&command); lock.lock(); data_cond_.wait(lock, [&]() @@ -431,17 +413,15 @@ bool MemoryTestSubscriber::test( --data_count_; lock.unlock(); - cout << "TEST OF SIZE: " << datasize + 4 << " ENDS" << endl; + std::cout << "TEST OF SIZE: " << datasize + 4 << " ENDS" << std::endl; std::this_thread::sleep_for(std::chrono::milliseconds(50)); - if (dynamic_data) + if (dynamic_data_) { - DynamicTypeBuilderFactory::delete_instance(); DynamicDataFactory::get_instance()->delete_data(m_DynData); - subAttr = mp_datasub->getAttributes(); } else { - delete(mp_memory); + delete(memory_); } if (m_status == -1) { diff --git a/test/profiling/MemoryTestSubscriber.h b/test/profiling/MemoryTestSubscriber.h index 5c44b202f95..98be00dd3da 100644 --- a/test/profiling/MemoryTestSubscriber.h +++ b/test/profiling/MemoryTestSubscriber.h @@ -20,93 +20,150 @@ #ifndef MEMORYTESTSUBSCRIBER_H_ #define MEMORYTESTSUBSCRIBER_H_ -#include #include + +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + #include "MemoryTestTypes.h" -#include -#include -#include -#include -#include -#include -#include -#include -#include class MemoryTestSubscriber { public: + MemoryTestSubscriber(); virtual ~MemoryTestSubscriber(); - eprosima::fastrtps::Participant* mp_participant; - eprosima::fastrtps::Publisher* mp_commandpub; - eprosima::fastrtps::Subscriber* mp_datasub; - eprosima::fastrtps::Subscriber* mp_commandsub; - eprosima::fastrtps::SampleInfo_t m_sampleinfo; + eprosima::fastdds::dds::DomainParticipant* participant_ {nullptr}; + eprosima::fastdds::dds::Publisher* publisher_ {nullptr}; + eprosima::fastdds::dds::Subscriber* subscriber_ {nullptr}; + eprosima::fastdds::dds::TypeSupport command_type_ {new TestCommandDataType()}; + eprosima::fastdds::dds::TypeSupport data_type_; + eprosima::fastdds::dds::Topic* command_pub_topic_ {nullptr}; + eprosima::fastdds::dds::Topic* command_sub_topic_ {nullptr}; + eprosima::fastdds::dds::Topic* data_topic_ {nullptr}; + eprosima::fastdds::dds::DataWriter* command_writer_ {nullptr}; + eprosima::fastdds::dds::DataReader* data_reader_ {nullptr}; + eprosima::fastdds::dds::DataReader* command_reader_ {nullptr}; + eprosima::fastdds::dds::SampleInfo m_sampleinfo; std::mutex mutex_; - int disc_count_; + int disc_count_ {0}; std::condition_variable disc_cond_; - int comm_count_; + int comm_count_ {0}; std::condition_variable comm_cond_; - int data_count_; + int data_count_ {0}; std::condition_variable data_cond_; - int m_status; - int n_received; - int n_samples; - bool init(bool echo, int nsam, bool reliable, uint32_t pid, bool hostname, - const eprosima::fastrtps::rtps::PropertyPolicy& part_property_policy, - const eprosima::fastrtps::rtps::PropertyPolicy& property_policy, - const std::string& sXMLConfigFile, uint32_t data_size, bool dynamic_types); + int m_status {0}; + int n_received {0}; + int n_samples {0}; + bool init( + bool echo, + int nsam, + bool reliable, + uint32_t pid, + bool hostname, + const eprosima::fastrtps::rtps::PropertyPolicy& part_property_policy, + const eprosima::fastrtps::rtps::PropertyPolicy& property_policy, + const std::string& sXMLConfigFile, + uint32_t data_size, + bool dynamic_types); void run(); - bool test(uint32_t datasize); + bool test( + uint32_t datasize); - class DataSubListener : public eprosima::fastrtps::SubscriberListener + class DataSubListener : public eprosima::fastdds::dds::DataReaderListener { public: - DataSubListener(MemoryTestSubscriber* up) :mp_up(up) {} - ~DataSubListener() {} - void onSubscriptionMatched(eprosima::fastrtps::Subscriber* sub, - eprosima::fastrtps::rtps::MatchingInfo& into); - void onNewDataMessage(eprosima::fastrtps::Subscriber* sub); - MemoryTestSubscriber* mp_up; - } m_datasublistener; - - class CommandPubListener : public eprosima::fastrtps::PublisherListener + + DataSubListener( + MemoryTestSubscriber* up) + : up_(up) + { + } + + ~DataSubListener() + { + } + + void on_data_available( + eprosima::fastdds::dds::DataReader* reader) override; + + void on_subscription_matched( + eprosima::fastdds::dds::DataReader* reader, + const eprosima::fastdds::dds::SubscriptionMatchedStatus& info) override; + + MemoryTestSubscriber* up_ {nullptr}; + } + m_datasublistener {nullptr}; + + class CommandPubListener : public eprosima::fastdds::dds::DataWriterListener { public: - CommandPubListener(MemoryTestSubscriber* up) :mp_up(up) {} - ~CommandPubListener() {} - void onPublicationMatched(eprosima::fastrtps::Publisher* pub, - eprosima::fastrtps::rtps::MatchingInfo& info); - MemoryTestSubscriber* mp_up; - } m_commandpublistener; - - class CommandSubListener : public eprosima::fastrtps::SubscriberListener + + CommandPubListener( + MemoryTestSubscriber* up) + : up_(up) + { + } + + ~CommandPubListener() + { + } + + void on_publication_matched( + eprosima::fastdds::dds::DataWriter* writer, + const eprosima::fastdds::dds::PublicationMatchedStatus& info) override; + + MemoryTestSubscriber* up_ {nullptr}; + } + m_commandpublistener {nullptr}; + + class CommandSubListener : public eprosima::fastdds::dds::DataReaderListener { public: - CommandSubListener(MemoryTestSubscriber* up) :mp_up(up) {} - ~CommandSubListener() {} - void onSubscriptionMatched(eprosima::fastrtps::Subscriber* sub, - eprosima::fastrtps::rtps::MatchingInfo& into); - void onNewDataMessage(eprosima::fastrtps::Subscriber* sub); - MemoryTestSubscriber* mp_up; - } m_commandsublistener; - - bool m_echo; - TestCommandDataType command_t; + + CommandSubListener( + MemoryTestSubscriber* up) + : up_(up) + { + } + + ~CommandSubListener() + { + } + + void on_data_available( + eprosima::fastdds::dds::DataReader* reader) override; + + void on_subscription_matched( + eprosima::fastdds::dds::DataReader* reader, + const eprosima::fastdds::dds::SubscriptionMatchedStatus& info) override; + + MemoryTestSubscriber* up_ {nullptr}; + } + m_commandsublistener {nullptr}; + + bool m_echo {true}; std::string m_sXMLConfigFile; - uint32_t m_data_size; - bool dynamic_data = false; + uint32_t m_data_size {0}; + bool dynamic_data_ {false}; // Static Data - MemoryType* mp_memory; - MemoryDataType memory_t; + MemoryType* memory_ {nullptr}; // Dynamic Data - eprosima::fastrtps::types::DynamicData* m_DynData; - eprosima::fastrtps::types::DynamicPubSubType m_DynType; - eprosima::fastrtps::types::DynamicType_ptr m_pDynType; - eprosima::fastrtps::SubscriberAttributes subAttr; + eprosima::fastdds::dds::DynamicData::_ref_type m_DynData; + eprosima::fastdds::dds::DynamicType::_ref_type m_pDynType; + eprosima::fastdds::dds::DynamicPubSubType* dynamic_type_support_ {nullptr}; }; #endif /* MEMORYTESTSUBSCRIBER_H_ */ diff --git a/test/profiling/MemoryTestTypes.cpp b/test/profiling/MemoryTestTypes.cpp index 8ebda73cb2a..127c9172c90 100644 --- a/test/profiling/MemoryTestTypes.cpp +++ b/test/profiling/MemoryTestTypes.cpp @@ -22,40 +22,60 @@ using namespace eprosima::fastrtps; using namespace eprosima::fastrtps::rtps; -bool MemoryDataType::serialize(void*data,SerializedPayload_t* payload) +bool MemoryDataType::serialize( + void* data, + SerializedPayload_t* payload) { MemoryType* lt = (MemoryType*)data; *(uint32_t*)payload->data = lt->seqnum; - *(uint32_t*)(payload->data+4) = (uint32_t)lt->data.size(); + *(uint32_t*)(payload->data + 4) = (uint32_t)lt->data.size(); //std::copy(lt->data.begin(),lt->data.end(),payload->data+8); memcpy(payload->data + 8, lt->data.data(), lt->data.size()); - payload->length = (uint32_t)(8+lt->data.size()); + payload->length = (uint32_t)(8 + lt->data.size()); return true; } -bool MemoryDataType::deserialize(SerializedPayload_t* payload,void * data) +bool MemoryDataType::serialize( + void* data, + SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t) +{ + return serialize(data, payload); +} + +bool MemoryDataType::deserialize( + SerializedPayload_t* payload, + void* data) { MemoryType* lt = (MemoryType*)data; lt->seqnum = *(uint32_t*)payload->data; - uint32_t siz = *(uint32_t*)(payload->data+4); - std::copy(payload->data+8,payload->data+8+siz,lt->data.begin()); + uint32_t siz = *(uint32_t*)(payload->data + 4); + std::copy(payload->data + 8, payload->data + 8 + siz, lt->data.begin()); return true; } -std::function MemoryDataType::getSerializedSizeProvider(void* data) +std::function MemoryDataType::getSerializedSizeProvider( + void* data) { return [data]() -> uint32_t - { - MemoryType *tdata = static_cast(data); - uint32_t size = 0; + { + MemoryType* tdata = static_cast(data); + uint32_t size = 0; + + size = (uint32_t)(sizeof(uint32_t) + sizeof(uint32_t) + tdata->data.size()); - size = (uint32_t)(sizeof(uint32_t) + sizeof(uint32_t) + tdata->data.size()); + return size; + }; +} - return size; - }; +std::function MemoryDataType::getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t) +{ + return getSerializedSizeProvider(data); } void* MemoryDataType::createData() @@ -63,21 +83,35 @@ void* MemoryDataType::createData() return (void*)new MemoryType(); } -void MemoryDataType::deleteData(void* data) + +void MemoryDataType::deleteData( + void* data) { delete((MemoryType*)data); } - -bool TestCommandDataType::serialize(void*data,SerializedPayload_t* payload) +bool TestCommandDataType::serialize( + void* data, + SerializedPayload_t* payload) { TestCommandType* t = (TestCommandType*)data; *(TESTCOMMAND*)payload->data = t->m_command; payload->length = 4; return true; } -bool TestCommandDataType::deserialize(SerializedPayload_t* payload,void * data) + +bool TestCommandDataType::serialize( + void* data, + SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t) +{ + return serialize(data, payload); +} + +bool TestCommandDataType::deserialize( + SerializedPayload_t* payload, + void* data) { TestCommandType* t = (TestCommandType*)data; // cout << "PAYLOAD LENGTH: "<length << endl; @@ -87,16 +121,24 @@ bool TestCommandDataType::deserialize(SerializedPayload_t* payload,void * data) return true; } -std::function TestCommandDataType::getSerializedSizeProvider(void*) +std::function TestCommandDataType::getSerializedSizeProvider( + void*) { return []() -> uint32_t - { - uint32_t size = 0; + { + uint32_t size = 0; - size = (uint32_t)sizeof(uint32_t); + size = (uint32_t)sizeof(uint32_t); - return size; - }; + return size; + }; +} + +std::function TestCommandDataType::getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t) +{ + return getSerializedSizeProvider(data); } void* TestCommandDataType::createData() @@ -104,7 +146,9 @@ void* TestCommandDataType::createData() return (void*)new TestCommandType(); } -void TestCommandDataType::deleteData(void* data) + +void TestCommandDataType::deleteData( + void* data) { delete((TestCommandType*)data); diff --git a/test/profiling/MemoryTestTypes.h b/test/profiling/MemoryTestTypes.h index 6c4155f34fa..6f6ec10fd2c 100644 --- a/test/profiling/MemoryTestTypes.h +++ b/test/profiling/MemoryTestTypes.h @@ -20,60 +20,106 @@ #ifndef MEMORYTESTTYPES_H_ #define MEMORYTESTTYPES_H_ -#include "fastrtps/fastrtps_all.h" +#include +#include +#include + +#include class MemoryType { - public: +public: + + uint32_t seqnum; + std::vector data; - uint32_t seqnum; - std::vector data; + MemoryType() + : seqnum(0) + { + } - MemoryType(): seqnum(0) {} + MemoryType( + uint32_t number) + : seqnum(0) + , data(number, 0) + { + } - MemoryType(uint32_t number) : - seqnum(0), data(number,0) {} + ~MemoryType() + { + } - ~MemoryType() {} }; -inline bool operator==(const MemoryType& lt1, const MemoryType& lt2) +inline bool operator ==( + const MemoryType& lt1, + const MemoryType& lt2) { - if(lt1.seqnum!=lt2.seqnum) + if (lt1.seqnum != lt2.seqnum) + { return false; - if(lt1.data.size()!=lt2.data.size()) + } + if (lt1.data.size() != lt2.data.size()) + { return false; - for(size_t i = 0;i getSerializedSizeProvider(void* data); - void* createData(); - void deleteData(void* data); - bool getKey(void* /*data*/, eprosima::fastrtps::rtps::InstanceHandle_t* /*ihandle*/, bool force_md5 = false) override { - (void)force_md5; - return false; - } +public: + + MemoryDataType() + { + setName("MemoryType"); + m_typeSize = 17000; + m_isGetKeyDefined = false; + } + + ~MemoryDataType() + { + } + + bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override; + bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + std::function getSerializedSizeProvider( + void* data) override; + std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + void* createData(); + void deleteData( + void* data); + bool getKey( + void* /*data*/, + eprosima::fastrtps::rtps::InstanceHandle_t* /*ihandle*/, + bool force_md5 = false) override + { + (void)force_md5; + return false; + } + }; -enum TESTCOMMAND:uint32_t{ +enum TESTCOMMAND : uint32_t +{ DEFAULT, READY, BEGIN, @@ -84,31 +130,61 @@ enum TESTCOMMAND:uint32_t{ typedef struct TestCommandType { TESTCOMMAND m_command; - TestCommandType(){ + TestCommandType() + { m_command = DEFAULT; } - TestCommandType(TESTCOMMAND com):m_command(com){} + + TestCommandType( + TESTCOMMAND com) + : m_command(com) + { + } + }TestCommandType; -class TestCommandDataType : public eprosima::fastrtps::TopicDataType +class TestCommandDataType : public eprosima::fastdds::dds::TopicDataType { - public: - TestCommandDataType() - { - setName("TestCommandType"); - m_typeSize = 4; - m_isGetKeyDefined = false; - }; - ~TestCommandDataType(){}; - bool serialize(void*data,eprosima::fastrtps::rtps::SerializedPayload_t* payload); - bool deserialize(eprosima::fastrtps::rtps::SerializedPayload_t* payload,void * data); - std::function getSerializedSizeProvider(void* data); - void* createData(); - void deleteData(void* data); - bool getKey(void* /*data*/, eprosima::fastrtps::rtps::InstanceHandle_t* /*ihandle*/, bool force_md5 = false) override { - (void)force_md5; - return false; - } +public: + + TestCommandDataType() + { + setName("TestCommandType"); + m_typeSize = 4; + m_isGetKeyDefined = false; + } + + ~TestCommandDataType() + { + } + + bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload) override; + bool serialize( + void* data, + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + bool deserialize( + eprosima::fastrtps::rtps::SerializedPayload_t* payload, + void* data) override; + std::function getSerializedSizeProvider( + void* data) override; + std::function getSerializedSizeProvider( + void* data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + void* createData(); + void deleteData( + void* data); + bool getKey( + void* /*data*/, + eprosima::fastrtps::rtps::InstanceHandle_t* /*ihandle*/, + bool force_md5 = false) override + { + (void)force_md5; + return false; + } + }; diff --git a/test/profiling/RTPSProfilingCommon.h b/test/profiling/RTPSProfilingCommon.h index 6eeeccddc81..5eb7d3f368d 100644 --- a/test/profiling/RTPSProfilingCommon.h +++ b/test/profiling/RTPSProfilingCommon.h @@ -1,11 +1,11 @@ -#ifndef _EPROSIMA_FASTRTPS_PROFILING_COMMON_ -#define _EPROSIMA_FASTRTPS_PROFILING_COMMON_ +#ifndef _EPROSIMA_FASTDDS_PROFILING_COMMON_ +#define _EPROSIMA_FASTDDS_PROFILING_COMMON_ #if defined(_WIN32) #define GET_PID _getpid #else #define GET_PID getpid -#endif +#endif // if defined(_WIN32) -#endif //_EPROSIMA_FASTRTPS_PROFILING_COMMON_ \ No newline at end of file +#endif //_EPROSIMA_FASTDDS_PROFILING_COMMON_ diff --git a/test/profiling/allocations/AllocTestCommon.cpp b/test/profiling/allocations/AllocTestCommon.cpp index be842d7d1c9..4c395124d96 100644 --- a/test/profiling/allocations/AllocTestCommon.cpp +++ b/test/profiling/allocations/AllocTestCommon.cpp @@ -23,12 +23,12 @@ #include #include #include -#include "osrf_testing_tools_cpp/memory_tools/memory_tools.hpp" + +#include using MemoryToolsService = osrf_testing_tools_cpp::memory_tools::MemoryToolsService; -namespace eprosima_profiling -{ +namespace eprosima_profiling { /** * Used to run callgrind with --zero-before=*callgrind_zero_count. @@ -57,28 +57,36 @@ static std::atomic_size_t g_phase(0u); static std::atomic g_allocationsPtr(g_allocations); static std::atomic g_deallocationsPtr(g_deallocations); -const std::regex is_fastrtps("fastrtps"); +const std::regex is_fastdds("fastdds"); -static void allocation_account(MemoryToolsService & service) +static void allocation_account( + MemoryToolsService& service) { // It makes no sense to track allocations if they don't come from our library auto stack = service.get_stack_trace(); - if (stack != nullptr && stack->matches_any_object_function(is_fastrtps)) + if (stack != nullptr && stack->matches_any_object_function(is_fastdds)) { (*g_allocationsPtr.load())++; - if (g_print_alloc_traces) service.print_backtrace(); + if (g_print_alloc_traces) + { + service.print_backtrace(); + } } service.ignore(); } -static void deallocation_account(MemoryToolsService & service) +static void deallocation_account( + MemoryToolsService& service) { // It makes no sense to track allocations if they don't come from our library auto stack = service.get_stack_trace(); - if (stack != nullptr && stack->matches_any_object_function(is_fastrtps)) + if (stack != nullptr && stack->matches_any_object_function(is_fastdds)) { (*g_deallocationsPtr.load())++; - if (g_print_dealloc_traces) service.print_backtrace(); + if (g_print_dealloc_traces) + { + service.print_backtrace(); + } } service.ignore(); } @@ -163,11 +171,11 @@ void print_results( const std::string& entity, const std::string& config) { - if(!g_print_results) + if (!g_print_results) { return; } - + std::string output_filename = file_prefix; if (file_prefix.length() == 0) { @@ -185,10 +193,10 @@ void print_results( if (pos == 0) { output_stream << "\"Discovery allocations\", \"Discovery deallocations\"," - << " \"First sample allocations\", \"First sample deallocations\"," - << " \"Data exchange allocations\", \"Data exchange deallocations\"," - << " \"Undiscovery allocations\", \"Undiscovery deallocations\"" - << std::endl; + << " \"First sample allocations\", \"First sample deallocations\"," + << " \"Data exchange allocations\", \"Data exchange deallocations\"," + << " \"Undiscovery allocations\", \"Undiscovery deallocations\"" + << std::endl; } for (size_t i = 0; i < 4; i++) diff --git a/test/profiling/allocations/AllocTestCommon.h b/test/profiling/allocations/AllocTestCommon.h index 0f321bae02c..85ff2a74557 100644 --- a/test/profiling/allocations/AllocTestCommon.h +++ b/test/profiling/allocations/AllocTestCommon.h @@ -17,13 +17,12 @@ * */ -#ifndef FASTRTPS_TEST_PROFILING_ALLOCATIONS_ALLOCTESTCOMMON_H_ -#define FASTRTPS_TEST_PROFILING_ALLOCATIONS_ALLOCTESTCOMMON_H_ +#ifndef FASTDDS_TEST_PROFILING_ALLOCATIONS_ALLOCTESTCOMMON_H_ +#define FASTDDS_TEST_PROFILING_ALLOCATIONS_ALLOCTESTCOMMON_H_ #include -namespace eprosima_profiling -{ +namespace eprosima_profiling { /** * Used to run callgrind with --zero-before=callgrind_zero_count. @@ -77,4 +76,4 @@ void print_results( } // namespace eprosima_profiling -#endif // FASTRTPS_TEST_PROFILING_ALLOCATIONS_ALLOCTESTCOMMON_H_ +#endif // FASTDDS_TEST_PROFILING_ALLOCATIONS_ALLOCTESTCOMMON_H_ diff --git a/test/profiling/allocations/AllocTestPublisher.cpp b/test/profiling/allocations/AllocTestPublisher.cpp index 21658794645..0bc00fc4340 100644 --- a/test/profiling/allocations/AllocTestPublisher.cpp +++ b/test/profiling/allocations/AllocTestPublisher.cpp @@ -17,129 +17,152 @@ * */ -#include "AllocTestPublisher.h" +#include "AllocTestPublisher.hpp" #include +#include -#include -#include -#include -#include -#include -#include +#include +#include +#include +#include +#include +#include #include "AllocTestCommon.h" +#include "AllocTestTypePubSubTypes.h" -using namespace eprosima::fastrtps; -using namespace eprosima::fastrtps::rtps; +using namespace eprosima::fastdds::dds; + +#define CHECK_RETURN_CODE(ret) \ + if (ReturnCode_t::RETCODE_OK != ret) \ + { \ + return false; \ + } + +#define CHECK_ENTITY_CREATION(entity) \ + if (nullptr != entity) \ + { \ + return false; \ + } AllocTestPublisher::AllocTestPublisher() - : mp_participant(nullptr) - , mp_publisher(nullptr) + : type_(new AllocTestTypePubSubType()) + , participant_(nullptr) + , topic_(nullptr) + , publisher_(nullptr) + , writer_(nullptr) + , profile_("") + , output_file_("") + , matched_(0) { +} - +AllocTestPublisher::~AllocTestPublisher() +{ + if (participant_ != nullptr) + { + participant_->delete_contained_entities(); + DomainParticipantFactory::get_shared_instance()->delete_participant(participant_); + participant_ = nullptr; + } } bool AllocTestPublisher::init( const char* profile, - int domainId, - const std::string& outputFile) + uint32_t domain_id, + const std::string& output_file) { - m_data.index(0); + data_.index(0); - m_profile = profile; - m_outputFile = outputFile; - Domain::loadXMLProfilesFile("test_xml_profile.xml"); + profile_ = profile; + output_file_ = output_file; - ParticipantAttributes participant_att; - if (eprosima::fastrtps::xmlparser::XMLP_ret::XML_OK == - eprosima::fastrtps::xmlparser::XMLProfileManager::fillParticipantAttributes("test_participant_profile", - participant_att)) - { - participant_att.domainId = domainId; - mp_participant = Domain::createParticipant(participant_att); - } + ReturnCode_t ret = ReturnCode_t::RETCODE_OK; - if (mp_participant == nullptr) - { - return false; - } + std::shared_ptr factory = DomainParticipantFactory::get_shared_instance(); + ret = factory->load_XML_profiles_file("test_xml_profile.xml"); + CHECK_RETURN_CODE(ret); - //REGISTER THE TYPE - Domain::registerType(mp_participant, &m_type); + DomainParticipantQos pqos; + ret = factory->get_participant_qos_from_profile("test_participant_profile", pqos); + CHECK_RETURN_CODE(ret); - //CREATE THE PUBLISHER - std::string prof("test_publisher_profile_"); - prof.append(profile); - mp_publisher = Domain::createPublisher(mp_participant, prof, (PublisherListener*)&m_listener); - if (mp_publisher == nullptr) - { - return false; - } + participant_ = factory->create_participant(domain_id, pqos); + CHECK_ENTITY_CREATION(participant_); - bool show_allocation_traces = std::getenv("FASTDDS_PROFILING_PRINT_TRACES") != nullptr; - eprosima_profiling::entities_created(show_allocation_traces); - return true; + ret = type_.register_type(participant_); + CHECK_RETURN_CODE(ret); -} + topic_ = participant_->create_topic("AllocTestTopic", type_.get_type_name(), TOPIC_QOS_DEFAULT); + CHECK_ENTITY_CREATION(topic_); -AllocTestPublisher::~AllocTestPublisher() -{ - Domain::removeParticipant(mp_participant); + publisher_ = participant_->create_publisher(PUBLISHER_QOS_DEFAULT); + CHECK_ENTITY_CREATION(publisher_); + + std::string prof = "test_publisher_profile_" + profile_; + writer_ = publisher_->create_datawriter_with_profile(topic_, prof, this); + CHECK_ENTITY_CREATION(writer_); + + bool show_allocation_traces = std::getenv("FASTDDS_PROFILING_PRINT_TRACES") != nullptr; + eprosima_profiling::entities_created(show_allocation_traces); + return ret == ReturnCode_t::RETCODE_OK; } -void AllocTestPublisher::PubListener::onPublicationMatched( - Publisher* /*pub*/, - MatchingInfo& info) +void AllocTestPublisher::on_publication_matched( + DataWriter* /*writer*/, + const PublicationMatchedStatus& status) { - std::unique_lock lock(mtx); - if (info.status == MATCHED_MATCHING) + if (status.current_count_change == 1) { - n_matched++; + matched_++; std::cout << "Publisher matched" << std::endl; } - else + else if (status.current_count_change == -1) { - n_matched--; + matched_--; std::cout << "Publisher unmatched" << std::endl; } - cv.notify_all(); + else + { + std::cout << status.current_count_change + << " is not a valid value for PublicationMatchedStatus current count change" << std::endl; + } + cv_.notify_all(); } -bool AllocTestPublisher::PubListener::is_matched() +bool AllocTestPublisher::is_matched() { - std::unique_lock lock(mtx); - return n_matched > 0; + return matched_ > 0; } -void AllocTestPublisher::PubListener::wait_match() +void AllocTestPublisher::wait_match() { - std::unique_lock lock(mtx); - cv.wait(lock, [this]() + std::unique_lock lck(mtx_); + cv_.wait(lck, [this]() { - return n_matched > 0; + return matched_ > 0; }); } -void AllocTestPublisher::PubListener::wait_unmatch() +void AllocTestPublisher::wait_unmatch() { - std::unique_lock lock(mtx); - cv.wait(lock, [this]() + std::unique_lock lck(mtx_); + cv_.wait(lck, [this]() { - return n_matched <= 0; + return matched_ <= 0; }); } void AllocTestPublisher::run( uint32_t samples, - bool wait_unmatch) + bool wait_unmatching) { // Restart callgrind graph eprosima_profiling::callgrind_zero_count(); std::cout << "Publisher waiting for subscriber..." << std::endl; - m_listener.wait_match(); + wait_match(); // Flush callgrind graph eprosima_profiling::callgrind_dump(); @@ -156,7 +179,7 @@ void AllocTestPublisher::run( } else { - std::cout << "Message with index: " << m_data.index() << " SENT" << std::endl; + std::cout << "Message with index: " << data_.index() << " SENT" << std::endl; } std::this_thread::sleep_for(std::chrono::milliseconds(500)); @@ -175,10 +198,10 @@ void AllocTestPublisher::run( eprosima_profiling::callgrind_dump(); eprosima_profiling::all_samples_exchanged(); - if (wait_unmatch) + if (wait_unmatching) { std::cout << "All messages have been sent. Waiting for subscriber to stop." << std::endl; - m_listener.wait_unmatch(); + wait_unmatch(); } else { @@ -189,16 +212,16 @@ void AllocTestPublisher::run( // Flush callgrind graph eprosima_profiling::callgrind_dump(); eprosima_profiling::undiscovery_finished(); - eprosima_profiling::print_results(m_outputFile, "publisher", m_profile); + eprosima_profiling::print_results(output_file_, "publisher", profile_); } bool AllocTestPublisher::publish() { - if (m_listener.is_matched()) + bool ret = false; + if (is_matched()) { - m_data.index(m_data.index() + 1); - mp_publisher->write((void*)&m_data); - return true; + data_.index(data_.index() + 1); + ret = writer_->write(&data_); } - return false; + return ret; } diff --git a/test/profiling/allocations/AllocTestPublisher.h b/test/profiling/allocations/AllocTestPublisher.h deleted file mode 100644 index 577c19f0ba5..00000000000 --- a/test/profiling/allocations/AllocTestPublisher.h +++ /dev/null @@ -1,70 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file AllocTestPublisher.h - * - */ - -#ifndef ALLOCTESTPUBLISHER_H_ -#define ALLOCTESTPUBLISHER_H_ - -#include "AllocTestTypePubSubTypes.h" - -#include -#include -#include -#include -#include -#include -#include "AllocTestType.h" - -class AllocTestPublisher { -public: - AllocTestPublisher(); - virtual ~AllocTestPublisher(); - //!Initialize - bool init(const char* profile, int domainId, const std::string& outputFile); - //!Publish a sample - bool publish(); - //!Run for number samples - void run(uint32_t number, bool wait_unmatch = false); -private: - AllocTestTypePubSubType m_type; - AllocTestType m_data; - eprosima::fastrtps::Participant* mp_participant; - eprosima::fastrtps::Publisher* mp_publisher; - std::string m_profile; - std::string m_outputFile; - class PubListener:public eprosima::fastrtps::PublisherListener - { - public: - PubListener():n_matched(0){}; - ~PubListener(){}; - void onPublicationMatched(eprosima::fastrtps::Publisher* pub, eprosima::fastrtps::rtps::MatchingInfo& info); - - bool is_matched(); - void wait_match(); - void wait_unmatch(); - - private: - int n_matched; - std::mutex mtx; - std::condition_variable cv; - }m_listener; -}; - - - -#endif /* ALLOCTESTPUBLISHER_H_ */ diff --git a/test/profiling/allocations/AllocTestPublisher.hpp b/test/profiling/allocations/AllocTestPublisher.hpp new file mode 100644 index 00000000000..14d17dfd08e --- /dev/null +++ b/test/profiling/allocations/AllocTestPublisher.hpp @@ -0,0 +1,99 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/** + * @file AllocTestPublisher.h + * + */ + +#ifndef _FASTDDS_ALLOCTESTPUBLISHER_H_ +#define _FASTDDS_ALLOCTESTPUBLISHER_H_ + +#include +#include +#include +#include +#include + +#include +#include +#include +#include +#include +#include +#include + +#include "AllocTestType.h" + +class AllocTestPublisher : public eprosima::fastdds::dds::DataWriterListener +{ +public: + + AllocTestPublisher(); + + virtual ~AllocTestPublisher(); + + //! Initialize + bool init( + const char* profile, + uint32_t domain_id, + const std::string& output_file); + + //! Publish a sample + bool publish(); + + //! Run for number samples + void run( + uint32_t number, + bool wait_unmatching); + + void on_publication_matched( + eprosima::fastdds::dds::DataWriter* writer, + const eprosima::fastdds::dds::PublicationMatchedStatus& status) override; + +private: + + bool is_matched(); + + void wait_match(); + + void wait_unmatch(); + + eprosima::fastdds::dds::TypeSupport type_; + + AllocTestType data_; + + eprosima::fastdds::dds::DomainParticipant* participant_; + + eprosima::fastdds::dds::Topic* topic_; + + eprosima::fastdds::dds::Publisher* publisher_; + + eprosima::fastdds::dds::DataWriter* writer_; + + std::string profile_; + + std::string output_file_; + + std::atomic matched_; + + mutable std::mutex mtx_; + + std::condition_variable cv_; + +}; + + + +#endif /* _FASTDDS_ALLOCTESTPUBLISHER_H_ */ diff --git a/test/profiling/allocations/AllocTestSubscriber.cpp b/test/profiling/allocations/AllocTestSubscriber.cpp index f535dab9dc6..9e9887e87e9 100644 --- a/test/profiling/allocations/AllocTestSubscriber.cpp +++ b/test/profiling/allocations/AllocTestSubscriber.cpp @@ -17,134 +17,166 @@ * */ -#include "AllocTestSubscriber.h" - +#include "AllocTestSubscriber.hpp" + +#include +#include +#include +#include +#include +#include #include -#include -#include -#include -#include -#include -#include +#include +#include +#include +#include +#include +#include +#include #include "AllocTestCommon.h" +#include "AllocTestTypePubSubTypes.h" + +using namespace eprosima::fastdds::dds; + +#define CHECK_RETURN_CODE(ret) \ + if (ReturnCode_t::RETCODE_OK != ret) \ + { \ + return false; \ + } -using namespace eprosima::fastrtps; -using namespace eprosima::fastrtps::rtps; +#define CHECK_ENTITY_CREATION(entity) \ + if (nullptr != entity) \ + { \ + return false; \ + } AllocTestSubscriber::AllocTestSubscriber() - : mp_participant(nullptr) - , mp_subscriber(nullptr) + : type_(new AllocTestTypePubSubType()) + , participant_(nullptr) + , topic_(nullptr) + , subscriber_(nullptr) + , reader_(nullptr) + , profile_("") + , output_file_("") + , matched_(0) + , samples_(0) { } -bool AllocTestSubscriber::init( - const char* profile, - int domainId, - const std::string& outputFile) +AllocTestSubscriber::~AllocTestSubscriber() { - m_profile = profile; - m_outputFile = outputFile; - Domain::loadXMLProfilesFile("test_xml_profile.xml"); - - ParticipantAttributes participant_att; - if (eprosima::fastrtps::xmlparser::XMLP_ret::XML_OK == - eprosima::fastrtps::xmlparser::XMLProfileManager::fillParticipantAttributes("test_participant_profile", - participant_att)) + if (participant_ != nullptr) { - participant_att.domainId = domainId; - mp_participant = Domain::createParticipant(participant_att); + participant_->delete_contained_entities(); + DomainParticipantFactory::get_shared_instance()->delete_participant(participant_); + participant_ = nullptr; } +} - if (mp_participant == nullptr) - { - return false; - } +bool AllocTestSubscriber::init( + const char* profile, + uint32_t domain_id, + const std::string& output_file) +{ + profile_ = profile; + output_file_ = output_file; - //REGISTER THE TYPE - Domain::registerType(mp_participant, &m_type); + ReturnCode_t ret = ReturnCode_t::RETCODE_OK; - //CREATE THE SUBSCRIBER - std::string prof("test_subscriber_profile_"); - prof.append(profile); - mp_subscriber = Domain::createSubscriber(mp_participant, prof, &m_listener); + std::shared_ptr factory = DomainParticipantFactory::get_shared_instance(); + ret = factory->load_XML_profiles_file("test_xml_profile.xml"); + CHECK_RETURN_CODE(ret); - if (mp_subscriber == nullptr) - { - return false; - } + DomainParticipantQos pqos; + ret = factory->get_participant_qos_from_profile("test_participant_profile", pqos); + CHECK_RETURN_CODE(ret); + + participant_ = factory->create_participant(domain_id, pqos); + CHECK_ENTITY_CREATION(participant_); + + ret = type_.register_type(participant_); + CHECK_RETURN_CODE(ret); + + topic_ = participant_->create_topic("AllocTestTopic", type_.get_type_name(), TOPIC_QOS_DEFAULT); + CHECK_ENTITY_CREATION(topic_); + + subscriber_ = participant_->create_subscriber(SUBSCRIBER_QOS_DEFAULT); + CHECK_ENTITY_CREATION(subscriber_); + + std::string prof = "test_subscriber_profile_" + profile_; + reader_ = subscriber_->create_datareader_with_profile(topic_, prof, this); + CHECK_ENTITY_CREATION(reader_); bool show_allocation_traces = std::getenv("FASTDDS_PROFILING_PRINT_TRACES") != nullptr; eprosima_profiling::entities_created(show_allocation_traces); - return true; + return ret == ReturnCode_t::RETCODE_OK; } -AllocTestSubscriber::~AllocTestSubscriber() +void AllocTestSubscriber::on_subscription_matched( + DataReader* /*reader*/, + const SubscriptionMatchedStatus& status) { - Domain::removeParticipant(mp_participant); -} - -void AllocTestSubscriber::SubListener::onSubscriptionMatched( - Subscriber* /*sub*/, - MatchingInfo& info) -{ - std::unique_lock lock(mtx); - if (info.status == MATCHED_MATCHING) + if (status.current_count_change == 1) { - n_matched++; + matched_++; std::cout << "Subscriber matched" << std::endl; } - else + else if (status.current_count_change == -1) { - n_matched--; + matched_--; std::cout << "Subscriber unmatched" << std::endl; } - cv.notify_all(); + else + { + std::cout << status.current_count_change + << " is not a valid value for SubscriptionMatchedStatus current count change" << std::endl; + } + cv_.notify_all(); } -void AllocTestSubscriber::SubListener::onNewDataMessage( - Subscriber* sub) +void AllocTestSubscriber::on_data_available( + DataReader* reader) { - if (sub->takeNextData((void*)&m_Hello, &m_info)) + SampleInfo info; + if (ReturnCode_t::RETCODE_OK == reader->take_next_sample(&data_, &info)) { - if (m_info.sampleKind == ALIVE) + if ((info.instance_state == ALIVE_INSTANCE_STATE) && (info.valid_data) && + (reader->is_sample_valid(&data_, &info))) { - std::unique_lock lock(mtx); - this->n_samples++; - // Print your structure data here. - std::cout << "Message " << m_Hello.index() << " RECEIVED" << std::endl; - cv.notify_all(); + samples_++; + std::cout << "Message " << data_.index() << " RECEIVED" << std::endl; + cv_.notify_all(); } } - } -void AllocTestSubscriber::SubListener::wait_match() +void AllocTestSubscriber::wait_match() { - std::unique_lock lock(mtx); - cv.wait(lock, [this]() + std::unique_lock lck(mtx_); + cv_.wait(lck, [this]() { - return n_matched > 0; + return matched_ > 0; }); } -void AllocTestSubscriber::SubListener::wait_unmatch() +void AllocTestSubscriber::wait_unmatch() { - std::unique_lock lock(mtx); - cv.wait(lock, [this]() + std::unique_lock lck(mtx_); + cv_.wait(lck, [this]() { - return n_matched <= 0; + return matched_ <= 0; }); } -void AllocTestSubscriber::SubListener::wait_until_total_received_at_least( +void AllocTestSubscriber::wait_until_total_received_at_least( uint32_t n) { - std::unique_lock lock(mtx); - cv.wait(lock, [this, n]() + std::unique_lock lock(mtx_); + cv_.wait(lock, [this, n]() { - return n_samples >= n; + return samples_ >= n; }); } @@ -156,36 +188,36 @@ void AllocTestSubscriber::run( void AllocTestSubscriber::run( uint32_t number, - bool wait_unmatch) + bool wait_unmatching) { // Restart callgrind graph eprosima_profiling::callgrind_zero_count(); std::cout << "Subscriber waiting for publisher..." << std::endl; - m_listener.wait_match(); + wait_match(); // Flush callgrind graph eprosima_profiling::callgrind_dump(); eprosima_profiling::discovery_finished(); std::cout << "Subscriber matched. Waiting for first sample..." << std::endl; - m_listener.wait_until_total_received_at_least(1ul); + wait_until_total_received_at_least(1ul); // Flush callgrind graph eprosima_profiling::callgrind_dump(); eprosima_profiling::first_sample_exchanged(); std::cout << "First sample received. Waiting for rest of samples..." << std::endl; - m_listener.wait_until_total_received_at_least(number); + wait_until_total_received_at_least(number); // Flush callgrind graph eprosima_profiling::callgrind_dump(); eprosima_profiling::all_samples_exchanged(); - if (wait_unmatch) + if (wait_unmatching) { std::cout << "All messages received. Waiting for publisher to stop." << std::endl; - m_listener.wait_unmatch(); + wait_unmatch(); } else { @@ -196,5 +228,5 @@ void AllocTestSubscriber::run( // Flush callgrind graph eprosima_profiling::callgrind_dump(); eprosima_profiling::undiscovery_finished(); - eprosima_profiling::print_results(m_outputFile, "subscriber", m_profile); + eprosima_profiling::print_results(output_file_, "subscriber", profile_); } diff --git a/test/profiling/allocations/AllocTestSubscriber.h b/test/profiling/allocations/AllocTestSubscriber.h deleted file mode 100644 index 64a53fa82c7..00000000000 --- a/test/profiling/allocations/AllocTestSubscriber.h +++ /dev/null @@ -1,104 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file AllocTestSubscriber.h - * - */ - -#ifndef ALLOCTESTSUBSCRIBER_H_ -#define ALLOCTESTSUBSCRIBER_H_ - -#include "AllocTestTypePubSubTypes.h" - -#include -#include -#include -#include -#include -#include -#include -#include -#include "AllocTestType.h" - -class AllocTestSubscriber -{ -public: - - AllocTestSubscriber(); - virtual ~AllocTestSubscriber(); - //!Initialize the subscriber - bool init( - const char* profile, - int domainId, - const std::string& outputFile); - //!RUN the subscriber - void run( - bool wait_unmatch = false); - //!Run the subscriber until number samples have been received. - void run( - uint32_t number, - bool wait_unmatch = false); - -private: - - eprosima::fastrtps::Participant* mp_participant; - eprosima::fastrtps::Subscriber* mp_subscriber; - std::string m_profile; - std::string m_outputFile; - -public: - - class SubListener : public eprosima::fastrtps::SubscriberListener - { - public: - - SubListener() - : n_matched(0) - , n_samples(0) - { - } - - ~SubListener() - { - } - - void onSubscriptionMatched( - eprosima::fastrtps::Subscriber* sub, - eprosima::fastrtps::rtps::MatchingInfo& info); - void onNewDataMessage( - eprosima::fastrtps::Subscriber* sub); - - void wait_match(); - void wait_unmatch(); - void wait_until_total_received_at_least( - uint32_t n); - - private: - - AllocTestType m_Hello; - eprosima::fastrtps::SampleInfo_t m_info; - int n_matched; - uint32_t n_samples; - std::mutex mtx; - std::condition_variable cv; - } - m_listener; - -private: - - AllocTestTypePubSubType m_type; -}; - -#endif /* ALLOCTESTSUBSCRIBER_H_ */ diff --git a/test/profiling/allocations/AllocTestSubscriber.hpp b/test/profiling/allocations/AllocTestSubscriber.hpp new file mode 100644 index 00000000000..6473235d630 --- /dev/null +++ b/test/profiling/allocations/AllocTestSubscriber.hpp @@ -0,0 +1,103 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/** + * @file AllocTestSubscriber.h + * + */ + +#ifndef _FASTDDS_ALLOCTESTSUBSCRIBER_H_ +#define _FASTDDS_ALLOCTESTSUBSCRIBER_H_ + +#include +#include +#include +#include +#include + +#include +#include +#include +#include +#include +#include +#include + +#include "AllocTestType.h" + +class AllocTestSubscriber : public eprosima::fastdds::dds::DataReaderListener +{ +public: + + AllocTestSubscriber(); + + virtual ~AllocTestSubscriber(); + + //! Initialize the subscriber + bool init( + const char* profile, + uint32_t domain_id, + const std::string& output_file); + + //! RUN the subscriber + void run( + bool wait_unmatch); + + void run( + uint32_t number, + bool wait_unmatching); + + void on_subscription_matched( + eprosima::fastdds::dds::DataReader* reader, + const eprosima::fastdds::dds::SubscriptionMatchedStatus& status) override; + + void on_data_available( + eprosima::fastdds::dds::DataReader* reader) override; + +private: + + void wait_match(); + + void wait_unmatch(); + + void wait_until_total_received_at_least( + uint32_t n); + + eprosima::fastdds::dds::TypeSupport type_; + + AllocTestType data_; + + eprosima::fastdds::dds::DomainParticipant* participant_; + + eprosima::fastdds::dds::Topic* topic_; + + eprosima::fastdds::dds::Subscriber* subscriber_; + + eprosima::fastdds::dds::DataReader* reader_; + + std::string profile_; + + std::string output_file_; + + std::atomic matched_; + + std::atomic samples_; + + mutable std::mutex mtx_; + + std::condition_variable cv_; + +}; + +#endif /* _FASTDDS_ALLOCTESTSUBSCRIBER_H_ */ diff --git a/test/profiling/allocations/AllocTestType.cxx b/test/profiling/allocations/AllocTestType.cxx deleted file mode 100644 index 58cc317296f..00000000000 --- a/test/profiling/allocations/AllocTestType.cxx +++ /dev/null @@ -1,124 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file AllocTestType.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "AllocTestType.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - - - - -AllocTestType::AllocTestType() -{ -} - -AllocTestType::~AllocTestType() -{ -} - -AllocTestType::AllocTestType( - const AllocTestType& x) -{ - m_index = x.m_index; -} - -AllocTestType::AllocTestType( - AllocTestType&& x) noexcept -{ - m_index = x.m_index; -} - -AllocTestType& AllocTestType::operator =( - const AllocTestType& x) -{ - - m_index = x.m_index; - return *this; -} - -AllocTestType& AllocTestType::operator =( - AllocTestType&& x) noexcept -{ - - m_index = x.m_index; - return *this; -} - -bool AllocTestType::operator ==( - const AllocTestType& x) const -{ - return (m_index == x.m_index); -} - -bool AllocTestType::operator !=( - const AllocTestType& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void AllocTestType::index( - uint32_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint32_t AllocTestType::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint32_t& AllocTestType::index() -{ - return m_index; -} - - -// Include auxiliary functions like for serializing/deserializing. -#include "AllocTestTypeCdrAux.ipp" - -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/test/profiling/allocations/AllocTestType.h b/test/profiling/allocations/AllocTestType.hpp similarity index 73% rename from test/profiling/allocations/AllocTestType.h rename to test/profiling/allocations/AllocTestType.hpp index e823f9360d1..46894facdf9 100644 --- a/test/profiling/allocations/AllocTestType.h +++ b/test/profiling/allocations/AllocTestType.hpp @@ -13,32 +13,17 @@ // limitations under the License. /*! - * @file AllocTestType.h + * @file AllocTestType.hpp * This header file contains the declaration of the described types in the IDL file. * * This file was generated by the tool fastddsgen. */ -#include -#include "AllocTestTypev1.h" +#ifndef _FAST_DDS_GENERATED_ALLOCTESTTYPE_HPP_ +#define _FAST_DDS_GENERATED_ALLOCTESTTYPE_HPP_ -#if FASTCDR_VERSION_MAJOR > 1 - -#ifndef _FAST_DDS_GENERATED_ALLOCTESTTYPE_H_ -#define _FAST_DDS_GENERATED_ALLOCTESTTYPE_H_ - -#include -#include #include -#include -#include -#include - -#include -#include -#include - - +#include #if defined(_WIN32) #if defined(EPROSIMA_USER_DLL_EXPORT) @@ -64,17 +49,6 @@ #define ALLOCTESTTYPE_DllAPI #endif // _WIN32 -namespace eprosima { -namespace fastcdr { -class Cdr; -class CdrSizeCalculator; -} // namespace fastcdr -} // namespace eprosima - - - - - /*! * @brief This class represents the structure AllocTestType defined by the user in the IDL file. * @ingroup AllocTestType @@ -86,73 +60,112 @@ class AllocTestType /*! * @brief Default constructor. */ - eProsima_user_DllExport AllocTestType(); + eProsima_user_DllExport AllocTestType() + { + } /*! * @brief Default destructor. */ - eProsima_user_DllExport ~AllocTestType(); + eProsima_user_DllExport ~AllocTestType() + { + } /*! * @brief Copy constructor. * @param x Reference to the object AllocTestType that will be copied. */ eProsima_user_DllExport AllocTestType( - const AllocTestType& x); + const AllocTestType& x) + { + m_index = x.m_index; + + } /*! * @brief Move constructor. * @param x Reference to the object AllocTestType that will be copied. */ eProsima_user_DllExport AllocTestType( - AllocTestType&& x) noexcept; + AllocTestType&& x) noexcept + { + m_index = x.m_index; + } /*! * @brief Copy assignment. * @param x Reference to the object AllocTestType that will be copied. */ eProsima_user_DllExport AllocTestType& operator =( - const AllocTestType& x); + const AllocTestType& x) + { + + m_index = x.m_index; + + return *this; + } /*! * @brief Move assignment. * @param x Reference to the object AllocTestType that will be copied. */ eProsima_user_DllExport AllocTestType& operator =( - AllocTestType&& x) noexcept; + AllocTestType&& x) noexcept + { + + m_index = x.m_index; + return *this; + } /*! * @brief Comparison operator. * @param x AllocTestType object to compare. */ eProsima_user_DllExport bool operator ==( - const AllocTestType& x) const; + const AllocTestType& x) const + { + return (m_index == x.m_index); + } /*! * @brief Comparison operator. * @param x AllocTestType object to compare. */ eProsima_user_DllExport bool operator !=( - const AllocTestType& x) const; + const AllocTestType& x) const + { + return !(*this == x); + } /*! * @brief This function sets a value in member index * @param _index New value for member index */ eProsima_user_DllExport void index( - uint32_t _index); + uint32_t _index) + { + m_index = _index; + } /*! * @brief This function returns the value of member index * @return Value of member index */ - eProsima_user_DllExport uint32_t index() const; + eProsima_user_DllExport uint32_t index() const + { + return m_index; + } /*! * @brief This function returns a reference to member index * @return Reference to member index */ - eProsima_user_DllExport uint32_t& index(); + eProsima_user_DllExport uint32_t& index() + { + return m_index; + } + + private: @@ -160,8 +173,6 @@ class AllocTestType }; -#endif // _FAST_DDS_GENERATED_ALLOCTESTTYPE_H_ - +#endif // _FAST_DDS_GENERATED_ALLOCTESTTYPE_HPP_ -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/test/profiling/allocations/AllocTestTypeCdrAux.hpp b/test/profiling/allocations/AllocTestTypeCdrAux.hpp index 9c9494f96d2..aac0de264cf 100644 --- a/test/profiling/allocations/AllocTestTypeCdrAux.hpp +++ b/test/profiling/allocations/AllocTestTypeCdrAux.hpp @@ -22,7 +22,7 @@ #ifndef _FAST_DDS_GENERATED_ALLOCTESTTYPECDRAUX_HPP_ #define _FAST_DDS_GENERATED_ALLOCTESTTYPECDRAUX_HPP_ -#include "AllocTestType.h" +#include "AllocTestType.hpp" constexpr uint32_t AllocTestType_max_cdr_typesize {8UL}; constexpr uint32_t AllocTestType_max_key_cdr_typesize {0UL}; @@ -34,8 +34,6 @@ namespace fastcdr { class Cdr; class CdrSizeCalculator; - - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const AllocTestType& data); diff --git a/test/profiling/allocations/AllocTestTypeCdrAux.ipp b/test/profiling/allocations/AllocTestTypeCdrAux.ipp index 42e4029739a..81f40a1acdd 100644 --- a/test/profiling/allocations/AllocTestTypeCdrAux.ipp +++ b/test/profiling/allocations/AllocTestTypeCdrAux.ipp @@ -34,8 +34,6 @@ using namespace eprosima::fastcdr::exception; namespace eprosima { namespace fastcdr { - - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, diff --git a/test/profiling/allocations/AllocTestTypePubSubTypes.cxx b/test/profiling/allocations/AllocTestTypePubSubTypes.cxx index 3aa18060dc2..1006b39cad8 100644 --- a/test/profiling/allocations/AllocTestTypePubSubTypes.cxx +++ b/test/profiling/allocations/AllocTestTypePubSubTypes.cxx @@ -19,18 +19,18 @@ * This file was generated by the tool fastddsgen. */ +#include "AllocTestTypePubSubTypes.h" +#include #include -#include "AllocTestTypePubSubTypes.h" #include "AllocTestTypeCdrAux.hpp" +#include "AllocTestTypeTypeObjectSupport.hpp" using SerializedPayload_t = eprosima::fastrtps::rtps::SerializedPayload_t; using InstanceHandle_t = eprosima::fastrtps::rtps::InstanceHandle_t; using DataRepresentationId_t = eprosima::fastdds::dds::DataRepresentationId_t; - - AllocTestTypePubSubType::AllocTestTypePubSubType() { setName("AllocTestType"); @@ -219,3 +219,11 @@ bool AllocTestTypePubSubType::getKey( return true; } +void AllocTestTypePubSubType::register_type_object_representation() const +{ + register_AllocTestType_type_objects(); +} + + +// Include auxiliary functions like for serializing/deserializing. +#include "AllocTestTypeCdrAux.ipp" diff --git a/test/profiling/allocations/AllocTestTypePubSubTypes.h b/test/profiling/allocations/AllocTestTypePubSubTypes.h index 80298136ea2..8ac424c490c 100644 --- a/test/profiling/allocations/AllocTestTypePubSubTypes.h +++ b/test/profiling/allocations/AllocTestTypePubSubTypes.h @@ -27,9 +27,9 @@ #include #include #include -#include +#include -#include "AllocTestType.h" +#include "AllocTestType.hpp" #if !defined(GEN_API_VER) || (GEN_API_VER != 2) @@ -38,8 +38,6 @@ #endif // GEN_API_VER - - /*! * @brief This class represents the TopicDataType of the type AllocTestType defined by the user in the IDL file. * @ingroup AllocTestType @@ -90,6 +88,9 @@ class AllocTestTypePubSubType : public eprosima::fastdds::dds::TopicDataType eProsima_user_DllExport void deleteData( void* data) override; + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + #ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED eProsima_user_DllExport inline bool is_bounded() const override { diff --git a/test/profiling/allocations/AllocTestTypeTypeObjectSupport.cxx b/test/profiling/allocations/AllocTestTypeTypeObjectSupport.cxx new file mode 100644 index 00000000000..8c9aada1b31 --- /dev/null +++ b/test/profiling/allocations/AllocTestTypeTypeObjectSupport.cxx @@ -0,0 +1,147 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file AllocTestTypeTypeObjectSupport.cxx + * Source file containing the implementation to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#include "AllocTestTypeTypeObjectSupport.hpp" + +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include + +#include "AllocTestType.hpp" + + +using namespace eprosima::fastdds::dds::xtypes; + +void register_AllocTestType_type_objects() +{ + static std::once_flag once_flag; + std::call_once(once_flag, []() + { + register_AllocTestType_type_identifier(); + + }); +} + +void register_AllocTestType_type_identifier() +{ + { + StructTypeFlag struct_flags_AllocTestType = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::NOT_APPLIED, + false, false); + ReturnCode_t return_code_AllocTestType; + TypeIdentifierPair type_ids_AllocTestType; + QualifiedTypeName type_name_AllocTestType = "AllocTestType"; + eprosima::fastcdr::optional type_ann_builtin_AllocTestType; + eprosima::fastcdr::optional ann_custom_AllocTestType; + CompleteTypeDetail detail_AllocTestType = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_AllocTestType, ann_custom_AllocTestType, type_name_AllocTestType.to_string()); + CompleteStructHeader header_AllocTestType; + header_AllocTestType = TypeObjectUtils::build_complete_struct_header(TypeIdentifier(), detail_AllocTestType); + CompleteStructMemberSeq member_seq_AllocTestType; + { + return_code_AllocTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_uint32_t", type_ids_AllocTestType); + + if (return_code_AllocTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "index Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_index = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_index; + MemberId member_id_index = 0x00000000; + if (EK_COMPLETE == type_ids_AllocTestType.type_identifier1()._d() || TK_NONE == type_ids_AllocTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_AllocTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_AllocTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_AllocTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_AllocTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_AllocTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_AllocTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_AllocTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_AllocTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_AllocTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_AllocTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_AllocTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_AllocTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_AllocTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_AllocTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_AllocTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_AllocTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_AllocTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_AllocTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_AllocTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_AllocTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_AllocTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_AllocTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_AllocTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_AllocTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_AllocTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_AllocTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_AllocTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_AllocTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_AllocTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_AllocTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_index = TypeObjectUtils::build_common_struct_member(member_id_index, member_flags_index, type_ids_AllocTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure index member TypeIdentifier inconsistent."); + return; + } + MemberName name_index = "index"; + eprosima::fastcdr::optional member_ann_builtin_index; + ann_custom_AllocTestType.reset(); + CompleteMemberDetail detail_index = TypeObjectUtils::build_complete_member_detail(name_index, member_ann_builtin_index, ann_custom_AllocTestType); + CompleteStructMember member_index = TypeObjectUtils::build_complete_struct_member(common_index, detail_index); + TypeObjectUtils::add_complete_struct_member(member_seq_AllocTestType, member_index); + } + CompleteStructType struct_type_AllocTestType = TypeObjectUtils::build_complete_struct_type(struct_flags_AllocTestType, header_AllocTestType, member_seq_AllocTestType); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_struct_type_object(struct_type_AllocTestType, type_name_AllocTestType.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "AllocTestType already registered in TypeObjectRegistry for a different type."); + } + return_code_AllocTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "AllocTestType", type_ids_AllocTestType); + if (return_code_AllocTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "AllocTestType: Given Struct TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } +} + diff --git a/test/profiling/allocations/AllocTestTypeTypeObjectSupport.hpp b/test/profiling/allocations/AllocTestTypeTypeObjectSupport.hpp new file mode 100644 index 00000000000..eb7db4ed676 --- /dev/null +++ b/test/profiling/allocations/AllocTestTypeTypeObjectSupport.hpp @@ -0,0 +1,54 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file AllocTestTypeTypeObjectSupport.hpp + * Header file containing the API required to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#ifndef _FAST_DDS_GENERATED_ALLOCTESTTYPE_TYPE_OBJECT_SUPPORT_HPP_ +#define _FAST_DDS_GENERATED_ALLOCTESTTYPE_TYPE_OBJECT_SUPPORT_HPP_ + + +#if defined(_WIN32) +#if defined(EPROSIMA_USER_DLL_EXPORT) +#define eProsima_user_DllExport __declspec( dllexport ) +#else +#define eProsima_user_DllExport +#endif // EPROSIMA_USER_DLL_EXPORT +#else +#define eProsima_user_DllExport +#endif // _WIN32 + +/** + * @brief Register every TypeObject representation defined in the IDL file in Fast DDS TypeObjectRegistry. + */ +eProsima_user_DllExport void register_AllocTestType_type_objects(); + +#ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +/** + * @brief Register AllocTestType related TypeIdentifier. + * Fully-descriptive TypeIdentifiers are directly registered. + * Hash TypeIdentifiers require to fill the TypeObject information and hash it, consequently, the TypeObject is + * indirectly registered as well. + */ +void register_AllocTestType_type_identifier(); + + +#endif // DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +#endif // _FAST_DDS_GENERATED_ALLOCTESTTYPE_TYPE_OBJECT_SUPPORT_HPP_ diff --git a/test/profiling/allocations/AllocTestTypev1.cxx b/test/profiling/allocations/AllocTestTypev1.cxx deleted file mode 100644 index 5d4e51b63a9..00000000000 --- a/test/profiling/allocations/AllocTestTypev1.cxx +++ /dev/null @@ -1,223 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file AllocTestType.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "AllocTestType.h" - -#if FASTCDR_VERSION_MAJOR == 1 - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - -namespace helper { namespace internal { - -enum class Size { - UInt8, - UInt16, - UInt32, - UInt64, -}; - -constexpr Size get_size(int s) { - return (s <= 8 ) ? Size::UInt8: - (s <= 16) ? Size::UInt16: - (s <= 32) ? Size::UInt32: Size::UInt64; -} - -template -struct FindTypeH; - -template<> -struct FindTypeH { - using type = std::uint8_t; -}; - -template<> -struct FindTypeH { - using type = std::uint16_t; -}; - -template<> -struct FindTypeH { - using type = std::uint32_t; -}; - -template<> -struct FindTypeH { - using type = std::uint64_t; -}; -} - -template -struct FindType { - using type = typename internal::FindTypeH::type; -}; -} - -#define AllocTestType_max_cdr_typesize 8ULL; - - - - -AllocTestType::AllocTestType() -{ - // unsigned long m_index - m_index = 0; - -} - -AllocTestType::~AllocTestType() -{ -} - -AllocTestType::AllocTestType( - const AllocTestType& x) -{ - m_index = x.m_index; - -} - -AllocTestType::AllocTestType( - AllocTestType&& x) noexcept -{ - m_index = x.m_index; - -} - -AllocTestType& AllocTestType::operator =( - const AllocTestType& x) -{ - m_index = x.m_index; - - return *this; -} - -AllocTestType& AllocTestType::operator =( - AllocTestType&& x) noexcept -{ - m_index = x.m_index; - - return *this; -} - -bool AllocTestType::operator ==( - const AllocTestType& x) const -{ - return (m_index == x.m_index); -} - -bool AllocTestType::operator !=( - const AllocTestType& x) const -{ - return !(*this == x); -} - -size_t AllocTestType::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return AllocTestType_max_cdr_typesize; -} - -size_t AllocTestType::getCdrSerializedSize( - const AllocTestType& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - return current_alignment - initial_alignment; -} - - -void AllocTestType::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_index; - -} - -void AllocTestType::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_index; - - -} - - -bool AllocTestType::isKeyDefined() -{ - return false; -} - -void AllocTestType::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ -void AllocTestType::index( - uint32_t _index) -{ - m_index = _index; -} - -/*! - * @brief This function returns the value of member index - * @return Value of member index - */ -uint32_t AllocTestType::index() const -{ - return m_index; -} - -/*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ -uint32_t& AllocTestType::index() -{ - return m_index; -} - - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/test/profiling/allocations/AllocTestTypev1.h b/test/profiling/allocations/AllocTestTypev1.h deleted file mode 100644 index 0195e31a222..00000000000 --- a/test/profiling/allocations/AllocTestTypev1.h +++ /dev/null @@ -1,216 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file AllocTestType.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#include - -#if FASTCDR_VERSION_MAJOR == 1 - -#ifndef _FAST_DDS_GENERATED_ALLOCTESTTYPE_H_ -#define _FAST_DDS_GENERATED_ALLOCTESTTYPE_H_ - - -#include - -#include -#include -#include -#include -#include -#include -#include - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define eProsima_user_DllExport -#endif // _WIN32 - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(ALLOCTESTTYPE_SOURCE) -#define ALLOCTESTTYPE_DllAPI __declspec( dllexport ) -#else -#define ALLOCTESTTYPE_DllAPI __declspec( dllimport ) -#endif // ALLOCTESTTYPE_SOURCE -#else -#define ALLOCTESTTYPE_DllAPI -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define ALLOCTESTTYPE_DllAPI -#endif // _WIN32 - -namespace eprosima { -namespace fastcdr { -class Cdr; -} // namespace fastcdr -} // namespace eprosima - - - - - -/*! - * @brief This class represents the structure AllocTestType defined by the user in the IDL file. - * @ingroup AllocTestType - */ -class AllocTestType -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport AllocTestType(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~AllocTestType(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object AllocTestType that will be copied. - */ - eProsima_user_DllExport AllocTestType( - const AllocTestType& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object AllocTestType that will be copied. - */ - eProsima_user_DllExport AllocTestType( - AllocTestType&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object AllocTestType that will be copied. - */ - eProsima_user_DllExport AllocTestType& operator =( - const AllocTestType& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object AllocTestType that will be copied. - */ - eProsima_user_DllExport AllocTestType& operator =( - AllocTestType&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x AllocTestType object to compare. - */ - eProsima_user_DllExport bool operator ==( - const AllocTestType& x) const; - - /*! - * @brief Comparison operator. - * @param x AllocTestType object to compare. - */ - eProsima_user_DllExport bool operator !=( - const AllocTestType& x) const; - - /*! - * @brief This function sets a value in member index - * @param _index New value for member index - */ - eProsima_user_DllExport void index( - uint32_t _index); - - /*! - * @brief This function returns the value of member index - * @return Value of member index - */ - eProsima_user_DllExport uint32_t index() const; - - /*! - * @brief This function returns a reference to member index - * @return Reference to member index - */ - eProsima_user_DllExport uint32_t& index(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const AllocTestType& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - uint32_t m_index; - -}; - - -#endif // _FAST_DDS_GENERATED_ALLOCTESTTYPE_H_ - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/test/profiling/allocations/AllocTest_main.cpp b/test/profiling/allocations/AllocTest_main.cpp index c014f69c616..933317510d2 100644 --- a/test/profiling/allocations/AllocTest_main.cpp +++ b/test/profiling/allocations/AllocTest_main.cpp @@ -17,30 +17,35 @@ * */ -#include "AllocTestPublisher.h" -#include "AllocTestSubscriber.h" - -#include #include +#include "AllocTestPublisher.hpp" +#include "AllocTestSubscriber.hpp" + using namespace eprosima; using namespace fastrtps; using namespace rtps; -int main(int argc, char** argv) +int main( + int argc, + char** argv) { - std::cout << "Starting "<< std::endl; + std::cout << "Starting " << std::endl; int type = 1; int domain = 1; bool wait_unmatch = false; const char* profile = "tl_be"; std::string outputFile = ""; - if(argc > 2) + if (argc > 2) { - if(strcmp(argv[1],"publisher")==0) + if (strcmp(argv[1], "publisher") == 0) + { type = 1; - else if(strcmp(argv[1],"subscriber")==0) + } + else if (strcmp(argv[1], "subscriber") == 0) + { type = 2; + } profile = argv[2]; @@ -57,7 +62,7 @@ int main(int argc, char** argv) } else { - std::cout + std::cout << "Syntax is AllocationTestExample , where:" << std::endl << " kind:" << std::endl << " publisher OR subscriber" << std::endl @@ -71,29 +76,28 @@ int main(int argc, char** argv) } - switch(type) + switch (type) { case 1: + { + AllocTestPublisher mypub; + if (mypub.init(profile, domain, outputFile)) { - AllocTestPublisher mypub; - if(mypub.init(profile, domain, outputFile)) - { - mypub.run(60, wait_unmatch); - } - break; + mypub.run(60, wait_unmatch); } + break; + } case 2: + { + AllocTestSubscriber mysub; + if (mysub.init(profile, domain, outputFile)) { - AllocTestSubscriber mysub; - if(mysub.init(profile, domain, outputFile)) - { - mysub.run(wait_unmatch); - } - break; + mysub.run(wait_unmatch); } + break; + } } - Domain::stopAll(); eprosima::fastdds::dds::Log::Reset(); return 0; diff --git a/test/profiling/allocations/CMakeLists.txt b/test/profiling/allocations/CMakeLists.txt index 8d67649d86f..b422176e11b 100644 --- a/test/profiling/allocations/CMakeLists.txt +++ b/test/profiling/allocations/CMakeLists.txt @@ -14,7 +14,7 @@ cmake_minimum_required(VERSION 3.20) -project(fastrtps_allocation_test VERSION 1 LANGUAGES CXX) +project(fastdds_allocation_test VERSION 1 LANGUAGES CXX) # Default to C++11 if(NOT CMAKE_CXX_STANDARD) @@ -25,7 +25,7 @@ if(CMAKE_COMPILER_IS_GNUCXX OR CMAKE_CXX_COMPILER_ID MATCHES "Clang") add_compile_options(-Wall -Wextra -Wpedantic -Werror) endif() -# Find requirements +# Find requirements (Version 1.4 is required, but their CMake does not set the version correctly) find_package(osrf_testing_tools_cpp) if (osrf_testing_tools_cpp_FOUND) @@ -44,7 +44,7 @@ if (osrf_testing_tools_cpp_FOUND) ) add_executable(AllocationTest ${ALLOCTEST_EXAMPLE_SOURCES_CXX} ${ALLOCTEST_EXAMPLE_SOURCES_CPP}) - target_link_libraries(AllocationTest fastrtps fastcdr foonathan_memory osrf_testing_tools_cpp::memory_tools) + target_link_libraries(AllocationTest fastdds fastcdr foonathan_memory osrf_testing_tools_cpp::memory_tools) install(TARGETS AllocationTest RUNTIME DESTINATION test/profiling/allocations/${BIN_INSTALL_DIR}) else(osrf_testing_tools_cpp_FOUND) diff --git a/test/profiling/allocations/test_xml_profile.xml b/test/profiling/allocations/test_xml_profile.xml index 37cf7a98755..7a4c935c265 100644 --- a/test/profiling/allocations/test_xml_profile.xml +++ b/test/profiling/allocations/test_xml_profile.xml @@ -1,5 +1,5 @@ - + diff --git a/test/system/tools/xmlvalidation/all_profile.xml b/test/system/tools/xmlvalidation/all_profile.xml index eb99327767f..ba9694c7fac 100644 --- a/test/system/tools/xmlvalidation/all_profile.xml +++ b/test/system/tools/xmlvalidation/all_profile.xml @@ -1,5 +1,5 @@ - + 1 @@ -293,10 +293,6 @@ 55 - - true - true - diff --git a/test/system/tools/xmlvalidation/dataReader_profile.xml b/test/system/tools/xmlvalidation/dataReader_profile.xml index c2c8ed17a84..4cbfb3dd8dc 100644 --- a/test/system/tools/xmlvalidation/dataReader_profile.xml +++ b/test/system/tools/xmlvalidation/dataReader_profile.xml @@ -1,5 +1,5 @@ - + diff --git a/test/system/tools/xmlvalidation/dataWriter_profile.xml b/test/system/tools/xmlvalidation/dataWriter_profile.xml index 718dff28343..b568bc3cc77 100644 --- a/test/system/tools/xmlvalidation/dataWriter_profile.xml +++ b/test/system/tools/xmlvalidation/dataWriter_profile.xml @@ -1,5 +1,5 @@ - + diff --git a/test/system/tools/xmlvalidation/domainParticipant_profile.xml b/test/system/tools/xmlvalidation/domainParticipant_profile.xml index 592fafb6143..54cca85719c 100644 --- a/test/system/tools/xmlvalidation/domainParticipant_profile.xml +++ b/test/system/tools/xmlvalidation/domainParticipant_profile.xml @@ -1,5 +1,5 @@ - + 11 @@ -292,10 +292,6 @@ 55 - - true - true - diff --git a/test/system/tools/xmlvalidation/librarySettings_profile.xml b/test/system/tools/xmlvalidation/librarySettings_profile.xml index bf2ba8075b6..fb4c8f8d92a 100644 --- a/test/system/tools/xmlvalidation/librarySettings_profile.xml +++ b/test/system/tools/xmlvalidation/librarySettings_profile.xml @@ -1,4 +1,4 @@ - + OFF diff --git a/test/system/tools/xmlvalidation/log_profile.xml b/test/system/tools/xmlvalidation/log_profile.xml index 58a2946c0ef..266a7ebd049 100644 --- a/test/system/tools/xmlvalidation/log_profile.xml +++ b/test/system/tools/xmlvalidation/log_profile.xml @@ -1,5 +1,5 @@ - + false diff --git a/test/system/tools/xmlvalidation/topic_profile.xml b/test/system/tools/xmlvalidation/topic_profile.xml index 07281bdb35f..6ffe6a728f1 100644 --- a/test/system/tools/xmlvalidation/topic_profile.xml +++ b/test/system/tools/xmlvalidation/topic_profile.xml @@ -1,5 +1,5 @@ - + diff --git a/test/system/tools/xmlvalidation/transportDescriptor_profile.xml b/test/system/tools/xmlvalidation/transportDescriptor_profile.xml index ade6ced192d..b63924ed044 100644 --- a/test/system/tools/xmlvalidation/transportDescriptor_profile.xml +++ b/test/system/tools/xmlvalidation/transportDescriptor_profile.xml @@ -1,5 +1,5 @@ - + diff --git a/test/system/tools/xmlvalidation/types_profile.xml b/test/system/tools/xmlvalidation/types_profile.xml index 71efc643154..a69160f7bf3 100644 --- a/test/system/tools/xmlvalidation/types_profile.xml +++ b/test/system/tools/xmlvalidation/types_profile.xml @@ -1,5 +1,5 @@ - + diff --git a/test/unittest/CMakeLists.txt b/test/unittest/CMakeLists.txt index 2eca626d922..f0a45665abe 100644 --- a/test/unittest/CMakeLists.txt +++ b/test/unittest/CMakeLists.txt @@ -12,38 +12,38 @@ # See the License for the specific language governing permissions and # limitations under the License. -add_compile_definitions(FASTRTPS_NO_LIB) +add_compile_definitions(FASTDDS_NO_LIB) -add_subdirectory(rtps/attributes) -add_subdirectory(rtps/common) -add_subdirectory(rtps/DataSharing) -add_subdirectory(rtps/builtin) -add_subdirectory(rtps/reader) -add_subdirectory(rtps/writer) -add_subdirectory(rtps/history) -add_subdirectory(rtps/resources/timedevent) -add_subdirectory(rtps/network) -if(NOT QNX) - add_subdirectory(rtps/flowcontrol) -endif() -add_subdirectory(rtps/persistence) -add_subdirectory(rtps/discovery) +add_subdirectory(cmake) add_subdirectory(dds/collections) add_subdirectory(dds/core) add_subdirectory(dds/participant) add_subdirectory(dds/publisher) +add_subdirectory(dds/status) add_subdirectory(dds/subscriber) add_subdirectory(dds/topic) add_subdirectory(dds/topic/DDSSQLFilter) -add_subdirectory(dds/status) -add_subdirectory(dynamic_types) -add_subdirectory(transport) +add_subdirectory(dds/xtypes/type_representation) add_subdirectory(logging) +add_subdirectory(rtps/attributes) +add_subdirectory(rtps/builtin) +add_subdirectory(rtps/common) +add_subdirectory(rtps/DataSharing) +add_subdirectory(rtps/discovery) +add_subdirectory(rtps/domain) +if(NOT QNX) + add_subdirectory(rtps/flowcontrol) +endif() +add_subdirectory(rtps/history) +add_subdirectory(rtps/network) +add_subdirectory(rtps/persistence) +add_subdirectory(rtps/reader) +add_subdirectory(rtps/resources/timedevent) +add_subdirectory(rtps/writer) +add_subdirectory(statistics/dds) +add_subdirectory(transport) add_subdirectory(utils) add_subdirectory(xmlparser) -add_subdirectory(xtypes) -add_subdirectory(statistics/dds) -add_subdirectory(cmake) if(SECURITY) add_subdirectory(security/authentication) diff --git a/test/unittest/cmake/CMakeLists.txt b/test/unittest/cmake/CMakeLists.txt index b86c7e8b30b..dddfc476798 100644 --- a/test/unittest/cmake/CMakeLists.txt +++ b/test/unittest/cmake/CMakeLists.txt @@ -16,8 +16,8 @@ # CMake modules tests ############################################################################### -set(build_dir "${fastrtps_BINARY_DIR}/test/force_cxx") -set(module_dir "${fastrtps_SOURCE_DIR}/cmake/common") +set(build_dir "${fastdds_BINARY_DIR}/test/force_cxx") +set(module_dir "${fastdds_SOURCE_DIR}/cmake/common") set(script "${CMAKE_CURRENT_LIST_DIR}/force_cxx/build.cmake") # The C++ sources use fold expressions which were introduced in C++17 diff --git a/test/unittest/common/GTestPrinters.hpp b/test/unittest/common/GTestPrinters.hpp deleted file mode 100644 index 48298803e00..00000000000 --- a/test/unittest/common/GTestPrinters.hpp +++ /dev/null @@ -1,43 +0,0 @@ -// Copyright 2022 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file GTestPrinters.hpp - * - */ - -#ifndef GTESTPRINTERS_HPP -#define GTESTPRINTERS_HPP - -#include - -/** - * Workaround for GCC to behave properly and let Google Test know what to do with null_types - * when printing an ASSERT/EXPECT result. Documentation can be found here: - * https://github.com/google/googletest/blob/main/googletest/include/gtest/gtest-printers.h - * - */ -namespace dds { -namespace core { -void PrintTo( - const null_type, - std::ostream* os) -{ - *os << "::dds::core::null_type"; -} - -} // namespace core -} // namespace dds - -#endif // GTESTPRINTERS_HPP diff --git a/test/unittest/dds/collections/CMakeLists.txt b/test/unittest/dds/collections/CMakeLists.txt index 42ba3a0b352..e8f3a9a5617 100644 --- a/test/unittest/dds/collections/CMakeLists.txt +++ b/test/unittest/dds/collections/CMakeLists.txt @@ -17,10 +17,6 @@ if(WIN32) endif() set(LOANABLE_SEQUENCE_TESTS_SOURCE - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/Log.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/OStreamConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutErrConsumer.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/LocatorWithMask.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/Time_t.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/network/utils/netmask_filter.cpp @@ -44,5 +40,9 @@ target_include_directories(LoanableSequenceTests PRIVATE ${Asio_INCLUDE_DIR} ${PROJECT_SOURCE_DIR}/include ${PROJECT_BINARY_DIR}/include ${PROJECT_SOURCE_DIR}/src/cpp) -target_link_libraries(LoanableSequenceTests GTest::gtest) +target_link_libraries(LoanableSequenceTests + fastcdr + fastdds::log + GTest::gtest + ) gtest_discover_tests(LoanableSequenceTests) diff --git a/test/unittest/dds/core/condition/CMakeLists.txt b/test/unittest/dds/core/condition/CMakeLists.txt index daff3d2a155..6e314e36e2a 100644 --- a/test/unittest/dds/core/condition/CMakeLists.txt +++ b/test/unittest/dds/core/condition/CMakeLists.txt @@ -13,10 +13,6 @@ # limitations under the License. set(LOG_SOURCES - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/Log.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/OStreamConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutErrConsumer.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/SystemInfo.cpp ) @@ -57,7 +53,11 @@ target_include_directories(ConditionTests PRIVATE ${PROJECT_BINARY_DIR}/include ${PROJECT_SOURCE_DIR}/src/cpp ) -target_link_libraries(ConditionTests GTest::gtest) +target_link_libraries(ConditionTests + fastcdr + fastdds::log + GTest::gtest + ) gtest_discover_tests(ConditionTests) ### ConditionNotifier ### @@ -91,7 +91,12 @@ target_include_directories(ConditionNotifierTests PRIVATE ${PROJECT_BINARY_DIR}/include ${PROJECT_SOURCE_DIR}/src/cpp ) -target_link_libraries(ConditionNotifierTests GTest::gtest GTest::gmock) +target_link_libraries(ConditionNotifierTests + fastcdr + fastdds::log + GTest::gtest + GTest::gmock + ) gtest_discover_tests(ConditionNotifierTests) ### StatusConditionImpl ### @@ -126,7 +131,12 @@ target_include_directories(StatusConditionImplTests PRIVATE ${PROJECT_BINARY_DIR}/include ${PROJECT_SOURCE_DIR}/src/cpp ) -target_link_libraries(StatusConditionImplTests GTest::gtest GTest::gmock) +target_link_libraries(StatusConditionImplTests + fastcdr + fastdds::log + GTest::gtest + GTest::gmock + ) gtest_discover_tests(StatusConditionImplTests) ### WaitSetImpl ### @@ -160,5 +170,10 @@ target_include_directories(WaitSetImplTests PRIVATE ${PROJECT_BINARY_DIR}/include ${PROJECT_SOURCE_DIR}/src/cpp ) -target_link_libraries(WaitSetImplTests GTest::gtest GTest::gmock) +target_link_libraries(WaitSetImplTests + fastcdr + fastdds::log + GTest::gtest + GTest::gmock + ) gtest_discover_tests(WaitSetImplTests) diff --git a/test/unittest/dds/core/condition/ConditionTests.cpp b/test/unittest/dds/core/condition/ConditionTests.cpp index 61bae7efaad..bd2f9f66e48 100644 --- a/test/unittest/dds/core/condition/ConditionTests.cpp +++ b/test/unittest/dds/core/condition/ConditionTests.cpp @@ -22,14 +22,12 @@ #include #include #include +#include #include #include -#include #include "../../../logging/mock/MockConsumer.h" -using eprosima::fastrtps::types::ReturnCode_t; - using namespace eprosima::fastdds::dds; using namespace std; @@ -98,7 +96,7 @@ TEST_F(ConditionTests, waitset_condition_management) WaitSet wait_set; // WaitSet should be created without conditions - EXPECT_EQ(ReturnCode_t::RETCODE_OK, wait_set.get_conditions(conditions)); + EXPECT_EQ(RETCODE_OK, wait_set.get_conditions(conditions)); EXPECT_TRUE(conditions.empty()); // This scope allows checking the wait_set behavior when the condition is destroyed @@ -106,36 +104,36 @@ TEST_F(ConditionTests, waitset_condition_management) GuardCondition condition; // Trying to detach without having attached - EXPECT_EQ(ReturnCode_t::RETCODE_PRECONDITION_NOT_MET, wait_set.detach_condition(condition)); + EXPECT_EQ(RETCODE_PRECONDITION_NOT_MET, wait_set.detach_condition(condition)); // Adding the same condition several times should always succeed and keep the list with a single condition for (int i = 0; i < 2; ++i) { - EXPECT_EQ(ReturnCode_t::RETCODE_OK, wait_set.attach_condition(condition)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, wait_set.get_conditions(conditions)); + EXPECT_EQ(RETCODE_OK, wait_set.attach_condition(condition)); + EXPECT_EQ(RETCODE_OK, wait_set.get_conditions(conditions)); EXPECT_EQ(1u, conditions.size()); EXPECT_NE(conditions.cend(), std::find(conditions.cbegin(), conditions.cend(), &condition)); } // Detaching the condition once should succeed - EXPECT_EQ(ReturnCode_t::RETCODE_OK, wait_set.detach_condition(condition)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, wait_set.get_conditions(conditions)); + EXPECT_EQ(RETCODE_OK, wait_set.detach_condition(condition)); + EXPECT_EQ(RETCODE_OK, wait_set.get_conditions(conditions)); EXPECT_TRUE(conditions.empty()); // Detaching a second time should fail - EXPECT_EQ(ReturnCode_t::RETCODE_PRECONDITION_NOT_MET, wait_set.detach_condition(condition)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, wait_set.get_conditions(conditions)); + EXPECT_EQ(RETCODE_PRECONDITION_NOT_MET, wait_set.detach_condition(condition)); + EXPECT_EQ(RETCODE_OK, wait_set.get_conditions(conditions)); EXPECT_TRUE(conditions.empty()); // Attach the condition again - EXPECT_EQ(ReturnCode_t::RETCODE_OK, wait_set.attach_condition(condition)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, wait_set.get_conditions(conditions)); + EXPECT_EQ(RETCODE_OK, wait_set.attach_condition(condition)); + EXPECT_EQ(RETCODE_OK, wait_set.get_conditions(conditions)); EXPECT_EQ(1u, conditions.size()); EXPECT_NE(conditions.cend(), std::find(conditions.cbegin(), conditions.cend(), &condition)); } // After the condition is destroyed, the wait_set should be empty - EXPECT_EQ(ReturnCode_t::RETCODE_OK, wait_set.get_conditions(conditions)); + EXPECT_EQ(RETCODE_OK, wait_set.get_conditions(conditions)); EXPECT_TRUE(conditions.empty()); } @@ -147,33 +145,33 @@ TEST_F(ConditionTests, waitset_wait) const eprosima::fastrtps::Duration_t timeout{ 1, 0 }; // Waiting on empty wait set should timeout - EXPECT_EQ(ReturnCode_t::RETCODE_TIMEOUT, wait_set.wait(conditions, timeout)); + EXPECT_EQ(RETCODE_TIMEOUT, wait_set.wait(conditions, timeout)); EXPECT_TRUE(conditions.empty()); // Attach condition - EXPECT_EQ(ReturnCode_t::RETCODE_OK, wait_set.attach_condition(condition)); + EXPECT_EQ(RETCODE_OK, wait_set.attach_condition(condition)); // Waiting on untriggered condition should timeout - EXPECT_EQ(ReturnCode_t::RETCODE_TIMEOUT, wait_set.wait(conditions, timeout)); + EXPECT_EQ(RETCODE_TIMEOUT, wait_set.wait(conditions, timeout)); EXPECT_TRUE(conditions.empty()); // Waiting on already triggered condition should inmediately return condition - EXPECT_EQ(ReturnCode_t::RETCODE_OK, condition.set_trigger_value(true)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, wait_set.wait(conditions, timeout)); + EXPECT_EQ(RETCODE_OK, condition.set_trigger_value(true)); + EXPECT_EQ(RETCODE_OK, wait_set.wait(conditions, timeout)); EXPECT_EQ(1u, conditions.size()); EXPECT_NE(conditions.cend(), std::find(conditions.cbegin(), conditions.cend(), &condition)); // Adding a non-triggered condition while waiting should timeout - EXPECT_EQ(ReturnCode_t::RETCODE_OK, condition.set_trigger_value(false)); + EXPECT_EQ(RETCODE_OK, condition.set_trigger_value(false)); { GuardCondition non_triggered_condition; std::thread thr_add_non_triggered([&]() { std::this_thread::sleep_for(std::chrono::milliseconds(200)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, wait_set.attach_condition(non_triggered_condition)); + EXPECT_EQ(RETCODE_OK, wait_set.attach_condition(non_triggered_condition)); }); - EXPECT_EQ(ReturnCode_t::RETCODE_TIMEOUT, wait_set.wait(conditions, timeout)); + EXPECT_EQ(RETCODE_TIMEOUT, wait_set.wait(conditions, timeout)); EXPECT_TRUE(conditions.empty()); thr_add_non_triggered.join(); } @@ -183,27 +181,27 @@ TEST_F(ConditionTests, waitset_wait) std::thread thr_set_trigger([&]() { std::this_thread::sleep_for(std::chrono::milliseconds(200)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, condition.set_trigger_value(true)); + EXPECT_EQ(RETCODE_OK, condition.set_trigger_value(true)); }); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, wait_set.wait(conditions, timeout)); + EXPECT_EQ(RETCODE_OK, wait_set.wait(conditions, timeout)); EXPECT_EQ(1u, conditions.size()); EXPECT_NE(conditions.cend(), std::find(conditions.cbegin(), conditions.cend(), &condition)); thr_set_trigger.join(); } // Two threads are not allowed to wait at the same time - EXPECT_EQ(ReturnCode_t::RETCODE_OK, condition.set_trigger_value(false)); + EXPECT_EQ(RETCODE_OK, condition.set_trigger_value(false)); { std::thread thr_second_wait([&wait_set, &timeout]() { std::this_thread::sleep_for(std::chrono::milliseconds(200)); ConditionSeq conds; - EXPECT_EQ(ReturnCode_t::RETCODE_PRECONDITION_NOT_MET, wait_set.wait(conds, timeout)); + EXPECT_EQ(RETCODE_PRECONDITION_NOT_MET, wait_set.wait(conds, timeout)); EXPECT_TRUE(conds.empty()); }); - EXPECT_EQ(ReturnCode_t::RETCODE_TIMEOUT, wait_set.wait(conditions, timeout)); + EXPECT_EQ(RETCODE_TIMEOUT, wait_set.wait(conditions, timeout)); EXPECT_TRUE(conditions.empty()); thr_second_wait.join(); } @@ -211,7 +209,7 @@ TEST_F(ConditionTests, waitset_wait) // Waiting forever and adding a triggered condition should wake and only return the added condition { GuardCondition triggered_condition; - EXPECT_EQ(ReturnCode_t::RETCODE_OK, triggered_condition.set_trigger_value(true)); + EXPECT_EQ(RETCODE_OK, triggered_condition.set_trigger_value(true)); std::thread thr_add_triggered([&]() { @@ -219,7 +217,7 @@ TEST_F(ConditionTests, waitset_wait) wait_set.attach_condition(triggered_condition); }); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, wait_set.wait(conditions, eprosima::fastrtps::c_TimeInfinite)); + EXPECT_EQ(RETCODE_OK, wait_set.wait(conditions, eprosima::fastrtps::c_TimeInfinite)); EXPECT_EQ(1u, conditions.size()); EXPECT_EQ(conditions.cend(), std::find(conditions.cbegin(), conditions.cend(), &condition)); EXPECT_NE(conditions.cend(), std::find(conditions.cbegin(), conditions.cend(), &triggered_condition)); @@ -232,9 +230,9 @@ TEST_F(ConditionTests, guard_condition_methods) GuardCondition cond; EXPECT_FALSE(cond.get_trigger_value()); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, cond.set_trigger_value(true)); + EXPECT_EQ(RETCODE_OK, cond.set_trigger_value(true)); EXPECT_TRUE(cond.get_trigger_value()); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, cond.set_trigger_value(false)); + EXPECT_EQ(RETCODE_OK, cond.set_trigger_value(false)); EXPECT_FALSE(cond.get_trigger_value()); } @@ -252,11 +250,11 @@ TEST_F(ConditionTests, status_condition_methods) // According to the DDS standard, StatusCondition should start with all statuses enabled EXPECT_EQ(mask_all.to_string(), cond.get_enabled_statuses().to_string()); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, cond.set_enabled_statuses(mask_single)); + EXPECT_EQ(RETCODE_OK, cond.set_enabled_statuses(mask_single)); EXPECT_EQ(mask_single.to_string(), cond.get_enabled_statuses().to_string()); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, cond.set_enabled_statuses(mask_none)); + EXPECT_EQ(RETCODE_OK, cond.set_enabled_statuses(mask_none)); EXPECT_EQ(mask_none.to_string(), cond.get_enabled_statuses().to_string()); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, cond.set_enabled_statuses(mask_all)); + EXPECT_EQ(RETCODE_OK, cond.set_enabled_statuses(mask_all)); EXPECT_EQ(mask_all.to_string(), cond.get_enabled_statuses().to_string()); } @@ -275,7 +273,7 @@ TEST_F(ConditionTests, status_condition_trigger) auto wait_for_trigger = [&]() { - EXPECT_EQ(ReturnCode_t::RETCODE_OK, wait_set.wait(conditions, eprosima::fastrtps::c_TimeInfinite)); + EXPECT_EQ(RETCODE_OK, wait_set.wait(conditions, eprosima::fastrtps::c_TimeInfinite)); EXPECT_EQ(1u, conditions.size()); EXPECT_EQ(&cond, conditions[0]); EXPECT_TRUE(cond.get_trigger_value()); @@ -284,13 +282,13 @@ TEST_F(ConditionTests, status_condition_trigger) auto expect_no_trigger = [&]() { EXPECT_FALSE(cond.get_trigger_value()); - EXPECT_EQ(ReturnCode_t::RETCODE_TIMEOUT, wait_set.wait(conditions, timeout)); + EXPECT_EQ(RETCODE_TIMEOUT, wait_set.wait(conditions, timeout)); EXPECT_TRUE(conditions.empty()); }; ASSERT_NE(nullptr, cond.get_impl()); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, wait_set.attach_condition(cond)); + EXPECT_EQ(RETCODE_OK, wait_set.attach_condition(cond)); // Condition should be untriggered upon creation EXPECT_EQ(mask_all.to_string(), cond.get_enabled_statuses().to_string()); @@ -305,7 +303,7 @@ TEST_F(ConditionTests, status_condition_trigger) } // Setting mask to one_mask should untrigger - EXPECT_EQ(ReturnCode_t::RETCODE_OK, cond.set_enabled_statuses(one_mask)); + EXPECT_EQ(RETCODE_OK, cond.set_enabled_statuses(one_mask)); EXPECT_EQ(one_mask.to_string(), cond.get_enabled_statuses().to_string()); expect_no_trigger(); @@ -344,7 +342,7 @@ TEST_F(ConditionTests, status_condition_trigger) // Setting mask to other_mask should trigger { std::thread wait_thr(wait_for_trigger); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, cond.set_enabled_statuses(other_mask)); + EXPECT_EQ(RETCODE_OK, cond.set_enabled_statuses(other_mask)); EXPECT_EQ(other_mask.to_string(), cond.get_enabled_statuses().to_string()); wait_thr.join(); } @@ -354,7 +352,7 @@ TEST_F(ConditionTests, status_condition_trigger) wait_for_trigger(); // Setting mask to one_mask should not affect trigger - EXPECT_EQ(ReturnCode_t::RETCODE_OK, cond.set_enabled_statuses(one_mask)); + EXPECT_EQ(RETCODE_OK, cond.set_enabled_statuses(one_mask)); EXPECT_EQ(one_mask.to_string(), cond.get_enabled_statuses().to_string()); wait_for_trigger(); @@ -363,12 +361,12 @@ TEST_F(ConditionTests, status_condition_trigger) wait_for_trigger(); // Setting mask to other_mask should untrigger - EXPECT_EQ(ReturnCode_t::RETCODE_OK, cond.set_enabled_statuses(other_mask)); + EXPECT_EQ(RETCODE_OK, cond.set_enabled_statuses(other_mask)); EXPECT_EQ(other_mask.to_string(), cond.get_enabled_statuses().to_string()); expect_no_trigger(); // Setting mask to one_mask should trigger - EXPECT_EQ(ReturnCode_t::RETCODE_OK, cond.set_enabled_statuses(one_mask)); + EXPECT_EQ(RETCODE_OK, cond.set_enabled_statuses(one_mask)); EXPECT_EQ(one_mask.to_string(), cond.get_enabled_statuses().to_string()); EXPECT_TRUE(cond.get_trigger_value()); wait_for_trigger(); diff --git a/test/unittest/dds/core/condition/StatusConditionImplTests.cpp b/test/unittest/dds/core/condition/StatusConditionImplTests.cpp index 90b42f2d149..aa67696ec97 100644 --- a/test/unittest/dds/core/condition/StatusConditionImplTests.cpp +++ b/test/unittest/dds/core/condition/StatusConditionImplTests.cpp @@ -39,11 +39,11 @@ TEST(StatusConditionImplTests, enabled_status_management) // According to the DDS standard, StatusCondition should start with all statuses enabled EXPECT_EQ(mask_all.to_string(), uut.get_enabled_statuses().to_string()); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, uut.set_enabled_statuses(mask_single)); + EXPECT_EQ(RETCODE_OK, uut.set_enabled_statuses(mask_single)); EXPECT_EQ(mask_single.to_string(), uut.get_enabled_statuses().to_string()); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, uut.set_enabled_statuses(mask_none)); + EXPECT_EQ(RETCODE_OK, uut.set_enabled_statuses(mask_none)); EXPECT_EQ(mask_none.to_string(), uut.get_enabled_statuses().to_string()); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, uut.set_enabled_statuses(mask_all)); + EXPECT_EQ(RETCODE_OK, uut.set_enabled_statuses(mask_all)); EXPECT_EQ(mask_all.to_string(), uut.get_enabled_statuses().to_string()); } @@ -71,7 +71,7 @@ TEST(StatusConditionImplTests, notify_trigger) EXPECT_TRUE(uut.get_trigger_value()); // Setting mask to one_mask should untrigger - EXPECT_EQ(ReturnCode_t::RETCODE_OK, uut.set_enabled_statuses(one_mask)); + EXPECT_EQ(RETCODE_OK, uut.set_enabled_statuses(one_mask)); EXPECT_EQ(one_mask.to_string(), uut.get_enabled_statuses().to_string()); EXPECT_FALSE(uut.get_trigger_value()); @@ -113,7 +113,7 @@ TEST(StatusConditionImplTests, notify_trigger) // Setting mask to other_mask should trigger auto& call3 = EXPECT_CALL(notifier, notify()).Times(1).After(call2); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, uut.set_enabled_statuses(other_mask)); + EXPECT_EQ(RETCODE_OK, uut.set_enabled_statuses(other_mask)); EXPECT_EQ(other_mask.to_string(), uut.get_enabled_statuses().to_string()); // Triggering one_mask should not affect trigger @@ -122,7 +122,7 @@ TEST(StatusConditionImplTests, notify_trigger) EXPECT_TRUE(uut.get_trigger_value()); // Setting mask to one_mask should not affect trigger - EXPECT_EQ(ReturnCode_t::RETCODE_OK, uut.set_enabled_statuses(one_mask)); + EXPECT_EQ(RETCODE_OK, uut.set_enabled_statuses(one_mask)); EXPECT_EQ(one_mask.to_string(), uut.get_enabled_statuses().to_string()); EXPECT_TRUE(uut.get_trigger_value()); @@ -132,13 +132,13 @@ TEST(StatusConditionImplTests, notify_trigger) EXPECT_TRUE(uut.get_trigger_value()); // Setting mask to other_mask should untrigger - EXPECT_EQ(ReturnCode_t::RETCODE_OK, uut.set_enabled_statuses(other_mask)); + EXPECT_EQ(RETCODE_OK, uut.set_enabled_statuses(other_mask)); EXPECT_EQ(other_mask.to_string(), uut.get_enabled_statuses().to_string()); EXPECT_FALSE(uut.get_trigger_value()); // Setting mask to one_mask should trigger EXPECT_CALL(notifier, notify()).Times(1).After(call3); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, uut.set_enabled_statuses(one_mask)); + EXPECT_EQ(RETCODE_OK, uut.set_enabled_statuses(one_mask)); EXPECT_EQ(one_mask.to_string(), uut.get_enabled_statuses().to_string()); EXPECT_TRUE(uut.get_trigger_value()); } diff --git a/test/unittest/dds/core/condition/WaitSetImplTests.cpp b/test/unittest/dds/core/condition/WaitSetImplTests.cpp index 798a6355103..a9e23ddcf66 100644 --- a/test/unittest/dds/core/condition/WaitSetImplTests.cpp +++ b/test/unittest/dds/core/condition/WaitSetImplTests.cpp @@ -58,40 +58,40 @@ TEST(WaitSetImplTests, condition_management) EXPECT_CALL(*notifier, will_be_deleted(_)).Times(1); // WaitSetImpl should be created without conditions - EXPECT_EQ(ReturnCode_t::RETCODE_OK, wait_set.get_conditions(conditions)); + EXPECT_EQ(RETCODE_OK, wait_set.get_conditions(conditions)); EXPECT_TRUE(conditions.empty()); // Trying to detach without having attached - EXPECT_EQ(ReturnCode_t::RETCODE_PRECONDITION_NOT_MET, wait_set.detach_condition(condition)); + EXPECT_EQ(RETCODE_PRECONDITION_NOT_MET, wait_set.detach_condition(condition)); // Adding the same condition several times should always succeed and keep the list with a single condition for (int i = 0; i < 2; ++i) { - EXPECT_EQ(ReturnCode_t::RETCODE_OK, wait_set.attach_condition(condition)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, wait_set.get_conditions(conditions)); + EXPECT_EQ(RETCODE_OK, wait_set.attach_condition(condition)); + EXPECT_EQ(RETCODE_OK, wait_set.get_conditions(conditions)); EXPECT_EQ(1u, conditions.size()); EXPECT_NE(conditions.cend(), std::find(conditions.cbegin(), conditions.cend(), &condition)); } // Detaching the condition once should succeed - EXPECT_EQ(ReturnCode_t::RETCODE_OK, wait_set.detach_condition(condition)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, wait_set.get_conditions(conditions)); + EXPECT_EQ(RETCODE_OK, wait_set.detach_condition(condition)); + EXPECT_EQ(RETCODE_OK, wait_set.get_conditions(conditions)); EXPECT_TRUE(conditions.empty()); // Detaching a second time should fail - EXPECT_EQ(ReturnCode_t::RETCODE_PRECONDITION_NOT_MET, wait_set.detach_condition(condition)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, wait_set.get_conditions(conditions)); + EXPECT_EQ(RETCODE_PRECONDITION_NOT_MET, wait_set.detach_condition(condition)); + EXPECT_EQ(RETCODE_OK, wait_set.get_conditions(conditions)); EXPECT_TRUE(conditions.empty()); // Attach the condition again - EXPECT_EQ(ReturnCode_t::RETCODE_OK, wait_set.attach_condition(condition)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, wait_set.get_conditions(conditions)); + EXPECT_EQ(RETCODE_OK, wait_set.attach_condition(condition)); + EXPECT_EQ(RETCODE_OK, wait_set.get_conditions(conditions)); EXPECT_EQ(1u, conditions.size()); EXPECT_NE(conditions.cend(), std::find(conditions.cbegin(), conditions.cend(), &condition)); // Calling will_be_deleted should detach the condition wait_set.will_be_deleted(condition); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, wait_set.get_conditions(conditions)); + EXPECT_EQ(RETCODE_OK, wait_set.get_conditions(conditions)); EXPECT_TRUE(conditions.empty()); } @@ -111,19 +111,19 @@ TEST(WaitSetImplTests, wait) EXPECT_CALL(*notifier, will_be_deleted(_)).Times(1); // Waiting on empty wait set should timeout - EXPECT_EQ(ReturnCode_t::RETCODE_TIMEOUT, wait_set.wait(conditions, timeout)); + EXPECT_EQ(RETCODE_TIMEOUT, wait_set.wait(conditions, timeout)); EXPECT_TRUE(conditions.empty()); // Attach condition - EXPECT_EQ(ReturnCode_t::RETCODE_OK, wait_set.attach_condition(condition)); + EXPECT_EQ(RETCODE_OK, wait_set.attach_condition(condition)); // Waiting on untriggered condition should timeout - EXPECT_EQ(ReturnCode_t::RETCODE_TIMEOUT, wait_set.wait(conditions, timeout)); + EXPECT_EQ(RETCODE_TIMEOUT, wait_set.wait(conditions, timeout)); EXPECT_TRUE(conditions.empty()); // Waiting on already triggered condition should inmediately return condition condition.trigger_value = true; - EXPECT_EQ(ReturnCode_t::RETCODE_OK, wait_set.wait(conditions, timeout)); + EXPECT_EQ(RETCODE_OK, wait_set.wait(conditions, timeout)); EXPECT_EQ(1u, conditions.size()); EXPECT_NE(conditions.cend(), std::find(conditions.cbegin(), conditions.cend(), &condition)); @@ -135,7 +135,7 @@ TEST(WaitSetImplTests, wait) std::this_thread::sleep_for(std::chrono::milliseconds(200)); wait_set.wake_up(); }); - EXPECT_EQ(ReturnCode_t::RETCODE_TIMEOUT, wait_set.wait(conditions, timeout)); + EXPECT_EQ(RETCODE_TIMEOUT, wait_set.wait(conditions, timeout)); EXPECT_TRUE(conditions.empty()); notify_without_trigger.join(); } @@ -148,7 +148,7 @@ TEST(WaitSetImplTests, wait) condition.trigger_value = true; wait_set.wake_up(); }); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, wait_set.wait(conditions, timeout)); + EXPECT_EQ(RETCODE_OK, wait_set.wait(conditions, timeout)); EXPECT_EQ(1u, conditions.size()); EXPECT_NE(conditions.cend(), std::find(conditions.cbegin(), conditions.cend(), &condition)); trigger_and_notify.join(); @@ -160,12 +160,12 @@ TEST(WaitSetImplTests, wait) { std::this_thread::sleep_for(std::chrono::milliseconds(200)); ConditionSeq conds; - EXPECT_EQ(ReturnCode_t::RETCODE_PRECONDITION_NOT_MET, wait_set.wait(conds, timeout)); + EXPECT_EQ(RETCODE_PRECONDITION_NOT_MET, wait_set.wait(conds, timeout)); EXPECT_TRUE(conds.empty()); }); condition.trigger_value = false; - EXPECT_EQ(ReturnCode_t::RETCODE_TIMEOUT, wait_set.wait(conditions, timeout)); + EXPECT_EQ(RETCODE_TIMEOUT, wait_set.wait(conditions, timeout)); EXPECT_TRUE(conditions.empty()); second_wait_thread.join(); } @@ -186,7 +186,7 @@ TEST(WaitSetImplTests, wait) wait_set.attach_condition(triggered_condition); }); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, wait_set.wait(conditions, eprosima::fastrtps::c_TimeInfinite)); + EXPECT_EQ(RETCODE_OK, wait_set.wait(conditions, eprosima::fastrtps::c_TimeInfinite)); EXPECT_EQ(1u, conditions.size()); EXPECT_EQ(conditions.cend(), std::find(conditions.cbegin(), conditions.cend(), &condition)); EXPECT_NE(conditions.cend(), std::find(conditions.cbegin(), conditions.cend(), &triggered_condition)); @@ -237,7 +237,7 @@ TEST(WaitSetImplTests, fix_wait_notification_lost) std::promise promise; std::future future = promise.get_future(); - ReturnCode_t ret = ReturnCode_t::RETCODE_ERROR; + ReturnCode_t ret = RETCODE_ERROR; std::thread wait_conditions([&]() { // Not to use `WaitSetImpl::wait` with a timeout value, because the @@ -253,7 +253,7 @@ TEST(WaitSetImplTests, fix_wait_notification_lost) // Expecting get notification after wake_up, otherwise output error within 5 seconds. future.wait_for(std::chrono::seconds(5)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, ret); + EXPECT_EQ(RETCODE_OK, ret); EXPECT_EQ(1u, conditions.size()); EXPECT_NE(conditions.cend(), std::find(conditions.cbegin(), conditions.cend(), &triggered_condition)); diff --git a/test/unittest/dds/core/entity/CMakeLists.txt b/test/unittest/dds/core/entity/CMakeLists.txt index f3b201f7f99..6d3142e6d37 100644 --- a/test/unittest/dds/core/entity/CMakeLists.txt +++ b/test/unittest/dds/core/entity/CMakeLists.txt @@ -17,17 +17,12 @@ if(WIN32) endif() set(ENTITY_TESTS_SOURCE - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypesBase.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/core/condition/Condition.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/core/condition/ConditionNotifier.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/core/condition/StatusCondition.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/core/condition/StatusConditionImpl.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/core/condition/WaitSetImpl.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/core/Entity.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/Log.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/OStreamConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutErrConsumer.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/LocatorWithMask.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/Time_t.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/network/utils/netmask_filter.cpp @@ -61,5 +56,8 @@ target_include_directories(EntityTests PRIVATE ${PROJECT_BINARY_DIR}/include ${PROJECT_SOURCE_DIR}/src/cpp ) -target_link_libraries(EntityTests GTest::gtest fastcdr) +target_link_libraries(EntityTests + fastcdr + fastdds::log + GTest::gtest) gtest_discover_tests(EntityTests) diff --git a/test/unittest/dds/core/entity/EntityTests.cpp b/test/unittest/dds/core/entity/EntityTests.cpp index 79a425dcaf8..ffe24fba0d6 100644 --- a/test/unittest/dds/core/entity/EntityTests.cpp +++ b/test/unittest/dds/core/entity/EntityTests.cpp @@ -22,7 +22,6 @@ #include #include #include -#include #include "../../../logging/mock/MockConsumer.h" #include "mock/MockEntity.hpp" @@ -106,7 +105,7 @@ TEST_F(EntityTests, entity_enable) Entity entity; ASSERT_FALSE(entity.is_enabled()); - ASSERT_EQ(entity.enable(), eprosima::fastrtps::types::ReturnCode_t::RETCODE_OK); + ASSERT_EQ(entity.enable(), RETCODE_OK); ASSERT_TRUE(entity.is_enabled()); entity.close(); ASSERT_FALSE(entity.is_enabled()); diff --git a/test/unittest/dds/core/entity/mock/MockEntity.hpp b/test/unittest/dds/core/entity/mock/MockEntity.hpp index 13fd3d98daf..15b80bf3f94 100644 --- a/test/unittest/dds/core/entity/mock/MockEntity.hpp +++ b/test/unittest/dds/core/entity/mock/MockEntity.hpp @@ -34,7 +34,7 @@ class MockEntity : public Entity }; } // namespace rtps -} // namespace fastrtps +} // namespace fastdds } // namespace eprosima #endif //MOCK_ENTITY_H diff --git a/test/unittest/dds/core/policy/CMakeLists.txt b/test/unittest/dds/core/policy/CMakeLists.txt index e638a4dcf0b..56dfe44bff1 100644 --- a/test/unittest/dds/core/policy/CMakeLists.txt +++ b/test/unittest/dds/core/policy/CMakeLists.txt @@ -20,7 +20,7 @@ set(PARAMETER_PROPERTY_LIST_TESTS ParameterPropertyList.cpp) add_executable(ParameterPropertyListTests ${PARAMETER_PROPERTY_LIST_TESTS}) -target_compile_definitions(ParameterPropertyListTests PRIVATE FASTRTPS_NO_LIB +target_compile_definitions(ParameterPropertyListTests PRIVATE FASTDDS_NO_LIB $<$>,$>:__DEBUG> $<$:__INTERNALDEBUG> # Internal debug activated. ) @@ -29,6 +29,6 @@ target_include_directories(ParameterPropertyListTests PRIVATE ${PROJECT_BINARY_DIR}/include ${PROJECT_SOURCE_DIR}/src/cpp ) -target_link_libraries(ParameterPropertyListTests GTest::gtest fastcdr fastrtps) +target_link_libraries(ParameterPropertyListTests GTest::gtest fastcdr fastdds) gtest_discover_tests(ParameterPropertyListTests) diff --git a/test/unittest/dds/participant/CMakeLists.txt b/test/unittest/dds/participant/CMakeLists.txt index 9982d19b89b..d8644da7ea3 100644 --- a/test/unittest/dds/participant/CMakeLists.txt +++ b/test/unittest/dds/participant/CMakeLists.txt @@ -42,7 +42,7 @@ target_include_directories(ParticipantTests PRIVATE ${PROJECT_SOURCE_DIR}/include ${PROJECT_BINARY_DIR}/include ${PROJECT_SOURCE_DIR}/src/cpp ) -target_link_libraries(ParticipantTests fastrtps fastcdr foonathan_memory +target_link_libraries(ParticipantTests fastdds fastcdr foonathan_memory GTest::gmock ${CMAKE_DL_LIBS}) diff --git a/test/unittest/dds/participant/ParticipantTests.cpp b/test/unittest/dds/participant/ParticipantTests.cpp index 7cf9d76db90..6ad7ede6372 100644 --- a/test/unittest/dds/participant/ParticipantTests.cpp +++ b/test/unittest/dds/participant/ParticipantTests.cpp @@ -13,6 +13,7 @@ // limitations under the License. #include +#include #include #include #include @@ -24,52 +25,49 @@ #include #include -#include -#include -#include -#include -#include -#include -#include -#include #include #include +#include #include #include #include +#include +#include #include #include #include #include #include -#include #include +#include #include +#include +#include +#include +#include +#include +#include +#include +#include +#include #include #include #include #include -#include -#include +#include #include #include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include +#include +#include +#include #include #include +#include +#include -#include "../../common/GTestPrinters.hpp" +#include "../../common/env_var_utils.hpp" #include "../../logging/mock/MockConsumer.h" -#include "fastdds/dds/domain/DomainParticipant.hpp" #if defined(__cplusplus_winrt) #define GET_PID GetCurrentProcessId @@ -85,17 +83,8 @@ namespace eprosima { namespace fastdds { namespace dds { -using fastrtps::ParticipantAttributes; using fastrtps::PublisherAttributes; using fastrtps::SubscriberAttributes; -using fastrtps::types::DynamicData_ptr; -using fastrtps::types::DynamicDataFactory; -using fastrtps::types::DynamicType_ptr; -using fastrtps::types::DynamicTypeBuilder_ptr; -using fastrtps::types::DynamicTypeBuilderFactory; -using fastrtps::types::TypeDescriptor; -using fastrtps::xmlparser::XMLP_ret; -using fastrtps::xmlparser::XMLProfileManager; // Mocked TopicDataType for Topic creation tests class TopicDataTypeMock : public TopicDataType @@ -366,7 +355,7 @@ TEST(ParticipantTests, ChangeDomainParticipantFactoryQos) entity_factory.autoenable_created_entities = false; qos.entity_factory(entity_factory); - ASSERT_TRUE(DomainParticipantFactory::get_instance()->set_qos(qos) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(DomainParticipantFactory::get_instance()->set_qos(qos) == RETCODE_OK); DomainParticipantFactoryQos fqos; DomainParticipantFactory::get_instance()->get_qos(fqos); @@ -376,13 +365,98 @@ TEST(ParticipantTests, ChangeDomainParticipantFactoryQos) entity_factory.autoenable_created_entities = true; qos.entity_factory(entity_factory); - ASSERT_TRUE(DomainParticipantFactory::get_instance()->set_qos(qos) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(DomainParticipantFactory::get_instance()->set_qos(qos) == RETCODE_OK); DomainParticipantFactory::get_instance()->get_qos(fqos); ASSERT_EQ(qos, fqos); ASSERT_EQ(fqos.entity_factory().autoenable_created_entities, true); } +TEST(ParticipantTests, DomainParticipantFactoryLibrarySettings) +{ + // Disable entities autoenabling + DomainParticipantFactoryQos qos; + qos.entity_factory().autoenable_created_entities = false; + ASSERT_EQ(DomainParticipantFactory::get_instance()->set_qos(qos), RETCODE_OK); + + eprosima::fastdds::LibrarySettings library_settings; + EXPECT_EQ(DomainParticipantFactory::get_instance()->get_library_settings(library_settings), + RETCODE_OK); + // Get LibrarySettings default values +#if HAVE_STRICT_REALTIME + EXPECT_EQ(eprosima::fastdds::INTRAPROCESS_OFF, library_settings.intraprocess_delivery); +#else + EXPECT_EQ(eprosima::fastdds::INTRAPROCESS_FULL, library_settings.intraprocess_delivery); +#endif // if HAVE_STRICT_REALTIME + library_settings.intraprocess_delivery = eprosima::fastdds::INTRAPROCESS_USER_DATA_ONLY; + // Setting the library settings within an empty DomainParticipantFactory shall return true + EXPECT_EQ(DomainParticipantFactory::get_instance()->set_library_settings(library_settings), + RETCODE_OK); + EXPECT_EQ(DomainParticipantFactory::get_instance()->get_library_settings(library_settings), + RETCODE_OK); + EXPECT_EQ(eprosima::fastdds::INTRAPROCESS_USER_DATA_ONLY, library_settings.intraprocess_delivery); + // Create DomainParticipant + DomainParticipant* participant = + DomainParticipantFactory::get_instance()->create_participant(0, PARTICIPANT_QOS_DEFAULT); + ASSERT_NE(nullptr, participant); + library_settings.intraprocess_delivery = eprosima::fastdds::INTRAPROCESS_OFF; + // Setting LibrarySettings with any disabled DomainParticipant shall succeed + EXPECT_EQ(DomainParticipantFactory::get_instance()->set_library_settings(library_settings), + RETCODE_OK); + EXPECT_EQ(DomainParticipantFactory::get_instance()->get_library_settings(library_settings), + RETCODE_OK); + EXPECT_EQ(eprosima::fastdds::INTRAPROCESS_OFF, library_settings.intraprocess_delivery); + // Operation shall fail if there is any enabled DomainParticipant + EXPECT_EQ(participant->enable(), RETCODE_OK); + library_settings.intraprocess_delivery = eprosima::fastdds::INTRAPROCESS_FULL; + // Setting LibrarySettings with any disabled DomainParticipant shall succeed + EXPECT_EQ(DomainParticipantFactory::get_instance()->set_library_settings(library_settings), + RETCODE_PRECONDITION_NOT_MET); + EXPECT_EQ(DomainParticipantFactory::get_instance()->get_library_settings(library_settings), + RETCODE_OK); + EXPECT_EQ(eprosima::fastdds::INTRAPROCESS_OFF, library_settings.intraprocess_delivery); + // Remove DomainParticipant + EXPECT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), + RETCODE_OK); + library_settings.intraprocess_delivery = eprosima::fastdds::INTRAPROCESS_FULL; + // Setting LibrarySettings with no participants shall suceed + EXPECT_EQ(DomainParticipantFactory::get_instance()->set_library_settings(library_settings), + RETCODE_OK); + EXPECT_EQ(DomainParticipantFactory::get_instance()->get_library_settings(library_settings), + RETCODE_OK); + EXPECT_EQ(eprosima::fastdds::INTRAPROCESS_FULL, library_settings.intraprocess_delivery); +} + +TEST(ParticipantTests, DomainParticipantFactoryGetDynamicTypeBuilder) +{ + traits::ref_type type; + std::string type_name("MyAloneEnumType"); + // Trying to get a Dynamic Type with empty name returns RETCODE_BAD_PARAMETER + EXPECT_EQ(RETCODE_BAD_PARAMETER, + DomainParticipantFactory::get_instance()->get_dynamic_type_builder_from_xml_by_name(std::string(), type)); + // Trying to get an unknown Dynamic Type return RETCODE_NO_DATA + EXPECT_EQ(RETCODE_NO_DATA, + DomainParticipantFactory::get_instance()->get_dynamic_type_builder_from_xml_by_name(type_name, type)); + EXPECT_EQ(nullptr, type); + // Load XML file + std::string xml = + "\ + \ + \ + \ + \ + \ + \ + \ + \ + "; + DomainParticipantFactory::get_instance()->load_XML_profiles_string(xml.c_str(), xml.length()); + // Getting a known dynamic type returns RETCODE_OK + EXPECT_EQ(RETCODE_OK, + DomainParticipantFactory::get_instance()->get_dynamic_type_builder_from_xml_by_name(type_name, type)); + EXPECT_NE(nullptr, type); +} + TEST(ParticipantTests, CreateDomainParticipant) { DomainParticipant* participant = @@ -392,7 +466,7 @@ TEST(ParticipantTests, CreateDomainParticipant) ASSERT_NE(participant, nullptr); EXPECT_EQ(participant->get_listener(), nullptr); - ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == RETCODE_OK); } @@ -432,35 +506,10 @@ void check_participant_with_profile ( DomainParticipantQos qos; participant->get_qos(qos); - ParticipantAttributes participant_atts; - XMLProfileManager::fillParticipantAttributes(profile_name, participant_atts); - - /* Values taken from profile */ - ASSERT_TRUE(qos.allocation() == participant_atts.rtps.allocation); - // Check that all the non-binary properties in participant_atts are present (by name) in qos - for (auto property : participant_atts.rtps.properties.properties()) - { - ASSERT_NE(nullptr, fastrtps::rtps::PropertyPolicyHelper::find_property(qos.properties(), property.name())); - } - ASSERT_TRUE(qos.properties().binary_properties() == participant_atts.rtps.properties.binary_properties()); - ASSERT_TRUE(qos.name().to_string() == participant_atts.rtps.getName()); - ASSERT_TRUE(qos.wire_protocol().prefix == participant_atts.rtps.prefix); - ASSERT_TRUE(qos.wire_protocol().participant_id == participant_atts.rtps.participantID); - ASSERT_TRUE(qos.wire_protocol().builtin == participant_atts.rtps.builtin); - ASSERT_TRUE(qos.wire_protocol().port == participant_atts.rtps.port); - ASSERT_TRUE(qos.wire_protocol().throughput_controller == participant_atts.rtps.throughputController); - ASSERT_TRUE(qos.wire_protocol().default_unicast_locator_list == - participant_atts.rtps.defaultUnicastLocatorList); - ASSERT_TRUE(qos.wire_protocol().default_multicast_locator_list == - participant_atts.rtps.defaultMulticastLocatorList); - ASSERT_TRUE(qos.transport().user_transports == participant_atts.rtps.userTransports); - ASSERT_TRUE(qos.transport().use_builtin_transports == participant_atts.rtps.useBuiltinTransports); - ASSERT_TRUE(qos.transport().send_socket_buffer_size == participant_atts.rtps.sendSocketBufferSize); - ASSERT_TRUE(qos.transport().listen_socket_buffer_size == participant_atts.rtps.listenSocketBufferSize); - ASSERT_TRUE(qos.user_data().data_vec() == participant_atts.rtps.userData); - - //Values not implemented on attributes (taken from default QoS) - ASSERT_TRUE(qos.entity_factory() == PARTICIPANT_QOS_DEFAULT.entity_factory()); + DomainParticipantQos profile_qos; + EXPECT_EQ(DomainParticipantFactory::get_instance()->get_participant_qos_from_profile(profile_name, profile_qos), + RETCODE_OK); + check_equivalent_qos(qos, profile_qos); } /** @@ -510,7 +559,7 @@ TEST(ParticipantTests, CreateDomainParticipantWithProfile) ASSERT_EQ(default_participant->get_domain_id(), domain_id); //Keep the DID given to the method, not the one on the profile check_participant_with_profile(default_participant, "test_default_participant_profile"); ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant( - default_participant) == ReturnCode_t::RETCODE_OK); + default_participant) == RETCODE_OK); //participant using non-default profile DomainParticipant* participant = @@ -519,7 +568,83 @@ TEST(ParticipantTests, CreateDomainParticipantWithProfile) ASSERT_NE(participant, nullptr); ASSERT_EQ(participant->get_domain_id(), domain_id); //Keep the DID given to the method, not the one on the profile check_participant_with_profile(participant, "test_participant_profile"); - ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == RETCODE_OK); +} + +TEST(ParticipantTests, CreateDomainParticipantWithDefaultProfile) +{ + uint32_t domain_id = 123u; // This is the domain ID set in the default profile above + + // set XML profile as environment variable: "export FASTDDS_DEFAULT_PROFILES_FILE=test_xml_profile.xml" + eprosima::testing::set_environment_variable("FASTDDS_DEFAULT_PROFILES_FILE", "test_xml_profile.xml"); + + //participant using the given profile + DomainParticipant* default_env_participant = + DomainParticipantFactory::get_instance()->create_participant_with_default_profile(); + + // unset XML profile environment variable + eprosima::testing::clear_environment_variable("FASTDDS_DEFAULT_PROFILES_FILE"); + + ASSERT_NE(default_env_participant, nullptr); + ASSERT_EQ(default_env_participant->get_domain_id(), domain_id); + ASSERT_EQ(default_env_participant->get_listener(), nullptr); + ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant( + default_env_participant) == RETCODE_OK); +} + +TEST(ParticipantTests, CreateDomainParticipantWithDefaultProfileListener) +{ + uint32_t domain_id = 123u; // This is the domain ID set in the default profile above + + // set XML profile as environment variable: "export FASTDDS_DEFAULT_PROFILES_FILE=test_xml_profile.xml" + eprosima::testing::set_environment_variable("FASTDDS_DEFAULT_PROFILES_FILE", "test_xml_profile.xml"); + + DomainParticipantListener listener; + + //participant using the given profile + DomainParticipant* default_env_participant = + DomainParticipantFactory::get_instance()->create_participant_with_default_profile(&listener, + StatusMask::none()); + + // unset XML profile environment variable + eprosima::testing::clear_environment_variable("FASTDDS_DEFAULT_PROFILES_FILE"); + + ASSERT_NE(default_env_participant, nullptr); + ASSERT_EQ(default_env_participant->get_domain_id(), domain_id); + ASSERT_EQ(default_env_participant->get_listener(), &listener); + ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant( + default_env_participant) == RETCODE_OK); +} + +TEST(ParticipantTests, CreateDomainParticipantWithoutDefaultProfile) +{ + uint32_t default_domain_id = 0u; // This is the default domain ID + + //participant using default values + DomainParticipant* default_participant = + DomainParticipantFactory::get_instance()->create_participant_with_default_profile(); + ASSERT_NE(default_participant, nullptr); + ASSERT_EQ(default_participant->get_domain_id(), default_domain_id); + ASSERT_EQ(default_participant->get_listener(), nullptr); + ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant( + default_participant) == RETCODE_OK); +} + +TEST(ParticipantTests, CreateDomainParticipantWithoutDefaultProfileListener) +{ + uint32_t default_domain_id = 0u; // This is the default domain ID + + DomainParticipantListener listener; + + //participant using default values + DomainParticipant* default_participant = + DomainParticipantFactory::get_instance()->create_participant_with_default_profile(&listener, + StatusMask::none()); + ASSERT_NE(default_participant, nullptr); + ASSERT_EQ(default_participant->get_domain_id(), default_domain_id); + ASSERT_EQ(default_participant->get_listener(), &listener); + ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant( + default_participant) == RETCODE_OK); } TEST(ParticipantTests, GetParticipantProfileQos) @@ -528,7 +653,7 @@ TEST(ParticipantTests, GetParticipantProfileQos) DomainParticipantQos qos; EXPECT_EQ( DomainParticipantFactory::get_instance()->get_participant_qos_from_profile("test_participant_profile", qos), - ReturnCode_t::RETCODE_OK); + RETCODE_OK); // Extract ParticipantQos from profile DomainParticipant* participant = @@ -541,28 +666,20 @@ TEST(ParticipantTests, GetParticipantProfileQos) // Test return when a non-existent profile is used EXPECT_EQ( DomainParticipantFactory::get_instance()->get_participant_qos_from_profile("incorrect_profile_name", qos), - ReturnCode_t::RETCODE_BAD_PARAMETER); + RETCODE_BAD_PARAMETER); // Clean up - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), RETCODE_OK); } -TEST(ParticipantTests, CreatePSMDomainParticipant) -{ - ::dds::domain::DomainParticipant participant = ::dds::core::null; - participant = ::dds::domain::DomainParticipant(0, PARTICIPANT_QOS_DEFAULT); - - ASSERT_NE(participant, ::dds::core::null); -} - TEST(ParticipantTests, DeleteDomainParticipant) { DomainParticipant* participant = DomainParticipantFactory::get_instance()->create_participant( (uint32_t)GET_PID() % 230, PARTICIPANT_QOS_DEFAULT); - ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == RETCODE_OK); } TEST(ParticipantTests, DeleteDomainParticipantWithEntities) @@ -575,9 +692,9 @@ TEST(ParticipantTests, DeleteDomainParticipantWithEntities) ASSERT_NE(subscriber, nullptr); ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant( - participant), ReturnCode_t::RETCODE_PRECONDITION_NOT_MET); - ASSERT_EQ(participant->delete_subscriber(subscriber), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); + participant), RETCODE_PRECONDITION_NOT_MET); + ASSERT_EQ(participant->delete_subscriber(subscriber), RETCODE_OK); + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), RETCODE_OK); participant = DomainParticipantFactory::get_instance()->create_participant(domain_id, PARTICIPANT_QOS_DEFAULT); @@ -585,9 +702,9 @@ TEST(ParticipantTests, DeleteDomainParticipantWithEntities) ASSERT_NE(publisher, nullptr); ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant( - participant), ReturnCode_t::RETCODE_PRECONDITION_NOT_MET); - ASSERT_EQ(participant->delete_publisher(publisher), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); + participant), RETCODE_PRECONDITION_NOT_MET); + ASSERT_EQ(participant->delete_publisher(publisher), RETCODE_OK); + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), RETCODE_OK); participant = DomainParticipantFactory::get_instance()->create_participant(domain_id, PARTICIPANT_QOS_DEFAULT); @@ -598,9 +715,9 @@ TEST(ParticipantTests, DeleteDomainParticipantWithEntities) ASSERT_NE(topic, nullptr); ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant( - participant), ReturnCode_t::RETCODE_PRECONDITION_NOT_MET); - ASSERT_EQ(participant->delete_topic(topic), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); + participant), RETCODE_PRECONDITION_NOT_MET); + ASSERT_EQ(participant->delete_topic(topic), RETCODE_OK); + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), RETCODE_OK); } TEST(ParticipantTests, ChangeDefaultParticipantQos) @@ -614,7 +731,7 @@ TEST(ParticipantTests, ChangeDefaultParticipantQos) entity_factory.autoenable_created_entities = false; qos.entity_factory(entity_factory); - ASSERT_TRUE(DomainParticipantFactory::get_instance()->set_default_participant_qos(qos) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(DomainParticipantFactory::get_instance()->set_default_participant_qos(qos) == RETCODE_OK); DomainParticipantQos pqos; DomainParticipantFactory::get_instance()->get_default_participant_qos(pqos); @@ -622,28 +739,7 @@ TEST(ParticipantTests, ChangeDefaultParticipantQos) ASSERT_EQ(pqos.entity_factory().autoenable_created_entities, false); ASSERT_TRUE(DomainParticipantFactory::get_instance()->set_default_participant_qos( - PARTICIPANT_QOS_DEFAULT) == ReturnCode_t::RETCODE_OK); -} - -TEST(ParticipantTests, ChangePSMDefaultParticipantQos) -{ - ::dds::domain::DomainParticipant participant = ::dds::domain::DomainParticipant(0, PARTICIPANT_QOS_DEFAULT); - - ::dds::domain::qos::DomainParticipantQos qos = participant.default_participant_qos(); - - ASSERT_EQ(qos, PARTICIPANT_QOS_DEFAULT); - - EntityFactoryQosPolicy entity_factory = qos.entity_factory(); - entity_factory.autoenable_created_entities = false; - qos.entity_factory(entity_factory); - - ASSERT_NO_THROW(participant.default_participant_qos(qos)); - ::dds::domain::qos::DomainParticipantQos pqos = participant.default_participant_qos(); - - ASSERT_EQ(qos, pqos); - ASSERT_EQ(pqos.entity_factory().autoenable_created_entities, false); - - ASSERT_NO_THROW(participant.default_participant_qos(PARTICIPANT_QOS_DEFAULT)); + PARTICIPANT_QOS_DEFAULT) == RETCODE_OK); } TEST(ParticipantTests, ChangeDomainParticipantQos) @@ -657,7 +753,7 @@ TEST(ParticipantTests, ChangeDomainParticipantQos) check_equivalent_qos(qos, PARTICIPANT_QOS_DEFAULT); qos.entity_factory().autoenable_created_entities = false; - ASSERT_TRUE(participant->set_qos(qos) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(participant->set_qos(qos) == RETCODE_OK); DomainParticipantQos pqos; participant->get_qos(pqos); @@ -665,26 +761,7 @@ TEST(ParticipantTests, ChangeDomainParticipantQos) ASSERT_EQ(qos, pqos); ASSERT_EQ(qos.entity_factory().autoenable_created_entities, false); - ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == ReturnCode_t::RETCODE_OK); - -} - -TEST(ParticipantTests, ChangePSMDomainParticipantQos) -{ - ::dds::domain::DomainParticipant participant = ::dds::core::null; - participant = ::dds::domain::DomainParticipant(0, PARTICIPANT_QOS_DEFAULT); - ::dds::domain::qos::DomainParticipantQos qos = participant.qos(); - - check_equivalent_qos(qos, PARTICIPANT_QOS_DEFAULT); - - qos.entity_factory().autoenable_created_entities = false; - ASSERT_NO_THROW(participant.qos(qos)); - ::dds::domain::qos::DomainParticipantQos pqos; - pqos = participant.qos(); - - ASSERT_FALSE(pqos == PARTICIPANT_QOS_DEFAULT); - ASSERT_EQ(qos, pqos); - ASSERT_EQ(qos.entity_factory().autoenable_created_entities, false); + ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == RETCODE_OK); } @@ -913,9 +990,9 @@ TEST(ParticipantTests, SimpleParticipantRemoteServerListConfiguration) DomainParticipantQos result_qos = participant->get_qos(); EXPECT_EQ(result_qos.wire_protocol().builtin.discovery_config.m_DiscoveryServers, qos_output); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, participant->set_qos(result_qos)); + EXPECT_EQ(RETCODE_OK, participant->set_qos(result_qos)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, DomainParticipantFactory::get_instance()->delete_participant(participant)); + EXPECT_EQ(RETCODE_OK, DomainParticipantFactory::get_instance()->delete_participant(participant)); } @@ -981,7 +1058,7 @@ TEST(ParticipantTests, TransformSimpleParticipantToSuperclientByEnvVariable) DomainParticipantQos result_qos = participant->get_qos(); EXPECT_EQ(result_qos.wire_protocol().builtin.discovery_config.m_DiscoveryServers, qos_output); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, participant->set_qos(result_qos)); + EXPECT_EQ(RETCODE_OK, participant->set_qos(result_qos)); // check UDPv6 transport is there auto udpv6_check_2 = [](fastrtps::rtps::RTPSParticipantAttributes& attributes_2) -> bool @@ -1000,10 +1077,10 @@ TEST(ParticipantTests, TransformSimpleParticipantToSuperclientByEnvVariable) result_qos = participant_2->get_qos(); EXPECT_EQ(result_qos.wire_protocol().builtin.discovery_config.m_DiscoveryServers, qos_output); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, participant_2->set_qos(result_qos)); + EXPECT_EQ(RETCODE_OK, participant_2->set_qos(result_qos)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, DomainParticipantFactory::get_instance()->delete_participant(participant)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, DomainParticipantFactory::get_instance()->delete_participant(participant_2)); + EXPECT_EQ(RETCODE_OK, DomainParticipantFactory::get_instance()->delete_participant(participant)); + EXPECT_EQ(RETCODE_OK, DomainParticipantFactory::get_instance()->delete_participant(participant_2)); } @@ -1056,7 +1133,7 @@ TEST(ParticipantTests, SimpleParticipantRemoteServerListConfigurationDNS) }; EXPECT_TRUE(udpv6_check(attributes)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, DomainParticipantFactory::get_instance()->delete_participant(participant)); + EXPECT_EQ(RETCODE_OK, DomainParticipantFactory::get_instance()->delete_participant(participant)); } /** @@ -1107,8 +1184,8 @@ TEST(ParticipantTests, SimpleParticipantDynamicAdditionRemoteServers) EXPECT_EQ(attributes.builtin.discovery_config.m_DiscoveryServers, output); #endif // APPLE DomainParticipantQos result_qos = participant->get_qos(); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, participant->set_qos(result_qos)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, DomainParticipantFactory::get_instance()->delete_participant(participant)); + EXPECT_EQ(RETCODE_OK, participant->set_qos(result_qos)); + EXPECT_EQ(RETCODE_OK, DomainParticipantFactory::get_instance()->delete_participant(participant)); std::remove(filename.c_str()); } @@ -1132,8 +1209,8 @@ TEST(ParticipantTests, ClientParticipantRemoteServerListConfiguration) EXPECT_EQ(attributes.builtin.discovery_config.discoveryProtocol, fastrtps::rtps::DiscoveryProtocol::CLIENT); EXPECT_EQ(attributes.builtin.discovery_config.m_DiscoveryServers, qos_output); DomainParticipantQos result_qos = participant->get_qos(); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, participant->set_qos(result_qos)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, DomainParticipantFactory::get_instance()->delete_participant(participant)); + EXPECT_EQ(RETCODE_OK, participant->set_qos(result_qos)); + EXPECT_EQ(RETCODE_OK, DomainParticipantFactory::get_instance()->delete_participant(participant)); } /** @@ -1161,8 +1238,8 @@ TEST(ParticipantTests, ServerParticipantEnvironmentConfiguration) EXPECT_EQ(attributes.builtin.discovery_config.discoveryProtocol, fastrtps::rtps::DiscoveryProtocol::SERVER); EXPECT_TRUE(attributes.builtin.discovery_config.m_DiscoveryServers.empty()); DomainParticipantQos result_qos = participant->get_qos(); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, participant->set_qos(result_qos)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, DomainParticipantFactory::get_instance()->delete_participant(participant)); + EXPECT_EQ(RETCODE_OK, participant->set_qos(result_qos)); + EXPECT_EQ(RETCODE_OK, DomainParticipantFactory::get_instance()->delete_participant(participant)); } /** @@ -1191,8 +1268,8 @@ TEST(ParticipantTests, ServerParticipantRemoteServerListConfiguration) EXPECT_EQ(attributes.builtin.discovery_config.discoveryProtocol, fastrtps::rtps::DiscoveryProtocol::SERVER); EXPECT_EQ(attributes.builtin.discovery_config.m_DiscoveryServers, qos_output); DomainParticipantQos result_qos = participant->get_qos(); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, participant->set_qos(result_qos)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, DomainParticipantFactory::get_instance()->delete_participant(participant)); + EXPECT_EQ(RETCODE_OK, participant->set_qos(result_qos)); + EXPECT_EQ(RETCODE_OK, DomainParticipantFactory::get_instance()->delete_participant(participant)); } /** @@ -1244,8 +1321,8 @@ TEST(ParticipantTests, ServerParticipantInconsistentRemoteServerListConfiguratio helper_wait_for_at_least_entries(mockConsumer, 1); #endif // APPLE DomainParticipantQos result_qos = participant->get_qos(); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, participant->set_qos(result_qos)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, DomainParticipantFactory::get_instance()->delete_participant(participant)); + EXPECT_EQ(RETCODE_OK, participant->set_qos(result_qos)); + EXPECT_EQ(RETCODE_OK, DomainParticipantFactory::get_instance()->delete_participant(participant)); std::remove(filename.c_str()); } @@ -1294,8 +1371,8 @@ TEST(ParticipantTests, ServerParticipantInconsistentLocatorsRemoteServerListConf EXPECT_EQ(attributes.builtin.discovery_config.m_DiscoveryServers, output); #endif // APPLE DomainParticipantQos result_qos = participant->get_qos(); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, participant->set_qos(result_qos)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, DomainParticipantFactory::get_instance()->delete_participant(participant)); + EXPECT_EQ(RETCODE_OK, participant->set_qos(result_qos)); + EXPECT_EQ(RETCODE_OK, DomainParticipantFactory::get_instance()->delete_participant(participant)); std::remove(filename.c_str()); } @@ -1320,7 +1397,7 @@ TEST(ParticipantTests, RepeatEnvironmentFileConfiguration) set_and_check_with_environment_file(participant, {"172.17.0.5:64863", "192.168.1.133:4321", "192.168.5.15:1234"}, filename); #endif // APPLE - EXPECT_EQ(ReturnCode_t::RETCODE_OK, DomainParticipantFactory::get_instance()->delete_participant(participant)); + EXPECT_EQ(RETCODE_OK, DomainParticipantFactory::get_instance()->delete_participant(participant)); std::remove(filename.c_str()); } @@ -1388,11 +1465,11 @@ TEST(ParticipantTests, ServerParticipantCorrectRemoteServerListConfiguration) get_rtps_attributes(participant, attributes); EXPECT_EQ(attributes.builtin.discovery_config.m_DiscoveryServers, output); result_qos = participant->get_qos(); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, participant->set_qos(result_qos)); + EXPECT_EQ(RETCODE_OK, participant->set_qos(result_qos)); // Add new server using API result_qos.wire_protocol().builtin.discovery_config.m_DiscoveryServers.push_back(server); // RTPS layer issues a Warning because a server has been removed. However, DDS layer returns OK - EXPECT_EQ(ReturnCode_t::RETCODE_OK, participant->set_qos(result_qos)); + EXPECT_EQ(RETCODE_OK, participant->set_qos(result_qos)); server.clear(); fastrtps::rtps::IPLocator::setIPv4(locator, "192.168.1.133"); locator.port = 64863; @@ -1405,14 +1482,14 @@ TEST(ParticipantTests, ServerParticipantCorrectRemoteServerListConfiguration) server.metatrafficUnicastLocatorList.push_back(locator); get_server_client_default_guidPrefix(3, server.guidPrefix); result_qos.wire_protocol().builtin.discovery_config.m_DiscoveryServers.push_back(server); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, participant->set_qos(result_qos)); + EXPECT_EQ(RETCODE_OK, participant->set_qos(result_qos)); output.push_back(server); get_rtps_attributes(participant, attributes); EXPECT_EQ(attributes.builtin.discovery_config.m_DiscoveryServers, output); #endif // APPLE result_qos = participant->get_qos(); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, participant->set_qos(result_qos)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, DomainParticipantFactory::get_instance()->delete_participant(participant)); + EXPECT_EQ(RETCODE_OK, participant->set_qos(result_qos)); + EXPECT_EQ(RETCODE_OK, DomainParticipantFactory::get_instance()->delete_participant(participant)); std::remove(filename.c_str()); } @@ -1449,35 +1526,35 @@ TEST(ParticipantTests, ChangeWireProtocolQos) server_2.metatrafficUnicastLocatorList.push_back(locator_2); qos.wire_protocol().builtin.discovery_config.m_DiscoveryServers.push_back(server_2); - ASSERT_TRUE(participant->set_qos(qos) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(participant->set_qos(qos) == RETCODE_OK); DomainParticipantQos set_qos; participant->get_qos(set_qos); ASSERT_EQ(set_qos, qos); // Check that removing one server is NOT OK qos.wire_protocol().builtin.discovery_config.m_DiscoveryServers.pop_front(); - ASSERT_FALSE(participant->set_qos(qos) == ReturnCode_t::RETCODE_OK); + ASSERT_FALSE(participant->set_qos(qos) == RETCODE_OK); participant->get_qos(set_qos); ASSERT_FALSE(set_qos == qos); // Check that removing all servers is NOT OK fastdds::rtps::RemoteServerList_t servers; qos.wire_protocol().builtin.discovery_config.m_DiscoveryServers = servers; - ASSERT_FALSE(participant->set_qos(qos) == ReturnCode_t::RETCODE_OK); + ASSERT_FALSE(participant->set_qos(qos) == RETCODE_OK); participant->get_qos(set_qos); ASSERT_FALSE(set_qos == qos); // Check changing wire_protocol().prefix is NOT OK participant->get_qos(qos); std::istringstream("44.53.00.5f.45.50.52.4f.53.49.4d.41") >> qos.wire_protocol().prefix; - ASSERT_TRUE(participant->set_qos(qos) == ReturnCode_t::RETCODE_IMMUTABLE_POLICY); + ASSERT_TRUE(participant->set_qos(qos) == RETCODE_IMMUTABLE_POLICY); participant->get_qos(set_qos); ASSERT_FALSE(set_qos == qos); // Check changing wire_protocol().participant_id is NOT OK participant->get_qos(qos); qos.wire_protocol().participant_id = 7; - ASSERT_TRUE(participant->set_qos(qos) == ReturnCode_t::RETCODE_IMMUTABLE_POLICY); + ASSERT_TRUE(participant->set_qos(qos) == RETCODE_IMMUTABLE_POLICY); participant->get_qos(set_qos); ASSERT_FALSE(set_qos == qos); @@ -1485,7 +1562,7 @@ TEST(ParticipantTests, ChangeWireProtocolQos) participant->get_qos(qos); fastrtps::rtps::ThroughputControllerDescriptor controller{300000, 1000}; qos.wire_protocol().throughput_controller = controller; - ASSERT_TRUE(participant->set_qos(qos) == ReturnCode_t::RETCODE_IMMUTABLE_POLICY); + ASSERT_TRUE(participant->set_qos(qos) == RETCODE_IMMUTABLE_POLICY); participant->get_qos(set_qos); ASSERT_FALSE(set_qos == qos); @@ -1495,56 +1572,42 @@ TEST(ParticipantTests, ChangeWireProtocolQos) fastrtps::rtps::IPLocator::setIPv4(loc, "192.0.0.0"); loc.port = static_cast(12); qos.wire_protocol().default_unicast_locator_list.push_back(loc); - ASSERT_TRUE(participant->set_qos(qos) == ReturnCode_t::RETCODE_IMMUTABLE_POLICY); + ASSERT_TRUE(participant->set_qos(qos) == RETCODE_IMMUTABLE_POLICY); participant->get_qos(set_qos); ASSERT_FALSE(set_qos == qos); // Check changing wire_protocol().default_multicast_locator_list is NOT OK participant->get_qos(qos); qos.wire_protocol().default_multicast_locator_list.push_back(loc); - ASSERT_TRUE(participant->set_qos(qos) == ReturnCode_t::RETCODE_IMMUTABLE_POLICY); + ASSERT_TRUE(participant->set_qos(qos) == RETCODE_IMMUTABLE_POLICY); participant->get_qos(set_qos); ASSERT_FALSE(set_qos == qos); // Check changing wire_protocol().builtin.use_WriterLivelinessProtocol is NOT OK participant->get_qos(qos); qos.wire_protocol().builtin.use_WriterLivelinessProtocol ^= true; - ASSERT_TRUE(participant->set_qos(qos) == ReturnCode_t::RETCODE_IMMUTABLE_POLICY); - participant->get_qos(set_qos); - ASSERT_FALSE(set_qos == qos); - - // Check changing wire_protocol().builtin.typelookup_config.use_client is NOT OK - participant->get_qos(qos); - qos.wire_protocol().builtin.typelookup_config.use_client ^= true; - ASSERT_TRUE(participant->set_qos(qos) == ReturnCode_t::RETCODE_IMMUTABLE_POLICY); - participant->get_qos(set_qos); - ASSERT_FALSE(set_qos == qos); - - // Check changing wire_protocol().builtin.typelookup_config.use_server is NOT OK - participant->get_qos(qos); - qos.wire_protocol().builtin.typelookup_config.use_server ^= true; - ASSERT_TRUE(participant->set_qos(qos) == ReturnCode_t::RETCODE_IMMUTABLE_POLICY); + ASSERT_TRUE(participant->set_qos(qos) == RETCODE_IMMUTABLE_POLICY); participant->get_qos(set_qos); ASSERT_FALSE(set_qos == qos); // Check changing wire_protocol().builtin.metatrafficUnicastLocatorList is NOT OK participant->get_qos(qos); qos.wire_protocol().builtin.metatrafficUnicastLocatorList.push_back(loc); - ASSERT_TRUE(participant->set_qos(qos) == ReturnCode_t::RETCODE_IMMUTABLE_POLICY); + ASSERT_TRUE(participant->set_qos(qos) == RETCODE_IMMUTABLE_POLICY); participant->get_qos(set_qos); ASSERT_FALSE(set_qos == qos); // Check changing wire_protocol().builtin.metatrafficMulticastLocatorList is NOT OK participant->get_qos(qos); qos.wire_protocol().builtin.metatrafficMulticastLocatorList.push_back(loc); - ASSERT_TRUE(participant->set_qos(qos) == ReturnCode_t::RETCODE_IMMUTABLE_POLICY); + ASSERT_TRUE(participant->set_qos(qos) == RETCODE_IMMUTABLE_POLICY); participant->get_qos(set_qos); ASSERT_FALSE(set_qos == qos); // Check changing wire_protocol().builtin.initialPeersList is NOT OK participant->get_qos(qos); qos.wire_protocol().builtin.initialPeersList.push_back(loc); - ASSERT_TRUE(participant->set_qos(qos) == ReturnCode_t::RETCODE_IMMUTABLE_POLICY); + ASSERT_TRUE(participant->set_qos(qos) == RETCODE_IMMUTABLE_POLICY); participant->get_qos(set_qos); ASSERT_FALSE(set_qos == qos); @@ -1552,14 +1615,14 @@ TEST(ParticipantTests, ChangeWireProtocolQos) participant->get_qos(qos); qos.wire_protocol().builtin.readerHistoryMemoryPolicy = fastrtps::rtps::MemoryManagementPolicy_t::DYNAMIC_RESERVE_MEMORY_MODE; - ASSERT_TRUE(participant->set_qos(qos) == ReturnCode_t::RETCODE_IMMUTABLE_POLICY); + ASSERT_TRUE(participant->set_qos(qos) == RETCODE_IMMUTABLE_POLICY); participant->get_qos(set_qos); ASSERT_FALSE(set_qos == qos); // Check changing wire_protocol().builtin.readerPayloadSize is NOT OK participant->get_qos(qos); qos.wire_protocol().builtin.readerPayloadSize = 27; - ASSERT_TRUE(participant->set_qos(qos) == ReturnCode_t::RETCODE_IMMUTABLE_POLICY); + ASSERT_TRUE(participant->set_qos(qos) == RETCODE_IMMUTABLE_POLICY); participant->get_qos(set_qos); ASSERT_FALSE(set_qos == qos); @@ -1567,70 +1630,70 @@ TEST(ParticipantTests, ChangeWireProtocolQos) participant->get_qos(qos); qos.wire_protocol().builtin.writerHistoryMemoryPolicy = fastrtps::rtps::MemoryManagementPolicy_t::DYNAMIC_RESERVE_MEMORY_MODE; - ASSERT_TRUE(participant->set_qos(qos) == ReturnCode_t::RETCODE_IMMUTABLE_POLICY); + ASSERT_TRUE(participant->set_qos(qos) == RETCODE_IMMUTABLE_POLICY); participant->get_qos(set_qos); ASSERT_FALSE(set_qos == qos); // Check changing wire_protocol().builtin.writerPayloadSize is NOT OK participant->get_qos(qos); qos.wire_protocol().builtin.writerPayloadSize = 27; - ASSERT_TRUE(participant->set_qos(qos) == ReturnCode_t::RETCODE_IMMUTABLE_POLICY); + ASSERT_TRUE(participant->set_qos(qos) == RETCODE_IMMUTABLE_POLICY); participant->get_qos(set_qos); ASSERT_FALSE(set_qos == qos); // Check changing wire_protocol().builtin.mutation_tries is NOT OK participant->get_qos(qos); qos.wire_protocol().builtin.mutation_tries = 27; - ASSERT_TRUE(participant->set_qos(qos) == ReturnCode_t::RETCODE_IMMUTABLE_POLICY); + ASSERT_TRUE(participant->set_qos(qos) == RETCODE_IMMUTABLE_POLICY); participant->get_qos(set_qos); ASSERT_FALSE(set_qos == qos); // Check changing wire_protocol().builtin.avoid_builtin_multicast is NOT OK participant->get_qos(qos); qos.wire_protocol().builtin.avoid_builtin_multicast ^= true; - ASSERT_TRUE(participant->set_qos(qos) == ReturnCode_t::RETCODE_IMMUTABLE_POLICY); + ASSERT_TRUE(participant->set_qos(qos) == RETCODE_IMMUTABLE_POLICY); participant->get_qos(set_qos); ASSERT_FALSE(set_qos == qos); // Check changing wire_protocol().builtin.discovery_config.discoveryProtocol is NOT OK participant->get_qos(qos); qos.wire_protocol().builtin.discovery_config.discoveryProtocol = fastrtps::rtps::DiscoveryProtocol_t::NONE; - ASSERT_TRUE(participant->set_qos(qos) == ReturnCode_t::RETCODE_IMMUTABLE_POLICY); + ASSERT_TRUE(participant->set_qos(qos) == RETCODE_IMMUTABLE_POLICY); participant->get_qos(set_qos); ASSERT_FALSE(set_qos == qos); // Check changing wire_protocol().builtin.discovery_config.use_SIMPLE_EndpointDiscoveryProtocol is NOT OK participant->get_qos(qos); qos.wire_protocol().builtin.discovery_config.use_SIMPLE_EndpointDiscoveryProtocol ^= true; - ASSERT_TRUE(participant->set_qos(qos) == ReturnCode_t::RETCODE_IMMUTABLE_POLICY); + ASSERT_TRUE(participant->set_qos(qos) == RETCODE_IMMUTABLE_POLICY); participant->get_qos(set_qos); ASSERT_FALSE(set_qos == qos); // Check changing wire_protocol().builtin.discovery_config.use_STATIC_EndpointDiscoveryProtocol is NOT OK participant->get_qos(qos); qos.wire_protocol().builtin.discovery_config.use_STATIC_EndpointDiscoveryProtocol ^= true; - ASSERT_TRUE(participant->set_qos(qos) == ReturnCode_t::RETCODE_IMMUTABLE_POLICY); + ASSERT_TRUE(participant->set_qos(qos) == RETCODE_IMMUTABLE_POLICY); participant->get_qos(set_qos); ASSERT_FALSE(set_qos == qos); // Check changing wire_protocol().builtin.discovery_config.discoveryServer_client_syncperiod is NOT OK participant->get_qos(qos); qos.wire_protocol().builtin.discovery_config.discoveryServer_client_syncperiod = { 27, 27}; - ASSERT_TRUE(participant->set_qos(qos) == ReturnCode_t::RETCODE_IMMUTABLE_POLICY); + ASSERT_TRUE(participant->set_qos(qos) == RETCODE_IMMUTABLE_POLICY); participant->get_qos(set_qos); ASSERT_FALSE(set_qos == qos); // Check changing wire_protocol().builtin.discovery_config.leaseDuration is NOT OK participant->get_qos(qos); qos.wire_protocol().builtin.discovery_config.leaseDuration = { 27, 27}; - ASSERT_TRUE(participant->set_qos(qos) == ReturnCode_t::RETCODE_IMMUTABLE_POLICY); + ASSERT_TRUE(participant->set_qos(qos) == RETCODE_IMMUTABLE_POLICY); participant->get_qos(set_qos); ASSERT_FALSE(set_qos == qos); // Check changing wire_protocol().builtin.discovery_config.leaseDuration_announcementperiod is NOT OK participant->get_qos(qos); qos.wire_protocol().builtin.discovery_config.leaseDuration_announcementperiod = { 27, 27}; - ASSERT_TRUE(participant->set_qos(qos) == ReturnCode_t::RETCODE_IMMUTABLE_POLICY); + ASSERT_TRUE(participant->set_qos(qos) == RETCODE_IMMUTABLE_POLICY); participant->get_qos(set_qos); ASSERT_FALSE(set_qos == qos); @@ -1638,7 +1701,7 @@ TEST(ParticipantTests, ChangeWireProtocolQos) participant->get_qos(qos); qos.wire_protocol().builtin.discovery_config.initial_announcements.count = 27; qos.wire_protocol().builtin.discovery_config.initial_announcements.period = {27, 27}; - ASSERT_TRUE(participant->set_qos(qos) == ReturnCode_t::RETCODE_IMMUTABLE_POLICY); + ASSERT_TRUE(participant->set_qos(qos) == RETCODE_IMMUTABLE_POLICY); participant->get_qos(set_qos); ASSERT_FALSE(set_qos == qos); @@ -1652,7 +1715,7 @@ TEST(ParticipantTests, ChangeWireProtocolQos) qos.wire_protocol().builtin.discovery_config.m_simpleEDP. enable_builtin_secure_subscriptions_writer_and_publications_reader ^= true; #endif // if HAVE_SECURITY - ASSERT_TRUE(participant->set_qos(qos) == ReturnCode_t::RETCODE_IMMUTABLE_POLICY); + ASSERT_TRUE(participant->set_qos(qos) == RETCODE_IMMUTABLE_POLICY); participant->get_qos(set_qos); ASSERT_FALSE(set_qos == qos); @@ -1671,7 +1734,7 @@ TEST(ParticipantTests, ChangeWireProtocolQos) "" \ ""; qos.wire_protocol().builtin.discovery_config.static_edp_xml_config(static_xml.c_str()); - ASSERT_TRUE(participant->set_qos(qos) == ReturnCode_t::RETCODE_IMMUTABLE_POLICY); + ASSERT_TRUE(participant->set_qos(qos) == RETCODE_IMMUTABLE_POLICY); participant->get_qos(set_qos); ASSERT_FALSE(set_qos == qos); @@ -1679,11 +1742,11 @@ TEST(ParticipantTests, ChangeWireProtocolQos) participant->get_qos(qos); qos.wire_protocol().builtin.discovery_config.ignoreParticipantFlags = fastrtps::rtps::ParticipantFilteringFlags::FILTER_DIFFERENT_HOST; - ASSERT_TRUE(participant->set_qos(qos) == ReturnCode_t::RETCODE_IMMUTABLE_POLICY); + ASSERT_TRUE(participant->set_qos(qos) == RETCODE_IMMUTABLE_POLICY); participant->get_qos(set_qos); ASSERT_FALSE(set_qos == qos); - ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == RETCODE_OK); } TEST(ParticipantTests, EntityFactoryBehavior) @@ -1694,7 +1757,7 @@ TEST(ParticipantTests, EntityFactoryBehavior) DomainParticipantFactoryQos qos; qos.entity_factory().autoenable_created_entities = false; - ASSERT_TRUE(factory->set_qos(qos) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(factory->set_qos(qos) == RETCODE_OK); } // Ensure that participant is created disabled. @@ -1706,7 +1769,7 @@ TEST(ParticipantTests, EntityFactoryBehavior) // Participant is disabled. This means we can change an inmutable qos. DomainParticipantQos qos = PARTICIPANT_QOS_DEFAULT; qos.wire_protocol().builtin.avoid_builtin_multicast = !qos.wire_protocol().builtin.avoid_builtin_multicast; - EXPECT_EQ(ReturnCode_t::RETCODE_OK, participant->set_qos(qos)); + EXPECT_EQ(RETCODE_OK, participant->set_qos(qos)); // Creating lower entities should create them disabled Publisher* pub = participant->create_publisher(PUBLISHER_QOS_DEFAULT); @@ -1724,13 +1787,13 @@ TEST(ParticipantTests, EntityFactoryBehavior) EXPECT_FALSE(topic->is_enabled()); // Enabling should fail on lower entities until participant is enabled - EXPECT_EQ(ReturnCode_t::RETCODE_PRECONDITION_NOT_MET, pub->enable()); - EXPECT_EQ(ReturnCode_t::RETCODE_PRECONDITION_NOT_MET, sub->enable()); + EXPECT_EQ(RETCODE_PRECONDITION_NOT_MET, pub->enable()); + EXPECT_EQ(RETCODE_PRECONDITION_NOT_MET, sub->enable()); // Enable participant and check idempotency of enable - EXPECT_EQ(ReturnCode_t::RETCODE_OK, participant->enable()); + EXPECT_EQ(RETCODE_OK, participant->enable()); EXPECT_TRUE(participant->is_enabled()); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, participant->enable()); + EXPECT_EQ(RETCODE_OK, participant->enable()); // As the participant was created with the default value for ENTITY_FACTORY, // lower entities should have been automatically enabled. @@ -1738,7 +1801,7 @@ TEST(ParticipantTests, EntityFactoryBehavior) EXPECT_TRUE(sub->is_enabled()); // Now that participant is enabled, we should not be able change an inmutable qos. - ASSERT_EQ(ReturnCode_t::RETCODE_IMMUTABLE_POLICY, participant->set_qos(PARTICIPANT_QOS_DEFAULT)); + ASSERT_EQ(RETCODE_IMMUTABLE_POLICY, participant->set_qos(PARTICIPANT_QOS_DEFAULT)); // Created entities should now be automatically enabled Subscriber* sub2 = participant->create_subscriber(SUBSCRIBER_QOS_DEFAULT); @@ -1747,7 +1810,7 @@ TEST(ParticipantTests, EntityFactoryBehavior) // We can change ENTITY_FACTORY on the participant qos.entity_factory().autoenable_created_entities = false; - ASSERT_EQ(ReturnCode_t::RETCODE_OK, participant->set_qos(qos)); + ASSERT_EQ(RETCODE_OK, participant->set_qos(qos)); // Lower entities should now be created disabled Publisher* pub2 = participant->create_publisher(PUBLISHER_QOS_DEFAULT); @@ -1755,22 +1818,22 @@ TEST(ParticipantTests, EntityFactoryBehavior) EXPECT_FALSE(pub2->is_enabled()); // But could be enabled afterwards - EXPECT_EQ(ReturnCode_t::RETCODE_OK, pub2->enable()); + EXPECT_EQ(RETCODE_OK, pub2->enable()); EXPECT_TRUE(pub2->is_enabled()); // Check idempotency of enable on entities - EXPECT_EQ(ReturnCode_t::RETCODE_OK, pub->enable()); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, pub2->enable()); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, sub->enable()); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, sub2->enable()); + EXPECT_EQ(RETCODE_OK, pub->enable()); + EXPECT_EQ(RETCODE_OK, pub2->enable()); + EXPECT_EQ(RETCODE_OK, sub->enable()); + EXPECT_EQ(RETCODE_OK, sub2->enable()); // Delete lower entities - EXPECT_EQ(ReturnCode_t::RETCODE_OK, participant->delete_subscriber(sub2)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, participant->delete_publisher(pub2)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, participant->delete_subscriber(sub)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, participant->delete_publisher(pub)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, participant->delete_topic(topic)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, DomainParticipantFactory::get_instance()->delete_participant(participant)); + EXPECT_EQ(RETCODE_OK, participant->delete_subscriber(sub2)); + EXPECT_EQ(RETCODE_OK, participant->delete_publisher(pub2)); + EXPECT_EQ(RETCODE_OK, participant->delete_subscriber(sub)); + EXPECT_EQ(RETCODE_OK, participant->delete_publisher(pub)); + EXPECT_EQ(RETCODE_OK, participant->delete_topic(topic)); + EXPECT_EQ(RETCODE_OK, DomainParticipantFactory::get_instance()->delete_participant(participant)); } TEST(ParticipantTests, CreatePublisher) @@ -1782,8 +1845,8 @@ TEST(ParticipantTests, CreatePublisher) ASSERT_NE(publisher, nullptr); - ASSERT_TRUE(participant->delete_publisher(publisher) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(participant->delete_publisher(publisher) == RETCODE_OK); + ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == RETCODE_OK); } void check_publisher_with_profile ( @@ -1793,16 +1856,10 @@ void check_publisher_with_profile ( PublisherQos qos; publisher->get_qos(qos); - PublisherAttributes publisher_atts; - XMLProfileManager::fillPublisherAttributes(profile_name, publisher_atts); - - //Values taken from profile - ASSERT_TRUE(qos.group_data().dataVec() == publisher_atts.qos.m_groupData.dataVec()); - ASSERT_TRUE(qos.partition() == publisher_atts.qos.m_partition); - ASSERT_TRUE(qos.presentation() == publisher_atts.qos.m_presentation); - - //Values not implemented on attributes (taken from default QoS) - ASSERT_TRUE(qos.entity_factory() == PUBLISHER_QOS_DEFAULT.entity_factory()); + PublisherQos profile_qos; + EXPECT_EQ(publisher->get_participant()->get_publisher_qos_from_profile(profile_name, profile_qos), + RETCODE_OK); + EXPECT_EQ(qos, profile_qos); } TEST(ParticipantTests, CreatePublisherWithProfile) @@ -1816,24 +1873,15 @@ TEST(ParticipantTests, CreatePublisherWithProfile) Publisher* default_publisher = participant->create_publisher(PUBLISHER_QOS_DEFAULT); ASSERT_NE(default_publisher, nullptr); check_publisher_with_profile(default_publisher, "test_default_publisher_profile"); - ASSERT_TRUE(participant->delete_publisher(default_publisher) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(participant->delete_publisher(default_publisher) == RETCODE_OK); //participant using non-default profile Publisher* publisher = participant->create_publisher_with_profile("test_publisher_profile"); ASSERT_NE(publisher, nullptr); check_publisher_with_profile(publisher, "test_publisher_profile"); - ASSERT_TRUE(participant->delete_publisher(publisher) == ReturnCode_t::RETCODE_OK); - - ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == ReturnCode_t::RETCODE_OK); -} - -TEST(ParticipantTests, CreatePSMPublisher) -{ - ::dds::domain::DomainParticipant participant = ::dds::domain::DomainParticipant(0, PARTICIPANT_QOS_DEFAULT); - ::dds::pub::Publisher publisher = ::dds::core::null; - publisher = ::dds::pub::Publisher(participant); + ASSERT_TRUE(participant->delete_publisher(publisher) == RETCODE_OK); - ASSERT_NE(publisher, ::dds::core::null); + ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == RETCODE_OK); } TEST(ParticipantTests, ChangeDefaultPublisherQos) @@ -1842,40 +1890,24 @@ TEST(ParticipantTests, ChangeDefaultPublisherQos) DomainParticipantFactory::get_instance()->create_participant( (uint32_t)GET_PID() % 230, PARTICIPANT_QOS_DEFAULT); - ASSERT_TRUE(participant->set_default_publisher_qos(PUBLISHER_QOS_DEFAULT) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(participant->set_default_publisher_qos(PUBLISHER_QOS_DEFAULT) == RETCODE_OK); PublisherQos qos; - ASSERT_TRUE(participant->get_default_publisher_qos(qos) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(participant->get_default_publisher_qos(qos) == RETCODE_OK); ASSERT_EQ(qos, PUBLISHER_QOS_DEFAULT); qos.entity_factory().autoenable_created_entities = false; - ASSERT_TRUE(participant->set_default_publisher_qos(qos) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(participant->set_default_publisher_qos(qos) == RETCODE_OK); PublisherQos pqos; - ASSERT_TRUE(participant->get_default_publisher_qos(pqos) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(participant->get_default_publisher_qos(pqos) == RETCODE_OK); ASSERT_TRUE(qos == pqos); ASSERT_EQ(pqos.entity_factory().autoenable_created_entities, false); - ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == ReturnCode_t::RETCODE_OK); -} - -TEST(ParticipantTests, ChangePSMDefaultPublisherQos) -{ - ::dds::domain::DomainParticipant participant = ::dds::domain::DomainParticipant(0, PARTICIPANT_QOS_DEFAULT); - ::dds::pub::qos::PublisherQos qos = participant.default_publisher_qos(); - ASSERT_EQ(qos, PUBLISHER_QOS_DEFAULT); - - qos.entity_factory().autoenable_created_entities = false; - - ASSERT_NO_THROW(participant.default_publisher_qos(qos)); - - ::dds::pub::qos::PublisherQos pqos = participant.default_publisher_qos(); - - ASSERT_TRUE(qos == pqos); - ASSERT_EQ(pqos.entity_factory().autoenable_created_entities, false); + ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == RETCODE_OK); } TEST(ParticipantTests, CreateSubscriber) @@ -1887,8 +1919,8 @@ TEST(ParticipantTests, CreateSubscriber) Subscriber* subscriber = participant->create_subscriber(SUBSCRIBER_QOS_DEFAULT); ASSERT_NE(subscriber, nullptr); - ASSERT_TRUE(participant->delete_subscriber(subscriber) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(participant->delete_subscriber(subscriber) == RETCODE_OK); + ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == RETCODE_OK); } void check_subscriber_with_profile ( @@ -1898,16 +1930,10 @@ void check_subscriber_with_profile ( SubscriberQos qos; subscriber->get_qos(qos); - SubscriberAttributes subscriber_atts; - XMLProfileManager::fillSubscriberAttributes(profile_name, subscriber_atts); - - //Values taken from profile - ASSERT_TRUE(qos.group_data().dataVec() == subscriber_atts.qos.m_groupData.dataVec()); - ASSERT_TRUE(qos.partition() == subscriber_atts.qos.m_partition); - ASSERT_TRUE(qos.presentation() == subscriber_atts.qos.m_presentation); - - //Values not implemented on attributes (taken from default QoS) - ASSERT_TRUE(qos.entity_factory() == SUBSCRIBER_QOS_DEFAULT.entity_factory()); + SubscriberQos profile_qos; + EXPECT_EQ(subscriber->get_participant()->get_subscriber_qos_from_profile(profile_name, profile_qos), + RETCODE_OK); + EXPECT_EQ(qos, profile_qos); } TEST(ParticipantTests, GetSubscriberProfileQos) @@ -1922,7 +1948,7 @@ TEST(ParticipantTests, GetSubscriberProfileQos) SubscriberQos qos; EXPECT_EQ( participant->get_subscriber_qos_from_profile("test_subscriber_profile", qos), - ReturnCode_t::RETCODE_OK); + RETCODE_OK); Subscriber* subscriber = participant->create_subscriber(qos); ASSERT_NE(subscriber, nullptr); @@ -1932,11 +1958,11 @@ TEST(ParticipantTests, GetSubscriberProfileQos) // Test return when a non-existent profile is used EXPECT_EQ( participant->get_subscriber_qos_from_profile("incorrect_profile_name", qos), - ReturnCode_t::RETCODE_BAD_PARAMETER); + RETCODE_BAD_PARAMETER); // Clean up - ASSERT_EQ(participant->delete_subscriber(subscriber), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(participant->delete_subscriber(subscriber), RETCODE_OK); + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), RETCODE_OK); } TEST(ParticipantTests, CreateSubscriberWithProfile) @@ -1950,15 +1976,15 @@ TEST(ParticipantTests, CreateSubscriberWithProfile) Subscriber* default_subscriber = participant->create_subscriber(SUBSCRIBER_QOS_DEFAULT); ASSERT_NE(default_subscriber, nullptr); check_subscriber_with_profile(default_subscriber, "test_default_subscriber_profile"); - ASSERT_TRUE(participant->delete_subscriber(default_subscriber) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(participant->delete_subscriber(default_subscriber) == RETCODE_OK); //participant using non-default profile Subscriber* subscriber = participant->create_subscriber_with_profile("test_subscriber_profile"); ASSERT_NE(subscriber, nullptr); check_subscriber_with_profile(subscriber, "test_subscriber_profile"); - ASSERT_TRUE(participant->delete_subscriber(subscriber) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(participant->delete_subscriber(subscriber) == RETCODE_OK); - ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == RETCODE_OK); } TEST(ParticipantTests, GetPublisherProfileQos) @@ -1973,7 +1999,7 @@ TEST(ParticipantTests, GetPublisherProfileQos) PublisherQos qos; EXPECT_EQ( participant->get_publisher_qos_from_profile("test_publisher_profile", qos), - ReturnCode_t::RETCODE_OK); + RETCODE_OK); Publisher* publisher = participant->create_publisher(qos); ASSERT_NE(publisher, nullptr); @@ -1983,22 +2009,57 @@ TEST(ParticipantTests, GetPublisherProfileQos) // Test return when a non-existent profile is used EXPECT_EQ( participant->get_publisher_qos_from_profile("incorrect_profile_name", qos), - ReturnCode_t::RETCODE_BAD_PARAMETER); + RETCODE_BAD_PARAMETER); // Clean up - ASSERT_EQ(participant->delete_publisher(publisher), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(participant->delete_publisher(publisher), RETCODE_OK); + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), RETCODE_OK); } +TEST(ParticipantTests, GetReplierProfileQos) +{ + DomainParticipantFactory::get_instance()->load_XML_profiles_file("test_xml_profile.xml"); + DomainParticipant* participant = + DomainParticipantFactory::get_instance()->create_participant( + (uint32_t)GET_PID() % 230, PARTICIPANT_QOS_DEFAULT); + ASSERT_NE(participant, nullptr); + + // Extract qos from profile + ReplierQos qos; + EXPECT_EQ( + participant->get_replier_qos_from_profile("test_replier_profile", qos), + RETCODE_OK); + + // Test return when a non-existent profile is used + EXPECT_EQ( + participant->get_replier_qos_from_profile("incorrect_profile_name", qos), + RETCODE_BAD_PARAMETER); -TEST(ParticipantTests, CreatePSMSubscriber) + // Clean up + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), RETCODE_OK); +} + +TEST(ParticipantTests, GetRequesterProfileQos) { - ::dds::domain::DomainParticipant participant = ::dds::domain::DomainParticipant( + DomainParticipantFactory::get_instance()->load_XML_profiles_file("test_xml_profile.xml"); + DomainParticipant* participant = + DomainParticipantFactory::get_instance()->create_participant( (uint32_t)GET_PID() % 230, PARTICIPANT_QOS_DEFAULT); - ::dds::sub::Subscriber subscriber = ::dds::core::null; - subscriber = ::dds::sub::Subscriber(participant, SUBSCRIBER_QOS_DEFAULT); + ASSERT_NE(participant, nullptr); - ASSERT_NE(subscriber, ::dds::core::null); + // Extract qos from profile + RequesterQos qos; + EXPECT_EQ( + participant->get_requester_qos_from_profile("test_requester_profile", qos), + RETCODE_OK); + + // Test return when a non-existent profile is used + EXPECT_EQ( + participant->get_requester_qos_from_profile("incorrect_profile_name", qos), + RETCODE_BAD_PARAMETER); + + // Clean up + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), RETCODE_OK); } TEST(ParticipantTests, DeletePublisher) @@ -2010,8 +2071,8 @@ TEST(ParticipantTests, DeletePublisher) Publisher* publisher = participant->create_publisher(PUBLISHER_QOS_DEFAULT); ASSERT_NE(publisher, nullptr); - ASSERT_TRUE(participant->delete_publisher(publisher) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(participant->delete_publisher(publisher) == RETCODE_OK); + ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == RETCODE_OK); } TEST(ParticipantTests, DeleteSubscriber) @@ -2023,8 +2084,8 @@ TEST(ParticipantTests, DeleteSubscriber) Subscriber* subscriber = participant->create_subscriber(SUBSCRIBER_QOS_DEFAULT); ASSERT_NE(subscriber, nullptr); - ASSERT_TRUE(participant->delete_subscriber(subscriber) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(participant->delete_subscriber(subscriber) == RETCODE_OK); + ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == RETCODE_OK); } TEST(ParticipantTests, ChangeDefaultSubscriberQos) @@ -2033,40 +2094,24 @@ TEST(ParticipantTests, ChangeDefaultSubscriberQos) DomainParticipantFactory::get_instance()->create_participant( (uint32_t)GET_PID() % 230, PARTICIPANT_QOS_DEFAULT); - ASSERT_EQ(participant->set_default_subscriber_qos(SUBSCRIBER_QOS_DEFAULT), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(participant->set_default_subscriber_qos(SUBSCRIBER_QOS_DEFAULT), RETCODE_OK); SubscriberQos qos; - ASSERT_EQ(participant->get_default_subscriber_qos(qos), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(participant->get_default_subscriber_qos(qos), RETCODE_OK); ASSERT_EQ(qos, SUBSCRIBER_QOS_DEFAULT); qos.entity_factory().autoenable_created_entities = false; - ASSERT_EQ(participant->set_default_subscriber_qos(qos), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(participant->set_default_subscriber_qos(qos), RETCODE_OK); SubscriberQos pqos; - ASSERT_EQ(participant->get_default_subscriber_qos(pqos), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(participant->get_default_subscriber_qos(pqos), RETCODE_OK); ASSERT_TRUE(pqos == qos); ASSERT_EQ(pqos.entity_factory().autoenable_created_entities, false); - ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == ReturnCode_t::RETCODE_OK); -} - -TEST(ParticipantTests, ChangePSMDefaultSubscriberQos) -{ - ::dds::domain::DomainParticipant participant = ::dds::domain::DomainParticipant(0, PARTICIPANT_QOS_DEFAULT); - ::dds::sub::qos::SubscriberQos qos = participant.default_subscriber_qos(); - ASSERT_EQ(qos, SUBSCRIBER_QOS_DEFAULT); - - qos.entity_factory().autoenable_created_entities = false; - - ASSERT_NO_THROW(participant.default_subscriber_qos(qos)); - - ::dds::sub::qos::SubscriberQos pqos = participant.default_subscriber_qos(); - - ASSERT_TRUE(qos == pqos); - ASSERT_EQ(pqos.entity_factory().autoenable_created_entities, false); + ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == RETCODE_OK); } TEST(ParticipantTests, ChangeDefaultTopicQos) @@ -2075,7 +2120,7 @@ TEST(ParticipantTests, ChangeDefaultTopicQos) DomainParticipantFactory::get_instance()->create_participant( (uint32_t)GET_PID() % 230, PARTICIPANT_QOS_DEFAULT); - ASSERT_TRUE(participant->set_default_topic_qos(TOPIC_QOS_DEFAULT) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(participant->set_default_topic_qos(TOPIC_QOS_DEFAULT) == RETCODE_OK); TopicQos qos; participant->get_default_topic_qos(qos); @@ -2084,7 +2129,7 @@ TEST(ParticipantTests, ChangeDefaultTopicQos) qos.reliability().kind = BEST_EFFORT_RELIABILITY_QOS; - ASSERT_TRUE(participant->set_default_topic_qos(qos) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(participant->set_default_topic_qos(qos) == RETCODE_OK); TopicQos tqos; participant->get_default_topic_qos(tqos); @@ -2093,25 +2138,9 @@ TEST(ParticipantTests, ChangeDefaultTopicQos) ASSERT_EQ(tqos.reliability().kind, BEST_EFFORT_RELIABILITY_QOS); qos.durability().kind = PERSISTENT_DURABILITY_QOS; - ASSERT_FALSE(participant->set_default_topic_qos(qos) == ReturnCode_t::RETCODE_OK); + ASSERT_FALSE(participant->set_default_topic_qos(qos) == RETCODE_OK); - ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == ReturnCode_t::RETCODE_OK); -} - -TEST(ParticipantTests, ChangePSMDefaultTopicQos) -{ - ::dds::domain::DomainParticipant participant = ::dds::domain::DomainParticipant(0, PARTICIPANT_QOS_DEFAULT); - ::dds::topic::qos::TopicQos qos = participant.default_topic_qos(); - - ASSERT_EQ(qos, TOPIC_QOS_DEFAULT); - - qos.ownership().kind = EXCLUSIVE_OWNERSHIP_QOS; - - ASSERT_NO_THROW(participant.default_topic_qos(qos)); - - ::dds::topic::qos::TopicQos tqos = participant.default_topic_qos(); - ASSERT_EQ(qos, tqos); - ASSERT_EQ(tqos.ownership().kind, EXCLUSIVE_OWNERSHIP_QOS); + ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == RETCODE_OK); } void check_topic_with_profile ( @@ -2121,12 +2150,10 @@ void check_topic_with_profile ( TopicQos qos; topic->get_qos(qos); - TopicAttributesQos topic_atts; - XMLProfileManager::fillTopicAttributes(profile_name, topic_atts); - - //Values taken from profile - ASSERT_TRUE(qos.history() == topic_atts.historyQos); - ASSERT_TRUE(qos.resource_limits() == topic_atts.resourceLimitsQos); + TopicQos profile_qos; + EXPECT_EQ(topic->get_participant()->get_topic_qos_from_profile(profile_name, profile_qos), + RETCODE_OK); + EXPECT_EQ(qos, profile_qos); } TEST(ParticipantTests, GetTopicProfileQos) @@ -2143,7 +2170,7 @@ TEST(ParticipantTests, GetTopicProfileQos) TopicQos qos; EXPECT_EQ( participant->get_topic_qos_from_profile("test_topic_profile", qos), - ReturnCode_t::RETCODE_OK); + RETCODE_OK); Topic* topic = participant->create_topic("footopic", type.get_type_name(), qos); ASSERT_NE(topic, nullptr); @@ -2154,11 +2181,11 @@ TEST(ParticipantTests, GetTopicProfileQos) // Test return when a non-existent profile is used EXPECT_EQ( participant->get_topic_qos_from_profile("incorrect_profile_name", qos), - ReturnCode_t::RETCODE_BAD_PARAMETER); + RETCODE_BAD_PARAMETER); // Clean up - ASSERT_EQ(participant->delete_topic(topic), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(participant->delete_topic(topic), RETCODE_OK); + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), RETCODE_OK); } TEST(ParticipantTests, CreateTopic) @@ -2179,15 +2206,15 @@ TEST(ParticipantTests, CreateTopic) Topic* topic_duplicated = participant->create_topic("footopic", "footype", TOPIC_QOS_DEFAULT); ASSERT_EQ(topic_duplicated, nullptr); - ASSERT_TRUE(participant->delete_topic(topic) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(participant->delete_topic(topic) == RETCODE_OK); // Topic using non-default profile Topic* topic_profile = participant->create_topic_with_profile("footopic", "footype", "test_topic_profile"); ASSERT_NE(topic_profile, nullptr); check_topic_with_profile(topic_profile, "test_topic_profile"); - ASSERT_TRUE(participant->delete_topic(topic_profile) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(participant->delete_topic(topic_profile) == RETCODE_OK); - ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == RETCODE_OK); } // Test that creating a Topic with a Data Type name different from the Type Support is possible as long @@ -2210,7 +2237,7 @@ TEST(ParticipantTests, CreateTopicWithDifferentTypeName) Topic* topic_duplicated = participant->create_topic("footopic", type_name, TOPIC_QOS_DEFAULT); ASSERT_EQ(topic_duplicated, nullptr); - ASSERT_TRUE(participant->delete_topic(topic) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(participant->delete_topic(topic) == RETCODE_OK); } // Test that creating a Topic with a Data Type name different from the data type is not possible @@ -2245,19 +2272,6 @@ TEST(ParticipantTests, CreateTopicWithDifferentTypeName_negative) } } -TEST(ParticipantTests, PSMCreateTopic) -{ - ::dds::domain::DomainParticipant participant = ::dds::domain::DomainParticipant(0, PARTICIPANT_QOS_DEFAULT); - - TypeSupport type(new TopicDataTypeMock()); - type.register_type(participant.delegate().get(), "footype"); - - ::dds::topic::Topic topic = ::dds::core::null; - topic = ::dds::topic::Topic(participant, "footopic", "footype", TOPIC_QOS_DEFAULT); - - ASSERT_NE(topic, ::dds::core::null); -} - TEST(ParticipantTests, DeleteTopic) { uint32_t domain_id = (uint32_t)GET_PID() % 230; @@ -2271,11 +2285,11 @@ TEST(ParticipantTests, DeleteTopic) Topic* topic = participant->create_topic("footopic", "footype", TOPIC_QOS_DEFAULT); - ASSERT_TRUE(participant->delete_topic(nullptr) == ReturnCode_t::RETCODE_BAD_PARAMETER); - ASSERT_TRUE(participant2->delete_topic(topic) == ReturnCode_t::RETCODE_PRECONDITION_NOT_MET); - ASSERT_TRUE(participant->delete_topic(topic) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant2) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(participant->delete_topic(nullptr) == RETCODE_BAD_PARAMETER); + ASSERT_TRUE(participant2->delete_topic(topic) == RETCODE_PRECONDITION_NOT_MET); + ASSERT_TRUE(participant->delete_topic(topic) == RETCODE_OK); + ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == RETCODE_OK); + ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant2) == RETCODE_OK); } TEST(ParticipantTests, LookupTopicDescription) @@ -2299,10 +2313,10 @@ TEST(ParticipantTests, LookupTopicDescription) ASSERT_EQ(participant->lookup_topicdescription(topic_name), topic); // After topic deletion, should return nil - EXPECT_TRUE(participant->delete_topic(topic) == ReturnCode_t::RETCODE_OK); + EXPECT_TRUE(participant->delete_topic(topic) == RETCODE_OK); ASSERT_EQ(participant->lookup_topicdescription(topic_name), nullptr); - ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == RETCODE_OK); } TEST(ParticipantTests, DeleteTopicInUse) @@ -2326,13 +2340,13 @@ TEST(ParticipantTests, DeleteTopicInUse) DataReader* data_reader = subscriber->create_datareader(topic, DATAREADER_QOS_DEFAULT); ASSERT_NE(data_reader, nullptr); - ASSERT_EQ(participant->delete_topic(topic), ReturnCode_t::RETCODE_PRECONDITION_NOT_MET); + ASSERT_EQ(participant->delete_topic(topic), RETCODE_PRECONDITION_NOT_MET); - ASSERT_EQ(subscriber->delete_datareader(data_reader), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(participant->delete_topic(topic), ReturnCode_t::RETCODE_PRECONDITION_NOT_MET); - ASSERT_EQ(participant->delete_contentfilteredtopic(content_filtered_topic), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(participant->delete_topic(topic), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(participant->delete_subscriber(subscriber), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(subscriber->delete_datareader(data_reader), RETCODE_OK); + ASSERT_EQ(participant->delete_topic(topic), RETCODE_PRECONDITION_NOT_MET); + ASSERT_EQ(participant->delete_contentfilteredtopic(content_filtered_topic), RETCODE_OK); + ASSERT_EQ(participant->delete_topic(topic), RETCODE_OK); + ASSERT_EQ(participant->delete_subscriber(subscriber), RETCODE_OK); topic = participant->create_topic("footopic", "footype", TOPIC_QOS_DEFAULT); @@ -2342,13 +2356,13 @@ TEST(ParticipantTests, DeleteTopicInUse) DataWriter* data_writer = publisher->create_datawriter(topic, DATAWRITER_QOS_DEFAULT); ASSERT_NE(data_writer, nullptr); - ASSERT_EQ(participant->delete_topic(topic), ReturnCode_t::RETCODE_PRECONDITION_NOT_MET); + ASSERT_EQ(participant->delete_topic(topic), RETCODE_PRECONDITION_NOT_MET); - ASSERT_EQ(publisher->delete_datawriter(data_writer), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(participant->delete_topic(topic), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(publisher->delete_datawriter(data_writer), RETCODE_OK); + ASSERT_EQ(participant->delete_topic(topic), RETCODE_OK); - ASSERT_EQ(participant->delete_publisher(publisher), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(participant->delete_publisher(publisher), RETCODE_OK); + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), RETCODE_OK); } // Check that the constraints on maximum expression parameter size are honored @@ -2383,10 +2397,10 @@ TEST(ParticipantTests, ExpressionParameterLimits) ASSERT_NE(content_filtered_topic_default_valid_parameters, nullptr); ASSERT_EQ(participant_default_max_parameters->delete_contentfilteredtopic( - content_filtered_topic_default_valid_parameters), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(participant_default_max_parameters->delete_topic(topic_default_max_parameters), ReturnCode_t::RETCODE_OK); + content_filtered_topic_default_valid_parameters), RETCODE_OK); + ASSERT_EQ(participant_default_max_parameters->delete_topic(topic_default_max_parameters), RETCODE_OK); ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant( - participant_default_max_parameters), ReturnCode_t::RETCODE_OK); + participant_default_max_parameters), RETCODE_OK); // Test user defined limits pqos.allocation().content_filter.expression_parameters.maximum = 1; @@ -2406,14 +2420,14 @@ TEST(ParticipantTests, ExpressionParameterLimits) topic, "", {"Parameter1"}); ASSERT_NE(content_filtered_topic, nullptr); - ASSERT_EQ(fastrtps::types::ReturnCode_t::RETCODE_BAD_PARAMETER, content_filtered_topic->set_expression_parameters( + ASSERT_EQ(eprosima::fastdds::dds::RETCODE_BAD_PARAMETER, content_filtered_topic->set_expression_parameters( {"Parameter1", "Parameter2"})); - ASSERT_EQ(participant->delete_contentfilteredtopic(content_filtered_topic), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(participant->delete_topic(topic), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(participant->delete_contentfilteredtopic(content_filtered_topic), RETCODE_OK); + ASSERT_EQ(participant->delete_topic(topic), RETCODE_OK); - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), RETCODE_OK); } @@ -2422,7 +2436,7 @@ void set_listener_test ( DomainParticipantListener* listener, StatusMask mask) { - ASSERT_EQ(participant->set_listener(listener, mask), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(participant->set_listener(listener, mask), RETCODE_OK); ASSERT_EQ(participant->get_status_mask(), mask); } @@ -2481,7 +2495,7 @@ TEST(ParticipantTests, SetListener) std::get<2>(testing_case)); } - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), RETCODE_OK); } class CustomListener2 : public DomainParticipantListener @@ -2502,8 +2516,10 @@ class CustomListener2 : public DomainParticipantListener void on_participant_discovery( eprosima::fastdds::dds::DomainParticipant*, - eprosima::fastrtps::rtps::ParticipantDiscoveryInfo&&) override + eprosima::fastrtps::rtps::ParticipantDiscoveryInfo&&, + bool& should_be_ignored) override { + static_cast(should_be_ignored); try { promise_.set_value(); @@ -2537,10 +2553,10 @@ TEST(ParticipantTests, FailingSetListener) // Wait for callback trigger listener.get_future().wait(); - ASSERT_EQ(participant->set_listener(nullptr, std::chrono::seconds(1)), ReturnCode_t::RETCODE_ERROR); - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(participant->set_listener(nullptr, std::chrono::seconds(1)), RETCODE_ERROR); + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), RETCODE_OK); ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant( - participant_to_discover), ReturnCode_t::RETCODE_OK); + participant_to_discover), RETCODE_OK); } /* @@ -2560,7 +2576,7 @@ TEST(ParticipantTests, CheckDomainParticipantQos) DomainParticipantFactoryQos qos; qos.entity_factory().autoenable_created_entities = false; - ASSERT_TRUE(factory->set_qos(qos) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(factory->set_qos(qos) == RETCODE_OK); } // Create the participant @@ -2570,25 +2586,25 @@ TEST(ParticipantTests, CheckDomainParticipantQos) // Get the participant qos DomainParticipantQos qos; - ASSERT_TRUE(participant->get_qos(qos) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(participant->get_qos(qos) == RETCODE_OK); // Change the user data qos.user_data().set_max_size(5); std::vector my_data {0, 1, 2, 3, 4}; qos.user_data().setValue(my_data); - ASSERT_TRUE(participant->set_qos(qos) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(participant->set_qos(qos) == RETCODE_OK); // Change the ParticipantResourceLimitsQos to a maximum user data value less than the current user data size // This should return an Inconsistent Policy error code qos.allocation().data_limits.max_user_data = 1; ASSERT_EQ(qos.allocation().data_limits.max_user_data, 1ul); - ASSERT_TRUE(participant->set_qos(qos) == ReturnCode_t::RETCODE_INCONSISTENT_POLICY); + ASSERT_TRUE(participant->set_qos(qos) == RETCODE_INCONSISTENT_POLICY); // Enable the participant - EXPECT_EQ(ReturnCode_t::RETCODE_OK, participant->enable()); + EXPECT_EQ(RETCODE_OK, participant->enable()); // Remove the participant - ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == RETCODE_OK); } /* @@ -2601,7 +2617,7 @@ TEST(ParticipantTests, ChangeAllocationDomainParticipantQos) DomainParticipantFactory* factory = DomainParticipantFactory::get_instance(); DomainParticipantFactoryQos pfqos; pfqos.entity_factory().autoenable_created_entities = false; - ASSERT_EQ(factory->set_qos(pfqos), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(factory->set_qos(pfqos), RETCODE_OK); DomainParticipant* participant = DomainParticipantFactory::get_instance()->create_participant( @@ -2613,7 +2629,7 @@ TEST(ParticipantTests, ChangeAllocationDomainParticipantQos) check_equivalent_qos(qos, PARTICIPANT_QOS_DEFAULT); qos.allocation().data_limits.max_properties = 10; - ASSERT_EQ(participant->set_qos(qos), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(participant->set_qos(qos), RETCODE_OK); DomainParticipantQos pqos; participant->get_qos(pqos); @@ -2625,9 +2641,9 @@ TEST(ParticipantTests, ChangeAllocationDomainParticipantQos) ASSERT_TRUE(participant->is_enabled()); participant->get_qos(pqos); pqos.allocation().data_limits.max_properties = 20; - ASSERT_EQ(participant->set_qos(pqos), ReturnCode_t::RETCODE_IMMUTABLE_POLICY); + ASSERT_EQ(participant->set_qos(pqos), RETCODE_IMMUTABLE_POLICY); - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), RETCODE_OK); } /* @@ -2640,7 +2656,7 @@ TEST(ParticipantTests, ChangeDomainParcipantName) DomainParticipantFactory* factory = DomainParticipantFactory::get_instance(); DomainParticipantFactoryQos pfqos; pfqos.entity_factory().autoenable_created_entities = false; - ASSERT_EQ(factory->set_qos(pfqos), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(factory->set_qos(pfqos), RETCODE_OK); DomainParticipant* participant = DomainParticipantFactory::get_instance()->create_participant( @@ -2652,7 +2668,7 @@ TEST(ParticipantTests, ChangeDomainParcipantName) check_equivalent_qos(qos, PARTICIPANT_QOS_DEFAULT); qos.name() = "part1"; - ASSERT_EQ(participant->set_qos(qos), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(participant->set_qos(qos), RETCODE_OK); DomainParticipantQos pqos; participant->get_qos(pqos); @@ -2664,9 +2680,9 @@ TEST(ParticipantTests, ChangeDomainParcipantName) ASSERT_TRUE(participant->is_enabled()); participant->get_qos(pqos); pqos.name() = "new_part1"; - ASSERT_EQ(participant->set_qos(pqos), ReturnCode_t::RETCODE_IMMUTABLE_POLICY); + ASSERT_EQ(participant->set_qos(pqos), RETCODE_IMMUTABLE_POLICY); - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), RETCODE_OK); } /* @@ -2686,20 +2702,20 @@ TEST(ParticipantTests, DeleteEntitiesNegativeClauses) ASSERT_NE(subscriber_1, nullptr); // Try to delete this subscriber using the second partipant. This should return a RETCODE_PRECONDITION_NOT_MET // error code as this subscriber does not belong to the second participant - ASSERT_EQ(participant_2->delete_subscriber(subscriber_1), ReturnCode_t::RETCODE_PRECONDITION_NOT_MET); - ASSERT_EQ(participant_1->delete_subscriber(subscriber_1), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(participant_2->delete_subscriber(subscriber_1), RETCODE_PRECONDITION_NOT_MET); + ASSERT_EQ(participant_1->delete_subscriber(subscriber_1), RETCODE_OK); // Create a publisher in the first participant Publisher* publisher_1 = participant_1->create_publisher(PUBLISHER_QOS_DEFAULT); ASSERT_NE(publisher_1, nullptr); // Try to delete this publisher using the second partipant. This should return a RETCODE_PRECONDITION_NOT_MET // error code as this publisher does not belong to the second participant - ASSERT_EQ(participant_2->delete_publisher(publisher_1), ReturnCode_t::RETCODE_PRECONDITION_NOT_MET); - ASSERT_EQ(participant_1->delete_publisher(publisher_1), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(participant_2->delete_publisher(publisher_1), RETCODE_PRECONDITION_NOT_MET); + ASSERT_EQ(participant_1->delete_publisher(publisher_1), RETCODE_OK); // Remove both participants - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant_1), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant_2), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant_1), RETCODE_OK); + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant_2), RETCODE_OK); } /* @@ -2725,7 +2741,7 @@ TEST(ParticipantTests, CreateEntitiesWithProfileNegativeClauses) ASSERT_EQ(topic, nullptr); // Remove the participant - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), RETCODE_OK); } /* @@ -2745,10 +2761,10 @@ TEST(ParticipantTests, RegisterTypeNegativeClauses) // Create the TypeSupport with the TopicDataType with an empty name TypeSupport type(data_type); // Register the type shoul return a RETCODE_BAD_PARAMETER return code - EXPECT_EQ(type.register_type(participant), ReturnCode_t::RETCODE_BAD_PARAMETER); + EXPECT_EQ(type.register_type(participant), RETCODE_BAD_PARAMETER); // Remove the participant - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), RETCODE_OK); } /* @@ -2763,7 +2779,7 @@ TEST(ParticipantTests, AssertLivelinesNegativeClauses) DomainParticipantFactory* factory = DomainParticipantFactory::get_instance(); DomainParticipantFactoryQos qos; qos.entity_factory().autoenable_created_entities = false; - ASSERT_EQ(factory->set_qos(qos), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(factory->set_qos(qos), RETCODE_OK); // Create a disabled participant DomainParticipant* participant = @@ -2773,23 +2789,23 @@ TEST(ParticipantTests, AssertLivelinesNegativeClauses) ASSERT_FALSE(participant->is_enabled()); // Assert liveliness from a disabled participant should return a RETCODE_NOT_ENABLED return code. - ASSERT_EQ(participant->assert_liveliness(), ReturnCode_t::RETCODE_NOT_ENABLED); + ASSERT_EQ(participant->assert_liveliness(), RETCODE_NOT_ENABLED); // Change the participant QoS to disable the Writer Liveliness Protocol DomainParticipantQos pqos; - ASSERT_EQ(participant->get_qos(pqos), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(participant->get_qos(pqos), RETCODE_OK); pqos.wire_protocol().builtin.use_WriterLivelinessProtocol = false; - ASSERT_EQ(participant->set_qos(pqos), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(participant->set_qos(pqos), RETCODE_OK); // Enable the participant - EXPECT_EQ(ReturnCode_t::RETCODE_OK, participant->enable()); + EXPECT_EQ(RETCODE_OK, participant->enable()); EXPECT_TRUE(participant->is_enabled()); // Check that an error is given at trying to assert the livelines from a participant with a disabled // Writer Liveliness Protocol (WLP writer is not defined). - ASSERT_EQ(participant->assert_liveliness(), ReturnCode_t::RETCODE_ERROR); + ASSERT_EQ(participant->assert_liveliness(), RETCODE_ERROR); // Remove the participant - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), RETCODE_OK); } /* @@ -2802,8 +2818,8 @@ TEST(ParticipantTests, GetCurrentTime) (uint32_t)GET_PID() % 230, PARTICIPANT_QOS_DEFAULT); eprosima::fastrtps::Time_t now; - ASSERT_EQ(participant->get_current_time(now), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(participant->get_current_time(now), RETCODE_OK); + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), RETCODE_OK); } /* @@ -2828,8 +2844,8 @@ TEST(ParticipantTests, GetParticipantConst) ASSERT_EQ(participant_pub->guid(), participant->guid()); // Remove the publisher and the participant - ASSERT_EQ(participant->delete_publisher(publisher), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(participant->delete_publisher(publisher), RETCODE_OK); + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), RETCODE_OK); } @@ -2844,7 +2860,7 @@ TEST(ParticipantTests, GetParticipantNames) DomainParticipantFactory* factory = DomainParticipantFactory::get_instance(); DomainParticipantFactoryQos qos; qos.entity_factory().autoenable_created_entities = false; - ASSERT_EQ(factory->set_qos(qos), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(factory->set_qos(qos), RETCODE_OK); // Create a disabled participant DomainParticipant* participant = @@ -2858,7 +2874,7 @@ TEST(ParticipantTests, GetParticipantNames) ASSERT_TRUE(participant_names.empty()); // Enable the participant - EXPECT_EQ(ReturnCode_t::RETCODE_OK, participant->enable()); + EXPECT_EQ(RETCODE_OK, participant->enable()); EXPECT_TRUE(participant->is_enabled()); // Check that the participant name is filled when the participant is enabled @@ -2866,7 +2882,7 @@ TEST(ParticipantTests, GetParticipantNames) ASSERT_FALSE(participant_names.empty()); // Remove the participant - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), RETCODE_OK); } /* @@ -2898,7 +2914,7 @@ TEST(ParticipantTests, CreateTopicNegativeClauses) ASSERT_EQ(topic, nullptr); // Remove the participant - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), RETCODE_OK); } /* @@ -2956,16 +2972,16 @@ TEST(ParticipantTests, ContainsEntity) ASSERT_TRUE(participant->contains_entity(data_reader_ihandle, true)); // Remove data_writer, data_reader, publisher, subscriber and topic entities. - ASSERT_EQ(publisher->delete_datawriter(data_writer), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(subscriber->delete_datareader(data_reader), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(participant->delete_publisher(publisher), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(participant->delete_subscriber(subscriber), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(participant->delete_topic(topic), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(publisher->delete_datawriter(data_writer), RETCODE_OK); + ASSERT_EQ(subscriber->delete_datareader(data_reader), RETCODE_OK); + ASSERT_EQ(participant->delete_publisher(publisher), RETCODE_OK); + ASSERT_EQ(participant->delete_subscriber(subscriber), RETCODE_OK); + ASSERT_EQ(participant->delete_topic(topic), RETCODE_OK); // Check that the participant does not contains a removed publisher ASSERT_FALSE(participant->contains_entity(pub_ihandle, false)); - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), RETCODE_OK); } /* @@ -2983,10 +2999,10 @@ TEST(ParticipantTests, UnregisterType) (uint32_t)GET_PID() % 230, PARTICIPANT_QOS_DEFAULT); // Check that an error is given at trying to unregister a type with an empty name - ASSERT_EQ(participant->unregister_type(""), ReturnCode_t::RETCODE_BAD_PARAMETER); + ASSERT_EQ(participant->unregister_type(""), RETCODE_BAD_PARAMETER); // Check that no error is given at trying to unregister a non registered type - ASSERT_EQ(participant->unregister_type("missing_type"), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(participant->unregister_type("missing_type"), RETCODE_OK); TypeSupport type(new TopicDataTypeMock()); type.register_type(participant); @@ -3000,10 +3016,10 @@ TEST(ParticipantTests, UnregisterType) DataReader* data_reader = subscriber->create_datareader(topic, DATAREADER_QOS_DEFAULT); ASSERT_NE(data_reader, nullptr); // Check that an error is given at trying to unregister a type that is been used by a data_reader - ASSERT_EQ(participant->unregister_type(type.get_type_name()), ReturnCode_t::RETCODE_PRECONDITION_NOT_MET); + ASSERT_EQ(participant->unregister_type(type.get_type_name()), RETCODE_PRECONDITION_NOT_MET); - ASSERT_EQ(subscriber->delete_datareader(data_reader), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(participant->delete_subscriber(subscriber), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(subscriber->delete_datareader(data_reader), RETCODE_OK); + ASSERT_EQ(participant->delete_subscriber(subscriber), RETCODE_OK); // Create the publisher and a data_writer that use the above topic Publisher* publisher = participant->create_publisher(PUBLISHER_QOS_DEFAULT); @@ -3011,19 +3027,19 @@ TEST(ParticipantTests, UnregisterType) DataWriter* data_writer = publisher->create_datawriter(topic, DATAWRITER_QOS_DEFAULT); ASSERT_NE(data_writer, nullptr); // Check that an error is given at trying to unregister a type that is been used by a data_writer - ASSERT_EQ(participant->unregister_type(type.get_type_name()), ReturnCode_t::RETCODE_PRECONDITION_NOT_MET); + ASSERT_EQ(participant->unregister_type(type.get_type_name()), RETCODE_PRECONDITION_NOT_MET); - ASSERT_EQ(publisher->delete_datawriter(data_writer), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(participant->delete_publisher(publisher), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(publisher->delete_datawriter(data_writer), RETCODE_OK); + ASSERT_EQ(participant->delete_publisher(publisher), RETCODE_OK); - ASSERT_EQ(participant->delete_topic(topic), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(participant->delete_topic(topic), RETCODE_OK); // At this point, the type is not been used by any entity. // Check that no errors result when an unused topic is unregistered - ASSERT_EQ(participant->unregister_type(type.get_type_name()), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(participant->unregister_type(type.get_type_name()), RETCODE_OK); // Remove the participant - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), RETCODE_OK); } /* @@ -3041,7 +3057,7 @@ TEST(ParticipantTests, NewRemoteEndpointDiscovered) DomainParticipantFactory* factory = DomainParticipantFactory::get_instance(); DomainParticipantFactoryQos qos; qos.entity_factory().autoenable_created_entities = false; - ASSERT_TRUE(factory->set_qos(qos) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(factory->set_qos(qos) == RETCODE_OK); // Create a disabled participant DomainParticipant* participant = @@ -3058,7 +3074,7 @@ TEST(ParticipantTests, NewRemoteEndpointDiscovered) remote_endpoint_guid, 1, eprosima::fastrtps::rtps::EndpointKind_t::WRITER)); // Enable the participant - ASSERT_EQ(ReturnCode_t::RETCODE_OK, participant->enable()); + ASSERT_EQ(RETCODE_OK, participant->enable()); ASSERT_TRUE(participant->is_enabled()); // Check that a WRITER remote endpoint is not registered in an enabled participant @@ -3069,7 +3085,7 @@ TEST(ParticipantTests, NewRemoteEndpointDiscovered) remote_endpoint_guid, 1, eprosima::fastrtps::rtps::EndpointKind_t::READER)); // Remove the participant - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), RETCODE_OK); } /* @@ -3084,7 +3100,7 @@ TEST(ParticipantTests, SetDomainParticipantQos) // Change in the DomainParticipantQos object the listening socket buffer size setting of the transport qos pqos.transport().listen_socket_buffer_size = 262144; // Set the modified participant qos as the default qos - ASSERT_EQ(DomainParticipantFactory::get_instance()->set_default_participant_qos(pqos), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(DomainParticipantFactory::get_instance()->set_default_participant_qos(pqos), RETCODE_OK); DomainParticipant* participant = DomainParticipantFactory::get_instance()->create_participant( @@ -3109,7 +3125,7 @@ TEST(ParticipantTests, SetDomainParticipantQos) ASSERT_EQ(qos.transport().listen_socket_buffer_size, pqos.transport().listen_socket_buffer_size); // Remove the participant - ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == RETCODE_OK); } /* @@ -3127,35 +3143,40 @@ TEST(ParticipantTests, UpdatableDomainParticipantQos) // Check that the PropertyPolicyQos can not be changed in an enabled participant participant->get_qos(pqos); pqos.properties().properties().emplace_back("dds.persistence.guid", "72.61.75.6c.5f.73.61.6e.63.68.65.7a"); - ASSERT_EQ(participant->set_qos(pqos), ReturnCode_t::RETCODE_IMMUTABLE_POLICY); + ASSERT_EQ(participant->set_qos(pqos), RETCODE_IMMUTABLE_POLICY); // Check that the TransportConfigQos can not be changed in an enabled participant participant->get_qos(pqos); pqos.transport().listen_socket_buffer_size = 262144; - ASSERT_EQ(participant->set_qos(pqos), ReturnCode_t::RETCODE_IMMUTABLE_POLICY); + ASSERT_EQ(participant->set_qos(pqos), RETCODE_IMMUTABLE_POLICY); // Check that the builtin_controllers_sender_thread can not be changed in an enabled participant participant->get_qos(pqos); pqos.builtin_controllers_sender_thread().affinity = 1; - ASSERT_EQ(participant->set_qos(pqos), ReturnCode_t::RETCODE_IMMUTABLE_POLICY); + ASSERT_EQ(participant->set_qos(pqos), RETCODE_IMMUTABLE_POLICY); // Check that the timed_events_thread can not be changed in an enabled participant participant->get_qos(pqos); pqos.timed_events_thread().affinity = 1; - ASSERT_EQ(participant->set_qos(pqos), ReturnCode_t::RETCODE_IMMUTABLE_POLICY); + ASSERT_EQ(participant->set_qos(pqos), RETCODE_IMMUTABLE_POLICY); // Check that the discovery_server_thread can not be changed in an enabled participant participant->get_qos(pqos); pqos.discovery_server_thread().affinity = 1; - ASSERT_EQ(participant->set_qos(pqos), ReturnCode_t::RETCODE_IMMUTABLE_POLICY); + ASSERT_EQ(participant->set_qos(pqos), RETCODE_IMMUTABLE_POLICY); + + // Check that the typelookup_service_thread can not be changed in an enabled participant + participant->get_qos(pqos); + pqos.typelookup_service_thread().affinity = 1; + ASSERT_EQ(participant->set_qos(pqos), RETCODE_IMMUTABLE_POLICY); #if HAVE_SECURITY // Check that the security_log_thread can not be changed in an enabled participant participant->get_qos(pqos); pqos.security_log_thread().affinity = 1; - ASSERT_EQ(participant->set_qos(pqos), ReturnCode_t::RETCODE_IMMUTABLE_POLICY); + ASSERT_EQ(participant->set_qos(pqos), RETCODE_IMMUTABLE_POLICY); - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), RETCODE_OK); #endif // if HAVE_SECURITY } @@ -3176,419 +3197,24 @@ TEST(ParticipantTests, RegisterDynamicTypeToFactories) (uint32_t)GET_PID() % 230, PARTICIPANT_QOS_DEFAULT); // Create the dynamic type builder - DynamicType_ptr base_type = DynamicTypeBuilderFactory::get_instance()->create_uint32_type(); - DynamicTypeBuilder_ptr builder = DynamicTypeBuilderFactory::get_instance()->create_struct_builder(); - builder->add_member(0, "uint", base_type); + traits::ref_type type_descriptor = traits::make_shared(); + type_descriptor->kind(TK_STRUCTURE); + type_descriptor->name("mystruct"); + traits::ref_type builder {DynamicTypeBuilderFactory::get_instance()->create_type(type_descriptor)}; + traits::ref_type member_descriptor = traits::make_shared(); + member_descriptor->type(DynamicTypeBuilderFactory::get_instance()->get_primitive_type(TK_UINT32)); + member_descriptor->name("myuint"); + builder->add_member(member_descriptor); // Build the complete dynamic type - DynamicType_ptr dyn_type = builder->build(); + traits::ref_type dyn_type {builder->build()}; // Create the data instance - DynamicData_ptr data(DynamicDataFactory::get_instance()->create_data(dyn_type)); + traits::ref_type data {DynamicDataFactory::get_instance()->create_data(dyn_type)}; // Register the type - TypeSupport type(new eprosima::fastrtps::types::DynamicPubSubType(dyn_type)); - // Activating the auto_fill_type_information or the auto_fill_type_object settings, the participant will try to - // add the type dynamic type factories - type->auto_fill_type_information(true); - type->auto_fill_type_object(true); - ASSERT_EQ(type.register_type(participant), ReturnCode_t::RETCODE_OK); + TypeSupport type(new DynamicPubSubType(dyn_type)); + ASSERT_EQ(type.register_type(participant), RETCODE_OK); // Remove the participant - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); -} - -/* - * This test adds a complete dynamic type to the participant dynamic type factories without enabling the - * auto_fill_type_information setting - */ -TEST(ParticipantTests, RegisterDynamicTypeToFactoriesNotFillTypeInfo) -{ - // Do not enable entities on creation - DomainParticipantFactoryQos factory_qos; - factory_qos.entity_factory().autoenable_created_entities = false; - DomainParticipantFactory::get_instance()->set_qos(factory_qos); - - // Create a disabled participant - DomainParticipant* participant = - DomainParticipantFactory::get_instance()->create_participant( - (uint32_t)GET_PID() % 230, PARTICIPANT_QOS_DEFAULT); - - // Create the dynamic type builder - DynamicType_ptr base_type = DynamicTypeBuilderFactory::get_instance()->create_uint32_type(); - DynamicTypeBuilder_ptr builder = DynamicTypeBuilderFactory::get_instance()->create_struct_builder(); - builder->add_member(0, "uint", base_type); - - // Build the complete dynamic type - DynamicType_ptr dyn_type = builder->build(); - // Create the data instance - DynamicData_ptr data(DynamicDataFactory::get_instance()->create_data(dyn_type)); - - // Register the type - TypeSupport type(new eprosima::fastrtps::types::DynamicPubSubType(dyn_type)); - type->auto_fill_type_information(false); - type->auto_fill_type_object(true); - ASSERT_EQ(type.register_type(participant), ReturnCode_t::RETCODE_OK); - - // Remove the participant - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); -} - -// Mocked DynamicType for DynamicType creation tests -class DynamicTypeMock : public eprosima::fastrtps::types::DynamicType -{ -public: - - DynamicTypeMock( - const eprosima::fastrtps::types::TypeDescriptor* descriptor) - : eprosima::fastrtps::types::DynamicType(descriptor) - { - } - - DynamicType_ptr get_base_type_wrapper() const - { - return get_base_type(); - } - -}; - -/* - * This test attempts to add a non supported custom dynamic type to the participant dynamic type factories. The type - * should be registered in the participant but not added to the dynamic types factories. - */ -TEST(ParticipantTests, RegisterDynamicTypeToFactoriesNotTypeIdentifier) -{ - // Do not enable entities on creation - DomainParticipantFactoryQos factory_qos; - factory_qos.entity_factory().autoenable_created_entities = false; - DomainParticipantFactory::get_instance()->set_qos(factory_qos); - - // Create a disabled participant - DomainParticipant* participant = - DomainParticipantFactory::get_instance()->create_participant( - (uint32_t)GET_PID() % 230, PARTICIPANT_QOS_DEFAULT); - - // Create a not supported TypeDescriptor - const TypeDescriptor* myDescriptor = new TypeDescriptor("my_descriptor", 0x11); - // Create the base type for the dynamic type - DynamicType_ptr base_type(new DynamicTypeMock(myDescriptor)); - // Create a custom dynamic type builder using the wrong TypeDescriptor - DynamicTypeBuilder_ptr builder = - DynamicTypeBuilderFactory::get_instance()->create_custom_builder(myDescriptor, "my_dynamic_type"); - builder->add_member(0, "uint", base_type); - // Create the dynamic type - DynamicType_ptr dyn_type = builder->build(); - // Create the data instance - DynamicData_ptr data(DynamicDataFactory::get_instance()->create_data(dyn_type)); - - // Register the type - TypeSupport type(new eprosima::fastrtps::types::DynamicPubSubType(dyn_type)); - type->auto_fill_type_information(true); - type->auto_fill_type_object(true); - type.register_type(participant); - - TypeSupport ret_type = participant->find_type("my_dynamic_type"); - - // The type is registered in the participant but not in the dynamic types factories - ASSERT_FALSE(ret_type.empty()); - - // Remove TypeDescriptor before closing - delete myDescriptor; - - // Remove the participant - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); -} - -/* - * This test create a sequence of TypeIdentifiers to call the get_types() DomainParticipant function. It should return - * the TypeObjects associated with the TypeIdentifiers. Finally, the test checks that the writer guid prefix given by - * the TypeObject is the same as the DomainPartipant guid prefix. - */ -TEST(ParticipantTests, GetTypes) -{ - // Create the participant - DomainParticipantQos pqos; - pqos.wire_protocol().builtin.typelookup_config.use_client = true; - DomainParticipant* participant = - DomainParticipantFactory::get_instance()->create_participant( - (uint32_t)GET_PID() % 230, pqos); - - // Create the dynamic type builder - DynamicTypeBuilder_ptr builder_string = DynamicTypeBuilderFactory::get_instance()->create_string_builder(100); - // Create the dynamic type - DynamicType_ptr dyn_type_string = builder_string->build(); - TypeSupport type_string(new eprosima::fastrtps::types::DynamicPubSubType(dyn_type_string)); - // Create the data instance - DynamicData_ptr data_string(DynamicDataFactory::get_instance()->create_data(dyn_type_string)); - data_string->set_string_value("Dynamic String"); - - // Register the type - type_string->auto_fill_type_information(true); - type_string->auto_fill_type_object(true); - type_string.register_type(participant); - - // Create the sequence of TypeIdentifiers - const fastrtps::types::TypeIdentifier* indentifier_string = - fastrtps::types::TypeObjectFactory::get_instance()->get_type_identifier_trying_complete( - type_string.get_type_name()); - - fastrtps::types::TypeIdentifierSeq types; - types.push_back(*indentifier_string); - - // Checks that the writer guid prefix given by the TypeObject is the same as the DomainPartipant guid prefix - ASSERT_EQ(participant->guid().guidPrefix, participant->get_types(types).writer_guid().guidPrefix); - - // Remove the participant - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); -} - -/* - * This test create a sequence of TypeIdentifiers to call the get_type_dependencies() DomainParticipant function. - * Finally, the test checks that the writer guid prefix given by the TypeObject is the same as the DomainPartipant - * guid prefix. - */ -TEST(ParticipantTests, GetTypeDependencies) -{ - // Create the participant - DomainParticipantQos pqos; - pqos.wire_protocol().builtin.typelookup_config.use_client = true; - DomainParticipant* participant = - DomainParticipantFactory::get_instance()->create_participant( - (uint32_t)GET_PID() % 230, pqos); - - // Create the dynamic type builder - DynamicTypeBuilder_ptr builder_string = DynamicTypeBuilderFactory::get_instance()->create_string_builder(100); - // Create the dynamic type - DynamicType_ptr dyn_type_string = builder_string->build(); - TypeSupport type_string(new eprosima::fastrtps::types::DynamicPubSubType(dyn_type_string)); - // Create the data instance - DynamicData_ptr data_string(DynamicDataFactory::get_instance()->create_data(dyn_type_string)); - data_string->set_string_value("Dynamic String"); - - // Register the type - type_string->auto_fill_type_information(true); - type_string->auto_fill_type_object(true); - type_string.register_type(participant); - - // Create the sequence of TypeIdentifiers - const fastrtps::types::TypeIdentifier* indentifier_string = - fastrtps::types::TypeObjectFactory::get_instance()->get_type_identifier_trying_complete( - type_string.get_type_name()); - - fastrtps::types::TypeIdentifierSeq types; - types.push_back(*indentifier_string); - - // Checks that the writer guid prefix given by the TypeObject is the same as the DomainPartipant guid prefix - ASSERT_EQ(participant->guid().guidPrefix, participant->get_type_dependencies(types).writer_guid().guidPrefix); - - // Remove the participant - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); -} - -/* - * This test create two participants which will share a complete dynamic type. - * 1. The remote participant registers a dynamic type - * 2. The local participant register the dynamic type of the remote participant using the TypeInformation and the type - * name - * 3. Check that the type is not registered if the local participant is disabled - * 4. Check that the type is registered if the local participant is enabled - */ -TEST(ParticipantTests, RegisterRemoteTypeComplete) -{ - // Do not enable entities on creation - DomainParticipantFactoryQos factory_qos; - factory_qos.entity_factory().autoenable_created_entities = false; - DomainParticipantFactory::get_instance()->set_qos(factory_qos); - uint32_t domain_id = (uint32_t)GET_PID() % 230; - - // Create the remote participant and enable it - DomainParticipant* remote_participant = - DomainParticipantFactory::get_instance()->create_participant(domain_id, PARTICIPANT_QOS_DEFAULT); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, remote_participant->enable()); - EXPECT_TRUE(remote_participant->is_enabled()); - - // Create the local participant - DomainParticipant* participant = - DomainParticipantFactory::get_instance()->create_participant(domain_id, PARTICIPANT_QOS_DEFAULT); - - // Create the complete dynamic type builder - DynamicTypeBuilder_ptr int32_builder = DynamicTypeBuilderFactory::get_instance()->create_int32_builder(); - DynamicTypeBuilder_ptr seqLong_builder = - DynamicTypeBuilderFactory::get_instance()->create_sequence_builder(int32_builder.get()); - DynamicTypeBuilder_ptr mySequenceLong_builder = - DynamicTypeBuilderFactory::get_instance()->create_alias_builder(seqLong_builder.get(), "MySequenceLong"); - // Build the dynamic type - DynamicType_ptr dyn_type = mySequenceLong_builder->build(); - - // Register the type - TypeSupport type(new eprosima::fastrtps::types::DynamicPubSubType(dyn_type)); - type.register_type(remote_participant); - - // Retrieve the Typeidentifier, the type name and the TypeInformation from the TypeObjectFactory - const fastrtps::types::TypeIdentifier* identifier = - fastrtps::types::TypeObjectFactory::get_instance()->get_type_identifier_trying_complete( - type.get_type_name()); - - std::string type_name = fastrtps::types::TypeObjectFactory::get_instance()->get_type_name(identifier); - - const fastrtps::types::TypeInformation* type_information = - fastrtps::types::TypeObjectFactory::get_instance()->get_type_information(type_name); - - Topic* topic = remote_participant->create_topic("footopic", type.get_type_name(), TOPIC_QOS_DEFAULT); - ASSERT_NE(topic, nullptr); - - // Create the functor for the remote type registration - std::string topic_name = "footopic"; - std::function callback = - [topic_name](const std::string&, const fastrtps::types::DynamicType_ptr type) - { - std::cout << "Callback for type: " << type->get_name() << " on topic: " << topic_name << std::endl; - }; - - // Register the remote type in the disabled local participant. This should return a RETCODE_NOT_ENABLED return code - ASSERT_EQ(participant->register_remote_type(*type_information, type.get_type_name(), callback), - ReturnCode_t::RETCODE_NOT_ENABLED); - - // Enable the local participant - EXPECT_EQ(ReturnCode_t::RETCODE_OK, participant->enable()); - EXPECT_TRUE(participant->is_enabled()); - - // Register the remote type in the disabled local participant - ASSERT_EQ(participant->register_remote_type(*type_information, type_name, callback), - ReturnCode_t::RETCODE_OK); - - // Remove the topic and both participants - ASSERT_EQ(remote_participant->delete_topic(topic), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(remote_participant), - ReturnCode_t::RETCODE_OK); - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); -} - -/* - * This test create two participants which will share a minimal dynamic type. - * 1. The remote participant registers a dynamic type - * 2. The local participant register the dynamic type of the remote participant using the TypeInformation and the type - * name - * 3. Check that the type is not registered if the local participant is disabled - * 4. Check that the type is registered if the local participant is enabled - */ -TEST(ParticipantTests, RegisterRemoteTypeMinimal) -{ - // Do not enable entities on creation - DomainParticipantFactoryQos factory_qos; - factory_qos.entity_factory().autoenable_created_entities = false; - DomainParticipantFactory::get_instance()->set_qos(factory_qos); - uint32_t domain_id = (uint32_t)GET_PID() % 230; - - // Create the remote participant and enable it - DomainParticipant* remote_participant = - DomainParticipantFactory::get_instance()->create_participant(domain_id, PARTICIPANT_QOS_DEFAULT); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, remote_participant->enable()); - EXPECT_TRUE(remote_participant->is_enabled()); - - // Create the local participant - DomainParticipant* participant = - DomainParticipantFactory::get_instance()->create_participant(domain_id, PARTICIPANT_QOS_DEFAULT); - - // Create the minimal dynamic type builder - DynamicTypeBuilder_ptr builder = DynamicTypeBuilderFactory::get_instance()->create_char16_builder(); - // Build the dynamic type - DynamicType_ptr dyn_type = DynamicTypeBuilderFactory::get_instance()->create_type(builder.get()); - DynamicData_ptr data(DynamicDataFactory::get_instance()->create_data(dyn_type)); - data->set_string_value("Dynamic Char16"); - - // Register the type - TypeSupport type(new eprosima::fastrtps::types::DynamicPubSubType(dyn_type)); - type.register_type(remote_participant); - - // Retrieve the Typeidentifier, the type name and the TypeInformation from the TypeObjectFactory - const fastrtps::types::TypeIdentifier* identifier = - fastrtps::types::TypeObjectFactory::get_instance()->get_type_identifier_trying_complete( - type.get_type_name()); - - std::string type_name = fastrtps::types::TypeObjectFactory::get_instance()->get_type_name(identifier); - - const fastrtps::types::TypeInformation* type_information = - fastrtps::types::TypeObjectFactory::get_instance()->get_type_information(type_name); - - Topic* topic = remote_participant->create_topic("footopic", type.get_type_name(), TOPIC_QOS_DEFAULT); - ASSERT_NE(topic, nullptr); - - // Create the functor for the remote type registration - std::string topic_name = "footopic"; - std::function callback = - [topic_name](const std::string&, const fastrtps::types::DynamicType_ptr type) - { - std::cout << "Callback for type: " << type->get_name() << " on topic: " << topic_name << std::endl; - }; - - // Register the remote type in the disabled local participant. This should return a RETCODE_NOT_ENABLED return code - ASSERT_EQ(participant->register_remote_type(*type_information, type.get_type_name(), callback), - ReturnCode_t::RETCODE_NOT_ENABLED); - - // Enable the local participant - EXPECT_EQ(ReturnCode_t::RETCODE_OK, participant->enable()); - EXPECT_TRUE(participant->is_enabled()); - - // Register the remote type in the disabled local participant - ASSERT_EQ(participant->register_remote_type(*type_information, type_name, callback), - ReturnCode_t::RETCODE_OK); - - // Remove the topic and both participants - ASSERT_EQ(remote_participant->delete_topic(topic), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(remote_participant), - ReturnCode_t::RETCODE_OK); - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); -} - -/* - * This test checks that a RETCODE_PRECONDITION_NOT_MET error code is returned when registering a dynamic remote type - * with an empty TypeInformation - */ -TEST(ParticipantTests, RegisterRemoteTypePreconditionNotMet) -{ - uint32_t domain_id = (uint32_t)GET_PID() % 230; - - // Create the remote participant - DomainParticipant* remote_participant = - DomainParticipantFactory::get_instance()->create_participant(domain_id, PARTICIPANT_QOS_DEFAULT); - - // Create the local participant - DomainParticipant* participant = - DomainParticipantFactory::get_instance()->create_participant(domain_id, PARTICIPANT_QOS_DEFAULT); - - // Create the type builder - DynamicTypeBuilder_ptr int32_builder = DynamicTypeBuilderFactory::get_instance()->create_int32_builder(); - DynamicTypeBuilder_ptr seqLong_builder = - DynamicTypeBuilderFactory::get_instance()->create_sequence_builder(int32_builder.get()); - DynamicTypeBuilder_ptr mySequenceLong_builder = - DynamicTypeBuilderFactory::get_instance()->create_alias_builder(seqLong_builder.get(), "MySequenceLong"); - // Build the dynamic type - DynamicType_ptr dyn_type = mySequenceLong_builder->build(); - - // Register the type - TypeSupport type(new eprosima::fastrtps::types::DynamicPubSubType(dyn_type)); - type.register_type(remote_participant); - - Topic* topic = remote_participant->create_topic("footopic", type.get_type_name(), TOPIC_QOS_DEFAULT); - ASSERT_NE(topic, nullptr); - - // Create the functor for the remote type registration - std::string topic_name = "footopic"; - std::function callback = - [topic_name](const std::string&, const fastrtps::types::DynamicType_ptr type) - { - std::cout << "Callback for type: " << type->get_name() << " on topic: " << topic_name << std::endl; - }; - - // Create an empty TypeInformation - fastrtps::types::TypeInformation info = fastrtps::types::TypeInformation(); - // Check that register_remote_type() returns RETCODE_PRECONDITION_NOT_MET if the TypeInformation is empty - ASSERT_EQ(participant->register_remote_type(info, type.get_type_name(), callback), - ReturnCode_t::RETCODE_PRECONDITION_NOT_MET); - - // Remove the topic and both participants - ASSERT_EQ(remote_participant->delete_topic(topic), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(remote_participant), - ReturnCode_t::RETCODE_OK); - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), RETCODE_OK); } // Delete contained entities test @@ -3668,7 +3294,7 @@ TEST(ParticipantTests, DeleteContainedEntities) // Setup done, start the actual testing void* loan_data; - ASSERT_EQ(data_writer_foo->loan_sample(loan_data), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(data_writer_foo->loan_sample(loan_data), RETCODE_OK); // Writer with active loans. Fail and keep everything as is @@ -3679,7 +3305,7 @@ TEST(ParticipantTests, DeleteContainedEntities) EXPECT_EQ(data_writer_list.size(), 2u); subscriber->get_datareaders(data_reader_list); EXPECT_EQ(data_reader_list.size(), 1u); - ASSERT_EQ(retcode, ReturnCode_t::RETCODE_PRECONDITION_NOT_MET); + ASSERT_EQ(retcode, RETCODE_PRECONDITION_NOT_MET); data_writer_list.clear(); data_reader_list.clear(); @@ -3688,11 +3314,11 @@ TEST(ParticipantTests, DeleteContainedEntities) // Reader with active loans. Fail and keep everything as is - EXPECT_EQ(ReturnCode_t::RETCODE_OK, data_writer_bar->write(&data, HANDLE_NIL)); + EXPECT_EQ(RETCODE_OK, data_writer_bar->write(&data, HANDLE_NIL)); Duration_t wait_time(1, 0); EXPECT_TRUE(data_reader_bar->wait_for_unread_message(wait_time)); - ASSERT_EQ(data_reader_bar->take(mock_coll, mock_seq), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(data_reader_bar->take(mock_coll, mock_seq), RETCODE_OK); retcode = participant->delete_contained_entities(); @@ -3702,12 +3328,12 @@ TEST(ParticipantTests, DeleteContainedEntities) subscriber->get_datareaders(data_reader_list); EXPECT_EQ(data_reader_list.size(), 1u); - ASSERT_EQ(retcode, ReturnCode_t::RETCODE_PRECONDITION_NOT_MET); + ASSERT_EQ(retcode, RETCODE_PRECONDITION_NOT_MET); data_writer_list.clear(); data_reader_list.clear(); - ASSERT_EQ(data_reader_bar->return_loan(mock_coll, mock_seq), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(data_reader_bar->return_loan(mock_coll, mock_seq), RETCODE_OK); QueryCondition* query_condition = data_reader_bar->create_querycondition( mock_sample_state_kind, @@ -3729,7 +3355,7 @@ TEST(ParticipantTests, DeleteContainedEntities) // ContentFilteredTopic is not considered an entity EXPECT_EQ(participant->lookup_topicdescription("contentfilteredtopic"), nullptr); - ASSERT_EQ(retcode, ReturnCode_t::RETCODE_OK); + ASSERT_EQ(retcode, RETCODE_OK); } @@ -3770,11 +3396,11 @@ TEST(ParticipantTests, ContentFilterInterfaces) if (filter_parameters.length() == std::count(s.begin(), s.end(), '%')) { filter_instance = this; - return ReturnCode_t::RETCODE_OK; + return RETCODE_OK; } } - return ReturnCode_t::RETCODE_BAD_PARAMETER; + return RETCODE_BAD_PARAMETER; } virtual ReturnCode_t delete_content_filter( @@ -3783,10 +3409,10 @@ TEST(ParticipantTests, ContentFilterInterfaces) { if (this == filter_instance) { - return ReturnCode_t::RETCODE_OK; + return RETCODE_OK; } - return ReturnCode_t::RETCODE_BAD_PARAMETER; + return RETCODE_BAD_PARAMETER; } }; @@ -3805,8 +3431,8 @@ TEST(ParticipantTests, ContentFilterInterfaces) // Create a type and a topics TypeSupport type(new TopicDataTypeMock()); - ASSERT_EQ(type.register_type(participant), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(type.register_type(participant2), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(type.register_type(participant), RETCODE_OK); + ASSERT_EQ(type.register_type(participant2), RETCODE_OK); Topic* topic = participant->create_topic("topic", type.get_type_name(), TOPIC_QOS_DEFAULT); ASSERT_NE(topic, nullptr); @@ -3830,18 +3456,18 @@ TEST(ParticipantTests, ContentFilterInterfaces) EXPECT_EQ(nullptr, participant->create_contentfilteredtopic("contentfilteredtopic", topic, "", {}, nullptr)); - EXPECT_EQ(ReturnCode_t::RETCODE_BAD_PARAMETER, participant->delete_contentfilteredtopic(nullptr)); + EXPECT_EQ(RETCODE_BAD_PARAMETER, participant->delete_contentfilteredtopic(nullptr)); } // Negative tests for register_content_filter_factory { - EXPECT_EQ(ReturnCode_t::RETCODE_BAD_PARAMETER, + EXPECT_EQ(RETCODE_BAD_PARAMETER, participant->register_content_filter_factory(nullptr, &test_filter)); - EXPECT_EQ(ReturnCode_t::RETCODE_BAD_PARAMETER, + EXPECT_EQ(RETCODE_BAD_PARAMETER, participant->register_content_filter_factory(very_long_name.c_str(), &test_filter)); - EXPECT_EQ(ReturnCode_t::RETCODE_BAD_PARAMETER, + EXPECT_EQ(RETCODE_BAD_PARAMETER, participant->register_content_filter_factory(TEST_FILTER_CLASS, nullptr)); - EXPECT_EQ(ReturnCode_t::RETCODE_PRECONDITION_NOT_MET, + EXPECT_EQ(RETCODE_PRECONDITION_NOT_MET, participant->register_content_filter_factory(FASTDDS_SQLFILTER_NAME, &test_filter)); } @@ -3854,32 +3480,32 @@ TEST(ParticipantTests, ContentFilterInterfaces) // Negative tests for unregister_content_filter_factory { - EXPECT_EQ(ReturnCode_t::RETCODE_BAD_PARAMETER, participant->unregister_content_filter_factory(nullptr)); - EXPECT_EQ(ReturnCode_t::RETCODE_PRECONDITION_NOT_MET, + EXPECT_EQ(RETCODE_BAD_PARAMETER, participant->unregister_content_filter_factory(nullptr)); + EXPECT_EQ(RETCODE_PRECONDITION_NOT_MET, participant->unregister_content_filter_factory(FASTDDS_SQLFILTER_NAME)); - EXPECT_EQ(ReturnCode_t::RETCODE_PRECONDITION_NOT_MET, + EXPECT_EQ(RETCODE_PRECONDITION_NOT_MET, participant->unregister_content_filter_factory(TEST_FILTER_CLASS)); } // Custom filter factory registration { // Register filter factory - EXPECT_EQ(ReturnCode_t::RETCODE_OK, + EXPECT_EQ(RETCODE_OK, participant->register_content_filter_factory(TEST_FILTER_CLASS, &test_filter)); // Lookup should return same pointer as the one registered EXPECT_EQ(&test_filter, participant->lookup_content_filter_factory(TEST_FILTER_CLASS)); // But not for other filter class name EXPECT_EQ(nullptr, participant->lookup_content_filter_factory(OTHER_FILTER_CLASS)); // Should not be able to register twice - EXPECT_EQ(ReturnCode_t::RETCODE_PRECONDITION_NOT_MET, + EXPECT_EQ(RETCODE_PRECONDITION_NOT_MET, participant->register_content_filter_factory(TEST_FILTER_CLASS, &test_filter)); // Unregister filter factory - EXPECT_EQ(ReturnCode_t::RETCODE_OK, + EXPECT_EQ(RETCODE_OK, participant->unregister_content_filter_factory(TEST_FILTER_CLASS)); // Lookup should now return nullptr EXPECT_EQ(nullptr, participant->lookup_content_filter_factory(TEST_FILTER_CLASS)); // Unregister twice should fail - EXPECT_EQ(ReturnCode_t::RETCODE_PRECONDITION_NOT_MET, + EXPECT_EQ(RETCODE_PRECONDITION_NOT_MET, participant->unregister_content_filter_factory(TEST_FILTER_CLASS)); } @@ -3889,9 +3515,9 @@ TEST(ParticipantTests, ContentFilterInterfaces) participant->create_contentfilteredtopic("contentfilteredtopic", topic, "", {}, TEST_FILTER_CLASS)); // Register two filter factories to ensure traversal of collections - EXPECT_EQ(ReturnCode_t::RETCODE_OK, + EXPECT_EQ(RETCODE_OK, participant->register_content_filter_factory(TEST_FILTER_CLASS, &test_filter)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, + EXPECT_EQ(RETCODE_OK, participant->register_content_filter_factory(OTHER_FILTER_CLASS, &test_filter)); // Negative tests for custom filtered topic creation @@ -3923,12 +3549,12 @@ TEST(ParticipantTests, ContentFilterInterfaces) EXPECT_EQ(filtered_topic2, participant->lookup_topicdescription("contentfilteredtopic2")); // Should not be able to delete topic, since it is referenced by filtered_topic - EXPECT_EQ(ReturnCode_t::RETCODE_PRECONDITION_NOT_MET, participant->delete_topic(topic)); + EXPECT_EQ(RETCODE_PRECONDITION_NOT_MET, participant->delete_topic(topic)); // Should not be able to unregister filter factory, since it is referenced by filtered_topic - EXPECT_EQ(ReturnCode_t::RETCODE_PRECONDITION_NOT_MET, + EXPECT_EQ(RETCODE_PRECONDITION_NOT_MET, participant->unregister_content_filter_factory(TEST_FILTER_CLASS)); - EXPECT_EQ(ReturnCode_t::RETCODE_PRECONDITION_NOT_MET, + EXPECT_EQ(RETCODE_PRECONDITION_NOT_MET, participant->unregister_content_filter_factory(OTHER_FILTER_CLASS)); // Reference filtered_topic by creating a DataReader @@ -3938,31 +3564,31 @@ TEST(ParticipantTests, ContentFilterInterfaces) ASSERT_NE(nullptr, data_reader); // Should not be able to delete filtered_topic, since it is referenced by data_reader - EXPECT_EQ(ReturnCode_t::RETCODE_PRECONDITION_NOT_MET, participant->delete_contentfilteredtopic(filtered_topic)); + EXPECT_EQ(RETCODE_PRECONDITION_NOT_MET, participant->delete_contentfilteredtopic(filtered_topic)); EXPECT_EQ(filtered_topic, participant->lookup_topicdescription("contentfilteredtopic")); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, subscriber->delete_datareader(data_reader)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, participant->delete_subscriber(subscriber)); + EXPECT_EQ(RETCODE_OK, subscriber->delete_datareader(data_reader)); + EXPECT_EQ(RETCODE_OK, participant->delete_subscriber(subscriber)); // Should be able to delete filtered_topic, but only on correct participant - EXPECT_EQ(ReturnCode_t::RETCODE_PRECONDITION_NOT_MET, + EXPECT_EQ(RETCODE_PRECONDITION_NOT_MET, participant2->delete_contentfilteredtopic(filtered_topic)); EXPECT_EQ(filtered_topic, participant->lookup_topicdescription("contentfilteredtopic")); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, participant->delete_contentfilteredtopic(filtered_topic)); + EXPECT_EQ(RETCODE_OK, participant->delete_contentfilteredtopic(filtered_topic)); EXPECT_EQ(nullptr, participant->lookup_topicdescription("contentfilteredtopic")); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, participant->delete_contentfilteredtopic(filtered_topic2)); + EXPECT_EQ(RETCODE_OK, participant->delete_contentfilteredtopic(filtered_topic2)); // Unregister filter factories - EXPECT_EQ(ReturnCode_t::RETCODE_OK, + EXPECT_EQ(RETCODE_OK, participant->unregister_content_filter_factory(TEST_FILTER_CLASS)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, + EXPECT_EQ(RETCODE_OK, participant->unregister_content_filter_factory(OTHER_FILTER_CLASS)); } - ASSERT_EQ(participant2->delete_topic(topic2), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant2), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(participant->delete_topic(topic), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(participant2->delete_topic(topic2), RETCODE_OK); + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant2), RETCODE_OK); + ASSERT_EQ(participant->delete_topic(topic), RETCODE_OK); + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), RETCODE_OK); } /* @@ -3989,7 +3615,7 @@ TEST(ParticipantTests, UnsupportedMethods) // Create a type and a topic TypeSupport type(new TopicDataTypeMock()); - ASSERT_EQ(type.register_type(participant), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(type.register_type(participant), RETCODE_OK); Topic* topic = participant->create_topic("topic", type.get_type_name(), TOPIC_QOS_DEFAULT); ASSERT_NE(topic, nullptr); @@ -4003,29 +3629,29 @@ TEST(ParticipantTests, UnsupportedMethods) nullptr); // nullptr use as there are not such a class - ASSERT_EQ(participant->delete_multitopic(nullptr), ReturnCode_t::RETCODE_UNSUPPORTED); + ASSERT_EQ(participant->delete_multitopic(nullptr), RETCODE_UNSUPPORTED); ASSERT_EQ(participant->get_builtin_subscriber(), nullptr); - ASSERT_EQ(participant->ignore_topic(InstanceHandle_t()), ReturnCode_t::RETCODE_UNSUPPORTED); - ASSERT_EQ(participant->ignore_publication(InstanceHandle_t()), ReturnCode_t::RETCODE_UNSUPPORTED); - ASSERT_EQ(participant->ignore_subscription(InstanceHandle_t()), ReturnCode_t::RETCODE_UNSUPPORTED); + ASSERT_EQ(participant->ignore_topic(InstanceHandle_t()), RETCODE_UNSUPPORTED); + ASSERT_EQ(participant->ignore_publication(InstanceHandle_t()), RETCODE_UNSUPPORTED); + ASSERT_EQ(participant->ignore_subscription(InstanceHandle_t()), RETCODE_UNSUPPORTED); // Discovery methods std::vector handle_vector({InstanceHandle_t()}); builtin::ParticipantBuiltinTopicData pbtd; builtin::TopicBuiltinTopicData tbtd; - ASSERT_EQ(participant->get_discovered_participants(handle_vector), ReturnCode_t::RETCODE_UNSUPPORTED); + ASSERT_EQ(participant->get_discovered_participants(handle_vector), RETCODE_UNSUPPORTED); ASSERT_EQ( - participant->get_discovered_participant_data(pbtd, InstanceHandle_t()), ReturnCode_t::RETCODE_UNSUPPORTED); + participant->get_discovered_participant_data(pbtd, InstanceHandle_t()), RETCODE_UNSUPPORTED); - ASSERT_EQ(participant->get_discovered_topics(handle_vector), ReturnCode_t::RETCODE_UNSUPPORTED); + ASSERT_EQ(participant->get_discovered_topics(handle_vector), RETCODE_UNSUPPORTED); ASSERT_EQ( - participant->get_discovered_topic_data(tbtd, InstanceHandle_t()), ReturnCode_t::RETCODE_UNSUPPORTED); + participant->get_discovered_topic_data(tbtd, InstanceHandle_t()), RETCODE_UNSUPPORTED); - ASSERT_EQ(participant->delete_topic(topic), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(participant->delete_topic(topic), RETCODE_OK); + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), RETCODE_OK); } /* @@ -4051,15 +3677,15 @@ TEST(ParticipantTests, TwoParticipantWithSameFixedId) ASSERT_EQ(participant2, nullptr); // Destroy the first participant - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant1), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant1), RETCODE_OK); } // Test participants disabled from beginning { DomainParticipantFactoryQos factory_qos; - ASSERT_EQ(ReturnCode_t::RETCODE_OK, DomainParticipantFactory::get_instance()->get_qos(factory_qos)); + ASSERT_EQ(RETCODE_OK, DomainParticipantFactory::get_instance()->get_qos(factory_qos)); factory_qos.entity_factory().autoenable_created_entities = false; - ASSERT_EQ(ReturnCode_t::RETCODE_OK, DomainParticipantFactory::get_instance()->set_qos(factory_qos)); + ASSERT_EQ(RETCODE_OK, DomainParticipantFactory::get_instance()->set_qos(factory_qos)); DomainParticipantQos participant_qos; participant_qos.wire_protocol().participant_id = 1; @@ -4074,13 +3700,13 @@ TEST(ParticipantTests, TwoParticipantWithSameFixedId) DomainParticipantFactory::get_instance()->create_participant(0, participant_qos); ASSERT_EQ(participant2, nullptr); - ASSERT_EQ(ReturnCode_t::RETCODE_OK, participant1->enable()); + ASSERT_EQ(RETCODE_OK, participant1->enable()); // Destroy the first participant - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant1), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant1), RETCODE_OK); factory_qos.entity_factory().autoenable_created_entities = true; - ASSERT_EQ(ReturnCode_t::RETCODE_OK, DomainParticipantFactory::get_instance()->set_qos(factory_qos)); + ASSERT_EQ(RETCODE_OK, DomainParticipantFactory::get_instance()->set_qos(factory_qos)); } } @@ -4112,7 +3738,7 @@ TEST(ParticipantTests, ParticipantCreationWithBuiltinTransport) }; EXPECT_TRUE(transport_check(attributes_)); EXPECT_FALSE(attributes_.useBuiltinTransports); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, DomainParticipantFactory::get_instance()->delete_participant(participant_)); + EXPECT_EQ(RETCODE_OK, DomainParticipantFactory::get_instance()->delete_participant(participant_)); } { @@ -4140,7 +3766,7 @@ TEST(ParticipantTests, ParticipantCreationWithBuiltinTransport) }; EXPECT_TRUE(transport_check(attributes_)); EXPECT_FALSE(attributes_.useBuiltinTransports); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, DomainParticipantFactory::get_instance()->delete_participant(participant_)); + EXPECT_EQ(RETCODE_OK, DomainParticipantFactory::get_instance()->delete_participant(participant_)); } { @@ -4168,7 +3794,7 @@ TEST(ParticipantTests, ParticipantCreationWithBuiltinTransport) }; EXPECT_TRUE(transport_check(attributes_)); EXPECT_FALSE(attributes_.useBuiltinTransports); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, DomainParticipantFactory::get_instance()->delete_participant(participant_)); + EXPECT_EQ(RETCODE_OK, DomainParticipantFactory::get_instance()->delete_participant(participant_)); } { @@ -4196,7 +3822,7 @@ TEST(ParticipantTests, ParticipantCreationWithBuiltinTransport) }; EXPECT_TRUE(transport_check(attributes_)); EXPECT_FALSE(attributes_.useBuiltinTransports); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, DomainParticipantFactory::get_instance()->delete_participant(participant_)); + EXPECT_EQ(RETCODE_OK, DomainParticipantFactory::get_instance()->delete_participant(participant_)); } { @@ -4224,7 +3850,7 @@ TEST(ParticipantTests, ParticipantCreationWithBuiltinTransport) }; EXPECT_TRUE(transport_check(attributes_)); EXPECT_FALSE(attributes_.useBuiltinTransports); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, DomainParticipantFactory::get_instance()->delete_participant(participant_)); + EXPECT_EQ(RETCODE_OK, DomainParticipantFactory::get_instance()->delete_participant(participant_)); } { @@ -4266,7 +3892,7 @@ TEST(ParticipantTests, ParticipantCreationWithBuiltinTransport) }; EXPECT_TRUE(transport_check(attributes_)); EXPECT_FALSE(attributes_.useBuiltinTransports); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, DomainParticipantFactory::get_instance()->delete_participant(participant_)); + EXPECT_EQ(RETCODE_OK, DomainParticipantFactory::get_instance()->delete_participant(participant_)); } { @@ -4308,7 +3934,7 @@ TEST(ParticipantTests, ParticipantCreationWithBuiltinTransport) }; EXPECT_TRUE(transport_check(attributes_)); EXPECT_FALSE(attributes_.useBuiltinTransports); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, DomainParticipantFactory::get_instance()->delete_participant(participant_)); + EXPECT_EQ(RETCODE_OK, DomainParticipantFactory::get_instance()->delete_participant(participant_)); } } @@ -4331,7 +3957,7 @@ class BuiltinTransportsOptionsTest get_rtps_attributes(participant_, attr); EXPECT_TRUE(check_options_attr(attr, options)); EXPECT_EQ(attr.userTransports.size(), 3u); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, DomainParticipantFactory::get_instance()->delete_participant(participant_)); + EXPECT_EQ(RETCODE_OK, DomainParticipantFactory::get_instance()->delete_participant(participant_)); } static void test_default_correct_participant_with_env( @@ -4365,7 +3991,7 @@ class BuiltinTransportsOptionsTest } EXPECT_TRUE(udp_ok); EXPECT_EQ(attr.userTransports.size(), 2u); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, DomainParticipantFactory::get_instance()->delete_participant(participant_)); + EXPECT_EQ(RETCODE_OK, DomainParticipantFactory::get_instance()->delete_participant(participant_)); } static void test_wrong_participant_with_env( @@ -4381,7 +4007,7 @@ class BuiltinTransportsOptionsTest fastrtps::rtps::RTPSParticipantAttributes attr; get_rtps_attributes(participant_, attr); EXPECT_TRUE(check_default_participant(attr)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, DomainParticipantFactory::get_instance()->delete_participant(participant_)); + EXPECT_EQ(RETCODE_OK, DomainParticipantFactory::get_instance()->delete_participant(participant_)); } static void apply_option_to_env( @@ -4535,7 +4161,7 @@ TEST(ParticipantTests, ParticipantCreationWithLargeDataOptionsThroughAPI) EXPECT_TRUE(BuiltinTransportsOptionsTest::check_options_attr(attr, options)); EXPECT_EQ(attr.userTransports.size(), 3u); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, DomainParticipantFactory::get_instance()->delete_participant(participant_)); + EXPECT_EQ(RETCODE_OK, DomainParticipantFactory::get_instance()->delete_participant(participant_)); } TEST(ParticipantTests, ParticipantCreationWithLargeDataOptionsThroughEnvVar) diff --git a/test/unittest/dds/profiles/test_xml_for_string_profile.xml b/test/unittest/dds/profiles/test_xml_for_string_profile.xml index 0f25801a726..b82c883fcaa 100644 --- a/test/unittest/dds/profiles/test_xml_for_string_profile.xml +++ b/test/unittest/dds/profiles/test_xml_for_string_profile.xml @@ -1,5 +1,5 @@ - + FULL @@ -138,6 +138,10 @@ 15 1048576 + + 15 + 1048576 + 15 1048576 @@ -283,6 +287,10 @@ 15 1048576 + + 15 + 1048576 + 15 1048576 diff --git a/test/unittest/dds/profiles/test_xml_profile.xml b/test/unittest/dds/profiles/test_xml_profile.xml index 791c89cc146..3d8c3604ed8 100644 --- a/test/unittest/dds/profiles/test_xml_profile.xml +++ b/test/unittest/dds/profiles/test_xml_profile.xml @@ -1,5 +1,5 @@ - + 123 @@ -135,6 +135,10 @@ 15 1048576 + + 15 + 1048576 + 15 1048576 @@ -280,6 +284,10 @@ 15 1048576 + + 15 + 1048576 + 15 1048576 @@ -699,6 +707,50 @@ 50 + + + request_topic_name + reply_topic_name + + + + MANUAL_BY_TOPIC + + + + + + + MANUAL_BY_TOPIC + + + + + + + request_topic_name + reply_topic_name + + + + MANUAL_BY_TOPIC + + + + + + + MANUAL_BY_TOPIC + + + + FULL diff --git a/test/unittest/dds/publisher/CMakeLists.txt b/test/unittest/dds/publisher/CMakeLists.txt index 72e1e505d3f..cd3f207bfb5 100644 --- a/test/unittest/dds/publisher/CMakeLists.txt +++ b/test/unittest/dds/publisher/CMakeLists.txt @@ -32,32 +32,11 @@ set(sqlite3_source_files set(DATAWRITERTESTS_SOURCE DataWriterTests.cpp ${DDSSQLFILTER_SOURCES} - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/AnnotationDescriptor.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/AnnotationParameterValue.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/BuiltinAnnotationsTypeObject.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicData.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicDataFactory.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicPubSubType.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicType.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeBuilder.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeBuilderFactory.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeBuilderPtr.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeMember.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypePtr.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/MemberDescriptor.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeDescriptor.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeIdentifier.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeIdentifierTypes.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeNamesGenerator.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeObject.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeObjectFactory.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeObjectHashId.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypesBase.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/builtin/common/RPCHeadersImpl.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/builtin/typelookup/common/TypeLookupTypes.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/builtin/typelookup/TypeLookupManager.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/builtin/typelookup/TypeLookupReplyListener.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/builtin/typelookup/TypeLookupRequestListener.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/builtin/type_lookup_service/detail/rpc_typesPubSubTypes.cxx + ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/builtin/type_lookup_service/detail/TypeLookupTypesPubSubTypes.cxx + ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/builtin/type_lookup_service/TypeLookupManager.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/builtin/type_lookup_service/TypeLookupReplyListener.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/builtin/type_lookup_service/TypeLookupRequestListener.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/core/condition/Condition.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/core/condition/ConditionNotifier.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/core/condition/StatusCondition.cpp @@ -71,11 +50,6 @@ set(DATAWRITERTESTS_SOURCE DataWriterTests.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/domain/DomainParticipantImpl.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/domain/qos/DomainParticipantFactoryQos.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/domain/qos/DomainParticipantQos.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/FileConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/Log.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/OStreamConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutErrConsumer.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/publisher/DataWriter.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/publisher/DataWriterImpl.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/publisher/Publisher.cpp @@ -200,12 +174,6 @@ set(DATAWRITERTESTS_SOURCE DataWriterTests.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/writer/StatefulWriter.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/writer/StatelessPersistentWriter.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/writer/StatelessWriter.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/xmlparser/XMLDynamicParser.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/xmlparser/XMLElementParser.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/xmlparser/XMLEndpointParser.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/xmlparser/XMLParser.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/xmlparser/XMLParserCommon.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/xmlparser/XMLProfileManager.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/IPFinder.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/IPLocator.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/md5.cpp @@ -214,6 +182,12 @@ set(DATAWRITERTESTS_SOURCE DataWriterTests.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/SystemInfo.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/TimedConditionVariable.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/UnitsParser.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/xmlparser/XMLDynamicParser.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/xmlparser/XMLElementParser.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/xmlparser/XMLEndpointParser.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/xmlparser/XMLParser.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/xmlparser/XMLParserCommon.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/xmlparser/XMLProfileManager.cpp ) if(SQLITE3_SUPPORT) @@ -235,12 +209,10 @@ set(DATAWRITERTESTS_SOURCE DataWriterTests.cpp ${PROJECT_SOURCE_DIR}/src/cpp/statistics/rtps/monitor-service/MonitorServiceListener.cpp ${PROJECT_SOURCE_DIR}/src/cpp/statistics/rtps/reader/StatisticsReaderImpl.cpp ${PROJECT_SOURCE_DIR}/src/cpp/statistics/rtps/writer/StatisticsWriterImpl.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/types.cxx - ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/typesv1.cxx - ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/typesPubSubTypes.cxx ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/monitorservice_typesPubSubTypes.cxx - ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/monitorservice_types.cxx - ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/monitorservice_typesv1.cxx + ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/monitorservice_typesTypeObjectSupport.cxx + ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/typesPubSubTypes.cxx + ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/typesTypeObjectSupport.cxx ) list(APPEND DATAWRITERTESTS_SOURCE ${statistics_sources}) @@ -307,7 +279,6 @@ set(DATAWRITERTESTS_SOURCE DataWriterTests.cpp endif(TINYXML2_INCLUDE_DIR) set(PUBLISHERTESTS_SOURCE PublisherTests.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dds/pub/DataWriter.cpp ) if(WIN32) @@ -342,7 +313,7 @@ target_include_directories(PublisherTests PRIVATE ${PROJECT_SOURCE_DIR}/src/cpp ${PROJECT_SOURCE_DIR}/thirdparty/taocpp-pegtl ) -target_link_libraries(PublisherTests fastrtps fastcdr foonathan_memory +target_link_libraries(PublisherTests fastdds fastcdr foonathan_memory GTest::gmock ${CMAKE_DL_LIBS}) if(QNX) @@ -369,14 +340,19 @@ target_compile_definitions(DataWriterTests PRIVATE ) target_include_directories(DataWriterTests PRIVATE $<$:${OPENSSL_INCLUDE_DIR}> - ${PROJECT_SOURCE_DIR}/test/mock/rtps/PublisherHistory + ${PROJECT_SOURCE_DIR}/test/mock/dds/DataWriterHistory ${PROJECT_SOURCE_DIR}/include ${PROJECT_BINARY_DIR}/include ${Asio_INCLUDE_DIR} ${PROJECT_SOURCE_DIR}/src/cpp ${THIRDPARTY_BOOST_INCLUDE_DIR} ${PROJECT_SOURCE_DIR}/thirdparty/taocpp-pegtl ) -target_link_libraries(DataWriterTests fastcdr foonathan_memory +target_link_libraries(DataWriterTests + fastcdr + fastdds::log + fastdds::xtypes::dynamic-types::impl + fastdds::xtypes::type-representation + foonathan_memory GTest::gmock ${CMAKE_DL_LIBS} ${TINYXML2_LIBRARY} diff --git a/test/unittest/dds/publisher/DataWriterTests.cpp b/test/unittest/dds/publisher/DataWriterTests.cpp index 529a46ca80d..04773355cba 100644 --- a/test/unittest/dds/publisher/DataWriterTests.cpp +++ b/test/unittest/dds/publisher/DataWriterTests.cpp @@ -22,10 +22,6 @@ #include #include -#include -#include -#include -#include #include #include #include @@ -40,10 +36,11 @@ #include #include #include -#include #include #include +#include + #include "../../common/CustomPayloadPool.hpp" #include "../../logging/mock/MockConsumer.h" @@ -360,10 +357,10 @@ TEST(DataWriterTests, get_type) ASSERT_EQ(type, datawriter->get_type()); - ASSERT_TRUE(publisher->delete_datawriter(datawriter) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(participant->delete_topic(topic) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(participant->delete_publisher(publisher) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(publisher->delete_datawriter(datawriter) == RETCODE_OK); + ASSERT_TRUE(participant->delete_topic(topic) == RETCODE_OK); + ASSERT_TRUE(participant->delete_publisher(publisher) == RETCODE_OK); + ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == RETCODE_OK); } /*! @@ -375,9 +372,10 @@ TEST(DataWriterTests, get_guid) { public: - void on_publisher_discovery( + void on_data_writer_discovery( DomainParticipant*, - fastrtps::rtps::WriterDiscoveryInfo&& info) + fastrtps::rtps::WriterDiscoveryInfo&& info, + bool& /*should_be_ignored*/) override { std::unique_lock lock(mutex); if (fastrtps::rtps::WriterDiscoveryInfo::DISCOVERED_WRITER == info.status) @@ -393,7 +391,7 @@ TEST(DataWriterTests, get_guid) private: - using DomainParticipantListener::on_publisher_discovery; + using DomainParticipantListener::on_data_writer_discovery; } discovery_listener; @@ -444,12 +442,12 @@ TEST(DataWriterTests, get_guid) } ASSERT_EQ(guid, discovery_listener.guid); - ASSERT_TRUE(publisher->delete_datawriter(datawriter) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(participant->delete_topic(topic) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(participant->delete_publisher(publisher) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(publisher->delete_datawriter(datawriter) == RETCODE_OK); + ASSERT_TRUE(participant->delete_topic(topic) == RETCODE_OK); + ASSERT_TRUE(participant->delete_publisher(publisher) == RETCODE_OK); + ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == RETCODE_OK); ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant( - listener_participant) == ReturnCode_t::RETCODE_OK); + listener_participant) == RETCODE_OK); } TEST(DataWriterTests, ChangeDataWriterQos) @@ -476,17 +474,17 @@ TEST(DataWriterTests, ChangeDataWriterQos) qos.deadline().period = 260; - ASSERT_TRUE(datawriter->set_qos(qos) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(datawriter->set_qos(qos) == RETCODE_OK); DataWriterQos wqos; datawriter->get_qos(wqos); ASSERT_EQ(qos, wqos); ASSERT_EQ(wqos.deadline().period, 260); - ASSERT_TRUE(publisher->delete_datawriter(datawriter) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(participant->delete_topic(topic) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(participant->delete_publisher(publisher) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(publisher->delete_datawriter(datawriter) == RETCODE_OK); + ASSERT_TRUE(participant->delete_topic(topic) == RETCODE_OK); + ASSERT_TRUE(participant->delete_publisher(publisher) == RETCODE_OK); + ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == RETCODE_OK); } TEST(DataWriterTests, ChangeImmutableDataWriterQos) @@ -517,29 +515,29 @@ TEST(DataWriterTests, ChangeImmutableDataWriterQos) qos.reliable_writer_qos().disable_positive_acks.enabled = true; - ASSERT_TRUE(datawriter->set_qos(qos) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(datawriter->set_qos(qos) == RETCODE_OK); DataWriterQos wqos; datawriter->get_qos(wqos); ASSERT_EQ(qos, wqos); ASSERT_TRUE(wqos.reliable_writer_qos().disable_positive_acks.enabled); - ASSERT_TRUE(datawriter->enable() == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(datawriter->enable() == RETCODE_OK); ASSERT_TRUE(datawriter->is_enabled()); qos.reliable_writer_qos().disable_positive_acks.enabled = false; ASSERT_FALSE(qos == wqos); - ASSERT_TRUE(datawriter->set_qos(qos) == ReturnCode_t::RETCODE_IMMUTABLE_POLICY); + ASSERT_TRUE(datawriter->set_qos(qos) == RETCODE_IMMUTABLE_POLICY); DataWriterQos wqos2; datawriter->get_qos(wqos2); ASSERT_EQ(wqos, wqos2); ASSERT_TRUE(wqos2.reliable_writer_qos().disable_positive_acks.enabled); - ASSERT_TRUE(publisher->delete_datawriter(datawriter) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(participant->delete_topic(topic) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(participant->delete_publisher(publisher) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(publisher->delete_datawriter(datawriter) == RETCODE_OK); + ASSERT_TRUE(participant->delete_topic(topic) == RETCODE_OK); + ASSERT_TRUE(participant->delete_publisher(publisher) == RETCODE_OK); + ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == RETCODE_OK); } TEST(DataWriterTests, ForcedDataSharing) @@ -572,12 +570,12 @@ TEST(DataWriterTests, ForcedDataSharing) qos.endpoint().history_memory_policy = fastrtps::rtps::PREALLOCATED_MEMORY_MODE; datawriter = publisher->create_datawriter(topic, qos); ASSERT_NE(datawriter, nullptr); - ASSERT_EQ(publisher->delete_datawriter(datawriter), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(publisher->delete_datawriter(datawriter), RETCODE_OK); // DataSharing automatic, bounded topic data type datawriter = publisher->create_datawriter(bounded_topic, qos); ASSERT_NE(datawriter, nullptr); - ASSERT_EQ(publisher->delete_datawriter(datawriter), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(publisher->delete_datawriter(datawriter), RETCODE_OK); // DataSharing enabled, unbounded topic data type qos = DATAWRITER_QOS_DEFAULT; @@ -589,7 +587,7 @@ TEST(DataWriterTests, ForcedDataSharing) // DataSharing enabled, bounded topic data type datawriter = publisher->create_datawriter(bounded_topic, qos); ASSERT_NE(datawriter, nullptr); - ASSERT_EQ(publisher->delete_datawriter(datawriter), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(publisher->delete_datawriter(datawriter), RETCODE_OK); // DataSharing enabled, bounded topic data type, Dynamic memory policy qos = DATAWRITER_QOS_DEFAULT; @@ -598,10 +596,10 @@ TEST(DataWriterTests, ForcedDataSharing) datawriter = publisher->create_datawriter(bounded_topic, qos); ASSERT_EQ(datawriter, nullptr); - ASSERT_EQ(participant->delete_topic(topic), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(participant->delete_topic(bounded_topic), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(participant->delete_publisher(publisher), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(participant->delete_topic(topic), RETCODE_OK); + ASSERT_EQ(participant->delete_topic(bounded_topic), RETCODE_OK); + ASSERT_EQ(participant->delete_publisher(publisher), RETCODE_OK); + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), RETCODE_OK); // DataSharing forced, bounded topic data type, security enabled @@ -650,9 +648,9 @@ TEST(DataWriterTests, ForcedDataSharing) datawriter = publisher->create_datawriter(bounded_topic, qos); ASSERT_EQ(datawriter, nullptr); - ASSERT_EQ(participant->delete_topic(bounded_topic), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(participant->delete_publisher(publisher), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(participant->delete_topic(bounded_topic), RETCODE_OK); + ASSERT_EQ(participant->delete_publisher(publisher), RETCODE_OK); + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), RETCODE_OK); #endif // HAS_SECURITY } @@ -676,7 +674,7 @@ TEST(DataWriterTests, InvalidQos) ASSERT_NE(datawriter, nullptr); /* Unsupported QoS */ - const ReturnCode_t unsupported_code = ReturnCode_t::RETCODE_UNSUPPORTED; + const ReturnCode_t unsupported_code = RETCODE_UNSUPPORTED; DataWriterQos qos; qos = DATAWRITER_QOS_DEFAULT; @@ -692,7 +690,7 @@ TEST(DataWriterTests, InvalidQos) EXPECT_EQ(unsupported_code, datawriter->set_qos(qos)); /* Inconsistent QoS */ - const ReturnCode_t inconsistent_code = ReturnCode_t::RETCODE_INCONSISTENT_POLICY; + const ReturnCode_t inconsistent_code = RETCODE_INCONSISTENT_POLICY; qos = DATAWRITER_QOS_DEFAULT; qos.properties().properties().emplace_back("fastdds.push_mode", "false"); @@ -721,26 +719,26 @@ TEST(DataWriterTests, InvalidQos) EXPECT_EQ(inconsistent_code, datawriter->set_qos(qos)); qos.endpoint().history_memory_policy = eprosima::fastrtps::rtps::PREALLOCATED_MEMORY_MODE; - EXPECT_EQ(ReturnCode_t::RETCODE_OK, datawriter->set_qos(qos)); + EXPECT_EQ(RETCODE_OK, datawriter->set_qos(qos)); qos.endpoint().history_memory_policy = eprosima::fastrtps::rtps::PREALLOCATED_WITH_REALLOC_MEMORY_MODE; - EXPECT_EQ(ReturnCode_t::RETCODE_OK, datawriter->set_qos(qos)); + EXPECT_EQ(RETCODE_OK, datawriter->set_qos(qos)); qos = DATAWRITER_QOS_DEFAULT; qos.history().kind = KEEP_LAST_HISTORY_QOS; qos.history().depth = 0; EXPECT_EQ(inconsistent_code, datawriter->set_qos(qos)); // KEEP LAST 0 is inconsistent qos.history().depth = 2; - EXPECT_EQ(ReturnCode_t::RETCODE_OK, datawriter->set_qos(qos)); // KEEP LAST 2 is OK + EXPECT_EQ(RETCODE_OK, datawriter->set_qos(qos)); // KEEP LAST 2 is OK // KEEP LAST 2000 but max_samples_per_instance default (400) is inconsistent but right now it only shows a warning // This test will fail whenever we enforce the consistency between depth and max_samples_per_instance. qos.history().depth = 2000; - EXPECT_EQ(ReturnCode_t::RETCODE_OK, datawriter->set_qos(qos)); + EXPECT_EQ(RETCODE_OK, datawriter->set_qos(qos)); - ASSERT_TRUE(publisher->delete_datawriter(datawriter) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(participant->delete_topic(topic) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(participant->delete_publisher(publisher) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(publisher->delete_datawriter(datawriter) == RETCODE_OK); + ASSERT_TRUE(participant->delete_topic(topic) == RETCODE_OK); + ASSERT_TRUE(participant->delete_publisher(publisher) == RETCODE_OK); + ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == RETCODE_OK); } //TODO: Activate the test once PSM API for DataWriter is in place @@ -783,15 +781,15 @@ TEST(DataWriterTests, Write) FooType data; data.message("HelloWorld"); - ASSERT_FALSE(datawriter->write(nullptr, HANDLE_NIL) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(datawriter->write(&data, HANDLE_NIL) == ReturnCode_t::RETCODE_OK); + ASSERT_FALSE(datawriter->write(nullptr, HANDLE_NIL) == RETCODE_OK); + ASSERT_TRUE(datawriter->write(&data, HANDLE_NIL) == RETCODE_OK); ASSERT_TRUE(datawriter->write(&data, participant->get_instance_handle()) == - ReturnCode_t::RETCODE_PRECONDITION_NOT_MET); + RETCODE_PRECONDITION_NOT_MET); - ASSERT_TRUE(publisher->delete_datawriter(datawriter) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(participant->delete_topic(topic) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(participant->delete_publisher(publisher) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(publisher->delete_datawriter(datawriter) == RETCODE_OK); + ASSERT_TRUE(participant->delete_topic(topic) == RETCODE_OK); + ASSERT_TRUE(participant->delete_publisher(publisher) == RETCODE_OK); + ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == RETCODE_OK); } TEST(DataWriterTests, WriteWithTimestamp) @@ -818,22 +816,22 @@ TEST(DataWriterTests, WriteWithTimestamp) data.message("HelloWorld"); // 1. Calling write with nullptr data returns RETCODE_BAD_PARAMETER - ASSERT_EQ(ReturnCode_t::RETCODE_BAD_PARAMETER, datawriter->write_w_timestamp(nullptr, HANDLE_NIL, ts)); + ASSERT_EQ(RETCODE_BAD_PARAMETER, datawriter->write_w_timestamp(nullptr, HANDLE_NIL, ts)); // 2. Calling write with an invalid timestamps returns RETCODE_BAD_PARAMETER - EXPECT_EQ(ReturnCode_t::RETCODE_BAD_PARAMETER, + EXPECT_EQ(RETCODE_BAD_PARAMETER, datawriter->write_w_timestamp(&data, HANDLE_NIL, fastrtps::c_TimeInfinite)); - EXPECT_EQ(ReturnCode_t::RETCODE_BAD_PARAMETER, + EXPECT_EQ(RETCODE_BAD_PARAMETER, datawriter->write_w_timestamp(&data, HANDLE_NIL, fastrtps::c_TimeInvalid)); // 3. Calling write with a wrong instance handle returns RETCODE_PRECONDITION_NOT_MET - ASSERT_EQ(ReturnCode_t::RETCODE_PRECONDITION_NOT_MET, + ASSERT_EQ(RETCODE_PRECONDITION_NOT_MET, datawriter->write_w_timestamp(&data, participant->get_instance_handle(), ts)); // 4. Correct case - ASSERT_EQ(ReturnCode_t::RETCODE_OK, datawriter->write_w_timestamp(&data, HANDLE_NIL, ts)); + ASSERT_EQ(RETCODE_OK, datawriter->write_w_timestamp(&data, HANDLE_NIL, ts)); - ASSERT_TRUE(publisher->delete_datawriter(datawriter) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(participant->delete_topic(topic) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(participant->delete_publisher(publisher) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(publisher->delete_datawriter(datawriter) == RETCODE_OK); + ASSERT_TRUE(participant->delete_topic(topic) == RETCODE_OK); + ASSERT_TRUE(participant->delete_publisher(publisher) == RETCODE_OK); + ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == RETCODE_OK); } void set_listener_test ( @@ -841,7 +839,7 @@ void set_listener_test ( DataWriterListener* listener, StatusMask mask) { - ASSERT_EQ(writer->set_listener(listener, mask), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(writer->set_listener(listener, mask), RETCODE_OK); ASSERT_EQ(writer->get_status_mask(), mask); } @@ -894,10 +892,10 @@ TEST(DataWriterTests, SetListener) std::get<2>(testing_case)); } - ASSERT_TRUE(publisher->delete_datawriter(datawriter) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(participant->delete_topic(topic) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(participant->delete_publisher(publisher) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(publisher->delete_datawriter(datawriter) == RETCODE_OK); + ASSERT_TRUE(participant->delete_topic(topic) == RETCODE_OK); + ASSERT_TRUE(participant->delete_publisher(publisher) == RETCODE_OK); + ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == RETCODE_OK); } TEST(DataWriterTests, TerminateWithoutDestroyingWriter) @@ -985,11 +983,11 @@ TEST(DataWriterTests, RegisterInstance) EXPECT_EQ(HANDLE_NIL, instance_datawriter->register_instance(&data)); // 2. Calling register_instance in a non keyed topic returns HANDLE_NIL - ASSERT_EQ(ReturnCode_t::RETCODE_OK, datawriter->enable()); + ASSERT_EQ(RETCODE_OK, datawriter->enable()); EXPECT_EQ(HANDLE_NIL, datawriter->register_instance(&data)); // 3. Calling register_instance with an invalid sample returns HANDLE_NIL - ASSERT_EQ(ReturnCode_t::RETCODE_OK, instance_datawriter->enable()); + ASSERT_EQ(RETCODE_OK, instance_datawriter->enable()); EXPECT_EQ(HANDLE_NIL, instance_datawriter->register_instance(nullptr)); // 4. Calling register_instance with a valid key returns a valid handle @@ -1017,11 +1015,11 @@ TEST(DataWriterTests, RegisterInstanceWithTimestamp) EXPECT_EQ(HANDLE_NIL, instance_datawriter->register_instance_w_timestamp(&data, ts)); // 2. Calling register_instance_w_timestamp in a non keyed topic returns HANDLE_NIL - ASSERT_EQ(ReturnCode_t::RETCODE_OK, datawriter->enable()); + ASSERT_EQ(RETCODE_OK, datawriter->enable()); EXPECT_EQ(HANDLE_NIL, datawriter->register_instance_w_timestamp(&data, ts)); // 3. Calling register_instance with an invalid sample returns HANDLE_NIL - ASSERT_EQ(ReturnCode_t::RETCODE_OK, instance_datawriter->enable()); + ASSERT_EQ(RETCODE_OK, instance_datawriter->enable()); EXPECT_EQ(HANDLE_NIL, instance_datawriter->register_instance_w_timestamp(nullptr, ts)); // 4. Calling register_instance with an invalid timestamps returns HANDLE_NIL @@ -1049,34 +1047,34 @@ TEST(DataWriterTests, UnregisterInstance) create_writers_for_instance_test(datawriter, instance_datawriter, &instance_type); // 1. Calling unregister_instance in a disable writer returns RETCODE_NOT_ENABLED - EXPECT_EQ(ReturnCode_t::RETCODE_NOT_ENABLED, datawriter->unregister_instance(&data, handle)); + EXPECT_EQ(RETCODE_NOT_ENABLED, datawriter->unregister_instance(&data, handle)); // 2. Calling unregister_instance in a non keyed topic returns RETCODE_PRECONDITION_NOT MET - ASSERT_EQ(ReturnCode_t::RETCODE_OK, datawriter->enable()); - EXPECT_EQ(ReturnCode_t::RETCODE_PRECONDITION_NOT_MET, datawriter->unregister_instance(&data, handle)); + ASSERT_EQ(RETCODE_OK, datawriter->enable()); + EXPECT_EQ(RETCODE_PRECONDITION_NOT_MET, datawriter->unregister_instance(&data, handle)); // 3. Calling unregister_instance with an invalid sample returns RETCODE_BAD_PARAMETER - ASSERT_EQ(ReturnCode_t::RETCODE_OK, instance_datawriter->enable()); - EXPECT_EQ(ReturnCode_t::RETCODE_BAD_PARAMETER, instance_datawriter->unregister_instance(nullptr, handle)); + ASSERT_EQ(RETCODE_OK, instance_datawriter->enable()); + EXPECT_EQ(RETCODE_BAD_PARAMETER, instance_datawriter->unregister_instance(nullptr, handle)); #if !defined(NDEBUG) // 4. Calling unregister_instance with an inconsistent handle returns RETCODE_PRECONDITION_NOT_MET - EXPECT_EQ(ReturnCode_t::RETCODE_PRECONDITION_NOT_MET, instance_datawriter->unregister_instance(&data, + EXPECT_EQ(RETCODE_PRECONDITION_NOT_MET, instance_datawriter->unregister_instance(&data, datawriter->get_instance_handle())); #endif // NDEBUG // 5. Calling unregister_instance with a key not yet registered returns RETCODE_PRECONDITION_NOT_MET - EXPECT_EQ(ReturnCode_t::RETCODE_PRECONDITION_NOT_MET, instance_datawriter->unregister_instance(&data, handle)); + EXPECT_EQ(RETCODE_PRECONDITION_NOT_MET, instance_datawriter->unregister_instance(&data, handle)); // 6. Calling unregister_instance with a valid key returns RETCODE_OK - ASSERT_EQ(ReturnCode_t::RETCODE_OK, instance_datawriter->write(&data, HANDLE_NIL)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, instance_datawriter->unregister_instance(&data, handle)); + ASSERT_EQ(RETCODE_OK, instance_datawriter->write(&data, HANDLE_NIL)); + EXPECT_EQ(RETCODE_OK, instance_datawriter->unregister_instance(&data, handle)); // 7. Calling unregister_instance with a valid InstanceHandle also returns RETCODE_OK data.message("HelloWorld_1"); - ASSERT_EQ(ReturnCode_t::RETCODE_OK, instance_datawriter->write(&data, HANDLE_NIL)); + ASSERT_EQ(RETCODE_OK, instance_datawriter->write(&data, HANDLE_NIL)); instance_type.get_key(&data, &handle); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, instance_datawriter->unregister_instance(&data, handle)); + EXPECT_EQ(RETCODE_OK, instance_datawriter->unregister_instance(&data, handle)); // TODO(jlbueno) There are other possible errors sending the unregister message: RETCODE_OUT_OF_RESOURCES, // RETCODE_ERROR, and RETCODE_TIMEOUT (only if HAVE_STRICT_REALTIME has been defined). @@ -1101,45 +1099,45 @@ TEST(DataWriterTests, UnregisterInstanceWithTimestamp) eprosima::fastrtps::Time_t ts{ 0, 1 }; // 1. Calling unregister_instance in a disable writer returns RETCODE_NOT_ENABLED - EXPECT_EQ(ReturnCode_t::RETCODE_NOT_ENABLED, datawriter->unregister_instance_w_timestamp(&data, handle, ts)); + EXPECT_EQ(RETCODE_NOT_ENABLED, datawriter->unregister_instance_w_timestamp(&data, handle, ts)); // 2. Calling unregister_instance in a non keyed topic returns RETCODE_PRECONDITION_NOT MET - ASSERT_EQ(ReturnCode_t::RETCODE_OK, datawriter->enable()); - EXPECT_EQ(ReturnCode_t::RETCODE_PRECONDITION_NOT_MET, + ASSERT_EQ(RETCODE_OK, datawriter->enable()); + EXPECT_EQ(RETCODE_PRECONDITION_NOT_MET, datawriter->unregister_instance_w_timestamp(&data, handle, ts)); // 3. Calling unregister_instance with an invalid sample returns RETCODE_BAD_PARAMETER - ASSERT_EQ(ReturnCode_t::RETCODE_OK, instance_datawriter->enable()); - EXPECT_EQ(ReturnCode_t::RETCODE_BAD_PARAMETER, + ASSERT_EQ(RETCODE_OK, instance_datawriter->enable()); + EXPECT_EQ(RETCODE_BAD_PARAMETER, instance_datawriter->unregister_instance_w_timestamp(nullptr, handle, ts)); #if !defined(NDEBUG) // 4. Calling unregister_instance with an inconsistent handle returns RETCODE_PRECONDITION_NOT_MET - EXPECT_EQ(ReturnCode_t::RETCODE_PRECONDITION_NOT_MET, instance_datawriter->unregister_instance_w_timestamp(&data, + EXPECT_EQ(RETCODE_PRECONDITION_NOT_MET, instance_datawriter->unregister_instance_w_timestamp(&data, datawriter->get_instance_handle(), ts)); #endif // NDEBUG // 5. Calling unregister_instance with a key not yet registered returns RETCODE_PRECONDITION_NOT_MET - EXPECT_EQ(ReturnCode_t::RETCODE_PRECONDITION_NOT_MET, + EXPECT_EQ(RETCODE_PRECONDITION_NOT_MET, instance_datawriter->unregister_instance_w_timestamp(&data, handle, ts)); // 6. Calling unregister_instance with a valid key returns RETCODE_OK - ASSERT_EQ(ReturnCode_t::RETCODE_OK, instance_datawriter->write_w_timestamp(&data, HANDLE_NIL, ts)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, instance_datawriter->unregister_instance_w_timestamp(&data, handle, ts)); + ASSERT_EQ(RETCODE_OK, instance_datawriter->write_w_timestamp(&data, HANDLE_NIL, ts)); + EXPECT_EQ(RETCODE_OK, instance_datawriter->unregister_instance_w_timestamp(&data, handle, ts)); // 7. Calling unregister_instance with a valid InstanceHandle also returns RETCODE_OK data.message("HelloWorld_1"); - ASSERT_EQ(ReturnCode_t::RETCODE_OK, instance_datawriter->write_w_timestamp(&data, HANDLE_NIL, ts)); + ASSERT_EQ(RETCODE_OK, instance_datawriter->write_w_timestamp(&data, HANDLE_NIL, ts)); instance_type.get_key(&data, &handle); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, instance_datawriter->unregister_instance_w_timestamp(&data, handle, ts)); + EXPECT_EQ(RETCODE_OK, instance_datawriter->unregister_instance_w_timestamp(&data, handle, ts)); // 8. Check invalid timestamps - ASSERT_EQ(ReturnCode_t::RETCODE_OK, instance_datawriter->write_w_timestamp(&data, HANDLE_NIL, ts)); + ASSERT_EQ(RETCODE_OK, instance_datawriter->write_w_timestamp(&data, HANDLE_NIL, ts)); ts = eprosima::fastrtps::c_TimeInfinite; - EXPECT_EQ(ReturnCode_t::RETCODE_BAD_PARAMETER, + EXPECT_EQ(RETCODE_BAD_PARAMETER, instance_datawriter->unregister_instance_w_timestamp(&data, handle, ts)); ts = eprosima::fastrtps::c_TimeInvalid; - EXPECT_EQ(ReturnCode_t::RETCODE_BAD_PARAMETER, + EXPECT_EQ(RETCODE_BAD_PARAMETER, instance_datawriter->unregister_instance_w_timestamp(&data, handle, ts)); // TODO(jlbueno) There are other possible errors sending the unregister message: RETCODE_OUT_OF_RESOURCES, @@ -1163,34 +1161,34 @@ TEST(DataWriterTests, Dispose) create_writers_for_instance_test(datawriter, instance_datawriter, &instance_type); // 1. Calling dispose in a disable writer returns RETCODE_NOT_ENABLED - EXPECT_EQ(ReturnCode_t::RETCODE_NOT_ENABLED, datawriter->dispose(&data, handle)); + EXPECT_EQ(RETCODE_NOT_ENABLED, datawriter->dispose(&data, handle)); // 2. Calling dispose in a non keyed topic returns RETCODE_PRECONDITION_NOT MET - ASSERT_EQ(ReturnCode_t::RETCODE_OK, datawriter->enable()); - EXPECT_EQ(ReturnCode_t::RETCODE_PRECONDITION_NOT_MET, datawriter->dispose(&data, handle)); + ASSERT_EQ(RETCODE_OK, datawriter->enable()); + EXPECT_EQ(RETCODE_PRECONDITION_NOT_MET, datawriter->dispose(&data, handle)); // 3. Calling dispose with an invalid sample returns RETCODE_BAD_PARAMETER - ASSERT_EQ(ReturnCode_t::RETCODE_OK, instance_datawriter->enable()); - EXPECT_EQ(ReturnCode_t::RETCODE_BAD_PARAMETER, instance_datawriter->dispose(nullptr, handle)); + ASSERT_EQ(RETCODE_OK, instance_datawriter->enable()); + EXPECT_EQ(RETCODE_BAD_PARAMETER, instance_datawriter->dispose(nullptr, handle)); #if !defined(NDEBUG) // 4. Calling dispose with an inconsistent handle returns RETCODE_PRECONDITION_NOT_MET - EXPECT_EQ(ReturnCode_t::RETCODE_PRECONDITION_NOT_MET, instance_datawriter->dispose(&data, + EXPECT_EQ(RETCODE_PRECONDITION_NOT_MET, instance_datawriter->dispose(&data, datawriter->get_instance_handle())); #endif // NDEBUG // 5. Calling dispose with a key not yet registered returns RETCODE_PRECONDITION_NOT_MET - EXPECT_EQ(ReturnCode_t::RETCODE_PRECONDITION_NOT_MET, instance_datawriter->dispose(&data, handle)); + EXPECT_EQ(RETCODE_PRECONDITION_NOT_MET, instance_datawriter->dispose(&data, handle)); // 6. Calling dispose with a valid key returns RETCODE_OK - ASSERT_EQ(ReturnCode_t::RETCODE_OK, instance_datawriter->write(&data, HANDLE_NIL)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, instance_datawriter->dispose(&data, handle)); + ASSERT_EQ(RETCODE_OK, instance_datawriter->write(&data, HANDLE_NIL)); + EXPECT_EQ(RETCODE_OK, instance_datawriter->dispose(&data, handle)); // 7. Calling dispose with a valid InstanceHandle also returns RETCODE_OK data.message("HelloWorld_1"); - ASSERT_EQ(ReturnCode_t::RETCODE_OK, instance_datawriter->write(&data, HANDLE_NIL)); + ASSERT_EQ(RETCODE_OK, instance_datawriter->write(&data, HANDLE_NIL)); instance_type.get_key(&data, &handle); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, instance_datawriter->dispose(&data, handle)); + EXPECT_EQ(RETCODE_OK, instance_datawriter->dispose(&data, handle)); // TODO(jlbueno) There are other possible errors sending the dispose message: RETCODE_OUT_OF_RESOURCES, // RETCODE_ERROR, and RETCODE_TIMEOUT (only if HAVE_STRICT_REALTIME has been defined). @@ -1215,41 +1213,41 @@ TEST(DataWriterTests, DisposeWithTimestamp) eprosima::fastrtps::Time_t ts{ 0, 1 }; // 1. Calling dispose in a disable writer returns RETCODE_NOT_ENABLED - EXPECT_EQ(ReturnCode_t::RETCODE_NOT_ENABLED, datawriter->dispose_w_timestamp(&data, handle, ts)); + EXPECT_EQ(RETCODE_NOT_ENABLED, datawriter->dispose_w_timestamp(&data, handle, ts)); // 2. Calling dispose in a non keyed topic returns RETCODE_PRECONDITION_NOT MET - ASSERT_EQ(ReturnCode_t::RETCODE_OK, datawriter->enable()); - EXPECT_EQ(ReturnCode_t::RETCODE_PRECONDITION_NOT_MET, datawriter->dispose_w_timestamp(&data, handle, ts)); + ASSERT_EQ(RETCODE_OK, datawriter->enable()); + EXPECT_EQ(RETCODE_PRECONDITION_NOT_MET, datawriter->dispose_w_timestamp(&data, handle, ts)); // 3. Calling dispose with an invalid sample returns RETCODE_BAD_PARAMETER - ASSERT_EQ(ReturnCode_t::RETCODE_OK, instance_datawriter->enable()); - EXPECT_EQ(ReturnCode_t::RETCODE_BAD_PARAMETER, instance_datawriter->dispose_w_timestamp(nullptr, handle, ts)); + ASSERT_EQ(RETCODE_OK, instance_datawriter->enable()); + EXPECT_EQ(RETCODE_BAD_PARAMETER, instance_datawriter->dispose_w_timestamp(nullptr, handle, ts)); #if !defined(NDEBUG) // 4. Calling dispose with an inconsistent handle returns RETCODE_PRECONDITION_NOT_MET - EXPECT_EQ(ReturnCode_t::RETCODE_PRECONDITION_NOT_MET, instance_datawriter->dispose_w_timestamp(&data, + EXPECT_EQ(RETCODE_PRECONDITION_NOT_MET, instance_datawriter->dispose_w_timestamp(&data, datawriter->get_instance_handle(), ts)); #endif // NDEBUG // 5. Calling dispose with a key not yet registered returns RETCODE_PRECONDITION_NOT_MET - EXPECT_EQ(ReturnCode_t::RETCODE_PRECONDITION_NOT_MET, instance_datawriter->dispose_w_timestamp(&data, handle, ts)); + EXPECT_EQ(RETCODE_PRECONDITION_NOT_MET, instance_datawriter->dispose_w_timestamp(&data, handle, ts)); // 6. Calling dispose with a valid key returns RETCODE_OK - ASSERT_EQ(ReturnCode_t::RETCODE_OK, instance_datawriter->write_w_timestamp(&data, HANDLE_NIL, ts)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, instance_datawriter->dispose_w_timestamp(&data, handle, ts)); + ASSERT_EQ(RETCODE_OK, instance_datawriter->write_w_timestamp(&data, HANDLE_NIL, ts)); + EXPECT_EQ(RETCODE_OK, instance_datawriter->dispose_w_timestamp(&data, handle, ts)); // 7. Calling dispose with a valid InstanceHandle also returns RETCODE_OK data.message("HelloWorld_1"); - ASSERT_EQ(ReturnCode_t::RETCODE_OK, instance_datawriter->write_w_timestamp(&data, HANDLE_NIL, ts)); + ASSERT_EQ(RETCODE_OK, instance_datawriter->write_w_timestamp(&data, HANDLE_NIL, ts)); instance_type.get_key(&data, &handle); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, instance_datawriter->dispose_w_timestamp(&data, handle, ts)); + EXPECT_EQ(RETCODE_OK, instance_datawriter->dispose_w_timestamp(&data, handle, ts)); // 8. Check invalid timestamps - ASSERT_EQ(ReturnCode_t::RETCODE_OK, instance_datawriter->write_w_timestamp(&data, HANDLE_NIL, ts)); + ASSERT_EQ(RETCODE_OK, instance_datawriter->write_w_timestamp(&data, HANDLE_NIL, ts)); ts = eprosima::fastrtps::c_TimeInfinite; - EXPECT_EQ(ReturnCode_t::RETCODE_BAD_PARAMETER, instance_datawriter->dispose_w_timestamp(&data, handle, ts)); + EXPECT_EQ(RETCODE_BAD_PARAMETER, instance_datawriter->dispose_w_timestamp(&data, handle, ts)); ts = eprosima::fastrtps::c_TimeInvalid; - EXPECT_EQ(ReturnCode_t::RETCODE_BAD_PARAMETER, instance_datawriter->dispose_w_timestamp(&data, handle, ts)); + EXPECT_EQ(RETCODE_BAD_PARAMETER, instance_datawriter->dispose_w_timestamp(&data, handle, ts)); // TODO(jlbueno) There are other possible errors sending the dispose message: RETCODE_OUT_OF_RESOURCES, // RETCODE_ERROR, and RETCODE_TIMEOUT (only if HAVE_STRICT_REALTIME has been defined). @@ -1274,39 +1272,39 @@ TEST(DataWriterTests, GetKeyValue) create_writers_for_instance_test(datawriter, instance_datawriter); // 1. Check nullptr on key_holder - EXPECT_EQ(ReturnCode_t::RETCODE_BAD_PARAMETER, datawriter->get_key_value(nullptr, wrong_handle)); - EXPECT_EQ(ReturnCode_t::RETCODE_BAD_PARAMETER, instance_datawriter->get_key_value(nullptr, wrong_handle)); + EXPECT_EQ(RETCODE_BAD_PARAMETER, datawriter->get_key_value(nullptr, wrong_handle)); + EXPECT_EQ(RETCODE_BAD_PARAMETER, instance_datawriter->get_key_value(nullptr, wrong_handle)); // 2. Check HANDLE_NIL - EXPECT_EQ(ReturnCode_t::RETCODE_BAD_PARAMETER, datawriter->get_key_value(&data, HANDLE_NIL)); - EXPECT_EQ(ReturnCode_t::RETCODE_BAD_PARAMETER, instance_datawriter->get_key_value(&data, HANDLE_NIL)); + EXPECT_EQ(RETCODE_BAD_PARAMETER, datawriter->get_key_value(&data, HANDLE_NIL)); + EXPECT_EQ(RETCODE_BAD_PARAMETER, instance_datawriter->get_key_value(&data, HANDLE_NIL)); // 3. Check type should have keys, and writer should be enabled - EXPECT_EQ(ReturnCode_t::RETCODE_ILLEGAL_OPERATION, datawriter->get_key_value(&data, wrong_handle)); - EXPECT_EQ(ReturnCode_t::RETCODE_NOT_ENABLED, instance_datawriter->get_key_value(&data, wrong_handle)); + EXPECT_EQ(RETCODE_ILLEGAL_OPERATION, datawriter->get_key_value(&data, wrong_handle)); + EXPECT_EQ(RETCODE_NOT_ENABLED, instance_datawriter->get_key_value(&data, wrong_handle)); - ASSERT_EQ(ReturnCode_t::RETCODE_OK, datawriter->enable()); - ASSERT_EQ(ReturnCode_t::RETCODE_OK, instance_datawriter->enable()); + ASSERT_EQ(RETCODE_OK, datawriter->enable()); + ASSERT_EQ(RETCODE_OK, instance_datawriter->enable()); // 4. Calling get_key_value with a key not yet registered returns RETCODE_BAD_PARAMETER - EXPECT_EQ(ReturnCode_t::RETCODE_BAD_PARAMETER, instance_datawriter->get_key_value(&data, wrong_handle)); + EXPECT_EQ(RETCODE_BAD_PARAMETER, instance_datawriter->get_key_value(&data, wrong_handle)); // 5. Calling get_key_value on a registered instance should work. valid_handle = instance_datawriter->register_instance(&valid_data); EXPECT_NE(HANDLE_NIL, valid_handle); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, instance_datawriter->get_key_value(&data, valid_handle)); + EXPECT_EQ(RETCODE_OK, instance_datawriter->get_key_value(&data, valid_handle)); // 6. Calling get_key_value on an unregistered instance should return RETCODE_BAD_PARAMETER. - ASSERT_EQ(ReturnCode_t::RETCODE_OK, instance_datawriter->unregister_instance(&valid_data, valid_handle)); - EXPECT_EQ(ReturnCode_t::RETCODE_BAD_PARAMETER, instance_datawriter->get_key_value(&data, valid_handle)); + ASSERT_EQ(RETCODE_OK, instance_datawriter->unregister_instance(&valid_data, valid_handle)); + EXPECT_EQ(RETCODE_BAD_PARAMETER, instance_datawriter->get_key_value(&data, valid_handle)); // 7. Calling get_key_value with a valid instance should work - ASSERT_EQ(ReturnCode_t::RETCODE_OK, instance_datawriter->write(&valid_data, HANDLE_NIL)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, instance_datawriter->get_key_value(&data, valid_handle)); + ASSERT_EQ(RETCODE_OK, instance_datawriter->write(&valid_data, HANDLE_NIL)); + EXPECT_EQ(RETCODE_OK, instance_datawriter->get_key_value(&data, valid_handle)); // 8. Calling get_key_value on a disposed instance should work. - ASSERT_EQ(ReturnCode_t::RETCODE_OK, instance_datawriter->dispose(&valid_data, valid_handle)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, instance_datawriter->get_key_value(&data, valid_handle)); + ASSERT_EQ(RETCODE_OK, instance_datawriter->dispose(&valid_data, valid_handle)); + EXPECT_EQ(RETCODE_OK, instance_datawriter->get_key_value(&data, valid_handle)); } struct LoanableType @@ -1444,61 +1442,61 @@ TEST(DataWriterTests, LoanPositiveTests) void* sample = nullptr; // Loan and discard (check different initialization schemes) - EXPECT_EQ(ReturnCode_t::RETCODE_OK, datawriter->loan_sample(sample, InitKind::NO_LOAN_INITIALIZATION)); + EXPECT_EQ(RETCODE_OK, datawriter->loan_sample(sample, InitKind::NO_LOAN_INITIALIZATION)); EXPECT_NE(nullptr, sample); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, datawriter->discard_loan(sample)); - EXPECT_EQ(ReturnCode_t::RETCODE_BAD_PARAMETER, datawriter->discard_loan(sample)); + EXPECT_EQ(RETCODE_OK, datawriter->discard_loan(sample)); + EXPECT_EQ(RETCODE_BAD_PARAMETER, datawriter->discard_loan(sample)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, datawriter->loan_sample(sample, InitKind::ZERO_LOAN_INITIALIZATION)); + EXPECT_EQ(RETCODE_OK, datawriter->loan_sample(sample, InitKind::ZERO_LOAN_INITIALIZATION)); ASSERT_NE(nullptr, sample); EXPECT_EQ(0u, static_cast(sample)->index); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, datawriter->discard_loan(sample)); - EXPECT_EQ(ReturnCode_t::RETCODE_BAD_PARAMETER, datawriter->discard_loan(sample)); + EXPECT_EQ(RETCODE_OK, datawriter->discard_loan(sample)); + EXPECT_EQ(RETCODE_BAD_PARAMETER, datawriter->discard_loan(sample)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, datawriter->loan_sample(sample, InitKind::CONSTRUCTED_LOAN_INITIALIZATION)); + EXPECT_EQ(RETCODE_OK, datawriter->loan_sample(sample, InitKind::CONSTRUCTED_LOAN_INITIALIZATION)); ASSERT_NE(nullptr, sample); EXPECT_EQ(LoanableType::initialization_value(), static_cast(sample)->index); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, datawriter->discard_loan(sample)); - EXPECT_EQ(ReturnCode_t::RETCODE_BAD_PARAMETER, datawriter->discard_loan(sample)); + EXPECT_EQ(RETCODE_OK, datawriter->discard_loan(sample)); + EXPECT_EQ(RETCODE_BAD_PARAMETER, datawriter->discard_loan(sample)); // Resource limits: // Depth has been configured to 1, so pool will allow up to depth + 1 loans. // We will check that the 3rd unreturned loan returns OUT_OF_RESOURCES. void* sample_2 = nullptr; void* sample_3 = nullptr; - EXPECT_EQ(ReturnCode_t::RETCODE_OK, datawriter->loan_sample(sample)); + EXPECT_EQ(RETCODE_OK, datawriter->loan_sample(sample)); EXPECT_NE(nullptr, sample); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, datawriter->loan_sample(sample_2)); + EXPECT_EQ(RETCODE_OK, datawriter->loan_sample(sample_2)); EXPECT_NE(nullptr, sample_2); - EXPECT_EQ(ReturnCode_t::RETCODE_OUT_OF_RESOURCES, datawriter->loan_sample(sample_3)); + EXPECT_EQ(RETCODE_OUT_OF_RESOURCES, datawriter->loan_sample(sample_3)); EXPECT_EQ(nullptr, sample_3); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, datawriter->discard_loan(sample_2)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, datawriter->discard_loan(sample)); + EXPECT_EQ(RETCODE_OK, datawriter->discard_loan(sample_2)); + EXPECT_EQ(RETCODE_OK, datawriter->discard_loan(sample)); // Write samples, both loaned and not LoanableType data; fastrtps::rtps::InstanceHandle_t handle; - EXPECT_EQ(ReturnCode_t::RETCODE_OK, datawriter->loan_sample(sample)); + EXPECT_EQ(RETCODE_OK, datawriter->loan_sample(sample)); EXPECT_NE(nullptr, sample); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, datawriter->loan_sample(sample_2)); + EXPECT_EQ(RETCODE_OK, datawriter->loan_sample(sample_2)); EXPECT_NE(nullptr, sample_2); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, datawriter->write(sample, handle)); - EXPECT_EQ(ReturnCode_t::RETCODE_BAD_PARAMETER, datawriter->discard_loan(sample)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, datawriter->write(sample_2, handle)); - EXPECT_EQ(ReturnCode_t::RETCODE_BAD_PARAMETER, datawriter->discard_loan(sample_2)); + EXPECT_EQ(RETCODE_OK, datawriter->write(sample, handle)); + EXPECT_EQ(RETCODE_BAD_PARAMETER, datawriter->discard_loan(sample)); + EXPECT_EQ(RETCODE_OK, datawriter->write(sample_2, handle)); + EXPECT_EQ(RETCODE_BAD_PARAMETER, datawriter->discard_loan(sample_2)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, datawriter->write(&data, handle)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, datawriter->loan_sample(sample)); + EXPECT_EQ(RETCODE_OK, datawriter->write(&data, handle)); + EXPECT_EQ(RETCODE_OK, datawriter->loan_sample(sample)); EXPECT_NE(nullptr, sample); - EXPECT_EQ(ReturnCode_t::RETCODE_OUT_OF_RESOURCES, datawriter->write(&data, handle)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, datawriter->discard_loan(sample)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, datawriter->write(&data, handle)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, datawriter->write(&data, handle)); - - ASSERT_TRUE(publisher->delete_datawriter(datawriter) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(participant->delete_topic(topic) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(participant->delete_publisher(publisher) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == ReturnCode_t::RETCODE_OK); + EXPECT_EQ(RETCODE_OUT_OF_RESOURCES, datawriter->write(&data, handle)); + EXPECT_EQ(RETCODE_OK, datawriter->discard_loan(sample)); + EXPECT_EQ(RETCODE_OK, datawriter->write(&data, handle)); + EXPECT_EQ(RETCODE_OK, datawriter->write(&data, handle)); + + ASSERT_TRUE(publisher->delete_datawriter(datawriter) == RETCODE_OK); + ASSERT_TRUE(participant->delete_topic(topic) == RETCODE_OK); + ASSERT_TRUE(participant->delete_publisher(publisher) == RETCODE_OK); + ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == RETCODE_OK); } class LoanableTypeSupportTesting : public LoanableTypeSupport @@ -1562,31 +1560,31 @@ TEST(DataWriterTests, LoanNegativeTests) // Check for illegal operation type_support->is_plain_result = false; - EXPECT_EQ(ReturnCode_t::RETCODE_ILLEGAL_OPERATION, datawriter->loan_sample(sample)); + EXPECT_EQ(RETCODE_ILLEGAL_OPERATION, datawriter->loan_sample(sample)); type_support->is_plain_result = true; type_support->m_typeSize = 0; - EXPECT_EQ(ReturnCode_t::RETCODE_ILLEGAL_OPERATION, datawriter->loan_sample(sample)); + EXPECT_EQ(RETCODE_ILLEGAL_OPERATION, datawriter->loan_sample(sample)); type_support->m_typeSize = original_type_size; // Check for not enabled - EXPECT_EQ(ReturnCode_t::RETCODE_NOT_ENABLED, datawriter->loan_sample(sample)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, datawriter->enable()); + EXPECT_EQ(RETCODE_NOT_ENABLED, datawriter->loan_sample(sample)); + EXPECT_EQ(RETCODE_OK, datawriter->enable()); // Check for constructor support type_support->construct_sample_result = false; - EXPECT_EQ(ReturnCode_t::RETCODE_UNSUPPORTED, + EXPECT_EQ(RETCODE_UNSUPPORTED, datawriter->loan_sample(sample, InitKind::CONSTRUCTED_LOAN_INITIALIZATION)); type_support->construct_sample_result = true; // Check preconditions on delete_datawriter - EXPECT_EQ(ReturnCode_t::RETCODE_OK, datawriter->loan_sample(sample)); - EXPECT_EQ(ReturnCode_t::RETCODE_PRECONDITION_NOT_MET, publisher->delete_datawriter(datawriter)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, datawriter->discard_loan(sample)); - - ASSERT_TRUE(publisher->delete_datawriter(datawriter) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(participant->delete_topic(topic) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(participant->delete_publisher(publisher) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == ReturnCode_t::RETCODE_OK); + EXPECT_EQ(RETCODE_OK, datawriter->loan_sample(sample)); + EXPECT_EQ(RETCODE_PRECONDITION_NOT_MET, publisher->delete_datawriter(datawriter)); + EXPECT_EQ(RETCODE_OK, datawriter->discard_loan(sample)); + + ASSERT_TRUE(publisher->delete_datawriter(datawriter) == RETCODE_OK); + ASSERT_TRUE(participant->delete_topic(topic) == RETCODE_OK); + ASSERT_TRUE(participant->delete_publisher(publisher) == RETCODE_OK); + ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == RETCODE_OK); } class DataWriterTest : public DataWriter @@ -1653,25 +1651,25 @@ TEST(DataWriterTests, InstanceWaitForAcknowledgement) ASSERT_NE(nullptr, instance_datawriter); // 1. Calling wait_for_acknowledgments in a disable writer returns RETCODE_NOT_ENABLED - EXPECT_EQ(ReturnCode_t::RETCODE_NOT_ENABLED, datawriter->wait_for_acknowledgments(&data, handle, max_wait)); + EXPECT_EQ(RETCODE_NOT_ENABLED, datawriter->wait_for_acknowledgments(&data, handle, max_wait)); // 2. Calling wait_for_acknowledgments in a non keyed topic returns RETCODE_PRECONDITION_NOT MET - ASSERT_EQ(ReturnCode_t::RETCODE_OK, datawriter->enable()); - EXPECT_EQ(ReturnCode_t::RETCODE_PRECONDITION_NOT_MET, datawriter->wait_for_acknowledgments(&data, handle, + ASSERT_EQ(RETCODE_OK, datawriter->enable()); + EXPECT_EQ(RETCODE_PRECONDITION_NOT_MET, datawriter->wait_for_acknowledgments(&data, handle, max_wait)); // 3. Calling wait_for_acknowledgments with an invalid sample returns RETCODE_BAD_PARAMETER - ASSERT_EQ(ReturnCode_t::RETCODE_OK, instance_datawriter->enable()); - EXPECT_EQ(ReturnCode_t::RETCODE_BAD_PARAMETER, instance_datawriter->wait_for_acknowledgments(nullptr, handle, + ASSERT_EQ(RETCODE_OK, instance_datawriter->enable()); + EXPECT_EQ(RETCODE_BAD_PARAMETER, instance_datawriter->wait_for_acknowledgments(nullptr, handle, max_wait)); #if !defined(NDEBUG) // 4. Calling wait_for_acknowledgments with an inconsistent handle returns RETCODE_BAD_PARAMETER - EXPECT_EQ(ReturnCode_t::RETCODE_PRECONDITION_NOT_MET, instance_datawriter->wait_for_acknowledgments(&data, + EXPECT_EQ(RETCODE_PRECONDITION_NOT_MET, instance_datawriter->wait_for_acknowledgments(&data, datawriter->get_instance_handle(), max_wait)); #endif // NDEBUG - // Access PublisherHistory + // Access DataWriterHistory DataWriterTest* instance_datawriter_test = static_cast(instance_datawriter); ASSERT_NE(nullptr, instance_datawriter_test); DataWriterImpl* datawriter_impl = instance_datawriter_test->get_impl(); @@ -1683,8 +1681,8 @@ TEST(DataWriterTests, InstanceWaitForAcknowledgement) // 5. Calling wait_for_acknowledgments in a keyed topic with HANDLE_NIL returns // RETCODE_OK EXPECT_CALL(*history, wait_for_acknowledgement_last_change(_, _, _)).WillOnce(testing::Return(true)); - ASSERT_EQ(ReturnCode_t::RETCODE_OK, instance_datawriter->write(&data, HANDLE_NIL)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, instance_datawriter->wait_for_acknowledgments(&data, handle, + ASSERT_EQ(RETCODE_OK, instance_datawriter->write(&data, HANDLE_NIL)); + EXPECT_EQ(RETCODE_OK, instance_datawriter->wait_for_acknowledgments(&data, handle, max_wait)); // 6. Calling wait_for_acknowledgments in a keyed topic with a known handle returns RETCODE_OK (no matched readers) @@ -1692,13 +1690,13 @@ TEST(DataWriterTests, InstanceWaitForAcknowledgement) EXPECT_CALL(*history, wait_for_acknowledgement_last_change(_, _, _)).WillOnce(testing::Return(true)); instance_type.get_key(&data, &handle); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, instance_datawriter->wait_for_acknowledgments(&data, handle, max_wait)); + EXPECT_EQ(RETCODE_OK, instance_datawriter->wait_for_acknowledgments(&data, handle, max_wait)); // 7. Calling wait_for_acknowledgments in a keyed topic with a known handle timeouts if some reader has not // acknowledged before max_wait time (mock) returns RETCODE_TIMEOUT // Expectations EXPECT_CALL(*history, wait_for_acknowledgement_last_change(_, _, _)).WillOnce(testing::Return(false)); - EXPECT_EQ(ReturnCode_t::RETCODE_TIMEOUT, instance_datawriter->wait_for_acknowledgments(&data, handle, max_wait)); + EXPECT_EQ(RETCODE_TIMEOUT, instance_datawriter->wait_for_acknowledgments(&data, handle, max_wait)); } #endif // __QNXNTO__ @@ -1754,7 +1752,7 @@ class DataWriterUnsupportedTests : public ::testing::Test /* * This test checks that the DataWriter methods defined in the standard not yet implemented in FastDDS return - * ReturnCode_t::RETCODE_UNSUPPORTED. The following methods are checked: + * RETCODE_UNSUPPORTED. The following methods are checked: * 1. get_matched_subscription_data * 2. get_matched_subscriptions * 3. lookup_instance @@ -1780,21 +1778,21 @@ TEST_F(DataWriterUnsupportedTests, UnsupportedDataWriterMethods) builtin::SubscriptionBuiltinTopicData subscription_data; fastrtps::rtps::InstanceHandle_t subscription_handle; EXPECT_EQ( - ReturnCode_t::RETCODE_UNSUPPORTED, + RETCODE_UNSUPPORTED, data_writer->get_matched_subscription_data(subscription_data, subscription_handle)); std::vector subscription_handles; - EXPECT_EQ(ReturnCode_t::RETCODE_UNSUPPORTED, data_writer->get_matched_subscriptions(subscription_handles)); + EXPECT_EQ(RETCODE_UNSUPPORTED, data_writer->get_matched_subscriptions(subscription_handles)); EXPECT_EQ(HANDLE_NIL, data_writer->lookup_instance(nullptr /* instance */)); // Expected logWarnings: lookup_instance HELPER_WaitForEntries(1); - ASSERT_EQ(publisher->delete_datawriter(data_writer), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(participant->delete_publisher(publisher), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(participant->delete_topic(topic), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(publisher->delete_datawriter(data_writer), RETCODE_OK); + ASSERT_EQ(participant->delete_publisher(publisher), RETCODE_OK); + ASSERT_EQ(participant->delete_topic(topic), RETCODE_OK); + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), RETCODE_OK); } /* @@ -1872,12 +1870,12 @@ TEST(DataWriterTests, InstancePolicyAllocationConsistencyNotKeyed) ASSERT_NE(data_writer5, nullptr); // Next QoS config checks the default qos configuration, - // set_qos() should return ReturnCode_t::RETCODE_OK = 0 + // set_qos() should return RETCODE_OK = 0 DataWriterQos qos2 = DATAWRITER_QOS_DEFAULT; DataWriter* default_data_writer1 = publisher->create_datawriter(topic, qos2); ASSERT_NE(default_data_writer1, nullptr); - ASSERT_EQ(ReturnCode_t::RETCODE_OK, default_data_writer1->set_qos(qos2)); + ASSERT_EQ(RETCODE_OK, default_data_writer1->set_qos(qos2)); // Below an ampliation of the last comprobation, for which it is proved the case of < 0 (-1), // which also means infinite value. @@ -1887,35 +1885,35 @@ TEST(DataWriterTests, InstancePolicyAllocationConsistencyNotKeyed) qos2.resource_limits().max_instances = -1; qos2.resource_limits().max_samples_per_instance = -1; - ASSERT_EQ(ReturnCode_t::RETCODE_OK, default_data_writer1->set_qos(qos2)); + ASSERT_EQ(RETCODE_OK, default_data_writer1->set_qos(qos2)); // Next QoS config checks that if user sets max_samples < ( max_instances * max_samples_per_instance ) , - // set_qos() should return ReturnCode_t::RETCODE_OK = 0 + // set_qos() should return RETCODE_OK = 0 // By not using instances, instance allocation consistency is not checked. qos2.resource_limits().max_samples = 4999; qos2.resource_limits().max_instances = 10; qos2.resource_limits().max_samples_per_instance = 500; - ASSERT_EQ(ReturnCode_t::RETCODE_OK, default_data_writer1->set_qos(qos2)); + ASSERT_EQ(RETCODE_OK, default_data_writer1->set_qos(qos2)); // Next QoS config checks that if user sets max_samples > ( max_instances * max_samples_per_instance ) , - // set_qos() should return ReturnCode_t::RETCODE_OK = 0 + // set_qos() should return RETCODE_OK = 0 // By not using instances, instance allocation consistency is not checked. qos2.resource_limits().max_samples = 5001; qos2.resource_limits().max_instances = 10; qos2.resource_limits().max_samples_per_instance = 500; - ASSERT_EQ(ReturnCode_t::RETCODE_OK, default_data_writer1->set_qos(qos2)); + ASSERT_EQ(RETCODE_OK, default_data_writer1->set_qos(qos2)); // Next QoS config checks that if user sets max_samples infinite // and ( max_instances * max_samples_per_instance ) finite, - // set_qos() should return ReturnCode_t::RETCODE_OK = 0 + // set_qos() should return RETCODE_OK = 0 // By not using instances, instance allocation consistency is not checked. qos2.resource_limits().max_samples = 0; qos2.resource_limits().max_instances = 10; qos2.resource_limits().max_samples_per_instance = 500; - ASSERT_EQ(ReturnCode_t::RETCODE_OK, default_data_writer1->set_qos(qos2)); + ASSERT_EQ(RETCODE_OK, default_data_writer1->set_qos(qos2)); } /* @@ -2002,12 +2000,12 @@ TEST(DataWriterTests, InstancePolicyAllocationConsistencyKeyed) ASSERT_NE(data_writer6, nullptr); // Next QoS config checks the default qos configuration, - // set_qos() should return ReturnCode_t::RETCODE_OK = 0, as the by default values are already infinite. + // set_qos() should return RETCODE_OK = 0, as the by default values are already infinite. DataWriterQos qos2 = DATAWRITER_QOS_DEFAULT; DataWriter* default_data_writer1 = publisher->create_datawriter(topic, qos2); ASSERT_NE(default_data_writer1, nullptr); - ASSERT_EQ(ReturnCode_t::RETCODE_OK, default_data_writer1->set_qos(qos2)); + ASSERT_EQ(RETCODE_OK, default_data_writer1->set_qos(qos2)); // Below an ampliation of the last comprobation, for which it is proved the case of < 0 (-1), // which also means infinite value. @@ -2016,7 +2014,7 @@ TEST(DataWriterTests, InstancePolicyAllocationConsistencyKeyed) qos2.resource_limits().max_instances = -1; qos2.resource_limits().max_samples_per_instance = -1; - ASSERT_EQ(ReturnCode_t::RETCODE_OK, default_data_writer1->set_qos(qos2)); + ASSERT_EQ(RETCODE_OK, default_data_writer1->set_qos(qos2)); // Next QoS config checks that if user sets max_samples < ( max_instances * max_samples_per_instance ) , // set_qos() should return a value != 0 (not OK) @@ -2024,32 +2022,32 @@ TEST(DataWriterTests, InstancePolicyAllocationConsistencyKeyed) qos2.resource_limits().max_instances = 10; qos2.resource_limits().max_samples_per_instance = 500; - ASSERT_NE(ReturnCode_t::RETCODE_OK, default_data_writer1->set_qos(qos2)); + ASSERT_NE(RETCODE_OK, default_data_writer1->set_qos(qos2)); // Next QoS config checks that if user sets max_samples > ( max_instances * max_samples_per_instance ) , - // set_qos() should return ReturnCode_t::RETCODE_OK = 0. + // set_qos() should return RETCODE_OK = 0. qos2.resource_limits().max_samples = 5001; qos2.resource_limits().max_instances = 10; qos2.resource_limits().max_samples_per_instance = 500; - ASSERT_EQ(ReturnCode_t::RETCODE_OK, default_data_writer1->set_qos(qos2)); + ASSERT_EQ(RETCODE_OK, default_data_writer1->set_qos(qos2)); // Next QoS config checks that if user sets max_samples = ( max_instances * max_samples_per_instance ) , - // set_qos() should return ReturnCode_t::RETCODE_OK = 0. + // set_qos() should return RETCODE_OK = 0. qos2.resource_limits().max_samples = 5000; qos2.resource_limits().max_instances = 10; qos2.resource_limits().max_samples_per_instance = 500; - ASSERT_EQ(ReturnCode_t::RETCODE_OK, default_data_writer1->set_qos(qos2)); + ASSERT_EQ(RETCODE_OK, default_data_writer1->set_qos(qos2)); // Next QoS config checks that if user sets max_samples infinite // and ( max_instances * max_samples_per_instance ) finite, - // set_qos() should return ReturnCode_t::RETCODE_OK = 0. + // set_qos() should return RETCODE_OK = 0. qos2.resource_limits().max_samples = 0; qos2.resource_limits().max_instances = 10; qos2.resource_limits().max_samples_per_instance = 500; - ASSERT_EQ(ReturnCode_t::RETCODE_OK, default_data_writer1->set_qos(qos2)); + ASSERT_EQ(RETCODE_OK, default_data_writer1->set_qos(qos2)); } @@ -2154,7 +2152,7 @@ TEST(DataWriterTests, history_depth_max_samples_per_instance_warning) /* Check that the datawriter can send data */ FooType data; - ASSERT_EQ(ReturnCode_t::RETCODE_OK, datawriter_1->write(&data, HANDLE_NIL)); + ASSERT_EQ(RETCODE_OK, datawriter_1->write(&data, HANDLE_NIL)); /* Check that a correctly initialized writer does not produce any warning */ qos.history().depth = 10; diff --git a/test/unittest/dds/publisher/PublisherTests.cpp b/test/unittest/dds/publisher/PublisherTests.cpp index 1b14b36dd1d..6d911c79005 100644 --- a/test/unittest/dds/publisher/PublisherTests.cpp +++ b/test/unittest/dds/publisher/PublisherTests.cpp @@ -17,12 +17,6 @@ #include #include -#include -#include -#include -#include -#include -#include #include #include #include @@ -32,18 +26,12 @@ #include #include #include -#include -#include -#include namespace eprosima { namespace fastdds { namespace dds { -using fastrtps::PublisherAttributes; using fastrtps::rtps::PropertyPolicyHelper; -using fastrtps::xmlparser::XMLProfileManager; -using fastrtps::xmlparser::XMLP_ret; class TopicDataTypeMock : public TopicDataType { @@ -211,17 +199,8 @@ TEST(PublisherTests, GetPublisherParticipant) ASSERT_EQ(publisher->get_participant(), participant); - ASSERT_TRUE(participant->delete_publisher(publisher) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == ReturnCode_t::RETCODE_OK); -} - -TEST(PublisherTests, GetPSMPublisherParticipant) -{ - ::dds::domain::DomainParticipant participant = ::dds::domain::DomainParticipant(0, PARTICIPANT_QOS_DEFAULT); - ::dds::pub::Publisher publisher = ::dds::pub::Publisher(participant, PUBLISHER_QOS_DEFAULT); - - ASSERT_EQ(publisher.participant().delegate().get(), participant.delegate().get()); - + ASSERT_TRUE(participant->delete_publisher(publisher) == RETCODE_OK); + ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == RETCODE_OK); } TEST(PublisherTests, ChangeDefaultDataWriterQos) @@ -322,7 +301,7 @@ TEST(PublisherTests, ChangeDefaultDataWriterQos) // . data_sharing qos.data_sharing().on("/"); - ASSERT_TRUE(publisher->set_default_datawriter_qos(qos) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(publisher->set_default_datawriter_qos(qos) == RETCODE_OK); DataWriterQos wqos; publisher->get_default_datawriter_qos(wqos); @@ -443,28 +422,11 @@ TEST(PublisherTests, ChangeDefaultDataWriterQos) EXPECT_TRUE(qos == wqos); - ASSERT_TRUE(participant->delete_publisher(publisher) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(participant->delete_publisher(publisher) == RETCODE_OK); + ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == RETCODE_OK); } -TEST(PublisherTests, ChangePSMDefaultDataWriterQos) -{ - ::dds::domain::DomainParticipant participant = ::dds::domain::DomainParticipant(0, PARTICIPANT_QOS_DEFAULT); - ::dds::pub::Publisher publisher = ::dds::pub::Publisher(participant); - - ::dds::pub::qos::DataWriterQos qos = publisher.default_datawriter_qos(); - ASSERT_EQ(qos, DATAWRITER_QOS_DEFAULT); - - qos.deadline().period = 540; - - ASSERT_NO_THROW(publisher.default_datawriter_qos(qos)); - ::dds::pub::qos::DataWriterQos wqos = publisher.default_datawriter_qos(); - - ASSERT_TRUE(qos == wqos); - ASSERT_EQ(wqos.deadline().period, 540); -} - TEST(PublisherTests, ChangePublisherQos) { DomainParticipant* participant = @@ -487,25 +449,9 @@ TEST(PublisherTests, ChangePublisherQos) ASSERT_TRUE(qos == pqos); ASSERT_EQ(pqos.entity_factory().autoenable_created_entities, false); - ASSERT_TRUE(participant->delete_publisher(publisher) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == ReturnCode_t::RETCODE_OK); - -} - -TEST(PublisherTests, ChangePSMPublisherQos) -{ - ::dds::domain::DomainParticipant participant = ::dds::domain::DomainParticipant(0, PARTICIPANT_QOS_DEFAULT); - ::dds::pub::Publisher publisher = ::dds::pub::Publisher(participant); - - ::dds::pub::qos::PublisherQos qos = publisher.qos(); - ASSERT_EQ(qos, PUBLISHER_QOS_DEFAULT); - - qos.entity_factory().autoenable_created_entities = false; - publisher.qos(qos); - ::dds::pub::qos::PublisherQos pqos = publisher.qos(); + ASSERT_TRUE(participant->delete_publisher(publisher) == RETCODE_OK); + ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == RETCODE_OK); - ASSERT_TRUE(qos == pqos); - ASSERT_EQ(pqos.entity_factory().autoenable_created_entities, false); } TEST(PublisherTests, CreateDataWriter) @@ -526,10 +472,10 @@ TEST(PublisherTests, CreateDataWriter) DataWriter* datawriter = publisher->create_datawriter(topic, DATAWRITER_QOS_DEFAULT); ASSERT_NE(datawriter, nullptr); - ASSERT_EQ(publisher->delete_datawriter(datawriter), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(participant->delete_publisher(publisher), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(participant->delete_topic(topic), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(publisher->delete_datawriter(datawriter), RETCODE_OK); + ASSERT_EQ(participant->delete_publisher(publisher), RETCODE_OK); + ASSERT_EQ(participant->delete_topic(topic), RETCODE_OK); + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), RETCODE_OK); } void check_datawriter_with_profile ( @@ -539,54 +485,10 @@ void check_datawriter_with_profile ( DataWriterQos qos; datawriter->get_qos(qos); - PublisherAttributes publisher_atts; - XMLProfileManager::fillPublisherAttributes(profile_name, publisher_atts); - - //Values taken from profile - ASSERT_TRUE( - qos.writer_resource_limits().matched_subscriber_allocation == - publisher_atts.matched_subscriber_allocation); - if (publisher_atts.qos.m_partition.names().empty()) - { - ASSERT_TRUE(qos.properties() == publisher_atts.properties); - } - else - { - ASSERT_NE(PropertyPolicyHelper::find_property(qos.properties(), "partitions"), nullptr); - for (auto partition: publisher_atts.qos.m_partition.names()) - { - ASSERT_NE(PropertyPolicyHelper::find_property(qos.properties(), "partitions")->find( - partition), std::string::npos); - } - } - ASSERT_TRUE(qos.throughput_controller() == publisher_atts.throughputController); - ASSERT_TRUE(qos.endpoint().unicast_locator_list == publisher_atts.unicastLocatorList); - ASSERT_TRUE(qos.endpoint().multicast_locator_list == publisher_atts.multicastLocatorList); - ASSERT_TRUE(qos.endpoint().remote_locator_list == publisher_atts.remoteLocatorList); - ASSERT_TRUE(qos.endpoint().history_memory_policy == publisher_atts.historyMemoryPolicy); - ASSERT_TRUE(qos.endpoint().user_defined_id == publisher_atts.getUserDefinedID()); - ASSERT_TRUE(qos.endpoint().entity_id == publisher_atts.getEntityID()); - ASSERT_TRUE(qos.reliable_writer_qos().times == publisher_atts.times); - ASSERT_TRUE(qos.reliable_writer_qos().disable_positive_acks == publisher_atts.qos.m_disablePositiveACKs); - ASSERT_TRUE(qos.durability() == publisher_atts.qos.m_durability); - ASSERT_TRUE(qos.durability_service() == publisher_atts.qos.m_durabilityService); - ASSERT_TRUE(qos.deadline() == publisher_atts.qos.m_deadline); - ASSERT_TRUE(qos.latency_budget() == publisher_atts.qos.m_latencyBudget); - ASSERT_TRUE(qos.liveliness() == publisher_atts.qos.m_liveliness); - ASSERT_TRUE(qos.reliability() == publisher_atts.qos.m_reliability); - ASSERT_TRUE(qos.lifespan() == publisher_atts.qos.m_lifespan); - ASSERT_TRUE(qos.user_data().data_vec() == publisher_atts.qos.m_userData.data_vec()); - ASSERT_TRUE(qos.ownership() == publisher_atts.qos.m_ownership); - ASSERT_TRUE(qos.ownership_strength() == publisher_atts.qos.m_ownershipStrength); - ASSERT_TRUE(qos.destination_order() == publisher_atts.qos.m_destinationOrder); - ASSERT_TRUE(qos.representation() == publisher_atts.qos.representation); - ASSERT_TRUE(qos.publish_mode() == publisher_atts.qos.m_publishMode); - ASSERT_TRUE(qos.history() == publisher_atts.topic.historyQos); - ASSERT_TRUE(qos.resource_limits() == publisher_atts.topic.resourceLimitsQos); - - //Values not implemented on attributes (taken from default QoS) - ASSERT_TRUE(qos.transport_priority() == DATAWRITER_QOS_DEFAULT.transport_priority()); - ASSERT_TRUE(qos.writer_data_lifecycle() == DATAWRITER_QOS_DEFAULT.writer_data_lifecycle()); + DataWriterQos profile_qos; + EXPECT_EQ(datawriter->get_publisher()->get_datawriter_qos_from_profile(profile_name, profile_qos), + RETCODE_OK); + EXPECT_EQ(qos, profile_qos); } TEST(PublisherTests, CreateDataWriterWithProfile) @@ -603,17 +505,17 @@ TEST(PublisherTests, CreateDataWriterWithProfile) DataWriter* default_datawriter = publisher->create_datawriter(topic, DATAWRITER_QOS_DEFAULT); ASSERT_NE(default_datawriter, nullptr); check_datawriter_with_profile(default_datawriter, "test_default_publisher_profile"); - ASSERT_TRUE(publisher->delete_datawriter(default_datawriter) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(publisher->delete_datawriter(default_datawriter) == RETCODE_OK); //participant using non-default profile DataWriter* datawriter = publisher->create_datawriter_with_profile(topic, "test_publisher_profile"); ASSERT_NE(datawriter, nullptr); check_datawriter_with_profile(datawriter, "test_publisher_profile"); - ASSERT_TRUE(publisher->delete_datawriter(datawriter) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(publisher->delete_datawriter(datawriter) == RETCODE_OK); - ASSERT_EQ(participant->delete_publisher(publisher), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(participant->delete_topic(topic), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(participant->delete_publisher(publisher), RETCODE_OK); + ASSERT_EQ(participant->delete_topic(topic), RETCODE_OK); + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), RETCODE_OK); } TEST(PublisherTests, CreateDataWriterWithProfileFromString) @@ -635,17 +537,17 @@ TEST(PublisherTests, CreateDataWriterWithProfileFromString) DataWriter* default_datawriter = publisher->create_datawriter(topic, DATAWRITER_QOS_DEFAULT); ASSERT_NE(default_datawriter, nullptr); check_datawriter_with_profile(default_datawriter, "test_default_publisher_profile_string"); - ASSERT_TRUE(publisher->delete_datawriter(default_datawriter) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(publisher->delete_datawriter(default_datawriter) == RETCODE_OK); //participant using non-default profile DataWriter* datawriter = publisher->create_datawriter_with_profile(topic, "test_publisher_profile_string"); ASSERT_NE(datawriter, nullptr); check_datawriter_with_profile(datawriter, "test_publisher_profile_string"); - ASSERT_TRUE(publisher->delete_datawriter(datawriter) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(publisher->delete_datawriter(datawriter) == RETCODE_OK); - ASSERT_EQ(participant->delete_publisher(publisher), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(participant->delete_topic(topic), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(participant->delete_publisher(publisher), RETCODE_OK); + ASSERT_EQ(participant->delete_topic(topic), RETCODE_OK); + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), RETCODE_OK); } TEST(PublisherTests, GetDataWriterProfileQos) @@ -665,7 +567,7 @@ TEST(PublisherTests, GetDataWriterProfileQos) DataWriterQos qos; EXPECT_EQ( publisher->get_datawriter_qos_from_profile("test_publisher_profile", qos), - ReturnCode_t::RETCODE_OK); + RETCODE_OK); //Datawriter using the extracted qos DataWriter* datawriter = publisher->create_datawriter(topic, qos); @@ -676,13 +578,13 @@ TEST(PublisherTests, GetDataWriterProfileQos) // Test return when a non-existent profile is used EXPECT_EQ( publisher->get_datawriter_qos_from_profile("incorrect_profile_name", qos), - ReturnCode_t::RETCODE_BAD_PARAMETER); + RETCODE_BAD_PARAMETER); // Clean up - ASSERT_EQ(publisher->delete_datawriter(datawriter), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(participant->delete_publisher(publisher), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(participant->delete_topic(topic), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(publisher->delete_datawriter(datawriter), RETCODE_OK); + ASSERT_EQ(participant->delete_publisher(publisher), RETCODE_OK); + ASSERT_EQ(participant->delete_topic(topic), RETCODE_OK); + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), RETCODE_OK); } TEST(PublisherTests, DeletePublisherWithWriters) @@ -703,13 +605,13 @@ TEST(PublisherTests, DeletePublisherWithWriters) DataWriter* datawriter = publisher->create_datawriter(topic, DATAWRITER_QOS_DEFAULT); ASSERT_NE(datawriter, nullptr); - ASSERT_EQ(participant->delete_publisher(publisher), ReturnCode_t::RETCODE_PRECONDITION_NOT_MET); + ASSERT_EQ(participant->delete_publisher(publisher), RETCODE_PRECONDITION_NOT_MET); - ASSERT_EQ(publisher->delete_datawriter(datawriter), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(participant->delete_publisher(publisher), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(publisher->delete_datawriter(datawriter), RETCODE_OK); + ASSERT_EQ(participant->delete_publisher(publisher), RETCODE_OK); - ASSERT_EQ(participant->delete_topic(topic), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(participant->delete_topic(topic), RETCODE_OK); + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), RETCODE_OK); } @@ -718,7 +620,7 @@ void set_listener_test ( PublisherListener* listener, StatusMask mask) { - ASSERT_EQ(publisher->set_listener(listener, mask), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(publisher->set_listener(listener, mask), RETCODE_OK); ASSERT_EQ(publisher->get_status_mask(), mask); } @@ -762,8 +664,8 @@ TEST(PublisherTests, SetListener) std::get<2>(testing_case)); } - ASSERT_EQ(participant->delete_publisher(publisher), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(participant->delete_publisher(publisher), RETCODE_OK); + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), RETCODE_OK); } // Delete contained entities test @@ -795,23 +697,23 @@ TEST(Publisher, DeleteContainedEntities) data_writer_list.clear(); void* loan_data; - ASSERT_EQ(data_writer_bar->loan_sample(loan_data), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(data_writer_bar->loan_sample(loan_data), RETCODE_OK); - ASSERT_EQ(publisher->delete_contained_entities(), ReturnCode_t::RETCODE_PRECONDITION_NOT_MET); + ASSERT_EQ(publisher->delete_contained_entities(), RETCODE_PRECONDITION_NOT_MET); publisher->get_datawriters(data_writer_list); ASSERT_EQ(data_writer_list.size(), 2u); data_writer_list.clear(); data_writer_bar->discard_loan(loan_data); - ASSERT_EQ(publisher->delete_contained_entities(), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(publisher->delete_contained_entities(), RETCODE_OK); publisher->get_datawriters(data_writer_list); ASSERT_FALSE(publisher->has_datawriters()); } /* * This test checks that the Publisher methods defined in the standard not yet implemented in FastDDS return - * ReturnCode_t::RETCODE_UNSUPPORTED. The following methods are checked: + * RETCODE_UNSUPPORTED. The following methods are checked: * 1. suspend_publications * 2. resume_publications * 3. begin_coherent_changes @@ -827,13 +729,13 @@ TEST(PublisherTests, UnsupportedPublisherMethods) fastdds::dds::DataWriterQos writer_qos; fastdds::dds::TopicQos topic_qos; - EXPECT_EQ(ReturnCode_t::RETCODE_UNSUPPORTED, publisher->suspend_publications()); - EXPECT_EQ(ReturnCode_t::RETCODE_UNSUPPORTED, publisher->resume_publications()); - EXPECT_EQ(ReturnCode_t::RETCODE_UNSUPPORTED, publisher->begin_coherent_changes()); - EXPECT_EQ(ReturnCode_t::RETCODE_UNSUPPORTED, publisher->end_coherent_changes()); + EXPECT_EQ(RETCODE_UNSUPPORTED, publisher->suspend_publications()); + EXPECT_EQ(RETCODE_UNSUPPORTED, publisher->resume_publications()); + EXPECT_EQ(RETCODE_UNSUPPORTED, publisher->begin_coherent_changes()); + EXPECT_EQ(RETCODE_UNSUPPORTED, publisher->end_coherent_changes()); - ASSERT_EQ(participant->delete_publisher(publisher), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(participant->delete_publisher(publisher), RETCODE_OK); + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), RETCODE_OK); } /** diff --git a/test/unittest/dds/status/CMakeLists.txt b/test/unittest/dds/status/CMakeLists.txt index a3a41587fca..711073a5c04 100644 --- a/test/unittest/dds/status/CMakeLists.txt +++ b/test/unittest/dds/status/CMakeLists.txt @@ -16,28 +16,6 @@ file(GLOB DDSSQLFILTER_SOURCES ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/topic/DDSSQ set(LISTENERTESTS_SOURCE ListenerTests.cpp ${DDSSQLFILTER_SOURCES} - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/AnnotationDescriptor.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/AnnotationParameterValue.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/BuiltinAnnotationsTypeObject.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicData.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicDataFactory.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicDataPtr.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicPubSubType.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicType.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeBuilder.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeBuilderFactory.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeBuilderPtr.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeMember.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypePtr.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/MemberDescriptor.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeDescriptor.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeIdentifier.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeIdentifierTypes.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeNamesGenerator.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeObject.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeObjectFactory.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeObjectHashId.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypesBase.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/core/condition/Condition.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/core/condition/ConditionNotifier.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/core/condition/StatusCondition.cpp @@ -51,11 +29,6 @@ set(LISTENERTESTS_SOURCE ListenerTests.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/domain/DomainParticipantImpl.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/domain/qos/DomainParticipantFactoryQos.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/domain/qos/DomainParticipantQos.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/FileConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/Log.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/OStreamConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutErrConsumer.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/publisher/DataWriter.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/publisher/DataWriterHistory.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/publisher/DataWriterImpl.cpp @@ -84,7 +57,6 @@ set(LISTENERTESTS_SOURCE ListenerTests.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/utils/QosConverters.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/attributes/PropertyPolicy.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/attributes/ThreadSettings.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/attributes/ThreadSettings.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/LocatorWithMask.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/Time_t.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/flowcontrol/FlowControllerConsts.cpp @@ -99,11 +71,6 @@ set(LISTENERTESTS_SOURCE ListenerTests.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/transport/network/NetworkInterfaceWithFilter.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/transport/PortBasedTransportDescriptor.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/writer/LocatorSelectorSender.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/xmlparser/XMLDynamicParser.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/xmlparser/XMLElementParser.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/xmlparser/XMLParser.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/xmlparser/XMLParserCommon.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/xmlparser/XMLProfileManager.cpp ${PROJECT_SOURCE_DIR}/src/cpp/statistics/fastdds/domain/DomainParticipant.cpp ${PROJECT_SOURCE_DIR}/src/cpp/statistics/fastdds/publisher/qos/DataWriterQos.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/IPFinder.cpp @@ -113,6 +80,11 @@ set(LISTENERTESTS_SOURCE ListenerTests.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/SystemInfo.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/TimedConditionVariable.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/UnitsParser.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/xmlparser/XMLDynamicParser.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/xmlparser/XMLElementParser.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/xmlparser/XMLParser.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/xmlparser/XMLParserCommon.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/xmlparser/XMLProfileManager.cpp ) if (FASTDDS_STATISTICS) @@ -120,12 +92,10 @@ if (FASTDDS_STATISTICS) set(statistics_sources ${PROJECT_SOURCE_DIR}/src/cpp/statistics/fastdds/domain/DomainParticipantImpl.cpp ${PROJECT_SOURCE_DIR}/src/cpp/statistics/fastdds/domain/DomainParticipantStatisticsListener.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/types.cxx - ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/typesv1.cxx - ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/typesPubSubTypes.cxx ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/monitorservice_typesPubSubTypes.cxx - ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/monitorservice_types.cxx - ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/monitorservice_typesv1.cxx + ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/monitorservice_typesTypeObjectSupport.cxx + ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/typesPubSubTypes.cxx + ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/typesTypeObjectSupport.cxx ) list(APPEND LISTENERTESTS_SOURCE ${statistics_sources}) @@ -205,7 +175,12 @@ target_include_directories(ListenerTests PRIVATE ${PROJECT_SOURCE_DIR}/thirdparty/taocpp-pegtl ) -target_link_libraries(ListenerTests fastcdr foonathan_memory +target_link_libraries(ListenerTests + fastcdr + fastdds::log + fastdds::xtypes::dynamic-types::impl + fastdds::xtypes::type-representation + foonathan_memory ${TINYXML2_LIBRARY} GTest::gmock ${CMAKE_DL_LIBS} diff --git a/test/unittest/dds/status/ListenerTests.cpp b/test/unittest/dds/status/ListenerTests.cpp index 61afbb40dcf..8f6937fe9e0 100644 --- a/test/unittest/dds/status/ListenerTests.cpp +++ b/test/unittest/dds/status/ListenerTests.cpp @@ -30,7 +30,6 @@ #include #include #include -#include #include #include @@ -60,12 +59,6 @@ RTPSParticipant* RTPSDomain::participant_ = nullptr; namespace fastdds { namespace dds { -namespace builtin { - -const fastrtps::rtps::SampleIdentity INVALID_SAMPLE_IDENTITY; - -} // namespace builtin - class RTPSParticipantMock : public eprosima::fastrtps::rtps::RTPSParticipant { public: @@ -161,7 +154,7 @@ class CustomDataReaderListener : public DataReaderListener void on_requested_deadline_missed( DataReader*, - const fastrtps::RequestedDeadlineMissedStatus&) + const RequestedDeadlineMissedStatus&) { on_requested_deadline_missed_relay(); } @@ -170,7 +163,7 @@ class CustomDataReaderListener : public DataReaderListener void on_liveliness_changed( DataReader*, - const fastrtps::LivelinessChangedStatus&) + const LivelinessChangedStatus&) { on_liveliness_changed_relay(); } @@ -179,7 +172,7 @@ class CustomDataReaderListener : public DataReaderListener void on_sample_rejected( DataReader*, - const fastrtps::SampleRejectedStatus&) + const SampleRejectedStatus&) { on_sample_rejected_relay(); } @@ -236,7 +229,7 @@ class CustomSubscriberListener : public SubscriberListener void on_requested_deadline_missed( DataReader*, - const fastrtps::RequestedDeadlineMissedStatus&) + const RequestedDeadlineMissedStatus&) { on_requested_deadline_missed_relay(); } @@ -245,7 +238,7 @@ class CustomSubscriberListener : public SubscriberListener void on_liveliness_changed( DataReader*, - const fastrtps::LivelinessChangedStatus&) + const LivelinessChangedStatus&) { on_liveliness_changed_relay(); } @@ -254,7 +247,7 @@ class CustomSubscriberListener : public SubscriberListener void on_sample_rejected( DataReader*, - const fastrtps::SampleRejectedStatus&) + const SampleRejectedStatus&) { on_sample_rejected_relay(); } @@ -429,7 +422,7 @@ class CustomParticipantListener : public DomainParticipantListener void on_requested_deadline_missed( DataReader*, - const fastrtps::RequestedDeadlineMissedStatus&) + const RequestedDeadlineMissedStatus&) { on_requested_deadline_missed_relay(); } @@ -438,7 +431,7 @@ class CustomParticipantListener : public DomainParticipantListener void on_liveliness_changed( DataReader*, - const fastrtps::LivelinessChangedStatus&) + const LivelinessChangedStatus&) { on_liveliness_changed_relay(); } @@ -447,7 +440,7 @@ class CustomParticipantListener : public DomainParticipantListener void on_sample_rejected( DataReader*, - const fastrtps::SampleRejectedStatus&) + const SampleRejectedStatus&) { on_sample_rejected_relay(); } @@ -588,15 +581,15 @@ class UserListeners : public ::testing::Test void TearDown() override { - ASSERT_EQ(publisher_->delete_datawriter(datawriter_), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(participant_->delete_publisher(publisher_), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(publisher_->delete_datawriter(datawriter_), RETCODE_OK); + ASSERT_EQ(participant_->delete_publisher(publisher_), RETCODE_OK); - ASSERT_EQ(subscriber_->delete_datareader(datareader_), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(participant_->delete_subscriber(subscriber_), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(subscriber_->delete_datareader(datareader_), RETCODE_OK); + ASSERT_EQ(participant_->delete_subscriber(subscriber_), RETCODE_OK); - ASSERT_EQ(participant_->delete_topic(topic_), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(participant_->delete_topic(topic_), RETCODE_OK); - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant_), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant_), RETCODE_OK); } // RTPS entity mocks are nice, we don't want to track all calls diff --git a/test/unittest/dds/subscriber/CMakeLists.txt b/test/unittest/dds/subscriber/CMakeLists.txt index b77b83e8739..82118c18449 100644 --- a/test/unittest/dds/subscriber/CMakeLists.txt +++ b/test/unittest/dds/subscriber/CMakeLists.txt @@ -24,9 +24,6 @@ set(DATAREADERINSTANCETESTS_SOURCE DataReaderInstanceTests.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/Time_t.cpp ) set(DATAREADERHISTORYTESTS_SOURCE DataReaderHistoryTests.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/Log.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/OStreamConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutConsumer.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/subscriber/history/DataReaderHistory.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/topic/TopicDataType.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/LocatorWithMask.cpp @@ -75,7 +72,7 @@ target_include_directories(SubscriberTests PRIVATE ${PROJECT_SOURCE_DIR}/include ${PROJECT_BINARY_DIR}/include ${PROJECT_SOURCE_DIR}/src/cpp ) -target_link_libraries(SubscriberTests fastrtps fastcdr foonathan_memory +target_link_libraries(SubscriberTests fastdds fastcdr foonathan_memory GTest::gmock ${CMAKE_DL_LIBS}) gtest_discover_tests(SubscriberTests) @@ -94,7 +91,7 @@ target_include_directories(DataReaderTests PRIVATE ${PROJECT_SOURCE_DIR}/src/cpp ${Asio_INCLUDE_DIR} ) -target_link_libraries(DataReaderTests fastrtps fastcdr foonathan_memory +target_link_libraries(DataReaderTests fastdds fastcdr foonathan_memory GTest::gmock ${CMAKE_DL_LIBS}) gtest_discover_tests(DataReaderTests) @@ -136,7 +133,10 @@ target_include_directories(DataReaderHistoryTests PRIVATE ${PROJECT_SOURCE_DIR}/src/cpp ${THIRDPARTY_BOOST_INCLUDE_DIR} ) -target_link_libraries(DataReaderHistoryTests fastcdr foonathan_memory +target_link_libraries(DataReaderHistoryTests + fastcdr + fastdds::log + foonathan_memory GTest::gmock ${CMAKE_DL_LIBS}) gtest_discover_tests(DataReaderHistoryTests) diff --git a/test/unittest/dds/subscriber/DataReaderHistoryTests.cpp b/test/unittest/dds/subscriber/DataReaderHistoryTests.cpp index 5efd99bf2b6..3fd9fc0c827 100644 --- a/test/unittest/dds/subscriber/DataReaderHistoryTests.cpp +++ b/test/unittest/dds/subscriber/DataReaderHistoryTests.cpp @@ -2,7 +2,7 @@ #include #include #include -#include +#include #include diff --git a/test/unittest/dds/subscriber/DataReaderTests.cpp b/test/unittest/dds/subscriber/DataReaderTests.cpp index d06472baa73..778adb7eb87 100644 --- a/test/unittest/dds/subscriber/DataReaderTests.cpp +++ b/test/unittest/dds/subscriber/DataReaderTests.cpp @@ -24,12 +24,11 @@ #include #include - #include #include -#include - +#include "fastdds/dds/common/InstanceHandle.hpp" +#include "fastdds/dds/core/policy/QosPolicies.hpp" #include #include #include @@ -54,15 +53,13 @@ #include #include #include +#include #include #include -#include -#include +#include #include "../../common/CustomPayloadPool.hpp" #include "../../logging/mock/MockConsumer.h" -#include "fastdds/dds/common/InstanceHandle.hpp" -#include "fastdds/dds/core/policy/QosPolicies.hpp" #include "FooBoundedType.hpp" #include "FooBoundedTypeSupport.hpp" #include "FooType.hpp" @@ -111,28 +108,28 @@ class DataReaderTests : public ::testing::Test if (data_writer_) { - ASSERT_EQ(publisher_->delete_datawriter(data_writer_), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(publisher_->delete_datawriter(data_writer_), RETCODE_OK); } if (data_reader_) { - ASSERT_EQ(subscriber_->delete_datareader(data_reader_), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(subscriber_->delete_datareader(data_reader_), RETCODE_OK); } if (topic_) { - ASSERT_EQ(participant_->delete_topic(topic_), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(participant_->delete_topic(topic_), RETCODE_OK); } if (publisher_) { - ASSERT_EQ(participant_->delete_publisher(publisher_), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(participant_->delete_publisher(publisher_), RETCODE_OK); } if (subscriber_) { - ASSERT_EQ(participant_->delete_subscriber(subscriber_), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(participant_->delete_subscriber(subscriber_), RETCODE_OK); } if (participant_) { auto factory = DomainParticipantFactory::get_instance(); - ASSERT_EQ(factory->delete_participant(participant_), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(factory->delete_participant(participant_), RETCODE_OK); } } @@ -186,7 +183,7 @@ class DataReaderTests : public ::testing::Test LoanableCollection& data_values, SampleInfoSeq& infos) { - if (ReturnCode_t::RETCODE_OK == code) + if (RETCODE_OK == code) { data_values.length(0); infos.length(0); @@ -203,7 +200,7 @@ class DataReaderTests : public ::testing::Test { if (infos[i].valid_data) { - EXPECT_EQ(ReturnCode_t::RETCODE_OK, data_writer_->write(buffer[i], HANDLE_NIL)); + EXPECT_EQ(RETCODE_OK, data_writer_->write(buffer[i], HANDLE_NIL)); } } } @@ -218,31 +215,33 @@ class DataReaderTests : public ::testing::Test * The return value to expect from `return_loan` will be calculated from this one as follows: * - NOT_ENABLED => NOT_ENABLED (calling `return_loan` on a not enabled reader). * - OK => OK (successfully returning a loan). - * - Any other => RETCODE_PRECONDITION_NOT_MET (trying to return collections which the reader - * did not loan). + * - Any other => RETCODE_PRECONDITION_NOT_MET (trying to return non-empty collections which + * the reader did not loan). * @param data_reader The reader on which to return the loan. * @param data_values The data collection to return. * @param infos The SampleInfo collection to return. + * @param seq_max The value to expect as `maximum` on the collections after return_loan returns OK. */ void check_return_loan( const ReturnCode_t& code, DataReader* data_reader, LoanableCollection& data_values, - SampleInfoSeq& infos) + SampleInfoSeq& infos, + int32_t seq_max) { - ReturnCode_t expected_return_loan_ret = ReturnCode_t::RETCODE_PRECONDITION_NOT_MET; - if (ReturnCode_t::RETCODE_OK == code || ReturnCode_t::RETCODE_NOT_ENABLED == code) + ReturnCode_t expected_return_loan_ret = RETCODE_PRECONDITION_NOT_MET; + if (RETCODE_OK == code || RETCODE_NOT_ENABLED == code) { expected_return_loan_ret = code; } EXPECT_EQ(expected_return_loan_ret, data_reader->return_loan(data_values, infos)); - if (ReturnCode_t::RETCODE_OK == expected_return_loan_ret) + if (RETCODE_OK == expected_return_loan_ret) { EXPECT_TRUE(data_values.has_ownership()); - EXPECT_EQ(0, data_values.maximum()); + EXPECT_EQ(seq_max, data_values.maximum()); EXPECT_TRUE(infos.has_ownership()); - EXPECT_EQ(0, infos.maximum()); + EXPECT_EQ(seq_max, infos.maximum()); } } @@ -264,19 +263,20 @@ class DataReaderTests : public ::testing::Test DataReader* data_reader, LoanableCollection& data_values, SampleInfoSeq& infos, - int32_t max_samples = LENGTH_UNLIMITED) + int32_t max_samples = LENGTH_UNLIMITED, + int32_t seq_max = 0) { EXPECT_EQ(instance_ok_code, data_reader->read_instance(data_values, infos, max_samples, handle)); - check_return_loan(loan_return_code, data_reader, data_values, infos); + check_return_loan(loan_return_code, data_reader, data_values, infos, seq_max); reset_lengths_if_ok(instance_ok_code, data_values, infos); EXPECT_EQ(instance_ok_code, data_reader->take_instance(data_values, infos, max_samples, handle)); - if (ReturnCode_t::RETCODE_OK == instance_ok_code) + if (RETCODE_OK == instance_ok_code) { // Write received data so it can be taken again send_data(data_values, infos); } - check_return_loan(loan_return_code, data_reader, data_values, infos); + check_return_loan(loan_return_code, data_reader, data_values, infos, seq_max); reset_lengths_if_ok(instance_ok_code, data_values, infos); } @@ -298,12 +298,13 @@ class DataReaderTests : public ::testing::Test DataReader* data_reader, LoanableCollection& data_values, SampleInfoSeq& infos, - int32_t max_samples = LENGTH_UNLIMITED) + int32_t max_samples = LENGTH_UNLIMITED, + int32_t seq_max = 0) { EXPECT_EQ(instance_bad_code, data_reader->read_instance(data_values, infos, max_samples, handle)); - check_return_loan(wrong_loan_code, data_reader, data_values, infos); + check_return_loan(wrong_loan_code, data_reader, data_values, infos, seq_max); EXPECT_EQ(instance_bad_code, data_reader->take_instance(data_values, infos, max_samples, handle)); - check_return_loan(wrong_loan_code, data_reader, data_values, infos); + check_return_loan(wrong_loan_code, data_reader, data_values, infos, seq_max); } /** @@ -317,6 +318,7 @@ class DataReaderTests : public ::testing::Test * @param infos The sample_info collection to use * @param max_samples The value to pass as `max_samples` on calls to `read/take_instance` * @param two_valid_instances Whether `handle_wrong_` is considered a valid instance + * @param seq_max The value to expect as `maximum` on the collections after return_loan returns OK. */ void check_instance_methods( const ReturnCode_t& instance_ok_code, @@ -326,34 +328,39 @@ class DataReaderTests : public ::testing::Test LoanableCollection& data_values, SampleInfoSeq& infos, int32_t max_samples = LENGTH_UNLIMITED, - bool two_valid_instances = false) + bool two_valid_instances = false, + int32_t seq_max = 0) { // Calc expected result of `return_loan` for calls with a wrong instance handle. - ReturnCode_t wrong_loan_code = ReturnCode_t::RETCODE_PRECONDITION_NOT_MET; - if (ReturnCode_t::RETCODE_NOT_ENABLED == instance_bad_code) + ReturnCode_t wrong_loan_code = RETCODE_PRECONDITION_NOT_MET; + if (RETCODE_NOT_ENABLED == instance_bad_code) { wrong_loan_code = instance_bad_code; } + else if (RETCODE_OK == loan_return_code) + { + wrong_loan_code = RETCODE_OK; + } // Trying to get data for HANDLE_NIL should always use instance_bad_code. check_wrong_instance_methods(HANDLE_NIL, instance_bad_code, wrong_loan_code, - data_reader, data_values, infos, max_samples); + data_reader, data_values, infos, max_samples, seq_max); // Trying to get data for handle_wrong_ depends on `two_instances` if (two_valid_instances) { check_correct_instance_methods(handle_wrong_, instance_ok_code, loan_return_code, - data_reader, data_values, infos, max_samples); + data_reader, data_values, infos, max_samples, seq_max); } else { check_wrong_instance_methods(handle_wrong_, instance_bad_code, wrong_loan_code, - data_reader, data_values, infos, max_samples); + data_reader, data_values, infos, max_samples, seq_max); } // Trying to get data for handle_ok_ should always use instance_ok_code check_correct_instance_methods(handle_ok_, instance_ok_code, loan_return_code, - data_reader, data_values, infos, max_samples); + data_reader, data_values, infos, max_samples, seq_max); } /** @@ -388,7 +395,7 @@ class DataReaderTests : public ::testing::Test SampleInfo info; EXPECT_EQ(code, data_reader->take_next_sample(&data, &info)); - if (ReturnCode_t::RETCODE_OK == code) + if (RETCODE_OK == code) { // Send taken sample so it can be read again data_writer_->write(&data); @@ -398,15 +405,15 @@ class DataReaderTests : public ::testing::Test } // Return code when requesting a bad instance - ReturnCode_t instance_bad_code = ReturnCode_t::RETCODE_BAD_PARAMETER; - if (ReturnCode_t::RETCODE_NOT_ENABLED == code) + ReturnCode_t instance_bad_code = RETCODE_BAD_PARAMETER; + if (RETCODE_NOT_ENABLED == code) { instance_bad_code = code; } // Return code when requesting a correct instance ReturnCode_t instance_ok_code = instance_bad_code; - if (ReturnCode_t::RETCODE_OK == code && type_->m_isGetKeyDefined) + if (RETCODE_OK == code && type_->m_isGetKeyDefined) { instance_ok_code = code; } @@ -416,33 +423,40 @@ class DataReaderTests : public ::testing::Test DataSeq data_values; SampleInfoSeq infos; + ReturnCode_t expected_return_loan_ret = code; + if (RETCODE_NO_DATA == code) + { + // Even when read returns data, no loan will be performed + expected_return_loan_ret = RETCODE_OK; + } + EXPECT_EQ(code, data_reader->read(data_values, infos)); - check_return_loan(code, data_reader, data_values, infos); + check_return_loan(expected_return_loan_ret, data_reader, data_values, infos, 0); reset_lengths_if_ok(code, data_values, infos); EXPECT_EQ(code, data_reader->read_next_instance(data_values, infos)); - check_return_loan(code, data_reader, data_values, infos); + check_return_loan(expected_return_loan_ret, data_reader, data_values, infos, 0); reset_lengths_if_ok(code, data_values, infos); EXPECT_EQ(code, data_reader->take(data_values, infos)); - if (ReturnCode_t::RETCODE_OK == code) + if (RETCODE_OK == code) { send_data(data_values, infos); data_reader->wait_for_unread_message(time_to_wait); } - check_return_loan(code, data_reader, data_values, infos); + check_return_loan(expected_return_loan_ret, data_reader, data_values, infos, 0); reset_lengths_if_ok(code, data_values, infos); EXPECT_EQ(code, data_reader->take_next_instance(data_values, infos)); - if (ReturnCode_t::RETCODE_OK == code) + if (RETCODE_OK == code) { send_data(data_values, infos); data_reader->wait_for_unread_message(time_to_wait); } - check_return_loan(code, data_reader, data_values, infos); + check_return_loan(expected_return_loan_ret, data_reader, data_values, infos, 0); reset_lengths_if_ok(code, data_values, infos); - check_instance_methods(instance_ok_code, instance_bad_code, instance_ok_code, - data_reader, data_values, infos, LENGTH_UNLIMITED, two_valid_instances); + check_instance_methods(instance_ok_code, instance_bad_code, expected_return_loan_ret, + data_reader, data_values, infos, LENGTH_UNLIMITED, two_valid_instances, 0); } // Check read/take and variants without loan @@ -451,39 +465,38 @@ class DataReaderTests : public ::testing::Test SampleInfoSeq infos(1); ReturnCode_t expected_return_loan_ret = code; - if (ReturnCode_t::RETCODE_OK == code) + if (RETCODE_NO_DATA == code) { - // Even when read returns data, no loan will be performed - expected_return_loan_ret = ReturnCode_t::RETCODE_PRECONDITION_NOT_MET; + expected_return_loan_ret = RETCODE_OK; } EXPECT_EQ(code, data_reader->read(data_values, infos)); - check_return_loan(expected_return_loan_ret, data_reader, data_values, infos); + check_return_loan(expected_return_loan_ret, data_reader, data_values, infos, data_values.maximum()); reset_lengths_if_ok(code, data_values, infos); EXPECT_EQ(code, data_reader->read_next_instance(data_values, infos)); - check_return_loan(expected_return_loan_ret, data_reader, data_values, infos); + check_return_loan(expected_return_loan_ret, data_reader, data_values, infos, data_values.maximum()); reset_lengths_if_ok(code, data_values, infos); EXPECT_EQ(code, data_reader->take(data_values, infos)); - if (ReturnCode_t::RETCODE_OK == code) + if (RETCODE_OK == code) { send_data(data_values, infos); data_reader->wait_for_unread_message(time_to_wait); } - check_return_loan(expected_return_loan_ret, data_reader, data_values, infos); + check_return_loan(expected_return_loan_ret, data_reader, data_values, infos, data_values.maximum()); reset_lengths_if_ok(code, data_values, infos); EXPECT_EQ(code, data_reader->take_next_instance(data_values, infos)); - if (ReturnCode_t::RETCODE_OK == code) + if (RETCODE_OK == code) { send_data(data_values, infos); data_reader->wait_for_unread_message(time_to_wait); } - check_return_loan(expected_return_loan_ret, data_reader, data_values, infos); + check_return_loan(expected_return_loan_ret, data_reader, data_values, infos, data_values.maximum()); reset_lengths_if_ok(code, data_values, infos); check_instance_methods(instance_ok_code, instance_bad_code, expected_return_loan_ret, - data_reader, data_values, infos, LENGTH_UNLIMITED, two_valid_instances); + data_reader, data_values, infos, LENGTH_UNLIMITED, two_valid_instances, data_values.maximum()); } } @@ -526,33 +539,33 @@ class DataReaderTests : public ::testing::Test EXPECT_EQ(0ull, data_reader_->get_unread_count()); // Read / take operations should all return NOT_ENABLED - basic_read_apis_check(ReturnCode_t::RETCODE_NOT_ENABLED, data_reader_); + basic_read_apis_check(RETCODE_NOT_ENABLED, data_reader_); // Enable the DataReader and check NO_DATA should be returned - EXPECT_EQ(ReturnCode_t::RETCODE_OK, data_reader_->enable()); + EXPECT_EQ(RETCODE_OK, data_reader_->enable()); EXPECT_TRUE(data_reader_->is_enabled()); - basic_read_apis_check(ReturnCode_t::RETCODE_NO_DATA, data_reader_); + basic_read_apis_check(RETCODE_NO_DATA, data_reader_); // Send data DataType data; data.index(0); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, data_writer_->write(&data, HANDLE_NIL)); + EXPECT_EQ(RETCODE_OK, data_writer_->write(&data, HANDLE_NIL)); // Wait for data to arrive and check OK should be returned Duration_t wait_time(1, 0); EXPECT_TRUE(data_reader_->wait_for_unread_message(wait_time)); - basic_read_apis_check(ReturnCode_t::RETCODE_OK, data_reader_); + basic_read_apis_check(RETCODE_OK, data_reader_); // Check with data on second instance data.index(2u); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, data_writer_->write(&data, HANDLE_NIL)); - basic_read_apis_check(ReturnCode_t::RETCODE_OK, data_reader_, true); + EXPECT_EQ(RETCODE_OK, data_writer_->write(&data, HANDLE_NIL)); + basic_read_apis_check(RETCODE_OK, data_reader_, true); // Check with disposed instance if (type_->m_isGetKeyDefined) { - EXPECT_EQ(ReturnCode_t::RETCODE_OK, data_writer_->dispose(&data, handle_wrong_)); - basic_read_apis_check(ReturnCode_t::RETCODE_OK, data_reader_, true); + EXPECT_EQ(RETCODE_OK, data_writer_->dispose(&data, handle_wrong_)); + basic_read_apis_check(RETCODE_OK, data_reader_, true); } } @@ -581,9 +594,10 @@ TEST_F(DataReaderTests, get_guid) { public: - void on_subscriber_discovery( + void on_data_reader_discovery( DomainParticipant*, - ReaderDiscoveryInfo&& info) + ReaderDiscoveryInfo&& info, + bool& /*should_be_ignored*/) override { std::unique_lock lock(mutex); if (ReaderDiscoveryInfo::DISCOVERED_READER == info.status) @@ -599,7 +613,7 @@ TEST_F(DataReaderTests, get_guid) private: - using DomainParticipantListener::on_subscriber_discovery; + using DomainParticipantListener::on_data_reader_discovery; } discovery_listener; @@ -652,12 +666,12 @@ TEST_F(DataReaderTests, get_guid) } ASSERT_EQ(guid, discovery_listener.guid); - ASSERT_TRUE(subscriber->delete_datareader(datareader) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(participant->delete_topic(topic) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(participant->delete_subscriber(subscriber) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(subscriber->delete_datareader(datareader) == RETCODE_OK); + ASSERT_TRUE(participant->delete_topic(topic) == RETCODE_OK); + ASSERT_TRUE(participant->delete_subscriber(subscriber) == RETCODE_OK); + ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == RETCODE_OK); ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant( - listener_participant) == ReturnCode_t::RETCODE_OK); + listener_participant) == RETCODE_OK); } TEST_F(DataReaderTests, InvalidQos) @@ -667,11 +681,11 @@ TEST_F(DataReaderTests, InvalidQos) create_entities(); ASSERT_TRUE(data_reader_->is_enabled()); - ASSERT_EQ(ReturnCode_t::RETCODE_OK, data_reader_->get_qos(qos)); + ASSERT_EQ(RETCODE_OK, data_reader_->get_qos(qos)); ASSERT_EQ(qos, DATAREADER_QOS_DEFAULT); /* Unsupported QoS */ - const ReturnCode_t unsupported_code = ReturnCode_t::RETCODE_UNSUPPORTED; + const ReturnCode_t unsupported_code = RETCODE_UNSUPPORTED; qos = DATAREADER_QOS_DEFAULT; qos.durability().kind = PERSISTENT_DURABILITY_QOS; @@ -682,7 +696,7 @@ TEST_F(DataReaderTests, InvalidQos) EXPECT_EQ(unsupported_code, data_reader_->set_qos(qos)); /* Inconsistent QoS */ - const ReturnCode_t inconsistent_code = ReturnCode_t::RETCODE_INCONSISTENT_POLICY; + const ReturnCode_t inconsistent_code = RETCODE_INCONSISTENT_POLICY; qos = DATAREADER_QOS_DEFAULT; qos.reader_resource_limits().max_samples_per_read = -1; @@ -714,10 +728,10 @@ TEST_F(DataReaderTests, InvalidQos) // return against RETCODE_INMUTABLE_POLICY we are testing that the setting are not considered inconsistent yet. // This test will fail whenever we enforce the consistency between depth and max_samples_per_instance. qos.history().depth = 2000; - EXPECT_EQ(ReturnCode_t::RETCODE_IMMUTABLE_POLICY, data_reader_->set_qos(qos)); + EXPECT_EQ(RETCODE_IMMUTABLE_POLICY, data_reader_->set_qos(qos)); /* Inmutable QoS */ - const ReturnCode_t inmutable_code = ReturnCode_t::RETCODE_IMMUTABLE_POLICY; + const ReturnCode_t inmutable_code = RETCODE_IMMUTABLE_POLICY; qos = DATAREADER_QOS_DEFAULT; qos.resource_limits().max_samples = 5000; @@ -815,15 +829,16 @@ void check_collection( * take_instance, where no instance would exist and the return will be BAD_PARAMETER. Otherwise, PRECONDITION_NOT_MET * should be returned. * - * As no data will ever be returned, return_loan will always return PRECONDITION_NOT_MET. + * As no data will ever be returned, return_loan will always return OK. */ TEST_F(DataReaderTests, collection_preconditions) { create_entities(); create_instance_handles(); - const ReturnCode_t& ok_code = ReturnCode_t::RETCODE_NO_DATA; - const ReturnCode_t& wrong_code = ReturnCode_t::RETCODE_PRECONDITION_NOT_MET; + const ReturnCode_t& no_data_code = RETCODE_NO_DATA; + const ReturnCode_t& wrong_code = RETCODE_PRECONDITION_NOT_MET; + const ReturnCode_t& return_loan_code = RETCODE_OK; // Helper buffers to create loaned sequences FooArray arr; @@ -904,35 +919,35 @@ TEST_F(DataReaderTests, collection_preconditions) } // Check compatible combinations - using ok_test_case_t = std::pair; + using ok_test_case_t = std::pair>; std::vector ok_cases { // max == 0. Loaned data will be returned. - { {true_0_0, info_true_0_0}, ok_code}, + { {true_0_0, info_true_0_0}, {no_data_code, return_loan_code}}, // max > 0 && owns == true. Data will be copied. - { {true_10_0, info_true_10_0}, ok_code}, - { {true_10_1, info_true_10_1}, ok_code}, + { {true_10_0, info_true_10_0}, {no_data_code, return_loan_code}}, + { {true_10_1, info_true_10_1}, {no_data_code, return_loan_code}}, // max > 0 && owns == false. Precondition not met. - { {false_10_0, info_false_10_0}, wrong_code}, - { {false_10_1, info_false_10_1}, wrong_code} + { {false_10_0, info_false_10_0}, {wrong_code, wrong_code}}, + { {false_10_1, info_false_10_1}, {wrong_code, wrong_code}} }; - const ReturnCode_t& instance_bad_code = ReturnCode_t::RETCODE_BAD_PARAMETER; + const ReturnCode_t& instance_bad_code = RETCODE_BAD_PARAMETER; for (const ok_test_case_t& test : ok_cases) { - EXPECT_EQ(test.second, data_reader_->read(test.first.first, test.first.second)); - EXPECT_EQ(wrong_code, data_reader_->return_loan(test.first.first, test.first.second)); - EXPECT_EQ(test.second, data_reader_->read_next_instance(test.first.first, test.first.second)); - EXPECT_EQ(wrong_code, data_reader_->return_loan(test.first.first, test.first.second)); - EXPECT_EQ(test.second, data_reader_->take(test.first.first, test.first.second)); - EXPECT_EQ(wrong_code, data_reader_->return_loan(test.first.first, test.first.second)); - EXPECT_EQ(test.second, data_reader_->take_next_instance(test.first.first, test.first.second)); - EXPECT_EQ(wrong_code, data_reader_->return_loan(test.first.first, test.first.second)); + EXPECT_EQ(test.second.first, data_reader_->read(test.first.first, test.first.second)); + EXPECT_EQ(test.second.second, data_reader_->return_loan(test.first.first, test.first.second)); + EXPECT_EQ(test.second.first, data_reader_->read_next_instance(test.first.first, test.first.second)); + EXPECT_EQ(test.second.second, data_reader_->return_loan(test.first.first, test.first.second)); + EXPECT_EQ(test.second.first, data_reader_->take(test.first.first, test.first.second)); + EXPECT_EQ(test.second.second, data_reader_->return_loan(test.first.first, test.first.second)); + EXPECT_EQ(test.second.first, data_reader_->take_next_instance(test.first.first, test.first.second)); + EXPECT_EQ(test.second.second, data_reader_->return_loan(test.first.first, test.first.second)); // When collection preconditions are ok, as the reader has no data, BAD_PARAMETER will be returned - const ReturnCode_t& instance_code = (test.second == ok_code) ? instance_bad_code : test.second; - check_instance_methods(instance_code, instance_code, wrong_code, - data_reader_, test.first.first, test.first.second); + const ReturnCode_t& instance_code = (test.second.first == no_data_code) ? instance_bad_code : test.second.first; + check_instance_methods(instance_code, instance_code, test.second.second, + data_reader_, test.first.first, test.first.second, LENGTH_UNLIMITED, false, test.first.first.maximum()); } // Check for max_samples > max_len @@ -942,8 +957,8 @@ TEST_F(DataReaderTests, collection_preconditions) EXPECT_EQ(wrong_code, data_reader_->take(true_10_0, info_true_10_0, 20)); EXPECT_EQ(wrong_code, data_reader_->take_next_instance(true_10_0, info_true_10_0, 20)); - check_instance_methods(wrong_code, wrong_code, wrong_code, - data_reader_, true_10_0, info_true_10_0, 20); + check_instance_methods(wrong_code, wrong_code, return_loan_code, + data_reader_, true_10_0, info_true_10_0, 20, false, true_10_0.maximum()); } @@ -994,16 +1009,19 @@ TEST_F(DataReaderTests, return_loan) FooSeq data_values_2; SampleInfoSeq infos_2; - const ReturnCode_t& ok_code = ReturnCode_t::RETCODE_OK; - const ReturnCode_t& precondition_code = ReturnCode_t::RETCODE_PRECONDITION_NOT_MET; + const ReturnCode_t& ok_code = RETCODE_OK; + const ReturnCode_t& precondition_code = RETCODE_PRECONDITION_NOT_MET; // Calling return loan on disabled reader should return NOT_ENABLED - EXPECT_EQ(ReturnCode_t::RETCODE_NOT_ENABLED, data_reader_->return_loan(data_values, infos)); + EXPECT_EQ(RETCODE_NOT_ENABLED, data_reader_->return_loan(data_values, infos)); // Enable both readers EXPECT_EQ(ok_code, data_reader_->enable()); EXPECT_EQ(ok_code, reader2->enable()); + // Calling return loan with empty sequences on an enabled reader should return OK + EXPECT_EQ(RETCODE_OK, data_reader_->return_loan(data_values, infos)); + FooType data; data.index(0); @@ -1013,9 +1031,6 @@ TEST_F(DataReaderTests, return_loan) EXPECT_EQ(ok_code, data_writer_->write(&data, handle_ok_)); } - // Returning a loan without having called read or take should return PRECONDITION_NOT_MET - EXPECT_EQ(precondition_code, data_reader_->return_loan(data_values, infos)); - // Read with loan from both readers EXPECT_EQ(ok_code, data_reader_->read(data_values, infos)); EXPECT_EQ(ok_code, reader2->read(data_values_2, infos_2)); @@ -1119,9 +1134,9 @@ TEST_F(DataReaderTests, resource_limits) { static constexpr int32_t num_samples = 100; - const ReturnCode_t& ok_code = ReturnCode_t::RETCODE_OK; - const ReturnCode_t& resources_code = ReturnCode_t::RETCODE_OUT_OF_RESOURCES; - const ReturnCode_t& no_data_code = ReturnCode_t::RETCODE_NO_DATA; + const ReturnCode_t& ok_code = RETCODE_OK; + const ReturnCode_t& resources_code = RETCODE_OUT_OF_RESOURCES; + const ReturnCode_t& no_data_code = RETCODE_NO_DATA; DataWriterQos writer_qos = DATAWRITER_QOS_DEFAULT; writer_qos.history().kind = KEEP_LAST_HISTORY_QOS; @@ -1334,8 +1349,8 @@ TEST_F(DataReaderTests, read_unread) static constexpr int32_t num_samples = 10; static constexpr uint64_t num_samples_check = static_cast(num_samples); - const ReturnCode_t& ok_code = ReturnCode_t::RETCODE_OK; - const ReturnCode_t& no_data_code = ReturnCode_t::RETCODE_NO_DATA; + const ReturnCode_t& ok_code = RETCODE_OK; + const ReturnCode_t& no_data_code = RETCODE_NO_DATA; DataWriterQos writer_qos = DATAWRITER_QOS_DEFAULT; writer_qos.history().kind = KEEP_LAST_HISTORY_QOS; @@ -1598,7 +1613,7 @@ TEST_F(DataReaderTests, get_unread_count) static constexpr int32_t num_samples = 10; static constexpr uint64_t num_samples_check = static_cast(num_samples); - const ReturnCode_t& ok_code = ReturnCode_t::RETCODE_OK; + const ReturnCode_t& ok_code = RETCODE_OK; DataWriterQos writer_qos = DATAWRITER_QOS_DEFAULT; writer_qos.history().kind = KEEP_LAST_HISTORY_QOS; @@ -1639,7 +1654,7 @@ TEST_F(DataReaderTests, get_unread_count) } SampleInfo sample_info; - ASSERT_EQ(ReturnCode_t::RETCODE_OK, data_reader_->get_first_untaken_info(&sample_info)); + ASSERT_EQ(RETCODE_OK, data_reader_->get_first_untaken_info(&sample_info)); ASSERT_EQ(SampleStateKind::NOT_READ_SAMPLE_STATE, sample_info.sample_state); // Calling get_unread_count(false) several times should always return the same value @@ -1648,13 +1663,13 @@ TEST_F(DataReaderTests, get_unread_count) EXPECT_EQ(num_samples_check, data_reader_->get_unread_count(false)); } - ASSERT_EQ(ReturnCode_t::RETCODE_OK, data_reader_->get_first_untaken_info(&sample_info)); + ASSERT_EQ(RETCODE_OK, data_reader_->get_first_untaken_info(&sample_info)); ASSERT_EQ(SampleStateKind::NOT_READ_SAMPLE_STATE, sample_info.sample_state); // Calling get_unread_count(true) once will return the correct value EXPECT_EQ(num_samples_check, data_reader_->get_unread_count(true)); - ASSERT_EQ(ReturnCode_t::RETCODE_OK, data_reader_->get_first_untaken_info(&sample_info)); + ASSERT_EQ(RETCODE_OK, data_reader_->get_first_untaken_info(&sample_info)); ASSERT_EQ(SampleStateKind::READ_SAMPLE_STATE, sample_info.sample_state); // All variants should then return 0 @@ -1826,19 +1841,19 @@ TEST_F(DataReaderTests, sample_info) case TestCmd::DISPOSE: writer = open_writer(cmd.writer_index); ret_code = writer->dispose(&data_[cmd.instance_index], handles_[cmd.instance_index]); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, ret_code); + EXPECT_EQ(RETCODE_OK, ret_code); break; case TestCmd::UNREGISTER: writer = open_writer(cmd.writer_index); ret_code = writer->unregister_instance(&data_[cmd.instance_index], handles_[cmd.instance_index]); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, ret_code); + EXPECT_EQ(RETCODE_OK, ret_code); break; case TestCmd::WRITE: writer = open_writer(cmd.writer_index); ret_code = writer->write(&data_[cmd.instance_index], handles_[cmd.instance_index]); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, ret_code); + EXPECT_EQ(RETCODE_OK, ret_code); break; } } @@ -1854,13 +1869,13 @@ TEST_F(DataReaderTests, sample_info) ret_code = reader->read_instance(values, infos, LENGTH_UNLIMITED, handles_[instance_index]); EXPECT_EQ(ret_code, instance_result.ret_code); - if (ReturnCode_t::RETCODE_OK == ret_code) + if (RETCODE_OK == ret_code) { EXPECT_EQ(instance_result.instance_state, infos[0].instance_state); EXPECT_EQ(instance_result.view_state, infos[0].view_state); EXPECT_EQ(instance_result.disposed_generation_count, infos[0].disposed_generation_count); EXPECT_EQ(instance_result.no_writers_generation_count, infos[0].no_writers_generation_count); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, reader->return_loan(values, infos)); + EXPECT_EQ(RETCODE_OK, reader->return_loan(values, infos)); EXPECT_EQ(handles_[instance_index], reader->lookup_instance(&data_[instance_index])); } @@ -1910,32 +1925,32 @@ TEST_F(DataReaderTests, sample_info) // Instances have never been written {}, { - {ReturnCode_t::RETCODE_BAD_PARAMETER, NEW_VIEW_STATE, ALIVE_INSTANCE_STATE, 0, 0}, - {ReturnCode_t::RETCODE_BAD_PARAMETER, NEW_VIEW_STATE, ALIVE_INSTANCE_STATE, 0, 0}, + {RETCODE_BAD_PARAMETER, NEW_VIEW_STATE, ALIVE_INSTANCE_STATE, 0, 0}, + {RETCODE_BAD_PARAMETER, NEW_VIEW_STATE, ALIVE_INSTANCE_STATE, 0, 0}, } }, { // One writer writes on first instance => that instance should be NEW and ALIVE { {0, TestCmd::WRITE, 0} }, { - {ReturnCode_t::RETCODE_OK, NEW_VIEW_STATE, ALIVE_INSTANCE_STATE, 0, 0}, - {ReturnCode_t::RETCODE_BAD_PARAMETER, NEW_VIEW_STATE, ALIVE_INSTANCE_STATE, 0, 0}, + {RETCODE_OK, NEW_VIEW_STATE, ALIVE_INSTANCE_STATE, 0, 0}, + {RETCODE_BAD_PARAMETER, NEW_VIEW_STATE, ALIVE_INSTANCE_STATE, 0, 0}, } }, { // Same writer writes on first instance => instance becomes NOT_NEW { {0, TestCmd::WRITE, 0} }, { - {ReturnCode_t::RETCODE_OK, NOT_NEW_VIEW_STATE, ALIVE_INSTANCE_STATE, 0, 0}, - {ReturnCode_t::RETCODE_BAD_PARAMETER, NEW_VIEW_STATE, ALIVE_INSTANCE_STATE, 0, 0}, + {RETCODE_OK, NOT_NEW_VIEW_STATE, ALIVE_INSTANCE_STATE, 0, 0}, + {RETCODE_BAD_PARAMETER, NEW_VIEW_STATE, ALIVE_INSTANCE_STATE, 0, 0}, } }, { // Same writer disposes first instance => instance becomes NOT_ALIVE_DISPOSED { {0, TestCmd::DISPOSE, 0} }, { - {ReturnCode_t::RETCODE_OK, NOT_NEW_VIEW_STATE, NOT_ALIVE_DISPOSED_INSTANCE_STATE, 0, 0}, - {ReturnCode_t::RETCODE_BAD_PARAMETER, NEW_VIEW_STATE, ALIVE_INSTANCE_STATE, 0, 0}, + {RETCODE_OK, NOT_NEW_VIEW_STATE, NOT_ALIVE_DISPOSED_INSTANCE_STATE, 0, 0}, + {RETCODE_BAD_PARAMETER, NEW_VIEW_STATE, ALIVE_INSTANCE_STATE, 0, 0}, } }, { @@ -1943,48 +1958,48 @@ TEST_F(DataReaderTests, sample_info) // Second writer writes first instance => NEW and ALIVE { {0, TestCmd::WRITE, 1}, {1, TestCmd::WRITE, 0} }, { - {ReturnCode_t::RETCODE_OK, NEW_VIEW_STATE, ALIVE_INSTANCE_STATE, 1, 0}, - {ReturnCode_t::RETCODE_OK, NEW_VIEW_STATE, ALIVE_INSTANCE_STATE, 0, 0}, + {RETCODE_OK, NEW_VIEW_STATE, ALIVE_INSTANCE_STATE, 1, 0}, + {RETCODE_OK, NEW_VIEW_STATE, ALIVE_INSTANCE_STATE, 0, 0}, } }, { // Both writers write on second instance => NOT_NEW and ALIVE { {0, TestCmd::WRITE, 1}, {1, TestCmd::WRITE, 1} }, { - {ReturnCode_t::RETCODE_OK, NOT_NEW_VIEW_STATE, ALIVE_INSTANCE_STATE, 1, 0}, - {ReturnCode_t::RETCODE_OK, NOT_NEW_VIEW_STATE, ALIVE_INSTANCE_STATE, 0, 0}, + {RETCODE_OK, NOT_NEW_VIEW_STATE, ALIVE_INSTANCE_STATE, 1, 0}, + {RETCODE_OK, NOT_NEW_VIEW_STATE, ALIVE_INSTANCE_STATE, 0, 0}, } }, { // Second writer closes => first instance becomes NOT_ALIVE_NO_WRITERS { {1, TestCmd::CLOSE, 0} }, { - {ReturnCode_t::RETCODE_OK, NOT_NEW_VIEW_STATE, NOT_ALIVE_NO_WRITERS_INSTANCE_STATE, 1, 0}, - {ReturnCode_t::RETCODE_OK, NOT_NEW_VIEW_STATE, ALIVE_INSTANCE_STATE, 0, 0}, + {RETCODE_OK, NOT_NEW_VIEW_STATE, NOT_ALIVE_NO_WRITERS_INSTANCE_STATE, 1, 0}, + {RETCODE_OK, NOT_NEW_VIEW_STATE, ALIVE_INSTANCE_STATE, 0, 0}, } }, { // First writer unregisters second instance => NOT_ALIVE_NO_WRITERS { {0, TestCmd::UNREGISTER, 1} }, { - {ReturnCode_t::RETCODE_OK, NOT_NEW_VIEW_STATE, NOT_ALIVE_NO_WRITERS_INSTANCE_STATE, 1, 0}, - {ReturnCode_t::RETCODE_OK, NOT_NEW_VIEW_STATE, NOT_ALIVE_NO_WRITERS_INSTANCE_STATE, 0, 0}, + {RETCODE_OK, NOT_NEW_VIEW_STATE, NOT_ALIVE_NO_WRITERS_INSTANCE_STATE, 1, 0}, + {RETCODE_OK, NOT_NEW_VIEW_STATE, NOT_ALIVE_NO_WRITERS_INSTANCE_STATE, 0, 0}, } }, { // Both writers write both instances { {0, TestCmd::WRITE, 0}, {1, TestCmd::WRITE, 0}, {0, TestCmd::WRITE, 1}, {1, TestCmd::WRITE, 1} }, { - {ReturnCode_t::RETCODE_OK, NEW_VIEW_STATE, ALIVE_INSTANCE_STATE, 1, 1}, - {ReturnCode_t::RETCODE_OK, NEW_VIEW_STATE, ALIVE_INSTANCE_STATE, 0, 1}, + {RETCODE_OK, NEW_VIEW_STATE, ALIVE_INSTANCE_STATE, 1, 1}, + {RETCODE_OK, NEW_VIEW_STATE, ALIVE_INSTANCE_STATE, 0, 1}, } }, { // Reading twice should return NOT_NEW {}, { - {ReturnCode_t::RETCODE_OK, NOT_NEW_VIEW_STATE, ALIVE_INSTANCE_STATE, 1, 1}, - {ReturnCode_t::RETCODE_OK, NOT_NEW_VIEW_STATE, ALIVE_INSTANCE_STATE, 0, 1}, + {RETCODE_OK, NOT_NEW_VIEW_STATE, ALIVE_INSTANCE_STATE, 1, 1}, + {RETCODE_OK, NOT_NEW_VIEW_STATE, ALIVE_INSTANCE_STATE, 0, 1}, } }, { @@ -1992,8 +2007,8 @@ TEST_F(DataReaderTests, sample_info) // 1 - Disposing while having another alive writer is always done { {0, TestCmd::UNREGISTER, 0}, {1, TestCmd::DISPOSE, 1} }, { - {ReturnCode_t::RETCODE_OK, NOT_NEW_VIEW_STATE, ALIVE_INSTANCE_STATE, 1, 1}, - {ReturnCode_t::RETCODE_OK, NOT_NEW_VIEW_STATE, NOT_ALIVE_DISPOSED_INSTANCE_STATE, 0, 1}, + {RETCODE_OK, NOT_NEW_VIEW_STATE, ALIVE_INSTANCE_STATE, 1, 1}, + {RETCODE_OK, NOT_NEW_VIEW_STATE, NOT_ALIVE_DISPOSED_INSTANCE_STATE, 0, 1}, } }, { @@ -2001,8 +2016,8 @@ TEST_F(DataReaderTests, sample_info) // 1 - Unregister a disposed instance should not change state { {0, TestCmd::WRITE, 0}, {0, TestCmd::UNREGISTER, 1}, {1, TestCmd::UNREGISTER, 0} }, { - {ReturnCode_t::RETCODE_OK, NOT_NEW_VIEW_STATE, ALIVE_INSTANCE_STATE, 1, 1}, - {ReturnCode_t::RETCODE_OK, NOT_NEW_VIEW_STATE, NOT_ALIVE_DISPOSED_INSTANCE_STATE, 0, 1}, + {RETCODE_OK, NOT_NEW_VIEW_STATE, ALIVE_INSTANCE_STATE, 1, 1}, + {RETCODE_OK, NOT_NEW_VIEW_STATE, NOT_ALIVE_DISPOSED_INSTANCE_STATE, 0, 1}, } }, { @@ -2010,8 +2025,8 @@ TEST_F(DataReaderTests, sample_info) // 1 - Closing both writers on a disposed instance should not change state { {0, TestCmd::CLOSE, 0}, {1, TestCmd::CLOSE, 0} }, { - {ReturnCode_t::RETCODE_OK, NOT_NEW_VIEW_STATE, NOT_ALIVE_NO_WRITERS_INSTANCE_STATE, 1, 1}, - {ReturnCode_t::RETCODE_OK, NOT_NEW_VIEW_STATE, NOT_ALIVE_DISPOSED_INSTANCE_STATE, 0, 1}, + {RETCODE_OK, NOT_NEW_VIEW_STATE, NOT_ALIVE_NO_WRITERS_INSTANCE_STATE, 1, 1}, + {RETCODE_OK, NOT_NEW_VIEW_STATE, NOT_ALIVE_DISPOSED_INSTANCE_STATE, 0, 1}, } }, }; @@ -2023,8 +2038,8 @@ TEST_F(DataReaderTests, sample_info) // Taking all data should remove instance information FooSeq data; SampleInfoSeq infos; - EXPECT_EQ(ReturnCode_t::RETCODE_OK, data_reader_->take(data, infos)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, data_reader_->return_loan(data, infos)); + EXPECT_EQ(RETCODE_OK, data_reader_->take(data, infos)); + EXPECT_EQ(RETCODE_OK, data_reader_->return_loan(data, infos)); // Run test again state.run_test(data_reader_, steps); @@ -2095,7 +2110,7 @@ TEST_F(DataReaderTests, check_read_take_iteration) oarraystream out(data.message()); out << i; - EXPECT_EQ(data_writer_->write(&data, handles[i]), ReturnCode_t::RETCODE_OK); + EXPECT_EQ(data_writer_->write(&data, handles[i]), RETCODE_OK); } } @@ -2114,10 +2129,10 @@ TEST_F(DataReaderTests, check_read_take_iteration) NEW_VIEW_STATE, ALIVE_INSTANCE_STATE); - if ( ret == ReturnCode_t::RETCODE_OK) + if ( ret == RETCODE_OK) { received += data.length(); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, data_reader_->return_loan(data, infos)); + EXPECT_EQ(RETCODE_OK, data_reader_->return_loan(data, infos)); } else { @@ -2138,11 +2153,11 @@ TEST_F(DataReaderTests, check_read_take_iteration) SampleInfoSeq infos; EXPECT_EQ(data_reader_->take_instance(data, infos, 1, handles[i]), - ReturnCode_t::RETCODE_OK); + RETCODE_OK); EXPECT_EQ(static_cast(i), std::atoi(data[0].message().data())); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, data_reader_->return_loan(data, infos)); + EXPECT_EQ(RETCODE_OK, data_reader_->return_loan(data, infos)); } // Iterate over available instances with data and check all are retrieved @@ -2161,15 +2176,15 @@ TEST_F(DataReaderTests, check_read_take_iteration) 1, handle); - if (!!ret) + if (RETCODE_OK == ret) { received += data.length(); handle = infos[0].instance_handle; EXPECT_TRUE(std::atoi(data[0].message().data()) % 2 == 1); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, data_reader_->return_loan(data, infos)); + EXPECT_EQ(RETCODE_OK, data_reader_->return_loan(data, infos)); } } - while (ret == ReturnCode_t::RETCODE_OK); + while (ret == RETCODE_OK); EXPECT_EQ(received, max_handles); @@ -2188,15 +2203,15 @@ TEST_F(DataReaderTests, check_read_take_iteration) 1, handle); - if (!!ret) + if (RETCODE_OK == ret) { received += data.length(); handle = infos[0].instance_handle; EXPECT_TRUE(std::atoi(data[0].message().data()) % 2 == 1); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, data_reader_->return_loan(data, infos)); + EXPECT_EQ(RETCODE_OK, data_reader_->return_loan(data, infos)); } } - while (ret == ReturnCode_t::RETCODE_OK); + while (ret == RETCODE_OK); EXPECT_EQ(received, max_handles); } @@ -2241,8 +2256,8 @@ TEST_F(DataReaderTests, Deserialization_errors) static const Duration_t time_to_wait(0, 100 * 1000 * 1000); static constexpr int32_t num_samples = 10; - const ReturnCode_t& ok_code = ReturnCode_t::RETCODE_OK; - const ReturnCode_t& no_data_code = ReturnCode_t::RETCODE_NO_DATA; + const ReturnCode_t& ok_code = RETCODE_OK; + const ReturnCode_t& no_data_code = RETCODE_NO_DATA; DataWriterQos writer_qos = DATAWRITER_QOS_DEFAULT; writer_qos.history().kind = KEEP_LAST_HISTORY_QOS; @@ -2389,7 +2404,7 @@ void set_listener_test ( DataReaderListener* listener, StatusMask mask) { - ASSERT_EQ(reader->set_listener(listener, mask), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(reader->set_listener(listener, mask), RETCODE_OK); ASSERT_EQ(reader->get_status_mask(), mask); } @@ -2463,11 +2478,11 @@ TEST_F(DataReaderTests, get_listening_locators) // Calling on disabled reader should return NOT_ENABLED LocatorList locator_list; - EXPECT_EQ(ReturnCode_t::RETCODE_NOT_ENABLED, data_reader_->get_listening_locators(locator_list)); + EXPECT_EQ(RETCODE_NOT_ENABLED, data_reader_->get_listening_locators(locator_list)); // Enable and try again - EXPECT_EQ(ReturnCode_t::RETCODE_OK, data_reader_->enable()); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, data_reader_->get_listening_locators(locator_list)); + EXPECT_EQ(RETCODE_OK, data_reader_->enable()); + EXPECT_EQ(RETCODE_OK, data_reader_->get_listening_locators(locator_list)); EXPECT_EQ(locator_list.size(), 2u); bool unicast_found = false; @@ -2521,7 +2536,7 @@ TEST_F(DataReaderTests, check_key_history_wholesomeness_on_unmatch) ASSERT_TRUE(data_reader_->wait_for_unread_message(Duration_t(3, 0))); // now the writer is removed - ASSERT_EQ(publisher_->delete_datawriter(data_writer_), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(publisher_->delete_datawriter(data_writer_), RETCODE_OK); data_writer_ = nullptr; // here the DataReader History state must be coherent and don't loop endlessly @@ -2535,7 +2550,7 @@ TEST_F(DataReaderTests, check_key_history_wholesomeness_on_unmatch) // If the DataWriter is destroyed only the non-notified samples must be removed // this operation MUST succeed - ASSERT_EQ(res, ReturnCode_t::RETCODE_OK); + ASSERT_EQ(res, RETCODE_OK); data_reader_->return_loan(samples, infos); }); @@ -2596,7 +2611,7 @@ class DataReaderUnsupportedTests : public ::testing::Test /* * This test checks that the DataReader methods defined in the standard not yet implemented in FastDDS return - * ReturnCode_t::RETCODE_UNSUPPORTED. The following methods are checked: + * RETCODE_UNSUPPORTED. The following methods are checked: * 1. get_matched_publication_data * 2. create_querycondition * 3. get_matched_publications @@ -2625,7 +2640,7 @@ TEST_F(DataReaderUnsupportedTests, UnsupportedDataReaderMethods) builtin::PublicationBuiltinTopicData publication_data; InstanceHandle_t publication_handle; EXPECT_EQ( - ReturnCode_t::RETCODE_UNSUPPORTED, + RETCODE_UNSUPPORTED, data_reader->get_matched_publication_data(publication_data, publication_handle)); { @@ -2645,31 +2660,31 @@ TEST_F(DataReaderUnsupportedTests, UnsupportedDataReaderMethods) } std::vector publication_handles; - EXPECT_EQ(ReturnCode_t::RETCODE_UNSUPPORTED, data_reader->get_matched_publications(publication_handles)); + EXPECT_EQ(RETCODE_UNSUPPORTED, data_reader->get_matched_publications(publication_handles)); InstanceHandle_t key_handle; - EXPECT_EQ(ReturnCode_t::RETCODE_UNSUPPORTED, data_reader->get_key_value(nullptr, key_handle)); + EXPECT_EQ(RETCODE_UNSUPPORTED, data_reader->get_key_value(nullptr, key_handle)); - EXPECT_EQ(ReturnCode_t::RETCODE_UNSUPPORTED, data_reader->wait_for_historical_data({0, 1})); + EXPECT_EQ(RETCODE_UNSUPPORTED, data_reader->wait_for_historical_data({0, 1})); // Expected logWarnings: create_querycondition HELPER_WaitForEntries(1); - ASSERT_EQ(subscriber->delete_datareader(data_reader), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(participant->delete_subscriber(subscriber), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(participant->delete_topic(topic), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(subscriber->delete_datareader(data_reader), RETCODE_OK); + ASSERT_EQ(participant->delete_subscriber(subscriber), RETCODE_OK); + ASSERT_EQ(participant->delete_topic(topic), RETCODE_OK); + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), RETCODE_OK); } // Regression test for #12133. TEST_F(DataReaderTests, read_samples_with_future_changes) { - eprosima::fastrtps::LibrarySettingsAttributes att; - att.intraprocess_delivery = eprosima::fastrtps::INTRAPROCESS_OFF; - eprosima::fastrtps::xmlparser::XMLProfileManager::library_settings(att); + eprosima::fastdds::LibrarySettings att; + att.intraprocess_delivery = eprosima::fastdds::INTRAPROCESS_OFF; + DomainParticipantFactory::get_instance()->set_library_settings(att); static constexpr int32_t num_samples = 8; static constexpr int32_t expected_samples = 4; - const ReturnCode_t& ok_code = ReturnCode_t::RETCODE_OK; + const ReturnCode_t& ok_code = RETCODE_OK; bool start_dropping_acks = false; bool start_dropping_datas = false; static const Duration_t time_to_wait(0, 100 * 1000 * 1000); @@ -2747,7 +2762,7 @@ TEST_F(DataReaderTests, read_samples_with_future_changes) EXPECT_EQ(ok_code, data_reader_->take(data_seq, info_seq, num_samples, NOT_READ_SAMPLE_STATE)); check_collection(data_seq, true, num_samples, expected_samples); - ASSERT_EQ(publisher_->delete_datawriter(data_writer2), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(publisher_->delete_datawriter(data_writer2), RETCODE_OK); } // Delete contained entities test @@ -2795,10 +2810,10 @@ TEST_F(DataReaderTests, delete_contained_entities) ASSERT_EQ(query_condition, nullptr); // Should fail with outstanding ReadConditions - ASSERT_EQ(subscriber->delete_datareader(data_reader), ReturnCode_t::RETCODE_PRECONDITION_NOT_MET); + ASSERT_EQ(subscriber->delete_datareader(data_reader), RETCODE_PRECONDITION_NOT_MET); // Should not fail with outstanding ReadConditions - ASSERT_EQ(data_reader->delete_contained_entities(), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(data_reader->delete_contained_entities(), RETCODE_OK); } TEST_F(DataReaderTests, read_conditions_management) @@ -2822,7 +2837,7 @@ TEST_F(DataReaderTests, read_conditions_management) cond = reader.create_readcondition( sample_states, view_states, instance_states); EXPECT_NE(cond, nullptr); ReturnCode_t res = reader.delete_readcondition(cond); - EXPECT_EQ(res, ReturnCode_t::RETCODE_OK); + EXPECT_EQ(res, RETCODE_OK); // 3- Create several ReadConditions associated to the same masks (share implementation) std::forward_list conds; @@ -2834,7 +2849,7 @@ TEST_F(DataReaderTests, read_conditions_management) for (ReadCondition* c : conds) { - EXPECT_EQ(reader.delete_readcondition(c), ReturnCode_t::RETCODE_OK); + EXPECT_EQ(reader.delete_readcondition(c), RETCODE_OK); } conds.clear(); @@ -2850,7 +2865,7 @@ TEST_F(DataReaderTests, read_conditions_management) for (ReadCondition* c : conds) { - EXPECT_EQ(reader.delete_readcondition(c), ReturnCode_t::RETCODE_OK); + EXPECT_EQ(reader.delete_readcondition(c), RETCODE_OK); } conds.clear(); @@ -2864,7 +2879,7 @@ TEST_F(DataReaderTests, read_conditions_management) conds.push_front(reader.create_readcondition( ++sample_states, ++view_states, ++instance_states)); } - EXPECT_EQ(reader.delete_contained_entities(), ReturnCode_t::RETCODE_OK); + EXPECT_EQ(reader.delete_contained_entities(), RETCODE_OK); conds.clear(); // 6- Check a DataReader only handles its own ReadConditions @@ -2873,23 +2888,23 @@ TEST_F(DataReaderTests, read_conditions_management) cond = another_reader->create_readcondition(sample_states, view_states, instance_states); EXPECT_NE(cond, nullptr); - EXPECT_EQ(reader.delete_readcondition(cond), ReturnCode_t::RETCODE_PRECONDITION_NOT_MET); + EXPECT_EQ(reader.delete_readcondition(cond), RETCODE_PRECONDITION_NOT_MET); // 7- Check the DataReader cannot be deleted with outstanding conditions - EXPECT_EQ(subscriber_->delete_datareader(another_reader), ReturnCode_t::RETCODE_PRECONDITION_NOT_MET); + EXPECT_EQ(subscriber_->delete_datareader(another_reader), RETCODE_PRECONDITION_NOT_MET); // but delete_contained_entities() succeeds with outstanding ReadConditions - EXPECT_EQ(another_reader->delete_contained_entities(), ReturnCode_t::RETCODE_OK); + EXPECT_EQ(another_reader->delete_contained_entities(), RETCODE_OK); // no outstanding conditions (killed above) - EXPECT_EQ(subscriber_->delete_datareader(another_reader), ReturnCode_t::RETCODE_OK); + EXPECT_EQ(subscriber_->delete_datareader(another_reader), RETCODE_OK); } TEST_F(DataReaderTests, read_conditions_wait_on_SampleStateMask) { DataReaderQos reader_qos = DATAREADER_QOS_DEFAULT; - reader_qos.reliability().kind = eprosima::fastrtps::RELIABLE_RELIABILITY_QOS; + reader_qos.reliability().kind = RELIABLE_RELIABILITY_QOS; DataWriterQos writer_qos = DATAWRITER_QOS_DEFAULT; - writer_qos.reliability().kind = eprosima::fastrtps::RELIABLE_RELIABILITY_QOS; + writer_qos.reliability().kind = RELIABLE_RELIABILITY_QOS; create_entities(nullptr, reader_qos, SUBSCRIBER_QOS_DEFAULT, writer_qos); DataReader& data_reader = *data_reader_; @@ -2912,9 +2927,9 @@ TEST_F(DataReaderTests, read_conditions_wait_on_SampleStateMask) // Create the waitset and associate WaitSet ws; - EXPECT_EQ(ws.attach_condition(*read_cond), ReturnCode_t::RETCODE_OK); - EXPECT_EQ(ws.attach_condition(*not_read_cond), ReturnCode_t::RETCODE_OK); - EXPECT_EQ(ws.attach_condition(*any_read_cond), ReturnCode_t::RETCODE_OK); + EXPECT_EQ(ws.attach_condition(*read_cond), RETCODE_OK); + EXPECT_EQ(ws.attach_condition(*not_read_cond), RETCODE_OK); + EXPECT_EQ(ws.attach_condition(*any_read_cond), RETCODE_OK); // 1- Check NOT_READ_SAMPLE_STATE // Send sample from a background thread @@ -2931,7 +2946,7 @@ TEST_F(DataReaderTests, read_conditions_wait_on_SampleStateMask) }); ConditionSeq triggered; - EXPECT_EQ(ws.wait(triggered, 2.0), ReturnCode_t::RETCODE_OK); + EXPECT_EQ(ws.wait(triggered, 2.0), RETCODE_OK); bw.join(); // Check the data is there @@ -2954,16 +2969,16 @@ TEST_F(DataReaderTests, read_conditions_wait_on_SampleStateMask) datas, infos, 1, - not_read_cond), ReturnCode_t::RETCODE_OK); + not_read_cond), RETCODE_OK); triggered.clear(); - EXPECT_EQ(ws.wait(triggered, 1.0), ReturnCode_t::RETCODE_OK); + EXPECT_EQ(ws.wait(triggered, 1.0), RETCODE_OK); // Check data is good ASSERT_TRUE(infos[0].valid_data); EXPECT_EQ(datas[0].index(), 1u); EXPECT_EQ(datas[0].message(), test_message); - EXPECT_EQ(data_reader.return_loan(datas, infos), ReturnCode_t::RETCODE_OK); + EXPECT_EQ(data_reader.return_loan(datas, infos), RETCODE_OK); // Check the conditions triggered were the expected ones ASSERT_TRUE(read_cond->get_trigger_value()); @@ -2978,30 +2993,30 @@ TEST_F(DataReaderTests, read_conditions_wait_on_SampleStateMask) datas, infos, 1, - read_cond), ReturnCode_t::RETCODE_OK); + read_cond), RETCODE_OK); // Check data is good ASSERT_TRUE(infos[0].valid_data); EXPECT_EQ(datas[0].index(), 1u); EXPECT_EQ(datas[0].message(), test_message); - EXPECT_EQ(data_reader.return_loan(datas, infos), ReturnCode_t::RETCODE_OK); + EXPECT_EQ(data_reader.return_loan(datas, infos), RETCODE_OK); // Detach conditions & destroy - EXPECT_EQ(ws.detach_condition(*read_cond), ReturnCode_t::RETCODE_OK); - EXPECT_EQ(data_reader.delete_readcondition(read_cond), ReturnCode_t::RETCODE_OK); - EXPECT_EQ(ws.detach_condition(*not_read_cond), ReturnCode_t::RETCODE_OK); - EXPECT_EQ(data_reader.delete_readcondition(not_read_cond), ReturnCode_t::RETCODE_OK); - EXPECT_EQ(ws.detach_condition(*any_read_cond), ReturnCode_t::RETCODE_OK); - EXPECT_EQ(data_reader.delete_readcondition(any_read_cond), ReturnCode_t::RETCODE_OK); + EXPECT_EQ(ws.detach_condition(*read_cond), RETCODE_OK); + EXPECT_EQ(data_reader.delete_readcondition(read_cond), RETCODE_OK); + EXPECT_EQ(ws.detach_condition(*not_read_cond), RETCODE_OK); + EXPECT_EQ(data_reader.delete_readcondition(not_read_cond), RETCODE_OK); + EXPECT_EQ(ws.detach_condition(*any_read_cond), RETCODE_OK); + EXPECT_EQ(data_reader.delete_readcondition(any_read_cond), RETCODE_OK); } TEST_F(DataReaderTests, read_conditions_wait_on_ViewStateMask) { DataReaderQos reader_qos = DATAREADER_QOS_DEFAULT; - reader_qos.reliability().kind = eprosima::fastrtps::RELIABLE_RELIABILITY_QOS; + reader_qos.reliability().kind = RELIABLE_RELIABILITY_QOS; DataWriterQos writer_qos = DATAWRITER_QOS_DEFAULT; - writer_qos.reliability().kind = eprosima::fastrtps::RELIABLE_RELIABILITY_QOS; + writer_qos.reliability().kind = RELIABLE_RELIABILITY_QOS; create_entities(nullptr, reader_qos, SUBSCRIBER_QOS_DEFAULT, writer_qos); DataReader& data_reader = *data_reader_; @@ -3024,9 +3039,9 @@ TEST_F(DataReaderTests, read_conditions_wait_on_ViewStateMask) // Create the waitset and associate WaitSet ws; - EXPECT_EQ(ws.attach_condition(*view_cond), ReturnCode_t::RETCODE_OK); - EXPECT_EQ(ws.attach_condition(*not_view_cond), ReturnCode_t::RETCODE_OK); - EXPECT_EQ(ws.attach_condition(*any_view_cond), ReturnCode_t::RETCODE_OK); + EXPECT_EQ(ws.attach_condition(*view_cond), RETCODE_OK); + EXPECT_EQ(ws.attach_condition(*not_view_cond), RETCODE_OK); + EXPECT_EQ(ws.attach_condition(*any_view_cond), RETCODE_OK); // 1- Check NEW_VIEW_STATE // Send sample from a background thread @@ -3043,7 +3058,7 @@ TEST_F(DataReaderTests, read_conditions_wait_on_ViewStateMask) }); ConditionSeq triggered; - EXPECT_EQ(ws.wait(triggered, 2.0), ReturnCode_t::RETCODE_OK); + EXPECT_EQ(ws.wait(triggered, 2.0), RETCODE_OK); bw.join(); // Check the data is there @@ -3066,16 +3081,16 @@ TEST_F(DataReaderTests, read_conditions_wait_on_ViewStateMask) datas, infos, 1, - view_cond), ReturnCode_t::RETCODE_OK); + view_cond), RETCODE_OK); triggered.clear(); - EXPECT_EQ(ws.wait(triggered, 1.0), ReturnCode_t::RETCODE_OK); + EXPECT_EQ(ws.wait(triggered, 1.0), RETCODE_OK); // Check data is good ASSERT_TRUE(infos[0].valid_data); EXPECT_EQ(datas[0].index(), 1u); EXPECT_EQ(datas[0].message(), test_message); - EXPECT_EQ(data_reader.return_loan(datas, infos), ReturnCode_t::RETCODE_OK); + EXPECT_EQ(data_reader.return_loan(datas, infos), RETCODE_OK); // Check the conditions triggered were the expected ones ASSERT_FALSE(view_cond->get_trigger_value()); @@ -3086,21 +3101,21 @@ TEST_F(DataReaderTests, read_conditions_wait_on_ViewStateMask) EXPECT_NE(std::find(triggered.begin(), triggered.end(), any_view_cond), triggered.end()); // Detach conditions & destroy - EXPECT_EQ(ws.detach_condition(*view_cond), ReturnCode_t::RETCODE_OK); - EXPECT_EQ(data_reader.delete_readcondition(view_cond), ReturnCode_t::RETCODE_OK); - EXPECT_EQ(ws.detach_condition(*not_view_cond), ReturnCode_t::RETCODE_OK); - EXPECT_EQ(data_reader.delete_readcondition(not_view_cond), ReturnCode_t::RETCODE_OK); - EXPECT_EQ(ws.detach_condition(*any_view_cond), ReturnCode_t::RETCODE_OK); - EXPECT_EQ(data_reader.delete_readcondition(any_view_cond), ReturnCode_t::RETCODE_OK); + EXPECT_EQ(ws.detach_condition(*view_cond), RETCODE_OK); + EXPECT_EQ(data_reader.delete_readcondition(view_cond), RETCODE_OK); + EXPECT_EQ(ws.detach_condition(*not_view_cond), RETCODE_OK); + EXPECT_EQ(data_reader.delete_readcondition(not_view_cond), RETCODE_OK); + EXPECT_EQ(ws.detach_condition(*any_view_cond), RETCODE_OK); + EXPECT_EQ(data_reader.delete_readcondition(any_view_cond), RETCODE_OK); } TEST_F(DataReaderTests, read_conditions_wait_on_InstanceStateMask) { DataReaderQos reader_qos = DATAREADER_QOS_DEFAULT; - reader_qos.reliability().kind = eprosima::fastrtps::RELIABLE_RELIABILITY_QOS; + reader_qos.reliability().kind = RELIABLE_RELIABILITY_QOS; DataWriterQos writer_qos = DATAWRITER_QOS_DEFAULT; - writer_qos.reliability().kind = eprosima::fastrtps::RELIABLE_RELIABILITY_QOS; + writer_qos.reliability().kind = RELIABLE_RELIABILITY_QOS; create_entities(nullptr, reader_qos, SUBSCRIBER_QOS_DEFAULT, writer_qos); DataReader& data_reader = *data_reader_; @@ -3127,10 +3142,10 @@ TEST_F(DataReaderTests, read_conditions_wait_on_InstanceStateMask) // Create the waitset and associate WaitSet ws; - EXPECT_EQ(ws.attach_condition(*alive_cond), ReturnCode_t::RETCODE_OK); - EXPECT_EQ(ws.attach_condition(*disposed_cond), ReturnCode_t::RETCODE_OK); - EXPECT_EQ(ws.attach_condition(*no_writer_cond), ReturnCode_t::RETCODE_OK); - EXPECT_EQ(ws.attach_condition(*any_cond), ReturnCode_t::RETCODE_OK); + EXPECT_EQ(ws.attach_condition(*alive_cond), RETCODE_OK); + EXPECT_EQ(ws.attach_condition(*disposed_cond), RETCODE_OK); + EXPECT_EQ(ws.attach_condition(*no_writer_cond), RETCODE_OK); + EXPECT_EQ(ws.attach_condition(*any_cond), RETCODE_OK); // 1- Check ALIVE_INSTANCE_STATE // Send sample from a background thread @@ -3148,7 +3163,7 @@ TEST_F(DataReaderTests, read_conditions_wait_on_InstanceStateMask) }); ConditionSeq triggered; - EXPECT_EQ(ws.wait(triggered, 2.0), ReturnCode_t::RETCODE_OK); + EXPECT_EQ(ws.wait(triggered, 2.0), RETCODE_OK); bw.join(); // Check the data is there @@ -3166,10 +3181,10 @@ TEST_F(DataReaderTests, read_conditions_wait_on_InstanceStateMask) // 2 - Check NOT_ALIVE_DISPOSED_INSTANCE_STATE // unregister the instance - EXPECT_EQ(data_writer.unregister_instance(&msg, HANDLE_NIL), ReturnCode_t::RETCODE_OK); + EXPECT_EQ(data_writer.unregister_instance(&msg, HANDLE_NIL), RETCODE_OK); triggered.clear(); - EXPECT_EQ(ws.wait(triggered, 1.0), ReturnCode_t::RETCODE_OK); + EXPECT_EQ(ws.wait(triggered, 1.0), RETCODE_OK); // Check the conditions triggered were the expected ones ASSERT_FALSE(alive_cond->get_trigger_value()); @@ -3190,12 +3205,12 @@ TEST_F(DataReaderTests, read_conditions_wait_on_InstanceStateMask) infos, 1, HANDLE_NIL, - disposed_cond), ReturnCode_t::RETCODE_OK); + disposed_cond), RETCODE_OK); // Check data is bad because the sample for instance 1 was unregistered ASSERT_FALSE(infos[0].valid_data); InstanceHandle_t prev_handle = infos[0].instance_handle; - EXPECT_EQ(data_reader.return_loan(datas, infos), ReturnCode_t::RETCODE_OK); + EXPECT_EQ(data_reader.return_loan(datas, infos), RETCODE_OK); // new instance msg.index(2u); @@ -3206,21 +3221,21 @@ TEST_F(DataReaderTests, read_conditions_wait_on_InstanceStateMask) infos, 1, prev_handle, - alive_cond), ReturnCode_t::RETCODE_OK); + alive_cond), RETCODE_OK); // Check data is good ASSERT_TRUE(infos[0].valid_data); EXPECT_EQ(datas[0].index(), 2u); EXPECT_EQ(datas[0].message(), test_message); - EXPECT_EQ(data_reader.return_loan(datas, infos), ReturnCode_t::RETCODE_OK); + EXPECT_EQ(data_reader.return_loan(datas, infos), RETCODE_OK); // 5 - Check NOT_ALIVE_NO_WRITERS_INSTANCE_STATE // delete the writer to remove all writers from a new instance - ASSERT_EQ(publisher_->delete_datawriter(data_writer_), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(publisher_->delete_datawriter(data_writer_), RETCODE_OK); data_writer_ = nullptr; triggered.clear(); - EXPECT_EQ(ws.wait(triggered, 1.0), ReturnCode_t::RETCODE_OK); + EXPECT_EQ(ws.wait(triggered, 1.0), RETCODE_OK); // Check the conditions triggered were the expected ones ASSERT_FALSE(alive_cond->get_trigger_value()); @@ -3233,14 +3248,14 @@ TEST_F(DataReaderTests, read_conditions_wait_on_InstanceStateMask) EXPECT_NE(std::find(triggered.begin(), triggered.end(), any_cond), triggered.end()); // Detach conditions & destroy - EXPECT_EQ(ws.detach_condition(*alive_cond), ReturnCode_t::RETCODE_OK); - EXPECT_EQ(data_reader.delete_readcondition(alive_cond), ReturnCode_t::RETCODE_OK); - EXPECT_EQ(ws.detach_condition(*disposed_cond), ReturnCode_t::RETCODE_OK); - EXPECT_EQ(data_reader.delete_readcondition(disposed_cond), ReturnCode_t::RETCODE_OK); - EXPECT_EQ(ws.detach_condition(*no_writer_cond), ReturnCode_t::RETCODE_OK); - EXPECT_EQ(data_reader.delete_readcondition(no_writer_cond), ReturnCode_t::RETCODE_OK); - EXPECT_EQ(ws.detach_condition(*any_cond), ReturnCode_t::RETCODE_OK); - EXPECT_EQ(data_reader.delete_readcondition(any_cond), ReturnCode_t::RETCODE_OK); + EXPECT_EQ(ws.detach_condition(*alive_cond), RETCODE_OK); + EXPECT_EQ(data_reader.delete_readcondition(alive_cond), RETCODE_OK); + EXPECT_EQ(ws.detach_condition(*disposed_cond), RETCODE_OK); + EXPECT_EQ(data_reader.delete_readcondition(disposed_cond), RETCODE_OK); + EXPECT_EQ(ws.detach_condition(*no_writer_cond), RETCODE_OK); + EXPECT_EQ(data_reader.delete_readcondition(no_writer_cond), RETCODE_OK); + EXPECT_EQ(ws.detach_condition(*any_cond), RETCODE_OK); + EXPECT_EQ(data_reader.delete_readcondition(any_cond), RETCODE_OK); } /* @@ -3324,15 +3339,15 @@ TEST_F(DataReaderTests, InstancePolicyAllocationConsistencyNotKeyed) // This allows to change inmutable policies SubscriberQos subscriber_qos = SUBSCRIBER_QOS_DEFAULT; subscriber_qos.entity_factory().autoenable_created_entities = false; - ASSERT_EQ(ReturnCode_t::RETCODE_OK, subscriber->set_qos(subscriber_qos)); + ASSERT_EQ(RETCODE_OK, subscriber->set_qos(subscriber_qos)); // Next QoS config checks the default qos configuration, - // set_qos() should return ReturnCode_t::RETCODE_OK = 0 + // set_qos() should return RETCODE_OK = 0 DataReaderQos qos2 = DATAREADER_QOS_DEFAULT; DataReader* default_data_reader2 = subscriber->create_datareader(topic, qos2); ASSERT_NE(default_data_reader2, nullptr); - ASSERT_EQ(ReturnCode_t::RETCODE_OK, default_data_reader2->set_qos(qos2)); + ASSERT_EQ(RETCODE_OK, default_data_reader2->set_qos(qos2)); // Below an ampliation of the last comprobation, for which it is proved the case of < 0 (-1), // which also means infinite value. @@ -3342,35 +3357,35 @@ TEST_F(DataReaderTests, InstancePolicyAllocationConsistencyNotKeyed) qos2.resource_limits().max_instances = -1; qos2.resource_limits().max_samples_per_instance = -1; - ASSERT_EQ(ReturnCode_t::RETCODE_OK, default_data_reader2->set_qos(qos2)); + ASSERT_EQ(RETCODE_OK, default_data_reader2->set_qos(qos2)); // Next QoS config checks that if user sets max_samples < ( max_instances * max_samples_per_instance ) , - // set_qos() should return ReturnCode_t::RETCODE_OK = 0 + // set_qos() should return RETCODE_OK = 0 // By not using instances, instance allocation consistency is not checked. qos2.resource_limits().max_samples = 4999; qos2.resource_limits().max_instances = 10; qos2.resource_limits().max_samples_per_instance = 500; - ASSERT_EQ(ReturnCode_t::RETCODE_OK, default_data_reader2->set_qos(qos2)); + ASSERT_EQ(RETCODE_OK, default_data_reader2->set_qos(qos2)); // Next QoS config checks that if user sets max_samples > ( max_instances * max_samples_per_instance ) , - // set_qos() should return ReturnCode_t::RETCODE_OK = 0 + // set_qos() should return RETCODE_OK = 0 // By not using instances, instance allocation consistency is not checked. qos2.resource_limits().max_samples = 5001; qos2.resource_limits().max_instances = 10; qos2.resource_limits().max_samples_per_instance = 500; - ASSERT_EQ(ReturnCode_t::RETCODE_OK, default_data_reader2->set_qos(qos2)); + ASSERT_EQ(RETCODE_OK, default_data_reader2->set_qos(qos2)); // Next QoS config checks that if user sets max_samples infinite // and ( max_instances * max_samples_per_instance ) finite, - // set_qos() should return ReturnCode_t::RETCODE_OK = 0 + // set_qos() should return RETCODE_OK = 0 // By not using instances, instance allocation consistency is not checked. qos2.resource_limits().max_samples = 0; qos2.resource_limits().max_instances = 10; qos2.resource_limits().max_samples_per_instance = 500; - ASSERT_EQ(ReturnCode_t::RETCODE_OK, default_data_reader2->set_qos(qos2)); + ASSERT_EQ(RETCODE_OK, default_data_reader2->set_qos(qos2)); } /* @@ -3460,15 +3475,15 @@ TEST_F(DataReaderTests, InstancePolicyAllocationConsistencyKeyed) // This allows to change inmutable policies SubscriberQos subscriber_qos = SUBSCRIBER_QOS_DEFAULT; subscriber_qos.entity_factory().autoenable_created_entities = false; - ASSERT_EQ(ReturnCode_t::RETCODE_OK, subscriber->set_qos(subscriber_qos)); + ASSERT_EQ(RETCODE_OK, subscriber->set_qos(subscriber_qos)); // Next QoS config checks the default qos configuration, - // set_qos() should return ReturnCode_t::RETCODE_OK = 0, as the by default values are already infinite. + // set_qos() should return RETCODE_OK = 0, as the by default values are already infinite. DataReaderQos qos2 = DATAREADER_QOS_DEFAULT; DataReader* default_data_reader2 = subscriber->create_datareader(topic, qos2); ASSERT_NE(default_data_reader2, nullptr); - ASSERT_EQ(ReturnCode_t::RETCODE_OK, default_data_reader2->set_qos(qos2)); + ASSERT_EQ(RETCODE_OK, default_data_reader2->set_qos(qos2)); // Below an ampliation of the last comprobation, for which it is proved the case of < 0 (-1), // which also means infinite value. @@ -3477,7 +3492,7 @@ TEST_F(DataReaderTests, InstancePolicyAllocationConsistencyKeyed) qos2.resource_limits().max_instances = -1; qos2.resource_limits().max_samples_per_instance = -1; - ASSERT_EQ(ReturnCode_t::RETCODE_OK, default_data_reader2->set_qos(qos2)); + ASSERT_EQ(RETCODE_OK, default_data_reader2->set_qos(qos2)); // Next QoS config checks that if user sets max_samples < ( max_instances * max_samples_per_instance ) , // set_qos() should return a value != 0 (not OK) @@ -3485,32 +3500,32 @@ TEST_F(DataReaderTests, InstancePolicyAllocationConsistencyKeyed) qos2.resource_limits().max_instances = 10; qos2.resource_limits().max_samples_per_instance = 500; - ASSERT_NE(ReturnCode_t::RETCODE_OK, default_data_reader2->set_qos(qos2)); + ASSERT_NE(RETCODE_OK, default_data_reader2->set_qos(qos2)); // Next QoS config checks that if user sets max_samples > ( max_instances * max_samples_per_instance ) , - // set_qos() should return ReturnCode_t::RETCODE_OK = 0. + // set_qos() should return RETCODE_OK = 0. qos2.resource_limits().max_samples = 5001; qos2.resource_limits().max_instances = 10; qos2.resource_limits().max_samples_per_instance = 500; - ASSERT_EQ(ReturnCode_t::RETCODE_OK, default_data_reader2->set_qos(qos2)); + ASSERT_EQ(RETCODE_OK, default_data_reader2->set_qos(qos2)); // Next QoS config checks that if user sets max_samples = ( max_instances * max_samples_per_instance ) , - // set_qos() should return ReturnCode_t::RETCODE_OK = 0. + // set_qos() should return RETCODE_OK = 0. qos2.resource_limits().max_samples = 5000; qos2.resource_limits().max_instances = 10; qos2.resource_limits().max_samples_per_instance = 500; - ASSERT_EQ(ReturnCode_t::RETCODE_OK, default_data_reader2->set_qos(qos2)); + ASSERT_EQ(RETCODE_OK, default_data_reader2->set_qos(qos2)); // Next QoS config checks that if user sets max_samples infinite // and ( max_instances * max_samples_per_instance ) finite, - // set_qos() should return ReturnCode_t::RETCODE_OK = 0. + // set_qos() should return RETCODE_OK = 0. qos2.resource_limits().max_samples = 0; qos2.resource_limits().max_instances = 10; qos2.resource_limits().max_samples_per_instance = 500; - ASSERT_EQ(ReturnCode_t::RETCODE_OK, default_data_reader2->set_qos(qos2)); + ASSERT_EQ(RETCODE_OK, default_data_reader2->set_qos(qos2)); } /* @@ -3588,78 +3603,78 @@ TEST_F(DataReaderTests, UpdateInmutableQos) // Resource limits DataReaderQos reader_qos = DATAREADER_QOS_DEFAULT; reader_qos.resource_limits().max_samples = reader_qos.resource_limits().max_samples - 1; - ASSERT_EQ(ReturnCode_t::RETCODE_IMMUTABLE_POLICY, data_reader->set_qos(reader_qos)); + ASSERT_EQ(RETCODE_IMMUTABLE_POLICY, data_reader->set_qos(reader_qos)); // History reader_qos = DATAREADER_QOS_DEFAULT; reader_qos.history().kind = KEEP_ALL_HISTORY_QOS; - ASSERT_EQ(ReturnCode_t::RETCODE_IMMUTABLE_POLICY, data_reader->set_qos(reader_qos)); + ASSERT_EQ(RETCODE_IMMUTABLE_POLICY, data_reader->set_qos(reader_qos)); reader_qos = DATAREADER_QOS_DEFAULT; reader_qos.history().depth = reader_qos.history().depth + 1; - ASSERT_EQ(ReturnCode_t::RETCODE_IMMUTABLE_POLICY, data_reader->set_qos(reader_qos)); + ASSERT_EQ(RETCODE_IMMUTABLE_POLICY, data_reader->set_qos(reader_qos)); // Durability reader_qos = DATAREADER_QOS_DEFAULT; reader_qos.durability().kind = TRANSIENT_LOCAL_DURABILITY_QOS; - ASSERT_EQ(ReturnCode_t::RETCODE_IMMUTABLE_POLICY, data_reader->set_qos(reader_qos)); + ASSERT_EQ(RETCODE_IMMUTABLE_POLICY, data_reader->set_qos(reader_qos)); // Liveliness reader_qos = DATAREADER_QOS_DEFAULT; reader_qos.liveliness().kind = MANUAL_BY_TOPIC_LIVELINESS_QOS; - ASSERT_EQ(ReturnCode_t::RETCODE_IMMUTABLE_POLICY, data_reader->set_qos(reader_qos)); + ASSERT_EQ(RETCODE_IMMUTABLE_POLICY, data_reader->set_qos(reader_qos)); reader_qos = DATAREADER_QOS_DEFAULT; reader_qos.liveliness().lease_duration = Duration_t{123, 123}; - ASSERT_EQ(ReturnCode_t::RETCODE_IMMUTABLE_POLICY, data_reader->set_qos(reader_qos)); + ASSERT_EQ(RETCODE_IMMUTABLE_POLICY, data_reader->set_qos(reader_qos)); reader_qos = DATAREADER_QOS_DEFAULT; reader_qos.liveliness().announcement_period = Duration_t{123, 123}; - ASSERT_EQ(ReturnCode_t::RETCODE_IMMUTABLE_POLICY, data_reader->set_qos(reader_qos)); + ASSERT_EQ(RETCODE_IMMUTABLE_POLICY, data_reader->set_qos(reader_qos)); // Relibility reader_qos = DATAREADER_QOS_DEFAULT; reader_qos.reliability().kind = RELIABLE_RELIABILITY_QOS; - ASSERT_EQ(ReturnCode_t::RETCODE_IMMUTABLE_POLICY, data_reader->set_qos(reader_qos)); + ASSERT_EQ(RETCODE_IMMUTABLE_POLICY, data_reader->set_qos(reader_qos)); // Ownsership reader_qos = DATAREADER_QOS_DEFAULT; reader_qos.ownership().kind = EXCLUSIVE_OWNERSHIP_QOS; - ASSERT_EQ(ReturnCode_t::RETCODE_IMMUTABLE_POLICY, data_reader->set_qos(reader_qos)); + ASSERT_EQ(RETCODE_IMMUTABLE_POLICY, data_reader->set_qos(reader_qos)); // Destination order (currently reports unsupported) reader_qos = DATAREADER_QOS_DEFAULT; reader_qos.destination_order().kind = BY_SOURCE_TIMESTAMP_DESTINATIONORDER_QOS; - ASSERT_EQ(ReturnCode_t::RETCODE_UNSUPPORTED, data_reader->set_qos(reader_qos)); + ASSERT_EQ(RETCODE_UNSUPPORTED, data_reader->set_qos(reader_qos)); // Reader resource limits reader_qos = DATAREADER_QOS_DEFAULT; reader_qos.reader_resource_limits().matched_publisher_allocation.maximum = reader_qos.reader_resource_limits().matched_publisher_allocation.maximum - 1; - ASSERT_EQ(ReturnCode_t::RETCODE_IMMUTABLE_POLICY, data_reader->set_qos(reader_qos)); + ASSERT_EQ(RETCODE_IMMUTABLE_POLICY, data_reader->set_qos(reader_qos)); // Datasharing reader_qos = DATAREADER_QOS_DEFAULT; reader_qos.data_sharing().off(); - ASSERT_EQ(ReturnCode_t::RETCODE_IMMUTABLE_POLICY, data_reader->set_qos(reader_qos)); + ASSERT_EQ(RETCODE_IMMUTABLE_POLICY, data_reader->set_qos(reader_qos)); reader_qos = DATAREADER_QOS_DEFAULT; reader_qos.data_sharing().automatic("."); - ASSERT_EQ(ReturnCode_t::RETCODE_IMMUTABLE_POLICY, data_reader->set_qos(reader_qos)); + ASSERT_EQ(RETCODE_IMMUTABLE_POLICY, data_reader->set_qos(reader_qos)); reader_qos = DATAREADER_QOS_DEFAULT; reader_qos.data_sharing().add_domain_id(static_cast(12)); - ASSERT_EQ(ReturnCode_t::RETCODE_IMMUTABLE_POLICY, data_reader->set_qos(reader_qos)); + ASSERT_EQ(RETCODE_IMMUTABLE_POLICY, data_reader->set_qos(reader_qos)); reader_qos = DATAREADER_QOS_DEFAULT; reader_qos.data_sharing().data_sharing_listener_thread().priority = reader_qos.data_sharing().data_sharing_listener_thread().priority + 1; - ASSERT_EQ(ReturnCode_t::RETCODE_IMMUTABLE_POLICY, data_reader->set_qos(reader_qos)); + ASSERT_EQ(RETCODE_IMMUTABLE_POLICY, data_reader->set_qos(reader_qos)); // Unique network flows reader_qos = DATAREADER_QOS_DEFAULT; reader_qos.properties().properties().push_back({"fastdds.unique_network_flows", "true"}); - ASSERT_EQ(ReturnCode_t::RETCODE_IMMUTABLE_POLICY, data_reader->set_qos(reader_qos)); + ASSERT_EQ(RETCODE_IMMUTABLE_POLICY, data_reader->set_qos(reader_qos)); /* Cleanup */ participant->delete_contained_entities(); diff --git a/test/unittest/dds/subscriber/SubscriberTests.cpp b/test/unittest/dds/subscriber/SubscriberTests.cpp index 1c0afb37849..9bf36a56724 100644 --- a/test/unittest/dds/subscriber/SubscriberTests.cpp +++ b/test/unittest/dds/subscriber/SubscriberTests.cpp @@ -12,44 +12,29 @@ // See the License for the specific language governing permissions and // limitations under the License. +#include #include #include -#include - -#include -#include -#include -#include -#include -#include -#include #include #include #include #include #include +#include #include #include #include #include #include #include -#include -#include -#include -#include +#include namespace eprosima { namespace fastdds { namespace dds { -using fastrtps::PublisherAttributes; -using fastrtps::SubscriberAttributes; using fastrtps::rtps::PropertyPolicyHelper; -using fastrtps::xmlparser::XMLProfileManager; -using fastrtps::xmlparser::XMLP_ret; - class FooType { @@ -235,40 +220,24 @@ TEST(SubscriberTests, ChangeSubscriberQos) ASSERT_NE(subscriber, nullptr); SubscriberQos qos; - ASSERT_EQ(subscriber->get_qos(qos), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(subscriber->get_qos(qos), RETCODE_OK); ASSERT_EQ(qos, SUBSCRIBER_QOS_DEFAULT); qos.entity_factory().autoenable_created_entities = false; - ASSERT_EQ(subscriber->set_qos(qos), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(subscriber->set_qos(qos), RETCODE_OK); SubscriberQos pqos; - ASSERT_EQ(subscriber->get_qos(pqos), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(subscriber->get_qos(pqos), RETCODE_OK); ASSERT_TRUE(qos == pqos); ASSERT_EQ(pqos.entity_factory().autoenable_created_entities, false); - ASSERT_TRUE(participant->delete_subscriber(subscriber) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(participant->delete_subscriber(subscriber) == RETCODE_OK); + ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == RETCODE_OK); } -TEST(SubscriberTests, ChangePSMSubscriberQos) -{ - ::dds::domain::DomainParticipant participant = ::dds::domain::DomainParticipant(0, PARTICIPANT_QOS_DEFAULT); - ::dds::sub::Subscriber subscriber = ::dds::sub::Subscriber(participant); - - ::dds::sub::qos::SubscriberQos qos = subscriber.qos(); - ASSERT_EQ(qos, SUBSCRIBER_QOS_DEFAULT); - - qos.entity_factory().autoenable_created_entities = false; - ASSERT_NO_THROW(subscriber.qos(qos)); - ::dds::sub::qos::SubscriberQos pqos = subscriber.qos(); - - ASSERT_TRUE(qos == pqos); - ASSERT_EQ(pqos.entity_factory().autoenable_created_entities, false); -} - TEST(SubscriberTests, ChangeDefaultDataReaderQos) { DomainParticipant* participant = @@ -379,7 +348,7 @@ TEST(SubscriberTests, ChangeDefaultDataReaderQos) // .data_sharing qos.data_sharing().on("/"); - ASSERT_TRUE(subscriber->set_default_datareader_qos(qos) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(subscriber->set_default_datareader_qos(qos) == RETCODE_OK); DataReaderQos wqos; subscriber->get_default_datareader_qos(wqos); @@ -511,26 +480,8 @@ TEST(SubscriberTests, ChangeDefaultDataReaderQos) EXPECT_EQ(qos, wqos); - ASSERT_TRUE(participant->delete_subscriber(subscriber) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == ReturnCode_t::RETCODE_OK); -} - -TEST(SubscriberTests, ChangePSMDefaultDataReaderQos) -{ - ::dds::domain::DomainParticipant participant = ::dds::domain::DomainParticipant(0, PARTICIPANT_QOS_DEFAULT); - ::dds::sub::Subscriber subscriber = ::dds::sub::Subscriber(participant, SUBSCRIBER_QOS_DEFAULT); - - ::dds::sub::qos::DataReaderQos qos = subscriber.default_datareader_qos(); - ASSERT_EQ(qos, DATAREADER_QOS_DEFAULT); - - qos.reliability().kind = BEST_EFFORT_RELIABILITY_QOS; - - ASSERT_NO_THROW(subscriber.default_datareader_qos(qos)); - - ::dds::sub::qos::DataReaderQos rqos = subscriber.default_datareader_qos(); - - ASSERT_EQ(qos, rqos); - ASSERT_EQ(rqos.reliability().kind, BEST_EFFORT_RELIABILITY_QOS); + ASSERT_TRUE(participant->delete_subscriber(subscriber) == RETCODE_OK); + ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == RETCODE_OK); } TEST(SubscriberTests, GetSubscriberParticipant) @@ -543,16 +494,8 @@ TEST(SubscriberTests, GetSubscriberParticipant) ASSERT_EQ(subscriber->get_participant(), participant); - ASSERT_TRUE(participant->delete_subscriber(subscriber) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == ReturnCode_t::RETCODE_OK); -} - -TEST(SubscriberTests, GetPSMSubscriberParticipant) -{ - ::dds::domain::DomainParticipant participant = ::dds::domain::DomainParticipant(0, PARTICIPANT_QOS_DEFAULT); - ::dds::sub::Subscriber subscriber = ::dds::sub::Subscriber(participant, SUBSCRIBER_QOS_DEFAULT); - - ASSERT_EQ(subscriber.participant().delegate().get(), participant.delegate().get()); + ASSERT_TRUE(participant->delete_subscriber(subscriber) == RETCODE_OK); + ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == RETCODE_OK); } TEST(SubscriberTests, CreateDataReader) @@ -573,10 +516,10 @@ TEST(SubscriberTests, CreateDataReader) DataReader* data_reader = subscriber->create_datareader(topic, DATAREADER_QOS_DEFAULT); ASSERT_NE(data_reader, nullptr); - ASSERT_EQ(subscriber->delete_datareader(data_reader), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(participant->delete_topic(topic), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(participant->delete_subscriber(subscriber), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(subscriber->delete_datareader(data_reader), RETCODE_OK); + ASSERT_EQ(participant->delete_topic(topic), RETCODE_OK); + ASSERT_EQ(participant->delete_subscriber(subscriber), RETCODE_OK); + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), RETCODE_OK); } void check_datareader_with_profile ( @@ -586,53 +529,10 @@ void check_datareader_with_profile ( DataReaderQos qos; datareader->get_qos(qos); - SubscriberAttributes subscriber_atts; - XMLProfileManager::fillSubscriberAttributes(profile_name, subscriber_atts); - - //Values taken from profile - ASSERT_TRUE( - qos.reader_resource_limits().matched_publisher_allocation == - subscriber_atts.matched_publisher_allocation); - if (subscriber_atts.qos.m_partition.names().empty()) - { - ASSERT_TRUE(qos.properties() == subscriber_atts.properties); - } - else - { - ASSERT_NE(PropertyPolicyHelper::find_property(qos.properties(), "partitions"), nullptr); - for (auto partition: subscriber_atts.qos.m_partition.names()) - { - ASSERT_NE(PropertyPolicyHelper::find_property(qos.properties(), "partitions")->find( - partition), std::string::npos); - } - } - ASSERT_TRUE(qos.expects_inline_qos() == subscriber_atts.expectsInlineQos); - ASSERT_TRUE(qos.endpoint().unicast_locator_list == subscriber_atts.unicastLocatorList); - ASSERT_TRUE(qos.endpoint().multicast_locator_list == subscriber_atts.multicastLocatorList); - ASSERT_TRUE(qos.endpoint().remote_locator_list == subscriber_atts.remoteLocatorList); - ASSERT_TRUE(qos.endpoint().history_memory_policy == subscriber_atts.historyMemoryPolicy); - ASSERT_TRUE(qos.endpoint().user_defined_id == subscriber_atts.getUserDefinedID()); - ASSERT_TRUE(qos.endpoint().entity_id == subscriber_atts.getEntityID()); - ASSERT_TRUE(qos.reliable_reader_qos().times == subscriber_atts.times); - ASSERT_TRUE(qos.reliable_reader_qos().disable_positive_ACKs == subscriber_atts.qos.m_disablePositiveACKs); - ASSERT_TRUE(qos.durability() == subscriber_atts.qos.m_durability); - ASSERT_TRUE(qos.durability_service() == subscriber_atts.qos.m_durabilityService); - ASSERT_TRUE(qos.deadline() == subscriber_atts.qos.m_deadline); - ASSERT_TRUE(qos.latency_budget() == subscriber_atts.qos.m_latencyBudget); - ASSERT_TRUE(qos.liveliness() == subscriber_atts.qos.m_liveliness); - ASSERT_TRUE(qos.reliability() == subscriber_atts.qos.m_reliability); - ASSERT_TRUE(qos.lifespan() == subscriber_atts.qos.m_lifespan); - ASSERT_TRUE(qos.user_data().data_vec() == subscriber_atts.qos.m_userData.data_vec()); - ASSERT_TRUE(qos.ownership() == subscriber_atts.qos.m_ownership); - ASSERT_TRUE(qos.destination_order() == subscriber_atts.qos.m_destinationOrder); - ASSERT_TRUE(qos.type_consistency().type_consistency == subscriber_atts.qos.type_consistency); - ASSERT_TRUE(qos.type_consistency().representation == subscriber_atts.qos.representation); - ASSERT_TRUE(qos.time_based_filter() == subscriber_atts.qos.m_timeBasedFilter); - ASSERT_TRUE(qos.history() == subscriber_atts.topic.historyQos); - ASSERT_TRUE(qos.resource_limits() == subscriber_atts.topic.resourceLimitsQos); - - //Values not implemented on attributes (taken from default QoS) - ASSERT_TRUE(qos.reader_data_lifecycle() == DATAREADER_QOS_DEFAULT.reader_data_lifecycle()); + DataReaderQos profile_qos; + EXPECT_EQ(datareader->get_subscriber()->get_datareader_qos_from_profile(profile_name, profile_qos), + RETCODE_OK); + EXPECT_EQ(qos, profile_qos); } TEST(SubscriberTests, CreateDataReaderWithProfile) @@ -649,17 +549,17 @@ TEST(SubscriberTests, CreateDataReaderWithProfile) DataReader* default_datareader = subscriber->create_datareader(topic, DATAREADER_QOS_DEFAULT); ASSERT_NE(default_datareader, nullptr); check_datareader_with_profile(default_datareader, "test_default_subscriber_profile"); - ASSERT_TRUE(subscriber->delete_datareader(default_datareader) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(subscriber->delete_datareader(default_datareader) == RETCODE_OK); //participant using non-default profile DataReader* datareader = subscriber->create_datareader_with_profile(topic, "test_subscriber_profile"); ASSERT_NE(datareader, nullptr); check_datareader_with_profile(datareader, "test_subscriber_profile"); - ASSERT_TRUE(subscriber->delete_datareader(datareader) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(subscriber->delete_datareader(datareader) == RETCODE_OK); - ASSERT_EQ(participant->delete_subscriber(subscriber), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(participant->delete_topic(topic), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(participant->delete_subscriber(subscriber), RETCODE_OK); + ASSERT_EQ(participant->delete_topic(topic), RETCODE_OK); + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), RETCODE_OK); } TEST(SubscriberTests, GetDataReaderProfileQos) @@ -679,7 +579,7 @@ TEST(SubscriberTests, GetDataReaderProfileQos) DataReaderQos qos; EXPECT_EQ( subscriber->get_datareader_qos_from_profile("test_subscriber_profile", qos), - ReturnCode_t::RETCODE_OK); + RETCODE_OK); //DataReader using the extracted qos DataReader* datareader = subscriber->create_datareader(topic, qos); @@ -690,13 +590,13 @@ TEST(SubscriberTests, GetDataReaderProfileQos) // Test return when a non-existent profile is used EXPECT_EQ( subscriber->get_datareader_qos_from_profile("incorrect_profile_name", qos), - ReturnCode_t::RETCODE_BAD_PARAMETER); + RETCODE_BAD_PARAMETER); // Clean up - ASSERT_EQ(subscriber->delete_datareader(datareader), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(participant->delete_subscriber(subscriber), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(participant->delete_topic(topic), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(subscriber->delete_datareader(datareader), RETCODE_OK); + ASSERT_EQ(participant->delete_subscriber(subscriber), RETCODE_OK); + ASSERT_EQ(participant->delete_topic(topic), RETCODE_OK); + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), RETCODE_OK); } TEST(SubscriberTests, DeleteSubscriberWithReaders) @@ -717,47 +617,21 @@ TEST(SubscriberTests, DeleteSubscriberWithReaders) DataReader* data_reader = subscriber->create_datareader(topic, DATAREADER_QOS_DEFAULT); ASSERT_NE(data_reader, nullptr); - ASSERT_EQ(participant->delete_subscriber(subscriber), ReturnCode_t::RETCODE_PRECONDITION_NOT_MET); + ASSERT_EQ(participant->delete_subscriber(subscriber), RETCODE_PRECONDITION_NOT_MET); - ASSERT_EQ(subscriber->delete_datareader(data_reader), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(participant->delete_subscriber(subscriber), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(subscriber->delete_datareader(data_reader), RETCODE_OK); + ASSERT_EQ(participant->delete_subscriber(subscriber), RETCODE_OK); - ASSERT_EQ(participant->delete_topic(topic), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(participant->delete_topic(topic), RETCODE_OK); + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), RETCODE_OK); } -//TODO: [ILG] Activate the test once PSM API for DataReader is in place -/* - TEST(SubscriberTests, CreatePSMDataReader) - { - ::dds::domain::DomainParticipant participant = ::dds::domain::DomainParticipant(0, PARTICIPANT_QOS_DEFAULT); - - ::dds::sub::Subscriber subscriber = ::dds::core::null; - subscriber = ::dds::sub::Subscriber(participant); - - ASSERT_NE(subscriber, ::dds::core::null); - - TypeSupport type(new TopicDataTypeMock()); - type.register_type(participant.delegate().get()); - - ::dds::topic::Topic topic = ::dds::core::null; - topic = ::dds::topic::Topic(participant, "footopic", type_->getName(), TOPIC_QOS_DEFAULT); - - ASSERT_NE(topic, ::dds::core::null); - - ::dds::sub::DataReader data_reader = ::dds::core::null; - data_reader = ::dds::sub::DataReader(subscriber, topic); - - ASSERT_NE(data_reader, ::dds::core::null); - } - */ - void set_listener_test ( Subscriber* subscriber, SubscriberListener* listener, StatusMask mask) { - ASSERT_EQ(subscriber->set_listener(listener, mask), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(subscriber->set_listener(listener, mask), RETCODE_OK); ASSERT_EQ(subscriber->get_status_mask(), mask); } @@ -809,13 +683,13 @@ TEST(SubscriberTests, SetListener) std::get<2>(testing_case)); } - ASSERT_EQ(participant->delete_subscriber(subscriber), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(participant->delete_subscriber(subscriber), RETCODE_OK); + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), RETCODE_OK); } /* * This test checks that the Subscriber methods defined in the standard not yet implemented in FastDDS return - * ReturnCode_t::RETCODE_UNSUPPORTED. The following methods are checked: + * RETCODE_UNSUPPORTED. The following methods are checked: * 1. begin_access * 2. end_access * 3. get_datareaders (all parameters) @@ -835,16 +709,16 @@ TEST(SubscriberTests, UnsupportedPublisherMethods) fastdds::dds::DataReaderQos reader_qos; fastdds::dds::TopicQos topic_qos; - EXPECT_EQ(ReturnCode_t::RETCODE_UNSUPPORTED, subscriber->begin_access()); - EXPECT_EQ(ReturnCode_t::RETCODE_UNSUPPORTED, subscriber->end_access()); - EXPECT_EQ(ReturnCode_t::RETCODE_UNSUPPORTED, subscriber->get_datareaders( + EXPECT_EQ(RETCODE_UNSUPPORTED, subscriber->begin_access()); + EXPECT_EQ(RETCODE_UNSUPPORTED, subscriber->end_access()); + EXPECT_EQ(RETCODE_UNSUPPORTED, subscriber->get_datareaders( readers, sample_states, view_states, instance_states)); - ASSERT_EQ(participant->delete_subscriber(subscriber), ReturnCode_t::RETCODE_OK); - ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(participant->delete_subscriber(subscriber), RETCODE_OK); + ASSERT_EQ(DomainParticipantFactory::get_instance()->delete_participant(participant), RETCODE_OK); } /** @@ -952,20 +826,20 @@ TEST(SubscriberTests, DeleteContainedEntities) BarType data; data.index(1); type.get_key(&data, &handle_nil); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, data_writer_foo->write(&data, HANDLE_NIL)); + EXPECT_EQ(RETCODE_OK, data_writer_foo->write(&data, HANDLE_NIL)); // Wait for data to arrive and check OK should be returned Duration_t wait_time(1, 0); EXPECT_TRUE(data_reader_foo->wait_for_unread_message(wait_time)); LoanableSequence mock_coll; - SampleInfoSeq mock_seq; + fastdds::dds::SampleInfoSeq mock_seq; - ASSERT_EQ(data_reader_foo->take(mock_coll, mock_seq), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(data_reader_foo->take(mock_coll, mock_seq), RETCODE_OK); - ASSERT_EQ(subscriber->delete_contained_entities(), ReturnCode_t::RETCODE_PRECONDITION_NOT_MET); + ASSERT_EQ(subscriber->delete_contained_entities(), RETCODE_PRECONDITION_NOT_MET); - ASSERT_EQ(data_reader_foo->return_loan(mock_coll, mock_seq), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(data_reader_foo->return_loan(mock_coll, mock_seq), RETCODE_OK); SampleStateMask mock_sample_state_kind = ANY_SAMPLE_STATE; ViewStateMask mock_view_state_kind = ANY_VIEW_STATE; @@ -989,7 +863,7 @@ TEST(SubscriberTests, DeleteContainedEntities) ASSERT_TRUE(data_reader_list.size() == 2); data_reader_list.clear(); - ASSERT_EQ(subscriber->delete_contained_entities(), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(subscriber->delete_contained_entities(), RETCODE_OK); subscriber->get_datareaders(data_reader_list); ASSERT_TRUE(data_reader_list.size() == 0); diff --git a/test/unittest/dds/topic/CMakeLists.txt b/test/unittest/dds/topic/CMakeLists.txt index e647f1048a1..051ee0b586e 100644 --- a/test/unittest/dds/topic/CMakeLists.txt +++ b/test/unittest/dds/topic/CMakeLists.txt @@ -31,7 +31,7 @@ target_include_directories(TopicTests PRIVATE ${PROJECT_SOURCE_DIR}/include ${PROJECT_BINARY_DIR}/include ${PROJECT_SOURCE_DIR}/src/cpp ) -target_link_libraries(TopicTests fastrtps fastcdr foonathan_memory +target_link_libraries(TopicTests fastdds fastcdr foonathan_memory GTest::gmock ${CMAKE_DL_LIBS}) gtest_discover_tests(TopicTests) diff --git a/test/unittest/dds/topic/DDSSQLFilter/CMakeLists.txt b/test/unittest/dds/topic/DDSSQLFilter/CMakeLists.txt index f30b03366d9..877f78b1b7c 100644 --- a/test/unittest/dds/topic/DDSSQLFilter/CMakeLists.txt +++ b/test/unittest/dds/topic/DDSSQLFilter/CMakeLists.txt @@ -20,7 +20,6 @@ file(GLOB DDSSQLFILTER_SOURCES ) file(GLOB DDSSQLFILTER_LIB_SOURCES - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/*.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/*.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/topic/TopicDataType.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/LocatorWithMask.cpp @@ -55,11 +54,18 @@ target_compile_definitions(DDSSQLFilterTests PRIVATE ) target_include_directories(DDSSQLFilterTests PRIVATE ${Asio_INCLUDE_DIR} + ${PROJECT_SOURCE_DIR}/test/mock/dds/DomainParticipantFactory/ + ${PROJECT_SOURCE_DIR}/test/mock/rtps/RTPSDomainImpl/ ${PROJECT_SOURCE_DIR}/include ${PROJECT_BINARY_DIR}/include ${PROJECT_SOURCE_DIR}/src/cpp ${PROJECT_SOURCE_DIR}/thirdparty/taocpp-pegtl ) -target_link_libraries(DDSSQLFilterTests fastcdr foonathan_memory +target_link_libraries(DDSSQLFilterTests + fastcdr + fastdds::xtypes::dynamic-types::impl + fastdds::xtypes::type-representation + foonathan_memory GTest::gmock - ${CMAKE_DL_LIBS}) + ${CMAKE_DL_LIBS} + ) gtest_discover_tests(DDSSQLFilterTests) diff --git a/test/unittest/dds/topic/DDSSQLFilter/DDSSQLFilterTests.cpp b/test/unittest/dds/topic/DDSSQLFilter/DDSSQLFilterTests.cpp index 1c26f98b22a..693cb30e78c 100644 --- a/test/unittest/dds/topic/DDSSQLFilter/DDSSQLFilterTests.cpp +++ b/test/unittest/dds/topic/DDSSQLFilter/DDSSQLFilterTests.cpp @@ -29,9 +29,9 @@ #include "fastdds/dds/core/StackAllocatedSequence.hpp" #include "fastdds/dds/log/Log.hpp" -#include "data_types/ContentFilterTestType.h" +#include "data_types/ContentFilterTestType.hpp" #include "data_types/ContentFilterTestTypePubSubTypes.h" -#include "data_types/ContentFilterTestTypeTypeObject.h" +#include "data_types/ContentFilterTestTypeTypeObjectSupport.hpp" namespace eprosima { namespace fastdds { @@ -120,7 +120,6 @@ static bool are_types_compatible( } using DDSFilterFactory = DDSSQLFilter::DDSFilterFactory; -using ReturnCode_t = DDSFilterFactory::ReturnCode_t; static ReturnCode_t create_content_filter( DDSFilterFactory& factory, @@ -148,8 +147,14 @@ class DDSSQLFilterTests : public testing::Test protected: - const ReturnCode_t ok_code = ReturnCode_t::RETCODE_OK; - const ReturnCode_t bad_code = ReturnCode_t::RETCODE_BAD_PARAMETER; + void SetUp() override + { + register_ContentFilterTestType_type_objects(); + eprosima::fastdds::dds::Log::ClearConsumers(); + } + + const ReturnCode_t ok_code = RETCODE_OK; + const ReturnCode_t bad_code = RETCODE_BAD_PARAMETER; struct TestCase { @@ -185,7 +190,7 @@ class DDSSQLFilterTests : public testing::Test TEST_F(DDSSQLFilterTests, empty_expression) { - TestCase empty{ "", {}, ReturnCode_t::RETCODE_OK }; + TestCase empty{ "", {}, RETCODE_OK }; run(empty); } @@ -1010,6 +1015,12 @@ class DDSSQLFilterValueTests : public testing::TestWithParam 1 - -#include "ContentFilterTestTypeTypeObject.h" - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - - - - -StructType::StructType() -{ - // Just to register all known types - registerContentFilterTestTypeTypes(); -} - -StructType::~StructType() -{ -} - -StructType::StructType( - const StructType& x) -{ - m_char_field = x.m_char_field; - m_uint8_field = x.m_uint8_field; - m_int16_field = x.m_int16_field; - m_uint16_field = x.m_uint16_field; - m_int32_field = x.m_int32_field; - m_uint32_field = x.m_uint32_field; - m_int64_field = x.m_int64_field; - m_uint64_field = x.m_uint64_field; - m_float_field = x.m_float_field; - m_double_field = x.m_double_field; - m_long_double_field = x.m_long_double_field; - m_bool_field = x.m_bool_field; - m_string_field = x.m_string_field; - m_enum_field = x.m_enum_field; - m_enum2_field = x.m_enum2_field; -} - -StructType::StructType( - StructType&& x) noexcept -{ - m_char_field = x.m_char_field; - m_uint8_field = x.m_uint8_field; - m_int16_field = x.m_int16_field; - m_uint16_field = x.m_uint16_field; - m_int32_field = x.m_int32_field; - m_uint32_field = x.m_uint32_field; - m_int64_field = x.m_int64_field; - m_uint64_field = x.m_uint64_field; - m_float_field = x.m_float_field; - m_double_field = x.m_double_field; - m_long_double_field = x.m_long_double_field; - m_bool_field = x.m_bool_field; - m_string_field = std::move(x.m_string_field); - m_enum_field = x.m_enum_field; - m_enum2_field = x.m_enum2_field; -} - -StructType& StructType::operator =( - const StructType& x) -{ - - m_char_field = x.m_char_field; - m_uint8_field = x.m_uint8_field; - m_int16_field = x.m_int16_field; - m_uint16_field = x.m_uint16_field; - m_int32_field = x.m_int32_field; - m_uint32_field = x.m_uint32_field; - m_int64_field = x.m_int64_field; - m_uint64_field = x.m_uint64_field; - m_float_field = x.m_float_field; - m_double_field = x.m_double_field; - m_long_double_field = x.m_long_double_field; - m_bool_field = x.m_bool_field; - m_string_field = x.m_string_field; - m_enum_field = x.m_enum_field; - m_enum2_field = x.m_enum2_field; - return *this; -} - -StructType& StructType::operator =( - StructType&& x) noexcept -{ - - m_char_field = x.m_char_field; - m_uint8_field = x.m_uint8_field; - m_int16_field = x.m_int16_field; - m_uint16_field = x.m_uint16_field; - m_int32_field = x.m_int32_field; - m_uint32_field = x.m_uint32_field; - m_int64_field = x.m_int64_field; - m_uint64_field = x.m_uint64_field; - m_float_field = x.m_float_field; - m_double_field = x.m_double_field; - m_long_double_field = x.m_long_double_field; - m_bool_field = x.m_bool_field; - m_string_field = std::move(x.m_string_field); - m_enum_field = x.m_enum_field; - m_enum2_field = x.m_enum2_field; - return *this; -} - -bool StructType::operator ==( - const StructType& x) const -{ - return (m_char_field == x.m_char_field && - m_uint8_field == x.m_uint8_field && - m_int16_field == x.m_int16_field && - m_uint16_field == x.m_uint16_field && - m_int32_field == x.m_int32_field && - m_uint32_field == x.m_uint32_field && - m_int64_field == x.m_int64_field && - m_uint64_field == x.m_uint64_field && - m_float_field == x.m_float_field && - m_double_field == x.m_double_field && - m_long_double_field == x.m_long_double_field && - m_bool_field == x.m_bool_field && - m_string_field == x.m_string_field && - m_enum_field == x.m_enum_field && - m_enum2_field == x.m_enum2_field); -} - -bool StructType::operator !=( - const StructType& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member char_field - * @param _char_field New value for member char_field - */ -void StructType::char_field( - char _char_field) -{ - m_char_field = _char_field; -} - -/*! - * @brief This function returns the value of member char_field - * @return Value of member char_field - */ -char StructType::char_field() const -{ - return m_char_field; -} - -/*! - * @brief This function returns a reference to member char_field - * @return Reference to member char_field - */ -char& StructType::char_field() -{ - return m_char_field; -} - - -/*! - * @brief This function sets a value in member uint8_field - * @param _uint8_field New value for member uint8_field - */ -void StructType::uint8_field( - uint8_t _uint8_field) -{ - m_uint8_field = _uint8_field; -} - -/*! - * @brief This function returns the value of member uint8_field - * @return Value of member uint8_field - */ -uint8_t StructType::uint8_field() const -{ - return m_uint8_field; -} - -/*! - * @brief This function returns a reference to member uint8_field - * @return Reference to member uint8_field - */ -uint8_t& StructType::uint8_field() -{ - return m_uint8_field; -} - - -/*! - * @brief This function sets a value in member int16_field - * @param _int16_field New value for member int16_field - */ -void StructType::int16_field( - int16_t _int16_field) -{ - m_int16_field = _int16_field; -} - -/*! - * @brief This function returns the value of member int16_field - * @return Value of member int16_field - */ -int16_t StructType::int16_field() const -{ - return m_int16_field; -} - -/*! - * @brief This function returns a reference to member int16_field - * @return Reference to member int16_field - */ -int16_t& StructType::int16_field() -{ - return m_int16_field; -} - - -/*! - * @brief This function sets a value in member uint16_field - * @param _uint16_field New value for member uint16_field - */ -void StructType::uint16_field( - uint16_t _uint16_field) -{ - m_uint16_field = _uint16_field; -} - -/*! - * @brief This function returns the value of member uint16_field - * @return Value of member uint16_field - */ -uint16_t StructType::uint16_field() const -{ - return m_uint16_field; -} - -/*! - * @brief This function returns a reference to member uint16_field - * @return Reference to member uint16_field - */ -uint16_t& StructType::uint16_field() -{ - return m_uint16_field; -} - - -/*! - * @brief This function sets a value in member int32_field - * @param _int32_field New value for member int32_field - */ -void StructType::int32_field( - int32_t _int32_field) -{ - m_int32_field = _int32_field; -} - -/*! - * @brief This function returns the value of member int32_field - * @return Value of member int32_field - */ -int32_t StructType::int32_field() const -{ - return m_int32_field; -} - -/*! - * @brief This function returns a reference to member int32_field - * @return Reference to member int32_field - */ -int32_t& StructType::int32_field() -{ - return m_int32_field; -} - - -/*! - * @brief This function sets a value in member uint32_field - * @param _uint32_field New value for member uint32_field - */ -void StructType::uint32_field( - uint32_t _uint32_field) -{ - m_uint32_field = _uint32_field; -} - -/*! - * @brief This function returns the value of member uint32_field - * @return Value of member uint32_field - */ -uint32_t StructType::uint32_field() const -{ - return m_uint32_field; -} - -/*! - * @brief This function returns a reference to member uint32_field - * @return Reference to member uint32_field - */ -uint32_t& StructType::uint32_field() -{ - return m_uint32_field; -} - - -/*! - * @brief This function sets a value in member int64_field - * @param _int64_field New value for member int64_field - */ -void StructType::int64_field( - int64_t _int64_field) -{ - m_int64_field = _int64_field; -} - -/*! - * @brief This function returns the value of member int64_field - * @return Value of member int64_field - */ -int64_t StructType::int64_field() const -{ - return m_int64_field; -} - -/*! - * @brief This function returns a reference to member int64_field - * @return Reference to member int64_field - */ -int64_t& StructType::int64_field() -{ - return m_int64_field; -} - - -/*! - * @brief This function sets a value in member uint64_field - * @param _uint64_field New value for member uint64_field - */ -void StructType::uint64_field( - uint64_t _uint64_field) -{ - m_uint64_field = _uint64_field; -} - -/*! - * @brief This function returns the value of member uint64_field - * @return Value of member uint64_field - */ -uint64_t StructType::uint64_field() const -{ - return m_uint64_field; -} - -/*! - * @brief This function returns a reference to member uint64_field - * @return Reference to member uint64_field - */ -uint64_t& StructType::uint64_field() -{ - return m_uint64_field; -} - - -/*! - * @brief This function sets a value in member float_field - * @param _float_field New value for member float_field - */ -void StructType::float_field( - float _float_field) -{ - m_float_field = _float_field; -} - -/*! - * @brief This function returns the value of member float_field - * @return Value of member float_field - */ -float StructType::float_field() const -{ - return m_float_field; -} - -/*! - * @brief This function returns a reference to member float_field - * @return Reference to member float_field - */ -float& StructType::float_field() -{ - return m_float_field; -} - - -/*! - * @brief This function sets a value in member double_field - * @param _double_field New value for member double_field - */ -void StructType::double_field( - double _double_field) -{ - m_double_field = _double_field; -} - -/*! - * @brief This function returns the value of member double_field - * @return Value of member double_field - */ -double StructType::double_field() const -{ - return m_double_field; -} - -/*! - * @brief This function returns a reference to member double_field - * @return Reference to member double_field - */ -double& StructType::double_field() -{ - return m_double_field; -} - - -/*! - * @brief This function sets a value in member long_double_field - * @param _long_double_field New value for member long_double_field - */ -void StructType::long_double_field( - long double _long_double_field) -{ - m_long_double_field = _long_double_field; -} - -/*! - * @brief This function returns the value of member long_double_field - * @return Value of member long_double_field - */ -long double StructType::long_double_field() const -{ - return m_long_double_field; -} - -/*! - * @brief This function returns a reference to member long_double_field - * @return Reference to member long_double_field - */ -long double& StructType::long_double_field() -{ - return m_long_double_field; -} - - -/*! - * @brief This function sets a value in member bool_field - * @param _bool_field New value for member bool_field - */ -void StructType::bool_field( - bool _bool_field) -{ - m_bool_field = _bool_field; -} - -/*! - * @brief This function returns the value of member bool_field - * @return Value of member bool_field - */ -bool StructType::bool_field() const -{ - return m_bool_field; -} - -/*! - * @brief This function returns a reference to member bool_field - * @return Reference to member bool_field - */ -bool& StructType::bool_field() -{ - return m_bool_field; -} - - -/*! - * @brief This function copies the value in member string_field - * @param _string_field New value to be copied in member string_field - */ -void StructType::string_field( - const std::string& _string_field) -{ - m_string_field = _string_field; -} - -/*! - * @brief This function moves the value in member string_field - * @param _string_field New value to be moved in member string_field - */ -void StructType::string_field( - std::string&& _string_field) -{ - m_string_field = std::move(_string_field); -} - -/*! - * @brief This function returns a constant reference to member string_field - * @return Constant reference to member string_field - */ -const std::string& StructType::string_field() const -{ - return m_string_field; -} - -/*! - * @brief This function returns a reference to member string_field - * @return Reference to member string_field - */ -std::string& StructType::string_field() -{ - return m_string_field; -} - - -/*! - * @brief This function sets a value in member enum_field - * @param _enum_field New value for member enum_field - */ -void StructType::enum_field( - Color _enum_field) -{ - m_enum_field = _enum_field; -} - -/*! - * @brief This function returns the value of member enum_field - * @return Value of member enum_field - */ -Color StructType::enum_field() const -{ - return m_enum_field; -} - -/*! - * @brief This function returns a reference to member enum_field - * @return Reference to member enum_field - */ -Color& StructType::enum_field() -{ - return m_enum_field; -} - - -/*! - * @brief This function sets a value in member enum2_field - * @param _enum2_field New value for member enum2_field - */ -void StructType::enum2_field( - Material _enum2_field) -{ - m_enum2_field = _enum2_field; -} - -/*! - * @brief This function returns the value of member enum2_field - * @return Value of member enum2_field - */ -Material StructType::enum2_field() const -{ - return m_enum2_field; -} - -/*! - * @brief This function returns a reference to member enum2_field - * @return Reference to member enum2_field - */ -Material& StructType::enum2_field() -{ - return m_enum2_field; -} - - - - - - - - -ContentFilterTestType::ContentFilterTestType() -{ - // Just to register all known types - registerContentFilterTestTypeTypes(); -} - -ContentFilterTestType::~ContentFilterTestType() -{ -} - -ContentFilterTestType::ContentFilterTestType( - const ContentFilterTestType& x) -{ - m_char_field = x.m_char_field; - m_uint8_field = x.m_uint8_field; - m_int16_field = x.m_int16_field; - m_uint16_field = x.m_uint16_field; - m_int32_field = x.m_int32_field; - m_uint32_field = x.m_uint32_field; - m_int64_field = x.m_int64_field; - m_uint64_field = x.m_uint64_field; - m_float_field = x.m_float_field; - m_double_field = x.m_double_field; - m_long_double_field = x.m_long_double_field; - m_bool_field = x.m_bool_field; - m_string_field = x.m_string_field; - m_enum_field = x.m_enum_field; - m_enum2_field = x.m_enum2_field; - m_struct_field = x.m_struct_field; - m_array_char_field = x.m_array_char_field; - m_array_uint8_field = x.m_array_uint8_field; - m_array_int16_field = x.m_array_int16_field; - m_array_uint16_field = x.m_array_uint16_field; - m_array_int32_field = x.m_array_int32_field; - m_array_uint32_field = x.m_array_uint32_field; - m_array_int64_field = x.m_array_int64_field; - m_array_uint64_field = x.m_array_uint64_field; - m_array_float_field = x.m_array_float_field; - m_array_double_field = x.m_array_double_field; - m_array_long_double_field = x.m_array_long_double_field; - m_array_bool_field = x.m_array_bool_field; - m_array_string_field = x.m_array_string_field; - m_array_enum_field = x.m_array_enum_field; - m_array_enum2_field = x.m_array_enum2_field; - m_array_struct_field = x.m_array_struct_field; - m_bounded_sequence_char_field = x.m_bounded_sequence_char_field; - m_bounded_sequence_uint8_field = x.m_bounded_sequence_uint8_field; - m_bounded_sequence_int16_field = x.m_bounded_sequence_int16_field; - m_bounded_sequence_uint16_field = x.m_bounded_sequence_uint16_field; - m_bounded_sequence_int32_field = x.m_bounded_sequence_int32_field; - m_bounded_sequence_uint32_field = x.m_bounded_sequence_uint32_field; - m_bounded_sequence_int64_field = x.m_bounded_sequence_int64_field; - m_bounded_sequence_uint64_field = x.m_bounded_sequence_uint64_field; - m_bounded_sequence_float_field = x.m_bounded_sequence_float_field; - m_bounded_sequence_double_field = x.m_bounded_sequence_double_field; - m_bounded_sequence_long_double_field = x.m_bounded_sequence_long_double_field; - m_bounded_sequence_bool_field = x.m_bounded_sequence_bool_field; - m_bounded_sequence_string_field = x.m_bounded_sequence_string_field; - m_bounded_sequence_enum_field = x.m_bounded_sequence_enum_field; - m_bounded_sequence_enum2_field = x.m_bounded_sequence_enum2_field; - m_bounded_sequence_struct_field = x.m_bounded_sequence_struct_field; - m_unbounded_sequence_char_field = x.m_unbounded_sequence_char_field; - m_unbounded_sequence_uint8_field = x.m_unbounded_sequence_uint8_field; - m_unbounded_sequence_int16_field = x.m_unbounded_sequence_int16_field; - m_unbounded_sequence_uint16_field = x.m_unbounded_sequence_uint16_field; - m_unbounded_sequence_int32_field = x.m_unbounded_sequence_int32_field; - m_unbounded_sequence_uint32_field = x.m_unbounded_sequence_uint32_field; - m_unbounded_sequence_int64_field = x.m_unbounded_sequence_int64_field; - m_unbounded_sequence_uint64_field = x.m_unbounded_sequence_uint64_field; - m_unbounded_sequence_float_field = x.m_unbounded_sequence_float_field; - m_unbounded_sequence_double_field = x.m_unbounded_sequence_double_field; - m_unbounded_sequence_long_double_field = x.m_unbounded_sequence_long_double_field; - m_unbounded_sequence_bool_field = x.m_unbounded_sequence_bool_field; - m_unbounded_sequence_string_field = x.m_unbounded_sequence_string_field; - m_unbounded_sequence_enum_field = x.m_unbounded_sequence_enum_field; - m_unbounded_sequence_enum2_field = x.m_unbounded_sequence_enum2_field; - m_unbounded_sequence_struct_field = x.m_unbounded_sequence_struct_field; -} - -ContentFilterTestType::ContentFilterTestType( - ContentFilterTestType&& x) noexcept -{ - m_char_field = x.m_char_field; - m_uint8_field = x.m_uint8_field; - m_int16_field = x.m_int16_field; - m_uint16_field = x.m_uint16_field; - m_int32_field = x.m_int32_field; - m_uint32_field = x.m_uint32_field; - m_int64_field = x.m_int64_field; - m_uint64_field = x.m_uint64_field; - m_float_field = x.m_float_field; - m_double_field = x.m_double_field; - m_long_double_field = x.m_long_double_field; - m_bool_field = x.m_bool_field; - m_string_field = std::move(x.m_string_field); - m_enum_field = x.m_enum_field; - m_enum2_field = x.m_enum2_field; - m_struct_field = std::move(x.m_struct_field); - m_array_char_field = std::move(x.m_array_char_field); - m_array_uint8_field = std::move(x.m_array_uint8_field); - m_array_int16_field = std::move(x.m_array_int16_field); - m_array_uint16_field = std::move(x.m_array_uint16_field); - m_array_int32_field = std::move(x.m_array_int32_field); - m_array_uint32_field = std::move(x.m_array_uint32_field); - m_array_int64_field = std::move(x.m_array_int64_field); - m_array_uint64_field = std::move(x.m_array_uint64_field); - m_array_float_field = std::move(x.m_array_float_field); - m_array_double_field = std::move(x.m_array_double_field); - m_array_long_double_field = std::move(x.m_array_long_double_field); - m_array_bool_field = std::move(x.m_array_bool_field); - m_array_string_field = std::move(x.m_array_string_field); - m_array_enum_field = std::move(x.m_array_enum_field); - m_array_enum2_field = std::move(x.m_array_enum2_field); - m_array_struct_field = std::move(x.m_array_struct_field); - m_bounded_sequence_char_field = std::move(x.m_bounded_sequence_char_field); - m_bounded_sequence_uint8_field = std::move(x.m_bounded_sequence_uint8_field); - m_bounded_sequence_int16_field = std::move(x.m_bounded_sequence_int16_field); - m_bounded_sequence_uint16_field = std::move(x.m_bounded_sequence_uint16_field); - m_bounded_sequence_int32_field = std::move(x.m_bounded_sequence_int32_field); - m_bounded_sequence_uint32_field = std::move(x.m_bounded_sequence_uint32_field); - m_bounded_sequence_int64_field = std::move(x.m_bounded_sequence_int64_field); - m_bounded_sequence_uint64_field = std::move(x.m_bounded_sequence_uint64_field); - m_bounded_sequence_float_field = std::move(x.m_bounded_sequence_float_field); - m_bounded_sequence_double_field = std::move(x.m_bounded_sequence_double_field); - m_bounded_sequence_long_double_field = std::move(x.m_bounded_sequence_long_double_field); - m_bounded_sequence_bool_field = std::move(x.m_bounded_sequence_bool_field); - m_bounded_sequence_string_field = std::move(x.m_bounded_sequence_string_field); - m_bounded_sequence_enum_field = std::move(x.m_bounded_sequence_enum_field); - m_bounded_sequence_enum2_field = std::move(x.m_bounded_sequence_enum2_field); - m_bounded_sequence_struct_field = std::move(x.m_bounded_sequence_struct_field); - m_unbounded_sequence_char_field = std::move(x.m_unbounded_sequence_char_field); - m_unbounded_sequence_uint8_field = std::move(x.m_unbounded_sequence_uint8_field); - m_unbounded_sequence_int16_field = std::move(x.m_unbounded_sequence_int16_field); - m_unbounded_sequence_uint16_field = std::move(x.m_unbounded_sequence_uint16_field); - m_unbounded_sequence_int32_field = std::move(x.m_unbounded_sequence_int32_field); - m_unbounded_sequence_uint32_field = std::move(x.m_unbounded_sequence_uint32_field); - m_unbounded_sequence_int64_field = std::move(x.m_unbounded_sequence_int64_field); - m_unbounded_sequence_uint64_field = std::move(x.m_unbounded_sequence_uint64_field); - m_unbounded_sequence_float_field = std::move(x.m_unbounded_sequence_float_field); - m_unbounded_sequence_double_field = std::move(x.m_unbounded_sequence_double_field); - m_unbounded_sequence_long_double_field = std::move(x.m_unbounded_sequence_long_double_field); - m_unbounded_sequence_bool_field = std::move(x.m_unbounded_sequence_bool_field); - m_unbounded_sequence_string_field = std::move(x.m_unbounded_sequence_string_field); - m_unbounded_sequence_enum_field = std::move(x.m_unbounded_sequence_enum_field); - m_unbounded_sequence_enum2_field = std::move(x.m_unbounded_sequence_enum2_field); - m_unbounded_sequence_struct_field = std::move(x.m_unbounded_sequence_struct_field); -} - -ContentFilterTestType& ContentFilterTestType::operator =( - const ContentFilterTestType& x) -{ - - m_char_field = x.m_char_field; - m_uint8_field = x.m_uint8_field; - m_int16_field = x.m_int16_field; - m_uint16_field = x.m_uint16_field; - m_int32_field = x.m_int32_field; - m_uint32_field = x.m_uint32_field; - m_int64_field = x.m_int64_field; - m_uint64_field = x.m_uint64_field; - m_float_field = x.m_float_field; - m_double_field = x.m_double_field; - m_long_double_field = x.m_long_double_field; - m_bool_field = x.m_bool_field; - m_string_field = x.m_string_field; - m_enum_field = x.m_enum_field; - m_enum2_field = x.m_enum2_field; - m_struct_field = x.m_struct_field; - m_array_char_field = x.m_array_char_field; - m_array_uint8_field = x.m_array_uint8_field; - m_array_int16_field = x.m_array_int16_field; - m_array_uint16_field = x.m_array_uint16_field; - m_array_int32_field = x.m_array_int32_field; - m_array_uint32_field = x.m_array_uint32_field; - m_array_int64_field = x.m_array_int64_field; - m_array_uint64_field = x.m_array_uint64_field; - m_array_float_field = x.m_array_float_field; - m_array_double_field = x.m_array_double_field; - m_array_long_double_field = x.m_array_long_double_field; - m_array_bool_field = x.m_array_bool_field; - m_array_string_field = x.m_array_string_field; - m_array_enum_field = x.m_array_enum_field; - m_array_enum2_field = x.m_array_enum2_field; - m_array_struct_field = x.m_array_struct_field; - m_bounded_sequence_char_field = x.m_bounded_sequence_char_field; - m_bounded_sequence_uint8_field = x.m_bounded_sequence_uint8_field; - m_bounded_sequence_int16_field = x.m_bounded_sequence_int16_field; - m_bounded_sequence_uint16_field = x.m_bounded_sequence_uint16_field; - m_bounded_sequence_int32_field = x.m_bounded_sequence_int32_field; - m_bounded_sequence_uint32_field = x.m_bounded_sequence_uint32_field; - m_bounded_sequence_int64_field = x.m_bounded_sequence_int64_field; - m_bounded_sequence_uint64_field = x.m_bounded_sequence_uint64_field; - m_bounded_sequence_float_field = x.m_bounded_sequence_float_field; - m_bounded_sequence_double_field = x.m_bounded_sequence_double_field; - m_bounded_sequence_long_double_field = x.m_bounded_sequence_long_double_field; - m_bounded_sequence_bool_field = x.m_bounded_sequence_bool_field; - m_bounded_sequence_string_field = x.m_bounded_sequence_string_field; - m_bounded_sequence_enum_field = x.m_bounded_sequence_enum_field; - m_bounded_sequence_enum2_field = x.m_bounded_sequence_enum2_field; - m_bounded_sequence_struct_field = x.m_bounded_sequence_struct_field; - m_unbounded_sequence_char_field = x.m_unbounded_sequence_char_field; - m_unbounded_sequence_uint8_field = x.m_unbounded_sequence_uint8_field; - m_unbounded_sequence_int16_field = x.m_unbounded_sequence_int16_field; - m_unbounded_sequence_uint16_field = x.m_unbounded_sequence_uint16_field; - m_unbounded_sequence_int32_field = x.m_unbounded_sequence_int32_field; - m_unbounded_sequence_uint32_field = x.m_unbounded_sequence_uint32_field; - m_unbounded_sequence_int64_field = x.m_unbounded_sequence_int64_field; - m_unbounded_sequence_uint64_field = x.m_unbounded_sequence_uint64_field; - m_unbounded_sequence_float_field = x.m_unbounded_sequence_float_field; - m_unbounded_sequence_double_field = x.m_unbounded_sequence_double_field; - m_unbounded_sequence_long_double_field = x.m_unbounded_sequence_long_double_field; - m_unbounded_sequence_bool_field = x.m_unbounded_sequence_bool_field; - m_unbounded_sequence_string_field = x.m_unbounded_sequence_string_field; - m_unbounded_sequence_enum_field = x.m_unbounded_sequence_enum_field; - m_unbounded_sequence_enum2_field = x.m_unbounded_sequence_enum2_field; - m_unbounded_sequence_struct_field = x.m_unbounded_sequence_struct_field; - return *this; -} - -ContentFilterTestType& ContentFilterTestType::operator =( - ContentFilterTestType&& x) noexcept -{ - - m_char_field = x.m_char_field; - m_uint8_field = x.m_uint8_field; - m_int16_field = x.m_int16_field; - m_uint16_field = x.m_uint16_field; - m_int32_field = x.m_int32_field; - m_uint32_field = x.m_uint32_field; - m_int64_field = x.m_int64_field; - m_uint64_field = x.m_uint64_field; - m_float_field = x.m_float_field; - m_double_field = x.m_double_field; - m_long_double_field = x.m_long_double_field; - m_bool_field = x.m_bool_field; - m_string_field = std::move(x.m_string_field); - m_enum_field = x.m_enum_field; - m_enum2_field = x.m_enum2_field; - m_struct_field = std::move(x.m_struct_field); - m_array_char_field = std::move(x.m_array_char_field); - m_array_uint8_field = std::move(x.m_array_uint8_field); - m_array_int16_field = std::move(x.m_array_int16_field); - m_array_uint16_field = std::move(x.m_array_uint16_field); - m_array_int32_field = std::move(x.m_array_int32_field); - m_array_uint32_field = std::move(x.m_array_uint32_field); - m_array_int64_field = std::move(x.m_array_int64_field); - m_array_uint64_field = std::move(x.m_array_uint64_field); - m_array_float_field = std::move(x.m_array_float_field); - m_array_double_field = std::move(x.m_array_double_field); - m_array_long_double_field = std::move(x.m_array_long_double_field); - m_array_bool_field = std::move(x.m_array_bool_field); - m_array_string_field = std::move(x.m_array_string_field); - m_array_enum_field = std::move(x.m_array_enum_field); - m_array_enum2_field = std::move(x.m_array_enum2_field); - m_array_struct_field = std::move(x.m_array_struct_field); - m_bounded_sequence_char_field = std::move(x.m_bounded_sequence_char_field); - m_bounded_sequence_uint8_field = std::move(x.m_bounded_sequence_uint8_field); - m_bounded_sequence_int16_field = std::move(x.m_bounded_sequence_int16_field); - m_bounded_sequence_uint16_field = std::move(x.m_bounded_sequence_uint16_field); - m_bounded_sequence_int32_field = std::move(x.m_bounded_sequence_int32_field); - m_bounded_sequence_uint32_field = std::move(x.m_bounded_sequence_uint32_field); - m_bounded_sequence_int64_field = std::move(x.m_bounded_sequence_int64_field); - m_bounded_sequence_uint64_field = std::move(x.m_bounded_sequence_uint64_field); - m_bounded_sequence_float_field = std::move(x.m_bounded_sequence_float_field); - m_bounded_sequence_double_field = std::move(x.m_bounded_sequence_double_field); - m_bounded_sequence_long_double_field = std::move(x.m_bounded_sequence_long_double_field); - m_bounded_sequence_bool_field = std::move(x.m_bounded_sequence_bool_field); - m_bounded_sequence_string_field = std::move(x.m_bounded_sequence_string_field); - m_bounded_sequence_enum_field = std::move(x.m_bounded_sequence_enum_field); - m_bounded_sequence_enum2_field = std::move(x.m_bounded_sequence_enum2_field); - m_bounded_sequence_struct_field = std::move(x.m_bounded_sequence_struct_field); - m_unbounded_sequence_char_field = std::move(x.m_unbounded_sequence_char_field); - m_unbounded_sequence_uint8_field = std::move(x.m_unbounded_sequence_uint8_field); - m_unbounded_sequence_int16_field = std::move(x.m_unbounded_sequence_int16_field); - m_unbounded_sequence_uint16_field = std::move(x.m_unbounded_sequence_uint16_field); - m_unbounded_sequence_int32_field = std::move(x.m_unbounded_sequence_int32_field); - m_unbounded_sequence_uint32_field = std::move(x.m_unbounded_sequence_uint32_field); - m_unbounded_sequence_int64_field = std::move(x.m_unbounded_sequence_int64_field); - m_unbounded_sequence_uint64_field = std::move(x.m_unbounded_sequence_uint64_field); - m_unbounded_sequence_float_field = std::move(x.m_unbounded_sequence_float_field); - m_unbounded_sequence_double_field = std::move(x.m_unbounded_sequence_double_field); - m_unbounded_sequence_long_double_field = std::move(x.m_unbounded_sequence_long_double_field); - m_unbounded_sequence_bool_field = std::move(x.m_unbounded_sequence_bool_field); - m_unbounded_sequence_string_field = std::move(x.m_unbounded_sequence_string_field); - m_unbounded_sequence_enum_field = std::move(x.m_unbounded_sequence_enum_field); - m_unbounded_sequence_enum2_field = std::move(x.m_unbounded_sequence_enum2_field); - m_unbounded_sequence_struct_field = std::move(x.m_unbounded_sequence_struct_field); - return *this; -} - -bool ContentFilterTestType::operator ==( - const ContentFilterTestType& x) const -{ - return (m_char_field == x.m_char_field && - m_uint8_field == x.m_uint8_field && - m_int16_field == x.m_int16_field && - m_uint16_field == x.m_uint16_field && - m_int32_field == x.m_int32_field && - m_uint32_field == x.m_uint32_field && - m_int64_field == x.m_int64_field && - m_uint64_field == x.m_uint64_field && - m_float_field == x.m_float_field && - m_double_field == x.m_double_field && - m_long_double_field == x.m_long_double_field && - m_bool_field == x.m_bool_field && - m_string_field == x.m_string_field && - m_enum_field == x.m_enum_field && - m_enum2_field == x.m_enum2_field && - m_struct_field == x.m_struct_field && - m_array_char_field == x.m_array_char_field && - m_array_uint8_field == x.m_array_uint8_field && - m_array_int16_field == x.m_array_int16_field && - m_array_uint16_field == x.m_array_uint16_field && - m_array_int32_field == x.m_array_int32_field && - m_array_uint32_field == x.m_array_uint32_field && - m_array_int64_field == x.m_array_int64_field && - m_array_uint64_field == x.m_array_uint64_field && - m_array_float_field == x.m_array_float_field && - m_array_double_field == x.m_array_double_field && - m_array_long_double_field == x.m_array_long_double_field && - m_array_bool_field == x.m_array_bool_field && - m_array_string_field == x.m_array_string_field && - m_array_enum_field == x.m_array_enum_field && - m_array_enum2_field == x.m_array_enum2_field && - m_array_struct_field == x.m_array_struct_field && - m_bounded_sequence_char_field == x.m_bounded_sequence_char_field && - m_bounded_sequence_uint8_field == x.m_bounded_sequence_uint8_field && - m_bounded_sequence_int16_field == x.m_bounded_sequence_int16_field && - m_bounded_sequence_uint16_field == x.m_bounded_sequence_uint16_field && - m_bounded_sequence_int32_field == x.m_bounded_sequence_int32_field && - m_bounded_sequence_uint32_field == x.m_bounded_sequence_uint32_field && - m_bounded_sequence_int64_field == x.m_bounded_sequence_int64_field && - m_bounded_sequence_uint64_field == x.m_bounded_sequence_uint64_field && - m_bounded_sequence_float_field == x.m_bounded_sequence_float_field && - m_bounded_sequence_double_field == x.m_bounded_sequence_double_field && - m_bounded_sequence_long_double_field == x.m_bounded_sequence_long_double_field && - m_bounded_sequence_bool_field == x.m_bounded_sequence_bool_field && - m_bounded_sequence_string_field == x.m_bounded_sequence_string_field && - m_bounded_sequence_enum_field == x.m_bounded_sequence_enum_field && - m_bounded_sequence_enum2_field == x.m_bounded_sequence_enum2_field && - m_bounded_sequence_struct_field == x.m_bounded_sequence_struct_field && - m_unbounded_sequence_char_field == x.m_unbounded_sequence_char_field && - m_unbounded_sequence_uint8_field == x.m_unbounded_sequence_uint8_field && - m_unbounded_sequence_int16_field == x.m_unbounded_sequence_int16_field && - m_unbounded_sequence_uint16_field == x.m_unbounded_sequence_uint16_field && - m_unbounded_sequence_int32_field == x.m_unbounded_sequence_int32_field && - m_unbounded_sequence_uint32_field == x.m_unbounded_sequence_uint32_field && - m_unbounded_sequence_int64_field == x.m_unbounded_sequence_int64_field && - m_unbounded_sequence_uint64_field == x.m_unbounded_sequence_uint64_field && - m_unbounded_sequence_float_field == x.m_unbounded_sequence_float_field && - m_unbounded_sequence_double_field == x.m_unbounded_sequence_double_field && - m_unbounded_sequence_long_double_field == x.m_unbounded_sequence_long_double_field && - m_unbounded_sequence_bool_field == x.m_unbounded_sequence_bool_field && - m_unbounded_sequence_string_field == x.m_unbounded_sequence_string_field && - m_unbounded_sequence_enum_field == x.m_unbounded_sequence_enum_field && - m_unbounded_sequence_enum2_field == x.m_unbounded_sequence_enum2_field && - m_unbounded_sequence_struct_field == x.m_unbounded_sequence_struct_field); -} - -bool ContentFilterTestType::operator !=( - const ContentFilterTestType& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member char_field - * @param _char_field New value for member char_field - */ -void ContentFilterTestType::char_field( - char _char_field) -{ - m_char_field = _char_field; -} - -/*! - * @brief This function returns the value of member char_field - * @return Value of member char_field - */ -char ContentFilterTestType::char_field() const -{ - return m_char_field; -} - -/*! - * @brief This function returns a reference to member char_field - * @return Reference to member char_field - */ -char& ContentFilterTestType::char_field() -{ - return m_char_field; -} - - -/*! - * @brief This function sets a value in member uint8_field - * @param _uint8_field New value for member uint8_field - */ -void ContentFilterTestType::uint8_field( - uint8_t _uint8_field) -{ - m_uint8_field = _uint8_field; -} - -/*! - * @brief This function returns the value of member uint8_field - * @return Value of member uint8_field - */ -uint8_t ContentFilterTestType::uint8_field() const -{ - return m_uint8_field; -} - -/*! - * @brief This function returns a reference to member uint8_field - * @return Reference to member uint8_field - */ -uint8_t& ContentFilterTestType::uint8_field() -{ - return m_uint8_field; -} - - -/*! - * @brief This function sets a value in member int16_field - * @param _int16_field New value for member int16_field - */ -void ContentFilterTestType::int16_field( - int16_t _int16_field) -{ - m_int16_field = _int16_field; -} - -/*! - * @brief This function returns the value of member int16_field - * @return Value of member int16_field - */ -int16_t ContentFilterTestType::int16_field() const -{ - return m_int16_field; -} - -/*! - * @brief This function returns a reference to member int16_field - * @return Reference to member int16_field - */ -int16_t& ContentFilterTestType::int16_field() -{ - return m_int16_field; -} - - -/*! - * @brief This function sets a value in member uint16_field - * @param _uint16_field New value for member uint16_field - */ -void ContentFilterTestType::uint16_field( - uint16_t _uint16_field) -{ - m_uint16_field = _uint16_field; -} - -/*! - * @brief This function returns the value of member uint16_field - * @return Value of member uint16_field - */ -uint16_t ContentFilterTestType::uint16_field() const -{ - return m_uint16_field; -} - -/*! - * @brief This function returns a reference to member uint16_field - * @return Reference to member uint16_field - */ -uint16_t& ContentFilterTestType::uint16_field() -{ - return m_uint16_field; -} - - -/*! - * @brief This function sets a value in member int32_field - * @param _int32_field New value for member int32_field - */ -void ContentFilterTestType::int32_field( - int32_t _int32_field) -{ - m_int32_field = _int32_field; -} - -/*! - * @brief This function returns the value of member int32_field - * @return Value of member int32_field - */ -int32_t ContentFilterTestType::int32_field() const -{ - return m_int32_field; -} - -/*! - * @brief This function returns a reference to member int32_field - * @return Reference to member int32_field - */ -int32_t& ContentFilterTestType::int32_field() -{ - return m_int32_field; -} - - -/*! - * @brief This function sets a value in member uint32_field - * @param _uint32_field New value for member uint32_field - */ -void ContentFilterTestType::uint32_field( - uint32_t _uint32_field) -{ - m_uint32_field = _uint32_field; -} - -/*! - * @brief This function returns the value of member uint32_field - * @return Value of member uint32_field - */ -uint32_t ContentFilterTestType::uint32_field() const -{ - return m_uint32_field; -} - -/*! - * @brief This function returns a reference to member uint32_field - * @return Reference to member uint32_field - */ -uint32_t& ContentFilterTestType::uint32_field() -{ - return m_uint32_field; -} - - -/*! - * @brief This function sets a value in member int64_field - * @param _int64_field New value for member int64_field - */ -void ContentFilterTestType::int64_field( - int64_t _int64_field) -{ - m_int64_field = _int64_field; -} - -/*! - * @brief This function returns the value of member int64_field - * @return Value of member int64_field - */ -int64_t ContentFilterTestType::int64_field() const -{ - return m_int64_field; -} - -/*! - * @brief This function returns a reference to member int64_field - * @return Reference to member int64_field - */ -int64_t& ContentFilterTestType::int64_field() -{ - return m_int64_field; -} - - -/*! - * @brief This function sets a value in member uint64_field - * @param _uint64_field New value for member uint64_field - */ -void ContentFilterTestType::uint64_field( - uint64_t _uint64_field) -{ - m_uint64_field = _uint64_field; -} - -/*! - * @brief This function returns the value of member uint64_field - * @return Value of member uint64_field - */ -uint64_t ContentFilterTestType::uint64_field() const -{ - return m_uint64_field; -} - -/*! - * @brief This function returns a reference to member uint64_field - * @return Reference to member uint64_field - */ -uint64_t& ContentFilterTestType::uint64_field() -{ - return m_uint64_field; -} - - -/*! - * @brief This function sets a value in member float_field - * @param _float_field New value for member float_field - */ -void ContentFilterTestType::float_field( - float _float_field) -{ - m_float_field = _float_field; -} - -/*! - * @brief This function returns the value of member float_field - * @return Value of member float_field - */ -float ContentFilterTestType::float_field() const -{ - return m_float_field; -} - -/*! - * @brief This function returns a reference to member float_field - * @return Reference to member float_field - */ -float& ContentFilterTestType::float_field() -{ - return m_float_field; -} - - -/*! - * @brief This function sets a value in member double_field - * @param _double_field New value for member double_field - */ -void ContentFilterTestType::double_field( - double _double_field) -{ - m_double_field = _double_field; -} - -/*! - * @brief This function returns the value of member double_field - * @return Value of member double_field - */ -double ContentFilterTestType::double_field() const -{ - return m_double_field; -} - -/*! - * @brief This function returns a reference to member double_field - * @return Reference to member double_field - */ -double& ContentFilterTestType::double_field() -{ - return m_double_field; -} - - -/*! - * @brief This function sets a value in member long_double_field - * @param _long_double_field New value for member long_double_field - */ -void ContentFilterTestType::long_double_field( - long double _long_double_field) -{ - m_long_double_field = _long_double_field; -} - -/*! - * @brief This function returns the value of member long_double_field - * @return Value of member long_double_field - */ -long double ContentFilterTestType::long_double_field() const -{ - return m_long_double_field; -} - -/*! - * @brief This function returns a reference to member long_double_field - * @return Reference to member long_double_field - */ -long double& ContentFilterTestType::long_double_field() -{ - return m_long_double_field; -} - - -/*! - * @brief This function sets a value in member bool_field - * @param _bool_field New value for member bool_field - */ -void ContentFilterTestType::bool_field( - bool _bool_field) -{ - m_bool_field = _bool_field; -} - -/*! - * @brief This function returns the value of member bool_field - * @return Value of member bool_field - */ -bool ContentFilterTestType::bool_field() const -{ - return m_bool_field; -} - -/*! - * @brief This function returns a reference to member bool_field - * @return Reference to member bool_field - */ -bool& ContentFilterTestType::bool_field() -{ - return m_bool_field; -} - - -/*! - * @brief This function copies the value in member string_field - * @param _string_field New value to be copied in member string_field - */ -void ContentFilterTestType::string_field( - const std::string& _string_field) -{ - m_string_field = _string_field; -} - -/*! - * @brief This function moves the value in member string_field - * @param _string_field New value to be moved in member string_field - */ -void ContentFilterTestType::string_field( - std::string&& _string_field) -{ - m_string_field = std::move(_string_field); -} - -/*! - * @brief This function returns a constant reference to member string_field - * @return Constant reference to member string_field - */ -const std::string& ContentFilterTestType::string_field() const -{ - return m_string_field; -} - -/*! - * @brief This function returns a reference to member string_field - * @return Reference to member string_field - */ -std::string& ContentFilterTestType::string_field() -{ - return m_string_field; -} - - -/*! - * @brief This function sets a value in member enum_field - * @param _enum_field New value for member enum_field - */ -void ContentFilterTestType::enum_field( - Color _enum_field) -{ - m_enum_field = _enum_field; -} - -/*! - * @brief This function returns the value of member enum_field - * @return Value of member enum_field - */ -Color ContentFilterTestType::enum_field() const -{ - return m_enum_field; -} - -/*! - * @brief This function returns a reference to member enum_field - * @return Reference to member enum_field - */ -Color& ContentFilterTestType::enum_field() -{ - return m_enum_field; -} - - -/*! - * @brief This function sets a value in member enum2_field - * @param _enum2_field New value for member enum2_field - */ -void ContentFilterTestType::enum2_field( - Material _enum2_field) -{ - m_enum2_field = _enum2_field; -} - -/*! - * @brief This function returns the value of member enum2_field - * @return Value of member enum2_field - */ -Material ContentFilterTestType::enum2_field() const -{ - return m_enum2_field; -} - -/*! - * @brief This function returns a reference to member enum2_field - * @return Reference to member enum2_field - */ -Material& ContentFilterTestType::enum2_field() -{ - return m_enum2_field; -} - - -/*! - * @brief This function copies the value in member struct_field - * @param _struct_field New value to be copied in member struct_field - */ -void ContentFilterTestType::struct_field( - const StructType& _struct_field) -{ - m_struct_field = _struct_field; -} - -/*! - * @brief This function moves the value in member struct_field - * @param _struct_field New value to be moved in member struct_field - */ -void ContentFilterTestType::struct_field( - StructType&& _struct_field) -{ - m_struct_field = std::move(_struct_field); -} - -/*! - * @brief This function returns a constant reference to member struct_field - * @return Constant reference to member struct_field - */ -const StructType& ContentFilterTestType::struct_field() const -{ - return m_struct_field; -} - -/*! - * @brief This function returns a reference to member struct_field - * @return Reference to member struct_field - */ -StructType& ContentFilterTestType::struct_field() -{ - return m_struct_field; -} - - -/*! - * @brief This function copies the value in member array_char_field - * @param _array_char_field New value to be copied in member array_char_field - */ -void ContentFilterTestType::array_char_field( - const std::array& _array_char_field) -{ - m_array_char_field = _array_char_field; -} - -/*! - * @brief This function moves the value in member array_char_field - * @param _array_char_field New value to be moved in member array_char_field - */ -void ContentFilterTestType::array_char_field( - std::array&& _array_char_field) -{ - m_array_char_field = std::move(_array_char_field); -} - -/*! - * @brief This function returns a constant reference to member array_char_field - * @return Constant reference to member array_char_field - */ -const std::array& ContentFilterTestType::array_char_field() const -{ - return m_array_char_field; -} - -/*! - * @brief This function returns a reference to member array_char_field - * @return Reference to member array_char_field - */ -std::array& ContentFilterTestType::array_char_field() -{ - return m_array_char_field; -} - - -/*! - * @brief This function copies the value in member array_uint8_field - * @param _array_uint8_field New value to be copied in member array_uint8_field - */ -void ContentFilterTestType::array_uint8_field( - const std::array& _array_uint8_field) -{ - m_array_uint8_field = _array_uint8_field; -} - -/*! - * @brief This function moves the value in member array_uint8_field - * @param _array_uint8_field New value to be moved in member array_uint8_field - */ -void ContentFilterTestType::array_uint8_field( - std::array&& _array_uint8_field) -{ - m_array_uint8_field = std::move(_array_uint8_field); -} - -/*! - * @brief This function returns a constant reference to member array_uint8_field - * @return Constant reference to member array_uint8_field - */ -const std::array& ContentFilterTestType::array_uint8_field() const -{ - return m_array_uint8_field; -} - -/*! - * @brief This function returns a reference to member array_uint8_field - * @return Reference to member array_uint8_field - */ -std::array& ContentFilterTestType::array_uint8_field() -{ - return m_array_uint8_field; -} - - -/*! - * @brief This function copies the value in member array_int16_field - * @param _array_int16_field New value to be copied in member array_int16_field - */ -void ContentFilterTestType::array_int16_field( - const std::array& _array_int16_field) -{ - m_array_int16_field = _array_int16_field; -} - -/*! - * @brief This function moves the value in member array_int16_field - * @param _array_int16_field New value to be moved in member array_int16_field - */ -void ContentFilterTestType::array_int16_field( - std::array&& _array_int16_field) -{ - m_array_int16_field = std::move(_array_int16_field); -} - -/*! - * @brief This function returns a constant reference to member array_int16_field - * @return Constant reference to member array_int16_field - */ -const std::array& ContentFilterTestType::array_int16_field() const -{ - return m_array_int16_field; -} - -/*! - * @brief This function returns a reference to member array_int16_field - * @return Reference to member array_int16_field - */ -std::array& ContentFilterTestType::array_int16_field() -{ - return m_array_int16_field; -} - - -/*! - * @brief This function copies the value in member array_uint16_field - * @param _array_uint16_field New value to be copied in member array_uint16_field - */ -void ContentFilterTestType::array_uint16_field( - const std::array& _array_uint16_field) -{ - m_array_uint16_field = _array_uint16_field; -} - -/*! - * @brief This function moves the value in member array_uint16_field - * @param _array_uint16_field New value to be moved in member array_uint16_field - */ -void ContentFilterTestType::array_uint16_field( - std::array&& _array_uint16_field) -{ - m_array_uint16_field = std::move(_array_uint16_field); -} - -/*! - * @brief This function returns a constant reference to member array_uint16_field - * @return Constant reference to member array_uint16_field - */ -const std::array& ContentFilterTestType::array_uint16_field() const -{ - return m_array_uint16_field; -} - -/*! - * @brief This function returns a reference to member array_uint16_field - * @return Reference to member array_uint16_field - */ -std::array& ContentFilterTestType::array_uint16_field() -{ - return m_array_uint16_field; -} - - -/*! - * @brief This function copies the value in member array_int32_field - * @param _array_int32_field New value to be copied in member array_int32_field - */ -void ContentFilterTestType::array_int32_field( - const std::array& _array_int32_field) -{ - m_array_int32_field = _array_int32_field; -} - -/*! - * @brief This function moves the value in member array_int32_field - * @param _array_int32_field New value to be moved in member array_int32_field - */ -void ContentFilterTestType::array_int32_field( - std::array&& _array_int32_field) -{ - m_array_int32_field = std::move(_array_int32_field); -} - -/*! - * @brief This function returns a constant reference to member array_int32_field - * @return Constant reference to member array_int32_field - */ -const std::array& ContentFilterTestType::array_int32_field() const -{ - return m_array_int32_field; -} - -/*! - * @brief This function returns a reference to member array_int32_field - * @return Reference to member array_int32_field - */ -std::array& ContentFilterTestType::array_int32_field() -{ - return m_array_int32_field; -} - - -/*! - * @brief This function copies the value in member array_uint32_field - * @param _array_uint32_field New value to be copied in member array_uint32_field - */ -void ContentFilterTestType::array_uint32_field( - const std::array& _array_uint32_field) -{ - m_array_uint32_field = _array_uint32_field; -} - -/*! - * @brief This function moves the value in member array_uint32_field - * @param _array_uint32_field New value to be moved in member array_uint32_field - */ -void ContentFilterTestType::array_uint32_field( - std::array&& _array_uint32_field) -{ - m_array_uint32_field = std::move(_array_uint32_field); -} - -/*! - * @brief This function returns a constant reference to member array_uint32_field - * @return Constant reference to member array_uint32_field - */ -const std::array& ContentFilterTestType::array_uint32_field() const -{ - return m_array_uint32_field; -} - -/*! - * @brief This function returns a reference to member array_uint32_field - * @return Reference to member array_uint32_field - */ -std::array& ContentFilterTestType::array_uint32_field() -{ - return m_array_uint32_field; -} - - -/*! - * @brief This function copies the value in member array_int64_field - * @param _array_int64_field New value to be copied in member array_int64_field - */ -void ContentFilterTestType::array_int64_field( - const std::array& _array_int64_field) -{ - m_array_int64_field = _array_int64_field; -} - -/*! - * @brief This function moves the value in member array_int64_field - * @param _array_int64_field New value to be moved in member array_int64_field - */ -void ContentFilterTestType::array_int64_field( - std::array&& _array_int64_field) -{ - m_array_int64_field = std::move(_array_int64_field); -} - -/*! - * @brief This function returns a constant reference to member array_int64_field - * @return Constant reference to member array_int64_field - */ -const std::array& ContentFilterTestType::array_int64_field() const -{ - return m_array_int64_field; -} - -/*! - * @brief This function returns a reference to member array_int64_field - * @return Reference to member array_int64_field - */ -std::array& ContentFilterTestType::array_int64_field() -{ - return m_array_int64_field; -} - - -/*! - * @brief This function copies the value in member array_uint64_field - * @param _array_uint64_field New value to be copied in member array_uint64_field - */ -void ContentFilterTestType::array_uint64_field( - const std::array& _array_uint64_field) -{ - m_array_uint64_field = _array_uint64_field; -} - -/*! - * @brief This function moves the value in member array_uint64_field - * @param _array_uint64_field New value to be moved in member array_uint64_field - */ -void ContentFilterTestType::array_uint64_field( - std::array&& _array_uint64_field) -{ - m_array_uint64_field = std::move(_array_uint64_field); -} - -/*! - * @brief This function returns a constant reference to member array_uint64_field - * @return Constant reference to member array_uint64_field - */ -const std::array& ContentFilterTestType::array_uint64_field() const -{ - return m_array_uint64_field; -} - -/*! - * @brief This function returns a reference to member array_uint64_field - * @return Reference to member array_uint64_field - */ -std::array& ContentFilterTestType::array_uint64_field() -{ - return m_array_uint64_field; -} - - -/*! - * @brief This function copies the value in member array_float_field - * @param _array_float_field New value to be copied in member array_float_field - */ -void ContentFilterTestType::array_float_field( - const std::array& _array_float_field) -{ - m_array_float_field = _array_float_field; -} - -/*! - * @brief This function moves the value in member array_float_field - * @param _array_float_field New value to be moved in member array_float_field - */ -void ContentFilterTestType::array_float_field( - std::array&& _array_float_field) -{ - m_array_float_field = std::move(_array_float_field); -} - -/*! - * @brief This function returns a constant reference to member array_float_field - * @return Constant reference to member array_float_field - */ -const std::array& ContentFilterTestType::array_float_field() const -{ - return m_array_float_field; -} - -/*! - * @brief This function returns a reference to member array_float_field - * @return Reference to member array_float_field - */ -std::array& ContentFilterTestType::array_float_field() -{ - return m_array_float_field; -} - - -/*! - * @brief This function copies the value in member array_double_field - * @param _array_double_field New value to be copied in member array_double_field - */ -void ContentFilterTestType::array_double_field( - const std::array& _array_double_field) -{ - m_array_double_field = _array_double_field; -} - -/*! - * @brief This function moves the value in member array_double_field - * @param _array_double_field New value to be moved in member array_double_field - */ -void ContentFilterTestType::array_double_field( - std::array&& _array_double_field) -{ - m_array_double_field = std::move(_array_double_field); -} - -/*! - * @brief This function returns a constant reference to member array_double_field - * @return Constant reference to member array_double_field - */ -const std::array& ContentFilterTestType::array_double_field() const -{ - return m_array_double_field; -} - -/*! - * @brief This function returns a reference to member array_double_field - * @return Reference to member array_double_field - */ -std::array& ContentFilterTestType::array_double_field() -{ - return m_array_double_field; -} - - -/*! - * @brief This function copies the value in member array_long_double_field - * @param _array_long_double_field New value to be copied in member array_long_double_field - */ -void ContentFilterTestType::array_long_double_field( - const std::array& _array_long_double_field) -{ - m_array_long_double_field = _array_long_double_field; -} - -/*! - * @brief This function moves the value in member array_long_double_field - * @param _array_long_double_field New value to be moved in member array_long_double_field - */ -void ContentFilterTestType::array_long_double_field( - std::array&& _array_long_double_field) -{ - m_array_long_double_field = std::move(_array_long_double_field); -} - -/*! - * @brief This function returns a constant reference to member array_long_double_field - * @return Constant reference to member array_long_double_field - */ -const std::array& ContentFilterTestType::array_long_double_field() const -{ - return m_array_long_double_field; -} - -/*! - * @brief This function returns a reference to member array_long_double_field - * @return Reference to member array_long_double_field - */ -std::array& ContentFilterTestType::array_long_double_field() -{ - return m_array_long_double_field; -} - - -/*! - * @brief This function copies the value in member array_bool_field - * @param _array_bool_field New value to be copied in member array_bool_field - */ -void ContentFilterTestType::array_bool_field( - const std::array& _array_bool_field) -{ - m_array_bool_field = _array_bool_field; -} - -/*! - * @brief This function moves the value in member array_bool_field - * @param _array_bool_field New value to be moved in member array_bool_field - */ -void ContentFilterTestType::array_bool_field( - std::array&& _array_bool_field) -{ - m_array_bool_field = std::move(_array_bool_field); -} - -/*! - * @brief This function returns a constant reference to member array_bool_field - * @return Constant reference to member array_bool_field - */ -const std::array& ContentFilterTestType::array_bool_field() const -{ - return m_array_bool_field; -} - -/*! - * @brief This function returns a reference to member array_bool_field - * @return Reference to member array_bool_field - */ -std::array& ContentFilterTestType::array_bool_field() -{ - return m_array_bool_field; -} - - -/*! - * @brief This function copies the value in member array_string_field - * @param _array_string_field New value to be copied in member array_string_field - */ -void ContentFilterTestType::array_string_field( - const std::array& _array_string_field) -{ - m_array_string_field = _array_string_field; -} - -/*! - * @brief This function moves the value in member array_string_field - * @param _array_string_field New value to be moved in member array_string_field - */ -void ContentFilterTestType::array_string_field( - std::array&& _array_string_field) -{ - m_array_string_field = std::move(_array_string_field); -} - -/*! - * @brief This function returns a constant reference to member array_string_field - * @return Constant reference to member array_string_field - */ -const std::array& ContentFilterTestType::array_string_field() const -{ - return m_array_string_field; -} - -/*! - * @brief This function returns a reference to member array_string_field - * @return Reference to member array_string_field - */ -std::array& ContentFilterTestType::array_string_field() -{ - return m_array_string_field; -} - - -/*! - * @brief This function copies the value in member array_enum_field - * @param _array_enum_field New value to be copied in member array_enum_field - */ -void ContentFilterTestType::array_enum_field( - const std::array& _array_enum_field) -{ - m_array_enum_field = _array_enum_field; -} - -/*! - * @brief This function moves the value in member array_enum_field - * @param _array_enum_field New value to be moved in member array_enum_field - */ -void ContentFilterTestType::array_enum_field( - std::array&& _array_enum_field) -{ - m_array_enum_field = std::move(_array_enum_field); -} - -/*! - * @brief This function returns a constant reference to member array_enum_field - * @return Constant reference to member array_enum_field - */ -const std::array& ContentFilterTestType::array_enum_field() const -{ - return m_array_enum_field; -} - -/*! - * @brief This function returns a reference to member array_enum_field - * @return Reference to member array_enum_field - */ -std::array& ContentFilterTestType::array_enum_field() -{ - return m_array_enum_field; -} - - -/*! - * @brief This function copies the value in member array_enum2_field - * @param _array_enum2_field New value to be copied in member array_enum2_field - */ -void ContentFilterTestType::array_enum2_field( - const std::array& _array_enum2_field) -{ - m_array_enum2_field = _array_enum2_field; -} - -/*! - * @brief This function moves the value in member array_enum2_field - * @param _array_enum2_field New value to be moved in member array_enum2_field - */ -void ContentFilterTestType::array_enum2_field( - std::array&& _array_enum2_field) -{ - m_array_enum2_field = std::move(_array_enum2_field); -} - -/*! - * @brief This function returns a constant reference to member array_enum2_field - * @return Constant reference to member array_enum2_field - */ -const std::array& ContentFilterTestType::array_enum2_field() const -{ - return m_array_enum2_field; -} - -/*! - * @brief This function returns a reference to member array_enum2_field - * @return Reference to member array_enum2_field - */ -std::array& ContentFilterTestType::array_enum2_field() -{ - return m_array_enum2_field; -} - - -/*! - * @brief This function copies the value in member array_struct_field - * @param _array_struct_field New value to be copied in member array_struct_field - */ -void ContentFilterTestType::array_struct_field( - const std::array& _array_struct_field) -{ - m_array_struct_field = _array_struct_field; -} - -/*! - * @brief This function moves the value in member array_struct_field - * @param _array_struct_field New value to be moved in member array_struct_field - */ -void ContentFilterTestType::array_struct_field( - std::array&& _array_struct_field) -{ - m_array_struct_field = std::move(_array_struct_field); -} - -/*! - * @brief This function returns a constant reference to member array_struct_field - * @return Constant reference to member array_struct_field - */ -const std::array& ContentFilterTestType::array_struct_field() const -{ - return m_array_struct_field; -} - -/*! - * @brief This function returns a reference to member array_struct_field - * @return Reference to member array_struct_field - */ -std::array& ContentFilterTestType::array_struct_field() -{ - return m_array_struct_field; -} - - -/*! - * @brief This function copies the value in member bounded_sequence_char_field - * @param _bounded_sequence_char_field New value to be copied in member bounded_sequence_char_field - */ -void ContentFilterTestType::bounded_sequence_char_field( - const std::vector& _bounded_sequence_char_field) -{ - m_bounded_sequence_char_field = _bounded_sequence_char_field; -} - -/*! - * @brief This function moves the value in member bounded_sequence_char_field - * @param _bounded_sequence_char_field New value to be moved in member bounded_sequence_char_field - */ -void ContentFilterTestType::bounded_sequence_char_field( - std::vector&& _bounded_sequence_char_field) -{ - m_bounded_sequence_char_field = std::move(_bounded_sequence_char_field); -} - -/*! - * @brief This function returns a constant reference to member bounded_sequence_char_field - * @return Constant reference to member bounded_sequence_char_field - */ -const std::vector& ContentFilterTestType::bounded_sequence_char_field() const -{ - return m_bounded_sequence_char_field; -} - -/*! - * @brief This function returns a reference to member bounded_sequence_char_field - * @return Reference to member bounded_sequence_char_field - */ -std::vector& ContentFilterTestType::bounded_sequence_char_field() -{ - return m_bounded_sequence_char_field; -} - - -/*! - * @brief This function copies the value in member bounded_sequence_uint8_field - * @param _bounded_sequence_uint8_field New value to be copied in member bounded_sequence_uint8_field - */ -void ContentFilterTestType::bounded_sequence_uint8_field( - const std::vector& _bounded_sequence_uint8_field) -{ - m_bounded_sequence_uint8_field = _bounded_sequence_uint8_field; -} - -/*! - * @brief This function moves the value in member bounded_sequence_uint8_field - * @param _bounded_sequence_uint8_field New value to be moved in member bounded_sequence_uint8_field - */ -void ContentFilterTestType::bounded_sequence_uint8_field( - std::vector&& _bounded_sequence_uint8_field) -{ - m_bounded_sequence_uint8_field = std::move(_bounded_sequence_uint8_field); -} - -/*! - * @brief This function returns a constant reference to member bounded_sequence_uint8_field - * @return Constant reference to member bounded_sequence_uint8_field - */ -const std::vector& ContentFilterTestType::bounded_sequence_uint8_field() const -{ - return m_bounded_sequence_uint8_field; -} - -/*! - * @brief This function returns a reference to member bounded_sequence_uint8_field - * @return Reference to member bounded_sequence_uint8_field - */ -std::vector& ContentFilterTestType::bounded_sequence_uint8_field() -{ - return m_bounded_sequence_uint8_field; -} - - -/*! - * @brief This function copies the value in member bounded_sequence_int16_field - * @param _bounded_sequence_int16_field New value to be copied in member bounded_sequence_int16_field - */ -void ContentFilterTestType::bounded_sequence_int16_field( - const std::vector& _bounded_sequence_int16_field) -{ - m_bounded_sequence_int16_field = _bounded_sequence_int16_field; -} - -/*! - * @brief This function moves the value in member bounded_sequence_int16_field - * @param _bounded_sequence_int16_field New value to be moved in member bounded_sequence_int16_field - */ -void ContentFilterTestType::bounded_sequence_int16_field( - std::vector&& _bounded_sequence_int16_field) -{ - m_bounded_sequence_int16_field = std::move(_bounded_sequence_int16_field); -} - -/*! - * @brief This function returns a constant reference to member bounded_sequence_int16_field - * @return Constant reference to member bounded_sequence_int16_field - */ -const std::vector& ContentFilterTestType::bounded_sequence_int16_field() const -{ - return m_bounded_sequence_int16_field; -} - -/*! - * @brief This function returns a reference to member bounded_sequence_int16_field - * @return Reference to member bounded_sequence_int16_field - */ -std::vector& ContentFilterTestType::bounded_sequence_int16_field() -{ - return m_bounded_sequence_int16_field; -} - - -/*! - * @brief This function copies the value in member bounded_sequence_uint16_field - * @param _bounded_sequence_uint16_field New value to be copied in member bounded_sequence_uint16_field - */ -void ContentFilterTestType::bounded_sequence_uint16_field( - const std::vector& _bounded_sequence_uint16_field) -{ - m_bounded_sequence_uint16_field = _bounded_sequence_uint16_field; -} - -/*! - * @brief This function moves the value in member bounded_sequence_uint16_field - * @param _bounded_sequence_uint16_field New value to be moved in member bounded_sequence_uint16_field - */ -void ContentFilterTestType::bounded_sequence_uint16_field( - std::vector&& _bounded_sequence_uint16_field) -{ - m_bounded_sequence_uint16_field = std::move(_bounded_sequence_uint16_field); -} - -/*! - * @brief This function returns a constant reference to member bounded_sequence_uint16_field - * @return Constant reference to member bounded_sequence_uint16_field - */ -const std::vector& ContentFilterTestType::bounded_sequence_uint16_field() const -{ - return m_bounded_sequence_uint16_field; -} - -/*! - * @brief This function returns a reference to member bounded_sequence_uint16_field - * @return Reference to member bounded_sequence_uint16_field - */ -std::vector& ContentFilterTestType::bounded_sequence_uint16_field() -{ - return m_bounded_sequence_uint16_field; -} - - -/*! - * @brief This function copies the value in member bounded_sequence_int32_field - * @param _bounded_sequence_int32_field New value to be copied in member bounded_sequence_int32_field - */ -void ContentFilterTestType::bounded_sequence_int32_field( - const std::vector& _bounded_sequence_int32_field) -{ - m_bounded_sequence_int32_field = _bounded_sequence_int32_field; -} - -/*! - * @brief This function moves the value in member bounded_sequence_int32_field - * @param _bounded_sequence_int32_field New value to be moved in member bounded_sequence_int32_field - */ -void ContentFilterTestType::bounded_sequence_int32_field( - std::vector&& _bounded_sequence_int32_field) -{ - m_bounded_sequence_int32_field = std::move(_bounded_sequence_int32_field); -} - -/*! - * @brief This function returns a constant reference to member bounded_sequence_int32_field - * @return Constant reference to member bounded_sequence_int32_field - */ -const std::vector& ContentFilterTestType::bounded_sequence_int32_field() const -{ - return m_bounded_sequence_int32_field; -} - -/*! - * @brief This function returns a reference to member bounded_sequence_int32_field - * @return Reference to member bounded_sequence_int32_field - */ -std::vector& ContentFilterTestType::bounded_sequence_int32_field() -{ - return m_bounded_sequence_int32_field; -} - - -/*! - * @brief This function copies the value in member bounded_sequence_uint32_field - * @param _bounded_sequence_uint32_field New value to be copied in member bounded_sequence_uint32_field - */ -void ContentFilterTestType::bounded_sequence_uint32_field( - const std::vector& _bounded_sequence_uint32_field) -{ - m_bounded_sequence_uint32_field = _bounded_sequence_uint32_field; -} - -/*! - * @brief This function moves the value in member bounded_sequence_uint32_field - * @param _bounded_sequence_uint32_field New value to be moved in member bounded_sequence_uint32_field - */ -void ContentFilterTestType::bounded_sequence_uint32_field( - std::vector&& _bounded_sequence_uint32_field) -{ - m_bounded_sequence_uint32_field = std::move(_bounded_sequence_uint32_field); -} - -/*! - * @brief This function returns a constant reference to member bounded_sequence_uint32_field - * @return Constant reference to member bounded_sequence_uint32_field - */ -const std::vector& ContentFilterTestType::bounded_sequence_uint32_field() const -{ - return m_bounded_sequence_uint32_field; -} - -/*! - * @brief This function returns a reference to member bounded_sequence_uint32_field - * @return Reference to member bounded_sequence_uint32_field - */ -std::vector& ContentFilterTestType::bounded_sequence_uint32_field() -{ - return m_bounded_sequence_uint32_field; -} - - -/*! - * @brief This function copies the value in member bounded_sequence_int64_field - * @param _bounded_sequence_int64_field New value to be copied in member bounded_sequence_int64_field - */ -void ContentFilterTestType::bounded_sequence_int64_field( - const std::vector& _bounded_sequence_int64_field) -{ - m_bounded_sequence_int64_field = _bounded_sequence_int64_field; -} - -/*! - * @brief This function moves the value in member bounded_sequence_int64_field - * @param _bounded_sequence_int64_field New value to be moved in member bounded_sequence_int64_field - */ -void ContentFilterTestType::bounded_sequence_int64_field( - std::vector&& _bounded_sequence_int64_field) -{ - m_bounded_sequence_int64_field = std::move(_bounded_sequence_int64_field); -} - -/*! - * @brief This function returns a constant reference to member bounded_sequence_int64_field - * @return Constant reference to member bounded_sequence_int64_field - */ -const std::vector& ContentFilterTestType::bounded_sequence_int64_field() const -{ - return m_bounded_sequence_int64_field; -} - -/*! - * @brief This function returns a reference to member bounded_sequence_int64_field - * @return Reference to member bounded_sequence_int64_field - */ -std::vector& ContentFilterTestType::bounded_sequence_int64_field() -{ - return m_bounded_sequence_int64_field; -} - - -/*! - * @brief This function copies the value in member bounded_sequence_uint64_field - * @param _bounded_sequence_uint64_field New value to be copied in member bounded_sequence_uint64_field - */ -void ContentFilterTestType::bounded_sequence_uint64_field( - const std::vector& _bounded_sequence_uint64_field) -{ - m_bounded_sequence_uint64_field = _bounded_sequence_uint64_field; -} - -/*! - * @brief This function moves the value in member bounded_sequence_uint64_field - * @param _bounded_sequence_uint64_field New value to be moved in member bounded_sequence_uint64_field - */ -void ContentFilterTestType::bounded_sequence_uint64_field( - std::vector&& _bounded_sequence_uint64_field) -{ - m_bounded_sequence_uint64_field = std::move(_bounded_sequence_uint64_field); -} - -/*! - * @brief This function returns a constant reference to member bounded_sequence_uint64_field - * @return Constant reference to member bounded_sequence_uint64_field - */ -const std::vector& ContentFilterTestType::bounded_sequence_uint64_field() const -{ - return m_bounded_sequence_uint64_field; -} - -/*! - * @brief This function returns a reference to member bounded_sequence_uint64_field - * @return Reference to member bounded_sequence_uint64_field - */ -std::vector& ContentFilterTestType::bounded_sequence_uint64_field() -{ - return m_bounded_sequence_uint64_field; -} - - -/*! - * @brief This function copies the value in member bounded_sequence_float_field - * @param _bounded_sequence_float_field New value to be copied in member bounded_sequence_float_field - */ -void ContentFilterTestType::bounded_sequence_float_field( - const std::vector& _bounded_sequence_float_field) -{ - m_bounded_sequence_float_field = _bounded_sequence_float_field; -} - -/*! - * @brief This function moves the value in member bounded_sequence_float_field - * @param _bounded_sequence_float_field New value to be moved in member bounded_sequence_float_field - */ -void ContentFilterTestType::bounded_sequence_float_field( - std::vector&& _bounded_sequence_float_field) -{ - m_bounded_sequence_float_field = std::move(_bounded_sequence_float_field); -} - -/*! - * @brief This function returns a constant reference to member bounded_sequence_float_field - * @return Constant reference to member bounded_sequence_float_field - */ -const std::vector& ContentFilterTestType::bounded_sequence_float_field() const -{ - return m_bounded_sequence_float_field; -} - -/*! - * @brief This function returns a reference to member bounded_sequence_float_field - * @return Reference to member bounded_sequence_float_field - */ -std::vector& ContentFilterTestType::bounded_sequence_float_field() -{ - return m_bounded_sequence_float_field; -} - - -/*! - * @brief This function copies the value in member bounded_sequence_double_field - * @param _bounded_sequence_double_field New value to be copied in member bounded_sequence_double_field - */ -void ContentFilterTestType::bounded_sequence_double_field( - const std::vector& _bounded_sequence_double_field) -{ - m_bounded_sequence_double_field = _bounded_sequence_double_field; -} - -/*! - * @brief This function moves the value in member bounded_sequence_double_field - * @param _bounded_sequence_double_field New value to be moved in member bounded_sequence_double_field - */ -void ContentFilterTestType::bounded_sequence_double_field( - std::vector&& _bounded_sequence_double_field) -{ - m_bounded_sequence_double_field = std::move(_bounded_sequence_double_field); -} - -/*! - * @brief This function returns a constant reference to member bounded_sequence_double_field - * @return Constant reference to member bounded_sequence_double_field - */ -const std::vector& ContentFilterTestType::bounded_sequence_double_field() const -{ - return m_bounded_sequence_double_field; -} - -/*! - * @brief This function returns a reference to member bounded_sequence_double_field - * @return Reference to member bounded_sequence_double_field - */ -std::vector& ContentFilterTestType::bounded_sequence_double_field() -{ - return m_bounded_sequence_double_field; -} - - -/*! - * @brief This function copies the value in member bounded_sequence_long_double_field - * @param _bounded_sequence_long_double_field New value to be copied in member bounded_sequence_long_double_field - */ -void ContentFilterTestType::bounded_sequence_long_double_field( - const std::vector& _bounded_sequence_long_double_field) -{ - m_bounded_sequence_long_double_field = _bounded_sequence_long_double_field; -} - -/*! - * @brief This function moves the value in member bounded_sequence_long_double_field - * @param _bounded_sequence_long_double_field New value to be moved in member bounded_sequence_long_double_field - */ -void ContentFilterTestType::bounded_sequence_long_double_field( - std::vector&& _bounded_sequence_long_double_field) -{ - m_bounded_sequence_long_double_field = std::move(_bounded_sequence_long_double_field); -} - -/*! - * @brief This function returns a constant reference to member bounded_sequence_long_double_field - * @return Constant reference to member bounded_sequence_long_double_field - */ -const std::vector& ContentFilterTestType::bounded_sequence_long_double_field() const -{ - return m_bounded_sequence_long_double_field; -} - -/*! - * @brief This function returns a reference to member bounded_sequence_long_double_field - * @return Reference to member bounded_sequence_long_double_field - */ -std::vector& ContentFilterTestType::bounded_sequence_long_double_field() -{ - return m_bounded_sequence_long_double_field; -} - - -/*! - * @brief This function copies the value in member bounded_sequence_bool_field - * @param _bounded_sequence_bool_field New value to be copied in member bounded_sequence_bool_field - */ -void ContentFilterTestType::bounded_sequence_bool_field( - const std::vector& _bounded_sequence_bool_field) -{ - m_bounded_sequence_bool_field = _bounded_sequence_bool_field; -} - -/*! - * @brief This function moves the value in member bounded_sequence_bool_field - * @param _bounded_sequence_bool_field New value to be moved in member bounded_sequence_bool_field - */ -void ContentFilterTestType::bounded_sequence_bool_field( - std::vector&& _bounded_sequence_bool_field) -{ - m_bounded_sequence_bool_field = std::move(_bounded_sequence_bool_field); -} - -/*! - * @brief This function returns a constant reference to member bounded_sequence_bool_field - * @return Constant reference to member bounded_sequence_bool_field - */ -const std::vector& ContentFilterTestType::bounded_sequence_bool_field() const -{ - return m_bounded_sequence_bool_field; -} - -/*! - * @brief This function returns a reference to member bounded_sequence_bool_field - * @return Reference to member bounded_sequence_bool_field - */ -std::vector& ContentFilterTestType::bounded_sequence_bool_field() -{ - return m_bounded_sequence_bool_field; -} - - -/*! - * @brief This function copies the value in member bounded_sequence_string_field - * @param _bounded_sequence_string_field New value to be copied in member bounded_sequence_string_field - */ -void ContentFilterTestType::bounded_sequence_string_field( - const std::vector& _bounded_sequence_string_field) -{ - m_bounded_sequence_string_field = _bounded_sequence_string_field; -} - -/*! - * @brief This function moves the value in member bounded_sequence_string_field - * @param _bounded_sequence_string_field New value to be moved in member bounded_sequence_string_field - */ -void ContentFilterTestType::bounded_sequence_string_field( - std::vector&& _bounded_sequence_string_field) -{ - m_bounded_sequence_string_field = std::move(_bounded_sequence_string_field); -} - -/*! - * @brief This function returns a constant reference to member bounded_sequence_string_field - * @return Constant reference to member bounded_sequence_string_field - */ -const std::vector& ContentFilterTestType::bounded_sequence_string_field() const -{ - return m_bounded_sequence_string_field; -} - -/*! - * @brief This function returns a reference to member bounded_sequence_string_field - * @return Reference to member bounded_sequence_string_field - */ -std::vector& ContentFilterTestType::bounded_sequence_string_field() -{ - return m_bounded_sequence_string_field; -} - - -/*! - * @brief This function copies the value in member bounded_sequence_enum_field - * @param _bounded_sequence_enum_field New value to be copied in member bounded_sequence_enum_field - */ -void ContentFilterTestType::bounded_sequence_enum_field( - const std::vector& _bounded_sequence_enum_field) -{ - m_bounded_sequence_enum_field = _bounded_sequence_enum_field; -} - -/*! - * @brief This function moves the value in member bounded_sequence_enum_field - * @param _bounded_sequence_enum_field New value to be moved in member bounded_sequence_enum_field - */ -void ContentFilterTestType::bounded_sequence_enum_field( - std::vector&& _bounded_sequence_enum_field) -{ - m_bounded_sequence_enum_field = std::move(_bounded_sequence_enum_field); -} - -/*! - * @brief This function returns a constant reference to member bounded_sequence_enum_field - * @return Constant reference to member bounded_sequence_enum_field - */ -const std::vector& ContentFilterTestType::bounded_sequence_enum_field() const -{ - return m_bounded_sequence_enum_field; -} - -/*! - * @brief This function returns a reference to member bounded_sequence_enum_field - * @return Reference to member bounded_sequence_enum_field - */ -std::vector& ContentFilterTestType::bounded_sequence_enum_field() -{ - return m_bounded_sequence_enum_field; -} - - -/*! - * @brief This function copies the value in member bounded_sequence_enum2_field - * @param _bounded_sequence_enum2_field New value to be copied in member bounded_sequence_enum2_field - */ -void ContentFilterTestType::bounded_sequence_enum2_field( - const std::vector& _bounded_sequence_enum2_field) -{ - m_bounded_sequence_enum2_field = _bounded_sequence_enum2_field; -} - -/*! - * @brief This function moves the value in member bounded_sequence_enum2_field - * @param _bounded_sequence_enum2_field New value to be moved in member bounded_sequence_enum2_field - */ -void ContentFilterTestType::bounded_sequence_enum2_field( - std::vector&& _bounded_sequence_enum2_field) -{ - m_bounded_sequence_enum2_field = std::move(_bounded_sequence_enum2_field); -} - -/*! - * @brief This function returns a constant reference to member bounded_sequence_enum2_field - * @return Constant reference to member bounded_sequence_enum2_field - */ -const std::vector& ContentFilterTestType::bounded_sequence_enum2_field() const -{ - return m_bounded_sequence_enum2_field; -} - -/*! - * @brief This function returns a reference to member bounded_sequence_enum2_field - * @return Reference to member bounded_sequence_enum2_field - */ -std::vector& ContentFilterTestType::bounded_sequence_enum2_field() -{ - return m_bounded_sequence_enum2_field; -} - - -/*! - * @brief This function copies the value in member bounded_sequence_struct_field - * @param _bounded_sequence_struct_field New value to be copied in member bounded_sequence_struct_field - */ -void ContentFilterTestType::bounded_sequence_struct_field( - const std::vector& _bounded_sequence_struct_field) -{ - m_bounded_sequence_struct_field = _bounded_sequence_struct_field; -} - -/*! - * @brief This function moves the value in member bounded_sequence_struct_field - * @param _bounded_sequence_struct_field New value to be moved in member bounded_sequence_struct_field - */ -void ContentFilterTestType::bounded_sequence_struct_field( - std::vector&& _bounded_sequence_struct_field) -{ - m_bounded_sequence_struct_field = std::move(_bounded_sequence_struct_field); -} - -/*! - * @brief This function returns a constant reference to member bounded_sequence_struct_field - * @return Constant reference to member bounded_sequence_struct_field - */ -const std::vector& ContentFilterTestType::bounded_sequence_struct_field() const -{ - return m_bounded_sequence_struct_field; -} - -/*! - * @brief This function returns a reference to member bounded_sequence_struct_field - * @return Reference to member bounded_sequence_struct_field - */ -std::vector& ContentFilterTestType::bounded_sequence_struct_field() -{ - return m_bounded_sequence_struct_field; -} - - -/*! - * @brief This function copies the value in member unbounded_sequence_char_field - * @param _unbounded_sequence_char_field New value to be copied in member unbounded_sequence_char_field - */ -void ContentFilterTestType::unbounded_sequence_char_field( - const std::vector& _unbounded_sequence_char_field) -{ - m_unbounded_sequence_char_field = _unbounded_sequence_char_field; -} - -/*! - * @brief This function moves the value in member unbounded_sequence_char_field - * @param _unbounded_sequence_char_field New value to be moved in member unbounded_sequence_char_field - */ -void ContentFilterTestType::unbounded_sequence_char_field( - std::vector&& _unbounded_sequence_char_field) -{ - m_unbounded_sequence_char_field = std::move(_unbounded_sequence_char_field); -} - -/*! - * @brief This function returns a constant reference to member unbounded_sequence_char_field - * @return Constant reference to member unbounded_sequence_char_field - */ -const std::vector& ContentFilterTestType::unbounded_sequence_char_field() const -{ - return m_unbounded_sequence_char_field; -} - -/*! - * @brief This function returns a reference to member unbounded_sequence_char_field - * @return Reference to member unbounded_sequence_char_field - */ -std::vector& ContentFilterTestType::unbounded_sequence_char_field() -{ - return m_unbounded_sequence_char_field; -} - - -/*! - * @brief This function copies the value in member unbounded_sequence_uint8_field - * @param _unbounded_sequence_uint8_field New value to be copied in member unbounded_sequence_uint8_field - */ -void ContentFilterTestType::unbounded_sequence_uint8_field( - const std::vector& _unbounded_sequence_uint8_field) -{ - m_unbounded_sequence_uint8_field = _unbounded_sequence_uint8_field; -} - -/*! - * @brief This function moves the value in member unbounded_sequence_uint8_field - * @param _unbounded_sequence_uint8_field New value to be moved in member unbounded_sequence_uint8_field - */ -void ContentFilterTestType::unbounded_sequence_uint8_field( - std::vector&& _unbounded_sequence_uint8_field) -{ - m_unbounded_sequence_uint8_field = std::move(_unbounded_sequence_uint8_field); -} - -/*! - * @brief This function returns a constant reference to member unbounded_sequence_uint8_field - * @return Constant reference to member unbounded_sequence_uint8_field - */ -const std::vector& ContentFilterTestType::unbounded_sequence_uint8_field() const -{ - return m_unbounded_sequence_uint8_field; -} - -/*! - * @brief This function returns a reference to member unbounded_sequence_uint8_field - * @return Reference to member unbounded_sequence_uint8_field - */ -std::vector& ContentFilterTestType::unbounded_sequence_uint8_field() -{ - return m_unbounded_sequence_uint8_field; -} - - -/*! - * @brief This function copies the value in member unbounded_sequence_int16_field - * @param _unbounded_sequence_int16_field New value to be copied in member unbounded_sequence_int16_field - */ -void ContentFilterTestType::unbounded_sequence_int16_field( - const std::vector& _unbounded_sequence_int16_field) -{ - m_unbounded_sequence_int16_field = _unbounded_sequence_int16_field; -} - -/*! - * @brief This function moves the value in member unbounded_sequence_int16_field - * @param _unbounded_sequence_int16_field New value to be moved in member unbounded_sequence_int16_field - */ -void ContentFilterTestType::unbounded_sequence_int16_field( - std::vector&& _unbounded_sequence_int16_field) -{ - m_unbounded_sequence_int16_field = std::move(_unbounded_sequence_int16_field); -} - -/*! - * @brief This function returns a constant reference to member unbounded_sequence_int16_field - * @return Constant reference to member unbounded_sequence_int16_field - */ -const std::vector& ContentFilterTestType::unbounded_sequence_int16_field() const -{ - return m_unbounded_sequence_int16_field; -} - -/*! - * @brief This function returns a reference to member unbounded_sequence_int16_field - * @return Reference to member unbounded_sequence_int16_field - */ -std::vector& ContentFilterTestType::unbounded_sequence_int16_field() -{ - return m_unbounded_sequence_int16_field; -} - - -/*! - * @brief This function copies the value in member unbounded_sequence_uint16_field - * @param _unbounded_sequence_uint16_field New value to be copied in member unbounded_sequence_uint16_field - */ -void ContentFilterTestType::unbounded_sequence_uint16_field( - const std::vector& _unbounded_sequence_uint16_field) -{ - m_unbounded_sequence_uint16_field = _unbounded_sequence_uint16_field; -} - -/*! - * @brief This function moves the value in member unbounded_sequence_uint16_field - * @param _unbounded_sequence_uint16_field New value to be moved in member unbounded_sequence_uint16_field - */ -void ContentFilterTestType::unbounded_sequence_uint16_field( - std::vector&& _unbounded_sequence_uint16_field) -{ - m_unbounded_sequence_uint16_field = std::move(_unbounded_sequence_uint16_field); -} - -/*! - * @brief This function returns a constant reference to member unbounded_sequence_uint16_field - * @return Constant reference to member unbounded_sequence_uint16_field - */ -const std::vector& ContentFilterTestType::unbounded_sequence_uint16_field() const -{ - return m_unbounded_sequence_uint16_field; -} - -/*! - * @brief This function returns a reference to member unbounded_sequence_uint16_field - * @return Reference to member unbounded_sequence_uint16_field - */ -std::vector& ContentFilterTestType::unbounded_sequence_uint16_field() -{ - return m_unbounded_sequence_uint16_field; -} - - -/*! - * @brief This function copies the value in member unbounded_sequence_int32_field - * @param _unbounded_sequence_int32_field New value to be copied in member unbounded_sequence_int32_field - */ -void ContentFilterTestType::unbounded_sequence_int32_field( - const std::vector& _unbounded_sequence_int32_field) -{ - m_unbounded_sequence_int32_field = _unbounded_sequence_int32_field; -} - -/*! - * @brief This function moves the value in member unbounded_sequence_int32_field - * @param _unbounded_sequence_int32_field New value to be moved in member unbounded_sequence_int32_field - */ -void ContentFilterTestType::unbounded_sequence_int32_field( - std::vector&& _unbounded_sequence_int32_field) -{ - m_unbounded_sequence_int32_field = std::move(_unbounded_sequence_int32_field); -} - -/*! - * @brief This function returns a constant reference to member unbounded_sequence_int32_field - * @return Constant reference to member unbounded_sequence_int32_field - */ -const std::vector& ContentFilterTestType::unbounded_sequence_int32_field() const -{ - return m_unbounded_sequence_int32_field; -} - -/*! - * @brief This function returns a reference to member unbounded_sequence_int32_field - * @return Reference to member unbounded_sequence_int32_field - */ -std::vector& ContentFilterTestType::unbounded_sequence_int32_field() -{ - return m_unbounded_sequence_int32_field; -} - - -/*! - * @brief This function copies the value in member unbounded_sequence_uint32_field - * @param _unbounded_sequence_uint32_field New value to be copied in member unbounded_sequence_uint32_field - */ -void ContentFilterTestType::unbounded_sequence_uint32_field( - const std::vector& _unbounded_sequence_uint32_field) -{ - m_unbounded_sequence_uint32_field = _unbounded_sequence_uint32_field; -} - -/*! - * @brief This function moves the value in member unbounded_sequence_uint32_field - * @param _unbounded_sequence_uint32_field New value to be moved in member unbounded_sequence_uint32_field - */ -void ContentFilterTestType::unbounded_sequence_uint32_field( - std::vector&& _unbounded_sequence_uint32_field) -{ - m_unbounded_sequence_uint32_field = std::move(_unbounded_sequence_uint32_field); -} - -/*! - * @brief This function returns a constant reference to member unbounded_sequence_uint32_field - * @return Constant reference to member unbounded_sequence_uint32_field - */ -const std::vector& ContentFilterTestType::unbounded_sequence_uint32_field() const -{ - return m_unbounded_sequence_uint32_field; -} - -/*! - * @brief This function returns a reference to member unbounded_sequence_uint32_field - * @return Reference to member unbounded_sequence_uint32_field - */ -std::vector& ContentFilterTestType::unbounded_sequence_uint32_field() -{ - return m_unbounded_sequence_uint32_field; -} - - -/*! - * @brief This function copies the value in member unbounded_sequence_int64_field - * @param _unbounded_sequence_int64_field New value to be copied in member unbounded_sequence_int64_field - */ -void ContentFilterTestType::unbounded_sequence_int64_field( - const std::vector& _unbounded_sequence_int64_field) -{ - m_unbounded_sequence_int64_field = _unbounded_sequence_int64_field; -} - -/*! - * @brief This function moves the value in member unbounded_sequence_int64_field - * @param _unbounded_sequence_int64_field New value to be moved in member unbounded_sequence_int64_field - */ -void ContentFilterTestType::unbounded_sequence_int64_field( - std::vector&& _unbounded_sequence_int64_field) -{ - m_unbounded_sequence_int64_field = std::move(_unbounded_sequence_int64_field); -} - -/*! - * @brief This function returns a constant reference to member unbounded_sequence_int64_field - * @return Constant reference to member unbounded_sequence_int64_field - */ -const std::vector& ContentFilterTestType::unbounded_sequence_int64_field() const -{ - return m_unbounded_sequence_int64_field; -} - -/*! - * @brief This function returns a reference to member unbounded_sequence_int64_field - * @return Reference to member unbounded_sequence_int64_field - */ -std::vector& ContentFilterTestType::unbounded_sequence_int64_field() -{ - return m_unbounded_sequence_int64_field; -} - - -/*! - * @brief This function copies the value in member unbounded_sequence_uint64_field - * @param _unbounded_sequence_uint64_field New value to be copied in member unbounded_sequence_uint64_field - */ -void ContentFilterTestType::unbounded_sequence_uint64_field( - const std::vector& _unbounded_sequence_uint64_field) -{ - m_unbounded_sequence_uint64_field = _unbounded_sequence_uint64_field; -} - -/*! - * @brief This function moves the value in member unbounded_sequence_uint64_field - * @param _unbounded_sequence_uint64_field New value to be moved in member unbounded_sequence_uint64_field - */ -void ContentFilterTestType::unbounded_sequence_uint64_field( - std::vector&& _unbounded_sequence_uint64_field) -{ - m_unbounded_sequence_uint64_field = std::move(_unbounded_sequence_uint64_field); -} - -/*! - * @brief This function returns a constant reference to member unbounded_sequence_uint64_field - * @return Constant reference to member unbounded_sequence_uint64_field - */ -const std::vector& ContentFilterTestType::unbounded_sequence_uint64_field() const -{ - return m_unbounded_sequence_uint64_field; -} - -/*! - * @brief This function returns a reference to member unbounded_sequence_uint64_field - * @return Reference to member unbounded_sequence_uint64_field - */ -std::vector& ContentFilterTestType::unbounded_sequence_uint64_field() -{ - return m_unbounded_sequence_uint64_field; -} - - -/*! - * @brief This function copies the value in member unbounded_sequence_float_field - * @param _unbounded_sequence_float_field New value to be copied in member unbounded_sequence_float_field - */ -void ContentFilterTestType::unbounded_sequence_float_field( - const std::vector& _unbounded_sequence_float_field) -{ - m_unbounded_sequence_float_field = _unbounded_sequence_float_field; -} - -/*! - * @brief This function moves the value in member unbounded_sequence_float_field - * @param _unbounded_sequence_float_field New value to be moved in member unbounded_sequence_float_field - */ -void ContentFilterTestType::unbounded_sequence_float_field( - std::vector&& _unbounded_sequence_float_field) -{ - m_unbounded_sequence_float_field = std::move(_unbounded_sequence_float_field); -} - -/*! - * @brief This function returns a constant reference to member unbounded_sequence_float_field - * @return Constant reference to member unbounded_sequence_float_field - */ -const std::vector& ContentFilterTestType::unbounded_sequence_float_field() const -{ - return m_unbounded_sequence_float_field; -} - -/*! - * @brief This function returns a reference to member unbounded_sequence_float_field - * @return Reference to member unbounded_sequence_float_field - */ -std::vector& ContentFilterTestType::unbounded_sequence_float_field() -{ - return m_unbounded_sequence_float_field; -} - - -/*! - * @brief This function copies the value in member unbounded_sequence_double_field - * @param _unbounded_sequence_double_field New value to be copied in member unbounded_sequence_double_field - */ -void ContentFilterTestType::unbounded_sequence_double_field( - const std::vector& _unbounded_sequence_double_field) -{ - m_unbounded_sequence_double_field = _unbounded_sequence_double_field; -} - -/*! - * @brief This function moves the value in member unbounded_sequence_double_field - * @param _unbounded_sequence_double_field New value to be moved in member unbounded_sequence_double_field - */ -void ContentFilterTestType::unbounded_sequence_double_field( - std::vector&& _unbounded_sequence_double_field) -{ - m_unbounded_sequence_double_field = std::move(_unbounded_sequence_double_field); -} - -/*! - * @brief This function returns a constant reference to member unbounded_sequence_double_field - * @return Constant reference to member unbounded_sequence_double_field - */ -const std::vector& ContentFilterTestType::unbounded_sequence_double_field() const -{ - return m_unbounded_sequence_double_field; -} - -/*! - * @brief This function returns a reference to member unbounded_sequence_double_field - * @return Reference to member unbounded_sequence_double_field - */ -std::vector& ContentFilterTestType::unbounded_sequence_double_field() -{ - return m_unbounded_sequence_double_field; -} - - -/*! - * @brief This function copies the value in member unbounded_sequence_long_double_field - * @param _unbounded_sequence_long_double_field New value to be copied in member unbounded_sequence_long_double_field - */ -void ContentFilterTestType::unbounded_sequence_long_double_field( - const std::vector& _unbounded_sequence_long_double_field) -{ - m_unbounded_sequence_long_double_field = _unbounded_sequence_long_double_field; -} - -/*! - * @brief This function moves the value in member unbounded_sequence_long_double_field - * @param _unbounded_sequence_long_double_field New value to be moved in member unbounded_sequence_long_double_field - */ -void ContentFilterTestType::unbounded_sequence_long_double_field( - std::vector&& _unbounded_sequence_long_double_field) -{ - m_unbounded_sequence_long_double_field = std::move(_unbounded_sequence_long_double_field); -} - -/*! - * @brief This function returns a constant reference to member unbounded_sequence_long_double_field - * @return Constant reference to member unbounded_sequence_long_double_field - */ -const std::vector& ContentFilterTestType::unbounded_sequence_long_double_field() const -{ - return m_unbounded_sequence_long_double_field; -} - -/*! - * @brief This function returns a reference to member unbounded_sequence_long_double_field - * @return Reference to member unbounded_sequence_long_double_field - */ -std::vector& ContentFilterTestType::unbounded_sequence_long_double_field() -{ - return m_unbounded_sequence_long_double_field; -} - - -/*! - * @brief This function copies the value in member unbounded_sequence_bool_field - * @param _unbounded_sequence_bool_field New value to be copied in member unbounded_sequence_bool_field - */ -void ContentFilterTestType::unbounded_sequence_bool_field( - const std::vector& _unbounded_sequence_bool_field) -{ - m_unbounded_sequence_bool_field = _unbounded_sequence_bool_field; -} - -/*! - * @brief This function moves the value in member unbounded_sequence_bool_field - * @param _unbounded_sequence_bool_field New value to be moved in member unbounded_sequence_bool_field - */ -void ContentFilterTestType::unbounded_sequence_bool_field( - std::vector&& _unbounded_sequence_bool_field) -{ - m_unbounded_sequence_bool_field = std::move(_unbounded_sequence_bool_field); -} - -/*! - * @brief This function returns a constant reference to member unbounded_sequence_bool_field - * @return Constant reference to member unbounded_sequence_bool_field - */ -const std::vector& ContentFilterTestType::unbounded_sequence_bool_field() const -{ - return m_unbounded_sequence_bool_field; -} - -/*! - * @brief This function returns a reference to member unbounded_sequence_bool_field - * @return Reference to member unbounded_sequence_bool_field - */ -std::vector& ContentFilterTestType::unbounded_sequence_bool_field() -{ - return m_unbounded_sequence_bool_field; -} - - -/*! - * @brief This function copies the value in member unbounded_sequence_string_field - * @param _unbounded_sequence_string_field New value to be copied in member unbounded_sequence_string_field - */ -void ContentFilterTestType::unbounded_sequence_string_field( - const std::vector& _unbounded_sequence_string_field) -{ - m_unbounded_sequence_string_field = _unbounded_sequence_string_field; -} - -/*! - * @brief This function moves the value in member unbounded_sequence_string_field - * @param _unbounded_sequence_string_field New value to be moved in member unbounded_sequence_string_field - */ -void ContentFilterTestType::unbounded_sequence_string_field( - std::vector&& _unbounded_sequence_string_field) -{ - m_unbounded_sequence_string_field = std::move(_unbounded_sequence_string_field); -} - -/*! - * @brief This function returns a constant reference to member unbounded_sequence_string_field - * @return Constant reference to member unbounded_sequence_string_field - */ -const std::vector& ContentFilterTestType::unbounded_sequence_string_field() const -{ - return m_unbounded_sequence_string_field; -} - -/*! - * @brief This function returns a reference to member unbounded_sequence_string_field - * @return Reference to member unbounded_sequence_string_field - */ -std::vector& ContentFilterTestType::unbounded_sequence_string_field() -{ - return m_unbounded_sequence_string_field; -} - - -/*! - * @brief This function copies the value in member unbounded_sequence_enum_field - * @param _unbounded_sequence_enum_field New value to be copied in member unbounded_sequence_enum_field - */ -void ContentFilterTestType::unbounded_sequence_enum_field( - const std::vector& _unbounded_sequence_enum_field) -{ - m_unbounded_sequence_enum_field = _unbounded_sequence_enum_field; -} - -/*! - * @brief This function moves the value in member unbounded_sequence_enum_field - * @param _unbounded_sequence_enum_field New value to be moved in member unbounded_sequence_enum_field - */ -void ContentFilterTestType::unbounded_sequence_enum_field( - std::vector&& _unbounded_sequence_enum_field) -{ - m_unbounded_sequence_enum_field = std::move(_unbounded_sequence_enum_field); -} - -/*! - * @brief This function returns a constant reference to member unbounded_sequence_enum_field - * @return Constant reference to member unbounded_sequence_enum_field - */ -const std::vector& ContentFilterTestType::unbounded_sequence_enum_field() const -{ - return m_unbounded_sequence_enum_field; -} - -/*! - * @brief This function returns a reference to member unbounded_sequence_enum_field - * @return Reference to member unbounded_sequence_enum_field - */ -std::vector& ContentFilterTestType::unbounded_sequence_enum_field() -{ - return m_unbounded_sequence_enum_field; -} - - -/*! - * @brief This function copies the value in member unbounded_sequence_enum2_field - * @param _unbounded_sequence_enum2_field New value to be copied in member unbounded_sequence_enum2_field - */ -void ContentFilterTestType::unbounded_sequence_enum2_field( - const std::vector& _unbounded_sequence_enum2_field) -{ - m_unbounded_sequence_enum2_field = _unbounded_sequence_enum2_field; -} - -/*! - * @brief This function moves the value in member unbounded_sequence_enum2_field - * @param _unbounded_sequence_enum2_field New value to be moved in member unbounded_sequence_enum2_field - */ -void ContentFilterTestType::unbounded_sequence_enum2_field( - std::vector&& _unbounded_sequence_enum2_field) -{ - m_unbounded_sequence_enum2_field = std::move(_unbounded_sequence_enum2_field); -} - -/*! - * @brief This function returns a constant reference to member unbounded_sequence_enum2_field - * @return Constant reference to member unbounded_sequence_enum2_field - */ -const std::vector& ContentFilterTestType::unbounded_sequence_enum2_field() const -{ - return m_unbounded_sequence_enum2_field; -} - -/*! - * @brief This function returns a reference to member unbounded_sequence_enum2_field - * @return Reference to member unbounded_sequence_enum2_field - */ -std::vector& ContentFilterTestType::unbounded_sequence_enum2_field() -{ - return m_unbounded_sequence_enum2_field; -} - - -/*! - * @brief This function copies the value in member unbounded_sequence_struct_field - * @param _unbounded_sequence_struct_field New value to be copied in member unbounded_sequence_struct_field - */ -void ContentFilterTestType::unbounded_sequence_struct_field( - const std::vector& _unbounded_sequence_struct_field) -{ - m_unbounded_sequence_struct_field = _unbounded_sequence_struct_field; -} - -/*! - * @brief This function moves the value in member unbounded_sequence_struct_field - * @param _unbounded_sequence_struct_field New value to be moved in member unbounded_sequence_struct_field - */ -void ContentFilterTestType::unbounded_sequence_struct_field( - std::vector&& _unbounded_sequence_struct_field) -{ - m_unbounded_sequence_struct_field = std::move(_unbounded_sequence_struct_field); -} - -/*! - * @brief This function returns a constant reference to member unbounded_sequence_struct_field - * @return Constant reference to member unbounded_sequence_struct_field - */ -const std::vector& ContentFilterTestType::unbounded_sequence_struct_field() const -{ - return m_unbounded_sequence_struct_field; -} - -/*! - * @brief This function returns a reference to member unbounded_sequence_struct_field - * @return Reference to member unbounded_sequence_struct_field - */ -std::vector& ContentFilterTestType::unbounded_sequence_struct_field() -{ - return m_unbounded_sequence_struct_field; -} - - -// Include auxiliary functions like for serializing/deserializing. -#include "ContentFilterTestTypeCdrAux.ipp" - -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestType.h b/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestType.hpp similarity index 58% rename from test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestType.h rename to test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestType.hpp index 898fe5080b4..828fce7b0ff 100644 --- a/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestType.h +++ b/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestType.hpp @@ -13,32 +13,22 @@ // limitations under the License. /*! - * @file ContentFilterTestType.h + * @file ContentFilterTestType.hpp * This header file contains the declaration of the described types in the IDL file. * * This file was generated by the tool fastddsgen. */ -#include -#include "ContentFilterTestTypev1.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#ifndef _FAST_DDS_GENERATED_CONTENTFILTERTESTTYPE_H_ -#define _FAST_DDS_GENERATED_CONTENTFILTERTESTTYPE_H_ +#ifndef _FAST_DDS_GENERATED_CONTENTFILTERTESTTYPE_HPP_ +#define _FAST_DDS_GENERATED_CONTENTFILTERTESTTYPE_HPP_ #include -#include #include -#include #include +#include #include #include -#include -#include - - #if defined(_WIN32) #if defined(EPROSIMA_USER_DLL_EXPORT) @@ -64,20 +54,11 @@ #define CONTENTFILTERTESTTYPE_DllAPI #endif // _WIN32 -namespace eprosima { -namespace fastcdr { -class Cdr; -class CdrSizeCalculator; -} // namespace fastcdr -} // namespace eprosima - - - /*! * @brief This class represents the enumeration Color defined by the user in the IDL file. * @ingroup ContentFilterTestType */ -enum Color : uint32_t +enum class Color : uint32_t { RED, GREEN, @@ -89,7 +70,7 @@ enum Color : uint32_t * @brief This class represents the enumeration Material defined by the user in the IDL file. * @ingroup ContentFilterTestType */ -enum Material : uint32_t +enum class Material : uint32_t { WOOD, PLASTIC, @@ -97,8 +78,6 @@ enum Material : uint32_t CONCRETE, STONE }; - - /*! * @brief This class represents the structure StructType defined by the user in the IDL file. * @ingroup ContentFilterTestType @@ -110,73 +89,208 @@ class StructType /*! * @brief Default constructor. */ - eProsima_user_DllExport StructType(); + eProsima_user_DllExport StructType() + { + } /*! * @brief Default destructor. */ - eProsima_user_DllExport ~StructType(); + eProsima_user_DllExport ~StructType() + { + } /*! * @brief Copy constructor. * @param x Reference to the object StructType that will be copied. */ eProsima_user_DllExport StructType( - const StructType& x); + const StructType& x) + { + m_char_field = x.m_char_field; + + m_uint8_field = x.m_uint8_field; + + m_int16_field = x.m_int16_field; + + m_uint16_field = x.m_uint16_field; + + m_int32_field = x.m_int32_field; + + m_uint32_field = x.m_uint32_field; + + m_int64_field = x.m_int64_field; + + m_uint64_field = x.m_uint64_field; + + m_float_field = x.m_float_field; + + m_double_field = x.m_double_field; + + m_long_double_field = x.m_long_double_field; + + m_bool_field = x.m_bool_field; + + m_string_field = x.m_string_field; + + m_enum_field = x.m_enum_field; + + m_enum2_field = x.m_enum2_field; + + } /*! * @brief Move constructor. * @param x Reference to the object StructType that will be copied. */ eProsima_user_DllExport StructType( - StructType&& x) noexcept; + StructType&& x) noexcept + { + m_char_field = x.m_char_field; + m_uint8_field = x.m_uint8_field; + m_int16_field = x.m_int16_field; + m_uint16_field = x.m_uint16_field; + m_int32_field = x.m_int32_field; + m_uint32_field = x.m_uint32_field; + m_int64_field = x.m_int64_field; + m_uint64_field = x.m_uint64_field; + m_float_field = x.m_float_field; + m_double_field = x.m_double_field; + m_long_double_field = x.m_long_double_field; + m_bool_field = x.m_bool_field; + m_string_field = std::move(x.m_string_field); + m_enum_field = x.m_enum_field; + m_enum2_field = x.m_enum2_field; + } /*! * @brief Copy assignment. * @param x Reference to the object StructType that will be copied. */ eProsima_user_DllExport StructType& operator =( - const StructType& x); + const StructType& x) + { + + m_char_field = x.m_char_field; + + m_uint8_field = x.m_uint8_field; + + m_int16_field = x.m_int16_field; + + m_uint16_field = x.m_uint16_field; + + m_int32_field = x.m_int32_field; + + m_uint32_field = x.m_uint32_field; + + m_int64_field = x.m_int64_field; + + m_uint64_field = x.m_uint64_field; + + m_float_field = x.m_float_field; + + m_double_field = x.m_double_field; + + m_long_double_field = x.m_long_double_field; + + m_bool_field = x.m_bool_field; + + m_string_field = x.m_string_field; + + m_enum_field = x.m_enum_field; + + m_enum2_field = x.m_enum2_field; + + return *this; + } /*! * @brief Move assignment. * @param x Reference to the object StructType that will be copied. */ eProsima_user_DllExport StructType& operator =( - StructType&& x) noexcept; + StructType&& x) noexcept + { + + m_char_field = x.m_char_field; + m_uint8_field = x.m_uint8_field; + m_int16_field = x.m_int16_field; + m_uint16_field = x.m_uint16_field; + m_int32_field = x.m_int32_field; + m_uint32_field = x.m_uint32_field; + m_int64_field = x.m_int64_field; + m_uint64_field = x.m_uint64_field; + m_float_field = x.m_float_field; + m_double_field = x.m_double_field; + m_long_double_field = x.m_long_double_field; + m_bool_field = x.m_bool_field; + m_string_field = std::move(x.m_string_field); + m_enum_field = x.m_enum_field; + m_enum2_field = x.m_enum2_field; + return *this; + } /*! * @brief Comparison operator. * @param x StructType object to compare. */ eProsima_user_DllExport bool operator ==( - const StructType& x) const; + const StructType& x) const + { + return (m_char_field == x.m_char_field && + m_uint8_field == x.m_uint8_field && + m_int16_field == x.m_int16_field && + m_uint16_field == x.m_uint16_field && + m_int32_field == x.m_int32_field && + m_uint32_field == x.m_uint32_field && + m_int64_field == x.m_int64_field && + m_uint64_field == x.m_uint64_field && + m_float_field == x.m_float_field && + m_double_field == x.m_double_field && + m_long_double_field == x.m_long_double_field && + m_bool_field == x.m_bool_field && + m_string_field == x.m_string_field && + m_enum_field == x.m_enum_field && + m_enum2_field == x.m_enum2_field); + } /*! * @brief Comparison operator. * @param x StructType object to compare. */ eProsima_user_DllExport bool operator !=( - const StructType& x) const; + const StructType& x) const + { + return !(*this == x); + } /*! * @brief This function sets a value in member char_field * @param _char_field New value for member char_field */ eProsima_user_DllExport void char_field( - char _char_field); + char _char_field) + { + m_char_field = _char_field; + } /*! * @brief This function returns the value of member char_field * @return Value of member char_field */ - eProsima_user_DllExport char char_field() const; + eProsima_user_DllExport char char_field() const + { + return m_char_field; + } /*! * @brief This function returns a reference to member char_field * @return Reference to member char_field */ - eProsima_user_DllExport char& char_field(); + eProsima_user_DllExport char& char_field() + { + return m_char_field; + } /*! @@ -184,19 +298,28 @@ class StructType * @param _uint8_field New value for member uint8_field */ eProsima_user_DllExport void uint8_field( - uint8_t _uint8_field); + uint8_t _uint8_field) + { + m_uint8_field = _uint8_field; + } /*! * @brief This function returns the value of member uint8_field * @return Value of member uint8_field */ - eProsima_user_DllExport uint8_t uint8_field() const; + eProsima_user_DllExport uint8_t uint8_field() const + { + return m_uint8_field; + } /*! * @brief This function returns a reference to member uint8_field * @return Reference to member uint8_field */ - eProsima_user_DllExport uint8_t& uint8_field(); + eProsima_user_DllExport uint8_t& uint8_field() + { + return m_uint8_field; + } /*! @@ -204,19 +327,28 @@ class StructType * @param _int16_field New value for member int16_field */ eProsima_user_DllExport void int16_field( - int16_t _int16_field); + int16_t _int16_field) + { + m_int16_field = _int16_field; + } /*! * @brief This function returns the value of member int16_field * @return Value of member int16_field */ - eProsima_user_DllExport int16_t int16_field() const; + eProsima_user_DllExport int16_t int16_field() const + { + return m_int16_field; + } /*! * @brief This function returns a reference to member int16_field * @return Reference to member int16_field */ - eProsima_user_DllExport int16_t& int16_field(); + eProsima_user_DllExport int16_t& int16_field() + { + return m_int16_field; + } /*! @@ -224,19 +356,28 @@ class StructType * @param _uint16_field New value for member uint16_field */ eProsima_user_DllExport void uint16_field( - uint16_t _uint16_field); + uint16_t _uint16_field) + { + m_uint16_field = _uint16_field; + } /*! * @brief This function returns the value of member uint16_field * @return Value of member uint16_field */ - eProsima_user_DllExport uint16_t uint16_field() const; + eProsima_user_DllExport uint16_t uint16_field() const + { + return m_uint16_field; + } /*! * @brief This function returns a reference to member uint16_field * @return Reference to member uint16_field */ - eProsima_user_DllExport uint16_t& uint16_field(); + eProsima_user_DllExport uint16_t& uint16_field() + { + return m_uint16_field; + } /*! @@ -244,19 +385,28 @@ class StructType * @param _int32_field New value for member int32_field */ eProsima_user_DllExport void int32_field( - int32_t _int32_field); + int32_t _int32_field) + { + m_int32_field = _int32_field; + } /*! * @brief This function returns the value of member int32_field * @return Value of member int32_field */ - eProsima_user_DllExport int32_t int32_field() const; + eProsima_user_DllExport int32_t int32_field() const + { + return m_int32_field; + } /*! * @brief This function returns a reference to member int32_field * @return Reference to member int32_field */ - eProsima_user_DllExport int32_t& int32_field(); + eProsima_user_DllExport int32_t& int32_field() + { + return m_int32_field; + } /*! @@ -264,19 +414,28 @@ class StructType * @param _uint32_field New value for member uint32_field */ eProsima_user_DllExport void uint32_field( - uint32_t _uint32_field); + uint32_t _uint32_field) + { + m_uint32_field = _uint32_field; + } /*! * @brief This function returns the value of member uint32_field * @return Value of member uint32_field */ - eProsima_user_DllExport uint32_t uint32_field() const; + eProsima_user_DllExport uint32_t uint32_field() const + { + return m_uint32_field; + } /*! * @brief This function returns a reference to member uint32_field * @return Reference to member uint32_field */ - eProsima_user_DllExport uint32_t& uint32_field(); + eProsima_user_DllExport uint32_t& uint32_field() + { + return m_uint32_field; + } /*! @@ -284,19 +443,28 @@ class StructType * @param _int64_field New value for member int64_field */ eProsima_user_DllExport void int64_field( - int64_t _int64_field); + int64_t _int64_field) + { + m_int64_field = _int64_field; + } /*! * @brief This function returns the value of member int64_field * @return Value of member int64_field */ - eProsima_user_DllExport int64_t int64_field() const; + eProsima_user_DllExport int64_t int64_field() const + { + return m_int64_field; + } /*! * @brief This function returns a reference to member int64_field * @return Reference to member int64_field */ - eProsima_user_DllExport int64_t& int64_field(); + eProsima_user_DllExport int64_t& int64_field() + { + return m_int64_field; + } /*! @@ -304,19 +472,28 @@ class StructType * @param _uint64_field New value for member uint64_field */ eProsima_user_DllExport void uint64_field( - uint64_t _uint64_field); + uint64_t _uint64_field) + { + m_uint64_field = _uint64_field; + } /*! * @brief This function returns the value of member uint64_field * @return Value of member uint64_field */ - eProsima_user_DllExport uint64_t uint64_field() const; + eProsima_user_DllExport uint64_t uint64_field() const + { + return m_uint64_field; + } /*! * @brief This function returns a reference to member uint64_field * @return Reference to member uint64_field */ - eProsima_user_DllExport uint64_t& uint64_field(); + eProsima_user_DllExport uint64_t& uint64_field() + { + return m_uint64_field; + } /*! @@ -324,19 +501,28 @@ class StructType * @param _float_field New value for member float_field */ eProsima_user_DllExport void float_field( - float _float_field); + float _float_field) + { + m_float_field = _float_field; + } /*! * @brief This function returns the value of member float_field * @return Value of member float_field */ - eProsima_user_DllExport float float_field() const; + eProsima_user_DllExport float float_field() const + { + return m_float_field; + } /*! * @brief This function returns a reference to member float_field * @return Reference to member float_field */ - eProsima_user_DllExport float& float_field(); + eProsima_user_DllExport float& float_field() + { + return m_float_field; + } /*! @@ -344,19 +530,28 @@ class StructType * @param _double_field New value for member double_field */ eProsima_user_DllExport void double_field( - double _double_field); + double _double_field) + { + m_double_field = _double_field; + } /*! * @brief This function returns the value of member double_field * @return Value of member double_field */ - eProsima_user_DllExport double double_field() const; + eProsima_user_DllExport double double_field() const + { + return m_double_field; + } /*! * @brief This function returns a reference to member double_field * @return Reference to member double_field */ - eProsima_user_DllExport double& double_field(); + eProsima_user_DllExport double& double_field() + { + return m_double_field; + } /*! @@ -364,19 +559,28 @@ class StructType * @param _long_double_field New value for member long_double_field */ eProsima_user_DllExport void long_double_field( - long double _long_double_field); + long double _long_double_field) + { + m_long_double_field = _long_double_field; + } /*! * @brief This function returns the value of member long_double_field * @return Value of member long_double_field */ - eProsima_user_DllExport long double long_double_field() const; + eProsima_user_DllExport long double long_double_field() const + { + return m_long_double_field; + } /*! * @brief This function returns a reference to member long_double_field * @return Reference to member long_double_field */ - eProsima_user_DllExport long double& long_double_field(); + eProsima_user_DllExport long double& long_double_field() + { + return m_long_double_field; + } /*! @@ -384,19 +588,28 @@ class StructType * @param _bool_field New value for member bool_field */ eProsima_user_DllExport void bool_field( - bool _bool_field); + bool _bool_field) + { + m_bool_field = _bool_field; + } /*! * @brief This function returns the value of member bool_field * @return Value of member bool_field */ - eProsima_user_DllExport bool bool_field() const; + eProsima_user_DllExport bool bool_field() const + { + return m_bool_field; + } /*! * @brief This function returns a reference to member bool_field * @return Reference to member bool_field */ - eProsima_user_DllExport bool& bool_field(); + eProsima_user_DllExport bool& bool_field() + { + return m_bool_field; + } /*! @@ -404,26 +617,38 @@ class StructType * @param _string_field New value to be copied in member string_field */ eProsima_user_DllExport void string_field( - const std::string& _string_field); + const std::string& _string_field) + { + m_string_field = _string_field; + } /*! * @brief This function moves the value in member string_field * @param _string_field New value to be moved in member string_field */ eProsima_user_DllExport void string_field( - std::string&& _string_field); + std::string&& _string_field) + { + m_string_field = std::move(_string_field); + } /*! * @brief This function returns a constant reference to member string_field * @return Constant reference to member string_field */ - eProsima_user_DllExport const std::string& string_field() const; + eProsima_user_DllExport const std::string& string_field() const + { + return m_string_field; + } /*! * @brief This function returns a reference to member string_field * @return Reference to member string_field */ - eProsima_user_DllExport std::string& string_field(); + eProsima_user_DllExport std::string& string_field() + { + return m_string_field; + } /*! @@ -431,19 +656,28 @@ class StructType * @param _enum_field New value for member enum_field */ eProsima_user_DllExport void enum_field( - Color _enum_field); + Color _enum_field) + { + m_enum_field = _enum_field; + } /*! * @brief This function returns the value of member enum_field * @return Value of member enum_field */ - eProsima_user_DllExport Color enum_field() const; + eProsima_user_DllExport Color enum_field() const + { + return m_enum_field; + } /*! * @brief This function returns a reference to member enum_field * @return Reference to member enum_field */ - eProsima_user_DllExport Color& enum_field(); + eProsima_user_DllExport Color& enum_field() + { + return m_enum_field; + } /*! @@ -451,19 +685,30 @@ class StructType * @param _enum2_field New value for member enum2_field */ eProsima_user_DllExport void enum2_field( - Material _enum2_field); + Material _enum2_field) + { + m_enum2_field = _enum2_field; + } /*! * @brief This function returns the value of member enum2_field * @return Value of member enum2_field */ - eProsima_user_DllExport Material enum2_field() const; + eProsima_user_DllExport Material enum2_field() const + { + return m_enum2_field; + } /*! * @brief This function returns a reference to member enum2_field * @return Reference to member enum2_field */ - eProsima_user_DllExport Material& enum2_field(); + eProsima_user_DllExport Material& enum2_field() + { + return m_enum2_field; + } + + private: @@ -480,16 +725,12 @@ class StructType long double m_long_double_field{0.0}; bool m_bool_field{false}; std::string m_string_field; - Color m_enum_field{::RED}; - Material m_enum2_field{::WOOD}; + Color m_enum_field{Color::RED}; + Material m_enum2_field{Material::WOOD}; }; const uint32_t max_array_size = 3; const uint32_t max_seq_size = 5; - - - - /*! * @brief This class represents the structure ContentFilterTestType defined by the user in the IDL file. * @ingroup ContentFilterTestType @@ -501,73 +742,551 @@ class ContentFilterTestType /*! * @brief Default constructor. */ - eProsima_user_DllExport ContentFilterTestType(); + eProsima_user_DllExport ContentFilterTestType() + { + } /*! * @brief Default destructor. */ - eProsima_user_DllExport ~ContentFilterTestType(); + eProsima_user_DllExport ~ContentFilterTestType() + { + } /*! * @brief Copy constructor. * @param x Reference to the object ContentFilterTestType that will be copied. */ eProsima_user_DllExport ContentFilterTestType( - const ContentFilterTestType& x); + const ContentFilterTestType& x) + { + m_char_field = x.m_char_field; + + m_uint8_field = x.m_uint8_field; + + m_int16_field = x.m_int16_field; + + m_uint16_field = x.m_uint16_field; + + m_int32_field = x.m_int32_field; + + m_uint32_field = x.m_uint32_field; + + m_int64_field = x.m_int64_field; + + m_uint64_field = x.m_uint64_field; + + m_float_field = x.m_float_field; + + m_double_field = x.m_double_field; + + m_long_double_field = x.m_long_double_field; + + m_bool_field = x.m_bool_field; + + m_string_field = x.m_string_field; + + m_enum_field = x.m_enum_field; + + m_enum2_field = x.m_enum2_field; + + m_struct_field = x.m_struct_field; + + m_array_char_field = x.m_array_char_field; + + m_array_uint8_field = x.m_array_uint8_field; + + m_array_int16_field = x.m_array_int16_field; + + m_array_uint16_field = x.m_array_uint16_field; + + m_array_int32_field = x.m_array_int32_field; + + m_array_uint32_field = x.m_array_uint32_field; + + m_array_int64_field = x.m_array_int64_field; + + m_array_uint64_field = x.m_array_uint64_field; + + m_array_float_field = x.m_array_float_field; + + m_array_double_field = x.m_array_double_field; + + m_array_long_double_field = x.m_array_long_double_field; + + m_array_bool_field = x.m_array_bool_field; + + m_array_string_field = x.m_array_string_field; + + m_array_enum_field = x.m_array_enum_field; + + m_array_enum2_field = x.m_array_enum2_field; + + m_array_struct_field = x.m_array_struct_field; + + m_bounded_sequence_char_field = x.m_bounded_sequence_char_field; + + m_bounded_sequence_uint8_field = x.m_bounded_sequence_uint8_field; + + m_bounded_sequence_int16_field = x.m_bounded_sequence_int16_field; + + m_bounded_sequence_uint16_field = x.m_bounded_sequence_uint16_field; + + m_bounded_sequence_int32_field = x.m_bounded_sequence_int32_field; + + m_bounded_sequence_uint32_field = x.m_bounded_sequence_uint32_field; + + m_bounded_sequence_int64_field = x.m_bounded_sequence_int64_field; + + m_bounded_sequence_uint64_field = x.m_bounded_sequence_uint64_field; + + m_bounded_sequence_float_field = x.m_bounded_sequence_float_field; + + m_bounded_sequence_double_field = x.m_bounded_sequence_double_field; + + m_bounded_sequence_long_double_field = x.m_bounded_sequence_long_double_field; + + m_bounded_sequence_bool_field = x.m_bounded_sequence_bool_field; + + m_bounded_sequence_string_field = x.m_bounded_sequence_string_field; + + m_bounded_sequence_enum_field = x.m_bounded_sequence_enum_field; + + m_bounded_sequence_enum2_field = x.m_bounded_sequence_enum2_field; + + m_bounded_sequence_struct_field = x.m_bounded_sequence_struct_field; + + m_unbounded_sequence_char_field = x.m_unbounded_sequence_char_field; + + m_unbounded_sequence_uint8_field = x.m_unbounded_sequence_uint8_field; + + m_unbounded_sequence_int16_field = x.m_unbounded_sequence_int16_field; + + m_unbounded_sequence_uint16_field = x.m_unbounded_sequence_uint16_field; + + m_unbounded_sequence_int32_field = x.m_unbounded_sequence_int32_field; + + m_unbounded_sequence_uint32_field = x.m_unbounded_sequence_uint32_field; + + m_unbounded_sequence_int64_field = x.m_unbounded_sequence_int64_field; + + m_unbounded_sequence_uint64_field = x.m_unbounded_sequence_uint64_field; + + m_unbounded_sequence_float_field = x.m_unbounded_sequence_float_field; + + m_unbounded_sequence_double_field = x.m_unbounded_sequence_double_field; + + m_unbounded_sequence_long_double_field = x.m_unbounded_sequence_long_double_field; + + m_unbounded_sequence_bool_field = x.m_unbounded_sequence_bool_field; + + m_unbounded_sequence_string_field = x.m_unbounded_sequence_string_field; + + m_unbounded_sequence_enum_field = x.m_unbounded_sequence_enum_field; + + m_unbounded_sequence_enum2_field = x.m_unbounded_sequence_enum2_field; + + m_unbounded_sequence_struct_field = x.m_unbounded_sequence_struct_field; + + } /*! * @brief Move constructor. * @param x Reference to the object ContentFilterTestType that will be copied. */ eProsima_user_DllExport ContentFilterTestType( - ContentFilterTestType&& x) noexcept; + ContentFilterTestType&& x) noexcept + { + m_char_field = x.m_char_field; + m_uint8_field = x.m_uint8_field; + m_int16_field = x.m_int16_field; + m_uint16_field = x.m_uint16_field; + m_int32_field = x.m_int32_field; + m_uint32_field = x.m_uint32_field; + m_int64_field = x.m_int64_field; + m_uint64_field = x.m_uint64_field; + m_float_field = x.m_float_field; + m_double_field = x.m_double_field; + m_long_double_field = x.m_long_double_field; + m_bool_field = x.m_bool_field; + m_string_field = std::move(x.m_string_field); + m_enum_field = x.m_enum_field; + m_enum2_field = x.m_enum2_field; + m_struct_field = std::move(x.m_struct_field); + m_array_char_field = std::move(x.m_array_char_field); + m_array_uint8_field = std::move(x.m_array_uint8_field); + m_array_int16_field = std::move(x.m_array_int16_field); + m_array_uint16_field = std::move(x.m_array_uint16_field); + m_array_int32_field = std::move(x.m_array_int32_field); + m_array_uint32_field = std::move(x.m_array_uint32_field); + m_array_int64_field = std::move(x.m_array_int64_field); + m_array_uint64_field = std::move(x.m_array_uint64_field); + m_array_float_field = std::move(x.m_array_float_field); + m_array_double_field = std::move(x.m_array_double_field); + m_array_long_double_field = std::move(x.m_array_long_double_field); + m_array_bool_field = std::move(x.m_array_bool_field); + m_array_string_field = std::move(x.m_array_string_field); + m_array_enum_field = std::move(x.m_array_enum_field); + m_array_enum2_field = std::move(x.m_array_enum2_field); + m_array_struct_field = std::move(x.m_array_struct_field); + m_bounded_sequence_char_field = std::move(x.m_bounded_sequence_char_field); + m_bounded_sequence_uint8_field = std::move(x.m_bounded_sequence_uint8_field); + m_bounded_sequence_int16_field = std::move(x.m_bounded_sequence_int16_field); + m_bounded_sequence_uint16_field = std::move(x.m_bounded_sequence_uint16_field); + m_bounded_sequence_int32_field = std::move(x.m_bounded_sequence_int32_field); + m_bounded_sequence_uint32_field = std::move(x.m_bounded_sequence_uint32_field); + m_bounded_sequence_int64_field = std::move(x.m_bounded_sequence_int64_field); + m_bounded_sequence_uint64_field = std::move(x.m_bounded_sequence_uint64_field); + m_bounded_sequence_float_field = std::move(x.m_bounded_sequence_float_field); + m_bounded_sequence_double_field = std::move(x.m_bounded_sequence_double_field); + m_bounded_sequence_long_double_field = std::move(x.m_bounded_sequence_long_double_field); + m_bounded_sequence_bool_field = std::move(x.m_bounded_sequence_bool_field); + m_bounded_sequence_string_field = std::move(x.m_bounded_sequence_string_field); + m_bounded_sequence_enum_field = std::move(x.m_bounded_sequence_enum_field); + m_bounded_sequence_enum2_field = std::move(x.m_bounded_sequence_enum2_field); + m_bounded_sequence_struct_field = std::move(x.m_bounded_sequence_struct_field); + m_unbounded_sequence_char_field = std::move(x.m_unbounded_sequence_char_field); + m_unbounded_sequence_uint8_field = std::move(x.m_unbounded_sequence_uint8_field); + m_unbounded_sequence_int16_field = std::move(x.m_unbounded_sequence_int16_field); + m_unbounded_sequence_uint16_field = std::move(x.m_unbounded_sequence_uint16_field); + m_unbounded_sequence_int32_field = std::move(x.m_unbounded_sequence_int32_field); + m_unbounded_sequence_uint32_field = std::move(x.m_unbounded_sequence_uint32_field); + m_unbounded_sequence_int64_field = std::move(x.m_unbounded_sequence_int64_field); + m_unbounded_sequence_uint64_field = std::move(x.m_unbounded_sequence_uint64_field); + m_unbounded_sequence_float_field = std::move(x.m_unbounded_sequence_float_field); + m_unbounded_sequence_double_field = std::move(x.m_unbounded_sequence_double_field); + m_unbounded_sequence_long_double_field = std::move(x.m_unbounded_sequence_long_double_field); + m_unbounded_sequence_bool_field = std::move(x.m_unbounded_sequence_bool_field); + m_unbounded_sequence_string_field = std::move(x.m_unbounded_sequence_string_field); + m_unbounded_sequence_enum_field = std::move(x.m_unbounded_sequence_enum_field); + m_unbounded_sequence_enum2_field = std::move(x.m_unbounded_sequence_enum2_field); + m_unbounded_sequence_struct_field = std::move(x.m_unbounded_sequence_struct_field); + } /*! * @brief Copy assignment. * @param x Reference to the object ContentFilterTestType that will be copied. */ eProsima_user_DllExport ContentFilterTestType& operator =( - const ContentFilterTestType& x); + const ContentFilterTestType& x) + { + + m_char_field = x.m_char_field; + + m_uint8_field = x.m_uint8_field; + + m_int16_field = x.m_int16_field; + + m_uint16_field = x.m_uint16_field; + + m_int32_field = x.m_int32_field; + + m_uint32_field = x.m_uint32_field; + + m_int64_field = x.m_int64_field; + + m_uint64_field = x.m_uint64_field; + + m_float_field = x.m_float_field; + + m_double_field = x.m_double_field; + + m_long_double_field = x.m_long_double_field; + + m_bool_field = x.m_bool_field; + + m_string_field = x.m_string_field; + + m_enum_field = x.m_enum_field; + + m_enum2_field = x.m_enum2_field; + + m_struct_field = x.m_struct_field; + + m_array_char_field = x.m_array_char_field; + + m_array_uint8_field = x.m_array_uint8_field; + + m_array_int16_field = x.m_array_int16_field; + + m_array_uint16_field = x.m_array_uint16_field; + + m_array_int32_field = x.m_array_int32_field; + + m_array_uint32_field = x.m_array_uint32_field; + + m_array_int64_field = x.m_array_int64_field; + + m_array_uint64_field = x.m_array_uint64_field; + + m_array_float_field = x.m_array_float_field; + + m_array_double_field = x.m_array_double_field; + + m_array_long_double_field = x.m_array_long_double_field; + + m_array_bool_field = x.m_array_bool_field; + + m_array_string_field = x.m_array_string_field; + + m_array_enum_field = x.m_array_enum_field; + + m_array_enum2_field = x.m_array_enum2_field; + + m_array_struct_field = x.m_array_struct_field; + + m_bounded_sequence_char_field = x.m_bounded_sequence_char_field; + + m_bounded_sequence_uint8_field = x.m_bounded_sequence_uint8_field; + + m_bounded_sequence_int16_field = x.m_bounded_sequence_int16_field; + + m_bounded_sequence_uint16_field = x.m_bounded_sequence_uint16_field; + + m_bounded_sequence_int32_field = x.m_bounded_sequence_int32_field; + + m_bounded_sequence_uint32_field = x.m_bounded_sequence_uint32_field; + + m_bounded_sequence_int64_field = x.m_bounded_sequence_int64_field; + + m_bounded_sequence_uint64_field = x.m_bounded_sequence_uint64_field; + + m_bounded_sequence_float_field = x.m_bounded_sequence_float_field; + + m_bounded_sequence_double_field = x.m_bounded_sequence_double_field; + + m_bounded_sequence_long_double_field = x.m_bounded_sequence_long_double_field; + + m_bounded_sequence_bool_field = x.m_bounded_sequence_bool_field; + + m_bounded_sequence_string_field = x.m_bounded_sequence_string_field; + + m_bounded_sequence_enum_field = x.m_bounded_sequence_enum_field; + + m_bounded_sequence_enum2_field = x.m_bounded_sequence_enum2_field; + + m_bounded_sequence_struct_field = x.m_bounded_sequence_struct_field; + + m_unbounded_sequence_char_field = x.m_unbounded_sequence_char_field; + + m_unbounded_sequence_uint8_field = x.m_unbounded_sequence_uint8_field; + + m_unbounded_sequence_int16_field = x.m_unbounded_sequence_int16_field; + + m_unbounded_sequence_uint16_field = x.m_unbounded_sequence_uint16_field; + + m_unbounded_sequence_int32_field = x.m_unbounded_sequence_int32_field; + + m_unbounded_sequence_uint32_field = x.m_unbounded_sequence_uint32_field; + + m_unbounded_sequence_int64_field = x.m_unbounded_sequence_int64_field; + + m_unbounded_sequence_uint64_field = x.m_unbounded_sequence_uint64_field; + + m_unbounded_sequence_float_field = x.m_unbounded_sequence_float_field; + + m_unbounded_sequence_double_field = x.m_unbounded_sequence_double_field; + + m_unbounded_sequence_long_double_field = x.m_unbounded_sequence_long_double_field; + + m_unbounded_sequence_bool_field = x.m_unbounded_sequence_bool_field; + + m_unbounded_sequence_string_field = x.m_unbounded_sequence_string_field; + + m_unbounded_sequence_enum_field = x.m_unbounded_sequence_enum_field; + + m_unbounded_sequence_enum2_field = x.m_unbounded_sequence_enum2_field; + + m_unbounded_sequence_struct_field = x.m_unbounded_sequence_struct_field; + + return *this; + } /*! * @brief Move assignment. * @param x Reference to the object ContentFilterTestType that will be copied. */ eProsima_user_DllExport ContentFilterTestType& operator =( - ContentFilterTestType&& x) noexcept; + ContentFilterTestType&& x) noexcept + { + + m_char_field = x.m_char_field; + m_uint8_field = x.m_uint8_field; + m_int16_field = x.m_int16_field; + m_uint16_field = x.m_uint16_field; + m_int32_field = x.m_int32_field; + m_uint32_field = x.m_uint32_field; + m_int64_field = x.m_int64_field; + m_uint64_field = x.m_uint64_field; + m_float_field = x.m_float_field; + m_double_field = x.m_double_field; + m_long_double_field = x.m_long_double_field; + m_bool_field = x.m_bool_field; + m_string_field = std::move(x.m_string_field); + m_enum_field = x.m_enum_field; + m_enum2_field = x.m_enum2_field; + m_struct_field = std::move(x.m_struct_field); + m_array_char_field = std::move(x.m_array_char_field); + m_array_uint8_field = std::move(x.m_array_uint8_field); + m_array_int16_field = std::move(x.m_array_int16_field); + m_array_uint16_field = std::move(x.m_array_uint16_field); + m_array_int32_field = std::move(x.m_array_int32_field); + m_array_uint32_field = std::move(x.m_array_uint32_field); + m_array_int64_field = std::move(x.m_array_int64_field); + m_array_uint64_field = std::move(x.m_array_uint64_field); + m_array_float_field = std::move(x.m_array_float_field); + m_array_double_field = std::move(x.m_array_double_field); + m_array_long_double_field = std::move(x.m_array_long_double_field); + m_array_bool_field = std::move(x.m_array_bool_field); + m_array_string_field = std::move(x.m_array_string_field); + m_array_enum_field = std::move(x.m_array_enum_field); + m_array_enum2_field = std::move(x.m_array_enum2_field); + m_array_struct_field = std::move(x.m_array_struct_field); + m_bounded_sequence_char_field = std::move(x.m_bounded_sequence_char_field); + m_bounded_sequence_uint8_field = std::move(x.m_bounded_sequence_uint8_field); + m_bounded_sequence_int16_field = std::move(x.m_bounded_sequence_int16_field); + m_bounded_sequence_uint16_field = std::move(x.m_bounded_sequence_uint16_field); + m_bounded_sequence_int32_field = std::move(x.m_bounded_sequence_int32_field); + m_bounded_sequence_uint32_field = std::move(x.m_bounded_sequence_uint32_field); + m_bounded_sequence_int64_field = std::move(x.m_bounded_sequence_int64_field); + m_bounded_sequence_uint64_field = std::move(x.m_bounded_sequence_uint64_field); + m_bounded_sequence_float_field = std::move(x.m_bounded_sequence_float_field); + m_bounded_sequence_double_field = std::move(x.m_bounded_sequence_double_field); + m_bounded_sequence_long_double_field = std::move(x.m_bounded_sequence_long_double_field); + m_bounded_sequence_bool_field = std::move(x.m_bounded_sequence_bool_field); + m_bounded_sequence_string_field = std::move(x.m_bounded_sequence_string_field); + m_bounded_sequence_enum_field = std::move(x.m_bounded_sequence_enum_field); + m_bounded_sequence_enum2_field = std::move(x.m_bounded_sequence_enum2_field); + m_bounded_sequence_struct_field = std::move(x.m_bounded_sequence_struct_field); + m_unbounded_sequence_char_field = std::move(x.m_unbounded_sequence_char_field); + m_unbounded_sequence_uint8_field = std::move(x.m_unbounded_sequence_uint8_field); + m_unbounded_sequence_int16_field = std::move(x.m_unbounded_sequence_int16_field); + m_unbounded_sequence_uint16_field = std::move(x.m_unbounded_sequence_uint16_field); + m_unbounded_sequence_int32_field = std::move(x.m_unbounded_sequence_int32_field); + m_unbounded_sequence_uint32_field = std::move(x.m_unbounded_sequence_uint32_field); + m_unbounded_sequence_int64_field = std::move(x.m_unbounded_sequence_int64_field); + m_unbounded_sequence_uint64_field = std::move(x.m_unbounded_sequence_uint64_field); + m_unbounded_sequence_float_field = std::move(x.m_unbounded_sequence_float_field); + m_unbounded_sequence_double_field = std::move(x.m_unbounded_sequence_double_field); + m_unbounded_sequence_long_double_field = std::move(x.m_unbounded_sequence_long_double_field); + m_unbounded_sequence_bool_field = std::move(x.m_unbounded_sequence_bool_field); + m_unbounded_sequence_string_field = std::move(x.m_unbounded_sequence_string_field); + m_unbounded_sequence_enum_field = std::move(x.m_unbounded_sequence_enum_field); + m_unbounded_sequence_enum2_field = std::move(x.m_unbounded_sequence_enum2_field); + m_unbounded_sequence_struct_field = std::move(x.m_unbounded_sequence_struct_field); + return *this; + } /*! * @brief Comparison operator. * @param x ContentFilterTestType object to compare. */ eProsima_user_DllExport bool operator ==( - const ContentFilterTestType& x) const; + const ContentFilterTestType& x) const + { + return (m_char_field == x.m_char_field && + m_uint8_field == x.m_uint8_field && + m_int16_field == x.m_int16_field && + m_uint16_field == x.m_uint16_field && + m_int32_field == x.m_int32_field && + m_uint32_field == x.m_uint32_field && + m_int64_field == x.m_int64_field && + m_uint64_field == x.m_uint64_field && + m_float_field == x.m_float_field && + m_double_field == x.m_double_field && + m_long_double_field == x.m_long_double_field && + m_bool_field == x.m_bool_field && + m_string_field == x.m_string_field && + m_enum_field == x.m_enum_field && + m_enum2_field == x.m_enum2_field && + m_struct_field == x.m_struct_field && + m_array_char_field == x.m_array_char_field && + m_array_uint8_field == x.m_array_uint8_field && + m_array_int16_field == x.m_array_int16_field && + m_array_uint16_field == x.m_array_uint16_field && + m_array_int32_field == x.m_array_int32_field && + m_array_uint32_field == x.m_array_uint32_field && + m_array_int64_field == x.m_array_int64_field && + m_array_uint64_field == x.m_array_uint64_field && + m_array_float_field == x.m_array_float_field && + m_array_double_field == x.m_array_double_field && + m_array_long_double_field == x.m_array_long_double_field && + m_array_bool_field == x.m_array_bool_field && + m_array_string_field == x.m_array_string_field && + m_array_enum_field == x.m_array_enum_field && + m_array_enum2_field == x.m_array_enum2_field && + m_array_struct_field == x.m_array_struct_field && + m_bounded_sequence_char_field == x.m_bounded_sequence_char_field && + m_bounded_sequence_uint8_field == x.m_bounded_sequence_uint8_field && + m_bounded_sequence_int16_field == x.m_bounded_sequence_int16_field && + m_bounded_sequence_uint16_field == x.m_bounded_sequence_uint16_field && + m_bounded_sequence_int32_field == x.m_bounded_sequence_int32_field && + m_bounded_sequence_uint32_field == x.m_bounded_sequence_uint32_field && + m_bounded_sequence_int64_field == x.m_bounded_sequence_int64_field && + m_bounded_sequence_uint64_field == x.m_bounded_sequence_uint64_field && + m_bounded_sequence_float_field == x.m_bounded_sequence_float_field && + m_bounded_sequence_double_field == x.m_bounded_sequence_double_field && + m_bounded_sequence_long_double_field == x.m_bounded_sequence_long_double_field && + m_bounded_sequence_bool_field == x.m_bounded_sequence_bool_field && + m_bounded_sequence_string_field == x.m_bounded_sequence_string_field && + m_bounded_sequence_enum_field == x.m_bounded_sequence_enum_field && + m_bounded_sequence_enum2_field == x.m_bounded_sequence_enum2_field && + m_bounded_sequence_struct_field == x.m_bounded_sequence_struct_field && + m_unbounded_sequence_char_field == x.m_unbounded_sequence_char_field && + m_unbounded_sequence_uint8_field == x.m_unbounded_sequence_uint8_field && + m_unbounded_sequence_int16_field == x.m_unbounded_sequence_int16_field && + m_unbounded_sequence_uint16_field == x.m_unbounded_sequence_uint16_field && + m_unbounded_sequence_int32_field == x.m_unbounded_sequence_int32_field && + m_unbounded_sequence_uint32_field == x.m_unbounded_sequence_uint32_field && + m_unbounded_sequence_int64_field == x.m_unbounded_sequence_int64_field && + m_unbounded_sequence_uint64_field == x.m_unbounded_sequence_uint64_field && + m_unbounded_sequence_float_field == x.m_unbounded_sequence_float_field && + m_unbounded_sequence_double_field == x.m_unbounded_sequence_double_field && + m_unbounded_sequence_long_double_field == x.m_unbounded_sequence_long_double_field && + m_unbounded_sequence_bool_field == x.m_unbounded_sequence_bool_field && + m_unbounded_sequence_string_field == x.m_unbounded_sequence_string_field && + m_unbounded_sequence_enum_field == x.m_unbounded_sequence_enum_field && + m_unbounded_sequence_enum2_field == x.m_unbounded_sequence_enum2_field && + m_unbounded_sequence_struct_field == x.m_unbounded_sequence_struct_field); + } /*! * @brief Comparison operator. * @param x ContentFilterTestType object to compare. */ eProsima_user_DllExport bool operator !=( - const ContentFilterTestType& x) const; + const ContentFilterTestType& x) const + { + return !(*this == x); + } /*! * @brief This function sets a value in member char_field * @param _char_field New value for member char_field */ eProsima_user_DllExport void char_field( - char _char_field); + char _char_field) + { + m_char_field = _char_field; + } /*! * @brief This function returns the value of member char_field * @return Value of member char_field */ - eProsima_user_DllExport char char_field() const; + eProsima_user_DllExport char char_field() const + { + return m_char_field; + } /*! * @brief This function returns a reference to member char_field * @return Reference to member char_field */ - eProsima_user_DllExport char& char_field(); + eProsima_user_DllExport char& char_field() + { + return m_char_field; + } /*! @@ -575,19 +1294,28 @@ class ContentFilterTestType * @param _uint8_field New value for member uint8_field */ eProsima_user_DllExport void uint8_field( - uint8_t _uint8_field); + uint8_t _uint8_field) + { + m_uint8_field = _uint8_field; + } /*! * @brief This function returns the value of member uint8_field * @return Value of member uint8_field */ - eProsima_user_DllExport uint8_t uint8_field() const; + eProsima_user_DllExport uint8_t uint8_field() const + { + return m_uint8_field; + } /*! * @brief This function returns a reference to member uint8_field * @return Reference to member uint8_field */ - eProsima_user_DllExport uint8_t& uint8_field(); + eProsima_user_DllExport uint8_t& uint8_field() + { + return m_uint8_field; + } /*! @@ -595,19 +1323,28 @@ class ContentFilterTestType * @param _int16_field New value for member int16_field */ eProsima_user_DllExport void int16_field( - int16_t _int16_field); + int16_t _int16_field) + { + m_int16_field = _int16_field; + } /*! * @brief This function returns the value of member int16_field * @return Value of member int16_field */ - eProsima_user_DllExport int16_t int16_field() const; + eProsima_user_DllExport int16_t int16_field() const + { + return m_int16_field; + } /*! * @brief This function returns a reference to member int16_field * @return Reference to member int16_field */ - eProsima_user_DllExport int16_t& int16_field(); + eProsima_user_DllExport int16_t& int16_field() + { + return m_int16_field; + } /*! @@ -615,19 +1352,28 @@ class ContentFilterTestType * @param _uint16_field New value for member uint16_field */ eProsima_user_DllExport void uint16_field( - uint16_t _uint16_field); + uint16_t _uint16_field) + { + m_uint16_field = _uint16_field; + } /*! * @brief This function returns the value of member uint16_field * @return Value of member uint16_field */ - eProsima_user_DllExport uint16_t uint16_field() const; + eProsima_user_DllExport uint16_t uint16_field() const + { + return m_uint16_field; + } /*! * @brief This function returns a reference to member uint16_field * @return Reference to member uint16_field */ - eProsima_user_DllExport uint16_t& uint16_field(); + eProsima_user_DllExport uint16_t& uint16_field() + { + return m_uint16_field; + } /*! @@ -635,19 +1381,28 @@ class ContentFilterTestType * @param _int32_field New value for member int32_field */ eProsima_user_DllExport void int32_field( - int32_t _int32_field); + int32_t _int32_field) + { + m_int32_field = _int32_field; + } /*! * @brief This function returns the value of member int32_field * @return Value of member int32_field */ - eProsima_user_DllExport int32_t int32_field() const; + eProsima_user_DllExport int32_t int32_field() const + { + return m_int32_field; + } /*! * @brief This function returns a reference to member int32_field * @return Reference to member int32_field */ - eProsima_user_DllExport int32_t& int32_field(); + eProsima_user_DllExport int32_t& int32_field() + { + return m_int32_field; + } /*! @@ -655,19 +1410,28 @@ class ContentFilterTestType * @param _uint32_field New value for member uint32_field */ eProsima_user_DllExport void uint32_field( - uint32_t _uint32_field); + uint32_t _uint32_field) + { + m_uint32_field = _uint32_field; + } /*! * @brief This function returns the value of member uint32_field * @return Value of member uint32_field */ - eProsima_user_DllExport uint32_t uint32_field() const; + eProsima_user_DllExport uint32_t uint32_field() const + { + return m_uint32_field; + } /*! * @brief This function returns a reference to member uint32_field * @return Reference to member uint32_field */ - eProsima_user_DllExport uint32_t& uint32_field(); + eProsima_user_DllExport uint32_t& uint32_field() + { + return m_uint32_field; + } /*! @@ -675,19 +1439,28 @@ class ContentFilterTestType * @param _int64_field New value for member int64_field */ eProsima_user_DllExport void int64_field( - int64_t _int64_field); + int64_t _int64_field) + { + m_int64_field = _int64_field; + } /*! * @brief This function returns the value of member int64_field * @return Value of member int64_field */ - eProsima_user_DllExport int64_t int64_field() const; + eProsima_user_DllExport int64_t int64_field() const + { + return m_int64_field; + } /*! * @brief This function returns a reference to member int64_field * @return Reference to member int64_field */ - eProsima_user_DllExport int64_t& int64_field(); + eProsima_user_DllExport int64_t& int64_field() + { + return m_int64_field; + } /*! @@ -695,19 +1468,28 @@ class ContentFilterTestType * @param _uint64_field New value for member uint64_field */ eProsima_user_DllExport void uint64_field( - uint64_t _uint64_field); + uint64_t _uint64_field) + { + m_uint64_field = _uint64_field; + } /*! * @brief This function returns the value of member uint64_field * @return Value of member uint64_field */ - eProsima_user_DllExport uint64_t uint64_field() const; + eProsima_user_DllExport uint64_t uint64_field() const + { + return m_uint64_field; + } /*! * @brief This function returns a reference to member uint64_field * @return Reference to member uint64_field */ - eProsima_user_DllExport uint64_t& uint64_field(); + eProsima_user_DllExport uint64_t& uint64_field() + { + return m_uint64_field; + } /*! @@ -715,19 +1497,28 @@ class ContentFilterTestType * @param _float_field New value for member float_field */ eProsima_user_DllExport void float_field( - float _float_field); + float _float_field) + { + m_float_field = _float_field; + } /*! * @brief This function returns the value of member float_field * @return Value of member float_field */ - eProsima_user_DllExport float float_field() const; + eProsima_user_DllExport float float_field() const + { + return m_float_field; + } /*! * @brief This function returns a reference to member float_field * @return Reference to member float_field */ - eProsima_user_DllExport float& float_field(); + eProsima_user_DllExport float& float_field() + { + return m_float_field; + } /*! @@ -735,19 +1526,28 @@ class ContentFilterTestType * @param _double_field New value for member double_field */ eProsima_user_DllExport void double_field( - double _double_field); + double _double_field) + { + m_double_field = _double_field; + } /*! * @brief This function returns the value of member double_field * @return Value of member double_field */ - eProsima_user_DllExport double double_field() const; + eProsima_user_DllExport double double_field() const + { + return m_double_field; + } /*! * @brief This function returns a reference to member double_field * @return Reference to member double_field */ - eProsima_user_DllExport double& double_field(); + eProsima_user_DllExport double& double_field() + { + return m_double_field; + } /*! @@ -755,19 +1555,28 @@ class ContentFilterTestType * @param _long_double_field New value for member long_double_field */ eProsima_user_DllExport void long_double_field( - long double _long_double_field); + long double _long_double_field) + { + m_long_double_field = _long_double_field; + } /*! * @brief This function returns the value of member long_double_field * @return Value of member long_double_field */ - eProsima_user_DllExport long double long_double_field() const; + eProsima_user_DllExport long double long_double_field() const + { + return m_long_double_field; + } /*! * @brief This function returns a reference to member long_double_field * @return Reference to member long_double_field */ - eProsima_user_DllExport long double& long_double_field(); + eProsima_user_DllExport long double& long_double_field() + { + return m_long_double_field; + } /*! @@ -775,19 +1584,28 @@ class ContentFilterTestType * @param _bool_field New value for member bool_field */ eProsima_user_DllExport void bool_field( - bool _bool_field); + bool _bool_field) + { + m_bool_field = _bool_field; + } /*! * @brief This function returns the value of member bool_field * @return Value of member bool_field */ - eProsima_user_DllExport bool bool_field() const; + eProsima_user_DllExport bool bool_field() const + { + return m_bool_field; + } /*! * @brief This function returns a reference to member bool_field * @return Reference to member bool_field */ - eProsima_user_DllExport bool& bool_field(); + eProsima_user_DllExport bool& bool_field() + { + return m_bool_field; + } /*! @@ -795,26 +1613,38 @@ class ContentFilterTestType * @param _string_field New value to be copied in member string_field */ eProsima_user_DllExport void string_field( - const std::string& _string_field); + const std::string& _string_field) + { + m_string_field = _string_field; + } /*! * @brief This function moves the value in member string_field * @param _string_field New value to be moved in member string_field */ eProsima_user_DllExport void string_field( - std::string&& _string_field); + std::string&& _string_field) + { + m_string_field = std::move(_string_field); + } /*! * @brief This function returns a constant reference to member string_field * @return Constant reference to member string_field */ - eProsima_user_DllExport const std::string& string_field() const; + eProsima_user_DllExport const std::string& string_field() const + { + return m_string_field; + } /*! * @brief This function returns a reference to member string_field * @return Reference to member string_field */ - eProsima_user_DllExport std::string& string_field(); + eProsima_user_DllExport std::string& string_field() + { + return m_string_field; + } /*! @@ -822,19 +1652,28 @@ class ContentFilterTestType * @param _enum_field New value for member enum_field */ eProsima_user_DllExport void enum_field( - Color _enum_field); + Color _enum_field) + { + m_enum_field = _enum_field; + } /*! * @brief This function returns the value of member enum_field * @return Value of member enum_field */ - eProsima_user_DllExport Color enum_field() const; + eProsima_user_DllExport Color enum_field() const + { + return m_enum_field; + } /*! * @brief This function returns a reference to member enum_field * @return Reference to member enum_field */ - eProsima_user_DllExport Color& enum_field(); + eProsima_user_DllExport Color& enum_field() + { + return m_enum_field; + } /*! @@ -842,19 +1681,28 @@ class ContentFilterTestType * @param _enum2_field New value for member enum2_field */ eProsima_user_DllExport void enum2_field( - Material _enum2_field); + Material _enum2_field) + { + m_enum2_field = _enum2_field; + } /*! * @brief This function returns the value of member enum2_field * @return Value of member enum2_field */ - eProsima_user_DllExport Material enum2_field() const; + eProsima_user_DllExport Material enum2_field() const + { + return m_enum2_field; + } /*! * @brief This function returns a reference to member enum2_field * @return Reference to member enum2_field */ - eProsima_user_DllExport Material& enum2_field(); + eProsima_user_DllExport Material& enum2_field() + { + return m_enum2_field; + } /*! @@ -862,26 +1710,38 @@ class ContentFilterTestType * @param _struct_field New value to be copied in member struct_field */ eProsima_user_DllExport void struct_field( - const StructType& _struct_field); + const StructType& _struct_field) + { + m_struct_field = _struct_field; + } /*! * @brief This function moves the value in member struct_field * @param _struct_field New value to be moved in member struct_field */ eProsima_user_DllExport void struct_field( - StructType&& _struct_field); + StructType&& _struct_field) + { + m_struct_field = std::move(_struct_field); + } /*! * @brief This function returns a constant reference to member struct_field * @return Constant reference to member struct_field */ - eProsima_user_DllExport const StructType& struct_field() const; + eProsima_user_DllExport const StructType& struct_field() const + { + return m_struct_field; + } /*! * @brief This function returns a reference to member struct_field * @return Reference to member struct_field */ - eProsima_user_DllExport StructType& struct_field(); + eProsima_user_DllExport StructType& struct_field() + { + return m_struct_field; + } /*! @@ -889,26 +1749,38 @@ class ContentFilterTestType * @param _array_char_field New value to be copied in member array_char_field */ eProsima_user_DllExport void array_char_field( - const std::array& _array_char_field); + const std::array& _array_char_field) + { + m_array_char_field = _array_char_field; + } /*! * @brief This function moves the value in member array_char_field * @param _array_char_field New value to be moved in member array_char_field */ eProsima_user_DllExport void array_char_field( - std::array&& _array_char_field); + std::array&& _array_char_field) + { + m_array_char_field = std::move(_array_char_field); + } /*! * @brief This function returns a constant reference to member array_char_field * @return Constant reference to member array_char_field */ - eProsima_user_DllExport const std::array& array_char_field() const; + eProsima_user_DllExport const std::array& array_char_field() const + { + return m_array_char_field; + } /*! * @brief This function returns a reference to member array_char_field * @return Reference to member array_char_field */ - eProsima_user_DllExport std::array& array_char_field(); + eProsima_user_DllExport std::array& array_char_field() + { + return m_array_char_field; + } /*! @@ -916,26 +1788,38 @@ class ContentFilterTestType * @param _array_uint8_field New value to be copied in member array_uint8_field */ eProsima_user_DllExport void array_uint8_field( - const std::array& _array_uint8_field); + const std::array& _array_uint8_field) + { + m_array_uint8_field = _array_uint8_field; + } /*! * @brief This function moves the value in member array_uint8_field * @param _array_uint8_field New value to be moved in member array_uint8_field */ eProsima_user_DllExport void array_uint8_field( - std::array&& _array_uint8_field); + std::array&& _array_uint8_field) + { + m_array_uint8_field = std::move(_array_uint8_field); + } /*! * @brief This function returns a constant reference to member array_uint8_field * @return Constant reference to member array_uint8_field */ - eProsima_user_DllExport const std::array& array_uint8_field() const; + eProsima_user_DllExport const std::array& array_uint8_field() const + { + return m_array_uint8_field; + } /*! * @brief This function returns a reference to member array_uint8_field * @return Reference to member array_uint8_field */ - eProsima_user_DllExport std::array& array_uint8_field(); + eProsima_user_DllExport std::array& array_uint8_field() + { + return m_array_uint8_field; + } /*! @@ -943,26 +1827,38 @@ class ContentFilterTestType * @param _array_int16_field New value to be copied in member array_int16_field */ eProsima_user_DllExport void array_int16_field( - const std::array& _array_int16_field); + const std::array& _array_int16_field) + { + m_array_int16_field = _array_int16_field; + } /*! * @brief This function moves the value in member array_int16_field * @param _array_int16_field New value to be moved in member array_int16_field */ eProsima_user_DllExport void array_int16_field( - std::array&& _array_int16_field); + std::array&& _array_int16_field) + { + m_array_int16_field = std::move(_array_int16_field); + } /*! * @brief This function returns a constant reference to member array_int16_field * @return Constant reference to member array_int16_field */ - eProsima_user_DllExport const std::array& array_int16_field() const; + eProsima_user_DllExport const std::array& array_int16_field() const + { + return m_array_int16_field; + } /*! * @brief This function returns a reference to member array_int16_field * @return Reference to member array_int16_field */ - eProsima_user_DllExport std::array& array_int16_field(); + eProsima_user_DllExport std::array& array_int16_field() + { + return m_array_int16_field; + } /*! @@ -970,26 +1866,38 @@ class ContentFilterTestType * @param _array_uint16_field New value to be copied in member array_uint16_field */ eProsima_user_DllExport void array_uint16_field( - const std::array& _array_uint16_field); + const std::array& _array_uint16_field) + { + m_array_uint16_field = _array_uint16_field; + } /*! * @brief This function moves the value in member array_uint16_field * @param _array_uint16_field New value to be moved in member array_uint16_field */ eProsima_user_DllExport void array_uint16_field( - std::array&& _array_uint16_field); + std::array&& _array_uint16_field) + { + m_array_uint16_field = std::move(_array_uint16_field); + } /*! * @brief This function returns a constant reference to member array_uint16_field * @return Constant reference to member array_uint16_field */ - eProsima_user_DllExport const std::array& array_uint16_field() const; + eProsima_user_DllExport const std::array& array_uint16_field() const + { + return m_array_uint16_field; + } /*! * @brief This function returns a reference to member array_uint16_field * @return Reference to member array_uint16_field */ - eProsima_user_DllExport std::array& array_uint16_field(); + eProsima_user_DllExport std::array& array_uint16_field() + { + return m_array_uint16_field; + } /*! @@ -997,26 +1905,38 @@ class ContentFilterTestType * @param _array_int32_field New value to be copied in member array_int32_field */ eProsima_user_DllExport void array_int32_field( - const std::array& _array_int32_field); + const std::array& _array_int32_field) + { + m_array_int32_field = _array_int32_field; + } /*! * @brief This function moves the value in member array_int32_field * @param _array_int32_field New value to be moved in member array_int32_field */ eProsima_user_DllExport void array_int32_field( - std::array&& _array_int32_field); + std::array&& _array_int32_field) + { + m_array_int32_field = std::move(_array_int32_field); + } /*! * @brief This function returns a constant reference to member array_int32_field * @return Constant reference to member array_int32_field */ - eProsima_user_DllExport const std::array& array_int32_field() const; + eProsima_user_DllExport const std::array& array_int32_field() const + { + return m_array_int32_field; + } /*! * @brief This function returns a reference to member array_int32_field * @return Reference to member array_int32_field */ - eProsima_user_DllExport std::array& array_int32_field(); + eProsima_user_DllExport std::array& array_int32_field() + { + return m_array_int32_field; + } /*! @@ -1024,26 +1944,38 @@ class ContentFilterTestType * @param _array_uint32_field New value to be copied in member array_uint32_field */ eProsima_user_DllExport void array_uint32_field( - const std::array& _array_uint32_field); + const std::array& _array_uint32_field) + { + m_array_uint32_field = _array_uint32_field; + } /*! * @brief This function moves the value in member array_uint32_field * @param _array_uint32_field New value to be moved in member array_uint32_field */ eProsima_user_DllExport void array_uint32_field( - std::array&& _array_uint32_field); + std::array&& _array_uint32_field) + { + m_array_uint32_field = std::move(_array_uint32_field); + } /*! * @brief This function returns a constant reference to member array_uint32_field * @return Constant reference to member array_uint32_field */ - eProsima_user_DllExport const std::array& array_uint32_field() const; + eProsima_user_DllExport const std::array& array_uint32_field() const + { + return m_array_uint32_field; + } /*! * @brief This function returns a reference to member array_uint32_field * @return Reference to member array_uint32_field */ - eProsima_user_DllExport std::array& array_uint32_field(); + eProsima_user_DllExport std::array& array_uint32_field() + { + return m_array_uint32_field; + } /*! @@ -1051,26 +1983,38 @@ class ContentFilterTestType * @param _array_int64_field New value to be copied in member array_int64_field */ eProsima_user_DllExport void array_int64_field( - const std::array& _array_int64_field); + const std::array& _array_int64_field) + { + m_array_int64_field = _array_int64_field; + } /*! * @brief This function moves the value in member array_int64_field * @param _array_int64_field New value to be moved in member array_int64_field */ eProsima_user_DllExport void array_int64_field( - std::array&& _array_int64_field); + std::array&& _array_int64_field) + { + m_array_int64_field = std::move(_array_int64_field); + } /*! * @brief This function returns a constant reference to member array_int64_field * @return Constant reference to member array_int64_field */ - eProsima_user_DllExport const std::array& array_int64_field() const; + eProsima_user_DllExport const std::array& array_int64_field() const + { + return m_array_int64_field; + } /*! * @brief This function returns a reference to member array_int64_field * @return Reference to member array_int64_field */ - eProsima_user_DllExport std::array& array_int64_field(); + eProsima_user_DllExport std::array& array_int64_field() + { + return m_array_int64_field; + } /*! @@ -1078,26 +2022,38 @@ class ContentFilterTestType * @param _array_uint64_field New value to be copied in member array_uint64_field */ eProsima_user_DllExport void array_uint64_field( - const std::array& _array_uint64_field); + const std::array& _array_uint64_field) + { + m_array_uint64_field = _array_uint64_field; + } /*! * @brief This function moves the value in member array_uint64_field * @param _array_uint64_field New value to be moved in member array_uint64_field */ eProsima_user_DllExport void array_uint64_field( - std::array&& _array_uint64_field); + std::array&& _array_uint64_field) + { + m_array_uint64_field = std::move(_array_uint64_field); + } /*! * @brief This function returns a constant reference to member array_uint64_field * @return Constant reference to member array_uint64_field */ - eProsima_user_DllExport const std::array& array_uint64_field() const; + eProsima_user_DllExport const std::array& array_uint64_field() const + { + return m_array_uint64_field; + } /*! * @brief This function returns a reference to member array_uint64_field * @return Reference to member array_uint64_field */ - eProsima_user_DllExport std::array& array_uint64_field(); + eProsima_user_DllExport std::array& array_uint64_field() + { + return m_array_uint64_field; + } /*! @@ -1105,26 +2061,38 @@ class ContentFilterTestType * @param _array_float_field New value to be copied in member array_float_field */ eProsima_user_DllExport void array_float_field( - const std::array& _array_float_field); + const std::array& _array_float_field) + { + m_array_float_field = _array_float_field; + } /*! * @brief This function moves the value in member array_float_field * @param _array_float_field New value to be moved in member array_float_field */ eProsima_user_DllExport void array_float_field( - std::array&& _array_float_field); + std::array&& _array_float_field) + { + m_array_float_field = std::move(_array_float_field); + } /*! * @brief This function returns a constant reference to member array_float_field * @return Constant reference to member array_float_field */ - eProsima_user_DllExport const std::array& array_float_field() const; + eProsima_user_DllExport const std::array& array_float_field() const + { + return m_array_float_field; + } /*! * @brief This function returns a reference to member array_float_field * @return Reference to member array_float_field */ - eProsima_user_DllExport std::array& array_float_field(); + eProsima_user_DllExport std::array& array_float_field() + { + return m_array_float_field; + } /*! @@ -1132,26 +2100,38 @@ class ContentFilterTestType * @param _array_double_field New value to be copied in member array_double_field */ eProsima_user_DllExport void array_double_field( - const std::array& _array_double_field); + const std::array& _array_double_field) + { + m_array_double_field = _array_double_field; + } /*! * @brief This function moves the value in member array_double_field * @param _array_double_field New value to be moved in member array_double_field */ eProsima_user_DllExport void array_double_field( - std::array&& _array_double_field); + std::array&& _array_double_field) + { + m_array_double_field = std::move(_array_double_field); + } /*! * @brief This function returns a constant reference to member array_double_field * @return Constant reference to member array_double_field */ - eProsima_user_DllExport const std::array& array_double_field() const; + eProsima_user_DllExport const std::array& array_double_field() const + { + return m_array_double_field; + } /*! * @brief This function returns a reference to member array_double_field * @return Reference to member array_double_field */ - eProsima_user_DllExport std::array& array_double_field(); + eProsima_user_DllExport std::array& array_double_field() + { + return m_array_double_field; + } /*! @@ -1159,26 +2139,38 @@ class ContentFilterTestType * @param _array_long_double_field New value to be copied in member array_long_double_field */ eProsima_user_DllExport void array_long_double_field( - const std::array& _array_long_double_field); + const std::array& _array_long_double_field) + { + m_array_long_double_field = _array_long_double_field; + } /*! * @brief This function moves the value in member array_long_double_field * @param _array_long_double_field New value to be moved in member array_long_double_field */ eProsima_user_DllExport void array_long_double_field( - std::array&& _array_long_double_field); + std::array&& _array_long_double_field) + { + m_array_long_double_field = std::move(_array_long_double_field); + } /*! * @brief This function returns a constant reference to member array_long_double_field * @return Constant reference to member array_long_double_field */ - eProsima_user_DllExport const std::array& array_long_double_field() const; + eProsima_user_DllExport const std::array& array_long_double_field() const + { + return m_array_long_double_field; + } /*! * @brief This function returns a reference to member array_long_double_field * @return Reference to member array_long_double_field */ - eProsima_user_DllExport std::array& array_long_double_field(); + eProsima_user_DllExport std::array& array_long_double_field() + { + return m_array_long_double_field; + } /*! @@ -1186,26 +2178,38 @@ class ContentFilterTestType * @param _array_bool_field New value to be copied in member array_bool_field */ eProsima_user_DllExport void array_bool_field( - const std::array& _array_bool_field); + const std::array& _array_bool_field) + { + m_array_bool_field = _array_bool_field; + } /*! * @brief This function moves the value in member array_bool_field * @param _array_bool_field New value to be moved in member array_bool_field */ eProsima_user_DllExport void array_bool_field( - std::array&& _array_bool_field); + std::array&& _array_bool_field) + { + m_array_bool_field = std::move(_array_bool_field); + } /*! * @brief This function returns a constant reference to member array_bool_field * @return Constant reference to member array_bool_field */ - eProsima_user_DllExport const std::array& array_bool_field() const; + eProsima_user_DllExport const std::array& array_bool_field() const + { + return m_array_bool_field; + } /*! * @brief This function returns a reference to member array_bool_field * @return Reference to member array_bool_field */ - eProsima_user_DllExport std::array& array_bool_field(); + eProsima_user_DllExport std::array& array_bool_field() + { + return m_array_bool_field; + } /*! @@ -1213,26 +2217,38 @@ class ContentFilterTestType * @param _array_string_field New value to be copied in member array_string_field */ eProsima_user_DllExport void array_string_field( - const std::array& _array_string_field); + const std::array& _array_string_field) + { + m_array_string_field = _array_string_field; + } /*! * @brief This function moves the value in member array_string_field * @param _array_string_field New value to be moved in member array_string_field */ eProsima_user_DllExport void array_string_field( - std::array&& _array_string_field); + std::array&& _array_string_field) + { + m_array_string_field = std::move(_array_string_field); + } /*! * @brief This function returns a constant reference to member array_string_field * @return Constant reference to member array_string_field */ - eProsima_user_DllExport const std::array& array_string_field() const; + eProsima_user_DllExport const std::array& array_string_field() const + { + return m_array_string_field; + } /*! * @brief This function returns a reference to member array_string_field * @return Reference to member array_string_field */ - eProsima_user_DllExport std::array& array_string_field(); + eProsima_user_DllExport std::array& array_string_field() + { + return m_array_string_field; + } /*! @@ -1240,26 +2256,38 @@ class ContentFilterTestType * @param _array_enum_field New value to be copied in member array_enum_field */ eProsima_user_DllExport void array_enum_field( - const std::array& _array_enum_field); + const std::array& _array_enum_field) + { + m_array_enum_field = _array_enum_field; + } /*! * @brief This function moves the value in member array_enum_field * @param _array_enum_field New value to be moved in member array_enum_field */ eProsima_user_DllExport void array_enum_field( - std::array&& _array_enum_field); + std::array&& _array_enum_field) + { + m_array_enum_field = std::move(_array_enum_field); + } /*! * @brief This function returns a constant reference to member array_enum_field * @return Constant reference to member array_enum_field */ - eProsima_user_DllExport const std::array& array_enum_field() const; + eProsima_user_DllExport const std::array& array_enum_field() const + { + return m_array_enum_field; + } /*! * @brief This function returns a reference to member array_enum_field * @return Reference to member array_enum_field */ - eProsima_user_DllExport std::array& array_enum_field(); + eProsima_user_DllExport std::array& array_enum_field() + { + return m_array_enum_field; + } /*! @@ -1267,26 +2295,38 @@ class ContentFilterTestType * @param _array_enum2_field New value to be copied in member array_enum2_field */ eProsima_user_DllExport void array_enum2_field( - const std::array& _array_enum2_field); + const std::array& _array_enum2_field) + { + m_array_enum2_field = _array_enum2_field; + } /*! * @brief This function moves the value in member array_enum2_field * @param _array_enum2_field New value to be moved in member array_enum2_field */ eProsima_user_DllExport void array_enum2_field( - std::array&& _array_enum2_field); + std::array&& _array_enum2_field) + { + m_array_enum2_field = std::move(_array_enum2_field); + } /*! * @brief This function returns a constant reference to member array_enum2_field * @return Constant reference to member array_enum2_field */ - eProsima_user_DllExport const std::array& array_enum2_field() const; + eProsima_user_DllExport const std::array& array_enum2_field() const + { + return m_array_enum2_field; + } /*! * @brief This function returns a reference to member array_enum2_field * @return Reference to member array_enum2_field */ - eProsima_user_DllExport std::array& array_enum2_field(); + eProsima_user_DllExport std::array& array_enum2_field() + { + return m_array_enum2_field; + } /*! @@ -1294,26 +2334,38 @@ class ContentFilterTestType * @param _array_struct_field New value to be copied in member array_struct_field */ eProsima_user_DllExport void array_struct_field( - const std::array& _array_struct_field); + const std::array& _array_struct_field) + { + m_array_struct_field = _array_struct_field; + } /*! * @brief This function moves the value in member array_struct_field * @param _array_struct_field New value to be moved in member array_struct_field */ eProsima_user_DllExport void array_struct_field( - std::array&& _array_struct_field); + std::array&& _array_struct_field) + { + m_array_struct_field = std::move(_array_struct_field); + } /*! * @brief This function returns a constant reference to member array_struct_field * @return Constant reference to member array_struct_field */ - eProsima_user_DllExport const std::array& array_struct_field() const; + eProsima_user_DllExport const std::array& array_struct_field() const + { + return m_array_struct_field; + } /*! * @brief This function returns a reference to member array_struct_field * @return Reference to member array_struct_field */ - eProsima_user_DllExport std::array& array_struct_field(); + eProsima_user_DllExport std::array& array_struct_field() + { + return m_array_struct_field; + } /*! @@ -1321,26 +2373,38 @@ class ContentFilterTestType * @param _bounded_sequence_char_field New value to be copied in member bounded_sequence_char_field */ eProsima_user_DllExport void bounded_sequence_char_field( - const std::vector& _bounded_sequence_char_field); + const std::vector& _bounded_sequence_char_field) + { + m_bounded_sequence_char_field = _bounded_sequence_char_field; + } /*! * @brief This function moves the value in member bounded_sequence_char_field * @param _bounded_sequence_char_field New value to be moved in member bounded_sequence_char_field */ eProsima_user_DllExport void bounded_sequence_char_field( - std::vector&& _bounded_sequence_char_field); + std::vector&& _bounded_sequence_char_field) + { + m_bounded_sequence_char_field = std::move(_bounded_sequence_char_field); + } /*! * @brief This function returns a constant reference to member bounded_sequence_char_field * @return Constant reference to member bounded_sequence_char_field */ - eProsima_user_DllExport const std::vector& bounded_sequence_char_field() const; + eProsima_user_DllExport const std::vector& bounded_sequence_char_field() const + { + return m_bounded_sequence_char_field; + } /*! * @brief This function returns a reference to member bounded_sequence_char_field * @return Reference to member bounded_sequence_char_field */ - eProsima_user_DllExport std::vector& bounded_sequence_char_field(); + eProsima_user_DllExport std::vector& bounded_sequence_char_field() + { + return m_bounded_sequence_char_field; + } /*! @@ -1348,26 +2412,38 @@ class ContentFilterTestType * @param _bounded_sequence_uint8_field New value to be copied in member bounded_sequence_uint8_field */ eProsima_user_DllExport void bounded_sequence_uint8_field( - const std::vector& _bounded_sequence_uint8_field); + const std::vector& _bounded_sequence_uint8_field) + { + m_bounded_sequence_uint8_field = _bounded_sequence_uint8_field; + } /*! * @brief This function moves the value in member bounded_sequence_uint8_field * @param _bounded_sequence_uint8_field New value to be moved in member bounded_sequence_uint8_field */ eProsima_user_DllExport void bounded_sequence_uint8_field( - std::vector&& _bounded_sequence_uint8_field); + std::vector&& _bounded_sequence_uint8_field) + { + m_bounded_sequence_uint8_field = std::move(_bounded_sequence_uint8_field); + } /*! * @brief This function returns a constant reference to member bounded_sequence_uint8_field * @return Constant reference to member bounded_sequence_uint8_field */ - eProsima_user_DllExport const std::vector& bounded_sequence_uint8_field() const; + eProsima_user_DllExport const std::vector& bounded_sequence_uint8_field() const + { + return m_bounded_sequence_uint8_field; + } /*! * @brief This function returns a reference to member bounded_sequence_uint8_field * @return Reference to member bounded_sequence_uint8_field */ - eProsima_user_DllExport std::vector& bounded_sequence_uint8_field(); + eProsima_user_DllExport std::vector& bounded_sequence_uint8_field() + { + return m_bounded_sequence_uint8_field; + } /*! @@ -1375,26 +2451,38 @@ class ContentFilterTestType * @param _bounded_sequence_int16_field New value to be copied in member bounded_sequence_int16_field */ eProsima_user_DllExport void bounded_sequence_int16_field( - const std::vector& _bounded_sequence_int16_field); + const std::vector& _bounded_sequence_int16_field) + { + m_bounded_sequence_int16_field = _bounded_sequence_int16_field; + } /*! * @brief This function moves the value in member bounded_sequence_int16_field * @param _bounded_sequence_int16_field New value to be moved in member bounded_sequence_int16_field */ eProsima_user_DllExport void bounded_sequence_int16_field( - std::vector&& _bounded_sequence_int16_field); + std::vector&& _bounded_sequence_int16_field) + { + m_bounded_sequence_int16_field = std::move(_bounded_sequence_int16_field); + } /*! * @brief This function returns a constant reference to member bounded_sequence_int16_field * @return Constant reference to member bounded_sequence_int16_field */ - eProsima_user_DllExport const std::vector& bounded_sequence_int16_field() const; + eProsima_user_DllExport const std::vector& bounded_sequence_int16_field() const + { + return m_bounded_sequence_int16_field; + } /*! * @brief This function returns a reference to member bounded_sequence_int16_field * @return Reference to member bounded_sequence_int16_field */ - eProsima_user_DllExport std::vector& bounded_sequence_int16_field(); + eProsima_user_DllExport std::vector& bounded_sequence_int16_field() + { + return m_bounded_sequence_int16_field; + } /*! @@ -1402,26 +2490,38 @@ class ContentFilterTestType * @param _bounded_sequence_uint16_field New value to be copied in member bounded_sequence_uint16_field */ eProsima_user_DllExport void bounded_sequence_uint16_field( - const std::vector& _bounded_sequence_uint16_field); + const std::vector& _bounded_sequence_uint16_field) + { + m_bounded_sequence_uint16_field = _bounded_sequence_uint16_field; + } /*! * @brief This function moves the value in member bounded_sequence_uint16_field * @param _bounded_sequence_uint16_field New value to be moved in member bounded_sequence_uint16_field */ eProsima_user_DllExport void bounded_sequence_uint16_field( - std::vector&& _bounded_sequence_uint16_field); + std::vector&& _bounded_sequence_uint16_field) + { + m_bounded_sequence_uint16_field = std::move(_bounded_sequence_uint16_field); + } /*! * @brief This function returns a constant reference to member bounded_sequence_uint16_field * @return Constant reference to member bounded_sequence_uint16_field */ - eProsima_user_DllExport const std::vector& bounded_sequence_uint16_field() const; + eProsima_user_DllExport const std::vector& bounded_sequence_uint16_field() const + { + return m_bounded_sequence_uint16_field; + } /*! * @brief This function returns a reference to member bounded_sequence_uint16_field * @return Reference to member bounded_sequence_uint16_field */ - eProsima_user_DllExport std::vector& bounded_sequence_uint16_field(); + eProsima_user_DllExport std::vector& bounded_sequence_uint16_field() + { + return m_bounded_sequence_uint16_field; + } /*! @@ -1429,26 +2529,38 @@ class ContentFilterTestType * @param _bounded_sequence_int32_field New value to be copied in member bounded_sequence_int32_field */ eProsima_user_DllExport void bounded_sequence_int32_field( - const std::vector& _bounded_sequence_int32_field); + const std::vector& _bounded_sequence_int32_field) + { + m_bounded_sequence_int32_field = _bounded_sequence_int32_field; + } /*! * @brief This function moves the value in member bounded_sequence_int32_field * @param _bounded_sequence_int32_field New value to be moved in member bounded_sequence_int32_field */ eProsima_user_DllExport void bounded_sequence_int32_field( - std::vector&& _bounded_sequence_int32_field); + std::vector&& _bounded_sequence_int32_field) + { + m_bounded_sequence_int32_field = std::move(_bounded_sequence_int32_field); + } /*! * @brief This function returns a constant reference to member bounded_sequence_int32_field * @return Constant reference to member bounded_sequence_int32_field */ - eProsima_user_DllExport const std::vector& bounded_sequence_int32_field() const; + eProsima_user_DllExport const std::vector& bounded_sequence_int32_field() const + { + return m_bounded_sequence_int32_field; + } /*! * @brief This function returns a reference to member bounded_sequence_int32_field * @return Reference to member bounded_sequence_int32_field */ - eProsima_user_DllExport std::vector& bounded_sequence_int32_field(); + eProsima_user_DllExport std::vector& bounded_sequence_int32_field() + { + return m_bounded_sequence_int32_field; + } /*! @@ -1456,26 +2568,38 @@ class ContentFilterTestType * @param _bounded_sequence_uint32_field New value to be copied in member bounded_sequence_uint32_field */ eProsima_user_DllExport void bounded_sequence_uint32_field( - const std::vector& _bounded_sequence_uint32_field); + const std::vector& _bounded_sequence_uint32_field) + { + m_bounded_sequence_uint32_field = _bounded_sequence_uint32_field; + } /*! * @brief This function moves the value in member bounded_sequence_uint32_field * @param _bounded_sequence_uint32_field New value to be moved in member bounded_sequence_uint32_field */ eProsima_user_DllExport void bounded_sequence_uint32_field( - std::vector&& _bounded_sequence_uint32_field); + std::vector&& _bounded_sequence_uint32_field) + { + m_bounded_sequence_uint32_field = std::move(_bounded_sequence_uint32_field); + } /*! * @brief This function returns a constant reference to member bounded_sequence_uint32_field * @return Constant reference to member bounded_sequence_uint32_field */ - eProsima_user_DllExport const std::vector& bounded_sequence_uint32_field() const; + eProsima_user_DllExport const std::vector& bounded_sequence_uint32_field() const + { + return m_bounded_sequence_uint32_field; + } /*! * @brief This function returns a reference to member bounded_sequence_uint32_field * @return Reference to member bounded_sequence_uint32_field */ - eProsima_user_DllExport std::vector& bounded_sequence_uint32_field(); + eProsima_user_DllExport std::vector& bounded_sequence_uint32_field() + { + return m_bounded_sequence_uint32_field; + } /*! @@ -1483,26 +2607,38 @@ class ContentFilterTestType * @param _bounded_sequence_int64_field New value to be copied in member bounded_sequence_int64_field */ eProsima_user_DllExport void bounded_sequence_int64_field( - const std::vector& _bounded_sequence_int64_field); + const std::vector& _bounded_sequence_int64_field) + { + m_bounded_sequence_int64_field = _bounded_sequence_int64_field; + } /*! * @brief This function moves the value in member bounded_sequence_int64_field * @param _bounded_sequence_int64_field New value to be moved in member bounded_sequence_int64_field */ eProsima_user_DllExport void bounded_sequence_int64_field( - std::vector&& _bounded_sequence_int64_field); + std::vector&& _bounded_sequence_int64_field) + { + m_bounded_sequence_int64_field = std::move(_bounded_sequence_int64_field); + } /*! * @brief This function returns a constant reference to member bounded_sequence_int64_field * @return Constant reference to member bounded_sequence_int64_field */ - eProsima_user_DllExport const std::vector& bounded_sequence_int64_field() const; + eProsima_user_DllExport const std::vector& bounded_sequence_int64_field() const + { + return m_bounded_sequence_int64_field; + } /*! * @brief This function returns a reference to member bounded_sequence_int64_field * @return Reference to member bounded_sequence_int64_field */ - eProsima_user_DllExport std::vector& bounded_sequence_int64_field(); + eProsima_user_DllExport std::vector& bounded_sequence_int64_field() + { + return m_bounded_sequence_int64_field; + } /*! @@ -1510,26 +2646,38 @@ class ContentFilterTestType * @param _bounded_sequence_uint64_field New value to be copied in member bounded_sequence_uint64_field */ eProsima_user_DllExport void bounded_sequence_uint64_field( - const std::vector& _bounded_sequence_uint64_field); + const std::vector& _bounded_sequence_uint64_field) + { + m_bounded_sequence_uint64_field = _bounded_sequence_uint64_field; + } /*! * @brief This function moves the value in member bounded_sequence_uint64_field * @param _bounded_sequence_uint64_field New value to be moved in member bounded_sequence_uint64_field */ eProsima_user_DllExport void bounded_sequence_uint64_field( - std::vector&& _bounded_sequence_uint64_field); + std::vector&& _bounded_sequence_uint64_field) + { + m_bounded_sequence_uint64_field = std::move(_bounded_sequence_uint64_field); + } /*! * @brief This function returns a constant reference to member bounded_sequence_uint64_field * @return Constant reference to member bounded_sequence_uint64_field */ - eProsima_user_DllExport const std::vector& bounded_sequence_uint64_field() const; + eProsima_user_DllExport const std::vector& bounded_sequence_uint64_field() const + { + return m_bounded_sequence_uint64_field; + } /*! * @brief This function returns a reference to member bounded_sequence_uint64_field * @return Reference to member bounded_sequence_uint64_field */ - eProsima_user_DllExport std::vector& bounded_sequence_uint64_field(); + eProsima_user_DllExport std::vector& bounded_sequence_uint64_field() + { + return m_bounded_sequence_uint64_field; + } /*! @@ -1537,26 +2685,38 @@ class ContentFilterTestType * @param _bounded_sequence_float_field New value to be copied in member bounded_sequence_float_field */ eProsima_user_DllExport void bounded_sequence_float_field( - const std::vector& _bounded_sequence_float_field); + const std::vector& _bounded_sequence_float_field) + { + m_bounded_sequence_float_field = _bounded_sequence_float_field; + } /*! * @brief This function moves the value in member bounded_sequence_float_field * @param _bounded_sequence_float_field New value to be moved in member bounded_sequence_float_field */ eProsima_user_DllExport void bounded_sequence_float_field( - std::vector&& _bounded_sequence_float_field); + std::vector&& _bounded_sequence_float_field) + { + m_bounded_sequence_float_field = std::move(_bounded_sequence_float_field); + } /*! * @brief This function returns a constant reference to member bounded_sequence_float_field * @return Constant reference to member bounded_sequence_float_field */ - eProsima_user_DllExport const std::vector& bounded_sequence_float_field() const; + eProsima_user_DllExport const std::vector& bounded_sequence_float_field() const + { + return m_bounded_sequence_float_field; + } /*! * @brief This function returns a reference to member bounded_sequence_float_field * @return Reference to member bounded_sequence_float_field */ - eProsima_user_DllExport std::vector& bounded_sequence_float_field(); + eProsima_user_DllExport std::vector& bounded_sequence_float_field() + { + return m_bounded_sequence_float_field; + } /*! @@ -1564,26 +2724,38 @@ class ContentFilterTestType * @param _bounded_sequence_double_field New value to be copied in member bounded_sequence_double_field */ eProsima_user_DllExport void bounded_sequence_double_field( - const std::vector& _bounded_sequence_double_field); + const std::vector& _bounded_sequence_double_field) + { + m_bounded_sequence_double_field = _bounded_sequence_double_field; + } /*! * @brief This function moves the value in member bounded_sequence_double_field * @param _bounded_sequence_double_field New value to be moved in member bounded_sequence_double_field */ eProsima_user_DllExport void bounded_sequence_double_field( - std::vector&& _bounded_sequence_double_field); + std::vector&& _bounded_sequence_double_field) + { + m_bounded_sequence_double_field = std::move(_bounded_sequence_double_field); + } /*! * @brief This function returns a constant reference to member bounded_sequence_double_field * @return Constant reference to member bounded_sequence_double_field */ - eProsima_user_DllExport const std::vector& bounded_sequence_double_field() const; + eProsima_user_DllExport const std::vector& bounded_sequence_double_field() const + { + return m_bounded_sequence_double_field; + } /*! * @brief This function returns a reference to member bounded_sequence_double_field * @return Reference to member bounded_sequence_double_field */ - eProsima_user_DllExport std::vector& bounded_sequence_double_field(); + eProsima_user_DllExport std::vector& bounded_sequence_double_field() + { + return m_bounded_sequence_double_field; + } /*! @@ -1591,26 +2763,38 @@ class ContentFilterTestType * @param _bounded_sequence_long_double_field New value to be copied in member bounded_sequence_long_double_field */ eProsima_user_DllExport void bounded_sequence_long_double_field( - const std::vector& _bounded_sequence_long_double_field); + const std::vector& _bounded_sequence_long_double_field) + { + m_bounded_sequence_long_double_field = _bounded_sequence_long_double_field; + } /*! * @brief This function moves the value in member bounded_sequence_long_double_field * @param _bounded_sequence_long_double_field New value to be moved in member bounded_sequence_long_double_field */ eProsima_user_DllExport void bounded_sequence_long_double_field( - std::vector&& _bounded_sequence_long_double_field); + std::vector&& _bounded_sequence_long_double_field) + { + m_bounded_sequence_long_double_field = std::move(_bounded_sequence_long_double_field); + } /*! * @brief This function returns a constant reference to member bounded_sequence_long_double_field * @return Constant reference to member bounded_sequence_long_double_field */ - eProsima_user_DllExport const std::vector& bounded_sequence_long_double_field() const; + eProsima_user_DllExport const std::vector& bounded_sequence_long_double_field() const + { + return m_bounded_sequence_long_double_field; + } /*! * @brief This function returns a reference to member bounded_sequence_long_double_field * @return Reference to member bounded_sequence_long_double_field */ - eProsima_user_DllExport std::vector& bounded_sequence_long_double_field(); + eProsima_user_DllExport std::vector& bounded_sequence_long_double_field() + { + return m_bounded_sequence_long_double_field; + } /*! @@ -1618,26 +2802,38 @@ class ContentFilterTestType * @param _bounded_sequence_bool_field New value to be copied in member bounded_sequence_bool_field */ eProsima_user_DllExport void bounded_sequence_bool_field( - const std::vector& _bounded_sequence_bool_field); + const std::vector& _bounded_sequence_bool_field) + { + m_bounded_sequence_bool_field = _bounded_sequence_bool_field; + } /*! * @brief This function moves the value in member bounded_sequence_bool_field * @param _bounded_sequence_bool_field New value to be moved in member bounded_sequence_bool_field */ eProsima_user_DllExport void bounded_sequence_bool_field( - std::vector&& _bounded_sequence_bool_field); + std::vector&& _bounded_sequence_bool_field) + { + m_bounded_sequence_bool_field = std::move(_bounded_sequence_bool_field); + } /*! * @brief This function returns a constant reference to member bounded_sequence_bool_field * @return Constant reference to member bounded_sequence_bool_field */ - eProsima_user_DllExport const std::vector& bounded_sequence_bool_field() const; + eProsima_user_DllExport const std::vector& bounded_sequence_bool_field() const + { + return m_bounded_sequence_bool_field; + } /*! * @brief This function returns a reference to member bounded_sequence_bool_field * @return Reference to member bounded_sequence_bool_field */ - eProsima_user_DllExport std::vector& bounded_sequence_bool_field(); + eProsima_user_DllExport std::vector& bounded_sequence_bool_field() + { + return m_bounded_sequence_bool_field; + } /*! @@ -1645,26 +2841,38 @@ class ContentFilterTestType * @param _bounded_sequence_string_field New value to be copied in member bounded_sequence_string_field */ eProsima_user_DllExport void bounded_sequence_string_field( - const std::vector& _bounded_sequence_string_field); + const std::vector& _bounded_sequence_string_field) + { + m_bounded_sequence_string_field = _bounded_sequence_string_field; + } /*! * @brief This function moves the value in member bounded_sequence_string_field * @param _bounded_sequence_string_field New value to be moved in member bounded_sequence_string_field */ eProsima_user_DllExport void bounded_sequence_string_field( - std::vector&& _bounded_sequence_string_field); + std::vector&& _bounded_sequence_string_field) + { + m_bounded_sequence_string_field = std::move(_bounded_sequence_string_field); + } /*! * @brief This function returns a constant reference to member bounded_sequence_string_field * @return Constant reference to member bounded_sequence_string_field */ - eProsima_user_DllExport const std::vector& bounded_sequence_string_field() const; + eProsima_user_DllExport const std::vector& bounded_sequence_string_field() const + { + return m_bounded_sequence_string_field; + } /*! * @brief This function returns a reference to member bounded_sequence_string_field * @return Reference to member bounded_sequence_string_field */ - eProsima_user_DllExport std::vector& bounded_sequence_string_field(); + eProsima_user_DllExport std::vector& bounded_sequence_string_field() + { + return m_bounded_sequence_string_field; + } /*! @@ -1672,26 +2880,38 @@ class ContentFilterTestType * @param _bounded_sequence_enum_field New value to be copied in member bounded_sequence_enum_field */ eProsima_user_DllExport void bounded_sequence_enum_field( - const std::vector& _bounded_sequence_enum_field); + const std::vector& _bounded_sequence_enum_field) + { + m_bounded_sequence_enum_field = _bounded_sequence_enum_field; + } /*! * @brief This function moves the value in member bounded_sequence_enum_field * @param _bounded_sequence_enum_field New value to be moved in member bounded_sequence_enum_field */ eProsima_user_DllExport void bounded_sequence_enum_field( - std::vector&& _bounded_sequence_enum_field); + std::vector&& _bounded_sequence_enum_field) + { + m_bounded_sequence_enum_field = std::move(_bounded_sequence_enum_field); + } /*! * @brief This function returns a constant reference to member bounded_sequence_enum_field * @return Constant reference to member bounded_sequence_enum_field */ - eProsima_user_DllExport const std::vector& bounded_sequence_enum_field() const; + eProsima_user_DllExport const std::vector& bounded_sequence_enum_field() const + { + return m_bounded_sequence_enum_field; + } /*! * @brief This function returns a reference to member bounded_sequence_enum_field * @return Reference to member bounded_sequence_enum_field */ - eProsima_user_DllExport std::vector& bounded_sequence_enum_field(); + eProsima_user_DllExport std::vector& bounded_sequence_enum_field() + { + return m_bounded_sequence_enum_field; + } /*! @@ -1699,26 +2919,38 @@ class ContentFilterTestType * @param _bounded_sequence_enum2_field New value to be copied in member bounded_sequence_enum2_field */ eProsima_user_DllExport void bounded_sequence_enum2_field( - const std::vector& _bounded_sequence_enum2_field); + const std::vector& _bounded_sequence_enum2_field) + { + m_bounded_sequence_enum2_field = _bounded_sequence_enum2_field; + } /*! * @brief This function moves the value in member bounded_sequence_enum2_field * @param _bounded_sequence_enum2_field New value to be moved in member bounded_sequence_enum2_field */ eProsima_user_DllExport void bounded_sequence_enum2_field( - std::vector&& _bounded_sequence_enum2_field); + std::vector&& _bounded_sequence_enum2_field) + { + m_bounded_sequence_enum2_field = std::move(_bounded_sequence_enum2_field); + } /*! * @brief This function returns a constant reference to member bounded_sequence_enum2_field * @return Constant reference to member bounded_sequence_enum2_field */ - eProsima_user_DllExport const std::vector& bounded_sequence_enum2_field() const; + eProsima_user_DllExport const std::vector& bounded_sequence_enum2_field() const + { + return m_bounded_sequence_enum2_field; + } /*! * @brief This function returns a reference to member bounded_sequence_enum2_field * @return Reference to member bounded_sequence_enum2_field */ - eProsima_user_DllExport std::vector& bounded_sequence_enum2_field(); + eProsima_user_DllExport std::vector& bounded_sequence_enum2_field() + { + return m_bounded_sequence_enum2_field; + } /*! @@ -1726,26 +2958,38 @@ class ContentFilterTestType * @param _bounded_sequence_struct_field New value to be copied in member bounded_sequence_struct_field */ eProsima_user_DllExport void bounded_sequence_struct_field( - const std::vector& _bounded_sequence_struct_field); + const std::vector& _bounded_sequence_struct_field) + { + m_bounded_sequence_struct_field = _bounded_sequence_struct_field; + } /*! * @brief This function moves the value in member bounded_sequence_struct_field * @param _bounded_sequence_struct_field New value to be moved in member bounded_sequence_struct_field */ eProsima_user_DllExport void bounded_sequence_struct_field( - std::vector&& _bounded_sequence_struct_field); + std::vector&& _bounded_sequence_struct_field) + { + m_bounded_sequence_struct_field = std::move(_bounded_sequence_struct_field); + } /*! * @brief This function returns a constant reference to member bounded_sequence_struct_field * @return Constant reference to member bounded_sequence_struct_field */ - eProsima_user_DllExport const std::vector& bounded_sequence_struct_field() const; + eProsima_user_DllExport const std::vector& bounded_sequence_struct_field() const + { + return m_bounded_sequence_struct_field; + } /*! * @brief This function returns a reference to member bounded_sequence_struct_field * @return Reference to member bounded_sequence_struct_field */ - eProsima_user_DllExport std::vector& bounded_sequence_struct_field(); + eProsima_user_DllExport std::vector& bounded_sequence_struct_field() + { + return m_bounded_sequence_struct_field; + } /*! @@ -1753,26 +2997,38 @@ class ContentFilterTestType * @param _unbounded_sequence_char_field New value to be copied in member unbounded_sequence_char_field */ eProsima_user_DllExport void unbounded_sequence_char_field( - const std::vector& _unbounded_sequence_char_field); + const std::vector& _unbounded_sequence_char_field) + { + m_unbounded_sequence_char_field = _unbounded_sequence_char_field; + } /*! * @brief This function moves the value in member unbounded_sequence_char_field * @param _unbounded_sequence_char_field New value to be moved in member unbounded_sequence_char_field */ eProsima_user_DllExport void unbounded_sequence_char_field( - std::vector&& _unbounded_sequence_char_field); + std::vector&& _unbounded_sequence_char_field) + { + m_unbounded_sequence_char_field = std::move(_unbounded_sequence_char_field); + } /*! * @brief This function returns a constant reference to member unbounded_sequence_char_field * @return Constant reference to member unbounded_sequence_char_field */ - eProsima_user_DllExport const std::vector& unbounded_sequence_char_field() const; + eProsima_user_DllExport const std::vector& unbounded_sequence_char_field() const + { + return m_unbounded_sequence_char_field; + } /*! * @brief This function returns a reference to member unbounded_sequence_char_field * @return Reference to member unbounded_sequence_char_field */ - eProsima_user_DllExport std::vector& unbounded_sequence_char_field(); + eProsima_user_DllExport std::vector& unbounded_sequence_char_field() + { + return m_unbounded_sequence_char_field; + } /*! @@ -1780,26 +3036,38 @@ class ContentFilterTestType * @param _unbounded_sequence_uint8_field New value to be copied in member unbounded_sequence_uint8_field */ eProsima_user_DllExport void unbounded_sequence_uint8_field( - const std::vector& _unbounded_sequence_uint8_field); + const std::vector& _unbounded_sequence_uint8_field) + { + m_unbounded_sequence_uint8_field = _unbounded_sequence_uint8_field; + } /*! * @brief This function moves the value in member unbounded_sequence_uint8_field * @param _unbounded_sequence_uint8_field New value to be moved in member unbounded_sequence_uint8_field */ eProsima_user_DllExport void unbounded_sequence_uint8_field( - std::vector&& _unbounded_sequence_uint8_field); + std::vector&& _unbounded_sequence_uint8_field) + { + m_unbounded_sequence_uint8_field = std::move(_unbounded_sequence_uint8_field); + } /*! * @brief This function returns a constant reference to member unbounded_sequence_uint8_field * @return Constant reference to member unbounded_sequence_uint8_field */ - eProsima_user_DllExport const std::vector& unbounded_sequence_uint8_field() const; + eProsima_user_DllExport const std::vector& unbounded_sequence_uint8_field() const + { + return m_unbounded_sequence_uint8_field; + } /*! * @brief This function returns a reference to member unbounded_sequence_uint8_field * @return Reference to member unbounded_sequence_uint8_field */ - eProsima_user_DllExport std::vector& unbounded_sequence_uint8_field(); + eProsima_user_DllExport std::vector& unbounded_sequence_uint8_field() + { + return m_unbounded_sequence_uint8_field; + } /*! @@ -1807,26 +3075,38 @@ class ContentFilterTestType * @param _unbounded_sequence_int16_field New value to be copied in member unbounded_sequence_int16_field */ eProsima_user_DllExport void unbounded_sequence_int16_field( - const std::vector& _unbounded_sequence_int16_field); + const std::vector& _unbounded_sequence_int16_field) + { + m_unbounded_sequence_int16_field = _unbounded_sequence_int16_field; + } /*! * @brief This function moves the value in member unbounded_sequence_int16_field * @param _unbounded_sequence_int16_field New value to be moved in member unbounded_sequence_int16_field */ eProsima_user_DllExport void unbounded_sequence_int16_field( - std::vector&& _unbounded_sequence_int16_field); + std::vector&& _unbounded_sequence_int16_field) + { + m_unbounded_sequence_int16_field = std::move(_unbounded_sequence_int16_field); + } /*! * @brief This function returns a constant reference to member unbounded_sequence_int16_field * @return Constant reference to member unbounded_sequence_int16_field */ - eProsima_user_DllExport const std::vector& unbounded_sequence_int16_field() const; + eProsima_user_DllExport const std::vector& unbounded_sequence_int16_field() const + { + return m_unbounded_sequence_int16_field; + } /*! * @brief This function returns a reference to member unbounded_sequence_int16_field * @return Reference to member unbounded_sequence_int16_field */ - eProsima_user_DllExport std::vector& unbounded_sequence_int16_field(); + eProsima_user_DllExport std::vector& unbounded_sequence_int16_field() + { + return m_unbounded_sequence_int16_field; + } /*! @@ -1834,26 +3114,38 @@ class ContentFilterTestType * @param _unbounded_sequence_uint16_field New value to be copied in member unbounded_sequence_uint16_field */ eProsima_user_DllExport void unbounded_sequence_uint16_field( - const std::vector& _unbounded_sequence_uint16_field); + const std::vector& _unbounded_sequence_uint16_field) + { + m_unbounded_sequence_uint16_field = _unbounded_sequence_uint16_field; + } /*! * @brief This function moves the value in member unbounded_sequence_uint16_field * @param _unbounded_sequence_uint16_field New value to be moved in member unbounded_sequence_uint16_field */ eProsima_user_DllExport void unbounded_sequence_uint16_field( - std::vector&& _unbounded_sequence_uint16_field); + std::vector&& _unbounded_sequence_uint16_field) + { + m_unbounded_sequence_uint16_field = std::move(_unbounded_sequence_uint16_field); + } /*! * @brief This function returns a constant reference to member unbounded_sequence_uint16_field * @return Constant reference to member unbounded_sequence_uint16_field */ - eProsima_user_DllExport const std::vector& unbounded_sequence_uint16_field() const; + eProsima_user_DllExport const std::vector& unbounded_sequence_uint16_field() const + { + return m_unbounded_sequence_uint16_field; + } /*! * @brief This function returns a reference to member unbounded_sequence_uint16_field * @return Reference to member unbounded_sequence_uint16_field */ - eProsima_user_DllExport std::vector& unbounded_sequence_uint16_field(); + eProsima_user_DllExport std::vector& unbounded_sequence_uint16_field() + { + return m_unbounded_sequence_uint16_field; + } /*! @@ -1861,26 +3153,38 @@ class ContentFilterTestType * @param _unbounded_sequence_int32_field New value to be copied in member unbounded_sequence_int32_field */ eProsima_user_DllExport void unbounded_sequence_int32_field( - const std::vector& _unbounded_sequence_int32_field); + const std::vector& _unbounded_sequence_int32_field) + { + m_unbounded_sequence_int32_field = _unbounded_sequence_int32_field; + } /*! * @brief This function moves the value in member unbounded_sequence_int32_field * @param _unbounded_sequence_int32_field New value to be moved in member unbounded_sequence_int32_field */ eProsima_user_DllExport void unbounded_sequence_int32_field( - std::vector&& _unbounded_sequence_int32_field); + std::vector&& _unbounded_sequence_int32_field) + { + m_unbounded_sequence_int32_field = std::move(_unbounded_sequence_int32_field); + } /*! * @brief This function returns a constant reference to member unbounded_sequence_int32_field * @return Constant reference to member unbounded_sequence_int32_field */ - eProsima_user_DllExport const std::vector& unbounded_sequence_int32_field() const; + eProsima_user_DllExport const std::vector& unbounded_sequence_int32_field() const + { + return m_unbounded_sequence_int32_field; + } /*! * @brief This function returns a reference to member unbounded_sequence_int32_field * @return Reference to member unbounded_sequence_int32_field */ - eProsima_user_DllExport std::vector& unbounded_sequence_int32_field(); + eProsima_user_DllExport std::vector& unbounded_sequence_int32_field() + { + return m_unbounded_sequence_int32_field; + } /*! @@ -1888,26 +3192,38 @@ class ContentFilterTestType * @param _unbounded_sequence_uint32_field New value to be copied in member unbounded_sequence_uint32_field */ eProsima_user_DllExport void unbounded_sequence_uint32_field( - const std::vector& _unbounded_sequence_uint32_field); + const std::vector& _unbounded_sequence_uint32_field) + { + m_unbounded_sequence_uint32_field = _unbounded_sequence_uint32_field; + } /*! * @brief This function moves the value in member unbounded_sequence_uint32_field * @param _unbounded_sequence_uint32_field New value to be moved in member unbounded_sequence_uint32_field */ eProsima_user_DllExport void unbounded_sequence_uint32_field( - std::vector&& _unbounded_sequence_uint32_field); + std::vector&& _unbounded_sequence_uint32_field) + { + m_unbounded_sequence_uint32_field = std::move(_unbounded_sequence_uint32_field); + } /*! * @brief This function returns a constant reference to member unbounded_sequence_uint32_field * @return Constant reference to member unbounded_sequence_uint32_field */ - eProsima_user_DllExport const std::vector& unbounded_sequence_uint32_field() const; + eProsima_user_DllExport const std::vector& unbounded_sequence_uint32_field() const + { + return m_unbounded_sequence_uint32_field; + } /*! * @brief This function returns a reference to member unbounded_sequence_uint32_field * @return Reference to member unbounded_sequence_uint32_field */ - eProsima_user_DllExport std::vector& unbounded_sequence_uint32_field(); + eProsima_user_DllExport std::vector& unbounded_sequence_uint32_field() + { + return m_unbounded_sequence_uint32_field; + } /*! @@ -1915,26 +3231,38 @@ class ContentFilterTestType * @param _unbounded_sequence_int64_field New value to be copied in member unbounded_sequence_int64_field */ eProsima_user_DllExport void unbounded_sequence_int64_field( - const std::vector& _unbounded_sequence_int64_field); + const std::vector& _unbounded_sequence_int64_field) + { + m_unbounded_sequence_int64_field = _unbounded_sequence_int64_field; + } /*! * @brief This function moves the value in member unbounded_sequence_int64_field * @param _unbounded_sequence_int64_field New value to be moved in member unbounded_sequence_int64_field */ eProsima_user_DllExport void unbounded_sequence_int64_field( - std::vector&& _unbounded_sequence_int64_field); + std::vector&& _unbounded_sequence_int64_field) + { + m_unbounded_sequence_int64_field = std::move(_unbounded_sequence_int64_field); + } /*! * @brief This function returns a constant reference to member unbounded_sequence_int64_field * @return Constant reference to member unbounded_sequence_int64_field */ - eProsima_user_DllExport const std::vector& unbounded_sequence_int64_field() const; + eProsima_user_DllExport const std::vector& unbounded_sequence_int64_field() const + { + return m_unbounded_sequence_int64_field; + } /*! * @brief This function returns a reference to member unbounded_sequence_int64_field * @return Reference to member unbounded_sequence_int64_field */ - eProsima_user_DllExport std::vector& unbounded_sequence_int64_field(); + eProsima_user_DllExport std::vector& unbounded_sequence_int64_field() + { + return m_unbounded_sequence_int64_field; + } /*! @@ -1942,26 +3270,38 @@ class ContentFilterTestType * @param _unbounded_sequence_uint64_field New value to be copied in member unbounded_sequence_uint64_field */ eProsima_user_DllExport void unbounded_sequence_uint64_field( - const std::vector& _unbounded_sequence_uint64_field); + const std::vector& _unbounded_sequence_uint64_field) + { + m_unbounded_sequence_uint64_field = _unbounded_sequence_uint64_field; + } /*! * @brief This function moves the value in member unbounded_sequence_uint64_field * @param _unbounded_sequence_uint64_field New value to be moved in member unbounded_sequence_uint64_field */ eProsima_user_DllExport void unbounded_sequence_uint64_field( - std::vector&& _unbounded_sequence_uint64_field); + std::vector&& _unbounded_sequence_uint64_field) + { + m_unbounded_sequence_uint64_field = std::move(_unbounded_sequence_uint64_field); + } /*! * @brief This function returns a constant reference to member unbounded_sequence_uint64_field * @return Constant reference to member unbounded_sequence_uint64_field */ - eProsima_user_DllExport const std::vector& unbounded_sequence_uint64_field() const; + eProsima_user_DllExport const std::vector& unbounded_sequence_uint64_field() const + { + return m_unbounded_sequence_uint64_field; + } /*! * @brief This function returns a reference to member unbounded_sequence_uint64_field * @return Reference to member unbounded_sequence_uint64_field */ - eProsima_user_DllExport std::vector& unbounded_sequence_uint64_field(); + eProsima_user_DllExport std::vector& unbounded_sequence_uint64_field() + { + return m_unbounded_sequence_uint64_field; + } /*! @@ -1969,26 +3309,38 @@ class ContentFilterTestType * @param _unbounded_sequence_float_field New value to be copied in member unbounded_sequence_float_field */ eProsima_user_DllExport void unbounded_sequence_float_field( - const std::vector& _unbounded_sequence_float_field); + const std::vector& _unbounded_sequence_float_field) + { + m_unbounded_sequence_float_field = _unbounded_sequence_float_field; + } /*! * @brief This function moves the value in member unbounded_sequence_float_field * @param _unbounded_sequence_float_field New value to be moved in member unbounded_sequence_float_field */ eProsima_user_DllExport void unbounded_sequence_float_field( - std::vector&& _unbounded_sequence_float_field); + std::vector&& _unbounded_sequence_float_field) + { + m_unbounded_sequence_float_field = std::move(_unbounded_sequence_float_field); + } /*! * @brief This function returns a constant reference to member unbounded_sequence_float_field * @return Constant reference to member unbounded_sequence_float_field */ - eProsima_user_DllExport const std::vector& unbounded_sequence_float_field() const; + eProsima_user_DllExport const std::vector& unbounded_sequence_float_field() const + { + return m_unbounded_sequence_float_field; + } /*! * @brief This function returns a reference to member unbounded_sequence_float_field * @return Reference to member unbounded_sequence_float_field */ - eProsima_user_DllExport std::vector& unbounded_sequence_float_field(); + eProsima_user_DllExport std::vector& unbounded_sequence_float_field() + { + return m_unbounded_sequence_float_field; + } /*! @@ -1996,26 +3348,38 @@ class ContentFilterTestType * @param _unbounded_sequence_double_field New value to be copied in member unbounded_sequence_double_field */ eProsima_user_DllExport void unbounded_sequence_double_field( - const std::vector& _unbounded_sequence_double_field); + const std::vector& _unbounded_sequence_double_field) + { + m_unbounded_sequence_double_field = _unbounded_sequence_double_field; + } /*! * @brief This function moves the value in member unbounded_sequence_double_field * @param _unbounded_sequence_double_field New value to be moved in member unbounded_sequence_double_field */ eProsima_user_DllExport void unbounded_sequence_double_field( - std::vector&& _unbounded_sequence_double_field); + std::vector&& _unbounded_sequence_double_field) + { + m_unbounded_sequence_double_field = std::move(_unbounded_sequence_double_field); + } /*! * @brief This function returns a constant reference to member unbounded_sequence_double_field * @return Constant reference to member unbounded_sequence_double_field */ - eProsima_user_DllExport const std::vector& unbounded_sequence_double_field() const; + eProsima_user_DllExport const std::vector& unbounded_sequence_double_field() const + { + return m_unbounded_sequence_double_field; + } /*! * @brief This function returns a reference to member unbounded_sequence_double_field * @return Reference to member unbounded_sequence_double_field */ - eProsima_user_DllExport std::vector& unbounded_sequence_double_field(); + eProsima_user_DllExport std::vector& unbounded_sequence_double_field() + { + return m_unbounded_sequence_double_field; + } /*! @@ -2023,26 +3387,38 @@ class ContentFilterTestType * @param _unbounded_sequence_long_double_field New value to be copied in member unbounded_sequence_long_double_field */ eProsima_user_DllExport void unbounded_sequence_long_double_field( - const std::vector& _unbounded_sequence_long_double_field); + const std::vector& _unbounded_sequence_long_double_field) + { + m_unbounded_sequence_long_double_field = _unbounded_sequence_long_double_field; + } /*! * @brief This function moves the value in member unbounded_sequence_long_double_field * @param _unbounded_sequence_long_double_field New value to be moved in member unbounded_sequence_long_double_field */ eProsima_user_DllExport void unbounded_sequence_long_double_field( - std::vector&& _unbounded_sequence_long_double_field); + std::vector&& _unbounded_sequence_long_double_field) + { + m_unbounded_sequence_long_double_field = std::move(_unbounded_sequence_long_double_field); + } /*! * @brief This function returns a constant reference to member unbounded_sequence_long_double_field * @return Constant reference to member unbounded_sequence_long_double_field */ - eProsima_user_DllExport const std::vector& unbounded_sequence_long_double_field() const; + eProsima_user_DllExport const std::vector& unbounded_sequence_long_double_field() const + { + return m_unbounded_sequence_long_double_field; + } /*! * @brief This function returns a reference to member unbounded_sequence_long_double_field * @return Reference to member unbounded_sequence_long_double_field */ - eProsima_user_DllExport std::vector& unbounded_sequence_long_double_field(); + eProsima_user_DllExport std::vector& unbounded_sequence_long_double_field() + { + return m_unbounded_sequence_long_double_field; + } /*! @@ -2050,26 +3426,38 @@ class ContentFilterTestType * @param _unbounded_sequence_bool_field New value to be copied in member unbounded_sequence_bool_field */ eProsima_user_DllExport void unbounded_sequence_bool_field( - const std::vector& _unbounded_sequence_bool_field); + const std::vector& _unbounded_sequence_bool_field) + { + m_unbounded_sequence_bool_field = _unbounded_sequence_bool_field; + } /*! * @brief This function moves the value in member unbounded_sequence_bool_field * @param _unbounded_sequence_bool_field New value to be moved in member unbounded_sequence_bool_field */ eProsima_user_DllExport void unbounded_sequence_bool_field( - std::vector&& _unbounded_sequence_bool_field); + std::vector&& _unbounded_sequence_bool_field) + { + m_unbounded_sequence_bool_field = std::move(_unbounded_sequence_bool_field); + } /*! * @brief This function returns a constant reference to member unbounded_sequence_bool_field * @return Constant reference to member unbounded_sequence_bool_field */ - eProsima_user_DllExport const std::vector& unbounded_sequence_bool_field() const; + eProsima_user_DllExport const std::vector& unbounded_sequence_bool_field() const + { + return m_unbounded_sequence_bool_field; + } /*! * @brief This function returns a reference to member unbounded_sequence_bool_field * @return Reference to member unbounded_sequence_bool_field */ - eProsima_user_DllExport std::vector& unbounded_sequence_bool_field(); + eProsima_user_DllExport std::vector& unbounded_sequence_bool_field() + { + return m_unbounded_sequence_bool_field; + } /*! @@ -2077,26 +3465,38 @@ class ContentFilterTestType * @param _unbounded_sequence_string_field New value to be copied in member unbounded_sequence_string_field */ eProsima_user_DllExport void unbounded_sequence_string_field( - const std::vector& _unbounded_sequence_string_field); + const std::vector& _unbounded_sequence_string_field) + { + m_unbounded_sequence_string_field = _unbounded_sequence_string_field; + } /*! * @brief This function moves the value in member unbounded_sequence_string_field * @param _unbounded_sequence_string_field New value to be moved in member unbounded_sequence_string_field */ eProsima_user_DllExport void unbounded_sequence_string_field( - std::vector&& _unbounded_sequence_string_field); + std::vector&& _unbounded_sequence_string_field) + { + m_unbounded_sequence_string_field = std::move(_unbounded_sequence_string_field); + } /*! * @brief This function returns a constant reference to member unbounded_sequence_string_field * @return Constant reference to member unbounded_sequence_string_field */ - eProsima_user_DllExport const std::vector& unbounded_sequence_string_field() const; + eProsima_user_DllExport const std::vector& unbounded_sequence_string_field() const + { + return m_unbounded_sequence_string_field; + } /*! * @brief This function returns a reference to member unbounded_sequence_string_field * @return Reference to member unbounded_sequence_string_field */ - eProsima_user_DllExport std::vector& unbounded_sequence_string_field(); + eProsima_user_DllExport std::vector& unbounded_sequence_string_field() + { + return m_unbounded_sequence_string_field; + } /*! @@ -2104,26 +3504,38 @@ class ContentFilterTestType * @param _unbounded_sequence_enum_field New value to be copied in member unbounded_sequence_enum_field */ eProsima_user_DllExport void unbounded_sequence_enum_field( - const std::vector& _unbounded_sequence_enum_field); + const std::vector& _unbounded_sequence_enum_field) + { + m_unbounded_sequence_enum_field = _unbounded_sequence_enum_field; + } /*! * @brief This function moves the value in member unbounded_sequence_enum_field * @param _unbounded_sequence_enum_field New value to be moved in member unbounded_sequence_enum_field */ eProsima_user_DllExport void unbounded_sequence_enum_field( - std::vector&& _unbounded_sequence_enum_field); + std::vector&& _unbounded_sequence_enum_field) + { + m_unbounded_sequence_enum_field = std::move(_unbounded_sequence_enum_field); + } /*! * @brief This function returns a constant reference to member unbounded_sequence_enum_field * @return Constant reference to member unbounded_sequence_enum_field */ - eProsima_user_DllExport const std::vector& unbounded_sequence_enum_field() const; + eProsima_user_DllExport const std::vector& unbounded_sequence_enum_field() const + { + return m_unbounded_sequence_enum_field; + } /*! * @brief This function returns a reference to member unbounded_sequence_enum_field * @return Reference to member unbounded_sequence_enum_field */ - eProsima_user_DllExport std::vector& unbounded_sequence_enum_field(); + eProsima_user_DllExport std::vector& unbounded_sequence_enum_field() + { + return m_unbounded_sequence_enum_field; + } /*! @@ -2131,26 +3543,38 @@ class ContentFilterTestType * @param _unbounded_sequence_enum2_field New value to be copied in member unbounded_sequence_enum2_field */ eProsima_user_DllExport void unbounded_sequence_enum2_field( - const std::vector& _unbounded_sequence_enum2_field); + const std::vector& _unbounded_sequence_enum2_field) + { + m_unbounded_sequence_enum2_field = _unbounded_sequence_enum2_field; + } /*! * @brief This function moves the value in member unbounded_sequence_enum2_field * @param _unbounded_sequence_enum2_field New value to be moved in member unbounded_sequence_enum2_field */ eProsima_user_DllExport void unbounded_sequence_enum2_field( - std::vector&& _unbounded_sequence_enum2_field); + std::vector&& _unbounded_sequence_enum2_field) + { + m_unbounded_sequence_enum2_field = std::move(_unbounded_sequence_enum2_field); + } /*! * @brief This function returns a constant reference to member unbounded_sequence_enum2_field * @return Constant reference to member unbounded_sequence_enum2_field */ - eProsima_user_DllExport const std::vector& unbounded_sequence_enum2_field() const; + eProsima_user_DllExport const std::vector& unbounded_sequence_enum2_field() const + { + return m_unbounded_sequence_enum2_field; + } /*! * @brief This function returns a reference to member unbounded_sequence_enum2_field * @return Reference to member unbounded_sequence_enum2_field */ - eProsima_user_DllExport std::vector& unbounded_sequence_enum2_field(); + eProsima_user_DllExport std::vector& unbounded_sequence_enum2_field() + { + return m_unbounded_sequence_enum2_field; + } /*! @@ -2158,26 +3582,40 @@ class ContentFilterTestType * @param _unbounded_sequence_struct_field New value to be copied in member unbounded_sequence_struct_field */ eProsima_user_DllExport void unbounded_sequence_struct_field( - const std::vector& _unbounded_sequence_struct_field); + const std::vector& _unbounded_sequence_struct_field) + { + m_unbounded_sequence_struct_field = _unbounded_sequence_struct_field; + } /*! * @brief This function moves the value in member unbounded_sequence_struct_field * @param _unbounded_sequence_struct_field New value to be moved in member unbounded_sequence_struct_field */ eProsima_user_DllExport void unbounded_sequence_struct_field( - std::vector&& _unbounded_sequence_struct_field); + std::vector&& _unbounded_sequence_struct_field) + { + m_unbounded_sequence_struct_field = std::move(_unbounded_sequence_struct_field); + } /*! * @brief This function returns a constant reference to member unbounded_sequence_struct_field * @return Constant reference to member unbounded_sequence_struct_field */ - eProsima_user_DllExport const std::vector& unbounded_sequence_struct_field() const; + eProsima_user_DllExport const std::vector& unbounded_sequence_struct_field() const + { + return m_unbounded_sequence_struct_field; + } /*! * @brief This function returns a reference to member unbounded_sequence_struct_field * @return Reference to member unbounded_sequence_struct_field */ - eProsima_user_DllExport std::vector& unbounded_sequence_struct_field(); + eProsima_user_DllExport std::vector& unbounded_sequence_struct_field() + { + return m_unbounded_sequence_struct_field; + } + + private: @@ -2194,8 +3632,8 @@ class ContentFilterTestType long double m_long_double_field{0.0}; bool m_bool_field{false}; std::string m_string_field; - Color m_enum_field{::RED}; - Material m_enum2_field{::WOOD}; + Color m_enum_field{Color::RED}; + Material m_enum2_field{Material::WOOD}; StructType m_struct_field; std::array m_array_char_field{0}; std::array m_array_uint8_field{0}; @@ -2210,8 +3648,8 @@ class ContentFilterTestType std::array m_array_long_double_field{0.0}; std::array m_array_bool_field{false}; std::array m_array_string_field; - std::array m_array_enum_field{::RED}; - std::array m_array_enum2_field{::WOOD}; + std::array m_array_enum_field{Color::RED}; + std::array m_array_enum2_field{Material::WOOD}; std::array m_array_struct_field; std::vector m_bounded_sequence_char_field; std::vector m_bounded_sequence_uint8_field; @@ -2248,8 +3686,6 @@ class ContentFilterTestType }; -#endif // _FAST_DDS_GENERATED_CONTENTFILTERTESTTYPE_H_ - +#endif // _FAST_DDS_GENERATED_CONTENTFILTERTESTTYPE_HPP_ -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypeCdrAux.hpp b/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypeCdrAux.hpp index f1ae8c42f15..c0276205e62 100644 --- a/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypeCdrAux.hpp +++ b/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypeCdrAux.hpp @@ -22,12 +22,12 @@ #ifndef _FAST_DDS_GENERATED_CONTENTFILTERTESTTYPECDRAUX_HPP_ #define _FAST_DDS_GENERATED_CONTENTFILTERTESTTYPECDRAUX_HPP_ -#include "ContentFilterTestType.h" +#include "ContentFilterTestType.hpp" constexpr uint32_t StructType_max_cdr_typesize {344UL}; constexpr uint32_t StructType_max_key_cdr_typesize {0UL}; -constexpr uint32_t ContentFilterTestType_max_cdr_typesize {73360UL}; +constexpr uint32_t ContentFilterTestType_max_cdr_typesize {6248UL}; constexpr uint32_t ContentFilterTestType_max_key_cdr_typesize {0UL}; @@ -39,20 +39,12 @@ namespace fastcdr { class Cdr; class CdrSizeCalculator; - - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const StructType& data); - - - - - - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const ContentFilterTestType& data); diff --git a/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypeCdrAux.ipp b/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypeCdrAux.ipp index 6e0b9053b9d..22665d4a663 100644 --- a/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypeCdrAux.ipp +++ b/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypeCdrAux.ipp @@ -34,8 +34,6 @@ using namespace eprosima::fastcdr::exception; namespace eprosima { namespace fastcdr { - - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, @@ -226,12 +224,6 @@ void serialize_key( - - - - - - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, diff --git a/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypePubSubTypes.cxx b/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypePubSubTypes.cxx index c4bd34e1232..f33c4acd920 100644 --- a/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypePubSubTypes.cxx +++ b/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypePubSubTypes.cxx @@ -19,18 +19,18 @@ * This file was generated by the tool fastddsgen. */ +#include "ContentFilterTestTypePubSubTypes.h" +#include #include -#include "ContentFilterTestTypePubSubTypes.h" #include "ContentFilterTestTypeCdrAux.hpp" +#include "ContentFilterTestTypeTypeObjectSupport.hpp" using SerializedPayload_t = eprosima::fastrtps::rtps::SerializedPayload_t; using InstanceHandle_t = eprosima::fastrtps::rtps::InstanceHandle_t; using DataRepresentationId_t = eprosima::fastdds::dds::DataRepresentationId_t; - - StructTypePubSubType::StructTypePubSubType() { setName("StructType"); @@ -219,11 +219,10 @@ bool StructTypePubSubType::getKey( return true; } - - - - - +void StructTypePubSubType::register_type_object_representation() const +{ + register_ContentFilterTestType_type_objects(); +} @@ -415,3 +414,11 @@ bool ContentFilterTestTypePubSubType::getKey( return true; } +void ContentFilterTestTypePubSubType::register_type_object_representation() const +{ + register_ContentFilterTestType_type_objects(); +} + + +// Include auxiliary functions like for serializing/deserializing. +#include "ContentFilterTestTypeCdrAux.ipp" diff --git a/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypePubSubTypes.h b/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypePubSubTypes.h index 776f184b73e..adac04295fb 100644 --- a/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypePubSubTypes.h +++ b/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypePubSubTypes.h @@ -27,9 +27,9 @@ #include #include #include -#include +#include -#include "ContentFilterTestType.h" +#include "ContentFilterTestType.hpp" #if !defined(GEN_API_VER) || (GEN_API_VER != 2) @@ -38,8 +38,6 @@ #endif // GEN_API_VER - - /*! * @brief This class represents the TopicDataType of the type StructType defined by the user in the IDL file. * @ingroup ContentFilterTestType @@ -90,6 +88,9 @@ class StructTypePubSubType : public eprosima::fastdds::dds::TopicDataType eProsima_user_DllExport void deleteData( void* data) override; + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + #ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED eProsima_user_DllExport inline bool is_bounded() const override { @@ -130,12 +131,6 @@ class StructTypePubSubType : public eprosima::fastdds::dds::TopicDataType - - - - - - /*! * @brief This class represents the TopicDataType of the type ContentFilterTestType defined by the user in the IDL file. * @ingroup ContentFilterTestType @@ -186,6 +181,9 @@ class ContentFilterTestTypePubSubType : public eprosima::fastdds::dds::TopicData eProsima_user_DllExport void deleteData( void* data) override; + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() const override; + #ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED eProsima_user_DllExport inline bool is_bounded() const override { diff --git a/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypeTypeObject.cxx b/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypeTypeObject.cxx deleted file mode 100644 index c9ec87ccb80..00000000000 --- a/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypeTypeObject.cxx +++ /dev/null @@ -1,3610 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file ContentFilterTestTypeTypeObject.cpp - * This source file contains the definition of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { char dummy; } -#endif - -#include "ContentFilterTestType.h" -#include "ContentFilterTestTypeTypeObject.h" -#include -#include -#include -#include -#include -#include -#include -#include -#include - -using namespace eprosima::fastrtps::rtps; - -void registerContentFilterTestTypeTypes() -{ - static std::once_flag once_flag; - std::call_once(once_flag, []() - { - TypeObjectFactory *factory = TypeObjectFactory::get_instance(); - factory->add_type_object("Color", GetColorIdentifier(true), - GetColorObject(true)); - factory->add_type_object("Color", GetColorIdentifier(false), - GetColorObject(false)); - - - factory->add_type_object("Material", GetMaterialIdentifier(true), - GetMaterialObject(true)); - factory->add_type_object("Material", GetMaterialIdentifier(false), - GetMaterialObject(false)); - - - factory->add_type_object("StructType", GetStructTypeIdentifier(true), - GetStructTypeObject(true)); - factory->add_type_object("StructType", GetStructTypeIdentifier(false), - GetStructTypeObject(false)); - - - - - factory->add_type_object("ContentFilterTestType", GetContentFilterTestTypeIdentifier(true), - GetContentFilterTestTypeObject(true)); - factory->add_type_object("ContentFilterTestType", GetContentFilterTestTypeIdentifier(false), - GetContentFilterTestTypeObject(false)); - - }); -} - -const TypeIdentifier* GetColorIdentifier(bool complete) -{ - const TypeIdentifier* c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("Color", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetColorObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("Color", complete); -} - -const TypeObject* GetColorObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("Color", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteColorObject(); - } - // else - return GetMinimalColorObject(); -} - -const TypeObject* GetMinimalColorObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("Color", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_ENUM); - - // No flags apply - //type_object->minimal().enumerated_type().enum_flags().IS_FINAL(false); - //type_object->minimal().enumerated_type().enum_flags().IS_APPENDABLE(false); - //type_object->minimal().enumerated_type().enum_flags().IS_MUTABLE(false); - //type_object->minimal().enumerated_type().enum_flags().IS_NESTED(false); - //type_object->minimal().enumerated_type().enum_flags().IS_AUTOID_HASH(false); - - type_object->minimal().enumerated_type().header().common().bit_bound(32); // TODO fixed by IDL, isn't? - - uint32_t value = 0; - MinimalEnumeratedLiteral mel_RED; - mel_RED.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - mel_RED.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - mel_RED.common().flags().IS_EXTERNAL(false); // Doesn't apply - mel_RED.common().flags().IS_OPTIONAL(false); // Doesn't apply - mel_RED.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mel_RED.common().flags().IS_KEY(false); // Doesn't apply - mel_RED.common().flags().IS_DEFAULT(false); - mel_RED.common().value(value++); - MD5 RED_hash("RED"); - for(int i = 0; i < 4; ++i) - { - mel_RED.detail().name_hash()[i] = RED_hash.digest[i]; - } - type_object->minimal().enumerated_type().literal_seq().emplace_back(mel_RED); - - MinimalEnumeratedLiteral mel_GREEN; - mel_GREEN.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - mel_GREEN.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - mel_GREEN.common().flags().IS_EXTERNAL(false); // Doesn't apply - mel_GREEN.common().flags().IS_OPTIONAL(false); // Doesn't apply - mel_GREEN.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mel_GREEN.common().flags().IS_KEY(false); // Doesn't apply - mel_GREEN.common().flags().IS_DEFAULT(false); - mel_GREEN.common().value(value++); - MD5 GREEN_hash("GREEN"); - for(int i = 0; i < 4; ++i) - { - mel_GREEN.detail().name_hash()[i] = GREEN_hash.digest[i]; - } - type_object->minimal().enumerated_type().literal_seq().emplace_back(mel_GREEN); - - MinimalEnumeratedLiteral mel_BLUE; - mel_BLUE.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - mel_BLUE.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - mel_BLUE.common().flags().IS_EXTERNAL(false); // Doesn't apply - mel_BLUE.common().flags().IS_OPTIONAL(false); // Doesn't apply - mel_BLUE.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mel_BLUE.common().flags().IS_KEY(false); // Doesn't apply - mel_BLUE.common().flags().IS_DEFAULT(false); - mel_BLUE.common().value(value++); - MD5 BLUE_hash("BLUE"); - for(int i = 0; i < 4; ++i) - { - mel_BLUE.detail().name_hash()[i] = BLUE_hash.digest[i]; - } - type_object->minimal().enumerated_type().literal_seq().emplace_back(mel_BLUE); - - MinimalEnumeratedLiteral mel_YELLOW; - mel_YELLOW.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - mel_YELLOW.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - mel_YELLOW.common().flags().IS_EXTERNAL(false); // Doesn't apply - mel_YELLOW.common().flags().IS_OPTIONAL(false); // Doesn't apply - mel_YELLOW.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mel_YELLOW.common().flags().IS_KEY(false); // Doesn't apply - mel_YELLOW.common().flags().IS_DEFAULT(false); - mel_YELLOW.common().value(value++); - MD5 YELLOW_hash("YELLOW"); - for(int i = 0; i < 4; ++i) - { - mel_YELLOW.detail().name_hash()[i] = YELLOW_hash.digest[i]; - } - type_object->minimal().enumerated_type().literal_seq().emplace_back(mel_YELLOW); - - MinimalEnumeratedLiteral mel_MAGENTA; - mel_MAGENTA.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - mel_MAGENTA.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - mel_MAGENTA.common().flags().IS_EXTERNAL(false); // Doesn't apply - mel_MAGENTA.common().flags().IS_OPTIONAL(false); // Doesn't apply - mel_MAGENTA.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mel_MAGENTA.common().flags().IS_KEY(false); // Doesn't apply - mel_MAGENTA.common().flags().IS_DEFAULT(false); - mel_MAGENTA.common().value(value++); - MD5 MAGENTA_hash("MAGENTA"); - for(int i = 0; i < 4; ++i) - { - mel_MAGENTA.detail().name_hash()[i] = MAGENTA_hash.digest[i]; - } - type_object->minimal().enumerated_type().literal_seq().emplace_back(mel_MAGENTA); - - - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().enumerated_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("Color", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("Color", false); -} - -const TypeObject* GetCompleteColorObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("Color", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_ENUM); - - // No flags apply - //type_object->complete().enumerated_type().enum_flags().IS_FINAL(false); - //type_object->complete().enumerated_type().enum_flags().IS_APPENDABLE(false); - //type_object->complete().enumerated_type().enum_flags().IS_MUTABLE(false); - //type_object->complete().enumerated_type().enum_flags().IS_NESTED(false); - //type_object->complete().enumerated_type().enum_flags().IS_AUTOID_HASH(false); - - type_object->complete().enumerated_type().header().common().bit_bound(32); // TODO fixed by IDL, isn't? - type_object->complete().enumerated_type().header().detail().type_name("Color"); - - uint32_t value = 0; - CompleteEnumeratedLiteral cel_RED; - cel_RED.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - cel_RED.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - cel_RED.common().flags().IS_EXTERNAL(false); // Doesn't apply - cel_RED.common().flags().IS_OPTIONAL(false); // Doesn't apply - cel_RED.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cel_RED.common().flags().IS_KEY(false); // Doesn't apply - cel_RED.common().flags().IS_DEFAULT(false); - cel_RED.common().value(value++); - cel_RED.detail().name("RED"); - - type_object->complete().enumerated_type().literal_seq().emplace_back(cel_RED); - - CompleteEnumeratedLiteral cel_GREEN; - cel_GREEN.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - cel_GREEN.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - cel_GREEN.common().flags().IS_EXTERNAL(false); // Doesn't apply - cel_GREEN.common().flags().IS_OPTIONAL(false); // Doesn't apply - cel_GREEN.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cel_GREEN.common().flags().IS_KEY(false); // Doesn't apply - cel_GREEN.common().flags().IS_DEFAULT(false); - cel_GREEN.common().value(value++); - cel_GREEN.detail().name("GREEN"); - - type_object->complete().enumerated_type().literal_seq().emplace_back(cel_GREEN); - - CompleteEnumeratedLiteral cel_BLUE; - cel_BLUE.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - cel_BLUE.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - cel_BLUE.common().flags().IS_EXTERNAL(false); // Doesn't apply - cel_BLUE.common().flags().IS_OPTIONAL(false); // Doesn't apply - cel_BLUE.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cel_BLUE.common().flags().IS_KEY(false); // Doesn't apply - cel_BLUE.common().flags().IS_DEFAULT(false); - cel_BLUE.common().value(value++); - cel_BLUE.detail().name("BLUE"); - - type_object->complete().enumerated_type().literal_seq().emplace_back(cel_BLUE); - - CompleteEnumeratedLiteral cel_YELLOW; - cel_YELLOW.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - cel_YELLOW.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - cel_YELLOW.common().flags().IS_EXTERNAL(false); // Doesn't apply - cel_YELLOW.common().flags().IS_OPTIONAL(false); // Doesn't apply - cel_YELLOW.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cel_YELLOW.common().flags().IS_KEY(false); // Doesn't apply - cel_YELLOW.common().flags().IS_DEFAULT(false); - cel_YELLOW.common().value(value++); - cel_YELLOW.detail().name("YELLOW"); - - type_object->complete().enumerated_type().literal_seq().emplace_back(cel_YELLOW); - - CompleteEnumeratedLiteral cel_MAGENTA; - cel_MAGENTA.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - cel_MAGENTA.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - cel_MAGENTA.common().flags().IS_EXTERNAL(false); // Doesn't apply - cel_MAGENTA.common().flags().IS_OPTIONAL(false); // Doesn't apply - cel_MAGENTA.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cel_MAGENTA.common().flags().IS_KEY(false); // Doesn't apply - cel_MAGENTA.common().flags().IS_DEFAULT(false); - cel_MAGENTA.common().value(value++); - cel_MAGENTA.detail().name("MAGENTA"); - - type_object->complete().enumerated_type().literal_seq().emplace_back(cel_MAGENTA); - - - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().enumerated_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("Color", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("Color", true); -} - -const TypeIdentifier* GetMaterialIdentifier(bool complete) -{ - const TypeIdentifier* c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("Material", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetMaterialObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("Material", complete); -} - -const TypeObject* GetMaterialObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("Material", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteMaterialObject(); - } - // else - return GetMinimalMaterialObject(); -} - -const TypeObject* GetMinimalMaterialObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("Material", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_ENUM); - - // No flags apply - //type_object->minimal().enumerated_type().enum_flags().IS_FINAL(false); - //type_object->minimal().enumerated_type().enum_flags().IS_APPENDABLE(false); - //type_object->minimal().enumerated_type().enum_flags().IS_MUTABLE(false); - //type_object->minimal().enumerated_type().enum_flags().IS_NESTED(false); - //type_object->minimal().enumerated_type().enum_flags().IS_AUTOID_HASH(false); - - type_object->minimal().enumerated_type().header().common().bit_bound(32); // TODO fixed by IDL, isn't? - - uint32_t value = 0; - MinimalEnumeratedLiteral mel_WOOD; - mel_WOOD.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - mel_WOOD.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - mel_WOOD.common().flags().IS_EXTERNAL(false); // Doesn't apply - mel_WOOD.common().flags().IS_OPTIONAL(false); // Doesn't apply - mel_WOOD.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mel_WOOD.common().flags().IS_KEY(false); // Doesn't apply - mel_WOOD.common().flags().IS_DEFAULT(false); - mel_WOOD.common().value(value++); - MD5 WOOD_hash("WOOD"); - for(int i = 0; i < 4; ++i) - { - mel_WOOD.detail().name_hash()[i] = WOOD_hash.digest[i]; - } - type_object->minimal().enumerated_type().literal_seq().emplace_back(mel_WOOD); - - MinimalEnumeratedLiteral mel_PLASTIC; - mel_PLASTIC.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - mel_PLASTIC.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - mel_PLASTIC.common().flags().IS_EXTERNAL(false); // Doesn't apply - mel_PLASTIC.common().flags().IS_OPTIONAL(false); // Doesn't apply - mel_PLASTIC.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mel_PLASTIC.common().flags().IS_KEY(false); // Doesn't apply - mel_PLASTIC.common().flags().IS_DEFAULT(false); - mel_PLASTIC.common().value(value++); - MD5 PLASTIC_hash("PLASTIC"); - for(int i = 0; i < 4; ++i) - { - mel_PLASTIC.detail().name_hash()[i] = PLASTIC_hash.digest[i]; - } - type_object->minimal().enumerated_type().literal_seq().emplace_back(mel_PLASTIC); - - MinimalEnumeratedLiteral mel_METAL; - mel_METAL.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - mel_METAL.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - mel_METAL.common().flags().IS_EXTERNAL(false); // Doesn't apply - mel_METAL.common().flags().IS_OPTIONAL(false); // Doesn't apply - mel_METAL.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mel_METAL.common().flags().IS_KEY(false); // Doesn't apply - mel_METAL.common().flags().IS_DEFAULT(false); - mel_METAL.common().value(value++); - MD5 METAL_hash("METAL"); - for(int i = 0; i < 4; ++i) - { - mel_METAL.detail().name_hash()[i] = METAL_hash.digest[i]; - } - type_object->minimal().enumerated_type().literal_seq().emplace_back(mel_METAL); - - MinimalEnumeratedLiteral mel_CONCRETE; - mel_CONCRETE.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - mel_CONCRETE.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - mel_CONCRETE.common().flags().IS_EXTERNAL(false); // Doesn't apply - mel_CONCRETE.common().flags().IS_OPTIONAL(false); // Doesn't apply - mel_CONCRETE.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mel_CONCRETE.common().flags().IS_KEY(false); // Doesn't apply - mel_CONCRETE.common().flags().IS_DEFAULT(false); - mel_CONCRETE.common().value(value++); - MD5 CONCRETE_hash("CONCRETE"); - for(int i = 0; i < 4; ++i) - { - mel_CONCRETE.detail().name_hash()[i] = CONCRETE_hash.digest[i]; - } - type_object->minimal().enumerated_type().literal_seq().emplace_back(mel_CONCRETE); - - MinimalEnumeratedLiteral mel_STONE; - mel_STONE.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - mel_STONE.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - mel_STONE.common().flags().IS_EXTERNAL(false); // Doesn't apply - mel_STONE.common().flags().IS_OPTIONAL(false); // Doesn't apply - mel_STONE.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mel_STONE.common().flags().IS_KEY(false); // Doesn't apply - mel_STONE.common().flags().IS_DEFAULT(false); - mel_STONE.common().value(value++); - MD5 STONE_hash("STONE"); - for(int i = 0; i < 4; ++i) - { - mel_STONE.detail().name_hash()[i] = STONE_hash.digest[i]; - } - type_object->minimal().enumerated_type().literal_seq().emplace_back(mel_STONE); - - - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().enumerated_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("Material", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("Material", false); -} - -const TypeObject* GetCompleteMaterialObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("Material", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_ENUM); - - // No flags apply - //type_object->complete().enumerated_type().enum_flags().IS_FINAL(false); - //type_object->complete().enumerated_type().enum_flags().IS_APPENDABLE(false); - //type_object->complete().enumerated_type().enum_flags().IS_MUTABLE(false); - //type_object->complete().enumerated_type().enum_flags().IS_NESTED(false); - //type_object->complete().enumerated_type().enum_flags().IS_AUTOID_HASH(false); - - type_object->complete().enumerated_type().header().common().bit_bound(32); // TODO fixed by IDL, isn't? - type_object->complete().enumerated_type().header().detail().type_name("Material"); - - uint32_t value = 0; - CompleteEnumeratedLiteral cel_WOOD; - cel_WOOD.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - cel_WOOD.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - cel_WOOD.common().flags().IS_EXTERNAL(false); // Doesn't apply - cel_WOOD.common().flags().IS_OPTIONAL(false); // Doesn't apply - cel_WOOD.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cel_WOOD.common().flags().IS_KEY(false); // Doesn't apply - cel_WOOD.common().flags().IS_DEFAULT(false); - cel_WOOD.common().value(value++); - cel_WOOD.detail().name("WOOD"); - - type_object->complete().enumerated_type().literal_seq().emplace_back(cel_WOOD); - - CompleteEnumeratedLiteral cel_PLASTIC; - cel_PLASTIC.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - cel_PLASTIC.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - cel_PLASTIC.common().flags().IS_EXTERNAL(false); // Doesn't apply - cel_PLASTIC.common().flags().IS_OPTIONAL(false); // Doesn't apply - cel_PLASTIC.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cel_PLASTIC.common().flags().IS_KEY(false); // Doesn't apply - cel_PLASTIC.common().flags().IS_DEFAULT(false); - cel_PLASTIC.common().value(value++); - cel_PLASTIC.detail().name("PLASTIC"); - - type_object->complete().enumerated_type().literal_seq().emplace_back(cel_PLASTIC); - - CompleteEnumeratedLiteral cel_METAL; - cel_METAL.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - cel_METAL.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - cel_METAL.common().flags().IS_EXTERNAL(false); // Doesn't apply - cel_METAL.common().flags().IS_OPTIONAL(false); // Doesn't apply - cel_METAL.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cel_METAL.common().flags().IS_KEY(false); // Doesn't apply - cel_METAL.common().flags().IS_DEFAULT(false); - cel_METAL.common().value(value++); - cel_METAL.detail().name("METAL"); - - type_object->complete().enumerated_type().literal_seq().emplace_back(cel_METAL); - - CompleteEnumeratedLiteral cel_CONCRETE; - cel_CONCRETE.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - cel_CONCRETE.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - cel_CONCRETE.common().flags().IS_EXTERNAL(false); // Doesn't apply - cel_CONCRETE.common().flags().IS_OPTIONAL(false); // Doesn't apply - cel_CONCRETE.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cel_CONCRETE.common().flags().IS_KEY(false); // Doesn't apply - cel_CONCRETE.common().flags().IS_DEFAULT(false); - cel_CONCRETE.common().value(value++); - cel_CONCRETE.detail().name("CONCRETE"); - - type_object->complete().enumerated_type().literal_seq().emplace_back(cel_CONCRETE); - - CompleteEnumeratedLiteral cel_STONE; - cel_STONE.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - cel_STONE.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - cel_STONE.common().flags().IS_EXTERNAL(false); // Doesn't apply - cel_STONE.common().flags().IS_OPTIONAL(false); // Doesn't apply - cel_STONE.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cel_STONE.common().flags().IS_KEY(false); // Doesn't apply - cel_STONE.common().flags().IS_DEFAULT(false); - cel_STONE.common().value(value++); - cel_STONE.detail().name("STONE"); - - type_object->complete().enumerated_type().literal_seq().emplace_back(cel_STONE); - - - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().enumerated_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("Material", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("Material", true); -} - - - -const TypeIdentifier* GetStructTypeIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("StructType", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetStructTypeObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("StructType", complete); -} - -const TypeObject* GetStructTypeObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("StructType", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteStructTypeObject(); - } - //else - return GetMinimalStructTypeObject(); -} - -const TypeObject* GetMinimalStructTypeObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("StructType", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_char_field; - mst_char_field.common().member_id(memberId++); - mst_char_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_char_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_char_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_char_field.common().member_flags().IS_OPTIONAL(false); - mst_char_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_char_field.common().member_flags().IS_KEY(false); - mst_char_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_char_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("char", false)); - - - MD5 char_field_hash("char_field"); - for(int i = 0; i < 4; ++i) - { - mst_char_field.detail().name_hash()[i] = char_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_char_field); - - MinimalStructMember mst_uint8_field; - mst_uint8_field.common().member_id(memberId++); - mst_uint8_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_uint8_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_uint8_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_uint8_field.common().member_flags().IS_OPTIONAL(false); - mst_uint8_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_uint8_field.common().member_flags().IS_KEY(false); - mst_uint8_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_uint8_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint8_t", false)); - - - MD5 uint8_field_hash("uint8_field"); - for(int i = 0; i < 4; ++i) - { - mst_uint8_field.detail().name_hash()[i] = uint8_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_uint8_field); - - MinimalStructMember mst_int16_field; - mst_int16_field.common().member_id(memberId++); - mst_int16_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_int16_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_int16_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_int16_field.common().member_flags().IS_OPTIONAL(false); - mst_int16_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_int16_field.common().member_flags().IS_KEY(false); - mst_int16_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_int16_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int16_t", false)); - - - MD5 int16_field_hash("int16_field"); - for(int i = 0; i < 4; ++i) - { - mst_int16_field.detail().name_hash()[i] = int16_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_int16_field); - - MinimalStructMember mst_uint16_field; - mst_uint16_field.common().member_id(memberId++); - mst_uint16_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_uint16_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_uint16_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_uint16_field.common().member_flags().IS_OPTIONAL(false); - mst_uint16_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_uint16_field.common().member_flags().IS_KEY(false); - mst_uint16_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_uint16_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint16_t", false)); - - - MD5 uint16_field_hash("uint16_field"); - for(int i = 0; i < 4; ++i) - { - mst_uint16_field.detail().name_hash()[i] = uint16_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_uint16_field); - - MinimalStructMember mst_int32_field; - mst_int32_field.common().member_id(memberId++); - mst_int32_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_int32_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_int32_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_int32_field.common().member_flags().IS_OPTIONAL(false); - mst_int32_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_int32_field.common().member_flags().IS_KEY(false); - mst_int32_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_int32_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - MD5 int32_field_hash("int32_field"); - for(int i = 0; i < 4; ++i) - { - mst_int32_field.detail().name_hash()[i] = int32_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_int32_field); - - MinimalStructMember mst_uint32_field; - mst_uint32_field.common().member_id(memberId++); - mst_uint32_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_uint32_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_uint32_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_uint32_field.common().member_flags().IS_OPTIONAL(false); - mst_uint32_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_uint32_field.common().member_flags().IS_KEY(false); - mst_uint32_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_uint32_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint32_t", false)); - - - MD5 uint32_field_hash("uint32_field"); - for(int i = 0; i < 4; ++i) - { - mst_uint32_field.detail().name_hash()[i] = uint32_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_uint32_field); - - MinimalStructMember mst_int64_field; - mst_int64_field.common().member_id(memberId++); - mst_int64_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_int64_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_int64_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_int64_field.common().member_flags().IS_OPTIONAL(false); - mst_int64_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_int64_field.common().member_flags().IS_KEY(false); - mst_int64_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_int64_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int64_t", false)); - - - MD5 int64_field_hash("int64_field"); - for(int i = 0; i < 4; ++i) - { - mst_int64_field.detail().name_hash()[i] = int64_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_int64_field); - - MinimalStructMember mst_uint64_field; - mst_uint64_field.common().member_id(memberId++); - mst_uint64_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_uint64_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_uint64_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_uint64_field.common().member_flags().IS_OPTIONAL(false); - mst_uint64_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_uint64_field.common().member_flags().IS_KEY(false); - mst_uint64_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_uint64_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint64_t", false)); - - - MD5 uint64_field_hash("uint64_field"); - for(int i = 0; i < 4; ++i) - { - mst_uint64_field.detail().name_hash()[i] = uint64_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_uint64_field); - - MinimalStructMember mst_float_field; - mst_float_field.common().member_id(memberId++); - mst_float_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_float_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_float_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_float_field.common().member_flags().IS_OPTIONAL(false); - mst_float_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_float_field.common().member_flags().IS_KEY(false); - mst_float_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_float_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("float", false)); - - - MD5 float_field_hash("float_field"); - for(int i = 0; i < 4; ++i) - { - mst_float_field.detail().name_hash()[i] = float_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_float_field); - - MinimalStructMember mst_double_field; - mst_double_field.common().member_id(memberId++); - mst_double_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_double_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_double_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_double_field.common().member_flags().IS_OPTIONAL(false); - mst_double_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_double_field.common().member_flags().IS_KEY(false); - mst_double_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_double_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("double", false)); - - - MD5 double_field_hash("double_field"); - for(int i = 0; i < 4; ++i) - { - mst_double_field.detail().name_hash()[i] = double_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_double_field); - - MinimalStructMember mst_long_double_field; - mst_long_double_field.common().member_id(memberId++); - mst_long_double_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_long_double_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_long_double_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_long_double_field.common().member_flags().IS_OPTIONAL(false); - mst_long_double_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_long_double_field.common().member_flags().IS_KEY(false); - mst_long_double_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_long_double_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("longdouble", false)); - - - MD5 long_double_field_hash("long_double_field"); - for(int i = 0; i < 4; ++i) - { - mst_long_double_field.detail().name_hash()[i] = long_double_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_long_double_field); - - MinimalStructMember mst_bool_field; - mst_bool_field.common().member_id(memberId++); - mst_bool_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_bool_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_bool_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_bool_field.common().member_flags().IS_OPTIONAL(false); - mst_bool_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_bool_field.common().member_flags().IS_KEY(false); - mst_bool_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_bool_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("bool", false)); - - - MD5 bool_field_hash("bool_field"); - for(int i = 0; i < 4; ++i) - { - mst_bool_field.detail().name_hash()[i] = bool_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_bool_field); - - MinimalStructMember mst_string_field; - mst_string_field.common().member_id(memberId++); - mst_string_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_string_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_string_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_string_field.common().member_flags().IS_OPTIONAL(false); - mst_string_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_string_field.common().member_flags().IS_KEY(false); - mst_string_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_string_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, false)); - - MD5 string_field_hash("string_field"); - for(int i = 0; i < 4; ++i) - { - mst_string_field.detail().name_hash()[i] = string_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_string_field); - - MinimalStructMember mst_enum_field; - mst_enum_field.common().member_id(memberId++); - mst_enum_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_enum_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_enum_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_enum_field.common().member_flags().IS_OPTIONAL(false); - mst_enum_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_enum_field.common().member_flags().IS_KEY(false); - mst_enum_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_enum_field.common().member_type_id(*GetColorIdentifier(false)); - - MD5 enum_field_hash("enum_field"); - for(int i = 0; i < 4; ++i) - { - mst_enum_field.detail().name_hash()[i] = enum_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_enum_field); - - MinimalStructMember mst_enum2_field; - mst_enum2_field.common().member_id(memberId++); - mst_enum2_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_enum2_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_enum2_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_enum2_field.common().member_flags().IS_OPTIONAL(false); - mst_enum2_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_enum2_field.common().member_flags().IS_KEY(false); - mst_enum2_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_enum2_field.common().member_type_id(*GetMaterialIdentifier(false)); - - MD5 enum2_field_hash("enum2_field"); - for(int i = 0; i < 4; ++i) - { - mst_enum2_field.detail().name_hash()[i] = enum2_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_enum2_field); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("StructType", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("StructType", false); -} - -const TypeObject* GetCompleteStructTypeObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("StructType", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_char_field; - cst_char_field.common().member_id(memberId++); - cst_char_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_char_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_char_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_char_field.common().member_flags().IS_OPTIONAL(false); - cst_char_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_char_field.common().member_flags().IS_KEY(false); - cst_char_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_char_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("char", false)); - - - cst_char_field.detail().name("char_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_char_field); - - CompleteStructMember cst_uint8_field; - cst_uint8_field.common().member_id(memberId++); - cst_uint8_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_uint8_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_uint8_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_uint8_field.common().member_flags().IS_OPTIONAL(false); - cst_uint8_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_uint8_field.common().member_flags().IS_KEY(false); - cst_uint8_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_uint8_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint8_t", false)); - - - cst_uint8_field.detail().name("uint8_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_uint8_field); - - CompleteStructMember cst_int16_field; - cst_int16_field.common().member_id(memberId++); - cst_int16_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_int16_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_int16_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_int16_field.common().member_flags().IS_OPTIONAL(false); - cst_int16_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_int16_field.common().member_flags().IS_KEY(false); - cst_int16_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_int16_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int16_t", false)); - - - cst_int16_field.detail().name("int16_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_int16_field); - - CompleteStructMember cst_uint16_field; - cst_uint16_field.common().member_id(memberId++); - cst_uint16_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_uint16_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_uint16_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_uint16_field.common().member_flags().IS_OPTIONAL(false); - cst_uint16_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_uint16_field.common().member_flags().IS_KEY(false); - cst_uint16_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_uint16_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint16_t", false)); - - - cst_uint16_field.detail().name("uint16_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_uint16_field); - - CompleteStructMember cst_int32_field; - cst_int32_field.common().member_id(memberId++); - cst_int32_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_int32_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_int32_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_int32_field.common().member_flags().IS_OPTIONAL(false); - cst_int32_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_int32_field.common().member_flags().IS_KEY(false); - cst_int32_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_int32_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - cst_int32_field.detail().name("int32_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_int32_field); - - CompleteStructMember cst_uint32_field; - cst_uint32_field.common().member_id(memberId++); - cst_uint32_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_uint32_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_uint32_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_uint32_field.common().member_flags().IS_OPTIONAL(false); - cst_uint32_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_uint32_field.common().member_flags().IS_KEY(false); - cst_uint32_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_uint32_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint32_t", false)); - - - cst_uint32_field.detail().name("uint32_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_uint32_field); - - CompleteStructMember cst_int64_field; - cst_int64_field.common().member_id(memberId++); - cst_int64_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_int64_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_int64_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_int64_field.common().member_flags().IS_OPTIONAL(false); - cst_int64_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_int64_field.common().member_flags().IS_KEY(false); - cst_int64_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_int64_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int64_t", false)); - - - cst_int64_field.detail().name("int64_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_int64_field); - - CompleteStructMember cst_uint64_field; - cst_uint64_field.common().member_id(memberId++); - cst_uint64_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_uint64_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_uint64_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_uint64_field.common().member_flags().IS_OPTIONAL(false); - cst_uint64_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_uint64_field.common().member_flags().IS_KEY(false); - cst_uint64_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_uint64_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint64_t", false)); - - - cst_uint64_field.detail().name("uint64_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_uint64_field); - - CompleteStructMember cst_float_field; - cst_float_field.common().member_id(memberId++); - cst_float_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_float_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_float_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_float_field.common().member_flags().IS_OPTIONAL(false); - cst_float_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_float_field.common().member_flags().IS_KEY(false); - cst_float_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_float_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("float", false)); - - - cst_float_field.detail().name("float_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_float_field); - - CompleteStructMember cst_double_field; - cst_double_field.common().member_id(memberId++); - cst_double_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_double_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_double_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_double_field.common().member_flags().IS_OPTIONAL(false); - cst_double_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_double_field.common().member_flags().IS_KEY(false); - cst_double_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_double_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("double", false)); - - - cst_double_field.detail().name("double_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_double_field); - - CompleteStructMember cst_long_double_field; - cst_long_double_field.common().member_id(memberId++); - cst_long_double_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_long_double_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_long_double_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_long_double_field.common().member_flags().IS_OPTIONAL(false); - cst_long_double_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_long_double_field.common().member_flags().IS_KEY(false); - cst_long_double_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_long_double_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("longdouble", false)); - - - cst_long_double_field.detail().name("long_double_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_long_double_field); - - CompleteStructMember cst_bool_field; - cst_bool_field.common().member_id(memberId++); - cst_bool_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_bool_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_bool_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_bool_field.common().member_flags().IS_OPTIONAL(false); - cst_bool_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_bool_field.common().member_flags().IS_KEY(false); - cst_bool_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_bool_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("bool", false)); - - - cst_bool_field.detail().name("bool_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_bool_field); - - CompleteStructMember cst_string_field; - cst_string_field.common().member_id(memberId++); - cst_string_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_string_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_string_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_string_field.common().member_flags().IS_OPTIONAL(false); - cst_string_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_string_field.common().member_flags().IS_KEY(false); - cst_string_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_string_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, false)); - - cst_string_field.detail().name("string_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_string_field); - - CompleteStructMember cst_enum_field; - cst_enum_field.common().member_id(memberId++); - cst_enum_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_enum_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_enum_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_enum_field.common().member_flags().IS_OPTIONAL(false); - cst_enum_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_enum_field.common().member_flags().IS_KEY(false); - cst_enum_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_enum_field.common().member_type_id(*GetColorIdentifier(true)); - - cst_enum_field.detail().name("enum_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_enum_field); - - CompleteStructMember cst_enum2_field; - cst_enum2_field.common().member_id(memberId++); - cst_enum2_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_enum2_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_enum2_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_enum2_field.common().member_flags().IS_OPTIONAL(false); - cst_enum2_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_enum2_field.common().member_flags().IS_KEY(false); - cst_enum2_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_enum2_field.common().member_type_id(*GetMaterialIdentifier(true)); - - cst_enum2_field.detail().name("enum2_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_enum2_field); - - - // Header - type_object->complete().struct_type().header().detail().type_name("StructType"); - // TODO inheritance - { - AppliedAnnotation ann; - //ann.annotation_typeid(GetnestedIdentifier(true)); - ann.annotation_typeid(*TypeObjectFactory::get_instance()->get_type_identifier_trying_complete("nested")); - { - AppliedAnnotationParameter annParam; - MD5 message_hash("value"); - for(int i = 0; i < 4; ++i) - { - annParam.paramname_hash()[i] = message_hash.digest[i]; - } - AnnotationParameterValue paramValue; - paramValue._d(TK_BOOLEAN); - paramValue.from_string("true"); - annParam.value(paramValue); - ann.param_seq().push_back(annParam); - } - - type_object->complete().struct_type().header().detail().ann_custom().push_back(ann); - } - - - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("StructType", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("StructType", true); -} - - - - - - - - - -const TypeIdentifier* GetContentFilterTestTypeIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("ContentFilterTestType", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetContentFilterTestTypeObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("ContentFilterTestType", complete); -} - -const TypeObject* GetContentFilterTestTypeObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ContentFilterTestType", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteContentFilterTestTypeObject(); - } - //else - return GetMinimalContentFilterTestTypeObject(); -} - -const TypeObject* GetMinimalContentFilterTestTypeObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ContentFilterTestType", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_char_field; - mst_char_field.common().member_id(memberId++); - mst_char_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_char_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_char_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_char_field.common().member_flags().IS_OPTIONAL(false); - mst_char_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_char_field.common().member_flags().IS_KEY(false); - mst_char_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_char_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("char", false)); - - - MD5 char_field_hash("char_field"); - for(int i = 0; i < 4; ++i) - { - mst_char_field.detail().name_hash()[i] = char_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_char_field); - - MinimalStructMember mst_uint8_field; - mst_uint8_field.common().member_id(memberId++); - mst_uint8_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_uint8_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_uint8_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_uint8_field.common().member_flags().IS_OPTIONAL(false); - mst_uint8_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_uint8_field.common().member_flags().IS_KEY(false); - mst_uint8_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_uint8_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint8_t", false)); - - - MD5 uint8_field_hash("uint8_field"); - for(int i = 0; i < 4; ++i) - { - mst_uint8_field.detail().name_hash()[i] = uint8_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_uint8_field); - - MinimalStructMember mst_int16_field; - mst_int16_field.common().member_id(memberId++); - mst_int16_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_int16_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_int16_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_int16_field.common().member_flags().IS_OPTIONAL(false); - mst_int16_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_int16_field.common().member_flags().IS_KEY(false); - mst_int16_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_int16_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int16_t", false)); - - - MD5 int16_field_hash("int16_field"); - for(int i = 0; i < 4; ++i) - { - mst_int16_field.detail().name_hash()[i] = int16_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_int16_field); - - MinimalStructMember mst_uint16_field; - mst_uint16_field.common().member_id(memberId++); - mst_uint16_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_uint16_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_uint16_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_uint16_field.common().member_flags().IS_OPTIONAL(false); - mst_uint16_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_uint16_field.common().member_flags().IS_KEY(false); - mst_uint16_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_uint16_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint16_t", false)); - - - MD5 uint16_field_hash("uint16_field"); - for(int i = 0; i < 4; ++i) - { - mst_uint16_field.detail().name_hash()[i] = uint16_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_uint16_field); - - MinimalStructMember mst_int32_field; - mst_int32_field.common().member_id(memberId++); - mst_int32_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_int32_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_int32_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_int32_field.common().member_flags().IS_OPTIONAL(false); - mst_int32_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_int32_field.common().member_flags().IS_KEY(false); - mst_int32_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_int32_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - MD5 int32_field_hash("int32_field"); - for(int i = 0; i < 4; ++i) - { - mst_int32_field.detail().name_hash()[i] = int32_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_int32_field); - - MinimalStructMember mst_uint32_field; - mst_uint32_field.common().member_id(memberId++); - mst_uint32_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_uint32_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_uint32_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_uint32_field.common().member_flags().IS_OPTIONAL(false); - mst_uint32_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_uint32_field.common().member_flags().IS_KEY(false); - mst_uint32_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_uint32_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint32_t", false)); - - - MD5 uint32_field_hash("uint32_field"); - for(int i = 0; i < 4; ++i) - { - mst_uint32_field.detail().name_hash()[i] = uint32_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_uint32_field); - - MinimalStructMember mst_int64_field; - mst_int64_field.common().member_id(memberId++); - mst_int64_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_int64_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_int64_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_int64_field.common().member_flags().IS_OPTIONAL(false); - mst_int64_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_int64_field.common().member_flags().IS_KEY(false); - mst_int64_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_int64_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int64_t", false)); - - - MD5 int64_field_hash("int64_field"); - for(int i = 0; i < 4; ++i) - { - mst_int64_field.detail().name_hash()[i] = int64_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_int64_field); - - MinimalStructMember mst_uint64_field; - mst_uint64_field.common().member_id(memberId++); - mst_uint64_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_uint64_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_uint64_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_uint64_field.common().member_flags().IS_OPTIONAL(false); - mst_uint64_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_uint64_field.common().member_flags().IS_KEY(false); - mst_uint64_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_uint64_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint64_t", false)); - - - MD5 uint64_field_hash("uint64_field"); - for(int i = 0; i < 4; ++i) - { - mst_uint64_field.detail().name_hash()[i] = uint64_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_uint64_field); - - MinimalStructMember mst_float_field; - mst_float_field.common().member_id(memberId++); - mst_float_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_float_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_float_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_float_field.common().member_flags().IS_OPTIONAL(false); - mst_float_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_float_field.common().member_flags().IS_KEY(false); - mst_float_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_float_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("float", false)); - - - MD5 float_field_hash("float_field"); - for(int i = 0; i < 4; ++i) - { - mst_float_field.detail().name_hash()[i] = float_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_float_field); - - MinimalStructMember mst_double_field; - mst_double_field.common().member_id(memberId++); - mst_double_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_double_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_double_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_double_field.common().member_flags().IS_OPTIONAL(false); - mst_double_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_double_field.common().member_flags().IS_KEY(false); - mst_double_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_double_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("double", false)); - - - MD5 double_field_hash("double_field"); - for(int i = 0; i < 4; ++i) - { - mst_double_field.detail().name_hash()[i] = double_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_double_field); - - MinimalStructMember mst_long_double_field; - mst_long_double_field.common().member_id(memberId++); - mst_long_double_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_long_double_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_long_double_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_long_double_field.common().member_flags().IS_OPTIONAL(false); - mst_long_double_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_long_double_field.common().member_flags().IS_KEY(false); - mst_long_double_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_long_double_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("longdouble", false)); - - - MD5 long_double_field_hash("long_double_field"); - for(int i = 0; i < 4; ++i) - { - mst_long_double_field.detail().name_hash()[i] = long_double_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_long_double_field); - - MinimalStructMember mst_bool_field; - mst_bool_field.common().member_id(memberId++); - mst_bool_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_bool_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_bool_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_bool_field.common().member_flags().IS_OPTIONAL(false); - mst_bool_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_bool_field.common().member_flags().IS_KEY(false); - mst_bool_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_bool_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("bool", false)); - - - MD5 bool_field_hash("bool_field"); - for(int i = 0; i < 4; ++i) - { - mst_bool_field.detail().name_hash()[i] = bool_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_bool_field); - - MinimalStructMember mst_string_field; - mst_string_field.common().member_id(memberId++); - mst_string_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_string_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_string_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_string_field.common().member_flags().IS_OPTIONAL(false); - mst_string_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_string_field.common().member_flags().IS_KEY(false); - mst_string_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_string_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, false)); - - MD5 string_field_hash("string_field"); - for(int i = 0; i < 4; ++i) - { - mst_string_field.detail().name_hash()[i] = string_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_string_field); - - MinimalStructMember mst_enum_field; - mst_enum_field.common().member_id(memberId++); - mst_enum_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_enum_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_enum_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_enum_field.common().member_flags().IS_OPTIONAL(false); - mst_enum_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_enum_field.common().member_flags().IS_KEY(false); - mst_enum_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_enum_field.common().member_type_id(*GetColorIdentifier(false)); - - MD5 enum_field_hash("enum_field"); - for(int i = 0; i < 4; ++i) - { - mst_enum_field.detail().name_hash()[i] = enum_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_enum_field); - - MinimalStructMember mst_enum2_field; - mst_enum2_field.common().member_id(memberId++); - mst_enum2_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_enum2_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_enum2_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_enum2_field.common().member_flags().IS_OPTIONAL(false); - mst_enum2_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_enum2_field.common().member_flags().IS_KEY(false); - mst_enum2_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_enum2_field.common().member_type_id(*GetMaterialIdentifier(false)); - - MD5 enum2_field_hash("enum2_field"); - for(int i = 0; i < 4; ++i) - { - mst_enum2_field.detail().name_hash()[i] = enum2_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_enum2_field); - - MinimalStructMember mst_struct_field; - mst_struct_field.common().member_id(memberId++); - mst_struct_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_struct_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_struct_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_struct_field.common().member_flags().IS_OPTIONAL(false); - mst_struct_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_struct_field.common().member_flags().IS_KEY(false); - mst_struct_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_struct_field.common().member_type_id(*GetStructTypeIdentifier(false)); - - MD5 struct_field_hash("struct_field"); - for(int i = 0; i < 4; ++i) - { - mst_struct_field.detail().name_hash()[i] = struct_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_struct_field); - - MinimalStructMember mst_array_char_field; - mst_array_char_field.common().member_id(memberId++); - mst_array_char_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_array_char_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_array_char_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_array_char_field.common().member_flags().IS_OPTIONAL(false); - mst_array_char_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_array_char_field.common().member_flags().IS_KEY(false); - mst_array_char_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_array_char_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("char", {max_array_size}, false)); - - MD5 array_char_field_hash("array_char_field"); - for(int i = 0; i < 4; ++i) - { - mst_array_char_field.detail().name_hash()[i] = array_char_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_array_char_field); - - MinimalStructMember mst_array_uint8_field; - mst_array_uint8_field.common().member_id(memberId++); - mst_array_uint8_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_array_uint8_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_array_uint8_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_array_uint8_field.common().member_flags().IS_OPTIONAL(false); - mst_array_uint8_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_array_uint8_field.common().member_flags().IS_KEY(false); - mst_array_uint8_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_array_uint8_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("uint8_t", {max_array_size}, false)); - - MD5 array_uint8_field_hash("array_uint8_field"); - for(int i = 0; i < 4; ++i) - { - mst_array_uint8_field.detail().name_hash()[i] = array_uint8_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_array_uint8_field); - - MinimalStructMember mst_array_int16_field; - mst_array_int16_field.common().member_id(memberId++); - mst_array_int16_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_array_int16_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_array_int16_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_array_int16_field.common().member_flags().IS_OPTIONAL(false); - mst_array_int16_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_array_int16_field.common().member_flags().IS_KEY(false); - mst_array_int16_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_array_int16_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("int16_t", {max_array_size}, false)); - - MD5 array_int16_field_hash("array_int16_field"); - for(int i = 0; i < 4; ++i) - { - mst_array_int16_field.detail().name_hash()[i] = array_int16_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_array_int16_field); - - MinimalStructMember mst_array_uint16_field; - mst_array_uint16_field.common().member_id(memberId++); - mst_array_uint16_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_array_uint16_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_array_uint16_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_array_uint16_field.common().member_flags().IS_OPTIONAL(false); - mst_array_uint16_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_array_uint16_field.common().member_flags().IS_KEY(false); - mst_array_uint16_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_array_uint16_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("uint16_t", {max_array_size}, false)); - - MD5 array_uint16_field_hash("array_uint16_field"); - for(int i = 0; i < 4; ++i) - { - mst_array_uint16_field.detail().name_hash()[i] = array_uint16_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_array_uint16_field); - - MinimalStructMember mst_array_int32_field; - mst_array_int32_field.common().member_id(memberId++); - mst_array_int32_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_array_int32_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_array_int32_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_array_int32_field.common().member_flags().IS_OPTIONAL(false); - mst_array_int32_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_array_int32_field.common().member_flags().IS_KEY(false); - mst_array_int32_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_array_int32_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("int32_t", {max_array_size}, false)); - - MD5 array_int32_field_hash("array_int32_field"); - for(int i = 0; i < 4; ++i) - { - mst_array_int32_field.detail().name_hash()[i] = array_int32_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_array_int32_field); - - MinimalStructMember mst_array_uint32_field; - mst_array_uint32_field.common().member_id(memberId++); - mst_array_uint32_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_array_uint32_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_array_uint32_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_array_uint32_field.common().member_flags().IS_OPTIONAL(false); - mst_array_uint32_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_array_uint32_field.common().member_flags().IS_KEY(false); - mst_array_uint32_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_array_uint32_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("uint32_t", {max_array_size}, false)); - - MD5 array_uint32_field_hash("array_uint32_field"); - for(int i = 0; i < 4; ++i) - { - mst_array_uint32_field.detail().name_hash()[i] = array_uint32_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_array_uint32_field); - - MinimalStructMember mst_array_int64_field; - mst_array_int64_field.common().member_id(memberId++); - mst_array_int64_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_array_int64_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_array_int64_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_array_int64_field.common().member_flags().IS_OPTIONAL(false); - mst_array_int64_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_array_int64_field.common().member_flags().IS_KEY(false); - mst_array_int64_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_array_int64_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("int64_t", {max_array_size}, false)); - - MD5 array_int64_field_hash("array_int64_field"); - for(int i = 0; i < 4; ++i) - { - mst_array_int64_field.detail().name_hash()[i] = array_int64_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_array_int64_field); - - MinimalStructMember mst_array_uint64_field; - mst_array_uint64_field.common().member_id(memberId++); - mst_array_uint64_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_array_uint64_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_array_uint64_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_array_uint64_field.common().member_flags().IS_OPTIONAL(false); - mst_array_uint64_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_array_uint64_field.common().member_flags().IS_KEY(false); - mst_array_uint64_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_array_uint64_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("uint64_t", {max_array_size}, false)); - - MD5 array_uint64_field_hash("array_uint64_field"); - for(int i = 0; i < 4; ++i) - { - mst_array_uint64_field.detail().name_hash()[i] = array_uint64_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_array_uint64_field); - - MinimalStructMember mst_array_float_field; - mst_array_float_field.common().member_id(memberId++); - mst_array_float_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_array_float_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_array_float_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_array_float_field.common().member_flags().IS_OPTIONAL(false); - mst_array_float_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_array_float_field.common().member_flags().IS_KEY(false); - mst_array_float_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_array_float_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("float", {max_array_size}, false)); - - MD5 array_float_field_hash("array_float_field"); - for(int i = 0; i < 4; ++i) - { - mst_array_float_field.detail().name_hash()[i] = array_float_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_array_float_field); - - MinimalStructMember mst_array_double_field; - mst_array_double_field.common().member_id(memberId++); - mst_array_double_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_array_double_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_array_double_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_array_double_field.common().member_flags().IS_OPTIONAL(false); - mst_array_double_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_array_double_field.common().member_flags().IS_KEY(false); - mst_array_double_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_array_double_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("double", {max_array_size}, false)); - - MD5 array_double_field_hash("array_double_field"); - for(int i = 0; i < 4; ++i) - { - mst_array_double_field.detail().name_hash()[i] = array_double_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_array_double_field); - - MinimalStructMember mst_array_long_double_field; - mst_array_long_double_field.common().member_id(memberId++); - mst_array_long_double_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_array_long_double_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_array_long_double_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_array_long_double_field.common().member_flags().IS_OPTIONAL(false); - mst_array_long_double_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_array_long_double_field.common().member_flags().IS_KEY(false); - mst_array_long_double_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_array_long_double_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("longdouble", {max_array_size}, false)); - - MD5 array_long_double_field_hash("array_long_double_field"); - for(int i = 0; i < 4; ++i) - { - mst_array_long_double_field.detail().name_hash()[i] = array_long_double_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_array_long_double_field); - - MinimalStructMember mst_array_bool_field; - mst_array_bool_field.common().member_id(memberId++); - mst_array_bool_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_array_bool_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_array_bool_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_array_bool_field.common().member_flags().IS_OPTIONAL(false); - mst_array_bool_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_array_bool_field.common().member_flags().IS_KEY(false); - mst_array_bool_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_array_bool_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("bool", {max_array_size}, false)); - - MD5 array_bool_field_hash("array_bool_field"); - for(int i = 0; i < 4; ++i) - { - mst_array_bool_field.detail().name_hash()[i] = array_bool_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_array_bool_field); - - MinimalStructMember mst_array_string_field; - mst_array_string_field.common().member_id(memberId++); - mst_array_string_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_array_string_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_array_string_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_array_string_field.common().member_flags().IS_OPTIONAL(false); - mst_array_string_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_array_string_field.common().member_flags().IS_KEY(false); - mst_array_string_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_array_string_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier(TypeNamesGenerator::get_string_type_name(255, false), {max_array_size}, false)); - - MD5 array_string_field_hash("array_string_field"); - for(int i = 0; i < 4; ++i) - { - mst_array_string_field.detail().name_hash()[i] = array_string_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_array_string_field); - - MinimalStructMember mst_array_enum_field; - mst_array_enum_field.common().member_id(memberId++); - mst_array_enum_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_array_enum_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_array_enum_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_array_enum_field.common().member_flags().IS_OPTIONAL(false); - mst_array_enum_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_array_enum_field.common().member_flags().IS_KEY(false); - mst_array_enum_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_array_enum_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("Color", {max_array_size}, false)); - - MD5 array_enum_field_hash("array_enum_field"); - for(int i = 0; i < 4; ++i) - { - mst_array_enum_field.detail().name_hash()[i] = array_enum_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_array_enum_field); - - MinimalStructMember mst_array_enum2_field; - mst_array_enum2_field.common().member_id(memberId++); - mst_array_enum2_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_array_enum2_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_array_enum2_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_array_enum2_field.common().member_flags().IS_OPTIONAL(false); - mst_array_enum2_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_array_enum2_field.common().member_flags().IS_KEY(false); - mst_array_enum2_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_array_enum2_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("Material", {max_array_size}, false)); - - MD5 array_enum2_field_hash("array_enum2_field"); - for(int i = 0; i < 4; ++i) - { - mst_array_enum2_field.detail().name_hash()[i] = array_enum2_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_array_enum2_field); - - MinimalStructMember mst_array_struct_field; - mst_array_struct_field.common().member_id(memberId++); - mst_array_struct_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_array_struct_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_array_struct_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_array_struct_field.common().member_flags().IS_OPTIONAL(false); - mst_array_struct_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_array_struct_field.common().member_flags().IS_KEY(false); - mst_array_struct_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_array_struct_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("StructType", {max_array_size}, false)); - - MD5 array_struct_field_hash("array_struct_field"); - for(int i = 0; i < 4; ++i) - { - mst_array_struct_field.detail().name_hash()[i] = array_struct_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_array_struct_field); - - MinimalStructMember mst_bounded_sequence_char_field; - mst_bounded_sequence_char_field.common().member_id(memberId++); - mst_bounded_sequence_char_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_bounded_sequence_char_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_bounded_sequence_char_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_bounded_sequence_char_field.common().member_flags().IS_OPTIONAL(false); - mst_bounded_sequence_char_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_bounded_sequence_char_field.common().member_flags().IS_KEY(false); - mst_bounded_sequence_char_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_bounded_sequence_char_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("char", max_seq_size, false)); - - MD5 bounded_sequence_char_field_hash("bounded_sequence_char_field"); - for(int i = 0; i < 4; ++i) - { - mst_bounded_sequence_char_field.detail().name_hash()[i] = bounded_sequence_char_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_bounded_sequence_char_field); - - MinimalStructMember mst_bounded_sequence_uint8_field; - mst_bounded_sequence_uint8_field.common().member_id(memberId++); - mst_bounded_sequence_uint8_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_bounded_sequence_uint8_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_bounded_sequence_uint8_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_bounded_sequence_uint8_field.common().member_flags().IS_OPTIONAL(false); - mst_bounded_sequence_uint8_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_bounded_sequence_uint8_field.common().member_flags().IS_KEY(false); - mst_bounded_sequence_uint8_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_bounded_sequence_uint8_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("uint8_t", max_seq_size, false)); - - MD5 bounded_sequence_uint8_field_hash("bounded_sequence_uint8_field"); - for(int i = 0; i < 4; ++i) - { - mst_bounded_sequence_uint8_field.detail().name_hash()[i] = bounded_sequence_uint8_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_bounded_sequence_uint8_field); - - MinimalStructMember mst_bounded_sequence_int16_field; - mst_bounded_sequence_int16_field.common().member_id(memberId++); - mst_bounded_sequence_int16_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_bounded_sequence_int16_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_bounded_sequence_int16_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_bounded_sequence_int16_field.common().member_flags().IS_OPTIONAL(false); - mst_bounded_sequence_int16_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_bounded_sequence_int16_field.common().member_flags().IS_KEY(false); - mst_bounded_sequence_int16_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_bounded_sequence_int16_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("int16_t", max_seq_size, false)); - - MD5 bounded_sequence_int16_field_hash("bounded_sequence_int16_field"); - for(int i = 0; i < 4; ++i) - { - mst_bounded_sequence_int16_field.detail().name_hash()[i] = bounded_sequence_int16_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_bounded_sequence_int16_field); - - MinimalStructMember mst_bounded_sequence_uint16_field; - mst_bounded_sequence_uint16_field.common().member_id(memberId++); - mst_bounded_sequence_uint16_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_bounded_sequence_uint16_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_bounded_sequence_uint16_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_bounded_sequence_uint16_field.common().member_flags().IS_OPTIONAL(false); - mst_bounded_sequence_uint16_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_bounded_sequence_uint16_field.common().member_flags().IS_KEY(false); - mst_bounded_sequence_uint16_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_bounded_sequence_uint16_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("uint16_t", max_seq_size, false)); - - MD5 bounded_sequence_uint16_field_hash("bounded_sequence_uint16_field"); - for(int i = 0; i < 4; ++i) - { - mst_bounded_sequence_uint16_field.detail().name_hash()[i] = bounded_sequence_uint16_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_bounded_sequence_uint16_field); - - MinimalStructMember mst_bounded_sequence_int32_field; - mst_bounded_sequence_int32_field.common().member_id(memberId++); - mst_bounded_sequence_int32_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_bounded_sequence_int32_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_bounded_sequence_int32_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_bounded_sequence_int32_field.common().member_flags().IS_OPTIONAL(false); - mst_bounded_sequence_int32_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_bounded_sequence_int32_field.common().member_flags().IS_KEY(false); - mst_bounded_sequence_int32_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_bounded_sequence_int32_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("int32_t", max_seq_size, false)); - - MD5 bounded_sequence_int32_field_hash("bounded_sequence_int32_field"); - for(int i = 0; i < 4; ++i) - { - mst_bounded_sequence_int32_field.detail().name_hash()[i] = bounded_sequence_int32_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_bounded_sequence_int32_field); - - MinimalStructMember mst_bounded_sequence_uint32_field; - mst_bounded_sequence_uint32_field.common().member_id(memberId++); - mst_bounded_sequence_uint32_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_bounded_sequence_uint32_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_bounded_sequence_uint32_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_bounded_sequence_uint32_field.common().member_flags().IS_OPTIONAL(false); - mst_bounded_sequence_uint32_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_bounded_sequence_uint32_field.common().member_flags().IS_KEY(false); - mst_bounded_sequence_uint32_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_bounded_sequence_uint32_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("uint32_t", max_seq_size, false)); - - MD5 bounded_sequence_uint32_field_hash("bounded_sequence_uint32_field"); - for(int i = 0; i < 4; ++i) - { - mst_bounded_sequence_uint32_field.detail().name_hash()[i] = bounded_sequence_uint32_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_bounded_sequence_uint32_field); - - MinimalStructMember mst_bounded_sequence_int64_field; - mst_bounded_sequence_int64_field.common().member_id(memberId++); - mst_bounded_sequence_int64_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_bounded_sequence_int64_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_bounded_sequence_int64_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_bounded_sequence_int64_field.common().member_flags().IS_OPTIONAL(false); - mst_bounded_sequence_int64_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_bounded_sequence_int64_field.common().member_flags().IS_KEY(false); - mst_bounded_sequence_int64_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_bounded_sequence_int64_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("int64_t", max_seq_size, false)); - - MD5 bounded_sequence_int64_field_hash("bounded_sequence_int64_field"); - for(int i = 0; i < 4; ++i) - { - mst_bounded_sequence_int64_field.detail().name_hash()[i] = bounded_sequence_int64_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_bounded_sequence_int64_field); - - MinimalStructMember mst_bounded_sequence_uint64_field; - mst_bounded_sequence_uint64_field.common().member_id(memberId++); - mst_bounded_sequence_uint64_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_bounded_sequence_uint64_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_bounded_sequence_uint64_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_bounded_sequence_uint64_field.common().member_flags().IS_OPTIONAL(false); - mst_bounded_sequence_uint64_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_bounded_sequence_uint64_field.common().member_flags().IS_KEY(false); - mst_bounded_sequence_uint64_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_bounded_sequence_uint64_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("uint64_t", max_seq_size, false)); - - MD5 bounded_sequence_uint64_field_hash("bounded_sequence_uint64_field"); - for(int i = 0; i < 4; ++i) - { - mst_bounded_sequence_uint64_field.detail().name_hash()[i] = bounded_sequence_uint64_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_bounded_sequence_uint64_field); - - MinimalStructMember mst_bounded_sequence_float_field; - mst_bounded_sequence_float_field.common().member_id(memberId++); - mst_bounded_sequence_float_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_bounded_sequence_float_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_bounded_sequence_float_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_bounded_sequence_float_field.common().member_flags().IS_OPTIONAL(false); - mst_bounded_sequence_float_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_bounded_sequence_float_field.common().member_flags().IS_KEY(false); - mst_bounded_sequence_float_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_bounded_sequence_float_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("float", max_seq_size, false)); - - MD5 bounded_sequence_float_field_hash("bounded_sequence_float_field"); - for(int i = 0; i < 4; ++i) - { - mst_bounded_sequence_float_field.detail().name_hash()[i] = bounded_sequence_float_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_bounded_sequence_float_field); - - MinimalStructMember mst_bounded_sequence_double_field; - mst_bounded_sequence_double_field.common().member_id(memberId++); - mst_bounded_sequence_double_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_bounded_sequence_double_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_bounded_sequence_double_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_bounded_sequence_double_field.common().member_flags().IS_OPTIONAL(false); - mst_bounded_sequence_double_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_bounded_sequence_double_field.common().member_flags().IS_KEY(false); - mst_bounded_sequence_double_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_bounded_sequence_double_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("double", max_seq_size, false)); - - MD5 bounded_sequence_double_field_hash("bounded_sequence_double_field"); - for(int i = 0; i < 4; ++i) - { - mst_bounded_sequence_double_field.detail().name_hash()[i] = bounded_sequence_double_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_bounded_sequence_double_field); - - MinimalStructMember mst_bounded_sequence_long_double_field; - mst_bounded_sequence_long_double_field.common().member_id(memberId++); - mst_bounded_sequence_long_double_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_bounded_sequence_long_double_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_bounded_sequence_long_double_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_bounded_sequence_long_double_field.common().member_flags().IS_OPTIONAL(false); - mst_bounded_sequence_long_double_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_bounded_sequence_long_double_field.common().member_flags().IS_KEY(false); - mst_bounded_sequence_long_double_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_bounded_sequence_long_double_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("longdouble", max_seq_size, false)); - - MD5 bounded_sequence_long_double_field_hash("bounded_sequence_long_double_field"); - for(int i = 0; i < 4; ++i) - { - mst_bounded_sequence_long_double_field.detail().name_hash()[i] = bounded_sequence_long_double_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_bounded_sequence_long_double_field); - - MinimalStructMember mst_bounded_sequence_bool_field; - mst_bounded_sequence_bool_field.common().member_id(memberId++); - mst_bounded_sequence_bool_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_bounded_sequence_bool_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_bounded_sequence_bool_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_bounded_sequence_bool_field.common().member_flags().IS_OPTIONAL(false); - mst_bounded_sequence_bool_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_bounded_sequence_bool_field.common().member_flags().IS_KEY(false); - mst_bounded_sequence_bool_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_bounded_sequence_bool_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("bool", max_seq_size, false)); - - MD5 bounded_sequence_bool_field_hash("bounded_sequence_bool_field"); - for(int i = 0; i < 4; ++i) - { - mst_bounded_sequence_bool_field.detail().name_hash()[i] = bounded_sequence_bool_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_bounded_sequence_bool_field); - - MinimalStructMember mst_bounded_sequence_string_field; - mst_bounded_sequence_string_field.common().member_id(memberId++); - mst_bounded_sequence_string_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_bounded_sequence_string_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_bounded_sequence_string_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_bounded_sequence_string_field.common().member_flags().IS_OPTIONAL(false); - mst_bounded_sequence_string_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_bounded_sequence_string_field.common().member_flags().IS_KEY(false); - mst_bounded_sequence_string_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_bounded_sequence_string_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier(TypeNamesGenerator::get_string_type_name(255, false), max_seq_size, false)); - - MD5 bounded_sequence_string_field_hash("bounded_sequence_string_field"); - for(int i = 0; i < 4; ++i) - { - mst_bounded_sequence_string_field.detail().name_hash()[i] = bounded_sequence_string_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_bounded_sequence_string_field); - - MinimalStructMember mst_bounded_sequence_enum_field; - mst_bounded_sequence_enum_field.common().member_id(memberId++); - mst_bounded_sequence_enum_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_bounded_sequence_enum_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_bounded_sequence_enum_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_bounded_sequence_enum_field.common().member_flags().IS_OPTIONAL(false); - mst_bounded_sequence_enum_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_bounded_sequence_enum_field.common().member_flags().IS_KEY(false); - mst_bounded_sequence_enum_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_bounded_sequence_enum_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("Color", max_seq_size, false)); - - MD5 bounded_sequence_enum_field_hash("bounded_sequence_enum_field"); - for(int i = 0; i < 4; ++i) - { - mst_bounded_sequence_enum_field.detail().name_hash()[i] = bounded_sequence_enum_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_bounded_sequence_enum_field); - - MinimalStructMember mst_bounded_sequence_enum2_field; - mst_bounded_sequence_enum2_field.common().member_id(memberId++); - mst_bounded_sequence_enum2_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_bounded_sequence_enum2_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_bounded_sequence_enum2_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_bounded_sequence_enum2_field.common().member_flags().IS_OPTIONAL(false); - mst_bounded_sequence_enum2_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_bounded_sequence_enum2_field.common().member_flags().IS_KEY(false); - mst_bounded_sequence_enum2_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_bounded_sequence_enum2_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("Material", max_seq_size, false)); - - MD5 bounded_sequence_enum2_field_hash("bounded_sequence_enum2_field"); - for(int i = 0; i < 4; ++i) - { - mst_bounded_sequence_enum2_field.detail().name_hash()[i] = bounded_sequence_enum2_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_bounded_sequence_enum2_field); - - MinimalStructMember mst_bounded_sequence_struct_field; - mst_bounded_sequence_struct_field.common().member_id(memberId++); - mst_bounded_sequence_struct_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_bounded_sequence_struct_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_bounded_sequence_struct_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_bounded_sequence_struct_field.common().member_flags().IS_OPTIONAL(false); - mst_bounded_sequence_struct_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_bounded_sequence_struct_field.common().member_flags().IS_KEY(false); - mst_bounded_sequence_struct_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_bounded_sequence_struct_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("StructType", max_seq_size, false)); - - MD5 bounded_sequence_struct_field_hash("bounded_sequence_struct_field"); - for(int i = 0; i < 4; ++i) - { - mst_bounded_sequence_struct_field.detail().name_hash()[i] = bounded_sequence_struct_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_bounded_sequence_struct_field); - - MinimalStructMember mst_unbounded_sequence_char_field; - mst_unbounded_sequence_char_field.common().member_id(memberId++); - mst_unbounded_sequence_char_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_unbounded_sequence_char_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_unbounded_sequence_char_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_unbounded_sequence_char_field.common().member_flags().IS_OPTIONAL(false); - mst_unbounded_sequence_char_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_unbounded_sequence_char_field.common().member_flags().IS_KEY(false); - mst_unbounded_sequence_char_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_unbounded_sequence_char_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("char", 100, false)); - - MD5 unbounded_sequence_char_field_hash("unbounded_sequence_char_field"); - for(int i = 0; i < 4; ++i) - { - mst_unbounded_sequence_char_field.detail().name_hash()[i] = unbounded_sequence_char_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_unbounded_sequence_char_field); - - MinimalStructMember mst_unbounded_sequence_uint8_field; - mst_unbounded_sequence_uint8_field.common().member_id(memberId++); - mst_unbounded_sequence_uint8_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_unbounded_sequence_uint8_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_unbounded_sequence_uint8_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_unbounded_sequence_uint8_field.common().member_flags().IS_OPTIONAL(false); - mst_unbounded_sequence_uint8_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_unbounded_sequence_uint8_field.common().member_flags().IS_KEY(false); - mst_unbounded_sequence_uint8_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_unbounded_sequence_uint8_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("uint8_t", 100, false)); - - MD5 unbounded_sequence_uint8_field_hash("unbounded_sequence_uint8_field"); - for(int i = 0; i < 4; ++i) - { - mst_unbounded_sequence_uint8_field.detail().name_hash()[i] = unbounded_sequence_uint8_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_unbounded_sequence_uint8_field); - - MinimalStructMember mst_unbounded_sequence_int16_field; - mst_unbounded_sequence_int16_field.common().member_id(memberId++); - mst_unbounded_sequence_int16_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_unbounded_sequence_int16_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_unbounded_sequence_int16_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_unbounded_sequence_int16_field.common().member_flags().IS_OPTIONAL(false); - mst_unbounded_sequence_int16_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_unbounded_sequence_int16_field.common().member_flags().IS_KEY(false); - mst_unbounded_sequence_int16_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_unbounded_sequence_int16_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("int16_t", 100, false)); - - MD5 unbounded_sequence_int16_field_hash("unbounded_sequence_int16_field"); - for(int i = 0; i < 4; ++i) - { - mst_unbounded_sequence_int16_field.detail().name_hash()[i] = unbounded_sequence_int16_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_unbounded_sequence_int16_field); - - MinimalStructMember mst_unbounded_sequence_uint16_field; - mst_unbounded_sequence_uint16_field.common().member_id(memberId++); - mst_unbounded_sequence_uint16_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_unbounded_sequence_uint16_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_unbounded_sequence_uint16_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_unbounded_sequence_uint16_field.common().member_flags().IS_OPTIONAL(false); - mst_unbounded_sequence_uint16_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_unbounded_sequence_uint16_field.common().member_flags().IS_KEY(false); - mst_unbounded_sequence_uint16_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_unbounded_sequence_uint16_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("uint16_t", 100, false)); - - MD5 unbounded_sequence_uint16_field_hash("unbounded_sequence_uint16_field"); - for(int i = 0; i < 4; ++i) - { - mst_unbounded_sequence_uint16_field.detail().name_hash()[i] = unbounded_sequence_uint16_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_unbounded_sequence_uint16_field); - - MinimalStructMember mst_unbounded_sequence_int32_field; - mst_unbounded_sequence_int32_field.common().member_id(memberId++); - mst_unbounded_sequence_int32_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_unbounded_sequence_int32_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_unbounded_sequence_int32_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_unbounded_sequence_int32_field.common().member_flags().IS_OPTIONAL(false); - mst_unbounded_sequence_int32_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_unbounded_sequence_int32_field.common().member_flags().IS_KEY(false); - mst_unbounded_sequence_int32_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_unbounded_sequence_int32_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("int32_t", 100, false)); - - MD5 unbounded_sequence_int32_field_hash("unbounded_sequence_int32_field"); - for(int i = 0; i < 4; ++i) - { - mst_unbounded_sequence_int32_field.detail().name_hash()[i] = unbounded_sequence_int32_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_unbounded_sequence_int32_field); - - MinimalStructMember mst_unbounded_sequence_uint32_field; - mst_unbounded_sequence_uint32_field.common().member_id(memberId++); - mst_unbounded_sequence_uint32_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_unbounded_sequence_uint32_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_unbounded_sequence_uint32_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_unbounded_sequence_uint32_field.common().member_flags().IS_OPTIONAL(false); - mst_unbounded_sequence_uint32_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_unbounded_sequence_uint32_field.common().member_flags().IS_KEY(false); - mst_unbounded_sequence_uint32_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_unbounded_sequence_uint32_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("uint32_t", 100, false)); - - MD5 unbounded_sequence_uint32_field_hash("unbounded_sequence_uint32_field"); - for(int i = 0; i < 4; ++i) - { - mst_unbounded_sequence_uint32_field.detail().name_hash()[i] = unbounded_sequence_uint32_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_unbounded_sequence_uint32_field); - - MinimalStructMember mst_unbounded_sequence_int64_field; - mst_unbounded_sequence_int64_field.common().member_id(memberId++); - mst_unbounded_sequence_int64_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_unbounded_sequence_int64_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_unbounded_sequence_int64_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_unbounded_sequence_int64_field.common().member_flags().IS_OPTIONAL(false); - mst_unbounded_sequence_int64_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_unbounded_sequence_int64_field.common().member_flags().IS_KEY(false); - mst_unbounded_sequence_int64_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_unbounded_sequence_int64_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("int64_t", 100, false)); - - MD5 unbounded_sequence_int64_field_hash("unbounded_sequence_int64_field"); - for(int i = 0; i < 4; ++i) - { - mst_unbounded_sequence_int64_field.detail().name_hash()[i] = unbounded_sequence_int64_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_unbounded_sequence_int64_field); - - MinimalStructMember mst_unbounded_sequence_uint64_field; - mst_unbounded_sequence_uint64_field.common().member_id(memberId++); - mst_unbounded_sequence_uint64_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_unbounded_sequence_uint64_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_unbounded_sequence_uint64_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_unbounded_sequence_uint64_field.common().member_flags().IS_OPTIONAL(false); - mst_unbounded_sequence_uint64_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_unbounded_sequence_uint64_field.common().member_flags().IS_KEY(false); - mst_unbounded_sequence_uint64_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_unbounded_sequence_uint64_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("uint64_t", 100, false)); - - MD5 unbounded_sequence_uint64_field_hash("unbounded_sequence_uint64_field"); - for(int i = 0; i < 4; ++i) - { - mst_unbounded_sequence_uint64_field.detail().name_hash()[i] = unbounded_sequence_uint64_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_unbounded_sequence_uint64_field); - - MinimalStructMember mst_unbounded_sequence_float_field; - mst_unbounded_sequence_float_field.common().member_id(memberId++); - mst_unbounded_sequence_float_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_unbounded_sequence_float_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_unbounded_sequence_float_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_unbounded_sequence_float_field.common().member_flags().IS_OPTIONAL(false); - mst_unbounded_sequence_float_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_unbounded_sequence_float_field.common().member_flags().IS_KEY(false); - mst_unbounded_sequence_float_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_unbounded_sequence_float_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("float", 100, false)); - - MD5 unbounded_sequence_float_field_hash("unbounded_sequence_float_field"); - for(int i = 0; i < 4; ++i) - { - mst_unbounded_sequence_float_field.detail().name_hash()[i] = unbounded_sequence_float_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_unbounded_sequence_float_field); - - MinimalStructMember mst_unbounded_sequence_double_field; - mst_unbounded_sequence_double_field.common().member_id(memberId++); - mst_unbounded_sequence_double_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_unbounded_sequence_double_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_unbounded_sequence_double_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_unbounded_sequence_double_field.common().member_flags().IS_OPTIONAL(false); - mst_unbounded_sequence_double_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_unbounded_sequence_double_field.common().member_flags().IS_KEY(false); - mst_unbounded_sequence_double_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_unbounded_sequence_double_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("double", 100, false)); - - MD5 unbounded_sequence_double_field_hash("unbounded_sequence_double_field"); - for(int i = 0; i < 4; ++i) - { - mst_unbounded_sequence_double_field.detail().name_hash()[i] = unbounded_sequence_double_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_unbounded_sequence_double_field); - - MinimalStructMember mst_unbounded_sequence_long_double_field; - mst_unbounded_sequence_long_double_field.common().member_id(memberId++); - mst_unbounded_sequence_long_double_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_unbounded_sequence_long_double_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_unbounded_sequence_long_double_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_unbounded_sequence_long_double_field.common().member_flags().IS_OPTIONAL(false); - mst_unbounded_sequence_long_double_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_unbounded_sequence_long_double_field.common().member_flags().IS_KEY(false); - mst_unbounded_sequence_long_double_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_unbounded_sequence_long_double_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("longdouble", 100, false)); - - MD5 unbounded_sequence_long_double_field_hash("unbounded_sequence_long_double_field"); - for(int i = 0; i < 4; ++i) - { - mst_unbounded_sequence_long_double_field.detail().name_hash()[i] = unbounded_sequence_long_double_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_unbounded_sequence_long_double_field); - - MinimalStructMember mst_unbounded_sequence_bool_field; - mst_unbounded_sequence_bool_field.common().member_id(memberId++); - mst_unbounded_sequence_bool_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_unbounded_sequence_bool_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_unbounded_sequence_bool_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_unbounded_sequence_bool_field.common().member_flags().IS_OPTIONAL(false); - mst_unbounded_sequence_bool_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_unbounded_sequence_bool_field.common().member_flags().IS_KEY(false); - mst_unbounded_sequence_bool_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_unbounded_sequence_bool_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("bool", 100, false)); - - MD5 unbounded_sequence_bool_field_hash("unbounded_sequence_bool_field"); - for(int i = 0; i < 4; ++i) - { - mst_unbounded_sequence_bool_field.detail().name_hash()[i] = unbounded_sequence_bool_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_unbounded_sequence_bool_field); - - MinimalStructMember mst_unbounded_sequence_string_field; - mst_unbounded_sequence_string_field.common().member_id(memberId++); - mst_unbounded_sequence_string_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_unbounded_sequence_string_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_unbounded_sequence_string_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_unbounded_sequence_string_field.common().member_flags().IS_OPTIONAL(false); - mst_unbounded_sequence_string_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_unbounded_sequence_string_field.common().member_flags().IS_KEY(false); - mst_unbounded_sequence_string_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_unbounded_sequence_string_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier(TypeNamesGenerator::get_string_type_name(255, false), 100, false)); - - MD5 unbounded_sequence_string_field_hash("unbounded_sequence_string_field"); - for(int i = 0; i < 4; ++i) - { - mst_unbounded_sequence_string_field.detail().name_hash()[i] = unbounded_sequence_string_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_unbounded_sequence_string_field); - - MinimalStructMember mst_unbounded_sequence_enum_field; - mst_unbounded_sequence_enum_field.common().member_id(memberId++); - mst_unbounded_sequence_enum_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_unbounded_sequence_enum_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_unbounded_sequence_enum_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_unbounded_sequence_enum_field.common().member_flags().IS_OPTIONAL(false); - mst_unbounded_sequence_enum_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_unbounded_sequence_enum_field.common().member_flags().IS_KEY(false); - mst_unbounded_sequence_enum_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_unbounded_sequence_enum_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("Color", 100, false)); - - MD5 unbounded_sequence_enum_field_hash("unbounded_sequence_enum_field"); - for(int i = 0; i < 4; ++i) - { - mst_unbounded_sequence_enum_field.detail().name_hash()[i] = unbounded_sequence_enum_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_unbounded_sequence_enum_field); - - MinimalStructMember mst_unbounded_sequence_enum2_field; - mst_unbounded_sequence_enum2_field.common().member_id(memberId++); - mst_unbounded_sequence_enum2_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_unbounded_sequence_enum2_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_unbounded_sequence_enum2_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_unbounded_sequence_enum2_field.common().member_flags().IS_OPTIONAL(false); - mst_unbounded_sequence_enum2_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_unbounded_sequence_enum2_field.common().member_flags().IS_KEY(false); - mst_unbounded_sequence_enum2_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_unbounded_sequence_enum2_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("Material", 100, false)); - - MD5 unbounded_sequence_enum2_field_hash("unbounded_sequence_enum2_field"); - for(int i = 0; i < 4; ++i) - { - mst_unbounded_sequence_enum2_field.detail().name_hash()[i] = unbounded_sequence_enum2_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_unbounded_sequence_enum2_field); - - MinimalStructMember mst_unbounded_sequence_struct_field; - mst_unbounded_sequence_struct_field.common().member_id(memberId++); - mst_unbounded_sequence_struct_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_unbounded_sequence_struct_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_unbounded_sequence_struct_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_unbounded_sequence_struct_field.common().member_flags().IS_OPTIONAL(false); - mst_unbounded_sequence_struct_field.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_unbounded_sequence_struct_field.common().member_flags().IS_KEY(false); - mst_unbounded_sequence_struct_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_unbounded_sequence_struct_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("StructType", 100, false)); - - MD5 unbounded_sequence_struct_field_hash("unbounded_sequence_struct_field"); - for(int i = 0; i < 4; ++i) - { - mst_unbounded_sequence_struct_field.detail().name_hash()[i] = unbounded_sequence_struct_field_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_unbounded_sequence_struct_field); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("ContentFilterTestType", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("ContentFilterTestType", false); -} - -const TypeObject* GetCompleteContentFilterTestTypeObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ContentFilterTestType", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_char_field; - cst_char_field.common().member_id(memberId++); - cst_char_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_char_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_char_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_char_field.common().member_flags().IS_OPTIONAL(false); - cst_char_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_char_field.common().member_flags().IS_KEY(false); - cst_char_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_char_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("char", false)); - - - cst_char_field.detail().name("char_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_char_field); - - CompleteStructMember cst_uint8_field; - cst_uint8_field.common().member_id(memberId++); - cst_uint8_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_uint8_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_uint8_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_uint8_field.common().member_flags().IS_OPTIONAL(false); - cst_uint8_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_uint8_field.common().member_flags().IS_KEY(false); - cst_uint8_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_uint8_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint8_t", false)); - - - cst_uint8_field.detail().name("uint8_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_uint8_field); - - CompleteStructMember cst_int16_field; - cst_int16_field.common().member_id(memberId++); - cst_int16_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_int16_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_int16_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_int16_field.common().member_flags().IS_OPTIONAL(false); - cst_int16_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_int16_field.common().member_flags().IS_KEY(false); - cst_int16_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_int16_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int16_t", false)); - - - cst_int16_field.detail().name("int16_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_int16_field); - - CompleteStructMember cst_uint16_field; - cst_uint16_field.common().member_id(memberId++); - cst_uint16_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_uint16_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_uint16_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_uint16_field.common().member_flags().IS_OPTIONAL(false); - cst_uint16_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_uint16_field.common().member_flags().IS_KEY(false); - cst_uint16_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_uint16_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint16_t", false)); - - - cst_uint16_field.detail().name("uint16_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_uint16_field); - - CompleteStructMember cst_int32_field; - cst_int32_field.common().member_id(memberId++); - cst_int32_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_int32_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_int32_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_int32_field.common().member_flags().IS_OPTIONAL(false); - cst_int32_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_int32_field.common().member_flags().IS_KEY(false); - cst_int32_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_int32_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - cst_int32_field.detail().name("int32_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_int32_field); - - CompleteStructMember cst_uint32_field; - cst_uint32_field.common().member_id(memberId++); - cst_uint32_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_uint32_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_uint32_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_uint32_field.common().member_flags().IS_OPTIONAL(false); - cst_uint32_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_uint32_field.common().member_flags().IS_KEY(false); - cst_uint32_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_uint32_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint32_t", false)); - - - cst_uint32_field.detail().name("uint32_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_uint32_field); - - CompleteStructMember cst_int64_field; - cst_int64_field.common().member_id(memberId++); - cst_int64_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_int64_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_int64_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_int64_field.common().member_flags().IS_OPTIONAL(false); - cst_int64_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_int64_field.common().member_flags().IS_KEY(false); - cst_int64_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_int64_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int64_t", false)); - - - cst_int64_field.detail().name("int64_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_int64_field); - - CompleteStructMember cst_uint64_field; - cst_uint64_field.common().member_id(memberId++); - cst_uint64_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_uint64_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_uint64_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_uint64_field.common().member_flags().IS_OPTIONAL(false); - cst_uint64_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_uint64_field.common().member_flags().IS_KEY(false); - cst_uint64_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_uint64_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint64_t", false)); - - - cst_uint64_field.detail().name("uint64_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_uint64_field); - - CompleteStructMember cst_float_field; - cst_float_field.common().member_id(memberId++); - cst_float_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_float_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_float_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_float_field.common().member_flags().IS_OPTIONAL(false); - cst_float_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_float_field.common().member_flags().IS_KEY(false); - cst_float_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_float_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("float", false)); - - - cst_float_field.detail().name("float_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_float_field); - - CompleteStructMember cst_double_field; - cst_double_field.common().member_id(memberId++); - cst_double_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_double_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_double_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_double_field.common().member_flags().IS_OPTIONAL(false); - cst_double_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_double_field.common().member_flags().IS_KEY(false); - cst_double_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_double_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("double", false)); - - - cst_double_field.detail().name("double_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_double_field); - - CompleteStructMember cst_long_double_field; - cst_long_double_field.common().member_id(memberId++); - cst_long_double_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_long_double_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_long_double_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_long_double_field.common().member_flags().IS_OPTIONAL(false); - cst_long_double_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_long_double_field.common().member_flags().IS_KEY(false); - cst_long_double_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_long_double_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("longdouble", false)); - - - cst_long_double_field.detail().name("long_double_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_long_double_field); - - CompleteStructMember cst_bool_field; - cst_bool_field.common().member_id(memberId++); - cst_bool_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_bool_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_bool_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_bool_field.common().member_flags().IS_OPTIONAL(false); - cst_bool_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_bool_field.common().member_flags().IS_KEY(false); - cst_bool_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_bool_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("bool", false)); - - - cst_bool_field.detail().name("bool_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_bool_field); - - CompleteStructMember cst_string_field; - cst_string_field.common().member_id(memberId++); - cst_string_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_string_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_string_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_string_field.common().member_flags().IS_OPTIONAL(false); - cst_string_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_string_field.common().member_flags().IS_KEY(false); - cst_string_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_string_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, false)); - - cst_string_field.detail().name("string_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_string_field); - - CompleteStructMember cst_enum_field; - cst_enum_field.common().member_id(memberId++); - cst_enum_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_enum_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_enum_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_enum_field.common().member_flags().IS_OPTIONAL(false); - cst_enum_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_enum_field.common().member_flags().IS_KEY(false); - cst_enum_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_enum_field.common().member_type_id(*GetColorIdentifier(true)); - - cst_enum_field.detail().name("enum_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_enum_field); - - CompleteStructMember cst_enum2_field; - cst_enum2_field.common().member_id(memberId++); - cst_enum2_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_enum2_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_enum2_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_enum2_field.common().member_flags().IS_OPTIONAL(false); - cst_enum2_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_enum2_field.common().member_flags().IS_KEY(false); - cst_enum2_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_enum2_field.common().member_type_id(*GetMaterialIdentifier(true)); - - cst_enum2_field.detail().name("enum2_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_enum2_field); - - CompleteStructMember cst_struct_field; - cst_struct_field.common().member_id(memberId++); - cst_struct_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_struct_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_struct_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_struct_field.common().member_flags().IS_OPTIONAL(false); - cst_struct_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_struct_field.common().member_flags().IS_KEY(false); - cst_struct_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_struct_field.common().member_type_id(*GetStructTypeIdentifier(true)); - - cst_struct_field.detail().name("struct_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_struct_field); - - CompleteStructMember cst_array_char_field; - cst_array_char_field.common().member_id(memberId++); - cst_array_char_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_array_char_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_array_char_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_array_char_field.common().member_flags().IS_OPTIONAL(false); - cst_array_char_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_array_char_field.common().member_flags().IS_KEY(false); - cst_array_char_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_array_char_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("char", {max_array_size}, true)); - - cst_array_char_field.detail().name("array_char_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_array_char_field); - - CompleteStructMember cst_array_uint8_field; - cst_array_uint8_field.common().member_id(memberId++); - cst_array_uint8_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_array_uint8_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_array_uint8_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_array_uint8_field.common().member_flags().IS_OPTIONAL(false); - cst_array_uint8_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_array_uint8_field.common().member_flags().IS_KEY(false); - cst_array_uint8_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_array_uint8_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("uint8_t", {max_array_size}, true)); - - cst_array_uint8_field.detail().name("array_uint8_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_array_uint8_field); - - CompleteStructMember cst_array_int16_field; - cst_array_int16_field.common().member_id(memberId++); - cst_array_int16_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_array_int16_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_array_int16_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_array_int16_field.common().member_flags().IS_OPTIONAL(false); - cst_array_int16_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_array_int16_field.common().member_flags().IS_KEY(false); - cst_array_int16_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_array_int16_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("int16_t", {max_array_size}, true)); - - cst_array_int16_field.detail().name("array_int16_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_array_int16_field); - - CompleteStructMember cst_array_uint16_field; - cst_array_uint16_field.common().member_id(memberId++); - cst_array_uint16_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_array_uint16_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_array_uint16_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_array_uint16_field.common().member_flags().IS_OPTIONAL(false); - cst_array_uint16_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_array_uint16_field.common().member_flags().IS_KEY(false); - cst_array_uint16_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_array_uint16_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("uint16_t", {max_array_size}, true)); - - cst_array_uint16_field.detail().name("array_uint16_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_array_uint16_field); - - CompleteStructMember cst_array_int32_field; - cst_array_int32_field.common().member_id(memberId++); - cst_array_int32_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_array_int32_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_array_int32_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_array_int32_field.common().member_flags().IS_OPTIONAL(false); - cst_array_int32_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_array_int32_field.common().member_flags().IS_KEY(false); - cst_array_int32_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_array_int32_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("int32_t", {max_array_size}, true)); - - cst_array_int32_field.detail().name("array_int32_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_array_int32_field); - - CompleteStructMember cst_array_uint32_field; - cst_array_uint32_field.common().member_id(memberId++); - cst_array_uint32_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_array_uint32_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_array_uint32_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_array_uint32_field.common().member_flags().IS_OPTIONAL(false); - cst_array_uint32_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_array_uint32_field.common().member_flags().IS_KEY(false); - cst_array_uint32_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_array_uint32_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("uint32_t", {max_array_size}, true)); - - cst_array_uint32_field.detail().name("array_uint32_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_array_uint32_field); - - CompleteStructMember cst_array_int64_field; - cst_array_int64_field.common().member_id(memberId++); - cst_array_int64_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_array_int64_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_array_int64_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_array_int64_field.common().member_flags().IS_OPTIONAL(false); - cst_array_int64_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_array_int64_field.common().member_flags().IS_KEY(false); - cst_array_int64_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_array_int64_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("int64_t", {max_array_size}, true)); - - cst_array_int64_field.detail().name("array_int64_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_array_int64_field); - - CompleteStructMember cst_array_uint64_field; - cst_array_uint64_field.common().member_id(memberId++); - cst_array_uint64_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_array_uint64_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_array_uint64_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_array_uint64_field.common().member_flags().IS_OPTIONAL(false); - cst_array_uint64_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_array_uint64_field.common().member_flags().IS_KEY(false); - cst_array_uint64_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_array_uint64_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("uint64_t", {max_array_size}, true)); - - cst_array_uint64_field.detail().name("array_uint64_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_array_uint64_field); - - CompleteStructMember cst_array_float_field; - cst_array_float_field.common().member_id(memberId++); - cst_array_float_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_array_float_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_array_float_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_array_float_field.common().member_flags().IS_OPTIONAL(false); - cst_array_float_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_array_float_field.common().member_flags().IS_KEY(false); - cst_array_float_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_array_float_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("float", {max_array_size}, true)); - - cst_array_float_field.detail().name("array_float_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_array_float_field); - - CompleteStructMember cst_array_double_field; - cst_array_double_field.common().member_id(memberId++); - cst_array_double_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_array_double_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_array_double_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_array_double_field.common().member_flags().IS_OPTIONAL(false); - cst_array_double_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_array_double_field.common().member_flags().IS_KEY(false); - cst_array_double_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_array_double_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("double", {max_array_size}, true)); - - cst_array_double_field.detail().name("array_double_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_array_double_field); - - CompleteStructMember cst_array_long_double_field; - cst_array_long_double_field.common().member_id(memberId++); - cst_array_long_double_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_array_long_double_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_array_long_double_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_array_long_double_field.common().member_flags().IS_OPTIONAL(false); - cst_array_long_double_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_array_long_double_field.common().member_flags().IS_KEY(false); - cst_array_long_double_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_array_long_double_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("longdouble", {max_array_size}, true)); - - cst_array_long_double_field.detail().name("array_long_double_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_array_long_double_field); - - CompleteStructMember cst_array_bool_field; - cst_array_bool_field.common().member_id(memberId++); - cst_array_bool_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_array_bool_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_array_bool_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_array_bool_field.common().member_flags().IS_OPTIONAL(false); - cst_array_bool_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_array_bool_field.common().member_flags().IS_KEY(false); - cst_array_bool_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_array_bool_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("bool", {max_array_size}, true)); - - cst_array_bool_field.detail().name("array_bool_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_array_bool_field); - - CompleteStructMember cst_array_string_field; - cst_array_string_field.common().member_id(memberId++); - cst_array_string_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_array_string_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_array_string_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_array_string_field.common().member_flags().IS_OPTIONAL(false); - cst_array_string_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_array_string_field.common().member_flags().IS_KEY(false); - cst_array_string_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_array_string_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier(TypeNamesGenerator::get_string_type_name(255, false), {max_array_size}, true)); - - cst_array_string_field.detail().name("array_string_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_array_string_field); - - CompleteStructMember cst_array_enum_field; - cst_array_enum_field.common().member_id(memberId++); - cst_array_enum_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_array_enum_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_array_enum_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_array_enum_field.common().member_flags().IS_OPTIONAL(false); - cst_array_enum_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_array_enum_field.common().member_flags().IS_KEY(false); - cst_array_enum_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_array_enum_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("Color", {max_array_size}, true)); - - cst_array_enum_field.detail().name("array_enum_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_array_enum_field); - - CompleteStructMember cst_array_enum2_field; - cst_array_enum2_field.common().member_id(memberId++); - cst_array_enum2_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_array_enum2_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_array_enum2_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_array_enum2_field.common().member_flags().IS_OPTIONAL(false); - cst_array_enum2_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_array_enum2_field.common().member_flags().IS_KEY(false); - cst_array_enum2_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_array_enum2_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("Material", {max_array_size}, true)); - - cst_array_enum2_field.detail().name("array_enum2_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_array_enum2_field); - - CompleteStructMember cst_array_struct_field; - cst_array_struct_field.common().member_id(memberId++); - cst_array_struct_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_array_struct_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_array_struct_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_array_struct_field.common().member_flags().IS_OPTIONAL(false); - cst_array_struct_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_array_struct_field.common().member_flags().IS_KEY(false); - cst_array_struct_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_array_struct_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("StructType", {max_array_size}, true)); - - cst_array_struct_field.detail().name("array_struct_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_array_struct_field); - - CompleteStructMember cst_bounded_sequence_char_field; - cst_bounded_sequence_char_field.common().member_id(memberId++); - cst_bounded_sequence_char_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_bounded_sequence_char_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_bounded_sequence_char_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_bounded_sequence_char_field.common().member_flags().IS_OPTIONAL(false); - cst_bounded_sequence_char_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_bounded_sequence_char_field.common().member_flags().IS_KEY(false); - cst_bounded_sequence_char_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_bounded_sequence_char_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("char", max_seq_size, true)); - - cst_bounded_sequence_char_field.detail().name("bounded_sequence_char_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_bounded_sequence_char_field); - - CompleteStructMember cst_bounded_sequence_uint8_field; - cst_bounded_sequence_uint8_field.common().member_id(memberId++); - cst_bounded_sequence_uint8_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_bounded_sequence_uint8_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_bounded_sequence_uint8_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_bounded_sequence_uint8_field.common().member_flags().IS_OPTIONAL(false); - cst_bounded_sequence_uint8_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_bounded_sequence_uint8_field.common().member_flags().IS_KEY(false); - cst_bounded_sequence_uint8_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_bounded_sequence_uint8_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("uint8_t", max_seq_size, true)); - - cst_bounded_sequence_uint8_field.detail().name("bounded_sequence_uint8_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_bounded_sequence_uint8_field); - - CompleteStructMember cst_bounded_sequence_int16_field; - cst_bounded_sequence_int16_field.common().member_id(memberId++); - cst_bounded_sequence_int16_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_bounded_sequence_int16_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_bounded_sequence_int16_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_bounded_sequence_int16_field.common().member_flags().IS_OPTIONAL(false); - cst_bounded_sequence_int16_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_bounded_sequence_int16_field.common().member_flags().IS_KEY(false); - cst_bounded_sequence_int16_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_bounded_sequence_int16_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("int16_t", max_seq_size, true)); - - cst_bounded_sequence_int16_field.detail().name("bounded_sequence_int16_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_bounded_sequence_int16_field); - - CompleteStructMember cst_bounded_sequence_uint16_field; - cst_bounded_sequence_uint16_field.common().member_id(memberId++); - cst_bounded_sequence_uint16_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_bounded_sequence_uint16_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_bounded_sequence_uint16_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_bounded_sequence_uint16_field.common().member_flags().IS_OPTIONAL(false); - cst_bounded_sequence_uint16_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_bounded_sequence_uint16_field.common().member_flags().IS_KEY(false); - cst_bounded_sequence_uint16_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_bounded_sequence_uint16_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("uint16_t", max_seq_size, true)); - - cst_bounded_sequence_uint16_field.detail().name("bounded_sequence_uint16_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_bounded_sequence_uint16_field); - - CompleteStructMember cst_bounded_sequence_int32_field; - cst_bounded_sequence_int32_field.common().member_id(memberId++); - cst_bounded_sequence_int32_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_bounded_sequence_int32_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_bounded_sequence_int32_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_bounded_sequence_int32_field.common().member_flags().IS_OPTIONAL(false); - cst_bounded_sequence_int32_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_bounded_sequence_int32_field.common().member_flags().IS_KEY(false); - cst_bounded_sequence_int32_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_bounded_sequence_int32_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("int32_t", max_seq_size, true)); - - cst_bounded_sequence_int32_field.detail().name("bounded_sequence_int32_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_bounded_sequence_int32_field); - - CompleteStructMember cst_bounded_sequence_uint32_field; - cst_bounded_sequence_uint32_field.common().member_id(memberId++); - cst_bounded_sequence_uint32_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_bounded_sequence_uint32_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_bounded_sequence_uint32_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_bounded_sequence_uint32_field.common().member_flags().IS_OPTIONAL(false); - cst_bounded_sequence_uint32_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_bounded_sequence_uint32_field.common().member_flags().IS_KEY(false); - cst_bounded_sequence_uint32_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_bounded_sequence_uint32_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("uint32_t", max_seq_size, true)); - - cst_bounded_sequence_uint32_field.detail().name("bounded_sequence_uint32_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_bounded_sequence_uint32_field); - - CompleteStructMember cst_bounded_sequence_int64_field; - cst_bounded_sequence_int64_field.common().member_id(memberId++); - cst_bounded_sequence_int64_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_bounded_sequence_int64_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_bounded_sequence_int64_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_bounded_sequence_int64_field.common().member_flags().IS_OPTIONAL(false); - cst_bounded_sequence_int64_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_bounded_sequence_int64_field.common().member_flags().IS_KEY(false); - cst_bounded_sequence_int64_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_bounded_sequence_int64_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("int64_t", max_seq_size, true)); - - cst_bounded_sequence_int64_field.detail().name("bounded_sequence_int64_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_bounded_sequence_int64_field); - - CompleteStructMember cst_bounded_sequence_uint64_field; - cst_bounded_sequence_uint64_field.common().member_id(memberId++); - cst_bounded_sequence_uint64_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_bounded_sequence_uint64_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_bounded_sequence_uint64_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_bounded_sequence_uint64_field.common().member_flags().IS_OPTIONAL(false); - cst_bounded_sequence_uint64_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_bounded_sequence_uint64_field.common().member_flags().IS_KEY(false); - cst_bounded_sequence_uint64_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_bounded_sequence_uint64_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("uint64_t", max_seq_size, true)); - - cst_bounded_sequence_uint64_field.detail().name("bounded_sequence_uint64_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_bounded_sequence_uint64_field); - - CompleteStructMember cst_bounded_sequence_float_field; - cst_bounded_sequence_float_field.common().member_id(memberId++); - cst_bounded_sequence_float_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_bounded_sequence_float_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_bounded_sequence_float_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_bounded_sequence_float_field.common().member_flags().IS_OPTIONAL(false); - cst_bounded_sequence_float_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_bounded_sequence_float_field.common().member_flags().IS_KEY(false); - cst_bounded_sequence_float_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_bounded_sequence_float_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("float", max_seq_size, true)); - - cst_bounded_sequence_float_field.detail().name("bounded_sequence_float_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_bounded_sequence_float_field); - - CompleteStructMember cst_bounded_sequence_double_field; - cst_bounded_sequence_double_field.common().member_id(memberId++); - cst_bounded_sequence_double_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_bounded_sequence_double_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_bounded_sequence_double_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_bounded_sequence_double_field.common().member_flags().IS_OPTIONAL(false); - cst_bounded_sequence_double_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_bounded_sequence_double_field.common().member_flags().IS_KEY(false); - cst_bounded_sequence_double_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_bounded_sequence_double_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("double", max_seq_size, true)); - - cst_bounded_sequence_double_field.detail().name("bounded_sequence_double_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_bounded_sequence_double_field); - - CompleteStructMember cst_bounded_sequence_long_double_field; - cst_bounded_sequence_long_double_field.common().member_id(memberId++); - cst_bounded_sequence_long_double_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_bounded_sequence_long_double_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_bounded_sequence_long_double_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_bounded_sequence_long_double_field.common().member_flags().IS_OPTIONAL(false); - cst_bounded_sequence_long_double_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_bounded_sequence_long_double_field.common().member_flags().IS_KEY(false); - cst_bounded_sequence_long_double_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_bounded_sequence_long_double_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("longdouble", max_seq_size, true)); - - cst_bounded_sequence_long_double_field.detail().name("bounded_sequence_long_double_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_bounded_sequence_long_double_field); - - CompleteStructMember cst_bounded_sequence_bool_field; - cst_bounded_sequence_bool_field.common().member_id(memberId++); - cst_bounded_sequence_bool_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_bounded_sequence_bool_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_bounded_sequence_bool_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_bounded_sequence_bool_field.common().member_flags().IS_OPTIONAL(false); - cst_bounded_sequence_bool_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_bounded_sequence_bool_field.common().member_flags().IS_KEY(false); - cst_bounded_sequence_bool_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_bounded_sequence_bool_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("bool", max_seq_size, true)); - - cst_bounded_sequence_bool_field.detail().name("bounded_sequence_bool_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_bounded_sequence_bool_field); - - CompleteStructMember cst_bounded_sequence_string_field; - cst_bounded_sequence_string_field.common().member_id(memberId++); - cst_bounded_sequence_string_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_bounded_sequence_string_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_bounded_sequence_string_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_bounded_sequence_string_field.common().member_flags().IS_OPTIONAL(false); - cst_bounded_sequence_string_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_bounded_sequence_string_field.common().member_flags().IS_KEY(false); - cst_bounded_sequence_string_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_bounded_sequence_string_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier(TypeNamesGenerator::get_string_type_name(255, false), max_seq_size, true)); - - cst_bounded_sequence_string_field.detail().name("bounded_sequence_string_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_bounded_sequence_string_field); - - CompleteStructMember cst_bounded_sequence_enum_field; - cst_bounded_sequence_enum_field.common().member_id(memberId++); - cst_bounded_sequence_enum_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_bounded_sequence_enum_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_bounded_sequence_enum_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_bounded_sequence_enum_field.common().member_flags().IS_OPTIONAL(false); - cst_bounded_sequence_enum_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_bounded_sequence_enum_field.common().member_flags().IS_KEY(false); - cst_bounded_sequence_enum_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_bounded_sequence_enum_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("Color", max_seq_size, true)); - - cst_bounded_sequence_enum_field.detail().name("bounded_sequence_enum_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_bounded_sequence_enum_field); - - CompleteStructMember cst_bounded_sequence_enum2_field; - cst_bounded_sequence_enum2_field.common().member_id(memberId++); - cst_bounded_sequence_enum2_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_bounded_sequence_enum2_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_bounded_sequence_enum2_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_bounded_sequence_enum2_field.common().member_flags().IS_OPTIONAL(false); - cst_bounded_sequence_enum2_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_bounded_sequence_enum2_field.common().member_flags().IS_KEY(false); - cst_bounded_sequence_enum2_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_bounded_sequence_enum2_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("Material", max_seq_size, true)); - - cst_bounded_sequence_enum2_field.detail().name("bounded_sequence_enum2_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_bounded_sequence_enum2_field); - - CompleteStructMember cst_bounded_sequence_struct_field; - cst_bounded_sequence_struct_field.common().member_id(memberId++); - cst_bounded_sequence_struct_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_bounded_sequence_struct_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_bounded_sequence_struct_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_bounded_sequence_struct_field.common().member_flags().IS_OPTIONAL(false); - cst_bounded_sequence_struct_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_bounded_sequence_struct_field.common().member_flags().IS_KEY(false); - cst_bounded_sequence_struct_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_bounded_sequence_struct_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("StructType", max_seq_size, true)); - - cst_bounded_sequence_struct_field.detail().name("bounded_sequence_struct_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_bounded_sequence_struct_field); - - CompleteStructMember cst_unbounded_sequence_char_field; - cst_unbounded_sequence_char_field.common().member_id(memberId++); - cst_unbounded_sequence_char_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_unbounded_sequence_char_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_unbounded_sequence_char_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_unbounded_sequence_char_field.common().member_flags().IS_OPTIONAL(false); - cst_unbounded_sequence_char_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_unbounded_sequence_char_field.common().member_flags().IS_KEY(false); - cst_unbounded_sequence_char_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_unbounded_sequence_char_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("char", 100, true)); - - cst_unbounded_sequence_char_field.detail().name("unbounded_sequence_char_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_unbounded_sequence_char_field); - - CompleteStructMember cst_unbounded_sequence_uint8_field; - cst_unbounded_sequence_uint8_field.common().member_id(memberId++); - cst_unbounded_sequence_uint8_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_unbounded_sequence_uint8_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_unbounded_sequence_uint8_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_unbounded_sequence_uint8_field.common().member_flags().IS_OPTIONAL(false); - cst_unbounded_sequence_uint8_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_unbounded_sequence_uint8_field.common().member_flags().IS_KEY(false); - cst_unbounded_sequence_uint8_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_unbounded_sequence_uint8_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("uint8_t", 100, true)); - - cst_unbounded_sequence_uint8_field.detail().name("unbounded_sequence_uint8_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_unbounded_sequence_uint8_field); - - CompleteStructMember cst_unbounded_sequence_int16_field; - cst_unbounded_sequence_int16_field.common().member_id(memberId++); - cst_unbounded_sequence_int16_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_unbounded_sequence_int16_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_unbounded_sequence_int16_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_unbounded_sequence_int16_field.common().member_flags().IS_OPTIONAL(false); - cst_unbounded_sequence_int16_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_unbounded_sequence_int16_field.common().member_flags().IS_KEY(false); - cst_unbounded_sequence_int16_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_unbounded_sequence_int16_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("int16_t", 100, true)); - - cst_unbounded_sequence_int16_field.detail().name("unbounded_sequence_int16_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_unbounded_sequence_int16_field); - - CompleteStructMember cst_unbounded_sequence_uint16_field; - cst_unbounded_sequence_uint16_field.common().member_id(memberId++); - cst_unbounded_sequence_uint16_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_unbounded_sequence_uint16_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_unbounded_sequence_uint16_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_unbounded_sequence_uint16_field.common().member_flags().IS_OPTIONAL(false); - cst_unbounded_sequence_uint16_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_unbounded_sequence_uint16_field.common().member_flags().IS_KEY(false); - cst_unbounded_sequence_uint16_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_unbounded_sequence_uint16_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("uint16_t", 100, true)); - - cst_unbounded_sequence_uint16_field.detail().name("unbounded_sequence_uint16_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_unbounded_sequence_uint16_field); - - CompleteStructMember cst_unbounded_sequence_int32_field; - cst_unbounded_sequence_int32_field.common().member_id(memberId++); - cst_unbounded_sequence_int32_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_unbounded_sequence_int32_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_unbounded_sequence_int32_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_unbounded_sequence_int32_field.common().member_flags().IS_OPTIONAL(false); - cst_unbounded_sequence_int32_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_unbounded_sequence_int32_field.common().member_flags().IS_KEY(false); - cst_unbounded_sequence_int32_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_unbounded_sequence_int32_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("int32_t", 100, true)); - - cst_unbounded_sequence_int32_field.detail().name("unbounded_sequence_int32_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_unbounded_sequence_int32_field); - - CompleteStructMember cst_unbounded_sequence_uint32_field; - cst_unbounded_sequence_uint32_field.common().member_id(memberId++); - cst_unbounded_sequence_uint32_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_unbounded_sequence_uint32_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_unbounded_sequence_uint32_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_unbounded_sequence_uint32_field.common().member_flags().IS_OPTIONAL(false); - cst_unbounded_sequence_uint32_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_unbounded_sequence_uint32_field.common().member_flags().IS_KEY(false); - cst_unbounded_sequence_uint32_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_unbounded_sequence_uint32_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("uint32_t", 100, true)); - - cst_unbounded_sequence_uint32_field.detail().name("unbounded_sequence_uint32_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_unbounded_sequence_uint32_field); - - CompleteStructMember cst_unbounded_sequence_int64_field; - cst_unbounded_sequence_int64_field.common().member_id(memberId++); - cst_unbounded_sequence_int64_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_unbounded_sequence_int64_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_unbounded_sequence_int64_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_unbounded_sequence_int64_field.common().member_flags().IS_OPTIONAL(false); - cst_unbounded_sequence_int64_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_unbounded_sequence_int64_field.common().member_flags().IS_KEY(false); - cst_unbounded_sequence_int64_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_unbounded_sequence_int64_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("int64_t", 100, true)); - - cst_unbounded_sequence_int64_field.detail().name("unbounded_sequence_int64_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_unbounded_sequence_int64_field); - - CompleteStructMember cst_unbounded_sequence_uint64_field; - cst_unbounded_sequence_uint64_field.common().member_id(memberId++); - cst_unbounded_sequence_uint64_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_unbounded_sequence_uint64_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_unbounded_sequence_uint64_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_unbounded_sequence_uint64_field.common().member_flags().IS_OPTIONAL(false); - cst_unbounded_sequence_uint64_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_unbounded_sequence_uint64_field.common().member_flags().IS_KEY(false); - cst_unbounded_sequence_uint64_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_unbounded_sequence_uint64_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("uint64_t", 100, true)); - - cst_unbounded_sequence_uint64_field.detail().name("unbounded_sequence_uint64_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_unbounded_sequence_uint64_field); - - CompleteStructMember cst_unbounded_sequence_float_field; - cst_unbounded_sequence_float_field.common().member_id(memberId++); - cst_unbounded_sequence_float_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_unbounded_sequence_float_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_unbounded_sequence_float_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_unbounded_sequence_float_field.common().member_flags().IS_OPTIONAL(false); - cst_unbounded_sequence_float_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_unbounded_sequence_float_field.common().member_flags().IS_KEY(false); - cst_unbounded_sequence_float_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_unbounded_sequence_float_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("float", 100, true)); - - cst_unbounded_sequence_float_field.detail().name("unbounded_sequence_float_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_unbounded_sequence_float_field); - - CompleteStructMember cst_unbounded_sequence_double_field; - cst_unbounded_sequence_double_field.common().member_id(memberId++); - cst_unbounded_sequence_double_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_unbounded_sequence_double_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_unbounded_sequence_double_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_unbounded_sequence_double_field.common().member_flags().IS_OPTIONAL(false); - cst_unbounded_sequence_double_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_unbounded_sequence_double_field.common().member_flags().IS_KEY(false); - cst_unbounded_sequence_double_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_unbounded_sequence_double_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("double", 100, true)); - - cst_unbounded_sequence_double_field.detail().name("unbounded_sequence_double_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_unbounded_sequence_double_field); - - CompleteStructMember cst_unbounded_sequence_long_double_field; - cst_unbounded_sequence_long_double_field.common().member_id(memberId++); - cst_unbounded_sequence_long_double_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_unbounded_sequence_long_double_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_unbounded_sequence_long_double_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_unbounded_sequence_long_double_field.common().member_flags().IS_OPTIONAL(false); - cst_unbounded_sequence_long_double_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_unbounded_sequence_long_double_field.common().member_flags().IS_KEY(false); - cst_unbounded_sequence_long_double_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_unbounded_sequence_long_double_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("longdouble", 100, true)); - - cst_unbounded_sequence_long_double_field.detail().name("unbounded_sequence_long_double_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_unbounded_sequence_long_double_field); - - CompleteStructMember cst_unbounded_sequence_bool_field; - cst_unbounded_sequence_bool_field.common().member_id(memberId++); - cst_unbounded_sequence_bool_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_unbounded_sequence_bool_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_unbounded_sequence_bool_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_unbounded_sequence_bool_field.common().member_flags().IS_OPTIONAL(false); - cst_unbounded_sequence_bool_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_unbounded_sequence_bool_field.common().member_flags().IS_KEY(false); - cst_unbounded_sequence_bool_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_unbounded_sequence_bool_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("bool", 100, true)); - - cst_unbounded_sequence_bool_field.detail().name("unbounded_sequence_bool_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_unbounded_sequence_bool_field); - - CompleteStructMember cst_unbounded_sequence_string_field; - cst_unbounded_sequence_string_field.common().member_id(memberId++); - cst_unbounded_sequence_string_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_unbounded_sequence_string_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_unbounded_sequence_string_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_unbounded_sequence_string_field.common().member_flags().IS_OPTIONAL(false); - cst_unbounded_sequence_string_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_unbounded_sequence_string_field.common().member_flags().IS_KEY(false); - cst_unbounded_sequence_string_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_unbounded_sequence_string_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier(TypeNamesGenerator::get_string_type_name(255, false), 100, true)); - - cst_unbounded_sequence_string_field.detail().name("unbounded_sequence_string_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_unbounded_sequence_string_field); - - CompleteStructMember cst_unbounded_sequence_enum_field; - cst_unbounded_sequence_enum_field.common().member_id(memberId++); - cst_unbounded_sequence_enum_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_unbounded_sequence_enum_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_unbounded_sequence_enum_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_unbounded_sequence_enum_field.common().member_flags().IS_OPTIONAL(false); - cst_unbounded_sequence_enum_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_unbounded_sequence_enum_field.common().member_flags().IS_KEY(false); - cst_unbounded_sequence_enum_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_unbounded_sequence_enum_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("Color", 100, true)); - - cst_unbounded_sequence_enum_field.detail().name("unbounded_sequence_enum_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_unbounded_sequence_enum_field); - - CompleteStructMember cst_unbounded_sequence_enum2_field; - cst_unbounded_sequence_enum2_field.common().member_id(memberId++); - cst_unbounded_sequence_enum2_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_unbounded_sequence_enum2_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_unbounded_sequence_enum2_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_unbounded_sequence_enum2_field.common().member_flags().IS_OPTIONAL(false); - cst_unbounded_sequence_enum2_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_unbounded_sequence_enum2_field.common().member_flags().IS_KEY(false); - cst_unbounded_sequence_enum2_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_unbounded_sequence_enum2_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("Material", 100, true)); - - cst_unbounded_sequence_enum2_field.detail().name("unbounded_sequence_enum2_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_unbounded_sequence_enum2_field); - - CompleteStructMember cst_unbounded_sequence_struct_field; - cst_unbounded_sequence_struct_field.common().member_id(memberId++); - cst_unbounded_sequence_struct_field.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_unbounded_sequence_struct_field.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_unbounded_sequence_struct_field.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_unbounded_sequence_struct_field.common().member_flags().IS_OPTIONAL(false); - cst_unbounded_sequence_struct_field.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_unbounded_sequence_struct_field.common().member_flags().IS_KEY(false); - cst_unbounded_sequence_struct_field.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_unbounded_sequence_struct_field.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("StructType", 100, true)); - - cst_unbounded_sequence_struct_field.detail().name("unbounded_sequence_struct_field"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_unbounded_sequence_struct_field); - - - // Header - type_object->complete().struct_type().header().detail().type_name("ContentFilterTestType"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("ContentFilterTestType", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("ContentFilterTestType", true); -} diff --git a/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypeTypeObject.h b/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypeTypeObject.h deleted file mode 100644 index f9d5ec3dc0f..00000000000 --- a/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypeTypeObject.h +++ /dev/null @@ -1,88 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file ContentFilterTestTypeTypeObject.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifndef _FAST_DDS_GENERATED_CONTENTFILTERTESTTYPE_TYPE_OBJECT_H_ -#define _FAST_DDS_GENERATED_CONTENTFILTERTESTTYPE_TYPE_OBJECT_H_ - - -#include -#include - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif -#else -#define eProsima_user_DllExport -#endif - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(ContentFilterTestType_SOURCE) -#define ContentFilterTestType_DllAPI __declspec( dllexport ) -#else -#define ContentFilterTestType_DllAPI __declspec( dllimport ) -#endif // ContentFilterTestType_SOURCE -#else -#define ContentFilterTestType_DllAPI -#endif -#else -#define ContentFilterTestType_DllAPI -#endif // _WIN32 - -using namespace eprosima::fastrtps::types; - -eProsima_user_DllExport void registerContentFilterTestTypeTypes(); - -eProsima_user_DllExport const TypeIdentifier* GetColorIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetColorObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalColorObject(); -eProsima_user_DllExport const TypeObject* GetCompleteColorObject(); - -eProsima_user_DllExport const TypeIdentifier* GetMaterialIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMaterialObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalMaterialObject(); -eProsima_user_DllExport const TypeObject* GetCompleteMaterialObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetStructTypeIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetStructTypeObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalStructTypeObject(); -eProsima_user_DllExport const TypeObject* GetCompleteStructTypeObject(); - - - - - - - - - -eProsima_user_DllExport const TypeIdentifier* GetContentFilterTestTypeIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetContentFilterTestTypeObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalContentFilterTestTypeObject(); -eProsima_user_DllExport const TypeObject* GetCompleteContentFilterTestTypeObject(); - - -#endif // _FAST_DDS_GENERATED_CONTENTFILTERTESTTYPE_TYPE_OBJECT_H_ \ No newline at end of file diff --git a/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypeTypeObjectSupport.cxx b/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypeTypeObjectSupport.cxx new file mode 100644 index 00000000000..02c507f9f65 --- /dev/null +++ b/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypeTypeObjectSupport.cxx @@ -0,0 +1,15231 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file ContentFilterTestTypeTypeObjectSupport.cxx + * Source file containing the implementation to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#include "ContentFilterTestTypeTypeObjectSupport.hpp" + +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include + +#include "ContentFilterTestType.hpp" + + +using namespace eprosima::fastdds::dds::xtypes; + +void register_ContentFilterTestType_type_objects() +{ + static std::once_flag once_flag; + std::call_once(once_flag, []() + { + register_StructType_type_identifier(); + + register_ContentFilterTestType_type_identifier(); + + }); +} + +void register_StructType_type_identifier() +{ + { + StructTypeFlag struct_flags_StructType = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::NOT_APPLIED, + true, false); + ReturnCode_t return_code_StructType; + TypeIdentifierPair type_ids_StructType; + QualifiedTypeName type_name_StructType = "StructType"; + eprosima::fastcdr::optional type_ann_builtin_StructType; + eprosima::fastcdr::optional ann_custom_StructType; + AppliedAnnotationSeq tmp_ann_custom_StructType; + eprosima::fastcdr::optional verbatim_StructType; + if (!tmp_ann_custom_StructType.empty()) + { + ann_custom_StructType = tmp_ann_custom_StructType; + } + + CompleteTypeDetail detail_StructType = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_StructType, ann_custom_StructType, type_name_StructType.to_string()); + CompleteStructHeader header_StructType; + header_StructType = TypeObjectUtils::build_complete_struct_header(TypeIdentifier(), detail_StructType); + CompleteStructMemberSeq member_seq_StructType; + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_char", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "char_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_char_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_char_field; + MemberId member_id_char_field = 0x00000000; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_char_field = TypeObjectUtils::build_common_struct_member(member_id_char_field, member_flags_char_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_char_field = TypeObjectUtils::build_common_struct_member(member_id_char_field, member_flags_char_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure char_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_char_field = "char_field"; + eprosima::fastcdr::optional member_ann_builtin_char_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_char_field = TypeObjectUtils::build_complete_member_detail(name_char_field, member_ann_builtin_char_field, ann_custom_StructType); + CompleteStructMember member_char_field = TypeObjectUtils::build_complete_struct_member(common_char_field, detail_char_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_char_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_byte", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "uint8_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_uint8_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_uint8_field; + MemberId member_id_uint8_field = 0x00000001; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_uint8_field = TypeObjectUtils::build_common_struct_member(member_id_uint8_field, member_flags_uint8_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_uint8_field = TypeObjectUtils::build_common_struct_member(member_id_uint8_field, member_flags_uint8_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure uint8_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_uint8_field = "uint8_field"; + eprosima::fastcdr::optional member_ann_builtin_uint8_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_uint8_field = TypeObjectUtils::build_complete_member_detail(name_uint8_field, member_ann_builtin_uint8_field, ann_custom_StructType); + CompleteStructMember member_uint8_field = TypeObjectUtils::build_complete_struct_member(common_uint8_field, detail_uint8_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_uint8_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_int16_t", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "int16_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_int16_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_int16_field; + MemberId member_id_int16_field = 0x00000002; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_int16_field = TypeObjectUtils::build_common_struct_member(member_id_int16_field, member_flags_int16_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_int16_field = TypeObjectUtils::build_common_struct_member(member_id_int16_field, member_flags_int16_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure int16_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_int16_field = "int16_field"; + eprosima::fastcdr::optional member_ann_builtin_int16_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_int16_field = TypeObjectUtils::build_complete_member_detail(name_int16_field, member_ann_builtin_int16_field, ann_custom_StructType); + CompleteStructMember member_int16_field = TypeObjectUtils::build_complete_struct_member(common_int16_field, detail_int16_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_int16_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_uint16_t", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "uint16_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_uint16_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_uint16_field; + MemberId member_id_uint16_field = 0x00000003; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_uint16_field = TypeObjectUtils::build_common_struct_member(member_id_uint16_field, member_flags_uint16_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_uint16_field = TypeObjectUtils::build_common_struct_member(member_id_uint16_field, member_flags_uint16_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure uint16_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_uint16_field = "uint16_field"; + eprosima::fastcdr::optional member_ann_builtin_uint16_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_uint16_field = TypeObjectUtils::build_complete_member_detail(name_uint16_field, member_ann_builtin_uint16_field, ann_custom_StructType); + CompleteStructMember member_uint16_field = TypeObjectUtils::build_complete_struct_member(common_uint16_field, detail_uint16_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_uint16_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_int32_t", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "int32_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_int32_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_int32_field; + MemberId member_id_int32_field = 0x00000004; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_int32_field = TypeObjectUtils::build_common_struct_member(member_id_int32_field, member_flags_int32_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_int32_field = TypeObjectUtils::build_common_struct_member(member_id_int32_field, member_flags_int32_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure int32_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_int32_field = "int32_field"; + eprosima::fastcdr::optional member_ann_builtin_int32_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_int32_field = TypeObjectUtils::build_complete_member_detail(name_int32_field, member_ann_builtin_int32_field, ann_custom_StructType); + CompleteStructMember member_int32_field = TypeObjectUtils::build_complete_struct_member(common_int32_field, detail_int32_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_int32_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_uint32_t", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "uint32_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_uint32_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_uint32_field; + MemberId member_id_uint32_field = 0x00000005; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_uint32_field = TypeObjectUtils::build_common_struct_member(member_id_uint32_field, member_flags_uint32_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_uint32_field = TypeObjectUtils::build_common_struct_member(member_id_uint32_field, member_flags_uint32_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure uint32_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_uint32_field = "uint32_field"; + eprosima::fastcdr::optional member_ann_builtin_uint32_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_uint32_field = TypeObjectUtils::build_complete_member_detail(name_uint32_field, member_ann_builtin_uint32_field, ann_custom_StructType); + CompleteStructMember member_uint32_field = TypeObjectUtils::build_complete_struct_member(common_uint32_field, detail_uint32_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_uint32_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_int64_t", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "int64_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_int64_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_int64_field; + MemberId member_id_int64_field = 0x00000006; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_int64_field = TypeObjectUtils::build_common_struct_member(member_id_int64_field, member_flags_int64_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_int64_field = TypeObjectUtils::build_common_struct_member(member_id_int64_field, member_flags_int64_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure int64_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_int64_field = "int64_field"; + eprosima::fastcdr::optional member_ann_builtin_int64_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_int64_field = TypeObjectUtils::build_complete_member_detail(name_int64_field, member_ann_builtin_int64_field, ann_custom_StructType); + CompleteStructMember member_int64_field = TypeObjectUtils::build_complete_struct_member(common_int64_field, detail_int64_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_int64_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_uint64_t", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "uint64_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_uint64_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_uint64_field; + MemberId member_id_uint64_field = 0x00000007; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_uint64_field = TypeObjectUtils::build_common_struct_member(member_id_uint64_field, member_flags_uint64_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_uint64_field = TypeObjectUtils::build_common_struct_member(member_id_uint64_field, member_flags_uint64_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure uint64_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_uint64_field = "uint64_field"; + eprosima::fastcdr::optional member_ann_builtin_uint64_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_uint64_field = TypeObjectUtils::build_complete_member_detail(name_uint64_field, member_ann_builtin_uint64_field, ann_custom_StructType); + CompleteStructMember member_uint64_field = TypeObjectUtils::build_complete_struct_member(common_uint64_field, detail_uint64_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_uint64_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_float", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "float_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_float_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_float_field; + MemberId member_id_float_field = 0x00000008; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_float_field = TypeObjectUtils::build_common_struct_member(member_id_float_field, member_flags_float_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_float_field = TypeObjectUtils::build_common_struct_member(member_id_float_field, member_flags_float_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure float_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_float_field = "float_field"; + eprosima::fastcdr::optional member_ann_builtin_float_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_float_field = TypeObjectUtils::build_complete_member_detail(name_float_field, member_ann_builtin_float_field, ann_custom_StructType); + CompleteStructMember member_float_field = TypeObjectUtils::build_complete_struct_member(common_float_field, detail_float_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_float_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_double", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "double_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_double_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_double_field; + MemberId member_id_double_field = 0x00000009; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_double_field = TypeObjectUtils::build_common_struct_member(member_id_double_field, member_flags_double_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_double_field = TypeObjectUtils::build_common_struct_member(member_id_double_field, member_flags_double_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure double_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_double_field = "double_field"; + eprosima::fastcdr::optional member_ann_builtin_double_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_double_field = TypeObjectUtils::build_complete_member_detail(name_double_field, member_ann_builtin_double_field, ann_custom_StructType); + CompleteStructMember member_double_field = TypeObjectUtils::build_complete_struct_member(common_double_field, detail_double_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_double_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_longdouble", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "long_double_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_long_double_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_long_double_field; + MemberId member_id_long_double_field = 0x0000000a; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_long_double_field = TypeObjectUtils::build_common_struct_member(member_id_long_double_field, member_flags_long_double_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_long_double_field = TypeObjectUtils::build_common_struct_member(member_id_long_double_field, member_flags_long_double_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure long_double_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_long_double_field = "long_double_field"; + eprosima::fastcdr::optional member_ann_builtin_long_double_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_long_double_field = TypeObjectUtils::build_complete_member_detail(name_long_double_field, member_ann_builtin_long_double_field, ann_custom_StructType); + CompleteStructMember member_long_double_field = TypeObjectUtils::build_complete_struct_member(common_long_double_field, detail_long_double_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_long_double_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_bool", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "bool_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_bool_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_bool_field; + MemberId member_id_bool_field = 0x0000000b; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_bool_field = TypeObjectUtils::build_common_struct_member(member_id_bool_field, member_flags_bool_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_bool_field = TypeObjectUtils::build_common_struct_member(member_id_bool_field, member_flags_bool_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure bool_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_bool_field = "bool_field"; + eprosima::fastcdr::optional member_ann_builtin_bool_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_bool_field = TypeObjectUtils::build_complete_member_detail(name_bool_field, member_ann_builtin_bool_field, ann_custom_StructType); + CompleteStructMember member_bool_field = TypeObjectUtils::build_complete_struct_member(common_bool_field, detail_bool_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_bool_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_string_unbounded", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + std::string type_id_kind_anonymous_string_unbounded("TI_STRING8_SMALL"); + if (type_id_kind_anonymous_string_unbounded == "TI_STRING8_SMALL") + { + SBound bound = 0; + StringSTypeDefn string_sdefn = TypeObjectUtils::build_string_s_type_defn(bound); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_string_type_identifier(string_sdefn, + "anonymous_string_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else if (type_id_kind_anonymous_string_unbounded == "TI_STRING8_LARGE") + { + LBound bound = 255; + StringLTypeDefn string_ldefn = TypeObjectUtils::build_string_l_type_defn(bound); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_string_type_identifier(string_ldefn, + "anonymous_string_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded: Unknown String kind."); + return; + } + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_string_unbounded", type_ids_StructType); + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded: Given String TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_string_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_string_field; + MemberId member_id_string_field = 0x0000000c; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_string_field = TypeObjectUtils::build_common_struct_member(member_id_string_field, member_flags_string_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_string_field = TypeObjectUtils::build_common_struct_member(member_id_string_field, member_flags_string_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure string_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_string_field = "string_field"; + eprosima::fastcdr::optional member_ann_builtin_string_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_string_field = TypeObjectUtils::build_complete_member_detail(name_string_field, member_ann_builtin_string_field, ann_custom_StructType); + CompleteStructMember member_string_field = TypeObjectUtils::build_complete_struct_member(common_string_field, detail_string_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_string_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "Color", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EnumTypeFlag enum_flags_Color = 0; + BitBound bit_bound_Color = 32; + CommonEnumeratedHeader common_Color = TypeObjectUtils::build_common_enumerated_header(bit_bound_Color); + QualifiedTypeName type_name_Color = "Color"; + eprosima::fastcdr::optional type_ann_builtin_Color; + eprosima::fastcdr::optional ann_custom_Color; + CompleteTypeDetail detail_Color = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_Color, ann_custom_Color, type_name_Color.to_string()); + CompleteEnumeratedHeader header_Color = TypeObjectUtils::build_complete_enumerated_header(common_Color, detail_Color); + CompleteEnumeratedLiteralSeq literal_seq_Color; + { + EnumeratedLiteralFlag flags_RED = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_RED = TypeObjectUtils::build_common_enumerated_literal(0, flags_RED); + eprosima::fastcdr::optional member_ann_builtin_RED; + ann_custom_Color.reset(); + MemberName name_RED = "RED"; + CompleteMemberDetail detail_RED = TypeObjectUtils::build_complete_member_detail(name_RED, member_ann_builtin_RED, ann_custom_Color); + CompleteEnumeratedLiteral literal_RED = TypeObjectUtils::build_complete_enumerated_literal(common_RED, detail_RED); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Color, literal_RED); + } + { + EnumeratedLiteralFlag flags_GREEN = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_GREEN = TypeObjectUtils::build_common_enumerated_literal(1, flags_GREEN); + eprosima::fastcdr::optional member_ann_builtin_GREEN; + ann_custom_Color.reset(); + MemberName name_GREEN = "GREEN"; + CompleteMemberDetail detail_GREEN = TypeObjectUtils::build_complete_member_detail(name_GREEN, member_ann_builtin_GREEN, ann_custom_Color); + CompleteEnumeratedLiteral literal_GREEN = TypeObjectUtils::build_complete_enumerated_literal(common_GREEN, detail_GREEN); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Color, literal_GREEN); + } + { + EnumeratedLiteralFlag flags_BLUE = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_BLUE = TypeObjectUtils::build_common_enumerated_literal(2, flags_BLUE); + eprosima::fastcdr::optional member_ann_builtin_BLUE; + ann_custom_Color.reset(); + MemberName name_BLUE = "BLUE"; + CompleteMemberDetail detail_BLUE = TypeObjectUtils::build_complete_member_detail(name_BLUE, member_ann_builtin_BLUE, ann_custom_Color); + CompleteEnumeratedLiteral literal_BLUE = TypeObjectUtils::build_complete_enumerated_literal(common_BLUE, detail_BLUE); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Color, literal_BLUE); + } + { + EnumeratedLiteralFlag flags_YELLOW = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_YELLOW = TypeObjectUtils::build_common_enumerated_literal(3, flags_YELLOW); + eprosima::fastcdr::optional member_ann_builtin_YELLOW; + ann_custom_Color.reset(); + MemberName name_YELLOW = "YELLOW"; + CompleteMemberDetail detail_YELLOW = TypeObjectUtils::build_complete_member_detail(name_YELLOW, member_ann_builtin_YELLOW, ann_custom_Color); + CompleteEnumeratedLiteral literal_YELLOW = TypeObjectUtils::build_complete_enumerated_literal(common_YELLOW, detail_YELLOW); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Color, literal_YELLOW); + } + { + EnumeratedLiteralFlag flags_MAGENTA = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_MAGENTA = TypeObjectUtils::build_common_enumerated_literal(4, flags_MAGENTA); + eprosima::fastcdr::optional member_ann_builtin_MAGENTA; + ann_custom_Color.reset(); + MemberName name_MAGENTA = "MAGENTA"; + CompleteMemberDetail detail_MAGENTA = TypeObjectUtils::build_complete_member_detail(name_MAGENTA, member_ann_builtin_MAGENTA, ann_custom_Color); + CompleteEnumeratedLiteral literal_MAGENTA = TypeObjectUtils::build_complete_enumerated_literal(common_MAGENTA, detail_MAGENTA); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Color, literal_MAGENTA); + } + CompleteEnumeratedType enumerated_type_Color = TypeObjectUtils::build_complete_enumerated_type(enum_flags_Color, header_Color, + literal_seq_Color); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_enumerated_type_object(enumerated_type_Color, type_name_Color.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Color already registered in TypeObjectRegistry for a different type."); + } + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "Color", type_ids_StructType); + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Color: Given Enum TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_enum_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_enum_field; + MemberId member_id_enum_field = 0x0000000d; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_enum_field = TypeObjectUtils::build_common_struct_member(member_id_enum_field, member_flags_enum_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_enum_field = TypeObjectUtils::build_common_struct_member(member_id_enum_field, member_flags_enum_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure enum_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_enum_field = "enum_field"; + eprosima::fastcdr::optional member_ann_builtin_enum_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_enum_field = TypeObjectUtils::build_complete_member_detail(name_enum_field, member_ann_builtin_enum_field, ann_custom_StructType); + CompleteStructMember member_enum_field = TypeObjectUtils::build_complete_struct_member(common_enum_field, detail_enum_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_enum_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "Material", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EnumTypeFlag enum_flags_Material = 0; + BitBound bit_bound_Material = 32; + CommonEnumeratedHeader common_Material = TypeObjectUtils::build_common_enumerated_header(bit_bound_Material); + QualifiedTypeName type_name_Material = "Material"; + eprosima::fastcdr::optional type_ann_builtin_Material; + eprosima::fastcdr::optional ann_custom_Material; + CompleteTypeDetail detail_Material = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_Material, ann_custom_Material, type_name_Material.to_string()); + CompleteEnumeratedHeader header_Material = TypeObjectUtils::build_complete_enumerated_header(common_Material, detail_Material); + CompleteEnumeratedLiteralSeq literal_seq_Material; + { + EnumeratedLiteralFlag flags_WOOD = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_WOOD = TypeObjectUtils::build_common_enumerated_literal(0, flags_WOOD); + eprosima::fastcdr::optional member_ann_builtin_WOOD; + ann_custom_Material.reset(); + MemberName name_WOOD = "WOOD"; + CompleteMemberDetail detail_WOOD = TypeObjectUtils::build_complete_member_detail(name_WOOD, member_ann_builtin_WOOD, ann_custom_Material); + CompleteEnumeratedLiteral literal_WOOD = TypeObjectUtils::build_complete_enumerated_literal(common_WOOD, detail_WOOD); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Material, literal_WOOD); + } + { + EnumeratedLiteralFlag flags_PLASTIC = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_PLASTIC = TypeObjectUtils::build_common_enumerated_literal(1, flags_PLASTIC); + eprosima::fastcdr::optional member_ann_builtin_PLASTIC; + ann_custom_Material.reset(); + MemberName name_PLASTIC = "PLASTIC"; + CompleteMemberDetail detail_PLASTIC = TypeObjectUtils::build_complete_member_detail(name_PLASTIC, member_ann_builtin_PLASTIC, ann_custom_Material); + CompleteEnumeratedLiteral literal_PLASTIC = TypeObjectUtils::build_complete_enumerated_literal(common_PLASTIC, detail_PLASTIC); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Material, literal_PLASTIC); + } + { + EnumeratedLiteralFlag flags_METAL = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_METAL = TypeObjectUtils::build_common_enumerated_literal(2, flags_METAL); + eprosima::fastcdr::optional member_ann_builtin_METAL; + ann_custom_Material.reset(); + MemberName name_METAL = "METAL"; + CompleteMemberDetail detail_METAL = TypeObjectUtils::build_complete_member_detail(name_METAL, member_ann_builtin_METAL, ann_custom_Material); + CompleteEnumeratedLiteral literal_METAL = TypeObjectUtils::build_complete_enumerated_literal(common_METAL, detail_METAL); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Material, literal_METAL); + } + { + EnumeratedLiteralFlag flags_CONCRETE = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_CONCRETE = TypeObjectUtils::build_common_enumerated_literal(3, flags_CONCRETE); + eprosima::fastcdr::optional member_ann_builtin_CONCRETE; + ann_custom_Material.reset(); + MemberName name_CONCRETE = "CONCRETE"; + CompleteMemberDetail detail_CONCRETE = TypeObjectUtils::build_complete_member_detail(name_CONCRETE, member_ann_builtin_CONCRETE, ann_custom_Material); + CompleteEnumeratedLiteral literal_CONCRETE = TypeObjectUtils::build_complete_enumerated_literal(common_CONCRETE, detail_CONCRETE); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Material, literal_CONCRETE); + } + { + EnumeratedLiteralFlag flags_STONE = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_STONE = TypeObjectUtils::build_common_enumerated_literal(4, flags_STONE); + eprosima::fastcdr::optional member_ann_builtin_STONE; + ann_custom_Material.reset(); + MemberName name_STONE = "STONE"; + CompleteMemberDetail detail_STONE = TypeObjectUtils::build_complete_member_detail(name_STONE, member_ann_builtin_STONE, ann_custom_Material); + CompleteEnumeratedLiteral literal_STONE = TypeObjectUtils::build_complete_enumerated_literal(common_STONE, detail_STONE); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Material, literal_STONE); + } + CompleteEnumeratedType enumerated_type_Material = TypeObjectUtils::build_complete_enumerated_type(enum_flags_Material, header_Material, + literal_seq_Material); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_enumerated_type_object(enumerated_type_Material, type_name_Material.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Material already registered in TypeObjectRegistry for a different type."); + } + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "Material", type_ids_StructType); + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Material: Given Enum TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_enum2_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_enum2_field; + MemberId member_id_enum2_field = 0x0000000e; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_enum2_field = TypeObjectUtils::build_common_struct_member(member_id_enum2_field, member_flags_enum2_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_enum2_field = TypeObjectUtils::build_common_struct_member(member_id_enum2_field, member_flags_enum2_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure enum2_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_enum2_field = "enum2_field"; + eprosima::fastcdr::optional member_ann_builtin_enum2_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_enum2_field = TypeObjectUtils::build_complete_member_detail(name_enum2_field, member_ann_builtin_enum2_field, ann_custom_StructType); + CompleteStructMember member_enum2_field = TypeObjectUtils::build_complete_struct_member(common_enum2_field, detail_enum2_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_enum2_field); + } + CompleteStructType struct_type_StructType = TypeObjectUtils::build_complete_struct_type(struct_flags_StructType, header_StructType, member_seq_StructType); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_struct_type_object(struct_type_StructType, type_name_StructType.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "StructType already registered in TypeObjectRegistry for a different type."); + } + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "StructType", type_ids_StructType); + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "StructType: Given Struct TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } +} +void register_ContentFilterTestType_type_identifier() +{ + { + StructTypeFlag struct_flags_ContentFilterTestType = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::NOT_APPLIED, + false, false); + ReturnCode_t return_code_ContentFilterTestType; + TypeIdentifierPair type_ids_ContentFilterTestType; + QualifiedTypeName type_name_ContentFilterTestType = "ContentFilterTestType"; + eprosima::fastcdr::optional type_ann_builtin_ContentFilterTestType; + eprosima::fastcdr::optional ann_custom_ContentFilterTestType; + CompleteTypeDetail detail_ContentFilterTestType = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_ContentFilterTestType, ann_custom_ContentFilterTestType, type_name_ContentFilterTestType.to_string()); + CompleteStructHeader header_ContentFilterTestType; + header_ContentFilterTestType = TypeObjectUtils::build_complete_struct_header(TypeIdentifier(), detail_ContentFilterTestType); + CompleteStructMemberSeq member_seq_ContentFilterTestType; + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_char", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "char_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_char_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_char_field; + MemberId member_id_char_field = 0x00000000; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_char_field = TypeObjectUtils::build_common_struct_member(member_id_char_field, member_flags_char_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_char_field = TypeObjectUtils::build_common_struct_member(member_id_char_field, member_flags_char_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure char_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_char_field = "char_field"; + eprosima::fastcdr::optional member_ann_builtin_char_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_char_field = TypeObjectUtils::build_complete_member_detail(name_char_field, member_ann_builtin_char_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_char_field = TypeObjectUtils::build_complete_struct_member(common_char_field, detail_char_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_char_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_byte", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "uint8_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_uint8_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_uint8_field; + MemberId member_id_uint8_field = 0x00000001; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_uint8_field = TypeObjectUtils::build_common_struct_member(member_id_uint8_field, member_flags_uint8_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_uint8_field = TypeObjectUtils::build_common_struct_member(member_id_uint8_field, member_flags_uint8_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure uint8_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_uint8_field = "uint8_field"; + eprosima::fastcdr::optional member_ann_builtin_uint8_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_uint8_field = TypeObjectUtils::build_complete_member_detail(name_uint8_field, member_ann_builtin_uint8_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_uint8_field = TypeObjectUtils::build_complete_struct_member(common_uint8_field, detail_uint8_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_uint8_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_int16_t", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "int16_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_int16_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_int16_field; + MemberId member_id_int16_field = 0x00000002; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_int16_field = TypeObjectUtils::build_common_struct_member(member_id_int16_field, member_flags_int16_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_int16_field = TypeObjectUtils::build_common_struct_member(member_id_int16_field, member_flags_int16_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure int16_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_int16_field = "int16_field"; + eprosima::fastcdr::optional member_ann_builtin_int16_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_int16_field = TypeObjectUtils::build_complete_member_detail(name_int16_field, member_ann_builtin_int16_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_int16_field = TypeObjectUtils::build_complete_struct_member(common_int16_field, detail_int16_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_int16_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_uint16_t", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "uint16_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_uint16_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_uint16_field; + MemberId member_id_uint16_field = 0x00000003; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_uint16_field = TypeObjectUtils::build_common_struct_member(member_id_uint16_field, member_flags_uint16_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_uint16_field = TypeObjectUtils::build_common_struct_member(member_id_uint16_field, member_flags_uint16_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure uint16_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_uint16_field = "uint16_field"; + eprosima::fastcdr::optional member_ann_builtin_uint16_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_uint16_field = TypeObjectUtils::build_complete_member_detail(name_uint16_field, member_ann_builtin_uint16_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_uint16_field = TypeObjectUtils::build_complete_struct_member(common_uint16_field, detail_uint16_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_uint16_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_int32_t", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "int32_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_int32_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_int32_field; + MemberId member_id_int32_field = 0x00000004; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_int32_field = TypeObjectUtils::build_common_struct_member(member_id_int32_field, member_flags_int32_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_int32_field = TypeObjectUtils::build_common_struct_member(member_id_int32_field, member_flags_int32_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure int32_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_int32_field = "int32_field"; + eprosima::fastcdr::optional member_ann_builtin_int32_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_int32_field = TypeObjectUtils::build_complete_member_detail(name_int32_field, member_ann_builtin_int32_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_int32_field = TypeObjectUtils::build_complete_struct_member(common_int32_field, detail_int32_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_int32_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_uint32_t", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "uint32_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_uint32_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_uint32_field; + MemberId member_id_uint32_field = 0x00000005; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_uint32_field = TypeObjectUtils::build_common_struct_member(member_id_uint32_field, member_flags_uint32_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_uint32_field = TypeObjectUtils::build_common_struct_member(member_id_uint32_field, member_flags_uint32_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure uint32_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_uint32_field = "uint32_field"; + eprosima::fastcdr::optional member_ann_builtin_uint32_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_uint32_field = TypeObjectUtils::build_complete_member_detail(name_uint32_field, member_ann_builtin_uint32_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_uint32_field = TypeObjectUtils::build_complete_struct_member(common_uint32_field, detail_uint32_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_uint32_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_int64_t", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "int64_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_int64_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_int64_field; + MemberId member_id_int64_field = 0x00000006; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_int64_field = TypeObjectUtils::build_common_struct_member(member_id_int64_field, member_flags_int64_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_int64_field = TypeObjectUtils::build_common_struct_member(member_id_int64_field, member_flags_int64_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure int64_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_int64_field = "int64_field"; + eprosima::fastcdr::optional member_ann_builtin_int64_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_int64_field = TypeObjectUtils::build_complete_member_detail(name_int64_field, member_ann_builtin_int64_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_int64_field = TypeObjectUtils::build_complete_struct_member(common_int64_field, detail_int64_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_int64_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_uint64_t", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "uint64_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_uint64_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_uint64_field; + MemberId member_id_uint64_field = 0x00000007; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_uint64_field = TypeObjectUtils::build_common_struct_member(member_id_uint64_field, member_flags_uint64_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_uint64_field = TypeObjectUtils::build_common_struct_member(member_id_uint64_field, member_flags_uint64_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure uint64_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_uint64_field = "uint64_field"; + eprosima::fastcdr::optional member_ann_builtin_uint64_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_uint64_field = TypeObjectUtils::build_complete_member_detail(name_uint64_field, member_ann_builtin_uint64_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_uint64_field = TypeObjectUtils::build_complete_struct_member(common_uint64_field, detail_uint64_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_uint64_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_float", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "float_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_float_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_float_field; + MemberId member_id_float_field = 0x00000008; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_float_field = TypeObjectUtils::build_common_struct_member(member_id_float_field, member_flags_float_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_float_field = TypeObjectUtils::build_common_struct_member(member_id_float_field, member_flags_float_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure float_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_float_field = "float_field"; + eprosima::fastcdr::optional member_ann_builtin_float_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_float_field = TypeObjectUtils::build_complete_member_detail(name_float_field, member_ann_builtin_float_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_float_field = TypeObjectUtils::build_complete_struct_member(common_float_field, detail_float_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_float_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_double", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "double_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_double_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_double_field; + MemberId member_id_double_field = 0x00000009; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_double_field = TypeObjectUtils::build_common_struct_member(member_id_double_field, member_flags_double_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_double_field = TypeObjectUtils::build_common_struct_member(member_id_double_field, member_flags_double_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure double_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_double_field = "double_field"; + eprosima::fastcdr::optional member_ann_builtin_double_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_double_field = TypeObjectUtils::build_complete_member_detail(name_double_field, member_ann_builtin_double_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_double_field = TypeObjectUtils::build_complete_struct_member(common_double_field, detail_double_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_double_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_longdouble", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "long_double_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_long_double_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_long_double_field; + MemberId member_id_long_double_field = 0x0000000a; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_long_double_field = TypeObjectUtils::build_common_struct_member(member_id_long_double_field, member_flags_long_double_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_long_double_field = TypeObjectUtils::build_common_struct_member(member_id_long_double_field, member_flags_long_double_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure long_double_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_long_double_field = "long_double_field"; + eprosima::fastcdr::optional member_ann_builtin_long_double_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_long_double_field = TypeObjectUtils::build_complete_member_detail(name_long_double_field, member_ann_builtin_long_double_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_long_double_field = TypeObjectUtils::build_complete_struct_member(common_long_double_field, detail_long_double_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_long_double_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_bool", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "bool_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_bool_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_bool_field; + MemberId member_id_bool_field = 0x0000000b; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_bool_field = TypeObjectUtils::build_common_struct_member(member_id_bool_field, member_flags_bool_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_bool_field = TypeObjectUtils::build_common_struct_member(member_id_bool_field, member_flags_bool_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure bool_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_bool_field = "bool_field"; + eprosima::fastcdr::optional member_ann_builtin_bool_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_bool_field = TypeObjectUtils::build_complete_member_detail(name_bool_field, member_ann_builtin_bool_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_bool_field = TypeObjectUtils::build_complete_struct_member(common_bool_field, detail_bool_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_bool_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_string_unbounded", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + std::string type_id_kind_anonymous_string_unbounded("TI_STRING8_SMALL"); + if (type_id_kind_anonymous_string_unbounded == "TI_STRING8_SMALL") + { + SBound bound = 0; + StringSTypeDefn string_sdefn = TypeObjectUtils::build_string_s_type_defn(bound); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_string_type_identifier(string_sdefn, + "anonymous_string_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else if (type_id_kind_anonymous_string_unbounded == "TI_STRING8_LARGE") + { + LBound bound = 255; + StringLTypeDefn string_ldefn = TypeObjectUtils::build_string_l_type_defn(bound); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_string_type_identifier(string_ldefn, + "anonymous_string_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded: Unknown String kind."); + return; + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_string_unbounded", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded: Given String TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_string_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_string_field; + MemberId member_id_string_field = 0x0000000c; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_string_field = TypeObjectUtils::build_common_struct_member(member_id_string_field, member_flags_string_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_string_field = TypeObjectUtils::build_common_struct_member(member_id_string_field, member_flags_string_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure string_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_string_field = "string_field"; + eprosima::fastcdr::optional member_ann_builtin_string_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_string_field = TypeObjectUtils::build_complete_member_detail(name_string_field, member_ann_builtin_string_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_string_field = TypeObjectUtils::build_complete_struct_member(common_string_field, detail_string_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_string_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "Color", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EnumTypeFlag enum_flags_Color = 0; + BitBound bit_bound_Color = 32; + CommonEnumeratedHeader common_Color = TypeObjectUtils::build_common_enumerated_header(bit_bound_Color); + QualifiedTypeName type_name_Color = "Color"; + eprosima::fastcdr::optional type_ann_builtin_Color; + eprosima::fastcdr::optional ann_custom_Color; + CompleteTypeDetail detail_Color = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_Color, ann_custom_Color, type_name_Color.to_string()); + CompleteEnumeratedHeader header_Color = TypeObjectUtils::build_complete_enumerated_header(common_Color, detail_Color); + CompleteEnumeratedLiteralSeq literal_seq_Color; + { + EnumeratedLiteralFlag flags_RED = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_RED = TypeObjectUtils::build_common_enumerated_literal(0, flags_RED); + eprosima::fastcdr::optional member_ann_builtin_RED; + ann_custom_Color.reset(); + MemberName name_RED = "RED"; + CompleteMemberDetail detail_RED = TypeObjectUtils::build_complete_member_detail(name_RED, member_ann_builtin_RED, ann_custom_Color); + CompleteEnumeratedLiteral literal_RED = TypeObjectUtils::build_complete_enumerated_literal(common_RED, detail_RED); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Color, literal_RED); + } + { + EnumeratedLiteralFlag flags_GREEN = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_GREEN = TypeObjectUtils::build_common_enumerated_literal(1, flags_GREEN); + eprosima::fastcdr::optional member_ann_builtin_GREEN; + ann_custom_Color.reset(); + MemberName name_GREEN = "GREEN"; + CompleteMemberDetail detail_GREEN = TypeObjectUtils::build_complete_member_detail(name_GREEN, member_ann_builtin_GREEN, ann_custom_Color); + CompleteEnumeratedLiteral literal_GREEN = TypeObjectUtils::build_complete_enumerated_literal(common_GREEN, detail_GREEN); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Color, literal_GREEN); + } + { + EnumeratedLiteralFlag flags_BLUE = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_BLUE = TypeObjectUtils::build_common_enumerated_literal(2, flags_BLUE); + eprosima::fastcdr::optional member_ann_builtin_BLUE; + ann_custom_Color.reset(); + MemberName name_BLUE = "BLUE"; + CompleteMemberDetail detail_BLUE = TypeObjectUtils::build_complete_member_detail(name_BLUE, member_ann_builtin_BLUE, ann_custom_Color); + CompleteEnumeratedLiteral literal_BLUE = TypeObjectUtils::build_complete_enumerated_literal(common_BLUE, detail_BLUE); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Color, literal_BLUE); + } + { + EnumeratedLiteralFlag flags_YELLOW = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_YELLOW = TypeObjectUtils::build_common_enumerated_literal(3, flags_YELLOW); + eprosima::fastcdr::optional member_ann_builtin_YELLOW; + ann_custom_Color.reset(); + MemberName name_YELLOW = "YELLOW"; + CompleteMemberDetail detail_YELLOW = TypeObjectUtils::build_complete_member_detail(name_YELLOW, member_ann_builtin_YELLOW, ann_custom_Color); + CompleteEnumeratedLiteral literal_YELLOW = TypeObjectUtils::build_complete_enumerated_literal(common_YELLOW, detail_YELLOW); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Color, literal_YELLOW); + } + { + EnumeratedLiteralFlag flags_MAGENTA = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_MAGENTA = TypeObjectUtils::build_common_enumerated_literal(4, flags_MAGENTA); + eprosima::fastcdr::optional member_ann_builtin_MAGENTA; + ann_custom_Color.reset(); + MemberName name_MAGENTA = "MAGENTA"; + CompleteMemberDetail detail_MAGENTA = TypeObjectUtils::build_complete_member_detail(name_MAGENTA, member_ann_builtin_MAGENTA, ann_custom_Color); + CompleteEnumeratedLiteral literal_MAGENTA = TypeObjectUtils::build_complete_enumerated_literal(common_MAGENTA, detail_MAGENTA); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Color, literal_MAGENTA); + } + CompleteEnumeratedType enumerated_type_Color = TypeObjectUtils::build_complete_enumerated_type(enum_flags_Color, header_Color, + literal_seq_Color); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_enumerated_type_object(enumerated_type_Color, type_name_Color.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Color already registered in TypeObjectRegistry for a different type."); + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "Color", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Color: Given Enum TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_enum_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_enum_field; + MemberId member_id_enum_field = 0x0000000d; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_enum_field = TypeObjectUtils::build_common_struct_member(member_id_enum_field, member_flags_enum_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_enum_field = TypeObjectUtils::build_common_struct_member(member_id_enum_field, member_flags_enum_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure enum_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_enum_field = "enum_field"; + eprosima::fastcdr::optional member_ann_builtin_enum_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_enum_field = TypeObjectUtils::build_complete_member_detail(name_enum_field, member_ann_builtin_enum_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_enum_field = TypeObjectUtils::build_complete_struct_member(common_enum_field, detail_enum_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_enum_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "Material", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EnumTypeFlag enum_flags_Material = 0; + BitBound bit_bound_Material = 32; + CommonEnumeratedHeader common_Material = TypeObjectUtils::build_common_enumerated_header(bit_bound_Material); + QualifiedTypeName type_name_Material = "Material"; + eprosima::fastcdr::optional type_ann_builtin_Material; + eprosima::fastcdr::optional ann_custom_Material; + CompleteTypeDetail detail_Material = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_Material, ann_custom_Material, type_name_Material.to_string()); + CompleteEnumeratedHeader header_Material = TypeObjectUtils::build_complete_enumerated_header(common_Material, detail_Material); + CompleteEnumeratedLiteralSeq literal_seq_Material; + { + EnumeratedLiteralFlag flags_WOOD = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_WOOD = TypeObjectUtils::build_common_enumerated_literal(0, flags_WOOD); + eprosima::fastcdr::optional member_ann_builtin_WOOD; + ann_custom_Material.reset(); + MemberName name_WOOD = "WOOD"; + CompleteMemberDetail detail_WOOD = TypeObjectUtils::build_complete_member_detail(name_WOOD, member_ann_builtin_WOOD, ann_custom_Material); + CompleteEnumeratedLiteral literal_WOOD = TypeObjectUtils::build_complete_enumerated_literal(common_WOOD, detail_WOOD); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Material, literal_WOOD); + } + { + EnumeratedLiteralFlag flags_PLASTIC = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_PLASTIC = TypeObjectUtils::build_common_enumerated_literal(1, flags_PLASTIC); + eprosima::fastcdr::optional member_ann_builtin_PLASTIC; + ann_custom_Material.reset(); + MemberName name_PLASTIC = "PLASTIC"; + CompleteMemberDetail detail_PLASTIC = TypeObjectUtils::build_complete_member_detail(name_PLASTIC, member_ann_builtin_PLASTIC, ann_custom_Material); + CompleteEnumeratedLiteral literal_PLASTIC = TypeObjectUtils::build_complete_enumerated_literal(common_PLASTIC, detail_PLASTIC); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Material, literal_PLASTIC); + } + { + EnumeratedLiteralFlag flags_METAL = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_METAL = TypeObjectUtils::build_common_enumerated_literal(2, flags_METAL); + eprosima::fastcdr::optional member_ann_builtin_METAL; + ann_custom_Material.reset(); + MemberName name_METAL = "METAL"; + CompleteMemberDetail detail_METAL = TypeObjectUtils::build_complete_member_detail(name_METAL, member_ann_builtin_METAL, ann_custom_Material); + CompleteEnumeratedLiteral literal_METAL = TypeObjectUtils::build_complete_enumerated_literal(common_METAL, detail_METAL); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Material, literal_METAL); + } + { + EnumeratedLiteralFlag flags_CONCRETE = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_CONCRETE = TypeObjectUtils::build_common_enumerated_literal(3, flags_CONCRETE); + eprosima::fastcdr::optional member_ann_builtin_CONCRETE; + ann_custom_Material.reset(); + MemberName name_CONCRETE = "CONCRETE"; + CompleteMemberDetail detail_CONCRETE = TypeObjectUtils::build_complete_member_detail(name_CONCRETE, member_ann_builtin_CONCRETE, ann_custom_Material); + CompleteEnumeratedLiteral literal_CONCRETE = TypeObjectUtils::build_complete_enumerated_literal(common_CONCRETE, detail_CONCRETE); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Material, literal_CONCRETE); + } + { + EnumeratedLiteralFlag flags_STONE = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_STONE = TypeObjectUtils::build_common_enumerated_literal(4, flags_STONE); + eprosima::fastcdr::optional member_ann_builtin_STONE; + ann_custom_Material.reset(); + MemberName name_STONE = "STONE"; + CompleteMemberDetail detail_STONE = TypeObjectUtils::build_complete_member_detail(name_STONE, member_ann_builtin_STONE, ann_custom_Material); + CompleteEnumeratedLiteral literal_STONE = TypeObjectUtils::build_complete_enumerated_literal(common_STONE, detail_STONE); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Material, literal_STONE); + } + CompleteEnumeratedType enumerated_type_Material = TypeObjectUtils::build_complete_enumerated_type(enum_flags_Material, header_Material, + literal_seq_Material); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_enumerated_type_object(enumerated_type_Material, type_name_Material.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Material already registered in TypeObjectRegistry for a different type."); + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "Material", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Material: Given Enum TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_enum2_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_enum2_field; + MemberId member_id_enum2_field = 0x0000000e; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_enum2_field = TypeObjectUtils::build_common_struct_member(member_id_enum2_field, member_flags_enum2_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_enum2_field = TypeObjectUtils::build_common_struct_member(member_id_enum2_field, member_flags_enum2_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure enum2_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_enum2_field = "enum2_field"; + eprosima::fastcdr::optional member_ann_builtin_enum2_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_enum2_field = TypeObjectUtils::build_complete_member_detail(name_enum2_field, member_ann_builtin_enum2_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_enum2_field = TypeObjectUtils::build_complete_struct_member(common_enum2_field, detail_enum2_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_enum2_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "StructType", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + { + StructTypeFlag struct_flags_StructType = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::NOT_APPLIED, + true, false); + ReturnCode_t return_code_StructType; + TypeIdentifierPair type_ids_StructType; + QualifiedTypeName type_name_StructType = "StructType"; + eprosima::fastcdr::optional type_ann_builtin_StructType; + eprosima::fastcdr::optional ann_custom_StructType; + AppliedAnnotationSeq tmp_ann_custom_StructType; + eprosima::fastcdr::optional verbatim_StructType; + if (!tmp_ann_custom_StructType.empty()) + { + ann_custom_StructType = tmp_ann_custom_StructType; + } + + CompleteTypeDetail detail_StructType = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_StructType, ann_custom_StructType, type_name_StructType.to_string()); + CompleteStructHeader header_StructType; + header_StructType = TypeObjectUtils::build_complete_struct_header(TypeIdentifier(), detail_StructType); + CompleteStructMemberSeq member_seq_StructType; + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_char", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "char_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_char_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_char_field; + MemberId member_id_char_field = 0x00000000; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_char_field = TypeObjectUtils::build_common_struct_member(member_id_char_field, member_flags_char_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_char_field = TypeObjectUtils::build_common_struct_member(member_id_char_field, member_flags_char_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure char_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_char_field = "char_field"; + eprosima::fastcdr::optional member_ann_builtin_char_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_char_field = TypeObjectUtils::build_complete_member_detail(name_char_field, member_ann_builtin_char_field, ann_custom_StructType); + CompleteStructMember member_char_field = TypeObjectUtils::build_complete_struct_member(common_char_field, detail_char_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_char_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_byte", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "uint8_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_uint8_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_uint8_field; + MemberId member_id_uint8_field = 0x00000001; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_uint8_field = TypeObjectUtils::build_common_struct_member(member_id_uint8_field, member_flags_uint8_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_uint8_field = TypeObjectUtils::build_common_struct_member(member_id_uint8_field, member_flags_uint8_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure uint8_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_uint8_field = "uint8_field"; + eprosima::fastcdr::optional member_ann_builtin_uint8_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_uint8_field = TypeObjectUtils::build_complete_member_detail(name_uint8_field, member_ann_builtin_uint8_field, ann_custom_StructType); + CompleteStructMember member_uint8_field = TypeObjectUtils::build_complete_struct_member(common_uint8_field, detail_uint8_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_uint8_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_int16_t", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "int16_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_int16_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_int16_field; + MemberId member_id_int16_field = 0x00000002; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_int16_field = TypeObjectUtils::build_common_struct_member(member_id_int16_field, member_flags_int16_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_int16_field = TypeObjectUtils::build_common_struct_member(member_id_int16_field, member_flags_int16_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure int16_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_int16_field = "int16_field"; + eprosima::fastcdr::optional member_ann_builtin_int16_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_int16_field = TypeObjectUtils::build_complete_member_detail(name_int16_field, member_ann_builtin_int16_field, ann_custom_StructType); + CompleteStructMember member_int16_field = TypeObjectUtils::build_complete_struct_member(common_int16_field, detail_int16_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_int16_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_uint16_t", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "uint16_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_uint16_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_uint16_field; + MemberId member_id_uint16_field = 0x00000003; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_uint16_field = TypeObjectUtils::build_common_struct_member(member_id_uint16_field, member_flags_uint16_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_uint16_field = TypeObjectUtils::build_common_struct_member(member_id_uint16_field, member_flags_uint16_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure uint16_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_uint16_field = "uint16_field"; + eprosima::fastcdr::optional member_ann_builtin_uint16_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_uint16_field = TypeObjectUtils::build_complete_member_detail(name_uint16_field, member_ann_builtin_uint16_field, ann_custom_StructType); + CompleteStructMember member_uint16_field = TypeObjectUtils::build_complete_struct_member(common_uint16_field, detail_uint16_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_uint16_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_int32_t", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "int32_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_int32_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_int32_field; + MemberId member_id_int32_field = 0x00000004; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_int32_field = TypeObjectUtils::build_common_struct_member(member_id_int32_field, member_flags_int32_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_int32_field = TypeObjectUtils::build_common_struct_member(member_id_int32_field, member_flags_int32_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure int32_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_int32_field = "int32_field"; + eprosima::fastcdr::optional member_ann_builtin_int32_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_int32_field = TypeObjectUtils::build_complete_member_detail(name_int32_field, member_ann_builtin_int32_field, ann_custom_StructType); + CompleteStructMember member_int32_field = TypeObjectUtils::build_complete_struct_member(common_int32_field, detail_int32_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_int32_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_uint32_t", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "uint32_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_uint32_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_uint32_field; + MemberId member_id_uint32_field = 0x00000005; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_uint32_field = TypeObjectUtils::build_common_struct_member(member_id_uint32_field, member_flags_uint32_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_uint32_field = TypeObjectUtils::build_common_struct_member(member_id_uint32_field, member_flags_uint32_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure uint32_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_uint32_field = "uint32_field"; + eprosima::fastcdr::optional member_ann_builtin_uint32_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_uint32_field = TypeObjectUtils::build_complete_member_detail(name_uint32_field, member_ann_builtin_uint32_field, ann_custom_StructType); + CompleteStructMember member_uint32_field = TypeObjectUtils::build_complete_struct_member(common_uint32_field, detail_uint32_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_uint32_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_int64_t", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "int64_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_int64_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_int64_field; + MemberId member_id_int64_field = 0x00000006; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_int64_field = TypeObjectUtils::build_common_struct_member(member_id_int64_field, member_flags_int64_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_int64_field = TypeObjectUtils::build_common_struct_member(member_id_int64_field, member_flags_int64_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure int64_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_int64_field = "int64_field"; + eprosima::fastcdr::optional member_ann_builtin_int64_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_int64_field = TypeObjectUtils::build_complete_member_detail(name_int64_field, member_ann_builtin_int64_field, ann_custom_StructType); + CompleteStructMember member_int64_field = TypeObjectUtils::build_complete_struct_member(common_int64_field, detail_int64_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_int64_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_uint64_t", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "uint64_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_uint64_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_uint64_field; + MemberId member_id_uint64_field = 0x00000007; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_uint64_field = TypeObjectUtils::build_common_struct_member(member_id_uint64_field, member_flags_uint64_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_uint64_field = TypeObjectUtils::build_common_struct_member(member_id_uint64_field, member_flags_uint64_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure uint64_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_uint64_field = "uint64_field"; + eprosima::fastcdr::optional member_ann_builtin_uint64_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_uint64_field = TypeObjectUtils::build_complete_member_detail(name_uint64_field, member_ann_builtin_uint64_field, ann_custom_StructType); + CompleteStructMember member_uint64_field = TypeObjectUtils::build_complete_struct_member(common_uint64_field, detail_uint64_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_uint64_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_float", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "float_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_float_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_float_field; + MemberId member_id_float_field = 0x00000008; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_float_field = TypeObjectUtils::build_common_struct_member(member_id_float_field, member_flags_float_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_float_field = TypeObjectUtils::build_common_struct_member(member_id_float_field, member_flags_float_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure float_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_float_field = "float_field"; + eprosima::fastcdr::optional member_ann_builtin_float_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_float_field = TypeObjectUtils::build_complete_member_detail(name_float_field, member_ann_builtin_float_field, ann_custom_StructType); + CompleteStructMember member_float_field = TypeObjectUtils::build_complete_struct_member(common_float_field, detail_float_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_float_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_double", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "double_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_double_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_double_field; + MemberId member_id_double_field = 0x00000009; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_double_field = TypeObjectUtils::build_common_struct_member(member_id_double_field, member_flags_double_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_double_field = TypeObjectUtils::build_common_struct_member(member_id_double_field, member_flags_double_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure double_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_double_field = "double_field"; + eprosima::fastcdr::optional member_ann_builtin_double_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_double_field = TypeObjectUtils::build_complete_member_detail(name_double_field, member_ann_builtin_double_field, ann_custom_StructType); + CompleteStructMember member_double_field = TypeObjectUtils::build_complete_struct_member(common_double_field, detail_double_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_double_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_longdouble", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "long_double_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_long_double_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_long_double_field; + MemberId member_id_long_double_field = 0x0000000a; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_long_double_field = TypeObjectUtils::build_common_struct_member(member_id_long_double_field, member_flags_long_double_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_long_double_field = TypeObjectUtils::build_common_struct_member(member_id_long_double_field, member_flags_long_double_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure long_double_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_long_double_field = "long_double_field"; + eprosima::fastcdr::optional member_ann_builtin_long_double_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_long_double_field = TypeObjectUtils::build_complete_member_detail(name_long_double_field, member_ann_builtin_long_double_field, ann_custom_StructType); + CompleteStructMember member_long_double_field = TypeObjectUtils::build_complete_struct_member(common_long_double_field, detail_long_double_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_long_double_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_bool", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "bool_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_bool_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_bool_field; + MemberId member_id_bool_field = 0x0000000b; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_bool_field = TypeObjectUtils::build_common_struct_member(member_id_bool_field, member_flags_bool_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_bool_field = TypeObjectUtils::build_common_struct_member(member_id_bool_field, member_flags_bool_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure bool_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_bool_field = "bool_field"; + eprosima::fastcdr::optional member_ann_builtin_bool_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_bool_field = TypeObjectUtils::build_complete_member_detail(name_bool_field, member_ann_builtin_bool_field, ann_custom_StructType); + CompleteStructMember member_bool_field = TypeObjectUtils::build_complete_struct_member(common_bool_field, detail_bool_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_bool_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_string_unbounded", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + std::string type_id_kind_anonymous_string_unbounded("TI_STRING8_SMALL"); + if (type_id_kind_anonymous_string_unbounded == "TI_STRING8_SMALL") + { + SBound bound = 0; + StringSTypeDefn string_sdefn = TypeObjectUtils::build_string_s_type_defn(bound); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_string_type_identifier(string_sdefn, + "anonymous_string_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else if (type_id_kind_anonymous_string_unbounded == "TI_STRING8_LARGE") + { + LBound bound = 255; + StringLTypeDefn string_ldefn = TypeObjectUtils::build_string_l_type_defn(bound); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_string_type_identifier(string_ldefn, + "anonymous_string_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded: Unknown String kind."); + return; + } + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_string_unbounded", type_ids_StructType); + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded: Given String TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_string_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_string_field; + MemberId member_id_string_field = 0x0000000c; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_string_field = TypeObjectUtils::build_common_struct_member(member_id_string_field, member_flags_string_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_string_field = TypeObjectUtils::build_common_struct_member(member_id_string_field, member_flags_string_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure string_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_string_field = "string_field"; + eprosima::fastcdr::optional member_ann_builtin_string_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_string_field = TypeObjectUtils::build_complete_member_detail(name_string_field, member_ann_builtin_string_field, ann_custom_StructType); + CompleteStructMember member_string_field = TypeObjectUtils::build_complete_struct_member(common_string_field, detail_string_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_string_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "Color", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EnumTypeFlag enum_flags_Color = 0; + BitBound bit_bound_Color = 32; + CommonEnumeratedHeader common_Color = TypeObjectUtils::build_common_enumerated_header(bit_bound_Color); + QualifiedTypeName type_name_Color = "Color"; + eprosima::fastcdr::optional type_ann_builtin_Color; + eprosima::fastcdr::optional ann_custom_Color; + CompleteTypeDetail detail_Color = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_Color, ann_custom_Color, type_name_Color.to_string()); + CompleteEnumeratedHeader header_Color = TypeObjectUtils::build_complete_enumerated_header(common_Color, detail_Color); + CompleteEnumeratedLiteralSeq literal_seq_Color; + { + EnumeratedLiteralFlag flags_RED = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_RED = TypeObjectUtils::build_common_enumerated_literal(0, flags_RED); + eprosima::fastcdr::optional member_ann_builtin_RED; + ann_custom_Color.reset(); + MemberName name_RED = "RED"; + CompleteMemberDetail detail_RED = TypeObjectUtils::build_complete_member_detail(name_RED, member_ann_builtin_RED, ann_custom_Color); + CompleteEnumeratedLiteral literal_RED = TypeObjectUtils::build_complete_enumerated_literal(common_RED, detail_RED); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Color, literal_RED); + } + { + EnumeratedLiteralFlag flags_GREEN = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_GREEN = TypeObjectUtils::build_common_enumerated_literal(1, flags_GREEN); + eprosima::fastcdr::optional member_ann_builtin_GREEN; + ann_custom_Color.reset(); + MemberName name_GREEN = "GREEN"; + CompleteMemberDetail detail_GREEN = TypeObjectUtils::build_complete_member_detail(name_GREEN, member_ann_builtin_GREEN, ann_custom_Color); + CompleteEnumeratedLiteral literal_GREEN = TypeObjectUtils::build_complete_enumerated_literal(common_GREEN, detail_GREEN); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Color, literal_GREEN); + } + { + EnumeratedLiteralFlag flags_BLUE = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_BLUE = TypeObjectUtils::build_common_enumerated_literal(2, flags_BLUE); + eprosima::fastcdr::optional member_ann_builtin_BLUE; + ann_custom_Color.reset(); + MemberName name_BLUE = "BLUE"; + CompleteMemberDetail detail_BLUE = TypeObjectUtils::build_complete_member_detail(name_BLUE, member_ann_builtin_BLUE, ann_custom_Color); + CompleteEnumeratedLiteral literal_BLUE = TypeObjectUtils::build_complete_enumerated_literal(common_BLUE, detail_BLUE); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Color, literal_BLUE); + } + { + EnumeratedLiteralFlag flags_YELLOW = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_YELLOW = TypeObjectUtils::build_common_enumerated_literal(3, flags_YELLOW); + eprosima::fastcdr::optional member_ann_builtin_YELLOW; + ann_custom_Color.reset(); + MemberName name_YELLOW = "YELLOW"; + CompleteMemberDetail detail_YELLOW = TypeObjectUtils::build_complete_member_detail(name_YELLOW, member_ann_builtin_YELLOW, ann_custom_Color); + CompleteEnumeratedLiteral literal_YELLOW = TypeObjectUtils::build_complete_enumerated_literal(common_YELLOW, detail_YELLOW); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Color, literal_YELLOW); + } + { + EnumeratedLiteralFlag flags_MAGENTA = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_MAGENTA = TypeObjectUtils::build_common_enumerated_literal(4, flags_MAGENTA); + eprosima::fastcdr::optional member_ann_builtin_MAGENTA; + ann_custom_Color.reset(); + MemberName name_MAGENTA = "MAGENTA"; + CompleteMemberDetail detail_MAGENTA = TypeObjectUtils::build_complete_member_detail(name_MAGENTA, member_ann_builtin_MAGENTA, ann_custom_Color); + CompleteEnumeratedLiteral literal_MAGENTA = TypeObjectUtils::build_complete_enumerated_literal(common_MAGENTA, detail_MAGENTA); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Color, literal_MAGENTA); + } + CompleteEnumeratedType enumerated_type_Color = TypeObjectUtils::build_complete_enumerated_type(enum_flags_Color, header_Color, + literal_seq_Color); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_enumerated_type_object(enumerated_type_Color, type_name_Color.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Color already registered in TypeObjectRegistry for a different type."); + } + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "Color", type_ids_StructType); + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Color: Given Enum TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_enum_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_enum_field; + MemberId member_id_enum_field = 0x0000000d; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_enum_field = TypeObjectUtils::build_common_struct_member(member_id_enum_field, member_flags_enum_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_enum_field = TypeObjectUtils::build_common_struct_member(member_id_enum_field, member_flags_enum_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure enum_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_enum_field = "enum_field"; + eprosima::fastcdr::optional member_ann_builtin_enum_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_enum_field = TypeObjectUtils::build_complete_member_detail(name_enum_field, member_ann_builtin_enum_field, ann_custom_StructType); + CompleteStructMember member_enum_field = TypeObjectUtils::build_complete_struct_member(common_enum_field, detail_enum_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_enum_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "Material", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EnumTypeFlag enum_flags_Material = 0; + BitBound bit_bound_Material = 32; + CommonEnumeratedHeader common_Material = TypeObjectUtils::build_common_enumerated_header(bit_bound_Material); + QualifiedTypeName type_name_Material = "Material"; + eprosima::fastcdr::optional type_ann_builtin_Material; + eprosima::fastcdr::optional ann_custom_Material; + CompleteTypeDetail detail_Material = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_Material, ann_custom_Material, type_name_Material.to_string()); + CompleteEnumeratedHeader header_Material = TypeObjectUtils::build_complete_enumerated_header(common_Material, detail_Material); + CompleteEnumeratedLiteralSeq literal_seq_Material; + { + EnumeratedLiteralFlag flags_WOOD = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_WOOD = TypeObjectUtils::build_common_enumerated_literal(0, flags_WOOD); + eprosima::fastcdr::optional member_ann_builtin_WOOD; + ann_custom_Material.reset(); + MemberName name_WOOD = "WOOD"; + CompleteMemberDetail detail_WOOD = TypeObjectUtils::build_complete_member_detail(name_WOOD, member_ann_builtin_WOOD, ann_custom_Material); + CompleteEnumeratedLiteral literal_WOOD = TypeObjectUtils::build_complete_enumerated_literal(common_WOOD, detail_WOOD); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Material, literal_WOOD); + } + { + EnumeratedLiteralFlag flags_PLASTIC = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_PLASTIC = TypeObjectUtils::build_common_enumerated_literal(1, flags_PLASTIC); + eprosima::fastcdr::optional member_ann_builtin_PLASTIC; + ann_custom_Material.reset(); + MemberName name_PLASTIC = "PLASTIC"; + CompleteMemberDetail detail_PLASTIC = TypeObjectUtils::build_complete_member_detail(name_PLASTIC, member_ann_builtin_PLASTIC, ann_custom_Material); + CompleteEnumeratedLiteral literal_PLASTIC = TypeObjectUtils::build_complete_enumerated_literal(common_PLASTIC, detail_PLASTIC); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Material, literal_PLASTIC); + } + { + EnumeratedLiteralFlag flags_METAL = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_METAL = TypeObjectUtils::build_common_enumerated_literal(2, flags_METAL); + eprosima::fastcdr::optional member_ann_builtin_METAL; + ann_custom_Material.reset(); + MemberName name_METAL = "METAL"; + CompleteMemberDetail detail_METAL = TypeObjectUtils::build_complete_member_detail(name_METAL, member_ann_builtin_METAL, ann_custom_Material); + CompleteEnumeratedLiteral literal_METAL = TypeObjectUtils::build_complete_enumerated_literal(common_METAL, detail_METAL); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Material, literal_METAL); + } + { + EnumeratedLiteralFlag flags_CONCRETE = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_CONCRETE = TypeObjectUtils::build_common_enumerated_literal(3, flags_CONCRETE); + eprosima::fastcdr::optional member_ann_builtin_CONCRETE; + ann_custom_Material.reset(); + MemberName name_CONCRETE = "CONCRETE"; + CompleteMemberDetail detail_CONCRETE = TypeObjectUtils::build_complete_member_detail(name_CONCRETE, member_ann_builtin_CONCRETE, ann_custom_Material); + CompleteEnumeratedLiteral literal_CONCRETE = TypeObjectUtils::build_complete_enumerated_literal(common_CONCRETE, detail_CONCRETE); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Material, literal_CONCRETE); + } + { + EnumeratedLiteralFlag flags_STONE = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_STONE = TypeObjectUtils::build_common_enumerated_literal(4, flags_STONE); + eprosima::fastcdr::optional member_ann_builtin_STONE; + ann_custom_Material.reset(); + MemberName name_STONE = "STONE"; + CompleteMemberDetail detail_STONE = TypeObjectUtils::build_complete_member_detail(name_STONE, member_ann_builtin_STONE, ann_custom_Material); + CompleteEnumeratedLiteral literal_STONE = TypeObjectUtils::build_complete_enumerated_literal(common_STONE, detail_STONE); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Material, literal_STONE); + } + CompleteEnumeratedType enumerated_type_Material = TypeObjectUtils::build_complete_enumerated_type(enum_flags_Material, header_Material, + literal_seq_Material); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_enumerated_type_object(enumerated_type_Material, type_name_Material.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Material already registered in TypeObjectRegistry for a different type."); + } + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "Material", type_ids_StructType); + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Material: Given Enum TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_enum2_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_enum2_field; + MemberId member_id_enum2_field = 0x0000000e; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_enum2_field = TypeObjectUtils::build_common_struct_member(member_id_enum2_field, member_flags_enum2_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_enum2_field = TypeObjectUtils::build_common_struct_member(member_id_enum2_field, member_flags_enum2_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure enum2_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_enum2_field = "enum2_field"; + eprosima::fastcdr::optional member_ann_builtin_enum2_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_enum2_field = TypeObjectUtils::build_complete_member_detail(name_enum2_field, member_ann_builtin_enum2_field, ann_custom_StructType); + CompleteStructMember member_enum2_field = TypeObjectUtils::build_complete_struct_member(common_enum2_field, detail_enum2_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_enum2_field); + } + CompleteStructType struct_type_StructType = TypeObjectUtils::build_complete_struct_type(struct_flags_StructType, header_StructType, member_seq_StructType); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_struct_type_object(struct_type_StructType, type_name_StructType.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "StructType already registered in TypeObjectRegistry for a different type."); + } + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "StructType", type_ids_StructType); + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "StructType: Given Struct TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + } + StructMemberFlag member_flags_struct_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_struct_field; + MemberId member_id_struct_field = 0x0000000f; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_struct_field = TypeObjectUtils::build_common_struct_member(member_id_struct_field, member_flags_struct_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_struct_field = TypeObjectUtils::build_common_struct_member(member_id_struct_field, member_flags_struct_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure struct_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_struct_field = "struct_field"; + eprosima::fastcdr::optional member_ann_builtin_struct_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_struct_field = TypeObjectUtils::build_complete_member_detail(name_struct_field, member_ann_builtin_struct_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_struct_field = TypeObjectUtils::build_complete_struct_member(common_struct_field, detail_struct_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_struct_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_array_char_3", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_char", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Array element TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + TypeIdentifier* element_identifier_anonymous_array_char_3 {nullptr}; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_array_char_3 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_array_char_3 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Array element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_array_char_3 = EK_COMPLETE; + if (TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d()) + { + equiv_kind_anonymous_array_char_3 = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_array_char_3 = 0; + PlainCollectionHeader header_anonymous_array_char_3 = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_array_char_3, element_flags_anonymous_array_char_3); + std::string type_id_kind_anonymous_array_char_3("TI_PLAIN_ARRAY_SMALL"); + if (type_id_kind_anonymous_array_char_3 == "TI_PLAIN_ARRAY_SMALL") + { + SBoundSeq array_bound_seq; + TypeObjectUtils::add_array_dimension(array_bound_seq, static_cast(3)); + + PlainArraySElemDefn array_sdefn = TypeObjectUtils::build_plain_array_s_elem_defn(header_anonymous_array_char_3, array_bound_seq, + eprosima::fastcdr::external(element_identifier_anonymous_array_char_3)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_array_type_identifier(array_sdefn, "anonymous_array_char_3")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_char_3 already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBoundSeq array_bound_seq; + TypeObjectUtils::add_array_dimension(array_bound_seq, static_cast(3)); + + PlainArrayLElemDefn array_ldefn = TypeObjectUtils::build_plain_array_l_elem_defn(header_anonymous_array_char_3, array_bound_seq, + eprosima::fastcdr::external(element_identifier_anonymous_array_char_3)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_array_type_identifier(array_ldefn, "anonymous_array_char_3")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_char_3 already registered in TypeObjectRegistry for a different type."); + } + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_array_char_3", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_char_3: Given Array TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_array_char_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_array_char_field; + MemberId member_id_array_char_field = 0x00000010; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_array_char_field = TypeObjectUtils::build_common_struct_member(member_id_array_char_field, member_flags_array_char_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_array_char_field = TypeObjectUtils::build_common_struct_member(member_id_array_char_field, member_flags_array_char_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure array_char_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_array_char_field = "array_char_field"; + eprosima::fastcdr::optional member_ann_builtin_array_char_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_array_char_field = TypeObjectUtils::build_complete_member_detail(name_array_char_field, member_ann_builtin_array_char_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_array_char_field = TypeObjectUtils::build_complete_struct_member(common_array_char_field, detail_array_char_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_array_char_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_array_uint8_t_3", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_byte", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Array element TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + TypeIdentifier* element_identifier_anonymous_array_uint8_t_3 {nullptr}; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_array_uint8_t_3 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_array_uint8_t_3 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Array element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_array_uint8_t_3 = EK_COMPLETE; + if (TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d()) + { + equiv_kind_anonymous_array_uint8_t_3 = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_array_uint8_t_3 = 0; + PlainCollectionHeader header_anonymous_array_uint8_t_3 = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_array_uint8_t_3, element_flags_anonymous_array_uint8_t_3); + std::string type_id_kind_anonymous_array_uint8_t_3("TI_PLAIN_ARRAY_SMALL"); + if (type_id_kind_anonymous_array_uint8_t_3 == "TI_PLAIN_ARRAY_SMALL") + { + SBoundSeq array_bound_seq; + TypeObjectUtils::add_array_dimension(array_bound_seq, static_cast(3)); + + PlainArraySElemDefn array_sdefn = TypeObjectUtils::build_plain_array_s_elem_defn(header_anonymous_array_uint8_t_3, array_bound_seq, + eprosima::fastcdr::external(element_identifier_anonymous_array_uint8_t_3)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_array_type_identifier(array_sdefn, "anonymous_array_uint8_t_3")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_uint8_t_3 already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBoundSeq array_bound_seq; + TypeObjectUtils::add_array_dimension(array_bound_seq, static_cast(3)); + + PlainArrayLElemDefn array_ldefn = TypeObjectUtils::build_plain_array_l_elem_defn(header_anonymous_array_uint8_t_3, array_bound_seq, + eprosima::fastcdr::external(element_identifier_anonymous_array_uint8_t_3)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_array_type_identifier(array_ldefn, "anonymous_array_uint8_t_3")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_uint8_t_3 already registered in TypeObjectRegistry for a different type."); + } + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_array_uint8_t_3", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_uint8_t_3: Given Array TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_array_uint8_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_array_uint8_field; + MemberId member_id_array_uint8_field = 0x00000011; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_array_uint8_field = TypeObjectUtils::build_common_struct_member(member_id_array_uint8_field, member_flags_array_uint8_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_array_uint8_field = TypeObjectUtils::build_common_struct_member(member_id_array_uint8_field, member_flags_array_uint8_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure array_uint8_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_array_uint8_field = "array_uint8_field"; + eprosima::fastcdr::optional member_ann_builtin_array_uint8_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_array_uint8_field = TypeObjectUtils::build_complete_member_detail(name_array_uint8_field, member_ann_builtin_array_uint8_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_array_uint8_field = TypeObjectUtils::build_complete_struct_member(common_array_uint8_field, detail_array_uint8_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_array_uint8_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_array_int16_t_3", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_int16_t", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Array element TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + TypeIdentifier* element_identifier_anonymous_array_int16_t_3 {nullptr}; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_array_int16_t_3 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_array_int16_t_3 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Array element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_array_int16_t_3 = EK_COMPLETE; + if (TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d()) + { + equiv_kind_anonymous_array_int16_t_3 = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_array_int16_t_3 = 0; + PlainCollectionHeader header_anonymous_array_int16_t_3 = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_array_int16_t_3, element_flags_anonymous_array_int16_t_3); + std::string type_id_kind_anonymous_array_int16_t_3("TI_PLAIN_ARRAY_SMALL"); + if (type_id_kind_anonymous_array_int16_t_3 == "TI_PLAIN_ARRAY_SMALL") + { + SBoundSeq array_bound_seq; + TypeObjectUtils::add_array_dimension(array_bound_seq, static_cast(3)); + + PlainArraySElemDefn array_sdefn = TypeObjectUtils::build_plain_array_s_elem_defn(header_anonymous_array_int16_t_3, array_bound_seq, + eprosima::fastcdr::external(element_identifier_anonymous_array_int16_t_3)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_array_type_identifier(array_sdefn, "anonymous_array_int16_t_3")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_int16_t_3 already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBoundSeq array_bound_seq; + TypeObjectUtils::add_array_dimension(array_bound_seq, static_cast(3)); + + PlainArrayLElemDefn array_ldefn = TypeObjectUtils::build_plain_array_l_elem_defn(header_anonymous_array_int16_t_3, array_bound_seq, + eprosima::fastcdr::external(element_identifier_anonymous_array_int16_t_3)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_array_type_identifier(array_ldefn, "anonymous_array_int16_t_3")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_int16_t_3 already registered in TypeObjectRegistry for a different type."); + } + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_array_int16_t_3", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_int16_t_3: Given Array TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_array_int16_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_array_int16_field; + MemberId member_id_array_int16_field = 0x00000012; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_array_int16_field = TypeObjectUtils::build_common_struct_member(member_id_array_int16_field, member_flags_array_int16_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_array_int16_field = TypeObjectUtils::build_common_struct_member(member_id_array_int16_field, member_flags_array_int16_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure array_int16_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_array_int16_field = "array_int16_field"; + eprosima::fastcdr::optional member_ann_builtin_array_int16_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_array_int16_field = TypeObjectUtils::build_complete_member_detail(name_array_int16_field, member_ann_builtin_array_int16_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_array_int16_field = TypeObjectUtils::build_complete_struct_member(common_array_int16_field, detail_array_int16_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_array_int16_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_array_uint16_t_3", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_uint16_t", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Array element TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + TypeIdentifier* element_identifier_anonymous_array_uint16_t_3 {nullptr}; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_array_uint16_t_3 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_array_uint16_t_3 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Array element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_array_uint16_t_3 = EK_COMPLETE; + if (TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d()) + { + equiv_kind_anonymous_array_uint16_t_3 = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_array_uint16_t_3 = 0; + PlainCollectionHeader header_anonymous_array_uint16_t_3 = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_array_uint16_t_3, element_flags_anonymous_array_uint16_t_3); + std::string type_id_kind_anonymous_array_uint16_t_3("TI_PLAIN_ARRAY_SMALL"); + if (type_id_kind_anonymous_array_uint16_t_3 == "TI_PLAIN_ARRAY_SMALL") + { + SBoundSeq array_bound_seq; + TypeObjectUtils::add_array_dimension(array_bound_seq, static_cast(3)); + + PlainArraySElemDefn array_sdefn = TypeObjectUtils::build_plain_array_s_elem_defn(header_anonymous_array_uint16_t_3, array_bound_seq, + eprosima::fastcdr::external(element_identifier_anonymous_array_uint16_t_3)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_array_type_identifier(array_sdefn, "anonymous_array_uint16_t_3")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_uint16_t_3 already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBoundSeq array_bound_seq; + TypeObjectUtils::add_array_dimension(array_bound_seq, static_cast(3)); + + PlainArrayLElemDefn array_ldefn = TypeObjectUtils::build_plain_array_l_elem_defn(header_anonymous_array_uint16_t_3, array_bound_seq, + eprosima::fastcdr::external(element_identifier_anonymous_array_uint16_t_3)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_array_type_identifier(array_ldefn, "anonymous_array_uint16_t_3")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_uint16_t_3 already registered in TypeObjectRegistry for a different type."); + } + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_array_uint16_t_3", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_uint16_t_3: Given Array TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_array_uint16_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_array_uint16_field; + MemberId member_id_array_uint16_field = 0x00000013; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_array_uint16_field = TypeObjectUtils::build_common_struct_member(member_id_array_uint16_field, member_flags_array_uint16_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_array_uint16_field = TypeObjectUtils::build_common_struct_member(member_id_array_uint16_field, member_flags_array_uint16_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure array_uint16_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_array_uint16_field = "array_uint16_field"; + eprosima::fastcdr::optional member_ann_builtin_array_uint16_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_array_uint16_field = TypeObjectUtils::build_complete_member_detail(name_array_uint16_field, member_ann_builtin_array_uint16_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_array_uint16_field = TypeObjectUtils::build_complete_struct_member(common_array_uint16_field, detail_array_uint16_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_array_uint16_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_array_int32_t_3", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_int32_t", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Array element TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + TypeIdentifier* element_identifier_anonymous_array_int32_t_3 {nullptr}; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_array_int32_t_3 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_array_int32_t_3 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Array element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_array_int32_t_3 = EK_COMPLETE; + if (TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d()) + { + equiv_kind_anonymous_array_int32_t_3 = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_array_int32_t_3 = 0; + PlainCollectionHeader header_anonymous_array_int32_t_3 = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_array_int32_t_3, element_flags_anonymous_array_int32_t_3); + std::string type_id_kind_anonymous_array_int32_t_3("TI_PLAIN_ARRAY_SMALL"); + if (type_id_kind_anonymous_array_int32_t_3 == "TI_PLAIN_ARRAY_SMALL") + { + SBoundSeq array_bound_seq; + TypeObjectUtils::add_array_dimension(array_bound_seq, static_cast(3)); + + PlainArraySElemDefn array_sdefn = TypeObjectUtils::build_plain_array_s_elem_defn(header_anonymous_array_int32_t_3, array_bound_seq, + eprosima::fastcdr::external(element_identifier_anonymous_array_int32_t_3)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_array_type_identifier(array_sdefn, "anonymous_array_int32_t_3")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_int32_t_3 already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBoundSeq array_bound_seq; + TypeObjectUtils::add_array_dimension(array_bound_seq, static_cast(3)); + + PlainArrayLElemDefn array_ldefn = TypeObjectUtils::build_plain_array_l_elem_defn(header_anonymous_array_int32_t_3, array_bound_seq, + eprosima::fastcdr::external(element_identifier_anonymous_array_int32_t_3)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_array_type_identifier(array_ldefn, "anonymous_array_int32_t_3")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_int32_t_3 already registered in TypeObjectRegistry for a different type."); + } + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_array_int32_t_3", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_int32_t_3: Given Array TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_array_int32_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_array_int32_field; + MemberId member_id_array_int32_field = 0x00000014; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_array_int32_field = TypeObjectUtils::build_common_struct_member(member_id_array_int32_field, member_flags_array_int32_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_array_int32_field = TypeObjectUtils::build_common_struct_member(member_id_array_int32_field, member_flags_array_int32_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure array_int32_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_array_int32_field = "array_int32_field"; + eprosima::fastcdr::optional member_ann_builtin_array_int32_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_array_int32_field = TypeObjectUtils::build_complete_member_detail(name_array_int32_field, member_ann_builtin_array_int32_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_array_int32_field = TypeObjectUtils::build_complete_struct_member(common_array_int32_field, detail_array_int32_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_array_int32_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_array_uint32_t_3", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_uint32_t", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Array element TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + TypeIdentifier* element_identifier_anonymous_array_uint32_t_3 {nullptr}; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_array_uint32_t_3 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_array_uint32_t_3 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Array element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_array_uint32_t_3 = EK_COMPLETE; + if (TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d()) + { + equiv_kind_anonymous_array_uint32_t_3 = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_array_uint32_t_3 = 0; + PlainCollectionHeader header_anonymous_array_uint32_t_3 = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_array_uint32_t_3, element_flags_anonymous_array_uint32_t_3); + std::string type_id_kind_anonymous_array_uint32_t_3("TI_PLAIN_ARRAY_SMALL"); + if (type_id_kind_anonymous_array_uint32_t_3 == "TI_PLAIN_ARRAY_SMALL") + { + SBoundSeq array_bound_seq; + TypeObjectUtils::add_array_dimension(array_bound_seq, static_cast(3)); + + PlainArraySElemDefn array_sdefn = TypeObjectUtils::build_plain_array_s_elem_defn(header_anonymous_array_uint32_t_3, array_bound_seq, + eprosima::fastcdr::external(element_identifier_anonymous_array_uint32_t_3)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_array_type_identifier(array_sdefn, "anonymous_array_uint32_t_3")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_uint32_t_3 already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBoundSeq array_bound_seq; + TypeObjectUtils::add_array_dimension(array_bound_seq, static_cast(3)); + + PlainArrayLElemDefn array_ldefn = TypeObjectUtils::build_plain_array_l_elem_defn(header_anonymous_array_uint32_t_3, array_bound_seq, + eprosima::fastcdr::external(element_identifier_anonymous_array_uint32_t_3)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_array_type_identifier(array_ldefn, "anonymous_array_uint32_t_3")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_uint32_t_3 already registered in TypeObjectRegistry for a different type."); + } + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_array_uint32_t_3", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_uint32_t_3: Given Array TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_array_uint32_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_array_uint32_field; + MemberId member_id_array_uint32_field = 0x00000015; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_array_uint32_field = TypeObjectUtils::build_common_struct_member(member_id_array_uint32_field, member_flags_array_uint32_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_array_uint32_field = TypeObjectUtils::build_common_struct_member(member_id_array_uint32_field, member_flags_array_uint32_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure array_uint32_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_array_uint32_field = "array_uint32_field"; + eprosima::fastcdr::optional member_ann_builtin_array_uint32_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_array_uint32_field = TypeObjectUtils::build_complete_member_detail(name_array_uint32_field, member_ann_builtin_array_uint32_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_array_uint32_field = TypeObjectUtils::build_complete_struct_member(common_array_uint32_field, detail_array_uint32_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_array_uint32_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_array_int64_t_3", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_int64_t", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Array element TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + TypeIdentifier* element_identifier_anonymous_array_int64_t_3 {nullptr}; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_array_int64_t_3 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_array_int64_t_3 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Array element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_array_int64_t_3 = EK_COMPLETE; + if (TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d()) + { + equiv_kind_anonymous_array_int64_t_3 = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_array_int64_t_3 = 0; + PlainCollectionHeader header_anonymous_array_int64_t_3 = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_array_int64_t_3, element_flags_anonymous_array_int64_t_3); + std::string type_id_kind_anonymous_array_int64_t_3("TI_PLAIN_ARRAY_SMALL"); + if (type_id_kind_anonymous_array_int64_t_3 == "TI_PLAIN_ARRAY_SMALL") + { + SBoundSeq array_bound_seq; + TypeObjectUtils::add_array_dimension(array_bound_seq, static_cast(3)); + + PlainArraySElemDefn array_sdefn = TypeObjectUtils::build_plain_array_s_elem_defn(header_anonymous_array_int64_t_3, array_bound_seq, + eprosima::fastcdr::external(element_identifier_anonymous_array_int64_t_3)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_array_type_identifier(array_sdefn, "anonymous_array_int64_t_3")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_int64_t_3 already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBoundSeq array_bound_seq; + TypeObjectUtils::add_array_dimension(array_bound_seq, static_cast(3)); + + PlainArrayLElemDefn array_ldefn = TypeObjectUtils::build_plain_array_l_elem_defn(header_anonymous_array_int64_t_3, array_bound_seq, + eprosima::fastcdr::external(element_identifier_anonymous_array_int64_t_3)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_array_type_identifier(array_ldefn, "anonymous_array_int64_t_3")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_int64_t_3 already registered in TypeObjectRegistry for a different type."); + } + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_array_int64_t_3", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_int64_t_3: Given Array TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_array_int64_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_array_int64_field; + MemberId member_id_array_int64_field = 0x00000016; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_array_int64_field = TypeObjectUtils::build_common_struct_member(member_id_array_int64_field, member_flags_array_int64_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_array_int64_field = TypeObjectUtils::build_common_struct_member(member_id_array_int64_field, member_flags_array_int64_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure array_int64_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_array_int64_field = "array_int64_field"; + eprosima::fastcdr::optional member_ann_builtin_array_int64_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_array_int64_field = TypeObjectUtils::build_complete_member_detail(name_array_int64_field, member_ann_builtin_array_int64_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_array_int64_field = TypeObjectUtils::build_complete_struct_member(common_array_int64_field, detail_array_int64_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_array_int64_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_array_uint64_t_3", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_uint64_t", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Array element TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + TypeIdentifier* element_identifier_anonymous_array_uint64_t_3 {nullptr}; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_array_uint64_t_3 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_array_uint64_t_3 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Array element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_array_uint64_t_3 = EK_COMPLETE; + if (TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d()) + { + equiv_kind_anonymous_array_uint64_t_3 = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_array_uint64_t_3 = 0; + PlainCollectionHeader header_anonymous_array_uint64_t_3 = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_array_uint64_t_3, element_flags_anonymous_array_uint64_t_3); + std::string type_id_kind_anonymous_array_uint64_t_3("TI_PLAIN_ARRAY_SMALL"); + if (type_id_kind_anonymous_array_uint64_t_3 == "TI_PLAIN_ARRAY_SMALL") + { + SBoundSeq array_bound_seq; + TypeObjectUtils::add_array_dimension(array_bound_seq, static_cast(3)); + + PlainArraySElemDefn array_sdefn = TypeObjectUtils::build_plain_array_s_elem_defn(header_anonymous_array_uint64_t_3, array_bound_seq, + eprosima::fastcdr::external(element_identifier_anonymous_array_uint64_t_3)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_array_type_identifier(array_sdefn, "anonymous_array_uint64_t_3")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_uint64_t_3 already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBoundSeq array_bound_seq; + TypeObjectUtils::add_array_dimension(array_bound_seq, static_cast(3)); + + PlainArrayLElemDefn array_ldefn = TypeObjectUtils::build_plain_array_l_elem_defn(header_anonymous_array_uint64_t_3, array_bound_seq, + eprosima::fastcdr::external(element_identifier_anonymous_array_uint64_t_3)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_array_type_identifier(array_ldefn, "anonymous_array_uint64_t_3")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_uint64_t_3 already registered in TypeObjectRegistry for a different type."); + } + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_array_uint64_t_3", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_uint64_t_3: Given Array TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_array_uint64_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_array_uint64_field; + MemberId member_id_array_uint64_field = 0x00000017; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_array_uint64_field = TypeObjectUtils::build_common_struct_member(member_id_array_uint64_field, member_flags_array_uint64_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_array_uint64_field = TypeObjectUtils::build_common_struct_member(member_id_array_uint64_field, member_flags_array_uint64_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure array_uint64_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_array_uint64_field = "array_uint64_field"; + eprosima::fastcdr::optional member_ann_builtin_array_uint64_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_array_uint64_field = TypeObjectUtils::build_complete_member_detail(name_array_uint64_field, member_ann_builtin_array_uint64_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_array_uint64_field = TypeObjectUtils::build_complete_struct_member(common_array_uint64_field, detail_array_uint64_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_array_uint64_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_array_float_3", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_float", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Array element TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + TypeIdentifier* element_identifier_anonymous_array_float_3 {nullptr}; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_array_float_3 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_array_float_3 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Array element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_array_float_3 = EK_COMPLETE; + if (TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d()) + { + equiv_kind_anonymous_array_float_3 = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_array_float_3 = 0; + PlainCollectionHeader header_anonymous_array_float_3 = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_array_float_3, element_flags_anonymous_array_float_3); + std::string type_id_kind_anonymous_array_float_3("TI_PLAIN_ARRAY_SMALL"); + if (type_id_kind_anonymous_array_float_3 == "TI_PLAIN_ARRAY_SMALL") + { + SBoundSeq array_bound_seq; + TypeObjectUtils::add_array_dimension(array_bound_seq, static_cast(3)); + + PlainArraySElemDefn array_sdefn = TypeObjectUtils::build_plain_array_s_elem_defn(header_anonymous_array_float_3, array_bound_seq, + eprosima::fastcdr::external(element_identifier_anonymous_array_float_3)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_array_type_identifier(array_sdefn, "anonymous_array_float_3")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_float_3 already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBoundSeq array_bound_seq; + TypeObjectUtils::add_array_dimension(array_bound_seq, static_cast(3)); + + PlainArrayLElemDefn array_ldefn = TypeObjectUtils::build_plain_array_l_elem_defn(header_anonymous_array_float_3, array_bound_seq, + eprosima::fastcdr::external(element_identifier_anonymous_array_float_3)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_array_type_identifier(array_ldefn, "anonymous_array_float_3")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_float_3 already registered in TypeObjectRegistry for a different type."); + } + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_array_float_3", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_float_3: Given Array TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_array_float_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_array_float_field; + MemberId member_id_array_float_field = 0x00000018; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_array_float_field = TypeObjectUtils::build_common_struct_member(member_id_array_float_field, member_flags_array_float_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_array_float_field = TypeObjectUtils::build_common_struct_member(member_id_array_float_field, member_flags_array_float_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure array_float_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_array_float_field = "array_float_field"; + eprosima::fastcdr::optional member_ann_builtin_array_float_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_array_float_field = TypeObjectUtils::build_complete_member_detail(name_array_float_field, member_ann_builtin_array_float_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_array_float_field = TypeObjectUtils::build_complete_struct_member(common_array_float_field, detail_array_float_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_array_float_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_array_double_3", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_double", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Array element TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + TypeIdentifier* element_identifier_anonymous_array_double_3 {nullptr}; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_array_double_3 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_array_double_3 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Array element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_array_double_3 = EK_COMPLETE; + if (TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d()) + { + equiv_kind_anonymous_array_double_3 = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_array_double_3 = 0; + PlainCollectionHeader header_anonymous_array_double_3 = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_array_double_3, element_flags_anonymous_array_double_3); + std::string type_id_kind_anonymous_array_double_3("TI_PLAIN_ARRAY_SMALL"); + if (type_id_kind_anonymous_array_double_3 == "TI_PLAIN_ARRAY_SMALL") + { + SBoundSeq array_bound_seq; + TypeObjectUtils::add_array_dimension(array_bound_seq, static_cast(3)); + + PlainArraySElemDefn array_sdefn = TypeObjectUtils::build_plain_array_s_elem_defn(header_anonymous_array_double_3, array_bound_seq, + eprosima::fastcdr::external(element_identifier_anonymous_array_double_3)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_array_type_identifier(array_sdefn, "anonymous_array_double_3")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_double_3 already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBoundSeq array_bound_seq; + TypeObjectUtils::add_array_dimension(array_bound_seq, static_cast(3)); + + PlainArrayLElemDefn array_ldefn = TypeObjectUtils::build_plain_array_l_elem_defn(header_anonymous_array_double_3, array_bound_seq, + eprosima::fastcdr::external(element_identifier_anonymous_array_double_3)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_array_type_identifier(array_ldefn, "anonymous_array_double_3")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_double_3 already registered in TypeObjectRegistry for a different type."); + } + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_array_double_3", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_double_3: Given Array TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_array_double_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_array_double_field; + MemberId member_id_array_double_field = 0x00000019; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_array_double_field = TypeObjectUtils::build_common_struct_member(member_id_array_double_field, member_flags_array_double_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_array_double_field = TypeObjectUtils::build_common_struct_member(member_id_array_double_field, member_flags_array_double_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure array_double_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_array_double_field = "array_double_field"; + eprosima::fastcdr::optional member_ann_builtin_array_double_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_array_double_field = TypeObjectUtils::build_complete_member_detail(name_array_double_field, member_ann_builtin_array_double_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_array_double_field = TypeObjectUtils::build_complete_struct_member(common_array_double_field, detail_array_double_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_array_double_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_array_longdouble_3", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_longdouble", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Array element TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + TypeIdentifier* element_identifier_anonymous_array_longdouble_3 {nullptr}; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_array_longdouble_3 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_array_longdouble_3 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Array element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_array_longdouble_3 = EK_COMPLETE; + if (TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d()) + { + equiv_kind_anonymous_array_longdouble_3 = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_array_longdouble_3 = 0; + PlainCollectionHeader header_anonymous_array_longdouble_3 = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_array_longdouble_3, element_flags_anonymous_array_longdouble_3); + std::string type_id_kind_anonymous_array_longdouble_3("TI_PLAIN_ARRAY_SMALL"); + if (type_id_kind_anonymous_array_longdouble_3 == "TI_PLAIN_ARRAY_SMALL") + { + SBoundSeq array_bound_seq; + TypeObjectUtils::add_array_dimension(array_bound_seq, static_cast(3)); + + PlainArraySElemDefn array_sdefn = TypeObjectUtils::build_plain_array_s_elem_defn(header_anonymous_array_longdouble_3, array_bound_seq, + eprosima::fastcdr::external(element_identifier_anonymous_array_longdouble_3)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_array_type_identifier(array_sdefn, "anonymous_array_longdouble_3")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_longdouble_3 already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBoundSeq array_bound_seq; + TypeObjectUtils::add_array_dimension(array_bound_seq, static_cast(3)); + + PlainArrayLElemDefn array_ldefn = TypeObjectUtils::build_plain_array_l_elem_defn(header_anonymous_array_longdouble_3, array_bound_seq, + eprosima::fastcdr::external(element_identifier_anonymous_array_longdouble_3)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_array_type_identifier(array_ldefn, "anonymous_array_longdouble_3")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_longdouble_3 already registered in TypeObjectRegistry for a different type."); + } + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_array_longdouble_3", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_longdouble_3: Given Array TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_array_long_double_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_array_long_double_field; + MemberId member_id_array_long_double_field = 0x0000001a; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_array_long_double_field = TypeObjectUtils::build_common_struct_member(member_id_array_long_double_field, member_flags_array_long_double_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_array_long_double_field = TypeObjectUtils::build_common_struct_member(member_id_array_long_double_field, member_flags_array_long_double_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure array_long_double_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_array_long_double_field = "array_long_double_field"; + eprosima::fastcdr::optional member_ann_builtin_array_long_double_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_array_long_double_field = TypeObjectUtils::build_complete_member_detail(name_array_long_double_field, member_ann_builtin_array_long_double_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_array_long_double_field = TypeObjectUtils::build_complete_struct_member(common_array_long_double_field, detail_array_long_double_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_array_long_double_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_array_bool_3", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_bool", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Array element TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + TypeIdentifier* element_identifier_anonymous_array_bool_3 {nullptr}; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_array_bool_3 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_array_bool_3 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Array element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_array_bool_3 = EK_COMPLETE; + if (TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d()) + { + equiv_kind_anonymous_array_bool_3 = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_array_bool_3 = 0; + PlainCollectionHeader header_anonymous_array_bool_3 = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_array_bool_3, element_flags_anonymous_array_bool_3); + std::string type_id_kind_anonymous_array_bool_3("TI_PLAIN_ARRAY_SMALL"); + if (type_id_kind_anonymous_array_bool_3 == "TI_PLAIN_ARRAY_SMALL") + { + SBoundSeq array_bound_seq; + TypeObjectUtils::add_array_dimension(array_bound_seq, static_cast(3)); + + PlainArraySElemDefn array_sdefn = TypeObjectUtils::build_plain_array_s_elem_defn(header_anonymous_array_bool_3, array_bound_seq, + eprosima::fastcdr::external(element_identifier_anonymous_array_bool_3)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_array_type_identifier(array_sdefn, "anonymous_array_bool_3")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_bool_3 already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBoundSeq array_bound_seq; + TypeObjectUtils::add_array_dimension(array_bound_seq, static_cast(3)); + + PlainArrayLElemDefn array_ldefn = TypeObjectUtils::build_plain_array_l_elem_defn(header_anonymous_array_bool_3, array_bound_seq, + eprosima::fastcdr::external(element_identifier_anonymous_array_bool_3)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_array_type_identifier(array_ldefn, "anonymous_array_bool_3")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_bool_3 already registered in TypeObjectRegistry for a different type."); + } + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_array_bool_3", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_bool_3: Given Array TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_array_bool_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_array_bool_field; + MemberId member_id_array_bool_field = 0x0000001b; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_array_bool_field = TypeObjectUtils::build_common_struct_member(member_id_array_bool_field, member_flags_array_bool_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_array_bool_field = TypeObjectUtils::build_common_struct_member(member_id_array_bool_field, member_flags_array_bool_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure array_bool_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_array_bool_field = "array_bool_field"; + eprosima::fastcdr::optional member_ann_builtin_array_bool_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_array_bool_field = TypeObjectUtils::build_complete_member_detail(name_array_bool_field, member_ann_builtin_array_bool_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_array_bool_field = TypeObjectUtils::build_complete_struct_member(common_array_bool_field, detail_array_bool_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_array_bool_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_array_anonymous_string_unbounded_3", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_string_unbounded", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + std::string type_id_kind_anonymous_string_unbounded("TI_STRING8_SMALL"); + if (type_id_kind_anonymous_string_unbounded == "TI_STRING8_SMALL") + { + SBound bound = 0; + StringSTypeDefn string_sdefn = TypeObjectUtils::build_string_s_type_defn(bound); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_string_type_identifier(string_sdefn, + "anonymous_string_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else if (type_id_kind_anonymous_string_unbounded == "TI_STRING8_LARGE") + { + LBound bound = 255; + StringLTypeDefn string_ldefn = TypeObjectUtils::build_string_l_type_defn(bound); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_string_type_identifier(string_ldefn, + "anonymous_string_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded: Unknown String kind."); + return; + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_string_unbounded", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded: Given String TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + TypeIdentifier* element_identifier_anonymous_array_anonymous_string_unbounded_3 {nullptr}; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_array_anonymous_string_unbounded_3 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_array_anonymous_string_unbounded_3 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Array element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_array_anonymous_string_unbounded_3 = EK_COMPLETE; + if (TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d()) + { + equiv_kind_anonymous_array_anonymous_string_unbounded_3 = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_array_anonymous_string_unbounded_3 = 0; + PlainCollectionHeader header_anonymous_array_anonymous_string_unbounded_3 = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_array_anonymous_string_unbounded_3, element_flags_anonymous_array_anonymous_string_unbounded_3); + std::string type_id_kind_anonymous_array_anonymous_string_unbounded_3("TI_PLAIN_ARRAY_SMALL"); + if (type_id_kind_anonymous_array_anonymous_string_unbounded_3 == "TI_PLAIN_ARRAY_SMALL") + { + SBoundSeq array_bound_seq; + TypeObjectUtils::add_array_dimension(array_bound_seq, static_cast(3)); + + PlainArraySElemDefn array_sdefn = TypeObjectUtils::build_plain_array_s_elem_defn(header_anonymous_array_anonymous_string_unbounded_3, array_bound_seq, + eprosima::fastcdr::external(element_identifier_anonymous_array_anonymous_string_unbounded_3)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_array_type_identifier(array_sdefn, "anonymous_array_anonymous_string_unbounded_3")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_anonymous_string_unbounded_3 already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBoundSeq array_bound_seq; + TypeObjectUtils::add_array_dimension(array_bound_seq, static_cast(3)); + + PlainArrayLElemDefn array_ldefn = TypeObjectUtils::build_plain_array_l_elem_defn(header_anonymous_array_anonymous_string_unbounded_3, array_bound_seq, + eprosima::fastcdr::external(element_identifier_anonymous_array_anonymous_string_unbounded_3)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_array_type_identifier(array_ldefn, "anonymous_array_anonymous_string_unbounded_3")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_anonymous_string_unbounded_3 already registered in TypeObjectRegistry for a different type."); + } + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_array_anonymous_string_unbounded_3", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_anonymous_string_unbounded_3: Given Array TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_array_string_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_array_string_field; + MemberId member_id_array_string_field = 0x0000001c; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_array_string_field = TypeObjectUtils::build_common_struct_member(member_id_array_string_field, member_flags_array_string_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_array_string_field = TypeObjectUtils::build_common_struct_member(member_id_array_string_field, member_flags_array_string_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure array_string_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_array_string_field = "array_string_field"; + eprosima::fastcdr::optional member_ann_builtin_array_string_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_array_string_field = TypeObjectUtils::build_complete_member_detail(name_array_string_field, member_ann_builtin_array_string_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_array_string_field = TypeObjectUtils::build_complete_struct_member(common_array_string_field, detail_array_string_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_array_string_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_array_Color_3", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "Color", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EnumTypeFlag enum_flags_Color = 0; + BitBound bit_bound_Color = 32; + CommonEnumeratedHeader common_Color = TypeObjectUtils::build_common_enumerated_header(bit_bound_Color); + QualifiedTypeName type_name_Color = "Color"; + eprosima::fastcdr::optional type_ann_builtin_Color; + eprosima::fastcdr::optional ann_custom_Color; + CompleteTypeDetail detail_Color = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_Color, ann_custom_Color, type_name_Color.to_string()); + CompleteEnumeratedHeader header_Color = TypeObjectUtils::build_complete_enumerated_header(common_Color, detail_Color); + CompleteEnumeratedLiteralSeq literal_seq_Color; + { + EnumeratedLiteralFlag flags_RED = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_RED = TypeObjectUtils::build_common_enumerated_literal(0, flags_RED); + eprosima::fastcdr::optional member_ann_builtin_RED; + ann_custom_Color.reset(); + MemberName name_RED = "RED"; + CompleteMemberDetail detail_RED = TypeObjectUtils::build_complete_member_detail(name_RED, member_ann_builtin_RED, ann_custom_Color); + CompleteEnumeratedLiteral literal_RED = TypeObjectUtils::build_complete_enumerated_literal(common_RED, detail_RED); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Color, literal_RED); + } + { + EnumeratedLiteralFlag flags_GREEN = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_GREEN = TypeObjectUtils::build_common_enumerated_literal(1, flags_GREEN); + eprosima::fastcdr::optional member_ann_builtin_GREEN; + ann_custom_Color.reset(); + MemberName name_GREEN = "GREEN"; + CompleteMemberDetail detail_GREEN = TypeObjectUtils::build_complete_member_detail(name_GREEN, member_ann_builtin_GREEN, ann_custom_Color); + CompleteEnumeratedLiteral literal_GREEN = TypeObjectUtils::build_complete_enumerated_literal(common_GREEN, detail_GREEN); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Color, literal_GREEN); + } + { + EnumeratedLiteralFlag flags_BLUE = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_BLUE = TypeObjectUtils::build_common_enumerated_literal(2, flags_BLUE); + eprosima::fastcdr::optional member_ann_builtin_BLUE; + ann_custom_Color.reset(); + MemberName name_BLUE = "BLUE"; + CompleteMemberDetail detail_BLUE = TypeObjectUtils::build_complete_member_detail(name_BLUE, member_ann_builtin_BLUE, ann_custom_Color); + CompleteEnumeratedLiteral literal_BLUE = TypeObjectUtils::build_complete_enumerated_literal(common_BLUE, detail_BLUE); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Color, literal_BLUE); + } + { + EnumeratedLiteralFlag flags_YELLOW = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_YELLOW = TypeObjectUtils::build_common_enumerated_literal(3, flags_YELLOW); + eprosima::fastcdr::optional member_ann_builtin_YELLOW; + ann_custom_Color.reset(); + MemberName name_YELLOW = "YELLOW"; + CompleteMemberDetail detail_YELLOW = TypeObjectUtils::build_complete_member_detail(name_YELLOW, member_ann_builtin_YELLOW, ann_custom_Color); + CompleteEnumeratedLiteral literal_YELLOW = TypeObjectUtils::build_complete_enumerated_literal(common_YELLOW, detail_YELLOW); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Color, literal_YELLOW); + } + { + EnumeratedLiteralFlag flags_MAGENTA = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_MAGENTA = TypeObjectUtils::build_common_enumerated_literal(4, flags_MAGENTA); + eprosima::fastcdr::optional member_ann_builtin_MAGENTA; + ann_custom_Color.reset(); + MemberName name_MAGENTA = "MAGENTA"; + CompleteMemberDetail detail_MAGENTA = TypeObjectUtils::build_complete_member_detail(name_MAGENTA, member_ann_builtin_MAGENTA, ann_custom_Color); + CompleteEnumeratedLiteral literal_MAGENTA = TypeObjectUtils::build_complete_enumerated_literal(common_MAGENTA, detail_MAGENTA); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Color, literal_MAGENTA); + } + CompleteEnumeratedType enumerated_type_Color = TypeObjectUtils::build_complete_enumerated_type(enum_flags_Color, header_Color, + literal_seq_Color); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_enumerated_type_object(enumerated_type_Color, type_name_Color.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Color already registered in TypeObjectRegistry for a different type."); + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "Color", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Color: Given Enum TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + TypeIdentifier* element_identifier_anonymous_array_Color_3 {nullptr}; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_array_Color_3 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_array_Color_3 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Array element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_array_Color_3 = EK_COMPLETE; + if (TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d()) + { + equiv_kind_anonymous_array_Color_3 = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_array_Color_3 = 0; + PlainCollectionHeader header_anonymous_array_Color_3 = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_array_Color_3, element_flags_anonymous_array_Color_3); + std::string type_id_kind_anonymous_array_Color_3("TI_PLAIN_ARRAY_SMALL"); + if (type_id_kind_anonymous_array_Color_3 == "TI_PLAIN_ARRAY_SMALL") + { + SBoundSeq array_bound_seq; + TypeObjectUtils::add_array_dimension(array_bound_seq, static_cast(3)); + + PlainArraySElemDefn array_sdefn = TypeObjectUtils::build_plain_array_s_elem_defn(header_anonymous_array_Color_3, array_bound_seq, + eprosima::fastcdr::external(element_identifier_anonymous_array_Color_3)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_array_type_identifier(array_sdefn, "anonymous_array_Color_3")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_Color_3 already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBoundSeq array_bound_seq; + TypeObjectUtils::add_array_dimension(array_bound_seq, static_cast(3)); + + PlainArrayLElemDefn array_ldefn = TypeObjectUtils::build_plain_array_l_elem_defn(header_anonymous_array_Color_3, array_bound_seq, + eprosima::fastcdr::external(element_identifier_anonymous_array_Color_3)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_array_type_identifier(array_ldefn, "anonymous_array_Color_3")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_Color_3 already registered in TypeObjectRegistry for a different type."); + } + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_array_Color_3", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_Color_3: Given Array TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_array_enum_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_array_enum_field; + MemberId member_id_array_enum_field = 0x0000001d; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_array_enum_field = TypeObjectUtils::build_common_struct_member(member_id_array_enum_field, member_flags_array_enum_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_array_enum_field = TypeObjectUtils::build_common_struct_member(member_id_array_enum_field, member_flags_array_enum_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure array_enum_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_array_enum_field = "array_enum_field"; + eprosima::fastcdr::optional member_ann_builtin_array_enum_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_array_enum_field = TypeObjectUtils::build_complete_member_detail(name_array_enum_field, member_ann_builtin_array_enum_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_array_enum_field = TypeObjectUtils::build_complete_struct_member(common_array_enum_field, detail_array_enum_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_array_enum_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_array_Material_3", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "Material", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EnumTypeFlag enum_flags_Material = 0; + BitBound bit_bound_Material = 32; + CommonEnumeratedHeader common_Material = TypeObjectUtils::build_common_enumerated_header(bit_bound_Material); + QualifiedTypeName type_name_Material = "Material"; + eprosima::fastcdr::optional type_ann_builtin_Material; + eprosima::fastcdr::optional ann_custom_Material; + CompleteTypeDetail detail_Material = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_Material, ann_custom_Material, type_name_Material.to_string()); + CompleteEnumeratedHeader header_Material = TypeObjectUtils::build_complete_enumerated_header(common_Material, detail_Material); + CompleteEnumeratedLiteralSeq literal_seq_Material; + { + EnumeratedLiteralFlag flags_WOOD = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_WOOD = TypeObjectUtils::build_common_enumerated_literal(0, flags_WOOD); + eprosima::fastcdr::optional member_ann_builtin_WOOD; + ann_custom_Material.reset(); + MemberName name_WOOD = "WOOD"; + CompleteMemberDetail detail_WOOD = TypeObjectUtils::build_complete_member_detail(name_WOOD, member_ann_builtin_WOOD, ann_custom_Material); + CompleteEnumeratedLiteral literal_WOOD = TypeObjectUtils::build_complete_enumerated_literal(common_WOOD, detail_WOOD); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Material, literal_WOOD); + } + { + EnumeratedLiteralFlag flags_PLASTIC = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_PLASTIC = TypeObjectUtils::build_common_enumerated_literal(1, flags_PLASTIC); + eprosima::fastcdr::optional member_ann_builtin_PLASTIC; + ann_custom_Material.reset(); + MemberName name_PLASTIC = "PLASTIC"; + CompleteMemberDetail detail_PLASTIC = TypeObjectUtils::build_complete_member_detail(name_PLASTIC, member_ann_builtin_PLASTIC, ann_custom_Material); + CompleteEnumeratedLiteral literal_PLASTIC = TypeObjectUtils::build_complete_enumerated_literal(common_PLASTIC, detail_PLASTIC); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Material, literal_PLASTIC); + } + { + EnumeratedLiteralFlag flags_METAL = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_METAL = TypeObjectUtils::build_common_enumerated_literal(2, flags_METAL); + eprosima::fastcdr::optional member_ann_builtin_METAL; + ann_custom_Material.reset(); + MemberName name_METAL = "METAL"; + CompleteMemberDetail detail_METAL = TypeObjectUtils::build_complete_member_detail(name_METAL, member_ann_builtin_METAL, ann_custom_Material); + CompleteEnumeratedLiteral literal_METAL = TypeObjectUtils::build_complete_enumerated_literal(common_METAL, detail_METAL); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Material, literal_METAL); + } + { + EnumeratedLiteralFlag flags_CONCRETE = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_CONCRETE = TypeObjectUtils::build_common_enumerated_literal(3, flags_CONCRETE); + eprosima::fastcdr::optional member_ann_builtin_CONCRETE; + ann_custom_Material.reset(); + MemberName name_CONCRETE = "CONCRETE"; + CompleteMemberDetail detail_CONCRETE = TypeObjectUtils::build_complete_member_detail(name_CONCRETE, member_ann_builtin_CONCRETE, ann_custom_Material); + CompleteEnumeratedLiteral literal_CONCRETE = TypeObjectUtils::build_complete_enumerated_literal(common_CONCRETE, detail_CONCRETE); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Material, literal_CONCRETE); + } + { + EnumeratedLiteralFlag flags_STONE = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_STONE = TypeObjectUtils::build_common_enumerated_literal(4, flags_STONE); + eprosima::fastcdr::optional member_ann_builtin_STONE; + ann_custom_Material.reset(); + MemberName name_STONE = "STONE"; + CompleteMemberDetail detail_STONE = TypeObjectUtils::build_complete_member_detail(name_STONE, member_ann_builtin_STONE, ann_custom_Material); + CompleteEnumeratedLiteral literal_STONE = TypeObjectUtils::build_complete_enumerated_literal(common_STONE, detail_STONE); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Material, literal_STONE); + } + CompleteEnumeratedType enumerated_type_Material = TypeObjectUtils::build_complete_enumerated_type(enum_flags_Material, header_Material, + literal_seq_Material); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_enumerated_type_object(enumerated_type_Material, type_name_Material.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Material already registered in TypeObjectRegistry for a different type."); + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "Material", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Material: Given Enum TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + TypeIdentifier* element_identifier_anonymous_array_Material_3 {nullptr}; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_array_Material_3 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_array_Material_3 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Array element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_array_Material_3 = EK_COMPLETE; + if (TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d()) + { + equiv_kind_anonymous_array_Material_3 = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_array_Material_3 = 0; + PlainCollectionHeader header_anonymous_array_Material_3 = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_array_Material_3, element_flags_anonymous_array_Material_3); + std::string type_id_kind_anonymous_array_Material_3("TI_PLAIN_ARRAY_SMALL"); + if (type_id_kind_anonymous_array_Material_3 == "TI_PLAIN_ARRAY_SMALL") + { + SBoundSeq array_bound_seq; + TypeObjectUtils::add_array_dimension(array_bound_seq, static_cast(3)); + + PlainArraySElemDefn array_sdefn = TypeObjectUtils::build_plain_array_s_elem_defn(header_anonymous_array_Material_3, array_bound_seq, + eprosima::fastcdr::external(element_identifier_anonymous_array_Material_3)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_array_type_identifier(array_sdefn, "anonymous_array_Material_3")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_Material_3 already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBoundSeq array_bound_seq; + TypeObjectUtils::add_array_dimension(array_bound_seq, static_cast(3)); + + PlainArrayLElemDefn array_ldefn = TypeObjectUtils::build_plain_array_l_elem_defn(header_anonymous_array_Material_3, array_bound_seq, + eprosima::fastcdr::external(element_identifier_anonymous_array_Material_3)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_array_type_identifier(array_ldefn, "anonymous_array_Material_3")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_Material_3 already registered in TypeObjectRegistry for a different type."); + } + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_array_Material_3", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_Material_3: Given Array TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_array_enum2_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_array_enum2_field; + MemberId member_id_array_enum2_field = 0x0000001e; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_array_enum2_field = TypeObjectUtils::build_common_struct_member(member_id_array_enum2_field, member_flags_array_enum2_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_array_enum2_field = TypeObjectUtils::build_common_struct_member(member_id_array_enum2_field, member_flags_array_enum2_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure array_enum2_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_array_enum2_field = "array_enum2_field"; + eprosima::fastcdr::optional member_ann_builtin_array_enum2_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_array_enum2_field = TypeObjectUtils::build_complete_member_detail(name_array_enum2_field, member_ann_builtin_array_enum2_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_array_enum2_field = TypeObjectUtils::build_complete_struct_member(common_array_enum2_field, detail_array_enum2_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_array_enum2_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_array_StructType_3", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "StructType", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + { + StructTypeFlag struct_flags_StructType = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::NOT_APPLIED, + true, false); + ReturnCode_t return_code_StructType; + TypeIdentifierPair type_ids_StructType; + QualifiedTypeName type_name_StructType = "StructType"; + eprosima::fastcdr::optional type_ann_builtin_StructType; + eprosima::fastcdr::optional ann_custom_StructType; + AppliedAnnotationSeq tmp_ann_custom_StructType; + eprosima::fastcdr::optional verbatim_StructType; + if (!tmp_ann_custom_StructType.empty()) + { + ann_custom_StructType = tmp_ann_custom_StructType; + } + + CompleteTypeDetail detail_StructType = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_StructType, ann_custom_StructType, type_name_StructType.to_string()); + CompleteStructHeader header_StructType; + header_StructType = TypeObjectUtils::build_complete_struct_header(TypeIdentifier(), detail_StructType); + CompleteStructMemberSeq member_seq_StructType; + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_char", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "char_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_char_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_char_field; + MemberId member_id_char_field = 0x00000000; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_char_field = TypeObjectUtils::build_common_struct_member(member_id_char_field, member_flags_char_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_char_field = TypeObjectUtils::build_common_struct_member(member_id_char_field, member_flags_char_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure char_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_char_field = "char_field"; + eprosima::fastcdr::optional member_ann_builtin_char_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_char_field = TypeObjectUtils::build_complete_member_detail(name_char_field, member_ann_builtin_char_field, ann_custom_StructType); + CompleteStructMember member_char_field = TypeObjectUtils::build_complete_struct_member(common_char_field, detail_char_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_char_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_byte", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "uint8_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_uint8_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_uint8_field; + MemberId member_id_uint8_field = 0x00000001; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_uint8_field = TypeObjectUtils::build_common_struct_member(member_id_uint8_field, member_flags_uint8_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_uint8_field = TypeObjectUtils::build_common_struct_member(member_id_uint8_field, member_flags_uint8_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure uint8_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_uint8_field = "uint8_field"; + eprosima::fastcdr::optional member_ann_builtin_uint8_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_uint8_field = TypeObjectUtils::build_complete_member_detail(name_uint8_field, member_ann_builtin_uint8_field, ann_custom_StructType); + CompleteStructMember member_uint8_field = TypeObjectUtils::build_complete_struct_member(common_uint8_field, detail_uint8_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_uint8_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_int16_t", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "int16_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_int16_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_int16_field; + MemberId member_id_int16_field = 0x00000002; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_int16_field = TypeObjectUtils::build_common_struct_member(member_id_int16_field, member_flags_int16_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_int16_field = TypeObjectUtils::build_common_struct_member(member_id_int16_field, member_flags_int16_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure int16_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_int16_field = "int16_field"; + eprosima::fastcdr::optional member_ann_builtin_int16_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_int16_field = TypeObjectUtils::build_complete_member_detail(name_int16_field, member_ann_builtin_int16_field, ann_custom_StructType); + CompleteStructMember member_int16_field = TypeObjectUtils::build_complete_struct_member(common_int16_field, detail_int16_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_int16_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_uint16_t", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "uint16_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_uint16_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_uint16_field; + MemberId member_id_uint16_field = 0x00000003; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_uint16_field = TypeObjectUtils::build_common_struct_member(member_id_uint16_field, member_flags_uint16_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_uint16_field = TypeObjectUtils::build_common_struct_member(member_id_uint16_field, member_flags_uint16_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure uint16_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_uint16_field = "uint16_field"; + eprosima::fastcdr::optional member_ann_builtin_uint16_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_uint16_field = TypeObjectUtils::build_complete_member_detail(name_uint16_field, member_ann_builtin_uint16_field, ann_custom_StructType); + CompleteStructMember member_uint16_field = TypeObjectUtils::build_complete_struct_member(common_uint16_field, detail_uint16_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_uint16_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_int32_t", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "int32_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_int32_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_int32_field; + MemberId member_id_int32_field = 0x00000004; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_int32_field = TypeObjectUtils::build_common_struct_member(member_id_int32_field, member_flags_int32_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_int32_field = TypeObjectUtils::build_common_struct_member(member_id_int32_field, member_flags_int32_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure int32_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_int32_field = "int32_field"; + eprosima::fastcdr::optional member_ann_builtin_int32_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_int32_field = TypeObjectUtils::build_complete_member_detail(name_int32_field, member_ann_builtin_int32_field, ann_custom_StructType); + CompleteStructMember member_int32_field = TypeObjectUtils::build_complete_struct_member(common_int32_field, detail_int32_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_int32_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_uint32_t", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "uint32_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_uint32_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_uint32_field; + MemberId member_id_uint32_field = 0x00000005; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_uint32_field = TypeObjectUtils::build_common_struct_member(member_id_uint32_field, member_flags_uint32_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_uint32_field = TypeObjectUtils::build_common_struct_member(member_id_uint32_field, member_flags_uint32_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure uint32_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_uint32_field = "uint32_field"; + eprosima::fastcdr::optional member_ann_builtin_uint32_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_uint32_field = TypeObjectUtils::build_complete_member_detail(name_uint32_field, member_ann_builtin_uint32_field, ann_custom_StructType); + CompleteStructMember member_uint32_field = TypeObjectUtils::build_complete_struct_member(common_uint32_field, detail_uint32_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_uint32_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_int64_t", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "int64_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_int64_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_int64_field; + MemberId member_id_int64_field = 0x00000006; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_int64_field = TypeObjectUtils::build_common_struct_member(member_id_int64_field, member_flags_int64_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_int64_field = TypeObjectUtils::build_common_struct_member(member_id_int64_field, member_flags_int64_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure int64_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_int64_field = "int64_field"; + eprosima::fastcdr::optional member_ann_builtin_int64_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_int64_field = TypeObjectUtils::build_complete_member_detail(name_int64_field, member_ann_builtin_int64_field, ann_custom_StructType); + CompleteStructMember member_int64_field = TypeObjectUtils::build_complete_struct_member(common_int64_field, detail_int64_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_int64_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_uint64_t", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "uint64_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_uint64_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_uint64_field; + MemberId member_id_uint64_field = 0x00000007; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_uint64_field = TypeObjectUtils::build_common_struct_member(member_id_uint64_field, member_flags_uint64_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_uint64_field = TypeObjectUtils::build_common_struct_member(member_id_uint64_field, member_flags_uint64_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure uint64_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_uint64_field = "uint64_field"; + eprosima::fastcdr::optional member_ann_builtin_uint64_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_uint64_field = TypeObjectUtils::build_complete_member_detail(name_uint64_field, member_ann_builtin_uint64_field, ann_custom_StructType); + CompleteStructMember member_uint64_field = TypeObjectUtils::build_complete_struct_member(common_uint64_field, detail_uint64_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_uint64_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_float", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "float_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_float_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_float_field; + MemberId member_id_float_field = 0x00000008; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_float_field = TypeObjectUtils::build_common_struct_member(member_id_float_field, member_flags_float_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_float_field = TypeObjectUtils::build_common_struct_member(member_id_float_field, member_flags_float_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure float_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_float_field = "float_field"; + eprosima::fastcdr::optional member_ann_builtin_float_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_float_field = TypeObjectUtils::build_complete_member_detail(name_float_field, member_ann_builtin_float_field, ann_custom_StructType); + CompleteStructMember member_float_field = TypeObjectUtils::build_complete_struct_member(common_float_field, detail_float_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_float_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_double", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "double_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_double_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_double_field; + MemberId member_id_double_field = 0x00000009; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_double_field = TypeObjectUtils::build_common_struct_member(member_id_double_field, member_flags_double_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_double_field = TypeObjectUtils::build_common_struct_member(member_id_double_field, member_flags_double_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure double_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_double_field = "double_field"; + eprosima::fastcdr::optional member_ann_builtin_double_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_double_field = TypeObjectUtils::build_complete_member_detail(name_double_field, member_ann_builtin_double_field, ann_custom_StructType); + CompleteStructMember member_double_field = TypeObjectUtils::build_complete_struct_member(common_double_field, detail_double_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_double_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_longdouble", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "long_double_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_long_double_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_long_double_field; + MemberId member_id_long_double_field = 0x0000000a; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_long_double_field = TypeObjectUtils::build_common_struct_member(member_id_long_double_field, member_flags_long_double_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_long_double_field = TypeObjectUtils::build_common_struct_member(member_id_long_double_field, member_flags_long_double_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure long_double_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_long_double_field = "long_double_field"; + eprosima::fastcdr::optional member_ann_builtin_long_double_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_long_double_field = TypeObjectUtils::build_complete_member_detail(name_long_double_field, member_ann_builtin_long_double_field, ann_custom_StructType); + CompleteStructMember member_long_double_field = TypeObjectUtils::build_complete_struct_member(common_long_double_field, detail_long_double_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_long_double_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_bool", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "bool_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_bool_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_bool_field; + MemberId member_id_bool_field = 0x0000000b; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_bool_field = TypeObjectUtils::build_common_struct_member(member_id_bool_field, member_flags_bool_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_bool_field = TypeObjectUtils::build_common_struct_member(member_id_bool_field, member_flags_bool_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure bool_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_bool_field = "bool_field"; + eprosima::fastcdr::optional member_ann_builtin_bool_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_bool_field = TypeObjectUtils::build_complete_member_detail(name_bool_field, member_ann_builtin_bool_field, ann_custom_StructType); + CompleteStructMember member_bool_field = TypeObjectUtils::build_complete_struct_member(common_bool_field, detail_bool_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_bool_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_string_unbounded", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + std::string type_id_kind_anonymous_string_unbounded("TI_STRING8_SMALL"); + if (type_id_kind_anonymous_string_unbounded == "TI_STRING8_SMALL") + { + SBound bound = 0; + StringSTypeDefn string_sdefn = TypeObjectUtils::build_string_s_type_defn(bound); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_string_type_identifier(string_sdefn, + "anonymous_string_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else if (type_id_kind_anonymous_string_unbounded == "TI_STRING8_LARGE") + { + LBound bound = 255; + StringLTypeDefn string_ldefn = TypeObjectUtils::build_string_l_type_defn(bound); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_string_type_identifier(string_ldefn, + "anonymous_string_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded: Unknown String kind."); + return; + } + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_string_unbounded", type_ids_StructType); + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded: Given String TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_string_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_string_field; + MemberId member_id_string_field = 0x0000000c; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_string_field = TypeObjectUtils::build_common_struct_member(member_id_string_field, member_flags_string_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_string_field = TypeObjectUtils::build_common_struct_member(member_id_string_field, member_flags_string_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure string_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_string_field = "string_field"; + eprosima::fastcdr::optional member_ann_builtin_string_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_string_field = TypeObjectUtils::build_complete_member_detail(name_string_field, member_ann_builtin_string_field, ann_custom_StructType); + CompleteStructMember member_string_field = TypeObjectUtils::build_complete_struct_member(common_string_field, detail_string_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_string_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "Color", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EnumTypeFlag enum_flags_Color = 0; + BitBound bit_bound_Color = 32; + CommonEnumeratedHeader common_Color = TypeObjectUtils::build_common_enumerated_header(bit_bound_Color); + QualifiedTypeName type_name_Color = "Color"; + eprosima::fastcdr::optional type_ann_builtin_Color; + eprosima::fastcdr::optional ann_custom_Color; + CompleteTypeDetail detail_Color = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_Color, ann_custom_Color, type_name_Color.to_string()); + CompleteEnumeratedHeader header_Color = TypeObjectUtils::build_complete_enumerated_header(common_Color, detail_Color); + CompleteEnumeratedLiteralSeq literal_seq_Color; + { + EnumeratedLiteralFlag flags_RED = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_RED = TypeObjectUtils::build_common_enumerated_literal(0, flags_RED); + eprosima::fastcdr::optional member_ann_builtin_RED; + ann_custom_Color.reset(); + MemberName name_RED = "RED"; + CompleteMemberDetail detail_RED = TypeObjectUtils::build_complete_member_detail(name_RED, member_ann_builtin_RED, ann_custom_Color); + CompleteEnumeratedLiteral literal_RED = TypeObjectUtils::build_complete_enumerated_literal(common_RED, detail_RED); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Color, literal_RED); + } + { + EnumeratedLiteralFlag flags_GREEN = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_GREEN = TypeObjectUtils::build_common_enumerated_literal(1, flags_GREEN); + eprosima::fastcdr::optional member_ann_builtin_GREEN; + ann_custom_Color.reset(); + MemberName name_GREEN = "GREEN"; + CompleteMemberDetail detail_GREEN = TypeObjectUtils::build_complete_member_detail(name_GREEN, member_ann_builtin_GREEN, ann_custom_Color); + CompleteEnumeratedLiteral literal_GREEN = TypeObjectUtils::build_complete_enumerated_literal(common_GREEN, detail_GREEN); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Color, literal_GREEN); + } + { + EnumeratedLiteralFlag flags_BLUE = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_BLUE = TypeObjectUtils::build_common_enumerated_literal(2, flags_BLUE); + eprosima::fastcdr::optional member_ann_builtin_BLUE; + ann_custom_Color.reset(); + MemberName name_BLUE = "BLUE"; + CompleteMemberDetail detail_BLUE = TypeObjectUtils::build_complete_member_detail(name_BLUE, member_ann_builtin_BLUE, ann_custom_Color); + CompleteEnumeratedLiteral literal_BLUE = TypeObjectUtils::build_complete_enumerated_literal(common_BLUE, detail_BLUE); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Color, literal_BLUE); + } + { + EnumeratedLiteralFlag flags_YELLOW = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_YELLOW = TypeObjectUtils::build_common_enumerated_literal(3, flags_YELLOW); + eprosima::fastcdr::optional member_ann_builtin_YELLOW; + ann_custom_Color.reset(); + MemberName name_YELLOW = "YELLOW"; + CompleteMemberDetail detail_YELLOW = TypeObjectUtils::build_complete_member_detail(name_YELLOW, member_ann_builtin_YELLOW, ann_custom_Color); + CompleteEnumeratedLiteral literal_YELLOW = TypeObjectUtils::build_complete_enumerated_literal(common_YELLOW, detail_YELLOW); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Color, literal_YELLOW); + } + { + EnumeratedLiteralFlag flags_MAGENTA = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_MAGENTA = TypeObjectUtils::build_common_enumerated_literal(4, flags_MAGENTA); + eprosima::fastcdr::optional member_ann_builtin_MAGENTA; + ann_custom_Color.reset(); + MemberName name_MAGENTA = "MAGENTA"; + CompleteMemberDetail detail_MAGENTA = TypeObjectUtils::build_complete_member_detail(name_MAGENTA, member_ann_builtin_MAGENTA, ann_custom_Color); + CompleteEnumeratedLiteral literal_MAGENTA = TypeObjectUtils::build_complete_enumerated_literal(common_MAGENTA, detail_MAGENTA); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Color, literal_MAGENTA); + } + CompleteEnumeratedType enumerated_type_Color = TypeObjectUtils::build_complete_enumerated_type(enum_flags_Color, header_Color, + literal_seq_Color); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_enumerated_type_object(enumerated_type_Color, type_name_Color.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Color already registered in TypeObjectRegistry for a different type."); + } + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "Color", type_ids_StructType); + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Color: Given Enum TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_enum_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_enum_field; + MemberId member_id_enum_field = 0x0000000d; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_enum_field = TypeObjectUtils::build_common_struct_member(member_id_enum_field, member_flags_enum_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_enum_field = TypeObjectUtils::build_common_struct_member(member_id_enum_field, member_flags_enum_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure enum_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_enum_field = "enum_field"; + eprosima::fastcdr::optional member_ann_builtin_enum_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_enum_field = TypeObjectUtils::build_complete_member_detail(name_enum_field, member_ann_builtin_enum_field, ann_custom_StructType); + CompleteStructMember member_enum_field = TypeObjectUtils::build_complete_struct_member(common_enum_field, detail_enum_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_enum_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "Material", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EnumTypeFlag enum_flags_Material = 0; + BitBound bit_bound_Material = 32; + CommonEnumeratedHeader common_Material = TypeObjectUtils::build_common_enumerated_header(bit_bound_Material); + QualifiedTypeName type_name_Material = "Material"; + eprosima::fastcdr::optional type_ann_builtin_Material; + eprosima::fastcdr::optional ann_custom_Material; + CompleteTypeDetail detail_Material = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_Material, ann_custom_Material, type_name_Material.to_string()); + CompleteEnumeratedHeader header_Material = TypeObjectUtils::build_complete_enumerated_header(common_Material, detail_Material); + CompleteEnumeratedLiteralSeq literal_seq_Material; + { + EnumeratedLiteralFlag flags_WOOD = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_WOOD = TypeObjectUtils::build_common_enumerated_literal(0, flags_WOOD); + eprosima::fastcdr::optional member_ann_builtin_WOOD; + ann_custom_Material.reset(); + MemberName name_WOOD = "WOOD"; + CompleteMemberDetail detail_WOOD = TypeObjectUtils::build_complete_member_detail(name_WOOD, member_ann_builtin_WOOD, ann_custom_Material); + CompleteEnumeratedLiteral literal_WOOD = TypeObjectUtils::build_complete_enumerated_literal(common_WOOD, detail_WOOD); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Material, literal_WOOD); + } + { + EnumeratedLiteralFlag flags_PLASTIC = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_PLASTIC = TypeObjectUtils::build_common_enumerated_literal(1, flags_PLASTIC); + eprosima::fastcdr::optional member_ann_builtin_PLASTIC; + ann_custom_Material.reset(); + MemberName name_PLASTIC = "PLASTIC"; + CompleteMemberDetail detail_PLASTIC = TypeObjectUtils::build_complete_member_detail(name_PLASTIC, member_ann_builtin_PLASTIC, ann_custom_Material); + CompleteEnumeratedLiteral literal_PLASTIC = TypeObjectUtils::build_complete_enumerated_literal(common_PLASTIC, detail_PLASTIC); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Material, literal_PLASTIC); + } + { + EnumeratedLiteralFlag flags_METAL = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_METAL = TypeObjectUtils::build_common_enumerated_literal(2, flags_METAL); + eprosima::fastcdr::optional member_ann_builtin_METAL; + ann_custom_Material.reset(); + MemberName name_METAL = "METAL"; + CompleteMemberDetail detail_METAL = TypeObjectUtils::build_complete_member_detail(name_METAL, member_ann_builtin_METAL, ann_custom_Material); + CompleteEnumeratedLiteral literal_METAL = TypeObjectUtils::build_complete_enumerated_literal(common_METAL, detail_METAL); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Material, literal_METAL); + } + { + EnumeratedLiteralFlag flags_CONCRETE = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_CONCRETE = TypeObjectUtils::build_common_enumerated_literal(3, flags_CONCRETE); + eprosima::fastcdr::optional member_ann_builtin_CONCRETE; + ann_custom_Material.reset(); + MemberName name_CONCRETE = "CONCRETE"; + CompleteMemberDetail detail_CONCRETE = TypeObjectUtils::build_complete_member_detail(name_CONCRETE, member_ann_builtin_CONCRETE, ann_custom_Material); + CompleteEnumeratedLiteral literal_CONCRETE = TypeObjectUtils::build_complete_enumerated_literal(common_CONCRETE, detail_CONCRETE); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Material, literal_CONCRETE); + } + { + EnumeratedLiteralFlag flags_STONE = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_STONE = TypeObjectUtils::build_common_enumerated_literal(4, flags_STONE); + eprosima::fastcdr::optional member_ann_builtin_STONE; + ann_custom_Material.reset(); + MemberName name_STONE = "STONE"; + CompleteMemberDetail detail_STONE = TypeObjectUtils::build_complete_member_detail(name_STONE, member_ann_builtin_STONE, ann_custom_Material); + CompleteEnumeratedLiteral literal_STONE = TypeObjectUtils::build_complete_enumerated_literal(common_STONE, detail_STONE); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Material, literal_STONE); + } + CompleteEnumeratedType enumerated_type_Material = TypeObjectUtils::build_complete_enumerated_type(enum_flags_Material, header_Material, + literal_seq_Material); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_enumerated_type_object(enumerated_type_Material, type_name_Material.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Material already registered in TypeObjectRegistry for a different type."); + } + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "Material", type_ids_StructType); + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Material: Given Enum TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_enum2_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_enum2_field; + MemberId member_id_enum2_field = 0x0000000e; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_enum2_field = TypeObjectUtils::build_common_struct_member(member_id_enum2_field, member_flags_enum2_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_enum2_field = TypeObjectUtils::build_common_struct_member(member_id_enum2_field, member_flags_enum2_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure enum2_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_enum2_field = "enum2_field"; + eprosima::fastcdr::optional member_ann_builtin_enum2_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_enum2_field = TypeObjectUtils::build_complete_member_detail(name_enum2_field, member_ann_builtin_enum2_field, ann_custom_StructType); + CompleteStructMember member_enum2_field = TypeObjectUtils::build_complete_struct_member(common_enum2_field, detail_enum2_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_enum2_field); + } + CompleteStructType struct_type_StructType = TypeObjectUtils::build_complete_struct_type(struct_flags_StructType, header_StructType, member_seq_StructType); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_struct_type_object(struct_type_StructType, type_name_StructType.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "StructType already registered in TypeObjectRegistry for a different type."); + } + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "StructType", type_ids_StructType); + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "StructType: Given Struct TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + } + TypeIdentifier* element_identifier_anonymous_array_StructType_3 {nullptr}; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_array_StructType_3 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_array_StructType_3 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Array element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_array_StructType_3 = EK_COMPLETE; + if (TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d()) + { + equiv_kind_anonymous_array_StructType_3 = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_array_StructType_3 = 0; + PlainCollectionHeader header_anonymous_array_StructType_3 = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_array_StructType_3, element_flags_anonymous_array_StructType_3); + std::string type_id_kind_anonymous_array_StructType_3("TI_PLAIN_ARRAY_SMALL"); + if (type_id_kind_anonymous_array_StructType_3 == "TI_PLAIN_ARRAY_SMALL") + { + SBoundSeq array_bound_seq; + TypeObjectUtils::add_array_dimension(array_bound_seq, static_cast(3)); + + PlainArraySElemDefn array_sdefn = TypeObjectUtils::build_plain_array_s_elem_defn(header_anonymous_array_StructType_3, array_bound_seq, + eprosima::fastcdr::external(element_identifier_anonymous_array_StructType_3)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_array_type_identifier(array_sdefn, "anonymous_array_StructType_3")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_StructType_3 already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBoundSeq array_bound_seq; + TypeObjectUtils::add_array_dimension(array_bound_seq, static_cast(3)); + + PlainArrayLElemDefn array_ldefn = TypeObjectUtils::build_plain_array_l_elem_defn(header_anonymous_array_StructType_3, array_bound_seq, + eprosima::fastcdr::external(element_identifier_anonymous_array_StructType_3)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_array_type_identifier(array_ldefn, "anonymous_array_StructType_3")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_StructType_3 already registered in TypeObjectRegistry for a different type."); + } + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_array_StructType_3", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_array_StructType_3: Given Array TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_array_struct_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_array_struct_field; + MemberId member_id_array_struct_field = 0x0000001f; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_array_struct_field = TypeObjectUtils::build_common_struct_member(member_id_array_struct_field, member_flags_array_struct_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_array_struct_field = TypeObjectUtils::build_common_struct_member(member_id_array_struct_field, member_flags_array_struct_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure array_struct_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_array_struct_field = "array_struct_field"; + eprosima::fastcdr::optional member_ann_builtin_array_struct_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_array_struct_field = TypeObjectUtils::build_complete_member_detail(name_array_struct_field, member_ann_builtin_array_struct_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_array_struct_field = TypeObjectUtils::build_complete_struct_member(common_array_struct_field, detail_array_struct_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_array_struct_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_char_5", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_char", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + TypeIdentifier* element_identifier_anonymous_sequence_char_5 {nullptr}; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_char_5 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_char_5 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_sequence_char_5 = EK_COMPLETE; + if (TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d()) + { + equiv_kind_anonymous_sequence_char_5 = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_sequence_char_5 = 0; + PlainCollectionHeader header_anonymous_sequence_char_5 = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_sequence_char_5, element_flags_anonymous_sequence_char_5); + std::string type_id_kind_anonymous_sequence_char_5("TI_PLAIN_SEQUENCE_SMALL"); + if (type_id_kind_anonymous_sequence_char_5 == "TI_PLAIN_SEQUENCE_SMALL") + { + SBound bound = static_cast(5); + PlainSequenceSElemDefn seq_sdefn = TypeObjectUtils::build_plain_sequence_s_elem_defn(header_anonymous_sequence_char_5, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_char_5)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_sequence_type_identifier(seq_sdefn, "anonymous_sequence_char_5")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_char_5 already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBound bound = 5; + PlainSequenceLElemDefn seq_ldefn = TypeObjectUtils::build_plain_sequence_l_elem_defn(header_anonymous_sequence_char_5, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_char_5)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_sequence_type_identifier(seq_ldefn, "anonymous_sequence_char_5")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_char_5 already registered in TypeObjectRegistry for a different type."); + } + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_char_5", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_char_5: Given Sequence TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_bounded_sequence_char_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_bounded_sequence_char_field; + MemberId member_id_bounded_sequence_char_field = 0x00000020; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_bounded_sequence_char_field = TypeObjectUtils::build_common_struct_member(member_id_bounded_sequence_char_field, member_flags_bounded_sequence_char_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_bounded_sequence_char_field = TypeObjectUtils::build_common_struct_member(member_id_bounded_sequence_char_field, member_flags_bounded_sequence_char_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure bounded_sequence_char_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_bounded_sequence_char_field = "bounded_sequence_char_field"; + eprosima::fastcdr::optional member_ann_builtin_bounded_sequence_char_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_bounded_sequence_char_field = TypeObjectUtils::build_complete_member_detail(name_bounded_sequence_char_field, member_ann_builtin_bounded_sequence_char_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_bounded_sequence_char_field = TypeObjectUtils::build_complete_struct_member(common_bounded_sequence_char_field, detail_bounded_sequence_char_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_bounded_sequence_char_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_uint8_t_5", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_byte", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + TypeIdentifier* element_identifier_anonymous_sequence_uint8_t_5 {nullptr}; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_uint8_t_5 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_uint8_t_5 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_sequence_uint8_t_5 = EK_COMPLETE; + if (TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d()) + { + equiv_kind_anonymous_sequence_uint8_t_5 = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_sequence_uint8_t_5 = 0; + PlainCollectionHeader header_anonymous_sequence_uint8_t_5 = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_sequence_uint8_t_5, element_flags_anonymous_sequence_uint8_t_5); + std::string type_id_kind_anonymous_sequence_uint8_t_5("TI_PLAIN_SEQUENCE_SMALL"); + if (type_id_kind_anonymous_sequence_uint8_t_5 == "TI_PLAIN_SEQUENCE_SMALL") + { + SBound bound = static_cast(5); + PlainSequenceSElemDefn seq_sdefn = TypeObjectUtils::build_plain_sequence_s_elem_defn(header_anonymous_sequence_uint8_t_5, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_uint8_t_5)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_sequence_type_identifier(seq_sdefn, "anonymous_sequence_uint8_t_5")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_uint8_t_5 already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBound bound = 5; + PlainSequenceLElemDefn seq_ldefn = TypeObjectUtils::build_plain_sequence_l_elem_defn(header_anonymous_sequence_uint8_t_5, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_uint8_t_5)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_sequence_type_identifier(seq_ldefn, "anonymous_sequence_uint8_t_5")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_uint8_t_5 already registered in TypeObjectRegistry for a different type."); + } + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_uint8_t_5", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_uint8_t_5: Given Sequence TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_bounded_sequence_uint8_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_bounded_sequence_uint8_field; + MemberId member_id_bounded_sequence_uint8_field = 0x00000021; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_bounded_sequence_uint8_field = TypeObjectUtils::build_common_struct_member(member_id_bounded_sequence_uint8_field, member_flags_bounded_sequence_uint8_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_bounded_sequence_uint8_field = TypeObjectUtils::build_common_struct_member(member_id_bounded_sequence_uint8_field, member_flags_bounded_sequence_uint8_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure bounded_sequence_uint8_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_bounded_sequence_uint8_field = "bounded_sequence_uint8_field"; + eprosima::fastcdr::optional member_ann_builtin_bounded_sequence_uint8_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_bounded_sequence_uint8_field = TypeObjectUtils::build_complete_member_detail(name_bounded_sequence_uint8_field, member_ann_builtin_bounded_sequence_uint8_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_bounded_sequence_uint8_field = TypeObjectUtils::build_complete_struct_member(common_bounded_sequence_uint8_field, detail_bounded_sequence_uint8_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_bounded_sequence_uint8_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_int16_t_5", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_int16_t", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + TypeIdentifier* element_identifier_anonymous_sequence_int16_t_5 {nullptr}; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_int16_t_5 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_int16_t_5 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_sequence_int16_t_5 = EK_COMPLETE; + if (TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d()) + { + equiv_kind_anonymous_sequence_int16_t_5 = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_sequence_int16_t_5 = 0; + PlainCollectionHeader header_anonymous_sequence_int16_t_5 = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_sequence_int16_t_5, element_flags_anonymous_sequence_int16_t_5); + std::string type_id_kind_anonymous_sequence_int16_t_5("TI_PLAIN_SEQUENCE_SMALL"); + if (type_id_kind_anonymous_sequence_int16_t_5 == "TI_PLAIN_SEQUENCE_SMALL") + { + SBound bound = static_cast(5); + PlainSequenceSElemDefn seq_sdefn = TypeObjectUtils::build_plain_sequence_s_elem_defn(header_anonymous_sequence_int16_t_5, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_int16_t_5)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_sequence_type_identifier(seq_sdefn, "anonymous_sequence_int16_t_5")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_int16_t_5 already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBound bound = 5; + PlainSequenceLElemDefn seq_ldefn = TypeObjectUtils::build_plain_sequence_l_elem_defn(header_anonymous_sequence_int16_t_5, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_int16_t_5)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_sequence_type_identifier(seq_ldefn, "anonymous_sequence_int16_t_5")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_int16_t_5 already registered in TypeObjectRegistry for a different type."); + } + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_int16_t_5", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_int16_t_5: Given Sequence TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_bounded_sequence_int16_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_bounded_sequence_int16_field; + MemberId member_id_bounded_sequence_int16_field = 0x00000022; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_bounded_sequence_int16_field = TypeObjectUtils::build_common_struct_member(member_id_bounded_sequence_int16_field, member_flags_bounded_sequence_int16_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_bounded_sequence_int16_field = TypeObjectUtils::build_common_struct_member(member_id_bounded_sequence_int16_field, member_flags_bounded_sequence_int16_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure bounded_sequence_int16_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_bounded_sequence_int16_field = "bounded_sequence_int16_field"; + eprosima::fastcdr::optional member_ann_builtin_bounded_sequence_int16_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_bounded_sequence_int16_field = TypeObjectUtils::build_complete_member_detail(name_bounded_sequence_int16_field, member_ann_builtin_bounded_sequence_int16_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_bounded_sequence_int16_field = TypeObjectUtils::build_complete_struct_member(common_bounded_sequence_int16_field, detail_bounded_sequence_int16_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_bounded_sequence_int16_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_uint16_t_5", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_uint16_t", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + TypeIdentifier* element_identifier_anonymous_sequence_uint16_t_5 {nullptr}; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_uint16_t_5 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_uint16_t_5 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_sequence_uint16_t_5 = EK_COMPLETE; + if (TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d()) + { + equiv_kind_anonymous_sequence_uint16_t_5 = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_sequence_uint16_t_5 = 0; + PlainCollectionHeader header_anonymous_sequence_uint16_t_5 = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_sequence_uint16_t_5, element_flags_anonymous_sequence_uint16_t_5); + std::string type_id_kind_anonymous_sequence_uint16_t_5("TI_PLAIN_SEQUENCE_SMALL"); + if (type_id_kind_anonymous_sequence_uint16_t_5 == "TI_PLAIN_SEQUENCE_SMALL") + { + SBound bound = static_cast(5); + PlainSequenceSElemDefn seq_sdefn = TypeObjectUtils::build_plain_sequence_s_elem_defn(header_anonymous_sequence_uint16_t_5, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_uint16_t_5)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_sequence_type_identifier(seq_sdefn, "anonymous_sequence_uint16_t_5")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_uint16_t_5 already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBound bound = 5; + PlainSequenceLElemDefn seq_ldefn = TypeObjectUtils::build_plain_sequence_l_elem_defn(header_anonymous_sequence_uint16_t_5, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_uint16_t_5)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_sequence_type_identifier(seq_ldefn, "anonymous_sequence_uint16_t_5")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_uint16_t_5 already registered in TypeObjectRegistry for a different type."); + } + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_uint16_t_5", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_uint16_t_5: Given Sequence TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_bounded_sequence_uint16_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_bounded_sequence_uint16_field; + MemberId member_id_bounded_sequence_uint16_field = 0x00000023; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_bounded_sequence_uint16_field = TypeObjectUtils::build_common_struct_member(member_id_bounded_sequence_uint16_field, member_flags_bounded_sequence_uint16_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_bounded_sequence_uint16_field = TypeObjectUtils::build_common_struct_member(member_id_bounded_sequence_uint16_field, member_flags_bounded_sequence_uint16_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure bounded_sequence_uint16_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_bounded_sequence_uint16_field = "bounded_sequence_uint16_field"; + eprosima::fastcdr::optional member_ann_builtin_bounded_sequence_uint16_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_bounded_sequence_uint16_field = TypeObjectUtils::build_complete_member_detail(name_bounded_sequence_uint16_field, member_ann_builtin_bounded_sequence_uint16_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_bounded_sequence_uint16_field = TypeObjectUtils::build_complete_struct_member(common_bounded_sequence_uint16_field, detail_bounded_sequence_uint16_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_bounded_sequence_uint16_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_int32_t_5", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_int32_t", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + TypeIdentifier* element_identifier_anonymous_sequence_int32_t_5 {nullptr}; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_int32_t_5 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_int32_t_5 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_sequence_int32_t_5 = EK_COMPLETE; + if (TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d()) + { + equiv_kind_anonymous_sequence_int32_t_5 = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_sequence_int32_t_5 = 0; + PlainCollectionHeader header_anonymous_sequence_int32_t_5 = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_sequence_int32_t_5, element_flags_anonymous_sequence_int32_t_5); + std::string type_id_kind_anonymous_sequence_int32_t_5("TI_PLAIN_SEQUENCE_SMALL"); + if (type_id_kind_anonymous_sequence_int32_t_5 == "TI_PLAIN_SEQUENCE_SMALL") + { + SBound bound = static_cast(5); + PlainSequenceSElemDefn seq_sdefn = TypeObjectUtils::build_plain_sequence_s_elem_defn(header_anonymous_sequence_int32_t_5, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_int32_t_5)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_sequence_type_identifier(seq_sdefn, "anonymous_sequence_int32_t_5")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_int32_t_5 already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBound bound = 5; + PlainSequenceLElemDefn seq_ldefn = TypeObjectUtils::build_plain_sequence_l_elem_defn(header_anonymous_sequence_int32_t_5, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_int32_t_5)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_sequence_type_identifier(seq_ldefn, "anonymous_sequence_int32_t_5")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_int32_t_5 already registered in TypeObjectRegistry for a different type."); + } + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_int32_t_5", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_int32_t_5: Given Sequence TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_bounded_sequence_int32_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_bounded_sequence_int32_field; + MemberId member_id_bounded_sequence_int32_field = 0x00000024; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_bounded_sequence_int32_field = TypeObjectUtils::build_common_struct_member(member_id_bounded_sequence_int32_field, member_flags_bounded_sequence_int32_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_bounded_sequence_int32_field = TypeObjectUtils::build_common_struct_member(member_id_bounded_sequence_int32_field, member_flags_bounded_sequence_int32_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure bounded_sequence_int32_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_bounded_sequence_int32_field = "bounded_sequence_int32_field"; + eprosima::fastcdr::optional member_ann_builtin_bounded_sequence_int32_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_bounded_sequence_int32_field = TypeObjectUtils::build_complete_member_detail(name_bounded_sequence_int32_field, member_ann_builtin_bounded_sequence_int32_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_bounded_sequence_int32_field = TypeObjectUtils::build_complete_struct_member(common_bounded_sequence_int32_field, detail_bounded_sequence_int32_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_bounded_sequence_int32_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_uint32_t_5", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_uint32_t", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + TypeIdentifier* element_identifier_anonymous_sequence_uint32_t_5 {nullptr}; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_uint32_t_5 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_uint32_t_5 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_sequence_uint32_t_5 = EK_COMPLETE; + if (TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d()) + { + equiv_kind_anonymous_sequence_uint32_t_5 = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_sequence_uint32_t_5 = 0; + PlainCollectionHeader header_anonymous_sequence_uint32_t_5 = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_sequence_uint32_t_5, element_flags_anonymous_sequence_uint32_t_5); + std::string type_id_kind_anonymous_sequence_uint32_t_5("TI_PLAIN_SEQUENCE_SMALL"); + if (type_id_kind_anonymous_sequence_uint32_t_5 == "TI_PLAIN_SEQUENCE_SMALL") + { + SBound bound = static_cast(5); + PlainSequenceSElemDefn seq_sdefn = TypeObjectUtils::build_plain_sequence_s_elem_defn(header_anonymous_sequence_uint32_t_5, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_uint32_t_5)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_sequence_type_identifier(seq_sdefn, "anonymous_sequence_uint32_t_5")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_uint32_t_5 already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBound bound = 5; + PlainSequenceLElemDefn seq_ldefn = TypeObjectUtils::build_plain_sequence_l_elem_defn(header_anonymous_sequence_uint32_t_5, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_uint32_t_5)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_sequence_type_identifier(seq_ldefn, "anonymous_sequence_uint32_t_5")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_uint32_t_5 already registered in TypeObjectRegistry for a different type."); + } + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_uint32_t_5", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_uint32_t_5: Given Sequence TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_bounded_sequence_uint32_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_bounded_sequence_uint32_field; + MemberId member_id_bounded_sequence_uint32_field = 0x00000025; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_bounded_sequence_uint32_field = TypeObjectUtils::build_common_struct_member(member_id_bounded_sequence_uint32_field, member_flags_bounded_sequence_uint32_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_bounded_sequence_uint32_field = TypeObjectUtils::build_common_struct_member(member_id_bounded_sequence_uint32_field, member_flags_bounded_sequence_uint32_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure bounded_sequence_uint32_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_bounded_sequence_uint32_field = "bounded_sequence_uint32_field"; + eprosima::fastcdr::optional member_ann_builtin_bounded_sequence_uint32_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_bounded_sequence_uint32_field = TypeObjectUtils::build_complete_member_detail(name_bounded_sequence_uint32_field, member_ann_builtin_bounded_sequence_uint32_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_bounded_sequence_uint32_field = TypeObjectUtils::build_complete_struct_member(common_bounded_sequence_uint32_field, detail_bounded_sequence_uint32_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_bounded_sequence_uint32_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_int64_t_5", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_int64_t", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + TypeIdentifier* element_identifier_anonymous_sequence_int64_t_5 {nullptr}; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_int64_t_5 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_int64_t_5 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_sequence_int64_t_5 = EK_COMPLETE; + if (TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d()) + { + equiv_kind_anonymous_sequence_int64_t_5 = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_sequence_int64_t_5 = 0; + PlainCollectionHeader header_anonymous_sequence_int64_t_5 = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_sequence_int64_t_5, element_flags_anonymous_sequence_int64_t_5); + std::string type_id_kind_anonymous_sequence_int64_t_5("TI_PLAIN_SEQUENCE_SMALL"); + if (type_id_kind_anonymous_sequence_int64_t_5 == "TI_PLAIN_SEQUENCE_SMALL") + { + SBound bound = static_cast(5); + PlainSequenceSElemDefn seq_sdefn = TypeObjectUtils::build_plain_sequence_s_elem_defn(header_anonymous_sequence_int64_t_5, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_int64_t_5)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_sequence_type_identifier(seq_sdefn, "anonymous_sequence_int64_t_5")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_int64_t_5 already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBound bound = 5; + PlainSequenceLElemDefn seq_ldefn = TypeObjectUtils::build_plain_sequence_l_elem_defn(header_anonymous_sequence_int64_t_5, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_int64_t_5)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_sequence_type_identifier(seq_ldefn, "anonymous_sequence_int64_t_5")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_int64_t_5 already registered in TypeObjectRegistry for a different type."); + } + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_int64_t_5", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_int64_t_5: Given Sequence TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_bounded_sequence_int64_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_bounded_sequence_int64_field; + MemberId member_id_bounded_sequence_int64_field = 0x00000026; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_bounded_sequence_int64_field = TypeObjectUtils::build_common_struct_member(member_id_bounded_sequence_int64_field, member_flags_bounded_sequence_int64_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_bounded_sequence_int64_field = TypeObjectUtils::build_common_struct_member(member_id_bounded_sequence_int64_field, member_flags_bounded_sequence_int64_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure bounded_sequence_int64_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_bounded_sequence_int64_field = "bounded_sequence_int64_field"; + eprosima::fastcdr::optional member_ann_builtin_bounded_sequence_int64_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_bounded_sequence_int64_field = TypeObjectUtils::build_complete_member_detail(name_bounded_sequence_int64_field, member_ann_builtin_bounded_sequence_int64_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_bounded_sequence_int64_field = TypeObjectUtils::build_complete_struct_member(common_bounded_sequence_int64_field, detail_bounded_sequence_int64_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_bounded_sequence_int64_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_uint64_t_5", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_uint64_t", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + TypeIdentifier* element_identifier_anonymous_sequence_uint64_t_5 {nullptr}; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_uint64_t_5 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_uint64_t_5 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_sequence_uint64_t_5 = EK_COMPLETE; + if (TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d()) + { + equiv_kind_anonymous_sequence_uint64_t_5 = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_sequence_uint64_t_5 = 0; + PlainCollectionHeader header_anonymous_sequence_uint64_t_5 = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_sequence_uint64_t_5, element_flags_anonymous_sequence_uint64_t_5); + std::string type_id_kind_anonymous_sequence_uint64_t_5("TI_PLAIN_SEQUENCE_SMALL"); + if (type_id_kind_anonymous_sequence_uint64_t_5 == "TI_PLAIN_SEQUENCE_SMALL") + { + SBound bound = static_cast(5); + PlainSequenceSElemDefn seq_sdefn = TypeObjectUtils::build_plain_sequence_s_elem_defn(header_anonymous_sequence_uint64_t_5, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_uint64_t_5)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_sequence_type_identifier(seq_sdefn, "anonymous_sequence_uint64_t_5")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_uint64_t_5 already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBound bound = 5; + PlainSequenceLElemDefn seq_ldefn = TypeObjectUtils::build_plain_sequence_l_elem_defn(header_anonymous_sequence_uint64_t_5, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_uint64_t_5)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_sequence_type_identifier(seq_ldefn, "anonymous_sequence_uint64_t_5")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_uint64_t_5 already registered in TypeObjectRegistry for a different type."); + } + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_uint64_t_5", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_uint64_t_5: Given Sequence TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_bounded_sequence_uint64_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_bounded_sequence_uint64_field; + MemberId member_id_bounded_sequence_uint64_field = 0x00000027; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_bounded_sequence_uint64_field = TypeObjectUtils::build_common_struct_member(member_id_bounded_sequence_uint64_field, member_flags_bounded_sequence_uint64_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_bounded_sequence_uint64_field = TypeObjectUtils::build_common_struct_member(member_id_bounded_sequence_uint64_field, member_flags_bounded_sequence_uint64_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure bounded_sequence_uint64_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_bounded_sequence_uint64_field = "bounded_sequence_uint64_field"; + eprosima::fastcdr::optional member_ann_builtin_bounded_sequence_uint64_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_bounded_sequence_uint64_field = TypeObjectUtils::build_complete_member_detail(name_bounded_sequence_uint64_field, member_ann_builtin_bounded_sequence_uint64_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_bounded_sequence_uint64_field = TypeObjectUtils::build_complete_struct_member(common_bounded_sequence_uint64_field, detail_bounded_sequence_uint64_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_bounded_sequence_uint64_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_float_5", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_float", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + TypeIdentifier* element_identifier_anonymous_sequence_float_5 {nullptr}; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_float_5 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_float_5 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_sequence_float_5 = EK_COMPLETE; + if (TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d()) + { + equiv_kind_anonymous_sequence_float_5 = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_sequence_float_5 = 0; + PlainCollectionHeader header_anonymous_sequence_float_5 = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_sequence_float_5, element_flags_anonymous_sequence_float_5); + std::string type_id_kind_anonymous_sequence_float_5("TI_PLAIN_SEQUENCE_SMALL"); + if (type_id_kind_anonymous_sequence_float_5 == "TI_PLAIN_SEQUENCE_SMALL") + { + SBound bound = static_cast(5); + PlainSequenceSElemDefn seq_sdefn = TypeObjectUtils::build_plain_sequence_s_elem_defn(header_anonymous_sequence_float_5, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_float_5)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_sequence_type_identifier(seq_sdefn, "anonymous_sequence_float_5")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_float_5 already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBound bound = 5; + PlainSequenceLElemDefn seq_ldefn = TypeObjectUtils::build_plain_sequence_l_elem_defn(header_anonymous_sequence_float_5, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_float_5)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_sequence_type_identifier(seq_ldefn, "anonymous_sequence_float_5")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_float_5 already registered in TypeObjectRegistry for a different type."); + } + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_float_5", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_float_5: Given Sequence TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_bounded_sequence_float_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_bounded_sequence_float_field; + MemberId member_id_bounded_sequence_float_field = 0x00000028; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_bounded_sequence_float_field = TypeObjectUtils::build_common_struct_member(member_id_bounded_sequence_float_field, member_flags_bounded_sequence_float_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_bounded_sequence_float_field = TypeObjectUtils::build_common_struct_member(member_id_bounded_sequence_float_field, member_flags_bounded_sequence_float_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure bounded_sequence_float_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_bounded_sequence_float_field = "bounded_sequence_float_field"; + eprosima::fastcdr::optional member_ann_builtin_bounded_sequence_float_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_bounded_sequence_float_field = TypeObjectUtils::build_complete_member_detail(name_bounded_sequence_float_field, member_ann_builtin_bounded_sequence_float_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_bounded_sequence_float_field = TypeObjectUtils::build_complete_struct_member(common_bounded_sequence_float_field, detail_bounded_sequence_float_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_bounded_sequence_float_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_double_5", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_double", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + TypeIdentifier* element_identifier_anonymous_sequence_double_5 {nullptr}; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_double_5 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_double_5 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_sequence_double_5 = EK_COMPLETE; + if (TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d()) + { + equiv_kind_anonymous_sequence_double_5 = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_sequence_double_5 = 0; + PlainCollectionHeader header_anonymous_sequence_double_5 = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_sequence_double_5, element_flags_anonymous_sequence_double_5); + std::string type_id_kind_anonymous_sequence_double_5("TI_PLAIN_SEQUENCE_SMALL"); + if (type_id_kind_anonymous_sequence_double_5 == "TI_PLAIN_SEQUENCE_SMALL") + { + SBound bound = static_cast(5); + PlainSequenceSElemDefn seq_sdefn = TypeObjectUtils::build_plain_sequence_s_elem_defn(header_anonymous_sequence_double_5, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_double_5)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_sequence_type_identifier(seq_sdefn, "anonymous_sequence_double_5")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_double_5 already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBound bound = 5; + PlainSequenceLElemDefn seq_ldefn = TypeObjectUtils::build_plain_sequence_l_elem_defn(header_anonymous_sequence_double_5, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_double_5)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_sequence_type_identifier(seq_ldefn, "anonymous_sequence_double_5")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_double_5 already registered in TypeObjectRegistry for a different type."); + } + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_double_5", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_double_5: Given Sequence TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_bounded_sequence_double_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_bounded_sequence_double_field; + MemberId member_id_bounded_sequence_double_field = 0x00000029; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_bounded_sequence_double_field = TypeObjectUtils::build_common_struct_member(member_id_bounded_sequence_double_field, member_flags_bounded_sequence_double_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_bounded_sequence_double_field = TypeObjectUtils::build_common_struct_member(member_id_bounded_sequence_double_field, member_flags_bounded_sequence_double_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure bounded_sequence_double_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_bounded_sequence_double_field = "bounded_sequence_double_field"; + eprosima::fastcdr::optional member_ann_builtin_bounded_sequence_double_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_bounded_sequence_double_field = TypeObjectUtils::build_complete_member_detail(name_bounded_sequence_double_field, member_ann_builtin_bounded_sequence_double_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_bounded_sequence_double_field = TypeObjectUtils::build_complete_struct_member(common_bounded_sequence_double_field, detail_bounded_sequence_double_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_bounded_sequence_double_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_longdouble_5", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_longdouble", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + TypeIdentifier* element_identifier_anonymous_sequence_longdouble_5 {nullptr}; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_longdouble_5 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_longdouble_5 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_sequence_longdouble_5 = EK_COMPLETE; + if (TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d()) + { + equiv_kind_anonymous_sequence_longdouble_5 = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_sequence_longdouble_5 = 0; + PlainCollectionHeader header_anonymous_sequence_longdouble_5 = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_sequence_longdouble_5, element_flags_anonymous_sequence_longdouble_5); + std::string type_id_kind_anonymous_sequence_longdouble_5("TI_PLAIN_SEQUENCE_SMALL"); + if (type_id_kind_anonymous_sequence_longdouble_5 == "TI_PLAIN_SEQUENCE_SMALL") + { + SBound bound = static_cast(5); + PlainSequenceSElemDefn seq_sdefn = TypeObjectUtils::build_plain_sequence_s_elem_defn(header_anonymous_sequence_longdouble_5, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_longdouble_5)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_sequence_type_identifier(seq_sdefn, "anonymous_sequence_longdouble_5")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_longdouble_5 already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBound bound = 5; + PlainSequenceLElemDefn seq_ldefn = TypeObjectUtils::build_plain_sequence_l_elem_defn(header_anonymous_sequence_longdouble_5, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_longdouble_5)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_sequence_type_identifier(seq_ldefn, "anonymous_sequence_longdouble_5")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_longdouble_5 already registered in TypeObjectRegistry for a different type."); + } + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_longdouble_5", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_longdouble_5: Given Sequence TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_bounded_sequence_long_double_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_bounded_sequence_long_double_field; + MemberId member_id_bounded_sequence_long_double_field = 0x0000002a; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_bounded_sequence_long_double_field = TypeObjectUtils::build_common_struct_member(member_id_bounded_sequence_long_double_field, member_flags_bounded_sequence_long_double_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_bounded_sequence_long_double_field = TypeObjectUtils::build_common_struct_member(member_id_bounded_sequence_long_double_field, member_flags_bounded_sequence_long_double_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure bounded_sequence_long_double_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_bounded_sequence_long_double_field = "bounded_sequence_long_double_field"; + eprosima::fastcdr::optional member_ann_builtin_bounded_sequence_long_double_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_bounded_sequence_long_double_field = TypeObjectUtils::build_complete_member_detail(name_bounded_sequence_long_double_field, member_ann_builtin_bounded_sequence_long_double_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_bounded_sequence_long_double_field = TypeObjectUtils::build_complete_struct_member(common_bounded_sequence_long_double_field, detail_bounded_sequence_long_double_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_bounded_sequence_long_double_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_bool_5", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_bool", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + TypeIdentifier* element_identifier_anonymous_sequence_bool_5 {nullptr}; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_bool_5 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_bool_5 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_sequence_bool_5 = EK_COMPLETE; + if (TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d()) + { + equiv_kind_anonymous_sequence_bool_5 = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_sequence_bool_5 = 0; + PlainCollectionHeader header_anonymous_sequence_bool_5 = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_sequence_bool_5, element_flags_anonymous_sequence_bool_5); + std::string type_id_kind_anonymous_sequence_bool_5("TI_PLAIN_SEQUENCE_SMALL"); + if (type_id_kind_anonymous_sequence_bool_5 == "TI_PLAIN_SEQUENCE_SMALL") + { + SBound bound = static_cast(5); + PlainSequenceSElemDefn seq_sdefn = TypeObjectUtils::build_plain_sequence_s_elem_defn(header_anonymous_sequence_bool_5, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_bool_5)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_sequence_type_identifier(seq_sdefn, "anonymous_sequence_bool_5")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_bool_5 already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBound bound = 5; + PlainSequenceLElemDefn seq_ldefn = TypeObjectUtils::build_plain_sequence_l_elem_defn(header_anonymous_sequence_bool_5, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_bool_5)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_sequence_type_identifier(seq_ldefn, "anonymous_sequence_bool_5")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_bool_5 already registered in TypeObjectRegistry for a different type."); + } + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_bool_5", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_bool_5: Given Sequence TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_bounded_sequence_bool_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_bounded_sequence_bool_field; + MemberId member_id_bounded_sequence_bool_field = 0x0000002b; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_bounded_sequence_bool_field = TypeObjectUtils::build_common_struct_member(member_id_bounded_sequence_bool_field, member_flags_bounded_sequence_bool_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_bounded_sequence_bool_field = TypeObjectUtils::build_common_struct_member(member_id_bounded_sequence_bool_field, member_flags_bounded_sequence_bool_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure bounded_sequence_bool_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_bounded_sequence_bool_field = "bounded_sequence_bool_field"; + eprosima::fastcdr::optional member_ann_builtin_bounded_sequence_bool_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_bounded_sequence_bool_field = TypeObjectUtils::build_complete_member_detail(name_bounded_sequence_bool_field, member_ann_builtin_bounded_sequence_bool_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_bounded_sequence_bool_field = TypeObjectUtils::build_complete_struct_member(common_bounded_sequence_bool_field, detail_bounded_sequence_bool_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_bounded_sequence_bool_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_anonymous_string_unbounded_5", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_string_unbounded", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + std::string type_id_kind_anonymous_string_unbounded("TI_STRING8_SMALL"); + if (type_id_kind_anonymous_string_unbounded == "TI_STRING8_SMALL") + { + SBound bound = 0; + StringSTypeDefn string_sdefn = TypeObjectUtils::build_string_s_type_defn(bound); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_string_type_identifier(string_sdefn, + "anonymous_string_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else if (type_id_kind_anonymous_string_unbounded == "TI_STRING8_LARGE") + { + LBound bound = 255; + StringLTypeDefn string_ldefn = TypeObjectUtils::build_string_l_type_defn(bound); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_string_type_identifier(string_ldefn, + "anonymous_string_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded: Unknown String kind."); + return; + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_string_unbounded", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded: Given String TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + TypeIdentifier* element_identifier_anonymous_sequence_anonymous_string_unbounded_5 {nullptr}; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_anonymous_string_unbounded_5 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_anonymous_string_unbounded_5 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_sequence_anonymous_string_unbounded_5 = EK_COMPLETE; + if (TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d()) + { + equiv_kind_anonymous_sequence_anonymous_string_unbounded_5 = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_sequence_anonymous_string_unbounded_5 = 0; + PlainCollectionHeader header_anonymous_sequence_anonymous_string_unbounded_5 = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_sequence_anonymous_string_unbounded_5, element_flags_anonymous_sequence_anonymous_string_unbounded_5); + std::string type_id_kind_anonymous_sequence_anonymous_string_unbounded_5("TI_PLAIN_SEQUENCE_SMALL"); + if (type_id_kind_anonymous_sequence_anonymous_string_unbounded_5 == "TI_PLAIN_SEQUENCE_SMALL") + { + SBound bound = static_cast(5); + PlainSequenceSElemDefn seq_sdefn = TypeObjectUtils::build_plain_sequence_s_elem_defn(header_anonymous_sequence_anonymous_string_unbounded_5, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_anonymous_string_unbounded_5)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_sequence_type_identifier(seq_sdefn, "anonymous_sequence_anonymous_string_unbounded_5")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_anonymous_string_unbounded_5 already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBound bound = 5; + PlainSequenceLElemDefn seq_ldefn = TypeObjectUtils::build_plain_sequence_l_elem_defn(header_anonymous_sequence_anonymous_string_unbounded_5, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_anonymous_string_unbounded_5)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_sequence_type_identifier(seq_ldefn, "anonymous_sequence_anonymous_string_unbounded_5")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_anonymous_string_unbounded_5 already registered in TypeObjectRegistry for a different type."); + } + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_anonymous_string_unbounded_5", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_anonymous_string_unbounded_5: Given Sequence TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_bounded_sequence_string_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_bounded_sequence_string_field; + MemberId member_id_bounded_sequence_string_field = 0x0000002c; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_bounded_sequence_string_field = TypeObjectUtils::build_common_struct_member(member_id_bounded_sequence_string_field, member_flags_bounded_sequence_string_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_bounded_sequence_string_field = TypeObjectUtils::build_common_struct_member(member_id_bounded_sequence_string_field, member_flags_bounded_sequence_string_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure bounded_sequence_string_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_bounded_sequence_string_field = "bounded_sequence_string_field"; + eprosima::fastcdr::optional member_ann_builtin_bounded_sequence_string_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_bounded_sequence_string_field = TypeObjectUtils::build_complete_member_detail(name_bounded_sequence_string_field, member_ann_builtin_bounded_sequence_string_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_bounded_sequence_string_field = TypeObjectUtils::build_complete_struct_member(common_bounded_sequence_string_field, detail_bounded_sequence_string_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_bounded_sequence_string_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_Color_5", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "Color", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EnumTypeFlag enum_flags_Color = 0; + BitBound bit_bound_Color = 32; + CommonEnumeratedHeader common_Color = TypeObjectUtils::build_common_enumerated_header(bit_bound_Color); + QualifiedTypeName type_name_Color = "Color"; + eprosima::fastcdr::optional type_ann_builtin_Color; + eprosima::fastcdr::optional ann_custom_Color; + CompleteTypeDetail detail_Color = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_Color, ann_custom_Color, type_name_Color.to_string()); + CompleteEnumeratedHeader header_Color = TypeObjectUtils::build_complete_enumerated_header(common_Color, detail_Color); + CompleteEnumeratedLiteralSeq literal_seq_Color; + { + EnumeratedLiteralFlag flags_RED = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_RED = TypeObjectUtils::build_common_enumerated_literal(0, flags_RED); + eprosima::fastcdr::optional member_ann_builtin_RED; + ann_custom_Color.reset(); + MemberName name_RED = "RED"; + CompleteMemberDetail detail_RED = TypeObjectUtils::build_complete_member_detail(name_RED, member_ann_builtin_RED, ann_custom_Color); + CompleteEnumeratedLiteral literal_RED = TypeObjectUtils::build_complete_enumerated_literal(common_RED, detail_RED); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Color, literal_RED); + } + { + EnumeratedLiteralFlag flags_GREEN = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_GREEN = TypeObjectUtils::build_common_enumerated_literal(1, flags_GREEN); + eprosima::fastcdr::optional member_ann_builtin_GREEN; + ann_custom_Color.reset(); + MemberName name_GREEN = "GREEN"; + CompleteMemberDetail detail_GREEN = TypeObjectUtils::build_complete_member_detail(name_GREEN, member_ann_builtin_GREEN, ann_custom_Color); + CompleteEnumeratedLiteral literal_GREEN = TypeObjectUtils::build_complete_enumerated_literal(common_GREEN, detail_GREEN); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Color, literal_GREEN); + } + { + EnumeratedLiteralFlag flags_BLUE = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_BLUE = TypeObjectUtils::build_common_enumerated_literal(2, flags_BLUE); + eprosima::fastcdr::optional member_ann_builtin_BLUE; + ann_custom_Color.reset(); + MemberName name_BLUE = "BLUE"; + CompleteMemberDetail detail_BLUE = TypeObjectUtils::build_complete_member_detail(name_BLUE, member_ann_builtin_BLUE, ann_custom_Color); + CompleteEnumeratedLiteral literal_BLUE = TypeObjectUtils::build_complete_enumerated_literal(common_BLUE, detail_BLUE); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Color, literal_BLUE); + } + { + EnumeratedLiteralFlag flags_YELLOW = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_YELLOW = TypeObjectUtils::build_common_enumerated_literal(3, flags_YELLOW); + eprosima::fastcdr::optional member_ann_builtin_YELLOW; + ann_custom_Color.reset(); + MemberName name_YELLOW = "YELLOW"; + CompleteMemberDetail detail_YELLOW = TypeObjectUtils::build_complete_member_detail(name_YELLOW, member_ann_builtin_YELLOW, ann_custom_Color); + CompleteEnumeratedLiteral literal_YELLOW = TypeObjectUtils::build_complete_enumerated_literal(common_YELLOW, detail_YELLOW); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Color, literal_YELLOW); + } + { + EnumeratedLiteralFlag flags_MAGENTA = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_MAGENTA = TypeObjectUtils::build_common_enumerated_literal(4, flags_MAGENTA); + eprosima::fastcdr::optional member_ann_builtin_MAGENTA; + ann_custom_Color.reset(); + MemberName name_MAGENTA = "MAGENTA"; + CompleteMemberDetail detail_MAGENTA = TypeObjectUtils::build_complete_member_detail(name_MAGENTA, member_ann_builtin_MAGENTA, ann_custom_Color); + CompleteEnumeratedLiteral literal_MAGENTA = TypeObjectUtils::build_complete_enumerated_literal(common_MAGENTA, detail_MAGENTA); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Color, literal_MAGENTA); + } + CompleteEnumeratedType enumerated_type_Color = TypeObjectUtils::build_complete_enumerated_type(enum_flags_Color, header_Color, + literal_seq_Color); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_enumerated_type_object(enumerated_type_Color, type_name_Color.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Color already registered in TypeObjectRegistry for a different type."); + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "Color", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Color: Given Enum TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + TypeIdentifier* element_identifier_anonymous_sequence_Color_5 {nullptr}; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_Color_5 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_Color_5 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_sequence_Color_5 = EK_COMPLETE; + if (TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d()) + { + equiv_kind_anonymous_sequence_Color_5 = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_sequence_Color_5 = 0; + PlainCollectionHeader header_anonymous_sequence_Color_5 = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_sequence_Color_5, element_flags_anonymous_sequence_Color_5); + std::string type_id_kind_anonymous_sequence_Color_5("TI_PLAIN_SEQUENCE_SMALL"); + if (type_id_kind_anonymous_sequence_Color_5 == "TI_PLAIN_SEQUENCE_SMALL") + { + SBound bound = static_cast(5); + PlainSequenceSElemDefn seq_sdefn = TypeObjectUtils::build_plain_sequence_s_elem_defn(header_anonymous_sequence_Color_5, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_Color_5)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_sequence_type_identifier(seq_sdefn, "anonymous_sequence_Color_5")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_Color_5 already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBound bound = 5; + PlainSequenceLElemDefn seq_ldefn = TypeObjectUtils::build_plain_sequence_l_elem_defn(header_anonymous_sequence_Color_5, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_Color_5)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_sequence_type_identifier(seq_ldefn, "anonymous_sequence_Color_5")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_Color_5 already registered in TypeObjectRegistry for a different type."); + } + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_Color_5", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_Color_5: Given Sequence TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_bounded_sequence_enum_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_bounded_sequence_enum_field; + MemberId member_id_bounded_sequence_enum_field = 0x0000002d; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_bounded_sequence_enum_field = TypeObjectUtils::build_common_struct_member(member_id_bounded_sequence_enum_field, member_flags_bounded_sequence_enum_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_bounded_sequence_enum_field = TypeObjectUtils::build_common_struct_member(member_id_bounded_sequence_enum_field, member_flags_bounded_sequence_enum_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure bounded_sequence_enum_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_bounded_sequence_enum_field = "bounded_sequence_enum_field"; + eprosima::fastcdr::optional member_ann_builtin_bounded_sequence_enum_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_bounded_sequence_enum_field = TypeObjectUtils::build_complete_member_detail(name_bounded_sequence_enum_field, member_ann_builtin_bounded_sequence_enum_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_bounded_sequence_enum_field = TypeObjectUtils::build_complete_struct_member(common_bounded_sequence_enum_field, detail_bounded_sequence_enum_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_bounded_sequence_enum_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_Material_5", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "Material", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EnumTypeFlag enum_flags_Material = 0; + BitBound bit_bound_Material = 32; + CommonEnumeratedHeader common_Material = TypeObjectUtils::build_common_enumerated_header(bit_bound_Material); + QualifiedTypeName type_name_Material = "Material"; + eprosima::fastcdr::optional type_ann_builtin_Material; + eprosima::fastcdr::optional ann_custom_Material; + CompleteTypeDetail detail_Material = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_Material, ann_custom_Material, type_name_Material.to_string()); + CompleteEnumeratedHeader header_Material = TypeObjectUtils::build_complete_enumerated_header(common_Material, detail_Material); + CompleteEnumeratedLiteralSeq literal_seq_Material; + { + EnumeratedLiteralFlag flags_WOOD = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_WOOD = TypeObjectUtils::build_common_enumerated_literal(0, flags_WOOD); + eprosima::fastcdr::optional member_ann_builtin_WOOD; + ann_custom_Material.reset(); + MemberName name_WOOD = "WOOD"; + CompleteMemberDetail detail_WOOD = TypeObjectUtils::build_complete_member_detail(name_WOOD, member_ann_builtin_WOOD, ann_custom_Material); + CompleteEnumeratedLiteral literal_WOOD = TypeObjectUtils::build_complete_enumerated_literal(common_WOOD, detail_WOOD); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Material, literal_WOOD); + } + { + EnumeratedLiteralFlag flags_PLASTIC = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_PLASTIC = TypeObjectUtils::build_common_enumerated_literal(1, flags_PLASTIC); + eprosima::fastcdr::optional member_ann_builtin_PLASTIC; + ann_custom_Material.reset(); + MemberName name_PLASTIC = "PLASTIC"; + CompleteMemberDetail detail_PLASTIC = TypeObjectUtils::build_complete_member_detail(name_PLASTIC, member_ann_builtin_PLASTIC, ann_custom_Material); + CompleteEnumeratedLiteral literal_PLASTIC = TypeObjectUtils::build_complete_enumerated_literal(common_PLASTIC, detail_PLASTIC); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Material, literal_PLASTIC); + } + { + EnumeratedLiteralFlag flags_METAL = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_METAL = TypeObjectUtils::build_common_enumerated_literal(2, flags_METAL); + eprosima::fastcdr::optional member_ann_builtin_METAL; + ann_custom_Material.reset(); + MemberName name_METAL = "METAL"; + CompleteMemberDetail detail_METAL = TypeObjectUtils::build_complete_member_detail(name_METAL, member_ann_builtin_METAL, ann_custom_Material); + CompleteEnumeratedLiteral literal_METAL = TypeObjectUtils::build_complete_enumerated_literal(common_METAL, detail_METAL); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Material, literal_METAL); + } + { + EnumeratedLiteralFlag flags_CONCRETE = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_CONCRETE = TypeObjectUtils::build_common_enumerated_literal(3, flags_CONCRETE); + eprosima::fastcdr::optional member_ann_builtin_CONCRETE; + ann_custom_Material.reset(); + MemberName name_CONCRETE = "CONCRETE"; + CompleteMemberDetail detail_CONCRETE = TypeObjectUtils::build_complete_member_detail(name_CONCRETE, member_ann_builtin_CONCRETE, ann_custom_Material); + CompleteEnumeratedLiteral literal_CONCRETE = TypeObjectUtils::build_complete_enumerated_literal(common_CONCRETE, detail_CONCRETE); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Material, literal_CONCRETE); + } + { + EnumeratedLiteralFlag flags_STONE = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_STONE = TypeObjectUtils::build_common_enumerated_literal(4, flags_STONE); + eprosima::fastcdr::optional member_ann_builtin_STONE; + ann_custom_Material.reset(); + MemberName name_STONE = "STONE"; + CompleteMemberDetail detail_STONE = TypeObjectUtils::build_complete_member_detail(name_STONE, member_ann_builtin_STONE, ann_custom_Material); + CompleteEnumeratedLiteral literal_STONE = TypeObjectUtils::build_complete_enumerated_literal(common_STONE, detail_STONE); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Material, literal_STONE); + } + CompleteEnumeratedType enumerated_type_Material = TypeObjectUtils::build_complete_enumerated_type(enum_flags_Material, header_Material, + literal_seq_Material); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_enumerated_type_object(enumerated_type_Material, type_name_Material.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Material already registered in TypeObjectRegistry for a different type."); + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "Material", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Material: Given Enum TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + TypeIdentifier* element_identifier_anonymous_sequence_Material_5 {nullptr}; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_Material_5 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_Material_5 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_sequence_Material_5 = EK_COMPLETE; + if (TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d()) + { + equiv_kind_anonymous_sequence_Material_5 = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_sequence_Material_5 = 0; + PlainCollectionHeader header_anonymous_sequence_Material_5 = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_sequence_Material_5, element_flags_anonymous_sequence_Material_5); + std::string type_id_kind_anonymous_sequence_Material_5("TI_PLAIN_SEQUENCE_SMALL"); + if (type_id_kind_anonymous_sequence_Material_5 == "TI_PLAIN_SEQUENCE_SMALL") + { + SBound bound = static_cast(5); + PlainSequenceSElemDefn seq_sdefn = TypeObjectUtils::build_plain_sequence_s_elem_defn(header_anonymous_sequence_Material_5, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_Material_5)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_sequence_type_identifier(seq_sdefn, "anonymous_sequence_Material_5")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_Material_5 already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBound bound = 5; + PlainSequenceLElemDefn seq_ldefn = TypeObjectUtils::build_plain_sequence_l_elem_defn(header_anonymous_sequence_Material_5, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_Material_5)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_sequence_type_identifier(seq_ldefn, "anonymous_sequence_Material_5")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_Material_5 already registered in TypeObjectRegistry for a different type."); + } + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_Material_5", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_Material_5: Given Sequence TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_bounded_sequence_enum2_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_bounded_sequence_enum2_field; + MemberId member_id_bounded_sequence_enum2_field = 0x0000002e; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_bounded_sequence_enum2_field = TypeObjectUtils::build_common_struct_member(member_id_bounded_sequence_enum2_field, member_flags_bounded_sequence_enum2_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_bounded_sequence_enum2_field = TypeObjectUtils::build_common_struct_member(member_id_bounded_sequence_enum2_field, member_flags_bounded_sequence_enum2_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure bounded_sequence_enum2_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_bounded_sequence_enum2_field = "bounded_sequence_enum2_field"; + eprosima::fastcdr::optional member_ann_builtin_bounded_sequence_enum2_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_bounded_sequence_enum2_field = TypeObjectUtils::build_complete_member_detail(name_bounded_sequence_enum2_field, member_ann_builtin_bounded_sequence_enum2_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_bounded_sequence_enum2_field = TypeObjectUtils::build_complete_struct_member(common_bounded_sequence_enum2_field, detail_bounded_sequence_enum2_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_bounded_sequence_enum2_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_StructType_5", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "StructType", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + { + StructTypeFlag struct_flags_StructType = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::NOT_APPLIED, + true, false); + ReturnCode_t return_code_StructType; + TypeIdentifierPair type_ids_StructType; + QualifiedTypeName type_name_StructType = "StructType"; + eprosima::fastcdr::optional type_ann_builtin_StructType; + eprosima::fastcdr::optional ann_custom_StructType; + AppliedAnnotationSeq tmp_ann_custom_StructType; + eprosima::fastcdr::optional verbatim_StructType; + if (!tmp_ann_custom_StructType.empty()) + { + ann_custom_StructType = tmp_ann_custom_StructType; + } + + CompleteTypeDetail detail_StructType = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_StructType, ann_custom_StructType, type_name_StructType.to_string()); + CompleteStructHeader header_StructType; + header_StructType = TypeObjectUtils::build_complete_struct_header(TypeIdentifier(), detail_StructType); + CompleteStructMemberSeq member_seq_StructType; + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_char", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "char_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_char_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_char_field; + MemberId member_id_char_field = 0x00000000; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_char_field = TypeObjectUtils::build_common_struct_member(member_id_char_field, member_flags_char_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_char_field = TypeObjectUtils::build_common_struct_member(member_id_char_field, member_flags_char_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure char_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_char_field = "char_field"; + eprosima::fastcdr::optional member_ann_builtin_char_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_char_field = TypeObjectUtils::build_complete_member_detail(name_char_field, member_ann_builtin_char_field, ann_custom_StructType); + CompleteStructMember member_char_field = TypeObjectUtils::build_complete_struct_member(common_char_field, detail_char_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_char_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_byte", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "uint8_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_uint8_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_uint8_field; + MemberId member_id_uint8_field = 0x00000001; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_uint8_field = TypeObjectUtils::build_common_struct_member(member_id_uint8_field, member_flags_uint8_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_uint8_field = TypeObjectUtils::build_common_struct_member(member_id_uint8_field, member_flags_uint8_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure uint8_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_uint8_field = "uint8_field"; + eprosima::fastcdr::optional member_ann_builtin_uint8_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_uint8_field = TypeObjectUtils::build_complete_member_detail(name_uint8_field, member_ann_builtin_uint8_field, ann_custom_StructType); + CompleteStructMember member_uint8_field = TypeObjectUtils::build_complete_struct_member(common_uint8_field, detail_uint8_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_uint8_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_int16_t", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "int16_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_int16_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_int16_field; + MemberId member_id_int16_field = 0x00000002; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_int16_field = TypeObjectUtils::build_common_struct_member(member_id_int16_field, member_flags_int16_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_int16_field = TypeObjectUtils::build_common_struct_member(member_id_int16_field, member_flags_int16_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure int16_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_int16_field = "int16_field"; + eprosima::fastcdr::optional member_ann_builtin_int16_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_int16_field = TypeObjectUtils::build_complete_member_detail(name_int16_field, member_ann_builtin_int16_field, ann_custom_StructType); + CompleteStructMember member_int16_field = TypeObjectUtils::build_complete_struct_member(common_int16_field, detail_int16_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_int16_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_uint16_t", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "uint16_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_uint16_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_uint16_field; + MemberId member_id_uint16_field = 0x00000003; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_uint16_field = TypeObjectUtils::build_common_struct_member(member_id_uint16_field, member_flags_uint16_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_uint16_field = TypeObjectUtils::build_common_struct_member(member_id_uint16_field, member_flags_uint16_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure uint16_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_uint16_field = "uint16_field"; + eprosima::fastcdr::optional member_ann_builtin_uint16_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_uint16_field = TypeObjectUtils::build_complete_member_detail(name_uint16_field, member_ann_builtin_uint16_field, ann_custom_StructType); + CompleteStructMember member_uint16_field = TypeObjectUtils::build_complete_struct_member(common_uint16_field, detail_uint16_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_uint16_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_int32_t", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "int32_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_int32_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_int32_field; + MemberId member_id_int32_field = 0x00000004; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_int32_field = TypeObjectUtils::build_common_struct_member(member_id_int32_field, member_flags_int32_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_int32_field = TypeObjectUtils::build_common_struct_member(member_id_int32_field, member_flags_int32_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure int32_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_int32_field = "int32_field"; + eprosima::fastcdr::optional member_ann_builtin_int32_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_int32_field = TypeObjectUtils::build_complete_member_detail(name_int32_field, member_ann_builtin_int32_field, ann_custom_StructType); + CompleteStructMember member_int32_field = TypeObjectUtils::build_complete_struct_member(common_int32_field, detail_int32_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_int32_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_uint32_t", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "uint32_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_uint32_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_uint32_field; + MemberId member_id_uint32_field = 0x00000005; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_uint32_field = TypeObjectUtils::build_common_struct_member(member_id_uint32_field, member_flags_uint32_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_uint32_field = TypeObjectUtils::build_common_struct_member(member_id_uint32_field, member_flags_uint32_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure uint32_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_uint32_field = "uint32_field"; + eprosima::fastcdr::optional member_ann_builtin_uint32_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_uint32_field = TypeObjectUtils::build_complete_member_detail(name_uint32_field, member_ann_builtin_uint32_field, ann_custom_StructType); + CompleteStructMember member_uint32_field = TypeObjectUtils::build_complete_struct_member(common_uint32_field, detail_uint32_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_uint32_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_int64_t", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "int64_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_int64_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_int64_field; + MemberId member_id_int64_field = 0x00000006; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_int64_field = TypeObjectUtils::build_common_struct_member(member_id_int64_field, member_flags_int64_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_int64_field = TypeObjectUtils::build_common_struct_member(member_id_int64_field, member_flags_int64_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure int64_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_int64_field = "int64_field"; + eprosima::fastcdr::optional member_ann_builtin_int64_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_int64_field = TypeObjectUtils::build_complete_member_detail(name_int64_field, member_ann_builtin_int64_field, ann_custom_StructType); + CompleteStructMember member_int64_field = TypeObjectUtils::build_complete_struct_member(common_int64_field, detail_int64_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_int64_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_uint64_t", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "uint64_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_uint64_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_uint64_field; + MemberId member_id_uint64_field = 0x00000007; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_uint64_field = TypeObjectUtils::build_common_struct_member(member_id_uint64_field, member_flags_uint64_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_uint64_field = TypeObjectUtils::build_common_struct_member(member_id_uint64_field, member_flags_uint64_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure uint64_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_uint64_field = "uint64_field"; + eprosima::fastcdr::optional member_ann_builtin_uint64_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_uint64_field = TypeObjectUtils::build_complete_member_detail(name_uint64_field, member_ann_builtin_uint64_field, ann_custom_StructType); + CompleteStructMember member_uint64_field = TypeObjectUtils::build_complete_struct_member(common_uint64_field, detail_uint64_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_uint64_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_float", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "float_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_float_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_float_field; + MemberId member_id_float_field = 0x00000008; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_float_field = TypeObjectUtils::build_common_struct_member(member_id_float_field, member_flags_float_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_float_field = TypeObjectUtils::build_common_struct_member(member_id_float_field, member_flags_float_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure float_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_float_field = "float_field"; + eprosima::fastcdr::optional member_ann_builtin_float_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_float_field = TypeObjectUtils::build_complete_member_detail(name_float_field, member_ann_builtin_float_field, ann_custom_StructType); + CompleteStructMember member_float_field = TypeObjectUtils::build_complete_struct_member(common_float_field, detail_float_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_float_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_double", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "double_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_double_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_double_field; + MemberId member_id_double_field = 0x00000009; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_double_field = TypeObjectUtils::build_common_struct_member(member_id_double_field, member_flags_double_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_double_field = TypeObjectUtils::build_common_struct_member(member_id_double_field, member_flags_double_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure double_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_double_field = "double_field"; + eprosima::fastcdr::optional member_ann_builtin_double_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_double_field = TypeObjectUtils::build_complete_member_detail(name_double_field, member_ann_builtin_double_field, ann_custom_StructType); + CompleteStructMember member_double_field = TypeObjectUtils::build_complete_struct_member(common_double_field, detail_double_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_double_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_longdouble", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "long_double_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_long_double_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_long_double_field; + MemberId member_id_long_double_field = 0x0000000a; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_long_double_field = TypeObjectUtils::build_common_struct_member(member_id_long_double_field, member_flags_long_double_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_long_double_field = TypeObjectUtils::build_common_struct_member(member_id_long_double_field, member_flags_long_double_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure long_double_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_long_double_field = "long_double_field"; + eprosima::fastcdr::optional member_ann_builtin_long_double_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_long_double_field = TypeObjectUtils::build_complete_member_detail(name_long_double_field, member_ann_builtin_long_double_field, ann_custom_StructType); + CompleteStructMember member_long_double_field = TypeObjectUtils::build_complete_struct_member(common_long_double_field, detail_long_double_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_long_double_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_bool", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "bool_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_bool_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_bool_field; + MemberId member_id_bool_field = 0x0000000b; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_bool_field = TypeObjectUtils::build_common_struct_member(member_id_bool_field, member_flags_bool_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_bool_field = TypeObjectUtils::build_common_struct_member(member_id_bool_field, member_flags_bool_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure bool_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_bool_field = "bool_field"; + eprosima::fastcdr::optional member_ann_builtin_bool_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_bool_field = TypeObjectUtils::build_complete_member_detail(name_bool_field, member_ann_builtin_bool_field, ann_custom_StructType); + CompleteStructMember member_bool_field = TypeObjectUtils::build_complete_struct_member(common_bool_field, detail_bool_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_bool_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_string_unbounded", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + std::string type_id_kind_anonymous_string_unbounded("TI_STRING8_SMALL"); + if (type_id_kind_anonymous_string_unbounded == "TI_STRING8_SMALL") + { + SBound bound = 0; + StringSTypeDefn string_sdefn = TypeObjectUtils::build_string_s_type_defn(bound); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_string_type_identifier(string_sdefn, + "anonymous_string_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else if (type_id_kind_anonymous_string_unbounded == "TI_STRING8_LARGE") + { + LBound bound = 255; + StringLTypeDefn string_ldefn = TypeObjectUtils::build_string_l_type_defn(bound); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_string_type_identifier(string_ldefn, + "anonymous_string_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded: Unknown String kind."); + return; + } + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_string_unbounded", type_ids_StructType); + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded: Given String TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_string_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_string_field; + MemberId member_id_string_field = 0x0000000c; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_string_field = TypeObjectUtils::build_common_struct_member(member_id_string_field, member_flags_string_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_string_field = TypeObjectUtils::build_common_struct_member(member_id_string_field, member_flags_string_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure string_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_string_field = "string_field"; + eprosima::fastcdr::optional member_ann_builtin_string_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_string_field = TypeObjectUtils::build_complete_member_detail(name_string_field, member_ann_builtin_string_field, ann_custom_StructType); + CompleteStructMember member_string_field = TypeObjectUtils::build_complete_struct_member(common_string_field, detail_string_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_string_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "Color", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EnumTypeFlag enum_flags_Color = 0; + BitBound bit_bound_Color = 32; + CommonEnumeratedHeader common_Color = TypeObjectUtils::build_common_enumerated_header(bit_bound_Color); + QualifiedTypeName type_name_Color = "Color"; + eprosima::fastcdr::optional type_ann_builtin_Color; + eprosima::fastcdr::optional ann_custom_Color; + CompleteTypeDetail detail_Color = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_Color, ann_custom_Color, type_name_Color.to_string()); + CompleteEnumeratedHeader header_Color = TypeObjectUtils::build_complete_enumerated_header(common_Color, detail_Color); + CompleteEnumeratedLiteralSeq literal_seq_Color; + { + EnumeratedLiteralFlag flags_RED = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_RED = TypeObjectUtils::build_common_enumerated_literal(0, flags_RED); + eprosima::fastcdr::optional member_ann_builtin_RED; + ann_custom_Color.reset(); + MemberName name_RED = "RED"; + CompleteMemberDetail detail_RED = TypeObjectUtils::build_complete_member_detail(name_RED, member_ann_builtin_RED, ann_custom_Color); + CompleteEnumeratedLiteral literal_RED = TypeObjectUtils::build_complete_enumerated_literal(common_RED, detail_RED); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Color, literal_RED); + } + { + EnumeratedLiteralFlag flags_GREEN = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_GREEN = TypeObjectUtils::build_common_enumerated_literal(1, flags_GREEN); + eprosima::fastcdr::optional member_ann_builtin_GREEN; + ann_custom_Color.reset(); + MemberName name_GREEN = "GREEN"; + CompleteMemberDetail detail_GREEN = TypeObjectUtils::build_complete_member_detail(name_GREEN, member_ann_builtin_GREEN, ann_custom_Color); + CompleteEnumeratedLiteral literal_GREEN = TypeObjectUtils::build_complete_enumerated_literal(common_GREEN, detail_GREEN); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Color, literal_GREEN); + } + { + EnumeratedLiteralFlag flags_BLUE = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_BLUE = TypeObjectUtils::build_common_enumerated_literal(2, flags_BLUE); + eprosima::fastcdr::optional member_ann_builtin_BLUE; + ann_custom_Color.reset(); + MemberName name_BLUE = "BLUE"; + CompleteMemberDetail detail_BLUE = TypeObjectUtils::build_complete_member_detail(name_BLUE, member_ann_builtin_BLUE, ann_custom_Color); + CompleteEnumeratedLiteral literal_BLUE = TypeObjectUtils::build_complete_enumerated_literal(common_BLUE, detail_BLUE); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Color, literal_BLUE); + } + { + EnumeratedLiteralFlag flags_YELLOW = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_YELLOW = TypeObjectUtils::build_common_enumerated_literal(3, flags_YELLOW); + eprosima::fastcdr::optional member_ann_builtin_YELLOW; + ann_custom_Color.reset(); + MemberName name_YELLOW = "YELLOW"; + CompleteMemberDetail detail_YELLOW = TypeObjectUtils::build_complete_member_detail(name_YELLOW, member_ann_builtin_YELLOW, ann_custom_Color); + CompleteEnumeratedLiteral literal_YELLOW = TypeObjectUtils::build_complete_enumerated_literal(common_YELLOW, detail_YELLOW); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Color, literal_YELLOW); + } + { + EnumeratedLiteralFlag flags_MAGENTA = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_MAGENTA = TypeObjectUtils::build_common_enumerated_literal(4, flags_MAGENTA); + eprosima::fastcdr::optional member_ann_builtin_MAGENTA; + ann_custom_Color.reset(); + MemberName name_MAGENTA = "MAGENTA"; + CompleteMemberDetail detail_MAGENTA = TypeObjectUtils::build_complete_member_detail(name_MAGENTA, member_ann_builtin_MAGENTA, ann_custom_Color); + CompleteEnumeratedLiteral literal_MAGENTA = TypeObjectUtils::build_complete_enumerated_literal(common_MAGENTA, detail_MAGENTA); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Color, literal_MAGENTA); + } + CompleteEnumeratedType enumerated_type_Color = TypeObjectUtils::build_complete_enumerated_type(enum_flags_Color, header_Color, + literal_seq_Color); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_enumerated_type_object(enumerated_type_Color, type_name_Color.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Color already registered in TypeObjectRegistry for a different type."); + } + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "Color", type_ids_StructType); + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Color: Given Enum TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_enum_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_enum_field; + MemberId member_id_enum_field = 0x0000000d; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_enum_field = TypeObjectUtils::build_common_struct_member(member_id_enum_field, member_flags_enum_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_enum_field = TypeObjectUtils::build_common_struct_member(member_id_enum_field, member_flags_enum_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure enum_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_enum_field = "enum_field"; + eprosima::fastcdr::optional member_ann_builtin_enum_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_enum_field = TypeObjectUtils::build_complete_member_detail(name_enum_field, member_ann_builtin_enum_field, ann_custom_StructType); + CompleteStructMember member_enum_field = TypeObjectUtils::build_complete_struct_member(common_enum_field, detail_enum_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_enum_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "Material", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EnumTypeFlag enum_flags_Material = 0; + BitBound bit_bound_Material = 32; + CommonEnumeratedHeader common_Material = TypeObjectUtils::build_common_enumerated_header(bit_bound_Material); + QualifiedTypeName type_name_Material = "Material"; + eprosima::fastcdr::optional type_ann_builtin_Material; + eprosima::fastcdr::optional ann_custom_Material; + CompleteTypeDetail detail_Material = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_Material, ann_custom_Material, type_name_Material.to_string()); + CompleteEnumeratedHeader header_Material = TypeObjectUtils::build_complete_enumerated_header(common_Material, detail_Material); + CompleteEnumeratedLiteralSeq literal_seq_Material; + { + EnumeratedLiteralFlag flags_WOOD = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_WOOD = TypeObjectUtils::build_common_enumerated_literal(0, flags_WOOD); + eprosima::fastcdr::optional member_ann_builtin_WOOD; + ann_custom_Material.reset(); + MemberName name_WOOD = "WOOD"; + CompleteMemberDetail detail_WOOD = TypeObjectUtils::build_complete_member_detail(name_WOOD, member_ann_builtin_WOOD, ann_custom_Material); + CompleteEnumeratedLiteral literal_WOOD = TypeObjectUtils::build_complete_enumerated_literal(common_WOOD, detail_WOOD); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Material, literal_WOOD); + } + { + EnumeratedLiteralFlag flags_PLASTIC = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_PLASTIC = TypeObjectUtils::build_common_enumerated_literal(1, flags_PLASTIC); + eprosima::fastcdr::optional member_ann_builtin_PLASTIC; + ann_custom_Material.reset(); + MemberName name_PLASTIC = "PLASTIC"; + CompleteMemberDetail detail_PLASTIC = TypeObjectUtils::build_complete_member_detail(name_PLASTIC, member_ann_builtin_PLASTIC, ann_custom_Material); + CompleteEnumeratedLiteral literal_PLASTIC = TypeObjectUtils::build_complete_enumerated_literal(common_PLASTIC, detail_PLASTIC); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Material, literal_PLASTIC); + } + { + EnumeratedLiteralFlag flags_METAL = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_METAL = TypeObjectUtils::build_common_enumerated_literal(2, flags_METAL); + eprosima::fastcdr::optional member_ann_builtin_METAL; + ann_custom_Material.reset(); + MemberName name_METAL = "METAL"; + CompleteMemberDetail detail_METAL = TypeObjectUtils::build_complete_member_detail(name_METAL, member_ann_builtin_METAL, ann_custom_Material); + CompleteEnumeratedLiteral literal_METAL = TypeObjectUtils::build_complete_enumerated_literal(common_METAL, detail_METAL); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Material, literal_METAL); + } + { + EnumeratedLiteralFlag flags_CONCRETE = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_CONCRETE = TypeObjectUtils::build_common_enumerated_literal(3, flags_CONCRETE); + eprosima::fastcdr::optional member_ann_builtin_CONCRETE; + ann_custom_Material.reset(); + MemberName name_CONCRETE = "CONCRETE"; + CompleteMemberDetail detail_CONCRETE = TypeObjectUtils::build_complete_member_detail(name_CONCRETE, member_ann_builtin_CONCRETE, ann_custom_Material); + CompleteEnumeratedLiteral literal_CONCRETE = TypeObjectUtils::build_complete_enumerated_literal(common_CONCRETE, detail_CONCRETE); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Material, literal_CONCRETE); + } + { + EnumeratedLiteralFlag flags_STONE = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_STONE = TypeObjectUtils::build_common_enumerated_literal(4, flags_STONE); + eprosima::fastcdr::optional member_ann_builtin_STONE; + ann_custom_Material.reset(); + MemberName name_STONE = "STONE"; + CompleteMemberDetail detail_STONE = TypeObjectUtils::build_complete_member_detail(name_STONE, member_ann_builtin_STONE, ann_custom_Material); + CompleteEnumeratedLiteral literal_STONE = TypeObjectUtils::build_complete_enumerated_literal(common_STONE, detail_STONE); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Material, literal_STONE); + } + CompleteEnumeratedType enumerated_type_Material = TypeObjectUtils::build_complete_enumerated_type(enum_flags_Material, header_Material, + literal_seq_Material); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_enumerated_type_object(enumerated_type_Material, type_name_Material.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Material already registered in TypeObjectRegistry for a different type."); + } + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "Material", type_ids_StructType); + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Material: Given Enum TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_enum2_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_enum2_field; + MemberId member_id_enum2_field = 0x0000000e; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_enum2_field = TypeObjectUtils::build_common_struct_member(member_id_enum2_field, member_flags_enum2_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_enum2_field = TypeObjectUtils::build_common_struct_member(member_id_enum2_field, member_flags_enum2_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure enum2_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_enum2_field = "enum2_field"; + eprosima::fastcdr::optional member_ann_builtin_enum2_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_enum2_field = TypeObjectUtils::build_complete_member_detail(name_enum2_field, member_ann_builtin_enum2_field, ann_custom_StructType); + CompleteStructMember member_enum2_field = TypeObjectUtils::build_complete_struct_member(common_enum2_field, detail_enum2_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_enum2_field); + } + CompleteStructType struct_type_StructType = TypeObjectUtils::build_complete_struct_type(struct_flags_StructType, header_StructType, member_seq_StructType); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_struct_type_object(struct_type_StructType, type_name_StructType.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "StructType already registered in TypeObjectRegistry for a different type."); + } + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "StructType", type_ids_StructType); + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "StructType: Given Struct TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + } + TypeIdentifier* element_identifier_anonymous_sequence_StructType_5 {nullptr}; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_StructType_5 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_StructType_5 = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_sequence_StructType_5 = EK_COMPLETE; + if (TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d()) + { + equiv_kind_anonymous_sequence_StructType_5 = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_sequence_StructType_5 = 0; + PlainCollectionHeader header_anonymous_sequence_StructType_5 = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_sequence_StructType_5, element_flags_anonymous_sequence_StructType_5); + std::string type_id_kind_anonymous_sequence_StructType_5("TI_PLAIN_SEQUENCE_SMALL"); + if (type_id_kind_anonymous_sequence_StructType_5 == "TI_PLAIN_SEQUENCE_SMALL") + { + SBound bound = static_cast(5); + PlainSequenceSElemDefn seq_sdefn = TypeObjectUtils::build_plain_sequence_s_elem_defn(header_anonymous_sequence_StructType_5, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_StructType_5)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_sequence_type_identifier(seq_sdefn, "anonymous_sequence_StructType_5")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_StructType_5 already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBound bound = 5; + PlainSequenceLElemDefn seq_ldefn = TypeObjectUtils::build_plain_sequence_l_elem_defn(header_anonymous_sequence_StructType_5, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_StructType_5)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_sequence_type_identifier(seq_ldefn, "anonymous_sequence_StructType_5")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_StructType_5 already registered in TypeObjectRegistry for a different type."); + } + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_StructType_5", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_StructType_5: Given Sequence TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_bounded_sequence_struct_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_bounded_sequence_struct_field; + MemberId member_id_bounded_sequence_struct_field = 0x0000002f; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_bounded_sequence_struct_field = TypeObjectUtils::build_common_struct_member(member_id_bounded_sequence_struct_field, member_flags_bounded_sequence_struct_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_bounded_sequence_struct_field = TypeObjectUtils::build_common_struct_member(member_id_bounded_sequence_struct_field, member_flags_bounded_sequence_struct_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure bounded_sequence_struct_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_bounded_sequence_struct_field = "bounded_sequence_struct_field"; + eprosima::fastcdr::optional member_ann_builtin_bounded_sequence_struct_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_bounded_sequence_struct_field = TypeObjectUtils::build_complete_member_detail(name_bounded_sequence_struct_field, member_ann_builtin_bounded_sequence_struct_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_bounded_sequence_struct_field = TypeObjectUtils::build_complete_struct_member(common_bounded_sequence_struct_field, detail_bounded_sequence_struct_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_bounded_sequence_struct_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_char_unbounded", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_char", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + TypeIdentifier* element_identifier_anonymous_sequence_char_unbounded {nullptr}; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_char_unbounded = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_char_unbounded = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_sequence_char_unbounded = EK_COMPLETE; + if (TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d()) + { + equiv_kind_anonymous_sequence_char_unbounded = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_sequence_char_unbounded = 0; + PlainCollectionHeader header_anonymous_sequence_char_unbounded = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_sequence_char_unbounded, element_flags_anonymous_sequence_char_unbounded); + std::string type_id_kind_anonymous_sequence_char_unbounded("TI_PLAIN_SEQUENCE_SMALL"); + if (type_id_kind_anonymous_sequence_char_unbounded == "TI_PLAIN_SEQUENCE_SMALL") + { + SBound bound = 0; + PlainSequenceSElemDefn seq_sdefn = TypeObjectUtils::build_plain_sequence_s_elem_defn(header_anonymous_sequence_char_unbounded, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_char_unbounded)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_sequence_type_identifier(seq_sdefn, "anonymous_sequence_char_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_char_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBound bound = 0; + PlainSequenceLElemDefn seq_ldefn = TypeObjectUtils::build_plain_sequence_l_elem_defn(header_anonymous_sequence_char_unbounded, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_char_unbounded)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_sequence_type_identifier(seq_ldefn, "anonymous_sequence_char_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_char_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_char_unbounded", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_char_unbounded: Given Sequence TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_unbounded_sequence_char_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_unbounded_sequence_char_field; + MemberId member_id_unbounded_sequence_char_field = 0x00000030; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_unbounded_sequence_char_field = TypeObjectUtils::build_common_struct_member(member_id_unbounded_sequence_char_field, member_flags_unbounded_sequence_char_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_unbounded_sequence_char_field = TypeObjectUtils::build_common_struct_member(member_id_unbounded_sequence_char_field, member_flags_unbounded_sequence_char_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure unbounded_sequence_char_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_unbounded_sequence_char_field = "unbounded_sequence_char_field"; + eprosima::fastcdr::optional member_ann_builtin_unbounded_sequence_char_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_unbounded_sequence_char_field = TypeObjectUtils::build_complete_member_detail(name_unbounded_sequence_char_field, member_ann_builtin_unbounded_sequence_char_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_unbounded_sequence_char_field = TypeObjectUtils::build_complete_struct_member(common_unbounded_sequence_char_field, detail_unbounded_sequence_char_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_unbounded_sequence_char_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_uint8_t_unbounded", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_byte", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + TypeIdentifier* element_identifier_anonymous_sequence_uint8_t_unbounded {nullptr}; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_uint8_t_unbounded = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_uint8_t_unbounded = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_sequence_uint8_t_unbounded = EK_COMPLETE; + if (TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d()) + { + equiv_kind_anonymous_sequence_uint8_t_unbounded = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_sequence_uint8_t_unbounded = 0; + PlainCollectionHeader header_anonymous_sequence_uint8_t_unbounded = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_sequence_uint8_t_unbounded, element_flags_anonymous_sequence_uint8_t_unbounded); + std::string type_id_kind_anonymous_sequence_uint8_t_unbounded("TI_PLAIN_SEQUENCE_SMALL"); + if (type_id_kind_anonymous_sequence_uint8_t_unbounded == "TI_PLAIN_SEQUENCE_SMALL") + { + SBound bound = 0; + PlainSequenceSElemDefn seq_sdefn = TypeObjectUtils::build_plain_sequence_s_elem_defn(header_anonymous_sequence_uint8_t_unbounded, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_uint8_t_unbounded)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_sequence_type_identifier(seq_sdefn, "anonymous_sequence_uint8_t_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_uint8_t_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBound bound = 0; + PlainSequenceLElemDefn seq_ldefn = TypeObjectUtils::build_plain_sequence_l_elem_defn(header_anonymous_sequence_uint8_t_unbounded, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_uint8_t_unbounded)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_sequence_type_identifier(seq_ldefn, "anonymous_sequence_uint8_t_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_uint8_t_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_uint8_t_unbounded", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_uint8_t_unbounded: Given Sequence TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_unbounded_sequence_uint8_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_unbounded_sequence_uint8_field; + MemberId member_id_unbounded_sequence_uint8_field = 0x00000031; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_unbounded_sequence_uint8_field = TypeObjectUtils::build_common_struct_member(member_id_unbounded_sequence_uint8_field, member_flags_unbounded_sequence_uint8_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_unbounded_sequence_uint8_field = TypeObjectUtils::build_common_struct_member(member_id_unbounded_sequence_uint8_field, member_flags_unbounded_sequence_uint8_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure unbounded_sequence_uint8_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_unbounded_sequence_uint8_field = "unbounded_sequence_uint8_field"; + eprosima::fastcdr::optional member_ann_builtin_unbounded_sequence_uint8_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_unbounded_sequence_uint8_field = TypeObjectUtils::build_complete_member_detail(name_unbounded_sequence_uint8_field, member_ann_builtin_unbounded_sequence_uint8_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_unbounded_sequence_uint8_field = TypeObjectUtils::build_complete_struct_member(common_unbounded_sequence_uint8_field, detail_unbounded_sequence_uint8_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_unbounded_sequence_uint8_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_int16_t_unbounded", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_int16_t", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + TypeIdentifier* element_identifier_anonymous_sequence_int16_t_unbounded {nullptr}; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_int16_t_unbounded = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_int16_t_unbounded = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_sequence_int16_t_unbounded = EK_COMPLETE; + if (TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d()) + { + equiv_kind_anonymous_sequence_int16_t_unbounded = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_sequence_int16_t_unbounded = 0; + PlainCollectionHeader header_anonymous_sequence_int16_t_unbounded = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_sequence_int16_t_unbounded, element_flags_anonymous_sequence_int16_t_unbounded); + std::string type_id_kind_anonymous_sequence_int16_t_unbounded("TI_PLAIN_SEQUENCE_SMALL"); + if (type_id_kind_anonymous_sequence_int16_t_unbounded == "TI_PLAIN_SEQUENCE_SMALL") + { + SBound bound = 0; + PlainSequenceSElemDefn seq_sdefn = TypeObjectUtils::build_plain_sequence_s_elem_defn(header_anonymous_sequence_int16_t_unbounded, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_int16_t_unbounded)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_sequence_type_identifier(seq_sdefn, "anonymous_sequence_int16_t_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_int16_t_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBound bound = 0; + PlainSequenceLElemDefn seq_ldefn = TypeObjectUtils::build_plain_sequence_l_elem_defn(header_anonymous_sequence_int16_t_unbounded, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_int16_t_unbounded)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_sequence_type_identifier(seq_ldefn, "anonymous_sequence_int16_t_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_int16_t_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_int16_t_unbounded", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_int16_t_unbounded: Given Sequence TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_unbounded_sequence_int16_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_unbounded_sequence_int16_field; + MemberId member_id_unbounded_sequence_int16_field = 0x00000032; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_unbounded_sequence_int16_field = TypeObjectUtils::build_common_struct_member(member_id_unbounded_sequence_int16_field, member_flags_unbounded_sequence_int16_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_unbounded_sequence_int16_field = TypeObjectUtils::build_common_struct_member(member_id_unbounded_sequence_int16_field, member_flags_unbounded_sequence_int16_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure unbounded_sequence_int16_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_unbounded_sequence_int16_field = "unbounded_sequence_int16_field"; + eprosima::fastcdr::optional member_ann_builtin_unbounded_sequence_int16_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_unbounded_sequence_int16_field = TypeObjectUtils::build_complete_member_detail(name_unbounded_sequence_int16_field, member_ann_builtin_unbounded_sequence_int16_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_unbounded_sequence_int16_field = TypeObjectUtils::build_complete_struct_member(common_unbounded_sequence_int16_field, detail_unbounded_sequence_int16_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_unbounded_sequence_int16_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_uint16_t_unbounded", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_uint16_t", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + TypeIdentifier* element_identifier_anonymous_sequence_uint16_t_unbounded {nullptr}; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_uint16_t_unbounded = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_uint16_t_unbounded = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_sequence_uint16_t_unbounded = EK_COMPLETE; + if (TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d()) + { + equiv_kind_anonymous_sequence_uint16_t_unbounded = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_sequence_uint16_t_unbounded = 0; + PlainCollectionHeader header_anonymous_sequence_uint16_t_unbounded = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_sequence_uint16_t_unbounded, element_flags_anonymous_sequence_uint16_t_unbounded); + std::string type_id_kind_anonymous_sequence_uint16_t_unbounded("TI_PLAIN_SEQUENCE_SMALL"); + if (type_id_kind_anonymous_sequence_uint16_t_unbounded == "TI_PLAIN_SEQUENCE_SMALL") + { + SBound bound = 0; + PlainSequenceSElemDefn seq_sdefn = TypeObjectUtils::build_plain_sequence_s_elem_defn(header_anonymous_sequence_uint16_t_unbounded, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_uint16_t_unbounded)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_sequence_type_identifier(seq_sdefn, "anonymous_sequence_uint16_t_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_uint16_t_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBound bound = 0; + PlainSequenceLElemDefn seq_ldefn = TypeObjectUtils::build_plain_sequence_l_elem_defn(header_anonymous_sequence_uint16_t_unbounded, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_uint16_t_unbounded)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_sequence_type_identifier(seq_ldefn, "anonymous_sequence_uint16_t_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_uint16_t_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_uint16_t_unbounded", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_uint16_t_unbounded: Given Sequence TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_unbounded_sequence_uint16_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_unbounded_sequence_uint16_field; + MemberId member_id_unbounded_sequence_uint16_field = 0x00000033; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_unbounded_sequence_uint16_field = TypeObjectUtils::build_common_struct_member(member_id_unbounded_sequence_uint16_field, member_flags_unbounded_sequence_uint16_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_unbounded_sequence_uint16_field = TypeObjectUtils::build_common_struct_member(member_id_unbounded_sequence_uint16_field, member_flags_unbounded_sequence_uint16_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure unbounded_sequence_uint16_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_unbounded_sequence_uint16_field = "unbounded_sequence_uint16_field"; + eprosima::fastcdr::optional member_ann_builtin_unbounded_sequence_uint16_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_unbounded_sequence_uint16_field = TypeObjectUtils::build_complete_member_detail(name_unbounded_sequence_uint16_field, member_ann_builtin_unbounded_sequence_uint16_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_unbounded_sequence_uint16_field = TypeObjectUtils::build_complete_struct_member(common_unbounded_sequence_uint16_field, detail_unbounded_sequence_uint16_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_unbounded_sequence_uint16_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_int32_t_unbounded", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_int32_t", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + TypeIdentifier* element_identifier_anonymous_sequence_int32_t_unbounded {nullptr}; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_int32_t_unbounded = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_int32_t_unbounded = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_sequence_int32_t_unbounded = EK_COMPLETE; + if (TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d()) + { + equiv_kind_anonymous_sequence_int32_t_unbounded = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_sequence_int32_t_unbounded = 0; + PlainCollectionHeader header_anonymous_sequence_int32_t_unbounded = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_sequence_int32_t_unbounded, element_flags_anonymous_sequence_int32_t_unbounded); + std::string type_id_kind_anonymous_sequence_int32_t_unbounded("TI_PLAIN_SEQUENCE_SMALL"); + if (type_id_kind_anonymous_sequence_int32_t_unbounded == "TI_PLAIN_SEQUENCE_SMALL") + { + SBound bound = 0; + PlainSequenceSElemDefn seq_sdefn = TypeObjectUtils::build_plain_sequence_s_elem_defn(header_anonymous_sequence_int32_t_unbounded, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_int32_t_unbounded)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_sequence_type_identifier(seq_sdefn, "anonymous_sequence_int32_t_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_int32_t_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBound bound = 0; + PlainSequenceLElemDefn seq_ldefn = TypeObjectUtils::build_plain_sequence_l_elem_defn(header_anonymous_sequence_int32_t_unbounded, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_int32_t_unbounded)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_sequence_type_identifier(seq_ldefn, "anonymous_sequence_int32_t_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_int32_t_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_int32_t_unbounded", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_int32_t_unbounded: Given Sequence TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_unbounded_sequence_int32_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_unbounded_sequence_int32_field; + MemberId member_id_unbounded_sequence_int32_field = 0x00000034; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_unbounded_sequence_int32_field = TypeObjectUtils::build_common_struct_member(member_id_unbounded_sequence_int32_field, member_flags_unbounded_sequence_int32_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_unbounded_sequence_int32_field = TypeObjectUtils::build_common_struct_member(member_id_unbounded_sequence_int32_field, member_flags_unbounded_sequence_int32_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure unbounded_sequence_int32_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_unbounded_sequence_int32_field = "unbounded_sequence_int32_field"; + eprosima::fastcdr::optional member_ann_builtin_unbounded_sequence_int32_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_unbounded_sequence_int32_field = TypeObjectUtils::build_complete_member_detail(name_unbounded_sequence_int32_field, member_ann_builtin_unbounded_sequence_int32_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_unbounded_sequence_int32_field = TypeObjectUtils::build_complete_struct_member(common_unbounded_sequence_int32_field, detail_unbounded_sequence_int32_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_unbounded_sequence_int32_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_uint32_t_unbounded", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_uint32_t", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + TypeIdentifier* element_identifier_anonymous_sequence_uint32_t_unbounded {nullptr}; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_uint32_t_unbounded = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_uint32_t_unbounded = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_sequence_uint32_t_unbounded = EK_COMPLETE; + if (TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d()) + { + equiv_kind_anonymous_sequence_uint32_t_unbounded = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_sequence_uint32_t_unbounded = 0; + PlainCollectionHeader header_anonymous_sequence_uint32_t_unbounded = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_sequence_uint32_t_unbounded, element_flags_anonymous_sequence_uint32_t_unbounded); + std::string type_id_kind_anonymous_sequence_uint32_t_unbounded("TI_PLAIN_SEQUENCE_SMALL"); + if (type_id_kind_anonymous_sequence_uint32_t_unbounded == "TI_PLAIN_SEQUENCE_SMALL") + { + SBound bound = 0; + PlainSequenceSElemDefn seq_sdefn = TypeObjectUtils::build_plain_sequence_s_elem_defn(header_anonymous_sequence_uint32_t_unbounded, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_uint32_t_unbounded)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_sequence_type_identifier(seq_sdefn, "anonymous_sequence_uint32_t_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_uint32_t_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBound bound = 0; + PlainSequenceLElemDefn seq_ldefn = TypeObjectUtils::build_plain_sequence_l_elem_defn(header_anonymous_sequence_uint32_t_unbounded, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_uint32_t_unbounded)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_sequence_type_identifier(seq_ldefn, "anonymous_sequence_uint32_t_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_uint32_t_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_uint32_t_unbounded", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_uint32_t_unbounded: Given Sequence TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_unbounded_sequence_uint32_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_unbounded_sequence_uint32_field; + MemberId member_id_unbounded_sequence_uint32_field = 0x00000035; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_unbounded_sequence_uint32_field = TypeObjectUtils::build_common_struct_member(member_id_unbounded_sequence_uint32_field, member_flags_unbounded_sequence_uint32_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_unbounded_sequence_uint32_field = TypeObjectUtils::build_common_struct_member(member_id_unbounded_sequence_uint32_field, member_flags_unbounded_sequence_uint32_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure unbounded_sequence_uint32_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_unbounded_sequence_uint32_field = "unbounded_sequence_uint32_field"; + eprosima::fastcdr::optional member_ann_builtin_unbounded_sequence_uint32_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_unbounded_sequence_uint32_field = TypeObjectUtils::build_complete_member_detail(name_unbounded_sequence_uint32_field, member_ann_builtin_unbounded_sequence_uint32_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_unbounded_sequence_uint32_field = TypeObjectUtils::build_complete_struct_member(common_unbounded_sequence_uint32_field, detail_unbounded_sequence_uint32_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_unbounded_sequence_uint32_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_int64_t_unbounded", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_int64_t", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + TypeIdentifier* element_identifier_anonymous_sequence_int64_t_unbounded {nullptr}; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_int64_t_unbounded = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_int64_t_unbounded = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_sequence_int64_t_unbounded = EK_COMPLETE; + if (TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d()) + { + equiv_kind_anonymous_sequence_int64_t_unbounded = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_sequence_int64_t_unbounded = 0; + PlainCollectionHeader header_anonymous_sequence_int64_t_unbounded = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_sequence_int64_t_unbounded, element_flags_anonymous_sequence_int64_t_unbounded); + std::string type_id_kind_anonymous_sequence_int64_t_unbounded("TI_PLAIN_SEQUENCE_SMALL"); + if (type_id_kind_anonymous_sequence_int64_t_unbounded == "TI_PLAIN_SEQUENCE_SMALL") + { + SBound bound = 0; + PlainSequenceSElemDefn seq_sdefn = TypeObjectUtils::build_plain_sequence_s_elem_defn(header_anonymous_sequence_int64_t_unbounded, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_int64_t_unbounded)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_sequence_type_identifier(seq_sdefn, "anonymous_sequence_int64_t_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_int64_t_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBound bound = 0; + PlainSequenceLElemDefn seq_ldefn = TypeObjectUtils::build_plain_sequence_l_elem_defn(header_anonymous_sequence_int64_t_unbounded, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_int64_t_unbounded)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_sequence_type_identifier(seq_ldefn, "anonymous_sequence_int64_t_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_int64_t_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_int64_t_unbounded", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_int64_t_unbounded: Given Sequence TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_unbounded_sequence_int64_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_unbounded_sequence_int64_field; + MemberId member_id_unbounded_sequence_int64_field = 0x00000036; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_unbounded_sequence_int64_field = TypeObjectUtils::build_common_struct_member(member_id_unbounded_sequence_int64_field, member_flags_unbounded_sequence_int64_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_unbounded_sequence_int64_field = TypeObjectUtils::build_common_struct_member(member_id_unbounded_sequence_int64_field, member_flags_unbounded_sequence_int64_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure unbounded_sequence_int64_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_unbounded_sequence_int64_field = "unbounded_sequence_int64_field"; + eprosima::fastcdr::optional member_ann_builtin_unbounded_sequence_int64_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_unbounded_sequence_int64_field = TypeObjectUtils::build_complete_member_detail(name_unbounded_sequence_int64_field, member_ann_builtin_unbounded_sequence_int64_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_unbounded_sequence_int64_field = TypeObjectUtils::build_complete_struct_member(common_unbounded_sequence_int64_field, detail_unbounded_sequence_int64_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_unbounded_sequence_int64_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_uint64_t_unbounded", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_uint64_t", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + TypeIdentifier* element_identifier_anonymous_sequence_uint64_t_unbounded {nullptr}; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_uint64_t_unbounded = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_uint64_t_unbounded = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_sequence_uint64_t_unbounded = EK_COMPLETE; + if (TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d()) + { + equiv_kind_anonymous_sequence_uint64_t_unbounded = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_sequence_uint64_t_unbounded = 0; + PlainCollectionHeader header_anonymous_sequence_uint64_t_unbounded = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_sequence_uint64_t_unbounded, element_flags_anonymous_sequence_uint64_t_unbounded); + std::string type_id_kind_anonymous_sequence_uint64_t_unbounded("TI_PLAIN_SEQUENCE_SMALL"); + if (type_id_kind_anonymous_sequence_uint64_t_unbounded == "TI_PLAIN_SEQUENCE_SMALL") + { + SBound bound = 0; + PlainSequenceSElemDefn seq_sdefn = TypeObjectUtils::build_plain_sequence_s_elem_defn(header_anonymous_sequence_uint64_t_unbounded, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_uint64_t_unbounded)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_sequence_type_identifier(seq_sdefn, "anonymous_sequence_uint64_t_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_uint64_t_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBound bound = 0; + PlainSequenceLElemDefn seq_ldefn = TypeObjectUtils::build_plain_sequence_l_elem_defn(header_anonymous_sequence_uint64_t_unbounded, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_uint64_t_unbounded)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_sequence_type_identifier(seq_ldefn, "anonymous_sequence_uint64_t_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_uint64_t_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_uint64_t_unbounded", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_uint64_t_unbounded: Given Sequence TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_unbounded_sequence_uint64_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_unbounded_sequence_uint64_field; + MemberId member_id_unbounded_sequence_uint64_field = 0x00000037; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_unbounded_sequence_uint64_field = TypeObjectUtils::build_common_struct_member(member_id_unbounded_sequence_uint64_field, member_flags_unbounded_sequence_uint64_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_unbounded_sequence_uint64_field = TypeObjectUtils::build_common_struct_member(member_id_unbounded_sequence_uint64_field, member_flags_unbounded_sequence_uint64_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure unbounded_sequence_uint64_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_unbounded_sequence_uint64_field = "unbounded_sequence_uint64_field"; + eprosima::fastcdr::optional member_ann_builtin_unbounded_sequence_uint64_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_unbounded_sequence_uint64_field = TypeObjectUtils::build_complete_member_detail(name_unbounded_sequence_uint64_field, member_ann_builtin_unbounded_sequence_uint64_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_unbounded_sequence_uint64_field = TypeObjectUtils::build_complete_struct_member(common_unbounded_sequence_uint64_field, detail_unbounded_sequence_uint64_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_unbounded_sequence_uint64_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_float_unbounded", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_float", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + TypeIdentifier* element_identifier_anonymous_sequence_float_unbounded {nullptr}; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_float_unbounded = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_float_unbounded = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_sequence_float_unbounded = EK_COMPLETE; + if (TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d()) + { + equiv_kind_anonymous_sequence_float_unbounded = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_sequence_float_unbounded = 0; + PlainCollectionHeader header_anonymous_sequence_float_unbounded = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_sequence_float_unbounded, element_flags_anonymous_sequence_float_unbounded); + std::string type_id_kind_anonymous_sequence_float_unbounded("TI_PLAIN_SEQUENCE_SMALL"); + if (type_id_kind_anonymous_sequence_float_unbounded == "TI_PLAIN_SEQUENCE_SMALL") + { + SBound bound = 0; + PlainSequenceSElemDefn seq_sdefn = TypeObjectUtils::build_plain_sequence_s_elem_defn(header_anonymous_sequence_float_unbounded, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_float_unbounded)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_sequence_type_identifier(seq_sdefn, "anonymous_sequence_float_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_float_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBound bound = 0; + PlainSequenceLElemDefn seq_ldefn = TypeObjectUtils::build_plain_sequence_l_elem_defn(header_anonymous_sequence_float_unbounded, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_float_unbounded)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_sequence_type_identifier(seq_ldefn, "anonymous_sequence_float_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_float_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_float_unbounded", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_float_unbounded: Given Sequence TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_unbounded_sequence_float_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_unbounded_sequence_float_field; + MemberId member_id_unbounded_sequence_float_field = 0x00000038; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_unbounded_sequence_float_field = TypeObjectUtils::build_common_struct_member(member_id_unbounded_sequence_float_field, member_flags_unbounded_sequence_float_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_unbounded_sequence_float_field = TypeObjectUtils::build_common_struct_member(member_id_unbounded_sequence_float_field, member_flags_unbounded_sequence_float_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure unbounded_sequence_float_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_unbounded_sequence_float_field = "unbounded_sequence_float_field"; + eprosima::fastcdr::optional member_ann_builtin_unbounded_sequence_float_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_unbounded_sequence_float_field = TypeObjectUtils::build_complete_member_detail(name_unbounded_sequence_float_field, member_ann_builtin_unbounded_sequence_float_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_unbounded_sequence_float_field = TypeObjectUtils::build_complete_struct_member(common_unbounded_sequence_float_field, detail_unbounded_sequence_float_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_unbounded_sequence_float_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_double_unbounded", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_double", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + TypeIdentifier* element_identifier_anonymous_sequence_double_unbounded {nullptr}; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_double_unbounded = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_double_unbounded = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_sequence_double_unbounded = EK_COMPLETE; + if (TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d()) + { + equiv_kind_anonymous_sequence_double_unbounded = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_sequence_double_unbounded = 0; + PlainCollectionHeader header_anonymous_sequence_double_unbounded = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_sequence_double_unbounded, element_flags_anonymous_sequence_double_unbounded); + std::string type_id_kind_anonymous_sequence_double_unbounded("TI_PLAIN_SEQUENCE_SMALL"); + if (type_id_kind_anonymous_sequence_double_unbounded == "TI_PLAIN_SEQUENCE_SMALL") + { + SBound bound = 0; + PlainSequenceSElemDefn seq_sdefn = TypeObjectUtils::build_plain_sequence_s_elem_defn(header_anonymous_sequence_double_unbounded, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_double_unbounded)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_sequence_type_identifier(seq_sdefn, "anonymous_sequence_double_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_double_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBound bound = 0; + PlainSequenceLElemDefn seq_ldefn = TypeObjectUtils::build_plain_sequence_l_elem_defn(header_anonymous_sequence_double_unbounded, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_double_unbounded)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_sequence_type_identifier(seq_ldefn, "anonymous_sequence_double_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_double_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_double_unbounded", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_double_unbounded: Given Sequence TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_unbounded_sequence_double_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_unbounded_sequence_double_field; + MemberId member_id_unbounded_sequence_double_field = 0x00000039; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_unbounded_sequence_double_field = TypeObjectUtils::build_common_struct_member(member_id_unbounded_sequence_double_field, member_flags_unbounded_sequence_double_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_unbounded_sequence_double_field = TypeObjectUtils::build_common_struct_member(member_id_unbounded_sequence_double_field, member_flags_unbounded_sequence_double_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure unbounded_sequence_double_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_unbounded_sequence_double_field = "unbounded_sequence_double_field"; + eprosima::fastcdr::optional member_ann_builtin_unbounded_sequence_double_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_unbounded_sequence_double_field = TypeObjectUtils::build_complete_member_detail(name_unbounded_sequence_double_field, member_ann_builtin_unbounded_sequence_double_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_unbounded_sequence_double_field = TypeObjectUtils::build_complete_struct_member(common_unbounded_sequence_double_field, detail_unbounded_sequence_double_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_unbounded_sequence_double_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_longdouble_unbounded", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_longdouble", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + TypeIdentifier* element_identifier_anonymous_sequence_longdouble_unbounded {nullptr}; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_longdouble_unbounded = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_longdouble_unbounded = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_sequence_longdouble_unbounded = EK_COMPLETE; + if (TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d()) + { + equiv_kind_anonymous_sequence_longdouble_unbounded = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_sequence_longdouble_unbounded = 0; + PlainCollectionHeader header_anonymous_sequence_longdouble_unbounded = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_sequence_longdouble_unbounded, element_flags_anonymous_sequence_longdouble_unbounded); + std::string type_id_kind_anonymous_sequence_longdouble_unbounded("TI_PLAIN_SEQUENCE_SMALL"); + if (type_id_kind_anonymous_sequence_longdouble_unbounded == "TI_PLAIN_SEQUENCE_SMALL") + { + SBound bound = 0; + PlainSequenceSElemDefn seq_sdefn = TypeObjectUtils::build_plain_sequence_s_elem_defn(header_anonymous_sequence_longdouble_unbounded, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_longdouble_unbounded)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_sequence_type_identifier(seq_sdefn, "anonymous_sequence_longdouble_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_longdouble_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBound bound = 0; + PlainSequenceLElemDefn seq_ldefn = TypeObjectUtils::build_plain_sequence_l_elem_defn(header_anonymous_sequence_longdouble_unbounded, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_longdouble_unbounded)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_sequence_type_identifier(seq_ldefn, "anonymous_sequence_longdouble_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_longdouble_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_longdouble_unbounded", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_longdouble_unbounded: Given Sequence TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_unbounded_sequence_long_double_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_unbounded_sequence_long_double_field; + MemberId member_id_unbounded_sequence_long_double_field = 0x0000003a; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_unbounded_sequence_long_double_field = TypeObjectUtils::build_common_struct_member(member_id_unbounded_sequence_long_double_field, member_flags_unbounded_sequence_long_double_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_unbounded_sequence_long_double_field = TypeObjectUtils::build_common_struct_member(member_id_unbounded_sequence_long_double_field, member_flags_unbounded_sequence_long_double_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure unbounded_sequence_long_double_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_unbounded_sequence_long_double_field = "unbounded_sequence_long_double_field"; + eprosima::fastcdr::optional member_ann_builtin_unbounded_sequence_long_double_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_unbounded_sequence_long_double_field = TypeObjectUtils::build_complete_member_detail(name_unbounded_sequence_long_double_field, member_ann_builtin_unbounded_sequence_long_double_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_unbounded_sequence_long_double_field = TypeObjectUtils::build_complete_struct_member(common_unbounded_sequence_long_double_field, detail_unbounded_sequence_long_double_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_unbounded_sequence_long_double_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_bool_unbounded", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_bool", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + TypeIdentifier* element_identifier_anonymous_sequence_bool_unbounded {nullptr}; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_bool_unbounded = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_bool_unbounded = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_sequence_bool_unbounded = EK_COMPLETE; + if (TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d()) + { + equiv_kind_anonymous_sequence_bool_unbounded = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_sequence_bool_unbounded = 0; + PlainCollectionHeader header_anonymous_sequence_bool_unbounded = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_sequence_bool_unbounded, element_flags_anonymous_sequence_bool_unbounded); + std::string type_id_kind_anonymous_sequence_bool_unbounded("TI_PLAIN_SEQUENCE_SMALL"); + if (type_id_kind_anonymous_sequence_bool_unbounded == "TI_PLAIN_SEQUENCE_SMALL") + { + SBound bound = 0; + PlainSequenceSElemDefn seq_sdefn = TypeObjectUtils::build_plain_sequence_s_elem_defn(header_anonymous_sequence_bool_unbounded, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_bool_unbounded)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_sequence_type_identifier(seq_sdefn, "anonymous_sequence_bool_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_bool_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBound bound = 0; + PlainSequenceLElemDefn seq_ldefn = TypeObjectUtils::build_plain_sequence_l_elem_defn(header_anonymous_sequence_bool_unbounded, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_bool_unbounded)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_sequence_type_identifier(seq_ldefn, "anonymous_sequence_bool_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_bool_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_bool_unbounded", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_bool_unbounded: Given Sequence TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_unbounded_sequence_bool_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_unbounded_sequence_bool_field; + MemberId member_id_unbounded_sequence_bool_field = 0x0000003b; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_unbounded_sequence_bool_field = TypeObjectUtils::build_common_struct_member(member_id_unbounded_sequence_bool_field, member_flags_unbounded_sequence_bool_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_unbounded_sequence_bool_field = TypeObjectUtils::build_common_struct_member(member_id_unbounded_sequence_bool_field, member_flags_unbounded_sequence_bool_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure unbounded_sequence_bool_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_unbounded_sequence_bool_field = "unbounded_sequence_bool_field"; + eprosima::fastcdr::optional member_ann_builtin_unbounded_sequence_bool_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_unbounded_sequence_bool_field = TypeObjectUtils::build_complete_member_detail(name_unbounded_sequence_bool_field, member_ann_builtin_unbounded_sequence_bool_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_unbounded_sequence_bool_field = TypeObjectUtils::build_complete_struct_member(common_unbounded_sequence_bool_field, detail_unbounded_sequence_bool_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_unbounded_sequence_bool_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_anonymous_string_unbounded_unbounded", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_string_unbounded", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + std::string type_id_kind_anonymous_string_unbounded("TI_STRING8_SMALL"); + if (type_id_kind_anonymous_string_unbounded == "TI_STRING8_SMALL") + { + SBound bound = 0; + StringSTypeDefn string_sdefn = TypeObjectUtils::build_string_s_type_defn(bound); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_string_type_identifier(string_sdefn, + "anonymous_string_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else if (type_id_kind_anonymous_string_unbounded == "TI_STRING8_LARGE") + { + LBound bound = 255; + StringLTypeDefn string_ldefn = TypeObjectUtils::build_string_l_type_defn(bound); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_string_type_identifier(string_ldefn, + "anonymous_string_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded: Unknown String kind."); + return; + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_string_unbounded", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded: Given String TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + TypeIdentifier* element_identifier_anonymous_sequence_anonymous_string_unbounded_unbounded {nullptr}; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_anonymous_string_unbounded_unbounded = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_anonymous_string_unbounded_unbounded = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_sequence_anonymous_string_unbounded_unbounded = EK_COMPLETE; + if (TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d()) + { + equiv_kind_anonymous_sequence_anonymous_string_unbounded_unbounded = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_sequence_anonymous_string_unbounded_unbounded = 0; + PlainCollectionHeader header_anonymous_sequence_anonymous_string_unbounded_unbounded = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_sequence_anonymous_string_unbounded_unbounded, element_flags_anonymous_sequence_anonymous_string_unbounded_unbounded); + std::string type_id_kind_anonymous_sequence_anonymous_string_unbounded_unbounded("TI_PLAIN_SEQUENCE_SMALL"); + if (type_id_kind_anonymous_sequence_anonymous_string_unbounded_unbounded == "TI_PLAIN_SEQUENCE_SMALL") + { + SBound bound = 0; + PlainSequenceSElemDefn seq_sdefn = TypeObjectUtils::build_plain_sequence_s_elem_defn(header_anonymous_sequence_anonymous_string_unbounded_unbounded, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_anonymous_string_unbounded_unbounded)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_sequence_type_identifier(seq_sdefn, "anonymous_sequence_anonymous_string_unbounded_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_anonymous_string_unbounded_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBound bound = 0; + PlainSequenceLElemDefn seq_ldefn = TypeObjectUtils::build_plain_sequence_l_elem_defn(header_anonymous_sequence_anonymous_string_unbounded_unbounded, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_anonymous_string_unbounded_unbounded)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_sequence_type_identifier(seq_ldefn, "anonymous_sequence_anonymous_string_unbounded_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_anonymous_string_unbounded_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_anonymous_string_unbounded_unbounded", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_anonymous_string_unbounded_unbounded: Given Sequence TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_unbounded_sequence_string_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_unbounded_sequence_string_field; + MemberId member_id_unbounded_sequence_string_field = 0x0000003c; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_unbounded_sequence_string_field = TypeObjectUtils::build_common_struct_member(member_id_unbounded_sequence_string_field, member_flags_unbounded_sequence_string_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_unbounded_sequence_string_field = TypeObjectUtils::build_common_struct_member(member_id_unbounded_sequence_string_field, member_flags_unbounded_sequence_string_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure unbounded_sequence_string_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_unbounded_sequence_string_field = "unbounded_sequence_string_field"; + eprosima::fastcdr::optional member_ann_builtin_unbounded_sequence_string_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_unbounded_sequence_string_field = TypeObjectUtils::build_complete_member_detail(name_unbounded_sequence_string_field, member_ann_builtin_unbounded_sequence_string_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_unbounded_sequence_string_field = TypeObjectUtils::build_complete_struct_member(common_unbounded_sequence_string_field, detail_unbounded_sequence_string_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_unbounded_sequence_string_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_Color_unbounded", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "Color", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EnumTypeFlag enum_flags_Color = 0; + BitBound bit_bound_Color = 32; + CommonEnumeratedHeader common_Color = TypeObjectUtils::build_common_enumerated_header(bit_bound_Color); + QualifiedTypeName type_name_Color = "Color"; + eprosima::fastcdr::optional type_ann_builtin_Color; + eprosima::fastcdr::optional ann_custom_Color; + CompleteTypeDetail detail_Color = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_Color, ann_custom_Color, type_name_Color.to_string()); + CompleteEnumeratedHeader header_Color = TypeObjectUtils::build_complete_enumerated_header(common_Color, detail_Color); + CompleteEnumeratedLiteralSeq literal_seq_Color; + { + EnumeratedLiteralFlag flags_RED = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_RED = TypeObjectUtils::build_common_enumerated_literal(0, flags_RED); + eprosima::fastcdr::optional member_ann_builtin_RED; + ann_custom_Color.reset(); + MemberName name_RED = "RED"; + CompleteMemberDetail detail_RED = TypeObjectUtils::build_complete_member_detail(name_RED, member_ann_builtin_RED, ann_custom_Color); + CompleteEnumeratedLiteral literal_RED = TypeObjectUtils::build_complete_enumerated_literal(common_RED, detail_RED); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Color, literal_RED); + } + { + EnumeratedLiteralFlag flags_GREEN = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_GREEN = TypeObjectUtils::build_common_enumerated_literal(1, flags_GREEN); + eprosima::fastcdr::optional member_ann_builtin_GREEN; + ann_custom_Color.reset(); + MemberName name_GREEN = "GREEN"; + CompleteMemberDetail detail_GREEN = TypeObjectUtils::build_complete_member_detail(name_GREEN, member_ann_builtin_GREEN, ann_custom_Color); + CompleteEnumeratedLiteral literal_GREEN = TypeObjectUtils::build_complete_enumerated_literal(common_GREEN, detail_GREEN); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Color, literal_GREEN); + } + { + EnumeratedLiteralFlag flags_BLUE = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_BLUE = TypeObjectUtils::build_common_enumerated_literal(2, flags_BLUE); + eprosima::fastcdr::optional member_ann_builtin_BLUE; + ann_custom_Color.reset(); + MemberName name_BLUE = "BLUE"; + CompleteMemberDetail detail_BLUE = TypeObjectUtils::build_complete_member_detail(name_BLUE, member_ann_builtin_BLUE, ann_custom_Color); + CompleteEnumeratedLiteral literal_BLUE = TypeObjectUtils::build_complete_enumerated_literal(common_BLUE, detail_BLUE); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Color, literal_BLUE); + } + { + EnumeratedLiteralFlag flags_YELLOW = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_YELLOW = TypeObjectUtils::build_common_enumerated_literal(3, flags_YELLOW); + eprosima::fastcdr::optional member_ann_builtin_YELLOW; + ann_custom_Color.reset(); + MemberName name_YELLOW = "YELLOW"; + CompleteMemberDetail detail_YELLOW = TypeObjectUtils::build_complete_member_detail(name_YELLOW, member_ann_builtin_YELLOW, ann_custom_Color); + CompleteEnumeratedLiteral literal_YELLOW = TypeObjectUtils::build_complete_enumerated_literal(common_YELLOW, detail_YELLOW); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Color, literal_YELLOW); + } + { + EnumeratedLiteralFlag flags_MAGENTA = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_MAGENTA = TypeObjectUtils::build_common_enumerated_literal(4, flags_MAGENTA); + eprosima::fastcdr::optional member_ann_builtin_MAGENTA; + ann_custom_Color.reset(); + MemberName name_MAGENTA = "MAGENTA"; + CompleteMemberDetail detail_MAGENTA = TypeObjectUtils::build_complete_member_detail(name_MAGENTA, member_ann_builtin_MAGENTA, ann_custom_Color); + CompleteEnumeratedLiteral literal_MAGENTA = TypeObjectUtils::build_complete_enumerated_literal(common_MAGENTA, detail_MAGENTA); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Color, literal_MAGENTA); + } + CompleteEnumeratedType enumerated_type_Color = TypeObjectUtils::build_complete_enumerated_type(enum_flags_Color, header_Color, + literal_seq_Color); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_enumerated_type_object(enumerated_type_Color, type_name_Color.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Color already registered in TypeObjectRegistry for a different type."); + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "Color", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Color: Given Enum TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + TypeIdentifier* element_identifier_anonymous_sequence_Color_unbounded {nullptr}; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_Color_unbounded = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_Color_unbounded = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_sequence_Color_unbounded = EK_COMPLETE; + if (TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d()) + { + equiv_kind_anonymous_sequence_Color_unbounded = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_sequence_Color_unbounded = 0; + PlainCollectionHeader header_anonymous_sequence_Color_unbounded = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_sequence_Color_unbounded, element_flags_anonymous_sequence_Color_unbounded); + std::string type_id_kind_anonymous_sequence_Color_unbounded("TI_PLAIN_SEQUENCE_SMALL"); + if (type_id_kind_anonymous_sequence_Color_unbounded == "TI_PLAIN_SEQUENCE_SMALL") + { + SBound bound = 0; + PlainSequenceSElemDefn seq_sdefn = TypeObjectUtils::build_plain_sequence_s_elem_defn(header_anonymous_sequence_Color_unbounded, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_Color_unbounded)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_sequence_type_identifier(seq_sdefn, "anonymous_sequence_Color_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_Color_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBound bound = 0; + PlainSequenceLElemDefn seq_ldefn = TypeObjectUtils::build_plain_sequence_l_elem_defn(header_anonymous_sequence_Color_unbounded, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_Color_unbounded)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_sequence_type_identifier(seq_ldefn, "anonymous_sequence_Color_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_Color_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_Color_unbounded", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_Color_unbounded: Given Sequence TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_unbounded_sequence_enum_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_unbounded_sequence_enum_field; + MemberId member_id_unbounded_sequence_enum_field = 0x0000003d; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_unbounded_sequence_enum_field = TypeObjectUtils::build_common_struct_member(member_id_unbounded_sequence_enum_field, member_flags_unbounded_sequence_enum_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_unbounded_sequence_enum_field = TypeObjectUtils::build_common_struct_member(member_id_unbounded_sequence_enum_field, member_flags_unbounded_sequence_enum_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure unbounded_sequence_enum_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_unbounded_sequence_enum_field = "unbounded_sequence_enum_field"; + eprosima::fastcdr::optional member_ann_builtin_unbounded_sequence_enum_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_unbounded_sequence_enum_field = TypeObjectUtils::build_complete_member_detail(name_unbounded_sequence_enum_field, member_ann_builtin_unbounded_sequence_enum_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_unbounded_sequence_enum_field = TypeObjectUtils::build_complete_struct_member(common_unbounded_sequence_enum_field, detail_unbounded_sequence_enum_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_unbounded_sequence_enum_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_Material_unbounded", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "Material", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EnumTypeFlag enum_flags_Material = 0; + BitBound bit_bound_Material = 32; + CommonEnumeratedHeader common_Material = TypeObjectUtils::build_common_enumerated_header(bit_bound_Material); + QualifiedTypeName type_name_Material = "Material"; + eprosima::fastcdr::optional type_ann_builtin_Material; + eprosima::fastcdr::optional ann_custom_Material; + CompleteTypeDetail detail_Material = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_Material, ann_custom_Material, type_name_Material.to_string()); + CompleteEnumeratedHeader header_Material = TypeObjectUtils::build_complete_enumerated_header(common_Material, detail_Material); + CompleteEnumeratedLiteralSeq literal_seq_Material; + { + EnumeratedLiteralFlag flags_WOOD = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_WOOD = TypeObjectUtils::build_common_enumerated_literal(0, flags_WOOD); + eprosima::fastcdr::optional member_ann_builtin_WOOD; + ann_custom_Material.reset(); + MemberName name_WOOD = "WOOD"; + CompleteMemberDetail detail_WOOD = TypeObjectUtils::build_complete_member_detail(name_WOOD, member_ann_builtin_WOOD, ann_custom_Material); + CompleteEnumeratedLiteral literal_WOOD = TypeObjectUtils::build_complete_enumerated_literal(common_WOOD, detail_WOOD); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Material, literal_WOOD); + } + { + EnumeratedLiteralFlag flags_PLASTIC = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_PLASTIC = TypeObjectUtils::build_common_enumerated_literal(1, flags_PLASTIC); + eprosima::fastcdr::optional member_ann_builtin_PLASTIC; + ann_custom_Material.reset(); + MemberName name_PLASTIC = "PLASTIC"; + CompleteMemberDetail detail_PLASTIC = TypeObjectUtils::build_complete_member_detail(name_PLASTIC, member_ann_builtin_PLASTIC, ann_custom_Material); + CompleteEnumeratedLiteral literal_PLASTIC = TypeObjectUtils::build_complete_enumerated_literal(common_PLASTIC, detail_PLASTIC); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Material, literal_PLASTIC); + } + { + EnumeratedLiteralFlag flags_METAL = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_METAL = TypeObjectUtils::build_common_enumerated_literal(2, flags_METAL); + eprosima::fastcdr::optional member_ann_builtin_METAL; + ann_custom_Material.reset(); + MemberName name_METAL = "METAL"; + CompleteMemberDetail detail_METAL = TypeObjectUtils::build_complete_member_detail(name_METAL, member_ann_builtin_METAL, ann_custom_Material); + CompleteEnumeratedLiteral literal_METAL = TypeObjectUtils::build_complete_enumerated_literal(common_METAL, detail_METAL); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Material, literal_METAL); + } + { + EnumeratedLiteralFlag flags_CONCRETE = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_CONCRETE = TypeObjectUtils::build_common_enumerated_literal(3, flags_CONCRETE); + eprosima::fastcdr::optional member_ann_builtin_CONCRETE; + ann_custom_Material.reset(); + MemberName name_CONCRETE = "CONCRETE"; + CompleteMemberDetail detail_CONCRETE = TypeObjectUtils::build_complete_member_detail(name_CONCRETE, member_ann_builtin_CONCRETE, ann_custom_Material); + CompleteEnumeratedLiteral literal_CONCRETE = TypeObjectUtils::build_complete_enumerated_literal(common_CONCRETE, detail_CONCRETE); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Material, literal_CONCRETE); + } + { + EnumeratedLiteralFlag flags_STONE = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_STONE = TypeObjectUtils::build_common_enumerated_literal(4, flags_STONE); + eprosima::fastcdr::optional member_ann_builtin_STONE; + ann_custom_Material.reset(); + MemberName name_STONE = "STONE"; + CompleteMemberDetail detail_STONE = TypeObjectUtils::build_complete_member_detail(name_STONE, member_ann_builtin_STONE, ann_custom_Material); + CompleteEnumeratedLiteral literal_STONE = TypeObjectUtils::build_complete_enumerated_literal(common_STONE, detail_STONE); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Material, literal_STONE); + } + CompleteEnumeratedType enumerated_type_Material = TypeObjectUtils::build_complete_enumerated_type(enum_flags_Material, header_Material, + literal_seq_Material); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_enumerated_type_object(enumerated_type_Material, type_name_Material.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Material already registered in TypeObjectRegistry for a different type."); + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "Material", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Material: Given Enum TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + TypeIdentifier* element_identifier_anonymous_sequence_Material_unbounded {nullptr}; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_Material_unbounded = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_Material_unbounded = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_sequence_Material_unbounded = EK_COMPLETE; + if (TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d()) + { + equiv_kind_anonymous_sequence_Material_unbounded = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_sequence_Material_unbounded = 0; + PlainCollectionHeader header_anonymous_sequence_Material_unbounded = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_sequence_Material_unbounded, element_flags_anonymous_sequence_Material_unbounded); + std::string type_id_kind_anonymous_sequence_Material_unbounded("TI_PLAIN_SEQUENCE_SMALL"); + if (type_id_kind_anonymous_sequence_Material_unbounded == "TI_PLAIN_SEQUENCE_SMALL") + { + SBound bound = 0; + PlainSequenceSElemDefn seq_sdefn = TypeObjectUtils::build_plain_sequence_s_elem_defn(header_anonymous_sequence_Material_unbounded, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_Material_unbounded)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_sequence_type_identifier(seq_sdefn, "anonymous_sequence_Material_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_Material_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBound bound = 0; + PlainSequenceLElemDefn seq_ldefn = TypeObjectUtils::build_plain_sequence_l_elem_defn(header_anonymous_sequence_Material_unbounded, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_Material_unbounded)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_sequence_type_identifier(seq_ldefn, "anonymous_sequence_Material_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_Material_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_Material_unbounded", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_Material_unbounded: Given Sequence TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_unbounded_sequence_enum2_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_unbounded_sequence_enum2_field; + MemberId member_id_unbounded_sequence_enum2_field = 0x0000003e; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_unbounded_sequence_enum2_field = TypeObjectUtils::build_common_struct_member(member_id_unbounded_sequence_enum2_field, member_flags_unbounded_sequence_enum2_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_unbounded_sequence_enum2_field = TypeObjectUtils::build_common_struct_member(member_id_unbounded_sequence_enum2_field, member_flags_unbounded_sequence_enum2_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure unbounded_sequence_enum2_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_unbounded_sequence_enum2_field = "unbounded_sequence_enum2_field"; + eprosima::fastcdr::optional member_ann_builtin_unbounded_sequence_enum2_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_unbounded_sequence_enum2_field = TypeObjectUtils::build_complete_member_detail(name_unbounded_sequence_enum2_field, member_ann_builtin_unbounded_sequence_enum2_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_unbounded_sequence_enum2_field = TypeObjectUtils::build_complete_struct_member(common_unbounded_sequence_enum2_field, detail_unbounded_sequence_enum2_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_unbounded_sequence_enum2_field); + } + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_StructType_unbounded", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "StructType", type_ids_ContentFilterTestType); + + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + { + StructTypeFlag struct_flags_StructType = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::NOT_APPLIED, + true, false); + ReturnCode_t return_code_StructType; + TypeIdentifierPair type_ids_StructType; + QualifiedTypeName type_name_StructType = "StructType"; + eprosima::fastcdr::optional type_ann_builtin_StructType; + eprosima::fastcdr::optional ann_custom_StructType; + AppliedAnnotationSeq tmp_ann_custom_StructType; + eprosima::fastcdr::optional verbatim_StructType; + if (!tmp_ann_custom_StructType.empty()) + { + ann_custom_StructType = tmp_ann_custom_StructType; + } + + CompleteTypeDetail detail_StructType = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_StructType, ann_custom_StructType, type_name_StructType.to_string()); + CompleteStructHeader header_StructType; + header_StructType = TypeObjectUtils::build_complete_struct_header(TypeIdentifier(), detail_StructType); + CompleteStructMemberSeq member_seq_StructType; + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_char", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "char_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_char_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_char_field; + MemberId member_id_char_field = 0x00000000; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_char_field = TypeObjectUtils::build_common_struct_member(member_id_char_field, member_flags_char_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_char_field = TypeObjectUtils::build_common_struct_member(member_id_char_field, member_flags_char_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure char_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_char_field = "char_field"; + eprosima::fastcdr::optional member_ann_builtin_char_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_char_field = TypeObjectUtils::build_complete_member_detail(name_char_field, member_ann_builtin_char_field, ann_custom_StructType); + CompleteStructMember member_char_field = TypeObjectUtils::build_complete_struct_member(common_char_field, detail_char_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_char_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_byte", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "uint8_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_uint8_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_uint8_field; + MemberId member_id_uint8_field = 0x00000001; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_uint8_field = TypeObjectUtils::build_common_struct_member(member_id_uint8_field, member_flags_uint8_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_uint8_field = TypeObjectUtils::build_common_struct_member(member_id_uint8_field, member_flags_uint8_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure uint8_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_uint8_field = "uint8_field"; + eprosima::fastcdr::optional member_ann_builtin_uint8_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_uint8_field = TypeObjectUtils::build_complete_member_detail(name_uint8_field, member_ann_builtin_uint8_field, ann_custom_StructType); + CompleteStructMember member_uint8_field = TypeObjectUtils::build_complete_struct_member(common_uint8_field, detail_uint8_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_uint8_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_int16_t", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "int16_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_int16_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_int16_field; + MemberId member_id_int16_field = 0x00000002; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_int16_field = TypeObjectUtils::build_common_struct_member(member_id_int16_field, member_flags_int16_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_int16_field = TypeObjectUtils::build_common_struct_member(member_id_int16_field, member_flags_int16_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure int16_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_int16_field = "int16_field"; + eprosima::fastcdr::optional member_ann_builtin_int16_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_int16_field = TypeObjectUtils::build_complete_member_detail(name_int16_field, member_ann_builtin_int16_field, ann_custom_StructType); + CompleteStructMember member_int16_field = TypeObjectUtils::build_complete_struct_member(common_int16_field, detail_int16_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_int16_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_uint16_t", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "uint16_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_uint16_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_uint16_field; + MemberId member_id_uint16_field = 0x00000003; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_uint16_field = TypeObjectUtils::build_common_struct_member(member_id_uint16_field, member_flags_uint16_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_uint16_field = TypeObjectUtils::build_common_struct_member(member_id_uint16_field, member_flags_uint16_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure uint16_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_uint16_field = "uint16_field"; + eprosima::fastcdr::optional member_ann_builtin_uint16_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_uint16_field = TypeObjectUtils::build_complete_member_detail(name_uint16_field, member_ann_builtin_uint16_field, ann_custom_StructType); + CompleteStructMember member_uint16_field = TypeObjectUtils::build_complete_struct_member(common_uint16_field, detail_uint16_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_uint16_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_int32_t", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "int32_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_int32_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_int32_field; + MemberId member_id_int32_field = 0x00000004; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_int32_field = TypeObjectUtils::build_common_struct_member(member_id_int32_field, member_flags_int32_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_int32_field = TypeObjectUtils::build_common_struct_member(member_id_int32_field, member_flags_int32_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure int32_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_int32_field = "int32_field"; + eprosima::fastcdr::optional member_ann_builtin_int32_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_int32_field = TypeObjectUtils::build_complete_member_detail(name_int32_field, member_ann_builtin_int32_field, ann_custom_StructType); + CompleteStructMember member_int32_field = TypeObjectUtils::build_complete_struct_member(common_int32_field, detail_int32_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_int32_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_uint32_t", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "uint32_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_uint32_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_uint32_field; + MemberId member_id_uint32_field = 0x00000005; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_uint32_field = TypeObjectUtils::build_common_struct_member(member_id_uint32_field, member_flags_uint32_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_uint32_field = TypeObjectUtils::build_common_struct_member(member_id_uint32_field, member_flags_uint32_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure uint32_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_uint32_field = "uint32_field"; + eprosima::fastcdr::optional member_ann_builtin_uint32_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_uint32_field = TypeObjectUtils::build_complete_member_detail(name_uint32_field, member_ann_builtin_uint32_field, ann_custom_StructType); + CompleteStructMember member_uint32_field = TypeObjectUtils::build_complete_struct_member(common_uint32_field, detail_uint32_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_uint32_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_int64_t", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "int64_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_int64_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_int64_field; + MemberId member_id_int64_field = 0x00000006; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_int64_field = TypeObjectUtils::build_common_struct_member(member_id_int64_field, member_flags_int64_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_int64_field = TypeObjectUtils::build_common_struct_member(member_id_int64_field, member_flags_int64_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure int64_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_int64_field = "int64_field"; + eprosima::fastcdr::optional member_ann_builtin_int64_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_int64_field = TypeObjectUtils::build_complete_member_detail(name_int64_field, member_ann_builtin_int64_field, ann_custom_StructType); + CompleteStructMember member_int64_field = TypeObjectUtils::build_complete_struct_member(common_int64_field, detail_int64_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_int64_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_uint64_t", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "uint64_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_uint64_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_uint64_field; + MemberId member_id_uint64_field = 0x00000007; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_uint64_field = TypeObjectUtils::build_common_struct_member(member_id_uint64_field, member_flags_uint64_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_uint64_field = TypeObjectUtils::build_common_struct_member(member_id_uint64_field, member_flags_uint64_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure uint64_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_uint64_field = "uint64_field"; + eprosima::fastcdr::optional member_ann_builtin_uint64_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_uint64_field = TypeObjectUtils::build_complete_member_detail(name_uint64_field, member_ann_builtin_uint64_field, ann_custom_StructType); + CompleteStructMember member_uint64_field = TypeObjectUtils::build_complete_struct_member(common_uint64_field, detail_uint64_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_uint64_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_float", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "float_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_float_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_float_field; + MemberId member_id_float_field = 0x00000008; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_float_field = TypeObjectUtils::build_common_struct_member(member_id_float_field, member_flags_float_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_float_field = TypeObjectUtils::build_common_struct_member(member_id_float_field, member_flags_float_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure float_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_float_field = "float_field"; + eprosima::fastcdr::optional member_ann_builtin_float_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_float_field = TypeObjectUtils::build_complete_member_detail(name_float_field, member_ann_builtin_float_field, ann_custom_StructType); + CompleteStructMember member_float_field = TypeObjectUtils::build_complete_struct_member(common_float_field, detail_float_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_float_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_double", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "double_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_double_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_double_field; + MemberId member_id_double_field = 0x00000009; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_double_field = TypeObjectUtils::build_common_struct_member(member_id_double_field, member_flags_double_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_double_field = TypeObjectUtils::build_common_struct_member(member_id_double_field, member_flags_double_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure double_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_double_field = "double_field"; + eprosima::fastcdr::optional member_ann_builtin_double_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_double_field = TypeObjectUtils::build_complete_member_detail(name_double_field, member_ann_builtin_double_field, ann_custom_StructType); + CompleteStructMember member_double_field = TypeObjectUtils::build_complete_struct_member(common_double_field, detail_double_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_double_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_longdouble", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "long_double_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_long_double_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_long_double_field; + MemberId member_id_long_double_field = 0x0000000a; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_long_double_field = TypeObjectUtils::build_common_struct_member(member_id_long_double_field, member_flags_long_double_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_long_double_field = TypeObjectUtils::build_common_struct_member(member_id_long_double_field, member_flags_long_double_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure long_double_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_long_double_field = "long_double_field"; + eprosima::fastcdr::optional member_ann_builtin_long_double_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_long_double_field = TypeObjectUtils::build_complete_member_detail(name_long_double_field, member_ann_builtin_long_double_field, ann_custom_StructType); + CompleteStructMember member_long_double_field = TypeObjectUtils::build_complete_struct_member(common_long_double_field, detail_long_double_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_long_double_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_bool", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "bool_field Structure member TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + StructMemberFlag member_flags_bool_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_bool_field; + MemberId member_id_bool_field = 0x0000000b; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_bool_field = TypeObjectUtils::build_common_struct_member(member_id_bool_field, member_flags_bool_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_bool_field = TypeObjectUtils::build_common_struct_member(member_id_bool_field, member_flags_bool_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure bool_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_bool_field = "bool_field"; + eprosima::fastcdr::optional member_ann_builtin_bool_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_bool_field = TypeObjectUtils::build_complete_member_detail(name_bool_field, member_ann_builtin_bool_field, ann_custom_StructType); + CompleteStructMember member_bool_field = TypeObjectUtils::build_complete_struct_member(common_bool_field, detail_bool_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_bool_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_string_unbounded", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + std::string type_id_kind_anonymous_string_unbounded("TI_STRING8_SMALL"); + if (type_id_kind_anonymous_string_unbounded == "TI_STRING8_SMALL") + { + SBound bound = 0; + StringSTypeDefn string_sdefn = TypeObjectUtils::build_string_s_type_defn(bound); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_string_type_identifier(string_sdefn, + "anonymous_string_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else if (type_id_kind_anonymous_string_unbounded == "TI_STRING8_LARGE") + { + LBound bound = 255; + StringLTypeDefn string_ldefn = TypeObjectUtils::build_string_l_type_defn(bound); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_string_type_identifier(string_ldefn, + "anonymous_string_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded: Unknown String kind."); + return; + } + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_string_unbounded", type_ids_StructType); + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_unbounded: Given String TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_string_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_string_field; + MemberId member_id_string_field = 0x0000000c; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_string_field = TypeObjectUtils::build_common_struct_member(member_id_string_field, member_flags_string_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_string_field = TypeObjectUtils::build_common_struct_member(member_id_string_field, member_flags_string_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure string_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_string_field = "string_field"; + eprosima::fastcdr::optional member_ann_builtin_string_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_string_field = TypeObjectUtils::build_complete_member_detail(name_string_field, member_ann_builtin_string_field, ann_custom_StructType); + CompleteStructMember member_string_field = TypeObjectUtils::build_complete_struct_member(common_string_field, detail_string_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_string_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "Color", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EnumTypeFlag enum_flags_Color = 0; + BitBound bit_bound_Color = 32; + CommonEnumeratedHeader common_Color = TypeObjectUtils::build_common_enumerated_header(bit_bound_Color); + QualifiedTypeName type_name_Color = "Color"; + eprosima::fastcdr::optional type_ann_builtin_Color; + eprosima::fastcdr::optional ann_custom_Color; + CompleteTypeDetail detail_Color = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_Color, ann_custom_Color, type_name_Color.to_string()); + CompleteEnumeratedHeader header_Color = TypeObjectUtils::build_complete_enumerated_header(common_Color, detail_Color); + CompleteEnumeratedLiteralSeq literal_seq_Color; + { + EnumeratedLiteralFlag flags_RED = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_RED = TypeObjectUtils::build_common_enumerated_literal(0, flags_RED); + eprosima::fastcdr::optional member_ann_builtin_RED; + ann_custom_Color.reset(); + MemberName name_RED = "RED"; + CompleteMemberDetail detail_RED = TypeObjectUtils::build_complete_member_detail(name_RED, member_ann_builtin_RED, ann_custom_Color); + CompleteEnumeratedLiteral literal_RED = TypeObjectUtils::build_complete_enumerated_literal(common_RED, detail_RED); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Color, literal_RED); + } + { + EnumeratedLiteralFlag flags_GREEN = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_GREEN = TypeObjectUtils::build_common_enumerated_literal(1, flags_GREEN); + eprosima::fastcdr::optional member_ann_builtin_GREEN; + ann_custom_Color.reset(); + MemberName name_GREEN = "GREEN"; + CompleteMemberDetail detail_GREEN = TypeObjectUtils::build_complete_member_detail(name_GREEN, member_ann_builtin_GREEN, ann_custom_Color); + CompleteEnumeratedLiteral literal_GREEN = TypeObjectUtils::build_complete_enumerated_literal(common_GREEN, detail_GREEN); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Color, literal_GREEN); + } + { + EnumeratedLiteralFlag flags_BLUE = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_BLUE = TypeObjectUtils::build_common_enumerated_literal(2, flags_BLUE); + eprosima::fastcdr::optional member_ann_builtin_BLUE; + ann_custom_Color.reset(); + MemberName name_BLUE = "BLUE"; + CompleteMemberDetail detail_BLUE = TypeObjectUtils::build_complete_member_detail(name_BLUE, member_ann_builtin_BLUE, ann_custom_Color); + CompleteEnumeratedLiteral literal_BLUE = TypeObjectUtils::build_complete_enumerated_literal(common_BLUE, detail_BLUE); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Color, literal_BLUE); + } + { + EnumeratedLiteralFlag flags_YELLOW = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_YELLOW = TypeObjectUtils::build_common_enumerated_literal(3, flags_YELLOW); + eprosima::fastcdr::optional member_ann_builtin_YELLOW; + ann_custom_Color.reset(); + MemberName name_YELLOW = "YELLOW"; + CompleteMemberDetail detail_YELLOW = TypeObjectUtils::build_complete_member_detail(name_YELLOW, member_ann_builtin_YELLOW, ann_custom_Color); + CompleteEnumeratedLiteral literal_YELLOW = TypeObjectUtils::build_complete_enumerated_literal(common_YELLOW, detail_YELLOW); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Color, literal_YELLOW); + } + { + EnumeratedLiteralFlag flags_MAGENTA = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_MAGENTA = TypeObjectUtils::build_common_enumerated_literal(4, flags_MAGENTA); + eprosima::fastcdr::optional member_ann_builtin_MAGENTA; + ann_custom_Color.reset(); + MemberName name_MAGENTA = "MAGENTA"; + CompleteMemberDetail detail_MAGENTA = TypeObjectUtils::build_complete_member_detail(name_MAGENTA, member_ann_builtin_MAGENTA, ann_custom_Color); + CompleteEnumeratedLiteral literal_MAGENTA = TypeObjectUtils::build_complete_enumerated_literal(common_MAGENTA, detail_MAGENTA); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Color, literal_MAGENTA); + } + CompleteEnumeratedType enumerated_type_Color = TypeObjectUtils::build_complete_enumerated_type(enum_flags_Color, header_Color, + literal_seq_Color); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_enumerated_type_object(enumerated_type_Color, type_name_Color.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Color already registered in TypeObjectRegistry for a different type."); + } + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "Color", type_ids_StructType); + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Color: Given Enum TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_enum_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_enum_field; + MemberId member_id_enum_field = 0x0000000d; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_enum_field = TypeObjectUtils::build_common_struct_member(member_id_enum_field, member_flags_enum_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_enum_field = TypeObjectUtils::build_common_struct_member(member_id_enum_field, member_flags_enum_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure enum_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_enum_field = "enum_field"; + eprosima::fastcdr::optional member_ann_builtin_enum_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_enum_field = TypeObjectUtils::build_complete_member_detail(name_enum_field, member_ann_builtin_enum_field, ann_custom_StructType); + CompleteStructMember member_enum_field = TypeObjectUtils::build_complete_struct_member(common_enum_field, detail_enum_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_enum_field); + } + { + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "Material", type_ids_StructType); + + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EnumTypeFlag enum_flags_Material = 0; + BitBound bit_bound_Material = 32; + CommonEnumeratedHeader common_Material = TypeObjectUtils::build_common_enumerated_header(bit_bound_Material); + QualifiedTypeName type_name_Material = "Material"; + eprosima::fastcdr::optional type_ann_builtin_Material; + eprosima::fastcdr::optional ann_custom_Material; + CompleteTypeDetail detail_Material = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_Material, ann_custom_Material, type_name_Material.to_string()); + CompleteEnumeratedHeader header_Material = TypeObjectUtils::build_complete_enumerated_header(common_Material, detail_Material); + CompleteEnumeratedLiteralSeq literal_seq_Material; + { + EnumeratedLiteralFlag flags_WOOD = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_WOOD = TypeObjectUtils::build_common_enumerated_literal(0, flags_WOOD); + eprosima::fastcdr::optional member_ann_builtin_WOOD; + ann_custom_Material.reset(); + MemberName name_WOOD = "WOOD"; + CompleteMemberDetail detail_WOOD = TypeObjectUtils::build_complete_member_detail(name_WOOD, member_ann_builtin_WOOD, ann_custom_Material); + CompleteEnumeratedLiteral literal_WOOD = TypeObjectUtils::build_complete_enumerated_literal(common_WOOD, detail_WOOD); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Material, literal_WOOD); + } + { + EnumeratedLiteralFlag flags_PLASTIC = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_PLASTIC = TypeObjectUtils::build_common_enumerated_literal(1, flags_PLASTIC); + eprosima::fastcdr::optional member_ann_builtin_PLASTIC; + ann_custom_Material.reset(); + MemberName name_PLASTIC = "PLASTIC"; + CompleteMemberDetail detail_PLASTIC = TypeObjectUtils::build_complete_member_detail(name_PLASTIC, member_ann_builtin_PLASTIC, ann_custom_Material); + CompleteEnumeratedLiteral literal_PLASTIC = TypeObjectUtils::build_complete_enumerated_literal(common_PLASTIC, detail_PLASTIC); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Material, literal_PLASTIC); + } + { + EnumeratedLiteralFlag flags_METAL = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_METAL = TypeObjectUtils::build_common_enumerated_literal(2, flags_METAL); + eprosima::fastcdr::optional member_ann_builtin_METAL; + ann_custom_Material.reset(); + MemberName name_METAL = "METAL"; + CompleteMemberDetail detail_METAL = TypeObjectUtils::build_complete_member_detail(name_METAL, member_ann_builtin_METAL, ann_custom_Material); + CompleteEnumeratedLiteral literal_METAL = TypeObjectUtils::build_complete_enumerated_literal(common_METAL, detail_METAL); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Material, literal_METAL); + } + { + EnumeratedLiteralFlag flags_CONCRETE = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_CONCRETE = TypeObjectUtils::build_common_enumerated_literal(3, flags_CONCRETE); + eprosima::fastcdr::optional member_ann_builtin_CONCRETE; + ann_custom_Material.reset(); + MemberName name_CONCRETE = "CONCRETE"; + CompleteMemberDetail detail_CONCRETE = TypeObjectUtils::build_complete_member_detail(name_CONCRETE, member_ann_builtin_CONCRETE, ann_custom_Material); + CompleteEnumeratedLiteral literal_CONCRETE = TypeObjectUtils::build_complete_enumerated_literal(common_CONCRETE, detail_CONCRETE); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Material, literal_CONCRETE); + } + { + EnumeratedLiteralFlag flags_STONE = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral common_STONE = TypeObjectUtils::build_common_enumerated_literal(4, flags_STONE); + eprosima::fastcdr::optional member_ann_builtin_STONE; + ann_custom_Material.reset(); + MemberName name_STONE = "STONE"; + CompleteMemberDetail detail_STONE = TypeObjectUtils::build_complete_member_detail(name_STONE, member_ann_builtin_STONE, ann_custom_Material); + CompleteEnumeratedLiteral literal_STONE = TypeObjectUtils::build_complete_enumerated_literal(common_STONE, detail_STONE); + TypeObjectUtils::add_complete_enumerated_literal(literal_seq_Material, literal_STONE); + } + CompleteEnumeratedType enumerated_type_Material = TypeObjectUtils::build_complete_enumerated_type(enum_flags_Material, header_Material, + literal_seq_Material); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_enumerated_type_object(enumerated_type_Material, type_name_Material.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Material already registered in TypeObjectRegistry for a different type."); + } + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "Material", type_ids_StructType); + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Material: Given Enum TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_enum2_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_enum2_field; + MemberId member_id_enum2_field = 0x0000000e; + if (EK_COMPLETE == type_ids_StructType.type_identifier1()._d() || TK_NONE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier1()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_enum2_field = TypeObjectUtils::build_common_struct_member(member_id_enum2_field, member_flags_enum2_field, type_ids_StructType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_StructType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_StructType.type_identifier2()._d() && + EK_COMPLETE == type_ids_StructType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_StructType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_StructType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_enum2_field = TypeObjectUtils::build_common_struct_member(member_id_enum2_field, member_flags_enum2_field, type_ids_StructType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure enum2_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_enum2_field = "enum2_field"; + eprosima::fastcdr::optional member_ann_builtin_enum2_field; + ann_custom_StructType.reset(); + CompleteMemberDetail detail_enum2_field = TypeObjectUtils::build_complete_member_detail(name_enum2_field, member_ann_builtin_enum2_field, ann_custom_StructType); + CompleteStructMember member_enum2_field = TypeObjectUtils::build_complete_struct_member(common_enum2_field, detail_enum2_field); + TypeObjectUtils::add_complete_struct_member(member_seq_StructType, member_enum2_field); + } + CompleteStructType struct_type_StructType = TypeObjectUtils::build_complete_struct_type(struct_flags_StructType, header_StructType, member_seq_StructType); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_struct_type_object(struct_type_StructType, type_name_StructType.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "StructType already registered in TypeObjectRegistry for a different type."); + } + return_code_StructType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "StructType", type_ids_StructType); + if (return_code_StructType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "StructType: Given Struct TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + } + TypeIdentifier* element_identifier_anonymous_sequence_StructType_unbounded {nullptr}; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_StructType_unbounded = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + element_identifier_anonymous_sequence_StructType_unbounded = new TypeIdentifier(type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Sequence element TypeIdentifier inconsistent."); + return; + } + EquivalenceKind equiv_kind_anonymous_sequence_StructType_unbounded = EK_COMPLETE; + if (TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d()) + { + equiv_kind_anonymous_sequence_StructType_unbounded = EK_BOTH; + } + CollectionElementFlag element_flags_anonymous_sequence_StructType_unbounded = 0; + PlainCollectionHeader header_anonymous_sequence_StructType_unbounded = TypeObjectUtils::build_plain_collection_header(equiv_kind_anonymous_sequence_StructType_unbounded, element_flags_anonymous_sequence_StructType_unbounded); + std::string type_id_kind_anonymous_sequence_StructType_unbounded("TI_PLAIN_SEQUENCE_SMALL"); + if (type_id_kind_anonymous_sequence_StructType_unbounded == "TI_PLAIN_SEQUENCE_SMALL") + { + SBound bound = 0; + PlainSequenceSElemDefn seq_sdefn = TypeObjectUtils::build_plain_sequence_s_elem_defn(header_anonymous_sequence_StructType_unbounded, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_StructType_unbounded)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_sequence_type_identifier(seq_sdefn, "anonymous_sequence_StructType_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_StructType_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + else + { + LBound bound = 0; + PlainSequenceLElemDefn seq_ldefn = TypeObjectUtils::build_plain_sequence_l_elem_defn(header_anonymous_sequence_StructType_unbounded, bound, + eprosima::fastcdr::external(element_identifier_anonymous_sequence_StructType_unbounded)); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_l_sequence_type_identifier(seq_ldefn, "anonymous_sequence_StructType_unbounded")) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_StructType_unbounded already registered in TypeObjectRegistry for a different type."); + } + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_sequence_StructType_unbounded", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_sequence_StructType_unbounded: Given Sequence TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } + StructMemberFlag member_flags_unbounded_sequence_struct_field = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::NOT_APPLIED, + false, false, false, false); + CommonStructMember common_unbounded_sequence_struct_field; + MemberId member_id_unbounded_sequence_struct_field = 0x0000003f; + if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1()._d() || TK_NONE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier1()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier1().map_ldefn().key_identifier()->_d()))) + { + common_unbounded_sequence_struct_field = TypeObjectUtils::build_common_struct_member(member_id_unbounded_sequence_struct_field, member_flags_unbounded_sequence_struct_field, type_ids_ContentFilterTestType.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2()._d() || + (TI_PLAIN_SEQUENCE_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_sdefn().header().equiv_kind()) || + (TI_PLAIN_SEQUENCE_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().seq_ldefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_sdefn().header().equiv_kind()) || + (TI_PLAIN_ARRAY_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().array_ldefn().header().equiv_kind()) || + (TI_PLAIN_MAP_SMALL == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_sdefn().key_identifier()->_d())) || + (TI_PLAIN_MAP_LARGE == type_ids_ContentFilterTestType.type_identifier2()._d() && + (EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().header().equiv_kind() || + EK_COMPLETE == type_ids_ContentFilterTestType.type_identifier2().map_ldefn().key_identifier()->_d()))) + { + common_unbounded_sequence_struct_field = TypeObjectUtils::build_common_struct_member(member_id_unbounded_sequence_struct_field, member_flags_unbounded_sequence_struct_field, type_ids_ContentFilterTestType.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Structure unbounded_sequence_struct_field member TypeIdentifier inconsistent."); + return; + } + MemberName name_unbounded_sequence_struct_field = "unbounded_sequence_struct_field"; + eprosima::fastcdr::optional member_ann_builtin_unbounded_sequence_struct_field; + ann_custom_ContentFilterTestType.reset(); + CompleteMemberDetail detail_unbounded_sequence_struct_field = TypeObjectUtils::build_complete_member_detail(name_unbounded_sequence_struct_field, member_ann_builtin_unbounded_sequence_struct_field, ann_custom_ContentFilterTestType); + CompleteStructMember member_unbounded_sequence_struct_field = TypeObjectUtils::build_complete_struct_member(common_unbounded_sequence_struct_field, detail_unbounded_sequence_struct_field); + TypeObjectUtils::add_complete_struct_member(member_seq_ContentFilterTestType, member_unbounded_sequence_struct_field); + } + CompleteStructType struct_type_ContentFilterTestType = TypeObjectUtils::build_complete_struct_type(struct_flags_ContentFilterTestType, header_ContentFilterTestType, member_seq_ContentFilterTestType); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_struct_type_object(struct_type_ContentFilterTestType, type_name_ContentFilterTestType.to_string())) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "ContentFilterTestType already registered in TypeObjectRegistry for a different type."); + } + return_code_ContentFilterTestType = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "ContentFilterTestType", type_ids_ContentFilterTestType); + if (return_code_ContentFilterTestType != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "ContentFilterTestType: Given Struct TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + } +} + diff --git a/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypeTypeObjectSupport.hpp b/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypeTypeObjectSupport.hpp new file mode 100644 index 00000000000..607d693ecc7 --- /dev/null +++ b/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypeTypeObjectSupport.hpp @@ -0,0 +1,61 @@ +// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! + * @file ContentFilterTestTypeTypeObjectSupport.hpp + * Header file containing the API required to register the TypeObject representation of the described types in the IDL file + * + * This file was generated by the tool fastddsgen. + */ + +#ifndef _FAST_DDS_GENERATED_CONTENTFILTERTESTTYPE_TYPE_OBJECT_SUPPORT_HPP_ +#define _FAST_DDS_GENERATED_CONTENTFILTERTESTTYPE_TYPE_OBJECT_SUPPORT_HPP_ + + +#if defined(_WIN32) +#if defined(EPROSIMA_USER_DLL_EXPORT) +#define eProsima_user_DllExport __declspec( dllexport ) +#else +#define eProsima_user_DllExport +#endif // EPROSIMA_USER_DLL_EXPORT +#else +#define eProsima_user_DllExport +#endif // _WIN32 + +/** + * @brief Register every TypeObject representation defined in the IDL file in Fast DDS TypeObjectRegistry. + */ +eProsima_user_DllExport void register_ContentFilterTestType_type_objects(); + +#ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +/** + * @brief Register StructType related TypeIdentifier. + * Fully-descriptive TypeIdentifiers are directly registered. + * Hash TypeIdentifiers require to fill the TypeObject information and hash it, consequently, the TypeObject is + * indirectly registered as well. + */ +void register_StructType_type_identifier(); +/** + * @brief Register ContentFilterTestType related TypeIdentifier. + * Fully-descriptive TypeIdentifiers are directly registered. + * Hash TypeIdentifiers require to fill the TypeObject information and hash it, consequently, the TypeObject is + * indirectly registered as well. + */ +void register_ContentFilterTestType_type_identifier(); + + +#endif // DOXYGEN_SHOULD_SKIP_THIS_PUBLIC + +#endif // _FAST_DDS_GENERATED_CONTENTFILTERTESTTYPE_TYPE_OBJECT_SUPPORT_HPP_ diff --git a/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypev1.cxx b/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypev1.cxx deleted file mode 100644 index 6b2d8da6280..00000000000 --- a/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypev1.cxx +++ /dev/null @@ -1,5318 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file ContentFilterTestType.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "ContentFilterTestType.h" - -#if FASTCDR_VERSION_MAJOR == 1 - -#include "ContentFilterTestTypeTypeObject.h" - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - -namespace helper { namespace internal { - -enum class Size { - UInt8, - UInt16, - UInt32, - UInt64, -}; - -constexpr Size get_size(int s) { - return (s <= 8 ) ? Size::UInt8: - (s <= 16) ? Size::UInt16: - (s <= 32) ? Size::UInt32: Size::UInt64; -} - -template -struct FindTypeH; - -template<> -struct FindTypeH { - using type = std::uint8_t; -}; - -template<> -struct FindTypeH { - using type = std::uint16_t; -}; - -template<> -struct FindTypeH { - using type = std::uint32_t; -}; - -template<> -struct FindTypeH { - using type = std::uint64_t; -}; -} - -template -struct FindType { - using type = typename internal::FindTypeH::type; -}; -} - -#define StructType_max_cdr_typesize 344ULL; -#define ContentFilterTestType_max_cdr_typesize 73360ULL; - - - - - - -StructType::StructType() -{ - // char m_char_field - m_char_field = 0; - // octet m_uint8_field - m_uint8_field = 0; - // short m_int16_field - m_int16_field = 0; - // unsigned short m_uint16_field - m_uint16_field = 0; - // long m_int32_field - m_int32_field = 0; - // unsigned long m_uint32_field - m_uint32_field = 0; - // long long m_int64_field - m_int64_field = 0; - // unsigned long long m_uint64_field - m_uint64_field = 0; - // float m_float_field - m_float_field = 0.0; - // double m_double_field - m_double_field = 0.0; - // long double m_long_double_field - m_long_double_field = 0.0; - // boolean m_bool_field - m_bool_field = false; - // /type_d() m_string_field - - // Color m_enum_field - m_enum_field = ::RED; - // Material m_enum2_field - m_enum2_field = ::WOOD; - - // Just to register all known types - registerContentFilterTestTypeTypes(); -} - -StructType::~StructType() -{ -} - -StructType::StructType( - const StructType& x) -{ - m_char_field = x.m_char_field; - - - m_uint8_field = x.m_uint8_field; - - - m_int16_field = x.m_int16_field; - - - m_uint16_field = x.m_uint16_field; - - - m_int32_field = x.m_int32_field; - - - m_uint32_field = x.m_uint32_field; - - - m_int64_field = x.m_int64_field; - - - m_uint64_field = x.m_uint64_field; - - - m_float_field = x.m_float_field; - - - m_double_field = x.m_double_field; - - - m_long_double_field = x.m_long_double_field; - - - m_bool_field = x.m_bool_field; - - - m_string_field = x.m_string_field; - - - m_enum_field = x.m_enum_field; - - - m_enum2_field = x.m_enum2_field; - -} - -StructType::StructType( - StructType&& x) noexcept -{ - m_char_field = x.m_char_field; - - - m_uint8_field = x.m_uint8_field; - - - m_int16_field = x.m_int16_field; - - - m_uint16_field = x.m_uint16_field; - - - m_int32_field = x.m_int32_field; - - - m_uint32_field = x.m_uint32_field; - - - m_int64_field = x.m_int64_field; - - - m_uint64_field = x.m_uint64_field; - - - m_float_field = x.m_float_field; - - - m_double_field = x.m_double_field; - - - m_long_double_field = x.m_long_double_field; - - - m_bool_field = x.m_bool_field; - - - m_string_field = std::move(x.m_string_field); - - - m_enum_field = x.m_enum_field; - - - m_enum2_field = x.m_enum2_field; - -} - -StructType& StructType::operator =( - const StructType& x) -{ - m_char_field = x.m_char_field; - - - m_uint8_field = x.m_uint8_field; - - - m_int16_field = x.m_int16_field; - - - m_uint16_field = x.m_uint16_field; - - - m_int32_field = x.m_int32_field; - - - m_uint32_field = x.m_uint32_field; - - - m_int64_field = x.m_int64_field; - - - m_uint64_field = x.m_uint64_field; - - - m_float_field = x.m_float_field; - - - m_double_field = x.m_double_field; - - - m_long_double_field = x.m_long_double_field; - - - m_bool_field = x.m_bool_field; - - - m_string_field = x.m_string_field; - - - m_enum_field = x.m_enum_field; - - - m_enum2_field = x.m_enum2_field; - - return *this; -} - -StructType& StructType::operator =( - StructType&& x) noexcept -{ - m_char_field = x.m_char_field; - - - m_uint8_field = x.m_uint8_field; - - - m_int16_field = x.m_int16_field; - - - m_uint16_field = x.m_uint16_field; - - - m_int32_field = x.m_int32_field; - - - m_uint32_field = x.m_uint32_field; - - - m_int64_field = x.m_int64_field; - - - m_uint64_field = x.m_uint64_field; - - - m_float_field = x.m_float_field; - - - m_double_field = x.m_double_field; - - - m_long_double_field = x.m_long_double_field; - - - m_bool_field = x.m_bool_field; - - - m_string_field = std::move(x.m_string_field); - - - m_enum_field = x.m_enum_field; - - - m_enum2_field = x.m_enum2_field; - - return *this; -} - -bool StructType::operator ==( - const StructType& x) const -{ - return (m_char_field == x.m_char_field && - m_uint8_field == x.m_uint8_field && - m_int16_field == x.m_int16_field && - m_uint16_field == x.m_uint16_field && - m_int32_field == x.m_int32_field && - m_uint32_field == x.m_uint32_field && - m_int64_field == x.m_int64_field && - m_uint64_field == x.m_uint64_field && - m_float_field == x.m_float_field && - m_double_field == x.m_double_field && - m_long_double_field == x.m_long_double_field && - m_bool_field == x.m_bool_field && - m_string_field == x.m_string_field && - m_enum_field == x.m_enum_field && - m_enum2_field == x.m_enum2_field); -} - -bool StructType::operator !=( - const StructType& x) const -{ - return !(*this == x); -} - -size_t StructType::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return StructType_max_cdr_typesize; -} - -size_t StructType::getCdrSerializedSize( - const StructType& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - current_alignment += 2 + eprosima::fastcdr::Cdr::alignment(current_alignment, 2); - - - current_alignment += 2 + eprosima::fastcdr::Cdr::alignment(current_alignment, 2); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += 8 + eprosima::fastcdr::Cdr::alignment(current_alignment, 8); - - - current_alignment += 8 + eprosima::fastcdr::Cdr::alignment(current_alignment, 8); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += 8 + eprosima::fastcdr::Cdr::alignment(current_alignment, 8); - - - current_alignment += 16 + eprosima::fastcdr::Cdr::alignment(current_alignment, 8); // 128 bits, but aligned as 64 - - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + data.string_field().size() + 1; - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - return current_alignment - initial_alignment; -} - - -void StructType::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_char_field; - - scdr << m_uint8_field; - - scdr << m_int16_field; - - scdr << m_uint16_field; - - scdr << m_int32_field; - - scdr << m_uint32_field; - - scdr << m_int64_field; - - scdr << m_uint64_field; - - scdr << m_float_field; - - scdr << m_double_field; - - scdr << m_long_double_field; - - scdr << m_bool_field; - - scdr << m_string_field.c_str(); - - scdr << (uint32_t)m_enum_field; - - scdr << (uint32_t)m_enum2_field; - -} - -void StructType::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_char_field; - - - - dcdr >> m_uint8_field; - - - - dcdr >> m_int16_field; - - - - dcdr >> m_uint16_field; - - - - dcdr >> m_int32_field; - - - - dcdr >> m_uint32_field; - - - - dcdr >> m_int64_field; - - - - dcdr >> m_uint64_field; - - - - dcdr >> m_float_field; - - - - dcdr >> m_double_field; - - - - dcdr >> m_long_double_field; - - - - dcdr >> m_bool_field; - - - - dcdr >> m_string_field; - - - - { - uint32_t enum_value = 0; - dcdr >> enum_value; - m_enum_field = (Color)enum_value; - } - - - - { - uint32_t enum_value = 0; - dcdr >> enum_value; - m_enum2_field = (Material)enum_value; - } - - -} - - -bool StructType::isKeyDefined() -{ - return false; -} - -void StructType::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member char_field - * @param _char_field New value for member char_field - */ -void StructType::char_field( - char _char_field) -{ - m_char_field = _char_field; -} - -/*! - * @brief This function returns the value of member char_field - * @return Value of member char_field - */ -char StructType::char_field() const -{ - return m_char_field; -} - -/*! - * @brief This function returns a reference to member char_field - * @return Reference to member char_field - */ -char& StructType::char_field() -{ - return m_char_field; -} - - -/*! - * @brief This function sets a value in member uint8_field - * @param _uint8_field New value for member uint8_field - */ -void StructType::uint8_field( - uint8_t _uint8_field) -{ - m_uint8_field = _uint8_field; -} - -/*! - * @brief This function returns the value of member uint8_field - * @return Value of member uint8_field - */ -uint8_t StructType::uint8_field() const -{ - return m_uint8_field; -} - -/*! - * @brief This function returns a reference to member uint8_field - * @return Reference to member uint8_field - */ -uint8_t& StructType::uint8_field() -{ - return m_uint8_field; -} - - -/*! - * @brief This function sets a value in member int16_field - * @param _int16_field New value for member int16_field - */ -void StructType::int16_field( - int16_t _int16_field) -{ - m_int16_field = _int16_field; -} - -/*! - * @brief This function returns the value of member int16_field - * @return Value of member int16_field - */ -int16_t StructType::int16_field() const -{ - return m_int16_field; -} - -/*! - * @brief This function returns a reference to member int16_field - * @return Reference to member int16_field - */ -int16_t& StructType::int16_field() -{ - return m_int16_field; -} - - -/*! - * @brief This function sets a value in member uint16_field - * @param _uint16_field New value for member uint16_field - */ -void StructType::uint16_field( - uint16_t _uint16_field) -{ - m_uint16_field = _uint16_field; -} - -/*! - * @brief This function returns the value of member uint16_field - * @return Value of member uint16_field - */ -uint16_t StructType::uint16_field() const -{ - return m_uint16_field; -} - -/*! - * @brief This function returns a reference to member uint16_field - * @return Reference to member uint16_field - */ -uint16_t& StructType::uint16_field() -{ - return m_uint16_field; -} - - -/*! - * @brief This function sets a value in member int32_field - * @param _int32_field New value for member int32_field - */ -void StructType::int32_field( - int32_t _int32_field) -{ - m_int32_field = _int32_field; -} - -/*! - * @brief This function returns the value of member int32_field - * @return Value of member int32_field - */ -int32_t StructType::int32_field() const -{ - return m_int32_field; -} - -/*! - * @brief This function returns a reference to member int32_field - * @return Reference to member int32_field - */ -int32_t& StructType::int32_field() -{ - return m_int32_field; -} - - -/*! - * @brief This function sets a value in member uint32_field - * @param _uint32_field New value for member uint32_field - */ -void StructType::uint32_field( - uint32_t _uint32_field) -{ - m_uint32_field = _uint32_field; -} - -/*! - * @brief This function returns the value of member uint32_field - * @return Value of member uint32_field - */ -uint32_t StructType::uint32_field() const -{ - return m_uint32_field; -} - -/*! - * @brief This function returns a reference to member uint32_field - * @return Reference to member uint32_field - */ -uint32_t& StructType::uint32_field() -{ - return m_uint32_field; -} - - -/*! - * @brief This function sets a value in member int64_field - * @param _int64_field New value for member int64_field - */ -void StructType::int64_field( - int64_t _int64_field) -{ - m_int64_field = _int64_field; -} - -/*! - * @brief This function returns the value of member int64_field - * @return Value of member int64_field - */ -int64_t StructType::int64_field() const -{ - return m_int64_field; -} - -/*! - * @brief This function returns a reference to member int64_field - * @return Reference to member int64_field - */ -int64_t& StructType::int64_field() -{ - return m_int64_field; -} - - -/*! - * @brief This function sets a value in member uint64_field - * @param _uint64_field New value for member uint64_field - */ -void StructType::uint64_field( - uint64_t _uint64_field) -{ - m_uint64_field = _uint64_field; -} - -/*! - * @brief This function returns the value of member uint64_field - * @return Value of member uint64_field - */ -uint64_t StructType::uint64_field() const -{ - return m_uint64_field; -} - -/*! - * @brief This function returns a reference to member uint64_field - * @return Reference to member uint64_field - */ -uint64_t& StructType::uint64_field() -{ - return m_uint64_field; -} - - -/*! - * @brief This function sets a value in member float_field - * @param _float_field New value for member float_field - */ -void StructType::float_field( - float _float_field) -{ - m_float_field = _float_field; -} - -/*! - * @brief This function returns the value of member float_field - * @return Value of member float_field - */ -float StructType::float_field() const -{ - return m_float_field; -} - -/*! - * @brief This function returns a reference to member float_field - * @return Reference to member float_field - */ -float& StructType::float_field() -{ - return m_float_field; -} - - -/*! - * @brief This function sets a value in member double_field - * @param _double_field New value for member double_field - */ -void StructType::double_field( - double _double_field) -{ - m_double_field = _double_field; -} - -/*! - * @brief This function returns the value of member double_field - * @return Value of member double_field - */ -double StructType::double_field() const -{ - return m_double_field; -} - -/*! - * @brief This function returns a reference to member double_field - * @return Reference to member double_field - */ -double& StructType::double_field() -{ - return m_double_field; -} - - -/*! - * @brief This function sets a value in member long_double_field - * @param _long_double_field New value for member long_double_field - */ -void StructType::long_double_field( - long double _long_double_field) -{ - m_long_double_field = _long_double_field; -} - -/*! - * @brief This function returns the value of member long_double_field - * @return Value of member long_double_field - */ -long double StructType::long_double_field() const -{ - return m_long_double_field; -} - -/*! - * @brief This function returns a reference to member long_double_field - * @return Reference to member long_double_field - */ -long double& StructType::long_double_field() -{ - return m_long_double_field; -} - - -/*! - * @brief This function sets a value in member bool_field - * @param _bool_field New value for member bool_field - */ -void StructType::bool_field( - bool _bool_field) -{ - m_bool_field = _bool_field; -} - -/*! - * @brief This function returns the value of member bool_field - * @return Value of member bool_field - */ -bool StructType::bool_field() const -{ - return m_bool_field; -} - -/*! - * @brief This function returns a reference to member bool_field - * @return Reference to member bool_field - */ -bool& StructType::bool_field() -{ - return m_bool_field; -} - - -/*! - * @brief This function copies the value in member string_field - * @param _string_field New value to be copied in member string_field - */ -void StructType::string_field( - const std::string& _string_field) -{ - m_string_field = _string_field; -} - -/*! - * @brief This function moves the value in member string_field - * @param _string_field New value to be moved in member string_field - */ -void StructType::string_field( - std::string&& _string_field) -{ - m_string_field = std::move(_string_field); -} - -/*! - * @brief This function returns a constant reference to member string_field - * @return Constant reference to member string_field - */ -const std::string& StructType::string_field() const -{ - return m_string_field; -} - -/*! - * @brief This function returns a reference to member string_field - * @return Reference to member string_field - */ -std::string& StructType::string_field() -{ - return m_string_field; -} - - -/*! - * @brief This function sets a value in member enum_field - * @param _enum_field New value for member enum_field - */ -void StructType::enum_field( - Color _enum_field) -{ - m_enum_field = _enum_field; -} - -/*! - * @brief This function returns the value of member enum_field - * @return Value of member enum_field - */ -Color StructType::enum_field() const -{ - return m_enum_field; -} - -/*! - * @brief This function returns a reference to member enum_field - * @return Reference to member enum_field - */ -Color& StructType::enum_field() -{ - return m_enum_field; -} - - -/*! - * @brief This function sets a value in member enum2_field - * @param _enum2_field New value for member enum2_field - */ -void StructType::enum2_field( - Material _enum2_field) -{ - m_enum2_field = _enum2_field; -} - -/*! - * @brief This function returns the value of member enum2_field - * @return Value of member enum2_field - */ -Material StructType::enum2_field() const -{ - return m_enum2_field; -} - -/*! - * @brief This function returns a reference to member enum2_field - * @return Reference to member enum2_field - */ -Material& StructType::enum2_field() -{ - return m_enum2_field; -} - - - - - - - - - -ContentFilterTestType::ContentFilterTestType() -{ - // char m_char_field - m_char_field = 0; - // octet m_uint8_field - m_uint8_field = 0; - // short m_int16_field - m_int16_field = 0; - // unsigned short m_uint16_field - m_uint16_field = 0; - // long m_int32_field - m_int32_field = 0; - // unsigned long m_uint32_field - m_uint32_field = 0; - // long long m_int64_field - m_int64_field = 0; - // unsigned long long m_uint64_field - m_uint64_field = 0; - // float m_float_field - m_float_field = 0.0; - // double m_double_field - m_double_field = 0.0; - // long double m_long_double_field - m_long_double_field = 0.0; - // boolean m_bool_field - m_bool_field = false; - // /type_d() m_string_field - - // Color m_enum_field - m_enum_field = ::RED; - // Material m_enum2_field - m_enum2_field = ::WOOD; - // StructType m_struct_field - - // char m_array_char_field - memset(&m_array_char_field, 0, ((max_array_size)) * 1); - // octet m_array_uint8_field - memset(&m_array_uint8_field, 0, ((max_array_size)) * 1); - // short m_array_int16_field - memset(&m_array_int16_field, 0, ((max_array_size)) * 2); - // unsigned short m_array_uint16_field - memset(&m_array_uint16_field, 0, ((max_array_size)) * 2); - // long m_array_int32_field - memset(&m_array_int32_field, 0, ((max_array_size)) * 4); - // unsigned long m_array_uint32_field - memset(&m_array_uint32_field, 0, ((max_array_size)) * 4); - // long long m_array_int64_field - memset(&m_array_int64_field, 0, ((max_array_size)) * 8); - // unsigned long long m_array_uint64_field - memset(&m_array_uint64_field, 0, ((max_array_size)) * 8); - // float m_array_float_field - memset(&m_array_float_field, 0, ((max_array_size)) * 4); - // double m_array_double_field - memset(&m_array_double_field, 0, ((max_array_size)) * 8); - // long double m_array_long_double_field - memset(&m_array_long_double_field, 0, ((max_array_size)) * 16); - // boolean m_array_bool_field - memset(&m_array_bool_field, 0, ((max_array_size)) * 1); - // /type_d() m_array_string_field - - // Color m_array_enum_field - memset(&m_array_enum_field, 0, ((max_array_size)) * 4); - // Material m_array_enum2_field - memset(&m_array_enum2_field, 0, ((max_array_size)) * 4); - // StructType m_array_struct_field - - // sequence m_bounded_sequence_char_field - - // sequence m_bounded_sequence_uint8_field - - // sequence m_bounded_sequence_int16_field - - // sequence m_bounded_sequence_uint16_field - - // sequence m_bounded_sequence_int32_field - - // sequence m_bounded_sequence_uint32_field - - // sequence m_bounded_sequence_int64_field - - // sequence m_bounded_sequence_uint64_field - - // sequence m_bounded_sequence_float_field - - // sequence m_bounded_sequence_double_field - - // sequence m_bounded_sequence_long_double_field - - // sequence m_bounded_sequence_bool_field - - // sequence m_bounded_sequence_string_field - - // sequence m_bounded_sequence_enum_field - - // sequence m_bounded_sequence_enum2_field - - // sequence m_bounded_sequence_struct_field - - // sequence m_unbounded_sequence_char_field - - // sequence m_unbounded_sequence_uint8_field - - // sequence m_unbounded_sequence_int16_field - - // sequence m_unbounded_sequence_uint16_field - - // sequence m_unbounded_sequence_int32_field - - // sequence m_unbounded_sequence_uint32_field - - // sequence m_unbounded_sequence_int64_field - - // sequence m_unbounded_sequence_uint64_field - - // sequence m_unbounded_sequence_float_field - - // sequence m_unbounded_sequence_double_field - - // sequence m_unbounded_sequence_long_double_field - - // sequence m_unbounded_sequence_bool_field - - // sequence m_unbounded_sequence_string_field - - // sequence m_unbounded_sequence_enum_field - - // sequence m_unbounded_sequence_enum2_field - - // sequence m_unbounded_sequence_struct_field - - - // Just to register all known types - registerContentFilterTestTypeTypes(); -} - -ContentFilterTestType::~ContentFilterTestType() -{ -} - -ContentFilterTestType::ContentFilterTestType( - const ContentFilterTestType& x) -{ - m_char_field = x.m_char_field; - - - m_uint8_field = x.m_uint8_field; - - - m_int16_field = x.m_int16_field; - - - m_uint16_field = x.m_uint16_field; - - - m_int32_field = x.m_int32_field; - - - m_uint32_field = x.m_uint32_field; - - - m_int64_field = x.m_int64_field; - - - m_uint64_field = x.m_uint64_field; - - - m_float_field = x.m_float_field; - - - m_double_field = x.m_double_field; - - - m_long_double_field = x.m_long_double_field; - - - m_bool_field = x.m_bool_field; - - - m_string_field = x.m_string_field; - - - m_enum_field = x.m_enum_field; - - - m_enum2_field = x.m_enum2_field; - - - m_struct_field = x.m_struct_field; - - - m_array_char_field = x.m_array_char_field; - - - m_array_uint8_field = x.m_array_uint8_field; - - - m_array_int16_field = x.m_array_int16_field; - - - m_array_uint16_field = x.m_array_uint16_field; - - - m_array_int32_field = x.m_array_int32_field; - - - m_array_uint32_field = x.m_array_uint32_field; - - - m_array_int64_field = x.m_array_int64_field; - - - m_array_uint64_field = x.m_array_uint64_field; - - - m_array_float_field = x.m_array_float_field; - - - m_array_double_field = x.m_array_double_field; - - - m_array_long_double_field = x.m_array_long_double_field; - - - m_array_bool_field = x.m_array_bool_field; - - - m_array_string_field = x.m_array_string_field; - - - m_array_enum_field = x.m_array_enum_field; - - - m_array_enum2_field = x.m_array_enum2_field; - - - m_array_struct_field = x.m_array_struct_field; - - - m_bounded_sequence_char_field = x.m_bounded_sequence_char_field; - - - m_bounded_sequence_uint8_field = x.m_bounded_sequence_uint8_field; - - - m_bounded_sequence_int16_field = x.m_bounded_sequence_int16_field; - - - m_bounded_sequence_uint16_field = x.m_bounded_sequence_uint16_field; - - - m_bounded_sequence_int32_field = x.m_bounded_sequence_int32_field; - - - m_bounded_sequence_uint32_field = x.m_bounded_sequence_uint32_field; - - - m_bounded_sequence_int64_field = x.m_bounded_sequence_int64_field; - - - m_bounded_sequence_uint64_field = x.m_bounded_sequence_uint64_field; - - - m_bounded_sequence_float_field = x.m_bounded_sequence_float_field; - - - m_bounded_sequence_double_field = x.m_bounded_sequence_double_field; - - - m_bounded_sequence_long_double_field = x.m_bounded_sequence_long_double_field; - - - m_bounded_sequence_bool_field = x.m_bounded_sequence_bool_field; - - - m_bounded_sequence_string_field = x.m_bounded_sequence_string_field; - - - m_bounded_sequence_enum_field = x.m_bounded_sequence_enum_field; - - - m_bounded_sequence_enum2_field = x.m_bounded_sequence_enum2_field; - - - m_bounded_sequence_struct_field = x.m_bounded_sequence_struct_field; - - - m_unbounded_sequence_char_field = x.m_unbounded_sequence_char_field; - - - m_unbounded_sequence_uint8_field = x.m_unbounded_sequence_uint8_field; - - - m_unbounded_sequence_int16_field = x.m_unbounded_sequence_int16_field; - - - m_unbounded_sequence_uint16_field = x.m_unbounded_sequence_uint16_field; - - - m_unbounded_sequence_int32_field = x.m_unbounded_sequence_int32_field; - - - m_unbounded_sequence_uint32_field = x.m_unbounded_sequence_uint32_field; - - - m_unbounded_sequence_int64_field = x.m_unbounded_sequence_int64_field; - - - m_unbounded_sequence_uint64_field = x.m_unbounded_sequence_uint64_field; - - - m_unbounded_sequence_float_field = x.m_unbounded_sequence_float_field; - - - m_unbounded_sequence_double_field = x.m_unbounded_sequence_double_field; - - - m_unbounded_sequence_long_double_field = x.m_unbounded_sequence_long_double_field; - - - m_unbounded_sequence_bool_field = x.m_unbounded_sequence_bool_field; - - - m_unbounded_sequence_string_field = x.m_unbounded_sequence_string_field; - - - m_unbounded_sequence_enum_field = x.m_unbounded_sequence_enum_field; - - - m_unbounded_sequence_enum2_field = x.m_unbounded_sequence_enum2_field; - - - m_unbounded_sequence_struct_field = x.m_unbounded_sequence_struct_field; - -} - -ContentFilterTestType::ContentFilterTestType( - ContentFilterTestType&& x) noexcept -{ - m_char_field = x.m_char_field; - - - m_uint8_field = x.m_uint8_field; - - - m_int16_field = x.m_int16_field; - - - m_uint16_field = x.m_uint16_field; - - - m_int32_field = x.m_int32_field; - - - m_uint32_field = x.m_uint32_field; - - - m_int64_field = x.m_int64_field; - - - m_uint64_field = x.m_uint64_field; - - - m_float_field = x.m_float_field; - - - m_double_field = x.m_double_field; - - - m_long_double_field = x.m_long_double_field; - - - m_bool_field = x.m_bool_field; - - - m_string_field = std::move(x.m_string_field); - - - m_enum_field = x.m_enum_field; - - - m_enum2_field = x.m_enum2_field; - - - m_struct_field = std::move(x.m_struct_field); - - - m_array_char_field = std::move(x.m_array_char_field); - - - m_array_uint8_field = std::move(x.m_array_uint8_field); - - - m_array_int16_field = std::move(x.m_array_int16_field); - - - m_array_uint16_field = std::move(x.m_array_uint16_field); - - - m_array_int32_field = std::move(x.m_array_int32_field); - - - m_array_uint32_field = std::move(x.m_array_uint32_field); - - - m_array_int64_field = std::move(x.m_array_int64_field); - - - m_array_uint64_field = std::move(x.m_array_uint64_field); - - - m_array_float_field = std::move(x.m_array_float_field); - - - m_array_double_field = std::move(x.m_array_double_field); - - - m_array_long_double_field = std::move(x.m_array_long_double_field); - - - m_array_bool_field = std::move(x.m_array_bool_field); - - - m_array_string_field = std::move(x.m_array_string_field); - - - m_array_enum_field = std::move(x.m_array_enum_field); - - - m_array_enum2_field = std::move(x.m_array_enum2_field); - - - m_array_struct_field = std::move(x.m_array_struct_field); - - - m_bounded_sequence_char_field = std::move(x.m_bounded_sequence_char_field); - - - m_bounded_sequence_uint8_field = std::move(x.m_bounded_sequence_uint8_field); - - - m_bounded_sequence_int16_field = std::move(x.m_bounded_sequence_int16_field); - - - m_bounded_sequence_uint16_field = std::move(x.m_bounded_sequence_uint16_field); - - - m_bounded_sequence_int32_field = std::move(x.m_bounded_sequence_int32_field); - - - m_bounded_sequence_uint32_field = std::move(x.m_bounded_sequence_uint32_field); - - - m_bounded_sequence_int64_field = std::move(x.m_bounded_sequence_int64_field); - - - m_bounded_sequence_uint64_field = std::move(x.m_bounded_sequence_uint64_field); - - - m_bounded_sequence_float_field = std::move(x.m_bounded_sequence_float_field); - - - m_bounded_sequence_double_field = std::move(x.m_bounded_sequence_double_field); - - - m_bounded_sequence_long_double_field = std::move(x.m_bounded_sequence_long_double_field); - - - m_bounded_sequence_bool_field = std::move(x.m_bounded_sequence_bool_field); - - - m_bounded_sequence_string_field = std::move(x.m_bounded_sequence_string_field); - - - m_bounded_sequence_enum_field = std::move(x.m_bounded_sequence_enum_field); - - - m_bounded_sequence_enum2_field = std::move(x.m_bounded_sequence_enum2_field); - - - m_bounded_sequence_struct_field = std::move(x.m_bounded_sequence_struct_field); - - - m_unbounded_sequence_char_field = std::move(x.m_unbounded_sequence_char_field); - - - m_unbounded_sequence_uint8_field = std::move(x.m_unbounded_sequence_uint8_field); - - - m_unbounded_sequence_int16_field = std::move(x.m_unbounded_sequence_int16_field); - - - m_unbounded_sequence_uint16_field = std::move(x.m_unbounded_sequence_uint16_field); - - - m_unbounded_sequence_int32_field = std::move(x.m_unbounded_sequence_int32_field); - - - m_unbounded_sequence_uint32_field = std::move(x.m_unbounded_sequence_uint32_field); - - - m_unbounded_sequence_int64_field = std::move(x.m_unbounded_sequence_int64_field); - - - m_unbounded_sequence_uint64_field = std::move(x.m_unbounded_sequence_uint64_field); - - - m_unbounded_sequence_float_field = std::move(x.m_unbounded_sequence_float_field); - - - m_unbounded_sequence_double_field = std::move(x.m_unbounded_sequence_double_field); - - - m_unbounded_sequence_long_double_field = std::move(x.m_unbounded_sequence_long_double_field); - - - m_unbounded_sequence_bool_field = std::move(x.m_unbounded_sequence_bool_field); - - - m_unbounded_sequence_string_field = std::move(x.m_unbounded_sequence_string_field); - - - m_unbounded_sequence_enum_field = std::move(x.m_unbounded_sequence_enum_field); - - - m_unbounded_sequence_enum2_field = std::move(x.m_unbounded_sequence_enum2_field); - - - m_unbounded_sequence_struct_field = std::move(x.m_unbounded_sequence_struct_field); - -} - -ContentFilterTestType& ContentFilterTestType::operator =( - const ContentFilterTestType& x) -{ - m_char_field = x.m_char_field; - - - m_uint8_field = x.m_uint8_field; - - - m_int16_field = x.m_int16_field; - - - m_uint16_field = x.m_uint16_field; - - - m_int32_field = x.m_int32_field; - - - m_uint32_field = x.m_uint32_field; - - - m_int64_field = x.m_int64_field; - - - m_uint64_field = x.m_uint64_field; - - - m_float_field = x.m_float_field; - - - m_double_field = x.m_double_field; - - - m_long_double_field = x.m_long_double_field; - - - m_bool_field = x.m_bool_field; - - - m_string_field = x.m_string_field; - - - m_enum_field = x.m_enum_field; - - - m_enum2_field = x.m_enum2_field; - - - m_struct_field = x.m_struct_field; - - - m_array_char_field = x.m_array_char_field; - - - m_array_uint8_field = x.m_array_uint8_field; - - - m_array_int16_field = x.m_array_int16_field; - - - m_array_uint16_field = x.m_array_uint16_field; - - - m_array_int32_field = x.m_array_int32_field; - - - m_array_uint32_field = x.m_array_uint32_field; - - - m_array_int64_field = x.m_array_int64_field; - - - m_array_uint64_field = x.m_array_uint64_field; - - - m_array_float_field = x.m_array_float_field; - - - m_array_double_field = x.m_array_double_field; - - - m_array_long_double_field = x.m_array_long_double_field; - - - m_array_bool_field = x.m_array_bool_field; - - - m_array_string_field = x.m_array_string_field; - - - m_array_enum_field = x.m_array_enum_field; - - - m_array_enum2_field = x.m_array_enum2_field; - - - m_array_struct_field = x.m_array_struct_field; - - - m_bounded_sequence_char_field = x.m_bounded_sequence_char_field; - - - m_bounded_sequence_uint8_field = x.m_bounded_sequence_uint8_field; - - - m_bounded_sequence_int16_field = x.m_bounded_sequence_int16_field; - - - m_bounded_sequence_uint16_field = x.m_bounded_sequence_uint16_field; - - - m_bounded_sequence_int32_field = x.m_bounded_sequence_int32_field; - - - m_bounded_sequence_uint32_field = x.m_bounded_sequence_uint32_field; - - - m_bounded_sequence_int64_field = x.m_bounded_sequence_int64_field; - - - m_bounded_sequence_uint64_field = x.m_bounded_sequence_uint64_field; - - - m_bounded_sequence_float_field = x.m_bounded_sequence_float_field; - - - m_bounded_sequence_double_field = x.m_bounded_sequence_double_field; - - - m_bounded_sequence_long_double_field = x.m_bounded_sequence_long_double_field; - - - m_bounded_sequence_bool_field = x.m_bounded_sequence_bool_field; - - - m_bounded_sequence_string_field = x.m_bounded_sequence_string_field; - - - m_bounded_sequence_enum_field = x.m_bounded_sequence_enum_field; - - - m_bounded_sequence_enum2_field = x.m_bounded_sequence_enum2_field; - - - m_bounded_sequence_struct_field = x.m_bounded_sequence_struct_field; - - - m_unbounded_sequence_char_field = x.m_unbounded_sequence_char_field; - - - m_unbounded_sequence_uint8_field = x.m_unbounded_sequence_uint8_field; - - - m_unbounded_sequence_int16_field = x.m_unbounded_sequence_int16_field; - - - m_unbounded_sequence_uint16_field = x.m_unbounded_sequence_uint16_field; - - - m_unbounded_sequence_int32_field = x.m_unbounded_sequence_int32_field; - - - m_unbounded_sequence_uint32_field = x.m_unbounded_sequence_uint32_field; - - - m_unbounded_sequence_int64_field = x.m_unbounded_sequence_int64_field; - - - m_unbounded_sequence_uint64_field = x.m_unbounded_sequence_uint64_field; - - - m_unbounded_sequence_float_field = x.m_unbounded_sequence_float_field; - - - m_unbounded_sequence_double_field = x.m_unbounded_sequence_double_field; - - - m_unbounded_sequence_long_double_field = x.m_unbounded_sequence_long_double_field; - - - m_unbounded_sequence_bool_field = x.m_unbounded_sequence_bool_field; - - - m_unbounded_sequence_string_field = x.m_unbounded_sequence_string_field; - - - m_unbounded_sequence_enum_field = x.m_unbounded_sequence_enum_field; - - - m_unbounded_sequence_enum2_field = x.m_unbounded_sequence_enum2_field; - - - m_unbounded_sequence_struct_field = x.m_unbounded_sequence_struct_field; - - return *this; -} - -ContentFilterTestType& ContentFilterTestType::operator =( - ContentFilterTestType&& x) noexcept -{ - m_char_field = x.m_char_field; - - - m_uint8_field = x.m_uint8_field; - - - m_int16_field = x.m_int16_field; - - - m_uint16_field = x.m_uint16_field; - - - m_int32_field = x.m_int32_field; - - - m_uint32_field = x.m_uint32_field; - - - m_int64_field = x.m_int64_field; - - - m_uint64_field = x.m_uint64_field; - - - m_float_field = x.m_float_field; - - - m_double_field = x.m_double_field; - - - m_long_double_field = x.m_long_double_field; - - - m_bool_field = x.m_bool_field; - - - m_string_field = std::move(x.m_string_field); - - - m_enum_field = x.m_enum_field; - - - m_enum2_field = x.m_enum2_field; - - - m_struct_field = std::move(x.m_struct_field); - - - m_array_char_field = std::move(x.m_array_char_field); - - - m_array_uint8_field = std::move(x.m_array_uint8_field); - - - m_array_int16_field = std::move(x.m_array_int16_field); - - - m_array_uint16_field = std::move(x.m_array_uint16_field); - - - m_array_int32_field = std::move(x.m_array_int32_field); - - - m_array_uint32_field = std::move(x.m_array_uint32_field); - - - m_array_int64_field = std::move(x.m_array_int64_field); - - - m_array_uint64_field = std::move(x.m_array_uint64_field); - - - m_array_float_field = std::move(x.m_array_float_field); - - - m_array_double_field = std::move(x.m_array_double_field); - - - m_array_long_double_field = std::move(x.m_array_long_double_field); - - - m_array_bool_field = std::move(x.m_array_bool_field); - - - m_array_string_field = std::move(x.m_array_string_field); - - - m_array_enum_field = std::move(x.m_array_enum_field); - - - m_array_enum2_field = std::move(x.m_array_enum2_field); - - - m_array_struct_field = std::move(x.m_array_struct_field); - - - m_bounded_sequence_char_field = std::move(x.m_bounded_sequence_char_field); - - - m_bounded_sequence_uint8_field = std::move(x.m_bounded_sequence_uint8_field); - - - m_bounded_sequence_int16_field = std::move(x.m_bounded_sequence_int16_field); - - - m_bounded_sequence_uint16_field = std::move(x.m_bounded_sequence_uint16_field); - - - m_bounded_sequence_int32_field = std::move(x.m_bounded_sequence_int32_field); - - - m_bounded_sequence_uint32_field = std::move(x.m_bounded_sequence_uint32_field); - - - m_bounded_sequence_int64_field = std::move(x.m_bounded_sequence_int64_field); - - - m_bounded_sequence_uint64_field = std::move(x.m_bounded_sequence_uint64_field); - - - m_bounded_sequence_float_field = std::move(x.m_bounded_sequence_float_field); - - - m_bounded_sequence_double_field = std::move(x.m_bounded_sequence_double_field); - - - m_bounded_sequence_long_double_field = std::move(x.m_bounded_sequence_long_double_field); - - - m_bounded_sequence_bool_field = std::move(x.m_bounded_sequence_bool_field); - - - m_bounded_sequence_string_field = std::move(x.m_bounded_sequence_string_field); - - - m_bounded_sequence_enum_field = std::move(x.m_bounded_sequence_enum_field); - - - m_bounded_sequence_enum2_field = std::move(x.m_bounded_sequence_enum2_field); - - - m_bounded_sequence_struct_field = std::move(x.m_bounded_sequence_struct_field); - - - m_unbounded_sequence_char_field = std::move(x.m_unbounded_sequence_char_field); - - - m_unbounded_sequence_uint8_field = std::move(x.m_unbounded_sequence_uint8_field); - - - m_unbounded_sequence_int16_field = std::move(x.m_unbounded_sequence_int16_field); - - - m_unbounded_sequence_uint16_field = std::move(x.m_unbounded_sequence_uint16_field); - - - m_unbounded_sequence_int32_field = std::move(x.m_unbounded_sequence_int32_field); - - - m_unbounded_sequence_uint32_field = std::move(x.m_unbounded_sequence_uint32_field); - - - m_unbounded_sequence_int64_field = std::move(x.m_unbounded_sequence_int64_field); - - - m_unbounded_sequence_uint64_field = std::move(x.m_unbounded_sequence_uint64_field); - - - m_unbounded_sequence_float_field = std::move(x.m_unbounded_sequence_float_field); - - - m_unbounded_sequence_double_field = std::move(x.m_unbounded_sequence_double_field); - - - m_unbounded_sequence_long_double_field = std::move(x.m_unbounded_sequence_long_double_field); - - - m_unbounded_sequence_bool_field = std::move(x.m_unbounded_sequence_bool_field); - - - m_unbounded_sequence_string_field = std::move(x.m_unbounded_sequence_string_field); - - - m_unbounded_sequence_enum_field = std::move(x.m_unbounded_sequence_enum_field); - - - m_unbounded_sequence_enum2_field = std::move(x.m_unbounded_sequence_enum2_field); - - - m_unbounded_sequence_struct_field = std::move(x.m_unbounded_sequence_struct_field); - - return *this; -} - -bool ContentFilterTestType::operator ==( - const ContentFilterTestType& x) const -{ - return (m_char_field == x.m_char_field && - m_uint8_field == x.m_uint8_field && - m_int16_field == x.m_int16_field && - m_uint16_field == x.m_uint16_field && - m_int32_field == x.m_int32_field && - m_uint32_field == x.m_uint32_field && - m_int64_field == x.m_int64_field && - m_uint64_field == x.m_uint64_field && - m_float_field == x.m_float_field && - m_double_field == x.m_double_field && - m_long_double_field == x.m_long_double_field && - m_bool_field == x.m_bool_field && - m_string_field == x.m_string_field && - m_enum_field == x.m_enum_field && - m_enum2_field == x.m_enum2_field && - m_struct_field == x.m_struct_field && - m_array_char_field == x.m_array_char_field && - m_array_uint8_field == x.m_array_uint8_field && - m_array_int16_field == x.m_array_int16_field && - m_array_uint16_field == x.m_array_uint16_field && - m_array_int32_field == x.m_array_int32_field && - m_array_uint32_field == x.m_array_uint32_field && - m_array_int64_field == x.m_array_int64_field && - m_array_uint64_field == x.m_array_uint64_field && - m_array_float_field == x.m_array_float_field && - m_array_double_field == x.m_array_double_field && - m_array_long_double_field == x.m_array_long_double_field && - m_array_bool_field == x.m_array_bool_field && - m_array_string_field == x.m_array_string_field && - m_array_enum_field == x.m_array_enum_field && - m_array_enum2_field == x.m_array_enum2_field && - m_array_struct_field == x.m_array_struct_field && - m_bounded_sequence_char_field == x.m_bounded_sequence_char_field && - m_bounded_sequence_uint8_field == x.m_bounded_sequence_uint8_field && - m_bounded_sequence_int16_field == x.m_bounded_sequence_int16_field && - m_bounded_sequence_uint16_field == x.m_bounded_sequence_uint16_field && - m_bounded_sequence_int32_field == x.m_bounded_sequence_int32_field && - m_bounded_sequence_uint32_field == x.m_bounded_sequence_uint32_field && - m_bounded_sequence_int64_field == x.m_bounded_sequence_int64_field && - m_bounded_sequence_uint64_field == x.m_bounded_sequence_uint64_field && - m_bounded_sequence_float_field == x.m_bounded_sequence_float_field && - m_bounded_sequence_double_field == x.m_bounded_sequence_double_field && - m_bounded_sequence_long_double_field == x.m_bounded_sequence_long_double_field && - m_bounded_sequence_bool_field == x.m_bounded_sequence_bool_field && - m_bounded_sequence_string_field == x.m_bounded_sequence_string_field && - m_bounded_sequence_enum_field == x.m_bounded_sequence_enum_field && - m_bounded_sequence_enum2_field == x.m_bounded_sequence_enum2_field && - m_bounded_sequence_struct_field == x.m_bounded_sequence_struct_field && - m_unbounded_sequence_char_field == x.m_unbounded_sequence_char_field && - m_unbounded_sequence_uint8_field == x.m_unbounded_sequence_uint8_field && - m_unbounded_sequence_int16_field == x.m_unbounded_sequence_int16_field && - m_unbounded_sequence_uint16_field == x.m_unbounded_sequence_uint16_field && - m_unbounded_sequence_int32_field == x.m_unbounded_sequence_int32_field && - m_unbounded_sequence_uint32_field == x.m_unbounded_sequence_uint32_field && - m_unbounded_sequence_int64_field == x.m_unbounded_sequence_int64_field && - m_unbounded_sequence_uint64_field == x.m_unbounded_sequence_uint64_field && - m_unbounded_sequence_float_field == x.m_unbounded_sequence_float_field && - m_unbounded_sequence_double_field == x.m_unbounded_sequence_double_field && - m_unbounded_sequence_long_double_field == x.m_unbounded_sequence_long_double_field && - m_unbounded_sequence_bool_field == x.m_unbounded_sequence_bool_field && - m_unbounded_sequence_string_field == x.m_unbounded_sequence_string_field && - m_unbounded_sequence_enum_field == x.m_unbounded_sequence_enum_field && - m_unbounded_sequence_enum2_field == x.m_unbounded_sequence_enum2_field && - m_unbounded_sequence_struct_field == x.m_unbounded_sequence_struct_field); -} - -bool ContentFilterTestType::operator !=( - const ContentFilterTestType& x) const -{ - return !(*this == x); -} - -size_t ContentFilterTestType::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return ContentFilterTestType_max_cdr_typesize; -} - -size_t ContentFilterTestType::getCdrSerializedSize( - const ContentFilterTestType& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - current_alignment += 2 + eprosima::fastcdr::Cdr::alignment(current_alignment, 2); - - - current_alignment += 2 + eprosima::fastcdr::Cdr::alignment(current_alignment, 2); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += 8 + eprosima::fastcdr::Cdr::alignment(current_alignment, 8); - - - current_alignment += 8 + eprosima::fastcdr::Cdr::alignment(current_alignment, 8); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += 8 + eprosima::fastcdr::Cdr::alignment(current_alignment, 8); - - - current_alignment += 16 + eprosima::fastcdr::Cdr::alignment(current_alignment, 8); // 128 bits, but aligned as 64 - - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + data.string_field().size() + 1; - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += StructType::getCdrSerializedSize(data.struct_field(), current_alignment); - - - current_alignment += (((max_array_size)) * 1) + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - - current_alignment += (((max_array_size)) * 1) + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - - current_alignment += (((max_array_size)) * 2) + eprosima::fastcdr::Cdr::alignment(current_alignment, 2); - - - - current_alignment += (((max_array_size)) * 2) + eprosima::fastcdr::Cdr::alignment(current_alignment, 2); - - - - current_alignment += (((max_array_size)) * 4) + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - - current_alignment += (((max_array_size)) * 4) + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - - current_alignment += (((max_array_size)) * 8) + eprosima::fastcdr::Cdr::alignment(current_alignment, 8); - - - - current_alignment += (((max_array_size)) * 8) + eprosima::fastcdr::Cdr::alignment(current_alignment, 8); - - - - current_alignment += (((max_array_size)) * 4) + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - - current_alignment += (((max_array_size)) * 8) + eprosima::fastcdr::Cdr::alignment(current_alignment, 8); - - - - current_alignment += (((max_array_size)) * 16) + eprosima::fastcdr::Cdr::alignment(current_alignment, 16); - - - - current_alignment += (((max_array_size)) * 1) + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - - - for(size_t a = 0; a < data.array_string_field().size(); ++a) - { - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + data.array_string_field().at(a).size() + 1; - - } - - - - current_alignment += (((max_array_size)) * 4) + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - - current_alignment += (((max_array_size)) * 4) + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - - - for(size_t a = 0; a < data.array_struct_field().size(); ++a) - { - current_alignment += StructType::getCdrSerializedSize(data.array_struct_field().at(a), current_alignment); - - } - - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - if (data.bounded_sequence_char_field().size() > 0) - { - current_alignment += (data.bounded_sequence_char_field().size() * 1) + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - } - - - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - if (data.bounded_sequence_uint8_field().size() > 0) - { - current_alignment += (data.bounded_sequence_uint8_field().size() * 1) + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - } - - - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - if (data.bounded_sequence_int16_field().size() > 0) - { - current_alignment += (data.bounded_sequence_int16_field().size() * 2) + eprosima::fastcdr::Cdr::alignment(current_alignment, 2); - } - - - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - if (data.bounded_sequence_uint16_field().size() > 0) - { - current_alignment += (data.bounded_sequence_uint16_field().size() * 2) + eprosima::fastcdr::Cdr::alignment(current_alignment, 2); - } - - - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - if (data.bounded_sequence_int32_field().size() > 0) - { - current_alignment += (data.bounded_sequence_int32_field().size() * 4) + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - } - - - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - if (data.bounded_sequence_uint32_field().size() > 0) - { - current_alignment += (data.bounded_sequence_uint32_field().size() * 4) + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - } - - - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - if (data.bounded_sequence_int64_field().size() > 0) - { - current_alignment += (data.bounded_sequence_int64_field().size() * 8) + eprosima::fastcdr::Cdr::alignment(current_alignment, 8); - } - - - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - if (data.bounded_sequence_uint64_field().size() > 0) - { - current_alignment += (data.bounded_sequence_uint64_field().size() * 8) + eprosima::fastcdr::Cdr::alignment(current_alignment, 8); - } - - - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - if (data.bounded_sequence_float_field().size() > 0) - { - current_alignment += (data.bounded_sequence_float_field().size() * 4) + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - } - - - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - if (data.bounded_sequence_double_field().size() > 0) - { - current_alignment += (data.bounded_sequence_double_field().size() * 8) + eprosima::fastcdr::Cdr::alignment(current_alignment, 8); - } - - - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - if (data.bounded_sequence_long_double_field().size() > 0) - { - current_alignment += (data.bounded_sequence_long_double_field().size() * 16) + eprosima::fastcdr::Cdr::alignment(current_alignment, 8); // 128 bits, but aligned as 64 - } - - - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - if (data.bounded_sequence_bool_field().size() > 0) - { - current_alignment += (data.bounded_sequence_bool_field().size() * 1) + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - } - - - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - for(size_t a = 0; a < data.bounded_sequence_string_field().size(); ++a) - { - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + - data.bounded_sequence_string_field().at(a).size() + 1; - } - - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - if (data.bounded_sequence_enum_field().size() > 0) - { - current_alignment += (data.bounded_sequence_enum_field().size() * 4) + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - } - - - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - if (data.bounded_sequence_enum2_field().size() > 0) - { - current_alignment += (data.bounded_sequence_enum2_field().size() * 4) + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - } - - - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - for(size_t a = 0; a < data.bounded_sequence_struct_field().size(); ++a) - { - current_alignment += StructType::getCdrSerializedSize(data.bounded_sequence_struct_field().at(a), current_alignment); - } - - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - if (data.unbounded_sequence_char_field().size() > 0) - { - current_alignment += (data.unbounded_sequence_char_field().size() * 1) + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - } - - - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - if (data.unbounded_sequence_uint8_field().size() > 0) - { - current_alignment += (data.unbounded_sequence_uint8_field().size() * 1) + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - } - - - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - if (data.unbounded_sequence_int16_field().size() > 0) - { - current_alignment += (data.unbounded_sequence_int16_field().size() * 2) + eprosima::fastcdr::Cdr::alignment(current_alignment, 2); - } - - - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - if (data.unbounded_sequence_uint16_field().size() > 0) - { - current_alignment += (data.unbounded_sequence_uint16_field().size() * 2) + eprosima::fastcdr::Cdr::alignment(current_alignment, 2); - } - - - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - if (data.unbounded_sequence_int32_field().size() > 0) - { - current_alignment += (data.unbounded_sequence_int32_field().size() * 4) + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - } - - - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - if (data.unbounded_sequence_uint32_field().size() > 0) - { - current_alignment += (data.unbounded_sequence_uint32_field().size() * 4) + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - } - - - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - if (data.unbounded_sequence_int64_field().size() > 0) - { - current_alignment += (data.unbounded_sequence_int64_field().size() * 8) + eprosima::fastcdr::Cdr::alignment(current_alignment, 8); - } - - - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - if (data.unbounded_sequence_uint64_field().size() > 0) - { - current_alignment += (data.unbounded_sequence_uint64_field().size() * 8) + eprosima::fastcdr::Cdr::alignment(current_alignment, 8); - } - - - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - if (data.unbounded_sequence_float_field().size() > 0) - { - current_alignment += (data.unbounded_sequence_float_field().size() * 4) + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - } - - - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - if (data.unbounded_sequence_double_field().size() > 0) - { - current_alignment += (data.unbounded_sequence_double_field().size() * 8) + eprosima::fastcdr::Cdr::alignment(current_alignment, 8); - } - - - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - if (data.unbounded_sequence_long_double_field().size() > 0) - { - current_alignment += (data.unbounded_sequence_long_double_field().size() * 16) + eprosima::fastcdr::Cdr::alignment(current_alignment, 8); // 128 bits, but aligned as 64 - } - - - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - if (data.unbounded_sequence_bool_field().size() > 0) - { - current_alignment += (data.unbounded_sequence_bool_field().size() * 1) + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - } - - - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - for(size_t a = 0; a < data.unbounded_sequence_string_field().size(); ++a) - { - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + - data.unbounded_sequence_string_field().at(a).size() + 1; - } - - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - if (data.unbounded_sequence_enum_field().size() > 0) - { - current_alignment += (data.unbounded_sequence_enum_field().size() * 4) + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - } - - - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - if (data.unbounded_sequence_enum2_field().size() > 0) - { - current_alignment += (data.unbounded_sequence_enum2_field().size() * 4) + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - } - - - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - for(size_t a = 0; a < data.unbounded_sequence_struct_field().size(); ++a) - { - current_alignment += StructType::getCdrSerializedSize(data.unbounded_sequence_struct_field().at(a), current_alignment); - } - - - - return current_alignment - initial_alignment; -} - - -void ContentFilterTestType::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_char_field; - - scdr << m_uint8_field; - - scdr << m_int16_field; - - scdr << m_uint16_field; - - scdr << m_int32_field; - - scdr << m_uint32_field; - - scdr << m_int64_field; - - scdr << m_uint64_field; - - scdr << m_float_field; - - scdr << m_double_field; - - scdr << m_long_double_field; - - scdr << m_bool_field; - - scdr << m_string_field.c_str(); - - scdr << (uint32_t)m_enum_field; - - scdr << (uint32_t)m_enum2_field; - - scdr << m_struct_field; - - scdr << m_array_char_field; - - - scdr << m_array_uint8_field; - - - scdr << m_array_int16_field; - - - scdr << m_array_uint16_field; - - - scdr << m_array_int32_field; - - - scdr << m_array_uint32_field; - - - scdr << m_array_int64_field; - - - scdr << m_array_uint64_field; - - - scdr << m_array_float_field; - - - scdr << m_array_double_field; - - - scdr << m_array_long_double_field; - - - scdr << m_array_bool_field; - - - for (const auto& str : m_array_string_field) - { - scdr << str.c_str(); - } - - - - - - scdr.serializeArray(reinterpret_cast(m_array_enum_field.data()), m_array_enum_field.size()); - - - scdr.serializeArray(reinterpret_cast(m_array_enum2_field.data()), m_array_enum2_field.size()); - - - scdr << m_array_struct_field; - - - scdr << m_bounded_sequence_char_field; - - - scdr << m_bounded_sequence_uint8_field; - - - scdr << m_bounded_sequence_int16_field; - - - scdr << m_bounded_sequence_uint16_field; - - - scdr << m_bounded_sequence_int32_field; - - - scdr << m_bounded_sequence_uint32_field; - - - scdr << m_bounded_sequence_int64_field; - - - scdr << m_bounded_sequence_uint64_field; - - - scdr << m_bounded_sequence_float_field; - - - scdr << m_bounded_sequence_double_field; - - - scdr << m_bounded_sequence_long_double_field; - - - scdr << m_bounded_sequence_bool_field; - - - scdr << m_bounded_sequence_string_field; - - - - - scdr << static_cast(m_bounded_sequence_enum_field.size()); - scdr.serializeArray(reinterpret_cast(m_bounded_sequence_enum_field.data()), m_bounded_sequence_enum_field.size()); - - - scdr << static_cast(m_bounded_sequence_enum2_field.size()); - scdr.serializeArray(reinterpret_cast(m_bounded_sequence_enum2_field.data()), m_bounded_sequence_enum2_field.size()); - - - scdr << m_bounded_sequence_struct_field; - - - scdr << m_unbounded_sequence_char_field; - - - scdr << m_unbounded_sequence_uint8_field; - - - scdr << m_unbounded_sequence_int16_field; - - - scdr << m_unbounded_sequence_uint16_field; - - - scdr << m_unbounded_sequence_int32_field; - - - scdr << m_unbounded_sequence_uint32_field; - - - scdr << m_unbounded_sequence_int64_field; - - - scdr << m_unbounded_sequence_uint64_field; - - - scdr << m_unbounded_sequence_float_field; - - - scdr << m_unbounded_sequence_double_field; - - - scdr << m_unbounded_sequence_long_double_field; - - - scdr << m_unbounded_sequence_bool_field; - - - scdr << m_unbounded_sequence_string_field; - - - - - scdr << static_cast(m_unbounded_sequence_enum_field.size()); - scdr.serializeArray(reinterpret_cast(m_unbounded_sequence_enum_field.data()), m_unbounded_sequence_enum_field.size()); - - - scdr << static_cast(m_unbounded_sequence_enum2_field.size()); - scdr.serializeArray(reinterpret_cast(m_unbounded_sequence_enum2_field.data()), m_unbounded_sequence_enum2_field.size()); - - - scdr << m_unbounded_sequence_struct_field; - - -} - -void ContentFilterTestType::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_char_field; - - - - dcdr >> m_uint8_field; - - - - dcdr >> m_int16_field; - - - - dcdr >> m_uint16_field; - - - - dcdr >> m_int32_field; - - - - dcdr >> m_uint32_field; - - - - dcdr >> m_int64_field; - - - - dcdr >> m_uint64_field; - - - - dcdr >> m_float_field; - - - - dcdr >> m_double_field; - - - - dcdr >> m_long_double_field; - - - - dcdr >> m_bool_field; - - - - dcdr >> m_string_field; - - - - { - uint32_t enum_value = 0; - dcdr >> enum_value; - m_enum_field = (Color)enum_value; - } - - - - { - uint32_t enum_value = 0; - dcdr >> enum_value; - m_enum2_field = (Material)enum_value; - } - - - - dcdr >> m_struct_field; - - - - dcdr >> m_array_char_field; - - - - dcdr >> m_array_uint8_field; - - - - dcdr >> m_array_int16_field; - - - - dcdr >> m_array_uint16_field; - - - - dcdr >> m_array_int32_field; - - - - dcdr >> m_array_uint32_field; - - - - dcdr >> m_array_int64_field; - - - - dcdr >> m_array_uint64_field; - - - - dcdr >> m_array_float_field; - - - - dcdr >> m_array_double_field; - - - - dcdr >> m_array_long_double_field; - - - - dcdr >> m_array_bool_field; - - - - for (auto& str : m_array_string_field) - { - dcdr >> str; - } - - - - - - - dcdr.deserializeArray(reinterpret_cast(m_array_enum_field.data()), m_array_enum_field.size()); - - - - dcdr.deserializeArray(reinterpret_cast(m_array_enum2_field.data()), m_array_enum2_field.size()); - - - - dcdr >> m_array_struct_field; - - - - dcdr >> m_bounded_sequence_char_field; - - - - dcdr >> m_bounded_sequence_uint8_field; - - - - dcdr >> m_bounded_sequence_int16_field; - - - - dcdr >> m_bounded_sequence_uint16_field; - - - - dcdr >> m_bounded_sequence_int32_field; - - - - dcdr >> m_bounded_sequence_uint32_field; - - - - dcdr >> m_bounded_sequence_int64_field; - - - - dcdr >> m_bounded_sequence_uint64_field; - - - - dcdr >> m_bounded_sequence_float_field; - - - - dcdr >> m_bounded_sequence_double_field; - - - - dcdr >> m_bounded_sequence_long_double_field; - - - - dcdr >> m_bounded_sequence_bool_field; - - - - dcdr >> m_bounded_sequence_string_field; - - - - - { - uint32_t seq_length = 0; - dcdr >> seq_length; - m_bounded_sequence_enum_field.resize(seq_length); - dcdr.deserializeArray(reinterpret_cast(m_bounded_sequence_enum_field.data()), seq_length); - } - - - - { - uint32_t seq_length = 0; - dcdr >> seq_length; - m_bounded_sequence_enum2_field.resize(seq_length); - dcdr.deserializeArray(reinterpret_cast(m_bounded_sequence_enum2_field.data()), seq_length); - } - - - - dcdr >> m_bounded_sequence_struct_field; - - - - dcdr >> m_unbounded_sequence_char_field; - - - - dcdr >> m_unbounded_sequence_uint8_field; - - - - dcdr >> m_unbounded_sequence_int16_field; - - - - dcdr >> m_unbounded_sequence_uint16_field; - - - - dcdr >> m_unbounded_sequence_int32_field; - - - - dcdr >> m_unbounded_sequence_uint32_field; - - - - dcdr >> m_unbounded_sequence_int64_field; - - - - dcdr >> m_unbounded_sequence_uint64_field; - - - - dcdr >> m_unbounded_sequence_float_field; - - - - dcdr >> m_unbounded_sequence_double_field; - - - - dcdr >> m_unbounded_sequence_long_double_field; - - - - dcdr >> m_unbounded_sequence_bool_field; - - - - dcdr >> m_unbounded_sequence_string_field; - - - - - { - uint32_t seq_length = 0; - dcdr >> seq_length; - m_unbounded_sequence_enum_field.resize(seq_length); - dcdr.deserializeArray(reinterpret_cast(m_unbounded_sequence_enum_field.data()), seq_length); - } - - - - { - uint32_t seq_length = 0; - dcdr >> seq_length; - m_unbounded_sequence_enum2_field.resize(seq_length); - dcdr.deserializeArray(reinterpret_cast(m_unbounded_sequence_enum2_field.data()), seq_length); - } - - - - dcdr >> m_unbounded_sequence_struct_field; - - -} - - -bool ContentFilterTestType::isKeyDefined() -{ - return false; -} - -void ContentFilterTestType::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member char_field - * @param _char_field New value for member char_field - */ -void ContentFilterTestType::char_field( - char _char_field) -{ - m_char_field = _char_field; -} - -/*! - * @brief This function returns the value of member char_field - * @return Value of member char_field - */ -char ContentFilterTestType::char_field() const -{ - return m_char_field; -} - -/*! - * @brief This function returns a reference to member char_field - * @return Reference to member char_field - */ -char& ContentFilterTestType::char_field() -{ - return m_char_field; -} - - -/*! - * @brief This function sets a value in member uint8_field - * @param _uint8_field New value for member uint8_field - */ -void ContentFilterTestType::uint8_field( - uint8_t _uint8_field) -{ - m_uint8_field = _uint8_field; -} - -/*! - * @brief This function returns the value of member uint8_field - * @return Value of member uint8_field - */ -uint8_t ContentFilterTestType::uint8_field() const -{ - return m_uint8_field; -} - -/*! - * @brief This function returns a reference to member uint8_field - * @return Reference to member uint8_field - */ -uint8_t& ContentFilterTestType::uint8_field() -{ - return m_uint8_field; -} - - -/*! - * @brief This function sets a value in member int16_field - * @param _int16_field New value for member int16_field - */ -void ContentFilterTestType::int16_field( - int16_t _int16_field) -{ - m_int16_field = _int16_field; -} - -/*! - * @brief This function returns the value of member int16_field - * @return Value of member int16_field - */ -int16_t ContentFilterTestType::int16_field() const -{ - return m_int16_field; -} - -/*! - * @brief This function returns a reference to member int16_field - * @return Reference to member int16_field - */ -int16_t& ContentFilterTestType::int16_field() -{ - return m_int16_field; -} - - -/*! - * @brief This function sets a value in member uint16_field - * @param _uint16_field New value for member uint16_field - */ -void ContentFilterTestType::uint16_field( - uint16_t _uint16_field) -{ - m_uint16_field = _uint16_field; -} - -/*! - * @brief This function returns the value of member uint16_field - * @return Value of member uint16_field - */ -uint16_t ContentFilterTestType::uint16_field() const -{ - return m_uint16_field; -} - -/*! - * @brief This function returns a reference to member uint16_field - * @return Reference to member uint16_field - */ -uint16_t& ContentFilterTestType::uint16_field() -{ - return m_uint16_field; -} - - -/*! - * @brief This function sets a value in member int32_field - * @param _int32_field New value for member int32_field - */ -void ContentFilterTestType::int32_field( - int32_t _int32_field) -{ - m_int32_field = _int32_field; -} - -/*! - * @brief This function returns the value of member int32_field - * @return Value of member int32_field - */ -int32_t ContentFilterTestType::int32_field() const -{ - return m_int32_field; -} - -/*! - * @brief This function returns a reference to member int32_field - * @return Reference to member int32_field - */ -int32_t& ContentFilterTestType::int32_field() -{ - return m_int32_field; -} - - -/*! - * @brief This function sets a value in member uint32_field - * @param _uint32_field New value for member uint32_field - */ -void ContentFilterTestType::uint32_field( - uint32_t _uint32_field) -{ - m_uint32_field = _uint32_field; -} - -/*! - * @brief This function returns the value of member uint32_field - * @return Value of member uint32_field - */ -uint32_t ContentFilterTestType::uint32_field() const -{ - return m_uint32_field; -} - -/*! - * @brief This function returns a reference to member uint32_field - * @return Reference to member uint32_field - */ -uint32_t& ContentFilterTestType::uint32_field() -{ - return m_uint32_field; -} - - -/*! - * @brief This function sets a value in member int64_field - * @param _int64_field New value for member int64_field - */ -void ContentFilterTestType::int64_field( - int64_t _int64_field) -{ - m_int64_field = _int64_field; -} - -/*! - * @brief This function returns the value of member int64_field - * @return Value of member int64_field - */ -int64_t ContentFilterTestType::int64_field() const -{ - return m_int64_field; -} - -/*! - * @brief This function returns a reference to member int64_field - * @return Reference to member int64_field - */ -int64_t& ContentFilterTestType::int64_field() -{ - return m_int64_field; -} - - -/*! - * @brief This function sets a value in member uint64_field - * @param _uint64_field New value for member uint64_field - */ -void ContentFilterTestType::uint64_field( - uint64_t _uint64_field) -{ - m_uint64_field = _uint64_field; -} - -/*! - * @brief This function returns the value of member uint64_field - * @return Value of member uint64_field - */ -uint64_t ContentFilterTestType::uint64_field() const -{ - return m_uint64_field; -} - -/*! - * @brief This function returns a reference to member uint64_field - * @return Reference to member uint64_field - */ -uint64_t& ContentFilterTestType::uint64_field() -{ - return m_uint64_field; -} - - -/*! - * @brief This function sets a value in member float_field - * @param _float_field New value for member float_field - */ -void ContentFilterTestType::float_field( - float _float_field) -{ - m_float_field = _float_field; -} - -/*! - * @brief This function returns the value of member float_field - * @return Value of member float_field - */ -float ContentFilterTestType::float_field() const -{ - return m_float_field; -} - -/*! - * @brief This function returns a reference to member float_field - * @return Reference to member float_field - */ -float& ContentFilterTestType::float_field() -{ - return m_float_field; -} - - -/*! - * @brief This function sets a value in member double_field - * @param _double_field New value for member double_field - */ -void ContentFilterTestType::double_field( - double _double_field) -{ - m_double_field = _double_field; -} - -/*! - * @brief This function returns the value of member double_field - * @return Value of member double_field - */ -double ContentFilterTestType::double_field() const -{ - return m_double_field; -} - -/*! - * @brief This function returns a reference to member double_field - * @return Reference to member double_field - */ -double& ContentFilterTestType::double_field() -{ - return m_double_field; -} - - -/*! - * @brief This function sets a value in member long_double_field - * @param _long_double_field New value for member long_double_field - */ -void ContentFilterTestType::long_double_field( - long double _long_double_field) -{ - m_long_double_field = _long_double_field; -} - -/*! - * @brief This function returns the value of member long_double_field - * @return Value of member long_double_field - */ -long double ContentFilterTestType::long_double_field() const -{ - return m_long_double_field; -} - -/*! - * @brief This function returns a reference to member long_double_field - * @return Reference to member long_double_field - */ -long double& ContentFilterTestType::long_double_field() -{ - return m_long_double_field; -} - - -/*! - * @brief This function sets a value in member bool_field - * @param _bool_field New value for member bool_field - */ -void ContentFilterTestType::bool_field( - bool _bool_field) -{ - m_bool_field = _bool_field; -} - -/*! - * @brief This function returns the value of member bool_field - * @return Value of member bool_field - */ -bool ContentFilterTestType::bool_field() const -{ - return m_bool_field; -} - -/*! - * @brief This function returns a reference to member bool_field - * @return Reference to member bool_field - */ -bool& ContentFilterTestType::bool_field() -{ - return m_bool_field; -} - - -/*! - * @brief This function copies the value in member string_field - * @param _string_field New value to be copied in member string_field - */ -void ContentFilterTestType::string_field( - const std::string& _string_field) -{ - m_string_field = _string_field; -} - -/*! - * @brief This function moves the value in member string_field - * @param _string_field New value to be moved in member string_field - */ -void ContentFilterTestType::string_field( - std::string&& _string_field) -{ - m_string_field = std::move(_string_field); -} - -/*! - * @brief This function returns a constant reference to member string_field - * @return Constant reference to member string_field - */ -const std::string& ContentFilterTestType::string_field() const -{ - return m_string_field; -} - -/*! - * @brief This function returns a reference to member string_field - * @return Reference to member string_field - */ -std::string& ContentFilterTestType::string_field() -{ - return m_string_field; -} - - -/*! - * @brief This function sets a value in member enum_field - * @param _enum_field New value for member enum_field - */ -void ContentFilterTestType::enum_field( - Color _enum_field) -{ - m_enum_field = _enum_field; -} - -/*! - * @brief This function returns the value of member enum_field - * @return Value of member enum_field - */ -Color ContentFilterTestType::enum_field() const -{ - return m_enum_field; -} - -/*! - * @brief This function returns a reference to member enum_field - * @return Reference to member enum_field - */ -Color& ContentFilterTestType::enum_field() -{ - return m_enum_field; -} - - -/*! - * @brief This function sets a value in member enum2_field - * @param _enum2_field New value for member enum2_field - */ -void ContentFilterTestType::enum2_field( - Material _enum2_field) -{ - m_enum2_field = _enum2_field; -} - -/*! - * @brief This function returns the value of member enum2_field - * @return Value of member enum2_field - */ -Material ContentFilterTestType::enum2_field() const -{ - return m_enum2_field; -} - -/*! - * @brief This function returns a reference to member enum2_field - * @return Reference to member enum2_field - */ -Material& ContentFilterTestType::enum2_field() -{ - return m_enum2_field; -} - - -/*! - * @brief This function copies the value in member struct_field - * @param _struct_field New value to be copied in member struct_field - */ -void ContentFilterTestType::struct_field( - const StructType& _struct_field) -{ - m_struct_field = _struct_field; -} - -/*! - * @brief This function moves the value in member struct_field - * @param _struct_field New value to be moved in member struct_field - */ -void ContentFilterTestType::struct_field( - StructType&& _struct_field) -{ - m_struct_field = std::move(_struct_field); -} - -/*! - * @brief This function returns a constant reference to member struct_field - * @return Constant reference to member struct_field - */ -const StructType& ContentFilterTestType::struct_field() const -{ - return m_struct_field; -} - -/*! - * @brief This function returns a reference to member struct_field - * @return Reference to member struct_field - */ -StructType& ContentFilterTestType::struct_field() -{ - return m_struct_field; -} - - -/*! - * @brief This function copies the value in member array_char_field - * @param _array_char_field New value to be copied in member array_char_field - */ -void ContentFilterTestType::array_char_field( - const std::array& _array_char_field) -{ - m_array_char_field = _array_char_field; -} - -/*! - * @brief This function moves the value in member array_char_field - * @param _array_char_field New value to be moved in member array_char_field - */ -void ContentFilterTestType::array_char_field( - std::array&& _array_char_field) -{ - m_array_char_field = std::move(_array_char_field); -} - -/*! - * @brief This function returns a constant reference to member array_char_field - * @return Constant reference to member array_char_field - */ -const std::array& ContentFilterTestType::array_char_field() const -{ - return m_array_char_field; -} - -/*! - * @brief This function returns a reference to member array_char_field - * @return Reference to member array_char_field - */ -std::array& ContentFilterTestType::array_char_field() -{ - return m_array_char_field; -} - - -/*! - * @brief This function copies the value in member array_uint8_field - * @param _array_uint8_field New value to be copied in member array_uint8_field - */ -void ContentFilterTestType::array_uint8_field( - const std::array& _array_uint8_field) -{ - m_array_uint8_field = _array_uint8_field; -} - -/*! - * @brief This function moves the value in member array_uint8_field - * @param _array_uint8_field New value to be moved in member array_uint8_field - */ -void ContentFilterTestType::array_uint8_field( - std::array&& _array_uint8_field) -{ - m_array_uint8_field = std::move(_array_uint8_field); -} - -/*! - * @brief This function returns a constant reference to member array_uint8_field - * @return Constant reference to member array_uint8_field - */ -const std::array& ContentFilterTestType::array_uint8_field() const -{ - return m_array_uint8_field; -} - -/*! - * @brief This function returns a reference to member array_uint8_field - * @return Reference to member array_uint8_field - */ -std::array& ContentFilterTestType::array_uint8_field() -{ - return m_array_uint8_field; -} - - -/*! - * @brief This function copies the value in member array_int16_field - * @param _array_int16_field New value to be copied in member array_int16_field - */ -void ContentFilterTestType::array_int16_field( - const std::array& _array_int16_field) -{ - m_array_int16_field = _array_int16_field; -} - -/*! - * @brief This function moves the value in member array_int16_field - * @param _array_int16_field New value to be moved in member array_int16_field - */ -void ContentFilterTestType::array_int16_field( - std::array&& _array_int16_field) -{ - m_array_int16_field = std::move(_array_int16_field); -} - -/*! - * @brief This function returns a constant reference to member array_int16_field - * @return Constant reference to member array_int16_field - */ -const std::array& ContentFilterTestType::array_int16_field() const -{ - return m_array_int16_field; -} - -/*! - * @brief This function returns a reference to member array_int16_field - * @return Reference to member array_int16_field - */ -std::array& ContentFilterTestType::array_int16_field() -{ - return m_array_int16_field; -} - - -/*! - * @brief This function copies the value in member array_uint16_field - * @param _array_uint16_field New value to be copied in member array_uint16_field - */ -void ContentFilterTestType::array_uint16_field( - const std::array& _array_uint16_field) -{ - m_array_uint16_field = _array_uint16_field; -} - -/*! - * @brief This function moves the value in member array_uint16_field - * @param _array_uint16_field New value to be moved in member array_uint16_field - */ -void ContentFilterTestType::array_uint16_field( - std::array&& _array_uint16_field) -{ - m_array_uint16_field = std::move(_array_uint16_field); -} - -/*! - * @brief This function returns a constant reference to member array_uint16_field - * @return Constant reference to member array_uint16_field - */ -const std::array& ContentFilterTestType::array_uint16_field() const -{ - return m_array_uint16_field; -} - -/*! - * @brief This function returns a reference to member array_uint16_field - * @return Reference to member array_uint16_field - */ -std::array& ContentFilterTestType::array_uint16_field() -{ - return m_array_uint16_field; -} - - -/*! - * @brief This function copies the value in member array_int32_field - * @param _array_int32_field New value to be copied in member array_int32_field - */ -void ContentFilterTestType::array_int32_field( - const std::array& _array_int32_field) -{ - m_array_int32_field = _array_int32_field; -} - -/*! - * @brief This function moves the value in member array_int32_field - * @param _array_int32_field New value to be moved in member array_int32_field - */ -void ContentFilterTestType::array_int32_field( - std::array&& _array_int32_field) -{ - m_array_int32_field = std::move(_array_int32_field); -} - -/*! - * @brief This function returns a constant reference to member array_int32_field - * @return Constant reference to member array_int32_field - */ -const std::array& ContentFilterTestType::array_int32_field() const -{ - return m_array_int32_field; -} - -/*! - * @brief This function returns a reference to member array_int32_field - * @return Reference to member array_int32_field - */ -std::array& ContentFilterTestType::array_int32_field() -{ - return m_array_int32_field; -} - - -/*! - * @brief This function copies the value in member array_uint32_field - * @param _array_uint32_field New value to be copied in member array_uint32_field - */ -void ContentFilterTestType::array_uint32_field( - const std::array& _array_uint32_field) -{ - m_array_uint32_field = _array_uint32_field; -} - -/*! - * @brief This function moves the value in member array_uint32_field - * @param _array_uint32_field New value to be moved in member array_uint32_field - */ -void ContentFilterTestType::array_uint32_field( - std::array&& _array_uint32_field) -{ - m_array_uint32_field = std::move(_array_uint32_field); -} - -/*! - * @brief This function returns a constant reference to member array_uint32_field - * @return Constant reference to member array_uint32_field - */ -const std::array& ContentFilterTestType::array_uint32_field() const -{ - return m_array_uint32_field; -} - -/*! - * @brief This function returns a reference to member array_uint32_field - * @return Reference to member array_uint32_field - */ -std::array& ContentFilterTestType::array_uint32_field() -{ - return m_array_uint32_field; -} - - -/*! - * @brief This function copies the value in member array_int64_field - * @param _array_int64_field New value to be copied in member array_int64_field - */ -void ContentFilterTestType::array_int64_field( - const std::array& _array_int64_field) -{ - m_array_int64_field = _array_int64_field; -} - -/*! - * @brief This function moves the value in member array_int64_field - * @param _array_int64_field New value to be moved in member array_int64_field - */ -void ContentFilterTestType::array_int64_field( - std::array&& _array_int64_field) -{ - m_array_int64_field = std::move(_array_int64_field); -} - -/*! - * @brief This function returns a constant reference to member array_int64_field - * @return Constant reference to member array_int64_field - */ -const std::array& ContentFilterTestType::array_int64_field() const -{ - return m_array_int64_field; -} - -/*! - * @brief This function returns a reference to member array_int64_field - * @return Reference to member array_int64_field - */ -std::array& ContentFilterTestType::array_int64_field() -{ - return m_array_int64_field; -} - - -/*! - * @brief This function copies the value in member array_uint64_field - * @param _array_uint64_field New value to be copied in member array_uint64_field - */ -void ContentFilterTestType::array_uint64_field( - const std::array& _array_uint64_field) -{ - m_array_uint64_field = _array_uint64_field; -} - -/*! - * @brief This function moves the value in member array_uint64_field - * @param _array_uint64_field New value to be moved in member array_uint64_field - */ -void ContentFilterTestType::array_uint64_field( - std::array&& _array_uint64_field) -{ - m_array_uint64_field = std::move(_array_uint64_field); -} - -/*! - * @brief This function returns a constant reference to member array_uint64_field - * @return Constant reference to member array_uint64_field - */ -const std::array& ContentFilterTestType::array_uint64_field() const -{ - return m_array_uint64_field; -} - -/*! - * @brief This function returns a reference to member array_uint64_field - * @return Reference to member array_uint64_field - */ -std::array& ContentFilterTestType::array_uint64_field() -{ - return m_array_uint64_field; -} - - -/*! - * @brief This function copies the value in member array_float_field - * @param _array_float_field New value to be copied in member array_float_field - */ -void ContentFilterTestType::array_float_field( - const std::array& _array_float_field) -{ - m_array_float_field = _array_float_field; -} - -/*! - * @brief This function moves the value in member array_float_field - * @param _array_float_field New value to be moved in member array_float_field - */ -void ContentFilterTestType::array_float_field( - std::array&& _array_float_field) -{ - m_array_float_field = std::move(_array_float_field); -} - -/*! - * @brief This function returns a constant reference to member array_float_field - * @return Constant reference to member array_float_field - */ -const std::array& ContentFilterTestType::array_float_field() const -{ - return m_array_float_field; -} - -/*! - * @brief This function returns a reference to member array_float_field - * @return Reference to member array_float_field - */ -std::array& ContentFilterTestType::array_float_field() -{ - return m_array_float_field; -} - - -/*! - * @brief This function copies the value in member array_double_field - * @param _array_double_field New value to be copied in member array_double_field - */ -void ContentFilterTestType::array_double_field( - const std::array& _array_double_field) -{ - m_array_double_field = _array_double_field; -} - -/*! - * @brief This function moves the value in member array_double_field - * @param _array_double_field New value to be moved in member array_double_field - */ -void ContentFilterTestType::array_double_field( - std::array&& _array_double_field) -{ - m_array_double_field = std::move(_array_double_field); -} - -/*! - * @brief This function returns a constant reference to member array_double_field - * @return Constant reference to member array_double_field - */ -const std::array& ContentFilterTestType::array_double_field() const -{ - return m_array_double_field; -} - -/*! - * @brief This function returns a reference to member array_double_field - * @return Reference to member array_double_field - */ -std::array& ContentFilterTestType::array_double_field() -{ - return m_array_double_field; -} - - -/*! - * @brief This function copies the value in member array_long_double_field - * @param _array_long_double_field New value to be copied in member array_long_double_field - */ -void ContentFilterTestType::array_long_double_field( - const std::array& _array_long_double_field) -{ - m_array_long_double_field = _array_long_double_field; -} - -/*! - * @brief This function moves the value in member array_long_double_field - * @param _array_long_double_field New value to be moved in member array_long_double_field - */ -void ContentFilterTestType::array_long_double_field( - std::array&& _array_long_double_field) -{ - m_array_long_double_field = std::move(_array_long_double_field); -} - -/*! - * @brief This function returns a constant reference to member array_long_double_field - * @return Constant reference to member array_long_double_field - */ -const std::array& ContentFilterTestType::array_long_double_field() const -{ - return m_array_long_double_field; -} - -/*! - * @brief This function returns a reference to member array_long_double_field - * @return Reference to member array_long_double_field - */ -std::array& ContentFilterTestType::array_long_double_field() -{ - return m_array_long_double_field; -} - - -/*! - * @brief This function copies the value in member array_bool_field - * @param _array_bool_field New value to be copied in member array_bool_field - */ -void ContentFilterTestType::array_bool_field( - const std::array& _array_bool_field) -{ - m_array_bool_field = _array_bool_field; -} - -/*! - * @brief This function moves the value in member array_bool_field - * @param _array_bool_field New value to be moved in member array_bool_field - */ -void ContentFilterTestType::array_bool_field( - std::array&& _array_bool_field) -{ - m_array_bool_field = std::move(_array_bool_field); -} - -/*! - * @brief This function returns a constant reference to member array_bool_field - * @return Constant reference to member array_bool_field - */ -const std::array& ContentFilterTestType::array_bool_field() const -{ - return m_array_bool_field; -} - -/*! - * @brief This function returns a reference to member array_bool_field - * @return Reference to member array_bool_field - */ -std::array& ContentFilterTestType::array_bool_field() -{ - return m_array_bool_field; -} - - -/*! - * @brief This function copies the value in member array_string_field - * @param _array_string_field New value to be copied in member array_string_field - */ -void ContentFilterTestType::array_string_field( - const std::array& _array_string_field) -{ - m_array_string_field = _array_string_field; -} - -/*! - * @brief This function moves the value in member array_string_field - * @param _array_string_field New value to be moved in member array_string_field - */ -void ContentFilterTestType::array_string_field( - std::array&& _array_string_field) -{ - m_array_string_field = std::move(_array_string_field); -} - -/*! - * @brief This function returns a constant reference to member array_string_field - * @return Constant reference to member array_string_field - */ -const std::array& ContentFilterTestType::array_string_field() const -{ - return m_array_string_field; -} - -/*! - * @brief This function returns a reference to member array_string_field - * @return Reference to member array_string_field - */ -std::array& ContentFilterTestType::array_string_field() -{ - return m_array_string_field; -} - - -/*! - * @brief This function copies the value in member array_enum_field - * @param _array_enum_field New value to be copied in member array_enum_field - */ -void ContentFilterTestType::array_enum_field( - const std::array& _array_enum_field) -{ - m_array_enum_field = _array_enum_field; -} - -/*! - * @brief This function moves the value in member array_enum_field - * @param _array_enum_field New value to be moved in member array_enum_field - */ -void ContentFilterTestType::array_enum_field( - std::array&& _array_enum_field) -{ - m_array_enum_field = std::move(_array_enum_field); -} - -/*! - * @brief This function returns a constant reference to member array_enum_field - * @return Constant reference to member array_enum_field - */ -const std::array& ContentFilterTestType::array_enum_field() const -{ - return m_array_enum_field; -} - -/*! - * @brief This function returns a reference to member array_enum_field - * @return Reference to member array_enum_field - */ -std::array& ContentFilterTestType::array_enum_field() -{ - return m_array_enum_field; -} - - -/*! - * @brief This function copies the value in member array_enum2_field - * @param _array_enum2_field New value to be copied in member array_enum2_field - */ -void ContentFilterTestType::array_enum2_field( - const std::array& _array_enum2_field) -{ - m_array_enum2_field = _array_enum2_field; -} - -/*! - * @brief This function moves the value in member array_enum2_field - * @param _array_enum2_field New value to be moved in member array_enum2_field - */ -void ContentFilterTestType::array_enum2_field( - std::array&& _array_enum2_field) -{ - m_array_enum2_field = std::move(_array_enum2_field); -} - -/*! - * @brief This function returns a constant reference to member array_enum2_field - * @return Constant reference to member array_enum2_field - */ -const std::array& ContentFilterTestType::array_enum2_field() const -{ - return m_array_enum2_field; -} - -/*! - * @brief This function returns a reference to member array_enum2_field - * @return Reference to member array_enum2_field - */ -std::array& ContentFilterTestType::array_enum2_field() -{ - return m_array_enum2_field; -} - - -/*! - * @brief This function copies the value in member array_struct_field - * @param _array_struct_field New value to be copied in member array_struct_field - */ -void ContentFilterTestType::array_struct_field( - const std::array& _array_struct_field) -{ - m_array_struct_field = _array_struct_field; -} - -/*! - * @brief This function moves the value in member array_struct_field - * @param _array_struct_field New value to be moved in member array_struct_field - */ -void ContentFilterTestType::array_struct_field( - std::array&& _array_struct_field) -{ - m_array_struct_field = std::move(_array_struct_field); -} - -/*! - * @brief This function returns a constant reference to member array_struct_field - * @return Constant reference to member array_struct_field - */ -const std::array& ContentFilterTestType::array_struct_field() const -{ - return m_array_struct_field; -} - -/*! - * @brief This function returns a reference to member array_struct_field - * @return Reference to member array_struct_field - */ -std::array& ContentFilterTestType::array_struct_field() -{ - return m_array_struct_field; -} - - -/*! - * @brief This function copies the value in member bounded_sequence_char_field - * @param _bounded_sequence_char_field New value to be copied in member bounded_sequence_char_field - */ -void ContentFilterTestType::bounded_sequence_char_field( - const std::vector& _bounded_sequence_char_field) -{ - m_bounded_sequence_char_field = _bounded_sequence_char_field; -} - -/*! - * @brief This function moves the value in member bounded_sequence_char_field - * @param _bounded_sequence_char_field New value to be moved in member bounded_sequence_char_field - */ -void ContentFilterTestType::bounded_sequence_char_field( - std::vector&& _bounded_sequence_char_field) -{ - m_bounded_sequence_char_field = std::move(_bounded_sequence_char_field); -} - -/*! - * @brief This function returns a constant reference to member bounded_sequence_char_field - * @return Constant reference to member bounded_sequence_char_field - */ -const std::vector& ContentFilterTestType::bounded_sequence_char_field() const -{ - return m_bounded_sequence_char_field; -} - -/*! - * @brief This function returns a reference to member bounded_sequence_char_field - * @return Reference to member bounded_sequence_char_field - */ -std::vector& ContentFilterTestType::bounded_sequence_char_field() -{ - return m_bounded_sequence_char_field; -} - - -/*! - * @brief This function copies the value in member bounded_sequence_uint8_field - * @param _bounded_sequence_uint8_field New value to be copied in member bounded_sequence_uint8_field - */ -void ContentFilterTestType::bounded_sequence_uint8_field( - const std::vector& _bounded_sequence_uint8_field) -{ - m_bounded_sequence_uint8_field = _bounded_sequence_uint8_field; -} - -/*! - * @brief This function moves the value in member bounded_sequence_uint8_field - * @param _bounded_sequence_uint8_field New value to be moved in member bounded_sequence_uint8_field - */ -void ContentFilterTestType::bounded_sequence_uint8_field( - std::vector&& _bounded_sequence_uint8_field) -{ - m_bounded_sequence_uint8_field = std::move(_bounded_sequence_uint8_field); -} - -/*! - * @brief This function returns a constant reference to member bounded_sequence_uint8_field - * @return Constant reference to member bounded_sequence_uint8_field - */ -const std::vector& ContentFilterTestType::bounded_sequence_uint8_field() const -{ - return m_bounded_sequence_uint8_field; -} - -/*! - * @brief This function returns a reference to member bounded_sequence_uint8_field - * @return Reference to member bounded_sequence_uint8_field - */ -std::vector& ContentFilterTestType::bounded_sequence_uint8_field() -{ - return m_bounded_sequence_uint8_field; -} - - -/*! - * @brief This function copies the value in member bounded_sequence_int16_field - * @param _bounded_sequence_int16_field New value to be copied in member bounded_sequence_int16_field - */ -void ContentFilterTestType::bounded_sequence_int16_field( - const std::vector& _bounded_sequence_int16_field) -{ - m_bounded_sequence_int16_field = _bounded_sequence_int16_field; -} - -/*! - * @brief This function moves the value in member bounded_sequence_int16_field - * @param _bounded_sequence_int16_field New value to be moved in member bounded_sequence_int16_field - */ -void ContentFilterTestType::bounded_sequence_int16_field( - std::vector&& _bounded_sequence_int16_field) -{ - m_bounded_sequence_int16_field = std::move(_bounded_sequence_int16_field); -} - -/*! - * @brief This function returns a constant reference to member bounded_sequence_int16_field - * @return Constant reference to member bounded_sequence_int16_field - */ -const std::vector& ContentFilterTestType::bounded_sequence_int16_field() const -{ - return m_bounded_sequence_int16_field; -} - -/*! - * @brief This function returns a reference to member bounded_sequence_int16_field - * @return Reference to member bounded_sequence_int16_field - */ -std::vector& ContentFilterTestType::bounded_sequence_int16_field() -{ - return m_bounded_sequence_int16_field; -} - - -/*! - * @brief This function copies the value in member bounded_sequence_uint16_field - * @param _bounded_sequence_uint16_field New value to be copied in member bounded_sequence_uint16_field - */ -void ContentFilterTestType::bounded_sequence_uint16_field( - const std::vector& _bounded_sequence_uint16_field) -{ - m_bounded_sequence_uint16_field = _bounded_sequence_uint16_field; -} - -/*! - * @brief This function moves the value in member bounded_sequence_uint16_field - * @param _bounded_sequence_uint16_field New value to be moved in member bounded_sequence_uint16_field - */ -void ContentFilterTestType::bounded_sequence_uint16_field( - std::vector&& _bounded_sequence_uint16_field) -{ - m_bounded_sequence_uint16_field = std::move(_bounded_sequence_uint16_field); -} - -/*! - * @brief This function returns a constant reference to member bounded_sequence_uint16_field - * @return Constant reference to member bounded_sequence_uint16_field - */ -const std::vector& ContentFilterTestType::bounded_sequence_uint16_field() const -{ - return m_bounded_sequence_uint16_field; -} - -/*! - * @brief This function returns a reference to member bounded_sequence_uint16_field - * @return Reference to member bounded_sequence_uint16_field - */ -std::vector& ContentFilterTestType::bounded_sequence_uint16_field() -{ - return m_bounded_sequence_uint16_field; -} - - -/*! - * @brief This function copies the value in member bounded_sequence_int32_field - * @param _bounded_sequence_int32_field New value to be copied in member bounded_sequence_int32_field - */ -void ContentFilterTestType::bounded_sequence_int32_field( - const std::vector& _bounded_sequence_int32_field) -{ - m_bounded_sequence_int32_field = _bounded_sequence_int32_field; -} - -/*! - * @brief This function moves the value in member bounded_sequence_int32_field - * @param _bounded_sequence_int32_field New value to be moved in member bounded_sequence_int32_field - */ -void ContentFilterTestType::bounded_sequence_int32_field( - std::vector&& _bounded_sequence_int32_field) -{ - m_bounded_sequence_int32_field = std::move(_bounded_sequence_int32_field); -} - -/*! - * @brief This function returns a constant reference to member bounded_sequence_int32_field - * @return Constant reference to member bounded_sequence_int32_field - */ -const std::vector& ContentFilterTestType::bounded_sequence_int32_field() const -{ - return m_bounded_sequence_int32_field; -} - -/*! - * @brief This function returns a reference to member bounded_sequence_int32_field - * @return Reference to member bounded_sequence_int32_field - */ -std::vector& ContentFilterTestType::bounded_sequence_int32_field() -{ - return m_bounded_sequence_int32_field; -} - - -/*! - * @brief This function copies the value in member bounded_sequence_uint32_field - * @param _bounded_sequence_uint32_field New value to be copied in member bounded_sequence_uint32_field - */ -void ContentFilterTestType::bounded_sequence_uint32_field( - const std::vector& _bounded_sequence_uint32_field) -{ - m_bounded_sequence_uint32_field = _bounded_sequence_uint32_field; -} - -/*! - * @brief This function moves the value in member bounded_sequence_uint32_field - * @param _bounded_sequence_uint32_field New value to be moved in member bounded_sequence_uint32_field - */ -void ContentFilterTestType::bounded_sequence_uint32_field( - std::vector&& _bounded_sequence_uint32_field) -{ - m_bounded_sequence_uint32_field = std::move(_bounded_sequence_uint32_field); -} - -/*! - * @brief This function returns a constant reference to member bounded_sequence_uint32_field - * @return Constant reference to member bounded_sequence_uint32_field - */ -const std::vector& ContentFilterTestType::bounded_sequence_uint32_field() const -{ - return m_bounded_sequence_uint32_field; -} - -/*! - * @brief This function returns a reference to member bounded_sequence_uint32_field - * @return Reference to member bounded_sequence_uint32_field - */ -std::vector& ContentFilterTestType::bounded_sequence_uint32_field() -{ - return m_bounded_sequence_uint32_field; -} - - -/*! - * @brief This function copies the value in member bounded_sequence_int64_field - * @param _bounded_sequence_int64_field New value to be copied in member bounded_sequence_int64_field - */ -void ContentFilterTestType::bounded_sequence_int64_field( - const std::vector& _bounded_sequence_int64_field) -{ - m_bounded_sequence_int64_field = _bounded_sequence_int64_field; -} - -/*! - * @brief This function moves the value in member bounded_sequence_int64_field - * @param _bounded_sequence_int64_field New value to be moved in member bounded_sequence_int64_field - */ -void ContentFilterTestType::bounded_sequence_int64_field( - std::vector&& _bounded_sequence_int64_field) -{ - m_bounded_sequence_int64_field = std::move(_bounded_sequence_int64_field); -} - -/*! - * @brief This function returns a constant reference to member bounded_sequence_int64_field - * @return Constant reference to member bounded_sequence_int64_field - */ -const std::vector& ContentFilterTestType::bounded_sequence_int64_field() const -{ - return m_bounded_sequence_int64_field; -} - -/*! - * @brief This function returns a reference to member bounded_sequence_int64_field - * @return Reference to member bounded_sequence_int64_field - */ -std::vector& ContentFilterTestType::bounded_sequence_int64_field() -{ - return m_bounded_sequence_int64_field; -} - - -/*! - * @brief This function copies the value in member bounded_sequence_uint64_field - * @param _bounded_sequence_uint64_field New value to be copied in member bounded_sequence_uint64_field - */ -void ContentFilterTestType::bounded_sequence_uint64_field( - const std::vector& _bounded_sequence_uint64_field) -{ - m_bounded_sequence_uint64_field = _bounded_sequence_uint64_field; -} - -/*! - * @brief This function moves the value in member bounded_sequence_uint64_field - * @param _bounded_sequence_uint64_field New value to be moved in member bounded_sequence_uint64_field - */ -void ContentFilterTestType::bounded_sequence_uint64_field( - std::vector&& _bounded_sequence_uint64_field) -{ - m_bounded_sequence_uint64_field = std::move(_bounded_sequence_uint64_field); -} - -/*! - * @brief This function returns a constant reference to member bounded_sequence_uint64_field - * @return Constant reference to member bounded_sequence_uint64_field - */ -const std::vector& ContentFilterTestType::bounded_sequence_uint64_field() const -{ - return m_bounded_sequence_uint64_field; -} - -/*! - * @brief This function returns a reference to member bounded_sequence_uint64_field - * @return Reference to member bounded_sequence_uint64_field - */ -std::vector& ContentFilterTestType::bounded_sequence_uint64_field() -{ - return m_bounded_sequence_uint64_field; -} - - -/*! - * @brief This function copies the value in member bounded_sequence_float_field - * @param _bounded_sequence_float_field New value to be copied in member bounded_sequence_float_field - */ -void ContentFilterTestType::bounded_sequence_float_field( - const std::vector& _bounded_sequence_float_field) -{ - m_bounded_sequence_float_field = _bounded_sequence_float_field; -} - -/*! - * @brief This function moves the value in member bounded_sequence_float_field - * @param _bounded_sequence_float_field New value to be moved in member bounded_sequence_float_field - */ -void ContentFilterTestType::bounded_sequence_float_field( - std::vector&& _bounded_sequence_float_field) -{ - m_bounded_sequence_float_field = std::move(_bounded_sequence_float_field); -} - -/*! - * @brief This function returns a constant reference to member bounded_sequence_float_field - * @return Constant reference to member bounded_sequence_float_field - */ -const std::vector& ContentFilterTestType::bounded_sequence_float_field() const -{ - return m_bounded_sequence_float_field; -} - -/*! - * @brief This function returns a reference to member bounded_sequence_float_field - * @return Reference to member bounded_sequence_float_field - */ -std::vector& ContentFilterTestType::bounded_sequence_float_field() -{ - return m_bounded_sequence_float_field; -} - - -/*! - * @brief This function copies the value in member bounded_sequence_double_field - * @param _bounded_sequence_double_field New value to be copied in member bounded_sequence_double_field - */ -void ContentFilterTestType::bounded_sequence_double_field( - const std::vector& _bounded_sequence_double_field) -{ - m_bounded_sequence_double_field = _bounded_sequence_double_field; -} - -/*! - * @brief This function moves the value in member bounded_sequence_double_field - * @param _bounded_sequence_double_field New value to be moved in member bounded_sequence_double_field - */ -void ContentFilterTestType::bounded_sequence_double_field( - std::vector&& _bounded_sequence_double_field) -{ - m_bounded_sequence_double_field = std::move(_bounded_sequence_double_field); -} - -/*! - * @brief This function returns a constant reference to member bounded_sequence_double_field - * @return Constant reference to member bounded_sequence_double_field - */ -const std::vector& ContentFilterTestType::bounded_sequence_double_field() const -{ - return m_bounded_sequence_double_field; -} - -/*! - * @brief This function returns a reference to member bounded_sequence_double_field - * @return Reference to member bounded_sequence_double_field - */ -std::vector& ContentFilterTestType::bounded_sequence_double_field() -{ - return m_bounded_sequence_double_field; -} - - -/*! - * @brief This function copies the value in member bounded_sequence_long_double_field - * @param _bounded_sequence_long_double_field New value to be copied in member bounded_sequence_long_double_field - */ -void ContentFilterTestType::bounded_sequence_long_double_field( - const std::vector& _bounded_sequence_long_double_field) -{ - m_bounded_sequence_long_double_field = _bounded_sequence_long_double_field; -} - -/*! - * @brief This function moves the value in member bounded_sequence_long_double_field - * @param _bounded_sequence_long_double_field New value to be moved in member bounded_sequence_long_double_field - */ -void ContentFilterTestType::bounded_sequence_long_double_field( - std::vector&& _bounded_sequence_long_double_field) -{ - m_bounded_sequence_long_double_field = std::move(_bounded_sequence_long_double_field); -} - -/*! - * @brief This function returns a constant reference to member bounded_sequence_long_double_field - * @return Constant reference to member bounded_sequence_long_double_field - */ -const std::vector& ContentFilterTestType::bounded_sequence_long_double_field() const -{ - return m_bounded_sequence_long_double_field; -} - -/*! - * @brief This function returns a reference to member bounded_sequence_long_double_field - * @return Reference to member bounded_sequence_long_double_field - */ -std::vector& ContentFilterTestType::bounded_sequence_long_double_field() -{ - return m_bounded_sequence_long_double_field; -} - - -/*! - * @brief This function copies the value in member bounded_sequence_bool_field - * @param _bounded_sequence_bool_field New value to be copied in member bounded_sequence_bool_field - */ -void ContentFilterTestType::bounded_sequence_bool_field( - const std::vector& _bounded_sequence_bool_field) -{ - m_bounded_sequence_bool_field = _bounded_sequence_bool_field; -} - -/*! - * @brief This function moves the value in member bounded_sequence_bool_field - * @param _bounded_sequence_bool_field New value to be moved in member bounded_sequence_bool_field - */ -void ContentFilterTestType::bounded_sequence_bool_field( - std::vector&& _bounded_sequence_bool_field) -{ - m_bounded_sequence_bool_field = std::move(_bounded_sequence_bool_field); -} - -/*! - * @brief This function returns a constant reference to member bounded_sequence_bool_field - * @return Constant reference to member bounded_sequence_bool_field - */ -const std::vector& ContentFilterTestType::bounded_sequence_bool_field() const -{ - return m_bounded_sequence_bool_field; -} - -/*! - * @brief This function returns a reference to member bounded_sequence_bool_field - * @return Reference to member bounded_sequence_bool_field - */ -std::vector& ContentFilterTestType::bounded_sequence_bool_field() -{ - return m_bounded_sequence_bool_field; -} - - -/*! - * @brief This function copies the value in member bounded_sequence_string_field - * @param _bounded_sequence_string_field New value to be copied in member bounded_sequence_string_field - */ -void ContentFilterTestType::bounded_sequence_string_field( - const std::vector& _bounded_sequence_string_field) -{ - m_bounded_sequence_string_field = _bounded_sequence_string_field; -} - -/*! - * @brief This function moves the value in member bounded_sequence_string_field - * @param _bounded_sequence_string_field New value to be moved in member bounded_sequence_string_field - */ -void ContentFilterTestType::bounded_sequence_string_field( - std::vector&& _bounded_sequence_string_field) -{ - m_bounded_sequence_string_field = std::move(_bounded_sequence_string_field); -} - -/*! - * @brief This function returns a constant reference to member bounded_sequence_string_field - * @return Constant reference to member bounded_sequence_string_field - */ -const std::vector& ContentFilterTestType::bounded_sequence_string_field() const -{ - return m_bounded_sequence_string_field; -} - -/*! - * @brief This function returns a reference to member bounded_sequence_string_field - * @return Reference to member bounded_sequence_string_field - */ -std::vector& ContentFilterTestType::bounded_sequence_string_field() -{ - return m_bounded_sequence_string_field; -} - - -/*! - * @brief This function copies the value in member bounded_sequence_enum_field - * @param _bounded_sequence_enum_field New value to be copied in member bounded_sequence_enum_field - */ -void ContentFilterTestType::bounded_sequence_enum_field( - const std::vector& _bounded_sequence_enum_field) -{ - m_bounded_sequence_enum_field = _bounded_sequence_enum_field; -} - -/*! - * @brief This function moves the value in member bounded_sequence_enum_field - * @param _bounded_sequence_enum_field New value to be moved in member bounded_sequence_enum_field - */ -void ContentFilterTestType::bounded_sequence_enum_field( - std::vector&& _bounded_sequence_enum_field) -{ - m_bounded_sequence_enum_field = std::move(_bounded_sequence_enum_field); -} - -/*! - * @brief This function returns a constant reference to member bounded_sequence_enum_field - * @return Constant reference to member bounded_sequence_enum_field - */ -const std::vector& ContentFilterTestType::bounded_sequence_enum_field() const -{ - return m_bounded_sequence_enum_field; -} - -/*! - * @brief This function returns a reference to member bounded_sequence_enum_field - * @return Reference to member bounded_sequence_enum_field - */ -std::vector& ContentFilterTestType::bounded_sequence_enum_field() -{ - return m_bounded_sequence_enum_field; -} - - -/*! - * @brief This function copies the value in member bounded_sequence_enum2_field - * @param _bounded_sequence_enum2_field New value to be copied in member bounded_sequence_enum2_field - */ -void ContentFilterTestType::bounded_sequence_enum2_field( - const std::vector& _bounded_sequence_enum2_field) -{ - m_bounded_sequence_enum2_field = _bounded_sequence_enum2_field; -} - -/*! - * @brief This function moves the value in member bounded_sequence_enum2_field - * @param _bounded_sequence_enum2_field New value to be moved in member bounded_sequence_enum2_field - */ -void ContentFilterTestType::bounded_sequence_enum2_field( - std::vector&& _bounded_sequence_enum2_field) -{ - m_bounded_sequence_enum2_field = std::move(_bounded_sequence_enum2_field); -} - -/*! - * @brief This function returns a constant reference to member bounded_sequence_enum2_field - * @return Constant reference to member bounded_sequence_enum2_field - */ -const std::vector& ContentFilterTestType::bounded_sequence_enum2_field() const -{ - return m_bounded_sequence_enum2_field; -} - -/*! - * @brief This function returns a reference to member bounded_sequence_enum2_field - * @return Reference to member bounded_sequence_enum2_field - */ -std::vector& ContentFilterTestType::bounded_sequence_enum2_field() -{ - return m_bounded_sequence_enum2_field; -} - - -/*! - * @brief This function copies the value in member bounded_sequence_struct_field - * @param _bounded_sequence_struct_field New value to be copied in member bounded_sequence_struct_field - */ -void ContentFilterTestType::bounded_sequence_struct_field( - const std::vector& _bounded_sequence_struct_field) -{ - m_bounded_sequence_struct_field = _bounded_sequence_struct_field; -} - -/*! - * @brief This function moves the value in member bounded_sequence_struct_field - * @param _bounded_sequence_struct_field New value to be moved in member bounded_sequence_struct_field - */ -void ContentFilterTestType::bounded_sequence_struct_field( - std::vector&& _bounded_sequence_struct_field) -{ - m_bounded_sequence_struct_field = std::move(_bounded_sequence_struct_field); -} - -/*! - * @brief This function returns a constant reference to member bounded_sequence_struct_field - * @return Constant reference to member bounded_sequence_struct_field - */ -const std::vector& ContentFilterTestType::bounded_sequence_struct_field() const -{ - return m_bounded_sequence_struct_field; -} - -/*! - * @brief This function returns a reference to member bounded_sequence_struct_field - * @return Reference to member bounded_sequence_struct_field - */ -std::vector& ContentFilterTestType::bounded_sequence_struct_field() -{ - return m_bounded_sequence_struct_field; -} - - -/*! - * @brief This function copies the value in member unbounded_sequence_char_field - * @param _unbounded_sequence_char_field New value to be copied in member unbounded_sequence_char_field - */ -void ContentFilterTestType::unbounded_sequence_char_field( - const std::vector& _unbounded_sequence_char_field) -{ - m_unbounded_sequence_char_field = _unbounded_sequence_char_field; -} - -/*! - * @brief This function moves the value in member unbounded_sequence_char_field - * @param _unbounded_sequence_char_field New value to be moved in member unbounded_sequence_char_field - */ -void ContentFilterTestType::unbounded_sequence_char_field( - std::vector&& _unbounded_sequence_char_field) -{ - m_unbounded_sequence_char_field = std::move(_unbounded_sequence_char_field); -} - -/*! - * @brief This function returns a constant reference to member unbounded_sequence_char_field - * @return Constant reference to member unbounded_sequence_char_field - */ -const std::vector& ContentFilterTestType::unbounded_sequence_char_field() const -{ - return m_unbounded_sequence_char_field; -} - -/*! - * @brief This function returns a reference to member unbounded_sequence_char_field - * @return Reference to member unbounded_sequence_char_field - */ -std::vector& ContentFilterTestType::unbounded_sequence_char_field() -{ - return m_unbounded_sequence_char_field; -} - - -/*! - * @brief This function copies the value in member unbounded_sequence_uint8_field - * @param _unbounded_sequence_uint8_field New value to be copied in member unbounded_sequence_uint8_field - */ -void ContentFilterTestType::unbounded_sequence_uint8_field( - const std::vector& _unbounded_sequence_uint8_field) -{ - m_unbounded_sequence_uint8_field = _unbounded_sequence_uint8_field; -} - -/*! - * @brief This function moves the value in member unbounded_sequence_uint8_field - * @param _unbounded_sequence_uint8_field New value to be moved in member unbounded_sequence_uint8_field - */ -void ContentFilterTestType::unbounded_sequence_uint8_field( - std::vector&& _unbounded_sequence_uint8_field) -{ - m_unbounded_sequence_uint8_field = std::move(_unbounded_sequence_uint8_field); -} - -/*! - * @brief This function returns a constant reference to member unbounded_sequence_uint8_field - * @return Constant reference to member unbounded_sequence_uint8_field - */ -const std::vector& ContentFilterTestType::unbounded_sequence_uint8_field() const -{ - return m_unbounded_sequence_uint8_field; -} - -/*! - * @brief This function returns a reference to member unbounded_sequence_uint8_field - * @return Reference to member unbounded_sequence_uint8_field - */ -std::vector& ContentFilterTestType::unbounded_sequence_uint8_field() -{ - return m_unbounded_sequence_uint8_field; -} - - -/*! - * @brief This function copies the value in member unbounded_sequence_int16_field - * @param _unbounded_sequence_int16_field New value to be copied in member unbounded_sequence_int16_field - */ -void ContentFilterTestType::unbounded_sequence_int16_field( - const std::vector& _unbounded_sequence_int16_field) -{ - m_unbounded_sequence_int16_field = _unbounded_sequence_int16_field; -} - -/*! - * @brief This function moves the value in member unbounded_sequence_int16_field - * @param _unbounded_sequence_int16_field New value to be moved in member unbounded_sequence_int16_field - */ -void ContentFilterTestType::unbounded_sequence_int16_field( - std::vector&& _unbounded_sequence_int16_field) -{ - m_unbounded_sequence_int16_field = std::move(_unbounded_sequence_int16_field); -} - -/*! - * @brief This function returns a constant reference to member unbounded_sequence_int16_field - * @return Constant reference to member unbounded_sequence_int16_field - */ -const std::vector& ContentFilterTestType::unbounded_sequence_int16_field() const -{ - return m_unbounded_sequence_int16_field; -} - -/*! - * @brief This function returns a reference to member unbounded_sequence_int16_field - * @return Reference to member unbounded_sequence_int16_field - */ -std::vector& ContentFilterTestType::unbounded_sequence_int16_field() -{ - return m_unbounded_sequence_int16_field; -} - - -/*! - * @brief This function copies the value in member unbounded_sequence_uint16_field - * @param _unbounded_sequence_uint16_field New value to be copied in member unbounded_sequence_uint16_field - */ -void ContentFilterTestType::unbounded_sequence_uint16_field( - const std::vector& _unbounded_sequence_uint16_field) -{ - m_unbounded_sequence_uint16_field = _unbounded_sequence_uint16_field; -} - -/*! - * @brief This function moves the value in member unbounded_sequence_uint16_field - * @param _unbounded_sequence_uint16_field New value to be moved in member unbounded_sequence_uint16_field - */ -void ContentFilterTestType::unbounded_sequence_uint16_field( - std::vector&& _unbounded_sequence_uint16_field) -{ - m_unbounded_sequence_uint16_field = std::move(_unbounded_sequence_uint16_field); -} - -/*! - * @brief This function returns a constant reference to member unbounded_sequence_uint16_field - * @return Constant reference to member unbounded_sequence_uint16_field - */ -const std::vector& ContentFilterTestType::unbounded_sequence_uint16_field() const -{ - return m_unbounded_sequence_uint16_field; -} - -/*! - * @brief This function returns a reference to member unbounded_sequence_uint16_field - * @return Reference to member unbounded_sequence_uint16_field - */ -std::vector& ContentFilterTestType::unbounded_sequence_uint16_field() -{ - return m_unbounded_sequence_uint16_field; -} - - -/*! - * @brief This function copies the value in member unbounded_sequence_int32_field - * @param _unbounded_sequence_int32_field New value to be copied in member unbounded_sequence_int32_field - */ -void ContentFilterTestType::unbounded_sequence_int32_field( - const std::vector& _unbounded_sequence_int32_field) -{ - m_unbounded_sequence_int32_field = _unbounded_sequence_int32_field; -} - -/*! - * @brief This function moves the value in member unbounded_sequence_int32_field - * @param _unbounded_sequence_int32_field New value to be moved in member unbounded_sequence_int32_field - */ -void ContentFilterTestType::unbounded_sequence_int32_field( - std::vector&& _unbounded_sequence_int32_field) -{ - m_unbounded_sequence_int32_field = std::move(_unbounded_sequence_int32_field); -} - -/*! - * @brief This function returns a constant reference to member unbounded_sequence_int32_field - * @return Constant reference to member unbounded_sequence_int32_field - */ -const std::vector& ContentFilterTestType::unbounded_sequence_int32_field() const -{ - return m_unbounded_sequence_int32_field; -} - -/*! - * @brief This function returns a reference to member unbounded_sequence_int32_field - * @return Reference to member unbounded_sequence_int32_field - */ -std::vector& ContentFilterTestType::unbounded_sequence_int32_field() -{ - return m_unbounded_sequence_int32_field; -} - - -/*! - * @brief This function copies the value in member unbounded_sequence_uint32_field - * @param _unbounded_sequence_uint32_field New value to be copied in member unbounded_sequence_uint32_field - */ -void ContentFilterTestType::unbounded_sequence_uint32_field( - const std::vector& _unbounded_sequence_uint32_field) -{ - m_unbounded_sequence_uint32_field = _unbounded_sequence_uint32_field; -} - -/*! - * @brief This function moves the value in member unbounded_sequence_uint32_field - * @param _unbounded_sequence_uint32_field New value to be moved in member unbounded_sequence_uint32_field - */ -void ContentFilterTestType::unbounded_sequence_uint32_field( - std::vector&& _unbounded_sequence_uint32_field) -{ - m_unbounded_sequence_uint32_field = std::move(_unbounded_sequence_uint32_field); -} - -/*! - * @brief This function returns a constant reference to member unbounded_sequence_uint32_field - * @return Constant reference to member unbounded_sequence_uint32_field - */ -const std::vector& ContentFilterTestType::unbounded_sequence_uint32_field() const -{ - return m_unbounded_sequence_uint32_field; -} - -/*! - * @brief This function returns a reference to member unbounded_sequence_uint32_field - * @return Reference to member unbounded_sequence_uint32_field - */ -std::vector& ContentFilterTestType::unbounded_sequence_uint32_field() -{ - return m_unbounded_sequence_uint32_field; -} - - -/*! - * @brief This function copies the value in member unbounded_sequence_int64_field - * @param _unbounded_sequence_int64_field New value to be copied in member unbounded_sequence_int64_field - */ -void ContentFilterTestType::unbounded_sequence_int64_field( - const std::vector& _unbounded_sequence_int64_field) -{ - m_unbounded_sequence_int64_field = _unbounded_sequence_int64_field; -} - -/*! - * @brief This function moves the value in member unbounded_sequence_int64_field - * @param _unbounded_sequence_int64_field New value to be moved in member unbounded_sequence_int64_field - */ -void ContentFilterTestType::unbounded_sequence_int64_field( - std::vector&& _unbounded_sequence_int64_field) -{ - m_unbounded_sequence_int64_field = std::move(_unbounded_sequence_int64_field); -} - -/*! - * @brief This function returns a constant reference to member unbounded_sequence_int64_field - * @return Constant reference to member unbounded_sequence_int64_field - */ -const std::vector& ContentFilterTestType::unbounded_sequence_int64_field() const -{ - return m_unbounded_sequence_int64_field; -} - -/*! - * @brief This function returns a reference to member unbounded_sequence_int64_field - * @return Reference to member unbounded_sequence_int64_field - */ -std::vector& ContentFilterTestType::unbounded_sequence_int64_field() -{ - return m_unbounded_sequence_int64_field; -} - - -/*! - * @brief This function copies the value in member unbounded_sequence_uint64_field - * @param _unbounded_sequence_uint64_field New value to be copied in member unbounded_sequence_uint64_field - */ -void ContentFilterTestType::unbounded_sequence_uint64_field( - const std::vector& _unbounded_sequence_uint64_field) -{ - m_unbounded_sequence_uint64_field = _unbounded_sequence_uint64_field; -} - -/*! - * @brief This function moves the value in member unbounded_sequence_uint64_field - * @param _unbounded_sequence_uint64_field New value to be moved in member unbounded_sequence_uint64_field - */ -void ContentFilterTestType::unbounded_sequence_uint64_field( - std::vector&& _unbounded_sequence_uint64_field) -{ - m_unbounded_sequence_uint64_field = std::move(_unbounded_sequence_uint64_field); -} - -/*! - * @brief This function returns a constant reference to member unbounded_sequence_uint64_field - * @return Constant reference to member unbounded_sequence_uint64_field - */ -const std::vector& ContentFilterTestType::unbounded_sequence_uint64_field() const -{ - return m_unbounded_sequence_uint64_field; -} - -/*! - * @brief This function returns a reference to member unbounded_sequence_uint64_field - * @return Reference to member unbounded_sequence_uint64_field - */ -std::vector& ContentFilterTestType::unbounded_sequence_uint64_field() -{ - return m_unbounded_sequence_uint64_field; -} - - -/*! - * @brief This function copies the value in member unbounded_sequence_float_field - * @param _unbounded_sequence_float_field New value to be copied in member unbounded_sequence_float_field - */ -void ContentFilterTestType::unbounded_sequence_float_field( - const std::vector& _unbounded_sequence_float_field) -{ - m_unbounded_sequence_float_field = _unbounded_sequence_float_field; -} - -/*! - * @brief This function moves the value in member unbounded_sequence_float_field - * @param _unbounded_sequence_float_field New value to be moved in member unbounded_sequence_float_field - */ -void ContentFilterTestType::unbounded_sequence_float_field( - std::vector&& _unbounded_sequence_float_field) -{ - m_unbounded_sequence_float_field = std::move(_unbounded_sequence_float_field); -} - -/*! - * @brief This function returns a constant reference to member unbounded_sequence_float_field - * @return Constant reference to member unbounded_sequence_float_field - */ -const std::vector& ContentFilterTestType::unbounded_sequence_float_field() const -{ - return m_unbounded_sequence_float_field; -} - -/*! - * @brief This function returns a reference to member unbounded_sequence_float_field - * @return Reference to member unbounded_sequence_float_field - */ -std::vector& ContentFilterTestType::unbounded_sequence_float_field() -{ - return m_unbounded_sequence_float_field; -} - - -/*! - * @brief This function copies the value in member unbounded_sequence_double_field - * @param _unbounded_sequence_double_field New value to be copied in member unbounded_sequence_double_field - */ -void ContentFilterTestType::unbounded_sequence_double_field( - const std::vector& _unbounded_sequence_double_field) -{ - m_unbounded_sequence_double_field = _unbounded_sequence_double_field; -} - -/*! - * @brief This function moves the value in member unbounded_sequence_double_field - * @param _unbounded_sequence_double_field New value to be moved in member unbounded_sequence_double_field - */ -void ContentFilterTestType::unbounded_sequence_double_field( - std::vector&& _unbounded_sequence_double_field) -{ - m_unbounded_sequence_double_field = std::move(_unbounded_sequence_double_field); -} - -/*! - * @brief This function returns a constant reference to member unbounded_sequence_double_field - * @return Constant reference to member unbounded_sequence_double_field - */ -const std::vector& ContentFilterTestType::unbounded_sequence_double_field() const -{ - return m_unbounded_sequence_double_field; -} - -/*! - * @brief This function returns a reference to member unbounded_sequence_double_field - * @return Reference to member unbounded_sequence_double_field - */ -std::vector& ContentFilterTestType::unbounded_sequence_double_field() -{ - return m_unbounded_sequence_double_field; -} - - -/*! - * @brief This function copies the value in member unbounded_sequence_long_double_field - * @param _unbounded_sequence_long_double_field New value to be copied in member unbounded_sequence_long_double_field - */ -void ContentFilterTestType::unbounded_sequence_long_double_field( - const std::vector& _unbounded_sequence_long_double_field) -{ - m_unbounded_sequence_long_double_field = _unbounded_sequence_long_double_field; -} - -/*! - * @brief This function moves the value in member unbounded_sequence_long_double_field - * @param _unbounded_sequence_long_double_field New value to be moved in member unbounded_sequence_long_double_field - */ -void ContentFilterTestType::unbounded_sequence_long_double_field( - std::vector&& _unbounded_sequence_long_double_field) -{ - m_unbounded_sequence_long_double_field = std::move(_unbounded_sequence_long_double_field); -} - -/*! - * @brief This function returns a constant reference to member unbounded_sequence_long_double_field - * @return Constant reference to member unbounded_sequence_long_double_field - */ -const std::vector& ContentFilterTestType::unbounded_sequence_long_double_field() const -{ - return m_unbounded_sequence_long_double_field; -} - -/*! - * @brief This function returns a reference to member unbounded_sequence_long_double_field - * @return Reference to member unbounded_sequence_long_double_field - */ -std::vector& ContentFilterTestType::unbounded_sequence_long_double_field() -{ - return m_unbounded_sequence_long_double_field; -} - - -/*! - * @brief This function copies the value in member unbounded_sequence_bool_field - * @param _unbounded_sequence_bool_field New value to be copied in member unbounded_sequence_bool_field - */ -void ContentFilterTestType::unbounded_sequence_bool_field( - const std::vector& _unbounded_sequence_bool_field) -{ - m_unbounded_sequence_bool_field = _unbounded_sequence_bool_field; -} - -/*! - * @brief This function moves the value in member unbounded_sequence_bool_field - * @param _unbounded_sequence_bool_field New value to be moved in member unbounded_sequence_bool_field - */ -void ContentFilterTestType::unbounded_sequence_bool_field( - std::vector&& _unbounded_sequence_bool_field) -{ - m_unbounded_sequence_bool_field = std::move(_unbounded_sequence_bool_field); -} - -/*! - * @brief This function returns a constant reference to member unbounded_sequence_bool_field - * @return Constant reference to member unbounded_sequence_bool_field - */ -const std::vector& ContentFilterTestType::unbounded_sequence_bool_field() const -{ - return m_unbounded_sequence_bool_field; -} - -/*! - * @brief This function returns a reference to member unbounded_sequence_bool_field - * @return Reference to member unbounded_sequence_bool_field - */ -std::vector& ContentFilterTestType::unbounded_sequence_bool_field() -{ - return m_unbounded_sequence_bool_field; -} - - -/*! - * @brief This function copies the value in member unbounded_sequence_string_field - * @param _unbounded_sequence_string_field New value to be copied in member unbounded_sequence_string_field - */ -void ContentFilterTestType::unbounded_sequence_string_field( - const std::vector& _unbounded_sequence_string_field) -{ - m_unbounded_sequence_string_field = _unbounded_sequence_string_field; -} - -/*! - * @brief This function moves the value in member unbounded_sequence_string_field - * @param _unbounded_sequence_string_field New value to be moved in member unbounded_sequence_string_field - */ -void ContentFilterTestType::unbounded_sequence_string_field( - std::vector&& _unbounded_sequence_string_field) -{ - m_unbounded_sequence_string_field = std::move(_unbounded_sequence_string_field); -} - -/*! - * @brief This function returns a constant reference to member unbounded_sequence_string_field - * @return Constant reference to member unbounded_sequence_string_field - */ -const std::vector& ContentFilterTestType::unbounded_sequence_string_field() const -{ - return m_unbounded_sequence_string_field; -} - -/*! - * @brief This function returns a reference to member unbounded_sequence_string_field - * @return Reference to member unbounded_sequence_string_field - */ -std::vector& ContentFilterTestType::unbounded_sequence_string_field() -{ - return m_unbounded_sequence_string_field; -} - - -/*! - * @brief This function copies the value in member unbounded_sequence_enum_field - * @param _unbounded_sequence_enum_field New value to be copied in member unbounded_sequence_enum_field - */ -void ContentFilterTestType::unbounded_sequence_enum_field( - const std::vector& _unbounded_sequence_enum_field) -{ - m_unbounded_sequence_enum_field = _unbounded_sequence_enum_field; -} - -/*! - * @brief This function moves the value in member unbounded_sequence_enum_field - * @param _unbounded_sequence_enum_field New value to be moved in member unbounded_sequence_enum_field - */ -void ContentFilterTestType::unbounded_sequence_enum_field( - std::vector&& _unbounded_sequence_enum_field) -{ - m_unbounded_sequence_enum_field = std::move(_unbounded_sequence_enum_field); -} - -/*! - * @brief This function returns a constant reference to member unbounded_sequence_enum_field - * @return Constant reference to member unbounded_sequence_enum_field - */ -const std::vector& ContentFilterTestType::unbounded_sequence_enum_field() const -{ - return m_unbounded_sequence_enum_field; -} - -/*! - * @brief This function returns a reference to member unbounded_sequence_enum_field - * @return Reference to member unbounded_sequence_enum_field - */ -std::vector& ContentFilterTestType::unbounded_sequence_enum_field() -{ - return m_unbounded_sequence_enum_field; -} - - -/*! - * @brief This function copies the value in member unbounded_sequence_enum2_field - * @param _unbounded_sequence_enum2_field New value to be copied in member unbounded_sequence_enum2_field - */ -void ContentFilterTestType::unbounded_sequence_enum2_field( - const std::vector& _unbounded_sequence_enum2_field) -{ - m_unbounded_sequence_enum2_field = _unbounded_sequence_enum2_field; -} - -/*! - * @brief This function moves the value in member unbounded_sequence_enum2_field - * @param _unbounded_sequence_enum2_field New value to be moved in member unbounded_sequence_enum2_field - */ -void ContentFilterTestType::unbounded_sequence_enum2_field( - std::vector&& _unbounded_sequence_enum2_field) -{ - m_unbounded_sequence_enum2_field = std::move(_unbounded_sequence_enum2_field); -} - -/*! - * @brief This function returns a constant reference to member unbounded_sequence_enum2_field - * @return Constant reference to member unbounded_sequence_enum2_field - */ -const std::vector& ContentFilterTestType::unbounded_sequence_enum2_field() const -{ - return m_unbounded_sequence_enum2_field; -} - -/*! - * @brief This function returns a reference to member unbounded_sequence_enum2_field - * @return Reference to member unbounded_sequence_enum2_field - */ -std::vector& ContentFilterTestType::unbounded_sequence_enum2_field() -{ - return m_unbounded_sequence_enum2_field; -} - - -/*! - * @brief This function copies the value in member unbounded_sequence_struct_field - * @param _unbounded_sequence_struct_field New value to be copied in member unbounded_sequence_struct_field - */ -void ContentFilterTestType::unbounded_sequence_struct_field( - const std::vector& _unbounded_sequence_struct_field) -{ - m_unbounded_sequence_struct_field = _unbounded_sequence_struct_field; -} - -/*! - * @brief This function moves the value in member unbounded_sequence_struct_field - * @param _unbounded_sequence_struct_field New value to be moved in member unbounded_sequence_struct_field - */ -void ContentFilterTestType::unbounded_sequence_struct_field( - std::vector&& _unbounded_sequence_struct_field) -{ - m_unbounded_sequence_struct_field = std::move(_unbounded_sequence_struct_field); -} - -/*! - * @brief This function returns a constant reference to member unbounded_sequence_struct_field - * @return Constant reference to member unbounded_sequence_struct_field - */ -const std::vector& ContentFilterTestType::unbounded_sequence_struct_field() const -{ - return m_unbounded_sequence_struct_field; -} - -/*! - * @brief This function returns a reference to member unbounded_sequence_struct_field - * @return Reference to member unbounded_sequence_struct_field - */ -std::vector& ContentFilterTestType::unbounded_sequence_struct_field() -{ - return m_unbounded_sequence_struct_field; -} - - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypev1.h b/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypev1.h deleted file mode 100644 index b67d7e3d05b..00000000000 --- a/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypev1.h +++ /dev/null @@ -1,2359 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file ContentFilterTestType.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#include - -#if FASTCDR_VERSION_MAJOR == 1 - -#ifndef _FAST_DDS_GENERATED_CONTENTFILTERTESTTYPE_H_ -#define _FAST_DDS_GENERATED_CONTENTFILTERTESTTYPE_H_ - - -#include - -#include -#include -#include -#include -#include -#include -#include - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define eProsima_user_DllExport -#endif // _WIN32 - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(CONTENTFILTERTESTTYPE_SOURCE) -#define CONTENTFILTERTESTTYPE_DllAPI __declspec( dllexport ) -#else -#define CONTENTFILTERTESTTYPE_DllAPI __declspec( dllimport ) -#endif // CONTENTFILTERTESTTYPE_SOURCE -#else -#define CONTENTFILTERTESTTYPE_DllAPI -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define CONTENTFILTERTESTTYPE_DllAPI -#endif // _WIN32 - -namespace eprosima { -namespace fastcdr { -class Cdr; -} // namespace fastcdr -} // namespace eprosima - - - -/*! - * @brief This class represents the enumeration Color defined by the user in the IDL file. - * @ingroup ContentFilterTestType - */ -enum Color : uint32_t -{ - RED, - GREEN, - BLUE, - YELLOW, - MAGENTA -}; -/*! - * @brief This class represents the enumeration Material defined by the user in the IDL file. - * @ingroup ContentFilterTestType - */ -enum Material : uint32_t -{ - WOOD, - PLASTIC, - METAL, - CONCRETE, - STONE -}; - - -/*! - * @brief This class represents the structure StructType defined by the user in the IDL file. - * @ingroup ContentFilterTestType - */ -class StructType -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport StructType(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~StructType(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object StructType that will be copied. - */ - eProsima_user_DllExport StructType( - const StructType& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object StructType that will be copied. - */ - eProsima_user_DllExport StructType( - StructType&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object StructType that will be copied. - */ - eProsima_user_DllExport StructType& operator =( - const StructType& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object StructType that will be copied. - */ - eProsima_user_DllExport StructType& operator =( - StructType&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x StructType object to compare. - */ - eProsima_user_DllExport bool operator ==( - const StructType& x) const; - - /*! - * @brief Comparison operator. - * @param x StructType object to compare. - */ - eProsima_user_DllExport bool operator !=( - const StructType& x) const; - - /*! - * @brief This function sets a value in member char_field - * @param _char_field New value for member char_field - */ - eProsima_user_DllExport void char_field( - char _char_field); - - /*! - * @brief This function returns the value of member char_field - * @return Value of member char_field - */ - eProsima_user_DllExport char char_field() const; - - /*! - * @brief This function returns a reference to member char_field - * @return Reference to member char_field - */ - eProsima_user_DllExport char& char_field(); - - - /*! - * @brief This function sets a value in member uint8_field - * @param _uint8_field New value for member uint8_field - */ - eProsima_user_DllExport void uint8_field( - uint8_t _uint8_field); - - /*! - * @brief This function returns the value of member uint8_field - * @return Value of member uint8_field - */ - eProsima_user_DllExport uint8_t uint8_field() const; - - /*! - * @brief This function returns a reference to member uint8_field - * @return Reference to member uint8_field - */ - eProsima_user_DllExport uint8_t& uint8_field(); - - - /*! - * @brief This function sets a value in member int16_field - * @param _int16_field New value for member int16_field - */ - eProsima_user_DllExport void int16_field( - int16_t _int16_field); - - /*! - * @brief This function returns the value of member int16_field - * @return Value of member int16_field - */ - eProsima_user_DllExport int16_t int16_field() const; - - /*! - * @brief This function returns a reference to member int16_field - * @return Reference to member int16_field - */ - eProsima_user_DllExport int16_t& int16_field(); - - - /*! - * @brief This function sets a value in member uint16_field - * @param _uint16_field New value for member uint16_field - */ - eProsima_user_DllExport void uint16_field( - uint16_t _uint16_field); - - /*! - * @brief This function returns the value of member uint16_field - * @return Value of member uint16_field - */ - eProsima_user_DllExport uint16_t uint16_field() const; - - /*! - * @brief This function returns a reference to member uint16_field - * @return Reference to member uint16_field - */ - eProsima_user_DllExport uint16_t& uint16_field(); - - - /*! - * @brief This function sets a value in member int32_field - * @param _int32_field New value for member int32_field - */ - eProsima_user_DllExport void int32_field( - int32_t _int32_field); - - /*! - * @brief This function returns the value of member int32_field - * @return Value of member int32_field - */ - eProsima_user_DllExport int32_t int32_field() const; - - /*! - * @brief This function returns a reference to member int32_field - * @return Reference to member int32_field - */ - eProsima_user_DllExport int32_t& int32_field(); - - - /*! - * @brief This function sets a value in member uint32_field - * @param _uint32_field New value for member uint32_field - */ - eProsima_user_DllExport void uint32_field( - uint32_t _uint32_field); - - /*! - * @brief This function returns the value of member uint32_field - * @return Value of member uint32_field - */ - eProsima_user_DllExport uint32_t uint32_field() const; - - /*! - * @brief This function returns a reference to member uint32_field - * @return Reference to member uint32_field - */ - eProsima_user_DllExport uint32_t& uint32_field(); - - - /*! - * @brief This function sets a value in member int64_field - * @param _int64_field New value for member int64_field - */ - eProsima_user_DllExport void int64_field( - int64_t _int64_field); - - /*! - * @brief This function returns the value of member int64_field - * @return Value of member int64_field - */ - eProsima_user_DllExport int64_t int64_field() const; - - /*! - * @brief This function returns a reference to member int64_field - * @return Reference to member int64_field - */ - eProsima_user_DllExport int64_t& int64_field(); - - - /*! - * @brief This function sets a value in member uint64_field - * @param _uint64_field New value for member uint64_field - */ - eProsima_user_DllExport void uint64_field( - uint64_t _uint64_field); - - /*! - * @brief This function returns the value of member uint64_field - * @return Value of member uint64_field - */ - eProsima_user_DllExport uint64_t uint64_field() const; - - /*! - * @brief This function returns a reference to member uint64_field - * @return Reference to member uint64_field - */ - eProsima_user_DllExport uint64_t& uint64_field(); - - - /*! - * @brief This function sets a value in member float_field - * @param _float_field New value for member float_field - */ - eProsima_user_DllExport void float_field( - float _float_field); - - /*! - * @brief This function returns the value of member float_field - * @return Value of member float_field - */ - eProsima_user_DllExport float float_field() const; - - /*! - * @brief This function returns a reference to member float_field - * @return Reference to member float_field - */ - eProsima_user_DllExport float& float_field(); - - - /*! - * @brief This function sets a value in member double_field - * @param _double_field New value for member double_field - */ - eProsima_user_DllExport void double_field( - double _double_field); - - /*! - * @brief This function returns the value of member double_field - * @return Value of member double_field - */ - eProsima_user_DllExport double double_field() const; - - /*! - * @brief This function returns a reference to member double_field - * @return Reference to member double_field - */ - eProsima_user_DllExport double& double_field(); - - - /*! - * @brief This function sets a value in member long_double_field - * @param _long_double_field New value for member long_double_field - */ - eProsima_user_DllExport void long_double_field( - long double _long_double_field); - - /*! - * @brief This function returns the value of member long_double_field - * @return Value of member long_double_field - */ - eProsima_user_DllExport long double long_double_field() const; - - /*! - * @brief This function returns a reference to member long_double_field - * @return Reference to member long_double_field - */ - eProsima_user_DllExport long double& long_double_field(); - - - /*! - * @brief This function sets a value in member bool_field - * @param _bool_field New value for member bool_field - */ - eProsima_user_DllExport void bool_field( - bool _bool_field); - - /*! - * @brief This function returns the value of member bool_field - * @return Value of member bool_field - */ - eProsima_user_DllExport bool bool_field() const; - - /*! - * @brief This function returns a reference to member bool_field - * @return Reference to member bool_field - */ - eProsima_user_DllExport bool& bool_field(); - - - /*! - * @brief This function copies the value in member string_field - * @param _string_field New value to be copied in member string_field - */ - eProsima_user_DllExport void string_field( - const std::string& _string_field); - - /*! - * @brief This function moves the value in member string_field - * @param _string_field New value to be moved in member string_field - */ - eProsima_user_DllExport void string_field( - std::string&& _string_field); - - /*! - * @brief This function returns a constant reference to member string_field - * @return Constant reference to member string_field - */ - eProsima_user_DllExport const std::string& string_field() const; - - /*! - * @brief This function returns a reference to member string_field - * @return Reference to member string_field - */ - eProsima_user_DllExport std::string& string_field(); - - - /*! - * @brief This function sets a value in member enum_field - * @param _enum_field New value for member enum_field - */ - eProsima_user_DllExport void enum_field( - Color _enum_field); - - /*! - * @brief This function returns the value of member enum_field - * @return Value of member enum_field - */ - eProsima_user_DllExport Color enum_field() const; - - /*! - * @brief This function returns a reference to member enum_field - * @return Reference to member enum_field - */ - eProsima_user_DllExport Color& enum_field(); - - - /*! - * @brief This function sets a value in member enum2_field - * @param _enum2_field New value for member enum2_field - */ - eProsima_user_DllExport void enum2_field( - Material _enum2_field); - - /*! - * @brief This function returns the value of member enum2_field - * @return Value of member enum2_field - */ - eProsima_user_DllExport Material enum2_field() const; - - /*! - * @brief This function returns a reference to member enum2_field - * @return Reference to member enum2_field - */ - eProsima_user_DllExport Material& enum2_field(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const StructType& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - char m_char_field; - uint8_t m_uint8_field; - int16_t m_int16_field; - uint16_t m_uint16_field; - int32_t m_int32_field; - uint32_t m_uint32_field; - int64_t m_int64_field; - uint64_t m_uint64_field; - float m_float_field; - double m_double_field; - long double m_long_double_field; - bool m_bool_field; - std::string m_string_field; - Color m_enum_field; - Material m_enum2_field; - -}; - -const uint32_t max_array_size = 3; - -const uint32_t max_seq_size = 5; - - - - - -/*! - * @brief This class represents the structure ContentFilterTestType defined by the user in the IDL file. - * @ingroup ContentFilterTestType - */ -class ContentFilterTestType -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport ContentFilterTestType(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~ContentFilterTestType(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object ContentFilterTestType that will be copied. - */ - eProsima_user_DllExport ContentFilterTestType( - const ContentFilterTestType& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object ContentFilterTestType that will be copied. - */ - eProsima_user_DllExport ContentFilterTestType( - ContentFilterTestType&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object ContentFilterTestType that will be copied. - */ - eProsima_user_DllExport ContentFilterTestType& operator =( - const ContentFilterTestType& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object ContentFilterTestType that will be copied. - */ - eProsima_user_DllExport ContentFilterTestType& operator =( - ContentFilterTestType&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x ContentFilterTestType object to compare. - */ - eProsima_user_DllExport bool operator ==( - const ContentFilterTestType& x) const; - - /*! - * @brief Comparison operator. - * @param x ContentFilterTestType object to compare. - */ - eProsima_user_DllExport bool operator !=( - const ContentFilterTestType& x) const; - - /*! - * @brief This function sets a value in member char_field - * @param _char_field New value for member char_field - */ - eProsima_user_DllExport void char_field( - char _char_field); - - /*! - * @brief This function returns the value of member char_field - * @return Value of member char_field - */ - eProsima_user_DllExport char char_field() const; - - /*! - * @brief This function returns a reference to member char_field - * @return Reference to member char_field - */ - eProsima_user_DllExport char& char_field(); - - - /*! - * @brief This function sets a value in member uint8_field - * @param _uint8_field New value for member uint8_field - */ - eProsima_user_DllExport void uint8_field( - uint8_t _uint8_field); - - /*! - * @brief This function returns the value of member uint8_field - * @return Value of member uint8_field - */ - eProsima_user_DllExport uint8_t uint8_field() const; - - /*! - * @brief This function returns a reference to member uint8_field - * @return Reference to member uint8_field - */ - eProsima_user_DllExport uint8_t& uint8_field(); - - - /*! - * @brief This function sets a value in member int16_field - * @param _int16_field New value for member int16_field - */ - eProsima_user_DllExport void int16_field( - int16_t _int16_field); - - /*! - * @brief This function returns the value of member int16_field - * @return Value of member int16_field - */ - eProsima_user_DllExport int16_t int16_field() const; - - /*! - * @brief This function returns a reference to member int16_field - * @return Reference to member int16_field - */ - eProsima_user_DllExport int16_t& int16_field(); - - - /*! - * @brief This function sets a value in member uint16_field - * @param _uint16_field New value for member uint16_field - */ - eProsima_user_DllExport void uint16_field( - uint16_t _uint16_field); - - /*! - * @brief This function returns the value of member uint16_field - * @return Value of member uint16_field - */ - eProsima_user_DllExport uint16_t uint16_field() const; - - /*! - * @brief This function returns a reference to member uint16_field - * @return Reference to member uint16_field - */ - eProsima_user_DllExport uint16_t& uint16_field(); - - - /*! - * @brief This function sets a value in member int32_field - * @param _int32_field New value for member int32_field - */ - eProsima_user_DllExport void int32_field( - int32_t _int32_field); - - /*! - * @brief This function returns the value of member int32_field - * @return Value of member int32_field - */ - eProsima_user_DllExport int32_t int32_field() const; - - /*! - * @brief This function returns a reference to member int32_field - * @return Reference to member int32_field - */ - eProsima_user_DllExport int32_t& int32_field(); - - - /*! - * @brief This function sets a value in member uint32_field - * @param _uint32_field New value for member uint32_field - */ - eProsima_user_DllExport void uint32_field( - uint32_t _uint32_field); - - /*! - * @brief This function returns the value of member uint32_field - * @return Value of member uint32_field - */ - eProsima_user_DllExport uint32_t uint32_field() const; - - /*! - * @brief This function returns a reference to member uint32_field - * @return Reference to member uint32_field - */ - eProsima_user_DllExport uint32_t& uint32_field(); - - - /*! - * @brief This function sets a value in member int64_field - * @param _int64_field New value for member int64_field - */ - eProsima_user_DllExport void int64_field( - int64_t _int64_field); - - /*! - * @brief This function returns the value of member int64_field - * @return Value of member int64_field - */ - eProsima_user_DllExport int64_t int64_field() const; - - /*! - * @brief This function returns a reference to member int64_field - * @return Reference to member int64_field - */ - eProsima_user_DllExport int64_t& int64_field(); - - - /*! - * @brief This function sets a value in member uint64_field - * @param _uint64_field New value for member uint64_field - */ - eProsima_user_DllExport void uint64_field( - uint64_t _uint64_field); - - /*! - * @brief This function returns the value of member uint64_field - * @return Value of member uint64_field - */ - eProsima_user_DllExport uint64_t uint64_field() const; - - /*! - * @brief This function returns a reference to member uint64_field - * @return Reference to member uint64_field - */ - eProsima_user_DllExport uint64_t& uint64_field(); - - - /*! - * @brief This function sets a value in member float_field - * @param _float_field New value for member float_field - */ - eProsima_user_DllExport void float_field( - float _float_field); - - /*! - * @brief This function returns the value of member float_field - * @return Value of member float_field - */ - eProsima_user_DllExport float float_field() const; - - /*! - * @brief This function returns a reference to member float_field - * @return Reference to member float_field - */ - eProsima_user_DllExport float& float_field(); - - - /*! - * @brief This function sets a value in member double_field - * @param _double_field New value for member double_field - */ - eProsima_user_DllExport void double_field( - double _double_field); - - /*! - * @brief This function returns the value of member double_field - * @return Value of member double_field - */ - eProsima_user_DllExport double double_field() const; - - /*! - * @brief This function returns a reference to member double_field - * @return Reference to member double_field - */ - eProsima_user_DllExport double& double_field(); - - - /*! - * @brief This function sets a value in member long_double_field - * @param _long_double_field New value for member long_double_field - */ - eProsima_user_DllExport void long_double_field( - long double _long_double_field); - - /*! - * @brief This function returns the value of member long_double_field - * @return Value of member long_double_field - */ - eProsima_user_DllExport long double long_double_field() const; - - /*! - * @brief This function returns a reference to member long_double_field - * @return Reference to member long_double_field - */ - eProsima_user_DllExport long double& long_double_field(); - - - /*! - * @brief This function sets a value in member bool_field - * @param _bool_field New value for member bool_field - */ - eProsima_user_DllExport void bool_field( - bool _bool_field); - - /*! - * @brief This function returns the value of member bool_field - * @return Value of member bool_field - */ - eProsima_user_DllExport bool bool_field() const; - - /*! - * @brief This function returns a reference to member bool_field - * @return Reference to member bool_field - */ - eProsima_user_DllExport bool& bool_field(); - - - /*! - * @brief This function copies the value in member string_field - * @param _string_field New value to be copied in member string_field - */ - eProsima_user_DllExport void string_field( - const std::string& _string_field); - - /*! - * @brief This function moves the value in member string_field - * @param _string_field New value to be moved in member string_field - */ - eProsima_user_DllExport void string_field( - std::string&& _string_field); - - /*! - * @brief This function returns a constant reference to member string_field - * @return Constant reference to member string_field - */ - eProsima_user_DllExport const std::string& string_field() const; - - /*! - * @brief This function returns a reference to member string_field - * @return Reference to member string_field - */ - eProsima_user_DllExport std::string& string_field(); - - - /*! - * @brief This function sets a value in member enum_field - * @param _enum_field New value for member enum_field - */ - eProsima_user_DllExport void enum_field( - Color _enum_field); - - /*! - * @brief This function returns the value of member enum_field - * @return Value of member enum_field - */ - eProsima_user_DllExport Color enum_field() const; - - /*! - * @brief This function returns a reference to member enum_field - * @return Reference to member enum_field - */ - eProsima_user_DllExport Color& enum_field(); - - - /*! - * @brief This function sets a value in member enum2_field - * @param _enum2_field New value for member enum2_field - */ - eProsima_user_DllExport void enum2_field( - Material _enum2_field); - - /*! - * @brief This function returns the value of member enum2_field - * @return Value of member enum2_field - */ - eProsima_user_DllExport Material enum2_field() const; - - /*! - * @brief This function returns a reference to member enum2_field - * @return Reference to member enum2_field - */ - eProsima_user_DllExport Material& enum2_field(); - - - /*! - * @brief This function copies the value in member struct_field - * @param _struct_field New value to be copied in member struct_field - */ - eProsima_user_DllExport void struct_field( - const StructType& _struct_field); - - /*! - * @brief This function moves the value in member struct_field - * @param _struct_field New value to be moved in member struct_field - */ - eProsima_user_DllExport void struct_field( - StructType&& _struct_field); - - /*! - * @brief This function returns a constant reference to member struct_field - * @return Constant reference to member struct_field - */ - eProsima_user_DllExport const StructType& struct_field() const; - - /*! - * @brief This function returns a reference to member struct_field - * @return Reference to member struct_field - */ - eProsima_user_DllExport StructType& struct_field(); - - - /*! - * @brief This function copies the value in member array_char_field - * @param _array_char_field New value to be copied in member array_char_field - */ - eProsima_user_DllExport void array_char_field( - const std::array& _array_char_field); - - /*! - * @brief This function moves the value in member array_char_field - * @param _array_char_field New value to be moved in member array_char_field - */ - eProsima_user_DllExport void array_char_field( - std::array&& _array_char_field); - - /*! - * @brief This function returns a constant reference to member array_char_field - * @return Constant reference to member array_char_field - */ - eProsima_user_DllExport const std::array& array_char_field() const; - - /*! - * @brief This function returns a reference to member array_char_field - * @return Reference to member array_char_field - */ - eProsima_user_DllExport std::array& array_char_field(); - - - /*! - * @brief This function copies the value in member array_uint8_field - * @param _array_uint8_field New value to be copied in member array_uint8_field - */ - eProsima_user_DllExport void array_uint8_field( - const std::array& _array_uint8_field); - - /*! - * @brief This function moves the value in member array_uint8_field - * @param _array_uint8_field New value to be moved in member array_uint8_field - */ - eProsima_user_DllExport void array_uint8_field( - std::array&& _array_uint8_field); - - /*! - * @brief This function returns a constant reference to member array_uint8_field - * @return Constant reference to member array_uint8_field - */ - eProsima_user_DllExport const std::array& array_uint8_field() const; - - /*! - * @brief This function returns a reference to member array_uint8_field - * @return Reference to member array_uint8_field - */ - eProsima_user_DllExport std::array& array_uint8_field(); - - - /*! - * @brief This function copies the value in member array_int16_field - * @param _array_int16_field New value to be copied in member array_int16_field - */ - eProsima_user_DllExport void array_int16_field( - const std::array& _array_int16_field); - - /*! - * @brief This function moves the value in member array_int16_field - * @param _array_int16_field New value to be moved in member array_int16_field - */ - eProsima_user_DllExport void array_int16_field( - std::array&& _array_int16_field); - - /*! - * @brief This function returns a constant reference to member array_int16_field - * @return Constant reference to member array_int16_field - */ - eProsima_user_DllExport const std::array& array_int16_field() const; - - /*! - * @brief This function returns a reference to member array_int16_field - * @return Reference to member array_int16_field - */ - eProsima_user_DllExport std::array& array_int16_field(); - - - /*! - * @brief This function copies the value in member array_uint16_field - * @param _array_uint16_field New value to be copied in member array_uint16_field - */ - eProsima_user_DllExport void array_uint16_field( - const std::array& _array_uint16_field); - - /*! - * @brief This function moves the value in member array_uint16_field - * @param _array_uint16_field New value to be moved in member array_uint16_field - */ - eProsima_user_DllExport void array_uint16_field( - std::array&& _array_uint16_field); - - /*! - * @brief This function returns a constant reference to member array_uint16_field - * @return Constant reference to member array_uint16_field - */ - eProsima_user_DllExport const std::array& array_uint16_field() const; - - /*! - * @brief This function returns a reference to member array_uint16_field - * @return Reference to member array_uint16_field - */ - eProsima_user_DllExport std::array& array_uint16_field(); - - - /*! - * @brief This function copies the value in member array_int32_field - * @param _array_int32_field New value to be copied in member array_int32_field - */ - eProsima_user_DllExport void array_int32_field( - const std::array& _array_int32_field); - - /*! - * @brief This function moves the value in member array_int32_field - * @param _array_int32_field New value to be moved in member array_int32_field - */ - eProsima_user_DllExport void array_int32_field( - std::array&& _array_int32_field); - - /*! - * @brief This function returns a constant reference to member array_int32_field - * @return Constant reference to member array_int32_field - */ - eProsima_user_DllExport const std::array& array_int32_field() const; - - /*! - * @brief This function returns a reference to member array_int32_field - * @return Reference to member array_int32_field - */ - eProsima_user_DllExport std::array& array_int32_field(); - - - /*! - * @brief This function copies the value in member array_uint32_field - * @param _array_uint32_field New value to be copied in member array_uint32_field - */ - eProsima_user_DllExport void array_uint32_field( - const std::array& _array_uint32_field); - - /*! - * @brief This function moves the value in member array_uint32_field - * @param _array_uint32_field New value to be moved in member array_uint32_field - */ - eProsima_user_DllExport void array_uint32_field( - std::array&& _array_uint32_field); - - /*! - * @brief This function returns a constant reference to member array_uint32_field - * @return Constant reference to member array_uint32_field - */ - eProsima_user_DllExport const std::array& array_uint32_field() const; - - /*! - * @brief This function returns a reference to member array_uint32_field - * @return Reference to member array_uint32_field - */ - eProsima_user_DllExport std::array& array_uint32_field(); - - - /*! - * @brief This function copies the value in member array_int64_field - * @param _array_int64_field New value to be copied in member array_int64_field - */ - eProsima_user_DllExport void array_int64_field( - const std::array& _array_int64_field); - - /*! - * @brief This function moves the value in member array_int64_field - * @param _array_int64_field New value to be moved in member array_int64_field - */ - eProsima_user_DllExport void array_int64_field( - std::array&& _array_int64_field); - - /*! - * @brief This function returns a constant reference to member array_int64_field - * @return Constant reference to member array_int64_field - */ - eProsima_user_DllExport const std::array& array_int64_field() const; - - /*! - * @brief This function returns a reference to member array_int64_field - * @return Reference to member array_int64_field - */ - eProsima_user_DllExport std::array& array_int64_field(); - - - /*! - * @brief This function copies the value in member array_uint64_field - * @param _array_uint64_field New value to be copied in member array_uint64_field - */ - eProsima_user_DllExport void array_uint64_field( - const std::array& _array_uint64_field); - - /*! - * @brief This function moves the value in member array_uint64_field - * @param _array_uint64_field New value to be moved in member array_uint64_field - */ - eProsima_user_DllExport void array_uint64_field( - std::array&& _array_uint64_field); - - /*! - * @brief This function returns a constant reference to member array_uint64_field - * @return Constant reference to member array_uint64_field - */ - eProsima_user_DllExport const std::array& array_uint64_field() const; - - /*! - * @brief This function returns a reference to member array_uint64_field - * @return Reference to member array_uint64_field - */ - eProsima_user_DllExport std::array& array_uint64_field(); - - - /*! - * @brief This function copies the value in member array_float_field - * @param _array_float_field New value to be copied in member array_float_field - */ - eProsima_user_DllExport void array_float_field( - const std::array& _array_float_field); - - /*! - * @brief This function moves the value in member array_float_field - * @param _array_float_field New value to be moved in member array_float_field - */ - eProsima_user_DllExport void array_float_field( - std::array&& _array_float_field); - - /*! - * @brief This function returns a constant reference to member array_float_field - * @return Constant reference to member array_float_field - */ - eProsima_user_DllExport const std::array& array_float_field() const; - - /*! - * @brief This function returns a reference to member array_float_field - * @return Reference to member array_float_field - */ - eProsima_user_DllExport std::array& array_float_field(); - - - /*! - * @brief This function copies the value in member array_double_field - * @param _array_double_field New value to be copied in member array_double_field - */ - eProsima_user_DllExport void array_double_field( - const std::array& _array_double_field); - - /*! - * @brief This function moves the value in member array_double_field - * @param _array_double_field New value to be moved in member array_double_field - */ - eProsima_user_DllExport void array_double_field( - std::array&& _array_double_field); - - /*! - * @brief This function returns a constant reference to member array_double_field - * @return Constant reference to member array_double_field - */ - eProsima_user_DllExport const std::array& array_double_field() const; - - /*! - * @brief This function returns a reference to member array_double_field - * @return Reference to member array_double_field - */ - eProsima_user_DllExport std::array& array_double_field(); - - - /*! - * @brief This function copies the value in member array_long_double_field - * @param _array_long_double_field New value to be copied in member array_long_double_field - */ - eProsima_user_DllExport void array_long_double_field( - const std::array& _array_long_double_field); - - /*! - * @brief This function moves the value in member array_long_double_field - * @param _array_long_double_field New value to be moved in member array_long_double_field - */ - eProsima_user_DllExport void array_long_double_field( - std::array&& _array_long_double_field); - - /*! - * @brief This function returns a constant reference to member array_long_double_field - * @return Constant reference to member array_long_double_field - */ - eProsima_user_DllExport const std::array& array_long_double_field() const; - - /*! - * @brief This function returns a reference to member array_long_double_field - * @return Reference to member array_long_double_field - */ - eProsima_user_DllExport std::array& array_long_double_field(); - - - /*! - * @brief This function copies the value in member array_bool_field - * @param _array_bool_field New value to be copied in member array_bool_field - */ - eProsima_user_DllExport void array_bool_field( - const std::array& _array_bool_field); - - /*! - * @brief This function moves the value in member array_bool_field - * @param _array_bool_field New value to be moved in member array_bool_field - */ - eProsima_user_DllExport void array_bool_field( - std::array&& _array_bool_field); - - /*! - * @brief This function returns a constant reference to member array_bool_field - * @return Constant reference to member array_bool_field - */ - eProsima_user_DllExport const std::array& array_bool_field() const; - - /*! - * @brief This function returns a reference to member array_bool_field - * @return Reference to member array_bool_field - */ - eProsima_user_DllExport std::array& array_bool_field(); - - - /*! - * @brief This function copies the value in member array_string_field - * @param _array_string_field New value to be copied in member array_string_field - */ - eProsima_user_DllExport void array_string_field( - const std::array& _array_string_field); - - /*! - * @brief This function moves the value in member array_string_field - * @param _array_string_field New value to be moved in member array_string_field - */ - eProsima_user_DllExport void array_string_field( - std::array&& _array_string_field); - - /*! - * @brief This function returns a constant reference to member array_string_field - * @return Constant reference to member array_string_field - */ - eProsima_user_DllExport const std::array& array_string_field() const; - - /*! - * @brief This function returns a reference to member array_string_field - * @return Reference to member array_string_field - */ - eProsima_user_DllExport std::array& array_string_field(); - - - /*! - * @brief This function copies the value in member array_enum_field - * @param _array_enum_field New value to be copied in member array_enum_field - */ - eProsima_user_DllExport void array_enum_field( - const std::array& _array_enum_field); - - /*! - * @brief This function moves the value in member array_enum_field - * @param _array_enum_field New value to be moved in member array_enum_field - */ - eProsima_user_DllExport void array_enum_field( - std::array&& _array_enum_field); - - /*! - * @brief This function returns a constant reference to member array_enum_field - * @return Constant reference to member array_enum_field - */ - eProsima_user_DllExport const std::array& array_enum_field() const; - - /*! - * @brief This function returns a reference to member array_enum_field - * @return Reference to member array_enum_field - */ - eProsima_user_DllExport std::array& array_enum_field(); - - - /*! - * @brief This function copies the value in member array_enum2_field - * @param _array_enum2_field New value to be copied in member array_enum2_field - */ - eProsima_user_DllExport void array_enum2_field( - const std::array& _array_enum2_field); - - /*! - * @brief This function moves the value in member array_enum2_field - * @param _array_enum2_field New value to be moved in member array_enum2_field - */ - eProsima_user_DllExport void array_enum2_field( - std::array&& _array_enum2_field); - - /*! - * @brief This function returns a constant reference to member array_enum2_field - * @return Constant reference to member array_enum2_field - */ - eProsima_user_DllExport const std::array& array_enum2_field() const; - - /*! - * @brief This function returns a reference to member array_enum2_field - * @return Reference to member array_enum2_field - */ - eProsima_user_DllExport std::array& array_enum2_field(); - - - /*! - * @brief This function copies the value in member array_struct_field - * @param _array_struct_field New value to be copied in member array_struct_field - */ - eProsima_user_DllExport void array_struct_field( - const std::array& _array_struct_field); - - /*! - * @brief This function moves the value in member array_struct_field - * @param _array_struct_field New value to be moved in member array_struct_field - */ - eProsima_user_DllExport void array_struct_field( - std::array&& _array_struct_field); - - /*! - * @brief This function returns a constant reference to member array_struct_field - * @return Constant reference to member array_struct_field - */ - eProsima_user_DllExport const std::array& array_struct_field() const; - - /*! - * @brief This function returns a reference to member array_struct_field - * @return Reference to member array_struct_field - */ - eProsima_user_DllExport std::array& array_struct_field(); - - - /*! - * @brief This function copies the value in member bounded_sequence_char_field - * @param _bounded_sequence_char_field New value to be copied in member bounded_sequence_char_field - */ - eProsima_user_DllExport void bounded_sequence_char_field( - const std::vector& _bounded_sequence_char_field); - - /*! - * @brief This function moves the value in member bounded_sequence_char_field - * @param _bounded_sequence_char_field New value to be moved in member bounded_sequence_char_field - */ - eProsima_user_DllExport void bounded_sequence_char_field( - std::vector&& _bounded_sequence_char_field); - - /*! - * @brief This function returns a constant reference to member bounded_sequence_char_field - * @return Constant reference to member bounded_sequence_char_field - */ - eProsima_user_DllExport const std::vector& bounded_sequence_char_field() const; - - /*! - * @brief This function returns a reference to member bounded_sequence_char_field - * @return Reference to member bounded_sequence_char_field - */ - eProsima_user_DllExport std::vector& bounded_sequence_char_field(); - - - /*! - * @brief This function copies the value in member bounded_sequence_uint8_field - * @param _bounded_sequence_uint8_field New value to be copied in member bounded_sequence_uint8_field - */ - eProsima_user_DllExport void bounded_sequence_uint8_field( - const std::vector& _bounded_sequence_uint8_field); - - /*! - * @brief This function moves the value in member bounded_sequence_uint8_field - * @param _bounded_sequence_uint8_field New value to be moved in member bounded_sequence_uint8_field - */ - eProsima_user_DllExport void bounded_sequence_uint8_field( - std::vector&& _bounded_sequence_uint8_field); - - /*! - * @brief This function returns a constant reference to member bounded_sequence_uint8_field - * @return Constant reference to member bounded_sequence_uint8_field - */ - eProsima_user_DllExport const std::vector& bounded_sequence_uint8_field() const; - - /*! - * @brief This function returns a reference to member bounded_sequence_uint8_field - * @return Reference to member bounded_sequence_uint8_field - */ - eProsima_user_DllExport std::vector& bounded_sequence_uint8_field(); - - - /*! - * @brief This function copies the value in member bounded_sequence_int16_field - * @param _bounded_sequence_int16_field New value to be copied in member bounded_sequence_int16_field - */ - eProsima_user_DllExport void bounded_sequence_int16_field( - const std::vector& _bounded_sequence_int16_field); - - /*! - * @brief This function moves the value in member bounded_sequence_int16_field - * @param _bounded_sequence_int16_field New value to be moved in member bounded_sequence_int16_field - */ - eProsima_user_DllExport void bounded_sequence_int16_field( - std::vector&& _bounded_sequence_int16_field); - - /*! - * @brief This function returns a constant reference to member bounded_sequence_int16_field - * @return Constant reference to member bounded_sequence_int16_field - */ - eProsima_user_DllExport const std::vector& bounded_sequence_int16_field() const; - - /*! - * @brief This function returns a reference to member bounded_sequence_int16_field - * @return Reference to member bounded_sequence_int16_field - */ - eProsima_user_DllExport std::vector& bounded_sequence_int16_field(); - - - /*! - * @brief This function copies the value in member bounded_sequence_uint16_field - * @param _bounded_sequence_uint16_field New value to be copied in member bounded_sequence_uint16_field - */ - eProsima_user_DllExport void bounded_sequence_uint16_field( - const std::vector& _bounded_sequence_uint16_field); - - /*! - * @brief This function moves the value in member bounded_sequence_uint16_field - * @param _bounded_sequence_uint16_field New value to be moved in member bounded_sequence_uint16_field - */ - eProsima_user_DllExport void bounded_sequence_uint16_field( - std::vector&& _bounded_sequence_uint16_field); - - /*! - * @brief This function returns a constant reference to member bounded_sequence_uint16_field - * @return Constant reference to member bounded_sequence_uint16_field - */ - eProsima_user_DllExport const std::vector& bounded_sequence_uint16_field() const; - - /*! - * @brief This function returns a reference to member bounded_sequence_uint16_field - * @return Reference to member bounded_sequence_uint16_field - */ - eProsima_user_DllExport std::vector& bounded_sequence_uint16_field(); - - - /*! - * @brief This function copies the value in member bounded_sequence_int32_field - * @param _bounded_sequence_int32_field New value to be copied in member bounded_sequence_int32_field - */ - eProsima_user_DllExport void bounded_sequence_int32_field( - const std::vector& _bounded_sequence_int32_field); - - /*! - * @brief This function moves the value in member bounded_sequence_int32_field - * @param _bounded_sequence_int32_field New value to be moved in member bounded_sequence_int32_field - */ - eProsima_user_DllExport void bounded_sequence_int32_field( - std::vector&& _bounded_sequence_int32_field); - - /*! - * @brief This function returns a constant reference to member bounded_sequence_int32_field - * @return Constant reference to member bounded_sequence_int32_field - */ - eProsima_user_DllExport const std::vector& bounded_sequence_int32_field() const; - - /*! - * @brief This function returns a reference to member bounded_sequence_int32_field - * @return Reference to member bounded_sequence_int32_field - */ - eProsima_user_DllExport std::vector& bounded_sequence_int32_field(); - - - /*! - * @brief This function copies the value in member bounded_sequence_uint32_field - * @param _bounded_sequence_uint32_field New value to be copied in member bounded_sequence_uint32_field - */ - eProsima_user_DllExport void bounded_sequence_uint32_field( - const std::vector& _bounded_sequence_uint32_field); - - /*! - * @brief This function moves the value in member bounded_sequence_uint32_field - * @param _bounded_sequence_uint32_field New value to be moved in member bounded_sequence_uint32_field - */ - eProsima_user_DllExport void bounded_sequence_uint32_field( - std::vector&& _bounded_sequence_uint32_field); - - /*! - * @brief This function returns a constant reference to member bounded_sequence_uint32_field - * @return Constant reference to member bounded_sequence_uint32_field - */ - eProsima_user_DllExport const std::vector& bounded_sequence_uint32_field() const; - - /*! - * @brief This function returns a reference to member bounded_sequence_uint32_field - * @return Reference to member bounded_sequence_uint32_field - */ - eProsima_user_DllExport std::vector& bounded_sequence_uint32_field(); - - - /*! - * @brief This function copies the value in member bounded_sequence_int64_field - * @param _bounded_sequence_int64_field New value to be copied in member bounded_sequence_int64_field - */ - eProsima_user_DllExport void bounded_sequence_int64_field( - const std::vector& _bounded_sequence_int64_field); - - /*! - * @brief This function moves the value in member bounded_sequence_int64_field - * @param _bounded_sequence_int64_field New value to be moved in member bounded_sequence_int64_field - */ - eProsima_user_DllExport void bounded_sequence_int64_field( - std::vector&& _bounded_sequence_int64_field); - - /*! - * @brief This function returns a constant reference to member bounded_sequence_int64_field - * @return Constant reference to member bounded_sequence_int64_field - */ - eProsima_user_DllExport const std::vector& bounded_sequence_int64_field() const; - - /*! - * @brief This function returns a reference to member bounded_sequence_int64_field - * @return Reference to member bounded_sequence_int64_field - */ - eProsima_user_DllExport std::vector& bounded_sequence_int64_field(); - - - /*! - * @brief This function copies the value in member bounded_sequence_uint64_field - * @param _bounded_sequence_uint64_field New value to be copied in member bounded_sequence_uint64_field - */ - eProsima_user_DllExport void bounded_sequence_uint64_field( - const std::vector& _bounded_sequence_uint64_field); - - /*! - * @brief This function moves the value in member bounded_sequence_uint64_field - * @param _bounded_sequence_uint64_field New value to be moved in member bounded_sequence_uint64_field - */ - eProsima_user_DllExport void bounded_sequence_uint64_field( - std::vector&& _bounded_sequence_uint64_field); - - /*! - * @brief This function returns a constant reference to member bounded_sequence_uint64_field - * @return Constant reference to member bounded_sequence_uint64_field - */ - eProsima_user_DllExport const std::vector& bounded_sequence_uint64_field() const; - - /*! - * @brief This function returns a reference to member bounded_sequence_uint64_field - * @return Reference to member bounded_sequence_uint64_field - */ - eProsima_user_DllExport std::vector& bounded_sequence_uint64_field(); - - - /*! - * @brief This function copies the value in member bounded_sequence_float_field - * @param _bounded_sequence_float_field New value to be copied in member bounded_sequence_float_field - */ - eProsima_user_DllExport void bounded_sequence_float_field( - const std::vector& _bounded_sequence_float_field); - - /*! - * @brief This function moves the value in member bounded_sequence_float_field - * @param _bounded_sequence_float_field New value to be moved in member bounded_sequence_float_field - */ - eProsima_user_DllExport void bounded_sequence_float_field( - std::vector&& _bounded_sequence_float_field); - - /*! - * @brief This function returns a constant reference to member bounded_sequence_float_field - * @return Constant reference to member bounded_sequence_float_field - */ - eProsima_user_DllExport const std::vector& bounded_sequence_float_field() const; - - /*! - * @brief This function returns a reference to member bounded_sequence_float_field - * @return Reference to member bounded_sequence_float_field - */ - eProsima_user_DllExport std::vector& bounded_sequence_float_field(); - - - /*! - * @brief This function copies the value in member bounded_sequence_double_field - * @param _bounded_sequence_double_field New value to be copied in member bounded_sequence_double_field - */ - eProsima_user_DllExport void bounded_sequence_double_field( - const std::vector& _bounded_sequence_double_field); - - /*! - * @brief This function moves the value in member bounded_sequence_double_field - * @param _bounded_sequence_double_field New value to be moved in member bounded_sequence_double_field - */ - eProsima_user_DllExport void bounded_sequence_double_field( - std::vector&& _bounded_sequence_double_field); - - /*! - * @brief This function returns a constant reference to member bounded_sequence_double_field - * @return Constant reference to member bounded_sequence_double_field - */ - eProsima_user_DllExport const std::vector& bounded_sequence_double_field() const; - - /*! - * @brief This function returns a reference to member bounded_sequence_double_field - * @return Reference to member bounded_sequence_double_field - */ - eProsima_user_DllExport std::vector& bounded_sequence_double_field(); - - - /*! - * @brief This function copies the value in member bounded_sequence_long_double_field - * @param _bounded_sequence_long_double_field New value to be copied in member bounded_sequence_long_double_field - */ - eProsima_user_DllExport void bounded_sequence_long_double_field( - const std::vector& _bounded_sequence_long_double_field); - - /*! - * @brief This function moves the value in member bounded_sequence_long_double_field - * @param _bounded_sequence_long_double_field New value to be moved in member bounded_sequence_long_double_field - */ - eProsima_user_DllExport void bounded_sequence_long_double_field( - std::vector&& _bounded_sequence_long_double_field); - - /*! - * @brief This function returns a constant reference to member bounded_sequence_long_double_field - * @return Constant reference to member bounded_sequence_long_double_field - */ - eProsima_user_DllExport const std::vector& bounded_sequence_long_double_field() const; - - /*! - * @brief This function returns a reference to member bounded_sequence_long_double_field - * @return Reference to member bounded_sequence_long_double_field - */ - eProsima_user_DllExport std::vector& bounded_sequence_long_double_field(); - - - /*! - * @brief This function copies the value in member bounded_sequence_bool_field - * @param _bounded_sequence_bool_field New value to be copied in member bounded_sequence_bool_field - */ - eProsima_user_DllExport void bounded_sequence_bool_field( - const std::vector& _bounded_sequence_bool_field); - - /*! - * @brief This function moves the value in member bounded_sequence_bool_field - * @param _bounded_sequence_bool_field New value to be moved in member bounded_sequence_bool_field - */ - eProsima_user_DllExport void bounded_sequence_bool_field( - std::vector&& _bounded_sequence_bool_field); - - /*! - * @brief This function returns a constant reference to member bounded_sequence_bool_field - * @return Constant reference to member bounded_sequence_bool_field - */ - eProsima_user_DllExport const std::vector& bounded_sequence_bool_field() const; - - /*! - * @brief This function returns a reference to member bounded_sequence_bool_field - * @return Reference to member bounded_sequence_bool_field - */ - eProsima_user_DllExport std::vector& bounded_sequence_bool_field(); - - - /*! - * @brief This function copies the value in member bounded_sequence_string_field - * @param _bounded_sequence_string_field New value to be copied in member bounded_sequence_string_field - */ - eProsima_user_DllExport void bounded_sequence_string_field( - const std::vector& _bounded_sequence_string_field); - - /*! - * @brief This function moves the value in member bounded_sequence_string_field - * @param _bounded_sequence_string_field New value to be moved in member bounded_sequence_string_field - */ - eProsima_user_DllExport void bounded_sequence_string_field( - std::vector&& _bounded_sequence_string_field); - - /*! - * @brief This function returns a constant reference to member bounded_sequence_string_field - * @return Constant reference to member bounded_sequence_string_field - */ - eProsima_user_DllExport const std::vector& bounded_sequence_string_field() const; - - /*! - * @brief This function returns a reference to member bounded_sequence_string_field - * @return Reference to member bounded_sequence_string_field - */ - eProsima_user_DllExport std::vector& bounded_sequence_string_field(); - - - /*! - * @brief This function copies the value in member bounded_sequence_enum_field - * @param _bounded_sequence_enum_field New value to be copied in member bounded_sequence_enum_field - */ - eProsima_user_DllExport void bounded_sequence_enum_field( - const std::vector& _bounded_sequence_enum_field); - - /*! - * @brief This function moves the value in member bounded_sequence_enum_field - * @param _bounded_sequence_enum_field New value to be moved in member bounded_sequence_enum_field - */ - eProsima_user_DllExport void bounded_sequence_enum_field( - std::vector&& _bounded_sequence_enum_field); - - /*! - * @brief This function returns a constant reference to member bounded_sequence_enum_field - * @return Constant reference to member bounded_sequence_enum_field - */ - eProsima_user_DllExport const std::vector& bounded_sequence_enum_field() const; - - /*! - * @brief This function returns a reference to member bounded_sequence_enum_field - * @return Reference to member bounded_sequence_enum_field - */ - eProsima_user_DllExport std::vector& bounded_sequence_enum_field(); - - - /*! - * @brief This function copies the value in member bounded_sequence_enum2_field - * @param _bounded_sequence_enum2_field New value to be copied in member bounded_sequence_enum2_field - */ - eProsima_user_DllExport void bounded_sequence_enum2_field( - const std::vector& _bounded_sequence_enum2_field); - - /*! - * @brief This function moves the value in member bounded_sequence_enum2_field - * @param _bounded_sequence_enum2_field New value to be moved in member bounded_sequence_enum2_field - */ - eProsima_user_DllExport void bounded_sequence_enum2_field( - std::vector&& _bounded_sequence_enum2_field); - - /*! - * @brief This function returns a constant reference to member bounded_sequence_enum2_field - * @return Constant reference to member bounded_sequence_enum2_field - */ - eProsima_user_DllExport const std::vector& bounded_sequence_enum2_field() const; - - /*! - * @brief This function returns a reference to member bounded_sequence_enum2_field - * @return Reference to member bounded_sequence_enum2_field - */ - eProsima_user_DllExport std::vector& bounded_sequence_enum2_field(); - - - /*! - * @brief This function copies the value in member bounded_sequence_struct_field - * @param _bounded_sequence_struct_field New value to be copied in member bounded_sequence_struct_field - */ - eProsima_user_DllExport void bounded_sequence_struct_field( - const std::vector& _bounded_sequence_struct_field); - - /*! - * @brief This function moves the value in member bounded_sequence_struct_field - * @param _bounded_sequence_struct_field New value to be moved in member bounded_sequence_struct_field - */ - eProsima_user_DllExport void bounded_sequence_struct_field( - std::vector&& _bounded_sequence_struct_field); - - /*! - * @brief This function returns a constant reference to member bounded_sequence_struct_field - * @return Constant reference to member bounded_sequence_struct_field - */ - eProsima_user_DllExport const std::vector& bounded_sequence_struct_field() const; - - /*! - * @brief This function returns a reference to member bounded_sequence_struct_field - * @return Reference to member bounded_sequence_struct_field - */ - eProsima_user_DllExport std::vector& bounded_sequence_struct_field(); - - - /*! - * @brief This function copies the value in member unbounded_sequence_char_field - * @param _unbounded_sequence_char_field New value to be copied in member unbounded_sequence_char_field - */ - eProsima_user_DllExport void unbounded_sequence_char_field( - const std::vector& _unbounded_sequence_char_field); - - /*! - * @brief This function moves the value in member unbounded_sequence_char_field - * @param _unbounded_sequence_char_field New value to be moved in member unbounded_sequence_char_field - */ - eProsima_user_DllExport void unbounded_sequence_char_field( - std::vector&& _unbounded_sequence_char_field); - - /*! - * @brief This function returns a constant reference to member unbounded_sequence_char_field - * @return Constant reference to member unbounded_sequence_char_field - */ - eProsima_user_DllExport const std::vector& unbounded_sequence_char_field() const; - - /*! - * @brief This function returns a reference to member unbounded_sequence_char_field - * @return Reference to member unbounded_sequence_char_field - */ - eProsima_user_DllExport std::vector& unbounded_sequence_char_field(); - - - /*! - * @brief This function copies the value in member unbounded_sequence_uint8_field - * @param _unbounded_sequence_uint8_field New value to be copied in member unbounded_sequence_uint8_field - */ - eProsima_user_DllExport void unbounded_sequence_uint8_field( - const std::vector& _unbounded_sequence_uint8_field); - - /*! - * @brief This function moves the value in member unbounded_sequence_uint8_field - * @param _unbounded_sequence_uint8_field New value to be moved in member unbounded_sequence_uint8_field - */ - eProsima_user_DllExport void unbounded_sequence_uint8_field( - std::vector&& _unbounded_sequence_uint8_field); - - /*! - * @brief This function returns a constant reference to member unbounded_sequence_uint8_field - * @return Constant reference to member unbounded_sequence_uint8_field - */ - eProsima_user_DllExport const std::vector& unbounded_sequence_uint8_field() const; - - /*! - * @brief This function returns a reference to member unbounded_sequence_uint8_field - * @return Reference to member unbounded_sequence_uint8_field - */ - eProsima_user_DllExport std::vector& unbounded_sequence_uint8_field(); - - - /*! - * @brief This function copies the value in member unbounded_sequence_int16_field - * @param _unbounded_sequence_int16_field New value to be copied in member unbounded_sequence_int16_field - */ - eProsima_user_DllExport void unbounded_sequence_int16_field( - const std::vector& _unbounded_sequence_int16_field); - - /*! - * @brief This function moves the value in member unbounded_sequence_int16_field - * @param _unbounded_sequence_int16_field New value to be moved in member unbounded_sequence_int16_field - */ - eProsima_user_DllExport void unbounded_sequence_int16_field( - std::vector&& _unbounded_sequence_int16_field); - - /*! - * @brief This function returns a constant reference to member unbounded_sequence_int16_field - * @return Constant reference to member unbounded_sequence_int16_field - */ - eProsima_user_DllExport const std::vector& unbounded_sequence_int16_field() const; - - /*! - * @brief This function returns a reference to member unbounded_sequence_int16_field - * @return Reference to member unbounded_sequence_int16_field - */ - eProsima_user_DllExport std::vector& unbounded_sequence_int16_field(); - - - /*! - * @brief This function copies the value in member unbounded_sequence_uint16_field - * @param _unbounded_sequence_uint16_field New value to be copied in member unbounded_sequence_uint16_field - */ - eProsima_user_DllExport void unbounded_sequence_uint16_field( - const std::vector& _unbounded_sequence_uint16_field); - - /*! - * @brief This function moves the value in member unbounded_sequence_uint16_field - * @param _unbounded_sequence_uint16_field New value to be moved in member unbounded_sequence_uint16_field - */ - eProsima_user_DllExport void unbounded_sequence_uint16_field( - std::vector&& _unbounded_sequence_uint16_field); - - /*! - * @brief This function returns a constant reference to member unbounded_sequence_uint16_field - * @return Constant reference to member unbounded_sequence_uint16_field - */ - eProsima_user_DllExport const std::vector& unbounded_sequence_uint16_field() const; - - /*! - * @brief This function returns a reference to member unbounded_sequence_uint16_field - * @return Reference to member unbounded_sequence_uint16_field - */ - eProsima_user_DllExport std::vector& unbounded_sequence_uint16_field(); - - - /*! - * @brief This function copies the value in member unbounded_sequence_int32_field - * @param _unbounded_sequence_int32_field New value to be copied in member unbounded_sequence_int32_field - */ - eProsima_user_DllExport void unbounded_sequence_int32_field( - const std::vector& _unbounded_sequence_int32_field); - - /*! - * @brief This function moves the value in member unbounded_sequence_int32_field - * @param _unbounded_sequence_int32_field New value to be moved in member unbounded_sequence_int32_field - */ - eProsima_user_DllExport void unbounded_sequence_int32_field( - std::vector&& _unbounded_sequence_int32_field); - - /*! - * @brief This function returns a constant reference to member unbounded_sequence_int32_field - * @return Constant reference to member unbounded_sequence_int32_field - */ - eProsima_user_DllExport const std::vector& unbounded_sequence_int32_field() const; - - /*! - * @brief This function returns a reference to member unbounded_sequence_int32_field - * @return Reference to member unbounded_sequence_int32_field - */ - eProsima_user_DllExport std::vector& unbounded_sequence_int32_field(); - - - /*! - * @brief This function copies the value in member unbounded_sequence_uint32_field - * @param _unbounded_sequence_uint32_field New value to be copied in member unbounded_sequence_uint32_field - */ - eProsima_user_DllExport void unbounded_sequence_uint32_field( - const std::vector& _unbounded_sequence_uint32_field); - - /*! - * @brief This function moves the value in member unbounded_sequence_uint32_field - * @param _unbounded_sequence_uint32_field New value to be moved in member unbounded_sequence_uint32_field - */ - eProsima_user_DllExport void unbounded_sequence_uint32_field( - std::vector&& _unbounded_sequence_uint32_field); - - /*! - * @brief This function returns a constant reference to member unbounded_sequence_uint32_field - * @return Constant reference to member unbounded_sequence_uint32_field - */ - eProsima_user_DllExport const std::vector& unbounded_sequence_uint32_field() const; - - /*! - * @brief This function returns a reference to member unbounded_sequence_uint32_field - * @return Reference to member unbounded_sequence_uint32_field - */ - eProsima_user_DllExport std::vector& unbounded_sequence_uint32_field(); - - - /*! - * @brief This function copies the value in member unbounded_sequence_int64_field - * @param _unbounded_sequence_int64_field New value to be copied in member unbounded_sequence_int64_field - */ - eProsima_user_DllExport void unbounded_sequence_int64_field( - const std::vector& _unbounded_sequence_int64_field); - - /*! - * @brief This function moves the value in member unbounded_sequence_int64_field - * @param _unbounded_sequence_int64_field New value to be moved in member unbounded_sequence_int64_field - */ - eProsima_user_DllExport void unbounded_sequence_int64_field( - std::vector&& _unbounded_sequence_int64_field); - - /*! - * @brief This function returns a constant reference to member unbounded_sequence_int64_field - * @return Constant reference to member unbounded_sequence_int64_field - */ - eProsima_user_DllExport const std::vector& unbounded_sequence_int64_field() const; - - /*! - * @brief This function returns a reference to member unbounded_sequence_int64_field - * @return Reference to member unbounded_sequence_int64_field - */ - eProsima_user_DllExport std::vector& unbounded_sequence_int64_field(); - - - /*! - * @brief This function copies the value in member unbounded_sequence_uint64_field - * @param _unbounded_sequence_uint64_field New value to be copied in member unbounded_sequence_uint64_field - */ - eProsima_user_DllExport void unbounded_sequence_uint64_field( - const std::vector& _unbounded_sequence_uint64_field); - - /*! - * @brief This function moves the value in member unbounded_sequence_uint64_field - * @param _unbounded_sequence_uint64_field New value to be moved in member unbounded_sequence_uint64_field - */ - eProsima_user_DllExport void unbounded_sequence_uint64_field( - std::vector&& _unbounded_sequence_uint64_field); - - /*! - * @brief This function returns a constant reference to member unbounded_sequence_uint64_field - * @return Constant reference to member unbounded_sequence_uint64_field - */ - eProsima_user_DllExport const std::vector& unbounded_sequence_uint64_field() const; - - /*! - * @brief This function returns a reference to member unbounded_sequence_uint64_field - * @return Reference to member unbounded_sequence_uint64_field - */ - eProsima_user_DllExport std::vector& unbounded_sequence_uint64_field(); - - - /*! - * @brief This function copies the value in member unbounded_sequence_float_field - * @param _unbounded_sequence_float_field New value to be copied in member unbounded_sequence_float_field - */ - eProsima_user_DllExport void unbounded_sequence_float_field( - const std::vector& _unbounded_sequence_float_field); - - /*! - * @brief This function moves the value in member unbounded_sequence_float_field - * @param _unbounded_sequence_float_field New value to be moved in member unbounded_sequence_float_field - */ - eProsima_user_DllExport void unbounded_sequence_float_field( - std::vector&& _unbounded_sequence_float_field); - - /*! - * @brief This function returns a constant reference to member unbounded_sequence_float_field - * @return Constant reference to member unbounded_sequence_float_field - */ - eProsima_user_DllExport const std::vector& unbounded_sequence_float_field() const; - - /*! - * @brief This function returns a reference to member unbounded_sequence_float_field - * @return Reference to member unbounded_sequence_float_field - */ - eProsima_user_DllExport std::vector& unbounded_sequence_float_field(); - - - /*! - * @brief This function copies the value in member unbounded_sequence_double_field - * @param _unbounded_sequence_double_field New value to be copied in member unbounded_sequence_double_field - */ - eProsima_user_DllExport void unbounded_sequence_double_field( - const std::vector& _unbounded_sequence_double_field); - - /*! - * @brief This function moves the value in member unbounded_sequence_double_field - * @param _unbounded_sequence_double_field New value to be moved in member unbounded_sequence_double_field - */ - eProsima_user_DllExport void unbounded_sequence_double_field( - std::vector&& _unbounded_sequence_double_field); - - /*! - * @brief This function returns a constant reference to member unbounded_sequence_double_field - * @return Constant reference to member unbounded_sequence_double_field - */ - eProsima_user_DllExport const std::vector& unbounded_sequence_double_field() const; - - /*! - * @brief This function returns a reference to member unbounded_sequence_double_field - * @return Reference to member unbounded_sequence_double_field - */ - eProsima_user_DllExport std::vector& unbounded_sequence_double_field(); - - - /*! - * @brief This function copies the value in member unbounded_sequence_long_double_field - * @param _unbounded_sequence_long_double_field New value to be copied in member unbounded_sequence_long_double_field - */ - eProsima_user_DllExport void unbounded_sequence_long_double_field( - const std::vector& _unbounded_sequence_long_double_field); - - /*! - * @brief This function moves the value in member unbounded_sequence_long_double_field - * @param _unbounded_sequence_long_double_field New value to be moved in member unbounded_sequence_long_double_field - */ - eProsima_user_DllExport void unbounded_sequence_long_double_field( - std::vector&& _unbounded_sequence_long_double_field); - - /*! - * @brief This function returns a constant reference to member unbounded_sequence_long_double_field - * @return Constant reference to member unbounded_sequence_long_double_field - */ - eProsima_user_DllExport const std::vector& unbounded_sequence_long_double_field() const; - - /*! - * @brief This function returns a reference to member unbounded_sequence_long_double_field - * @return Reference to member unbounded_sequence_long_double_field - */ - eProsima_user_DllExport std::vector& unbounded_sequence_long_double_field(); - - - /*! - * @brief This function copies the value in member unbounded_sequence_bool_field - * @param _unbounded_sequence_bool_field New value to be copied in member unbounded_sequence_bool_field - */ - eProsima_user_DllExport void unbounded_sequence_bool_field( - const std::vector& _unbounded_sequence_bool_field); - - /*! - * @brief This function moves the value in member unbounded_sequence_bool_field - * @param _unbounded_sequence_bool_field New value to be moved in member unbounded_sequence_bool_field - */ - eProsima_user_DllExport void unbounded_sequence_bool_field( - std::vector&& _unbounded_sequence_bool_field); - - /*! - * @brief This function returns a constant reference to member unbounded_sequence_bool_field - * @return Constant reference to member unbounded_sequence_bool_field - */ - eProsima_user_DllExport const std::vector& unbounded_sequence_bool_field() const; - - /*! - * @brief This function returns a reference to member unbounded_sequence_bool_field - * @return Reference to member unbounded_sequence_bool_field - */ - eProsima_user_DllExport std::vector& unbounded_sequence_bool_field(); - - - /*! - * @brief This function copies the value in member unbounded_sequence_string_field - * @param _unbounded_sequence_string_field New value to be copied in member unbounded_sequence_string_field - */ - eProsima_user_DllExport void unbounded_sequence_string_field( - const std::vector& _unbounded_sequence_string_field); - - /*! - * @brief This function moves the value in member unbounded_sequence_string_field - * @param _unbounded_sequence_string_field New value to be moved in member unbounded_sequence_string_field - */ - eProsima_user_DllExport void unbounded_sequence_string_field( - std::vector&& _unbounded_sequence_string_field); - - /*! - * @brief This function returns a constant reference to member unbounded_sequence_string_field - * @return Constant reference to member unbounded_sequence_string_field - */ - eProsima_user_DllExport const std::vector& unbounded_sequence_string_field() const; - - /*! - * @brief This function returns a reference to member unbounded_sequence_string_field - * @return Reference to member unbounded_sequence_string_field - */ - eProsima_user_DllExport std::vector& unbounded_sequence_string_field(); - - - /*! - * @brief This function copies the value in member unbounded_sequence_enum_field - * @param _unbounded_sequence_enum_field New value to be copied in member unbounded_sequence_enum_field - */ - eProsima_user_DllExport void unbounded_sequence_enum_field( - const std::vector& _unbounded_sequence_enum_field); - - /*! - * @brief This function moves the value in member unbounded_sequence_enum_field - * @param _unbounded_sequence_enum_field New value to be moved in member unbounded_sequence_enum_field - */ - eProsima_user_DllExport void unbounded_sequence_enum_field( - std::vector&& _unbounded_sequence_enum_field); - - /*! - * @brief This function returns a constant reference to member unbounded_sequence_enum_field - * @return Constant reference to member unbounded_sequence_enum_field - */ - eProsima_user_DllExport const std::vector& unbounded_sequence_enum_field() const; - - /*! - * @brief This function returns a reference to member unbounded_sequence_enum_field - * @return Reference to member unbounded_sequence_enum_field - */ - eProsima_user_DllExport std::vector& unbounded_sequence_enum_field(); - - - /*! - * @brief This function copies the value in member unbounded_sequence_enum2_field - * @param _unbounded_sequence_enum2_field New value to be copied in member unbounded_sequence_enum2_field - */ - eProsima_user_DllExport void unbounded_sequence_enum2_field( - const std::vector& _unbounded_sequence_enum2_field); - - /*! - * @brief This function moves the value in member unbounded_sequence_enum2_field - * @param _unbounded_sequence_enum2_field New value to be moved in member unbounded_sequence_enum2_field - */ - eProsima_user_DllExport void unbounded_sequence_enum2_field( - std::vector&& _unbounded_sequence_enum2_field); - - /*! - * @brief This function returns a constant reference to member unbounded_sequence_enum2_field - * @return Constant reference to member unbounded_sequence_enum2_field - */ - eProsima_user_DllExport const std::vector& unbounded_sequence_enum2_field() const; - - /*! - * @brief This function returns a reference to member unbounded_sequence_enum2_field - * @return Reference to member unbounded_sequence_enum2_field - */ - eProsima_user_DllExport std::vector& unbounded_sequence_enum2_field(); - - - /*! - * @brief This function copies the value in member unbounded_sequence_struct_field - * @param _unbounded_sequence_struct_field New value to be copied in member unbounded_sequence_struct_field - */ - eProsima_user_DllExport void unbounded_sequence_struct_field( - const std::vector& _unbounded_sequence_struct_field); - - /*! - * @brief This function moves the value in member unbounded_sequence_struct_field - * @param _unbounded_sequence_struct_field New value to be moved in member unbounded_sequence_struct_field - */ - eProsima_user_DllExport void unbounded_sequence_struct_field( - std::vector&& _unbounded_sequence_struct_field); - - /*! - * @brief This function returns a constant reference to member unbounded_sequence_struct_field - * @return Constant reference to member unbounded_sequence_struct_field - */ - eProsima_user_DllExport const std::vector& unbounded_sequence_struct_field() const; - - /*! - * @brief This function returns a reference to member unbounded_sequence_struct_field - * @return Reference to member unbounded_sequence_struct_field - */ - eProsima_user_DllExport std::vector& unbounded_sequence_struct_field(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const ContentFilterTestType& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - char m_char_field; - uint8_t m_uint8_field; - int16_t m_int16_field; - uint16_t m_uint16_field; - int32_t m_int32_field; - uint32_t m_uint32_field; - int64_t m_int64_field; - uint64_t m_uint64_field; - float m_float_field; - double m_double_field; - long double m_long_double_field; - bool m_bool_field; - std::string m_string_field; - Color m_enum_field; - Material m_enum2_field; - StructType m_struct_field; - std::array m_array_char_field; - std::array m_array_uint8_field; - std::array m_array_int16_field; - std::array m_array_uint16_field; - std::array m_array_int32_field; - std::array m_array_uint32_field; - std::array m_array_int64_field; - std::array m_array_uint64_field; - std::array m_array_float_field; - std::array m_array_double_field; - std::array m_array_long_double_field; - std::array m_array_bool_field; - std::array m_array_string_field; - std::array m_array_enum_field; - std::array m_array_enum2_field; - std::array m_array_struct_field; - std::vector m_bounded_sequence_char_field; - std::vector m_bounded_sequence_uint8_field; - std::vector m_bounded_sequence_int16_field; - std::vector m_bounded_sequence_uint16_field; - std::vector m_bounded_sequence_int32_field; - std::vector m_bounded_sequence_uint32_field; - std::vector m_bounded_sequence_int64_field; - std::vector m_bounded_sequence_uint64_field; - std::vector m_bounded_sequence_float_field; - std::vector m_bounded_sequence_double_field; - std::vector m_bounded_sequence_long_double_field; - std::vector m_bounded_sequence_bool_field; - std::vector m_bounded_sequence_string_field; - std::vector m_bounded_sequence_enum_field; - std::vector m_bounded_sequence_enum2_field; - std::vector m_bounded_sequence_struct_field; - std::vector m_unbounded_sequence_char_field; - std::vector m_unbounded_sequence_uint8_field; - std::vector m_unbounded_sequence_int16_field; - std::vector m_unbounded_sequence_uint16_field; - std::vector m_unbounded_sequence_int32_field; - std::vector m_unbounded_sequence_uint32_field; - std::vector m_unbounded_sequence_int64_field; - std::vector m_unbounded_sequence_uint64_field; - std::vector m_unbounded_sequence_float_field; - std::vector m_unbounded_sequence_double_field; - std::vector m_unbounded_sequence_long_double_field; - std::vector m_unbounded_sequence_bool_field; - std::vector m_unbounded_sequence_string_field; - std::vector m_unbounded_sequence_enum_field; - std::vector m_unbounded_sequence_enum2_field; - std::vector m_unbounded_sequence_struct_field; - -}; - - -#endif // _FAST_DDS_GENERATED_CONTENTFILTERTESTTYPE_H_ - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/test/unittest/dds/topic/TopicTests.cpp b/test/unittest/dds/topic/TopicTests.cpp index bd102150bfe..94b38e4ee46 100644 --- a/test/unittest/dds/topic/TopicTests.cpp +++ b/test/unittest/dds/topic/TopicTests.cpp @@ -15,30 +15,19 @@ #include #include -#include #include +#include +#include +#include +#include #include #include -#include -#include - -#include -#include -#include - -#include -#include - +#include namespace eprosima { namespace fastdds { namespace dds { -using fastrtps::TopicAttributes; -using fastrtps::xmlparser::XMLProfileManager; -using fastrtps::xmlparser::XMLP_ret; - - class FooType { public: @@ -143,21 +132,21 @@ TEST(TopicTests, ChangeTopicQos) ASSERT_NE(topic, nullptr); TopicQos qos; - ASSERT_EQ(topic->get_qos(qos), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(topic->get_qos(qos), RETCODE_OK); ASSERT_EQ(qos, TOPIC_QOS_DEFAULT); qos.reliability().kind = RELIABLE_RELIABILITY_QOS; - ASSERT_EQ(topic->set_qos(qos), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(topic->set_qos(qos), RETCODE_OK); TopicQos tqos; - ASSERT_EQ(topic->get_qos(tqos), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(topic->get_qos(tqos), RETCODE_OK); ASSERT_TRUE(qos == tqos); ASSERT_EQ(tqos.reliability().kind, RELIABLE_RELIABILITY_QOS); - ASSERT_TRUE(participant->delete_topic(topic) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(participant->delete_topic(topic) == RETCODE_OK); + ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == RETCODE_OK); } @@ -175,8 +164,8 @@ TEST(TopicTests, GetTopicParticipant) ASSERT_EQ(topic->get_participant(), participant); - ASSERT_TRUE(participant->delete_topic(topic) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(participant->delete_topic(topic) == RETCODE_OK); + ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == RETCODE_OK); } void set_listener_test ( @@ -184,7 +173,7 @@ void set_listener_test ( TopicListener* listener, StatusMask mask) { - ASSERT_EQ(topic->set_listener(listener, mask), ReturnCode_t::RETCODE_OK); + ASSERT_EQ(topic->set_listener(listener, mask), RETCODE_OK); ASSERT_EQ(topic->get_status_mask(), mask); } @@ -225,8 +214,8 @@ TEST(TopicTests, SetListener) std::get<2>(testing_case)); } - ASSERT_TRUE(participant->delete_topic(topic) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == ReturnCode_t::RETCODE_OK); + ASSERT_TRUE(participant->delete_topic(topic) == RETCODE_OK); + ASSERT_TRUE(DomainParticipantFactory::get_instance()->delete_participant(participant) == RETCODE_OK); } /* @@ -301,12 +290,12 @@ TEST(TopicTests, InstancePolicyAllocationConsistencyNotKeyed) ASSERT_NE(topic5, nullptr); // Next QoS config checks the default qos configuration, - // set_qos() should return ReturnCode_t::RETCODE_OK = 0 + // set_qos() should return RETCODE_OK = 0 TopicQos qos2 = TOPIC_QOS_DEFAULT; Topic* default_topic1 = participant->create_topic("footopic6", type.get_type_name(), qos2); ASSERT_NE(default_topic1, nullptr); - ASSERT_EQ(ReturnCode_t::RETCODE_OK, default_topic1->set_qos(qos2)); + ASSERT_EQ(RETCODE_OK, default_topic1->set_qos(qos2)); // Below an ampliation of the last comprobation, for which it is proved the case of < 0 (-1), // which also means infinite value. @@ -316,35 +305,35 @@ TEST(TopicTests, InstancePolicyAllocationConsistencyNotKeyed) qos2.resource_limits().max_instances = -1; qos2.resource_limits().max_samples_per_instance = -1; - ASSERT_EQ(ReturnCode_t::RETCODE_OK, default_topic1->set_qos(qos2)); + ASSERT_EQ(RETCODE_OK, default_topic1->set_qos(qos2)); // Next QoS config checks that if user sets max_samples < ( max_instances * max_samples_per_instance ) , - // set_qos() should return ReturnCode_t::RETCODE_OK = 0 + // set_qos() should return RETCODE_OK = 0 // By not using instances, instance allocation consistency is not checked. qos2.resource_limits().max_samples = 4999; qos2.resource_limits().max_instances = 10; qos2.resource_limits().max_samples_per_instance = 500; - ASSERT_EQ(ReturnCode_t::RETCODE_OK, default_topic1->set_qos(qos2)); + ASSERT_EQ(RETCODE_OK, default_topic1->set_qos(qos2)); // Next QoS config checks that if user sets max_samples > ( max_instances * max_samples_per_instance ) , - // set_qos() should return ReturnCode_t::RETCODE_OK = 0 + // set_qos() should return RETCODE_OK = 0 // By not using instances, instance allocation consistency is not checked. qos2.resource_limits().max_samples = 5001; qos2.resource_limits().max_instances = 10; qos2.resource_limits().max_samples_per_instance = 500; - ASSERT_EQ(ReturnCode_t::RETCODE_OK, default_topic1->set_qos(qos2)); + ASSERT_EQ(RETCODE_OK, default_topic1->set_qos(qos2)); // Next QoS config checks that if user sets max_samples infinite // and ( max_instances * max_samples_per_instance ) finite, - // set_qos() should return ReturnCode_t::RETCODE_OK = 0 + // set_qos() should return RETCODE_OK = 0 // By not using instances, instance allocation consistency is not checked. qos2.resource_limits().max_samples = 0; qos2.resource_limits().max_instances = 10; qos2.resource_limits().max_samples_per_instance = 500; - ASSERT_EQ(ReturnCode_t::RETCODE_OK, default_topic1->set_qos(qos2)); + ASSERT_EQ(RETCODE_OK, default_topic1->set_qos(qos2)); } /* @@ -429,12 +418,12 @@ TEST(TopicTests, InstancePolicyAllocationConsistencyKeyed) ASSERT_NE(topic6, nullptr); // Next QoS config checks the default qos configuration, - // set_qos() should return ReturnCode_t::RETCODE_OK = 0. + // set_qos() should return RETCODE_OK = 0. TopicQos qos2 = TOPIC_QOS_DEFAULT; Topic* default_topic1 = participant->create_topic("footopic7", type.get_type_name(), qos2); ASSERT_NE(default_topic1, nullptr); - ASSERT_EQ(ReturnCode_t::RETCODE_OK, default_topic1->set_qos(qos2)); + ASSERT_EQ(RETCODE_OK, default_topic1->set_qos(qos2)); // Below an ampliation of the last comprobation, for which it is proved the case of < 0 (-1), // which also means infinite value. @@ -443,7 +432,7 @@ TEST(TopicTests, InstancePolicyAllocationConsistencyKeyed) qos2.resource_limits().max_instances = -1; qos2.resource_limits().max_samples_per_instance = -1; - ASSERT_EQ(ReturnCode_t::RETCODE_OK, default_topic1->set_qos(qos2)); + ASSERT_EQ(RETCODE_OK, default_topic1->set_qos(qos2)); // Next QoS config checks that if user sets max_samples < ( max_instances * max_samples_per_instance ) , // set_qos() should return a value != 0 (not OK) @@ -451,32 +440,32 @@ TEST(TopicTests, InstancePolicyAllocationConsistencyKeyed) qos2.resource_limits().max_instances = 10; qos2.resource_limits().max_samples_per_instance = 500; - ASSERT_NE(ReturnCode_t::RETCODE_OK, default_topic1->set_qos(qos2)); + ASSERT_NE(RETCODE_OK, default_topic1->set_qos(qos2)); // Next QoS config checks that if user sets max_samples > ( max_instances * max_samples_per_instance ) , - // set_qos() should return ReturnCode_t::RETCODE_OK = 0. + // set_qos() should return RETCODE_OK = 0. qos2.resource_limits().max_samples = 5001; qos2.resource_limits().max_instances = 10; qos2.resource_limits().max_samples_per_instance = 500; - ASSERT_EQ(ReturnCode_t::RETCODE_OK, default_topic1->set_qos(qos2)); + ASSERT_EQ(RETCODE_OK, default_topic1->set_qos(qos2)); // Next QoS config checks that if user sets max_samples = ( max_instances * max_samples_per_instance ) , - // set_qos() should return ReturnCode_t::RETCODE_OK = 0. + // set_qos() should return RETCODE_OK = 0. qos2.resource_limits().max_samples = 5000; qos2.resource_limits().max_instances = 10; qos2.resource_limits().max_samples_per_instance = 500; - ASSERT_EQ(ReturnCode_t::RETCODE_OK, default_topic1->set_qos(qos2)); + ASSERT_EQ(RETCODE_OK, default_topic1->set_qos(qos2)); // Next QoS config checks that if user sets max_samples infinite // and ( max_instances * max_samples_per_instance ) finite, - // set_qos() should return ReturnCode_t::RETCODE_OK = 0. + // set_qos() should return RETCODE_OK = 0. qos2.resource_limits().max_samples = 0; qos2.resource_limits().max_instances = 10; qos2.resource_limits().max_samples_per_instance = 500; - ASSERT_EQ(ReturnCode_t::RETCODE_OK, default_topic1->set_qos(qos2)); + ASSERT_EQ(RETCODE_OK, default_topic1->set_qos(qos2)); } } // namespace dds diff --git a/test/unittest/dds/xtypes/type_representation/CMakeLists.txt b/test/unittest/dds/xtypes/type_representation/CMakeLists.txt new file mode 100644 index 00000000000..52e1664ecbb --- /dev/null +++ b/test/unittest/dds/xtypes/type_representation/CMakeLists.txt @@ -0,0 +1,52 @@ +# Copyright 2023 Proyectos y Sistemas de Mantenimiento SL (eProsima). +# +# Licensed 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 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +set(TYPEOBJECTUTILSTESTS_SOURCE TypeObjectUtilsTests.cpp) +set(TYPEOBJECTREGISTRYTESTS_SOURCE TypeObjectRegistryTests.cpp) + +if(WIN32) + add_definitions(-D_WIN32_WINNT=0x0601) +endif() + +add_executable(TypeObjectUtilsTests ${TYPEOBJECTUTILSTESTS_SOURCE}) +target_compile_definitions(TypeObjectUtilsTests PRIVATE + $<$>,$>:__DEBUG> + $<$:__INTERNALDEBUG> # Internal debug activated. + ) +target_include_directories(TypeObjectUtilsTests PRIVATE + ${PROJECT_SOURCE_DIR}/include ${PROJECT_BINARY_DIR}/include + ${PROJECT_SOURCE_DIR}/src/cpp + ) +target_link_libraries(TypeObjectUtilsTests + fastcdr + fastdds + GTest::gtest + ${CMAKE_DL_LIBS}) +gtest_discover_tests(TypeObjectUtilsTests SOURCES ${TYPEOBJECTUTILSTESTS_SOURCE}) + +add_executable(TypeObjectRegistryTests ${TYPEOBJECTREGISTRYTESTS_SOURCE}) +target_compile_definitions(TypeObjectRegistryTests PRIVATE + $<$>,$>:__DEBUG> + $<$:__INTERNALDEBUG> # Internal debug activated. + ) +target_include_directories(TypeObjectRegistryTests PRIVATE + ${PROJECT_SOURCE_DIR}/include ${PROJECT_BINARY_DIR}/include + ${PROJECT_SOURCE_DIR}/src/cpp + ) +target_link_libraries(TypeObjectRegistryTests + fastcdr + fastdds + GTest::gtest + ${CMAKE_DL_LIBS}) + gtest_discover_tests(TypeObjectRegistryTests SOURCES ${TYPEOBJECTREGISTRYTESTS_SOURCE}) diff --git a/test/unittest/dds/xtypes/type_representation/TypeObjectRegistryTests.cpp b/test/unittest/dds/xtypes/type_representation/TypeObjectRegistryTests.cpp new file mode 100644 index 00000000000..7e331436d42 --- /dev/null +++ b/test/unittest/dds/xtypes/type_representation/TypeObjectRegistryTests.cpp @@ -0,0 +1,265 @@ +// Copyright 2023 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/** + * @file + * This file contains unit tests related to the TypeObjectRegistry API. + */ + +#include + +#include +#include +#include +#include + +namespace eprosima { +namespace fastdds { +namespace dds { +namespace xtypes { + +// Test TypeObjectRegistry::register_type_object +TEST(TypeObjectRegistryTests, register_type_object) +{ + TypeIdentifier type_id; + type_id._d(TK_BYTE); + CompleteAliasType complete_alias_type; + complete_alias_type.header().detail().type_name("alias_name"); + CompleteTypeObject type_object; + type_object.alias_type(complete_alias_type); +#if !defined(NDEBUG) + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_PRECONDITION_NOT_MET, + DomainParticipantFactory::get_instance()->type_object_registry().register_type_object("alias", + type_object)); +#endif // if !defined(NDEBUG) + complete_alias_type.body().common().related_type(type_id); + type_object.alias_type(complete_alias_type); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_PRECONDITION_NOT_MET, + DomainParticipantFactory::get_instance()->type_object_registry().register_type_object("", type_object)); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, + DomainParticipantFactory::get_instance()->type_object_registry().register_type_object("alias", + type_object)); + complete_alias_type.header().detail().type_name("other_name"); + type_object.alias_type(complete_alias_type); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_BAD_PARAMETER, + DomainParticipantFactory::get_instance()->type_object_registry().register_type_object("alias", + type_object)); +} + +// Test TypeObjectRegistry::register_type_identifier +TEST(TypeObjectRegistryTests, register_type_identifier) +{ + TypeIdentifier type_id; + type_id.equivalence_hash(EquivalenceHash()); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_PRECONDITION_NOT_MET, + DomainParticipantFactory::get_instance()->type_object_registry().register_type_identifier("hash_type_id", + type_id)); + StringSTypeDefn small_string; + small_string.bound(10); + type_id.string_sdefn(small_string); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_PRECONDITION_NOT_MET, + DomainParticipantFactory::get_instance()->type_object_registry().register_type_identifier("", + type_id)); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, + DomainParticipantFactory::get_instance()->type_object_registry().register_type_identifier("string_type_id", + type_id)); + type_id.string_sdefn().bound(5); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_BAD_PARAMETER, + DomainParticipantFactory::get_instance()->type_object_registry().register_type_identifier("string_type_id", + type_id)); +} + +// Test TypeObjectRegistry::get_type_objects +TEST(TypeObjectRegistryTests, get_type_objects) +{ + TypeObjectPair type_objects; + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_PRECONDITION_NOT_MET, + DomainParticipantFactory::get_instance()->type_object_registry().get_type_objects("", type_objects)); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_NO_DATA, + DomainParticipantFactory::get_instance()->type_object_registry().get_type_objects("test_name", + type_objects)); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_BAD_PARAMETER, + DomainParticipantFactory::get_instance()->type_object_registry().get_type_objects(boolean_type_name, + type_objects)); + TypeIdentifier alias_type_id; + alias_type_id._d(TK_BYTE); + CompleteAliasType complete_alias_type; + complete_alias_type.header().detail().type_name("alias_name"); + complete_alias_type.body().common().related_type(alias_type_id); + TypeObject type_object; + CompleteTypeObject complete_type_object; + complete_type_object.alias_type(complete_alias_type); + type_object.complete(complete_type_object); + ASSERT_EQ(eprosima::fastdds::dds::RETCODE_OK, + DomainParticipantFactory::get_instance()->type_object_registry().register_type_object("test_name", + type_object.complete())); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, + DomainParticipantFactory::get_instance()->type_object_registry().get_type_objects("test_name", + type_objects)); + EXPECT_EQ(type_objects.complete_type_object, type_object); +} + +// Test TypeObjectRegistry::get_type_identifiers +TEST(TypeObjectRegistryTests, get_type_identifiers) +{ + TypeIdentifierPair type_ids; + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_PRECONDITION_NOT_MET, + DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers("", type_ids)); + TypeIdentifier none_type_id; + TypeIdentifier type_id; + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_NO_DATA, + DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers("test_type", + type_ids)); + + // Register fully descriptive TypeIdentifier + StringSTypeDefn small_string = TypeObjectUtils::build_string_s_type_defn(32); + type_id.string_sdefn(small_string); + ASSERT_EQ(eprosima::fastdds::dds::RETCODE_OK, + DomainParticipantFactory::get_instance()->type_object_registry().register_type_identifier("test_type", + type_id)); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, + DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers("test_type", + type_ids)); + EXPECT_EQ(type_ids.type_identifier1(), type_id); + EXPECT_EQ(type_ids.type_identifier2(), none_type_id); + + // Register hash TypeIdentifier + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_NO_DATA, + DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers("alias", type_ids)); + TypeIdentifier alias_type_id; + alias_type_id._d(TK_BYTE); + CompleteAliasType complete_alias_type; + complete_alias_type.header().detail().type_name("alias_name"); + complete_alias_type.body().common().related_type(alias_type_id); + CompleteTypeObject type_object; + type_object.alias_type(complete_alias_type); + ASSERT_EQ(eprosima::fastdds::dds::RETCODE_OK, + DomainParticipantFactory::get_instance()->type_object_registry().register_type_object("alias", + type_object)); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, + DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers("alias", type_ids)); + EXPECT_TRUE((type_ids.type_identifier1()._d() == EK_MINIMAL && type_ids.type_identifier2()._d() == EK_COMPLETE) || + (type_ids.type_identifier1()._d() == EK_COMPLETE && type_ids.type_identifier2()._d() == EK_MINIMAL)); +} + +// Test TypeObjectRegistry::get_type_identifiers for primitive types +TEST(TypeObjectRegistryTests, get_type_identifiers_primitive_types) +{ + TypeIdentifierPair type_ids; + TypeIdentifier none_type_id; + TypeIdentifier type_id; + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, + DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers(boolean_type_name, + type_ids)); + type_id._d(TK_BOOLEAN); + EXPECT_EQ(type_ids.type_identifier1(), type_id); + EXPECT_EQ(type_ids.type_identifier2(), none_type_id); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, + DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers(byte_type_name, + type_ids)); + type_id._d(TK_BYTE); + EXPECT_EQ(type_ids.type_identifier1(), type_id); + EXPECT_EQ(type_ids.type_identifier2(), none_type_id); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, + DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers(int16_type_name, + type_ids)); + type_id._d(TK_INT16); + EXPECT_EQ(type_ids.type_identifier1(), type_id); + EXPECT_EQ(type_ids.type_identifier2(), none_type_id); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, + DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers(int32_type_name, + type_ids)); + type_id._d(TK_INT32); + EXPECT_EQ(type_ids.type_identifier1(), type_id); + EXPECT_EQ(type_ids.type_identifier2(), none_type_id); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, + DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers(int64_type_name, + type_ids)); + type_id._d(TK_INT64); + EXPECT_EQ(type_ids.type_identifier1(), type_id); + EXPECT_EQ(type_ids.type_identifier2(), none_type_id); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, + DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers(uint16_type_name, + type_ids)); + type_id._d(TK_UINT16); + EXPECT_EQ(type_ids.type_identifier1(), type_id); + EXPECT_EQ(type_ids.type_identifier2(), none_type_id); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, + DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers(uint32_type_name, + type_ids)); + type_id._d(TK_UINT32); + EXPECT_EQ(type_ids.type_identifier1(), type_id); + EXPECT_EQ(type_ids.type_identifier2(), none_type_id); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, + DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers(uint64_type_name, + type_ids)); + type_id._d(TK_UINT64); + EXPECT_EQ(type_ids.type_identifier1(), type_id); + EXPECT_EQ(type_ids.type_identifier2(), none_type_id); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, + DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers(float32_type_name, + type_ids)); + type_id._d(TK_FLOAT32); + EXPECT_EQ(type_ids.type_identifier1(), type_id); + EXPECT_EQ(type_ids.type_identifier2(), none_type_id); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, + DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers(float64_type_name, + type_ids)); + type_id._d(TK_FLOAT64); + EXPECT_EQ(type_ids.type_identifier1(), type_id); + EXPECT_EQ(type_ids.type_identifier2(), none_type_id); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, + DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers(float128_type_name, + type_ids)); + type_id._d(TK_FLOAT128); + EXPECT_EQ(type_ids.type_identifier1(), type_id); + EXPECT_EQ(type_ids.type_identifier2(), none_type_id); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, + DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers(int8_type_name, + type_ids)); + type_id._d(TK_INT8); + EXPECT_EQ(type_ids.type_identifier1(), type_id); + EXPECT_EQ(type_ids.type_identifier2(), none_type_id); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, + DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers(uint8_type_name, + type_ids)); + type_id._d(TK_UINT8); + EXPECT_EQ(type_ids.type_identifier1(), type_id); + EXPECT_EQ(type_ids.type_identifier2(), none_type_id); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, + DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers(char8_type_name, + type_ids)); + type_id._d(TK_CHAR8); + EXPECT_EQ(type_ids.type_identifier1(), type_id); + EXPECT_EQ(type_ids.type_identifier2(), none_type_id); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, + DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers(char16_type_name, + type_ids)); + type_id._d(TK_CHAR16); + EXPECT_EQ(type_ids.type_identifier1(), type_id); + EXPECT_EQ(type_ids.type_identifier2(), none_type_id); +} + +} // xtypes +} // dds +} // fastdds +} // eprosima + +int main( + int argc, + char** argv) +{ + testing::InitGoogleTest(&argc, argv); + return RUN_ALL_TESTS(); +} diff --git a/test/unittest/dds/xtypes/type_representation/TypeObjectUtilsTests.cpp b/test/unittest/dds/xtypes/type_representation/TypeObjectUtilsTests.cpp new file mode 100644 index 00000000000..55cbd0b5d6a --- /dev/null +++ b/test/unittest/dds/xtypes/type_representation/TypeObjectUtilsTests.cpp @@ -0,0 +1,3457 @@ +// Copyright 2023 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/** + * @file + * This file contains negative tests related to the TypeObjectUtils API. + */ + +#include + +#include + +#include +#include +#include +#include +#include + +namespace eprosima { +namespace fastdds { +namespace dds { +namespace xtypes { + +// Build TypeObjectHashId object with wrong discriminator. +TEST(TypeObjectUtilsTests, build_type_object_hash_id_wrong_discriminator) +{ + uint8_t bad_discriminator = EK_BOTH; + EquivalenceHash hash; + EXPECT_THROW(TypeObjectHashId type_object_hash_id = TypeObjectUtils::build_type_object_hash_id( + bad_discriminator, hash), InvalidArgumentError); + EXPECT_NO_THROW(TypeObjectHashId type_object_hash_id = TypeObjectUtils::build_type_object_hash_id( + EK_MINIMAL, hash)); + EXPECT_NO_THROW(TypeObjectHashId type_object_hash_id = TypeObjectUtils::build_type_object_hash_id( + EK_COMPLETE, hash)); +} + +// Build inconsistent StructMemberFlag +TEST(TypeObjectUtilsTests, build_inconsistent_struct_member_flag) +{ + EXPECT_THROW(TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::DISCARD, + true, false, true, false), InvalidArgumentError); + EXPECT_NO_THROW(TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::DISCARD, + true, false, false, false)); + EXPECT_NO_THROW(TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructKind::DISCARD, + false, false, true, false)); +} + +// Build StringLTypeDefn with bound smaller than 256. +TEST(TypeObjectUtilsTests, build_string_l_type_defn_small_bound) +{ + LBound wrong_bound = 255; + EXPECT_THROW(StringLTypeDefn string_l_type_defn = TypeObjectUtils::build_string_l_type_defn(wrong_bound), + InvalidArgumentError); + EXPECT_NO_THROW(StringLTypeDefn string_l_type_defn = TypeObjectUtils::build_string_l_type_defn(256)); +} + +void register_empty_structure_type_object() +{ + std::string empty_struct_name = "empty_structure"; + CompleteTypeDetail detail = TypeObjectUtils::build_complete_type_detail( + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional(), empty_struct_name); + CompleteStructHeader header = TypeObjectUtils::build_complete_struct_header(TypeIdentifier(), detail); + CompleteStructType struct_type = TypeObjectUtils::build_complete_struct_type(0, header, CompleteStructMemberSeq()); + TypeObjectUtils::build_and_register_struct_type_object(struct_type, empty_struct_name); +} + +void register_plain_seq_type_object( + eprosima::fastcdr::external complete_typeid) +{ + std::string plain_seq_name = "plain_sequence"; + CollectionElementFlag flags = TypeObjectUtils::build_collection_element_flag( + eprosima::fastdds::dds::xtypes::TryConstructKind::USE_DEFAULT, false); + PlainCollectionHeader header = TypeObjectUtils::build_plain_collection_header(EK_COMPLETE, flags); + PlainSequenceSElemDefn plain_seq = TypeObjectUtils::build_plain_sequence_s_elem_defn( + header, 255, complete_typeid); + TypeObjectUtils::build_and_register_s_sequence_type_identifier(plain_seq, plain_seq_name); +} + +void register_alias_type_object() +{ + TypeIdentifier primitive_type_id; + primitive_type_id._d(TK_INT16); + CommonAliasBody int16_common_body = TypeObjectUtils::build_common_alias_body(0, primitive_type_id); + CompleteAliasBody int16_body = TypeObjectUtils::build_complete_alias_body(int16_common_body, + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional()); + CompleteTypeDetail empty_type_detail = TypeObjectUtils::build_complete_type_detail( + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional(), "type_name"); + CompleteAliasHeader alias_header = TypeObjectUtils::build_complete_alias_header(empty_type_detail); + CompleteAliasType alias_type = TypeObjectUtils::build_complete_alias_type(0, alias_header, int16_body); + TypeObjectUtils::build_and_register_alias_type_object(alias_type, "int16_alias"); +} + +// Build PlainSequenceSElemDefn with inconsistent parameters. +TEST(TypeObjectUtilsTests, build_plain_sequence_s_elem_defn_inconsistencies) +{ + eprosima::fastcdr::external test_identifier{new TypeIdentifier()}; + CollectionElementFlag flags = TypeObjectUtils::build_collection_element_flag( + eprosima::fastdds::dds::xtypes::TryConstructKind::TRIM, false); + PlainCollectionHeader complete_header = TypeObjectUtils::build_plain_collection_header( + EK_COMPLETE, flags); +#if !defined(NDEBUG) + PlainCollectionHeader wrong_header; + // Inconsistent header CollectionElementFlags + EXPECT_THROW(PlainSequenceSElemDefn plain_seq = TypeObjectUtils::build_plain_sequence_s_elem_defn( + wrong_header, 10, test_identifier), InvalidArgumentError); + wrong_header.element_flags(flags); + // Inconsistent header EquivalenceKind + EXPECT_THROW(PlainSequenceSElemDefn plain_seq = TypeObjectUtils::build_plain_sequence_s_elem_defn( + wrong_header, 10, test_identifier), InvalidArgumentError); + // Non-initialized TypeIdentifier + EXPECT_THROW(PlainSequenceSElemDefn plain_seq = TypeObjectUtils::build_plain_sequence_s_elem_defn( + complete_header, 10, test_identifier), InvalidArgumentError); +#endif // !defined(NDEBUG) + // Check SBound consistency + SBound wrong_bound = 0; + EXPECT_THROW(PlainSequenceSElemDefn plain_seq = TypeObjectUtils::build_plain_sequence_s_elem_defn( + complete_header, wrong_bound, test_identifier), InvalidArgumentError); + + // Primitive TypeIdentifier + EXPECT_NO_THROW(test_identifier->_d(TK_BOOLEAN)); + // TypeIdentifier inconsistent with complete header + EXPECT_THROW(PlainSequenceSElemDefn plain_seq = TypeObjectUtils::build_plain_sequence_s_elem_defn( + complete_header, 10, test_identifier), InvalidArgumentError); + PlainCollectionHeader minimal_header = TypeObjectUtils::build_plain_collection_header( + EK_MINIMAL, flags); + // TypeIdentifier inconsistent with minimal header + EXPECT_THROW(PlainSequenceSElemDefn plain_seq = TypeObjectUtils::build_plain_sequence_s_elem_defn( + minimal_header, 10, test_identifier), InvalidArgumentError); + PlainCollectionHeader fully_descriptive_header = TypeObjectUtils::build_plain_collection_header( + EK_BOTH, flags); + // TypeIdentifier consistent with fully-descriptive header + EXPECT_NO_THROW(PlainSequenceSElemDefn plain_seq = TypeObjectUtils::build_plain_sequence_s_elem_defn( + fully_descriptive_header, 10, test_identifier)); + // Change discriminator to EK_COMPLETE + register_empty_structure_type_object(); + TypeIdentifierPair type_ids; + DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers("empty_structure", type_ids); + if (EK_COMPLETE == type_ids.type_identifier1()._d()) + { + test_identifier = eprosima::fastcdr::external(new TypeIdentifier(type_ids.type_identifier1())); + } + else + { + test_identifier = eprosima::fastcdr::external(new TypeIdentifier(type_ids.type_identifier2())); + } + // TypeIdentifier consistent with complete header + EXPECT_NO_THROW(PlainSequenceSElemDefn plain_seq = TypeObjectUtils::build_plain_sequence_s_elem_defn( + complete_header, 10, test_identifier)); + // TypeIdentifier inconsistent with minimal header + EXPECT_THROW(PlainSequenceSElemDefn plain_seq = TypeObjectUtils::build_plain_sequence_s_elem_defn( + minimal_header, 10, test_identifier), InvalidArgumentError); + // TypeIdentifier inconsistent with fully-descriptive header + EXPECT_THROW(PlainSequenceSElemDefn plain_seq = TypeObjectUtils::build_plain_sequence_s_elem_defn( + fully_descriptive_header, 10, test_identifier), InvalidArgumentError); + // Change discriminator to EK_MINIMAL + if (EK_COMPLETE == type_ids.type_identifier1()._d()) + { + test_identifier = eprosima::fastcdr::external(new TypeIdentifier(type_ids.type_identifier2())); + } + else + { + test_identifier = eprosima::fastcdr::external(new TypeIdentifier(type_ids.type_identifier1())); + } + // TypeIdentifier inconsistent with complete header + EXPECT_THROW(PlainSequenceSElemDefn plain_seq = TypeObjectUtils::build_plain_sequence_s_elem_defn( + complete_header, 10, test_identifier), InvalidArgumentError); + // TypeIdentifier consistent with minimal header + EXPECT_NO_THROW(PlainSequenceSElemDefn plain_seq = TypeObjectUtils::build_plain_sequence_s_elem_defn( + minimal_header, 10, test_identifier)); + // TypeIdentifier inconsistent with fully-descriptive header + EXPECT_THROW(PlainSequenceSElemDefn plain_seq = TypeObjectUtils::build_plain_sequence_s_elem_defn( + fully_descriptive_header, 10, test_identifier), InvalidArgumentError); +} + +// Build PlainSequenceLElemDefn with inconsistent parameters. +TEST(TypeObjectUtilsTests, build_plain_sequence_l_elem_defn_inconsistencies) +{ + eprosima::fastcdr::external test_identifier{new TypeIdentifier()}; + CollectionElementFlag flags = TypeObjectUtils::build_collection_element_flag( + eprosima::fastdds::dds::xtypes::TryConstructKind::TRIM, false); + PlainCollectionHeader complete_header = TypeObjectUtils::build_plain_collection_header( + EK_COMPLETE, flags); +#if !defined(NDEBUG) + PlainCollectionHeader wrong_header; + // Inconsistent header CollectionElementFlags + EXPECT_THROW(PlainSequenceLElemDefn plain_seq = TypeObjectUtils::build_plain_sequence_l_elem_defn( + wrong_header, 256, test_identifier), InvalidArgumentError); + wrong_header.element_flags(flags); + // Inconsistent header EquivalenceKind + EXPECT_THROW(PlainSequenceLElemDefn plain_seq = TypeObjectUtils::build_plain_sequence_l_elem_defn( + wrong_header, 256, test_identifier), InvalidArgumentError); + // Non-initialized TypeIdentifier + EXPECT_THROW(PlainSequenceLElemDefn plain_seq = TypeObjectUtils::build_plain_sequence_l_elem_defn( + complete_header, 256, test_identifier), InvalidArgumentError); +#endif // !defined(NDEBUG) + // Check LBound consistency + LBound wrong_bound = 255; + EXPECT_THROW(PlainSequenceLElemDefn plain_seq = TypeObjectUtils::build_plain_sequence_l_elem_defn( + complete_header, wrong_bound, test_identifier), InvalidArgumentError); + wrong_bound = 0; + EXPECT_THROW(PlainSequenceLElemDefn plain_seq = TypeObjectUtils::build_plain_sequence_l_elem_defn( + complete_header, wrong_bound, test_identifier), InvalidArgumentError); + + // Primitive TypeIdentifier + EXPECT_NO_THROW(test_identifier->_d(TK_BOOLEAN)); + // TypeIdentifier inconsistent with complete header + EXPECT_THROW(PlainSequenceLElemDefn plain_seq = TypeObjectUtils::build_plain_sequence_l_elem_defn( + complete_header, 256, test_identifier), InvalidArgumentError); + PlainCollectionHeader minimal_header = TypeObjectUtils::build_plain_collection_header( + EK_MINIMAL, flags); + // TypeIdentifier inconsistent with minimal header + EXPECT_THROW(PlainSequenceLElemDefn plain_seq = TypeObjectUtils::build_plain_sequence_l_elem_defn( + minimal_header, 256, test_identifier), InvalidArgumentError); + PlainCollectionHeader fully_descriptive_header = TypeObjectUtils::build_plain_collection_header( + EK_BOTH, flags); + // TypeIdentifier consistent with fully-descriptive header + EXPECT_NO_THROW(PlainSequenceLElemDefn plain_seq = TypeObjectUtils::build_plain_sequence_l_elem_defn( + fully_descriptive_header, 256, test_identifier)); + // Change discriminator to EK_COMPLETE + register_empty_structure_type_object(); + TypeIdentifierPair type_ids; + DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers("empty_structure", type_ids); + if (EK_COMPLETE == type_ids.type_identifier1()._d()) + { + test_identifier = eprosima::fastcdr::external(new TypeIdentifier(type_ids.type_identifier1())); + } + else + { + test_identifier = eprosima::fastcdr::external(new TypeIdentifier(type_ids.type_identifier2())); + } + // TypeIdentifier consistent with complete header + EXPECT_NO_THROW(PlainSequenceLElemDefn plain_seq = TypeObjectUtils::build_plain_sequence_l_elem_defn( + complete_header, 256, test_identifier)); + // TypeIdentifier inconsistent with minimal header + EXPECT_THROW(PlainSequenceLElemDefn plain_seq = TypeObjectUtils::build_plain_sequence_l_elem_defn( + minimal_header, 256, test_identifier), InvalidArgumentError); + // TypeIdentifier inconsistent with fully-descriptive header + EXPECT_THROW(PlainSequenceLElemDefn plain_seq = TypeObjectUtils::build_plain_sequence_l_elem_defn( + fully_descriptive_header, 256, test_identifier), InvalidArgumentError); + // Change discriminator to EK_MINIMAL + if (EK_COMPLETE == type_ids.type_identifier1()._d()) + { + test_identifier = eprosima::fastcdr::external(new TypeIdentifier(type_ids.type_identifier2())); + } + else + { + test_identifier = eprosima::fastcdr::external(new TypeIdentifier(type_ids.type_identifier1())); + } + // TypeIdentifier inconsistent with complete header + EXPECT_THROW(PlainSequenceLElemDefn plain_seq = TypeObjectUtils::build_plain_sequence_l_elem_defn( + complete_header, 256, test_identifier), InvalidArgumentError); + // TypeIdentifier consistent with minimal header + EXPECT_NO_THROW(PlainSequenceLElemDefn plain_seq = TypeObjectUtils::build_plain_sequence_l_elem_defn( + minimal_header, 256, test_identifier)); + // TypeIdentifier inconsistent with fully-descriptive header + EXPECT_THROW(PlainSequenceLElemDefn plain_seq = TypeObjectUtils::build_plain_sequence_l_elem_defn( + fully_descriptive_header, 256, test_identifier), InvalidArgumentError); +} + +// Add inconsistent dimension to array +TEST(TypeObjectUtilsTests, add_inconsistent_array_dimension) +{ + SBoundSeq small_dimensions; + LBoundSeq large_dimensions; + SBound invalid_sbound = 0; + LBound invalid_lbound = 0; + EXPECT_THROW(TypeObjectUtils::add_array_dimension(small_dimensions, invalid_sbound), InvalidArgumentError); + EXPECT_THROW(TypeObjectUtils::add_array_dimension(large_dimensions, invalid_lbound), InvalidArgumentError); +} + +// Build PlainArraySElemDefn with inconsistent parameters. +TEST(TypeObjectUtilsTests, build_plain_array_s_elem_defn_inconsistencies) +{ + eprosima::fastcdr::external test_identifier{new TypeIdentifier()}; + CollectionElementFlag flags = TypeObjectUtils::build_collection_element_flag( + eprosima::fastdds::dds::xtypes::TryConstructKind::TRIM, false); + SBoundSeq bound_seq; + SBound bound = 10; + TypeObjectUtils::add_array_dimension(bound_seq, bound); + PlainCollectionHeader complete_header = TypeObjectUtils::build_plain_collection_header( + EK_COMPLETE, flags); +#if !defined(NDEBUG) + PlainCollectionHeader wrong_header; + // Inconsistent header CollectionElementFlags + EXPECT_THROW(PlainArraySElemDefn plain_array = TypeObjectUtils::build_plain_array_s_elem_defn( + wrong_header, bound_seq, test_identifier), InvalidArgumentError); + wrong_header.element_flags(flags); + // Inconsistent header EquivalenceKind + EXPECT_THROW(PlainArraySElemDefn plain_array = TypeObjectUtils::build_plain_array_s_elem_defn( + wrong_header, bound_seq, test_identifier), InvalidArgumentError); + // Non-initialized TypeIdentifier + EXPECT_THROW(PlainArraySElemDefn plain_array = TypeObjectUtils::build_plain_array_s_elem_defn( + complete_header, bound_seq, test_identifier), InvalidArgumentError); +#endif // !defined(NDEBUG) + // Check SBoundSeq consistency + SBoundSeq wrong_bound_seq; + // Empty array_bound_seq + EXPECT_THROW(PlainArraySElemDefn plain_array = TypeObjectUtils::build_plain_array_s_elem_defn( + complete_header, wrong_bound_seq, test_identifier), InvalidArgumentError); + // Zero element + TypeObjectUtils::add_array_dimension(wrong_bound_seq, bound); + bound = 0; + EXPECT_THROW(TypeObjectUtils::add_array_dimension(wrong_bound_seq, bound), InvalidArgumentError); + wrong_bound_seq.push_back(0); + EXPECT_THROW(PlainArraySElemDefn plain_array = TypeObjectUtils::build_plain_array_s_elem_defn( + complete_header, wrong_bound_seq, test_identifier), InvalidArgumentError); + + // Primitive TypeIdentifier + EXPECT_NO_THROW(test_identifier->_d(TK_BOOLEAN)); + // TypeIdentifier inconsistent with complete header + EXPECT_THROW(PlainArraySElemDefn plain_array = TypeObjectUtils::build_plain_array_s_elem_defn( + complete_header, bound_seq, test_identifier), InvalidArgumentError); + PlainCollectionHeader minimal_header = TypeObjectUtils::build_plain_collection_header( + EK_MINIMAL, flags); + // TypeIdentifier inconsistent with minimal header + EXPECT_THROW(PlainArraySElemDefn plain_array = TypeObjectUtils::build_plain_array_s_elem_defn( + minimal_header, bound_seq, test_identifier), InvalidArgumentError); + PlainCollectionHeader fully_descriptive_header = TypeObjectUtils::build_plain_collection_header( + EK_BOTH, flags); + // TypeIdentifier consistent with fully-descriptive header + EXPECT_NO_THROW(PlainArraySElemDefn plain_array = TypeObjectUtils::build_plain_array_s_elem_defn( + fully_descriptive_header, bound_seq, test_identifier)); + // Change discriminator to EK_COMPLETE + register_empty_structure_type_object(); + TypeIdentifierPair type_ids; + DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers("empty_structure", type_ids); + if (EK_COMPLETE == type_ids.type_identifier1()._d()) + { + test_identifier = eprosima::fastcdr::external(new TypeIdentifier(type_ids.type_identifier1())); + } + else + { + test_identifier = eprosima::fastcdr::external(new TypeIdentifier(type_ids.type_identifier2())); + } + // TypeIdentifier consistent with complete header + EXPECT_NO_THROW(PlainArraySElemDefn plain_array = TypeObjectUtils::build_plain_array_s_elem_defn( + complete_header, bound_seq, test_identifier)); + // TypeIdentifier inconsistent with minimal header + EXPECT_THROW(PlainArraySElemDefn plain_array = TypeObjectUtils::build_plain_array_s_elem_defn( + minimal_header, bound_seq, test_identifier), InvalidArgumentError); + // TypeIdentifier inconsistent with fully-descriptive header + EXPECT_THROW(PlainArraySElemDefn plain_array = TypeObjectUtils::build_plain_array_s_elem_defn( + fully_descriptive_header, bound_seq, test_identifier), InvalidArgumentError); + // Change discriminator to EK_MINIMAL + if (EK_COMPLETE == type_ids.type_identifier1()._d()) + { + test_identifier = eprosima::fastcdr::external(new TypeIdentifier(type_ids.type_identifier2())); + } + else + { + test_identifier = eprosima::fastcdr::external(new TypeIdentifier(type_ids.type_identifier1())); + } + // TypeIdentifier inconsistent with complete header + EXPECT_THROW(PlainArraySElemDefn plain_array = TypeObjectUtils::build_plain_array_s_elem_defn( + complete_header, bound_seq, test_identifier), InvalidArgumentError); + // TypeIdentifier consistent with minimal header + EXPECT_NO_THROW(PlainArraySElemDefn plain_array = TypeObjectUtils::build_plain_array_s_elem_defn( + minimal_header, bound_seq, test_identifier)); + // TypeIdentifier inconsistent with fully-descriptive header + EXPECT_THROW(PlainArraySElemDefn plain_array = TypeObjectUtils::build_plain_array_s_elem_defn( + fully_descriptive_header, bound_seq, test_identifier), InvalidArgumentError); +} + +// Build PlainArrayLElemDefn with inconsistent parameters. +TEST(TypeObjectUtilsTests, build_plain_array_l_elem_defn_inconsistencies) +{ + eprosima::fastcdr::external test_identifier{new TypeIdentifier()}; + CollectionElementFlag flags = TypeObjectUtils::build_collection_element_flag( + eprosima::fastdds::dds::xtypes::TryConstructKind::TRIM, false); + LBoundSeq bound_seq; + LBound bound = 256; + TypeObjectUtils::add_array_dimension(bound_seq, bound); + PlainCollectionHeader complete_header = TypeObjectUtils::build_plain_collection_header( + EK_COMPLETE, flags); +#if !defined(NDEBUG) + PlainCollectionHeader wrong_header; + // Inconsistent header CollectionElementFlags + EXPECT_THROW(PlainArrayLElemDefn plain_array = TypeObjectUtils::build_plain_array_l_elem_defn( + wrong_header, bound_seq, test_identifier), InvalidArgumentError); + wrong_header.element_flags(flags); + // Inconsistent header EquivalenceKind + EXPECT_THROW(PlainArrayLElemDefn plain_array = TypeObjectUtils::build_plain_array_l_elem_defn( + wrong_header, bound_seq, test_identifier), InvalidArgumentError); + // Non-initialized TypeIdentifier + EXPECT_THROW(PlainArrayLElemDefn plain_array = TypeObjectUtils::build_plain_array_l_elem_defn( + complete_header, bound_seq, test_identifier), InvalidArgumentError); +#endif // !defined(NDEBUG) + // Check SBoundSeq consistency + LBoundSeq wrong_bound_seq; + // Empty array_bound_seq + EXPECT_THROW(PlainArrayLElemDefn plain_array = TypeObjectUtils::build_plain_array_l_elem_defn( + complete_header, wrong_bound_seq, test_identifier), InvalidArgumentError); + // Non-large bound dimension + bound = 10; + TypeObjectUtils::add_array_dimension(wrong_bound_seq, bound); + EXPECT_THROW(PlainArrayLElemDefn plain_array = TypeObjectUtils::build_plain_array_l_elem_defn( + complete_header, wrong_bound_seq, test_identifier), InvalidArgumentError); + + // Primitive TypeIdentifier + EXPECT_NO_THROW(test_identifier->_d(TK_BOOLEAN)); + // TypeIdentifier inconsistent with complete header + EXPECT_THROW(PlainArrayLElemDefn plain_array = TypeObjectUtils::build_plain_array_l_elem_defn( + complete_header, bound_seq, test_identifier), InvalidArgumentError); + PlainCollectionHeader minimal_header = TypeObjectUtils::build_plain_collection_header( + EK_MINIMAL, flags); + // TypeIdentifier inconsistent with minimal header + EXPECT_THROW(PlainArrayLElemDefn plain_array = TypeObjectUtils::build_plain_array_l_elem_defn( + minimal_header, bound_seq, test_identifier), InvalidArgumentError); + PlainCollectionHeader fully_descriptive_header = TypeObjectUtils::build_plain_collection_header( + EK_BOTH, flags); + // TypeIdentifier consistent with fully-descriptive header + EXPECT_NO_THROW(PlainArrayLElemDefn plain_array = TypeObjectUtils::build_plain_array_l_elem_defn( + fully_descriptive_header, bound_seq, test_identifier)); + // At least one dimension should be large + bound = 256; + TypeObjectUtils::add_array_dimension(wrong_bound_seq, bound); + EXPECT_NO_THROW(PlainArrayLElemDefn plain_array = TypeObjectUtils::build_plain_array_l_elem_defn( + fully_descriptive_header, wrong_bound_seq, test_identifier)); + // Zero element + bound = 0; + EXPECT_THROW(TypeObjectUtils::add_array_dimension(wrong_bound_seq, bound), InvalidArgumentError); + wrong_bound_seq.push_back(0); + EXPECT_THROW(PlainArrayLElemDefn plain_array = TypeObjectUtils::build_plain_array_l_elem_defn( + fully_descriptive_header, wrong_bound_seq, test_identifier), InvalidArgumentError); + // Change discriminator to EK_COMPLETE + register_empty_structure_type_object(); + TypeIdentifierPair type_ids; + DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers("empty_structure", type_ids); + if (EK_COMPLETE == type_ids.type_identifier1()._d()) + { + test_identifier = eprosima::fastcdr::external(new TypeIdentifier(type_ids.type_identifier1())); + } + else + { + test_identifier = eprosima::fastcdr::external(new TypeIdentifier(type_ids.type_identifier2())); + } + // TypeIdentifier consistent with complete header + EXPECT_NO_THROW(PlainArrayLElemDefn plain_array = TypeObjectUtils::build_plain_array_l_elem_defn( + complete_header, bound_seq, test_identifier)); + // TypeIdentifier inconsistent with minimal header + EXPECT_THROW(PlainArrayLElemDefn plain_array = TypeObjectUtils::build_plain_array_l_elem_defn( + minimal_header, bound_seq, test_identifier), InvalidArgumentError); + // TypeIdentifier inconsistent with fully-descriptive header + EXPECT_THROW(PlainArrayLElemDefn plain_array = TypeObjectUtils::build_plain_array_l_elem_defn( + fully_descriptive_header, bound_seq, test_identifier), InvalidArgumentError); + // Change discriminator to EK_MINIMAL + if (EK_COMPLETE == type_ids.type_identifier1()._d()) + { + test_identifier = eprosima::fastcdr::external(new TypeIdentifier(type_ids.type_identifier2())); + } + else + { + test_identifier = eprosima::fastcdr::external(new TypeIdentifier(type_ids.type_identifier1())); + } + // TypeIdentifier inconsistent with complete header + EXPECT_THROW(PlainArrayLElemDefn plain_array = TypeObjectUtils::build_plain_array_l_elem_defn( + complete_header, bound_seq, test_identifier), InvalidArgumentError); + // TypeIdentifier consistent with minimal header + EXPECT_NO_THROW(PlainArrayLElemDefn plain_array = TypeObjectUtils::build_plain_array_l_elem_defn( + minimal_header, bound_seq, test_identifier)); + // TypeIdentifier inconsistent with fully-descriptive header + EXPECT_THROW(PlainArrayLElemDefn plain_array = TypeObjectUtils::build_plain_array_l_elem_defn( + fully_descriptive_header, bound_seq, test_identifier), InvalidArgumentError); +} + +// Build PlainMapSTypeDefn with inconsistent parameters. +TEST(TypeObjectUtilsTests, build_plain_map_s_type_defn_inconsistencies) +{ + eprosima::fastcdr::external test_identifier{new TypeIdentifier()}; + eprosima::fastcdr::external key_identifier{new TypeIdentifier()}; + CollectionElementFlag flags = TypeObjectUtils::build_collection_element_flag( + eprosima::fastdds::dds::xtypes::TryConstructKind::TRIM, false); + PlainCollectionHeader complete_header = TypeObjectUtils::build_plain_collection_header( + EK_COMPLETE, flags); +#if !defined(NDEBUG) + PlainCollectionHeader wrong_header; + // Inconsistent header CollectionElementFlags + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + wrong_header, 10, test_identifier, flags, key_identifier), InvalidArgumentError); + wrong_header.element_flags(flags); + // Inconsistent header EquivalenceKind + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + wrong_header, 10, test_identifier, flags, key_identifier), InvalidArgumentError); + // Non-initialized TypeIdentifier + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, test_identifier, flags, key_identifier), InvalidArgumentError); +#endif // !defined(NDEBUG) + // Check SBound consistency + SBound wrong_bound = 0; + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, wrong_bound, test_identifier, flags, key_identifier), InvalidArgumentError); + + // Primitive TypeIdentifier + EXPECT_NO_THROW(test_identifier->_d(TK_BOOLEAN)); + // TypeIdentifier inconsistent with complete header + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, test_identifier, flags, key_identifier), InvalidArgumentError); + PlainCollectionHeader minimal_header = TypeObjectUtils::build_plain_collection_header( + EK_MINIMAL, flags); + // TypeIdentifier inconsistent with minimal header + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + minimal_header, 10, test_identifier, flags, key_identifier), InvalidArgumentError); + PlainCollectionHeader fully_descriptive_header = TypeObjectUtils::build_plain_collection_header( + EK_BOTH, flags); + // Wrong key_flags + CollectionElementFlag wrong_flags = 0; + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, test_identifier, wrong_flags, key_identifier), InvalidArgumentError); +#if !defined(NDEBUG) + // Uninitialized key_identifier + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, test_identifier, flags, key_identifier), InvalidArgumentError); +#endif // !defined(NDEBUG) + // Non-integer key identifier + EXPECT_NO_THROW(key_identifier->_d(TK_FLOAT32)); + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, test_identifier, flags, key_identifier), InvalidArgumentError); + // TypeIdentifier consistent with fully-descriptive header and integer key identifier + EXPECT_NO_THROW(key_identifier->_d(TK_INT64)); + EXPECT_NO_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, test_identifier, flags, key_identifier)); + StringSTypeDefn string_type_def = TypeObjectUtils::build_string_s_type_defn(50); + EXPECT_NO_THROW(key_identifier->string_sdefn(string_type_def)); + EXPECT_NO_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, test_identifier, flags, key_identifier)); + + // Get EK_COMPLETE and EK_MINIMAL TypeIdentifiers + register_empty_structure_type_object(); + TypeIdentifierPair type_ids; + eprosima::fastcdr::external complete_typeid; + eprosima::fastcdr::external minimal_typeid; + DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers("empty_structure", type_ids); + if (EK_COMPLETE == type_ids.type_identifier1()._d()) + { + complete_typeid = eprosima::fastcdr::external(new TypeIdentifier(type_ids.type_identifier1())); + minimal_typeid = eprosima::fastcdr::external(new TypeIdentifier(type_ids.type_identifier2())); + } + else + { + complete_typeid = eprosima::fastcdr::external(new TypeIdentifier(type_ids.type_identifier2())); + minimal_typeid = eprosima::fastcdr::external(new TypeIdentifier(type_ids.type_identifier1())); + } + + register_plain_seq_type_object(complete_typeid); + eprosima::fastcdr::external complete_indirect_id; + eprosima::fastcdr::external minimal_indirect_id; + DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers("plain_sequence", type_ids); + if (EK_COMPLETE == type_ids.type_identifier1()._d()) + { + complete_indirect_id = + eprosima::fastcdr::external(new TypeIdentifier(type_ids.type_identifier1())); + minimal_indirect_id = + eprosima::fastcdr::external(new TypeIdentifier(type_ids.type_identifier2())); + } + else + { + complete_indirect_id = + eprosima::fastcdr::external(new TypeIdentifier(type_ids.type_identifier2())); + minimal_indirect_id = + eprosima::fastcdr::external(new TypeIdentifier(type_ids.type_identifier1())); + } + + register_alias_type_object(); + eprosima::fastcdr::external complete_alias_id; + eprosima::fastcdr::external minimal_alias_id; + DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers("int16_alias", type_ids); + if (EK_COMPLETE == type_ids.type_identifier1()._d()) + { + complete_alias_id = + eprosima::fastcdr::external(new TypeIdentifier(type_ids.type_identifier1())); + minimal_alias_id = + eprosima::fastcdr::external(new TypeIdentifier(type_ids.type_identifier2())); + } + else + { + complete_alias_id = + eprosima::fastcdr::external(new TypeIdentifier(type_ids.type_identifier2())); + minimal_alias_id = + eprosima::fastcdr::external(new TypeIdentifier(type_ids.type_identifier1())); + } + + EXPECT_NO_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, test_identifier, flags, key_identifier)); + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, test_identifier, flags, complete_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, test_identifier, flags, complete_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, test_identifier, flags, complete_alias_id), InvalidArgumentError); + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, test_identifier, flags, minimal_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, test_identifier, flags, minimal_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, test_identifier, flags, minimal_alias_id), InvalidArgumentError); + + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, complete_typeid, flags, key_identifier), InvalidArgumentError); + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, complete_typeid, flags, complete_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, complete_typeid, flags, complete_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, complete_typeid, flags, complete_alias_id), InvalidArgumentError); + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, complete_typeid, flags, minimal_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, complete_typeid, flags, minimal_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, complete_typeid, flags, minimal_alias_id), InvalidArgumentError); + + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, complete_indirect_id, flags, key_identifier), InvalidArgumentError); + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, complete_indirect_id, flags, complete_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, complete_indirect_id, flags, complete_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, complete_indirect_id, flags, complete_alias_id), InvalidArgumentError); + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, complete_indirect_id, flags, minimal_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, complete_indirect_id, flags, minimal_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, complete_indirect_id, flags, minimal_alias_id), InvalidArgumentError); + + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, complete_alias_id, flags, key_identifier), InvalidArgumentError); + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, complete_alias_id, flags, complete_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, complete_alias_id, flags, complete_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, complete_alias_id, flags, complete_alias_id), InvalidArgumentError); + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, complete_alias_id, flags, minimal_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, complete_alias_id, flags, minimal_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, complete_alias_id, flags, minimal_alias_id), InvalidArgumentError); + + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, minimal_typeid, flags, key_identifier), InvalidArgumentError); + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, minimal_typeid, flags, complete_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, minimal_typeid, flags, complete_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, minimal_typeid, flags, complete_alias_id), InvalidArgumentError); + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, minimal_typeid, flags, minimal_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, minimal_typeid, flags, minimal_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, minimal_typeid, flags, minimal_alias_id), InvalidArgumentError); + + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, minimal_indirect_id, flags, key_identifier), InvalidArgumentError); + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, minimal_indirect_id, flags, complete_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, minimal_indirect_id, flags, complete_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, minimal_indirect_id, flags, complete_alias_id), InvalidArgumentError); + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, minimal_indirect_id, flags, minimal_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, minimal_indirect_id, flags, minimal_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, minimal_indirect_id, flags, minimal_alias_id), InvalidArgumentError); + + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, minimal_alias_id, flags, key_identifier), InvalidArgumentError); + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, minimal_alias_id, flags, complete_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, minimal_alias_id, flags, complete_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, minimal_alias_id, flags, complete_alias_id), InvalidArgumentError); + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, minimal_alias_id, flags, minimal_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, minimal_alias_id, flags, minimal_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + fully_descriptive_header, 10, minimal_alias_id, flags, minimal_alias_id), InvalidArgumentError); + + + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, test_identifier, flags, key_identifier), InvalidArgumentError); + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, test_identifier, flags, complete_typeid), InvalidArgumentError); //Invalid key/// + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, test_identifier, flags, complete_indirect_id), InvalidArgumentError); //Invalid key/// + EXPECT_NO_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, test_identifier, flags, complete_alias_id)); + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, test_identifier, flags, minimal_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, test_identifier, flags, minimal_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, test_identifier, flags, minimal_alias_id), InvalidArgumentError); + + EXPECT_NO_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, complete_typeid, flags, key_identifier)); + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, complete_typeid, flags, complete_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, complete_typeid, flags, complete_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_NO_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, complete_typeid, flags, complete_alias_id)); + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, complete_typeid, flags, minimal_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, complete_typeid, flags, minimal_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, complete_typeid, flags, minimal_alias_id), InvalidArgumentError); + + EXPECT_NO_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, complete_indirect_id, flags, key_identifier)); + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, complete_indirect_id, flags, complete_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, complete_indirect_id, flags, complete_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_NO_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, complete_indirect_id, flags, complete_alias_id)); + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, complete_indirect_id, flags, minimal_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, complete_indirect_id, flags, minimal_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, complete_indirect_id, flags, minimal_alias_id), InvalidArgumentError); + + EXPECT_NO_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, complete_alias_id, flags, key_identifier)); + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, complete_alias_id, flags, complete_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, complete_alias_id, flags, complete_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_NO_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, complete_alias_id, flags, complete_alias_id)); + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, complete_alias_id, flags, minimal_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, complete_alias_id, flags, minimal_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, complete_alias_id, flags, minimal_alias_id), InvalidArgumentError); + + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, minimal_typeid, flags, key_identifier), InvalidArgumentError); + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, minimal_typeid, flags, complete_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, minimal_typeid, flags, complete_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, minimal_typeid, flags, complete_alias_id), InvalidArgumentError); + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, minimal_typeid, flags, minimal_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, minimal_typeid, flags, minimal_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, minimal_typeid, flags, minimal_alias_id), InvalidArgumentError); + + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, minimal_indirect_id, flags, key_identifier), InvalidArgumentError); + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, minimal_indirect_id, flags, complete_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, minimal_indirect_id, flags, complete_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, minimal_indirect_id, flags, complete_alias_id), InvalidArgumentError); + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, minimal_indirect_id, flags, minimal_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, minimal_indirect_id, flags, minimal_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, minimal_indirect_id, flags, minimal_alias_id), InvalidArgumentError); + + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, minimal_alias_id, flags, key_identifier), InvalidArgumentError); + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, minimal_alias_id, flags, complete_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, minimal_alias_id, flags, complete_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, minimal_alias_id, flags, complete_alias_id), InvalidArgumentError); + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, minimal_alias_id, flags, minimal_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, minimal_alias_id, flags, minimal_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + complete_header, 10, minimal_alias_id, flags, minimal_alias_id), InvalidArgumentError); + + + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + minimal_header, 10, test_identifier, flags, key_identifier), InvalidArgumentError); + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + minimal_header, 10, test_identifier, flags, complete_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + minimal_header, 10, test_identifier, flags, complete_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + minimal_header, 10, test_identifier, flags, complete_alias_id), InvalidArgumentError); + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + minimal_header, 10, test_identifier, flags, minimal_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + minimal_header, 10, test_identifier, flags, minimal_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_NO_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + minimal_header, 10, test_identifier, flags, minimal_alias_id)); + + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + minimal_header, 10, complete_typeid, flags, key_identifier), InvalidArgumentError); + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + minimal_header, 10, complete_typeid, flags, complete_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + minimal_header, 10, complete_typeid, flags, complete_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + minimal_header, 10, complete_typeid, flags, complete_alias_id), InvalidArgumentError); + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + minimal_header, 10, complete_typeid, flags, minimal_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + minimal_header, 10, complete_typeid, flags, minimal_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + minimal_header, 10, complete_typeid, flags, minimal_alias_id), InvalidArgumentError); + + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + minimal_header, 10, complete_indirect_id, flags, key_identifier), InvalidArgumentError); + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + minimal_header, 10, complete_indirect_id, flags, complete_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + minimal_header, 10, complete_indirect_id, flags, complete_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + minimal_header, 10, complete_indirect_id, flags, complete_alias_id), InvalidArgumentError); + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + minimal_header, 10, complete_indirect_id, flags, minimal_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + minimal_header, 10, complete_indirect_id, flags, minimal_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + minimal_header, 10, complete_indirect_id, flags, minimal_alias_id), InvalidArgumentError); + + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + minimal_header, 10, complete_alias_id, flags, key_identifier), InvalidArgumentError); + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + minimal_header, 10, complete_alias_id, flags, complete_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + minimal_header, 10, complete_alias_id, flags, complete_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + minimal_header, 10, complete_alias_id, flags, complete_alias_id), InvalidArgumentError); + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + minimal_header, 10, complete_alias_id, flags, minimal_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + minimal_header, 10, complete_alias_id, flags, minimal_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + minimal_header, 10, complete_alias_id, flags, minimal_alias_id), InvalidArgumentError); + + EXPECT_NO_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + minimal_header, 10, minimal_typeid, flags, key_identifier)); + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + minimal_header, 10, minimal_typeid, flags, complete_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + minimal_header, 10, minimal_typeid, flags, complete_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + minimal_header, 10, minimal_typeid, flags, complete_alias_id), InvalidArgumentError); + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + minimal_header, 10, minimal_typeid, flags, minimal_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + minimal_header, 10, minimal_typeid, flags, minimal_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_NO_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + minimal_header, 10, minimal_typeid, flags, minimal_alias_id)); + + EXPECT_NO_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + minimal_header, 10, minimal_indirect_id, flags, key_identifier)); + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + minimal_header, 10, minimal_indirect_id, flags, complete_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + minimal_header, 10, minimal_indirect_id, flags, complete_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + minimal_header, 10, minimal_indirect_id, flags, complete_alias_id), InvalidArgumentError); + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + minimal_header, 10, minimal_indirect_id, flags, minimal_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + minimal_header, 10, minimal_indirect_id, flags, minimal_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_NO_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + minimal_header, 10, minimal_indirect_id, flags, minimal_alias_id)); + + EXPECT_NO_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + minimal_header, 10, minimal_alias_id, flags, key_identifier)); + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + minimal_header, 10, minimal_alias_id, flags, complete_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + minimal_header, 10, minimal_alias_id, flags, complete_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + minimal_header, 10, minimal_alias_id, flags, complete_alias_id), InvalidArgumentError); + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + minimal_header, 10, minimal_alias_id, flags, minimal_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + minimal_header, 10, minimal_alias_id, flags, minimal_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_NO_THROW(PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn( + minimal_header, 10, minimal_alias_id, flags, minimal_alias_id)); +} + +// Build PlainMapLTypeDefn with inconsistent parameters. +TEST(TypeObjectUtilsTests, build_plain_map_l_type_defn_inconsistencies) +{ + eprosima::fastcdr::external test_identifier{new TypeIdentifier()}; + eprosima::fastcdr::external key_identifier{new TypeIdentifier()}; + CollectionElementFlag flags = TypeObjectUtils::build_collection_element_flag( + eprosima::fastdds::dds::xtypes::TryConstructKind::TRIM, false); + PlainCollectionHeader complete_header = TypeObjectUtils::build_plain_collection_header( + EK_COMPLETE, flags); +#if !defined(NDEBUG) + PlainCollectionHeader wrong_header; + // Inconsistent header CollectionElementFlags + EXPECT_THROW(PlainMapLTypeDefn plain_seq = TypeObjectUtils::build_plain_map_l_type_defn( + wrong_header, 1000, test_identifier, flags, key_identifier), InvalidArgumentError); + wrong_header.element_flags(flags); + // Inconsistent header EquivalenceKind + EXPECT_THROW(PlainMapLTypeDefn plain_seq = TypeObjectUtils::build_plain_map_l_type_defn( + wrong_header, 1000, test_identifier, flags, key_identifier), InvalidArgumentError); + // Non-initialized TypeIdentifier + EXPECT_THROW(PlainMapLTypeDefn plain_seq = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, test_identifier, flags, key_identifier), InvalidArgumentError); +#endif // !defined(NDEBUG) + // Check LBound consistency + LBound wrong_bound = 255; + EXPECT_THROW(PlainMapLTypeDefn plain_seq = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, wrong_bound, test_identifier, flags, key_identifier), InvalidArgumentError); + wrong_bound = 0; + EXPECT_THROW(PlainMapLTypeDefn plain_seq = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, wrong_bound, test_identifier, flags, key_identifier), InvalidArgumentError); + + // Primitive TypeIdentifier + EXPECT_NO_THROW(test_identifier->_d(TK_BOOLEAN)); + // TypeIdentifier inconsistent with complete header + EXPECT_THROW(PlainMapLTypeDefn plain_seq = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, test_identifier, flags, key_identifier), InvalidArgumentError); + PlainCollectionHeader minimal_header = TypeObjectUtils::build_plain_collection_header( + EK_MINIMAL, flags); + // TypeIdentifier inconsistent with minimal header + EXPECT_THROW(PlainMapLTypeDefn plain_seq = TypeObjectUtils::build_plain_map_l_type_defn( + minimal_header, 1000, test_identifier, flags, key_identifier), InvalidArgumentError); + PlainCollectionHeader fully_descriptive_header = TypeObjectUtils::build_plain_collection_header( + EK_BOTH, flags); + // Wrong key_flags + CollectionElementFlag wrong_flags = 0; + EXPECT_THROW(PlainMapLTypeDefn plain_seq = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, test_identifier, wrong_flags, key_identifier), InvalidArgumentError); +#if !defined(NDEBUG) + // Uninitialized key_identifier + EXPECT_THROW(PlainMapLTypeDefn plain_seq = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, test_identifier, flags, key_identifier), InvalidArgumentError); +#endif // !defined(NDEBUG) + // Non-integer key identifier + EXPECT_NO_THROW(key_identifier->_d(TK_FLOAT32)); + EXPECT_THROW(PlainMapLTypeDefn plain_seq = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, test_identifier, flags, key_identifier), InvalidArgumentError); + // TypeIdentifier consistent with fully-descriptive header and integer key identifier + EXPECT_NO_THROW(key_identifier->_d(TK_INT64)); + EXPECT_NO_THROW(PlainMapLTypeDefn plain_seq = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, test_identifier, flags, key_identifier)); + StringSTypeDefn string_type_def = TypeObjectUtils::build_string_s_type_defn(50); + EXPECT_NO_THROW(key_identifier->string_sdefn(string_type_def)); + EXPECT_NO_THROW(PlainMapLTypeDefn plain_seq = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, test_identifier, flags, key_identifier)); + + + + // Get EK_COMPLETE and EK_MINIMAL TypeIdentifiers + register_empty_structure_type_object(); + TypeIdentifierPair type_ids; + eprosima::fastcdr::external complete_typeid; + eprosima::fastcdr::external minimal_typeid; + DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers("empty_structure", type_ids); + if (EK_COMPLETE == type_ids.type_identifier1()._d()) + { + complete_typeid = eprosima::fastcdr::external(new TypeIdentifier(type_ids.type_identifier1())); + minimal_typeid = eprosima::fastcdr::external(new TypeIdentifier(type_ids.type_identifier2())); + } + else + { + complete_typeid = eprosima::fastcdr::external(new TypeIdentifier(type_ids.type_identifier2())); + minimal_typeid = eprosima::fastcdr::external(new TypeIdentifier(type_ids.type_identifier1())); + } + + register_plain_seq_type_object(complete_typeid); + eprosima::fastcdr::external complete_indirect_id; + eprosima::fastcdr::external minimal_indirect_id; + DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers("plain_sequence", type_ids); + if (EK_COMPLETE == type_ids.type_identifier1()._d()) + { + complete_indirect_id = + eprosima::fastcdr::external(new TypeIdentifier(type_ids.type_identifier1())); + minimal_indirect_id = + eprosima::fastcdr::external(new TypeIdentifier(type_ids.type_identifier2())); + } + else + { + complete_indirect_id = + eprosima::fastcdr::external(new TypeIdentifier(type_ids.type_identifier2())); + minimal_indirect_id = + eprosima::fastcdr::external(new TypeIdentifier(type_ids.type_identifier1())); + } + + register_alias_type_object(); + eprosima::fastcdr::external complete_alias_id; + eprosima::fastcdr::external minimal_alias_id; + DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers("int16_alias", type_ids); + if (EK_COMPLETE == type_ids.type_identifier1()._d()) + { + complete_alias_id = + eprosima::fastcdr::external(new TypeIdentifier(type_ids.type_identifier1())); + minimal_alias_id = + eprosima::fastcdr::external(new TypeIdentifier(type_ids.type_identifier2())); + } + else + { + complete_alias_id = + eprosima::fastcdr::external(new TypeIdentifier(type_ids.type_identifier2())); + minimal_alias_id = + eprosima::fastcdr::external(new TypeIdentifier(type_ids.type_identifier1())); + } + + EXPECT_NO_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, test_identifier, flags, key_identifier)); + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, test_identifier, flags, complete_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, test_identifier, flags, complete_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, test_identifier, flags, complete_alias_id), InvalidArgumentError); + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, test_identifier, flags, minimal_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, test_identifier, flags, minimal_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, test_identifier, flags, minimal_alias_id), InvalidArgumentError); + + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, complete_typeid, flags, key_identifier), InvalidArgumentError); + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, complete_typeid, flags, complete_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, complete_typeid, flags, complete_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, complete_typeid, flags, complete_alias_id), InvalidArgumentError); + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, complete_typeid, flags, minimal_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, complete_typeid, flags, minimal_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, complete_typeid, flags, minimal_alias_id), InvalidArgumentError); + + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, complete_indirect_id, flags, key_identifier), InvalidArgumentError); + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, complete_indirect_id, flags, complete_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, complete_indirect_id, flags, complete_indirect_id), + InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, complete_indirect_id, flags, complete_alias_id), InvalidArgumentError); + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, complete_indirect_id, flags, minimal_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, complete_indirect_id, flags, minimal_indirect_id), + InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, complete_indirect_id, flags, minimal_alias_id), InvalidArgumentError); + + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, complete_alias_id, flags, key_identifier), InvalidArgumentError); + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, complete_alias_id, flags, complete_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, complete_alias_id, flags, complete_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, complete_alias_id, flags, complete_alias_id), InvalidArgumentError); + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, complete_alias_id, flags, minimal_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, complete_alias_id, flags, minimal_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, complete_alias_id, flags, minimal_alias_id), InvalidArgumentError); + + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, minimal_typeid, flags, key_identifier), InvalidArgumentError); + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, minimal_typeid, flags, complete_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, minimal_typeid, flags, complete_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, minimal_typeid, flags, complete_alias_id), InvalidArgumentError); + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, minimal_typeid, flags, minimal_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, minimal_typeid, flags, minimal_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, minimal_typeid, flags, minimal_alias_id), InvalidArgumentError); + + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, minimal_indirect_id, flags, key_identifier), InvalidArgumentError); + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, minimal_indirect_id, flags, complete_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, minimal_indirect_id, flags, complete_indirect_id), + InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, minimal_indirect_id, flags, complete_alias_id), InvalidArgumentError); + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, minimal_indirect_id, flags, minimal_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, minimal_indirect_id, flags, minimal_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, minimal_indirect_id, flags, minimal_alias_id), InvalidArgumentError); + + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, minimal_alias_id, flags, key_identifier), InvalidArgumentError); + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, minimal_alias_id, flags, complete_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, minimal_alias_id, flags, complete_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, minimal_alias_id, flags, complete_alias_id), InvalidArgumentError); + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, minimal_alias_id, flags, minimal_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, minimal_alias_id, flags, minimal_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + fully_descriptive_header, 1000, minimal_alias_id, flags, minimal_alias_id), InvalidArgumentError); + + + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, test_identifier, flags, key_identifier), InvalidArgumentError); + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, test_identifier, flags, complete_typeid), InvalidArgumentError); //Invalid key/// + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, test_identifier, flags, complete_indirect_id), InvalidArgumentError); //Invalid key/// + EXPECT_NO_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, test_identifier, flags, complete_alias_id)); + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, test_identifier, flags, minimal_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, test_identifier, flags, minimal_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, test_identifier, flags, minimal_alias_id), InvalidArgumentError); + + EXPECT_NO_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, complete_typeid, flags, key_identifier)); + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, complete_typeid, flags, complete_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, complete_typeid, flags, complete_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_NO_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, complete_typeid, flags, complete_alias_id)); + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, complete_typeid, flags, minimal_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, complete_typeid, flags, minimal_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, complete_typeid, flags, minimal_alias_id), InvalidArgumentError); + + EXPECT_NO_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, complete_indirect_id, flags, key_identifier)); + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, complete_indirect_id, flags, complete_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, complete_indirect_id, flags, complete_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_NO_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, complete_indirect_id, flags, complete_alias_id)); + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, complete_indirect_id, flags, minimal_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, complete_indirect_id, flags, minimal_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, complete_indirect_id, flags, minimal_alias_id), InvalidArgumentError); + + EXPECT_NO_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, complete_alias_id, flags, key_identifier)); + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, complete_alias_id, flags, complete_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, complete_alias_id, flags, complete_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_NO_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, complete_alias_id, flags, complete_alias_id)); + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, complete_alias_id, flags, minimal_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, complete_alias_id, flags, minimal_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, complete_alias_id, flags, minimal_alias_id), InvalidArgumentError); + + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, minimal_typeid, flags, key_identifier), InvalidArgumentError); + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, minimal_typeid, flags, complete_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, minimal_typeid, flags, complete_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, minimal_typeid, flags, complete_alias_id), InvalidArgumentError); + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, minimal_typeid, flags, minimal_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, minimal_typeid, flags, minimal_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, minimal_typeid, flags, minimal_alias_id), InvalidArgumentError); + + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, minimal_indirect_id, flags, key_identifier), InvalidArgumentError); + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, minimal_indirect_id, flags, complete_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, minimal_indirect_id, flags, complete_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, minimal_indirect_id, flags, complete_alias_id), InvalidArgumentError); + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, minimal_indirect_id, flags, minimal_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, minimal_indirect_id, flags, minimal_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, minimal_indirect_id, flags, minimal_alias_id), InvalidArgumentError); + + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, minimal_alias_id, flags, key_identifier), InvalidArgumentError); + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, minimal_alias_id, flags, complete_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, minimal_alias_id, flags, complete_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, minimal_alias_id, flags, complete_alias_id), InvalidArgumentError); + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, minimal_alias_id, flags, minimal_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, minimal_alias_id, flags, minimal_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + complete_header, 1000, minimal_alias_id, flags, minimal_alias_id), InvalidArgumentError); + + + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + minimal_header, 1000, test_identifier, flags, key_identifier), InvalidArgumentError); + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + minimal_header, 1000, test_identifier, flags, complete_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + minimal_header, 1000, test_identifier, flags, complete_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + minimal_header, 1000, test_identifier, flags, complete_alias_id), InvalidArgumentError); + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + minimal_header, 1000, test_identifier, flags, minimal_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + minimal_header, 1000, test_identifier, flags, minimal_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_NO_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + minimal_header, 1000, test_identifier, flags, minimal_alias_id)); + + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + minimal_header, 1000, complete_typeid, flags, key_identifier), InvalidArgumentError); + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + minimal_header, 1000, complete_typeid, flags, complete_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + minimal_header, 1000, complete_typeid, flags, complete_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + minimal_header, 1000, complete_typeid, flags, complete_alias_id), InvalidArgumentError); + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + minimal_header, 1000, complete_typeid, flags, minimal_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + minimal_header, 1000, complete_typeid, flags, minimal_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + minimal_header, 1000, complete_typeid, flags, minimal_alias_id), InvalidArgumentError); + + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + minimal_header, 1000, complete_indirect_id, flags, key_identifier), InvalidArgumentError); + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + minimal_header, 1000, complete_indirect_id, flags, complete_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + minimal_header, 1000, complete_indirect_id, flags, complete_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + minimal_header, 1000, complete_indirect_id, flags, complete_alias_id), InvalidArgumentError); + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + minimal_header, 1000, complete_indirect_id, flags, minimal_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + minimal_header, 1000, complete_indirect_id, flags, minimal_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + minimal_header, 1000, complete_indirect_id, flags, minimal_alias_id), InvalidArgumentError); + + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + minimal_header, 1000, complete_alias_id, flags, key_identifier), InvalidArgumentError); + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + minimal_header, 1000, complete_alias_id, flags, complete_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + minimal_header, 1000, complete_alias_id, flags, complete_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + minimal_header, 1000, complete_alias_id, flags, complete_alias_id), InvalidArgumentError); + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + minimal_header, 1000, complete_alias_id, flags, minimal_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + minimal_header, 1000, complete_alias_id, flags, minimal_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + minimal_header, 1000, complete_alias_id, flags, minimal_alias_id), InvalidArgumentError); + + EXPECT_NO_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + minimal_header, 1000, minimal_typeid, flags, key_identifier)); + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + minimal_header, 1000, minimal_typeid, flags, complete_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + minimal_header, 1000, minimal_typeid, flags, complete_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + minimal_header, 1000, minimal_typeid, flags, complete_alias_id), InvalidArgumentError); + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + minimal_header, 1000, minimal_typeid, flags, minimal_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + minimal_header, 1000, minimal_typeid, flags, minimal_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_NO_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + minimal_header, 1000, minimal_typeid, flags, minimal_alias_id)); + + EXPECT_NO_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + minimal_header, 1000, minimal_indirect_id, flags, key_identifier)); + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + minimal_header, 1000, minimal_indirect_id, flags, complete_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + minimal_header, 1000, minimal_indirect_id, flags, complete_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + minimal_header, 1000, minimal_indirect_id, flags, complete_alias_id), InvalidArgumentError); + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + minimal_header, 1000, minimal_indirect_id, flags, minimal_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + minimal_header, 1000, minimal_indirect_id, flags, minimal_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_NO_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + minimal_header, 1000, minimal_indirect_id, flags, minimal_alias_id)); + + EXPECT_NO_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + minimal_header, 1000, minimal_alias_id, flags, key_identifier)); + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + minimal_header, 1000, minimal_alias_id, flags, complete_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + minimal_header, 1000, minimal_alias_id, flags, complete_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + minimal_header, 1000, minimal_alias_id, flags, complete_alias_id), InvalidArgumentError); + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + minimal_header, 1000, minimal_alias_id, flags, minimal_typeid), InvalidArgumentError); //Invalid key + EXPECT_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + minimal_header, 1000, minimal_alias_id, flags, minimal_indirect_id), InvalidArgumentError); //Invalid key + EXPECT_NO_THROW(PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn( + minimal_header, 1000, minimal_alias_id, flags, minimal_alias_id)); +} + +// Register small string/wstring. This test does not check member consistency (only checked in Debug build mode). +TEST(TypeObjectUtilsTests, register_s_string) +{ + StringSTypeDefn string_defn = TypeObjectUtils::build_string_s_type_defn(32); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, + TypeObjectUtils::build_and_register_s_string_type_identifier(string_defn, + "small_string")); + // Registering twice the same TypeIdentifier should not fail + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, + TypeObjectUtils::build_and_register_s_string_type_identifier(string_defn, + "small_string")); + // Registering another TypeIdentifier with the same name should return RETCODE_BAD_PARAMETER + StringSTypeDefn another_string_defn = TypeObjectUtils::build_string_s_type_defn(100); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_BAD_PARAMETER, TypeObjectUtils::build_and_register_s_string_type_identifier( + another_string_defn, + "small_string")); + std::string type_name; + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_PRECONDITION_NOT_MET, TypeObjectUtils::build_and_register_s_string_type_identifier( + another_string_defn, + type_name)); +} + +// Register large string/wstring. This test does not check member consistency (only checked in Debug build mode). +TEST(TypeObjectUtilsTests, register_l_string) +{ + StringLTypeDefn string_defn = TypeObjectUtils::build_string_l_type_defn(1000); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, + TypeObjectUtils::build_and_register_l_string_type_identifier(string_defn, + "large_string")); + // Registering twice the same TypeIdentifier should not fail + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, + TypeObjectUtils::build_and_register_l_string_type_identifier(string_defn, + "large_string")); + // Registering another TypeIdentifier with the same name should return RETCODE_BAD_PARAMETER + StringLTypeDefn another_string_defn = TypeObjectUtils::build_string_l_type_defn(2000); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_BAD_PARAMETER, TypeObjectUtils::build_and_register_l_string_type_identifier( + another_string_defn, + "large_string")); + std::string type_name; + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_PRECONDITION_NOT_MET, TypeObjectUtils::build_and_register_l_string_type_identifier( + another_string_defn, + type_name)); +} + +// Register small sequence. This test does not check member consistency (only checked in Debug build mode). +TEST(TypeObjectUtilsTests, register_s_sequence) +{ + CollectionElementFlag flags = TypeObjectUtils::build_collection_element_flag( + eprosima::fastdds::dds::xtypes::TryConstructKind::USE_DEFAULT, false); + PlainCollectionHeader header = TypeObjectUtils::build_plain_collection_header(EK_BOTH, flags); + eprosima::fastcdr::external primitive_identifier{new TypeIdentifier()}; + primitive_identifier->_d(TK_FLOAT128); + PlainSequenceSElemDefn plain_seq = TypeObjectUtils::build_plain_sequence_s_elem_defn( + header, 255, primitive_identifier); + // Another external is required cause the comparison is only of the pointer and not the data contained. + eprosima::fastcdr::external other_identifier{new TypeIdentifier()}; + other_identifier->_d(TK_INT16); + PlainSequenceSElemDefn another_plain_seq = TypeObjectUtils::build_plain_sequence_s_elem_defn( + header, 255, other_identifier); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, + TypeObjectUtils::build_and_register_s_sequence_type_identifier(plain_seq, + "small_sequence")); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, + TypeObjectUtils::build_and_register_s_sequence_type_identifier(plain_seq, + "small_sequence")); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_BAD_PARAMETER, TypeObjectUtils::build_and_register_s_sequence_type_identifier( + another_plain_seq, + "small_sequence")); + std::string type_name; + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_PRECONDITION_NOT_MET, + TypeObjectUtils::build_and_register_s_sequence_type_identifier(another_plain_seq, type_name)); +} + +// Register large sequence. This test does not check member consistency (only checked in Debug build mode). +TEST(TypeObjectUtilsTests, register_l_sequence) +{ + CollectionElementFlag flags = TypeObjectUtils::build_collection_element_flag( + eprosima::fastdds::dds::xtypes::TryConstructKind::USE_DEFAULT, false); + PlainCollectionHeader header = TypeObjectUtils::build_plain_collection_header(EK_BOTH, flags); + eprosima::fastcdr::external primitive_identifier{new TypeIdentifier()}; + primitive_identifier->_d(TK_FLOAT128); + PlainSequenceLElemDefn plain_seq = TypeObjectUtils::build_plain_sequence_l_elem_defn( + header, 256, primitive_identifier); + eprosima::fastcdr::external other_identifier{new TypeIdentifier()}; + other_identifier->_d(TK_INT16); + PlainSequenceLElemDefn another_plain_seq = TypeObjectUtils::build_plain_sequence_l_elem_defn( + header, 256, other_identifier); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, + TypeObjectUtils::build_and_register_l_sequence_type_identifier(plain_seq, + "large_sequence")); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, + TypeObjectUtils::build_and_register_l_sequence_type_identifier(plain_seq, + "large_sequence")); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_BAD_PARAMETER, TypeObjectUtils::build_and_register_l_sequence_type_identifier( + another_plain_seq, + "large_sequence")); + std::string type_name; + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_PRECONDITION_NOT_MET, + TypeObjectUtils::build_and_register_l_sequence_type_identifier(another_plain_seq, type_name)); +} + +// Register small array. This test does not check member consistency (only checked in Debug build mode). +TEST(TypeObjectUtilsTests, register_s_array) +{ + CollectionElementFlag flags = TypeObjectUtils::build_collection_element_flag( + eprosima::fastdds::dds::xtypes::TryConstructKind::USE_DEFAULT, false); + PlainCollectionHeader header = TypeObjectUtils::build_plain_collection_header(EK_BOTH, flags); + eprosima::fastcdr::external primitive_identifier{new TypeIdentifier()}; + primitive_identifier->_d(TK_FLOAT128); + SBoundSeq array_bounds; + SBound bound = 26; + TypeObjectUtils::add_array_dimension(array_bounds, bound); + PlainArraySElemDefn plain_array = TypeObjectUtils::build_plain_array_s_elem_defn(header, array_bounds, + primitive_identifier); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, + TypeObjectUtils::build_and_register_s_array_type_identifier(plain_array, + "small_array")); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, + TypeObjectUtils::build_and_register_s_array_type_identifier(plain_array, + "small_array")); + bound = 100; + TypeObjectUtils::add_array_dimension(array_bounds, bound); + PlainArraySElemDefn another_plain_array = TypeObjectUtils::build_plain_array_s_elem_defn(header, array_bounds, + primitive_identifier); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_BAD_PARAMETER, TypeObjectUtils::build_and_register_s_array_type_identifier( + another_plain_array, + "small_array")); + std::string type_name; + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_PRECONDITION_NOT_MET, TypeObjectUtils::build_and_register_s_array_type_identifier( + another_plain_array, + type_name)); +} + +// Register large array. This test does not check member consistency (only checked in Debug build mode). +TEST(TypeObjectUtilsTests, register_l_array) +{ + CollectionElementFlag flags = TypeObjectUtils::build_collection_element_flag( + eprosima::fastdds::dds::xtypes::TryConstructKind::USE_DEFAULT, false); + PlainCollectionHeader header = TypeObjectUtils::build_plain_collection_header(EK_BOTH, flags); + eprosima::fastcdr::external primitive_identifier{new TypeIdentifier()}; + primitive_identifier->_d(TK_FLOAT128); + LBoundSeq array_bounds; + LBound bound = 260; + TypeObjectUtils::add_array_dimension(array_bounds, bound); + PlainArrayLElemDefn plain_array = TypeObjectUtils::build_plain_array_l_elem_defn(header, array_bounds, + primitive_identifier); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, + TypeObjectUtils::build_and_register_l_array_type_identifier(plain_array, + "large_array")); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, + TypeObjectUtils::build_and_register_l_array_type_identifier(plain_array, + "large_array")); + bound = 1000; + TypeObjectUtils::add_array_dimension(array_bounds, bound); + PlainArrayLElemDefn another_plain_array = TypeObjectUtils::build_plain_array_l_elem_defn(header, array_bounds, + primitive_identifier); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_BAD_PARAMETER, TypeObjectUtils::build_and_register_l_array_type_identifier( + another_plain_array, + "large_array")); + std::string type_name; + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_PRECONDITION_NOT_MET, TypeObjectUtils::build_and_register_l_array_type_identifier( + another_plain_array, + type_name)); +} + +// Register small map. This test does not check member consistency (only checked in Debug build mode). +TEST(TypeObjectUtilsTests, register_s_map) +{ + CollectionElementFlag flags = TypeObjectUtils::build_collection_element_flag( + eprosima::fastdds::dds::xtypes::TryConstructKind::USE_DEFAULT, false); + PlainCollectionHeader header = TypeObjectUtils::build_plain_collection_header(EK_BOTH, flags); + eprosima::fastcdr::external primitive_identifier{new TypeIdentifier()}; + primitive_identifier->_d(TK_UINT32); + PlainMapSTypeDefn plain_map = TypeObjectUtils::build_plain_map_s_type_defn(header, 10, primitive_identifier, flags, + primitive_identifier); + eprosima::fastcdr::external key_identifier{new TypeIdentifier()}; + key_identifier->_d(TK_INT8); + PlainMapSTypeDefn another_plain_map = TypeObjectUtils::build_plain_map_s_type_defn(header, 10, primitive_identifier, + flags, key_identifier); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, TypeObjectUtils::build_and_register_s_map_type_identifier(plain_map, + "small_map")); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, TypeObjectUtils::build_and_register_s_map_type_identifier(plain_map, + "small_map")); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_BAD_PARAMETER, TypeObjectUtils::build_and_register_s_map_type_identifier( + another_plain_map, "small_map")); + std::string type_name; + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_PRECONDITION_NOT_MET, TypeObjectUtils::build_and_register_s_map_type_identifier( + another_plain_map, + type_name)); +} + +// Register large map. This test does not check member consistency (only checked in Debug build mode). +TEST(TypeObjectUtilsTests, register_l_map) +{ + CollectionElementFlag flags = TypeObjectUtils::build_collection_element_flag( + eprosima::fastdds::dds::xtypes::TryConstructKind::USE_DEFAULT, false); + PlainCollectionHeader header = TypeObjectUtils::build_plain_collection_header(EK_BOTH, flags); + eprosima::fastcdr::external primitive_identifier{new TypeIdentifier()}; + primitive_identifier->_d(TK_UINT32); + PlainMapLTypeDefn plain_map = TypeObjectUtils::build_plain_map_l_type_defn(header, 500, primitive_identifier, flags, + primitive_identifier); + eprosima::fastcdr::external key_identifier{new TypeIdentifier()}; + key_identifier->_d(TK_INT8); + PlainMapLTypeDefn other_plain_map = TypeObjectUtils::build_plain_map_l_type_defn(header, 500, primitive_identifier, + flags, key_identifier); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, TypeObjectUtils::build_and_register_l_map_type_identifier(plain_map, + "large_map")); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, TypeObjectUtils::build_and_register_l_map_type_identifier(plain_map, + "large_map")); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_BAD_PARAMETER, TypeObjectUtils::build_and_register_l_map_type_identifier( + other_plain_map, "large_map")); + std::string type_name; + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_PRECONDITION_NOT_MET, TypeObjectUtils::build_and_register_l_map_type_identifier( + other_plain_map, + type_name)); +} + +// Build AppliedAnnotation invalid TypeIdentifier +TEST(TypeObjectUtilsTests, build_applied_annotation_invalid_type_identifier) +{ + TypeIdentifier type_id; + type_id._d(TK_INT32); + EXPECT_THROW(AppliedAnnotation annotation = TypeObjectUtils::build_applied_annotation(type_id, + eprosima::fastcdr::optional()), InvalidArgumentError); + CompleteAnnotationHeader annotation_header = TypeObjectUtils::build_complete_annotation_header("custom_annotation"); + CompleteAnnotationType custom_annotation = TypeObjectUtils::build_complete_annotation_type(0, annotation_header, + CompleteAnnotationParameterSeq()); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, + TypeObjectUtils::build_and_register_annotation_type_object(custom_annotation, + "custom")); + TypeIdentifierPair custom_annotation_ids; + ASSERT_EQ(eprosima::fastdds::dds::RETCODE_OK, + DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers("custom", + custom_annotation_ids)); + EXPECT_NO_THROW(AppliedAnnotation annotation = TypeObjectUtils::build_applied_annotation( + custom_annotation_ids.type_identifier1(), + eprosima::fastcdr::optional())); +} + +// Build CompleteMemberDetail with empty name +TEST(TypeObjectUtilsTests, build_complete_member_detail_empty_member_name) +{ + EXPECT_THROW(CompleteMemberDetail detail = TypeObjectUtils::build_complete_member_detail("", + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional()), InvalidArgumentError); + EXPECT_NO_THROW(CompleteMemberDetail detail = TypeObjectUtils::build_complete_member_detail("member_name", + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional())); +} + +// Build CompleteStructMember with inconsistent @hashid annotation value and member id +TEST(TypeObjectUtilsTests, build_complete_struct_member_inconsistent_hashid_member_id) +{ + StructMemberFlag basic_flags = TypeObjectUtils::build_struct_member_flag( + eprosima::fastdds::dds::xtypes::TryConstructKind::DISCARD, false, false, + false, false); + TypeIdentifier type_id; + type_id._d(TK_INT32); + CommonStructMember common = TypeObjectUtils::build_common_struct_member(0x047790DA, basic_flags, type_id); + AppliedBuiltinMemberAnnotations wrong_ann_builtin = TypeObjectUtils::build_applied_builtin_member_annotations( + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional("color")); + AppliedBuiltinMemberAnnotations ann_builtin = TypeObjectUtils::build_applied_builtin_member_annotations( + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional("shapesize")); + AppliedBuiltinMemberAnnotations empty_ann_builtin = TypeObjectUtils::build_applied_builtin_member_annotations( + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional("")); + CompleteMemberDetail wrong_detail = TypeObjectUtils::build_complete_member_detail("member_name", wrong_ann_builtin, + eprosima::fastcdr::optional()); + CompleteMemberDetail detail = TypeObjectUtils::build_complete_member_detail("member_name", ann_builtin, + eprosima::fastcdr::optional()); + CompleteMemberDetail empty_detail = TypeObjectUtils::build_complete_member_detail("shapesize", empty_ann_builtin, + eprosima::fastcdr::optional()); + CompleteMemberDetail other_wrong_detail = TypeObjectUtils::build_complete_member_detail("name", empty_ann_builtin, + eprosima::fastcdr::optional()); + EXPECT_THROW(CompleteStructMember member = TypeObjectUtils::build_complete_struct_member(common, wrong_detail), + InvalidArgumentError); + EXPECT_NO_THROW(CompleteStructMember member = TypeObjectUtils::build_complete_struct_member(common, detail)); + EXPECT_THROW(CompleteStructMember member = TypeObjectUtils::build_complete_struct_member(common, + other_wrong_detail), InvalidArgumentError); + EXPECT_NO_THROW(CompleteStructMember member = TypeObjectUtils::build_complete_struct_member(common, empty_detail)); +} + +// Build CompleteTypeDetail with empty type_name +TEST(TypeObjectUtilsTests, build_complete_type_detail_empty_type_name) +{ + EXPECT_THROW(CompleteTypeDetail detail = TypeObjectUtils::build_complete_type_detail( + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional(), ""), InvalidArgumentError); + EXPECT_NO_THROW(CompleteTypeDetail detail = TypeObjectUtils::build_complete_type_detail( + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional(), "type_name")); +} + +// Build CommonUnionMember with empty case labels +TEST(TypeObjectUtilsTests, build_common_union_member_empty_case_labels) +{ + UnionMemberFlag basic_flags = TypeObjectUtils::build_union_member_flag( + eprosima::fastdds::dds::xtypes::TryConstructKind::DISCARD, false, false); + UnionMemberFlag default_flags = TypeObjectUtils::build_union_member_flag( + eprosima::fastdds::dds::xtypes::TryConstructKind::DISCARD, true, false); + TypeIdentifier type_id; + type_id._d(TK_INT32); + EXPECT_THROW(CommonUnionMember common = TypeObjectUtils::build_common_union_member(0, basic_flags, type_id, + UnionCaseLabelSeq()), InvalidArgumentError); + EXPECT_NO_THROW(CommonUnionMember common = TypeObjectUtils::build_common_union_member(0, default_flags, type_id, + UnionCaseLabelSeq())); +} + +// Build CompleteUnionMember with inconsistent @hashid annotation value and member id +TEST(TypeObjectUtilsTests, build_complete_union_member_inconsistent_hashid_member_id) +{ + UnionMemberFlag basic_flags = TypeObjectUtils::build_union_member_flag( + eprosima::fastdds::dds::xtypes::TryConstructKind::DISCARD, false, false); + TypeIdentifier type_id; + type_id._d(TK_INT32); + CommonUnionMember common = TypeObjectUtils::build_common_union_member(0x047790DA, basic_flags, type_id, + {1}); + AppliedBuiltinMemberAnnotations wrong_ann_builtin = TypeObjectUtils::build_applied_builtin_member_annotations( + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional("color")); + AppliedBuiltinMemberAnnotations ann_builtin = TypeObjectUtils::build_applied_builtin_member_annotations( + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional("shapesize")); + AppliedBuiltinMemberAnnotations empty_ann_builtin = TypeObjectUtils::build_applied_builtin_member_annotations( + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional("")); + CompleteMemberDetail wrong_detail = TypeObjectUtils::build_complete_member_detail("member_name", wrong_ann_builtin, + eprosima::fastcdr::optional()); + CompleteMemberDetail detail = TypeObjectUtils::build_complete_member_detail("member_name", ann_builtin, + eprosima::fastcdr::optional()); + CompleteMemberDetail empty_detail = TypeObjectUtils::build_complete_member_detail("shapesize", empty_ann_builtin, + eprosima::fastcdr::optional()); + CompleteMemberDetail other_wrong_detail = TypeObjectUtils::build_complete_member_detail("name", empty_ann_builtin, + eprosima::fastcdr::optional()); + EXPECT_THROW(CompleteUnionMember member = TypeObjectUtils::build_complete_union_member(common, wrong_detail), + InvalidArgumentError); + EXPECT_NO_THROW(CompleteUnionMember member = TypeObjectUtils::build_complete_union_member(common, detail)); + EXPECT_THROW(CompleteUnionMember member = TypeObjectUtils::build_complete_union_member(common, + other_wrong_detail), InvalidArgumentError); + EXPECT_NO_THROW(CompleteUnionMember member = TypeObjectUtils::build_complete_union_member(common, empty_detail)); +} + +/** + * Auxiliary methods to build valid hash TypeIdentifiers + */ +void small_string_type_identifier( + TypeIdentifier& type_id) +{ + StringSTypeDefn small_string = TypeObjectUtils::build_string_s_type_defn(56); + type_id.string_sdefn(small_string); +} + +void large_string_type_identifier( + TypeIdentifier& type_id) +{ + StringLTypeDefn large_string = TypeObjectUtils::build_string_l_type_defn(300); + type_id.string_ldefn(large_string); +} + +const PlainCollectionHeader plain_collection_header() +{ + CollectionElementFlag flags = TypeObjectUtils::build_collection_element_flag( + eprosima::fastdds::dds::xtypes::TryConstructKind::DISCARD, false); + return TypeObjectUtils::build_plain_collection_header(EK_BOTH, flags); +} + +const eprosima::fastcdr::external primitive_type_identifier() +{ + eprosima::fastcdr::external primitive_type_id{new TypeIdentifier()}; + primitive_type_id->_d(TK_INT16); + return primitive_type_id; +} + +void small_sequence_type_identifier( + TypeIdentifier& type_id) +{ + PlainCollectionHeader collection_header = plain_collection_header(); + eprosima::fastcdr::external primitive_type_id = primitive_type_identifier(); + PlainSequenceSElemDefn small_seq = TypeObjectUtils::build_plain_sequence_s_elem_defn(collection_header, 100, + primitive_type_id); + type_id.seq_sdefn(small_seq); +} + +void large_sequence_type_identifier( + TypeIdentifier& type_id) +{ + PlainCollectionHeader collection_header = plain_collection_header(); + eprosima::fastcdr::external primitive_type_id = primitive_type_identifier(); + PlainSequenceLElemDefn large_seq = TypeObjectUtils::build_plain_sequence_l_elem_defn(collection_header, 1000, + primitive_type_id); + type_id.seq_ldefn(large_seq); +} + +void small_array_type_identifier( + TypeIdentifier& type_id) +{ + PlainCollectionHeader collection_header = plain_collection_header(); + eprosima::fastcdr::external primitive_type_id = primitive_type_identifier(); + PlainArraySElemDefn small_array = TypeObjectUtils::build_plain_array_s_elem_defn(collection_header, + {5, 3}, primitive_type_id); + type_id.array_sdefn(small_array); +} + +void large_array_type_identifier( + TypeIdentifier& type_id) +{ + PlainCollectionHeader collection_header = plain_collection_header(); + eprosima::fastcdr::external primitive_type_id = primitive_type_identifier(); + PlainArrayLElemDefn large_array = TypeObjectUtils::build_plain_array_l_elem_defn(collection_header, + {500, 3}, primitive_type_id); + type_id.array_ldefn(large_array); +} + +void small_map_type_identifier( + TypeIdentifier& type_id) +{ + PlainCollectionHeader collection_header = plain_collection_header(); + eprosima::fastcdr::external primitive_type_id = primitive_type_identifier(); + CollectionElementFlag flags = TypeObjectUtils::build_collection_element_flag( + eprosima::fastdds::dds::xtypes::TryConstructKind::DISCARD, false); + PlainMapSTypeDefn small_map = TypeObjectUtils::build_plain_map_s_type_defn(collection_header, 100, + primitive_type_id, flags, primitive_type_id); + type_id.map_sdefn(small_map); +} + +void large_map_type_identifier( + TypeIdentifier& type_id) +{ + PlainCollectionHeader collection_header = plain_collection_header(); + eprosima::fastcdr::external primitive_type_id = primitive_type_identifier(); + CollectionElementFlag flags = TypeObjectUtils::build_collection_element_flag( + eprosima::fastdds::dds::xtypes::TryConstructKind::DISCARD, false); + PlainMapLTypeDefn large_map = TypeObjectUtils::build_plain_map_l_type_defn(collection_header, 500, + primitive_type_id, flags, primitive_type_id); + type_id.map_ldefn(large_map); +} + +const CompleteAliasType int_16_alias() +{ + TypeIdentifier primitive_type_id; + primitive_type_id._d(TK_INT16); + CommonAliasBody int16_common_body = TypeObjectUtils::build_common_alias_body(0, primitive_type_id); + CompleteAliasBody int16_body = TypeObjectUtils::build_complete_alias_body(int16_common_body, + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional()); + CompleteTypeDetail empty_type_detail = TypeObjectUtils::build_complete_type_detail( + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional(), "type_name"); + CompleteAliasHeader alias_header = TypeObjectUtils::build_complete_alias_header(empty_type_detail); + return TypeObjectUtils::build_complete_alias_type(0, alias_header, int16_body); +} + +const CompleteAliasType float32_alias() +{ + TypeIdentifier primitive_type_id; + primitive_type_id._d(TK_FLOAT32); + CommonAliasBody float_common_body = TypeObjectUtils::build_common_alias_body(0, primitive_type_id); + CompleteAliasBody float_body = TypeObjectUtils::build_complete_alias_body(float_common_body, + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional()); + CompleteTypeDetail empty_type_detail = TypeObjectUtils::build_complete_type_detail( + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional(), "type_name"); + CompleteAliasHeader alias_header = TypeObjectUtils::build_complete_alias_header(empty_type_detail); + return TypeObjectUtils::build_complete_alias_type(0, alias_header, float_body); +} + +void register_basic_enum() +{ + std::string basic_enum_name = "basic_enum"; + CommonEnumeratedHeader common = TypeObjectUtils::build_common_enumerated_header(32); + CompleteTypeDetail detail = TypeObjectUtils::build_complete_type_detail( + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional(), basic_enum_name); + CompleteEnumeratedHeader header = TypeObjectUtils::build_complete_enumerated_header(common, detail); + CommonEnumeratedLiteral common_literal = TypeObjectUtils::build_common_enumerated_literal(1, 0); + CompleteMemberDetail detail_literal = TypeObjectUtils::build_complete_member_detail("literal", + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional()); + CompleteEnumeratedLiteral literal = TypeObjectUtils::build_complete_enumerated_literal(common_literal, + detail_literal); + CompleteEnumeratedLiteralSeq literal_seq; + TypeObjectUtils::add_complete_enumerated_literal(literal_seq, literal); + CompleteEnumeratedType enum_type = TypeObjectUtils::build_complete_enumerated_type(0, header, literal_seq); + TypeObjectUtils::build_and_register_enumerated_type_object(enum_type, basic_enum_name); +} + +void register_basic_bitmask() +{ + std::string basic_bitmask_name = "basic_bitmask"; + CommonEnumeratedHeader common = TypeObjectUtils::build_common_enumerated_header(32, true); + CompleteTypeDetail detail = TypeObjectUtils::build_complete_type_detail( + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional(), basic_bitmask_name); + CompleteEnumeratedHeader header = TypeObjectUtils::build_complete_enumerated_header(common, detail, true); + CommonBitflag common_flag = TypeObjectUtils::build_common_bitflag(5, 0); + CompleteMemberDetail detail_flag = TypeObjectUtils::build_complete_member_detail("flag", + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional()); + CompleteBitflag flag = TypeObjectUtils::build_complete_bitflag(common_flag, detail_flag); + CompleteBitflagSeq flag_seq; + TypeObjectUtils::add_complete_bitflag(flag_seq, flag); + CompleteBitmaskType bitmask_type = TypeObjectUtils::build_complete_bitmask_type(0, header, flag_seq); + TypeObjectUtils::build_and_register_bitmask_type_object(bitmask_type, basic_bitmask_name); +} + +// Build CommonDiscriminatorMember with inconsistent TypeIdentifier +TEST(TypeObjectUtilsTests, build_common_discriminator_member_inconsistent_type_identifier) +{ + UnionDiscriminatorFlag flags = TypeObjectUtils::build_union_discriminator_flag( + eprosima::fastdds::dds::xtypes::TryConstructKind::DISCARD, false); + TypeIdentifier type_id; + EXPECT_THROW(CommonDiscriminatorMember member = TypeObjectUtils::build_common_discriminator_member(flags, type_id), + InvalidArgumentError); + type_id._d(TK_BOOLEAN); + EXPECT_NO_THROW(CommonDiscriminatorMember member = TypeObjectUtils::build_common_discriminator_member(flags, + type_id)); + type_id._d(TK_BYTE); + EXPECT_NO_THROW(CommonDiscriminatorMember member = TypeObjectUtils::build_common_discriminator_member(flags, + type_id)); + type_id._d(TK_INT8); + EXPECT_NO_THROW(CommonDiscriminatorMember member = TypeObjectUtils::build_common_discriminator_member(flags, + type_id)); + type_id._d(TK_INT16); + EXPECT_NO_THROW(CommonDiscriminatorMember member = TypeObjectUtils::build_common_discriminator_member(flags, + type_id)); + type_id._d(TK_INT32); + EXPECT_NO_THROW(CommonDiscriminatorMember member = TypeObjectUtils::build_common_discriminator_member(flags, + type_id)); + type_id._d(TK_INT64); + EXPECT_NO_THROW(CommonDiscriminatorMember member = TypeObjectUtils::build_common_discriminator_member(flags, + type_id)); + type_id._d(TK_UINT8); + EXPECT_NO_THROW(CommonDiscriminatorMember member = TypeObjectUtils::build_common_discriminator_member(flags, + type_id)); + type_id._d(TK_UINT16); + EXPECT_NO_THROW(CommonDiscriminatorMember member = TypeObjectUtils::build_common_discriminator_member(flags, + type_id)); + type_id._d(TK_UINT32); + EXPECT_NO_THROW(CommonDiscriminatorMember member = TypeObjectUtils::build_common_discriminator_member(flags, + type_id)); + type_id._d(TK_UINT64); + EXPECT_NO_THROW(CommonDiscriminatorMember member = TypeObjectUtils::build_common_discriminator_member(flags, + type_id)); + type_id._d(TK_FLOAT32); + EXPECT_THROW(CommonDiscriminatorMember member = TypeObjectUtils::build_common_discriminator_member(flags, type_id), + InvalidArgumentError); + type_id._d(TK_FLOAT64); + EXPECT_THROW(CommonDiscriminatorMember member = TypeObjectUtils::build_common_discriminator_member(flags, type_id), + InvalidArgumentError); + type_id._d(TK_FLOAT128); + EXPECT_THROW(CommonDiscriminatorMember member = TypeObjectUtils::build_common_discriminator_member(flags, type_id), + InvalidArgumentError); + type_id._d(TK_CHAR8); + EXPECT_NO_THROW(CommonDiscriminatorMember member = TypeObjectUtils::build_common_discriminator_member(flags, + type_id)); + type_id._d(TK_CHAR16); + EXPECT_NO_THROW(CommonDiscriminatorMember member = TypeObjectUtils::build_common_discriminator_member(flags, + type_id)); + small_string_type_identifier(type_id); + EXPECT_THROW(CommonDiscriminatorMember member = TypeObjectUtils::build_common_discriminator_member(flags, type_id), + InvalidArgumentError); + type_id._d(TI_STRING16_SMALL); + EXPECT_THROW(CommonDiscriminatorMember member = TypeObjectUtils::build_common_discriminator_member(flags, type_id), + InvalidArgumentError); + large_string_type_identifier(type_id); + EXPECT_THROW(CommonDiscriminatorMember member = TypeObjectUtils::build_common_discriminator_member(flags, type_id), + InvalidArgumentError); + type_id._d(TI_STRING16_LARGE); + EXPECT_THROW(CommonDiscriminatorMember member = TypeObjectUtils::build_common_discriminator_member(flags, type_id), + InvalidArgumentError); + small_sequence_type_identifier(type_id); + EXPECT_THROW(CommonDiscriminatorMember member = TypeObjectUtils::build_common_discriminator_member(flags, type_id), + InvalidArgumentError); + large_sequence_type_identifier(type_id); + EXPECT_THROW(CommonDiscriminatorMember member = TypeObjectUtils::build_common_discriminator_member(flags, type_id), + InvalidArgumentError); + small_array_type_identifier(type_id); + EXPECT_THROW(CommonDiscriminatorMember member = TypeObjectUtils::build_common_discriminator_member(flags, type_id), + InvalidArgumentError); + large_array_type_identifier(type_id); + EXPECT_THROW(CommonDiscriminatorMember member = TypeObjectUtils::build_common_discriminator_member(flags, type_id), + InvalidArgumentError); + small_map_type_identifier(type_id); + EXPECT_THROW(CommonDiscriminatorMember member = TypeObjectUtils::build_common_discriminator_member(flags, type_id), + InvalidArgumentError); + large_map_type_identifier(type_id); + EXPECT_THROW(CommonDiscriminatorMember member = TypeObjectUtils::build_common_discriminator_member(flags, type_id), + InvalidArgumentError); + // Enum + register_basic_enum(); + TypeIdentifierPair type_ids; + DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers("basic_enum", type_ids); + EXPECT_NO_THROW(CommonDiscriminatorMember member = TypeObjectUtils::build_common_discriminator_member(flags, + type_ids.type_identifier1())); + // Bitmask + register_basic_bitmask(); + DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers("basic_bitmask", type_ids); + EXPECT_THROW(CommonDiscriminatorMember member = TypeObjectUtils::build_common_discriminator_member(flags, + type_ids.type_identifier1()), InvalidArgumentError); + // Alias: int16_t & float + CompleteAliasType int16_alias = int_16_alias(); + CompleteAliasType float_alias = float32_alias(); + TypeObjectUtils::build_and_register_alias_type_object(int16_alias, "alias_int16"); + TypeObjectUtils::build_and_register_alias_type_object(float_alias, "alias_float"); + TypeIdentifierPair alias_type_identifiers; + ASSERT_EQ(eprosima::fastdds::dds::RETCODE_OK, DomainParticipantFactory::get_instance()->type_object_registry(). + get_type_identifiers("alias_float", alias_type_identifiers)); + EXPECT_THROW(CommonDiscriminatorMember member = TypeObjectUtils::build_common_discriminator_member(flags, + alias_type_identifiers.type_identifier1()), InvalidArgumentError); + ASSERT_EQ(eprosima::fastdds::dds::RETCODE_OK, DomainParticipantFactory::get_instance()->type_object_registry(). + get_type_identifiers("alias_int16", alias_type_identifiers)); + EXPECT_NO_THROW(CommonDiscriminatorMember member = TypeObjectUtils::build_common_discriminator_member(flags, + alias_type_identifiers.type_identifier1())); +} + +// Add CompleteUnionMember to sequence with invalid name +TEST(TypeObjectUtilsTests, build_complete_union_member_invalid_name) +{ + std::string invalid_name = "discriminator"; + UnionMemberFlag member_flags = TypeObjectUtils::build_union_member_flag( + eprosima::fastdds::dds::xtypes::TryConstructKind::DISCARD, false, false); + TypeIdentifier type_id; + type_id._d(TK_FLOAT128); + UnionCaseLabelSeq case_labels; + TypeObjectUtils::add_union_case_label(case_labels, 5); + CommonUnionMember common_member = TypeObjectUtils::build_common_union_member(3, member_flags, type_id, case_labels); + CompleteMemberDetail invalid_member_detail = TypeObjectUtils::build_complete_member_detail(invalid_name, + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional()); + CompleteUnionMember member = TypeObjectUtils::build_complete_union_member(common_member, invalid_member_detail); + CompleteUnionMemberSeq member_seq; + EXPECT_THROW(TypeObjectUtils::add_complete_union_member(member_seq, member), InvalidArgumentError); +} + +// Build CommonAnnotationParameter with non-empty flags +TEST(TypeObjectUtilsTests, build_common_annotation_parameter_non_empty_flags) +{ + AnnotationParameterFlag non_empty_flags = 1; + AnnotationParameterFlag empty_flags = 0; + TypeIdentifier type_id; + EXPECT_NO_THROW(type_id._d(TK_INT16)); + EXPECT_THROW(CommonAnnotationParameter common = TypeObjectUtils::build_common_annotation_parameter(non_empty_flags, + type_id), InvalidArgumentError); + EXPECT_NO_THROW(CommonAnnotationParameter common = TypeObjectUtils::build_common_annotation_parameter(empty_flags, + type_id)); +} + +/** + * Auxiliary method to check annotation parameter consistency + */ +void check_annotation_parameter_consistency( + const CommonAnnotationParameter& common, + const std::vector& ann_param_seq, + const std::vector& expected_results) +{ + for (size_t i = 0; i < ann_param_seq.size(); i++) + { + if (expected_results[i]) + { + EXPECT_NO_THROW(CompleteAnnotationParameter param = TypeObjectUtils::build_complete_annotation_parameter( + common, "param_name", ann_param_seq[i])); + } + else + { + EXPECT_THROW(CompleteAnnotationParameter param = TypeObjectUtils::build_complete_annotation_parameter( + common, "param_name", ann_param_seq[i]), InvalidArgumentError); + } + } +} + +// Build CompleteAnnotationParameter with inconsistent TypeIdentifier and AnnotationParameterValue +TEST(TypeObjectUtilsTests, build_complete_annotation_parameter_inconsistent_data) +{ + AnnotationParameterValue bool_param = TypeObjectUtils::build_annotation_parameter_value(true); + AnnotationParameterValue byte_param = TypeObjectUtils::build_annotation_parameter_value_byte(16); + AnnotationParameterValue int8_param = TypeObjectUtils::build_annotation_parameter_value(static_cast(16)); + AnnotationParameterValue uint8_param = TypeObjectUtils::build_annotation_parameter_value(static_cast(16)); + AnnotationParameterValue int16_param = TypeObjectUtils::build_annotation_parameter_value(static_cast(16)); + AnnotationParameterValue uint16_param = TypeObjectUtils::build_annotation_parameter_value(static_cast( + 16)); + AnnotationParameterValue int32_param = TypeObjectUtils::build_annotation_parameter_value(static_cast(16)); + AnnotationParameterValue uint32_param = TypeObjectUtils::build_annotation_parameter_value(static_cast( + 16)); + AnnotationParameterValue int64_param = TypeObjectUtils::build_annotation_parameter_value(static_cast(16)); + AnnotationParameterValue uint64_param = TypeObjectUtils::build_annotation_parameter_value(static_cast( + 16)); + AnnotationParameterValue float32_param = TypeObjectUtils::build_annotation_parameter_value(static_cast(16)); + AnnotationParameterValue float64_param = TypeObjectUtils::build_annotation_parameter_value(static_cast(16)); + AnnotationParameterValue float128_param = TypeObjectUtils::build_annotation_parameter_value( + static_cast(16)); + AnnotationParameterValue char8_param = TypeObjectUtils::build_annotation_parameter_value('A'); + AnnotationParameterValue char16_param = TypeObjectUtils::build_annotation_parameter_value(L'A'); + // TODO(jlbueno) + AnnotationParameterValue enum_param = TypeObjectUtils::build_annotation_parameter_value_enum( + static_cast(0)); + AnnotationParameterValue string8_param = TypeObjectUtils::build_annotation_parameter_value( + eprosima::fastcdr::fixed_string<128>("Hello")); + AnnotationParameterValue string16_param = TypeObjectUtils::build_annotation_parameter_value(std::wstring(L"Hello")); + std::vector ann_param_seq; + ann_param_seq.push_back(bool_param); + ann_param_seq.push_back(byte_param); + ann_param_seq.push_back(int8_param); + ann_param_seq.push_back(uint8_param); + ann_param_seq.push_back(int16_param); + ann_param_seq.push_back(uint16_param); + ann_param_seq.push_back(int32_param); + ann_param_seq.push_back(uint32_param); + ann_param_seq.push_back(int64_param); + ann_param_seq.push_back(uint64_param); + ann_param_seq.push_back(float32_param); + ann_param_seq.push_back(float64_param); + ann_param_seq.push_back(float128_param); + ann_param_seq.push_back(char8_param); + ann_param_seq.push_back(char16_param); + ann_param_seq.push_back(enum_param); + ann_param_seq.push_back(string8_param); + ann_param_seq.push_back(string16_param); + CommonAnnotationParameter common; + std::vector expected_results = {false, false, false, false, false, false, false, false, false, false, false, + false, false, false, false, false, false, false}; + check_annotation_parameter_consistency(common, ann_param_seq, expected_results); + TypeIdentifier type_id; + type_id._d(TK_BOOLEAN); + common = TypeObjectUtils::build_common_annotation_parameter(0, type_id); + expected_results[0] = true; + check_annotation_parameter_consistency(common, ann_param_seq, expected_results); + type_id._d(TK_BYTE); + common = TypeObjectUtils::build_common_annotation_parameter(0, type_id); + expected_results[0] = false; + expected_results[1] = true; + check_annotation_parameter_consistency(common, ann_param_seq, expected_results); + type_id._d(TK_INT8); + common = TypeObjectUtils::build_common_annotation_parameter(0, type_id); + expected_results[1] = false; + expected_results[2] = true; + check_annotation_parameter_consistency(common, ann_param_seq, expected_results); + type_id._d(TK_INT16); + common = TypeObjectUtils::build_common_annotation_parameter(0, type_id); + expected_results[2] = false; + expected_results[4] = true; + check_annotation_parameter_consistency(common, ann_param_seq, expected_results); + type_id._d(TK_INT32); + common = TypeObjectUtils::build_common_annotation_parameter(0, type_id); + expected_results[4] = false; + expected_results[6] = true; + check_annotation_parameter_consistency(common, ann_param_seq, expected_results); + type_id._d(TK_INT64); + common = TypeObjectUtils::build_common_annotation_parameter(0, type_id); + expected_results[6] = false; + expected_results[8] = true; + check_annotation_parameter_consistency(common, ann_param_seq, expected_results); + type_id._d(TK_UINT8); + common = TypeObjectUtils::build_common_annotation_parameter(0, type_id); + expected_results[8] = false; + expected_results[3] = true; + check_annotation_parameter_consistency(common, ann_param_seq, expected_results); + type_id._d(TK_UINT16); + common = TypeObjectUtils::build_common_annotation_parameter(0, type_id); + expected_results[3] = false; + expected_results[5] = true; + check_annotation_parameter_consistency(common, ann_param_seq, expected_results); + type_id._d(TK_UINT32); + common = TypeObjectUtils::build_common_annotation_parameter(0, type_id); + expected_results[5] = false; + expected_results[7] = true; + check_annotation_parameter_consistency(common, ann_param_seq, expected_results); + type_id._d(TK_UINT64); + common = TypeObjectUtils::build_common_annotation_parameter(0, type_id); + expected_results[7] = false; + expected_results[9] = true; + check_annotation_parameter_consistency(common, ann_param_seq, expected_results); + type_id._d(TK_FLOAT32); + common = TypeObjectUtils::build_common_annotation_parameter(0, type_id); + expected_results[9] = false; + expected_results[10] = true; + check_annotation_parameter_consistency(common, ann_param_seq, expected_results); + type_id._d(TK_FLOAT64); + common = TypeObjectUtils::build_common_annotation_parameter(0, type_id); + expected_results[10] = false; + expected_results[11] = true; + check_annotation_parameter_consistency(common, ann_param_seq, expected_results); + type_id._d(TK_FLOAT128); + common = TypeObjectUtils::build_common_annotation_parameter(0, type_id); + expected_results[11] = false; + expected_results[12] = true; + check_annotation_parameter_consistency(common, ann_param_seq, expected_results); + type_id._d(TK_CHAR8); + common = TypeObjectUtils::build_common_annotation_parameter(0, type_id); + expected_results[12] = false; + expected_results[13] = true; + check_annotation_parameter_consistency(common, ann_param_seq, expected_results); + type_id._d(TK_CHAR16); + common = TypeObjectUtils::build_common_annotation_parameter(0, type_id); + expected_results[13] = false; + expected_results[14] = true; + check_annotation_parameter_consistency(common, ann_param_seq, expected_results); + small_string_type_identifier(type_id); + common = TypeObjectUtils::build_common_annotation_parameter(0, type_id); + expected_results[14] = false; + expected_results[16] = true; + check_annotation_parameter_consistency(common, ann_param_seq, expected_results); + type_id._d(TI_STRING16_SMALL); + common = TypeObjectUtils::build_common_annotation_parameter(0, type_id); + expected_results[16] = false; + expected_results[17] = true; + check_annotation_parameter_consistency(common, ann_param_seq, expected_results); + large_string_type_identifier(type_id); + common = TypeObjectUtils::build_common_annotation_parameter(0, type_id); + expected_results[17] = false; + expected_results[16] = true; + check_annotation_parameter_consistency(common, ann_param_seq, expected_results); + type_id._d(TI_STRING16_LARGE); + common = TypeObjectUtils::build_common_annotation_parameter(0, type_id); + expected_results[16] = false; + expected_results[17] = true; + check_annotation_parameter_consistency(common, ann_param_seq, expected_results); + small_sequence_type_identifier(type_id); + common = TypeObjectUtils::build_common_annotation_parameter(0, type_id); + expected_results[17] = false; + check_annotation_parameter_consistency(common, ann_param_seq, expected_results); + large_sequence_type_identifier(type_id); + common = TypeObjectUtils::build_common_annotation_parameter(0, type_id); + check_annotation_parameter_consistency(common, ann_param_seq, expected_results); + small_array_type_identifier(type_id); + common = TypeObjectUtils::build_common_annotation_parameter(0, type_id); + check_annotation_parameter_consistency(common, ann_param_seq, expected_results); + large_array_type_identifier(type_id); + common = TypeObjectUtils::build_common_annotation_parameter(0, type_id); + check_annotation_parameter_consistency(common, ann_param_seq, expected_results); + small_map_type_identifier(type_id); + common = TypeObjectUtils::build_common_annotation_parameter(0, type_id); + check_annotation_parameter_consistency(common, ann_param_seq, expected_results); + large_map_type_identifier(type_id); + common = TypeObjectUtils::build_common_annotation_parameter(0, type_id); + check_annotation_parameter_consistency(common, ann_param_seq, expected_results); + register_basic_enum(); + TypeIdentifierPair type_ids; + DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers("basic_enum", type_ids); + common = TypeObjectUtils::build_common_annotation_parameter(0, + type_ids.type_identifier1()); + expected_results[15] = true; + check_annotation_parameter_consistency(common, ann_param_seq, expected_results); + register_basic_bitmask(); + DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers("basic_bitmask", type_ids); + common = TypeObjectUtils::build_common_annotation_parameter(0, + type_ids.type_identifier1()); + expected_results[15] = false; + check_annotation_parameter_consistency(common, ann_param_seq, expected_results); +} + +// Build CompleteAnnotationParameter with empty name +TEST(TypeObjectUtilsTests, build_complete_annotation_parameter_empty_name) +{ + std::string parameter_name; + TypeIdentifier type_id; + type_id._d(TK_INT32); + CommonAnnotationParameter common = TypeObjectUtils::build_common_annotation_parameter(0, type_id); + int32_t param_value = 100; + AnnotationParameterValue param = TypeObjectUtils::build_annotation_parameter_value(param_value); + EXPECT_THROW(CompleteAnnotationParameter ann_param = TypeObjectUtils::build_complete_annotation_parameter(common, + parameter_name, param), InvalidArgumentError); + EXPECT_NO_THROW(CompleteAnnotationParameter ann_param = TypeObjectUtils::build_complete_annotation_parameter(common, + "parameter_name", param)); +} + +// Build CompleteAnnotationHeader with empty name +TEST(TypeObjectUtilsTests, build_complete_annotation_header_empty_name) +{ + std::string annotation_name; + EXPECT_THROW(CompleteAnnotationHeader header = TypeObjectUtils::build_complete_annotation_header(annotation_name), + InvalidArgumentError); + EXPECT_NO_THROW(CompleteAnnotationHeader header = TypeObjectUtils::build_complete_annotation_header( + "annotation_name")); +} + +// Build CompleteAnnotationType with non-empty flags +TEST(TypeObjectUtilsTests, build_complete_annotation_type_non_empty_flags) +{ + AnnotationTypeFlag non_empty_flags = 1; + AnnotationTypeFlag empty_flags = 0; + CompleteAnnotationHeader header = TypeObjectUtils::build_complete_annotation_header("annotation_name"); + CompleteAnnotationParameterSeq sequence; + EXPECT_THROW(CompleteAnnotationType annotation = TypeObjectUtils::build_complete_annotation_type(non_empty_flags, + header, sequence), InvalidArgumentError); + EXPECT_NO_THROW(CompleteAnnotationType annotation = TypeObjectUtils::build_complete_annotation_type(empty_flags, + header, sequence)); +} + +// Build CommonAliasBody with non-empty flags +TEST(TypeObjectUtilsTests, build_common_alias_body_non_empty_flags) +{ + AliasMemberFlag non_empty_flags = 1; + AliasMemberFlag empty_flags = 0; + TypeIdentifier type_id; + EXPECT_NO_THROW(type_id._d(TK_INT16)); + EXPECT_THROW(CommonAliasBody common = TypeObjectUtils::build_common_alias_body(non_empty_flags, + type_id), InvalidArgumentError); + EXPECT_NO_THROW(CommonAliasBody common = TypeObjectUtils::build_common_alias_body(empty_flags, + type_id)); +} + +// Build CompleteAliasBody with @hashid annotation applied +TEST(TypeObjectUtilsTests, build_complete_alias_body_inconsistent_hashid) +{ + TypeIdentifier type_id; + type_id._d(TK_INT16); + CommonAliasBody common_body = TypeObjectUtils::build_common_alias_body(0, type_id); + AppliedBuiltinMemberAnnotations unit_builtin_ann = TypeObjectUtils::build_applied_builtin_member_annotations( + eprosima::fastcdr::optional("unit"), eprosima::fastcdr::optional(), + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional()); + // TODO(jlbueno) @min & @max annotations cannot be applied: TypeObject depends on 'any' block implementation. + AppliedBuiltinMemberAnnotations hash_id_builtin_ann = TypeObjectUtils::build_applied_builtin_member_annotations( + eprosima::fastcdr::optional(), eprosima::fastcdr::optional(), + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional("member_hash")); + EXPECT_THROW(CompleteAliasBody body = TypeObjectUtils::build_complete_alias_body(common_body, hash_id_builtin_ann, + eprosima::fastcdr::optional()), InvalidArgumentError); + EXPECT_NO_THROW(CompleteAliasBody body = TypeObjectUtils::build_complete_alias_body(common_body, unit_builtin_ann, + eprosima::fastcdr::optional())); +} + +// Build CompleteAliasType with non-empty flags +TEST(TypeObjectUtilsTests, build_complete_alias_type_non_empty_flags) +{ + AliasTypeFlag non_empty_flags = 1; + AliasTypeFlag empty_flags = 0; + CompleteTypeDetail detail = TypeObjectUtils::build_complete_type_detail( + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional(), "alias_name"); + CompleteAliasHeader header = TypeObjectUtils::build_complete_alias_header(detail); + TypeIdentifier type_id; + type_id._d(TK_CHAR8); + CommonAliasBody common = TypeObjectUtils::build_common_alias_body(0, type_id); + eprosima::fastcdr::optional ann_builtin; + eprosima::fastcdr::optional ann_custom; + CompleteAliasBody body = TypeObjectUtils::build_complete_alias_body(common, ann_builtin, ann_custom); + EXPECT_THROW(CompleteAliasType alias = TypeObjectUtils::build_complete_alias_type(non_empty_flags, + header, body), InvalidArgumentError); + EXPECT_NO_THROW(CompleteAliasType alias = TypeObjectUtils::build_complete_alias_type(empty_flags, + header, body)); +} + +// Build CompleteElementDetail with @hasid builtin annotation +TEST(TypeObjectUtilsTests, build_complete_element_detail_inconsistent_hashid) +{ + AppliedBuiltinMemberAnnotations unit_builtin_ann = TypeObjectUtils::build_applied_builtin_member_annotations( + eprosima::fastcdr::optional("unit"), eprosima::fastcdr::optional(), + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional()); + // TODO(jlbueno) @min & @max annotations cannot be applied: TypeObject depends on 'any' block implementation. + AppliedBuiltinMemberAnnotations hash_id_builtin_ann = TypeObjectUtils::build_applied_builtin_member_annotations( + eprosima::fastcdr::optional(), eprosima::fastcdr::optional(), + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional("member_hash")); + EXPECT_THROW(CompleteElementDetail element_detail = TypeObjectUtils::build_complete_element_detail( + hash_id_builtin_ann, eprosima::fastcdr::optional()), InvalidArgumentError); + EXPECT_NO_THROW(CompleteElementDetail element_detail = TypeObjectUtils::build_complete_element_detail( + unit_builtin_ann, eprosima::fastcdr::optional())); +} + +// Build CompleteSequenceType with non-empty flags. +TEST(TypeObjectUtilsTests, build_complete_sequence_type_non_empty_flags) +{ + CollectionTypeFlag non_empty_flags = 1; + CollectionTypeFlag empty_flags = 0; + CommonCollectionHeader common_header = TypeObjectUtils::build_common_collection_header(356); + CompleteCollectionHeader header = TypeObjectUtils::build_complete_collection_header(common_header, + eprosima::fastcdr::optional()); + CollectionElementFlag flags = TypeObjectUtils::build_collection_element_flag( + eprosima::fastdds::dds::xtypes::TryConstructKind::USE_DEFAULT, true); + TypeIdentifier type_id; + type_id._d(TK_FLOAT128); + CommonCollectionElement common_element = TypeObjectUtils::build_common_collection_element(flags, type_id); + CompleteElementDetail detail; + CompleteCollectionElement element = TypeObjectUtils::build_complete_collection_element(common_element, detail); + EXPECT_THROW(CompleteSequenceType sequence = TypeObjectUtils::build_complete_sequence_type(non_empty_flags, header, + element), InvalidArgumentError); + EXPECT_NO_THROW(CompleteSequenceType sequence = TypeObjectUtils::build_complete_sequence_type(empty_flags, header, + element)); +} + +// Build CommonArrayHeader with invalid bound +TEST(TypeObjectUtilsTests, build_common_array_header_invalid_bound) +{ + LBoundSeq array_bounds; + EXPECT_THROW(CommonArrayHeader header = TypeObjectUtils::build_common_array_header(array_bounds), + InvalidArgumentError); + LBound bound = 150; + TypeObjectUtils::add_array_dimension(array_bounds, bound); + EXPECT_NO_THROW(CommonArrayHeader header = TypeObjectUtils::build_common_array_header(array_bounds)); + bound = 0; + EXPECT_THROW(TypeObjectUtils::add_array_dimension(array_bounds, bound), InvalidArgumentError); + array_bounds.push_back(bound); + EXPECT_THROW(CommonArrayHeader header = TypeObjectUtils::build_common_array_header(array_bounds), + InvalidArgumentError); +} + +// Build CompleteArrayType with non-empty flags. +TEST(TypeObjectUtilsTests, build_complete_array_type_non_empty_flags) +{ + CollectionTypeFlag non_empty_flags = 1; + CollectionTypeFlag empty_flags = 0; + LBoundSeq array_bounds; + LBound bound = 356; + TypeObjectUtils::add_array_dimension(array_bounds, bound); + CommonArrayHeader common_header = TypeObjectUtils::build_common_array_header(array_bounds); + CompleteTypeDetail type_detail = TypeObjectUtils::build_complete_type_detail( + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional(), "array_type_name"); + CompleteArrayHeader header = TypeObjectUtils::build_complete_array_header(common_header, type_detail); + CollectionElementFlag flags = TypeObjectUtils::build_collection_element_flag( + eprosima::fastdds::dds::xtypes::TryConstructKind::USE_DEFAULT, true); + TypeIdentifier type_id; + type_id._d(TK_FLOAT128); + CommonCollectionElement common_element = TypeObjectUtils::build_common_collection_element(flags, type_id); + CompleteElementDetail detail; + CompleteCollectionElement element = TypeObjectUtils::build_complete_collection_element(common_element, detail); + EXPECT_THROW(CompleteArrayType array = TypeObjectUtils::build_complete_array_type(non_empty_flags, header, + element), InvalidArgumentError); + EXPECT_NO_THROW(CompleteArrayType array = TypeObjectUtils::build_complete_array_type(empty_flags, header, + element)); +} + +// Build CompleteMapType with non-empty flags. +TEST(TypeObjectUtilsTests, build_complete_map_type_non_empty_flags) +{ + CollectionTypeFlag non_empty_flags = 1; + CollectionTypeFlag empty_flags = 0; + CommonCollectionHeader common_header = TypeObjectUtils::build_common_collection_header(356); + CompleteCollectionHeader header = TypeObjectUtils::build_complete_collection_header(common_header, + eprosima::fastcdr::optional()); + CollectionElementFlag flags = TypeObjectUtils::build_collection_element_flag( + eprosima::fastdds::dds::xtypes::TryConstructKind::USE_DEFAULT, true); + TypeIdentifier type_id; + type_id._d(TK_INT16); + CommonCollectionElement common_element = TypeObjectUtils::build_common_collection_element(flags, type_id); + CompleteElementDetail detail; + CompleteCollectionElement element = TypeObjectUtils::build_complete_collection_element(common_element, detail); + EXPECT_THROW(CompleteMapType map = TypeObjectUtils::build_complete_map_type(non_empty_flags, header, + element, element), InvalidArgumentError); + EXPECT_NO_THROW(CompleteMapType map = TypeObjectUtils::build_complete_map_type(empty_flags, header, + element, element)); +} + +// Build CompleteMapType with inconsistent key TypeIdentifier. +TEST(TypeObjectUtilsTests, build_complete_map_type_inconsistent_key) +{ + CollectionTypeFlag empty_flags = 0; + CommonCollectionHeader common_header = TypeObjectUtils::build_common_collection_header(356); + CompleteCollectionHeader header = TypeObjectUtils::build_complete_collection_header(common_header, + eprosima::fastcdr::optional()); + CollectionElementFlag flags = TypeObjectUtils::build_collection_element_flag( + eprosima::fastdds::dds::xtypes::TryConstructKind::USE_DEFAULT, true); + TypeIdentifier type_id; + type_id._d(TK_FLOAT32); + CommonCollectionElement common_element = TypeObjectUtils::build_common_collection_element(flags, type_id); + CompleteElementDetail detail; + CompleteCollectionElement element = TypeObjectUtils::build_complete_collection_element(common_element, detail); + EXPECT_THROW(CompleteMapType map = TypeObjectUtils::build_complete_map_type(empty_flags, header, + element, element), InvalidArgumentError); + TypeIdentifier key_type_id; + key_type_id._d(TK_INT32); + CommonCollectionElement common_key = TypeObjectUtils::build_common_collection_element(flags, key_type_id); + CompleteCollectionElement key = TypeObjectUtils::build_complete_collection_element(common_key, detail); + EXPECT_NO_THROW(CompleteMapType map = TypeObjectUtils::build_complete_map_type(empty_flags, header, + key, element)); + key_type_id._d(TK_BOOLEAN); + common_key = TypeObjectUtils::build_common_collection_element(flags, key_type_id); + key = TypeObjectUtils::build_complete_collection_element(common_key, detail); + EXPECT_THROW(CompleteMapType map = TypeObjectUtils::build_complete_map_type(empty_flags, header, + key, element), InvalidArgumentError); + key_type_id._d(TK_BYTE); + common_key = TypeObjectUtils::build_common_collection_element(flags, key_type_id); + key = TypeObjectUtils::build_complete_collection_element(common_key, detail); + EXPECT_THROW(CompleteMapType map = TypeObjectUtils::build_complete_map_type(empty_flags, header, + key, element), InvalidArgumentError); + key_type_id._d(TK_FLOAT64); + common_key = TypeObjectUtils::build_common_collection_element(flags, key_type_id); + key = TypeObjectUtils::build_complete_collection_element(common_key, detail); + EXPECT_THROW(CompleteMapType map = TypeObjectUtils::build_complete_map_type(empty_flags, header, + key, element), InvalidArgumentError); + key_type_id._d(TK_FLOAT128); + common_key = TypeObjectUtils::build_common_collection_element(flags, key_type_id); + key = TypeObjectUtils::build_complete_collection_element(common_key, detail); + EXPECT_THROW(CompleteMapType map = TypeObjectUtils::build_complete_map_type(empty_flags, header, + key, element), InvalidArgumentError); + key_type_id._d(TK_CHAR8); + common_key = TypeObjectUtils::build_common_collection_element(flags, key_type_id); + key = TypeObjectUtils::build_complete_collection_element(common_key, detail); + EXPECT_THROW(CompleteMapType map = TypeObjectUtils::build_complete_map_type(empty_flags, header, + key, element), InvalidArgumentError); + key_type_id._d(TK_CHAR16); + common_key = TypeObjectUtils::build_common_collection_element(flags, key_type_id); + key = TypeObjectUtils::build_complete_collection_element(common_key, detail); + EXPECT_THROW(CompleteMapType map = TypeObjectUtils::build_complete_map_type(empty_flags, header, + key, element), InvalidArgumentError); + small_string_type_identifier(key_type_id); + common_key = TypeObjectUtils::build_common_collection_element(flags, key_type_id); + key = TypeObjectUtils::build_complete_collection_element(common_key, detail); + EXPECT_NO_THROW(CompleteMapType map = TypeObjectUtils::build_complete_map_type(empty_flags, header, + key, element)); + key_type_id._d(TI_STRING16_SMALL); + common_key = TypeObjectUtils::build_common_collection_element(flags, key_type_id); + key = TypeObjectUtils::build_complete_collection_element(common_key, detail); + EXPECT_NO_THROW(CompleteMapType map = TypeObjectUtils::build_complete_map_type(empty_flags, header, + key, element)); + large_string_type_identifier(key_type_id); + common_key = TypeObjectUtils::build_common_collection_element(flags, key_type_id); + key = TypeObjectUtils::build_complete_collection_element(common_key, detail); + EXPECT_NO_THROW(CompleteMapType map = TypeObjectUtils::build_complete_map_type(empty_flags, header, + key, element)); + key_type_id._d(TI_STRING16_LARGE); + common_key = TypeObjectUtils::build_common_collection_element(flags, key_type_id); + key = TypeObjectUtils::build_complete_collection_element(common_key, detail); + EXPECT_NO_THROW(CompleteMapType map = TypeObjectUtils::build_complete_map_type(empty_flags, header, + key, element)); + small_sequence_type_identifier(key_type_id); + common_key = TypeObjectUtils::build_common_collection_element(flags, key_type_id); + key = TypeObjectUtils::build_complete_collection_element(common_key, detail); + EXPECT_THROW(CompleteMapType map = TypeObjectUtils::build_complete_map_type(empty_flags, header, + key, element), InvalidArgumentError); + large_sequence_type_identifier(key_type_id); + common_key = TypeObjectUtils::build_common_collection_element(flags, key_type_id); + key = TypeObjectUtils::build_complete_collection_element(common_key, detail); + EXPECT_THROW(CompleteMapType map = TypeObjectUtils::build_complete_map_type(empty_flags, header, + key, element), InvalidArgumentError); + small_array_type_identifier(key_type_id); + common_key = TypeObjectUtils::build_common_collection_element(flags, key_type_id); + key = TypeObjectUtils::build_complete_collection_element(common_key, detail); + EXPECT_THROW(CompleteMapType map = TypeObjectUtils::build_complete_map_type(empty_flags, header, + key, element), InvalidArgumentError); + large_array_type_identifier(key_type_id); + common_key = TypeObjectUtils::build_common_collection_element(flags, key_type_id); + key = TypeObjectUtils::build_complete_collection_element(common_key, detail); + EXPECT_THROW(CompleteMapType map = TypeObjectUtils::build_complete_map_type(empty_flags, header, + key, element), InvalidArgumentError); + small_map_type_identifier(key_type_id); + common_key = TypeObjectUtils::build_common_collection_element(flags, key_type_id); + key = TypeObjectUtils::build_complete_collection_element(common_key, detail); + EXPECT_THROW(CompleteMapType map = TypeObjectUtils::build_complete_map_type(empty_flags, header, + key, element), InvalidArgumentError); + large_map_type_identifier(key_type_id); + common_key = TypeObjectUtils::build_common_collection_element(flags, key_type_id); + key = TypeObjectUtils::build_complete_collection_element(common_key, detail); + EXPECT_THROW(CompleteMapType map = TypeObjectUtils::build_complete_map_type(empty_flags, header, + key, element), InvalidArgumentError); + register_basic_enum(); + TypeIdentifierPair type_ids; + DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers("basic_enum", type_ids); + common_key = TypeObjectUtils::build_common_collection_element(flags, + type_ids.type_identifier1()); + key = TypeObjectUtils::build_complete_collection_element(common_key, detail); + EXPECT_THROW(CompleteMapType map = TypeObjectUtils::build_complete_map_type(empty_flags, header, + key, element), InvalidArgumentError); + register_basic_bitmask(); + DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers("basic_bitmask", type_ids); + common_key = TypeObjectUtils::build_common_collection_element(flags, + type_ids.type_identifier1()); + key = TypeObjectUtils::build_complete_collection_element(common_key, detail); + EXPECT_THROW(CompleteMapType map = TypeObjectUtils::build_complete_map_type(empty_flags, header, + key, element), InvalidArgumentError); + CompleteAliasType int16_alias = int_16_alias(); + CompleteAliasType float_alias = float32_alias(); + TypeObjectUtils::build_and_register_alias_type_object(int16_alias, "alias_int16"); + TypeObjectUtils::build_and_register_alias_type_object(float_alias, "alias_float"); + TypeIdentifierPair alias_type_identifiers; + ASSERT_EQ(eprosima::fastdds::dds::RETCODE_OK, DomainParticipantFactory::get_instance()->type_object_registry(). + get_type_identifiers("alias_float", alias_type_identifiers)); + common_key = TypeObjectUtils::build_common_collection_element(flags, + alias_type_identifiers.type_identifier1()); + key = TypeObjectUtils::build_complete_collection_element(common_key, detail); + EXPECT_THROW(CompleteMapType map = TypeObjectUtils::build_complete_map_type(empty_flags, header, + key, element), InvalidArgumentError); + ASSERT_EQ(eprosima::fastdds::dds::RETCODE_OK, DomainParticipantFactory::get_instance()->type_object_registry(). + get_type_identifiers("alias_int16", alias_type_identifiers)); + common_key = TypeObjectUtils::build_common_collection_element(flags, + alias_type_identifiers.type_identifier1()); + key = TypeObjectUtils::build_complete_collection_element(common_key, detail); + EXPECT_NO_THROW(CompleteMapType map = TypeObjectUtils::build_complete_map_type(empty_flags, header, + key, element)); +} + +// Build CompleteEnumeratedLiteral with non-applying builtin annotations. +TEST(TypeObjectUtilsTests, build_complete_enumerated_literal_invalid_builtin_annotations) +{ + AppliedBuiltinMemberAnnotations unit_builtin_ann = TypeObjectUtils::build_applied_builtin_member_annotations( + eprosima::fastcdr::optional("unit"), eprosima::fastcdr::optional(), + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional()); + // TODO(jlbueno) @min & @max annotations cannot be applied: TypeObject depends on 'any' block implementation. + AppliedBuiltinMemberAnnotations hash_id_builtin_ann = TypeObjectUtils::build_applied_builtin_member_annotations( + eprosima::fastcdr::optional(), eprosima::fastcdr::optional(), + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional("member_hash")); + CompleteMemberDetail unit_member = TypeObjectUtils::build_complete_member_detail("member_name", unit_builtin_ann, + eprosima::fastcdr::optional()); + CompleteMemberDetail hash_id_member = TypeObjectUtils::build_complete_member_detail("member_name", + hash_id_builtin_ann, eprosima::fastcdr::optional()); + EXPECT_THROW(CompleteEnumeratedLiteral enum_literal = TypeObjectUtils::build_complete_enumerated_literal( + CommonEnumeratedLiteral(), unit_member), InvalidArgumentError); + EXPECT_THROW(CompleteEnumeratedLiteral enum_literal = TypeObjectUtils::build_complete_enumerated_literal( + CommonEnumeratedLiteral(), hash_id_member), InvalidArgumentError); +} + +// Build CommonEnumeratedHeader with inconsistent bit bound +TEST(TypeObjectUtilsTests, build_common_enumerated_header_inconsistent_bit_bound) +{ + BitBound bit_bound = 0; + EXPECT_THROW(CommonEnumeratedHeader header = TypeObjectUtils::build_common_enumerated_header(bit_bound), + InvalidArgumentError); + bit_bound = 16; + EXPECT_NO_THROW(CommonEnumeratedHeader header = TypeObjectUtils::build_common_enumerated_header(bit_bound)); + bit_bound = 33; + EXPECT_THROW(CommonEnumeratedHeader header = TypeObjectUtils::build_common_enumerated_header(bit_bound), + InvalidArgumentError); +} + +// Build CompleteEnumeratedType with non-empty flags +TEST(TypeObjectUtilsTests, build_complete_enumerated_type_non_empty_flags) +{ + EnumTypeFlag empty_flags = 0; + EnumTypeFlag non_empty_flags = 1; + CommonEnumeratedHeader common_header = TypeObjectUtils::build_common_enumerated_header(32); + CompleteTypeDetail type_detail = TypeObjectUtils::build_complete_type_detail( + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional(), "enumerated_type_name"); + CompleteEnumeratedHeader header = TypeObjectUtils::build_complete_enumerated_header(common_header, type_detail); + CommonEnumeratedLiteral common_literal = TypeObjectUtils::build_common_enumerated_literal(1, 0); + CompleteMemberDetail member_detail = TypeObjectUtils::build_complete_member_detail("enum_member_name", + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional()); + CompleteEnumeratedLiteral literal = TypeObjectUtils::build_complete_enumerated_literal(common_literal, + member_detail); + CompleteEnumeratedLiteralSeq literal_seq; + TypeObjectUtils::add_complete_enumerated_literal(literal_seq, literal); + EXPECT_THROW(CompleteEnumeratedType enumeration = TypeObjectUtils::build_complete_enumerated_type(non_empty_flags, + header, literal_seq), InvalidArgumentError); + EXPECT_NO_THROW(CompleteEnumeratedType enumeration = TypeObjectUtils::build_complete_enumerated_type(empty_flags, + header, literal_seq)); +} + +// Build CommonBitflag with inconsistent data +TEST(TypeObjectUtilsTests, build_common_bitflag_inconsistent_data) +{ + BitflagFlag empty_flags = 0; + BitflagFlag non_empty_flags = 1; + EXPECT_THROW(CommonBitflag bitflag = TypeObjectUtils::build_common_bitflag(65, non_empty_flags), + InvalidArgumentError); + EXPECT_THROW(CommonBitflag bitflag = TypeObjectUtils::build_common_bitflag(65, empty_flags), + InvalidArgumentError); + EXPECT_THROW(CommonBitflag bitflag = TypeObjectUtils::build_common_bitflag(32, non_empty_flags), + InvalidArgumentError); + EXPECT_NO_THROW(CommonBitflag bitflag = TypeObjectUtils::build_common_bitflag(32, empty_flags)); +} + +// Build CompleteBitflag with non-applying builtin annotations. +TEST(TypeObjectUtilsTests, build_complete_bitflag_invalid_builtin_annotations) +{ + AppliedBuiltinMemberAnnotations unit_builtin_ann = TypeObjectUtils::build_applied_builtin_member_annotations( + eprosima::fastcdr::optional("unit"), eprosima::fastcdr::optional(), + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional()); + // TODO(jlbueno) @min & @max annotations cannot be applied: TypeObject depends on 'any' block implementation. + AppliedBuiltinMemberAnnotations hash_id_builtin_ann = TypeObjectUtils::build_applied_builtin_member_annotations( + eprosima::fastcdr::optional(), eprosima::fastcdr::optional(), + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional("member_hash")); + CompleteMemberDetail unit_member = TypeObjectUtils::build_complete_member_detail("member_name", unit_builtin_ann, + eprosima::fastcdr::optional()); + CompleteMemberDetail hash_id_member = TypeObjectUtils::build_complete_member_detail("member_name", + hash_id_builtin_ann, eprosima::fastcdr::optional()); + EXPECT_THROW(CompleteBitflag bitflag = TypeObjectUtils::build_complete_bitflag(CommonBitflag(), unit_member), + InvalidArgumentError); + EXPECT_THROW(CompleteBitflag bitflag = TypeObjectUtils::build_complete_bitflag(CommonBitflag(), hash_id_member), + InvalidArgumentError); +} + +// Build CommonEnumeratedHeader with inconsistent bitmask bit bound +TEST(TypeObjectUtilsTests, build_common_enumerated_header_inconsistent_bitmask_bit_bound) +{ + BitBound bit_bound = 0; + EXPECT_THROW(CommonEnumeratedHeader header = TypeObjectUtils::build_common_enumerated_header(bit_bound, true), + InvalidArgumentError); + bit_bound = 33; + EXPECT_NO_THROW(CommonEnumeratedHeader header = TypeObjectUtils::build_common_enumerated_header(bit_bound, true)); + bit_bound = 65; + EXPECT_THROW(CommonEnumeratedHeader header = TypeObjectUtils::build_common_enumerated_header(bit_bound, true), + InvalidArgumentError); +} + +// Build CompleteBitmaskType with non-empty flags +TEST(TypeObjectUtilsTests, build_complete_bitmask_type_non_empty_flags) +{ + EnumTypeFlag empty_flags = 0; + EnumTypeFlag non_empty_flags = 1; + CommonEnumeratedHeader common_header = TypeObjectUtils::build_common_enumerated_header(64, true); + CompleteTypeDetail type_detail = TypeObjectUtils::build_complete_type_detail( + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional(), "bitmask_type_name"); + CompleteBitmaskHeader header = TypeObjectUtils::build_complete_enumerated_header(common_header, type_detail, true); + CompleteMemberDetail member_detail = TypeObjectUtils::build_complete_member_detail("bitflag_name", + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional()); + CompleteBitflag bitflag = TypeObjectUtils::build_complete_bitflag(CommonBitflag(), member_detail); + CompleteBitflagSeq bitflag_seq; + TypeObjectUtils::add_complete_bitflag(bitflag_seq, bitflag); + EXPECT_THROW(CompleteBitmaskType bitmask = TypeObjectUtils::build_complete_bitmask_type(non_empty_flags, header, + bitflag_seq), InvalidArgumentError); + EXPECT_NO_THROW(CompleteBitmaskType bitmask = TypeObjectUtils::build_complete_bitmask_type(empty_flags, header, + bitflag_seq)); +} + +// Build CommonBitfield with inconsistent data +TEST(TypeObjectUtilsTests, build_common_bitfield_inconsistent_data) +{ + BitsetMemberFlag empty_flags = 0; + BitsetMemberFlag non_empty_flags = 1; + EXPECT_THROW(CommonBitfield bitfield = TypeObjectUtils::build_common_bitfield(65, non_empty_flags, 0, TK_FLOAT128), + InvalidArgumentError); + EXPECT_THROW(CommonBitfield bitfield = TypeObjectUtils::build_common_bitfield(32, non_empty_flags, 0, TK_FLOAT128), + InvalidArgumentError); + EXPECT_THROW(CommonBitfield bitfield = TypeObjectUtils::build_common_bitfield(65, empty_flags, 0, TK_FLOAT128), + InvalidArgumentError); + EXPECT_THROW(CommonBitfield bitfield = TypeObjectUtils::build_common_bitfield(65, non_empty_flags, 3, TK_FLOAT128), + InvalidArgumentError); + EXPECT_THROW(CommonBitfield bitfield = TypeObjectUtils::build_common_bitfield(65, non_empty_flags, 0, TK_BYTE), + InvalidArgumentError); + EXPECT_NO_THROW(CommonBitfield bitfield = TypeObjectUtils::build_common_bitfield(32, empty_flags, 3, TK_BYTE)); + EXPECT_THROW(CommonBitfield bitfield = TypeObjectUtils::build_common_bitfield(32, empty_flags, 3, TK_BOOLEAN), + InvalidArgumentError); + EXPECT_THROW(CommonBitfield bitfield = TypeObjectUtils::build_common_bitfield(32, empty_flags, 15, TK_BYTE), + InvalidArgumentError); + EXPECT_THROW(CommonBitfield bitfield = TypeObjectUtils::build_common_bitfield(32, empty_flags, 27, TK_UINT16), + InvalidArgumentError); + EXPECT_THROW(CommonBitfield bitfield = TypeObjectUtils::build_common_bitfield(0, empty_flags, 33, TK_INT32), + InvalidArgumentError); + EXPECT_NO_THROW(CommonBitfield bitfield = TypeObjectUtils::build_common_bitfield(0, empty_flags, 64, TK_INT64)); + EXPECT_THROW(CommonBitfield bitfield = TypeObjectUtils::build_common_bitfield(1, empty_flags, 64, TK_UINT64), + InvalidArgumentError); +} + +// Build CompleteBitfield with non-applying builtin annotations. +TEST(TypeObjectUtilsTests, build_complete_bitfield_invalid_builtin_annotations) +{ + AppliedBuiltinMemberAnnotations unit_builtin_ann = TypeObjectUtils::build_applied_builtin_member_annotations( + eprosima::fastcdr::optional("unit"), eprosima::fastcdr::optional(), + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional()); + // TODO(jlbueno) @min & @max annotations cannot be applied: TypeObject depends on 'any' block implementation. + AppliedBuiltinMemberAnnotations hash_id_builtin_ann = TypeObjectUtils::build_applied_builtin_member_annotations( + eprosima::fastcdr::optional(), eprosima::fastcdr::optional(), + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional("member_hash")); + CompleteMemberDetail unit_member = TypeObjectUtils::build_complete_member_detail("member_name", unit_builtin_ann, + eprosima::fastcdr::optional()); + CompleteMemberDetail hash_id_member = TypeObjectUtils::build_complete_member_detail("member_name", + hash_id_builtin_ann, eprosima::fastcdr::optional()); + CommonBitfield common_bitfield = TypeObjectUtils::build_common_bitfield(0, 0, 1, TK_BOOLEAN); + EXPECT_THROW(CompleteBitfield bitfield = TypeObjectUtils::build_complete_bitfield(common_bitfield, unit_member), + InvalidArgumentError); + EXPECT_THROW(CompleteBitfield bitfield = TypeObjectUtils::build_complete_bitfield(common_bitfield, hash_id_member), + InvalidArgumentError); +} + +// Build CompleteBitsetType with non-empty flags +TEST(TypeObjectUtilsTests, build_complete_bitset_type_non_empty_flags) +{ + BitsetTypeFlag empty_flags = 0; + BitsetTypeFlag non_empty_flags = 1; + CommonBitfield common_bitfield = TypeObjectUtils::build_common_bitfield(0, empty_flags, 3, TK_BYTE); + CompleteMemberDetail member_detail = TypeObjectUtils::build_complete_member_detail("bitfield_name", + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional()); + CompleteBitfield bitfield = TypeObjectUtils::build_complete_bitfield(common_bitfield, member_detail); + CompleteBitfieldSeq bitfield_seq; + TypeObjectUtils::add_complete_bitfield(bitfield_seq, bitfield); + CompleteTypeDetail type_detail = TypeObjectUtils::build_complete_type_detail( + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional(), "bitset_type_name"); + CompleteBitsetHeader header = TypeObjectUtils::build_complete_bitset_header(type_detail); + EXPECT_THROW(CompleteBitsetType bitset = TypeObjectUtils::build_complete_bitset_type(non_empty_flags, + header, bitfield_seq), InvalidArgumentError); + EXPECT_NO_THROW(CompleteBitsetType bitset = TypeObjectUtils::build_complete_bitset_type(empty_flags, + header, bitfield_seq)); +} + +// Register alias TypeObject +TEST(TypeObjectUtilsTests, register_alias_type_object) +{ + TypeIdentifier related_type; + related_type._d(TK_CHAR16); + CommonAliasBody common_body = TypeObjectUtils::build_common_alias_body(0, related_type); + CompleteAliasBody body = TypeObjectUtils::build_complete_alias_body(common_body, + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional()); + CompleteTypeDetail empty_type_detail = TypeObjectUtils::build_complete_type_detail( + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional(), "type_name"); + CompleteAliasHeader empty_header = TypeObjectUtils::build_complete_alias_header(empty_type_detail); + CompleteAliasType alias = TypeObjectUtils::build_complete_alias_type(0, empty_header, body); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, + TypeObjectUtils::build_and_register_alias_type_object(alias, "alias")); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, + TypeObjectUtils::build_and_register_alias_type_object(alias, "alias")); + CompleteTypeDetail detail = TypeObjectUtils::build_complete_type_detail( + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional(), + "alias_name"); + CompleteAliasHeader header = TypeObjectUtils::build_complete_alias_header(detail); + CompleteAliasType other_alias = TypeObjectUtils::build_complete_alias_type(0, header, body); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_BAD_PARAMETER, + TypeObjectUtils::build_and_register_alias_type_object(other_alias, + "alias")); + std::string type_name; + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_PRECONDITION_NOT_MET, TypeObjectUtils::build_and_register_alias_type_object( + other_alias, + type_name)); +} + +// Register annotation TypeObject +TEST(TypeObjectUtilsTests, register_annotation_type_object) +{ + CompleteAnnotationHeader header = TypeObjectUtils::build_complete_annotation_header("annotation_name"); + CompleteAnnotationType annotation = TypeObjectUtils::build_complete_annotation_type(0, header, + CompleteAnnotationParameterSeq()); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, TypeObjectUtils::build_and_register_annotation_type_object(annotation, + "annotation")); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, TypeObjectUtils::build_and_register_annotation_type_object(annotation, + "annotation")); + CompleteAnnotationHeader other_header = TypeObjectUtils::build_complete_annotation_header("other_annotation_name"); + CompleteAnnotationType other_annotation = TypeObjectUtils::build_complete_annotation_type(0, other_header, + CompleteAnnotationParameterSeq()); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_BAD_PARAMETER, TypeObjectUtils::build_and_register_annotation_type_object( + other_annotation, "annotation")); + std::string type_name; + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_PRECONDITION_NOT_MET, TypeObjectUtils::build_and_register_annotation_type_object( + other_annotation, + type_name)); +} + +// Register structure TypeObject +TEST(TypeObjectUtilsTests, register_structure_type_object) +{ + StructTypeFlag flags = TypeObjectUtils::build_struct_type_flag( + eprosima::fastdds::dds::xtypes::ExtensibilityKind::APPENDABLE, false, false); + CompleteTypeDetail empty_type_detail = TypeObjectUtils::build_complete_type_detail( + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional(), "type_name"); + CompleteStructHeader header = TypeObjectUtils::build_complete_struct_header(TypeIdentifier(), empty_type_detail); + CompleteStructType structure = TypeObjectUtils::build_complete_struct_type(flags, header, + CompleteStructMemberSeq()); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, TypeObjectUtils::build_and_register_struct_type_object(structure, + "structure")); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, TypeObjectUtils::build_and_register_struct_type_object(structure, + "structure")); + StructTypeFlag other_flags = TypeObjectUtils::build_struct_type_flag( + eprosima::fastdds::dds::xtypes::ExtensibilityKind::FINAL, false, false); + CompleteStructType other_structure = TypeObjectUtils::build_complete_struct_type(other_flags, + header, CompleteStructMemberSeq()); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_BAD_PARAMETER, TypeObjectUtils::build_and_register_struct_type_object( + other_structure, "structure")); + std::string type_name; + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_PRECONDITION_NOT_MET, TypeObjectUtils::build_and_register_struct_type_object( + other_structure, + type_name)); +} + +// Register union TypeObject +TEST(TypeObjectUtilsTests, register_union_type_object) +{ + UnionTypeFlag flags = TypeObjectUtils::build_union_type_flag( + eprosima::fastdds::dds::xtypes::ExtensibilityKind::APPENDABLE, false, false); + UnionDiscriminatorFlag discr_flags = TypeObjectUtils::build_union_discriminator_flag( + eprosima::fastdds::dds::xtypes::TryConstructKind::DISCARD, + false); + TypeIdentifier discriminator_type_id; + discriminator_type_id._d(TK_BYTE); + CommonDiscriminatorMember discr_member = TypeObjectUtils::build_common_discriminator_member(discr_flags, + discriminator_type_id); + CompleteDiscriminatorMember discriminator = TypeObjectUtils::build_complete_discriminator_member(discr_member, + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional()); + UnionMemberFlag member_flags = TypeObjectUtils::build_union_member_flag( + eprosima::fastdds::dds::xtypes::TryConstructKind::DISCARD, false, false); + TypeIdentifier type_id; + type_id._d(TK_FLOAT128); + UnionCaseLabelSeq case_labels; + TypeObjectUtils::add_union_case_label(case_labels, 5); + CommonUnionMember common_member = TypeObjectUtils::build_common_union_member(3, member_flags, type_id, case_labels); + CompleteMemberDetail empty_member_detail = TypeObjectUtils::build_complete_member_detail("member_name", + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional()); + CompleteUnionMember member = TypeObjectUtils::build_complete_union_member(common_member, empty_member_detail); + CompleteUnionMemberSeq member_seq; + TypeObjectUtils::add_complete_union_member(member_seq, member); + CompleteTypeDetail empty_type_detail = TypeObjectUtils::build_complete_type_detail( + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional(), "type_name"); + CompleteUnionHeader header = TypeObjectUtils::build_complete_union_header(empty_type_detail); + CompleteUnionType union_type = TypeObjectUtils::build_complete_union_type(flags, header, + discriminator, member_seq); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, + TypeObjectUtils::build_and_register_union_type_object(union_type, "union")); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, + TypeObjectUtils::build_and_register_union_type_object(union_type, "union")); + UnionTypeFlag other_flags = TypeObjectUtils::build_union_type_flag( + eprosima::fastdds::dds::xtypes::ExtensibilityKind::MUTABLE, false, false); + CompleteUnionType other_union_type = TypeObjectUtils::build_complete_union_type(other_flags, header, + discriminator, member_seq); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_BAD_PARAMETER, TypeObjectUtils::build_and_register_union_type_object( + other_union_type, "union")); + std::string type_name; + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_PRECONDITION_NOT_MET, TypeObjectUtils::build_and_register_union_type_object( + other_union_type, + type_name)); +} + +// Register bitset TypeObject +TEST(TypeObjectUtilsTests, register_bitset_type_object) +{ + CommonBitfield common_bitfield = TypeObjectUtils::build_common_bitfield(0, 0, 3, TK_BYTE); + CompleteMemberDetail empty_member_detail = TypeObjectUtils::build_complete_member_detail("member_name", + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional()); + CompleteBitfield bitfield = TypeObjectUtils::build_complete_bitfield(common_bitfield, empty_member_detail); + CompleteBitfieldSeq bitfield_seq; + TypeObjectUtils::add_complete_bitfield(bitfield_seq, bitfield); + CompleteTypeDetail empty_type_detail = TypeObjectUtils::build_complete_type_detail( + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional(), "type_name"); + CompleteBitsetHeader header = TypeObjectUtils::build_complete_bitset_header(empty_type_detail); + CompleteBitsetType bitset = TypeObjectUtils::build_complete_bitset_type(0, header, bitfield_seq); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, + TypeObjectUtils::build_and_register_bitset_type_object(bitset, "bitset")); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, + TypeObjectUtils::build_and_register_bitset_type_object(bitset, "bitset")); + CompleteTypeDetail detail = TypeObjectUtils::build_complete_type_detail( + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional(), + "bitset"); + CompleteBitsetHeader other_header = TypeObjectUtils::build_complete_bitset_header(detail); + CompleteBitsetType other_bitset = TypeObjectUtils::build_complete_bitset_type(0, other_header, bitfield_seq); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_BAD_PARAMETER, TypeObjectUtils::build_and_register_bitset_type_object( + other_bitset, "bitset")); + std::string type_name; + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_PRECONDITION_NOT_MET, TypeObjectUtils::build_and_register_bitset_type_object( + other_bitset, + type_name)); +} + +// Register sequence TypeObject +TEST(TypeObjectUtilsTests, register_sequence_type_object) +{ + CommonCollectionHeader common_header = TypeObjectUtils::build_common_collection_header(356); + CompleteCollectionHeader header = TypeObjectUtils::build_complete_collection_header(common_header, + eprosima::fastcdr::optional()); + CollectionElementFlag flags = TypeObjectUtils::build_collection_element_flag( + eprosima::fastdds::dds::xtypes::TryConstructKind::USE_DEFAULT, true); + TypeIdentifier type_id; + type_id._d(TK_FLOAT128); + CommonCollectionElement common_element = TypeObjectUtils::build_common_collection_element(flags, type_id); + CompleteCollectionElement element = TypeObjectUtils::build_complete_collection_element(common_element, + CompleteElementDetail()); + CompleteSequenceType sequence = TypeObjectUtils::build_complete_sequence_type(0, header, element); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, + TypeObjectUtils::build_and_register_sequence_type_object(sequence, "sequence")); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, + TypeObjectUtils::build_and_register_sequence_type_object(sequence, "sequence")); + CompleteTypeDetail detail = TypeObjectUtils::build_complete_type_detail( + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional(), + "sequence"); + CompleteCollectionHeader other_header = TypeObjectUtils::build_complete_collection_header(common_header, detail); + CompleteSequenceType other_sequence = TypeObjectUtils::build_complete_sequence_type(0, other_header, element); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_BAD_PARAMETER, TypeObjectUtils::build_and_register_sequence_type_object( + other_sequence, "sequence")); + std::string type_name; + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_PRECONDITION_NOT_MET, TypeObjectUtils::build_and_register_sequence_type_object( + other_sequence, + type_name)); +} + +// Register array TypeObject +TEST(TypeObjectUtilsTests, register_array_type_object) +{ + LBoundSeq array_bounds; + LBound bound = 356; + TypeObjectUtils::add_array_dimension(array_bounds, bound); + CommonArrayHeader common_header = TypeObjectUtils::build_common_array_header(array_bounds); + CompleteTypeDetail empty_type_detail = TypeObjectUtils::build_complete_type_detail( + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional(), "type_name"); + CompleteArrayHeader header = TypeObjectUtils::build_complete_array_header(common_header, empty_type_detail); + CollectionElementFlag flags = TypeObjectUtils::build_collection_element_flag( + eprosima::fastdds::dds::xtypes::TryConstructKind::USE_DEFAULT, true); + TypeIdentifier type_id; + type_id._d(TK_FLOAT128); + CommonCollectionElement common_element = TypeObjectUtils::build_common_collection_element(flags, type_id); + CompleteCollectionElement element = TypeObjectUtils::build_complete_collection_element(common_element, + CompleteElementDetail()); + CompleteArrayType array = TypeObjectUtils::build_complete_array_type(0, header, element); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, + TypeObjectUtils::build_and_register_array_type_object(array, "array")); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, + TypeObjectUtils::build_and_register_array_type_object(array, "array")); + type_id._d(TK_INT16); + CommonCollectionElement other_common_element = TypeObjectUtils::build_common_collection_element(flags, type_id); + CompleteCollectionElement other_element = TypeObjectUtils::build_complete_collection_element(other_common_element, + CompleteElementDetail()); + CompleteArrayType other_array = TypeObjectUtils::build_complete_array_type(0, header, other_element); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_BAD_PARAMETER, + TypeObjectUtils::build_and_register_array_type_object(other_array, + "array")); + std::string type_name; + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_PRECONDITION_NOT_MET, TypeObjectUtils::build_and_register_array_type_object( + other_array, + type_name)); +} + +// Register map TypeObject +TEST(TypeObjectUtilsTests, register_map_type_object) +{ + CommonCollectionHeader common_header = TypeObjectUtils::build_common_collection_header(356); + CompleteCollectionHeader header = TypeObjectUtils::build_complete_collection_header(common_header, + eprosima::fastcdr::optional()); + CollectionElementFlag flags = TypeObjectUtils::build_collection_element_flag( + eprosima::fastdds::dds::xtypes::TryConstructKind::USE_DEFAULT, true); + TypeIdentifier type_id; + type_id._d(TK_INT16); + CommonCollectionElement common_element = TypeObjectUtils::build_common_collection_element(flags, type_id); + CompleteCollectionElement element = TypeObjectUtils::build_complete_collection_element(common_element, + CompleteElementDetail()); + CompleteMapType map = TypeObjectUtils::build_complete_map_type(0, header, element, element); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, TypeObjectUtils::build_and_register_map_type_object(map, "map")); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, TypeObjectUtils::build_and_register_map_type_object(map, "map")); + type_id._d(TK_INT32); + CommonCollectionElement key_element = TypeObjectUtils::build_common_collection_element(flags, type_id); + CompleteCollectionElement key = TypeObjectUtils::build_complete_collection_element(key_element, + CompleteElementDetail()); + CompleteMapType other_map = TypeObjectUtils::build_complete_map_type(0, header, key, element); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_BAD_PARAMETER, + TypeObjectUtils::build_and_register_map_type_object(other_map, + "map")); + std::string type_name; + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_PRECONDITION_NOT_MET, + TypeObjectUtils::build_and_register_map_type_object(other_map, + type_name)); +} + +// Register enumeration TypeObject +TEST(TypeObjectUtilsTests, register_enumerated_type_object) +{ + CommonEnumeratedHeader common_header = TypeObjectUtils::build_common_enumerated_header(32); + CompleteTypeDetail empty_type_detail = TypeObjectUtils::build_complete_type_detail( + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional(), "type_name"); + CompleteEnumeratedHeader header = TypeObjectUtils::build_complete_enumerated_header(common_header, + empty_type_detail); + CommonEnumeratedLiteral common_literal = TypeObjectUtils::build_common_enumerated_literal(1, 0); + CompleteMemberDetail empty_member_detail = TypeObjectUtils::build_complete_member_detail("member_name", + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional()); + CompleteEnumeratedLiteral literal = TypeObjectUtils::build_complete_enumerated_literal(common_literal, + empty_member_detail); + CompleteEnumeratedLiteralSeq literal_seq; + TypeObjectUtils::add_complete_enumerated_literal(literal_seq, literal); + CompleteEnumeratedType enumeration = TypeObjectUtils::build_complete_enumerated_type(0, header, literal_seq); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, + TypeObjectUtils::build_and_register_enumerated_type_object(enumeration, + "enum")); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, + TypeObjectUtils::build_and_register_enumerated_type_object(enumeration, + "enum")); + CompleteTypeDetail detail = TypeObjectUtils::build_complete_type_detail( + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional(), + "enumeration"); + CompleteEnumeratedHeader other_header = TypeObjectUtils::build_complete_enumerated_header(common_header, detail); + CompleteEnumeratedType other_enumeration = TypeObjectUtils::build_complete_enumerated_type(0, other_header, + literal_seq); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_BAD_PARAMETER, + TypeObjectUtils::build_and_register_enumerated_type_object(other_enumeration, + "enum")); + std::string type_name; + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_PRECONDITION_NOT_MET, TypeObjectUtils::build_and_register_enumerated_type_object( + other_enumeration, + type_name)); +} + +// Register bitmask TypeObject +TEST(TypeObjectUtilsTests, register_bitmask_type_object) +{ + CommonEnumeratedHeader common_header = TypeObjectUtils::build_common_enumerated_header(64, true); + CompleteTypeDetail type_detail = TypeObjectUtils::build_complete_type_detail( + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional(), "type_name"); + CompleteBitmaskHeader header = TypeObjectUtils::build_complete_enumerated_header(common_header, type_detail, true); + CompleteMemberDetail empty_member_detail = TypeObjectUtils::build_complete_member_detail("member_name", + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional()); + CompleteBitflag bitflag = TypeObjectUtils::build_complete_bitflag(CommonBitflag(), empty_member_detail); + CompleteBitflagSeq bitflag_seq; + TypeObjectUtils::add_complete_bitflag(bitflag_seq, bitflag); + CompleteBitmaskType bitmask = TypeObjectUtils::build_complete_bitmask_type(0, header, bitflag_seq); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, + TypeObjectUtils::build_and_register_bitmask_type_object(bitmask, "bitmask")); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, + TypeObjectUtils::build_and_register_bitmask_type_object(bitmask, "bitmask")); + CommonBitflag common = TypeObjectUtils::build_common_bitflag(1, 0); + CompleteMemberDetail other_member_detail = TypeObjectUtils::build_complete_member_detail("other_member_name", + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional()); + CompleteBitflag other_bitflag = TypeObjectUtils::build_complete_bitflag(common, other_member_detail); + TypeObjectUtils::add_complete_bitflag(bitflag_seq, other_bitflag); + CompleteBitmaskType other_bitmask = TypeObjectUtils::build_complete_bitmask_type(0, header, bitflag_seq); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_BAD_PARAMETER, + TypeObjectUtils::build_and_register_bitmask_type_object(other_bitmask, + "bitmask")); + std::string type_name; + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_PRECONDITION_NOT_MET, TypeObjectUtils::build_and_register_bitmask_type_object( + other_bitmask, + type_name)); +} + +// This tests only check that Complete TypeObjects sequences are correctly ordered. TypeObjectUtils API only generates +// Complete TypeObjects. Minimal TypeObject sequence order is checked in Fast DDS-Gen. +// Test add element to AppliedAnnotationParameterSeq +TEST(TypeObjectUtilsTests, add_to_applied_annotation_parameter_seq) +{ + NameHash get_dependencies_hash = TypeObjectUtils::name_hash("getDependencies"); // 0x31FBAA_5 + NameHash color_hash = TypeObjectUtils::name_hash("color"); // 0x70DDA5DF + NameHash shapesize_hash = TypeObjectUtils::name_hash("shapesize"); // 0xDA907714 + EXPECT_TRUE(color_hash < shapesize_hash); + AnnotationParameterValue param_value = TypeObjectUtils::build_annotation_parameter_value(true); + AppliedAnnotationParameter get_dependencies_param = TypeObjectUtils::build_applied_annotation_parameter( + get_dependencies_hash, param_value); + AppliedAnnotationParameter color_param = TypeObjectUtils::build_applied_annotation_parameter(color_hash, + param_value); + AppliedAnnotationParameter shapesize_param = TypeObjectUtils::build_applied_annotation_parameter(shapesize_hash, + param_value); + AppliedAnnotationParameterSeq param_seq; + EXPECT_NO_THROW(TypeObjectUtils::add_applied_annotation_parameter(param_seq, shapesize_param)); + EXPECT_THROW(TypeObjectUtils::add_applied_annotation_parameter(param_seq, shapesize_param), InvalidArgumentError); + EXPECT_NO_THROW(TypeObjectUtils::add_applied_annotation_parameter(param_seq, get_dependencies_param)); + EXPECT_THROW(TypeObjectUtils::add_applied_annotation_parameter(param_seq, get_dependencies_param), + InvalidArgumentError); + EXPECT_NO_THROW(TypeObjectUtils::add_applied_annotation_parameter(param_seq, color_param)); + EXPECT_THROW(TypeObjectUtils::add_applied_annotation_parameter(param_seq, color_param), InvalidArgumentError); + EXPECT_EQ(3, param_seq.size()); + EXPECT_EQ(get_dependencies_param, param_seq[0]); + EXPECT_EQ(color_param, param_seq[1]); + EXPECT_EQ(shapesize_param, param_seq[2]); + EXPECT_TRUE(param_seq[0].paramname_hash() < param_seq[1].paramname_hash()); + EXPECT_TRUE(param_seq[1].paramname_hash() < param_seq[2].paramname_hash()); +} + +// Test add element to AppliedAnnotationSeq +TEST(TypeObjectUtilsTests, add_to_applied_annotation_seq) +{ + CompleteAnnotationHeader first_ann = TypeObjectUtils::build_complete_annotation_header("first"); + CompleteAnnotationHeader second_ann = TypeObjectUtils::build_complete_annotation_header("second"); + CompleteAnnotationHeader third_ann = TypeObjectUtils::build_complete_annotation_header("third"); + CompleteAnnotationType first_custom_annotation = TypeObjectUtils::build_complete_annotation_type(0, first_ann, + CompleteAnnotationParameterSeq()); + CompleteAnnotationType second_custom_annotation = TypeObjectUtils::build_complete_annotation_type(0, second_ann, + CompleteAnnotationParameterSeq()); + CompleteAnnotationType third_custom_annotation = TypeObjectUtils::build_complete_annotation_type(0, third_ann, + CompleteAnnotationParameterSeq()); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, TypeObjectUtils::build_and_register_annotation_type_object( + first_custom_annotation, "first_custom")); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, TypeObjectUtils::build_and_register_annotation_type_object( + second_custom_annotation, "second_custom")); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, TypeObjectUtils::build_and_register_annotation_type_object( + third_custom_annotation, "third_custom")); + TypeIdentifierPair first_custom_annotation_ids; + ASSERT_EQ(eprosima::fastdds::dds::RETCODE_OK, + DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers("first_custom", + first_custom_annotation_ids)); + TypeIdentifierPair second_custom_annotation_ids; + ASSERT_EQ(eprosima::fastdds::dds::RETCODE_OK, + DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers("second_custom", + second_custom_annotation_ids)); + TypeIdentifierPair third_custom_annotation_ids; + ASSERT_EQ(eprosima::fastdds::dds::RETCODE_OK, + DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers("third_custom", + third_custom_annotation_ids)); + // Ensure to use Complete TypeIdentifier. The test uses annotations that differs on the name which is not included + // in the Minimal TypeObject. + AppliedAnnotation first_annotation; + AppliedAnnotation second_annotation; + AppliedAnnotation third_annotation; + if (EK_COMPLETE == first_custom_annotation_ids.type_identifier1()._d()) + { + first_annotation = TypeObjectUtils::build_applied_annotation( + first_custom_annotation_ids.type_identifier1(), + eprosima::fastcdr::optional()); + } + else + { + first_annotation = TypeObjectUtils::build_applied_annotation( + first_custom_annotation_ids.type_identifier2(), + eprosima::fastcdr::optional()); + } + if (EK_COMPLETE == second_custom_annotation_ids.type_identifier1()._d()) + { + second_annotation = TypeObjectUtils::build_applied_annotation( + second_custom_annotation_ids.type_identifier1(), + eprosima::fastcdr::optional()); + } + else + { + second_annotation = TypeObjectUtils::build_applied_annotation( + second_custom_annotation_ids.type_identifier2(), + eprosima::fastcdr::optional()); + } + if (EK_COMPLETE == third_custom_annotation_ids.type_identifier1()._d()) + { + third_annotation = TypeObjectUtils::build_applied_annotation( + third_custom_annotation_ids.type_identifier1(), + eprosima::fastcdr::optional()); + } + else + { + third_annotation = TypeObjectUtils::build_applied_annotation( + third_custom_annotation_ids.type_identifier2(), + eprosima::fastcdr::optional()); + } + AppliedAnnotationSeq applied_annotation_seq; + EXPECT_NO_THROW(TypeObjectUtils::add_applied_annotation(applied_annotation_seq, third_annotation)); + EXPECT_THROW(TypeObjectUtils::add_applied_annotation(applied_annotation_seq, third_annotation), + InvalidArgumentError); + EXPECT_NO_THROW(TypeObjectUtils::add_applied_annotation(applied_annotation_seq, first_annotation)); + EXPECT_THROW(TypeObjectUtils::add_applied_annotation(applied_annotation_seq, first_annotation), + InvalidArgumentError); + EXPECT_NO_THROW(TypeObjectUtils::add_applied_annotation(applied_annotation_seq, second_annotation)); + EXPECT_THROW(TypeObjectUtils::add_applied_annotation(applied_annotation_seq, second_annotation), + InvalidArgumentError); + EXPECT_EQ(3, applied_annotation_seq.size()); + // Ordered by Annotation TypeIdentifier + EXPECT_TRUE(applied_annotation_seq[0].annotation_typeid().equivalence_hash() < + applied_annotation_seq[1].annotation_typeid().equivalence_hash()); + EXPECT_TRUE(applied_annotation_seq[1].annotation_typeid().equivalence_hash() < + applied_annotation_seq[2].annotation_typeid().equivalence_hash()); +} + +// Test add element to CompleteStructMemberSeq +TEST(TypeObjectUtilsTests, add_to_complete_struct_member_seq) +{ + StructMemberFlag flags = TypeObjectUtils::build_struct_member_flag( + eprosima::fastdds::dds::xtypes::TryConstructKind::DISCARD, false, false, false, + false); + TypeIdentifier type_id; + type_id._d(TK_INT32); + CommonStructMember first_member = TypeObjectUtils::build_common_struct_member(0, flags, type_id); + CommonStructMember second_member = TypeObjectUtils::build_common_struct_member(1, flags, type_id); + CommonStructMember third_member = TypeObjectUtils::build_common_struct_member(2, flags, type_id); + CompleteMemberDetail first_detail = TypeObjectUtils::build_complete_member_detail("first", + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional()); + CompleteMemberDetail second_detail = TypeObjectUtils::build_complete_member_detail("second", + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional()); + CompleteMemberDetail third_detail = TypeObjectUtils::build_complete_member_detail("third", + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional()); + CompleteStructMember first = TypeObjectUtils::build_complete_struct_member(first_member, first_detail); + CompleteStructMember second = TypeObjectUtils::build_complete_struct_member(second_member, second_detail); + CompleteStructMember third = TypeObjectUtils::build_complete_struct_member(third_member, third_detail); + CompleteStructMember invalid = TypeObjectUtils::build_complete_struct_member(first_member, third_detail); + CompleteStructMemberSeq member_seq; + EXPECT_NO_THROW(TypeObjectUtils::add_complete_struct_member(member_seq, third)); + EXPECT_THROW(TypeObjectUtils::add_complete_struct_member(member_seq, third), InvalidArgumentError); +#if !defined(NDEBUG) + EXPECT_THROW(TypeObjectUtils::add_complete_struct_member(member_seq, invalid), InvalidArgumentError); +#endif // !defined(NDEBUG) + EXPECT_NO_THROW(TypeObjectUtils::add_complete_struct_member(member_seq, first)); + EXPECT_THROW(TypeObjectUtils::add_complete_struct_member(member_seq, first), + InvalidArgumentError); + EXPECT_NO_THROW(TypeObjectUtils::add_complete_struct_member(member_seq, second)); + EXPECT_THROW(TypeObjectUtils::add_complete_struct_member(member_seq, second), InvalidArgumentError); + EXPECT_EQ(3, member_seq.size()); + EXPECT_EQ(first, member_seq[0]); + EXPECT_EQ(second, member_seq[1]); + EXPECT_EQ(third, member_seq[2]); +} + +// Test add element to UnionCaseLabelSeq +TEST(TypeObjectUtilsTests, add_to_union_case_label_seq) +{ + UnionCaseLabelSeq labels; + EXPECT_NO_THROW(TypeObjectUtils::add_union_case_label(labels, 3)); + EXPECT_EQ(1, labels.size()); + EXPECT_NO_THROW(TypeObjectUtils::add_union_case_label(labels, 3)); + EXPECT_EQ(1, labels.size()); + EXPECT_NO_THROW(TypeObjectUtils::add_union_case_label(labels, 1)); + EXPECT_NO_THROW(TypeObjectUtils::add_union_case_label(labels, 2)); + EXPECT_EQ(3, labels.size()); + EXPECT_EQ(1, labels[0]); + EXPECT_EQ(2, labels[1]); + EXPECT_EQ(3, labels[2]); +} + +// Test add element to CompleteUnionMemberSeq +TEST(TypeObjectUtilsTests, add_to_complete_union_member_seq) +{ + UnionMemberFlag flags = TypeObjectUtils::build_union_member_flag( + eprosima::fastdds::dds::xtypes::TryConstructKind::DISCARD, false, false); + TypeIdentifier type_id; + type_id._d(TK_UINT32); + UnionCaseLabelSeq label_1; + UnionCaseLabelSeq label_2; + UnionCaseLabelSeq label_3; + TypeObjectUtils::add_union_case_label(label_1, 1); + TypeObjectUtils::add_union_case_label(label_2, 2); + TypeObjectUtils::add_union_case_label(label_3, 3); + CommonUnionMember member_1 = TypeObjectUtils::build_common_union_member(1, flags, type_id, label_1); + CommonUnionMember member_2 = TypeObjectUtils::build_common_union_member(2, flags, type_id, label_2); + CommonUnionMember member_3 = TypeObjectUtils::build_common_union_member(3, flags, type_id, label_3); + CompleteMemberDetail first_detail = TypeObjectUtils::build_complete_member_detail("first", + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional()); + CompleteMemberDetail second_detail = TypeObjectUtils::build_complete_member_detail("second", + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional()); + CompleteMemberDetail third_detail = TypeObjectUtils::build_complete_member_detail("third", + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional()); + CompleteUnionMember first_member = TypeObjectUtils::build_complete_union_member(member_1, first_detail); + CompleteUnionMember second_member = TypeObjectUtils::build_complete_union_member(member_2, second_detail); + CompleteUnionMember third_member = TypeObjectUtils::build_complete_union_member(member_3, third_detail); + CompleteUnionMemberSeq member_seq; + EXPECT_NO_THROW(TypeObjectUtils::add_complete_union_member(member_seq, third_member)); + EXPECT_THROW(TypeObjectUtils::add_complete_union_member(member_seq, third_member), InvalidArgumentError); + EXPECT_NO_THROW(TypeObjectUtils::add_complete_union_member(member_seq, first_member)); + EXPECT_THROW(TypeObjectUtils::add_complete_union_member(member_seq, first_member), + InvalidArgumentError); + EXPECT_NO_THROW(TypeObjectUtils::add_complete_union_member(member_seq, second_member)); + EXPECT_THROW(TypeObjectUtils::add_complete_union_member(member_seq, second_member), InvalidArgumentError); + EXPECT_EQ(3, member_seq.size()); + EXPECT_EQ(first_member, member_seq[0]); + EXPECT_EQ(second_member, member_seq[1]); + EXPECT_EQ(third_member, member_seq[2]); +} + +// Test add element to CompleteAnnotationParameterSeq +TEST(TypeObjectUtilsTests, add_to_complete_annotation_parameter_seq) +{ + TypeIdentifier type_id; + type_id._d(TK_BOOLEAN); + CommonAnnotationParameter common = TypeObjectUtils::build_common_annotation_parameter(0, type_id); + AnnotationParameterValue default_value = TypeObjectUtils::build_annotation_parameter_value(false); + MemberName first = "first"; + MemberName second = "second"; + MemberName third = "third"; + CompleteAnnotationParameter first_param = TypeObjectUtils::build_complete_annotation_parameter(common, first, + default_value); + CompleteAnnotationParameter second_param = TypeObjectUtils::build_complete_annotation_parameter(common, second, + default_value); + CompleteAnnotationParameter third_param = TypeObjectUtils::build_complete_annotation_parameter(common, third, + default_value); + CompleteAnnotationParameterSeq param_seq; + EXPECT_NO_THROW(TypeObjectUtils::add_complete_annotation_parameter(param_seq, third_param)); + EXPECT_THROW(TypeObjectUtils::add_complete_annotation_parameter(param_seq, third_param), InvalidArgumentError); + EXPECT_NO_THROW(TypeObjectUtils::add_complete_annotation_parameter(param_seq, first_param)); + EXPECT_THROW(TypeObjectUtils::add_complete_annotation_parameter(param_seq, first_param), + InvalidArgumentError); + EXPECT_NO_THROW(TypeObjectUtils::add_complete_annotation_parameter(param_seq, second_param)); + EXPECT_THROW(TypeObjectUtils::add_complete_annotation_parameter(param_seq, second_param), InvalidArgumentError); + EXPECT_EQ(3, param_seq.size()); + EXPECT_EQ(first_param, param_seq[0]); + EXPECT_EQ(second_param, param_seq[1]); + EXPECT_EQ(third_param, param_seq[2]); +} + +// Test add element to CompleteEnumeratedLiteralSeq +TEST(TypeObjectUtils, add_to_complete_enumerated_literal_seq) +{ + EnumeratedLiteralFlag flags = TypeObjectUtils::build_enumerated_literal_flag(false); + CommonEnumeratedLiteral first = TypeObjectUtils::build_common_enumerated_literal(1, flags); + CommonEnumeratedLiteral second = TypeObjectUtils::build_common_enumerated_literal(2, flags); + CommonEnumeratedLiteral third = TypeObjectUtils::build_common_enumerated_literal(3, flags); + CompleteMemberDetail first_detail = TypeObjectUtils::build_complete_member_detail("first", + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional()); + CompleteMemberDetail second_detail = TypeObjectUtils::build_complete_member_detail("second", + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional()); + CompleteMemberDetail third_detail = TypeObjectUtils::build_complete_member_detail("third", + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional()); + CompleteEnumeratedLiteral first_literal = TypeObjectUtils::build_complete_enumerated_literal(first, first_detail); + CompleteEnumeratedLiteral second_literal = + TypeObjectUtils::build_complete_enumerated_literal(second, second_detail); + CompleteEnumeratedLiteral third_literal = TypeObjectUtils::build_complete_enumerated_literal(third, third_detail); + CompleteEnumeratedLiteralSeq literal_seq; + EXPECT_NO_THROW(TypeObjectUtils::add_complete_enumerated_literal(literal_seq, third_literal)); + EXPECT_THROW(TypeObjectUtils::add_complete_enumerated_literal(literal_seq, third_literal), InvalidArgumentError); + EXPECT_NO_THROW(TypeObjectUtils::add_complete_enumerated_literal(literal_seq, first_literal)); + EXPECT_THROW(TypeObjectUtils::add_complete_enumerated_literal(literal_seq, first_literal), + InvalidArgumentError); + EXPECT_NO_THROW(TypeObjectUtils::add_complete_enumerated_literal(literal_seq, second_literal)); + EXPECT_THROW(TypeObjectUtils::add_complete_enumerated_literal(literal_seq, second_literal), InvalidArgumentError); + EXPECT_EQ(3, literal_seq.size()); + EXPECT_EQ(first_literal, literal_seq[0]); + EXPECT_EQ(second_literal, literal_seq[1]); + EXPECT_EQ(third_literal, literal_seq[2]); +} + +// Test add element to CompleteBitflagSeq +TEST(TypeObjectUtilsTests, add_to_complete_bitflag_seq) +{ + CompleteMemberDetail first_detail = TypeObjectUtils::build_complete_member_detail("first", + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional()); + CompleteMemberDetail second_detail = TypeObjectUtils::build_complete_member_detail("second", + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional()); + CompleteMemberDetail third_detail = TypeObjectUtils::build_complete_member_detail("third", + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional()); + CommonBitflag first = TypeObjectUtils::build_common_bitflag(1, 0); + CommonBitflag second = TypeObjectUtils::build_common_bitflag(2, 0); + CommonBitflag third = TypeObjectUtils::build_common_bitflag(3, 0); + CompleteBitflag first_bitflag = TypeObjectUtils::build_complete_bitflag(first, first_detail); + CompleteBitflag second_bitflag = TypeObjectUtils::build_complete_bitflag(second, second_detail); + CompleteBitflag third_bitflag = TypeObjectUtils::build_complete_bitflag(third, third_detail); + CompleteBitflagSeq bitflag_seq; + EXPECT_NO_THROW(TypeObjectUtils::add_complete_bitflag(bitflag_seq, third_bitflag)); + EXPECT_THROW(TypeObjectUtils::add_complete_bitflag(bitflag_seq, third_bitflag), InvalidArgumentError); + EXPECT_NO_THROW(TypeObjectUtils::add_complete_bitflag(bitflag_seq, first_bitflag)); + EXPECT_THROW(TypeObjectUtils::add_complete_bitflag(bitflag_seq, first_bitflag), + InvalidArgumentError); + EXPECT_NO_THROW(TypeObjectUtils::add_complete_bitflag(bitflag_seq, second_bitflag)); + EXPECT_THROW(TypeObjectUtils::add_complete_bitflag(bitflag_seq, second_bitflag), InvalidArgumentError); + EXPECT_EQ(3, bitflag_seq.size()); + EXPECT_EQ(first_bitflag, bitflag_seq[0]); + EXPECT_EQ(second_bitflag, bitflag_seq[1]); + EXPECT_EQ(third_bitflag, bitflag_seq[2]); +} + +// Test add element to CompleteBitfieldSeq +TEST(TypeObjectUtilsTests, add_to_complete_bitfield_seq) +{ + CompleteMemberDetail first_detail = TypeObjectUtils::build_complete_member_detail("first", + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional()); + CompleteMemberDetail second_detail = TypeObjectUtils::build_complete_member_detail("second", + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional()); + CompleteMemberDetail third_detail = TypeObjectUtils::build_complete_member_detail("third", + eprosima::fastcdr::optional(), + eprosima::fastcdr::optional()); + CommonBitfield first = TypeObjectUtils::build_common_bitfield(1, 0, 1, TK_BOOLEAN); + CommonBitfield second = TypeObjectUtils::build_common_bitfield(2, 0, 1, TK_BOOLEAN); + CommonBitfield third = TypeObjectUtils::build_common_bitfield(3, 0, 1, TK_BOOLEAN); + CompleteBitfield first_bitfield = TypeObjectUtils::build_complete_bitfield(first, first_detail); + CompleteBitfield second_bitfield = TypeObjectUtils::build_complete_bitfield(second, second_detail); + CompleteBitfield third_bitfield = TypeObjectUtils::build_complete_bitfield(third, third_detail); + CompleteBitfieldSeq bitfield_seq; + EXPECT_NO_THROW(TypeObjectUtils::add_complete_bitfield(bitfield_seq, third_bitfield)); + EXPECT_THROW(TypeObjectUtils::add_complete_bitfield(bitfield_seq, third_bitfield), InvalidArgumentError); + EXPECT_NO_THROW(TypeObjectUtils::add_complete_bitfield(bitfield_seq, first_bitfield)); + EXPECT_THROW(TypeObjectUtils::add_complete_bitfield(bitfield_seq, first_bitfield), + InvalidArgumentError); + EXPECT_NO_THROW(TypeObjectUtils::add_complete_bitfield(bitfield_seq, second_bitfield)); + EXPECT_THROW(TypeObjectUtils::add_complete_bitfield(bitfield_seq, second_bitfield), InvalidArgumentError); + EXPECT_EQ(3, bitfield_seq.size()); + EXPECT_EQ(first_bitfield, bitfield_seq[0]); + EXPECT_EQ(second_bitfield, bitfield_seq[1]); + EXPECT_EQ(third_bitfield, bitfield_seq[2]); +} + +} // xtypes +} // dds +} // fastdds +} // eprosima + +int main( + int argc, + char** argv) +{ + testing::InitGoogleTest(&argc, argv); + int ret_value = RUN_ALL_TESTS(); + eprosima::fastdds::dds::Log::KillThread(); + return ret_value; +} diff --git a/test/unittest/dynamic_types/CMakeLists.txt b/test/unittest/dynamic_types/CMakeLists.txt deleted file mode 100644 index ce0e8ec043d..00000000000 --- a/test/unittest/dynamic_types/CMakeLists.txt +++ /dev/null @@ -1,202 +0,0 @@ -# Copyright 2020 Proyectos y Sistemas de Mantenimiento SL (eProsima). -# -# Licensed 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 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -if(WIN32) - add_definitions( - -D_WIN32_WINNT=0x0601 - -D_CRT_SECURE_NO_WARNINGS - ) -endif() - -set(DYNAMIC_TYPES_SOURCE - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/AnnotationDescriptor.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/AnnotationParameterValue.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/BuiltinAnnotationsTypeObject.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicData.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicDataFactory.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicDataPtr.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicPubSubType.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicType.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeBuilder.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeBuilderFactory.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeBuilderPtr.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeMember.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypePtr.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/MemberDescriptor.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeDescriptor.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeIdentifier.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeIdentifierTypes.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeNamesGenerator.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeObject.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeObjectFactory.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeObjectHashId.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypesBase.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/FileConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/Log.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/OStreamConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutErrConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/topic/TopicDataType.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/LocatorWithMask.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/Time_t.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/network/utils/netmask_filter.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/network/utils/network.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/transport/network/NetmaskFilterKind.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/transport/network/NetworkInterface.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/transport/network/NetworkInterfaceWithFilter.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/utils/IPFinder.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/utils/IPLocator.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/utils/md5.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/utils/string_convert.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/utils/SystemInfo.cpp - ) - -# External sources -if(TINYXML2_SOURCE_DIR) - list(APPEND DYNAMIC_TYPES_SOURCE - ${TINYXML2_SOURCE_DIR}/tinyxml2.cpp - ) -endif() - -if(ANDROID) - if (ANDROID_NATIVE_API_LEVEL LESS 24) - list(APPEND DYNAMIC_TYPES_SOURCE - ${ANDROID_IFADDRS_SOURCE_DIR}/ifaddrs.c - ) - endif() -endif() - -set(DYNAMIC_TYPES_TEST_SOURCE - DynamicTypesTests.cpp - idl/Basic.cxx - idl/Basicv1.cxx - idl/BasicPubSubTypes.cxx - idl/BasicTypeObject.cxx - ${DYNAMIC_TYPES_SOURCE} - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/publisher/qos/WriterQos.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/subscriber/qos/ReaderQos.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/attributes/ThreadSettings.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/flowcontrol/FlowControllerConsts.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/flowcontrol/ThroughputControllerDescriptor.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/transport/PortBasedTransportDescriptor.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/xmlparser/XMLDynamicParser.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/xmlparser/XMLElementParser.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/xmlparser/XMLParser.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/xmlparser/XMLParserCommon.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/xmlparser/XMLProfileManager.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/utils/UnitsParser.cpp - ) - -set(DYNAMIC_COMPLEX_TYPES_TEST_SOURCE - DynamicComplexTypesTests.cpp - idl/Test.cxx - idl/Testv1.cxx - idl/TestPubSubTypes.cxx - idl/TestTypeObject.cxx - ${DYNAMIC_TYPES_SOURCE} - ) - -set(DYNAMIC_TYPES_4_2_TEST_SOURCE - DynamicTypes_4_2_Tests.cpp - idl/new_features_4_2.cxx - idl/new_features_4_2v1.cxx - idl/new_features_4_2PubSubTypes.cxx - idl/new_features_4_2TypeObject.cxx - ${DYNAMIC_TYPES_SOURCE} - ) - -include_directories(mock/) - -add_executable(DynamicTypesTests ${DYNAMIC_TYPES_TEST_SOURCE}) -target_compile_definitions(DynamicTypesTests PRIVATE - BOOST_ASIO_STANDALONE - ASIO_STANDALONE - $<$>,$>:__DEBUG> - $<$:__INTERNALDEBUG> # Internal debug activated. - ) -target_include_directories(DynamicTypesTests PRIVATE - ${Asio_INCLUDE_DIR} - ${PROJECT_SOURCE_DIR}/test/mock/rtps/SharedMemTransportDescriptor - ${PROJECT_SOURCE_DIR}/test/mock/rtps/TCPTransportDescriptor - ${PROJECT_SOURCE_DIR}/test/mock/rtps/TCPv4TransportDescriptor - ${PROJECT_SOURCE_DIR}/test/mock/rtps/TCPv6TransportDescriptor - ${PROJECT_SOURCE_DIR}/test/mock/rtps/UDPTransportDescriptor - ${PROJECT_SOURCE_DIR}/test/mock/rtps/UDPv4TransportDescriptor - ${PROJECT_SOURCE_DIR}/test/mock/rtps/UDPv6TransportDescriptor - ${PROJECT_SOURCE_DIR}/test/mock/rtps/RTPSParticipantAttributes - $<$:${TINYXML2_INCLUDE_DIR}> - ${PROJECT_SOURCE_DIR}/include ${PROJECT_BINARY_DIR}/include - ${PROJECT_SOURCE_DIR}/src/cpp - $<$:${ANDROID_IFADDRS_INCLUDE_DIR}> - ) -target_link_libraries(DynamicTypesTests GTest::gtest - $<$:iphlpapi$Shlwapi> - $<$:ws2_32> - ${TINYXML2_LIBRARY} - fastcdr - ) -if(QNX) - target_link_libraries(DynamicTypesTests socket) -endif() -gtest_discover_tests(DynamicTypesTests) - - -add_executable(DynamicComplexTypesTests ${DYNAMIC_COMPLEX_TYPES_TEST_SOURCE}) -target_compile_definitions(DynamicComplexTypesTests PRIVATE - BOOST_ASIO_STANDALONE - ASIO_STANDALONE - $<$>,$>:__DEBUG> - $<$:__INTERNALDEBUG> # Internal debug activated. - ) -target_include_directories(DynamicComplexTypesTests PRIVATE - ${Asio_INCLUDE_DIR} - ${PROJECT_SOURCE_DIR}/include ${PROJECT_BINARY_DIR}/include - ${PROJECT_SOURCE_DIR}/src/cpp - $<$:${ANDROID_IFADDRS_INCLUDE_DIR}>) -target_link_libraries(DynamicComplexTypesTests GTest::gtest - $<$:iphlpapi$Shlwapi> - $<$:ws2_32> - ${TINYXML2_LIBRARY} - fastcdr - ) -if(QNX) - target_link_libraries(DynamicComplexTypesTests socket) -endif() -gtest_discover_tests(DynamicComplexTypesTests) - - -add_executable(DynamicTypes_4_2_Tests ${DYNAMIC_TYPES_4_2_TEST_SOURCE}) -target_compile_definitions(DynamicTypes_4_2_Tests PRIVATE - BOOST_ASIO_STANDALONE - ASIO_STANDALONE - $<$>,$>:__DEBUG> - $<$:__INTERNALDEBUG> # Internal debug activated. - ) -target_include_directories(DynamicTypes_4_2_Tests PRIVATE - ${Asio_INCLUDE_DIR} - ${PROJECT_SOURCE_DIR}/include ${PROJECT_BINARY_DIR}/include - ${PROJECT_SOURCE_DIR}/src/cpp) - target_link_libraries(DynamicTypes_4_2_Tests GTest::gtest - $<$:iphlpapi$Shlwapi> - $<$:ws2_32> - ${TINYXML2_LIBRARY} - fastcdr - $<$:${ANDROID_IFADDRS_INCLUDE_DIR}> - ) -if(QNX) - target_link_libraries(DynamicTypes_4_2_Tests socket) -endif() -gtest_discover_tests(DynamicTypes_4_2_Tests) - -configure_file("types_profile.xml" "types_profile.xml" COPYONLY) diff --git a/test/unittest/dynamic_types/DynamicComplexTypesTests.cpp b/test/unittest/dynamic_types/DynamicComplexTypesTests.cpp deleted file mode 100644 index 75930dcc02f..00000000000 --- a/test/unittest/dynamic_types/DynamicComplexTypesTests.cpp +++ /dev/null @@ -1,2322 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -#include - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#include "idl/Test.h" -#include "idl/TestPubSubTypes.h" -#include "idl/TestTypeObject.h" - -using namespace eprosima::fastrtps; -using namespace eprosima::fastrtps::rtps; -using namespace eprosima::fastrtps::types; - -class DynamicComplexTypesTests : public ::testing::Test -{ -public: - - DynamicComplexTypesTests() - { - registerTestTypes(); - m_factory = DynamicTypeBuilderFactory::get_instance(); - init(); - } - - ~DynamicComplexTypesTests() - { - m_DynAutoType = nullptr; - //DynamicDataFactory::get_instance()->delete_data(m_DynAuto); - - m_DynManualType = nullptr; - //DynamicDataFactory::get_instance()->delete_data(m_DynManual); - - if (!DynamicTypeBuilderFactory::get_instance()->is_empty()) - { - EPROSIMA_LOG_ERROR(DYN_TEST, "DynamicTypeBuilderFactory is not empty."); - } - - if (!DynamicDataFactory::get_instance()->is_empty()) - { - EPROSIMA_LOG_ERROR(DYN_TEST, "DynamicDataFactory is not empty."); - } - - DynamicDataFactory::delete_instance(); - DynamicTypeBuilderFactory::delete_instance(); - TypeObjectFactory::delete_instance(); - - eprosima::fastdds::dds::Log::KillThread(); - } - - virtual void TearDown() - { - } - - void init(); - - types::DynamicType_ptr GetMyEnumType(); - types::DynamicType_ptr GetMyAliasEnumType(); - types::DynamicType_ptr GetMyAliasEnum2Type(); - types::DynamicType_ptr GetMyAliasEnum3Type(); - types::DynamicType_ptr GetMyOctetArray500Type(); - types::DynamicType_ptr GetBSAlias5Type(); - types::DynamicType_ptr GetMA3Type(); - types::DynamicType_ptr GetMyMiniArrayType(); - types::DynamicType_ptr GetMySequenceLongType(); - types::DynamicType_ptr GetBasicStructType(); - types::DynamicType_ptr GetComplexStructType(); - types::DynamicType_ptr GetUnionSwitchType(); - types::DynamicType_ptr GetUnion2SwitchType(); - types::DynamicType_ptr GetCompleteStructType(); - types::DynamicType_ptr GetKeyedStructType(); - - // Static types - //CompleteStruct m_Static; - CompleteStructPubSubType m_StaticType; - // Dynamic Types - //DynamicData* m_DynAuto; - types::DynamicType_ptr m_DynAutoType; - //DynamicData* m_DynManual; - types::DynamicType_ptr m_DynManualType; - DynamicTypeBuilderFactory* m_factory; - -private: - - types::DynamicType_ptr m_MyEnumType; - types::DynamicType_ptr m_MyAliasEnumType; - types::DynamicType_ptr m_MyAliasEnum2Type; - types::DynamicType_ptr m_MyAliasEnum3Type; - types::DynamicType_ptr m_MyOctetArray500; - types::DynamicType_ptr m_BSAlias5; - types::DynamicType_ptr m_MA3; - types::DynamicType_ptr m_MyMiniArray; - types::DynamicType_ptr m_MySequenceLong; - types::DynamicType_ptr m_BasicStructType; - types::DynamicType_ptr m_ComplexStructType; - types::DynamicType_ptr m_UnionSwitchType; - types::DynamicType_ptr m_Union2SwitchType; - types::DynamicType_ptr m_CompleteStructType; - types::DynamicType_ptr m_KeyedStructType; -}; - -/* - - struct KeyedStruct - { - @Key octet key; - BasicStruct basic; - }; - */ -types::DynamicType_ptr DynamicComplexTypesTests::GetKeyedStructType() -{ - if (m_KeyedStructType.get() == nullptr) - { - DynamicTypeBuilder_ptr keyedStruct_builder = m_factory->create_struct_builder(); - DynamicTypeBuilder_ptr octet_builder = m_factory->create_byte_builder(); - octet_builder->apply_annotation(ANNOTATION_KEY_ID, "value", "true"); - keyedStruct_builder->add_member(0, "key", octet_builder->build()); - keyedStruct_builder->add_member(1, "basic", GetBasicStructType()); - keyedStruct_builder->apply_annotation(ANNOTATION_KEY_ID, "value", "true"); - keyedStruct_builder->set_name("KeyedStruct"); - m_KeyedStructType = keyedStruct_builder->build(); - } - - return m_KeyedStructType; -} - -types::DynamicType_ptr DynamicComplexTypesTests::GetMyEnumType() -{ - if (m_MyEnumType.get() == nullptr) - { - DynamicTypeBuilder_ptr myEnum_builder = m_factory->create_enum_builder(); - myEnum_builder->set_name("MyEnum"); - myEnum_builder->add_empty_member(0, "A"); - myEnum_builder->add_empty_member(1, "B"); - myEnum_builder->add_empty_member(2, "C"); - m_MyEnumType = myEnum_builder->build(); - } - - return m_MyEnumType; -} - -types::DynamicType_ptr DynamicComplexTypesTests::GetMyAliasEnumType() -{ - if (m_MyAliasEnumType.get() == nullptr) - { - DynamicTypeBuilder_ptr myAliasEnum_builder = m_factory->create_alias_builder(GetMyEnumType(), "MyAliasEnum"); - m_MyAliasEnumType = myAliasEnum_builder->build(); - } - - return m_MyAliasEnumType; -} - -types::DynamicType_ptr DynamicComplexTypesTests::GetMyAliasEnum2Type() -{ - if (m_MyAliasEnum2Type.get() == nullptr) - { - DynamicTypeBuilder_ptr myAliasEnum2_builder = m_factory->create_alias_builder( - GetMyAliasEnumType(), "MyAliasEnum2"); - m_MyAliasEnum2Type = myAliasEnum2_builder->build(); - } - - return m_MyAliasEnum2Type; -} - -types::DynamicType_ptr DynamicComplexTypesTests::GetMyAliasEnum3Type() -{ - if (m_MyAliasEnum3Type.get() == nullptr) - { - DynamicTypeBuilder_ptr myAliasEnum3_builder = m_factory->create_alias_builder( - GetMyAliasEnum2Type(), "MyAliasEnum3"); - m_MyAliasEnum3Type = myAliasEnum3_builder->build(); - } - - return m_MyAliasEnum3Type; -} - -types::DynamicType_ptr DynamicComplexTypesTests::GetMyOctetArray500Type() -{ - if (m_MyOctetArray500.get() == nullptr) - { - DynamicTypeBuilder_ptr octet_builder = m_factory->create_byte_builder(); - DynamicTypeBuilder_ptr myOctetArray500_builder = m_factory->create_array_builder(octet_builder.get(), { 500 }); - myOctetArray500_builder->set_name("MyOctetArray500"); - m_MyOctetArray500 = myOctetArray500_builder->build(); - } - - return m_MyOctetArray500; -} - -types::DynamicType_ptr DynamicComplexTypesTests::GetBSAlias5Type() -{ - if (m_BSAlias5.get() == nullptr) - { - DynamicTypeBuilder_ptr bSAlias5_builder = m_factory->create_array_builder(GetBasicStructType(), { 5 }); - bSAlias5_builder->set_name("BSAlias5"); - m_BSAlias5 = bSAlias5_builder->build(); - } - - return m_BSAlias5; -} - -types::DynamicType_ptr DynamicComplexTypesTests::GetMA3Type() -{ - if (m_MA3.get() == nullptr) - { - DynamicTypeBuilder_ptr mA3_builder = m_factory->create_array_builder(GetMyAliasEnum3Type(), { 42 }); - mA3_builder->set_name("MA3"); - m_MA3 = mA3_builder->build(); - } - - return m_MA3; -} - -types::DynamicType_ptr DynamicComplexTypesTests::GetMyMiniArrayType() -{ - if (m_MyMiniArray.get() == nullptr) - { - DynamicTypeBuilder_ptr int32_builder = m_factory->create_int32_builder(); - DynamicTypeBuilder_ptr myMiniArray_builder = m_factory->create_array_builder(int32_builder.get(), { 2 }); - myMiniArray_builder->set_name("MyMiniArray"); - m_MyMiniArray = myMiniArray_builder->build(); - } - - return m_MyMiniArray; -} - -types::DynamicType_ptr DynamicComplexTypesTests::GetMySequenceLongType() -{ - if (m_MySequenceLong.get() == nullptr) - { - DynamicTypeBuilder_ptr int32_builder = m_factory->create_int32_builder(); - DynamicTypeBuilder_ptr seqLong_builder = m_factory->create_sequence_builder(int32_builder.get()); - DynamicTypeBuilder_ptr mySequenceLong_builder = m_factory->create_alias_builder( - seqLong_builder.get(), "MySequenceLong"); - m_MySequenceLong = mySequenceLong_builder->build(); - } - - return m_MySequenceLong; -} - -types::DynamicType_ptr DynamicComplexTypesTests::GetBasicStructType() -{ - if (m_BasicStructType.get() == nullptr) - { - // Members - DynamicTypeBuilder_ptr bool_builder = m_factory->create_bool_builder(); - DynamicTypeBuilder_ptr octet_builder = m_factory->create_byte_builder(); - DynamicTypeBuilder_ptr int16_builder = m_factory->create_int16_builder(); - DynamicTypeBuilder_ptr int32_builder = m_factory->create_int32_builder(); - DynamicTypeBuilder_ptr int64_builder = m_factory->create_int64_builder(); - DynamicTypeBuilder_ptr uint16_builder = m_factory->create_uint16_builder(); - DynamicTypeBuilder_ptr uint32_builder = m_factory->create_uint32_builder(); - DynamicTypeBuilder_ptr uint64_builder = m_factory->create_uint64_builder(); - DynamicTypeBuilder_ptr float_builder = m_factory->create_float32_builder(); - DynamicTypeBuilder_ptr double_builder = m_factory->create_float64_builder(); - DynamicTypeBuilder_ptr ldouble_builder = m_factory->create_float128_builder(); - DynamicTypeBuilder_ptr char_builder = m_factory->create_char8_builder(); - //DynamicTypeBuilder_ptr wchar_builder = m_factory->create_char16_builder(); - DynamicTypeBuilder_ptr string_builder = m_factory->create_string_builder(); - //DynamicTypeBuilder_ptr wstring_builder = m_factory->create_wstring_builder(); - DynamicTypeBuilder_ptr basicStruct_builder = m_factory->create_struct_builder(); - - // Add members to the struct. - int idx = 0; - basicStruct_builder->add_member(idx++, "my_bool", bool_builder.get()); - basicStruct_builder->add_member(idx++, "my_octet", octet_builder.get()); - basicStruct_builder->add_member(idx++, "my_int16", int16_builder.get()); - basicStruct_builder->add_member(idx++, "my_int32", int32_builder.get()); - basicStruct_builder->add_member(idx++, "my_int64", int64_builder.get()); - basicStruct_builder->add_member(idx++, "my_uint16", uint16_builder.get()); - basicStruct_builder->add_member(idx++, "my_uint32", uint32_builder.get()); - basicStruct_builder->add_member(idx++, "my_uint64", uint64_builder.get()); - basicStruct_builder->add_member(idx++, "my_float32", float_builder.get()); - basicStruct_builder->add_member(idx++, "my_float64", double_builder.get()); - basicStruct_builder->add_member(idx++, "my_float128", ldouble_builder.get()); - basicStruct_builder->add_member(idx++, "my_char", char_builder.get()); - //basicStruct_builder->add_member(idx++, "my_wchar", wchar_builder.get()); - basicStruct_builder->add_member(idx++, "my_string", string_builder.get()); - //basicStruct_builder->add_member(idx++, "my_wstring", wstring_builder.get()); - basicStruct_builder->set_name("BasicStruct"); - - m_BasicStructType = basicStruct_builder->build(); - } - - return m_BasicStructType; -} - -types::DynamicType_ptr DynamicComplexTypesTests::GetComplexStructType() -{ - if (m_ComplexStructType.get() == nullptr) - { - // Members (auxiliar types are tab) - DynamicTypeBuilder_ptr octet_builder = m_factory->create_byte_builder(); - DynamicTypeBuilder_ptr my_sequence_octet_builder = m_factory->create_sequence_builder(octet_builder.get(), 55); - DynamicTypeBuilder_ptr my_sequence_struct_builder = m_factory->create_sequence_builder(GetBasicStructType()); - DynamicTypeBuilder_ptr char_builder = m_factory->create_char8_builder(); - DynamicTypeBuilder_ptr byte_builder = m_factory->create_byte_builder(); - DynamicTypeBuilder_ptr my_array_octet_builder = m_factory->create_array_builder( - byte_builder.get(), { 500, 5, 4 }); - // MyOctetArray500 is already created - // We reuse the bounds... { 5 } - DynamicTypeBuilder_ptr my_array_struct_builder = m_factory->create_array_builder(GetBasicStructType(), { 5 }); - DynamicTypeBuilder_ptr int16_builder = m_factory->create_int16_builder(); - DynamicTypeBuilder_ptr my_map_octet_short_builder = m_factory->create_map_builder( - octet_builder.get(), int16_builder.get()); - DynamicTypeBuilder_ptr int32_builder = m_factory->create_int32_builder(); - DynamicTypeBuilder_ptr my_map_long_struct_builder = m_factory->create_map_builder( - int32_builder.get()->build(), GetBasicStructType()); - DynamicTypeBuilder_ptr seqOctet_builder = m_factory->create_sequence_builder(octet_builder.get()); - DynamicTypeBuilder_ptr seqSeqOctet_builder = m_factory->create_sequence_builder(seqOctet_builder.get()); - DynamicTypeBuilder_ptr my_map_long_seq_octet_builder = m_factory->create_map_builder( - int32_builder.get(), seqSeqOctet_builder.get()); - DynamicTypeBuilder_ptr my_map_long_octet_array_500_builder = m_factory->create_map_builder( - int32_builder.get()->build(), GetMyOctetArray500Type()); - DynamicTypeBuilder_ptr map_octet_bsalias5_builder = m_factory->create_map_builder( - octet_builder.get()->build(), GetBSAlias5Type()); - DynamicTypeBuilder_ptr my_map_long_lol_type_builder = m_factory->create_map_builder( - int32_builder.get(), map_octet_bsalias5_builder.get()); - DynamicTypeBuilder_ptr my_small_string_8_builder = m_factory->create_string_builder(128); - //DynamicTypeBuilder_ptr my_small_string_16_builder = m_factory->create_wstring_builder(64); - DynamicTypeBuilder_ptr my_large_string_8_builder = m_factory->create_string_builder(500); - //DynamicTypeBuilder_ptr my_large_string_16_builder = m_factory->create_wstring_builder(1024); - DynamicTypeBuilder_ptr string75_8_builder = m_factory->create_string_builder(75); - DynamicTypeBuilder_ptr my_array_string_builder = m_factory->create_array_builder( - string75_8_builder.get(), { 5, 5 }); - - // MA3 is already defined. - // { 5 } being reused - DynamicTypeBuilder_ptr my_array_arrays_builder = m_factory->create_array_builder(GetMyMiniArrayType(), { 5 }); - DynamicTypeBuilder_ptr my_sequences_array_builder = m_factory->create_array_builder( - GetMySequenceLongType(), { 23 }); - DynamicTypeBuilder_ptr complexStruct_builder = m_factory->create_struct_builder(); - - // Add members to the struct. - int idx = 0; - complexStruct_builder->add_member(idx++, "my_octet", octet_builder.get()); - complexStruct_builder->add_member(idx++, "my_basic_struct", GetBasicStructType()); - complexStruct_builder->add_member(idx++, "my_alias_enum", GetMyAliasEnumType()); - complexStruct_builder->add_member(idx++, "my_enum", GetMyEnumType()); - complexStruct_builder->add_member(idx++, "my_sequence_octet", my_sequence_octet_builder.get()); - complexStruct_builder->add_member(idx++, "my_sequence_struct", my_sequence_struct_builder.get()); - complexStruct_builder->add_member(idx++, "my_array_octet", my_array_octet_builder.get()); - complexStruct_builder->add_member(idx++, "my_octet_array_500", GetMyOctetArray500Type()); - complexStruct_builder->add_member(idx++, "my_array_struct", my_array_struct_builder.get()); - complexStruct_builder->add_member(idx++, "my_map_octet_short", my_map_octet_short_builder.get()); - complexStruct_builder->add_member(idx++, "my_map_long_struct", my_map_long_struct_builder.get()); - complexStruct_builder->add_member(idx++, "my_map_long_seq_octet", my_map_long_seq_octet_builder.get()); - complexStruct_builder->add_member(idx++, "my_map_long_octet_array_500", - my_map_long_octet_array_500_builder.get()); - complexStruct_builder->add_member(idx++, "my_map_long_lol_type", my_map_long_lol_type_builder.get()); - complexStruct_builder->add_member(idx++, "my_small_string_8", my_small_string_8_builder.get()); - //complexStruct_builder->add_member(idx++, "my_small_string_16", my_small_string_16_builder.get()); - complexStruct_builder->add_member(idx++, "my_large_string_8", my_large_string_8_builder.get()); - //complexStruct_builder->add_member(idx++, "my_large_string_16", my_large_string_16_builder.get()); - complexStruct_builder->add_member(idx++, "my_array_string", my_array_string_builder.get()); - complexStruct_builder->add_member(idx++, "multi_alias_array_42", GetMA3Type()); - complexStruct_builder->add_member(idx++, "my_array_arrays", my_array_arrays_builder.get()); - complexStruct_builder->add_member(idx++, "my_sequences_array", my_sequences_array_builder.get()); - complexStruct_builder->set_name("ComplexStruct"); - m_ComplexStructType = complexStruct_builder->build(); - } - - return m_ComplexStructType; -} - -types::DynamicType_ptr DynamicComplexTypesTests::GetUnionSwitchType() -{ - if (m_UnionSwitchType.get() == nullptr) - { - DynamicTypeBuilder_ptr myUnion_builder = m_factory->create_union_builder(GetMyEnumType()); - myUnion_builder->add_member(0, "basic", GetBasicStructType(), "A", { 0 }, false); - myUnion_builder->add_member(1, "complex", GetComplexStructType(), "B", { 1, 2 }, false); - myUnion_builder->set_name("MyUnion"); - m_UnionSwitchType = myUnion_builder->build(); - } - - return m_UnionSwitchType; -} - -types::DynamicType_ptr DynamicComplexTypesTests::GetUnion2SwitchType() -{ - if (m_Union2SwitchType.get() == nullptr) - { - DynamicTypeBuilder_ptr octet_builder = m_factory->create_byte_builder(); - DynamicTypeBuilder_ptr int32_builder = m_factory->create_int32_builder(); - DynamicTypeBuilder_ptr string_builder = m_factory->create_string_builder(); - DynamicTypeBuilder_ptr myUnion2_builder = m_factory->create_union_builder(octet_builder.get()); - myUnion2_builder->add_member(0, "uno", int32_builder.get(), "0", { 0 }, false); - myUnion2_builder->add_member(1, "imString", string_builder.get(), "1", { 1 }, false); - myUnion2_builder->add_member(2, "tres", int32_builder.get(), "2", { 2 }, false); - myUnion2_builder->set_name("MyUnion2"); - m_Union2SwitchType = myUnion2_builder->build(); - } - - return m_Union2SwitchType; -} - -types::DynamicType_ptr DynamicComplexTypesTests::GetCompleteStructType() -{ - if (m_CompleteStructType.get() == nullptr) - { - DynamicTypeBuilder_ptr completeStruct_builder = m_factory->create_struct_builder(); - // Add members to the struct. - int idx = 0; - completeStruct_builder->add_member(idx++, "my_union", GetUnionSwitchType()); - completeStruct_builder->add_member(idx++, "my_union_2", GetUnion2SwitchType()); - completeStruct_builder->set_name("CompleteStruct"); - m_CompleteStructType = completeStruct_builder->build(); - } - - return m_CompleteStructType; -} - -void DynamicComplexTypesTests::init() -{ - const TypeIdentifier* id = TypeObjectFactory::get_instance()->get_type_identifier("CompleteStruct", true); - const TypeObject* obj = TypeObjectFactory::get_instance()->get_type_object(id); - m_DynAutoType = TypeObjectFactory::get_instance()->build_dynamic_type("CompleteStruct", id, obj); - - m_DynManualType = GetCompleteStructType(); -} - -TEST_F(DynamicComplexTypesTests, Static_Manual_Comparison) -{ - // Serialize <-> Deserialize Test - DynamicPubSubType pubsubType(m_DynManualType); - types::DynamicData_ptr dynData(DynamicDataFactory::get_instance()->create_data(m_DynManualType)); - types::DynamicData_ptr dynData2(DynamicDataFactory::get_instance()->create_data(m_DynManualType)); - ASSERT_TRUE(dynData2->equals(dynData.get())); - - uint32_t payloadSize = static_cast(pubsubType.getSerializedSizeProvider(dynData.get())()); - SerializedPayload_t payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(dynData.get(), &payload)); - - CompleteStruct staticData; - uint32_t payloadSize2 = static_cast(m_StaticType.getSerializedSizeProvider(&staticData)()); - ASSERT_TRUE(payloadSize == payloadSize2); - SerializedPayload_t payload2(payloadSize2); - ASSERT_TRUE(m_StaticType.deserialize(&payload, &staticData)); - ASSERT_TRUE(m_StaticType.serialize(&staticData, &payload2)); - - ASSERT_TRUE(pubsubType.deserialize(&payload2, dynData2.get())); - ASSERT_TRUE(dynData2->equals(dynData.get())); -} - -TEST_F(DynamicComplexTypesTests, Manual_Auto_Comparision) -{ - types::DynamicData* dynAutoData = DynamicDataFactory::get_instance()->create_data(m_DynAutoType); - types::DynamicData* dynManualData = DynamicDataFactory::get_instance()->create_data(m_DynManualType); - - ASSERT_TRUE(dynManualData->equals(dynAutoData)); - - DynamicDataFactory::get_instance()->delete_data(dynAutoData); - DynamicDataFactory::get_instance()->delete_data(dynManualData); -} - -TEST_F(DynamicComplexTypesTests, Static_Auto_Comparision) -{ - // Serialize <-> Deserialize Test - DynamicPubSubType pubsubtype(m_DynAutoType); - types::DynamicData_ptr dynData(DynamicDataFactory::get_instance()->create_data(m_DynAutoType)); - uint32_t payloadSize = static_cast(pubsubtype.getSerializedSizeProvider(dynData.get())()); - SerializedPayload_t payload(payloadSize); - ASSERT_TRUE(pubsubtype.serialize(dynData.get(), &payload)); - ASSERT_TRUE(payloadSize == payload.length); - - CompleteStruct staticData; - ASSERT_TRUE(m_StaticType.deserialize(&payload, &staticData)); - - uint32_t payloadSize2 = static_cast(m_StaticType.getSerializedSizeProvider(&staticData)()); - SerializedPayload_t payload2 = SerializedPayload_t(payloadSize2); - ASSERT_TRUE(m_StaticType.serialize(&staticData, &payload2)); - ASSERT_TRUE(payloadSize2 == payload2.length); - - types::DynamicData_ptr dynData2(DynamicDataFactory::get_instance()->create_data(m_DynAutoType)); - ASSERT_TRUE(pubsubtype.deserialize(&payload2, dynData2.get())); - - ASSERT_TRUE(dynData2->equals(dynData.get())); -} - -TEST_F(DynamicComplexTypesTests, Conversions_Test) -{ - TypeObject newObject; - DynamicTypeBuilderFactory::get_instance()->build_type_object(m_DynManualType, newObject, true); - - const TypeIdentifier* identifier = TypeObjectFactory::get_instance()->get_type_identifier( - m_DynManualType->get_name(), - true); - DynamicType_ptr newAutoType = TypeObjectFactory::get_instance()->build_dynamic_type(m_DynManualType->get_name(), - identifier, &newObject); - types::DynamicData* dynData = DynamicDataFactory::get_instance()->create_data(m_DynManualType); - types::DynamicData* dynData2 = DynamicDataFactory::get_instance()->create_data(newAutoType); - - ASSERT_TRUE(dynData2->equals(dynData)); - - DynamicDataFactory::get_instance()->delete_data(dynData); - DynamicDataFactory::get_instance()->delete_data(dynData2); -} - -TEST_F(DynamicComplexTypesTests, DynamicDiscoveryTest) -{ - TypeObject typeObject1, typeObject2, typeObject3; - DynamicTypeBuilder_ptr type1, type2, type3; - { - type1 = DynamicTypeBuilderFactory::get_instance()->create_uint16_builder(); - //types::DynamicData_ptr data(DynamicDataFactory::get_instance()->create_data(type1)); - DynamicTypeBuilderFactory::get_instance()->build_type_object(type1->get_type_descriptor(), typeObject1); - } - { - type2 = DynamicTypeBuilderFactory::get_instance()->create_int16_builder(); - //types::DynamicData_ptr data2(DynamicDataFactory::get_instance()->create_data(type2)); - DynamicTypeBuilderFactory::get_instance()->build_type_object(type2->get_type_descriptor(), typeObject2); - } - - { - type3 = DynamicTypeBuilderFactory::get_instance()->create_int16_builder(); - //types::DynamicData_ptr data2(DynamicDataFactory::get_instance()->create_data(type3)); - DynamicTypeBuilderFactory::get_instance()->build_type_object(type3->get_type_descriptor(), typeObject3); - } - - const TypeIdentifier* identifier1 = TypeObjectFactory::get_instance()->get_type_identifier(type1->get_name()); - const TypeIdentifier* identifier2 = TypeObjectFactory::get_instance()->get_type_identifier(type2->get_name()); - const TypeIdentifier* identifier3 = TypeObjectFactory::get_instance()->get_type_identifier(type3->get_name()); - ASSERT_FALSE(*identifier1 == *identifier2); - ASSERT_FALSE(*identifier1 == *identifier3); - ASSERT_TRUE(*identifier2 == *identifier3); -} - -TEST_F(DynamicComplexTypesTests, Data_Comparison_A_A) -{ - // Serialize <-> Deserialize Test - DynamicPubSubType pubsubType(m_DynManualType); - types::DynamicData_ptr dynData(DynamicDataFactory::get_instance()->create_data(m_DynManualType)); - types::DynamicData_ptr dynDataFromStatic(DynamicDataFactory::get_instance()->create_data(m_DynAutoType)); - - CompleteStruct staticData; - staticData.my_union()._d(A); - staticData.my_union().basic().my_bool(true); - staticData.my_union().basic().my_octet(166); - staticData.my_union().basic().my_int16(-10401); - staticData.my_union().basic().my_int32(5884001); - staticData.my_union().basic().my_int64(884481567); - staticData.my_union().basic().my_uint16(250); - staticData.my_union().basic().my_uint32(15884); - staticData.my_union().basic().my_uint64(765241); - staticData.my_union().basic().my_float32(158.55f); - staticData.my_union().basic().my_float64(765241.58); - staticData.my_union().basic().my_float128(765241878.154874); - staticData.my_union().basic().my_char('L'); - //staticData.my_union().basic().my_wchar(L'G'); - staticData.my_union().basic().my_string("Luis@eProsima"); - //staticData.my_union().basic().my_wstring(L"LuisGasco@eProsima"); - - //staticData.my_union_2()._d(A); - staticData.my_union_2().uno(156); - - DynamicData* my_union = dynData->loan_value(dynData->get_member_id_by_name("my_union")); - DynamicData* basic = my_union->loan_value(my_union->get_member_id_by_name("basic")); - - basic->set_bool_value(true, basic->get_member_id_by_name("my_bool")); - basic->set_byte_value(166, basic->get_member_id_by_name("my_octet")); - basic->set_int16_value(-10401, basic->get_member_id_by_name("my_int16")); - basic->set_int32_value(5884001, basic->get_member_id_by_name("my_int32")); - basic->set_int64_value(884481567, basic->get_member_id_by_name("my_int64")); - basic->set_uint16_value(250, basic->get_member_id_by_name("my_uint16")); - basic->set_uint32_value(15884, basic->get_member_id_by_name("my_uint32")); - basic->set_uint64_value(765241, basic->get_member_id_by_name("my_uint64")); - basic->set_float32_value(158.55f, basic->get_member_id_by_name("my_float32")); - basic->set_float64_value(765241.58, basic->get_member_id_by_name("my_float64")); - basic->set_float128_value(765241878.154874, basic->get_member_id_by_name("my_float128")); - basic->set_char8_value('L', basic->get_member_id_by_name("my_char")); - //basic->set_char16_value(L'G', basic->get_member_id_by_name("my_wchar")); - basic->set_string_value("Luis@eProsima", basic->get_member_id_by_name("my_string")); - //basic->set_wstring_value(L"LuisGasco@eProsima", basic->get_member_id_by_name("my_wstring")); - - my_union->return_loaned_value(basic); - dynData->return_loaned_value(my_union); - - DynamicData* my_union_2 = dynData->loan_value(dynData->get_member_id_by_name("my_union_2")); - my_union_2->set_int32_value(156, my_union_2->get_member_id_by_name("uno")); - - - dynData->return_loaned_value(my_union_2); - - uint32_t payloadSize = static_cast(pubsubType.getSerializedSizeProvider(dynData.get())()); - SerializedPayload_t payload(payloadSize); - - uint32_t payloadSize2 = static_cast(m_StaticType.getSerializedSizeProvider(&staticData)()); - ASSERT_TRUE(payloadSize == payloadSize2); - - CompleteStructPubSubType pbComplete; - ASSERT_TRUE(pbComplete.serialize(&staticData, &payload)); - ASSERT_TRUE(pubsubType.deserialize(&payload, dynDataFromStatic.get())); - - ASSERT_TRUE(dynDataFromStatic->equals(dynData.get())); -} - -TEST_F(DynamicComplexTypesTests, Data_Comparison_A_B) -{ - // Serialize <-> Deserialize Test - DynamicPubSubType pubsubType(m_DynManualType); - types::DynamicData_ptr dynData(DynamicDataFactory::get_instance()->create_data(m_DynManualType)); - types::DynamicData_ptr dynDataFromStatic(DynamicDataFactory::get_instance()->create_data(m_DynAutoType)); - - CompleteStruct staticData; - staticData.my_union()._d(A); - staticData.my_union().basic().my_bool(true); - staticData.my_union().basic().my_octet(166); - staticData.my_union().basic().my_int16(-10401); - staticData.my_union().basic().my_int32(5884001); - staticData.my_union().basic().my_int64(884481567); - staticData.my_union().basic().my_uint16(250); - staticData.my_union().basic().my_uint32(15884); - staticData.my_union().basic().my_uint64(765241); - staticData.my_union().basic().my_float32(158.55f); - staticData.my_union().basic().my_float64(765241.58); - staticData.my_union().basic().my_float128(765241878.154874); - staticData.my_union().basic().my_char('L'); - //staticData.my_union().basic().my_wchar(L'G'); - staticData.my_union().basic().my_string("Luis@eProsima"); - //staticData.my_union().basic().my_wstring(L"LuisGasco@eProsima"); - - staticData.my_union_2().imString("JuanCarlosArcereredekljnjkds"); - - DynamicData* my_union = dynData->loan_value(dynData->get_member_id_by_name("my_union")); - DynamicData* basic = my_union->loan_value(my_union->get_member_id_by_name("basic")); - - basic->set_bool_value(true, basic->get_member_id_by_name("my_bool")); - basic->set_byte_value(166, basic->get_member_id_by_name("my_octet")); - basic->set_int16_value(-10401, basic->get_member_id_by_name("my_int16")); - basic->set_int32_value(5884001, basic->get_member_id_by_name("my_int32")); - basic->set_int64_value(884481567, basic->get_member_id_by_name("my_int64")); - basic->set_uint16_value(250, basic->get_member_id_by_name("my_uint16")); - basic->set_uint32_value(15884, basic->get_member_id_by_name("my_uint32")); - basic->set_uint64_value(765241, basic->get_member_id_by_name("my_uint64")); - basic->set_float32_value(158.55f, basic->get_member_id_by_name("my_float32")); - basic->set_float64_value(765241.58, basic->get_member_id_by_name("my_float64")); - basic->set_float128_value(765241878.154874, basic->get_member_id_by_name("my_float128")); - basic->set_char8_value('L', basic->get_member_id_by_name("my_char")); - //basic->set_char16_value(L'G', basic->get_member_id_by_name("my_wchar")); - basic->set_string_value("Luis@eProsima", basic->get_member_id_by_name("my_string")); - //basic->set_wstring_value(L"LuisGasco@eProsima", basic->get_member_id_by_name("my_wstring")); - - my_union->return_loaned_value(basic); - dynData->return_loaned_value(my_union); - - DynamicData* my_union_2 = dynData->loan_value(dynData->get_member_id_by_name("my_union_2")); - my_union_2->set_string_value("JuanCarlosArcereredekljnjkds", my_union_2->get_member_id_by_name("imString")); - - - dynData->return_loaned_value(my_union_2); - - uint32_t payloadSize = static_cast(pubsubType.getSerializedSizeProvider(dynData.get())()); - SerializedPayload_t payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(dynData.get(), &payload)); - - uint32_t payloadSize2 = static_cast(m_StaticType.getSerializedSizeProvider(&staticData)()); - ASSERT_TRUE(payloadSize == payloadSize2); - - CompleteStructPubSubType pbComplete; - ASSERT_TRUE(pbComplete.serialize(&staticData, &payload)); - ASSERT_TRUE(pubsubType.deserialize(&payload, dynDataFromStatic.get())); - - ASSERT_TRUE(dynDataFromStatic->equals(dynData.get())); -} - -TEST_F(DynamicComplexTypesTests, Data_Comparison_A_C) -{ - // Serialize <-> Deserialize Test - DynamicPubSubType pubsubType(m_DynManualType); - types::DynamicData_ptr dynData(DynamicDataFactory::get_instance()->create_data(m_DynManualType)); - types::DynamicData_ptr dynDataFromStatic(DynamicDataFactory::get_instance()->create_data(m_DynAutoType)); - - CompleteStruct staticData; - staticData.my_union()._d(A); - staticData.my_union().basic().my_bool(true); - staticData.my_union().basic().my_octet(166); - staticData.my_union().basic().my_int16(-10401); - staticData.my_union().basic().my_int32(5884001); - staticData.my_union().basic().my_int64(884481567); - staticData.my_union().basic().my_uint16(250); - staticData.my_union().basic().my_uint32(15884); - staticData.my_union().basic().my_uint64(765241); - staticData.my_union().basic().my_float32(158.55f); - staticData.my_union().basic().my_float64(765241.58); - staticData.my_union().basic().my_float128(765241878.154874); - staticData.my_union().basic().my_char('L'); - //staticData.my_union().basic().my_wchar(L'G'); - staticData.my_union().basic().my_string("Luis@eProsima"); - //staticData.my_union().basic().my_wstring(L"LuisGasco@eProsima"); - - //staticData.my_union_2()._d(A); - staticData.my_union_2().tres(333); - - DynamicData* my_union = dynData->loan_value(dynData->get_member_id_by_name("my_union")); - DynamicData* basic = my_union->loan_value(my_union->get_member_id_by_name("basic")); - - basic->set_bool_value(true, basic->get_member_id_by_name("my_bool")); - basic->set_byte_value(166, basic->get_member_id_by_name("my_octet")); - basic->set_int16_value(-10401, basic->get_member_id_by_name("my_int16")); - basic->set_int32_value(5884001, basic->get_member_id_by_name("my_int32")); - basic->set_int64_value(884481567, basic->get_member_id_by_name("my_int64")); - basic->set_uint16_value(250, basic->get_member_id_by_name("my_uint16")); - basic->set_uint32_value(15884, basic->get_member_id_by_name("my_uint32")); - basic->set_uint64_value(765241, basic->get_member_id_by_name("my_uint64")); - basic->set_float32_value(158.55f, basic->get_member_id_by_name("my_float32")); - basic->set_float64_value(765241.58, basic->get_member_id_by_name("my_float64")); - basic->set_float128_value(765241878.154874, basic->get_member_id_by_name("my_float128")); - basic->set_char8_value('L', basic->get_member_id_by_name("my_char")); - //basic->set_char16_value(L'G', basic->get_member_id_by_name("my_wchar")); - basic->set_string_value("Luis@eProsima", basic->get_member_id_by_name("my_string")); - //basic->set_wstring_value(L"LuisGasco@eProsima", basic->get_member_id_by_name("my_wstring")); - - my_union->return_loaned_value(basic); - dynData->return_loaned_value(my_union); - - DynamicData* my_union_2 = dynData->loan_value(dynData->get_member_id_by_name("my_union_2")); - my_union_2->set_int32_value(333, my_union_2->get_member_id_by_name("tres")); - - dynData->return_loaned_value(my_union_2); - - uint32_t payloadSize = static_cast(pubsubType.getSerializedSizeProvider(dynData.get())()); - SerializedPayload_t payload(payloadSize); - - uint32_t payloadSize2 = static_cast(m_StaticType.getSerializedSizeProvider(&staticData)()); - ASSERT_TRUE(payloadSize == payloadSize2); - - CompleteStructPubSubType pbComplete; - ASSERT_TRUE(pbComplete.serialize(&staticData, &payload)); - ASSERT_TRUE(pubsubType.deserialize(&payload, dynDataFromStatic.get())); - - ASSERT_TRUE(dynDataFromStatic->equals(dynData.get())); -} - -TEST_F(DynamicComplexTypesTests, Data_Comparison_B_A) -{ - types::DynamicData_ptr dynData(DynamicDataFactory::get_instance()->create_data(m_DynManualType)); - - CompleteStruct staticData; - staticData.my_union()._d() = B; - staticData.my_union().complex().my_octet(66); - staticData.my_union().complex().my_basic_struct().my_bool(true); - staticData.my_union().complex().my_basic_struct().my_octet(166); - staticData.my_union().complex().my_basic_struct().my_int16(-10401); - staticData.my_union().complex().my_basic_struct().my_int32(5884001); - staticData.my_union().complex().my_basic_struct().my_int64(884481567); - staticData.my_union().complex().my_basic_struct().my_uint16(250); - staticData.my_union().complex().my_basic_struct().my_uint32(15884); - staticData.my_union().complex().my_basic_struct().my_uint64(765241); - staticData.my_union().complex().my_basic_struct().my_float32(158.55f); - staticData.my_union().complex().my_basic_struct().my_float64(765241.58); - staticData.my_union().complex().my_basic_struct().my_float128(765241878.154874); - staticData.my_union().complex().my_basic_struct().my_char('L'); - //staticData.my_union().complex().my_basic_struct().my_wchar(L'G'); - staticData.my_union().complex().my_basic_struct().my_string("Luis@eProsima"); - //staticData.my_union().complex().my_basic_struct().my_wstring(L"LuisGasco@eProsima"); - - staticData.my_union().complex().my_alias_enum(C); - staticData.my_union().complex().my_enum(B); - staticData.my_union().complex().my_sequence_octet().push_back(88); - staticData.my_union().complex().my_sequence_octet().push_back(99); - staticData.my_union().complex().my_sequence_struct().push_back(staticData.my_union().complex().my_basic_struct()); - for (int i = 0; i < 500; ++i) - { - for (int j = 0; j < 5; ++j) - { - for (int k = 0; k < 4; ++k) - { - staticData.my_union().complex().my_array_octet()[i][j][k] = static_cast(j * k); - } - } - } - - for (int i = 0; i < 5; ++i) - { - staticData.my_union().complex().my_array_struct()[i].my_bool(i % 2 == 1); - staticData.my_union().complex().my_array_struct()[i].my_octet(static_cast(i)); - staticData.my_union().complex().my_array_struct()[i].my_int16(static_cast(-i)); - staticData.my_union().complex().my_array_struct()[i].my_int32(i); - staticData.my_union().complex().my_array_struct()[i].my_int64(i * 1000); - staticData.my_union().complex().my_array_struct()[i].my_uint16(static_cast(i)); - staticData.my_union().complex().my_array_struct()[i].my_uint32(i); - staticData.my_union().complex().my_array_struct()[i].my_uint64(i * 10005); - staticData.my_union().complex().my_array_struct()[i].my_float32(i * 5.5f); - staticData.my_union().complex().my_array_struct()[i].my_float64(i * 8.8); - staticData.my_union().complex().my_array_struct()[i].my_float128(i * 10.0); - staticData.my_union().complex().my_array_struct()[i].my_char('J'); - //staticData.my_union().complex().my_array_struct()[i].my_wchar(L'C'); - staticData.my_union().complex().my_array_struct()[i].my_string("JC@eProsima"); - //staticData.my_union().complex().my_array_struct()[i].my_wstring(L"JC-BOOM-Armadilo!@eProsima"); - } - - staticData.my_union().complex().my_map_octet_short()[0] = 1340; - staticData.my_union().complex().my_map_octet_short()[1] = 1341; - staticData.my_union().complex().my_map_long_struct()[1000] = staticData.my_union().complex().my_array_struct()[3]; - staticData.my_union().complex().my_map_long_struct()[55] = staticData.my_union().complex().my_basic_struct(); - - staticData.my_union().complex().my_map_long_seq_octet()[55].push_back({1, 2, 3, 4, 5}); - staticData.my_union().complex().my_map_long_seq_octet()[55].push_back({1, 2, 3, 4, 5}); - staticData.my_union().complex().my_map_long_seq_octet()[0].push_back({1, 2, 3, 4, 5}); - for (int i = 0; i < 500; ++i) - { - staticData.my_union().complex().my_map_long_octet_array_500()[0][i] = i % 256; - staticData.my_union().complex().my_map_long_octet_array_500()[10][i] = (i + 55) % 256; - } - - staticData.my_union().complex().my_small_string_8( - "Bv7EMffURwGNqePoujdSfkF9PXN9TH125X5nGpNLfzya53tZtNJdgMROlYdZnTE1SLWzBdIU7ZyjjGvsGHkmuJUROwVPcNa9q5dRUV3KZAKNx1exL7BjhqIgQFconhd"); - //staticData.my_union().complex().my_small_string_16( - // L"AgzñgXsI9pXbWjYLDvvn8JUFWhxZhk9t92rdsTqylvdpqtXA6hy9dHkoBTgmF2c"); - staticData.my_union().complex().my_large_string_8( - "hYE5v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wJ3Qv0WZNcuVLvMMhhg85A3620b84MAIc2UoW9Hl4BIT7pHo41ApF0DxIPJL0QdIdAOjn0JTPZqAhoHVBQoYvivPHftk5Crd1a1J8L7hSs0s4uSQKAMTKDxy3gKLaGAg277h4iEsEZRCI4RPlPTo9nZ48s8OO2KzqrUbMkoPSTgaJEXq8GsozAzh0wtL4P3gPeHO5nQzoytoXAkiXoPph0GaTLiahYQksYeK1eVQADDqZPXC55teXKKdX4aomCufr1ZizgzkGwAmnsFmhmBSF0gvbm56NDaUVT0UqXxKxAfRjkILeWR1mW8jfn6RYJH3IWiHxEfyB23rr78NySfgzIchhrm7jEFtmwPpKPKAwzajLv0HpkrtTr38YwWeT5LzHokFAQEc6l3aWdJWapVyt9wX89dEkmPPG9torCV2ddjyF4jAKsxKvzU4pCxV6B3m16IIdnksemJ0xG8iKh4ZPsX"); - for (int i = 0; i < 5; ++i) - { - for (int j = 0; j < 5; ++j) - { - staticData.my_union().complex().my_array_string()[i][j] = - "Ee4rH8nSX1xnWrlDqDJjKWtWntMia9RrZqZPznr0yIDjeroWxUUzpPVV8UK4qUF4eilYR3Dz42"; - } - } - for (int i = 0; i < 42; ++i) - { - staticData.my_union().complex().multi_alias_array_42()[i] = (MyEnum)(i % 3); - } - - for (int i = 0; i < 5; ++i) - { - for (int j = 0; j < 2; ++j) - { - staticData.my_union().complex().my_array_arrays()[i][j] = i * j; - } - } - - for (int i = 0; i < 23; ++i) - { - staticData.my_union().complex().my_sequences_array()[i].push_back(i); - staticData.my_union().complex().my_sequences_array()[i].push_back(i * 10); - staticData.my_union().complex().my_sequences_array()[i].push_back(i * 100); - } - staticData.my_union_2()._d(A); - staticData.my_union_2().uno(156); - - DynamicData* my_union = dynData->loan_value(dynData->get_member_id_by_name("my_union")); - - DynamicData* complex = my_union->loan_value(my_union->get_member_id_by_name("complex")); - complex->set_byte_value(66, complex->get_member_id_by_name("my_octet")); - - DynamicData* basic = complex->loan_value(complex->get_member_id_by_name("my_basic_struct")); - basic->set_bool_value(true, basic->get_member_id_by_name("my_bool")); - basic->set_byte_value(166, basic->get_member_id_by_name("my_octet")); - basic->set_int16_value(-10401, basic->get_member_id_by_name("my_int16")); - basic->set_int32_value(5884001, basic->get_member_id_by_name("my_int32")); - basic->set_int64_value(884481567, basic->get_member_id_by_name("my_int64")); - basic->set_uint16_value(250, basic->get_member_id_by_name("my_uint16")); - basic->set_uint32_value(15884, basic->get_member_id_by_name("my_uint32")); - basic->set_uint64_value(765241, basic->get_member_id_by_name("my_uint64")); - basic->set_float32_value(158.55f, basic->get_member_id_by_name("my_float32")); - basic->set_float64_value(765241.58, basic->get_member_id_by_name("my_float64")); - basic->set_float128_value(765241878.154874, basic->get_member_id_by_name("my_float128")); - basic->set_char8_value('L', basic->get_member_id_by_name("my_char")); - //basic->set_char16_value(L'G', basic->get_member_id_by_name("my_wchar")); - basic->set_string_value("Luis@eProsima", basic->get_member_id_by_name("my_string")); - //basic->set_wstring_value(L"LuisGasco@eProsima", basic->get_member_id_by_name("my_wstring")); - complex->return_loaned_value(basic); - - complex->set_enum_value("C", complex->get_member_id_by_name("my_alias_enum")); - complex->set_enum_value("B", complex->get_member_id_by_name("my_enum")); - - DynamicData* my_seq_octet = complex->loan_value(complex->get_member_id_by_name("my_sequence_octet")); - MemberId id; - my_seq_octet->insert_sequence_data(id); - my_seq_octet->set_byte_value(88, id); - my_seq_octet->insert_sequence_data(id); - my_seq_octet->set_byte_value(99, id); - //staticData.my_union().complex().my_sequence_octet().push_back(88); - //staticData.my_union().complex().my_sequence_octet().push_back(99); - complex->return_loaned_value(my_seq_octet); - - DynamicData* my_seq_struct = complex->loan_value(complex->get_member_id_by_name("my_sequence_struct")); - my_seq_struct->insert_sequence_data(id); - my_seq_struct->set_complex_value(DynamicDataFactory::get_instance()->create_copy(basic), id); - //staticData.my_union().complex().my_sequence_struct().push_back(staticData.my_union().complex().my_basic_struct()); - complex->return_loaned_value(my_seq_struct); - - DynamicData* my_array_octet = complex->loan_value(complex->get_member_id_by_name("my_array_octet")); - for (unsigned int i = 0; i < 500; ++i) - { - for (unsigned int j = 0; j < 5; ++j) - { - for (unsigned int k = 0; k < 4; ++k) - { - MemberId array_idx = my_array_octet->get_array_index({ i, j, k }); - my_array_octet->set_byte_value(static_cast(j * k), array_idx); - } - } - //staticData.my_union().complex().my_array_octet()[i][j][k] = j*k; - } - complex->return_loaned_value(my_array_octet); - - DynamicData* my_array_struct = complex->loan_value(complex->get_member_id_by_name("my_array_struct")); - for (int i = 0; i < 5; ++i) - { - DynamicData* tempBasic = DynamicDataFactory::get_instance()->create_data(GetBasicStructType()); - tempBasic->set_bool_value(i % 2 == 1, tempBasic->get_member_id_by_name("my_bool")); - tempBasic->set_byte_value(static_cast(i), tempBasic->get_member_id_by_name("my_octet")); - tempBasic->set_int16_value(static_cast(-i), tempBasic->get_member_id_by_name("my_int16")); - tempBasic->set_int32_value(i, tempBasic->get_member_id_by_name("my_int32")); - tempBasic->set_int64_value(i * 1000, tempBasic->get_member_id_by_name("my_int64")); - tempBasic->set_uint16_value(static_cast(i), tempBasic->get_member_id_by_name("my_uint16")); - tempBasic->set_uint32_value(i, tempBasic->get_member_id_by_name("my_uint32")); - tempBasic->set_uint64_value(i * 10005, tempBasic->get_member_id_by_name("my_uint64")); - tempBasic->set_float32_value(i * 5.5f, tempBasic->get_member_id_by_name("my_float32")); - tempBasic->set_float64_value(i * 8.8, tempBasic->get_member_id_by_name("my_float64")); - tempBasic->set_float128_value(i * 10.0, tempBasic->get_member_id_by_name("my_float128")); - tempBasic->set_char8_value('J', tempBasic->get_member_id_by_name("my_char")); - //tempBasic->set_char16_value(L'C', tempBasic->get_member_id_by_name("my_wchar")); - tempBasic->set_string_value("JC@eProsima", tempBasic->get_member_id_by_name("my_string")); - //tempBasic->set_wstring_value(L"JC-BOOM-Armadilo!@eProsima", tempBasic->get_member_id_by_name("my_wstring")); - my_array_struct->set_complex_value(tempBasic, i); - } - complex->return_loaned_value(my_array_struct); - - DynamicTypeBuilder_ptr octet_builder = m_factory->create_byte_builder(); - DynamicData_ptr key_oct(DynamicDataFactory::get_instance()->create_data(octet_builder->build())); - MemberId kId; - MemberId vId; - MemberId ssId; - MemberId sId; - DynamicData* my_map_octet_short = complex->loan_value(complex->get_member_id_by_name("my_map_octet_short")); - key_oct->set_byte_value(0); - my_map_octet_short->insert_map_data(key_oct.get(), kId, vId); - my_map_octet_short->set_int16_value((short)1340, vId); - key_oct = DynamicDataFactory::get_instance()->create_data(octet_builder->build()); - key_oct->set_byte_value(1); - my_map_octet_short->insert_map_data(key_oct.get(), kId, vId); - my_map_octet_short->set_int16_value((short)1341, vId); - //staticData.my_union().complex().my_map_octet_short()[0] = 1340; - //staticData.my_union().complex().my_map_octet_short()[1] = 1341; - complex->return_loaned_value(my_map_octet_short); - - DynamicTypeBuilder_ptr long_builder = m_factory->create_int32_builder(); - DynamicData_ptr key(DynamicDataFactory::get_instance()->create_data(long_builder->build())); - DynamicData* my_map_long_struct = complex->loan_value(complex->get_member_id_by_name("my_map_long_struct")); - - //DynamicData *mas3 = my_array_struct->loan_value(3); - key = DynamicDataFactory::get_instance()->create_data(long_builder->build()); - key->set_int32_value(55); - my_map_long_struct->insert_map_data(key.get(), kId, vId); - basic = my_map_long_struct->loan_value(vId); - basic->set_bool_value(true, basic->get_member_id_by_name("my_bool")); - basic->set_byte_value(166, basic->get_member_id_by_name("my_octet")); - basic->set_int16_value(-10401, basic->get_member_id_by_name("my_int16")); - basic->set_int32_value(5884001, basic->get_member_id_by_name("my_int32")); - basic->set_int64_value(884481567, basic->get_member_id_by_name("my_int64")); - basic->set_uint16_value(250, basic->get_member_id_by_name("my_uint16")); - basic->set_uint32_value(15884, basic->get_member_id_by_name("my_uint32")); - basic->set_uint64_value(765241, basic->get_member_id_by_name("my_uint64")); - basic->set_float32_value(158.55f, basic->get_member_id_by_name("my_float32")); - basic->set_float64_value(765241.58, basic->get_member_id_by_name("my_float64")); - basic->set_float128_value(765241878.154874, basic->get_member_id_by_name("my_float128")); - basic->set_char8_value('L', basic->get_member_id_by_name("my_char")); - //basic->set_char16_value(L'G', basic->get_member_id_by_name("my_wchar")); - basic->set_string_value("Luis@eProsima", basic->get_member_id_by_name("my_string")); - //basic->set_wstring_value(L"LuisGasco@eProsima", basic->get_member_id_by_name("my_wstring")); - my_map_long_struct->return_loaned_value(basic); - key = DynamicDataFactory::get_instance()->create_data(long_builder->build()); - key->set_int32_value(1000); - my_map_long_struct->insert_map_data(key.get(), kId, vId); - DynamicData* mas3 = my_map_long_struct->loan_value(vId); - int i = 3; - mas3->set_bool_value(i % 2 == 1, mas3->get_member_id_by_name("my_bool")); - mas3->set_byte_value(static_cast(i), mas3->get_member_id_by_name("my_octet")); - mas3->set_int16_value(static_cast(-i), mas3->get_member_id_by_name("my_int16")); - mas3->set_int32_value(i, mas3->get_member_id_by_name("my_int32")); - mas3->set_int64_value(i * 1000, mas3->get_member_id_by_name("my_int64")); - mas3->set_uint16_value(static_cast(i), mas3->get_member_id_by_name("my_uint16")); - mas3->set_uint32_value(i, mas3->get_member_id_by_name("my_uint32")); - mas3->set_uint64_value(i * 10005, mas3->get_member_id_by_name("my_uint64")); - mas3->set_float32_value(i * 5.5f, mas3->get_member_id_by_name("my_float32")); - mas3->set_float64_value(i * 8.8, mas3->get_member_id_by_name("my_float64")); - mas3->set_float128_value(i * 10.0, mas3->get_member_id_by_name("my_float128")); - mas3->set_char8_value('J', mas3->get_member_id_by_name("my_char")); - //mas3->set_char16_value(L'C', mas3->get_member_id_by_name("my_wchar")); - mas3->set_string_value("JC@eProsima", mas3->get_member_id_by_name("my_string")); - //mas3->set_wstring_value(L"JC-BOOM-Armadilo!@eProsima", mas3->get_member_id_by_name("my_wstring")); - my_map_long_struct->return_loaned_value(mas3); - - // staticData.my_union().complex().my_map_long_struct()[1000] = staticData.my_union().complex().my_array_struct()[3]; - // staticData.my_union().complex().my_map_long_struct()[55] = staticData.my_union().complex().my_basic_struct(); - complex->return_loaned_value(my_map_long_struct); - - DynamicData* my_map_long_seq_octet = complex->loan_value(complex->get_member_id_by_name("my_map_long_seq_octet")); - //std::vector my_vector_octet = {1, 2, 3, 4, 5}; - //MemberId id; - /*DynamicTypeBuilder_ptr octet_builder = m_factory->create_byte_builder(); - types::DynamicTypeBuilder_ptr seqOctet_builder = m_factory->create_sequence_builder(octet_builder.get()); - types::DynamicType_ptr seqSeqOctet_builder = m_factory->create_sequence_builder(seqOctet_builder.get())->build(); - DynamicData *dataSeqOctet = seqOctet_builder->build(); - DynamicData *dataSeqSeqOctet = seqSeqOctet_builder->build(); - dataSeqOctet->insert_sequence_data(id); - dataSeqOctet->set_byte_value(1, id); - dataSeqOctet->insert_sequence_data(id); - dataSeqOctet->set_byte_value(2, id); - dataSeqOctet->insert_sequence_data(id); - dataSeqOctet->set_byte_value(3, id); - dataSeqOctet->insert_sequence_data(id); - dataSeqOctet->set_byte_value(4, id); - dataSeqOctet->insert_sequence_data(id); - dataSeqOctet->set_byte_value(5, id); - dataSeqSeqOctet->insert_sequence_data(id); - dataSeqSeqOctet->set_complex_value(dataSeqOctet, id);*/ - // insert_map_data(DynamicData_ptr key, MemberId& outKeyId, MemberId& outValueId); - // TODO De la muerte para Juan Carlos - Esto no es NADA práctico... - - key = DynamicDataFactory::get_instance()->create_data(long_builder->build()); - key->set_int32_value(0); - my_map_long_seq_octet->insert_map_data(key.get(), kId, vId); - - DynamicData* seq_seq_oct = my_map_long_seq_octet->loan_value(vId); - seq_seq_oct->insert_sequence_data(ssId); - DynamicData* seq_oct = seq_seq_oct->loan_value(ssId); - seq_oct->insert_sequence_data(sId); - seq_oct->set_byte_value(1, sId); - seq_oct->insert_sequence_data(sId); - seq_oct->set_byte_value(2, sId); - seq_oct->insert_sequence_data(sId); - seq_oct->set_byte_value(3, sId); - seq_oct->insert_sequence_data(sId); - seq_oct->set_byte_value(4, sId); - seq_oct->insert_sequence_data(sId); - seq_oct->set_byte_value(5, sId); - seq_seq_oct->return_loaned_value(seq_oct); - my_map_long_seq_octet->return_loaned_value(seq_seq_oct); - - key = DynamicDataFactory::get_instance()->create_data(long_builder->build()); - key->set_int32_value(55); - my_map_long_seq_octet->insert_map_data(key.get(), kId, vId); - - seq_seq_oct = my_map_long_seq_octet->loan_value(vId); - seq_seq_oct->insert_sequence_data(ssId); - seq_oct = seq_seq_oct->loan_value(ssId); - seq_oct->insert_sequence_data(sId); - seq_oct->set_byte_value(1, sId); - seq_oct->insert_sequence_data(sId); - seq_oct->set_byte_value(2, sId); - seq_oct->insert_sequence_data(sId); - seq_oct->set_byte_value(3, sId); - seq_oct->insert_sequence_data(sId); - seq_oct->set_byte_value(4, sId); - seq_oct->insert_sequence_data(sId); - seq_oct->set_byte_value(5, sId); - seq_seq_oct->return_loaned_value(seq_oct); - seq_seq_oct->insert_sequence_data(ssId); - seq_oct = seq_seq_oct->loan_value(ssId); - seq_oct->insert_sequence_data(sId); - seq_oct->set_byte_value(1, sId); - seq_oct->insert_sequence_data(sId); - seq_oct->set_byte_value(2, sId); - seq_oct->insert_sequence_data(sId); - seq_oct->set_byte_value(3, sId); - seq_oct->insert_sequence_data(sId); - seq_oct->set_byte_value(4, sId); - seq_oct->insert_sequence_data(sId); - seq_oct->set_byte_value(5, sId); - seq_seq_oct->return_loaned_value(seq_oct); - my_map_long_seq_octet->return_loaned_value(seq_seq_oct); - //staticData.my_union().complex().my_map_long_seq_octet()[55].push_back(my_vector_octet); - //staticData.my_union().complex().my_map_long_seq_octet()[55].push_back(my_vector_octet); - //staticData.my_union().complex().my_map_long_seq_octet()[0].push_back(my_vector_octet); - complex->return_loaned_value(my_map_long_seq_octet); - - DynamicData* my_map_long_octet_array_500 = - complex->loan_value(complex->get_member_id_by_name("my_map_long_octet_array_500")); - - key = DynamicDataFactory::get_instance()->create_data(long_builder->build()); - key->set_int32_value(0); - my_map_long_octet_array_500->insert_map_data(key.get(), kId, vId); - - DynamicData* oct_array_500 = my_map_long_octet_array_500->loan_value(vId); - for (int j = 0; j < 500; ++j) - { - oct_array_500->set_byte_value(j % 256, j); - //staticData.my_union().complex().my_map_long_octet_array_500()[0][i] = i%256; - } - my_map_long_octet_array_500->return_loaned_value(oct_array_500); - - key = DynamicDataFactory::get_instance()->create_data(long_builder->build()); - key->set_int32_value(10); - my_map_long_octet_array_500->insert_map_data(key.get(), kId, vId); - oct_array_500 = my_map_long_octet_array_500->loan_value(vId); - - for (int j = 0; j < 500; ++j) - { - oct_array_500->set_byte_value((j + 55) % 256, j); - //staticData.my_union().complex().my_map_long_octet_array_500()[10][i] = (i+55)%256; - } - my_map_long_octet_array_500->return_loaned_value(oct_array_500); - complex->return_loaned_value(my_map_long_octet_array_500); - - complex->set_string_value( - "Bv7EMffURwGNqePoujdSfkF9PXN9TH125X5nGpNLfzya53tZtNJdgMROlYdZnTE1SLWzBdIU7ZyjjGvsGHkmuJUROwVPcNa9q5dRUV3KZAKNx1exL7BjhqIgQFconhd", complex->get_member_id_by_name( - "my_small_string_8")); - //complex->set_wstring_value(L"AgzñgXsI9pXbWjYLDvvn8JUFWhxZhk9t92rdsTqylvdpqtXA6hy9dHkoBTgmF2c", complex->get_member_id_by_name( - // "my_small_string_16")); - complex->set_string_value( - "hYE5vjcLJe6ML5DmoqQwh9ns866dAbnjkVKIKu2VF6lbkvh91ZOG2enEcdoRa8T43hR0Ym0k7tI621EQGufvzmLqxKCPgiXSp2zUTTmIWtn4fM8tC3aP1Yd0dKvn0tDobyp6p3156KvxqG3BKQ6VjFiHlMFoEyz8pjCclhXLl2cfAi97sQzXLUoPYUC5BWKyQTrA2JF6HXZM6vrbw5dc3B4AOJNGdPJ9ai6weF43h1RhnXE9MOFxPNoQnJ8gqSXYbMtpG6ZzqhUyoz0XhFDt7EOqXIgvc9SCejQTVMPeRcF5Zy57hrYZiKrCQqFWidS4BdfEAkuwESgBmEpEFOpZotwDt0TGDaLktSt3dKRsURO6TpuZ2nZNdiEJyc597ZjjQXtyKU7OCyRRqllzAnHEtoU3zd3OLTOvT5uk32N1Y64tpUte63De2EMwDNYb2eGAQfATdSt8VcGBOzJQjsmrMwMumtk48JzXXLxjo6s2vl2rNK9WQM1", complex->get_member_id_by_name( - "my_large_string_8")); - //complex->set_wstring_value( - // L"nosYBfFr1s3t8rUsuUrVCWFi6moDk7GULFj6XnkebIDkjl3n2ykKxUIaLj3qNNUx0ny8DvFbdfxZBdMhBNW3fHbKrig4GkHnN1JoEo0ACiPxrARusDs3xKzvaQQrls6lVUFAUXzDOtw5f2CNVJKiruGjXUO2Lq5Mmy8ygW3eUiTlueAHA2dRXXryOFi47jS3DkmBH4aAOKcmR27KhhJnXaY0gWy3XdSnaGQNB3XvbmxQ7xXDsf1wz860WMEKP3VhdOLsmS6tKCb4sshuOlmUSyTggY7vNoxfpG1EUFP5iPro9E0tHLLdHlWf2NwU8OXCYx6KKEbs5pFMvgEstnQglsdTk0lOv6riaFkFOwx83gW1l6Pg4eXjacnJKoVh1pOeZxULLZpCECw8yRZ9z4JPHxh2C7ytkCHMKp9O4MwQwYvvvgWWLWfJgb7Ecy2tgvWLpNDzgkFrEFhaCTKitChlG422CnLSsXvTBNnF52sULH6rcwOVx3mbhqte3ld3fObtAuH3zPzjOF4vVbvUXxgZh1Zx1cey0iGfnhOZHUfUwJ3Qv0WZNcuVLvMMhhg85A3620b84MAIc2UoW9Hl4BIT7pHo41ApF0DxIPJL0QdIdAOjn0JTPZqAhoHVBQoYvivPHftk5Crd1a1J8L7hSs0s4uSQKAMTKDxy3gKLaGAg277h4iEsEZRCI4RPlPTo9nZ48s8OO2KzqrUbMkoPSTgaJEXq8GsozAzh0wtL4P3gPeHO5nQzoytoXAkiXoPph0GaTLiahYQksYeK1eVQADDqZPXC55teXKKdX4aomCufr1ZizgzkGwAmnsFmhmBSF0gvbm56NDaUVT0UqXxKxAfRjkILeWR1mW8jfn6RYJH3IWiHxEfyB23rr78NySfgzIchhrm7jEFtmwPpKPKAwzajLv0HpkrtTr38YwWeT5LzHokFAQEc6l3aWdJWapVyt9wX89dEkmPPG9torCV2ddjyF4jAKsxKvzU4pCxV6B3m16IIdnksemJ0xG8iKh4ZPsX", complex->get_member_id_by_name( - // "my_large_string_16")); - - DynamicData* my_array_string = complex->loan_value(complex->get_member_id_by_name("my_array_string")); - for (unsigned int j = 0; j < 5; ++j) - { - for (unsigned int k = 0; k < 5; ++k) - { - MemberId array_idx = my_array_string->get_array_index({ j, k }); - my_array_string->set_string_value( - "Ee4rH8nSX1xnWrlDqDJjKWtWntMia9RrZqZPznr0yIDjeroWxUUzpPVV8UK4qUF4eilYR3Dz42", array_idx); - //staticData.my_union().complex().my_array_string()[i][j]("Ee4rH8nSX1xnWrlDqDJjKWtWntMia9RrZqZPznr0yIDjeroWxUUzpPVV8UK4qUF4eilYR3Dz42"); - } - } - complex->return_loaned_value(my_array_string); - - DynamicData* multi_alias_array_42 = complex->loan_value(complex->get_member_id_by_name("multi_alias_array_42")); - for (int j = 0; j < 42; ++j) - { - multi_alias_array_42->set_enum_value(j % 3, j); - //staticData.my_union().complex().multi_alias_array_42()[i](i%3); - } - complex->return_loaned_value(multi_alias_array_42); - - DynamicData* my_array_arrays = complex->loan_value(complex->get_member_id_by_name("my_array_arrays")); - for (unsigned int j = 0; j < 5; ++j) - { - DynamicData* myMiniArray = my_array_arrays->loan_value(j); - for (unsigned int k = 0; k < 2; ++k) - { - myMiniArray->set_int32_value(j * k, k); - //staticData.my_union().complex().my_array_arrays()[i][j](i*j); - } - my_array_arrays->return_loaned_value(myMiniArray); - } - complex->return_loaned_value(my_array_arrays); - - DynamicData* my_sequences_array = complex->loan_value(complex->get_member_id_by_name("my_sequences_array")); - for (int j = 0; j < 23; ++j) - { - DynamicData* seq = DynamicDataFactory::get_instance()->create_data(GetMySequenceLongType()); - seq->insert_sequence_data(id); - seq->set_int32_value(j, id); - seq->insert_sequence_data(id); - seq->set_int32_value(j * 10, id); - seq->insert_sequence_data(id); - seq->set_int32_value(j * 100, id); - my_sequences_array->set_complex_value(seq, j); - // staticData.my_union().complex().my_sequences_array()[i].push_back(i); - // staticData.my_union().complex().my_sequences_array()[i].push_back(i*10); - // staticData.my_union().complex().my_sequences_array()[i].push_back(i*100); - } - complex->return_loaned_value(my_sequences_array); - - my_union->return_loaned_value(complex); - dynData->return_loaned_value(my_union); - - DynamicData* my_union_2 = dynData->loan_value(dynData->get_member_id_by_name("my_union_2")); - my_union_2->set_int32_value(156, my_union_2->get_member_id_by_name("uno")); - - dynData->return_loaned_value(my_union_2); - - // Serialize <-> Deserialize Test - DynamicPubSubType pubsubType(m_DynManualType); - uint32_t payloadSize = static_cast(pubsubType.getSerializedSizeProvider(dynData.get())()); - SerializedPayload_t payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(dynData.get(), &payload)); - ASSERT_TRUE(payload.length == payloadSize); - /* - std::cout << "BEGIN" << std::endl; - for (uint32_t j = 0; j < payload.length; j += 100) - { - std::cout << std::endl; - for (uint32_t k = 0; k < 100; k++) - { - if (j + k < payload.length) - { - if ((int)payload.data[j + k] == 204) - { - std::cout << 0 << " "; - } - else - { - std::cout << (int)payload.data[j + k] << " "; - } - } - } - } - std::cout << "END" << std::endl; - */ - CompleteStructPubSubType pbComplete; - uint32_t payloadSize2 = static_cast(m_StaticType.getSerializedSizeProvider(&staticData)()); - SerializedPayload_t stPayload(payloadSize2); - ASSERT_TRUE(pbComplete.serialize(&staticData, &stPayload)); - ASSERT_TRUE(stPayload.length == payloadSize2); - /* - std::cout << "BEGIN" << std::endl; - for (uint32_t j = 0; j < stPayload.length; j += 100) - { - std::cout << std::endl; - for (uint32_t k = 0; k < 100; k++) - { - if (j + k < stPayload.length) - { - if ((int)stPayload.data[j + k] == 204) - { - std::cout << 0 << " "; - } - else - { - std::cout << (int)stPayload.data[j + k] << " "; - } - } - } - } - std::cout << "END" << std::endl; - */ - types::DynamicData_ptr dynDataFromDynamic(DynamicDataFactory::get_instance()->create_data(m_DynAutoType)); - ASSERT_TRUE(pubsubType.deserialize(&payload, dynDataFromDynamic.get())); - - types::DynamicData_ptr dynDataFromStatic(DynamicDataFactory::get_instance()->create_data(m_DynAutoType)); - ASSERT_TRUE(pubsubType.deserialize(&stPayload, dynDataFromStatic.get())); - - ASSERT_TRUE(dynDataFromStatic->equals(dynDataFromDynamic.get())); -} - -TEST_F(DynamicComplexTypesTests, Data_Comparison_B_B) -{ - types::DynamicData_ptr dynData(DynamicDataFactory::get_instance()->create_data(m_DynManualType)); - - CompleteStruct staticData; - staticData.my_union()._d() = B; - staticData.my_union().complex().my_octet(66); - staticData.my_union().complex().my_basic_struct().my_bool(true); - staticData.my_union().complex().my_basic_struct().my_octet(166); - staticData.my_union().complex().my_basic_struct().my_int16(-10401); - staticData.my_union().complex().my_basic_struct().my_int32(5884001); - staticData.my_union().complex().my_basic_struct().my_int64(884481567); - staticData.my_union().complex().my_basic_struct().my_uint16(250); - staticData.my_union().complex().my_basic_struct().my_uint32(15884); - staticData.my_union().complex().my_basic_struct().my_uint64(765241); - staticData.my_union().complex().my_basic_struct().my_float32(158.55f); - staticData.my_union().complex().my_basic_struct().my_float64(765241.58); - staticData.my_union().complex().my_basic_struct().my_float128(765241878.154874); - staticData.my_union().complex().my_basic_struct().my_char('L'); - //staticData.my_union().complex().my_basic_struct().my_wchar(L'G'); - staticData.my_union().complex().my_basic_struct().my_string("Luis@eProsima"); - //staticData.my_union().complex().my_basic_struct().my_wstring(L"LuisGasco@eProsima"); - - staticData.my_union().complex().my_alias_enum(C); - staticData.my_union().complex().my_enum(B); - staticData.my_union().complex().my_sequence_octet().push_back(88); - staticData.my_union().complex().my_sequence_octet().push_back(99); - staticData.my_union().complex().my_sequence_struct().push_back(staticData.my_union().complex().my_basic_struct()); - for (int i = 0; i < 500; ++i) - { - for (int j = 0; j < 5; ++j) - { - for (int k = 0; k < 4; ++k) - { - staticData.my_union().complex().my_array_octet()[i][j][k] = static_cast(j * k); - } - } - } - - for (int i = 0; i < 5; ++i) - { - staticData.my_union().complex().my_array_struct()[i].my_bool(i % 2 == 1); - staticData.my_union().complex().my_array_struct()[i].my_octet(static_cast(i)); - staticData.my_union().complex().my_array_struct()[i].my_int16(static_cast(-i)); - staticData.my_union().complex().my_array_struct()[i].my_int32(i); - staticData.my_union().complex().my_array_struct()[i].my_int64(i * 1000); - staticData.my_union().complex().my_array_struct()[i].my_uint16(static_cast(i)); - staticData.my_union().complex().my_array_struct()[i].my_uint32(i); - staticData.my_union().complex().my_array_struct()[i].my_uint64(i * 10005); - staticData.my_union().complex().my_array_struct()[i].my_float32(i * 5.5f); - staticData.my_union().complex().my_array_struct()[i].my_float64(i * 8.8); - staticData.my_union().complex().my_array_struct()[i].my_float128(i * 10.0); - staticData.my_union().complex().my_array_struct()[i].my_char('J'); - //staticData.my_union().complex().my_array_struct()[i].my_wchar(L'C'); - staticData.my_union().complex().my_array_struct()[i].my_string("JC@eProsima"); - //staticData.my_union().complex().my_array_struct()[i].my_wstring(L"JC-BOOM-Armadilo!@eProsima"); - } - - staticData.my_union().complex().my_map_octet_short()[0] = 1340; - staticData.my_union().complex().my_map_octet_short()[1] = 1341; - staticData.my_union().complex().my_map_long_struct()[1000] = staticData.my_union().complex().my_array_struct()[3]; - staticData.my_union().complex().my_map_long_struct()[55] = staticData.my_union().complex().my_basic_struct(); - - staticData.my_union().complex().my_map_long_seq_octet()[55].push_back({ 1, 2, 3, 4, 5 }); - staticData.my_union().complex().my_map_long_seq_octet()[55].push_back({ 1, 2, 3, 4, 5 }); - staticData.my_union().complex().my_map_long_seq_octet()[0].push_back({ 1, 2, 3, 4, 5 }); - for (int i = 0; i < 500; ++i) - { - staticData.my_union().complex().my_map_long_octet_array_500()[0][i] = i % 256; - staticData.my_union().complex().my_map_long_octet_array_500()[10][i] = (i + 55) % 256; - } - - staticData.my_union().complex().my_small_string_8( - "Bv7EMffURwGNqePoujdSfkF9PXN9TH125X5nGpNLfzya53tZtNJdgMROlYdZnTE1SLWzBdIU7ZyjjGvsGHkmuJUROwVPcNa9q5dRUV3KZAKNx1exL7BjhqIgQFconhd"); - //staticData.my_union().complex().my_small_string_16( - // L"AgzñgXsI9pXbWjYLDvvn8JUFWhxZhk9t92rdsTqylvdpqtXA6hy9dHkoBTgmF2c"); - staticData.my_union().complex().my_large_string_8( - "hYE5vjcLJe6ML5DmoqQwh9ns866dAbnjkVKIKu2VF6lbkvh91ZOG2enEcdoRa8T43hR0Ym0k7tI621EQGufvzmLqxKCPgiXSp2zUTTmIWtn4fM8tC3aP1Yd0dKvn0tDobyp6p3156KvxqG3BKQ6VjFiHlMFoEyz8pjCclhXLl2cfAi97sQzXLUoPYUC5BWKyQTrA2JF6HXZM6vrbw5dc3B4AOJNGdPJ9ai6weF43h1RhnXE9MOFxPNoQnJ8gqSXYbMtpG6ZzqhUyoz0XhFDt7EOqXIgvc9SCejQTVMPeRcF5Zy57hrYZiKrCQqFWidS4BdfEAkuwESgBmEpEFOpZotwDt0TGDaLktSt3dKRsURO6TpuZ2nZNdiEJyc597ZjjQXtyKU7OCyRRqllzAnHEtoU3zd3OLTOvT5uk32N1Y64tpUte63De2EMwDNYb2eGAQfATdSt8VcGBOzJQjsmrMwMumtk48JzXXLxjo6s2vl2rNK9WQM1"); - //staticData.my_union().complex().my_large_string_16( - // L"nosYBfFr1s3t8rUsuUrVCWFi6moDk7GULFj6XnkebIDkjl3n2ykKxUIaLj3qNNUx0ny8DvFbdfxZBdMhBNW3fHbKrig4GkHnN1JoEo0ACiPxrARusDs3xKzvaQQrls6lVUFAUXzDOtw5f2CNVJKiruGjXUO2Lq5Mmy8ygW3eUiTlueAHA2dRXXryOFi47jS3DkmBH4aAOKcmR27KhhJnXaY0gWy3XdSnaGQNB3XvbmxQ7xXDsf1wz860WMEKP3VhdOLsmS6tKCb4sshuOlmUSyTggY7vNoxfpG1EUFP5iPro9E0tHLLdHlWf2NwU8OXCYx6KKEbs5pFMvgEstnQglsdTk0lOv6riaFkFOwx83gW1l6Pg4eXjacnJKoVh1pOeZxULLZpCECw8yRZ9z4JPHxh2C7ytkCHMKp9O4MwQwYvvvgWWLWfJgb7Ecy2tgvWLpNDzgkFrEFhaCTKitChlG422CnLSsXvTBNnF52sULH6rcwOVx3mbhqte3ld3fObtAuH3zPzjOF4vVbvUXxgZh1Zx1cey0iGfnhOZHUfUwJ3Qv0WZNcuVLvMMhhg85A3620b84MAIc2UoW9Hl4BIT7pHo41ApF0DxIPJL0QdIdAOjn0JTPZqAhoHVBQoYvivPHftk5Crd1a1J8L7hSs0s4uSQKAMTKDxy3gKLaGAg277h4iEsEZRCI4RPlPTo9nZ48s8OO2KzqrUbMkoPSTgaJEXq8GsozAzh0wtL4P3gPeHO5nQzoytoXAkiXoPph0GaTLiahYQksYeK1eVQADDqZPXC55teXKKdX4aomCufr1ZizgzkGwAmnsFmhmBSF0gvbm56NDaUVT0UqXxKxAfRjkILeWR1mW8jfn6RYJH3IWiHxEfyB23rr78NySfgzIchhrm7jEFtmwPpKPKAwzajLv0HpkrtTr38YwWeT5LzHokFAQEc6l3aWdJWapVyt9wX89dEkmPPG9torCV2ddjyF4jAKsxKvzU4pCxV6B3m16IIdnksemJ0xG8iKh4ZPsX"); - for (int i = 0; i < 5; ++i) - { - for (int j = 0; j < 5; ++j) - { - staticData.my_union().complex().my_array_string()[i][j] = - "Ee4rH8nSX1xnWrlDqDJjKWtWntMia9RrZqZPznr0yIDjeroWxUUzpPVV8UK4qUF4eilYR3Dz42"; - } - } - for (int i = 0; i < 42; ++i) - { - staticData.my_union().complex().multi_alias_array_42()[i] = (MyEnum)(i % 3); - } - - for (int i = 0; i < 5; ++i) - { - for (int j = 0; j < 2; ++j) - { - staticData.my_union().complex().my_array_arrays()[i][j] = i * j; - } - } - - for (int i = 0; i < 23; ++i) - { - staticData.my_union().complex().my_sequences_array()[i].push_back(i); - staticData.my_union().complex().my_sequences_array()[i].push_back(i * 10); - staticData.my_union().complex().my_sequences_array()[i].push_back(i * 100); - } - //staticData.my_union_2()._d() = B; - staticData.my_union_2().imString("GASCO!"); - - DynamicData* my_union = dynData->loan_value(dynData->get_member_id_by_name("my_union")); - - DynamicData* complex = my_union->loan_value(my_union->get_member_id_by_name("complex")); - complex->set_byte_value(66, complex->get_member_id_by_name("my_octet")); - - DynamicData* basic = complex->loan_value(complex->get_member_id_by_name("my_basic_struct")); - basic->set_bool_value(true, basic->get_member_id_by_name("my_bool")); - basic->set_byte_value(166, basic->get_member_id_by_name("my_octet")); - basic->set_int16_value(-10401, basic->get_member_id_by_name("my_int16")); - basic->set_int32_value(5884001, basic->get_member_id_by_name("my_int32")); - basic->set_int64_value(884481567, basic->get_member_id_by_name("my_int64")); - basic->set_uint16_value(250, basic->get_member_id_by_name("my_uint16")); - basic->set_uint32_value(15884, basic->get_member_id_by_name("my_uint32")); - basic->set_uint64_value(765241, basic->get_member_id_by_name("my_uint64")); - basic->set_float32_value(158.55f, basic->get_member_id_by_name("my_float32")); - basic->set_float64_value(765241.58, basic->get_member_id_by_name("my_float64")); - basic->set_float128_value(765241878.154874, basic->get_member_id_by_name("my_float128")); - basic->set_char8_value('L', basic->get_member_id_by_name("my_char")); - //basic->set_char16_value(L'G', basic->get_member_id_by_name("my_wchar")); - basic->set_string_value("Luis@eProsima", basic->get_member_id_by_name("my_string")); - //basic->set_wstring_value(L"LuisGasco@eProsima", basic->get_member_id_by_name("my_wstring")); - complex->return_loaned_value(basic); - - complex->set_enum_value("C", complex->get_member_id_by_name("my_alias_enum")); - complex->set_enum_value("B", complex->get_member_id_by_name("my_enum")); - - DynamicData* my_seq_octet = complex->loan_value(complex->get_member_id_by_name("my_sequence_octet")); - MemberId id; - my_seq_octet->insert_sequence_data(id); - my_seq_octet->set_byte_value(88, id); - my_seq_octet->insert_sequence_data(id); - my_seq_octet->set_byte_value(99, id); - //staticData.my_union().complex().my_sequence_octet().push_back(88); - //staticData.my_union().complex().my_sequence_octet().push_back(99); - complex->return_loaned_value(my_seq_octet); - - DynamicData* my_seq_struct = complex->loan_value(complex->get_member_id_by_name("my_sequence_struct")); - my_seq_struct->insert_sequence_data(id); - my_seq_struct->set_complex_value(DynamicDataFactory::get_instance()->create_copy(basic), id); - //staticData.my_union().complex().my_sequence_struct().push_back(staticData.my_union().complex().my_basic_struct()); - complex->return_loaned_value(my_seq_struct); - - DynamicData* my_array_octet = complex->loan_value(complex->get_member_id_by_name("my_array_octet")); - for (unsigned int i = 0; i < 500; ++i) - { - for (unsigned int j = 0; j < 5; ++j) - { - for (unsigned int k = 0; k < 4; ++k) - { - MemberId array_idx = my_array_octet->get_array_index({ i, j, k }); - my_array_octet->set_byte_value(static_cast(j * k), array_idx); - } - } - //staticData.my_union().complex().my_array_octet()[i][j][k] = j*k; - } - complex->return_loaned_value(my_array_octet); - - DynamicData* my_array_struct = complex->loan_value(complex->get_member_id_by_name("my_array_struct")); - for (int i = 0; i < 5; ++i) - { - DynamicData* tempBasic = DynamicDataFactory::get_instance()->create_data(GetBasicStructType()); - tempBasic->set_bool_value(i % 2 == 1, tempBasic->get_member_id_by_name("my_bool")); - tempBasic->set_byte_value(static_cast(i), tempBasic->get_member_id_by_name("my_octet")); - tempBasic->set_int16_value(static_cast(-i), tempBasic->get_member_id_by_name("my_int16")); - tempBasic->set_int32_value(i, tempBasic->get_member_id_by_name("my_int32")); - tempBasic->set_int64_value(i * 1000, tempBasic->get_member_id_by_name("my_int64")); - tempBasic->set_uint16_value(static_cast(i), tempBasic->get_member_id_by_name("my_uint16")); - tempBasic->set_uint32_value(i, tempBasic->get_member_id_by_name("my_uint32")); - tempBasic->set_uint64_value(i * 10005, tempBasic->get_member_id_by_name("my_uint64")); - tempBasic->set_float32_value(i * 5.5f, tempBasic->get_member_id_by_name("my_float32")); - tempBasic->set_float64_value(i * 8.8, tempBasic->get_member_id_by_name("my_float64")); - tempBasic->set_float128_value(i * 10.0, tempBasic->get_member_id_by_name("my_float128")); - tempBasic->set_char8_value('J', tempBasic->get_member_id_by_name("my_char")); - //tempBasic->set_char16_value(L'C', tempBasic->get_member_id_by_name("my_wchar")); - tempBasic->set_string_value("JC@eProsima", tempBasic->get_member_id_by_name("my_string")); - //tempBasic->set_wstring_value(L"JC-BOOM-Armadilo!@eProsima", tempBasic->get_member_id_by_name("my_wstring")); - my_array_struct->set_complex_value(tempBasic, i); - } - complex->return_loaned_value(my_array_struct); - - DynamicTypeBuilder_ptr octet_builder = m_factory->create_byte_builder(); - DynamicData_ptr key_oct(DynamicDataFactory::get_instance()->create_data(octet_builder->build())); - MemberId kId; - MemberId vId; - MemberId ssId; - MemberId sId; - DynamicData* my_map_octet_short = complex->loan_value(complex->get_member_id_by_name("my_map_octet_short")); - key_oct->set_byte_value(0); - my_map_octet_short->insert_map_data(key_oct.get(), kId, vId); - my_map_octet_short->set_int16_value((short)1340, vId); - key_oct = DynamicDataFactory::get_instance()->create_data(octet_builder->build()); - key_oct->set_byte_value(1); - my_map_octet_short->insert_map_data(key_oct.get(), kId, vId); - my_map_octet_short->set_int16_value((short)1341, vId); - //staticData.my_union().complex().my_map_octet_short()[0] = 1340; - //staticData.my_union().complex().my_map_octet_short()[1] = 1341; - complex->return_loaned_value(my_map_octet_short); - - DynamicTypeBuilder_ptr long_builder = m_factory->create_int32_builder(); - DynamicData_ptr key(DynamicDataFactory::get_instance()->create_data(long_builder->build())); - DynamicData* my_map_long_struct = complex->loan_value(complex->get_member_id_by_name("my_map_long_struct")); - - //DynamicData *mas3 = my_array_struct->loan_value(3); - key = DynamicDataFactory::get_instance()->create_data(long_builder->build()); - key->set_int32_value(55); - my_map_long_struct->insert_map_data(key.get(), kId, vId); - basic = my_map_long_struct->loan_value(vId); - basic->set_bool_value(true, basic->get_member_id_by_name("my_bool")); - basic->set_byte_value(166, basic->get_member_id_by_name("my_octet")); - basic->set_int16_value(-10401, basic->get_member_id_by_name("my_int16")); - basic->set_int32_value(5884001, basic->get_member_id_by_name("my_int32")); - basic->set_int64_value(884481567, basic->get_member_id_by_name("my_int64")); - basic->set_uint16_value(250, basic->get_member_id_by_name("my_uint16")); - basic->set_uint32_value(15884, basic->get_member_id_by_name("my_uint32")); - basic->set_uint64_value(765241, basic->get_member_id_by_name("my_uint64")); - basic->set_float32_value(158.55f, basic->get_member_id_by_name("my_float32")); - basic->set_float64_value(765241.58, basic->get_member_id_by_name("my_float64")); - basic->set_float128_value(765241878.154874, basic->get_member_id_by_name("my_float128")); - basic->set_char8_value('L', basic->get_member_id_by_name("my_char")); - //basic->set_char16_value(L'G', basic->get_member_id_by_name("my_wchar")); - basic->set_string_value("Luis@eProsima", basic->get_member_id_by_name("my_string")); - //basic->set_wstring_value(L"LuisGasco@eProsima", basic->get_member_id_by_name("my_wstring")); - my_map_long_struct->return_loaned_value(basic); - key = DynamicDataFactory::get_instance()->create_data(long_builder->build()); - key->set_int32_value(1000); - my_map_long_struct->insert_map_data(key.get(), kId, vId); - DynamicData* mas3 = my_map_long_struct->loan_value(vId); - int i = 3; - mas3->set_bool_value(i % 2 == 1, mas3->get_member_id_by_name("my_bool")); - mas3->set_byte_value(static_cast(i), mas3->get_member_id_by_name("my_octet")); - mas3->set_int16_value(static_cast(-i), mas3->get_member_id_by_name("my_int16")); - mas3->set_int32_value(i, mas3->get_member_id_by_name("my_int32")); - mas3->set_int64_value(i * 1000, mas3->get_member_id_by_name("my_int64")); - mas3->set_uint16_value(static_cast(i), mas3->get_member_id_by_name("my_uint16")); - mas3->set_uint32_value(i, mas3->get_member_id_by_name("my_uint32")); - mas3->set_uint64_value(i * 10005, mas3->get_member_id_by_name("my_uint64")); - mas3->set_float32_value(i * 5.5f, mas3->get_member_id_by_name("my_float32")); - mas3->set_float64_value(i * 8.8, mas3->get_member_id_by_name("my_float64")); - mas3->set_float128_value(i * 10.0, mas3->get_member_id_by_name("my_float128")); - mas3->set_char8_value('J', mas3->get_member_id_by_name("my_char")); - //mas3->set_char16_value(L'C', mas3->get_member_id_by_name("my_wchar")); - mas3->set_string_value("JC@eProsima", mas3->get_member_id_by_name("my_string")); - //mas3->set_wstring_value(L"JC-BOOM-Armadilo!@eProsima", mas3->get_member_id_by_name("my_wstring")); - my_map_long_struct->return_loaned_value(mas3); - - // staticData.my_union().complex().my_map_long_struct()[1000] = staticData.my_union().complex().my_array_struct()[3]; - // staticData.my_union().complex().my_map_long_struct()[55] = staticData.my_union().complex().my_basic_struct(); - complex->return_loaned_value(my_map_long_struct); - - DynamicData* my_map_long_seq_octet = complex->loan_value(complex->get_member_id_by_name("my_map_long_seq_octet")); - //std::vector my_vector_octet = {1, 2, 3, 4, 5}; - //MemberId id; - /*DynamicTypeBuilder_ptr octet_builder = m_factory->create_byte_builder(); - types::DynamicTypeBuilder_ptr seqOctet_builder = m_factory->create_sequence_builder(octet_builder.get()); - types::DynamicType_ptr seqSeqOctet_builder = m_factory->create_sequence_builder(seqOctet_builder.get())->build(); - DynamicData *dataSeqOctet = seqOctet_builder->build(); - DynamicData *dataSeqSeqOctet = seqSeqOctet_builder->build(); - dataSeqOctet->insert_sequence_data(id); - dataSeqOctet->set_byte_value(1, id); - dataSeqOctet->insert_sequence_data(id); - dataSeqOctet->set_byte_value(2, id); - dataSeqOctet->insert_sequence_data(id); - dataSeqOctet->set_byte_value(3, id); - dataSeqOctet->insert_sequence_data(id); - dataSeqOctet->set_byte_value(4, id); - dataSeqOctet->insert_sequence_data(id); - dataSeqOctet->set_byte_value(5, id); - dataSeqSeqOctet->insert_sequence_data(id); - dataSeqSeqOctet->set_complex_value(dataSeqOctet, id);*/ - // insert_map_data(DynamicData_ptr key, MemberId& outKeyId, MemberId& outValueId); - // TODO De la muerte para Juan Carlos - Esto no es NADA práctico... - - key = DynamicDataFactory::get_instance()->create_data(long_builder->build()); - key->set_int32_value(0); - my_map_long_seq_octet->insert_map_data(key.get(), kId, vId); - - DynamicData* seq_seq_oct = my_map_long_seq_octet->loan_value(vId); - seq_seq_oct->insert_sequence_data(ssId); - DynamicData* seq_oct = seq_seq_oct->loan_value(ssId); - seq_oct->insert_sequence_data(sId); - seq_oct->set_byte_value(1, sId); - seq_oct->insert_sequence_data(sId); - seq_oct->set_byte_value(2, sId); - seq_oct->insert_sequence_data(sId); - seq_oct->set_byte_value(3, sId); - seq_oct->insert_sequence_data(sId); - seq_oct->set_byte_value(4, sId); - seq_oct->insert_sequence_data(sId); - seq_oct->set_byte_value(5, sId); - seq_seq_oct->return_loaned_value(seq_oct); - my_map_long_seq_octet->return_loaned_value(seq_seq_oct); - - key = DynamicDataFactory::get_instance()->create_data(long_builder->build()); - key->set_int32_value(55); - my_map_long_seq_octet->insert_map_data(key.get(), kId, vId); - - seq_seq_oct = my_map_long_seq_octet->loan_value(vId); - seq_seq_oct->insert_sequence_data(ssId); - seq_oct = seq_seq_oct->loan_value(ssId); - seq_oct->insert_sequence_data(sId); - seq_oct->set_byte_value(1, sId); - seq_oct->insert_sequence_data(sId); - seq_oct->set_byte_value(2, sId); - seq_oct->insert_sequence_data(sId); - seq_oct->set_byte_value(3, sId); - seq_oct->insert_sequence_data(sId); - seq_oct->set_byte_value(4, sId); - seq_oct->insert_sequence_data(sId); - seq_oct->set_byte_value(5, sId); - seq_seq_oct->return_loaned_value(seq_oct); - seq_seq_oct->insert_sequence_data(ssId); - seq_oct = seq_seq_oct->loan_value(ssId); - seq_oct->insert_sequence_data(sId); - seq_oct->set_byte_value(1, sId); - seq_oct->insert_sequence_data(sId); - seq_oct->set_byte_value(2, sId); - seq_oct->insert_sequence_data(sId); - seq_oct->set_byte_value(3, sId); - seq_oct->insert_sequence_data(sId); - seq_oct->set_byte_value(4, sId); - seq_oct->insert_sequence_data(sId); - seq_oct->set_byte_value(5, sId); - seq_seq_oct->return_loaned_value(seq_oct); - my_map_long_seq_octet->return_loaned_value(seq_seq_oct); - //staticData.my_union().complex().my_map_long_seq_octet()[55].push_back(my_vector_octet); - //staticData.my_union().complex().my_map_long_seq_octet()[55].push_back(my_vector_octet); - //staticData.my_union().complex().my_map_long_seq_octet()[0].push_back(my_vector_octet); - complex->return_loaned_value(my_map_long_seq_octet); - - DynamicData* my_map_long_octet_array_500 = - complex->loan_value(complex->get_member_id_by_name("my_map_long_octet_array_500")); - - key = DynamicDataFactory::get_instance()->create_data(long_builder->build()); - key->set_int32_value(0); - my_map_long_octet_array_500->insert_map_data(key.get(), kId, vId); - - DynamicData* oct_array_500 = my_map_long_octet_array_500->loan_value(vId); - for (int j = 0; j < 500; ++j) - { - oct_array_500->set_byte_value(j % 256, j); - //staticData.my_union().complex().my_map_long_octet_array_500()[0][i] = i%256; - } - my_map_long_octet_array_500->return_loaned_value(oct_array_500); - - key = DynamicDataFactory::get_instance()->create_data(long_builder->build()); - key->set_int32_value(10); - my_map_long_octet_array_500->insert_map_data(key.get(), kId, vId); - oct_array_500 = my_map_long_octet_array_500->loan_value(vId); - - for (int j = 0; j < 500; ++j) - { - oct_array_500->set_byte_value((j + 55) % 256, j); - //staticData.my_union().complex().my_map_long_octet_array_500()[10][i] = (i+55)%256; - } - my_map_long_octet_array_500->return_loaned_value(oct_array_500); - complex->return_loaned_value(my_map_long_octet_array_500); - - complex->set_string_value( - "Bv7EMffURwGNqePoujdSfkF9PXN9TH125X5nGpNLfzya53tZtNJdgMROlYdZnTE1SLWzBdIU7ZyjjGvsGHkmuJUROwVPcNa9q5dRUV3KZAKNx1exL7BjhqIgQFconhd", complex->get_member_id_by_name( - "my_small_string_8")); - //complex->set_wstring_value(L"AgzñgXsI9pXbWjYLDvvn8JUFWhxZhk9t92rdsTqylvdpqtXA6hy9dHkoBTgmF2c", complex->get_member_id_by_name( - // "my_small_string_16")); - complex->set_string_value( - "hYE5vjcLJe6ML5DmoqQwh9ns866dAbnjkVKIKu2VF6lbkvh91ZOG2enEcdoRa8T43hR0Ym0k7tI621EQGufvzmLqxKCPgiXSp2zUTTmIWtn4fM8tC3aP1Yd0dKvn0tDobyp6p3156KvxqG3BKQ6VjFiHlMFoEyz8pjCclhXLl2cfAi97sQzXLUoPYUC5BWKyQTrA2JF6HXZM6vrbw5dc3B4AOJNGdPJ9ai6weF43h1RhnXE9MOFxPNoQnJ8gqSXYbMtpG6ZzqhUyoz0XhFDt7EOqXIgvc9SCejQTVMPeRcF5Zy57hrYZiKrCQqFWidS4BdfEAkuwESgBmEpEFOpZotwDt0TGDaLktSt3dKRsURO6TpuZ2nZNdiEJyc597ZjjQXtyKU7OCyRRqllzAnHEtoU3zd3OLTOvT5uk32N1Y64tpUte63De2EMwDNYb2eGAQfATdSt8VcGBOzJQjsmrMwMumtk48JzXXLxjo6s2vl2rNK9WQM1", complex->get_member_id_by_name( - "my_large_string_8")); - //complex->set_wstring_value( - // L"nosYBfFr1s3t8rUsuUrVCWFi6moDk7GULFj6XnkebIDkjl3n2ykKxUIaLj3qNNUx0ny8DvFbdfxZBdMhBNW3fHbKrig4GkHnN1JoEo0ACiPxrARusDs3xKzvaQQrls6lVUFAUXzDOtw5f2CNVJKiruGjXUO2Lq5Mmy8ygW3eUiTlueAHA2dRXXryOFi47jS3DkmBH4aAOKcmR27KhhJnXaY0gWy3XdSnaGQNB3XvbmxQ7xXDsf1wz860WMEKP3VhdOLsmS6tKCb4sshuOlmUSyTggY7vNoxfpG1EUFP5iPro9E0tHLLdHlWf2NwU8OXCYx6KKEbs5pFMvgEstnQglsdTk0lOv6riaFkFOwx83gW1l6Pg4eXjacnJKoVh1pOeZxULLZpCECw8yRZ9z4JPHxh2C7ytkCHMKp9O4MwQwYvvvgWWLWfJgb7Ecy2tgvWLpNDzgkFrEFhaCTKitChlG422CnLSsXvTBNnF52sULH6rcwOVx3mbhqte3ld3fObtAuH3zPzjOF4vVbvUXxgZh1Zx1cey0iGfnhOZHUfUwJ3Qv0WZNcuVLvMMhhg85A3620b84MAIc2UoW9Hl4BIT7pHo41ApF0DxIPJL0QdIdAOjn0JTPZqAhoHVBQoYvivPHftk5Crd1a1J8L7hSs0s4uSQKAMTKDxy3gKLaGAg277h4iEsEZRCI4RPlPTo9nZ48s8OO2KzqrUbMkoPSTgaJEXq8GsozAzh0wtL4P3gPeHO5nQzoytoXAkiXoPph0GaTLiahYQksYeK1eVQADDqZPXC55teXKKdX4aomCufr1ZizgzkGwAmnsFmhmBSF0gvbm56NDaUVT0UqXxKxAfRjkILeWR1mW8jfn6RYJH3IWiHxEfyB23rr78NySfgzIchhrm7jEFtmwPpKPKAwzajLv0HpkrtTr38YwWeT5LzHokFAQEc6l3aWdJWapVyt9wX89dEkmPPG9torCV2ddjyF4jAKsxKvzU4pCxV6B3m16IIdnksemJ0xG8iKh4ZPsX", complex->get_member_id_by_name( - //"my_large_string_16")); - - DynamicData* my_array_string = complex->loan_value(complex->get_member_id_by_name("my_array_string")); - for (unsigned int j = 0; j < 5; ++j) - { - for (unsigned int k = 0; k < 5; ++k) - { - MemberId array_idx = my_array_string->get_array_index({ j, k }); - my_array_string->set_string_value( - "Ee4rH8nSX1xnWrlDqDJjKWtWntMia9RrZqZPznr0yIDjeroWxUUzpPVV8UK4qUF4eilYR3Dz42", array_idx); - //staticData.my_union().complex().my_array_string()[i][j]("Ee4rH8nSX1xnWrlDqDJjKWtWntMia9RrZqZPznr0yIDjeroWxUUzpPVV8UK4qUF4eilYR3Dz42"); - } - } - complex->return_loaned_value(my_array_string); - - DynamicData* multi_alias_array_42 = complex->loan_value(complex->get_member_id_by_name("multi_alias_array_42")); - for (int j = 0; j < 42; ++j) - { - multi_alias_array_42->set_enum_value(j % 3, j); - //staticData.my_union().complex().multi_alias_array_42()[i](i%3); - } - complex->return_loaned_value(multi_alias_array_42); - - DynamicData* my_array_arrays = complex->loan_value(complex->get_member_id_by_name("my_array_arrays")); - for (unsigned int j = 0; j < 5; ++j) - { - DynamicData* myMiniArray = my_array_arrays->loan_value(j); - for (unsigned int k = 0; k < 2; ++k) - { - myMiniArray->set_int32_value(j * k, k); - //staticData.my_union().complex().my_array_arrays()[i][j](i*j); - } - my_array_arrays->return_loaned_value(myMiniArray); - } - complex->return_loaned_value(my_array_arrays); - - DynamicData* my_sequences_array = complex->loan_value(complex->get_member_id_by_name("my_sequences_array")); - for (int j = 0; j < 23; ++j) - { - DynamicData* seq = DynamicDataFactory::get_instance()->create_data(GetMySequenceLongType()); - seq->insert_sequence_data(id); - seq->set_int32_value(j, id); - seq->insert_sequence_data(id); - seq->set_int32_value(j * 10, id); - seq->insert_sequence_data(id); - seq->set_int32_value(j * 100, id); - my_sequences_array->set_complex_value(seq, j); - // staticData.my_union().complex().my_sequences_array()[i].push_back(i); - // staticData.my_union().complex().my_sequences_array()[i].push_back(i*10); - // staticData.my_union().complex().my_sequences_array()[i].push_back(i*100); - } - complex->return_loaned_value(my_sequences_array); - - my_union->return_loaned_value(complex); - dynData->return_loaned_value(my_union); - - DynamicData* my_union_2 = dynData->loan_value(dynData->get_member_id_by_name("my_union_2")); - my_union_2->set_string_value("GASCO!", my_union_2->get_member_id_by_name("imString")); - - dynData->return_loaned_value(my_union_2); - - // Serialize <-> Deserialize Test - DynamicPubSubType pubsubType(m_DynManualType); - uint32_t payloadSize = static_cast(pubsubType.getSerializedSizeProvider(dynData.get())()); - SerializedPayload_t payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(dynData.get(), &payload)); - ASSERT_TRUE(payload.length == payloadSize); - - CompleteStructPubSubType pbComplete; - uint32_t payloadSize2 = static_cast(m_StaticType.getSerializedSizeProvider(&staticData)()); - SerializedPayload_t stPayload(payloadSize2); - ASSERT_TRUE(pbComplete.serialize(&staticData, &stPayload)); - ASSERT_TRUE(stPayload.length == payloadSize2); - - types::DynamicData_ptr dynDataFromDynamic(DynamicDataFactory::get_instance()->create_data(m_DynAutoType)); - ASSERT_TRUE(pubsubType.deserialize(&payload, dynDataFromDynamic.get())); - - types::DynamicData_ptr dynDataFromStatic(DynamicDataFactory::get_instance()->create_data(m_DynAutoType)); - ASSERT_TRUE(pubsubType.deserialize(&stPayload, dynDataFromStatic.get())); - - ASSERT_TRUE(dynDataFromStatic->equals(dynDataFromDynamic.get())); -} - -TEST_F(DynamicComplexTypesTests, Data_Comparison_B_C) -{ - types::DynamicData_ptr dynData(DynamicDataFactory::get_instance()->create_data(m_DynManualType)); - - CompleteStruct staticData; - staticData.my_union()._d() = B; - staticData.my_union().complex().my_octet(66); - staticData.my_union().complex().my_basic_struct().my_bool(true); - staticData.my_union().complex().my_basic_struct().my_octet(166); - staticData.my_union().complex().my_basic_struct().my_int16(-10401); - staticData.my_union().complex().my_basic_struct().my_int32(5884001); - staticData.my_union().complex().my_basic_struct().my_int64(884481567); - staticData.my_union().complex().my_basic_struct().my_uint16(250); - staticData.my_union().complex().my_basic_struct().my_uint32(15884); - staticData.my_union().complex().my_basic_struct().my_uint64(765241); - staticData.my_union().complex().my_basic_struct().my_float32(158.55f); - staticData.my_union().complex().my_basic_struct().my_float64(765241.58); - staticData.my_union().complex().my_basic_struct().my_float128(765241878.154874); - staticData.my_union().complex().my_basic_struct().my_char('L'); - //staticData.my_union().complex().my_basic_struct().my_wchar(L'G'); - staticData.my_union().complex().my_basic_struct().my_string("Luis@eProsima"); - //staticData.my_union().complex().my_basic_struct().my_wstring(L"LuisGasco@eProsima"); - - staticData.my_union().complex().my_alias_enum(C); - staticData.my_union().complex().my_enum(B); - staticData.my_union().complex().my_sequence_octet().push_back(88); - staticData.my_union().complex().my_sequence_octet().push_back(99); - staticData.my_union().complex().my_sequence_struct().push_back(staticData.my_union().complex().my_basic_struct()); - for (int i = 0; i < 500; ++i) - { - for (int j = 0; j < 5; ++j) - { - for (int k = 0; k < 4; ++k) - { - staticData.my_union().complex().my_array_octet()[i][j][k] = static_cast(j * k); - } - } - } - - for (int i = 0; i < 5; ++i) - { - staticData.my_union().complex().my_array_struct()[i].my_bool(i % 2 == 1); - staticData.my_union().complex().my_array_struct()[i].my_octet(static_cast(i)); - staticData.my_union().complex().my_array_struct()[i].my_int16(static_cast(-i)); - staticData.my_union().complex().my_array_struct()[i].my_int32(i); - staticData.my_union().complex().my_array_struct()[i].my_int64(i * 1000); - staticData.my_union().complex().my_array_struct()[i].my_uint16(static_cast(i)); - staticData.my_union().complex().my_array_struct()[i].my_uint32(i); - staticData.my_union().complex().my_array_struct()[i].my_uint64(i * 10005); - staticData.my_union().complex().my_array_struct()[i].my_float32(i * 5.5f); - staticData.my_union().complex().my_array_struct()[i].my_float64(i * 8.8); - staticData.my_union().complex().my_array_struct()[i].my_float128(i * 10.0); - staticData.my_union().complex().my_array_struct()[i].my_char('J'); - //staticData.my_union().complex().my_array_struct()[i].my_wchar(L'C'); - staticData.my_union().complex().my_array_struct()[i].my_string("JC@eProsima"); - //staticData.my_union().complex().my_array_struct()[i].my_wstring(L"JC-BOOM-Armadilo!@eProsima"); - } - - staticData.my_union().complex().my_map_octet_short()[0] = 1340; - staticData.my_union().complex().my_map_octet_short()[1] = 1341; - staticData.my_union().complex().my_map_long_struct()[1000] = staticData.my_union().complex().my_array_struct()[3]; - staticData.my_union().complex().my_map_long_struct()[55] = staticData.my_union().complex().my_basic_struct(); - - staticData.my_union().complex().my_map_long_seq_octet()[55].push_back({ 1, 2, 3, 4, 5 }); - staticData.my_union().complex().my_map_long_seq_octet()[55].push_back({ 1, 2, 3, 4, 5 }); - staticData.my_union().complex().my_map_long_seq_octet()[0].push_back({ 1, 2, 3, 4, 5 }); - for (int i = 0; i < 500; ++i) - { - staticData.my_union().complex().my_map_long_octet_array_500()[0][i] = i % 256; - staticData.my_union().complex().my_map_long_octet_array_500()[10][i] = (i + 55) % 256; - } - - staticData.my_union().complex().my_small_string_8( - "Bv7EMffURwGNqePoujdSfkF9PXN9TH125X5nGpNLfzya53tZtNJdgMROlYdZnTE1SLWzBdIU7ZyjjGvsGHkmuJUROwVPcNa9q5dRUV3KZAKNx1exL7BjhqIgQFconhd"); - //staticData.my_union().complex().my_small_string_16( - // L"AgzñgXsI9pXbWjYLDvvn8JUFWhxZhk9t92rdsTqylvdpqtXA6hy9dHkoBTgmF2c"); - staticData.my_union().complex().my_large_string_8( - "hYE5vjcLJe6ML5DmoqQwh9ns866dAbnjkVKIKu2VF6lbkvh91ZOG2enEcdoRa8T43hR0Ym0k7tI621EQGufvzmLqxKCPgiXSp2zUTTmIWtn4fM8tC3aP1Yd0dKvn0tDobyp6p3156KvxqG3BKQ6VjFiHlMFoEyz8pjCclhXLl2cfAi97sQzXLUoPYUC5BWKyQTrA2JF6HXZM6vrbw5dc3B4AOJNGdPJ9ai6weF43h1RhnXE9MOFxPNoQnJ8g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Cufr1ZizgzkGwAmnsFmhmBSF0gvbm56NDaUVT0UqXxKxAfRjkILeWR1mW8jfn6RYJH3IWiHxEfyB23rr78NySfgzIchhrm7jEFtmwPpKPKAwzajLv0HpkrtTr38YwWeT5LzHokFAQEc6l3aWdJWapVyt9wX89dEkmPPG9torCV2ddjyF4jAKsxKvzU4pCxV6B3m16IIdnksemJ0xG8iKh4ZPsX"); - for (int i = 0; i < 5; ++i) - { - for (int j = 0; j < 5; ++j) - { - staticData.my_union().complex().my_array_string()[i][j] = - "Ee4rH8nSX1xnWrlDqDJjKWtWntMia9RrZqZPznr0yIDjeroWxUUzpPVV8UK4qUF4eilYR3Dz42"; - } - } - for (int i = 0; i < 42; ++i) - { - staticData.my_union().complex().multi_alias_array_42()[i] = (MyEnum)(i % 3); - } - - for (int i = 0; i < 5; ++i) - { - for (int j = 0; j < 2; ++j) - { - staticData.my_union().complex().my_array_arrays()[i][j] = i * j; - } - } - - for (int i = 0; i < 23; ++i) - { - staticData.my_union().complex().my_sequences_array()[i].push_back(i); - staticData.my_union().complex().my_sequences_array()[i].push_back(i * 10); - staticData.my_union().complex().my_sequences_array()[i].push_back(i * 100); - } - staticData.my_union_2().tres(156); - - DynamicData* my_union = dynData->loan_value(dynData->get_member_id_by_name("my_union")); - - DynamicData* complex = my_union->loan_value(my_union->get_member_id_by_name("complex")); - complex->set_byte_value(66, complex->get_member_id_by_name("my_octet")); - - DynamicData* basic = complex->loan_value(complex->get_member_id_by_name("my_basic_struct")); - basic->set_bool_value(true, basic->get_member_id_by_name("my_bool")); - basic->set_byte_value(166, basic->get_member_id_by_name("my_octet")); - basic->set_int16_value(-10401, basic->get_member_id_by_name("my_int16")); - basic->set_int32_value(5884001, basic->get_member_id_by_name("my_int32")); - basic->set_int64_value(884481567, basic->get_member_id_by_name("my_int64")); - basic->set_uint16_value(250, basic->get_member_id_by_name("my_uint16")); - basic->set_uint32_value(15884, basic->get_member_id_by_name("my_uint32")); - basic->set_uint64_value(765241, basic->get_member_id_by_name("my_uint64")); - basic->set_float32_value(158.55f, basic->get_member_id_by_name("my_float32")); - basic->set_float64_value(765241.58, basic->get_member_id_by_name("my_float64")); - basic->set_float128_value(765241878.154874, basic->get_member_id_by_name("my_float128")); - basic->set_char8_value('L', basic->get_member_id_by_name("my_char")); - //basic->set_char16_value(L'G', basic->get_member_id_by_name("my_wchar")); - basic->set_string_value("Luis@eProsima", basic->get_member_id_by_name("my_string")); - //basic->set_wstring_value(L"LuisGasco@eProsima", basic->get_member_id_by_name("my_wstring")); - complex->return_loaned_value(basic); - - complex->set_enum_value("C", complex->get_member_id_by_name("my_alias_enum")); - complex->set_enum_value("B", complex->get_member_id_by_name("my_enum")); - - DynamicData* my_seq_octet = complex->loan_value(complex->get_member_id_by_name("my_sequence_octet")); - MemberId id; - my_seq_octet->insert_sequence_data(id); - my_seq_octet->set_byte_value(88, id); - my_seq_octet->insert_sequence_data(id); - my_seq_octet->set_byte_value(99, id); - //staticData.my_union().complex().my_sequence_octet().push_back(88); - //staticData.my_union().complex().my_sequence_octet().push_back(99); - complex->return_loaned_value(my_seq_octet); - - DynamicData* my_seq_struct = complex->loan_value(complex->get_member_id_by_name("my_sequence_struct")); - my_seq_struct->insert_sequence_data(id); - my_seq_struct->set_complex_value(DynamicDataFactory::get_instance()->create_copy(basic), id); - //staticData.my_union().complex().my_sequence_struct().push_back(staticData.my_union().complex().my_basic_struct()); - complex->return_loaned_value(my_seq_struct); - - DynamicData* my_array_octet = complex->loan_value(complex->get_member_id_by_name("my_array_octet")); - for (unsigned int i = 0; i < 500; ++i) - { - for (unsigned int j = 0; j < 5; ++j) - { - for (unsigned int k = 0; k < 4; ++k) - { - MemberId array_idx = my_array_octet->get_array_index({ i, j, k }); - my_array_octet->set_byte_value(static_cast(j * k), array_idx); - } - } - //staticData.my_union().complex().my_array_octet()[i][j][k] = j*k; - } - complex->return_loaned_value(my_array_octet); - - DynamicData* my_array_struct = complex->loan_value(complex->get_member_id_by_name("my_array_struct")); - for (int i = 0; i < 5; ++i) - { - DynamicData* tempBasic = DynamicDataFactory::get_instance()->create_data(GetBasicStructType()); - tempBasic->set_bool_value(i % 2 == 1, tempBasic->get_member_id_by_name("my_bool")); - tempBasic->set_byte_value(static_cast(i), tempBasic->get_member_id_by_name("my_octet")); - tempBasic->set_int16_value(static_cast(-i), tempBasic->get_member_id_by_name("my_int16")); - tempBasic->set_int32_value(i, tempBasic->get_member_id_by_name("my_int32")); - tempBasic->set_int64_value(i * 1000, tempBasic->get_member_id_by_name("my_int64")); - tempBasic->set_uint16_value(static_cast(i), tempBasic->get_member_id_by_name("my_uint16")); - tempBasic->set_uint32_value(i, tempBasic->get_member_id_by_name("my_uint32")); - tempBasic->set_uint64_value(i * 10005, tempBasic->get_member_id_by_name("my_uint64")); - tempBasic->set_float32_value(i * 5.5f, tempBasic->get_member_id_by_name("my_float32")); - tempBasic->set_float64_value(i * 8.8, tempBasic->get_member_id_by_name("my_float64")); - tempBasic->set_float128_value(i * 10.0, tempBasic->get_member_id_by_name("my_float128")); - tempBasic->set_char8_value('J', tempBasic->get_member_id_by_name("my_char")); - //tempBasic->set_char16_value(L'C', tempBasic->get_member_id_by_name("my_wchar")); - tempBasic->set_string_value("JC@eProsima", tempBasic->get_member_id_by_name("my_string")); - //tempBasic->set_wstring_value(L"JC-BOOM-Armadilo!@eProsima", tempBasic->get_member_id_by_name("my_wstring")); - my_array_struct->set_complex_value(tempBasic, i); - } - complex->return_loaned_value(my_array_struct); - - DynamicTypeBuilder_ptr octet_builder = m_factory->create_byte_builder(); - DynamicData_ptr key_oct(DynamicDataFactory::get_instance()->create_data(octet_builder->build())); - MemberId kId; - MemberId vId; - MemberId ssId; - MemberId sId; - DynamicData* my_map_octet_short = complex->loan_value(complex->get_member_id_by_name("my_map_octet_short")); - key_oct->set_byte_value(0); - my_map_octet_short->insert_map_data(key_oct.get(), kId, vId); - my_map_octet_short->set_int16_value((short)1340, vId); - key_oct = DynamicDataFactory::get_instance()->create_data(octet_builder->build()); - key_oct->set_byte_value(1); - my_map_octet_short->insert_map_data(key_oct.get(), kId, vId); - my_map_octet_short->set_int16_value((short)1341, vId); - //staticData.my_union().complex().my_map_octet_short()[0] = 1340; - //staticData.my_union().complex().my_map_octet_short()[1] = 1341; - complex->return_loaned_value(my_map_octet_short); - - DynamicTypeBuilder_ptr long_builder = m_factory->create_int32_builder(); - DynamicData_ptr key(DynamicDataFactory::get_instance()->create_data(long_builder->build())); - DynamicData* my_map_long_struct = complex->loan_value(complex->get_member_id_by_name("my_map_long_struct")); - - //DynamicData *mas3 = my_array_struct->loan_value(3); - key = DynamicDataFactory::get_instance()->create_data(long_builder->build()); - key->set_int32_value(55); - my_map_long_struct->insert_map_data(key.get(), kId, vId); - basic = my_map_long_struct->loan_value(vId); - basic->set_bool_value(true, basic->get_member_id_by_name("my_bool")); - basic->set_byte_value(166, basic->get_member_id_by_name("my_octet")); - basic->set_int16_value(-10401, basic->get_member_id_by_name("my_int16")); - basic->set_int32_value(5884001, basic->get_member_id_by_name("my_int32")); - basic->set_int64_value(884481567, basic->get_member_id_by_name("my_int64")); - basic->set_uint16_value(250, basic->get_member_id_by_name("my_uint16")); - basic->set_uint32_value(15884, basic->get_member_id_by_name("my_uint32")); - basic->set_uint64_value(765241, basic->get_member_id_by_name("my_uint64")); - basic->set_float32_value(158.55f, basic->get_member_id_by_name("my_float32")); - basic->set_float64_value(765241.58, basic->get_member_id_by_name("my_float64")); - basic->set_float128_value(765241878.154874, basic->get_member_id_by_name("my_float128")); - basic->set_char8_value('L', basic->get_member_id_by_name("my_char")); - //basic->set_char16_value(L'G', basic->get_member_id_by_name("my_wchar")); - basic->set_string_value("Luis@eProsima", basic->get_member_id_by_name("my_string")); - //basic->set_wstring_value(L"LuisGasco@eProsima", basic->get_member_id_by_name("my_wstring")); - my_map_long_struct->return_loaned_value(basic); - key = DynamicDataFactory::get_instance()->create_data(long_builder->build()); - key->set_int32_value(1000); - my_map_long_struct->insert_map_data(key.get(), kId, vId); - DynamicData* mas3 = my_map_long_struct->loan_value(vId); - int i = 3; - mas3->set_bool_value(i % 2 == 1, mas3->get_member_id_by_name("my_bool")); - mas3->set_byte_value(static_cast(i), mas3->get_member_id_by_name("my_octet")); - mas3->set_int16_value(static_cast(-i), mas3->get_member_id_by_name("my_int16")); - mas3->set_int32_value(i, mas3->get_member_id_by_name("my_int32")); - mas3->set_int64_value(i * 1000, mas3->get_member_id_by_name("my_int64")); - mas3->set_uint16_value(static_cast(i), mas3->get_member_id_by_name("my_uint16")); - mas3->set_uint32_value(i, mas3->get_member_id_by_name("my_uint32")); - mas3->set_uint64_value(i * 10005, mas3->get_member_id_by_name("my_uint64")); - mas3->set_float32_value(i * 5.5f, mas3->get_member_id_by_name("my_float32")); - mas3->set_float64_value(i * 8.8, mas3->get_member_id_by_name("my_float64")); - mas3->set_float128_value(i * 10.0, mas3->get_member_id_by_name("my_float128")); - mas3->set_char8_value('J', mas3->get_member_id_by_name("my_char")); - //mas3->set_char16_value(L'C', mas3->get_member_id_by_name("my_wchar")); - mas3->set_string_value("JC@eProsima", mas3->get_member_id_by_name("my_string")); - //mas3->set_wstring_value(L"JC-BOOM-Armadilo!@eProsima", mas3->get_member_id_by_name("my_wstring")); - my_map_long_struct->return_loaned_value(mas3); - - // staticData.my_union().complex().my_map_long_struct()[1000] = staticData.my_union().complex().my_array_struct()[3]; - // staticData.my_union().complex().my_map_long_struct()[55] = staticData.my_union().complex().my_basic_struct(); - complex->return_loaned_value(my_map_long_struct); - - DynamicData* my_map_long_seq_octet = complex->loan_value(complex->get_member_id_by_name("my_map_long_seq_octet")); - //std::vector my_vector_octet = {1, 2, 3, 4, 5}; - //MemberId id; - /*DynamicTypeBuilder_ptr octet_builder = m_factory->create_byte_builder(); - types::DynamicTypeBuilder_ptr seqOctet_builder = m_factory->create_sequence_builder(octet_builder.get()); - types::DynamicType_ptr seqSeqOctet_builder = m_factory->create_sequence_builder(seqOctet_builder.get())->build(); - DynamicData *dataSeqOctet = seqOctet_builder->build(); - DynamicData *dataSeqSeqOctet = seqSeqOctet_builder->build(); - dataSeqOctet->insert_sequence_data(id); - dataSeqOctet->set_byte_value(1, id); - dataSeqOctet->insert_sequence_data(id); - dataSeqOctet->set_byte_value(2, id); - dataSeqOctet->insert_sequence_data(id); - dataSeqOctet->set_byte_value(3, id); - dataSeqOctet->insert_sequence_data(id); - dataSeqOctet->set_byte_value(4, id); - dataSeqOctet->insert_sequence_data(id); - dataSeqOctet->set_byte_value(5, id); - dataSeqSeqOctet->insert_sequence_data(id); - dataSeqSeqOctet->set_complex_value(dataSeqOctet, id);*/ - // insert_map_data(DynamicData_ptr key, MemberId& outKeyId, MemberId& outValueId); - - key = DynamicDataFactory::get_instance()->create_data(long_builder->build()); - key->set_int32_value(0); - my_map_long_seq_octet->insert_map_data(key.get(), kId, vId); - - DynamicData* seq_seq_oct = my_map_long_seq_octet->loan_value(vId); - seq_seq_oct->insert_sequence_data(ssId); - DynamicData* seq_oct = seq_seq_oct->loan_value(ssId); - seq_oct->insert_sequence_data(sId); - seq_oct->set_byte_value(1, sId); - seq_oct->insert_sequence_data(sId); - seq_oct->set_byte_value(2, sId); - seq_oct->insert_sequence_data(sId); - seq_oct->set_byte_value(3, sId); - seq_oct->insert_sequence_data(sId); - seq_oct->set_byte_value(4, sId); - seq_oct->insert_sequence_data(sId); - seq_oct->set_byte_value(5, sId); - seq_seq_oct->return_loaned_value(seq_oct); - my_map_long_seq_octet->return_loaned_value(seq_seq_oct); - - key = DynamicDataFactory::get_instance()->create_data(long_builder->build()); - key->set_int32_value(55); - my_map_long_seq_octet->insert_map_data(key.get(), kId, vId); - - seq_seq_oct = my_map_long_seq_octet->loan_value(vId); - seq_seq_oct->insert_sequence_data(ssId); - seq_oct = seq_seq_oct->loan_value(ssId); - seq_oct->insert_sequence_data(sId); - seq_oct->set_byte_value(1, sId); - seq_oct->insert_sequence_data(sId); - seq_oct->set_byte_value(2, sId); - seq_oct->insert_sequence_data(sId); - seq_oct->set_byte_value(3, sId); - seq_oct->insert_sequence_data(sId); - seq_oct->set_byte_value(4, sId); - seq_oct->insert_sequence_data(sId); - seq_oct->set_byte_value(5, sId); - seq_seq_oct->return_loaned_value(seq_oct); - seq_seq_oct->insert_sequence_data(ssId); - seq_oct = seq_seq_oct->loan_value(ssId); - seq_oct->insert_sequence_data(sId); - seq_oct->set_byte_value(1, sId); - seq_oct->insert_sequence_data(sId); - seq_oct->set_byte_value(2, sId); - seq_oct->insert_sequence_data(sId); - seq_oct->set_byte_value(3, sId); - seq_oct->insert_sequence_data(sId); - seq_oct->set_byte_value(4, sId); - seq_oct->insert_sequence_data(sId); - seq_oct->set_byte_value(5, sId); - seq_seq_oct->return_loaned_value(seq_oct); - my_map_long_seq_octet->return_loaned_value(seq_seq_oct); - //staticData.my_union().complex().my_map_long_seq_octet()[55].push_back(my_vector_octet); - //staticData.my_union().complex().my_map_long_seq_octet()[55].push_back(my_vector_octet); - //staticData.my_union().complex().my_map_long_seq_octet()[0].push_back(my_vector_octet); - complex->return_loaned_value(my_map_long_seq_octet); - - DynamicData* my_map_long_octet_array_500 = - complex->loan_value(complex->get_member_id_by_name("my_map_long_octet_array_500")); - - key = DynamicDataFactory::get_instance()->create_data(long_builder->build()); - key->set_int32_value(0); - my_map_long_octet_array_500->insert_map_data(key.get(), kId, vId); - - DynamicData* oct_array_500 = my_map_long_octet_array_500->loan_value(vId); - for (int j = 0; j < 500; ++j) - { - oct_array_500->set_byte_value(j % 256, j); - //staticData.my_union().complex().my_map_long_octet_array_500()[0][i] = i%256; - } - my_map_long_octet_array_500->return_loaned_value(oct_array_500); - - key = DynamicDataFactory::get_instance()->create_data(long_builder->build()); - key->set_int32_value(10); - my_map_long_octet_array_500->insert_map_data(key.get(), kId, vId); - oct_array_500 = my_map_long_octet_array_500->loan_value(vId); - - for (int j = 0; j < 500; ++j) - { - oct_array_500->set_byte_value((j + 55) % 256, j); - //staticData.my_union().complex().my_map_long_octet_array_500()[10][i] = (i+55)%256; - } - my_map_long_octet_array_500->return_loaned_value(oct_array_500); - complex->return_loaned_value(my_map_long_octet_array_500); - - complex->set_string_value( - "Bv7EMffURwGNqePoujdSfkF9PXN9TH125X5nGpNLfzya53tZtNJdgMROlYdZnTE1SLWzBdIU7ZyjjGvsGHkmuJUROwVPcNa9q5dRUV3KZAKNx1exL7BjhqIgQFconhd", complex->get_member_id_by_name( - "my_small_string_8")); - //complex->set_wstring_value(L"AgzñgXsI9pXbWjYLDvvn8JUFWhxZhk9t92rdsTqylvdpqtXA6hy9dHkoBTgmF2c", complex->get_member_id_by_name( - // "my_small_string_16")); - complex->set_string_value( - "hYE5vjcLJe6ML5DmoqQwh9ns866dAbnjkVKIKu2VF6lbkvh91ZOG2enEcdoRa8T43hR0Ym0k7tI621EQGufvzmLqxKCPgiXSp2zUTTmIWtn4fM8tC3aP1Yd0dKvn0tDobyp6p3156KvxqG3BKQ6VjFiHlMFoEyz8pjCclhXLl2cfAi97sQzXLUoPYUC5BWKyQTrA2JF6HXZM6vrbw5dc3B4AOJNGdPJ9ai6weF43h1RhnXE9MOFxPNoQnJ8gqSXYbMtpG6ZzqhUyoz0XhFDt7EOqXIgvc9SCejQTVMPeRcF5Zy57hrYZiKrCQqFWidS4BdfEAkuwESgBmEpEFOpZotwDt0TGDaLktSt3dKRsURO6TpuZ2nZNdiEJyc597ZjjQXtyKU7OCyRRqllzAnHEtoU3zd3OLTOvT5uk32N1Y64tpUte63De2EMwDNYb2eGAQfATdSt8VcGBOzJQjsmrMwMumtk48JzXXLxjo6s2vl2rNK9WQM1", complex->get_member_id_by_name( - "my_large_string_8")); - //complex->set_wstring_value( - // L"nosYBfFr1s3t8rUsuUrVCWFi6moDk7GULFj6XnkebIDkjl3n2ykKxUIaLj3qNNUx0ny8DvFbdfxZBdMhBNW3fHbKrig4GkHnN1JoEo0ACiPxrARusDs3xKzvaQQrls6lVUFAUXzDOtw5f2CNVJKiruGjXUO2Lq5Mmy8ygW3eUiTlueAHA2dRXXryOFi47jS3DkmBH4aAOKcmR27KhhJnXaY0gWy3XdSnaGQNB3XvbmxQ7xXDsf1wz860WMEKP3VhdOLsmS6tKCb4sshuOlmUSyTggY7vNoxfpG1EUFP5iPro9E0tHLLdHlWf2NwU8OXCYx6KKEbs5pFMvgEstnQglsdTk0lOv6riaFkFOwx83gW1l6Pg4eXjacnJKoVh1pOeZxULLZpCECw8yRZ9z4JPHxh2C7ytkCHMKp9O4MwQwYvvvgWWLWfJgb7Ecy2tgvWLpNDzgkFrEFhaCTKitChlG422CnLSsXvTBNnF52sULH6rcwOVx3mbhqte3ld3fObtAuH3zPzjOF4vVbvUXxgZh1Zx1cey0iGfnhOZHUfUwJ3Qv0WZNcuVLvMMhhg85A3620b84MAIc2UoW9Hl4BIT7pHo41ApF0DxIPJL0QdIdAOjn0JTPZqAhoHVBQoYvivPHftk5Crd1a1J8L7hSs0s4uSQKAMTKDxy3gKLaGAg277h4iEsEZRCI4RPlPTo9nZ48s8OO2KzqrUbMkoPSTgaJEXq8GsozAzh0wtL4P3gPeHO5nQzoytoXAkiXoPph0GaTLiahYQksYeK1eVQADDqZPXC55teXKKdX4aomCufr1ZizgzkGwAmnsFmhmBSF0gvbm56NDaUVT0UqXxKxAfRjkILeWR1mW8jfn6RYJH3IWiHxEfyB23rr78NySfgzIchhrm7jEFtmwPpKPKAwzajLv0HpkrtTr38YwWeT5LzHokFAQEc6l3aWdJWapVyt9wX89dEkmPPG9torCV2ddjyF4jAKsxKvzU4pCxV6B3m16IIdnksemJ0xG8iKh4ZPsX", complex->get_member_id_by_name( - // "my_large_string_16")); - - DynamicData* my_array_string = complex->loan_value(complex->get_member_id_by_name("my_array_string")); - for (unsigned int j = 0; j < 5; ++j) - { - for (unsigned int k = 0; k < 5; ++k) - { - MemberId array_idx = my_array_string->get_array_index({ j, k }); - my_array_string->set_string_value( - "Ee4rH8nSX1xnWrlDqDJjKWtWntMia9RrZqZPznr0yIDjeroWxUUzpPVV8UK4qUF4eilYR3Dz42", array_idx); - //staticData.my_union().complex().my_array_string()[i][j]("Ee4rH8nSX1xnWrlDqDJjKWtWntMia9RrZqZPznr0yIDjeroWxUUzpPVV8UK4qUF4eilYR3Dz42"); - } - } - complex->return_loaned_value(my_array_string); - - DynamicData* multi_alias_array_42 = complex->loan_value(complex->get_member_id_by_name("multi_alias_array_42")); - for (int j = 0; j < 42; ++j) - { - multi_alias_array_42->set_enum_value(j % 3, j); - //staticData.my_union().complex().multi_alias_array_42()[i](i%3); - } - complex->return_loaned_value(multi_alias_array_42); - - DynamicData* my_array_arrays = complex->loan_value(complex->get_member_id_by_name("my_array_arrays")); - for (unsigned int j = 0; j < 5; ++j) - { - DynamicData* myMiniArray = my_array_arrays->loan_value(j); - for (unsigned int k = 0; k < 2; ++k) - { - myMiniArray->set_int32_value(j * k, k); - //staticData.my_union().complex().my_array_arrays()[i][j](i*j); - } - my_array_arrays->return_loaned_value(myMiniArray); - } - complex->return_loaned_value(my_array_arrays); - - DynamicData* my_sequences_array = complex->loan_value(complex->get_member_id_by_name("my_sequences_array")); - for (int j = 0; j < 23; ++j) - { - DynamicData* seq = DynamicDataFactory::get_instance()->create_data(GetMySequenceLongType()); - seq->insert_sequence_data(id); - seq->set_int32_value(j, id); - seq->insert_sequence_data(id); - seq->set_int32_value(j * 10, id); - seq->insert_sequence_data(id); - seq->set_int32_value(j * 100, id); - my_sequences_array->set_complex_value(seq, j); - // staticData.my_union().complex().my_sequences_array()[i].push_back(i); - // staticData.my_union().complex().my_sequences_array()[i].push_back(i*10); - // staticData.my_union().complex().my_sequences_array()[i].push_back(i*100); - } - complex->return_loaned_value(my_sequences_array); - - my_union->return_loaned_value(complex); - dynData->return_loaned_value(my_union); - - DynamicData* my_union_2 = dynData->loan_value(dynData->get_member_id_by_name("my_union_2")); - my_union_2->set_int32_value(156, my_union_2->get_member_id_by_name("tres")); - - dynData->return_loaned_value(my_union_2); - - // Serialize <-> Deserialize Test - DynamicPubSubType pubsubType(m_DynManualType); - uint32_t payloadSize = static_cast(pubsubType.getSerializedSizeProvider(dynData.get())()); - SerializedPayload_t payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(dynData.get(), &payload)); - ASSERT_TRUE(payload.length == payloadSize); - /* - std::cout << "BEGIN" << std::endl; - for (uint32_t j = 0; j < payload.length; j += 100) - { - std::cout << std::endl; - for (uint32_t k = 0; k < 100; k++) - { - if (j + k < payload.length) - { - if ((int)payload.data[j + k] == 204) - { - std::cout << 0 << " "; - } - else - { - std::cout << (int)payload.data[j + k] << " "; - } - } - } - } - std::cout << "END" << std::endl; - */ - CompleteStructPubSubType pbComplete; - uint32_t payloadSize2 = static_cast(m_StaticType.getSerializedSizeProvider(&staticData)()); - SerializedPayload_t stPayload(payloadSize2); - ASSERT_TRUE(pbComplete.serialize(&staticData, &stPayload)); - ASSERT_TRUE(stPayload.length == payloadSize2); - /* - std::cout << "BEGIN" << std::endl; - for (uint32_t j = 0; j < stPayload.length; j += 100) - { - std::cout << std::endl; - for (uint32_t k = 0; k < 100; k++) - { - if (j + k < stPayload.length) - { - if ((int)stPayload.data[j + k] == 204) - { - std::cout << 0 << " "; - } - else - { - std::cout << (int)stPayload.data[j + k] << " "; - } - } - } - } - std::cout << "END" << std::endl; - */ - types::DynamicData_ptr dynDataFromDynamic(DynamicDataFactory::get_instance()->create_data(m_DynAutoType)); - ASSERT_TRUE(pubsubType.deserialize(&payload, dynDataFromDynamic.get())); - - types::DynamicData_ptr dynDataFromStatic(DynamicDataFactory::get_instance()->create_data(m_DynAutoType)); - ASSERT_TRUE(pubsubType.deserialize(&stPayload, dynDataFromStatic.get())); - - ASSERT_TRUE(dynDataFromStatic->equals(dynDataFromDynamic.get())); -} - -TEST_F(DynamicComplexTypesTests, Data_Comparison_with_Keys) -{ - KeyedStruct staticData; - - staticData.basic().my_bool(true); - staticData.basic().my_octet(100); - staticData.basic().my_int16(-12000); - staticData.basic().my_int32(-12000000); - staticData.basic().my_int64(-1200000000); - staticData.basic().my_uint16(12000); - staticData.basic().my_uint32(12000000); - staticData.basic().my_uint64(1200000000); - staticData.basic().my_float32(5.5f); - staticData.basic().my_float64(8.888); - staticData.basic().my_float128(1005.1005); - staticData.basic().my_char('O'); - //staticData.basic().my_wchar(L'M'); - staticData.basic().my_string("G It's"); - //staticData.basic().my_wstring(L" Working"); - //staticData.key(88); - - DynamicData* dynData = DynamicDataFactory::get_instance()->create_data(GetKeyedStructType()); - DynamicData* basic = dynData->loan_value(dynData->get_member_id_by_name("basic")); - basic->set_bool_value(true, basic->get_member_id_by_name("my_bool")); - basic->set_byte_value(100, basic->get_member_id_by_name("my_octet")); - basic->set_int16_value(-12000, basic->get_member_id_by_name("my_int16")); - basic->set_int32_value(-12000000, basic->get_member_id_by_name("my_int32")); - basic->set_int64_value(-1200000000, basic->get_member_id_by_name("my_int64")); - basic->set_uint16_value(12000, basic->get_member_id_by_name("my_uint16")); - basic->set_uint32_value(12000000, basic->get_member_id_by_name("my_uint32")); - basic->set_uint64_value(1200000000, basic->get_member_id_by_name("my_uint64")); - basic->set_float32_value(5.5f, basic->get_member_id_by_name("my_float32")); - basic->set_float64_value(8.888, basic->get_member_id_by_name("my_float64")); - basic->set_float128_value(1005.1005, basic->get_member_id_by_name("my_float128")); - basic->set_char8_value('O', basic->get_member_id_by_name("my_char")); - //basic->set_char16_value(L'M', basic->get_member_id_by_name("my_wchar")); - basic->set_string_value("G It's", basic->get_member_id_by_name("my_string")); - //basic->set_wstring_value(L" Working", basic->get_member_id_by_name("my_wstring")); - dynData->return_loaned_value(basic); - //dynData->set_byte_value(88, dynData->get_member_id_by_name("key")); - - KeyedStructPubSubType pbKeyed; - DynamicPubSubType pubsubType(GetKeyedStructType()); - uint32_t payloadSize = static_cast(pbKeyed.getSerializedSizeProvider(&staticData)()); - SerializedPayload_t stPayload(payloadSize); - ASSERT_TRUE(pbKeyed.serialize(&staticData, &stPayload)); - ASSERT_TRUE(payloadSize == stPayload.length); - - DynamicPubSubType dynPubSub; - uint32_t payloadSize2 = static_cast(dynPubSub.getSerializedSizeProvider(dynData)()); - SerializedPayload_t dynPayload(payloadSize2); - ASSERT_TRUE(dynPubSub.serialize(dynData, &dynPayload)); - ASSERT_TRUE(payloadSize2 == dynPayload.length); - - types::DynamicData* dynDataFromStatic = DynamicDataFactory::get_instance()->create_data(GetKeyedStructType()); - ASSERT_TRUE(pubsubType.deserialize(&stPayload, dynDataFromStatic)); - - types::DynamicData* dynDataFromDynamic = DynamicDataFactory::get_instance()->create_data(GetKeyedStructType()); - ASSERT_TRUE(dynPubSub.deserialize(&dynPayload, dynDataFromDynamic)); - - ASSERT_TRUE(dynDataFromStatic->equals(dynDataFromDynamic)); - - DynamicDataFactory::get_instance()->delete_data(dynData); - DynamicDataFactory::get_instance()->delete_data(dynDataFromStatic); - DynamicDataFactory::get_instance()->delete_data(dynDataFromDynamic); -} - -TEST_F(DynamicComplexTypesTests, TypeInformation) -{ - const TypeObject* compl_obj = TypeObjectFactory::get_instance()->get_type_object("CompleteStruct", true); - const TypeInformation* info = TypeObjectFactory::get_instance()->get_type_information("CompleteStruct"); - ASSERT_FALSE(info->minimal().typeid_with_size().type_id() == info->complete().typeid_with_size().type_id()); - ASSERT_TRUE(info->complete().typeid_with_size().type_id()._d() == EK_COMPLETE); - ASSERT_TRUE(info->complete().dependent_typeid_count() == 2); - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - ASSERT_TRUE(info->complete().typeid_with_size().typeobject_serialized_size() - == calculator.calculate_serialized_size(*compl_obj, current_alignment)); - const TypeInformation* enum_info = TypeObjectFactory::get_instance()->get_type_information("MyAliasEnum"); - ASSERT_TRUE(enum_info->minimal().typeid_with_size().type_id()._d() == EK_MINIMAL); - const TypeInformation* bool_info = TypeObjectFactory::get_instance()->get_type_information("bool"); - ASSERT_TRUE(bool_info->minimal().typeid_with_size().type_id()._d() == TK_BOOLEAN); - ASSERT_TRUE(bool_info->minimal().typeid_with_size().typeobject_serialized_size() == 0); - - const TypeObject* key_obj = TypeObjectFactory::get_instance()->get_type_object("key"); - ASSERT_EQ(key_obj->minimal()._d(), TK_ANNOTATION); - key_obj = TypeObjectFactory::get_instance()->get_type_object("Key"); - ASSERT_EQ(key_obj->minimal()._d(), TK_ANNOTATION); -} - -int main( - int argc, - char** argv) -{ - eprosima::fastdds::dds::Log::SetVerbosity(eprosima::fastdds::dds::Log::Info); - - testing::InitGoogleTest(&argc, argv); - return RUN_ALL_TESTS(); -} diff --git a/test/unittest/dynamic_types/DynamicTypesTests.cpp b/test/unittest/dynamic_types/DynamicTypesTests.cpp deleted file mode 100644 index b4e3e097199..00000000000 --- a/test/unittest/dynamic_types/DynamicTypesTests.cpp +++ /dev/null @@ -1,5106 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include "idl/BasicPubSubTypes.h" -#include "idl/BasicTypeObject.h" -#include - -using namespace eprosima::fastrtps; -using namespace eprosima::fastrtps::rtps; -using namespace eprosima::fastrtps::types; - -class DynamicTypesTests : public ::testing::Test -{ - const std::string config_file_ = "types_profile.xml"; - -public: - - DynamicTypesTests() - { - } - - ~DynamicTypesTests() - { - eprosima::fastdds::dds::Log::KillThread(); - } - - virtual void TearDown() - { - DynamicDataFactory::delete_instance(); - DynamicTypeBuilderFactory::delete_instance(); - } - - const std::string& config_file() - { - return config_file_; - } - -}; - -TEST_F(DynamicTypesTests, TypeDescriptors_unit_tests) -{ - // Given - TypeDescriptor pInt32Descriptor; - pInt32Descriptor.set_kind(TK_INT32); - pInt32Descriptor.set_name("TEST_INT32"); - TypeDescriptor pInt32Descriptor2; - - // Then - ASSERT_FALSE(pInt32Descriptor.equals(&pInt32Descriptor2)); - ASSERT_FALSE(pInt32Descriptor2.copy_from(nullptr) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(pInt32Descriptor2.copy_from(&pInt32Descriptor) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(pInt32Descriptor.equals(&pInt32Descriptor2)); - pInt32Descriptor2.set_name("TEST_2"); - ASSERT_FALSE(pInt32Descriptor.equals(&pInt32Descriptor2)); - pInt32Descriptor2.set_name(pInt32Descriptor.get_name()); - ASSERT_TRUE(pInt32Descriptor.equals(&pInt32Descriptor2)); - pInt32Descriptor2.set_kind(TK_NONE); - ASSERT_FALSE(pInt32Descriptor.equals(&pInt32Descriptor2)); -} - -TEST_F(DynamicTypesTests, DynamicType_basic_unit_tests) -{ - // Create basic types - DynamicTypeBuilder_ptr int32_builder = DynamicTypeBuilderFactory::get_instance()->create_int32_builder(); - ASSERT_TRUE(int32_builder != nullptr); - ASSERT_FALSE(int32_builder == nullptr); - DynamicType_ptr int32_type = DynamicTypeBuilderFactory::get_instance()->create_type(int32_builder.get()); - ASSERT_TRUE(int32_type != nullptr); - ASSERT_FALSE(int32_type == nullptr); - DynamicType_ptr type2 = DynamicTypeBuilderFactory::get_instance()->create_type(int32_builder.get()); - ASSERT_TRUE(type2 != nullptr); - ASSERT_TRUE(type2->equals(int32_type.get())); - - DynamicTypeBuilder_ptr struct_type_builder = DynamicTypeBuilderFactory::get_instance()->create_struct_builder(); - ASSERT_TRUE(struct_type_builder != nullptr); - - // Add members to the struct. - ASSERT_TRUE(struct_type_builder->add_member(0, "int32", int32_type) == ReturnCode_t::RETCODE_OK); - auto struct_type = struct_type_builder->build(); - ASSERT_TRUE(struct_type != nullptr); - - ASSERT_TRUE(struct_type_builder->add_member(1, "int64", - DynamicTypeBuilderFactory::get_instance()->create_int64_type()) == ReturnCode_t::RETCODE_OK); - auto struct_type2 = struct_type_builder->build(); - ASSERT_TRUE(struct_type2 != nullptr); - ASSERT_FALSE(struct_type->equals(struct_type2.get())); -} - -TEST_F(DynamicTypesTests, DynamicTypeBuilderFactory_unit_tests) -{ - // Try to create with invalid values - ASSERT_FALSE(DynamicTypeBuilderFactory::get_instance()->create_custom_builder(nullptr)); - { - // Create basic types - DynamicTypeBuilder_ptr created_builder = DynamicTypeBuilderFactory::get_instance()->create_int32_builder(); - ASSERT_TRUE(created_builder != nullptr); - DynamicType_ptr type = created_builder->build(); - ASSERT_TRUE(type != nullptr); - DynamicType_ptr type2 = created_builder->build(); - ASSERT_TRUE(type2 != nullptr); - ASSERT_TRUE(type->equals(type2.get())); - DynamicType_ptr type3 = DynamicTypeBuilderFactory::get_instance()->create_int32_type(); - ASSERT_TRUE(type3 != nullptr); - ASSERT_TRUE(type->equals(type3.get())); - auto data = DynamicDataFactory::get_instance()->create_data(created_builder.get()); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data) == ReturnCode_t::RETCODE_OK); - - auto data2 = DynamicDataFactory::get_instance()->create_data(type); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data2) == ReturnCode_t::RETCODE_OK); - - created_builder = DynamicTypeBuilderFactory::get_instance()->create_uint32_builder(); - ASSERT_TRUE(created_builder != nullptr); - type = created_builder->build(); - ASSERT_TRUE(type != nullptr); - type2 = created_builder->build(); - ASSERT_TRUE(type2 != nullptr); - ASSERT_TRUE(type->equals(type2.get())); - type3 = DynamicTypeBuilderFactory::get_instance()->create_uint32_type(); - ASSERT_TRUE(type3 != nullptr); - ASSERT_TRUE(type->equals(type3.get())); - data = DynamicDataFactory::get_instance()->create_data(type); - data2 = DynamicDataFactory::get_instance()->create_copy(data); - ASSERT_TRUE(data2->equals(data)); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data2) == ReturnCode_t::RETCODE_OK); - - created_builder = DynamicTypeBuilderFactory::get_instance()->create_int16_builder(); - ASSERT_TRUE(created_builder != nullptr); - type = created_builder->build(); - ASSERT_TRUE(type != nullptr); - type2 = created_builder->build(); - ASSERT_TRUE(type2 != nullptr); - ASSERT_TRUE(type->equals(type2.get())); - type3 = DynamicTypeBuilderFactory::get_instance()->create_int16_type(); - ASSERT_TRUE(type3 != nullptr); - ASSERT_TRUE(type->equals(type3.get())); - data = DynamicDataFactory::get_instance()->create_data(type); - data2 = DynamicDataFactory::get_instance()->create_copy(data); - ASSERT_TRUE(data2->equals(data)); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data2) == ReturnCode_t::RETCODE_OK); - - created_builder = DynamicTypeBuilderFactory::get_instance()->create_uint16_builder(); - ASSERT_TRUE(created_builder != nullptr); - type = created_builder->build(); - ASSERT_TRUE(type != nullptr); - type2 = created_builder->build(); - ASSERT_TRUE(type2 != nullptr); - ASSERT_TRUE(type->equals(type2.get())); - type3 = DynamicTypeBuilderFactory::get_instance()->create_uint16_type(); - ASSERT_TRUE(type3 != nullptr); - ASSERT_TRUE(type->equals(type3.get())); - data = DynamicDataFactory::get_instance()->create_data(type); - data2 = DynamicDataFactory::get_instance()->create_copy(data); - ASSERT_TRUE(data2->equals(data)); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data2) == ReturnCode_t::RETCODE_OK); - - created_builder = DynamicTypeBuilderFactory::get_instance()->create_int64_builder(); - ASSERT_TRUE(created_builder != nullptr); - type = created_builder->build(); - ASSERT_TRUE(type != nullptr); - type2 = created_builder->build(); - ASSERT_TRUE(type2 != nullptr); - ASSERT_TRUE(type->equals(type2.get())); - type3 = DynamicTypeBuilderFactory::get_instance()->create_int64_type(); - ASSERT_TRUE(type3 != nullptr); - ASSERT_TRUE(type->equals(type3.get())); - data = DynamicDataFactory::get_instance()->create_data(type); - data2 = DynamicDataFactory::get_instance()->create_copy(data); - ASSERT_TRUE(data2->equals(data)); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data2) == ReturnCode_t::RETCODE_OK); - - created_builder = DynamicTypeBuilderFactory::get_instance()->create_uint64_builder(); - ASSERT_TRUE(created_builder != nullptr); - type = created_builder->build(); - ASSERT_TRUE(type != nullptr); - type2 = created_builder->build(); - ASSERT_TRUE(type2 != nullptr); - ASSERT_TRUE(type->equals(type2.get())); - type3 = DynamicTypeBuilderFactory::get_instance()->create_uint64_type(); - ASSERT_TRUE(type3 != nullptr); - ASSERT_TRUE(type->equals(type3.get())); - data = DynamicDataFactory::get_instance()->create_data(type); - data2 = DynamicDataFactory::get_instance()->create_copy(data); - ASSERT_TRUE(data2->equals(data)); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data2) == ReturnCode_t::RETCODE_OK); - - created_builder = DynamicTypeBuilderFactory::get_instance()->create_float32_builder(); - ASSERT_TRUE(created_builder != nullptr); - type = created_builder->build(); - ASSERT_TRUE(type != nullptr); - type2 = created_builder->build(); - ASSERT_TRUE(type2 != nullptr); - ASSERT_TRUE(type->equals(type2.get())); - type3 = DynamicTypeBuilderFactory::get_instance()->create_float32_type(); - ASSERT_TRUE(type3 != nullptr); - ASSERT_TRUE(type->equals(type3.get())); - data = DynamicDataFactory::get_instance()->create_data(type); - data2 = DynamicDataFactory::get_instance()->create_copy(data); - ASSERT_TRUE(data2->equals(data)); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data2) == ReturnCode_t::RETCODE_OK); - - created_builder = DynamicTypeBuilderFactory::get_instance()->create_float64_builder(); - ASSERT_TRUE(created_builder != nullptr); - type = created_builder->build(); - ASSERT_TRUE(type != nullptr); - type2 = created_builder->build(); - ASSERT_TRUE(type2 != nullptr); - ASSERT_TRUE(type->equals(type2.get())); - type3 = DynamicTypeBuilderFactory::get_instance()->create_float64_type(); - ASSERT_TRUE(type3 != nullptr); - ASSERT_TRUE(type->equals(type3.get())); - data = DynamicDataFactory::get_instance()->create_data(type); - data2 = DynamicDataFactory::get_instance()->create_copy(data); - ASSERT_TRUE(data2->equals(data)); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data2) == ReturnCode_t::RETCODE_OK); - - created_builder = DynamicTypeBuilderFactory::get_instance()->create_float128_builder(); - ASSERT_TRUE(created_builder != nullptr); - type = created_builder->build(); - ASSERT_TRUE(type != nullptr); - type2 = created_builder->build(); - ASSERT_TRUE(type2 != nullptr); - ASSERT_TRUE(type->equals(type2.get())); - type3 = DynamicTypeBuilderFactory::get_instance()->create_float128_type(); - ASSERT_TRUE(type3 != nullptr); - ASSERT_TRUE(type->equals(type3.get())); - data = DynamicDataFactory::get_instance()->create_data(type); - data2 = DynamicDataFactory::get_instance()->create_copy(data); - ASSERT_TRUE(data2->equals(data)); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data2) == ReturnCode_t::RETCODE_OK); - - created_builder = DynamicTypeBuilderFactory::get_instance()->create_char8_builder(); - ASSERT_TRUE(created_builder != nullptr); - type = created_builder->build(); - ASSERT_TRUE(type != nullptr); - type2 = created_builder->build(); - ASSERT_TRUE(type2 != nullptr); - ASSERT_TRUE(type->equals(type2.get())); - type3 = DynamicTypeBuilderFactory::get_instance()->create_char8_type(); - ASSERT_TRUE(type3 != nullptr); - ASSERT_TRUE(type->equals(type3.get())); - data = DynamicDataFactory::get_instance()->create_data(type); - data2 = DynamicDataFactory::get_instance()->create_copy(data); - ASSERT_TRUE(data2->equals(data)); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data2) == ReturnCode_t::RETCODE_OK); - - created_builder = DynamicTypeBuilderFactory::get_instance()->create_char16_builder(); - ASSERT_TRUE(created_builder != nullptr); - type = created_builder->build(); - ASSERT_TRUE(type != nullptr); - type2 = created_builder->build(); - ASSERT_TRUE(type2 != nullptr); - ASSERT_TRUE(type->equals(type2.get())); - type3 = DynamicTypeBuilderFactory::get_instance()->create_char16_type(); - ASSERT_TRUE(type3 != nullptr); - ASSERT_TRUE(type->equals(type3.get())); - data = DynamicDataFactory::get_instance()->create_data(type); - data2 = DynamicDataFactory::get_instance()->create_copy(data); - ASSERT_TRUE(data2->equals(data)); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data2) == ReturnCode_t::RETCODE_OK); - - created_builder = DynamicTypeBuilderFactory::get_instance()->create_byte_builder(); - ASSERT_TRUE(created_builder != nullptr); - type = created_builder->build(); - ASSERT_TRUE(type != nullptr); - type2 = created_builder->build(); - ASSERT_TRUE(type2 != nullptr); - ASSERT_TRUE(type->equals(type2.get())); - type3 = DynamicTypeBuilderFactory::get_instance()->create_byte_type(); - ASSERT_TRUE(type3 != nullptr); - ASSERT_TRUE(type->equals(type3.get())); - data = DynamicDataFactory::get_instance()->create_data(type); - data2 = DynamicDataFactory::get_instance()->create_copy(data); - ASSERT_TRUE(data2->equals(data)); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data2) == ReturnCode_t::RETCODE_OK); - - created_builder = DynamicTypeBuilderFactory::get_instance()->create_bool_builder(); - ASSERT_TRUE(created_builder != nullptr); - type = created_builder->build(); - ASSERT_TRUE(type != nullptr); - type2 = created_builder->build(); - ASSERT_TRUE(type2 != nullptr); - ASSERT_TRUE(type->equals(type2.get())); - type3 = DynamicTypeBuilderFactory::get_instance()->create_bool_type(); - ASSERT_TRUE(type3 != nullptr); - ASSERT_TRUE(type->equals(type3.get())); - data = DynamicDataFactory::get_instance()->create_data(type); - data2 = DynamicDataFactory::get_instance()->create_copy(data); - ASSERT_TRUE(data2->equals(data)); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data2) == ReturnCode_t::RETCODE_OK); - - created_builder = - DynamicTypeBuilderFactory::get_instance()->create_string_builder(BOUND_UNLIMITED); - ASSERT_TRUE(created_builder != nullptr); - type = created_builder->build(); - ASSERT_TRUE(type != nullptr); - type2 = created_builder->build(); - ASSERT_TRUE(type2 != nullptr); - ASSERT_TRUE(type->equals(type2.get())); - type3 = DynamicTypeBuilderFactory::get_instance()->create_string_type(); - ASSERT_TRUE(type3 != nullptr); - ASSERT_TRUE(type->equals(type3.get())); - data = DynamicDataFactory::get_instance()->create_data(type); - data2 = DynamicDataFactory::get_instance()->create_copy(data); - ASSERT_TRUE(data2->equals(data)); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data2) == ReturnCode_t::RETCODE_OK); - - created_builder = DynamicTypeBuilderFactory::get_instance()->create_wstring_builder(BOUND_UNLIMITED); - ASSERT_TRUE(created_builder != nullptr); - type = created_builder->build(); - ASSERT_TRUE(type != nullptr); - type2 = created_builder->build(); - ASSERT_TRUE(type2 != nullptr); - ASSERT_TRUE(type->equals(type2.get())); - type3 = DynamicTypeBuilderFactory::get_instance()->create_wstring_type(); - ASSERT_TRUE(type3 != nullptr); - ASSERT_TRUE(type->equals(type3.get())); - data = DynamicDataFactory::get_instance()->create_data(type); - data2 = DynamicDataFactory::get_instance()->create_copy(data); - ASSERT_TRUE(data2->equals(data)); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data2) == ReturnCode_t::RETCODE_OK); - - // Create with custom types - TypeDescriptor pInt32Descriptor; - pInt32Descriptor.set_kind(TK_INT32); - pInt32Descriptor.set_name("TEST_INT32"); - created_builder = DynamicTypeBuilderFactory::get_instance()->create_custom_builder(&pInt32Descriptor); - ASSERT_TRUE(created_builder != nullptr); - type = created_builder->build(); - ASSERT_TRUE(type != nullptr); - type2 = created_builder->build(); - ASSERT_TRUE(type2 != nullptr); - ASSERT_TRUE(type->equals(type2.get())); - data = DynamicDataFactory::get_instance()->create_data(type); - data2 = DynamicDataFactory::get_instance()->create_copy(data); - ASSERT_TRUE(data2->equals(data)); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data2) == ReturnCode_t::RETCODE_OK); - } - ASSERT_TRUE(DynamicTypeBuilderFactory::get_instance()->is_empty()); - ASSERT_TRUE(DynamicDataFactory::get_instance()->is_empty()); -} - -TEST_F(DynamicTypesTests, DynamicType_int32_unit_tests) -{ - { - DynamicTypeBuilder_ptr created_builder = DynamicTypeBuilderFactory::get_instance()->create_int32_builder(); - ASSERT_TRUE(created_builder != nullptr); - DynamicType_ptr created_type = DynamicTypeBuilderFactory::get_instance()->create_type(created_builder.get()); - ASSERT_TRUE(created_type != nullptr); - DynamicData* data = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(data != nullptr); - - int32_t test1 = 123; - int32_t test2 = 0; - ASSERT_TRUE(data->set_int32_value(test1, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->get_int32_value(test2, 0) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(data->get_int32_value(test2, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(test1 == test2); - - //ASSERT_FALSE(data->set_int32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_int16_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint16_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_int64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float128_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_char8_value('a', MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_char16_value(L'a', MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_byte_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_bool_value(false, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_string_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_wstring_value(L"", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_enum_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - //int32_t iTest32; - //ASSERT_FALSE(data->get_int32_value(iTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint32_t uTest32; - ASSERT_FALSE(data->get_uint32_value(uTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - int16_t iTest16; - ASSERT_FALSE(data->get_int16_value(iTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint16_t uTest16; - ASSERT_FALSE(data->get_uint16_value(uTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - int64_t iTest64; - ASSERT_FALSE(data->get_int64_value(iTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint64_t uTest64; - ASSERT_FALSE(data->get_uint64_value(uTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - float fTest32; - ASSERT_FALSE(data->get_float32_value(fTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - double fTest64; - ASSERT_FALSE(data->get_float64_value(fTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - long double fTest128; - ASSERT_FALSE(data->get_float128_value(fTest128, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - char cTest8; - ASSERT_FALSE(data->get_char8_value(cTest8, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - wchar_t cTest16; - ASSERT_FALSE(data->get_char16_value(cTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - octet oTest; - ASSERT_FALSE(data->get_byte_value(oTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - bool bTest; - ASSERT_FALSE(data->get_bool_value(bTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::string sTest; - ASSERT_FALSE(data->get_string_value(sTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::wstring wsTest; - ASSERT_FALSE(data->get_wstring_value(wsTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::string sEnumTest; - ASSERT_FALSE(data->get_enum_value(sEnumTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - // Serialize <-> Deserialize Test - DynamicPubSubType pubsubType(created_type); - uint32_t payloadSize = static_cast(pubsubType.getSerializedSizeProvider(data)()); - SerializedPayload_t payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(data, &payload)); - ASSERT_TRUE(payload.length == payloadSize); - types::DynamicData* data2 = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(pubsubType.deserialize(&payload, data2)); - ASSERT_TRUE(data2->equals(data)); - - // SERIALIZATION TEST - LongStruct wlong; - LongStructPubSubType wlongpb; - - SerializedPayload_t dynamic_payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(data, &dynamic_payload)); - ASSERT_TRUE(wlongpb.deserialize(&dynamic_payload, &wlong)); - - uint32_t static_payloadSize = static_cast(wlongpb.getSerializedSizeProvider(&wlong)()); - SerializedPayload_t static_payload(static_payloadSize); - ASSERT_TRUE(wlongpb.serialize(&wlong, &static_payload)); - ASSERT_TRUE(static_payload.length == static_payloadSize); - types::DynamicData* data3 = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(pubsubType.deserialize(&static_payload, data3)); - ASSERT_TRUE(data3->equals(data)); - - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data2) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data3) == ReturnCode_t::RETCODE_OK); - } - ASSERT_TRUE(DynamicTypeBuilderFactory::get_instance()->is_empty()); - ASSERT_TRUE(DynamicDataFactory::get_instance()->is_empty()); -} - -TEST_F(DynamicTypesTests, DynamicType_uint32_unit_tests) -{ - { - DynamicTypeBuilder_ptr created_builder = DynamicTypeBuilderFactory::get_instance()->create_uint32_builder(); - ASSERT_TRUE(created_builder != nullptr); - DynamicType_ptr created_type = DynamicTypeBuilderFactory::get_instance()->create_type(created_builder.get()); - ASSERT_TRUE(created_type != nullptr); - DynamicData* data = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(data != nullptr); - - uint32_t test1 = 123; - uint32_t test2 = 0; - ASSERT_TRUE(data->set_uint32_value(test1, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->get_uint32_value(test2, 0) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(data->get_uint32_value(test2, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(test1 == test2); - - ASSERT_FALSE(data->set_int32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - //ASSERT_FALSE(data->set_uint32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_int16_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint16_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_int64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float128_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_char8_value('a', MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_char16_value(L'a', MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_byte_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_bool_value(false, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_string_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_wstring_value(L"", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_enum_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - int32_t iTest32; - ASSERT_FALSE(data->get_int32_value(iTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - //uint32_t uTest32; - //ASSERT_FALSE(data->get_uint32_value(uTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - int16_t iTest16; - ASSERT_FALSE(data->get_int16_value(iTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint16_t uTest16; - ASSERT_FALSE(data->get_uint16_value(uTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - int64_t iTest64; - ASSERT_FALSE(data->get_int64_value(iTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint64_t uTest64; - ASSERT_FALSE(data->get_uint64_value(uTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - float fTest32; - ASSERT_FALSE(data->get_float32_value(fTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - double fTest64; - ASSERT_FALSE(data->get_float64_value(fTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - long double fTest128; - ASSERT_FALSE(data->get_float128_value(fTest128, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - char cTest8; - ASSERT_FALSE(data->get_char8_value(cTest8, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - wchar_t cTest16; - ASSERT_FALSE(data->get_char16_value(cTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - octet oTest; - ASSERT_FALSE(data->get_byte_value(oTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - bool bTest; - ASSERT_FALSE(data->get_bool_value(bTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::string sTest; - ASSERT_FALSE(data->get_string_value(sTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::wstring wsTest; - ASSERT_FALSE(data->get_wstring_value(wsTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::string sEnumTest; - ASSERT_FALSE(data->get_enum_value(sEnumTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - // Serialize <-> Deserialize Test - DynamicPubSubType pubsubType(created_type); - uint32_t payloadSize = static_cast(pubsubType.getSerializedSizeProvider(data)()); - SerializedPayload_t payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(data, &payload)); - ASSERT_TRUE(payload.length == payloadSize); - types::DynamicData* data2 = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(pubsubType.deserialize(&payload, data2)); - ASSERT_TRUE(data2->equals(data)); - - // SERIALIZATION TEST - ULongStruct wlong; - ULongStructPubSubType wlongpb; - - SerializedPayload_t dynamic_payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(data, &dynamic_payload)); - ASSERT_TRUE(wlongpb.deserialize(&dynamic_payload, &wlong)); - - uint32_t static_payloadSize = static_cast(wlongpb.getSerializedSizeProvider(&wlong)()); - SerializedPayload_t static_payload(static_payloadSize); - ASSERT_TRUE(wlongpb.serialize(&wlong, &static_payload)); - ASSERT_TRUE(static_payload.length == static_payloadSize); - types::DynamicData* data3 = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(pubsubType.deserialize(&static_payload, data3)); - ASSERT_TRUE(data3->equals(data)); - - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data2) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data3) == ReturnCode_t::RETCODE_OK); - } - ASSERT_TRUE(DynamicTypeBuilderFactory::get_instance()->is_empty()); - ASSERT_TRUE(DynamicDataFactory::get_instance()->is_empty()); -} - -TEST_F(DynamicTypesTests, DynamicType_int16_unit_tests) -{ - { - DynamicTypeBuilder_ptr created_builder = DynamicTypeBuilderFactory::get_instance()->create_int16_builder(); - ASSERT_TRUE(created_builder != nullptr); - DynamicType_ptr created_type = DynamicTypeBuilderFactory::get_instance()->create_type(created_builder.get()); - ASSERT_TRUE(created_type != nullptr); - DynamicData* data = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(data != nullptr); - - int16_t test1 = 123; - int16_t test2 = 0; - ASSERT_TRUE(data->set_int16_value(test1, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->get_int16_value(test2, 0) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(data->get_int16_value(test2, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(test1 == test2); - - ASSERT_FALSE(data->set_int32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - //ASSERT_FALSE(data->set_int16_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint16_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_int64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float128_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_char8_value('a', MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_char16_value(L'a', MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_byte_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_bool_value(false, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_string_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_wstring_value(L"", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_enum_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - int32_t iTest32; - ASSERT_FALSE(data->get_int32_value(iTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint32_t uTest32; - ASSERT_FALSE(data->get_uint32_value(uTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - //int16_t iTest16; - //ASSERT_FALSE(data->get_int16_value(iTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint16_t uTest16; - ASSERT_FALSE(data->get_uint16_value(uTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - int64_t iTest64; - ASSERT_FALSE(data->get_int64_value(iTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint64_t uTest64; - ASSERT_FALSE(data->get_uint64_value(uTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - float fTest32; - ASSERT_FALSE(data->get_float32_value(fTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - double fTest64; - ASSERT_FALSE(data->get_float64_value(fTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - long double fTest128; - ASSERT_FALSE(data->get_float128_value(fTest128, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - char cTest8; - ASSERT_FALSE(data->get_char8_value(cTest8, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - wchar_t cTest16; - ASSERT_FALSE(data->get_char16_value(cTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - octet oTest; - ASSERT_FALSE(data->get_byte_value(oTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - bool bTest; - ASSERT_FALSE(data->get_bool_value(bTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::string sTest; - ASSERT_FALSE(data->get_string_value(sTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::wstring wsTest; - ASSERT_FALSE(data->get_wstring_value(wsTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::string sEnumTest; - ASSERT_FALSE(data->get_enum_value(sEnumTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - // Serialize <-> Deserialize Test - DynamicPubSubType pubsubType(created_type); - uint32_t payloadSize = static_cast(pubsubType.getSerializedSizeProvider(data)()); - SerializedPayload_t payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(data, &payload)); - ASSERT_TRUE(payload.length == payloadSize); - types::DynamicData* data2 = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(pubsubType.deserialize(&payload, data2)); - ASSERT_TRUE(data2->equals(data)); - - // SERIALIZATION TEST - ShortStruct wshort; - ShortStructPubSubType wshortpb; - - SerializedPayload_t dynamic_payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(data, &dynamic_payload)); - ASSERT_TRUE(wshortpb.deserialize(&dynamic_payload, &wshort)); - - uint32_t static_payloadSize = static_cast(wshortpb.getSerializedSizeProvider(&wshort)()); - SerializedPayload_t static_payload(static_payloadSize); - ASSERT_TRUE(wshortpb.serialize(&wshort, &static_payload)); - ASSERT_TRUE(static_payload.length == static_payloadSize); - types::DynamicData* data3 = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(pubsubType.deserialize(&static_payload, data3)); - ASSERT_TRUE(data3->equals(data)); - - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data2) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data3) == ReturnCode_t::RETCODE_OK); - } - ASSERT_TRUE(DynamicTypeBuilderFactory::get_instance()->is_empty()); - ASSERT_TRUE(DynamicDataFactory::get_instance()->is_empty()); -} - -TEST_F(DynamicTypesTests, DynamicType_uint16_unit_tests) -{ - { - DynamicTypeBuilder_ptr created_builder = DynamicTypeBuilderFactory::get_instance()->create_uint16_builder(); - ASSERT_TRUE(created_builder != nullptr); - DynamicType_ptr created_type = DynamicTypeBuilderFactory::get_instance()->create_type(created_builder.get()); - ASSERT_TRUE(created_type != nullptr); - DynamicData* data = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(data != nullptr); - - uint16_t test1 = 123; - uint16_t test2 = 0; - ASSERT_TRUE(data->set_uint16_value(test1, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->get_uint16_value(test2, 0) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(data->get_uint16_value(test2, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(test1 == test2); - - ASSERT_FALSE(data->set_int32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_int16_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - //ASSERT_FALSE(data->set_uint16_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_int64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float128_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_char8_value('a', MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_char16_value(L'a', MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_byte_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_bool_value(false, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_string_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_wstring_value(L"", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_enum_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - int32_t iTest32; - ASSERT_FALSE(data->get_int32_value(iTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint32_t uTest32; - ASSERT_FALSE(data->get_uint32_value(uTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - int16_t iTest16; - ASSERT_FALSE(data->get_int16_value(iTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - //uint16_t uTest16; - //ASSERT_FALSE(data->get_uint16_value(uTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - int64_t iTest64; - ASSERT_FALSE(data->get_int64_value(iTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint64_t uTest64; - ASSERT_FALSE(data->get_uint64_value(uTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - float fTest32; - ASSERT_FALSE(data->get_float32_value(fTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - double fTest64; - ASSERT_FALSE(data->get_float64_value(fTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - long double fTest128; - ASSERT_FALSE(data->get_float128_value(fTest128, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - char cTest8; - ASSERT_FALSE(data->get_char8_value(cTest8, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - wchar_t cTest16; - ASSERT_FALSE(data->get_char16_value(cTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - octet oTest; - ASSERT_FALSE(data->get_byte_value(oTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - bool bTest; - ASSERT_FALSE(data->get_bool_value(bTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::string sTest; - ASSERT_FALSE(data->get_string_value(sTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::wstring wsTest; - ASSERT_FALSE(data->get_wstring_value(wsTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::string sEnumTest; - ASSERT_FALSE(data->get_enum_value(sEnumTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - // Serialize <-> Deserialize Test - DynamicPubSubType pubsubType(created_type); - uint32_t payloadSize = static_cast(pubsubType.getSerializedSizeProvider(data)()); - SerializedPayload_t payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(data, &payload)); - ASSERT_TRUE(payload.length == payloadSize); - types::DynamicData* data2 = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(pubsubType.deserialize(&payload, data2)); - ASSERT_TRUE(data2->equals(data)); - - // SERIALIZATION TEST - UShortStruct wshort; - UShortStructPubSubType wshortpb; - - SerializedPayload_t dynamic_payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(data, &dynamic_payload)); - ASSERT_TRUE(wshortpb.deserialize(&dynamic_payload, &wshort)); - - uint32_t static_payloadSize = static_cast(wshortpb.getSerializedSizeProvider(&wshort)()); - SerializedPayload_t static_payload(static_payloadSize); - ASSERT_TRUE(wshortpb.serialize(&wshort, &static_payload)); - ASSERT_TRUE(static_payload.length == static_payloadSize); - types::DynamicData* data3 = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(pubsubType.deserialize(&static_payload, data3)); - ASSERT_TRUE(data3->equals(data)); - - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data2) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data3) == ReturnCode_t::RETCODE_OK); - } - ASSERT_TRUE(DynamicTypeBuilderFactory::get_instance()->is_empty()); - ASSERT_TRUE(DynamicDataFactory::get_instance()->is_empty()); -} - -TEST_F(DynamicTypesTests, DynamicType_int64_unit_tests) -{ - { - DynamicTypeBuilder_ptr created_builder = DynamicTypeBuilderFactory::get_instance()->create_int64_builder(); - ASSERT_TRUE(created_builder != nullptr); - DynamicType_ptr created_type = DynamicTypeBuilderFactory::get_instance()->create_type(created_builder.get()); - ASSERT_TRUE(created_type != nullptr); - DynamicData* data = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(data != nullptr); - - int64_t test1 = 123; - int64_t test2 = 0; - ASSERT_TRUE(data->set_int64_value(test1, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->get_int64_value(test2, 0) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(data->get_int64_value(test2, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(test1 == test2); - - ASSERT_FALSE(data->set_int32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_int16_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint16_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - //ASSERT_FALSE(data->set_int64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float128_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_char8_value('a', MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_char16_value(L'a', MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_byte_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_bool_value(false, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_string_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_wstring_value(L"", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_enum_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - int32_t iTest32; - ASSERT_FALSE(data->get_int32_value(iTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint32_t uTest32; - ASSERT_FALSE(data->get_uint32_value(uTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - int16_t iTest16; - ASSERT_FALSE(data->get_int16_value(iTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint16_t uTest16; - ASSERT_FALSE(data->get_uint16_value(uTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - //int64_t iTest64; - //ASSERT_FALSE(data->get_int64_value(iTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint64_t uTest64; - ASSERT_FALSE(data->get_uint64_value(uTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - float fTest32; - ASSERT_FALSE(data->get_float32_value(fTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - double fTest64; - ASSERT_FALSE(data->get_float64_value(fTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - long double fTest128; - ASSERT_FALSE(data->get_float128_value(fTest128, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - char cTest8; - ASSERT_FALSE(data->get_char8_value(cTest8, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - wchar_t cTest16; - ASSERT_FALSE(data->get_char16_value(cTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - octet oTest; - ASSERT_FALSE(data->get_byte_value(oTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - bool bTest; - ASSERT_FALSE(data->get_bool_value(bTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::string sTest; - ASSERT_FALSE(data->get_string_value(sTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::wstring wsTest; - ASSERT_FALSE(data->get_wstring_value(wsTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::string sEnumTest; - ASSERT_FALSE(data->get_enum_value(sEnumTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - // Serialize <-> Deserialize Test - DynamicPubSubType pubsubType(created_type); - uint32_t payloadSize = static_cast(pubsubType.getSerializedSizeProvider(data)()); - SerializedPayload_t payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(data, &payload)); - ASSERT_TRUE(payload.length == payloadSize); - types::DynamicData* data2 = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(pubsubType.deserialize(&payload, data2)); - ASSERT_TRUE(data2->equals(data)); - - // SERIALIZATION TEST - LongLongStruct wlonglong; - LongLongStructPubSubType wlonglongpb; - - SerializedPayload_t dynamic_payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(data, &dynamic_payload)); - ASSERT_TRUE(wlonglongpb.deserialize(&dynamic_payload, &wlonglong)); - - uint32_t static_payloadSize = static_cast(wlonglongpb.getSerializedSizeProvider(&wlonglong)()); - SerializedPayload_t static_payload(static_payloadSize); - ASSERT_TRUE(wlonglongpb.serialize(&wlonglong, &static_payload)); - ASSERT_TRUE(static_payload.length == static_payloadSize); - types::DynamicData* data3 = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(pubsubType.deserialize(&static_payload, data3)); - ASSERT_TRUE(data3->equals(data)); - - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data2) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data3) == ReturnCode_t::RETCODE_OK); - } - ASSERT_TRUE(DynamicTypeBuilderFactory::get_instance()->is_empty()); - ASSERT_TRUE(DynamicDataFactory::get_instance()->is_empty()); -} - -TEST_F(DynamicTypesTests, DynamicType_uint64_unit_tests) -{ - { - DynamicTypeBuilder_ptr created_builder = DynamicTypeBuilderFactory::get_instance()->create_uint64_builder(); - ASSERT_TRUE(created_builder != nullptr); - DynamicType_ptr created_type = DynamicTypeBuilderFactory::get_instance()->create_type(created_builder.get()); - ASSERT_TRUE(created_type != nullptr); - DynamicData* data = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(data != nullptr); - - uint64_t test1 = 123; - uint64_t test2 = 0; - ASSERT_TRUE(data->set_uint64_value(test1, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->get_uint64_value(test2, 0) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(data->get_uint64_value(test2, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(test1 == test2); - - ASSERT_FALSE(data->set_int32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_int16_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint16_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_int64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - //ASSERT_FALSE(data->set_uint64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float128_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_char8_value('a', MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_char16_value(L'a', MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_byte_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_bool_value(false, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_string_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_wstring_value(L"", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_enum_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - int32_t iTest32; - ASSERT_FALSE(data->get_int32_value(iTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint32_t uTest32; - ASSERT_FALSE(data->get_uint32_value(uTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - int16_t iTest16; - ASSERT_FALSE(data->get_int16_value(iTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint16_t uTest16; - ASSERT_FALSE(data->get_uint16_value(uTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - int64_t iTest64; - ASSERT_FALSE(data->get_int64_value(iTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - //uint64_t uTest64; - //ASSERT_FALSE(data->get_uint64_value(uTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - float fTest32; - ASSERT_FALSE(data->get_float32_value(fTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - double fTest64; - ASSERT_FALSE(data->get_float64_value(fTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - long double fTest128; - ASSERT_FALSE(data->get_float128_value(fTest128, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - char cTest8; - ASSERT_FALSE(data->get_char8_value(cTest8, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - wchar_t cTest16; - ASSERT_FALSE(data->get_char16_value(cTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - octet oTest; - ASSERT_FALSE(data->get_byte_value(oTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - bool bTest; - ASSERT_FALSE(data->get_bool_value(bTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::string sTest; - ASSERT_FALSE(data->get_string_value(sTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::wstring wsTest; - ASSERT_FALSE(data->get_wstring_value(wsTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::string sEnumTest; - ASSERT_FALSE(data->get_enum_value(sEnumTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - // Serialize <-> Deserialize Test - DynamicPubSubType pubsubType(created_type); - uint32_t payloadSize = static_cast(pubsubType.getSerializedSizeProvider(data)()); - SerializedPayload_t payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(data, &payload)); - ASSERT_TRUE(payload.length == payloadSize); - types::DynamicData* data2 = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(pubsubType.deserialize(&payload, data2)); - ASSERT_TRUE(data2->equals(data)); - - // SERIALIZATION TEST - ULongLongStruct wlonglong; - ULongLongStructPubSubType wlonglongpb; - - SerializedPayload_t dynamic_payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(data, &dynamic_payload)); - ASSERT_TRUE(wlonglongpb.deserialize(&dynamic_payload, &wlonglong)); - - uint32_t static_payloadSize = static_cast(wlonglongpb.getSerializedSizeProvider(&wlonglong)()); - SerializedPayload_t static_payload(static_payloadSize); - ASSERT_TRUE(wlonglongpb.serialize(&wlonglong, &static_payload)); - ASSERT_TRUE(static_payload.length == static_payloadSize); - types::DynamicData* data3 = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(pubsubType.deserialize(&static_payload, data3)); - ASSERT_TRUE(data3->equals(data)); - - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data2) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data3) == ReturnCode_t::RETCODE_OK); - } - ASSERT_TRUE(DynamicTypeBuilderFactory::get_instance()->is_empty()); - ASSERT_TRUE(DynamicDataFactory::get_instance()->is_empty()); -} - -TEST_F(DynamicTypesTests, DynamicType_float32_unit_tests) -{ - { - DynamicTypeBuilder_ptr created_builder = DynamicTypeBuilderFactory::get_instance()->create_float32_builder(); - ASSERT_TRUE(created_builder != nullptr); - DynamicType_ptr created_type = DynamicTypeBuilderFactory::get_instance()->create_type(created_builder.get()); - ASSERT_TRUE(created_type != nullptr); - DynamicData* data = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(data != nullptr); - - float test1 = 123.0f; - float test2 = 0.0f; - ASSERT_TRUE(data->set_float32_value(test1, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->get_float32_value(test2, 0) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(data->get_float32_value(test2, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(test1 == test2); - - ASSERT_FALSE(data->set_int32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_int16_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint16_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_int64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - //ASSERT_FALSE(data->set_float32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float128_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_char8_value('a', MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_char16_value(L'a', MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_byte_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_bool_value(false, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_string_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_wstring_value(L"", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_enum_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - int32_t iTest32; - ASSERT_FALSE(data->get_int32_value(iTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint32_t uTest32; - ASSERT_FALSE(data->get_uint32_value(uTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - int16_t iTest16; - ASSERT_FALSE(data->get_int16_value(iTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint16_t uTest16; - ASSERT_FALSE(data->get_uint16_value(uTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - int64_t iTest64; - ASSERT_FALSE(data->get_int64_value(iTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint64_t uTest64; - ASSERT_FALSE(data->get_uint64_value(uTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - //float fTest32; - //ASSERT_FALSE(data->get_float32_value(fTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - double fTest64; - ASSERT_FALSE(data->get_float64_value(fTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - long double fTest128; - ASSERT_FALSE(data->get_float128_value(fTest128, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - char cTest8; - ASSERT_FALSE(data->get_char8_value(cTest8, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - wchar_t cTest16; - ASSERT_FALSE(data->get_char16_value(cTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - octet oTest; - ASSERT_FALSE(data->get_byte_value(oTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - bool bTest; - ASSERT_FALSE(data->get_bool_value(bTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::string sTest; - ASSERT_FALSE(data->get_string_value(sTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::wstring wsTest; - ASSERT_FALSE(data->get_wstring_value(wsTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::string sEnumTest; - ASSERT_FALSE(data->get_enum_value(sEnumTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - // Serialize <-> Deserialize Test - DynamicPubSubType pubsubType(created_type); - uint32_t payloadSize = static_cast(pubsubType.getSerializedSizeProvider(data)()); - SerializedPayload_t payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(data, &payload)); - ASSERT_TRUE(payload.length == payloadSize); - types::DynamicData* data2 = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(pubsubType.deserialize(&payload, data2)); - ASSERT_TRUE(data2->equals(data)); - - // SERIALIZATION TEST - FloatStruct wfloat; - FloatStructPubSubType wfloatpb; - - SerializedPayload_t dynamic_payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(data, &dynamic_payload)); - ASSERT_TRUE(wfloatpb.deserialize(&dynamic_payload, &wfloat)); - - uint32_t static_payloadSize = static_cast(wfloatpb.getSerializedSizeProvider(&wfloat)()); - SerializedPayload_t static_payload(static_payloadSize); - ASSERT_TRUE(wfloatpb.serialize(&wfloat, &static_payload)); - ASSERT_TRUE(static_payload.length == static_payloadSize); - types::DynamicData* data3 = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(pubsubType.deserialize(&static_payload, data3)); - ASSERT_TRUE(data3->equals(data)); - - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data2) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data3) == ReturnCode_t::RETCODE_OK); - } - - ASSERT_TRUE(DynamicTypeBuilderFactory::get_instance()->is_empty()); - ASSERT_TRUE(DynamicDataFactory::get_instance()->is_empty()); -} - -TEST_F(DynamicTypesTests, DynamicType_float64_unit_tests) -{ - { - DynamicTypeBuilder_ptr created_builder = DynamicTypeBuilderFactory::get_instance()->create_float64_builder(); - ASSERT_TRUE(created_builder != nullptr); - DynamicType_ptr created_type = DynamicTypeBuilderFactory::get_instance()->create_type(created_builder.get()); - ASSERT_TRUE(created_type != nullptr); - DynamicData* data = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(data != nullptr); - - double test1 = 123.0; - double test2 = 0.0; - ASSERT_TRUE(data->set_float64_value(test1, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->get_float64_value(test2, 0) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(data->get_float64_value(test2, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(test1 == test2); - - ASSERT_FALSE(data->set_int32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_int16_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint16_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_int64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - //ASSERT_FALSE(data->set_float64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float128_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_char8_value('a', MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_char16_value(L'a', MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_byte_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_bool_value(false, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_string_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_wstring_value(L"", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_enum_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - int32_t iTest32; - ASSERT_FALSE(data->get_int32_value(iTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint32_t uTest32; - ASSERT_FALSE(data->get_uint32_value(uTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - int16_t iTest16; - ASSERT_FALSE(data->get_int16_value(iTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint16_t uTest16; - ASSERT_FALSE(data->get_uint16_value(uTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - int64_t iTest64; - ASSERT_FALSE(data->get_int64_value(iTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint64_t uTest64; - ASSERT_FALSE(data->get_uint64_value(uTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - float fTest32; - ASSERT_FALSE(data->get_float32_value(fTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - //double fTest64; - //ASSERT_FALSE(data->get_float64_value(fTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - long double fTest128; - ASSERT_FALSE(data->get_float128_value(fTest128, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - char cTest8; - ASSERT_FALSE(data->get_char8_value(cTest8, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - wchar_t cTest16; - ASSERT_FALSE(data->get_char16_value(cTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - octet oTest; - ASSERT_FALSE(data->get_byte_value(oTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - bool bTest; - ASSERT_FALSE(data->get_bool_value(bTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::string sTest; - ASSERT_FALSE(data->get_string_value(sTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::wstring wsTest; - ASSERT_FALSE(data->get_wstring_value(wsTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::string sEnumTest; - ASSERT_FALSE(data->get_enum_value(sEnumTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - // Serialize <-> Deserialize Test - DynamicPubSubType pubsubType(created_type); - uint32_t payloadSize = static_cast(pubsubType.getSerializedSizeProvider(data)()); - SerializedPayload_t payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(data, &payload)); - ASSERT_TRUE(payload.length == payloadSize); - types::DynamicData* data2 = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(pubsubType.deserialize(&payload, data2)); - ASSERT_TRUE(data2->equals(data)); - - // SERIALIZATION TEST - DoubleStruct wdouble; - DoubleStructPubSubType wdoublepb; - - SerializedPayload_t dynamic_payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(data, &dynamic_payload)); - ASSERT_TRUE(wdoublepb.deserialize(&dynamic_payload, &wdouble)); - - uint32_t static_payloadSize = static_cast(wdoublepb.getSerializedSizeProvider(&wdouble)()); - SerializedPayload_t static_payload(static_payloadSize); - ASSERT_TRUE(wdoublepb.serialize(&wdouble, &static_payload)); - ASSERT_TRUE(static_payload.length == static_payloadSize); - types::DynamicData* data3 = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(pubsubType.deserialize(&static_payload, data3)); - ASSERT_TRUE(data3->equals(data)); - - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data2) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data3) == ReturnCode_t::RETCODE_OK); - } - - ASSERT_TRUE(DynamicTypeBuilderFactory::get_instance()->is_empty()); - ASSERT_TRUE(DynamicDataFactory::get_instance()->is_empty()); -} - -TEST_F(DynamicTypesTests, DynamicType_float128_unit_tests) -{ - { - DynamicTypeBuilder_ptr created_builder = DynamicTypeBuilderFactory::get_instance()->create_float128_builder(); - ASSERT_TRUE(created_builder != nullptr); - DynamicType_ptr created_type = DynamicTypeBuilderFactory::get_instance()->create_type(created_builder.get()); - ASSERT_TRUE(created_type != nullptr); - DynamicData* data = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(data != nullptr); - - long double test1 = 123.0; - long double test2 = 0.0; - ASSERT_TRUE(data->set_float128_value(test1, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->get_float128_value(test2, 0) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(data->get_float128_value(test2, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(test1 == test2); - - ASSERT_FALSE(data->set_int32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_int16_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint16_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_int64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - //ASSERT_FALSE(data->set_float128_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_char8_value('a', MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_char16_value(L'a', MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_byte_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_bool_value(false, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_string_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_wstring_value(L"", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_enum_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - int32_t iTest32; - ASSERT_FALSE(data->get_int32_value(iTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint32_t uTest32; - ASSERT_FALSE(data->get_uint32_value(uTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - int16_t iTest16; - ASSERT_FALSE(data->get_int16_value(iTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint16_t uTest16; - ASSERT_FALSE(data->get_uint16_value(uTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - int64_t iTest64; - ASSERT_FALSE(data->get_int64_value(iTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint64_t uTest64; - ASSERT_FALSE(data->get_uint64_value(uTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - float fTest32; - ASSERT_FALSE(data->get_float32_value(fTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - double fTest64; - ASSERT_FALSE(data->get_float64_value(fTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - //long double fTest128; - //ASSERT_FALSE(data->get_float128_value(fTest128, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - char cTest8; - ASSERT_FALSE(data->get_char8_value(cTest8, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - wchar_t cTest16; - ASSERT_FALSE(data->get_char16_value(cTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - octet oTest; - ASSERT_FALSE(data->get_byte_value(oTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - bool bTest; - ASSERT_FALSE(data->get_bool_value(bTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::string sTest; - ASSERT_FALSE(data->get_string_value(sTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::wstring wsTest; - ASSERT_FALSE(data->get_wstring_value(wsTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::string sEnumTest; - ASSERT_FALSE(data->get_enum_value(sEnumTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - // Serialize <-> Deserialize Test - DynamicPubSubType pubsubType(created_type); - uint32_t payloadSize = static_cast(pubsubType.getSerializedSizeProvider(data)()); - SerializedPayload_t payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(data, &payload)); - ASSERT_TRUE(payload.length == payloadSize); - types::DynamicData* data2 = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(pubsubType.deserialize(&payload, data2)); - ASSERT_TRUE(data2->equals(data)); - - // SERIALIZATION TEST - LongDoubleStruct wldouble; - LongDoubleStructPubSubType wldoublepb; - - SerializedPayload_t dynamic_payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(data, &dynamic_payload)); - ASSERT_TRUE(wldoublepb.deserialize(&dynamic_payload, &wldouble)); - - uint32_t static_payloadSize = static_cast(wldoublepb.getSerializedSizeProvider(&wldouble)()); - SerializedPayload_t static_payload(static_payloadSize); - ASSERT_TRUE(wldoublepb.serialize(&wldouble, &static_payload)); - ASSERT_TRUE(static_payload.length == static_payloadSize); - types::DynamicData* data3 = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(pubsubType.deserialize(&static_payload, data3)); - ASSERT_TRUE(data3->equals(data)); - - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data2) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data3) == ReturnCode_t::RETCODE_OK); - } - ASSERT_TRUE(DynamicTypeBuilderFactory::get_instance()->is_empty()); - ASSERT_TRUE(DynamicDataFactory::get_instance()->is_empty()); -} - -TEST_F(DynamicTypesTests, DynamicType_char8_unit_tests) -{ - { - DynamicTypeBuilder_ptr created_builder = DynamicTypeBuilderFactory::get_instance()->create_char8_builder(); - ASSERT_TRUE(created_builder != nullptr); - DynamicType_ptr created_type = DynamicTypeBuilderFactory::get_instance()->create_type(created_builder.get()); - ASSERT_TRUE(created_type != nullptr); - DynamicData* data = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(data != nullptr); - - char test1 = 'a'; - char test2 = 'b'; - ASSERT_TRUE(data->set_char8_value(test1, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->get_char8_value(test2, 0) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(data->get_char8_value(test2, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(test1 == test2); - - ASSERT_FALSE(data->set_int32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_int16_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint16_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_int64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float128_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - //ASSERT_FALSE(data->set_char8_value('a', MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_char16_value(L'a', MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_byte_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_bool_value(false, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_string_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_wstring_value(L"", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_enum_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - int32_t iTest32; - ASSERT_FALSE(data->get_int32_value(iTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint32_t uTest32; - ASSERT_FALSE(data->get_uint32_value(uTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - int16_t iTest16; - ASSERT_FALSE(data->get_int16_value(iTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint16_t uTest16; - ASSERT_FALSE(data->get_uint16_value(uTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - int64_t iTest64; - ASSERT_FALSE(data->get_int64_value(iTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint64_t uTest64; - ASSERT_FALSE(data->get_uint64_value(uTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - float fTest32; - ASSERT_FALSE(data->get_float32_value(fTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - double fTest64; - ASSERT_FALSE(data->get_float64_value(fTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - long double fTest128; - ASSERT_FALSE(data->get_float128_value(fTest128, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - //char cTest8; - //ASSERT_FALSE(data->get_char8_value(cTest8, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - wchar_t cTest16; - ASSERT_FALSE(data->get_char16_value(cTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - octet oTest; - ASSERT_FALSE(data->get_byte_value(oTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - bool bTest; - ASSERT_FALSE(data->get_bool_value(bTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::string sTest; - ASSERT_FALSE(data->get_string_value(sTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::wstring wsTest; - ASSERT_FALSE(data->get_wstring_value(wsTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::string sEnumTest; - ASSERT_FALSE(data->get_enum_value(sEnumTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - // Serialize <-> Deserialize Test - DynamicPubSubType pubsubType(created_type); - uint32_t payloadSize = static_cast(pubsubType.getSerializedSizeProvider(data)()); - SerializedPayload_t payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(data, &payload)); - ASSERT_TRUE(payload.length == payloadSize); - types::DynamicData* data2 = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(pubsubType.deserialize(&payload, data2)); - ASSERT_TRUE(data2->equals(data)); - - // SERIALIZATION TEST - CharStruct wchar; - CharStructPubSubType wcharpb; - - SerializedPayload_t dynamic_payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(data, &dynamic_payload)); - ASSERT_TRUE(wcharpb.deserialize(&dynamic_payload, &wchar)); - - uint32_t static_payloadSize = static_cast(wcharpb.getSerializedSizeProvider(&wchar)()); - SerializedPayload_t static_payload(static_payloadSize); - ASSERT_TRUE(wcharpb.serialize(&wchar, &static_payload)); - ASSERT_TRUE(static_payload.length == static_payloadSize); - types::DynamicData* data3 = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(pubsubType.deserialize(&static_payload, data3)); - ASSERT_TRUE(data3->equals(data)); - - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data2) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data3) == ReturnCode_t::RETCODE_OK); - } - - ASSERT_TRUE(DynamicTypeBuilderFactory::get_instance()->is_empty()); - ASSERT_TRUE(DynamicDataFactory::get_instance()->is_empty()); -} - -#if FASTCDR_VERSION_MAJOR == 1 -TEST_F(DynamicTypesTests, DynamicType_char16_unit_tests) -{ - { - DynamicTypeBuilder_ptr created_builder = DynamicTypeBuilderFactory::get_instance()->create_char16_builder(); - ASSERT_TRUE(created_builder != nullptr); - DynamicType_ptr created_type = DynamicTypeBuilderFactory::get_instance()->create_type(created_builder.get()); - ASSERT_TRUE(created_type != nullptr); - DynamicData* data = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(data != nullptr); - - wchar_t test1 = L'a'; - wchar_t test2 = L'b'; - ASSERT_TRUE(data->set_char16_value(test1, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->get_char16_value(test2, 0) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(data->get_char16_value(test2, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(test1 == test2); - - ASSERT_FALSE(data->set_int32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_int16_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint16_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_int64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float128_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_char8_value('a', MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - //ASSERT_FALSE(data->set_char16_value(L'a', MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_byte_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_bool_value(false, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_string_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_wstring_value(L"", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_enum_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - int32_t iTest32; - ASSERT_FALSE(data->get_int32_value(iTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint32_t uTest32; - ASSERT_FALSE(data->get_uint32_value(uTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - int16_t iTest16; - ASSERT_FALSE(data->get_int16_value(iTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint16_t uTest16; - ASSERT_FALSE(data->get_uint16_value(uTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - int64_t iTest64; - ASSERT_FALSE(data->get_int64_value(iTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint64_t uTest64; - ASSERT_FALSE(data->get_uint64_value(uTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - float fTest32; - ASSERT_FALSE(data->get_float32_value(fTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - double fTest64; - ASSERT_FALSE(data->get_float64_value(fTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - long double fTest128; - ASSERT_FALSE(data->get_float128_value(fTest128, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - char cTest8; - ASSERT_FALSE(data->get_char8_value(cTest8, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - //wchar_t cTest16; - //ASSERT_FALSE(data->get_char16_value(cTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - octet oTest; - ASSERT_FALSE(data->get_byte_value(oTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - bool bTest; - ASSERT_FALSE(data->get_bool_value(bTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::string sTest; - ASSERT_FALSE(data->get_string_value(sTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::wstring wsTest; - ASSERT_FALSE(data->get_wstring_value(wsTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::string sEnumTest; - ASSERT_FALSE(data->get_enum_value(sEnumTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - // Serialize <-> Deserialize Test - DynamicPubSubType pubsubType(created_type); - uint32_t payloadSize = static_cast(pubsubType.getSerializedSizeProvider(data)()); - SerializedPayload_t payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(data, &payload)); - ASSERT_TRUE(payload.length == payloadSize); - - types::DynamicData* data2 = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(pubsubType.deserialize(&payload, data2)); - ASSERT_TRUE(data2->equals(data)); - - // SERIALIZATION TEST - WCharStruct wchar; - WCharStructPubSubType wcharpb; - - SerializedPayload_t dynamic_payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(data, &dynamic_payload)); - ASSERT_TRUE(wcharpb.deserialize(&dynamic_payload, &wchar)); - - uint32_t static_payloadSize = static_cast(wcharpb.getSerializedSizeProvider(&wchar)()); - SerializedPayload_t static_payload(static_payloadSize); - ASSERT_TRUE(wcharpb.serialize(&wchar, &static_payload)); - ASSERT_TRUE(static_payload.length == static_payloadSize); - types::DynamicData* data3 = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(pubsubType.deserialize(&static_payload, data3)); - ASSERT_TRUE(data3->equals(data)); - - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data2) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data3) == ReturnCode_t::RETCODE_OK); - } - ASSERT_TRUE(DynamicTypeBuilderFactory::get_instance()->is_empty()); - ASSERT_TRUE(DynamicDataFactory::get_instance()->is_empty()); -} -#endif // if FASTCDR_VERSION_MAJOR == 1 - -TEST_F(DynamicTypesTests, DynamicType_byte_unit_tests) -{ - { - DynamicTypeBuilder_ptr created_builder = DynamicTypeBuilderFactory::get_instance()->create_byte_builder(); - ASSERT_TRUE(created_builder != nullptr); - DynamicType_ptr created_type = DynamicTypeBuilderFactory::get_instance()->create_type(created_builder.get()); - ASSERT_TRUE(created_type != nullptr); - DynamicData* data = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(data != nullptr); - - octet test1 = 255; - octet test2 = 0; - ASSERT_TRUE(data->set_byte_value(test1, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->get_byte_value(test2, 0) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(data->get_byte_value(test2, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(test1 == test2); - - ASSERT_FALSE(data->set_int32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_int16_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint16_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_int64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float128_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_char8_value('a', MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_char16_value(L'a', MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - //ASSERT_FALSE(data->set_byte_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_bool_value(false, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_string_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_wstring_value(L"", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_enum_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - int32_t iTest32; - ASSERT_FALSE(data->get_int32_value(iTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint32_t uTest32; - ASSERT_FALSE(data->get_uint32_value(uTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - int16_t iTest16; - ASSERT_FALSE(data->get_int16_value(iTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint16_t uTest16; - ASSERT_FALSE(data->get_uint16_value(uTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - int64_t iTest64; - ASSERT_FALSE(data->get_int64_value(iTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint64_t uTest64; - ASSERT_FALSE(data->get_uint64_value(uTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - float fTest32; - ASSERT_FALSE(data->get_float32_value(fTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - double fTest64; - ASSERT_FALSE(data->get_float64_value(fTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - long double fTest128; - ASSERT_FALSE(data->get_float128_value(fTest128, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - char cTest8; - ASSERT_FALSE(data->get_char8_value(cTest8, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - wchar_t cTest16; - ASSERT_FALSE(data->get_char16_value(cTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - //octet oTest; - //ASSERT_FALSE(data->get_byte_value(oTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - bool bTest; - ASSERT_FALSE(data->get_bool_value(bTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::string sTest; - ASSERT_FALSE(data->get_string_value(sTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::wstring wsTest; - ASSERT_FALSE(data->get_wstring_value(wsTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::string sEnumTest; - ASSERT_FALSE(data->get_enum_value(sEnumTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - // Serialize <-> Deserialize Test - DynamicPubSubType pubsubType(created_type); - uint32_t payloadSize = static_cast(pubsubType.getSerializedSizeProvider(data)()); - SerializedPayload_t payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(data, &payload)); - ASSERT_TRUE(payload.length == payloadSize); - types::DynamicData* data2 = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(pubsubType.deserialize(&payload, data2)); - ASSERT_TRUE(data2->equals(data)); - - // SERIALIZATION TEST - OctetStruct wchar; - OctetStructPubSubType wcharpb; - - SerializedPayload_t dynamic_payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(data, &dynamic_payload)); - ASSERT_TRUE(wcharpb.deserialize(&dynamic_payload, &wchar)); - - uint32_t static_payloadSize = static_cast(wcharpb.getSerializedSizeProvider(&wchar)()); - SerializedPayload_t static_payload(static_payloadSize); - ASSERT_TRUE(wcharpb.serialize(&wchar, &static_payload)); - ASSERT_TRUE(static_payload.length == static_payloadSize); - types::DynamicData* data3 = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(pubsubType.deserialize(&static_payload, data3)); - ASSERT_TRUE(data3->equals(data)); - - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data2) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data3) == ReturnCode_t::RETCODE_OK); - } - ASSERT_TRUE(DynamicTypeBuilderFactory::get_instance()->is_empty()); - ASSERT_TRUE(DynamicDataFactory::get_instance()->is_empty()); -} - -TEST_F(DynamicTypesTests, DynamicType_bool_unit_tests) -{ - { - DynamicTypeBuilder_ptr created_builder = DynamicTypeBuilderFactory::get_instance()->create_bool_builder(); - ASSERT_TRUE(created_builder != nullptr); - DynamicType_ptr created_type = DynamicTypeBuilderFactory::get_instance()->create_type(created_builder.get()); - ASSERT_TRUE(created_type != nullptr); - DynamicData* data = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(data != nullptr); - - bool test1 = true; - bool test2 = false; - ASSERT_TRUE(data->set_bool_value(test1, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->get_bool_value(test2, 0) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(data->get_bool_value(test2, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(test1 == test2); - - ASSERT_FALSE(data->set_int32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_int16_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint16_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_int64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float128_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_char8_value('a', MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_char16_value(L'a', MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_byte_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - //ASSERT_FALSE(data->set_bool_value(false, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_string_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_wstring_value(L"", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_enum_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - int32_t iTest32; - ASSERT_FALSE(data->get_int32_value(iTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint32_t uTest32; - ASSERT_FALSE(data->get_uint32_value(uTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - int16_t iTest16; - ASSERT_FALSE(data->get_int16_value(iTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint16_t uTest16; - ASSERT_FALSE(data->get_uint16_value(uTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - int64_t iTest64; - ASSERT_FALSE(data->get_int64_value(iTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint64_t uTest64; - ASSERT_FALSE(data->get_uint64_value(uTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - float fTest32; - ASSERT_FALSE(data->get_float32_value(fTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - double fTest64; - ASSERT_FALSE(data->get_float64_value(fTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - long double fTest128; - ASSERT_FALSE(data->get_float128_value(fTest128, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - char cTest8; - ASSERT_FALSE(data->get_char8_value(cTest8, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - wchar_t cTest16; - ASSERT_FALSE(data->get_char16_value(cTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - octet oTest; - ASSERT_FALSE(data->get_byte_value(oTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - //bool bTest; - //ASSERT_FALSE(data->get_bool_value(bTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::string sTest; - ASSERT_FALSE(data->get_string_value(sTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::wstring wsTest; - ASSERT_FALSE(data->get_wstring_value(wsTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::string sEnumTest; - ASSERT_FALSE(data->get_enum_value(sEnumTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - // Serialize <-> Deserialize Test - DynamicPubSubType pubsubType(created_type); - uint32_t payloadSize = static_cast(pubsubType.getSerializedSizeProvider(data)()); - SerializedPayload_t payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(data, &payload)); - ASSERT_TRUE(payload.length == payloadSize); - types::DynamicData* data2 = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(pubsubType.deserialize(&payload, data2)); - ASSERT_TRUE(data2->equals(data)); - - // SERIALIZATION TEST - BoolStruct wbool; - BoolStructPubSubType wboolpb; - - SerializedPayload_t dynamic_payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(data, &dynamic_payload)); - ASSERT_TRUE(wboolpb.deserialize(&dynamic_payload, &wbool)); - - uint32_t static_payloadSize = static_cast(wboolpb.getSerializedSizeProvider(&wbool)()); - SerializedPayload_t static_payload(static_payloadSize); - ASSERT_TRUE(wboolpb.serialize(&wbool, &static_payload)); - ASSERT_TRUE(static_payload.length == static_payloadSize); - types::DynamicData* data3 = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(pubsubType.deserialize(&static_payload, data3)); - ASSERT_TRUE(data3->equals(data)); - - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data2) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data3) == ReturnCode_t::RETCODE_OK); - } - ASSERT_TRUE(DynamicTypeBuilderFactory::get_instance()->is_empty()); - ASSERT_TRUE(DynamicDataFactory::get_instance()->is_empty()); -} - -TEST_F(DynamicTypesTests, DynamicType_enum_unit_tests) -{ - { - DynamicTypeBuilder_ptr created_builder = DynamicTypeBuilderFactory::get_instance()->create_enum_builder(); - ASSERT_TRUE(created_builder != nullptr); - - // Add three members to the enum. - ASSERT_TRUE(created_builder->add_empty_member(0, "DEFAULT") == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(created_builder->add_empty_member(1, "FIRST") == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(created_builder->add_empty_member(2, "SECOND") == ReturnCode_t::RETCODE_OK); - - // Try to add a descriptor with the same name. - ASSERT_FALSE(created_builder->add_empty_member(4, "DEFAULT") == ReturnCode_t::RETCODE_OK); - - DynamicType_ptr created_type = DynamicTypeBuilderFactory::get_instance()->create_type(created_builder.get()); - ASSERT_TRUE(created_type != nullptr); - DynamicData* data = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(data != nullptr); - - ASSERT_FALSE(data->set_int32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - // Try to set an invalid value. - ASSERT_FALSE(data->set_enum_value("BAD", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - std::string test1 = "SECOND"; - ASSERT_FALSE(data->set_enum_value(test1, 1) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(data->set_enum_value(test1, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - std::string test2; - int iTest; - ASSERT_FALSE(data->get_int32_value(iTest, 0) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->get_enum_value(test2, 1) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(data->get_enum_value(test2, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(test1 == test2); - - // Work as uint32_t - uint32_t uTest1 = 2; - ASSERT_FALSE(data->set_enum_value(uTest1, 1) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(data->set_enum_value(uTest1, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - uint32_t uTest2; - ASSERT_FALSE(data->get_int32_value(iTest, 0) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->get_enum_value(uTest2, 1) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(data->get_enum_value(uTest2, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(uTest1 == uTest2); - - ASSERT_FALSE(data->set_int32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_int16_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint16_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_int64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float128_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_char8_value('a', MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_char16_value(L'a', MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_byte_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_bool_value(false, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_string_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_wstring_value(L"", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - //ASSERT_FALSE(data->set_enum_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - int32_t iTest32; - ASSERT_FALSE(data->get_int32_value(iTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint32_t uTest32; - ASSERT_FALSE(data->get_uint32_value(uTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - int16_t iTest16; - ASSERT_FALSE(data->get_int16_value(iTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint16_t uTest16; - ASSERT_FALSE(data->get_uint16_value(uTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - int64_t iTest64; - ASSERT_FALSE(data->get_int64_value(iTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint64_t uTest64; - ASSERT_FALSE(data->get_uint64_value(uTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - float fTest32; - ASSERT_FALSE(data->get_float32_value(fTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - double fTest64; - ASSERT_FALSE(data->get_float64_value(fTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - long double fTest128; - ASSERT_FALSE(data->get_float128_value(fTest128, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - char cTest8; - ASSERT_FALSE(data->get_char8_value(cTest8, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - wchar_t cTest16; - ASSERT_FALSE(data->get_char16_value(cTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - octet oTest; - ASSERT_FALSE(data->get_byte_value(oTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - bool bTest; - ASSERT_FALSE(data->get_bool_value(bTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::string sTest; - ASSERT_FALSE(data->get_string_value(sTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::wstring wsTest; - ASSERT_FALSE(data->get_wstring_value(wsTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - //std::string sEnumTest; - //ASSERT_FALSE(data->get_enum_value(sEnumTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - // Serialize <-> Deserialize Test - DynamicPubSubType pubsubType(created_type); - uint32_t payloadSize = static_cast(pubsubType.getSerializedSizeProvider(data)()); - SerializedPayload_t payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(data, &payload)); - ASSERT_TRUE(payload.length == payloadSize); - types::DynamicData* data2 = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(pubsubType.deserialize(&payload, data2)); - ASSERT_TRUE(data2->equals(data)); - - // SERIALIZATION TEST - EnumStruct wenum; - EnumStructPubSubType wenumpb; - - SerializedPayload_t dynamic_payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(data, &dynamic_payload)); - ASSERT_TRUE(wenumpb.deserialize(&dynamic_payload, &wenum)); - - uint32_t static_payloadSize = static_cast(wenumpb.getSerializedSizeProvider(&wenum)()); - SerializedPayload_t static_payload(static_payloadSize); - ASSERT_TRUE(wenumpb.serialize(&wenum, &static_payload)); - ASSERT_TRUE(static_payload.length == static_payloadSize); - types::DynamicData* data3 = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(pubsubType.deserialize(&static_payload, data3)); - ASSERT_TRUE(data3->equals(data)); - - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data2) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data3) == ReturnCode_t::RETCODE_OK); - } - ASSERT_TRUE(DynamicTypeBuilderFactory::get_instance()->is_empty()); - ASSERT_TRUE(DynamicDataFactory::get_instance()->is_empty()); -} - -TEST_F(DynamicTypesTests, DynamicType_string_unit_tests) -{ - uint32_t length = 15; - { - DynamicTypeBuilderFactory::get_instance()->create_string_type(length); - DynamicTypeBuilder_ptr created_builder = - DynamicTypeBuilderFactory::get_instance()->create_string_builder(length); - ASSERT_TRUE(created_builder != nullptr); - DynamicType_ptr created_type = DynamicTypeBuilderFactory::get_instance()->create_type(created_builder.get()); - ASSERT_TRUE(created_type != nullptr); - DynamicData* data = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(data != nullptr); - - ASSERT_FALSE(data->set_int32_value(10, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_string_value("", 1) == ReturnCode_t::RETCODE_OK); - std::string sTest1 = "STRING_TEST"; - ASSERT_TRUE(data->set_string_value(sTest1, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - int test = 0; - ASSERT_FALSE(data->get_int32_value(test, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::string sTest2 = ""; - ASSERT_FALSE(data->get_string_value(sTest2, 0) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(data->get_string_value(sTest2, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(sTest1 == sTest2); - - ASSERT_FALSE(data->set_string_value("TEST_OVER_LENGTH_LIMITS", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - ASSERT_FALSE(data->set_int32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_int16_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint16_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_int64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float128_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_char8_value('a', MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_char16_value(L'a', MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_byte_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_bool_value(false, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - //ASSERT_FALSE(data->set_string_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_wstring_value(L"", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_enum_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - int32_t iTest32; - ASSERT_FALSE(data->get_int32_value(iTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint32_t uTest32; - ASSERT_FALSE(data->get_uint32_value(uTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - int16_t iTest16; - ASSERT_FALSE(data->get_int16_value(iTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint16_t uTest16; - ASSERT_FALSE(data->get_uint16_value(uTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - int64_t iTest64; - ASSERT_FALSE(data->get_int64_value(iTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint64_t uTest64; - ASSERT_FALSE(data->get_uint64_value(uTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - float fTest32; - ASSERT_FALSE(data->get_float32_value(fTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - double fTest64; - ASSERT_FALSE(data->get_float64_value(fTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - long double fTest128; - ASSERT_FALSE(data->get_float128_value(fTest128, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - char cTest8; - ASSERT_FALSE(data->get_char8_value(cTest8, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - wchar_t cTest16; - ASSERT_FALSE(data->get_char16_value(cTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - octet oTest; - ASSERT_FALSE(data->get_byte_value(oTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - bool bTest; - ASSERT_FALSE(data->get_bool_value(bTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - //std::string sTest; - //ASSERT_FALSE(data->get_string_value(sTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::wstring wsTest; - ASSERT_FALSE(data->get_wstring_value(wsTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::string sEnumTest; - ASSERT_FALSE(data->get_enum_value(sEnumTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - // Serialize <-> Deserialize Test - DynamicPubSubType pubsubType(created_type); - uint32_t payloadSize = static_cast(pubsubType.getSerializedSizeProvider(data)()); - SerializedPayload_t payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(data, &payload)); - ASSERT_TRUE(payload.length == payloadSize); - types::DynamicData* data2 = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(pubsubType.deserialize(&payload, data2)); - ASSERT_TRUE(data2->equals(data)); - - // SERIALIZATION TEST - StringStruct wstring; - StringStructPubSubType wstringpb; - - SerializedPayload_t dynamic_payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(data, &dynamic_payload)); - ASSERT_TRUE(wstringpb.deserialize(&dynamic_payload, &wstring)); - - uint32_t static_payloadSize = static_cast(wstringpb.getSerializedSizeProvider(&wstring)()); - SerializedPayload_t static_payload(static_payloadSize); - ASSERT_TRUE(wstringpb.serialize(&wstring, &static_payload)); - ASSERT_TRUE(static_payload.length == static_payloadSize); - types::DynamicData* data3 = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(pubsubType.deserialize(&static_payload, data3)); - ASSERT_TRUE(data3->equals(data)); - - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data2) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data3) == ReturnCode_t::RETCODE_OK); - } - ASSERT_TRUE(DynamicTypeBuilderFactory::get_instance()->is_empty()); - ASSERT_TRUE(DynamicDataFactory::get_instance()->is_empty()); -} - -#if FASTCDR_VERSION_MAJOR == 1 -TEST_F(DynamicTypesTests, DynamicType_wstring_unit_tests) -{ - uint32_t length = 15; - { - DynamicTypeBuilder_ptr created_builder = DynamicTypeBuilderFactory::get_instance()->create_wstring_builder( - length); - ASSERT_TRUE(created_builder != nullptr); - DynamicType_ptr created_type = DynamicTypeBuilderFactory::get_instance()->create_type(created_builder.get()); - ASSERT_TRUE(created_type != nullptr); - DynamicData* data = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(data != nullptr); - - ASSERT_FALSE(data->set_int32_value(10, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_wstring_value(L"", 1) == ReturnCode_t::RETCODE_OK); - std::wstring sTest1 = L"STRING_TEST"; - ASSERT_TRUE(data->set_wstring_value(sTest1, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - int test = 0; - ASSERT_FALSE(data->get_int32_value(test, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::wstring sTest2 = L""; - ASSERT_FALSE(data->get_wstring_value(sTest2, 0) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(data->get_wstring_value(sTest2, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(sTest1 == sTest2); - - ASSERT_FALSE(data->set_wstring_value(L"TEST_OVER_LENGTH_LIMITS", - MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - ASSERT_FALSE(data->set_int32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_int16_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint16_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_int64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float128_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_char8_value('a', MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_char16_value(L'a', MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_byte_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_bool_value(false, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_string_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - //ASSERT_FALSE(data->set_wstring_value(L"", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_enum_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - int32_t iTest32; - ASSERT_FALSE(data->get_int32_value(iTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint32_t uTest32; - ASSERT_FALSE(data->get_uint32_value(uTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - int16_t iTest16; - ASSERT_FALSE(data->get_int16_value(iTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint16_t uTest16; - ASSERT_FALSE(data->get_uint16_value(uTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - int64_t iTest64; - ASSERT_FALSE(data->get_int64_value(iTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint64_t uTest64; - ASSERT_FALSE(data->get_uint64_value(uTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - float fTest32; - ASSERT_FALSE(data->get_float32_value(fTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - double fTest64; - ASSERT_FALSE(data->get_float64_value(fTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - long double fTest128; - ASSERT_FALSE(data->get_float128_value(fTest128, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - char cTest8; - ASSERT_FALSE(data->get_char8_value(cTest8, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - wchar_t cTest16; - ASSERT_FALSE(data->get_char16_value(cTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - octet oTest; - ASSERT_FALSE(data->get_byte_value(oTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - bool bTest; - ASSERT_FALSE(data->get_bool_value(bTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::string sTest; - ASSERT_FALSE(data->get_string_value(sTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - //std::wstring wsTest; - //ASSERT_FALSE(data->get_wstring_value(wsTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::string sEnumTest; - ASSERT_FALSE(data->get_enum_value(sEnumTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - // Serialize <-> Deserialize Test - DynamicPubSubType pubsubType(created_type); - uint32_t payloadSize = static_cast(pubsubType.getSerializedSizeProvider(data)()); - SerializedPayload_t payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(data, &payload)); - ASSERT_TRUE(payload.length == payloadSize); - types::DynamicData* data2 = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(pubsubType.deserialize(&payload, data2)); - ASSERT_TRUE(data2->equals(data)); - - // SERIALIZATION TEST - WStringStruct wwstring; - WStringStructPubSubType wwstringpb; - - SerializedPayload_t dynamic_payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(data, &dynamic_payload)); - ASSERT_TRUE(wwstringpb.deserialize(&dynamic_payload, &wwstring)); - - uint32_t static_payloadSize = static_cast(wwstringpb.getSerializedSizeProvider(&wwstring)()); - SerializedPayload_t static_payload(static_payloadSize); - ASSERT_TRUE(wwstringpb.serialize(&wwstring, &static_payload)); - ASSERT_TRUE(static_payload.length == static_payloadSize); - types::DynamicData* data3 = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(pubsubType.deserialize(&static_payload, data3)); - ASSERT_TRUE(data3->equals(data)); - - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data2) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data3) == ReturnCode_t::RETCODE_OK); - } - ASSERT_TRUE(DynamicTypeBuilderFactory::get_instance()->is_empty()); - ASSERT_TRUE(DynamicDataFactory::get_instance()->is_empty()); -} -#endif // if FASTCDR_VERSION_MAJOR == 1 - -TEST_F(DynamicTypesTests, DynamicType_alias_unit_tests) -{ - { - std::string name = "ALIAS"; - DynamicTypeBuilder_ptr base_builder = DynamicTypeBuilderFactory::get_instance()->create_uint32_builder(); - ASSERT_TRUE(base_builder != nullptr); - DynamicTypeBuilder_ptr alias_builder = DynamicTypeBuilderFactory::get_instance()->create_alias_builder( - base_builder.get(), name); - ASSERT_TRUE(alias_builder != nullptr); - DynamicType_ptr created_type = DynamicTypeBuilderFactory::get_instance()->create_type(alias_builder.get()); - ASSERT_TRUE(created_type != nullptr); - ASSERT_TRUE(created_type->get_name() == "ALIAS"); - DynamicData* aliasData = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(aliasData != nullptr); - - ASSERT_FALSE(aliasData->set_int32_value(10, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(aliasData->set_string_value("", 1) == ReturnCode_t::RETCODE_OK); - - uint32_t uTest1 = 2; - ASSERT_TRUE(aliasData->set_uint32_value(uTest1, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - uint32_t uTest2 = 0; - ASSERT_TRUE(aliasData->get_uint32_value(uTest2, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(uTest1 == uTest2); - - // Serialize <-> Deserialize Test - DynamicPubSubType pubsubType(created_type); - uint32_t payloadSize = static_cast(pubsubType.getSerializedSizeProvider(aliasData)()); - SerializedPayload_t payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(aliasData, &payload)); - ASSERT_TRUE(payload.length == payloadSize); - types::DynamicData* data2 = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(pubsubType.deserialize(&payload, data2)); - ASSERT_TRUE(data2->equals(aliasData)); - - // SERIALIZATION TEST - AliasStruct walias; - AliasStructPubSubType waliaspb; - - SerializedPayload_t dynamic_payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(aliasData, &dynamic_payload)); - ASSERT_TRUE(waliaspb.deserialize(&dynamic_payload, &walias)); - - uint32_t static_payloadSize = static_cast(waliaspb.getSerializedSizeProvider(&walias)()); - SerializedPayload_t static_payload(static_payloadSize); - ASSERT_TRUE(waliaspb.serialize(&walias, &static_payload)); - ASSERT_TRUE(static_payload.length == static_payloadSize); - types::DynamicData* data3 = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(pubsubType.deserialize(&static_payload, data3)); - ASSERT_TRUE(data3->equals(aliasData)); - - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(aliasData) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data2) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data3) == ReturnCode_t::RETCODE_OK); - } - - ASSERT_TRUE(DynamicTypeBuilderFactory::get_instance()->is_empty()); - ASSERT_TRUE(DynamicDataFactory::get_instance()->is_empty()); -} - -TEST_F(DynamicTypesTests, DynamicType_multi_alias_unit_tests) -{ - { - uint32_t length = 15; - std::string name = "ALIAS"; - std::string name2 = "ALIAS2"; - DynamicTypeBuilder_ptr base_builder = DynamicTypeBuilderFactory::get_instance()->create_string_builder(length); - ASSERT_TRUE(base_builder != nullptr); - DynamicTypeBuilder_ptr base_alias_builder = DynamicTypeBuilderFactory::get_instance()->create_alias_builder( - base_builder.get(), name); - ASSERT_TRUE(base_alias_builder != nullptr); - DynamicType_ptr base_type = DynamicTypeBuilderFactory::get_instance()->create_type(base_alias_builder.get()); - ASSERT_TRUE(base_type != nullptr); - ASSERT_TRUE(base_type->get_name() == name); - DynamicTypeBuilder_ptr alias_builder = DynamicTypeBuilderFactory::get_instance()->create_alias_builder( - base_alias_builder.get(), name2); - ASSERT_TRUE(alias_builder != nullptr); - DynamicType_ptr created_type = DynamicTypeBuilderFactory::get_instance()->create_type(alias_builder.get()); - ASSERT_TRUE(created_type != nullptr); - ASSERT_TRUE(created_type->get_name() == name2); - DynamicData* aliasData = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(aliasData != nullptr); - - // Try to create an alias without base type. - DynamicTypeBuilder_ptr alias2_type_builder = DynamicTypeBuilderFactory::get_instance()->create_alias_builder( - nullptr, "ALIAS2"); - ASSERT_FALSE(alias2_type_builder != nullptr); - - ASSERT_FALSE(aliasData->set_int32_value(10, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(aliasData->set_string_value("", 1) == ReturnCode_t::RETCODE_OK); - std::string sTest1 = "STRING_TEST"; - ASSERT_TRUE(aliasData->set_string_value(sTest1, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - int test = 0; - ASSERT_FALSE(aliasData->get_int32_value(test, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::string sTest2 = ""; - ASSERT_FALSE(aliasData->get_string_value(sTest2, 0) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(aliasData->get_string_value(sTest2, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(sTest1 == sTest2); - - ASSERT_FALSE(aliasData->set_string_value("TEST_OVER_LENGTH_LIMITS", - MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - // Serialize <-> Deserialize Test - DynamicPubSubType pubsubType(created_type); - uint32_t payloadSize = static_cast(pubsubType.getSerializedSizeProvider(aliasData)()); - SerializedPayload_t payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(aliasData, &payload)); - ASSERT_TRUE(payload.length == payloadSize); - types::DynamicData* data2 = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(pubsubType.deserialize(&payload, data2)); - ASSERT_TRUE(data2->equals(aliasData)); - - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(aliasData) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data2) == ReturnCode_t::RETCODE_OK); - } - - ASSERT_TRUE(DynamicTypeBuilderFactory::get_instance()->is_empty()); - ASSERT_TRUE(DynamicDataFactory::get_instance()->is_empty()); -} - -TEST_F(DynamicTypesTests, DynamicType_bitset_unit_tests) -{ - { - DynamicTypeBuilder_ptr base_type_builder = DynamicTypeBuilderFactory::get_instance()->create_byte_builder(); - ASSERT_TRUE(base_type_builder != nullptr); - auto base_type = base_type_builder->build(); - - DynamicTypeBuilder_ptr base_type_builder2 = DynamicTypeBuilderFactory::get_instance()->create_uint32_builder(); - ASSERT_TRUE(base_type_builder2 != nullptr); - auto base_type2 = base_type_builder2->build(); - - DynamicTypeBuilder_ptr bitset_type_builder = - DynamicTypeBuilderFactory::get_instance()->create_bitset_builder(); - ASSERT_TRUE(bitset_type_builder != nullptr); - - // Add members to the struct. - ASSERT_TRUE(bitset_type_builder->add_member(0, "int2", base_type) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(bitset_type_builder->add_member(1, "int20", base_type2) == ReturnCode_t::RETCODE_OK); - bitset_type_builder->apply_annotation_to_member(0, ANNOTATION_BIT_BOUND_ID, "value", "2"); - bitset_type_builder->apply_annotation_to_member(0, ANNOTATION_POSITION_ID, "value", "0"); - bitset_type_builder->apply_annotation_to_member(1, ANNOTATION_BIT_BOUND_ID, "value", "20"); - bitset_type_builder->apply_annotation_to_member(1, ANNOTATION_POSITION_ID, "value", "10"); // 8 bits empty - - auto bitset_type = bitset_type_builder->build(); - ASSERT_TRUE(bitset_type != nullptr); - auto bitset_data = DynamicDataFactory::get_instance()->create_data(bitset_type); - ASSERT_TRUE(bitset_data != nullptr); - - ASSERT_FALSE(bitset_data->set_int32_value(10, 1) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(bitset_data->set_string_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - // Set and get the child values. - octet test1(234); - ASSERT_TRUE(bitset_data->set_byte_value(test1, 0) == ReturnCode_t::RETCODE_OK); - octet test2(0); - ASSERT_TRUE(bitset_data->get_byte_value(test2, 0) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(test1 == test2); - // 11101010 - // 00000010 (two bits) - ASSERT_TRUE(test2 == 2); - uint32_t test3(289582314); - ASSERT_TRUE(bitset_data->set_uint32_value(test3, 1) == ReturnCode_t::RETCODE_OK); - uint32_t test4(0); - ASSERT_TRUE(bitset_data->get_uint32_value(test4, 1) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(test3 == test4); - // 00000001010000101010110011101010 - // 00000000000000101010110011101010 (20 bits) - ASSERT_TRUE(test4 == 175338); - - - - // Bitset serialization - // Tested in DynamicTypes_4_2_Tests - - // Delete the structure - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(bitset_data) == ReturnCode_t::RETCODE_OK); - - } - ASSERT_TRUE(DynamicTypeBuilderFactory::get_instance()->is_empty()); - ASSERT_TRUE(DynamicDataFactory::get_instance()->is_empty()); -} - -TEST_F(DynamicTypesTests, DynamicType_bitmask_unit_tests) -{ - uint32_t limit = 5; - { - DynamicTypeBuilder_ptr created_builder = - DynamicTypeBuilderFactory::get_instance()->create_bitmask_builder(limit); - ASSERT_TRUE(created_builder != nullptr); - - // Add two members to the bitmask - ASSERT_TRUE(created_builder->add_empty_member(0, "TEST") == ReturnCode_t::RETCODE_OK); - - // Try to add a descriptor with the same name - ASSERT_FALSE(created_builder->add_empty_member(1, "TEST") == ReturnCode_t::RETCODE_OK); - - ASSERT_TRUE(created_builder->add_empty_member(1, "TEST2") == ReturnCode_t::RETCODE_OK); - - ASSERT_TRUE(created_builder->add_empty_member(4, "TEST4") == ReturnCode_t::RETCODE_OK); - - ASSERT_FALSE(created_builder->add_empty_member(5, "TEST5") == ReturnCode_t::RETCODE_OK); // Out of bounds - - DynamicType_ptr created_type = DynamicTypeBuilderFactory::get_instance()->create_type(created_builder.get()); - ASSERT_TRUE(created_type != nullptr); - DynamicData* data = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(data != nullptr); - - MemberId testId = data->get_member_id_by_name("TEST"); - ASSERT_TRUE(testId != MEMBER_ID_INVALID); - MemberId test2Id = data->get_member_id_by_name("TEST2"); - ASSERT_TRUE(test2Id != MEMBER_ID_INVALID); - MemberId test4Id = data->get_member_id_by_name("TEST4"); - ASSERT_TRUE(test4Id != MEMBER_ID_INVALID); - MemberId test5Id = data->get_member_id_by_name("TEST5"); - ASSERT_TRUE(test5Id == MEMBER_ID_INVALID); - - bool test1 = true; - ASSERT_FALSE(data->set_int32_value(1, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(data->set_bool_value(test1, testId) == ReturnCode_t::RETCODE_OK); - - // Over the limit - ASSERT_FALSE(data->set_bool_value(test1, limit + 1) == ReturnCode_t::RETCODE_OK); - - bool test2 = false; - ASSERT_TRUE(data->get_bool_value(test2, 2) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(test2 == false); - ASSERT_TRUE(data->get_bool_value(test2, testId) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(test1 == test2); - ASSERT_TRUE(data->get_bool_value(test2, testId) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(test1 == test2); - bool test3 = data->get_bool_value("TEST"); - ASSERT_TRUE(test1 == test3); - ASSERT_TRUE(data->set_bool_value(true, "TEST4") == ReturnCode_t::RETCODE_OK); - bool test4 = data->get_bool_value("TEST4"); - ASSERT_TRUE(test4 == true); - - test1 = false; - ASSERT_TRUE(data->set_bool_value(test1, testId) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(data->get_bool_value(test2, test2Id) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(data->get_bool_value(test2, testId) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(test1 == test2); - data->set_bitmask_value(55); // 00110111 - uint64_t value = data->get_bitmask_value(); - ASSERT_TRUE(value == 55); - ASSERT_TRUE(data->get_bool_value("TEST")); - ASSERT_TRUE(data->get_bool_value("TEST2")); - ASSERT_TRUE(data->get_bool_value("TEST4")); - data->set_bitmask_value(37); // 00100101 - ASSERT_TRUE(data->get_bool_value("TEST")); - ASSERT_FALSE(data->get_bool_value("TEST2")); - ASSERT_FALSE(data->get_bool_value("TEST4")); - - ASSERT_FALSE(data->set_int32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_int16_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint16_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_int64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - //ASSERT_FALSE(data->set_uint64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float128_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_char8_value('a', MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_char16_value(L'a', MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_byte_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - //ASSERT_FALSE(data->set_bool_value(false, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_string_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_wstring_value(L"", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_enum_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - int32_t iTest32; - ASSERT_FALSE(data->get_int32_value(iTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint32_t uTest32; - ASSERT_FALSE(data->get_uint32_value(uTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - int16_t iTest16; - ASSERT_FALSE(data->get_int16_value(iTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint16_t uTest16; - ASSERT_FALSE(data->get_uint16_value(uTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - int64_t iTest64; - ASSERT_FALSE(data->get_int64_value(iTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - //uint64_t uTest64; - //ASSERT_FALSE(data->get_uint64_value(uTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - float fTest32; - ASSERT_FALSE(data->get_float32_value(fTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - double fTest64; - ASSERT_FALSE(data->get_float64_value(fTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - long double fTest128; - ASSERT_FALSE(data->get_float128_value(fTest128, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - char cTest8; - ASSERT_FALSE(data->get_char8_value(cTest8, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - wchar_t cTest16; - ASSERT_FALSE(data->get_char16_value(cTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - octet oTest; - ASSERT_FALSE(data->get_byte_value(oTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - bool bTest; - ASSERT_FALSE(data->get_bool_value(bTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::string sTest; - ASSERT_FALSE(data->get_string_value(sTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::wstring wsTest; - ASSERT_FALSE(data->get_wstring_value(wsTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::string sEnumTest; - ASSERT_FALSE(data->get_enum_value(sEnumTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - // Serialize <-> Deserialize Test - ASSERT_TRUE(data->set_bool_value(true, 0) == ReturnCode_t::RETCODE_OK); - DynamicPubSubType pubsubType(created_type); - uint32_t payloadSize = static_cast(pubsubType.getSerializedSizeProvider(data)()); - SerializedPayload_t payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(data, &payload)); - ASSERT_TRUE(payload.length == payloadSize); - - types::DynamicData* data2 = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(pubsubType.deserialize(&payload, data2)); - ASSERT_TRUE(data2->equals(data)); - - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data2) == ReturnCode_t::RETCODE_OK); - } - ASSERT_TRUE(DynamicTypeBuilderFactory::get_instance()->is_empty()); - ASSERT_TRUE(DynamicDataFactory::get_instance()->is_empty()); -} - -TEST_F(DynamicTypesTests, DynamicType_sequence_unit_tests) -{ - uint32_t length = 2; - { - // Then - DynamicTypeBuilder_ptr base_type_builder = DynamicTypeBuilderFactory::get_instance()->create_int32_builder(); - ASSERT_TRUE(base_type_builder != nullptr); - DynamicTypeBuilder_ptr seq_type_builder = DynamicTypeBuilderFactory::get_instance()->create_sequence_builder( - base_type_builder.get(), length); - ASSERT_TRUE(seq_type_builder != nullptr); - auto seq_type = seq_type_builder->build(); - ASSERT_TRUE(seq_type != nullptr); - - auto data = DynamicDataFactory::get_instance()->create_data(seq_type); - ASSERT_FALSE(data->set_int32_value(10, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_string_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - // Try to write on an empty position - ASSERT_FALSE(data->set_int32_value(234, 1) == ReturnCode_t::RETCODE_OK); - - MemberId newId; - ASSERT_TRUE(data->insert_sequence_data(newId) == ReturnCode_t::RETCODE_OK); - MemberId newId2; - ASSERT_TRUE(data->insert_sequence_data(newId2) == ReturnCode_t::RETCODE_OK); - - // Try to insert more than the limit. - MemberId newId3; - ASSERT_FALSE(data->insert_sequence_data(newId3) == ReturnCode_t::RETCODE_OK); - - // Set and get a value. - int32_t test1(234); - ASSERT_TRUE(data->set_int32_value(test1, newId2) == ReturnCode_t::RETCODE_OK); - int32_t test2(0); - ASSERT_TRUE(data->get_int32_value(test2, newId2) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(test1 == test2); - - // Serialize <-> Deserialize Test - DynamicPubSubType pubsubType(seq_type); - uint32_t payloadSize = static_cast(pubsubType.getSerializedSizeProvider(data)()); - SerializedPayload_t payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(data, &payload)); - ASSERT_TRUE(payload.length == payloadSize); - - types::DynamicData* data2 = DynamicDataFactory::get_instance()->create_data(seq_type); - ASSERT_TRUE(pubsubType.deserialize(&payload, data2)); - ASSERT_TRUE(data2->equals(data)); - - // Remove the elements. - ASSERT_TRUE(data->remove_sequence_data(newId) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(data->clear_all_values() == ReturnCode_t::RETCODE_OK); - - // New Insert Methods - ASSERT_TRUE(data->insert_int32_value(test1, newId) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(data->get_int32_value(test2, newId) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(test1 == test2); - ASSERT_TRUE(data->clear_all_values() == ReturnCode_t::RETCODE_OK); - - // Check that the sequence is empty. - ASSERT_FALSE(data->get_int32_value(test2, 0) == ReturnCode_t::RETCODE_OK); - - ASSERT_FALSE(data->set_int32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_int16_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint16_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_int64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float128_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_char8_value('a', MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_char16_value(L'a', MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_byte_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_bool_value(false, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_string_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_wstring_value(L"", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_enum_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - int32_t iTest32; - ASSERT_FALSE(data->get_int32_value(iTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint32_t uTest32; - ASSERT_FALSE(data->get_uint32_value(uTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - int16_t iTest16; - ASSERT_FALSE(data->get_int16_value(iTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint16_t uTest16; - ASSERT_FALSE(data->get_uint16_value(uTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - int64_t iTest64; - ASSERT_FALSE(data->get_int64_value(iTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint64_t uTest64; - ASSERT_FALSE(data->get_uint64_value(uTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - float fTest32; - ASSERT_FALSE(data->get_float32_value(fTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - double fTest64; - ASSERT_FALSE(data->get_float64_value(fTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - long double fTest128; - ASSERT_FALSE(data->get_float128_value(fTest128, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - char cTest8; - ASSERT_FALSE(data->get_char8_value(cTest8, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - wchar_t cTest16; - ASSERT_FALSE(data->get_char16_value(cTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - octet oTest; - ASSERT_FALSE(data->get_byte_value(oTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - bool bTest; - ASSERT_FALSE(data->get_bool_value(bTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::string sTest; - ASSERT_FALSE(data->get_string_value(sTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::wstring wsTest; - ASSERT_FALSE(data->get_wstring_value(wsTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::string sEnumTest; - ASSERT_FALSE(data->get_enum_value(sEnumTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - - // SERIALIZATION TEST - SequenceStruct seq; - SequenceStructPubSubType seqpb; - - SerializedPayload_t dynamic_payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(data, &dynamic_payload)); - ASSERT_TRUE(seqpb.deserialize(&dynamic_payload, &seq)); - - uint32_t static_payloadSize = static_cast(seqpb.getSerializedSizeProvider(&seq)()); - SerializedPayload_t static_payload(static_payloadSize); - ASSERT_TRUE(seqpb.serialize(&seq, &static_payload)); - ASSERT_TRUE(static_payload.length == static_payloadSize); - types::DynamicData* data3 = DynamicDataFactory::get_instance()->create_data(seq_type); - ASSERT_TRUE(pubsubType.deserialize(&static_payload, data3)); - ASSERT_TRUE(data3->equals(data)); - - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data2) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data3) == ReturnCode_t::RETCODE_OK); - } - ASSERT_TRUE(DynamicTypeBuilderFactory::get_instance()->is_empty()); - ASSERT_TRUE(DynamicDataFactory::get_instance()->is_empty()); -} - -TEST_F(DynamicTypesTests, DynamicType_sequence_of_sequences_unit_tests) -{ - uint32_t sequence_length = 2; - uint32_t sup_sequence_length = 3; - { - // Then - DynamicTypeBuilder_ptr base_type_builder = DynamicTypeBuilderFactory::get_instance()->create_int32_builder(); - ASSERT_TRUE(base_type_builder != nullptr); - - DynamicTypeBuilder_ptr seq_type_builder = DynamicTypeBuilderFactory::get_instance()->create_sequence_builder( - base_type_builder.get(), sequence_length); - ASSERT_TRUE(seq_type_builder != nullptr); - auto seq_type = seq_type_builder->build(); - ASSERT_TRUE(seq_type != nullptr); - - DynamicTypeBuilder_ptr seq_seq_type_builder = - DynamicTypeBuilderFactory::get_instance()->create_sequence_builder( - seq_type_builder.get(), sup_sequence_length); - ASSERT_TRUE(seq_seq_type_builder != nullptr); - auto seq_seq_type = seq_seq_type_builder->build(); - ASSERT_TRUE(seq_seq_type != nullptr); - - auto data = DynamicDataFactory::get_instance()->create_data(seq_seq_type); - ASSERT_FALSE(data->set_int32_value(10, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_string_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - MemberId newId; - ASSERT_TRUE(data->insert_sequence_data(newId) == ReturnCode_t::RETCODE_OK); - MemberId newId2; - ASSERT_TRUE(data->insert_sequence_data(newId2) == ReturnCode_t::RETCODE_OK); - - // Loan Value to modify the first sequence - auto seq_data = data->loan_value(newId); - ASSERT_TRUE(seq_data != nullptr); - - MemberId newSeqId; - ASSERT_TRUE(seq_data->insert_sequence_data(newSeqId) == ReturnCode_t::RETCODE_OK); - - // Set and get a value. - int32_t test1(234); - ASSERT_TRUE(seq_data->set_int32_value(test1, newSeqId) == ReturnCode_t::RETCODE_OK); - int32_t test2(0); - ASSERT_TRUE(seq_data->get_int32_value(test2, newSeqId) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(test1 == test2); - - // Return the pointer of the sequence - ASSERT_TRUE(data->return_loaned_value(seq_data) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->return_loaned_value(seq_data) == ReturnCode_t::RETCODE_OK); - - // Serialize <-> Deserialize Test - DynamicPubSubType pubsubType(seq_seq_type); - uint32_t payloadSize = static_cast(pubsubType.getSerializedSizeProvider(data)()); - SerializedPayload_t payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(data, &payload)); - ASSERT_TRUE(payload.length == payloadSize); - - types::DynamicData* data2 = DynamicDataFactory::get_instance()->create_data(seq_seq_type); - ASSERT_TRUE(pubsubType.deserialize(&payload, data2)); - ASSERT_TRUE(data2->equals(data)); - - // Remove the elements. - ASSERT_TRUE(data->remove_sequence_data(newId) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(data->clear_all_values() == ReturnCode_t::RETCODE_OK); - - // Check that the sequence is empty. - ASSERT_FALSE(data->get_int32_value(test2, 0) == ReturnCode_t::RETCODE_OK); - - ASSERT_FALSE(data->set_int32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_int16_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint16_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_int64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float128_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_char8_value('a', MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_char16_value(L'a', MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_byte_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_bool_value(false, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_string_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_wstring_value(L"", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_enum_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - int32_t iTest32; - ASSERT_FALSE(data->get_int32_value(iTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint32_t uTest32; - ASSERT_FALSE(data->get_uint32_value(uTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - int16_t iTest16; - ASSERT_FALSE(data->get_int16_value(iTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint16_t uTest16; - ASSERT_FALSE(data->get_uint16_value(uTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - int64_t iTest64; - ASSERT_FALSE(data->get_int64_value(iTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint64_t uTest64; - ASSERT_FALSE(data->get_uint64_value(uTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - float fTest32; - ASSERT_FALSE(data->get_float32_value(fTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - double fTest64; - ASSERT_FALSE(data->get_float64_value(fTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - long double fTest128; - ASSERT_FALSE(data->get_float128_value(fTest128, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - char cTest8; - ASSERT_FALSE(data->get_char8_value(cTest8, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - wchar_t cTest16; - ASSERT_FALSE(data->get_char16_value(cTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - octet oTest; - ASSERT_FALSE(data->get_byte_value(oTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - bool bTest; - ASSERT_FALSE(data->get_bool_value(bTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::string sTest; - ASSERT_FALSE(data->get_string_value(sTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::wstring wsTest; - ASSERT_FALSE(data->get_wstring_value(wsTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::string sEnumTest; - ASSERT_FALSE(data->get_enum_value(sEnumTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - // SERIALIZATION TEST - SequenceSequenceStruct seq; - SequenceSequenceStructPubSubType seqpb; - - SerializedPayload_t dynamic_payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(data, &dynamic_payload)); - ASSERT_TRUE(seqpb.deserialize(&dynamic_payload, &seq)); - - uint32_t static_payloadSize = static_cast(seqpb.getSerializedSizeProvider(&seq)()); - SerializedPayload_t static_payload(static_payloadSize); - ASSERT_TRUE(seqpb.serialize(&seq, &static_payload)); - ASSERT_TRUE(static_payload.length == static_payloadSize); - types::DynamicData* data3 = DynamicDataFactory::get_instance()->create_data(seq_type); - ASSERT_TRUE(pubsubType.deserialize(&static_payload, data3)); - ASSERT_TRUE(data3->equals(data)); - - // New Insert Methods - ASSERT_TRUE(data->clear_all_values() == ReturnCode_t::RETCODE_OK); - seq_data = DynamicDataFactory::get_instance()->create_data(seq_type); - ASSERT_TRUE(seq_data->insert_int32_value(test1, newSeqId) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(seq_data->get_int32_value(test2, newSeqId) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(test1 == test2); - ASSERT_TRUE(data->insert_complex_value(seq_data, newId) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(data->clear_all_values() == ReturnCode_t::RETCODE_OK); - - - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data2) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data3) == ReturnCode_t::RETCODE_OK); - } - - ASSERT_TRUE(DynamicTypeBuilderFactory::get_instance()->is_empty()); - ASSERT_TRUE(DynamicDataFactory::get_instance()->is_empty()); -} - -TEST_F(DynamicTypesTests, DynamicType_array_unit_tests) -{ - std::vector sequence_lengths = { 2, 2, 2 }; - { - // Then - DynamicTypeBuilder_ptr base_type_builder = DynamicTypeBuilderFactory::get_instance()->create_int32_builder(); - ASSERT_TRUE(base_type_builder != nullptr); - auto base_type = base_type_builder->build(); - - DynamicTypeBuilder_ptr array_type_builder = DynamicTypeBuilderFactory::get_instance()->create_array_builder( - base_type_builder.get(), sequence_lengths); - ASSERT_TRUE(array_type_builder != nullptr); - auto array_type = array_type_builder->build(); - ASSERT_TRUE(array_type != nullptr); - - auto data = DynamicDataFactory::get_instance()->create_data(array_type); - ASSERT_FALSE(data->set_int32_value(10, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_string_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - MemberId newId; - ASSERT_FALSE(data->insert_sequence_data(newId) == ReturnCode_t::RETCODE_OK); - - // Get an index in the multidimensional array. - std::vector vPosition = { 1, 1, 1 }; - MemberId testPos(0); - testPos = data->get_array_index(vPosition); - ASSERT_TRUE(testPos != MEMBER_ID_INVALID); - - // Invalid input vectors. - std::vector vPosition2 = { 1, 1 }; - ASSERT_FALSE(data->get_array_index(vPosition2) != MEMBER_ID_INVALID); - std::vector vPosition3 = { 1, 1, 1, 1 }; - ASSERT_FALSE(data->get_array_index(vPosition3) != MEMBER_ID_INVALID); - - // Set and get a value. - int32_t test1 = 156; - ASSERT_TRUE(data->set_int32_value(test1, testPos) == ReturnCode_t::RETCODE_OK); - int32_t test2(0); - ASSERT_TRUE(data->get_int32_value(test2, testPos) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(test1 == test2); - - // Serialize <-> Deserialize Test - DynamicPubSubType pubsubType(array_type); - uint32_t payloadSize = static_cast(pubsubType.getSerializedSizeProvider(data)()); - SerializedPayload_t payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(data, &payload)); - ASSERT_TRUE(payload.length == payloadSize); - - types::DynamicData* data2 = DynamicDataFactory::get_instance()->create_data(array_type); - ASSERT_TRUE(pubsubType.deserialize(&payload, data2)); - ASSERT_TRUE(data2->equals(data)); - - // Check items count before and after remove an element. - ASSERT_TRUE(data->get_item_count() == array_type->get_total_bounds()); - ASSERT_TRUE(data->clear_value(testPos) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(data->get_item_count() == array_type->get_total_bounds()); - ASSERT_TRUE(data->clear_array_data(testPos) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(data->get_item_count() == array_type->get_total_bounds()); - - // Check the clear values method - ASSERT_TRUE(data->set_int32_value(test1, testPos) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(data->get_item_count() == array_type->get_total_bounds()); - ASSERT_TRUE(data->clear_all_values() == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(data->get_item_count() == array_type->get_total_bounds()); - - // Try to set a value out of the array. - ASSERT_FALSE(data->set_int32_value(test1, 100) == ReturnCode_t::RETCODE_OK); - - ASSERT_FALSE(data->set_int32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_int16_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint16_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_int64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float128_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_char8_value('a', MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_char16_value(L'a', MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_byte_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_bool_value(false, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_string_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_wstring_value(L"", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_enum_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - int32_t iTest32; - ASSERT_FALSE(data->get_int32_value(iTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint32_t uTest32; - ASSERT_FALSE(data->get_uint32_value(uTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - int16_t iTest16; - ASSERT_FALSE(data->get_int16_value(iTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint16_t uTest16; - ASSERT_FALSE(data->get_uint16_value(uTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - int64_t iTest64; - ASSERT_FALSE(data->get_int64_value(iTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint64_t uTest64; - ASSERT_FALSE(data->get_uint64_value(uTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - float fTest32; - ASSERT_FALSE(data->get_float32_value(fTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - double fTest64; - ASSERT_FALSE(data->get_float64_value(fTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - long double fTest128; - ASSERT_FALSE(data->get_float128_value(fTest128, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - char cTest8; - ASSERT_FALSE(data->get_char8_value(cTest8, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - wchar_t cTest16; - ASSERT_FALSE(data->get_char16_value(cTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - octet oTest; - ASSERT_FALSE(data->get_byte_value(oTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - bool bTest; - ASSERT_FALSE(data->get_bool_value(bTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::string sTest; - ASSERT_FALSE(data->get_string_value(sTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::wstring wsTest; - ASSERT_FALSE(data->get_wstring_value(wsTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::string sEnumTest; - ASSERT_FALSE(data->get_enum_value(sEnumTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - // SERIALIZATION TEST - ArraytStruct seq; - ArraytStructPubSubType seqpb; - - SerializedPayload_t dynamic_payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(data, &dynamic_payload)); - ASSERT_TRUE(seqpb.deserialize(&dynamic_payload, &seq)); - - uint32_t static_payloadSize = static_cast(seqpb.getSerializedSizeProvider(&seq)()); - SerializedPayload_t static_payload(static_payloadSize); - ASSERT_TRUE(seqpb.serialize(&seq, &static_payload)); - ASSERT_TRUE(static_payload.length == static_payloadSize); - types::DynamicData* data3 = DynamicDataFactory::get_instance()->create_data(array_type); - ASSERT_TRUE(pubsubType.deserialize(&static_payload, data3)); - ASSERT_TRUE(data3->equals(data)); - - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data2) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data3) == ReturnCode_t::RETCODE_OK); - } - ASSERT_TRUE(DynamicTypeBuilderFactory::get_instance()->is_empty()); - ASSERT_TRUE(DynamicDataFactory::get_instance()->is_empty()); -} - -TEST_F(DynamicTypesTests, DynamicType_array_of_arrays_unit_tests) -{ - std::vector sequence_lengths = { 2, 2 }; - { - DynamicTypeBuilder_ptr base_type_builder = DynamicTypeBuilderFactory::get_instance()->create_int32_builder(); - ASSERT_TRUE(base_type_builder != nullptr); - auto base_type = base_type_builder->build(); - - DynamicTypeBuilder_ptr array_type_builder = DynamicTypeBuilderFactory::get_instance()->create_array_builder( - base_type_builder.get(), sequence_lengths); - ASSERT_TRUE(array_type_builder != nullptr); - auto array_type = array_type_builder->build(); - ASSERT_TRUE(array_type != nullptr); - - DynamicTypeBuilder_ptr parent_array_type_builder = - DynamicTypeBuilderFactory::get_instance()->create_array_builder( - array_type_builder.get(), sequence_lengths); - ASSERT_TRUE(parent_array_type_builder != nullptr); - auto parent_array_type = parent_array_type_builder->build(); - ASSERT_TRUE(parent_array_type != nullptr); - - auto data = DynamicDataFactory::get_instance()->create_data(parent_array_type); - ASSERT_FALSE(data->set_int32_value(10, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_string_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - MemberId newId; - ASSERT_FALSE(data->insert_sequence_data(newId) == ReturnCode_t::RETCODE_OK); - - // Get an index in the multidimensional array. - std::vector vPosition = { 1, 1 }; - MemberId testPos(0); - testPos = data->get_array_index(vPosition); - ASSERT_TRUE(testPos != MEMBER_ID_INVALID); - - // Invalid input vectors. - std::vector vPosition2 = { 1, 1, 1 }; - ASSERT_FALSE(data->get_array_index(vPosition2) != MEMBER_ID_INVALID); - std::vector vPosition3 = { 1, 1, 1, 1 }; - ASSERT_FALSE(data->get_array_index(vPosition3) != MEMBER_ID_INVALID); - - // Loan Complex values. - DynamicData* temp = data->loan_value(testPos); - ASSERT_TRUE(temp != nullptr); - DynamicData* temp2 = data->loan_value(testPos); - ASSERT_FALSE(temp2 != nullptr); - - int32_t test1 = 156; - ASSERT_TRUE(temp->set_int32_value(test1, testPos) == ReturnCode_t::RETCODE_OK); - int32_t test2(0); - ASSERT_TRUE(temp->get_int32_value(test2, testPos) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(test1 == test2); - - ASSERT_TRUE(data->return_loaned_value(temp) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->return_loaned_value(temp) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->return_loaned_value(temp2) == ReturnCode_t::RETCODE_OK); - - // Serialize <-> Deserialize Test - DynamicPubSubType pubsubType(parent_array_type); - uint32_t payloadSize = static_cast(pubsubType.getSerializedSizeProvider(data)()); - SerializedPayload_t payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(data, &payload)); - ASSERT_TRUE(payload.length == payloadSize); - - types::DynamicData* data2 = DynamicDataFactory::get_instance()->create_data(parent_array_type); - ASSERT_TRUE(pubsubType.deserialize(&payload, data2)); - ASSERT_TRUE(data2->equals(data)); - - // Check items count before and after remove an element. - ASSERT_TRUE(data->get_item_count() == parent_array_type->get_total_bounds()); - ASSERT_TRUE(data->clear_value(testPos) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(data->get_item_count() == parent_array_type->get_total_bounds()); - ASSERT_TRUE(data->clear_array_data(testPos) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(data->get_item_count() == parent_array_type->get_total_bounds()); - - // Try to set a value out of the array. - ASSERT_FALSE(data->set_int32_value(test1, 100) == ReturnCode_t::RETCODE_OK); - - ASSERT_FALSE(data->set_int32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_int16_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint16_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_int64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float128_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_char8_value('a', MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_char16_value(L'a', MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_byte_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_bool_value(false, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_string_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_wstring_value(L"", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_enum_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - int32_t iTest32; - ASSERT_FALSE(data->get_int32_value(iTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint32_t uTest32; - ASSERT_FALSE(data->get_uint32_value(uTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - int16_t iTest16; - ASSERT_FALSE(data->get_int16_value(iTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint16_t uTest16; - ASSERT_FALSE(data->get_uint16_value(uTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - int64_t iTest64; - ASSERT_FALSE(data->get_int64_value(iTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint64_t uTest64; - ASSERT_FALSE(data->get_uint64_value(uTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - float fTest32; - ASSERT_FALSE(data->get_float32_value(fTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - double fTest64; - ASSERT_FALSE(data->get_float64_value(fTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - long double fTest128; - ASSERT_FALSE(data->get_float128_value(fTest128, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - char cTest8; - ASSERT_FALSE(data->get_char8_value(cTest8, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - wchar_t cTest16; - ASSERT_FALSE(data->get_char16_value(cTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - octet oTest; - ASSERT_FALSE(data->get_byte_value(oTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - bool bTest; - ASSERT_FALSE(data->get_bool_value(bTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::string sTest; - ASSERT_FALSE(data->get_string_value(sTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::wstring wsTest; - ASSERT_FALSE(data->get_wstring_value(wsTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::string sEnumTest; - ASSERT_FALSE(data->get_enum_value(sEnumTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - // SERIALIZATION TEST - ArrayArrayStruct seq; - ArrayArrayStructPubSubType seqpb; - - SerializedPayload_t dynamic_payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(data, &dynamic_payload)); - ASSERT_TRUE(seqpb.deserialize(&dynamic_payload, &seq)); - - uint32_t static_payloadSize = static_cast(seqpb.getSerializedSizeProvider(&seq)()); - SerializedPayload_t static_payload(static_payloadSize); - ASSERT_TRUE(seqpb.serialize(&seq, &static_payload)); - ASSERT_TRUE(static_payload.length == static_payloadSize); - types::DynamicData* data3 = DynamicDataFactory::get_instance()->create_data(array_type); - ASSERT_TRUE(pubsubType.deserialize(&static_payload, data3)); - ASSERT_TRUE(data3->equals(data)); - - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data2) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data3) == ReturnCode_t::RETCODE_OK); - } - ASSERT_TRUE(DynamicTypeBuilderFactory::get_instance()->is_empty()); - ASSERT_TRUE(DynamicDataFactory::get_instance()->is_empty()); -} - -TEST_F(DynamicTypesTests, DynamicType_map_unit_tests) -{ - uint32_t map_length = 2; - { - // Then - DynamicTypeBuilder_ptr base_type_builder = DynamicTypeBuilderFactory::get_instance()->create_int32_builder(); - ASSERT_TRUE(base_type_builder != nullptr); - auto base_type = base_type_builder->build(); - - DynamicTypeBuilder_ptr map_type_builder = DynamicTypeBuilderFactory::get_instance()->create_map_builder( - base_type_builder.get(), base_type_builder.get(), map_length); - ASSERT_TRUE(map_type_builder != nullptr); - auto map_type = map_type_builder->build(); - ASSERT_TRUE(map_type != nullptr); - - DynamicData* data = DynamicDataFactory::get_instance()->create_data(map_type); - - ASSERT_FALSE(data->set_int32_value(10, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_string_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - // Try to write on an empty position - ASSERT_FALSE(data->set_int32_value(234, 0) == ReturnCode_t::RETCODE_OK); - - MemberId keyId; - MemberId valueId; - auto key_data = DynamicDataFactory::get_instance()->create_data(base_type); - ASSERT_TRUE(data->insert_map_data(key_data, keyId, valueId) == ReturnCode_t::RETCODE_OK); - - // Try to Add the same key twice. - ASSERT_FALSE(data->insert_map_data(key_data, keyId, valueId) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(key_data) == ReturnCode_t::RETCODE_OK); - - MemberId keyId2; - MemberId valueId2; - key_data = DynamicDataFactory::get_instance()->create_data(base_type); - key_data->set_int32_value(2, MEMBER_ID_INVALID); - ASSERT_TRUE(data->insert_map_data(key_data, keyId2, valueId2) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(key_data) == ReturnCode_t::RETCODE_OK); - - // Try to Add one more than the limit - auto key_data2 = DynamicDataFactory::get_instance()->create_data(base_type); - key_data2->set_int32_value(3, MEMBER_ID_INVALID); - ASSERT_FALSE(data->insert_map_data(key_data2, keyId, valueId) == ReturnCode_t::RETCODE_OK); - - // Set and get a value. - int32_t test1(234); - ASSERT_TRUE(data->set_int32_value(test1, valueId) == ReturnCode_t::RETCODE_OK); - int32_t test2(0); - ASSERT_TRUE(data->get_int32_value(test2, valueId) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(test1 == test2); - - // Serialize <-> Deserialize Test - DynamicPubSubType pubsubType(map_type); - uint32_t payloadSize = static_cast(pubsubType.getSerializedSizeProvider(data)()); - SerializedPayload_t payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(data, &payload)); - ASSERT_TRUE(payload.length == payloadSize); - - types::DynamicData* data2 = DynamicDataFactory::get_instance()->create_data(map_type); - ASSERT_TRUE(pubsubType.deserialize(&payload, data2)); - ASSERT_TRUE(data2->equals(data)); - - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data2) == ReturnCode_t::RETCODE_OK); - - // Check items count with removes - ASSERT_TRUE(data->get_item_count() == 2); - ASSERT_FALSE(data->remove_map_data(valueId) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(data->get_item_count() == 2); - ASSERT_TRUE(data->remove_map_data(keyId) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(data->get_item_count() == 1); - ASSERT_TRUE(data->clear_all_values() == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(data->get_item_count() == 0); - - ASSERT_FALSE(data->set_int32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_int16_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint16_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_int64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float128_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_char8_value('a', MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_char16_value(L'a', MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_byte_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_bool_value(false, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_string_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_wstring_value(L"", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_enum_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - int32_t iTest32; - ASSERT_FALSE(data->get_int32_value(iTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint32_t uTest32; - ASSERT_FALSE(data->get_uint32_value(uTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - int16_t iTest16; - ASSERT_FALSE(data->get_int16_value(iTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint16_t uTest16; - ASSERT_FALSE(data->get_uint16_value(uTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - int64_t iTest64; - ASSERT_FALSE(data->get_int64_value(iTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint64_t uTest64; - ASSERT_FALSE(data->get_uint64_value(uTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - float fTest32; - ASSERT_FALSE(data->get_float32_value(fTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - double fTest64; - ASSERT_FALSE(data->get_float64_value(fTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - long double fTest128; - ASSERT_FALSE(data->get_float128_value(fTest128, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - char cTest8; - ASSERT_FALSE(data->get_char8_value(cTest8, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - wchar_t cTest16; - ASSERT_FALSE(data->get_char16_value(cTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - octet oTest; - ASSERT_FALSE(data->get_byte_value(oTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - bool bTest; - ASSERT_FALSE(data->get_bool_value(bTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::string sTest; - ASSERT_FALSE(data->get_string_value(sTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::wstring wsTest; - ASSERT_FALSE(data->get_wstring_value(wsTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::string sEnumTest; - ASSERT_FALSE(data->get_enum_value(sEnumTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - //// SERIALIZATION TEST - //MapStruct seq; - //MapStructPubSubType seqpb; - - //uint32_t payloadSize3 = static_cast(pubsubType.getSerializedSizeProvider(data)()); - //SerializedPayload_t dynamic_payload(payloadSize3); - //ASSERT_TRUE(pubsubType.serialize(data, &dynamic_payload)); - //ASSERT_TRUE(dynamic_payload.length == payloadSize3); - //ASSERT_TRUE(seqpb.deserialize(&dynamic_payload, &seq)); - - //uint32_t static_payloadSize = static_cast(seqpb.getSerializedSizeProvider(&seq)()); - //SerializedPayload_t static_payload(static_payloadSize); - //ASSERT_TRUE(seqpb.serialize(&seq, &static_payload)); - //ASSERT_TRUE(static_payload.length == static_payloadSize); - //types::DynamicData* data3 = DynamicDataFactory::get_instance()->create_data(map_type); - //ASSERT_TRUE(pubsubType.deserialize(&static_payload, data3)); - //ASSERT_TRUE(data3->equals(data)); - - //ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data) == ReturnCode_t::RETCODE_OK); - //ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data2) == ReturnCode_t::RETCODE_OK); - //ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data3) == ReturnCode_t::RETCODE_OK); - - // Delete the map - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(key_data2) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data) == ReturnCode_t::RETCODE_OK); - } - ASSERT_TRUE(DynamicTypeBuilderFactory::get_instance()->is_empty()); - ASSERT_TRUE(DynamicDataFactory::get_instance()->is_empty()); -} - -TEST_F(DynamicTypesTests, DynamicType_map_of_maps_unit_tests) -{ - uint32_t map_length = 2; - { - // Then - DynamicTypeBuilder_ptr base_type_builder = DynamicTypeBuilderFactory::get_instance()->create_int32_builder(); - ASSERT_TRUE(base_type_builder != nullptr); - auto base_type = base_type_builder->build(); - - DynamicTypeBuilder_ptr map_type_builder = DynamicTypeBuilderFactory::get_instance()->create_map_builder( - base_type_builder.get(), base_type_builder.get(), map_length); - ASSERT_TRUE(map_type_builder != nullptr); - auto map_type = map_type_builder->build(); - ASSERT_TRUE(map_type != nullptr); - - DynamicTypeBuilder_ptr map_map_type_builder = DynamicTypeBuilderFactory::get_instance()->create_map_builder( - base_type_builder.get(), map_type_builder.get(), map_length); - ASSERT_TRUE(map_map_type_builder != nullptr); - auto map_map_type = map_map_type_builder->build(); - ASSERT_TRUE(map_map_type != nullptr); - - DynamicData* data = DynamicDataFactory::get_instance()->create_data(map_map_type); - - ASSERT_FALSE(data->set_int32_value(10, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_string_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - MemberId keyId; - MemberId valueId; - auto key_data = DynamicDataFactory::get_instance()->create_data(base_type); - ASSERT_TRUE(data->insert_map_data(key_data, keyId, valueId) == ReturnCode_t::RETCODE_OK); - - // Try to Add the same key twice. - ASSERT_FALSE(data->insert_map_data(key_data, keyId, valueId) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(key_data) == ReturnCode_t::RETCODE_OK); - - MemberId keyId2; - MemberId valueId2; - key_data = DynamicDataFactory::get_instance()->create_data(base_type); - key_data->set_int32_value(2, MEMBER_ID_INVALID); - ASSERT_TRUE(data->insert_map_data(key_data, keyId2, valueId2) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(key_data) == ReturnCode_t::RETCODE_OK); - - // Try to Add one more than the limit - auto key_data2 = DynamicDataFactory::get_instance()->create_data(base_type); - key_data2->set_int32_value(3, MEMBER_ID_INVALID); - ASSERT_FALSE(data->insert_map_data(key_data2, keyId, valueId) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(key_data2) == ReturnCode_t::RETCODE_OK); - - auto seq_data = data->loan_value(valueId); - ASSERT_TRUE(seq_data != nullptr); - - auto key_data3 = DynamicDataFactory::get_instance()->create_data(base_type); - ASSERT_TRUE(seq_data->insert_map_data(key_data3, keyId, valueId) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(key_data3) == ReturnCode_t::RETCODE_OK); - - // Set and get a value. - int32_t test1(234); - ASSERT_TRUE(seq_data->set_int32_value(test1, valueId) == ReturnCode_t::RETCODE_OK); - int32_t test2(0); - ASSERT_TRUE(seq_data->get_int32_value(test2, valueId) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(test1 == test2); - - ASSERT_TRUE(data->return_loaned_value(seq_data) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->return_loaned_value(seq_data) == ReturnCode_t::RETCODE_OK); - - ASSERT_FALSE(data->set_int32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_int16_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint16_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_int64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_uint64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float32_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float64_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_float128_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_char8_value('a', MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_char16_value(L'a', MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_byte_value(0, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_bool_value(false, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_string_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_wstring_value(L"", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(data->set_enum_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - int32_t iTest32; - ASSERT_FALSE(data->get_int32_value(iTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint32_t uTest32; - ASSERT_FALSE(data->get_uint32_value(uTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - int16_t iTest16; - ASSERT_FALSE(data->get_int16_value(iTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint16_t uTest16; - ASSERT_FALSE(data->get_uint16_value(uTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - int64_t iTest64; - ASSERT_FALSE(data->get_int64_value(iTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - uint64_t uTest64; - ASSERT_FALSE(data->get_uint64_value(uTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - float fTest32; - ASSERT_FALSE(data->get_float32_value(fTest32, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - double fTest64; - ASSERT_FALSE(data->get_float64_value(fTest64, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - long double fTest128; - ASSERT_FALSE(data->get_float128_value(fTest128, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - char cTest8; - ASSERT_FALSE(data->get_char8_value(cTest8, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - wchar_t cTest16; - ASSERT_FALSE(data->get_char16_value(cTest16, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - octet oTest; - ASSERT_FALSE(data->get_byte_value(oTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - bool bTest; - ASSERT_FALSE(data->get_bool_value(bTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::string sTest; - ASSERT_FALSE(data->get_string_value(sTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::wstring wsTest; - ASSERT_FALSE(data->get_wstring_value(wsTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - std::string sEnumTest; - ASSERT_FALSE(data->get_enum_value(sEnumTest, MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - // Serialize <-> Deserialize Test - DynamicPubSubType pubsubType(map_map_type); - uint32_t payloadSize = static_cast(pubsubType.getSerializedSizeProvider(data)()); - SerializedPayload_t payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(data, &payload)); - ASSERT_TRUE(payload.length == payloadSize); - - types::DynamicData* data2 = DynamicDataFactory::get_instance()->create_data(map_map_type); - ASSERT_TRUE(pubsubType.deserialize(&payload, data2)); - ASSERT_TRUE(data2->equals(data)); - - //// SERIALIZATION TEST - //MapMapStruct seq; - //MapMapStructPubSubType seqpb; - - //uint32_t payloadSize3 = static_cast(pubsubType.getSerializedSizeProvider(data)()); - //SerializedPayload_t dynamic_payload(payloadSize3); - //ASSERT_TRUE(pubsubType.serialize(data, &dynamic_payload)); - //ASSERT_TRUE(dynamic_payload.length == payloadSize3); - //ASSERT_TRUE(seqpb.deserialize(&dynamic_payload, &seq)); - - //uint32_t static_payloadSize = static_cast(seqpb.getSerializedSizeProvider(&seq)()); - //SerializedPayload_t static_payload(static_payloadSize); - //ASSERT_TRUE(seqpb.serialize(&seq, &static_payload)); - //ASSERT_TRUE(static_payload.length == static_payloadSize); - //types::DynamicData* data3 = DynamicDataFactory::get_instance()->create_data(map_map_type); - //ASSERT_TRUE(pubsubType.deserialize(&static_payload, data3)); - //ASSERT_TRUE(data3->equals(data)); - - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data2) == ReturnCode_t::RETCODE_OK); - //ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data3) == ReturnCode_t::RETCODE_OK); - } - ASSERT_TRUE(DynamicTypeBuilderFactory::get_instance()->is_empty()); - ASSERT_TRUE(DynamicDataFactory::get_instance()->is_empty()); -} - -TEST_F(DynamicTypesTests, DynamicType_structure_unit_tests) -{ - { - DynamicTypeBuilder_ptr base_type_builder = DynamicTypeBuilderFactory::get_instance()->create_int32_builder(); - ASSERT_TRUE(base_type_builder != nullptr); - auto base_type = base_type_builder->build(); - - DynamicTypeBuilder_ptr base_type_builder2 = DynamicTypeBuilderFactory::get_instance()->create_int64_builder(); - ASSERT_TRUE(base_type_builder2 != nullptr); - auto base_type2 = base_type_builder2->build(); - - DynamicTypeBuilder_ptr struct_type_builder = DynamicTypeBuilderFactory::get_instance()->create_struct_builder(); - ASSERT_TRUE(struct_type_builder != nullptr); - - // Add members to the struct. - ASSERT_TRUE(struct_type_builder->add_member(0, "int32", base_type) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(struct_type_builder->add_member(1, "int64", base_type2) == ReturnCode_t::RETCODE_OK); - - auto struct_type = struct_type_builder->build(); - ASSERT_TRUE(struct_type != nullptr); - auto struct_data = DynamicDataFactory::get_instance()->create_data(struct_type); - ASSERT_TRUE(struct_data != nullptr); - - ASSERT_FALSE(struct_data->set_int32_value(10, 1) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(struct_data->set_string_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - // Set and get the child values. - int32_t test1(234); - ASSERT_TRUE(struct_data->set_int32_value(test1, 0) == ReturnCode_t::RETCODE_OK); - int32_t test2(0); - ASSERT_TRUE(struct_data->get_int32_value(test2, 0) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(test1 == test2); - int64_t test3(234); - ASSERT_TRUE(struct_data->set_int64_value(test3, 1) == ReturnCode_t::RETCODE_OK); - int64_t test4(0); - ASSERT_TRUE(struct_data->get_int64_value(test4, 1) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(test3 == test4); - - // Serialize <-> Deserialize Test - DynamicPubSubType pubsubType(struct_type); - uint32_t payloadSize = static_cast(pubsubType.getSerializedSizeProvider(struct_data)()); - SerializedPayload_t payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(struct_data, &payload)); - ASSERT_TRUE(payload.length == payloadSize); - - types::DynamicData* data2 = DynamicDataFactory::get_instance()->create_data(struct_type); - ASSERT_TRUE(pubsubType.deserialize(&payload, data2)); - ASSERT_TRUE(data2->equals(struct_data)); - - // SERIALIZATION TEST - StructStruct seq; - StructStructPubSubType seqpb; - - uint32_t payloadSize3 = static_cast(pubsubType.getSerializedSizeProvider(struct_data)()); - SerializedPayload_t dynamic_payload(payloadSize3); - ASSERT_TRUE(pubsubType.serialize(struct_data, &dynamic_payload)); - ASSERT_TRUE(dynamic_payload.length == payloadSize3); - ASSERT_TRUE(seqpb.deserialize(&dynamic_payload, &seq)); - - uint32_t static_payloadSize = static_cast(seqpb.getSerializedSizeProvider(&seq)()); - SerializedPayload_t static_payload(static_payloadSize); - ASSERT_TRUE(seqpb.serialize(&seq, &static_payload)); - ASSERT_TRUE(static_payload.length == static_payloadSize); - types::DynamicData* data3 = DynamicDataFactory::get_instance()->create_data(struct_type); - ASSERT_TRUE(pubsubType.deserialize(&static_payload, data3)); - ASSERT_TRUE(data3->equals(struct_data)); - - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data2) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data3) == ReturnCode_t::RETCODE_OK); - - // Delete the structure - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(struct_data) == ReturnCode_t::RETCODE_OK); - - } - ASSERT_TRUE(DynamicTypeBuilderFactory::get_instance()->is_empty()); - ASSERT_TRUE(DynamicDataFactory::get_instance()->is_empty()); -} - -TEST_F(DynamicTypesTests, DynamicType_structure_inheritance_unit_tests) -{ - { - DynamicTypeBuilder_ptr base_type_builder = DynamicTypeBuilderFactory::get_instance()->create_int32_builder(); - ASSERT_TRUE(base_type_builder != nullptr); - auto base_type = base_type_builder->build(); - - DynamicTypeBuilder_ptr base_type_builder2 = DynamicTypeBuilderFactory::get_instance()->create_int64_builder(); - ASSERT_TRUE(base_type_builder2 != nullptr); - auto base_type2 = base_type_builder2->build(); - - DynamicTypeBuilder_ptr struct_type_builder = DynamicTypeBuilderFactory::get_instance()->create_struct_builder(); - ASSERT_TRUE(struct_type_builder != nullptr); - - // Add members to the struct. - ASSERT_TRUE(struct_type_builder->add_member(0, "int32", base_type) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(struct_type_builder->add_member(1, "int64", base_type2) == ReturnCode_t::RETCODE_OK); - - auto struct_type = struct_type_builder->build(); - ASSERT_TRUE(struct_type != nullptr); - - // Try to create the child struct without parent - DynamicTypeBuilder_ptr child_struct_type_builder = - DynamicTypeBuilderFactory::get_instance()->create_child_struct_builder(nullptr); - ASSERT_FALSE(child_struct_type_builder != nullptr); - - // Create the child struct. - child_struct_type_builder = DynamicTypeBuilderFactory::get_instance()->create_child_struct_builder( - struct_type_builder.get()); - ASSERT_TRUE(child_struct_type_builder != nullptr); - - // Add a new member to the child struct. - ASSERT_TRUE(child_struct_type_builder->add_member(2, "child_int32", base_type) == ReturnCode_t::RETCODE_OK); - - // try to add a member to override one of the parent struct. - ASSERT_FALSE(child_struct_type_builder->add_member(3, "int32", base_type) == ReturnCode_t::RETCODE_OK); - - auto child_struct_type = child_struct_type_builder->build(); - ASSERT_TRUE(child_struct_type != nullptr); - auto struct_data = DynamicDataFactory::get_instance()->create_data(child_struct_type); - ASSERT_TRUE(struct_data != nullptr); - - ASSERT_FALSE(struct_data->set_int32_value(10, 1) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(struct_data->set_string_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - // Set and get the parent values. - int32_t test1(234); - ASSERT_TRUE(struct_data->set_int32_value(test1, 0) == ReturnCode_t::RETCODE_OK); - int32_t test2(0); - ASSERT_TRUE(struct_data->get_int32_value(test2, 0) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(test1 == test2); - int64_t test3(234); - ASSERT_TRUE(struct_data->set_int64_value(test3, 1) == ReturnCode_t::RETCODE_OK); - int64_t test4(0); - ASSERT_TRUE(struct_data->get_int64_value(test4, 1) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(test3 == test4); - // Set and get the child value. - int32_t test5(234); - ASSERT_TRUE(struct_data->set_int32_value(test5, 2) == ReturnCode_t::RETCODE_OK); - int32_t test6(0); - ASSERT_TRUE(struct_data->get_int32_value(test6, 2) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(test5 == test6); - - // Serialize <-> Deserialize Test - DynamicPubSubType pubsubType(child_struct_type); - uint32_t payloadSize = static_cast(pubsubType.getSerializedSizeProvider(struct_data)()); - SerializedPayload_t payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(struct_data, &payload)); - ASSERT_TRUE(payload.length == payloadSize); - - types::DynamicData* data2 = DynamicDataFactory::get_instance()->create_data(child_struct_type); - ASSERT_TRUE(pubsubType.deserialize(&payload, data2)); - ASSERT_TRUE(data2->equals(struct_data)); - - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data2) == ReturnCode_t::RETCODE_OK); - - // Delete the structure - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(struct_data) == ReturnCode_t::RETCODE_OK); - } - ASSERT_TRUE(DynamicTypeBuilderFactory::get_instance()->is_empty()); - ASSERT_TRUE(DynamicDataFactory::get_instance()->is_empty()); -} - -TEST_F(DynamicTypesTests, DynamicType_multi_structure_unit_tests) -{ - { - DynamicTypeBuilder_ptr base_type_builder = DynamicTypeBuilderFactory::get_instance()->create_int32_builder(); - ASSERT_TRUE(base_type_builder != nullptr); - auto base_type = base_type_builder->build(); - - DynamicTypeBuilder_ptr base_type_builder2 = DynamicTypeBuilderFactory::get_instance()->create_int64_builder(); - ASSERT_TRUE(base_type_builder2 != nullptr); - auto base_type2 = base_type_builder2->build(); - - DynamicTypeBuilder_ptr struct_type_builder = DynamicTypeBuilderFactory::get_instance()->create_struct_builder(); - ASSERT_TRUE(struct_type_builder != nullptr); - - // Add members to the struct. - ASSERT_TRUE(struct_type_builder->add_member(0, "int32", base_type) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(struct_type_builder->add_member(1, "int64", base_type2) == ReturnCode_t::RETCODE_OK); - - auto struct_type = struct_type_builder->build(); - ASSERT_TRUE(struct_type != nullptr); - - // Create the parent struct. - DynamicTypeBuilder_ptr parent_struct_type_builder = - DynamicTypeBuilderFactory::get_instance()->create_struct_builder(); - ASSERT_TRUE(parent_struct_type_builder != nullptr); - - // Add members to the parent struct. - ASSERT_TRUE(parent_struct_type_builder->add_member(0, "child_struct", struct_type) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(parent_struct_type_builder->add_member(1, "child_int64", base_type2) == ReturnCode_t::RETCODE_OK); - - auto parent_struct_type = parent_struct_type_builder->build(); - ASSERT_TRUE(parent_struct_type != nullptr); - - auto struct_data = DynamicDataFactory::get_instance()->create_data(parent_struct_type); - ASSERT_TRUE(struct_data != nullptr); - - ASSERT_FALSE(struct_data->set_int32_value(10, 1) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(struct_data->set_string_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - // Set and get the child values. - int64_t test1(234); - ASSERT_TRUE(struct_data->set_int64_value(test1, 1) == ReturnCode_t::RETCODE_OK); - int64_t test2(0); - ASSERT_TRUE(struct_data->get_int64_value(test2, 1) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(test1 == test2); - - auto child_struct_data = struct_data->loan_value(0); - ASSERT_TRUE(child_struct_data != nullptr); - - // Set and get the child values. - int32_t test3(234); - ASSERT_TRUE(child_struct_data->set_int32_value(test3, 0) == ReturnCode_t::RETCODE_OK); - int32_t test4(0); - ASSERT_TRUE(child_struct_data->get_int32_value(test4, 0) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(test3 == test4); - int64_t test5(234); - ASSERT_TRUE(child_struct_data->set_int64_value(test5, 1) == ReturnCode_t::RETCODE_OK); - int64_t test6(0); - ASSERT_TRUE(child_struct_data->get_int64_value(test6, 1) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(test5 == test6); - - ASSERT_TRUE(struct_data->return_loaned_value(child_struct_data) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(struct_data->return_loaned_value(child_struct_data) == ReturnCode_t::RETCODE_OK); - - // Serialize <-> Deserialize Test - DynamicPubSubType pubsubType(parent_struct_type); - uint32_t payloadSize = static_cast(pubsubType.getSerializedSizeProvider(struct_data)()); - SerializedPayload_t payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(struct_data, &payload)); - ASSERT_TRUE(payload.length == payloadSize); - - types::DynamicData* data2 = DynamicDataFactory::get_instance()->create_data(parent_struct_type); - ASSERT_TRUE(pubsubType.deserialize(&payload, data2)); - ASSERT_TRUE(data2->equals(struct_data)); - - // SERIALIZATION TEST - StructStructStruct seq; - StructStructStructPubSubType seqpb; - - uint32_t payloadSize3 = static_cast(pubsubType.getSerializedSizeProvider(struct_data)()); - SerializedPayload_t dynamic_payload(payloadSize3); - ASSERT_TRUE(pubsubType.serialize(struct_data, &dynamic_payload)); - ASSERT_TRUE(dynamic_payload.length == payloadSize3); - ASSERT_TRUE(seqpb.deserialize(&dynamic_payload, &seq)); - - uint32_t static_payloadSize = static_cast(seqpb.getSerializedSizeProvider(&seq)()); - SerializedPayload_t static_payload(static_payloadSize); - ASSERT_TRUE(seqpb.serialize(&seq, &static_payload)); - ASSERT_TRUE(static_payload.length == static_payloadSize); - types::DynamicData* data3 = DynamicDataFactory::get_instance()->create_data(parent_struct_type); - ASSERT_TRUE(pubsubType.deserialize(&static_payload, data3)); - ASSERT_TRUE(data3->equals(struct_data)); - - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data2) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data3) == ReturnCode_t::RETCODE_OK); - - // Delete the map - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(struct_data) == ReturnCode_t::RETCODE_OK); - } - ASSERT_TRUE(DynamicTypeBuilderFactory::get_instance()->is_empty()); - ASSERT_TRUE(DynamicDataFactory::get_instance()->is_empty()); -} - -TEST_F(DynamicTypesTests, DynamicType_union_unit_tests) -{ - { - DynamicTypeBuilder_ptr base_type_builder = DynamicTypeBuilderFactory::get_instance()->create_int32_builder(); - ASSERT_TRUE(base_type_builder != nullptr); - auto base_type = base_type_builder->build(); - - DynamicTypeBuilder_ptr base_type_builder2 = DynamicTypeBuilderFactory::get_instance()->create_int64_builder(); - ASSERT_TRUE(base_type_builder2 != nullptr); - auto base_type2 = base_type_builder2->build(); - - DynamicTypeBuilder_ptr union_type_builder = DynamicTypeBuilderFactory::get_instance()->create_union_builder( - base_type_builder.get()); - ASSERT_TRUE(union_type_builder != nullptr); - - // Add members to the union. - ASSERT_TRUE(union_type_builder->add_member(0, "first", base_type, "", { 0 }, true) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(union_type_builder->add_member(1, "second", base_type2, "", { 1 }, - false) == ReturnCode_t::RETCODE_OK); - - // Try to add a second "DEFAULT" value to the union - ASSERT_FALSE(union_type_builder->add_member(0, "third", base_type, "", { 0 }, - true) == ReturnCode_t::RETCODE_OK); - - // Try to add a second value to the same case label - ASSERT_FALSE(union_type_builder->add_member(0, "third", base_type, "", { 1 }, - false) == ReturnCode_t::RETCODE_OK); - - // Create a data of this union - auto union_type = union_type_builder->build(); - ASSERT_TRUE(union_type != nullptr); - auto union_data = DynamicDataFactory::get_instance()->create_data(union_type); - ASSERT_TRUE(union_data != nullptr); - - // Set and get the child values. - ASSERT_FALSE(union_data->set_int32_value(10, 1) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(union_data->set_string_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - uint64_t label; - ASSERT_TRUE(union_data->get_union_label(label) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(label == 0); - - int32_t test1(234); - ASSERT_TRUE(union_data->set_int32_value(test1, 0) == ReturnCode_t::RETCODE_OK); - int32_t test2(0); - ASSERT_TRUE(union_data->get_int32_value(test2, 0) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(test1 == test2); - ASSERT_TRUE(union_data->get_union_label(label) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(label == 0); - - int64_t test3(234); - int64_t test4(0); - - // Try to get values from invalid indexes and from an invalid element ( not the current one ) - ASSERT_FALSE(union_data->get_int32_value(test2, 1) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(union_data->get_int64_value(test4, 1) == ReturnCode_t::RETCODE_OK); - - ASSERT_TRUE(union_data->set_int64_value(test3, 1) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(union_data->get_int64_value(test4, 1) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(test3 == test4); - ASSERT_TRUE(union_data->get_union_label(label) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(label == 1); - - // Serialize <-> Deserialize Test - DynamicPubSubType pubsubType(union_type); - uint32_t payloadSize = static_cast(pubsubType.getSerializedSizeProvider(union_data)()); - SerializedPayload_t payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(union_data, &payload)); - ASSERT_TRUE(payload.length == payloadSize); - - types::DynamicData* data2 = DynamicDataFactory::get_instance()->create_data(union_type); - ASSERT_TRUE(pubsubType.deserialize(&payload, data2)); - ASSERT_TRUE(data2->equals(union_data)); - - // SERIALIZATION TEST - SimpleUnionStruct seq; - SimpleUnionStructPubSubType seqpb; - - uint32_t payloadSize3 = static_cast(pubsubType.getSerializedSizeProvider(union_data)()); - SerializedPayload_t dynamic_payload(payloadSize3); - ASSERT_TRUE(pubsubType.serialize(union_data, &dynamic_payload)); - ASSERT_TRUE(dynamic_payload.length == payloadSize3); - ASSERT_TRUE(seqpb.deserialize(&dynamic_payload, &seq)); - - uint32_t static_payloadSize = static_cast(seqpb.getSerializedSizeProvider(&seq)()); - SerializedPayload_t static_payload(static_payloadSize); - ASSERT_TRUE(seqpb.serialize(&seq, &static_payload)); - ASSERT_TRUE(static_payload.length == static_payloadSize); - types::DynamicData* data3 = DynamicDataFactory::get_instance()->create_data(union_type); - ASSERT_TRUE(pubsubType.deserialize(&static_payload, data3)); - ASSERT_TRUE(data3->equals(union_data)); - - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data2) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data3) == ReturnCode_t::RETCODE_OK); - - // Delete the map - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(union_data) == ReturnCode_t::RETCODE_OK); - } - ASSERT_TRUE(DynamicTypeBuilderFactory::get_instance()->is_empty()); - ASSERT_TRUE(DynamicDataFactory::get_instance()->is_empty()); -} - -TEST_F(DynamicTypesTests, DynamicType_union_with_unions_unit_tests) -{ - { - DynamicTypeBuilder_ptr base_type_builder = DynamicTypeBuilderFactory::get_instance()->create_int32_builder(); - ASSERT_TRUE(base_type_builder != nullptr); - auto base_type = base_type_builder->build(); - - DynamicTypeBuilder_ptr base_type_builder2 = DynamicTypeBuilderFactory::get_instance()->create_int64_builder(); - ASSERT_TRUE(base_type_builder2 != nullptr); - auto base_type2 = base_type_builder2->build(); - - DynamicTypeBuilder_ptr union_type_builder = DynamicTypeBuilderFactory::get_instance()->create_union_builder( - base_type); - ASSERT_TRUE(union_type_builder != nullptr); - - // Add members to the union. - ASSERT_TRUE(union_type_builder->add_member(0, "first", base_type, "", { 0 }, true) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(union_type_builder->add_member(1, "second", base_type2, "", { 1 }, - false) == ReturnCode_t::RETCODE_OK); - - // Try to add a second "DEFAULT" value to the union - ASSERT_FALSE(union_type_builder->add_member(0, "third", base_type, "", { 0 }, - true) == ReturnCode_t::RETCODE_OK); - - // Try to add a second value to the same case label - ASSERT_FALSE(union_type_builder->add_member(0, "third", base_type, "", { 1 }, - false) == ReturnCode_t::RETCODE_OK); - - // Create a data of this union - auto union_type = union_type_builder->build(); - ASSERT_TRUE(union_type != nullptr); - - DynamicTypeBuilder_ptr parent_union_type_builder = - DynamicTypeBuilderFactory::get_instance()->create_union_builder(base_type); - ASSERT_TRUE(parent_union_type_builder != nullptr); - - // Add Members to the parent union - ASSERT_TRUE(parent_union_type_builder->add_member(0, "first", base_type, "", { 0 }, - true) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(parent_union_type_builder->add_member(1, "second", union_type, "", { 1 }, - false) == ReturnCode_t::RETCODE_OK); - - DynamicType_ptr created_type = DynamicTypeBuilderFactory::get_instance()->create_type( - parent_union_type_builder.get()); - ASSERT_TRUE(created_type != nullptr); - auto union_data = DynamicDataFactory::get_instance()->create_data(parent_union_type_builder.get()); - ASSERT_TRUE(union_data != nullptr); - - // Set and get the child values. - ASSERT_FALSE(union_data->set_int32_value(10, 1) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(union_data->set_string_value("", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - - uint64_t label; - ASSERT_TRUE(union_data->get_union_label(label) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(label == 0); - - int32_t test1(234); - ASSERT_TRUE(union_data->set_int32_value(test1, 0) == ReturnCode_t::RETCODE_OK); - int32_t test2(0); - ASSERT_TRUE(union_data->get_int32_value(test2, 0) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(test1 == test2); - ASSERT_TRUE(union_data->get_union_label(label) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(label == 0); - - // Loan Value ( Activates this union id ) - DynamicData* child_data = union_data->loan_value(1); - ASSERT_TRUE(child_data != 0); - - int64_t test3(234); - int64_t test4(0); - - // Try to get values from invalid indexes and from an invalid element ( not the current one ) - ASSERT_FALSE(child_data->get_int32_value(test2, 1) == ReturnCode_t::RETCODE_OK); - ASSERT_FALSE(child_data->get_int64_value(test4, 1) == ReturnCode_t::RETCODE_OK); - - ASSERT_TRUE(child_data->set_int64_value(test3, 1) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(child_data->get_int64_value(test4, 1) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(test3 == test4); - - ASSERT_TRUE(union_data->return_loaned_value(child_data) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(union_data->get_union_label(label) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(label == 1); - - // Serialize <-> Deserialize Test - DynamicPubSubType pubsubType(created_type); - uint32_t payloadSize = static_cast(pubsubType.getSerializedSizeProvider(union_data)()); - SerializedPayload_t payload(payloadSize); - ASSERT_TRUE(pubsubType.serialize(union_data, &payload)); - ASSERT_TRUE(payload.length == payloadSize); - - types::DynamicData* data2 = DynamicDataFactory::get_instance()->create_data(created_type); - ASSERT_TRUE(pubsubType.deserialize(&payload, data2)); - ASSERT_TRUE(data2->equals(union_data)); - - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data2) == ReturnCode_t::RETCODE_OK); - - // Delete the map - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(union_data) == ReturnCode_t::RETCODE_OK); - } - ASSERT_TRUE(DynamicTypeBuilderFactory::get_instance()->is_empty()); - ASSERT_TRUE(DynamicDataFactory::get_instance()->is_empty()); -} - -TEST_F(DynamicTypesTests, DynamicType_XML_EnumStruct_test) -{ - using namespace xmlparser; - using namespace types; - - XMLP_ret ret = XMLProfileManager::loadXMLFile(DynamicTypesTests::config_file()); - ASSERT_EQ(ret, XMLP_ret::XML_OK); - { - DynamicPubSubType* pbType = XMLProfileManager::CreateDynamicPubSubType("EnumStruct"); - - DynamicTypeBuilderFactory* m_factory = DynamicTypeBuilderFactory::get_instance(); - - // Enum - DynamicTypeBuilder_ptr enum_builder = m_factory->create_enum_builder(); - enum_builder->add_empty_member(0, "A"); - enum_builder->add_empty_member(1, "B"); - enum_builder->add_empty_member(2, "C"); - enum_builder->set_name("MyEnum"); - - // Struct EnumStruct - DynamicTypeBuilder_ptr es_builder = m_factory->create_struct_builder(); - es_builder->add_member(0, "my_enum", enum_builder.get()); - es_builder->set_name("EnumStruct"); - - ASSERT_TRUE(pbType->GetDynamicType()->equals(es_builder->build().get())); - - delete(pbType); - XMLProfileManager::DeleteInstance(); - } -} - -TEST_F(DynamicTypesTests, DynamicType_XML_AliasStruct_test) -{ - using namespace xmlparser; - using namespace types; - - XMLP_ret ret = XMLProfileManager::loadXMLFile(DynamicTypesTests::config_file()); - ASSERT_EQ(ret, XMLP_ret::XML_OK); - { - DynamicPubSubType* pbType = XMLProfileManager::CreateDynamicPubSubType("AliasStruct"); - - DynamicTypeBuilderFactory* m_factory = DynamicTypeBuilderFactory::get_instance(); - - // Enum - DynamicTypeBuilder_ptr enum_builder = m_factory->create_enum_builder(); - enum_builder->add_empty_member(0, "A"); - enum_builder->add_empty_member(1, "B"); - enum_builder->add_empty_member(2, "C"); - enum_builder->set_name("MyEnum"); - - // Alias - DynamicTypeBuilder_ptr alias_builder = m_factory->create_alias_builder(enum_builder.get(), "MyAliasEnum"); - - // Struct AliasStruct - DynamicTypeBuilder_ptr aliass_builder_ptr = m_factory->create_struct_builder(); - aliass_builder_ptr->add_member(0, "my_alias", alias_builder.get()); - aliass_builder_ptr->set_name("AliasStruct"); - - ASSERT_TRUE(pbType->GetDynamicType()->equals(aliass_builder_ptr->build().get())); - - delete(pbType); - XMLProfileManager::DeleteInstance(); - } -} - -TEST_F(DynamicTypesTests, DynamicType_XML_AliasAliasStruct_test) -{ - using namespace xmlparser; - using namespace types; - - XMLP_ret ret = XMLProfileManager::loadXMLFile(DynamicTypesTests::config_file()); - ASSERT_EQ(ret, XMLP_ret::XML_OK); - { - DynamicPubSubType* pbType = XMLProfileManager::CreateDynamicPubSubType("AliasAliasStruct"); - - DynamicTypeBuilderFactory* m_factory = DynamicTypeBuilderFactory::get_instance(); - - // Enum - DynamicTypeBuilder_ptr enum_builder = m_factory->create_enum_builder(); - enum_builder->add_empty_member(0, "A"); - enum_builder->add_empty_member(1, "B"); - enum_builder->add_empty_member(2, "C"); - enum_builder->set_name("MyEnum"); - - // Alias and aliasalias - DynamicTypeBuilder_ptr alias_builder = m_factory->create_alias_builder(enum_builder.get(), "MyAliasEnum"); - DynamicTypeBuilder_ptr alias_alias_builder = m_factory->create_alias_builder( - alias_builder.get(), "MyAliasAliasEnum"); - - // Struct AliasAliasStruct - DynamicTypeBuilder_ptr aliasAliasS_builder_ptr = m_factory->create_struct_builder(); - aliasAliasS_builder_ptr->add_member(0, "my_alias_alias", alias_alias_builder.get()); - aliasAliasS_builder_ptr->set_name("AliasAliasStruct"); - - ASSERT_TRUE(pbType->GetDynamicType()->equals(aliasAliasS_builder_ptr->build().get())); - - delete(pbType); - XMLProfileManager::DeleteInstance(); - } -} - -TEST_F(DynamicTypesTests, DynamicType_XML_BoolStruct_test) -{ - using namespace xmlparser; - using namespace types; - - XMLP_ret ret = XMLProfileManager::loadXMLFile(DynamicTypesTests::config_file()); - ASSERT_EQ(ret, XMLP_ret::XML_OK); - { - DynamicPubSubType* pbType = XMLProfileManager::CreateDynamicPubSubType("BoolStruct"); - - DynamicTypeBuilderFactory* m_factory = DynamicTypeBuilderFactory::get_instance(); - - // Boolean - DynamicTypeBuilder_ptr boolean_builder = m_factory->create_bool_builder(); - - // Struct BoolStruct - DynamicTypeBuilder_ptr bool_builder_ptr = m_factory->create_struct_builder(); - bool_builder_ptr->add_member(0, "my_bool", boolean_builder.get()); - bool_builder_ptr->set_name("BoolStruct"); - - ASSERT_TRUE(pbType->GetDynamicType()->equals(bool_builder_ptr->build().get())); - - delete(pbType); - XMLProfileManager::DeleteInstance(); - } -} - -TEST_F(DynamicTypesTests, DynamicType_XML_OctetStruct_test) -{ - using namespace xmlparser; - using namespace types; - - XMLP_ret ret = XMLProfileManager::loadXMLFile(DynamicTypesTests::config_file()); - ASSERT_EQ(ret, XMLP_ret::XML_OK); - { - DynamicPubSubType* pbType = XMLProfileManager::CreateDynamicPubSubType("OctetStruct"); - - DynamicTypeBuilderFactory* m_factory = DynamicTypeBuilderFactory::get_instance(); - - // Byte - DynamicTypeBuilder_ptr byte_builder = m_factory->create_byte_builder(); - - // Struct OctetStruct - DynamicTypeBuilder_ptr octet_builder_ptr = m_factory->create_struct_builder(); - octet_builder_ptr->add_member(0, "my_octet", byte_builder.get()); - octet_builder_ptr->set_name("OctetStruct"); - - ASSERT_TRUE(pbType->GetDynamicType()->equals(octet_builder_ptr->build().get())); - - delete(pbType); - XMLProfileManager::DeleteInstance(); - } -} - -TEST_F(DynamicTypesTests, DynamicType_XML_ShortStruct_test) -{ - using namespace xmlparser; - using namespace types; - - XMLP_ret ret = XMLProfileManager::loadXMLFile(DynamicTypesTests::config_file()); - ASSERT_EQ(ret, XMLP_ret::XML_OK); - { - DynamicPubSubType* pbType = XMLProfileManager::CreateDynamicPubSubType("ShortStruct"); - - DynamicTypeBuilderFactory* m_factory = DynamicTypeBuilderFactory::get_instance(); - - // Int16 - DynamicTypeBuilder_ptr int16_builder = m_factory->create_int16_builder(); - - // Struct ShortStruct - DynamicTypeBuilder_ptr int16_builder_ptr = m_factory->create_struct_builder(); - int16_builder_ptr->add_member(0, "my_int16", int16_builder.get()); - int16_builder_ptr->set_name("ShortStruct"); - - ASSERT_TRUE(pbType->GetDynamicType()->equals(int16_builder_ptr->build().get())); - - delete(pbType); - XMLProfileManager::DeleteInstance(); - } -} - -TEST_F(DynamicTypesTests, DynamicType_XML_LongStruct_test) -{ - using namespace xmlparser; - using namespace types; - - XMLP_ret ret = XMLProfileManager::loadXMLFile(DynamicTypesTests::config_file()); - ASSERT_EQ(ret, XMLP_ret::XML_OK); - { - DynamicPubSubType* pbType = XMLProfileManager::CreateDynamicPubSubType("LongStruct"); - - DynamicTypeBuilderFactory* m_factory = DynamicTypeBuilderFactory::get_instance(); - - // Int32 - DynamicTypeBuilder_ptr int32_builder = m_factory->create_int32_builder(); - - // Struct LongStruct - DynamicTypeBuilder_ptr int32_builder_ptr = m_factory->create_struct_builder(); - int32_builder_ptr->add_member(0, "my_int32", int32_builder.get()); - int32_builder_ptr->set_name("LongStruct"); - - ASSERT_TRUE(pbType->GetDynamicType()->equals(int32_builder_ptr->build().get())); - - delete(pbType); - XMLProfileManager::DeleteInstance(); - } -} - -TEST_F(DynamicTypesTests, DynamicType_XML_LongLongStruct_test) -{ - using namespace xmlparser; - using namespace types; - - XMLP_ret ret = XMLProfileManager::loadXMLFile(DynamicTypesTests::config_file()); - ASSERT_EQ(ret, XMLP_ret::XML_OK); - { - DynamicPubSubType* pbType = XMLProfileManager::CreateDynamicPubSubType("LongLongStruct"); - - DynamicTypeBuilderFactory* m_factory = DynamicTypeBuilderFactory::get_instance(); - - // Int64 - DynamicTypeBuilder_ptr int64_builder = m_factory->create_int64_builder(); - - // Struct LongLongStruct - DynamicTypeBuilder_ptr int64_builder_ptr = m_factory->create_struct_builder(); - int64_builder_ptr->add_member(0, "my_int64", int64_builder.get()); - int64_builder_ptr->set_name("LongLongStruct"); - - ASSERT_TRUE(pbType->GetDynamicType()->equals(int64_builder_ptr->build().get())); - - delete(pbType); - XMLProfileManager::DeleteInstance(); - } -} - -TEST_F(DynamicTypesTests, DynamicType_XML_UShortStruct_test) -{ - using namespace xmlparser; - using namespace types; - - XMLP_ret ret = XMLProfileManager::loadXMLFile(DynamicTypesTests::config_file()); - ASSERT_EQ(ret, XMLP_ret::XML_OK); - { - DynamicPubSubType* pbType = XMLProfileManager::CreateDynamicPubSubType("UShortStruct"); - - DynamicTypeBuilderFactory* m_factory = DynamicTypeBuilderFactory::get_instance(); - - // uint16 - DynamicTypeBuilder_ptr uint16_builder = m_factory->create_uint16_builder(); - - // Struct UShortStruct - DynamicTypeBuilder_ptr uint16_builder_ptr = m_factory->create_struct_builder(); - uint16_builder_ptr->add_member(0, "my_uint16", uint16_builder.get()); - uint16_builder_ptr->set_name("UShortStruct"); - - ASSERT_TRUE(pbType->GetDynamicType()->equals(uint16_builder_ptr->build().get())); - - delete(pbType); - XMLProfileManager::DeleteInstance(); - } -} - -TEST_F(DynamicTypesTests, DynamicType_XML_ULongStruct_test) -{ - using namespace xmlparser; - using namespace types; - - XMLP_ret ret = XMLProfileManager::loadXMLFile(DynamicTypesTests::config_file()); - ASSERT_EQ(ret, XMLP_ret::XML_OK); - { - DynamicPubSubType* pbType = XMLProfileManager::CreateDynamicPubSubType("ULongStruct"); - - DynamicTypeBuilderFactory* m_factory = DynamicTypeBuilderFactory::get_instance(); - - // uint32 - DynamicTypeBuilder_ptr uint32_builder = m_factory->create_uint32_builder(); - - // Struct ULongStruct - DynamicTypeBuilder_ptr uint32_builder_ptr = m_factory->create_struct_builder(); - uint32_builder_ptr->add_member(0, "my_uint32", uint32_builder.get()); - uint32_builder_ptr->set_name("ULongStruct"); - - ASSERT_TRUE(pbType->GetDynamicType()->equals(uint32_builder_ptr->build().get())); - - delete(pbType); - XMLProfileManager::DeleteInstance(); - } -} - -TEST_F(DynamicTypesTests, DynamicType_XML_ULongLongStruct_test) -{ - using namespace xmlparser; - using namespace types; - - XMLP_ret ret = XMLProfileManager::loadXMLFile(DynamicTypesTests::config_file()); - ASSERT_EQ(ret, XMLP_ret::XML_OK); - { - DynamicPubSubType* pbType = XMLProfileManager::CreateDynamicPubSubType("ULongLongStruct"); - - DynamicTypeBuilderFactory* m_factory = DynamicTypeBuilderFactory::get_instance(); - - // uint64 - DynamicTypeBuilder_ptr uint64_builder = m_factory->create_uint64_builder(); - - // Struct ULongLongStruct - DynamicTypeBuilder_ptr uint64_builder_ptr = m_factory->create_struct_builder(); - uint64_builder_ptr->add_member(0, "my_uint64", uint64_builder.get()); - uint64_builder_ptr->set_name("ULongLongStruct"); - - ASSERT_TRUE(pbType->GetDynamicType()->equals(uint64_builder_ptr->build().get())); - - delete(pbType); - XMLProfileManager::DeleteInstance(); - } -} - -TEST_F(DynamicTypesTests, DynamicType_XML_FloatStruct_test) -{ - using namespace xmlparser; - using namespace types; - - XMLP_ret ret = XMLProfileManager::loadXMLFile(DynamicTypesTests::config_file()); - ASSERT_EQ(ret, XMLP_ret::XML_OK); - { - DynamicPubSubType* pbType = XMLProfileManager::CreateDynamicPubSubType("FloatStruct"); - - DynamicTypeBuilderFactory* m_factory = DynamicTypeBuilderFactory::get_instance(); - - // float32 - DynamicTypeBuilder_ptr float32_builder = m_factory->create_float32_builder(); - - // Struct FloatStruct - DynamicTypeBuilder_ptr float32_builder_ptr = m_factory->create_struct_builder(); - float32_builder_ptr->add_member(0, "my_float32", float32_builder.get()); - float32_builder_ptr->set_name("FloatStruct"); - - ASSERT_TRUE(pbType->GetDynamicType()->equals(float32_builder_ptr->build().get())); - - delete(pbType); - XMLProfileManager::DeleteInstance(); - } -} - -TEST_F(DynamicTypesTests, DynamicType_XML_DoubleStruct_test) -{ - using namespace xmlparser; - using namespace types; - - XMLP_ret ret = XMLProfileManager::loadXMLFile(DynamicTypesTests::config_file()); - ASSERT_EQ(ret, XMLP_ret::XML_OK); - { - DynamicPubSubType* pbType = XMLProfileManager::CreateDynamicPubSubType("DoubleStruct"); - - DynamicTypeBuilderFactory* m_factory = DynamicTypeBuilderFactory::get_instance(); - - // float64 - DynamicTypeBuilder_ptr float64_builder = m_factory->create_float64_builder(); - - // Struct DoubleStruct - DynamicTypeBuilder_ptr float64_builder_ptr = m_factory->create_struct_builder(); - float64_builder_ptr->add_member(0, "my_float64", float64_builder.get()); - float64_builder_ptr->set_name("DoubleStruct"); - - ASSERT_TRUE(pbType->GetDynamicType()->equals(float64_builder_ptr->build().get())); - - delete(pbType); - XMLProfileManager::DeleteInstance(); - } -} - -TEST_F(DynamicTypesTests, DynamicType_XML_LongDoubleStruct_test) -{ - using namespace xmlparser; - using namespace types; - - XMLP_ret ret = XMLProfileManager::loadXMLFile(DynamicTypesTests::config_file()); - ASSERT_EQ(ret, XMLP_ret::XML_OK); - { - DynamicPubSubType* pbType = XMLProfileManager::CreateDynamicPubSubType("LongDoubleStruct"); - - DynamicTypeBuilderFactory* m_factory = DynamicTypeBuilderFactory::get_instance(); - - // float128 - DynamicTypeBuilder_ptr float128_builder = m_factory->create_float128_builder(); - - // Struct LongDoubleStruct - DynamicTypeBuilder_ptr float128_builder_ptr = m_factory->create_struct_builder(); - float128_builder_ptr->add_member(0, "my_float128", float128_builder.get()); - float128_builder_ptr->set_name("LongDoubleStruct"); - - ASSERT_TRUE(pbType->GetDynamicType()->equals(float128_builder_ptr->build().get())); - - delete(pbType); - XMLProfileManager::DeleteInstance(); - } -} - -TEST_F(DynamicTypesTests, DynamicType_XML_CharStruct_test) -{ - using namespace xmlparser; - using namespace types; - - XMLP_ret ret = XMLProfileManager::loadXMLFile(DynamicTypesTests::config_file()); - ASSERT_EQ(ret, XMLP_ret::XML_OK); - { - DynamicPubSubType* pbType = XMLProfileManager::CreateDynamicPubSubType("CharStruct"); - - DynamicTypeBuilderFactory* m_factory = DynamicTypeBuilderFactory::get_instance(); - - // char - DynamicTypeBuilder_ptr char8_builder = m_factory->create_char8_builder(); - - // Struct CharStruct - DynamicTypeBuilder_ptr char_builder_ptr = m_factory->create_struct_builder(); - char_builder_ptr->add_member(0, "my_char", char8_builder.get()); - char_builder_ptr->set_name("CharStruct"); - - ASSERT_TRUE(pbType->GetDynamicType()->equals(char_builder_ptr->build().get())); - - delete(pbType); - XMLProfileManager::DeleteInstance(); - } -} - -TEST_F(DynamicTypesTests, DynamicType_XML_WCharStruct_test) -{ - using namespace xmlparser; - using namespace types; - - XMLP_ret ret = XMLProfileManager::loadXMLFile(DynamicTypesTests::config_file()); - ASSERT_EQ(ret, XMLP_ret::XML_OK); - { - DynamicPubSubType* pbType = XMLProfileManager::CreateDynamicPubSubType("WCharStruct"); - - DynamicTypeBuilderFactory* m_factory = DynamicTypeBuilderFactory::get_instance(); - - // wchar - DynamicTypeBuilder_ptr char16_builder = m_factory->create_char16_builder(); - - // Struct WCharStruct - DynamicTypeBuilder_ptr wchar_builder_ptr = m_factory->create_struct_builder(); - wchar_builder_ptr->add_member(0, "my_wchar", char16_builder.get()); - wchar_builder_ptr->set_name("WCharStruct"); - - ASSERT_TRUE(pbType->GetDynamicType()->equals(wchar_builder_ptr->build().get())); - - delete(pbType); - XMLProfileManager::DeleteInstance(); - } -} - -TEST_F(DynamicTypesTests, DynamicType_XML_StringStruct_test) -{ - using namespace xmlparser; - using namespace types; - - XMLP_ret ret = XMLProfileManager::loadXMLFile(DynamicTypesTests::config_file()); - ASSERT_EQ(ret, XMLP_ret::XML_OK); - { - DynamicPubSubType* pbType = XMLProfileManager::CreateDynamicPubSubType("StringStruct"); - - DynamicTypeBuilderFactory* m_factory = DynamicTypeBuilderFactory::get_instance(); - - // string - DynamicTypeBuilder_ptr string_builder = m_factory->create_string_builder(); - - // Struct StringStruct - DynamicTypeBuilder_ptr string_builder_ptr = m_factory->create_struct_builder(); - string_builder_ptr->add_member(0, "my_string", string_builder.get()); - string_builder_ptr->set_name("StringStruct"); - - ASSERT_TRUE(pbType->GetDynamicType()->equals(string_builder_ptr->build().get())); - - delete(pbType); - XMLProfileManager::DeleteInstance(); - } -} - -TEST_F(DynamicTypesTests, DynamicType_XML_WStringStruct_test) -{ - using namespace xmlparser; - using namespace types; - - XMLP_ret ret = XMLProfileManager::loadXMLFile(DynamicTypesTests::config_file()); - ASSERT_EQ(ret, XMLP_ret::XML_OK); - { - DynamicPubSubType* pbType = XMLProfileManager::CreateDynamicPubSubType("WStringStruct"); - - DynamicTypeBuilderFactory* m_factory = DynamicTypeBuilderFactory::get_instance(); - - // wstring - DynamicTypeBuilder_ptr wstring_builder = m_factory->create_wstring_builder(); - - // Struct WStringStruct - DynamicTypeBuilder_ptr wstring_builder_ptr = m_factory->create_struct_builder(); - wstring_builder_ptr->add_member(0, "my_wstring", wstring_builder.get()); - wstring_builder_ptr->set_name("WStringStruct"); - - ASSERT_TRUE(pbType->GetDynamicType()->equals(wstring_builder_ptr->build().get())); - - delete(pbType); - XMLProfileManager::DeleteInstance(); - } -} - -TEST_F(DynamicTypesTests, DynamicType_XML_LargeStringStruct_test) -{ - using namespace xmlparser; - using namespace types; - - XMLP_ret ret = XMLProfileManager::loadXMLFile(DynamicTypesTests::config_file()); - ASSERT_EQ(ret, XMLP_ret::XML_OK); - { - DynamicPubSubType* pbType = XMLProfileManager::CreateDynamicPubSubType("LargeStringStruct"); - - DynamicTypeBuilderFactory* m_factory = DynamicTypeBuilderFactory::get_instance(); - - // large string - DynamicTypeBuilder_ptr string_builder = m_factory->create_string_builder(41925); - - // Struct LargeStringStruct - DynamicTypeBuilder_ptr large_string_builder_ptr = m_factory->create_struct_builder(); - large_string_builder_ptr->add_member(0, "my_large_string", string_builder.get()); - large_string_builder_ptr->set_name("LargeStringStruct"); - - ASSERT_TRUE(pbType->GetDynamicType()->equals(large_string_builder_ptr->build().get())); - - delete(pbType); - XMLProfileManager::DeleteInstance(); - } -} - -TEST_F(DynamicTypesTests, DynamicType_XML_LargeWStringStruct_test) -{ - using namespace xmlparser; - using namespace types; - - XMLP_ret ret = XMLProfileManager::loadXMLFile(DynamicTypesTests::config_file()); - ASSERT_EQ(ret, XMLP_ret::XML_OK); - { - DynamicPubSubType* pbType = XMLProfileManager::CreateDynamicPubSubType("LargeWStringStruct"); - - DynamicTypeBuilderFactory* m_factory = DynamicTypeBuilderFactory::get_instance(); - - // large wstring - DynamicTypeBuilder_ptr wstring_builder = m_factory->create_wstring_builder(41925); - - // Struct LargeWStringStruct - DynamicTypeBuilder_ptr large_wstring_builder_ptr = m_factory->create_struct_builder(); - large_wstring_builder_ptr->add_member(0, "my_large_wstring", wstring_builder.get()); - large_wstring_builder_ptr->set_name("LargeWStringStruct"); - - ASSERT_TRUE(pbType->GetDynamicType()->equals(large_wstring_builder_ptr->build().get())); - - delete(pbType); - XMLProfileManager::DeleteInstance(); - } -} - -TEST_F(DynamicTypesTests, DynamicType_XML_ShortStringStruct_test) -{ - using namespace xmlparser; - using namespace types; - - XMLP_ret ret = XMLProfileManager::loadXMLFile(DynamicTypesTests::config_file()); - ASSERT_EQ(ret, XMLP_ret::XML_OK); - { - DynamicPubSubType* pbType = XMLProfileManager::CreateDynamicPubSubType("ShortStringStruct"); - - DynamicTypeBuilderFactory* m_factory = DynamicTypeBuilderFactory::get_instance(); - - // Short string - DynamicTypeBuilder_ptr string_builder = m_factory->create_string_builder(15); - - // Struct ShortStringStruct - DynamicTypeBuilder_ptr short_string_builder_ptr = m_factory->create_struct_builder(); - short_string_builder_ptr->add_member(0, "my_short_string", string_builder.get()); - short_string_builder_ptr->set_name("ShortStringStruct"); - - ASSERT_TRUE(pbType->GetDynamicType()->equals(short_string_builder_ptr->build().get())); - - delete(pbType); - XMLProfileManager::DeleteInstance(); - } -} - -TEST_F(DynamicTypesTests, DynamicType_XML_ShortWStringStruct_test) -{ - using namespace xmlparser; - using namespace types; - - XMLP_ret ret = XMLProfileManager::loadXMLFile(DynamicTypesTests::config_file()); - ASSERT_EQ(ret, XMLP_ret::XML_OK); - { - DynamicPubSubType* pbType = XMLProfileManager::CreateDynamicPubSubType("ShortWStringStruct"); - - DynamicTypeBuilderFactory* m_factory = DynamicTypeBuilderFactory::get_instance(); - - // Short wstring - DynamicTypeBuilder_ptr wstring_builder = m_factory->create_wstring_builder(15); - - // Struct ShortWStringStruct - DynamicTypeBuilder_ptr short_wstring_builder_ptr = m_factory->create_struct_builder(); - short_wstring_builder_ptr->add_member(0, "my_short_wstring", wstring_builder.get()); - short_wstring_builder_ptr->set_name("ShortWStringStruct"); - - ASSERT_TRUE(pbType->GetDynamicType()->equals(short_wstring_builder_ptr->build().get())); - - delete(pbType); - XMLProfileManager::DeleteInstance(); - } -} - -TEST_F(DynamicTypesTests, DynamicType_XML_AliasStringStruct_test) -{ - using namespace xmlparser; - using namespace types; - - XMLP_ret ret = XMLProfileManager::loadXMLFile(DynamicTypesTests::config_file()); - ASSERT_EQ(ret, XMLP_ret::XML_OK); - { - DynamicPubSubType* pbType = XMLProfileManager::CreateDynamicPubSubType("StructAliasString"); - - DynamicTypeBuilderFactory* m_factory = DynamicTypeBuilderFactory::get_instance(); - - // String - DynamicTypeBuilder_ptr string_builder = m_factory->create_string_builder(); - - // Alias - DynamicTypeBuilder_ptr myAlias_builder = m_factory->create_alias_builder(string_builder.get(), "MyAliasString"); - - // Struct StructAliasString - DynamicTypeBuilder_ptr alias_string_builder_ptr = m_factory->create_struct_builder(); - alias_string_builder_ptr->add_member(0, "my_alias_string", myAlias_builder.get()); - alias_string_builder_ptr->set_name("StructAliasString"); - - ASSERT_TRUE(pbType->GetDynamicType()->equals(alias_string_builder_ptr->build().get())); - - delete(pbType); - XMLProfileManager::DeleteInstance(); - } -} - -TEST_F(DynamicTypesTests, DynamicType_XML_StructAliasWString_test) -{ - using namespace xmlparser; - using namespace types; - - XMLP_ret ret = XMLProfileManager::loadXMLFile(DynamicTypesTests::config_file()); - ASSERT_EQ(ret, XMLP_ret::XML_OK); - { - DynamicPubSubType* pbType = XMLProfileManager::CreateDynamicPubSubType("StructAliasWString"); - - DynamicTypeBuilderFactory* m_factory = DynamicTypeBuilderFactory::get_instance(); - - // wstring - DynamicTypeBuilder_ptr wstring_builder = m_factory->create_wstring_builder(); - - // Alias - DynamicTypeBuilder_ptr myAlias_builder = - m_factory->create_alias_builder(wstring_builder.get(), "MyAliasWString"); - - // Struct StructAliasWString - DynamicTypeBuilder_ptr alias_wstring_builder_ptr = m_factory->create_struct_builder(); - alias_wstring_builder_ptr->add_member(0, "my_alias_wstring", myAlias_builder.get()); - alias_wstring_builder_ptr->set_name("StructAliasWString"); - - ASSERT_TRUE(pbType->GetDynamicType()->equals(alias_wstring_builder_ptr->build().get())); - - delete(pbType); - XMLProfileManager::DeleteInstance(); - } -} - -TEST_F(DynamicTypesTests, DynamicType_XML_ArraytStruct_test) -{ - using namespace xmlparser; - using namespace types; - - XMLP_ret ret = XMLProfileManager::loadXMLFile(DynamicTypesTests::config_file()); - ASSERT_EQ(ret, XMLP_ret::XML_OK); - { - DynamicPubSubType* pbType = XMLProfileManager::CreateDynamicPubSubType("ArraytStruct"); - - DynamicTypeBuilderFactory* m_factory = DynamicTypeBuilderFactory::get_instance(); - - // Int32 - DynamicTypeBuilder_ptr int32_builder = m_factory->create_int32_builder(); - - // Array - DynamicTypeBuilder_ptr array_builder = m_factory->create_array_builder(int32_builder.get(), { 2, 2, 2 }); - - // Struct ShortWStringStruct - DynamicTypeBuilder_ptr array_int32_builder_ptr = m_factory->create_struct_builder(); - array_int32_builder_ptr->add_member(0, "my_array", array_builder.get()); - array_int32_builder_ptr->set_name("ArraytStruct"); - - ASSERT_TRUE(pbType->GetDynamicType()->equals(array_int32_builder_ptr->build().get())); - - delete(pbType); - XMLProfileManager::DeleteInstance(); - } -} - -TEST_F(DynamicTypesTests, DynamicType_XML_ArrayArrayStruct_test) -{ - using namespace xmlparser; - using namespace types; - - XMLP_ret ret = XMLProfileManager::loadXMLFile(DynamicTypesTests::config_file()); - ASSERT_EQ(ret, XMLP_ret::XML_OK); - { - DynamicPubSubType* pbType = XMLProfileManager::CreateDynamicPubSubType("ArrayArrayStruct"); - - DynamicTypeBuilderFactory* m_factory = DynamicTypeBuilderFactory::get_instance(); - - // Typedef aka Alias - DynamicTypeBuilder_ptr int32_builder = m_factory->create_int32_builder(); - DynamicTypeBuilder_ptr array_builder = m_factory->create_array_builder(int32_builder.get(), { 2, 2 }); - DynamicTypeBuilder_ptr myArray_builder = m_factory->create_alias_builder(array_builder.get(), "MyArray"); - - // Struct ArrayArrayStruct - DynamicTypeBuilder_ptr aas_builder = m_factory->create_struct_builder(); - DynamicTypeBuilder_ptr aMyArray_builder = m_factory->create_array_builder(myArray_builder.get(), { 2, 2 }); - aas_builder->add_member(0, "my_array_array", aMyArray_builder.get()); - aas_builder->set_name("ArrayArrayStruct"); - - ASSERT_TRUE(pbType->GetDynamicType()->equals(aas_builder->build().get())); - - delete(pbType); - XMLProfileManager::DeleteInstance(); - } -} - -TEST_F(DynamicTypesTests, DynamicType_XML_ArrayArrayArrayStruct_test) -{ - using namespace xmlparser; - using namespace types; - - XMLP_ret ret = XMLProfileManager::loadXMLFile(DynamicTypesTests::config_file()); - ASSERT_EQ(ret, XMLP_ret::XML_OK); - { - DynamicPubSubType* pbType = XMLProfileManager::CreateDynamicPubSubType("ArrayArrayArrayStruct"); - - DynamicTypeBuilderFactory* m_factory = DynamicTypeBuilderFactory::get_instance(); - // Manual comparision test - /* - typedef long MyArray[2][2]; - - struct ArrayArrayStruct - { - MyArray my_array_array[2][2]; - }; - - struct ArrayArrayArrayStruct - { - ArrayArrayStruct my_array_array_array[2][2]; - }; - - ====== - - - - - - - - - - - - - - - */ - // Typedef aka Alias - DynamicTypeBuilder_ptr int32_builder = m_factory->create_int32_builder(); - DynamicTypeBuilder_ptr array_builder = m_factory->create_array_builder(int32_builder.get(), { 2, 2 }); - DynamicTypeBuilder_ptr myArray_builder = m_factory->create_alias_builder(array_builder.get(), "MyArray"); - - // Struct ArrayArrayStruct - DynamicTypeBuilder_ptr aas_builder = m_factory->create_struct_builder(); - DynamicTypeBuilder_ptr aMyArray_builder = m_factory->create_array_builder(myArray_builder.get(), { 2, 2 }); - aas_builder->add_member(0, "my_array_array", aMyArray_builder.get()); - aas_builder->set_name("ArrayArrayStruct"); - - // Struct ArrayArrayArrayStruct - DynamicTypeBuilder_ptr aaas_builder = m_factory->create_struct_builder(); - DynamicTypeBuilder_ptr aas_array_builder = m_factory->create_array_builder(aas_builder.get(), { 2, 2 }); - aaas_builder->add_member(0, "my_array_array_array", aas_array_builder.get()); - aaas_builder->set_name("ArrayArrayArrayStruct"); - - ASSERT_TRUE(pbType->GetDynamicType()->equals(aaas_builder->build().get())); - - delete(pbType); - XMLProfileManager::DeleteInstance(); - } -} - -TEST_F(DynamicTypesTests, DynamicType_XML_SequenceStruct_test) -{ - using namespace xmlparser; - using namespace types; - - XMLP_ret ret = XMLProfileManager::loadXMLFile(DynamicTypesTests::config_file()); - ASSERT_EQ(ret, XMLP_ret::XML_OK); - { - DynamicPubSubType* pbType = XMLProfileManager::CreateDynamicPubSubType("SequenceStruct"); - - DynamicTypeBuilderFactory* m_factory = DynamicTypeBuilderFactory::get_instance(); - - DynamicTypeBuilder_ptr int32_builder = m_factory->create_int32_builder(); - DynamicTypeBuilder_ptr seq_builder = m_factory->create_sequence_builder(int32_builder.get(), 2); - - DynamicTypeBuilder_ptr seqs_builder = m_factory->create_struct_builder(); - seqs_builder->add_member(0, "my_sequence", seq_builder.get()); - seqs_builder->set_name("SequenceStruct"); - - ASSERT_TRUE(pbType->GetDynamicType()->equals(seqs_builder->build().get())); - - delete(pbType); - XMLProfileManager::DeleteInstance(); - } -} - -TEST_F(DynamicTypesTests, DynamicType_XML_SequenceSequenceStruct_test) -{ - using namespace xmlparser; - using namespace types; - - XMLP_ret ret = XMLProfileManager::loadXMLFile(DynamicTypesTests::config_file()); - ASSERT_EQ(ret, XMLP_ret::XML_OK); - { - DynamicPubSubType* pbType = XMLProfileManager::CreateDynamicPubSubType("SequenceSequenceStruct"); - - DynamicTypeBuilderFactory* m_factory = DynamicTypeBuilderFactory::get_instance(); - - DynamicTypeBuilder_ptr int32_builder = m_factory->create_int32_builder(); - DynamicTypeBuilder_ptr seq_builder = m_factory->create_sequence_builder(int32_builder.get(), 2); - DynamicTypeBuilder_ptr alias_builder = m_factory->create_alias_builder( - seq_builder.get(), "my_sequence_sequence_inner"); - - DynamicTypeBuilder_ptr sss_builder = m_factory->create_struct_builder(); - DynamicTypeBuilder_ptr seq_seq_builder = m_factory->create_sequence_builder(alias_builder.get(), 2); - sss_builder->add_member(0, "my_sequence_sequence", seq_seq_builder.get()); - sss_builder->set_name("SequenceSequenceStruct"); - - ASSERT_TRUE(pbType->GetDynamicType()->equals(sss_builder->build().get())); - - delete(pbType); - XMLProfileManager::DeleteInstance(); - } -} - -TEST_F(DynamicTypesTests, DynamicType_XML_MapStruct_test) -{ - using namespace xmlparser; - using namespace types; - - XMLP_ret ret = XMLProfileManager::loadXMLFile(DynamicTypesTests::config_file()); - ASSERT_EQ(ret, XMLP_ret::XML_OK); - { - DynamicPubSubType* pbType = XMLProfileManager::CreateDynamicPubSubType("MapStruct"); - - DynamicTypeBuilderFactory* m_factory = DynamicTypeBuilderFactory::get_instance(); - - DynamicTypeBuilder_ptr int32_builder = m_factory->create_int32_builder(); - DynamicTypeBuilder_ptr map_builder = m_factory->create_map_builder(int32_builder.get(), int32_builder.get(), 7); - - DynamicTypeBuilder_ptr maps_builder = m_factory->create_struct_builder(); - maps_builder->add_member(0, "my_map", map_builder.get()); - maps_builder->set_name("MapStruct"); - - ASSERT_TRUE(pbType->GetDynamicType()->equals(maps_builder->build().get())); - - delete(pbType); - XMLProfileManager::DeleteInstance(); - } -} - -TEST_F(DynamicTypesTests, DynamicType_XML_MapMapStruct_test) -{ - using namespace xmlparser; - using namespace types; - - XMLP_ret ret = XMLProfileManager::loadXMLFile(DynamicTypesTests::config_file()); - ASSERT_EQ(ret, XMLP_ret::XML_OK); - { - DynamicPubSubType* pbType = XMLProfileManager::CreateDynamicPubSubType("MapMapStruct"); - - DynamicTypeBuilderFactory* m_factory = DynamicTypeBuilderFactory::get_instance(); - - DynamicTypeBuilder_ptr int32_builder = m_factory->create_int32_builder(); - DynamicTypeBuilder_ptr map_builder = m_factory->create_map_builder(int32_builder.get(), int32_builder.get(), 7); - DynamicTypeBuilder_ptr alias_builder = m_factory->create_alias_builder(map_builder.get(), "my_map_map_inner"); - DynamicTypeBuilder_ptr map_map_builder = m_factory->create_map_builder(alias_builder.get(), - int32_builder.get(), 2); - - - DynamicTypeBuilder_ptr maps_builder = m_factory->create_struct_builder(); - maps_builder->add_member(0, "my_map_map", map_map_builder.get()); - maps_builder->set_name("MapMapStruct"); - - ASSERT_TRUE(pbType->GetDynamicType()->equals(maps_builder->build().get())); - - delete(pbType); - XMLProfileManager::DeleteInstance(); - } -} - -TEST_F(DynamicTypesTests, DynamicType_XML_StructStruct_test) -{ - using namespace xmlparser; - using namespace types; - - XMLP_ret ret = XMLProfileManager::loadXMLFile(DynamicTypesTests::config_file()); - ASSERT_EQ(ret, XMLP_ret::XML_OK); - { - DynamicPubSubType* pbType = XMLProfileManager::CreateDynamicPubSubType("StructStruct"); - - DynamicTypeBuilderFactory* m_factory = DynamicTypeBuilderFactory::get_instance(); - - DynamicTypeBuilder_ptr int32_builder = m_factory->create_int32_builder(); - DynamicTypeBuilder_ptr int64_builder = m_factory->create_int64_builder(); - - DynamicTypeBuilder_ptr structs_builder = m_factory->create_struct_builder(); - structs_builder->add_member(0, "a", int32_builder.get()); - structs_builder->add_member(1, "b", int64_builder.get()); - structs_builder->set_name("StructStruct"); - - ASSERT_TRUE(pbType->GetDynamicType()->equals(structs_builder->build().get())); - - delete(pbType); - XMLProfileManager::DeleteInstance(); - } -} - -TEST_F(DynamicTypesTests, DynamicType_XML_StructStructStruct_test) -{ - using namespace xmlparser; - using namespace types; - - XMLP_ret ret = XMLProfileManager::loadXMLFile(DynamicTypesTests::config_file()); - ASSERT_EQ(ret, XMLP_ret::XML_OK); - { - DynamicPubSubType* pbType = XMLProfileManager::CreateDynamicPubSubType("StructStructStruct"); - - DynamicTypeBuilderFactory* m_factory = DynamicTypeBuilderFactory::get_instance(); - - DynamicTypeBuilder_ptr int32_builder = m_factory->create_int32_builder(); - DynamicTypeBuilder_ptr int64_builder = m_factory->create_int64_builder(); - - DynamicTypeBuilder_ptr structs_builder = m_factory->create_struct_builder(); - structs_builder->add_member(0, "a", int32_builder.get()); - structs_builder->add_member(1, "b", int64_builder.get()); - structs_builder->set_name("StructStruct"); - - DynamicTypeBuilder_ptr sss_builder = m_factory->create_struct_builder(); - sss_builder->add_member(0, "child_struct", structs_builder.get()); - sss_builder->add_member(1, "child_int64", int64_builder.get()); - sss_builder->set_name("StructStructStruct"); - - ASSERT_TRUE(pbType->GetDynamicType()->equals(sss_builder->build().get())); - - delete(pbType); - XMLProfileManager::DeleteInstance(); - } -} - -TEST_F(DynamicTypesTests, DynamicType_XML_SimpleUnionStruct_test) -{ - using namespace xmlparser; - using namespace types; - - XMLP_ret ret = XMLProfileManager::loadXMLFile(DynamicTypesTests::config_file()); - ASSERT_EQ(ret, XMLP_ret::XML_OK); - { - DynamicPubSubType* pbType = XMLProfileManager::CreateDynamicPubSubType("SimpleUnionStruct"); - - DynamicTypeBuilderFactory* m_factory = DynamicTypeBuilderFactory::get_instance(); - - DynamicTypeBuilder_ptr int32_builder = m_factory->create_int32_builder(); - DynamicTypeBuilder_ptr int64_builder = m_factory->create_int64_builder(); - - DynamicTypeBuilder_ptr union_builder = m_factory->create_union_builder(int32_builder.get()); - union_builder->add_member(0, "first", int32_builder.get(), "", { 0 }, true); - union_builder->add_member(1, "second", int64_builder.get(), "", { 1 }, false); - union_builder->set_name("SimpleUnion"); - - - DynamicTypeBuilder_ptr us_builder = m_factory->create_struct_builder(); - us_builder->add_member(0, "my_union", union_builder.get()); - us_builder->set_name("SimpleUnionStruct"); - - ASSERT_TRUE(pbType->GetDynamicType()->equals(us_builder->build().get())); - - delete(pbType); - XMLProfileManager::DeleteInstance(); - } -} - -TEST_F(DynamicTypesTests, DynamicType_XML_UnionUnionStruct_test) -{ - using namespace xmlparser; - using namespace types; - - XMLP_ret ret = XMLProfileManager::loadXMLFile(DynamicTypesTests::config_file()); - ASSERT_EQ(ret, XMLP_ret::XML_OK); - { - DynamicPubSubType* pbType = XMLProfileManager::CreateDynamicPubSubType("UnionUnionStruct"); - - DynamicTypeBuilderFactory* m_factory = DynamicTypeBuilderFactory::get_instance(); - - DynamicTypeBuilder_ptr int32_builder = m_factory->create_int32_builder(); - DynamicTypeBuilder_ptr int64_builder = m_factory->create_int64_builder(); - - DynamicTypeBuilder_ptr union_builder = m_factory->create_union_builder(int32_builder.get()); - union_builder->add_member(0, "first", int32_builder.get(), "", { 0 }, true); - union_builder->add_member(1, "second", int64_builder.get(), "", { 1 }, false); - union_builder->set_name("SimpleUnion"); - - DynamicTypeBuilder_ptr union_union_builder = m_factory->create_union_builder(int32_builder.get()); - union_union_builder->add_member(0, "first", int32_builder.get(), "", { 0 }, true); - union_union_builder->add_member(1, "second", union_builder.get(), "", { 1 }, false); - union_union_builder->set_name("UnionUnion"); - - - DynamicTypeBuilder_ptr uus_builder = m_factory->create_struct_builder(); - uus_builder->add_member(0, "my_union", union_union_builder.get()); - uus_builder->set_name("UnionUnionStruct"); - - ASSERT_TRUE(pbType->GetDynamicType()->equals(uus_builder->build().get())); - - delete(pbType); - XMLProfileManager::DeleteInstance(); - } -} - -TEST_F(DynamicTypesTests, DynamicType_XML_WCharUnionStruct_test) -{ - using namespace xmlparser; - using namespace types; - - XMLP_ret ret = XMLProfileManager::loadXMLFile(DynamicTypesTests::config_file()); - ASSERT_EQ(ret, XMLP_ret::XML_OK); - { - DynamicPubSubType* pbType = XMLProfileManager::CreateDynamicPubSubType("WCharUnionStruct"); - - DynamicTypeBuilderFactory* m_factory = DynamicTypeBuilderFactory::get_instance(); - - DynamicTypeBuilder_ptr wchar_builder = m_factory->create_char16_builder(); - DynamicTypeBuilder_ptr int32_builder = m_factory->create_int32_builder(); - DynamicTypeBuilder_ptr int64_builder = m_factory->create_int64_builder(); - - DynamicTypeBuilder_ptr union_builder = m_factory->create_union_builder(wchar_builder.get()); - union_builder->add_member(0, "first", int32_builder.get(), "", { 0 }, true); - union_builder->add_member(1, "second", int64_builder.get(), "", { 1 }, false); - union_builder->set_name("WCharUnion"); - - - DynamicTypeBuilder_ptr us_builder = m_factory->create_struct_builder(); - us_builder->add_member(0, "my_union", union_builder.get()); - us_builder->set_name("WCharUnionStruct"); - - ASSERT_TRUE(pbType->GetDynamicType()->equals(us_builder->build().get())); - - delete(pbType); - XMLProfileManager::DeleteInstance(); - } -} - -TEST_F(DynamicTypesTests, DynamicType_bounded_string_unit_tests) -{ - using namespace xmlparser; - using namespace types; - - XMLP_ret ret = XMLProfileManager::loadXMLFile(DynamicTypesTests::config_file()); - ASSERT_EQ(ret, XMLP_ret::XML_OK); - { - DynamicPubSubType* pbType = XMLProfileManager::CreateDynamicPubSubType("ShortStringStruct"); - DynamicData* data = DynamicDataFactory::get_instance()->create_data(pbType->GetDynamicType()); - - // SERIALIZATION TEST - StringStruct refData; - StringStructPubSubType refDatapb; - - uint32_t payloadSize = static_cast(pbType->getSerializedSizeProvider(data)()); - SerializedPayload_t payload(payloadSize); - SerializedPayload_t dynamic_payload(payloadSize); - ASSERT_TRUE(pbType->serialize(data, &dynamic_payload)); - ASSERT_TRUE(refDatapb.deserialize(&dynamic_payload, &refData)); - - uint32_t static_payloadSize = static_cast(refDatapb.getSerializedSizeProvider(&refData)()); - SerializedPayload_t static_payload(static_payloadSize); - ASSERT_TRUE(refDatapb.serialize(&refData, &static_payload)); - ASSERT_TRUE(static_payload.length == static_payloadSize); - ASSERT_FALSE(data->set_string_value("TEST_OVER_LENGTH_LIMITS", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data) == ReturnCode_t::RETCODE_OK); - - delete(pbType); - XMLProfileManager::DeleteInstance(); - } -} - -TEST_F(DynamicTypesTests, DynamicType_bounded_wstring_unit_tests) -{ - using namespace xmlparser; - using namespace types; - - XMLP_ret ret = XMLProfileManager::loadXMLFile(DynamicTypesTests::config_file()); - ASSERT_EQ(ret, XMLP_ret::XML_OK); - { - DynamicPubSubType* pbType = XMLProfileManager::CreateDynamicPubSubType("ShortWStringStruct"); - DynamicData* data = DynamicDataFactory::get_instance()->create_data(pbType->GetDynamicType()); - - // SERIALIZATION TEST - StringStruct refData; - StringStructPubSubType refDatapb; - - uint32_t payloadSize = static_cast(pbType->getSerializedSizeProvider(data)()); - SerializedPayload_t payload(payloadSize); - SerializedPayload_t dynamic_payload(payloadSize); - ASSERT_TRUE(pbType->serialize(data, &dynamic_payload)); - ASSERT_TRUE(refDatapb.deserialize(&dynamic_payload, &refData)); - - uint32_t static_payloadSize = static_cast(refDatapb.getSerializedSizeProvider(&refData)()); - SerializedPayload_t static_payload(static_payloadSize); - ASSERT_TRUE(refDatapb.serialize(&refData, &static_payload)); - ASSERT_TRUE(static_payload.length == static_payloadSize); - ASSERT_FALSE(data->set_string_value("TEST_OVER_LENGTH_LIMITS", MEMBER_ID_INVALID) == ReturnCode_t::RETCODE_OK); - ASSERT_TRUE(DynamicDataFactory::get_instance()->delete_data(data) == ReturnCode_t::RETCODE_OK); - - delete(pbType); - XMLProfileManager::DeleteInstance(); - } -} - -TEST_F(DynamicTypesTests, DynamicType_XML_Bitset_test) -{ - using namespace xmlparser; - using namespace types; - - XMLP_ret ret = XMLProfileManager::loadXMLFile(DynamicTypesTests::config_file()); - ASSERT_EQ(ret, XMLP_ret::XML_OK); - { - DynamicPubSubType* pbType = XMLProfileManager::CreateDynamicPubSubType("MyBitSet"); - - DynamicTypeBuilderFactory* m_factory = DynamicTypeBuilderFactory::get_instance(); - - DynamicTypeBuilder_ptr a_builder = m_factory->create_byte_builder(); - DynamicTypeBuilder_ptr b_builder = m_factory->create_bool_builder(); - DynamicTypeBuilder_ptr empty_builder = m_factory->create_byte_builder(); - DynamicTypeBuilder_ptr c_builder = m_factory->create_uint16_builder(); - DynamicTypeBuilder_ptr d_builder = m_factory->create_int16_builder(); - auto a_type = a_builder->build(); - auto b_type = b_builder->build(); - auto e_type = empty_builder->build(); - auto c_type = c_builder->build(); - auto d_type = d_builder->build(); - - // Bitset - DynamicTypeBuilder_ptr builder_ptr = m_factory->create_bitset_builder(); - builder_ptr->add_member(0, "a", a_type); - builder_ptr->add_member(1, "b", b_type); - builder_ptr->add_member(2, "", e_type); - builder_ptr->add_member(3, "c", c_type); - builder_ptr->add_member(4, "d", d_type); - builder_ptr->add_member(5, "", e_type); // Test more than one empty member. Trailing shouldn't affect equallity. - builder_ptr->apply_annotation_to_member(0, ANNOTATION_BIT_BOUND_ID, "value", "3"); - builder_ptr->apply_annotation_to_member(0, ANNOTATION_POSITION_ID, "value", "0"); - builder_ptr->apply_annotation_to_member(1, ANNOTATION_BIT_BOUND_ID, "value", "1"); - builder_ptr->apply_annotation_to_member(1, ANNOTATION_POSITION_ID, "value", "3"); - // The member doesn't exist so the annotation application will fail, and isn't needed. - //builder_ptr->apply_annotation_to_member(2, ANNOTATION_BIT_BOUND_ID, "value", "4"); - //builder_ptr->apply_annotation_to_member(2, ANNOTATION_POSITION_ID, "value", "4"); - builder_ptr->apply_annotation_to_member(3, ANNOTATION_BIT_BOUND_ID, "value", "10"); - builder_ptr->apply_annotation_to_member(3, ANNOTATION_POSITION_ID, "value", "8"); // 4 empty - builder_ptr->apply_annotation_to_member(4, ANNOTATION_BIT_BOUND_ID, "value", "12"); - builder_ptr->apply_annotation_to_member(4, ANNOTATION_POSITION_ID, "value", "18"); - builder_ptr->set_name("MyBitSet"); - - ASSERT_TRUE(pbType->GetDynamicType()->equals(builder_ptr->build().get())); - - delete(pbType); - XMLProfileManager::DeleteInstance(); - } -} - -TEST_F(DynamicTypesTests, DynamicType_XML_Bitmask_test) -{ - using namespace xmlparser; - using namespace types; - - XMLP_ret ret = XMLProfileManager::loadXMLFile(DynamicTypesTests::config_file()); - ASSERT_EQ(ret, XMLP_ret::XML_OK); - { - DynamicPubSubType* pbType = XMLProfileManager::CreateDynamicPubSubType("MyBitMask"); - - DynamicTypeBuilderFactory* m_factory = DynamicTypeBuilderFactory::get_instance(); - - // Bitset - DynamicTypeBuilder_ptr builder_ptr = m_factory->create_bitmask_builder(8); - builder_ptr->add_empty_member(0, "flag0"); - builder_ptr->add_empty_member(1, "flag1"); - builder_ptr->add_empty_member(2, "flag2"); - builder_ptr->add_empty_member(5, "flag5"); - builder_ptr->set_name("MyBitMask"); - - ASSERT_TRUE(pbType->GetDynamicType()->equals(builder_ptr->build().get())); - - delete(pbType); - XMLProfileManager::DeleteInstance(); - } -} - -TEST_F(DynamicTypesTests, DynamicType_XML_key_annotation) -{ - using namespace xmlparser; - using namespace types; - - XMLP_ret ret = XMLProfileManager::loadXMLFile(DynamicTypesTests::config_file()); - ASSERT_EQ(ret, XMLP_ret::XML_OK); - - { - DynamicPubSubType* pbType = XMLProfileManager::CreateDynamicPubSubType("BoolStruct"); - ASSERT_FALSE(pbType->m_isGetKeyDefined); - XMLProfileManager::DeleteDynamicPubSubType(pbType); - } - - { - DynamicPubSubType* pbType = XMLProfileManager::CreateDynamicPubSubType("my_keyed_struct"); - ASSERT_TRUE(pbType->m_isGetKeyDefined); - XMLProfileManager::DeleteDynamicPubSubType(pbType); - } - - XMLProfileManager::DeleteInstance(); -} - -TEST(TypeIdentifierTests, MinimalTypeIdentifierComparision) -{ - TypeIdentifier enum1 = *GetMyEnumIdentifier(false); - TypeIdentifier aliasEnum1 = *GetMyAliasEnumIdentifier(false); - TypeIdentifier aliasAliasEnum1 = *GetMyAliasAliasEnumIdentifier(false); - TypeIdentifier boolStruct1 = *GetBoolStructIdentifier(false); - TypeIdentifier octetStruct1 = *GetOctetStructIdentifier(false); - TypeIdentifier shortStruct1 = *GetShortStructIdentifier(false); - TypeIdentifier longStruct1 = *GetLongStructIdentifier(false); - TypeIdentifier longLongStruct1 = *GetLongLongStructIdentifier(false); - TypeIdentifier uShortStruct1 = *GetShortStructIdentifier(false); - TypeIdentifier uLongStruct1 = *GetULongStructIdentifier(false); - TypeIdentifier uLongLongStruct1 = *GetULongLongStructIdentifier(false); - TypeIdentifier floatStruct1 = *GetFloatStructIdentifier(false); - TypeIdentifier doubleStruct1 = *GetDoubleStructIdentifier(false); - TypeIdentifier longDoubleStruct1 = *GetLongDoubleStructIdentifier(false); - TypeIdentifier charStruct1 = *GetCharStructIdentifier(false); - TypeIdentifier wcharStruct1 = *GetWCharStructIdentifier(false); - TypeIdentifier stringStruct1 = *GetStringStructIdentifier(false); - TypeIdentifier wstringStruct1 = *GetWStringStructIdentifier(false); - TypeIdentifier largeStringStruct1 = *GetLargeStringStructIdentifier(false); - TypeIdentifier largeWStringStruct1 = *GetLargeWStringStructIdentifier(false); - TypeIdentifier arrayStruct1 = *GetArraytStructIdentifier(false); - GetMyArrayIdentifier(false); // We need to generate it before arrayArrayStruct - TypeIdentifier arrayArrayStruct1 = *GetArrayArrayStructIdentifier(false); - TypeIdentifier sequenceStruct1 = *GetSequenceStructIdentifier(false); - TypeIdentifier sequenceSequenceStruct1 = *GetSequenceSequenceStructIdentifier(false); - TypeIdentifier mapStruct1 = *GetMapStructIdentifier(false); - TypeIdentifier mapMapStruct1 = *GetMapMapStructIdentifier(false); - TypeIdentifier structStruct1 = *GetStructStructIdentifier(false); - TypeIdentifier structStructStruct1 = *GetStructStructStructIdentifier(false); - TypeIdentifier simpleUnion1 = *GetSimpleUnionIdentifier(false); - TypeIdentifier unionUnion1 = *GetUnionUnionIdentifier(false); - TypeIdentifier wCharUnion1 = *GetWCharUnionIdentifier(false); - TypeIdentifier unionUnionStruct1 = *GetUnionUnionUnionStructIdentifier(false); - TypeObjectFactory::get_instance()->delete_instance(); // Force new instances instead reusing them - registerBasicTypes(); // Register them again - TypeIdentifier enum2 = *GetMyEnumIdentifier(false); - TypeIdentifier aliasEnum2 = *GetMyAliasEnumIdentifier(false); - TypeIdentifier aliasAliasEnum2 = *GetMyAliasAliasEnumIdentifier(false); - TypeIdentifier boolStruct2 = *GetBoolStructIdentifier(false); - TypeIdentifier octetStruct2 = *GetOctetStructIdentifier(false); - TypeIdentifier shortStruct2 = *GetShortStructIdentifier(false); - TypeIdentifier longStruct2 = *GetLongStructIdentifier(false); - TypeIdentifier longLongStruct2 = *GetLongLongStructIdentifier(false); - TypeIdentifier uShortStruct2 = *GetShortStructIdentifier(false); - TypeIdentifier uLongStruct2 = *GetULongStructIdentifier(false); - TypeIdentifier uLongLongStruct2 = *GetULongLongStructIdentifier(false); - TypeIdentifier floatStruct2 = *GetFloatStructIdentifier(false); - TypeIdentifier doubleStruct2 = *GetDoubleStructIdentifier(false); - TypeIdentifier longDoubleStruct2 = *GetLongDoubleStructIdentifier(false); - TypeIdentifier charStruct2 = *GetCharStructIdentifier(false); - TypeIdentifier wcharStruct2 = *GetWCharStructIdentifier(false); - TypeIdentifier stringStruct2 = *GetStringStructIdentifier(false); - TypeIdentifier wstringStruct2 = *GetWStringStructIdentifier(false); - TypeIdentifier largeStringStruct2 = *GetLargeStringStructIdentifier(false); - TypeIdentifier largeWStringStruct2 = *GetLargeWStringStructIdentifier(false); - TypeIdentifier arrayStruct2 = *GetArraytStructIdentifier(false); - TypeIdentifier arrayArrayStruct2 = *GetArrayArrayStructIdentifier(false); - TypeIdentifier sequenceStruct2 = *GetSequenceStructIdentifier(false); - TypeIdentifier sequenceSequenceStruct2 = *GetSequenceSequenceStructIdentifier(false); - TypeIdentifier mapStruct2 = *GetMapStructIdentifier(false); - TypeIdentifier mapMapStruct2 = *GetMapMapStructIdentifier(false); - TypeIdentifier structStruct2 = *GetStructStructIdentifier(false); - TypeIdentifier structStructStruct2 = *GetStructStructStructIdentifier(false); - TypeIdentifier simpleUnion2 = *GetSimpleUnionIdentifier(false); - TypeIdentifier unionUnion2 = *GetUnionUnionIdentifier(false); - TypeIdentifier wCharUnion2 = *GetWCharUnionIdentifier(false); - TypeIdentifier unionUnionStruct2 = *GetUnionUnionUnionStructIdentifier(false); - - // Compare equals - ASSERT_TRUE(enum1 == enum2); - ASSERT_TRUE(aliasEnum1 == aliasEnum2 || aliasEnum2 == enum1); - ASSERT_TRUE(aliasAliasEnum1 == aliasAliasEnum2 || aliasAliasEnum2 == enum1); - ASSERT_TRUE(boolStruct1 == boolStruct2); - ASSERT_TRUE(octetStruct1 == octetStruct2); - ASSERT_TRUE(shortStruct1 == shortStruct2); - ASSERT_TRUE(longStruct1 == longStruct2); - ASSERT_TRUE(longLongStruct1 == longLongStruct2); - ASSERT_TRUE(uShortStruct1 == uShortStruct2); - ASSERT_TRUE(uLongStruct1 == uLongStruct2); - ASSERT_TRUE(uLongLongStruct1 == uLongLongStruct2); - ASSERT_TRUE(floatStruct1 == floatStruct2); - ASSERT_TRUE(doubleStruct1 == doubleStruct2); - ASSERT_TRUE(longDoubleStruct1 == longDoubleStruct2); - ASSERT_TRUE(charStruct1 == charStruct2); - ASSERT_TRUE(wcharStruct1 == wcharStruct2); - ASSERT_TRUE(stringStruct1 == stringStruct2); - ASSERT_TRUE(wstringStruct1 == wstringStruct2); - ASSERT_TRUE(largeStringStruct1 == largeStringStruct2); - ASSERT_TRUE(largeWStringStruct1 == largeWStringStruct2); - ASSERT_TRUE(arrayStruct1 == arrayStruct2); - ASSERT_TRUE(arrayArrayStruct1 == arrayArrayStruct2); - ASSERT_TRUE(sequenceStruct1 == sequenceStruct2); - ASSERT_TRUE(sequenceSequenceStruct1 == sequenceSequenceStruct2); - ASSERT_TRUE(mapStruct1 == mapStruct2); - ASSERT_TRUE(mapMapStruct1 == mapMapStruct2); - ASSERT_TRUE(structStruct1 == structStruct2); - ASSERT_TRUE(structStructStruct1 == structStructStruct2); - ASSERT_TRUE(simpleUnion1 == simpleUnion2); - ASSERT_TRUE(unionUnion1 == unionUnion2); - ASSERT_TRUE(wCharUnion1 == wCharUnion2); - ASSERT_TRUE(unionUnionStruct1 == unionUnionStruct2); - ASSERT_TRUE(enum2 == aliasEnum2); - - // Compare some not equals - ASSERT_FALSE(aliasAliasEnum1 == boolStruct1); - ASSERT_FALSE(octetStruct1 == shortStruct1); - ASSERT_FALSE(longStruct1 == longLongStruct1); - ASSERT_FALSE(uShortStruct1 == uLongStruct1); - ASSERT_FALSE(uLongStruct1 == uLongLongStruct2); - ASSERT_FALSE(floatStruct1 == doubleStruct1); - ASSERT_FALSE(doubleStruct1 == longDoubleStruct2); - ASSERT_FALSE(charStruct1 == wcharStruct1); - ASSERT_FALSE(stringStruct1 == wstringStruct1); - ASSERT_FALSE(stringStruct1 == largeStringStruct2); - ASSERT_FALSE(wstringStruct1 == largeWStringStruct2); - ASSERT_FALSE(arrayStruct1 == arrayArrayStruct1); - ASSERT_FALSE(sequenceStruct1 == sequenceSequenceStruct1); - ASSERT_FALSE(mapStruct1 == mapMapStruct1); - ASSERT_FALSE(structStruct1 == structStructStruct1); - ASSERT_FALSE(simpleUnion1 == unionUnion1); - ASSERT_FALSE(unionUnion1 == wCharUnion2); - ASSERT_FALSE(unionUnionStruct1 == unionUnion1); -} - -int main( - int argc, - char** argv) -{ - eprosima::fastdds::dds::Log::SetVerbosity(eprosima::fastdds::dds::Log::Info); - - testing::InitGoogleTest(&argc, argv); - return RUN_ALL_TESTS(); -} diff --git a/test/unittest/dynamic_types/DynamicTypes_4_2_Tests.cpp b/test/unittest/dynamic_types/DynamicTypes_4_2_Tests.cpp deleted file mode 100644 index 217d6531f11..00000000000 --- a/test/unittest/dynamic_types/DynamicTypes_4_2_Tests.cpp +++ /dev/null @@ -1,462 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include "idl/new_features_4_2PubSubTypes.h" -#include "idl/new_features_4_2TypeObject.h" - -using namespace eprosima::fastrtps; -using namespace eprosima::fastrtps::rtps; -using namespace eprosima::fastrtps::types; -using namespace eprosima::fastcdr::exception; - -class DynamicTypes_4_2_Tests : public ::testing::Test -{ - const std::string config_file_ = "types_profile.xml"; - -public: - - DynamicTypes_4_2_Tests() - { - } - - ~DynamicTypes_4_2_Tests() - { - eprosima::fastdds::dds::Log::KillThread(); - } - - virtual void TearDown() override - { - TypeObjectFactory::delete_instance(); - DynamicDataFactory::delete_instance(); - DynamicTypeBuilderFactory::delete_instance(); - } - -}; - -TEST_F(DynamicTypes_4_2_Tests, Inheritance_And_Default_Value) -{ - StructTest struct_test; - ASSERT_TRUE(struct_test.uint64_() == 555); - ASSERT_TRUE(struct_test.int64_() == 0); -} - -TEST_F(DynamicTypes_4_2_Tests, Bitmask) -{ - using namespace bitmodule; - MyBitMask bitmask(static_cast(0)); - - ASSERT_TRUE(bitmask == static_cast(0)); - bitmask = MyBitMaskBits::flag0; - ASSERT_TRUE(bitmask == static_cast(1)); - bitmask = MyBitMaskBits::flag1; - ASSERT_TRUE(bitmask == static_cast(2)); - bitmask = MyBitMaskBits::flag4; - ASSERT_TRUE(bitmask == static_cast(16)); - bitmask = MyBitMaskBits::flag6; - ASSERT_TRUE(bitmask == static_cast(64)); - bitmask = MyBitMaskBits::flag7; - ASSERT_TRUE(bitmask == static_cast(128)); - - bitmask = static_cast(MyBitMaskBits::flag0 | MyBitMaskBits::flag4); - ASSERT_TRUE(bitmask == static_cast(17)); - - bitmask = static_cast(9); - ASSERT_TRUE(bitmask & MyBitMaskBits::flag0); - ASSERT_FALSE(bitmask & MyBitMaskBits::flag1); - ASSERT_FALSE(bitmask & MyBitMaskBits::flag4); -} - -TEST_F(DynamicTypes_4_2_Tests, Bitset) -{ - using namespace bitmodule; - MyBitset mybitset; - - ASSERT_TRUE(mybitset.a() == 0); - ASSERT_TRUE(mybitset.b() == 0); - ASSERT_TRUE(mybitset.c() == 0); - ASSERT_TRUE(mybitset.d() == 0); - ASSERT_TRUE(mybitset.e() == 0); - ASSERT_TRUE(mybitset.f() == 0); - ASSERT_TRUE(mybitset.parent_bitfield() == 0); - - mybitset.a(static_cast(15)); // 00001111 - ASSERT_TRUE(mybitset.a() == 7); // 00000111 - ASSERT_TRUE(mybitset.b() == 0); // b unaffected - ASSERT_FALSE(mybitset.b()); - mybitset.b(true); - ASSERT_TRUE(mybitset.b()); - mybitset.c(static_cast(-1));// 1111111111111111 - ASSERT_TRUE(mybitset.c() == 1023); // 0000001111111111 (2^10 - 1) - mybitset.d(-1); // 1111111111111111 - mybitset.e(5555); // 0001010110110011 (The most significant bit is not stored) - mybitset.f(3851); - ASSERT_TRUE(mybitset.d() == 31); // 0000111111111111 (2^12 - 1) - ASSERT_TRUE(mybitset.e() == 19); // 0000010110110011 (The most significant bit is not stored) - ASSERT_TRUE(mybitset.f() == 11); - mybitset.parent_bitfield(static_cast(-1));// 11111111111111111111111111111111 - ASSERT_TRUE(mybitset.parent_bitfield() == 131071); // 00000000000000111111111111111111 (2^17 - 1) -} - -TEST_F(DynamicTypes_4_2_Tests, Non_Serialized_Annotation) -{ - NewAliases struct_test; - struct_test.int8_(-8); - struct_test.uint8_(8); - struct_test.int16_(-16); - struct_test.uint16_(16); - struct_test.int32_(-32); - struct_test.uint32_(32); - struct_test.int64_(-64); - struct_test.uint64_(64); - struct_test.local_string("DON'T_SERIALIZE"); - - NewAliasesPubSubType pst; - NewAliases destination; - uint32_t payloadSize = static_cast(pst.getSerializedSizeProvider(&struct_test)()); - SerializedPayload_t payload(payloadSize); - - pst.serialize(&struct_test, &payload); - pst.deserialize(&payload, &destination); - - ASSERT_TRUE(destination.int8_() == -8); - ASSERT_TRUE(destination.uint8_() == 8); - ASSERT_TRUE(destination.int16_() == -16); - ASSERT_TRUE(destination.uint16_() == 16); - ASSERT_TRUE(destination.int32_() == -32); - ASSERT_TRUE(destination.uint32_() == 32); - ASSERT_TRUE(destination.int64_() == -64); - ASSERT_TRUE(destination.uint64_() == 64); - ASSERT_FALSE(destination.local_string() == "DON'T_SERIALIZE"); // Is non_serialized annotated -} - -TEST_F(DynamicTypes_4_2_Tests, New_Union_Discriminators) -{ - StructTest struct_test; - - ASSERT_TRUE(sizeof(struct_test.int8Union()._d()) == 1); - ASSERT_TRUE(sizeof(struct_test.octetUnion()._d()) == 1); - //ASSERT_TRUE(sizeof(struct_test.charUnion()._d()) == sizeof(wchar_t)); - - // int8Union - struct_test.int8Union().case_three(333); - struct_test.int8Union().case_six(666); - - struct_test.int8Union()._d() = 3; - ASSERT_TRUE(struct_test.int8Union().case_three() == 333); - try - { - ASSERT_FALSE(struct_test.int8Union().case_six() == 666); - ASSERT_TRUE(false); - } - catch (const BadParamException&) - { - } - - struct_test.int8Union()._d() = 6; - try - { - ASSERT_FALSE(struct_test.int8Union().case_three() == 333); - ASSERT_TRUE(false); - } - catch (const BadParamException&) - { - } - ASSERT_TRUE(struct_test.int8Union().case_six() == 666); - - // octetUnion - struct_test.octetUnion().case_five(555); - struct_test.octetUnion().case_seven(777); - - struct_test.octetUnion()._d() = 5; - ASSERT_TRUE(struct_test.octetUnion().case_five() == 555); - try - { - ASSERT_FALSE(struct_test.octetUnion().case_seven() == 777); - ASSERT_TRUE(false); - } - catch (const BadParamException&) - { - } - - struct_test.octetUnion()._d() = 7; - try - { - ASSERT_FALSE(struct_test.octetUnion().case_five() == 555); - ASSERT_TRUE(false); - } - catch (const BadParamException&) - { - } - ASSERT_TRUE(struct_test.octetUnion().case_seven() == 777); - - /* - // charUnion - struct_test.charUnion().case_zero(111); - struct_test.charUnion().case_one(222); - - struct_test.charUnion()._d() = L'a'; - ASSERT_TRUE(struct_test.charUnion().case_zero() == 111); - try - { - ASSERT_FALSE(struct_test.charUnion().case_one() == 222); - ASSERT_TRUE(false); - } - catch (const BadParamException&) - { - } - - struct_test.charUnion()._d() = L'b'; - try - { - ASSERT_FALSE(struct_test.charUnion().case_zero() == 111); - ASSERT_TRUE(false); - } - catch (const BadParamException&) - { - } - ASSERT_TRUE(struct_test.charUnion().case_one() == 222); - */ -} - -TEST_F(DynamicTypes_4_2_Tests, TypeObject_DynamicType_Conversion) -{ - registernew_features_4_2Types(); - - // TODO Bitset serialization isn't compatible. - const TypeIdentifier* identifier = GetStructTestIdentifier(true); - const TypeObject* object = GetCompleteStructTestObject(); - - DynamicType_ptr dyn_type = - TypeObjectFactory::get_instance()->build_dynamic_type("StructTest", identifier, object); - - TypeIdentifier conv_identifier; - TypeObject conv_object; - DynamicTypeBuilderFactory::get_instance()->build_type_object(dyn_type, conv_object, true, true); // Avoid factory - DynamicTypeBuilderFactory::get_instance()->build_type_identifier(dyn_type, conv_identifier, true); - - ASSERT_TRUE(*identifier == conv_identifier); - //ASSERT_TRUE(*object == conv_object); //TODO(richiware) Fails because not implemented get appendable flag to - //dynamic_type in `build_dynamic_type()`. - - // Serialize static <-> dynamic - - StructTest struct_test; - DynamicData_ptr dyn_data(DynamicDataFactory::get_instance()->create_data(dyn_type)); - - DynamicPubSubType pst_dynamic(dyn_type); - uint32_t payload_dyn_size = static_cast(pst_dynamic.getSerializedSizeProvider(dyn_data.get())()); - SerializedPayload_t payload(payload_dyn_size); - ASSERT_TRUE(pst_dynamic.serialize(dyn_data.get(), &payload)); - ASSERT_TRUE(payload.length == payload_dyn_size); - - StructTestPubSubType pst_static; - uint32_t payload_size = static_cast(pst_static.getSerializedSizeProvider(&struct_test)()); - SerializedPayload_t st_payload(payload_size); - ASSERT_TRUE(pst_static.serialize(&struct_test, &st_payload)); - ASSERT_TRUE(st_payload.length == payload_size); - - DynamicData_ptr dyn_data_from_dynamic(DynamicDataFactory::get_instance()->create_data(dyn_type)); - ASSERT_TRUE(pst_dynamic.deserialize(&payload, dyn_data_from_dynamic.get())); - - types::DynamicData_ptr dyn_data_from_static(DynamicDataFactory::get_instance()->create_data(dyn_type)); - //ASSERT_TRUE(pst_dynamic.deserialize(&st_payload, dyn_data_from_static.get())); //TODO(richiware) Bitsets are not - //serialized correctly currently by DynamicData. - //dynamic_type in `build_dynamic_type()`. - - // DEBUG Printing payloads - /* - std::cout << "Payload: " << std::endl; - for (int i = 0; i < payload_size; ++i) - { - std::cout << std::hex << (uint32_t)(payload.data[i]) << " "; - } - std::cout << std::endl; - std::cout << "ST_Payload: " << std::endl; - for (int i = 0; i < st_payload.length; ++i) - { - std::cout << std::hex << (uint32_t)(st_payload.data[i]) << " "; - } - std::cout << "--------------------------" << std::endl; - */ - ASSERT_TRUE(dyn_data_from_static->equals(dyn_data_from_dynamic.get())); -} - -/* TODO(richiware) Bitsets are not serialized correctly currently by DynamicData. - TEST_F(DynamicTypes_4_2_Tests, Static_Dynamic_Values) - { - registernew_features_4_2Types(); - - const TypeIdentifier* identifier = GetStructTestIdentifier(true); - const TypeObject* object = GetCompleteStructTestObject(); - - DynamicType_ptr dyn_type = - TypeObjectFactory::get_instance()->build_dynamic_type("StructTest", identifier, object); - - // Serialize static initialization with values - StructTest struct_test; - StructTestPubSubType pst_static; - - struct_test.int8_(-8); - struct_test.uint8_(8); - struct_test.int16_(-16); - struct_test.uint16_(16); - struct_test.int32_(-32); - struct_test.uint32_(32); - struct_test.int64_(-64); - struct_test.uint64_(64); - struct_test.local_string("DON'T_SERIALIZE"); - struct_test.charUnion().case_one(11111); - struct_test.octetUnion().case_seven(77777); - struct_test.int8Union().case_three(33333); - struct_test.myStructBits().mybitset().parent_bitfield(2121); - struct_test.myStructBits().mybitset().a(5); - struct_test.myStructBits().mybitset().b(true); - struct_test.myStructBits().mybitset().c(333); - struct_test.myStructBits().mybitset().d(4000); - struct_test.myStructBits().mybitset().e(4001); - struct_test.myStructBits().mybitset().f(3001); - struct_test.myStructBits().mybitmask( - static_cast(bitmodule::MyBitMaskBits::flag0 | bitmodule::MyBitMaskBits::flag4)); - struct_test.myStructBits().two( - static_cast(bitmodule::MyBitMaskBits::flag1 | bitmodule::MyBitMaskBits::flag6)); - struct_test.myStructBits().mylong(static_cast(struct_test.myStructBits().two())); - - // Static serialization - uint32_t payload_size = static_cast(pst_static.getSerializedSizeProvider(&struct_test)()); - SerializedPayload_t st_payload(payload_size); - ASSERT_TRUE(pst_static.serialize(&struct_test, &st_payload)); - ASSERT_TRUE(st_payload.length == payload_size); - - // Dynamic deserialization from static - DynamicPubSubType pst_dynamic(dyn_type); - DynamicData_ptr dyn_data(DynamicDataFactory::get_instance()->create_data(dyn_type)); - ASSERT_TRUE(pst_dynamic.deserialize(&st_payload, dyn_data.get())); - - - // Dynamic serialization - uint32_t payload_dyn_size = static_cast(pst_dynamic.getSerializedSizeProvider(dyn_data.get())()); - SerializedPayload_t dyn_payload(payload_dyn_size); - ASSERT_TRUE(pst_dynamic.serialize(dyn_data.get(), &dyn_payload)); - ASSERT_TRUE(dyn_payload.length == payload_dyn_size); - - // Static deserialization from dynamic - StructTest struct_test_from_dynamic; - ASSERT_TRUE(pst_static.deserialize(&dyn_payload, &struct_test_from_dynamic)); - - // Check values - ASSERT_TRUE(struct_test_from_dynamic.int8_() == struct_test.int8_()); - ASSERT_TRUE(struct_test_from_dynamic.uint8_() == struct_test.uint8_()); - ASSERT_TRUE(struct_test_from_dynamic.int16_() == struct_test.int16_()); - ASSERT_TRUE(struct_test_from_dynamic.uint16_() == struct_test.uint16_()); - ASSERT_TRUE(struct_test_from_dynamic.int32_() == struct_test.int32_()); - ASSERT_TRUE(struct_test_from_dynamic.uint32_() == struct_test.uint32_()); - ASSERT_TRUE(struct_test_from_dynamic.int64_() == struct_test.int64_()); - ASSERT_TRUE(struct_test_from_dynamic.uint64_() == struct_test.uint64_()); - ASSERT_FALSE(struct_test_from_dynamic.local_string() == struct_test.local_string()); // Non serialized - //ASSERT_TRUE(struct_test_from_dynamic.charUnion().case_one() == struct_test.charUnion().case_one()); - ASSERT_TRUE(struct_test_from_dynamic.octetUnion().case_seven() == struct_test.octetUnion().case_seven()); - ASSERT_TRUE(struct_test_from_dynamic.int8Union().case_three() == struct_test.int8Union().case_three()); - ASSERT_TRUE( - struct_test_from_dynamic.myStructBits().mybitset().parent_bitfield() == - struct_test.myStructBits().mybitset().parent_bitfield()); - ASSERT_TRUE(struct_test_from_dynamic.myStructBits().mybitset().a() == struct_test.myStructBits().mybitset().a()); - ASSERT_TRUE(struct_test_from_dynamic.myStructBits().mybitset().b() == struct_test.myStructBits().mybitset().b()); - ASSERT_TRUE(struct_test_from_dynamic.myStructBits().mybitset().c() == struct_test.myStructBits().mybitset().c()); - ASSERT_TRUE(struct_test_from_dynamic.myStructBits().mybitset().d() == struct_test.myStructBits().mybitset().d()); - ASSERT_TRUE(struct_test_from_dynamic.myStructBits().mybitset().e() == struct_test.myStructBits().mybitset().e()); - ASSERT_TRUE(struct_test_from_dynamic.myStructBits().mybitset().f() == struct_test.myStructBits().mybitset().f()); - ASSERT_TRUE(struct_test_from_dynamic.myStructBits().mybitmask() == struct_test.myStructBits().mybitmask()); - ASSERT_TRUE(struct_test_from_dynamic.myStructBits().two() == struct_test.myStructBits().two()); - ASSERT_TRUE(struct_test_from_dynamic.myStructBits().mylong() == struct_test.myStructBits().mylong()); - - ASSERT_TRUE(dyn_data->get_int8_value(dyn_data->get_member_id_by_name("int8_")) == struct_test.int8_()); - ASSERT_TRUE(dyn_data->get_uint8_value(dyn_data->get_member_id_by_name("uint8_")) == struct_test.uint8_()); - ASSERT_TRUE(dyn_data->get_int16_value(dyn_data->get_member_id_by_name("int16_")) == struct_test.int16_()); - ASSERT_TRUE(dyn_data->get_uint16_value(dyn_data->get_member_id_by_name("uint16_")) == struct_test.uint16_()); - ASSERT_TRUE(dyn_data->get_int32_value(dyn_data->get_member_id_by_name("int32_")) == struct_test.int32_()); - ASSERT_TRUE(dyn_data->get_uint32_value(dyn_data->get_member_id_by_name("uint32_")) == struct_test.uint32_()); - ASSERT_TRUE(dyn_data->get_int64_value(dyn_data->get_member_id_by_name("int64_")) == struct_test.int64_()); - ASSERT_TRUE(dyn_data->get_uint64_value(dyn_data->get_member_id_by_name("uint64_")) == struct_test.uint64_()); - ASSERT_FALSE(dyn_data->get_string_value(dyn_data->get_member_id_by_name("local_string")) == - struct_test.local_string()); // Non serialized - - DynamicData* charUnion = dyn_data->loan_value(dyn_data->get_member_id_by_name("charUnion")); - ASSERT_TRUE(charUnion->get_int32_value(charUnion->get_member_id_by_name("case_one")) == - struct_test.charUnion().case_one()); - dyn_data->return_loaned_value(charUnion); - - DynamicData* octetUnion = dyn_data->loan_value(dyn_data->get_member_id_by_name("octetUnion")); - ASSERT_TRUE(octetUnion->get_int32_value(octetUnion->get_member_id_by_name("case_seven")) == - struct_test.octetUnion().case_seven()); - dyn_data->return_loaned_value(octetUnion); - - DynamicData* int8Union = dyn_data->loan_value(dyn_data->get_member_id_by_name("int8Union")); - ASSERT_TRUE(int8Union->get_int32_value(int8Union->get_member_id_by_name("case_three")) == - struct_test.int8Union().case_three()); - dyn_data->return_loaned_value(int8Union); - - DynamicData* myStructBits = dyn_data->loan_value(dyn_data->get_member_id_by_name("myStructBits")); - DynamicData* mybitset = myStructBits->loan_value(myStructBits->get_member_id_by_name("mybitset")); - - ASSERT_TRUE(mybitset->get_uint32_value(mybitset->get_member_id_by_name("parent_bitfield")) - == struct_test.myStructBits().mybitset().parent_bitfield()); - ASSERT_TRUE(mybitset->get_char8_value(mybitset->get_member_id_by_name("a")) - == struct_test.myStructBits().mybitset().a()); - ASSERT_TRUE(mybitset->get_bool_value(mybitset->get_member_id_by_name("b")) - == struct_test.myStructBits().mybitset().b()); - ASSERT_TRUE(mybitset->get_uint16_value(mybitset->get_member_id_by_name("c")) - == struct_test.myStructBits().mybitset().c()); - ASSERT_TRUE(mybitset->get_int16_value(mybitset->get_member_id_by_name("d")) - == struct_test.myStructBits().mybitset().d()); - ASSERT_TRUE(mybitset->get_int16_value(mybitset->get_member_id_by_name("e")) - == struct_test.myStructBits().mybitset().e()); - ASSERT_TRUE(mybitset->get_int16_value(mybitset->get_member_id_by_name("f")) - == struct_test.myStructBits().mybitset().f()); - - myStructBits->return_loaned_value(mybitset); - ASSERT_TRUE(myStructBits->get_uint64_value(myStructBits->get_member_id_by_name("mybitmask")) == - struct_test.myStructBits().mybitmask()); - ASSERT_TRUE(myStructBits->get_uint64_value(myStructBits->get_member_id_by_name("two")) == - struct_test.myStructBits().two()); - ASSERT_TRUE(myStructBits->get_int32_value(myStructBits->get_member_id_by_name("mylong")) == - struct_test.myStructBits().mylong()); - dyn_data->return_loaned_value(myStructBits); - } - */ - -int main( - int argc, - char** argv) -{ - eprosima::fastdds::dds::Log::SetVerbosity(eprosima::fastdds::dds::Log::Info); - - testing::InitGoogleTest(&argc, argv); - return RUN_ALL_TESTS(); -} diff --git a/test/unittest/dynamic_types/idl/Basic.cxx b/test/unittest/dynamic_types/idl/Basic.cxx deleted file mode 100644 index 90e2adc8191..00000000000 --- a/test/unittest/dynamic_types/idl/Basic.cxx +++ /dev/null @@ -1,3858 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file Basic.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "Basic.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#include "BasicTypeObject.h" - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - - - - -EnumStruct::EnumStruct() -{ - // Just to register all known types - registerBasicTypes(); -} - -EnumStruct::~EnumStruct() -{ -} - -EnumStruct::EnumStruct( - const EnumStruct& x) -{ - m_my_enum = x.m_my_enum; -} - -EnumStruct::EnumStruct( - EnumStruct&& x) noexcept -{ - m_my_enum = x.m_my_enum; -} - -EnumStruct& EnumStruct::operator =( - const EnumStruct& x) -{ - - m_my_enum = x.m_my_enum; - return *this; -} - -EnumStruct& EnumStruct::operator =( - EnumStruct&& x) noexcept -{ - - m_my_enum = x.m_my_enum; - return *this; -} - -bool EnumStruct::operator ==( - const EnumStruct& x) const -{ - return (m_my_enum == x.m_my_enum); -} - -bool EnumStruct::operator !=( - const EnumStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member my_enum - * @param _my_enum New value for member my_enum - */ -void EnumStruct::my_enum( - MyEnum _my_enum) -{ - m_my_enum = _my_enum; -} - -/*! - * @brief This function returns the value of member my_enum - * @return Value of member my_enum - */ -MyEnum EnumStruct::my_enum() const -{ - return m_my_enum; -} - -/*! - * @brief This function returns a reference to member my_enum - * @return Reference to member my_enum - */ -MyEnum& EnumStruct::my_enum() -{ - return m_my_enum; -} - - - - -AliasStruct::AliasStruct() -{ - // Just to register all known types - registerBasicTypes(); -} - -AliasStruct::~AliasStruct() -{ -} - -AliasStruct::AliasStruct( - const AliasStruct& x) -{ - m_my_alias = x.m_my_alias; -} - -AliasStruct::AliasStruct( - AliasStruct&& x) noexcept -{ - m_my_alias = x.m_my_alias; -} - -AliasStruct& AliasStruct::operator =( - const AliasStruct& x) -{ - - m_my_alias = x.m_my_alias; - return *this; -} - -AliasStruct& AliasStruct::operator =( - AliasStruct&& x) noexcept -{ - - m_my_alias = x.m_my_alias; - return *this; -} - -bool AliasStruct::operator ==( - const AliasStruct& x) const -{ - return (m_my_alias == x.m_my_alias); -} - -bool AliasStruct::operator !=( - const AliasStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member my_alias - * @param _my_alias New value for member my_alias - */ -void AliasStruct::my_alias( - MyAliasEnum _my_alias) -{ - m_my_alias = _my_alias; -} - -/*! - * @brief This function returns the value of member my_alias - * @return Value of member my_alias - */ -MyAliasEnum AliasStruct::my_alias() const -{ - return m_my_alias; -} - -/*! - * @brief This function returns a reference to member my_alias - * @return Reference to member my_alias - */ -MyAliasEnum& AliasStruct::my_alias() -{ - return m_my_alias; -} - - - - -AliasAliasStruct::AliasAliasStruct() -{ - // Just to register all known types - registerBasicTypes(); -} - -AliasAliasStruct::~AliasAliasStruct() -{ -} - -AliasAliasStruct::AliasAliasStruct( - const AliasAliasStruct& x) -{ - m_my_alias_alias = x.m_my_alias_alias; -} - -AliasAliasStruct::AliasAliasStruct( - AliasAliasStruct&& x) noexcept -{ - m_my_alias_alias = x.m_my_alias_alias; -} - -AliasAliasStruct& AliasAliasStruct::operator =( - const AliasAliasStruct& x) -{ - - m_my_alias_alias = x.m_my_alias_alias; - return *this; -} - -AliasAliasStruct& AliasAliasStruct::operator =( - AliasAliasStruct&& x) noexcept -{ - - m_my_alias_alias = x.m_my_alias_alias; - return *this; -} - -bool AliasAliasStruct::operator ==( - const AliasAliasStruct& x) const -{ - return (m_my_alias_alias == x.m_my_alias_alias); -} - -bool AliasAliasStruct::operator !=( - const AliasAliasStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member my_alias_alias - * @param _my_alias_alias New value for member my_alias_alias - */ -void AliasAliasStruct::my_alias_alias( - MyAliasAliasEnum _my_alias_alias) -{ - m_my_alias_alias = _my_alias_alias; -} - -/*! - * @brief This function returns the value of member my_alias_alias - * @return Value of member my_alias_alias - */ -MyAliasAliasEnum AliasAliasStruct::my_alias_alias() const -{ - return m_my_alias_alias; -} - -/*! - * @brief This function returns a reference to member my_alias_alias - * @return Reference to member my_alias_alias - */ -MyAliasAliasEnum& AliasAliasStruct::my_alias_alias() -{ - return m_my_alias_alias; -} - - - - -BoolStruct::BoolStruct() -{ - // Just to register all known types - registerBasicTypes(); -} - -BoolStruct::~BoolStruct() -{ -} - -BoolStruct::BoolStruct( - const BoolStruct& x) -{ - m_my_bool = x.m_my_bool; -} - -BoolStruct::BoolStruct( - BoolStruct&& x) noexcept -{ - m_my_bool = x.m_my_bool; -} - -BoolStruct& BoolStruct::operator =( - const BoolStruct& x) -{ - - m_my_bool = x.m_my_bool; - return *this; -} - -BoolStruct& BoolStruct::operator =( - BoolStruct&& x) noexcept -{ - - m_my_bool = x.m_my_bool; - return *this; -} - -bool BoolStruct::operator ==( - const BoolStruct& x) const -{ - return (m_my_bool == x.m_my_bool); -} - -bool BoolStruct::operator !=( - const BoolStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member my_bool - * @param _my_bool New value for member my_bool - */ -void BoolStruct::my_bool( - bool _my_bool) -{ - m_my_bool = _my_bool; -} - -/*! - * @brief This function returns the value of member my_bool - * @return Value of member my_bool - */ -bool BoolStruct::my_bool() const -{ - return m_my_bool; -} - -/*! - * @brief This function returns a reference to member my_bool - * @return Reference to member my_bool - */ -bool& BoolStruct::my_bool() -{ - return m_my_bool; -} - - - - -OctetStruct::OctetStruct() -{ - // Just to register all known types - registerBasicTypes(); -} - -OctetStruct::~OctetStruct() -{ -} - -OctetStruct::OctetStruct( - const OctetStruct& x) -{ - m_my_octet = x.m_my_octet; -} - -OctetStruct::OctetStruct( - OctetStruct&& x) noexcept -{ - m_my_octet = x.m_my_octet; -} - -OctetStruct& OctetStruct::operator =( - const OctetStruct& x) -{ - - m_my_octet = x.m_my_octet; - return *this; -} - -OctetStruct& OctetStruct::operator =( - OctetStruct&& x) noexcept -{ - - m_my_octet = x.m_my_octet; - return *this; -} - -bool OctetStruct::operator ==( - const OctetStruct& x) const -{ - return (m_my_octet == x.m_my_octet); -} - -bool OctetStruct::operator !=( - const OctetStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member my_octet - * @param _my_octet New value for member my_octet - */ -void OctetStruct::my_octet( - uint8_t _my_octet) -{ - m_my_octet = _my_octet; -} - -/*! - * @brief This function returns the value of member my_octet - * @return Value of member my_octet - */ -uint8_t OctetStruct::my_octet() const -{ - return m_my_octet; -} - -/*! - * @brief This function returns a reference to member my_octet - * @return Reference to member my_octet - */ -uint8_t& OctetStruct::my_octet() -{ - return m_my_octet; -} - - - - -ShortStruct::ShortStruct() -{ - // Just to register all known types - registerBasicTypes(); -} - -ShortStruct::~ShortStruct() -{ -} - -ShortStruct::ShortStruct( - const ShortStruct& x) -{ - m_my_int16 = x.m_my_int16; -} - -ShortStruct::ShortStruct( - ShortStruct&& x) noexcept -{ - m_my_int16 = x.m_my_int16; -} - -ShortStruct& ShortStruct::operator =( - const ShortStruct& x) -{ - - m_my_int16 = x.m_my_int16; - return *this; -} - -ShortStruct& ShortStruct::operator =( - ShortStruct&& x) noexcept -{ - - m_my_int16 = x.m_my_int16; - return *this; -} - -bool ShortStruct::operator ==( - const ShortStruct& x) const -{ - return (m_my_int16 == x.m_my_int16); -} - -bool ShortStruct::operator !=( - const ShortStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member my_int16 - * @param _my_int16 New value for member my_int16 - */ -void ShortStruct::my_int16( - int16_t _my_int16) -{ - m_my_int16 = _my_int16; -} - -/*! - * @brief This function returns the value of member my_int16 - * @return Value of member my_int16 - */ -int16_t ShortStruct::my_int16() const -{ - return m_my_int16; -} - -/*! - * @brief This function returns a reference to member my_int16 - * @return Reference to member my_int16 - */ -int16_t& ShortStruct::my_int16() -{ - return m_my_int16; -} - - - - -LongStruct::LongStruct() -{ - // Just to register all known types - registerBasicTypes(); -} - -LongStruct::~LongStruct() -{ -} - -LongStruct::LongStruct( - const LongStruct& x) -{ - m_my_int32 = x.m_my_int32; -} - -LongStruct::LongStruct( - LongStruct&& x) noexcept -{ - m_my_int32 = x.m_my_int32; -} - -LongStruct& LongStruct::operator =( - const LongStruct& x) -{ - - m_my_int32 = x.m_my_int32; - return *this; -} - -LongStruct& LongStruct::operator =( - LongStruct&& x) noexcept -{ - - m_my_int32 = x.m_my_int32; - return *this; -} - -bool LongStruct::operator ==( - const LongStruct& x) const -{ - return (m_my_int32 == x.m_my_int32); -} - -bool LongStruct::operator !=( - const LongStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member my_int32 - * @param _my_int32 New value for member my_int32 - */ -void LongStruct::my_int32( - int32_t _my_int32) -{ - m_my_int32 = _my_int32; -} - -/*! - * @brief This function returns the value of member my_int32 - * @return Value of member my_int32 - */ -int32_t LongStruct::my_int32() const -{ - return m_my_int32; -} - -/*! - * @brief This function returns a reference to member my_int32 - * @return Reference to member my_int32 - */ -int32_t& LongStruct::my_int32() -{ - return m_my_int32; -} - - - - -LongLongStruct::LongLongStruct() -{ - // Just to register all known types - registerBasicTypes(); -} - -LongLongStruct::~LongLongStruct() -{ -} - -LongLongStruct::LongLongStruct( - const LongLongStruct& x) -{ - m_my_int64 = x.m_my_int64; -} - -LongLongStruct::LongLongStruct( - LongLongStruct&& x) noexcept -{ - m_my_int64 = x.m_my_int64; -} - -LongLongStruct& LongLongStruct::operator =( - const LongLongStruct& x) -{ - - m_my_int64 = x.m_my_int64; - return *this; -} - -LongLongStruct& LongLongStruct::operator =( - LongLongStruct&& x) noexcept -{ - - m_my_int64 = x.m_my_int64; - return *this; -} - -bool LongLongStruct::operator ==( - const LongLongStruct& x) const -{ - return (m_my_int64 == x.m_my_int64); -} - -bool LongLongStruct::operator !=( - const LongLongStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member my_int64 - * @param _my_int64 New value for member my_int64 - */ -void LongLongStruct::my_int64( - int64_t _my_int64) -{ - m_my_int64 = _my_int64; -} - -/*! - * @brief This function returns the value of member my_int64 - * @return Value of member my_int64 - */ -int64_t LongLongStruct::my_int64() const -{ - return m_my_int64; -} - -/*! - * @brief This function returns a reference to member my_int64 - * @return Reference to member my_int64 - */ -int64_t& LongLongStruct::my_int64() -{ - return m_my_int64; -} - - - - -UShortStruct::UShortStruct() -{ - // Just to register all known types - registerBasicTypes(); -} - -UShortStruct::~UShortStruct() -{ -} - -UShortStruct::UShortStruct( - const UShortStruct& x) -{ - m_my_uint16 = x.m_my_uint16; -} - -UShortStruct::UShortStruct( - UShortStruct&& x) noexcept -{ - m_my_uint16 = x.m_my_uint16; -} - -UShortStruct& UShortStruct::operator =( - const UShortStruct& x) -{ - - m_my_uint16 = x.m_my_uint16; - return *this; -} - -UShortStruct& UShortStruct::operator =( - UShortStruct&& x) noexcept -{ - - m_my_uint16 = x.m_my_uint16; - return *this; -} - -bool UShortStruct::operator ==( - const UShortStruct& x) const -{ - return (m_my_uint16 == x.m_my_uint16); -} - -bool UShortStruct::operator !=( - const UShortStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member my_uint16 - * @param _my_uint16 New value for member my_uint16 - */ -void UShortStruct::my_uint16( - uint16_t _my_uint16) -{ - m_my_uint16 = _my_uint16; -} - -/*! - * @brief This function returns the value of member my_uint16 - * @return Value of member my_uint16 - */ -uint16_t UShortStruct::my_uint16() const -{ - return m_my_uint16; -} - -/*! - * @brief This function returns a reference to member my_uint16 - * @return Reference to member my_uint16 - */ -uint16_t& UShortStruct::my_uint16() -{ - return m_my_uint16; -} - - - - -ULongStruct::ULongStruct() -{ - // Just to register all known types - registerBasicTypes(); -} - -ULongStruct::~ULongStruct() -{ -} - -ULongStruct::ULongStruct( - const ULongStruct& x) -{ - m_my_uint32 = x.m_my_uint32; -} - -ULongStruct::ULongStruct( - ULongStruct&& x) noexcept -{ - m_my_uint32 = x.m_my_uint32; -} - -ULongStruct& ULongStruct::operator =( - const ULongStruct& x) -{ - - m_my_uint32 = x.m_my_uint32; - return *this; -} - -ULongStruct& ULongStruct::operator =( - ULongStruct&& x) noexcept -{ - - m_my_uint32 = x.m_my_uint32; - return *this; -} - -bool ULongStruct::operator ==( - const ULongStruct& x) const -{ - return (m_my_uint32 == x.m_my_uint32); -} - -bool ULongStruct::operator !=( - const ULongStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member my_uint32 - * @param _my_uint32 New value for member my_uint32 - */ -void ULongStruct::my_uint32( - uint32_t _my_uint32) -{ - m_my_uint32 = _my_uint32; -} - -/*! - * @brief This function returns the value of member my_uint32 - * @return Value of member my_uint32 - */ -uint32_t ULongStruct::my_uint32() const -{ - return m_my_uint32; -} - -/*! - * @brief This function returns a reference to member my_uint32 - * @return Reference to member my_uint32 - */ -uint32_t& ULongStruct::my_uint32() -{ - return m_my_uint32; -} - - - - -ULongLongStruct::ULongLongStruct() -{ - // Just to register all known types - registerBasicTypes(); -} - -ULongLongStruct::~ULongLongStruct() -{ -} - -ULongLongStruct::ULongLongStruct( - const ULongLongStruct& x) -{ - m_my_uint64 = x.m_my_uint64; -} - -ULongLongStruct::ULongLongStruct( - ULongLongStruct&& x) noexcept -{ - m_my_uint64 = x.m_my_uint64; -} - -ULongLongStruct& ULongLongStruct::operator =( - const ULongLongStruct& x) -{ - - m_my_uint64 = x.m_my_uint64; - return *this; -} - -ULongLongStruct& ULongLongStruct::operator =( - ULongLongStruct&& x) noexcept -{ - - m_my_uint64 = x.m_my_uint64; - return *this; -} - -bool ULongLongStruct::operator ==( - const ULongLongStruct& x) const -{ - return (m_my_uint64 == x.m_my_uint64); -} - -bool ULongLongStruct::operator !=( - const ULongLongStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member my_uint64 - * @param _my_uint64 New value for member my_uint64 - */ -void ULongLongStruct::my_uint64( - uint64_t _my_uint64) -{ - m_my_uint64 = _my_uint64; -} - -/*! - * @brief This function returns the value of member my_uint64 - * @return Value of member my_uint64 - */ -uint64_t ULongLongStruct::my_uint64() const -{ - return m_my_uint64; -} - -/*! - * @brief This function returns a reference to member my_uint64 - * @return Reference to member my_uint64 - */ -uint64_t& ULongLongStruct::my_uint64() -{ - return m_my_uint64; -} - - - - -FloatStruct::FloatStruct() -{ - // Just to register all known types - registerBasicTypes(); -} - -FloatStruct::~FloatStruct() -{ -} - -FloatStruct::FloatStruct( - const FloatStruct& x) -{ - m_my_float32 = x.m_my_float32; -} - -FloatStruct::FloatStruct( - FloatStruct&& x) noexcept -{ - m_my_float32 = x.m_my_float32; -} - -FloatStruct& FloatStruct::operator =( - const FloatStruct& x) -{ - - m_my_float32 = x.m_my_float32; - return *this; -} - -FloatStruct& FloatStruct::operator =( - FloatStruct&& x) noexcept -{ - - m_my_float32 = x.m_my_float32; - return *this; -} - -bool FloatStruct::operator ==( - const FloatStruct& x) const -{ - return (m_my_float32 == x.m_my_float32); -} - -bool FloatStruct::operator !=( - const FloatStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member my_float32 - * @param _my_float32 New value for member my_float32 - */ -void FloatStruct::my_float32( - float _my_float32) -{ - m_my_float32 = _my_float32; -} - -/*! - * @brief This function returns the value of member my_float32 - * @return Value of member my_float32 - */ -float FloatStruct::my_float32() const -{ - return m_my_float32; -} - -/*! - * @brief This function returns a reference to member my_float32 - * @return Reference to member my_float32 - */ -float& FloatStruct::my_float32() -{ - return m_my_float32; -} - - - - -DoubleStruct::DoubleStruct() -{ - // Just to register all known types - registerBasicTypes(); -} - -DoubleStruct::~DoubleStruct() -{ -} - -DoubleStruct::DoubleStruct( - const DoubleStruct& x) -{ - m_my_float64 = x.m_my_float64; -} - -DoubleStruct::DoubleStruct( - DoubleStruct&& x) noexcept -{ - m_my_float64 = x.m_my_float64; -} - -DoubleStruct& DoubleStruct::operator =( - const DoubleStruct& x) -{ - - m_my_float64 = x.m_my_float64; - return *this; -} - -DoubleStruct& DoubleStruct::operator =( - DoubleStruct&& x) noexcept -{ - - m_my_float64 = x.m_my_float64; - return *this; -} - -bool DoubleStruct::operator ==( - const DoubleStruct& x) const -{ - return (m_my_float64 == x.m_my_float64); -} - -bool DoubleStruct::operator !=( - const DoubleStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member my_float64 - * @param _my_float64 New value for member my_float64 - */ -void DoubleStruct::my_float64( - double _my_float64) -{ - m_my_float64 = _my_float64; -} - -/*! - * @brief This function returns the value of member my_float64 - * @return Value of member my_float64 - */ -double DoubleStruct::my_float64() const -{ - return m_my_float64; -} - -/*! - * @brief This function returns a reference to member my_float64 - * @return Reference to member my_float64 - */ -double& DoubleStruct::my_float64() -{ - return m_my_float64; -} - - - - -LongDoubleStruct::LongDoubleStruct() -{ - // Just to register all known types - registerBasicTypes(); -} - -LongDoubleStruct::~LongDoubleStruct() -{ -} - -LongDoubleStruct::LongDoubleStruct( - const LongDoubleStruct& x) -{ - m_my_float128 = x.m_my_float128; -} - -LongDoubleStruct::LongDoubleStruct( - LongDoubleStruct&& x) noexcept -{ - m_my_float128 = x.m_my_float128; -} - -LongDoubleStruct& LongDoubleStruct::operator =( - const LongDoubleStruct& x) -{ - - m_my_float128 = x.m_my_float128; - return *this; -} - -LongDoubleStruct& LongDoubleStruct::operator =( - LongDoubleStruct&& x) noexcept -{ - - m_my_float128 = x.m_my_float128; - return *this; -} - -bool LongDoubleStruct::operator ==( - const LongDoubleStruct& x) const -{ - return (m_my_float128 == x.m_my_float128); -} - -bool LongDoubleStruct::operator !=( - const LongDoubleStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member my_float128 - * @param _my_float128 New value for member my_float128 - */ -void LongDoubleStruct::my_float128( - long double _my_float128) -{ - m_my_float128 = _my_float128; -} - -/*! - * @brief This function returns the value of member my_float128 - * @return Value of member my_float128 - */ -long double LongDoubleStruct::my_float128() const -{ - return m_my_float128; -} - -/*! - * @brief This function returns a reference to member my_float128 - * @return Reference to member my_float128 - */ -long double& LongDoubleStruct::my_float128() -{ - return m_my_float128; -} - - - - -CharStruct::CharStruct() -{ - // Just to register all known types - registerBasicTypes(); -} - -CharStruct::~CharStruct() -{ -} - -CharStruct::CharStruct( - const CharStruct& x) -{ - m_my_char = x.m_my_char; -} - -CharStruct::CharStruct( - CharStruct&& x) noexcept -{ - m_my_char = x.m_my_char; -} - -CharStruct& CharStruct::operator =( - const CharStruct& x) -{ - - m_my_char = x.m_my_char; - return *this; -} - -CharStruct& CharStruct::operator =( - CharStruct&& x) noexcept -{ - - m_my_char = x.m_my_char; - return *this; -} - -bool CharStruct::operator ==( - const CharStruct& x) const -{ - return (m_my_char == x.m_my_char); -} - -bool CharStruct::operator !=( - const CharStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member my_char - * @param _my_char New value for member my_char - */ -void CharStruct::my_char( - char _my_char) -{ - m_my_char = _my_char; -} - -/*! - * @brief This function returns the value of member my_char - * @return Value of member my_char - */ -char CharStruct::my_char() const -{ - return m_my_char; -} - -/*! - * @brief This function returns a reference to member my_char - * @return Reference to member my_char - */ -char& CharStruct::my_char() -{ - return m_my_char; -} - - - - -WCharStruct::WCharStruct() -{ - // Just to register all known types - registerBasicTypes(); -} - -WCharStruct::~WCharStruct() -{ -} - -WCharStruct::WCharStruct( - const WCharStruct& x) -{ - m_my_wchar = x.m_my_wchar; -} - -WCharStruct::WCharStruct( - WCharStruct&& x) noexcept -{ - m_my_wchar = x.m_my_wchar; -} - -WCharStruct& WCharStruct::operator =( - const WCharStruct& x) -{ - - m_my_wchar = x.m_my_wchar; - return *this; -} - -WCharStruct& WCharStruct::operator =( - WCharStruct&& x) noexcept -{ - - m_my_wchar = x.m_my_wchar; - return *this; -} - -bool WCharStruct::operator ==( - const WCharStruct& x) const -{ - return (m_my_wchar == x.m_my_wchar); -} - -bool WCharStruct::operator !=( - const WCharStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member my_wchar - * @param _my_wchar New value for member my_wchar - */ -void WCharStruct::my_wchar( - wchar_t _my_wchar) -{ - m_my_wchar = _my_wchar; -} - -/*! - * @brief This function returns the value of member my_wchar - * @return Value of member my_wchar - */ -wchar_t WCharStruct::my_wchar() const -{ - return m_my_wchar; -} - -/*! - * @brief This function returns a reference to member my_wchar - * @return Reference to member my_wchar - */ -wchar_t& WCharStruct::my_wchar() -{ - return m_my_wchar; -} - - - - -StringStruct::StringStruct() -{ - // Just to register all known types - registerBasicTypes(); -} - -StringStruct::~StringStruct() -{ -} - -StringStruct::StringStruct( - const StringStruct& x) -{ - m_my_string = x.m_my_string; -} - -StringStruct::StringStruct( - StringStruct&& x) noexcept -{ - m_my_string = std::move(x.m_my_string); -} - -StringStruct& StringStruct::operator =( - const StringStruct& x) -{ - - m_my_string = x.m_my_string; - return *this; -} - -StringStruct& StringStruct::operator =( - StringStruct&& x) noexcept -{ - - m_my_string = std::move(x.m_my_string); - return *this; -} - -bool StringStruct::operator ==( - const StringStruct& x) const -{ - return (m_my_string == x.m_my_string); -} - -bool StringStruct::operator !=( - const StringStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_string - * @param _my_string New value to be copied in member my_string - */ -void StringStruct::my_string( - const std::string& _my_string) -{ - m_my_string = _my_string; -} - -/*! - * @brief This function moves the value in member my_string - * @param _my_string New value to be moved in member my_string - */ -void StringStruct::my_string( - std::string&& _my_string) -{ - m_my_string = std::move(_my_string); -} - -/*! - * @brief This function returns a constant reference to member my_string - * @return Constant reference to member my_string - */ -const std::string& StringStruct::my_string() const -{ - return m_my_string; -} - -/*! - * @brief This function returns a reference to member my_string - * @return Reference to member my_string - */ -std::string& StringStruct::my_string() -{ - return m_my_string; -} - - - - -WStringStruct::WStringStruct() -{ - // Just to register all known types - registerBasicTypes(); -} - -WStringStruct::~WStringStruct() -{ -} - -WStringStruct::WStringStruct( - const WStringStruct& x) -{ - m_my_wstring = x.m_my_wstring; -} - -WStringStruct::WStringStruct( - WStringStruct&& x) noexcept -{ - m_my_wstring = std::move(x.m_my_wstring); -} - -WStringStruct& WStringStruct::operator =( - const WStringStruct& x) -{ - - m_my_wstring = x.m_my_wstring; - return *this; -} - -WStringStruct& WStringStruct::operator =( - WStringStruct&& x) noexcept -{ - - m_my_wstring = std::move(x.m_my_wstring); - return *this; -} - -bool WStringStruct::operator ==( - const WStringStruct& x) const -{ - return (m_my_wstring == x.m_my_wstring); -} - -bool WStringStruct::operator !=( - const WStringStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_wstring - * @param _my_wstring New value to be copied in member my_wstring - */ -void WStringStruct::my_wstring( - const std::wstring& _my_wstring) -{ - m_my_wstring = _my_wstring; -} - -/*! - * @brief This function moves the value in member my_wstring - * @param _my_wstring New value to be moved in member my_wstring - */ -void WStringStruct::my_wstring( - std::wstring&& _my_wstring) -{ - m_my_wstring = std::move(_my_wstring); -} - -/*! - * @brief This function returns a constant reference to member my_wstring - * @return Constant reference to member my_wstring - */ -const std::wstring& WStringStruct::my_wstring() const -{ - return m_my_wstring; -} - -/*! - * @brief This function returns a reference to member my_wstring - * @return Reference to member my_wstring - */ -std::wstring& WStringStruct::my_wstring() -{ - return m_my_wstring; -} - - - - -LargeStringStruct::LargeStringStruct() -{ - // Just to register all known types - registerBasicTypes(); -} - -LargeStringStruct::~LargeStringStruct() -{ -} - -LargeStringStruct::LargeStringStruct( - const LargeStringStruct& x) -{ - m_my_large_string = x.m_my_large_string; -} - -LargeStringStruct::LargeStringStruct( - LargeStringStruct&& x) noexcept -{ - m_my_large_string = std::move(x.m_my_large_string); -} - -LargeStringStruct& LargeStringStruct::operator =( - const LargeStringStruct& x) -{ - - m_my_large_string = x.m_my_large_string; - return *this; -} - -LargeStringStruct& LargeStringStruct::operator =( - LargeStringStruct&& x) noexcept -{ - - m_my_large_string = std::move(x.m_my_large_string); - return *this; -} - -bool LargeStringStruct::operator ==( - const LargeStringStruct& x) const -{ - return (m_my_large_string == x.m_my_large_string); -} - -bool LargeStringStruct::operator !=( - const LargeStringStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_large_string - * @param _my_large_string New value to be copied in member my_large_string - */ -void LargeStringStruct::my_large_string( - const eprosima::fastcdr::fixed_string<41925>& _my_large_string) -{ - m_my_large_string = _my_large_string; -} - -/*! - * @brief This function moves the value in member my_large_string - * @param _my_large_string New value to be moved in member my_large_string - */ -void LargeStringStruct::my_large_string( - eprosima::fastcdr::fixed_string<41925>&& _my_large_string) -{ - m_my_large_string = std::move(_my_large_string); -} - -/*! - * @brief This function returns a constant reference to member my_large_string - * @return Constant reference to member my_large_string - */ -const eprosima::fastcdr::fixed_string<41925>& LargeStringStruct::my_large_string() const -{ - return m_my_large_string; -} - -/*! - * @brief This function returns a reference to member my_large_string - * @return Reference to member my_large_string - */ -eprosima::fastcdr::fixed_string<41925>& LargeStringStruct::my_large_string() -{ - return m_my_large_string; -} - - - - -LargeWStringStruct::LargeWStringStruct() -{ - // Just to register all known types - registerBasicTypes(); -} - -LargeWStringStruct::~LargeWStringStruct() -{ -} - -LargeWStringStruct::LargeWStringStruct( - const LargeWStringStruct& x) -{ - m_my_large_wstring = x.m_my_large_wstring; -} - -LargeWStringStruct::LargeWStringStruct( - LargeWStringStruct&& x) noexcept -{ - m_my_large_wstring = std::move(x.m_my_large_wstring); -} - -LargeWStringStruct& LargeWStringStruct::operator =( - const LargeWStringStruct& x) -{ - - m_my_large_wstring = x.m_my_large_wstring; - return *this; -} - -LargeWStringStruct& LargeWStringStruct::operator =( - LargeWStringStruct&& x) noexcept -{ - - m_my_large_wstring = std::move(x.m_my_large_wstring); - return *this; -} - -bool LargeWStringStruct::operator ==( - const LargeWStringStruct& x) const -{ - return (m_my_large_wstring == x.m_my_large_wstring); -} - -bool LargeWStringStruct::operator !=( - const LargeWStringStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_large_wstring - * @param _my_large_wstring New value to be copied in member my_large_wstring - */ -void LargeWStringStruct::my_large_wstring( - const std::wstring& _my_large_wstring) -{ - m_my_large_wstring = _my_large_wstring; -} - -/*! - * @brief This function moves the value in member my_large_wstring - * @param _my_large_wstring New value to be moved in member my_large_wstring - */ -void LargeWStringStruct::my_large_wstring( - std::wstring&& _my_large_wstring) -{ - m_my_large_wstring = std::move(_my_large_wstring); -} - -/*! - * @brief This function returns a constant reference to member my_large_wstring - * @return Constant reference to member my_large_wstring - */ -const std::wstring& LargeWStringStruct::my_large_wstring() const -{ - return m_my_large_wstring; -} - -/*! - * @brief This function returns a reference to member my_large_wstring - * @return Reference to member my_large_wstring - */ -std::wstring& LargeWStringStruct::my_large_wstring() -{ - return m_my_large_wstring; -} - - - - -ArraytStruct::ArraytStruct() -{ - // Just to register all known types - registerBasicTypes(); -} - -ArraytStruct::~ArraytStruct() -{ -} - -ArraytStruct::ArraytStruct( - const ArraytStruct& x) -{ - m_my_array = x.m_my_array; -} - -ArraytStruct::ArraytStruct( - ArraytStruct&& x) noexcept -{ - m_my_array = std::move(x.m_my_array); -} - -ArraytStruct& ArraytStruct::operator =( - const ArraytStruct& x) -{ - - m_my_array = x.m_my_array; - return *this; -} - -ArraytStruct& ArraytStruct::operator =( - ArraytStruct&& x) noexcept -{ - - m_my_array = std::move(x.m_my_array); - return *this; -} - -bool ArraytStruct::operator ==( - const ArraytStruct& x) const -{ - return (m_my_array == x.m_my_array); -} - -bool ArraytStruct::operator !=( - const ArraytStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_array - * @param _my_array New value to be copied in member my_array - */ -void ArraytStruct::my_array( - const std::array, 2>, 2>& _my_array) -{ - m_my_array = _my_array; -} - -/*! - * @brief This function moves the value in member my_array - * @param _my_array New value to be moved in member my_array - */ -void ArraytStruct::my_array( - std::array, 2>, 2>&& _my_array) -{ - m_my_array = std::move(_my_array); -} - -/*! - * @brief This function returns a constant reference to member my_array - * @return Constant reference to member my_array - */ -const std::array, 2>, 2>& ArraytStruct::my_array() const -{ - return m_my_array; -} - -/*! - * @brief This function returns a reference to member my_array - * @return Reference to member my_array - */ -std::array, 2>, 2>& ArraytStruct::my_array() -{ - return m_my_array; -} - - - - - -ArrayArrayStruct::ArrayArrayStruct() -{ - // Just to register all known types - registerBasicTypes(); -} - -ArrayArrayStruct::~ArrayArrayStruct() -{ -} - -ArrayArrayStruct::ArrayArrayStruct( - const ArrayArrayStruct& x) -{ - m_my_array_array = x.m_my_array_array; -} - -ArrayArrayStruct::ArrayArrayStruct( - ArrayArrayStruct&& x) noexcept -{ - m_my_array_array = std::move(x.m_my_array_array); -} - -ArrayArrayStruct& ArrayArrayStruct::operator =( - const ArrayArrayStruct& x) -{ - - m_my_array_array = x.m_my_array_array; - return *this; -} - -ArrayArrayStruct& ArrayArrayStruct::operator =( - ArrayArrayStruct&& x) noexcept -{ - - m_my_array_array = std::move(x.m_my_array_array); - return *this; -} - -bool ArrayArrayStruct::operator ==( - const ArrayArrayStruct& x) const -{ - return (m_my_array_array == x.m_my_array_array); -} - -bool ArrayArrayStruct::operator !=( - const ArrayArrayStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_array_array - * @param _my_array_array New value to be copied in member my_array_array - */ -void ArrayArrayStruct::my_array_array( - const std::array, 2>& _my_array_array) -{ - m_my_array_array = _my_array_array; -} - -/*! - * @brief This function moves the value in member my_array_array - * @param _my_array_array New value to be moved in member my_array_array - */ -void ArrayArrayStruct::my_array_array( - std::array, 2>&& _my_array_array) -{ - m_my_array_array = std::move(_my_array_array); -} - -/*! - * @brief This function returns a constant reference to member my_array_array - * @return Constant reference to member my_array_array - */ -const std::array, 2>& ArrayArrayStruct::my_array_array() const -{ - return m_my_array_array; -} - -/*! - * @brief This function returns a reference to member my_array_array - * @return Reference to member my_array_array - */ -std::array, 2>& ArrayArrayStruct::my_array_array() -{ - return m_my_array_array; -} - - - - - - -SequenceStruct::SequenceStruct() -{ - // Just to register all known types - registerBasicTypes(); -} - -SequenceStruct::~SequenceStruct() -{ -} - -SequenceStruct::SequenceStruct( - const SequenceStruct& x) -{ - m_my_sequence = x.m_my_sequence; -} - -SequenceStruct::SequenceStruct( - SequenceStruct&& x) noexcept -{ - m_my_sequence = std::move(x.m_my_sequence); -} - -SequenceStruct& SequenceStruct::operator =( - const SequenceStruct& x) -{ - - m_my_sequence = x.m_my_sequence; - return *this; -} - -SequenceStruct& SequenceStruct::operator =( - SequenceStruct&& x) noexcept -{ - - m_my_sequence = std::move(x.m_my_sequence); - return *this; -} - -bool SequenceStruct::operator ==( - const SequenceStruct& x) const -{ - return (m_my_sequence == x.m_my_sequence); -} - -bool SequenceStruct::operator !=( - const SequenceStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_sequence - * @param _my_sequence New value to be copied in member my_sequence - */ -void SequenceStruct::my_sequence( - const std::vector& _my_sequence) -{ - m_my_sequence = _my_sequence; -} - -/*! - * @brief This function moves the value in member my_sequence - * @param _my_sequence New value to be moved in member my_sequence - */ -void SequenceStruct::my_sequence( - std::vector&& _my_sequence) -{ - m_my_sequence = std::move(_my_sequence); -} - -/*! - * @brief This function returns a constant reference to member my_sequence - * @return Constant reference to member my_sequence - */ -const std::vector& SequenceStruct::my_sequence() const -{ - return m_my_sequence; -} - -/*! - * @brief This function returns a reference to member my_sequence - * @return Reference to member my_sequence - */ -std::vector& SequenceStruct::my_sequence() -{ - return m_my_sequence; -} - - - - - - - - -SequenceSequenceStruct::SequenceSequenceStruct() -{ - // Just to register all known types - registerBasicTypes(); -} - -SequenceSequenceStruct::~SequenceSequenceStruct() -{ -} - -SequenceSequenceStruct::SequenceSequenceStruct( - const SequenceSequenceStruct& x) -{ - m_my_sequence_sequence = x.m_my_sequence_sequence; -} - -SequenceSequenceStruct::SequenceSequenceStruct( - SequenceSequenceStruct&& x) noexcept -{ - m_my_sequence_sequence = std::move(x.m_my_sequence_sequence); -} - -SequenceSequenceStruct& SequenceSequenceStruct::operator =( - const SequenceSequenceStruct& x) -{ - - m_my_sequence_sequence = x.m_my_sequence_sequence; - return *this; -} - -SequenceSequenceStruct& SequenceSequenceStruct::operator =( - SequenceSequenceStruct&& x) noexcept -{ - - m_my_sequence_sequence = std::move(x.m_my_sequence_sequence); - return *this; -} - -bool SequenceSequenceStruct::operator ==( - const SequenceSequenceStruct& x) const -{ - return (m_my_sequence_sequence == x.m_my_sequence_sequence); -} - -bool SequenceSequenceStruct::operator !=( - const SequenceSequenceStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_sequence_sequence - * @param _my_sequence_sequence New value to be copied in member my_sequence_sequence - */ -void SequenceSequenceStruct::my_sequence_sequence( - const std::vector>& _my_sequence_sequence) -{ - m_my_sequence_sequence = _my_sequence_sequence; -} - -/*! - * @brief This function moves the value in member my_sequence_sequence - * @param _my_sequence_sequence New value to be moved in member my_sequence_sequence - */ -void SequenceSequenceStruct::my_sequence_sequence( - std::vector>&& _my_sequence_sequence) -{ - m_my_sequence_sequence = std::move(_my_sequence_sequence); -} - -/*! - * @brief This function returns a constant reference to member my_sequence_sequence - * @return Constant reference to member my_sequence_sequence - */ -const std::vector>& SequenceSequenceStruct::my_sequence_sequence() const -{ - return m_my_sequence_sequence; -} - -/*! - * @brief This function returns a reference to member my_sequence_sequence - * @return Reference to member my_sequence_sequence - */ -std::vector>& SequenceSequenceStruct::my_sequence_sequence() -{ - return m_my_sequence_sequence; -} - - - - - - -MapStruct::MapStruct() -{ - // Just to register all known types - registerBasicTypes(); -} - -MapStruct::~MapStruct() -{ -} - -MapStruct::MapStruct( - const MapStruct& x) -{ - m_my_map = x.m_my_map; -} - -MapStruct::MapStruct( - MapStruct&& x) noexcept -{ - m_my_map = std::move(x.m_my_map); -} - -MapStruct& MapStruct::operator =( - const MapStruct& x) -{ - - m_my_map = x.m_my_map; - return *this; -} - -MapStruct& MapStruct::operator =( - MapStruct&& x) noexcept -{ - - m_my_map = std::move(x.m_my_map); - return *this; -} - -bool MapStruct::operator ==( - const MapStruct& x) const -{ - return (m_my_map == x.m_my_map); -} - -bool MapStruct::operator !=( - const MapStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_map - * @param _my_map New value to be copied in member my_map - */ -void MapStruct::my_map( - const std::map& _my_map) -{ - m_my_map = _my_map; -} - -/*! - * @brief This function moves the value in member my_map - * @param _my_map New value to be moved in member my_map - */ -void MapStruct::my_map( - std::map&& _my_map) -{ - m_my_map = std::move(_my_map); -} - -/*! - * @brief This function returns a constant reference to member my_map - * @return Constant reference to member my_map - */ -const std::map& MapStruct::my_map() const -{ - return m_my_map; -} - -/*! - * @brief This function returns a reference to member my_map - * @return Reference to member my_map - */ -std::map& MapStruct::my_map() -{ - return m_my_map; -} - - - - - - - - -MapMapStruct::MapMapStruct() -{ - // Just to register all known types - registerBasicTypes(); -} - -MapMapStruct::~MapMapStruct() -{ -} - -MapMapStruct::MapMapStruct( - const MapMapStruct& x) -{ - m_my_map_map = x.m_my_map_map; -} - -MapMapStruct::MapMapStruct( - MapMapStruct&& x) noexcept -{ - m_my_map_map = std::move(x.m_my_map_map); -} - -MapMapStruct& MapMapStruct::operator =( - const MapMapStruct& x) -{ - - m_my_map_map = x.m_my_map_map; - return *this; -} - -MapMapStruct& MapMapStruct::operator =( - MapMapStruct&& x) noexcept -{ - - m_my_map_map = std::move(x.m_my_map_map); - return *this; -} - -bool MapMapStruct::operator ==( - const MapMapStruct& x) const -{ - return (m_my_map_map == x.m_my_map_map); -} - -bool MapMapStruct::operator !=( - const MapMapStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_map_map - * @param _my_map_map New value to be copied in member my_map_map - */ -void MapMapStruct::my_map_map( - const std::map>& _my_map_map) -{ - m_my_map_map = _my_map_map; -} - -/*! - * @brief This function moves the value in member my_map_map - * @param _my_map_map New value to be moved in member my_map_map - */ -void MapMapStruct::my_map_map( - std::map>&& _my_map_map) -{ - m_my_map_map = std::move(_my_map_map); -} - -/*! - * @brief This function returns a constant reference to member my_map_map - * @return Constant reference to member my_map_map - */ -const std::map>& MapMapStruct::my_map_map() const -{ - return m_my_map_map; -} - -/*! - * @brief This function returns a reference to member my_map_map - * @return Reference to member my_map_map - */ -std::map>& MapMapStruct::my_map_map() -{ - return m_my_map_map; -} - - -MyBitset::MyBitset(){ - // Just to register all known types - registerBasicTypes(); -} - -MyBitset::~MyBitset() -{ -} - -MyBitset::MyBitset( - const MyBitset& x){ - m_bitset = x.m_bitset; -} - -MyBitset::MyBitset( - MyBitset&& x) noexcept { - m_bitset = x.m_bitset; -} - -MyBitset& MyBitset::operator =( - const MyBitset& x) -{ - - m_bitset = x.m_bitset; - - return *this; -} - -MyBitset& MyBitset::operator =( - MyBitset&& x) noexcept -{ - - m_bitset = x.m_bitset; - - return *this; -} - -bool MyBitset::operator ==( - const MyBitset& x) const -{ - - return m_bitset == x.m_bitset; -} - -bool MyBitset::operator !=( - const MyBitset& x) const -{ - return !(*this == x); -} - - -void MyBitset::a( - char _a) -{ - int base = 0; - int size = 2; - for (int i = base; i < base + size; ++i) - { - m_bitset.set(i, !!(_a & 0x01)); - _a = _a >> 1; - } - -} - -char MyBitset::a() const -{ - int base = 0; - int size = 2; - std::bitset<2> aux; - for (int i = 0; i < size; ++i) - { - aux.set(i, m_bitset.test(i + base)); - } - return static_cast(aux.to_ullong()); - -} - - - -void MyBitset::b( - uint32_t _b) -{ - int base = 10; - int size = 20; - for (int i = base; i < base + size; ++i) - { - m_bitset.set(i, !!(_b & 0x01)); - _b = _b >> 1; - } - -} - -uint32_t MyBitset::b() const -{ - int base = 10; - int size = 20; - std::bitset<20> aux; - for (int i = 0; i < size; ++i) - { - aux.set(i, m_bitset.test(i + base)); - } - return static_cast(aux.to_ullong()); - -} - - -std::bitset<30> MyBitset::bitset() const -{ - std::string str_value; - - str_value = m_bitset.to_string() + str_value; - - return std::bitset<30>(str_value); -} - -void MyBitset::bitset( - const std::bitset<30>& bitset) -{ - std::string str_value {bitset.to_string()}; - size_t base_diff {0}; - size_t last_post {std::string::npos}; - - base_diff += 30; - m_bitset = std::bitset<30>(str_value.substr(str_value.length() - base_diff, last_post)); -} - - - -BitsetStruct::BitsetStruct() -{ - // Just to register all known types - registerBasicTypes(); -} - -BitsetStruct::~BitsetStruct() -{ -} - -BitsetStruct::BitsetStruct( - const BitsetStruct& x) -{ - m_a = x.m_a; -} - -BitsetStruct::BitsetStruct( - BitsetStruct&& x) noexcept -{ - m_a = std::move(x.m_a); -} - -BitsetStruct& BitsetStruct::operator =( - const BitsetStruct& x) -{ - - m_a = x.m_a; - return *this; -} - -BitsetStruct& BitsetStruct::operator =( - BitsetStruct&& x) noexcept -{ - - m_a = std::move(x.m_a); - return *this; -} - -bool BitsetStruct::operator ==( - const BitsetStruct& x) const -{ - return (m_a == x.m_a); -} - -bool BitsetStruct::operator !=( - const BitsetStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member a - * @param _a New value to be copied in member a - */ -void BitsetStruct::a( - const MyBitset& _a) -{ - m_a = _a; -} - -/*! - * @brief This function moves the value in member a - * @param _a New value to be moved in member a - */ -void BitsetStruct::a( - MyBitset&& _a) -{ - m_a = std::move(_a); -} - -/*! - * @brief This function returns a constant reference to member a - * @return Constant reference to member a - */ -const MyBitset& BitsetStruct::a() const -{ - return m_a; -} - -/*! - * @brief This function returns a reference to member a - * @return Reference to member a - */ -MyBitset& BitsetStruct::a() -{ - return m_a; -} - - - - -StructStruct::StructStruct() -{ - // Just to register all known types - registerBasicTypes(); -} - -StructStruct::~StructStruct() -{ -} - -StructStruct::StructStruct( - const StructStruct& x) -{ - m_a = x.m_a; - m_b = x.m_b; -} - -StructStruct::StructStruct( - StructStruct&& x) noexcept -{ - m_a = x.m_a; - m_b = x.m_b; -} - -StructStruct& StructStruct::operator =( - const StructStruct& x) -{ - - m_a = x.m_a; - m_b = x.m_b; - return *this; -} - -StructStruct& StructStruct::operator =( - StructStruct&& x) noexcept -{ - - m_a = x.m_a; - m_b = x.m_b; - return *this; -} - -bool StructStruct::operator ==( - const StructStruct& x) const -{ - return (m_a == x.m_a && - m_b == x.m_b); -} - -bool StructStruct::operator !=( - const StructStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member a - * @param _a New value for member a - */ -void StructStruct::a( - int32_t _a) -{ - m_a = _a; -} - -/*! - * @brief This function returns the value of member a - * @return Value of member a - */ -int32_t StructStruct::a() const -{ - return m_a; -} - -/*! - * @brief This function returns a reference to member a - * @return Reference to member a - */ -int32_t& StructStruct::a() -{ - return m_a; -} - - -/*! - * @brief This function sets a value in member b - * @param _b New value for member b - */ -void StructStruct::b( - int64_t _b) -{ - m_b = _b; -} - -/*! - * @brief This function returns the value of member b - * @return Value of member b - */ -int64_t StructStruct::b() const -{ - return m_b; -} - -/*! - * @brief This function returns a reference to member b - * @return Reference to member b - */ -int64_t& StructStruct::b() -{ - return m_b; -} - - - - -StructStructStruct::StructStructStruct() -{ - // Just to register all known types - registerBasicTypes(); -} - -StructStructStruct::~StructStructStruct() -{ -} - -StructStructStruct::StructStructStruct( - const StructStructStruct& x) -{ - m_child_struct = x.m_child_struct; - m_child_int64 = x.m_child_int64; -} - -StructStructStruct::StructStructStruct( - StructStructStruct&& x) noexcept -{ - m_child_struct = std::move(x.m_child_struct); - m_child_int64 = x.m_child_int64; -} - -StructStructStruct& StructStructStruct::operator =( - const StructStructStruct& x) -{ - - m_child_struct = x.m_child_struct; - m_child_int64 = x.m_child_int64; - return *this; -} - -StructStructStruct& StructStructStruct::operator =( - StructStructStruct&& x) noexcept -{ - - m_child_struct = std::move(x.m_child_struct); - m_child_int64 = x.m_child_int64; - return *this; -} - -bool StructStructStruct::operator ==( - const StructStructStruct& x) const -{ - return (m_child_struct == x.m_child_struct && - m_child_int64 == x.m_child_int64); -} - -bool StructStructStruct::operator !=( - const StructStructStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member child_struct - * @param _child_struct New value to be copied in member child_struct - */ -void StructStructStruct::child_struct( - const StructStruct& _child_struct) -{ - m_child_struct = _child_struct; -} - -/*! - * @brief This function moves the value in member child_struct - * @param _child_struct New value to be moved in member child_struct - */ -void StructStructStruct::child_struct( - StructStruct&& _child_struct) -{ - m_child_struct = std::move(_child_struct); -} - -/*! - * @brief This function returns a constant reference to member child_struct - * @return Constant reference to member child_struct - */ -const StructStruct& StructStructStruct::child_struct() const -{ - return m_child_struct; -} - -/*! - * @brief This function returns a reference to member child_struct - * @return Reference to member child_struct - */ -StructStruct& StructStructStruct::child_struct() -{ - return m_child_struct; -} - - -/*! - * @brief This function sets a value in member child_int64 - * @param _child_int64 New value for member child_int64 - */ -void StructStructStruct::child_int64( - int64_t _child_int64) -{ - m_child_int64 = _child_int64; -} - -/*! - * @brief This function returns the value of member child_int64 - * @return Value of member child_int64 - */ -int64_t StructStructStruct::child_int64() const -{ - return m_child_int64; -} - -/*! - * @brief This function returns a reference to member child_int64 - * @return Reference to member child_int64 - */ -int64_t& StructStructStruct::child_int64() -{ - return m_child_int64; -} - - - - -SimpleUnion::SimpleUnion() -{ - m__d = A; -} - -SimpleUnion::~SimpleUnion() -{ -} - -SimpleUnion::SimpleUnion( - const SimpleUnion& x) -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } -} - -SimpleUnion::SimpleUnion( - SimpleUnion&& x) noexcept -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } -} - -SimpleUnion& SimpleUnion::operator =( - const SimpleUnion& x) -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } - - return *this; -} - -SimpleUnion& SimpleUnion::operator =( - SimpleUnion&& x) noexcept -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } - - return *this; -} - -bool SimpleUnion::operator ==( - const SimpleUnion& x) const -{ - if (m__d != x.m__d) - { - return false; - } - - switch (m__d) - { - case A: - return (m_first == x.m_first); - break; - - - case B: - return (m_second == x.m_second); - break; - - default: - break; - } - return false; -} - -bool SimpleUnion::operator !=( - const SimpleUnion& x) const -{ - return !(*this == x); -} - -void SimpleUnion::_d( - int32_t __d) -{ - bool b = false; - - switch (m__d) - { - case A: - switch (__d) - { - case A: - b = true; - break; - default: - break; - } - break; - - - case B: - switch (__d) - { - case B: - b = true; - break; - default: - break; - } - break; - - default: - break; - } - - if (!b) - { - throw BadParamException("Discriminator doesn't correspond with the selected union member"); - } - - m__d = __d; -} - -int32_t SimpleUnion::_d() const -{ - return m__d; -} - -int32_t& SimpleUnion::_d() -{ - return m__d; -} - -void SimpleUnion::first( - int32_t _first) -{ - m_first = _first; - m__d = A; - -} - -int32_t SimpleUnion::first() const -{ - bool b = false; - - switch (m__d) - { - case A: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first; -} - -int32_t& SimpleUnion::first() -{ - bool b = false; - - switch (m__d) - { - case A: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first; -} - - -void SimpleUnion::second( - int64_t _second) -{ - m_second = _second; - m__d = B; - -} - -int64_t SimpleUnion::second() const -{ - bool b = false; - - switch (m__d) - { - case B: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second; -} - -int64_t& SimpleUnion::second() -{ - bool b = false; - - switch (m__d) - { - case B: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second; -} - - - - -UnionUnion::UnionUnion() -{ - m__d = A; -} - -UnionUnion::~UnionUnion() -{ -} - -UnionUnion::UnionUnion( - const UnionUnion& x) -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } -} - -UnionUnion::UnionUnion( - UnionUnion&& x) noexcept -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = std::move(x.m_second); - - break; - - default: - break; - } -} - -UnionUnion& UnionUnion::operator =( - const UnionUnion& x) -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } - - return *this; -} - -UnionUnion& UnionUnion::operator =( - UnionUnion&& x) noexcept -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = std::move(x.m_second); - - break; - - default: - break; - } - - return *this; -} - -bool UnionUnion::operator ==( - const UnionUnion& x) const -{ - if (m__d != x.m__d) - { - return false; - } - - switch (m__d) - { - case A: - return (m_first == x.m_first); - break; - - - case B: - return (m_second == x.m_second); - break; - - default: - break; - } - return false; -} - -bool UnionUnion::operator !=( - const UnionUnion& x) const -{ - return !(*this == x); -} - -void UnionUnion::_d( - int32_t __d) -{ - bool b = false; - - switch (m__d) - { - case A: - switch (__d) - { - case A: - b = true; - break; - default: - break; - } - break; - - - case B: - switch (__d) - { - case B: - b = true; - break; - default: - break; - } - break; - - default: - break; - } - - if (!b) - { - throw BadParamException("Discriminator doesn't correspond with the selected union member"); - } - - m__d = __d; -} - -int32_t UnionUnion::_d() const -{ - return m__d; -} - -int32_t& UnionUnion::_d() -{ - return m__d; -} - -void UnionUnion::first( - int32_t _first) -{ - m_first = _first; - m__d = A; - -} - -int32_t UnionUnion::first() const -{ - bool b = false; - - switch (m__d) - { - case A: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first; -} - -int32_t& UnionUnion::first() -{ - bool b = false; - - switch (m__d) - { - case A: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first; -} - - -void UnionUnion::second( - const SimpleUnion& _second) -{ - m_second = _second; - m__d = B; - -} - -void UnionUnion::second( - SimpleUnion&& _second) -{ - m_second = std::move(_second); - m__d = B; - -} - -const SimpleUnion& UnionUnion::second() const -{ - bool b = false; - - switch (m__d) - { - case B: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second; -} - -SimpleUnion& UnionUnion::second() -{ - bool b = false; - - switch (m__d) - { - case B: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second; -} - - - - -WCharUnion::WCharUnion() -{ - m__d = A; -} - -WCharUnion::~WCharUnion() -{ -} - -WCharUnion::WCharUnion( - const WCharUnion& x) -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } -} - -WCharUnion::WCharUnion( - WCharUnion&& x) noexcept -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } -} - -WCharUnion& WCharUnion::operator =( - const WCharUnion& x) -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } - - return *this; -} - -WCharUnion& WCharUnion::operator =( - WCharUnion&& x) noexcept -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } - - return *this; -} - -bool WCharUnion::operator ==( - const WCharUnion& x) const -{ - if (m__d != x.m__d) - { - return false; - } - - switch (m__d) - { - case A: - return (m_first == x.m_first); - break; - - - case B: - return (m_second == x.m_second); - break; - - default: - break; - } - return false; -} - -bool WCharUnion::operator !=( - const WCharUnion& x) const -{ - return !(*this == x); -} - -void WCharUnion::_d( - wchar_t __d) -{ - bool b = false; - - switch (m__d) - { - case A: - switch (__d) - { - case A: - b = true; - break; - default: - break; - } - break; - - - case B: - switch (__d) - { - case B: - b = true; - break; - default: - break; - } - break; - - default: - break; - } - - if (!b) - { - throw BadParamException("Discriminator doesn't correspond with the selected union member"); - } - - m__d = __d; -} - -wchar_t WCharUnion::_d() const -{ - return m__d; -} - -wchar_t& WCharUnion::_d() -{ - return m__d; -} - -void WCharUnion::first( - int32_t _first) -{ - m_first = _first; - m__d = A; - -} - -int32_t WCharUnion::first() const -{ - bool b = false; - - switch (m__d) - { - case A: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first; -} - -int32_t& WCharUnion::first() -{ - bool b = false; - - switch (m__d) - { - case A: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first; -} - - -void WCharUnion::second( - int64_t _second) -{ - m_second = _second; - m__d = B; - -} - -int64_t WCharUnion::second() const -{ - bool b = false; - - switch (m__d) - { - case B: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second; -} - -int64_t& WCharUnion::second() -{ - bool b = false; - - switch (m__d) - { - case B: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second; -} - - - - -SimpleUnionStruct::SimpleUnionStruct() -{ - // Just to register all known types - registerBasicTypes(); -} - -SimpleUnionStruct::~SimpleUnionStruct() -{ -} - -SimpleUnionStruct::SimpleUnionStruct( - const SimpleUnionStruct& x) -{ - m_my_union = x.m_my_union; -} - -SimpleUnionStruct::SimpleUnionStruct( - SimpleUnionStruct&& x) noexcept -{ - m_my_union = std::move(x.m_my_union); -} - -SimpleUnionStruct& SimpleUnionStruct::operator =( - const SimpleUnionStruct& x) -{ - - m_my_union = x.m_my_union; - return *this; -} - -SimpleUnionStruct& SimpleUnionStruct::operator =( - SimpleUnionStruct&& x) noexcept -{ - - m_my_union = std::move(x.m_my_union); - return *this; -} - -bool SimpleUnionStruct::operator ==( - const SimpleUnionStruct& x) const -{ - return (m_my_union == x.m_my_union); -} - -bool SimpleUnionStruct::operator !=( - const SimpleUnionStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ -void SimpleUnionStruct::my_union( - const SimpleUnion& _my_union) -{ - m_my_union = _my_union; -} - -/*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ -void SimpleUnionStruct::my_union( - SimpleUnion&& _my_union) -{ - m_my_union = std::move(_my_union); -} - -/*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ -const SimpleUnion& SimpleUnionStruct::my_union() const -{ - return m_my_union; -} - -/*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ -SimpleUnion& SimpleUnionStruct::my_union() -{ - return m_my_union; -} - - - - -UnionUnionUnionStruct::UnionUnionUnionStruct() -{ - // Just to register all known types - registerBasicTypes(); -} - -UnionUnionUnionStruct::~UnionUnionUnionStruct() -{ -} - -UnionUnionUnionStruct::UnionUnionUnionStruct( - const UnionUnionUnionStruct& x) -{ - m_my_union = x.m_my_union; -} - -UnionUnionUnionStruct::UnionUnionUnionStruct( - UnionUnionUnionStruct&& x) noexcept -{ - m_my_union = std::move(x.m_my_union); -} - -UnionUnionUnionStruct& UnionUnionUnionStruct::operator =( - const UnionUnionUnionStruct& x) -{ - - m_my_union = x.m_my_union; - return *this; -} - -UnionUnionUnionStruct& UnionUnionUnionStruct::operator =( - UnionUnionUnionStruct&& x) noexcept -{ - - m_my_union = std::move(x.m_my_union); - return *this; -} - -bool UnionUnionUnionStruct::operator ==( - const UnionUnionUnionStruct& x) const -{ - return (m_my_union == x.m_my_union); -} - -bool UnionUnionUnionStruct::operator !=( - const UnionUnionUnionStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ -void UnionUnionUnionStruct::my_union( - const UnionUnion& _my_union) -{ - m_my_union = _my_union; -} - -/*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ -void UnionUnionUnionStruct::my_union( - UnionUnion&& _my_union) -{ - m_my_union = std::move(_my_union); -} - -/*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ -const UnionUnion& UnionUnionUnionStruct::my_union() const -{ - return m_my_union; -} - -/*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ -UnionUnion& UnionUnionUnionStruct::my_union() -{ - return m_my_union; -} - - - - -WCharUnionStruct::WCharUnionStruct() -{ - // Just to register all known types - registerBasicTypes(); -} - -WCharUnionStruct::~WCharUnionStruct() -{ -} - -WCharUnionStruct::WCharUnionStruct( - const WCharUnionStruct& x) -{ - m_my_union = x.m_my_union; -} - -WCharUnionStruct::WCharUnionStruct( - WCharUnionStruct&& x) noexcept -{ - m_my_union = std::move(x.m_my_union); -} - -WCharUnionStruct& WCharUnionStruct::operator =( - const WCharUnionStruct& x) -{ - - m_my_union = x.m_my_union; - return *this; -} - -WCharUnionStruct& WCharUnionStruct::operator =( - WCharUnionStruct&& x) noexcept -{ - - m_my_union = std::move(x.m_my_union); - return *this; -} - -bool WCharUnionStruct::operator ==( - const WCharUnionStruct& x) const -{ - return (m_my_union == x.m_my_union); -} - -bool WCharUnionStruct::operator !=( - const WCharUnionStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ -void WCharUnionStruct::my_union( - const WCharUnion& _my_union) -{ - m_my_union = _my_union; -} - -/*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ -void WCharUnionStruct::my_union( - WCharUnion&& _my_union) -{ - m_my_union = std::move(_my_union); -} - -/*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ -const WCharUnion& WCharUnionStruct::my_union() const -{ - return m_my_union; -} - -/*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ -WCharUnion& WCharUnionStruct::my_union() -{ - return m_my_union; -} - - -// Include auxiliary functions like for serializing/deserializing. -#include "BasicCdrAux.ipp" - -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/test/unittest/dynamic_types/idl/Basic.h b/test/unittest/dynamic_types/idl/Basic.h deleted file mode 100644 index 3f82c93abc2..00000000000 --- a/test/unittest/dynamic_types/idl/Basic.h +++ /dev/null @@ -1,3511 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file Basic.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#include -#include "Basicv1.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#ifndef _FAST_DDS_GENERATED_BASIC_H_ -#define _FAST_DDS_GENERATED_BASIC_H_ - -#include -#include -#include -#include -#include -#include - -#include -#include -#include - - - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define eProsima_user_DllExport -#endif // _WIN32 - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(BASIC_SOURCE) -#define BASIC_DllAPI __declspec( dllexport ) -#else -#define BASIC_DllAPI __declspec( dllimport ) -#endif // BASIC_SOURCE -#else -#define BASIC_DllAPI -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define BASIC_DllAPI -#endif // _WIN32 - -namespace eprosima { -namespace fastcdr { -class Cdr; -class CdrSizeCalculator; -} // namespace fastcdr -} // namespace eprosima - - - -/*! - * @brief This class represents the enumeration MyEnum defined by the user in the IDL file. - * @ingroup Basic - */ -enum MyEnum : uint32_t -{ - A, - B, - C -}; -typedef MyEnum MyAliasEnum; - -typedef MyAliasEnum MyAliasAliasEnum; - - - -/*! - * @brief This class represents the structure EnumStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class EnumStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport EnumStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~EnumStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object EnumStruct that will be copied. - */ - eProsima_user_DllExport EnumStruct( - const EnumStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object EnumStruct that will be copied. - */ - eProsima_user_DllExport EnumStruct( - EnumStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object EnumStruct that will be copied. - */ - eProsima_user_DllExport EnumStruct& operator =( - const EnumStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object EnumStruct that will be copied. - */ - eProsima_user_DllExport EnumStruct& operator =( - EnumStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x EnumStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const EnumStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x EnumStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const EnumStruct& x) const; - - /*! - * @brief This function sets a value in member my_enum - * @param _my_enum New value for member my_enum - */ - eProsima_user_DllExport void my_enum( - MyEnum _my_enum); - - /*! - * @brief This function returns the value of member my_enum - * @return Value of member my_enum - */ - eProsima_user_DllExport MyEnum my_enum() const; - - /*! - * @brief This function returns a reference to member my_enum - * @return Reference to member my_enum - */ - eProsima_user_DllExport MyEnum& my_enum(); - -private: - - MyEnum m_my_enum{::A}; - -}; - - -/*! - * @brief This class represents the structure AliasStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class AliasStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport AliasStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~AliasStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object AliasStruct that will be copied. - */ - eProsima_user_DllExport AliasStruct( - const AliasStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object AliasStruct that will be copied. - */ - eProsima_user_DllExport AliasStruct( - AliasStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object AliasStruct that will be copied. - */ - eProsima_user_DllExport AliasStruct& operator =( - const AliasStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object AliasStruct that will be copied. - */ - eProsima_user_DllExport AliasStruct& operator =( - AliasStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x AliasStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const AliasStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x AliasStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const AliasStruct& x) const; - - /*! - * @brief This function sets a value in member my_alias - * @param _my_alias New value for member my_alias - */ - eProsima_user_DllExport void my_alias( - MyAliasEnum _my_alias); - - /*! - * @brief This function returns the value of member my_alias - * @return Value of member my_alias - */ - eProsima_user_DllExport MyAliasEnum my_alias() const; - - /*! - * @brief This function returns a reference to member my_alias - * @return Reference to member my_alias - */ - eProsima_user_DllExport MyAliasEnum& my_alias(); - -private: - - MyAliasEnum m_my_alias{::A}; - -}; - - -/*! - * @brief This class represents the structure AliasAliasStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class AliasAliasStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport AliasAliasStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~AliasAliasStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object AliasAliasStruct that will be copied. - */ - eProsima_user_DllExport AliasAliasStruct( - const AliasAliasStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object AliasAliasStruct that will be copied. - */ - eProsima_user_DllExport AliasAliasStruct( - AliasAliasStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object AliasAliasStruct that will be copied. - */ - eProsima_user_DllExport AliasAliasStruct& operator =( - const AliasAliasStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object AliasAliasStruct that will be copied. - */ - eProsima_user_DllExport AliasAliasStruct& operator =( - AliasAliasStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x AliasAliasStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const AliasAliasStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x AliasAliasStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const AliasAliasStruct& x) const; - - /*! - * @brief This function sets a value in member my_alias_alias - * @param _my_alias_alias New value for member my_alias_alias - */ - eProsima_user_DllExport void my_alias_alias( - MyAliasAliasEnum _my_alias_alias); - - /*! - * @brief This function returns the value of member my_alias_alias - * @return Value of member my_alias_alias - */ - eProsima_user_DllExport MyAliasAliasEnum my_alias_alias() const; - - /*! - * @brief This function returns a reference to member my_alias_alias - * @return Reference to member my_alias_alias - */ - eProsima_user_DllExport MyAliasAliasEnum& my_alias_alias(); - -private: - - MyAliasAliasEnum m_my_alias_alias{::A}; - -}; - - -/*! - * @brief This class represents the structure BoolStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class BoolStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport BoolStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~BoolStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object BoolStruct that will be copied. - */ - eProsima_user_DllExport BoolStruct( - const BoolStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object BoolStruct that will be copied. - */ - eProsima_user_DllExport BoolStruct( - BoolStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object BoolStruct that will be copied. - */ - eProsima_user_DllExport BoolStruct& operator =( - const BoolStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object BoolStruct that will be copied. - */ - eProsima_user_DllExport BoolStruct& operator =( - BoolStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x BoolStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const BoolStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x BoolStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const BoolStruct& x) const; - - /*! - * @brief This function sets a value in member my_bool - * @param _my_bool New value for member my_bool - */ - eProsima_user_DllExport void my_bool( - bool _my_bool); - - /*! - * @brief This function returns the value of member my_bool - * @return Value of member my_bool - */ - eProsima_user_DllExport bool my_bool() const; - - /*! - * @brief This function returns a reference to member my_bool - * @return Reference to member my_bool - */ - eProsima_user_DllExport bool& my_bool(); - -private: - - bool m_my_bool{false}; - -}; - - -/*! - * @brief This class represents the structure OctetStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class OctetStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport OctetStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~OctetStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object OctetStruct that will be copied. - */ - eProsima_user_DllExport OctetStruct( - const OctetStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object OctetStruct that will be copied. - */ - eProsima_user_DllExport OctetStruct( - OctetStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object OctetStruct that will be copied. - */ - eProsima_user_DllExport OctetStruct& operator =( - const OctetStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object OctetStruct that will be copied. - */ - eProsima_user_DllExport OctetStruct& operator =( - OctetStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x OctetStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const OctetStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x OctetStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const OctetStruct& x) const; - - /*! - * @brief This function sets a value in member my_octet - * @param _my_octet New value for member my_octet - */ - eProsima_user_DllExport void my_octet( - uint8_t _my_octet); - - /*! - * @brief This function returns the value of member my_octet - * @return Value of member my_octet - */ - eProsima_user_DllExport uint8_t my_octet() const; - - /*! - * @brief This function returns a reference to member my_octet - * @return Reference to member my_octet - */ - eProsima_user_DllExport uint8_t& my_octet(); - -private: - - uint8_t m_my_octet{0}; - -}; - - -/*! - * @brief This class represents the structure ShortStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class ShortStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport ShortStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~ShortStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object ShortStruct that will be copied. - */ - eProsima_user_DllExport ShortStruct( - const ShortStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object ShortStruct that will be copied. - */ - eProsima_user_DllExport ShortStruct( - ShortStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object ShortStruct that will be copied. - */ - eProsima_user_DllExport ShortStruct& operator =( - const ShortStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object ShortStruct that will be copied. - */ - eProsima_user_DllExport ShortStruct& operator =( - ShortStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x ShortStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const ShortStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x ShortStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const ShortStruct& x) const; - - /*! - * @brief This function sets a value in member my_int16 - * @param _my_int16 New value for member my_int16 - */ - eProsima_user_DllExport void my_int16( - int16_t _my_int16); - - /*! - * @brief This function returns the value of member my_int16 - * @return Value of member my_int16 - */ - eProsima_user_DllExport int16_t my_int16() const; - - /*! - * @brief This function returns a reference to member my_int16 - * @return Reference to member my_int16 - */ - eProsima_user_DllExport int16_t& my_int16(); - -private: - - int16_t m_my_int16{0}; - -}; - - -/*! - * @brief This class represents the structure LongStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class LongStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport LongStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~LongStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object LongStruct that will be copied. - */ - eProsima_user_DllExport LongStruct( - const LongStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object LongStruct that will be copied. - */ - eProsima_user_DllExport LongStruct( - LongStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object LongStruct that will be copied. - */ - eProsima_user_DllExport LongStruct& operator =( - const LongStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object LongStruct that will be copied. - */ - eProsima_user_DllExport LongStruct& operator =( - LongStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x LongStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const LongStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x LongStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const LongStruct& x) const; - - /*! - * @brief This function sets a value in member my_int32 - * @param _my_int32 New value for member my_int32 - */ - eProsima_user_DllExport void my_int32( - int32_t _my_int32); - - /*! - * @brief This function returns the value of member my_int32 - * @return Value of member my_int32 - */ - eProsima_user_DllExport int32_t my_int32() const; - - /*! - * @brief This function returns a reference to member my_int32 - * @return Reference to member my_int32 - */ - eProsima_user_DllExport int32_t& my_int32(); - -private: - - int32_t m_my_int32{0}; - -}; - - -/*! - * @brief This class represents the structure LongLongStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class LongLongStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport LongLongStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~LongLongStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object LongLongStruct that will be copied. - */ - eProsima_user_DllExport LongLongStruct( - const LongLongStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object LongLongStruct that will be copied. - */ - eProsima_user_DllExport LongLongStruct( - LongLongStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object LongLongStruct that will be copied. - */ - eProsima_user_DllExport LongLongStruct& operator =( - const LongLongStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object LongLongStruct that will be copied. - */ - eProsima_user_DllExport LongLongStruct& operator =( - LongLongStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x LongLongStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const LongLongStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x LongLongStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const LongLongStruct& x) const; - - /*! - * @brief This function sets a value in member my_int64 - * @param _my_int64 New value for member my_int64 - */ - eProsima_user_DllExport void my_int64( - int64_t _my_int64); - - /*! - * @brief This function returns the value of member my_int64 - * @return Value of member my_int64 - */ - eProsima_user_DllExport int64_t my_int64() const; - - /*! - * @brief This function returns a reference to member my_int64 - * @return Reference to member my_int64 - */ - eProsima_user_DllExport int64_t& my_int64(); - -private: - - int64_t m_my_int64{0}; - -}; - - -/*! - * @brief This class represents the structure UShortStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class UShortStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport UShortStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~UShortStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object UShortStruct that will be copied. - */ - eProsima_user_DllExport UShortStruct( - const UShortStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object UShortStruct that will be copied. - */ - eProsima_user_DllExport UShortStruct( - UShortStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object UShortStruct that will be copied. - */ - eProsima_user_DllExport UShortStruct& operator =( - const UShortStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object UShortStruct that will be copied. - */ - eProsima_user_DllExport UShortStruct& operator =( - UShortStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x UShortStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const UShortStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x UShortStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const UShortStruct& x) const; - - /*! - * @brief This function sets a value in member my_uint16 - * @param _my_uint16 New value for member my_uint16 - */ - eProsima_user_DllExport void my_uint16( - uint16_t _my_uint16); - - /*! - * @brief This function returns the value of member my_uint16 - * @return Value of member my_uint16 - */ - eProsima_user_DllExport uint16_t my_uint16() const; - - /*! - * @brief This function returns a reference to member my_uint16 - * @return Reference to member my_uint16 - */ - eProsima_user_DllExport uint16_t& my_uint16(); - -private: - - uint16_t m_my_uint16{0}; - -}; - - -/*! - * @brief This class represents the structure ULongStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class ULongStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport ULongStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~ULongStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object ULongStruct that will be copied. - */ - eProsima_user_DllExport ULongStruct( - const ULongStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object ULongStruct that will be copied. - */ - eProsima_user_DllExport ULongStruct( - ULongStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object ULongStruct that will be copied. - */ - eProsima_user_DllExport ULongStruct& operator =( - const ULongStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object ULongStruct that will be copied. - */ - eProsima_user_DllExport ULongStruct& operator =( - ULongStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x ULongStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const ULongStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x ULongStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const ULongStruct& x) const; - - /*! - * @brief This function sets a value in member my_uint32 - * @param _my_uint32 New value for member my_uint32 - */ - eProsima_user_DllExport void my_uint32( - uint32_t _my_uint32); - - /*! - * @brief This function returns the value of member my_uint32 - * @return Value of member my_uint32 - */ - eProsima_user_DllExport uint32_t my_uint32() const; - - /*! - * @brief This function returns a reference to member my_uint32 - * @return Reference to member my_uint32 - */ - eProsima_user_DllExport uint32_t& my_uint32(); - -private: - - uint32_t m_my_uint32{0}; - -}; - - -/*! - * @brief This class represents the structure ULongLongStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class ULongLongStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport ULongLongStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~ULongLongStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object ULongLongStruct that will be copied. - */ - eProsima_user_DllExport ULongLongStruct( - const ULongLongStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object ULongLongStruct that will be copied. - */ - eProsima_user_DllExport ULongLongStruct( - ULongLongStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object ULongLongStruct that will be copied. - */ - eProsima_user_DllExport ULongLongStruct& operator =( - const ULongLongStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object ULongLongStruct that will be copied. - */ - eProsima_user_DllExport ULongLongStruct& operator =( - ULongLongStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x ULongLongStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const ULongLongStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x ULongLongStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const ULongLongStruct& x) const; - - /*! - * @brief This function sets a value in member my_uint64 - * @param _my_uint64 New value for member my_uint64 - */ - eProsima_user_DllExport void my_uint64( - uint64_t _my_uint64); - - /*! - * @brief This function returns the value of member my_uint64 - * @return Value of member my_uint64 - */ - eProsima_user_DllExport uint64_t my_uint64() const; - - /*! - * @brief This function returns a reference to member my_uint64 - * @return Reference to member my_uint64 - */ - eProsima_user_DllExport uint64_t& my_uint64(); - -private: - - uint64_t m_my_uint64{0}; - -}; - - -/*! - * @brief This class represents the structure FloatStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class FloatStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport FloatStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~FloatStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object FloatStruct that will be copied. - */ - eProsima_user_DllExport FloatStruct( - const FloatStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object FloatStruct that will be copied. - */ - eProsima_user_DllExport FloatStruct( - FloatStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object FloatStruct that will be copied. - */ - eProsima_user_DllExport FloatStruct& operator =( - const FloatStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object FloatStruct that will be copied. - */ - eProsima_user_DllExport FloatStruct& operator =( - FloatStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x FloatStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const FloatStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x FloatStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const FloatStruct& x) const; - - /*! - * @brief This function sets a value in member my_float32 - * @param _my_float32 New value for member my_float32 - */ - eProsima_user_DllExport void my_float32( - float _my_float32); - - /*! - * @brief This function returns the value of member my_float32 - * @return Value of member my_float32 - */ - eProsima_user_DllExport float my_float32() const; - - /*! - * @brief This function returns a reference to member my_float32 - * @return Reference to member my_float32 - */ - eProsima_user_DllExport float& my_float32(); - -private: - - float m_my_float32{0.0}; - -}; - - -/*! - * @brief This class represents the structure DoubleStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class DoubleStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport DoubleStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~DoubleStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object DoubleStruct that will be copied. - */ - eProsima_user_DllExport DoubleStruct( - const DoubleStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object DoubleStruct that will be copied. - */ - eProsima_user_DllExport DoubleStruct( - DoubleStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object DoubleStruct that will be copied. - */ - eProsima_user_DllExport DoubleStruct& operator =( - const DoubleStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object DoubleStruct that will be copied. - */ - eProsima_user_DllExport DoubleStruct& operator =( - DoubleStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x DoubleStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const DoubleStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x DoubleStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const DoubleStruct& x) const; - - /*! - * @brief This function sets a value in member my_float64 - * @param _my_float64 New value for member my_float64 - */ - eProsima_user_DllExport void my_float64( - double _my_float64); - - /*! - * @brief This function returns the value of member my_float64 - * @return Value of member my_float64 - */ - eProsima_user_DllExport double my_float64() const; - - /*! - * @brief This function returns a reference to member my_float64 - * @return Reference to member my_float64 - */ - eProsima_user_DllExport double& my_float64(); - -private: - - double m_my_float64{0.0}; - -}; - - -/*! - * @brief This class represents the structure LongDoubleStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class LongDoubleStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport LongDoubleStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~LongDoubleStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object LongDoubleStruct that will be copied. - */ - eProsima_user_DllExport LongDoubleStruct( - const LongDoubleStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object LongDoubleStruct that will be copied. - */ - eProsima_user_DllExport LongDoubleStruct( - LongDoubleStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object LongDoubleStruct that will be copied. - */ - eProsima_user_DllExport LongDoubleStruct& operator =( - const LongDoubleStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object LongDoubleStruct that will be copied. - */ - eProsima_user_DllExport LongDoubleStruct& operator =( - LongDoubleStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x LongDoubleStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const LongDoubleStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x LongDoubleStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const LongDoubleStruct& x) const; - - /*! - * @brief This function sets a value in member my_float128 - * @param _my_float128 New value for member my_float128 - */ - eProsima_user_DllExport void my_float128( - long double _my_float128); - - /*! - * @brief This function returns the value of member my_float128 - * @return Value of member my_float128 - */ - eProsima_user_DllExport long double my_float128() const; - - /*! - * @brief This function returns a reference to member my_float128 - * @return Reference to member my_float128 - */ - eProsima_user_DllExport long double& my_float128(); - -private: - - long double m_my_float128{0.0}; - -}; - - -/*! - * @brief This class represents the structure CharStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class CharStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport CharStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~CharStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object CharStruct that will be copied. - */ - eProsima_user_DllExport CharStruct( - const CharStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object CharStruct that will be copied. - */ - eProsima_user_DllExport CharStruct( - CharStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object CharStruct that will be copied. - */ - eProsima_user_DllExport CharStruct& operator =( - const CharStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object CharStruct that will be copied. - */ - eProsima_user_DllExport CharStruct& operator =( - CharStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x CharStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const CharStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x CharStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const CharStruct& x) const; - - /*! - * @brief This function sets a value in member my_char - * @param _my_char New value for member my_char - */ - eProsima_user_DllExport void my_char( - char _my_char); - - /*! - * @brief This function returns the value of member my_char - * @return Value of member my_char - */ - eProsima_user_DllExport char my_char() const; - - /*! - * @brief This function returns a reference to member my_char - * @return Reference to member my_char - */ - eProsima_user_DllExport char& my_char(); - -private: - - char m_my_char{0}; - -}; - - -/*! - * @brief This class represents the structure WCharStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class WCharStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport WCharStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~WCharStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object WCharStruct that will be copied. - */ - eProsima_user_DllExport WCharStruct( - const WCharStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object WCharStruct that will be copied. - */ - eProsima_user_DllExport WCharStruct( - WCharStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object WCharStruct that will be copied. - */ - eProsima_user_DllExport WCharStruct& operator =( - const WCharStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object WCharStruct that will be copied. - */ - eProsima_user_DllExport WCharStruct& operator =( - WCharStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x WCharStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const WCharStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x WCharStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const WCharStruct& x) const; - - /*! - * @brief This function sets a value in member my_wchar - * @param _my_wchar New value for member my_wchar - */ - eProsima_user_DllExport void my_wchar( - wchar_t _my_wchar); - - /*! - * @brief This function returns the value of member my_wchar - * @return Value of member my_wchar - */ - eProsima_user_DllExport wchar_t my_wchar() const; - - /*! - * @brief This function returns a reference to member my_wchar - * @return Reference to member my_wchar - */ - eProsima_user_DllExport wchar_t& my_wchar(); - -private: - - wchar_t m_my_wchar{0}; - -}; - - -/*! - * @brief This class represents the structure StringStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class StringStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport StringStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~StringStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object StringStruct that will be copied. - */ - eProsima_user_DllExport StringStruct( - const StringStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object StringStruct that will be copied. - */ - eProsima_user_DllExport StringStruct( - StringStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object StringStruct that will be copied. - */ - eProsima_user_DllExport StringStruct& operator =( - const StringStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object StringStruct that will be copied. - */ - eProsima_user_DllExport StringStruct& operator =( - StringStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x StringStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const StringStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x StringStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const StringStruct& x) const; - - /*! - * @brief This function copies the value in member my_string - * @param _my_string New value to be copied in member my_string - */ - eProsima_user_DllExport void my_string( - const std::string& _my_string); - - /*! - * @brief This function moves the value in member my_string - * @param _my_string New value to be moved in member my_string - */ - eProsima_user_DllExport void my_string( - std::string&& _my_string); - - /*! - * @brief This function returns a constant reference to member my_string - * @return Constant reference to member my_string - */ - eProsima_user_DllExport const std::string& my_string() const; - - /*! - * @brief This function returns a reference to member my_string - * @return Reference to member my_string - */ - eProsima_user_DllExport std::string& my_string(); - -private: - - std::string m_my_string; - -}; - - -/*! - * @brief This class represents the structure WStringStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class WStringStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport WStringStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~WStringStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object WStringStruct that will be copied. - */ - eProsima_user_DllExport WStringStruct( - const WStringStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object WStringStruct that will be copied. - */ - eProsima_user_DllExport WStringStruct( - WStringStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object WStringStruct that will be copied. - */ - eProsima_user_DllExport WStringStruct& operator =( - const WStringStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object WStringStruct that will be copied. - */ - eProsima_user_DllExport WStringStruct& operator =( - WStringStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x WStringStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const WStringStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x WStringStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const WStringStruct& x) const; - - /*! - * @brief This function copies the value in member my_wstring - * @param _my_wstring New value to be copied in member my_wstring - */ - eProsima_user_DllExport void my_wstring( - const std::wstring& _my_wstring); - - /*! - * @brief This function moves the value in member my_wstring - * @param _my_wstring New value to be moved in member my_wstring - */ - eProsima_user_DllExport void my_wstring( - std::wstring&& _my_wstring); - - /*! - * @brief This function returns a constant reference to member my_wstring - * @return Constant reference to member my_wstring - */ - eProsima_user_DllExport const std::wstring& my_wstring() const; - - /*! - * @brief This function returns a reference to member my_wstring - * @return Reference to member my_wstring - */ - eProsima_user_DllExport std::wstring& my_wstring(); - -private: - - std::wstring m_my_wstring; - -}; - - -/*! - * @brief This class represents the structure LargeStringStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class LargeStringStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport LargeStringStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~LargeStringStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object LargeStringStruct that will be copied. - */ - eProsima_user_DllExport LargeStringStruct( - const LargeStringStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object LargeStringStruct that will be copied. - */ - eProsima_user_DllExport LargeStringStruct( - LargeStringStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object LargeStringStruct that will be copied. - */ - eProsima_user_DllExport LargeStringStruct& operator =( - const LargeStringStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object LargeStringStruct that will be copied. - */ - eProsima_user_DllExport LargeStringStruct& operator =( - LargeStringStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x LargeStringStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const LargeStringStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x LargeStringStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const LargeStringStruct& x) const; - - /*! - * @brief This function copies the value in member my_large_string - * @param _my_large_string New value to be copied in member my_large_string - */ - eProsima_user_DllExport void my_large_string( - const eprosima::fastcdr::fixed_string<41925>& _my_large_string); - - /*! - * @brief This function moves the value in member my_large_string - * @param _my_large_string New value to be moved in member my_large_string - */ - eProsima_user_DllExport void my_large_string( - eprosima::fastcdr::fixed_string<41925>&& _my_large_string); - - /*! - * @brief This function returns a constant reference to member my_large_string - * @return Constant reference to member my_large_string - */ - eProsima_user_DllExport const eprosima::fastcdr::fixed_string<41925>& my_large_string() const; - - /*! - * @brief This function returns a reference to member my_large_string - * @return Reference to member my_large_string - */ - eProsima_user_DllExport eprosima::fastcdr::fixed_string<41925>& my_large_string(); - -private: - - eprosima::fastcdr::fixed_string<41925> m_my_large_string; - -}; - - -/*! - * @brief This class represents the structure LargeWStringStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class LargeWStringStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport LargeWStringStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~LargeWStringStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object LargeWStringStruct that will be copied. - */ - eProsima_user_DllExport LargeWStringStruct( - const LargeWStringStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object LargeWStringStruct that will be copied. - */ - eProsima_user_DllExport LargeWStringStruct( - LargeWStringStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object LargeWStringStruct that will be copied. - */ - eProsima_user_DllExport LargeWStringStruct& operator =( - const LargeWStringStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object LargeWStringStruct that will be copied. - */ - eProsima_user_DllExport LargeWStringStruct& operator =( - LargeWStringStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x LargeWStringStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const LargeWStringStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x LargeWStringStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const LargeWStringStruct& x) const; - - /*! - * @brief This function copies the value in member my_large_wstring - * @param _my_large_wstring New value to be copied in member my_large_wstring - */ - eProsima_user_DllExport void my_large_wstring( - const std::wstring& _my_large_wstring); - - /*! - * @brief This function moves the value in member my_large_wstring - * @param _my_large_wstring New value to be moved in member my_large_wstring - */ - eProsima_user_DllExport void my_large_wstring( - std::wstring&& _my_large_wstring); - - /*! - * @brief This function returns a constant reference to member my_large_wstring - * @return Constant reference to member my_large_wstring - */ - eProsima_user_DllExport const std::wstring& my_large_wstring() const; - - /*! - * @brief This function returns a reference to member my_large_wstring - * @return Reference to member my_large_wstring - */ - eProsima_user_DllExport std::wstring& my_large_wstring(); - -private: - - std::wstring m_my_large_wstring; - -}; - - -/*! - * @brief This class represents the structure ArraytStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class ArraytStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport ArraytStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~ArraytStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object ArraytStruct that will be copied. - */ - eProsima_user_DllExport ArraytStruct( - const ArraytStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object ArraytStruct that will be copied. - */ - eProsima_user_DllExport ArraytStruct( - ArraytStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object ArraytStruct that will be copied. - */ - eProsima_user_DllExport ArraytStruct& operator =( - const ArraytStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object ArraytStruct that will be copied. - */ - eProsima_user_DllExport ArraytStruct& operator =( - ArraytStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x ArraytStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const ArraytStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x ArraytStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const ArraytStruct& x) const; - - /*! - * @brief This function copies the value in member my_array - * @param _my_array New value to be copied in member my_array - */ - eProsima_user_DllExport void my_array( - const std::array, 2>, 2>& _my_array); - - /*! - * @brief This function moves the value in member my_array - * @param _my_array New value to be moved in member my_array - */ - eProsima_user_DllExport void my_array( - std::array, 2>, 2>&& _my_array); - - /*! - * @brief This function returns a constant reference to member my_array - * @return Constant reference to member my_array - */ - eProsima_user_DllExport const std::array, 2>, 2>& my_array() const; - - /*! - * @brief This function returns a reference to member my_array - * @return Reference to member my_array - */ - eProsima_user_DllExport std::array, 2>, 2>& my_array(); - -private: - - std::array, 2>, 2> m_my_array{ {{ {{0}} }} }; - -}; -typedef std::array, 2> MyArray; - - - -/*! - * @brief This class represents the structure ArrayArrayStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class ArrayArrayStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport ArrayArrayStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~ArrayArrayStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object ArrayArrayStruct that will be copied. - */ - eProsima_user_DllExport ArrayArrayStruct( - const ArrayArrayStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object ArrayArrayStruct that will be copied. - */ - eProsima_user_DllExport ArrayArrayStruct( - ArrayArrayStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object ArrayArrayStruct that will be copied. - */ - eProsima_user_DllExport ArrayArrayStruct& operator =( - const ArrayArrayStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object ArrayArrayStruct that will be copied. - */ - eProsima_user_DllExport ArrayArrayStruct& operator =( - ArrayArrayStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x ArrayArrayStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const ArrayArrayStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x ArrayArrayStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const ArrayArrayStruct& x) const; - - /*! - * @brief This function copies the value in member my_array_array - * @param _my_array_array New value to be copied in member my_array_array - */ - eProsima_user_DllExport void my_array_array( - const std::array, 2>& _my_array_array); - - /*! - * @brief This function moves the value in member my_array_array - * @param _my_array_array New value to be moved in member my_array_array - */ - eProsima_user_DllExport void my_array_array( - std::array, 2>&& _my_array_array); - - /*! - * @brief This function returns a constant reference to member my_array_array - * @return Constant reference to member my_array_array - */ - eProsima_user_DllExport const std::array, 2>& my_array_array() const; - - /*! - * @brief This function returns a reference to member my_array_array - * @return Reference to member my_array_array - */ - eProsima_user_DllExport std::array, 2>& my_array_array(); - -private: - - std::array, 2> m_my_array_array{ {{ {{ {{0}} }} }} }; - -}; - - - - -/*! - * @brief This class represents the structure SequenceStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class SequenceStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SequenceStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SequenceStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SequenceStruct that will be copied. - */ - eProsima_user_DllExport SequenceStruct( - const SequenceStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SequenceStruct that will be copied. - */ - eProsima_user_DllExport SequenceStruct( - SequenceStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SequenceStruct that will be copied. - */ - eProsima_user_DllExport SequenceStruct& operator =( - const SequenceStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SequenceStruct that will be copied. - */ - eProsima_user_DllExport SequenceStruct& operator =( - SequenceStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SequenceStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SequenceStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x SequenceStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SequenceStruct& x) const; - - /*! - * @brief This function copies the value in member my_sequence - * @param _my_sequence New value to be copied in member my_sequence - */ - eProsima_user_DllExport void my_sequence( - const std::vector& _my_sequence); - - /*! - * @brief This function moves the value in member my_sequence - * @param _my_sequence New value to be moved in member my_sequence - */ - eProsima_user_DllExport void my_sequence( - std::vector&& _my_sequence); - - /*! - * @brief This function returns a constant reference to member my_sequence - * @return Constant reference to member my_sequence - */ - eProsima_user_DllExport const std::vector& my_sequence() const; - - /*! - * @brief This function returns a reference to member my_sequence - * @return Reference to member my_sequence - */ - eProsima_user_DllExport std::vector& my_sequence(); - -private: - - std::vector m_my_sequence; - -}; - - - - - - -/*! - * @brief This class represents the structure SequenceSequenceStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class SequenceSequenceStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SequenceSequenceStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SequenceSequenceStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SequenceSequenceStruct that will be copied. - */ - eProsima_user_DllExport SequenceSequenceStruct( - const SequenceSequenceStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SequenceSequenceStruct that will be copied. - */ - eProsima_user_DllExport SequenceSequenceStruct( - SequenceSequenceStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SequenceSequenceStruct that will be copied. - */ - eProsima_user_DllExport SequenceSequenceStruct& operator =( - const SequenceSequenceStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SequenceSequenceStruct that will be copied. - */ - eProsima_user_DllExport SequenceSequenceStruct& operator =( - SequenceSequenceStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SequenceSequenceStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SequenceSequenceStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x SequenceSequenceStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SequenceSequenceStruct& x) const; - - /*! - * @brief This function copies the value in member my_sequence_sequence - * @param _my_sequence_sequence New value to be copied in member my_sequence_sequence - */ - eProsima_user_DllExport void my_sequence_sequence( - const std::vector>& _my_sequence_sequence); - - /*! - * @brief This function moves the value in member my_sequence_sequence - * @param _my_sequence_sequence New value to be moved in member my_sequence_sequence - */ - eProsima_user_DllExport void my_sequence_sequence( - std::vector>&& _my_sequence_sequence); - - /*! - * @brief This function returns a constant reference to member my_sequence_sequence - * @return Constant reference to member my_sequence_sequence - */ - eProsima_user_DllExport const std::vector>& my_sequence_sequence() const; - - /*! - * @brief This function returns a reference to member my_sequence_sequence - * @return Reference to member my_sequence_sequence - */ - eProsima_user_DllExport std::vector>& my_sequence_sequence(); - -private: - - std::vector> m_my_sequence_sequence; - -}; - - - - -/*! - * @brief This class represents the structure MapStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class MapStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MapStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MapStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MapStruct that will be copied. - */ - eProsima_user_DllExport MapStruct( - const MapStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MapStruct that will be copied. - */ - eProsima_user_DllExport MapStruct( - MapStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MapStruct that will be copied. - */ - eProsima_user_DllExport MapStruct& operator =( - const MapStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MapStruct that will be copied. - */ - eProsima_user_DllExport MapStruct& operator =( - MapStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MapStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MapStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x MapStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MapStruct& x) const; - - /*! - * @brief This function copies the value in member my_map - * @param _my_map New value to be copied in member my_map - */ - eProsima_user_DllExport void my_map( - const std::map& _my_map); - - /*! - * @brief This function moves the value in member my_map - * @param _my_map New value to be moved in member my_map - */ - eProsima_user_DllExport void my_map( - std::map&& _my_map); - - /*! - * @brief This function returns a constant reference to member my_map - * @return Constant reference to member my_map - */ - eProsima_user_DllExport const std::map& my_map() const; - - /*! - * @brief This function returns a reference to member my_map - * @return Reference to member my_map - */ - eProsima_user_DllExport std::map& my_map(); - -private: - - std::map m_my_map; - -}; - - - - - - -/*! - * @brief This class represents the structure MapMapStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class MapMapStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MapMapStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MapMapStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MapMapStruct that will be copied. - */ - eProsima_user_DllExport MapMapStruct( - const MapMapStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MapMapStruct that will be copied. - */ - eProsima_user_DllExport MapMapStruct( - MapMapStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MapMapStruct that will be copied. - */ - eProsima_user_DllExport MapMapStruct& operator =( - const MapMapStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MapMapStruct that will be copied. - */ - eProsima_user_DllExport MapMapStruct& operator =( - MapMapStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MapMapStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MapMapStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x MapMapStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MapMapStruct& x) const; - - /*! - * @brief This function copies the value in member my_map_map - * @param _my_map_map New value to be copied in member my_map_map - */ - eProsima_user_DllExport void my_map_map( - const std::map>& _my_map_map); - - /*! - * @brief This function moves the value in member my_map_map - * @param _my_map_map New value to be moved in member my_map_map - */ - eProsima_user_DllExport void my_map_map( - std::map>&& _my_map_map); - - /*! - * @brief This function returns a constant reference to member my_map_map - * @return Constant reference to member my_map_map - */ - eProsima_user_DllExport const std::map>& my_map_map() const; - - /*! - * @brief This function returns a reference to member my_map_map - * @return Reference to member my_map_map - */ - eProsima_user_DllExport std::map>& my_map_map(); - -private: - - std::map> m_my_map_map; - -}; -/*! - * @brief This class represents the structure MyBitset defined by the user in the IDL file. - * @ingroup Basic - */ -class MyBitset -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MyBitset(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MyBitset(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MyBitset that will be copied. - */ - eProsima_user_DllExport MyBitset( - const MyBitset& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MyBitset that will be copied. - */ - eProsima_user_DllExport MyBitset( - MyBitset&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MyBitset that will be copied. - */ - eProsima_user_DllExport MyBitset& operator =( - const MyBitset& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MyBitset that will be copied. - */ - eProsima_user_DllExport MyBitset& operator =( - MyBitset&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MyBitset object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MyBitset& x) const; - - /*! - * @brief Comparison operator. - * @param x MyBitset object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MyBitset& x) const; - - /*! - * @brief This function sets a value in member a - * @param _a New value for member a - */ - eProsima_user_DllExport void a( - char _a); - - /*! - * @brief This function returns the value of member a - * @return Value of member a - */ - eProsima_user_DllExport char a() const; - - - - /*! - * @brief This function sets a value in member b - * @param _b New value for member b - */ - eProsima_user_DllExport void b( - uint32_t _b); - - /*! - * @brief This function returns the value of member b - * @return Value of member b - */ - eProsima_user_DllExport uint32_t b() const; - - - eProsima_user_DllExport std::bitset<30> bitset() const; - - eProsima_user_DllExport void bitset( - const std::bitset<30>&); - - - -private: - - std::bitset<30> m_bitset; -}; - - -/*! - * @brief This class represents the structure BitsetStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class BitsetStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport BitsetStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~BitsetStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object BitsetStruct that will be copied. - */ - eProsima_user_DllExport BitsetStruct( - const BitsetStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object BitsetStruct that will be copied. - */ - eProsima_user_DllExport BitsetStruct( - BitsetStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object BitsetStruct that will be copied. - */ - eProsima_user_DllExport BitsetStruct& operator =( - const BitsetStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object BitsetStruct that will be copied. - */ - eProsima_user_DllExport BitsetStruct& operator =( - BitsetStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x BitsetStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const BitsetStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x BitsetStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const BitsetStruct& x) const; - - /*! - * @brief This function copies the value in member a - * @param _a New value to be copied in member a - */ - eProsima_user_DllExport void a( - const MyBitset& _a); - - /*! - * @brief This function moves the value in member a - * @param _a New value to be moved in member a - */ - eProsima_user_DllExport void a( - MyBitset&& _a); - - /*! - * @brief This function returns a constant reference to member a - * @return Constant reference to member a - */ - eProsima_user_DllExport const MyBitset& a() const; - - /*! - * @brief This function returns a reference to member a - * @return Reference to member a - */ - eProsima_user_DllExport MyBitset& a(); - -private: - - MyBitset m_a; - -}; - - -/*! - * @brief This class represents the structure StructStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class StructStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport StructStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~StructStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object StructStruct that will be copied. - */ - eProsima_user_DllExport StructStruct( - const StructStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object StructStruct that will be copied. - */ - eProsima_user_DllExport StructStruct( - StructStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object StructStruct that will be copied. - */ - eProsima_user_DllExport StructStruct& operator =( - const StructStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object StructStruct that will be copied. - */ - eProsima_user_DllExport StructStruct& operator =( - StructStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x StructStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const StructStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x StructStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const StructStruct& x) const; - - /*! - * @brief This function sets a value in member a - * @param _a New value for member a - */ - eProsima_user_DllExport void a( - int32_t _a); - - /*! - * @brief This function returns the value of member a - * @return Value of member a - */ - eProsima_user_DllExport int32_t a() const; - - /*! - * @brief This function returns a reference to member a - * @return Reference to member a - */ - eProsima_user_DllExport int32_t& a(); - - - /*! - * @brief This function sets a value in member b - * @param _b New value for member b - */ - eProsima_user_DllExport void b( - int64_t _b); - - /*! - * @brief This function returns the value of member b - * @return Value of member b - */ - eProsima_user_DllExport int64_t b() const; - - /*! - * @brief This function returns a reference to member b - * @return Reference to member b - */ - eProsima_user_DllExport int64_t& b(); - -private: - - int32_t m_a{0}; - int64_t m_b{0}; - -}; - - -/*! - * @brief This class represents the structure StructStructStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class StructStructStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport StructStructStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~StructStructStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object StructStructStruct that will be copied. - */ - eProsima_user_DllExport StructStructStruct( - const StructStructStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object StructStructStruct that will be copied. - */ - eProsima_user_DllExport StructStructStruct( - StructStructStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object StructStructStruct that will be copied. - */ - eProsima_user_DllExport StructStructStruct& operator =( - const StructStructStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object StructStructStruct that will be copied. - */ - eProsima_user_DllExport StructStructStruct& operator =( - StructStructStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x StructStructStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const StructStructStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x StructStructStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const StructStructStruct& x) const; - - /*! - * @brief This function copies the value in member child_struct - * @param _child_struct New value to be copied in member child_struct - */ - eProsima_user_DllExport void child_struct( - const StructStruct& _child_struct); - - /*! - * @brief This function moves the value in member child_struct - * @param _child_struct New value to be moved in member child_struct - */ - eProsima_user_DllExport void child_struct( - StructStruct&& _child_struct); - - /*! - * @brief This function returns a constant reference to member child_struct - * @return Constant reference to member child_struct - */ - eProsima_user_DllExport const StructStruct& child_struct() const; - - /*! - * @brief This function returns a reference to member child_struct - * @return Reference to member child_struct - */ - eProsima_user_DllExport StructStruct& child_struct(); - - - /*! - * @brief This function sets a value in member child_int64 - * @param _child_int64 New value for member child_int64 - */ - eProsima_user_DllExport void child_int64( - int64_t _child_int64); - - /*! - * @brief This function returns the value of member child_int64 - * @return Value of member child_int64 - */ - eProsima_user_DllExport int64_t child_int64() const; - - /*! - * @brief This function returns a reference to member child_int64 - * @return Reference to member child_int64 - */ - eProsima_user_DllExport int64_t& child_int64(); - -private: - - StructStruct m_child_struct; - int64_t m_child_int64{0}; - -}; - - -/*! - * @brief This class represents the union SimpleUnion defined by the user in the IDL file. - * @ingroup Basic - */ -class SimpleUnion -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimpleUnion(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimpleUnion(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimpleUnion that will be copied. - */ - eProsima_user_DllExport SimpleUnion( - const SimpleUnion& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimpleUnion that will be copied. - */ - eProsima_user_DllExport SimpleUnion( - SimpleUnion&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimpleUnion that will be copied. - */ - eProsima_user_DllExport SimpleUnion& operator =( - const SimpleUnion& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimpleUnion that will be copied. - */ - eProsima_user_DllExport SimpleUnion& operator =( - SimpleUnion&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimpleUnion object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimpleUnion& x) const; - - /*! - * @brief Comparison operator. - * @param x SimpleUnion object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimpleUnion& x) const; - - /*! - * @brief This function sets the discriminator value. - * @param __d New value for the discriminator. - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the new value doesn't correspond to the selected union member. - */ - eProsima_user_DllExport void _d( - int32_t __d); - - /*! - * @brief This function returns the value of the discriminator. - * @return Value of the discriminator - */ - eProsima_user_DllExport int32_t _d() const; - - /*! - * @brief This function returns a reference to the discriminator. - * @return Reference to the discriminator. - */ - eProsima_user_DllExport int32_t& _d(); - - /*! - * @brief This function sets a value in member first - * @param _first New value for member first - */ - eProsima_user_DllExport void first( - int32_t _first); - - /*! - * @brief This function returns the value of member first - * @return Value of member first - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t first() const; - - /*! - * @brief This function returns a reference to member first - * @return Reference to member first - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t& first(); - - - /*! - * @brief This function sets a value in member second - * @param _second New value for member second - */ - eProsima_user_DllExport void second( - int64_t _second); - - /*! - * @brief This function returns the value of member second - * @return Value of member second - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t second() const; - - /*! - * @brief This function returns a reference to member second - * @return Reference to member second - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t& second(); - -private: - - int32_t m__d; - - int32_t m_first{0}; - int64_t m_second{0}; -}; - - -/*! - * @brief This class represents the union UnionUnion defined by the user in the IDL file. - * @ingroup Basic - */ -class UnionUnion -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport UnionUnion(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~UnionUnion(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object UnionUnion that will be copied. - */ - eProsima_user_DllExport UnionUnion( - const UnionUnion& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object UnionUnion that will be copied. - */ - eProsima_user_DllExport UnionUnion( - UnionUnion&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object UnionUnion that will be copied. - */ - eProsima_user_DllExport UnionUnion& operator =( - const UnionUnion& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object UnionUnion that will be copied. - */ - eProsima_user_DllExport UnionUnion& operator =( - UnionUnion&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x UnionUnion object to compare. - */ - eProsima_user_DllExport bool operator ==( - const UnionUnion& x) const; - - /*! - * @brief Comparison operator. - * @param x UnionUnion object to compare. - */ - eProsima_user_DllExport bool operator !=( - const UnionUnion& x) const; - - /*! - * @brief This function sets the discriminator value. - * @param __d New value for the discriminator. - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the new value doesn't correspond to the selected union member. - */ - eProsima_user_DllExport void _d( - int32_t __d); - - /*! - * @brief This function returns the value of the discriminator. - * @return Value of the discriminator - */ - eProsima_user_DllExport int32_t _d() const; - - /*! - * @brief This function returns a reference to the discriminator. - * @return Reference to the discriminator. - */ - eProsima_user_DllExport int32_t& _d(); - - /*! - * @brief This function sets a value in member first - * @param _first New value for member first - */ - eProsima_user_DllExport void first( - int32_t _first); - - /*! - * @brief This function returns the value of member first - * @return Value of member first - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t first() const; - - /*! - * @brief This function returns a reference to member first - * @return Reference to member first - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t& first(); - - - /*! - * @brief This function copies the value in member second - * @param _second New value to be copied in member second - */ - eProsima_user_DllExport void second( - const SimpleUnion& _second); - - /*! - * @brief This function moves the value in member second - * @param _second New value to be moved in member second - */ - eProsima_user_DllExport void second( - SimpleUnion&& _second); - - /*! - * @brief This function returns a constant reference to member second - * @return Constant reference to member second - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport const SimpleUnion& second() const; - - /*! - * @brief This function returns a reference to member second - * @return Reference to member second - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport SimpleUnion& second(); - -private: - - int32_t m__d; - - int32_t m_first{0}; - SimpleUnion m_second; -}; - - -/*! - * @brief This class represents the union WCharUnion defined by the user in the IDL file. - * @ingroup Basic - */ -class WCharUnion -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport WCharUnion(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~WCharUnion(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object WCharUnion that will be copied. - */ - eProsima_user_DllExport WCharUnion( - const WCharUnion& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object WCharUnion that will be copied. - */ - eProsima_user_DllExport WCharUnion( - WCharUnion&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object WCharUnion that will be copied. - */ - eProsima_user_DllExport WCharUnion& operator =( - const WCharUnion& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object WCharUnion that will be copied. - */ - eProsima_user_DllExport WCharUnion& operator =( - WCharUnion&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x WCharUnion object to compare. - */ - eProsima_user_DllExport bool operator ==( - const WCharUnion& x) const; - - /*! - * @brief Comparison operator. - * @param x WCharUnion object to compare. - */ - eProsima_user_DllExport bool operator !=( - const WCharUnion& x) const; - - /*! - * @brief This function sets the discriminator value. - * @param __d New value for the discriminator. - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the new value doesn't correspond to the selected union member. - */ - eProsima_user_DllExport void _d( - wchar_t __d); - - /*! - * @brief This function returns the value of the discriminator. - * @return Value of the discriminator - */ - eProsima_user_DllExport wchar_t _d() const; - - /*! - * @brief This function returns a reference to the discriminator. - * @return Reference to the discriminator. - */ - eProsima_user_DllExport wchar_t& _d(); - - /*! - * @brief This function sets a value in member first - * @param _first New value for member first - */ - eProsima_user_DllExport void first( - int32_t _first); - - /*! - * @brief This function returns the value of member first - * @return Value of member first - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t first() const; - - /*! - * @brief This function returns a reference to member first - * @return Reference to member first - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t& first(); - - - /*! - * @brief This function sets a value in member second - * @param _second New value for member second - */ - eProsima_user_DllExport void second( - int64_t _second); - - /*! - * @brief This function returns the value of member second - * @return Value of member second - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t second() const; - - /*! - * @brief This function returns a reference to member second - * @return Reference to member second - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t& second(); - -private: - - wchar_t m__d; - - int32_t m_first{0}; - int64_t m_second{0}; -}; - - -/*! - * @brief This class represents the structure SimpleUnionStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class SimpleUnionStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimpleUnionStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimpleUnionStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimpleUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleUnionStruct( - const SimpleUnionStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimpleUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleUnionStruct( - SimpleUnionStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimpleUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleUnionStruct& operator =( - const SimpleUnionStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimpleUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleUnionStruct& operator =( - SimpleUnionStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimpleUnionStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimpleUnionStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x SimpleUnionStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimpleUnionStruct& x) const; - - /*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ - eProsima_user_DllExport void my_union( - const SimpleUnion& _my_union); - - /*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ - eProsima_user_DllExport void my_union( - SimpleUnion&& _my_union); - - /*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ - eProsima_user_DllExport const SimpleUnion& my_union() const; - - /*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ - eProsima_user_DllExport SimpleUnion& my_union(); - -private: - - SimpleUnion m_my_union; - -}; - - -/*! - * @brief This class represents the structure UnionUnionUnionStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class UnionUnionUnionStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport UnionUnionUnionStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~UnionUnionUnionStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object UnionUnionUnionStruct that will be copied. - */ - eProsima_user_DllExport UnionUnionUnionStruct( - const UnionUnionUnionStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object UnionUnionUnionStruct that will be copied. - */ - eProsima_user_DllExport UnionUnionUnionStruct( - UnionUnionUnionStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object UnionUnionUnionStruct that will be copied. - */ - eProsima_user_DllExport UnionUnionUnionStruct& operator =( - const UnionUnionUnionStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object UnionUnionUnionStruct that will be copied. - */ - eProsima_user_DllExport UnionUnionUnionStruct& operator =( - UnionUnionUnionStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x UnionUnionUnionStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const UnionUnionUnionStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x UnionUnionUnionStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const UnionUnionUnionStruct& x) const; - - /*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ - eProsima_user_DllExport void my_union( - const UnionUnion& _my_union); - - /*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ - eProsima_user_DllExport void my_union( - UnionUnion&& _my_union); - - /*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ - eProsima_user_DllExport const UnionUnion& my_union() const; - - /*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ - eProsima_user_DllExport UnionUnion& my_union(); - -private: - - UnionUnion m_my_union; - -}; - - -/*! - * @brief This class represents the structure WCharUnionStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class WCharUnionStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport WCharUnionStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~WCharUnionStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object WCharUnionStruct that will be copied. - */ - eProsima_user_DllExport WCharUnionStruct( - const WCharUnionStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object WCharUnionStruct that will be copied. - */ - eProsima_user_DllExport WCharUnionStruct( - WCharUnionStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object WCharUnionStruct that will be copied. - */ - eProsima_user_DllExport WCharUnionStruct& operator =( - const WCharUnionStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object WCharUnionStruct that will be copied. - */ - eProsima_user_DllExport WCharUnionStruct& operator =( - WCharUnionStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x WCharUnionStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const WCharUnionStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x WCharUnionStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const WCharUnionStruct& x) const; - - /*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ - eProsima_user_DllExport void my_union( - const WCharUnion& _my_union); - - /*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ - eProsima_user_DllExport void my_union( - WCharUnion&& _my_union); - - /*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ - eProsima_user_DllExport const WCharUnion& my_union() const; - - /*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ - eProsima_user_DllExport WCharUnion& my_union(); - -private: - - WCharUnion m_my_union; - -}; - -#endif // _FAST_DDS_GENERATED_BASIC_H_ - - - -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/test/unittest/dynamic_types/idl/Basic.idl b/test/unittest/dynamic_types/idl/Basic.idl deleted file mode 100644 index e800494e7de..00000000000 --- a/test/unittest/dynamic_types/idl/Basic.idl +++ /dev/null @@ -1,204 +0,0 @@ -enum MyEnum -{ - A, - B, - C -}; - -typedef MyEnum MyAliasEnum; -typedef MyAliasEnum MyAliasAliasEnum; - -struct EnumStruct -{ - MyEnum my_enum; -}; - -struct AliasStruct -{ - MyAliasEnum my_alias; -}; - -struct AliasAliasStruct -{ - MyAliasAliasEnum my_alias_alias; -}; - -struct BoolStruct -{ - boolean my_bool; -}; - -struct OctetStruct -{ - octet my_octet; -}; - -struct ShortStruct -{ - short my_int16; -}; - -struct LongStruct -{ - long my_int32; -}; - -struct LongLongStruct -{ - long long my_int64; -}; - -struct UShortStruct -{ - unsigned short my_uint16; -}; - -struct ULongStruct -{ - unsigned long my_uint32; -}; - -struct ULongLongStruct -{ - unsigned long long my_uint64; -}; - -struct FloatStruct -{ - float my_float32; -}; - -struct DoubleStruct -{ - double my_float64; -}; - -struct LongDoubleStruct -{ - long double my_float128; -}; - -struct CharStruct -{ - char my_char; -}; - -struct WCharStruct -{ - wchar my_wchar; -}; - -struct StringStruct -{ - string my_string; -}; - -struct WStringStruct -{ - wstring my_wstring; -}; - -struct LargeStringStruct -{ - string<41925> my_large_string; -}; - -struct LargeWStringStruct -{ - wstring<41925> my_large_wstring; -}; - -struct ArraytStruct -{ - long my_array[2][2][2]; -}; - -typedef long MyArray[2][2]; - -struct ArrayArrayStruct -{ - MyArray my_array_array[2][2]; -}; - -struct SequenceStruct -{ - sequence my_sequence; -}; - -struct SequenceSequenceStruct -{ - sequence, 3> my_sequence_sequence; -}; - -struct MapStruct -{ - map my_map; -}; - -struct MapMapStruct -{ - map , 2> my_map_map; -}; - -bitset MyBitset -{ - bitfield<2> a; - bitfield<8>; - bitfield<20> b; -}; - -struct BitsetStruct -{ - MyBitset a; -}; - -struct StructStruct -{ - long a; - long long b; -}; - -struct StructStructStruct -{ - StructStruct child_struct; - long long child_int64; -}; - -union SimpleUnion switch (long) -{ - case A: - long first; - case B: - long long second; -}; - -union UnionUnion switch (long) -{ - case A: - long first; - case B: - SimpleUnion second; -}; - -union WCharUnion switch (wchar) -{ - case A: - long first; - case B: - long long second; -}; - -struct SimpleUnionStruct -{ - SimpleUnion my_union; -}; - -struct UnionUnionUnionStruct -{ - UnionUnion my_union; -}; - -struct WCharUnionStruct -{ - WCharUnion my_union; -}; \ No newline at end of file diff --git a/test/unittest/dynamic_types/idl/BasicCdrAux.hpp b/test/unittest/dynamic_types/idl/BasicCdrAux.hpp deleted file mode 100644 index ddb7d2cc3b4..00000000000 --- a/test/unittest/dynamic_types/idl/BasicCdrAux.hpp +++ /dev/null @@ -1,366 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file BasicCdrAux.hpp - * This source file contains some definitions of CDR related functions. - * - * This file was generated by the tool fastddsgen. - */ - -#ifndef _FAST_DDS_GENERATED_BASICCDRAUX_HPP_ -#define _FAST_DDS_GENERATED_BASICCDRAUX_HPP_ - -#include "Basic.h" - -constexpr uint32_t ArraytStruct_max_cdr_typesize {36UL}; -constexpr uint32_t ArraytStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t SimpleUnionStruct_max_cdr_typesize {24UL}; -constexpr uint32_t SimpleUnionStruct_max_key_cdr_typesize {0UL}; - - -constexpr uint32_t WCharUnionStruct_max_cdr_typesize {24UL}; -constexpr uint32_t WCharUnionStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t OctetStruct_max_cdr_typesize {5UL}; -constexpr uint32_t OctetStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t LongStruct_max_cdr_typesize {8UL}; -constexpr uint32_t LongStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t EnumStruct_max_cdr_typesize {8UL}; -constexpr uint32_t EnumStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t BitsetStruct_max_cdr_typesize {8UL}; -constexpr uint32_t BitsetStruct_max_key_cdr_typesize {0UL}; - - - -constexpr uint32_t DoubleStruct_max_cdr_typesize {16UL}; -constexpr uint32_t DoubleStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t LargeWStringStruct_max_cdr_typesize {83858UL}; -constexpr uint32_t LargeWStringStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t WCharStruct_max_cdr_typesize {6UL}; -constexpr uint32_t WCharStruct_max_key_cdr_typesize {0UL}; - - -constexpr uint32_t WStringStruct_max_cdr_typesize {518UL}; -constexpr uint32_t WStringStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t SequenceStruct_max_cdr_typesize {16UL}; -constexpr uint32_t SequenceStruct_max_key_cdr_typesize {0UL}; - - -constexpr uint32_t ULongStruct_max_cdr_typesize {8UL}; -constexpr uint32_t ULongStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t SequenceSequenceStruct_max_cdr_typesize {48UL}; -constexpr uint32_t SequenceSequenceStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t FloatStruct_max_cdr_typesize {8UL}; -constexpr uint32_t FloatStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t LongDoubleStruct_max_cdr_typesize {24UL}; -constexpr uint32_t LongDoubleStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t StructStructStruct_max_cdr_typesize {32UL}; -constexpr uint32_t StructStructStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t UnionUnionUnionStruct_max_cdr_typesize {32UL}; -constexpr uint32_t UnionUnionUnionStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t BoolStruct_max_cdr_typesize {5UL}; -constexpr uint32_t BoolStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t MapMapStruct_max_cdr_typesize {60UL}; -constexpr uint32_t MapMapStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t AliasAliasStruct_max_cdr_typesize {8UL}; -constexpr uint32_t AliasAliasStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t ArrayArrayStruct_max_cdr_typesize {72UL}; -constexpr uint32_t ArrayArrayStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t ShortStruct_max_cdr_typesize {6UL}; -constexpr uint32_t ShortStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t MapStruct_max_cdr_typesize {24UL}; -constexpr uint32_t MapStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t UShortStruct_max_cdr_typesize {6UL}; -constexpr uint32_t UShortStruct_max_key_cdr_typesize {0UL}; - - - -constexpr uint32_t ULongLongStruct_max_cdr_typesize {16UL}; -constexpr uint32_t ULongLongStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t AliasStruct_max_cdr_typesize {8UL}; -constexpr uint32_t AliasStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t LargeStringStruct_max_cdr_typesize {41934UL}; -constexpr uint32_t LargeStringStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t CharStruct_max_cdr_typesize {5UL}; -constexpr uint32_t CharStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t LongLongStruct_max_cdr_typesize {16UL}; -constexpr uint32_t LongLongStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t StringStruct_max_cdr_typesize {264UL}; -constexpr uint32_t StringStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t StructStruct_max_cdr_typesize {16UL}; -constexpr uint32_t StructStruct_max_key_cdr_typesize {0UL}; - - - -namespace eprosima { -namespace fastcdr { - -class Cdr; -class CdrSizeCalculator; - - - - - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const EnumStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const AliasStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const AliasAliasStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const BoolStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const OctetStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const ShortStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const LongStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const LongLongStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const UShortStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const ULongStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const ULongLongStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const FloatStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const DoubleStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const LongDoubleStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const CharStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const WCharStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const StringStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const WStringStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const LargeStringStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const LargeWStringStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const ArraytStruct& data); - - - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const ArrayArrayStruct& data); - - - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SequenceStruct& data); - - - - - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SequenceSequenceStruct& data); - - - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const MapStruct& data); - - - - - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const MapMapStruct& data); - - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const BitsetStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const StructStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const StructStructStruct& data); - - - - - - - - - - - - - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SimpleUnionStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const UnionUnionUnionStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const WCharUnionStruct& data); - - -} // namespace fastcdr -} // namespace eprosima - -#endif // _FAST_DDS_GENERATED_BASICCDRAUX_HPP_ - diff --git a/test/unittest/dynamic_types/idl/BasicCdrAux.ipp b/test/unittest/dynamic_types/idl/BasicCdrAux.ipp deleted file mode 100644 index 98a0f8f1dd5..00000000000 --- a/test/unittest/dynamic_types/idl/BasicCdrAux.ipp +++ /dev/null @@ -1,2926 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file BasicCdrAux.ipp - * This source file contains some declarations of CDR related functions. - * - * This file was generated by the tool fastddsgen. - */ - -#ifndef _FAST_DDS_GENERATED_BASICCDRAUX_IPP_ -#define _FAST_DDS_GENERATED_BASICCDRAUX_IPP_ - -#include "BasicCdrAux.hpp" - -#include -#include - - -#include -using namespace eprosima::fastcdr::exception; - -namespace eprosima { -namespace fastcdr { - - - - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const EnumStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_enum(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const EnumStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_enum() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - EnumStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_enum(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const EnumStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const AliasStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_alias(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const AliasStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_alias() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - AliasStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_alias(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const AliasStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const AliasAliasStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_alias_alias(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const AliasAliasStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_alias_alias() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - AliasAliasStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_alias_alias(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const AliasAliasStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const BoolStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_bool(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const BoolStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_bool() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - BoolStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_bool(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const BoolStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const OctetStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_octet(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const OctetStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_octet() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - OctetStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_octet(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const OctetStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const ShortStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_int16(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const ShortStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_int16() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - ShortStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_int16(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const ShortStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const LongStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_int32(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const LongStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_int32() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - LongStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_int32(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const LongStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const LongLongStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_int64(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const LongLongStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_int64() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - LongLongStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_int64(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const LongLongStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const UShortStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_uint16(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const UShortStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_uint16() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - UShortStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_uint16(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const UShortStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const ULongStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_uint32(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const ULongStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_uint32() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - ULongStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_uint32(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const ULongStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const ULongLongStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_uint64(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const ULongLongStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_uint64() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - ULongLongStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_uint64(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const ULongLongStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const FloatStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_float32(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const FloatStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_float32() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - FloatStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_float32(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const FloatStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const DoubleStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_float64(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const DoubleStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_float64() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - DoubleStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_float64(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const DoubleStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const LongDoubleStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_float128(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const LongDoubleStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_float128() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - LongDoubleStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_float128(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const LongDoubleStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const CharStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_char(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const CharStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_char() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - CharStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_char(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const CharStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const WCharStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_wchar(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const WCharStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_wchar() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - WCharStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_wchar(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const WCharStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const StringStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_string(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const StringStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_string() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - StringStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_string(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const StringStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const WStringStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_wstring(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const WStringStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_wstring() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - WStringStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_wstring(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const WStringStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const LargeStringStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_large_string(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const LargeStringStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_large_string() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - LargeStringStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_large_string(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const LargeStringStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const LargeWStringStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_large_wstring(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const LargeWStringStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_large_wstring() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - LargeWStringStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_large_wstring(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const LargeWStringStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const ArraytStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_array(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const ArraytStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_array() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - ArraytStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_array(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const ArraytStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const ArrayArrayStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_array_array(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const ArrayArrayStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_array_array() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - ArrayArrayStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_array_array(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const ArrayArrayStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const SequenceStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_sequence(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const SequenceStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_sequence() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - SequenceStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_sequence(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SequenceStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const SequenceSequenceStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_sequence_sequence(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const SequenceSequenceStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_sequence_sequence() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - SequenceSequenceStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_sequence_sequence(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SequenceSequenceStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const MapStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_map(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const MapStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_map() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - MapStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_map(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const MapStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const MapMapStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_map_map(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const MapMapStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_map_map() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - MapMapStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_map_map(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const MapMapStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const MyBitset& data, - size_t& current_alignment) -{ - return calculator.calculate_serialized_size(data.bitset(), current_alignment); -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const MyBitset& data) -{ - scdr << data.bitset(); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& dcdr, - MyBitset& data) -{ - std::bitset<30> bitset; - dcdr >> bitset; - data.bitset(bitset); -} - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const BitsetStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.a(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const BitsetStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.a() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - BitsetStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.a(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const BitsetStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const StructStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.a(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(1), - data.b(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const StructStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.a() - << eprosima::fastcdr::MemberId(1) << data.b() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - StructStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.a(); - break; - - case 1: - dcdr >> data.b(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const StructStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const StructStructStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.child_struct(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(1), - data.child_int64(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const StructStructStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.child_struct() - << eprosima::fastcdr::MemberId(1) << data.child_int64() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - StructStructStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.child_struct(); - break; - - case 1: - dcdr >> data.child_int64(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const StructStructStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const SimpleUnion& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), data._d(), - current_alignment); - - switch (data._d()) - { - case A: - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(1), - data.first(), current_alignment); - break; - - case B: - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(2), - data.second(), current_alignment); - break; - - default: - break; - } - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const SimpleUnion& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr << eprosima::fastcdr::MemberId(0) << data._d(); - - switch (data._d()) - { - case A: - scdr << eprosima::fastcdr::MemberId(1) << data.first(); - break; - - case B: - scdr << eprosima::fastcdr::MemberId(2) << data.second(); - break; - - default: - break; - } - - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - SimpleUnion& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data._d(); - break; - default: - switch (data._d()) - { - case A: - dcdr >> data.first(); - break; - - case B: - dcdr >> data.second(); - break; - - default: - break; - } - ret_value = false; - break; - } - return ret_value; - }); -} - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const UnionUnion& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), data._d(), - current_alignment); - - switch (data._d()) - { - case A: - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(1), - data.first(), current_alignment); - break; - - case B: - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(2), - data.second(), current_alignment); - break; - - default: - break; - } - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const UnionUnion& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr << eprosima::fastcdr::MemberId(0) << data._d(); - - switch (data._d()) - { - case A: - scdr << eprosima::fastcdr::MemberId(1) << data.first(); - break; - - case B: - scdr << eprosima::fastcdr::MemberId(2) << data.second(); - break; - - default: - break; - } - - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - UnionUnion& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data._d(); - break; - default: - switch (data._d()) - { - case A: - dcdr >> data.first(); - break; - - case B: - dcdr >> data.second(); - break; - - default: - break; - } - ret_value = false; - break; - } - return ret_value; - }); -} - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const WCharUnion& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), data._d(), - current_alignment); - - switch (data._d()) - { - case A: - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(1), - data.first(), current_alignment); - break; - - case B: - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(2), - data.second(), current_alignment); - break; - - default: - break; - } - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const WCharUnion& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr << eprosima::fastcdr::MemberId(0) << data._d(); - - switch (data._d()) - { - case A: - scdr << eprosima::fastcdr::MemberId(1) << data.first(); - break; - - case B: - scdr << eprosima::fastcdr::MemberId(2) << data.second(); - break; - - default: - break; - } - - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - WCharUnion& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data._d(); - break; - default: - switch (data._d()) - { - case A: - dcdr >> data.first(); - break; - - case B: - dcdr >> data.second(); - break; - - default: - break; - } - ret_value = false; - break; - } - return ret_value; - }); -} - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const SimpleUnionStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_union(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const SimpleUnionStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_union() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - SimpleUnionStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_union(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SimpleUnionStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const UnionUnionUnionStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_union(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const UnionUnionUnionStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_union() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - UnionUnionUnionStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_union(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const UnionUnionUnionStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const WCharUnionStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_union(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const WCharUnionStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_union() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - WCharUnionStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_union(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const WCharUnionStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - -} // namespace fastcdr -} // namespace eprosima - -#endif // _FAST_DDS_GENERATED_BASICCDRAUX_IPP_ - diff --git a/test/unittest/dynamic_types/idl/BasicPubSubTypes.cxx b/test/unittest/dynamic_types/idl/BasicPubSubTypes.cxx deleted file mode 100644 index efe25ce72f8..00000000000 --- a/test/unittest/dynamic_types/idl/BasicPubSubTypes.cxx +++ /dev/null @@ -1,6142 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file BasicPubSubTypes.cpp - * This header file contains the implementation of the serialization functions. - * - * This file was generated by the tool fastddsgen. - */ - - -#include - -#include "BasicPubSubTypes.h" -#include "BasicCdrAux.hpp" - -using SerializedPayload_t = eprosima::fastrtps::rtps::SerializedPayload_t; -using InstanceHandle_t = eprosima::fastrtps::rtps::InstanceHandle_t; -using DataRepresentationId_t = eprosima::fastdds::dds::DataRepresentationId_t; - - - - - - - -EnumStructPubSubType::EnumStructPubSubType() -{ - setName("EnumStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(EnumStruct::getMaxCdrSerializedSize()); -#else - EnumStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = EnumStruct_max_key_cdr_typesize > 16 ? EnumStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -EnumStructPubSubType::~EnumStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool EnumStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - EnumStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool EnumStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - EnumStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function EnumStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* EnumStructPubSubType::createData() -{ - return reinterpret_cast(new EnumStruct()); -} - -void EnumStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool EnumStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - EnumStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - EnumStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || EnumStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -AliasStructPubSubType::AliasStructPubSubType() -{ - setName("AliasStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(AliasStruct::getMaxCdrSerializedSize()); -#else - AliasStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = AliasStruct_max_key_cdr_typesize > 16 ? AliasStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -AliasStructPubSubType::~AliasStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool AliasStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - AliasStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool AliasStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - AliasStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function AliasStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* AliasStructPubSubType::createData() -{ - return reinterpret_cast(new AliasStruct()); -} - -void AliasStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool AliasStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - AliasStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - AliasStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || AliasStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -AliasAliasStructPubSubType::AliasAliasStructPubSubType() -{ - setName("AliasAliasStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(AliasAliasStruct::getMaxCdrSerializedSize()); -#else - AliasAliasStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = AliasAliasStruct_max_key_cdr_typesize > 16 ? AliasAliasStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -AliasAliasStructPubSubType::~AliasAliasStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool AliasAliasStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - AliasAliasStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool AliasAliasStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - AliasAliasStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function AliasAliasStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* AliasAliasStructPubSubType::createData() -{ - return reinterpret_cast(new AliasAliasStruct()); -} - -void AliasAliasStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool AliasAliasStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - AliasAliasStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - AliasAliasStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || AliasAliasStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -BoolStructPubSubType::BoolStructPubSubType() -{ - setName("BoolStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(BoolStruct::getMaxCdrSerializedSize()); -#else - BoolStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = BoolStruct_max_key_cdr_typesize > 16 ? BoolStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -BoolStructPubSubType::~BoolStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool BoolStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - BoolStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool BoolStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - BoolStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function BoolStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* BoolStructPubSubType::createData() -{ - return reinterpret_cast(new BoolStruct()); -} - -void BoolStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool BoolStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - BoolStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - BoolStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || BoolStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -OctetStructPubSubType::OctetStructPubSubType() -{ - setName("OctetStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(OctetStruct::getMaxCdrSerializedSize()); -#else - OctetStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = OctetStruct_max_key_cdr_typesize > 16 ? OctetStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -OctetStructPubSubType::~OctetStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool OctetStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - OctetStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool OctetStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - OctetStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function OctetStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* OctetStructPubSubType::createData() -{ - return reinterpret_cast(new OctetStruct()); -} - -void OctetStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool OctetStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - OctetStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - OctetStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || OctetStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -ShortStructPubSubType::ShortStructPubSubType() -{ - setName("ShortStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(ShortStruct::getMaxCdrSerializedSize()); -#else - ShortStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = ShortStruct_max_key_cdr_typesize > 16 ? ShortStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -ShortStructPubSubType::~ShortStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool ShortStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - ShortStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool ShortStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - ShortStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function ShortStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* ShortStructPubSubType::createData() -{ - return reinterpret_cast(new ShortStruct()); -} - -void ShortStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool ShortStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - ShortStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - ShortStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || ShortStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -LongStructPubSubType::LongStructPubSubType() -{ - setName("LongStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(LongStruct::getMaxCdrSerializedSize()); -#else - LongStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = LongStruct_max_key_cdr_typesize > 16 ? LongStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -LongStructPubSubType::~LongStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool LongStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - LongStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool LongStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - LongStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function LongStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* LongStructPubSubType::createData() -{ - return reinterpret_cast(new LongStruct()); -} - -void LongStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool LongStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - LongStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - LongStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || LongStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -LongLongStructPubSubType::LongLongStructPubSubType() -{ - setName("LongLongStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(LongLongStruct::getMaxCdrSerializedSize()); -#else - LongLongStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = LongLongStruct_max_key_cdr_typesize > 16 ? LongLongStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -LongLongStructPubSubType::~LongLongStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool LongLongStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - LongLongStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool LongLongStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - LongLongStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function LongLongStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* LongLongStructPubSubType::createData() -{ - return reinterpret_cast(new LongLongStruct()); -} - -void LongLongStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool LongLongStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - LongLongStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - LongLongStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || LongLongStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -UShortStructPubSubType::UShortStructPubSubType() -{ - setName("UShortStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(UShortStruct::getMaxCdrSerializedSize()); -#else - UShortStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = UShortStruct_max_key_cdr_typesize > 16 ? UShortStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -UShortStructPubSubType::~UShortStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool UShortStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - UShortStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool UShortStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - UShortStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function UShortStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* UShortStructPubSubType::createData() -{ - return reinterpret_cast(new UShortStruct()); -} - -void UShortStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool UShortStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - UShortStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - UShortStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || UShortStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -ULongStructPubSubType::ULongStructPubSubType() -{ - setName("ULongStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(ULongStruct::getMaxCdrSerializedSize()); -#else - ULongStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = ULongStruct_max_key_cdr_typesize > 16 ? ULongStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -ULongStructPubSubType::~ULongStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool ULongStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - ULongStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool ULongStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - ULongStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function ULongStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* ULongStructPubSubType::createData() -{ - return reinterpret_cast(new ULongStruct()); -} - -void ULongStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool ULongStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - ULongStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - ULongStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || ULongStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -ULongLongStructPubSubType::ULongLongStructPubSubType() -{ - setName("ULongLongStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(ULongLongStruct::getMaxCdrSerializedSize()); -#else - ULongLongStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = ULongLongStruct_max_key_cdr_typesize > 16 ? ULongLongStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -ULongLongStructPubSubType::~ULongLongStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool ULongLongStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - ULongLongStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool ULongLongStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - ULongLongStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function ULongLongStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* ULongLongStructPubSubType::createData() -{ - return reinterpret_cast(new ULongLongStruct()); -} - -void ULongLongStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool ULongLongStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - ULongLongStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - ULongLongStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || ULongLongStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -FloatStructPubSubType::FloatStructPubSubType() -{ - setName("FloatStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(FloatStruct::getMaxCdrSerializedSize()); -#else - FloatStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = FloatStruct_max_key_cdr_typesize > 16 ? FloatStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -FloatStructPubSubType::~FloatStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool FloatStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - FloatStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool FloatStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - FloatStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function FloatStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* FloatStructPubSubType::createData() -{ - return reinterpret_cast(new FloatStruct()); -} - -void FloatStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool FloatStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - FloatStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - FloatStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || FloatStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -DoubleStructPubSubType::DoubleStructPubSubType() -{ - setName("DoubleStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(DoubleStruct::getMaxCdrSerializedSize()); -#else - DoubleStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = DoubleStruct_max_key_cdr_typesize > 16 ? DoubleStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -DoubleStructPubSubType::~DoubleStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool DoubleStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - DoubleStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool DoubleStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - DoubleStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function DoubleStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* DoubleStructPubSubType::createData() -{ - return reinterpret_cast(new DoubleStruct()); -} - -void DoubleStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool DoubleStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - DoubleStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - DoubleStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || DoubleStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -LongDoubleStructPubSubType::LongDoubleStructPubSubType() -{ - setName("LongDoubleStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(LongDoubleStruct::getMaxCdrSerializedSize()); -#else - LongDoubleStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = LongDoubleStruct_max_key_cdr_typesize > 16 ? LongDoubleStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -LongDoubleStructPubSubType::~LongDoubleStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool LongDoubleStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - LongDoubleStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool LongDoubleStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - LongDoubleStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function LongDoubleStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* LongDoubleStructPubSubType::createData() -{ - return reinterpret_cast(new LongDoubleStruct()); -} - -void LongDoubleStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool LongDoubleStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - LongDoubleStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - LongDoubleStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || LongDoubleStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -CharStructPubSubType::CharStructPubSubType() -{ - setName("CharStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(CharStruct::getMaxCdrSerializedSize()); -#else - CharStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = CharStruct_max_key_cdr_typesize > 16 ? CharStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -CharStructPubSubType::~CharStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool CharStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - CharStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool CharStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - CharStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function CharStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* CharStructPubSubType::createData() -{ - return reinterpret_cast(new CharStruct()); -} - -void CharStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool CharStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - CharStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - CharStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || CharStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -WCharStructPubSubType::WCharStructPubSubType() -{ - setName("WCharStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(WCharStruct::getMaxCdrSerializedSize()); -#else - WCharStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = WCharStruct_max_key_cdr_typesize > 16 ? WCharStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -WCharStructPubSubType::~WCharStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool WCharStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - WCharStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool WCharStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - WCharStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function WCharStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* WCharStructPubSubType::createData() -{ - return reinterpret_cast(new WCharStruct()); -} - -void WCharStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool WCharStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - WCharStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - WCharStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || WCharStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -StringStructPubSubType::StringStructPubSubType() -{ - setName("StringStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(StringStruct::getMaxCdrSerializedSize()); -#else - StringStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = StringStruct_max_key_cdr_typesize > 16 ? StringStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -StringStructPubSubType::~StringStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool StringStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - StringStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool StringStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - StringStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function StringStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* StringStructPubSubType::createData() -{ - return reinterpret_cast(new StringStruct()); -} - -void StringStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool StringStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - StringStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - StringStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || StringStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -WStringStructPubSubType::WStringStructPubSubType() -{ - setName("WStringStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(WStringStruct::getMaxCdrSerializedSize()); -#else - WStringStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = WStringStruct_max_key_cdr_typesize > 16 ? WStringStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -WStringStructPubSubType::~WStringStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool WStringStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - WStringStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool WStringStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - WStringStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function WStringStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* WStringStructPubSubType::createData() -{ - return reinterpret_cast(new WStringStruct()); -} - -void WStringStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool WStringStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - WStringStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - WStringStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || WStringStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -LargeStringStructPubSubType::LargeStringStructPubSubType() -{ - setName("LargeStringStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(LargeStringStruct::getMaxCdrSerializedSize()); -#else - LargeStringStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = LargeStringStruct_max_key_cdr_typesize > 16 ? LargeStringStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -LargeStringStructPubSubType::~LargeStringStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool LargeStringStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - LargeStringStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool LargeStringStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - LargeStringStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function LargeStringStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* LargeStringStructPubSubType::createData() -{ - return reinterpret_cast(new LargeStringStruct()); -} - -void LargeStringStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool LargeStringStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - LargeStringStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - LargeStringStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || LargeStringStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -LargeWStringStructPubSubType::LargeWStringStructPubSubType() -{ - setName("LargeWStringStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(LargeWStringStruct::getMaxCdrSerializedSize()); -#else - LargeWStringStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = LargeWStringStruct_max_key_cdr_typesize > 16 ? LargeWStringStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -LargeWStringStructPubSubType::~LargeWStringStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool LargeWStringStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - LargeWStringStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool LargeWStringStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - LargeWStringStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function LargeWStringStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* LargeWStringStructPubSubType::createData() -{ - return reinterpret_cast(new LargeWStringStruct()); -} - -void LargeWStringStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool LargeWStringStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - LargeWStringStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - LargeWStringStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || LargeWStringStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -ArraytStructPubSubType::ArraytStructPubSubType() -{ - setName("ArraytStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(ArraytStruct::getMaxCdrSerializedSize()); -#else - ArraytStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = ArraytStruct_max_key_cdr_typesize > 16 ? ArraytStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -ArraytStructPubSubType::~ArraytStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool ArraytStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - ArraytStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool ArraytStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - ArraytStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function ArraytStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* ArraytStructPubSubType::createData() -{ - return reinterpret_cast(new ArraytStruct()); -} - -void ArraytStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool ArraytStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - ArraytStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - ArraytStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || ArraytStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - - - -ArrayArrayStructPubSubType::ArrayArrayStructPubSubType() -{ - setName("ArrayArrayStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(ArrayArrayStruct::getMaxCdrSerializedSize()); -#else - ArrayArrayStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = ArrayArrayStruct_max_key_cdr_typesize > 16 ? ArrayArrayStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -ArrayArrayStructPubSubType::~ArrayArrayStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool ArrayArrayStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - ArrayArrayStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool ArrayArrayStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - ArrayArrayStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function ArrayArrayStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* ArrayArrayStructPubSubType::createData() -{ - return reinterpret_cast(new ArrayArrayStruct()); -} - -void ArrayArrayStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool ArrayArrayStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - ArrayArrayStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - ArrayArrayStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || ArrayArrayStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - - - -SequenceStructPubSubType::SequenceStructPubSubType() -{ - setName("SequenceStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(SequenceStruct::getMaxCdrSerializedSize()); -#else - SequenceStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = SequenceStruct_max_key_cdr_typesize > 16 ? SequenceStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -SequenceStructPubSubType::~SequenceStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool SequenceStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - SequenceStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool SequenceStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - SequenceStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function SequenceStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* SequenceStructPubSubType::createData() -{ - return reinterpret_cast(new SequenceStruct()); -} - -void SequenceStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool SequenceStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - SequenceStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - SequenceStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || SequenceStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - - - - - -SequenceSequenceStructPubSubType::SequenceSequenceStructPubSubType() -{ - setName("SequenceSequenceStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(SequenceSequenceStruct::getMaxCdrSerializedSize()); -#else - SequenceSequenceStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = SequenceSequenceStruct_max_key_cdr_typesize > 16 ? SequenceSequenceStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -SequenceSequenceStructPubSubType::~SequenceSequenceStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool SequenceSequenceStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - SequenceSequenceStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool SequenceSequenceStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - SequenceSequenceStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function SequenceSequenceStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* SequenceSequenceStructPubSubType::createData() -{ - return reinterpret_cast(new SequenceSequenceStruct()); -} - -void SequenceSequenceStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool SequenceSequenceStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - SequenceSequenceStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - SequenceSequenceStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || SequenceSequenceStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - - - -MapStructPubSubType::MapStructPubSubType() -{ - setName("MapStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(MapStruct::getMaxCdrSerializedSize()); -#else - MapStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = MapStruct_max_key_cdr_typesize > 16 ? MapStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -MapStructPubSubType::~MapStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool MapStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - MapStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool MapStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - MapStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function MapStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* MapStructPubSubType::createData() -{ - return reinterpret_cast(new MapStruct()); -} - -void MapStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool MapStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - MapStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - MapStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || MapStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - - - - - -MapMapStructPubSubType::MapMapStructPubSubType() -{ - setName("MapMapStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(MapMapStruct::getMaxCdrSerializedSize()); -#else - MapMapStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = MapMapStruct_max_key_cdr_typesize > 16 ? MapMapStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -MapMapStructPubSubType::~MapMapStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool MapMapStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - MapMapStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool MapMapStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - MapMapStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function MapMapStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* MapMapStructPubSubType::createData() -{ - return reinterpret_cast(new MapMapStruct()); -} - -void MapMapStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool MapMapStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - MapMapStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - MapMapStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || MapMapStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - - -BitsetStructPubSubType::BitsetStructPubSubType() -{ - setName("BitsetStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(BitsetStruct::getMaxCdrSerializedSize()); -#else - BitsetStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = BitsetStruct_max_key_cdr_typesize > 16 ? BitsetStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -BitsetStructPubSubType::~BitsetStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool BitsetStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - BitsetStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool BitsetStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - BitsetStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function BitsetStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* BitsetStructPubSubType::createData() -{ - return reinterpret_cast(new BitsetStruct()); -} - -void BitsetStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool BitsetStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - BitsetStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - BitsetStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || BitsetStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -StructStructPubSubType::StructStructPubSubType() -{ - setName("StructStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(StructStruct::getMaxCdrSerializedSize()); -#else - StructStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = StructStruct_max_key_cdr_typesize > 16 ? StructStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -StructStructPubSubType::~StructStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool StructStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - StructStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool StructStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - StructStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function StructStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* StructStructPubSubType::createData() -{ - return reinterpret_cast(new StructStruct()); -} - -void StructStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool StructStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - StructStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - StructStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || StructStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -StructStructStructPubSubType::StructStructStructPubSubType() -{ - setName("StructStructStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(StructStructStruct::getMaxCdrSerializedSize()); -#else - StructStructStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = StructStructStruct_max_key_cdr_typesize > 16 ? StructStructStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -StructStructStructPubSubType::~StructStructStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool StructStructStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - StructStructStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool StructStructStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - StructStructStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function StructStructStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* StructStructStructPubSubType::createData() -{ - return reinterpret_cast(new StructStructStruct()); -} - -void StructStructStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool StructStructStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - StructStructStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - StructStructStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || StructStructStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - - - - - - - - - - - - - -SimpleUnionStructPubSubType::SimpleUnionStructPubSubType() -{ - setName("SimpleUnionStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(SimpleUnionStruct::getMaxCdrSerializedSize()); -#else - SimpleUnionStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = SimpleUnionStruct_max_key_cdr_typesize > 16 ? SimpleUnionStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -SimpleUnionStructPubSubType::~SimpleUnionStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool SimpleUnionStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - SimpleUnionStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool SimpleUnionStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - SimpleUnionStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function SimpleUnionStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* SimpleUnionStructPubSubType::createData() -{ - return reinterpret_cast(new SimpleUnionStruct()); -} - -void SimpleUnionStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool SimpleUnionStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - SimpleUnionStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - SimpleUnionStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || SimpleUnionStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -UnionUnionUnionStructPubSubType::UnionUnionUnionStructPubSubType() -{ - setName("UnionUnionUnionStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(UnionUnionUnionStruct::getMaxCdrSerializedSize()); -#else - UnionUnionUnionStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = UnionUnionUnionStruct_max_key_cdr_typesize > 16 ? UnionUnionUnionStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -UnionUnionUnionStructPubSubType::~UnionUnionUnionStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool UnionUnionUnionStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - UnionUnionUnionStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool UnionUnionUnionStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - UnionUnionUnionStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function UnionUnionUnionStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* UnionUnionUnionStructPubSubType::createData() -{ - return reinterpret_cast(new UnionUnionUnionStruct()); -} - -void UnionUnionUnionStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool UnionUnionUnionStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - UnionUnionUnionStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - UnionUnionUnionStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || UnionUnionUnionStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -WCharUnionStructPubSubType::WCharUnionStructPubSubType() -{ - setName("WCharUnionStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(WCharUnionStruct::getMaxCdrSerializedSize()); -#else - WCharUnionStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = WCharUnionStruct_max_key_cdr_typesize > 16 ? WCharUnionStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -WCharUnionStructPubSubType::~WCharUnionStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool WCharUnionStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - WCharUnionStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool WCharUnionStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - WCharUnionStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function WCharUnionStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* WCharUnionStructPubSubType::createData() -{ - return reinterpret_cast(new WCharUnionStruct()); -} - -void WCharUnionStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool WCharUnionStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - WCharUnionStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - WCharUnionStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || WCharUnionStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - diff --git a/test/unittest/dynamic_types/idl/BasicPubSubTypes.h b/test/unittest/dynamic_types/idl/BasicPubSubTypes.h deleted file mode 100644 index 467e624b19b..00000000000 --- a/test/unittest/dynamic_types/idl/BasicPubSubTypes.h +++ /dev/null @@ -1,2950 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file BasicPubSubTypes.h - * This header file contains the declaration of the serialization functions. - * - * This file was generated by the tool fastddsgen. - */ - - -#ifndef _FAST_DDS_GENERATED_BASIC_PUBSUBTYPES_H_ -#define _FAST_DDS_GENERATED_BASIC_PUBSUBTYPES_H_ - -#include -#include -#include -#include -#include - -#include "Basic.h" - - -#if !defined(GEN_API_VER) || (GEN_API_VER != 2) -#error \ - Generated Basic is not compatible with current installed Fast DDS. Please, regenerate it with fastddsgen. -#endif // GEN_API_VER - -typedef MyEnum MyAliasEnum; -typedef MyAliasEnum MyAliasAliasEnum; - - - -/*! - * @brief This class represents the TopicDataType of the type EnumStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class EnumStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef EnumStruct type; - - eProsima_user_DllExport EnumStructPubSubType(); - - eProsima_user_DllExport ~EnumStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type AliasStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class AliasStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef AliasStruct type; - - eProsima_user_DllExport AliasStructPubSubType(); - - eProsima_user_DllExport ~AliasStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type AliasAliasStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class AliasAliasStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef AliasAliasStruct type; - - eProsima_user_DllExport AliasAliasStructPubSubType(); - - eProsima_user_DllExport ~AliasAliasStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type BoolStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class BoolStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef BoolStruct type; - - eProsima_user_DllExport BoolStructPubSubType(); - - eProsima_user_DllExport ~BoolStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type OctetStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class OctetStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef OctetStruct type; - - eProsima_user_DllExport OctetStructPubSubType(); - - eProsima_user_DllExport ~OctetStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type ShortStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class ShortStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef ShortStruct type; - - eProsima_user_DllExport ShortStructPubSubType(); - - eProsima_user_DllExport ~ShortStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type LongStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class LongStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef LongStruct type; - - eProsima_user_DllExport LongStructPubSubType(); - - eProsima_user_DllExport ~LongStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type LongLongStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class LongLongStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef LongLongStruct type; - - eProsima_user_DllExport LongLongStructPubSubType(); - - eProsima_user_DllExport ~LongLongStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type UShortStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class UShortStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef UShortStruct type; - - eProsima_user_DllExport UShortStructPubSubType(); - - eProsima_user_DllExport ~UShortStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type ULongStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class ULongStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef ULongStruct type; - - eProsima_user_DllExport ULongStructPubSubType(); - - eProsima_user_DllExport ~ULongStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type ULongLongStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class ULongLongStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef ULongLongStruct type; - - eProsima_user_DllExport ULongLongStructPubSubType(); - - eProsima_user_DllExport ~ULongLongStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type FloatStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class FloatStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef FloatStruct type; - - eProsima_user_DllExport FloatStructPubSubType(); - - eProsima_user_DllExport ~FloatStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type DoubleStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class DoubleStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef DoubleStruct type; - - eProsima_user_DllExport DoubleStructPubSubType(); - - eProsima_user_DllExport ~DoubleStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type LongDoubleStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class LongDoubleStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef LongDoubleStruct type; - - eProsima_user_DllExport LongDoubleStructPubSubType(); - - eProsima_user_DllExport ~LongDoubleStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type CharStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class CharStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef CharStruct type; - - eProsima_user_DllExport CharStructPubSubType(); - - eProsima_user_DllExport ~CharStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type WCharStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class WCharStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef WCharStruct type; - - eProsima_user_DllExport WCharStructPubSubType(); - - eProsima_user_DllExport ~WCharStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type StringStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class StringStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef StringStruct type; - - eProsima_user_DllExport StringStructPubSubType(); - - eProsima_user_DllExport ~StringStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type WStringStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class WStringStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef WStringStruct type; - - eProsima_user_DllExport WStringStructPubSubType(); - - eProsima_user_DllExport ~WStringStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type LargeStringStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class LargeStringStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef LargeStringStruct type; - - eProsima_user_DllExport LargeStringStructPubSubType(); - - eProsima_user_DllExport ~LargeStringStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type LargeWStringStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class LargeWStringStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef LargeWStringStruct type; - - eProsima_user_DllExport LargeWStringStructPubSubType(); - - eProsima_user_DllExport ~LargeWStringStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type ArraytStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class ArraytStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef ArraytStruct type; - - eProsima_user_DllExport ArraytStructPubSubType(); - - eProsima_user_DllExport ~ArraytStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; -typedef std::array, 2> MyArray; - - - -/*! - * @brief This class represents the TopicDataType of the type ArrayArrayStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class ArrayArrayStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef ArrayArrayStruct type; - - eProsima_user_DllExport ArrayArrayStructPubSubType(); - - eProsima_user_DllExport ~ArrayArrayStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - - - -/*! - * @brief This class represents the TopicDataType of the type SequenceStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class SequenceStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef SequenceStruct type; - - eProsima_user_DllExport SequenceStructPubSubType(); - - eProsima_user_DllExport ~SequenceStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - - - - - -/*! - * @brief This class represents the TopicDataType of the type SequenceSequenceStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class SequenceSequenceStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef SequenceSequenceStruct type; - - eProsima_user_DllExport SequenceSequenceStructPubSubType(); - - eProsima_user_DllExport ~SequenceSequenceStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - - - -/*! - * @brief This class represents the TopicDataType of the type MapStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class MapStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef MapStruct type; - - eProsima_user_DllExport MapStructPubSubType(); - - eProsima_user_DllExport ~MapStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - - - - - -/*! - * @brief This class represents the TopicDataType of the type MapMapStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class MapMapStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef MapMapStruct type; - - eProsima_user_DllExport MapMapStructPubSubType(); - - eProsima_user_DllExport ~MapMapStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - - -/*! - * @brief This class represents the TopicDataType of the type BitsetStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class BitsetStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef BitsetStruct type; - - eProsima_user_DllExport BitsetStructPubSubType(); - - eProsima_user_DllExport ~BitsetStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type StructStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class StructStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef StructStruct type; - - eProsima_user_DllExport StructStructPubSubType(); - - eProsima_user_DllExport ~StructStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type StructStructStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class StructStructStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef StructStructStruct type; - - eProsima_user_DllExport StructStructStructPubSubType(); - - eProsima_user_DllExport ~StructStructStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - - - - - - - - - - - - - -/*! - * @brief This class represents the TopicDataType of the type SimpleUnionStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class SimpleUnionStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef SimpleUnionStruct type; - - eProsima_user_DllExport SimpleUnionStructPubSubType(); - - eProsima_user_DllExport ~SimpleUnionStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type UnionUnionUnionStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class UnionUnionUnionStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef UnionUnionUnionStruct type; - - eProsima_user_DllExport UnionUnionUnionStructPubSubType(); - - eProsima_user_DllExport ~UnionUnionUnionStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type WCharUnionStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class WCharUnionStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef WCharUnionStruct type; - - eProsima_user_DllExport WCharUnionStructPubSubType(); - - eProsima_user_DllExport ~WCharUnionStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - -#endif // _FAST_DDS_GENERATED_BASIC_PUBSUBTYPES_H_ - diff --git a/test/unittest/dynamic_types/idl/BasicTypeObject.cxx b/test/unittest/dynamic_types/idl/BasicTypeObject.cxx deleted file mode 100644 index 282c8898fe4..00000000000 --- a/test/unittest/dynamic_types/idl/BasicTypeObject.cxx +++ /dev/null @@ -1,7817 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file BasicTypeObject.cpp - * This source file contains the definition of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { char dummy; } -#endif - -#include "Basic.h" -#include "BasicTypeObject.h" -#include -#include -#include -#include -#include -#include -#include -#include -#include - -using namespace eprosima::fastrtps::rtps; - -void registerBasicTypes() -{ - static std::once_flag once_flag; - std::call_once(once_flag, []() - { - TypeObjectFactory *factory = TypeObjectFactory::get_instance(); - factory->add_type_object("MyEnum", GetMyEnumIdentifier(true), - GetMyEnumObject(true)); - factory->add_type_object("MyEnum", GetMyEnumIdentifier(false), - GetMyEnumObject(false)); - - - factory->add_type_object("MyAliasEnum", GetMyAliasEnumIdentifier(true), - GetMyAliasEnumObject(true)); - factory->add_type_object("MyAliasEnum", GetMyAliasEnumIdentifier(false), - GetMyAliasEnumObject(false)); - - - factory->add_type_object("MyAliasAliasEnum", GetMyAliasAliasEnumIdentifier(true), - GetMyAliasAliasEnumObject(true)); - factory->add_type_object("MyAliasAliasEnum", GetMyAliasAliasEnumIdentifier(false), - GetMyAliasAliasEnumObject(false)); - - - factory->add_type_object("EnumStruct", GetEnumStructIdentifier(true), - GetEnumStructObject(true)); - factory->add_type_object("EnumStruct", GetEnumStructIdentifier(false), - GetEnumStructObject(false)); - - - factory->add_type_object("AliasStruct", GetAliasStructIdentifier(true), - GetAliasStructObject(true)); - factory->add_type_object("AliasStruct", GetAliasStructIdentifier(false), - GetAliasStructObject(false)); - - - factory->add_type_object("AliasAliasStruct", GetAliasAliasStructIdentifier(true), - GetAliasAliasStructObject(true)); - factory->add_type_object("AliasAliasStruct", GetAliasAliasStructIdentifier(false), - GetAliasAliasStructObject(false)); - - - factory->add_type_object("BoolStruct", GetBoolStructIdentifier(true), - GetBoolStructObject(true)); - factory->add_type_object("BoolStruct", GetBoolStructIdentifier(false), - GetBoolStructObject(false)); - - - factory->add_type_object("OctetStruct", GetOctetStructIdentifier(true), - GetOctetStructObject(true)); - factory->add_type_object("OctetStruct", GetOctetStructIdentifier(false), - GetOctetStructObject(false)); - - - factory->add_type_object("ShortStruct", GetShortStructIdentifier(true), - GetShortStructObject(true)); - factory->add_type_object("ShortStruct", GetShortStructIdentifier(false), - GetShortStructObject(false)); - - - factory->add_type_object("LongStruct", GetLongStructIdentifier(true), - GetLongStructObject(true)); - factory->add_type_object("LongStruct", GetLongStructIdentifier(false), - GetLongStructObject(false)); - - - factory->add_type_object("LongLongStruct", GetLongLongStructIdentifier(true), - GetLongLongStructObject(true)); - factory->add_type_object("LongLongStruct", GetLongLongStructIdentifier(false), - GetLongLongStructObject(false)); - - - factory->add_type_object("UShortStruct", GetUShortStructIdentifier(true), - GetUShortStructObject(true)); - factory->add_type_object("UShortStruct", GetUShortStructIdentifier(false), - GetUShortStructObject(false)); - - - factory->add_type_object("ULongStruct", GetULongStructIdentifier(true), - GetULongStructObject(true)); - factory->add_type_object("ULongStruct", GetULongStructIdentifier(false), - GetULongStructObject(false)); - - - factory->add_type_object("ULongLongStruct", GetULongLongStructIdentifier(true), - GetULongLongStructObject(true)); - factory->add_type_object("ULongLongStruct", GetULongLongStructIdentifier(false), - GetULongLongStructObject(false)); - - - factory->add_type_object("FloatStruct", GetFloatStructIdentifier(true), - GetFloatStructObject(true)); - factory->add_type_object("FloatStruct", GetFloatStructIdentifier(false), - GetFloatStructObject(false)); - - - factory->add_type_object("DoubleStruct", GetDoubleStructIdentifier(true), - GetDoubleStructObject(true)); - factory->add_type_object("DoubleStruct", GetDoubleStructIdentifier(false), - GetDoubleStructObject(false)); - - - factory->add_type_object("LongDoubleStruct", GetLongDoubleStructIdentifier(true), - GetLongDoubleStructObject(true)); - factory->add_type_object("LongDoubleStruct", GetLongDoubleStructIdentifier(false), - GetLongDoubleStructObject(false)); - - - factory->add_type_object("CharStruct", GetCharStructIdentifier(true), - GetCharStructObject(true)); - factory->add_type_object("CharStruct", GetCharStructIdentifier(false), - GetCharStructObject(false)); - - - factory->add_type_object("WCharStruct", GetWCharStructIdentifier(true), - GetWCharStructObject(true)); - factory->add_type_object("WCharStruct", GetWCharStructIdentifier(false), - GetWCharStructObject(false)); - - - factory->add_type_object("StringStruct", GetStringStructIdentifier(true), - GetStringStructObject(true)); - factory->add_type_object("StringStruct", GetStringStructIdentifier(false), - GetStringStructObject(false)); - - - factory->add_type_object("WStringStruct", GetWStringStructIdentifier(true), - GetWStringStructObject(true)); - factory->add_type_object("WStringStruct", GetWStringStructIdentifier(false), - GetWStringStructObject(false)); - - - factory->add_type_object("LargeStringStruct", GetLargeStringStructIdentifier(true), - GetLargeStringStructObject(true)); - factory->add_type_object("LargeStringStruct", GetLargeStringStructIdentifier(false), - GetLargeStringStructObject(false)); - - - factory->add_type_object("LargeWStringStruct", GetLargeWStringStructIdentifier(true), - GetLargeWStringStructObject(true)); - factory->add_type_object("LargeWStringStruct", GetLargeWStringStructIdentifier(false), - GetLargeWStringStructObject(false)); - - - factory->add_type_object("ArraytStruct", GetArraytStructIdentifier(true), - GetArraytStructObject(true)); - factory->add_type_object("ArraytStruct", GetArraytStructIdentifier(false), - GetArraytStructObject(false)); - - - factory->add_type_object("MyArray", GetMyArrayIdentifier(true), - GetMyArrayObject(true)); - factory->add_type_object("MyArray", GetMyArrayIdentifier(false), - GetMyArrayObject(false)); - - - factory->add_type_object("ArrayArrayStruct", GetArrayArrayStructIdentifier(true), - GetArrayArrayStructObject(true)); - factory->add_type_object("ArrayArrayStruct", GetArrayArrayStructIdentifier(false), - GetArrayArrayStructObject(false)); - - - factory->add_type_object("SequenceStruct", GetSequenceStructIdentifier(true), - GetSequenceStructObject(true)); - factory->add_type_object("SequenceStruct", GetSequenceStructIdentifier(false), - GetSequenceStructObject(false)); - - - factory->add_type_object("SequenceSequenceStruct", GetSequenceSequenceStructIdentifier(true), - GetSequenceSequenceStructObject(true)); - factory->add_type_object("SequenceSequenceStruct", GetSequenceSequenceStructIdentifier(false), - GetSequenceSequenceStructObject(false)); - - - factory->add_type_object("MapStruct", GetMapStructIdentifier(true), - GetMapStructObject(true)); - factory->add_type_object("MapStruct", GetMapStructIdentifier(false), - GetMapStructObject(false)); - - - factory->add_type_object("MapMapStruct", GetMapMapStructIdentifier(true), - GetMapMapStructObject(true)); - factory->add_type_object("MapMapStruct", GetMapMapStructIdentifier(false), - GetMapMapStructObject(false)); - - - factory->add_type_object("MyBitset", GetMyBitsetIdentifier(true), - GetMyBitsetObject(true)); - factory->add_type_object("MyBitset", GetMyBitsetIdentifier(false), - GetMyBitsetObject(false)); - - - factory->add_type_object("BitsetStruct", GetBitsetStructIdentifier(true), - GetBitsetStructObject(true)); - factory->add_type_object("BitsetStruct", GetBitsetStructIdentifier(false), - GetBitsetStructObject(false)); - - - factory->add_type_object("StructStruct", GetStructStructIdentifier(true), - GetStructStructObject(true)); - factory->add_type_object("StructStruct", GetStructStructIdentifier(false), - GetStructStructObject(false)); - - - factory->add_type_object("StructStructStruct", GetStructStructStructIdentifier(true), - GetStructStructStructObject(true)); - factory->add_type_object("StructStructStruct", GetStructStructStructIdentifier(false), - GetStructStructStructObject(false)); - - - factory->add_type_object("SimpleUnion", GetSimpleUnionIdentifier(true), - GetSimpleUnionObject(true)); - factory->add_type_object("SimpleUnion", GetSimpleUnionIdentifier(false), - GetSimpleUnionObject(false)); - - - factory->add_type_object("UnionUnion", GetUnionUnionIdentifier(true), - GetUnionUnionObject(true)); - factory->add_type_object("UnionUnion", GetUnionUnionIdentifier(false), - GetUnionUnionObject(false)); - - - factory->add_type_object("WCharUnion", GetWCharUnionIdentifier(true), - GetWCharUnionObject(true)); - factory->add_type_object("WCharUnion", GetWCharUnionIdentifier(false), - GetWCharUnionObject(false)); - - - factory->add_type_object("SimpleUnionStruct", GetSimpleUnionStructIdentifier(true), - GetSimpleUnionStructObject(true)); - factory->add_type_object("SimpleUnionStruct", GetSimpleUnionStructIdentifier(false), - GetSimpleUnionStructObject(false)); - - - factory->add_type_object("UnionUnionUnionStruct", GetUnionUnionUnionStructIdentifier(true), - GetUnionUnionUnionStructObject(true)); - factory->add_type_object("UnionUnionUnionStruct", GetUnionUnionUnionStructIdentifier(false), - GetUnionUnionUnionStructObject(false)); - - - factory->add_type_object("WCharUnionStruct", GetWCharUnionStructIdentifier(true), - GetWCharUnionStructObject(true)); - factory->add_type_object("WCharUnionStruct", GetWCharUnionStructIdentifier(false), - GetWCharUnionStructObject(false)); - - }); -} - -const TypeIdentifier* GetMyEnumIdentifier(bool complete) -{ - const TypeIdentifier* c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("MyEnum", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetMyEnumObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("MyEnum", complete); -} - -const TypeObject* GetMyEnumObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyEnum", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteMyEnumObject(); - } - // else - return GetMinimalMyEnumObject(); -} - -const TypeObject* GetMinimalMyEnumObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyEnum", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_ENUM); - - // No flags apply - //type_object->minimal().enumerated_type().enum_flags().IS_FINAL(false); - //type_object->minimal().enumerated_type().enum_flags().IS_APPENDABLE(false); - //type_object->minimal().enumerated_type().enum_flags().IS_MUTABLE(false); - //type_object->minimal().enumerated_type().enum_flags().IS_NESTED(false); - //type_object->minimal().enumerated_type().enum_flags().IS_AUTOID_HASH(false); - - type_object->minimal().enumerated_type().header().common().bit_bound(32); // TODO fixed by IDL, isn't? - - uint32_t value = 0; - MinimalEnumeratedLiteral mel_A; - mel_A.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - mel_A.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - mel_A.common().flags().IS_EXTERNAL(false); // Doesn't apply - mel_A.common().flags().IS_OPTIONAL(false); // Doesn't apply - mel_A.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mel_A.common().flags().IS_KEY(false); // Doesn't apply - mel_A.common().flags().IS_DEFAULT(false); - mel_A.common().value(value++); - MD5 A_hash("A"); - for(int i = 0; i < 4; ++i) - { - mel_A.detail().name_hash()[i] = A_hash.digest[i]; - } - type_object->minimal().enumerated_type().literal_seq().emplace_back(mel_A); - - MinimalEnumeratedLiteral mel_B; - mel_B.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - mel_B.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - mel_B.common().flags().IS_EXTERNAL(false); // Doesn't apply - mel_B.common().flags().IS_OPTIONAL(false); // Doesn't apply - mel_B.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mel_B.common().flags().IS_KEY(false); // Doesn't apply - mel_B.common().flags().IS_DEFAULT(false); - mel_B.common().value(value++); - MD5 B_hash("B"); - for(int i = 0; i < 4; ++i) - { - mel_B.detail().name_hash()[i] = B_hash.digest[i]; - } - type_object->minimal().enumerated_type().literal_seq().emplace_back(mel_B); - - MinimalEnumeratedLiteral mel_C; - mel_C.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - mel_C.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - mel_C.common().flags().IS_EXTERNAL(false); // Doesn't apply - mel_C.common().flags().IS_OPTIONAL(false); // Doesn't apply - mel_C.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mel_C.common().flags().IS_KEY(false); // Doesn't apply - mel_C.common().flags().IS_DEFAULT(false); - mel_C.common().value(value++); - MD5 C_hash("C"); - for(int i = 0; i < 4; ++i) - { - mel_C.detail().name_hash()[i] = C_hash.digest[i]; - } - type_object->minimal().enumerated_type().literal_seq().emplace_back(mel_C); - - - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().enumerated_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MyEnum", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyEnum", false); -} - -const TypeObject* GetCompleteMyEnumObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyEnum", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_ENUM); - - // No flags apply - //type_object->complete().enumerated_type().enum_flags().IS_FINAL(false); - //type_object->complete().enumerated_type().enum_flags().IS_APPENDABLE(false); - //type_object->complete().enumerated_type().enum_flags().IS_MUTABLE(false); - //type_object->complete().enumerated_type().enum_flags().IS_NESTED(false); - //type_object->complete().enumerated_type().enum_flags().IS_AUTOID_HASH(false); - - type_object->complete().enumerated_type().header().common().bit_bound(32); // TODO fixed by IDL, isn't? - type_object->complete().enumerated_type().header().detail().type_name("MyEnum"); - - uint32_t value = 0; - CompleteEnumeratedLiteral cel_A; - cel_A.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - cel_A.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - cel_A.common().flags().IS_EXTERNAL(false); // Doesn't apply - cel_A.common().flags().IS_OPTIONAL(false); // Doesn't apply - cel_A.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cel_A.common().flags().IS_KEY(false); // Doesn't apply - cel_A.common().flags().IS_DEFAULT(false); - cel_A.common().value(value++); - cel_A.detail().name("A"); - - type_object->complete().enumerated_type().literal_seq().emplace_back(cel_A); - - CompleteEnumeratedLiteral cel_B; - cel_B.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - cel_B.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - cel_B.common().flags().IS_EXTERNAL(false); // Doesn't apply - cel_B.common().flags().IS_OPTIONAL(false); // Doesn't apply - cel_B.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cel_B.common().flags().IS_KEY(false); // Doesn't apply - cel_B.common().flags().IS_DEFAULT(false); - cel_B.common().value(value++); - cel_B.detail().name("B"); - - type_object->complete().enumerated_type().literal_seq().emplace_back(cel_B); - - CompleteEnumeratedLiteral cel_C; - cel_C.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - cel_C.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - cel_C.common().flags().IS_EXTERNAL(false); // Doesn't apply - cel_C.common().flags().IS_OPTIONAL(false); // Doesn't apply - cel_C.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cel_C.common().flags().IS_KEY(false); // Doesn't apply - cel_C.common().flags().IS_DEFAULT(false); - cel_C.common().value(value++); - cel_C.detail().name("C"); - - type_object->complete().enumerated_type().literal_seq().emplace_back(cel_C); - - - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().enumerated_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MyEnum", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyEnum", true); -} - -const TypeIdentifier* GetMyAliasEnumIdentifier(bool complete) -{ - const TypeIdentifier* c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("MyAliasEnum", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetMyAliasEnumObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("MyAliasEnum", complete); -} - -const TypeObject* GetMyAliasEnumObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyAliasEnum", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteMyAliasEnumObject(); - } - else - { - return GetMinimalMyAliasEnumObject(); - } -} - -const TypeObject* GetMinimalMyAliasEnumObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyAliasEnum", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_ALIAS); - - // No flags apply - //type_object->minimal().alias_type().alias_flags().IS_FINAL(false); - //type_object->minimal().alias_type().alias_flags().IS_APPENDABLE(false); - //type_object->minimal().alias_type().alias_flags().IS_MUTABLE(false); - //type_object->minimal().alias_type().alias_flags().IS_NESTED(false); - //type_object->minimal().alias_type().alias_flags().IS_AUTOID_HASH(false); - - // type_object->minimal().alias_type().header()... Is empty - - // No flags apply - //type_object->minimal().alias_type().body().common().related_flags().TRY_CONSTRUCT1(false); - //type_object->minimal().alias_type().body().common().related_flags().TRY_CONSTRUCT2(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_EXTERNAL(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_OPTIONAL(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_MUST_UNDERSTAND(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_KEY(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_DEFAULT(false); - - // Must be defined already, if don't, may be an recursive alias - const TypeIdentifier *relatedType = TypeObjectFactory::get_instance()->get_type_identifier("MyEnum", false); - - - if (relatedType != nullptr) - { - type_object->minimal().alias_type().body().common().related_type() = *relatedType; // Make a copy - } - else - { - // Cannot determine base type - delete type_object; - return nullptr; - } - - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().alias_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - // Don't add our TypeIdentifier but our alias - TypeObjectFactory::get_instance()->add_alias("MyAliasEnum", "MyEnum"); - - TypeObjectFactory::get_instance()->add_type_object("MyAliasEnum", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyAliasEnum", false); -} - -const TypeObject* GetCompleteMyAliasEnumObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyAliasEnum", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_ALIAS); - - // No flags apply - //type_object->complete().alias_type().alias_flags().IS_FINAL(false); - //type_object->complete().alias_type().alias_flags().IS_APPENDABLE(false); - //type_object->complete().alias_type().alias_flags().IS_MUTABLE(false); - //type_object->complete().alias_type().alias_flags().IS_NESTED(false); - //type_object->complete().alias_type().alias_flags().IS_AUTOID_HASH(false); - - //type_object->complete().alias_type().header().detail().ann_builtin().verbatim().placement("placement"); - //type_object->complete().alias_type().header().detail().ann_builtin().verbatim().language("language"); - //type_object->complete().alias_type().header().detail().ann_builtin().verbatim().text("text"); - //type_object->complete().alias_type().header().detail().ann_custom().push_back(...); - type_object->complete().alias_type().header().detail().type_name("MyAliasEnum"); - - // No flags apply - //type_object->complete().alias_type().body().common().related_flags().TRY_CONSTRUCT1(false); - //type_object->complete().alias_type().body().common().related_flags().TRY_CONSTRUCT2(false); - //type_object->complete().alias_type().body().common().related_flags().IS_EXTERNAL(false); - //type_object->complete().alias_type().body().common().related_flags().IS_OPTIONAL(false); - //type_object->complete().alias_type().body().common().related_flags().IS_MUST_UNDERSTAND(false); - //type_object->complete().alias_type().body().common().related_flags().IS_KEY(false); - //type_object->complete().alias_type().body().common().related_flags().IS_DEFAULT(false); - - //type_object->complete().alias_type().body().common().ann_builtin() - //type_object->complete().alias_type().body().common().ann_custom() - - // Must be defined already, if don't, may be an recursive alias - const TypeIdentifier *relatedType = TypeObjectFactory::get_instance()->get_type_identifier_trying_complete("MyEnum"); - - - if (relatedType != nullptr) - { - type_object->complete().alias_type().body().common().related_type() = *relatedType; // Make a copy - } - else - { - // Cannot determine base type - delete type_object; - return nullptr; - } - - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().alias_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - // Don't add our TypeIdentifier but our alias - TypeObjectFactory::get_instance()->add_alias("MyAliasEnum", "MyEnum"); - - TypeObjectFactory::get_instance()->add_type_object("MyAliasEnum", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyAliasEnum", true); -} - -const TypeIdentifier* GetMyAliasAliasEnumIdentifier(bool complete) -{ - const TypeIdentifier* c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("MyAliasAliasEnum", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetMyAliasAliasEnumObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("MyAliasAliasEnum", complete); -} - -const TypeObject* GetMyAliasAliasEnumObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyAliasAliasEnum", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteMyAliasAliasEnumObject(); - } - else - { - return GetMinimalMyAliasAliasEnumObject(); - } -} - -const TypeObject* GetMinimalMyAliasAliasEnumObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyAliasAliasEnum", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_ALIAS); - - // No flags apply - //type_object->minimal().alias_type().alias_flags().IS_FINAL(false); - //type_object->minimal().alias_type().alias_flags().IS_APPENDABLE(false); - //type_object->minimal().alias_type().alias_flags().IS_MUTABLE(false); - //type_object->minimal().alias_type().alias_flags().IS_NESTED(false); - //type_object->minimal().alias_type().alias_flags().IS_AUTOID_HASH(false); - - // type_object->minimal().alias_type().header()... Is empty - - // No flags apply - //type_object->minimal().alias_type().body().common().related_flags().TRY_CONSTRUCT1(false); - //type_object->minimal().alias_type().body().common().related_flags().TRY_CONSTRUCT2(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_EXTERNAL(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_OPTIONAL(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_MUST_UNDERSTAND(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_KEY(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_DEFAULT(false); - - // Must be defined already, if don't, may be an recursive alias - const TypeIdentifier *relatedType = TypeObjectFactory::get_instance()->get_type_identifier("MyAliasEnum", false); - - - if (relatedType != nullptr) - { - type_object->minimal().alias_type().body().common().related_type() = *relatedType; // Make a copy - } - else - { - // Cannot determine base type - delete type_object; - return nullptr; - } - - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().alias_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - // Don't add our TypeIdentifier but our alias - TypeObjectFactory::get_instance()->add_alias("MyAliasAliasEnum", "MyAliasEnum"); - - TypeObjectFactory::get_instance()->add_type_object("MyAliasAliasEnum", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyAliasAliasEnum", false); -} - -const TypeObject* GetCompleteMyAliasAliasEnumObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyAliasAliasEnum", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_ALIAS); - - // No flags apply - //type_object->complete().alias_type().alias_flags().IS_FINAL(false); - //type_object->complete().alias_type().alias_flags().IS_APPENDABLE(false); - //type_object->complete().alias_type().alias_flags().IS_MUTABLE(false); - //type_object->complete().alias_type().alias_flags().IS_NESTED(false); - //type_object->complete().alias_type().alias_flags().IS_AUTOID_HASH(false); - - //type_object->complete().alias_type().header().detail().ann_builtin().verbatim().placement("placement"); - //type_object->complete().alias_type().header().detail().ann_builtin().verbatim().language("language"); - //type_object->complete().alias_type().header().detail().ann_builtin().verbatim().text("text"); - //type_object->complete().alias_type().header().detail().ann_custom().push_back(...); - type_object->complete().alias_type().header().detail().type_name("MyAliasAliasEnum"); - - // No flags apply - //type_object->complete().alias_type().body().common().related_flags().TRY_CONSTRUCT1(false); - //type_object->complete().alias_type().body().common().related_flags().TRY_CONSTRUCT2(false); - //type_object->complete().alias_type().body().common().related_flags().IS_EXTERNAL(false); - //type_object->complete().alias_type().body().common().related_flags().IS_OPTIONAL(false); - //type_object->complete().alias_type().body().common().related_flags().IS_MUST_UNDERSTAND(false); - //type_object->complete().alias_type().body().common().related_flags().IS_KEY(false); - //type_object->complete().alias_type().body().common().related_flags().IS_DEFAULT(false); - - //type_object->complete().alias_type().body().common().ann_builtin() - //type_object->complete().alias_type().body().common().ann_custom() - - // Must be defined already, if don't, may be an recursive alias - const TypeIdentifier *relatedType = TypeObjectFactory::get_instance()->get_type_identifier_trying_complete("MyAliasEnum"); - - - if (relatedType != nullptr) - { - type_object->complete().alias_type().body().common().related_type() = *relatedType; // Make a copy - } - else - { - // Cannot determine base type - delete type_object; - return nullptr; - } - - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().alias_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - // Don't add our TypeIdentifier but our alias - TypeObjectFactory::get_instance()->add_alias("MyAliasAliasEnum", "MyAliasEnum"); - - TypeObjectFactory::get_instance()->add_type_object("MyAliasAliasEnum", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyAliasAliasEnum", true); -} - - - -const TypeIdentifier* GetEnumStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("EnumStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetEnumStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("EnumStruct", complete); -} - -const TypeObject* GetEnumStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("EnumStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteEnumStructObject(); - } - //else - return GetMinimalEnumStructObject(); -} - -const TypeObject* GetMinimalEnumStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("EnumStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_enum; - mst_my_enum.common().member_id(memberId++); - mst_my_enum.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_enum.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_enum.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_enum.common().member_flags().IS_OPTIONAL(false); - mst_my_enum.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_enum.common().member_flags().IS_KEY(false); - mst_my_enum.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_enum.common().member_type_id(*GetMyEnumIdentifier(false)); - - MD5 my_enum_hash("my_enum"); - for(int i = 0; i < 4; ++i) - { - mst_my_enum.detail().name_hash()[i] = my_enum_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_enum); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("EnumStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("EnumStruct", false); -} - -const TypeObject* GetCompleteEnumStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("EnumStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_enum; - cst_my_enum.common().member_id(memberId++); - cst_my_enum.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_enum.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_enum.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_enum.common().member_flags().IS_OPTIONAL(false); - cst_my_enum.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_enum.common().member_flags().IS_KEY(false); - cst_my_enum.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_enum.common().member_type_id(*GetMyEnumIdentifier(true)); - - cst_my_enum.detail().name("my_enum"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_enum); - - - // Header - type_object->complete().struct_type().header().detail().type_name("EnumStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("EnumStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("EnumStruct", true); -} - - - -const TypeIdentifier* GetAliasStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("AliasStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetAliasStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("AliasStruct", complete); -} - -const TypeObject* GetAliasStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("AliasStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteAliasStructObject(); - } - //else - return GetMinimalAliasStructObject(); -} - -const TypeObject* GetMinimalAliasStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("AliasStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_alias; - mst_my_alias.common().member_id(memberId++); - mst_my_alias.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_alias.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_alias.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_alias.common().member_flags().IS_OPTIONAL(false); - mst_my_alias.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_alias.common().member_flags().IS_KEY(false); - mst_my_alias.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_alias.common().member_type_id(*GetMyAliasEnumIdentifier(false)); - - MD5 my_alias_hash("my_alias"); - for(int i = 0; i < 4; ++i) - { - mst_my_alias.detail().name_hash()[i] = my_alias_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_alias); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("AliasStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("AliasStruct", false); -} - -const TypeObject* GetCompleteAliasStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("AliasStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_alias; - cst_my_alias.common().member_id(memberId++); - cst_my_alias.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_alias.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_alias.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_alias.common().member_flags().IS_OPTIONAL(false); - cst_my_alias.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_alias.common().member_flags().IS_KEY(false); - cst_my_alias.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_alias.common().member_type_id(*GetMyAliasEnumIdentifier(true)); - - cst_my_alias.detail().name("my_alias"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_alias); - - - // Header - type_object->complete().struct_type().header().detail().type_name("AliasStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("AliasStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("AliasStruct", true); -} - - - -const TypeIdentifier* GetAliasAliasStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("AliasAliasStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetAliasAliasStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("AliasAliasStruct", complete); -} - -const TypeObject* GetAliasAliasStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("AliasAliasStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteAliasAliasStructObject(); - } - //else - return GetMinimalAliasAliasStructObject(); -} - -const TypeObject* GetMinimalAliasAliasStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("AliasAliasStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_alias_alias; - mst_my_alias_alias.common().member_id(memberId++); - mst_my_alias_alias.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_alias_alias.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_alias_alias.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_alias_alias.common().member_flags().IS_OPTIONAL(false); - mst_my_alias_alias.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_alias_alias.common().member_flags().IS_KEY(false); - mst_my_alias_alias.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_alias_alias.common().member_type_id(*GetMyAliasAliasEnumIdentifier(false)); - - MD5 my_alias_alias_hash("my_alias_alias"); - for(int i = 0; i < 4; ++i) - { - mst_my_alias_alias.detail().name_hash()[i] = my_alias_alias_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_alias_alias); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("AliasAliasStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("AliasAliasStruct", false); -} - -const TypeObject* GetCompleteAliasAliasStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("AliasAliasStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_alias_alias; - cst_my_alias_alias.common().member_id(memberId++); - cst_my_alias_alias.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_alias_alias.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_alias_alias.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_alias_alias.common().member_flags().IS_OPTIONAL(false); - cst_my_alias_alias.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_alias_alias.common().member_flags().IS_KEY(false); - cst_my_alias_alias.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_alias_alias.common().member_type_id(*GetMyAliasAliasEnumIdentifier(true)); - - cst_my_alias_alias.detail().name("my_alias_alias"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_alias_alias); - - - // Header - type_object->complete().struct_type().header().detail().type_name("AliasAliasStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("AliasAliasStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("AliasAliasStruct", true); -} - - - -const TypeIdentifier* GetBoolStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("BoolStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetBoolStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("BoolStruct", complete); -} - -const TypeObject* GetBoolStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("BoolStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteBoolStructObject(); - } - //else - return GetMinimalBoolStructObject(); -} - -const TypeObject* GetMinimalBoolStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("BoolStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_bool; - mst_my_bool.common().member_id(memberId++); - mst_my_bool.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_bool.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_bool.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_bool.common().member_flags().IS_OPTIONAL(false); - mst_my_bool.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_bool.common().member_flags().IS_KEY(false); - mst_my_bool.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_bool.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("bool", false)); - - - MD5 my_bool_hash("my_bool"); - for(int i = 0; i < 4; ++i) - { - mst_my_bool.detail().name_hash()[i] = my_bool_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_bool); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("BoolStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("BoolStruct", false); -} - -const TypeObject* GetCompleteBoolStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("BoolStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_bool; - cst_my_bool.common().member_id(memberId++); - cst_my_bool.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_bool.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_bool.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_bool.common().member_flags().IS_OPTIONAL(false); - cst_my_bool.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_bool.common().member_flags().IS_KEY(false); - cst_my_bool.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_bool.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("bool", false)); - - - cst_my_bool.detail().name("my_bool"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_bool); - - - // Header - type_object->complete().struct_type().header().detail().type_name("BoolStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("BoolStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("BoolStruct", true); -} - - - -const TypeIdentifier* GetOctetStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("OctetStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetOctetStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("OctetStruct", complete); -} - -const TypeObject* GetOctetStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("OctetStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteOctetStructObject(); - } - //else - return GetMinimalOctetStructObject(); -} - -const TypeObject* GetMinimalOctetStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("OctetStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_octet; - mst_my_octet.common().member_id(memberId++); - mst_my_octet.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_octet.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_octet.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_octet.common().member_flags().IS_OPTIONAL(false); - mst_my_octet.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_octet.common().member_flags().IS_KEY(false); - mst_my_octet.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_octet.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint8_t", false)); - - - MD5 my_octet_hash("my_octet"); - for(int i = 0; i < 4; ++i) - { - mst_my_octet.detail().name_hash()[i] = my_octet_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_octet); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("OctetStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("OctetStruct", false); -} - -const TypeObject* GetCompleteOctetStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("OctetStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_octet; - cst_my_octet.common().member_id(memberId++); - cst_my_octet.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_octet.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_octet.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_octet.common().member_flags().IS_OPTIONAL(false); - cst_my_octet.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_octet.common().member_flags().IS_KEY(false); - cst_my_octet.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_octet.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint8_t", false)); - - - cst_my_octet.detail().name("my_octet"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_octet); - - - // Header - type_object->complete().struct_type().header().detail().type_name("OctetStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("OctetStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("OctetStruct", true); -} - - - -const TypeIdentifier* GetShortStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("ShortStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetShortStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("ShortStruct", complete); -} - -const TypeObject* GetShortStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ShortStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteShortStructObject(); - } - //else - return GetMinimalShortStructObject(); -} - -const TypeObject* GetMinimalShortStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ShortStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_int16; - mst_my_int16.common().member_id(memberId++); - mst_my_int16.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_int16.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_int16.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_int16.common().member_flags().IS_OPTIONAL(false); - mst_my_int16.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_int16.common().member_flags().IS_KEY(false); - mst_my_int16.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_int16.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int16_t", false)); - - - MD5 my_int16_hash("my_int16"); - for(int i = 0; i < 4; ++i) - { - mst_my_int16.detail().name_hash()[i] = my_int16_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_int16); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("ShortStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("ShortStruct", false); -} - -const TypeObject* GetCompleteShortStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ShortStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_int16; - cst_my_int16.common().member_id(memberId++); - cst_my_int16.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_int16.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_int16.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_int16.common().member_flags().IS_OPTIONAL(false); - cst_my_int16.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_int16.common().member_flags().IS_KEY(false); - cst_my_int16.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_int16.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int16_t", false)); - - - cst_my_int16.detail().name("my_int16"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_int16); - - - // Header - type_object->complete().struct_type().header().detail().type_name("ShortStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("ShortStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("ShortStruct", true); -} - - - -const TypeIdentifier* GetLongStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("LongStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetLongStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("LongStruct", complete); -} - -const TypeObject* GetLongStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("LongStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteLongStructObject(); - } - //else - return GetMinimalLongStructObject(); -} - -const TypeObject* GetMinimalLongStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("LongStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_int32; - mst_my_int32.common().member_id(memberId++); - mst_my_int32.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_int32.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_int32.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_int32.common().member_flags().IS_OPTIONAL(false); - mst_my_int32.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_int32.common().member_flags().IS_KEY(false); - mst_my_int32.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_int32.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - MD5 my_int32_hash("my_int32"); - for(int i = 0; i < 4; ++i) - { - mst_my_int32.detail().name_hash()[i] = my_int32_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_int32); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("LongStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("LongStruct", false); -} - -const TypeObject* GetCompleteLongStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("LongStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_int32; - cst_my_int32.common().member_id(memberId++); - cst_my_int32.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_int32.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_int32.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_int32.common().member_flags().IS_OPTIONAL(false); - cst_my_int32.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_int32.common().member_flags().IS_KEY(false); - cst_my_int32.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_int32.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - cst_my_int32.detail().name("my_int32"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_int32); - - - // Header - type_object->complete().struct_type().header().detail().type_name("LongStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("LongStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("LongStruct", true); -} - - - -const TypeIdentifier* GetLongLongStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("LongLongStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetLongLongStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("LongLongStruct", complete); -} - -const TypeObject* GetLongLongStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("LongLongStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteLongLongStructObject(); - } - //else - return GetMinimalLongLongStructObject(); -} - -const TypeObject* GetMinimalLongLongStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("LongLongStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_int64; - mst_my_int64.common().member_id(memberId++); - mst_my_int64.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_int64.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_int64.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_int64.common().member_flags().IS_OPTIONAL(false); - mst_my_int64.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_int64.common().member_flags().IS_KEY(false); - mst_my_int64.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_int64.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int64_t", false)); - - - MD5 my_int64_hash("my_int64"); - for(int i = 0; i < 4; ++i) - { - mst_my_int64.detail().name_hash()[i] = my_int64_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_int64); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("LongLongStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("LongLongStruct", false); -} - -const TypeObject* GetCompleteLongLongStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("LongLongStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_int64; - cst_my_int64.common().member_id(memberId++); - cst_my_int64.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_int64.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_int64.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_int64.common().member_flags().IS_OPTIONAL(false); - cst_my_int64.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_int64.common().member_flags().IS_KEY(false); - cst_my_int64.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_int64.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int64_t", false)); - - - cst_my_int64.detail().name("my_int64"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_int64); - - - // Header - type_object->complete().struct_type().header().detail().type_name("LongLongStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("LongLongStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("LongLongStruct", true); -} - - - -const TypeIdentifier* GetUShortStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("UShortStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetUShortStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("UShortStruct", complete); -} - -const TypeObject* GetUShortStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("UShortStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteUShortStructObject(); - } - //else - return GetMinimalUShortStructObject(); -} - -const TypeObject* GetMinimalUShortStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("UShortStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_uint16; - mst_my_uint16.common().member_id(memberId++); - mst_my_uint16.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_uint16.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_uint16.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_uint16.common().member_flags().IS_OPTIONAL(false); - mst_my_uint16.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_uint16.common().member_flags().IS_KEY(false); - mst_my_uint16.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_uint16.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint16_t", false)); - - - MD5 my_uint16_hash("my_uint16"); - for(int i = 0; i < 4; ++i) - { - mst_my_uint16.detail().name_hash()[i] = my_uint16_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_uint16); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("UShortStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("UShortStruct", false); -} - -const TypeObject* GetCompleteUShortStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("UShortStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_uint16; - cst_my_uint16.common().member_id(memberId++); - cst_my_uint16.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_uint16.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_uint16.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_uint16.common().member_flags().IS_OPTIONAL(false); - cst_my_uint16.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_uint16.common().member_flags().IS_KEY(false); - cst_my_uint16.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_uint16.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint16_t", false)); - - - cst_my_uint16.detail().name("my_uint16"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_uint16); - - - // Header - type_object->complete().struct_type().header().detail().type_name("UShortStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("UShortStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("UShortStruct", true); -} - - - -const TypeIdentifier* GetULongStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("ULongStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetULongStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("ULongStruct", complete); -} - -const TypeObject* GetULongStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ULongStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteULongStructObject(); - } - //else - return GetMinimalULongStructObject(); -} - -const TypeObject* GetMinimalULongStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ULongStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_uint32; - mst_my_uint32.common().member_id(memberId++); - mst_my_uint32.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_uint32.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_uint32.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_uint32.common().member_flags().IS_OPTIONAL(false); - mst_my_uint32.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_uint32.common().member_flags().IS_KEY(false); - mst_my_uint32.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_uint32.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint32_t", false)); - - - MD5 my_uint32_hash("my_uint32"); - for(int i = 0; i < 4; ++i) - { - mst_my_uint32.detail().name_hash()[i] = my_uint32_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_uint32); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("ULongStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("ULongStruct", false); -} - -const TypeObject* GetCompleteULongStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ULongStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_uint32; - cst_my_uint32.common().member_id(memberId++); - cst_my_uint32.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_uint32.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_uint32.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_uint32.common().member_flags().IS_OPTIONAL(false); - cst_my_uint32.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_uint32.common().member_flags().IS_KEY(false); - cst_my_uint32.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_uint32.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint32_t", false)); - - - cst_my_uint32.detail().name("my_uint32"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_uint32); - - - // Header - type_object->complete().struct_type().header().detail().type_name("ULongStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("ULongStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("ULongStruct", true); -} - - - -const TypeIdentifier* GetULongLongStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("ULongLongStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetULongLongStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("ULongLongStruct", complete); -} - -const TypeObject* GetULongLongStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ULongLongStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteULongLongStructObject(); - } - //else - return GetMinimalULongLongStructObject(); -} - -const TypeObject* GetMinimalULongLongStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ULongLongStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_uint64; - mst_my_uint64.common().member_id(memberId++); - mst_my_uint64.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_uint64.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_uint64.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_uint64.common().member_flags().IS_OPTIONAL(false); - mst_my_uint64.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_uint64.common().member_flags().IS_KEY(false); - mst_my_uint64.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_uint64.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint64_t", false)); - - - MD5 my_uint64_hash("my_uint64"); - for(int i = 0; i < 4; ++i) - { - mst_my_uint64.detail().name_hash()[i] = my_uint64_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_uint64); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("ULongLongStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("ULongLongStruct", false); -} - -const TypeObject* GetCompleteULongLongStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ULongLongStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_uint64; - cst_my_uint64.common().member_id(memberId++); - cst_my_uint64.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_uint64.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_uint64.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_uint64.common().member_flags().IS_OPTIONAL(false); - cst_my_uint64.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_uint64.common().member_flags().IS_KEY(false); - cst_my_uint64.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_uint64.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint64_t", false)); - - - cst_my_uint64.detail().name("my_uint64"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_uint64); - - - // Header - type_object->complete().struct_type().header().detail().type_name("ULongLongStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("ULongLongStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("ULongLongStruct", true); -} - - - -const TypeIdentifier* GetFloatStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("FloatStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetFloatStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("FloatStruct", complete); -} - -const TypeObject* GetFloatStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("FloatStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteFloatStructObject(); - } - //else - return GetMinimalFloatStructObject(); -} - -const TypeObject* GetMinimalFloatStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("FloatStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_float32; - mst_my_float32.common().member_id(memberId++); - mst_my_float32.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_float32.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_float32.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_float32.common().member_flags().IS_OPTIONAL(false); - mst_my_float32.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_float32.common().member_flags().IS_KEY(false); - mst_my_float32.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_float32.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("float", false)); - - - MD5 my_float32_hash("my_float32"); - for(int i = 0; i < 4; ++i) - { - mst_my_float32.detail().name_hash()[i] = my_float32_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_float32); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("FloatStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("FloatStruct", false); -} - -const TypeObject* GetCompleteFloatStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("FloatStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_float32; - cst_my_float32.common().member_id(memberId++); - cst_my_float32.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_float32.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_float32.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_float32.common().member_flags().IS_OPTIONAL(false); - cst_my_float32.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_float32.common().member_flags().IS_KEY(false); - cst_my_float32.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_float32.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("float", false)); - - - cst_my_float32.detail().name("my_float32"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_float32); - - - // Header - type_object->complete().struct_type().header().detail().type_name("FloatStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("FloatStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("FloatStruct", true); -} - - - -const TypeIdentifier* GetDoubleStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("DoubleStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetDoubleStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("DoubleStruct", complete); -} - -const TypeObject* GetDoubleStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("DoubleStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteDoubleStructObject(); - } - //else - return GetMinimalDoubleStructObject(); -} - -const TypeObject* GetMinimalDoubleStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("DoubleStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_float64; - mst_my_float64.common().member_id(memberId++); - mst_my_float64.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_float64.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_float64.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_float64.common().member_flags().IS_OPTIONAL(false); - mst_my_float64.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_float64.common().member_flags().IS_KEY(false); - mst_my_float64.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_float64.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("double", false)); - - - MD5 my_float64_hash("my_float64"); - for(int i = 0; i < 4; ++i) - { - mst_my_float64.detail().name_hash()[i] = my_float64_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_float64); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("DoubleStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("DoubleStruct", false); -} - -const TypeObject* GetCompleteDoubleStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("DoubleStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_float64; - cst_my_float64.common().member_id(memberId++); - cst_my_float64.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_float64.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_float64.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_float64.common().member_flags().IS_OPTIONAL(false); - cst_my_float64.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_float64.common().member_flags().IS_KEY(false); - cst_my_float64.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_float64.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("double", false)); - - - cst_my_float64.detail().name("my_float64"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_float64); - - - // Header - type_object->complete().struct_type().header().detail().type_name("DoubleStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("DoubleStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("DoubleStruct", true); -} - - - -const TypeIdentifier* GetLongDoubleStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("LongDoubleStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetLongDoubleStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("LongDoubleStruct", complete); -} - -const TypeObject* GetLongDoubleStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("LongDoubleStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteLongDoubleStructObject(); - } - //else - return GetMinimalLongDoubleStructObject(); -} - -const TypeObject* GetMinimalLongDoubleStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("LongDoubleStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_float128; - mst_my_float128.common().member_id(memberId++); - mst_my_float128.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_float128.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_float128.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_float128.common().member_flags().IS_OPTIONAL(false); - mst_my_float128.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_float128.common().member_flags().IS_KEY(false); - mst_my_float128.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_float128.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("longdouble", false)); - - - MD5 my_float128_hash("my_float128"); - for(int i = 0; i < 4; ++i) - { - mst_my_float128.detail().name_hash()[i] = my_float128_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_float128); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("LongDoubleStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("LongDoubleStruct", false); -} - -const TypeObject* GetCompleteLongDoubleStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("LongDoubleStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_float128; - cst_my_float128.common().member_id(memberId++); - cst_my_float128.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_float128.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_float128.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_float128.common().member_flags().IS_OPTIONAL(false); - cst_my_float128.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_float128.common().member_flags().IS_KEY(false); - cst_my_float128.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_float128.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("longdouble", false)); - - - cst_my_float128.detail().name("my_float128"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_float128); - - - // Header - type_object->complete().struct_type().header().detail().type_name("LongDoubleStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("LongDoubleStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("LongDoubleStruct", true); -} - - - -const TypeIdentifier* GetCharStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("CharStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetCharStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("CharStruct", complete); -} - -const TypeObject* GetCharStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("CharStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteCharStructObject(); - } - //else - return GetMinimalCharStructObject(); -} - -const TypeObject* GetMinimalCharStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("CharStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_char; - mst_my_char.common().member_id(memberId++); - mst_my_char.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_char.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_char.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_char.common().member_flags().IS_OPTIONAL(false); - mst_my_char.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_char.common().member_flags().IS_KEY(false); - mst_my_char.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_char.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("char", false)); - - - MD5 my_char_hash("my_char"); - for(int i = 0; i < 4; ++i) - { - mst_my_char.detail().name_hash()[i] = my_char_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_char); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("CharStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("CharStruct", false); -} - -const TypeObject* GetCompleteCharStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("CharStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_char; - cst_my_char.common().member_id(memberId++); - cst_my_char.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_char.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_char.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_char.common().member_flags().IS_OPTIONAL(false); - cst_my_char.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_char.common().member_flags().IS_KEY(false); - cst_my_char.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_char.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("char", false)); - - - cst_my_char.detail().name("my_char"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_char); - - - // Header - type_object->complete().struct_type().header().detail().type_name("CharStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("CharStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("CharStruct", true); -} - - - -const TypeIdentifier* GetWCharStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("WCharStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetWCharStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("WCharStruct", complete); -} - -const TypeObject* GetWCharStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("WCharStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteWCharStructObject(); - } - //else - return GetMinimalWCharStructObject(); -} - -const TypeObject* GetMinimalWCharStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("WCharStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_wchar; - mst_my_wchar.common().member_id(memberId++); - mst_my_wchar.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_wchar.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_wchar.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_wchar.common().member_flags().IS_OPTIONAL(false); - mst_my_wchar.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_wchar.common().member_flags().IS_KEY(false); - mst_my_wchar.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_wchar.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("wchar_t", false)); - - - MD5 my_wchar_hash("my_wchar"); - for(int i = 0; i < 4; ++i) - { - mst_my_wchar.detail().name_hash()[i] = my_wchar_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_wchar); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("WCharStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("WCharStruct", false); -} - -const TypeObject* GetCompleteWCharStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("WCharStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_wchar; - cst_my_wchar.common().member_id(memberId++); - cst_my_wchar.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_wchar.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_wchar.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_wchar.common().member_flags().IS_OPTIONAL(false); - cst_my_wchar.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_wchar.common().member_flags().IS_KEY(false); - cst_my_wchar.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_wchar.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("wchar_t", false)); - - - cst_my_wchar.detail().name("my_wchar"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_wchar); - - - // Header - type_object->complete().struct_type().header().detail().type_name("WCharStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("WCharStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("WCharStruct", true); -} - - - -const TypeIdentifier* GetStringStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("StringStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetStringStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("StringStruct", complete); -} - -const TypeObject* GetStringStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("StringStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteStringStructObject(); - } - //else - return GetMinimalStringStructObject(); -} - -const TypeObject* GetMinimalStringStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("StringStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_string; - mst_my_string.common().member_id(memberId++); - mst_my_string.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_string.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_string.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_string.common().member_flags().IS_OPTIONAL(false); - mst_my_string.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_string.common().member_flags().IS_KEY(false); - mst_my_string.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_string.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, false)); - - MD5 my_string_hash("my_string"); - for(int i = 0; i < 4; ++i) - { - mst_my_string.detail().name_hash()[i] = my_string_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_string); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("StringStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("StringStruct", false); -} - -const TypeObject* GetCompleteStringStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("StringStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_string; - cst_my_string.common().member_id(memberId++); - cst_my_string.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_string.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_string.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_string.common().member_flags().IS_OPTIONAL(false); - cst_my_string.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_string.common().member_flags().IS_KEY(false); - cst_my_string.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_string.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, false)); - - cst_my_string.detail().name("my_string"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_string); - - - // Header - type_object->complete().struct_type().header().detail().type_name("StringStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("StringStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("StringStruct", true); -} - - - -const TypeIdentifier* GetWStringStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("WStringStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetWStringStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("WStringStruct", complete); -} - -const TypeObject* GetWStringStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("WStringStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteWStringStructObject(); - } - //else - return GetMinimalWStringStructObject(); -} - -const TypeObject* GetMinimalWStringStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("WStringStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_wstring; - mst_my_wstring.common().member_id(memberId++); - mst_my_wstring.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_wstring.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_wstring.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_wstring.common().member_flags().IS_OPTIONAL(false); - mst_my_wstring.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_wstring.common().member_flags().IS_KEY(false); - mst_my_wstring.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_wstring.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, true)); - - MD5 my_wstring_hash("my_wstring"); - for(int i = 0; i < 4; ++i) - { - mst_my_wstring.detail().name_hash()[i] = my_wstring_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_wstring); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("WStringStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("WStringStruct", false); -} - -const TypeObject* GetCompleteWStringStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("WStringStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_wstring; - cst_my_wstring.common().member_id(memberId++); - cst_my_wstring.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_wstring.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_wstring.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_wstring.common().member_flags().IS_OPTIONAL(false); - cst_my_wstring.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_wstring.common().member_flags().IS_KEY(false); - cst_my_wstring.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_wstring.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, true)); - - cst_my_wstring.detail().name("my_wstring"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_wstring); - - - // Header - type_object->complete().struct_type().header().detail().type_name("WStringStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("WStringStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("WStringStruct", true); -} - - - -const TypeIdentifier* GetLargeStringStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("LargeStringStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetLargeStringStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("LargeStringStruct", complete); -} - -const TypeObject* GetLargeStringStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("LargeStringStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteLargeStringStructObject(); - } - //else - return GetMinimalLargeStringStructObject(); -} - -const TypeObject* GetMinimalLargeStringStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("LargeStringStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_large_string; - mst_my_large_string.common().member_id(memberId++); - mst_my_large_string.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_large_string.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_large_string.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_large_string.common().member_flags().IS_OPTIONAL(false); - mst_my_large_string.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_large_string.common().member_flags().IS_KEY(false); - mst_my_large_string.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_large_string.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(41925, false)); - - MD5 my_large_string_hash("my_large_string"); - for(int i = 0; i < 4; ++i) - { - mst_my_large_string.detail().name_hash()[i] = my_large_string_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_large_string); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("LargeStringStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("LargeStringStruct", false); -} - -const TypeObject* GetCompleteLargeStringStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("LargeStringStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_large_string; - cst_my_large_string.common().member_id(memberId++); - cst_my_large_string.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_large_string.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_large_string.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_large_string.common().member_flags().IS_OPTIONAL(false); - cst_my_large_string.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_large_string.common().member_flags().IS_KEY(false); - cst_my_large_string.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_large_string.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(41925, false)); - - cst_my_large_string.detail().name("my_large_string"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_large_string); - - - // Header - type_object->complete().struct_type().header().detail().type_name("LargeStringStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("LargeStringStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("LargeStringStruct", true); -} - - - -const TypeIdentifier* GetLargeWStringStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("LargeWStringStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetLargeWStringStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("LargeWStringStruct", complete); -} - -const TypeObject* GetLargeWStringStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("LargeWStringStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteLargeWStringStructObject(); - } - //else - return GetMinimalLargeWStringStructObject(); -} - -const TypeObject* GetMinimalLargeWStringStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("LargeWStringStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_large_wstring; - mst_my_large_wstring.common().member_id(memberId++); - mst_my_large_wstring.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_large_wstring.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_large_wstring.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_large_wstring.common().member_flags().IS_OPTIONAL(false); - mst_my_large_wstring.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_large_wstring.common().member_flags().IS_KEY(false); - mst_my_large_wstring.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_large_wstring.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(41925, true)); - - MD5 my_large_wstring_hash("my_large_wstring"); - for(int i = 0; i < 4; ++i) - { - mst_my_large_wstring.detail().name_hash()[i] = my_large_wstring_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_large_wstring); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("LargeWStringStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("LargeWStringStruct", false); -} - -const TypeObject* GetCompleteLargeWStringStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("LargeWStringStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_large_wstring; - cst_my_large_wstring.common().member_id(memberId++); - cst_my_large_wstring.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_large_wstring.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_large_wstring.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_large_wstring.common().member_flags().IS_OPTIONAL(false); - cst_my_large_wstring.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_large_wstring.common().member_flags().IS_KEY(false); - cst_my_large_wstring.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_large_wstring.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(41925, true)); - - cst_my_large_wstring.detail().name("my_large_wstring"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_large_wstring); - - - // Header - type_object->complete().struct_type().header().detail().type_name("LargeWStringStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("LargeWStringStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("LargeWStringStruct", true); -} - - - -const TypeIdentifier* GetArraytStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("ArraytStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetArraytStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("ArraytStruct", complete); -} - -const TypeObject* GetArraytStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ArraytStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteArraytStructObject(); - } - //else - return GetMinimalArraytStructObject(); -} - -const TypeObject* GetMinimalArraytStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ArraytStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_array; - mst_my_array.common().member_id(memberId++); - mst_my_array.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_array.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_array.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_array.common().member_flags().IS_OPTIONAL(false); - mst_my_array.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_array.common().member_flags().IS_KEY(false); - mst_my_array.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_array.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("int32_t", {2, 2, 2}, false)); - - MD5 my_array_hash("my_array"); - for(int i = 0; i < 4; ++i) - { - mst_my_array.detail().name_hash()[i] = my_array_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_array); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("ArraytStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("ArraytStruct", false); -} - -const TypeObject* GetCompleteArraytStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ArraytStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_array; - cst_my_array.common().member_id(memberId++); - cst_my_array.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_array.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_array.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_array.common().member_flags().IS_OPTIONAL(false); - cst_my_array.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_array.common().member_flags().IS_KEY(false); - cst_my_array.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_array.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("int32_t", {2, 2, 2}, true)); - - cst_my_array.detail().name("my_array"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_array); - - - // Header - type_object->complete().struct_type().header().detail().type_name("ArraytStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("ArraytStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("ArraytStruct", true); -} - -const TypeIdentifier* GetMyArrayIdentifier(bool complete) -{ - const TypeIdentifier* c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("MyArray", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetMyArrayObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("MyArray", complete); -} - -const TypeObject* GetMyArrayObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyArray", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteMyArrayObject(); - } - else - { - return GetMinimalMyArrayObject(); - } -} - -const TypeObject* GetMinimalMyArrayObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyArray", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_ALIAS); - - // No flags apply - //type_object->minimal().alias_type().alias_flags().IS_FINAL(false); - //type_object->minimal().alias_type().alias_flags().IS_APPENDABLE(false); - //type_object->minimal().alias_type().alias_flags().IS_MUTABLE(false); - //type_object->minimal().alias_type().alias_flags().IS_NESTED(false); - //type_object->minimal().alias_type().alias_flags().IS_AUTOID_HASH(false); - - // type_object->minimal().alias_type().header()... Is empty - - // No flags apply - //type_object->minimal().alias_type().body().common().related_flags().TRY_CONSTRUCT1(false); - //type_object->minimal().alias_type().body().common().related_flags().TRY_CONSTRUCT2(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_EXTERNAL(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_OPTIONAL(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_MUST_UNDERSTAND(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_KEY(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_DEFAULT(false); - - // Must be defined already, if don't, may be an recursive alias - const TypeIdentifier *relatedType = TypeObjectFactory::get_instance()->get_type_identifier(TypeNamesGenerator::get_array_type_name("int32_t", {2, 2}), false); - - - if (relatedType != nullptr) - { - type_object->minimal().alias_type().body().common().related_type() = *relatedType; // Make a copy - } - else - { - // Cannot determine base type - delete type_object; - return nullptr; - } - - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().alias_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - // Don't add our TypeIdentifier but our alias - TypeObjectFactory::get_instance()->add_alias("MyArray", TypeNamesGenerator::get_array_type_name("int32_t", {2, 2})); - - TypeObjectFactory::get_instance()->add_type_object("MyArray", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyArray", false); -} - -const TypeObject* GetCompleteMyArrayObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyArray", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_ALIAS); - - // No flags apply - //type_object->complete().alias_type().alias_flags().IS_FINAL(false); - //type_object->complete().alias_type().alias_flags().IS_APPENDABLE(false); - //type_object->complete().alias_type().alias_flags().IS_MUTABLE(false); - //type_object->complete().alias_type().alias_flags().IS_NESTED(false); - //type_object->complete().alias_type().alias_flags().IS_AUTOID_HASH(false); - - //type_object->complete().alias_type().header().detail().ann_builtin().verbatim().placement("placement"); - //type_object->complete().alias_type().header().detail().ann_builtin().verbatim().language("language"); - //type_object->complete().alias_type().header().detail().ann_builtin().verbatim().text("text"); - //type_object->complete().alias_type().header().detail().ann_custom().push_back(...); - type_object->complete().alias_type().header().detail().type_name("MyArray"); - - // No flags apply - //type_object->complete().alias_type().body().common().related_flags().TRY_CONSTRUCT1(false); - //type_object->complete().alias_type().body().common().related_flags().TRY_CONSTRUCT2(false); - //type_object->complete().alias_type().body().common().related_flags().IS_EXTERNAL(false); - //type_object->complete().alias_type().body().common().related_flags().IS_OPTIONAL(false); - //type_object->complete().alias_type().body().common().related_flags().IS_MUST_UNDERSTAND(false); - //type_object->complete().alias_type().body().common().related_flags().IS_KEY(false); - //type_object->complete().alias_type().body().common().related_flags().IS_DEFAULT(false); - - //type_object->complete().alias_type().body().common().ann_builtin() - //type_object->complete().alias_type().body().common().ann_custom() - - // Must be defined already, if don't, may be an recursive alias - const TypeIdentifier *relatedType = TypeObjectFactory::get_instance()->get_type_identifier_trying_complete(TypeNamesGenerator::get_array_type_name("int32_t", {2, 2})); - - - if (relatedType != nullptr) - { - type_object->complete().alias_type().body().common().related_type() = *relatedType; // Make a copy - } - else - { - // Cannot determine base type - delete type_object; - return nullptr; - } - - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().alias_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - // Don't add our TypeIdentifier but our alias - TypeObjectFactory::get_instance()->add_alias("MyArray", TypeNamesGenerator::get_array_type_name("int32_t", {2, 2})); - - TypeObjectFactory::get_instance()->add_type_object("MyArray", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyArray", true); -} - - - -const TypeIdentifier* GetArrayArrayStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("ArrayArrayStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetArrayArrayStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("ArrayArrayStruct", complete); -} - -const TypeObject* GetArrayArrayStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ArrayArrayStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteArrayArrayStructObject(); - } - //else - return GetMinimalArrayArrayStructObject(); -} - -const TypeObject* GetMinimalArrayArrayStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ArrayArrayStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_array_array; - mst_my_array_array.common().member_id(memberId++); - mst_my_array_array.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_array_array.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_array_array.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_array_array.common().member_flags().IS_OPTIONAL(false); - mst_my_array_array.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_array_array.common().member_flags().IS_KEY(false); - mst_my_array_array.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_array_array.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("MyArray", {2, 2}, false)); - - MD5 my_array_array_hash("my_array_array"); - for(int i = 0; i < 4; ++i) - { - mst_my_array_array.detail().name_hash()[i] = my_array_array_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_array_array); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("ArrayArrayStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("ArrayArrayStruct", false); -} - -const TypeObject* GetCompleteArrayArrayStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ArrayArrayStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_array_array; - cst_my_array_array.common().member_id(memberId++); - cst_my_array_array.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_array_array.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_array_array.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_array_array.common().member_flags().IS_OPTIONAL(false); - cst_my_array_array.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_array_array.common().member_flags().IS_KEY(false); - cst_my_array_array.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_array_array.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("MyArray", {2, 2}, true)); - - cst_my_array_array.detail().name("my_array_array"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_array_array); - - - // Header - type_object->complete().struct_type().header().detail().type_name("ArrayArrayStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("ArrayArrayStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("ArrayArrayStruct", true); -} - - - - - -const TypeIdentifier* GetSequenceStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("SequenceStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetSequenceStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("SequenceStruct", complete); -} - -const TypeObject* GetSequenceStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SequenceStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteSequenceStructObject(); - } - //else - return GetMinimalSequenceStructObject(); -} - -const TypeObject* GetMinimalSequenceStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SequenceStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_sequence; - mst_my_sequence.common().member_id(memberId++); - mst_my_sequence.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_sequence.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_sequence.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_sequence.common().member_flags().IS_OPTIONAL(false); - mst_my_sequence.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_sequence.common().member_flags().IS_KEY(false); - mst_my_sequence.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_sequence.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("int32_t", 2, false)); - - MD5 my_sequence_hash("my_sequence"); - for(int i = 0; i < 4; ++i) - { - mst_my_sequence.detail().name_hash()[i] = my_sequence_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_sequence); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SequenceStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SequenceStruct", false); -} - -const TypeObject* GetCompleteSequenceStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SequenceStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_sequence; - cst_my_sequence.common().member_id(memberId++); - cst_my_sequence.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_sequence.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_sequence.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_sequence.common().member_flags().IS_OPTIONAL(false); - cst_my_sequence.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_sequence.common().member_flags().IS_KEY(false); - cst_my_sequence.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_sequence.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("int32_t", 2, true)); - - cst_my_sequence.detail().name("my_sequence"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_sequence); - - - // Header - type_object->complete().struct_type().header().detail().type_name("SequenceStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SequenceStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SequenceStruct", true); -} - - - - - - - -const TypeIdentifier* GetSequenceSequenceStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("SequenceSequenceStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetSequenceSequenceStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("SequenceSequenceStruct", complete); -} - -const TypeObject* GetSequenceSequenceStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SequenceSequenceStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteSequenceSequenceStructObject(); - } - //else - return GetMinimalSequenceSequenceStructObject(); -} - -const TypeObject* GetMinimalSequenceSequenceStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SequenceSequenceStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_sequence_sequence; - mst_my_sequence_sequence.common().member_id(memberId++); - mst_my_sequence_sequence.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_sequence_sequence.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_sequence_sequence.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_sequence_sequence.common().member_flags().IS_OPTIONAL(false); - mst_my_sequence_sequence.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_sequence_sequence.common().member_flags().IS_KEY(false); - mst_my_sequence_sequence.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_sequence_sequence.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier(TypeNamesGenerator::get_sequence_type_name("int32_t", 2), 3, false)); - - MD5 my_sequence_sequence_hash("my_sequence_sequence"); - for(int i = 0; i < 4; ++i) - { - mst_my_sequence_sequence.detail().name_hash()[i] = my_sequence_sequence_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_sequence_sequence); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SequenceSequenceStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SequenceSequenceStruct", false); -} - -const TypeObject* GetCompleteSequenceSequenceStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SequenceSequenceStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_sequence_sequence; - cst_my_sequence_sequence.common().member_id(memberId++); - cst_my_sequence_sequence.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_sequence_sequence.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_sequence_sequence.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_sequence_sequence.common().member_flags().IS_OPTIONAL(false); - cst_my_sequence_sequence.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_sequence_sequence.common().member_flags().IS_KEY(false); - cst_my_sequence_sequence.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_sequence_sequence.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier(TypeNamesGenerator::get_sequence_type_name("int32_t", 2), 3, true)); - - cst_my_sequence_sequence.detail().name("my_sequence_sequence"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_sequence_sequence); - - - // Header - type_object->complete().struct_type().header().detail().type_name("SequenceSequenceStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SequenceSequenceStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SequenceSequenceStruct", true); -} - - - - - -const TypeIdentifier* GetMapStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("MapStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetMapStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("MapStruct", complete); -} - -const TypeObject* GetMapStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MapStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteMapStructObject(); - } - //else - return GetMinimalMapStructObject(); -} - -const TypeObject* GetMinimalMapStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MapStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_map; - mst_my_map.common().member_id(memberId++); - mst_my_map.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_map.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_map.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_map.common().member_flags().IS_OPTIONAL(false); - mst_my_map.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_map.common().member_flags().IS_KEY(false); - mst_my_map.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_map.common().member_type_id(*TypeObjectFactory::get_instance()->get_map_identifier("int32_t", "int32_t", 2, false)); - - MD5 my_map_hash("my_map"); - for(int i = 0; i < 4; ++i) - { - mst_my_map.detail().name_hash()[i] = my_map_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_map); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MapStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MapStruct", false); -} - -const TypeObject* GetCompleteMapStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MapStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_map; - cst_my_map.common().member_id(memberId++); - cst_my_map.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_map.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_map.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_map.common().member_flags().IS_OPTIONAL(false); - cst_my_map.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_map.common().member_flags().IS_KEY(false); - cst_my_map.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_map.common().member_type_id(*TypeObjectFactory::get_instance()->get_map_identifier("int32_t", "int32_t", 2, true)); - - cst_my_map.detail().name("my_map"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_map); - - - // Header - type_object->complete().struct_type().header().detail().type_name("MapStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MapStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MapStruct", true); -} - - - - - - - -const TypeIdentifier* GetMapMapStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("MapMapStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetMapMapStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("MapMapStruct", complete); -} - -const TypeObject* GetMapMapStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MapMapStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteMapMapStructObject(); - } - //else - return GetMinimalMapMapStructObject(); -} - -const TypeObject* GetMinimalMapMapStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MapMapStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_map_map; - mst_my_map_map.common().member_id(memberId++); - mst_my_map_map.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_map_map.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_map_map.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_map_map.common().member_flags().IS_OPTIONAL(false); - mst_my_map_map.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_map_map.common().member_flags().IS_KEY(false); - mst_my_map_map.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_map_map.common().member_type_id(*TypeObjectFactory::get_instance()->get_map_identifier("int32_t", TypeNamesGenerator::get_map_type_name("int32_t", "int32_t", 2), 2, false)); - - MD5 my_map_map_hash("my_map_map"); - for(int i = 0; i < 4; ++i) - { - mst_my_map_map.detail().name_hash()[i] = my_map_map_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_map_map); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MapMapStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MapMapStruct", false); -} - -const TypeObject* GetCompleteMapMapStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MapMapStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_map_map; - cst_my_map_map.common().member_id(memberId++); - cst_my_map_map.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_map_map.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_map_map.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_map_map.common().member_flags().IS_OPTIONAL(false); - cst_my_map_map.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_map_map.common().member_flags().IS_KEY(false); - cst_my_map_map.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_map_map.common().member_type_id(*TypeObjectFactory::get_instance()->get_map_identifier("int32_t", TypeNamesGenerator::get_map_type_name("int32_t", "int32_t", 2), 2, true)); - - cst_my_map_map.detail().name("my_map_map"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_map_map); - - - // Header - type_object->complete().struct_type().header().detail().type_name("MapMapStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MapMapStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MapMapStruct", true); -} - -const TypeIdentifier* GetMyBitsetIdentifier(bool complete) -{ - const TypeIdentifier* c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("MyBitset", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetMyBitsetObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("MyBitset", complete); -} - -const TypeObject* GetMyBitsetObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyBitset", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteMyBitsetObject(); - } - // else - return GetMinimalMyBitsetObject(); -} - -const TypeObject* GetMinimalMyBitsetObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyBitset", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_BITSET); - - MinimalBitfield mbf_a; - mbf_a.common().flags().TRY_CONSTRUCT1(false); - mbf_a.common().flags().TRY_CONSTRUCT2(false); - mbf_a.common().flags().IS_EXTERNAL(false); - mbf_a.common().flags().IS_OPTIONAL(false); - mbf_a.common().flags().IS_MUST_UNDERSTAND(false); - mbf_a.common().flags().IS_KEY(false); - mbf_a.common().flags().IS_DEFAULT(false); - mbf_a.common().position(0); - mbf_a.common().bitcount(2); - mbf_a.common().holder_type(TK_CHAR8); - MD5 a_hash("a"); - for(int i = 0; i < 4; ++i) - { - mbf_a.name_hash()[i] = a_hash.digest[i]; - } - type_object->minimal().bitset_type().field_seq().emplace_back(mbf_a); - - - - MinimalBitfield mbf_b; - mbf_b.common().flags().TRY_CONSTRUCT1(false); - mbf_b.common().flags().TRY_CONSTRUCT2(false); - mbf_b.common().flags().IS_EXTERNAL(false); - mbf_b.common().flags().IS_OPTIONAL(false); - mbf_b.common().flags().IS_MUST_UNDERSTAND(false); - mbf_b.common().flags().IS_KEY(false); - mbf_b.common().flags().IS_DEFAULT(false); - mbf_b.common().position(10); - mbf_b.common().bitcount(20); - mbf_b.common().holder_type(TK_UINT32); - MD5 b_hash("b"); - for(int i = 0; i < 4; ++i) - { - mbf_b.name_hash()[i] = b_hash.digest[i]; - } - type_object->minimal().bitset_type().field_seq().emplace_back(mbf_b); - - - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().bitset_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MyBitset", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyBitset", false); -} - -const TypeObject* GetCompleteMyBitsetObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyBitset", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_BITSET); - - // No flags apply - //type_object->complete().bitset_type().bitset_flags().IS_FINAL(false); - //type_object->complete().bitset_type().bitset_flags().IS_APPENDABLE(false); - //type_object->complete().bitset_type().bitset_flags().IS_MUTABLE(false); - //type_object->complete().bitset_type().bitset_flags().IS_NESTED(false); - //type_object->complete().bitset_type().bitset_flags().IS_AUTOID_HASH(false); - - type_object->complete().bitset_type().header().detail().type_name("MyBitset"); - - CompleteBitfield cbf_a; - cbf_a.common().flags().TRY_CONSTRUCT1(false); - cbf_a.common().flags().TRY_CONSTRUCT2(false); - cbf_a.common().flags().IS_EXTERNAL(false); - cbf_a.common().flags().IS_OPTIONAL(false); - cbf_a.common().flags().IS_MUST_UNDERSTAND(false); - cbf_a.common().flags().IS_KEY(false); - cbf_a.common().flags().IS_DEFAULT(false); - cbf_a.common().position(0); - cbf_a.common().bitcount(2); - cbf_a.common().holder_type(TK_CHAR8); - cbf_a.detail().name("a"); - - // Position annotation always present - { - // Position - AppliedAnnotation ann; - ann.annotation_typeid(*TypeObjectFactory::get_instance()->get_type_identifier_trying_complete("position")); - AppliedAnnotationParameter annParam; - MD5 message_hash("value"); - for(int i = 0; i < 4; ++i) - { - annParam.paramname_hash()[i] = message_hash.digest[i]; - } - AnnotationParameterValue paramValue; - paramValue._d(TK_UINT16); - paramValue.uint_16_value(0); - annParam.value(paramValue); - ann.param_seq().push_back(annParam); - - cbf_a.detail().ann_custom().push_back(ann); - } - - // Use bit_bound as bitcount. - { - // Position - AppliedAnnotation ann; - ann.annotation_typeid(*TypeObjectFactory::get_instance()->get_type_identifier_trying_complete("bit_bound")); - AppliedAnnotationParameter annParam; - MD5 message_hash("value"); - for(int i = 0; i < 4; ++i) - { - annParam.paramname_hash()[i] = message_hash.digest[i]; - } - AnnotationParameterValue paramValue; - paramValue._d(TK_UINT16); - paramValue.uint_16_value(2); - annParam.value(paramValue); - ann.param_seq().push_back(annParam); - - cbf_a.detail().ann_custom().push_back(ann); - } - - type_object->complete().bitset_type().field_seq().emplace_back(cbf_a); - - - - CompleteBitfield cbf_b; - cbf_b.common().flags().TRY_CONSTRUCT1(false); - cbf_b.common().flags().TRY_CONSTRUCT2(false); - cbf_b.common().flags().IS_EXTERNAL(false); - cbf_b.common().flags().IS_OPTIONAL(false); - cbf_b.common().flags().IS_MUST_UNDERSTAND(false); - cbf_b.common().flags().IS_KEY(false); - cbf_b.common().flags().IS_DEFAULT(false); - cbf_b.common().position(10); - cbf_b.common().bitcount(20); - cbf_b.common().holder_type(TK_UINT32); - cbf_b.detail().name("b"); - - // Position annotation always present - { - // Position - AppliedAnnotation ann; - ann.annotation_typeid(*TypeObjectFactory::get_instance()->get_type_identifier_trying_complete("position")); - AppliedAnnotationParameter annParam; - MD5 message_hash("value"); - for(int i = 0; i < 4; ++i) - { - annParam.paramname_hash()[i] = message_hash.digest[i]; - } - AnnotationParameterValue paramValue; - paramValue._d(TK_UINT16); - paramValue.uint_16_value(10); - annParam.value(paramValue); - ann.param_seq().push_back(annParam); - - cbf_b.detail().ann_custom().push_back(ann); - } - - // Use bit_bound as bitcount. - { - // Position - AppliedAnnotation ann; - ann.annotation_typeid(*TypeObjectFactory::get_instance()->get_type_identifier_trying_complete("bit_bound")); - AppliedAnnotationParameter annParam; - MD5 message_hash("value"); - for(int i = 0; i < 4; ++i) - { - annParam.paramname_hash()[i] = message_hash.digest[i]; - } - AnnotationParameterValue paramValue; - paramValue._d(TK_UINT16); - paramValue.uint_16_value(20); - annParam.value(paramValue); - ann.param_seq().push_back(annParam); - - cbf_b.detail().ann_custom().push_back(ann); - } - - type_object->complete().bitset_type().field_seq().emplace_back(cbf_b); - - - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().bitset_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MyBitset", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyBitset", true); -} - - - -const TypeIdentifier* GetBitsetStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("BitsetStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetBitsetStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("BitsetStruct", complete); -} - -const TypeObject* GetBitsetStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("BitsetStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteBitsetStructObject(); - } - //else - return GetMinimalBitsetStructObject(); -} - -const TypeObject* GetMinimalBitsetStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("BitsetStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_a; - mst_a.common().member_id(memberId++); - mst_a.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_a.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_a.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_a.common().member_flags().IS_OPTIONAL(false); - mst_a.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_a.common().member_flags().IS_KEY(false); - mst_a.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_a.common().member_type_id(*GetMyBitsetIdentifier(false)); - - MD5 a_hash("a"); - for(int i = 0; i < 4; ++i) - { - mst_a.detail().name_hash()[i] = a_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_a); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("BitsetStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("BitsetStruct", false); -} - -const TypeObject* GetCompleteBitsetStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("BitsetStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_a; - cst_a.common().member_id(memberId++); - cst_a.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_a.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_a.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_a.common().member_flags().IS_OPTIONAL(false); - cst_a.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_a.common().member_flags().IS_KEY(false); - cst_a.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_a.common().member_type_id(*GetMyBitsetIdentifier(true)); - - cst_a.detail().name("a"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_a); - - - // Header - type_object->complete().struct_type().header().detail().type_name("BitsetStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("BitsetStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("BitsetStruct", true); -} - - - -const TypeIdentifier* GetStructStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("StructStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetStructStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("StructStruct", complete); -} - -const TypeObject* GetStructStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("StructStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteStructStructObject(); - } - //else - return GetMinimalStructStructObject(); -} - -const TypeObject* GetMinimalStructStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("StructStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_a; - mst_a.common().member_id(memberId++); - mst_a.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_a.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_a.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_a.common().member_flags().IS_OPTIONAL(false); - mst_a.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_a.common().member_flags().IS_KEY(false); - mst_a.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_a.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - MD5 a_hash("a"); - for(int i = 0; i < 4; ++i) - { - mst_a.detail().name_hash()[i] = a_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_a); - - MinimalStructMember mst_b; - mst_b.common().member_id(memberId++); - mst_b.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_b.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_b.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_b.common().member_flags().IS_OPTIONAL(false); - mst_b.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_b.common().member_flags().IS_KEY(false); - mst_b.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_b.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int64_t", false)); - - - MD5 b_hash("b"); - for(int i = 0; i < 4; ++i) - { - mst_b.detail().name_hash()[i] = b_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_b); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("StructStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("StructStruct", false); -} - -const TypeObject* GetCompleteStructStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("StructStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_a; - cst_a.common().member_id(memberId++); - cst_a.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_a.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_a.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_a.common().member_flags().IS_OPTIONAL(false); - cst_a.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_a.common().member_flags().IS_KEY(false); - cst_a.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_a.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - cst_a.detail().name("a"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_a); - - CompleteStructMember cst_b; - cst_b.common().member_id(memberId++); - cst_b.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_b.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_b.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_b.common().member_flags().IS_OPTIONAL(false); - cst_b.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_b.common().member_flags().IS_KEY(false); - cst_b.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_b.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int64_t", false)); - - - cst_b.detail().name("b"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_b); - - - // Header - type_object->complete().struct_type().header().detail().type_name("StructStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("StructStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("StructStruct", true); -} - - - -const TypeIdentifier* GetStructStructStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("StructStructStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetStructStructStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("StructStructStruct", complete); -} - -const TypeObject* GetStructStructStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("StructStructStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteStructStructStructObject(); - } - //else - return GetMinimalStructStructStructObject(); -} - -const TypeObject* GetMinimalStructStructStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("StructStructStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_child_struct; - mst_child_struct.common().member_id(memberId++); - mst_child_struct.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_child_struct.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_child_struct.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_child_struct.common().member_flags().IS_OPTIONAL(false); - mst_child_struct.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_child_struct.common().member_flags().IS_KEY(false); - mst_child_struct.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_child_struct.common().member_type_id(*GetStructStructIdentifier(false)); - - MD5 child_struct_hash("child_struct"); - for(int i = 0; i < 4; ++i) - { - mst_child_struct.detail().name_hash()[i] = child_struct_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_child_struct); - - MinimalStructMember mst_child_int64; - mst_child_int64.common().member_id(memberId++); - mst_child_int64.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_child_int64.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_child_int64.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_child_int64.common().member_flags().IS_OPTIONAL(false); - mst_child_int64.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_child_int64.common().member_flags().IS_KEY(false); - mst_child_int64.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_child_int64.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int64_t", false)); - - - MD5 child_int64_hash("child_int64"); - for(int i = 0; i < 4; ++i) - { - mst_child_int64.detail().name_hash()[i] = child_int64_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_child_int64); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("StructStructStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("StructStructStruct", false); -} - -const TypeObject* GetCompleteStructStructStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("StructStructStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_child_struct; - cst_child_struct.common().member_id(memberId++); - cst_child_struct.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_child_struct.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_child_struct.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_child_struct.common().member_flags().IS_OPTIONAL(false); - cst_child_struct.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_child_struct.common().member_flags().IS_KEY(false); - cst_child_struct.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_child_struct.common().member_type_id(*GetStructStructIdentifier(true)); - - cst_child_struct.detail().name("child_struct"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_child_struct); - - CompleteStructMember cst_child_int64; - cst_child_int64.common().member_id(memberId++); - cst_child_int64.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_child_int64.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_child_int64.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_child_int64.common().member_flags().IS_OPTIONAL(false); - cst_child_int64.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_child_int64.common().member_flags().IS_KEY(false); - cst_child_int64.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_child_int64.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int64_t", false)); - - - cst_child_int64.detail().name("child_int64"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_child_int64); - - - // Header - type_object->complete().struct_type().header().detail().type_name("StructStructStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("StructStructStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("StructStructStruct", true); -} - - - -const TypeIdentifier* GetSimpleUnionIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("SimpleUnion", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetSimpleUnionObject(complete); - return TypeObjectFactory::get_instance()->get_type_identifier("SimpleUnion", complete); -} - -const TypeObject* GetSimpleUnionObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleUnion", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteSimpleUnionObject(); - } - // else - return GetMinimalSimpleUnionObject(); -} - -const TypeObject* GetMinimalSimpleUnionObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleUnion", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_UNION); - - type_object->minimal().union_type().union_flags().IS_FINAL(false); - type_object->minimal().union_type().union_flags().IS_APPENDABLE(false); - type_object->minimal().union_type().union_flags().IS_MUTABLE(false); - type_object->minimal().union_type().union_flags().IS_NESTED(false); - type_object->minimal().union_type().union_flags().IS_AUTOID_HASH(false); // Unsupported - - type_object->minimal().union_type().discriminator().common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().IS_EXTERNAL(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_OPTIONAL(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_KEY(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().IS_DEFAULT(false); // Doesn't apply - - type_object->minimal().union_type().discriminator().common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - MemberId memberId = 0; - MinimalUnionMember mst_first; - mst_first.common().member_id(memberId++); - mst_first.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_first.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_first.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_first.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - mst_first.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mst_first.common().member_flags().IS_KEY(false); // Doesn't apply - mst_first.common().member_flags().IS_DEFAULT(false); - mst_first.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - mst_first.common().label_seq().emplace_back(A); - - MD5 first_hash("first"); - for(int i = 0; i < 4; ++i) - { - mst_first.detail().name_hash()[i] = first_hash.digest[i]; - } - type_object->minimal().union_type().member_seq().emplace_back(mst_first); - - MinimalUnionMember mst_second; - mst_second.common().member_id(memberId++); - mst_second.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_second.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_second.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_second.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - mst_second.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mst_second.common().member_flags().IS_KEY(false); // Doesn't apply - mst_second.common().member_flags().IS_DEFAULT(false); - mst_second.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int64_t", false)); - - - mst_second.common().label_seq().emplace_back(B); - - MD5 second_hash("second"); - for(int i = 0; i < 4; ++i) - { - mst_second.detail().name_hash()[i] = second_hash.digest[i]; - } - type_object->minimal().union_type().member_seq().emplace_back(mst_second); - - - // Header - //type_object->minimal().union_type().header().detail()... // Empty - - TypeIdentifier* identifier = new TypeIdentifier(); - identifier->_d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().union_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier->equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimpleUnion", identifier, type_object); - delete type_object; - delete identifier; - return TypeObjectFactory::get_instance()->get_type_object("SimpleUnion", false); -} - -const TypeObject* GetCompleteSimpleUnionObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleUnion", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_UNION); - - type_object->complete().union_type().union_flags().IS_FINAL(false); - type_object->complete().union_type().union_flags().IS_APPENDABLE(false); - type_object->complete().union_type().union_flags().IS_MUTABLE(false); - type_object->complete().union_type().union_flags().IS_NESTED(false); - type_object->complete().union_type().union_flags().IS_AUTOID_HASH(false); // Unsupported - - type_object->complete().union_type().discriminator().common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().IS_EXTERNAL(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_OPTIONAL(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_KEY(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().IS_DEFAULT(false); // Doesn't apply - - type_object->complete().union_type().discriminator().common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - MemberId memberId = 0; - CompleteUnionMember cst_first; - cst_first.common().member_id(memberId++); - cst_first.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_first.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_first.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_first.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - cst_first.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cst_first.common().member_flags().IS_KEY(false); // Doesn't apply - cst_first.common().member_flags().IS_DEFAULT(false); - cst_first.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - cst_first.common().label_seq().emplace_back(A); - - - cst_first.detail().name("first"); - - type_object->complete().union_type().member_seq().emplace_back(cst_first); - - CompleteUnionMember cst_second; - cst_second.common().member_id(memberId++); - cst_second.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_second.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_second.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_second.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - cst_second.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cst_second.common().member_flags().IS_KEY(false); // Doesn't apply - cst_second.common().member_flags().IS_DEFAULT(false); - cst_second.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int64_t", false)); - - cst_second.common().label_seq().emplace_back(B); - - - cst_second.detail().name("second"); - - type_object->complete().union_type().member_seq().emplace_back(cst_second); - - - // Header - type_object->complete().union_type().header().detail().type_name("SimpleUnion"); - - TypeIdentifier* identifier = new TypeIdentifier(); - identifier->_d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().union_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier->equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimpleUnion", identifier, type_object); - delete type_object; - delete identifier; - return TypeObjectFactory::get_instance()->get_type_object("SimpleUnion", true); -} - - - -const TypeIdentifier* GetUnionUnionIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("UnionUnion", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetUnionUnionObject(complete); - return TypeObjectFactory::get_instance()->get_type_identifier("UnionUnion", complete); -} - -const TypeObject* GetUnionUnionObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("UnionUnion", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteUnionUnionObject(); - } - // else - return GetMinimalUnionUnionObject(); -} - -const TypeObject* GetMinimalUnionUnionObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("UnionUnion", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_UNION); - - type_object->minimal().union_type().union_flags().IS_FINAL(false); - type_object->minimal().union_type().union_flags().IS_APPENDABLE(false); - type_object->minimal().union_type().union_flags().IS_MUTABLE(false); - type_object->minimal().union_type().union_flags().IS_NESTED(false); - type_object->minimal().union_type().union_flags().IS_AUTOID_HASH(false); // Unsupported - - type_object->minimal().union_type().discriminator().common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().IS_EXTERNAL(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_OPTIONAL(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_KEY(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().IS_DEFAULT(false); // Doesn't apply - - type_object->minimal().union_type().discriminator().common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - MemberId memberId = 0; - MinimalUnionMember mst_first; - mst_first.common().member_id(memberId++); - mst_first.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_first.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_first.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_first.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - mst_first.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mst_first.common().member_flags().IS_KEY(false); // Doesn't apply - mst_first.common().member_flags().IS_DEFAULT(false); - mst_first.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - mst_first.common().label_seq().emplace_back(A); - - MD5 first_hash("first"); - for(int i = 0; i < 4; ++i) - { - mst_first.detail().name_hash()[i] = first_hash.digest[i]; - } - type_object->minimal().union_type().member_seq().emplace_back(mst_first); - - MinimalUnionMember mst_second; - mst_second.common().member_id(memberId++); - mst_second.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_second.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_second.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_second.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - mst_second.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mst_second.common().member_flags().IS_KEY(false); // Doesn't apply - mst_second.common().member_flags().IS_DEFAULT(false); - mst_second.common().type_id(*GetSimpleUnionIdentifier(false)); - - mst_second.common().label_seq().emplace_back(B); - - MD5 second_hash("second"); - for(int i = 0; i < 4; ++i) - { - mst_second.detail().name_hash()[i] = second_hash.digest[i]; - } - type_object->minimal().union_type().member_seq().emplace_back(mst_second); - - - // Header - //type_object->minimal().union_type().header().detail()... // Empty - - TypeIdentifier* identifier = new TypeIdentifier(); - identifier->_d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().union_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier->equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("UnionUnion", identifier, type_object); - delete type_object; - delete identifier; - return TypeObjectFactory::get_instance()->get_type_object("UnionUnion", false); -} - -const TypeObject* GetCompleteUnionUnionObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("UnionUnion", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_UNION); - - type_object->complete().union_type().union_flags().IS_FINAL(false); - type_object->complete().union_type().union_flags().IS_APPENDABLE(false); - type_object->complete().union_type().union_flags().IS_MUTABLE(false); - type_object->complete().union_type().union_flags().IS_NESTED(false); - type_object->complete().union_type().union_flags().IS_AUTOID_HASH(false); // Unsupported - - type_object->complete().union_type().discriminator().common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().IS_EXTERNAL(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_OPTIONAL(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_KEY(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().IS_DEFAULT(false); // Doesn't apply - - type_object->complete().union_type().discriminator().common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - MemberId memberId = 0; - CompleteUnionMember cst_first; - cst_first.common().member_id(memberId++); - cst_first.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_first.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_first.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_first.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - cst_first.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cst_first.common().member_flags().IS_KEY(false); // Doesn't apply - cst_first.common().member_flags().IS_DEFAULT(false); - cst_first.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - cst_first.common().label_seq().emplace_back(A); - - - cst_first.detail().name("first"); - - type_object->complete().union_type().member_seq().emplace_back(cst_first); - - CompleteUnionMember cst_second; - cst_second.common().member_id(memberId++); - cst_second.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_second.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_second.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_second.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - cst_second.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cst_second.common().member_flags().IS_KEY(false); // Doesn't apply - cst_second.common().member_flags().IS_DEFAULT(false); - cst_second.common().type_id(*GetSimpleUnionIdentifier(true)); - cst_second.common().label_seq().emplace_back(B); - - - cst_second.detail().name("second"); - - type_object->complete().union_type().member_seq().emplace_back(cst_second); - - - // Header - type_object->complete().union_type().header().detail().type_name("UnionUnion"); - - TypeIdentifier* identifier = new TypeIdentifier(); - identifier->_d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().union_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier->equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("UnionUnion", identifier, type_object); - delete type_object; - delete identifier; - return TypeObjectFactory::get_instance()->get_type_object("UnionUnion", true); -} - - - -const TypeIdentifier* GetWCharUnionIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("WCharUnion", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetWCharUnionObject(complete); - return TypeObjectFactory::get_instance()->get_type_identifier("WCharUnion", complete); -} - -const TypeObject* GetWCharUnionObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("WCharUnion", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteWCharUnionObject(); - } - // else - return GetMinimalWCharUnionObject(); -} - -const TypeObject* GetMinimalWCharUnionObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("WCharUnion", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_UNION); - - type_object->minimal().union_type().union_flags().IS_FINAL(false); - type_object->minimal().union_type().union_flags().IS_APPENDABLE(false); - type_object->minimal().union_type().union_flags().IS_MUTABLE(false); - type_object->minimal().union_type().union_flags().IS_NESTED(false); - type_object->minimal().union_type().union_flags().IS_AUTOID_HASH(false); // Unsupported - - type_object->minimal().union_type().discriminator().common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().IS_EXTERNAL(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_OPTIONAL(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_KEY(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().IS_DEFAULT(false); // Doesn't apply - - type_object->minimal().union_type().discriminator().common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("wchar_t", false)); - - MemberId memberId = 0; - MinimalUnionMember mst_first; - mst_first.common().member_id(memberId++); - mst_first.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_first.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_first.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_first.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - mst_first.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mst_first.common().member_flags().IS_KEY(false); // Doesn't apply - mst_first.common().member_flags().IS_DEFAULT(false); - mst_first.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - mst_first.common().label_seq().emplace_back(A); - - MD5 first_hash("first"); - for(int i = 0; i < 4; ++i) - { - mst_first.detail().name_hash()[i] = first_hash.digest[i]; - } - type_object->minimal().union_type().member_seq().emplace_back(mst_first); - - MinimalUnionMember mst_second; - mst_second.common().member_id(memberId++); - mst_second.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_second.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_second.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_second.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - mst_second.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mst_second.common().member_flags().IS_KEY(false); // Doesn't apply - mst_second.common().member_flags().IS_DEFAULT(false); - mst_second.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int64_t", false)); - - - mst_second.common().label_seq().emplace_back(B); - - MD5 second_hash("second"); - for(int i = 0; i < 4; ++i) - { - mst_second.detail().name_hash()[i] = second_hash.digest[i]; - } - type_object->minimal().union_type().member_seq().emplace_back(mst_second); - - - // Header - //type_object->minimal().union_type().header().detail()... // Empty - - TypeIdentifier* identifier = new TypeIdentifier(); - identifier->_d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().union_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier->equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("WCharUnion", identifier, type_object); - delete type_object; - delete identifier; - return TypeObjectFactory::get_instance()->get_type_object("WCharUnion", false); -} - -const TypeObject* GetCompleteWCharUnionObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("WCharUnion", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_UNION); - - type_object->complete().union_type().union_flags().IS_FINAL(false); - type_object->complete().union_type().union_flags().IS_APPENDABLE(false); - type_object->complete().union_type().union_flags().IS_MUTABLE(false); - type_object->complete().union_type().union_flags().IS_NESTED(false); - type_object->complete().union_type().union_flags().IS_AUTOID_HASH(false); // Unsupported - - type_object->complete().union_type().discriminator().common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().IS_EXTERNAL(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_OPTIONAL(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_KEY(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().IS_DEFAULT(false); // Doesn't apply - - type_object->complete().union_type().discriminator().common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("wchar_t", false)); - - MemberId memberId = 0; - CompleteUnionMember cst_first; - cst_first.common().member_id(memberId++); - cst_first.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_first.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_first.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_first.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - cst_first.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cst_first.common().member_flags().IS_KEY(false); // Doesn't apply - cst_first.common().member_flags().IS_DEFAULT(false); - cst_first.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - cst_first.common().label_seq().emplace_back(A); - - - cst_first.detail().name("first"); - - type_object->complete().union_type().member_seq().emplace_back(cst_first); - - CompleteUnionMember cst_second; - cst_second.common().member_id(memberId++); - cst_second.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_second.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_second.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_second.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - cst_second.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cst_second.common().member_flags().IS_KEY(false); // Doesn't apply - cst_second.common().member_flags().IS_DEFAULT(false); - cst_second.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int64_t", false)); - - cst_second.common().label_seq().emplace_back(B); - - - cst_second.detail().name("second"); - - type_object->complete().union_type().member_seq().emplace_back(cst_second); - - - // Header - type_object->complete().union_type().header().detail().type_name("WCharUnion"); - - TypeIdentifier* identifier = new TypeIdentifier(); - identifier->_d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().union_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier->equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("WCharUnion", identifier, type_object); - delete type_object; - delete identifier; - return TypeObjectFactory::get_instance()->get_type_object("WCharUnion", true); -} - - - -const TypeIdentifier* GetSimpleUnionStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("SimpleUnionStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetSimpleUnionStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("SimpleUnionStruct", complete); -} - -const TypeObject* GetSimpleUnionStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleUnionStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteSimpleUnionStructObject(); - } - //else - return GetMinimalSimpleUnionStructObject(); -} - -const TypeObject* GetMinimalSimpleUnionStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleUnionStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_union; - mst_my_union.common().member_id(memberId++); - mst_my_union.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_union.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_union.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_union.common().member_flags().IS_OPTIONAL(false); - mst_my_union.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_union.common().member_flags().IS_KEY(false); - mst_my_union.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_union.common().member_type_id(*GetSimpleUnionIdentifier(false)); - - MD5 my_union_hash("my_union"); - for(int i = 0; i < 4; ++i) - { - mst_my_union.detail().name_hash()[i] = my_union_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_union); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimpleUnionStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SimpleUnionStruct", false); -} - -const TypeObject* GetCompleteSimpleUnionStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleUnionStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_union; - cst_my_union.common().member_id(memberId++); - cst_my_union.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_union.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_union.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_union.common().member_flags().IS_OPTIONAL(false); - cst_my_union.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_union.common().member_flags().IS_KEY(false); - cst_my_union.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_union.common().member_type_id(*GetSimpleUnionIdentifier(true)); - - cst_my_union.detail().name("my_union"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_union); - - - // Header - type_object->complete().struct_type().header().detail().type_name("SimpleUnionStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimpleUnionStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SimpleUnionStruct", true); -} - - - -const TypeIdentifier* GetUnionUnionUnionStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("UnionUnionUnionStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetUnionUnionUnionStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("UnionUnionUnionStruct", complete); -} - -const TypeObject* GetUnionUnionUnionStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("UnionUnionUnionStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteUnionUnionUnionStructObject(); - } - //else - return GetMinimalUnionUnionUnionStructObject(); -} - -const TypeObject* GetMinimalUnionUnionUnionStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("UnionUnionUnionStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_union; - mst_my_union.common().member_id(memberId++); - mst_my_union.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_union.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_union.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_union.common().member_flags().IS_OPTIONAL(false); - mst_my_union.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_union.common().member_flags().IS_KEY(false); - mst_my_union.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_union.common().member_type_id(*GetUnionUnionIdentifier(false)); - - MD5 my_union_hash("my_union"); - for(int i = 0; i < 4; ++i) - { - mst_my_union.detail().name_hash()[i] = my_union_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_union); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("UnionUnionUnionStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("UnionUnionUnionStruct", false); -} - -const TypeObject* GetCompleteUnionUnionUnionStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("UnionUnionUnionStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_union; - cst_my_union.common().member_id(memberId++); - cst_my_union.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_union.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_union.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_union.common().member_flags().IS_OPTIONAL(false); - cst_my_union.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_union.common().member_flags().IS_KEY(false); - cst_my_union.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_union.common().member_type_id(*GetUnionUnionIdentifier(true)); - - cst_my_union.detail().name("my_union"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_union); - - - // Header - type_object->complete().struct_type().header().detail().type_name("UnionUnionUnionStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("UnionUnionUnionStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("UnionUnionUnionStruct", true); -} - - - -const TypeIdentifier* GetWCharUnionStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("WCharUnionStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetWCharUnionStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("WCharUnionStruct", complete); -} - -const TypeObject* GetWCharUnionStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("WCharUnionStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteWCharUnionStructObject(); - } - //else - return GetMinimalWCharUnionStructObject(); -} - -const TypeObject* GetMinimalWCharUnionStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("WCharUnionStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_union; - mst_my_union.common().member_id(memberId++); - mst_my_union.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_union.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_union.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_union.common().member_flags().IS_OPTIONAL(false); - mst_my_union.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_union.common().member_flags().IS_KEY(false); - mst_my_union.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_union.common().member_type_id(*GetWCharUnionIdentifier(false)); - - MD5 my_union_hash("my_union"); - for(int i = 0; i < 4; ++i) - { - mst_my_union.detail().name_hash()[i] = my_union_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_union); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("WCharUnionStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("WCharUnionStruct", false); -} - -const TypeObject* GetCompleteWCharUnionStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("WCharUnionStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_union; - cst_my_union.common().member_id(memberId++); - cst_my_union.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_union.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_union.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_union.common().member_flags().IS_OPTIONAL(false); - cst_my_union.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_union.common().member_flags().IS_KEY(false); - cst_my_union.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_union.common().member_type_id(*GetWCharUnionIdentifier(true)); - - cst_my_union.detail().name("my_union"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_union); - - - // Header - type_object->complete().struct_type().header().detail().type_name("WCharUnionStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("WCharUnionStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("WCharUnionStruct", true); -} diff --git a/test/unittest/dynamic_types/idl/BasicTypeObject.h b/test/unittest/dynamic_types/idl/BasicTypeObject.h deleted file mode 100644 index e114b7d10d0..00000000000 --- a/test/unittest/dynamic_types/idl/BasicTypeObject.h +++ /dev/null @@ -1,340 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file BasicTypeObject.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifndef _FAST_DDS_GENERATED_BASIC_TYPE_OBJECT_H_ -#define _FAST_DDS_GENERATED_BASIC_TYPE_OBJECT_H_ - - -#include -#include - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif -#else -#define eProsima_user_DllExport -#endif - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(Basic_SOURCE) -#define Basic_DllAPI __declspec( dllexport ) -#else -#define Basic_DllAPI __declspec( dllimport ) -#endif // Basic_SOURCE -#else -#define Basic_DllAPI -#endif -#else -#define Basic_DllAPI -#endif // _WIN32 - -using namespace eprosima::fastrtps::types; - -eProsima_user_DllExport void registerBasicTypes(); - -eProsima_user_DllExport const TypeIdentifier* GetMyEnumIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMyEnumObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalMyEnumObject(); -eProsima_user_DllExport const TypeObject* GetCompleteMyEnumObject(); - -eProsima_user_DllExport const TypeIdentifier* GetMyAliasEnumIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMyAliasEnumObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalMyAliasEnumObject(); -eProsima_user_DllExport const TypeObject* GetCompleteMyAliasEnumObject(); - -eProsima_user_DllExport const TypeIdentifier* GetMyAliasAliasEnumIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMyAliasAliasEnumObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalMyAliasAliasEnumObject(); -eProsima_user_DllExport const TypeObject* GetCompleteMyAliasAliasEnumObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetEnumStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetEnumStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalEnumStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteEnumStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetAliasStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetAliasStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalAliasStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteAliasStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetAliasAliasStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetAliasAliasStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalAliasAliasStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteAliasAliasStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetBoolStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetBoolStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalBoolStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteBoolStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetOctetStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetOctetStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalOctetStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteOctetStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetShortStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetShortStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalShortStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteShortStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetLongStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetLongStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalLongStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteLongStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetLongLongStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetLongLongStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalLongLongStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteLongLongStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetUShortStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetUShortStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalUShortStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteUShortStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetULongStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetULongStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalULongStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteULongStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetULongLongStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetULongLongStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalULongLongStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteULongLongStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetFloatStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetFloatStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalFloatStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteFloatStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetDoubleStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetDoubleStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalDoubleStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteDoubleStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetLongDoubleStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetLongDoubleStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalLongDoubleStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteLongDoubleStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetCharStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetCharStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalCharStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteCharStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetWCharStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetWCharStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalWCharStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteWCharStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetStringStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetStringStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalStringStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteStringStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetWStringStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetWStringStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalWStringStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteWStringStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetLargeStringStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetLargeStringStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalLargeStringStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteLargeStringStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetLargeWStringStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetLargeWStringStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalLargeWStringStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteLargeWStringStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetArraytStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetArraytStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalArraytStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteArraytStructObject(); - -eProsima_user_DllExport const TypeIdentifier* GetMyArrayIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMyArrayObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalMyArrayObject(); -eProsima_user_DllExport const TypeObject* GetCompleteMyArrayObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetArrayArrayStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetArrayArrayStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalArrayArrayStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteArrayArrayStructObject(); - - - - - -eProsima_user_DllExport const TypeIdentifier* GetSequenceStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetSequenceStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalSequenceStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteSequenceStructObject(); - - - - - - - -eProsima_user_DllExport const TypeIdentifier* GetSequenceSequenceStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetSequenceSequenceStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalSequenceSequenceStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteSequenceSequenceStructObject(); - - - - - -eProsima_user_DllExport const TypeIdentifier* GetMapStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMapStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalMapStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteMapStructObject(); - - - - - - - -eProsima_user_DllExport const TypeIdentifier* GetMapMapStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMapMapStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalMapMapStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteMapMapStructObject(); - -eProsima_user_DllExport const TypeIdentifier* GetMyBitsetIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMyBitsetObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalMyBitsetObject(); -eProsima_user_DllExport const TypeObject* GetCompleteMyBitsetObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetBitsetStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetBitsetStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalBitsetStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteBitsetStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetStructStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetStructStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalStructStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteStructStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetStructStructStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetStructStructStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalStructStructStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteStructStructStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetSimpleUnionIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetSimpleUnionObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalSimpleUnionObject(); -eProsima_user_DllExport const TypeObject* GetCompleteSimpleUnionObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetUnionUnionIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetUnionUnionObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalUnionUnionObject(); -eProsima_user_DllExport const TypeObject* GetCompleteUnionUnionObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetWCharUnionIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetWCharUnionObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalWCharUnionObject(); -eProsima_user_DllExport const TypeObject* GetCompleteWCharUnionObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetSimpleUnionStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetSimpleUnionStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalSimpleUnionStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteSimpleUnionStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetUnionUnionUnionStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetUnionUnionUnionStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalUnionUnionUnionStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteUnionUnionUnionStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetWCharUnionStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetWCharUnionStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalWCharUnionStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteWCharUnionStructObject(); - - -#endif // _FAST_DDS_GENERATED_BASIC_TYPE_OBJECT_H_ \ No newline at end of file diff --git a/test/unittest/dynamic_types/idl/Basicv1.cxx b/test/unittest/dynamic_types/idl/Basicv1.cxx deleted file mode 100644 index b8fca04e00d..00000000000 --- a/test/unittest/dynamic_types/idl/Basicv1.cxx +++ /dev/null @@ -1,6119 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file Basic.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "Basic.h" - -#if FASTCDR_VERSION_MAJOR == 1 - -#include "BasicTypeObject.h" - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - -namespace helper { namespace internal { - -enum class Size { - UInt8, - UInt16, - UInt32, - UInt64, -}; - -constexpr Size get_size(int s) { - return (s <= 8 ) ? Size::UInt8: - (s <= 16) ? Size::UInt16: - (s <= 32) ? Size::UInt32: Size::UInt64; -} - -template -struct FindTypeH; - -template<> -struct FindTypeH { - using type = std::uint8_t; -}; - -template<> -struct FindTypeH { - using type = std::uint16_t; -}; - -template<> -struct FindTypeH { - using type = std::uint32_t; -}; - -template<> -struct FindTypeH { - using type = std::uint64_t; -}; -} - -template -struct FindType { - using type = typename internal::FindTypeH::type; -}; -} - -#define ArraytStruct_max_cdr_typesize 36ULL; -#define SimpleUnionStruct_max_cdr_typesize 24ULL; - -#define WCharUnionStruct_max_cdr_typesize 24ULL; -#define OctetStruct_max_cdr_typesize 5ULL; -#define LongStruct_max_cdr_typesize 8ULL; -#define EnumStruct_max_cdr_typesize 8ULL; -#define BitsetStruct_max_cdr_typesize 8ULL; - - -#define DoubleStruct_max_cdr_typesize 16ULL; -#define LargeWStringStruct_max_cdr_typesize 167708ULL; -#define WCharStruct_max_cdr_typesize 8ULL; - -#define WStringStruct_max_cdr_typesize 1028ULL; -#define SequenceStruct_max_cdr_typesize 16ULL; - -#define ULongStruct_max_cdr_typesize 8ULL; -#define SequenceSequenceStruct_max_cdr_typesize 48ULL; -#define FloatStruct_max_cdr_typesize 8ULL; -#define LongDoubleStruct_max_cdr_typesize 24ULL; -#define StructStructStruct_max_cdr_typesize 32ULL; -#define UnionUnionUnionStruct_max_cdr_typesize 32ULL; -#define BoolStruct_max_cdr_typesize 5ULL; -#define MapMapStruct_max_cdr_typesize 60ULL; -#define AliasAliasStruct_max_cdr_typesize 8ULL; -#define ArrayArrayStruct_max_cdr_typesize 72ULL; -#define ShortStruct_max_cdr_typesize 6ULL; -#define MapStruct_max_cdr_typesize 24ULL; -#define UShortStruct_max_cdr_typesize 6ULL; - - -#define ULongLongStruct_max_cdr_typesize 16ULL; -#define AliasStruct_max_cdr_typesize 8ULL; -#define LargeStringStruct_max_cdr_typesize 41934ULL; -#define CharStruct_max_cdr_typesize 5ULL; -#define LongLongStruct_max_cdr_typesize 16ULL; -#define StringStruct_max_cdr_typesize 264ULL; -#define StructStruct_max_cdr_typesize 16ULL; - - - - - -EnumStruct::EnumStruct() -{ - // MyEnum m_my_enum - m_my_enum = ::A; - - // Just to register all known types - registerBasicTypes(); -} - -EnumStruct::~EnumStruct() -{ -} - -EnumStruct::EnumStruct( - const EnumStruct& x) -{ - m_my_enum = x.m_my_enum; - -} - -EnumStruct::EnumStruct( - EnumStruct&& x) noexcept -{ - m_my_enum = x.m_my_enum; - -} - -EnumStruct& EnumStruct::operator =( - const EnumStruct& x) -{ - m_my_enum = x.m_my_enum; - - return *this; -} - -EnumStruct& EnumStruct::operator =( - EnumStruct&& x) noexcept -{ - m_my_enum = x.m_my_enum; - - return *this; -} - -bool EnumStruct::operator ==( - const EnumStruct& x) const -{ - return (m_my_enum == x.m_my_enum); -} - -bool EnumStruct::operator !=( - const EnumStruct& x) const -{ - return !(*this == x); -} - -size_t EnumStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return EnumStruct_max_cdr_typesize; -} - -size_t EnumStruct::getCdrSerializedSize( - const EnumStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - return current_alignment - initial_alignment; -} - - -void EnumStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << (uint32_t)m_my_enum; - -} - -void EnumStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - { - uint32_t enum_value = 0; - dcdr >> enum_value; - m_my_enum = (MyEnum)enum_value; - } - - -} - - -bool EnumStruct::isKeyDefined() -{ - return false; -} - -void EnumStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member my_enum - * @param _my_enum New value for member my_enum - */ -void EnumStruct::my_enum( - MyEnum _my_enum) -{ - m_my_enum = _my_enum; -} - -/*! - * @brief This function returns the value of member my_enum - * @return Value of member my_enum - */ -MyEnum EnumStruct::my_enum() const -{ - return m_my_enum; -} - -/*! - * @brief This function returns a reference to member my_enum - * @return Reference to member my_enum - */ -MyEnum& EnumStruct::my_enum() -{ - return m_my_enum; -} - - - - - -AliasStruct::AliasStruct() -{ - // MyAliasEnum m_my_alias - m_my_alias = ::A; - - // Just to register all known types - registerBasicTypes(); -} - -AliasStruct::~AliasStruct() -{ -} - -AliasStruct::AliasStruct( - const AliasStruct& x) -{ - m_my_alias = x.m_my_alias; - -} - -AliasStruct::AliasStruct( - AliasStruct&& x) noexcept -{ - m_my_alias = x.m_my_alias; - -} - -AliasStruct& AliasStruct::operator =( - const AliasStruct& x) -{ - m_my_alias = x.m_my_alias; - - return *this; -} - -AliasStruct& AliasStruct::operator =( - AliasStruct&& x) noexcept -{ - m_my_alias = x.m_my_alias; - - return *this; -} - -bool AliasStruct::operator ==( - const AliasStruct& x) const -{ - return (m_my_alias == x.m_my_alias); -} - -bool AliasStruct::operator !=( - const AliasStruct& x) const -{ - return !(*this == x); -} - -size_t AliasStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return AliasStruct_max_cdr_typesize; -} - -size_t AliasStruct::getCdrSerializedSize( - const AliasStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - return current_alignment - initial_alignment; -} - - -void AliasStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << (uint32_t)m_my_alias; - -} - -void AliasStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - { - uint32_t enum_value = 0; - dcdr >> enum_value; - m_my_alias = (MyAliasEnum)enum_value; - } - - -} - - -bool AliasStruct::isKeyDefined() -{ - return false; -} - -void AliasStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member my_alias - * @param _my_alias New value for member my_alias - */ -void AliasStruct::my_alias( - MyAliasEnum _my_alias) -{ - m_my_alias = _my_alias; -} - -/*! - * @brief This function returns the value of member my_alias - * @return Value of member my_alias - */ -MyAliasEnum AliasStruct::my_alias() const -{ - return m_my_alias; -} - -/*! - * @brief This function returns a reference to member my_alias - * @return Reference to member my_alias - */ -MyAliasEnum& AliasStruct::my_alias() -{ - return m_my_alias; -} - - - - - -AliasAliasStruct::AliasAliasStruct() -{ - // MyAliasAliasEnum m_my_alias_alias - m_my_alias_alias = ::A; - - // Just to register all known types - registerBasicTypes(); -} - -AliasAliasStruct::~AliasAliasStruct() -{ -} - -AliasAliasStruct::AliasAliasStruct( - const AliasAliasStruct& x) -{ - m_my_alias_alias = x.m_my_alias_alias; - -} - -AliasAliasStruct::AliasAliasStruct( - AliasAliasStruct&& x) noexcept -{ - m_my_alias_alias = x.m_my_alias_alias; - -} - -AliasAliasStruct& AliasAliasStruct::operator =( - const AliasAliasStruct& x) -{ - m_my_alias_alias = x.m_my_alias_alias; - - return *this; -} - -AliasAliasStruct& AliasAliasStruct::operator =( - AliasAliasStruct&& x) noexcept -{ - m_my_alias_alias = x.m_my_alias_alias; - - return *this; -} - -bool AliasAliasStruct::operator ==( - const AliasAliasStruct& x) const -{ - return (m_my_alias_alias == x.m_my_alias_alias); -} - -bool AliasAliasStruct::operator !=( - const AliasAliasStruct& x) const -{ - return !(*this == x); -} - -size_t AliasAliasStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return AliasAliasStruct_max_cdr_typesize; -} - -size_t AliasAliasStruct::getCdrSerializedSize( - const AliasAliasStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - return current_alignment - initial_alignment; -} - - -void AliasAliasStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << (uint32_t)m_my_alias_alias; - -} - -void AliasAliasStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - { - uint32_t enum_value = 0; - dcdr >> enum_value; - m_my_alias_alias = (MyAliasAliasEnum)enum_value; - } - - -} - - -bool AliasAliasStruct::isKeyDefined() -{ - return false; -} - -void AliasAliasStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member my_alias_alias - * @param _my_alias_alias New value for member my_alias_alias - */ -void AliasAliasStruct::my_alias_alias( - MyAliasAliasEnum _my_alias_alias) -{ - m_my_alias_alias = _my_alias_alias; -} - -/*! - * @brief This function returns the value of member my_alias_alias - * @return Value of member my_alias_alias - */ -MyAliasAliasEnum AliasAliasStruct::my_alias_alias() const -{ - return m_my_alias_alias; -} - -/*! - * @brief This function returns a reference to member my_alias_alias - * @return Reference to member my_alias_alias - */ -MyAliasAliasEnum& AliasAliasStruct::my_alias_alias() -{ - return m_my_alias_alias; -} - - - - - -BoolStruct::BoolStruct() -{ - // boolean m_my_bool - m_my_bool = false; - - // Just to register all known types - registerBasicTypes(); -} - -BoolStruct::~BoolStruct() -{ -} - -BoolStruct::BoolStruct( - const BoolStruct& x) -{ - m_my_bool = x.m_my_bool; - -} - -BoolStruct::BoolStruct( - BoolStruct&& x) noexcept -{ - m_my_bool = x.m_my_bool; - -} - -BoolStruct& BoolStruct::operator =( - const BoolStruct& x) -{ - m_my_bool = x.m_my_bool; - - return *this; -} - -BoolStruct& BoolStruct::operator =( - BoolStruct&& x) noexcept -{ - m_my_bool = x.m_my_bool; - - return *this; -} - -bool BoolStruct::operator ==( - const BoolStruct& x) const -{ - return (m_my_bool == x.m_my_bool); -} - -bool BoolStruct::operator !=( - const BoolStruct& x) const -{ - return !(*this == x); -} - -size_t BoolStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return BoolStruct_max_cdr_typesize; -} - -size_t BoolStruct::getCdrSerializedSize( - const BoolStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - return current_alignment - initial_alignment; -} - - -void BoolStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_bool; - -} - -void BoolStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_bool; - - -} - - -bool BoolStruct::isKeyDefined() -{ - return false; -} - -void BoolStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member my_bool - * @param _my_bool New value for member my_bool - */ -void BoolStruct::my_bool( - bool _my_bool) -{ - m_my_bool = _my_bool; -} - -/*! - * @brief This function returns the value of member my_bool - * @return Value of member my_bool - */ -bool BoolStruct::my_bool() const -{ - return m_my_bool; -} - -/*! - * @brief This function returns a reference to member my_bool - * @return Reference to member my_bool - */ -bool& BoolStruct::my_bool() -{ - return m_my_bool; -} - - - - - -OctetStruct::OctetStruct() -{ - // octet m_my_octet - m_my_octet = 0; - - // Just to register all known types - registerBasicTypes(); -} - -OctetStruct::~OctetStruct() -{ -} - -OctetStruct::OctetStruct( - const OctetStruct& x) -{ - m_my_octet = x.m_my_octet; - -} - -OctetStruct::OctetStruct( - OctetStruct&& x) noexcept -{ - m_my_octet = x.m_my_octet; - -} - -OctetStruct& OctetStruct::operator =( - const OctetStruct& x) -{ - m_my_octet = x.m_my_octet; - - return *this; -} - -OctetStruct& OctetStruct::operator =( - OctetStruct&& x) noexcept -{ - m_my_octet = x.m_my_octet; - - return *this; -} - -bool OctetStruct::operator ==( - const OctetStruct& x) const -{ - return (m_my_octet == x.m_my_octet); -} - -bool OctetStruct::operator !=( - const OctetStruct& x) const -{ - return !(*this == x); -} - -size_t OctetStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return OctetStruct_max_cdr_typesize; -} - -size_t OctetStruct::getCdrSerializedSize( - const OctetStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - return current_alignment - initial_alignment; -} - - -void OctetStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_octet; - -} - -void OctetStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_octet; - - -} - - -bool OctetStruct::isKeyDefined() -{ - return false; -} - -void OctetStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member my_octet - * @param _my_octet New value for member my_octet - */ -void OctetStruct::my_octet( - uint8_t _my_octet) -{ - m_my_octet = _my_octet; -} - -/*! - * @brief This function returns the value of member my_octet - * @return Value of member my_octet - */ -uint8_t OctetStruct::my_octet() const -{ - return m_my_octet; -} - -/*! - * @brief This function returns a reference to member my_octet - * @return Reference to member my_octet - */ -uint8_t& OctetStruct::my_octet() -{ - return m_my_octet; -} - - - - - -ShortStruct::ShortStruct() -{ - // short m_my_int16 - m_my_int16 = 0; - - // Just to register all known types - registerBasicTypes(); -} - -ShortStruct::~ShortStruct() -{ -} - -ShortStruct::ShortStruct( - const ShortStruct& x) -{ - m_my_int16 = x.m_my_int16; - -} - -ShortStruct::ShortStruct( - ShortStruct&& x) noexcept -{ - m_my_int16 = x.m_my_int16; - -} - -ShortStruct& ShortStruct::operator =( - const ShortStruct& x) -{ - m_my_int16 = x.m_my_int16; - - return *this; -} - -ShortStruct& ShortStruct::operator =( - ShortStruct&& x) noexcept -{ - m_my_int16 = x.m_my_int16; - - return *this; -} - -bool ShortStruct::operator ==( - const ShortStruct& x) const -{ - return (m_my_int16 == x.m_my_int16); -} - -bool ShortStruct::operator !=( - const ShortStruct& x) const -{ - return !(*this == x); -} - -size_t ShortStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return ShortStruct_max_cdr_typesize; -} - -size_t ShortStruct::getCdrSerializedSize( - const ShortStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 2 + eprosima::fastcdr::Cdr::alignment(current_alignment, 2); - - - return current_alignment - initial_alignment; -} - - -void ShortStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_int16; - -} - -void ShortStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_int16; - - -} - - -bool ShortStruct::isKeyDefined() -{ - return false; -} - -void ShortStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member my_int16 - * @param _my_int16 New value for member my_int16 - */ -void ShortStruct::my_int16( - int16_t _my_int16) -{ - m_my_int16 = _my_int16; -} - -/*! - * @brief This function returns the value of member my_int16 - * @return Value of member my_int16 - */ -int16_t ShortStruct::my_int16() const -{ - return m_my_int16; -} - -/*! - * @brief This function returns a reference to member my_int16 - * @return Reference to member my_int16 - */ -int16_t& ShortStruct::my_int16() -{ - return m_my_int16; -} - - - - - -LongStruct::LongStruct() -{ - // long m_my_int32 - m_my_int32 = 0; - - // Just to register all known types - registerBasicTypes(); -} - -LongStruct::~LongStruct() -{ -} - -LongStruct::LongStruct( - const LongStruct& x) -{ - m_my_int32 = x.m_my_int32; - -} - -LongStruct::LongStruct( - LongStruct&& x) noexcept -{ - m_my_int32 = x.m_my_int32; - -} - -LongStruct& LongStruct::operator =( - const LongStruct& x) -{ - m_my_int32 = x.m_my_int32; - - return *this; -} - -LongStruct& LongStruct::operator =( - LongStruct&& x) noexcept -{ - m_my_int32 = x.m_my_int32; - - return *this; -} - -bool LongStruct::operator ==( - const LongStruct& x) const -{ - return (m_my_int32 == x.m_my_int32); -} - -bool LongStruct::operator !=( - const LongStruct& x) const -{ - return !(*this == x); -} - -size_t LongStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return LongStruct_max_cdr_typesize; -} - -size_t LongStruct::getCdrSerializedSize( - const LongStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - return current_alignment - initial_alignment; -} - - -void LongStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_int32; - -} - -void LongStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_int32; - - -} - - -bool LongStruct::isKeyDefined() -{ - return false; -} - -void LongStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member my_int32 - * @param _my_int32 New value for member my_int32 - */ -void LongStruct::my_int32( - int32_t _my_int32) -{ - m_my_int32 = _my_int32; -} - -/*! - * @brief This function returns the value of member my_int32 - * @return Value of member my_int32 - */ -int32_t LongStruct::my_int32() const -{ - return m_my_int32; -} - -/*! - * @brief This function returns a reference to member my_int32 - * @return Reference to member my_int32 - */ -int32_t& LongStruct::my_int32() -{ - return m_my_int32; -} - - - - - -LongLongStruct::LongLongStruct() -{ - // long long m_my_int64 - m_my_int64 = 0; - - // Just to register all known types - registerBasicTypes(); -} - -LongLongStruct::~LongLongStruct() -{ -} - -LongLongStruct::LongLongStruct( - const LongLongStruct& x) -{ - m_my_int64 = x.m_my_int64; - -} - -LongLongStruct::LongLongStruct( - LongLongStruct&& x) noexcept -{ - m_my_int64 = x.m_my_int64; - -} - -LongLongStruct& LongLongStruct::operator =( - const LongLongStruct& x) -{ - m_my_int64 = x.m_my_int64; - - return *this; -} - -LongLongStruct& LongLongStruct::operator =( - LongLongStruct&& x) noexcept -{ - m_my_int64 = x.m_my_int64; - - return *this; -} - -bool LongLongStruct::operator ==( - const LongLongStruct& x) const -{ - return (m_my_int64 == x.m_my_int64); -} - -bool LongLongStruct::operator !=( - const LongLongStruct& x) const -{ - return !(*this == x); -} - -size_t LongLongStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return LongLongStruct_max_cdr_typesize; -} - -size_t LongLongStruct::getCdrSerializedSize( - const LongLongStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 8 + eprosima::fastcdr::Cdr::alignment(current_alignment, 8); - - - return current_alignment - initial_alignment; -} - - -void LongLongStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_int64; - -} - -void LongLongStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_int64; - - -} - - -bool LongLongStruct::isKeyDefined() -{ - return false; -} - -void LongLongStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member my_int64 - * @param _my_int64 New value for member my_int64 - */ -void LongLongStruct::my_int64( - int64_t _my_int64) -{ - m_my_int64 = _my_int64; -} - -/*! - * @brief This function returns the value of member my_int64 - * @return Value of member my_int64 - */ -int64_t LongLongStruct::my_int64() const -{ - return m_my_int64; -} - -/*! - * @brief This function returns a reference to member my_int64 - * @return Reference to member my_int64 - */ -int64_t& LongLongStruct::my_int64() -{ - return m_my_int64; -} - - - - - -UShortStruct::UShortStruct() -{ - // unsigned short m_my_uint16 - m_my_uint16 = 0; - - // Just to register all known types - registerBasicTypes(); -} - -UShortStruct::~UShortStruct() -{ -} - -UShortStruct::UShortStruct( - const UShortStruct& x) -{ - m_my_uint16 = x.m_my_uint16; - -} - -UShortStruct::UShortStruct( - UShortStruct&& x) noexcept -{ - m_my_uint16 = x.m_my_uint16; - -} - -UShortStruct& UShortStruct::operator =( - const UShortStruct& x) -{ - m_my_uint16 = x.m_my_uint16; - - return *this; -} - -UShortStruct& UShortStruct::operator =( - UShortStruct&& x) noexcept -{ - m_my_uint16 = x.m_my_uint16; - - return *this; -} - -bool UShortStruct::operator ==( - const UShortStruct& x) const -{ - return (m_my_uint16 == x.m_my_uint16); -} - -bool UShortStruct::operator !=( - const UShortStruct& x) const -{ - return !(*this == x); -} - -size_t UShortStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return UShortStruct_max_cdr_typesize; -} - -size_t UShortStruct::getCdrSerializedSize( - const UShortStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 2 + eprosima::fastcdr::Cdr::alignment(current_alignment, 2); - - - return current_alignment - initial_alignment; -} - - -void UShortStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_uint16; - -} - -void UShortStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_uint16; - - -} - - -bool UShortStruct::isKeyDefined() -{ - return false; -} - -void UShortStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member my_uint16 - * @param _my_uint16 New value for member my_uint16 - */ -void UShortStruct::my_uint16( - uint16_t _my_uint16) -{ - m_my_uint16 = _my_uint16; -} - -/*! - * @brief This function returns the value of member my_uint16 - * @return Value of member my_uint16 - */ -uint16_t UShortStruct::my_uint16() const -{ - return m_my_uint16; -} - -/*! - * @brief This function returns a reference to member my_uint16 - * @return Reference to member my_uint16 - */ -uint16_t& UShortStruct::my_uint16() -{ - return m_my_uint16; -} - - - - - -ULongStruct::ULongStruct() -{ - // unsigned long m_my_uint32 - m_my_uint32 = 0; - - // Just to register all known types - registerBasicTypes(); -} - -ULongStruct::~ULongStruct() -{ -} - -ULongStruct::ULongStruct( - const ULongStruct& x) -{ - m_my_uint32 = x.m_my_uint32; - -} - -ULongStruct::ULongStruct( - ULongStruct&& x) noexcept -{ - m_my_uint32 = x.m_my_uint32; - -} - -ULongStruct& ULongStruct::operator =( - const ULongStruct& x) -{ - m_my_uint32 = x.m_my_uint32; - - return *this; -} - -ULongStruct& ULongStruct::operator =( - ULongStruct&& x) noexcept -{ - m_my_uint32 = x.m_my_uint32; - - return *this; -} - -bool ULongStruct::operator ==( - const ULongStruct& x) const -{ - return (m_my_uint32 == x.m_my_uint32); -} - -bool ULongStruct::operator !=( - const ULongStruct& x) const -{ - return !(*this == x); -} - -size_t ULongStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return ULongStruct_max_cdr_typesize; -} - -size_t ULongStruct::getCdrSerializedSize( - const ULongStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - return current_alignment - initial_alignment; -} - - -void ULongStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_uint32; - -} - -void ULongStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_uint32; - - -} - - -bool ULongStruct::isKeyDefined() -{ - return false; -} - -void ULongStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member my_uint32 - * @param _my_uint32 New value for member my_uint32 - */ -void ULongStruct::my_uint32( - uint32_t _my_uint32) -{ - m_my_uint32 = _my_uint32; -} - -/*! - * @brief This function returns the value of member my_uint32 - * @return Value of member my_uint32 - */ -uint32_t ULongStruct::my_uint32() const -{ - return m_my_uint32; -} - -/*! - * @brief This function returns a reference to member my_uint32 - * @return Reference to member my_uint32 - */ -uint32_t& ULongStruct::my_uint32() -{ - return m_my_uint32; -} - - - - - -ULongLongStruct::ULongLongStruct() -{ - // unsigned long long m_my_uint64 - m_my_uint64 = 0; - - // Just to register all known types - registerBasicTypes(); -} - -ULongLongStruct::~ULongLongStruct() -{ -} - -ULongLongStruct::ULongLongStruct( - const ULongLongStruct& x) -{ - m_my_uint64 = x.m_my_uint64; - -} - -ULongLongStruct::ULongLongStruct( - ULongLongStruct&& x) noexcept -{ - m_my_uint64 = x.m_my_uint64; - -} - -ULongLongStruct& ULongLongStruct::operator =( - const ULongLongStruct& x) -{ - m_my_uint64 = x.m_my_uint64; - - return *this; -} - -ULongLongStruct& ULongLongStruct::operator =( - ULongLongStruct&& x) noexcept -{ - m_my_uint64 = x.m_my_uint64; - - return *this; -} - -bool ULongLongStruct::operator ==( - const ULongLongStruct& x) const -{ - return (m_my_uint64 == x.m_my_uint64); -} - -bool ULongLongStruct::operator !=( - const ULongLongStruct& x) const -{ - return !(*this == x); -} - -size_t ULongLongStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return ULongLongStruct_max_cdr_typesize; -} - -size_t ULongLongStruct::getCdrSerializedSize( - const ULongLongStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 8 + eprosima::fastcdr::Cdr::alignment(current_alignment, 8); - - - return current_alignment - initial_alignment; -} - - -void ULongLongStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_uint64; - -} - -void ULongLongStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_uint64; - - -} - - -bool ULongLongStruct::isKeyDefined() -{ - return false; -} - -void ULongLongStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member my_uint64 - * @param _my_uint64 New value for member my_uint64 - */ -void ULongLongStruct::my_uint64( - uint64_t _my_uint64) -{ - m_my_uint64 = _my_uint64; -} - -/*! - * @brief This function returns the value of member my_uint64 - * @return Value of member my_uint64 - */ -uint64_t ULongLongStruct::my_uint64() const -{ - return m_my_uint64; -} - -/*! - * @brief This function returns a reference to member my_uint64 - * @return Reference to member my_uint64 - */ -uint64_t& ULongLongStruct::my_uint64() -{ - return m_my_uint64; -} - - - - - -FloatStruct::FloatStruct() -{ - // float m_my_float32 - m_my_float32 = 0.0; - - // Just to register all known types - registerBasicTypes(); -} - -FloatStruct::~FloatStruct() -{ -} - -FloatStruct::FloatStruct( - const FloatStruct& x) -{ - m_my_float32 = x.m_my_float32; - -} - -FloatStruct::FloatStruct( - FloatStruct&& x) noexcept -{ - m_my_float32 = x.m_my_float32; - -} - -FloatStruct& FloatStruct::operator =( - const FloatStruct& x) -{ - m_my_float32 = x.m_my_float32; - - return *this; -} - -FloatStruct& FloatStruct::operator =( - FloatStruct&& x) noexcept -{ - m_my_float32 = x.m_my_float32; - - return *this; -} - -bool FloatStruct::operator ==( - const FloatStruct& x) const -{ - return (m_my_float32 == x.m_my_float32); -} - -bool FloatStruct::operator !=( - const FloatStruct& x) const -{ - return !(*this == x); -} - -size_t FloatStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return FloatStruct_max_cdr_typesize; -} - -size_t FloatStruct::getCdrSerializedSize( - const FloatStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - return current_alignment - initial_alignment; -} - - -void FloatStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_float32; - -} - -void FloatStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_float32; - - -} - - -bool FloatStruct::isKeyDefined() -{ - return false; -} - -void FloatStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member my_float32 - * @param _my_float32 New value for member my_float32 - */ -void FloatStruct::my_float32( - float _my_float32) -{ - m_my_float32 = _my_float32; -} - -/*! - * @brief This function returns the value of member my_float32 - * @return Value of member my_float32 - */ -float FloatStruct::my_float32() const -{ - return m_my_float32; -} - -/*! - * @brief This function returns a reference to member my_float32 - * @return Reference to member my_float32 - */ -float& FloatStruct::my_float32() -{ - return m_my_float32; -} - - - - - -DoubleStruct::DoubleStruct() -{ - // double m_my_float64 - m_my_float64 = 0.0; - - // Just to register all known types - registerBasicTypes(); -} - -DoubleStruct::~DoubleStruct() -{ -} - -DoubleStruct::DoubleStruct( - const DoubleStruct& x) -{ - m_my_float64 = x.m_my_float64; - -} - -DoubleStruct::DoubleStruct( - DoubleStruct&& x) noexcept -{ - m_my_float64 = x.m_my_float64; - -} - -DoubleStruct& DoubleStruct::operator =( - const DoubleStruct& x) -{ - m_my_float64 = x.m_my_float64; - - return *this; -} - -DoubleStruct& DoubleStruct::operator =( - DoubleStruct&& x) noexcept -{ - m_my_float64 = x.m_my_float64; - - return *this; -} - -bool DoubleStruct::operator ==( - const DoubleStruct& x) const -{ - return (m_my_float64 == x.m_my_float64); -} - -bool DoubleStruct::operator !=( - const DoubleStruct& x) const -{ - return !(*this == x); -} - -size_t DoubleStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return DoubleStruct_max_cdr_typesize; -} - -size_t DoubleStruct::getCdrSerializedSize( - const DoubleStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 8 + eprosima::fastcdr::Cdr::alignment(current_alignment, 8); - - - return current_alignment - initial_alignment; -} - - -void DoubleStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_float64; - -} - -void DoubleStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_float64; - - -} - - -bool DoubleStruct::isKeyDefined() -{ - return false; -} - -void DoubleStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member my_float64 - * @param _my_float64 New value for member my_float64 - */ -void DoubleStruct::my_float64( - double _my_float64) -{ - m_my_float64 = _my_float64; -} - -/*! - * @brief This function returns the value of member my_float64 - * @return Value of member my_float64 - */ -double DoubleStruct::my_float64() const -{ - return m_my_float64; -} - -/*! - * @brief This function returns a reference to member my_float64 - * @return Reference to member my_float64 - */ -double& DoubleStruct::my_float64() -{ - return m_my_float64; -} - - - - - -LongDoubleStruct::LongDoubleStruct() -{ - // long double m_my_float128 - m_my_float128 = 0.0; - - // Just to register all known types - registerBasicTypes(); -} - -LongDoubleStruct::~LongDoubleStruct() -{ -} - -LongDoubleStruct::LongDoubleStruct( - const LongDoubleStruct& x) -{ - m_my_float128 = x.m_my_float128; - -} - -LongDoubleStruct::LongDoubleStruct( - LongDoubleStruct&& x) noexcept -{ - m_my_float128 = x.m_my_float128; - -} - -LongDoubleStruct& LongDoubleStruct::operator =( - const LongDoubleStruct& x) -{ - m_my_float128 = x.m_my_float128; - - return *this; -} - -LongDoubleStruct& LongDoubleStruct::operator =( - LongDoubleStruct&& x) noexcept -{ - m_my_float128 = x.m_my_float128; - - return *this; -} - -bool LongDoubleStruct::operator ==( - const LongDoubleStruct& x) const -{ - return (m_my_float128 == x.m_my_float128); -} - -bool LongDoubleStruct::operator !=( - const LongDoubleStruct& x) const -{ - return !(*this == x); -} - -size_t LongDoubleStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return LongDoubleStruct_max_cdr_typesize; -} - -size_t LongDoubleStruct::getCdrSerializedSize( - const LongDoubleStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 16 + eprosima::fastcdr::Cdr::alignment(current_alignment, 8); // 128 bits, but aligned as 64 - - - return current_alignment - initial_alignment; -} - - -void LongDoubleStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_float128; - -} - -void LongDoubleStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_float128; - - -} - - -bool LongDoubleStruct::isKeyDefined() -{ - return false; -} - -void LongDoubleStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member my_float128 - * @param _my_float128 New value for member my_float128 - */ -void LongDoubleStruct::my_float128( - long double _my_float128) -{ - m_my_float128 = _my_float128; -} - -/*! - * @brief This function returns the value of member my_float128 - * @return Value of member my_float128 - */ -long double LongDoubleStruct::my_float128() const -{ - return m_my_float128; -} - -/*! - * @brief This function returns a reference to member my_float128 - * @return Reference to member my_float128 - */ -long double& LongDoubleStruct::my_float128() -{ - return m_my_float128; -} - - - - - -CharStruct::CharStruct() -{ - // char m_my_char - m_my_char = 0; - - // Just to register all known types - registerBasicTypes(); -} - -CharStruct::~CharStruct() -{ -} - -CharStruct::CharStruct( - const CharStruct& x) -{ - m_my_char = x.m_my_char; - -} - -CharStruct::CharStruct( - CharStruct&& x) noexcept -{ - m_my_char = x.m_my_char; - -} - -CharStruct& CharStruct::operator =( - const CharStruct& x) -{ - m_my_char = x.m_my_char; - - return *this; -} - -CharStruct& CharStruct::operator =( - CharStruct&& x) noexcept -{ - m_my_char = x.m_my_char; - - return *this; -} - -bool CharStruct::operator ==( - const CharStruct& x) const -{ - return (m_my_char == x.m_my_char); -} - -bool CharStruct::operator !=( - const CharStruct& x) const -{ - return !(*this == x); -} - -size_t CharStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return CharStruct_max_cdr_typesize; -} - -size_t CharStruct::getCdrSerializedSize( - const CharStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - return current_alignment - initial_alignment; -} - - -void CharStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_char; - -} - -void CharStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_char; - - -} - - -bool CharStruct::isKeyDefined() -{ - return false; -} - -void CharStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member my_char - * @param _my_char New value for member my_char - */ -void CharStruct::my_char( - char _my_char) -{ - m_my_char = _my_char; -} - -/*! - * @brief This function returns the value of member my_char - * @return Value of member my_char - */ -char CharStruct::my_char() const -{ - return m_my_char; -} - -/*! - * @brief This function returns a reference to member my_char - * @return Reference to member my_char - */ -char& CharStruct::my_char() -{ - return m_my_char; -} - - - - - -WCharStruct::WCharStruct() -{ - // wchar m_my_wchar - m_my_wchar = 0; - - // Just to register all known types - registerBasicTypes(); -} - -WCharStruct::~WCharStruct() -{ -} - -WCharStruct::WCharStruct( - const WCharStruct& x) -{ - m_my_wchar = x.m_my_wchar; - -} - -WCharStruct::WCharStruct( - WCharStruct&& x) noexcept -{ - m_my_wchar = x.m_my_wchar; - -} - -WCharStruct& WCharStruct::operator =( - const WCharStruct& x) -{ - m_my_wchar = x.m_my_wchar; - - return *this; -} - -WCharStruct& WCharStruct::operator =( - WCharStruct&& x) noexcept -{ - m_my_wchar = x.m_my_wchar; - - return *this; -} - -bool WCharStruct::operator ==( - const WCharStruct& x) const -{ - return (m_my_wchar == x.m_my_wchar); -} - -bool WCharStruct::operator !=( - const WCharStruct& x) const -{ - return !(*this == x); -} - -size_t WCharStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return WCharStruct_max_cdr_typesize; -} - -size_t WCharStruct::getCdrSerializedSize( - const WCharStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - return current_alignment - initial_alignment; -} - - -void WCharStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_wchar; - -} - -void WCharStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_wchar; - - -} - - -bool WCharStruct::isKeyDefined() -{ - return false; -} - -void WCharStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member my_wchar - * @param _my_wchar New value for member my_wchar - */ -void WCharStruct::my_wchar( - wchar_t _my_wchar) -{ - m_my_wchar = _my_wchar; -} - -/*! - * @brief This function returns the value of member my_wchar - * @return Value of member my_wchar - */ -wchar_t WCharStruct::my_wchar() const -{ - return m_my_wchar; -} - -/*! - * @brief This function returns a reference to member my_wchar - * @return Reference to member my_wchar - */ -wchar_t& WCharStruct::my_wchar() -{ - return m_my_wchar; -} - - - - - -StringStruct::StringStruct() -{ - // /type_d() m_my_string - - - // Just to register all known types - registerBasicTypes(); -} - -StringStruct::~StringStruct() -{ -} - -StringStruct::StringStruct( - const StringStruct& x) -{ - m_my_string = x.m_my_string; - -} - -StringStruct::StringStruct( - StringStruct&& x) noexcept -{ - m_my_string = std::move(x.m_my_string); - -} - -StringStruct& StringStruct::operator =( - const StringStruct& x) -{ - m_my_string = x.m_my_string; - - return *this; -} - -StringStruct& StringStruct::operator =( - StringStruct&& x) noexcept -{ - m_my_string = std::move(x.m_my_string); - - return *this; -} - -bool StringStruct::operator ==( - const StringStruct& x) const -{ - return (m_my_string == x.m_my_string); -} - -bool StringStruct::operator !=( - const StringStruct& x) const -{ - return !(*this == x); -} - -size_t StringStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return StringStruct_max_cdr_typesize; -} - -size_t StringStruct::getCdrSerializedSize( - const StringStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + data.my_string().size() + 1; - - - return current_alignment - initial_alignment; -} - - -void StringStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_string.c_str(); - -} - -void StringStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_string; - - -} - - -bool StringStruct::isKeyDefined() -{ - return false; -} - -void StringStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_string - * @param _my_string New value to be copied in member my_string - */ -void StringStruct::my_string( - const std::string& _my_string) -{ - m_my_string = _my_string; -} - -/*! - * @brief This function moves the value in member my_string - * @param _my_string New value to be moved in member my_string - */ -void StringStruct::my_string( - std::string&& _my_string) -{ - m_my_string = std::move(_my_string); -} - -/*! - * @brief This function returns a constant reference to member my_string - * @return Constant reference to member my_string - */ -const std::string& StringStruct::my_string() const -{ - return m_my_string; -} - -/*! - * @brief This function returns a reference to member my_string - * @return Reference to member my_string - */ -std::string& StringStruct::my_string() -{ - return m_my_string; -} - - - - - -WStringStruct::WStringStruct() -{ - // /type_15() m_my_wstring - - - // Just to register all known types - registerBasicTypes(); -} - -WStringStruct::~WStringStruct() -{ -} - -WStringStruct::WStringStruct( - const WStringStruct& x) -{ - m_my_wstring = x.m_my_wstring; - -} - -WStringStruct::WStringStruct( - WStringStruct&& x) noexcept -{ - m_my_wstring = std::move(x.m_my_wstring); - -} - -WStringStruct& WStringStruct::operator =( - const WStringStruct& x) -{ - m_my_wstring = x.m_my_wstring; - - return *this; -} - -WStringStruct& WStringStruct::operator =( - WStringStruct&& x) noexcept -{ - m_my_wstring = std::move(x.m_my_wstring); - - return *this; -} - -bool WStringStruct::operator ==( - const WStringStruct& x) const -{ - return (m_my_wstring == x.m_my_wstring); -} - -bool WStringStruct::operator !=( - const WStringStruct& x) const -{ - return !(*this == x); -} - -size_t WStringStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return WStringStruct_max_cdr_typesize; -} - -size_t WStringStruct::getCdrSerializedSize( - const WStringStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + (data.my_wstring().size()) * 4; // 32 bits - - - return current_alignment - initial_alignment; -} - - -void WStringStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_wstring; - -} - -void WStringStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_wstring; - - -} - - -bool WStringStruct::isKeyDefined() -{ - return false; -} - -void WStringStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_wstring - * @param _my_wstring New value to be copied in member my_wstring - */ -void WStringStruct::my_wstring( - const std::wstring& _my_wstring) -{ - m_my_wstring = _my_wstring; -} - -/*! - * @brief This function moves the value in member my_wstring - * @param _my_wstring New value to be moved in member my_wstring - */ -void WStringStruct::my_wstring( - std::wstring&& _my_wstring) -{ - m_my_wstring = std::move(_my_wstring); -} - -/*! - * @brief This function returns a constant reference to member my_wstring - * @return Constant reference to member my_wstring - */ -const std::wstring& WStringStruct::my_wstring() const -{ - return m_my_wstring; -} - -/*! - * @brief This function returns a reference to member my_wstring - * @return Reference to member my_wstring - */ -std::wstring& WStringStruct::my_wstring() -{ - return m_my_wstring; -} - - - - - -LargeStringStruct::LargeStringStruct() -{ - // /type_d() m_my_large_string - - - // Just to register all known types - registerBasicTypes(); -} - -LargeStringStruct::~LargeStringStruct() -{ -} - -LargeStringStruct::LargeStringStruct( - const LargeStringStruct& x) -{ - m_my_large_string = x.m_my_large_string; - -} - -LargeStringStruct::LargeStringStruct( - LargeStringStruct&& x) noexcept -{ - m_my_large_string = std::move(x.m_my_large_string); - -} - -LargeStringStruct& LargeStringStruct::operator =( - const LargeStringStruct& x) -{ - m_my_large_string = x.m_my_large_string; - - return *this; -} - -LargeStringStruct& LargeStringStruct::operator =( - LargeStringStruct&& x) noexcept -{ - m_my_large_string = std::move(x.m_my_large_string); - - return *this; -} - -bool LargeStringStruct::operator ==( - const LargeStringStruct& x) const -{ - return (m_my_large_string == x.m_my_large_string); -} - -bool LargeStringStruct::operator !=( - const LargeStringStruct& x) const -{ - return !(*this == x); -} - -size_t LargeStringStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return LargeStringStruct_max_cdr_typesize; -} - -size_t LargeStringStruct::getCdrSerializedSize( - const LargeStringStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + data.my_large_string().size() + 1; - - - return current_alignment - initial_alignment; -} - - -void LargeStringStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_large_string.c_str(); - -} - -void LargeStringStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - { - std::string aux; - dcdr >> aux; - m_my_large_string = aux.c_str(); - } - - -} - - -bool LargeStringStruct::isKeyDefined() -{ - return false; -} - -void LargeStringStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_large_string - * @param _my_large_string New value to be copied in member my_large_string - */ -void LargeStringStruct::my_large_string( - const eprosima::fastrtps::fixed_string<41925>& _my_large_string) -{ - m_my_large_string = _my_large_string; -} - -/*! - * @brief This function moves the value in member my_large_string - * @param _my_large_string New value to be moved in member my_large_string - */ -void LargeStringStruct::my_large_string( - eprosima::fastrtps::fixed_string<41925>&& _my_large_string) -{ - m_my_large_string = std::move(_my_large_string); -} - -/*! - * @brief This function returns a constant reference to member my_large_string - * @return Constant reference to member my_large_string - */ -const eprosima::fastrtps::fixed_string<41925>& LargeStringStruct::my_large_string() const -{ - return m_my_large_string; -} - -/*! - * @brief This function returns a reference to member my_large_string - * @return Reference to member my_large_string - */ -eprosima::fastrtps::fixed_string<41925>& LargeStringStruct::my_large_string() -{ - return m_my_large_string; -} - - - - - -LargeWStringStruct::LargeWStringStruct() -{ - // /type_15() m_my_large_wstring - - - // Just to register all known types - registerBasicTypes(); -} - -LargeWStringStruct::~LargeWStringStruct() -{ -} - -LargeWStringStruct::LargeWStringStruct( - const LargeWStringStruct& x) -{ - m_my_large_wstring = x.m_my_large_wstring; - -} - -LargeWStringStruct::LargeWStringStruct( - LargeWStringStruct&& x) noexcept -{ - m_my_large_wstring = std::move(x.m_my_large_wstring); - -} - -LargeWStringStruct& LargeWStringStruct::operator =( - const LargeWStringStruct& x) -{ - m_my_large_wstring = x.m_my_large_wstring; - - return *this; -} - -LargeWStringStruct& LargeWStringStruct::operator =( - LargeWStringStruct&& x) noexcept -{ - m_my_large_wstring = std::move(x.m_my_large_wstring); - - return *this; -} - -bool LargeWStringStruct::operator ==( - const LargeWStringStruct& x) const -{ - return (m_my_large_wstring == x.m_my_large_wstring); -} - -bool LargeWStringStruct::operator !=( - const LargeWStringStruct& x) const -{ - return !(*this == x); -} - -size_t LargeWStringStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return LargeWStringStruct_max_cdr_typesize; -} - -size_t LargeWStringStruct::getCdrSerializedSize( - const LargeWStringStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + (data.my_large_wstring().size()) * 4; // 32 bits - - - return current_alignment - initial_alignment; -} - - -void LargeWStringStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_large_wstring; - -} - -void LargeWStringStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_large_wstring; - - -} - - -bool LargeWStringStruct::isKeyDefined() -{ - return false; -} - -void LargeWStringStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_large_wstring - * @param _my_large_wstring New value to be copied in member my_large_wstring - */ -void LargeWStringStruct::my_large_wstring( - const std::wstring& _my_large_wstring) -{ - m_my_large_wstring = _my_large_wstring; -} - -/*! - * @brief This function moves the value in member my_large_wstring - * @param _my_large_wstring New value to be moved in member my_large_wstring - */ -void LargeWStringStruct::my_large_wstring( - std::wstring&& _my_large_wstring) -{ - m_my_large_wstring = std::move(_my_large_wstring); -} - -/*! - * @brief This function returns a constant reference to member my_large_wstring - * @return Constant reference to member my_large_wstring - */ -const std::wstring& LargeWStringStruct::my_large_wstring() const -{ - return m_my_large_wstring; -} - -/*! - * @brief This function returns a reference to member my_large_wstring - * @return Reference to member my_large_wstring - */ -std::wstring& LargeWStringStruct::my_large_wstring() -{ - return m_my_large_wstring; -} - - - - - -ArraytStruct::ArraytStruct() -{ - // long m_my_array - memset(&m_my_array, 0, ((2) * (2) * (2)) * 4); - - // Just to register all known types - registerBasicTypes(); -} - -ArraytStruct::~ArraytStruct() -{ -} - -ArraytStruct::ArraytStruct( - const ArraytStruct& x) -{ - m_my_array = x.m_my_array; - -} - -ArraytStruct::ArraytStruct( - ArraytStruct&& x) noexcept -{ - m_my_array = std::move(x.m_my_array); - -} - -ArraytStruct& ArraytStruct::operator =( - const ArraytStruct& x) -{ - m_my_array = x.m_my_array; - - return *this; -} - -ArraytStruct& ArraytStruct::operator =( - ArraytStruct&& x) noexcept -{ - m_my_array = std::move(x.m_my_array); - - return *this; -} - -bool ArraytStruct::operator ==( - const ArraytStruct& x) const -{ - return (m_my_array == x.m_my_array); -} - -bool ArraytStruct::operator !=( - const ArraytStruct& x) const -{ - return !(*this == x); -} - -size_t ArraytStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return ArraytStruct_max_cdr_typesize; -} - -size_t ArraytStruct::getCdrSerializedSize( - const ArraytStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += (((2) * (2) * (2)) * 4) + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - - return current_alignment - initial_alignment; -} - - -void ArraytStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - for (uint32_t b = 0; b < m_my_array.size(); ++b) - { - for (uint32_t c = 0; c < m_my_array[b].size(); ++c) - { - scdr << m_my_array[b][c]; - - } - - } - - - -} - -void ArraytStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - for (uint32_t e = 0; e < m_my_array.size(); ++e) - { - for (uint32_t f = 0; f < m_my_array[e].size(); ++f) - { - dcdr >> m_my_array[e][f]; - - } - - } - - - -} - - -bool ArraytStruct::isKeyDefined() -{ - return false; -} - -void ArraytStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_array - * @param _my_array New value to be copied in member my_array - */ -void ArraytStruct::my_array( - const std::array, 2>, 2>& _my_array) -{ - m_my_array = _my_array; -} - -/*! - * @brief This function moves the value in member my_array - * @param _my_array New value to be moved in member my_array - */ -void ArraytStruct::my_array( - std::array, 2>, 2>&& _my_array) -{ - m_my_array = std::move(_my_array); -} - -/*! - * @brief This function returns a constant reference to member my_array - * @return Constant reference to member my_array - */ -const std::array, 2>, 2>& ArraytStruct::my_array() const -{ - return m_my_array; -} - -/*! - * @brief This function returns a reference to member my_array - * @return Reference to member my_array - */ -std::array, 2>, 2>& ArraytStruct::my_array() -{ - return m_my_array; -} - - - - - - -ArrayArrayStruct::ArrayArrayStruct() -{ - // MyArray m_my_array_array - - - // Just to register all known types - registerBasicTypes(); -} - -ArrayArrayStruct::~ArrayArrayStruct() -{ -} - -ArrayArrayStruct::ArrayArrayStruct( - const ArrayArrayStruct& x) -{ - m_my_array_array = x.m_my_array_array; - -} - -ArrayArrayStruct::ArrayArrayStruct( - ArrayArrayStruct&& x) noexcept -{ - m_my_array_array = std::move(x.m_my_array_array); - -} - -ArrayArrayStruct& ArrayArrayStruct::operator =( - const ArrayArrayStruct& x) -{ - m_my_array_array = x.m_my_array_array; - - return *this; -} - -ArrayArrayStruct& ArrayArrayStruct::operator =( - ArrayArrayStruct&& x) noexcept -{ - m_my_array_array = std::move(x.m_my_array_array); - - return *this; -} - -bool ArrayArrayStruct::operator ==( - const ArrayArrayStruct& x) const -{ - return (m_my_array_array == x.m_my_array_array); -} - -bool ArrayArrayStruct::operator !=( - const ArrayArrayStruct& x) const -{ - return !(*this == x); -} - -size_t ArrayArrayStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return ArrayArrayStruct_max_cdr_typesize; -} - -size_t ArrayArrayStruct::getCdrSerializedSize( - const ArrayArrayStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - - for(size_t a = 0; a < data.my_array_array().size(); ++a) - { - - for(size_t b = 0; b < data.my_array_array().at(a).size(); ++b) - { - current_alignment += (((2) * (2)) * 4) + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - } - - } - - - - return current_alignment - initial_alignment; -} - - -void ArrayArrayStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - for (uint32_t d = 0; d < m_my_array_array.size(); ++d) - { - scdr << m_my_array_array[d]; - - } - - - -} - -void ArrayArrayStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - for (uint32_t f = 0; f < m_my_array_array.size(); ++f) - { - dcdr >> m_my_array_array[f]; - - } - - - -} - - -bool ArrayArrayStruct::isKeyDefined() -{ - return false; -} - -void ArrayArrayStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_array_array - * @param _my_array_array New value to be copied in member my_array_array - */ -void ArrayArrayStruct::my_array_array( - const std::array, 2>& _my_array_array) -{ - m_my_array_array = _my_array_array; -} - -/*! - * @brief This function moves the value in member my_array_array - * @param _my_array_array New value to be moved in member my_array_array - */ -void ArrayArrayStruct::my_array_array( - std::array, 2>&& _my_array_array) -{ - m_my_array_array = std::move(_my_array_array); -} - -/*! - * @brief This function returns a constant reference to member my_array_array - * @return Constant reference to member my_array_array - */ -const std::array, 2>& ArrayArrayStruct::my_array_array() const -{ - return m_my_array_array; -} - -/*! - * @brief This function returns a reference to member my_array_array - * @return Reference to member my_array_array - */ -std::array, 2>& ArrayArrayStruct::my_array_array() -{ - return m_my_array_array; -} - - - - - - - -SequenceStruct::SequenceStruct() -{ - // sequence m_my_sequence - - - // Just to register all known types - registerBasicTypes(); -} - -SequenceStruct::~SequenceStruct() -{ -} - -SequenceStruct::SequenceStruct( - const SequenceStruct& x) -{ - m_my_sequence = x.m_my_sequence; - -} - -SequenceStruct::SequenceStruct( - SequenceStruct&& x) noexcept -{ - m_my_sequence = std::move(x.m_my_sequence); - -} - -SequenceStruct& SequenceStruct::operator =( - const SequenceStruct& x) -{ - m_my_sequence = x.m_my_sequence; - - return *this; -} - -SequenceStruct& SequenceStruct::operator =( - SequenceStruct&& x) noexcept -{ - m_my_sequence = std::move(x.m_my_sequence); - - return *this; -} - -bool SequenceStruct::operator ==( - const SequenceStruct& x) const -{ - return (m_my_sequence == x.m_my_sequence); -} - -bool SequenceStruct::operator !=( - const SequenceStruct& x) const -{ - return !(*this == x); -} - -size_t SequenceStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return SequenceStruct_max_cdr_typesize; -} - -size_t SequenceStruct::getCdrSerializedSize( - const SequenceStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - if (data.my_sequence().size() > 0) - { - current_alignment += (data.my_sequence().size() * 4) + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - } - - - - - return current_alignment - initial_alignment; -} - - -void SequenceStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_sequence; - - -} - -void SequenceStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_sequence; - - -} - - -bool SequenceStruct::isKeyDefined() -{ - return false; -} - -void SequenceStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_sequence - * @param _my_sequence New value to be copied in member my_sequence - */ -void SequenceStruct::my_sequence( - const std::vector& _my_sequence) -{ - m_my_sequence = _my_sequence; -} - -/*! - * @brief This function moves the value in member my_sequence - * @param _my_sequence New value to be moved in member my_sequence - */ -void SequenceStruct::my_sequence( - std::vector&& _my_sequence) -{ - m_my_sequence = std::move(_my_sequence); -} - -/*! - * @brief This function returns a constant reference to member my_sequence - * @return Constant reference to member my_sequence - */ -const std::vector& SequenceStruct::my_sequence() const -{ - return m_my_sequence; -} - -/*! - * @brief This function returns a reference to member my_sequence - * @return Reference to member my_sequence - */ -std::vector& SequenceStruct::my_sequence() -{ - return m_my_sequence; -} - - - - - - - - - -SequenceSequenceStruct::SequenceSequenceStruct() -{ - // sequence, 3> m_my_sequence_sequence - - - // Just to register all known types - registerBasicTypes(); -} - -SequenceSequenceStruct::~SequenceSequenceStruct() -{ -} - -SequenceSequenceStruct::SequenceSequenceStruct( - const SequenceSequenceStruct& x) -{ - m_my_sequence_sequence = x.m_my_sequence_sequence; - -} - -SequenceSequenceStruct::SequenceSequenceStruct( - SequenceSequenceStruct&& x) noexcept -{ - m_my_sequence_sequence = std::move(x.m_my_sequence_sequence); - -} - -SequenceSequenceStruct& SequenceSequenceStruct::operator =( - const SequenceSequenceStruct& x) -{ - m_my_sequence_sequence = x.m_my_sequence_sequence; - - return *this; -} - -SequenceSequenceStruct& SequenceSequenceStruct::operator =( - SequenceSequenceStruct&& x) noexcept -{ - m_my_sequence_sequence = std::move(x.m_my_sequence_sequence); - - return *this; -} - -bool SequenceSequenceStruct::operator ==( - const SequenceSequenceStruct& x) const -{ - return (m_my_sequence_sequence == x.m_my_sequence_sequence); -} - -bool SequenceSequenceStruct::operator !=( - const SequenceSequenceStruct& x) const -{ - return !(*this == x); -} - -size_t SequenceSequenceStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return SequenceSequenceStruct_max_cdr_typesize; -} - -size_t SequenceSequenceStruct::getCdrSerializedSize( - const SequenceSequenceStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - for(size_t a = 0; a < data.my_sequence_sequence().size(); ++a) - { - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - if (data.my_sequence_sequence().at(a).size() > 0) - { - current_alignment += (data.my_sequence_sequence().at(a).size() * 4) + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - } - - - } - - - - return current_alignment - initial_alignment; -} - - -void SequenceSequenceStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_sequence_sequence; - - -} - -void SequenceSequenceStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_sequence_sequence; - - -} - - -bool SequenceSequenceStruct::isKeyDefined() -{ - return false; -} - -void SequenceSequenceStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_sequence_sequence - * @param _my_sequence_sequence New value to be copied in member my_sequence_sequence - */ -void SequenceSequenceStruct::my_sequence_sequence( - const std::vector>& _my_sequence_sequence) -{ - m_my_sequence_sequence = _my_sequence_sequence; -} - -/*! - * @brief This function moves the value in member my_sequence_sequence - * @param _my_sequence_sequence New value to be moved in member my_sequence_sequence - */ -void SequenceSequenceStruct::my_sequence_sequence( - std::vector>&& _my_sequence_sequence) -{ - m_my_sequence_sequence = std::move(_my_sequence_sequence); -} - -/*! - * @brief This function returns a constant reference to member my_sequence_sequence - * @return Constant reference to member my_sequence_sequence - */ -const std::vector>& SequenceSequenceStruct::my_sequence_sequence() const -{ - return m_my_sequence_sequence; -} - -/*! - * @brief This function returns a reference to member my_sequence_sequence - * @return Reference to member my_sequence_sequence - */ -std::vector>& SequenceSequenceStruct::my_sequence_sequence() -{ - return m_my_sequence_sequence; -} - - - - - - - -MapStruct::MapStruct() -{ - // map m_my_map - - - // Just to register all known types - registerBasicTypes(); -} - -MapStruct::~MapStruct() -{ -} - -MapStruct::MapStruct( - const MapStruct& x) -{ - m_my_map = x.m_my_map; - -} - -MapStruct::MapStruct( - MapStruct&& x) noexcept -{ - m_my_map = std::move(x.m_my_map); - -} - -MapStruct& MapStruct::operator =( - const MapStruct& x) -{ - m_my_map = x.m_my_map; - - return *this; -} - -MapStruct& MapStruct::operator =( - MapStruct&& x) noexcept -{ - m_my_map = std::move(x.m_my_map); - - return *this; -} - -bool MapStruct::operator ==( - const MapStruct& x) const -{ - return (m_my_map == x.m_my_map); -} - -bool MapStruct::operator !=( - const MapStruct& x) const -{ - return !(*this == x); -} - -size_t MapStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return MapStruct_max_cdr_typesize; -} - -size_t MapStruct::getCdrSerializedSize( - const MapStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - for(auto a : data.my_map()) - { - (void)a; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - } - - - return current_alignment - initial_alignment; -} - - -void MapStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << static_cast(m_my_map.size()); - for (const auto& pair : m_my_map) - { - scdr << pair.first; - scdr << pair.second; - } - -} - -void MapStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - - dcdr >> m_my_map; - - -} - - -bool MapStruct::isKeyDefined() -{ - return false; -} - -void MapStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_map - * @param _my_map New value to be copied in member my_map - */ -void MapStruct::my_map( - const std::map& _my_map) -{ - m_my_map = _my_map; -} - -/*! - * @brief This function moves the value in member my_map - * @param _my_map New value to be moved in member my_map - */ -void MapStruct::my_map( - std::map&& _my_map) -{ - m_my_map = std::move(_my_map); -} - -/*! - * @brief This function returns a constant reference to member my_map - * @return Constant reference to member my_map - */ -const std::map& MapStruct::my_map() const -{ - return m_my_map; -} - -/*! - * @brief This function returns a reference to member my_map - * @return Reference to member my_map - */ -std::map& MapStruct::my_map() -{ - return m_my_map; -} - - - - - - - - - -MapMapStruct::MapMapStruct() -{ - // map> m_my_map_map - - - // Just to register all known types - registerBasicTypes(); -} - -MapMapStruct::~MapMapStruct() -{ -} - -MapMapStruct::MapMapStruct( - const MapMapStruct& x) -{ - m_my_map_map = x.m_my_map_map; - -} - -MapMapStruct::MapMapStruct( - MapMapStruct&& x) noexcept -{ - m_my_map_map = std::move(x.m_my_map_map); - -} - -MapMapStruct& MapMapStruct::operator =( - const MapMapStruct& x) -{ - m_my_map_map = x.m_my_map_map; - - return *this; -} - -MapMapStruct& MapMapStruct::operator =( - MapMapStruct&& x) noexcept -{ - m_my_map_map = std::move(x.m_my_map_map); - - return *this; -} - -bool MapMapStruct::operator ==( - const MapMapStruct& x) const -{ - return (m_my_map_map == x.m_my_map_map); -} - -bool MapMapStruct::operator !=( - const MapMapStruct& x) const -{ - return !(*this == x); -} - -size_t MapMapStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return MapMapStruct_max_cdr_typesize; -} - -size_t MapMapStruct::getCdrSerializedSize( - const MapMapStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - for(auto a : data.my_map_map()) - { - (void)a; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - for(auto b : a.second) - { - (void)b; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - } - - } - - - return current_alignment - initial_alignment; -} - - -void MapMapStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << static_cast(m_my_map_map.size()); - for (const auto& pair : m_my_map_map) - { - scdr << pair.first; - scdr << pair.second; - } - -} - -void MapMapStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - - dcdr >> m_my_map_map; - - -} - - -bool MapMapStruct::isKeyDefined() -{ - return false; -} - -void MapMapStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_map_map - * @param _my_map_map New value to be copied in member my_map_map - */ -void MapMapStruct::my_map_map( - const std::map>& _my_map_map) -{ - m_my_map_map = _my_map_map; -} - -/*! - * @brief This function moves the value in member my_map_map - * @param _my_map_map New value to be moved in member my_map_map - */ -void MapMapStruct::my_map_map( - std::map>&& _my_map_map) -{ - m_my_map_map = std::move(_my_map_map); -} - -/*! - * @brief This function returns a constant reference to member my_map_map - * @return Constant reference to member my_map_map - */ -const std::map>& MapMapStruct::my_map_map() const -{ - return m_my_map_map; -} - -/*! - * @brief This function returns a reference to member my_map_map - * @return Reference to member my_map_map - */ -std::map>& MapMapStruct::my_map_map() -{ - return m_my_map_map; -} - - - -MyBitset::MyBitset() -{ - // Just to register all known types - registerBasicTypes(); -} - -MyBitset::~MyBitset() -{ -} - -MyBitset::MyBitset( - const MyBitset& x) -{ - m_bitset = x.m_bitset; -} - -MyBitset::MyBitset( - MyBitset&& x) noexcept -{ - m_bitset = x.m_bitset; -} - -MyBitset& MyBitset::operator =( - const MyBitset& x) -{ - m_bitset = x.m_bitset; - - return *this; -} - -MyBitset& MyBitset::operator =( - MyBitset&& x) noexcept -{ - m_bitset = x.m_bitset; - - return *this; -} - -bool MyBitset::operator ==( - const MyBitset& x) const -{ - return m_bitset == x.m_bitset; -} - -bool MyBitset::operator !=( - const MyBitset& x) const -{ - return !(*this == x); -} - -size_t MyBitset::getCdrSerializedSize( - const MyBitset&, - size_t current_alignment) -{ - size_t initial_alignment = current_alignment; - - current_alignment += sizeof(helper::FindType<30>::type) + - eprosima::fastcdr::Cdr::alignment(current_alignment, sizeof(helper::FindType<30>::type)); - - return current_alignment - initial_alignment; -} - - -void MyBitset::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - helper::FindType<30>::type bits = static_cast::type>(bitset().to_ullong()); - scdr << bits; -} - -void MyBitset::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - helper::FindType<30>::type bits; - dcdr >> bits; - bitset(std::bitset<30>(bits)); -} - - - -void MyBitset::a( - char _a) -{ - int base = 0; - int size = 2; - for (int i = base; i < base + size; ++i) - { - m_bitset.set(i, !!(_a & 0x01)); - _a = _a >> 1; - } - -} - -char MyBitset::a() const -{ - int base = 0; - int size = 2; - std::bitset<2> aux; - for (int i = 0; i < size; ++i) - { - aux.set(i, m_bitset.test(i + base)); - } - return static_cast(aux.to_ullong()); - -} - - - -void MyBitset::b( - uint32_t _b) -{ - int base = 10; - int size = 20; - for (int i = base; i < base + size; ++i) - { - m_bitset.set(i, !!(_b & 0x01)); - _b = _b >> 1; - } - -} - -uint32_t MyBitset::b() const -{ - int base = 10; - int size = 20; - std::bitset<20> aux; - for (int i = 0; i < size; ++i) - { - aux.set(i, m_bitset.test(i + base)); - } - return static_cast(aux.to_ullong()); - -} - - -std::bitset<30> MyBitset::bitset() const -{ - std::string str_value; - - str_value = m_bitset.to_string() + str_value; - - return std::bitset<30>(str_value); -} - -void MyBitset::bitset( - const std::bitset<30>& bitset) -{ - std::string str_value {bitset.to_string()}; - size_t base_diff {0}; - size_t last_post {std::string::npos}; - - base_diff += 30; - m_bitset = std::bitset<30>(str_value.substr(str_value.length() - base_diff, last_post)); -} - - - -BitsetStruct::BitsetStruct() -{ - // MyBitset m_a - - - // Just to register all known types - registerBasicTypes(); -} - -BitsetStruct::~BitsetStruct() -{ -} - -BitsetStruct::BitsetStruct( - const BitsetStruct& x) -{ - m_a = x.m_a; - -} - -BitsetStruct::BitsetStruct( - BitsetStruct&& x) noexcept -{ - m_a = std::move(x.m_a); - -} - -BitsetStruct& BitsetStruct::operator =( - const BitsetStruct& x) -{ - m_a = x.m_a; - - return *this; -} - -BitsetStruct& BitsetStruct::operator =( - BitsetStruct&& x) noexcept -{ - m_a = std::move(x.m_a); - - return *this; -} - -bool BitsetStruct::operator ==( - const BitsetStruct& x) const -{ - return (m_a == x.m_a); -} - -bool BitsetStruct::operator !=( - const BitsetStruct& x) const -{ - return !(*this == x); -} - -size_t BitsetStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return BitsetStruct_max_cdr_typesize; -} - -size_t BitsetStruct::getCdrSerializedSize( - const BitsetStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += MyBitset::getCdrSerializedSize(data.a(), current_alignment); - - - return current_alignment - initial_alignment; -} - - -void BitsetStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_a; - -} - -void BitsetStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_a; - - -} - - -bool BitsetStruct::isKeyDefined() -{ - return false; -} - -void BitsetStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member a - * @param _a New value to be copied in member a - */ -void BitsetStruct::a( - const MyBitset& _a) -{ - m_a = _a; -} - -/*! - * @brief This function moves the value in member a - * @param _a New value to be moved in member a - */ -void BitsetStruct::a( - MyBitset&& _a) -{ - m_a = std::move(_a); -} - -/*! - * @brief This function returns a constant reference to member a - * @return Constant reference to member a - */ -const MyBitset& BitsetStruct::a() const -{ - return m_a; -} - -/*! - * @brief This function returns a reference to member a - * @return Reference to member a - */ -MyBitset& BitsetStruct::a() -{ - return m_a; -} - - - - - -StructStruct::StructStruct() -{ - // long m_a - m_a = 0; - // long long m_b - m_b = 0; - - // Just to register all known types - registerBasicTypes(); -} - -StructStruct::~StructStruct() -{ -} - -StructStruct::StructStruct( - const StructStruct& x) -{ - m_a = x.m_a; - - - m_b = x.m_b; - -} - -StructStruct::StructStruct( - StructStruct&& x) noexcept -{ - m_a = x.m_a; - - - m_b = x.m_b; - -} - -StructStruct& StructStruct::operator =( - const StructStruct& x) -{ - m_a = x.m_a; - - - m_b = x.m_b; - - return *this; -} - -StructStruct& StructStruct::operator =( - StructStruct&& x) noexcept -{ - m_a = x.m_a; - - - m_b = x.m_b; - - return *this; -} - -bool StructStruct::operator ==( - const StructStruct& x) const -{ - return (m_a == x.m_a && - m_b == x.m_b); -} - -bool StructStruct::operator !=( - const StructStruct& x) const -{ - return !(*this == x); -} - -size_t StructStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return StructStruct_max_cdr_typesize; -} - -size_t StructStruct::getCdrSerializedSize( - const StructStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += 8 + eprosima::fastcdr::Cdr::alignment(current_alignment, 8); - - - return current_alignment - initial_alignment; -} - - -void StructStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_a; - - scdr << m_b; - -} - -void StructStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_a; - - - - dcdr >> m_b; - - -} - - -bool StructStruct::isKeyDefined() -{ - return false; -} - -void StructStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member a - * @param _a New value for member a - */ -void StructStruct::a( - int32_t _a) -{ - m_a = _a; -} - -/*! - * @brief This function returns the value of member a - * @return Value of member a - */ -int32_t StructStruct::a() const -{ - return m_a; -} - -/*! - * @brief This function returns a reference to member a - * @return Reference to member a - */ -int32_t& StructStruct::a() -{ - return m_a; -} - - -/*! - * @brief This function sets a value in member b - * @param _b New value for member b - */ -void StructStruct::b( - int64_t _b) -{ - m_b = _b; -} - -/*! - * @brief This function returns the value of member b - * @return Value of member b - */ -int64_t StructStruct::b() const -{ - return m_b; -} - -/*! - * @brief This function returns a reference to member b - * @return Reference to member b - */ -int64_t& StructStruct::b() -{ - return m_b; -} - - - - - -StructStructStruct::StructStructStruct() -{ - // StructStruct m_child_struct - - // long long m_child_int64 - m_child_int64 = 0; - - // Just to register all known types - registerBasicTypes(); -} - -StructStructStruct::~StructStructStruct() -{ -} - -StructStructStruct::StructStructStruct( - const StructStructStruct& x) -{ - m_child_struct = x.m_child_struct; - - - m_child_int64 = x.m_child_int64; - -} - -StructStructStruct::StructStructStruct( - StructStructStruct&& x) noexcept -{ - m_child_struct = std::move(x.m_child_struct); - - - m_child_int64 = x.m_child_int64; - -} - -StructStructStruct& StructStructStruct::operator =( - const StructStructStruct& x) -{ - m_child_struct = x.m_child_struct; - - - m_child_int64 = x.m_child_int64; - - return *this; -} - -StructStructStruct& StructStructStruct::operator =( - StructStructStruct&& x) noexcept -{ - m_child_struct = std::move(x.m_child_struct); - - - m_child_int64 = x.m_child_int64; - - return *this; -} - -bool StructStructStruct::operator ==( - const StructStructStruct& x) const -{ - return (m_child_struct == x.m_child_struct && - m_child_int64 == x.m_child_int64); -} - -bool StructStructStruct::operator !=( - const StructStructStruct& x) const -{ - return !(*this == x); -} - -size_t StructStructStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return StructStructStruct_max_cdr_typesize; -} - -size_t StructStructStruct::getCdrSerializedSize( - const StructStructStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += StructStruct::getCdrSerializedSize(data.child_struct(), current_alignment); - - - current_alignment += 8 + eprosima::fastcdr::Cdr::alignment(current_alignment, 8); - - - return current_alignment - initial_alignment; -} - - -void StructStructStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_child_struct; - - scdr << m_child_int64; - -} - -void StructStructStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_child_struct; - - - - dcdr >> m_child_int64; - - -} - - -bool StructStructStruct::isKeyDefined() -{ - return false; -} - -void StructStructStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member child_struct - * @param _child_struct New value to be copied in member child_struct - */ -void StructStructStruct::child_struct( - const StructStruct& _child_struct) -{ - m_child_struct = _child_struct; -} - -/*! - * @brief This function moves the value in member child_struct - * @param _child_struct New value to be moved in member child_struct - */ -void StructStructStruct::child_struct( - StructStruct&& _child_struct) -{ - m_child_struct = std::move(_child_struct); -} - -/*! - * @brief This function returns a constant reference to member child_struct - * @return Constant reference to member child_struct - */ -const StructStruct& StructStructStruct::child_struct() const -{ - return m_child_struct; -} - -/*! - * @brief This function returns a reference to member child_struct - * @return Reference to member child_struct - */ -StructStruct& StructStructStruct::child_struct() -{ - return m_child_struct; -} - - -/*! - * @brief This function sets a value in member child_int64 - * @param _child_int64 New value for member child_int64 - */ -void StructStructStruct::child_int64( - int64_t _child_int64) -{ - m_child_int64 = _child_int64; -} - -/*! - * @brief This function returns the value of member child_int64 - * @return Value of member child_int64 - */ -int64_t StructStructStruct::child_int64() const -{ - return m_child_int64; -} - -/*! - * @brief This function returns a reference to member child_int64 - * @return Reference to member child_int64 - */ -int64_t& StructStructStruct::child_int64() -{ - return m_child_int64; -} - - - - - -SimpleUnion::SimpleUnion() -{ - m__d = A; - // long m_first - m_first = 0; - // long long m_second - m_second = 0; -} - -SimpleUnion::~SimpleUnion() -{ -} - -SimpleUnion::SimpleUnion( - const SimpleUnion& x) -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } -} - -SimpleUnion::SimpleUnion( - SimpleUnion&& x) noexcept -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } -} - -SimpleUnion& SimpleUnion::operator =( - const SimpleUnion& x) -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } - - return *this; -} - -SimpleUnion& SimpleUnion::operator =( - SimpleUnion&& x) noexcept -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } - - return *this; -} - -bool SimpleUnion::operator ==( - const SimpleUnion& x) const -{ - if (m__d != x.m__d) - { - return false; - } - - switch(m__d) - { - case A: - return (m_first == x.m_first); - break; - - - case B: - return (m_second == x.m_second); - break; - - default: - break; - } - return false; -} - -bool SimpleUnion::operator !=( - const SimpleUnion& x) const -{ - return !(*this == x); -} - -void SimpleUnion::_d( - int32_t __d) -{ - bool b = false; - - switch(m__d) - { - case A: - switch(__d) - { - case A: - b = true; - break; - default: - break; - } - break; - - - case B: - switch(__d) - { - case B: - b = true; - break; - default: - break; - } - break; - - } - - if(!b) - { - throw BadParamException("Discriminator doesn't correspond with the selected union member"); - } - - m__d = __d; -} - -int32_t SimpleUnion::_d() const -{ - return m__d; -} - -int32_t& SimpleUnion::_d() -{ - return m__d; -} - -void SimpleUnion::first( - int32_t _first) -{ - m_first = _first; - m__d = A; - -} - -int32_t SimpleUnion::first() const -{ - bool b = false; - - switch(m__d) - { - case A: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first; -} - -int32_t& SimpleUnion::first() -{ - bool b = false; - - switch(m__d) - { - case A: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first; -} - - -void SimpleUnion::second( - int64_t _second) -{ - m_second = _second; - m__d = B; - -} - -int64_t SimpleUnion::second() const -{ - bool b = false; - - switch(m__d) - { - case B: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second; -} - -int64_t& SimpleUnion::second() -{ - bool b = false; - - switch(m__d) - { - case B: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second; -} - - -// TODO(Ricardo) Review -size_t SimpleUnion::getCdrSerializedSize( - const SimpleUnion& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - - switch(data.m__d) - { - case A: - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - break; - - - case B: - current_alignment += 8 + eprosima::fastcdr::Cdr::alignment(current_alignment, 8); - - break; - - default: - break; - } - - return current_alignment - initial_alignment; -} - - -void SimpleUnion::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m__d; - - switch(m__d) - { - case A: - scdr << m_first; - - break; - - - case B: - scdr << m_second; - - break; - - default: - break; - } -} - -void SimpleUnion::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m__d; - - - switch(m__d) - { - case A: - dcdr >> m_first; - - - break; - - - case B: - dcdr >> m_second; - - - break; - - default: - break; - } -} - - - - - -UnionUnion::UnionUnion() -{ - m__d = A; - // long m_first - m_first = 0; - // SimpleUnion m_second - -} - -UnionUnion::~UnionUnion() -{ -} - -UnionUnion::UnionUnion( - const UnionUnion& x) -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } -} - -UnionUnion::UnionUnion( - UnionUnion&& x) noexcept -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = std::move(x.m_second); - - break; - - default: - break; - } -} - -UnionUnion& UnionUnion::operator =( - const UnionUnion& x) -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } - - return *this; -} - -UnionUnion& UnionUnion::operator =( - UnionUnion&& x) noexcept -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = std::move(x.m_second); - - break; - - default: - break; - } - - return *this; -} - -bool UnionUnion::operator ==( - const UnionUnion& x) const -{ - if (m__d != x.m__d) - { - return false; - } - - switch(m__d) - { - case A: - return (m_first == x.m_first); - break; - - - case B: - return (m_second == x.m_second); - break; - - default: - break; - } - return false; -} - -bool UnionUnion::operator !=( - const UnionUnion& x) const -{ - return !(*this == x); -} - -void UnionUnion::_d( - int32_t __d) -{ - bool b = false; - - switch(m__d) - { - case A: - switch(__d) - { - case A: - b = true; - break; - default: - break; - } - break; - - - case B: - switch(__d) - { - case B: - b = true; - break; - default: - break; - } - break; - - } - - if(!b) - { - throw BadParamException("Discriminator doesn't correspond with the selected union member"); - } - - m__d = __d; -} - -int32_t UnionUnion::_d() const -{ - return m__d; -} - -int32_t& UnionUnion::_d() -{ - return m__d; -} - -void UnionUnion::first( - int32_t _first) -{ - m_first = _first; - m__d = A; - -} - -int32_t UnionUnion::first() const -{ - bool b = false; - - switch(m__d) - { - case A: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first; -} - -int32_t& UnionUnion::first() -{ - bool b = false; - - switch(m__d) - { - case A: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first; -} - - -void UnionUnion::second( - const SimpleUnion& _second) -{ - m_second = _second; - m__d = B; - -} - -void UnionUnion::second( - SimpleUnion&& _second) -{ - m_second = std::move(_second); - m__d = B; - -} - -const SimpleUnion& UnionUnion::second() const -{ - bool b = false; - - switch(m__d) - { - case B: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second; -} - -SimpleUnion& UnionUnion::second() -{ - bool b = false; - - switch(m__d) - { - case B: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second; -} - - -// TODO(Ricardo) Review -size_t UnionUnion::getCdrSerializedSize( - const UnionUnion& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - - switch(data.m__d) - { - case A: - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - break; - - - case B: - current_alignment += SimpleUnion::getCdrSerializedSize(data.second(), current_alignment); - - break; - - default: - break; - } - - return current_alignment - initial_alignment; -} - - -void UnionUnion::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m__d; - - switch(m__d) - { - case A: - scdr << m_first; - - break; - - - case B: - scdr << m_second; - - break; - - default: - break; - } -} - -void UnionUnion::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m__d; - - - switch(m__d) - { - case A: - dcdr >> m_first; - - - break; - - - case B: - dcdr >> m_second; - - - break; - - default: - break; - } -} - - - - - -WCharUnion::WCharUnion() -{ - m__d = A; - // long m_first - m_first = 0; - // long long m_second - m_second = 0; -} - -WCharUnion::~WCharUnion() -{ -} - -WCharUnion::WCharUnion( - const WCharUnion& x) -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } -} - -WCharUnion::WCharUnion( - WCharUnion&& x) noexcept -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } -} - -WCharUnion& WCharUnion::operator =( - const WCharUnion& x) -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } - - return *this; -} - -WCharUnion& WCharUnion::operator =( - WCharUnion&& x) noexcept -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } - - return *this; -} - -bool WCharUnion::operator ==( - const WCharUnion& x) const -{ - if (m__d != x.m__d) - { - return false; - } - - switch(m__d) - { - case A: - return (m_first == x.m_first); - break; - - - case B: - return (m_second == x.m_second); - break; - - default: - break; - } - return false; -} - -bool WCharUnion::operator !=( - const WCharUnion& x) const -{ - return !(*this == x); -} - -void WCharUnion::_d( - wchar_t __d) -{ - bool b = false; - - switch(m__d) - { - case A: - switch(__d) - { - case A: - b = true; - break; - default: - break; - } - break; - - - case B: - switch(__d) - { - case B: - b = true; - break; - default: - break; - } - break; - - } - - if(!b) - { - throw BadParamException("Discriminator doesn't correspond with the selected union member"); - } - - m__d = __d; -} - -wchar_t WCharUnion::_d() const -{ - return m__d; -} - -wchar_t& WCharUnion::_d() -{ - return m__d; -} - -void WCharUnion::first( - int32_t _first) -{ - m_first = _first; - m__d = A; - -} - -int32_t WCharUnion::first() const -{ - bool b = false; - - switch(m__d) - { - case A: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first; -} - -int32_t& WCharUnion::first() -{ - bool b = false; - - switch(m__d) - { - case A: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first; -} - - -void WCharUnion::second( - int64_t _second) -{ - m_second = _second; - m__d = B; - -} - -int64_t WCharUnion::second() const -{ - bool b = false; - - switch(m__d) - { - case B: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second; -} - -int64_t& WCharUnion::second() -{ - bool b = false; - - switch(m__d) - { - case B: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second; -} - - -// TODO(Ricardo) Review -size_t WCharUnion::getCdrSerializedSize( - const WCharUnion& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - - switch(data.m__d) - { - case A: - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - break; - - - case B: - current_alignment += 8 + eprosima::fastcdr::Cdr::alignment(current_alignment, 8); - - break; - - default: - break; - } - - return current_alignment - initial_alignment; -} - - -void WCharUnion::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m__d; - - switch(m__d) - { - case A: - scdr << m_first; - - break; - - - case B: - scdr << m_second; - - break; - - default: - break; - } -} - -void WCharUnion::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m__d; - - - switch(m__d) - { - case A: - dcdr >> m_first; - - - break; - - - case B: - dcdr >> m_second; - - - break; - - default: - break; - } -} - - - - - -SimpleUnionStruct::SimpleUnionStruct() -{ - // SimpleUnion m_my_union - - - // Just to register all known types - registerBasicTypes(); -} - -SimpleUnionStruct::~SimpleUnionStruct() -{ -} - -SimpleUnionStruct::SimpleUnionStruct( - const SimpleUnionStruct& x) -{ - m_my_union = x.m_my_union; - -} - -SimpleUnionStruct::SimpleUnionStruct( - SimpleUnionStruct&& x) noexcept -{ - m_my_union = std::move(x.m_my_union); - -} - -SimpleUnionStruct& SimpleUnionStruct::operator =( - const SimpleUnionStruct& x) -{ - m_my_union = x.m_my_union; - - return *this; -} - -SimpleUnionStruct& SimpleUnionStruct::operator =( - SimpleUnionStruct&& x) noexcept -{ - m_my_union = std::move(x.m_my_union); - - return *this; -} - -bool SimpleUnionStruct::operator ==( - const SimpleUnionStruct& x) const -{ - return (m_my_union == x.m_my_union); -} - -bool SimpleUnionStruct::operator !=( - const SimpleUnionStruct& x) const -{ - return !(*this == x); -} - -size_t SimpleUnionStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return SimpleUnionStruct_max_cdr_typesize; -} - -size_t SimpleUnionStruct::getCdrSerializedSize( - const SimpleUnionStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += SimpleUnion::getCdrSerializedSize(data.my_union(), current_alignment); - - - return current_alignment - initial_alignment; -} - - -void SimpleUnionStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_union; - -} - -void SimpleUnionStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_union; - - -} - - -bool SimpleUnionStruct::isKeyDefined() -{ - return false; -} - -void SimpleUnionStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ -void SimpleUnionStruct::my_union( - const SimpleUnion& _my_union) -{ - m_my_union = _my_union; -} - -/*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ -void SimpleUnionStruct::my_union( - SimpleUnion&& _my_union) -{ - m_my_union = std::move(_my_union); -} - -/*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ -const SimpleUnion& SimpleUnionStruct::my_union() const -{ - return m_my_union; -} - -/*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ -SimpleUnion& SimpleUnionStruct::my_union() -{ - return m_my_union; -} - - - - - -UnionUnionUnionStruct::UnionUnionUnionStruct() -{ - // UnionUnion m_my_union - - - // Just to register all known types - registerBasicTypes(); -} - -UnionUnionUnionStruct::~UnionUnionUnionStruct() -{ -} - -UnionUnionUnionStruct::UnionUnionUnionStruct( - const UnionUnionUnionStruct& x) -{ - m_my_union = x.m_my_union; - -} - -UnionUnionUnionStruct::UnionUnionUnionStruct( - UnionUnionUnionStruct&& x) noexcept -{ - m_my_union = std::move(x.m_my_union); - -} - -UnionUnionUnionStruct& UnionUnionUnionStruct::operator =( - const UnionUnionUnionStruct& x) -{ - m_my_union = x.m_my_union; - - return *this; -} - -UnionUnionUnionStruct& UnionUnionUnionStruct::operator =( - UnionUnionUnionStruct&& x) noexcept -{ - m_my_union = std::move(x.m_my_union); - - return *this; -} - -bool UnionUnionUnionStruct::operator ==( - const UnionUnionUnionStruct& x) const -{ - return (m_my_union == x.m_my_union); -} - -bool UnionUnionUnionStruct::operator !=( - const UnionUnionUnionStruct& x) const -{ - return !(*this == x); -} - -size_t UnionUnionUnionStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return UnionUnionUnionStruct_max_cdr_typesize; -} - -size_t UnionUnionUnionStruct::getCdrSerializedSize( - const UnionUnionUnionStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += UnionUnion::getCdrSerializedSize(data.my_union(), current_alignment); - - - return current_alignment - initial_alignment; -} - - -void UnionUnionUnionStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_union; - -} - -void UnionUnionUnionStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_union; - - -} - - -bool UnionUnionUnionStruct::isKeyDefined() -{ - return false; -} - -void UnionUnionUnionStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ -void UnionUnionUnionStruct::my_union( - const UnionUnion& _my_union) -{ - m_my_union = _my_union; -} - -/*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ -void UnionUnionUnionStruct::my_union( - UnionUnion&& _my_union) -{ - m_my_union = std::move(_my_union); -} - -/*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ -const UnionUnion& UnionUnionUnionStruct::my_union() const -{ - return m_my_union; -} - -/*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ -UnionUnion& UnionUnionUnionStruct::my_union() -{ - return m_my_union; -} - - - - - -WCharUnionStruct::WCharUnionStruct() -{ - // WCharUnion m_my_union - - - // Just to register all known types - registerBasicTypes(); -} - -WCharUnionStruct::~WCharUnionStruct() -{ -} - -WCharUnionStruct::WCharUnionStruct( - const WCharUnionStruct& x) -{ - m_my_union = x.m_my_union; - -} - -WCharUnionStruct::WCharUnionStruct( - WCharUnionStruct&& x) noexcept -{ - m_my_union = std::move(x.m_my_union); - -} - -WCharUnionStruct& WCharUnionStruct::operator =( - const WCharUnionStruct& x) -{ - m_my_union = x.m_my_union; - - return *this; -} - -WCharUnionStruct& WCharUnionStruct::operator =( - WCharUnionStruct&& x) noexcept -{ - m_my_union = std::move(x.m_my_union); - - return *this; -} - -bool WCharUnionStruct::operator ==( - const WCharUnionStruct& x) const -{ - return (m_my_union == x.m_my_union); -} - -bool WCharUnionStruct::operator !=( - const WCharUnionStruct& x) const -{ - return !(*this == x); -} - -size_t WCharUnionStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return WCharUnionStruct_max_cdr_typesize; -} - -size_t WCharUnionStruct::getCdrSerializedSize( - const WCharUnionStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += WCharUnion::getCdrSerializedSize(data.my_union(), current_alignment); - - - return current_alignment - initial_alignment; -} - - -void WCharUnionStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_union; - -} - -void WCharUnionStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_union; - - -} - - -bool WCharUnionStruct::isKeyDefined() -{ - return false; -} - -void WCharUnionStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ -void WCharUnionStruct::my_union( - const WCharUnion& _my_union) -{ - m_my_union = _my_union; -} - -/*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ -void WCharUnionStruct::my_union( - WCharUnion&& _my_union) -{ - m_my_union = std::move(_my_union); -} - -/*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ -const WCharUnion& WCharUnionStruct::my_union() const -{ - return m_my_union; -} - -/*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ -WCharUnion& WCharUnionStruct::my_union() -{ - return m_my_union; -} - - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/test/unittest/dynamic_types/idl/Basicv1.h b/test/unittest/dynamic_types/idl/Basicv1.h deleted file mode 100644 index 1a8ac2db83d..00000000000 --- a/test/unittest/dynamic_types/idl/Basicv1.h +++ /dev/null @@ -1,5327 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file Basic.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#include - -#if FASTCDR_VERSION_MAJOR == 1 - -#ifndef _FAST_DDS_GENERATED_BASIC_H_ -#define _FAST_DDS_GENERATED_BASIC_H_ - - -#include - -#include -#include -#include -#include -#include -#include -#include - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define eProsima_user_DllExport -#endif // _WIN32 - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(BASIC_SOURCE) -#define BASIC_DllAPI __declspec( dllexport ) -#else -#define BASIC_DllAPI __declspec( dllimport ) -#endif // BASIC_SOURCE -#else -#define BASIC_DllAPI -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define BASIC_DllAPI -#endif // _WIN32 - -namespace eprosima { -namespace fastcdr { -class Cdr; -} // namespace fastcdr -} // namespace eprosima - - - -/*! - * @brief This class represents the enumeration MyEnum defined by the user in the IDL file. - * @ingroup Basic - */ -enum MyEnum : uint32_t -{ - A, - B, - C -}; -typedef MyEnum MyAliasEnum; - -typedef MyAliasEnum MyAliasAliasEnum; - - - -/*! - * @brief This class represents the structure EnumStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class EnumStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport EnumStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~EnumStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object EnumStruct that will be copied. - */ - eProsima_user_DllExport EnumStruct( - const EnumStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object EnumStruct that will be copied. - */ - eProsima_user_DllExport EnumStruct( - EnumStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object EnumStruct that will be copied. - */ - eProsima_user_DllExport EnumStruct& operator =( - const EnumStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object EnumStruct that will be copied. - */ - eProsima_user_DllExport EnumStruct& operator =( - EnumStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x EnumStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const EnumStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x EnumStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const EnumStruct& x) const; - - /*! - * @brief This function sets a value in member my_enum - * @param _my_enum New value for member my_enum - */ - eProsima_user_DllExport void my_enum( - MyEnum _my_enum); - - /*! - * @brief This function returns the value of member my_enum - * @return Value of member my_enum - */ - eProsima_user_DllExport MyEnum my_enum() const; - - /*! - * @brief This function returns a reference to member my_enum - * @return Reference to member my_enum - */ - eProsima_user_DllExport MyEnum& my_enum(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const EnumStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - MyEnum m_my_enum; - -}; - - - -/*! - * @brief This class represents the structure AliasStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class AliasStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport AliasStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~AliasStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object AliasStruct that will be copied. - */ - eProsima_user_DllExport AliasStruct( - const AliasStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object AliasStruct that will be copied. - */ - eProsima_user_DllExport AliasStruct( - AliasStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object AliasStruct that will be copied. - */ - eProsima_user_DllExport AliasStruct& operator =( - const AliasStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object AliasStruct that will be copied. - */ - eProsima_user_DllExport AliasStruct& operator =( - AliasStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x AliasStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const AliasStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x AliasStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const AliasStruct& x) const; - - /*! - * @brief This function sets a value in member my_alias - * @param _my_alias New value for member my_alias - */ - eProsima_user_DllExport void my_alias( - MyAliasEnum _my_alias); - - /*! - * @brief This function returns the value of member my_alias - * @return Value of member my_alias - */ - eProsima_user_DllExport MyAliasEnum my_alias() const; - - /*! - * @brief This function returns a reference to member my_alias - * @return Reference to member my_alias - */ - eProsima_user_DllExport MyAliasEnum& my_alias(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const AliasStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - MyAliasEnum m_my_alias; - -}; - - - -/*! - * @brief This class represents the structure AliasAliasStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class AliasAliasStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport AliasAliasStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~AliasAliasStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object AliasAliasStruct that will be copied. - */ - eProsima_user_DllExport AliasAliasStruct( - const AliasAliasStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object AliasAliasStruct that will be copied. - */ - eProsima_user_DllExport AliasAliasStruct( - AliasAliasStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object AliasAliasStruct that will be copied. - */ - eProsima_user_DllExport AliasAliasStruct& operator =( - const AliasAliasStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object AliasAliasStruct that will be copied. - */ - eProsima_user_DllExport AliasAliasStruct& operator =( - AliasAliasStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x AliasAliasStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const AliasAliasStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x AliasAliasStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const AliasAliasStruct& x) const; - - /*! - * @brief This function sets a value in member my_alias_alias - * @param _my_alias_alias New value for member my_alias_alias - */ - eProsima_user_DllExport void my_alias_alias( - MyAliasAliasEnum _my_alias_alias); - - /*! - * @brief This function returns the value of member my_alias_alias - * @return Value of member my_alias_alias - */ - eProsima_user_DllExport MyAliasAliasEnum my_alias_alias() const; - - /*! - * @brief This function returns a reference to member my_alias_alias - * @return Reference to member my_alias_alias - */ - eProsima_user_DllExport MyAliasAliasEnum& my_alias_alias(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const AliasAliasStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - MyAliasAliasEnum m_my_alias_alias; - -}; - - - -/*! - * @brief This class represents the structure BoolStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class BoolStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport BoolStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~BoolStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object BoolStruct that will be copied. - */ - eProsima_user_DllExport BoolStruct( - const BoolStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object BoolStruct that will be copied. - */ - eProsima_user_DllExport BoolStruct( - BoolStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object BoolStruct that will be copied. - */ - eProsima_user_DllExport BoolStruct& operator =( - const BoolStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object BoolStruct that will be copied. - */ - eProsima_user_DllExport BoolStruct& operator =( - BoolStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x BoolStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const BoolStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x BoolStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const BoolStruct& x) const; - - /*! - * @brief This function sets a value in member my_bool - * @param _my_bool New value for member my_bool - */ - eProsima_user_DllExport void my_bool( - bool _my_bool); - - /*! - * @brief This function returns the value of member my_bool - * @return Value of member my_bool - */ - eProsima_user_DllExport bool my_bool() const; - - /*! - * @brief This function returns a reference to member my_bool - * @return Reference to member my_bool - */ - eProsima_user_DllExport bool& my_bool(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const BoolStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - bool m_my_bool; - -}; - - - -/*! - * @brief This class represents the structure OctetStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class OctetStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport OctetStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~OctetStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object OctetStruct that will be copied. - */ - eProsima_user_DllExport OctetStruct( - const OctetStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object OctetStruct that will be copied. - */ - eProsima_user_DllExport OctetStruct( - OctetStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object OctetStruct that will be copied. - */ - eProsima_user_DllExport OctetStruct& operator =( - const OctetStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object OctetStruct that will be copied. - */ - eProsima_user_DllExport OctetStruct& operator =( - OctetStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x OctetStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const OctetStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x OctetStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const OctetStruct& x) const; - - /*! - * @brief This function sets a value in member my_octet - * @param _my_octet New value for member my_octet - */ - eProsima_user_DllExport void my_octet( - uint8_t _my_octet); - - /*! - * @brief This function returns the value of member my_octet - * @return Value of member my_octet - */ - eProsima_user_DllExport uint8_t my_octet() const; - - /*! - * @brief This function returns a reference to member my_octet - * @return Reference to member my_octet - */ - eProsima_user_DllExport uint8_t& my_octet(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const OctetStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - uint8_t m_my_octet; - -}; - - - -/*! - * @brief This class represents the structure ShortStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class ShortStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport ShortStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~ShortStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object ShortStruct that will be copied. - */ - eProsima_user_DllExport ShortStruct( - const ShortStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object ShortStruct that will be copied. - */ - eProsima_user_DllExport ShortStruct( - ShortStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object ShortStruct that will be copied. - */ - eProsima_user_DllExport ShortStruct& operator =( - const ShortStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object ShortStruct that will be copied. - */ - eProsima_user_DllExport ShortStruct& operator =( - ShortStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x ShortStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const ShortStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x ShortStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const ShortStruct& x) const; - - /*! - * @brief This function sets a value in member my_int16 - * @param _my_int16 New value for member my_int16 - */ - eProsima_user_DllExport void my_int16( - int16_t _my_int16); - - /*! - * @brief This function returns the value of member my_int16 - * @return Value of member my_int16 - */ - eProsima_user_DllExport int16_t my_int16() const; - - /*! - * @brief This function returns a reference to member my_int16 - * @return Reference to member my_int16 - */ - eProsima_user_DllExport int16_t& my_int16(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const ShortStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - int16_t m_my_int16; - -}; - - - -/*! - * @brief This class represents the structure LongStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class LongStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport LongStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~LongStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object LongStruct that will be copied. - */ - eProsima_user_DllExport LongStruct( - const LongStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object LongStruct that will be copied. - */ - eProsima_user_DllExport LongStruct( - LongStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object LongStruct that will be copied. - */ - eProsima_user_DllExport LongStruct& operator =( - const LongStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object LongStruct that will be copied. - */ - eProsima_user_DllExport LongStruct& operator =( - LongStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x LongStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const LongStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x LongStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const LongStruct& x) const; - - /*! - * @brief This function sets a value in member my_int32 - * @param _my_int32 New value for member my_int32 - */ - eProsima_user_DllExport void my_int32( - int32_t _my_int32); - - /*! - * @brief This function returns the value of member my_int32 - * @return Value of member my_int32 - */ - eProsima_user_DllExport int32_t my_int32() const; - - /*! - * @brief This function returns a reference to member my_int32 - * @return Reference to member my_int32 - */ - eProsima_user_DllExport int32_t& my_int32(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const LongStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - int32_t m_my_int32; - -}; - - - -/*! - * @brief This class represents the structure LongLongStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class LongLongStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport LongLongStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~LongLongStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object LongLongStruct that will be copied. - */ - eProsima_user_DllExport LongLongStruct( - const LongLongStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object LongLongStruct that will be copied. - */ - eProsima_user_DllExport LongLongStruct( - LongLongStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object LongLongStruct that will be copied. - */ - eProsima_user_DllExport LongLongStruct& operator =( - const LongLongStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object LongLongStruct that will be copied. - */ - eProsima_user_DllExport LongLongStruct& operator =( - LongLongStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x LongLongStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const LongLongStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x LongLongStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const LongLongStruct& x) const; - - /*! - * @brief This function sets a value in member my_int64 - * @param _my_int64 New value for member my_int64 - */ - eProsima_user_DllExport void my_int64( - int64_t _my_int64); - - /*! - * @brief This function returns the value of member my_int64 - * @return Value of member my_int64 - */ - eProsima_user_DllExport int64_t my_int64() const; - - /*! - * @brief This function returns a reference to member my_int64 - * @return Reference to member my_int64 - */ - eProsima_user_DllExport int64_t& my_int64(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const LongLongStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - int64_t m_my_int64; - -}; - - - -/*! - * @brief This class represents the structure UShortStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class UShortStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport UShortStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~UShortStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object UShortStruct that will be copied. - */ - eProsima_user_DllExport UShortStruct( - const UShortStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object UShortStruct that will be copied. - */ - eProsima_user_DllExport UShortStruct( - UShortStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object UShortStruct that will be copied. - */ - eProsima_user_DllExport UShortStruct& operator =( - const UShortStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object UShortStruct that will be copied. - */ - eProsima_user_DllExport UShortStruct& operator =( - UShortStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x UShortStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const UShortStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x UShortStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const UShortStruct& x) const; - - /*! - * @brief This function sets a value in member my_uint16 - * @param _my_uint16 New value for member my_uint16 - */ - eProsima_user_DllExport void my_uint16( - uint16_t _my_uint16); - - /*! - * @brief This function returns the value of member my_uint16 - * @return Value of member my_uint16 - */ - eProsima_user_DllExport uint16_t my_uint16() const; - - /*! - * @brief This function returns a reference to member my_uint16 - * @return Reference to member my_uint16 - */ - eProsima_user_DllExport uint16_t& my_uint16(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const UShortStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - uint16_t m_my_uint16; - -}; - - - -/*! - * @brief This class represents the structure ULongStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class ULongStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport ULongStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~ULongStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object ULongStruct that will be copied. - */ - eProsima_user_DllExport ULongStruct( - const ULongStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object ULongStruct that will be copied. - */ - eProsima_user_DllExport ULongStruct( - ULongStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object ULongStruct that will be copied. - */ - eProsima_user_DllExport ULongStruct& operator =( - const ULongStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object ULongStruct that will be copied. - */ - eProsima_user_DllExport ULongStruct& operator =( - ULongStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x ULongStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const ULongStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x ULongStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const ULongStruct& x) const; - - /*! - * @brief This function sets a value in member my_uint32 - * @param _my_uint32 New value for member my_uint32 - */ - eProsima_user_DllExport void my_uint32( - uint32_t _my_uint32); - - /*! - * @brief This function returns the value of member my_uint32 - * @return Value of member my_uint32 - */ - eProsima_user_DllExport uint32_t my_uint32() const; - - /*! - * @brief This function returns a reference to member my_uint32 - * @return Reference to member my_uint32 - */ - eProsima_user_DllExport uint32_t& my_uint32(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const ULongStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - uint32_t m_my_uint32; - -}; - - - -/*! - * @brief This class represents the structure ULongLongStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class ULongLongStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport ULongLongStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~ULongLongStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object ULongLongStruct that will be copied. - */ - eProsima_user_DllExport ULongLongStruct( - const ULongLongStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object ULongLongStruct that will be copied. - */ - eProsima_user_DllExport ULongLongStruct( - ULongLongStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object ULongLongStruct that will be copied. - */ - eProsima_user_DllExport ULongLongStruct& operator =( - const ULongLongStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object ULongLongStruct that will be copied. - */ - eProsima_user_DllExport ULongLongStruct& operator =( - ULongLongStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x ULongLongStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const ULongLongStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x ULongLongStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const ULongLongStruct& x) const; - - /*! - * @brief This function sets a value in member my_uint64 - * @param _my_uint64 New value for member my_uint64 - */ - eProsima_user_DllExport void my_uint64( - uint64_t _my_uint64); - - /*! - * @brief This function returns the value of member my_uint64 - * @return Value of member my_uint64 - */ - eProsima_user_DllExport uint64_t my_uint64() const; - - /*! - * @brief This function returns a reference to member my_uint64 - * @return Reference to member my_uint64 - */ - eProsima_user_DllExport uint64_t& my_uint64(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const ULongLongStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - uint64_t m_my_uint64; - -}; - - - -/*! - * @brief This class represents the structure FloatStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class FloatStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport FloatStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~FloatStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object FloatStruct that will be copied. - */ - eProsima_user_DllExport FloatStruct( - const FloatStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object FloatStruct that will be copied. - */ - eProsima_user_DllExport FloatStruct( - FloatStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object FloatStruct that will be copied. - */ - eProsima_user_DllExport FloatStruct& operator =( - const FloatStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object FloatStruct that will be copied. - */ - eProsima_user_DllExport FloatStruct& operator =( - FloatStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x FloatStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const FloatStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x FloatStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const FloatStruct& x) const; - - /*! - * @brief This function sets a value in member my_float32 - * @param _my_float32 New value for member my_float32 - */ - eProsima_user_DllExport void my_float32( - float _my_float32); - - /*! - * @brief This function returns the value of member my_float32 - * @return Value of member my_float32 - */ - eProsima_user_DllExport float my_float32() const; - - /*! - * @brief This function returns a reference to member my_float32 - * @return Reference to member my_float32 - */ - eProsima_user_DllExport float& my_float32(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const FloatStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - float m_my_float32; - -}; - - - -/*! - * @brief This class represents the structure DoubleStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class DoubleStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport DoubleStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~DoubleStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object DoubleStruct that will be copied. - */ - eProsima_user_DllExport DoubleStruct( - const DoubleStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object DoubleStruct that will be copied. - */ - eProsima_user_DllExport DoubleStruct( - DoubleStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object DoubleStruct that will be copied. - */ - eProsima_user_DllExport DoubleStruct& operator =( - const DoubleStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object DoubleStruct that will be copied. - */ - eProsima_user_DllExport DoubleStruct& operator =( - DoubleStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x DoubleStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const DoubleStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x DoubleStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const DoubleStruct& x) const; - - /*! - * @brief This function sets a value in member my_float64 - * @param _my_float64 New value for member my_float64 - */ - eProsima_user_DllExport void my_float64( - double _my_float64); - - /*! - * @brief This function returns the value of member my_float64 - * @return Value of member my_float64 - */ - eProsima_user_DllExport double my_float64() const; - - /*! - * @brief This function returns a reference to member my_float64 - * @return Reference to member my_float64 - */ - eProsima_user_DllExport double& my_float64(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const DoubleStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - double m_my_float64; - -}; - - - -/*! - * @brief This class represents the structure LongDoubleStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class LongDoubleStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport LongDoubleStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~LongDoubleStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object LongDoubleStruct that will be copied. - */ - eProsima_user_DllExport LongDoubleStruct( - const LongDoubleStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object LongDoubleStruct that will be copied. - */ - eProsima_user_DllExport LongDoubleStruct( - LongDoubleStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object LongDoubleStruct that will be copied. - */ - eProsima_user_DllExport LongDoubleStruct& operator =( - const LongDoubleStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object LongDoubleStruct that will be copied. - */ - eProsima_user_DllExport LongDoubleStruct& operator =( - LongDoubleStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x LongDoubleStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const LongDoubleStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x LongDoubleStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const LongDoubleStruct& x) const; - - /*! - * @brief This function sets a value in member my_float128 - * @param _my_float128 New value for member my_float128 - */ - eProsima_user_DllExport void my_float128( - long double _my_float128); - - /*! - * @brief This function returns the value of member my_float128 - * @return Value of member my_float128 - */ - eProsima_user_DllExport long double my_float128() const; - - /*! - * @brief This function returns a reference to member my_float128 - * @return Reference to member my_float128 - */ - eProsima_user_DllExport long double& my_float128(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const LongDoubleStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - long double m_my_float128; - -}; - - - -/*! - * @brief This class represents the structure CharStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class CharStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport CharStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~CharStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object CharStruct that will be copied. - */ - eProsima_user_DllExport CharStruct( - const CharStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object CharStruct that will be copied. - */ - eProsima_user_DllExport CharStruct( - CharStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object CharStruct that will be copied. - */ - eProsima_user_DllExport CharStruct& operator =( - const CharStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object CharStruct that will be copied. - */ - eProsima_user_DllExport CharStruct& operator =( - CharStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x CharStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const CharStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x CharStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const CharStruct& x) const; - - /*! - * @brief This function sets a value in member my_char - * @param _my_char New value for member my_char - */ - eProsima_user_DllExport void my_char( - char _my_char); - - /*! - * @brief This function returns the value of member my_char - * @return Value of member my_char - */ - eProsima_user_DllExport char my_char() const; - - /*! - * @brief This function returns a reference to member my_char - * @return Reference to member my_char - */ - eProsima_user_DllExport char& my_char(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const CharStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - char m_my_char; - -}; - - - -/*! - * @brief This class represents the structure WCharStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class WCharStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport WCharStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~WCharStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object WCharStruct that will be copied. - */ - eProsima_user_DllExport WCharStruct( - const WCharStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object WCharStruct that will be copied. - */ - eProsima_user_DllExport WCharStruct( - WCharStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object WCharStruct that will be copied. - */ - eProsima_user_DllExport WCharStruct& operator =( - const WCharStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object WCharStruct that will be copied. - */ - eProsima_user_DllExport WCharStruct& operator =( - WCharStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x WCharStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const WCharStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x WCharStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const WCharStruct& x) const; - - /*! - * @brief This function sets a value in member my_wchar - * @param _my_wchar New value for member my_wchar - */ - eProsima_user_DllExport void my_wchar( - wchar_t _my_wchar); - - /*! - * @brief This function returns the value of member my_wchar - * @return Value of member my_wchar - */ - eProsima_user_DllExport wchar_t my_wchar() const; - - /*! - * @brief This function returns a reference to member my_wchar - * @return Reference to member my_wchar - */ - eProsima_user_DllExport wchar_t& my_wchar(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const WCharStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - wchar_t m_my_wchar; - -}; - - - -/*! - * @brief This class represents the structure StringStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class StringStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport StringStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~StringStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object StringStruct that will be copied. - */ - eProsima_user_DllExport StringStruct( - const StringStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object StringStruct that will be copied. - */ - eProsima_user_DllExport StringStruct( - StringStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object StringStruct that will be copied. - */ - eProsima_user_DllExport StringStruct& operator =( - const StringStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object StringStruct that will be copied. - */ - eProsima_user_DllExport StringStruct& operator =( - StringStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x StringStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const StringStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x StringStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const StringStruct& x) const; - - /*! - * @brief This function copies the value in member my_string - * @param _my_string New value to be copied in member my_string - */ - eProsima_user_DllExport void my_string( - const std::string& _my_string); - - /*! - * @brief This function moves the value in member my_string - * @param _my_string New value to be moved in member my_string - */ - eProsima_user_DllExport void my_string( - std::string&& _my_string); - - /*! - * @brief This function returns a constant reference to member my_string - * @return Constant reference to member my_string - */ - eProsima_user_DllExport const std::string& my_string() const; - - /*! - * @brief This function returns a reference to member my_string - * @return Reference to member my_string - */ - eProsima_user_DllExport std::string& my_string(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const StringStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::string m_my_string; - -}; - - - -/*! - * @brief This class represents the structure WStringStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class WStringStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport WStringStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~WStringStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object WStringStruct that will be copied. - */ - eProsima_user_DllExport WStringStruct( - const WStringStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object WStringStruct that will be copied. - */ - eProsima_user_DllExport WStringStruct( - WStringStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object WStringStruct that will be copied. - */ - eProsima_user_DllExport WStringStruct& operator =( - const WStringStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object WStringStruct that will be copied. - */ - eProsima_user_DllExport WStringStruct& operator =( - WStringStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x WStringStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const WStringStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x WStringStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const WStringStruct& x) const; - - /*! - * @brief This function copies the value in member my_wstring - * @param _my_wstring New value to be copied in member my_wstring - */ - eProsima_user_DllExport void my_wstring( - const std::wstring& _my_wstring); - - /*! - * @brief This function moves the value in member my_wstring - * @param _my_wstring New value to be moved in member my_wstring - */ - eProsima_user_DllExport void my_wstring( - std::wstring&& _my_wstring); - - /*! - * @brief This function returns a constant reference to member my_wstring - * @return Constant reference to member my_wstring - */ - eProsima_user_DllExport const std::wstring& my_wstring() const; - - /*! - * @brief This function returns a reference to member my_wstring - * @return Reference to member my_wstring - */ - eProsima_user_DllExport std::wstring& my_wstring(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const WStringStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::wstring m_my_wstring; - -}; - - - -/*! - * @brief This class represents the structure LargeStringStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class LargeStringStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport LargeStringStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~LargeStringStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object LargeStringStruct that will be copied. - */ - eProsima_user_DllExport LargeStringStruct( - const LargeStringStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object LargeStringStruct that will be copied. - */ - eProsima_user_DllExport LargeStringStruct( - LargeStringStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object LargeStringStruct that will be copied. - */ - eProsima_user_DllExport LargeStringStruct& operator =( - const LargeStringStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object LargeStringStruct that will be copied. - */ - eProsima_user_DllExport LargeStringStruct& operator =( - LargeStringStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x LargeStringStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const LargeStringStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x LargeStringStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const LargeStringStruct& x) const; - - /*! - * @brief This function copies the value in member my_large_string - * @param _my_large_string New value to be copied in member my_large_string - */ - eProsima_user_DllExport void my_large_string( - const eprosima::fastrtps::fixed_string<41925>& _my_large_string); - - /*! - * @brief This function moves the value in member my_large_string - * @param _my_large_string New value to be moved in member my_large_string - */ - eProsima_user_DllExport void my_large_string( - eprosima::fastrtps::fixed_string<41925>&& _my_large_string); - - /*! - * @brief This function returns a constant reference to member my_large_string - * @return Constant reference to member my_large_string - */ - eProsima_user_DllExport const eprosima::fastrtps::fixed_string<41925>& my_large_string() const; - - /*! - * @brief This function returns a reference to member my_large_string - * @return Reference to member my_large_string - */ - eProsima_user_DllExport eprosima::fastrtps::fixed_string<41925>& my_large_string(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const LargeStringStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - eprosima::fastrtps::fixed_string<41925> m_my_large_string; - -}; - - - -/*! - * @brief This class represents the structure LargeWStringStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class LargeWStringStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport LargeWStringStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~LargeWStringStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object LargeWStringStruct that will be copied. - */ - eProsima_user_DllExport LargeWStringStruct( - const LargeWStringStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object LargeWStringStruct that will be copied. - */ - eProsima_user_DllExport LargeWStringStruct( - LargeWStringStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object LargeWStringStruct that will be copied. - */ - eProsima_user_DllExport LargeWStringStruct& operator =( - const LargeWStringStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object LargeWStringStruct that will be copied. - */ - eProsima_user_DllExport LargeWStringStruct& operator =( - LargeWStringStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x LargeWStringStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const LargeWStringStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x LargeWStringStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const LargeWStringStruct& x) const; - - /*! - * @brief This function copies the value in member my_large_wstring - * @param _my_large_wstring New value to be copied in member my_large_wstring - */ - eProsima_user_DllExport void my_large_wstring( - const std::wstring& _my_large_wstring); - - /*! - * @brief This function moves the value in member my_large_wstring - * @param _my_large_wstring New value to be moved in member my_large_wstring - */ - eProsima_user_DllExport void my_large_wstring( - std::wstring&& _my_large_wstring); - - /*! - * @brief This function returns a constant reference to member my_large_wstring - * @return Constant reference to member my_large_wstring - */ - eProsima_user_DllExport const std::wstring& my_large_wstring() const; - - /*! - * @brief This function returns a reference to member my_large_wstring - * @return Reference to member my_large_wstring - */ - eProsima_user_DllExport std::wstring& my_large_wstring(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const LargeWStringStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::wstring m_my_large_wstring; - -}; - - - -/*! - * @brief This class represents the structure ArraytStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class ArraytStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport ArraytStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~ArraytStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object ArraytStruct that will be copied. - */ - eProsima_user_DllExport ArraytStruct( - const ArraytStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object ArraytStruct that will be copied. - */ - eProsima_user_DllExport ArraytStruct( - ArraytStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object ArraytStruct that will be copied. - */ - eProsima_user_DllExport ArraytStruct& operator =( - const ArraytStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object ArraytStruct that will be copied. - */ - eProsima_user_DllExport ArraytStruct& operator =( - ArraytStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x ArraytStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const ArraytStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x ArraytStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const ArraytStruct& x) const; - - /*! - * @brief This function copies the value in member my_array - * @param _my_array New value to be copied in member my_array - */ - eProsima_user_DllExport void my_array( - const std::array, 2>, 2>& _my_array); - - /*! - * @brief This function moves the value in member my_array - * @param _my_array New value to be moved in member my_array - */ - eProsima_user_DllExport void my_array( - std::array, 2>, 2>&& _my_array); - - /*! - * @brief This function returns a constant reference to member my_array - * @return Constant reference to member my_array - */ - eProsima_user_DllExport const std::array, 2>, 2>& my_array() const; - - /*! - * @brief This function returns a reference to member my_array - * @return Reference to member my_array - */ - eProsima_user_DllExport std::array, 2>, 2>& my_array(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const ArraytStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::array, 2>, 2> m_my_array; - -}; - -typedef std::array, 2> MyArray; - - - -/*! - * @brief This class represents the structure ArrayArrayStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class ArrayArrayStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport ArrayArrayStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~ArrayArrayStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object ArrayArrayStruct that will be copied. - */ - eProsima_user_DllExport ArrayArrayStruct( - const ArrayArrayStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object ArrayArrayStruct that will be copied. - */ - eProsima_user_DllExport ArrayArrayStruct( - ArrayArrayStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object ArrayArrayStruct that will be copied. - */ - eProsima_user_DllExport ArrayArrayStruct& operator =( - const ArrayArrayStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object ArrayArrayStruct that will be copied. - */ - eProsima_user_DllExport ArrayArrayStruct& operator =( - ArrayArrayStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x ArrayArrayStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const ArrayArrayStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x ArrayArrayStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const ArrayArrayStruct& x) const; - - /*! - * @brief This function copies the value in member my_array_array - * @param _my_array_array New value to be copied in member my_array_array - */ - eProsima_user_DllExport void my_array_array( - const std::array, 2>& _my_array_array); - - /*! - * @brief This function moves the value in member my_array_array - * @param _my_array_array New value to be moved in member my_array_array - */ - eProsima_user_DllExport void my_array_array( - std::array, 2>&& _my_array_array); - - /*! - * @brief This function returns a constant reference to member my_array_array - * @return Constant reference to member my_array_array - */ - eProsima_user_DllExport const std::array, 2>& my_array_array() const; - - /*! - * @brief This function returns a reference to member my_array_array - * @return Reference to member my_array_array - */ - eProsima_user_DllExport std::array, 2>& my_array_array(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const ArrayArrayStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::array, 2> m_my_array_array; - -}; - - - - - -/*! - * @brief This class represents the structure SequenceStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class SequenceStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SequenceStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SequenceStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SequenceStruct that will be copied. - */ - eProsima_user_DllExport SequenceStruct( - const SequenceStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SequenceStruct that will be copied. - */ - eProsima_user_DllExport SequenceStruct( - SequenceStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SequenceStruct that will be copied. - */ - eProsima_user_DllExport SequenceStruct& operator =( - const SequenceStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SequenceStruct that will be copied. - */ - eProsima_user_DllExport SequenceStruct& operator =( - SequenceStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SequenceStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SequenceStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x SequenceStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SequenceStruct& x) const; - - /*! - * @brief This function copies the value in member my_sequence - * @param _my_sequence New value to be copied in member my_sequence - */ - eProsima_user_DllExport void my_sequence( - const std::vector& _my_sequence); - - /*! - * @brief This function moves the value in member my_sequence - * @param _my_sequence New value to be moved in member my_sequence - */ - eProsima_user_DllExport void my_sequence( - std::vector&& _my_sequence); - - /*! - * @brief This function returns a constant reference to member my_sequence - * @return Constant reference to member my_sequence - */ - eProsima_user_DllExport const std::vector& my_sequence() const; - - /*! - * @brief This function returns a reference to member my_sequence - * @return Reference to member my_sequence - */ - eProsima_user_DllExport std::vector& my_sequence(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const SequenceStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::vector m_my_sequence; - -}; - - - - - - - -/*! - * @brief This class represents the structure SequenceSequenceStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class SequenceSequenceStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SequenceSequenceStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SequenceSequenceStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SequenceSequenceStruct that will be copied. - */ - eProsima_user_DllExport SequenceSequenceStruct( - const SequenceSequenceStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SequenceSequenceStruct that will be copied. - */ - eProsima_user_DllExport SequenceSequenceStruct( - SequenceSequenceStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SequenceSequenceStruct that will be copied. - */ - eProsima_user_DllExport SequenceSequenceStruct& operator =( - const SequenceSequenceStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SequenceSequenceStruct that will be copied. - */ - eProsima_user_DllExport SequenceSequenceStruct& operator =( - SequenceSequenceStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SequenceSequenceStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SequenceSequenceStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x SequenceSequenceStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SequenceSequenceStruct& x) const; - - /*! - * @brief This function copies the value in member my_sequence_sequence - * @param _my_sequence_sequence New value to be copied in member my_sequence_sequence - */ - eProsima_user_DllExport void my_sequence_sequence( - const std::vector>& _my_sequence_sequence); - - /*! - * @brief This function moves the value in member my_sequence_sequence - * @param _my_sequence_sequence New value to be moved in member my_sequence_sequence - */ - eProsima_user_DllExport void my_sequence_sequence( - std::vector>&& _my_sequence_sequence); - - /*! - * @brief This function returns a constant reference to member my_sequence_sequence - * @return Constant reference to member my_sequence_sequence - */ - eProsima_user_DllExport const std::vector>& my_sequence_sequence() const; - - /*! - * @brief This function returns a reference to member my_sequence_sequence - * @return Reference to member my_sequence_sequence - */ - eProsima_user_DllExport std::vector>& my_sequence_sequence(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const SequenceSequenceStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::vector> m_my_sequence_sequence; - -}; - - - - - -/*! - * @brief This class represents the structure MapStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class MapStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MapStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MapStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MapStruct that will be copied. - */ - eProsima_user_DllExport MapStruct( - const MapStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MapStruct that will be copied. - */ - eProsima_user_DllExport MapStruct( - MapStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MapStruct that will be copied. - */ - eProsima_user_DllExport MapStruct& operator =( - const MapStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MapStruct that will be copied. - */ - eProsima_user_DllExport MapStruct& operator =( - MapStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MapStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MapStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x MapStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MapStruct& x) const; - - /*! - * @brief This function copies the value in member my_map - * @param _my_map New value to be copied in member my_map - */ - eProsima_user_DllExport void my_map( - const std::map& _my_map); - - /*! - * @brief This function moves the value in member my_map - * @param _my_map New value to be moved in member my_map - */ - eProsima_user_DllExport void my_map( - std::map&& _my_map); - - /*! - * @brief This function returns a constant reference to member my_map - * @return Constant reference to member my_map - */ - eProsima_user_DllExport const std::map& my_map() const; - - /*! - * @brief This function returns a reference to member my_map - * @return Reference to member my_map - */ - eProsima_user_DllExport std::map& my_map(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const MapStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::map m_my_map; - -}; - - - - - - - -/*! - * @brief This class represents the structure MapMapStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class MapMapStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MapMapStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MapMapStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MapMapStruct that will be copied. - */ - eProsima_user_DllExport MapMapStruct( - const MapMapStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MapMapStruct that will be copied. - */ - eProsima_user_DllExport MapMapStruct( - MapMapStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MapMapStruct that will be copied. - */ - eProsima_user_DllExport MapMapStruct& operator =( - const MapMapStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MapMapStruct that will be copied. - */ - eProsima_user_DllExport MapMapStruct& operator =( - MapMapStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MapMapStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MapMapStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x MapMapStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MapMapStruct& x) const; - - /*! - * @brief This function copies the value in member my_map_map - * @param _my_map_map New value to be copied in member my_map_map - */ - eProsima_user_DllExport void my_map_map( - const std::map>& _my_map_map); - - /*! - * @brief This function moves the value in member my_map_map - * @param _my_map_map New value to be moved in member my_map_map - */ - eProsima_user_DllExport void my_map_map( - std::map>&& _my_map_map); - - /*! - * @brief This function returns a constant reference to member my_map_map - * @return Constant reference to member my_map_map - */ - eProsima_user_DllExport const std::map>& my_map_map() const; - - /*! - * @brief This function returns a reference to member my_map_map - * @return Reference to member my_map_map - */ - eProsima_user_DllExport std::map>& my_map_map(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const MapMapStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::map> m_my_map_map; - -}; - -/*! - * @brief This class represents the structure MyBitset defined by the user in the IDL file. - * @ingroup Basic - */ -class MyBitset -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MyBitset(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MyBitset(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MyBitset that will be copied. - */ - eProsima_user_DllExport MyBitset( - const MyBitset& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MyBitset that will be copied. - */ - eProsima_user_DllExport MyBitset( - MyBitset&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MyBitset that will be copied. - */ - eProsima_user_DllExport MyBitset& operator =( - const MyBitset& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MyBitset that will be copied. - */ - eProsima_user_DllExport MyBitset& operator =( - MyBitset&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MyBitset object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MyBitset& x) const; - - /*! - * @brief Comparison operator. - * @param x MyBitset object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MyBitset& x) const; - - /*! - * @brief This function sets a value in member a - * @param _a New value for member a - */ - eProsima_user_DllExport void a( - char _a); - - /*! - * @brief This function returns the value of member a - * @return Value of member a - */ - eProsima_user_DllExport char a() const; - - - - /*! - * @brief This function sets a value in member b - * @param _b New value for member b - */ - eProsima_user_DllExport void b( - uint32_t _b); - - /*! - * @brief This function returns the value of member b - * @return Value of member b - */ - eProsima_user_DllExport uint32_t b() const; - - - eProsima_user_DllExport std::bitset<30> bitset() const; - - eProsima_user_DllExport void bitset( - const std::bitset<30>&); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const MyBitset& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - -private: - - std::bitset<30> m_bitset; -}; - - -/*! - * @brief This class represents the structure BitsetStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class BitsetStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport BitsetStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~BitsetStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object BitsetStruct that will be copied. - */ - eProsima_user_DllExport BitsetStruct( - const BitsetStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object BitsetStruct that will be copied. - */ - eProsima_user_DllExport BitsetStruct( - BitsetStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object BitsetStruct that will be copied. - */ - eProsima_user_DllExport BitsetStruct& operator =( - const BitsetStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object BitsetStruct that will be copied. - */ - eProsima_user_DllExport BitsetStruct& operator =( - BitsetStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x BitsetStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const BitsetStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x BitsetStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const BitsetStruct& x) const; - - /*! - * @brief This function copies the value in member a - * @param _a New value to be copied in member a - */ - eProsima_user_DllExport void a( - const MyBitset& _a); - - /*! - * @brief This function moves the value in member a - * @param _a New value to be moved in member a - */ - eProsima_user_DllExport void a( - MyBitset&& _a); - - /*! - * @brief This function returns a constant reference to member a - * @return Constant reference to member a - */ - eProsima_user_DllExport const MyBitset& a() const; - - /*! - * @brief This function returns a reference to member a - * @return Reference to member a - */ - eProsima_user_DllExport MyBitset& a(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const BitsetStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - MyBitset m_a; - -}; - - - -/*! - * @brief This class represents the structure StructStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class StructStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport StructStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~StructStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object StructStruct that will be copied. - */ - eProsima_user_DllExport StructStruct( - const StructStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object StructStruct that will be copied. - */ - eProsima_user_DllExport StructStruct( - StructStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object StructStruct that will be copied. - */ - eProsima_user_DllExport StructStruct& operator =( - const StructStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object StructStruct that will be copied. - */ - eProsima_user_DllExport StructStruct& operator =( - StructStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x StructStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const StructStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x StructStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const StructStruct& x) const; - - /*! - * @brief This function sets a value in member a - * @param _a New value for member a - */ - eProsima_user_DllExport void a( - int32_t _a); - - /*! - * @brief This function returns the value of member a - * @return Value of member a - */ - eProsima_user_DllExport int32_t a() const; - - /*! - * @brief This function returns a reference to member a - * @return Reference to member a - */ - eProsima_user_DllExport int32_t& a(); - - - /*! - * @brief This function sets a value in member b - * @param _b New value for member b - */ - eProsima_user_DllExport void b( - int64_t _b); - - /*! - * @brief This function returns the value of member b - * @return Value of member b - */ - eProsima_user_DllExport int64_t b() const; - - /*! - * @brief This function returns a reference to member b - * @return Reference to member b - */ - eProsima_user_DllExport int64_t& b(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const StructStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - int32_t m_a; - int64_t m_b; - -}; - - - -/*! - * @brief This class represents the structure StructStructStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class StructStructStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport StructStructStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~StructStructStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object StructStructStruct that will be copied. - */ - eProsima_user_DllExport StructStructStruct( - const StructStructStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object StructStructStruct that will be copied. - */ - eProsima_user_DllExport StructStructStruct( - StructStructStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object StructStructStruct that will be copied. - */ - eProsima_user_DllExport StructStructStruct& operator =( - const StructStructStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object StructStructStruct that will be copied. - */ - eProsima_user_DllExport StructStructStruct& operator =( - StructStructStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x StructStructStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const StructStructStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x StructStructStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const StructStructStruct& x) const; - - /*! - * @brief This function copies the value in member child_struct - * @param _child_struct New value to be copied in member child_struct - */ - eProsima_user_DllExport void child_struct( - const StructStruct& _child_struct); - - /*! - * @brief This function moves the value in member child_struct - * @param _child_struct New value to be moved in member child_struct - */ - eProsima_user_DllExport void child_struct( - StructStruct&& _child_struct); - - /*! - * @brief This function returns a constant reference to member child_struct - * @return Constant reference to member child_struct - */ - eProsima_user_DllExport const StructStruct& child_struct() const; - - /*! - * @brief This function returns a reference to member child_struct - * @return Reference to member child_struct - */ - eProsima_user_DllExport StructStruct& child_struct(); - - - /*! - * @brief This function sets a value in member child_int64 - * @param _child_int64 New value for member child_int64 - */ - eProsima_user_DllExport void child_int64( - int64_t _child_int64); - - /*! - * @brief This function returns the value of member child_int64 - * @return Value of member child_int64 - */ - eProsima_user_DllExport int64_t child_int64() const; - - /*! - * @brief This function returns a reference to member child_int64 - * @return Reference to member child_int64 - */ - eProsima_user_DllExport int64_t& child_int64(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const StructStructStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - StructStruct m_child_struct; - int64_t m_child_int64; - -}; - - - -/*! - * @brief This class represents the union SimpleUnion defined by the user in the IDL file. - * @ingroup Basic - */ -class SimpleUnion -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimpleUnion(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimpleUnion(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimpleUnion that will be copied. - */ - eProsima_user_DllExport SimpleUnion( - const SimpleUnion& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimpleUnion that will be copied. - */ - eProsima_user_DllExport SimpleUnion( - SimpleUnion&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimpleUnion that will be copied. - */ - eProsima_user_DllExport SimpleUnion& operator =( - const SimpleUnion& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimpleUnion that will be copied. - */ - eProsima_user_DllExport SimpleUnion& operator =( - SimpleUnion&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimpleUnion object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimpleUnion& x) const; - - /*! - * @brief Comparison operator. - * @param x SimpleUnion object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimpleUnion& x) const; - - /*! - * @brief This function sets the discriminator value. - * @param __d New value for the discriminator. - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the new value doesn't correspond to the selected union member. - */ - eProsima_user_DllExport void _d( - int32_t __d); - - /*! - * @brief This function returns the value of the discriminator. - * @return Value of the discriminator - */ - eProsima_user_DllExport int32_t _d() const; - - /*! - * @brief This function returns a reference to the discriminator. - * @return Reference to the discriminator. - */ - eProsima_user_DllExport int32_t& _d(); - - /*! - * @brief This function sets a value in member first - * @param _first New value for member first - */ - eProsima_user_DllExport void first( - int32_t _first); - - /*! - * @brief This function returns the value of member first - * @return Value of member first - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t first() const; - - /*! - * @brief This function returns a reference to member first - * @return Reference to member first - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t& first(); - - - /*! - * @brief This function sets a value in member second - * @param _second New value for member second - */ - eProsima_user_DllExport void second( - int64_t _second); - - /*! - * @brief This function returns the value of member second - * @return Value of member second - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t second() const; - - /*! - * @brief This function returns a reference to member second - * @return Reference to member second - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t& second(); - - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const SimpleUnion& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - -private: - - int32_t m__d; - - int32_t m_first; - int64_t m_second; -}; - - - -/*! - * @brief This class represents the union UnionUnion defined by the user in the IDL file. - * @ingroup Basic - */ -class UnionUnion -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport UnionUnion(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~UnionUnion(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object UnionUnion that will be copied. - */ - eProsima_user_DllExport UnionUnion( - const UnionUnion& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object UnionUnion that will be copied. - */ - eProsima_user_DllExport UnionUnion( - UnionUnion&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object UnionUnion that will be copied. - */ - eProsima_user_DllExport UnionUnion& operator =( - const UnionUnion& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object UnionUnion that will be copied. - */ - eProsima_user_DllExport UnionUnion& operator =( - UnionUnion&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x UnionUnion object to compare. - */ - eProsima_user_DllExport bool operator ==( - const UnionUnion& x) const; - - /*! - * @brief Comparison operator. - * @param x UnionUnion object to compare. - */ - eProsima_user_DllExport bool operator !=( - const UnionUnion& x) const; - - /*! - * @brief This function sets the discriminator value. - * @param __d New value for the discriminator. - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the new value doesn't correspond to the selected union member. - */ - eProsima_user_DllExport void _d( - int32_t __d); - - /*! - * @brief This function returns the value of the discriminator. - * @return Value of the discriminator - */ - eProsima_user_DllExport int32_t _d() const; - - /*! - * @brief This function returns a reference to the discriminator. - * @return Reference to the discriminator. - */ - eProsima_user_DllExport int32_t& _d(); - - /*! - * @brief This function sets a value in member first - * @param _first New value for member first - */ - eProsima_user_DllExport void first( - int32_t _first); - - /*! - * @brief This function returns the value of member first - * @return Value of member first - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t first() const; - - /*! - * @brief This function returns a reference to member first - * @return Reference to member first - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t& first(); - - - /*! - * @brief This function copies the value in member second - * @param _second New value to be copied in member second - */ - eProsima_user_DllExport void second( - const SimpleUnion& _second); - - /*! - * @brief This function moves the value in member second - * @param _second New value to be moved in member second - */ - eProsima_user_DllExport void second( - SimpleUnion&& _second); - - /*! - * @brief This function returns a constant reference to member second - * @return Constant reference to member second - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport const SimpleUnion& second() const; - - /*! - * @brief This function returns a reference to member second - * @return Reference to member second - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport SimpleUnion& second(); - - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const UnionUnion& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - -private: - - int32_t m__d; - - int32_t m_first; - SimpleUnion m_second; -}; - - - -/*! - * @brief This class represents the union WCharUnion defined by the user in the IDL file. - * @ingroup Basic - */ -class WCharUnion -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport WCharUnion(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~WCharUnion(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object WCharUnion that will be copied. - */ - eProsima_user_DllExport WCharUnion( - const WCharUnion& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object WCharUnion that will be copied. - */ - eProsima_user_DllExport WCharUnion( - WCharUnion&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object WCharUnion that will be copied. - */ - eProsima_user_DllExport WCharUnion& operator =( - const WCharUnion& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object WCharUnion that will be copied. - */ - eProsima_user_DllExport WCharUnion& operator =( - WCharUnion&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x WCharUnion object to compare. - */ - eProsima_user_DllExport bool operator ==( - const WCharUnion& x) const; - - /*! - * @brief Comparison operator. - * @param x WCharUnion object to compare. - */ - eProsima_user_DllExport bool operator !=( - const WCharUnion& x) const; - - /*! - * @brief This function sets the discriminator value. - * @param __d New value for the discriminator. - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the new value doesn't correspond to the selected union member. - */ - eProsima_user_DllExport void _d( - wchar_t __d); - - /*! - * @brief This function returns the value of the discriminator. - * @return Value of the discriminator - */ - eProsima_user_DllExport wchar_t _d() const; - - /*! - * @brief This function returns a reference to the discriminator. - * @return Reference to the discriminator. - */ - eProsima_user_DllExport wchar_t& _d(); - - /*! - * @brief This function sets a value in member first - * @param _first New value for member first - */ - eProsima_user_DllExport void first( - int32_t _first); - - /*! - * @brief This function returns the value of member first - * @return Value of member first - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t first() const; - - /*! - * @brief This function returns a reference to member first - * @return Reference to member first - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t& first(); - - - /*! - * @brief This function sets a value in member second - * @param _second New value for member second - */ - eProsima_user_DllExport void second( - int64_t _second); - - /*! - * @brief This function returns the value of member second - * @return Value of member second - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t second() const; - - /*! - * @brief This function returns a reference to member second - * @return Reference to member second - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t& second(); - - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const WCharUnion& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - -private: - - wchar_t m__d; - - int32_t m_first; - int64_t m_second; -}; - - - -/*! - * @brief This class represents the structure SimpleUnionStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class SimpleUnionStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimpleUnionStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimpleUnionStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimpleUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleUnionStruct( - const SimpleUnionStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimpleUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleUnionStruct( - SimpleUnionStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimpleUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleUnionStruct& operator =( - const SimpleUnionStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimpleUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleUnionStruct& operator =( - SimpleUnionStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimpleUnionStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimpleUnionStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x SimpleUnionStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimpleUnionStruct& x) const; - - /*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ - eProsima_user_DllExport void my_union( - const SimpleUnion& _my_union); - - /*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ - eProsima_user_DllExport void my_union( - SimpleUnion&& _my_union); - - /*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ - eProsima_user_DllExport const SimpleUnion& my_union() const; - - /*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ - eProsima_user_DllExport SimpleUnion& my_union(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const SimpleUnionStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - SimpleUnion m_my_union; - -}; - - - -/*! - * @brief This class represents the structure UnionUnionUnionStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class UnionUnionUnionStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport UnionUnionUnionStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~UnionUnionUnionStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object UnionUnionUnionStruct that will be copied. - */ - eProsima_user_DllExport UnionUnionUnionStruct( - const UnionUnionUnionStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object UnionUnionUnionStruct that will be copied. - */ - eProsima_user_DllExport UnionUnionUnionStruct( - UnionUnionUnionStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object UnionUnionUnionStruct that will be copied. - */ - eProsima_user_DllExport UnionUnionUnionStruct& operator =( - const UnionUnionUnionStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object UnionUnionUnionStruct that will be copied. - */ - eProsima_user_DllExport UnionUnionUnionStruct& operator =( - UnionUnionUnionStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x UnionUnionUnionStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const UnionUnionUnionStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x UnionUnionUnionStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const UnionUnionUnionStruct& x) const; - - /*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ - eProsima_user_DllExport void my_union( - const UnionUnion& _my_union); - - /*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ - eProsima_user_DllExport void my_union( - UnionUnion&& _my_union); - - /*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ - eProsima_user_DllExport const UnionUnion& my_union() const; - - /*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ - eProsima_user_DllExport UnionUnion& my_union(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const UnionUnionUnionStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - UnionUnion m_my_union; - -}; - - - -/*! - * @brief This class represents the structure WCharUnionStruct defined by the user in the IDL file. - * @ingroup Basic - */ -class WCharUnionStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport WCharUnionStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~WCharUnionStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object WCharUnionStruct that will be copied. - */ - eProsima_user_DllExport WCharUnionStruct( - const WCharUnionStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object WCharUnionStruct that will be copied. - */ - eProsima_user_DllExport WCharUnionStruct( - WCharUnionStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object WCharUnionStruct that will be copied. - */ - eProsima_user_DllExport WCharUnionStruct& operator =( - const WCharUnionStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object WCharUnionStruct that will be copied. - */ - eProsima_user_DllExport WCharUnionStruct& operator =( - WCharUnionStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x WCharUnionStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const WCharUnionStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x WCharUnionStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const WCharUnionStruct& x) const; - - /*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ - eProsima_user_DllExport void my_union( - const WCharUnion& _my_union); - - /*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ - eProsima_user_DllExport void my_union( - WCharUnion&& _my_union); - - /*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ - eProsima_user_DllExport const WCharUnion& my_union() const; - - /*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ - eProsima_user_DllExport WCharUnion& my_union(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const WCharUnionStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - WCharUnion m_my_union; - -}; - - -#endif // _FAST_DDS_GENERATED_BASIC_H_ - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/test/unittest/dynamic_types/idl/Test.cxx b/test/unittest/dynamic_types/idl/Test.cxx deleted file mode 100644 index 423925e0980..00000000000 --- a/test/unittest/dynamic_types/idl/Test.cxx +++ /dev/null @@ -1,2405 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file Test.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "Test.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#include "TestTypeObject.h" - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - - - - -BasicStruct::BasicStruct() -{ - // Just to register all known types - registerTestTypes(); -} - -BasicStruct::~BasicStruct() -{ -} - -BasicStruct::BasicStruct( - const BasicStruct& x) -{ - m_my_bool = x.m_my_bool; - m_my_octet = x.m_my_octet; - m_my_int16 = x.m_my_int16; - m_my_int32 = x.m_my_int32; - m_my_int64 = x.m_my_int64; - m_my_uint16 = x.m_my_uint16; - m_my_uint32 = x.m_my_uint32; - m_my_uint64 = x.m_my_uint64; - m_my_float32 = x.m_my_float32; - m_my_float64 = x.m_my_float64; - m_my_float128 = x.m_my_float128; - m_my_char = x.m_my_char; - m_my_string = x.m_my_string; -} - -BasicStruct::BasicStruct( - BasicStruct&& x) noexcept -{ - m_my_bool = x.m_my_bool; - m_my_octet = x.m_my_octet; - m_my_int16 = x.m_my_int16; - m_my_int32 = x.m_my_int32; - m_my_int64 = x.m_my_int64; - m_my_uint16 = x.m_my_uint16; - m_my_uint32 = x.m_my_uint32; - m_my_uint64 = x.m_my_uint64; - m_my_float32 = x.m_my_float32; - m_my_float64 = x.m_my_float64; - m_my_float128 = x.m_my_float128; - m_my_char = x.m_my_char; - m_my_string = std::move(x.m_my_string); -} - -BasicStruct& BasicStruct::operator =( - const BasicStruct& x) -{ - - m_my_bool = x.m_my_bool; - m_my_octet = x.m_my_octet; - m_my_int16 = x.m_my_int16; - m_my_int32 = x.m_my_int32; - m_my_int64 = x.m_my_int64; - m_my_uint16 = x.m_my_uint16; - m_my_uint32 = x.m_my_uint32; - m_my_uint64 = x.m_my_uint64; - m_my_float32 = x.m_my_float32; - m_my_float64 = x.m_my_float64; - m_my_float128 = x.m_my_float128; - m_my_char = x.m_my_char; - m_my_string = x.m_my_string; - return *this; -} - -BasicStruct& BasicStruct::operator =( - BasicStruct&& x) noexcept -{ - - m_my_bool = x.m_my_bool; - m_my_octet = x.m_my_octet; - m_my_int16 = x.m_my_int16; - m_my_int32 = x.m_my_int32; - m_my_int64 = x.m_my_int64; - m_my_uint16 = x.m_my_uint16; - m_my_uint32 = x.m_my_uint32; - m_my_uint64 = x.m_my_uint64; - m_my_float32 = x.m_my_float32; - m_my_float64 = x.m_my_float64; - m_my_float128 = x.m_my_float128; - m_my_char = x.m_my_char; - m_my_string = std::move(x.m_my_string); - return *this; -} - -bool BasicStruct::operator ==( - const BasicStruct& x) const -{ - return (m_my_bool == x.m_my_bool && - m_my_octet == x.m_my_octet && - m_my_int16 == x.m_my_int16 && - m_my_int32 == x.m_my_int32 && - m_my_int64 == x.m_my_int64 && - m_my_uint16 == x.m_my_uint16 && - m_my_uint32 == x.m_my_uint32 && - m_my_uint64 == x.m_my_uint64 && - m_my_float32 == x.m_my_float32 && - m_my_float64 == x.m_my_float64 && - m_my_float128 == x.m_my_float128 && - m_my_char == x.m_my_char && - m_my_string == x.m_my_string); -} - -bool BasicStruct::operator !=( - const BasicStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member my_bool - * @param _my_bool New value for member my_bool - */ -void BasicStruct::my_bool( - bool _my_bool) -{ - m_my_bool = _my_bool; -} - -/*! - * @brief This function returns the value of member my_bool - * @return Value of member my_bool - */ -bool BasicStruct::my_bool() const -{ - return m_my_bool; -} - -/*! - * @brief This function returns a reference to member my_bool - * @return Reference to member my_bool - */ -bool& BasicStruct::my_bool() -{ - return m_my_bool; -} - - -/*! - * @brief This function sets a value in member my_octet - * @param _my_octet New value for member my_octet - */ -void BasicStruct::my_octet( - uint8_t _my_octet) -{ - m_my_octet = _my_octet; -} - -/*! - * @brief This function returns the value of member my_octet - * @return Value of member my_octet - */ -uint8_t BasicStruct::my_octet() const -{ - return m_my_octet; -} - -/*! - * @brief This function returns a reference to member my_octet - * @return Reference to member my_octet - */ -uint8_t& BasicStruct::my_octet() -{ - return m_my_octet; -} - - -/*! - * @brief This function sets a value in member my_int16 - * @param _my_int16 New value for member my_int16 - */ -void BasicStruct::my_int16( - int16_t _my_int16) -{ - m_my_int16 = _my_int16; -} - -/*! - * @brief This function returns the value of member my_int16 - * @return Value of member my_int16 - */ -int16_t BasicStruct::my_int16() const -{ - return m_my_int16; -} - -/*! - * @brief This function returns a reference to member my_int16 - * @return Reference to member my_int16 - */ -int16_t& BasicStruct::my_int16() -{ - return m_my_int16; -} - - -/*! - * @brief This function sets a value in member my_int32 - * @param _my_int32 New value for member my_int32 - */ -void BasicStruct::my_int32( - int32_t _my_int32) -{ - m_my_int32 = _my_int32; -} - -/*! - * @brief This function returns the value of member my_int32 - * @return Value of member my_int32 - */ -int32_t BasicStruct::my_int32() const -{ - return m_my_int32; -} - -/*! - * @brief This function returns a reference to member my_int32 - * @return Reference to member my_int32 - */ -int32_t& BasicStruct::my_int32() -{ - return m_my_int32; -} - - -/*! - * @brief This function sets a value in member my_int64 - * @param _my_int64 New value for member my_int64 - */ -void BasicStruct::my_int64( - int64_t _my_int64) -{ - m_my_int64 = _my_int64; -} - -/*! - * @brief This function returns the value of member my_int64 - * @return Value of member my_int64 - */ -int64_t BasicStruct::my_int64() const -{ - return m_my_int64; -} - -/*! - * @brief This function returns a reference to member my_int64 - * @return Reference to member my_int64 - */ -int64_t& BasicStruct::my_int64() -{ - return m_my_int64; -} - - -/*! - * @brief This function sets a value in member my_uint16 - * @param _my_uint16 New value for member my_uint16 - */ -void BasicStruct::my_uint16( - uint16_t _my_uint16) -{ - m_my_uint16 = _my_uint16; -} - -/*! - * @brief This function returns the value of member my_uint16 - * @return Value of member my_uint16 - */ -uint16_t BasicStruct::my_uint16() const -{ - return m_my_uint16; -} - -/*! - * @brief This function returns a reference to member my_uint16 - * @return Reference to member my_uint16 - */ -uint16_t& BasicStruct::my_uint16() -{ - return m_my_uint16; -} - - -/*! - * @brief This function sets a value in member my_uint32 - * @param _my_uint32 New value for member my_uint32 - */ -void BasicStruct::my_uint32( - uint32_t _my_uint32) -{ - m_my_uint32 = _my_uint32; -} - -/*! - * @brief This function returns the value of member my_uint32 - * @return Value of member my_uint32 - */ -uint32_t BasicStruct::my_uint32() const -{ - return m_my_uint32; -} - -/*! - * @brief This function returns a reference to member my_uint32 - * @return Reference to member my_uint32 - */ -uint32_t& BasicStruct::my_uint32() -{ - return m_my_uint32; -} - - -/*! - * @brief This function sets a value in member my_uint64 - * @param _my_uint64 New value for member my_uint64 - */ -void BasicStruct::my_uint64( - uint64_t _my_uint64) -{ - m_my_uint64 = _my_uint64; -} - -/*! - * @brief This function returns the value of member my_uint64 - * @return Value of member my_uint64 - */ -uint64_t BasicStruct::my_uint64() const -{ - return m_my_uint64; -} - -/*! - * @brief This function returns a reference to member my_uint64 - * @return Reference to member my_uint64 - */ -uint64_t& BasicStruct::my_uint64() -{ - return m_my_uint64; -} - - -/*! - * @brief This function sets a value in member my_float32 - * @param _my_float32 New value for member my_float32 - */ -void BasicStruct::my_float32( - float _my_float32) -{ - m_my_float32 = _my_float32; -} - -/*! - * @brief This function returns the value of member my_float32 - * @return Value of member my_float32 - */ -float BasicStruct::my_float32() const -{ - return m_my_float32; -} - -/*! - * @brief This function returns a reference to member my_float32 - * @return Reference to member my_float32 - */ -float& BasicStruct::my_float32() -{ - return m_my_float32; -} - - -/*! - * @brief This function sets a value in member my_float64 - * @param _my_float64 New value for member my_float64 - */ -void BasicStruct::my_float64( - double _my_float64) -{ - m_my_float64 = _my_float64; -} - -/*! - * @brief This function returns the value of member my_float64 - * @return Value of member my_float64 - */ -double BasicStruct::my_float64() const -{ - return m_my_float64; -} - -/*! - * @brief This function returns a reference to member my_float64 - * @return Reference to member my_float64 - */ -double& BasicStruct::my_float64() -{ - return m_my_float64; -} - - -/*! - * @brief This function sets a value in member my_float128 - * @param _my_float128 New value for member my_float128 - */ -void BasicStruct::my_float128( - long double _my_float128) -{ - m_my_float128 = _my_float128; -} - -/*! - * @brief This function returns the value of member my_float128 - * @return Value of member my_float128 - */ -long double BasicStruct::my_float128() const -{ - return m_my_float128; -} - -/*! - * @brief This function returns a reference to member my_float128 - * @return Reference to member my_float128 - */ -long double& BasicStruct::my_float128() -{ - return m_my_float128; -} - - -/*! - * @brief This function sets a value in member my_char - * @param _my_char New value for member my_char - */ -void BasicStruct::my_char( - char _my_char) -{ - m_my_char = _my_char; -} - -/*! - * @brief This function returns the value of member my_char - * @return Value of member my_char - */ -char BasicStruct::my_char() const -{ - return m_my_char; -} - -/*! - * @brief This function returns a reference to member my_char - * @return Reference to member my_char - */ -char& BasicStruct::my_char() -{ - return m_my_char; -} - - -/*! - * @brief This function copies the value in member my_string - * @param _my_string New value to be copied in member my_string - */ -void BasicStruct::my_string( - const std::string& _my_string) -{ - m_my_string = _my_string; -} - -/*! - * @brief This function moves the value in member my_string - * @param _my_string New value to be moved in member my_string - */ -void BasicStruct::my_string( - std::string&& _my_string) -{ - m_my_string = std::move(_my_string); -} - -/*! - * @brief This function returns a constant reference to member my_string - * @return Constant reference to member my_string - */ -const std::string& BasicStruct::my_string() const -{ - return m_my_string; -} - -/*! - * @brief This function returns a reference to member my_string - * @return Reference to member my_string - */ -std::string& BasicStruct::my_string() -{ - return m_my_string; -} - - - - - - - - - - - -ComplexStruct::ComplexStruct() -{ - // Just to register all known types - registerTestTypes(); -} - -ComplexStruct::~ComplexStruct() -{ -} - -ComplexStruct::ComplexStruct( - const ComplexStruct& x) -{ - m_my_octet = x.m_my_octet; - m_my_basic_struct = x.m_my_basic_struct; - m_my_alias_enum = x.m_my_alias_enum; - m_my_enum = x.m_my_enum; - m_my_sequence_octet = x.m_my_sequence_octet; - m_my_sequence_struct = x.m_my_sequence_struct; - m_my_array_octet = x.m_my_array_octet; - m_my_octet_array_500 = x.m_my_octet_array_500; - m_my_array_struct = x.m_my_array_struct; - m_my_map_octet_short = x.m_my_map_octet_short; - m_my_map_long_struct = x.m_my_map_long_struct; - m_my_map_long_seq_octet = x.m_my_map_long_seq_octet; - m_my_map_long_octet_array_500 = x.m_my_map_long_octet_array_500; - m_my_map_long_lol_type = x.m_my_map_long_lol_type; - m_my_small_string_8 = x.m_my_small_string_8; - m_my_large_string_8 = x.m_my_large_string_8; - m_my_array_string = x.m_my_array_string; - m_multi_alias_array_42 = x.m_multi_alias_array_42; - m_my_array_arrays = x.m_my_array_arrays; - m_my_sequences_array = x.m_my_sequences_array; -} - -ComplexStruct::ComplexStruct( - ComplexStruct&& x) noexcept -{ - m_my_octet = x.m_my_octet; - m_my_basic_struct = std::move(x.m_my_basic_struct); - m_my_alias_enum = x.m_my_alias_enum; - m_my_enum = x.m_my_enum; - m_my_sequence_octet = std::move(x.m_my_sequence_octet); - m_my_sequence_struct = std::move(x.m_my_sequence_struct); - m_my_array_octet = std::move(x.m_my_array_octet); - m_my_octet_array_500 = std::move(x.m_my_octet_array_500); - m_my_array_struct = std::move(x.m_my_array_struct); - m_my_map_octet_short = std::move(x.m_my_map_octet_short); - m_my_map_long_struct = std::move(x.m_my_map_long_struct); - m_my_map_long_seq_octet = std::move(x.m_my_map_long_seq_octet); - m_my_map_long_octet_array_500 = std::move(x.m_my_map_long_octet_array_500); - m_my_map_long_lol_type = std::move(x.m_my_map_long_lol_type); - m_my_small_string_8 = std::move(x.m_my_small_string_8); - m_my_large_string_8 = std::move(x.m_my_large_string_8); - m_my_array_string = std::move(x.m_my_array_string); - m_multi_alias_array_42 = std::move(x.m_multi_alias_array_42); - m_my_array_arrays = std::move(x.m_my_array_arrays); - m_my_sequences_array = std::move(x.m_my_sequences_array); -} - -ComplexStruct& ComplexStruct::operator =( - const ComplexStruct& x) -{ - - m_my_octet = x.m_my_octet; - m_my_basic_struct = x.m_my_basic_struct; - m_my_alias_enum = x.m_my_alias_enum; - m_my_enum = x.m_my_enum; - m_my_sequence_octet = x.m_my_sequence_octet; - m_my_sequence_struct = x.m_my_sequence_struct; - m_my_array_octet = x.m_my_array_octet; - m_my_octet_array_500 = x.m_my_octet_array_500; - m_my_array_struct = x.m_my_array_struct; - m_my_map_octet_short = x.m_my_map_octet_short; - m_my_map_long_struct = x.m_my_map_long_struct; - m_my_map_long_seq_octet = x.m_my_map_long_seq_octet; - m_my_map_long_octet_array_500 = x.m_my_map_long_octet_array_500; - m_my_map_long_lol_type = x.m_my_map_long_lol_type; - m_my_small_string_8 = x.m_my_small_string_8; - m_my_large_string_8 = x.m_my_large_string_8; - m_my_array_string = x.m_my_array_string; - m_multi_alias_array_42 = x.m_multi_alias_array_42; - m_my_array_arrays = x.m_my_array_arrays; - m_my_sequences_array = x.m_my_sequences_array; - return *this; -} - -ComplexStruct& ComplexStruct::operator =( - ComplexStruct&& x) noexcept -{ - - m_my_octet = x.m_my_octet; - m_my_basic_struct = std::move(x.m_my_basic_struct); - m_my_alias_enum = x.m_my_alias_enum; - m_my_enum = x.m_my_enum; - m_my_sequence_octet = std::move(x.m_my_sequence_octet); - m_my_sequence_struct = std::move(x.m_my_sequence_struct); - m_my_array_octet = std::move(x.m_my_array_octet); - m_my_octet_array_500 = std::move(x.m_my_octet_array_500); - m_my_array_struct = std::move(x.m_my_array_struct); - m_my_map_octet_short = std::move(x.m_my_map_octet_short); - m_my_map_long_struct = std::move(x.m_my_map_long_struct); - m_my_map_long_seq_octet = std::move(x.m_my_map_long_seq_octet); - m_my_map_long_octet_array_500 = std::move(x.m_my_map_long_octet_array_500); - m_my_map_long_lol_type = std::move(x.m_my_map_long_lol_type); - m_my_small_string_8 = std::move(x.m_my_small_string_8); - m_my_large_string_8 = std::move(x.m_my_large_string_8); - m_my_array_string = std::move(x.m_my_array_string); - m_multi_alias_array_42 = std::move(x.m_multi_alias_array_42); - m_my_array_arrays = std::move(x.m_my_array_arrays); - m_my_sequences_array = std::move(x.m_my_sequences_array); - return *this; -} - -bool ComplexStruct::operator ==( - const ComplexStruct& x) const -{ - return (m_my_octet == x.m_my_octet && - m_my_basic_struct == x.m_my_basic_struct && - m_my_alias_enum == x.m_my_alias_enum && - m_my_enum == x.m_my_enum && - m_my_sequence_octet == x.m_my_sequence_octet && - m_my_sequence_struct == x.m_my_sequence_struct && - m_my_array_octet == x.m_my_array_octet && - m_my_octet_array_500 == x.m_my_octet_array_500 && - m_my_array_struct == x.m_my_array_struct && - m_my_map_octet_short == x.m_my_map_octet_short && - m_my_map_long_struct == x.m_my_map_long_struct && - m_my_map_long_seq_octet == x.m_my_map_long_seq_octet && - m_my_map_long_octet_array_500 == x.m_my_map_long_octet_array_500 && - m_my_map_long_lol_type == x.m_my_map_long_lol_type && - m_my_small_string_8 == x.m_my_small_string_8 && - m_my_large_string_8 == x.m_my_large_string_8 && - m_my_array_string == x.m_my_array_string && - m_multi_alias_array_42 == x.m_multi_alias_array_42 && - m_my_array_arrays == x.m_my_array_arrays && - m_my_sequences_array == x.m_my_sequences_array); -} - -bool ComplexStruct::operator !=( - const ComplexStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member my_octet - * @param _my_octet New value for member my_octet - */ -void ComplexStruct::my_octet( - uint8_t _my_octet) -{ - m_my_octet = _my_octet; -} - -/*! - * @brief This function returns the value of member my_octet - * @return Value of member my_octet - */ -uint8_t ComplexStruct::my_octet() const -{ - return m_my_octet; -} - -/*! - * @brief This function returns a reference to member my_octet - * @return Reference to member my_octet - */ -uint8_t& ComplexStruct::my_octet() -{ - return m_my_octet; -} - - -/*! - * @brief This function copies the value in member my_basic_struct - * @param _my_basic_struct New value to be copied in member my_basic_struct - */ -void ComplexStruct::my_basic_struct( - const BasicStruct& _my_basic_struct) -{ - m_my_basic_struct = _my_basic_struct; -} - -/*! - * @brief This function moves the value in member my_basic_struct - * @param _my_basic_struct New value to be moved in member my_basic_struct - */ -void ComplexStruct::my_basic_struct( - BasicStruct&& _my_basic_struct) -{ - m_my_basic_struct = std::move(_my_basic_struct); -} - -/*! - * @brief This function returns a constant reference to member my_basic_struct - * @return Constant reference to member my_basic_struct - */ -const BasicStruct& ComplexStruct::my_basic_struct() const -{ - return m_my_basic_struct; -} - -/*! - * @brief This function returns a reference to member my_basic_struct - * @return Reference to member my_basic_struct - */ -BasicStruct& ComplexStruct::my_basic_struct() -{ - return m_my_basic_struct; -} - - -/*! - * @brief This function sets a value in member my_alias_enum - * @param _my_alias_enum New value for member my_alias_enum - */ -void ComplexStruct::my_alias_enum( - MyAliasEnum _my_alias_enum) -{ - m_my_alias_enum = _my_alias_enum; -} - -/*! - * @brief This function returns the value of member my_alias_enum - * @return Value of member my_alias_enum - */ -MyAliasEnum ComplexStruct::my_alias_enum() const -{ - return m_my_alias_enum; -} - -/*! - * @brief This function returns a reference to member my_alias_enum - * @return Reference to member my_alias_enum - */ -MyAliasEnum& ComplexStruct::my_alias_enum() -{ - return m_my_alias_enum; -} - - -/*! - * @brief This function sets a value in member my_enum - * @param _my_enum New value for member my_enum - */ -void ComplexStruct::my_enum( - MyEnum _my_enum) -{ - m_my_enum = _my_enum; -} - -/*! - * @brief This function returns the value of member my_enum - * @return Value of member my_enum - */ -MyEnum ComplexStruct::my_enum() const -{ - return m_my_enum; -} - -/*! - * @brief This function returns a reference to member my_enum - * @return Reference to member my_enum - */ -MyEnum& ComplexStruct::my_enum() -{ - return m_my_enum; -} - - -/*! - * @brief This function copies the value in member my_sequence_octet - * @param _my_sequence_octet New value to be copied in member my_sequence_octet - */ -void ComplexStruct::my_sequence_octet( - const std::vector& _my_sequence_octet) -{ - m_my_sequence_octet = _my_sequence_octet; -} - -/*! - * @brief This function moves the value in member my_sequence_octet - * @param _my_sequence_octet New value to be moved in member my_sequence_octet - */ -void ComplexStruct::my_sequence_octet( - std::vector&& _my_sequence_octet) -{ - m_my_sequence_octet = std::move(_my_sequence_octet); -} - -/*! - * @brief This function returns a constant reference to member my_sequence_octet - * @return Constant reference to member my_sequence_octet - */ -const std::vector& ComplexStruct::my_sequence_octet() const -{ - return m_my_sequence_octet; -} - -/*! - * @brief This function returns a reference to member my_sequence_octet - * @return Reference to member my_sequence_octet - */ -std::vector& ComplexStruct::my_sequence_octet() -{ - return m_my_sequence_octet; -} - - -/*! - * @brief This function copies the value in member my_sequence_struct - * @param _my_sequence_struct New value to be copied in member my_sequence_struct - */ -void ComplexStruct::my_sequence_struct( - const std::vector& _my_sequence_struct) -{ - m_my_sequence_struct = _my_sequence_struct; -} - -/*! - * @brief This function moves the value in member my_sequence_struct - * @param _my_sequence_struct New value to be moved in member my_sequence_struct - */ -void ComplexStruct::my_sequence_struct( - std::vector&& _my_sequence_struct) -{ - m_my_sequence_struct = std::move(_my_sequence_struct); -} - -/*! - * @brief This function returns a constant reference to member my_sequence_struct - * @return Constant reference to member my_sequence_struct - */ -const std::vector& ComplexStruct::my_sequence_struct() const -{ - return m_my_sequence_struct; -} - -/*! - * @brief This function returns a reference to member my_sequence_struct - * @return Reference to member my_sequence_struct - */ -std::vector& ComplexStruct::my_sequence_struct() -{ - return m_my_sequence_struct; -} - - -/*! - * @brief This function copies the value in member my_array_octet - * @param _my_array_octet New value to be copied in member my_array_octet - */ -void ComplexStruct::my_array_octet( - const std::array, 5>, 500>& _my_array_octet) -{ - m_my_array_octet = _my_array_octet; -} - -/*! - * @brief This function moves the value in member my_array_octet - * @param _my_array_octet New value to be moved in member my_array_octet - */ -void ComplexStruct::my_array_octet( - std::array, 5>, 500>&& _my_array_octet) -{ - m_my_array_octet = std::move(_my_array_octet); -} - -/*! - * @brief This function returns a constant reference to member my_array_octet - * @return Constant reference to member my_array_octet - */ -const std::array, 5>, 500>& ComplexStruct::my_array_octet() const -{ - return m_my_array_octet; -} - -/*! - * @brief This function returns a reference to member my_array_octet - * @return Reference to member my_array_octet - */ -std::array, 5>, 500>& ComplexStruct::my_array_octet() -{ - return m_my_array_octet; -} - - -/*! - * @brief This function copies the value in member my_octet_array_500 - * @param _my_octet_array_500 New value to be copied in member my_octet_array_500 - */ -void ComplexStruct::my_octet_array_500( - const MyOctetArray500& _my_octet_array_500) -{ - m_my_octet_array_500 = _my_octet_array_500; -} - -/*! - * @brief This function moves the value in member my_octet_array_500 - * @param _my_octet_array_500 New value to be moved in member my_octet_array_500 - */ -void ComplexStruct::my_octet_array_500( - MyOctetArray500&& _my_octet_array_500) -{ - m_my_octet_array_500 = std::move(_my_octet_array_500); -} - -/*! - * @brief This function returns a constant reference to member my_octet_array_500 - * @return Constant reference to member my_octet_array_500 - */ -const MyOctetArray500& ComplexStruct::my_octet_array_500() const -{ - return m_my_octet_array_500; -} - -/*! - * @brief This function returns a reference to member my_octet_array_500 - * @return Reference to member my_octet_array_500 - */ -MyOctetArray500& ComplexStruct::my_octet_array_500() -{ - return m_my_octet_array_500; -} - - -/*! - * @brief This function copies the value in member my_array_struct - * @param _my_array_struct New value to be copied in member my_array_struct - */ -void ComplexStruct::my_array_struct( - const std::array& _my_array_struct) -{ - m_my_array_struct = _my_array_struct; -} - -/*! - * @brief This function moves the value in member my_array_struct - * @param _my_array_struct New value to be moved in member my_array_struct - */ -void ComplexStruct::my_array_struct( - std::array&& _my_array_struct) -{ - m_my_array_struct = std::move(_my_array_struct); -} - -/*! - * @brief This function returns a constant reference to member my_array_struct - * @return Constant reference to member my_array_struct - */ -const std::array& ComplexStruct::my_array_struct() const -{ - return m_my_array_struct; -} - -/*! - * @brief This function returns a reference to member my_array_struct - * @return Reference to member my_array_struct - */ -std::array& ComplexStruct::my_array_struct() -{ - return m_my_array_struct; -} - - -/*! - * @brief This function copies the value in member my_map_octet_short - * @param _my_map_octet_short New value to be copied in member my_map_octet_short - */ -void ComplexStruct::my_map_octet_short( - const std::map& _my_map_octet_short) -{ - m_my_map_octet_short = _my_map_octet_short; -} - -/*! - * @brief This function moves the value in member my_map_octet_short - * @param _my_map_octet_short New value to be moved in member my_map_octet_short - */ -void ComplexStruct::my_map_octet_short( - std::map&& _my_map_octet_short) -{ - m_my_map_octet_short = std::move(_my_map_octet_short); -} - -/*! - * @brief This function returns a constant reference to member my_map_octet_short - * @return Constant reference to member my_map_octet_short - */ -const std::map& ComplexStruct::my_map_octet_short() const -{ - return m_my_map_octet_short; -} - -/*! - * @brief This function returns a reference to member my_map_octet_short - * @return Reference to member my_map_octet_short - */ -std::map& ComplexStruct::my_map_octet_short() -{ - return m_my_map_octet_short; -} - - -/*! - * @brief This function copies the value in member my_map_long_struct - * @param _my_map_long_struct New value to be copied in member my_map_long_struct - */ -void ComplexStruct::my_map_long_struct( - const std::map& _my_map_long_struct) -{ - m_my_map_long_struct = _my_map_long_struct; -} - -/*! - * @brief This function moves the value in member my_map_long_struct - * @param _my_map_long_struct New value to be moved in member my_map_long_struct - */ -void ComplexStruct::my_map_long_struct( - std::map&& _my_map_long_struct) -{ - m_my_map_long_struct = std::move(_my_map_long_struct); -} - -/*! - * @brief This function returns a constant reference to member my_map_long_struct - * @return Constant reference to member my_map_long_struct - */ -const std::map& ComplexStruct::my_map_long_struct() const -{ - return m_my_map_long_struct; -} - -/*! - * @brief This function returns a reference to member my_map_long_struct - * @return Reference to member my_map_long_struct - */ -std::map& ComplexStruct::my_map_long_struct() -{ - return m_my_map_long_struct; -} - - -/*! - * @brief This function copies the value in member my_map_long_seq_octet - * @param _my_map_long_seq_octet New value to be copied in member my_map_long_seq_octet - */ -void ComplexStruct::my_map_long_seq_octet( - const std::map>>& _my_map_long_seq_octet) -{ - m_my_map_long_seq_octet = _my_map_long_seq_octet; -} - -/*! - * @brief This function moves the value in member my_map_long_seq_octet - * @param _my_map_long_seq_octet New value to be moved in member my_map_long_seq_octet - */ -void ComplexStruct::my_map_long_seq_octet( - std::map>>&& _my_map_long_seq_octet) -{ - m_my_map_long_seq_octet = std::move(_my_map_long_seq_octet); -} - -/*! - * @brief This function returns a constant reference to member my_map_long_seq_octet - * @return Constant reference to member my_map_long_seq_octet - */ -const std::map>>& ComplexStruct::my_map_long_seq_octet() const -{ - return m_my_map_long_seq_octet; -} - -/*! - * @brief This function returns a reference to member my_map_long_seq_octet - * @return Reference to member my_map_long_seq_octet - */ -std::map>>& ComplexStruct::my_map_long_seq_octet() -{ - return m_my_map_long_seq_octet; -} - - -/*! - * @brief This function copies the value in member my_map_long_octet_array_500 - * @param _my_map_long_octet_array_500 New value to be copied in member my_map_long_octet_array_500 - */ -void ComplexStruct::my_map_long_octet_array_500( - const std::map& _my_map_long_octet_array_500) -{ - m_my_map_long_octet_array_500 = _my_map_long_octet_array_500; -} - -/*! - * @brief This function moves the value in member my_map_long_octet_array_500 - * @param _my_map_long_octet_array_500 New value to be moved in member my_map_long_octet_array_500 - */ -void ComplexStruct::my_map_long_octet_array_500( - std::map&& _my_map_long_octet_array_500) -{ - m_my_map_long_octet_array_500 = std::move(_my_map_long_octet_array_500); -} - -/*! - * @brief This function returns a constant reference to member my_map_long_octet_array_500 - * @return Constant reference to member my_map_long_octet_array_500 - */ -const std::map& ComplexStruct::my_map_long_octet_array_500() const -{ - return m_my_map_long_octet_array_500; -} - -/*! - * @brief This function returns a reference to member my_map_long_octet_array_500 - * @return Reference to member my_map_long_octet_array_500 - */ -std::map& ComplexStruct::my_map_long_octet_array_500() -{ - return m_my_map_long_octet_array_500; -} - - -/*! - * @brief This function copies the value in member my_map_long_lol_type - * @param _my_map_long_lol_type New value to be copied in member my_map_long_lol_type - */ -void ComplexStruct::my_map_long_lol_type( - const std::map>& _my_map_long_lol_type) -{ - m_my_map_long_lol_type = _my_map_long_lol_type; -} - -/*! - * @brief This function moves the value in member my_map_long_lol_type - * @param _my_map_long_lol_type New value to be moved in member my_map_long_lol_type - */ -void ComplexStruct::my_map_long_lol_type( - std::map>&& _my_map_long_lol_type) -{ - m_my_map_long_lol_type = std::move(_my_map_long_lol_type); -} - -/*! - * @brief This function returns a constant reference to member my_map_long_lol_type - * @return Constant reference to member my_map_long_lol_type - */ -const std::map>& ComplexStruct::my_map_long_lol_type() const -{ - return m_my_map_long_lol_type; -} - -/*! - * @brief This function returns a reference to member my_map_long_lol_type - * @return Reference to member my_map_long_lol_type - */ -std::map>& ComplexStruct::my_map_long_lol_type() -{ - return m_my_map_long_lol_type; -} - - -/*! - * @brief This function copies the value in member my_small_string_8 - * @param _my_small_string_8 New value to be copied in member my_small_string_8 - */ -void ComplexStruct::my_small_string_8( - const eprosima::fastcdr::fixed_string<128>& _my_small_string_8) -{ - m_my_small_string_8 = _my_small_string_8; -} - -/*! - * @brief This function moves the value in member my_small_string_8 - * @param _my_small_string_8 New value to be moved in member my_small_string_8 - */ -void ComplexStruct::my_small_string_8( - eprosima::fastcdr::fixed_string<128>&& _my_small_string_8) -{ - m_my_small_string_8 = std::move(_my_small_string_8); -} - -/*! - * @brief This function returns a constant reference to member my_small_string_8 - * @return Constant reference to member my_small_string_8 - */ -const eprosima::fastcdr::fixed_string<128>& ComplexStruct::my_small_string_8() const -{ - return m_my_small_string_8; -} - -/*! - * @brief This function returns a reference to member my_small_string_8 - * @return Reference to member my_small_string_8 - */ -eprosima::fastcdr::fixed_string<128>& ComplexStruct::my_small_string_8() -{ - return m_my_small_string_8; -} - - -/*! - * @brief This function copies the value in member my_large_string_8 - * @param _my_large_string_8 New value to be copied in member my_large_string_8 - */ -void ComplexStruct::my_large_string_8( - const eprosima::fastcdr::fixed_string<500>& _my_large_string_8) -{ - m_my_large_string_8 = _my_large_string_8; -} - -/*! - * @brief This function moves the value in member my_large_string_8 - * @param _my_large_string_8 New value to be moved in member my_large_string_8 - */ -void ComplexStruct::my_large_string_8( - eprosima::fastcdr::fixed_string<500>&& _my_large_string_8) -{ - m_my_large_string_8 = std::move(_my_large_string_8); -} - -/*! - * @brief This function returns a constant reference to member my_large_string_8 - * @return Constant reference to member my_large_string_8 - */ -const eprosima::fastcdr::fixed_string<500>& ComplexStruct::my_large_string_8() const -{ - return m_my_large_string_8; -} - -/*! - * @brief This function returns a reference to member my_large_string_8 - * @return Reference to member my_large_string_8 - */ -eprosima::fastcdr::fixed_string<500>& ComplexStruct::my_large_string_8() -{ - return m_my_large_string_8; -} - - -/*! - * @brief This function copies the value in member my_array_string - * @param _my_array_string New value to be copied in member my_array_string - */ -void ComplexStruct::my_array_string( - const std::array, 5>, 5>& _my_array_string) -{ - m_my_array_string = _my_array_string; -} - -/*! - * @brief This function moves the value in member my_array_string - * @param _my_array_string New value to be moved in member my_array_string - */ -void ComplexStruct::my_array_string( - std::array, 5>, 5>&& _my_array_string) -{ - m_my_array_string = std::move(_my_array_string); -} - -/*! - * @brief This function returns a constant reference to member my_array_string - * @return Constant reference to member my_array_string - */ -const std::array, 5>, 5>& ComplexStruct::my_array_string() const -{ - return m_my_array_string; -} - -/*! - * @brief This function returns a reference to member my_array_string - * @return Reference to member my_array_string - */ -std::array, 5>, 5>& ComplexStruct::my_array_string() -{ - return m_my_array_string; -} - - -/*! - * @brief This function copies the value in member multi_alias_array_42 - * @param _multi_alias_array_42 New value to be copied in member multi_alias_array_42 - */ -void ComplexStruct::multi_alias_array_42( - const MA3& _multi_alias_array_42) -{ - m_multi_alias_array_42 = _multi_alias_array_42; -} - -/*! - * @brief This function moves the value in member multi_alias_array_42 - * @param _multi_alias_array_42 New value to be moved in member multi_alias_array_42 - */ -void ComplexStruct::multi_alias_array_42( - MA3&& _multi_alias_array_42) -{ - m_multi_alias_array_42 = std::move(_multi_alias_array_42); -} - -/*! - * @brief This function returns a constant reference to member multi_alias_array_42 - * @return Constant reference to member multi_alias_array_42 - */ -const MA3& ComplexStruct::multi_alias_array_42() const -{ - return m_multi_alias_array_42; -} - -/*! - * @brief This function returns a reference to member multi_alias_array_42 - * @return Reference to member multi_alias_array_42 - */ -MA3& ComplexStruct::multi_alias_array_42() -{ - return m_multi_alias_array_42; -} - - -/*! - * @brief This function copies the value in member my_array_arrays - * @param _my_array_arrays New value to be copied in member my_array_arrays - */ -void ComplexStruct::my_array_arrays( - const std::array& _my_array_arrays) -{ - m_my_array_arrays = _my_array_arrays; -} - -/*! - * @brief This function moves the value in member my_array_arrays - * @param _my_array_arrays New value to be moved in member my_array_arrays - */ -void ComplexStruct::my_array_arrays( - std::array&& _my_array_arrays) -{ - m_my_array_arrays = std::move(_my_array_arrays); -} - -/*! - * @brief This function returns a constant reference to member my_array_arrays - * @return Constant reference to member my_array_arrays - */ -const std::array& ComplexStruct::my_array_arrays() const -{ - return m_my_array_arrays; -} - -/*! - * @brief This function returns a reference to member my_array_arrays - * @return Reference to member my_array_arrays - */ -std::array& ComplexStruct::my_array_arrays() -{ - return m_my_array_arrays; -} - - -/*! - * @brief This function copies the value in member my_sequences_array - * @param _my_sequences_array New value to be copied in member my_sequences_array - */ -void ComplexStruct::my_sequences_array( - const std::array& _my_sequences_array) -{ - m_my_sequences_array = _my_sequences_array; -} - -/*! - * @brief This function moves the value in member my_sequences_array - * @param _my_sequences_array New value to be moved in member my_sequences_array - */ -void ComplexStruct::my_sequences_array( - std::array&& _my_sequences_array) -{ - m_my_sequences_array = std::move(_my_sequences_array); -} - -/*! - * @brief This function returns a constant reference to member my_sequences_array - * @return Constant reference to member my_sequences_array - */ -const std::array& ComplexStruct::my_sequences_array() const -{ - return m_my_sequences_array; -} - -/*! - * @brief This function returns a reference to member my_sequences_array - * @return Reference to member my_sequences_array - */ -std::array& ComplexStruct::my_sequences_array() -{ - return m_my_sequences_array; -} - - - - -MyUnion::MyUnion() -{ - m__d = ::A; -} - -MyUnion::~MyUnion() -{ -} - -MyUnion::MyUnion( - const MyUnion& x) -{ - m__d = x.m__d; - - switch (m__d) - { - case ::A: - m_basic = x.m_basic; - break; - - - case ::B: - case ::C: - m_complex = x.m_complex; - break; - - default: - break; - } -} - -MyUnion::MyUnion( - MyUnion&& x) noexcept -{ - m__d = x.m__d; - - switch (m__d) - { - case ::A: - m_basic = std::move(x.m_basic); - - break; - - - case ::B: - case ::C: - m_complex = std::move(x.m_complex); - - break; - - default: - break; - } -} - -MyUnion& MyUnion::operator =( - const MyUnion& x) -{ - m__d = x.m__d; - - switch (m__d) - { - case ::A: - m_basic = x.m_basic; - break; - - - case ::B: - case ::C: - m_complex = x.m_complex; - break; - - default: - break; - } - - return *this; -} - -MyUnion& MyUnion::operator =( - MyUnion&& x) noexcept -{ - m__d = x.m__d; - - switch (m__d) - { - case ::A: - m_basic = std::move(x.m_basic); - - break; - - - case ::B: - case ::C: - m_complex = std::move(x.m_complex); - - break; - - default: - break; - } - - return *this; -} - -bool MyUnion::operator ==( - const MyUnion& x) const -{ - if (m__d != x.m__d) - { - return false; - } - - switch (m__d) - { - case ::A: - return (m_basic == x.m_basic); - break; - - - case ::B: - case ::C: - return (m_complex == x.m_complex); - break; - - default: - break; - } - return false; -} - -bool MyUnion::operator !=( - const MyUnion& x) const -{ - return !(*this == x); -} - -void MyUnion::_d( - MyEnum __d) -{ - bool b = false; - - switch (m__d) - { - case ::A: - switch (__d) - { - case ::A: - b = true; - break; - default: - break; - } - break; - - - case ::B: - case ::C: - switch (__d) - { - case ::B: - case ::C: - b = true; - break; - default: - break; - } - break; - - default: - break; - } - - if (!b) - { - throw BadParamException("Discriminator doesn't correspond with the selected union member"); - } - - m__d = __d; -} - -MyEnum MyUnion::_d() const -{ - return m__d; -} - -MyEnum& MyUnion::_d() -{ - return m__d; -} - -void MyUnion::basic( - const BasicStruct& _basic) -{ - m_basic = _basic; - m__d = ::A; - -} - -void MyUnion::basic( - BasicStruct&& _basic) -{ - m_basic = std::move(_basic); - m__d = ::A; - -} - -const BasicStruct& MyUnion::basic() const -{ - bool b = false; - - switch (m__d) - { - case ::A: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_basic; -} - -BasicStruct& MyUnion::basic() -{ - bool b = false; - - switch (m__d) - { - case ::A: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_basic; -} - - -void MyUnion::complex( - const ComplexStruct& _complex) -{ - m_complex = _complex; - m__d = ::B; - -} - -void MyUnion::complex( - ComplexStruct&& _complex) -{ - m_complex = std::move(_complex); - m__d = ::B; - -} - -const ComplexStruct& MyUnion::complex() const -{ - bool b = false; - - switch (m__d) - { - case ::B: - case ::C: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_complex; -} - -ComplexStruct& MyUnion::complex() -{ - bool b = false; - - switch (m__d) - { - case ::B: - case ::C: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_complex; -} - - - - -MyUnion2::MyUnion2() -{ - m__d = A; -} - -MyUnion2::~MyUnion2() -{ -} - -MyUnion2::MyUnion2( - const MyUnion2& x) -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_uno = x.m_uno; - break; - - - case B: - m_imString = x.m_imString; - break; - - - case C: - m_tres = x.m_tres; - break; - - default: - break; - } -} - -MyUnion2::MyUnion2( - MyUnion2&& x) noexcept -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_uno = x.m_uno; - break; - - - case B: - m_imString = std::move(x.m_imString); - - break; - - - case C: - m_tres = x.m_tres; - break; - - default: - break; - } -} - -MyUnion2& MyUnion2::operator =( - const MyUnion2& x) -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_uno = x.m_uno; - break; - - - case B: - m_imString = x.m_imString; - break; - - - case C: - m_tres = x.m_tres; - break; - - default: - break; - } - - return *this; -} - -MyUnion2& MyUnion2::operator =( - MyUnion2&& x) noexcept -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_uno = x.m_uno; - break; - - - case B: - m_imString = std::move(x.m_imString); - - break; - - - case C: - m_tres = x.m_tres; - break; - - default: - break; - } - - return *this; -} - -bool MyUnion2::operator ==( - const MyUnion2& x) const -{ - if (m__d != x.m__d) - { - return false; - } - - switch (m__d) - { - case A: - return (m_uno == x.m_uno); - break; - - - case B: - return (m_imString == x.m_imString); - break; - - - case C: - return (m_tres == x.m_tres); - break; - - default: - break; - } - return false; -} - -bool MyUnion2::operator !=( - const MyUnion2& x) const -{ - return !(*this == x); -} - -void MyUnion2::_d( - uint8_t __d) -{ - bool b = false; - - switch (m__d) - { - case A: - switch (__d) - { - case A: - b = true; - break; - default: - break; - } - break; - - - case B: - switch (__d) - { - case B: - b = true; - break; - default: - break; - } - break; - - - case C: - switch (__d) - { - case C: - b = true; - break; - default: - break; - } - break; - - default: - break; - } - - if (!b) - { - throw BadParamException("Discriminator doesn't correspond with the selected union member"); - } - - m__d = __d; -} - -uint8_t MyUnion2::_d() const -{ - return m__d; -} - -uint8_t& MyUnion2::_d() -{ - return m__d; -} - -void MyUnion2::uno( - int32_t _uno) -{ - m_uno = _uno; - m__d = A; - -} - -int32_t MyUnion2::uno() const -{ - bool b = false; - - switch (m__d) - { - case A: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_uno; -} - -int32_t& MyUnion2::uno() -{ - bool b = false; - - switch (m__d) - { - case A: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_uno; -} - - -void MyUnion2::imString( - const std::string& _imString) -{ - m_imString = _imString; - m__d = B; - -} - -void MyUnion2::imString( - std::string&& _imString) -{ - m_imString = std::move(_imString); - m__d = B; - -} - -const std::string& MyUnion2::imString() const -{ - bool b = false; - - switch (m__d) - { - case B: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_imString; -} - -std::string& MyUnion2::imString() -{ - bool b = false; - - switch (m__d) - { - case B: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_imString; -} - - -void MyUnion2::tres( - int32_t _tres) -{ - m_tres = _tres; - m__d = C; - -} - -int32_t MyUnion2::tres() const -{ - bool b = false; - - switch (m__d) - { - case C: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_tres; -} - -int32_t& MyUnion2::tres() -{ - bool b = false; - - switch (m__d) - { - case C: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_tres; -} - - - - -CompleteStruct::CompleteStruct() -{ - // Just to register all known types - registerTestTypes(); -} - -CompleteStruct::~CompleteStruct() -{ -} - -CompleteStruct::CompleteStruct( - const CompleteStruct& x) -{ - m_my_union = x.m_my_union; - m_my_union_2 = x.m_my_union_2; -} - -CompleteStruct::CompleteStruct( - CompleteStruct&& x) noexcept -{ - m_my_union = std::move(x.m_my_union); - m_my_union_2 = std::move(x.m_my_union_2); -} - -CompleteStruct& CompleteStruct::operator =( - const CompleteStruct& x) -{ - - m_my_union = x.m_my_union; - m_my_union_2 = x.m_my_union_2; - return *this; -} - -CompleteStruct& CompleteStruct::operator =( - CompleteStruct&& x) noexcept -{ - - m_my_union = std::move(x.m_my_union); - m_my_union_2 = std::move(x.m_my_union_2); - return *this; -} - -bool CompleteStruct::operator ==( - const CompleteStruct& x) const -{ - return (m_my_union == x.m_my_union && - m_my_union_2 == x.m_my_union_2); -} - -bool CompleteStruct::operator !=( - const CompleteStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ -void CompleteStruct::my_union( - const MyUnion& _my_union) -{ - m_my_union = _my_union; -} - -/*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ -void CompleteStruct::my_union( - MyUnion&& _my_union) -{ - m_my_union = std::move(_my_union); -} - -/*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ -const MyUnion& CompleteStruct::my_union() const -{ - return m_my_union; -} - -/*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ -MyUnion& CompleteStruct::my_union() -{ - return m_my_union; -} - - -/*! - * @brief This function copies the value in member my_union_2 - * @param _my_union_2 New value to be copied in member my_union_2 - */ -void CompleteStruct::my_union_2( - const MyUnion2& _my_union_2) -{ - m_my_union_2 = _my_union_2; -} - -/*! - * @brief This function moves the value in member my_union_2 - * @param _my_union_2 New value to be moved in member my_union_2 - */ -void CompleteStruct::my_union_2( - MyUnion2&& _my_union_2) -{ - m_my_union_2 = std::move(_my_union_2); -} - -/*! - * @brief This function returns a constant reference to member my_union_2 - * @return Constant reference to member my_union_2 - */ -const MyUnion2& CompleteStruct::my_union_2() const -{ - return m_my_union_2; -} - -/*! - * @brief This function returns a reference to member my_union_2 - * @return Reference to member my_union_2 - */ -MyUnion2& CompleteStruct::my_union_2() -{ - return m_my_union_2; -} - - - - -KeyedStruct::KeyedStruct() -{ - // Just to register all known types - registerTestTypes(); -} - -KeyedStruct::~KeyedStruct() -{ -} - -KeyedStruct::KeyedStruct( - const KeyedStruct& x) -{ - m_key = x.m_key; - m_basic = x.m_basic; -} - -KeyedStruct::KeyedStruct( - KeyedStruct&& x) noexcept -{ - m_key = x.m_key; - m_basic = std::move(x.m_basic); -} - -KeyedStruct& KeyedStruct::operator =( - const KeyedStruct& x) -{ - - m_key = x.m_key; - m_basic = x.m_basic; - return *this; -} - -KeyedStruct& KeyedStruct::operator =( - KeyedStruct&& x) noexcept -{ - - m_key = x.m_key; - m_basic = std::move(x.m_basic); - return *this; -} - -bool KeyedStruct::operator ==( - const KeyedStruct& x) const -{ - return (m_key == x.m_key && - m_basic == x.m_basic); -} - -bool KeyedStruct::operator !=( - const KeyedStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member key - * @param _key New value for member key - */ -void KeyedStruct::key( - uint8_t _key) -{ - m_key = _key; -} - -/*! - * @brief This function returns the value of member key - * @return Value of member key - */ -uint8_t KeyedStruct::key() const -{ - return m_key; -} - -/*! - * @brief This function returns a reference to member key - * @return Reference to member key - */ -uint8_t& KeyedStruct::key() -{ - return m_key; -} - - -/*! - * @brief This function copies the value in member basic - * @param _basic New value to be copied in member basic - */ -void KeyedStruct::basic( - const BasicStruct& _basic) -{ - m_basic = _basic; -} - -/*! - * @brief This function moves the value in member basic - * @param _basic New value to be moved in member basic - */ -void KeyedStruct::basic( - BasicStruct&& _basic) -{ - m_basic = std::move(_basic); -} - -/*! - * @brief This function returns a constant reference to member basic - * @return Constant reference to member basic - */ -const BasicStruct& KeyedStruct::basic() const -{ - return m_basic; -} - -/*! - * @brief This function returns a reference to member basic - * @return Reference to member basic - */ -BasicStruct& KeyedStruct::basic() -{ - return m_basic; -} - - -// Include auxiliary functions like for serializing/deserializing. -#include "TestCdrAux.ipp" - -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/test/unittest/dynamic_types/idl/Test.h b/test/unittest/dynamic_types/idl/Test.h deleted file mode 100644 index a67ced7e1c2..00000000000 --- a/test/unittest/dynamic_types/idl/Test.h +++ /dev/null @@ -1,1601 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file Test.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#include -#include "Testv1.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#ifndef _FAST_DDS_GENERATED_TEST_H_ -#define _FAST_DDS_GENERATED_TEST_H_ - -#include -#include -#include -#include -#include -#include - -#include -#include -#include - - - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define eProsima_user_DllExport -#endif // _WIN32 - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(TEST_SOURCE) -#define TEST_DllAPI __declspec( dllexport ) -#else -#define TEST_DllAPI __declspec( dllimport ) -#endif // TEST_SOURCE -#else -#define TEST_DllAPI -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define TEST_DllAPI -#endif // _WIN32 - -namespace eprosima { -namespace fastcdr { -class Cdr; -class CdrSizeCalculator; -} // namespace fastcdr -} // namespace eprosima - - - -/*! - * @brief This class represents the enumeration MyEnum defined by the user in the IDL file. - * @ingroup Test - */ -enum MyEnum : uint32_t -{ - A, - B, - C -}; -typedef MyEnum MyAliasEnum; - -typedef MyAliasEnum MyAliasEnum2; - -typedef MyAliasEnum2 MyAliasEnum3; - - - -/*! - * @brief This class represents the structure BasicStruct defined by the user in the IDL file. - * @ingroup Test - */ -class BasicStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport BasicStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~BasicStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object BasicStruct that will be copied. - */ - eProsima_user_DllExport BasicStruct( - const BasicStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object BasicStruct that will be copied. - */ - eProsima_user_DllExport BasicStruct( - BasicStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object BasicStruct that will be copied. - */ - eProsima_user_DllExport BasicStruct& operator =( - const BasicStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object BasicStruct that will be copied. - */ - eProsima_user_DllExport BasicStruct& operator =( - BasicStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x BasicStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const BasicStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x BasicStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const BasicStruct& x) const; - - /*! - * @brief This function sets a value in member my_bool - * @param _my_bool New value for member my_bool - */ - eProsima_user_DllExport void my_bool( - bool _my_bool); - - /*! - * @brief This function returns the value of member my_bool - * @return Value of member my_bool - */ - eProsima_user_DllExport bool my_bool() const; - - /*! - * @brief This function returns a reference to member my_bool - * @return Reference to member my_bool - */ - eProsima_user_DllExport bool& my_bool(); - - - /*! - * @brief This function sets a value in member my_octet - * @param _my_octet New value for member my_octet - */ - eProsima_user_DllExport void my_octet( - uint8_t _my_octet); - - /*! - * @brief This function returns the value of member my_octet - * @return Value of member my_octet - */ - eProsima_user_DllExport uint8_t my_octet() const; - - /*! - * @brief This function returns a reference to member my_octet - * @return Reference to member my_octet - */ - eProsima_user_DllExport uint8_t& my_octet(); - - - /*! - * @brief This function sets a value in member my_int16 - * @param _my_int16 New value for member my_int16 - */ - eProsima_user_DllExport void my_int16( - int16_t _my_int16); - - /*! - * @brief This function returns the value of member my_int16 - * @return Value of member my_int16 - */ - eProsima_user_DllExport int16_t my_int16() const; - - /*! - * @brief This function returns a reference to member my_int16 - * @return Reference to member my_int16 - */ - eProsima_user_DllExport int16_t& my_int16(); - - - /*! - * @brief This function sets a value in member my_int32 - * @param _my_int32 New value for member my_int32 - */ - eProsima_user_DllExport void my_int32( - int32_t _my_int32); - - /*! - * @brief This function returns the value of member my_int32 - * @return Value of member my_int32 - */ - eProsima_user_DllExport int32_t my_int32() const; - - /*! - * @brief This function returns a reference to member my_int32 - * @return Reference to member my_int32 - */ - eProsima_user_DllExport int32_t& my_int32(); - - - /*! - * @brief This function sets a value in member my_int64 - * @param _my_int64 New value for member my_int64 - */ - eProsima_user_DllExport void my_int64( - int64_t _my_int64); - - /*! - * @brief This function returns the value of member my_int64 - * @return Value of member my_int64 - */ - eProsima_user_DllExport int64_t my_int64() const; - - /*! - * @brief This function returns a reference to member my_int64 - * @return Reference to member my_int64 - */ - eProsima_user_DllExport int64_t& my_int64(); - - - /*! - * @brief This function sets a value in member my_uint16 - * @param _my_uint16 New value for member my_uint16 - */ - eProsima_user_DllExport void my_uint16( - uint16_t _my_uint16); - - /*! - * @brief This function returns the value of member my_uint16 - * @return Value of member my_uint16 - */ - eProsima_user_DllExport uint16_t my_uint16() const; - - /*! - * @brief This function returns a reference to member my_uint16 - * @return Reference to member my_uint16 - */ - eProsima_user_DllExport uint16_t& my_uint16(); - - - /*! - * @brief This function sets a value in member my_uint32 - * @param _my_uint32 New value for member my_uint32 - */ - eProsima_user_DllExport void my_uint32( - uint32_t _my_uint32); - - /*! - * @brief This function returns the value of member my_uint32 - * @return Value of member my_uint32 - */ - eProsima_user_DllExport uint32_t my_uint32() const; - - /*! - * @brief This function returns a reference to member my_uint32 - * @return Reference to member my_uint32 - */ - eProsima_user_DllExport uint32_t& my_uint32(); - - - /*! - * @brief This function sets a value in member my_uint64 - * @param _my_uint64 New value for member my_uint64 - */ - eProsima_user_DllExport void my_uint64( - uint64_t _my_uint64); - - /*! - * @brief This function returns the value of member my_uint64 - * @return Value of member my_uint64 - */ - eProsima_user_DllExport uint64_t my_uint64() const; - - /*! - * @brief This function returns a reference to member my_uint64 - * @return Reference to member my_uint64 - */ - eProsima_user_DllExport uint64_t& my_uint64(); - - - /*! - * @brief This function sets a value in member my_float32 - * @param _my_float32 New value for member my_float32 - */ - eProsima_user_DllExport void my_float32( - float _my_float32); - - /*! - * @brief This function returns the value of member my_float32 - * @return Value of member my_float32 - */ - eProsima_user_DllExport float my_float32() const; - - /*! - * @brief This function returns a reference to member my_float32 - * @return Reference to member my_float32 - */ - eProsima_user_DllExport float& my_float32(); - - - /*! - * @brief This function sets a value in member my_float64 - * @param _my_float64 New value for member my_float64 - */ - eProsima_user_DllExport void my_float64( - double _my_float64); - - /*! - * @brief This function returns the value of member my_float64 - * @return Value of member my_float64 - */ - eProsima_user_DllExport double my_float64() const; - - /*! - * @brief This function returns a reference to member my_float64 - * @return Reference to member my_float64 - */ - eProsima_user_DllExport double& my_float64(); - - - /*! - * @brief This function sets a value in member my_float128 - * @param _my_float128 New value for member my_float128 - */ - eProsima_user_DllExport void my_float128( - long double _my_float128); - - /*! - * @brief This function returns the value of member my_float128 - * @return Value of member my_float128 - */ - eProsima_user_DllExport long double my_float128() const; - - /*! - * @brief This function returns a reference to member my_float128 - * @return Reference to member my_float128 - */ - eProsima_user_DllExport long double& my_float128(); - - - /*! - * @brief This function sets a value in member my_char - * @param _my_char New value for member my_char - */ - eProsima_user_DllExport void my_char( - char _my_char); - - /*! - * @brief This function returns the value of member my_char - * @return Value of member my_char - */ - eProsima_user_DllExport char my_char() const; - - /*! - * @brief This function returns a reference to member my_char - * @return Reference to member my_char - */ - eProsima_user_DllExport char& my_char(); - - - /*! - * @brief This function copies the value in member my_string - * @param _my_string New value to be copied in member my_string - */ - eProsima_user_DllExport void my_string( - const std::string& _my_string); - - /*! - * @brief This function moves the value in member my_string - * @param _my_string New value to be moved in member my_string - */ - eProsima_user_DllExport void my_string( - std::string&& _my_string); - - /*! - * @brief This function returns a constant reference to member my_string - * @return Constant reference to member my_string - */ - eProsima_user_DllExport const std::string& my_string() const; - - /*! - * @brief This function returns a reference to member my_string - * @return Reference to member my_string - */ - eProsima_user_DllExport std::string& my_string(); - -private: - - bool m_my_bool{false}; - uint8_t m_my_octet{0}; - int16_t m_my_int16{0}; - int32_t m_my_int32{0}; - int64_t m_my_int64{0}; - uint16_t m_my_uint16{0}; - uint32_t m_my_uint32{0}; - uint64_t m_my_uint64{0}; - float m_my_float32{0.0}; - double m_my_float64{0.0}; - long double m_my_float128{0.0}; - char m_my_char{0}; - std::string m_my_string; - -}; -typedef std::array MyOctetArray500; - -typedef std::array BSAlias5; - -typedef std::array MA3; - -typedef std::array MyMiniArray; - - - -typedef std::vector MySequenceLong; - - - -/*! - * @brief This class represents the structure ComplexStruct defined by the user in the IDL file. - * @ingroup Test - */ -class ComplexStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport ComplexStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~ComplexStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object ComplexStruct that will be copied. - */ - eProsima_user_DllExport ComplexStruct( - const ComplexStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object ComplexStruct that will be copied. - */ - eProsima_user_DllExport ComplexStruct( - ComplexStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object ComplexStruct that will be copied. - */ - eProsima_user_DllExport ComplexStruct& operator =( - const ComplexStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object ComplexStruct that will be copied. - */ - eProsima_user_DllExport ComplexStruct& operator =( - ComplexStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x ComplexStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const ComplexStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x ComplexStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const ComplexStruct& x) const; - - /*! - * @brief This function sets a value in member my_octet - * @param _my_octet New value for member my_octet - */ - eProsima_user_DllExport void my_octet( - uint8_t _my_octet); - - /*! - * @brief This function returns the value of member my_octet - * @return Value of member my_octet - */ - eProsima_user_DllExport uint8_t my_octet() const; - - /*! - * @brief This function returns a reference to member my_octet - * @return Reference to member my_octet - */ - eProsima_user_DllExport uint8_t& my_octet(); - - - /*! - * @brief This function copies the value in member my_basic_struct - * @param _my_basic_struct New value to be copied in member my_basic_struct - */ - eProsima_user_DllExport void my_basic_struct( - const BasicStruct& _my_basic_struct); - - /*! - * @brief This function moves the value in member my_basic_struct - * @param _my_basic_struct New value to be moved in member my_basic_struct - */ - eProsima_user_DllExport void my_basic_struct( - BasicStruct&& _my_basic_struct); - - /*! - * @brief This function returns a constant reference to member my_basic_struct - * @return Constant reference to member my_basic_struct - */ - eProsima_user_DllExport const BasicStruct& my_basic_struct() const; - - /*! - * @brief This function returns a reference to member my_basic_struct - * @return Reference to member my_basic_struct - */ - eProsima_user_DllExport BasicStruct& my_basic_struct(); - - - /*! - * @brief This function sets a value in member my_alias_enum - * @param _my_alias_enum New value for member my_alias_enum - */ - eProsima_user_DllExport void my_alias_enum( - MyAliasEnum _my_alias_enum); - - /*! - * @brief This function returns the value of member my_alias_enum - * @return Value of member my_alias_enum - */ - eProsima_user_DllExport MyAliasEnum my_alias_enum() const; - - /*! - * @brief This function returns a reference to member my_alias_enum - * @return Reference to member my_alias_enum - */ - eProsima_user_DllExport MyAliasEnum& my_alias_enum(); - - - /*! - * @brief This function sets a value in member my_enum - * @param _my_enum New value for member my_enum - */ - eProsima_user_DllExport void my_enum( - MyEnum _my_enum); - - /*! - * @brief This function returns the value of member my_enum - * @return Value of member my_enum - */ - eProsima_user_DllExport MyEnum my_enum() const; - - /*! - * @brief This function returns a reference to member my_enum - * @return Reference to member my_enum - */ - eProsima_user_DllExport MyEnum& my_enum(); - - - /*! - * @brief This function copies the value in member my_sequence_octet - * @param _my_sequence_octet New value to be copied in member my_sequence_octet - */ - eProsima_user_DllExport void my_sequence_octet( - const std::vector& _my_sequence_octet); - - /*! - * @brief This function moves the value in member my_sequence_octet - * @param _my_sequence_octet New value to be moved in member my_sequence_octet - */ - eProsima_user_DllExport void my_sequence_octet( - std::vector&& _my_sequence_octet); - - /*! - * @brief This function returns a constant reference to member my_sequence_octet - * @return Constant reference to member my_sequence_octet - */ - eProsima_user_DllExport const std::vector& my_sequence_octet() const; - - /*! - * @brief This function returns a reference to member my_sequence_octet - * @return Reference to member my_sequence_octet - */ - eProsima_user_DllExport std::vector& my_sequence_octet(); - - - /*! - * @brief This function copies the value in member my_sequence_struct - * @param _my_sequence_struct New value to be copied in member my_sequence_struct - */ - eProsima_user_DllExport void my_sequence_struct( - const std::vector& _my_sequence_struct); - - /*! - * @brief This function moves the value in member my_sequence_struct - * @param _my_sequence_struct New value to be moved in member my_sequence_struct - */ - eProsima_user_DllExport void my_sequence_struct( - std::vector&& _my_sequence_struct); - - /*! - * @brief This function returns a constant reference to member my_sequence_struct - * @return Constant reference to member my_sequence_struct - */ - eProsima_user_DllExport const std::vector& my_sequence_struct() const; - - /*! - * @brief This function returns a reference to member my_sequence_struct - * @return Reference to member my_sequence_struct - */ - eProsima_user_DllExport std::vector& my_sequence_struct(); - - - /*! - * @brief This function copies the value in member my_array_octet - * @param _my_array_octet New value to be copied in member my_array_octet - */ - eProsima_user_DllExport void my_array_octet( - const std::array, 5>, 500>& _my_array_octet); - - /*! - * @brief This function moves the value in member my_array_octet - * @param _my_array_octet New value to be moved in member my_array_octet - */ - eProsima_user_DllExport void my_array_octet( - std::array, 5>, 500>&& _my_array_octet); - - /*! - * @brief This function returns a constant reference to member my_array_octet - * @return Constant reference to member my_array_octet - */ - eProsima_user_DllExport const std::array, 5>, 500>& my_array_octet() const; - - /*! - * @brief This function returns a reference to member my_array_octet - * @return Reference to member my_array_octet - */ - eProsima_user_DllExport std::array, 5>, 500>& my_array_octet(); - - - /*! - * @brief This function copies the value in member my_octet_array_500 - * @param _my_octet_array_500 New value to be copied in member my_octet_array_500 - */ - eProsima_user_DllExport void my_octet_array_500( - const MyOctetArray500& _my_octet_array_500); - - /*! - * @brief This function moves the value in member my_octet_array_500 - * @param _my_octet_array_500 New value to be moved in member my_octet_array_500 - */ - eProsima_user_DllExport void my_octet_array_500( - MyOctetArray500&& _my_octet_array_500); - - /*! - * @brief This function returns a constant reference to member my_octet_array_500 - * @return Constant reference to member my_octet_array_500 - */ - eProsima_user_DllExport const MyOctetArray500& my_octet_array_500() const; - - /*! - * @brief This function returns a reference to member my_octet_array_500 - * @return Reference to member my_octet_array_500 - */ - eProsima_user_DllExport MyOctetArray500& my_octet_array_500(); - - - /*! - * @brief This function copies the value in member my_array_struct - * @param _my_array_struct New value to be copied in member my_array_struct - */ - eProsima_user_DllExport void my_array_struct( - const std::array& _my_array_struct); - - /*! - * @brief This function moves the value in member my_array_struct - * @param _my_array_struct New value to be moved in member my_array_struct - */ - eProsima_user_DllExport void my_array_struct( - std::array&& _my_array_struct); - - /*! - * @brief This function returns a constant reference to member my_array_struct - * @return Constant reference to member my_array_struct - */ - eProsima_user_DllExport const std::array& my_array_struct() const; - - /*! - * @brief This function returns a reference to member my_array_struct - * @return Reference to member my_array_struct - */ - eProsima_user_DllExport std::array& my_array_struct(); - - - /*! - * @brief This function copies the value in member my_map_octet_short - * @param _my_map_octet_short New value to be copied in member my_map_octet_short - */ - eProsima_user_DllExport void my_map_octet_short( - const std::map& _my_map_octet_short); - - /*! - * @brief This function moves the value in member my_map_octet_short - * @param _my_map_octet_short New value to be moved in member my_map_octet_short - */ - eProsima_user_DllExport void my_map_octet_short( - std::map&& _my_map_octet_short); - - /*! - * @brief This function returns a constant reference to member my_map_octet_short - * @return Constant reference to member my_map_octet_short - */ - eProsima_user_DllExport const std::map& my_map_octet_short() const; - - /*! - * @brief This function returns a reference to member my_map_octet_short - * @return Reference to member my_map_octet_short - */ - eProsima_user_DllExport std::map& my_map_octet_short(); - - - /*! - * @brief This function copies the value in member my_map_long_struct - * @param _my_map_long_struct New value to be copied in member my_map_long_struct - */ - eProsima_user_DllExport void my_map_long_struct( - const std::map& _my_map_long_struct); - - /*! - * @brief This function moves the value in member my_map_long_struct - * @param _my_map_long_struct New value to be moved in member my_map_long_struct - */ - eProsima_user_DllExport void my_map_long_struct( - std::map&& _my_map_long_struct); - - /*! - * @brief This function returns a constant reference to member my_map_long_struct - * @return Constant reference to member my_map_long_struct - */ - eProsima_user_DllExport const std::map& my_map_long_struct() const; - - /*! - * @brief This function returns a reference to member my_map_long_struct - * @return Reference to member my_map_long_struct - */ - eProsima_user_DllExport std::map& my_map_long_struct(); - - - /*! - * @brief This function copies the value in member my_map_long_seq_octet - * @param _my_map_long_seq_octet New value to be copied in member my_map_long_seq_octet - */ - eProsima_user_DllExport void my_map_long_seq_octet( - const std::map>>& _my_map_long_seq_octet); - - /*! - * @brief This function moves the value in member my_map_long_seq_octet - * @param _my_map_long_seq_octet New value to be moved in member my_map_long_seq_octet - */ - eProsima_user_DllExport void my_map_long_seq_octet( - std::map>>&& _my_map_long_seq_octet); - - /*! - * @brief This function returns a constant reference to member my_map_long_seq_octet - * @return Constant reference to member my_map_long_seq_octet - */ - eProsima_user_DllExport const std::map>>& my_map_long_seq_octet() const; - - /*! - * @brief This function returns a reference to member my_map_long_seq_octet - * @return Reference to member my_map_long_seq_octet - */ - eProsima_user_DllExport std::map>>& my_map_long_seq_octet(); - - - /*! - * @brief This function copies the value in member my_map_long_octet_array_500 - * @param _my_map_long_octet_array_500 New value to be copied in member my_map_long_octet_array_500 - */ - eProsima_user_DllExport void my_map_long_octet_array_500( - const std::map& _my_map_long_octet_array_500); - - /*! - * @brief This function moves the value in member my_map_long_octet_array_500 - * @param _my_map_long_octet_array_500 New value to be moved in member my_map_long_octet_array_500 - */ - eProsima_user_DllExport void my_map_long_octet_array_500( - std::map&& _my_map_long_octet_array_500); - - /*! - * @brief This function returns a constant reference to member my_map_long_octet_array_500 - * @return Constant reference to member my_map_long_octet_array_500 - */ - eProsima_user_DllExport const std::map& my_map_long_octet_array_500() const; - - /*! - * @brief This function returns a reference to member my_map_long_octet_array_500 - * @return Reference to member my_map_long_octet_array_500 - */ - eProsima_user_DllExport std::map& my_map_long_octet_array_500(); - - - /*! - * @brief This function copies the value in member my_map_long_lol_type - * @param _my_map_long_lol_type New value to be copied in member my_map_long_lol_type - */ - eProsima_user_DllExport void my_map_long_lol_type( - const std::map>& _my_map_long_lol_type); - - /*! - * @brief This function moves the value in member my_map_long_lol_type - * @param _my_map_long_lol_type New value to be moved in member my_map_long_lol_type - */ - eProsima_user_DllExport void my_map_long_lol_type( - std::map>&& _my_map_long_lol_type); - - /*! - * @brief This function returns a constant reference to member my_map_long_lol_type - * @return Constant reference to member my_map_long_lol_type - */ - eProsima_user_DllExport const std::map>& my_map_long_lol_type() const; - - /*! - * @brief This function returns a reference to member my_map_long_lol_type - * @return Reference to member my_map_long_lol_type - */ - eProsima_user_DllExport std::map>& my_map_long_lol_type(); - - - /*! - * @brief This function copies the value in member my_small_string_8 - * @param _my_small_string_8 New value to be copied in member my_small_string_8 - */ - eProsima_user_DllExport void my_small_string_8( - const eprosima::fastcdr::fixed_string<128>& _my_small_string_8); - - /*! - * @brief This function moves the value in member my_small_string_8 - * @param _my_small_string_8 New value to be moved in member my_small_string_8 - */ - eProsima_user_DllExport void my_small_string_8( - eprosima::fastcdr::fixed_string<128>&& _my_small_string_8); - - /*! - * @brief This function returns a constant reference to member my_small_string_8 - * @return Constant reference to member my_small_string_8 - */ - eProsima_user_DllExport const eprosima::fastcdr::fixed_string<128>& my_small_string_8() const; - - /*! - * @brief This function returns a reference to member my_small_string_8 - * @return Reference to member my_small_string_8 - */ - eProsima_user_DllExport eprosima::fastcdr::fixed_string<128>& my_small_string_8(); - - - /*! - * @brief This function copies the value in member my_large_string_8 - * @param _my_large_string_8 New value to be copied in member my_large_string_8 - */ - eProsima_user_DllExport void my_large_string_8( - const eprosima::fastcdr::fixed_string<500>& _my_large_string_8); - - /*! - * @brief This function moves the value in member my_large_string_8 - * @param _my_large_string_8 New value to be moved in member my_large_string_8 - */ - eProsima_user_DllExport void my_large_string_8( - eprosima::fastcdr::fixed_string<500>&& _my_large_string_8); - - /*! - * @brief This function returns a constant reference to member my_large_string_8 - * @return Constant reference to member my_large_string_8 - */ - eProsima_user_DllExport const eprosima::fastcdr::fixed_string<500>& my_large_string_8() const; - - /*! - * @brief This function returns a reference to member my_large_string_8 - * @return Reference to member my_large_string_8 - */ - eProsima_user_DllExport eprosima::fastcdr::fixed_string<500>& my_large_string_8(); - - - /*! - * @brief This function copies the value in member my_array_string - * @param _my_array_string New value to be copied in member my_array_string - */ - eProsima_user_DllExport void my_array_string( - const std::array, 5>, 5>& _my_array_string); - - /*! - * @brief This function moves the value in member my_array_string - * @param _my_array_string New value to be moved in member my_array_string - */ - eProsima_user_DllExport void my_array_string( - std::array, 5>, 5>&& _my_array_string); - - /*! - * @brief This function returns a constant reference to member my_array_string - * @return Constant reference to member my_array_string - */ - eProsima_user_DllExport const std::array, 5>, 5>& my_array_string() const; - - /*! - * @brief This function returns a reference to member my_array_string - * @return Reference to member my_array_string - */ - eProsima_user_DllExport std::array, 5>, 5>& my_array_string(); - - - /*! - * @brief This function copies the value in member multi_alias_array_42 - * @param _multi_alias_array_42 New value to be copied in member multi_alias_array_42 - */ - eProsima_user_DllExport void multi_alias_array_42( - const MA3& _multi_alias_array_42); - - /*! - * @brief This function moves the value in member multi_alias_array_42 - * @param _multi_alias_array_42 New value to be moved in member multi_alias_array_42 - */ - eProsima_user_DllExport void multi_alias_array_42( - MA3&& _multi_alias_array_42); - - /*! - * @brief This function returns a constant reference to member multi_alias_array_42 - * @return Constant reference to member multi_alias_array_42 - */ - eProsima_user_DllExport const MA3& multi_alias_array_42() const; - - /*! - * @brief This function returns a reference to member multi_alias_array_42 - * @return Reference to member multi_alias_array_42 - */ - eProsima_user_DllExport MA3& multi_alias_array_42(); - - - /*! - * @brief This function copies the value in member my_array_arrays - * @param _my_array_arrays New value to be copied in member my_array_arrays - */ - eProsima_user_DllExport void my_array_arrays( - const std::array& _my_array_arrays); - - /*! - * @brief This function moves the value in member my_array_arrays - * @param _my_array_arrays New value to be moved in member my_array_arrays - */ - eProsima_user_DllExport void my_array_arrays( - std::array&& _my_array_arrays); - - /*! - * @brief This function returns a constant reference to member my_array_arrays - * @return Constant reference to member my_array_arrays - */ - eProsima_user_DllExport const std::array& my_array_arrays() const; - - /*! - * @brief This function returns a reference to member my_array_arrays - * @return Reference to member my_array_arrays - */ - eProsima_user_DllExport std::array& my_array_arrays(); - - - /*! - * @brief This function copies the value in member my_sequences_array - * @param _my_sequences_array New value to be copied in member my_sequences_array - */ - eProsima_user_DllExport void my_sequences_array( - const std::array& _my_sequences_array); - - /*! - * @brief This function moves the value in member my_sequences_array - * @param _my_sequences_array New value to be moved in member my_sequences_array - */ - eProsima_user_DllExport void my_sequences_array( - std::array&& _my_sequences_array); - - /*! - * @brief This function returns a constant reference to member my_sequences_array - * @return Constant reference to member my_sequences_array - */ - eProsima_user_DllExport const std::array& my_sequences_array() const; - - /*! - * @brief This function returns a reference to member my_sequences_array - * @return Reference to member my_sequences_array - */ - eProsima_user_DllExport std::array& my_sequences_array(); - -private: - - uint8_t m_my_octet{0}; - BasicStruct m_my_basic_struct; - MyAliasEnum m_my_alias_enum{::A}; - MyEnum m_my_enum{::A}; - std::vector m_my_sequence_octet; - std::vector m_my_sequence_struct; - std::array, 5>, 500> m_my_array_octet{ {{ {{0}} }} }; - MyOctetArray500 m_my_octet_array_500{0}; - std::array m_my_array_struct; - std::map m_my_map_octet_short; - std::map m_my_map_long_struct; - std::map>> m_my_map_long_seq_octet; - std::map m_my_map_long_octet_array_500; - std::map> m_my_map_long_lol_type; - eprosima::fastcdr::fixed_string<128> m_my_small_string_8; - eprosima::fastcdr::fixed_string<500> m_my_large_string_8; - std::array, 5>, 5> m_my_array_string; - MA3 m_multi_alias_array_42{::A}; - std::array m_my_array_arrays{ {{0}} }; - std::array m_my_sequences_array; - -}; - - -/*! - * @brief This class represents the union MyUnion defined by the user in the IDL file. - * @ingroup Test - */ -class MyUnion -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MyUnion(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MyUnion(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MyUnion that will be copied. - */ - eProsima_user_DllExport MyUnion( - const MyUnion& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MyUnion that will be copied. - */ - eProsima_user_DllExport MyUnion( - MyUnion&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MyUnion that will be copied. - */ - eProsima_user_DllExport MyUnion& operator =( - const MyUnion& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MyUnion that will be copied. - */ - eProsima_user_DllExport MyUnion& operator =( - MyUnion&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MyUnion object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MyUnion& x) const; - - /*! - * @brief Comparison operator. - * @param x MyUnion object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MyUnion& x) const; - - /*! - * @brief This function sets the discriminator value. - * @param __d New value for the discriminator. - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the new value doesn't correspond to the selected union member. - */ - eProsima_user_DllExport void _d( - MyEnum __d); - - /*! - * @brief This function returns the value of the discriminator. - * @return Value of the discriminator - */ - eProsima_user_DllExport MyEnum _d() const; - - /*! - * @brief This function returns a reference to the discriminator. - * @return Reference to the discriminator. - */ - eProsima_user_DllExport MyEnum& _d(); - - /*! - * @brief This function copies the value in member basic - * @param _basic New value to be copied in member basic - */ - eProsima_user_DllExport void basic( - const BasicStruct& _basic); - - /*! - * @brief This function moves the value in member basic - * @param _basic New value to be moved in member basic - */ - eProsima_user_DllExport void basic( - BasicStruct&& _basic); - - /*! - * @brief This function returns a constant reference to member basic - * @return Constant reference to member basic - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport const BasicStruct& basic() const; - - /*! - * @brief This function returns a reference to member basic - * @return Reference to member basic - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport BasicStruct& basic(); - - - /*! - * @brief This function copies the value in member complex - * @param _complex New value to be copied in member complex - */ - eProsima_user_DllExport void complex( - const ComplexStruct& _complex); - - /*! - * @brief This function moves the value in member complex - * @param _complex New value to be moved in member complex - */ - eProsima_user_DllExport void complex( - ComplexStruct&& _complex); - - /*! - * @brief This function returns a constant reference to member complex - * @return Constant reference to member complex - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport const ComplexStruct& complex() const; - - /*! - * @brief This function returns a reference to member complex - * @return Reference to member complex - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport ComplexStruct& complex(); - -private: - - MyEnum m__d; - - BasicStruct m_basic; - ComplexStruct m_complex; -}; - - -/*! - * @brief This class represents the union MyUnion2 defined by the user in the IDL file. - * @ingroup Test - */ -class MyUnion2 -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MyUnion2(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MyUnion2(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MyUnion2 that will be copied. - */ - eProsima_user_DllExport MyUnion2( - const MyUnion2& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MyUnion2 that will be copied. - */ - eProsima_user_DllExport MyUnion2( - MyUnion2&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MyUnion2 that will be copied. - */ - eProsima_user_DllExport MyUnion2& operator =( - const MyUnion2& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MyUnion2 that will be copied. - */ - eProsima_user_DllExport MyUnion2& operator =( - MyUnion2&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MyUnion2 object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MyUnion2& x) const; - - /*! - * @brief Comparison operator. - * @param x MyUnion2 object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MyUnion2& x) const; - - /*! - * @brief This function sets the discriminator value. - * @param __d New value for the discriminator. - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the new value doesn't correspond to the selected union member. - */ - eProsima_user_DllExport void _d( - uint8_t __d); - - /*! - * @brief This function returns the value of the discriminator. - * @return Value of the discriminator - */ - eProsima_user_DllExport uint8_t _d() const; - - /*! - * @brief This function returns a reference to the discriminator. - * @return Reference to the discriminator. - */ - eProsima_user_DllExport uint8_t& _d(); - - /*! - * @brief This function sets a value in member uno - * @param _uno New value for member uno - */ - eProsima_user_DllExport void uno( - int32_t _uno); - - /*! - * @brief This function returns the value of member uno - * @return Value of member uno - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t uno() const; - - /*! - * @brief This function returns a reference to member uno - * @return Reference to member uno - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t& uno(); - - - /*! - * @brief This function copies the value in member imString - * @param _imString New value to be copied in member imString - */ - eProsima_user_DllExport void imString( - const std::string& _imString); - - /*! - * @brief This function moves the value in member imString - * @param _imString New value to be moved in member imString - */ - eProsima_user_DllExport void imString( - std::string&& _imString); - - /*! - * @brief This function returns a constant reference to member imString - * @return Constant reference to member imString - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport const std::string& imString() const; - - /*! - * @brief This function returns a reference to member imString - * @return Reference to member imString - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport std::string& imString(); - - - /*! - * @brief This function sets a value in member tres - * @param _tres New value for member tres - */ - eProsima_user_DllExport void tres( - int32_t _tres); - - /*! - * @brief This function returns the value of member tres - * @return Value of member tres - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t tres() const; - - /*! - * @brief This function returns a reference to member tres - * @return Reference to member tres - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t& tres(); - -private: - - uint8_t m__d; - - int32_t m_uno{0}; - std::string m_imString; - int32_t m_tres{0}; -}; - - -/*! - * @brief This class represents the structure CompleteStruct defined by the user in the IDL file. - * @ingroup Test - */ -class CompleteStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport CompleteStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~CompleteStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object CompleteStruct that will be copied. - */ - eProsima_user_DllExport CompleteStruct( - const CompleteStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object CompleteStruct that will be copied. - */ - eProsima_user_DllExport CompleteStruct( - CompleteStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object CompleteStruct that will be copied. - */ - eProsima_user_DllExport CompleteStruct& operator =( - const CompleteStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object CompleteStruct that will be copied. - */ - eProsima_user_DllExport CompleteStruct& operator =( - CompleteStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x CompleteStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const CompleteStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x CompleteStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const CompleteStruct& x) const; - - /*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ - eProsima_user_DllExport void my_union( - const MyUnion& _my_union); - - /*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ - eProsima_user_DllExport void my_union( - MyUnion&& _my_union); - - /*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ - eProsima_user_DllExport const MyUnion& my_union() const; - - /*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ - eProsima_user_DllExport MyUnion& my_union(); - - - /*! - * @brief This function copies the value in member my_union_2 - * @param _my_union_2 New value to be copied in member my_union_2 - */ - eProsima_user_DllExport void my_union_2( - const MyUnion2& _my_union_2); - - /*! - * @brief This function moves the value in member my_union_2 - * @param _my_union_2 New value to be moved in member my_union_2 - */ - eProsima_user_DllExport void my_union_2( - MyUnion2&& _my_union_2); - - /*! - * @brief This function returns a constant reference to member my_union_2 - * @return Constant reference to member my_union_2 - */ - eProsima_user_DllExport const MyUnion2& my_union_2() const; - - /*! - * @brief This function returns a reference to member my_union_2 - * @return Reference to member my_union_2 - */ - eProsima_user_DllExport MyUnion2& my_union_2(); - -private: - - MyUnion m_my_union; - MyUnion2 m_my_union_2; - -}; - - -/*! - * @brief This class represents the structure KeyedStruct defined by the user in the IDL file. - * @ingroup Test - */ -class KeyedStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport KeyedStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~KeyedStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object KeyedStruct that will be copied. - */ - eProsima_user_DllExport KeyedStruct( - const KeyedStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object KeyedStruct that will be copied. - */ - eProsima_user_DllExport KeyedStruct( - KeyedStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object KeyedStruct that will be copied. - */ - eProsima_user_DllExport KeyedStruct& operator =( - const KeyedStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object KeyedStruct that will be copied. - */ - eProsima_user_DllExport KeyedStruct& operator =( - KeyedStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x KeyedStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const KeyedStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x KeyedStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const KeyedStruct& x) const; - - /*! - * @brief This function sets a value in member key - * @param _key New value for member key - */ - eProsima_user_DllExport void key( - uint8_t _key); - - /*! - * @brief This function returns the value of member key - * @return Value of member key - */ - eProsima_user_DllExport uint8_t key() const; - - /*! - * @brief This function returns a reference to member key - * @return Reference to member key - */ - eProsima_user_DllExport uint8_t& key(); - - - /*! - * @brief This function copies the value in member basic - * @param _basic New value to be copied in member basic - */ - eProsima_user_DllExport void basic( - const BasicStruct& _basic); - - /*! - * @brief This function moves the value in member basic - * @param _basic New value to be moved in member basic - */ - eProsima_user_DllExport void basic( - BasicStruct&& _basic); - - /*! - * @brief This function returns a constant reference to member basic - * @return Constant reference to member basic - */ - eProsima_user_DllExport const BasicStruct& basic() const; - - /*! - * @brief This function returns a reference to member basic - * @return Reference to member basic - */ - eProsima_user_DllExport BasicStruct& basic(); - -private: - - uint8_t m_key{0}; - BasicStruct m_basic; - -}; - -#endif // _FAST_DDS_GENERATED_TEST_H_ - - - -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/test/unittest/dynamic_types/idl/Test.idl b/test/unittest/dynamic_types/idl/Test.idl deleted file mode 100644 index 8da8bd7cc2a..00000000000 --- a/test/unittest/dynamic_types/idl/Test.idl +++ /dev/null @@ -1,93 +0,0 @@ - -enum MyEnum -{ - A, - B, - C -}; - -typedef MyEnum MyAliasEnum; -typedef MyAliasEnum MyAliasEnum2; -typedef MyAliasEnum2 MyAliasEnum3; - -struct BasicStruct -{ - boolean my_bool; - octet my_octet; - short my_int16; - long my_int32; - long long my_int64; - unsigned short my_uint16; - unsigned long my_uint32; - unsigned long long my_uint64; - float my_float32; - double my_float64; - long double my_float128; - char my_char; - //wchar my_wchar; //TODO(richiware) Remove when xtype 1.3. Also in DynamicComplexTypesTests.cpp. - string my_string; - //wstring my_wstring; //TODO(richiware) Remove when xtype 1.3. Also in DynamicComplexTypesTests.cpp. -}; - -typedef octet MyOctetArray500[500]; -typedef BasicStruct BSAlias5[5]; -typedef MyAliasEnum3 MA3[42]; -typedef long MyMiniArray[2]; -typedef sequence MySequenceLong; - -struct ComplexStruct -{ - octet my_octet; - BasicStruct my_basic_struct; - MyAliasEnum my_alias_enum; - MyEnum my_enum; - sequence my_sequence_octet; - sequence my_sequence_struct; - char my_array_octet[500][5][4]; - MyOctetArray500 my_octet_array_500; - BasicStruct my_array_struct[5]; - map my_map_octet_short; - map my_map_long_struct; - map > > my_map_long_seq_octet; - map my_map_long_octet_array_500; - map > my_map_long_lol_type; - string<128> my_small_string_8; - //wstring<64> my_small_string_16; //TODO(richiware) Remove when xtype 1.3 - string<500> my_large_string_8; - //wstring<1024> my_large_string_16; //TODO(richiware) Remove when xtype 1.3 - string<75> my_array_string[5][5]; - MA3 multi_alias_array_42; - MyMiniArray my_array_arrays[5]; - MySequenceLong my_sequences_array[23]; -}; - -union MyUnion switch (MyEnum) -{ - case A: - BasicStruct basic; - case B: - case C: - ComplexStruct complex; -}; - -union MyUnion2 switch (octet) -{ - case A: - long uno; - case B: - string imString; - case C: - long tres; -}; - -struct CompleteStruct -{ - MyUnion my_union; - MyUnion2 my_union_2; -}; - -struct KeyedStruct -{ - @key octet key; - BasicStruct basic; -}; diff --git a/test/unittest/dynamic_types/idl/TestCdrAux.hpp b/test/unittest/dynamic_types/idl/TestCdrAux.hpp deleted file mode 100644 index 785beb525b0..00000000000 --- a/test/unittest/dynamic_types/idl/TestCdrAux.hpp +++ /dev/null @@ -1,112 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file TestCdrAux.hpp - * This source file contains some definitions of CDR related functions. - * - * This file was generated by the tool fastddsgen. - */ - -#ifndef _FAST_DDS_GENERATED_TESTCDRAUX_HPP_ -#define _FAST_DDS_GENERATED_TESTCDRAUX_HPP_ - -#include "Test.h" - -constexpr uint32_t KeyedStruct_max_cdr_typesize {344UL}; -constexpr uint32_t KeyedStruct_max_key_cdr_typesize {1UL}; - - - - -constexpr uint32_t BasicStruct_max_cdr_typesize {336UL}; -constexpr uint32_t BasicStruct_max_key_cdr_typesize {0UL}; - - -constexpr uint32_t ComplexStruct_max_cdr_typesize {18064796UL}; -constexpr uint32_t ComplexStruct_max_key_cdr_typesize {0UL}; - - - -constexpr uint32_t CompleteStruct_max_cdr_typesize {18065072UL}; -constexpr uint32_t CompleteStruct_max_key_cdr_typesize {0UL}; - - - - - - - -namespace eprosima { -namespace fastcdr { - -class Cdr; -class CdrSizeCalculator; - - - - - - - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const BasicStruct& data); - - - - - - - - - - - - - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const ComplexStruct& data); - - - - - - - - - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const CompleteStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const KeyedStruct& data); - - -} // namespace fastcdr -} // namespace eprosima - -#endif // _FAST_DDS_GENERATED_TESTCDRAUX_HPP_ - diff --git a/test/unittest/dynamic_types/idl/TestCdrAux.ipp b/test/unittest/dynamic_types/idl/TestCdrAux.ipp deleted file mode 100644 index f6f905aa6ca..00000000000 --- a/test/unittest/dynamic_types/idl/TestCdrAux.ipp +++ /dev/null @@ -1,873 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file TestCdrAux.ipp - * This source file contains some declarations of CDR related functions. - * - * This file was generated by the tool fastddsgen. - */ - -#ifndef _FAST_DDS_GENERATED_TESTCDRAUX_IPP_ -#define _FAST_DDS_GENERATED_TESTCDRAUX_IPP_ - -#include "TestCdrAux.hpp" - -#include -#include - - -#include -using namespace eprosima::fastcdr::exception; - -namespace eprosima { -namespace fastcdr { - - - - - - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const BasicStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_bool(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(1), - data.my_octet(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(2), - data.my_int16(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(3), - data.my_int32(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(4), - data.my_int64(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(5), - data.my_uint16(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(6), - data.my_uint32(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(7), - data.my_uint64(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(8), - data.my_float32(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(9), - data.my_float64(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(10), - data.my_float128(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(11), - data.my_char(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(12), - data.my_string(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const BasicStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_bool() - << eprosima::fastcdr::MemberId(1) << data.my_octet() - << eprosima::fastcdr::MemberId(2) << data.my_int16() - << eprosima::fastcdr::MemberId(3) << data.my_int32() - << eprosima::fastcdr::MemberId(4) << data.my_int64() - << eprosima::fastcdr::MemberId(5) << data.my_uint16() - << eprosima::fastcdr::MemberId(6) << data.my_uint32() - << eprosima::fastcdr::MemberId(7) << data.my_uint64() - << eprosima::fastcdr::MemberId(8) << data.my_float32() - << eprosima::fastcdr::MemberId(9) << data.my_float64() - << eprosima::fastcdr::MemberId(10) << data.my_float128() - << eprosima::fastcdr::MemberId(11) << data.my_char() - << eprosima::fastcdr::MemberId(12) << data.my_string() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - BasicStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_bool(); - break; - - case 1: - dcdr >> data.my_octet(); - break; - - case 2: - dcdr >> data.my_int16(); - break; - - case 3: - dcdr >> data.my_int32(); - break; - - case 4: - dcdr >> data.my_int64(); - break; - - case 5: - dcdr >> data.my_uint16(); - break; - - case 6: - dcdr >> data.my_uint32(); - break; - - case 7: - dcdr >> data.my_uint64(); - break; - - case 8: - dcdr >> data.my_float32(); - break; - - case 9: - dcdr >> data.my_float64(); - break; - - case 10: - dcdr >> data.my_float128(); - break; - - case 11: - dcdr >> data.my_char(); - break; - - case 12: - dcdr >> data.my_string(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const BasicStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - - - - - - - - - - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const ComplexStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_octet(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(1), - data.my_basic_struct(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(2), - data.my_alias_enum(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(3), - data.my_enum(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(4), - data.my_sequence_octet(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(5), - data.my_sequence_struct(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(6), - data.my_array_octet(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(7), - data.my_octet_array_500(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(8), - data.my_array_struct(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(9), - data.my_map_octet_short(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(10), - data.my_map_long_struct(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(11), - data.my_map_long_seq_octet(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(12), - data.my_map_long_octet_array_500(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(13), - data.my_map_long_lol_type(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(14), - data.my_small_string_8(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(15), - data.my_large_string_8(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(16), - data.my_array_string(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(17), - data.multi_alias_array_42(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(18), - data.my_array_arrays(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(19), - data.my_sequences_array(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const ComplexStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_octet() - << eprosima::fastcdr::MemberId(1) << data.my_basic_struct() - << eprosima::fastcdr::MemberId(2) << data.my_alias_enum() - << eprosima::fastcdr::MemberId(3) << data.my_enum() - << eprosima::fastcdr::MemberId(4) << data.my_sequence_octet() - << eprosima::fastcdr::MemberId(5) << data.my_sequence_struct() - << eprosima::fastcdr::MemberId(6) << data.my_array_octet() - << eprosima::fastcdr::MemberId(7) << data.my_octet_array_500() - << eprosima::fastcdr::MemberId(8) << data.my_array_struct() - << eprosima::fastcdr::MemberId(9) << data.my_map_octet_short() - << eprosima::fastcdr::MemberId(10) << data.my_map_long_struct() - << eprosima::fastcdr::MemberId(11) << data.my_map_long_seq_octet() - << eprosima::fastcdr::MemberId(12) << data.my_map_long_octet_array_500() - << eprosima::fastcdr::MemberId(13) << data.my_map_long_lol_type() - << eprosima::fastcdr::MemberId(14) << data.my_small_string_8() - << eprosima::fastcdr::MemberId(15) << data.my_large_string_8() - << eprosima::fastcdr::MemberId(16) << data.my_array_string() - << eprosima::fastcdr::MemberId(17) << data.multi_alias_array_42() - << eprosima::fastcdr::MemberId(18) << data.my_array_arrays() - << eprosima::fastcdr::MemberId(19) << data.my_sequences_array() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - ComplexStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_octet(); - break; - - case 1: - dcdr >> data.my_basic_struct(); - break; - - case 2: - dcdr >> data.my_alias_enum(); - break; - - case 3: - dcdr >> data.my_enum(); - break; - - case 4: - dcdr >> data.my_sequence_octet(); - break; - - case 5: - dcdr >> data.my_sequence_struct(); - break; - - case 6: - dcdr >> data.my_array_octet(); - break; - - case 7: - dcdr >> data.my_octet_array_500(); - break; - - case 8: - dcdr >> data.my_array_struct(); - break; - - case 9: - dcdr >> data.my_map_octet_short(); - break; - - case 10: - dcdr >> data.my_map_long_struct(); - break; - - case 11: - dcdr >> data.my_map_long_seq_octet(); - break; - - case 12: - dcdr >> data.my_map_long_octet_array_500(); - break; - - case 13: - dcdr >> data.my_map_long_lol_type(); - break; - - case 14: - dcdr >> data.my_small_string_8(); - break; - - case 15: - dcdr >> data.my_large_string_8(); - break; - - case 16: - dcdr >> data.my_array_string(); - break; - - case 17: - dcdr >> data.multi_alias_array_42(); - break; - - case 18: - dcdr >> data.my_array_arrays(); - break; - - case 19: - dcdr >> data.my_sequences_array(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const ComplexStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const MyUnion& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), data._d(), - current_alignment); - - switch (data._d()) - { - case ::A: - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(1), - data.basic(), current_alignment); - break; - - case ::B: - case ::C: - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(2), - data.complex(), current_alignment); - break; - - default: - break; - } - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const MyUnion& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr << eprosima::fastcdr::MemberId(0) << data._d(); - - switch (data._d()) - { - case ::A: - scdr << eprosima::fastcdr::MemberId(1) << data.basic(); - break; - - case ::B: - case ::C: - scdr << eprosima::fastcdr::MemberId(2) << data.complex(); - break; - - default: - break; - } - - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - MyUnion& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data._d(); - break; - default: - switch (data._d()) - { - case ::A: - dcdr >> data.basic(); - break; - - case ::B: - case ::C: - dcdr >> data.complex(); - break; - - default: - break; - } - ret_value = false; - break; - } - return ret_value; - }); -} - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const MyUnion2& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), data._d(), - current_alignment); - - switch (data._d()) - { - case A: - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(1), - data.uno(), current_alignment); - break; - - case B: - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(2), - data.imString(), current_alignment); - break; - - case C: - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(3), - data.tres(), current_alignment); - break; - - default: - break; - } - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const MyUnion2& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr << eprosima::fastcdr::MemberId(0) << data._d(); - - switch (data._d()) - { - case A: - scdr << eprosima::fastcdr::MemberId(1) << data.uno(); - break; - - case B: - scdr << eprosima::fastcdr::MemberId(2) << data.imString(); - break; - - case C: - scdr << eprosima::fastcdr::MemberId(3) << data.tres(); - break; - - default: - break; - } - - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - MyUnion2& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data._d(); - break; - default: - switch (data._d()) - { - case A: - dcdr >> data.uno(); - break; - - case B: - dcdr >> data.imString(); - break; - - case C: - dcdr >> data.tres(); - break; - - default: - break; - } - ret_value = false; - break; - } - return ret_value; - }); -} - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const CompleteStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_union(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(1), - data.my_union_2(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const CompleteStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_union() - << eprosima::fastcdr::MemberId(1) << data.my_union_2() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - CompleteStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_union(); - break; - - case 1: - dcdr >> data.my_union_2(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const CompleteStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const KeyedStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.key(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(1), - data.basic(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const KeyedStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.key() - << eprosima::fastcdr::MemberId(1) << data.basic() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - KeyedStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.key(); - break; - - case 1: - dcdr >> data.basic(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const KeyedStruct& data) -{ - static_cast(scdr); - static_cast(data); - scdr << data.key(); - - -} - - - -} // namespace fastcdr -} // namespace eprosima - -#endif // _FAST_DDS_GENERATED_TESTCDRAUX_IPP_ - diff --git a/test/unittest/dynamic_types/idl/TestPubSubTypes.cxx b/test/unittest/dynamic_types/idl/TestPubSubTypes.cxx deleted file mode 100644 index d450d6de064..00000000000 --- a/test/unittest/dynamic_types/idl/TestPubSubTypes.cxx +++ /dev/null @@ -1,817 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file TestPubSubTypes.cpp - * This header file contains the implementation of the serialization functions. - * - * This file was generated by the tool fastddsgen. - */ - - -#include - -#include "TestPubSubTypes.h" -#include "TestCdrAux.hpp" - -using SerializedPayload_t = eprosima::fastrtps::rtps::SerializedPayload_t; -using InstanceHandle_t = eprosima::fastrtps::rtps::InstanceHandle_t; -using DataRepresentationId_t = eprosima::fastdds::dds::DataRepresentationId_t; - - - - - - - - - -BasicStructPubSubType::BasicStructPubSubType() -{ - setName("BasicStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(BasicStruct::getMaxCdrSerializedSize()); -#else - BasicStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = BasicStruct_max_key_cdr_typesize > 16 ? BasicStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -BasicStructPubSubType::~BasicStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool BasicStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - BasicStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool BasicStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - BasicStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function BasicStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* BasicStructPubSubType::createData() -{ - return reinterpret_cast(new BasicStruct()); -} - -void BasicStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool BasicStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - BasicStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - BasicStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || BasicStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - - - - - - - - - - - - - -ComplexStructPubSubType::ComplexStructPubSubType() -{ - setName("ComplexStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(ComplexStruct::getMaxCdrSerializedSize()); -#else - ComplexStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = ComplexStruct_max_key_cdr_typesize > 16 ? ComplexStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -ComplexStructPubSubType::~ComplexStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool ComplexStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - ComplexStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool ComplexStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - ComplexStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function ComplexStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* ComplexStructPubSubType::createData() -{ - return reinterpret_cast(new ComplexStruct()); -} - -void ComplexStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool ComplexStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - ComplexStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - ComplexStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || ComplexStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - - - - - - - - - -CompleteStructPubSubType::CompleteStructPubSubType() -{ - setName("CompleteStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(CompleteStruct::getMaxCdrSerializedSize()); -#else - CompleteStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = CompleteStruct_max_key_cdr_typesize > 16 ? CompleteStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -CompleteStructPubSubType::~CompleteStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool CompleteStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - CompleteStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool CompleteStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - CompleteStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function CompleteStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* CompleteStructPubSubType::createData() -{ - return reinterpret_cast(new CompleteStruct()); -} - -void CompleteStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool CompleteStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - CompleteStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - CompleteStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || CompleteStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -KeyedStructPubSubType::KeyedStructPubSubType() -{ - setName("KeyedStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(KeyedStruct::getMaxCdrSerializedSize()); -#else - KeyedStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = true; - uint32_t keyLength = KeyedStruct_max_key_cdr_typesize > 16 ? KeyedStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -KeyedStructPubSubType::~KeyedStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool KeyedStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - KeyedStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool KeyedStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - KeyedStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function KeyedStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* KeyedStructPubSubType::createData() -{ - return reinterpret_cast(new KeyedStruct()); -} - -void KeyedStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool KeyedStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - KeyedStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - KeyedStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || KeyedStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - diff --git a/test/unittest/dynamic_types/idl/TestPubSubTypes.h b/test/unittest/dynamic_types/idl/TestPubSubTypes.h deleted file mode 100644 index d74f7ae2664..00000000000 --- a/test/unittest/dynamic_types/idl/TestPubSubTypes.h +++ /dev/null @@ -1,420 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file TestPubSubTypes.h - * This header file contains the declaration of the serialization functions. - * - * This file was generated by the tool fastddsgen. - */ - - -#ifndef _FAST_DDS_GENERATED_TEST_PUBSUBTYPES_H_ -#define _FAST_DDS_GENERATED_TEST_PUBSUBTYPES_H_ - -#include -#include -#include -#include -#include - -#include "Test.h" - - -#if !defined(GEN_API_VER) || (GEN_API_VER != 2) -#error \ - Generated Test is not compatible with current installed Fast DDS. Please, regenerate it with fastddsgen. -#endif // GEN_API_VER - -typedef MyEnum MyAliasEnum; -typedef MyAliasEnum MyAliasEnum2; -typedef MyAliasEnum2 MyAliasEnum3; - - - -/*! - * @brief This class represents the TopicDataType of the type BasicStruct defined by the user in the IDL file. - * @ingroup Test - */ -class BasicStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef BasicStruct type; - - eProsima_user_DllExport BasicStructPubSubType(); - - eProsima_user_DllExport ~BasicStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; -typedef std::array MyOctetArray500; -typedef std::array BSAlias5; -typedef std::array MA3; -typedef std::array MyMiniArray; - - -typedef std::vector MySequenceLong; - - - -/*! - * @brief This class represents the TopicDataType of the type ComplexStruct defined by the user in the IDL file. - * @ingroup Test - */ -class ComplexStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef ComplexStruct type; - - eProsima_user_DllExport ComplexStructPubSubType(); - - eProsima_user_DllExport ~ComplexStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - - - - - - - - - -/*! - * @brief This class represents the TopicDataType of the type CompleteStruct defined by the user in the IDL file. - * @ingroup Test - */ -class CompleteStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef CompleteStruct type; - - eProsima_user_DllExport CompleteStructPubSubType(); - - eProsima_user_DllExport ~CompleteStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type KeyedStruct defined by the user in the IDL file. - * @ingroup Test - */ -class KeyedStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef KeyedStruct type; - - eProsima_user_DllExport KeyedStructPubSubType(); - - eProsima_user_DllExport ~KeyedStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - -#endif // _FAST_DDS_GENERATED_TEST_PUBSUBTYPES_H_ - diff --git a/test/unittest/dynamic_types/idl/TestTypeObject.cxx b/test/unittest/dynamic_types/idl/TestTypeObject.cxx deleted file mode 100644 index 60d8dba0b18..00000000000 --- a/test/unittest/dynamic_types/idl/TestTypeObject.cxx +++ /dev/null @@ -1,4306 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file TestTypeObject.cpp - * This source file contains the definition of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { char dummy; } -#endif - -#include "Test.h" -#include "TestTypeObject.h" -#include -#include -#include -#include -#include -#include -#include -#include -#include - -using namespace eprosima::fastrtps::rtps; - -void registerTestTypes() -{ - static std::once_flag once_flag; - std::call_once(once_flag, []() - { - TypeObjectFactory *factory = TypeObjectFactory::get_instance(); - factory->add_type_object("MyEnum", GetMyEnumIdentifier(true), - GetMyEnumObject(true)); - factory->add_type_object("MyEnum", GetMyEnumIdentifier(false), - GetMyEnumObject(false)); - - - factory->add_type_object("MyAliasEnum", GetMyAliasEnumIdentifier(true), - GetMyAliasEnumObject(true)); - factory->add_type_object("MyAliasEnum", GetMyAliasEnumIdentifier(false), - GetMyAliasEnumObject(false)); - - - factory->add_type_object("MyAliasEnum2", GetMyAliasEnum2Identifier(true), - GetMyAliasEnum2Object(true)); - factory->add_type_object("MyAliasEnum2", GetMyAliasEnum2Identifier(false), - GetMyAliasEnum2Object(false)); - - - factory->add_type_object("MyAliasEnum3", GetMyAliasEnum3Identifier(true), - GetMyAliasEnum3Object(true)); - factory->add_type_object("MyAliasEnum3", GetMyAliasEnum3Identifier(false), - GetMyAliasEnum3Object(false)); - - - factory->add_type_object("BasicStruct", GetBasicStructIdentifier(true), - GetBasicStructObject(true)); - factory->add_type_object("BasicStruct", GetBasicStructIdentifier(false), - GetBasicStructObject(false)); - - - factory->add_type_object("MyOctetArray500", GetMyOctetArray500Identifier(true), - GetMyOctetArray500Object(true)); - factory->add_type_object("MyOctetArray500", GetMyOctetArray500Identifier(false), - GetMyOctetArray500Object(false)); - - - factory->add_type_object("BSAlias5", GetBSAlias5Identifier(true), - GetBSAlias5Object(true)); - factory->add_type_object("BSAlias5", GetBSAlias5Identifier(false), - GetBSAlias5Object(false)); - - - factory->add_type_object("MA3", GetMA3Identifier(true), - GetMA3Object(true)); - factory->add_type_object("MA3", GetMA3Identifier(false), - GetMA3Object(false)); - - - factory->add_type_object("MyMiniArray", GetMyMiniArrayIdentifier(true), - GetMyMiniArrayObject(true)); - factory->add_type_object("MyMiniArray", GetMyMiniArrayIdentifier(false), - GetMyMiniArrayObject(false)); - - - factory->add_type_object("MySequenceLong", GetMySequenceLongIdentifier(true), - GetMySequenceLongObject(true)); - factory->add_type_object("MySequenceLong", GetMySequenceLongIdentifier(false), - GetMySequenceLongObject(false)); - - - factory->add_type_object("ComplexStruct", GetComplexStructIdentifier(true), - GetComplexStructObject(true)); - factory->add_type_object("ComplexStruct", GetComplexStructIdentifier(false), - GetComplexStructObject(false)); - - - factory->add_type_object("MyUnion", GetMyUnionIdentifier(true), - GetMyUnionObject(true)); - factory->add_type_object("MyUnion", GetMyUnionIdentifier(false), - GetMyUnionObject(false)); - - - factory->add_type_object("MyUnion2", GetMyUnion2Identifier(true), - GetMyUnion2Object(true)); - factory->add_type_object("MyUnion2", GetMyUnion2Identifier(false), - GetMyUnion2Object(false)); - - - factory->add_type_object("CompleteStruct", GetCompleteStructIdentifier(true), - GetCompleteStructObject(true)); - factory->add_type_object("CompleteStruct", GetCompleteStructIdentifier(false), - GetCompleteStructObject(false)); - - - factory->add_type_object("KeyedStruct", GetKeyedStructIdentifier(true), - GetKeyedStructObject(true)); - factory->add_type_object("KeyedStruct", GetKeyedStructIdentifier(false), - GetKeyedStructObject(false)); - - }); -} - -const TypeIdentifier* GetMyEnumIdentifier(bool complete) -{ - const TypeIdentifier* c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("MyEnum", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetMyEnumObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("MyEnum", complete); -} - -const TypeObject* GetMyEnumObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyEnum", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteMyEnumObject(); - } - // else - return GetMinimalMyEnumObject(); -} - -const TypeObject* GetMinimalMyEnumObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyEnum", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_ENUM); - - // No flags apply - //type_object->minimal().enumerated_type().enum_flags().IS_FINAL(false); - //type_object->minimal().enumerated_type().enum_flags().IS_APPENDABLE(false); - //type_object->minimal().enumerated_type().enum_flags().IS_MUTABLE(false); - //type_object->minimal().enumerated_type().enum_flags().IS_NESTED(false); - //type_object->minimal().enumerated_type().enum_flags().IS_AUTOID_HASH(false); - - type_object->minimal().enumerated_type().header().common().bit_bound(32); // TODO fixed by IDL, isn't? - - uint32_t value = 0; - MinimalEnumeratedLiteral mel_A; - mel_A.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - mel_A.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - mel_A.common().flags().IS_EXTERNAL(false); // Doesn't apply - mel_A.common().flags().IS_OPTIONAL(false); // Doesn't apply - mel_A.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mel_A.common().flags().IS_KEY(false); // Doesn't apply - mel_A.common().flags().IS_DEFAULT(false); - mel_A.common().value(value++); - MD5 A_hash("A"); - for(int i = 0; i < 4; ++i) - { - mel_A.detail().name_hash()[i] = A_hash.digest[i]; - } - type_object->minimal().enumerated_type().literal_seq().emplace_back(mel_A); - - MinimalEnumeratedLiteral mel_B; - mel_B.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - mel_B.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - mel_B.common().flags().IS_EXTERNAL(false); // Doesn't apply - mel_B.common().flags().IS_OPTIONAL(false); // Doesn't apply - mel_B.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mel_B.common().flags().IS_KEY(false); // Doesn't apply - mel_B.common().flags().IS_DEFAULT(false); - mel_B.common().value(value++); - MD5 B_hash("B"); - for(int i = 0; i < 4; ++i) - { - mel_B.detail().name_hash()[i] = B_hash.digest[i]; - } - type_object->minimal().enumerated_type().literal_seq().emplace_back(mel_B); - - MinimalEnumeratedLiteral mel_C; - mel_C.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - mel_C.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - mel_C.common().flags().IS_EXTERNAL(false); // Doesn't apply - mel_C.common().flags().IS_OPTIONAL(false); // Doesn't apply - mel_C.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mel_C.common().flags().IS_KEY(false); // Doesn't apply - mel_C.common().flags().IS_DEFAULT(false); - mel_C.common().value(value++); - MD5 C_hash("C"); - for(int i = 0; i < 4; ++i) - { - mel_C.detail().name_hash()[i] = C_hash.digest[i]; - } - type_object->minimal().enumerated_type().literal_seq().emplace_back(mel_C); - - - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().enumerated_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MyEnum", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyEnum", false); -} - -const TypeObject* GetCompleteMyEnumObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyEnum", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_ENUM); - - // No flags apply - //type_object->complete().enumerated_type().enum_flags().IS_FINAL(false); - //type_object->complete().enumerated_type().enum_flags().IS_APPENDABLE(false); - //type_object->complete().enumerated_type().enum_flags().IS_MUTABLE(false); - //type_object->complete().enumerated_type().enum_flags().IS_NESTED(false); - //type_object->complete().enumerated_type().enum_flags().IS_AUTOID_HASH(false); - - type_object->complete().enumerated_type().header().common().bit_bound(32); // TODO fixed by IDL, isn't? - type_object->complete().enumerated_type().header().detail().type_name("MyEnum"); - - uint32_t value = 0; - CompleteEnumeratedLiteral cel_A; - cel_A.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - cel_A.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - cel_A.common().flags().IS_EXTERNAL(false); // Doesn't apply - cel_A.common().flags().IS_OPTIONAL(false); // Doesn't apply - cel_A.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cel_A.common().flags().IS_KEY(false); // Doesn't apply - cel_A.common().flags().IS_DEFAULT(false); - cel_A.common().value(value++); - cel_A.detail().name("A"); - - type_object->complete().enumerated_type().literal_seq().emplace_back(cel_A); - - CompleteEnumeratedLiteral cel_B; - cel_B.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - cel_B.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - cel_B.common().flags().IS_EXTERNAL(false); // Doesn't apply - cel_B.common().flags().IS_OPTIONAL(false); // Doesn't apply - cel_B.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cel_B.common().flags().IS_KEY(false); // Doesn't apply - cel_B.common().flags().IS_DEFAULT(false); - cel_B.common().value(value++); - cel_B.detail().name("B"); - - type_object->complete().enumerated_type().literal_seq().emplace_back(cel_B); - - CompleteEnumeratedLiteral cel_C; - cel_C.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - cel_C.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - cel_C.common().flags().IS_EXTERNAL(false); // Doesn't apply - cel_C.common().flags().IS_OPTIONAL(false); // Doesn't apply - cel_C.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cel_C.common().flags().IS_KEY(false); // Doesn't apply - cel_C.common().flags().IS_DEFAULT(false); - cel_C.common().value(value++); - cel_C.detail().name("C"); - - type_object->complete().enumerated_type().literal_seq().emplace_back(cel_C); - - - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().enumerated_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MyEnum", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyEnum", true); -} - -const TypeIdentifier* GetMyAliasEnumIdentifier(bool complete) -{ - const TypeIdentifier* c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("MyAliasEnum", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetMyAliasEnumObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("MyAliasEnum", complete); -} - -const TypeObject* GetMyAliasEnumObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyAliasEnum", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteMyAliasEnumObject(); - } - else - { - return GetMinimalMyAliasEnumObject(); - } -} - -const TypeObject* GetMinimalMyAliasEnumObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyAliasEnum", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_ALIAS); - - // No flags apply - //type_object->minimal().alias_type().alias_flags().IS_FINAL(false); - //type_object->minimal().alias_type().alias_flags().IS_APPENDABLE(false); - //type_object->minimal().alias_type().alias_flags().IS_MUTABLE(false); - //type_object->minimal().alias_type().alias_flags().IS_NESTED(false); - //type_object->minimal().alias_type().alias_flags().IS_AUTOID_HASH(false); - - // type_object->minimal().alias_type().header()... Is empty - - // No flags apply - //type_object->minimal().alias_type().body().common().related_flags().TRY_CONSTRUCT1(false); - //type_object->minimal().alias_type().body().common().related_flags().TRY_CONSTRUCT2(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_EXTERNAL(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_OPTIONAL(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_MUST_UNDERSTAND(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_KEY(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_DEFAULT(false); - - // Must be defined already, if don't, may be an recursive alias - const TypeIdentifier *relatedType = TypeObjectFactory::get_instance()->get_type_identifier("MyEnum", false); - - - if (relatedType != nullptr) - { - type_object->minimal().alias_type().body().common().related_type() = *relatedType; // Make a copy - } - else - { - // Cannot determine base type - delete type_object; - return nullptr; - } - - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().alias_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - // Don't add our TypeIdentifier but our alias - TypeObjectFactory::get_instance()->add_alias("MyAliasEnum", "MyEnum"); - - TypeObjectFactory::get_instance()->add_type_object("MyAliasEnum", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyAliasEnum", false); -} - -const TypeObject* GetCompleteMyAliasEnumObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyAliasEnum", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_ALIAS); - - // No flags apply - //type_object->complete().alias_type().alias_flags().IS_FINAL(false); - //type_object->complete().alias_type().alias_flags().IS_APPENDABLE(false); - //type_object->complete().alias_type().alias_flags().IS_MUTABLE(false); - //type_object->complete().alias_type().alias_flags().IS_NESTED(false); - //type_object->complete().alias_type().alias_flags().IS_AUTOID_HASH(false); - - //type_object->complete().alias_type().header().detail().ann_builtin().verbatim().placement("placement"); - //type_object->complete().alias_type().header().detail().ann_builtin().verbatim().language("language"); - //type_object->complete().alias_type().header().detail().ann_builtin().verbatim().text("text"); - //type_object->complete().alias_type().header().detail().ann_custom().push_back(...); - type_object->complete().alias_type().header().detail().type_name("MyAliasEnum"); - - // No flags apply - //type_object->complete().alias_type().body().common().related_flags().TRY_CONSTRUCT1(false); - //type_object->complete().alias_type().body().common().related_flags().TRY_CONSTRUCT2(false); - //type_object->complete().alias_type().body().common().related_flags().IS_EXTERNAL(false); - //type_object->complete().alias_type().body().common().related_flags().IS_OPTIONAL(false); - //type_object->complete().alias_type().body().common().related_flags().IS_MUST_UNDERSTAND(false); - //type_object->complete().alias_type().body().common().related_flags().IS_KEY(false); - //type_object->complete().alias_type().body().common().related_flags().IS_DEFAULT(false); - - //type_object->complete().alias_type().body().common().ann_builtin() - //type_object->complete().alias_type().body().common().ann_custom() - - // Must be defined already, if don't, may be an recursive alias - const TypeIdentifier *relatedType = TypeObjectFactory::get_instance()->get_type_identifier_trying_complete("MyEnum"); - - - if (relatedType != nullptr) - { - type_object->complete().alias_type().body().common().related_type() = *relatedType; // Make a copy - } - else - { - // Cannot determine base type - delete type_object; - return nullptr; - } - - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().alias_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - // Don't add our TypeIdentifier but our alias - TypeObjectFactory::get_instance()->add_alias("MyAliasEnum", "MyEnum"); - - TypeObjectFactory::get_instance()->add_type_object("MyAliasEnum", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyAliasEnum", true); -} - -const TypeIdentifier* GetMyAliasEnum2Identifier(bool complete) -{ - const TypeIdentifier* c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("MyAliasEnum2", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetMyAliasEnum2Object(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("MyAliasEnum2", complete); -} - -const TypeObject* GetMyAliasEnum2Object(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyAliasEnum2", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteMyAliasEnum2Object(); - } - else - { - return GetMinimalMyAliasEnum2Object(); - } -} - -const TypeObject* GetMinimalMyAliasEnum2Object() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyAliasEnum2", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_ALIAS); - - // No flags apply - //type_object->minimal().alias_type().alias_flags().IS_FINAL(false); - //type_object->minimal().alias_type().alias_flags().IS_APPENDABLE(false); - //type_object->minimal().alias_type().alias_flags().IS_MUTABLE(false); - //type_object->minimal().alias_type().alias_flags().IS_NESTED(false); - //type_object->minimal().alias_type().alias_flags().IS_AUTOID_HASH(false); - - // type_object->minimal().alias_type().header()... Is empty - - // No flags apply - //type_object->minimal().alias_type().body().common().related_flags().TRY_CONSTRUCT1(false); - //type_object->minimal().alias_type().body().common().related_flags().TRY_CONSTRUCT2(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_EXTERNAL(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_OPTIONAL(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_MUST_UNDERSTAND(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_KEY(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_DEFAULT(false); - - // Must be defined already, if don't, may be an recursive alias - const TypeIdentifier *relatedType = TypeObjectFactory::get_instance()->get_type_identifier("MyAliasEnum", false); - - - if (relatedType != nullptr) - { - type_object->minimal().alias_type().body().common().related_type() = *relatedType; // Make a copy - } - else - { - // Cannot determine base type - delete type_object; - return nullptr; - } - - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().alias_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - // Don't add our TypeIdentifier but our alias - TypeObjectFactory::get_instance()->add_alias("MyAliasEnum2", "MyAliasEnum"); - - TypeObjectFactory::get_instance()->add_type_object("MyAliasEnum2", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyAliasEnum2", false); -} - -const TypeObject* GetCompleteMyAliasEnum2Object() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyAliasEnum2", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_ALIAS); - - // No flags apply - //type_object->complete().alias_type().alias_flags().IS_FINAL(false); - //type_object->complete().alias_type().alias_flags().IS_APPENDABLE(false); - //type_object->complete().alias_type().alias_flags().IS_MUTABLE(false); - //type_object->complete().alias_type().alias_flags().IS_NESTED(false); - //type_object->complete().alias_type().alias_flags().IS_AUTOID_HASH(false); - - //type_object->complete().alias_type().header().detail().ann_builtin().verbatim().placement("placement"); - //type_object->complete().alias_type().header().detail().ann_builtin().verbatim().language("language"); - //type_object->complete().alias_type().header().detail().ann_builtin().verbatim().text("text"); - //type_object->complete().alias_type().header().detail().ann_custom().push_back(...); - type_object->complete().alias_type().header().detail().type_name("MyAliasEnum2"); - - // No flags apply - //type_object->complete().alias_type().body().common().related_flags().TRY_CONSTRUCT1(false); - //type_object->complete().alias_type().body().common().related_flags().TRY_CONSTRUCT2(false); - //type_object->complete().alias_type().body().common().related_flags().IS_EXTERNAL(false); - //type_object->complete().alias_type().body().common().related_flags().IS_OPTIONAL(false); - //type_object->complete().alias_type().body().common().related_flags().IS_MUST_UNDERSTAND(false); - //type_object->complete().alias_type().body().common().related_flags().IS_KEY(false); - //type_object->complete().alias_type().body().common().related_flags().IS_DEFAULT(false); - - //type_object->complete().alias_type().body().common().ann_builtin() - //type_object->complete().alias_type().body().common().ann_custom() - - // Must be defined already, if don't, may be an recursive alias - const TypeIdentifier *relatedType = TypeObjectFactory::get_instance()->get_type_identifier_trying_complete("MyAliasEnum"); - - - if (relatedType != nullptr) - { - type_object->complete().alias_type().body().common().related_type() = *relatedType; // Make a copy - } - else - { - // Cannot determine base type - delete type_object; - return nullptr; - } - - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().alias_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - // Don't add our TypeIdentifier but our alias - TypeObjectFactory::get_instance()->add_alias("MyAliasEnum2", "MyAliasEnum"); - - TypeObjectFactory::get_instance()->add_type_object("MyAliasEnum2", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyAliasEnum2", true); -} - -const TypeIdentifier* GetMyAliasEnum3Identifier(bool complete) -{ - const TypeIdentifier* c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("MyAliasEnum3", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetMyAliasEnum3Object(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("MyAliasEnum3", complete); -} - -const TypeObject* GetMyAliasEnum3Object(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyAliasEnum3", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteMyAliasEnum3Object(); - } - else - { - return GetMinimalMyAliasEnum3Object(); - } -} - -const TypeObject* GetMinimalMyAliasEnum3Object() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyAliasEnum3", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_ALIAS); - - // No flags apply - //type_object->minimal().alias_type().alias_flags().IS_FINAL(false); - //type_object->minimal().alias_type().alias_flags().IS_APPENDABLE(false); - //type_object->minimal().alias_type().alias_flags().IS_MUTABLE(false); - //type_object->minimal().alias_type().alias_flags().IS_NESTED(false); - //type_object->minimal().alias_type().alias_flags().IS_AUTOID_HASH(false); - - // type_object->minimal().alias_type().header()... Is empty - - // No flags apply - //type_object->minimal().alias_type().body().common().related_flags().TRY_CONSTRUCT1(false); - //type_object->minimal().alias_type().body().common().related_flags().TRY_CONSTRUCT2(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_EXTERNAL(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_OPTIONAL(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_MUST_UNDERSTAND(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_KEY(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_DEFAULT(false); - - // Must be defined already, if don't, may be an recursive alias - const TypeIdentifier *relatedType = TypeObjectFactory::get_instance()->get_type_identifier("MyAliasEnum2", false); - - - if (relatedType != nullptr) - { - type_object->minimal().alias_type().body().common().related_type() = *relatedType; // Make a copy - } - else - { - // Cannot determine base type - delete type_object; - return nullptr; - } - - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().alias_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - // Don't add our TypeIdentifier but our alias - TypeObjectFactory::get_instance()->add_alias("MyAliasEnum3", "MyAliasEnum2"); - - TypeObjectFactory::get_instance()->add_type_object("MyAliasEnum3", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyAliasEnum3", false); -} - -const TypeObject* GetCompleteMyAliasEnum3Object() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyAliasEnum3", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_ALIAS); - - // No flags apply - //type_object->complete().alias_type().alias_flags().IS_FINAL(false); - //type_object->complete().alias_type().alias_flags().IS_APPENDABLE(false); - //type_object->complete().alias_type().alias_flags().IS_MUTABLE(false); - //type_object->complete().alias_type().alias_flags().IS_NESTED(false); - //type_object->complete().alias_type().alias_flags().IS_AUTOID_HASH(false); - - //type_object->complete().alias_type().header().detail().ann_builtin().verbatim().placement("placement"); - //type_object->complete().alias_type().header().detail().ann_builtin().verbatim().language("language"); - //type_object->complete().alias_type().header().detail().ann_builtin().verbatim().text("text"); - //type_object->complete().alias_type().header().detail().ann_custom().push_back(...); - type_object->complete().alias_type().header().detail().type_name("MyAliasEnum3"); - - // No flags apply - //type_object->complete().alias_type().body().common().related_flags().TRY_CONSTRUCT1(false); - //type_object->complete().alias_type().body().common().related_flags().TRY_CONSTRUCT2(false); - //type_object->complete().alias_type().body().common().related_flags().IS_EXTERNAL(false); - //type_object->complete().alias_type().body().common().related_flags().IS_OPTIONAL(false); - //type_object->complete().alias_type().body().common().related_flags().IS_MUST_UNDERSTAND(false); - //type_object->complete().alias_type().body().common().related_flags().IS_KEY(false); - //type_object->complete().alias_type().body().common().related_flags().IS_DEFAULT(false); - - //type_object->complete().alias_type().body().common().ann_builtin() - //type_object->complete().alias_type().body().common().ann_custom() - - // Must be defined already, if don't, may be an recursive alias - const TypeIdentifier *relatedType = TypeObjectFactory::get_instance()->get_type_identifier_trying_complete("MyAliasEnum2"); - - - if (relatedType != nullptr) - { - type_object->complete().alias_type().body().common().related_type() = *relatedType; // Make a copy - } - else - { - // Cannot determine base type - delete type_object; - return nullptr; - } - - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().alias_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - // Don't add our TypeIdentifier but our alias - TypeObjectFactory::get_instance()->add_alias("MyAliasEnum3", "MyAliasEnum2"); - - TypeObjectFactory::get_instance()->add_type_object("MyAliasEnum3", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyAliasEnum3", true); -} - - - -const TypeIdentifier* GetBasicStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("BasicStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetBasicStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("BasicStruct", complete); -} - -const TypeObject* GetBasicStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("BasicStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteBasicStructObject(); - } - //else - return GetMinimalBasicStructObject(); -} - -const TypeObject* GetMinimalBasicStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("BasicStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_bool; - mst_my_bool.common().member_id(memberId++); - mst_my_bool.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_bool.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_bool.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_bool.common().member_flags().IS_OPTIONAL(false); - mst_my_bool.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_bool.common().member_flags().IS_KEY(false); - mst_my_bool.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_bool.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("bool", false)); - - - MD5 my_bool_hash("my_bool"); - for(int i = 0; i < 4; ++i) - { - mst_my_bool.detail().name_hash()[i] = my_bool_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_bool); - - MinimalStructMember mst_my_octet; - mst_my_octet.common().member_id(memberId++); - mst_my_octet.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_octet.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_octet.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_octet.common().member_flags().IS_OPTIONAL(false); - mst_my_octet.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_octet.common().member_flags().IS_KEY(false); - mst_my_octet.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_octet.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint8_t", false)); - - - MD5 my_octet_hash("my_octet"); - for(int i = 0; i < 4; ++i) - { - mst_my_octet.detail().name_hash()[i] = my_octet_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_octet); - - MinimalStructMember mst_my_int16; - mst_my_int16.common().member_id(memberId++); - mst_my_int16.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_int16.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_int16.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_int16.common().member_flags().IS_OPTIONAL(false); - mst_my_int16.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_int16.common().member_flags().IS_KEY(false); - mst_my_int16.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_int16.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int16_t", false)); - - - MD5 my_int16_hash("my_int16"); - for(int i = 0; i < 4; ++i) - { - mst_my_int16.detail().name_hash()[i] = my_int16_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_int16); - - MinimalStructMember mst_my_int32; - mst_my_int32.common().member_id(memberId++); - mst_my_int32.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_int32.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_int32.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_int32.common().member_flags().IS_OPTIONAL(false); - mst_my_int32.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_int32.common().member_flags().IS_KEY(false); - mst_my_int32.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_int32.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - MD5 my_int32_hash("my_int32"); - for(int i = 0; i < 4; ++i) - { - mst_my_int32.detail().name_hash()[i] = my_int32_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_int32); - - MinimalStructMember mst_my_int64; - mst_my_int64.common().member_id(memberId++); - mst_my_int64.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_int64.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_int64.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_int64.common().member_flags().IS_OPTIONAL(false); - mst_my_int64.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_int64.common().member_flags().IS_KEY(false); - mst_my_int64.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_int64.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int64_t", false)); - - - MD5 my_int64_hash("my_int64"); - for(int i = 0; i < 4; ++i) - { - mst_my_int64.detail().name_hash()[i] = my_int64_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_int64); - - MinimalStructMember mst_my_uint16; - mst_my_uint16.common().member_id(memberId++); - mst_my_uint16.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_uint16.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_uint16.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_uint16.common().member_flags().IS_OPTIONAL(false); - mst_my_uint16.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_uint16.common().member_flags().IS_KEY(false); - mst_my_uint16.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_uint16.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint16_t", false)); - - - MD5 my_uint16_hash("my_uint16"); - for(int i = 0; i < 4; ++i) - { - mst_my_uint16.detail().name_hash()[i] = my_uint16_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_uint16); - - MinimalStructMember mst_my_uint32; - mst_my_uint32.common().member_id(memberId++); - mst_my_uint32.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_uint32.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_uint32.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_uint32.common().member_flags().IS_OPTIONAL(false); - mst_my_uint32.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_uint32.common().member_flags().IS_KEY(false); - mst_my_uint32.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_uint32.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint32_t", false)); - - - MD5 my_uint32_hash("my_uint32"); - for(int i = 0; i < 4; ++i) - { - mst_my_uint32.detail().name_hash()[i] = my_uint32_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_uint32); - - MinimalStructMember mst_my_uint64; - mst_my_uint64.common().member_id(memberId++); - mst_my_uint64.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_uint64.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_uint64.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_uint64.common().member_flags().IS_OPTIONAL(false); - mst_my_uint64.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_uint64.common().member_flags().IS_KEY(false); - mst_my_uint64.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_uint64.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint64_t", false)); - - - MD5 my_uint64_hash("my_uint64"); - for(int i = 0; i < 4; ++i) - { - mst_my_uint64.detail().name_hash()[i] = my_uint64_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_uint64); - - MinimalStructMember mst_my_float32; - mst_my_float32.common().member_id(memberId++); - mst_my_float32.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_float32.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_float32.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_float32.common().member_flags().IS_OPTIONAL(false); - mst_my_float32.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_float32.common().member_flags().IS_KEY(false); - mst_my_float32.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_float32.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("float", false)); - - - MD5 my_float32_hash("my_float32"); - for(int i = 0; i < 4; ++i) - { - mst_my_float32.detail().name_hash()[i] = my_float32_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_float32); - - MinimalStructMember mst_my_float64; - mst_my_float64.common().member_id(memberId++); - mst_my_float64.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_float64.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_float64.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_float64.common().member_flags().IS_OPTIONAL(false); - mst_my_float64.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_float64.common().member_flags().IS_KEY(false); - mst_my_float64.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_float64.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("double", false)); - - - MD5 my_float64_hash("my_float64"); - for(int i = 0; i < 4; ++i) - { - mst_my_float64.detail().name_hash()[i] = my_float64_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_float64); - - MinimalStructMember mst_my_float128; - mst_my_float128.common().member_id(memberId++); - mst_my_float128.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_float128.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_float128.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_float128.common().member_flags().IS_OPTIONAL(false); - mst_my_float128.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_float128.common().member_flags().IS_KEY(false); - mst_my_float128.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_float128.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("longdouble", false)); - - - MD5 my_float128_hash("my_float128"); - for(int i = 0; i < 4; ++i) - { - mst_my_float128.detail().name_hash()[i] = my_float128_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_float128); - - MinimalStructMember mst_my_char; - mst_my_char.common().member_id(memberId++); - mst_my_char.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_char.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_char.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_char.common().member_flags().IS_OPTIONAL(false); - mst_my_char.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_char.common().member_flags().IS_KEY(false); - mst_my_char.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_char.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("char", false)); - - - MD5 my_char_hash("my_char"); - for(int i = 0; i < 4; ++i) - { - mst_my_char.detail().name_hash()[i] = my_char_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_char); - - MinimalStructMember mst_my_string; - mst_my_string.common().member_id(memberId++); - mst_my_string.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_string.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_string.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_string.common().member_flags().IS_OPTIONAL(false); - mst_my_string.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_string.common().member_flags().IS_KEY(false); - mst_my_string.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_string.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, false)); - - MD5 my_string_hash("my_string"); - for(int i = 0; i < 4; ++i) - { - mst_my_string.detail().name_hash()[i] = my_string_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_string); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("BasicStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("BasicStruct", false); -} - -const TypeObject* GetCompleteBasicStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("BasicStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_bool; - cst_my_bool.common().member_id(memberId++); - cst_my_bool.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_bool.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_bool.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_bool.common().member_flags().IS_OPTIONAL(false); - cst_my_bool.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_bool.common().member_flags().IS_KEY(false); - cst_my_bool.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_bool.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("bool", false)); - - - cst_my_bool.detail().name("my_bool"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_bool); - - CompleteStructMember cst_my_octet; - cst_my_octet.common().member_id(memberId++); - cst_my_octet.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_octet.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_octet.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_octet.common().member_flags().IS_OPTIONAL(false); - cst_my_octet.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_octet.common().member_flags().IS_KEY(false); - cst_my_octet.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_octet.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint8_t", false)); - - - cst_my_octet.detail().name("my_octet"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_octet); - - CompleteStructMember cst_my_int16; - cst_my_int16.common().member_id(memberId++); - cst_my_int16.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_int16.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_int16.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_int16.common().member_flags().IS_OPTIONAL(false); - cst_my_int16.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_int16.common().member_flags().IS_KEY(false); - cst_my_int16.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_int16.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int16_t", false)); - - - cst_my_int16.detail().name("my_int16"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_int16); - - CompleteStructMember cst_my_int32; - cst_my_int32.common().member_id(memberId++); - cst_my_int32.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_int32.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_int32.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_int32.common().member_flags().IS_OPTIONAL(false); - cst_my_int32.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_int32.common().member_flags().IS_KEY(false); - cst_my_int32.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_int32.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - cst_my_int32.detail().name("my_int32"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_int32); - - CompleteStructMember cst_my_int64; - cst_my_int64.common().member_id(memberId++); - cst_my_int64.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_int64.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_int64.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_int64.common().member_flags().IS_OPTIONAL(false); - cst_my_int64.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_int64.common().member_flags().IS_KEY(false); - cst_my_int64.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_int64.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int64_t", false)); - - - cst_my_int64.detail().name("my_int64"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_int64); - - CompleteStructMember cst_my_uint16; - cst_my_uint16.common().member_id(memberId++); - cst_my_uint16.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_uint16.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_uint16.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_uint16.common().member_flags().IS_OPTIONAL(false); - cst_my_uint16.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_uint16.common().member_flags().IS_KEY(false); - cst_my_uint16.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_uint16.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint16_t", false)); - - - cst_my_uint16.detail().name("my_uint16"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_uint16); - - CompleteStructMember cst_my_uint32; - cst_my_uint32.common().member_id(memberId++); - cst_my_uint32.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_uint32.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_uint32.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_uint32.common().member_flags().IS_OPTIONAL(false); - cst_my_uint32.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_uint32.common().member_flags().IS_KEY(false); - cst_my_uint32.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_uint32.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint32_t", false)); - - - cst_my_uint32.detail().name("my_uint32"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_uint32); - - CompleteStructMember cst_my_uint64; - cst_my_uint64.common().member_id(memberId++); - cst_my_uint64.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_uint64.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_uint64.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_uint64.common().member_flags().IS_OPTIONAL(false); - cst_my_uint64.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_uint64.common().member_flags().IS_KEY(false); - cst_my_uint64.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_uint64.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint64_t", false)); - - - cst_my_uint64.detail().name("my_uint64"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_uint64); - - CompleteStructMember cst_my_float32; - cst_my_float32.common().member_id(memberId++); - cst_my_float32.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_float32.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_float32.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_float32.common().member_flags().IS_OPTIONAL(false); - cst_my_float32.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_float32.common().member_flags().IS_KEY(false); - cst_my_float32.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_float32.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("float", false)); - - - cst_my_float32.detail().name("my_float32"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_float32); - - CompleteStructMember cst_my_float64; - cst_my_float64.common().member_id(memberId++); - cst_my_float64.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_float64.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_float64.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_float64.common().member_flags().IS_OPTIONAL(false); - cst_my_float64.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_float64.common().member_flags().IS_KEY(false); - cst_my_float64.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_float64.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("double", false)); - - - cst_my_float64.detail().name("my_float64"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_float64); - - CompleteStructMember cst_my_float128; - cst_my_float128.common().member_id(memberId++); - cst_my_float128.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_float128.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_float128.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_float128.common().member_flags().IS_OPTIONAL(false); - cst_my_float128.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_float128.common().member_flags().IS_KEY(false); - cst_my_float128.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_float128.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("longdouble", false)); - - - cst_my_float128.detail().name("my_float128"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_float128); - - CompleteStructMember cst_my_char; - cst_my_char.common().member_id(memberId++); - cst_my_char.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_char.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_char.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_char.common().member_flags().IS_OPTIONAL(false); - cst_my_char.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_char.common().member_flags().IS_KEY(false); - cst_my_char.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_char.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("char", false)); - - - cst_my_char.detail().name("my_char"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_char); - - CompleteStructMember cst_my_string; - cst_my_string.common().member_id(memberId++); - cst_my_string.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_string.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_string.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_string.common().member_flags().IS_OPTIONAL(false); - cst_my_string.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_string.common().member_flags().IS_KEY(false); - cst_my_string.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_string.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, false)); - - cst_my_string.detail().name("my_string"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_string); - - - // Header - type_object->complete().struct_type().header().detail().type_name("BasicStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("BasicStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("BasicStruct", true); -} - -const TypeIdentifier* GetMyOctetArray500Identifier(bool complete) -{ - const TypeIdentifier* c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("MyOctetArray500", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetMyOctetArray500Object(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("MyOctetArray500", complete); -} - -const TypeObject* GetMyOctetArray500Object(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyOctetArray500", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteMyOctetArray500Object(); - } - else - { - return GetMinimalMyOctetArray500Object(); - } -} - -const TypeObject* GetMinimalMyOctetArray500Object() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyOctetArray500", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_ALIAS); - - // No flags apply - //type_object->minimal().alias_type().alias_flags().IS_FINAL(false); - //type_object->minimal().alias_type().alias_flags().IS_APPENDABLE(false); - //type_object->minimal().alias_type().alias_flags().IS_MUTABLE(false); - //type_object->minimal().alias_type().alias_flags().IS_NESTED(false); - //type_object->minimal().alias_type().alias_flags().IS_AUTOID_HASH(false); - - // type_object->minimal().alias_type().header()... Is empty - - // No flags apply - //type_object->minimal().alias_type().body().common().related_flags().TRY_CONSTRUCT1(false); - //type_object->minimal().alias_type().body().common().related_flags().TRY_CONSTRUCT2(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_EXTERNAL(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_OPTIONAL(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_MUST_UNDERSTAND(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_KEY(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_DEFAULT(false); - - // Must be defined already, if don't, may be an recursive alias - const TypeIdentifier *relatedType = TypeObjectFactory::get_instance()->get_type_identifier(TypeNamesGenerator::get_array_type_name("uint8_t", {500}), false); - - - if (relatedType != nullptr) - { - type_object->minimal().alias_type().body().common().related_type() = *relatedType; // Make a copy - } - else - { - // Cannot determine base type - delete type_object; - return nullptr; - } - - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().alias_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - // Don't add our TypeIdentifier but our alias - TypeObjectFactory::get_instance()->add_alias("MyOctetArray500", TypeNamesGenerator::get_array_type_name("uint8_t", {500})); - - TypeObjectFactory::get_instance()->add_type_object("MyOctetArray500", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyOctetArray500", false); -} - -const TypeObject* GetCompleteMyOctetArray500Object() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyOctetArray500", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_ALIAS); - - // No flags apply - //type_object->complete().alias_type().alias_flags().IS_FINAL(false); - //type_object->complete().alias_type().alias_flags().IS_APPENDABLE(false); - //type_object->complete().alias_type().alias_flags().IS_MUTABLE(false); - //type_object->complete().alias_type().alias_flags().IS_NESTED(false); - //type_object->complete().alias_type().alias_flags().IS_AUTOID_HASH(false); - - //type_object->complete().alias_type().header().detail().ann_builtin().verbatim().placement("placement"); - //type_object->complete().alias_type().header().detail().ann_builtin().verbatim().language("language"); - //type_object->complete().alias_type().header().detail().ann_builtin().verbatim().text("text"); - //type_object->complete().alias_type().header().detail().ann_custom().push_back(...); - type_object->complete().alias_type().header().detail().type_name("MyOctetArray500"); - - // No flags apply - //type_object->complete().alias_type().body().common().related_flags().TRY_CONSTRUCT1(false); - //type_object->complete().alias_type().body().common().related_flags().TRY_CONSTRUCT2(false); - //type_object->complete().alias_type().body().common().related_flags().IS_EXTERNAL(false); - //type_object->complete().alias_type().body().common().related_flags().IS_OPTIONAL(false); - //type_object->complete().alias_type().body().common().related_flags().IS_MUST_UNDERSTAND(false); - //type_object->complete().alias_type().body().common().related_flags().IS_KEY(false); - //type_object->complete().alias_type().body().common().related_flags().IS_DEFAULT(false); - - //type_object->complete().alias_type().body().common().ann_builtin() - //type_object->complete().alias_type().body().common().ann_custom() - - // Must be defined already, if don't, may be an recursive alias - const TypeIdentifier *relatedType = TypeObjectFactory::get_instance()->get_type_identifier_trying_complete(TypeNamesGenerator::get_array_type_name("uint8_t", {500})); - - - if (relatedType != nullptr) - { - type_object->complete().alias_type().body().common().related_type() = *relatedType; // Make a copy - } - else - { - // Cannot determine base type - delete type_object; - return nullptr; - } - - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().alias_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - // Don't add our TypeIdentifier but our alias - TypeObjectFactory::get_instance()->add_alias("MyOctetArray500", TypeNamesGenerator::get_array_type_name("uint8_t", {500})); - - TypeObjectFactory::get_instance()->add_type_object("MyOctetArray500", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyOctetArray500", true); -} - -const TypeIdentifier* GetBSAlias5Identifier(bool complete) -{ - const TypeIdentifier* c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("BSAlias5", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetBSAlias5Object(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("BSAlias5", complete); -} - -const TypeObject* GetBSAlias5Object(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("BSAlias5", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteBSAlias5Object(); - } - else - { - return GetMinimalBSAlias5Object(); - } -} - -const TypeObject* GetMinimalBSAlias5Object() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("BSAlias5", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_ALIAS); - - // No flags apply - //type_object->minimal().alias_type().alias_flags().IS_FINAL(false); - //type_object->minimal().alias_type().alias_flags().IS_APPENDABLE(false); - //type_object->minimal().alias_type().alias_flags().IS_MUTABLE(false); - //type_object->minimal().alias_type().alias_flags().IS_NESTED(false); - //type_object->minimal().alias_type().alias_flags().IS_AUTOID_HASH(false); - - // type_object->minimal().alias_type().header()... Is empty - - // No flags apply - //type_object->minimal().alias_type().body().common().related_flags().TRY_CONSTRUCT1(false); - //type_object->minimal().alias_type().body().common().related_flags().TRY_CONSTRUCT2(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_EXTERNAL(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_OPTIONAL(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_MUST_UNDERSTAND(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_KEY(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_DEFAULT(false); - - // Must be defined already, if don't, may be an recursive alias - const TypeIdentifier *relatedType = TypeObjectFactory::get_instance()->get_type_identifier(TypeNamesGenerator::get_array_type_name("BasicStruct", {5}), false); - - - if (relatedType != nullptr) - { - type_object->minimal().alias_type().body().common().related_type() = *relatedType; // Make a copy - } - else - { - // Cannot determine base type - delete type_object; - return nullptr; - } - - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().alias_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - // Don't add our TypeIdentifier but our alias - TypeObjectFactory::get_instance()->add_alias("BSAlias5", TypeNamesGenerator::get_array_type_name("BasicStruct", {5})); - - TypeObjectFactory::get_instance()->add_type_object("BSAlias5", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("BSAlias5", false); -} - -const TypeObject* GetCompleteBSAlias5Object() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("BSAlias5", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_ALIAS); - - // No flags apply - //type_object->complete().alias_type().alias_flags().IS_FINAL(false); - //type_object->complete().alias_type().alias_flags().IS_APPENDABLE(false); - //type_object->complete().alias_type().alias_flags().IS_MUTABLE(false); - //type_object->complete().alias_type().alias_flags().IS_NESTED(false); - //type_object->complete().alias_type().alias_flags().IS_AUTOID_HASH(false); - - //type_object->complete().alias_type().header().detail().ann_builtin().verbatim().placement("placement"); - //type_object->complete().alias_type().header().detail().ann_builtin().verbatim().language("language"); - //type_object->complete().alias_type().header().detail().ann_builtin().verbatim().text("text"); - //type_object->complete().alias_type().header().detail().ann_custom().push_back(...); - type_object->complete().alias_type().header().detail().type_name("BSAlias5"); - - // No flags apply - //type_object->complete().alias_type().body().common().related_flags().TRY_CONSTRUCT1(false); - //type_object->complete().alias_type().body().common().related_flags().TRY_CONSTRUCT2(false); - //type_object->complete().alias_type().body().common().related_flags().IS_EXTERNAL(false); - //type_object->complete().alias_type().body().common().related_flags().IS_OPTIONAL(false); - //type_object->complete().alias_type().body().common().related_flags().IS_MUST_UNDERSTAND(false); - //type_object->complete().alias_type().body().common().related_flags().IS_KEY(false); - //type_object->complete().alias_type().body().common().related_flags().IS_DEFAULT(false); - - //type_object->complete().alias_type().body().common().ann_builtin() - //type_object->complete().alias_type().body().common().ann_custom() - - // Must be defined already, if don't, may be an recursive alias - const TypeIdentifier *relatedType = TypeObjectFactory::get_instance()->get_type_identifier_trying_complete(TypeNamesGenerator::get_array_type_name("BasicStruct", {5})); - - - if (relatedType != nullptr) - { - type_object->complete().alias_type().body().common().related_type() = *relatedType; // Make a copy - } - else - { - // Cannot determine base type - delete type_object; - return nullptr; - } - - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().alias_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - // Don't add our TypeIdentifier but our alias - TypeObjectFactory::get_instance()->add_alias("BSAlias5", TypeNamesGenerator::get_array_type_name("BasicStruct", {5})); - - TypeObjectFactory::get_instance()->add_type_object("BSAlias5", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("BSAlias5", true); -} - -const TypeIdentifier* GetMA3Identifier(bool complete) -{ - const TypeIdentifier* c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("MA3", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetMA3Object(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("MA3", complete); -} - -const TypeObject* GetMA3Object(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MA3", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteMA3Object(); - } - else - { - return GetMinimalMA3Object(); - } -} - -const TypeObject* GetMinimalMA3Object() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MA3", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_ALIAS); - - // No flags apply - //type_object->minimal().alias_type().alias_flags().IS_FINAL(false); - //type_object->minimal().alias_type().alias_flags().IS_APPENDABLE(false); - //type_object->minimal().alias_type().alias_flags().IS_MUTABLE(false); - //type_object->minimal().alias_type().alias_flags().IS_NESTED(false); - //type_object->minimal().alias_type().alias_flags().IS_AUTOID_HASH(false); - - // type_object->minimal().alias_type().header()... Is empty - - // No flags apply - //type_object->minimal().alias_type().body().common().related_flags().TRY_CONSTRUCT1(false); - //type_object->minimal().alias_type().body().common().related_flags().TRY_CONSTRUCT2(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_EXTERNAL(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_OPTIONAL(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_MUST_UNDERSTAND(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_KEY(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_DEFAULT(false); - - // Must be defined already, if don't, may be an recursive alias - const TypeIdentifier *relatedType = TypeObjectFactory::get_instance()->get_type_identifier(TypeNamesGenerator::get_array_type_name("MyAliasEnum3", {42}), false); - - - if (relatedType != nullptr) - { - type_object->minimal().alias_type().body().common().related_type() = *relatedType; // Make a copy - } - else - { - // Cannot determine base type - delete type_object; - return nullptr; - } - - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().alias_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - // Don't add our TypeIdentifier but our alias - TypeObjectFactory::get_instance()->add_alias("MA3", TypeNamesGenerator::get_array_type_name("MyAliasEnum3", {42})); - - TypeObjectFactory::get_instance()->add_type_object("MA3", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MA3", false); -} - -const TypeObject* GetCompleteMA3Object() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MA3", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_ALIAS); - - // No flags apply - //type_object->complete().alias_type().alias_flags().IS_FINAL(false); - //type_object->complete().alias_type().alias_flags().IS_APPENDABLE(false); - //type_object->complete().alias_type().alias_flags().IS_MUTABLE(false); - //type_object->complete().alias_type().alias_flags().IS_NESTED(false); - //type_object->complete().alias_type().alias_flags().IS_AUTOID_HASH(false); - - //type_object->complete().alias_type().header().detail().ann_builtin().verbatim().placement("placement"); - //type_object->complete().alias_type().header().detail().ann_builtin().verbatim().language("language"); - //type_object->complete().alias_type().header().detail().ann_builtin().verbatim().text("text"); - //type_object->complete().alias_type().header().detail().ann_custom().push_back(...); - type_object->complete().alias_type().header().detail().type_name("MA3"); - - // No flags apply - //type_object->complete().alias_type().body().common().related_flags().TRY_CONSTRUCT1(false); - //type_object->complete().alias_type().body().common().related_flags().TRY_CONSTRUCT2(false); - //type_object->complete().alias_type().body().common().related_flags().IS_EXTERNAL(false); - //type_object->complete().alias_type().body().common().related_flags().IS_OPTIONAL(false); - //type_object->complete().alias_type().body().common().related_flags().IS_MUST_UNDERSTAND(false); - //type_object->complete().alias_type().body().common().related_flags().IS_KEY(false); - //type_object->complete().alias_type().body().common().related_flags().IS_DEFAULT(false); - - //type_object->complete().alias_type().body().common().ann_builtin() - //type_object->complete().alias_type().body().common().ann_custom() - - // Must be defined already, if don't, may be an recursive alias - const TypeIdentifier *relatedType = TypeObjectFactory::get_instance()->get_type_identifier_trying_complete(TypeNamesGenerator::get_array_type_name("MyAliasEnum3", {42})); - - - if (relatedType != nullptr) - { - type_object->complete().alias_type().body().common().related_type() = *relatedType; // Make a copy - } - else - { - // Cannot determine base type - delete type_object; - return nullptr; - } - - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().alias_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - // Don't add our TypeIdentifier but our alias - TypeObjectFactory::get_instance()->add_alias("MA3", TypeNamesGenerator::get_array_type_name("MyAliasEnum3", {42})); - - TypeObjectFactory::get_instance()->add_type_object("MA3", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MA3", true); -} - -const TypeIdentifier* GetMyMiniArrayIdentifier(bool complete) -{ - const TypeIdentifier* c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("MyMiniArray", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetMyMiniArrayObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("MyMiniArray", complete); -} - -const TypeObject* GetMyMiniArrayObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyMiniArray", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteMyMiniArrayObject(); - } - else - { - return GetMinimalMyMiniArrayObject(); - } -} - -const TypeObject* GetMinimalMyMiniArrayObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyMiniArray", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_ALIAS); - - // No flags apply - //type_object->minimal().alias_type().alias_flags().IS_FINAL(false); - //type_object->minimal().alias_type().alias_flags().IS_APPENDABLE(false); - //type_object->minimal().alias_type().alias_flags().IS_MUTABLE(false); - //type_object->minimal().alias_type().alias_flags().IS_NESTED(false); - //type_object->minimal().alias_type().alias_flags().IS_AUTOID_HASH(false); - - // type_object->minimal().alias_type().header()... Is empty - - // No flags apply - //type_object->minimal().alias_type().body().common().related_flags().TRY_CONSTRUCT1(false); - //type_object->minimal().alias_type().body().common().related_flags().TRY_CONSTRUCT2(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_EXTERNAL(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_OPTIONAL(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_MUST_UNDERSTAND(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_KEY(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_DEFAULT(false); - - // Must be defined already, if don't, may be an recursive alias - const TypeIdentifier *relatedType = TypeObjectFactory::get_instance()->get_type_identifier(TypeNamesGenerator::get_array_type_name("int32_t", {2}), false); - - - if (relatedType != nullptr) - { - type_object->minimal().alias_type().body().common().related_type() = *relatedType; // Make a copy - } - else - { - // Cannot determine base type - delete type_object; - return nullptr; - } - - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().alias_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - // Don't add our TypeIdentifier but our alias - TypeObjectFactory::get_instance()->add_alias("MyMiniArray", TypeNamesGenerator::get_array_type_name("int32_t", {2})); - - TypeObjectFactory::get_instance()->add_type_object("MyMiniArray", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyMiniArray", false); -} - -const TypeObject* GetCompleteMyMiniArrayObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyMiniArray", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_ALIAS); - - // No flags apply - //type_object->complete().alias_type().alias_flags().IS_FINAL(false); - //type_object->complete().alias_type().alias_flags().IS_APPENDABLE(false); - //type_object->complete().alias_type().alias_flags().IS_MUTABLE(false); - //type_object->complete().alias_type().alias_flags().IS_NESTED(false); - //type_object->complete().alias_type().alias_flags().IS_AUTOID_HASH(false); - - //type_object->complete().alias_type().header().detail().ann_builtin().verbatim().placement("placement"); - //type_object->complete().alias_type().header().detail().ann_builtin().verbatim().language("language"); - //type_object->complete().alias_type().header().detail().ann_builtin().verbatim().text("text"); - //type_object->complete().alias_type().header().detail().ann_custom().push_back(...); - type_object->complete().alias_type().header().detail().type_name("MyMiniArray"); - - // No flags apply - //type_object->complete().alias_type().body().common().related_flags().TRY_CONSTRUCT1(false); - //type_object->complete().alias_type().body().common().related_flags().TRY_CONSTRUCT2(false); - //type_object->complete().alias_type().body().common().related_flags().IS_EXTERNAL(false); - //type_object->complete().alias_type().body().common().related_flags().IS_OPTIONAL(false); - //type_object->complete().alias_type().body().common().related_flags().IS_MUST_UNDERSTAND(false); - //type_object->complete().alias_type().body().common().related_flags().IS_KEY(false); - //type_object->complete().alias_type().body().common().related_flags().IS_DEFAULT(false); - - //type_object->complete().alias_type().body().common().ann_builtin() - //type_object->complete().alias_type().body().common().ann_custom() - - // Must be defined already, if don't, may be an recursive alias - const TypeIdentifier *relatedType = TypeObjectFactory::get_instance()->get_type_identifier_trying_complete(TypeNamesGenerator::get_array_type_name("int32_t", {2})); - - - if (relatedType != nullptr) - { - type_object->complete().alias_type().body().common().related_type() = *relatedType; // Make a copy - } - else - { - // Cannot determine base type - delete type_object; - return nullptr; - } - - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().alias_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - // Don't add our TypeIdentifier but our alias - TypeObjectFactory::get_instance()->add_alias("MyMiniArray", TypeNamesGenerator::get_array_type_name("int32_t", {2})); - - TypeObjectFactory::get_instance()->add_type_object("MyMiniArray", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyMiniArray", true); -} - - - -const TypeIdentifier* GetMySequenceLongIdentifier(bool complete) -{ - const TypeIdentifier* c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("MySequenceLong", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetMySequenceLongObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("MySequenceLong", complete); -} - -const TypeObject* GetMySequenceLongObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MySequenceLong", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteMySequenceLongObject(); - } - else - { - return GetMinimalMySequenceLongObject(); - } -} - -const TypeObject* GetMinimalMySequenceLongObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MySequenceLong", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_ALIAS); - - // No flags apply - //type_object->minimal().alias_type().alias_flags().IS_FINAL(false); - //type_object->minimal().alias_type().alias_flags().IS_APPENDABLE(false); - //type_object->minimal().alias_type().alias_flags().IS_MUTABLE(false); - //type_object->minimal().alias_type().alias_flags().IS_NESTED(false); - //type_object->minimal().alias_type().alias_flags().IS_AUTOID_HASH(false); - - // type_object->minimal().alias_type().header()... Is empty - - // No flags apply - //type_object->minimal().alias_type().body().common().related_flags().TRY_CONSTRUCT1(false); - //type_object->minimal().alias_type().body().common().related_flags().TRY_CONSTRUCT2(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_EXTERNAL(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_OPTIONAL(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_MUST_UNDERSTAND(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_KEY(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_DEFAULT(false); - - // Must be defined already, if don't, may be an recursive alias - const TypeIdentifier *relatedType = TypeObjectFactory::get_instance()->get_type_identifier(TypeNamesGenerator::get_sequence_type_name("int32_t", 100), false); - - - if (relatedType != nullptr) - { - type_object->minimal().alias_type().body().common().related_type() = *relatedType; // Make a copy - } - else - { - // Cannot determine base type - delete type_object; - return nullptr; - } - - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().alias_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - // Don't add our TypeIdentifier but our alias - TypeObjectFactory::get_instance()->add_alias("MySequenceLong", TypeNamesGenerator::get_sequence_type_name("int32_t", 100)); - - TypeObjectFactory::get_instance()->add_type_object("MySequenceLong", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MySequenceLong", false); -} - -const TypeObject* GetCompleteMySequenceLongObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MySequenceLong", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_ALIAS); - - // No flags apply - //type_object->complete().alias_type().alias_flags().IS_FINAL(false); - //type_object->complete().alias_type().alias_flags().IS_APPENDABLE(false); - //type_object->complete().alias_type().alias_flags().IS_MUTABLE(false); - //type_object->complete().alias_type().alias_flags().IS_NESTED(false); - //type_object->complete().alias_type().alias_flags().IS_AUTOID_HASH(false); - - //type_object->complete().alias_type().header().detail().ann_builtin().verbatim().placement("placement"); - //type_object->complete().alias_type().header().detail().ann_builtin().verbatim().language("language"); - //type_object->complete().alias_type().header().detail().ann_builtin().verbatim().text("text"); - //type_object->complete().alias_type().header().detail().ann_custom().push_back(...); - type_object->complete().alias_type().header().detail().type_name("MySequenceLong"); - - // No flags apply - //type_object->complete().alias_type().body().common().related_flags().TRY_CONSTRUCT1(false); - //type_object->complete().alias_type().body().common().related_flags().TRY_CONSTRUCT2(false); - //type_object->complete().alias_type().body().common().related_flags().IS_EXTERNAL(false); - //type_object->complete().alias_type().body().common().related_flags().IS_OPTIONAL(false); - //type_object->complete().alias_type().body().common().related_flags().IS_MUST_UNDERSTAND(false); - //type_object->complete().alias_type().body().common().related_flags().IS_KEY(false); - //type_object->complete().alias_type().body().common().related_flags().IS_DEFAULT(false); - - //type_object->complete().alias_type().body().common().ann_builtin() - //type_object->complete().alias_type().body().common().ann_custom() - - // Must be defined already, if don't, may be an recursive alias - const TypeIdentifier *relatedType = TypeObjectFactory::get_instance()->get_type_identifier_trying_complete(TypeNamesGenerator::get_sequence_type_name("int32_t", 100)); - - - if (relatedType != nullptr) - { - type_object->complete().alias_type().body().common().related_type() = *relatedType; // Make a copy - } - else - { - // Cannot determine base type - delete type_object; - return nullptr; - } - - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().alias_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - // Don't add our TypeIdentifier but our alias - TypeObjectFactory::get_instance()->add_alias("MySequenceLong", TypeNamesGenerator::get_sequence_type_name("int32_t", 100)); - - TypeObjectFactory::get_instance()->add_type_object("MySequenceLong", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MySequenceLong", true); -} - - - -const TypeIdentifier* GetComplexStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("ComplexStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetComplexStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("ComplexStruct", complete); -} - -const TypeObject* GetComplexStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ComplexStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteComplexStructObject(); - } - //else - return GetMinimalComplexStructObject(); -} - -const TypeObject* GetMinimalComplexStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ComplexStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_octet; - mst_my_octet.common().member_id(memberId++); - mst_my_octet.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_octet.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_octet.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_octet.common().member_flags().IS_OPTIONAL(false); - mst_my_octet.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_octet.common().member_flags().IS_KEY(false); - mst_my_octet.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_octet.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint8_t", false)); - - - MD5 my_octet_hash("my_octet"); - for(int i = 0; i < 4; ++i) - { - mst_my_octet.detail().name_hash()[i] = my_octet_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_octet); - - MinimalStructMember mst_my_basic_struct; - mst_my_basic_struct.common().member_id(memberId++); - mst_my_basic_struct.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_basic_struct.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_basic_struct.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_basic_struct.common().member_flags().IS_OPTIONAL(false); - mst_my_basic_struct.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_basic_struct.common().member_flags().IS_KEY(false); - mst_my_basic_struct.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_basic_struct.common().member_type_id(*GetBasicStructIdentifier(false)); - - MD5 my_basic_struct_hash("my_basic_struct"); - for(int i = 0; i < 4; ++i) - { - mst_my_basic_struct.detail().name_hash()[i] = my_basic_struct_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_basic_struct); - - MinimalStructMember mst_my_alias_enum; - mst_my_alias_enum.common().member_id(memberId++); - mst_my_alias_enum.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_alias_enum.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_alias_enum.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_alias_enum.common().member_flags().IS_OPTIONAL(false); - mst_my_alias_enum.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_alias_enum.common().member_flags().IS_KEY(false); - mst_my_alias_enum.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_alias_enum.common().member_type_id(*GetMyAliasEnumIdentifier(false)); - - MD5 my_alias_enum_hash("my_alias_enum"); - for(int i = 0; i < 4; ++i) - { - mst_my_alias_enum.detail().name_hash()[i] = my_alias_enum_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_alias_enum); - - MinimalStructMember mst_my_enum; - mst_my_enum.common().member_id(memberId++); - mst_my_enum.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_enum.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_enum.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_enum.common().member_flags().IS_OPTIONAL(false); - mst_my_enum.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_enum.common().member_flags().IS_KEY(false); - mst_my_enum.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_enum.common().member_type_id(*GetMyEnumIdentifier(false)); - - MD5 my_enum_hash("my_enum"); - for(int i = 0; i < 4; ++i) - { - mst_my_enum.detail().name_hash()[i] = my_enum_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_enum); - - MinimalStructMember mst_my_sequence_octet; - mst_my_sequence_octet.common().member_id(memberId++); - mst_my_sequence_octet.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_sequence_octet.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_sequence_octet.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_sequence_octet.common().member_flags().IS_OPTIONAL(false); - mst_my_sequence_octet.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_sequence_octet.common().member_flags().IS_KEY(false); - mst_my_sequence_octet.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_sequence_octet.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("uint8_t", 55, false)); - - MD5 my_sequence_octet_hash("my_sequence_octet"); - for(int i = 0; i < 4; ++i) - { - mst_my_sequence_octet.detail().name_hash()[i] = my_sequence_octet_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_sequence_octet); - - MinimalStructMember mst_my_sequence_struct; - mst_my_sequence_struct.common().member_id(memberId++); - mst_my_sequence_struct.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_sequence_struct.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_sequence_struct.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_sequence_struct.common().member_flags().IS_OPTIONAL(false); - mst_my_sequence_struct.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_sequence_struct.common().member_flags().IS_KEY(false); - mst_my_sequence_struct.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_sequence_struct.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("BasicStruct", 100, false)); - - MD5 my_sequence_struct_hash("my_sequence_struct"); - for(int i = 0; i < 4; ++i) - { - mst_my_sequence_struct.detail().name_hash()[i] = my_sequence_struct_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_sequence_struct); - - MinimalStructMember mst_my_array_octet; - mst_my_array_octet.common().member_id(memberId++); - mst_my_array_octet.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_array_octet.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_array_octet.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_array_octet.common().member_flags().IS_OPTIONAL(false); - mst_my_array_octet.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_array_octet.common().member_flags().IS_KEY(false); - mst_my_array_octet.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_array_octet.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("char", {500, 5, 4}, false)); - - MD5 my_array_octet_hash("my_array_octet"); - for(int i = 0; i < 4; ++i) - { - mst_my_array_octet.detail().name_hash()[i] = my_array_octet_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_array_octet); - - MinimalStructMember mst_my_octet_array_500; - mst_my_octet_array_500.common().member_id(memberId++); - mst_my_octet_array_500.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_octet_array_500.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_octet_array_500.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_octet_array_500.common().member_flags().IS_OPTIONAL(false); - mst_my_octet_array_500.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_octet_array_500.common().member_flags().IS_KEY(false); - mst_my_octet_array_500.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_octet_array_500.common().member_type_id(*GetMyOctetArray500Identifier(false)); - - MD5 my_octet_array_500_hash("my_octet_array_500"); - for(int i = 0; i < 4; ++i) - { - mst_my_octet_array_500.detail().name_hash()[i] = my_octet_array_500_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_octet_array_500); - - MinimalStructMember mst_my_array_struct; - mst_my_array_struct.common().member_id(memberId++); - mst_my_array_struct.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_array_struct.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_array_struct.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_array_struct.common().member_flags().IS_OPTIONAL(false); - mst_my_array_struct.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_array_struct.common().member_flags().IS_KEY(false); - mst_my_array_struct.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_array_struct.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("BasicStruct", {5}, false)); - - MD5 my_array_struct_hash("my_array_struct"); - for(int i = 0; i < 4; ++i) - { - mst_my_array_struct.detail().name_hash()[i] = my_array_struct_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_array_struct); - - MinimalStructMember mst_my_map_octet_short; - mst_my_map_octet_short.common().member_id(memberId++); - mst_my_map_octet_short.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_map_octet_short.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_map_octet_short.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_map_octet_short.common().member_flags().IS_OPTIONAL(false); - mst_my_map_octet_short.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_map_octet_short.common().member_flags().IS_KEY(false); - mst_my_map_octet_short.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_map_octet_short.common().member_type_id(*TypeObjectFactory::get_instance()->get_map_identifier("uint8_t", "int16_t", 100, false)); - - MD5 my_map_octet_short_hash("my_map_octet_short"); - for(int i = 0; i < 4; ++i) - { - mst_my_map_octet_short.detail().name_hash()[i] = my_map_octet_short_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_map_octet_short); - - MinimalStructMember mst_my_map_long_struct; - mst_my_map_long_struct.common().member_id(memberId++); - mst_my_map_long_struct.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_map_long_struct.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_map_long_struct.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_map_long_struct.common().member_flags().IS_OPTIONAL(false); - mst_my_map_long_struct.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_map_long_struct.common().member_flags().IS_KEY(false); - mst_my_map_long_struct.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_map_long_struct.common().member_type_id(*TypeObjectFactory::get_instance()->get_map_identifier("int32_t", "BasicStruct", 100, false)); - - MD5 my_map_long_struct_hash("my_map_long_struct"); - for(int i = 0; i < 4; ++i) - { - mst_my_map_long_struct.detail().name_hash()[i] = my_map_long_struct_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_map_long_struct); - - MinimalStructMember mst_my_map_long_seq_octet; - mst_my_map_long_seq_octet.common().member_id(memberId++); - mst_my_map_long_seq_octet.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_map_long_seq_octet.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_map_long_seq_octet.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_map_long_seq_octet.common().member_flags().IS_OPTIONAL(false); - mst_my_map_long_seq_octet.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_map_long_seq_octet.common().member_flags().IS_KEY(false); - mst_my_map_long_seq_octet.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_map_long_seq_octet.common().member_type_id(*TypeObjectFactory::get_instance()->get_map_identifier("int32_t", TypeNamesGenerator::get_sequence_type_name(TypeNamesGenerator::get_sequence_type_name("uint8_t", 100), 100), 100, false)); - - MD5 my_map_long_seq_octet_hash("my_map_long_seq_octet"); - for(int i = 0; i < 4; ++i) - { - mst_my_map_long_seq_octet.detail().name_hash()[i] = my_map_long_seq_octet_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_map_long_seq_octet); - - MinimalStructMember mst_my_map_long_octet_array_500; - mst_my_map_long_octet_array_500.common().member_id(memberId++); - mst_my_map_long_octet_array_500.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_map_long_octet_array_500.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_map_long_octet_array_500.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_map_long_octet_array_500.common().member_flags().IS_OPTIONAL(false); - mst_my_map_long_octet_array_500.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_map_long_octet_array_500.common().member_flags().IS_KEY(false); - mst_my_map_long_octet_array_500.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_map_long_octet_array_500.common().member_type_id(*TypeObjectFactory::get_instance()->get_map_identifier("int32_t", "MyOctetArray500", 100, false)); - - MD5 my_map_long_octet_array_500_hash("my_map_long_octet_array_500"); - for(int i = 0; i < 4; ++i) - { - mst_my_map_long_octet_array_500.detail().name_hash()[i] = my_map_long_octet_array_500_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_map_long_octet_array_500); - - MinimalStructMember mst_my_map_long_lol_type; - mst_my_map_long_lol_type.common().member_id(memberId++); - mst_my_map_long_lol_type.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_map_long_lol_type.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_map_long_lol_type.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_map_long_lol_type.common().member_flags().IS_OPTIONAL(false); - mst_my_map_long_lol_type.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_map_long_lol_type.common().member_flags().IS_KEY(false); - mst_my_map_long_lol_type.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_map_long_lol_type.common().member_type_id(*TypeObjectFactory::get_instance()->get_map_identifier("int32_t", TypeNamesGenerator::get_map_type_name("uint8_t", "BSAlias5", 100), 100, false)); - - MD5 my_map_long_lol_type_hash("my_map_long_lol_type"); - for(int i = 0; i < 4; ++i) - { - mst_my_map_long_lol_type.detail().name_hash()[i] = my_map_long_lol_type_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_map_long_lol_type); - - MinimalStructMember mst_my_small_string_8; - mst_my_small_string_8.common().member_id(memberId++); - mst_my_small_string_8.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_small_string_8.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_small_string_8.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_small_string_8.common().member_flags().IS_OPTIONAL(false); - mst_my_small_string_8.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_small_string_8.common().member_flags().IS_KEY(false); - mst_my_small_string_8.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_small_string_8.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(128, false)); - - MD5 my_small_string_8_hash("my_small_string_8"); - for(int i = 0; i < 4; ++i) - { - mst_my_small_string_8.detail().name_hash()[i] = my_small_string_8_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_small_string_8); - - MinimalStructMember mst_my_large_string_8; - mst_my_large_string_8.common().member_id(memberId++); - mst_my_large_string_8.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_large_string_8.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_large_string_8.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_large_string_8.common().member_flags().IS_OPTIONAL(false); - mst_my_large_string_8.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_large_string_8.common().member_flags().IS_KEY(false); - mst_my_large_string_8.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_large_string_8.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(500, false)); - - MD5 my_large_string_8_hash("my_large_string_8"); - for(int i = 0; i < 4; ++i) - { - mst_my_large_string_8.detail().name_hash()[i] = my_large_string_8_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_large_string_8); - - MinimalStructMember mst_my_array_string; - mst_my_array_string.common().member_id(memberId++); - mst_my_array_string.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_array_string.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_array_string.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_array_string.common().member_flags().IS_OPTIONAL(false); - mst_my_array_string.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_array_string.common().member_flags().IS_KEY(false); - mst_my_array_string.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_array_string.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier(TypeNamesGenerator::get_string_type_name(75, false), {5, 5}, false)); - - MD5 my_array_string_hash("my_array_string"); - for(int i = 0; i < 4; ++i) - { - mst_my_array_string.detail().name_hash()[i] = my_array_string_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_array_string); - - MinimalStructMember mst_multi_alias_array_42; - mst_multi_alias_array_42.common().member_id(memberId++); - mst_multi_alias_array_42.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_multi_alias_array_42.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_multi_alias_array_42.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_multi_alias_array_42.common().member_flags().IS_OPTIONAL(false); - mst_multi_alias_array_42.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_multi_alias_array_42.common().member_flags().IS_KEY(false); - mst_multi_alias_array_42.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_multi_alias_array_42.common().member_type_id(*GetMA3Identifier(false)); - - MD5 multi_alias_array_42_hash("multi_alias_array_42"); - for(int i = 0; i < 4; ++i) - { - mst_multi_alias_array_42.detail().name_hash()[i] = multi_alias_array_42_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_multi_alias_array_42); - - MinimalStructMember mst_my_array_arrays; - mst_my_array_arrays.common().member_id(memberId++); - mst_my_array_arrays.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_array_arrays.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_array_arrays.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_array_arrays.common().member_flags().IS_OPTIONAL(false); - mst_my_array_arrays.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_array_arrays.common().member_flags().IS_KEY(false); - mst_my_array_arrays.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_array_arrays.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("MyMiniArray", {5}, false)); - - MD5 my_array_arrays_hash("my_array_arrays"); - for(int i = 0; i < 4; ++i) - { - mst_my_array_arrays.detail().name_hash()[i] = my_array_arrays_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_array_arrays); - - MinimalStructMember mst_my_sequences_array; - mst_my_sequences_array.common().member_id(memberId++); - mst_my_sequences_array.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_sequences_array.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_sequences_array.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_sequences_array.common().member_flags().IS_OPTIONAL(false); - mst_my_sequences_array.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_sequences_array.common().member_flags().IS_KEY(false); - mst_my_sequences_array.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_sequences_array.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("MySequenceLong", {23}, false)); - - MD5 my_sequences_array_hash("my_sequences_array"); - for(int i = 0; i < 4; ++i) - { - mst_my_sequences_array.detail().name_hash()[i] = my_sequences_array_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_sequences_array); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("ComplexStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("ComplexStruct", false); -} - -const TypeObject* GetCompleteComplexStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ComplexStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_octet; - cst_my_octet.common().member_id(memberId++); - cst_my_octet.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_octet.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_octet.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_octet.common().member_flags().IS_OPTIONAL(false); - cst_my_octet.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_octet.common().member_flags().IS_KEY(false); - cst_my_octet.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_octet.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint8_t", false)); - - - cst_my_octet.detail().name("my_octet"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_octet); - - CompleteStructMember cst_my_basic_struct; - cst_my_basic_struct.common().member_id(memberId++); - cst_my_basic_struct.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_basic_struct.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_basic_struct.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_basic_struct.common().member_flags().IS_OPTIONAL(false); - cst_my_basic_struct.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_basic_struct.common().member_flags().IS_KEY(false); - cst_my_basic_struct.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_basic_struct.common().member_type_id(*GetBasicStructIdentifier(true)); - - cst_my_basic_struct.detail().name("my_basic_struct"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_basic_struct); - - CompleteStructMember cst_my_alias_enum; - cst_my_alias_enum.common().member_id(memberId++); - cst_my_alias_enum.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_alias_enum.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_alias_enum.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_alias_enum.common().member_flags().IS_OPTIONAL(false); - cst_my_alias_enum.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_alias_enum.common().member_flags().IS_KEY(false); - cst_my_alias_enum.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_alias_enum.common().member_type_id(*GetMyAliasEnumIdentifier(true)); - - cst_my_alias_enum.detail().name("my_alias_enum"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_alias_enum); - - CompleteStructMember cst_my_enum; - cst_my_enum.common().member_id(memberId++); - cst_my_enum.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_enum.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_enum.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_enum.common().member_flags().IS_OPTIONAL(false); - cst_my_enum.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_enum.common().member_flags().IS_KEY(false); - cst_my_enum.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_enum.common().member_type_id(*GetMyEnumIdentifier(true)); - - cst_my_enum.detail().name("my_enum"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_enum); - - CompleteStructMember cst_my_sequence_octet; - cst_my_sequence_octet.common().member_id(memberId++); - cst_my_sequence_octet.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_sequence_octet.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_sequence_octet.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_sequence_octet.common().member_flags().IS_OPTIONAL(false); - cst_my_sequence_octet.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_sequence_octet.common().member_flags().IS_KEY(false); - cst_my_sequence_octet.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_sequence_octet.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("uint8_t", 55, true)); - - cst_my_sequence_octet.detail().name("my_sequence_octet"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_sequence_octet); - - CompleteStructMember cst_my_sequence_struct; - cst_my_sequence_struct.common().member_id(memberId++); - cst_my_sequence_struct.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_sequence_struct.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_sequence_struct.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_sequence_struct.common().member_flags().IS_OPTIONAL(false); - cst_my_sequence_struct.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_sequence_struct.common().member_flags().IS_KEY(false); - cst_my_sequence_struct.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_sequence_struct.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("BasicStruct", 100, true)); - - cst_my_sequence_struct.detail().name("my_sequence_struct"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_sequence_struct); - - CompleteStructMember cst_my_array_octet; - cst_my_array_octet.common().member_id(memberId++); - cst_my_array_octet.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_array_octet.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_array_octet.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_array_octet.common().member_flags().IS_OPTIONAL(false); - cst_my_array_octet.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_array_octet.common().member_flags().IS_KEY(false); - cst_my_array_octet.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_array_octet.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("char", {500, 5, 4}, true)); - - cst_my_array_octet.detail().name("my_array_octet"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_array_octet); - - CompleteStructMember cst_my_octet_array_500; - cst_my_octet_array_500.common().member_id(memberId++); - cst_my_octet_array_500.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_octet_array_500.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_octet_array_500.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_octet_array_500.common().member_flags().IS_OPTIONAL(false); - cst_my_octet_array_500.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_octet_array_500.common().member_flags().IS_KEY(false); - cst_my_octet_array_500.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_octet_array_500.common().member_type_id(*GetMyOctetArray500Identifier(true)); - - cst_my_octet_array_500.detail().name("my_octet_array_500"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_octet_array_500); - - CompleteStructMember cst_my_array_struct; - cst_my_array_struct.common().member_id(memberId++); - cst_my_array_struct.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_array_struct.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_array_struct.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_array_struct.common().member_flags().IS_OPTIONAL(false); - cst_my_array_struct.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_array_struct.common().member_flags().IS_KEY(false); - cst_my_array_struct.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_array_struct.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("BasicStruct", {5}, true)); - - cst_my_array_struct.detail().name("my_array_struct"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_array_struct); - - CompleteStructMember cst_my_map_octet_short; - cst_my_map_octet_short.common().member_id(memberId++); - cst_my_map_octet_short.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_map_octet_short.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_map_octet_short.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_map_octet_short.common().member_flags().IS_OPTIONAL(false); - cst_my_map_octet_short.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_map_octet_short.common().member_flags().IS_KEY(false); - cst_my_map_octet_short.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_map_octet_short.common().member_type_id(*TypeObjectFactory::get_instance()->get_map_identifier("uint8_t", "int16_t", 100, true)); - - cst_my_map_octet_short.detail().name("my_map_octet_short"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_map_octet_short); - - CompleteStructMember cst_my_map_long_struct; - cst_my_map_long_struct.common().member_id(memberId++); - cst_my_map_long_struct.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_map_long_struct.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_map_long_struct.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_map_long_struct.common().member_flags().IS_OPTIONAL(false); - cst_my_map_long_struct.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_map_long_struct.common().member_flags().IS_KEY(false); - cst_my_map_long_struct.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_map_long_struct.common().member_type_id(*TypeObjectFactory::get_instance()->get_map_identifier("int32_t", "BasicStruct", 100, true)); - - cst_my_map_long_struct.detail().name("my_map_long_struct"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_map_long_struct); - - CompleteStructMember cst_my_map_long_seq_octet; - cst_my_map_long_seq_octet.common().member_id(memberId++); - cst_my_map_long_seq_octet.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_map_long_seq_octet.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_map_long_seq_octet.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_map_long_seq_octet.common().member_flags().IS_OPTIONAL(false); - cst_my_map_long_seq_octet.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_map_long_seq_octet.common().member_flags().IS_KEY(false); - cst_my_map_long_seq_octet.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_map_long_seq_octet.common().member_type_id(*TypeObjectFactory::get_instance()->get_map_identifier("int32_t", TypeNamesGenerator::get_sequence_type_name(TypeNamesGenerator::get_sequence_type_name("uint8_t", 100), 100), 100, true)); - - cst_my_map_long_seq_octet.detail().name("my_map_long_seq_octet"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_map_long_seq_octet); - - CompleteStructMember cst_my_map_long_octet_array_500; - cst_my_map_long_octet_array_500.common().member_id(memberId++); - cst_my_map_long_octet_array_500.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_map_long_octet_array_500.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_map_long_octet_array_500.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_map_long_octet_array_500.common().member_flags().IS_OPTIONAL(false); - cst_my_map_long_octet_array_500.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_map_long_octet_array_500.common().member_flags().IS_KEY(false); - cst_my_map_long_octet_array_500.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_map_long_octet_array_500.common().member_type_id(*TypeObjectFactory::get_instance()->get_map_identifier("int32_t", "MyOctetArray500", 100, true)); - - cst_my_map_long_octet_array_500.detail().name("my_map_long_octet_array_500"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_map_long_octet_array_500); - - CompleteStructMember cst_my_map_long_lol_type; - cst_my_map_long_lol_type.common().member_id(memberId++); - cst_my_map_long_lol_type.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_map_long_lol_type.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_map_long_lol_type.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_map_long_lol_type.common().member_flags().IS_OPTIONAL(false); - cst_my_map_long_lol_type.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_map_long_lol_type.common().member_flags().IS_KEY(false); - cst_my_map_long_lol_type.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_map_long_lol_type.common().member_type_id(*TypeObjectFactory::get_instance()->get_map_identifier("int32_t", TypeNamesGenerator::get_map_type_name("uint8_t", "BSAlias5", 100), 100, true)); - - cst_my_map_long_lol_type.detail().name("my_map_long_lol_type"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_map_long_lol_type); - - CompleteStructMember cst_my_small_string_8; - cst_my_small_string_8.common().member_id(memberId++); - cst_my_small_string_8.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_small_string_8.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_small_string_8.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_small_string_8.common().member_flags().IS_OPTIONAL(false); - cst_my_small_string_8.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_small_string_8.common().member_flags().IS_KEY(false); - cst_my_small_string_8.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_small_string_8.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(128, false)); - - cst_my_small_string_8.detail().name("my_small_string_8"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_small_string_8); - - CompleteStructMember cst_my_large_string_8; - cst_my_large_string_8.common().member_id(memberId++); - cst_my_large_string_8.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_large_string_8.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_large_string_8.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_large_string_8.common().member_flags().IS_OPTIONAL(false); - cst_my_large_string_8.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_large_string_8.common().member_flags().IS_KEY(false); - cst_my_large_string_8.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_large_string_8.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(500, false)); - - cst_my_large_string_8.detail().name("my_large_string_8"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_large_string_8); - - CompleteStructMember cst_my_array_string; - cst_my_array_string.common().member_id(memberId++); - cst_my_array_string.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_array_string.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_array_string.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_array_string.common().member_flags().IS_OPTIONAL(false); - cst_my_array_string.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_array_string.common().member_flags().IS_KEY(false); - cst_my_array_string.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_array_string.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier(TypeNamesGenerator::get_string_type_name(75, false), {5, 5}, true)); - - cst_my_array_string.detail().name("my_array_string"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_array_string); - - CompleteStructMember cst_multi_alias_array_42; - cst_multi_alias_array_42.common().member_id(memberId++); - cst_multi_alias_array_42.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_multi_alias_array_42.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_multi_alias_array_42.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_multi_alias_array_42.common().member_flags().IS_OPTIONAL(false); - cst_multi_alias_array_42.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_multi_alias_array_42.common().member_flags().IS_KEY(false); - cst_multi_alias_array_42.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_multi_alias_array_42.common().member_type_id(*GetMA3Identifier(true)); - - cst_multi_alias_array_42.detail().name("multi_alias_array_42"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_multi_alias_array_42); - - CompleteStructMember cst_my_array_arrays; - cst_my_array_arrays.common().member_id(memberId++); - cst_my_array_arrays.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_array_arrays.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_array_arrays.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_array_arrays.common().member_flags().IS_OPTIONAL(false); - cst_my_array_arrays.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_array_arrays.common().member_flags().IS_KEY(false); - cst_my_array_arrays.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_array_arrays.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("MyMiniArray", {5}, true)); - - cst_my_array_arrays.detail().name("my_array_arrays"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_array_arrays); - - CompleteStructMember cst_my_sequences_array; - cst_my_sequences_array.common().member_id(memberId++); - cst_my_sequences_array.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_sequences_array.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_sequences_array.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_sequences_array.common().member_flags().IS_OPTIONAL(false); - cst_my_sequences_array.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_sequences_array.common().member_flags().IS_KEY(false); - cst_my_sequences_array.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_sequences_array.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("MySequenceLong", {23}, true)); - - cst_my_sequences_array.detail().name("my_sequences_array"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_sequences_array); - - - // Header - type_object->complete().struct_type().header().detail().type_name("ComplexStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("ComplexStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("ComplexStruct", true); -} - - - -const TypeIdentifier* GetMyUnionIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("MyUnion", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetMyUnionObject(complete); - return TypeObjectFactory::get_instance()->get_type_identifier("MyUnion", complete); -} - -const TypeObject* GetMyUnionObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyUnion", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteMyUnionObject(); - } - // else - return GetMinimalMyUnionObject(); -} - -const TypeObject* GetMinimalMyUnionObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyUnion", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_UNION); - - type_object->minimal().union_type().union_flags().IS_FINAL(false); - type_object->minimal().union_type().union_flags().IS_APPENDABLE(false); - type_object->minimal().union_type().union_flags().IS_MUTABLE(false); - type_object->minimal().union_type().union_flags().IS_NESTED(false); - type_object->minimal().union_type().union_flags().IS_AUTOID_HASH(false); // Unsupported - - type_object->minimal().union_type().discriminator().common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().IS_EXTERNAL(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_OPTIONAL(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_KEY(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().IS_DEFAULT(false); // Doesn't apply - - type_object->minimal().union_type().discriminator().common().type_id(*GetMyEnumIdentifier(false)); - - MemberId memberId = 0; - MinimalUnionMember mst_basic; - mst_basic.common().member_id(memberId++); - mst_basic.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_basic.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_basic.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_basic.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - mst_basic.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mst_basic.common().member_flags().IS_KEY(false); // Doesn't apply - mst_basic.common().member_flags().IS_DEFAULT(false); - mst_basic.common().type_id(*GetBasicStructIdentifier(false)); - - mst_basic.common().label_seq().emplace_back(::A); - - MD5 basic_hash("basic"); - for(int i = 0; i < 4; ++i) - { - mst_basic.detail().name_hash()[i] = basic_hash.digest[i]; - } - type_object->minimal().union_type().member_seq().emplace_back(mst_basic); - - MinimalUnionMember mst_complex; - mst_complex.common().member_id(memberId++); - mst_complex.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_complex.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_complex.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_complex.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - mst_complex.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mst_complex.common().member_flags().IS_KEY(false); // Doesn't apply - mst_complex.common().member_flags().IS_DEFAULT(false); - mst_complex.common().type_id(*GetComplexStructIdentifier(false)); - - mst_complex.common().label_seq().emplace_back(::B); - mst_complex.common().label_seq().emplace_back(::C); - - MD5 complex_hash("complex"); - for(int i = 0; i < 4; ++i) - { - mst_complex.detail().name_hash()[i] = complex_hash.digest[i]; - } - type_object->minimal().union_type().member_seq().emplace_back(mst_complex); - - - // Header - //type_object->minimal().union_type().header().detail()... // Empty - - TypeIdentifier* identifier = new TypeIdentifier(); - identifier->_d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().union_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier->equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MyUnion", identifier, type_object); - delete type_object; - delete identifier; - return TypeObjectFactory::get_instance()->get_type_object("MyUnion", false); -} - -const TypeObject* GetCompleteMyUnionObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyUnion", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_UNION); - - type_object->complete().union_type().union_flags().IS_FINAL(false); - type_object->complete().union_type().union_flags().IS_APPENDABLE(false); - type_object->complete().union_type().union_flags().IS_MUTABLE(false); - type_object->complete().union_type().union_flags().IS_NESTED(false); - type_object->complete().union_type().union_flags().IS_AUTOID_HASH(false); // Unsupported - - type_object->complete().union_type().discriminator().common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().IS_EXTERNAL(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_OPTIONAL(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_KEY(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().IS_DEFAULT(false); // Doesn't apply - - type_object->complete().union_type().discriminator().common().type_id(*GetMyEnumIdentifier(true)); - - MemberId memberId = 0; - CompleteUnionMember cst_basic; - cst_basic.common().member_id(memberId++); - cst_basic.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_basic.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_basic.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_basic.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - cst_basic.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cst_basic.common().member_flags().IS_KEY(false); // Doesn't apply - cst_basic.common().member_flags().IS_DEFAULT(false); - cst_basic.common().type_id(*GetBasicStructIdentifier(true)); - cst_basic.common().label_seq().emplace_back(::A); - - - cst_basic.detail().name("basic"); - - type_object->complete().union_type().member_seq().emplace_back(cst_basic); - - CompleteUnionMember cst_complex; - cst_complex.common().member_id(memberId++); - cst_complex.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_complex.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_complex.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_complex.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - cst_complex.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cst_complex.common().member_flags().IS_KEY(false); // Doesn't apply - cst_complex.common().member_flags().IS_DEFAULT(false); - cst_complex.common().type_id(*GetComplexStructIdentifier(true)); - cst_complex.common().label_seq().emplace_back(::B); - cst_complex.common().label_seq().emplace_back(::C); - - - cst_complex.detail().name("complex"); - - type_object->complete().union_type().member_seq().emplace_back(cst_complex); - - - // Header - type_object->complete().union_type().header().detail().type_name("MyUnion"); - - TypeIdentifier* identifier = new TypeIdentifier(); - identifier->_d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().union_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier->equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MyUnion", identifier, type_object); - delete type_object; - delete identifier; - return TypeObjectFactory::get_instance()->get_type_object("MyUnion", true); -} - - - -const TypeIdentifier* GetMyUnion2Identifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("MyUnion2", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetMyUnion2Object(complete); - return TypeObjectFactory::get_instance()->get_type_identifier("MyUnion2", complete); -} - -const TypeObject* GetMyUnion2Object(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyUnion2", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteMyUnion2Object(); - } - // else - return GetMinimalMyUnion2Object(); -} - -const TypeObject* GetMinimalMyUnion2Object() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyUnion2", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_UNION); - - type_object->minimal().union_type().union_flags().IS_FINAL(false); - type_object->minimal().union_type().union_flags().IS_APPENDABLE(false); - type_object->minimal().union_type().union_flags().IS_MUTABLE(false); - type_object->minimal().union_type().union_flags().IS_NESTED(false); - type_object->minimal().union_type().union_flags().IS_AUTOID_HASH(false); // Unsupported - - type_object->minimal().union_type().discriminator().common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().IS_EXTERNAL(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_OPTIONAL(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_KEY(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().IS_DEFAULT(false); // Doesn't apply - - type_object->minimal().union_type().discriminator().common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint8_t", false)); - - MemberId memberId = 0; - MinimalUnionMember mst_uno; - mst_uno.common().member_id(memberId++); - mst_uno.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_uno.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_uno.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_uno.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - mst_uno.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mst_uno.common().member_flags().IS_KEY(false); // Doesn't apply - mst_uno.common().member_flags().IS_DEFAULT(false); - mst_uno.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - mst_uno.common().label_seq().emplace_back(A); - - MD5 uno_hash("uno"); - for(int i = 0; i < 4; ++i) - { - mst_uno.detail().name_hash()[i] = uno_hash.digest[i]; - } - type_object->minimal().union_type().member_seq().emplace_back(mst_uno); - - MinimalUnionMember mst_imString; - mst_imString.common().member_id(memberId++); - mst_imString.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_imString.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_imString.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_imString.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - mst_imString.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mst_imString.common().member_flags().IS_KEY(false); // Doesn't apply - mst_imString.common().member_flags().IS_DEFAULT(false); - mst_imString.common().type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, false)); - - mst_imString.common().label_seq().emplace_back(B); - - MD5 imString_hash("imString"); - for(int i = 0; i < 4; ++i) - { - mst_imString.detail().name_hash()[i] = imString_hash.digest[i]; - } - type_object->minimal().union_type().member_seq().emplace_back(mst_imString); - - MinimalUnionMember mst_tres; - mst_tres.common().member_id(memberId++); - mst_tres.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_tres.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_tres.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_tres.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - mst_tres.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mst_tres.common().member_flags().IS_KEY(false); // Doesn't apply - mst_tres.common().member_flags().IS_DEFAULT(false); - mst_tres.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - mst_tres.common().label_seq().emplace_back(C); - - MD5 tres_hash("tres"); - for(int i = 0; i < 4; ++i) - { - mst_tres.detail().name_hash()[i] = tres_hash.digest[i]; - } - type_object->minimal().union_type().member_seq().emplace_back(mst_tres); - - - // Header - //type_object->minimal().union_type().header().detail()... // Empty - - TypeIdentifier* identifier = new TypeIdentifier(); - identifier->_d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().union_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier->equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MyUnion2", identifier, type_object); - delete type_object; - delete identifier; - return TypeObjectFactory::get_instance()->get_type_object("MyUnion2", false); -} - -const TypeObject* GetCompleteMyUnion2Object() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyUnion2", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_UNION); - - type_object->complete().union_type().union_flags().IS_FINAL(false); - type_object->complete().union_type().union_flags().IS_APPENDABLE(false); - type_object->complete().union_type().union_flags().IS_MUTABLE(false); - type_object->complete().union_type().union_flags().IS_NESTED(false); - type_object->complete().union_type().union_flags().IS_AUTOID_HASH(false); // Unsupported - - type_object->complete().union_type().discriminator().common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().IS_EXTERNAL(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_OPTIONAL(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_KEY(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().IS_DEFAULT(false); // Doesn't apply - - type_object->complete().union_type().discriminator().common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint8_t", false)); - - MemberId memberId = 0; - CompleteUnionMember cst_uno; - cst_uno.common().member_id(memberId++); - cst_uno.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_uno.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_uno.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_uno.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - cst_uno.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cst_uno.common().member_flags().IS_KEY(false); // Doesn't apply - cst_uno.common().member_flags().IS_DEFAULT(false); - cst_uno.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - cst_uno.common().label_seq().emplace_back(A); - - - cst_uno.detail().name("uno"); - - type_object->complete().union_type().member_seq().emplace_back(cst_uno); - - CompleteUnionMember cst_imString; - cst_imString.common().member_id(memberId++); - cst_imString.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_imString.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_imString.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_imString.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - cst_imString.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cst_imString.common().member_flags().IS_KEY(false); // Doesn't apply - cst_imString.common().member_flags().IS_DEFAULT(false); - cst_imString.common().type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, false)); - cst_imString.common().label_seq().emplace_back(B); - - - cst_imString.detail().name("imString"); - - type_object->complete().union_type().member_seq().emplace_back(cst_imString); - - CompleteUnionMember cst_tres; - cst_tres.common().member_id(memberId++); - cst_tres.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_tres.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_tres.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_tres.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - cst_tres.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cst_tres.common().member_flags().IS_KEY(false); // Doesn't apply - cst_tres.common().member_flags().IS_DEFAULT(false); - cst_tres.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - cst_tres.common().label_seq().emplace_back(C); - - - cst_tres.detail().name("tres"); - - type_object->complete().union_type().member_seq().emplace_back(cst_tres); - - - // Header - type_object->complete().union_type().header().detail().type_name("MyUnion2"); - - TypeIdentifier* identifier = new TypeIdentifier(); - identifier->_d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().union_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier->equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MyUnion2", identifier, type_object); - delete type_object; - delete identifier; - return TypeObjectFactory::get_instance()->get_type_object("MyUnion2", true); -} - - - -const TypeIdentifier* GetCompleteStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("CompleteStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetCompleteStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("CompleteStruct", complete); -} - -const TypeObject* GetCompleteStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("CompleteStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteCompleteStructObject(); - } - //else - return GetMinimalCompleteStructObject(); -} - -const TypeObject* GetMinimalCompleteStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("CompleteStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_union; - mst_my_union.common().member_id(memberId++); - mst_my_union.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_union.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_union.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_union.common().member_flags().IS_OPTIONAL(false); - mst_my_union.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_union.common().member_flags().IS_KEY(false); - mst_my_union.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_union.common().member_type_id(*GetMyUnionIdentifier(false)); - - MD5 my_union_hash("my_union"); - for(int i = 0; i < 4; ++i) - { - mst_my_union.detail().name_hash()[i] = my_union_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_union); - - MinimalStructMember mst_my_union_2; - mst_my_union_2.common().member_id(memberId++); - mst_my_union_2.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_union_2.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_union_2.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_union_2.common().member_flags().IS_OPTIONAL(false); - mst_my_union_2.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_union_2.common().member_flags().IS_KEY(false); - mst_my_union_2.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_union_2.common().member_type_id(*GetMyUnion2Identifier(false)); - - MD5 my_union_2_hash("my_union_2"); - for(int i = 0; i < 4; ++i) - { - mst_my_union_2.detail().name_hash()[i] = my_union_2_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_union_2); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("CompleteStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("CompleteStruct", false); -} - -const TypeObject* GetCompleteCompleteStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("CompleteStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_union; - cst_my_union.common().member_id(memberId++); - cst_my_union.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_union.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_union.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_union.common().member_flags().IS_OPTIONAL(false); - cst_my_union.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_union.common().member_flags().IS_KEY(false); - cst_my_union.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_union.common().member_type_id(*GetMyUnionIdentifier(true)); - - cst_my_union.detail().name("my_union"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_union); - - CompleteStructMember cst_my_union_2; - cst_my_union_2.common().member_id(memberId++); - cst_my_union_2.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_union_2.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_union_2.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_union_2.common().member_flags().IS_OPTIONAL(false); - cst_my_union_2.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_union_2.common().member_flags().IS_KEY(false); - cst_my_union_2.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_union_2.common().member_type_id(*GetMyUnion2Identifier(true)); - - cst_my_union_2.detail().name("my_union_2"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_union_2); - - - // Header - type_object->complete().struct_type().header().detail().type_name("CompleteStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("CompleteStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("CompleteStruct", true); -} - - - -const TypeIdentifier* GetKeyedStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("KeyedStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetKeyedStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("KeyedStruct", complete); -} - -const TypeObject* GetKeyedStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("KeyedStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteKeyedStructObject(); - } - //else - return GetMinimalKeyedStructObject(); -} - -const TypeObject* GetMinimalKeyedStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("KeyedStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_key; - mst_key.common().member_id(memberId++); - mst_key.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_key.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_key.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_key.common().member_flags().IS_OPTIONAL(false); - mst_key.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_key.common().member_flags().IS_KEY(true); - mst_key.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_key.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint8_t", false)); - - - MD5 key_hash("key"); - for(int i = 0; i < 4; ++i) - { - mst_key.detail().name_hash()[i] = key_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_key); - - MinimalStructMember mst_basic; - mst_basic.common().member_id(memberId++); - mst_basic.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_basic.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_basic.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_basic.common().member_flags().IS_OPTIONAL(false); - mst_basic.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_basic.common().member_flags().IS_KEY(false); - mst_basic.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_basic.common().member_type_id(*GetBasicStructIdentifier(false)); - - MD5 basic_hash("basic"); - for(int i = 0; i < 4; ++i) - { - mst_basic.detail().name_hash()[i] = basic_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_basic); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("KeyedStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("KeyedStruct", false); -} - -const TypeObject* GetCompleteKeyedStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("KeyedStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_key; - cst_key.common().member_id(memberId++); - cst_key.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_key.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_key.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_key.common().member_flags().IS_OPTIONAL(false); - cst_key.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_key.common().member_flags().IS_KEY(true); - cst_key.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_key.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint8_t", false)); - - - cst_key.detail().name("key"); - - { - AppliedAnnotation ann; - //ann.annotation_typeid(GetkeyIdentifier(true)); - ann.annotation_typeid(*TypeObjectFactory::get_instance()->get_type_identifier_trying_complete("key")); - { - AppliedAnnotationParameter annParam; - MD5 message_hash("value"); - for(int i = 0; i < 4; ++i) - { - annParam.paramname_hash()[i] = message_hash.digest[i]; - } - AnnotationParameterValue paramValue; - paramValue._d(TK_BOOLEAN); - paramValue.from_string("true"); - annParam.value(paramValue); - ann.param_seq().push_back(annParam); - } - - cst_key.detail().ann_custom().push_back(ann); - } - - - type_object->complete().struct_type().member_seq().emplace_back(cst_key); - - CompleteStructMember cst_basic; - cst_basic.common().member_id(memberId++); - cst_basic.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_basic.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_basic.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_basic.common().member_flags().IS_OPTIONAL(false); - cst_basic.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_basic.common().member_flags().IS_KEY(false); - cst_basic.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_basic.common().member_type_id(*GetBasicStructIdentifier(true)); - - cst_basic.detail().name("basic"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_basic); - - - // Header - type_object->complete().struct_type().header().detail().type_name("KeyedStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("KeyedStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("KeyedStruct", true); -} diff --git a/test/unittest/dynamic_types/idl/TestTypeObject.h b/test/unittest/dynamic_types/idl/TestTypeObject.h deleted file mode 100644 index 9d4dc990651..00000000000 --- a/test/unittest/dynamic_types/idl/TestTypeObject.h +++ /dev/null @@ -1,147 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file TestTypeObject.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifndef _FAST_DDS_GENERATED_TEST_TYPE_OBJECT_H_ -#define _FAST_DDS_GENERATED_TEST_TYPE_OBJECT_H_ - - -#include -#include - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif -#else -#define eProsima_user_DllExport -#endif - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(Test_SOURCE) -#define Test_DllAPI __declspec( dllexport ) -#else -#define Test_DllAPI __declspec( dllimport ) -#endif // Test_SOURCE -#else -#define Test_DllAPI -#endif -#else -#define Test_DllAPI -#endif // _WIN32 - -using namespace eprosima::fastrtps::types; - -eProsima_user_DllExport void registerTestTypes(); - -eProsima_user_DllExport const TypeIdentifier* GetMyEnumIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMyEnumObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalMyEnumObject(); -eProsima_user_DllExport const TypeObject* GetCompleteMyEnumObject(); - -eProsima_user_DllExport const TypeIdentifier* GetMyAliasEnumIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMyAliasEnumObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalMyAliasEnumObject(); -eProsima_user_DllExport const TypeObject* GetCompleteMyAliasEnumObject(); - -eProsima_user_DllExport const TypeIdentifier* GetMyAliasEnum2Identifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMyAliasEnum2Object(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalMyAliasEnum2Object(); -eProsima_user_DllExport const TypeObject* GetCompleteMyAliasEnum2Object(); - -eProsima_user_DllExport const TypeIdentifier* GetMyAliasEnum3Identifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMyAliasEnum3Object(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalMyAliasEnum3Object(); -eProsima_user_DllExport const TypeObject* GetCompleteMyAliasEnum3Object(); - - - -eProsima_user_DllExport const TypeIdentifier* GetBasicStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetBasicStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalBasicStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteBasicStructObject(); - -eProsima_user_DllExport const TypeIdentifier* GetMyOctetArray500Identifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMyOctetArray500Object(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalMyOctetArray500Object(); -eProsima_user_DllExport const TypeObject* GetCompleteMyOctetArray500Object(); - -eProsima_user_DllExport const TypeIdentifier* GetBSAlias5Identifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetBSAlias5Object(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalBSAlias5Object(); -eProsima_user_DllExport const TypeObject* GetCompleteBSAlias5Object(); - -eProsima_user_DllExport const TypeIdentifier* GetMA3Identifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMA3Object(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalMA3Object(); -eProsima_user_DllExport const TypeObject* GetCompleteMA3Object(); - -eProsima_user_DllExport const TypeIdentifier* GetMyMiniArrayIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMyMiniArrayObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalMyMiniArrayObject(); -eProsima_user_DllExport const TypeObject* GetCompleteMyMiniArrayObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetMySequenceLongIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMySequenceLongObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalMySequenceLongObject(); -eProsima_user_DllExport const TypeObject* GetCompleteMySequenceLongObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetComplexStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetComplexStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalComplexStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteComplexStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetMyUnionIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMyUnionObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalMyUnionObject(); -eProsima_user_DllExport const TypeObject* GetCompleteMyUnionObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetMyUnion2Identifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMyUnion2Object(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalMyUnion2Object(); -eProsima_user_DllExport const TypeObject* GetCompleteMyUnion2Object(); - - - -eProsima_user_DllExport const TypeIdentifier* GetCompleteStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetCompleteStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalCompleteStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteCompleteStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetKeyedStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetKeyedStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalKeyedStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteKeyedStructObject(); - - -#endif // _FAST_DDS_GENERATED_TEST_TYPE_OBJECT_H_ \ No newline at end of file diff --git a/test/unittest/dynamic_types/idl/Testv1.cxx b/test/unittest/dynamic_types/idl/Testv1.cxx deleted file mode 100644 index d5f720de3dd..00000000000 --- a/test/unittest/dynamic_types/idl/Testv1.cxx +++ /dev/null @@ -1,3744 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file Test.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "Test.h" - -#if FASTCDR_VERSION_MAJOR == 1 - -#include "TestTypeObject.h" - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - -namespace helper { namespace internal { - -enum class Size { - UInt8, - UInt16, - UInt32, - UInt64, -}; - -constexpr Size get_size(int s) { - return (s <= 8 ) ? Size::UInt8: - (s <= 16) ? Size::UInt16: - (s <= 32) ? Size::UInt32: Size::UInt64; -} - -template -struct FindTypeH; - -template<> -struct FindTypeH { - using type = std::uint8_t; -}; - -template<> -struct FindTypeH { - using type = std::uint16_t; -}; - -template<> -struct FindTypeH { - using type = std::uint32_t; -}; - -template<> -struct FindTypeH { - using type = std::uint64_t; -}; -} - -template -struct FindType { - using type = typename internal::FindTypeH::type; -}; -} - -#define KeyedStruct_max_cdr_typesize 344ULL; - - - -#define BasicStruct_max_cdr_typesize 336ULL; - -#define ComplexStruct_max_cdr_typesize 18064796ULL; - - -#define CompleteStruct_max_cdr_typesize 18065072ULL; - - - - - - - - - -BasicStruct::BasicStruct() -{ - // boolean m_my_bool - m_my_bool = false; - // octet m_my_octet - m_my_octet = 0; - // short m_my_int16 - m_my_int16 = 0; - // long m_my_int32 - m_my_int32 = 0; - // long long m_my_int64 - m_my_int64 = 0; - // unsigned short m_my_uint16 - m_my_uint16 = 0; - // unsigned long m_my_uint32 - m_my_uint32 = 0; - // unsigned long long m_my_uint64 - m_my_uint64 = 0; - // float m_my_float32 - m_my_float32 = 0.0; - // double m_my_float64 - m_my_float64 = 0.0; - // long double m_my_float128 - m_my_float128 = 0.0; - // char m_my_char - m_my_char = 0; - // /type_d() m_my_string - - - // Just to register all known types - registerTestTypes(); -} - -BasicStruct::~BasicStruct() -{ -} - -BasicStruct::BasicStruct( - const BasicStruct& x) -{ - m_my_bool = x.m_my_bool; - - - m_my_octet = x.m_my_octet; - - - m_my_int16 = x.m_my_int16; - - - m_my_int32 = x.m_my_int32; - - - m_my_int64 = x.m_my_int64; - - - m_my_uint16 = x.m_my_uint16; - - - m_my_uint32 = x.m_my_uint32; - - - m_my_uint64 = x.m_my_uint64; - - - m_my_float32 = x.m_my_float32; - - - m_my_float64 = x.m_my_float64; - - - m_my_float128 = x.m_my_float128; - - - m_my_char = x.m_my_char; - - - m_my_string = x.m_my_string; - -} - -BasicStruct::BasicStruct( - BasicStruct&& x) noexcept -{ - m_my_bool = x.m_my_bool; - - - m_my_octet = x.m_my_octet; - - - m_my_int16 = x.m_my_int16; - - - m_my_int32 = x.m_my_int32; - - - m_my_int64 = x.m_my_int64; - - - m_my_uint16 = x.m_my_uint16; - - - m_my_uint32 = x.m_my_uint32; - - - m_my_uint64 = x.m_my_uint64; - - - m_my_float32 = x.m_my_float32; - - - m_my_float64 = x.m_my_float64; - - - m_my_float128 = x.m_my_float128; - - - m_my_char = x.m_my_char; - - - m_my_string = std::move(x.m_my_string); - -} - -BasicStruct& BasicStruct::operator =( - const BasicStruct& x) -{ - m_my_bool = x.m_my_bool; - - - m_my_octet = x.m_my_octet; - - - m_my_int16 = x.m_my_int16; - - - m_my_int32 = x.m_my_int32; - - - m_my_int64 = x.m_my_int64; - - - m_my_uint16 = x.m_my_uint16; - - - m_my_uint32 = x.m_my_uint32; - - - m_my_uint64 = x.m_my_uint64; - - - m_my_float32 = x.m_my_float32; - - - m_my_float64 = x.m_my_float64; - - - m_my_float128 = x.m_my_float128; - - - m_my_char = x.m_my_char; - - - m_my_string = x.m_my_string; - - return *this; -} - -BasicStruct& BasicStruct::operator =( - BasicStruct&& x) noexcept -{ - m_my_bool = x.m_my_bool; - - - m_my_octet = x.m_my_octet; - - - m_my_int16 = x.m_my_int16; - - - m_my_int32 = x.m_my_int32; - - - m_my_int64 = x.m_my_int64; - - - m_my_uint16 = x.m_my_uint16; - - - m_my_uint32 = x.m_my_uint32; - - - m_my_uint64 = x.m_my_uint64; - - - m_my_float32 = x.m_my_float32; - - - m_my_float64 = x.m_my_float64; - - - m_my_float128 = x.m_my_float128; - - - m_my_char = x.m_my_char; - - - m_my_string = std::move(x.m_my_string); - - return *this; -} - -bool BasicStruct::operator ==( - const BasicStruct& x) const -{ - return (m_my_bool == x.m_my_bool && - m_my_octet == x.m_my_octet && - m_my_int16 == x.m_my_int16 && - m_my_int32 == x.m_my_int32 && - m_my_int64 == x.m_my_int64 && - m_my_uint16 == x.m_my_uint16 && - m_my_uint32 == x.m_my_uint32 && - m_my_uint64 == x.m_my_uint64 && - m_my_float32 == x.m_my_float32 && - m_my_float64 == x.m_my_float64 && - m_my_float128 == x.m_my_float128 && - m_my_char == x.m_my_char && - m_my_string == x.m_my_string); -} - -bool BasicStruct::operator !=( - const BasicStruct& x) const -{ - return !(*this == x); -} - -size_t BasicStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return BasicStruct_max_cdr_typesize; -} - -size_t BasicStruct::getCdrSerializedSize( - const BasicStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - current_alignment += 2 + eprosima::fastcdr::Cdr::alignment(current_alignment, 2); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += 8 + eprosima::fastcdr::Cdr::alignment(current_alignment, 8); - - - current_alignment += 2 + eprosima::fastcdr::Cdr::alignment(current_alignment, 2); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += 8 + eprosima::fastcdr::Cdr::alignment(current_alignment, 8); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += 8 + eprosima::fastcdr::Cdr::alignment(current_alignment, 8); - - - current_alignment += 16 + eprosima::fastcdr::Cdr::alignment(current_alignment, 8); // 128 bits, but aligned as 64 - - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + data.my_string().size() + 1; - - - return current_alignment - initial_alignment; -} - - -void BasicStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_bool; - - scdr << m_my_octet; - - scdr << m_my_int16; - - scdr << m_my_int32; - - scdr << m_my_int64; - - scdr << m_my_uint16; - - scdr << m_my_uint32; - - scdr << m_my_uint64; - - scdr << m_my_float32; - - scdr << m_my_float64; - - scdr << m_my_float128; - - scdr << m_my_char; - - scdr << m_my_string.c_str(); - -} - -void BasicStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_bool; - - - - dcdr >> m_my_octet; - - - - dcdr >> m_my_int16; - - - - dcdr >> m_my_int32; - - - - dcdr >> m_my_int64; - - - - dcdr >> m_my_uint16; - - - - dcdr >> m_my_uint32; - - - - dcdr >> m_my_uint64; - - - - dcdr >> m_my_float32; - - - - dcdr >> m_my_float64; - - - - dcdr >> m_my_float128; - - - - dcdr >> m_my_char; - - - - dcdr >> m_my_string; - - -} - - -bool BasicStruct::isKeyDefined() -{ - return false; -} - -void BasicStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member my_bool - * @param _my_bool New value for member my_bool - */ -void BasicStruct::my_bool( - bool _my_bool) -{ - m_my_bool = _my_bool; -} - -/*! - * @brief This function returns the value of member my_bool - * @return Value of member my_bool - */ -bool BasicStruct::my_bool() const -{ - return m_my_bool; -} - -/*! - * @brief This function returns a reference to member my_bool - * @return Reference to member my_bool - */ -bool& BasicStruct::my_bool() -{ - return m_my_bool; -} - - -/*! - * @brief This function sets a value in member my_octet - * @param _my_octet New value for member my_octet - */ -void BasicStruct::my_octet( - uint8_t _my_octet) -{ - m_my_octet = _my_octet; -} - -/*! - * @brief This function returns the value of member my_octet - * @return Value of member my_octet - */ -uint8_t BasicStruct::my_octet() const -{ - return m_my_octet; -} - -/*! - * @brief This function returns a reference to member my_octet - * @return Reference to member my_octet - */ -uint8_t& BasicStruct::my_octet() -{ - return m_my_octet; -} - - -/*! - * @brief This function sets a value in member my_int16 - * @param _my_int16 New value for member my_int16 - */ -void BasicStruct::my_int16( - int16_t _my_int16) -{ - m_my_int16 = _my_int16; -} - -/*! - * @brief This function returns the value of member my_int16 - * @return Value of member my_int16 - */ -int16_t BasicStruct::my_int16() const -{ - return m_my_int16; -} - -/*! - * @brief This function returns a reference to member my_int16 - * @return Reference to member my_int16 - */ -int16_t& BasicStruct::my_int16() -{ - return m_my_int16; -} - - -/*! - * @brief This function sets a value in member my_int32 - * @param _my_int32 New value for member my_int32 - */ -void BasicStruct::my_int32( - int32_t _my_int32) -{ - m_my_int32 = _my_int32; -} - -/*! - * @brief This function returns the value of member my_int32 - * @return Value of member my_int32 - */ -int32_t BasicStruct::my_int32() const -{ - return m_my_int32; -} - -/*! - * @brief This function returns a reference to member my_int32 - * @return Reference to member my_int32 - */ -int32_t& BasicStruct::my_int32() -{ - return m_my_int32; -} - - -/*! - * @brief This function sets a value in member my_int64 - * @param _my_int64 New value for member my_int64 - */ -void BasicStruct::my_int64( - int64_t _my_int64) -{ - m_my_int64 = _my_int64; -} - -/*! - * @brief This function returns the value of member my_int64 - * @return Value of member my_int64 - */ -int64_t BasicStruct::my_int64() const -{ - return m_my_int64; -} - -/*! - * @brief This function returns a reference to member my_int64 - * @return Reference to member my_int64 - */ -int64_t& BasicStruct::my_int64() -{ - return m_my_int64; -} - - -/*! - * @brief This function sets a value in member my_uint16 - * @param _my_uint16 New value for member my_uint16 - */ -void BasicStruct::my_uint16( - uint16_t _my_uint16) -{ - m_my_uint16 = _my_uint16; -} - -/*! - * @brief This function returns the value of member my_uint16 - * @return Value of member my_uint16 - */ -uint16_t BasicStruct::my_uint16() const -{ - return m_my_uint16; -} - -/*! - * @brief This function returns a reference to member my_uint16 - * @return Reference to member my_uint16 - */ -uint16_t& BasicStruct::my_uint16() -{ - return m_my_uint16; -} - - -/*! - * @brief This function sets a value in member my_uint32 - * @param _my_uint32 New value for member my_uint32 - */ -void BasicStruct::my_uint32( - uint32_t _my_uint32) -{ - m_my_uint32 = _my_uint32; -} - -/*! - * @brief This function returns the value of member my_uint32 - * @return Value of member my_uint32 - */ -uint32_t BasicStruct::my_uint32() const -{ - return m_my_uint32; -} - -/*! - * @brief This function returns a reference to member my_uint32 - * @return Reference to member my_uint32 - */ -uint32_t& BasicStruct::my_uint32() -{ - return m_my_uint32; -} - - -/*! - * @brief This function sets a value in member my_uint64 - * @param _my_uint64 New value for member my_uint64 - */ -void BasicStruct::my_uint64( - uint64_t _my_uint64) -{ - m_my_uint64 = _my_uint64; -} - -/*! - * @brief This function returns the value of member my_uint64 - * @return Value of member my_uint64 - */ -uint64_t BasicStruct::my_uint64() const -{ - return m_my_uint64; -} - -/*! - * @brief This function returns a reference to member my_uint64 - * @return Reference to member my_uint64 - */ -uint64_t& BasicStruct::my_uint64() -{ - return m_my_uint64; -} - - -/*! - * @brief This function sets a value in member my_float32 - * @param _my_float32 New value for member my_float32 - */ -void BasicStruct::my_float32( - float _my_float32) -{ - m_my_float32 = _my_float32; -} - -/*! - * @brief This function returns the value of member my_float32 - * @return Value of member my_float32 - */ -float BasicStruct::my_float32() const -{ - return m_my_float32; -} - -/*! - * @brief This function returns a reference to member my_float32 - * @return Reference to member my_float32 - */ -float& BasicStruct::my_float32() -{ - return m_my_float32; -} - - -/*! - * @brief This function sets a value in member my_float64 - * @param _my_float64 New value for member my_float64 - */ -void BasicStruct::my_float64( - double _my_float64) -{ - m_my_float64 = _my_float64; -} - -/*! - * @brief This function returns the value of member my_float64 - * @return Value of member my_float64 - */ -double BasicStruct::my_float64() const -{ - return m_my_float64; -} - -/*! - * @brief This function returns a reference to member my_float64 - * @return Reference to member my_float64 - */ -double& BasicStruct::my_float64() -{ - return m_my_float64; -} - - -/*! - * @brief This function sets a value in member my_float128 - * @param _my_float128 New value for member my_float128 - */ -void BasicStruct::my_float128( - long double _my_float128) -{ - m_my_float128 = _my_float128; -} - -/*! - * @brief This function returns the value of member my_float128 - * @return Value of member my_float128 - */ -long double BasicStruct::my_float128() const -{ - return m_my_float128; -} - -/*! - * @brief This function returns a reference to member my_float128 - * @return Reference to member my_float128 - */ -long double& BasicStruct::my_float128() -{ - return m_my_float128; -} - - -/*! - * @brief This function sets a value in member my_char - * @param _my_char New value for member my_char - */ -void BasicStruct::my_char( - char _my_char) -{ - m_my_char = _my_char; -} - -/*! - * @brief This function returns the value of member my_char - * @return Value of member my_char - */ -char BasicStruct::my_char() const -{ - return m_my_char; -} - -/*! - * @brief This function returns a reference to member my_char - * @return Reference to member my_char - */ -char& BasicStruct::my_char() -{ - return m_my_char; -} - - -/*! - * @brief This function copies the value in member my_string - * @param _my_string New value to be copied in member my_string - */ -void BasicStruct::my_string( - const std::string& _my_string) -{ - m_my_string = _my_string; -} - -/*! - * @brief This function moves the value in member my_string - * @param _my_string New value to be moved in member my_string - */ -void BasicStruct::my_string( - std::string&& _my_string) -{ - m_my_string = std::move(_my_string); -} - -/*! - * @brief This function returns a constant reference to member my_string - * @return Constant reference to member my_string - */ -const std::string& BasicStruct::my_string() const -{ - return m_my_string; -} - -/*! - * @brief This function returns a reference to member my_string - * @return Reference to member my_string - */ -std::string& BasicStruct::my_string() -{ - return m_my_string; -} - - - - - - - - - - - - -ComplexStruct::ComplexStruct() -{ - // octet m_my_octet - m_my_octet = 0; - // BasicStruct m_my_basic_struct - - // MyAliasEnum m_my_alias_enum - m_my_alias_enum = ::A; - // MyEnum m_my_enum - m_my_enum = ::A; - // sequence m_my_sequence_octet - - // sequence m_my_sequence_struct - - // char m_my_array_octet - memset(&m_my_array_octet, 0, ((500) * (5) * (4)) * 1); - // MyOctetArray500 m_my_octet_array_500 - memset(&m_my_octet_array_500, 0, ((500)) * 1); - // BasicStruct m_my_array_struct - - // map m_my_map_octet_short - - // map m_my_map_long_struct - - // map>> m_my_map_long_seq_octet - - // map m_my_map_long_octet_array_500 - - // map> m_my_map_long_lol_type - - // /type_d() m_my_small_string_8 - - // /type_d() m_my_large_string_8 - - // /type_d() m_my_array_string - - // MA3 m_multi_alias_array_42 - memset(&m_multi_alias_array_42, 0, ((42)) * 4); - // MyMiniArray m_my_array_arrays - - // MySequenceLong m_my_sequences_array - - - // Just to register all known types - registerTestTypes(); -} - -ComplexStruct::~ComplexStruct() -{ -} - -ComplexStruct::ComplexStruct( - const ComplexStruct& x) -{ - m_my_octet = x.m_my_octet; - - - m_my_basic_struct = x.m_my_basic_struct; - - - m_my_alias_enum = x.m_my_alias_enum; - - - m_my_enum = x.m_my_enum; - - - m_my_sequence_octet = x.m_my_sequence_octet; - - - m_my_sequence_struct = x.m_my_sequence_struct; - - - m_my_array_octet = x.m_my_array_octet; - - - m_my_octet_array_500 = x.m_my_octet_array_500; - - - m_my_array_struct = x.m_my_array_struct; - - - m_my_map_octet_short = x.m_my_map_octet_short; - - - m_my_map_long_struct = x.m_my_map_long_struct; - - - m_my_map_long_seq_octet = x.m_my_map_long_seq_octet; - - - m_my_map_long_octet_array_500 = x.m_my_map_long_octet_array_500; - - - m_my_map_long_lol_type = x.m_my_map_long_lol_type; - - - m_my_small_string_8 = x.m_my_small_string_8; - - - m_my_large_string_8 = x.m_my_large_string_8; - - - m_my_array_string = x.m_my_array_string; - - - m_multi_alias_array_42 = x.m_multi_alias_array_42; - - - m_my_array_arrays = x.m_my_array_arrays; - - - m_my_sequences_array = x.m_my_sequences_array; - -} - -ComplexStruct::ComplexStruct( - ComplexStruct&& x) noexcept -{ - m_my_octet = x.m_my_octet; - - - m_my_basic_struct = std::move(x.m_my_basic_struct); - - - m_my_alias_enum = x.m_my_alias_enum; - - - m_my_enum = x.m_my_enum; - - - m_my_sequence_octet = std::move(x.m_my_sequence_octet); - - - m_my_sequence_struct = std::move(x.m_my_sequence_struct); - - - m_my_array_octet = std::move(x.m_my_array_octet); - - - m_my_octet_array_500 = std::move(x.m_my_octet_array_500); - - - m_my_array_struct = std::move(x.m_my_array_struct); - - - m_my_map_octet_short = std::move(x.m_my_map_octet_short); - - - m_my_map_long_struct = std::move(x.m_my_map_long_struct); - - - m_my_map_long_seq_octet = std::move(x.m_my_map_long_seq_octet); - - - m_my_map_long_octet_array_500 = std::move(x.m_my_map_long_octet_array_500); - - - m_my_map_long_lol_type = std::move(x.m_my_map_long_lol_type); - - - m_my_small_string_8 = std::move(x.m_my_small_string_8); - - - m_my_large_string_8 = std::move(x.m_my_large_string_8); - - - m_my_array_string = std::move(x.m_my_array_string); - - - m_multi_alias_array_42 = std::move(x.m_multi_alias_array_42); - - - m_my_array_arrays = std::move(x.m_my_array_arrays); - - - m_my_sequences_array = std::move(x.m_my_sequences_array); - -} - -ComplexStruct& ComplexStruct::operator =( - const ComplexStruct& x) -{ - m_my_octet = x.m_my_octet; - - - m_my_basic_struct = x.m_my_basic_struct; - - - m_my_alias_enum = x.m_my_alias_enum; - - - m_my_enum = x.m_my_enum; - - - m_my_sequence_octet = x.m_my_sequence_octet; - - - m_my_sequence_struct = x.m_my_sequence_struct; - - - m_my_array_octet = x.m_my_array_octet; - - - m_my_octet_array_500 = x.m_my_octet_array_500; - - - m_my_array_struct = x.m_my_array_struct; - - - m_my_map_octet_short = x.m_my_map_octet_short; - - - m_my_map_long_struct = x.m_my_map_long_struct; - - - m_my_map_long_seq_octet = x.m_my_map_long_seq_octet; - - - m_my_map_long_octet_array_500 = x.m_my_map_long_octet_array_500; - - - m_my_map_long_lol_type = x.m_my_map_long_lol_type; - - - m_my_small_string_8 = x.m_my_small_string_8; - - - m_my_large_string_8 = x.m_my_large_string_8; - - - m_my_array_string = x.m_my_array_string; - - - m_multi_alias_array_42 = x.m_multi_alias_array_42; - - - m_my_array_arrays = x.m_my_array_arrays; - - - m_my_sequences_array = x.m_my_sequences_array; - - return *this; -} - -ComplexStruct& ComplexStruct::operator =( - ComplexStruct&& x) noexcept -{ - m_my_octet = x.m_my_octet; - - - m_my_basic_struct = std::move(x.m_my_basic_struct); - - - m_my_alias_enum = x.m_my_alias_enum; - - - m_my_enum = x.m_my_enum; - - - m_my_sequence_octet = std::move(x.m_my_sequence_octet); - - - m_my_sequence_struct = std::move(x.m_my_sequence_struct); - - - m_my_array_octet = std::move(x.m_my_array_octet); - - - m_my_octet_array_500 = std::move(x.m_my_octet_array_500); - - - m_my_array_struct = std::move(x.m_my_array_struct); - - - m_my_map_octet_short = std::move(x.m_my_map_octet_short); - - - m_my_map_long_struct = std::move(x.m_my_map_long_struct); - - - m_my_map_long_seq_octet = std::move(x.m_my_map_long_seq_octet); - - - m_my_map_long_octet_array_500 = std::move(x.m_my_map_long_octet_array_500); - - - m_my_map_long_lol_type = std::move(x.m_my_map_long_lol_type); - - - m_my_small_string_8 = std::move(x.m_my_small_string_8); - - - m_my_large_string_8 = std::move(x.m_my_large_string_8); - - - m_my_array_string = std::move(x.m_my_array_string); - - - m_multi_alias_array_42 = std::move(x.m_multi_alias_array_42); - - - m_my_array_arrays = std::move(x.m_my_array_arrays); - - - m_my_sequences_array = std::move(x.m_my_sequences_array); - - return *this; -} - -bool ComplexStruct::operator ==( - const ComplexStruct& x) const -{ - return (m_my_octet == x.m_my_octet && - m_my_basic_struct == x.m_my_basic_struct && - m_my_alias_enum == x.m_my_alias_enum && - m_my_enum == x.m_my_enum && - m_my_sequence_octet == x.m_my_sequence_octet && - m_my_sequence_struct == x.m_my_sequence_struct && - m_my_array_octet == x.m_my_array_octet && - m_my_octet_array_500 == x.m_my_octet_array_500 && - m_my_array_struct == x.m_my_array_struct && - m_my_map_octet_short == x.m_my_map_octet_short && - m_my_map_long_struct == x.m_my_map_long_struct && - m_my_map_long_seq_octet == x.m_my_map_long_seq_octet && - m_my_map_long_octet_array_500 == x.m_my_map_long_octet_array_500 && - m_my_map_long_lol_type == x.m_my_map_long_lol_type && - m_my_small_string_8 == x.m_my_small_string_8 && - m_my_large_string_8 == x.m_my_large_string_8 && - m_my_array_string == x.m_my_array_string && - m_multi_alias_array_42 == x.m_multi_alias_array_42 && - m_my_array_arrays == x.m_my_array_arrays && - m_my_sequences_array == x.m_my_sequences_array); -} - -bool ComplexStruct::operator !=( - const ComplexStruct& x) const -{ - return !(*this == x); -} - -size_t ComplexStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return ComplexStruct_max_cdr_typesize; -} - -size_t ComplexStruct::getCdrSerializedSize( - const ComplexStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - current_alignment += BasicStruct::getCdrSerializedSize(data.my_basic_struct(), current_alignment); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - if (data.my_sequence_octet().size() > 0) - { - current_alignment += (data.my_sequence_octet().size() * 1) + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - } - - - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - for(size_t a = 0; a < data.my_sequence_struct().size(); ++a) - { - current_alignment += BasicStruct::getCdrSerializedSize(data.my_sequence_struct().at(a), current_alignment); - } - - - - current_alignment += (((500) * (5) * (4)) * 1) + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - - current_alignment += (((500)) * 1) + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - - - for(size_t a = 0; a < data.my_array_struct().size(); ++a) - { - current_alignment += BasicStruct::getCdrSerializedSize(data.my_array_struct().at(a), current_alignment); - - } - - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - for(auto a : data.my_map_octet_short()) - { - (void)a; - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - current_alignment += 2 + eprosima::fastcdr::Cdr::alignment(current_alignment, 2); - - } - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - for(auto a : data.my_map_long_struct()) - { - (void)a; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - current_alignment += BasicStruct::getCdrSerializedSize(a.second, current_alignment); - - } - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - for(auto a : data.my_map_long_seq_octet()) - { - (void)a; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - for(size_t b = 0; b < a.second.size(); ++b) - { - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - if (a.second.at(b).size() > 0) - { - current_alignment += (a.second.at(b).size() * 1) + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - } - - - } - - - } - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - for(auto a : data.my_map_long_octet_array_500()) - { - (void)a; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - current_alignment += (((500)) * 1) + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - } - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - for(auto a : data.my_map_long_lol_type()) - { - (void)a; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - for(auto b : a.second) - { - (void)b; - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - for(size_t c = 0; c < b.second.size(); ++c) - { - current_alignment += BasicStruct::getCdrSerializedSize(b.second.at(c), current_alignment); - - } - - - } - - } - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + data.my_small_string_8().size() + 1; - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + data.my_large_string_8().size() + 1; - - - - for(size_t a = 0; a < data.my_array_string().size(); ++a) - { - - for(size_t b = 0; b < data.my_array_string().at(a).size(); ++b) - { - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + data.my_array_string().at(a).at(b).size() + 1; - - } - - } - - - - current_alignment += (((42)) * 4) + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - - - for(size_t a = 0; a < data.my_array_arrays().size(); ++a) - { - current_alignment += (((2)) * 4) + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - } - - - - - for(size_t a = 0; a < data.my_sequences_array().size(); ++a) - { - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - if (data.my_sequences_array().at(a).size() > 0) - { - current_alignment += (data.my_sequences_array().at(a).size() * 4) + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - } - - - - } - - - - return current_alignment - initial_alignment; -} - - -void ComplexStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_octet; - - scdr << m_my_basic_struct; - - scdr << (uint32_t)m_my_alias_enum; - - scdr << (uint32_t)m_my_enum; - - scdr << m_my_sequence_octet; - - - scdr << m_my_sequence_struct; - - - for (uint32_t d = 0; d < m_my_array_octet.size(); ++d) - { - for (uint32_t e = 0; e < m_my_array_octet[d].size(); ++e) - { - scdr << m_my_array_octet[d][e]; - - } - - } - - - - scdr << m_my_octet_array_500; - - - scdr << m_my_array_struct; - - - scdr << static_cast(m_my_map_octet_short.size()); - for (const auto& pair : m_my_map_octet_short) - { - scdr << pair.first; - scdr << pair.second; - } - - scdr << static_cast(m_my_map_long_struct.size()); - for (const auto& pair : m_my_map_long_struct) - { - scdr << pair.first; - scdr << pair.second; - } - - scdr << static_cast(m_my_map_long_seq_octet.size()); - for (const auto& pair : m_my_map_long_seq_octet) - { - scdr << pair.first; - scdr << pair.second; - } - - scdr << static_cast(m_my_map_long_octet_array_500.size()); - for (const auto& pair : m_my_map_long_octet_array_500) - { - scdr << pair.first; - scdr << pair.second; - } - - scdr << static_cast(m_my_map_long_lol_type.size()); - for (const auto& pair : m_my_map_long_lol_type) - { - scdr << pair.first; - scdr << pair.second; - } - - scdr << m_my_small_string_8.c_str(); - - scdr << m_my_large_string_8.c_str(); - - for (uint32_t g = 0; g < m_my_array_string.size(); ++g) - { - for (const auto& str : m_my_array_string[g]) - { - scdr << str.c_str(); - } - - - } - - - - - scdr.serializeArray(reinterpret_cast(m_multi_alias_array_42.data()), m_multi_alias_array_42.size()); - - - scdr << m_my_array_arrays; - - - scdr << m_my_sequences_array; - - -} - -void ComplexStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_octet; - - - - dcdr >> m_my_basic_struct; - - - - { - uint32_t enum_value = 0; - dcdr >> enum_value; - m_my_alias_enum = (MyAliasEnum)enum_value; - } - - - - { - uint32_t enum_value = 0; - dcdr >> enum_value; - m_my_enum = (MyEnum)enum_value; - } - - - - dcdr >> m_my_sequence_octet; - - - - dcdr >> m_my_sequence_struct; - - - - for (uint32_t i = 0; i < m_my_array_octet.size(); ++i) - { - for (uint32_t j = 0; j < m_my_array_octet[i].size(); ++j) - { - dcdr >> m_my_array_octet[i][j]; - - } - - } - - - - - dcdr >> m_my_octet_array_500; - - - - dcdr >> m_my_array_struct; - - - - - dcdr >> m_my_map_octet_short; - - - - - dcdr >> m_my_map_long_struct; - - - - - dcdr >> m_my_map_long_seq_octet; - - - - - dcdr >> m_my_map_long_octet_array_500; - - - - - dcdr >> m_my_map_long_lol_type; - - - - { - std::string aux; - dcdr >> aux; - m_my_small_string_8 = aux.c_str(); - } - - - - { - std::string aux; - dcdr >> aux; - m_my_large_string_8 = aux.c_str(); - } - - - - for (uint32_t l = 0; l < m_my_array_string.size(); ++l) - { - for (auto& str : m_my_array_string[l]) - { - { - std::string aux_str; - dcdr >> aux_str; - str = aux_str.c_str(); - } - - } - - - } - - - - - - dcdr.deserializeArray(reinterpret_cast(m_multi_alias_array_42.data()), m_multi_alias_array_42.size()); - - - - dcdr >> m_my_array_arrays; - - - - dcdr >> m_my_sequences_array; - - -} - - -bool ComplexStruct::isKeyDefined() -{ - return false; -} - -void ComplexStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member my_octet - * @param _my_octet New value for member my_octet - */ -void ComplexStruct::my_octet( - uint8_t _my_octet) -{ - m_my_octet = _my_octet; -} - -/*! - * @brief This function returns the value of member my_octet - * @return Value of member my_octet - */ -uint8_t ComplexStruct::my_octet() const -{ - return m_my_octet; -} - -/*! - * @brief This function returns a reference to member my_octet - * @return Reference to member my_octet - */ -uint8_t& ComplexStruct::my_octet() -{ - return m_my_octet; -} - - -/*! - * @brief This function copies the value in member my_basic_struct - * @param _my_basic_struct New value to be copied in member my_basic_struct - */ -void ComplexStruct::my_basic_struct( - const BasicStruct& _my_basic_struct) -{ - m_my_basic_struct = _my_basic_struct; -} - -/*! - * @brief This function moves the value in member my_basic_struct - * @param _my_basic_struct New value to be moved in member my_basic_struct - */ -void ComplexStruct::my_basic_struct( - BasicStruct&& _my_basic_struct) -{ - m_my_basic_struct = std::move(_my_basic_struct); -} - -/*! - * @brief This function returns a constant reference to member my_basic_struct - * @return Constant reference to member my_basic_struct - */ -const BasicStruct& ComplexStruct::my_basic_struct() const -{ - return m_my_basic_struct; -} - -/*! - * @brief This function returns a reference to member my_basic_struct - * @return Reference to member my_basic_struct - */ -BasicStruct& ComplexStruct::my_basic_struct() -{ - return m_my_basic_struct; -} - - -/*! - * @brief This function sets a value in member my_alias_enum - * @param _my_alias_enum New value for member my_alias_enum - */ -void ComplexStruct::my_alias_enum( - MyAliasEnum _my_alias_enum) -{ - m_my_alias_enum = _my_alias_enum; -} - -/*! - * @brief This function returns the value of member my_alias_enum - * @return Value of member my_alias_enum - */ -MyAliasEnum ComplexStruct::my_alias_enum() const -{ - return m_my_alias_enum; -} - -/*! - * @brief This function returns a reference to member my_alias_enum - * @return Reference to member my_alias_enum - */ -MyAliasEnum& ComplexStruct::my_alias_enum() -{ - return m_my_alias_enum; -} - - -/*! - * @brief This function sets a value in member my_enum - * @param _my_enum New value for member my_enum - */ -void ComplexStruct::my_enum( - MyEnum _my_enum) -{ - m_my_enum = _my_enum; -} - -/*! - * @brief This function returns the value of member my_enum - * @return Value of member my_enum - */ -MyEnum ComplexStruct::my_enum() const -{ - return m_my_enum; -} - -/*! - * @brief This function returns a reference to member my_enum - * @return Reference to member my_enum - */ -MyEnum& ComplexStruct::my_enum() -{ - return m_my_enum; -} - - -/*! - * @brief This function copies the value in member my_sequence_octet - * @param _my_sequence_octet New value to be copied in member my_sequence_octet - */ -void ComplexStruct::my_sequence_octet( - const std::vector& _my_sequence_octet) -{ - m_my_sequence_octet = _my_sequence_octet; -} - -/*! - * @brief This function moves the value in member my_sequence_octet - * @param _my_sequence_octet New value to be moved in member my_sequence_octet - */ -void ComplexStruct::my_sequence_octet( - std::vector&& _my_sequence_octet) -{ - m_my_sequence_octet = std::move(_my_sequence_octet); -} - -/*! - * @brief This function returns a constant reference to member my_sequence_octet - * @return Constant reference to member my_sequence_octet - */ -const std::vector& ComplexStruct::my_sequence_octet() const -{ - return m_my_sequence_octet; -} - -/*! - * @brief This function returns a reference to member my_sequence_octet - * @return Reference to member my_sequence_octet - */ -std::vector& ComplexStruct::my_sequence_octet() -{ - return m_my_sequence_octet; -} - - -/*! - * @brief This function copies the value in member my_sequence_struct - * @param _my_sequence_struct New value to be copied in member my_sequence_struct - */ -void ComplexStruct::my_sequence_struct( - const std::vector& _my_sequence_struct) -{ - m_my_sequence_struct = _my_sequence_struct; -} - -/*! - * @brief This function moves the value in member my_sequence_struct - * @param _my_sequence_struct New value to be moved in member my_sequence_struct - */ -void ComplexStruct::my_sequence_struct( - std::vector&& _my_sequence_struct) -{ - m_my_sequence_struct = std::move(_my_sequence_struct); -} - -/*! - * @brief This function returns a constant reference to member my_sequence_struct - * @return Constant reference to member my_sequence_struct - */ -const std::vector& ComplexStruct::my_sequence_struct() const -{ - return m_my_sequence_struct; -} - -/*! - * @brief This function returns a reference to member my_sequence_struct - * @return Reference to member my_sequence_struct - */ -std::vector& ComplexStruct::my_sequence_struct() -{ - return m_my_sequence_struct; -} - - -/*! - * @brief This function copies the value in member my_array_octet - * @param _my_array_octet New value to be copied in member my_array_octet - */ -void ComplexStruct::my_array_octet( - const std::array, 5>, 500>& _my_array_octet) -{ - m_my_array_octet = _my_array_octet; -} - -/*! - * @brief This function moves the value in member my_array_octet - * @param _my_array_octet New value to be moved in member my_array_octet - */ -void ComplexStruct::my_array_octet( - std::array, 5>, 500>&& _my_array_octet) -{ - m_my_array_octet = std::move(_my_array_octet); -} - -/*! - * @brief This function returns a constant reference to member my_array_octet - * @return Constant reference to member my_array_octet - */ -const std::array, 5>, 500>& ComplexStruct::my_array_octet() const -{ - return m_my_array_octet; -} - -/*! - * @brief This function returns a reference to member my_array_octet - * @return Reference to member my_array_octet - */ -std::array, 5>, 500>& ComplexStruct::my_array_octet() -{ - return m_my_array_octet; -} - - -/*! - * @brief This function copies the value in member my_octet_array_500 - * @param _my_octet_array_500 New value to be copied in member my_octet_array_500 - */ -void ComplexStruct::my_octet_array_500( - const MyOctetArray500& _my_octet_array_500) -{ - m_my_octet_array_500 = _my_octet_array_500; -} - -/*! - * @brief This function moves the value in member my_octet_array_500 - * @param _my_octet_array_500 New value to be moved in member my_octet_array_500 - */ -void ComplexStruct::my_octet_array_500( - MyOctetArray500&& _my_octet_array_500) -{ - m_my_octet_array_500 = std::move(_my_octet_array_500); -} - -/*! - * @brief This function returns a constant reference to member my_octet_array_500 - * @return Constant reference to member my_octet_array_500 - */ -const MyOctetArray500& ComplexStruct::my_octet_array_500() const -{ - return m_my_octet_array_500; -} - -/*! - * @brief This function returns a reference to member my_octet_array_500 - * @return Reference to member my_octet_array_500 - */ -MyOctetArray500& ComplexStruct::my_octet_array_500() -{ - return m_my_octet_array_500; -} - - -/*! - * @brief This function copies the value in member my_array_struct - * @param _my_array_struct New value to be copied in member my_array_struct - */ -void ComplexStruct::my_array_struct( - const std::array& _my_array_struct) -{ - m_my_array_struct = _my_array_struct; -} - -/*! - * @brief This function moves the value in member my_array_struct - * @param _my_array_struct New value to be moved in member my_array_struct - */ -void ComplexStruct::my_array_struct( - std::array&& _my_array_struct) -{ - m_my_array_struct = std::move(_my_array_struct); -} - -/*! - * @brief This function returns a constant reference to member my_array_struct - * @return Constant reference to member my_array_struct - */ -const std::array& ComplexStruct::my_array_struct() const -{ - return m_my_array_struct; -} - -/*! - * @brief This function returns a reference to member my_array_struct - * @return Reference to member my_array_struct - */ -std::array& ComplexStruct::my_array_struct() -{ - return m_my_array_struct; -} - - -/*! - * @brief This function copies the value in member my_map_octet_short - * @param _my_map_octet_short New value to be copied in member my_map_octet_short - */ -void ComplexStruct::my_map_octet_short( - const std::map& _my_map_octet_short) -{ - m_my_map_octet_short = _my_map_octet_short; -} - -/*! - * @brief This function moves the value in member my_map_octet_short - * @param _my_map_octet_short New value to be moved in member my_map_octet_short - */ -void ComplexStruct::my_map_octet_short( - std::map&& _my_map_octet_short) -{ - m_my_map_octet_short = std::move(_my_map_octet_short); -} - -/*! - * @brief This function returns a constant reference to member my_map_octet_short - * @return Constant reference to member my_map_octet_short - */ -const std::map& ComplexStruct::my_map_octet_short() const -{ - return m_my_map_octet_short; -} - -/*! - * @brief This function returns a reference to member my_map_octet_short - * @return Reference to member my_map_octet_short - */ -std::map& ComplexStruct::my_map_octet_short() -{ - return m_my_map_octet_short; -} - - -/*! - * @brief This function copies the value in member my_map_long_struct - * @param _my_map_long_struct New value to be copied in member my_map_long_struct - */ -void ComplexStruct::my_map_long_struct( - const std::map& _my_map_long_struct) -{ - m_my_map_long_struct = _my_map_long_struct; -} - -/*! - * @brief This function moves the value in member my_map_long_struct - * @param _my_map_long_struct New value to be moved in member my_map_long_struct - */ -void ComplexStruct::my_map_long_struct( - std::map&& _my_map_long_struct) -{ - m_my_map_long_struct = std::move(_my_map_long_struct); -} - -/*! - * @brief This function returns a constant reference to member my_map_long_struct - * @return Constant reference to member my_map_long_struct - */ -const std::map& ComplexStruct::my_map_long_struct() const -{ - return m_my_map_long_struct; -} - -/*! - * @brief This function returns a reference to member my_map_long_struct - * @return Reference to member my_map_long_struct - */ -std::map& ComplexStruct::my_map_long_struct() -{ - return m_my_map_long_struct; -} - - -/*! - * @brief This function copies the value in member my_map_long_seq_octet - * @param _my_map_long_seq_octet New value to be copied in member my_map_long_seq_octet - */ -void ComplexStruct::my_map_long_seq_octet( - const std::map>>& _my_map_long_seq_octet) -{ - m_my_map_long_seq_octet = _my_map_long_seq_octet; -} - -/*! - * @brief This function moves the value in member my_map_long_seq_octet - * @param _my_map_long_seq_octet New value to be moved in member my_map_long_seq_octet - */ -void ComplexStruct::my_map_long_seq_octet( - std::map>>&& _my_map_long_seq_octet) -{ - m_my_map_long_seq_octet = std::move(_my_map_long_seq_octet); -} - -/*! - * @brief This function returns a constant reference to member my_map_long_seq_octet - * @return Constant reference to member my_map_long_seq_octet - */ -const std::map>>& ComplexStruct::my_map_long_seq_octet() const -{ - return m_my_map_long_seq_octet; -} - -/*! - * @brief This function returns a reference to member my_map_long_seq_octet - * @return Reference to member my_map_long_seq_octet - */ -std::map>>& ComplexStruct::my_map_long_seq_octet() -{ - return m_my_map_long_seq_octet; -} - - -/*! - * @brief This function copies the value in member my_map_long_octet_array_500 - * @param _my_map_long_octet_array_500 New value to be copied in member my_map_long_octet_array_500 - */ -void ComplexStruct::my_map_long_octet_array_500( - const std::map& _my_map_long_octet_array_500) -{ - m_my_map_long_octet_array_500 = _my_map_long_octet_array_500; -} - -/*! - * @brief This function moves the value in member my_map_long_octet_array_500 - * @param _my_map_long_octet_array_500 New value to be moved in member my_map_long_octet_array_500 - */ -void ComplexStruct::my_map_long_octet_array_500( - std::map&& _my_map_long_octet_array_500) -{ - m_my_map_long_octet_array_500 = std::move(_my_map_long_octet_array_500); -} - -/*! - * @brief This function returns a constant reference to member my_map_long_octet_array_500 - * @return Constant reference to member my_map_long_octet_array_500 - */ -const std::map& ComplexStruct::my_map_long_octet_array_500() const -{ - return m_my_map_long_octet_array_500; -} - -/*! - * @brief This function returns a reference to member my_map_long_octet_array_500 - * @return Reference to member my_map_long_octet_array_500 - */ -std::map& ComplexStruct::my_map_long_octet_array_500() -{ - return m_my_map_long_octet_array_500; -} - - -/*! - * @brief This function copies the value in member my_map_long_lol_type - * @param _my_map_long_lol_type New value to be copied in member my_map_long_lol_type - */ -void ComplexStruct::my_map_long_lol_type( - const std::map>& _my_map_long_lol_type) -{ - m_my_map_long_lol_type = _my_map_long_lol_type; -} - -/*! - * @brief This function moves the value in member my_map_long_lol_type - * @param _my_map_long_lol_type New value to be moved in member my_map_long_lol_type - */ -void ComplexStruct::my_map_long_lol_type( - std::map>&& _my_map_long_lol_type) -{ - m_my_map_long_lol_type = std::move(_my_map_long_lol_type); -} - -/*! - * @brief This function returns a constant reference to member my_map_long_lol_type - * @return Constant reference to member my_map_long_lol_type - */ -const std::map>& ComplexStruct::my_map_long_lol_type() const -{ - return m_my_map_long_lol_type; -} - -/*! - * @brief This function returns a reference to member my_map_long_lol_type - * @return Reference to member my_map_long_lol_type - */ -std::map>& ComplexStruct::my_map_long_lol_type() -{ - return m_my_map_long_lol_type; -} - - -/*! - * @brief This function copies the value in member my_small_string_8 - * @param _my_small_string_8 New value to be copied in member my_small_string_8 - */ -void ComplexStruct::my_small_string_8( - const eprosima::fastrtps::fixed_string<128>& _my_small_string_8) -{ - m_my_small_string_8 = _my_small_string_8; -} - -/*! - * @brief This function moves the value in member my_small_string_8 - * @param _my_small_string_8 New value to be moved in member my_small_string_8 - */ -void ComplexStruct::my_small_string_8( - eprosima::fastrtps::fixed_string<128>&& _my_small_string_8) -{ - m_my_small_string_8 = std::move(_my_small_string_8); -} - -/*! - * @brief This function returns a constant reference to member my_small_string_8 - * @return Constant reference to member my_small_string_8 - */ -const eprosima::fastrtps::fixed_string<128>& ComplexStruct::my_small_string_8() const -{ - return m_my_small_string_8; -} - -/*! - * @brief This function returns a reference to member my_small_string_8 - * @return Reference to member my_small_string_8 - */ -eprosima::fastrtps::fixed_string<128>& ComplexStruct::my_small_string_8() -{ - return m_my_small_string_8; -} - - -/*! - * @brief This function copies the value in member my_large_string_8 - * @param _my_large_string_8 New value to be copied in member my_large_string_8 - */ -void ComplexStruct::my_large_string_8( - const eprosima::fastrtps::fixed_string<500>& _my_large_string_8) -{ - m_my_large_string_8 = _my_large_string_8; -} - -/*! - * @brief This function moves the value in member my_large_string_8 - * @param _my_large_string_8 New value to be moved in member my_large_string_8 - */ -void ComplexStruct::my_large_string_8( - eprosima::fastrtps::fixed_string<500>&& _my_large_string_8) -{ - m_my_large_string_8 = std::move(_my_large_string_8); -} - -/*! - * @brief This function returns a constant reference to member my_large_string_8 - * @return Constant reference to member my_large_string_8 - */ -const eprosima::fastrtps::fixed_string<500>& ComplexStruct::my_large_string_8() const -{ - return m_my_large_string_8; -} - -/*! - * @brief This function returns a reference to member my_large_string_8 - * @return Reference to member my_large_string_8 - */ -eprosima::fastrtps::fixed_string<500>& ComplexStruct::my_large_string_8() -{ - return m_my_large_string_8; -} - - -/*! - * @brief This function copies the value in member my_array_string - * @param _my_array_string New value to be copied in member my_array_string - */ -void ComplexStruct::my_array_string( - const std::array, 5>, 5>& _my_array_string) -{ - m_my_array_string = _my_array_string; -} - -/*! - * @brief This function moves the value in member my_array_string - * @param _my_array_string New value to be moved in member my_array_string - */ -void ComplexStruct::my_array_string( - std::array, 5>, 5>&& _my_array_string) -{ - m_my_array_string = std::move(_my_array_string); -} - -/*! - * @brief This function returns a constant reference to member my_array_string - * @return Constant reference to member my_array_string - */ -const std::array, 5>, 5>& ComplexStruct::my_array_string() const -{ - return m_my_array_string; -} - -/*! - * @brief This function returns a reference to member my_array_string - * @return Reference to member my_array_string - */ -std::array, 5>, 5>& ComplexStruct::my_array_string() -{ - return m_my_array_string; -} - - -/*! - * @brief This function copies the value in member multi_alias_array_42 - * @param _multi_alias_array_42 New value to be copied in member multi_alias_array_42 - */ -void ComplexStruct::multi_alias_array_42( - const MA3& _multi_alias_array_42) -{ - m_multi_alias_array_42 = _multi_alias_array_42; -} - -/*! - * @brief This function moves the value in member multi_alias_array_42 - * @param _multi_alias_array_42 New value to be moved in member multi_alias_array_42 - */ -void ComplexStruct::multi_alias_array_42( - MA3&& _multi_alias_array_42) -{ - m_multi_alias_array_42 = std::move(_multi_alias_array_42); -} - -/*! - * @brief This function returns a constant reference to member multi_alias_array_42 - * @return Constant reference to member multi_alias_array_42 - */ -const MA3& ComplexStruct::multi_alias_array_42() const -{ - return m_multi_alias_array_42; -} - -/*! - * @brief This function returns a reference to member multi_alias_array_42 - * @return Reference to member multi_alias_array_42 - */ -MA3& ComplexStruct::multi_alias_array_42() -{ - return m_multi_alias_array_42; -} - - -/*! - * @brief This function copies the value in member my_array_arrays - * @param _my_array_arrays New value to be copied in member my_array_arrays - */ -void ComplexStruct::my_array_arrays( - const std::array& _my_array_arrays) -{ - m_my_array_arrays = _my_array_arrays; -} - -/*! - * @brief This function moves the value in member my_array_arrays - * @param _my_array_arrays New value to be moved in member my_array_arrays - */ -void ComplexStruct::my_array_arrays( - std::array&& _my_array_arrays) -{ - m_my_array_arrays = std::move(_my_array_arrays); -} - -/*! - * @brief This function returns a constant reference to member my_array_arrays - * @return Constant reference to member my_array_arrays - */ -const std::array& ComplexStruct::my_array_arrays() const -{ - return m_my_array_arrays; -} - -/*! - * @brief This function returns a reference to member my_array_arrays - * @return Reference to member my_array_arrays - */ -std::array& ComplexStruct::my_array_arrays() -{ - return m_my_array_arrays; -} - - -/*! - * @brief This function copies the value in member my_sequences_array - * @param _my_sequences_array New value to be copied in member my_sequences_array - */ -void ComplexStruct::my_sequences_array( - const std::array& _my_sequences_array) -{ - m_my_sequences_array = _my_sequences_array; -} - -/*! - * @brief This function moves the value in member my_sequences_array - * @param _my_sequences_array New value to be moved in member my_sequences_array - */ -void ComplexStruct::my_sequences_array( - std::array&& _my_sequences_array) -{ - m_my_sequences_array = std::move(_my_sequences_array); -} - -/*! - * @brief This function returns a constant reference to member my_sequences_array - * @return Constant reference to member my_sequences_array - */ -const std::array& ComplexStruct::my_sequences_array() const -{ - return m_my_sequences_array; -} - -/*! - * @brief This function returns a reference to member my_sequences_array - * @return Reference to member my_sequences_array - */ -std::array& ComplexStruct::my_sequences_array() -{ - return m_my_sequences_array; -} - - - - - -MyUnion::MyUnion() -{ - m__d = ::A; - // BasicStruct m_basic - - // ComplexStruct m_complex - -} - -MyUnion::~MyUnion() -{ -} - -MyUnion::MyUnion( - const MyUnion& x) -{ - m__d = x.m__d; - - switch(m__d) - { - case ::A: - m_basic = x.m_basic; - break; - - - case ::B: - case ::C: - m_complex = x.m_complex; - break; - - default: - break; - } -} - -MyUnion::MyUnion( - MyUnion&& x) noexcept -{ - m__d = x.m__d; - - switch(m__d) - { - case ::A: - m_basic = std::move(x.m_basic); - - break; - - - case ::B: - case ::C: - m_complex = std::move(x.m_complex); - - break; - - default: - break; - } -} - -MyUnion& MyUnion::operator =( - const MyUnion& x) -{ - m__d = x.m__d; - - switch(m__d) - { - case ::A: - m_basic = x.m_basic; - break; - - - case ::B: - case ::C: - m_complex = x.m_complex; - break; - - default: - break; - } - - return *this; -} - -MyUnion& MyUnion::operator =( - MyUnion&& x) noexcept -{ - m__d = x.m__d; - - switch(m__d) - { - case ::A: - m_basic = std::move(x.m_basic); - - break; - - - case ::B: - case ::C: - m_complex = std::move(x.m_complex); - - break; - - default: - break; - } - - return *this; -} - -bool MyUnion::operator ==( - const MyUnion& x) const -{ - if (m__d != x.m__d) - { - return false; - } - - switch(m__d) - { - case ::A: - return (m_basic == x.m_basic); - break; - - - case ::B: - case ::C: - return (m_complex == x.m_complex); - break; - - default: - break; - } - return false; -} - -bool MyUnion::operator !=( - const MyUnion& x) const -{ - return !(*this == x); -} - -void MyUnion::_d( - MyEnum __d) -{ - bool b = false; - - switch(m__d) - { - case ::A: - switch(__d) - { - case ::A: - b = true; - break; - default: - break; - } - break; - - - case ::B: - case ::C: - switch(__d) - { - case ::B: - case ::C: - b = true; - break; - default: - break; - } - break; - - } - - if(!b) - { - throw BadParamException("Discriminator doesn't correspond with the selected union member"); - } - - m__d = __d; -} - -MyEnum MyUnion::_d() const -{ - return m__d; -} - -MyEnum& MyUnion::_d() -{ - return m__d; -} - -void MyUnion::basic( - const BasicStruct& _basic) -{ - m_basic = _basic; - m__d = ::A; - -} - -void MyUnion::basic( - BasicStruct&& _basic) -{ - m_basic = std::move(_basic); - m__d = ::A; - -} - -const BasicStruct& MyUnion::basic() const -{ - bool b = false; - - switch(m__d) - { - case ::A: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_basic; -} - -BasicStruct& MyUnion::basic() -{ - bool b = false; - - switch(m__d) - { - case ::A: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_basic; -} - - -void MyUnion::complex( - const ComplexStruct& _complex) -{ - m_complex = _complex; - m__d = ::B; - -} - -void MyUnion::complex( - ComplexStruct&& _complex) -{ - m_complex = std::move(_complex); - m__d = ::B; - -} - -const ComplexStruct& MyUnion::complex() const -{ - bool b = false; - - switch(m__d) - { - case ::B: - case ::C: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_complex; -} - -ComplexStruct& MyUnion::complex() -{ - bool b = false; - - switch(m__d) - { - case ::B: - case ::C: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_complex; -} - - -// TODO(Ricardo) Review -size_t MyUnion::getCdrSerializedSize( - const MyUnion& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - - switch(data.m__d) - { - case ::A: - current_alignment += BasicStruct::getCdrSerializedSize(data.basic(), current_alignment); - - break; - - - case ::B: - case ::C: - current_alignment += ComplexStruct::getCdrSerializedSize(data.complex(), current_alignment); - - break; - - default: - break; - } - - return current_alignment - initial_alignment; -} - - -void MyUnion::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << (uint32_t)m__d; - - switch(m__d) - { - case ::A: - scdr << m_basic; - - break; - - - case ::B: - case ::C: - scdr << m_complex; - - break; - - default: - break; - } -} - -void MyUnion::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - { - uint32_t enum_value = 0; - dcdr >> enum_value; - m__d = (MyEnum)enum_value; - } - - - switch(m__d) - { - case ::A: - dcdr >> m_basic; - - - break; - - - case ::B: - case ::C: - dcdr >> m_complex; - - - break; - - default: - break; - } -} - - - - - -MyUnion2::MyUnion2() -{ - m__d = A; - // long m_uno - m_uno = 0; - // /type_d() m_imString - - // long m_tres - m_tres = 0; -} - -MyUnion2::~MyUnion2() -{ -} - -MyUnion2::MyUnion2( - const MyUnion2& x) -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_uno = x.m_uno; - break; - - - case B: - m_imString = x.m_imString; - break; - - - case C: - m_tres = x.m_tres; - break; - - default: - break; - } -} - -MyUnion2::MyUnion2( - MyUnion2&& x) noexcept -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_uno = x.m_uno; - break; - - - case B: - m_imString = std::move(x.m_imString); - - break; - - - case C: - m_tres = x.m_tres; - break; - - default: - break; - } -} - -MyUnion2& MyUnion2::operator =( - const MyUnion2& x) -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_uno = x.m_uno; - break; - - - case B: - m_imString = x.m_imString; - break; - - - case C: - m_tres = x.m_tres; - break; - - default: - break; - } - - return *this; -} - -MyUnion2& MyUnion2::operator =( - MyUnion2&& x) noexcept -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_uno = x.m_uno; - break; - - - case B: - m_imString = std::move(x.m_imString); - - break; - - - case C: - m_tres = x.m_tres; - break; - - default: - break; - } - - return *this; -} - -bool MyUnion2::operator ==( - const MyUnion2& x) const -{ - if (m__d != x.m__d) - { - return false; - } - - switch(m__d) - { - case A: - return (m_uno == x.m_uno); - break; - - - case B: - return (m_imString == x.m_imString); - break; - - - case C: - return (m_tres == x.m_tres); - break; - - default: - break; - } - return false; -} - -bool MyUnion2::operator !=( - const MyUnion2& x) const -{ - return !(*this == x); -} - -void MyUnion2::_d( - uint8_t __d) -{ - bool b = false; - - switch(m__d) - { - case A: - switch(__d) - { - case A: - b = true; - break; - default: - break; - } - break; - - - case B: - switch(__d) - { - case B: - b = true; - break; - default: - break; - } - break; - - - case C: - switch(__d) - { - case C: - b = true; - break; - default: - break; - } - break; - - } - - if(!b) - { - throw BadParamException("Discriminator doesn't correspond with the selected union member"); - } - - m__d = __d; -} - -uint8_t MyUnion2::_d() const -{ - return m__d; -} - -uint8_t& MyUnion2::_d() -{ - return m__d; -} - -void MyUnion2::uno( - int32_t _uno) -{ - m_uno = _uno; - m__d = A; - -} - -int32_t MyUnion2::uno() const -{ - bool b = false; - - switch(m__d) - { - case A: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_uno; -} - -int32_t& MyUnion2::uno() -{ - bool b = false; - - switch(m__d) - { - case A: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_uno; -} - - -void MyUnion2::imString( - const std::string& _imString) -{ - m_imString = _imString; - m__d = B; - -} - -void MyUnion2::imString( - std::string&& _imString) -{ - m_imString = std::move(_imString); - m__d = B; - -} - -const std::string& MyUnion2::imString() const -{ - bool b = false; - - switch(m__d) - { - case B: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_imString; -} - -std::string& MyUnion2::imString() -{ - bool b = false; - - switch(m__d) - { - case B: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_imString; -} - - -void MyUnion2::tres( - int32_t _tres) -{ - m_tres = _tres; - m__d = C; - -} - -int32_t MyUnion2::tres() const -{ - bool b = false; - - switch(m__d) - { - case C: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_tres; -} - -int32_t& MyUnion2::tres() -{ - bool b = false; - - switch(m__d) - { - case C: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_tres; -} - - -// TODO(Ricardo) Review -size_t MyUnion2::getCdrSerializedSize( - const MyUnion2& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - - switch(data.m__d) - { - case A: - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - break; - - - case B: - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + data.imString().size() + 1; - - break; - - - case C: - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - break; - - default: - break; - } - - return current_alignment - initial_alignment; -} - - -void MyUnion2::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m__d; - - switch(m__d) - { - case A: - scdr << m_uno; - - break; - - - case B: - scdr << m_imString.c_str(); - - break; - - - case C: - scdr << m_tres; - - break; - - default: - break; - } -} - -void MyUnion2::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m__d; - - - switch(m__d) - { - case A: - dcdr >> m_uno; - - - break; - - - case B: - dcdr >> m_imString; - - - break; - - - case C: - dcdr >> m_tres; - - - break; - - default: - break; - } -} - - - - - -CompleteStruct::CompleteStruct() -{ - // MyUnion m_my_union - - // MyUnion2 m_my_union_2 - - - // Just to register all known types - registerTestTypes(); -} - -CompleteStruct::~CompleteStruct() -{ -} - -CompleteStruct::CompleteStruct( - const CompleteStruct& x) -{ - m_my_union = x.m_my_union; - - - m_my_union_2 = x.m_my_union_2; - -} - -CompleteStruct::CompleteStruct( - CompleteStruct&& x) noexcept -{ - m_my_union = std::move(x.m_my_union); - - - m_my_union_2 = std::move(x.m_my_union_2); - -} - -CompleteStruct& CompleteStruct::operator =( - const CompleteStruct& x) -{ - m_my_union = x.m_my_union; - - - m_my_union_2 = x.m_my_union_2; - - return *this; -} - -CompleteStruct& CompleteStruct::operator =( - CompleteStruct&& x) noexcept -{ - m_my_union = std::move(x.m_my_union); - - - m_my_union_2 = std::move(x.m_my_union_2); - - return *this; -} - -bool CompleteStruct::operator ==( - const CompleteStruct& x) const -{ - return (m_my_union == x.m_my_union && - m_my_union_2 == x.m_my_union_2); -} - -bool CompleteStruct::operator !=( - const CompleteStruct& x) const -{ - return !(*this == x); -} - -size_t CompleteStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return CompleteStruct_max_cdr_typesize; -} - -size_t CompleteStruct::getCdrSerializedSize( - const CompleteStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += MyUnion::getCdrSerializedSize(data.my_union(), current_alignment); - - - current_alignment += MyUnion2::getCdrSerializedSize(data.my_union_2(), current_alignment); - - - return current_alignment - initial_alignment; -} - - -void CompleteStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_union; - - scdr << m_my_union_2; - -} - -void CompleteStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_union; - - - - dcdr >> m_my_union_2; - - -} - - -bool CompleteStruct::isKeyDefined() -{ - return false; -} - -void CompleteStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ -void CompleteStruct::my_union( - const MyUnion& _my_union) -{ - m_my_union = _my_union; -} - -/*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ -void CompleteStruct::my_union( - MyUnion&& _my_union) -{ - m_my_union = std::move(_my_union); -} - -/*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ -const MyUnion& CompleteStruct::my_union() const -{ - return m_my_union; -} - -/*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ -MyUnion& CompleteStruct::my_union() -{ - return m_my_union; -} - - -/*! - * @brief This function copies the value in member my_union_2 - * @param _my_union_2 New value to be copied in member my_union_2 - */ -void CompleteStruct::my_union_2( - const MyUnion2& _my_union_2) -{ - m_my_union_2 = _my_union_2; -} - -/*! - * @brief This function moves the value in member my_union_2 - * @param _my_union_2 New value to be moved in member my_union_2 - */ -void CompleteStruct::my_union_2( - MyUnion2&& _my_union_2) -{ - m_my_union_2 = std::move(_my_union_2); -} - -/*! - * @brief This function returns a constant reference to member my_union_2 - * @return Constant reference to member my_union_2 - */ -const MyUnion2& CompleteStruct::my_union_2() const -{ - return m_my_union_2; -} - -/*! - * @brief This function returns a reference to member my_union_2 - * @return Reference to member my_union_2 - */ -MyUnion2& CompleteStruct::my_union_2() -{ - return m_my_union_2; -} - - - - - -KeyedStruct::KeyedStruct() -{ - // octet m_key - m_key = 0; - // BasicStruct m_basic - - - // Just to register all known types - registerTestTypes(); -} - -KeyedStruct::~KeyedStruct() -{ -} - -KeyedStruct::KeyedStruct( - const KeyedStruct& x) -{ - m_key = x.m_key; - - - m_basic = x.m_basic; - -} - -KeyedStruct::KeyedStruct( - KeyedStruct&& x) noexcept -{ - m_key = x.m_key; - - - m_basic = std::move(x.m_basic); - -} - -KeyedStruct& KeyedStruct::operator =( - const KeyedStruct& x) -{ - m_key = x.m_key; - - - m_basic = x.m_basic; - - return *this; -} - -KeyedStruct& KeyedStruct::operator =( - KeyedStruct&& x) noexcept -{ - m_key = x.m_key; - - - m_basic = std::move(x.m_basic); - - return *this; -} - -bool KeyedStruct::operator ==( - const KeyedStruct& x) const -{ - return (m_key == x.m_key && - m_basic == x.m_basic); -} - -bool KeyedStruct::operator !=( - const KeyedStruct& x) const -{ - return !(*this == x); -} - -size_t KeyedStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return KeyedStruct_max_cdr_typesize; -} - -size_t KeyedStruct::getCdrSerializedSize( - const KeyedStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - current_alignment += BasicStruct::getCdrSerializedSize(data.basic(), current_alignment); - - - return current_alignment - initial_alignment; -} - - -void KeyedStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_key; - - scdr << m_basic; - -} - -void KeyedStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_key; - - - - dcdr >> m_basic; - - -} - - -bool KeyedStruct::isKeyDefined() -{ - return true; -} - -void KeyedStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; - - scdr << m_key; - - -} - -/*! - * @brief This function sets a value in member key - * @param _key New value for member key - */ -void KeyedStruct::key( - uint8_t _key) -{ - m_key = _key; -} - -/*! - * @brief This function returns the value of member key - * @return Value of member key - */ -uint8_t KeyedStruct::key() const -{ - return m_key; -} - -/*! - * @brief This function returns a reference to member key - * @return Reference to member key - */ -uint8_t& KeyedStruct::key() -{ - return m_key; -} - - -/*! - * @brief This function copies the value in member basic - * @param _basic New value to be copied in member basic - */ -void KeyedStruct::basic( - const BasicStruct& _basic) -{ - m_basic = _basic; -} - -/*! - * @brief This function moves the value in member basic - * @param _basic New value to be moved in member basic - */ -void KeyedStruct::basic( - BasicStruct&& _basic) -{ - m_basic = std::move(_basic); -} - -/*! - * @brief This function returns a constant reference to member basic - * @return Constant reference to member basic - */ -const BasicStruct& KeyedStruct::basic() const -{ - return m_basic; -} - -/*! - * @brief This function returns a reference to member basic - * @return Reference to member basic - */ -BasicStruct& KeyedStruct::basic() -{ - return m_basic; -} - - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/test/unittest/dynamic_types/idl/Testv1.h b/test/unittest/dynamic_types/idl/Testv1.h deleted file mode 100644 index 42ae9b215ea..00000000000 --- a/test/unittest/dynamic_types/idl/Testv1.h +++ /dev/null @@ -1,1873 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file Test.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#include - -#if FASTCDR_VERSION_MAJOR == 1 - -#ifndef _FAST_DDS_GENERATED_TEST_H_ -#define _FAST_DDS_GENERATED_TEST_H_ - - -#include - -#include -#include -#include -#include -#include -#include -#include - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define eProsima_user_DllExport -#endif // _WIN32 - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(TEST_SOURCE) -#define TEST_DllAPI __declspec( dllexport ) -#else -#define TEST_DllAPI __declspec( dllimport ) -#endif // TEST_SOURCE -#else -#define TEST_DllAPI -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define TEST_DllAPI -#endif // _WIN32 - -namespace eprosima { -namespace fastcdr { -class Cdr; -} // namespace fastcdr -} // namespace eprosima - - - -/*! - * @brief This class represents the enumeration MyEnum defined by the user in the IDL file. - * @ingroup Test - */ -enum MyEnum : uint32_t -{ - A, - B, - C -}; -typedef MyEnum MyAliasEnum; - -typedef MyAliasEnum MyAliasEnum2; - -typedef MyAliasEnum2 MyAliasEnum3; - - - -/*! - * @brief This class represents the structure BasicStruct defined by the user in the IDL file. - * @ingroup Test - */ -class BasicStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport BasicStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~BasicStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object BasicStruct that will be copied. - */ - eProsima_user_DllExport BasicStruct( - const BasicStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object BasicStruct that will be copied. - */ - eProsima_user_DllExport BasicStruct( - BasicStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object BasicStruct that will be copied. - */ - eProsima_user_DllExport BasicStruct& operator =( - const BasicStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object BasicStruct that will be copied. - */ - eProsima_user_DllExport BasicStruct& operator =( - BasicStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x BasicStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const BasicStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x BasicStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const BasicStruct& x) const; - - /*! - * @brief This function sets a value in member my_bool - * @param _my_bool New value for member my_bool - */ - eProsima_user_DllExport void my_bool( - bool _my_bool); - - /*! - * @brief This function returns the value of member my_bool - * @return Value of member my_bool - */ - eProsima_user_DllExport bool my_bool() const; - - /*! - * @brief This function returns a reference to member my_bool - * @return Reference to member my_bool - */ - eProsima_user_DllExport bool& my_bool(); - - - /*! - * @brief This function sets a value in member my_octet - * @param _my_octet New value for member my_octet - */ - eProsima_user_DllExport void my_octet( - uint8_t _my_octet); - - /*! - * @brief This function returns the value of member my_octet - * @return Value of member my_octet - */ - eProsima_user_DllExport uint8_t my_octet() const; - - /*! - * @brief This function returns a reference to member my_octet - * @return Reference to member my_octet - */ - eProsima_user_DllExport uint8_t& my_octet(); - - - /*! - * @brief This function sets a value in member my_int16 - * @param _my_int16 New value for member my_int16 - */ - eProsima_user_DllExport void my_int16( - int16_t _my_int16); - - /*! - * @brief This function returns the value of member my_int16 - * @return Value of member my_int16 - */ - eProsima_user_DllExport int16_t my_int16() const; - - /*! - * @brief This function returns a reference to member my_int16 - * @return Reference to member my_int16 - */ - eProsima_user_DllExport int16_t& my_int16(); - - - /*! - * @brief This function sets a value in member my_int32 - * @param _my_int32 New value for member my_int32 - */ - eProsima_user_DllExport void my_int32( - int32_t _my_int32); - - /*! - * @brief This function returns the value of member my_int32 - * @return Value of member my_int32 - */ - eProsima_user_DllExport int32_t my_int32() const; - - /*! - * @brief This function returns a reference to member my_int32 - * @return Reference to member my_int32 - */ - eProsima_user_DllExport int32_t& my_int32(); - - - /*! - * @brief This function sets a value in member my_int64 - * @param _my_int64 New value for member my_int64 - */ - eProsima_user_DllExport void my_int64( - int64_t _my_int64); - - /*! - * @brief This function returns the value of member my_int64 - * @return Value of member my_int64 - */ - eProsima_user_DllExport int64_t my_int64() const; - - /*! - * @brief This function returns a reference to member my_int64 - * @return Reference to member my_int64 - */ - eProsima_user_DllExport int64_t& my_int64(); - - - /*! - * @brief This function sets a value in member my_uint16 - * @param _my_uint16 New value for member my_uint16 - */ - eProsima_user_DllExport void my_uint16( - uint16_t _my_uint16); - - /*! - * @brief This function returns the value of member my_uint16 - * @return Value of member my_uint16 - */ - eProsima_user_DllExport uint16_t my_uint16() const; - - /*! - * @brief This function returns a reference to member my_uint16 - * @return Reference to member my_uint16 - */ - eProsima_user_DllExport uint16_t& my_uint16(); - - - /*! - * @brief This function sets a value in member my_uint32 - * @param _my_uint32 New value for member my_uint32 - */ - eProsima_user_DllExport void my_uint32( - uint32_t _my_uint32); - - /*! - * @brief This function returns the value of member my_uint32 - * @return Value of member my_uint32 - */ - eProsima_user_DllExport uint32_t my_uint32() const; - - /*! - * @brief This function returns a reference to member my_uint32 - * @return Reference to member my_uint32 - */ - eProsima_user_DllExport uint32_t& my_uint32(); - - - /*! - * @brief This function sets a value in member my_uint64 - * @param _my_uint64 New value for member my_uint64 - */ - eProsima_user_DllExport void my_uint64( - uint64_t _my_uint64); - - /*! - * @brief This function returns the value of member my_uint64 - * @return Value of member my_uint64 - */ - eProsima_user_DllExport uint64_t my_uint64() const; - - /*! - * @brief This function returns a reference to member my_uint64 - * @return Reference to member my_uint64 - */ - eProsima_user_DllExport uint64_t& my_uint64(); - - - /*! - * @brief This function sets a value in member my_float32 - * @param _my_float32 New value for member my_float32 - */ - eProsima_user_DllExport void my_float32( - float _my_float32); - - /*! - * @brief This function returns the value of member my_float32 - * @return Value of member my_float32 - */ - eProsima_user_DllExport float my_float32() const; - - /*! - * @brief This function returns a reference to member my_float32 - * @return Reference to member my_float32 - */ - eProsima_user_DllExport float& my_float32(); - - - /*! - * @brief This function sets a value in member my_float64 - * @param _my_float64 New value for member my_float64 - */ - eProsima_user_DllExport void my_float64( - double _my_float64); - - /*! - * @brief This function returns the value of member my_float64 - * @return Value of member my_float64 - */ - eProsima_user_DllExport double my_float64() const; - - /*! - * @brief This function returns a reference to member my_float64 - * @return Reference to member my_float64 - */ - eProsima_user_DllExport double& my_float64(); - - - /*! - * @brief This function sets a value in member my_float128 - * @param _my_float128 New value for member my_float128 - */ - eProsima_user_DllExport void my_float128( - long double _my_float128); - - /*! - * @brief This function returns the value of member my_float128 - * @return Value of member my_float128 - */ - eProsima_user_DllExport long double my_float128() const; - - /*! - * @brief This function returns a reference to member my_float128 - * @return Reference to member my_float128 - */ - eProsima_user_DllExport long double& my_float128(); - - - /*! - * @brief This function sets a value in member my_char - * @param _my_char New value for member my_char - */ - eProsima_user_DllExport void my_char( - char _my_char); - - /*! - * @brief This function returns the value of member my_char - * @return Value of member my_char - */ - eProsima_user_DllExport char my_char() const; - - /*! - * @brief This function returns a reference to member my_char - * @return Reference to member my_char - */ - eProsima_user_DllExport char& my_char(); - - - /*! - * @brief This function copies the value in member my_string - * @param _my_string New value to be copied in member my_string - */ - eProsima_user_DllExport void my_string( - const std::string& _my_string); - - /*! - * @brief This function moves the value in member my_string - * @param _my_string New value to be moved in member my_string - */ - eProsima_user_DllExport void my_string( - std::string&& _my_string); - - /*! - * @brief This function returns a constant reference to member my_string - * @return Constant reference to member my_string - */ - eProsima_user_DllExport const std::string& my_string() const; - - /*! - * @brief This function returns a reference to member my_string - * @return Reference to member my_string - */ - eProsima_user_DllExport std::string& my_string(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const BasicStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - bool m_my_bool; - uint8_t m_my_octet; - int16_t m_my_int16; - int32_t m_my_int32; - int64_t m_my_int64; - uint16_t m_my_uint16; - uint32_t m_my_uint32; - uint64_t m_my_uint64; - float m_my_float32; - double m_my_float64; - long double m_my_float128; - char m_my_char; - std::string m_my_string; - -}; - -typedef std::array MyOctetArray500; - -typedef std::array BSAlias5; - -typedef std::array MA3; - -typedef std::array MyMiniArray; - - - -typedef std::vector MySequenceLong; - - - -/*! - * @brief This class represents the structure ComplexStruct defined by the user in the IDL file. - * @ingroup Test - */ -class ComplexStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport ComplexStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~ComplexStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object ComplexStruct that will be copied. - */ - eProsima_user_DllExport ComplexStruct( - const ComplexStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object ComplexStruct that will be copied. - */ - eProsima_user_DllExport ComplexStruct( - ComplexStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object ComplexStruct that will be copied. - */ - eProsima_user_DllExport ComplexStruct& operator =( - const ComplexStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object ComplexStruct that will be copied. - */ - eProsima_user_DllExport ComplexStruct& operator =( - ComplexStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x ComplexStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const ComplexStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x ComplexStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const ComplexStruct& x) const; - - /*! - * @brief This function sets a value in member my_octet - * @param _my_octet New value for member my_octet - */ - eProsima_user_DllExport void my_octet( - uint8_t _my_octet); - - /*! - * @brief This function returns the value of member my_octet - * @return Value of member my_octet - */ - eProsima_user_DllExport uint8_t my_octet() const; - - /*! - * @brief This function returns a reference to member my_octet - * @return Reference to member my_octet - */ - eProsima_user_DllExport uint8_t& my_octet(); - - - /*! - * @brief This function copies the value in member my_basic_struct - * @param _my_basic_struct New value to be copied in member my_basic_struct - */ - eProsima_user_DllExport void my_basic_struct( - const BasicStruct& _my_basic_struct); - - /*! - * @brief This function moves the value in member my_basic_struct - * @param _my_basic_struct New value to be moved in member my_basic_struct - */ - eProsima_user_DllExport void my_basic_struct( - BasicStruct&& _my_basic_struct); - - /*! - * @brief This function returns a constant reference to member my_basic_struct - * @return Constant reference to member my_basic_struct - */ - eProsima_user_DllExport const BasicStruct& my_basic_struct() const; - - /*! - * @brief This function returns a reference to member my_basic_struct - * @return Reference to member my_basic_struct - */ - eProsima_user_DllExport BasicStruct& my_basic_struct(); - - - /*! - * @brief This function sets a value in member my_alias_enum - * @param _my_alias_enum New value for member my_alias_enum - */ - eProsima_user_DllExport void my_alias_enum( - MyAliasEnum _my_alias_enum); - - /*! - * @brief This function returns the value of member my_alias_enum - * @return Value of member my_alias_enum - */ - eProsima_user_DllExport MyAliasEnum my_alias_enum() const; - - /*! - * @brief This function returns a reference to member my_alias_enum - * @return Reference to member my_alias_enum - */ - eProsima_user_DllExport MyAliasEnum& my_alias_enum(); - - - /*! - * @brief This function sets a value in member my_enum - * @param _my_enum New value for member my_enum - */ - eProsima_user_DllExport void my_enum( - MyEnum _my_enum); - - /*! - * @brief This function returns the value of member my_enum - * @return Value of member my_enum - */ - eProsima_user_DllExport MyEnum my_enum() const; - - /*! - * @brief This function returns a reference to member my_enum - * @return Reference to member my_enum - */ - eProsima_user_DllExport MyEnum& my_enum(); - - - /*! - * @brief This function copies the value in member my_sequence_octet - * @param _my_sequence_octet New value to be copied in member my_sequence_octet - */ - eProsima_user_DllExport void my_sequence_octet( - const std::vector& _my_sequence_octet); - - /*! - * @brief This function moves the value in member my_sequence_octet - * @param _my_sequence_octet New value to be moved in member my_sequence_octet - */ - eProsima_user_DllExport void my_sequence_octet( - std::vector&& _my_sequence_octet); - - /*! - * @brief This function returns a constant reference to member my_sequence_octet - * @return Constant reference to member my_sequence_octet - */ - eProsima_user_DllExport const std::vector& my_sequence_octet() const; - - /*! - * @brief This function returns a reference to member my_sequence_octet - * @return Reference to member my_sequence_octet - */ - eProsima_user_DllExport std::vector& my_sequence_octet(); - - - /*! - * @brief This function copies the value in member my_sequence_struct - * @param _my_sequence_struct New value to be copied in member my_sequence_struct - */ - eProsima_user_DllExport void my_sequence_struct( - const std::vector& _my_sequence_struct); - - /*! - * @brief This function moves the value in member my_sequence_struct - * @param _my_sequence_struct New value to be moved in member my_sequence_struct - */ - eProsima_user_DllExport void my_sequence_struct( - std::vector&& _my_sequence_struct); - - /*! - * @brief This function returns a constant reference to member my_sequence_struct - * @return Constant reference to member my_sequence_struct - */ - eProsima_user_DllExport const std::vector& my_sequence_struct() const; - - /*! - * @brief This function returns a reference to member my_sequence_struct - * @return Reference to member my_sequence_struct - */ - eProsima_user_DllExport std::vector& my_sequence_struct(); - - - /*! - * @brief This function copies the value in member my_array_octet - * @param _my_array_octet New value to be copied in member my_array_octet - */ - eProsima_user_DllExport void my_array_octet( - const std::array, 5>, 500>& _my_array_octet); - - /*! - * @brief This function moves the value in member my_array_octet - * @param _my_array_octet New value to be moved in member my_array_octet - */ - eProsima_user_DllExport void my_array_octet( - std::array, 5>, 500>&& _my_array_octet); - - /*! - * @brief This function returns a constant reference to member my_array_octet - * @return Constant reference to member my_array_octet - */ - eProsima_user_DllExport const std::array, 5>, 500>& my_array_octet() const; - - /*! - * @brief This function returns a reference to member my_array_octet - * @return Reference to member my_array_octet - */ - eProsima_user_DllExport std::array, 5>, 500>& my_array_octet(); - - - /*! - * @brief This function copies the value in member my_octet_array_500 - * @param _my_octet_array_500 New value to be copied in member my_octet_array_500 - */ - eProsima_user_DllExport void my_octet_array_500( - const MyOctetArray500& _my_octet_array_500); - - /*! - * @brief This function moves the value in member my_octet_array_500 - * @param _my_octet_array_500 New value to be moved in member my_octet_array_500 - */ - eProsima_user_DllExport void my_octet_array_500( - MyOctetArray500&& _my_octet_array_500); - - /*! - * @brief This function returns a constant reference to member my_octet_array_500 - * @return Constant reference to member my_octet_array_500 - */ - eProsima_user_DllExport const MyOctetArray500& my_octet_array_500() const; - - /*! - * @brief This function returns a reference to member my_octet_array_500 - * @return Reference to member my_octet_array_500 - */ - eProsima_user_DllExport MyOctetArray500& my_octet_array_500(); - - - /*! - * @brief This function copies the value in member my_array_struct - * @param _my_array_struct New value to be copied in member my_array_struct - */ - eProsima_user_DllExport void my_array_struct( - const std::array& _my_array_struct); - - /*! - * @brief This function moves the value in member my_array_struct - * @param _my_array_struct New value to be moved in member my_array_struct - */ - eProsima_user_DllExport void my_array_struct( - std::array&& _my_array_struct); - - /*! - * @brief This function returns a constant reference to member my_array_struct - * @return Constant reference to member my_array_struct - */ - eProsima_user_DllExport const std::array& my_array_struct() const; - - /*! - * @brief This function returns a reference to member my_array_struct - * @return Reference to member my_array_struct - */ - eProsima_user_DllExport std::array& my_array_struct(); - - - /*! - * @brief This function copies the value in member my_map_octet_short - * @param _my_map_octet_short New value to be copied in member my_map_octet_short - */ - eProsima_user_DllExport void my_map_octet_short( - const std::map& _my_map_octet_short); - - /*! - * @brief This function moves the value in member my_map_octet_short - * @param _my_map_octet_short New value to be moved in member my_map_octet_short - */ - eProsima_user_DllExport void my_map_octet_short( - std::map&& _my_map_octet_short); - - /*! - * @brief This function returns a constant reference to member my_map_octet_short - * @return Constant reference to member my_map_octet_short - */ - eProsima_user_DllExport const std::map& my_map_octet_short() const; - - /*! - * @brief This function returns a reference to member my_map_octet_short - * @return Reference to member my_map_octet_short - */ - eProsima_user_DllExport std::map& my_map_octet_short(); - - - /*! - * @brief This function copies the value in member my_map_long_struct - * @param _my_map_long_struct New value to be copied in member my_map_long_struct - */ - eProsima_user_DllExport void my_map_long_struct( - const std::map& _my_map_long_struct); - - /*! - * @brief This function moves the value in member my_map_long_struct - * @param _my_map_long_struct New value to be moved in member my_map_long_struct - */ - eProsima_user_DllExport void my_map_long_struct( - std::map&& _my_map_long_struct); - - /*! - * @brief This function returns a constant reference to member my_map_long_struct - * @return Constant reference to member my_map_long_struct - */ - eProsima_user_DllExport const std::map& my_map_long_struct() const; - - /*! - * @brief This function returns a reference to member my_map_long_struct - * @return Reference to member my_map_long_struct - */ - eProsima_user_DllExport std::map& my_map_long_struct(); - - - /*! - * @brief This function copies the value in member my_map_long_seq_octet - * @param _my_map_long_seq_octet New value to be copied in member my_map_long_seq_octet - */ - eProsima_user_DllExport void my_map_long_seq_octet( - const std::map>>& _my_map_long_seq_octet); - - /*! - * @brief This function moves the value in member my_map_long_seq_octet - * @param _my_map_long_seq_octet New value to be moved in member my_map_long_seq_octet - */ - eProsima_user_DllExport void my_map_long_seq_octet( - std::map>>&& _my_map_long_seq_octet); - - /*! - * @brief This function returns a constant reference to member my_map_long_seq_octet - * @return Constant reference to member my_map_long_seq_octet - */ - eProsima_user_DllExport const std::map>>& my_map_long_seq_octet() const; - - /*! - * @brief This function returns a reference to member my_map_long_seq_octet - * @return Reference to member my_map_long_seq_octet - */ - eProsima_user_DllExport std::map>>& my_map_long_seq_octet(); - - - /*! - * @brief This function copies the value in member my_map_long_octet_array_500 - * @param _my_map_long_octet_array_500 New value to be copied in member my_map_long_octet_array_500 - */ - eProsima_user_DllExport void my_map_long_octet_array_500( - const std::map& _my_map_long_octet_array_500); - - /*! - * @brief This function moves the value in member my_map_long_octet_array_500 - * @param _my_map_long_octet_array_500 New value to be moved in member my_map_long_octet_array_500 - */ - eProsima_user_DllExport void my_map_long_octet_array_500( - std::map&& _my_map_long_octet_array_500); - - /*! - * @brief This function returns a constant reference to member my_map_long_octet_array_500 - * @return Constant reference to member my_map_long_octet_array_500 - */ - eProsima_user_DllExport const std::map& my_map_long_octet_array_500() const; - - /*! - * @brief This function returns a reference to member my_map_long_octet_array_500 - * @return Reference to member my_map_long_octet_array_500 - */ - eProsima_user_DllExport std::map& my_map_long_octet_array_500(); - - - /*! - * @brief This function copies the value in member my_map_long_lol_type - * @param _my_map_long_lol_type New value to be copied in member my_map_long_lol_type - */ - eProsima_user_DllExport void my_map_long_lol_type( - const std::map>& _my_map_long_lol_type); - - /*! - * @brief This function moves the value in member my_map_long_lol_type - * @param _my_map_long_lol_type New value to be moved in member my_map_long_lol_type - */ - eProsima_user_DllExport void my_map_long_lol_type( - std::map>&& _my_map_long_lol_type); - - /*! - * @brief This function returns a constant reference to member my_map_long_lol_type - * @return Constant reference to member my_map_long_lol_type - */ - eProsima_user_DllExport const std::map>& my_map_long_lol_type() const; - - /*! - * @brief This function returns a reference to member my_map_long_lol_type - * @return Reference to member my_map_long_lol_type - */ - eProsima_user_DllExport std::map>& my_map_long_lol_type(); - - - /*! - * @brief This function copies the value in member my_small_string_8 - * @param _my_small_string_8 New value to be copied in member my_small_string_8 - */ - eProsima_user_DllExport void my_small_string_8( - const eprosima::fastrtps::fixed_string<128>& _my_small_string_8); - - /*! - * @brief This function moves the value in member my_small_string_8 - * @param _my_small_string_8 New value to be moved in member my_small_string_8 - */ - eProsima_user_DllExport void my_small_string_8( - eprosima::fastrtps::fixed_string<128>&& _my_small_string_8); - - /*! - * @brief This function returns a constant reference to member my_small_string_8 - * @return Constant reference to member my_small_string_8 - */ - eProsima_user_DllExport const eprosima::fastrtps::fixed_string<128>& my_small_string_8() const; - - /*! - * @brief This function returns a reference to member my_small_string_8 - * @return Reference to member my_small_string_8 - */ - eProsima_user_DllExport eprosima::fastrtps::fixed_string<128>& my_small_string_8(); - - - /*! - * @brief This function copies the value in member my_large_string_8 - * @param _my_large_string_8 New value to be copied in member my_large_string_8 - */ - eProsima_user_DllExport void my_large_string_8( - const eprosima::fastrtps::fixed_string<500>& _my_large_string_8); - - /*! - * @brief This function moves the value in member my_large_string_8 - * @param _my_large_string_8 New value to be moved in member my_large_string_8 - */ - eProsima_user_DllExport void my_large_string_8( - eprosima::fastrtps::fixed_string<500>&& _my_large_string_8); - - /*! - * @brief This function returns a constant reference to member my_large_string_8 - * @return Constant reference to member my_large_string_8 - */ - eProsima_user_DllExport const eprosima::fastrtps::fixed_string<500>& my_large_string_8() const; - - /*! - * @brief This function returns a reference to member my_large_string_8 - * @return Reference to member my_large_string_8 - */ - eProsima_user_DllExport eprosima::fastrtps::fixed_string<500>& my_large_string_8(); - - - /*! - * @brief This function copies the value in member my_array_string - * @param _my_array_string New value to be copied in member my_array_string - */ - eProsima_user_DllExport void my_array_string( - const std::array, 5>, 5>& _my_array_string); - - /*! - * @brief This function moves the value in member my_array_string - * @param _my_array_string New value to be moved in member my_array_string - */ - eProsima_user_DllExport void my_array_string( - std::array, 5>, 5>&& _my_array_string); - - /*! - * @brief This function returns a constant reference to member my_array_string - * @return Constant reference to member my_array_string - */ - eProsima_user_DllExport const std::array, 5>, 5>& my_array_string() const; - - /*! - * @brief This function returns a reference to member my_array_string - * @return Reference to member my_array_string - */ - eProsima_user_DllExport std::array, 5>, 5>& my_array_string(); - - - /*! - * @brief This function copies the value in member multi_alias_array_42 - * @param _multi_alias_array_42 New value to be copied in member multi_alias_array_42 - */ - eProsima_user_DllExport void multi_alias_array_42( - const MA3& _multi_alias_array_42); - - /*! - * @brief This function moves the value in member multi_alias_array_42 - * @param _multi_alias_array_42 New value to be moved in member multi_alias_array_42 - */ - eProsima_user_DllExport void multi_alias_array_42( - MA3&& _multi_alias_array_42); - - /*! - * @brief This function returns a constant reference to member multi_alias_array_42 - * @return Constant reference to member multi_alias_array_42 - */ - eProsima_user_DllExport const MA3& multi_alias_array_42() const; - - /*! - * @brief This function returns a reference to member multi_alias_array_42 - * @return Reference to member multi_alias_array_42 - */ - eProsima_user_DllExport MA3& multi_alias_array_42(); - - - /*! - * @brief This function copies the value in member my_array_arrays - * @param _my_array_arrays New value to be copied in member my_array_arrays - */ - eProsima_user_DllExport void my_array_arrays( - const std::array& _my_array_arrays); - - /*! - * @brief This function moves the value in member my_array_arrays - * @param _my_array_arrays New value to be moved in member my_array_arrays - */ - eProsima_user_DllExport void my_array_arrays( - std::array&& _my_array_arrays); - - /*! - * @brief This function returns a constant reference to member my_array_arrays - * @return Constant reference to member my_array_arrays - */ - eProsima_user_DllExport const std::array& my_array_arrays() const; - - /*! - * @brief This function returns a reference to member my_array_arrays - * @return Reference to member my_array_arrays - */ - eProsima_user_DllExport std::array& my_array_arrays(); - - - /*! - * @brief This function copies the value in member my_sequences_array - * @param _my_sequences_array New value to be copied in member my_sequences_array - */ - eProsima_user_DllExport void my_sequences_array( - const std::array& _my_sequences_array); - - /*! - * @brief This function moves the value in member my_sequences_array - * @param _my_sequences_array New value to be moved in member my_sequences_array - */ - eProsima_user_DllExport void my_sequences_array( - std::array&& _my_sequences_array); - - /*! - * @brief This function returns a constant reference to member my_sequences_array - * @return Constant reference to member my_sequences_array - */ - eProsima_user_DllExport const std::array& my_sequences_array() const; - - /*! - * @brief This function returns a reference to member my_sequences_array - * @return Reference to member my_sequences_array - */ - eProsima_user_DllExport std::array& my_sequences_array(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const ComplexStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - uint8_t m_my_octet; - BasicStruct m_my_basic_struct; - MyAliasEnum m_my_alias_enum; - MyEnum m_my_enum; - std::vector m_my_sequence_octet; - std::vector m_my_sequence_struct; - std::array, 5>, 500> m_my_array_octet; - MyOctetArray500 m_my_octet_array_500; - std::array m_my_array_struct; - std::map m_my_map_octet_short; - std::map m_my_map_long_struct; - std::map>> m_my_map_long_seq_octet; - std::map m_my_map_long_octet_array_500; - std::map> m_my_map_long_lol_type; - eprosima::fastrtps::fixed_string<128> m_my_small_string_8; - eprosima::fastrtps::fixed_string<500> m_my_large_string_8; - std::array, 5>, 5> m_my_array_string; - MA3 m_multi_alias_array_42; - std::array m_my_array_arrays; - std::array m_my_sequences_array; - -}; - - - -/*! - * @brief This class represents the union MyUnion defined by the user in the IDL file. - * @ingroup Test - */ -class MyUnion -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MyUnion(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MyUnion(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MyUnion that will be copied. - */ - eProsima_user_DllExport MyUnion( - const MyUnion& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MyUnion that will be copied. - */ - eProsima_user_DllExport MyUnion( - MyUnion&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MyUnion that will be copied. - */ - eProsima_user_DllExport MyUnion& operator =( - const MyUnion& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MyUnion that will be copied. - */ - eProsima_user_DllExport MyUnion& operator =( - MyUnion&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MyUnion object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MyUnion& x) const; - - /*! - * @brief Comparison operator. - * @param x MyUnion object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MyUnion& x) const; - - /*! - * @brief This function sets the discriminator value. - * @param __d New value for the discriminator. - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the new value doesn't correspond to the selected union member. - */ - eProsima_user_DllExport void _d( - MyEnum __d); - - /*! - * @brief This function returns the value of the discriminator. - * @return Value of the discriminator - */ - eProsima_user_DllExport MyEnum _d() const; - - /*! - * @brief This function returns a reference to the discriminator. - * @return Reference to the discriminator. - */ - eProsima_user_DllExport MyEnum& _d(); - - /*! - * @brief This function copies the value in member basic - * @param _basic New value to be copied in member basic - */ - eProsima_user_DllExport void basic( - const BasicStruct& _basic); - - /*! - * @brief This function moves the value in member basic - * @param _basic New value to be moved in member basic - */ - eProsima_user_DllExport void basic( - BasicStruct&& _basic); - - /*! - * @brief This function returns a constant reference to member basic - * @return Constant reference to member basic - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport const BasicStruct& basic() const; - - /*! - * @brief This function returns a reference to member basic - * @return Reference to member basic - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport BasicStruct& basic(); - - - /*! - * @brief This function copies the value in member complex - * @param _complex New value to be copied in member complex - */ - eProsima_user_DllExport void complex( - const ComplexStruct& _complex); - - /*! - * @brief This function moves the value in member complex - * @param _complex New value to be moved in member complex - */ - eProsima_user_DllExport void complex( - ComplexStruct&& _complex); - - /*! - * @brief This function returns a constant reference to member complex - * @return Constant reference to member complex - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport const ComplexStruct& complex() const; - - /*! - * @brief This function returns a reference to member complex - * @return Reference to member complex - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport ComplexStruct& complex(); - - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const MyUnion& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - -private: - - MyEnum m__d; - - BasicStruct m_basic; - ComplexStruct m_complex; -}; - - - -/*! - * @brief This class represents the union MyUnion2 defined by the user in the IDL file. - * @ingroup Test - */ -class MyUnion2 -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MyUnion2(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MyUnion2(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MyUnion2 that will be copied. - */ - eProsima_user_DllExport MyUnion2( - const MyUnion2& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MyUnion2 that will be copied. - */ - eProsima_user_DllExport MyUnion2( - MyUnion2&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MyUnion2 that will be copied. - */ - eProsima_user_DllExport MyUnion2& operator =( - const MyUnion2& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MyUnion2 that will be copied. - */ - eProsima_user_DllExport MyUnion2& operator =( - MyUnion2&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MyUnion2 object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MyUnion2& x) const; - - /*! - * @brief Comparison operator. - * @param x MyUnion2 object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MyUnion2& x) const; - - /*! - * @brief This function sets the discriminator value. - * @param __d New value for the discriminator. - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the new value doesn't correspond to the selected union member. - */ - eProsima_user_DllExport void _d( - uint8_t __d); - - /*! - * @brief This function returns the value of the discriminator. - * @return Value of the discriminator - */ - eProsima_user_DllExport uint8_t _d() const; - - /*! - * @brief This function returns a reference to the discriminator. - * @return Reference to the discriminator. - */ - eProsima_user_DllExport uint8_t& _d(); - - /*! - * @brief This function sets a value in member uno - * @param _uno New value for member uno - */ - eProsima_user_DllExport void uno( - int32_t _uno); - - /*! - * @brief This function returns the value of member uno - * @return Value of member uno - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t uno() const; - - /*! - * @brief This function returns a reference to member uno - * @return Reference to member uno - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t& uno(); - - - /*! - * @brief This function copies the value in member imString - * @param _imString New value to be copied in member imString - */ - eProsima_user_DllExport void imString( - const std::string& _imString); - - /*! - * @brief This function moves the value in member imString - * @param _imString New value to be moved in member imString - */ - eProsima_user_DllExport void imString( - std::string&& _imString); - - /*! - * @brief This function returns a constant reference to member imString - * @return Constant reference to member imString - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport const std::string& imString() const; - - /*! - * @brief This function returns a reference to member imString - * @return Reference to member imString - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport std::string& imString(); - - - /*! - * @brief This function sets a value in member tres - * @param _tres New value for member tres - */ - eProsima_user_DllExport void tres( - int32_t _tres); - - /*! - * @brief This function returns the value of member tres - * @return Value of member tres - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t tres() const; - - /*! - * @brief This function returns a reference to member tres - * @return Reference to member tres - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t& tres(); - - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const MyUnion2& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - -private: - - uint8_t m__d; - - int32_t m_uno; - std::string m_imString; - int32_t m_tres; -}; - - - -/*! - * @brief This class represents the structure CompleteStruct defined by the user in the IDL file. - * @ingroup Test - */ -class CompleteStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport CompleteStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~CompleteStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object CompleteStruct that will be copied. - */ - eProsima_user_DllExport CompleteStruct( - const CompleteStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object CompleteStruct that will be copied. - */ - eProsima_user_DllExport CompleteStruct( - CompleteStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object CompleteStruct that will be copied. - */ - eProsima_user_DllExport CompleteStruct& operator =( - const CompleteStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object CompleteStruct that will be copied. - */ - eProsima_user_DllExport CompleteStruct& operator =( - CompleteStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x CompleteStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const CompleteStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x CompleteStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const CompleteStruct& x) const; - - /*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ - eProsima_user_DllExport void my_union( - const MyUnion& _my_union); - - /*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ - eProsima_user_DllExport void my_union( - MyUnion&& _my_union); - - /*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ - eProsima_user_DllExport const MyUnion& my_union() const; - - /*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ - eProsima_user_DllExport MyUnion& my_union(); - - - /*! - * @brief This function copies the value in member my_union_2 - * @param _my_union_2 New value to be copied in member my_union_2 - */ - eProsima_user_DllExport void my_union_2( - const MyUnion2& _my_union_2); - - /*! - * @brief This function moves the value in member my_union_2 - * @param _my_union_2 New value to be moved in member my_union_2 - */ - eProsima_user_DllExport void my_union_2( - MyUnion2&& _my_union_2); - - /*! - * @brief This function returns a constant reference to member my_union_2 - * @return Constant reference to member my_union_2 - */ - eProsima_user_DllExport const MyUnion2& my_union_2() const; - - /*! - * @brief This function returns a reference to member my_union_2 - * @return Reference to member my_union_2 - */ - eProsima_user_DllExport MyUnion2& my_union_2(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const CompleteStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - MyUnion m_my_union; - MyUnion2 m_my_union_2; - -}; - - - -/*! - * @brief This class represents the structure KeyedStruct defined by the user in the IDL file. - * @ingroup Test - */ -class KeyedStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport KeyedStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~KeyedStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object KeyedStruct that will be copied. - */ - eProsima_user_DllExport KeyedStruct( - const KeyedStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object KeyedStruct that will be copied. - */ - eProsima_user_DllExport KeyedStruct( - KeyedStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object KeyedStruct that will be copied. - */ - eProsima_user_DllExport KeyedStruct& operator =( - const KeyedStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object KeyedStruct that will be copied. - */ - eProsima_user_DllExport KeyedStruct& operator =( - KeyedStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x KeyedStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const KeyedStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x KeyedStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const KeyedStruct& x) const; - - /*! - * @brief This function sets a value in member key - * @param _key New value for member key - */ - eProsima_user_DllExport void key( - uint8_t _key); - - /*! - * @brief This function returns the value of member key - * @return Value of member key - */ - eProsima_user_DllExport uint8_t key() const; - - /*! - * @brief This function returns a reference to member key - * @return Reference to member key - */ - eProsima_user_DllExport uint8_t& key(); - - - /*! - * @brief This function copies the value in member basic - * @param _basic New value to be copied in member basic - */ - eProsima_user_DllExport void basic( - const BasicStruct& _basic); - - /*! - * @brief This function moves the value in member basic - * @param _basic New value to be moved in member basic - */ - eProsima_user_DllExport void basic( - BasicStruct&& _basic); - - /*! - * @brief This function returns a constant reference to member basic - * @return Constant reference to member basic - */ - eProsima_user_DllExport const BasicStruct& basic() const; - - /*! - * @brief This function returns a reference to member basic - * @return Reference to member basic - */ - eProsima_user_DllExport BasicStruct& basic(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const KeyedStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - uint8_t m_key; - BasicStruct m_basic; - -}; - - -#endif // _FAST_DDS_GENERATED_TEST_H_ - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/test/unittest/dynamic_types/idl/new_features_4_2.cxx b/test/unittest/dynamic_types/idl/new_features_4_2.cxx deleted file mode 100644 index 17bb0eb11e5..00000000000 --- a/test/unittest/dynamic_types/idl/new_features_4_2.cxx +++ /dev/null @@ -1,2065 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file new_features_4_2.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "new_features_4_2.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#include "new_features_4_2TypeObject.h" - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - - - - -NewAliases::NewAliases() -{ - // Just to register all known types - registernew_features_4_2Types(); -} - -NewAliases::~NewAliases() -{ -} - -NewAliases::NewAliases( - const NewAliases& x) -{ - m_int8_ = x.m_int8_; - m_uint8_ = x.m_uint8_; - m_int16_ = x.m_int16_; - m_uint16_ = x.m_uint16_; - m_int32_ = x.m_int32_; - m_uint32_ = x.m_uint32_; - m_int64_ = x.m_int64_; - m_uint64_ = x.m_uint64_; - m_local_string = x.m_local_string; -} - -NewAliases::NewAliases( - NewAliases&& x) noexcept -{ - m_int8_ = x.m_int8_; - m_uint8_ = x.m_uint8_; - m_int16_ = x.m_int16_; - m_uint16_ = x.m_uint16_; - m_int32_ = x.m_int32_; - m_uint32_ = x.m_uint32_; - m_int64_ = x.m_int64_; - m_uint64_ = x.m_uint64_; - m_local_string = std::move(x.m_local_string); -} - -NewAliases& NewAliases::operator =( - const NewAliases& x) -{ - - m_int8_ = x.m_int8_; - m_uint8_ = x.m_uint8_; - m_int16_ = x.m_int16_; - m_uint16_ = x.m_uint16_; - m_int32_ = x.m_int32_; - m_uint32_ = x.m_uint32_; - m_int64_ = x.m_int64_; - m_uint64_ = x.m_uint64_; - m_local_string = x.m_local_string; - return *this; -} - -NewAliases& NewAliases::operator =( - NewAliases&& x) noexcept -{ - - m_int8_ = x.m_int8_; - m_uint8_ = x.m_uint8_; - m_int16_ = x.m_int16_; - m_uint16_ = x.m_uint16_; - m_int32_ = x.m_int32_; - m_uint32_ = x.m_uint32_; - m_int64_ = x.m_int64_; - m_uint64_ = x.m_uint64_; - m_local_string = std::move(x.m_local_string); - return *this; -} - -bool NewAliases::operator ==( - const NewAliases& x) const -{ - return (m_int8_ == x.m_int8_ && - m_uint8_ == x.m_uint8_ && - m_int16_ == x.m_int16_ && - m_uint16_ == x.m_uint16_ && - m_int32_ == x.m_int32_ && - m_uint32_ == x.m_uint32_ && - m_int64_ == x.m_int64_ && - m_uint64_ == x.m_uint64_ && - m_local_string == x.m_local_string); -} - -bool NewAliases::operator !=( - const NewAliases& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member int8_ - * @param _int8_ New value for member int8_ - */ -void NewAliases::int8_( - int8_t _int8_) -{ - m_int8_ = _int8_; -} - -/*! - * @brief This function returns the value of member int8_ - * @return Value of member int8_ - */ -int8_t NewAliases::int8_() const -{ - return m_int8_; -} - -/*! - * @brief This function returns a reference to member int8_ - * @return Reference to member int8_ - */ -int8_t& NewAliases::int8_() -{ - return m_int8_; -} - - -/*! - * @brief This function sets a value in member uint8_ - * @param _uint8_ New value for member uint8_ - */ -void NewAliases::uint8_( - uint8_t _uint8_) -{ - m_uint8_ = _uint8_; -} - -/*! - * @brief This function returns the value of member uint8_ - * @return Value of member uint8_ - */ -uint8_t NewAliases::uint8_() const -{ - return m_uint8_; -} - -/*! - * @brief This function returns a reference to member uint8_ - * @return Reference to member uint8_ - */ -uint8_t& NewAliases::uint8_() -{ - return m_uint8_; -} - - -/*! - * @brief This function sets a value in member int16_ - * @param _int16_ New value for member int16_ - */ -void NewAliases::int16_( - int16_t _int16_) -{ - m_int16_ = _int16_; -} - -/*! - * @brief This function returns the value of member int16_ - * @return Value of member int16_ - */ -int16_t NewAliases::int16_() const -{ - return m_int16_; -} - -/*! - * @brief This function returns a reference to member int16_ - * @return Reference to member int16_ - */ -int16_t& NewAliases::int16_() -{ - return m_int16_; -} - - -/*! - * @brief This function sets a value in member uint16_ - * @param _uint16_ New value for member uint16_ - */ -void NewAliases::uint16_( - uint16_t _uint16_) -{ - m_uint16_ = _uint16_; -} - -/*! - * @brief This function returns the value of member uint16_ - * @return Value of member uint16_ - */ -uint16_t NewAliases::uint16_() const -{ - return m_uint16_; -} - -/*! - * @brief This function returns a reference to member uint16_ - * @return Reference to member uint16_ - */ -uint16_t& NewAliases::uint16_() -{ - return m_uint16_; -} - - -/*! - * @brief This function sets a value in member int32_ - * @param _int32_ New value for member int32_ - */ -void NewAliases::int32_( - int32_t _int32_) -{ - m_int32_ = _int32_; -} - -/*! - * @brief This function returns the value of member int32_ - * @return Value of member int32_ - */ -int32_t NewAliases::int32_() const -{ - return m_int32_; -} - -/*! - * @brief This function returns a reference to member int32_ - * @return Reference to member int32_ - */ -int32_t& NewAliases::int32_() -{ - return m_int32_; -} - - -/*! - * @brief This function sets a value in member uint32_ - * @param _uint32_ New value for member uint32_ - */ -void NewAliases::uint32_( - uint32_t _uint32_) -{ - m_uint32_ = _uint32_; -} - -/*! - * @brief This function returns the value of member uint32_ - * @return Value of member uint32_ - */ -uint32_t NewAliases::uint32_() const -{ - return m_uint32_; -} - -/*! - * @brief This function returns a reference to member uint32_ - * @return Reference to member uint32_ - */ -uint32_t& NewAliases::uint32_() -{ - return m_uint32_; -} - - -/*! - * @brief This function sets a value in member int64_ - * @param _int64_ New value for member int64_ - */ -void NewAliases::int64_( - int64_t _int64_) -{ - m_int64_ = _int64_; -} - -/*! - * @brief This function returns the value of member int64_ - * @return Value of member int64_ - */ -int64_t NewAliases::int64_() const -{ - return m_int64_; -} - -/*! - * @brief This function returns a reference to member int64_ - * @return Reference to member int64_ - */ -int64_t& NewAliases::int64_() -{ - return m_int64_; -} - - -/*! - * @brief This function sets a value in member uint64_ - * @param _uint64_ New value for member uint64_ - */ -void NewAliases::uint64_( - uint64_t _uint64_) -{ - m_uint64_ = _uint64_; -} - -/*! - * @brief This function returns the value of member uint64_ - * @return Value of member uint64_ - */ -uint64_t NewAliases::uint64_() const -{ - return m_uint64_; -} - -/*! - * @brief This function returns a reference to member uint64_ - * @return Reference to member uint64_ - */ -uint64_t& NewAliases::uint64_() -{ - return m_uint64_; -} - - -/*! - * @brief This function copies the value in member local_string - * @param _local_string New value to be copied in member local_string - */ -void NewAliases::local_string( - const std::string& _local_string) -{ - m_local_string = _local_string; -} - -/*! - * @brief This function moves the value in member local_string - * @param _local_string New value to be moved in member local_string - */ -void NewAliases::local_string( - std::string&& _local_string) -{ - m_local_string = std::move(_local_string); -} - -/*! - * @brief This function returns a constant reference to member local_string - * @return Constant reference to member local_string - */ -const std::string& NewAliases::local_string() const -{ - return m_local_string; -} - -/*! - * @brief This function returns a reference to member local_string - * @return Reference to member local_string - */ -std::string& NewAliases::local_string() -{ - return m_local_string; -} - - - - -WCharUnion::WCharUnion() -{ - m__d = 'a'; -} - -WCharUnion::~WCharUnion() -{ -} - -WCharUnion::WCharUnion( - const WCharUnion& x) -{ - m__d = x.m__d; - - switch (m__d) - { - case 'a': - m_case_zero = x.m_case_zero; - break; - - - case 'b': - m_case_one = x.m_case_one; - break; - - default: - break; - } -} - -WCharUnion::WCharUnion( - WCharUnion&& x) noexcept -{ - m__d = x.m__d; - - switch (m__d) - { - case 'a': - m_case_zero = x.m_case_zero; - break; - - - case 'b': - m_case_one = x.m_case_one; - break; - - default: - break; - } -} - -WCharUnion& WCharUnion::operator =( - const WCharUnion& x) -{ - m__d = x.m__d; - - switch (m__d) - { - case 'a': - m_case_zero = x.m_case_zero; - break; - - - case 'b': - m_case_one = x.m_case_one; - break; - - default: - break; - } - - return *this; -} - -WCharUnion& WCharUnion::operator =( - WCharUnion&& x) noexcept -{ - m__d = x.m__d; - - switch (m__d) - { - case 'a': - m_case_zero = x.m_case_zero; - break; - - - case 'b': - m_case_one = x.m_case_one; - break; - - default: - break; - } - - return *this; -} - -bool WCharUnion::operator ==( - const WCharUnion& x) const -{ - if (m__d != x.m__d) - { - return false; - } - - switch (m__d) - { - case 'a': - return (m_case_zero == x.m_case_zero); - break; - - - case 'b': - return (m_case_one == x.m_case_one); - break; - - default: - break; - } - return false; -} - -bool WCharUnion::operator !=( - const WCharUnion& x) const -{ - return !(*this == x); -} - -void WCharUnion::_d( - wchar_t __d) -{ - bool b = false; - - switch (m__d) - { - case 'a': - switch (__d) - { - case 'a': - b = true; - break; - default: - break; - } - break; - - - case 'b': - switch (__d) - { - case 'b': - b = true; - break; - default: - break; - } - break; - - default: - break; - } - - if (!b) - { - throw BadParamException("Discriminator doesn't correspond with the selected union member"); - } - - m__d = __d; -} - -wchar_t WCharUnion::_d() const -{ - return m__d; -} - -wchar_t& WCharUnion::_d() -{ - return m__d; -} - -void WCharUnion::case_zero( - int32_t _case_zero) -{ - m_case_zero = _case_zero; - m__d = 'a'; - -} - -int32_t WCharUnion::case_zero() const -{ - bool b = false; - - switch (m__d) - { - case 'a': - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_case_zero; -} - -int32_t& WCharUnion::case_zero() -{ - bool b = false; - - switch (m__d) - { - case 'a': - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_case_zero; -} - - -void WCharUnion::case_one( - int32_t _case_one) -{ - m_case_one = _case_one; - m__d = 'b'; - -} - -int32_t WCharUnion::case_one() const -{ - bool b = false; - - switch (m__d) - { - case 'b': - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_case_one; -} - -int32_t& WCharUnion::case_one() -{ - bool b = false; - - switch (m__d) - { - case 'b': - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_case_one; -} - - - - -OctetUnion::OctetUnion() -{ - m__d = 5; -} - -OctetUnion::~OctetUnion() -{ -} - -OctetUnion::OctetUnion( - const OctetUnion& x) -{ - m__d = x.m__d; - - switch (m__d) - { - case 5: - m_case_five = x.m_case_five; - break; - - - case 7: - m_case_seven = x.m_case_seven; - break; - - default: - break; - } -} - -OctetUnion::OctetUnion( - OctetUnion&& x) noexcept -{ - m__d = x.m__d; - - switch (m__d) - { - case 5: - m_case_five = x.m_case_five; - break; - - - case 7: - m_case_seven = x.m_case_seven; - break; - - default: - break; - } -} - -OctetUnion& OctetUnion::operator =( - const OctetUnion& x) -{ - m__d = x.m__d; - - switch (m__d) - { - case 5: - m_case_five = x.m_case_five; - break; - - - case 7: - m_case_seven = x.m_case_seven; - break; - - default: - break; - } - - return *this; -} - -OctetUnion& OctetUnion::operator =( - OctetUnion&& x) noexcept -{ - m__d = x.m__d; - - switch (m__d) - { - case 5: - m_case_five = x.m_case_five; - break; - - - case 7: - m_case_seven = x.m_case_seven; - break; - - default: - break; - } - - return *this; -} - -bool OctetUnion::operator ==( - const OctetUnion& x) const -{ - if (m__d != x.m__d) - { - return false; - } - - switch (m__d) - { - case 5: - return (m_case_five == x.m_case_five); - break; - - - case 7: - return (m_case_seven == x.m_case_seven); - break; - - default: - break; - } - return false; -} - -bool OctetUnion::operator !=( - const OctetUnion& x) const -{ - return !(*this == x); -} - -void OctetUnion::_d( - uint8_t __d) -{ - bool b = false; - - switch (m__d) - { - case 5: - switch (__d) - { - case 5: - b = true; - break; - default: - break; - } - break; - - - case 7: - switch (__d) - { - case 7: - b = true; - break; - default: - break; - } - break; - - default: - break; - } - - if (!b) - { - throw BadParamException("Discriminator doesn't correspond with the selected union member"); - } - - m__d = __d; -} - -uint8_t OctetUnion::_d() const -{ - return m__d; -} - -uint8_t& OctetUnion::_d() -{ - return m__d; -} - -void OctetUnion::case_five( - int32_t _case_five) -{ - m_case_five = _case_five; - m__d = 5; - -} - -int32_t OctetUnion::case_five() const -{ - bool b = false; - - switch (m__d) - { - case 5: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_case_five; -} - -int32_t& OctetUnion::case_five() -{ - bool b = false; - - switch (m__d) - { - case 5: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_case_five; -} - - -void OctetUnion::case_seven( - int32_t _case_seven) -{ - m_case_seven = _case_seven; - m__d = 7; - -} - -int32_t OctetUnion::case_seven() const -{ - bool b = false; - - switch (m__d) - { - case 7: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_case_seven; -} - -int32_t& OctetUnion::case_seven() -{ - bool b = false; - - switch (m__d) - { - case 7: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_case_seven; -} - - - - -Int8Union::Int8Union() -{ - m__d = 3; -} - -Int8Union::~Int8Union() -{ -} - -Int8Union::Int8Union( - const Int8Union& x) -{ - m__d = x.m__d; - - switch (m__d) - { - case 3: - m_case_three = x.m_case_three; - break; - - - case 6: - m_case_six = x.m_case_six; - break; - - default: - break; - } -} - -Int8Union::Int8Union( - Int8Union&& x) noexcept -{ - m__d = x.m__d; - - switch (m__d) - { - case 3: - m_case_three = x.m_case_three; - break; - - - case 6: - m_case_six = x.m_case_six; - break; - - default: - break; - } -} - -Int8Union& Int8Union::operator =( - const Int8Union& x) -{ - m__d = x.m__d; - - switch (m__d) - { - case 3: - m_case_three = x.m_case_three; - break; - - - case 6: - m_case_six = x.m_case_six; - break; - - default: - break; - } - - return *this; -} - -Int8Union& Int8Union::operator =( - Int8Union&& x) noexcept -{ - m__d = x.m__d; - - switch (m__d) - { - case 3: - m_case_three = x.m_case_three; - break; - - - case 6: - m_case_six = x.m_case_six; - break; - - default: - break; - } - - return *this; -} - -bool Int8Union::operator ==( - const Int8Union& x) const -{ - if (m__d != x.m__d) - { - return false; - } - - switch (m__d) - { - case 3: - return (m_case_three == x.m_case_three); - break; - - - case 6: - return (m_case_six == x.m_case_six); - break; - - default: - break; - } - return false; -} - -bool Int8Union::operator !=( - const Int8Union& x) const -{ - return !(*this == x); -} - -void Int8Union::_d( - int8_t __d) -{ - bool b = false; - - switch (m__d) - { - case 3: - switch (__d) - { - case 3: - b = true; - break; - default: - break; - } - break; - - - case 6: - switch (__d) - { - case 6: - b = true; - break; - default: - break; - } - break; - - default: - break; - } - - if (!b) - { - throw BadParamException("Discriminator doesn't correspond with the selected union member"); - } - - m__d = __d; -} - -int8_t Int8Union::_d() const -{ - return m__d; -} - -int8_t& Int8Union::_d() -{ - return m__d; -} - -void Int8Union::case_three( - int32_t _case_three) -{ - m_case_three = _case_three; - m__d = 3; - -} - -int32_t Int8Union::case_three() const -{ - bool b = false; - - switch (m__d) - { - case 3: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_case_three; -} - -int32_t& Int8Union::case_three() -{ - bool b = false; - - switch (m__d) - { - case 3: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_case_three; -} - - -void Int8Union::case_six( - int32_t _case_six) -{ - m_case_six = _case_six; - m__d = 6; - -} - -int32_t Int8Union::case_six() const -{ - bool b = false; - - switch (m__d) - { - case 6: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_case_six; -} - -int32_t& Int8Union::case_six() -{ - bool b = false; - - switch (m__d) - { - case 6: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_case_six; -} - - -namespace bitmodule { - -ParentBitset::ParentBitset(){ - // Just to register all known types - registernew_features_4_2Types(); -} - -ParentBitset::~ParentBitset() -{ -} - -ParentBitset::ParentBitset( - const ParentBitset& x){ - m_bitset = x.m_bitset; -} - -ParentBitset::ParentBitset( - ParentBitset&& x) noexcept { - m_bitset = x.m_bitset; -} - -ParentBitset& ParentBitset::operator =( - const ParentBitset& x) -{ - - m_bitset = x.m_bitset; - - return *this; -} - -ParentBitset& ParentBitset::operator =( - ParentBitset&& x) noexcept -{ - - m_bitset = x.m_bitset; - - return *this; -} - -bool ParentBitset::operator ==( - const ParentBitset& x) const -{ - - return m_bitset == x.m_bitset; -} - -bool ParentBitset::operator !=( - const ParentBitset& x) const -{ - return !(*this == x); -} - - -void ParentBitset::parent_bitfield( - uint32_t _parent_bitfield) -{ - int base = 0; - int size = 17; - for (int i = base; i < base + size; ++i) - { - m_bitset.set(i, !!(_parent_bitfield & 0x01)); - _parent_bitfield = _parent_bitfield >> 1; - } - -} - -uint32_t ParentBitset::parent_bitfield() const -{ - int base = 0; - int size = 17; - std::bitset<17> aux; - for (int i = 0; i < size; ++i) - { - aux.set(i, m_bitset.test(i + base)); - } - return static_cast(aux.to_ullong()); - -} - - -std::bitset<17> ParentBitset::bitset() const -{ - std::string str_value; - - str_value = m_bitset.to_string() + str_value; - - return std::bitset<17>(str_value); -} - -void ParentBitset::bitset( - const std::bitset<17>& bitset) -{ - std::string str_value {bitset.to_string()}; - size_t base_diff {0}; - size_t last_post {std::string::npos}; - - base_diff += 17; - m_bitset = std::bitset<17>(str_value.substr(str_value.length() - base_diff, last_post)); -} - -MyBitset::MyBitset() - : bitmodule::ParentBitset(){ - // Just to register all known types - registernew_features_4_2Types(); -} - -MyBitset::~MyBitset() -{ -} - -MyBitset::MyBitset( - const MyBitset& x) - : bitmodule::ParentBitset(x){ - m_bitset = x.m_bitset; -} - -MyBitset::MyBitset( - MyBitset&& x) noexcept - : bitmodule::ParentBitset(std::move(x)){ - m_bitset = x.m_bitset; -} - -MyBitset& MyBitset::operator =( - const MyBitset& x) -{ - bitmodule::ParentBitset::operator =(x); - - m_bitset = x.m_bitset; - - return *this; -} - -MyBitset& MyBitset::operator =( - MyBitset&& x) noexcept -{ - bitmodule::ParentBitset::operator =(std::move(x)); - - m_bitset = x.m_bitset; - - return *this; -} - -bool MyBitset::operator ==( - const MyBitset& x) const -{ - if (bitmodule::ParentBitset::operator !=(x)) return false; - - return m_bitset == x.m_bitset; -} - -bool MyBitset::operator !=( - const MyBitset& x) const -{ - return !(*this == x); -} - - -void MyBitset::a( - char _a) -{ - int base = 0; - int size = 3; - for (int i = base; i < base + size; ++i) - { - m_bitset.set(i, !!(_a & 0x01)); - _a = _a >> 1; - } - -} - -char MyBitset::a() const -{ - int base = 0; - int size = 3; - std::bitset<3> aux; - for (int i = 0; i < size; ++i) - { - aux.set(i, m_bitset.test(i + base)); - } - return static_cast(aux.to_ullong()); - -} - - -void MyBitset::b( - bool _b) -{ - int base = 3; - m_bitset.set(base, _b); -} - -bool MyBitset::b() const -{ - int base = 3; - return m_bitset.test(base); -} - - - -void MyBitset::c( - uint16_t _c) -{ - int base = 8; - int size = 10; - for (int i = base; i < base + size; ++i) - { - m_bitset.set(i, !!(_c & 0x01)); - _c = _c >> 1; - } - -} - -uint16_t MyBitset::c() const -{ - int base = 8; - int size = 10; - std::bitset<10> aux; - for (int i = 0; i < size; ++i) - { - aux.set(i, m_bitset.test(i + base)); - } - return static_cast(aux.to_ullong()); - -} - - -void MyBitset::d( - int16_t _d) -{ - int base = 18; - int size = 5; - for (int i = base; i < base + size; ++i) - { - m_bitset.set(i, !!(_d & 0x01)); - _d = _d >> 1; - } - -} - -int16_t MyBitset::d() const -{ - int base = 18; - int size = 5; - std::bitset<5> aux; - for (int i = 0; i < size; ++i) - { - aux.set(i, m_bitset.test(i + base)); - } - return static_cast(aux.to_ullong()); - -} - - -void MyBitset::e( - int16_t _e) -{ - int base = 23; - int size = 5; - for (int i = base; i < base + size; ++i) - { - m_bitset.set(i, !!(_e & 0x01)); - _e = _e >> 1; - } - -} - -int16_t MyBitset::e() const -{ - int base = 23; - int size = 5; - std::bitset<5> aux; - for (int i = 0; i < size; ++i) - { - aux.set(i, m_bitset.test(i + base)); - } - return static_cast(aux.to_ullong()); - -} - - -void MyBitset::f( - int16_t _f) -{ - int base = 28; - int size = 5; - for (int i = base; i < base + size; ++i) - { - m_bitset.set(i, !!(_f & 0x01)); - _f = _f >> 1; - } - -} - -int16_t MyBitset::f() const -{ - int base = 28; - int size = 5; - std::bitset<5> aux; - for (int i = 0; i < size; ++i) - { - aux.set(i, m_bitset.test(i + base)); - } - return static_cast(aux.to_ullong()); - -} - - -std::bitset<50> MyBitset::bitset() const -{ - std::string str_value; - - str_value = static_cast(this)->bitset().to_string() + str_value; - - str_value = m_bitset.to_string() + str_value; - - return std::bitset<50>(str_value); -} - -void MyBitset::bitset( - const std::bitset<50>& bitset) -{ - std::string str_value {bitset.to_string()}; - size_t base_diff {0}; - size_t last_post {std::string::npos}; - - { - base_diff += 17; - std::bitset<17> internal_bitset(str_value.substr(str_value.length() - base_diff, last_post)); - static_cast(this)->bitset(internal_bitset); - last_post = base_diff; - } - - base_diff += 33; - m_bitset = std::bitset<33>(str_value.substr(str_value.length() - base_diff, last_post)); -} - - - - -BitsetBitmask::BitsetBitmask() -{ - // Just to register all known types - registernew_features_4_2Types(); -} - -BitsetBitmask::~BitsetBitmask() -{ -} - -BitsetBitmask::BitsetBitmask( - const BitsetBitmask& x) -{ - m_mybitset = x.m_mybitset; - m_mybitmask = x.m_mybitmask; -} - -BitsetBitmask::BitsetBitmask( - BitsetBitmask&& x) noexcept -{ - m_mybitset = std::move(x.m_mybitset); - m_mybitmask = std::move(x.m_mybitmask); -} - -BitsetBitmask& BitsetBitmask::operator =( - const BitsetBitmask& x) -{ - - m_mybitset = x.m_mybitset; - m_mybitmask = x.m_mybitmask; - return *this; -} - -BitsetBitmask& BitsetBitmask::operator =( - BitsetBitmask&& x) noexcept -{ - - m_mybitset = std::move(x.m_mybitset); - m_mybitmask = std::move(x.m_mybitmask); - return *this; -} - -bool BitsetBitmask::operator ==( - const BitsetBitmask& x) const -{ - return (m_mybitset == x.m_mybitset && - m_mybitmask == x.m_mybitmask); -} - -bool BitsetBitmask::operator !=( - const BitsetBitmask& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member mybitset - * @param _mybitset New value to be copied in member mybitset - */ -void BitsetBitmask::mybitset( - const bitmodule::MyBitset& _mybitset) -{ - m_mybitset = _mybitset; -} - -/*! - * @brief This function moves the value in member mybitset - * @param _mybitset New value to be moved in member mybitset - */ -void BitsetBitmask::mybitset( - bitmodule::MyBitset&& _mybitset) -{ - m_mybitset = std::move(_mybitset); -} - -/*! - * @brief This function returns a constant reference to member mybitset - * @return Constant reference to member mybitset - */ -const bitmodule::MyBitset& BitsetBitmask::mybitset() const -{ - return m_mybitset; -} - -/*! - * @brief This function returns a reference to member mybitset - * @return Reference to member mybitset - */ -bitmodule::MyBitset& BitsetBitmask::mybitset() -{ - return m_mybitset; -} - - -/*! - * @brief This function copies the value in member mybitmask - * @param _mybitmask New value to be copied in member mybitmask - */ -void BitsetBitmask::mybitmask( - const bitmodule::MyBitMask& _mybitmask) -{ - m_mybitmask = _mybitmask; -} - -/*! - * @brief This function moves the value in member mybitmask - * @param _mybitmask New value to be moved in member mybitmask - */ -void BitsetBitmask::mybitmask( - bitmodule::MyBitMask&& _mybitmask) -{ - m_mybitmask = std::move(_mybitmask); -} - -/*! - * @brief This function returns a constant reference to member mybitmask - * @return Constant reference to member mybitmask - */ -const bitmodule::MyBitMask& BitsetBitmask::mybitmask() const -{ - return m_mybitmask; -} - -/*! - * @brief This function returns a reference to member mybitmask - * @return Reference to member mybitmask - */ -bitmodule::MyBitMask& BitsetBitmask::mybitmask() -{ - return m_mybitmask; -} - - - - -BM2::BM2() - : bitmodule::BitsetBitmask() - -{ - // Just to register all known types - registernew_features_4_2Types(); -} - -BM2::~BM2() -{ -} - -BM2::BM2( - const BM2& x) - : bitmodule::BitsetBitmask(x) - -{ - m_two = x.m_two; - m_mylong = x.m_mylong; -} - -BM2::BM2( - BM2&& x) noexcept - : bitmodule::BitsetBitmask(std::move(x)) - -{ - m_two = std::move(x.m_two); - m_mylong = x.m_mylong; -} - -BM2& BM2::operator =( - const BM2& x) -{ - bitmodule::BitsetBitmask::operator =(x); - - m_two = x.m_two; - m_mylong = x.m_mylong; - return *this; -} - -BM2& BM2::operator =( - BM2&& x) noexcept -{ - bitmodule::BitsetBitmask::operator =(std::move(x)); - - m_two = std::move(x.m_two); - m_mylong = x.m_mylong; - return *this; -} - -bool BM2::operator ==( - const BM2& x) const -{ - if (bitmodule::BitsetBitmask::operator !=(x)) - { - return false; - } - return (m_two == x.m_two && - m_mylong == x.m_mylong); -} - -bool BM2::operator !=( - const BM2& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member two - * @param _two New value to be copied in member two - */ -void BM2::two( - const bitmodule::MyBitMask& _two) -{ - m_two = _two; -} - -/*! - * @brief This function moves the value in member two - * @param _two New value to be moved in member two - */ -void BM2::two( - bitmodule::MyBitMask&& _two) -{ - m_two = std::move(_two); -} - -/*! - * @brief This function returns a constant reference to member two - * @return Constant reference to member two - */ -const bitmodule::MyBitMask& BM2::two() const -{ - return m_two; -} - -/*! - * @brief This function returns a reference to member two - * @return Reference to member two - */ -bitmodule::MyBitMask& BM2::two() -{ - return m_two; -} - - -/*! - * @brief This function sets a value in member mylong - * @param _mylong New value for member mylong - */ -void BM2::mylong( - int32_t _mylong) -{ - m_mylong = _mylong; -} - -/*! - * @brief This function returns the value of member mylong - * @return Value of member mylong - */ -int32_t BM2::mylong() const -{ - return m_mylong; -} - -/*! - * @brief This function returns a reference to member mylong - * @return Reference to member mylong - */ -int32_t& BM2::mylong() -{ - return m_mylong; -} - - - - -} // namespace bitmodule - - -StructTest::StructTest() - : NewAliases() - -{ - // Just to register all known types - registernew_features_4_2Types(); -} - -StructTest::~StructTest() -{ -} - -StructTest::StructTest( - const StructTest& x) - : NewAliases(x) - -{ - m_octetUnion = x.m_octetUnion; - m_int8Union = x.m_int8Union; - m_myStructBits = x.m_myStructBits; -} - -StructTest::StructTest( - StructTest&& x) noexcept - : NewAliases(std::move(x)) - -{ - m_octetUnion = std::move(x.m_octetUnion); - m_int8Union = std::move(x.m_int8Union); - m_myStructBits = std::move(x.m_myStructBits); -} - -StructTest& StructTest::operator =( - const StructTest& x) -{ - NewAliases::operator =(x); - - m_octetUnion = x.m_octetUnion; - m_int8Union = x.m_int8Union; - m_myStructBits = x.m_myStructBits; - return *this; -} - -StructTest& StructTest::operator =( - StructTest&& x) noexcept -{ - NewAliases::operator =(std::move(x)); - - m_octetUnion = std::move(x.m_octetUnion); - m_int8Union = std::move(x.m_int8Union); - m_myStructBits = std::move(x.m_myStructBits); - return *this; -} - -bool StructTest::operator ==( - const StructTest& x) const -{ - if (NewAliases::operator !=(x)) - { - return false; - } - return (m_octetUnion == x.m_octetUnion && - m_int8Union == x.m_int8Union && - m_myStructBits == x.m_myStructBits); -} - -bool StructTest::operator !=( - const StructTest& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member octetUnion - * @param _octetUnion New value to be copied in member octetUnion - */ -void StructTest::octetUnion( - const OctetUnion& _octetUnion) -{ - m_octetUnion = _octetUnion; -} - -/*! - * @brief This function moves the value in member octetUnion - * @param _octetUnion New value to be moved in member octetUnion - */ -void StructTest::octetUnion( - OctetUnion&& _octetUnion) -{ - m_octetUnion = std::move(_octetUnion); -} - -/*! - * @brief This function returns a constant reference to member octetUnion - * @return Constant reference to member octetUnion - */ -const OctetUnion& StructTest::octetUnion() const -{ - return m_octetUnion; -} - -/*! - * @brief This function returns a reference to member octetUnion - * @return Reference to member octetUnion - */ -OctetUnion& StructTest::octetUnion() -{ - return m_octetUnion; -} - - -/*! - * @brief This function copies the value in member int8Union - * @param _int8Union New value to be copied in member int8Union - */ -void StructTest::int8Union( - const Int8Union& _int8Union) -{ - m_int8Union = _int8Union; -} - -/*! - * @brief This function moves the value in member int8Union - * @param _int8Union New value to be moved in member int8Union - */ -void StructTest::int8Union( - Int8Union&& _int8Union) -{ - m_int8Union = std::move(_int8Union); -} - -/*! - * @brief This function returns a constant reference to member int8Union - * @return Constant reference to member int8Union - */ -const Int8Union& StructTest::int8Union() const -{ - return m_int8Union; -} - -/*! - * @brief This function returns a reference to member int8Union - * @return Reference to member int8Union - */ -Int8Union& StructTest::int8Union() -{ - return m_int8Union; -} - - -/*! - * @brief This function copies the value in member myStructBits - * @param _myStructBits New value to be copied in member myStructBits - */ -void StructTest::myStructBits( - const bitmodule::BM2& _myStructBits) -{ - m_myStructBits = _myStructBits; -} - -/*! - * @brief This function moves the value in member myStructBits - * @param _myStructBits New value to be moved in member myStructBits - */ -void StructTest::myStructBits( - bitmodule::BM2&& _myStructBits) -{ - m_myStructBits = std::move(_myStructBits); -} - -/*! - * @brief This function returns a constant reference to member myStructBits - * @return Constant reference to member myStructBits - */ -const bitmodule::BM2& StructTest::myStructBits() const -{ - return m_myStructBits; -} - -/*! - * @brief This function returns a reference to member myStructBits - * @return Reference to member myStructBits - */ -bitmodule::BM2& StructTest::myStructBits() -{ - return m_myStructBits; -} - - -// Include auxiliary functions like for serializing/deserializing. -#include "new_features_4_2CdrAux.ipp" - -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/test/unittest/dynamic_types/idl/new_features_4_2.h b/test/unittest/dynamic_types/idl/new_features_4_2.h deleted file mode 100644 index de85dadf42c..00000000000 --- a/test/unittest/dynamic_types/idl/new_features_4_2.h +++ /dev/null @@ -1,1380 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file new_features_4_2.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#include -#include "new_features_4_2v1.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#ifndef _FAST_DDS_GENERATED_NEW_FEATURES_4_2_H_ -#define _FAST_DDS_GENERATED_NEW_FEATURES_4_2_H_ - -#include -#include -#include -#include -#include -#include - -#include -#include -#include - - - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define eProsima_user_DllExport -#endif // _WIN32 - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(NEW_FEATURES_4_2_SOURCE) -#define NEW_FEATURES_4_2_DllAPI __declspec( dllexport ) -#else -#define NEW_FEATURES_4_2_DllAPI __declspec( dllimport ) -#endif // NEW_FEATURES_4_2_SOURCE -#else -#define NEW_FEATURES_4_2_DllAPI -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define NEW_FEATURES_4_2_DllAPI -#endif // _WIN32 - -namespace eprosima { -namespace fastcdr { -class Cdr; -class CdrSizeCalculator; -} // namespace fastcdr -} // namespace eprosima - - - - - -/*! - * @brief This class represents the structure NewAliases defined by the user in the IDL file. - * @ingroup new_features_4_2 - */ -class NewAliases -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport NewAliases(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~NewAliases(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object NewAliases that will be copied. - */ - eProsima_user_DllExport NewAliases( - const NewAliases& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object NewAliases that will be copied. - */ - eProsima_user_DllExport NewAliases( - NewAliases&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object NewAliases that will be copied. - */ - eProsima_user_DllExport NewAliases& operator =( - const NewAliases& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object NewAliases that will be copied. - */ - eProsima_user_DllExport NewAliases& operator =( - NewAliases&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x NewAliases object to compare. - */ - eProsima_user_DllExport bool operator ==( - const NewAliases& x) const; - - /*! - * @brief Comparison operator. - * @param x NewAliases object to compare. - */ - eProsima_user_DllExport bool operator !=( - const NewAliases& x) const; - - /*! - * @brief This function sets a value in member int8_ - * @param _int8_ New value for member int8_ - */ - eProsima_user_DllExport void int8_( - int8_t _int8_); - - /*! - * @brief This function returns the value of member int8_ - * @return Value of member int8_ - */ - eProsima_user_DllExport int8_t int8_() const; - - /*! - * @brief This function returns a reference to member int8_ - * @return Reference to member int8_ - */ - eProsima_user_DllExport int8_t& int8_(); - - - /*! - * @brief This function sets a value in member uint8_ - * @param _uint8_ New value for member uint8_ - */ - eProsima_user_DllExport void uint8_( - uint8_t _uint8_); - - /*! - * @brief This function returns the value of member uint8_ - * @return Value of member uint8_ - */ - eProsima_user_DllExport uint8_t uint8_() const; - - /*! - * @brief This function returns a reference to member uint8_ - * @return Reference to member uint8_ - */ - eProsima_user_DllExport uint8_t& uint8_(); - - - /*! - * @brief This function sets a value in member int16_ - * @param _int16_ New value for member int16_ - */ - eProsima_user_DllExport void int16_( - int16_t _int16_); - - /*! - * @brief This function returns the value of member int16_ - * @return Value of member int16_ - */ - eProsima_user_DllExport int16_t int16_() const; - - /*! - * @brief This function returns a reference to member int16_ - * @return Reference to member int16_ - */ - eProsima_user_DllExport int16_t& int16_(); - - - /*! - * @brief This function sets a value in member uint16_ - * @param _uint16_ New value for member uint16_ - */ - eProsima_user_DllExport void uint16_( - uint16_t _uint16_); - - /*! - * @brief This function returns the value of member uint16_ - * @return Value of member uint16_ - */ - eProsima_user_DllExport uint16_t uint16_() const; - - /*! - * @brief This function returns a reference to member uint16_ - * @return Reference to member uint16_ - */ - eProsima_user_DllExport uint16_t& uint16_(); - - - /*! - * @brief This function sets a value in member int32_ - * @param _int32_ New value for member int32_ - */ - eProsima_user_DllExport void int32_( - int32_t _int32_); - - /*! - * @brief This function returns the value of member int32_ - * @return Value of member int32_ - */ - eProsima_user_DllExport int32_t int32_() const; - - /*! - * @brief This function returns a reference to member int32_ - * @return Reference to member int32_ - */ - eProsima_user_DllExport int32_t& int32_(); - - - /*! - * @brief This function sets a value in member uint32_ - * @param _uint32_ New value for member uint32_ - */ - eProsima_user_DllExport void uint32_( - uint32_t _uint32_); - - /*! - * @brief This function returns the value of member uint32_ - * @return Value of member uint32_ - */ - eProsima_user_DllExport uint32_t uint32_() const; - - /*! - * @brief This function returns a reference to member uint32_ - * @return Reference to member uint32_ - */ - eProsima_user_DllExport uint32_t& uint32_(); - - - /*! - * @brief This function sets a value in member int64_ - * @param _int64_ New value for member int64_ - */ - eProsima_user_DllExport void int64_( - int64_t _int64_); - - /*! - * @brief This function returns the value of member int64_ - * @return Value of member int64_ - */ - eProsima_user_DllExport int64_t int64_() const; - - /*! - * @brief This function returns a reference to member int64_ - * @return Reference to member int64_ - */ - eProsima_user_DllExport int64_t& int64_(); - - - /*! - * @brief This function sets a value in member uint64_ - * @param _uint64_ New value for member uint64_ - */ - eProsima_user_DllExport void uint64_( - uint64_t _uint64_); - - /*! - * @brief This function returns the value of member uint64_ - * @return Value of member uint64_ - */ - eProsima_user_DllExport uint64_t uint64_() const; - - /*! - * @brief This function returns a reference to member uint64_ - * @return Reference to member uint64_ - */ - eProsima_user_DllExport uint64_t& uint64_(); - - - /*! - * @brief This function copies the value in member local_string - * @param _local_string New value to be copied in member local_string - */ - eProsima_user_DllExport void local_string( - const std::string& _local_string); - - /*! - * @brief This function moves the value in member local_string - * @param _local_string New value to be moved in member local_string - */ - eProsima_user_DllExport void local_string( - std::string&& _local_string); - - /*! - * @brief This function returns a constant reference to member local_string - * @return Constant reference to member local_string - */ - eProsima_user_DllExport const std::string& local_string() const; - - /*! - * @brief This function returns a reference to member local_string - * @return Reference to member local_string - */ - eProsima_user_DllExport std::string& local_string(); - -private: - - int8_t m_int8_{0}; - uint8_t m_uint8_{0}; - int16_t m_int16_{0}; - uint16_t m_uint16_{0}; - int32_t m_int32_{0}; - uint32_t m_uint32_{0}; - int64_t m_int64_{0}; - uint64_t m_uint64_{555}; - std::string m_local_string; - -}; - - -/*! - * @brief This class represents the union WCharUnion defined by the user in the IDL file. - * @ingroup new_features_4_2 - */ -class WCharUnion -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport WCharUnion(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~WCharUnion(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object WCharUnion that will be copied. - */ - eProsima_user_DllExport WCharUnion( - const WCharUnion& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object WCharUnion that will be copied. - */ - eProsima_user_DllExport WCharUnion( - WCharUnion&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object WCharUnion that will be copied. - */ - eProsima_user_DllExport WCharUnion& operator =( - const WCharUnion& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object WCharUnion that will be copied. - */ - eProsima_user_DllExport WCharUnion& operator =( - WCharUnion&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x WCharUnion object to compare. - */ - eProsima_user_DllExport bool operator ==( - const WCharUnion& x) const; - - /*! - * @brief Comparison operator. - * @param x WCharUnion object to compare. - */ - eProsima_user_DllExport bool operator !=( - const WCharUnion& x) const; - - /*! - * @brief This function sets the discriminator value. - * @param __d New value for the discriminator. - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the new value doesn't correspond to the selected union member. - */ - eProsima_user_DllExport void _d( - wchar_t __d); - - /*! - * @brief This function returns the value of the discriminator. - * @return Value of the discriminator - */ - eProsima_user_DllExport wchar_t _d() const; - - /*! - * @brief This function returns a reference to the discriminator. - * @return Reference to the discriminator. - */ - eProsima_user_DllExport wchar_t& _d(); - - /*! - * @brief This function sets a value in member case_zero - * @param _case_zero New value for member case_zero - */ - eProsima_user_DllExport void case_zero( - int32_t _case_zero); - - /*! - * @brief This function returns the value of member case_zero - * @return Value of member case_zero - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t case_zero() const; - - /*! - * @brief This function returns a reference to member case_zero - * @return Reference to member case_zero - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t& case_zero(); - - - /*! - * @brief This function sets a value in member case_one - * @param _case_one New value for member case_one - */ - eProsima_user_DllExport void case_one( - int32_t _case_one); - - /*! - * @brief This function returns the value of member case_one - * @return Value of member case_one - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t case_one() const; - - /*! - * @brief This function returns a reference to member case_one - * @return Reference to member case_one - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t& case_one(); - -private: - - wchar_t m__d; - - int32_t m_case_zero{0}; - int32_t m_case_one{0}; -}; - - -/*! - * @brief This class represents the union OctetUnion defined by the user in the IDL file. - * @ingroup new_features_4_2 - */ -class OctetUnion -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport OctetUnion(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~OctetUnion(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object OctetUnion that will be copied. - */ - eProsima_user_DllExport OctetUnion( - const OctetUnion& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object OctetUnion that will be copied. - */ - eProsima_user_DllExport OctetUnion( - OctetUnion&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object OctetUnion that will be copied. - */ - eProsima_user_DllExport OctetUnion& operator =( - const OctetUnion& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object OctetUnion that will be copied. - */ - eProsima_user_DllExport OctetUnion& operator =( - OctetUnion&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x OctetUnion object to compare. - */ - eProsima_user_DllExport bool operator ==( - const OctetUnion& x) const; - - /*! - * @brief Comparison operator. - * @param x OctetUnion object to compare. - */ - eProsima_user_DllExport bool operator !=( - const OctetUnion& x) const; - - /*! - * @brief This function sets the discriminator value. - * @param __d New value for the discriminator. - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the new value doesn't correspond to the selected union member. - */ - eProsima_user_DllExport void _d( - uint8_t __d); - - /*! - * @brief This function returns the value of the discriminator. - * @return Value of the discriminator - */ - eProsima_user_DllExport uint8_t _d() const; - - /*! - * @brief This function returns a reference to the discriminator. - * @return Reference to the discriminator. - */ - eProsima_user_DllExport uint8_t& _d(); - - /*! - * @brief This function sets a value in member case_five - * @param _case_five New value for member case_five - */ - eProsima_user_DllExport void case_five( - int32_t _case_five); - - /*! - * @brief This function returns the value of member case_five - * @return Value of member case_five - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t case_five() const; - - /*! - * @brief This function returns a reference to member case_five - * @return Reference to member case_five - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t& case_five(); - - - /*! - * @brief This function sets a value in member case_seven - * @param _case_seven New value for member case_seven - */ - eProsima_user_DllExport void case_seven( - int32_t _case_seven); - - /*! - * @brief This function returns the value of member case_seven - * @return Value of member case_seven - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t case_seven() const; - - /*! - * @brief This function returns a reference to member case_seven - * @return Reference to member case_seven - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t& case_seven(); - -private: - - uint8_t m__d; - - int32_t m_case_five{0}; - int32_t m_case_seven{0}; -}; - - -/*! - * @brief This class represents the union Int8Union defined by the user in the IDL file. - * @ingroup new_features_4_2 - */ -class Int8Union -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport Int8Union(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~Int8Union(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object Int8Union that will be copied. - */ - eProsima_user_DllExport Int8Union( - const Int8Union& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object Int8Union that will be copied. - */ - eProsima_user_DllExport Int8Union( - Int8Union&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object Int8Union that will be copied. - */ - eProsima_user_DllExport Int8Union& operator =( - const Int8Union& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object Int8Union that will be copied. - */ - eProsima_user_DllExport Int8Union& operator =( - Int8Union&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x Int8Union object to compare. - */ - eProsima_user_DllExport bool operator ==( - const Int8Union& x) const; - - /*! - * @brief Comparison operator. - * @param x Int8Union object to compare. - */ - eProsima_user_DllExport bool operator !=( - const Int8Union& x) const; - - /*! - * @brief This function sets the discriminator value. - * @param __d New value for the discriminator. - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the new value doesn't correspond to the selected union member. - */ - eProsima_user_DllExport void _d( - int8_t __d); - - /*! - * @brief This function returns the value of the discriminator. - * @return Value of the discriminator - */ - eProsima_user_DllExport int8_t _d() const; - - /*! - * @brief This function returns a reference to the discriminator. - * @return Reference to the discriminator. - */ - eProsima_user_DllExport int8_t& _d(); - - /*! - * @brief This function sets a value in member case_three - * @param _case_three New value for member case_three - */ - eProsima_user_DllExport void case_three( - int32_t _case_three); - - /*! - * @brief This function returns the value of member case_three - * @return Value of member case_three - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t case_three() const; - - /*! - * @brief This function returns a reference to member case_three - * @return Reference to member case_three - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t& case_three(); - - - /*! - * @brief This function sets a value in member case_six - * @param _case_six New value for member case_six - */ - eProsima_user_DllExport void case_six( - int32_t _case_six); - - /*! - * @brief This function returns the value of member case_six - * @return Value of member case_six - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t case_six() const; - - /*! - * @brief This function returns a reference to member case_six - * @return Reference to member case_six - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t& case_six(); - -private: - - int8_t m__d; - - int32_t m_case_three{0}; - int32_t m_case_six{0}; -}; -namespace bitmodule { - -/*! - * @brief This class represents the structure ParentBitset defined by the user in the IDL file. - * @ingroup new_features_4_2 - */ -class ParentBitset -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport ParentBitset(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~ParentBitset(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object bitmodule::ParentBitset that will be copied. - */ - eProsima_user_DllExport ParentBitset( - const ParentBitset& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object bitmodule::ParentBitset that will be copied. - */ - eProsima_user_DllExport ParentBitset( - ParentBitset&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object bitmodule::ParentBitset that will be copied. - */ - eProsima_user_DllExport ParentBitset& operator =( - const ParentBitset& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object bitmodule::ParentBitset that will be copied. - */ - eProsima_user_DllExport ParentBitset& operator =( - ParentBitset&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x bitmodule::ParentBitset object to compare. - */ - eProsima_user_DllExport bool operator ==( - const ParentBitset& x) const; - - /*! - * @brief Comparison operator. - * @param x bitmodule::ParentBitset object to compare. - */ - eProsima_user_DllExport bool operator !=( - const ParentBitset& x) const; - - /*! - * @brief This function sets a value in member parent_bitfield - * @param _parent_bitfield New value for member parent_bitfield - */ - eProsima_user_DllExport void parent_bitfield( - uint32_t _parent_bitfield); - - /*! - * @brief This function returns the value of member parent_bitfield - * @return Value of member parent_bitfield - */ - eProsima_user_DllExport uint32_t parent_bitfield() const; - - - eProsima_user_DllExport std::bitset<17> bitset() const; - - eProsima_user_DllExport void bitset( - const std::bitset<17>&); - - - -private: - - std::bitset<17> m_bitset; -}; -/*! - * @brief This class represents the structure MyBitset defined by the user in the IDL file. - * @ingroup new_features_4_2 - */ -class MyBitset : public bitmodule::ParentBitset -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MyBitset(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MyBitset(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object bitmodule::MyBitset that will be copied. - */ - eProsima_user_DllExport MyBitset( - const MyBitset& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object bitmodule::MyBitset that will be copied. - */ - eProsima_user_DllExport MyBitset( - MyBitset&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object bitmodule::MyBitset that will be copied. - */ - eProsima_user_DllExport MyBitset& operator =( - const MyBitset& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object bitmodule::MyBitset that will be copied. - */ - eProsima_user_DllExport MyBitset& operator =( - MyBitset&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x bitmodule::MyBitset object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MyBitset& x) const; - - /*! - * @brief Comparison operator. - * @param x bitmodule::MyBitset object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MyBitset& x) const; - - /*! - * @brief This function sets a value in member a - * @param _a New value for member a - */ - eProsima_user_DllExport void a( - char _a); - - /*! - * @brief This function returns the value of member a - * @return Value of member a - */ - eProsima_user_DllExport char a() const; - - - /*! - * @brief This function sets a value in member b - * @param _b New value for member b - */ - eProsima_user_DllExport void b( - bool _b); - - /*! - * @brief This function returns the value of member b - * @return Value of member b - */ - eProsima_user_DllExport bool b() const; - - - - /*! - * @brief This function sets a value in member c - * @param _c New value for member c - */ - eProsima_user_DllExport void c( - uint16_t _c); - - /*! - * @brief This function returns the value of member c - * @return Value of member c - */ - eProsima_user_DllExport uint16_t c() const; - - - /*! - * @brief This function sets a value in member d - * @param _d New value for member d - */ - eProsima_user_DllExport void d( - int16_t _d); - - /*! - * @brief This function returns the value of member d - * @return Value of member d - */ - eProsima_user_DllExport int16_t d() const; - - - /*! - * @brief This function sets a value in member e - * @param _e New value for member e - */ - eProsima_user_DllExport void e( - int16_t _e); - - /*! - * @brief This function returns the value of member e - * @return Value of member e - */ - eProsima_user_DllExport int16_t e() const; - - - /*! - * @brief This function sets a value in member f - * @param _f New value for member f - */ - eProsima_user_DllExport void f( - int16_t _f); - - /*! - * @brief This function returns the value of member f - * @return Value of member f - */ - eProsima_user_DllExport int16_t f() const; - - - eProsima_user_DllExport std::bitset<50> bitset() const; - - eProsima_user_DllExport void bitset( - const std::bitset<50>&); - - - -private: - - std::bitset<33> m_bitset; -}; -/*! - * @brief This enumeration represents the MyBitMask bitflags defined by the user in the IDL file. - * @ingroup new_features_4_2 - */ -enum MyBitMaskBits : uint8_t -{ - flag0 = 0x01ull << 0, - flag1 = 0x01ull << 1, - flag4 = 0x01ull << 4, - flag6 = 0x01ull << 6, - flag7 = 0x01ull << 7 -}; -typedef uint8_t MyBitMask; - - -/*! - * @brief This class represents the structure BitsetBitmask defined by the user in the IDL file. - * @ingroup new_features_4_2 - */ -class BitsetBitmask -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport BitsetBitmask(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~BitsetBitmask(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object bitmodule::BitsetBitmask that will be copied. - */ - eProsima_user_DllExport BitsetBitmask( - const BitsetBitmask& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object bitmodule::BitsetBitmask that will be copied. - */ - eProsima_user_DllExport BitsetBitmask( - BitsetBitmask&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object bitmodule::BitsetBitmask that will be copied. - */ - eProsima_user_DllExport BitsetBitmask& operator =( - const BitsetBitmask& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object bitmodule::BitsetBitmask that will be copied. - */ - eProsima_user_DllExport BitsetBitmask& operator =( - BitsetBitmask&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x bitmodule::BitsetBitmask object to compare. - */ - eProsima_user_DllExport bool operator ==( - const BitsetBitmask& x) const; - - /*! - * @brief Comparison operator. - * @param x bitmodule::BitsetBitmask object to compare. - */ - eProsima_user_DllExport bool operator !=( - const BitsetBitmask& x) const; - - /*! - * @brief This function copies the value in member mybitset - * @param _mybitset New value to be copied in member mybitset - */ - eProsima_user_DllExport void mybitset( - const bitmodule::MyBitset& _mybitset); - - /*! - * @brief This function moves the value in member mybitset - * @param _mybitset New value to be moved in member mybitset - */ - eProsima_user_DllExport void mybitset( - bitmodule::MyBitset&& _mybitset); - - /*! - * @brief This function returns a constant reference to member mybitset - * @return Constant reference to member mybitset - */ - eProsima_user_DllExport const bitmodule::MyBitset& mybitset() const; - - /*! - * @brief This function returns a reference to member mybitset - * @return Reference to member mybitset - */ - eProsima_user_DllExport bitmodule::MyBitset& mybitset(); - - - /*! - * @brief This function copies the value in member mybitmask - * @param _mybitmask New value to be copied in member mybitmask - */ - eProsima_user_DllExport void mybitmask( - const bitmodule::MyBitMask& _mybitmask); - - /*! - * @brief This function moves the value in member mybitmask - * @param _mybitmask New value to be moved in member mybitmask - */ - eProsima_user_DllExport void mybitmask( - bitmodule::MyBitMask&& _mybitmask); - - /*! - * @brief This function returns a constant reference to member mybitmask - * @return Constant reference to member mybitmask - */ - eProsima_user_DllExport const bitmodule::MyBitMask& mybitmask() const; - - /*! - * @brief This function returns a reference to member mybitmask - * @return Reference to member mybitmask - */ - eProsima_user_DllExport bitmodule::MyBitMask& mybitmask(); - -private: - - bitmodule::MyBitset m_mybitset; - bitmodule::MyBitMask m_mybitmask{0}; - -}; - - -/*! - * @brief This class represents the structure BM2 defined by the user in the IDL file. - * @ingroup new_features_4_2 - */ -class BM2 : public bitmodule::BitsetBitmask -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport BM2(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~BM2(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object bitmodule::BM2 that will be copied. - */ - eProsima_user_DllExport BM2( - const BM2& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object bitmodule::BM2 that will be copied. - */ - eProsima_user_DllExport BM2( - BM2&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object bitmodule::BM2 that will be copied. - */ - eProsima_user_DllExport BM2& operator =( - const BM2& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object bitmodule::BM2 that will be copied. - */ - eProsima_user_DllExport BM2& operator =( - BM2&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x bitmodule::BM2 object to compare. - */ - eProsima_user_DllExport bool operator ==( - const BM2& x) const; - - /*! - * @brief Comparison operator. - * @param x bitmodule::BM2 object to compare. - */ - eProsima_user_DllExport bool operator !=( - const BM2& x) const; - - /*! - * @brief This function copies the value in member two - * @param _two New value to be copied in member two - */ - eProsima_user_DllExport void two( - const bitmodule::MyBitMask& _two); - - /*! - * @brief This function moves the value in member two - * @param _two New value to be moved in member two - */ - eProsima_user_DllExport void two( - bitmodule::MyBitMask&& _two); - - /*! - * @brief This function returns a constant reference to member two - * @return Constant reference to member two - */ - eProsima_user_DllExport const bitmodule::MyBitMask& two() const; - - /*! - * @brief This function returns a reference to member two - * @return Reference to member two - */ - eProsima_user_DllExport bitmodule::MyBitMask& two(); - - - /*! - * @brief This function sets a value in member mylong - * @param _mylong New value for member mylong - */ - eProsima_user_DllExport void mylong( - int32_t _mylong); - - /*! - * @brief This function returns the value of member mylong - * @return Value of member mylong - */ - eProsima_user_DllExport int32_t mylong() const; - - /*! - * @brief This function returns a reference to member mylong - * @return Reference to member mylong - */ - eProsima_user_DllExport int32_t& mylong(); - -private: - - bitmodule::MyBitMask m_two{0}; - int32_t m_mylong{0}; - -}; - -} // namespace bitmodule - - -/*! - * @brief This class represents the structure StructTest defined by the user in the IDL file. - * @ingroup new_features_4_2 - */ -class StructTest : public NewAliases -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport StructTest(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~StructTest(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object StructTest that will be copied. - */ - eProsima_user_DllExport StructTest( - const StructTest& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object StructTest that will be copied. - */ - eProsima_user_DllExport StructTest( - StructTest&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object StructTest that will be copied. - */ - eProsima_user_DllExport StructTest& operator =( - const StructTest& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object StructTest that will be copied. - */ - eProsima_user_DllExport StructTest& operator =( - StructTest&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x StructTest object to compare. - */ - eProsima_user_DllExport bool operator ==( - const StructTest& x) const; - - /*! - * @brief Comparison operator. - * @param x StructTest object to compare. - */ - eProsima_user_DllExport bool operator !=( - const StructTest& x) const; - - /*! - * @brief This function copies the value in member octetUnion - * @param _octetUnion New value to be copied in member octetUnion - */ - eProsima_user_DllExport void octetUnion( - const OctetUnion& _octetUnion); - - /*! - * @brief This function moves the value in member octetUnion - * @param _octetUnion New value to be moved in member octetUnion - */ - eProsima_user_DllExport void octetUnion( - OctetUnion&& _octetUnion); - - /*! - * @brief This function returns a constant reference to member octetUnion - * @return Constant reference to member octetUnion - */ - eProsima_user_DllExport const OctetUnion& octetUnion() const; - - /*! - * @brief This function returns a reference to member octetUnion - * @return Reference to member octetUnion - */ - eProsima_user_DllExport OctetUnion& octetUnion(); - - - /*! - * @brief This function copies the value in member int8Union - * @param _int8Union New value to be copied in member int8Union - */ - eProsima_user_DllExport void int8Union( - const Int8Union& _int8Union); - - /*! - * @brief This function moves the value in member int8Union - * @param _int8Union New value to be moved in member int8Union - */ - eProsima_user_DllExport void int8Union( - Int8Union&& _int8Union); - - /*! - * @brief This function returns a constant reference to member int8Union - * @return Constant reference to member int8Union - */ - eProsima_user_DllExport const Int8Union& int8Union() const; - - /*! - * @brief This function returns a reference to member int8Union - * @return Reference to member int8Union - */ - eProsima_user_DllExport Int8Union& int8Union(); - - - /*! - * @brief This function copies the value in member myStructBits - * @param _myStructBits New value to be copied in member myStructBits - */ - eProsima_user_DllExport void myStructBits( - const bitmodule::BM2& _myStructBits); - - /*! - * @brief This function moves the value in member myStructBits - * @param _myStructBits New value to be moved in member myStructBits - */ - eProsima_user_DllExport void myStructBits( - bitmodule::BM2&& _myStructBits); - - /*! - * @brief This function returns a constant reference to member myStructBits - * @return Constant reference to member myStructBits - */ - eProsima_user_DllExport const bitmodule::BM2& myStructBits() const; - - /*! - * @brief This function returns a reference to member myStructBits - * @return Reference to member myStructBits - */ - eProsima_user_DllExport bitmodule::BM2& myStructBits(); - -private: - - OctetUnion m_octetUnion; - Int8Union m_int8Union; - bitmodule::BM2 m_myStructBits; - -}; - -#endif // _FAST_DDS_GENERATED_NEW_FEATURES_4_2_H_ - - - -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/test/unittest/dynamic_types/idl/new_features_4_2.idl b/test/unittest/dynamic_types/idl/new_features_4_2.idl deleted file mode 100644 index 533096f4353..00000000000 --- a/test/unittest/dynamic_types/idl/new_features_4_2.idl +++ /dev/null @@ -1,85 +0,0 @@ -struct NewAliases -{ - int8 int8_; - uint8 uint8_; - int16 int16_; - uint16 uint16_; - int32 int32_; - uint32 uint32_; - int64 int64_; - @default(555) uint64 uint64_; - @non_serialized string local_string; -}; - -union WCharUnion switch (wchar) -{ - case 'a': - long case_zero; - case 'b': - long case_one; -}; - -union OctetUnion switch (octet) -{ - case 5: - long case_five; - case 7: - long case_seven; -}; - - -union Int8Union switch (int8) -{ - case 3: - long case_three; - case 6: - long case_six; -}; - -module bitmodule -{ - bitset ParentBitset - { - bitfield<17> parent_bitfield; - }; - - bitset MyBitset : ParentBitset - { - bitfield<3> a; - bitfield<1> b; - bitfield<4>; - bitfield<10> c; - bitfield<5, short> d, e, f; - }; - - @bit_bound(8) - bitmask MyBitMask - { - @position(0) flag0, - @position(1) flag1, - @position(4) flag4, - @position(6) flag6, - flag7 - }; - - - struct BitsetBitmask - { - MyBitset mybitset; - MyBitMask mybitmask; - }; - - struct BM2 : BitsetBitmask - { - MyBitMask two; - long mylong; - }; -}; - -struct StructTest : NewAliases -{ - //WCharUnion charUnion; //TODO(richiware) Remove when xtype 1.3. Uncomment also in DynamicTypes_4_2_Tests.cpp - OctetUnion octetUnion; - Int8Union int8Union; - bitmodule::BM2 myStructBits; -}; diff --git a/test/unittest/dynamic_types/idl/new_features_4_2CdrAux.hpp b/test/unittest/dynamic_types/idl/new_features_4_2CdrAux.hpp deleted file mode 100644 index 213ee811979..00000000000 --- a/test/unittest/dynamic_types/idl/new_features_4_2CdrAux.hpp +++ /dev/null @@ -1,92 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file new_features_4_2CdrAux.hpp - * This source file contains some definitions of CDR related functions. - * - * This file was generated by the tool fastddsgen. - */ - -#ifndef _FAST_DDS_GENERATED_NEW_FEATURES_4_2CDRAUX_HPP_ -#define _FAST_DDS_GENERATED_NEW_FEATURES_4_2CDRAUX_HPP_ - -#include "new_features_4_2.h" - -constexpr uint32_t bitmodule_BM2_max_cdr_typesize {24UL}; -constexpr uint32_t bitmodule_BM2_max_key_cdr_typesize {0UL}; - -constexpr uint32_t NewAliases_max_cdr_typesize {40UL}; -constexpr uint32_t NewAliases_max_key_cdr_typesize {0UL}; - - -constexpr uint32_t StructTest_max_cdr_typesize {88UL}; -constexpr uint32_t StructTest_max_key_cdr_typesize {0UL}; - - - - -constexpr uint32_t bitmodule_BitsetBitmask_max_cdr_typesize {17UL}; -constexpr uint32_t bitmodule_BitsetBitmask_max_key_cdr_typesize {0UL}; - - -namespace eprosima { -namespace fastcdr { - -class Cdr; -class CdrSizeCalculator; - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const NewAliases& data); - - - - - - - - - - - - - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const bitmodule::BitsetBitmask& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const bitmodule::BM2& data); - - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const StructTest& data); - - -} // namespace fastcdr -} // namespace eprosima - -#endif // _FAST_DDS_GENERATED_NEW_FEATURES_4_2CDRAUX_HPP_ - diff --git a/test/unittest/dynamic_types/idl/new_features_4_2CdrAux.ipp b/test/unittest/dynamic_types/idl/new_features_4_2CdrAux.ipp deleted file mode 100644 index 55ea9cc4dd5..00000000000 --- a/test/unittest/dynamic_types/idl/new_features_4_2CdrAux.ipp +++ /dev/null @@ -1,941 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file new_features_4_2CdrAux.ipp - * This source file contains some declarations of CDR related functions. - * - * This file was generated by the tool fastddsgen. - */ - -#ifndef _FAST_DDS_GENERATED_NEW_FEATURES_4_2CDRAUX_IPP_ -#define _FAST_DDS_GENERATED_NEW_FEATURES_4_2CDRAUX_IPP_ - -#include "new_features_4_2CdrAux.hpp" - -#include -#include - - -#include -using namespace eprosima::fastcdr::exception; - -namespace eprosima { -namespace fastcdr { - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const NewAliases& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.int8_(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(1), - data.uint8_(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(2), - data.int16_(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(3), - data.uint16_(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(4), - data.int32_(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(5), - data.uint32_(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(6), - data.int64_(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(7), - data.uint64_(), current_alignment); - - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const NewAliases& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.int8_() - << eprosima::fastcdr::MemberId(1) << data.uint8_() - << eprosima::fastcdr::MemberId(2) << data.int16_() - << eprosima::fastcdr::MemberId(3) << data.uint16_() - << eprosima::fastcdr::MemberId(4) << data.int32_() - << eprosima::fastcdr::MemberId(5) << data.uint32_() - << eprosima::fastcdr::MemberId(6) << data.int64_() - << eprosima::fastcdr::MemberId(7) << data.uint64_() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - NewAliases& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.int8_(); - break; - - case 1: - dcdr >> data.uint8_(); - break; - - case 2: - dcdr >> data.int16_(); - break; - - case 3: - dcdr >> data.uint16_(); - break; - - case 4: - dcdr >> data.int32_(); - break; - - case 5: - dcdr >> data.uint32_(); - break; - - case 6: - dcdr >> data.int64_(); - break; - - case 7: - dcdr >> data.uint64_(); - break; - - case 8: - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const NewAliases& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const WCharUnion& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), data._d(), - current_alignment); - - switch (data._d()) - { - case 'a': - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(1), - data.case_zero(), current_alignment); - break; - - case 'b': - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(2), - data.case_one(), current_alignment); - break; - - default: - break; - } - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const WCharUnion& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr << eprosima::fastcdr::MemberId(0) << data._d(); - - switch (data._d()) - { - case 'a': - scdr << eprosima::fastcdr::MemberId(1) << data.case_zero(); - break; - - case 'b': - scdr << eprosima::fastcdr::MemberId(2) << data.case_one(); - break; - - default: - break; - } - - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - WCharUnion& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data._d(); - break; - default: - switch (data._d()) - { - case 'a': - dcdr >> data.case_zero(); - break; - - case 'b': - dcdr >> data.case_one(); - break; - - default: - break; - } - ret_value = false; - break; - } - return ret_value; - }); -} - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const OctetUnion& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), data._d(), - current_alignment); - - switch (data._d()) - { - case 5: - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(1), - data.case_five(), current_alignment); - break; - - case 7: - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(2), - data.case_seven(), current_alignment); - break; - - default: - break; - } - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const OctetUnion& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr << eprosima::fastcdr::MemberId(0) << data._d(); - - switch (data._d()) - { - case 5: - scdr << eprosima::fastcdr::MemberId(1) << data.case_five(); - break; - - case 7: - scdr << eprosima::fastcdr::MemberId(2) << data.case_seven(); - break; - - default: - break; - } - - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - OctetUnion& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data._d(); - break; - default: - switch (data._d()) - { - case 5: - dcdr >> data.case_five(); - break; - - case 7: - dcdr >> data.case_seven(); - break; - - default: - break; - } - ret_value = false; - break; - } - return ret_value; - }); -} - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const Int8Union& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), data._d(), - current_alignment); - - switch (data._d()) - { - case 3: - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(1), - data.case_three(), current_alignment); - break; - - case 6: - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(2), - data.case_six(), current_alignment); - break; - - default: - break; - } - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const Int8Union& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr << eprosima::fastcdr::MemberId(0) << data._d(); - - switch (data._d()) - { - case 3: - scdr << eprosima::fastcdr::MemberId(1) << data.case_three(); - break; - - case 6: - scdr << eprosima::fastcdr::MemberId(2) << data.case_six(); - break; - - default: - break; - } - - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - Int8Union& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data._d(); - break; - default: - switch (data._d()) - { - case 3: - dcdr >> data.case_three(); - break; - - case 6: - dcdr >> data.case_six(); - break; - - default: - break; - } - ret_value = false; - break; - } - return ret_value; - }); -} - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const bitmodule::ParentBitset& data, - size_t& current_alignment) -{ - using namespace bitmodule; - - return calculator.calculate_serialized_size(data.bitset(), current_alignment); -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const bitmodule::ParentBitset& data) -{ - using namespace bitmodule; - - scdr << data.bitset(); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& dcdr, - bitmodule::ParentBitset& data) -{ - using namespace bitmodule; - - std::bitset<17> bitset; - dcdr >> bitset; - data.bitset(bitset); -} - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const bitmodule::MyBitset& data, - size_t& current_alignment) -{ - using namespace bitmodule; - - return calculator.calculate_serialized_size(data.bitset(), current_alignment); -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const bitmodule::MyBitset& data) -{ - using namespace bitmodule; - - scdr << data.bitset(); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& dcdr, - bitmodule::MyBitset& data) -{ - using namespace bitmodule; - - std::bitset<50> bitset; - dcdr >> bitset; - data.bitset(bitset); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const bitmodule::BitsetBitmask& data, - size_t& current_alignment) -{ - using namespace bitmodule; - - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.mybitset(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(1), - data.mybitmask(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const bitmodule::BitsetBitmask& data) -{ - using namespace bitmodule; - - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.mybitset() - << eprosima::fastcdr::MemberId(1) << data.mybitmask() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - bitmodule::BitsetBitmask& data) -{ - using namespace bitmodule; - - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.mybitset(); - break; - - case 1: - dcdr >> data.mybitmask(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const bitmodule::BitsetBitmask& data) -{ - using namespace bitmodule; - - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const bitmodule::BM2& data, - size_t& current_alignment) -{ - using namespace bitmodule; - - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.mybitset(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(1), - data.mybitmask(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(2), - data.two(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(3), - data.mylong(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const bitmodule::BM2& data) -{ - using namespace bitmodule; - - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.mybitset() - << eprosima::fastcdr::MemberId(1) << data.mybitmask() - << eprosima::fastcdr::MemberId(2) << data.two() - << eprosima::fastcdr::MemberId(3) << data.mylong() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - bitmodule::BM2& data) -{ - using namespace bitmodule; - - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.mybitset(); - break; - - case 1: - dcdr >> data.mybitmask(); - break; - - case 2: - dcdr >> data.two(); - break; - - case 3: - dcdr >> data.mylong(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const bitmodule::BM2& data) -{ - using namespace bitmodule; - - static_cast(scdr); - static_cast(data); -} - - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const StructTest& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.int8_(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(1), - data.uint8_(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(2), - data.int16_(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(3), - data.uint16_(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(4), - data.int32_(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(5), - data.uint32_(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(6), - data.int64_(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(7), - data.uint64_(), current_alignment); - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(9), - data.octetUnion(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(10), - data.int8Union(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(11), - data.myStructBits(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const StructTest& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.int8_() - << eprosima::fastcdr::MemberId(1) << data.uint8_() - << eprosima::fastcdr::MemberId(2) << data.int16_() - << eprosima::fastcdr::MemberId(3) << data.uint16_() - << eprosima::fastcdr::MemberId(4) << data.int32_() - << eprosima::fastcdr::MemberId(5) << data.uint32_() - << eprosima::fastcdr::MemberId(6) << data.int64_() - << eprosima::fastcdr::MemberId(7) << data.uint64_() - << eprosima::fastcdr::MemberId(9) << data.octetUnion() - << eprosima::fastcdr::MemberId(10) << data.int8Union() - << eprosima::fastcdr::MemberId(11) << data.myStructBits() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - StructTest& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.int8_(); - break; - - case 1: - dcdr >> data.uint8_(); - break; - - case 2: - dcdr >> data.int16_(); - break; - - case 3: - dcdr >> data.uint16_(); - break; - - case 4: - dcdr >> data.int32_(); - break; - - case 5: - dcdr >> data.uint32_(); - break; - - case 6: - dcdr >> data.int64_(); - break; - - case 7: - dcdr >> data.uint64_(); - break; - - case 8: - break; - - case 9: - dcdr >> data.octetUnion(); - break; - - case 10: - dcdr >> data.int8Union(); - break; - - case 11: - dcdr >> data.myStructBits(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const StructTest& data) -{ - static_cast(scdr); - static_cast(data); -} - - - -} // namespace fastcdr -} // namespace eprosima - -#endif // _FAST_DDS_GENERATED_NEW_FEATURES_4_2CDRAUX_IPP_ - diff --git a/test/unittest/dynamic_types/idl/new_features_4_2TypeObject.cxx b/test/unittest/dynamic_types/idl/new_features_4_2TypeObject.cxx deleted file mode 100644 index 32f204ac131..00000000000 --- a/test/unittest/dynamic_types/idl/new_features_4_2TypeObject.cxx +++ /dev/null @@ -1,3276 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file new_features_4_2TypeObject.cpp - * This source file contains the definition of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { char dummy; } -#endif - -#include "new_features_4_2.h" -#include "new_features_4_2TypeObject.h" -#include -#include -#include -#include -#include -#include -#include -#include -#include - -using namespace eprosima::fastrtps::rtps; - -void registernew_features_4_2Types() -{ - static std::once_flag once_flag; - std::call_once(once_flag, []() - { - TypeObjectFactory *factory = TypeObjectFactory::get_instance(); - factory->add_type_object("NewAliases", GetNewAliasesIdentifier(true), - GetNewAliasesObject(true)); - factory->add_type_object("NewAliases", GetNewAliasesIdentifier(false), - GetNewAliasesObject(false)); - - - factory->add_type_object("WCharUnion", GetWCharUnionIdentifier(true), - GetWCharUnionObject(true)); - factory->add_type_object("WCharUnion", GetWCharUnionIdentifier(false), - GetWCharUnionObject(false)); - - - factory->add_type_object("OctetUnion", GetOctetUnionIdentifier(true), - GetOctetUnionObject(true)); - factory->add_type_object("OctetUnion", GetOctetUnionIdentifier(false), - GetOctetUnionObject(false)); - - - factory->add_type_object("Int8Union", GetInt8UnionIdentifier(true), - GetInt8UnionObject(true)); - factory->add_type_object("Int8Union", GetInt8UnionIdentifier(false), - GetInt8UnionObject(false)); - - - factory->add_type_object("bitmodule::ParentBitset", bitmodule::GetParentBitsetIdentifier(true), - bitmodule::GetParentBitsetObject(true)); - factory->add_type_object("bitmodule::ParentBitset", bitmodule::GetParentBitsetIdentifier(false), - bitmodule::GetParentBitsetObject(false)); - - - factory->add_type_object("bitmodule::MyBitset", bitmodule::GetMyBitsetIdentifier(true), - bitmodule::GetMyBitsetObject(true)); - factory->add_type_object("bitmodule::MyBitset", bitmodule::GetMyBitsetIdentifier(false), - bitmodule::GetMyBitsetObject(false)); - - - factory->add_type_object("bitmodule::MyBitMask", bitmodule::GetMyBitMaskIdentifier(true), - bitmodule::GetMyBitMaskObject(true)); - factory->add_type_object("bitmodule::MyBitMask", bitmodule::GetMyBitMaskIdentifier(false), - bitmodule::GetMyBitMaskObject(false)); - - - factory->add_type_object("bitmodule::BitsetBitmask", bitmodule::GetBitsetBitmaskIdentifier(true), - bitmodule::GetBitsetBitmaskObject(true)); - factory->add_type_object("bitmodule::BitsetBitmask", bitmodule::GetBitsetBitmaskIdentifier(false), - bitmodule::GetBitsetBitmaskObject(false)); - - - factory->add_type_object("bitmodule::BM2", bitmodule::GetBM2Identifier(true), - bitmodule::GetBM2Object(true)); - factory->add_type_object("bitmodule::BM2", bitmodule::GetBM2Identifier(false), - bitmodule::GetBM2Object(false)); - - - - factory->add_type_object("StructTest", GetStructTestIdentifier(true), - GetStructTestObject(true)); - factory->add_type_object("StructTest", GetStructTestIdentifier(false), - GetStructTestObject(false)); - - }); -} - - - -const TypeIdentifier* GetNewAliasesIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("NewAliases", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetNewAliasesObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("NewAliases", complete); -} - -const TypeObject* GetNewAliasesObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("NewAliases", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteNewAliasesObject(); - } - //else - return GetMinimalNewAliasesObject(); -} - -const TypeObject* GetMinimalNewAliasesObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("NewAliases", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_int8_; - mst_int8_.common().member_id(memberId++); - mst_int8_.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_int8_.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_int8_.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_int8_.common().member_flags().IS_OPTIONAL(false); - mst_int8_.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_int8_.common().member_flags().IS_KEY(false); - mst_int8_.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_int8_.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int8_t", false)); - - - MD5 int8__hash("int8_"); - for(int i = 0; i < 4; ++i) - { - mst_int8_.detail().name_hash()[i] = int8__hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_int8_); - - MinimalStructMember mst_uint8_; - mst_uint8_.common().member_id(memberId++); - mst_uint8_.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_uint8_.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_uint8_.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_uint8_.common().member_flags().IS_OPTIONAL(false); - mst_uint8_.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_uint8_.common().member_flags().IS_KEY(false); - mst_uint8_.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_uint8_.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint8_t", false)); - - - MD5 uint8__hash("uint8_"); - for(int i = 0; i < 4; ++i) - { - mst_uint8_.detail().name_hash()[i] = uint8__hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_uint8_); - - MinimalStructMember mst_int16_; - mst_int16_.common().member_id(memberId++); - mst_int16_.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_int16_.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_int16_.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_int16_.common().member_flags().IS_OPTIONAL(false); - mst_int16_.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_int16_.common().member_flags().IS_KEY(false); - mst_int16_.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_int16_.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int16_t", false)); - - - MD5 int16__hash("int16_"); - for(int i = 0; i < 4; ++i) - { - mst_int16_.detail().name_hash()[i] = int16__hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_int16_); - - MinimalStructMember mst_uint16_; - mst_uint16_.common().member_id(memberId++); - mst_uint16_.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_uint16_.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_uint16_.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_uint16_.common().member_flags().IS_OPTIONAL(false); - mst_uint16_.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_uint16_.common().member_flags().IS_KEY(false); - mst_uint16_.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_uint16_.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint16_t", false)); - - - MD5 uint16__hash("uint16_"); - for(int i = 0; i < 4; ++i) - { - mst_uint16_.detail().name_hash()[i] = uint16__hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_uint16_); - - MinimalStructMember mst_int32_; - mst_int32_.common().member_id(memberId++); - mst_int32_.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_int32_.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_int32_.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_int32_.common().member_flags().IS_OPTIONAL(false); - mst_int32_.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_int32_.common().member_flags().IS_KEY(false); - mst_int32_.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_int32_.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - MD5 int32__hash("int32_"); - for(int i = 0; i < 4; ++i) - { - mst_int32_.detail().name_hash()[i] = int32__hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_int32_); - - MinimalStructMember mst_uint32_; - mst_uint32_.common().member_id(memberId++); - mst_uint32_.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_uint32_.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_uint32_.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_uint32_.common().member_flags().IS_OPTIONAL(false); - mst_uint32_.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_uint32_.common().member_flags().IS_KEY(false); - mst_uint32_.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_uint32_.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint32_t", false)); - - - MD5 uint32__hash("uint32_"); - for(int i = 0; i < 4; ++i) - { - mst_uint32_.detail().name_hash()[i] = uint32__hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_uint32_); - - MinimalStructMember mst_int64_; - mst_int64_.common().member_id(memberId++); - mst_int64_.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_int64_.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_int64_.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_int64_.common().member_flags().IS_OPTIONAL(false); - mst_int64_.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_int64_.common().member_flags().IS_KEY(false); - mst_int64_.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_int64_.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int64_t", false)); - - - MD5 int64__hash("int64_"); - for(int i = 0; i < 4; ++i) - { - mst_int64_.detail().name_hash()[i] = int64__hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_int64_); - - MinimalStructMember mst_uint64_; - mst_uint64_.common().member_id(memberId++); - mst_uint64_.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_uint64_.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_uint64_.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_uint64_.common().member_flags().IS_OPTIONAL(false); - mst_uint64_.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_uint64_.common().member_flags().IS_KEY(false); - mst_uint64_.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_uint64_.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint64_t", false)); - - - MD5 uint64__hash("uint64_"); - for(int i = 0; i < 4; ++i) - { - mst_uint64_.detail().name_hash()[i] = uint64__hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_uint64_); - - MinimalStructMember mst_local_string; - mst_local_string.common().member_id(memberId++); - mst_local_string.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_local_string.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_local_string.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_local_string.common().member_flags().IS_OPTIONAL(false); - mst_local_string.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_local_string.common().member_flags().IS_KEY(false); - mst_local_string.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_local_string.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, false)); - - MD5 local_string_hash("local_string"); - for(int i = 0; i < 4; ++i) - { - mst_local_string.detail().name_hash()[i] = local_string_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_local_string); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("NewAliases", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("NewAliases", false); -} - -const TypeObject* GetCompleteNewAliasesObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("NewAliases", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_int8_; - cst_int8_.common().member_id(memberId++); - cst_int8_.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_int8_.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_int8_.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_int8_.common().member_flags().IS_OPTIONAL(false); - cst_int8_.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_int8_.common().member_flags().IS_KEY(false); - cst_int8_.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_int8_.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int8_t", false)); - - - cst_int8_.detail().name("int8_"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_int8_); - - CompleteStructMember cst_uint8_; - cst_uint8_.common().member_id(memberId++); - cst_uint8_.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_uint8_.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_uint8_.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_uint8_.common().member_flags().IS_OPTIONAL(false); - cst_uint8_.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_uint8_.common().member_flags().IS_KEY(false); - cst_uint8_.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_uint8_.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint8_t", false)); - - - cst_uint8_.detail().name("uint8_"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_uint8_); - - CompleteStructMember cst_int16_; - cst_int16_.common().member_id(memberId++); - cst_int16_.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_int16_.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_int16_.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_int16_.common().member_flags().IS_OPTIONAL(false); - cst_int16_.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_int16_.common().member_flags().IS_KEY(false); - cst_int16_.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_int16_.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int16_t", false)); - - - cst_int16_.detail().name("int16_"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_int16_); - - CompleteStructMember cst_uint16_; - cst_uint16_.common().member_id(memberId++); - cst_uint16_.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_uint16_.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_uint16_.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_uint16_.common().member_flags().IS_OPTIONAL(false); - cst_uint16_.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_uint16_.common().member_flags().IS_KEY(false); - cst_uint16_.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_uint16_.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint16_t", false)); - - - cst_uint16_.detail().name("uint16_"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_uint16_); - - CompleteStructMember cst_int32_; - cst_int32_.common().member_id(memberId++); - cst_int32_.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_int32_.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_int32_.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_int32_.common().member_flags().IS_OPTIONAL(false); - cst_int32_.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_int32_.common().member_flags().IS_KEY(false); - cst_int32_.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_int32_.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - cst_int32_.detail().name("int32_"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_int32_); - - CompleteStructMember cst_uint32_; - cst_uint32_.common().member_id(memberId++); - cst_uint32_.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_uint32_.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_uint32_.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_uint32_.common().member_flags().IS_OPTIONAL(false); - cst_uint32_.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_uint32_.common().member_flags().IS_KEY(false); - cst_uint32_.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_uint32_.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint32_t", false)); - - - cst_uint32_.detail().name("uint32_"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_uint32_); - - CompleteStructMember cst_int64_; - cst_int64_.common().member_id(memberId++); - cst_int64_.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_int64_.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_int64_.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_int64_.common().member_flags().IS_OPTIONAL(false); - cst_int64_.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_int64_.common().member_flags().IS_KEY(false); - cst_int64_.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_int64_.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int64_t", false)); - - - cst_int64_.detail().name("int64_"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_int64_); - - CompleteStructMember cst_uint64_; - cst_uint64_.common().member_id(memberId++); - cst_uint64_.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_uint64_.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_uint64_.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_uint64_.common().member_flags().IS_OPTIONAL(false); - cst_uint64_.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_uint64_.common().member_flags().IS_KEY(false); - cst_uint64_.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_uint64_.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint64_t", false)); - - - cst_uint64_.detail().name("uint64_"); - - { - AppliedAnnotation ann; - //ann.annotation_typeid(GetdefaultIdentifier(true)); - ann.annotation_typeid(*TypeObjectFactory::get_instance()->get_type_identifier_trying_complete("default")); - { - AppliedAnnotationParameter annParam; - MD5 message_hash("value"); - for(int i = 0; i < 4; ++i) - { - annParam.paramname_hash()[i] = message_hash.digest[i]; - } - AnnotationParameterValue paramValue; - paramValue._d(); - paramValue.from_string("555"); - annParam.value(paramValue); - ann.param_seq().push_back(annParam); - } - - cst_uint64_.detail().ann_custom().push_back(ann); - } - - - type_object->complete().struct_type().member_seq().emplace_back(cst_uint64_); - - CompleteStructMember cst_local_string; - cst_local_string.common().member_id(memberId++); - cst_local_string.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_local_string.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_local_string.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_local_string.common().member_flags().IS_OPTIONAL(false); - cst_local_string.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_local_string.common().member_flags().IS_KEY(false); - cst_local_string.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_local_string.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, false)); - - cst_local_string.detail().name("local_string"); - - { - AppliedAnnotation ann; - //ann.annotation_typeid(Getnon_serializedIdentifier(true)); - ann.annotation_typeid(*TypeObjectFactory::get_instance()->get_type_identifier_trying_complete("non_serialized")); - { - AppliedAnnotationParameter annParam; - MD5 message_hash("value"); - for(int i = 0; i < 4; ++i) - { - annParam.paramname_hash()[i] = message_hash.digest[i]; - } - AnnotationParameterValue paramValue; - paramValue._d(TK_BOOLEAN); - paramValue.from_string("true"); - annParam.value(paramValue); - ann.param_seq().push_back(annParam); - } - - cst_local_string.detail().ann_custom().push_back(ann); - } - - - type_object->complete().struct_type().member_seq().emplace_back(cst_local_string); - - - // Header - type_object->complete().struct_type().header().detail().type_name("NewAliases"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("NewAliases", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("NewAliases", true); -} - - - -const TypeIdentifier* GetWCharUnionIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("WCharUnion", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetWCharUnionObject(complete); - return TypeObjectFactory::get_instance()->get_type_identifier("WCharUnion", complete); -} - -const TypeObject* GetWCharUnionObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("WCharUnion", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteWCharUnionObject(); - } - // else - return GetMinimalWCharUnionObject(); -} - -const TypeObject* GetMinimalWCharUnionObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("WCharUnion", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_UNION); - - type_object->minimal().union_type().union_flags().IS_FINAL(false); - type_object->minimal().union_type().union_flags().IS_APPENDABLE(false); - type_object->minimal().union_type().union_flags().IS_MUTABLE(false); - type_object->minimal().union_type().union_flags().IS_NESTED(false); - type_object->minimal().union_type().union_flags().IS_AUTOID_HASH(false); // Unsupported - - type_object->minimal().union_type().discriminator().common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().IS_EXTERNAL(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_OPTIONAL(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_KEY(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().IS_DEFAULT(false); // Doesn't apply - - type_object->minimal().union_type().discriminator().common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("wchar_t", false)); - - MemberId memberId = 0; - MinimalUnionMember mst_case_zero; - mst_case_zero.common().member_id(memberId++); - mst_case_zero.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_case_zero.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_case_zero.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_case_zero.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - mst_case_zero.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mst_case_zero.common().member_flags().IS_KEY(false); // Doesn't apply - mst_case_zero.common().member_flags().IS_DEFAULT(false); - mst_case_zero.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - mst_case_zero.common().label_seq().emplace_back('a'); - - MD5 case_zero_hash("case_zero"); - for(int i = 0; i < 4; ++i) - { - mst_case_zero.detail().name_hash()[i] = case_zero_hash.digest[i]; - } - type_object->minimal().union_type().member_seq().emplace_back(mst_case_zero); - - MinimalUnionMember mst_case_one; - mst_case_one.common().member_id(memberId++); - mst_case_one.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_case_one.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_case_one.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_case_one.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - mst_case_one.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mst_case_one.common().member_flags().IS_KEY(false); // Doesn't apply - mst_case_one.common().member_flags().IS_DEFAULT(false); - mst_case_one.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - mst_case_one.common().label_seq().emplace_back('b'); - - MD5 case_one_hash("case_one"); - for(int i = 0; i < 4; ++i) - { - mst_case_one.detail().name_hash()[i] = case_one_hash.digest[i]; - } - type_object->minimal().union_type().member_seq().emplace_back(mst_case_one); - - - // Header - //type_object->minimal().union_type().header().detail()... // Empty - - TypeIdentifier* identifier = new TypeIdentifier(); - identifier->_d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().union_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier->equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("WCharUnion", identifier, type_object); - delete type_object; - delete identifier; - return TypeObjectFactory::get_instance()->get_type_object("WCharUnion", false); -} - -const TypeObject* GetCompleteWCharUnionObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("WCharUnion", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_UNION); - - type_object->complete().union_type().union_flags().IS_FINAL(false); - type_object->complete().union_type().union_flags().IS_APPENDABLE(false); - type_object->complete().union_type().union_flags().IS_MUTABLE(false); - type_object->complete().union_type().union_flags().IS_NESTED(false); - type_object->complete().union_type().union_flags().IS_AUTOID_HASH(false); // Unsupported - - type_object->complete().union_type().discriminator().common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().IS_EXTERNAL(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_OPTIONAL(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_KEY(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().IS_DEFAULT(false); // Doesn't apply - - type_object->complete().union_type().discriminator().common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("wchar_t", false)); - - MemberId memberId = 0; - CompleteUnionMember cst_case_zero; - cst_case_zero.common().member_id(memberId++); - cst_case_zero.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_case_zero.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_case_zero.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_case_zero.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - cst_case_zero.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cst_case_zero.common().member_flags().IS_KEY(false); // Doesn't apply - cst_case_zero.common().member_flags().IS_DEFAULT(false); - cst_case_zero.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - cst_case_zero.common().label_seq().emplace_back('a'); - - - cst_case_zero.detail().name("case_zero"); - - type_object->complete().union_type().member_seq().emplace_back(cst_case_zero); - - CompleteUnionMember cst_case_one; - cst_case_one.common().member_id(memberId++); - cst_case_one.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_case_one.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_case_one.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_case_one.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - cst_case_one.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cst_case_one.common().member_flags().IS_KEY(false); // Doesn't apply - cst_case_one.common().member_flags().IS_DEFAULT(false); - cst_case_one.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - cst_case_one.common().label_seq().emplace_back('b'); - - - cst_case_one.detail().name("case_one"); - - type_object->complete().union_type().member_seq().emplace_back(cst_case_one); - - - // Header - type_object->complete().union_type().header().detail().type_name("WCharUnion"); - - TypeIdentifier* identifier = new TypeIdentifier(); - identifier->_d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().union_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier->equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("WCharUnion", identifier, type_object); - delete type_object; - delete identifier; - return TypeObjectFactory::get_instance()->get_type_object("WCharUnion", true); -} - - - -const TypeIdentifier* GetOctetUnionIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("OctetUnion", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetOctetUnionObject(complete); - return TypeObjectFactory::get_instance()->get_type_identifier("OctetUnion", complete); -} - -const TypeObject* GetOctetUnionObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("OctetUnion", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteOctetUnionObject(); - } - // else - return GetMinimalOctetUnionObject(); -} - -const TypeObject* GetMinimalOctetUnionObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("OctetUnion", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_UNION); - - type_object->minimal().union_type().union_flags().IS_FINAL(false); - type_object->minimal().union_type().union_flags().IS_APPENDABLE(false); - type_object->minimal().union_type().union_flags().IS_MUTABLE(false); - type_object->minimal().union_type().union_flags().IS_NESTED(false); - type_object->minimal().union_type().union_flags().IS_AUTOID_HASH(false); // Unsupported - - type_object->minimal().union_type().discriminator().common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().IS_EXTERNAL(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_OPTIONAL(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_KEY(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().IS_DEFAULT(false); // Doesn't apply - - type_object->minimal().union_type().discriminator().common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint8_t", false)); - - MemberId memberId = 0; - MinimalUnionMember mst_case_five; - mst_case_five.common().member_id(memberId++); - mst_case_five.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_case_five.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_case_five.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_case_five.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - mst_case_five.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mst_case_five.common().member_flags().IS_KEY(false); // Doesn't apply - mst_case_five.common().member_flags().IS_DEFAULT(false); - mst_case_five.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - mst_case_five.common().label_seq().emplace_back(5); - - MD5 case_five_hash("case_five"); - for(int i = 0; i < 4; ++i) - { - mst_case_five.detail().name_hash()[i] = case_five_hash.digest[i]; - } - type_object->minimal().union_type().member_seq().emplace_back(mst_case_five); - - MinimalUnionMember mst_case_seven; - mst_case_seven.common().member_id(memberId++); - mst_case_seven.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_case_seven.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_case_seven.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_case_seven.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - mst_case_seven.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mst_case_seven.common().member_flags().IS_KEY(false); // Doesn't apply - mst_case_seven.common().member_flags().IS_DEFAULT(false); - mst_case_seven.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - mst_case_seven.common().label_seq().emplace_back(7); - - MD5 case_seven_hash("case_seven"); - for(int i = 0; i < 4; ++i) - { - mst_case_seven.detail().name_hash()[i] = case_seven_hash.digest[i]; - } - type_object->minimal().union_type().member_seq().emplace_back(mst_case_seven); - - - // Header - //type_object->minimal().union_type().header().detail()... // Empty - - TypeIdentifier* identifier = new TypeIdentifier(); - identifier->_d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().union_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier->equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("OctetUnion", identifier, type_object); - delete type_object; - delete identifier; - return TypeObjectFactory::get_instance()->get_type_object("OctetUnion", false); -} - -const TypeObject* GetCompleteOctetUnionObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("OctetUnion", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_UNION); - - type_object->complete().union_type().union_flags().IS_FINAL(false); - type_object->complete().union_type().union_flags().IS_APPENDABLE(false); - type_object->complete().union_type().union_flags().IS_MUTABLE(false); - type_object->complete().union_type().union_flags().IS_NESTED(false); - type_object->complete().union_type().union_flags().IS_AUTOID_HASH(false); // Unsupported - - type_object->complete().union_type().discriminator().common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().IS_EXTERNAL(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_OPTIONAL(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_KEY(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().IS_DEFAULT(false); // Doesn't apply - - type_object->complete().union_type().discriminator().common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint8_t", false)); - - MemberId memberId = 0; - CompleteUnionMember cst_case_five; - cst_case_five.common().member_id(memberId++); - cst_case_five.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_case_five.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_case_five.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_case_five.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - cst_case_five.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cst_case_five.common().member_flags().IS_KEY(false); // Doesn't apply - cst_case_five.common().member_flags().IS_DEFAULT(false); - cst_case_five.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - cst_case_five.common().label_seq().emplace_back(5); - - - cst_case_five.detail().name("case_five"); - - type_object->complete().union_type().member_seq().emplace_back(cst_case_five); - - CompleteUnionMember cst_case_seven; - cst_case_seven.common().member_id(memberId++); - cst_case_seven.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_case_seven.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_case_seven.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_case_seven.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - cst_case_seven.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cst_case_seven.common().member_flags().IS_KEY(false); // Doesn't apply - cst_case_seven.common().member_flags().IS_DEFAULT(false); - cst_case_seven.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - cst_case_seven.common().label_seq().emplace_back(7); - - - cst_case_seven.detail().name("case_seven"); - - type_object->complete().union_type().member_seq().emplace_back(cst_case_seven); - - - // Header - type_object->complete().union_type().header().detail().type_name("OctetUnion"); - - TypeIdentifier* identifier = new TypeIdentifier(); - identifier->_d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().union_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier->equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("OctetUnion", identifier, type_object); - delete type_object; - delete identifier; - return TypeObjectFactory::get_instance()->get_type_object("OctetUnion", true); -} - - - -const TypeIdentifier* GetInt8UnionIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("Int8Union", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetInt8UnionObject(complete); - return TypeObjectFactory::get_instance()->get_type_identifier("Int8Union", complete); -} - -const TypeObject* GetInt8UnionObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("Int8Union", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteInt8UnionObject(); - } - // else - return GetMinimalInt8UnionObject(); -} - -const TypeObject* GetMinimalInt8UnionObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("Int8Union", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_UNION); - - type_object->minimal().union_type().union_flags().IS_FINAL(false); - type_object->minimal().union_type().union_flags().IS_APPENDABLE(false); - type_object->minimal().union_type().union_flags().IS_MUTABLE(false); - type_object->minimal().union_type().union_flags().IS_NESTED(false); - type_object->minimal().union_type().union_flags().IS_AUTOID_HASH(false); // Unsupported - - type_object->minimal().union_type().discriminator().common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().IS_EXTERNAL(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_OPTIONAL(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_KEY(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().IS_DEFAULT(false); // Doesn't apply - - type_object->minimal().union_type().discriminator().common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int8_t", false)); - - MemberId memberId = 0; - MinimalUnionMember mst_case_three; - mst_case_three.common().member_id(memberId++); - mst_case_three.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_case_three.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_case_three.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_case_three.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - mst_case_three.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mst_case_three.common().member_flags().IS_KEY(false); // Doesn't apply - mst_case_three.common().member_flags().IS_DEFAULT(false); - mst_case_three.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - mst_case_three.common().label_seq().emplace_back(3); - - MD5 case_three_hash("case_three"); - for(int i = 0; i < 4; ++i) - { - mst_case_three.detail().name_hash()[i] = case_three_hash.digest[i]; - } - type_object->minimal().union_type().member_seq().emplace_back(mst_case_three); - - MinimalUnionMember mst_case_six; - mst_case_six.common().member_id(memberId++); - mst_case_six.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_case_six.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_case_six.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_case_six.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - mst_case_six.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mst_case_six.common().member_flags().IS_KEY(false); // Doesn't apply - mst_case_six.common().member_flags().IS_DEFAULT(false); - mst_case_six.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - mst_case_six.common().label_seq().emplace_back(6); - - MD5 case_six_hash("case_six"); - for(int i = 0; i < 4; ++i) - { - mst_case_six.detail().name_hash()[i] = case_six_hash.digest[i]; - } - type_object->minimal().union_type().member_seq().emplace_back(mst_case_six); - - - // Header - //type_object->minimal().union_type().header().detail()... // Empty - - TypeIdentifier* identifier = new TypeIdentifier(); - identifier->_d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().union_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier->equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("Int8Union", identifier, type_object); - delete type_object; - delete identifier; - return TypeObjectFactory::get_instance()->get_type_object("Int8Union", false); -} - -const TypeObject* GetCompleteInt8UnionObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("Int8Union", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_UNION); - - type_object->complete().union_type().union_flags().IS_FINAL(false); - type_object->complete().union_type().union_flags().IS_APPENDABLE(false); - type_object->complete().union_type().union_flags().IS_MUTABLE(false); - type_object->complete().union_type().union_flags().IS_NESTED(false); - type_object->complete().union_type().union_flags().IS_AUTOID_HASH(false); // Unsupported - - type_object->complete().union_type().discriminator().common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().IS_EXTERNAL(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_OPTIONAL(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_KEY(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().IS_DEFAULT(false); // Doesn't apply - - type_object->complete().union_type().discriminator().common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int8_t", false)); - - MemberId memberId = 0; - CompleteUnionMember cst_case_three; - cst_case_three.common().member_id(memberId++); - cst_case_three.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_case_three.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_case_three.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_case_three.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - cst_case_three.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cst_case_three.common().member_flags().IS_KEY(false); // Doesn't apply - cst_case_three.common().member_flags().IS_DEFAULT(false); - cst_case_three.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - cst_case_three.common().label_seq().emplace_back(3); - - - cst_case_three.detail().name("case_three"); - - type_object->complete().union_type().member_seq().emplace_back(cst_case_three); - - CompleteUnionMember cst_case_six; - cst_case_six.common().member_id(memberId++); - cst_case_six.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_case_six.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_case_six.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_case_six.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - cst_case_six.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cst_case_six.common().member_flags().IS_KEY(false); // Doesn't apply - cst_case_six.common().member_flags().IS_DEFAULT(false); - cst_case_six.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - cst_case_six.common().label_seq().emplace_back(6); - - - cst_case_six.detail().name("case_six"); - - type_object->complete().union_type().member_seq().emplace_back(cst_case_six); - - - // Header - type_object->complete().union_type().header().detail().type_name("Int8Union"); - - TypeIdentifier* identifier = new TypeIdentifier(); - identifier->_d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().union_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier->equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("Int8Union", identifier, type_object); - delete type_object; - delete identifier; - return TypeObjectFactory::get_instance()->get_type_object("Int8Union", true); -} - -namespace bitmodule { - const TypeIdentifier* GetParentBitsetIdentifier(bool complete) - { - const TypeIdentifier* c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("ParentBitset", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetParentBitsetObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("ParentBitset", complete); - } - - const TypeObject* GetParentBitsetObject(bool complete) - { - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ParentBitset", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteParentBitsetObject(); - } - // else - return GetMinimalParentBitsetObject(); - } - - const TypeObject* GetMinimalParentBitsetObject() - { - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ParentBitset", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_BITSET); - - MinimalBitfield mbf_parent_bitfield; - mbf_parent_bitfield.common().flags().TRY_CONSTRUCT1(false); - mbf_parent_bitfield.common().flags().TRY_CONSTRUCT2(false); - mbf_parent_bitfield.common().flags().IS_EXTERNAL(false); - mbf_parent_bitfield.common().flags().IS_OPTIONAL(false); - mbf_parent_bitfield.common().flags().IS_MUST_UNDERSTAND(false); - mbf_parent_bitfield.common().flags().IS_KEY(false); - mbf_parent_bitfield.common().flags().IS_DEFAULT(false); - mbf_parent_bitfield.common().position(0); - mbf_parent_bitfield.common().bitcount(17); - mbf_parent_bitfield.common().holder_type(TK_UINT32); - MD5 parent_bitfield_hash("parent_bitfield"); - for(int i = 0; i < 4; ++i) - { - mbf_parent_bitfield.name_hash()[i] = parent_bitfield_hash.digest[i]; - } - type_object->minimal().bitset_type().field_seq().emplace_back(mbf_parent_bitfield); - - - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().bitset_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; - #if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length - #else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length - #endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("ParentBitset", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("ParentBitset", false); - } - - const TypeObject* GetCompleteParentBitsetObject() - { - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ParentBitset", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_BITSET); - - // No flags apply - //type_object->complete().bitset_type().bitset_flags().IS_FINAL(false); - //type_object->complete().bitset_type().bitset_flags().IS_APPENDABLE(false); - //type_object->complete().bitset_type().bitset_flags().IS_MUTABLE(false); - //type_object->complete().bitset_type().bitset_flags().IS_NESTED(false); - //type_object->complete().bitset_type().bitset_flags().IS_AUTOID_HASH(false); - - type_object->complete().bitset_type().header().detail().type_name("ParentBitset"); - - CompleteBitfield cbf_parent_bitfield; - cbf_parent_bitfield.common().flags().TRY_CONSTRUCT1(false); - cbf_parent_bitfield.common().flags().TRY_CONSTRUCT2(false); - cbf_parent_bitfield.common().flags().IS_EXTERNAL(false); - cbf_parent_bitfield.common().flags().IS_OPTIONAL(false); - cbf_parent_bitfield.common().flags().IS_MUST_UNDERSTAND(false); - cbf_parent_bitfield.common().flags().IS_KEY(false); - cbf_parent_bitfield.common().flags().IS_DEFAULT(false); - cbf_parent_bitfield.common().position(0); - cbf_parent_bitfield.common().bitcount(17); - cbf_parent_bitfield.common().holder_type(TK_UINT32); - cbf_parent_bitfield.detail().name("parent_bitfield"); - - // Position annotation always present - { - // Position - AppliedAnnotation ann; - ann.annotation_typeid(*TypeObjectFactory::get_instance()->get_type_identifier_trying_complete("position")); - AppliedAnnotationParameter annParam; - MD5 message_hash("value"); - for(int i = 0; i < 4; ++i) - { - annParam.paramname_hash()[i] = message_hash.digest[i]; - } - AnnotationParameterValue paramValue; - paramValue._d(TK_UINT16); - paramValue.uint_16_value(0); - annParam.value(paramValue); - ann.param_seq().push_back(annParam); - - cbf_parent_bitfield.detail().ann_custom().push_back(ann); - } - - // Use bit_bound as bitcount. - { - // Position - AppliedAnnotation ann; - ann.annotation_typeid(*TypeObjectFactory::get_instance()->get_type_identifier_trying_complete("bit_bound")); - AppliedAnnotationParameter annParam; - MD5 message_hash("value"); - for(int i = 0; i < 4; ++i) - { - annParam.paramname_hash()[i] = message_hash.digest[i]; - } - AnnotationParameterValue paramValue; - paramValue._d(TK_UINT16); - paramValue.uint_16_value(17); - annParam.value(paramValue); - ann.param_seq().push_back(annParam); - - cbf_parent_bitfield.detail().ann_custom().push_back(ann); - } - - type_object->complete().bitset_type().field_seq().emplace_back(cbf_parent_bitfield); - - - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().bitset_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; - #if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length - #else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length - #endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("ParentBitset", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("ParentBitset", true); - } - - const TypeIdentifier* GetMyBitsetIdentifier(bool complete) - { - const TypeIdentifier* c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("MyBitset", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetMyBitsetObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("MyBitset", complete); - } - - const TypeObject* GetMyBitsetObject(bool complete) - { - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyBitset", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteMyBitsetObject(); - } - // else - return GetMinimalMyBitsetObject(); - } - - const TypeObject* GetMinimalMyBitsetObject() - { - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyBitset", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_BITSET); - - MinimalBitfield mbf_a; - mbf_a.common().flags().TRY_CONSTRUCT1(false); - mbf_a.common().flags().TRY_CONSTRUCT2(false); - mbf_a.common().flags().IS_EXTERNAL(false); - mbf_a.common().flags().IS_OPTIONAL(false); - mbf_a.common().flags().IS_MUST_UNDERSTAND(false); - mbf_a.common().flags().IS_KEY(false); - mbf_a.common().flags().IS_DEFAULT(false); - mbf_a.common().position(0); - mbf_a.common().bitcount(3); - mbf_a.common().holder_type(TK_CHAR8); - MD5 a_hash("a"); - for(int i = 0; i < 4; ++i) - { - mbf_a.name_hash()[i] = a_hash.digest[i]; - } - type_object->minimal().bitset_type().field_seq().emplace_back(mbf_a); - - - MinimalBitfield mbf_b; - mbf_b.common().flags().TRY_CONSTRUCT1(false); - mbf_b.common().flags().TRY_CONSTRUCT2(false); - mbf_b.common().flags().IS_EXTERNAL(false); - mbf_b.common().flags().IS_OPTIONAL(false); - mbf_b.common().flags().IS_MUST_UNDERSTAND(false); - mbf_b.common().flags().IS_KEY(false); - mbf_b.common().flags().IS_DEFAULT(false); - mbf_b.common().position(3); - mbf_b.common().bitcount(1); - mbf_b.common().holder_type(TK_BOOLEAN); - MD5 b_hash("b"); - for(int i = 0; i < 4; ++i) - { - mbf_b.name_hash()[i] = b_hash.digest[i]; - } - type_object->minimal().bitset_type().field_seq().emplace_back(mbf_b); - - - - MinimalBitfield mbf_c; - mbf_c.common().flags().TRY_CONSTRUCT1(false); - mbf_c.common().flags().TRY_CONSTRUCT2(false); - mbf_c.common().flags().IS_EXTERNAL(false); - mbf_c.common().flags().IS_OPTIONAL(false); - mbf_c.common().flags().IS_MUST_UNDERSTAND(false); - mbf_c.common().flags().IS_KEY(false); - mbf_c.common().flags().IS_DEFAULT(false); - mbf_c.common().position(8); - mbf_c.common().bitcount(10); - mbf_c.common().holder_type(TK_UINT16); - MD5 c_hash("c"); - for(int i = 0; i < 4; ++i) - { - mbf_c.name_hash()[i] = c_hash.digest[i]; - } - type_object->minimal().bitset_type().field_seq().emplace_back(mbf_c); - - - MinimalBitfield mbf_d; - mbf_d.common().flags().TRY_CONSTRUCT1(false); - mbf_d.common().flags().TRY_CONSTRUCT2(false); - mbf_d.common().flags().IS_EXTERNAL(false); - mbf_d.common().flags().IS_OPTIONAL(false); - mbf_d.common().flags().IS_MUST_UNDERSTAND(false); - mbf_d.common().flags().IS_KEY(false); - mbf_d.common().flags().IS_DEFAULT(false); - mbf_d.common().position(18); - mbf_d.common().bitcount(5); - mbf_d.common().holder_type(TK_INT16); - MD5 d_hash("d"); - for(int i = 0; i < 4; ++i) - { - mbf_d.name_hash()[i] = d_hash.digest[i]; - } - type_object->minimal().bitset_type().field_seq().emplace_back(mbf_d); - - - MinimalBitfield mbf_e; - mbf_e.common().flags().TRY_CONSTRUCT1(false); - mbf_e.common().flags().TRY_CONSTRUCT2(false); - mbf_e.common().flags().IS_EXTERNAL(false); - mbf_e.common().flags().IS_OPTIONAL(false); - mbf_e.common().flags().IS_MUST_UNDERSTAND(false); - mbf_e.common().flags().IS_KEY(false); - mbf_e.common().flags().IS_DEFAULT(false); - mbf_e.common().position(23); - mbf_e.common().bitcount(5); - mbf_e.common().holder_type(TK_INT16); - MD5 e_hash("e"); - for(int i = 0; i < 4; ++i) - { - mbf_e.name_hash()[i] = e_hash.digest[i]; - } - type_object->minimal().bitset_type().field_seq().emplace_back(mbf_e); - - - MinimalBitfield mbf_f; - mbf_f.common().flags().TRY_CONSTRUCT1(false); - mbf_f.common().flags().TRY_CONSTRUCT2(false); - mbf_f.common().flags().IS_EXTERNAL(false); - mbf_f.common().flags().IS_OPTIONAL(false); - mbf_f.common().flags().IS_MUST_UNDERSTAND(false); - mbf_f.common().flags().IS_KEY(false); - mbf_f.common().flags().IS_DEFAULT(false); - mbf_f.common().position(28); - mbf_f.common().bitcount(5); - mbf_f.common().holder_type(TK_INT16); - MD5 f_hash("f"); - for(int i = 0; i < 4; ++i) - { - mbf_f.name_hash()[i] = f_hash.digest[i]; - } - type_object->minimal().bitset_type().field_seq().emplace_back(mbf_f); - - - type_object->minimal().bitset_type().header().base_type(*GetParentBitsetIdentifier(false)); - - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().bitset_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; - #if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length - #else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length - #endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MyBitset", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyBitset", false); - } - - const TypeObject* GetCompleteMyBitsetObject() - { - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyBitset", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_BITSET); - - // No flags apply - //type_object->complete().bitset_type().bitset_flags().IS_FINAL(false); - //type_object->complete().bitset_type().bitset_flags().IS_APPENDABLE(false); - //type_object->complete().bitset_type().bitset_flags().IS_MUTABLE(false); - //type_object->complete().bitset_type().bitset_flags().IS_NESTED(false); - //type_object->complete().bitset_type().bitset_flags().IS_AUTOID_HASH(false); - - type_object->complete().bitset_type().header().detail().type_name("MyBitset"); - - CompleteBitfield cbf_a; - cbf_a.common().flags().TRY_CONSTRUCT1(false); - cbf_a.common().flags().TRY_CONSTRUCT2(false); - cbf_a.common().flags().IS_EXTERNAL(false); - cbf_a.common().flags().IS_OPTIONAL(false); - cbf_a.common().flags().IS_MUST_UNDERSTAND(false); - cbf_a.common().flags().IS_KEY(false); - cbf_a.common().flags().IS_DEFAULT(false); - cbf_a.common().position(0); - cbf_a.common().bitcount(3); - cbf_a.common().holder_type(TK_CHAR8); - cbf_a.detail().name("a"); - - // Position annotation always present - { - // Position - AppliedAnnotation ann; - ann.annotation_typeid(*TypeObjectFactory::get_instance()->get_type_identifier_trying_complete("position")); - AppliedAnnotationParameter annParam; - MD5 message_hash("value"); - for(int i = 0; i < 4; ++i) - { - annParam.paramname_hash()[i] = message_hash.digest[i]; - } - AnnotationParameterValue paramValue; - paramValue._d(TK_UINT16); - paramValue.uint_16_value(0); - annParam.value(paramValue); - ann.param_seq().push_back(annParam); - - cbf_a.detail().ann_custom().push_back(ann); - } - - // Use bit_bound as bitcount. - { - // Position - AppliedAnnotation ann; - ann.annotation_typeid(*TypeObjectFactory::get_instance()->get_type_identifier_trying_complete("bit_bound")); - AppliedAnnotationParameter annParam; - MD5 message_hash("value"); - for(int i = 0; i < 4; ++i) - { - annParam.paramname_hash()[i] = message_hash.digest[i]; - } - AnnotationParameterValue paramValue; - paramValue._d(TK_UINT16); - paramValue.uint_16_value(3); - annParam.value(paramValue); - ann.param_seq().push_back(annParam); - - cbf_a.detail().ann_custom().push_back(ann); - } - - type_object->complete().bitset_type().field_seq().emplace_back(cbf_a); - - - CompleteBitfield cbf_b; - cbf_b.common().flags().TRY_CONSTRUCT1(false); - cbf_b.common().flags().TRY_CONSTRUCT2(false); - cbf_b.common().flags().IS_EXTERNAL(false); - cbf_b.common().flags().IS_OPTIONAL(false); - cbf_b.common().flags().IS_MUST_UNDERSTAND(false); - cbf_b.common().flags().IS_KEY(false); - cbf_b.common().flags().IS_DEFAULT(false); - cbf_b.common().position(3); - cbf_b.common().bitcount(1); - cbf_b.common().holder_type(TK_BOOLEAN); - cbf_b.detail().name("b"); - - // Position annotation always present - { - // Position - AppliedAnnotation ann; - ann.annotation_typeid(*TypeObjectFactory::get_instance()->get_type_identifier_trying_complete("position")); - AppliedAnnotationParameter annParam; - MD5 message_hash("value"); - for(int i = 0; i < 4; ++i) - { - annParam.paramname_hash()[i] = message_hash.digest[i]; - } - AnnotationParameterValue paramValue; - paramValue._d(TK_UINT16); - paramValue.uint_16_value(3); - annParam.value(paramValue); - ann.param_seq().push_back(annParam); - - cbf_b.detail().ann_custom().push_back(ann); - } - - // Use bit_bound as bitcount. - { - // Position - AppliedAnnotation ann; - ann.annotation_typeid(*TypeObjectFactory::get_instance()->get_type_identifier_trying_complete("bit_bound")); - AppliedAnnotationParameter annParam; - MD5 message_hash("value"); - for(int i = 0; i < 4; ++i) - { - annParam.paramname_hash()[i] = message_hash.digest[i]; - } - AnnotationParameterValue paramValue; - paramValue._d(TK_UINT16); - paramValue.uint_16_value(1); - annParam.value(paramValue); - ann.param_seq().push_back(annParam); - - cbf_b.detail().ann_custom().push_back(ann); - } - - type_object->complete().bitset_type().field_seq().emplace_back(cbf_b); - - - - CompleteBitfield cbf_c; - cbf_c.common().flags().TRY_CONSTRUCT1(false); - cbf_c.common().flags().TRY_CONSTRUCT2(false); - cbf_c.common().flags().IS_EXTERNAL(false); - cbf_c.common().flags().IS_OPTIONAL(false); - cbf_c.common().flags().IS_MUST_UNDERSTAND(false); - cbf_c.common().flags().IS_KEY(false); - cbf_c.common().flags().IS_DEFAULT(false); - cbf_c.common().position(8); - cbf_c.common().bitcount(10); - cbf_c.common().holder_type(TK_UINT16); - cbf_c.detail().name("c"); - - // Position annotation always present - { - // Position - AppliedAnnotation ann; - ann.annotation_typeid(*TypeObjectFactory::get_instance()->get_type_identifier_trying_complete("position")); - AppliedAnnotationParameter annParam; - MD5 message_hash("value"); - for(int i = 0; i < 4; ++i) - { - annParam.paramname_hash()[i] = message_hash.digest[i]; - } - AnnotationParameterValue paramValue; - paramValue._d(TK_UINT16); - paramValue.uint_16_value(8); - annParam.value(paramValue); - ann.param_seq().push_back(annParam); - - cbf_c.detail().ann_custom().push_back(ann); - } - - // Use bit_bound as bitcount. - { - // Position - AppliedAnnotation ann; - ann.annotation_typeid(*TypeObjectFactory::get_instance()->get_type_identifier_trying_complete("bit_bound")); - AppliedAnnotationParameter annParam; - MD5 message_hash("value"); - for(int i = 0; i < 4; ++i) - { - annParam.paramname_hash()[i] = message_hash.digest[i]; - } - AnnotationParameterValue paramValue; - paramValue._d(TK_UINT16); - paramValue.uint_16_value(10); - annParam.value(paramValue); - ann.param_seq().push_back(annParam); - - cbf_c.detail().ann_custom().push_back(ann); - } - - type_object->complete().bitset_type().field_seq().emplace_back(cbf_c); - - - CompleteBitfield cbf_d; - cbf_d.common().flags().TRY_CONSTRUCT1(false); - cbf_d.common().flags().TRY_CONSTRUCT2(false); - cbf_d.common().flags().IS_EXTERNAL(false); - cbf_d.common().flags().IS_OPTIONAL(false); - cbf_d.common().flags().IS_MUST_UNDERSTAND(false); - cbf_d.common().flags().IS_KEY(false); - cbf_d.common().flags().IS_DEFAULT(false); - cbf_d.common().position(18); - cbf_d.common().bitcount(5); - cbf_d.common().holder_type(TK_INT16); - cbf_d.detail().name("d"); - - // Position annotation always present - { - // Position - AppliedAnnotation ann; - ann.annotation_typeid(*TypeObjectFactory::get_instance()->get_type_identifier_trying_complete("position")); - AppliedAnnotationParameter annParam; - MD5 message_hash("value"); - for(int i = 0; i < 4; ++i) - { - annParam.paramname_hash()[i] = message_hash.digest[i]; - } - AnnotationParameterValue paramValue; - paramValue._d(TK_UINT16); - paramValue.uint_16_value(18); - annParam.value(paramValue); - ann.param_seq().push_back(annParam); - - cbf_d.detail().ann_custom().push_back(ann); - } - - // Use bit_bound as bitcount. - { - // Position - AppliedAnnotation ann; - ann.annotation_typeid(*TypeObjectFactory::get_instance()->get_type_identifier_trying_complete("bit_bound")); - AppliedAnnotationParameter annParam; - MD5 message_hash("value"); - for(int i = 0; i < 4; ++i) - { - annParam.paramname_hash()[i] = message_hash.digest[i]; - } - AnnotationParameterValue paramValue; - paramValue._d(TK_UINT16); - paramValue.uint_16_value(5); - annParam.value(paramValue); - ann.param_seq().push_back(annParam); - - cbf_d.detail().ann_custom().push_back(ann); - } - - type_object->complete().bitset_type().field_seq().emplace_back(cbf_d); - - - CompleteBitfield cbf_e; - cbf_e.common().flags().TRY_CONSTRUCT1(false); - cbf_e.common().flags().TRY_CONSTRUCT2(false); - cbf_e.common().flags().IS_EXTERNAL(false); - cbf_e.common().flags().IS_OPTIONAL(false); - cbf_e.common().flags().IS_MUST_UNDERSTAND(false); - cbf_e.common().flags().IS_KEY(false); - cbf_e.common().flags().IS_DEFAULT(false); - cbf_e.common().position(23); - cbf_e.common().bitcount(5); - cbf_e.common().holder_type(TK_INT16); - cbf_e.detail().name("e"); - - // Position annotation always present - { - // Position - AppliedAnnotation ann; - ann.annotation_typeid(*TypeObjectFactory::get_instance()->get_type_identifier_trying_complete("position")); - AppliedAnnotationParameter annParam; - MD5 message_hash("value"); - for(int i = 0; i < 4; ++i) - { - annParam.paramname_hash()[i] = message_hash.digest[i]; - } - AnnotationParameterValue paramValue; - paramValue._d(TK_UINT16); - paramValue.uint_16_value(23); - annParam.value(paramValue); - ann.param_seq().push_back(annParam); - - cbf_e.detail().ann_custom().push_back(ann); - } - - // Use bit_bound as bitcount. - { - // Position - AppliedAnnotation ann; - ann.annotation_typeid(*TypeObjectFactory::get_instance()->get_type_identifier_trying_complete("bit_bound")); - AppliedAnnotationParameter annParam; - MD5 message_hash("value"); - for(int i = 0; i < 4; ++i) - { - annParam.paramname_hash()[i] = message_hash.digest[i]; - } - AnnotationParameterValue paramValue; - paramValue._d(TK_UINT16); - paramValue.uint_16_value(5); - annParam.value(paramValue); - ann.param_seq().push_back(annParam); - - cbf_e.detail().ann_custom().push_back(ann); - } - - type_object->complete().bitset_type().field_seq().emplace_back(cbf_e); - - - CompleteBitfield cbf_f; - cbf_f.common().flags().TRY_CONSTRUCT1(false); - cbf_f.common().flags().TRY_CONSTRUCT2(false); - cbf_f.common().flags().IS_EXTERNAL(false); - cbf_f.common().flags().IS_OPTIONAL(false); - cbf_f.common().flags().IS_MUST_UNDERSTAND(false); - cbf_f.common().flags().IS_KEY(false); - cbf_f.common().flags().IS_DEFAULT(false); - cbf_f.common().position(28); - cbf_f.common().bitcount(5); - cbf_f.common().holder_type(TK_INT16); - cbf_f.detail().name("f"); - - // Position annotation always present - { - // Position - AppliedAnnotation ann; - ann.annotation_typeid(*TypeObjectFactory::get_instance()->get_type_identifier_trying_complete("position")); - AppliedAnnotationParameter annParam; - MD5 message_hash("value"); - for(int i = 0; i < 4; ++i) - { - annParam.paramname_hash()[i] = message_hash.digest[i]; - } - AnnotationParameterValue paramValue; - paramValue._d(TK_UINT16); - paramValue.uint_16_value(28); - annParam.value(paramValue); - ann.param_seq().push_back(annParam); - - cbf_f.detail().ann_custom().push_back(ann); - } - - // Use bit_bound as bitcount. - { - // Position - AppliedAnnotation ann; - ann.annotation_typeid(*TypeObjectFactory::get_instance()->get_type_identifier_trying_complete("bit_bound")); - AppliedAnnotationParameter annParam; - MD5 message_hash("value"); - for(int i = 0; i < 4; ++i) - { - annParam.paramname_hash()[i] = message_hash.digest[i]; - } - AnnotationParameterValue paramValue; - paramValue._d(TK_UINT16); - paramValue.uint_16_value(5); - annParam.value(paramValue); - ann.param_seq().push_back(annParam); - - cbf_f.detail().ann_custom().push_back(ann); - } - - type_object->complete().bitset_type().field_seq().emplace_back(cbf_f); - - - type_object->complete().bitset_type().header().base_type(*GetParentBitsetIdentifier(true)); - - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().bitset_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; - #if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length - #else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length - #endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MyBitset", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyBitset", true); - } - - const TypeIdentifier* GetMyBitMaskIdentifier(bool complete) - { - const TypeIdentifier* c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("MyBitMask", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetMyBitMaskObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("MyBitMask", complete); - } - - const TypeObject* GetMyBitMaskObject(bool complete) - { - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyBitMask", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteMyBitMaskObject(); - } - // else - return GetMinimalMyBitMaskObject(); - } - - const TypeObject* GetMinimalMyBitMaskObject() - { - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyBitMask", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_BITMASK); - - type_object->minimal().bitmask_type().header().common().bit_bound(8); - - MinimalBitflag mbf_flag0; - mbf_flag0.common().flags().TRY_CONSTRUCT1(false); - mbf_flag0.common().flags().TRY_CONSTRUCT2(false); - mbf_flag0.common().flags().IS_EXTERNAL(false); - mbf_flag0.common().flags().IS_OPTIONAL(false); - mbf_flag0.common().flags().IS_MUST_UNDERSTAND(false); - mbf_flag0.common().flags().IS_KEY(false); - mbf_flag0.common().flags().IS_DEFAULT(false); - mbf_flag0.common().position(0); - MD5 flag0_hash("flag0"); - for(int i = 0; i < 4; ++i) - { - mbf_flag0.detail().name_hash()[i] = flag0_hash.digest[i]; - } - type_object->minimal().bitmask_type().flag_seq().emplace_back(mbf_flag0); - - MinimalBitflag mbf_flag1; - mbf_flag1.common().flags().TRY_CONSTRUCT1(false); - mbf_flag1.common().flags().TRY_CONSTRUCT2(false); - mbf_flag1.common().flags().IS_EXTERNAL(false); - mbf_flag1.common().flags().IS_OPTIONAL(false); - mbf_flag1.common().flags().IS_MUST_UNDERSTAND(false); - mbf_flag1.common().flags().IS_KEY(false); - mbf_flag1.common().flags().IS_DEFAULT(false); - mbf_flag1.common().position(1); - MD5 flag1_hash("flag1"); - for(int i = 0; i < 4; ++i) - { - mbf_flag1.detail().name_hash()[i] = flag1_hash.digest[i]; - } - type_object->minimal().bitmask_type().flag_seq().emplace_back(mbf_flag1); - - MinimalBitflag mbf_flag4; - mbf_flag4.common().flags().TRY_CONSTRUCT1(false); - mbf_flag4.common().flags().TRY_CONSTRUCT2(false); - mbf_flag4.common().flags().IS_EXTERNAL(false); - mbf_flag4.common().flags().IS_OPTIONAL(false); - mbf_flag4.common().flags().IS_MUST_UNDERSTAND(false); - mbf_flag4.common().flags().IS_KEY(false); - mbf_flag4.common().flags().IS_DEFAULT(false); - mbf_flag4.common().position(4); - MD5 flag4_hash("flag4"); - for(int i = 0; i < 4; ++i) - { - mbf_flag4.detail().name_hash()[i] = flag4_hash.digest[i]; - } - type_object->minimal().bitmask_type().flag_seq().emplace_back(mbf_flag4); - - MinimalBitflag mbf_flag6; - mbf_flag6.common().flags().TRY_CONSTRUCT1(false); - mbf_flag6.common().flags().TRY_CONSTRUCT2(false); - mbf_flag6.common().flags().IS_EXTERNAL(false); - mbf_flag6.common().flags().IS_OPTIONAL(false); - mbf_flag6.common().flags().IS_MUST_UNDERSTAND(false); - mbf_flag6.common().flags().IS_KEY(false); - mbf_flag6.common().flags().IS_DEFAULT(false); - mbf_flag6.common().position(6); - MD5 flag6_hash("flag6"); - for(int i = 0; i < 4; ++i) - { - mbf_flag6.detail().name_hash()[i] = flag6_hash.digest[i]; - } - type_object->minimal().bitmask_type().flag_seq().emplace_back(mbf_flag6); - - MinimalBitflag mbf_flag7; - mbf_flag7.common().flags().TRY_CONSTRUCT1(false); - mbf_flag7.common().flags().TRY_CONSTRUCT2(false); - mbf_flag7.common().flags().IS_EXTERNAL(false); - mbf_flag7.common().flags().IS_OPTIONAL(false); - mbf_flag7.common().flags().IS_MUST_UNDERSTAND(false); - mbf_flag7.common().flags().IS_KEY(false); - mbf_flag7.common().flags().IS_DEFAULT(false); - mbf_flag7.common().position(7); - MD5 flag7_hash("flag7"); - for(int i = 0; i < 4; ++i) - { - mbf_flag7.detail().name_hash()[i] = flag7_hash.digest[i]; - } - type_object->minimal().bitmask_type().flag_seq().emplace_back(mbf_flag7); - - - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().bitmask_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; - #if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length - #else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length - #endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MyBitMask", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyBitMask", false); - } - - const TypeObject* GetCompleteMyBitMaskObject() - { - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyBitMask", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_BITMASK); - - // No flags apply - //type_object->complete().bitmask_type().bitmask_flags().IS_FINAL(false); - //type_object->complete().bitmask_type().bitmask_flags().IS_APPENDABLE(false); - //type_object->complete().bitmask_type().bitmask_flags().IS_MUTABLE(false); - //type_object->complete().bitmask_type().bitmask_flags().IS_NESTED(false); - //type_object->complete().bitmask_type().bitmask_flags().IS_AUTOID_HASH(false); - - type_object->complete().bitmask_type().header().common().bit_bound(8); - - { - AppliedAnnotation ann; - //ann.annotation_typeid(Getbit_boundIdentifier(true)); - ann.annotation_typeid(*TypeObjectFactory::get_instance()->get_type_identifier_trying_complete("bit_bound")); - { - AppliedAnnotationParameter annParam; - MD5 message_hash("value"); - for(int i = 0; i < 4; ++i) - { - annParam.paramname_hash()[i] = message_hash.digest[i]; - } - AnnotationParameterValue paramValue; - paramValue._d(TK_UINT16); - paramValue.from_string("8"); - annParam.value(paramValue); - ann.param_seq().push_back(annParam); - } - - type_object->complete().bitmask_type().header().detail().ann_custom().push_back(ann); - } - - - type_object->complete().bitmask_type().header().detail().type_name("MyBitMask"); - - CompleteBitflag cbf_flag0; - cbf_flag0.common().flags().TRY_CONSTRUCT1(false); - cbf_flag0.common().flags().TRY_CONSTRUCT2(false); - cbf_flag0.common().flags().IS_EXTERNAL(false); - cbf_flag0.common().flags().IS_OPTIONAL(false); - cbf_flag0.common().flags().IS_MUST_UNDERSTAND(false); - cbf_flag0.common().flags().IS_KEY(false); - cbf_flag0.common().flags().IS_DEFAULT(false); - cbf_flag0.common().position(0); - cbf_flag0.detail().name("flag0"); - - // Position annotation always present - { - AppliedAnnotation ann; - ann.annotation_typeid(*TypeObjectFactory::get_instance()->get_type_identifier_trying_complete("position")); - AppliedAnnotationParameter annParam; - MD5 message_hash("value"); - for(int i = 0; i < 4; ++i) - { - annParam.paramname_hash()[i] = message_hash.digest[i]; - } - AnnotationParameterValue paramValue; - paramValue._d(TK_UINT16); - paramValue.uint_16_value(0); - annParam.value(paramValue); - ann.param_seq().push_back(annParam); - - cbf_flag0.detail().ann_custom().push_back(ann); - } - - { - if (std::strcmp("position", "position") != 0) - { - AppliedAnnotation ann; - //ann.annotation_typeid(GetpositionIdentifier(true)); - ann.annotation_typeid(*TypeObjectFactory::get_instance()->get_type_identifier_trying_complete("position")); - { - AppliedAnnotationParameter annParam; - MD5 message_hash("value"); - for(int i = 0; i < 4; ++i) - { - annParam.paramname_hash()[i] = message_hash.digest[i]; - } - AnnotationParameterValue paramValue; - paramValue._d(TK_UINT16); - paramValue.from_string("0"); - annParam.value(paramValue); - ann.param_seq().push_back(annParam); - } - - cbf_flag0.detail().ann_custom().push_back(ann); - } - } - - - type_object->complete().bitmask_type().flag_seq().emplace_back(cbf_flag0); - - CompleteBitflag cbf_flag1; - cbf_flag1.common().flags().TRY_CONSTRUCT1(false); - cbf_flag1.common().flags().TRY_CONSTRUCT2(false); - cbf_flag1.common().flags().IS_EXTERNAL(false); - cbf_flag1.common().flags().IS_OPTIONAL(false); - cbf_flag1.common().flags().IS_MUST_UNDERSTAND(false); - cbf_flag1.common().flags().IS_KEY(false); - cbf_flag1.common().flags().IS_DEFAULT(false); - cbf_flag1.common().position(1); - cbf_flag1.detail().name("flag1"); - - // Position annotation always present - { - AppliedAnnotation ann; - ann.annotation_typeid(*TypeObjectFactory::get_instance()->get_type_identifier_trying_complete("position")); - AppliedAnnotationParameter annParam; - MD5 message_hash("value"); - for(int i = 0; i < 4; ++i) - { - annParam.paramname_hash()[i] = message_hash.digest[i]; - } - AnnotationParameterValue paramValue; - paramValue._d(TK_UINT16); - paramValue.uint_16_value(1); - annParam.value(paramValue); - ann.param_seq().push_back(annParam); - - cbf_flag1.detail().ann_custom().push_back(ann); - } - - { - if (std::strcmp("position", "position") != 0) - { - AppliedAnnotation ann; - //ann.annotation_typeid(GetpositionIdentifier(true)); - ann.annotation_typeid(*TypeObjectFactory::get_instance()->get_type_identifier_trying_complete("position")); - { - AppliedAnnotationParameter annParam; - MD5 message_hash("value"); - for(int i = 0; i < 4; ++i) - { - annParam.paramname_hash()[i] = message_hash.digest[i]; - } - AnnotationParameterValue paramValue; - paramValue._d(TK_UINT16); - paramValue.from_string("1"); - annParam.value(paramValue); - ann.param_seq().push_back(annParam); - } - - cbf_flag1.detail().ann_custom().push_back(ann); - } - } - - - type_object->complete().bitmask_type().flag_seq().emplace_back(cbf_flag1); - - CompleteBitflag cbf_flag4; - cbf_flag4.common().flags().TRY_CONSTRUCT1(false); - cbf_flag4.common().flags().TRY_CONSTRUCT2(false); - cbf_flag4.common().flags().IS_EXTERNAL(false); - cbf_flag4.common().flags().IS_OPTIONAL(false); - cbf_flag4.common().flags().IS_MUST_UNDERSTAND(false); - cbf_flag4.common().flags().IS_KEY(false); - cbf_flag4.common().flags().IS_DEFAULT(false); - cbf_flag4.common().position(4); - cbf_flag4.detail().name("flag4"); - - // Position annotation always present - { - AppliedAnnotation ann; - ann.annotation_typeid(*TypeObjectFactory::get_instance()->get_type_identifier_trying_complete("position")); - AppliedAnnotationParameter annParam; - MD5 message_hash("value"); - for(int i = 0; i < 4; ++i) - { - annParam.paramname_hash()[i] = message_hash.digest[i]; - } - AnnotationParameterValue paramValue; - paramValue._d(TK_UINT16); - paramValue.uint_16_value(4); - annParam.value(paramValue); - ann.param_seq().push_back(annParam); - - cbf_flag4.detail().ann_custom().push_back(ann); - } - - { - if (std::strcmp("position", "position") != 0) - { - AppliedAnnotation ann; - //ann.annotation_typeid(GetpositionIdentifier(true)); - ann.annotation_typeid(*TypeObjectFactory::get_instance()->get_type_identifier_trying_complete("position")); - { - AppliedAnnotationParameter annParam; - MD5 message_hash("value"); - for(int i = 0; i < 4; ++i) - { - annParam.paramname_hash()[i] = message_hash.digest[i]; - } - AnnotationParameterValue paramValue; - paramValue._d(TK_UINT16); - paramValue.from_string("4"); - annParam.value(paramValue); - ann.param_seq().push_back(annParam); - } - - cbf_flag4.detail().ann_custom().push_back(ann); - } - } - - - type_object->complete().bitmask_type().flag_seq().emplace_back(cbf_flag4); - - CompleteBitflag cbf_flag6; - cbf_flag6.common().flags().TRY_CONSTRUCT1(false); - cbf_flag6.common().flags().TRY_CONSTRUCT2(false); - cbf_flag6.common().flags().IS_EXTERNAL(false); - cbf_flag6.common().flags().IS_OPTIONAL(false); - cbf_flag6.common().flags().IS_MUST_UNDERSTAND(false); - cbf_flag6.common().flags().IS_KEY(false); - cbf_flag6.common().flags().IS_DEFAULT(false); - cbf_flag6.common().position(6); - cbf_flag6.detail().name("flag6"); - - // Position annotation always present - { - AppliedAnnotation ann; - ann.annotation_typeid(*TypeObjectFactory::get_instance()->get_type_identifier_trying_complete("position")); - AppliedAnnotationParameter annParam; - MD5 message_hash("value"); - for(int i = 0; i < 4; ++i) - { - annParam.paramname_hash()[i] = message_hash.digest[i]; - } - AnnotationParameterValue paramValue; - paramValue._d(TK_UINT16); - paramValue.uint_16_value(6); - annParam.value(paramValue); - ann.param_seq().push_back(annParam); - - cbf_flag6.detail().ann_custom().push_back(ann); - } - - { - if (std::strcmp("position", "position") != 0) - { - AppliedAnnotation ann; - //ann.annotation_typeid(GetpositionIdentifier(true)); - ann.annotation_typeid(*TypeObjectFactory::get_instance()->get_type_identifier_trying_complete("position")); - { - AppliedAnnotationParameter annParam; - MD5 message_hash("value"); - for(int i = 0; i < 4; ++i) - { - annParam.paramname_hash()[i] = message_hash.digest[i]; - } - AnnotationParameterValue paramValue; - paramValue._d(TK_UINT16); - paramValue.from_string("6"); - annParam.value(paramValue); - ann.param_seq().push_back(annParam); - } - - cbf_flag6.detail().ann_custom().push_back(ann); - } - } - - - type_object->complete().bitmask_type().flag_seq().emplace_back(cbf_flag6); - - CompleteBitflag cbf_flag7; - cbf_flag7.common().flags().TRY_CONSTRUCT1(false); - cbf_flag7.common().flags().TRY_CONSTRUCT2(false); - cbf_flag7.common().flags().IS_EXTERNAL(false); - cbf_flag7.common().flags().IS_OPTIONAL(false); - cbf_flag7.common().flags().IS_MUST_UNDERSTAND(false); - cbf_flag7.common().flags().IS_KEY(false); - cbf_flag7.common().flags().IS_DEFAULT(false); - cbf_flag7.common().position(7); - cbf_flag7.detail().name("flag7"); - - // Position annotation always present - { - AppliedAnnotation ann; - ann.annotation_typeid(*TypeObjectFactory::get_instance()->get_type_identifier_trying_complete("position")); - AppliedAnnotationParameter annParam; - MD5 message_hash("value"); - for(int i = 0; i < 4; ++i) - { - annParam.paramname_hash()[i] = message_hash.digest[i]; - } - AnnotationParameterValue paramValue; - paramValue._d(TK_UINT16); - paramValue.uint_16_value(7); - annParam.value(paramValue); - ann.param_seq().push_back(annParam); - - cbf_flag7.detail().ann_custom().push_back(ann); - } - - type_object->complete().bitmask_type().flag_seq().emplace_back(cbf_flag7); - - - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().bitmask_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; - #if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length - #else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length - #endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MyBitMask", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyBitMask", true); - } - - - - const TypeIdentifier* GetBitsetBitmaskIdentifier(bool complete) - { - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("BitsetBitmask", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetBitsetBitmaskObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("BitsetBitmask", complete); - } - - const TypeObject* GetBitsetBitmaskObject(bool complete) - { - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("BitsetBitmask", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteBitsetBitmaskObject(); - } - //else - return GetMinimalBitsetBitmaskObject(); - } - - const TypeObject* GetMinimalBitsetBitmaskObject() - { - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("BitsetBitmask", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_mybitset; - mst_mybitset.common().member_id(memberId++); - mst_mybitset.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_mybitset.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_mybitset.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_mybitset.common().member_flags().IS_OPTIONAL(false); - mst_mybitset.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_mybitset.common().member_flags().IS_KEY(false); - mst_mybitset.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_mybitset.common().member_type_id(*bitmodule::GetMyBitsetIdentifier(false)); - - MD5 mybitset_hash("mybitset"); - for(int i = 0; i < 4; ++i) - { - mst_mybitset.detail().name_hash()[i] = mybitset_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_mybitset); - - MinimalStructMember mst_mybitmask; - mst_mybitmask.common().member_id(memberId++); - mst_mybitmask.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_mybitmask.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_mybitmask.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_mybitmask.common().member_flags().IS_OPTIONAL(false); - mst_mybitmask.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_mybitmask.common().member_flags().IS_KEY(false); - mst_mybitmask.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_mybitmask.common().member_type_id(*bitmodule::GetMyBitMaskIdentifier(false)); - - MD5 mybitmask_hash("mybitmask"); - for(int i = 0; i < 4; ++i) - { - mst_mybitmask.detail().name_hash()[i] = mybitmask_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_mybitmask); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; - #if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length - #else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length - #endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("BitsetBitmask", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("BitsetBitmask", false); - } - - const TypeObject* GetCompleteBitsetBitmaskObject() - { - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("BitsetBitmask", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_mybitset; - cst_mybitset.common().member_id(memberId++); - cst_mybitset.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_mybitset.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_mybitset.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_mybitset.common().member_flags().IS_OPTIONAL(false); - cst_mybitset.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_mybitset.common().member_flags().IS_KEY(false); - cst_mybitset.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_mybitset.common().member_type_id(*bitmodule::GetMyBitsetIdentifier(true)); - - cst_mybitset.detail().name("mybitset"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_mybitset); - - CompleteStructMember cst_mybitmask; - cst_mybitmask.common().member_id(memberId++); - cst_mybitmask.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_mybitmask.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_mybitmask.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_mybitmask.common().member_flags().IS_OPTIONAL(false); - cst_mybitmask.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_mybitmask.common().member_flags().IS_KEY(false); - cst_mybitmask.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_mybitmask.common().member_type_id(*bitmodule::GetMyBitMaskIdentifier(true)); - - cst_mybitmask.detail().name("mybitmask"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_mybitmask); - - - // Header - type_object->complete().struct_type().header().detail().type_name("BitsetBitmask"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; - #if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length - #else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length - #endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("BitsetBitmask", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("BitsetBitmask", true); - } - - - - const TypeIdentifier* GetBM2Identifier(bool complete) - { - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("BM2", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetBM2Object(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("BM2", complete); - } - - const TypeObject* GetBM2Object(bool complete) - { - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("BM2", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteBM2Object(); - } - //else - return GetMinimalBM2Object(); - } - - const TypeObject* GetMinimalBM2Object() - { - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("BM2", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_two; - mst_two.common().member_id(memberId++); - mst_two.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_two.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_two.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_two.common().member_flags().IS_OPTIONAL(false); - mst_two.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_two.common().member_flags().IS_KEY(false); - mst_two.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_two.common().member_type_id(*bitmodule::GetMyBitMaskIdentifier(false)); - - MD5 two_hash("two"); - for(int i = 0; i < 4; ++i) - { - mst_two.detail().name_hash()[i] = two_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_two); - - MinimalStructMember mst_mylong; - mst_mylong.common().member_id(memberId++); - mst_mylong.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_mylong.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_mylong.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_mylong.common().member_flags().IS_OPTIONAL(false); - mst_mylong.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_mylong.common().member_flags().IS_KEY(false); - mst_mylong.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_mylong.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - MD5 mylong_hash("mylong"); - for(int i = 0; i < 4; ++i) - { - mst_mylong.detail().name_hash()[i] = mylong_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_mylong); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - type_object->minimal().struct_type().header().base_type(*GetBitsetBitmaskIdentifier(false)); - - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; - #if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length - #else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length - #endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("BM2", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("BM2", false); - } - - const TypeObject* GetCompleteBM2Object() - { - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("BM2", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_two; - cst_two.common().member_id(memberId++); - cst_two.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_two.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_two.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_two.common().member_flags().IS_OPTIONAL(false); - cst_two.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_two.common().member_flags().IS_KEY(false); - cst_two.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_two.common().member_type_id(*bitmodule::GetMyBitMaskIdentifier(true)); - - cst_two.detail().name("two"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_two); - - CompleteStructMember cst_mylong; - cst_mylong.common().member_id(memberId++); - cst_mylong.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_mylong.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_mylong.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_mylong.common().member_flags().IS_OPTIONAL(false); - cst_mylong.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_mylong.common().member_flags().IS_KEY(false); - cst_mylong.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_mylong.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - cst_mylong.detail().name("mylong"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_mylong); - - - // Header - type_object->complete().struct_type().header().detail().type_name("BM2"); - // TODO inheritance - type_object->complete().struct_type().header().base_type(*GetBitsetBitmaskIdentifier(true)); - - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; - #if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length - #else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length - #endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("BM2", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("BM2", true); - } - -} // namespace bitmodule - - -const TypeIdentifier* GetStructTestIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("StructTest", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetStructTestObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("StructTest", complete); -} - -const TypeObject* GetStructTestObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("StructTest", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteStructTestObject(); - } - //else - return GetMinimalStructTestObject(); -} - -const TypeObject* GetMinimalStructTestObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("StructTest", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_octetUnion; - mst_octetUnion.common().member_id(memberId++); - mst_octetUnion.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_octetUnion.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_octetUnion.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_octetUnion.common().member_flags().IS_OPTIONAL(false); - mst_octetUnion.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_octetUnion.common().member_flags().IS_KEY(false); - mst_octetUnion.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_octetUnion.common().member_type_id(*GetOctetUnionIdentifier(false)); - - MD5 octetUnion_hash("octetUnion"); - for(int i = 0; i < 4; ++i) - { - mst_octetUnion.detail().name_hash()[i] = octetUnion_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_octetUnion); - - MinimalStructMember mst_int8Union; - mst_int8Union.common().member_id(memberId++); - mst_int8Union.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_int8Union.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_int8Union.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_int8Union.common().member_flags().IS_OPTIONAL(false); - mst_int8Union.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_int8Union.common().member_flags().IS_KEY(false); - mst_int8Union.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_int8Union.common().member_type_id(*GetInt8UnionIdentifier(false)); - - MD5 int8Union_hash("int8Union"); - for(int i = 0; i < 4; ++i) - { - mst_int8Union.detail().name_hash()[i] = int8Union_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_int8Union); - - MinimalStructMember mst_myStructBits; - mst_myStructBits.common().member_id(memberId++); - mst_myStructBits.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_myStructBits.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_myStructBits.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_myStructBits.common().member_flags().IS_OPTIONAL(false); - mst_myStructBits.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_myStructBits.common().member_flags().IS_KEY(false); - mst_myStructBits.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_myStructBits.common().member_type_id(*bitmodule::GetBM2Identifier(false)); - - MD5 myStructBits_hash("myStructBits"); - for(int i = 0; i < 4; ++i) - { - mst_myStructBits.detail().name_hash()[i] = myStructBits_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_myStructBits); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - type_object->minimal().struct_type().header().base_type(*GetNewAliasesIdentifier(false)); - - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("StructTest", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("StructTest", false); -} - -const TypeObject* GetCompleteStructTestObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("StructTest", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_octetUnion; - cst_octetUnion.common().member_id(memberId++); - cst_octetUnion.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_octetUnion.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_octetUnion.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_octetUnion.common().member_flags().IS_OPTIONAL(false); - cst_octetUnion.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_octetUnion.common().member_flags().IS_KEY(false); - cst_octetUnion.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_octetUnion.common().member_type_id(*GetOctetUnionIdentifier(true)); - - cst_octetUnion.detail().name("octetUnion"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_octetUnion); - - CompleteStructMember cst_int8Union; - cst_int8Union.common().member_id(memberId++); - cst_int8Union.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_int8Union.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_int8Union.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_int8Union.common().member_flags().IS_OPTIONAL(false); - cst_int8Union.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_int8Union.common().member_flags().IS_KEY(false); - cst_int8Union.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_int8Union.common().member_type_id(*GetInt8UnionIdentifier(true)); - - cst_int8Union.detail().name("int8Union"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_int8Union); - - CompleteStructMember cst_myStructBits; - cst_myStructBits.common().member_id(memberId++); - cst_myStructBits.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_myStructBits.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_myStructBits.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_myStructBits.common().member_flags().IS_OPTIONAL(false); - cst_myStructBits.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_myStructBits.common().member_flags().IS_KEY(false); - cst_myStructBits.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_myStructBits.common().member_type_id(*bitmodule::GetBM2Identifier(true)); - - cst_myStructBits.detail().name("myStructBits"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_myStructBits); - - - // Header - type_object->complete().struct_type().header().detail().type_name("StructTest"); - // TODO inheritance - type_object->complete().struct_type().header().base_type(*GetNewAliasesIdentifier(true)); - - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("StructTest", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("StructTest", true); -} diff --git a/test/unittest/dynamic_types/idl/new_features_4_2TypeObject.h b/test/unittest/dynamic_types/idl/new_features_4_2TypeObject.h deleted file mode 100644 index 55337a6942d..00000000000 --- a/test/unittest/dynamic_types/idl/new_features_4_2TypeObject.h +++ /dev/null @@ -1,124 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file new_features_4_2TypeObject.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifndef _FAST_DDS_GENERATED_NEW_FEATURES_4_2_TYPE_OBJECT_H_ -#define _FAST_DDS_GENERATED_NEW_FEATURES_4_2_TYPE_OBJECT_H_ - - -#include -#include - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif -#else -#define eProsima_user_DllExport -#endif - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(new_features_4_2_SOURCE) -#define new_features_4_2_DllAPI __declspec( dllexport ) -#else -#define new_features_4_2_DllAPI __declspec( dllimport ) -#endif // new_features_4_2_SOURCE -#else -#define new_features_4_2_DllAPI -#endif -#else -#define new_features_4_2_DllAPI -#endif // _WIN32 - -using namespace eprosima::fastrtps::types; - -eProsima_user_DllExport void registernew_features_4_2Types(); - - - -eProsima_user_DllExport const TypeIdentifier* GetNewAliasesIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetNewAliasesObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalNewAliasesObject(); -eProsima_user_DllExport const TypeObject* GetCompleteNewAliasesObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetWCharUnionIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetWCharUnionObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalWCharUnionObject(); -eProsima_user_DllExport const TypeObject* GetCompleteWCharUnionObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetOctetUnionIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetOctetUnionObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalOctetUnionObject(); -eProsima_user_DllExport const TypeObject* GetCompleteOctetUnionObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetInt8UnionIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetInt8UnionObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalInt8UnionObject(); -eProsima_user_DllExport const TypeObject* GetCompleteInt8UnionObject(); - -namespace bitmodule { - eProsima_user_DllExport const TypeIdentifier* GetParentBitsetIdentifier(bool complete = false); - eProsima_user_DllExport const TypeObject* GetParentBitsetObject(bool complete = false); - eProsima_user_DllExport const TypeObject* GetMinimalParentBitsetObject(); - eProsima_user_DllExport const TypeObject* GetCompleteParentBitsetObject(); - - eProsima_user_DllExport const TypeIdentifier* GetMyBitsetIdentifier(bool complete = false); - eProsima_user_DllExport const TypeObject* GetMyBitsetObject(bool complete = false); - eProsima_user_DllExport const TypeObject* GetMinimalMyBitsetObject(); - eProsima_user_DllExport const TypeObject* GetCompleteMyBitsetObject(); - - eProsima_user_DllExport const TypeIdentifier* GetMyBitMaskIdentifier(bool complete = false); - eProsima_user_DllExport const TypeObject* GetMyBitMaskObject(bool complete = false); - eProsima_user_DllExport const TypeObject* GetMinimalMyBitMaskObject(); - eProsima_user_DllExport const TypeObject* GetCompleteMyBitMaskObject(); - - - - eProsima_user_DllExport const TypeIdentifier* GetBitsetBitmaskIdentifier(bool complete = false); - eProsima_user_DllExport const TypeObject* GetBitsetBitmaskObject(bool complete = false); - eProsima_user_DllExport const TypeObject* GetMinimalBitsetBitmaskObject(); - eProsima_user_DllExport const TypeObject* GetCompleteBitsetBitmaskObject(); - - - - eProsima_user_DllExport const TypeIdentifier* GetBM2Identifier(bool complete = false); - eProsima_user_DllExport const TypeObject* GetBM2Object(bool complete = false); - eProsima_user_DllExport const TypeObject* GetMinimalBM2Object(); - eProsima_user_DllExport const TypeObject* GetCompleteBM2Object(); - -} // namespace bitmodule - - -eProsima_user_DllExport const TypeIdentifier* GetStructTestIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetStructTestObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalStructTestObject(); -eProsima_user_DllExport const TypeObject* GetCompleteStructTestObject(); - - -#endif // _FAST_DDS_GENERATED_NEW_FEATURES_4_2_TYPE_OBJECT_H_ \ No newline at end of file diff --git a/test/unittest/dynamic_types/idl/new_features_4_2v1.cxx b/test/unittest/dynamic_types/idl/new_features_4_2v1.cxx deleted file mode 100644 index 4287df4cf97..00000000000 --- a/test/unittest/dynamic_types/idl/new_features_4_2v1.cxx +++ /dev/null @@ -1,2905 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file new_features_4_2.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "new_features_4_2.h" - -#if FASTCDR_VERSION_MAJOR == 1 - -#include "new_features_4_2TypeObject.h" - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - -namespace helper { namespace internal { - -enum class Size { - UInt8, - UInt16, - UInt32, - UInt64, -}; - -constexpr Size get_size(int s) { - return (s <= 8 ) ? Size::UInt8: - (s <= 16) ? Size::UInt16: - (s <= 32) ? Size::UInt32: Size::UInt64; -} - -template -struct FindTypeH; - -template<> -struct FindTypeH { - using type = std::uint8_t; -}; - -template<> -struct FindTypeH { - using type = std::uint16_t; -}; - -template<> -struct FindTypeH { - using type = std::uint32_t; -}; - -template<> -struct FindTypeH { - using type = std::uint64_t; -}; -} - -template -struct FindType { - using type = typename internal::FindTypeH::type; -}; -} - -#define bitmodule_BM2_max_cdr_typesize 24ULL; -#define NewAliases_max_cdr_typesize 40ULL; - -#define StructTest_max_cdr_typesize 88ULL; - - - -#define bitmodule_BitsetBitmask_max_cdr_typesize 17ULL; - - - - -NewAliases::NewAliases() -{ - // int8 m_int8_ - m_int8_ = 0; - // uint8 m_uint8_ - m_uint8_ = 0; - // short m_int16_ - m_int16_ = 0; - // unsigned short m_uint16_ - m_uint16_ = 0; - // long m_int32_ - m_int32_ = 0; - // unsigned long m_uint32_ - m_uint32_ = 0; - // long long m_int64_ - m_int64_ = 0; - // unsigned long long m_uint64_ - m_uint64_ = 555; - // /type_d() m_local_string - - - // Just to register all known types - registernew_features_4_2Types(); -} - -NewAliases::~NewAliases() -{ -} - -NewAliases::NewAliases( - const NewAliases& x) -{ - m_int8_ = x.m_int8_; - - - m_uint8_ = x.m_uint8_; - - - m_int16_ = x.m_int16_; - - - m_uint16_ = x.m_uint16_; - - - m_int32_ = x.m_int32_; - - - m_uint32_ = x.m_uint32_; - - - m_int64_ = x.m_int64_; - - - m_uint64_ = x.m_uint64_; - - - m_local_string = x.m_local_string; - -} - -NewAliases::NewAliases( - NewAliases&& x) noexcept -{ - m_int8_ = x.m_int8_; - - - m_uint8_ = x.m_uint8_; - - - m_int16_ = x.m_int16_; - - - m_uint16_ = x.m_uint16_; - - - m_int32_ = x.m_int32_; - - - m_uint32_ = x.m_uint32_; - - - m_int64_ = x.m_int64_; - - - m_uint64_ = x.m_uint64_; - - - m_local_string = std::move(x.m_local_string); - -} - -NewAliases& NewAliases::operator =( - const NewAliases& x) -{ - m_int8_ = x.m_int8_; - - - m_uint8_ = x.m_uint8_; - - - m_int16_ = x.m_int16_; - - - m_uint16_ = x.m_uint16_; - - - m_int32_ = x.m_int32_; - - - m_uint32_ = x.m_uint32_; - - - m_int64_ = x.m_int64_; - - - m_uint64_ = x.m_uint64_; - - - m_local_string = x.m_local_string; - - return *this; -} - -NewAliases& NewAliases::operator =( - NewAliases&& x) noexcept -{ - m_int8_ = x.m_int8_; - - - m_uint8_ = x.m_uint8_; - - - m_int16_ = x.m_int16_; - - - m_uint16_ = x.m_uint16_; - - - m_int32_ = x.m_int32_; - - - m_uint32_ = x.m_uint32_; - - - m_int64_ = x.m_int64_; - - - m_uint64_ = x.m_uint64_; - - - m_local_string = std::move(x.m_local_string); - - return *this; -} - -bool NewAliases::operator ==( - const NewAliases& x) const -{ - return (m_int8_ == x.m_int8_ && - m_uint8_ == x.m_uint8_ && - m_int16_ == x.m_int16_ && - m_uint16_ == x.m_uint16_ && - m_int32_ == x.m_int32_ && - m_uint32_ == x.m_uint32_ && - m_int64_ == x.m_int64_ && - m_uint64_ == x.m_uint64_ && - m_local_string == x.m_local_string); -} - -bool NewAliases::operator !=( - const NewAliases& x) const -{ - return !(*this == x); -} - -size_t NewAliases::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return NewAliases_max_cdr_typesize; -} - -size_t NewAliases::getCdrSerializedSize( - const NewAliases& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - current_alignment += 2 + eprosima::fastcdr::Cdr::alignment(current_alignment, 2); - - - current_alignment += 2 + eprosima::fastcdr::Cdr::alignment(current_alignment, 2); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += 8 + eprosima::fastcdr::Cdr::alignment(current_alignment, 8); - - - current_alignment += 8 + eprosima::fastcdr::Cdr::alignment(current_alignment, 8); - - - - return current_alignment - initial_alignment; -} - - -void NewAliases::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_int8_; - - scdr << m_uint8_; - - scdr << m_int16_; - - scdr << m_uint16_; - - scdr << m_int32_; - - scdr << m_uint32_; - - scdr << m_int64_; - - scdr << m_uint64_; - -} - -void NewAliases::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_int8_; - - - - dcdr >> m_uint8_; - - - - dcdr >> m_int16_; - - - - dcdr >> m_uint16_; - - - - dcdr >> m_int32_; - - - - dcdr >> m_uint32_; - - - - dcdr >> m_int64_; - - - - dcdr >> m_uint64_; - - - -} - - -bool NewAliases::isKeyDefined() -{ - return false; -} - -void NewAliases::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member int8_ - * @param _int8_ New value for member int8_ - */ -void NewAliases::int8_( - int8_t _int8_) -{ - m_int8_ = _int8_; -} - -/*! - * @brief This function returns the value of member int8_ - * @return Value of member int8_ - */ -int8_t NewAliases::int8_() const -{ - return m_int8_; -} - -/*! - * @brief This function returns a reference to member int8_ - * @return Reference to member int8_ - */ -int8_t& NewAliases::int8_() -{ - return m_int8_; -} - - -/*! - * @brief This function sets a value in member uint8_ - * @param _uint8_ New value for member uint8_ - */ -void NewAliases::uint8_( - uint8_t _uint8_) -{ - m_uint8_ = _uint8_; -} - -/*! - * @brief This function returns the value of member uint8_ - * @return Value of member uint8_ - */ -uint8_t NewAliases::uint8_() const -{ - return m_uint8_; -} - -/*! - * @brief This function returns a reference to member uint8_ - * @return Reference to member uint8_ - */ -uint8_t& NewAliases::uint8_() -{ - return m_uint8_; -} - - -/*! - * @brief This function sets a value in member int16_ - * @param _int16_ New value for member int16_ - */ -void NewAliases::int16_( - int16_t _int16_) -{ - m_int16_ = _int16_; -} - -/*! - * @brief This function returns the value of member int16_ - * @return Value of member int16_ - */ -int16_t NewAliases::int16_() const -{ - return m_int16_; -} - -/*! - * @brief This function returns a reference to member int16_ - * @return Reference to member int16_ - */ -int16_t& NewAliases::int16_() -{ - return m_int16_; -} - - -/*! - * @brief This function sets a value in member uint16_ - * @param _uint16_ New value for member uint16_ - */ -void NewAliases::uint16_( - uint16_t _uint16_) -{ - m_uint16_ = _uint16_; -} - -/*! - * @brief This function returns the value of member uint16_ - * @return Value of member uint16_ - */ -uint16_t NewAliases::uint16_() const -{ - return m_uint16_; -} - -/*! - * @brief This function returns a reference to member uint16_ - * @return Reference to member uint16_ - */ -uint16_t& NewAliases::uint16_() -{ - return m_uint16_; -} - - -/*! - * @brief This function sets a value in member int32_ - * @param _int32_ New value for member int32_ - */ -void NewAliases::int32_( - int32_t _int32_) -{ - m_int32_ = _int32_; -} - -/*! - * @brief This function returns the value of member int32_ - * @return Value of member int32_ - */ -int32_t NewAliases::int32_() const -{ - return m_int32_; -} - -/*! - * @brief This function returns a reference to member int32_ - * @return Reference to member int32_ - */ -int32_t& NewAliases::int32_() -{ - return m_int32_; -} - - -/*! - * @brief This function sets a value in member uint32_ - * @param _uint32_ New value for member uint32_ - */ -void NewAliases::uint32_( - uint32_t _uint32_) -{ - m_uint32_ = _uint32_; -} - -/*! - * @brief This function returns the value of member uint32_ - * @return Value of member uint32_ - */ -uint32_t NewAliases::uint32_() const -{ - return m_uint32_; -} - -/*! - * @brief This function returns a reference to member uint32_ - * @return Reference to member uint32_ - */ -uint32_t& NewAliases::uint32_() -{ - return m_uint32_; -} - - -/*! - * @brief This function sets a value in member int64_ - * @param _int64_ New value for member int64_ - */ -void NewAliases::int64_( - int64_t _int64_) -{ - m_int64_ = _int64_; -} - -/*! - * @brief This function returns the value of member int64_ - * @return Value of member int64_ - */ -int64_t NewAliases::int64_() const -{ - return m_int64_; -} - -/*! - * @brief This function returns a reference to member int64_ - * @return Reference to member int64_ - */ -int64_t& NewAliases::int64_() -{ - return m_int64_; -} - - -/*! - * @brief This function sets a value in member uint64_ - * @param _uint64_ New value for member uint64_ - */ -void NewAliases::uint64_( - uint64_t _uint64_) -{ - m_uint64_ = _uint64_; -} - -/*! - * @brief This function returns the value of member uint64_ - * @return Value of member uint64_ - */ -uint64_t NewAliases::uint64_() const -{ - return m_uint64_; -} - -/*! - * @brief This function returns a reference to member uint64_ - * @return Reference to member uint64_ - */ -uint64_t& NewAliases::uint64_() -{ - return m_uint64_; -} - - -/*! - * @brief This function copies the value in member local_string - * @param _local_string New value to be copied in member local_string - */ -void NewAliases::local_string( - const std::string& _local_string) -{ - m_local_string = _local_string; -} - -/*! - * @brief This function moves the value in member local_string - * @param _local_string New value to be moved in member local_string - */ -void NewAliases::local_string( - std::string&& _local_string) -{ - m_local_string = std::move(_local_string); -} - -/*! - * @brief This function returns a constant reference to member local_string - * @return Constant reference to member local_string - */ -const std::string& NewAliases::local_string() const -{ - return m_local_string; -} - -/*! - * @brief This function returns a reference to member local_string - * @return Reference to member local_string - */ -std::string& NewAliases::local_string() -{ - return m_local_string; -} - - - - - -WCharUnion::WCharUnion() -{ - m__d = 'a'; - // long m_case_zero - m_case_zero = 0; - // long m_case_one - m_case_one = 0; -} - -WCharUnion::~WCharUnion() -{ -} - -WCharUnion::WCharUnion( - const WCharUnion& x) -{ - m__d = x.m__d; - - switch(m__d) - { - case 'a': - m_case_zero = x.m_case_zero; - break; - - - case 'b': - m_case_one = x.m_case_one; - break; - - default: - break; - } -} - -WCharUnion::WCharUnion( - WCharUnion&& x) noexcept -{ - m__d = x.m__d; - - switch(m__d) - { - case 'a': - m_case_zero = x.m_case_zero; - break; - - - case 'b': - m_case_one = x.m_case_one; - break; - - default: - break; - } -} - -WCharUnion& WCharUnion::operator =( - const WCharUnion& x) -{ - m__d = x.m__d; - - switch(m__d) - { - case 'a': - m_case_zero = x.m_case_zero; - break; - - - case 'b': - m_case_one = x.m_case_one; - break; - - default: - break; - } - - return *this; -} - -WCharUnion& WCharUnion::operator =( - WCharUnion&& x) noexcept -{ - m__d = x.m__d; - - switch(m__d) - { - case 'a': - m_case_zero = x.m_case_zero; - break; - - - case 'b': - m_case_one = x.m_case_one; - break; - - default: - break; - } - - return *this; -} - -bool WCharUnion::operator ==( - const WCharUnion& x) const -{ - if (m__d != x.m__d) - { - return false; - } - - switch(m__d) - { - case 'a': - return (m_case_zero == x.m_case_zero); - break; - - - case 'b': - return (m_case_one == x.m_case_one); - break; - - default: - break; - } - return false; -} - -bool WCharUnion::operator !=( - const WCharUnion& x) const -{ - return !(*this == x); -} - -void WCharUnion::_d( - wchar_t __d) -{ - bool b = false; - - switch(m__d) - { - case 'a': - switch(__d) - { - case 'a': - b = true; - break; - default: - break; - } - break; - - - case 'b': - switch(__d) - { - case 'b': - b = true; - break; - default: - break; - } - break; - - } - - if(!b) - { - throw BadParamException("Discriminator doesn't correspond with the selected union member"); - } - - m__d = __d; -} - -wchar_t WCharUnion::_d() const -{ - return m__d; -} - -wchar_t& WCharUnion::_d() -{ - return m__d; -} - -void WCharUnion::case_zero( - int32_t _case_zero) -{ - m_case_zero = _case_zero; - m__d = 'a'; - -} - -int32_t WCharUnion::case_zero() const -{ - bool b = false; - - switch(m__d) - { - case 'a': - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_case_zero; -} - -int32_t& WCharUnion::case_zero() -{ - bool b = false; - - switch(m__d) - { - case 'a': - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_case_zero; -} - - -void WCharUnion::case_one( - int32_t _case_one) -{ - m_case_one = _case_one; - m__d = 'b'; - -} - -int32_t WCharUnion::case_one() const -{ - bool b = false; - - switch(m__d) - { - case 'b': - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_case_one; -} - -int32_t& WCharUnion::case_one() -{ - bool b = false; - - switch(m__d) - { - case 'b': - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_case_one; -} - - -// TODO(Ricardo) Review -size_t WCharUnion::getCdrSerializedSize( - const WCharUnion& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - - switch(data.m__d) - { - case 'a': - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - break; - - - case 'b': - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - break; - - default: - break; - } - - return current_alignment - initial_alignment; -} - - -void WCharUnion::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m__d; - - switch(m__d) - { - case 'a': - scdr << m_case_zero; - - break; - - - case 'b': - scdr << m_case_one; - - break; - - default: - break; - } -} - -void WCharUnion::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m__d; - - - switch(m__d) - { - case 'a': - dcdr >> m_case_zero; - - - break; - - - case 'b': - dcdr >> m_case_one; - - - break; - - default: - break; - } -} - - - - - -OctetUnion::OctetUnion() -{ - m__d = 5; - // long m_case_five - m_case_five = 0; - // long m_case_seven - m_case_seven = 0; -} - -OctetUnion::~OctetUnion() -{ -} - -OctetUnion::OctetUnion( - const OctetUnion& x) -{ - m__d = x.m__d; - - switch(m__d) - { - case 5: - m_case_five = x.m_case_five; - break; - - - case 7: - m_case_seven = x.m_case_seven; - break; - - default: - break; - } -} - -OctetUnion::OctetUnion( - OctetUnion&& x) noexcept -{ - m__d = x.m__d; - - switch(m__d) - { - case 5: - m_case_five = x.m_case_five; - break; - - - case 7: - m_case_seven = x.m_case_seven; - break; - - default: - break; - } -} - -OctetUnion& OctetUnion::operator =( - const OctetUnion& x) -{ - m__d = x.m__d; - - switch(m__d) - { - case 5: - m_case_five = x.m_case_five; - break; - - - case 7: - m_case_seven = x.m_case_seven; - break; - - default: - break; - } - - return *this; -} - -OctetUnion& OctetUnion::operator =( - OctetUnion&& x) noexcept -{ - m__d = x.m__d; - - switch(m__d) - { - case 5: - m_case_five = x.m_case_five; - break; - - - case 7: - m_case_seven = x.m_case_seven; - break; - - default: - break; - } - - return *this; -} - -bool OctetUnion::operator ==( - const OctetUnion& x) const -{ - if (m__d != x.m__d) - { - return false; - } - - switch(m__d) - { - case 5: - return (m_case_five == x.m_case_five); - break; - - - case 7: - return (m_case_seven == x.m_case_seven); - break; - - default: - break; - } - return false; -} - -bool OctetUnion::operator !=( - const OctetUnion& x) const -{ - return !(*this == x); -} - -void OctetUnion::_d( - uint8_t __d) -{ - bool b = false; - - switch(m__d) - { - case 5: - switch(__d) - { - case 5: - b = true; - break; - default: - break; - } - break; - - - case 7: - switch(__d) - { - case 7: - b = true; - break; - default: - break; - } - break; - - } - - if(!b) - { - throw BadParamException("Discriminator doesn't correspond with the selected union member"); - } - - m__d = __d; -} - -uint8_t OctetUnion::_d() const -{ - return m__d; -} - -uint8_t& OctetUnion::_d() -{ - return m__d; -} - -void OctetUnion::case_five( - int32_t _case_five) -{ - m_case_five = _case_five; - m__d = 5; - -} - -int32_t OctetUnion::case_five() const -{ - bool b = false; - - switch(m__d) - { - case 5: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_case_five; -} - -int32_t& OctetUnion::case_five() -{ - bool b = false; - - switch(m__d) - { - case 5: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_case_five; -} - - -void OctetUnion::case_seven( - int32_t _case_seven) -{ - m_case_seven = _case_seven; - m__d = 7; - -} - -int32_t OctetUnion::case_seven() const -{ - bool b = false; - - switch(m__d) - { - case 7: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_case_seven; -} - -int32_t& OctetUnion::case_seven() -{ - bool b = false; - - switch(m__d) - { - case 7: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_case_seven; -} - - -// TODO(Ricardo) Review -size_t OctetUnion::getCdrSerializedSize( - const OctetUnion& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - - switch(data.m__d) - { - case 5: - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - break; - - - case 7: - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - break; - - default: - break; - } - - return current_alignment - initial_alignment; -} - - -void OctetUnion::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m__d; - - switch(m__d) - { - case 5: - scdr << m_case_five; - - break; - - - case 7: - scdr << m_case_seven; - - break; - - default: - break; - } -} - -void OctetUnion::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m__d; - - - switch(m__d) - { - case 5: - dcdr >> m_case_five; - - - break; - - - case 7: - dcdr >> m_case_seven; - - - break; - - default: - break; - } -} - - - - - -Int8Union::Int8Union() -{ - m__d = 3; - // long m_case_three - m_case_three = 0; - // long m_case_six - m_case_six = 0; -} - -Int8Union::~Int8Union() -{ -} - -Int8Union::Int8Union( - const Int8Union& x) -{ - m__d = x.m__d; - - switch(m__d) - { - case 3: - m_case_three = x.m_case_three; - break; - - - case 6: - m_case_six = x.m_case_six; - break; - - default: - break; - } -} - -Int8Union::Int8Union( - Int8Union&& x) noexcept -{ - m__d = x.m__d; - - switch(m__d) - { - case 3: - m_case_three = x.m_case_three; - break; - - - case 6: - m_case_six = x.m_case_six; - break; - - default: - break; - } -} - -Int8Union& Int8Union::operator =( - const Int8Union& x) -{ - m__d = x.m__d; - - switch(m__d) - { - case 3: - m_case_three = x.m_case_three; - break; - - - case 6: - m_case_six = x.m_case_six; - break; - - default: - break; - } - - return *this; -} - -Int8Union& Int8Union::operator =( - Int8Union&& x) noexcept -{ - m__d = x.m__d; - - switch(m__d) - { - case 3: - m_case_three = x.m_case_three; - break; - - - case 6: - m_case_six = x.m_case_six; - break; - - default: - break; - } - - return *this; -} - -bool Int8Union::operator ==( - const Int8Union& x) const -{ - if (m__d != x.m__d) - { - return false; - } - - switch(m__d) - { - case 3: - return (m_case_three == x.m_case_three); - break; - - - case 6: - return (m_case_six == x.m_case_six); - break; - - default: - break; - } - return false; -} - -bool Int8Union::operator !=( - const Int8Union& x) const -{ - return !(*this == x); -} - -void Int8Union::_d( - int8_t __d) -{ - bool b = false; - - switch(m__d) - { - case 3: - switch(__d) - { - case 3: - b = true; - break; - default: - break; - } - break; - - - case 6: - switch(__d) - { - case 6: - b = true; - break; - default: - break; - } - break; - - } - - if(!b) - { - throw BadParamException("Discriminator doesn't correspond with the selected union member"); - } - - m__d = __d; -} - -int8_t Int8Union::_d() const -{ - return m__d; -} - -int8_t& Int8Union::_d() -{ - return m__d; -} - -void Int8Union::case_three( - int32_t _case_three) -{ - m_case_three = _case_three; - m__d = 3; - -} - -int32_t Int8Union::case_three() const -{ - bool b = false; - - switch(m__d) - { - case 3: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_case_three; -} - -int32_t& Int8Union::case_three() -{ - bool b = false; - - switch(m__d) - { - case 3: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_case_three; -} - - -void Int8Union::case_six( - int32_t _case_six) -{ - m_case_six = _case_six; - m__d = 6; - -} - -int32_t Int8Union::case_six() const -{ - bool b = false; - - switch(m__d) - { - case 6: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_case_six; -} - -int32_t& Int8Union::case_six() -{ - bool b = false; - - switch(m__d) - { - case 6: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_case_six; -} - - -// TODO(Ricardo) Review -size_t Int8Union::getCdrSerializedSize( - const Int8Union& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - - switch(data.m__d) - { - case 3: - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - break; - - - case 6: - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - break; - - default: - break; - } - - return current_alignment - initial_alignment; -} - - -void Int8Union::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m__d; - - switch(m__d) - { - case 3: - scdr << m_case_three; - - break; - - - case 6: - scdr << m_case_six; - - break; - - default: - break; - } -} - -void Int8Union::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m__d; - - - switch(m__d) - { - case 3: - dcdr >> m_case_three; - - - break; - - - case 6: - dcdr >> m_case_six; - - - break; - - default: - break; - } -} - - - -namespace bitmodule { - -ParentBitset::ParentBitset() -{ - // Just to register all known types - registernew_features_4_2Types(); -} - -ParentBitset::~ParentBitset() -{ -} - -ParentBitset::ParentBitset( - const ParentBitset& x) -{ - m_bitset = x.m_bitset; -} - -ParentBitset::ParentBitset( - ParentBitset&& x) noexcept -{ - m_bitset = x.m_bitset; -} - -ParentBitset& ParentBitset::operator =( - const ParentBitset& x) -{ - m_bitset = x.m_bitset; - - return *this; -} - -ParentBitset& ParentBitset::operator =( - ParentBitset&& x) noexcept -{ - m_bitset = x.m_bitset; - - return *this; -} - -bool ParentBitset::operator ==( - const ParentBitset& x) const -{ - return m_bitset == x.m_bitset; -} - -bool ParentBitset::operator !=( - const ParentBitset& x) const -{ - return !(*this == x); -} - -size_t ParentBitset::getCdrSerializedSize( - const ParentBitset&, - size_t current_alignment) -{ - size_t initial_alignment = current_alignment; - - current_alignment += sizeof(helper::FindType<17>::type) + - eprosima::fastcdr::Cdr::alignment(current_alignment, sizeof(helper::FindType<17>::type)); - - return current_alignment - initial_alignment; -} - - -void ParentBitset::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - using namespace bitmodule; - - helper::FindType<17>::type bits = static_cast::type>(bitset().to_ullong()); - scdr << bits; -} - -void ParentBitset::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - using namespace bitmodule; - - helper::FindType<17>::type bits; - dcdr >> bits; - bitset(std::bitset<17>(bits)); -} - - - -void bitmodule::ParentBitset::parent_bitfield( - uint32_t _parent_bitfield) -{ - int base = 0; - int size = 17; - for (int i = base; i < base + size; ++i) - { - m_bitset.set(i, !!(_parent_bitfield & 0x01)); - _parent_bitfield = _parent_bitfield >> 1; - } - -} - -uint32_t bitmodule::ParentBitset::parent_bitfield() const -{ - int base = 0; - int size = 17; - std::bitset<17> aux; - for (int i = 0; i < size; ++i) - { - aux.set(i, m_bitset.test(i + base)); - } - return static_cast(aux.to_ullong()); - -} - - -std::bitset<17> ParentBitset::bitset() const -{ - std::string str_value; - - str_value = m_bitset.to_string() + str_value; - - return std::bitset<17>(str_value); -} - -void ParentBitset::bitset( - const std::bitset<17>& bitset) -{ - std::string str_value {bitset.to_string()}; - size_t base_diff {0}; - size_t last_post {std::string::npos}; - - base_diff += 17; - m_bitset = std::bitset<17>(str_value.substr(str_value.length() - base_diff, last_post)); -} - -MyBitset::MyBitset() - : bitmodule::ParentBitset() -{ - // Just to register all known types - registernew_features_4_2Types(); -} - -MyBitset::~MyBitset() -{ -} - -MyBitset::MyBitset( - const MyBitset& x) - : bitmodule::ParentBitset(x) -{ - m_bitset = x.m_bitset; -} - -MyBitset::MyBitset( - MyBitset&& x) noexcept - : bitmodule::ParentBitset(std::move(x)) -{ - m_bitset = x.m_bitset; -} - -MyBitset& MyBitset::operator =( - const MyBitset& x) -{ - bitmodule::ParentBitset::operator =(x); - - m_bitset = x.m_bitset; - - return *this; -} - -MyBitset& MyBitset::operator =( - MyBitset&& x) noexcept -{ - bitmodule::ParentBitset::operator =(std::move(x)); - - m_bitset = x.m_bitset; - - return *this; -} - -bool MyBitset::operator ==( - const MyBitset& x) const -{ - if (bitmodule::ParentBitset::operator !=(x)) return false; - - return m_bitset == x.m_bitset; -} - -bool MyBitset::operator !=( - const MyBitset& x) const -{ - return !(*this == x); -} - -size_t MyBitset::getCdrSerializedSize( - const MyBitset&, - size_t current_alignment) -{ - size_t initial_alignment = current_alignment; - - current_alignment += sizeof(helper::FindType<50>::type) + - eprosima::fastcdr::Cdr::alignment(current_alignment, sizeof(helper::FindType<50>::type)); - - return current_alignment - initial_alignment; -} - - -void MyBitset::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - using namespace bitmodule; - - helper::FindType<50>::type bits = static_cast::type>(bitset().to_ullong()); - scdr << bits; -} - -void MyBitset::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - using namespace bitmodule; - - helper::FindType<50>::type bits; - dcdr >> bits; - bitset(std::bitset<50>(bits)); -} - - - -void bitmodule::MyBitset::a( - char _a) -{ - int base = 0; - int size = 3; - for (int i = base; i < base + size; ++i) - { - m_bitset.set(i, !!(_a & 0x01)); - _a = _a >> 1; - } - -} - -char bitmodule::MyBitset::a() const -{ - int base = 0; - int size = 3; - std::bitset<3> aux; - for (int i = 0; i < size; ++i) - { - aux.set(i, m_bitset.test(i + base)); - } - return static_cast(aux.to_ullong()); - -} - - -void bitmodule::MyBitset::b( - bool _b) -{ - int base = 3; - m_bitset.set(base, _b); -} - -bool bitmodule::MyBitset::b() const -{ - int base = 3; - return m_bitset.test(base); -} - - - -void bitmodule::MyBitset::c( - uint16_t _c) -{ - int base = 8; - int size = 10; - for (int i = base; i < base + size; ++i) - { - m_bitset.set(i, !!(_c & 0x01)); - _c = _c >> 1; - } - -} - -uint16_t bitmodule::MyBitset::c() const -{ - int base = 8; - int size = 10; - std::bitset<10> aux; - for (int i = 0; i < size; ++i) - { - aux.set(i, m_bitset.test(i + base)); - } - return static_cast(aux.to_ullong()); - -} - - -void bitmodule::MyBitset::d( - int16_t _d) -{ - int base = 18; - int size = 5; - for (int i = base; i < base + size; ++i) - { - m_bitset.set(i, !!(_d & 0x01)); - _d = _d >> 1; - } - -} - -int16_t bitmodule::MyBitset::d() const -{ - int base = 18; - int size = 5; - std::bitset<5> aux; - for (int i = 0; i < size; ++i) - { - aux.set(i, m_bitset.test(i + base)); - } - return static_cast(aux.to_ullong()); - -} - - -void bitmodule::MyBitset::e( - int16_t _e) -{ - int base = 23; - int size = 5; - for (int i = base; i < base + size; ++i) - { - m_bitset.set(i, !!(_e & 0x01)); - _e = _e >> 1; - } - -} - -int16_t bitmodule::MyBitset::e() const -{ - int base = 23; - int size = 5; - std::bitset<5> aux; - for (int i = 0; i < size; ++i) - { - aux.set(i, m_bitset.test(i + base)); - } - return static_cast(aux.to_ullong()); - -} - - -void bitmodule::MyBitset::f( - int16_t _f) -{ - int base = 28; - int size = 5; - for (int i = base; i < base + size; ++i) - { - m_bitset.set(i, !!(_f & 0x01)); - _f = _f >> 1; - } - -} - -int16_t bitmodule::MyBitset::f() const -{ - int base = 28; - int size = 5; - std::bitset<5> aux; - for (int i = 0; i < size; ++i) - { - aux.set(i, m_bitset.test(i + base)); - } - return static_cast(aux.to_ullong()); - -} - - -std::bitset<50> MyBitset::bitset() const -{ - std::string str_value; - - str_value = static_cast(this)->bitset().to_string() + str_value; - - str_value = m_bitset.to_string() + str_value; - - return std::bitset<50>(str_value); -} - -void MyBitset::bitset( - const std::bitset<50>& bitset) -{ - std::string str_value {bitset.to_string()}; - size_t base_diff {0}; - size_t last_post {std::string::npos}; - - { - base_diff += 17; - std::bitset<17> internal_bitset(str_value.substr(str_value.length() - base_diff, last_post)); - static_cast(this)->bitset(internal_bitset); - last_post = base_diff; - } - - base_diff += 33; - m_bitset = std::bitset<33>(str_value.substr(str_value.length() - base_diff, last_post)); -} - - - - -BitsetBitmask::BitsetBitmask() -{ - // bitmodule::MyBitset m_mybitset - - // bitmodule::MyBitMask m_mybitmask - - - // Just to register all known types - registernew_features_4_2Types(); -} - -BitsetBitmask::~BitsetBitmask() -{ -} - -BitsetBitmask::BitsetBitmask( - const BitsetBitmask& x) -{ - m_mybitset = x.m_mybitset; - - - m_mybitmask = x.m_mybitmask; - -} - -BitsetBitmask::BitsetBitmask( - BitsetBitmask&& x) noexcept -{ - m_mybitset = std::move(x.m_mybitset); - - - m_mybitmask = std::move(x.m_mybitmask); - -} - -BitsetBitmask& BitsetBitmask::operator =( - const BitsetBitmask& x) -{ - m_mybitset = x.m_mybitset; - - - m_mybitmask = x.m_mybitmask; - - return *this; -} - -BitsetBitmask& BitsetBitmask::operator =( - BitsetBitmask&& x) noexcept -{ - m_mybitset = std::move(x.m_mybitset); - - - m_mybitmask = std::move(x.m_mybitmask); - - return *this; -} - -bool BitsetBitmask::operator ==( - const BitsetBitmask& x) const -{ - return (m_mybitset == x.m_mybitset && - m_mybitmask == x.m_mybitmask); -} - -bool BitsetBitmask::operator !=( - const BitsetBitmask& x) const -{ - return !(*this == x); -} - -size_t BitsetBitmask::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return bitmodule_BitsetBitmask_max_cdr_typesize; -} - -size_t BitsetBitmask::getCdrSerializedSize( - const BitsetBitmask& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += bitmodule::MyBitset::getCdrSerializedSize(data.mybitset(), current_alignment); - - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - return current_alignment - initial_alignment; -} - - -void BitsetBitmask::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_mybitset; - - scdr << (uint8_t)m_mybitmask; - -} - -void BitsetBitmask::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_mybitset; - - - - { - uint8_t bitmask_value = 0; - dcdr >> bitmask_value; - m_mybitmask = (bitmodule::MyBitMask)bitmask_value; - } - - - -} - - -bool BitsetBitmask::isKeyDefined() -{ - return false; -} - -void BitsetBitmask::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member mybitset - * @param _mybitset New value to be copied in member mybitset - */ -void BitsetBitmask::mybitset( - const bitmodule::MyBitset& _mybitset) -{ - m_mybitset = _mybitset; -} - -/*! - * @brief This function moves the value in member mybitset - * @param _mybitset New value to be moved in member mybitset - */ -void BitsetBitmask::mybitset( - bitmodule::MyBitset&& _mybitset) -{ - m_mybitset = std::move(_mybitset); -} - -/*! - * @brief This function returns a constant reference to member mybitset - * @return Constant reference to member mybitset - */ -const bitmodule::MyBitset& BitsetBitmask::mybitset() const -{ - return m_mybitset; -} - -/*! - * @brief This function returns a reference to member mybitset - * @return Reference to member mybitset - */ -bitmodule::MyBitset& BitsetBitmask::mybitset() -{ - return m_mybitset; -} - - -/*! - * @brief This function copies the value in member mybitmask - * @param _mybitmask New value to be copied in member mybitmask - */ -void BitsetBitmask::mybitmask( - const bitmodule::MyBitMask& _mybitmask) -{ - m_mybitmask = _mybitmask; -} - -/*! - * @brief This function moves the value in member mybitmask - * @param _mybitmask New value to be moved in member mybitmask - */ -void BitsetBitmask::mybitmask( - bitmodule::MyBitMask&& _mybitmask) -{ - m_mybitmask = std::move(_mybitmask); -} - -/*! - * @brief This function returns a constant reference to member mybitmask - * @return Constant reference to member mybitmask - */ -const bitmodule::MyBitMask& BitsetBitmask::mybitmask() const -{ - return m_mybitmask; -} - -/*! - * @brief This function returns a reference to member mybitmask - * @return Reference to member mybitmask - */ -bitmodule::MyBitMask& BitsetBitmask::mybitmask() -{ - return m_mybitmask; -} - - - - - -BM2::BM2() - : bitmodule::BitsetBitmask() -{ - // bitmodule::MyBitMask m_two - - // long m_mylong - m_mylong = 0; - - // Just to register all known types - registernew_features_4_2Types(); -} - -BM2::~BM2() -{ -} - -BM2::BM2( - const BM2& x) - : bitmodule::BitsetBitmask(x) -{ - m_two = x.m_two; - - - m_mylong = x.m_mylong; - -} - -BM2::BM2( - BM2&& x) noexcept - : bitmodule::BitsetBitmask(std::move(x)) -{ - m_two = std::move(x.m_two); - - - m_mylong = x.m_mylong; - -} - -BM2& BM2::operator =( - const BM2& x) -{ - bitmodule::BitsetBitmask::operator =(x); - - m_two = x.m_two; - - - m_mylong = x.m_mylong; - - return *this; -} - -BM2& BM2::operator =( - BM2&& x) noexcept -{ - bitmodule::BitsetBitmask::operator =(std::move(x)); - - m_two = std::move(x.m_two); - - - m_mylong = x.m_mylong; - - return *this; -} - -bool BM2::operator ==( - const BM2& x) const -{ - if (bitmodule::BitsetBitmask::operator !=(x)) return false; - - return (m_two == x.m_two && - m_mylong == x.m_mylong); -} - -bool BM2::operator !=( - const BM2& x) const -{ - return !(*this == x); -} - -size_t BM2::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return bitmodule_BM2_max_cdr_typesize; -} - -size_t BM2::getCdrSerializedSize( - const BM2& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += bitmodule::BitsetBitmask::getCdrSerializedSize(data, current_alignment); - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - return current_alignment - initial_alignment; -} - - -void BM2::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - bitmodule::BitsetBitmask::serialize(scdr); - - scdr << (uint8_t)m_two; - - scdr << m_mylong; - -} - -void BM2::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - bitmodule::BitsetBitmask::deserialize(dcdr); - - { - uint8_t bitmask_value = 0; - dcdr >> bitmask_value; - m_two = (bitmodule::MyBitMask)bitmask_value; - } - - - - - dcdr >> m_mylong; - - -} - - -bool BM2::isKeyDefined() -{ - if (bitmodule::BitsetBitmask::isKeyDefined()) - return true; - - return false; -} - -void BM2::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; - bitmodule::BitsetBitmask::serializeKey(scdr); -} - -/*! - * @brief This function copies the value in member two - * @param _two New value to be copied in member two - */ -void BM2::two( - const bitmodule::MyBitMask& _two) -{ - m_two = _two; -} - -/*! - * @brief This function moves the value in member two - * @param _two New value to be moved in member two - */ -void BM2::two( - bitmodule::MyBitMask&& _two) -{ - m_two = std::move(_two); -} - -/*! - * @brief This function returns a constant reference to member two - * @return Constant reference to member two - */ -const bitmodule::MyBitMask& BM2::two() const -{ - return m_two; -} - -/*! - * @brief This function returns a reference to member two - * @return Reference to member two - */ -bitmodule::MyBitMask& BM2::two() -{ - return m_two; -} - - -/*! - * @brief This function sets a value in member mylong - * @param _mylong New value for member mylong - */ -void BM2::mylong( - int32_t _mylong) -{ - m_mylong = _mylong; -} - -/*! - * @brief This function returns the value of member mylong - * @return Value of member mylong - */ -int32_t BM2::mylong() const -{ - return m_mylong; -} - -/*! - * @brief This function returns a reference to member mylong - * @return Reference to member mylong - */ -int32_t& BM2::mylong() -{ - return m_mylong; -} - - - - - -} // namespace bitmodule - - -StructTest::StructTest() - : NewAliases() -{ - // OctetUnion m_octetUnion - - // Int8Union m_int8Union - - // bitmodule::BM2 m_myStructBits - - - // Just to register all known types - registernew_features_4_2Types(); -} - -StructTest::~StructTest() -{ -} - -StructTest::StructTest( - const StructTest& x) - : NewAliases(x) -{ - m_octetUnion = x.m_octetUnion; - - - m_int8Union = x.m_int8Union; - - - m_myStructBits = x.m_myStructBits; - -} - -StructTest::StructTest( - StructTest&& x) noexcept - : NewAliases(std::move(x)) -{ - m_octetUnion = std::move(x.m_octetUnion); - - - m_int8Union = std::move(x.m_int8Union); - - - m_myStructBits = std::move(x.m_myStructBits); - -} - -StructTest& StructTest::operator =( - const StructTest& x) -{ - NewAliases::operator =(x); - - m_octetUnion = x.m_octetUnion; - - - m_int8Union = x.m_int8Union; - - - m_myStructBits = x.m_myStructBits; - - return *this; -} - -StructTest& StructTest::operator =( - StructTest&& x) noexcept -{ - NewAliases::operator =(std::move(x)); - - m_octetUnion = std::move(x.m_octetUnion); - - - m_int8Union = std::move(x.m_int8Union); - - - m_myStructBits = std::move(x.m_myStructBits); - - return *this; -} - -bool StructTest::operator ==( - const StructTest& x) const -{ - if (NewAliases::operator !=(x)) return false; - - return (m_octetUnion == x.m_octetUnion && - m_int8Union == x.m_int8Union && - m_myStructBits == x.m_myStructBits); -} - -bool StructTest::operator !=( - const StructTest& x) const -{ - return !(*this == x); -} - -size_t StructTest::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return StructTest_max_cdr_typesize; -} - -size_t StructTest::getCdrSerializedSize( - const StructTest& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += NewAliases::getCdrSerializedSize(data, current_alignment); - - current_alignment += OctetUnion::getCdrSerializedSize(data.octetUnion(), current_alignment); - - - current_alignment += Int8Union::getCdrSerializedSize(data.int8Union(), current_alignment); - - - current_alignment += bitmodule::BM2::getCdrSerializedSize(data.myStructBits(), current_alignment); - - - return current_alignment - initial_alignment; -} - - -void StructTest::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - NewAliases::serialize(scdr); - - scdr << m_octetUnion; - - scdr << m_int8Union; - - scdr << m_myStructBits; - -} - -void StructTest::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - NewAliases::deserialize(dcdr); - - dcdr >> m_octetUnion; - - - - dcdr >> m_int8Union; - - - - dcdr >> m_myStructBits; - - -} - - -bool StructTest::isKeyDefined() -{ - if (NewAliases::isKeyDefined()) - return true; - - return false; -} - -void StructTest::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; - NewAliases::serializeKey(scdr); -} - -/*! - * @brief This function copies the value in member octetUnion - * @param _octetUnion New value to be copied in member octetUnion - */ -void StructTest::octetUnion( - const OctetUnion& _octetUnion) -{ - m_octetUnion = _octetUnion; -} - -/*! - * @brief This function moves the value in member octetUnion - * @param _octetUnion New value to be moved in member octetUnion - */ -void StructTest::octetUnion( - OctetUnion&& _octetUnion) -{ - m_octetUnion = std::move(_octetUnion); -} - -/*! - * @brief This function returns a constant reference to member octetUnion - * @return Constant reference to member octetUnion - */ -const OctetUnion& StructTest::octetUnion() const -{ - return m_octetUnion; -} - -/*! - * @brief This function returns a reference to member octetUnion - * @return Reference to member octetUnion - */ -OctetUnion& StructTest::octetUnion() -{ - return m_octetUnion; -} - - -/*! - * @brief This function copies the value in member int8Union - * @param _int8Union New value to be copied in member int8Union - */ -void StructTest::int8Union( - const Int8Union& _int8Union) -{ - m_int8Union = _int8Union; -} - -/*! - * @brief This function moves the value in member int8Union - * @param _int8Union New value to be moved in member int8Union - */ -void StructTest::int8Union( - Int8Union&& _int8Union) -{ - m_int8Union = std::move(_int8Union); -} - -/*! - * @brief This function returns a constant reference to member int8Union - * @return Constant reference to member int8Union - */ -const Int8Union& StructTest::int8Union() const -{ - return m_int8Union; -} - -/*! - * @brief This function returns a reference to member int8Union - * @return Reference to member int8Union - */ -Int8Union& StructTest::int8Union() -{ - return m_int8Union; -} - - -/*! - * @brief This function copies the value in member myStructBits - * @param _myStructBits New value to be copied in member myStructBits - */ -void StructTest::myStructBits( - const bitmodule::BM2& _myStructBits) -{ - m_myStructBits = _myStructBits; -} - -/*! - * @brief This function moves the value in member myStructBits - * @param _myStructBits New value to be moved in member myStructBits - */ -void StructTest::myStructBits( - bitmodule::BM2&& _myStructBits) -{ - m_myStructBits = std::move(_myStructBits); -} - -/*! - * @brief This function returns a constant reference to member myStructBits - * @return Constant reference to member myStructBits - */ -const bitmodule::BM2& StructTest::myStructBits() const -{ - return m_myStructBits; -} - -/*! - * @brief This function returns a reference to member myStructBits - * @return Reference to member myStructBits - */ -bitmodule::BM2& StructTest::myStructBits() -{ - return m_myStructBits; -} - - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/test/unittest/dynamic_types/idl/new_features_4_2v1.h b/test/unittest/dynamic_types/idl/new_features_4_2v1.h deleted file mode 100644 index d66f6b145e6..00000000000 --- a/test/unittest/dynamic_types/idl/new_features_4_2v1.h +++ /dev/null @@ -1,1738 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file new_features_4_2.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#include - -#if FASTCDR_VERSION_MAJOR == 1 - -#ifndef _FAST_DDS_GENERATED_NEW_FEATURES_4_2_H_ -#define _FAST_DDS_GENERATED_NEW_FEATURES_4_2_H_ - - -#include - -#include -#include -#include -#include -#include -#include -#include - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define eProsima_user_DllExport -#endif // _WIN32 - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(NEW_FEATURES_4_2_SOURCE) -#define NEW_FEATURES_4_2_DllAPI __declspec( dllexport ) -#else -#define NEW_FEATURES_4_2_DllAPI __declspec( dllimport ) -#endif // NEW_FEATURES_4_2_SOURCE -#else -#define NEW_FEATURES_4_2_DllAPI -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define NEW_FEATURES_4_2_DllAPI -#endif // _WIN32 - -namespace eprosima { -namespace fastcdr { -class Cdr; -} // namespace fastcdr -} // namespace eprosima - - - - - -/*! - * @brief This class represents the structure NewAliases defined by the user in the IDL file. - * @ingroup new_features_4_2 - */ -class NewAliases -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport NewAliases(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~NewAliases(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object NewAliases that will be copied. - */ - eProsima_user_DllExport NewAliases( - const NewAliases& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object NewAliases that will be copied. - */ - eProsima_user_DllExport NewAliases( - NewAliases&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object NewAliases that will be copied. - */ - eProsima_user_DllExport NewAliases& operator =( - const NewAliases& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object NewAliases that will be copied. - */ - eProsima_user_DllExport NewAliases& operator =( - NewAliases&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x NewAliases object to compare. - */ - eProsima_user_DllExport bool operator ==( - const NewAliases& x) const; - - /*! - * @brief Comparison operator. - * @param x NewAliases object to compare. - */ - eProsima_user_DllExport bool operator !=( - const NewAliases& x) const; - - /*! - * @brief This function sets a value in member int8_ - * @param _int8_ New value for member int8_ - */ - eProsima_user_DllExport void int8_( - int8_t _int8_); - - /*! - * @brief This function returns the value of member int8_ - * @return Value of member int8_ - */ - eProsima_user_DllExport int8_t int8_() const; - - /*! - * @brief This function returns a reference to member int8_ - * @return Reference to member int8_ - */ - eProsima_user_DllExport int8_t& int8_(); - - - /*! - * @brief This function sets a value in member uint8_ - * @param _uint8_ New value for member uint8_ - */ - eProsima_user_DllExport void uint8_( - uint8_t _uint8_); - - /*! - * @brief This function returns the value of member uint8_ - * @return Value of member uint8_ - */ - eProsima_user_DllExport uint8_t uint8_() const; - - /*! - * @brief This function returns a reference to member uint8_ - * @return Reference to member uint8_ - */ - eProsima_user_DllExport uint8_t& uint8_(); - - - /*! - * @brief This function sets a value in member int16_ - * @param _int16_ New value for member int16_ - */ - eProsima_user_DllExport void int16_( - int16_t _int16_); - - /*! - * @brief This function returns the value of member int16_ - * @return Value of member int16_ - */ - eProsima_user_DllExport int16_t int16_() const; - - /*! - * @brief This function returns a reference to member int16_ - * @return Reference to member int16_ - */ - eProsima_user_DllExport int16_t& int16_(); - - - /*! - * @brief This function sets a value in member uint16_ - * @param _uint16_ New value for member uint16_ - */ - eProsima_user_DllExport void uint16_( - uint16_t _uint16_); - - /*! - * @brief This function returns the value of member uint16_ - * @return Value of member uint16_ - */ - eProsima_user_DllExport uint16_t uint16_() const; - - /*! - * @brief This function returns a reference to member uint16_ - * @return Reference to member uint16_ - */ - eProsima_user_DllExport uint16_t& uint16_(); - - - /*! - * @brief This function sets a value in member int32_ - * @param _int32_ New value for member int32_ - */ - eProsima_user_DllExport void int32_( - int32_t _int32_); - - /*! - * @brief This function returns the value of member int32_ - * @return Value of member int32_ - */ - eProsima_user_DllExport int32_t int32_() const; - - /*! - * @brief This function returns a reference to member int32_ - * @return Reference to member int32_ - */ - eProsima_user_DllExport int32_t& int32_(); - - - /*! - * @brief This function sets a value in member uint32_ - * @param _uint32_ New value for member uint32_ - */ - eProsima_user_DllExport void uint32_( - uint32_t _uint32_); - - /*! - * @brief This function returns the value of member uint32_ - * @return Value of member uint32_ - */ - eProsima_user_DllExport uint32_t uint32_() const; - - /*! - * @brief This function returns a reference to member uint32_ - * @return Reference to member uint32_ - */ - eProsima_user_DllExport uint32_t& uint32_(); - - - /*! - * @brief This function sets a value in member int64_ - * @param _int64_ New value for member int64_ - */ - eProsima_user_DllExport void int64_( - int64_t _int64_); - - /*! - * @brief This function returns the value of member int64_ - * @return Value of member int64_ - */ - eProsima_user_DllExport int64_t int64_() const; - - /*! - * @brief This function returns a reference to member int64_ - * @return Reference to member int64_ - */ - eProsima_user_DllExport int64_t& int64_(); - - - /*! - * @brief This function sets a value in member uint64_ - * @param _uint64_ New value for member uint64_ - */ - eProsima_user_DllExport void uint64_( - uint64_t _uint64_); - - /*! - * @brief This function returns the value of member uint64_ - * @return Value of member uint64_ - */ - eProsima_user_DllExport uint64_t uint64_() const; - - /*! - * @brief This function returns a reference to member uint64_ - * @return Reference to member uint64_ - */ - eProsima_user_DllExport uint64_t& uint64_(); - - - /*! - * @brief This function copies the value in member local_string - * @param _local_string New value to be copied in member local_string - */ - eProsima_user_DllExport void local_string( - const std::string& _local_string); - - /*! - * @brief This function moves the value in member local_string - * @param _local_string New value to be moved in member local_string - */ - eProsima_user_DllExport void local_string( - std::string&& _local_string); - - /*! - * @brief This function returns a constant reference to member local_string - * @return Constant reference to member local_string - */ - eProsima_user_DllExport const std::string& local_string() const; - - /*! - * @brief This function returns a reference to member local_string - * @return Reference to member local_string - */ - eProsima_user_DllExport std::string& local_string(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const NewAliases& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - int8_t m_int8_; - uint8_t m_uint8_; - int16_t m_int16_; - uint16_t m_uint16_; - int32_t m_int32_; - uint32_t m_uint32_; - int64_t m_int64_; - uint64_t m_uint64_; - std::string m_local_string; - -}; - - - -/*! - * @brief This class represents the union WCharUnion defined by the user in the IDL file. - * @ingroup new_features_4_2 - */ -class WCharUnion -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport WCharUnion(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~WCharUnion(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object WCharUnion that will be copied. - */ - eProsima_user_DllExport WCharUnion( - const WCharUnion& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object WCharUnion that will be copied. - */ - eProsima_user_DllExport WCharUnion( - WCharUnion&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object WCharUnion that will be copied. - */ - eProsima_user_DllExport WCharUnion& operator =( - const WCharUnion& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object WCharUnion that will be copied. - */ - eProsima_user_DllExport WCharUnion& operator =( - WCharUnion&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x WCharUnion object to compare. - */ - eProsima_user_DllExport bool operator ==( - const WCharUnion& x) const; - - /*! - * @brief Comparison operator. - * @param x WCharUnion object to compare. - */ - eProsima_user_DllExport bool operator !=( - const WCharUnion& x) const; - - /*! - * @brief This function sets the discriminator value. - * @param __d New value for the discriminator. - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the new value doesn't correspond to the selected union member. - */ - eProsima_user_DllExport void _d( - wchar_t __d); - - /*! - * @brief This function returns the value of the discriminator. - * @return Value of the discriminator - */ - eProsima_user_DllExport wchar_t _d() const; - - /*! - * @brief This function returns a reference to the discriminator. - * @return Reference to the discriminator. - */ - eProsima_user_DllExport wchar_t& _d(); - - /*! - * @brief This function sets a value in member case_zero - * @param _case_zero New value for member case_zero - */ - eProsima_user_DllExport void case_zero( - int32_t _case_zero); - - /*! - * @brief This function returns the value of member case_zero - * @return Value of member case_zero - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t case_zero() const; - - /*! - * @brief This function returns a reference to member case_zero - * @return Reference to member case_zero - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t& case_zero(); - - - /*! - * @brief This function sets a value in member case_one - * @param _case_one New value for member case_one - */ - eProsima_user_DllExport void case_one( - int32_t _case_one); - - /*! - * @brief This function returns the value of member case_one - * @return Value of member case_one - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t case_one() const; - - /*! - * @brief This function returns a reference to member case_one - * @return Reference to member case_one - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t& case_one(); - - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const WCharUnion& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - -private: - - wchar_t m__d; - - int32_t m_case_zero; - int32_t m_case_one; -}; - - - -/*! - * @brief This class represents the union OctetUnion defined by the user in the IDL file. - * @ingroup new_features_4_2 - */ -class OctetUnion -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport OctetUnion(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~OctetUnion(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object OctetUnion that will be copied. - */ - eProsima_user_DllExport OctetUnion( - const OctetUnion& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object OctetUnion that will be copied. - */ - eProsima_user_DllExport OctetUnion( - OctetUnion&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object OctetUnion that will be copied. - */ - eProsima_user_DllExport OctetUnion& operator =( - const OctetUnion& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object OctetUnion that will be copied. - */ - eProsima_user_DllExport OctetUnion& operator =( - OctetUnion&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x OctetUnion object to compare. - */ - eProsima_user_DllExport bool operator ==( - const OctetUnion& x) const; - - /*! - * @brief Comparison operator. - * @param x OctetUnion object to compare. - */ - eProsima_user_DllExport bool operator !=( - const OctetUnion& x) const; - - /*! - * @brief This function sets the discriminator value. - * @param __d New value for the discriminator. - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the new value doesn't correspond to the selected union member. - */ - eProsima_user_DllExport void _d( - uint8_t __d); - - /*! - * @brief This function returns the value of the discriminator. - * @return Value of the discriminator - */ - eProsima_user_DllExport uint8_t _d() const; - - /*! - * @brief This function returns a reference to the discriminator. - * @return Reference to the discriminator. - */ - eProsima_user_DllExport uint8_t& _d(); - - /*! - * @brief This function sets a value in member case_five - * @param _case_five New value for member case_five - */ - eProsima_user_DllExport void case_five( - int32_t _case_five); - - /*! - * @brief This function returns the value of member case_five - * @return Value of member case_five - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t case_five() const; - - /*! - * @brief This function returns a reference to member case_five - * @return Reference to member case_five - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t& case_five(); - - - /*! - * @brief This function sets a value in member case_seven - * @param _case_seven New value for member case_seven - */ - eProsima_user_DllExport void case_seven( - int32_t _case_seven); - - /*! - * @brief This function returns the value of member case_seven - * @return Value of member case_seven - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t case_seven() const; - - /*! - * @brief This function returns a reference to member case_seven - * @return Reference to member case_seven - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t& case_seven(); - - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const OctetUnion& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - -private: - - uint8_t m__d; - - int32_t m_case_five; - int32_t m_case_seven; -}; - - - -/*! - * @brief This class represents the union Int8Union defined by the user in the IDL file. - * @ingroup new_features_4_2 - */ -class Int8Union -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport Int8Union(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~Int8Union(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object Int8Union that will be copied. - */ - eProsima_user_DllExport Int8Union( - const Int8Union& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object Int8Union that will be copied. - */ - eProsima_user_DllExport Int8Union( - Int8Union&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object Int8Union that will be copied. - */ - eProsima_user_DllExport Int8Union& operator =( - const Int8Union& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object Int8Union that will be copied. - */ - eProsima_user_DllExport Int8Union& operator =( - Int8Union&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x Int8Union object to compare. - */ - eProsima_user_DllExport bool operator ==( - const Int8Union& x) const; - - /*! - * @brief Comparison operator. - * @param x Int8Union object to compare. - */ - eProsima_user_DllExport bool operator !=( - const Int8Union& x) const; - - /*! - * @brief This function sets the discriminator value. - * @param __d New value for the discriminator. - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the new value doesn't correspond to the selected union member. - */ - eProsima_user_DllExport void _d( - int8_t __d); - - /*! - * @brief This function returns the value of the discriminator. - * @return Value of the discriminator - */ - eProsima_user_DllExport int8_t _d() const; - - /*! - * @brief This function returns a reference to the discriminator. - * @return Reference to the discriminator. - */ - eProsima_user_DllExport int8_t& _d(); - - /*! - * @brief This function sets a value in member case_three - * @param _case_three New value for member case_three - */ - eProsima_user_DllExport void case_three( - int32_t _case_three); - - /*! - * @brief This function returns the value of member case_three - * @return Value of member case_three - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t case_three() const; - - /*! - * @brief This function returns a reference to member case_three - * @return Reference to member case_three - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t& case_three(); - - - /*! - * @brief This function sets a value in member case_six - * @param _case_six New value for member case_six - */ - eProsima_user_DllExport void case_six( - int32_t _case_six); - - /*! - * @brief This function returns the value of member case_six - * @return Value of member case_six - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t case_six() const; - - /*! - * @brief This function returns a reference to member case_six - * @return Reference to member case_six - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t& case_six(); - - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const Int8Union& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - -private: - - int8_t m__d; - - int32_t m_case_three; - int32_t m_case_six; -}; - -namespace bitmodule { - /*! - * @brief This class represents the structure ParentBitset defined by the user in the IDL file. - * @ingroup new_features_4_2 - */ - class ParentBitset - { - public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport ParentBitset(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~ParentBitset(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object bitmodule::ParentBitset that will be copied. - */ - eProsima_user_DllExport ParentBitset( - const ParentBitset& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object bitmodule::ParentBitset that will be copied. - */ - eProsima_user_DllExport ParentBitset( - ParentBitset&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object bitmodule::ParentBitset that will be copied. - */ - eProsima_user_DllExport ParentBitset& operator =( - const ParentBitset& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object bitmodule::ParentBitset that will be copied. - */ - eProsima_user_DllExport ParentBitset& operator =( - ParentBitset&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x bitmodule::ParentBitset object to compare. - */ - eProsima_user_DllExport bool operator ==( - const ParentBitset& x) const; - - /*! - * @brief Comparison operator. - * @param x bitmodule::ParentBitset object to compare. - */ - eProsima_user_DllExport bool operator !=( - const ParentBitset& x) const; - - /*! - * @brief This function sets a value in member parent_bitfield - * @param _parent_bitfield New value for member parent_bitfield - */ - eProsima_user_DllExport void parent_bitfield( - uint32_t _parent_bitfield); - - /*! - * @brief This function returns the value of member parent_bitfield - * @return Value of member parent_bitfield - */ - eProsima_user_DllExport uint32_t parent_bitfield() const; - - - eProsima_user_DllExport std::bitset<17> bitset() const; - - eProsima_user_DllExport void bitset( - const std::bitset<17>&); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const bitmodule::ParentBitset& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - - private: - - std::bitset<17> m_bitset; - }; - /*! - * @brief This class represents the structure MyBitset defined by the user in the IDL file. - * @ingroup new_features_4_2 - */ - class MyBitset : public bitmodule::ParentBitset - { - public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MyBitset(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MyBitset(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object bitmodule::MyBitset that will be copied. - */ - eProsima_user_DllExport MyBitset( - const MyBitset& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object bitmodule::MyBitset that will be copied. - */ - eProsima_user_DllExport MyBitset( - MyBitset&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object bitmodule::MyBitset that will be copied. - */ - eProsima_user_DllExport MyBitset& operator =( - const MyBitset& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object bitmodule::MyBitset that will be copied. - */ - eProsima_user_DllExport MyBitset& operator =( - MyBitset&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x bitmodule::MyBitset object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MyBitset& x) const; - - /*! - * @brief Comparison operator. - * @param x bitmodule::MyBitset object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MyBitset& x) const; - - /*! - * @brief This function sets a value in member a - * @param _a New value for member a - */ - eProsima_user_DllExport void a( - char _a); - - /*! - * @brief This function returns the value of member a - * @return Value of member a - */ - eProsima_user_DllExport char a() const; - - - /*! - * @brief This function sets a value in member b - * @param _b New value for member b - */ - eProsima_user_DllExport void b( - bool _b); - - /*! - * @brief This function returns the value of member b - * @return Value of member b - */ - eProsima_user_DllExport bool b() const; - - - - /*! - * @brief This function sets a value in member c - * @param _c New value for member c - */ - eProsima_user_DllExport void c( - uint16_t _c); - - /*! - * @brief This function returns the value of member c - * @return Value of member c - */ - eProsima_user_DllExport uint16_t c() const; - - - /*! - * @brief This function sets a value in member d - * @param _d New value for member d - */ - eProsima_user_DllExport void d( - int16_t _d); - - /*! - * @brief This function returns the value of member d - * @return Value of member d - */ - eProsima_user_DllExport int16_t d() const; - - - /*! - * @brief This function sets a value in member e - * @param _e New value for member e - */ - eProsima_user_DllExport void e( - int16_t _e); - - /*! - * @brief This function returns the value of member e - * @return Value of member e - */ - eProsima_user_DllExport int16_t e() const; - - - /*! - * @brief This function sets a value in member f - * @param _f New value for member f - */ - eProsima_user_DllExport void f( - int16_t _f); - - /*! - * @brief This function returns the value of member f - * @return Value of member f - */ - eProsima_user_DllExport int16_t f() const; - - - eProsima_user_DllExport std::bitset<50> bitset() const; - - eProsima_user_DllExport void bitset( - const std::bitset<50>&); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const bitmodule::MyBitset& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - - private: - - std::bitset<33> m_bitset; - }; - /*! - * @brief This class represents the bitmask MyBitMask defined by the user in the IDL file. - * @ingroup new_features_4_2 - */ - enum MyBitMaskBits : uint8_t - { - flag0 = 0x01ull << 0, - flag1 = 0x01ull << 1, - flag4 = 0x01ull << 4, - flag6 = 0x01ull << 6, - flag7 = 0x01ull << 7 - }; - typedef uint8_t MyBitMask; - - - /*! - * @brief This class represents the structure BitsetBitmask defined by the user in the IDL file. - * @ingroup new_features_4_2 - */ - class BitsetBitmask - { - public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport BitsetBitmask(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~BitsetBitmask(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object bitmodule::BitsetBitmask that will be copied. - */ - eProsima_user_DllExport BitsetBitmask( - const BitsetBitmask& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object bitmodule::BitsetBitmask that will be copied. - */ - eProsima_user_DllExport BitsetBitmask( - BitsetBitmask&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object bitmodule::BitsetBitmask that will be copied. - */ - eProsima_user_DllExport BitsetBitmask& operator =( - const BitsetBitmask& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object bitmodule::BitsetBitmask that will be copied. - */ - eProsima_user_DllExport BitsetBitmask& operator =( - BitsetBitmask&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x bitmodule::BitsetBitmask object to compare. - */ - eProsima_user_DllExport bool operator ==( - const BitsetBitmask& x) const; - - /*! - * @brief Comparison operator. - * @param x bitmodule::BitsetBitmask object to compare. - */ - eProsima_user_DllExport bool operator !=( - const BitsetBitmask& x) const; - - /*! - * @brief This function copies the value in member mybitset - * @param _mybitset New value to be copied in member mybitset - */ - eProsima_user_DllExport void mybitset( - const bitmodule::MyBitset& _mybitset); - - /*! - * @brief This function moves the value in member mybitset - * @param _mybitset New value to be moved in member mybitset - */ - eProsima_user_DllExport void mybitset( - bitmodule::MyBitset&& _mybitset); - - /*! - * @brief This function returns a constant reference to member mybitset - * @return Constant reference to member mybitset - */ - eProsima_user_DllExport const bitmodule::MyBitset& mybitset() const; - - /*! - * @brief This function returns a reference to member mybitset - * @return Reference to member mybitset - */ - eProsima_user_DllExport bitmodule::MyBitset& mybitset(); - - - /*! - * @brief This function copies the value in member mybitmask - * @param _mybitmask New value to be copied in member mybitmask - */ - eProsima_user_DllExport void mybitmask( - const bitmodule::MyBitMask& _mybitmask); - - /*! - * @brief This function moves the value in member mybitmask - * @param _mybitmask New value to be moved in member mybitmask - */ - eProsima_user_DllExport void mybitmask( - bitmodule::MyBitMask&& _mybitmask); - - /*! - * @brief This function returns a constant reference to member mybitmask - * @return Constant reference to member mybitmask - */ - eProsima_user_DllExport const bitmodule::MyBitMask& mybitmask() const; - - /*! - * @brief This function returns a reference to member mybitmask - * @return Reference to member mybitmask - */ - eProsima_user_DllExport bitmodule::MyBitMask& mybitmask(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const bitmodule::BitsetBitmask& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - - private: - - bitmodule::MyBitset m_mybitset; - bitmodule::MyBitMask m_mybitmask; - - }; - - - - /*! - * @brief This class represents the structure BM2 defined by the user in the IDL file. - * @ingroup new_features_4_2 - */ - class BM2 : public bitmodule::BitsetBitmask - { - public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport BM2(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~BM2(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object bitmodule::BM2 that will be copied. - */ - eProsima_user_DllExport BM2( - const BM2& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object bitmodule::BM2 that will be copied. - */ - eProsima_user_DllExport BM2( - BM2&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object bitmodule::BM2 that will be copied. - */ - eProsima_user_DllExport BM2& operator =( - const BM2& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object bitmodule::BM2 that will be copied. - */ - eProsima_user_DllExport BM2& operator =( - BM2&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x bitmodule::BM2 object to compare. - */ - eProsima_user_DllExport bool operator ==( - const BM2& x) const; - - /*! - * @brief Comparison operator. - * @param x bitmodule::BM2 object to compare. - */ - eProsima_user_DllExport bool operator !=( - const BM2& x) const; - - /*! - * @brief This function copies the value in member two - * @param _two New value to be copied in member two - */ - eProsima_user_DllExport void two( - const bitmodule::MyBitMask& _two); - - /*! - * @brief This function moves the value in member two - * @param _two New value to be moved in member two - */ - eProsima_user_DllExport void two( - bitmodule::MyBitMask&& _two); - - /*! - * @brief This function returns a constant reference to member two - * @return Constant reference to member two - */ - eProsima_user_DllExport const bitmodule::MyBitMask& two() const; - - /*! - * @brief This function returns a reference to member two - * @return Reference to member two - */ - eProsima_user_DllExport bitmodule::MyBitMask& two(); - - - /*! - * @brief This function sets a value in member mylong - * @param _mylong New value for member mylong - */ - eProsima_user_DllExport void mylong( - int32_t _mylong); - - /*! - * @brief This function returns the value of member mylong - * @return Value of member mylong - */ - eProsima_user_DllExport int32_t mylong() const; - - /*! - * @brief This function returns a reference to member mylong - * @return Reference to member mylong - */ - eProsima_user_DllExport int32_t& mylong(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const bitmodule::BM2& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - - private: - - bitmodule::MyBitMask m_two; - int32_t m_mylong; - - }; - -} // namespace bitmodule - - -/*! - * @brief This class represents the structure StructTest defined by the user in the IDL file. - * @ingroup new_features_4_2 - */ -class StructTest : public NewAliases -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport StructTest(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~StructTest(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object StructTest that will be copied. - */ - eProsima_user_DllExport StructTest( - const StructTest& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object StructTest that will be copied. - */ - eProsima_user_DllExport StructTest( - StructTest&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object StructTest that will be copied. - */ - eProsima_user_DllExport StructTest& operator =( - const StructTest& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object StructTest that will be copied. - */ - eProsima_user_DllExport StructTest& operator =( - StructTest&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x StructTest object to compare. - */ - eProsima_user_DllExport bool operator ==( - const StructTest& x) const; - - /*! - * @brief Comparison operator. - * @param x StructTest object to compare. - */ - eProsima_user_DllExport bool operator !=( - const StructTest& x) const; - - /*! - * @brief This function copies the value in member octetUnion - * @param _octetUnion New value to be copied in member octetUnion - */ - eProsima_user_DllExport void octetUnion( - const OctetUnion& _octetUnion); - - /*! - * @brief This function moves the value in member octetUnion - * @param _octetUnion New value to be moved in member octetUnion - */ - eProsima_user_DllExport void octetUnion( - OctetUnion&& _octetUnion); - - /*! - * @brief This function returns a constant reference to member octetUnion - * @return Constant reference to member octetUnion - */ - eProsima_user_DllExport const OctetUnion& octetUnion() const; - - /*! - * @brief This function returns a reference to member octetUnion - * @return Reference to member octetUnion - */ - eProsima_user_DllExport OctetUnion& octetUnion(); - - - /*! - * @brief This function copies the value in member int8Union - * @param _int8Union New value to be copied in member int8Union - */ - eProsima_user_DllExport void int8Union( - const Int8Union& _int8Union); - - /*! - * @brief This function moves the value in member int8Union - * @param _int8Union New value to be moved in member int8Union - */ - eProsima_user_DllExport void int8Union( - Int8Union&& _int8Union); - - /*! - * @brief This function returns a constant reference to member int8Union - * @return Constant reference to member int8Union - */ - eProsima_user_DllExport const Int8Union& int8Union() const; - - /*! - * @brief This function returns a reference to member int8Union - * @return Reference to member int8Union - */ - eProsima_user_DllExport Int8Union& int8Union(); - - - /*! - * @brief This function copies the value in member myStructBits - * @param _myStructBits New value to be copied in member myStructBits - */ - eProsima_user_DllExport void myStructBits( - const bitmodule::BM2& _myStructBits); - - /*! - * @brief This function moves the value in member myStructBits - * @param _myStructBits New value to be moved in member myStructBits - */ - eProsima_user_DllExport void myStructBits( - bitmodule::BM2&& _myStructBits); - - /*! - * @brief This function returns a constant reference to member myStructBits - * @return Constant reference to member myStructBits - */ - eProsima_user_DllExport const bitmodule::BM2& myStructBits() const; - - /*! - * @brief This function returns a reference to member myStructBits - * @return Reference to member myStructBits - */ - eProsima_user_DllExport bitmodule::BM2& myStructBits(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const StructTest& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - OctetUnion m_octetUnion; - Int8Union m_int8Union; - bitmodule::BM2 m_myStructBits; - -}; - - -#endif // _FAST_DDS_GENERATED_NEW_FEATURES_4_2_H_ - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/test/unittest/dynamic_types/types_profile.xml b/test/unittest/dynamic_types/types_profile.xml deleted file mode 100644 index bb0bffdfe07..00000000000 --- a/test/unittest/dynamic_types/types_profile.xml +++ /dev/null @@ -1,277 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/test/unittest/logging/CMakeLists.txt b/test/unittest/logging/CMakeLists.txt index be92901677e..1c3cbceba53 100644 --- a/test/unittest/logging/CMakeLists.txt +++ b/test/unittest/logging/CMakeLists.txt @@ -19,10 +19,6 @@ if(WIN32) endif() set(LOG_COMMON_SOURCE - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/Log.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/OStreamConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutErrConsumer.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/LocatorWithMask.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/Time_t.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/network/utils/netmask_filter.cpp @@ -57,7 +53,11 @@ target_include_directories(LogTests PRIVATE ${Asio_INCLUDE_DIR} ${PROJECT_SOURCE_DIR}/include ${PROJECT_BINARY_DIR}/include ${PROJECT_SOURCE_DIR}/src/cpp) -target_link_libraries(LogTests GTest::gtest ${MOCKS} +target_link_libraries(LogTests + fastcdr + fastdds::log + GTest::gtest + ${MOCKS} $<$:iphlpapi$Shlwapi> ) gtest_discover_tests(LogTests) @@ -67,8 +67,8 @@ set(LOGFILETESTS_TEST_SOURCE LogFileTests.cpp) set(LOGFILETESTS_SOURCE ${LOG_COMMON_SOURCE} - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/FileConsumer.cpp - ${LOGFILETESTS_TEST_SOURCE}) + ${LOGFILETESTS_TEST_SOURCE} + ) # External sources if(TINYXML2_SOURCE_DIR) @@ -97,5 +97,6 @@ target_link_libraries(LogFileTests GTest::gtest ${MOCKS} $<$:iphlpapi$Shlwapi> ${TINYXML2_LIBRARY} fastcdr + fastdds::log ) gtest_discover_tests(LogFileTests) diff --git a/test/unittest/logging/log_macros/CMakeLists.txt b/test/unittest/logging/log_macros/CMakeLists.txt index 0e0b64f5954..8e25c598db3 100644 --- a/test/unittest/logging/log_macros/CMakeLists.txt +++ b/test/unittest/logging/log_macros/CMakeLists.txt @@ -17,10 +17,6 @@ if(WIN32) endif() set(LOG_COMMON_SOURCE - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/Log.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/OStreamConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutErrConsumer.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/LocatorWithMask.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/Time_t.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/network/utils/netmask_filter.cpp @@ -51,7 +47,11 @@ target_include_directories(LogMacrosAllActiveTests PRIVATE ${Asio_INCLUDE_DIR} ${PROJECT_SOURCE_DIR}/include ${PROJECT_BINARY_DIR}/include ${PROJECT_SOURCE_DIR}/src/cpp) -target_link_libraries(LogMacrosAllActiveTests GTest::gtest ${MOCKS} +target_link_libraries(LogMacrosAllActiveTests + fastcdr + fastdds::log + GTest::gtest + ${MOCKS} $<$:iphlpapi$Shlwapi> ) gtest_discover_tests(LogMacrosAllActiveTests) @@ -75,7 +75,11 @@ target_include_directories(LogMacrosNoInfoTests PRIVATE ${Asio_INCLUDE_DIR} ${PROJECT_SOURCE_DIR}/include ${PROJECT_BINARY_DIR}/include ${PROJECT_SOURCE_DIR}/src/cpp) -target_link_libraries(LogMacrosNoInfoTests GTest::gtest ${MOCKS} +target_link_libraries(LogMacrosNoInfoTests + fastcdr + fastdds::log + GTest::gtest + ${MOCKS} $<$:iphlpapi$Shlwapi> ) gtest_discover_tests(LogMacrosNoInfoTests) @@ -99,7 +103,11 @@ target_include_directories(LogMacrosNoWarningTests PRIVATE ${Asio_INCLUDE_DIR} ${PROJECT_SOURCE_DIR}/include ${PROJECT_BINARY_DIR}/include ${PROJECT_SOURCE_DIR}/src/cpp) -target_link_libraries(LogMacrosNoWarningTests GTest::gtest ${MOCKS} +target_link_libraries(LogMacrosNoWarningTests + fastcdr + fastdds::log + GTest::gtest + ${MOCKS} $<$:iphlpapi$Shlwapi> ) gtest_discover_tests(LogMacrosNoWarningTests) @@ -123,7 +131,11 @@ target_include_directories(LogMacrosNoErrorTests PRIVATE ${Asio_INCLUDE_DIR} ${PROJECT_SOURCE_DIR}/include ${PROJECT_BINARY_DIR}/include ${PROJECT_SOURCE_DIR}/src/cpp) -target_link_libraries(LogMacrosNoErrorTests GTest::gtest ${MOCKS} +target_link_libraries(LogMacrosNoErrorTests + fastcdr + fastdds::log + GTest::gtest + ${MOCKS} $<$:iphlpapi$Shlwapi> ) gtest_discover_tests(LogMacrosNoErrorTests) @@ -147,7 +159,11 @@ target_include_directories(LogMacrosDefaultTests PRIVATE ${Asio_INCLUDE_DIR} ${PROJECT_SOURCE_DIR}/include ${PROJECT_BINARY_DIR}/include ${PROJECT_SOURCE_DIR}/src/cpp) -target_link_libraries(LogMacrosDefaultTests GTest::gtest ${MOCKS} +target_link_libraries(LogMacrosDefaultTests + fastcdr + fastdds::log + GTest::gtest + ${MOCKS} $<$:iphlpapi$Shlwapi> ) gtest_discover_tests(LogMacrosDefaultTests) @@ -173,7 +189,11 @@ target_include_directories(LogMacrosInternalDebugOffTests PRIVATE ${Asio_INCLUDE_DIR} ${PROJECT_SOURCE_DIR}/include ${PROJECT_BINARY_DIR}/include ${PROJECT_SOURCE_DIR}/src/cpp) -target_link_libraries(LogMacrosInternalDebugOffTests GTest::gtest ${MOCKS} +target_link_libraries(LogMacrosInternalDebugOffTests + fastcdr + fastdds::log + GTest::gtest + ${MOCKS} $<$:iphlpapi$Shlwapi> ) gtest_discover_tests(LogMacrosInternalDebugOffTests) @@ -196,7 +216,11 @@ target_include_directories(OldLogMacrosTests PRIVATE ${Asio_INCLUDE_DIR} ${PROJECT_SOURCE_DIR}/include ${PROJECT_BINARY_DIR}/include ${PROJECT_SOURCE_DIR}/src/cpp) -target_link_libraries(OldLogMacrosTests GTest::gtest ${MOCKS} +target_link_libraries(OldLogMacrosTests + fastcdr + fastdds::log + GTest::gtest + ${MOCKS} $<$:iphlpapi$Shlwapi> ) gtest_discover_tests(OldLogMacrosTests) @@ -220,7 +244,11 @@ target_include_directories(OldLogMacrosDisableTests PRIVATE ${Asio_INCLUDE_DIR} ${PROJECT_SOURCE_DIR}/include ${PROJECT_BINARY_DIR}/include ${PROJECT_SOURCE_DIR}/src/cpp) -target_link_libraries(OldLogMacrosDisableTests GTest::gtest ${MOCKS} +target_link_libraries(OldLogMacrosDisableTests + fastcdr + fastdds::log + GTest::gtest + ${MOCKS} $<$:iphlpapi$Shlwapi> ) gtest_discover_tests(OldLogMacrosDisableTests) diff --git a/test/unittest/rtps/DataSharing/CMakeLists.txt b/test/unittest/rtps/DataSharing/CMakeLists.txt index ca66e5558ce..b769066e807 100644 --- a/test/unittest/rtps/DataSharing/CMakeLists.txt +++ b/test/unittest/rtps/DataSharing/CMakeLists.txt @@ -38,7 +38,7 @@ target_include_directories(SHMSegmentTests PRIVATE ${THIRDPARTY_BOOST_INCLUDE_DIR} ) target_link_libraries(SHMSegmentTests - fastcdr fastrtps foonathan_memory + fastcdr fastdds foonathan_memory GTest::gmock ${CMAKE_DL_LIBS} ${CMAKE_DL_LIBS} diff --git a/test/unittest/rtps/DataSharing/SHMSegmentTests.cpp b/test/unittest/rtps/DataSharing/SHMSegmentTests.cpp index 495cdde0aa9..70cb3f07343 100644 --- a/test/unittest/rtps/DataSharing/SHMSegmentTests.cpp +++ b/test/unittest/rtps/DataSharing/SHMSegmentTests.cpp @@ -12,22 +12,21 @@ // See the License for the specific language governing permissions and // limitations under the License. -#include "fastdds/rtps/common/Types.h" -#include "fastrtps/qos/QosPolicies.h" #include #include -#include +#include "fastdds/rtps/common/Types.h" +#include +#include #include +#include #include -#include +#include #include #include #include -#include - namespace eprosima { namespace fastrtps { namespace rtps { diff --git a/test/unittest/rtps/builtin/BuiltinDataSerializationTests.cpp b/test/unittest/rtps/builtin/BuiltinDataSerializationTests.cpp index ae7274f243a..76cd708b1bc 100644 --- a/test/unittest/rtps/builtin/BuiltinDataSerializationTests.cpp +++ b/test/unittest/rtps/builtin/BuiltinDataSerializationTests.cpp @@ -20,16 +20,16 @@ #include #include #include +#include +#include +#include +#include #include #include #include #include #include #include -#include -#include -#include -#include #include @@ -140,8 +140,9 @@ TEST(BuiltinDataSerializationTests, ok_with_defaults) } } -// Regression test for redmine issue #10547 -TEST(BuiltinDataSerializationTests, ignore_unsupported_type_info) +// Regression test for redmine issue #10547. +// Update against OpenDDS 3.27. With this version we can read the remote DATA(w). +TEST(BuiltinDataSerializationTests, interoperability_with_opendds_3_27) { // DATA(w) { @@ -153,16 +154,17 @@ TEST(BuiltinDataSerializationTests, ignore_unsupported_type_info) // Topic name 0x05, 0x00, 0x0c, 0x00, 0x07, 0x00, 0x00, 0x00, 0x43, 0x69, 0x72, 0x63, 0x6c, 0x65, 0x00, 0x00, - // Type information - 0x75, 0x00, 0x50, 0x00, - 0x4c, 0x00, 0x00, 0x00, 0x01, 0x10, 0x00, 0x40, 0x24, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, - 0x14, 0x00, 0x00, 0x00, 0xf1, 0x80, 0x99, 0x5e, 0xfc, 0xdb, 0xda, 0xbe, 0xd5, 0xb3, 0x3d, 0xe3, - 0xea, 0x3a, 0x4b, 0x00, 0x53, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, - 0x02, 0x10, 0x00, 0x40, 0x18, 0x00, 0x00, 0x00, 0x14, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // Type name 0x07, 0x00, 0x10, 0x00, 0x0a, 0x00, 0x00, 0x00, 0x53, 0x68, 0x61, 0x70, 0x65, 0x54, 0x79, 0x70, 0x65, 0x00, 0x00, 0x00, + // Type information + 0x75, 0x00, 0x58, 0x00, + 0x54, 0x00, 0x00, 0x00, 0x01, 0x10, 0x00, 0x40, 0x28, 0x00, 0x00, 0x00, 0x24, 0x00, 0x00, 0x00, + 0x14, 0x00, 0x00, 0x00, 0xf1, 0x8b, 0x4b, 0x28, 0x4d, 0xe3, 0xa2, 0x4e, 0x5f, 0x86, 0x58, 0x5c, + 0x57, 0x88, 0xf6, 0x00, 0x57, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, 0x04, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x02, 0x10, 0x00, 0x40, 0x1c, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // Reliability 0x1a, 0x00, 0x0c, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe1, 0xf5, 0x05, @@ -171,15 +173,27 @@ TEST(BuiltinDataSerializationTests, ignore_unsupported_type_info) 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, // Endpoint GUID 0x5a, 0x00, 0x10, 0x00, - 0x01, 0x03, 0x08, 0x00, 0x27, 0x5c, 0x4f, 0x05, 0x0f, 0x19, 0x05, 0xea, 0x00, 0x00, 0x00, 0x02, + 0x01, 0x03, 0x74, 0x04, 0xf1, 0x0b, 0x6b, 0x16, 0x94, 0x6c, 0x26, 0x73, 0x00, 0x00, 0x00, 0x02, // Multicast locator 0x30, 0x00, 0x18, 0x00, 0x01, 0x00, 0x00, 0x00, 0xe9, 0x1c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xef, 0xff, 0x00, 0x02, // Unicast locator 0x2f, 0x00, 0x18, 0x00, - 0x01, 0x00, 0x00, 0x00, 0x3e, 0xcd, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x00, 0xc0, 0xa8, 0x01, 0xb4, + 0x01, 0x00, 0x00, 0x00, 0x67, 0x85, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xc0, 0xa8, 0x01, 0x27, + 0x2f, 0x00, 0x18, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x67, 0x85, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xac, 0x11, 0x00, 0x01, + 0x2f, 0x00, 0x18, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x67, 0x85, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x0a, 0x05, 0x00, 0x01, + 0x2f, 0x00, 0x18, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x67, 0x85, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xc0, 0xa8, 0x50, 0x01, + 0x2f, 0x00, 0x18, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x67, 0x85, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xc0, 0xa8, 0x01, 0x8b, // Sentinel 0x01, 0x00, 0x00, 0x00 }; @@ -203,35 +217,45 @@ TEST(BuiltinDataSerializationTests, ignore_unsupported_type_info) 0x05, 0x00, 0x0c, 0x00, 0x07, 0x00, 0x00, 0x00, 0x43, 0x69, 0x72, 0x63, 0x6c, 0x65, 0x00, 0x00, // Type information - 0x75, 0x00, 0x50, 0x00, - 0x4c, 0x00, 0x00, 0x00, 0x01, 0x10, 0x00, 0x40, 0x24, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, - 0x14, 0x00, 0x00, 0x00, 0xf1, 0x80, 0x99, 0x5e, 0xfc, 0xdb, 0xda, 0xbe, 0xd5, 0xb3, 0x3d, 0xe3, - 0xea, 0x3a, 0x4b, 0x00, 0x53, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, - 0x02, 0x10, 0x00, 0x40, 0x18, 0x00, 0x00, 0x00, 0x14, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x75, 0x00, 0x58, 0x00, + 0x54, 0x00, 0x00, 0x00, 0x01, 0x10, 0x00, 0x40, 0x28, 0x00, 0x00, 0x00, 0x24, 0x00, 0x00, 0x00, + 0x14, 0x00, 0x00, 0x00, 0xf1, 0x8b, 0x4b, 0x28, 0x4d, 0xe3, 0xa2, 0x4e, 0x5f, 0x86, 0x58, 0x5c, + 0x57, 0x88, 0xf6, 0x00, 0x57, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, 0x04, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x02, 0x10, 0x00, 0x40, 0x1c, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // Type name 0x07, 0x00, 0x10, 0x00, 0x0a, 0x00, 0x00, 0x00, 0x53, 0x68, 0x61, 0x70, 0x65, 0x54, 0x79, 0x70, 0x65, 0x00, 0x00, 0x00, // Reliability 0x1a, 0x00, 0x0c, 0x00, 0x01, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0x7f, 0xff, 0xff, 0xff, 0x7f, - // Endpoint GUID - 0x5a, 0x00, 0x10, 0x00, - 0x01, 0x03, 0x08, 0x00, 0x27, 0x5c, 0x4f, 0x05, 0x0f, 0x40, 0x29, 0x9d, 0x00, 0x00, 0x00, 0x07, // Data representation 0x73, 0x00, 0x08, 0x00, - 0x02, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x94, 0xd0, 0x00, 0x00, + // Endpoint GUID + 0x5a, 0x00, 0x10, 0x00, + 0x01, 0x03, 0x74, 0x04, 0xf1, 0x0b, 0x6b, 0x16, 0x84, 0x3e, 0x9d, 0x2b, 0x00, 0x00, 0x00, 0x07, // Multicast locator 0x30, 0x00, 0x18, 0x00, 0x01, 0x00, 0x00, 0x00, 0xe9, 0x1c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xef, 0xff, 0x00, 0x02, // Unicast locator 0x2f, 0x00, 0x18, 0x00, - 0x01, 0x00, 0x00, 0x00, 0x45, 0x95, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x00, 0xc0, 0xa8, 0x01, 0xb4, - // Type consistency - 0x74, 0x00, 0x08, 0x00, - 0x02, 0x00, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x67, 0x85, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xc0, 0xa8, 0x01, 0x27, + 0x2f, 0x00, 0x18, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x67, 0x85, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xac, 0x11, 0x00, 0x01, + 0x2f, 0x00, 0x18, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x67, 0x85, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x0a, 0x05, 0x00, 0x01, + 0x2f, 0x00, 0x18, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x67, 0x85, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xc0, 0xa8, 0x50, 0x01, + 0x2f, 0x00, 0x18, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x67, 0x85, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xc0, 0xa8, 0x01, 0x8b, // Sentinel 0x01, 0x00, 0x00, 0x00 }; diff --git a/test/unittest/rtps/builtin/CMakeLists.txt b/test/unittest/rtps/builtin/CMakeLists.txt index 6080be5c018..79d207a3766 100644 --- a/test/unittest/rtps/builtin/CMakeLists.txt +++ b/test/unittest/rtps/builtin/CMakeLists.txt @@ -13,36 +13,12 @@ # limitations under the License. set(BUILTIN_DATA_SERIALIZATION_TESTS_SOURCE BuiltinDataSerializationTests.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/AnnotationDescriptor.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/AnnotationParameterValue.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/BuiltinAnnotationsTypeObject.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicData.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicDataFactory.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicDataPtr.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicPubSubType.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicType.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeBuilder.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeBuilderFactory.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeBuilderPtr.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeMember.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypePtr.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/MemberDescriptor.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeDescriptor.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeIdentifier.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeIdentifierTypes.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeNamesGenerator.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeObject.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeObjectFactory.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeObjectHashId.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypesBase.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/core/policy/ParameterList.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/Log.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/OStreamConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutErrConsumer.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/publisher/qos/WriterQos.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/subscriber/qos/ReaderQos.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/topic/TopicDataType.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/xtypes/exception/Exception.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/xtypes/type_representation/dds_xtypes_typeobjectPubSubTypes.cxx ${PROJECT_SOURCE_DIR}/src/cpp/rtps/attributes/ThreadSettings.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/builtin/data/ParticipantProxyData.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/builtin/data/ReaderProxyData.cpp @@ -88,13 +64,18 @@ target_compile_definitions(BuiltinDataSerializationTests PRIVATE $<$:__INTERNALDEBUG> # Internal debug activated. ) target_include_directories(BuiltinDataSerializationTests PRIVATE + ${PROJECT_SOURCE_DIR}/test/mock/dds/TypeObjectRegistry + ${PROJECT_SOURCE_DIR}/test/mock/dds/TypeObjectUtils ${PROJECT_SOURCE_DIR}/test/mock/rtps/NetworkFactory + ${PROJECT_SOURCE_DIR}/test/mock/rtps/RTPSDomainImpl ${PROJECT_SOURCE_DIR}/include ${PROJECT_BINARY_DIR}/include ${PROJECT_SOURCE_DIR}/src/cpp ${Asio_INCLUDE_DIR} $<$:${ANDROID_IFADDRS_INCLUDE_DIR}> ) -target_link_libraries(BuiltinDataSerializationTests foonathan_memory +target_link_libraries(BuiltinDataSerializationTests + fastdds::log + foonathan_memory GTest::gmock ${CMAKE_DL_LIBS}) if(QNX) diff --git a/test/unittest/rtps/common/CMakeLists.txt b/test/unittest/rtps/common/CMakeLists.txt index 1aaa1f32094..770533a4d34 100644 --- a/test/unittest/rtps/common/CMakeLists.txt +++ b/test/unittest/rtps/common/CMakeLists.txt @@ -15,10 +15,6 @@ set(CACHECHANGETESTS_SOURCE CacheChangeTests.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/Time_t.cpp) set(GUID_UTILS_TESTS_SOURCE GuidUtilsTests.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/Log.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/OStreamConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutErrConsumer.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/GuidPrefix_t.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/LocatorWithMask.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/Time_t.cpp @@ -47,10 +43,6 @@ endif() set(SEQUENCENUMBERTESTS_SOURCE SequenceNumberTests.cpp) set(PORTPARAMETERSTESTS_SOURCE PortParametersTests.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/Log.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/OStreamConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutErrConsumer.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/LocatorWithMask.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/Time_t.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/network/utils/netmask_filter.cpp @@ -89,7 +81,11 @@ target_include_directories(GuidUtilsTests PRIVATE ${PROJECT_SOURCE_DIR}/include ${PROJECT_BINARY_DIR}/include ${Asio_INCLUDE_DIR} $<$:${ANDROID_IFADDRS_INCLUDE_DIR}>) -target_link_libraries(GuidUtilsTests GTest::gtest) +target_link_libraries(GuidUtilsTests + fastcdr + fastdds::log + GTest::gtest + ) if(QNX) target_link_libraries(GuidUtilsTests socket) endif() @@ -119,7 +115,11 @@ target_include_directories(PortParametersTests PRIVATE ${Asio_INCLUDE_DIR} ${PROJECT_SOURCE_DIR}/include ${PROJECT_BINARY_DIR}/include ${PROJECT_SOURCE_DIR}/src/cpp) -target_link_libraries(PortParametersTests GTest::gtest) +target_link_libraries(PortParametersTests + fastcdr + fastdds::log + GTest::gtest + ) gtest_discover_tests(PortParametersTests PROPERTIES LABELS "NoMemoryCheck") ################### diff --git a/test/unittest/rtps/common/CacheChangeTests.cpp b/test/unittest/rtps/common/CacheChangeTests.cpp index d9f07608ad6..bdc53a79063 100644 --- a/test/unittest/rtps/common/CacheChangeTests.cpp +++ b/test/unittest/rtps/common/CacheChangeTests.cpp @@ -12,12 +12,13 @@ // See the License for the specific language governing permissions and // limitations under the License. -#include - #include #include + #include +#include + using namespace eprosima::fastrtps::rtps; struct FragmentTestStep @@ -28,12 +29,14 @@ struct FragmentTestStep { uint32_t initial_fragment; uint16_t num_fragments; - } input; + } + input; struct __Check { bool missing_fragments[10]; - } check; + } + check; void do_test( CacheChange_t& uut) const @@ -134,7 +137,7 @@ TEST(CacheChange, FragmentManagement) int main( int argc, - char **argv) + char** argv) { testing::InitGoogleTest(&argc, argv); return RUN_ALL_TESTS(); diff --git a/test/unittest/rtps/common/PortParametersTests.cpp b/test/unittest/rtps/common/PortParametersTests.cpp index 6eb2bdd5b69..a0eacc02ab3 100644 --- a/test/unittest/rtps/common/PortParametersTests.cpp +++ b/test/unittest/rtps/common/PortParametersTests.cpp @@ -12,11 +12,12 @@ // See the License for the specific language governing permissions and // limitations under the License. -#include - #include + #include +#include + using namespace eprosima::fastrtps::rtps; /*! @@ -88,7 +89,9 @@ TEST(PortParametersDeathTest, Limit_Multicast_Domain_FAIL) ASSERT_EXIT( { params.getMulticastPort(233); }, ::testing::ExitedWithCode(EXIT_FAILURE), ""); } -int main(int argc, char **argv) +int main( + int argc, + char** argv) { testing::InitGoogleTest(&argc, argv); return RUN_ALL_TESTS(); diff --git a/test/unittest/rtps/common/SequenceNumberTests.cpp b/test/unittest/rtps/common/SequenceNumberTests.cpp index 09708e42021..96f8252832b 100644 --- a/test/unittest/rtps/common/SequenceNumberTests.cpp +++ b/test/unittest/rtps/common/SequenceNumberTests.cpp @@ -12,11 +12,12 @@ // See the License for the specific language governing permissions and // limitations under the License. -#include - #include + #include +#include + using namespace eprosima::fastrtps::rtps; /*! @@ -445,7 +446,7 @@ TEST(SequenceNumberSet, AddOperation) ASSERT_TRUE(set.add(seq)); seq += 3; - + ASSERT_FALSE(set.add(seq)); } @@ -490,7 +491,9 @@ TEST(SequenceNumberSet, GetMaxSeqNumOperation) ASSERT_EQ(set.max(), expected_seq); } -int main(int argc, char **argv) +int main( + int argc, + char** argv) { testing::InitGoogleTest(&argc, argv); return RUN_ALL_TESTS(); diff --git a/test/unittest/rtps/common/TimeTests.cpp b/test/unittest/rtps/common/TimeTests.cpp index 5f8521bfc20..ca00d4e278c 100644 --- a/test/unittest/rtps/common/TimeTests.cpp +++ b/test/unittest/rtps/common/TimeTests.cpp @@ -12,10 +12,10 @@ // See the License for the specific language governing permissions and // limitations under the License. -#include - #include +#include + using namespace eprosima::fastrtps::rtps; /* diff --git a/test/unittest/rtps/discovery/CMakeLists.txt b/test/unittest/rtps/discovery/CMakeLists.txt index b0217786eff..c3bbc5c71e2 100644 --- a/test/unittest/rtps/discovery/CMakeLists.txt +++ b/test/unittest/rtps/discovery/CMakeLists.txt @@ -14,32 +14,6 @@ #EDP TESTS set(EDPTESTS_SOURCE EdpTests.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/AnnotationDescriptor.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/AnnotationParameterValue.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/BuiltinAnnotationsTypeObject.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicData.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicDataFactory.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicDataPtr.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicPubSubType.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicType.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeBuilder.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeBuilderFactory.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeBuilderPtr.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeMember.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypePtr.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/MemberDescriptor.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeDescriptor.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeIdentifier.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeIdentifierTypes.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeNamesGenerator.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeObject.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeObjectFactory.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeObjectHashId.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypesBase.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/Log.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/OStreamConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutErrConsumer.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/publisher/qos/WriterQos.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/subscriber/qos/ReaderQos.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/topic/TopicDataType.cpp @@ -89,11 +63,15 @@ target_include_directories(EdpTests PRIVATE ${PROJECT_SOURCE_DIR}/test/mock/rtps/TimedEvent ${PROJECT_SOURCE_DIR}/test/mock/rtps/ResourceEvent ${PROJECT_SOURCE_DIR}/test/mock/rtps/SecurityManager + ${PROJECT_SOURCE_DIR}/test/mock/rtps/RTPSDomainImpl ${PROJECT_SOURCE_DIR}/include ${PROJECT_BINARY_DIR}/include ${PROJECT_SOURCE_DIR}/src/cpp ${Asio_INCLUDE_DIR} ) -target_link_libraries(EdpTests foonathan_memory +target_link_libraries(EdpTests + fastdds::log + fastdds::xtypes::type-representation + foonathan_memory GTest::gmock ${CMAKE_DL_LIBS}) if(QNX) @@ -131,36 +109,11 @@ if(TLS_FOUND) endif() set(PDPTESTS_SOURCE PDPTests.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/AnnotationDescriptor.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/AnnotationParameterValue.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/BuiltinAnnotationsTypeObject.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicData.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicDataFactory.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicDataPtr.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicPubSubType.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicType.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeBuilder.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeBuilderFactory.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeBuilderPtr.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeMember.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypePtr.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/MemberDescriptor.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeDescriptor.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeIdentifier.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeIdentifierTypes.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeNamesGenerator.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeObject.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeObjectFactory.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeObjectHashId.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypesBase.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/core/policy/ParameterList.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/Log.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/OStreamConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutErrConsumer.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/publisher/qos/WriterQos.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/subscriber/qos/ReaderQos.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/topic/TopicDataType.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/xtypes/type_representation/dds_xtypes_typeobjectPubSubTypes.cxx ${PROJECT_SOURCE_DIR}/src/cpp/rtps/attributes/PropertyPolicy.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/attributes/ThreadSettings.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/builtin/data/ParticipantProxyData.cpp @@ -189,7 +142,7 @@ set(PDPTESTS_SOURCE PDPTests.cpp add_executable(PDPTests ${PDPTESTS_SOURCE}) -target_compile_definitions(PDPTests PRIVATE FASTRTPS_NO_LIB +target_compile_definitions(PDPTests PRIVATE FASTDDS_NO_LIB BOOST_ASIO_STANDALONE ASIO_STANDALONE $<$>,$>:__DEBUG> @@ -220,7 +173,9 @@ target_include_directories(PDPTests PRIVATE ${Asio_INCLUDE_DIR} ) -target_link_libraries(PDPTests foonathan_memory +target_link_libraries(PDPTests + fastdds::log + foonathan_memory GTest::gmock ${CMAKE_DL_LIBS} $<$:OpenSSL::SSL$OpenSSL::Crypto>) diff --git a/test/unittest/rtps/discovery/EdpTests.cpp b/test/unittest/rtps/discovery/EdpTests.cpp index 930d13ba9dc..f092e87bbbe 100644 --- a/test/unittest/rtps/discovery/EdpTests.cpp +++ b/test/unittest/rtps/discovery/EdpTests.cpp @@ -15,14 +15,14 @@ #include #include -#include -#include -#include -#include +#include +#include + +#include +#include #include #include - namespace eprosima { namespace fastrtps { namespace rtps { @@ -133,6 +133,8 @@ class EdpTests : public ::testing::Test void set_incompatible_type() { rdata->typeName("AnotherTypeName"); + rdata->type_information().assigned(false); + wdata->type_information().assigned(false); } void check_expectations( @@ -266,23 +268,39 @@ TEST_F(EdpTests, CheckPartitionCompatibility) TEST_F(EdpTests, CheckDurabilityCompatibility) { - std::vector> testing_cases{ - { PERSISTENT_DURABILITY_QOS, PERSISTENT_DURABILITY_QOS, fastdds::dds::INVALID_QOS_POLICY_ID}, - { PERSISTENT_DURABILITY_QOS, TRANSIENT_DURABILITY_QOS, fastdds::dds::INVALID_QOS_POLICY_ID}, - { PERSISTENT_DURABILITY_QOS, TRANSIENT_LOCAL_DURABILITY_QOS, fastdds::dds::INVALID_QOS_POLICY_ID}, - { PERSISTENT_DURABILITY_QOS, VOLATILE_DURABILITY_QOS, fastdds::dds::INVALID_QOS_POLICY_ID}, - { TRANSIENT_DURABILITY_QOS, PERSISTENT_DURABILITY_QOS, fastdds::dds::DURABILITY_QOS_POLICY_ID}, - { TRANSIENT_DURABILITY_QOS, TRANSIENT_DURABILITY_QOS, fastdds::dds::INVALID_QOS_POLICY_ID}, - { TRANSIENT_DURABILITY_QOS, TRANSIENT_LOCAL_DURABILITY_QOS, fastdds::dds::INVALID_QOS_POLICY_ID}, - { TRANSIENT_DURABILITY_QOS, VOLATILE_DURABILITY_QOS, fastdds::dds::INVALID_QOS_POLICY_ID}, - { TRANSIENT_LOCAL_DURABILITY_QOS, PERSISTENT_DURABILITY_QOS, fastdds::dds::DURABILITY_QOS_POLICY_ID}, - { TRANSIENT_LOCAL_DURABILITY_QOS, TRANSIENT_DURABILITY_QOS, fastdds::dds::DURABILITY_QOS_POLICY_ID}, - { TRANSIENT_LOCAL_DURABILITY_QOS, TRANSIENT_LOCAL_DURABILITY_QOS, fastdds::dds::INVALID_QOS_POLICY_ID}, - { TRANSIENT_LOCAL_DURABILITY_QOS, VOLATILE_DURABILITY_QOS, fastdds::dds::INVALID_QOS_POLICY_ID}, - { VOLATILE_DURABILITY_QOS, PERSISTENT_DURABILITY_QOS, fastdds::dds::DURABILITY_QOS_POLICY_ID}, - { VOLATILE_DURABILITY_QOS, TRANSIENT_DURABILITY_QOS, fastdds::dds::DURABILITY_QOS_POLICY_ID}, - { VOLATILE_DURABILITY_QOS, TRANSIENT_LOCAL_DURABILITY_QOS, fastdds::dds::DURABILITY_QOS_POLICY_ID}, - { VOLATILE_DURABILITY_QOS, VOLATILE_DURABILITY_QOS, fastdds::dds::INVALID_QOS_POLICY_ID} + std::vector> testing_cases{ + { fastdds::dds::PERSISTENT_DURABILITY_QOS, fastdds::dds::PERSISTENT_DURABILITY_QOS, + fastdds::dds::INVALID_QOS_POLICY_ID}, + { fastdds::dds::PERSISTENT_DURABILITY_QOS, fastdds::dds::TRANSIENT_DURABILITY_QOS, + fastdds::dds::INVALID_QOS_POLICY_ID}, + { fastdds::dds::PERSISTENT_DURABILITY_QOS, fastdds::dds::TRANSIENT_LOCAL_DURABILITY_QOS, + fastdds::dds::INVALID_QOS_POLICY_ID}, + { fastdds::dds::PERSISTENT_DURABILITY_QOS, fastdds::dds::VOLATILE_DURABILITY_QOS, + fastdds::dds::INVALID_QOS_POLICY_ID}, + { fastdds::dds::TRANSIENT_DURABILITY_QOS, fastdds::dds::PERSISTENT_DURABILITY_QOS, + fastdds::dds::DURABILITY_QOS_POLICY_ID}, + { fastdds::dds::TRANSIENT_DURABILITY_QOS, fastdds::dds::TRANSIENT_DURABILITY_QOS, + fastdds::dds::INVALID_QOS_POLICY_ID}, + { fastdds::dds::TRANSIENT_DURABILITY_QOS, fastdds::dds::TRANSIENT_LOCAL_DURABILITY_QOS, + fastdds::dds::INVALID_QOS_POLICY_ID}, + { fastdds::dds::TRANSIENT_DURABILITY_QOS, fastdds::dds::VOLATILE_DURABILITY_QOS, + fastdds::dds::INVALID_QOS_POLICY_ID}, + { fastdds::dds::TRANSIENT_LOCAL_DURABILITY_QOS, fastdds::dds::PERSISTENT_DURABILITY_QOS, + fastdds::dds::DURABILITY_QOS_POLICY_ID}, + { fastdds::dds::TRANSIENT_LOCAL_DURABILITY_QOS, fastdds::dds::TRANSIENT_DURABILITY_QOS, + fastdds::dds::DURABILITY_QOS_POLICY_ID}, + { fastdds::dds::TRANSIENT_LOCAL_DURABILITY_QOS, fastdds::dds::TRANSIENT_LOCAL_DURABILITY_QOS, + fastdds::dds::INVALID_QOS_POLICY_ID}, + { fastdds::dds::TRANSIENT_LOCAL_DURABILITY_QOS, fastdds::dds::VOLATILE_DURABILITY_QOS, + fastdds::dds::INVALID_QOS_POLICY_ID}, + { fastdds::dds::VOLATILE_DURABILITY_QOS, fastdds::dds::PERSISTENT_DURABILITY_QOS, + fastdds::dds::DURABILITY_QOS_POLICY_ID}, + { fastdds::dds::VOLATILE_DURABILITY_QOS, fastdds::dds::TRANSIENT_DURABILITY_QOS, + fastdds::dds::DURABILITY_QOS_POLICY_ID}, + { fastdds::dds::VOLATILE_DURABILITY_QOS, fastdds::dds::TRANSIENT_LOCAL_DURABILITY_QOS, + fastdds::dds::DURABILITY_QOS_POLICY_ID}, + { fastdds::dds::VOLATILE_DURABILITY_QOS, fastdds::dds::VOLATILE_DURABILITY_QOS, + fastdds::dds::INVALID_QOS_POLICY_ID} }; for (auto testing_case : testing_cases) @@ -311,11 +329,14 @@ TEST_F(EdpTests, CheckDeadlineCompatibility) TEST_F(EdpTests, CheckOwnershipCompatibility) { - std::vector> testing_cases{ - { SHARED_OWNERSHIP_QOS, SHARED_OWNERSHIP_QOS, fastdds::dds::INVALID_QOS_POLICY_ID}, - { SHARED_OWNERSHIP_QOS, EXCLUSIVE_OWNERSHIP_QOS, fastdds::dds::OWNERSHIP_QOS_POLICY_ID}, - { EXCLUSIVE_OWNERSHIP_QOS, SHARED_OWNERSHIP_QOS, fastdds::dds::OWNERSHIP_QOS_POLICY_ID}, - { EXCLUSIVE_OWNERSHIP_QOS, EXCLUSIVE_OWNERSHIP_QOS, fastdds::dds::INVALID_QOS_POLICY_ID} + std::vector> testing_cases{ + { fastdds::dds::SHARED_OWNERSHIP_QOS, fastdds::dds::SHARED_OWNERSHIP_QOS, fastdds::dds::INVALID_QOS_POLICY_ID}, + { fastdds::dds::SHARED_OWNERSHIP_QOS, fastdds::dds::EXCLUSIVE_OWNERSHIP_QOS, + fastdds::dds::OWNERSHIP_QOS_POLICY_ID}, + { fastdds::dds::EXCLUSIVE_OWNERSHIP_QOS, fastdds::dds::SHARED_OWNERSHIP_QOS, + fastdds::dds::OWNERSHIP_QOS_POLICY_ID}, + { fastdds::dds::EXCLUSIVE_OWNERSHIP_QOS, fastdds::dds::EXCLUSIVE_OWNERSHIP_QOS, + fastdds::dds::INVALID_QOS_POLICY_ID} }; for (auto testing_case : testing_cases) @@ -328,17 +349,25 @@ TEST_F(EdpTests, CheckOwnershipCompatibility) TEST_F(EdpTests, CheckLivelinessKindCompatibility) { - std::vector> testing_cases{ - { MANUAL_BY_TOPIC_LIVELINESS_QOS, MANUAL_BY_TOPIC_LIVELINESS_QOS, fastdds::dds::INVALID_QOS_POLICY_ID}, - { MANUAL_BY_TOPIC_LIVELINESS_QOS, MANUAL_BY_PARTICIPANT_LIVELINESS_QOS, fastdds::dds::INVALID_QOS_POLICY_ID}, - { MANUAL_BY_TOPIC_LIVELINESS_QOS, AUTOMATIC_LIVELINESS_QOS, fastdds::dds::INVALID_QOS_POLICY_ID}, - { MANUAL_BY_PARTICIPANT_LIVELINESS_QOS, MANUAL_BY_TOPIC_LIVELINESS_QOS, fastdds::dds::LIVELINESS_QOS_POLICY_ID}, - { MANUAL_BY_PARTICIPANT_LIVELINESS_QOS, MANUAL_BY_PARTICIPANT_LIVELINESS_QOS, + std::vector> testing_cases{ + { fastdds::dds::MANUAL_BY_TOPIC_LIVELINESS_QOS, fastdds::dds::MANUAL_BY_TOPIC_LIVELINESS_QOS, + fastdds::dds::INVALID_QOS_POLICY_ID}, + { fastdds::dds::MANUAL_BY_TOPIC_LIVELINESS_QOS, fastdds::dds::MANUAL_BY_PARTICIPANT_LIVELINESS_QOS, + fastdds::dds::INVALID_QOS_POLICY_ID}, + { fastdds::dds::MANUAL_BY_TOPIC_LIVELINESS_QOS, fastdds::dds::AUTOMATIC_LIVELINESS_QOS, + fastdds::dds::INVALID_QOS_POLICY_ID}, + { fastdds::dds::MANUAL_BY_PARTICIPANT_LIVELINESS_QOS, fastdds::dds::MANUAL_BY_TOPIC_LIVELINESS_QOS, + fastdds::dds::LIVELINESS_QOS_POLICY_ID}, + { fastdds::dds::MANUAL_BY_PARTICIPANT_LIVELINESS_QOS, fastdds::dds::MANUAL_BY_PARTICIPANT_LIVELINESS_QOS, + fastdds::dds::INVALID_QOS_POLICY_ID}, + { fastdds::dds::MANUAL_BY_PARTICIPANT_LIVELINESS_QOS, fastdds::dds::AUTOMATIC_LIVELINESS_QOS, fastdds::dds::INVALID_QOS_POLICY_ID}, - { MANUAL_BY_PARTICIPANT_LIVELINESS_QOS, AUTOMATIC_LIVELINESS_QOS, fastdds::dds::INVALID_QOS_POLICY_ID}, - { AUTOMATIC_LIVELINESS_QOS, MANUAL_BY_TOPIC_LIVELINESS_QOS, fastdds::dds::LIVELINESS_QOS_POLICY_ID}, - { AUTOMATIC_LIVELINESS_QOS, MANUAL_BY_PARTICIPANT_LIVELINESS_QOS, fastdds::dds::LIVELINESS_QOS_POLICY_ID}, - { AUTOMATIC_LIVELINESS_QOS, AUTOMATIC_LIVELINESS_QOS, fastdds::dds::INVALID_QOS_POLICY_ID} + { fastdds::dds::AUTOMATIC_LIVELINESS_QOS, fastdds::dds::MANUAL_BY_TOPIC_LIVELINESS_QOS, + fastdds::dds::LIVELINESS_QOS_POLICY_ID}, + { fastdds::dds::AUTOMATIC_LIVELINESS_QOS, fastdds::dds::MANUAL_BY_PARTICIPANT_LIVELINESS_QOS, + fastdds::dds::LIVELINESS_QOS_POLICY_ID}, + { fastdds::dds::AUTOMATIC_LIVELINESS_QOS, fastdds::dds::AUTOMATIC_LIVELINESS_QOS, + fastdds::dds::INVALID_QOS_POLICY_ID} }; for (auto testing_case : testing_cases) @@ -367,11 +396,15 @@ TEST_F(EdpTests, CheckLeaseDurationCompatibility) TEST_F(EdpTests, CheckReliabilityCompatibility) { - std::vector> testing_cases{ - { RELIABLE_RELIABILITY_QOS, RELIABLE_RELIABILITY_QOS, fastdds::dds::INVALID_QOS_POLICY_ID}, - { RELIABLE_RELIABILITY_QOS, BEST_EFFORT_RELIABILITY_QOS, fastdds::dds::INVALID_QOS_POLICY_ID}, - { BEST_EFFORT_RELIABILITY_QOS, RELIABLE_RELIABILITY_QOS, fastdds::dds::RELIABILITY_QOS_POLICY_ID}, - { BEST_EFFORT_RELIABILITY_QOS, BEST_EFFORT_RELIABILITY_QOS, fastdds::dds::INVALID_QOS_POLICY_ID} + std::vector> testing_cases{ + { fastdds::dds::RELIABLE_RELIABILITY_QOS, fastdds::dds::RELIABLE_RELIABILITY_QOS, + fastdds::dds::INVALID_QOS_POLICY_ID}, + { fastdds::dds::RELIABLE_RELIABILITY_QOS, fastdds::dds::BEST_EFFORT_RELIABILITY_QOS, + fastdds::dds::INVALID_QOS_POLICY_ID}, + { fastdds::dds::BEST_EFFORT_RELIABILITY_QOS, fastdds::dds::RELIABLE_RELIABILITY_QOS, + fastdds::dds::RELIABILITY_QOS_POLICY_ID}, + { fastdds::dds::BEST_EFFORT_RELIABILITY_QOS, fastdds::dds::BEST_EFFORT_RELIABILITY_QOS, + fastdds::dds::INVALID_QOS_POLICY_ID} }; for (auto testing_case : testing_cases) @@ -401,28 +434,38 @@ TEST_F(EdpTests, CheckPositiveAckCompatibility) TEST_F(EdpTests, CheckDataRepresentationCompatibility) { - using DataRepresentationQosVector = std::vector; + using DataRepresentationQosVector = std::vector; std::vector> testing_cases{ { {}, {}, fastdds::dds::INVALID_QOS_POLICY_ID}, - { {}, {DataRepresentationId::XCDR_DATA_REPRESENTATION}, fastdds::dds::INVALID_QOS_POLICY_ID}, - { {}, {DataRepresentationId::XCDR_DATA_REPRESENTATION, DataRepresentationId::XCDR2_DATA_REPRESENTATION}, + { {}, {fastdds::dds::DataRepresentationId::XCDR_DATA_REPRESENTATION}, fastdds::dds::INVALID_QOS_POLICY_ID}, + { {}, + {fastdds::dds::DataRepresentationId::XCDR_DATA_REPRESENTATION, + fastdds::dds::DataRepresentationId::XCDR2_DATA_REPRESENTATION}, fastdds::dds::INVALID_QOS_POLICY_ID}, - { {}, {DataRepresentationId::XCDR2_DATA_REPRESENTATION}, fastdds::dds::DATAREPRESENTATION_QOS_POLICY_ID}, - { {DataRepresentationId::XCDR_DATA_REPRESENTATION}, {}, fastdds::dds::INVALID_QOS_POLICY_ID}, - { {DataRepresentationId::XCDR_DATA_REPRESENTATION}, {DataRepresentationId::XCDR_DATA_REPRESENTATION}, + { {}, {fastdds::dds::DataRepresentationId::XCDR2_DATA_REPRESENTATION}, + fastdds::dds::DATAREPRESENTATION_QOS_POLICY_ID}, + { {fastdds::dds::DataRepresentationId::XCDR_DATA_REPRESENTATION}, {}, fastdds::dds::INVALID_QOS_POLICY_ID}, + { {fastdds::dds::DataRepresentationId::XCDR_DATA_REPRESENTATION}, + {fastdds::dds::DataRepresentationId::XCDR_DATA_REPRESENTATION}, fastdds::dds::INVALID_QOS_POLICY_ID}, - { {DataRepresentationId::XCDR_DATA_REPRESENTATION}, - {DataRepresentationId::XCDR_DATA_REPRESENTATION, DataRepresentationId::XCDR2_DATA_REPRESENTATION}, + { {fastdds::dds::DataRepresentationId::XCDR_DATA_REPRESENTATION}, + {fastdds::dds::DataRepresentationId::XCDR_DATA_REPRESENTATION, + fastdds::dds::DataRepresentationId::XCDR2_DATA_REPRESENTATION}, fastdds::dds::INVALID_QOS_POLICY_ID}, - { {DataRepresentationId::XCDR_DATA_REPRESENTATION}, {DataRepresentationId::XCDR2_DATA_REPRESENTATION}, + { {fastdds::dds::DataRepresentationId::XCDR_DATA_REPRESENTATION}, + {fastdds::dds::DataRepresentationId::XCDR2_DATA_REPRESENTATION}, + fastdds::dds::DATAREPRESENTATION_QOS_POLICY_ID}, + { {fastdds::dds::DataRepresentationId::XCDR2_DATA_REPRESENTATION}, {}, fastdds::dds::DATAREPRESENTATION_QOS_POLICY_ID}, - { {DataRepresentationId::XCDR2_DATA_REPRESENTATION}, {}, fastdds::dds::DATAREPRESENTATION_QOS_POLICY_ID}, - { {DataRepresentationId::XCDR2_DATA_REPRESENTATION}, {DataRepresentationId::XCDR_DATA_REPRESENTATION}, + { {fastdds::dds::DataRepresentationId::XCDR2_DATA_REPRESENTATION}, + {fastdds::dds::DataRepresentationId::XCDR_DATA_REPRESENTATION}, fastdds::dds::DATAREPRESENTATION_QOS_POLICY_ID}, - { {DataRepresentationId::XCDR2_DATA_REPRESENTATION}, - {DataRepresentationId::XCDR_DATA_REPRESENTATION, DataRepresentationId::XCDR2_DATA_REPRESENTATION}, + { {fastdds::dds::DataRepresentationId::XCDR2_DATA_REPRESENTATION}, + {fastdds::dds::DataRepresentationId::XCDR_DATA_REPRESENTATION, + fastdds::dds::DataRepresentationId::XCDR2_DATA_REPRESENTATION}, fastdds::dds::INVALID_QOS_POLICY_ID}, - { {DataRepresentationId::XCDR2_DATA_REPRESENTATION}, {DataRepresentationId::XCDR2_DATA_REPRESENTATION}, + { {fastdds::dds::DataRepresentationId::XCDR2_DATA_REPRESENTATION}, + {fastdds::dds::DataRepresentationId::XCDR2_DATA_REPRESENTATION}, fastdds::dds::INVALID_QOS_POLICY_ID} }; diff --git a/test/unittest/rtps/discovery/PDPTests.cpp b/test/unittest/rtps/discovery/PDPTests.cpp index 67321b3cd97..cae1a91143d 100644 --- a/test/unittest/rtps/discovery/PDPTests.cpp +++ b/test/unittest/rtps/discovery/PDPTests.cpp @@ -13,25 +13,25 @@ // limitations under the License. #include -#include #include +#include #include +#include + #include #include -#include #include -#include #include #include #include #include -#include -#include +#include +#include #include -#include -#include +#include +#include #include #include #include @@ -47,17 +47,6 @@ #endif // if defined(_WIN32) namespace eprosima { - -namespace fastdds { -namespace dds { -namespace builtin { - -const fastrtps::rtps::SampleIdentity INVALID_SAMPLE_IDENTITY; - -} // namespace builtin -} // namespace dds -} // namespace fastdds - namespace fastrtps { namespace rtps { @@ -262,17 +251,6 @@ class Listener : public eprosima::fastdds::dds::DomainParticipantListener { } - void on_participant_discovery( - fastdds::dds::DomainParticipant* participant, - fastrtps::rtps::ParticipantDiscoveryInfo&& /*info*/) override - { - if (std::find(p_matched_.begin(), p_matched_.end(), participant->guid()) == p_matched_.end()) - { - matched++; - p_matched_.push_back(participant->guid()); - } - } - void on_participant_discovery( fastdds::dds::DomainParticipant* participant, fastrtps::rtps::ParticipantDiscoveryInfo&& /*info*/, diff --git a/test/unittest/rtps/domain/CMakeLists.txt b/test/unittest/rtps/domain/CMakeLists.txt new file mode 100644 index 00000000000..c6253245c05 --- /dev/null +++ b/test/unittest/rtps/domain/CMakeLists.txt @@ -0,0 +1,67 @@ +# Copyright 2024 Proyectos y Sistemas de Mantenimiento SL (eProsima). +# +# Licensed 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 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +set(RTPS_DOMAIN_TESTS_EXEC RTPSDomainTests) + +file(GLOB RTPS_DOMAIN_TESTS_SOURCE + RTPSDomainTests.cpp + ) + +# External sources +if(TINYXML2_SOURCE_DIR) + list(APPEND RTPS_DOMAIN_TESTS_SOURCE + ${TINYXML2_SOURCE_DIR}/tinyxml2.cpp + ) +endif() + +if(TINYXML2_INCLUDE_DIR) + include_directories(${TINYXML2_INCLUDE_DIR}) +endif(TINYXML2_INCLUDE_DIR) + +if(WIN32) + add_definitions(-D_WIN32_WINNT=0x0601) +endif() + +add_executable( + ${RTPS_DOMAIN_TESTS_EXEC} + ${RTPS_DOMAIN_TESTS_SOURCE} + ) + +target_compile_definitions(${RTPS_DOMAIN_TESTS_EXEC} PRIVATE + BOOST_ASIO_STANDALONE + ASIO_STANDALONE + $<$>,$>:__DEBUG> + $<$:__INTERNALDEBUG> # Internal debug activated. + ) + +target_include_directories( + ${RTPS_DOMAIN_TESTS_EXEC} + PRIVATE + ${PROJECT_SOURCE_DIR}/include + ${PROJECT_BINARY_DIR}/include + ${PROJECT_SOURCE_DIR}/src/cpp + ${Asio_INCLUDE_DIR} + ) + +target_link_libraries( + ${RTPS_DOMAIN_TESTS_EXEC} + GTest::gmock + ${CMAKE_DL_LIBS} + fastcdr + fastdds + $<$:OpenSSL::SSL$OpenSSL::Crypto> + ${TINYXML2_LIBRARY} + ) + +gtest_discover_tests(${RTPS_DOMAIN_TESTS_EXEC}) diff --git a/test/unittest/rtps/domain/RTPSDomainTests.cpp b/test/unittest/rtps/domain/RTPSDomainTests.cpp new file mode 100644 index 00000000000..ed89b579c8f --- /dev/null +++ b/test/unittest/rtps/domain/RTPSDomainTests.cpp @@ -0,0 +1,107 @@ +// Copyright 2024 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +#include + +#include +#include +#include + +/** + * This test checks the getter and setter for the library settings in the RTPS layer. + */ +TEST(RTPSDomainTests, library_settings_test) +{ + eprosima::fastdds::LibrarySettings library_settings; + EXPECT_TRUE(eprosima::fastrtps::rtps::RTPSDomain::get_library_settings(library_settings)); + // Get LibrarySettings default values +#if HAVE_STRICT_REALTIME + EXPECT_EQ(eprosima::fastdds::INTRAPROCESS_OFF, library_settings.intraprocess_delivery); +#else + EXPECT_EQ(eprosima::fastdds::INTRAPROCESS_FULL, library_settings.intraprocess_delivery); +#endif // if HAVE_STRICT_REALTIME + library_settings.intraprocess_delivery = eprosima::fastdds::INTRAPROCESS_USER_DATA_ONLY; + // Setting the library settings within an empty RTPSDomain shall return true + EXPECT_TRUE(eprosima::fastrtps::rtps::RTPSDomain::set_library_settings(library_settings)); + EXPECT_TRUE(eprosima::fastrtps::rtps::RTPSDomain::get_library_settings(library_settings)); + EXPECT_EQ(eprosima::fastdds::INTRAPROCESS_USER_DATA_ONLY, library_settings.intraprocess_delivery); + // Create RTPSParticipant + eprosima::fastrtps::rtps::RTPSParticipantAttributes part_attr; + eprosima::fastrtps::rtps::RTPSParticipant* participant = + eprosima::fastrtps::rtps::RTPSDomain::createParticipant(0, part_attr); + ASSERT_NE(nullptr, participant); + library_settings.intraprocess_delivery = eprosima::fastdds::INTRAPROCESS_OFF; + // Setting LibrarySettings with any RTPSParticipant shall fail + EXPECT_FALSE(eprosima::fastrtps::rtps::RTPSDomain::set_library_settings(library_settings)); + EXPECT_TRUE(eprosima::fastrtps::rtps::RTPSDomain::get_library_settings(library_settings)); + EXPECT_EQ(eprosima::fastdds::INTRAPROCESS_USER_DATA_ONLY, library_settings.intraprocess_delivery); + // Remove RTPSParticipant + EXPECT_TRUE(eprosima::fastrtps::rtps::RTPSDomain::removeRTPSParticipant(participant)); + library_settings.intraprocess_delivery = eprosima::fastdds::INTRAPROCESS_OFF; + // Setting LibrarySettings with no participants shall suceed + EXPECT_TRUE(eprosima::fastrtps::rtps::RTPSDomain::set_library_settings(library_settings)); + EXPECT_TRUE(eprosima::fastrtps::rtps::RTPSDomain::get_library_settings(library_settings)); + EXPECT_EQ(eprosima::fastdds::INTRAPROCESS_OFF, library_settings.intraprocess_delivery); + eprosima::fastrtps::rtps::RTPSDomain::stopAll(); +} + +/** + * This test checks get_topic_attributes_from_profile API. + */ +TEST(RTPSDomainTests, get_topic_attributes_from_profile_test) +{ + std::string profile_name = "test_profile_name"; + eprosima::fastrtps::TopicAttributes topic_att; + EXPECT_FALSE(eprosima::fastrtps::rtps::RTPSDomain::get_topic_attributes_from_profile(profile_name, topic_att)); + + const std::string xml = + R"( + + Test + DataTest + + KEEP_LAST + 20 + + + 5 + 2 + 1 + 20 + 10 + + +)"; + + EXPECT_EQ(eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->load_XML_profiles_string(xml.c_str(), + xml.length()), eprosima::fastdds::dds::RETCODE_OK); + EXPECT_TRUE(eprosima::fastrtps::rtps::RTPSDomain::get_topic_attributes_from_profile(profile_name, topic_att)); + EXPECT_EQ(topic_att.topicName, "Test"); + EXPECT_EQ(topic_att.topicDataType, "DataTest"); + EXPECT_EQ(topic_att.historyQos.kind, eprosima::fastdds::dds::HistoryQosPolicyKind::KEEP_LAST_HISTORY_QOS); + EXPECT_EQ(topic_att.historyQos.depth, 20); + EXPECT_EQ(topic_att.resourceLimitsQos.max_samples, 5); + EXPECT_EQ(topic_att.resourceLimitsQos.max_instances, 2); + EXPECT_EQ(topic_att.resourceLimitsQos.max_samples_per_instance, 1); + EXPECT_EQ(topic_att.resourceLimitsQos.allocated_samples, 20); + EXPECT_EQ(topic_att.resourceLimitsQos.extra_samples, 10); +} + +int main( + int argc, + char** argv) +{ + testing::InitGoogleTest(&argc, argv); + return RUN_ALL_TESTS(); +} diff --git a/test/unittest/rtps/flowcontrol/CMakeLists.txt b/test/unittest/rtps/flowcontrol/CMakeLists.txt index b5c706ae2d1..e4c7e412dc9 100644 --- a/test/unittest/rtps/flowcontrol/CMakeLists.txt +++ b/test/unittest/rtps/flowcontrol/CMakeLists.txt @@ -17,9 +17,6 @@ if(WIN32) endif() set(FLOWCONTROLLER_COMMON_SOURCE - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/Log.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/OStreamConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutConsumer.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/attributes/PropertyPolicy.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/LocatorWithMask.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/Time_t.cpp @@ -58,6 +55,7 @@ target_include_directories(FlowControllerFactoryTests PRIVATE ) target_link_libraries(FlowControllerFactoryTests fastcdr + fastdds::log GTest::gmock ) if(MSVC OR MSVC_IDE) @@ -92,6 +90,7 @@ target_include_directories(FlowControllerPublishModesTests PRIVATE ) target_link_libraries(FlowControllerPublishModesTests fastcdr + fastdds::log GTest::gmock ) if(MSVC OR MSVC_IDE) @@ -122,6 +121,7 @@ target_include_directories(FlowControllerSchedulersTests PRIVATE ) target_link_libraries(FlowControllerSchedulersTests fastcdr + fastdds::log GTest::gmock ) if(MSVC OR MSVC_IDE) diff --git a/test/unittest/rtps/history/CMakeLists.txt b/test/unittest/rtps/history/CMakeLists.txt index 73c78eceb21..31fa6a7ca92 100644 --- a/test/unittest/rtps/history/CMakeLists.txt +++ b/test/unittest/rtps/history/CMakeLists.txt @@ -13,10 +13,6 @@ # limitations under the License. set(READERHISTORYTESTS_SOURCE ReaderHistoryTests.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/Log.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/OStreamConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutErrConsumer.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/LocatorWithMask.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/Time_t.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/history/CacheChangePool.cpp @@ -32,10 +28,6 @@ set(READERHISTORYTESTS_SOURCE ReaderHistoryTests.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/SystemInfo.cpp) set(BASICPOOLSTESTS_SOURCE BasicPoolsTests.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/Log.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/OStreamConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutErrConsumer.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/LocatorWithMask.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/Time_t.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/history/CacheChangePool.cpp @@ -49,10 +41,6 @@ set(BASICPOOLSTESTS_SOURCE BasicPoolsTests.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/SystemInfo.cpp) set(CACHECHANGEPOOLTESTS_SOURCE CacheChangePoolTests.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/Log.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/OStreamConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutErrConsumer.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/LocatorWithMask.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/Time_t.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/history/CacheChangePool.cpp @@ -67,10 +55,6 @@ set(CACHECHANGEPOOLTESTS_SOURCE CacheChangePoolTests.cpp set(TOPICPAYLOADPOOLTESTS_SOURCE TopicPayloadPoolTests.cpp TopicPayloadPoolRegistryTests.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/Log.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/OStreamConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutErrConsumer.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/LocatorWithMask.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/Time_t.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/history/TopicPayloadPool.cpp @@ -112,6 +96,8 @@ target_include_directories(ReaderHistoryTests PRIVATE ${PROJECT_SOURCE_DIR}/src/cpp ${PROJECT_SOURCE_DIR}/include ${PROJECT_BINARY_DIR}/include) target_link_libraries(ReaderHistoryTests + fastcdr + fastdds::log GTest::gmock ${CMAKE_DL_LIBS}) gtest_discover_tests(ReaderHistoryTests) @@ -128,6 +114,8 @@ target_include_directories(BasicPoolsTests PRIVATE ${PROJECT_SOURCE_DIR}/src/cpp ${PROJECT_SOURCE_DIR}/include ${PROJECT_BINARY_DIR}/include) target_link_libraries(BasicPoolsTests + fastcdr + fastdds::log GTest::gtest ${CMAKE_DL_LIBS}) gtest_discover_tests(BasicPoolsTests) @@ -144,6 +132,8 @@ target_include_directories(CacheChangePoolTests PRIVATE ${PROJECT_SOURCE_DIR}/src/cpp ${PROJECT_SOURCE_DIR}/include ${PROJECT_BINARY_DIR}/include) target_link_libraries(CacheChangePoolTests + fastcdr + fastdds::log GTest::gtest ${CMAKE_DL_LIBS}) gtest_discover_tests(CacheChangePoolTests) @@ -161,6 +151,8 @@ target_include_directories(TopicPayloadPoolTests PRIVATE ${PROJECT_SOURCE_DIR}/src/cpp ${PROJECT_SOURCE_DIR}/include ${PROJECT_BINARY_DIR}/include) target_link_libraries(TopicPayloadPoolTests + fastcdr + fastdds::log GTest::gtest ${CMAKE_DL_LIBS}) gtest_discover_tests(TopicPayloadPoolTests) diff --git a/test/unittest/rtps/history/ReaderHistoryTests.cpp b/test/unittest/rtps/history/ReaderHistoryTests.cpp index 9bfad247506..4f82977b609 100644 --- a/test/unittest/rtps/history/ReaderHistoryTests.cpp +++ b/test/unittest/rtps/history/ReaderHistoryTests.cpp @@ -19,9 +19,9 @@ #include #include -#include -#include -#include +#include +#include +#include #include diff --git a/test/unittest/rtps/network/CMakeLists.txt b/test/unittest/rtps/network/CMakeLists.txt index 429a2d5e05c..8095ff14daf 100644 --- a/test/unittest/rtps/network/CMakeLists.txt +++ b/test/unittest/rtps/network/CMakeLists.txt @@ -16,10 +16,6 @@ set(NETWORKFACTORYTESTS_SOURCE NetworkFactoryTests.cpp mock/MockTransport.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/core/policy/ParameterList.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/Log.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/OStreamConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutErrConsumer.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/attributes/PropertyPolicy.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/attributes/ThreadSettings.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/GuidPrefix_t.cpp @@ -55,7 +51,6 @@ set(NETWORKFACTORYTESTS_SOURCE ${PROJECT_SOURCE_DIR}/src/cpp/utils/IPFinder.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/IPLocator.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/md5.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/utils/System.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/SystemInfo.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/TimedConditionVariable.cpp ) @@ -95,7 +90,10 @@ target_include_directories(NetworkFactoryTests PRIVATE ${PROJECT_SOURCE_DIR}/src/cpp $<$:${ANDROID_IFADDRS_INCLUDE_DIR}> ) -target_link_libraries(NetworkFactoryTests fastcdr foonathan_memory +target_link_libraries(NetworkFactoryTests + fastcdr + fastdds::log + foonathan_memory GTest::gtest ${MOCKS} $<$:OpenSSL::SSL$OpenSSL::Crypto> ${CMAKE_THREAD_LIBS_INIT} ${CMAKE_DL_LIBS}) @@ -105,34 +103,10 @@ if(QNX) endif() add_executable(ExternalLocatorsTests ExternalLocatorsTests.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/AnnotationDescriptor.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/AnnotationParameterValue.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/BuiltinAnnotationsTypeObject.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicData.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicDataFactory.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicDataPtr.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicPubSubType.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicType.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeBuilder.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeBuilderFactory.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeBuilderPtr.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeMember.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypePtr.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/MemberDescriptor.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeDescriptor.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeIdentifier.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeIdentifierTypes.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeNamesGenerator.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeObject.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeObjectFactory.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeObjectHashId.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypesBase.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/Log.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/OStreamConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutConsumer.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/publisher/qos/WriterQos.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/subscriber/qos/ReaderQos.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/topic/TopicDataType.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/xtypes/exception/Exception.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/attributes/ThreadSettings.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/LocatorWithMask.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/Time_t.cpp @@ -158,13 +132,19 @@ target_compile_definitions(ExternalLocatorsTests PRIVATE ) target_include_directories(ExternalLocatorsTests PRIVATE ${Asio_INCLUDE_DIR} + ${PROJECT_SOURCE_DIR}/test/mock/dds/TypeObjectRegistry + ${PROJECT_SOURCE_DIR}/test/mock/dds/TypeObjectUtils ${PROJECT_SOURCE_DIR}/test/mock/rtps/ParticipantProxyData ${PROJECT_SOURCE_DIR}/test/mock/rtps/ReaderProxyData + ${PROJECT_SOURCE_DIR}/test/mock/rtps/RTPSDomainImpl # Dependency of fastdds::xtypes::type_representation ${PROJECT_SOURCE_DIR}/test/mock/rtps/WriterProxyData ${PROJECT_SOURCE_DIR}/include ${PROJECT_BINARY_DIR}/include ${PROJECT_SOURCE_DIR}/src/cpp ) -target_link_libraries(ExternalLocatorsTests fastcdr +target_link_libraries(ExternalLocatorsTests + fastcdr + fastdds::log + fastdds::xtypes::dynamic-types::impl GTest::gtest ${MOCKS} ${CMAKE_THREAD_LIBS_INIT} ${CMAKE_DL_LIBS}) diff --git a/test/unittest/rtps/network/ExternalLocatorsTests.cpp b/test/unittest/rtps/network/ExternalLocatorsTests.cpp index cf643b0f1a5..a81467bab89 100644 --- a/test/unittest/rtps/network/ExternalLocatorsTests.cpp +++ b/test/unittest/rtps/network/ExternalLocatorsTests.cpp @@ -15,7 +15,7 @@ #include #include -#include +#include #include diff --git a/test/unittest/rtps/network/NetworkFactoryTests.cpp b/test/unittest/rtps/network/NetworkFactoryTests.cpp index 536547d872e..241c2dc79a8 100644 --- a/test/unittest/rtps/network/NetworkFactoryTests.cpp +++ b/test/unittest/rtps/network/NetworkFactoryTests.cpp @@ -17,19 +17,19 @@ #include #include -#include -#include -#include -#include -#include -#include +#include +#include +#include +#include +#include +#include #include #include -using namespace std; using namespace eprosima::fastrtps; using namespace eprosima::fastrtps::rtps; +using namespace eprosima::fastdds::rtps; class NetworkTests : public ::testing::Test { @@ -65,7 +65,7 @@ TEST_F(NetworkTests, build_sender_resource_returns_send_resource_for_a_kind_comp int ArbitraryKind = 1; HELPER_RegisterTransportWithKindAndChannels(ArbitraryKind, 10); - SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; Locator_t kindCompatibleLocator; kindCompatibleLocator.kind = ArbitraryKind; @@ -121,7 +121,7 @@ TEST_F(NetworkTests, build_sender_resource_returns_multiple_resources_if_multipl HELPER_RegisterTransportWithKindAndChannels(2, 10); HELPER_RegisterTransportWithKindAndChannels(2, 10); - SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; Locator_t locatorCompatibleWithTwoTransports; locatorCompatibleWithTwoTransports.kind = 2; @@ -223,7 +223,7 @@ TEST_F(NetworkTests, BuildSenderResources_returns_empty_vector_if_no_registered_ mockTransportDescriptor.maximumChannels = 10; networkFactoryUnderTest.RegisterTransport(mockTransportDescriptor); - SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; Locator_t locatorOfDifferentKind; locatorOfDifferentKind.kind = 2; @@ -242,7 +242,7 @@ TEST_F(NetworkTests, BuildSenderResources_returns_empty_vector_if_all_compatible // Given int ArbitraryKind = 1; HELPER_RegisterTransportWithKindAndChannels(ArbitraryKind, 10); - SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; Locator_t locator; locator.kind = ArbitraryKind; @@ -288,7 +288,7 @@ TEST_F(NetworkTests, A_receiver_resource_accurately_reports_whether_it_supports_ // Given int ArbitraryKind = 1; HELPER_RegisterTransportWithKindAndChannels(ArbitraryKind, 10); - SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; Locator_t locator; locator.kind = ArbitraryKind; ASSERT_TRUE(networkFactoryUnderTest.build_send_resources(send_resource_list, locator)); @@ -651,7 +651,7 @@ TEST_F(NetworkTests, LocatorShrink) fill_blackbox_locators_test_cases(test_cases); NetworkFactory f{pattr}; - UDPv4TransportDescriptor udpv4; + eprosima::fastdds::rtps::UDPv4TransportDescriptor udpv4; f.RegisterTransport(&udpv4); // TODO: Register more transports diff --git a/test/unittest/rtps/network/mock/MockTransport.cpp b/test/unittest/rtps/network/mock/MockTransport.cpp index 0520a98b63e..506b7137256 100644 --- a/test/unittest/rtps/network/mock/MockTransport.cpp +++ b/test/unittest/rtps/network/mock/MockTransport.cpp @@ -12,14 +12,13 @@ // See the License for the specific language governing permissions and // limitations under the License. -#include #include -#include +#include -using namespace std; +#include namespace eprosima { -namespace fastrtps { +namespace fastdds { namespace rtps { std::vector MockTransport::mockTransportInstances; @@ -49,7 +48,7 @@ MockTransport::~MockTransport() } bool MockTransport::init( - const PropertyPolicy* /*properties*/, + const fastrtps::rtps::PropertyPolicy* /*properties*/, const uint32_t& /*max_msg_size_no_frag*/) { return true; @@ -75,7 +74,7 @@ bool MockTransport::is_locator_allowed( } bool MockTransport::OpenOutputChannel( - SendResourceList& send_resource_list, + fastdds::rtps::SendResourceList& send_resource_list, const Locator_t& locator) { if (!IsLocatorSupported(locator)) @@ -98,7 +97,7 @@ bool MockTransport::OpenOutputChannel( bool MockTransport::OpenInputChannel( const Locator_t& locator, - TransportReceiverInterface*, + fastdds::rtps::TransportReceiverInterface*, uint32_t) { mockOpenInputChannels.push_back(locator.port); @@ -116,7 +115,6 @@ Locator_t MockTransport::RemoteToMainLocal( const Locator_t& remote) const { Locator_t mainLocal(remote); - //memset(mainLocal.address, 0x00, sizeof(mainLocal.address)); mainLocal.set_Invalid_Address(); return mainLocal; } @@ -140,12 +138,12 @@ LocatorList_t MockTransport::NormalizeLocator( } void MockTransport::select_locators( - LocatorSelector& selector) const + fastrtps::rtps::LocatorSelector& selector) const { - ResourceLimitedVector& entries = selector.transport_starts(); + fastrtps::ResourceLimitedVector& entries = selector.transport_starts(); for (size_t i = 0; i < entries.size(); ++i) { - LocatorSelectorEntry* entry = entries[i]; + fastrtps::rtps::LocatorSelectorEntry* entry = entries[i]; if (entry->transport_should_process) { for (size_t j = 0; j < entry->unicast.size(); ++j) diff --git a/test/unittest/rtps/network/mock/MockTransport.h b/test/unittest/rtps/network/mock/MockTransport.h index cf575acd6d3..358d45224f0 100644 --- a/test/unittest/rtps/network/mock/MockTransport.h +++ b/test/unittest/rtps/network/mock/MockTransport.h @@ -15,15 +15,22 @@ #ifndef MOCK_TRANSPORT_H #define MOCK_TRANSPORT_H -#include -#include #include #include +#include +#include +#include +#include + namespace eprosima { -namespace fastrtps { +namespace fastdds { namespace rtps { +using Locator_t = eprosima::fastrtps::rtps::Locator_t; +using LocatorList_t = eprosima::fastrtps::rtps::LocatorList_t; +using SenderResource = eprosima::fastrtps::rtps::SenderResource; + class MockTransportDescriptor; class MockSenderResource : public SenderResource @@ -47,7 +54,7 @@ class MockSenderResource : public SenderResource Locator_t locator_; }; -class MockTransport : public TransportInterface +class MockTransport : public fastdds::rtps::TransportInterface { public: @@ -59,7 +66,7 @@ class MockTransport : public TransportInterface ~MockTransport(); bool init( - const PropertyPolicy* properties = nullptr, + const fastrtps::rtps::PropertyPolicy* properties = nullptr, const uint32_t& max_msg_size_no_frag = 0) override; //API implementation @@ -67,12 +74,12 @@ class MockTransport : public TransportInterface const Locator_t&) const override; bool OpenOutputChannel( - SendResourceList& sender_resource_list, + fastdds::rtps::SendResourceList& sender_resource_list, const Locator_t&) override; bool OpenInputChannel( const Locator_t&, - TransportReceiverInterface*, + fastdds::rtps::TransportReceiverInterface*, uint32_t) override; bool CloseInputChannel( @@ -105,7 +112,7 @@ class MockTransport : public TransportInterface * @param [in, out] selector Locator selector. */ void select_locators( - LocatorSelector& selector) const override; + fastrtps::rtps::LocatorSelector& selector) const override; bool is_local_locator( const Locator_t&) const override @@ -118,7 +125,7 @@ class MockTransport : public TransportInterface return false; } - TransportDescriptorInterface* get_configuration() override + fastdds::rtps::TransportDescriptorInterface* get_configuration() override { return nullptr; } @@ -165,7 +172,7 @@ class MockTransport : public TransportInterface bool configureInitialPeerLocator( Locator_t&, - const PortParameters&, + const fastrtps::rtps::PortParameters&, uint32_t, LocatorList_t& ) const override { @@ -205,7 +212,7 @@ class MockTransport : public TransportInterface { Locator_t destination; Locator_t origin; - std::vector data; + std::vector data; } MockMessage; std::vector mockMessagesToReceive; @@ -224,7 +231,7 @@ class MockTransport : public TransportInterface static std::vector mockTransportInstances; }; -class MockTransportDescriptor : public SocketTransportDescriptor +class MockTransportDescriptor : public fastdds::rtps::SocketTransportDescriptor { public: @@ -235,7 +242,7 @@ class MockTransportDescriptor : public SocketTransportDescriptor int maximumChannels; int supportedKind; - TransportInterface* create_transport() const override + fastdds::rtps::TransportInterface* create_transport() const override { return new MockTransport(*this); } @@ -243,7 +250,7 @@ class MockTransportDescriptor : public SocketTransportDescriptor }; } // namespace rtps -} // namespace fastrtps +} // namespace fastdds } // namespace eprosima #endif // ifndef MOCK_TRANSPORT_H diff --git a/test/unittest/rtps/persistence/CMakeLists.txt b/test/unittest/rtps/persistence/CMakeLists.txt index 502d5404d71..eeadf5ffe1f 100644 --- a/test/unittest/rtps/persistence/CMakeLists.txt +++ b/test/unittest/rtps/persistence/CMakeLists.txt @@ -18,10 +18,6 @@ if(SQLITE3_SUPPORT) set(PERSISTENCETESTS_SOURCE PersistenceTests.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/Log.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/OStreamConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutErrConsumer.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/attributes/PropertyPolicy.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/LocatorWithMask.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/Time_t.cpp @@ -53,8 +49,10 @@ if(SQLITE3_SUPPORT) ${PROJECT_SOURCE_DIR}/src/cpp ) target_link_libraries(PersistenceTests + fastcdr + fastdds::log foonathan_memory - GTest::gmock + GTest::gmock ${CMAKE_DL_LIBS} ) if(MSVC OR MSVC_IDE) diff --git a/test/unittest/rtps/persistence/PersistenceTests.cpp b/test/unittest/rtps/persistence/PersistenceTests.cpp index 9e1ff61e15f..d76b4ba1b7b 100644 --- a/test/unittest/rtps/persistence/PersistenceTests.cpp +++ b/test/unittest/rtps/persistence/PersistenceTests.cpp @@ -12,23 +12,21 @@ // See the License for the specific language governing permissions and // limitations under the License. +#include +#include + +#include + #include +#include +#include #include #include #include #include - -#include -#include -#include - #include -#include -#include -#include - using namespace eprosima::fastrtps::rtps; class NoOpPayloadPool : public IPayloadPool diff --git a/test/unittest/rtps/reader/CMakeLists.txt b/test/unittest/rtps/reader/CMakeLists.txt index 68827d15e73..503782b447a 100644 --- a/test/unittest/rtps/reader/CMakeLists.txt +++ b/test/unittest/rtps/reader/CMakeLists.txt @@ -17,10 +17,6 @@ # WriterProxyTests ########################################################################### set(WRITERPROXYTESTS_SOURCE WriterProxyTests.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/Log.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/OStreamConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutErrConsumer.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/publisher/qos/WriterQos.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/LocatorWithMask.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/Time_t.cpp @@ -62,7 +58,10 @@ target_include_directories(WriterProxyTests PRIVATE ${PROJECT_SOURCE_DIR}/include ${PROJECT_BINARY_DIR}/include ${PROJECT_SOURCE_DIR}/src/cpp ) -target_link_libraries(WriterProxyTests foonathan_memory +target_link_libraries(WriterProxyTests + fastcdr + fastdds::log + foonathan_memory GTest::gmock ${CMAKE_DL_LIBS}) gtest_discover_tests(WriterProxyTests) @@ -71,10 +70,6 @@ gtest_discover_tests(WriterProxyTests) # WriterProxyStopTest ########################################################################### set(WRITERPROXYSTOPTEST_SOURCE WriterProxyStopTest.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/Log.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/OStreamConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutErrConsumer.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/publisher/qos/WriterQos.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/LocatorWithMask.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/Time_t.cpp @@ -118,7 +113,10 @@ target_include_directories(WriterProxyStopTest PRIVATE ${PROJECT_SOURCE_DIR}/include ${PROJECT_BINARY_DIR}/include ${PROJECT_SOURCE_DIR}/src/cpp ) -target_link_libraries(WriterProxyStopTest foonathan_memory +target_link_libraries(WriterProxyStopTest + fastcdr + fastdds::log + foonathan_memory GTest::gmock ${CMAKE_DL_LIBS}) gtest_discover_tests(WriterProxyStopTest) @@ -127,10 +125,6 @@ gtest_discover_tests(WriterProxyStopTest) # WriterProxyAcknackTests ########################################################################### set(WRITERPROXYACKNACKTESTS_SOURCE WriterProxyAcknackTests.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/Log.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/OStreamConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutErrConsumer.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/publisher/qos/WriterQos.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/LocatorWithMask.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/Time_t.cpp @@ -173,7 +167,10 @@ target_include_directories(WriterProxyAcknackTests PRIVATE ${PROJECT_SOURCE_DIR}/include ${PROJECT_BINARY_DIR}/include ${PROJECT_SOURCE_DIR}/src/cpp ) -target_link_libraries(WriterProxyAcknackTests foonathan_memory +target_link_libraries(WriterProxyAcknackTests + fastcdr + fastdds::log + foonathan_memory GTest::gmock ${CMAKE_DL_LIBS}) gtest_discover_tests(WriterProxyAcknackTests) diff --git a/test/unittest/rtps/reader/WriterProxyAcknackTests.cpp b/test/unittest/rtps/reader/WriterProxyAcknackTests.cpp index b216494eff2..e3a203f670d 100644 --- a/test/unittest/rtps/reader/WriterProxyAcknackTests.cpp +++ b/test/unittest/rtps/reader/WriterProxyAcknackTests.cpp @@ -13,19 +13,21 @@ // limitations under the License. #include +#include + #include #include -#include #define TEST_FRIENDS \ FRIEND_TEST(WriterProxyAcknackTests, AcknackBackoff); -#include +#include +#include +#include +#include + #include -#include -#include -#include -#include +#include #include diff --git a/test/unittest/rtps/reader/WriterProxyStopTest.cpp b/test/unittest/rtps/reader/WriterProxyStopTest.cpp index f587984e7ee..038382f0894 100644 --- a/test/unittest/rtps/reader/WriterProxyStopTest.cpp +++ b/test/unittest/rtps/reader/WriterProxyStopTest.cpp @@ -13,16 +13,18 @@ // limitations under the License. #include + #include #include -#include +#include +#include +#include +#include +#include + #include -#include -#include -#include -#include -#include +#include #include diff --git a/test/unittest/rtps/reader/WriterProxyTests.cpp b/test/unittest/rtps/reader/WriterProxyTests.cpp index 7d7311fdcba..649db33f020 100644 --- a/test/unittest/rtps/reader/WriterProxyTests.cpp +++ b/test/unittest/rtps/reader/WriterProxyTests.cpp @@ -21,12 +21,13 @@ FRIEND_TEST(WriterProxyTests, ReceivedChangeSet); \ FRIEND_TEST(WriterProxyTests, IrrelevantChangeSet); -#include +#include +#include +#include +#include + #include -#include -#include -#include -#include +#include #include diff --git a/test/unittest/rtps/resources/timedevent/CMakeLists.txt b/test/unittest/rtps/resources/timedevent/CMakeLists.txt index 122fe4b1dfd..b25201384ff 100644 --- a/test/unittest/rtps/resources/timedevent/CMakeLists.txt +++ b/test/unittest/rtps/resources/timedevent/CMakeLists.txt @@ -14,10 +14,6 @@ set(TIMEDEVENTTESTS_SOURCE mock/MockEvent.cpp TimedEventTests.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/Log.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/OStreamConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutErrConsumer.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/LocatorWithMask.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/Time_t.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/network/utils/netmask_filter.cpp @@ -58,5 +54,10 @@ target_include_directories(TimedEventTests PRIVATE ${PROJECT_BINARY_DIR}/include ${PROJECT_SOURCE_DIR}/src/cpp ) -target_link_libraries(TimedEventTests GTest::gtest ${CMAKE_DL_LIBS}) +target_link_libraries(TimedEventTests + fastcdr + fastdds::log + GTest::gtest + ${CMAKE_DL_LIBS} + ) gtest_discover_tests(TimedEventTests) diff --git a/test/unittest/rtps/resources/timedevent/TimedEventTests.cpp b/test/unittest/rtps/resources/timedevent/TimedEventTests.cpp index 258c629bc4f..62e11d28994 100644 --- a/test/unittest/rtps/resources/timedevent/TimedEventTests.cpp +++ b/test/unittest/rtps/resources/timedevent/TimedEventTests.cpp @@ -12,12 +12,15 @@ // See the License for the specific language governing permissions and // limitations under the License. -#include "mock/MockEvent.h" -#include -#include #include +#include + #include +#include + +#include "mock/MockEvent.h" + class TimedEventEnvironment : public ::testing::Environment { public: diff --git a/test/unittest/rtps/resources/timedevent/mock/MockEvent.h b/test/unittest/rtps/resources/timedevent/mock/MockEvent.h index 16ec04b6f35..dc00803d984 100644 --- a/test/unittest/rtps/resources/timedevent/mock/MockEvent.h +++ b/test/unittest/rtps/resources/timedevent/mock/MockEvent.h @@ -15,13 +15,14 @@ #ifndef _TEST_RTPS_RESOURCES_TIMEDEVENT_MOCKEVENT_H_ #define _TEST_RTPS_RESOURCES_TIMEDEVENT_MOCKEVENT_H_ -#include - #include #include -#include #include +#include + +#include + class MockEvent { public: diff --git a/test/unittest/rtps/security/CMakeLists.txt b/test/unittest/rtps/security/CMakeLists.txt index d0e70b5ce98..c927133ca28 100644 --- a/test/unittest/rtps/security/CMakeLists.txt +++ b/test/unittest/rtps/security/CMakeLists.txt @@ -17,10 +17,6 @@ if(WIN32) endif() set(SOURCES_SECURITY_TEST_SOURCE - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/Log.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/OStreamConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutErrConsumer.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/publisher/qos/WriterQos.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/subscriber/qos/ReaderQos.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/attributes/PropertyPolicy.cpp @@ -96,7 +92,9 @@ target_include_directories(SecurityAuthentication PRIVATE ${PROJECT_SOURCE_DIR}/include ${PROJECT_BINARY_DIR}/include ${PROJECT_SOURCE_DIR}/src/cpp ) -target_link_libraries(SecurityAuthentication fastcdr +target_link_libraries(SecurityAuthentication + fastcdr + fastdds::log GTest::gmock ${OPENSSL_LIBRARIES} ) diff --git a/test/unittest/rtps/security/SecurityTests.hpp b/test/unittest/rtps/security/SecurityTests.hpp index 852cd82145e..ccb14129f64 100644 --- a/test/unittest/rtps/security/SecurityTests.hpp +++ b/test/unittest/rtps/security/SecurityTests.hpp @@ -15,23 +15,24 @@ #ifndef __TEST_UNITTEST_RTPS_SECURITY_SECURITYTESTS_HPP__ #define __TEST_UNITTEST_RTPS_SECURITY_SECURITYTESTS_HPP__ +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include #include -#include #include #include -#include -#include -#include -#include -#include -#include -#include -#include #include -#include -#include - -#include +#include using namespace eprosima::fastrtps::rtps; using namespace eprosima::fastrtps::rtps::security; diff --git a/test/unittest/rtps/writer/CMakeLists.txt b/test/unittest/rtps/writer/CMakeLists.txt index bcc2f523a80..8011e7f35b0 100644 --- a/test/unittest/rtps/writer/CMakeLists.txt +++ b/test/unittest/rtps/writer/CMakeLists.txt @@ -14,10 +14,6 @@ # ReaderProxy set(WRITERPROXYTESTS_SOURCE ReaderProxyTests.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/Log.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/OStreamConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutErrConsumer.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/subscriber/qos/ReaderQos.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/LocatorWithMask.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/Time_t.cpp @@ -65,6 +61,7 @@ target_include_directories(ReaderProxyTests PRIVATE ) target_link_libraries(ReaderProxyTests fastcdr + fastdds::log foonathan_memory GTest::gmock ${CMAKE_DL_LIBS} @@ -72,10 +69,6 @@ target_link_libraries(ReaderProxyTests gtest_discover_tests(ReaderProxyTests) set(LIVELINESSMANAGERTESTS_SOURCE LivelinessManagerTests.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/Log.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/OStreamConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutErrConsumer.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/LocatorWithMask.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/Time_t.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/network/utils/netmask_filter.cpp @@ -106,7 +99,10 @@ target_include_directories(LivelinessManagerTests PRIVATE ${PROJECT_SOURCE_DIR}/src/cpp ) target_link_libraries(LivelinessManagerTests PRIVATE - GTest::gmock) + fastcdr + fastdds::log + GTest::gmock + ) gtest_discover_tests(LivelinessManagerTests) if(NOT QNX) @@ -121,7 +117,7 @@ if(NOT QNX) ) target_include_directories(RTPSWriterTests PRIVATE ${Asio_INCLUDE_DIR}) - target_link_libraries(RTPSWriterTests fastcdr fastrtps foonathan_memory + target_link_libraries(RTPSWriterTests fastcdr fastdds foonathan_memory GTest::gmock ${CMAKE_DL_LIBS}) gtest_discover_tests(RTPSWriterTests) diff --git a/test/unittest/rtps/writer/LivelinessManagerTests.cpp b/test/unittest/rtps/writer/LivelinessManagerTests.cpp index 03ed08ababb..05d2829fd16 100644 --- a/test/unittest/rtps/writer/LivelinessManagerTests.cpp +++ b/test/unittest/rtps/writer/LivelinessManagerTests.cpp @@ -1,4 +1,4 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// Copyright 2019 Proyectos y Sistemas de Mantenimiento SL (eProsima). // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. @@ -12,17 +12,19 @@ // See the License for the specific language governing permissions and // limitations under the License. -#include -#include +#include +#include -#include -#include -#include #include -#include -#include + +#include #include +#include +#include + +#include + class LivelinessManagerTests : public ::testing::Test { public: @@ -56,7 +58,7 @@ class LivelinessManagerTests : public ::testing::Test void liveliness_changed( eprosima::fastrtps::rtps::GUID_t guid, - const eprosima::fastrtps::LivelinessQosPolicyKind&, + const eprosima::fastdds::dds::LivelinessQosPolicyKind&, const eprosima::fastrtps::Duration_t&, int alive_change, int not_alive_change) @@ -128,19 +130,20 @@ TEST_F(LivelinessManagerTests, WriterCanAlwaysBeAdded) // Writers with same Guid, liveliness kind and lease duration cannot be added - EXPECT_EQ(liveliness_manager.add_writer(guid, AUTOMATIC_LIVELINESS_QOS, Duration_t(1)), true); + EXPECT_EQ(liveliness_manager.add_writer(guid, fastdds::dds::AUTOMATIC_LIVELINESS_QOS, Duration_t(1)), true); // Same guid and different liveliness kind can be added - EXPECT_EQ(liveliness_manager.add_writer(guid, MANUAL_BY_PARTICIPANT_LIVELINESS_QOS, Duration_t(1)), true); - EXPECT_EQ(liveliness_manager.add_writer(guid, MANUAL_BY_TOPIC_LIVELINESS_QOS, Duration_t(1)), true); + EXPECT_EQ(liveliness_manager.add_writer(guid, fastdds::dds::MANUAL_BY_PARTICIPANT_LIVELINESS_QOS, Duration_t( + 1)), true); + EXPECT_EQ(liveliness_manager.add_writer(guid, fastdds::dds::MANUAL_BY_TOPIC_LIVELINESS_QOS, Duration_t(1)), true); // Same guid and different lease duration can be added - EXPECT_EQ(liveliness_manager.add_writer(guid, AUTOMATIC_LIVELINESS_QOS, Duration_t(2)), true); - EXPECT_EQ(liveliness_manager.add_writer(guid, AUTOMATIC_LIVELINESS_QOS, Duration_t(3)), true); - EXPECT_EQ(liveliness_manager.add_writer(guid, AUTOMATIC_LIVELINESS_QOS, Duration_t(4)), true); + EXPECT_EQ(liveliness_manager.add_writer(guid, fastdds::dds::AUTOMATIC_LIVELINESS_QOS, Duration_t(2)), true); + EXPECT_EQ(liveliness_manager.add_writer(guid, fastdds::dds::AUTOMATIC_LIVELINESS_QOS, Duration_t(3)), true); + EXPECT_EQ(liveliness_manager.add_writer(guid, fastdds::dds::AUTOMATIC_LIVELINESS_QOS, Duration_t(4)), true); // Same guid, same kind, and same lease duration can also be added - EXPECT_EQ(liveliness_manager.add_writer(guid, AUTOMATIC_LIVELINESS_QOS, Duration_t(1)), true); + EXPECT_EQ(liveliness_manager.add_writer(guid, fastdds::dds::AUTOMATIC_LIVELINESS_QOS, Duration_t(1)), true); } TEST_F(LivelinessManagerTests, WriterCannotBeRemovedTwice) @@ -153,17 +156,22 @@ TEST_F(LivelinessManagerTests, WriterCannotBeRemovedTwice) guidP.value[0] = 1; GUID_t guid(guidP, 0); - EXPECT_EQ(liveliness_manager.add_writer(guid, AUTOMATIC_LIVELINESS_QOS, Duration_t(1)), true); - EXPECT_EQ(liveliness_manager.remove_writer(guid, AUTOMATIC_LIVELINESS_QOS, Duration_t(1)), true); - EXPECT_EQ(liveliness_manager.remove_writer(guid, AUTOMATIC_LIVELINESS_QOS, Duration_t(1)), false); - - EXPECT_EQ(liveliness_manager.add_writer(guid, MANUAL_BY_PARTICIPANT_LIVELINESS_QOS, Duration_t(1)), true); - EXPECT_EQ(liveliness_manager.remove_writer(guid, MANUAL_BY_PARTICIPANT_LIVELINESS_QOS, Duration_t(1)), true); - EXPECT_EQ(liveliness_manager.remove_writer(guid, MANUAL_BY_PARTICIPANT_LIVELINESS_QOS, Duration_t(1)), false); - - EXPECT_EQ(liveliness_manager.add_writer(guid, MANUAL_BY_TOPIC_LIVELINESS_QOS, Duration_t(1)), true); - EXPECT_EQ(liveliness_manager.remove_writer(guid, MANUAL_BY_TOPIC_LIVELINESS_QOS, Duration_t(1)), true); - EXPECT_EQ(liveliness_manager.remove_writer(guid, MANUAL_BY_TOPIC_LIVELINESS_QOS, Duration_t(1)), false); + EXPECT_EQ(liveliness_manager.add_writer(guid, fastdds::dds::AUTOMATIC_LIVELINESS_QOS, Duration_t(1)), true); + EXPECT_EQ(liveliness_manager.remove_writer(guid, fastdds::dds::AUTOMATIC_LIVELINESS_QOS, Duration_t(1)), true); + EXPECT_EQ(liveliness_manager.remove_writer(guid, fastdds::dds::AUTOMATIC_LIVELINESS_QOS, Duration_t(1)), false); + + EXPECT_EQ(liveliness_manager.add_writer(guid, fastdds::dds::MANUAL_BY_PARTICIPANT_LIVELINESS_QOS, Duration_t( + 1)), true); + EXPECT_EQ(liveliness_manager.remove_writer(guid, fastdds::dds::MANUAL_BY_PARTICIPANT_LIVELINESS_QOS, Duration_t( + 1)), true); + EXPECT_EQ(liveliness_manager.remove_writer(guid, fastdds::dds::MANUAL_BY_PARTICIPANT_LIVELINESS_QOS, Duration_t( + 1)), false); + + EXPECT_EQ(liveliness_manager.add_writer(guid, fastdds::dds::MANUAL_BY_TOPIC_LIVELINESS_QOS, Duration_t(1)), true); + EXPECT_EQ(liveliness_manager.remove_writer(guid, fastdds::dds::MANUAL_BY_TOPIC_LIVELINESS_QOS, Duration_t(1)), + true); + EXPECT_EQ(liveliness_manager.remove_writer(guid, fastdds::dds::MANUAL_BY_TOPIC_LIVELINESS_QOS, Duration_t(1)), + false); } //! Tests that the assert_liveliness() method that takes liveliness kind as argument sets the alive state and time @@ -177,15 +185,15 @@ TEST_F(LivelinessManagerTests, AssertLivelinessByKind) GuidPrefix_t guidP; guidP.value[0] = 1; - liveliness_manager.add_writer(GUID_t(guidP, 1), AUTOMATIC_LIVELINESS_QOS, Duration_t(10)); - liveliness_manager.add_writer(GUID_t(guidP, 2), AUTOMATIC_LIVELINESS_QOS, Duration_t(10)); - liveliness_manager.add_writer(GUID_t(guidP, 3), MANUAL_BY_PARTICIPANT_LIVELINESS_QOS, Duration_t(10)); - liveliness_manager.add_writer(GUID_t(guidP, 4), MANUAL_BY_PARTICIPANT_LIVELINESS_QOS, Duration_t(10)); - liveliness_manager.add_writer(GUID_t(guidP, 5), MANUAL_BY_TOPIC_LIVELINESS_QOS, Duration_t(10)); - liveliness_manager.add_writer(GUID_t(guidP, 6), MANUAL_BY_TOPIC_LIVELINESS_QOS, Duration_t(10)); + liveliness_manager.add_writer(GUID_t(guidP, 1), fastdds::dds::AUTOMATIC_LIVELINESS_QOS, Duration_t(10)); + liveliness_manager.add_writer(GUID_t(guidP, 2), fastdds::dds::AUTOMATIC_LIVELINESS_QOS, Duration_t(10)); + liveliness_manager.add_writer(GUID_t(guidP, 3), fastdds::dds::MANUAL_BY_PARTICIPANT_LIVELINESS_QOS, Duration_t(10)); + liveliness_manager.add_writer(GUID_t(guidP, 4), fastdds::dds::MANUAL_BY_PARTICIPANT_LIVELINESS_QOS, Duration_t(10)); + liveliness_manager.add_writer(GUID_t(guidP, 5), fastdds::dds::MANUAL_BY_TOPIC_LIVELINESS_QOS, Duration_t(10)); + liveliness_manager.add_writer(GUID_t(guidP, 6), fastdds::dds::MANUAL_BY_TOPIC_LIVELINESS_QOS, Duration_t(10)); // Assert liveliness of automatic writers (the rest should be unchanged) - EXPECT_TRUE(liveliness_manager.assert_liveliness(AUTOMATIC_LIVELINESS_QOS, guidP)); + EXPECT_TRUE(liveliness_manager.assert_liveliness(fastdds::dds::AUTOMATIC_LIVELINESS_QOS, guidP)); auto liveliness_data = liveliness_manager.get_liveliness_data(); EXPECT_EQ(liveliness_data[0].status, LivelinessData::WriterStatus::ALIVE); EXPECT_EQ(liveliness_data[1].status, LivelinessData::WriterStatus::ALIVE); @@ -195,7 +203,7 @@ TEST_F(LivelinessManagerTests, AssertLivelinessByKind) EXPECT_EQ(liveliness_data[5].status, LivelinessData::WriterStatus::NOT_ASSERTED); // Assert liveliness of manual by participant writers - EXPECT_TRUE(liveliness_manager.assert_liveliness(MANUAL_BY_PARTICIPANT_LIVELINESS_QOS, guidP)); + EXPECT_TRUE(liveliness_manager.assert_liveliness(fastdds::dds::MANUAL_BY_PARTICIPANT_LIVELINESS_QOS, guidP)); liveliness_data = liveliness_manager.get_liveliness_data(); EXPECT_EQ(liveliness_data[0].status, LivelinessData::WriterStatus::ALIVE); EXPECT_EQ(liveliness_data[1].status, LivelinessData::WriterStatus::ALIVE); @@ -205,7 +213,7 @@ TEST_F(LivelinessManagerTests, AssertLivelinessByKind) EXPECT_EQ(liveliness_data[5].status, LivelinessData::WriterStatus::NOT_ASSERTED); // Assert liveliness of manual by topic writers - EXPECT_TRUE(liveliness_manager.assert_liveliness(MANUAL_BY_TOPIC_LIVELINESS_QOS, guidP)); + EXPECT_TRUE(liveliness_manager.assert_liveliness(fastdds::dds::MANUAL_BY_TOPIC_LIVELINESS_QOS, guidP)); liveliness_data = liveliness_manager.get_liveliness_data(); EXPECT_EQ(liveliness_data[0].status, LivelinessData::WriterStatus::ALIVE); EXPECT_EQ(liveliness_data[1].status, LivelinessData::WriterStatus::ALIVE); @@ -233,17 +241,17 @@ TEST_F(LivelinessManagerTests, AssertLivelinessByWriter) GuidPrefix_t guidP; guidP.value[0] = 1; - liveliness_manager.add_writer(GUID_t(guidP, 1), AUTOMATIC_LIVELINESS_QOS, Duration_t(1)); - liveliness_manager.add_writer(GUID_t(guidP, 2), AUTOMATIC_LIVELINESS_QOS, Duration_t(1)); - liveliness_manager.add_writer(GUID_t(guidP, 3), MANUAL_BY_PARTICIPANT_LIVELINESS_QOS, Duration_t(1)); - liveliness_manager.add_writer(GUID_t(guidP, 4), MANUAL_BY_PARTICIPANT_LIVELINESS_QOS, Duration_t(1)); - liveliness_manager.add_writer(GUID_t(guidP, 5), MANUAL_BY_TOPIC_LIVELINESS_QOS, Duration_t(1)); - liveliness_manager.add_writer(GUID_t(guidP, 6), MANUAL_BY_TOPIC_LIVELINESS_QOS, Duration_t(1)); + liveliness_manager.add_writer(GUID_t(guidP, 1), fastdds::dds::AUTOMATIC_LIVELINESS_QOS, Duration_t(1)); + liveliness_manager.add_writer(GUID_t(guidP, 2), fastdds::dds::AUTOMATIC_LIVELINESS_QOS, Duration_t(1)); + liveliness_manager.add_writer(GUID_t(guidP, 3), fastdds::dds::MANUAL_BY_PARTICIPANT_LIVELINESS_QOS, Duration_t(1)); + liveliness_manager.add_writer(GUID_t(guidP, 4), fastdds::dds::MANUAL_BY_PARTICIPANT_LIVELINESS_QOS, Duration_t(1)); + liveliness_manager.add_writer(GUID_t(guidP, 5), fastdds::dds::MANUAL_BY_TOPIC_LIVELINESS_QOS, Duration_t(1)); + liveliness_manager.add_writer(GUID_t(guidP, 6), fastdds::dds::MANUAL_BY_TOPIC_LIVELINESS_QOS, Duration_t(1)); // If a manual by topic writer is asserted the other writers are unchanged EXPECT_TRUE(liveliness_manager.assert_liveliness( GUID_t(guidP, 6), - MANUAL_BY_TOPIC_LIVELINESS_QOS, + fastdds::dds::MANUAL_BY_TOPIC_LIVELINESS_QOS, Duration_t(1))); auto liveliness_data = liveliness_manager.get_liveliness_data(); EXPECT_EQ(liveliness_data[0].status, LivelinessData::WriterStatus::NOT_ASSERTED); @@ -255,7 +263,7 @@ TEST_F(LivelinessManagerTests, AssertLivelinessByWriter) EXPECT_TRUE(liveliness_manager.assert_liveliness( GUID_t(guidP, 5), - MANUAL_BY_TOPIC_LIVELINESS_QOS, + fastdds::dds::MANUAL_BY_TOPIC_LIVELINESS_QOS, Duration_t(1))); liveliness_data = liveliness_manager.get_liveliness_data(); EXPECT_EQ(liveliness_data[0].status, LivelinessData::WriterStatus::NOT_ASSERTED); @@ -268,7 +276,7 @@ TEST_F(LivelinessManagerTests, AssertLivelinessByWriter) // If an automatic writer is asserted all automatic writers are asserted as well EXPECT_TRUE(liveliness_manager.assert_liveliness( GUID_t(guidP, 1), - AUTOMATIC_LIVELINESS_QOS, + fastdds::dds::AUTOMATIC_LIVELINESS_QOS, Duration_t(1))); liveliness_data = liveliness_manager.get_liveliness_data(); EXPECT_EQ(liveliness_data[0].status, LivelinessData::WriterStatus::ALIVE); @@ -281,7 +289,7 @@ TEST_F(LivelinessManagerTests, AssertLivelinessByWriter) // If a manual by participant writer is asserted all manual by participant writers are asserted as well EXPECT_TRUE(liveliness_manager.assert_liveliness( GUID_t(guidP, 4), - MANUAL_BY_PARTICIPANT_LIVELINESS_QOS, + fastdds::dds::MANUAL_BY_PARTICIPANT_LIVELINESS_QOS, Duration_t(1))); liveliness_data = liveliness_manager.get_liveliness_data(); EXPECT_EQ(liveliness_data[0].status, LivelinessData::WriterStatus::ALIVE); @@ -317,11 +325,11 @@ TEST_F(LivelinessManagerTests, TimerExpired_Automatic) GuidPrefix_t guidP; guidP.value[0] = 1; - liveliness_manager.add_writer(GUID_t(guidP, 1), AUTOMATIC_LIVELINESS_QOS, Duration_t(0.1)); - liveliness_manager.add_writer(GUID_t(guidP, 2), AUTOMATIC_LIVELINESS_QOS, Duration_t(0.5)); + liveliness_manager.add_writer(GUID_t(guidP, 1), fastdds::dds::AUTOMATIC_LIVELINESS_QOS, Duration_t(0.1)); + liveliness_manager.add_writer(GUID_t(guidP, 2), fastdds::dds::AUTOMATIC_LIVELINESS_QOS, Duration_t(0.5)); // Assert liveliness - liveliness_manager.assert_liveliness(GUID_t(guidP, 2), AUTOMATIC_LIVELINESS_QOS, Duration_t(0.5)); + liveliness_manager.assert_liveliness(GUID_t(guidP, 2), fastdds::dds::AUTOMATIC_LIVELINESS_QOS, Duration_t(0.5)); num_writers_recovered = 0u; // Wait so that first writer loses liveliness @@ -333,7 +341,7 @@ TEST_F(LivelinessManagerTests, TimerExpired_Automatic) EXPECT_EQ(writer_losing_liveliness, GUID_t(guidP, 2)); // Assert first writer - liveliness_manager.assert_liveliness(GUID_t(guidP, 1), AUTOMATIC_LIVELINESS_QOS, Duration_t(0.1)); + liveliness_manager.assert_liveliness(GUID_t(guidP, 1), fastdds::dds::AUTOMATIC_LIVELINESS_QOS, Duration_t(0.1)); wait_liveliness_recovered(2u); EXPECT_EQ(num_writers_recovered, 2u); } @@ -356,11 +364,15 @@ TEST_F(LivelinessManagerTests, TimerExpired_ManualByParticipant) GuidPrefix_t guidP; guidP.value[0] = 1; - liveliness_manager.add_writer(GUID_t(guidP, 1), MANUAL_BY_PARTICIPANT_LIVELINESS_QOS, Duration_t(0.1)); - liveliness_manager.add_writer(GUID_t(guidP, 2), MANUAL_BY_PARTICIPANT_LIVELINESS_QOS, Duration_t(0.5)); + liveliness_manager.add_writer(GUID_t(guidP, 1), fastdds::dds::MANUAL_BY_PARTICIPANT_LIVELINESS_QOS, + Duration_t(0.1)); + liveliness_manager.add_writer(GUID_t(guidP, 2), fastdds::dds::MANUAL_BY_PARTICIPANT_LIVELINESS_QOS, + Duration_t(0.5)); // Assert liveliness - liveliness_manager.assert_liveliness(GUID_t(guidP, 2), MANUAL_BY_PARTICIPANT_LIVELINESS_QOS, Duration_t(0.5)); + liveliness_manager.assert_liveliness(GUID_t(guidP, + 2), fastdds::dds::MANUAL_BY_PARTICIPANT_LIVELINESS_QOS, + Duration_t(0.5)); num_writers_recovered = 0u; // Wait so that first writer loses liveliness @@ -374,7 +386,9 @@ TEST_F(LivelinessManagerTests, TimerExpired_ManualByParticipant) EXPECT_EQ(num_writers_lost, 2u); // Assert first writer - liveliness_manager.assert_liveliness(GUID_t(guidP, 1), MANUAL_BY_PARTICIPANT_LIVELINESS_QOS, Duration_t(0.1)); + liveliness_manager.assert_liveliness(GUID_t(guidP, + 1), fastdds::dds::MANUAL_BY_PARTICIPANT_LIVELINESS_QOS, + Duration_t(0.1)); wait_liveliness_recovered(2u); EXPECT_EQ(num_writers_recovered, 2u); } @@ -397,11 +411,12 @@ TEST_F(LivelinessManagerTests, TimerExpired_ManualByTopic) GuidPrefix_t guidP; guidP.value[0] = 1; - liveliness_manager.add_writer(GUID_t(guidP, 1), MANUAL_BY_TOPIC_LIVELINESS_QOS, Duration_t(0.1)); - liveliness_manager.add_writer(GUID_t(guidP, 2), MANUAL_BY_TOPIC_LIVELINESS_QOS, Duration_t(0.2)); + liveliness_manager.add_writer(GUID_t(guidP, 1), fastdds::dds::MANUAL_BY_TOPIC_LIVELINESS_QOS, Duration_t(0.1)); + liveliness_manager.add_writer(GUID_t(guidP, 2), fastdds::dds::MANUAL_BY_TOPIC_LIVELINESS_QOS, Duration_t(0.2)); // Assert first writer - liveliness_manager.assert_liveliness(GUID_t(guidP, 1), MANUAL_BY_TOPIC_LIVELINESS_QOS, Duration_t(0.1)); + liveliness_manager.assert_liveliness(GUID_t(guidP, 1), fastdds::dds::MANUAL_BY_TOPIC_LIVELINESS_QOS, + Duration_t(0.1)); wait_liveliness_recovered(1u); // Wait so that first writer loses liveliness @@ -415,7 +430,8 @@ TEST_F(LivelinessManagerTests, TimerExpired_ManualByTopic) EXPECT_EQ(num_writers_lost, 1u); // Assert second writer - liveliness_manager.assert_liveliness(GUID_t(guidP, 2), MANUAL_BY_TOPIC_LIVELINESS_QOS, Duration_t(0.2)); + liveliness_manager.assert_liveliness(GUID_t(guidP, 2), fastdds::dds::MANUAL_BY_TOPIC_LIVELINESS_QOS, + Duration_t(0.2)); wait_liveliness_recovered(2u); num_writers_lost = 0u; @@ -443,11 +459,11 @@ TEST_F(LivelinessManagerTests, TimerOwnerCalculation) GuidPrefix_t guidP; guidP.value[0] = 1; - liveliness_manager.add_writer(GUID_t(guidP, 1), AUTOMATIC_LIVELINESS_QOS, Duration_t(100 * 1e-3)); - liveliness_manager.add_writer(GUID_t(guidP, 2), AUTOMATIC_LIVELINESS_QOS, Duration_t(1000 * 1e-3)); - liveliness_manager.add_writer(GUID_t(guidP, 3), AUTOMATIC_LIVELINESS_QOS, Duration_t(500 * 1e-3)); + liveliness_manager.add_writer(GUID_t(guidP, 1), fastdds::dds::AUTOMATIC_LIVELINESS_QOS, Duration_t(100 * 1e-3)); + liveliness_manager.add_writer(GUID_t(guidP, 2), fastdds::dds::AUTOMATIC_LIVELINESS_QOS, Duration_t(1000 * 1e-3)); + liveliness_manager.add_writer(GUID_t(guidP, 3), fastdds::dds::AUTOMATIC_LIVELINESS_QOS, Duration_t(500 * 1e-3)); - liveliness_manager.assert_liveliness(AUTOMATIC_LIVELINESS_QOS, guidP); + liveliness_manager.assert_liveliness(fastdds::dds::AUTOMATIC_LIVELINESS_QOS, guidP); wait_liveliness_lost(1u); EXPECT_EQ(writer_losing_liveliness, GUID_t(guidP, 1)); @@ -480,11 +496,11 @@ TEST_F(LivelinessManagerTests, TimerOwnerRemoved) GuidPrefix_t guidP; guidP.value[0] = 1; - liveliness_manager.add_writer(GUID_t(guidP, 1), AUTOMATIC_LIVELINESS_QOS, Duration_t(0.5)); - liveliness_manager.add_writer(GUID_t(guidP, 2), AUTOMATIC_LIVELINESS_QOS, Duration_t(1)); + liveliness_manager.add_writer(GUID_t(guidP, 1), fastdds::dds::AUTOMATIC_LIVELINESS_QOS, Duration_t(0.5)); + liveliness_manager.add_writer(GUID_t(guidP, 2), fastdds::dds::AUTOMATIC_LIVELINESS_QOS, Duration_t(1)); - liveliness_manager.assert_liveliness(GUID_t(guidP, 1), AUTOMATIC_LIVELINESS_QOS, Duration_t(0.5)); - liveliness_manager.remove_writer(GUID_t(guidP, 1), AUTOMATIC_LIVELINESS_QOS, Duration_t(0.5)); + liveliness_manager.assert_liveliness(GUID_t(guidP, 1), fastdds::dds::AUTOMATIC_LIVELINESS_QOS, Duration_t(0.5)); + liveliness_manager.remove_writer(GUID_t(guidP, 1), fastdds::dds::AUTOMATIC_LIVELINESS_QOS, Duration_t(0.5)); wait_liveliness_lost(1u); EXPECT_EQ(writer_losing_liveliness, GUID_t(guidP, 2)); diff --git a/test/unittest/rtps/writer/ReaderProxyTests.cpp b/test/unittest/rtps/writer/ReaderProxyTests.cpp index bb6d0bee937..e92d8473710 100644 --- a/test/unittest/rtps/writer/ReaderProxyTests.cpp +++ b/test/unittest/rtps/writer/ReaderProxyTests.cpp @@ -15,8 +15,9 @@ #include #include -#include -#include +#include +#include + #include //using namespace eprosima::fastrtps::rtps; @@ -128,7 +129,7 @@ TEST(ReaderProxyTests, requested_changes_set_test) RTPSGapBuilder gap_builder(message_group); ReaderProxyData reader_attributes(0, 0); - reader_attributes.m_qos.m_reliability.kind = RELIABLE_RELIABILITY_QOS; + reader_attributes.m_qos.m_reliability.kind = fastdds::dds::RELIABLE_RELIABILITY_QOS; rproxy.start(reader_attributes); @@ -188,7 +189,7 @@ TEST(ReaderProxyTests, process_nack_frag_single_fragment_different_windows_test) RTPSGapBuilder gap_builder(message_group); ReaderProxyData reader_attributes(0, 0); - reader_attributes.m_qos.m_reliability.kind = RELIABLE_RELIABILITY_QOS; + reader_attributes.m_qos.m_reliability.kind = fastdds::dds::RELIABLE_RELIABILITY_QOS; rproxy.start(reader_attributes); ChangeForReader_t change(&seq); @@ -257,7 +258,7 @@ TEST(ReaderProxyTests, process_nack_frag_multiple_fragments_different_windows_te RTPSGapBuilder gap_builder(message_group); ReaderProxyData reader_attributes(0, 0); - reader_attributes.m_qos.m_reliability.kind = RELIABLE_RELIABILITY_QOS; + reader_attributes.m_qos.m_reliability.kind = fastdds::dds::RELIABLE_RELIABILITY_QOS; rproxy.start(reader_attributes); ChangeForReader_t change(&seq); @@ -346,7 +347,7 @@ TEST(ReaderProxyTests, has_been_delivered_test) seq2.sequenceNumber = {0, 2}; ReaderProxyData reader_attributes(0, 0); - reader_attributes.m_qos.m_reliability.kind = RELIABLE_RELIABILITY_QOS; + reader_attributes.m_qos.m_reliability.kind = fastdds::dds::RELIABLE_RELIABILITY_QOS; rproxy.start(reader_attributes); auto expect_result = [&rproxy](SequenceNumber_t seq, bool delivered, bool should_be_found) @@ -392,7 +393,7 @@ TEST(ReaderProxyTests, acknack_count) ReaderProxy rproxy(w_times, alloc, &writer_mock); ReaderProxyData reader_attributes(0, 0); - reader_attributes.m_qos.m_reliability.kind = RELIABLE_RELIABILITY_QOS; + reader_attributes.m_qos.m_reliability.kind = eprosima::fastdds::dds::RELIABLE_RELIABILITY_QOS; rproxy.start(reader_attributes); // Check that the initial acknack count is 0. diff --git a/test/unittest/security/accesscontrol/AccessControlTests.cpp b/test/unittest/security/accesscontrol/AccessControlTests.cpp index 3cd39972e31..afdfe5c4f51 100644 --- a/test/unittest/security/accesscontrol/AccessControlTests.cpp +++ b/test/unittest/security/accesscontrol/AccessControlTests.cpp @@ -12,22 +12,21 @@ // See the License for the specific language governing permissions and // limitations under the License. -#include +#include + +#include -#include -#include -#include +#include +#include +#include +#include -#include +#include +#include #include -#include #include -#include -#include - -#include - -#include +#include +#include using namespace eprosima::fastrtps::rtps; using namespace eprosima::fastrtps::rtps::security; @@ -230,7 +229,7 @@ void AccessControlTest::check_remote_datareader( SecurityException exception; ReaderProxyData reader_proxy_data(1, 1); - reader_proxy_data.topicName(eprosima::fastrtps::string_255(topic_name)); + reader_proxy_data.topicName(eprosima::fastcdr::string_255(topic_name)); reader_proxy_data.m_qos.m_partition.setNames(partitions); bool relay_only; bool result = access_plugin.check_remote_datareader( @@ -288,7 +287,7 @@ void AccessControlTest::check_remote_datawriter( SecurityException exception; WriterProxyData writer_proxy_data(1, 1); - writer_proxy_data.topicName(eprosima::fastrtps::string_255(topic_name)); + writer_proxy_data.topicName(eprosima::fastcdr::string_255(topic_name)); writer_proxy_data.m_qos.m_partition.setNames(partitions); bool result = access_plugin.check_remote_datawriter( *access_handle, diff --git a/test/unittest/security/accesscontrol/CMakeLists.txt b/test/unittest/security/accesscontrol/CMakeLists.txt index 1ece99f44da..fe0a56d91d6 100644 --- a/test/unittest/security/accesscontrol/CMakeLists.txt +++ b/test/unittest/security/accesscontrol/CMakeLists.txt @@ -16,15 +16,12 @@ if(WIN32) add_definitions( -D_WIN32_WINNT=0x0601 -D_CRT_SECURE_NO_WARNINGS + -DNOMINMAX ) endif() set(COMMON_SOURCES_ACCESS_CONTROL_TEST_SOURCE ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/core/policy/ParameterList.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/Log.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/OStreamConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutErrConsumer.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/attributes/PropertyPolicy.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/LocatorWithMask.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/Time_t.cpp @@ -101,6 +98,7 @@ target_link_libraries(AccessControlTests GTest::gmock ${OPENSSL_LIBRARIES} fastcdr + fastdds::log foonathan_memory $<$:ws2_32> ${TINYXML2_LIBRARY} @@ -128,12 +126,6 @@ set( add_executable( ${DISTINGUISHEDNAME_TEST_NAME} - # Log related files - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/Log.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/OStreamConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutErrConsumer.cpp - # src files ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/LocatorWithMask.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/Time_t.cpp @@ -145,6 +137,7 @@ add_executable( ${PROJECT_SOURCE_DIR}/src/cpp/security/accesscontrol/DistinguishedName.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/IPFinder.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/IPLocator.cpp + # Log related files ${PROJECT_SOURCE_DIR}/src/cpp/utils/SystemInfo.cpp # test files @@ -169,8 +162,9 @@ target_include_directories( ${PROJECT_SOURCE_DIR}/src/cpp ) -target_link_libraries( - ${DISTINGUISHEDNAME_TEST_NAME} +target_link_libraries(${DISTINGUISHEDNAME_TEST_NAME} + fastcdr + fastdds::log GTest::gtest ) diff --git a/test/unittest/security/authentication/AuthenticationPluginTests.hpp b/test/unittest/security/authentication/AuthenticationPluginTests.hpp index 95087dd4d85..31482ae88aa 100644 --- a/test/unittest/security/authentication/AuthenticationPluginTests.hpp +++ b/test/unittest/security/authentication/AuthenticationPluginTests.hpp @@ -15,17 +15,16 @@ #ifndef _UNITTEST_SECURITY_AUTHENTICATION_AUTHENTICATIONPLUGINTESTS_HPP_ #define _UNITTEST_SECURITY_AUTHENTICATION_AUTHENTICATIONPLUGINTESTS_HPP_ -#include -#include +#include // Include first necessary mocks -#include -#include -#include - #include +#include +#include +#include -#include +#include +#include class AuthenticationPluginTest : public ::testing::Test { diff --git a/test/unittest/security/authentication/BuiltinPKIDHTests.cpp b/test/unittest/security/authentication/BuiltinPKIDHTests.cpp index 14a8d2301ab..37622e782f1 100644 --- a/test/unittest/security/authentication/BuiltinPKIDHTests.cpp +++ b/test/unittest/security/authentication/BuiltinPKIDHTests.cpp @@ -16,13 +16,15 @@ // suppresses the warnings until true OpenSSL 3.0 APIs can be used. #define OPENSSL_API_COMPAT 10101 -#include "AuthenticationPluginTests.hpp" +#include +#include +#include -#include -#include -#include +#include -#include +#include "AuthenticationPluginTests.hpp" +#include +#include #if OPENSSL_VERSION_NUMBER >= 0x10100000L #define IS_OPENSSL_1_1 1 @@ -30,9 +32,6 @@ #define IS_OPENSSL_1_1 0 #endif // if OPENSSL_VERSION_NUMBER >= 0x10100000L -#include -#include - using namespace eprosima::fastrtps::rtps; using namespace eprosima::fastrtps::rtps::security; diff --git a/test/unittest/security/authentication/CMakeLists.txt b/test/unittest/security/authentication/CMakeLists.txt index b03767f0723..e896ba3d77b 100644 --- a/test/unittest/security/authentication/CMakeLists.txt +++ b/test/unittest/security/authentication/CMakeLists.txt @@ -16,15 +16,12 @@ if(WIN32) add_definitions( -D_WIN32_WINNT=0x0601 -D_CRT_SECURE_NO_WARNINGS + -DNOMINMAX ) endif() set(COMMON_SOURCES_AUTH_PLUGIN_TEST_SOURCE ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/core/policy/ParameterList.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/Log.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/OStreamConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutErrConsumer.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/attributes/PropertyPolicy.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/builtin/data/ParticipantProxyData.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/GuidPrefix_t.cpp @@ -75,6 +72,7 @@ target_link_libraries(BuiltinPKIDH GTest::gtest ${OPENSSL_LIBRARIES} fastcdr + fastdds::log foonathan_memory $<$:ws2_32> $<$:eProsima_p11> # $ diff --git a/test/unittest/security/cryptography/CMakeLists.txt b/test/unittest/security/cryptography/CMakeLists.txt index f353b295f69..4e5bc2508e2 100644 --- a/test/unittest/security/cryptography/CMakeLists.txt +++ b/test/unittest/security/cryptography/CMakeLists.txt @@ -17,10 +17,6 @@ if(WIN32) endif() set(COMMON_SOURCES_CRYPTO_PLUGIN_TEST_SOURCE - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/Log.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/OStreamConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutErrConsumer.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/attributes/PropertyPolicy.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/LocatorWithMask.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/Time_t.cpp @@ -63,7 +59,12 @@ target_include_directories(BuiltinAESGCMGMAC PRIVATE ${PROJECT_SOURCE_DIR}/src/cpp ) -target_link_libraries(BuiltinAESGCMGMAC fastcdr GTest::gmock ${OPENSSL_LIBRARIES}) +target_link_libraries(BuiltinAESGCMGMAC + fastcdr + fastdds::log + GTest::gmock + ${OPENSSL_LIBRARIES} + ) gtest_discover_tests(BuiltinAESGCMGMAC SOURCES ${COMMON_SOURCES_CRYPTO_PLUGIN_TEST_SOURCE} PROPERTIES ENVIRONMENT "CERTS_PATH=${PROJECT_SOURCE_DIR}/test/certs") diff --git a/test/unittest/security/cryptography/CryptographyPluginTests.hpp b/test/unittest/security/cryptography/CryptographyPluginTests.hpp index 8e7f7487572..43b3a109cee 100644 --- a/test/unittest/security/cryptography/CryptographyPluginTests.hpp +++ b/test/unittest/security/cryptography/CryptographyPluginTests.hpp @@ -15,18 +15,19 @@ #ifndef _UNITTEST_SECURITY_CRYPTOGRAPHY_CRYPTOGRAPHYPLUGINTESTS_HPP_ #define _UNITTEST_SECURITY_CRYPTOGRAPHY_CRYPTOGRAPHYPLUGINTESTS_HPP_ -#include -#include -#include -#include - -#include -#include +#include +#include #include #include -#include -#include + +#include + +#include +#include +#include +#include +#include class CryptographyPluginTest : public ::testing::Test { diff --git a/test/unittest/security/logging/CMakeLists.txt b/test/unittest/security/logging/CMakeLists.txt index fa218fa762b..5e6d9b02922 100644 --- a/test/unittest/security/logging/CMakeLists.txt +++ b/test/unittest/security/logging/CMakeLists.txt @@ -17,10 +17,6 @@ if(WIN32) endif() set(COMMON_SOURCES_LOGGING_PLUGIN_TEST_SOURCE - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/Log.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/OStreamConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutErrConsumer.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/attributes/PropertyPolicy.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/LocatorWithMask.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/Time_t.cpp @@ -53,5 +49,10 @@ target_include_directories(BuiltinLogging PRIVATE ${PROJECT_SOURCE_DIR}/include ${PROJECT_BINARY_DIR}/include ${PROJECT_SOURCE_DIR}/src/cpp ) -target_link_libraries(BuiltinLogging fastcdr GTest::gtest ${OPENSSL_LIBRARIES}) +target_link_libraries(BuiltinLogging + fastcdr + fastdds::log + GTest::gtest + ${OPENSSL_LIBRARIES} + ) gtest_discover_tests(BuiltinLogging) diff --git a/test/unittest/statistics/dds/CMakeLists.txt b/test/unittest/statistics/dds/CMakeLists.txt index 511a6f821fd..e4d949d7051 100644 --- a/test/unittest/statistics/dds/CMakeLists.txt +++ b/test/unittest/statistics/dds/CMakeLists.txt @@ -25,12 +25,11 @@ endif(TINYXML2_INCLUDE_DIR) ## StatisticsDomainParticipantTests set(STATISTICS_DOMAINPARTICIPANT_TESTS_SOURCE StatisticsDomainParticipantTests.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/typesPubSubTypes.cxx - ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/types.cxx - ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/typesv1.cxx ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/monitorservice_typesPubSubTypes.cxx - ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/monitorservice_types.cxx - ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/monitorservice_typesv1.cxx) + ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/monitorservice_typesTypeObjectSupport.cxx + ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/typesPubSubTypes.cxx + ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/typesTypeObjectSupport.cxx + ) add_executable(StatisticsDomainParticipantTests ${STATISTICS_DOMAINPARTICIPANT_TESTS_SOURCE}) target_compile_definitions(StatisticsDomainParticipantTests PRIVATE @@ -39,7 +38,11 @@ target_compile_definitions(StatisticsDomainParticipantTests PRIVATE ) target_include_directories(StatisticsDomainParticipantTests PRIVATE ${PROJECT_SOURCE_DIR}/include ${PROJECT_BINARY_DIR}/include ${PROJECT_SOURCE_DIR}/src/cpp) -target_link_libraries(StatisticsDomainParticipantTests fastrtps fastcdr GTest::gtest) +target_link_libraries(StatisticsDomainParticipantTests + fastcdr + fastdds + GTest::gtest + ) gtest_discover_tests(StatisticsDomainParticipantTests) ## StatisticsQosTests @@ -63,7 +66,12 @@ target_compile_definitions(StatisticsQosTests PRIVATE BOOST_ASIO_STANDALONE ASIO ) target_include_directories(StatisticsQosTests PRIVATE ${PROJECT_SOURCE_DIR}/include ${PROJECT_BINARY_DIR}/include ${PROJECT_SOURCE_DIR}/src/cpp ${THIRDPARTY_BOOST_INCLUDE_DIR}) -target_link_libraries(StatisticsQosTests fastrtps fastcdr ${TINYXML2_LIBRARY} foonathan_memory GTest::gtest) +target_link_libraries(StatisticsQosTests + fastcdr + fastdds + foonathan_memory + ${TINYXML2_LIBRARY} + GTest::gtest) gtest_discover_tests(StatisticsQosTests) ## StatisticsDomainParticipantListenerTests @@ -72,29 +80,43 @@ if (FASTDDS_STATISTICS) DomainParticipantStatisticsListenerTests.cpp) add_executable(DomainParticipantStatisticsListenerTests + ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/topic/TopicDataType.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/rtps/attributes/ThreadSettings.cpp ${PROJECT_SOURCE_DIR}/src/cpp/statistics/fastdds/domain/DomainParticipantStatisticsListener.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/typesPubSubTypes.cxx - ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/types.cxx - ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/typesv1.cxx ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/monitorservice_typesPubSubTypes.cxx - ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/monitorservice_types.cxx - ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/monitorservice_typesv1.cxx - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/topic/TopicDataType.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/monitorservice_typesTypeObjectSupport.cxx + ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/typesPubSubTypes.cxx + ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/typesTypeObjectSupport.cxx + ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/LocatorWithMask.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/Time_t.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/rtps/network/utils/network.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/utils/IPFinder.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/utils/IPLocator.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/md5.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/utils/SystemInfo.cpp ${TINYXML2_SOURCES} ${DOMAINPARTICIPANTSTATISTICSLISTENER_TESTS_SOURCE}) target_compile_definitions(DomainParticipantStatisticsListenerTests PRIVATE + BOOST_ASIO_STANDALONE + ASIO_STANDALONE $<$>,$>:__DEBUG> $<$:__INTERNAL_DEBUG> # Internal debug activated. ) target_include_directories(DomainParticipantStatisticsListenerTests PRIVATE + ${Asio_INCLUDE_DIR} DomainParticipantStatisticsListenerTests/mock + ${PROJECT_SOURCE_DIR}/test/mock/dds/DomainParticipantFactory/ + ${PROJECT_SOURCE_DIR}/test/mock/rtps/RTPSDomainImpl/ ${PROJECT_SOURCE_DIR}/include ${PROJECT_BINARY_DIR}/include ${PROJECT_SOURCE_DIR}/src/cpp) target_link_libraries(DomainParticipantStatisticsListenerTests - ${TINYXML2_LIBRARY} fastcdr GTest::gmock ) + ${TINYXML2_LIBRARY} + fastcdr + fastdds::log + fastdds::xtypes::type-representation + GTest::gmock + ) gtest_discover_tests(DomainParticipantStatisticsListenerTests) endif() @@ -103,34 +125,13 @@ if (SQLITE3_SUPPORT AND FASTDDS_STATISTICS AND NOT QNX) # this test includes C sources enable_language(C) - set(STATISTICS_DOMAINPARTICIPANT_MOCK_TESTS_SOURCE + file(GLOB STATISTICS_DOMAINPARTICIPANT_MOCK_TESTS_SOURCE StatisticsDomainParticipantMockTests.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/AnnotationDescriptor.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/AnnotationParameterValue.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/BuiltinAnnotationsTypeObject.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicData.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicDataFactory.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicPubSubType.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicType.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeBuilder.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeBuilderFactory.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeBuilderPtr.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeMember.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypePtr.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/MemberDescriptor.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeDescriptor.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeIdentifier.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeIdentifierTypes.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeNamesGenerator.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeObject.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeObjectFactory.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeObjectHashId.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypesBase.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/builtin/common/RPCHeadersImpl.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/builtin/typelookup/common/TypeLookupTypes.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/builtin/typelookup/TypeLookupManager.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/builtin/typelookup/TypeLookupReplyListener.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/builtin/typelookup/TypeLookupRequestListener.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/builtin/type_lookup_service/detail/rpc_typesPubSubTypes.cxx + ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/builtin/type_lookup_service/detail/TypeLookupTypesPubSubTypes.cxx + ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/builtin/type_lookup_service/TypeLookupManager.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/builtin/type_lookup_service/TypeLookupReplyListener.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/builtin/type_lookup_service/TypeLookupRequestListener.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/core/condition/Condition.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/core/condition/ConditionNotifier.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/core/condition/StatusCondition.cpp @@ -275,12 +276,6 @@ if (SQLITE3_SUPPORT AND FASTDDS_STATISTICS AND NOT QNX) ${PROJECT_SOURCE_DIR}/src/cpp/rtps/writer/StatefulWriter.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/writer/StatelessPersistentWriter.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/writer/StatelessWriter.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/xmlparser/XMLDynamicParser.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/xmlparser/XMLElementParser.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/xmlparser/XMLEndpointParser.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/xmlparser/XMLParser.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/xmlparser/XMLParserCommon.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/xmlparser/XMLProfileManager.cpp ${PROJECT_SOURCE_DIR}/src/cpp/statistics/fastdds/domain/DomainParticipant.cpp ${PROJECT_SOURCE_DIR}/src/cpp/statistics/fastdds/domain/DomainParticipantImpl.cpp ${PROJECT_SOURCE_DIR}/src/cpp/statistics/fastdds/domain/DomainParticipantStatisticsListener.cpp @@ -290,12 +285,10 @@ if (SQLITE3_SUPPORT AND FASTDDS_STATISTICS AND NOT QNX) ${PROJECT_SOURCE_DIR}/src/cpp/statistics/rtps/reader/StatisticsReaderImpl.cpp ${PROJECT_SOURCE_DIR}/src/cpp/statistics/rtps/StatisticsBase.cpp ${PROJECT_SOURCE_DIR}/src/cpp/statistics/rtps/writer/StatisticsWriterImpl.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/monitorservice_types.cxx ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/monitorservice_typesPubSubTypes.cxx - ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/monitorservice_typesv1.cxx - ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/types.cxx + ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/monitorservice_typesTypeObjectSupport.cxx ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/typesPubSubTypes.cxx - ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/typesv1.cxx + ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/typesTypeObjectSupport.cxx ${PROJECT_SOURCE_DIR}/src/cpp/utils/IPFinder.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/IPLocator.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/md5.cpp @@ -304,36 +297,22 @@ if (SQLITE3_SUPPORT AND FASTDDS_STATISTICS AND NOT QNX) ${PROJECT_SOURCE_DIR}/src/cpp/utils/SystemInfo.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/TimedConditionVariable.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/UnitsParser.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/xmlparser/XMLDynamicParser.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/xmlparser/XMLElementParser.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/xmlparser/XMLEndpointParser.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/xmlparser/XMLParser.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/xmlparser/XMLParserCommon.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/xmlparser/XMLProfileManager.cpp ) set(STATISTICS_DOMAINPARTICIPANT_STATUS_QUERYABLE_TESTS_SOURCE StatisticsDomainParticipantStatusQueryableTests.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/AnnotationDescriptor.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/AnnotationParameterValue.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/BuiltinAnnotationsTypeObject.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicData.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicDataFactory.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicPubSubType.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicType.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeBuilder.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeBuilderFactory.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeBuilderPtr.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeMember.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypePtr.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/MemberDescriptor.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeDescriptor.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeIdentifier.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeIdentifierTypes.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeNamesGenerator.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeObject.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeObjectFactory.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeObjectHashId.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypesBase.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/builtin/common/RPCHeadersImpl.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/builtin/typelookup/common/TypeLookupTypes.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/builtin/typelookup/TypeLookupManager.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/builtin/typelookup/TypeLookupReplyListener.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/builtin/typelookup/TypeLookupRequestListener.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/builtin/type_lookup_service/detail/rpc_typesPubSubTypes.cxx + ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/builtin/type_lookup_service/detail/TypeLookupTypesPubSubTypes.cxx + ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/builtin/type_lookup_service/TypeLookupManager.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/builtin/type_lookup_service/TypeLookupReplyListener.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/builtin/type_lookup_service/TypeLookupRequestListener.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/core/Entity.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/core/condition/Condition.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/core/condition/ConditionNotifier.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/core/condition/StatusCondition.cpp @@ -342,16 +321,10 @@ if (SQLITE3_SUPPORT AND FASTDDS_STATISTICS AND NOT QNX) ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/core/Entity.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/core/policy/ParameterList.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/core/policy/QosPolicyUtils.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/core/policy/QosPolicyUtils.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/domain/DomainParticipant.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/domain/DomainParticipantFactory.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/domain/qos/DomainParticipantFactoryQos.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/domain/qos/DomainParticipantQos.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/FileConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/Log.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/OStreamConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutErrConsumer.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/publisher/DataWriter.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/publisher/DataWriterHistory.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/publisher/PublisherImpl.cpp @@ -476,12 +449,6 @@ if (SQLITE3_SUPPORT AND FASTDDS_STATISTICS AND NOT QNX) ${PROJECT_SOURCE_DIR}/src/cpp/rtps/writer/StatefulWriter.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/writer/StatelessPersistentWriter.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/writer/StatelessWriter.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/xmlparser/XMLDynamicParser.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/xmlparser/XMLElementParser.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/xmlparser/XMLEndpointParser.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/xmlparser/XMLParser.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/xmlparser/XMLParserCommon.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/xmlparser/XMLProfileManager.cpp ${PROJECT_SOURCE_DIR}/src/cpp/statistics/fastdds/domain/DomainParticipant.cpp ${PROJECT_SOURCE_DIR}/src/cpp/statistics/fastdds/domain/DomainParticipantImpl.cpp ${PROJECT_SOURCE_DIR}/src/cpp/statistics/fastdds/domain/DomainParticipantStatisticsListener.cpp @@ -490,14 +457,11 @@ if (SQLITE3_SUPPORT AND FASTDDS_STATISTICS AND NOT QNX) ${PROJECT_SOURCE_DIR}/src/cpp/statistics/rtps/monitor-service/MonitorServiceListener.cpp ${PROJECT_SOURCE_DIR}/src/cpp/statistics/rtps/reader/StatisticsReaderImpl.cpp ${PROJECT_SOURCE_DIR}/src/cpp/statistics/rtps/StatisticsBase.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/statistics/rtps/StatisticsBase.cpp ${PROJECT_SOURCE_DIR}/src/cpp/statistics/rtps/writer/StatisticsWriterImpl.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/monitorservice_types.cxx ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/monitorservice_typesPubSubTypes.cxx - ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/monitorservice_typesv1.cxx - ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/types.cxx + ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/monitorservice_typesTypeObjectSupport.cxx ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/typesPubSubTypes.cxx - ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/typesv1.cxx + ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/typesTypeObjectSupport.cxx ${PROJECT_SOURCE_DIR}/src/cpp/utils/IPFinder.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/IPLocator.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/md5.cpp @@ -506,6 +470,12 @@ if (SQLITE3_SUPPORT AND FASTDDS_STATISTICS AND NOT QNX) ${PROJECT_SOURCE_DIR}/src/cpp/utils/SystemInfo.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/TimedConditionVariable.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/UnitsParser.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/xmlparser/XMLDynamicParser.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/xmlparser/XMLElementParser.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/xmlparser/XMLEndpointParser.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/xmlparser/XMLParser.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/xmlparser/XMLParserCommon.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/xmlparser/XMLProfileManager.cpp ) # SHM Transport @@ -532,79 +502,43 @@ if (SQLITE3_SUPPORT AND FASTDDS_STATISTICS AND NOT QNX) # Security Support if(SECURITY) - list(APPEND STATISTICS_DOMAINPARTICIPANT_MOCK_TESTS_SOURCE + file(GLOB security_sources ${PROJECT_SOURCE_DIR}/src/cpp/rtps/exceptions/Exception.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/Token.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/security/exceptions/SecurityException.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/security/common/SharedSecretHandle.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/security/logging/Logging.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/security/SecurityManager.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/security/SecurityPluginFactory.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/rtps/security/*.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/builtin/discovery/participant/DS/PDPSecurityInitiatorListener.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/security/artifact_providers/FileProvider.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/security/artifact_providers/Pkcs11Provider.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/security/authentication/PKIDH.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/security/accesscontrol/Permissions.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/security/accesscontrol/DistinguishedName.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/security/cryptography/AESGCMGMAC.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/security/cryptography/AESGCMGMAC_KeyExchange.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/security/cryptography/AESGCMGMAC_KeyFactory.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/security/cryptography/AESGCMGMAC_Transform.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/security/cryptography/AESGCMGMAC_Types.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/security/authentication/PKIIdentityHandle.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/security/authentication/PKIHandshakeHandle.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/security/accesscontrol/AccessPermissionsHandle.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/security/accesscontrol/CommonParser.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/security/accesscontrol/GovernanceParser.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/security/accesscontrol/PermissionsParser.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/security/logging/LogTopic.cpp - ) - list(APPEND STATISTICS_DOMAINPARTICIPANT_STATUS_QUERYABLE_TESTS_SOURCE - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/exceptions/Exception.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/Token.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/security/exceptions/SecurityException.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/security/common/SharedSecretHandle.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/security/logging/Logging.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/security/SecurityManager.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/security/SecurityPluginFactory.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/builtin/discovery/participant/DS/PDPSecurityInitiatorListener.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/security/artifact_providers/FileProvider.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/security/artifact_providers/Pkcs11Provider.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/security/authentication/PKIDH.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/security/accesscontrol/Permissions.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/security/accesscontrol/DistinguishedName.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/security/cryptography/AESGCMGMAC.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/security/cryptography/AESGCMGMAC_KeyExchange.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/security/cryptography/AESGCMGMAC_KeyFactory.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/security/cryptography/AESGCMGMAC_Transform.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/security/cryptography/AESGCMGMAC_Types.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/security/authentication/PKIIdentityHandle.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/security/authentication/PKIHandshakeHandle.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/security/accesscontrol/AccessPermissionsHandle.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/security/accesscontrol/CommonParser.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/security/accesscontrol/GovernanceParser.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/security/accesscontrol/PermissionsParser.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/security/logging/LogTopic.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/security/accesscontrol/*.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/security/artifact_providers/*.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/security/authentication/*.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/security/cryptography/*.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/security/logging/*.cpp ) + list(APPEND STATISTICS_DOMAINPARTICIPANT_MOCK_TESTS_SOURCE ${security_sources}) + list(APPEND STATISTICS_DOMAINPARTICIPANT_STATUS_QUERYABLE_TESTS_SOURCE ${security_sources}) endif() # External sources if(TINYXML2_SOURCE_DIR) list(APPEND STATISTICS_DOMAINPARTICIPANT_MOCK_TESTS_SOURCE - ${TINYXML2_SOURCE_DIR}/tinyxml2.cpp + ${TINYXML2_SOURCES} ) list(APPEND STATISTICS_DOMAINPARTICIPANT_STATUS_QUERYABLE_TESTS_SOURCE ${TINYXML2_SOURCE_DIR}/tinyxml2.cpp ) endif() - add_executable(StatisticsDomainParticipantMockTests ${STATISTICS_DOMAINPARTICIPANT_MOCK_TESTS_SOURCE}) + add_executable(StatisticsDomainParticipantMockTests + ${STATISTICS_DOMAINPARTICIPANT_MOCK_TESTS_SOURCE} + ) target_compile_definitions(StatisticsDomainParticipantMockTests PRIVATE BOOST_ASIO_STANDALONE ASIO_STANDALONE SQLITE_WIN32_GETVERSIONEX=0 $<$>,$>:__DEBUG> - $<$:__INTERNALDEBUG> # Internal debug activated. + $<$:__INTERNAL_DEBUG> # Internal debug activated. $<$,$>:_WIN32_WINNT=0x0603> $<$,$>>:_WIN32_WINNT=0x0601> $<$,$>:SQLITE_OS_WINRT> @@ -616,7 +550,7 @@ if (SQLITE3_SUPPORT AND FASTDDS_STATISTICS AND NOT QNX) ) target_include_directories(StatisticsDomainParticipantMockTests PRIVATE $<$:${OPENSSL_INCLUDE_DIR}> - StatisticsDomainParticipantMockTests/mock/ + StatisticsDomainParticipantMockTests/mock ${PROJECT_SOURCE_DIR}/test/mock/dds/Publisher/ ${PROJECT_SOURCE_DIR}/test/mock/dds/DomainParticipantImpl/ ${PROJECT_SOURCE_DIR}/include @@ -626,6 +560,9 @@ if (SQLITE3_SUPPORT AND FASTDDS_STATISTICS AND NOT QNX) ${THIRDPARTY_BOOST_INCLUDE_DIR}) target_link_libraries(StatisticsDomainParticipantMockTests ${PRIVACY} fastcdr + fastdds::log + fastdds::xtypes::dynamic-types::impl + fastdds::xtypes::type-representation foonathan_memory GTest::gmock ${CMAKE_DL_LIBS} @@ -644,7 +581,7 @@ if (SQLITE3_SUPPORT AND FASTDDS_STATISTICS AND NOT QNX) gtest_discover_tests(StatisticsDomainParticipantMockTests) add_executable(StatisticsDomainParticipantStatusQueryableTests ${STATISTICS_DOMAINPARTICIPANT_STATUS_QUERYABLE_TESTS_SOURCE}) - target_compile_definitions(StatisticsDomainParticipantStatusQueryableTests PRIVATE FASTRTPS_NO_LIB + target_compile_definitions(StatisticsDomainParticipantStatusQueryableTests PRIVATE FASTDDS_NO_LIB BOOST_ASIO_STANDALONE ASIO_STANDALONE SQLITE_WIN32_GETVERSIONEX=0 @@ -672,6 +609,9 @@ if (SQLITE3_SUPPORT AND FASTDDS_STATISTICS AND NOT QNX) ${THIRDPARTY_BOOST_INCLUDE_DIR}) target_link_libraries(StatisticsDomainParticipantStatusQueryableTests ${PRIVACY} fastcdr + fastdds::log + fastdds::xtypes::dynamic-types::impl + fastdds::xtypes::type-representation foonathan_memory GTest::gmock ${CMAKE_DL_LIBS} diff --git a/test/unittest/statistics/dds/DomainParticipantStatisticsListenerTests.cpp b/test/unittest/statistics/dds/DomainParticipantStatisticsListenerTests.cpp index 553ab7d2b98..7475d19bed1 100644 --- a/test/unittest/statistics/dds/DomainParticipantStatisticsListenerTests.cpp +++ b/test/unittest/statistics/dds/DomainParticipantStatisticsListenerTests.cpp @@ -20,7 +20,7 @@ #include #include -#include +#include namespace eprosima { namespace fastdds { @@ -134,7 +134,7 @@ class DomainParticipantStatisticsListenerTests : public ::testing::Test } void write_all_data_except( - EventKind kind) + uint32_t kind) { for (const Data& data : data_) { @@ -156,25 +156,25 @@ class DomainParticipantStatisticsListenerTests : public ::testing::Test std::array, 17> writers_; std::array data_to_check_; std::array data_; - std::array kinds_ = + std::array kinds_ = { - EventKindBits::HISTORY2HISTORY_LATENCY, - EventKindBits::NETWORK_LATENCY, - EventKindBits::PUBLICATION_THROUGHPUT, - EventKindBits::SUBSCRIPTION_THROUGHPUT, - EventKindBits::RTPS_SENT, - EventKindBits::RTPS_LOST, - EventKindBits::RESENT_DATAS, - EventKindBits::HEARTBEAT_COUNT, - EventKindBits::ACKNACK_COUNT, - EventKindBits::NACKFRAG_COUNT, - EventKindBits::GAP_COUNT, - EventKindBits::DATA_COUNT, - EventKindBits::PDP_PACKETS, - EventKindBits::EDP_PACKETS, - EventKindBits::DISCOVERED_ENTITY, - EventKindBits::SAMPLE_DATAS, - EventKindBits::PHYSICAL_DATA + EventKind::HISTORY2HISTORY_LATENCY, + EventKind::NETWORK_LATENCY, + EventKind::PUBLICATION_THROUGHPUT, + EventKind::SUBSCRIPTION_THROUGHPUT, + EventKind::RTPS_SENT, + EventKind::RTPS_LOST, + EventKind::RESENT_DATAS, + EventKind::HEARTBEAT_COUNT, + EventKind::ACKNACK_COUNT, + EventKind::NACKFRAG_COUNT, + EventKind::GAP_COUNT, + EventKind::DATA_COUNT, + EventKind::PDP_PACKETS, + EventKind::EDP_PACKETS, + EventKind::DISCOVERED_ENTITY, + EventKind::SAMPLE_DATAS, + EventKind::PHYSICAL_DATA }; DomainParticipantStatisticsListener listener_; diff --git a/test/unittest/statistics/dds/DomainParticipantStatisticsListenerTests/mock/fastdds/dds/publisher/DataWriter.hpp b/test/unittest/statistics/dds/DomainParticipantStatisticsListenerTests/mock/fastdds/dds/publisher/DataWriter.hpp index 0fc0cff7f28..fc7e092503a 100644 --- a/test/unittest/statistics/dds/DomainParticipantStatisticsListenerTests/mock/fastdds/dds/publisher/DataWriter.hpp +++ b/test/unittest/statistics/dds/DomainParticipantStatisticsListenerTests/mock/fastdds/dds/publisher/DataWriter.hpp @@ -21,10 +21,18 @@ #include +#include +#include +#include + namespace eprosima { namespace fastdds { namespace dds { +class DataWriterImpl; +class Publisher; +class Topic; + class DataWriter { public: diff --git a/test/unittest/statistics/dds/StatisticsDomainParticipantMockTests.cpp b/test/unittest/statistics/dds/StatisticsDomainParticipantMockTests.cpp index 88c0399fa36..b276d4611d1 100644 --- a/test/unittest/statistics/dds/StatisticsDomainParticipantMockTests.cpp +++ b/test/unittest/statistics/dds/StatisticsDomainParticipantMockTests.cpp @@ -14,6 +14,8 @@ #include #include + +#include #include #include #include @@ -21,15 +23,12 @@ #include #include #include -#include #include #include #include #include "../../logging/mock/MockConsumer.h" -using eprosima::fastrtps::types::ReturnCode_t; - namespace eprosima { namespace fastdds { namespace statistics { @@ -77,7 +76,7 @@ class DomainParticipantTest : public eprosima::fastdds::dds::DomainParticipant }; /** - * This test checks that enable_statistics_datawriter fails returning RETCODE_ERROR when create_datawriter fails + * This test checks that enable_statistics_datawriter fails returning eprosima::fastdds::dds::RETCODE_ERROR when create_datawriter fails * returning a nullptr. * 1. Create participant * 2. Mock create_datawriter so it returns nullptr @@ -116,7 +115,8 @@ TEST_F(StatisticsDomainParticipantMockTests, EnableStatisticsDataWriterFailureCr EXPECT_CALL(*builtin_pub_impl, create_datawriter_mock()).WillOnce(testing::Return(true)); // 3. enable_statistics_datawriter - EXPECT_EQ(ReturnCode_t::RETCODE_ERROR, statistics_participant->enable_statistics_datawriter(HEARTBEAT_COUNT_TOPIC, + EXPECT_EQ(fastdds::dds::RETCODE_ERROR, + statistics_participant->enable_statistics_datawriter(HEARTBEAT_COUNT_TOPIC, STATISTICS_DATAWRITER_QOS)); EXPECT_EQ(nullptr, statistics_participant->lookup_topicdescription(HEARTBEAT_COUNT_TOPIC)); EXPECT_EQ(null_type, statistics_participant->find_type(count_type.get_type_name())); @@ -127,12 +127,12 @@ TEST_F(StatisticsDomainParticipantMockTests, EnableStatisticsDataWriterFailureCr EXPECT_EQ(consumed_entries.size(), 1u); EXPECT_EQ(eprosima::fastdds::dds::DomainParticipantFactory::get_instance()-> - delete_participant(participant), ReturnCode_t::RETCODE_OK); + delete_participant(participant), fastdds::dds::RETCODE_OK); #endif // FASTDDS_STATISTICS } /** - * This test checks that disable_statistics_datawriter fails returning RETCODE_ERROR when delete_datawriter fails. + * This test checks that disable_statistics_datawriter fails returning eprosima::fastdds::dds::RETCODE_ERROR when delete_datawriter fails. * 1. Create a participant * 2. Mock delete_datawriter * 3. Enable a statistics datawriter @@ -168,29 +168,30 @@ TEST_F(StatisticsDomainParticipantMockTests, DisableStatisticsDataWriterFailureD // 3. enable_statistics_datawriter EXPECT_CALL(*builtin_pub_impl, create_datawriter_mock()).WillOnce(testing::Return(false)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, statistics_participant->enable_statistics_datawriter(HEARTBEAT_COUNT_TOPIC, + EXPECT_EQ(fastdds::dds::RETCODE_OK, + statistics_participant->enable_statistics_datawriter(HEARTBEAT_COUNT_TOPIC, STATISTICS_DATAWRITER_QOS)); // 4. disable_statistics_datawriter - EXPECT_EQ(ReturnCode_t::RETCODE_ERROR, statistics_participant->disable_statistics_datawriter( + EXPECT_EQ(fastdds::dds::RETCODE_ERROR, statistics_participant->disable_statistics_datawriter( HEARTBEAT_COUNT_TOPIC)); EXPECT_NE(nullptr, statistics_participant->lookup_topicdescription(HEARTBEAT_COUNT_TOPIC)); EXPECT_TRUE(count_type == statistics_participant->find_type(count_type.get_type_name())); EXPECT_CALL(*builtin_pub, delete_datawriter_mock()).WillOnce(testing::Return(false)); EXPECT_CALL(*statistics_participant_impl_test, delete_topic_mock()).WillOnce(testing::Return(false)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, statistics_participant->disable_statistics_datawriter( + EXPECT_EQ(fastdds::dds::RETCODE_OK, statistics_participant->disable_statistics_datawriter( HEARTBEAT_COUNT_TOPIC)); EXPECT_EQ(nullptr, statistics_participant->lookup_topicdescription(HEARTBEAT_COUNT_TOPIC)); EXPECT_EQ(null_type, statistics_participant->find_type(count_type.get_type_name())); EXPECT_EQ(eprosima::fastdds::dds::DomainParticipantFactory::get_instance()-> - delete_participant(statistics_participant), ReturnCode_t::RETCODE_OK); + delete_participant(statistics_participant), fastdds::dds::RETCODE_OK); #endif // FASTDDS_STATISTICS } /** - * This test checks that disable_statistics_datawriter fails returning RETCODE_ERROR when delete_topic fails. + * This test checks that disable_statistics_datawriter fails returning eprosima::fastdds::dds::RETCODE_ERROR when delete_topic fails. * 1. Create a participant * 2. Mock delete_topic * 3. Enable a statistics datawriter @@ -223,24 +224,25 @@ TEST_F(StatisticsDomainParticipantMockTests, DisableStatisticsDataWriterFailureD // 3. enable_statistics_datawriter EXPECT_CALL(*builtin_pub_impl, create_datawriter_mock()).WillOnce(testing::Return(false)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, statistics_participant->enable_statistics_datawriter(HEARTBEAT_COUNT_TOPIC, + EXPECT_EQ(fastdds::dds::RETCODE_OK, + statistics_participant->enable_statistics_datawriter(HEARTBEAT_COUNT_TOPIC, STATISTICS_DATAWRITER_QOS)); EXPECT_NE(nullptr, statistics_participant->lookup_topicdescription(HEARTBEAT_COUNT_TOPIC)); // 4. disable_statistics_datawriter - EXPECT_EQ(ReturnCode_t::RETCODE_ERROR, statistics_participant->disable_statistics_datawriter( + EXPECT_EQ(fastdds::dds::RETCODE_ERROR, statistics_participant->disable_statistics_datawriter( HEARTBEAT_COUNT_TOPIC)); EXPECT_NE(nullptr, statistics_participant->lookup_topicdescription(HEARTBEAT_COUNT_TOPIC)); // As the DataWriter has been deleted, the topic has to be removed manually EXPECT_CALL(*statistics_participant_impl_test, delete_topic_mock()).WillOnce(testing::Return(false)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, statistics_participant->delete_topic( + EXPECT_EQ(fastdds::dds::RETCODE_OK, statistics_participant->delete_topic( dynamic_cast(statistics_participant->lookup_topicdescription( HEARTBEAT_COUNT_TOPIC)))); EXPECT_EQ(nullptr, statistics_participant->lookup_topicdescription(HEARTBEAT_COUNT_TOPIC)); EXPECT_EQ(eprosima::fastdds::dds::DomainParticipantFactory::get_instance()-> - delete_participant(statistics_participant), ReturnCode_t::RETCODE_OK); + delete_participant(statistics_participant), fastdds::dds::RETCODE_OK); #endif // FASTDDS_STATISTICS } diff --git a/test/unittest/statistics/dds/StatisticsDomainParticipantStatusQueryableTests.cpp b/test/unittest/statistics/dds/StatisticsDomainParticipantStatusQueryableTests.cpp index e9c3dec1e3f..e5b5bc30bb7 100644 --- a/test/unittest/statistics/dds/StatisticsDomainParticipantStatusQueryableTests.cpp +++ b/test/unittest/statistics/dds/StatisticsDomainParticipantStatusQueryableTests.cpp @@ -22,15 +22,12 @@ #include #include #include -#include #include #include #include #include "../../logging/mock/MockConsumer.h" -using eprosima::fastrtps::types::ReturnCode_t; - constexpr const char* TEST_TOPIC = "test_topic"; class TopicDataTypeMock : public eprosima::fastdds::dds::TopicDataType diff --git a/test/unittest/statistics/dds/StatisticsDomainParticipantStatusQueryableTests/mock/fastdds/publisher/DataWriterImpl.hpp b/test/unittest/statistics/dds/StatisticsDomainParticipantStatusQueryableTests/mock/fastdds/publisher/DataWriterImpl.hpp index e6036a05b00..ca7b6c59787 100644 --- a/test/unittest/statistics/dds/StatisticsDomainParticipantStatusQueryableTests/mock/fastdds/publisher/DataWriterImpl.hpp +++ b/test/unittest/statistics/dds/StatisticsDomainParticipantStatusQueryableTests/mock/fastdds/publisher/DataWriterImpl.hpp @@ -16,40 +16,34 @@ * @file DataWriterImpl.hpp */ -#ifndef _FASTRTPS_DATAWRITERIMPL_HPP_ -#define _FASTRTPS_DATAWRITERIMPL_HPP_ +#ifndef _FASTDDS_DATAWRITERIMPL_HPP_ +#define _FASTDDS_DATAWRITERIMPL_HPP_ #include +#include #include +#include #include #include #include #include #include #include - +#include +#include #include -#include #include +#include #include #include #include #include #include -#include -#include - -#include - -#include -#include - #include -#include #include - +#include namespace eprosima { namespace fastrtps { @@ -151,25 +145,25 @@ class DataWriterImpl : protected rtps::IReaderDataFilter virtual ReturnCode_t enable() { - return ReturnCode_t::RETCODE_OK; + return RETCODE_OK; } ReturnCode_t check_delete_preconditions() { - return ReturnCode_t::RETCODE_OK; + return RETCODE_OK; } ReturnCode_t loan_sample( void*&, LoanInitializationKind ) { - return ReturnCode_t::RETCODE_OK; + return RETCODE_OK; } ReturnCode_t discard_loan( void*& ) { - return ReturnCode_t::RETCODE_OK; + return RETCODE_OK; } bool write( @@ -189,7 +183,7 @@ class DataWriterImpl : protected rtps::IReaderDataFilter void*, const InstanceHandle_t& ) { - return ReturnCode_t::RETCODE_OK; + return RETCODE_OK; } ReturnCode_t write_w_timestamp( @@ -197,7 +191,7 @@ class DataWriterImpl : protected rtps::IReaderDataFilter const InstanceHandle_t&, const fastrtps::Time_t& ) { - return ReturnCode_t::RETCODE_OK; + return RETCODE_OK; } InstanceHandle_t register_instance( @@ -218,7 +212,7 @@ class DataWriterImpl : protected rtps::IReaderDataFilter const InstanceHandle_t&, bool = false) { - return ReturnCode_t::RETCODE_OK; + return RETCODE_OK; } ReturnCode_t unregister_instance_w_timestamp( @@ -227,7 +221,7 @@ class DataWriterImpl : protected rtps::IReaderDataFilter const fastrtps::Time_t&, bool = false) { - return ReturnCode_t::RETCODE_OK; + return RETCODE_OK; } void gen_guid() @@ -257,7 +251,7 @@ class DataWriterImpl : protected rtps::IReaderDataFilter ReturnCode_t wait_for_acknowledgments( const fastrtps::Duration_t& ) { - return ReturnCode_t::RETCODE_OK; + return RETCODE_OK; } ReturnCode_t wait_for_acknowledgments( @@ -265,33 +259,33 @@ class DataWriterImpl : protected rtps::IReaderDataFilter const InstanceHandle_t&, const fastrtps::Duration_t& ) { - return ReturnCode_t::RETCODE_OK; + return RETCODE_OK; } ReturnCode_t get_publication_matched_status( PublicationMatchedStatus&) { - return ReturnCode_t::RETCODE_OK; + return RETCODE_OK; } ReturnCode_t get_offered_deadline_missed_status( - fastrtps::OfferedDeadlineMissedStatus& status) + OfferedDeadlineMissedStatus& status) { status = deadline_missed_status_; - return ReturnCode_t::RETCODE_OK; + return RETCODE_OK; } ReturnCode_t get_offered_incompatible_qos_status( OfferedIncompatibleQosStatus& status) { status = offered_incompatible_qos_status_; - return ReturnCode_t::RETCODE_OK; + return RETCODE_OK; } ReturnCode_t set_qos( const DataWriterQos&) { - return ReturnCode_t::RETCODE_OK; + return RETCODE_OK; } const DataWriterQos& get_qos() const @@ -312,21 +306,21 @@ class DataWriterImpl : protected rtps::IReaderDataFilter ReturnCode_t set_listener( DataWriterListener*) { - return ReturnCode_t::RETCODE_OK; + return RETCODE_OK; } ReturnCode_t get_key_value( void*, const InstanceHandle_t& ) { - return ReturnCode_t::RETCODE_OK; + return RETCODE_OK; } ReturnCode_t get_liveliness_lost_status( LivelinessLostStatus& status) { status = liveliness_lost_status_; - return ReturnCode_t::RETCODE_OK; + return RETCODE_OK; } const Publisher* get_publisher() const @@ -342,7 +336,7 @@ class DataWriterImpl : protected rtps::IReaderDataFilter ReturnCode_t assert_liveliness() { - return ReturnCode_t::RETCODE_OK; + return RETCODE_OK; } virtual void disable() @@ -353,13 +347,13 @@ class DataWriterImpl : protected rtps::IReaderDataFilter ReturnCode_t clear_history( size_t*) { - return ReturnCode_t::RETCODE_OK; + return RETCODE_OK; } ReturnCode_t get_sending_locators( rtps::LocatorList&) const { - return ReturnCode_t::RETCODE_OK; + return RETCODE_OK; } void filter_is_being_removed( @@ -411,14 +405,14 @@ class DataWriterImpl : protected rtps::IReaderDataFilter static ReturnCode_t check_qos( const ::eprosima::fastdds::dds::DataWriterQos&) { - return ReturnCode_t::RETCODE_OK; + return RETCODE_OK; } static ReturnCode_t check_qos_including_resource_limits( const DataWriterQos&, const TypeSupport& ) { - return fastrtps::types::ReturnCode_t::RETCODE_OK; + return RETCODE_OK; } static void set_qos( @@ -451,4 +445,4 @@ class DataWriterImpl : protected rtps::IReaderDataFilter } /* namespace fastdds */ } /* namespace eprosima */ -#endif //_FASTRTPS_DATAWRITERIMPL_HPP_ +#endif //_FASTDDS_DATAWRITERIMPL_HPP_ diff --git a/test/unittest/statistics/dds/StatisticsDomainParticipantStatusQueryableTests/mock/statistics/fastdds/publisher/DataWriterImpl.hpp b/test/unittest/statistics/dds/StatisticsDomainParticipantStatusQueryableTests/mock/statistics/fastdds/publisher/DataWriterImpl.hpp index f56e0b3326b..7fb59c56b26 100644 --- a/test/unittest/statistics/dds/StatisticsDomainParticipantStatusQueryableTests/mock/statistics/fastdds/publisher/DataWriterImpl.hpp +++ b/test/unittest/statistics/dds/StatisticsDomainParticipantStatusQueryableTests/mock/statistics/fastdds/publisher/DataWriterImpl.hpp @@ -65,9 +65,9 @@ class DataWriterImpl : public efd::DataWriterImpl { } - ReturnCode_t enable() override + efd::ReturnCode_t enable() override { - return fastrtps::types::ReturnCode_t::RETCODE_OK; + return efd::RETCODE_OK; } void disable() override diff --git a/test/unittest/statistics/dds/StatisticsDomainParticipantStatusQueryableTests/mock/statistics/fastdds/publisher/PublisherImpl.hpp b/test/unittest/statistics/dds/StatisticsDomainParticipantStatusQueryableTests/mock/statistics/fastdds/publisher/PublisherImpl.hpp index 69e0f445156..6b5f3e54759 100644 --- a/test/unittest/statistics/dds/StatisticsDomainParticipantStatusQueryableTests/mock/statistics/fastdds/publisher/PublisherImpl.hpp +++ b/test/unittest/statistics/dds/StatisticsDomainParticipantStatusQueryableTests/mock/statistics/fastdds/publisher/PublisherImpl.hpp @@ -116,7 +116,7 @@ class PublisherImpl : public efd::PublisherImpl return retcode; } - ReturnCode_t delete_datawriters() + efd::ReturnCode_t delete_datawriters() { std::unique_lock lock(mtx_writers_); @@ -131,7 +131,7 @@ class PublisherImpl : public efd::PublisherImpl writers_.clear(); - return ReturnCode_t::RETCODE_OK; + return efd::RETCODE_OK; } private: diff --git a/test/unittest/statistics/dds/StatisticsDomainParticipantTests.cpp b/test/unittest/statistics/dds/StatisticsDomainParticipantTests.cpp index aaa34188199..c3d0db2e535 100644 --- a/test/unittest/statistics/dds/StatisticsDomainParticipantTests.cpp +++ b/test/unittest/statistics/dds/StatisticsDomainParticipantTests.cpp @@ -31,7 +31,6 @@ #include #include #include -#include #include #include "../../logging/mock/MockConsumer.h" @@ -41,8 +40,6 @@ namespace fastdds { namespace statistics { namespace dds { -using ReturnCode_t = eprosima::fastrtps::types::ReturnCode_t; - class FooType { public: @@ -191,31 +188,31 @@ TEST_F(StatisticsDomainParticipantTests, NarrowDomainParticipantTest) // 4. Delete DDS entities ASSERT_EQ(eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->delete_participant(participant), - eprosima::fastrtps::types::ReturnCode_t::RETCODE_OK); + fastdds::dds::RETCODE_OK); } /* * This test checks both eprosima::fastdds::statistics::dds::DomainParticipant enable_statistics_datawriter() and * disable_statistics_datawriter() methods. - * 1. If the FASTDDS_STATISTICS compilation flag is not set, check that the methods return RETCODE_UNSUPPORTED. + * 1. If the FASTDDS_STATISTICS compilation flag is not set, check that the methods return fastdds::dds::RETCODE_UNSUPPORTED. * Check that this error takes precedence over other possible errors. * 2. Narrow DomainParticipant to the children class. * 3. Create TypeSupports. * 4. Check that the types are not registered yet. * 5. Check that the topics do not exist yet. * 6. Enable each statistics DataWriter checking that topics are created and types are registered. - * 7. Enable an already enabled statistics DataWriter and check that it returns RETCODE_OK. - * 8. Call enable_statistics_datawriter method with an invalid topic name and check that returns RETCODE_BAD_PARAMETER. + * 7. Enable an already enabled statistics DataWriter and check that it returns fastdds::dds::RETCODE_OK. + * 8. Call enable_statistics_datawriter method with an invalid topic name and check that returns fastdds::dds::RETCODE_BAD_PARAMETER. * 9. Disable one statistics DataWriter and check that it is successful. * 10. Enable the previous statistics DataWriter with an inconsistent QoS and check that it returns - * RETCODE_INCONSISTENT_POLICY. - * 11. Check error code precedence: RETCODE_BAD_PARAMETER takes precedence over RETCODE_INCONSISTENT_POLICY. - * The case where the create_datawriter fails returning RETCODE_ERROR is not checked because it only passes the error + * fastdds::dds::RETCODE_INCONSISTENT_POLICY. + * 11. Check error code precedence: fastdds::dds::RETCODE_BAD_PARAMETER takes precedence over fastdds::dds::RETCODE_INCONSISTENT_POLICY. + * The case where the create_datawriter fails returning fastdds::dds::RETCODE_ERROR is not checked because it only passes the error * upstream. - * 12. Try to disable an already disabled statistics DataWriter and check that returns RETCODE_ERROR. + * 12. Try to disable an already disabled statistics DataWriter and check that returns fastdds::dds::RETCODE_ERROR. * 13. Check that if an invalid topic name is provided to the disable_statistics_datawriter method, it returns - * RETCODE_BAD_PARAMETER. - * The case where the delete_datawriter fails returning RETCODE_ERROR is not checked because it only passes the error + * fastdds::dds::RETCODE_BAD_PARAMETER. + * The case where the delete_datawriter fails returning fastdds::dds::RETCODE_ERROR is not checked because it only passes the error * upstream. * 14. Delete DDS entities. */ @@ -235,13 +232,13 @@ TEST_F(StatisticsDomainParticipantTests, EnableDisableStatisticsDataWriterTest) DomainParticipant* statistics_participant = static_cast(participant); ASSERT_NE(statistics_participant, nullptr); - EXPECT_EQ(ReturnCode_t::RETCODE_UNSUPPORTED, statistics_participant->enable_statistics_datawriter( + EXPECT_EQ(fastdds::dds::RETCODE_UNSUPPORTED, statistics_participant->enable_statistics_datawriter( HISTORY_LATENCY_TOPIC, STATISTICS_DATAWRITER_QOS)); - EXPECT_EQ(ReturnCode_t::RETCODE_UNSUPPORTED, statistics_participant->enable_statistics_datawriter("INVALID_TOPIC", + EXPECT_EQ(fastdds::dds::RETCODE_UNSUPPORTED, statistics_participant->enable_statistics_datawriter("INVALID_TOPIC", inconsistent_qos)); - EXPECT_EQ(ReturnCode_t::RETCODE_UNSUPPORTED, statistics_participant->disable_statistics_datawriter( + EXPECT_EQ(fastdds::dds::RETCODE_UNSUPPORTED, statistics_participant->disable_statistics_datawriter( HISTORY_LATENCY_TOPIC)); - EXPECT_EQ(ReturnCode_t::RETCODE_UNSUPPORTED, statistics_participant->disable_statistics_datawriter( + EXPECT_EQ(fastdds::dds::RETCODE_UNSUPPORTED, statistics_participant->disable_statistics_datawriter( "INVALID_TOPIC")); #else // 2. Narrow DomainParticipant to eprosima::fastdds::statistics::dds::DomainParticipant @@ -289,202 +286,202 @@ TEST_F(StatisticsDomainParticipantTests, EnableDisableStatisticsDataWriterTest) EXPECT_EQ(nullptr, statistics_participant->lookup_topicdescription(PHYSICAL_DATA_TOPIC)); // 6. Enable each statistics DataWriter checking that topics are created and types are registered. - EXPECT_EQ(ReturnCode_t::RETCODE_OK, statistics_participant->enable_statistics_datawriter(HISTORY_LATENCY_TOPIC, + EXPECT_EQ(fastdds::dds::RETCODE_OK, statistics_participant->enable_statistics_datawriter(HISTORY_LATENCY_TOPIC, STATISTICS_DATAWRITER_QOS)); EXPECT_NE(nullptr, statistics_participant->lookup_topicdescription(HISTORY_LATENCY_TOPIC)); EXPECT_TRUE(history_latency_type == statistics_participant->find_type(history_latency_type.get_type_name())); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, statistics_participant->enable_statistics_datawriter(NETWORK_LATENCY_TOPIC, + EXPECT_EQ(fastdds::dds::RETCODE_OK, statistics_participant->enable_statistics_datawriter(NETWORK_LATENCY_TOPIC, STATISTICS_DATAWRITER_QOS)); EXPECT_NE(nullptr, statistics_participant->lookup_topicdescription(NETWORK_LATENCY_TOPIC)); EXPECT_TRUE(network_latency_type == statistics_participant->find_type(network_latency_type.get_type_name())); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, statistics_participant->enable_statistics_datawriter( + EXPECT_EQ(fastdds::dds::RETCODE_OK, statistics_participant->enable_statistics_datawriter( PUBLICATION_THROUGHPUT_TOPIC, STATISTICS_DATAWRITER_QOS)); EXPECT_NE(nullptr, statistics_participant->lookup_topicdescription(PUBLICATION_THROUGHPUT_TOPIC)); EXPECT_TRUE(throughput_type == statistics_participant->find_type(throughput_type.get_type_name())); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, statistics_participant->enable_statistics_datawriter( + EXPECT_EQ(fastdds::dds::RETCODE_OK, statistics_participant->enable_statistics_datawriter( SUBSCRIPTION_THROUGHPUT_TOPIC, STATISTICS_DATAWRITER_QOS)); EXPECT_NE(nullptr, statistics_participant->lookup_topicdescription(SUBSCRIPTION_THROUGHPUT_TOPIC)); EXPECT_TRUE(throughput_type == statistics_participant->find_type(throughput_type.get_type_name())); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, statistics_participant->enable_statistics_datawriter(RTPS_SENT_TOPIC, + EXPECT_EQ(fastdds::dds::RETCODE_OK, statistics_participant->enable_statistics_datawriter(RTPS_SENT_TOPIC, STATISTICS_DATAWRITER_QOS)); EXPECT_NE(nullptr, statistics_participant->lookup_topicdescription(RTPS_SENT_TOPIC)); EXPECT_TRUE(rtps_traffic_type == statistics_participant->find_type(rtps_traffic_type.get_type_name())); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, statistics_participant->enable_statistics_datawriter(RTPS_LOST_TOPIC, + EXPECT_EQ(fastdds::dds::RETCODE_OK, statistics_participant->enable_statistics_datawriter(RTPS_LOST_TOPIC, STATISTICS_DATAWRITER_QOS)); EXPECT_NE(nullptr, statistics_participant->lookup_topicdescription(RTPS_LOST_TOPIC)); EXPECT_TRUE(rtps_traffic_type == statistics_participant->find_type(rtps_traffic_type.get_type_name())); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, statistics_participant->enable_statistics_datawriter(RESENT_DATAS_TOPIC, + EXPECT_EQ(fastdds::dds::RETCODE_OK, statistics_participant->enable_statistics_datawriter(RESENT_DATAS_TOPIC, STATISTICS_DATAWRITER_QOS)); EXPECT_NE(nullptr, statistics_participant->lookup_topicdescription(RESENT_DATAS_TOPIC)); EXPECT_TRUE(count_type == statistics_participant->find_type(count_type.get_type_name())); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, statistics_participant->enable_statistics_datawriter(HEARTBEAT_COUNT_TOPIC, + EXPECT_EQ(fastdds::dds::RETCODE_OK, statistics_participant->enable_statistics_datawriter(HEARTBEAT_COUNT_TOPIC, STATISTICS_DATAWRITER_QOS)); EXPECT_NE(nullptr, statistics_participant->lookup_topicdescription(HEARTBEAT_COUNT_TOPIC)); EXPECT_TRUE(count_type == statistics_participant->find_type(count_type.get_type_name())); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, statistics_participant->enable_statistics_datawriter(ACKNACK_COUNT_TOPIC, + EXPECT_EQ(fastdds::dds::RETCODE_OK, statistics_participant->enable_statistics_datawriter(ACKNACK_COUNT_TOPIC, STATISTICS_DATAWRITER_QOS)); EXPECT_NE(nullptr, statistics_participant->lookup_topicdescription(ACKNACK_COUNT_TOPIC)); EXPECT_TRUE(count_type == statistics_participant->find_type(count_type.get_type_name())); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, statistics_participant->enable_statistics_datawriter(NACKFRAG_COUNT_TOPIC, + EXPECT_EQ(fastdds::dds::RETCODE_OK, statistics_participant->enable_statistics_datawriter(NACKFRAG_COUNT_TOPIC, STATISTICS_DATAWRITER_QOS)); EXPECT_NE(nullptr, statistics_participant->lookup_topicdescription(NACKFRAG_COUNT_TOPIC)); EXPECT_TRUE(count_type == statistics_participant->find_type(count_type.get_type_name())); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, statistics_participant->enable_statistics_datawriter(GAP_COUNT_TOPIC, + EXPECT_EQ(fastdds::dds::RETCODE_OK, statistics_participant->enable_statistics_datawriter(GAP_COUNT_TOPIC, STATISTICS_DATAWRITER_QOS)); EXPECT_NE(nullptr, statistics_participant->lookup_topicdescription(GAP_COUNT_TOPIC)); EXPECT_TRUE(count_type == statistics_participant->find_type(count_type.get_type_name())); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, statistics_participant->enable_statistics_datawriter(DATA_COUNT_TOPIC, + EXPECT_EQ(fastdds::dds::RETCODE_OK, statistics_participant->enable_statistics_datawriter(DATA_COUNT_TOPIC, STATISTICS_DATAWRITER_QOS)); EXPECT_NE(nullptr, statistics_participant->lookup_topicdescription(DATA_COUNT_TOPIC)); EXPECT_TRUE(count_type == statistics_participant->find_type(count_type.get_type_name())); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, statistics_participant->enable_statistics_datawriter(PDP_PACKETS_TOPIC, + EXPECT_EQ(fastdds::dds::RETCODE_OK, statistics_participant->enable_statistics_datawriter(PDP_PACKETS_TOPIC, STATISTICS_DATAWRITER_QOS)); EXPECT_NE(nullptr, statistics_participant->lookup_topicdescription(PDP_PACKETS_TOPIC)); EXPECT_TRUE(count_type == statistics_participant->find_type(count_type.get_type_name())); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, statistics_participant->enable_statistics_datawriter(EDP_PACKETS_TOPIC, + EXPECT_EQ(fastdds::dds::RETCODE_OK, statistics_participant->enable_statistics_datawriter(EDP_PACKETS_TOPIC, STATISTICS_DATAWRITER_QOS)); EXPECT_NE(nullptr, statistics_participant->lookup_topicdescription(EDP_PACKETS_TOPIC)); EXPECT_TRUE(count_type == statistics_participant->find_type(count_type.get_type_name())); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, statistics_participant->enable_statistics_datawriter(DISCOVERY_TOPIC, + EXPECT_EQ(fastdds::dds::RETCODE_OK, statistics_participant->enable_statistics_datawriter(DISCOVERY_TOPIC, STATISTICS_DATAWRITER_QOS)); EXPECT_NE(nullptr, statistics_participant->lookup_topicdescription(DISCOVERY_TOPIC)); EXPECT_TRUE(discovery_type == statistics_participant->find_type(discovery_type.get_type_name())); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, statistics_participant->enable_statistics_datawriter(SAMPLE_DATAS_TOPIC, + EXPECT_EQ(fastdds::dds::RETCODE_OK, statistics_participant->enable_statistics_datawriter(SAMPLE_DATAS_TOPIC, STATISTICS_DATAWRITER_QOS)); EXPECT_NE(nullptr, statistics_participant->lookup_topicdescription(SAMPLE_DATAS_TOPIC)); EXPECT_TRUE(sample_identity_count_type == statistics_participant->find_type( sample_identity_count_type.get_type_name())); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, statistics_participant->enable_statistics_datawriter(PHYSICAL_DATA_TOPIC, + EXPECT_EQ(fastdds::dds::RETCODE_OK, statistics_participant->enable_statistics_datawriter(PHYSICAL_DATA_TOPIC, STATISTICS_DATAWRITER_QOS)); EXPECT_NE(nullptr, statistics_participant->lookup_topicdescription(PHYSICAL_DATA_TOPIC)); EXPECT_TRUE(physical_data_type == statistics_participant->find_type(physical_data_type.get_type_name())); // 7. Enable an already enabled statistics DataWriter - EXPECT_EQ(ReturnCode_t::RETCODE_OK, statistics_participant->enable_statistics_datawriter(SAMPLE_DATAS_TOPIC, + EXPECT_EQ(fastdds::dds::RETCODE_OK, statistics_participant->enable_statistics_datawriter(SAMPLE_DATAS_TOPIC, STATISTICS_DATAWRITER_QOS)); // 8. Invalid topic name - EXPECT_EQ(ReturnCode_t::RETCODE_BAD_PARAMETER, statistics_participant->enable_statistics_datawriter("INVALID_TOPIC", + EXPECT_EQ(fastdds::dds::RETCODE_BAD_PARAMETER, statistics_participant->enable_statistics_datawriter("INVALID_TOPIC", STATISTICS_DATAWRITER_QOS)); EXPECT_EQ(nullptr, statistics_participant->lookup_topicdescription("INVALID_TOPIC")); // 9. Disable statistics DataWriter - EXPECT_EQ(ReturnCode_t::RETCODE_OK, statistics_participant->disable_statistics_datawriter(HISTORY_LATENCY_TOPIC)); + EXPECT_EQ(fastdds::dds::RETCODE_OK, statistics_participant->disable_statistics_datawriter(HISTORY_LATENCY_TOPIC)); EXPECT_EQ(nullptr, statistics_participant->lookup_topicdescription(HISTORY_LATENCY_TOPIC)); EXPECT_NE(nullptr, statistics_participant->lookup_topicdescription(PDP_PACKETS_TOPIC)); EXPECT_EQ(null_type, statistics_participant->find_type(history_latency_type.get_type_name())); // 10. Enable previous statistics DataWriter with an inconsistent QoS - EXPECT_EQ(ReturnCode_t::RETCODE_INCONSISTENT_POLICY, statistics_participant->enable_statistics_datawriter( + EXPECT_EQ(fastdds::dds::RETCODE_INCONSISTENT_POLICY, statistics_participant->enable_statistics_datawriter( HISTORY_LATENCY_TOPIC, inconsistent_qos)); EXPECT_EQ(nullptr, statistics_participant->lookup_topicdescription(HISTORY_LATENCY_TOPIC)); EXPECT_EQ(null_type, statistics_participant->find_type(history_latency_type.get_type_name())); - // 11. RETCODE_BAD_PARAMETER error has precedence over RETCODE_INCONSISTENT_POLICY - EXPECT_EQ(ReturnCode_t::RETCODE_BAD_PARAMETER, statistics_participant->enable_statistics_datawriter("INVALID_TOPIC", + // 11. fastdds::dds::RETCODE_BAD_PARAMETER error has precedence over fastdds::dds::RETCODE_INCONSISTENT_POLICY + EXPECT_EQ(fastdds::dds::RETCODE_BAD_PARAMETER, statistics_participant->enable_statistics_datawriter("INVALID_TOPIC", inconsistent_qos)); // 12. Disable already disabled DataWriter - EXPECT_EQ(ReturnCode_t::RETCODE_OK, statistics_participant->disable_statistics_datawriter(HISTORY_LATENCY_TOPIC)); + EXPECT_EQ(fastdds::dds::RETCODE_OK, statistics_participant->disable_statistics_datawriter(HISTORY_LATENCY_TOPIC)); // 13. Disable invalid topic name - EXPECT_EQ(ReturnCode_t::RETCODE_BAD_PARAMETER, statistics_participant->disable_statistics_datawriter( + EXPECT_EQ(fastdds::dds::RETCODE_BAD_PARAMETER, statistics_participant->disable_statistics_datawriter( "INVALID_TOPIC")); // 14. Remove DDS entities - EXPECT_EQ(ReturnCode_t::RETCODE_OK, statistics_participant->disable_statistics_datawriter(NETWORK_LATENCY_TOPIC)); + EXPECT_EQ(fastdds::dds::RETCODE_OK, statistics_participant->disable_statistics_datawriter(NETWORK_LATENCY_TOPIC)); EXPECT_EQ(nullptr, statistics_participant->lookup_topicdescription(NETWORK_LATENCY_TOPIC)); EXPECT_EQ(null_type, statistics_participant->find_type(network_latency_type.get_type_name())); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, statistics_participant->disable_statistics_datawriter( + EXPECT_EQ(fastdds::dds::RETCODE_OK, statistics_participant->disable_statistics_datawriter( PUBLICATION_THROUGHPUT_TOPIC)); EXPECT_EQ(nullptr, statistics_participant->lookup_topicdescription(PUBLICATION_THROUGHPUT_TOPIC)); // The type is being used by another topic yet EXPECT_TRUE(throughput_type == statistics_participant->find_type(throughput_type.get_type_name())); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, statistics_participant->disable_statistics_datawriter( + EXPECT_EQ(fastdds::dds::RETCODE_OK, statistics_participant->disable_statistics_datawriter( SUBSCRIPTION_THROUGHPUT_TOPIC)); EXPECT_EQ(nullptr, statistics_participant->lookup_topicdescription(SUBSCRIPTION_THROUGHPUT_TOPIC)); EXPECT_EQ(null_type, statistics_participant->find_type(throughput_type.get_type_name())); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, statistics_participant->disable_statistics_datawriter(RTPS_SENT_TOPIC)); + EXPECT_EQ(fastdds::dds::RETCODE_OK, statistics_participant->disable_statistics_datawriter(RTPS_SENT_TOPIC)); EXPECT_EQ(nullptr, statistics_participant->lookup_topicdescription(RTPS_SENT_TOPIC)); // The type is being used by another topic yet EXPECT_TRUE(rtps_traffic_type == statistics_participant->find_type(rtps_traffic_type.get_type_name())); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, statistics_participant->disable_statistics_datawriter(RTPS_LOST_TOPIC)); + EXPECT_EQ(fastdds::dds::RETCODE_OK, statistics_participant->disable_statistics_datawriter(RTPS_LOST_TOPIC)); EXPECT_EQ(nullptr, statistics_participant->lookup_topicdescription(RTPS_LOST_TOPIC)); EXPECT_EQ(null_type, statistics_participant->find_type(rtps_traffic_type.get_type_name())); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, statistics_participant->disable_statistics_datawriter(RESENT_DATAS_TOPIC)); + EXPECT_EQ(fastdds::dds::RETCODE_OK, statistics_participant->disable_statistics_datawriter(RESENT_DATAS_TOPIC)); EXPECT_EQ(nullptr, statistics_participant->lookup_topicdescription(RESENT_DATAS_TOPIC)); // The type is being used by another topic yet EXPECT_TRUE(count_type == statistics_participant->find_type(count_type.get_type_name())); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, statistics_participant->disable_statistics_datawriter(HEARTBEAT_COUNT_TOPIC)); + EXPECT_EQ(fastdds::dds::RETCODE_OK, statistics_participant->disable_statistics_datawriter(HEARTBEAT_COUNT_TOPIC)); EXPECT_EQ(nullptr, statistics_participant->lookup_topicdescription(HEARTBEAT_COUNT_TOPIC)); // The type is being used by another topic yet EXPECT_TRUE(count_type == statistics_participant->find_type(count_type.get_type_name())); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, statistics_participant->disable_statistics_datawriter(ACKNACK_COUNT_TOPIC)); + EXPECT_EQ(fastdds::dds::RETCODE_OK, statistics_participant->disable_statistics_datawriter(ACKNACK_COUNT_TOPIC)); EXPECT_EQ(nullptr, statistics_participant->lookup_topicdescription(ACKNACK_COUNT_TOPIC)); // The type is being used by another topic yet EXPECT_TRUE(count_type == statistics_participant->find_type(count_type.get_type_name())); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, statistics_participant->disable_statistics_datawriter(NACKFRAG_COUNT_TOPIC)); + EXPECT_EQ(fastdds::dds::RETCODE_OK, statistics_participant->disable_statistics_datawriter(NACKFRAG_COUNT_TOPIC)); EXPECT_EQ(nullptr, statistics_participant->lookup_topicdescription(NACKFRAG_COUNT_TOPIC)); // The type is being used by another topic yet EXPECT_TRUE(count_type == statistics_participant->find_type(count_type.get_type_name())); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, statistics_participant->disable_statistics_datawriter(GAP_COUNT_TOPIC)); + EXPECT_EQ(fastdds::dds::RETCODE_OK, statistics_participant->disable_statistics_datawriter(GAP_COUNT_TOPIC)); EXPECT_EQ(nullptr, statistics_participant->lookup_topicdescription(GAP_COUNT_TOPIC)); // The type is being used by another topic yet EXPECT_TRUE(count_type == statistics_participant->find_type(count_type.get_type_name())); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, statistics_participant->disable_statistics_datawriter(DATA_COUNT_TOPIC)); + EXPECT_EQ(fastdds::dds::RETCODE_OK, statistics_participant->disable_statistics_datawriter(DATA_COUNT_TOPIC)); EXPECT_EQ(nullptr, statistics_participant->lookup_topicdescription(DATA_COUNT_TOPIC)); // The type is being used by another topic yet EXPECT_TRUE(count_type == statistics_participant->find_type(count_type.get_type_name())); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, statistics_participant->disable_statistics_datawriter(PDP_PACKETS_TOPIC)); + EXPECT_EQ(fastdds::dds::RETCODE_OK, statistics_participant->disable_statistics_datawriter(PDP_PACKETS_TOPIC)); EXPECT_EQ(nullptr, statistics_participant->lookup_topicdescription(PDP_PACKETS_TOPIC)); // The type is being used by another topic yet EXPECT_TRUE(count_type == statistics_participant->find_type(count_type.get_type_name())); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, statistics_participant->disable_statistics_datawriter(EDP_PACKETS_TOPIC)); + EXPECT_EQ(fastdds::dds::RETCODE_OK, statistics_participant->disable_statistics_datawriter(EDP_PACKETS_TOPIC)); EXPECT_EQ(nullptr, statistics_participant->lookup_topicdescription(EDP_PACKETS_TOPIC)); EXPECT_EQ(null_type, statistics_participant->find_type(count_type.get_type_name())); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, statistics_participant->disable_statistics_datawriter(DISCOVERY_TOPIC)); + EXPECT_EQ(fastdds::dds::RETCODE_OK, statistics_participant->disable_statistics_datawriter(DISCOVERY_TOPIC)); EXPECT_EQ(nullptr, statistics_participant->lookup_topicdescription(DISCOVERY_TOPIC)); EXPECT_EQ(null_type, statistics_participant->find_type(discovery_type.get_type_name())); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, statistics_participant->disable_statistics_datawriter(SAMPLE_DATAS_TOPIC)); + EXPECT_EQ(fastdds::dds::RETCODE_OK, statistics_participant->disable_statistics_datawriter(SAMPLE_DATAS_TOPIC)); EXPECT_EQ(nullptr, statistics_participant->lookup_topicdescription(SAMPLE_DATAS_TOPIC)); EXPECT_EQ(null_type, statistics_participant->find_type(sample_identity_count_type.get_type_name())); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, statistics_participant->disable_statistics_datawriter(PHYSICAL_DATA_TOPIC)); + EXPECT_EQ(fastdds::dds::RETCODE_OK, statistics_participant->disable_statistics_datawriter(PHYSICAL_DATA_TOPIC)); EXPECT_EQ(nullptr, statistics_participant->lookup_topicdescription(PHYSICAL_DATA_TOPIC)); EXPECT_EQ(null_type, statistics_participant->find_type(physical_data_type.get_type_name())); #endif // FASTDDS_STATISTICS - EXPECT_EQ(ReturnCode_t::RETCODE_OK, eprosima::fastdds::dds::DomainParticipantFactory::get_instance()-> + EXPECT_EQ(fastdds::dds::RETCODE_OK, eprosima::fastdds::dds::DomainParticipantFactory::get_instance()-> delete_participant(statistics_participant)); } @@ -559,12 +556,12 @@ TEST_F(StatisticsDomainParticipantTests, CreateParticipantWithInvalidTopicName) EXPECT_EQ(consumed_entries.size(), 2u); EXPECT_EQ(eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->delete_participant(participant), - ReturnCode_t::RETCODE_OK); + fastdds::dds::RETCODE_OK); #endif // FASTDDS_STATISTICS } /** - * This test checks that enable_statistics_datawriter fails returning RETCODE_ERROR when there is already a TypeSupport + * This test checks that enable_statistics_datawriter fails returning fastdds::dds::RETCODE_ERROR when there is already a TypeSupport * using a statistics reserved name registered in the participant. * 1. Create a participant and register a TypeSupport using one of the statistics reserved type names. * 2. Call enable_statistics_datawriter and check that it fails. @@ -603,7 +600,7 @@ TEST_F(StatisticsDomainParticipantTests, EnableStatisticsDataWriterFailureIncomp DomainParticipant* statistics_participant = DomainParticipant::narrow(participant); ASSERT_NE(statistics_participant, nullptr); - EXPECT_EQ(ReturnCode_t::RETCODE_ERROR, statistics_participant->enable_statistics_datawriter(HEARTBEAT_COUNT_TOPIC, + EXPECT_EQ(fastdds::dds::RETCODE_ERROR, statistics_participant->enable_statistics_datawriter(HEARTBEAT_COUNT_TOPIC, STATISTICS_DATAWRITER_QOS)); eprosima::fastdds::dds::TypeSupport type = participant->find_type(count_type.get_type_name()); EXPECT_FALSE(count_type == type); @@ -614,7 +611,7 @@ TEST_F(StatisticsDomainParticipantTests, EnableStatisticsDataWriterFailureIncomp // 4. Call enable_statistics_datawriter with an already correctly registered type. EXPECT_EQ(nullptr, participant->lookup_topicdescription(PHYSICAL_DATA_TOPIC)); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, statistics_participant->enable_statistics_datawriter(PHYSICAL_DATA_TOPIC, + EXPECT_EQ(fastdds::dds::RETCODE_OK, statistics_participant->enable_statistics_datawriter(PHYSICAL_DATA_TOPIC, STATISTICS_DATAWRITER_QOS)); EXPECT_TRUE(physical_data_type == participant->find_type(physical_data_type.get_type_name())); EXPECT_NE(nullptr, participant->lookup_topicdescription(PHYSICAL_DATA_TOPIC)); @@ -626,12 +623,12 @@ TEST_F(StatisticsDomainParticipantTests, EnableStatisticsDataWriterFailureIncomp // delete_participant removes all builtin statistics entities EXPECT_EQ(eprosima::fastdds::dds::DomainParticipantFactory::get_instance()-> - delete_participant(statistics_participant), ReturnCode_t::RETCODE_OK); + delete_participant(statistics_participant), fastdds::dds::RETCODE_OK); #endif // FASTDDS_STATISTICS } /** - * This test checks that enable_statistics_datawriter fails returning RETCODE_ERROR when there is already a statistics + * This test checks that enable_statistics_datawriter fails returning fastdds::dds::RETCODE_ERROR when there is already a statistics * Topic created with another type different from the one expected. * 1. Create a participant and register a Topic using one of the statistics reserved topic names and with another type * different from the one expected. Register another Topic correctly. @@ -678,19 +675,19 @@ TEST_F(StatisticsDomainParticipantTests, EnableStatisticsDataWriterFailureIncomp DomainParticipant* statistics_participant = DomainParticipant::narrow(participant); ASSERT_NE(statistics_participant, nullptr); - EXPECT_EQ(ReturnCode_t::RETCODE_ERROR, statistics_participant->enable_statistics_datawriter(HISTORY_LATENCY_TOPIC, + EXPECT_EQ(fastdds::dds::RETCODE_ERROR, statistics_participant->enable_statistics_datawriter(HISTORY_LATENCY_TOPIC, STATISTICS_DATAWRITER_QOS)); // 3. Check type registration EXPECT_EQ(null_type, participant->find_type(history_latency_type.get_type_name())); // 4. Call enable_statistics_datawriter with correctly created topic - EXPECT_EQ(ReturnCode_t::RETCODE_OK, statistics_participant->enable_statistics_datawriter(HEARTBEAT_COUNT_TOPIC, + EXPECT_EQ(fastdds::dds::RETCODE_OK, statistics_participant->enable_statistics_datawriter(HEARTBEAT_COUNT_TOPIC, STATISTICS_DATAWRITER_QOS)); EXPECT_TRUE(count_type == participant->find_type(count_type.get_type_name())); // 5. Call enable_statistics_datawriter and check it is successful - EXPECT_EQ(ReturnCode_t::RETCODE_OK, statistics_participant->enable_statistics_datawriter(PHYSICAL_DATA_TOPIC, + EXPECT_EQ(fastdds::dds::RETCODE_OK, statistics_participant->enable_statistics_datawriter(PHYSICAL_DATA_TOPIC, STATISTICS_DATAWRITER_QOS)); // 6. Check log error entry @@ -699,9 +696,9 @@ TEST_F(StatisticsDomainParticipantTests, EnableStatisticsDataWriterFailureIncomp EXPECT_EQ(consumed_entries.size(), 1u); // delete_participant removes all builtin statistics entities but not others - EXPECT_EQ(ReturnCode_t::RETCODE_OK, participant->delete_topic(invalid_topic)); + EXPECT_EQ(fastdds::dds::RETCODE_OK, participant->delete_topic(invalid_topic)); EXPECT_EQ(eprosima::fastdds::dds::DomainParticipantFactory::get_instance()-> - delete_participant(statistics_participant), ReturnCode_t::RETCODE_OK); + delete_participant(statistics_participant), fastdds::dds::RETCODE_OK); #endif // FASTDDS_STATISTICS } @@ -736,15 +733,15 @@ TEST_F(StatisticsDomainParticipantTests, DeleteParticipantAfterDeleteContainedEn DomainParticipant* statistics_participant = DomainParticipant::narrow(participant); ASSERT_NE(statistics_participant, nullptr); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, statistics_participant->enable_statistics_datawriter(HEARTBEAT_COUNT_TOPIC, + EXPECT_EQ(fastdds::dds::RETCODE_OK, statistics_participant->enable_statistics_datawriter(HEARTBEAT_COUNT_TOPIC, STATISTICS_DATAWRITER_QOS)); // 3. Perform a delete_contained_entities() in the statistics participant - EXPECT_EQ(participant->delete_contained_entities(), ReturnCode_t::RETCODE_OK); + EXPECT_EQ(participant->delete_contained_entities(), fastdds::dds::RETCODE_OK); // 4. Delete the participant EXPECT_EQ(eprosima::fastdds::dds::DomainParticipantFactory::get_instance()-> - delete_participant(participant), ReturnCode_t::RETCODE_OK); + delete_participant(participant), fastdds::dds::RETCODE_OK); #endif // FASTDDS_STATISTICS } diff --git a/test/unittest/statistics/dds/StatisticsQosTests.cpp b/test/unittest/statistics/dds/StatisticsQosTests.cpp index d5c1f73d1f1..aaad09d88ba 100644 --- a/test/unittest/statistics/dds/StatisticsQosTests.cpp +++ b/test/unittest/statistics/dds/StatisticsQosTests.cpp @@ -15,10 +15,10 @@ #include #include - #include #include +#include #include #include #include @@ -29,7 +29,6 @@ #include #include #include -#include #ifdef FASTDDS_STATISTICS #include @@ -40,8 +39,6 @@ namespace fastdds { namespace statistics { namespace dds { -using ReturnCode_t = eprosima::fastrtps::types::ReturnCode_t; - class StatisticsFromXMLProfileTests : public ::testing::Test { public: @@ -170,7 +167,7 @@ TEST_F(StatisticsFromXMLProfileTests, XMLConfigurationForStatisticsDataWritersQo const std::string xml = " \ \ - \ + \ \ \ \ @@ -318,10 +315,10 @@ TEST_F(StatisticsFromXMLProfileTests, XMLConfigurationForStatisticsDataWritersQo ASSERT_EQ(network_latency_writer, nullptr); // But user can enable it manually through enable_statistics_datawriter_with_profile() - ReturnCode_t ret = statistics_participant->enable_statistics_datawriter_with_profile( + fastdds::dds::ReturnCode_t ret = statistics_participant->enable_statistics_datawriter_with_profile( "NETWORK_LATENCY_TOPIC", "NETWORK_LATENCY_TOPIC"); - ASSERT_EQ(ReturnCode_t::RETCODE_OK, ret); + ASSERT_EQ(fastdds::dds::RETCODE_OK, ret); network_latency_writer = statistics_publisher->lookup_datawriter(network_latency_name); ASSERT_NE(network_latency_writer, nullptr); @@ -339,7 +336,7 @@ TEST_F(StatisticsFromXMLProfileTests, XMLConfigurationForStatisticsDataWritersQo ret = statistics_participant->enable_statistics_datawriter_with_profile( "SUBSCRIPTION_THROUGHPUT_TOPIC", "SUBSCRIPTION_THROUGHPUT_TOPIC"); - ASSERT_EQ(ReturnCode_t::RETCODE_OK, ret); + ASSERT_EQ(fastdds::dds::RETCODE_OK, ret); subscription_througput_writer = statistics_publisher->lookup_datawriter(subscription_throughput_name); ASSERT_NE(subscription_througput_writer, nullptr); @@ -359,11 +356,11 @@ TEST_F(StatisticsFromXMLProfileTests, XMLConfigurationForStatisticsDataWritersQo ASSERT_EQ(qos4, subscription_througput_writer->get_qos()); // Calling enable_statistics_datawriter_with_profile with a profile that does not exist, - // RETCODE_ERROR must be returned. + // fastdds::dds::RETCODE_ERROR must be returned. ret = statistics_participant->enable_statistics_datawriter_with_profile( "FAKE_TOPIC", "FAKE_TOPIC"); - ASSERT_EQ(ReturnCode_t::RETCODE_ERROR, ret); + ASSERT_EQ(fastdds::dds::RETCODE_ERROR, ret); // DATA_COUNT_TOPIC is defined with inconsistent QoS policies, // and configured to be enabled automatically at initialization @@ -376,17 +373,17 @@ TEST_F(StatisticsFromXMLProfileTests, XMLConfigurationForStatisticsDataWritersQo ASSERT_EQ(data_count_writer, nullptr); // Calling enable_statistics_datawriter_with_profile with a profile defined with inconsistent QoS configuration, - // RETCODE_INCONSISTENT_POLICY must be returned. + // fastdds::dds::RETCODE_INCONSISTENT_POLICY must be returned. ret = statistics_participant->enable_statistics_datawriter_with_profile( "HEARTBEAT_COUNT_TOPIC", "HEARTBEAT_COUNT_TOPIC"); - ASSERT_EQ(ReturnCode_t::RETCODE_INCONSISTENT_POLICY, ret); + ASSERT_EQ(fastdds::dds::RETCODE_INCONSISTENT_POLICY, ret); // There is the possibility to enable a statistics topic with a profile defined with different name: ret = statistics_participant->enable_statistics_datawriter_with_profile( "OTHER_NAME_FOR_PROFILE", "NACKFRAG_COUNT_TOPIC"); - ASSERT_EQ(ReturnCode_t::RETCODE_OK, ret); + ASSERT_EQ(fastdds::dds::RETCODE_OK, ret); std::string nackfrag_count_name = NACKFRAG_COUNT_TOPIC; eprosima::fastdds::dds::DataWriter* nackfrag_count_writer = statistics_publisher->lookup_datawriter(nackfrag_count_name); @@ -414,20 +411,20 @@ TEST_F(StatisticsFromXMLProfileTests, XMLConfigurationForStatisticsDataWritersQo statistics_participant = static_cast(participant); ASSERT_NE(statistics_participant, nullptr); - ReturnCode_t ret = statistics_participant->enable_statistics_datawriter_with_profile( + fastdds::dds::ReturnCode_t ret = statistics_participant->enable_statistics_datawriter_with_profile( "HISTORY_LATENCY_TOPIC", "HISTORY_LATENCY_TOPIC"); - ASSERT_EQ(ReturnCode_t::RETCODE_UNSUPPORTED, ret); + ASSERT_EQ(fastdds::dds::RETCODE_UNSUPPORTED, ret); ret = statistics_participant->enable_statistics_datawriter_with_profile( "NETWORK_LATENCY_TOPIC", "NETWORK_LATENCY_TOPIC"); - ASSERT_EQ(ReturnCode_t::RETCODE_UNSUPPORTED, ret); + ASSERT_EQ(fastdds::dds::RETCODE_UNSUPPORTED, ret); ret = statistics_participant->enable_statistics_datawriter_with_profile( "SUBSCRIPTION_THROUGHPUT_TOPIC", "SUBSCRIPTION_THROUGHPUT_TOPIC"); - ASSERT_EQ(ReturnCode_t::RETCODE_UNSUPPORTED, ret); + ASSERT_EQ(fastdds::dds::RETCODE_UNSUPPORTED, ret); #endif // FASTDDS_STATISTICS @@ -446,7 +443,7 @@ TEST_F(StatisticsFromXMLProfileTests, XMLConfigurationForStatisticsDataWritersQo const std::string xml = " \ \ - \ + \ \ \ \ diff --git a/test/unittest/statistics/rtps/CMakeLists.txt b/test/unittest/statistics/rtps/CMakeLists.txt index a13e24cd0da..ea906b30359 100644 --- a/test/unittest/statistics/rtps/CMakeLists.txt +++ b/test/unittest/statistics/rtps/CMakeLists.txt @@ -18,10 +18,6 @@ endif() set(STATISTICS_RTPS_TESTS_SOURCE RTPSStatisticsTests.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/monitorservice_types.cxx - ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/monitorservice_typesv1.cxx - ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/types.cxx - ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/typesv1.cxx ) add_executable(RTPSStatisticsTests ${STATISTICS_RTPS_TESTS_SOURCE}) @@ -40,7 +36,7 @@ target_include_directories(RTPSStatisticsTests PRIVATE ${Asio_INCLUDE_DIR} ) -target_link_libraries(RTPSStatisticsTests fastrtps fastcdr GTest::gtest GTest::gmock) +target_link_libraries(RTPSStatisticsTests fastdds fastcdr GTest::gtest GTest::gmock) gtest_discover_tests(RTPSStatisticsTests) set(TCPTransportInterface_SOURCE @@ -66,37 +62,7 @@ endif() set(STATISTICS_RTPS_MONITORSERVICETESTS_SOURCE MonitorServiceTests.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/AnnotationDescriptor.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/AnnotationParameterValue.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/BuiltinAnnotationsTypeObject.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicData.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicDataFactory.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicDataPtr.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicPubSubType.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicType.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeBuilder.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeBuilderFactory.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeBuilderPtr.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeMember.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypePtr.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/MemberDescriptor.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeDescriptor.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeIdentifier.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeIdentifierTypes.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeNamesGenerator.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeObject.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeObjectFactory.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeObjectHashId.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypesBase.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/core/policy/ParameterList.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/Log.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/Log.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/OStreamConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/OStreamConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutErrConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutErrConsumer.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/publisher/qos/WriterQos.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/subscriber/qos/ReaderQos.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/topic/TopicDataType.cpp @@ -123,11 +89,10 @@ set(STATISTICS_RTPS_MONITORSERVICETESTS_SOURCE ${PROJECT_SOURCE_DIR}/src/cpp/rtps/writer/LocatorSelectorSender.cpp ${PROJECT_SOURCE_DIR}/src/cpp/statistics/rtps/monitor-service/MonitorService.cpp ${PROJECT_SOURCE_DIR}/src/cpp/statistics/rtps/monitor-service/MonitorServiceListener.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/monitorservice_types.cxx ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/monitorservice_typesPubSubTypes.cxx - ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/monitorservice_typesv1.cxx - ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/types.cxx - ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/typesv1.cxx + ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/monitorservice_typesTypeObjectSupport.cxx + ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/typesPubSubTypes.cxx + ${PROJECT_SOURCE_DIR}/src/cpp/statistics/types/typesTypeObjectSupport.cxx ${PROJECT_SOURCE_DIR}/src/cpp/utils/IPFinder.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/IPLocator.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/md5.cpp @@ -138,7 +103,7 @@ set(STATISTICS_RTPS_MONITORSERVICETESTS_SOURCE add_executable(MonitorServiceTests ${STATISTICS_RTPS_MONITORSERVICETESTS_SOURCE}) -target_compile_definitions(MonitorServiceTests PRIVATE FASTRTPS_NO_LIB +target_compile_definitions(MonitorServiceTests PRIVATE FASTDDS_NO_LIB BOOST_ASIO_STANDALONE ASIO_STANDALONE $<$>,$>:__DEBUG> @@ -148,6 +113,7 @@ target_compile_definitions(MonitorServiceTests PRIVATE FASTRTPS_NO_LIB target_include_directories(MonitorServiceTests PRIVATE mock/Publisher mock/StatisticsBase + ${PROJECT_SOURCE_DIR}/test/mock/dds/DomainParticipantFactory ${PROJECT_SOURCE_DIR}/test/mock/rtps/BuiltinProtocols ${PROJECT_SOURCE_DIR}/test/mock/rtps/EDP ${PROJECT_SOURCE_DIR}/test/mock/rtps/Endpoint @@ -155,6 +121,7 @@ target_include_directories(MonitorServiceTests PRIVATE ${PROJECT_SOURCE_DIR}/test/mock/rtps/ExternalLocatorsProcessor ${PROJECT_SOURCE_DIR}/test/mock/rtps/ReaderHistory ${PROJECT_SOURCE_DIR}/test/mock/rtps/ReceiverResource + ${PROJECT_SOURCE_DIR}/test/mock/rtps/RTPSDomainImpl ${PROJECT_SOURCE_DIR}/test/mock/rtps/RTPSParticipantImpl ${PROJECT_SOURCE_DIR}/test/mock/rtps/RTPSReader ${PROJECT_SOURCE_DIR}/test/mock/rtps/RTPSWriter @@ -174,9 +141,13 @@ target_include_directories(MonitorServiceTests PRIVATE target_link_libraries(MonitorServiceTests fastcdr + fastdds::log + fastdds::xtypes::dynamic-types::impl + fastdds::xtypes::type-representation GTest::gtest GTest::gmock - $<$:OpenSSL::SSL$OpenSSL::Crypto>) + $<$:OpenSSL::SSL$OpenSSL::Crypto> + ) gtest_discover_tests(MonitorServiceTests) diff --git a/test/unittest/statistics/rtps/MonitorServiceTests.cpp b/test/unittest/statistics/rtps/MonitorServiceTests.cpp index af7852a825f..bb35df72573 100644 --- a/test/unittest/statistics/rtps/MonitorServiceTests.cpp +++ b/test/unittest/statistics/rtps/MonitorServiceTests.cpp @@ -80,7 +80,7 @@ class MonitorServiceTests : public ::testing::Test [&]( fastrtps::rtps::RTPSWriter*, const fastrtps::TopicAttributes&, - const fastrtps::WriterQos&)->bool + const fastdds::dds::WriterQos&)->bool { return true; }, @@ -217,11 +217,11 @@ TEST_F(MonitorServiceTests, multiple_dds_status_updates) //! Trigger statuses updates for each entity for (auto& entity : mock_guids) { - listener_.on_local_entity_status_change(entity, statistics::INCOMPATIBLE_QOS); - listener_.on_local_entity_status_change(entity, statistics::LIVELINESS_CHANGED); - listener_.on_local_entity_status_change(entity, statistics::LIVELINESS_LOST); - listener_.on_local_entity_status_change(entity, statistics::DEADLINE_MISSED); - listener_.on_local_entity_status_change(entity, statistics::SAMPLE_LOST); + listener_.on_local_entity_status_change(entity, statistics::StatusKind::INCOMPATIBLE_QOS); + listener_.on_local_entity_status_change(entity, statistics::StatusKind::LIVELINESS_CHANGED); + listener_.on_local_entity_status_change(entity, statistics::StatusKind::LIVELINESS_LOST); + listener_.on_local_entity_status_change(entity, statistics::StatusKind::DEADLINE_MISSED); + listener_.on_local_entity_status_change(entity, statistics::StatusKind::SAMPLE_LOST); } //! Verify expectations @@ -263,11 +263,11 @@ TEST_F(MonitorServiceTests, entity_removal_correctly_performs) for (auto& entity : mock_guids) { listener_.on_local_entity_connections_change(entity); - listener_.on_local_entity_status_change(entity, statistics::INCOMPATIBLE_QOS); - listener_.on_local_entity_status_change(entity, statistics::LIVELINESS_CHANGED); - listener_.on_local_entity_status_change(entity, statistics::LIVELINESS_LOST); - listener_.on_local_entity_status_change(entity, statistics::DEADLINE_MISSED); - listener_.on_local_entity_status_change(entity, statistics::SAMPLE_LOST); + listener_.on_local_entity_status_change(entity, statistics::StatusKind::INCOMPATIBLE_QOS); + listener_.on_local_entity_status_change(entity, statistics::StatusKind::LIVELINESS_CHANGED); + listener_.on_local_entity_status_change(entity, statistics::StatusKind::LIVELINESS_LOST); + listener_.on_local_entity_status_change(entity, statistics::StatusKind::DEADLINE_MISSED); + listener_.on_local_entity_status_change(entity, statistics::StatusKind::SAMPLE_LOST); } //! Verify expectations diff --git a/test/unittest/statistics/rtps/RTPSStatisticsTests.cpp b/test/unittest/statistics/rtps/RTPSStatisticsTests.cpp index a54d4c88183..2bf525fe701 100644 --- a/test/unittest/statistics/rtps/RTPSStatisticsTests.cpp +++ b/test/unittest/statistics/rtps/RTPSStatisticsTests.cpp @@ -14,6 +14,7 @@ #include #include + #if defined(_WIN32) #include #else @@ -26,9 +27,11 @@ #include #include #include +#include #include #include #include +#include #include #include #include @@ -36,24 +39,17 @@ #include #include #include +#include #include #include -#include -#include -#include -#include -#include -#include -#include - -#include -#include #include #include #include -#include +#include +#include #include +#include namespace eprosima { namespace fastdds { @@ -88,52 +84,52 @@ struct MockListener : IListener auto kind = data._d(); switch (kind) { - case HISTORY2HISTORY_LATENCY: + case EventKind::HISTORY2HISTORY_LATENCY: on_history_latency(data.writer_reader_data()); break; - case RTPS_SENT: + case EventKind::RTPS_SENT: on_rtps_sent(data.entity2locator_traffic()); break; - case RTPS_LOST: + case EventKind::RTPS_LOST: on_rtps_lost(data.entity2locator_traffic()); break; - case NETWORK_LATENCY: + case EventKind::NETWORK_LATENCY: on_network_latency(data.locator2locator_data()); break; - case HEARTBEAT_COUNT: + case EventKind::HEARTBEAT_COUNT: on_heartbeat_count(data.entity_count()); break; - case ACKNACK_COUNT: + case EventKind::ACKNACK_COUNT: on_acknack_count(data.entity_count()); break; - case DATA_COUNT: + case EventKind::DATA_COUNT: on_data_count(data.entity_count()); break; - case RESENT_DATAS: + case EventKind::RESENT_DATAS: on_resent_count(data.entity_count()); break; - case GAP_COUNT: + case EventKind::GAP_COUNT: on_gap_count(data.entity_count()); break; - case NACKFRAG_COUNT: + case EventKind::NACKFRAG_COUNT: on_nackfrag_count(data.entity_count()); break; - case DISCOVERED_ENTITY: + case EventKind::DISCOVERED_ENTITY: on_entity_discovery(data.discovery_time()); break; - case PDP_PACKETS: + case EventKind::PDP_PACKETS: on_pdp_packets(data.entity_count()); break; - case EDP_PACKETS: + case EventKind::EDP_PACKETS: on_edp_packets(data.entity_count()); break; - case SAMPLE_DATAS: + case EventKind::SAMPLE_DATAS: on_sample_datas(data.sample_identity_count()); break; - case PUBLICATION_THROUGHPUT: + case EventKind::PUBLICATION_THROUGHPUT: on_publisher_throughput(data.entity_data()); break; - case SUBSCRIPTION_THROUGHPUT: + case EventKind::SUBSCRIPTION_THROUGHPUT: on_subscriber_throughput(data.entity_data()); break; default: @@ -158,7 +154,7 @@ struct MockListener : IListener MOCK_METHOD1(on_sample_datas, void(const eprosima::fastdds::statistics::SampleIdentityCount&)); MOCK_METHOD1(on_publisher_throughput, void(const eprosima::fastdds::statistics::EntityData&)); MOCK_METHOD1(on_subscriber_throughput, void(const eprosima::fastdds::statistics::EntityData&)); - MOCK_METHOD1(on_unexpected_kind, void(eprosima::fastdds::statistics::EventKind)); + MOCK_METHOD1(on_unexpected_kind, void(uint32_t)); }; class RTPSStatisticsTestsImpl @@ -355,8 +351,8 @@ class RTPSStatisticsTestsImpl void match_endpoints( bool key, - fastrtps::string_255 data_type, - fastrtps::string_255 topic_name) + fastcdr::string_255 data_type, + fastcdr::string_255 topic_name) { using namespace fastrtps; using namespace fastrtps::rtps; @@ -469,9 +465,9 @@ class RTPSStatisticsTests using namespace fastrtps; // Intraprocess must be disable in order to receive DATA callbacks - LibrarySettingsAttributes att; + LibrarySettings att; att.intraprocess_delivery = INTRAPROCESS_OFF; - xmlparser::XMLProfileManager::library_settings(att); + fastrtps::rtps::RTPSDomain::set_library_settings(att); create_participant(); } @@ -503,9 +499,9 @@ TEST_F(RTPSStatisticsTests, statistics_rpts_listener_management) auto nolistener = listener1; nolistener.reset(); - EventKind kind = EventKindBits::PUBLICATION_THROUGHPUT; - EventKind another_kind = EventKindBits::SUBSCRIPTION_THROUGHPUT; - EventKind yet_another_kind = EventKindBits::NETWORK_LATENCY; + uint32_t kind = EventKind::PUBLICATION_THROUGHPUT; + uint32_t another_kind = EventKind::SUBSCRIPTION_THROUGHPUT; + uint32_t yet_another_kind = EventKind::NETWORK_LATENCY; // test the participant apis // + fails to remove an empty listener @@ -635,13 +631,13 @@ TEST_F(RTPSStatisticsTests, statistics_rpts_listener_callbacks) // participant specific callbacks auto participant_listener = make_shared(); ASSERT_TRUE(participant_->add_statistics_listener(participant_listener, - EventKindBits::RTPS_SENT | EventKindBits::NETWORK_LATENCY | EventKindBits::RTPS_LOST)); + EventKind::RTPS_SENT | EventKind::NETWORK_LATENCY | EventKind::RTPS_LOST)); // writer callbacks through participant listener auto participant_writer_listener = make_shared(); ASSERT_TRUE(participant_->add_statistics_listener(participant_writer_listener, - EventKindBits::DATA_COUNT | EventKindBits::RESENT_DATAS | - EventKindBits::PUBLICATION_THROUGHPUT | EventKindBits::SAMPLE_DATAS)); + EventKind::DATA_COUNT | EventKind::RESENT_DATAS | + EventKind::PUBLICATION_THROUGHPUT | EventKind::SAMPLE_DATAS)); // writer specific callbacks auto writer_listener = make_shared(); @@ -650,8 +646,8 @@ TEST_F(RTPSStatisticsTests, statistics_rpts_listener_callbacks) // reader callbacks through participant listener auto participant_reader_listener = make_shared(); ASSERT_TRUE(participant_->add_statistics_listener(participant_reader_listener, - EventKindBits::ACKNACK_COUNT | EventKindBits::HISTORY2HISTORY_LATENCY | - EventKindBits::SUBSCRIPTION_THROUGHPUT)); + EventKind::ACKNACK_COUNT | EventKind::HISTORY2HISTORY_LATENCY | + EventKind::SUBSCRIPTION_THROUGHPUT)); // reader specific callbacks auto reader_listener = make_shared(); @@ -726,28 +722,28 @@ TEST_F(RTPSStatisticsTests, statistics_rpts_listener_callbacks) EXPECT_TRUE(reader_->remove_statistics_listener(reader_listener)); EXPECT_TRUE(participant_->remove_statistics_listener(participant_listener, - EventKindBits::RTPS_SENT | EventKindBits::NETWORK_LATENCY | EventKindBits::RTPS_LOST)); + EventKind::RTPS_SENT | EventKind::NETWORK_LATENCY | EventKind::RTPS_LOST)); EXPECT_TRUE(participant_->remove_statistics_listener(participant_writer_listener, - EventKindBits::DATA_COUNT | EventKindBits::RESENT_DATAS | - EventKindBits::PUBLICATION_THROUGHPUT | EventKindBits::SAMPLE_DATAS)); + EventKind::DATA_COUNT | EventKind::RESENT_DATAS | + EventKind::PUBLICATION_THROUGHPUT | EventKind::SAMPLE_DATAS)); EXPECT_TRUE(participant_->remove_statistics_listener(participant_reader_listener, - EventKindBits::ACKNACK_COUNT | EventKindBits::HISTORY2HISTORY_LATENCY | - EventKindBits::SUBSCRIPTION_THROUGHPUT)); + EventKind::ACKNACK_COUNT | EventKind::HISTORY2HISTORY_LATENCY | + EventKind::SUBSCRIPTION_THROUGHPUT)); }; // Check that setting the mask after creating the endpoints work uint32_t enable_writers_mask = - EventKindBits::HISTORY2HISTORY_LATENCY | - EventKindBits::NETWORK_LATENCY | - EventKindBits::PUBLICATION_THROUGHPUT | - EventKindBits::SUBSCRIPTION_THROUGHPUT | - EventKindBits::RTPS_SENT | - EventKindBits::RTPS_LOST | - EventKindBits::RESENT_DATAS | - EventKindBits::HEARTBEAT_COUNT | - EventKindBits::ACKNACK_COUNT | - EventKindBits::DATA_COUNT | - EventKindBits::SAMPLE_DATAS; + EventKind::HISTORY2HISTORY_LATENCY | + EventKind::NETWORK_LATENCY | + EventKind::PUBLICATION_THROUGHPUT | + EventKind::SUBSCRIPTION_THROUGHPUT | + EventKind::RTPS_SENT | + EventKind::RTPS_LOST | + EventKind::RESENT_DATAS | + EventKind::HEARTBEAT_COUNT | + EventKind::ACKNACK_COUNT | + EventKind::DATA_COUNT | + EventKind::SAMPLE_DATAS; create_endpoints(length, RELIABLE); participant_->set_enabled_statistics_writers_mask(enable_writers_mask); test_execution(); @@ -803,16 +799,16 @@ TEST_F(RTPSStatisticsTests, statistics_rpts_listener_callbacks_fragmented) }); uint32_t enable_writers_mask = - EventKindBits::HISTORY2HISTORY_LATENCY | - EventKindBits::HEARTBEAT_COUNT | - EventKindBits::ACKNACK_COUNT | - EventKindBits::NACKFRAG_COUNT | - EventKindBits::DATA_COUNT; + EventKind::HISTORY2HISTORY_LATENCY | + EventKind::HEARTBEAT_COUNT | + EventKind::ACKNACK_COUNT | + EventKind::NACKFRAG_COUNT | + EventKind::DATA_COUNT; // writer callbacks through participant listener auto participant_listener = make_shared(); - uint32_t mask = EventKindBits::DATA_COUNT | EventKindBits::HEARTBEAT_COUNT - | EventKindBits::ACKNACK_COUNT | EventKindBits::NACKFRAG_COUNT | EventKindBits::HISTORY2HISTORY_LATENCY; + uint32_t mask = EventKind::DATA_COUNT | EventKind::HEARTBEAT_COUNT + | EventKind::ACKNACK_COUNT | EventKind::NACKFRAG_COUNT | EventKind::HISTORY2HISTORY_LATENCY; ASSERT_TRUE(participant_->add_statistics_listener(participant_listener, mask)); participant_->set_enabled_statistics_writers_mask(enable_writers_mask); @@ -913,13 +909,13 @@ TEST_F(RTPSStatisticsTests, statistics_rpts_listener_callbacks_no_enabled_writer // participant specific callbacks auto participant_listener = make_shared(); ASSERT_TRUE(participant_->add_statistics_listener(participant_listener, - EventKindBits::RTPS_SENT | EventKindBits::NETWORK_LATENCY | EventKindBits::RTPS_LOST)); + EventKind::RTPS_SENT | EventKind::NETWORK_LATENCY | EventKind::RTPS_LOST)); // writer callbacks through participant listener auto participant_writer_listener = make_shared(); ASSERT_TRUE(participant_->add_statistics_listener(participant_writer_listener, - EventKindBits::DATA_COUNT | EventKindBits::RESENT_DATAS | - EventKindBits::PUBLICATION_THROUGHPUT | EventKindBits::SAMPLE_DATAS)); + EventKind::DATA_COUNT | EventKind::RESENT_DATAS | + EventKind::PUBLICATION_THROUGHPUT | EventKind::SAMPLE_DATAS)); // writer specific callbacks auto writer_listener = make_shared(); @@ -928,8 +924,8 @@ TEST_F(RTPSStatisticsTests, statistics_rpts_listener_callbacks_no_enabled_writer // reader callbacks through participant listener auto participant_reader_listener = make_shared(); ASSERT_TRUE(participant_->add_statistics_listener(participant_reader_listener, - EventKindBits::ACKNACK_COUNT | EventKindBits::HISTORY2HISTORY_LATENCY | - EventKindBits::SUBSCRIPTION_THROUGHPUT)); + EventKind::ACKNACK_COUNT | EventKind::HISTORY2HISTORY_LATENCY | + EventKind::SUBSCRIPTION_THROUGHPUT)); // reader specific callbacks auto reader_listener = make_shared(); @@ -1004,13 +1000,13 @@ TEST_F(RTPSStatisticsTests, statistics_rpts_listener_callbacks_no_enabled_writer EXPECT_TRUE(reader_->remove_statistics_listener(reader_listener)); EXPECT_TRUE(participant_->remove_statistics_listener(participant_listener, - EventKindBits::RTPS_SENT | EventKindBits::NETWORK_LATENCY | EventKindBits::RTPS_LOST)); + EventKind::RTPS_SENT | EventKind::NETWORK_LATENCY | EventKind::RTPS_LOST)); EXPECT_TRUE(participant_->remove_statistics_listener(participant_writer_listener, - EventKindBits::DATA_COUNT | EventKindBits::RESENT_DATAS | - EventKindBits::PUBLICATION_THROUGHPUT | EventKindBits::SAMPLE_DATAS)); + EventKind::DATA_COUNT | EventKind::RESENT_DATAS | + EventKind::PUBLICATION_THROUGHPUT | EventKind::SAMPLE_DATAS)); EXPECT_TRUE(participant_->remove_statistics_listener(participant_reader_listener, - EventKindBits::ACKNACK_COUNT | EventKindBits::HISTORY2HISTORY_LATENCY | - EventKindBits::SUBSCRIPTION_THROUGHPUT)); + EventKind::ACKNACK_COUNT | EventKind::HISTORY2HISTORY_LATENCY | + EventKind::SUBSCRIPTION_THROUGHPUT)); } /* @@ -1024,14 +1020,14 @@ TEST_F(RTPSStatisticsTests, statistics_rpts_listener_gap_callback) using namespace std; uint32_t enable_writers_mask = - EventKindBits::PUBLICATION_THROUGHPUT | - EventKindBits::RESENT_DATAS | - EventKindBits::HEARTBEAT_COUNT | - EventKindBits::ACKNACK_COUNT | - EventKindBits::NACKFRAG_COUNT | - EventKindBits::GAP_COUNT | - EventKindBits::DATA_COUNT | - EventKindBits::SAMPLE_DATAS; + EventKind::PUBLICATION_THROUGHPUT | + EventKind::RESENT_DATAS | + EventKind::HEARTBEAT_COUNT | + EventKind::ACKNACK_COUNT | + EventKind::NACKFRAG_COUNT | + EventKind::GAP_COUNT | + EventKind::DATA_COUNT | + EventKind::SAMPLE_DATAS; // create the listeners and set expectations auto participant_writer_listener = make_shared(); @@ -1060,7 +1056,7 @@ TEST_F(RTPSStatisticsTests, statistics_rpts_listener_gap_callback) writer_->set_enabled_statistics_writers_mask(enable_writers_mask); // writer callback through participant listener - ASSERT_TRUE(participant_->add_statistics_listener(participant_writer_listener, EventKindBits::GAP_COUNT)); + ASSERT_TRUE(participant_->add_statistics_listener(participant_writer_listener, EventKind::GAP_COUNT)); // writer specific callbacks ASSERT_TRUE(writer_->add_statistics_listener(writer_listener)); @@ -1091,7 +1087,7 @@ TEST_F(RTPSStatisticsTests, statistics_rpts_listener_gap_callback) // release the listeners EXPECT_TRUE(writer_->remove_statistics_listener(writer_listener)); - EXPECT_TRUE(participant_->remove_statistics_listener(participant_writer_listener, EventKindBits::GAP_COUNT)); + EXPECT_TRUE(participant_->remove_statistics_listener(participant_writer_listener, EventKind::GAP_COUNT)); } /* @@ -1105,14 +1101,14 @@ TEST_F(RTPSStatisticsTests, statistics_rpts_listener_discovery_callbacks) using namespace std; uint32_t enable_writers_mask = - EventKindBits::PDP_PACKETS | - EventKindBits::EDP_PACKETS | - EventKindBits::DISCOVERED_ENTITY; + EventKind::PDP_PACKETS | + EventKind::EDP_PACKETS | + EventKind::DISCOVERED_ENTITY; // create the listener and set expectations auto participant_listener = make_shared(); ASSERT_TRUE(participant_->add_statistics_listener(participant_listener, - EventKindBits::DISCOVERED_ENTITY | EventKindBits::PDP_PACKETS | EventKindBits::EDP_PACKETS)); + EventKind::DISCOVERED_ENTITY | EventKind::PDP_PACKETS | EventKind::EDP_PACKETS)); participant_->set_enabled_statistics_writers_mask(enable_writers_mask); // check callbacks on data exchange @@ -1157,7 +1153,7 @@ TEST_F(RTPSStatisticsTests, statistics_rpts_listener_discovery_callbacks) } // release the listener - EXPECT_TRUE(participant_->remove_statistics_listener(participant_listener, EventKindBits::DISCOVERED_ENTITY)); + EXPECT_TRUE(participant_->remove_statistics_listener(participant_listener, EventKind::DISCOVERED_ENTITY)); } /* @@ -1241,11 +1237,11 @@ TEST_F(RTPSStatisticsTests, statistics_rpts_avoid_empty_resent_callbacks) uint16_t length = 255; create_lazy_writer(length, RELIABLE, TRANSIENT_LOCAL); uint32_t enable_writers_mask = - EventKindBits::HEARTBEAT_COUNT | - EventKindBits::DATA_COUNT | - EventKindBits::SAMPLE_DATAS | - EventKindBits::PUBLICATION_THROUGHPUT | - EventKindBits::RESENT_DATAS; + EventKind::HEARTBEAT_COUNT | + EventKind::DATA_COUNT | + EventKind::SAMPLE_DATAS | + EventKind::PUBLICATION_THROUGHPUT | + EventKind::RESENT_DATAS; writer_->set_enabled_statistics_writers_mask(enable_writers_mask); // writer specific callbacks @@ -1348,8 +1344,8 @@ TEST_F(RTPSStatisticsTests, statistics_rpts_unordered_datagrams) // create the listener and set expectations auto participant_listener = make_shared(); - ASSERT_TRUE(participant_->add_statistics_listener(participant_listener, EventKindBits::RTPS_LOST)); - participant_->set_enabled_statistics_writers_mask(EventKindBits::RTPS_LOST); + ASSERT_TRUE(participant_->add_statistics_listener(participant_listener, EventKind::RTPS_LOST)); + participant_->set_enabled_statistics_writers_mask(EventKind::RTPS_LOST); std::vector lost_callback_data; auto callback_action = [&lost_callback_data](const Entity2LocatorTraffic& data) -> void @@ -1386,7 +1382,7 @@ TEST_F(RTPSStatisticsTests, statistics_rpts_unordered_datagrams) std::this_thread::sleep_for(std::chrono::seconds(1)); // release the listener - EXPECT_TRUE(participant_->remove_statistics_listener(participant_listener, EventKindBits::RTPS_LOST)); + EXPECT_TRUE(participant_->remove_statistics_listener(participant_listener, EventKind::RTPS_LOST)); // Check reported callbacks EXPECT_EQ(sizeof(lost_count_notified) / sizeof(lost_count_notified[0]), lost_callback_data.size()); diff --git a/test/unittest/statistics/rtps/mock/Publisher/fastdds/publisher/DataWriterHistory.hpp b/test/unittest/statistics/rtps/mock/Publisher/fastdds/publisher/DataWriterHistory.hpp index f1859167b1f..ef28c734513 100644 --- a/test/unittest/statistics/rtps/mock/Publisher/fastdds/publisher/DataWriterHistory.hpp +++ b/test/unittest/statistics/rtps/mock/Publisher/fastdds/publisher/DataWriterHistory.hpp @@ -23,7 +23,7 @@ #include #include -#include +#include namespace eprosima { namespace fastrtps { diff --git a/test/unittest/statistics/rtps/mock/StatisticsBase/statistics/rtps/StatisticsBase.hpp b/test/unittest/statistics/rtps/mock/StatisticsBase/statistics/rtps/StatisticsBase.hpp index 8d1ee7f86de..8f2b04b0f27 100644 --- a/test/unittest/statistics/rtps/mock/StatisticsBase/statistics/rtps/StatisticsBase.hpp +++ b/test/unittest/statistics/rtps/mock/StatisticsBase/statistics/rtps/StatisticsBase.hpp @@ -24,11 +24,9 @@ #include #include -#include - - -#include +#include +#include namespace eprosima { namespace fastdds { diff --git a/test/unittest/statistics/rtps/mock/StatisticsBase/statistics/rtps/monitor-service/MonitorService.hpp b/test/unittest/statistics/rtps/mock/StatisticsBase/statistics/rtps/monitor-service/MonitorService.hpp index 0160eec3d28..636a93084af 100644 --- a/test/unittest/statistics/rtps/mock/StatisticsBase/statistics/rtps/monitor-service/MonitorService.hpp +++ b/test/unittest/statistics/rtps/mock/StatisticsBase/statistics/rtps/monitor-service/MonitorService.hpp @@ -27,16 +27,16 @@ #include #include +#include #include #include #include #include -#include #include #include #include -#include +#include #include namespace eprosima { @@ -63,7 +63,7 @@ class MonitorService using endpoint_registrator_t = std::function; + const fastdds::dds::WriterQos&)>; MonitorService( const fastrtps::rtps::GUID_t& guid, @@ -167,7 +167,7 @@ class MonitorService */ bool write_status( const fastrtps::rtps::EntityId_t& entity_id, - const std::bitset& changed_statuses, + const std::bitset& changed_statuses, const bool& entity_disposed); /** @@ -233,7 +233,7 @@ class MonitorService //! inserted twice. std::map, bool>> local_entities_; + std::bitset, bool>> local_entities_; std::unique_ptr event_; diff --git a/test/unittest/transport/CMakeLists.txt b/test/unittest/transport/CMakeLists.txt index 9d201a3a95a..fdbe4c131cb 100644 --- a/test/unittest/transport/CMakeLists.txt +++ b/test/unittest/transport/CMakeLists.txt @@ -67,10 +67,6 @@ endif() set(UDPV4TESTS_SOURCE UDPv4Tests.cpp mock/MockReceiverResource.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/Log.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/OStreamConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutErrConsumer.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/attributes/PropertyPolicy.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/attributes/ThreadSettings.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/GuidPrefix_t.cpp @@ -99,10 +95,6 @@ set(UDPV4TESTS_SOURCE set(UDPV6TESTS_SOURCE UDPv6Tests.cpp mock/MockReceiverResource.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/Log.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/OStreamConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutErrConsumer.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/attributes/PropertyPolicy.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/attributes/ThreadSettings.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/GuidPrefix_t.cpp @@ -134,10 +126,6 @@ set(TCPV4TESTS_SOURCE mock/MockReceiverResource.cpp mock/MockTCPChannelResource.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/core/policy/ParameterList.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/Log.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/OStreamConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutErrConsumer.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/attributes/PropertyPolicy.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/attributes/ThreadSettings.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/GuidPrefix_t.cpp @@ -168,7 +156,6 @@ set(TCPV4TESTS_SOURCE ${PROJECT_SOURCE_DIR}/src/cpp/utils/IPFinder.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/IPLocator.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/md5.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/utils/System.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/SystemInfo.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/TimedConditionVariable.cpp ) @@ -185,10 +172,6 @@ set(TCPV6TESTS_SOURCE TCPv6Tests.cpp mock/MockReceiverResource.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/core/policy/ParameterList.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/Log.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/OStreamConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutErrConsumer.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/attributes/PropertyPolicy.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/attributes/ThreadSettings.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/GuidPrefix_t.cpp @@ -219,7 +202,6 @@ set(TCPV6TESTS_SOURCE ${PROJECT_SOURCE_DIR}/src/cpp/utils/IPFinder.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/IPLocator.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/md5.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/utils/System.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/SystemInfo.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/TimedConditionVariable.cpp ) @@ -235,10 +217,6 @@ endif() set(SHAREDMEMTESTS_SOURCE SharedMemTests.cpp mock/MockReceiverResource.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/Log.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/OStreamConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutErrConsumer.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/attributes/PropertyPolicy.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/attributes/ThreadSettings.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/GuidPrefix_t.cpp @@ -305,6 +283,7 @@ target_include_directories(UDPv4Tests PRIVATE ) target_link_libraries(UDPv4Tests fastcdr + fastdds::log GTest::gtest ${MOCKS} $<$:OpenSSL::SSL$OpenSSL::Crypto>) @@ -341,6 +320,7 @@ if(NOT DISABLE_UDPV6_TESTS) ) target_link_libraries(UDPv6Tests fastcdr + fastdds::log GTest::gtest ${MOCKS} $<$:OpenSSL::SSL$OpenSSL::Crypto>) @@ -374,6 +354,7 @@ if(NOT DISABLE_UDPV6_TESTS) ) target_link_libraries(TCPv6Tests fastcdr + fastdds::log GTest::gtest ${MOCKS} $<$:OpenSSL::SSL$OpenSSL::Crypto>) @@ -410,6 +391,7 @@ target_include_directories(TCPv4Tests PRIVATE ) target_link_libraries(TCPv4Tests fastcdr + fastdds::log GTest::gtest ${MOCKS} $<$:OpenSSL::SSL$OpenSSL::Crypto>) @@ -449,6 +431,7 @@ if(IS_THIRDPARTY_BOOST_OK) target_link_libraries(SharedMemTests foonathan_memory fastcdr + fastdds::log GTest::gtest ${MOCKS} $<$:OpenSSL::SSL$OpenSSL::Crypto> diff --git a/test/unittest/transport/SharedMemTests.cpp b/test/unittest/transport/SharedMemTests.cpp index 35470bf9489..8459305fbbd 100644 --- a/test/unittest/transport/SharedMemTests.cpp +++ b/test/unittest/transport/SharedMemTests.cpp @@ -12,24 +12,28 @@ // See the License for the specific language governing permissions and // limitations under the License. -#include -#include -#include -#include -#include -#include "../../../src/cpp/rtps/transport/shared_mem/SharedMemSenderResource.hpp" -#include "../../../src/cpp/rtps/transport/shared_mem/SharedMemManager.hpp" -#include "../../../src/cpp/rtps/transport/shared_mem/SharedMemGlobal.hpp" -#include "../../../src/cpp/rtps/transport/shared_mem/MultiProducerConsumerRingBuffer.hpp" - -#include #include +#include #include #include -#include -#include +#include #include +#include + +#include +#include + +#include + +#include "../../../src/cpp/rtps/transport/shared_mem/MultiProducerConsumerRingBuffer.hpp" +#include "../../../src/cpp/rtps/transport/shared_mem/SharedMemGlobal.hpp" +#include "../../../src/cpp/rtps/transport/shared_mem/SharedMemManager.hpp" +#include "../../../src/cpp/rtps/transport/shared_mem/SharedMemSenderResource.hpp" + +#include +#include + using namespace eprosima::fastrtps; using namespace eprosima::fastrtps::rtps; using namespace eprosima::fastdds; @@ -386,7 +390,7 @@ TEST_F(SHMCondition, wait_notify) // POSIX glibc 2.25 conditions are not robust when used with interprocess shared memory: // https://sourceware.org/bugzilla/show_bug.cgi?id=21422 -// FastRTPS > v1.10.0 SHM has implemented robust conditions to solve issue #1144 +// Fast DDS > v1.10.0 SHM has implemented robust conditions to solve issue #1144 // This is the correspoding regresion test #ifndef _MSC_VER TEST_F(SHMCondition, robust_condition_fix_glibc_deadlock) @@ -733,7 +737,7 @@ TEST_F(SHMTransportTests, send_and_receive_between_ports) MockReceiverResource receiver(transportUnderTest, unicastLocator); MockMessageReceiver* msg_recv = dynamic_cast(receiver.CreateMessageReceiver()); - eprosima::fastrtps::rtps::SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; ASSERT_TRUE(transportUnderTest.OpenOutputChannel(send_resource_list, outputChannelLocator)); ASSERT_FALSE(send_resource_list.empty()); ASSERT_TRUE(transportUnderTest.IsInputChannelOpen(unicastLocator)); @@ -796,7 +800,7 @@ TEST_F(SHMTransportTests, port_and_segment_overflow_discard) outputChannelLocator.kind = LOCATOR_KIND_SHM; outputChannelLocator.port = g_default_port + 1; - eprosima::fastrtps::rtps::SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; ASSERT_TRUE(transportUnderTest.OpenOutputChannel(send_resource_list, outputChannelLocator)); ASSERT_FALSE(send_resource_list.empty()); octet message[4] = { 'H', 'e', 'l', 'l'}; @@ -1781,7 +1785,7 @@ TEST_F(SHMTransportTests, remote_segments_free) LocatorList send_locators_list; send_locators_list.push_back(pub_locator); - eprosima::fastrtps::rtps::SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; ASSERT_TRUE(transport.OpenOutputChannel(send_resource_list, pub_locator)); std::function sub_callback = [&]() @@ -1817,7 +1821,7 @@ TEST_F(SHMTransportTests, remote_segments_free) LocatorList send_locators_list; send_locators_list.push_back(sub_locator); - eprosima::fastrtps::rtps::SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; ASSERT_TRUE(transport.OpenOutputChannel(send_resource_list, sub_locator)); std::chrono::high_resolution_clock::rep total_times = 0; @@ -1920,7 +1924,7 @@ TEST_F(SHMTransportTests, remote_segments_free) LocatorList send_locators_list; send_locators_list.push_back(sub_locator); - eprosima::fastrtps::rtps::SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; ASSERT_TRUE(pub_transport.OpenOutputChannel(send_resource_list, sub_locator)); auto t0 = std::chrono::high_resolution_clock::now(); @@ -2005,7 +2009,7 @@ TEST_F(SHMTransportTests, remote_segments_free) LocatorList send_locators_list; send_locators_list.push_back(sub_locator); - SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; ASSERT_TRUE(pub_transport.OpenOutputChannel(send_resource_list, sub_locator)); auto t0 = std::chrono::high_resolution_clock::now(); @@ -2052,7 +2056,7 @@ TEST_F(SHMTransportTests, dump_file) MockReceiverResource receiver(transportUnderTest, unicastLocator); MockMessageReceiver* msg_recv = dynamic_cast(receiver.CreateMessageReceiver()); - eprosima::fastrtps::rtps::SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; ASSERT_TRUE(transportUnderTest.OpenOutputChannel(send_resource_list, outputChannelLocator)); ASSERT_FALSE(send_resource_list.empty()); ASSERT_TRUE(transportUnderTest.IsInputChannelOpen(unicastLocator)); diff --git a/test/unittest/transport/TCPv4Tests.cpp b/test/unittest/transport/TCPv4Tests.cpp index 7c6ad31efb0..64786dfcd13 100644 --- a/test/unittest/transport/TCPv4Tests.cpp +++ b/test/unittest/transport/TCPv4Tests.cpp @@ -17,22 +17,30 @@ #include #include -#include -#include "mock/MockTCPChannelResource.h" -#include "mock/MockTCPv4Transport.h" + #include #include -#include -#include -#include -#include -#include +#include +#include +#include + +#include "mock/MockTCPChannelResource.h" +#include "mock/MockTCPv4Transport.h" +#include + #include +#include +#include +using namespace eprosima::fastdds; using namespace eprosima::fastrtps; using namespace eprosima::fastrtps::rtps; -using TCPv4Transport = eprosima::fastdds::rtps::TCPv4Transport; +using MockTCPv4Transport = eprosima::fastdds::rtps::MockTCPv4Transport; +using SendResourceList = eprosima::fastdds::rtps::SendResourceList; +using TCPChannelResourceBasic = eprosima::fastdds::rtps::TCPChannelResourceBasic; using TCPHeader = eprosima::fastdds::rtps::TCPHeader; +using TCPv4Transport = eprosima::fastdds::rtps::TCPv4Transport; +using TCPv4TransportDescriptor = eprosima::fastdds::rtps::TCPv4TransportDescriptor; #if defined(_WIN32) #define GET_PID _getpid @@ -75,8 +83,8 @@ class TCPv4Tests : public ::testing::Test void HELPER_SetDescriptorDefaults(); - TCPv4TransportDescriptor descriptor; - TCPv4TransportDescriptor descriptorOnlyOutput; + eprosima::fastdds::rtps::TCPv4TransportDescriptor descriptor; + eprosima::fastdds::rtps::TCPv4TransportDescriptor descriptorOnlyOutput; std::unique_ptr senderThread; std::unique_ptr receiverThread; }; @@ -110,7 +118,7 @@ TEST_F(TCPv4Tests, opening_and_closing_output_channel) genericOutputChannelLocator.kind = LOCATOR_KIND_TCPv4; genericOutputChannelLocator.port = g_output_port; // arbitrary IPLocator::setLogicalPort(genericOutputChannelLocator, g_output_port); - SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; // Then ASSERT_FALSE(transportUnderTest.is_output_channel_open_for(genericOutputChannelLocator)); @@ -137,7 +145,7 @@ TEST_F(TCPv4Tests, opening_and_closing_output_channel_with_listener) // acceptor (no channel resource is created until it receives a connection request). genericOutputChannelLocator.port = g_output_port + 1; IPLocator::setLogicalPort(genericOutputChannelLocator, g_output_port + 1); - SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; // Then ASSERT_FALSE(transportUnderTest.is_output_channel_open_for(genericOutputChannelLocator)); @@ -174,12 +182,12 @@ TEST_F(TCPv4Tests, send_and_receive_between_ports) eprosima::fastdds::dds::Log::SetVerbosity(eprosima::fastdds::dds::Log::Kind::Info); std::regex filter("RTCP(?!_SEQ)"); eprosima::fastdds::dds::Log::SetCategoryFilter(filter); - TCPv4TransportDescriptor recvDescriptor; + eprosima::fastdds::rtps::TCPv4TransportDescriptor recvDescriptor; recvDescriptor.add_listener_port(g_default_port); TCPv4Transport receiveTransportUnderTest(recvDescriptor); receiveTransportUnderTest.init(); - TCPv4TransportDescriptor sendDescriptor; + eprosima::fastdds::rtps::TCPv4TransportDescriptor sendDescriptor; TCPv4Transport sendTransportUnderTest(sendDescriptor); sendTransportUnderTest.init(); @@ -202,7 +210,7 @@ TEST_F(TCPv4Tests, send_and_receive_between_ports) MockMessageReceiver* msg_recv = dynamic_cast(receiver.CreateMessageReceiver()); ASSERT_TRUE(receiveTransportUnderTest.IsInputChannelOpen(inputLocator)); - SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; ASSERT_TRUE(sendTransportUnderTest.OpenOutputChannel(send_resource_list, outputLocator)); ASSERT_FALSE(send_resource_list.empty()); octet message[5] = { 'H', 'e', 'l', 'l', 'o' }; @@ -249,7 +257,7 @@ TEST_F(TCPv4Tests, send_is_rejected_if_buffer_size_is_bigger_to_size_specified_i genericOutputChannelLocator.kind = LOCATOR_KIND_TCPv4; genericOutputChannelLocator.port = g_output_port; IPLocator::setLogicalPort(genericOutputChannelLocator, 7400); - SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; transportUnderTest.OpenOutputChannel(send_resource_list, genericOutputChannelLocator); ASSERT_FALSE(send_resource_list.empty()); @@ -285,7 +293,7 @@ TEST_F(TCPv4Tests, RemoteToMainLocal_simply_strips_out_address_leaving_IP_ANY) ASSERT_EQ(mainLocalLocator.port, remote_locator.port); ASSERT_EQ(mainLocalLocator.kind, remote_locator.kind); - ASSERT_EQ(IPLocator::toIPv4string(mainLocalLocator), s_IPv4AddressAny); + ASSERT_EQ(IPLocator::toIPv4string(mainLocalLocator), eprosima::fastdds::rtps::s_IPv4AddressAny); } TEST_F(TCPv4Tests, match_if_port_AND_address_matches) @@ -317,7 +325,7 @@ TEST_F(TCPv4Tests, send_to_wrong_interface) outputChannelLocator.kind = LOCATOR_KIND_TCPv4; IPLocator::setLogicalPort(outputChannelLocator, 7400); IPLocator::setIPv4(outputChannelLocator, 127, 0, 0, 1); // Loopback - SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; ASSERT_TRUE(transportUnderTest.OpenOutputChannel(send_resource_list, outputChannelLocator)); ASSERT_FALSE(send_resource_list.empty()); @@ -346,7 +354,7 @@ TEST_F(TCPv4Tests, send_to_blocked_interface) outputChannelLocator.kind = LOCATOR_KIND_TCPv4; IPLocator::setLogicalPort(outputChannelLocator, 7400); IPLocator::setIPv4(outputChannelLocator, 127, 0, 0, 1); // Loopback - SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; ASSERT_TRUE(transportUnderTest.OpenOutputChannel(send_resource_list, outputChannelLocator)); ASSERT_FALSE(send_resource_list.empty()); @@ -386,13 +394,13 @@ TEST_F(TCPv4Tests, send_and_receive_between_allowed_interfaces_ports) eprosima::fastdds::dds::Log::SetVerbosity(eprosima::fastdds::dds::Log::Kind::Info); std::regex filter("RTCP(?!_SEQ)"); eprosima::fastdds::dds::Log::SetCategoryFilter(filter); - TCPv4TransportDescriptor recvDescriptor; + eprosima::fastdds::rtps::TCPv4TransportDescriptor recvDescriptor; recvDescriptor.interfaceWhiteList.emplace_back(IPLocator::toIPv4string(locator)); recvDescriptor.add_listener_port(g_default_port); TCPv4Transport receiveTransportUnderTest(recvDescriptor); receiveTransportUnderTest.init(); - TCPv4TransportDescriptor sendDescriptor; + eprosima::fastdds::rtps::TCPv4TransportDescriptor sendDescriptor; sendDescriptor.interfaceWhiteList.emplace_back(IPLocator::toIPv4string(locator)); TCPv4Transport sendTransportUnderTest(sendDescriptor); sendTransportUnderTest.init(); @@ -417,7 +425,7 @@ TEST_F(TCPv4Tests, send_and_receive_between_allowed_interfaces_ports) MockMessageReceiver* msg_recv = dynamic_cast(receiver.CreateMessageReceiver()); ASSERT_TRUE(receiveTransportUnderTest.IsInputChannelOpen(inputLocator)); - SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; ASSERT_TRUE(sendTransportUnderTest.OpenOutputChannel(send_resource_list, outputLocator)); ASSERT_FALSE(send_resource_list.empty()); octet message[5] = { 'H', 'e', 'l', 'l', 'o' }; @@ -490,7 +498,7 @@ TEST_F(TCPv4Tests, send_and_receive_between_allowed_interfaces_ports_by_name) eprosima::fastdds::dds::Log::SetVerbosity(eprosima::fastdds::dds::Log::Kind::Info); std::regex filter("RTCP(?!_SEQ)"); eprosima::fastdds::dds::Log::SetCategoryFilter(filter); - TCPv4TransportDescriptor recvDescriptor; + eprosima::fastdds::rtps::TCPv4TransportDescriptor recvDescriptor; std::cout << "Adding to whitelist: " << interfaces[0].dev << " " << interfaces[0].name << " " << interfaces[0].locator << std::endl; recvDescriptor.interfaceWhiteList.emplace_back(interfaces[0].dev); @@ -499,7 +507,7 @@ TEST_F(TCPv4Tests, send_and_receive_between_allowed_interfaces_ports_by_name) TCPv4Transport receiveTransportUnderTest(recvDescriptor); receiveTransportUnderTest.init(); - TCPv4TransportDescriptor sendDescriptor; + eprosima::fastdds::rtps::TCPv4TransportDescriptor sendDescriptor; sendDescriptor.interfaceWhiteList.emplace_back(interfaces[0].dev); TCPv4Transport sendTransportUnderTest(sendDescriptor); @@ -525,7 +533,7 @@ TEST_F(TCPv4Tests, send_and_receive_between_allowed_interfaces_ports_by_name) MockMessageReceiver* msg_recv = dynamic_cast(receiver.CreateMessageReceiver()); ASSERT_TRUE(receiveTransportUnderTest.IsInputChannelOpen(inputLocator)); - SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; ASSERT_TRUE(sendTransportUnderTest.OpenOutputChannel(send_resource_list, outputLocator)); ASSERT_FALSE(send_resource_list.empty()); octet message[5] = { 'H', 'e', 'l', 'l', 'o' }; @@ -618,7 +626,7 @@ TEST_F(TCPv4Tests, send_and_receive_between_secure_ports_client_verifies) using TLSOptions = TCPTransportDescriptor::TLSConfig::TLSOptions; using TLSVerifyMode = TCPTransportDescriptor::TLSConfig::TLSVerifyMode; - TCPv4TransportDescriptor recvDescriptor; + eprosima::fastdds::rtps::TCPv4TransportDescriptor recvDescriptor; recvDescriptor.add_listener_port(g_default_port); recvDescriptor.apply_security = true; recvDescriptor.tls_config.password = "fastddspwd"; @@ -633,7 +641,7 @@ TEST_F(TCPv4Tests, send_and_receive_between_secure_ports_client_verifies) TCPv4Transport receiveTransportUnderTest(recvDescriptor); receiveTransportUnderTest.init(); - TCPv4TransportDescriptor sendDescriptor; + eprosima::fastdds::rtps::TCPv4TransportDescriptor sendDescriptor; sendDescriptor.apply_security = true; sendDescriptor.tls_config.verify_file = "ca.crt"; sendDescriptor.tls_config.verify_mode = TLSVerifyMode::VERIFY_PEER; @@ -664,7 +672,7 @@ TEST_F(TCPv4Tests, send_and_receive_between_secure_ports_client_verifies) MockMessageReceiver* msg_recv = dynamic_cast(receiver.CreateMessageReceiver()); ASSERT_TRUE(receiveTransportUnderTest.IsInputChannelOpen(inputLocator)); - SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; ASSERT_TRUE(sendTransportUnderTest.OpenOutputChannel(send_resource_list, outputLocator)); ASSERT_FALSE(send_resource_list.empty()); octet message[5] = { 'H', 'e', 'l', 'l', 'o' }; @@ -715,7 +723,7 @@ TEST_F(TCPv4Tests, send_and_receive_between_secure_ports_server_verifies) using TLSVerifyMode = TCPTransportDescriptor::TLSConfig::TLSVerifyMode; using TLSHSRole = TCPTransportDescriptor::TLSConfig::TLSHandShakeRole; - TCPv4TransportDescriptor recvDescriptor; + eprosima::fastdds::rtps::TCPv4TransportDescriptor recvDescriptor; recvDescriptor.add_listener_port(g_default_port); recvDescriptor.apply_security = true; recvDescriptor.tls_config.handshake_role = TLSHSRole::CLIENT; @@ -728,7 +736,7 @@ TEST_F(TCPv4Tests, send_and_receive_between_secure_ports_server_verifies) TCPv4Transport receiveTransportUnderTest(recvDescriptor); receiveTransportUnderTest.init(); - TCPv4TransportDescriptor sendDescriptor; + eprosima::fastdds::rtps::TCPv4TransportDescriptor sendDescriptor; sendDescriptor.apply_security = true; sendDescriptor.tls_config.handshake_role = TLSHSRole::SERVER; sendDescriptor.tls_config.password = "fastddspwd"; @@ -763,7 +771,7 @@ TEST_F(TCPv4Tests, send_and_receive_between_secure_ports_server_verifies) MockMessageReceiver* msg_recv = dynamic_cast(receiver.CreateMessageReceiver()); ASSERT_TRUE(receiveTransportUnderTest.IsInputChannelOpen(inputLocator)); - SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; ASSERT_TRUE(sendTransportUnderTest.OpenOutputChannel(send_resource_list, outputLocator)); ASSERT_FALSE(send_resource_list.empty()); octet message[5] = { 'H', 'e', 'l', 'l', 'o' }; @@ -813,7 +821,7 @@ TEST_F(TCPv4Tests, send_and_receive_between_both_secure_ports) using TLSOptions = TCPTransportDescriptor::TLSConfig::TLSOptions; using TLSVerifyMode = TCPTransportDescriptor::TLSConfig::TLSVerifyMode; - TCPv4TransportDescriptor recvDescriptor; + eprosima::fastdds::rtps::TCPv4TransportDescriptor recvDescriptor; recvDescriptor.add_listener_port(g_default_port); recvDescriptor.apply_security = true; recvDescriptor.tls_config.password = "testkey"; @@ -830,7 +838,7 @@ TEST_F(TCPv4Tests, send_and_receive_between_both_secure_ports) TCPv4Transport receiveTransportUnderTest(recvDescriptor); receiveTransportUnderTest.init(); - TCPv4TransportDescriptor sendDescriptor; + eprosima::fastdds::rtps::TCPv4TransportDescriptor sendDescriptor; sendDescriptor.apply_security = true; sendDescriptor.tls_config.password = "testkey"; sendDescriptor.tls_config.cert_chain_file = "mainsubcert.pem"; @@ -865,7 +873,7 @@ TEST_F(TCPv4Tests, send_and_receive_between_both_secure_ports) MockMessageReceiver* msg_recv = dynamic_cast(receiver.CreateMessageReceiver()); ASSERT_TRUE(receiveTransportUnderTest.IsInputChannelOpen(inputLocator)); - SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; ASSERT_TRUE(sendTransportUnderTest.OpenOutputChannel(send_resource_list, outputLocator)); ASSERT_FALSE(send_resource_list.empty()); octet message[5] = { 'H', 'e', 'l', 'l', 'o' }; @@ -915,7 +923,7 @@ TEST_F(TCPv4Tests, send_and_receive_between_both_secure_ports_untrusted) using TLSOptions = TCPTransportDescriptor::TLSConfig::TLSOptions; using TLSVerifyMode = TCPTransportDescriptor::TLSConfig::TLSVerifyMode; - TCPv4TransportDescriptor recvDescriptor; + eprosima::fastdds::rtps::TCPv4TransportDescriptor recvDescriptor; recvDescriptor.add_listener_port(g_default_port); recvDescriptor.apply_security = true; recvDescriptor.tls_config.password = "testkey"; @@ -932,7 +940,7 @@ TEST_F(TCPv4Tests, send_and_receive_between_both_secure_ports_untrusted) TCPv4Transport receiveTransportUnderTest(recvDescriptor); receiveTransportUnderTest.init(); - TCPv4TransportDescriptor sendDescriptor; + eprosima::fastdds::rtps::TCPv4TransportDescriptor sendDescriptor; sendDescriptor.apply_security = true; sendDescriptor.tls_config.password = "testkey"; sendDescriptor.tls_config.cert_chain_file = "mainsubcert.pem"; @@ -967,7 +975,7 @@ TEST_F(TCPv4Tests, send_and_receive_between_both_secure_ports_untrusted) MockMessageReceiver* msg_recv = dynamic_cast(receiver.CreateMessageReceiver()); ASSERT_TRUE(receiveTransportUnderTest.IsInputChannelOpen(inputLocator)); - SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; ASSERT_TRUE(sendTransportUnderTest.OpenOutputChannel(send_resource_list, outputLocator)); ASSERT_FALSE(send_resource_list.empty()); octet message[5] = { 'H', 'e', 'l', 'l', 'o' }; @@ -1022,7 +1030,7 @@ TEST_F(TCPv4Tests, send_and_receive_between_secure_clients_1) using TLSOptions = TCPTransportDescriptor::TLSConfig::TLSOptions; using TLSHSRole = TCPTransportDescriptor::TLSConfig::TLSHandShakeRole; - TCPv4TransportDescriptor recvDescriptor; + eprosima::fastdds::rtps::TCPv4TransportDescriptor recvDescriptor; recvDescriptor.add_listener_port(g_default_port); recvDescriptor.apply_security = true; recvDescriptor.tls_config.handshake_role = TLSHSRole::CLIENT; @@ -1038,7 +1046,7 @@ TEST_F(TCPv4Tests, send_and_receive_between_secure_clients_1) TCPv4Transport receiveTransportUnderTest(recvDescriptor); receiveTransportUnderTest.init(); - TCPv4TransportDescriptor sendDescriptor; + eprosima::fastdds::rtps::TCPv4TransportDescriptor sendDescriptor; sendDescriptor.apply_security = true; sendDescriptor.tls_config.handshake_role = TLSHSRole::SERVER; sendDescriptor.tls_config.password = "testkey"; @@ -1073,7 +1081,7 @@ TEST_F(TCPv4Tests, send_and_receive_between_secure_clients_1) MockMessageReceiver* msg_recv = dynamic_cast(receiver.CreateMessageReceiver()); ASSERT_TRUE(receiveTransportUnderTest.IsInputChannelOpen(inputLocator)); - SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; ASSERT_TRUE(sendTransportUnderTest.OpenOutputChannel(send_resource_list, outputLocator)); ASSERT_FALSE(send_resource_list.empty()); octet message[5] = { 'H', 'e', 'l', 'l', 'o' }; @@ -1124,7 +1132,7 @@ TEST_F(TCPv4Tests, send_and_receive_between_secure_ports_untrusted_server) using TLSOptions = TCPTransportDescriptor::TLSConfig::TLSOptions; using TLSVerifyMode = TCPTransportDescriptor::TLSConfig::TLSVerifyMode; - TCPv4TransportDescriptor recvDescriptor; + eprosima::fastdds::rtps::TCPv4TransportDescriptor recvDescriptor; recvDescriptor.add_listener_port(g_default_port); recvDescriptor.apply_security = true; recvDescriptor.tls_config.password = "testkey"; @@ -1140,7 +1148,7 @@ TEST_F(TCPv4Tests, send_and_receive_between_secure_ports_untrusted_server) TCPv4Transport receiveTransportUnderTest(recvDescriptor); receiveTransportUnderTest.init(); - TCPv4TransportDescriptor sendDescriptor; + eprosima::fastdds::rtps::TCPv4TransportDescriptor sendDescriptor; sendDescriptor.apply_security = true; sendDescriptor.tls_config.verify_file = "ca.pem"; // This CA doesn't know about these certificates sendDescriptor.tls_config.verify_mode = TLSVerifyMode::VERIFY_PEER; @@ -1172,7 +1180,7 @@ TEST_F(TCPv4Tests, send_and_receive_between_secure_ports_untrusted_server) MockMessageReceiver* msg_recv = dynamic_cast(receiver.CreateMessageReceiver()); ASSERT_TRUE(receiveTransportUnderTest.IsInputChannelOpen(inputLocator)); - SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; ASSERT_TRUE(sendTransportUnderTest.OpenOutputChannel(send_resource_list, outputLocator)); ASSERT_FALSE(send_resource_list.empty()); octet message[5] = { 'H', 'e', 'l', 'l', 'o' }; @@ -1229,7 +1237,7 @@ TEST_F(TCPv4Tests, send_and_receive_between_both_secure_ports_with_sni) using TLSOptions = TCPTransportDescriptor::TLSConfig::TLSOptions; using TLSVerifyMode = TCPTransportDescriptor::TLSConfig::TLSVerifyMode; - TCPv4TransportDescriptor recvDescriptor; + eprosima::fastdds::rtps::TCPv4TransportDescriptor recvDescriptor; recvDescriptor.add_listener_port(g_default_port); recvDescriptor.apply_security = true; recvDescriptor.tls_config.password = "testkey"; @@ -1246,7 +1254,7 @@ TEST_F(TCPv4Tests, send_and_receive_between_both_secure_ports_with_sni) TCPv4Transport receiveTransportUnderTest(recvDescriptor); receiveTransportUnderTest.init(); - TCPv4TransportDescriptor sendDescriptor; + eprosima::fastdds::rtps::TCPv4TransportDescriptor sendDescriptor; sendDescriptor.apply_security = true; sendDescriptor.tls_config.password = "testkey"; sendDescriptor.tls_config.cert_chain_file = "mainsubcert.pem"; @@ -1282,7 +1290,7 @@ TEST_F(TCPv4Tests, send_and_receive_between_both_secure_ports_with_sni) MockMessageReceiver* msg_recv = dynamic_cast(receiver.CreateMessageReceiver()); ASSERT_TRUE(receiveTransportUnderTest.IsInputChannelOpen(inputLocator)); - SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; ASSERT_TRUE(sendTransportUnderTest.OpenOutputChannel(send_resource_list, outputLocator)); ASSERT_FALSE(send_resource_list.empty()); octet message[5] = { 'H', 'e', 'l', 'l', 'o' }; @@ -1337,7 +1345,7 @@ TEST_F(TCPv4Tests, secure_non_blocking_send) // Create a TCP Server transport using TLSOptions = TCPTransportDescriptor::TLSConfig::TLSOptions; using TLSVerifyMode = TCPTransportDescriptor::TLSConfig::TLSVerifyMode; - TCPv4TransportDescriptor senderDescriptor; + eprosima::fastdds::rtps::TCPv4TransportDescriptor senderDescriptor; senderDescriptor.add_listener_port(port); senderDescriptor.apply_security = true; senderDescriptor.non_blocking_send = true; @@ -1436,7 +1444,8 @@ TEST_F(TCPv4Tests, secure_non_blocking_send) auto sender_unbound_channel_resources = senderTransportUnderTest.get_unbound_channel_resources(); ASSERT_TRUE(sender_unbound_channel_resources.size() == 1u); auto sender_channel_resource = - std::static_pointer_cast(sender_unbound_channel_resources[0]); + std::static_pointer_cast( + sender_unbound_channel_resources[0]); // Prepare the message asio::error_code ec; @@ -1476,13 +1485,13 @@ TEST_F(TCPv4Tests, send_and_receive_between_allowed_localhost_interfaces_ports) eprosima::fastdds::dds::Log::SetVerbosity(eprosima::fastdds::dds::Log::Kind::Info); std::regex filter("RTCP(?!_SEQ)"); eprosima::fastdds::dds::Log::SetCategoryFilter(filter); - TCPv4TransportDescriptor recvDescriptor; + eprosima::fastdds::rtps::TCPv4TransportDescriptor recvDescriptor; recvDescriptor.interfaceWhiteList.emplace_back("127.0.0.1"); recvDescriptor.add_listener_port(g_default_port); TCPv4Transport receiveTransportUnderTest(recvDescriptor); receiveTransportUnderTest.init(); - TCPv4TransportDescriptor sendDescriptor; + eprosima::fastdds::rtps::TCPv4TransportDescriptor sendDescriptor; sendDescriptor.interfaceWhiteList.emplace_back("127.0.0.1"); TCPv4Transport sendTransportUnderTest(sendDescriptor); sendTransportUnderTest.init(); @@ -1507,7 +1516,7 @@ TEST_F(TCPv4Tests, send_and_receive_between_allowed_localhost_interfaces_ports) MockMessageReceiver* msg_recv = dynamic_cast(receiver.CreateMessageReceiver()); ASSERT_TRUE(receiveTransportUnderTest.IsInputChannelOpen(inputLocator)); - SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; ASSERT_TRUE(sendTransportUnderTest.OpenOutputChannel(send_resource_list, outputLocator)); ASSERT_FALSE(send_resource_list.empty()); octet message[5] = { 'H', 'e', 'l', 'l', 'o' }; @@ -1571,13 +1580,13 @@ TEST_F(TCPv4Tests, send_and_receive_between_blocked_interfaces_ports) eprosima::fastdds::dds::Log::SetVerbosity(eprosima::fastdds::dds::Log::Kind::Info); std::regex filter("RTCP(?!_SEQ)"); eprosima::fastdds::dds::Log::SetCategoryFilter(filter); - TCPv4TransportDescriptor recvDescriptor; + eprosima::fastdds::rtps::TCPv4TransportDescriptor recvDescriptor; recvDescriptor.interfaceWhiteList.emplace_back(IPLocator::toIPv4string(locator)); recvDescriptor.add_listener_port(g_default_port); TCPv4Transport receiveTransportUnderTest(recvDescriptor); receiveTransportUnderTest.init(); - TCPv4TransportDescriptor sendDescriptor; + eprosima::fastdds::rtps::TCPv4TransportDescriptor sendDescriptor; sendDescriptor.interfaceWhiteList.emplace_back(IPLocator::toIPv4string(locator)); TCPv4Transport sendTransportUnderTest(sendDescriptor); sendTransportUnderTest.init(); @@ -1602,7 +1611,7 @@ TEST_F(TCPv4Tests, send_and_receive_between_blocked_interfaces_ports) MockMessageReceiver* msg_recv = dynamic_cast(receiver.CreateMessageReceiver()); ASSERT_TRUE(receiveTransportUnderTest.IsInputChannelOpen(inputLocator)); - SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; ASSERT_TRUE(sendTransportUnderTest.OpenOutputChannel(send_resource_list, outputLocator)); ASSERT_FALSE(send_resource_list.empty()); octet message[5] = { 'H', 'e', 'l', 'l', 'o' }; @@ -1663,7 +1672,7 @@ TEST_F(TCPv4Tests, receive_unordered_data) "-RTCRTC", "-RTCRT", "-RTCR" }; - struct Receiver : public TransportReceiverInterface + struct Receiver : public eprosima::fastdds::rtps::TransportReceiverInterface { std::array num_received{ 0, 0, 0 }; @@ -1697,7 +1706,7 @@ TEST_F(TCPv4Tests, receive_unordered_data) Receiver receiver; - TCPv4TransportDescriptor test_descriptor = descriptor; + eprosima::fastdds::rtps::TCPv4TransportDescriptor test_descriptor = descriptor; test_descriptor.check_crc = false; TCPv4Transport uut(test_descriptor); ASSERT_TRUE(uut.init()) << "Failed to initialize transport. Port " << g_default_port << " may be in use"; @@ -1790,7 +1799,7 @@ TEST_F(TCPv4Tests, header_read_interrumption) std::regex filter("RTCP(?!_SEQ)"); eprosima::fastdds::dds::Log::SetCategoryFilter(filter); - TCPv4TransportDescriptor test_descriptor; + eprosima::fastdds::rtps::TCPv4TransportDescriptor test_descriptor; test_descriptor.add_listener_port(g_default_port); TCPv4Transport transportUnderTest(test_descriptor); transportUnderTest.init(); @@ -1832,7 +1841,7 @@ TEST_F(TCPv4Tests, header_read_interrumption) TEST_F(TCPv4Tests, autofill_port) { // Check normal port assignation - TCPv4TransportDescriptor test_descriptor; + eprosima::fastdds::rtps::TCPv4TransportDescriptor test_descriptor; test_descriptor.add_listener_port(g_default_port); TCPv4Transport transportUnderTest(test_descriptor); transportUnderTest.init(); @@ -1840,7 +1849,7 @@ TEST_F(TCPv4Tests, autofill_port) EXPECT_TRUE(transportUnderTest.configuration()->listening_ports[0] == g_default_port); // Check default port assignation - TCPv4TransportDescriptor test_descriptor_autofill; + eprosima::fastdds::rtps::TCPv4TransportDescriptor test_descriptor_autofill; test_descriptor_autofill.add_listener_port(0); TCPv4Transport transportUnderTest_autofill(test_descriptor_autofill); transportUnderTest_autofill.init(); @@ -1854,16 +1863,16 @@ TEST_F(TCPv4Tests, autofill_port) // process this lead to overwriting server's channel resources map elements. TEST_F(TCPv4Tests, client_announced_local_port_uniqueness) { - TCPv4TransportDescriptor recvDescriptor; + eprosima::fastdds::rtps::TCPv4TransportDescriptor recvDescriptor; recvDescriptor.add_listener_port(g_default_port); MockTCPv4Transport receiveTransportUnderTest(recvDescriptor); receiveTransportUnderTest.init(); - TCPv4TransportDescriptor sendDescriptor_1; + eprosima::fastdds::rtps::TCPv4TransportDescriptor sendDescriptor_1; TCPv4Transport sendTransportUnderTest_1(sendDescriptor_1); sendTransportUnderTest_1.init(); - TCPv4TransportDescriptor sendDescriptor_2; + eprosima::fastdds::rtps::TCPv4TransportDescriptor sendDescriptor_2; TCPv4Transport sendTransportUnderTest_2(sendDescriptor_2); sendTransportUnderTest_2.init(); @@ -1873,11 +1882,11 @@ TEST_F(TCPv4Tests, client_announced_local_port_uniqueness) outputLocator.port = g_default_port; IPLocator::setLogicalPort(outputLocator, 7410); - SendResourceList send_resource_list_1; + eprosima::fastdds::rtps::SendResourceList send_resource_list_1; ASSERT_TRUE(sendTransportUnderTest_1.OpenOutputChannel(send_resource_list_1, outputLocator)); ASSERT_FALSE(send_resource_list_1.empty()); - SendResourceList send_resource_list_2; + eprosima::fastdds::rtps::SendResourceList send_resource_list_2; ASSERT_TRUE(sendTransportUnderTest_2.OpenOutputChannel(send_resource_list_2, outputLocator)); ASSERT_FALSE(send_resource_list_2.empty()); @@ -1894,7 +1903,7 @@ TEST_F(TCPv4Tests, non_blocking_send) uint16_t port = g_default_port; uint32_t msg_size = eprosima::fastdds::rtps::s_minimumSocketBuffer; // Create a TCP Server transport - TCPv4TransportDescriptor senderDescriptor; + eprosima::fastdds::rtps::TCPv4TransportDescriptor senderDescriptor; senderDescriptor.add_listener_port(port); senderDescriptor.non_blocking_send = true; senderDescriptor.sendBufferSize = msg_size; @@ -1949,7 +1958,8 @@ TEST_F(TCPv4Tests, non_blocking_send) auto sender_unbound_channel_resources = senderTransportUnderTest.get_unbound_channel_resources(); ASSERT_TRUE(sender_unbound_channel_resources.size() == 1u); auto sender_channel_resource = - std::static_pointer_cast(sender_unbound_channel_resources[0]); + std::static_pointer_cast( + sender_unbound_channel_resources[0]); // Prepare the message asio::error_code ec; @@ -1987,13 +1997,13 @@ TEST_F(TCPv4Tests, reconnect_after_open_port_failure) eprosima::fastdds::dds::Log::SetVerbosity(eprosima::fastdds::dds::Log::Warning); uint16_t port = g_default_port; // Create a TCP Server transport - TCPv4TransportDescriptor serverDescriptor; + eprosima::fastdds::rtps::TCPv4TransportDescriptor serverDescriptor; serverDescriptor.add_listener_port(port); std::unique_ptr serverTransportUnderTest(new TCPv4Transport(serverDescriptor)); serverTransportUnderTest->init(); // Create a TCP Client transport - TCPv4TransportDescriptor clientDescriptor; + eprosima::fastdds::rtps::TCPv4TransportDescriptor clientDescriptor; std::unique_ptr clientTransportUnderTest(new MockTCPv4Transport(clientDescriptor)); clientTransportUnderTest->init(); @@ -2004,7 +2014,7 @@ TEST_F(TCPv4Tests, reconnect_after_open_port_failure) // Connect client to server EXPECT_TRUE(serverTransportUnderTest->OpenInputChannel(initialPeerLocator, nullptr, 0x00FF)); - SendResourceList client_resource_list; + eprosima::fastdds::rtps::SendResourceList client_resource_list; ASSERT_TRUE(clientTransportUnderTest->OpenOutputChannel(client_resource_list, initialPeerLocator)); ASSERT_FALSE(client_resource_list.empty()); std::this_thread::sleep_for(std::chrono::milliseconds(300)); @@ -2082,7 +2092,7 @@ TEST_F(TCPv4Tests, opening_output_channel_with_same_locator_as_local_listening_p IPLocator::setIPv4(lowerOutputChannelLocator, 1, 1, 1, 1); IPLocator::setIPv4(higherOutputChannelLocator, 255, 255, 255, 255); - SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; // If the remote address is lower than the local one, no channel must be created but it must be added to the send_resource_list ASSERT_TRUE(transportUnderTest.OpenOutputChannel(send_resource_list, lowerOutputChannelLocator)); @@ -2109,7 +2119,7 @@ TEST_F(TCPv4Tests, remove_from_send_resource_list) for (const std::string& test_case : test_cases) { - TCPv4TransportDescriptor send_descriptor; + eprosima::fastdds::rtps::TCPv4TransportDescriptor send_descriptor; MockTCPv4Transport send_transport_under_test(send_descriptor); send_transport_under_test.init(); @@ -2136,7 +2146,7 @@ TEST_F(TCPv4Tests, remove_from_send_resource_list) initial_peer_list.push_back(initial_peer_locator); - SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; ASSERT_TRUE(send_transport_under_test.OpenOutputChannel(send_resource_list, discovery_locator)); ASSERT_TRUE(send_transport_under_test.OpenOutputChannel(send_resource_list, initial_peer_locator)); ASSERT_EQ(send_resource_list.size(), 2u); @@ -2193,7 +2203,7 @@ TEST_F(TCPv4Tests, add_logical_port_on_send_resource_creation) // TCP Client { uint16_t port = 12345; - TCPv4TransportDescriptor clientDescriptor; + eprosima::fastdds::rtps::TCPv4TransportDescriptor clientDescriptor; std::unique_ptr clientTransportUnderTest(new MockTCPv4Transport(clientDescriptor)); clientTransportUnderTest->init(); @@ -2203,7 +2213,7 @@ TEST_F(TCPv4Tests, add_logical_port_on_send_resource_creation) IPLocator::setLogicalPort(initialPeerLocator, 7410); // OpenOutputChannel - SendResourceList client_resource_list; + eprosima::fastdds::rtps::SendResourceList client_resource_list; ASSERT_TRUE(clientTransportUnderTest->OpenOutputChannel(client_resource_list, initialPeerLocator)); IPLocator::setLogicalPort(initialPeerLocator, 7411); ASSERT_TRUE(clientTransportUnderTest->OpenOutputChannel(client_resource_list, initialPeerLocator)); @@ -2223,7 +2233,7 @@ TEST_F(TCPv4Tests, add_logical_port_on_send_resource_creation) // Discovered participant physical port has to have a lower value than the listening port to behave as a server uint16_t participantPhysicalLocator = 12344; // Create a TCP Server transport - TCPv4TransportDescriptor serverDescriptor; + eprosima::fastdds::rtps::TCPv4TransportDescriptor serverDescriptor; serverDescriptor.add_listener_port(port); std::unique_ptr serverTransportUnderTest(new MockTCPv4Transport(serverDescriptor)); serverTransportUnderTest->init(); @@ -2235,7 +2245,7 @@ TEST_F(TCPv4Tests, add_logical_port_on_send_resource_creation) IPLocator::setLogicalPort(discoveredParticipantLocator, 7410); // OpenOutputChannel - SendResourceList server_resource_list; + eprosima::fastdds::rtps::SendResourceList server_resource_list; ASSERT_TRUE(serverTransportUnderTest->OpenOutputChannel(server_resource_list, discoveredParticipantLocator)); IPLocator::setLogicalPort(discoveredParticipantLocator, 7411); ASSERT_TRUE(serverTransportUnderTest->OpenOutputChannel(server_resource_list, discoveredParticipantLocator)); @@ -2258,7 +2268,7 @@ TEST_F(TCPv4Tests, add_logical_port_on_send_resource_creation) // Discovered participant physical port has to have a larger value than the listening port to behave as a client uint16_t participantPhysicalLocator = 12346; // Create a TCP Client transport - TCPv4TransportDescriptor clientDescriptor; + eprosima::fastdds::rtps::TCPv4TransportDescriptor clientDescriptor; clientDescriptor.add_listener_port(port); std::unique_ptr clientTransportUnderTest(new MockTCPv4Transport(clientDescriptor)); clientTransportUnderTest->init(); @@ -2270,7 +2280,7 @@ TEST_F(TCPv4Tests, add_logical_port_on_send_resource_creation) IPLocator::setLogicalPort(discoveredParticipantLocator, 7410); // OpenOutputChannel - SendResourceList client_resource_list; + eprosima::fastdds::rtps::SendResourceList client_resource_list; ASSERT_TRUE(clientTransportUnderTest->OpenOutputChannel(client_resource_list, discoveredParticipantLocator)); IPLocator::setLogicalPort(discoveredParticipantLocator, 7411); ASSERT_TRUE(clientTransportUnderTest->OpenOutputChannel(client_resource_list, discoveredParticipantLocator)); diff --git a/test/unittest/transport/TCPv6Tests.cpp b/test/unittest/transport/TCPv6Tests.cpp index c88a79ff063..c5abb31ca88 100644 --- a/test/unittest/transport/TCPv6Tests.cpp +++ b/test/unittest/transport/TCPv6Tests.cpp @@ -21,18 +21,20 @@ #include #include #include -#include -#include -#include +#include +#include -#include -#include "mock/MockTCPv6Transport.h" #include #include +#include + +#include "mock/MockTCPv6Transport.h" +#include using namespace eprosima::fastrtps::rtps; using namespace eprosima::fastrtps; using TCPv6Transport = eprosima::fastdds::rtps::TCPv6Transport; +using TCPv6TransportDescriptor = eprosima::fastdds::rtps::TCPv6TransportDescriptor; #if defined(_WIN32) #define GET_PID _getpid @@ -78,7 +80,7 @@ class TCPv6Tests : public ::testing::Test void HELPER_SetDescriptorDefaults(); - TCPv6TransportDescriptor descriptor; + eprosima::fastdds::rtps::TCPv6TransportDescriptor descriptor; std::unique_ptr senderThread; std::unique_ptr receiverThread; }; @@ -164,7 +166,7 @@ TEST_F(TCPv6Tests, opening_and_closing_input_channel) RTPSParticipantAttributes p_attr{}; NetworkFactory factory{p_attr}; - factory.RegisterTransport(descriptor); + factory.RegisterTransport(descriptor); std::vector> receivers; factory.BuildReceiverResources(multicastFilterLocator, receivers, 0x8FFF); ReceiverResource* receiver = receivers.back().get(); @@ -183,7 +185,7 @@ TEST_F(TCPv6Tests, opening_and_closing_input_channel) TEST_F(TCPv6Tests, autofill_port) { // Check normal port assignation - TCPv6TransportDescriptor test_descriptor; + eprosima::fastdds::rtps::TCPv6TransportDescriptor test_descriptor; test_descriptor.add_listener_port(g_default_port); TCPv6Transport transportUnderTest(test_descriptor); transportUnderTest.init(); @@ -191,7 +193,7 @@ TEST_F(TCPv6Tests, autofill_port) EXPECT_TRUE(transportUnderTest.configuration()->listening_ports[0] == g_default_port); // Check default port assignation - TCPv6TransportDescriptor test_descriptor_autofill; + eprosima::fastdds::rtps::TCPv6TransportDescriptor test_descriptor_autofill; test_descriptor_autofill.add_listener_port(0); TCPv6Transport transportUnderTest_autofill(test_descriptor_autofill); transportUnderTest_autofill.init(); @@ -269,16 +271,16 @@ TEST_F(TCPv6Tests, check_TCPv6_interface_whitelist_initialization) // process this lead to overwriting server's channel resources map elements. TEST_F(TCPv6Tests, client_announced_local_port_uniqueness) { - TCPv6TransportDescriptor recvDescriptor; + eprosima::fastdds::rtps::TCPv6TransportDescriptor recvDescriptor; recvDescriptor.add_listener_port(g_default_port); MockTCPv6Transport receiveTransportUnderTest(recvDescriptor); receiveTransportUnderTest.init(); - TCPv6TransportDescriptor sendDescriptor_1; + eprosima::fastdds::rtps::TCPv6TransportDescriptor sendDescriptor_1; TCPv6Transport sendTransportUnderTest_1(sendDescriptor_1); sendTransportUnderTest_1.init(); - TCPv6TransportDescriptor sendDescriptor_2; + eprosima::fastdds::rtps::TCPv6TransportDescriptor sendDescriptor_2; TCPv6Transport sendTransportUnderTest_2(sendDescriptor_2); sendTransportUnderTest_2.init(); @@ -288,11 +290,11 @@ TEST_F(TCPv6Tests, client_announced_local_port_uniqueness) outputLocator.port = g_default_port; IPLocator::setLogicalPort(outputLocator, 7610); - SendResourceList send_resource_list_1; + eprosima::fastdds::rtps::SendResourceList send_resource_list_1; ASSERT_TRUE(sendTransportUnderTest_1.OpenOutputChannel(send_resource_list_1, outputLocator)); ASSERT_FALSE(send_resource_list_1.empty()); - SendResourceList send_resource_list_2; + eprosima::fastdds::rtps::SendResourceList send_resource_list_2; ASSERT_TRUE(sendTransportUnderTest_2.OpenOutputChannel(send_resource_list_2, outputLocator)); ASSERT_FALSE(send_resource_list_2.empty()); @@ -309,7 +311,7 @@ TEST_F(TCPv6Tests, non_blocking_send) uint16_t port = g_default_port; uint32_t msg_size = eprosima::fastdds::rtps::s_minimumSocketBuffer; // Create a TCP Server transport - TCPv6TransportDescriptor senderDescriptor; + eprosima::fastdds::rtps::TCPv6TransportDescriptor senderDescriptor; senderDescriptor.add_listener_port(port); senderDescriptor.non_blocking_send = true; senderDescriptor.sendBufferSize = msg_size; @@ -402,13 +404,13 @@ TEST_F(TCPv6Tests, reconnect_after_open_port_failure) eprosima::fastdds::dds::Log::SetVerbosity(eprosima::fastdds::dds::Log::Warning); uint16_t port = g_default_port; // Create a TCP Server transport - TCPv6TransportDescriptor serverDescriptor; + eprosima::fastdds::rtps::TCPv6TransportDescriptor serverDescriptor; serverDescriptor.add_listener_port(port); std::unique_ptr serverTransportUnderTest(new TCPv6Transport(serverDescriptor)); serverTransportUnderTest->init(); // Create a TCP Client transport - TCPv6TransportDescriptor clientDescriptor; + eprosima::fastdds::rtps::TCPv6TransportDescriptor clientDescriptor; std::unique_ptr clientTransportUnderTest(new MockTCPv6Transport(clientDescriptor)); clientTransportUnderTest->init(); @@ -419,7 +421,7 @@ TEST_F(TCPv6Tests, reconnect_after_open_port_failure) // Connect client to server EXPECT_TRUE(serverTransportUnderTest->OpenInputChannel(initialPeerLocator, nullptr, 0x00FF)); - SendResourceList client_resource_list; + eprosima::fastdds::rtps::SendResourceList client_resource_list; ASSERT_TRUE(clientTransportUnderTest->OpenOutputChannel(client_resource_list, initialPeerLocator)); ASSERT_FALSE(client_resource_list.empty()); std::this_thread::sleep_for(std::chrono::milliseconds(300)); @@ -496,7 +498,7 @@ TEST_F(TCPv6Tests, opening_output_channel_with_same_locator_as_local_listening_p IPLocator::setIPv6(lowerOutputChannelLocator, "::"); IPLocator::setIPv6(higherOutputChannelLocator, "ffff:ffff:ffff:ffff:ffff:ffff:ffff:ffff"); - SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; // If the remote address is lower than the local one, no channel must be created but it must be added to the send_resource_list ASSERT_TRUE(transportUnderTest.OpenOutputChannel(send_resource_list, lowerOutputChannelLocator)); @@ -512,7 +514,7 @@ TEST_F(TCPv6Tests, opening_output_channel_with_same_locator_as_local_listening_p // from the channel_resources_map. TEST_F(TCPv6Tests, remove_from_send_resource_list) { - TCPv6TransportDescriptor send_descriptor; + eprosima::fastdds::rtps::TCPv6TransportDescriptor send_descriptor; MockTCPv6Transport send_transport_under_test(send_descriptor); send_transport_under_test.init(); @@ -527,7 +529,7 @@ TEST_F(TCPv6Tests, remove_from_send_resource_list) LocatorList_t initial_peer_list; initial_peer_list.push_back(output_locator_2); - SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; ASSERT_TRUE(send_transport_under_test.OpenOutputChannel(send_resource_list, output_locator_1)); ASSERT_TRUE(send_transport_under_test.OpenOutputChannel(send_resource_list, output_locator_2)); ASSERT_EQ(send_resource_list.size(), 2u); @@ -572,7 +574,7 @@ TEST_F(TCPv6Tests, add_logical_port_on_send_resource_creation) // TCP Client { uint16_t port = 12345; - TCPv6TransportDescriptor clientDescriptor; + eprosima::fastdds::rtps::TCPv6TransportDescriptor clientDescriptor; std::unique_ptr clientTransportUnderTest(new MockTCPv6Transport(clientDescriptor)); clientTransportUnderTest->init(); @@ -582,7 +584,7 @@ TEST_F(TCPv6Tests, add_logical_port_on_send_resource_creation) IPLocator::setLogicalPort(initialPeerLocator, 7410); // OpenOutputChannel - SendResourceList client_resource_list; + eprosima::fastdds::rtps::SendResourceList client_resource_list; ASSERT_TRUE(clientTransportUnderTest->OpenOutputChannel(client_resource_list, initialPeerLocator)); IPLocator::setLogicalPort(initialPeerLocator, 7411); ASSERT_TRUE(clientTransportUnderTest->OpenOutputChannel(client_resource_list, initialPeerLocator)); @@ -602,7 +604,7 @@ TEST_F(TCPv6Tests, add_logical_port_on_send_resource_creation) // Discovered participant physical port has to have a lower value than the listening port to behave as a server uint16_t participantPhysicalLocator = 12344; // Create a TCP Server transport - TCPv6TransportDescriptor serverDescriptor; + eprosima::fastdds::rtps::TCPv6TransportDescriptor serverDescriptor; serverDescriptor.add_listener_port(port); std::unique_ptr serverTransportUnderTest(new MockTCPv6Transport(serverDescriptor)); serverTransportUnderTest->init(); @@ -613,7 +615,7 @@ TEST_F(TCPv6Tests, add_logical_port_on_send_resource_creation) IPLocator::setLogicalPort(discoveredParticipantLocator, 7410); // OpenOutputChannel - SendResourceList server_resource_list; + eprosima::fastdds::rtps::SendResourceList server_resource_list; ASSERT_TRUE(serverTransportUnderTest->OpenOutputChannel(server_resource_list, discoveredParticipantLocator)); IPLocator::setLogicalPort(discoveredParticipantLocator, 7411); ASSERT_TRUE(serverTransportUnderTest->OpenOutputChannel(server_resource_list, discoveredParticipantLocator)); @@ -636,7 +638,7 @@ TEST_F(TCPv6Tests, add_logical_port_on_send_resource_creation) // Discovered participant physical port has to have a larger value than the listening port to behave as a client uint16_t participantPhysicalLocator = 12346; // Create a TCP Client transport - TCPv6TransportDescriptor clientDescriptor; + eprosima::fastdds::rtps::TCPv6TransportDescriptor clientDescriptor; clientDescriptor.add_listener_port(port); std::unique_ptr clientTransportUnderTest(new MockTCPv6Transport(clientDescriptor)); clientTransportUnderTest->init(); @@ -647,7 +649,7 @@ TEST_F(TCPv6Tests, add_logical_port_on_send_resource_creation) IPLocator::setLogicalPort(discoveredParticipantLocator, 7410); // OpenOutputChannel - SendResourceList client_resource_list; + eprosima::fastdds::rtps::SendResourceList client_resource_list; ASSERT_TRUE(clientTransportUnderTest->OpenOutputChannel(client_resource_list, discoveredParticipantLocator)); IPLocator::setLogicalPort(discoveredParticipantLocator, 7411); ASSERT_TRUE(clientTransportUnderTest->OpenOutputChannel(client_resource_list, discoveredParticipantLocator)); diff --git a/test/unittest/transport/UDPv4Tests.cpp b/test/unittest/transport/UDPv4Tests.cpp index 430e58feabf..21d5f2d037b 100644 --- a/test/unittest/transport/UDPv4Tests.cpp +++ b/test/unittest/transport/UDPv4Tests.cpp @@ -18,17 +18,21 @@ #include #include -#include -#include -#include -#include +#include +#include +#include + +#include #include #include +using namespace eprosima::fastdds; using namespace eprosima::fastrtps; using namespace eprosima::fastrtps::rtps; using UDPv4Transport = eprosima::fastdds::rtps::UDPv4Transport; +using UDPv4TransportDescriptor = eprosima::fastdds::rtps::UDPv4TransportDescriptor; +using SendResourceList = eprosima::fastdds::rtps::SendResourceList; #ifndef __APPLE__ const uint32_t ReceiveBufferCapacity = 65536; @@ -70,7 +74,7 @@ class UDPv4Tests : public ::testing::Test void HELPER_SetDescriptorDefaults(); - UDPv4TransportDescriptor descriptor; + eprosima::fastdds::rtps::UDPv4TransportDescriptor descriptor; std::unique_ptr senderThread; std::unique_ptr receiverThread; }; @@ -129,7 +133,7 @@ TEST_F(UDPv4Tests, send_and_receive_between_ports) MockReceiverResource receiver(transportUnderTest, multicastLocator); MockMessageReceiver* msg_recv = dynamic_cast(receiver.CreateMessageReceiver()); - SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; ASSERT_TRUE(transportUnderTest.OpenOutputChannel(send_resource_list, multicastLocator)); ASSERT_TRUE(transportUnderTest.OpenOutputChannel(send_resource_list, outputChannelLocator)); // Includes loopback ASSERT_FALSE(send_resource_list.empty()); @@ -189,7 +193,7 @@ TEST_F(UDPv4Tests, send_to_loopback) MockReceiverResource receiver(transportUnderTest, multicastLocator); MockMessageReceiver* msg_recv = dynamic_cast(receiver.CreateMessageReceiver()); - SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; ASSERT_TRUE(transportUnderTest.OpenOutputChannel(send_resource_list, multicastLocator)); ASSERT_TRUE(transportUnderTest.OpenOutputChannel(send_resource_list, outputChannelLocator)); // Includes loopback ASSERT_FALSE(send_resource_list.empty()); @@ -238,7 +242,7 @@ TEST_F(UDPv4Tests, send_is_rejected_if_buffer_size_is_bigger_to_size_specified_i UDPv4Transport transportUnderTest(descriptor); transportUnderTest.init(); - SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; Locator_t genericOutputChannelLocator; genericOutputChannelLocator.kind = LOCATOR_KIND_UDPv4; genericOutputChannelLocator.port = g_default_port; @@ -277,7 +281,7 @@ TEST_F(UDPv4Tests, RemoteToMainLocal_simply_strips_out_address_leaving_IP_ANY) ASSERT_EQ(mainLocalLocator.port, remote_locator.port); ASSERT_EQ(mainLocalLocator.kind, remote_locator.kind); - ASSERT_EQ(IPLocator::toIPv4string(mainLocalLocator), s_IPv4AddressAny); + ASSERT_EQ(IPLocator::toIPv4string(mainLocalLocator), eprosima::fastdds::rtps::s_IPv4AddressAny); } TEST_F(UDPv4Tests, match_if_port_AND_address_matches) @@ -304,7 +308,7 @@ TEST_F(UDPv4Tests, send_to_wrong_interface) UDPv4Transport transportUnderTest(descriptor); transportUnderTest.init(); - SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; Locator_t outputChannelLocator; outputChannelLocator.port = g_default_port; outputChannelLocator.kind = LOCATOR_KIND_UDPv4; @@ -332,7 +336,7 @@ TEST_F(UDPv4Tests, send_to_blocked_interface) UDPv4Transport transportUnderTest(descriptor); transportUnderTest.init(); - SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; Locator_t outputChannelLocator; outputChannelLocator.port = g_default_port; outputChannelLocator.kind = LOCATOR_KIND_UDPv4; @@ -362,7 +366,7 @@ TEST_F(UDPv4Tests, send_to_allowed_interface) UDPv4Transport transportUnderTest(descriptor); transportUnderTest.init(); - SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; Locator_t outputChannelLocator; outputChannelLocator.port = g_default_port; outputChannelLocator.kind = LOCATOR_KIND_UDPv4; @@ -429,7 +433,7 @@ TEST_F(UDPv4Tests, send_and_receive_between_allowed_sockets_using_localhost) MockReceiverResource receiver(transportUnderTest, unicastLocator); MockMessageReceiver* msg_recv = dynamic_cast(receiver.CreateMessageReceiver()); - SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; ASSERT_TRUE(transportUnderTest.OpenOutputChannel(send_resource_list, unicastLocator)); ASSERT_TRUE(transportUnderTest.OpenOutputChannel(send_resource_list, outputChannelLocator)); // Includes loopback ASSERT_FALSE(send_resource_list.empty()); @@ -467,9 +471,9 @@ TEST_F(UDPv4Tests, send_and_receive_between_allowed_sockets_using_unicast) if (interfaces.size() > 0) { - for (const auto& interface : interfaces) + for (const auto& network_interface : interfaces) { - descriptor.interfaceWhiteList.push_back(interface.name); + descriptor.interfaceWhiteList.push_back(network_interface.name); } UDPv4Transport transportUnderTest(descriptor); transportUnderTest.init(); @@ -490,7 +494,7 @@ TEST_F(UDPv4Tests, send_and_receive_between_allowed_sockets_using_unicast) MockReceiverResource receiver(transportUnderTest, unicastLocator); MockMessageReceiver* msg_recv = dynamic_cast(receiver.CreateMessageReceiver()); - SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; ASSERT_TRUE(transportUnderTest.OpenOutputChannel(send_resource_list, unicastLocator)); ASSERT_TRUE(transportUnderTest.OpenOutputChannel(send_resource_list, outputChannelLocator)); // Includes loopback ASSERT_FALSE(send_resource_list.empty()); @@ -529,9 +533,9 @@ TEST_F(UDPv4Tests, send_and_receive_between_allowed_sockets_using_unicast_to_mul if (interfaces.size() > 0) { - for (const auto& interface : interfaces) + for (const auto& network_interface : interfaces) { - descriptor.interfaceWhiteList.push_back(interface.name); + descriptor.interfaceWhiteList.push_back(network_interface.name); } UDPv4Transport transportUnderTest(descriptor); transportUnderTest.init(); @@ -552,7 +556,7 @@ TEST_F(UDPv4Tests, send_and_receive_between_allowed_sockets_using_unicast_to_mul MockReceiverResource receiver(transportUnderTest, unicastLocator); MockMessageReceiver* msg_recv = dynamic_cast(receiver.CreateMessageReceiver()); - SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; ASSERT_TRUE(transportUnderTest.OpenOutputChannel(send_resource_list, unicastLocator)); ASSERT_TRUE(transportUnderTest.OpenOutputChannel(send_resource_list, outputChannelLocator)); // Includes loopback ASSERT_FALSE(send_resource_list.empty()); @@ -656,7 +660,7 @@ TEST_F(UDPv4Tests, simple_throughput) sub_locator.port = 50000; IPLocator::setIPv4(sub_locator, 127, 0, 0, 1); - UDPv4TransportDescriptor my_descriptor; + eprosima::fastdds::rtps::UDPv4TransportDescriptor my_descriptor; // Subscriber @@ -681,7 +685,7 @@ TEST_F(UDPv4Tests, simple_throughput) LocatorList_t send_locators_list; send_locators_list.push_back(sub_locator); - SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; ASSERT_TRUE(pub_transport.OpenOutputChannel(send_resource_list, sub_locator)); auto t0 = std::chrono::high_resolution_clock::now(); diff --git a/test/unittest/transport/UDPv6Tests.cpp b/test/unittest/transport/UDPv6Tests.cpp index 805518934c5..803753dfb9d 100644 --- a/test/unittest/transport/UDPv6Tests.cpp +++ b/test/unittest/transport/UDPv6Tests.cpp @@ -19,16 +19,20 @@ #include #include -#include -#include -#include +#include +#include -#include #include +#include -using namespace eprosima::fastrtps::rtps; +#include + +using namespace eprosima::fastdds; using namespace eprosima::fastrtps; +using namespace eprosima::fastrtps::rtps; using UDPv6Transport = eprosima::fastdds::rtps::UDPv6Transport; +using UDPv6TransportDescriptor = eprosima::fastdds::rtps::UDPv6TransportDescriptor; +using SendResourceList = eprosima::fastdds::rtps::SendResourceList; #ifndef __APPLE__ const uint32_t ReceiveBufferCapacity = 65536; @@ -78,7 +82,7 @@ class UDPv6Tests : public ::testing::Test void HELPER_SetDescriptorDefaults(); - UDPv6TransportDescriptor descriptor; + eprosima::fastdds::rtps::UDPv6TransportDescriptor descriptor; std::unique_ptr senderThread; std::unique_ptr receiverThread; }; @@ -167,7 +171,7 @@ TEST_F(UDPv6Tests, send_and_receive_between_ports) MockReceiverResource receiver(transportUnderTest, multicastLocator); MockMessageReceiver* msg_recv = dynamic_cast(receiver.CreateMessageReceiver()); - SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; ASSERT_TRUE(transportUnderTest.OpenOutputChannel(send_resource_list, multicastLocator)); ASSERT_TRUE(transportUnderTest.OpenOutputChannel(send_resource_list, outputChannelLocator)); // Includes loopback ASSERT_FALSE(send_resource_list.empty()); @@ -227,7 +231,7 @@ TEST_F(UDPv6Tests, send_to_loopback) MockReceiverResource receiver(transportUnderTest, multicastLocator); MockMessageReceiver* msg_recv = dynamic_cast(receiver.CreateMessageReceiver()); - SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; ASSERT_TRUE(transportUnderTest.OpenOutputChannel(send_resource_list, multicastLocator)); ASSERT_TRUE(transportUnderTest.OpenOutputChannel(send_resource_list, outputChannelLocator)); ASSERT_FALSE(send_resource_list.empty()); @@ -276,7 +280,7 @@ TEST_F(UDPv6Tests, send_is_rejected_if_buffer_size_is_bigger_to_size_specified_i UDPv6Transport transportUnderTest(descriptor); transportUnderTest.init(); - SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; Locator_t genericOutputChannelLocator; genericOutputChannelLocator.kind = LOCATOR_KIND_UDPv6; genericOutputChannelLocator.port = g_default_port; @@ -315,7 +319,7 @@ TEST_F(UDPv6Tests, RemoteToMainLocal_simply_strips_out_address_leaving_IP_ANY) ASSERT_EQ(mainLocalLocator.port, remote_locator.port); ASSERT_EQ(mainLocalLocator.kind, remote_locator.kind); - ASSERT_EQ(IPLocator::toIPv6string(mainLocalLocator), s_IPv6AddressAny); + ASSERT_EQ(IPLocator::toIPv6string(mainLocalLocator), eprosima::fastdds::rtps::s_IPv6AddressAny); } TEST_F(UDPv6Tests, match_if_port_AND_address_matches) @@ -343,7 +347,7 @@ TEST_F(UDPv6Tests, send_to_wrong_interface) UDPv6Transport transportUnderTest(descriptor); transportUnderTest.init(); - SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; Locator_t outputChannelLocator; outputChannelLocator.port = g_default_port; outputChannelLocator.kind = LOCATOR_KIND_UDPv6; @@ -372,7 +376,7 @@ TEST_F(UDPv6Tests, send_to_blocked_interface) UDPv6Transport transportUnderTest(descriptor); transportUnderTest.init(); - SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; Locator_t outputChannelLocator; outputChannelLocator.port = g_default_port; outputChannelLocator.kind = LOCATOR_KIND_UDPv6; @@ -402,7 +406,7 @@ TEST_F(UDPv6Tests, send_to_allowed_interface) UDPv6Transport transportUnderTest(descriptor); transportUnderTest.init(); - SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; Locator_t outputChannelLocator; outputChannelLocator.port = g_default_port; outputChannelLocator.kind = LOCATOR_KIND_UDPv6; @@ -470,7 +474,7 @@ TEST_F(UDPv6Tests, send_and_receive_between_allowed_sockets_using_localhost) MockReceiverResource receiver(transportUnderTest, unicastLocator); MockMessageReceiver* msg_recv = dynamic_cast(receiver.CreateMessageReceiver()); - SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; ASSERT_TRUE(transportUnderTest.OpenOutputChannel(send_resource_list, unicastLocator)); ASSERT_TRUE(transportUnderTest.OpenOutputChannel(send_resource_list, outputChannelLocator)); // Includes loopback ASSERT_FALSE(send_resource_list.empty()); @@ -508,9 +512,9 @@ TEST_F(UDPv6Tests, send_and_receive_between_allowed_sockets_using_unicast) if (interfaces.size() > 0) { - for (const auto& interface : interfaces) + for (const auto& network_interface : interfaces) { - descriptor.interfaceWhiteList.push_back(interface.name); + descriptor.interfaceWhiteList.push_back(network_interface.name); } UDPv6Transport transportUnderTest(descriptor); transportUnderTest.init(); @@ -531,7 +535,7 @@ TEST_F(UDPv6Tests, send_and_receive_between_allowed_sockets_using_unicast) MockReceiverResource receiver(transportUnderTest, unicastLocator); MockMessageReceiver* msg_recv = dynamic_cast(receiver.CreateMessageReceiver()); - SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; ASSERT_TRUE(transportUnderTest.OpenOutputChannel(send_resource_list, unicastLocator)); ASSERT_TRUE(transportUnderTest.OpenOutputChannel(send_resource_list, outputChannelLocator)); // Includes loopback ASSERT_FALSE(send_resource_list.empty()); @@ -570,9 +574,9 @@ TEST_F(UDPv6Tests, send_and_receive_between_allowed_sockets_using_unicast_to_mul if (interfaces.size() > 0) { - for (const auto& interface : interfaces) + for (const auto& network_interface : interfaces) { - descriptor.interfaceWhiteList.push_back(interface.name); + descriptor.interfaceWhiteList.push_back(network_interface.name); } UDPv6Transport transportUnderTest(descriptor); transportUnderTest.init(); @@ -593,7 +597,7 @@ TEST_F(UDPv6Tests, send_and_receive_between_allowed_sockets_using_unicast_to_mul MockReceiverResource receiver(transportUnderTest, unicastLocator); MockMessageReceiver* msg_recv = dynamic_cast(receiver.CreateMessageReceiver()); - SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; ASSERT_TRUE(transportUnderTest.OpenOutputChannel(send_resource_list, unicastLocator)); ASSERT_TRUE(transportUnderTest.OpenOutputChannel(send_resource_list, outputChannelLocator)); // Includes loopback ASSERT_FALSE(send_resource_list.empty()); @@ -697,7 +701,7 @@ TEST_F(UDPv6Tests, simple_throughput) sub_locator.port = 50000; IPLocator::setIPv6(sub_locator, std::string("::1")); - UDPv6TransportDescriptor my_descriptor; + eprosima::fastdds::rtps::UDPv6TransportDescriptor my_descriptor; // Subscriber @@ -722,7 +726,7 @@ TEST_F(UDPv6Tests, simple_throughput) LocatorList_t send_locators_list; send_locators_list.push_back(sub_locator); - SendResourceList send_resource_list; + eprosima::fastdds::rtps::SendResourceList send_resource_list; ASSERT_TRUE(pub_transport.OpenOutputChannel(send_resource_list, sub_locator)); auto t0 = std::chrono::high_resolution_clock::now(); diff --git a/test/unittest/transport/mock/MockReceiverResource.cpp b/test/unittest/transport/mock/MockReceiverResource.cpp index b1542c30e94..d22d4d7126d 100644 --- a/test/unittest/transport/mock/MockReceiverResource.cpp +++ b/test/unittest/transport/mock/MockReceiverResource.cpp @@ -14,12 +14,14 @@ #include "MockReceiverResource.h" -namespace eprosima{ -namespace fastrtps{ -namespace rtps{ +namespace eprosima { +namespace fastrtps { +namespace rtps { -MockReceiverResource::MockReceiverResource(TransportInterface& transport, const Locator_t& locator) - : msg_receiver(nullptr) +MockReceiverResource::MockReceiverResource( + eprosima::fastdds::rtps::TransportInterface& transport, + const Locator_t& locator) + : msg_receiver(nullptr) { m_maxMsgSize = 0x8FFF; // Internal channel is opened and assigned to this resource. @@ -30,9 +32,14 @@ MockReceiverResource::MockReceiverResource(TransportInterface& transport, const } // Implementation functions are bound to the right transport parameters - Cleanup = [&transport, locator]() { transport.CloseInputChannel(locator); }; + Cleanup = [&transport, locator]() + { + transport.CloseInputChannel(locator); + }; LocatorMapsToManagedChannel = [&transport, locator](const Locator_t& locatorToCheck) -> bool - { return transport.DoInputLocatorsMatch(locator, locatorToCheck); }; + { + return transport.DoInputLocatorsMatch(locator, locatorToCheck); + }; } MockReceiverResource::~MockReceiverResource() @@ -55,8 +62,11 @@ MessageReceiver* MockReceiverResource::CreateMessageReceiver() return msg_receiver; } -void MockReceiverResource::OnDataReceived(const octet* buf, const uint32_t size, - const Locator_t&, const Locator_t& remote) +void MockReceiverResource::OnDataReceived( + const octet* buf, + const uint32_t size, + const Locator_t&, + const Locator_t& remote) { if (msg_receiver != nullptr) { @@ -68,12 +78,15 @@ void MockReceiverResource::OnDataReceived(const octet* buf, const uint32_t size, } } -void MockMessageReceiver::setCallback(std::function cb) +void MockMessageReceiver::setCallback( + std::function cb) { this->callback = cb; } -void MockMessageReceiver::processCDRMsg(const Locator_t&, CDRMessage_t*msg) +void MockMessageReceiver::processCDRMsg( + const Locator_t&, + CDRMessage_t* msg) { data = msg->buffer; if (callback != nullptr) diff --git a/test/unittest/transport/mock/MockReceiverResource.h b/test/unittest/transport/mock/MockReceiverResource.h index b1da38cd24a..9e2f4843e24 100644 --- a/test/unittest/transport/mock/MockReceiverResource.h +++ b/test/unittest/transport/mock/MockReceiverResource.h @@ -17,8 +17,7 @@ #include -#include - +#include #include namespace eprosima { @@ -42,7 +41,7 @@ class MockReceiverResource : public ReceiverResource const Locator_t&, const Locator_t&) override; MockReceiverResource( - TransportInterface& transport, + eprosima::fastdds::rtps::TransportInterface& transport, const Locator_t& locator); ~MockReceiverResource(); MessageReceiver* CreateMessageReceiver() override; diff --git a/test/unittest/transport/mock/MockTCPv4Transport.h b/test/unittest/transport/mock/MockTCPv4Transport.h index e2aa8e0e9b1..414b3c52c3b 100644 --- a/test/unittest/transport/mock/MockTCPv4Transport.h +++ b/test/unittest/transport/mock/MockTCPv4Transport.h @@ -15,23 +15,22 @@ #ifndef MOCK_TRANSPORT_TCP4_STUFF_H #define MOCK_TRANSPORT_TCP4_STUFF_H -#include +#include + #include namespace eprosima { -namespace fastrtps { +namespace fastdds { namespace rtps { -using TCPv4Transport = eprosima::fastdds::rtps::TCPv4Transport; -using TCPChannelResource = eprosima::fastdds::rtps::TCPChannelResource; -using TCPChannelResourceBasic = eprosima::fastdds::rtps::TCPChannelResourceBasic; +using Locator_t = eprosima::fastrtps::rtps::Locator_t; class MockTCPv4Transport : public TCPv4Transport { public: MockTCPv4Transport( - const TCPv4TransportDescriptor& descriptor) + const eprosima::fastdds::rtps::TCPv4TransportDescriptor& descriptor) : TCPv4Transport(descriptor) { } diff --git a/test/unittest/transport/mock/MockTCPv6Transport.h b/test/unittest/transport/mock/MockTCPv6Transport.h index cc23f039a5a..f65088d4bb4 100644 --- a/test/unittest/transport/mock/MockTCPv6Transport.h +++ b/test/unittest/transport/mock/MockTCPv6Transport.h @@ -15,7 +15,7 @@ #ifndef MOCK_TRANSPORT_TCP6_STUFF_H #define MOCK_TRANSPORT_TCP6_STUFF_H -#include +#include #include namespace eprosima { @@ -31,7 +31,7 @@ class MockTCPv6Transport : public TCPv6Transport public: MockTCPv6Transport( - const TCPv6TransportDescriptor& descriptor) + const fastdds::rtps::TCPv6TransportDescriptor& descriptor) : TCPv6Transport(descriptor) { } diff --git a/test/unittest/utils/BitmapRangeTests.cpp b/test/unittest/utils/BitmapRangeTests.cpp index fe0cadd436e..2c649a339f8 100644 --- a/test/unittest/utils/BitmapRangeTests.cpp +++ b/test/unittest/utils/BitmapRangeTests.cpp @@ -13,7 +13,7 @@ // limitations under the License. #include -#include +#include #include #include diff --git a/test/unittest/utils/CMakeLists.txt b/test/unittest/utils/CMakeLists.txt index f528cf6d0f7..881b79ded67 100644 --- a/test/unittest/utils/CMakeLists.txt +++ b/test/unittest/utils/CMakeLists.txt @@ -18,10 +18,6 @@ endif() set(STRINGMATCHINGTESTS_SOURCE StringMatchingTests.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/Log.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/OStreamConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutErrConsumer.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/LocatorWithMask.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/Time_t.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/network/utils/netmask_filter.cpp @@ -34,9 +30,6 @@ set(STRINGMATCHINGTESTS_SOURCE ${PROJECT_SOURCE_DIR}/src/cpp/utils/StringMatching.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/SystemInfo.cpp) -set(FIXEDSIZESTRINGTESTS_SOURCE - FixedSizeStringTests.cpp) - set(BITMAPRANGETESTS_SOURCE BitmapRangeTests.cpp) @@ -45,10 +38,6 @@ set(RESOURCELIMITEDVECTORTESTS_SOURCE set(LOCATORTESTS_SOURCE LocatorTests.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/Log.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/OStreamConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutErrConsumer.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/LocatorWithMask.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/Time_t.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/network/utils/netmask_filter.cpp @@ -65,10 +54,6 @@ set(FIXEDSIZEQUEUETESTS_SOURCE set(SYSTEMINFOTESTS_SOURCE SystemInfoTests.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/Log.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/OStreamConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutErrConsumer.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/LocatorWithMask.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/Time_t.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/network/utils/netmask_filter.cpp @@ -93,7 +78,12 @@ target_include_directories(StringMatchingTests PRIVATE ${Asio_INCLUDE_DIR} ${PROJECT_SOURCE_DIR}/include ${PROJECT_BINARY_DIR}/include ${PROJECT_SOURCE_DIR}/src/cpp) -target_link_libraries(StringMatchingTests GTest::gtest ${MOCKS}) +target_link_libraries(StringMatchingTests + fastcdr + fastdds::log + GTest::gtest + ${MOCKS} + ) if(MSVC OR MSVC_IDE) target_link_libraries(StringMatchingTests ${PRIVACY} iphlpapi Shlwapi ) @@ -101,17 +91,6 @@ endif() gtest_discover_tests(StringMatchingTests) -add_executable(FixedSizeStringTests ${FIXEDSIZESTRINGTESTS_SOURCE}) -target_compile_definitions(FixedSizeStringTests PRIVATE - $<$>,$>:__DEBUG> - $<$:__INTERNALDEBUG> # Internal debug activated. - ) -target_include_directories(FixedSizeStringTests PRIVATE - ${PROJECT_SOURCE_DIR}/include ${PROJECT_BINARY_DIR}/include) -target_link_libraries(FixedSizeStringTests GTest::gtest ${MOCKS}) -gtest_discover_tests(FixedSizeStringTests) - - add_executable(BitmapRangeTests ${BITMAPRANGETESTS_SOURCE}) target_compile_definitions(BitmapRangeTests PRIVATE $<$>,$>:__DEBUG> @@ -143,7 +122,12 @@ target_compile_definitions(LocatorTests PRIVATE target_include_directories(LocatorTests PRIVATE ${PROJECT_SOURCE_DIR}/include ${PROJECT_BINARY_DIR}/include ${Asio_INCLUDE_DIR} ${PROJECT_SOURCE_DIR}/src/cpp) -target_link_libraries(LocatorTests GTest::gtest ${MOCKS}) +target_link_libraries(LocatorTests + fastcdr + fastdds::log + GTest::gtest + ${MOCKS} + ) if(QNX) target_link_libraries(LocatorTests socket) endif() @@ -170,12 +154,16 @@ target_compile_definitions(SystemInfoTests PRIVATE target_include_directories(SystemInfoTests PRIVATE ${Asio_INCLUDE_DIR} ${PROJECT_SOURCE_DIR}/include ${PROJECT_SOURCE_DIR}/src/cpp ${PROJECT_BINARY_DIR}/include) -target_link_libraries(SystemInfoTests GTest::gtest) +target_link_libraries(SystemInfoTests + fastcdr + fastdds::log + GTest::gtest + ) gtest_discover_tests(SystemInfoTests) add_executable(SharedMutexTests shared_mutex_tests.cpp) target_compile_definitions(SharedMutexTests PUBLIC USE_THIRDPARTY_SHARED_MUTEX=1) -target_include_directories(SharedMutexTests PUBLIC ${PROJECT_SOURCE_DIR}/include) +target_include_directories(SharedMutexTests PRIVATE ${PROJECT_SOURCE_DIR}/src/cpp) target_link_libraries(SharedMutexTests PUBLIC GTest::gtest) gtest_discover_tests(SharedMutexTests) diff --git a/test/unittest/utils/FixedSizeStringTests.cpp b/test/unittest/utils/FixedSizeStringTests.cpp deleted file mode 100644 index d0c25ef2660..00000000000 --- a/test/unittest/utils/FixedSizeStringTests.cpp +++ /dev/null @@ -1,273 +0,0 @@ -// Copyright 2018 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -#include -#include - -using namespace eprosima::fastrtps; - -constexpr size_t MAX_CHARS = 255; -constexpr size_t OTHER_MAX_CHARS = 127; - -class FixedSizeStringTests : public ::testing::Test -{ -public: - - char const* pattern0 = "foo/bar/baz"; - char const* long_pattern = - "0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF" - "0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF" - "0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF" - "0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF" - "0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF" - "0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF" - "0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF" - "0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF"; - - size_t pattern0_len = strlen(pattern0); -}; - -TEST_F(FixedSizeStringTests, default_constructor) -{ - std::string std_s; - fixed_string fixed_s; - - ASSERT_EQ(fixed_s.size(), 0u); - ASSERT_EQ(fixed_s, ""); - ASSERT_EQ(fixed_s, std_s); -} - -TEST_F(FixedSizeStringTests, construct_with_empty_c_string) -{ - std::string std_s; - fixed_string fixed_s(""); - - ASSERT_EQ(fixed_s.size(), 0u); - ASSERT_EQ(fixed_s, ""); - ASSERT_EQ(fixed_s, std_s); -} - -TEST_F(FixedSizeStringTests, construct_with_empty_std_string) -{ - std::string std_s; - fixed_string fixed_s(std_s); - - ASSERT_EQ(fixed_s.size(), 0u); - ASSERT_EQ(fixed_s, ""); - ASSERT_EQ(fixed_s, std_s); -} - -TEST_F(FixedSizeStringTests, construct_with_c_string) -{ - fixed_string fixed_s(pattern0); - - ASSERT_EQ(fixed_s.size(), pattern0_len); - ASSERT_EQ(fixed_s, pattern0); -} - -TEST_F(FixedSizeStringTests, construct_with_std_string) -{ - std::string std_string(pattern0); - fixed_string fixed_s(std_string); - - ASSERT_EQ(fixed_s.size(), pattern0_len); - ASSERT_EQ(fixed_s, std_string); -} - -TEST_F(FixedSizeStringTests, construct_with_long_c_string) -{ - fixed_string fixed_s(long_pattern); - - ASSERT_EQ(fixed_s.size(), MAX_CHARS); - ASSERT_EQ(fixed_s, long_pattern); -} - -TEST_F(FixedSizeStringTests, construct_with_long_std_string) -{ - std::string std_string(long_pattern); - fixed_string fixed_s(std_string); - - ASSERT_EQ(fixed_s.size(), MAX_CHARS); - ASSERT_EQ(fixed_s, std_string); -} - -TEST_F(FixedSizeStringTests, assign_operators_and_inequality) -{ - fixed_string fixed_s; - - std::string std_s_empty; - std::string std_s(pattern0); - std::string std_s_long(long_pattern); - - fixed_s = std_s_long; - ASSERT_EQ(fixed_s.size(), MAX_CHARS); - ASSERT_EQ(fixed_s, long_pattern); - ASSERT_NE(fixed_s, pattern0); - ASSERT_NE(fixed_s, ""); - - fixed_s = pattern0; - ASSERT_EQ(fixed_s.size(), pattern0_len); - ASSERT_EQ(fixed_s, std_s); - ASSERT_NE(fixed_s, std_s_empty); - ASSERT_NE(fixed_s, std_s_long); - - fixed_s = std_s_empty; - ASSERT_EQ(fixed_s.size(), 0u); - ASSERT_EQ(fixed_s, ""); - ASSERT_NE(fixed_s, long_pattern); - ASSERT_NE(fixed_s, pattern0); - - fixed_s = long_pattern; - ASSERT_EQ(fixed_s.size(), MAX_CHARS); - ASSERT_EQ(fixed_s, std_s_long); - ASSERT_NE(fixed_s, std_s); - ASSERT_NE(fixed_s, std_s_empty); - - fixed_s = std_s; - ASSERT_EQ(fixed_s.size(), pattern0_len); - ASSERT_EQ(fixed_s, pattern0); - ASSERT_NE(fixed_s, ""); - ASSERT_NE(fixed_s, long_pattern); - - fixed_s = ""; - ASSERT_EQ(fixed_s.size(), 0u); - ASSERT_EQ(fixed_s, std_s_empty); - ASSERT_NE(fixed_s, std_s_long); - ASSERT_NE(fixed_s, std_s); -} - -TEST_F(FixedSizeStringTests, different_fixed_sizes) -{ - fixed_string s1; - fixed_string s2; - - ASSERT_EQ(s1, s2); - - s1 = long_pattern; - ASSERT_NE(s1, s2); - - s2 = s1; - ASSERT_EQ(s2, s1); - - s2 = pattern0; - ASSERT_NE(s2, s1); - - s1 = s2; - ASSERT_EQ(s1, s2); -} - -TEST_F(FixedSizeStringTests, comparisons) -{ - const char* c_string_short = "test string"; - const char* c_string_a = "test string a"; - const char* c_string_b = "test string b"; - const char* c_string_c = "test string c"; - const char* c_string_large = "test string b "; - std::string std_string_short = "test string"; - std::string std_string_a = "test string a"; - std::string std_string_b = "test string b"; - std::string std_string_c = "test string c"; - std::string std_string_large = "test string b "; - fixed_string fixed_short = "test string"; - fixed_string fixed_a = "test string a"; - fixed_string fixed_b = "test string b"; - fixed_string fixed_c = "test string c"; - fixed_string fixed_large = "test string b "; - - ASSERT_NE(fixed_b, c_string_short); - ASSERT_NE(fixed_b, c_string_a); - ASSERT_EQ(fixed_b, c_string_b); - ASSERT_NE(fixed_b, c_string_c); - ASSERT_NE(fixed_b, c_string_large); - - ASSERT_LT(0, fixed_b.compare(c_string_short)); - ASSERT_LT(0, fixed_b.compare(c_string_a)); - ASSERT_EQ(0, fixed_b.compare(c_string_b)); - ASSERT_GT(0, fixed_b.compare(c_string_c)); - ASSERT_GT(0, fixed_b.compare(c_string_large)); - - ASSERT_NE(fixed_b, std_string_short); - ASSERT_NE(fixed_b, std_string_a); - ASSERT_EQ(fixed_b, std_string_b); - ASSERT_NE(fixed_b, std_string_c); - ASSERT_NE(fixed_b, std_string_large); - - ASSERT_LE(0, fixed_b.compare(std_string_short)); - ASSERT_LE(0, fixed_b.compare(std_string_a)); - ASSERT_EQ(0, fixed_b.compare(std_string_b)); - ASSERT_GT(0, fixed_b.compare(std_string_c)); - ASSERT_GT(0, fixed_b.compare(std_string_large)); - - ASSERT_NE(fixed_b, fixed_short); - ASSERT_NE(fixed_b, fixed_a); - ASSERT_EQ(fixed_b, fixed_b); - ASSERT_NE(fixed_b, fixed_c); - ASSERT_NE(fixed_b, fixed_large); - - ASSERT_LE(0, fixed_b.compare(fixed_short)); - ASSERT_LE(0, fixed_b.compare(fixed_a)); - ASSERT_EQ(0, fixed_b.compare(fixed_b)); - ASSERT_GT(0, fixed_b.compare(fixed_c)); - ASSERT_GT(0, fixed_b.compare(fixed_large)); -} - -TEST_F(FixedSizeStringTests, less_than_operator_fixed_string) -{ - fixed_string fixed_string_short = "test string"; - fixed_string fixed_string_long = "test string long"; - - ASSERT_FALSE(fixed_string_short < fixed_string_short); - ASSERT_FALSE(fixed_string_long < fixed_string_long); - ASSERT_TRUE(fixed_string_short < fixed_string_long); - ASSERT_FALSE(fixed_string_long < fixed_string_short); -} - -TEST_F(FixedSizeStringTests, less_than_operator_std_string) -{ - fixed_string fixed_string_short = "test string"; - std::string std_string_long = "test string long"; - std::string std_string_short = "test"; - - ASSERT_TRUE(fixed_string_short < std_string_long); - ASSERT_FALSE(fixed_string_short < std_string_short); -} - -TEST_F(FixedSizeStringTests, greater_than_operator_fixed_string) -{ - fixed_string fixed_string_short = "test string"; - fixed_string fixed_string_long = "test string long"; - - ASSERT_FALSE(fixed_string_short > fixed_string_short); - ASSERT_FALSE(fixed_string_long > fixed_string_long); - ASSERT_FALSE(fixed_string_short > fixed_string_long); - ASSERT_TRUE(fixed_string_long > fixed_string_short); -} - -TEST_F(FixedSizeStringTests, greater_than_operator_std_string) -{ - fixed_string fixed_string_short = "test string"; - std::string std_string_long = "test string long"; - std::string std_string_short = "test"; - - ASSERT_FALSE(fixed_string_short > std_string_long); - ASSERT_TRUE(fixed_string_short > std_string_short); -} - -int main( - int argc, - char** argv) -{ - testing::InitGoogleTest(&argc, argv); - return RUN_ALL_TESTS(); -} diff --git a/test/unittest/utils/LocatorTests.cpp b/test/unittest/utils/LocatorTests.cpp index 17719a5b5c3..08d126628d0 100644 --- a/test/unittest/utils/LocatorTests.cpp +++ b/test/unittest/utils/LocatorTests.cpp @@ -12,15 +12,16 @@ // See the License for the specific language governing permissions and // limitations under the License. -#include -#include -#include -#include -#include +#include #include -#include +#include +#include +#include +#include +#include +#include using namespace eprosima::fastrtps::rtps; diff --git a/test/unittest/utils/ResourceLimitedVectorTests.cpp b/test/unittest/utils/ResourceLimitedVectorTests.cpp index 98c2a581bad..5772fdc4f2a 100644 --- a/test/unittest/utils/ResourceLimitedVectorTests.cpp +++ b/test/unittest/utils/ResourceLimitedVectorTests.cpp @@ -12,7 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. -#include +#include #include using namespace eprosima::fastrtps; diff --git a/test/unittest/utils/StringMatchingTests.cpp b/test/unittest/utils/StringMatchingTests.cpp index dfaba43ff8a..3ef84302476 100644 --- a/test/unittest/utils/StringMatchingTests.cpp +++ b/test/unittest/utils/StringMatchingTests.cpp @@ -12,31 +12,38 @@ // See the License for the specific language governing permissions and // limitations under the License. -#include #include + #include -using namespace eprosima::fastrtps; -using namespace eprosima::fastrtps::rtps; +#include + +using namespace eprosima::fastdds::rtps; -class StringMatchingTests: public ::testing::Test +class StringMatchingTests : public ::testing::Test { - public: - StringMatchingTests(){} - ~StringMatchingTests(){} +public: + + StringMatchingTests() + { + } + + ~StringMatchingTests() + { + } - char const *path = "foo/bar/baz"; - char const *pattern0 = "foo/bar/baz"; - char const *pattern1 = "foo*"; - char const *pattern2 = "*baz"; - char const *pattern3 = "foo/*/baz"; - char const *pattern4 = "foo/bar/ba?"; - char const *pattern5 = "*ba?*"; - char const *pattern6 = "foo\\bar\\baz"; - char const *pattern7 = "*bar"; - char const *pattern8 = "*"; - char const *pattern9 = "foo/bar/qux"; - char const *pattern10 = "FOO/BAR/QUX"; + char const* path = "foo/bar/baz"; + char const* pattern0 = "foo/bar/baz"; + char const* pattern1 = "foo*"; + char const* pattern2 = "*baz"; + char const* pattern3 = "foo/*/baz"; + char const* pattern4 = "foo/bar/ba?"; + char const* pattern5 = "*ba?*"; + char const* pattern6 = "foo\\bar\\baz"; + char const* pattern7 = "*bar"; + char const* pattern8 = "*"; + char const* pattern9 = "foo/bar/qux"; + char const* pattern10 = "FOO/BAR/QUX"; }; @@ -56,7 +63,9 @@ TEST_F(StringMatchingTests, patterns_with_wildcards) } -int main(int argc, char **argv) +int main( + int argc, + char** argv) { eprosima::fastdds::dds::Log::SetVerbosity(eprosima::fastdds::dds::Log::Info); testing::InitGoogleTest(&argc, argv); diff --git a/test/unittest/utils/SystemInfoTests.cpp b/test/unittest/utils/SystemInfoTests.cpp index d94a6e4bb34..50da9759535 100644 --- a/test/unittest/utils/SystemInfoTests.cpp +++ b/test/unittest/utils/SystemInfoTests.cpp @@ -30,15 +30,13 @@ #endif // _WIN32 #include -#include -#include #include + +#include #include #define SIZE 512 -using ReturnCode_t = eprosima::fastrtps::types::ReturnCode_t; - class SystemInfoTests : public ::testing::Test { public: @@ -96,68 +94,69 @@ TEST_F(SystemInfoTests, GetEnvTest) ASSERT_EQ(0, setenv(eprosima::fastdds::rtps::DEFAULT_ROS2_MASTER_URI, value.c_str(), 1)); ASSERT_EQ(0, setenv(empty_var_name.c_str(), value.c_str(), 1)); #endif // _WIN32 - ASSERT_EQ(ReturnCode_t::RETCODE_OK, eprosima::SystemInfo::set_environment_file()); + ASSERT_EQ(eprosima::fastdds::dds::RETCODE_OK, eprosima::SystemInfo::set_environment_file()); // 2. Read environment variable not contained in the file but set in the environment - EXPECT_EQ(ReturnCode_t::RETCODE_OK, eprosima::SystemInfo::get_env(env_var_name, env_value)); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, eprosima::SystemInfo::get_env(env_var_name, env_value)); EXPECT_EQ(env_value, value); // 3. Read environment variable contained in the file and in the environment: file has priority - EXPECT_EQ(ReturnCode_t::RETCODE_OK, eprosima::SystemInfo::get_env(eprosima::fastdds::rtps::DEFAULT_ROS2_MASTER_URI, + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, + eprosima::SystemInfo::get_env(eprosima::fastdds::rtps::DEFAULT_ROS2_MASTER_URI, env_value)); EXPECT_EQ("localhost:11811", env_value); // 4. Read variable set empty in the file but with a valid value in the environment: file has priority - EXPECT_EQ(ReturnCode_t::RETCODE_OK, eprosima::SystemInfo::get_env(empty_var_name, env_value)); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, eprosima::SystemInfo::get_env(empty_var_name, env_value)); EXPECT_TRUE(env_value.empty()); // 5. Invalid environment name: neither in the file nor in the environment - EXPECT_EQ(eprosima::SystemInfo::get_env("INVALID_NAME", env_value), ReturnCode_t::RETCODE_NO_DATA); + EXPECT_EQ(eprosima::SystemInfo::get_env("INVALID_NAME", env_value), eprosima::fastdds::dds::RETCODE_NO_DATA); // 6. Bad parameters: empty environment name std::string non_init_string; - EXPECT_EQ(eprosima::SystemInfo::get_env("", env_value), ReturnCode_t::RETCODE_BAD_PARAMETER); - EXPECT_EQ(eprosima::SystemInfo::get_env(non_init_string, env_value), ReturnCode_t::RETCODE_BAD_PARAMETER); + EXPECT_EQ(eprosima::SystemInfo::get_env("", env_value), eprosima::fastdds::dds::RETCODE_BAD_PARAMETER); + EXPECT_EQ(eprosima::SystemInfo::get_env(non_init_string, env_value), eprosima::fastdds::dds::RETCODE_BAD_PARAMETER); // 7. Check that reading the environment variable directly from file returns correctly - ASSERT_EQ(ReturnCode_t::RETCODE_OK, eprosima::SystemInfo::get_env(filename, + ASSERT_EQ(eprosima::fastdds::dds::RETCODE_OK, eprosima::SystemInfo::get_env(filename, eprosima::fastdds::rtps::DEFAULT_ROS2_MASTER_URI, env_value)); EXPECT_EQ("localhost:11811", env_value); // 8. Check that an empty environment variable returns correctly std::string empty_environment_variable = "EMPTY_ENV_VAR"; - EXPECT_EQ(ReturnCode_t::RETCODE_OK, eprosima::SystemInfo::get_env(filename, + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, eprosima::SystemInfo::get_env(filename, empty_environment_variable, env_value)); EXPECT_TRUE(env_value.empty()); - // 9. Check that a non-existent tag returns RETCODE_NO_DATA + // 9. Check that a non-existent tag returns eprosima::fastdds::dds::RETCODE_NO_DATA std::string non_existent_env_variable = "NON_EXISTENT_ENV_VARIBLE"; env_value.clear(); - EXPECT_EQ(ReturnCode_t::RETCODE_NO_DATA, eprosima::SystemInfo::get_env(filename, + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_NO_DATA, eprosima::SystemInfo::get_env(filename, non_existent_env_variable, env_value)); EXPECT_TRUE(env_value.empty()); - // 10. Check that a non-existent file returns RETCODE_BAD_PARAMETER + // 10. Check that a non-existent file returns eprosima::fastdds::dds::RETCODE_BAD_PARAMETER filename = "non_existent.json"; - EXPECT_EQ(ReturnCode_t::RETCODE_BAD_PARAMETER, eprosima::SystemInfo::get_env(filename, + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_BAD_PARAMETER, eprosima::SystemInfo::get_env(filename, eprosima::fastdds::rtps::DEFAULT_ROS2_MASTER_URI, env_value)); EXPECT_TRUE(env_value.empty()); - // 11. Check that a wrong formatted file returns RETCODE_ERROR + // 11. Check that a wrong formatted file returns eprosima::fastdds::dds::RETCODE_ERROR filename = "empty_environment_test_file.json"; - EXPECT_EQ(ReturnCode_t::RETCODE_ERROR, eprosima::SystemInfo::get_env(filename, + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_ERROR, eprosima::SystemInfo::get_env(filename, eprosima::fastdds::rtps::DEFAULT_ROS2_MASTER_URI, env_value)); EXPECT_TRUE(env_value.empty()); } /* * This test checks the get_username static method of the SystemInfo class - * The test only checks that the method returns RETCODE_OK and that the username is not an empty string + * The test only checks that the method returns eprosima::fastdds::dds::RETCODE_OK and that the username is not an empty string */ TEST_F(SystemInfoTests, GetUsernameTest) { std::string username; - EXPECT_EQ(ReturnCode_t::RETCODE_OK, eprosima::SystemInfo::get_username(username)); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, eprosima::SystemInfo::get_username(username)); EXPECT_FALSE(username.empty()); } @@ -204,9 +203,9 @@ TEST_F(SystemInfoTests, FileExistsTest) */ TEST_F(SystemInfoTests, EnvironmentFileTest) { - // 1. Environment variable not set: call to set_environment_variable returns RETCODE_NO_DATA and + // 1. Environment variable not set: call to set_environment_variable returns eprosima::fastdds::dds::RETCODE_NO_DATA and // get_environment_file returns empty - EXPECT_EQ(ReturnCode_t::RETCODE_NO_DATA, eprosima::SystemInfo::set_environment_file()); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_NO_DATA, eprosima::SystemInfo::set_environment_file()); EXPECT_TRUE(eprosima::SystemInfo::get_environment_file().empty()); // 2. Set environment file variable and see that it returns correctly @@ -216,7 +215,7 @@ TEST_F(SystemInfoTests, EnvironmentFileTest) #else ASSERT_EQ(0, setenv(eprosima::FASTDDS_ENVIRONMENT_FILE_ENV_VAR, value.c_str(), 1)); #endif // _WIN32 - EXPECT_EQ(ReturnCode_t::RETCODE_OK, eprosima::SystemInfo::set_environment_file()); + EXPECT_EQ(eprosima::fastdds::dds::RETCODE_OK, eprosima::SystemInfo::set_environment_file()); EXPECT_EQ(0, eprosima::SystemInfo::get_environment_file().compare(value)); } diff --git a/test/unittest/utils/shared_mutex_tests.cpp b/test/unittest/utils/shared_mutex_tests.cpp index eba86e73e46..77dc39a46b3 100644 --- a/test/unittest/utils/shared_mutex_tests.cpp +++ b/test/unittest/utils/shared_mutex_tests.cpp @@ -8,9 +8,10 @@ #include #include -#include #include +#include + using namespace std; using namespace std::chrono; using namespace eprosima; diff --git a/test/unittest/xmlparser/CMakeLists.txt b/test/unittest/xmlparser/CMakeLists.txt index f631a897b1e..a5575b364fe 100644 --- a/test/unittest/xmlparser/CMakeLists.txt +++ b/test/unittest/xmlparser/CMakeLists.txt @@ -78,31 +78,10 @@ file(COPY "${CMAKE_CURRENT_SOURCE_DIR}/regressions" DESTINATION "${CMAKE_CURRENT ################################### XMLProfileParserTests #################################################### set(XMLPROFILEPARSER_SOURCE XMLProfileParserTests.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/AnnotationDescriptor.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/AnnotationParameterValue.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/BuiltinAnnotationsTypeObject.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicData.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicDataFactory.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicDataPtr.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicPubSubType.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicType.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeBuilder.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeBuilderFactory.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeBuilderPtr.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeMember.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypePtr.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/MemberDescriptor.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeDescriptor.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeIdentifier.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeIdentifierTypes.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeNamesGenerator.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeObject.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeObjectFactory.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeObjectHashId.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypesBase.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/publisher/qos/WriterQos.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/subscriber/qos/ReaderQos.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/topic/TopicDataType.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/xtypes/exception/Exception.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/attributes/ThreadSettings.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/LocatorWithMask.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/Time_t.cpp @@ -114,17 +93,17 @@ set(XMLPROFILEPARSER_SOURCE ${PROJECT_SOURCE_DIR}/src/cpp/rtps/transport/network/NetworkInterface.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/transport/network/NetworkInterfaceWithFilter.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/transport/PortBasedTransportDescriptor.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/xmlparser/XMLDynamicParser.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/xmlparser/XMLElementParser.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/xmlparser/XMLParser.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/xmlparser/XMLParserCommon.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/xmlparser/XMLProfileManager.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/IPFinder.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/IPLocator.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/md5.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/string_convert.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/SystemInfo.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/UnitsParser.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/xmlparser/XMLDynamicParser.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/xmlparser/XMLElementParser.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/xmlparser/XMLParser.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/xmlparser/XMLParserCommon.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/xmlparser/XMLProfileManager.cpp ) # External sources @@ -155,7 +134,10 @@ target_compile_definitions(XMLProfileParserTests PRIVATE $<$:__INTERNALDEBUG> # Internal debug activated. ) target_include_directories(XMLProfileParserTests PRIVATE + ${PROJECT_SOURCE_DIR}/test/mock/dds/TypeObjectRegistry + ${PROJECT_SOURCE_DIR}/test/mock/dds/TypeObjectUtils ${PROJECT_SOURCE_DIR}/test/mock/rtps/Log + ${PROJECT_SOURCE_DIR}/test/mock/rtps/RTPSDomainImpl # Dependency of fastdds::xtypes::type_representation ${PROJECT_SOURCE_DIR}/test/mock/rtps/SharedMemTransportDescriptor ${PROJECT_SOURCE_DIR}/test/mock/rtps/TCPTransportDescriptor ${PROJECT_SOURCE_DIR}/test/mock/rtps/TCPv4TransportDescriptor @@ -164,7 +146,8 @@ target_include_directories(XMLProfileParserTests PRIVATE ${PROJECT_SOURCE_DIR}/test/mock/rtps/UDPv4TransportDescriptor ${PROJECT_SOURCE_DIR}/test/mock/rtps/UDPv6TransportDescriptor ${PROJECT_SOURCE_DIR}/test/mock/rtps/RTPSParticipantAttributes - ${PROJECT_SOURCE_DIR}/include ${PROJECT_BINARY_DIR}/include + ${PROJECT_SOURCE_DIR}/include + ${PROJECT_BINARY_DIR}/include ${PROJECT_SOURCE_DIR}/src/cpp ${Asio_INCLUDE_DIR} $<$:${ANDROID_IFADDRS_INCLUDE_DIR}> @@ -175,6 +158,7 @@ target_link_libraries(XMLProfileParserTests GTest::gmock $<$:ws2_32> ${TINYXML2_LIBRARY} fastcdr + fastdds::xtypes::dynamic-types::impl ) if(QNX) target_link_libraries(XMLProfileParserTests socket) @@ -188,36 +172,10 @@ gtest_discover_tests(XMLProfileParserTests) set(XMLPARSER_SOURCE XMLParserTests.cpp XMLElementParserTests.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/AnnotationDescriptor.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/AnnotationParameterValue.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/BuiltinAnnotationsTypeObject.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicData.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicDataFactory.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicDataPtr.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicPubSubType.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicType.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeBuilder.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeBuilderFactory.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeBuilderPtr.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeMember.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypePtr.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/MemberDescriptor.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeDescriptor.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeIdentifier.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeIdentifierTypes.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeNamesGenerator.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeObject.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeObjectFactory.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeObjectHashId.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypesBase.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/FileConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/Log.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/OStreamConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutErrConsumer.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/publisher/qos/WriterQos.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/subscriber/qos/ReaderQos.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/topic/TopicDataType.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/xtypes/exception/Exception.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/attributes/ThreadSettings.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/LocatorWithMask.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/Time_t.cpp @@ -229,17 +187,17 @@ set(XMLPARSER_SOURCE ${PROJECT_SOURCE_DIR}/src/cpp/rtps/transport/network/NetworkInterface.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/transport/network/NetworkInterfaceWithFilter.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/transport/PortBasedTransportDescriptor.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/xmlparser/XMLDynamicParser.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/xmlparser/XMLElementParser.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/xmlparser/XMLParser.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/xmlparser/XMLParserCommon.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/xmlparser/XMLProfileManager.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/IPFinder.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/IPLocator.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/md5.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/string_convert.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/SystemInfo.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/UnitsParser.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/xmlparser/XMLDynamicParser.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/xmlparser/XMLElementParser.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/xmlparser/XMLParser.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/xmlparser/XMLParserCommon.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/xmlparser/XMLProfileManager.cpp ) # External sources @@ -265,6 +223,9 @@ target_compile_definitions(XMLParserTests PRIVATE $<$:__INTERNALDEBUG> # Internal debug activated. ) target_include_directories(XMLParserTests PRIVATE + ${PROJECT_SOURCE_DIR}/test/mock/dds/TypeObjectRegistry + ${PROJECT_SOURCE_DIR}/test/mock/dds/TypeObjectUtils + ${PROJECT_SOURCE_DIR}/test/mock/rtps/RTPSDomainImpl # Dependency of fastdds::xtypes::type_representation ${PROJECT_SOURCE_DIR}/test/mock/rtps/SharedMemTransportDescriptor ${PROJECT_SOURCE_DIR}/test/mock/rtps/TCPTransportDescriptor ${PROJECT_SOURCE_DIR}/test/mock/rtps/TCPv4TransportDescriptor @@ -285,6 +246,8 @@ target_link_libraries(XMLParserTests GTest::gtest $<$:ws2_32> ${TINYXML2_LIBRARY} fastcdr + fastdds::log + fastdds::xtypes::dynamic-types::impl ) if(QNX) target_link_libraries(XMLParserTests socket) @@ -314,6 +277,7 @@ target_compile_definitions(XMLTreeTests PRIVATE target_include_directories(XMLTreeTests PRIVATE ${PROJECT_SOURCE_DIR}/include ${PROJECT_BINARY_DIR}/include + ${PROJECT_SOURCE_DIR}/src/cpp $<$:${ANDROID_IFADDRS_INCLUDE_DIR}> ) @@ -328,36 +292,10 @@ gtest_discover_tests(XMLTreeTests) ################################### XMLENDPOINTPARSERTESTS ################################################### set(XMLENDPOINTPARSERTESTS_SOURCE XMLEndpointParserTests.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/AnnotationDescriptor.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/AnnotationParameterValue.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/BuiltinAnnotationsTypeObject.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicData.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicDataFactory.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicDataPtr.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicPubSubType.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicType.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeBuilder.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeBuilderFactory.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeBuilderPtr.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeMember.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypePtr.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/MemberDescriptor.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeDescriptor.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeIdentifier.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeIdentifierTypes.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeNamesGenerator.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeObject.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeObjectFactory.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeObjectHashId.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypesBase.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/FileConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/Log.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/OStreamConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutErrConsumer.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/publisher/qos/WriterQos.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/subscriber/qos/ReaderQos.cpp ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/topic/TopicDataType.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/xtypes/exception/Exception.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/attributes/ThreadSettings.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/LocatorWithMask.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/Time_t.cpp @@ -368,13 +306,16 @@ set(XMLENDPOINTPARSERTESTS_SOURCE ${PROJECT_SOURCE_DIR}/src/cpp/rtps/transport/network/NetworkInterface.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/transport/network/NetworkInterfaceWithFilter.cpp ${PROJECT_SOURCE_DIR}/src/cpp/rtps/transport/PortBasedTransportDescriptor.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/xmlparser/XMLElementParser.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/xmlparser/XMLEndpointParser.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/xmlparser/XMLParserCommon.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/utils/IPFinder.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/utils/IPLocator.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/md5.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/string_convert.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/utils/UnitsParser.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/xmlparser/XMLElementParser.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/xmlparser/XMLEndpointParser.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/xmlparser/XMLParserCommon.cpp + + # locators + ${PROJECT_SOURCE_DIR}/src/cpp/utils/IPFinder.cpp + ${PROJECT_SOURCE_DIR}/src/cpp/utils/IPLocator.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/SystemInfo.cpp ${PROJECT_SOURCE_DIR}/src/cpp/utils/UnitsParser.cpp ) @@ -400,7 +341,10 @@ target_compile_definitions(XMLEndpointParserTests PRIVATE ASIO_STANDALONE ) target_include_directories(XMLEndpointParserTests PRIVATE + ${PROJECT_SOURCE_DIR}/test/mock/dds/TypeObjectRegistry + ${PROJECT_SOURCE_DIR}/test/mock/dds/TypeObjectUtils ${PROJECT_SOURCE_DIR}/test/mock/rtps/ReaderProxyData + ${PROJECT_SOURCE_DIR}/test/mock/rtps/RTPSDomainImpl ${PROJECT_SOURCE_DIR}/test/mock/rtps/SharedMemTransportDescriptor ${PROJECT_SOURCE_DIR}/test/mock/rtps/TCPTransportDescriptor ${PROJECT_SOURCE_DIR}/test/mock/rtps/TCPv4TransportDescriptor @@ -422,6 +366,8 @@ target_link_libraries(XMLEndpointParserTests GTest::gtest $<$:ws2_32> ${TINYXML2_LIBRARY} fastcdr + fastdds::log + fastdds::xtypes::dynamic-types::impl ) if(QNX) target_link_libraries(XMLEndpointParserTests socket) diff --git a/test/unittest/xmlparser/SHM_transport_descriptors_config_profile.xml b/test/unittest/xmlparser/SHM_transport_descriptors_config_profile.xml index a079f97229b..5411c729ad4 100644 --- a/test/unittest/xmlparser/SHM_transport_descriptors_config_profile.xml +++ b/test/unittest/xmlparser/SHM_transport_descriptors_config_profile.xml @@ -1,5 +1,5 @@ - + diff --git a/test/unittest/xmlparser/UDP_transport_descriptors_config_profile.xml b/test/unittest/xmlparser/UDP_transport_descriptors_config_profile.xml index 9a80454373f..3bf2ace35ed 100644 --- a/test/unittest/xmlparser/UDP_transport_descriptors_config_profile.xml +++ b/test/unittest/xmlparser/UDP_transport_descriptors_config_profile.xml @@ -1,5 +1,5 @@ - + diff --git a/test/unittest/xmlparser/XMLElementParserTests.cpp b/test/unittest/xmlparser/XMLElementParserTests.cpp index 3f9bf02e258..190c552e2d9 100644 --- a/test/unittest/xmlparser/XMLElementParserTests.cpp +++ b/test/unittest/xmlparser/XMLElementParserTests.cpp @@ -25,15 +25,17 @@ #include #include +#include #include -#include -#include -#include -#include +#include + +#include +#include +#include #include "../common/env_var_utils.hpp" #include "../logging/mock/MockConsumer.h" -#include "rtps/xmlparser/XMLParserUtils.hpp" +#include "xmlparser/XMLParserUtils.hpp" #include "wrapper/XMLParserTest.hpp" using namespace eprosima::fastdds::dds; @@ -552,7 +554,7 @@ TEST_F(XMLParserTests, getXMLLocatorTCPv6) TEST_F(XMLParserTests, getXMLTransports) { uint8_t ident = 1; - std::vector> transports; + std::vector> transports; tinyxml2::XMLDocument xml_doc; tinyxml2::XMLElement* titleElement; @@ -1770,7 +1772,7 @@ TEST_F(XMLParserTests, getXMLWriterReaderUnsupportedQosPolicies) TEST_F(XMLParserTests, ParticipantAllocationAttributesDataLimits) { uint8_t ident = 1; - rtps::RTPSParticipantAllocationAttributes allocation; + eprosima::fastrtps::rtps::RTPSParticipantAllocationAttributes allocation; tinyxml2::XMLDocument xml_doc; tinyxml2::XMLElement* titleElement; @@ -1809,7 +1811,7 @@ TEST_F(XMLParserTests, ParticipantAllocationAttributesDataLimits) TEST_F(XMLParserTests, getXMLDiscoverySettingsStaticEDP) { uint8_t ident = 1; - rtps::DiscoverySettings settings; + eprosima::fastrtps::rtps::DiscoverySettings settings; tinyxml2::XMLDocument xml_doc; tinyxml2::XMLElement* titleElement; @@ -2010,7 +2012,6 @@ TEST_F(XMLParserTests, getXMLDurabilityQosKind) * * * - * * 2. Check invalid element */ TEST_F(XMLParserTests, getXMLBuiltinAttributes_NegativeClauses) @@ -2051,8 +2052,7 @@ TEST_F(XMLParserTests, getXMLBuiltinAttributes_NegativeClauses) "readerPayloadSize", "writerPayloadSize", "mutation_tries", - "avoid_builtin_multicast", - "typelookup_config" + "avoid_builtin_multicast" }; for (std::string tag : field_vec) @@ -3374,7 +3374,7 @@ TEST_F(XMLParserTests, getXMLEnum_NegativeClauses) // IntraprocessDeliveryType Enum { - IntraprocessDeliveryType e; + eprosima::fastdds::IntraprocessDeliveryType e; const char* enum_p = "\ \ @@ -3475,7 +3475,7 @@ TEST_F(XMLParserTests, getXMLEnum_positive) // IntraprocessDeliveryType Enum { - IntraprocessDeliveryType e; + eprosima::fastdds::IntraprocessDeliveryType e; const char* enum_p = "\ OFF\ @@ -3485,12 +3485,12 @@ TEST_F(XMLParserTests, getXMLEnum_positive) ASSERT_EQ(tinyxml2::XMLError::XML_SUCCESS, xml_doc.Parse(enum_p)); titleElement = xml_doc.RootElement(); EXPECT_EQ(XMLP_ret::XML_OK, XMLParserTest::getXMLEnum_wrapper(titleElement, &e, ident)); - EXPECT_EQ(IntraprocessDeliveryType::INTRAPROCESS_OFF, e); + EXPECT_EQ(eprosima::fastdds::IntraprocessDeliveryType::INTRAPROCESS_OFF, e); } // IntraprocessDeliveryType Enum { - IntraprocessDeliveryType e; + eprosima::fastdds::IntraprocessDeliveryType e; const char* enum_p = "\ USER_DATA_ONLY\ @@ -3500,7 +3500,7 @@ TEST_F(XMLParserTests, getXMLEnum_positive) ASSERT_EQ(tinyxml2::XMLError::XML_SUCCESS, xml_doc.Parse(enum_p)); titleElement = xml_doc.RootElement(); EXPECT_EQ(XMLP_ret::XML_OK, XMLParserTest::getXMLEnum_wrapper(titleElement, &e, ident)); - EXPECT_EQ(IntraprocessDeliveryType::INTRAPROCESS_USER_DATA_ONLY, e); + EXPECT_EQ(eprosima::fastdds::IntraprocessDeliveryType::INTRAPROCESS_USER_DATA_ONLY, e); } // DiscoveryProtocol Enum @@ -4003,109 +4003,6 @@ TEST_F(XMLParserTests, getXMLOwnershipStrengthQos) } } -/* - * This test checks the positive cases of configuration through XML of the TypeLookupService. - * 1. Check that the XML return code is correct for the TypeLookup configuration settings. - * 2. Check that the flags are corretly set. - */ -TEST_F(XMLParserTests, getXMLTypeLookupSettings) -{ - uint8_t ident = 1; - TypeLookupSettings settings; - tinyxml2::XMLDocument xml_doc; - tinyxml2::XMLElement* titleElement; - - // XML snippet - const char* xml = - "\ - \ - true\ - false\ - \ - "; - - // Load the xml - ASSERT_EQ(tinyxml2::XMLError::XML_SUCCESS, xml_doc.Parse(xml)); - // Check that the XML return code is correct for the TypeLookup settings - titleElement = xml_doc.RootElement(); - EXPECT_EQ(XMLP_ret::XML_OK, XMLParserTest::getXMLTypeLookupSettings_wrapper(titleElement, settings, ident)); - EXPECT_TRUE(settings.use_server); - EXPECT_FALSE(settings.use_client); - - // XML snippet - xml = - "\ - \ - false\ - true\ - \ - "; - - // Load the xml - ASSERT_EQ(tinyxml2::XMLError::XML_SUCCESS, xml_doc.Parse(xml)); - // Check that the XML return code is correct for the TypeLookup settings - EXPECT_EQ(XMLP_ret::XML_OK, XMLParserTest::getXMLTypeLookupSettings_wrapper(titleElement, settings, ident)); - EXPECT_FALSE(settings.use_server); - EXPECT_TRUE(settings.use_client); -} - -/* - * This test checks the negative cases in the xml element. - * 1. Check an invalid tag of: - * - * - * 2. Check invalid element. - */ -TEST_F(XMLParserTests, getXMLTypeLookupSettings_NegativeClauses) -{ - uint8_t ident = 1; - TypeLookupSettings settings; - tinyxml2::XMLDocument xml_doc; - tinyxml2::XMLElement* titleElement; - - // Parametrized XML - const char* xml_p = - "\ - \ - %s\ - \ - "; - constexpr size_t xml_len {1000}; - char xml[xml_len]; - - const char* field_p = - "\ - <%s>\ - \ - \ - "; - constexpr size_t field_len {500}; - char field[field_len]; - - std::vector field_vec = - { - "use_client", - "use_server", - }; - - for (std::string tag : field_vec) - { - snprintf(field, field_len, field_p, tag.c_str(), tag.c_str()); - snprintf(xml, xml_len, xml_p, field); - ASSERT_EQ(tinyxml2::XMLError::XML_SUCCESS, xml_doc.Parse(xml)); - titleElement = xml_doc.RootElement(); - EXPECT_EQ(XMLP_ret::XML_ERROR, - XMLParserTest::getXMLTypeLookupSettings_wrapper(titleElement, settings, ident)); - } - - // Invalid element - snprintf(xml, xml_len, xml_p, " "); - ASSERT_EQ(tinyxml2::XMLError::XML_SUCCESS, xml_doc.Parse(xml)); - titleElement = xml_doc.RootElement(); - EXPECT_EQ(XMLP_ret::XML_ERROR, - XMLParserTest::getXMLTypeLookupSettings_wrapper(titleElement, settings, ident)); -} - TEST_F(XMLParserTests, get_element_text) { using namespace eprosima::fastdds::xml::detail; diff --git a/test/unittest/xmlparser/XMLEndpointParserTests.cpp b/test/unittest/xmlparser/XMLEndpointParserTests.cpp index 59ecdf722a7..c92dbed8d23 100644 --- a/test/unittest/xmlparser/XMLEndpointParserTests.cpp +++ b/test/unittest/xmlparser/XMLEndpointParserTests.cpp @@ -12,22 +12,24 @@ // See the License for the specific language governing permissions and // limitations under the License. -#include -#include -#include +#include +#include +#include + +#include +#include + +#include #include #include -#include #include #include -#include "../logging/mock/MockConsumer.h" +#include +#include -#include -#include +#include -#include -#include -#include +#include "../logging/mock/MockConsumer.h" using namespace eprosima::fastrtps; using namespace eprosima::fastrtps::rtps; diff --git a/test/unittest/xmlparser/XMLParserTests.cpp b/test/unittest/xmlparser/XMLParserTests.cpp index b36a0e383b4..811618d10f7 100644 --- a/test/unittest/xmlparser/XMLParserTests.cpp +++ b/test/unittest/xmlparser/XMLParserTests.cpp @@ -17,6 +17,9 @@ #include #include +#include +#include + #include #include #include @@ -28,18 +31,15 @@ #include #include #include -#include -#include -#include -#include -#include -#include -#include -#include - -#include +#include +#include +#include +#include +#include -#include +#include +#include +#include #include "../logging/mock/MockConsumer.h" #include "wrapper/XMLParserTest.hpp" @@ -89,7 +89,7 @@ TEST_F(XMLParserTests, NoFile) TEST_F(XMLParserTests, EmptyDefaultFile) { std::ifstream inFile; - inFile.open("DEFAULT_FASTRTPS_PROFILES.xml"); + inFile.open("DEFAULT_FASTDDS_PROFILES.xml"); std::unique_ptr root; ASSERT_EQ(XMLParser::loadDefaultXMLFile(root), XMLP_ret::XML_ERROR); } @@ -524,8 +524,6 @@ TEST_F(XMLParserTests, Data) EXPECT_EQ(builtin.readerPayloadSize, 1000u); EXPECT_EQ(builtin.writerPayloadSize, 2000u); EXPECT_EQ(builtin.mutation_tries, 55u); - EXPECT_TRUE(builtin.typelookup_config.use_client); - EXPECT_TRUE(builtin.typelookup_config.use_server); EXPECT_EQ(port.portBase, 12); EXPECT_EQ(port.domainIDGain, 34); EXPECT_EQ(port.participantIDGain, 56); @@ -620,8 +618,6 @@ TEST_F(XMLParserTests, DataDeprecated) EXPECT_EQ(builtin.readerPayloadSize, 1000u); EXPECT_EQ(builtin.writerPayloadSize, 2000u); EXPECT_EQ(builtin.mutation_tries, 55u); - EXPECT_TRUE(builtin.typelookup_config.use_client); - EXPECT_TRUE(builtin.typelookup_config.use_server); EXPECT_EQ(port.portBase, 12); EXPECT_EQ(port.domainIDGain, 34); EXPECT_EQ(port.participantIDGain, 56); @@ -716,8 +712,6 @@ TEST_F(XMLParserTests, DataBuffer) EXPECT_EQ(builtin.readerPayloadSize, 1000u); EXPECT_EQ(builtin.writerPayloadSize, 2000u); EXPECT_EQ(builtin.mutation_tries, 55u); - EXPECT_TRUE(builtin.typelookup_config.use_client); - EXPECT_TRUE(builtin.typelookup_config.use_server); EXPECT_EQ(port.portBase, 12); EXPECT_EQ(port.domainIDGain, 34); EXPECT_EQ(port.participantIDGain, 56); @@ -812,8 +806,6 @@ TEST_F(XMLParserTests, DataBufferDeprecated) EXPECT_EQ(builtin.readerPayloadSize, 1000u); EXPECT_EQ(builtin.writerPayloadSize, 2000u); EXPECT_EQ(builtin.mutation_tries, 55u); - EXPECT_TRUE(builtin.typelookup_config.use_client); - EXPECT_TRUE(builtin.typelookup_config.use_server); EXPECT_EQ(port.portBase, 12); EXPECT_EQ(port.domainIDGain, 34); EXPECT_EQ(port.participantIDGain, 56); @@ -962,8 +954,8 @@ TEST_F(XMLParserTests, parseXMLTransportData) ASSERT_EQ(tinyxml2::XMLError::XML_SUCCESS, xml_doc.Parse(xml)); titleElement = xml_doc.RootElement(); EXPECT_EQ(XMLP_ret::XML_OK, XMLParserTest::parseXMLTransportData_wrapper(titleElement)); - std::shared_ptr pUDPv4Desc = - std::dynamic_pointer_cast( + std::shared_ptr pUDPv4Desc = + std::dynamic_pointer_cast( xmlparser::XMLProfileManager::getTransportById("TransportId1")); EXPECT_EQ(pUDPv4Desc->sendBufferSize, 8192u); EXPECT_EQ(pUDPv4Desc->receiveBufferSize, 8192u); @@ -991,8 +983,8 @@ TEST_F(XMLParserTests, parseXMLTransportData) ASSERT_EQ(tinyxml2::XMLError::XML_SUCCESS, xml_doc.Parse(xml)); titleElement = xml_doc.RootElement(); EXPECT_EQ(XMLP_ret::XML_OK, XMLParserTest::parseXMLTransportData_wrapper(titleElement)); - std::shared_ptr pUDPv6Desc = - std::dynamic_pointer_cast( + std::shared_ptr pUDPv6Desc = + std::dynamic_pointer_cast( xmlparser::XMLProfileManager::getTransportById("TransportId1")); EXPECT_EQ(pUDPv6Desc->sendBufferSize, 8192u); EXPECT_EQ(pUDPv6Desc->receiveBufferSize, 8192u); @@ -1102,8 +1094,8 @@ TEST_F(XMLParserTests, parseXMLTransportData) ASSERT_EQ(tinyxml2::XMLError::XML_SUCCESS, xml_doc.Parse(xml)); titleElement = xml_doc.RootElement(); EXPECT_EQ(XMLP_ret::XML_OK, XMLParserTest::parseXMLTransportData_wrapper(titleElement)); - std::shared_ptr pTCPv4Desc = - std::dynamic_pointer_cast( + std::shared_ptr pTCPv4Desc = + std::dynamic_pointer_cast( xmlparser::XMLProfileManager::getTransportById("TransportId1")); EXPECT_EQ(pTCPv4Desc->sendBufferSize, 8192u); EXPECT_EQ(pTCPv4Desc->receiveBufferSize, 8192u); @@ -1142,8 +1134,8 @@ TEST_F(XMLParserTests, parseXMLTransportData) ASSERT_EQ(tinyxml2::XMLError::XML_SUCCESS, xml_doc.Parse(xml)); titleElement = xml_doc.RootElement(); EXPECT_EQ(XMLP_ret::XML_OK, XMLParserTest::parseXMLTransportData_wrapper(titleElement)); - std::shared_ptr pTCPv6Desc = - std::dynamic_pointer_cast( + std::shared_ptr pTCPv6Desc = + std::dynamic_pointer_cast( xmlparser::XMLProfileManager::getTransportById("TransportId1")); EXPECT_EQ(pTCPv6Desc->sendBufferSize, 8192u); EXPECT_EQ(pTCPv6Desc->receiveBufferSize, 8192u); @@ -1989,7 +1981,7 @@ TEST_F(XMLParserTests, parseTLSConfigPositiveClauses) std::unique_ptr root; tinyxml2::XMLElement* titleElement; std::shared_ptr tcp_transport = - std::make_shared(); + std::make_shared(); // Parametrized XML const char* xml = @@ -2024,7 +2016,7 @@ TEST_F(XMLParserTests, parseTLSConfigNegativeClauses) std::unique_ptr root; tinyxml2::XMLElement* titleElement; std::shared_ptr tcp_transport = - std::make_shared(); + std::make_shared(); constexpr size_t xml_len {600}; char xml[xml_len]; @@ -2172,7 +2164,7 @@ TEST_F(XMLParserTests, parseTLSConfigHandshakeRole) std::unique_ptr root; tinyxml2::XMLElement* titleElement; std::shared_ptr tcp_transport = - std::make_shared(); + std::make_shared(); constexpr size_t xml_len {600}; char xml[xml_len]; @@ -2191,10 +2183,10 @@ TEST_F(XMLParserTests, parseTLSConfigHandshakeRole) ASSERT_EQ(tinyxml2::XMLError::XML_SUCCESS, xml_doc.Parse(xml)); titleElement = xml_doc.RootElement(); EXPECT_EQ(XMLP_ret::XML_OK, XMLParserTest::parse_tls_config_wrapper(titleElement, tcp_transport)); - std::shared_ptr descriptor = - std::dynamic_pointer_cast(tcp_transport); + std::shared_ptr descriptor = + std::dynamic_pointer_cast(tcp_transport); EXPECT_EQ(descriptor->tls_config.handshake_role, - TCPTransportDescriptor::TLSConfig::TLSHandShakeRole::DEFAULT); + eprosima::fastdds::rtps::TCPTransportDescriptor::TLSConfig::TLSHandShakeRole::DEFAULT); } // Check that the CLIENT setting return an xml ok code and is set correctly. @@ -2203,10 +2195,10 @@ TEST_F(XMLParserTests, parseTLSConfigHandshakeRole) ASSERT_EQ(tinyxml2::XMLError::XML_SUCCESS, xml_doc.Parse(xml)); titleElement = xml_doc.RootElement(); EXPECT_EQ(XMLP_ret::XML_OK, XMLParserTest::parse_tls_config_wrapper(titleElement, tcp_transport)); - std::shared_ptr descriptor = - std::dynamic_pointer_cast(tcp_transport); + std::shared_ptr descriptor = + std::dynamic_pointer_cast(tcp_transport); EXPECT_EQ(descriptor->tls_config.handshake_role, - TCPTransportDescriptor::TLSConfig::TLSHandShakeRole::CLIENT); + eprosima::fastdds::rtps::TCPTransportDescriptor::TLSConfig::TLSHandShakeRole::CLIENT); } // Check that the SERVER setting return an xml ok code and is set correctly. @@ -2215,10 +2207,10 @@ TEST_F(XMLParserTests, parseTLSConfigHandshakeRole) ASSERT_EQ(tinyxml2::XMLError::XML_SUCCESS, xml_doc.Parse(xml)); titleElement = xml_doc.RootElement(); EXPECT_EQ(XMLP_ret::XML_OK, XMLParserTest::parse_tls_config_wrapper(titleElement, tcp_transport)); - std::shared_ptr descriptor = - std::dynamic_pointer_cast(tcp_transport); + std::shared_ptr descriptor = + std::dynamic_pointer_cast(tcp_transport); EXPECT_EQ(descriptor->tls_config.handshake_role, - TCPTransportDescriptor::TLSConfig::TLSHandShakeRole::SERVER); + eprosima::fastdds::rtps::TCPTransportDescriptor::TLSConfig::TLSHandShakeRole::SERVER); } } @@ -2254,12 +2246,13 @@ TEST_F(XMLParserTests, parseTLSConfigVerifyMode) titleElement = xml_doc.RootElement(); std::shared_ptr tcp_transport = - std::make_shared(); + std::make_shared(); EXPECT_EQ(XMLP_ret::XML_OK, XMLParserTest::parse_tls_config_wrapper(titleElement, tcp_transport)); - std::shared_ptr descriptor = - std::dynamic_pointer_cast(tcp_transport); - EXPECT_EQ(descriptor->tls_config.verify_mode, TCPTransportDescriptor::TLSConfig::TLSVerifyMode::VERIFY_NONE); + std::shared_ptr descriptor = + std::dynamic_pointer_cast(tcp_transport); + EXPECT_EQ(descriptor->tls_config.verify_mode, + eprosima::fastdds::rtps::TCPTransportDescriptor::TLSConfig::TLSVerifyMode::VERIFY_NONE); } // Check that the VERIFY_PEER setting return an xml ok code and is set correctly. @@ -2269,12 +2262,13 @@ TEST_F(XMLParserTests, parseTLSConfigVerifyMode) titleElement = xml_doc.RootElement(); std::shared_ptr tcp_transport = - std::make_shared(); + std::make_shared(); EXPECT_EQ(XMLP_ret::XML_OK, XMLParserTest::parse_tls_config_wrapper(titleElement, tcp_transport)); - std::shared_ptr descriptor = - std::dynamic_pointer_cast(tcp_transport); - EXPECT_EQ(descriptor->tls_config.verify_mode, TCPTransportDescriptor::TLSConfig::TLSVerifyMode::VERIFY_PEER); + std::shared_ptr descriptor = + std::dynamic_pointer_cast(tcp_transport); + EXPECT_EQ(descriptor->tls_config.verify_mode, + eprosima::fastdds::rtps::TCPTransportDescriptor::TLSConfig::TLSVerifyMode::VERIFY_PEER); } // Check that the VERIFY_FAIL_IF_NO_PEER_CERT setting return an xml ok code and is set correctly. @@ -2284,13 +2278,13 @@ TEST_F(XMLParserTests, parseTLSConfigVerifyMode) titleElement = xml_doc.RootElement(); std::shared_ptr tcp_transport = - std::make_shared(); + std::make_shared(); EXPECT_EQ(XMLP_ret::XML_OK, XMLParserTest::parse_tls_config_wrapper(titleElement, tcp_transport)); - std::shared_ptr descriptor = - std::dynamic_pointer_cast(tcp_transport); + std::shared_ptr descriptor = + std::dynamic_pointer_cast(tcp_transport); EXPECT_EQ(descriptor->tls_config.verify_mode, - TCPTransportDescriptor::TLSConfig::TLSVerifyMode::VERIFY_FAIL_IF_NO_PEER_CERT); + eprosima::fastdds::rtps::TCPTransportDescriptor::TLSConfig::TLSVerifyMode::VERIFY_FAIL_IF_NO_PEER_CERT); } // Check that the VERIFY_CLIENT_ONCE setting return an xml ok code and is set correctly. @@ -2300,12 +2294,12 @@ TEST_F(XMLParserTests, parseTLSConfigVerifyMode) titleElement = xml_doc.RootElement(); std::shared_ptr tcp_transport = - std::make_shared(); + std::make_shared(); EXPECT_EQ(XMLP_ret::XML_OK, XMLParserTest::parse_tls_config_wrapper(titleElement, tcp_transport)); - std::shared_ptr descriptor = - std::dynamic_pointer_cast(tcp_transport); + std::shared_ptr descriptor = + std::dynamic_pointer_cast(tcp_transport); EXPECT_EQ(descriptor->tls_config.verify_mode, - TCPTransportDescriptor::TLSConfig::TLSVerifyMode::VERIFY_CLIENT_ONCE); + eprosima::fastdds::rtps::TCPTransportDescriptor::TLSConfig::TLSVerifyMode::VERIFY_CLIENT_ONCE); } } @@ -2327,7 +2321,7 @@ TEST_F(XMLParserTests, parseTLSConfigOptions) std::unique_ptr root; tinyxml2::XMLElement* titleElement; std::shared_ptr tcp_transport = - std::make_shared(); + std::make_shared(); constexpr size_t xml_len {600}; char xml[xml_len]; @@ -2347,10 +2341,11 @@ TEST_F(XMLParserTests, parseTLSConfigOptions) ASSERT_EQ(tinyxml2::XMLError::XML_SUCCESS, xml_doc.Parse(xml)); titleElement = xml_doc.RootElement(); EXPECT_EQ(XMLP_ret::XML_OK, XMLParserTest::parse_tls_config_wrapper(titleElement, tcp_transport)); - std::shared_ptr descriptor = - std::dynamic_pointer_cast(tcp_transport); + std::shared_ptr descriptor = + std::dynamic_pointer_cast(tcp_transport); EXPECT_TRUE( - descriptor->tls_config.get_option(TCPTransportDescriptor::TLSConfig::TLSOptions::DEFAULT_WORKAROUNDS)); + descriptor->tls_config.get_option(eprosima::fastdds::rtps::TCPTransportDescriptor::TLSConfig::TLSOptions:: + DEFAULT_WORKAROUNDS)); } // Check that the NO_COMPRESSION setting return an xml ok code and is set correctly. @@ -2359,10 +2354,11 @@ TEST_F(XMLParserTests, parseTLSConfigOptions) ASSERT_EQ(tinyxml2::XMLError::XML_SUCCESS, xml_doc.Parse(xml)); titleElement = xml_doc.RootElement(); EXPECT_EQ(XMLP_ret::XML_OK, XMLParserTest::parse_tls_config_wrapper(titleElement, tcp_transport)); - std::shared_ptr descriptor = - std::dynamic_pointer_cast(tcp_transport); + std::shared_ptr descriptor = + std::dynamic_pointer_cast(tcp_transport); EXPECT_TRUE( - descriptor->tls_config.get_option(TCPTransportDescriptor::TLSConfig::TLSOptions::NO_COMPRESSION)); + descriptor->tls_config.get_option(eprosima::fastdds::rtps::TCPTransportDescriptor::TLSConfig::TLSOptions:: + NO_COMPRESSION)); } // Check that the NO_SSLV2 setting return an xml ok code and is set correctly. @@ -2371,10 +2367,11 @@ TEST_F(XMLParserTests, parseTLSConfigOptions) ASSERT_EQ(tinyxml2::XMLError::XML_SUCCESS, xml_doc.Parse(xml)); titleElement = xml_doc.RootElement(); EXPECT_EQ(XMLP_ret::XML_OK, XMLParserTest::parse_tls_config_wrapper(titleElement, tcp_transport)); - std::shared_ptr descriptor = - std::dynamic_pointer_cast(tcp_transport); + std::shared_ptr descriptor = + std::dynamic_pointer_cast(tcp_transport); EXPECT_TRUE( - descriptor->tls_config.get_option(TCPTransportDescriptor::TLSConfig::TLSOptions::NO_SSLV2)); + descriptor->tls_config.get_option(eprosima::fastdds::rtps::TCPTransportDescriptor::TLSConfig::TLSOptions:: + NO_SSLV2)); } // Check that the NO_SSLV3 setting return an xml ok code and is set correctly. @@ -2383,10 +2380,11 @@ TEST_F(XMLParserTests, parseTLSConfigOptions) ASSERT_EQ(tinyxml2::XMLError::XML_SUCCESS, xml_doc.Parse(xml)); titleElement = xml_doc.RootElement(); EXPECT_EQ(XMLP_ret::XML_OK, XMLParserTest::parse_tls_config_wrapper(titleElement, tcp_transport)); - std::shared_ptr descriptor = - std::dynamic_pointer_cast(tcp_transport); + std::shared_ptr descriptor = + std::dynamic_pointer_cast(tcp_transport); EXPECT_TRUE( - descriptor->tls_config.get_option(TCPTransportDescriptor::TLSConfig::TLSOptions::NO_SSLV3)); + descriptor->tls_config.get_option(eprosima::fastdds::rtps::TCPTransportDescriptor::TLSConfig::TLSOptions:: + NO_SSLV3)); } // Check that the NO_TLSV1 setting return an xml ok code and is set correctly. @@ -2395,10 +2393,11 @@ TEST_F(XMLParserTests, parseTLSConfigOptions) ASSERT_EQ(tinyxml2::XMLError::XML_SUCCESS, xml_doc.Parse(xml)); titleElement = xml_doc.RootElement(); EXPECT_EQ(XMLP_ret::XML_OK, XMLParserTest::parse_tls_config_wrapper(titleElement, tcp_transport)); - std::shared_ptr descriptor = - std::dynamic_pointer_cast(tcp_transport); + std::shared_ptr descriptor = + std::dynamic_pointer_cast(tcp_transport); EXPECT_TRUE( - descriptor->tls_config.get_option(TCPTransportDescriptor::TLSConfig::TLSOptions::NO_TLSV1)); + descriptor->tls_config.get_option(eprosima::fastdds::rtps::TCPTransportDescriptor::TLSConfig::TLSOptions:: + NO_TLSV1)); } // Check that the NO_TLSV1_1 setting return an xml ok code and is set correctly. @@ -2407,10 +2406,11 @@ TEST_F(XMLParserTests, parseTLSConfigOptions) ASSERT_EQ(tinyxml2::XMLError::XML_SUCCESS, xml_doc.Parse(xml)); titleElement = xml_doc.RootElement(); EXPECT_EQ(XMLP_ret::XML_OK, XMLParserTest::parse_tls_config_wrapper(titleElement, tcp_transport)); - std::shared_ptr descriptor = - std::dynamic_pointer_cast(tcp_transport); + std::shared_ptr descriptor = + std::dynamic_pointer_cast(tcp_transport); EXPECT_TRUE( - descriptor->tls_config.get_option(TCPTransportDescriptor::TLSConfig::TLSOptions::NO_TLSV1_1)); + descriptor->tls_config.get_option(eprosima::fastdds::rtps::TCPTransportDescriptor::TLSConfig::TLSOptions:: + NO_TLSV1_1)); } // Check that the NO_TLSV1_2 setting return an xml ok code and is set correctly. @@ -2419,10 +2419,11 @@ TEST_F(XMLParserTests, parseTLSConfigOptions) ASSERT_EQ(tinyxml2::XMLError::XML_SUCCESS, xml_doc.Parse(xml)); titleElement = xml_doc.RootElement(); EXPECT_EQ(XMLP_ret::XML_OK, XMLParserTest::parse_tls_config_wrapper(titleElement, tcp_transport)); - std::shared_ptr descriptor = - std::dynamic_pointer_cast(tcp_transport); + std::shared_ptr descriptor = + std::dynamic_pointer_cast(tcp_transport); EXPECT_TRUE( - descriptor->tls_config.get_option(TCPTransportDescriptor::TLSConfig::TLSOptions::NO_TLSV1_2)); + descriptor->tls_config.get_option(eprosima::fastdds::rtps::TCPTransportDescriptor::TLSConfig::TLSOptions:: + NO_TLSV1_2)); } // Check that the NO_TLSV1_3 setting return an xml ok code and is set correctly. @@ -2431,10 +2432,11 @@ TEST_F(XMLParserTests, parseTLSConfigOptions) ASSERT_EQ(tinyxml2::XMLError::XML_SUCCESS, xml_doc.Parse(xml)); titleElement = xml_doc.RootElement(); EXPECT_EQ(XMLP_ret::XML_OK, XMLParserTest::parse_tls_config_wrapper(titleElement, tcp_transport)); - std::shared_ptr descriptor = - std::dynamic_pointer_cast(tcp_transport); + std::shared_ptr descriptor = + std::dynamic_pointer_cast(tcp_transport); EXPECT_TRUE( - descriptor->tls_config.get_option(TCPTransportDescriptor::TLSConfig::TLSOptions::NO_TLSV1_3)); + descriptor->tls_config.get_option(eprosima::fastdds::rtps::TCPTransportDescriptor::TLSConfig::TLSOptions:: + NO_TLSV1_3)); } // Check that the SINGLE_DH_USE setting return an xml ok code and is set correctly. @@ -2443,10 +2445,11 @@ TEST_F(XMLParserTests, parseTLSConfigOptions) ASSERT_EQ(tinyxml2::XMLError::XML_SUCCESS, xml_doc.Parse(xml)); titleElement = xml_doc.RootElement(); EXPECT_EQ(XMLP_ret::XML_OK, XMLParserTest::parse_tls_config_wrapper(titleElement, tcp_transport)); - std::shared_ptr descriptor = - std::dynamic_pointer_cast(tcp_transport); + std::shared_ptr descriptor = + std::dynamic_pointer_cast(tcp_transport); EXPECT_TRUE( - descriptor->tls_config.get_option(TCPTransportDescriptor::TLSConfig::TLSOptions::SINGLE_DH_USE)); + descriptor->tls_config.get_option(eprosima::fastdds::rtps::TCPTransportDescriptor::TLSConfig::TLSOptions:: + SINGLE_DH_USE)); } } @@ -3071,7 +3074,7 @@ TEST_F(XMLParserTests, parseXMLReceptionThreads) std::string title; std::string xml; xmlparser::XMLP_ret result; - PortBasedTransportDescriptor::ReceptionThreadsConfigMap threads_config; + eprosima::fastdds::rtps::PortBasedTransportDescriptor::ReceptionThreadsConfigMap threads_config; }; ThreadSettings modified_thread_settings; @@ -3181,7 +3184,7 @@ TEST_F(XMLParserTests, parseXMLReceptionThreads) tinyxml2::XMLDocument xml_doc; std::unique_ptr root; tinyxml2::XMLElement* titleElement; - PortBasedTransportDescriptor::ReceptionThreadsConfigMap reception_threads; + eprosima::fastdds::rtps::PortBasedTransportDescriptor::ReceptionThreadsConfigMap reception_threads; ASSERT_EQ(tinyxml2::XMLError::XML_SUCCESS, xml_doc.Parse(test_case.xml.c_str())) << "test_case = [" << test_case.title << "]"; diff --git a/test/unittest/xmlparser/XMLParserTests.hpp b/test/unittest/xmlparser/XMLParserTests.hpp index 5791f15e288..7e3be090639 100644 --- a/test/unittest/xmlparser/XMLParserTests.hpp +++ b/test/unittest/xmlparser/XMLParserTests.hpp @@ -12,15 +12,16 @@ // See the License for the specific language governing permissions and // limitations under the License. +#include + #include -#include -#include -#include +#include +#include #include "../logging/mock/MockConsumer.h" - +using namespace eprosima::fastdds; using namespace eprosima::fastrtps; using namespace eprosima::fastrtps::rtps; using namespace eprosima::fastrtps::xmlparser; diff --git a/test/unittest/xmlparser/XMLProfileParserTests.cpp b/test/unittest/xmlparser/XMLProfileParserTests.cpp index 74de575eab8..d8e98b0554c 100644 --- a/test/unittest/xmlparser/XMLProfileParserTests.cpp +++ b/test/unittest/xmlparser/XMLProfileParserTests.cpp @@ -28,17 +28,21 @@ #include #include #include +#include +#include #include #include #include #include -#include -#include -#include -#include +#include +#include +#include + +#include #include "../common/env_var_utils.hpp" +using namespace eprosima::fastdds; using namespace eprosima::fastrtps; using namespace eprosima::fastrtps::rtps; using namespace eprosima::testing; @@ -331,8 +335,9 @@ TEST_F(XMLProfileParserBasicTests, XMLParserRootLibrarySettings) ASSERT_EQ(xmlparser::XMLP_ret::XML_OK, xmlparser::XMLProfileManager::loadXMLFile("test_xml_root_library_settings_profile.xml")); - const LibrarySettingsAttributes& library_settings = xmlparser::XMLProfileManager::library_settings(); - EXPECT_EQ(library_settings.intraprocess_delivery, IntraprocessDeliveryType::INTRAPROCESS_USER_DATA_ONLY); + const eprosima::fastdds::LibrarySettings& library_settings = xmlparser::XMLProfileManager::library_settings(); + EXPECT_EQ(library_settings.intraprocess_delivery, + eprosima::fastdds::IntraprocessDeliveryType::INTRAPROCESS_USER_DATA_ONLY); } TEST_F(XMLProfileParserBasicTests, XMLoadProfiles) @@ -457,8 +462,8 @@ TEST_P(XMLProfileParserTests, XMLParserLibrarySettings) ASSERT_EQ(xmlparser::XMLP_ret::XML_OK, xmlparser::XMLProfileManager::loadXMLFile(xml_filename_)); - const LibrarySettingsAttributes& library_settings = xmlparser::XMLProfileManager::library_settings(); - EXPECT_EQ(library_settings.intraprocess_delivery, IntraprocessDeliveryType::INTRAPROCESS_FULL); + const eprosima::fastdds::LibrarySettings& library_settings = xmlparser::XMLProfileManager::library_settings(); + EXPECT_EQ(library_settings.intraprocess_delivery, eprosima::fastdds::IntraprocessDeliveryType::INTRAPROCESS_FULL); } /* @@ -546,8 +551,6 @@ TEST_P(XMLProfileParserTests, XMLParserParticipant) EXPECT_EQ(builtin.readerPayloadSize, 1000u); EXPECT_EQ(builtin.writerPayloadSize, 2000u); EXPECT_EQ(builtin.mutation_tries, 55u); - EXPECT_TRUE(builtin.typelookup_config.use_client); - EXPECT_TRUE(builtin.typelookup_config.use_server); EXPECT_EQ(port.portBase, 12); EXPECT_EQ(port.domainIDGain, 34); EXPECT_EQ(port.participantIDGain, 56); @@ -571,9 +574,9 @@ TEST_F(XMLProfileParserBasicTests, XMLParserParticipantDeprecated) std::string participant_profile = std::string("test_participant_profile"); ParticipantAttributes participant_atts; - ASSERT_EQ( xmlparser::XMLP_ret::XML_OK, + ASSERT_EQ(xmlparser::XMLP_ret::XML_OK, xmlparser::XMLProfileManager::loadXMLFile("test_xml_deprecated.xml")); - EXPECT_EQ( xmlparser::XMLP_ret::XML_OK, + EXPECT_EQ(xmlparser::XMLP_ret::XML_OK, xmlparser::XMLProfileManager::fillParticipantAttributes(participant_profile, participant_atts)); EXPECT_EQ(participant_atts.domainId, 2019102u); @@ -648,8 +651,6 @@ TEST_F(XMLProfileParserBasicTests, XMLParserParticipantDeprecated) EXPECT_EQ(builtin.readerPayloadSize, 1000u); EXPECT_EQ(builtin.writerPayloadSize, 2000u); EXPECT_EQ(builtin.mutation_tries, 55u); - EXPECT_TRUE(builtin.typelookup_config.use_client); - EXPECT_TRUE(builtin.typelookup_config.use_server); EXPECT_EQ(port.portBase, 12); EXPECT_EQ(port.domainIDGain, 34); EXPECT_EQ(port.participantIDGain, 56); @@ -733,8 +734,6 @@ TEST_P(XMLProfileParserTests, XMLParserDefaultParticipantProfile) EXPECT_EQ(builtin.readerPayloadSize, 1000u); EXPECT_EQ(builtin.writerPayloadSize, 2000u); EXPECT_EQ(builtin.mutation_tries, 55u); - EXPECT_TRUE(builtin.typelookup_config.use_client); - EXPECT_TRUE(builtin.typelookup_config.use_server); EXPECT_EQ(port.portBase, 12); EXPECT_EQ(port.domainIDGain, 34); EXPECT_EQ(port.participantIDGain, 56); @@ -818,8 +817,6 @@ TEST_F(XMLProfileParserBasicTests, XMLParserDefaultParticipantProfileDeprecated) EXPECT_EQ(builtin.readerPayloadSize, 1000u); EXPECT_EQ(builtin.writerPayloadSize, 2000u); EXPECT_EQ(builtin.mutation_tries, 55u); - EXPECT_TRUE(builtin.typelookup_config.use_client); - EXPECT_TRUE(builtin.typelookup_config.use_server); EXPECT_EQ(port.portBase, 12); EXPECT_EQ(port.domainIDGain, 34); EXPECT_EQ(port.participantIDGain, 56); @@ -1667,8 +1664,8 @@ TEST_F(XMLProfileParserBasicTests, tls_config) xmlparser::sp_transport_t transport = xmlparser::XMLProfileManager::getTransportById("Test"); - using TCPDescriptor = std::shared_ptr; - TCPDescriptor descriptor = std::dynamic_pointer_cast(transport); + using TCPDescriptor = std::shared_ptr; + TCPDescriptor descriptor = std::dynamic_pointer_cast(transport); /* @@ -1692,16 +1689,26 @@ TEST_F(XMLProfileParserBasicTests, tls_config) EXPECT_EQ("DH.pem", descriptor->tls_config.tmp_dh_file); EXPECT_EQ("verify.pem", descriptor->tls_config.verify_file); EXPECT_EQ("my_server.com", descriptor->tls_config.server_name); - EXPECT_EQ(TCPTransportDescriptor::TLSConfig::TLSVerifyMode::VERIFY_PEER, descriptor->tls_config.verify_mode); - EXPECT_TRUE(descriptor->tls_config.get_option(TCPTransportDescriptor::TLSConfig::TLSOptions::NO_TLSV1)); - EXPECT_TRUE(descriptor->tls_config.get_option(TCPTransportDescriptor::TLSConfig::TLSOptions::NO_TLSV1_1)); - EXPECT_FALSE(descriptor->tls_config.get_option(TCPTransportDescriptor::TLSConfig::TLSOptions::NO_SSLV2)); - EXPECT_FALSE(descriptor->tls_config.get_option(TCPTransportDescriptor::TLSConfig::TLSOptions::NO_SSLV3)); - EXPECT_FALSE(descriptor->tls_config.get_option(TCPTransportDescriptor::TLSConfig::TLSOptions::NO_TLSV1_2)); - EXPECT_FALSE(descriptor->tls_config.get_option(TCPTransportDescriptor::TLSConfig::TLSOptions::NO_TLSV1_3)); - EXPECT_FALSE(descriptor->tls_config.get_option(TCPTransportDescriptor::TLSConfig::TLSOptions::DEFAULT_WORKAROUNDS)); - EXPECT_FALSE(descriptor->tls_config.get_option(TCPTransportDescriptor::TLSConfig::TLSOptions::NO_COMPRESSION)); - EXPECT_FALSE(descriptor->tls_config.get_option(TCPTransportDescriptor::TLSConfig::TLSOptions::SINGLE_DH_USE)); + EXPECT_EQ(eprosima::fastdds::rtps::TCPTransportDescriptor::TLSConfig::TLSVerifyMode::VERIFY_PEER, + descriptor->tls_config.verify_mode); + EXPECT_TRUE(descriptor->tls_config.get_option(eprosima::fastdds::rtps::TCPTransportDescriptor::TLSConfig::TLSOptions + ::NO_TLSV1)); + EXPECT_TRUE(descriptor->tls_config.get_option(eprosima::fastdds::rtps::TCPTransportDescriptor::TLSConfig::TLSOptions + ::NO_TLSV1_1)); + EXPECT_FALSE(descriptor->tls_config.get_option(eprosima::fastdds::rtps::TCPTransportDescriptor::TLSConfig:: + TLSOptions::NO_SSLV2)); + EXPECT_FALSE(descriptor->tls_config.get_option(eprosima::fastdds::rtps::TCPTransportDescriptor::TLSConfig:: + TLSOptions::NO_SSLV3)); + EXPECT_FALSE(descriptor->tls_config.get_option(eprosima::fastdds::rtps::TCPTransportDescriptor::TLSConfig:: + TLSOptions::NO_TLSV1_2)); + EXPECT_FALSE(descriptor->tls_config.get_option(eprosima::fastdds::rtps::TCPTransportDescriptor::TLSConfig:: + TLSOptions::NO_TLSV1_3)); + EXPECT_FALSE(descriptor->tls_config.get_option(eprosima::fastdds::rtps::TCPTransportDescriptor::TLSConfig:: + TLSOptions::DEFAULT_WORKAROUNDS)); + EXPECT_FALSE(descriptor->tls_config.get_option(eprosima::fastdds::rtps::TCPTransportDescriptor::TLSConfig:: + TLSOptions::NO_COMPRESSION)); + EXPECT_FALSE(descriptor->tls_config.get_option(eprosima::fastdds::rtps::TCPTransportDescriptor::TLSConfig:: + TLSOptions::SINGLE_DH_USE)); EXPECT_EQ(descriptor->tls_config.verify_paths.size(), static_cast(3)); EXPECT_EQ(descriptor->tls_config.verify_paths[0], "Path1"); @@ -1710,7 +1717,8 @@ TEST_F(XMLProfileParserBasicTests, tls_config) EXPECT_EQ(descriptor->tls_config.verify_depth, static_cast(55)); EXPECT_TRUE(descriptor->tls_config.default_verify_path); - EXPECT_EQ(descriptor->tls_config.handshake_role, TCPTransportDescriptor::TLSConfig::TLSHandShakeRole::SERVER); + EXPECT_EQ(descriptor->tls_config.handshake_role, + eprosima::fastdds::rtps::TCPTransportDescriptor::TLSConfig::TLSHandShakeRole::SERVER); } TEST_F(XMLProfileParserBasicTests, UDP_transport_descriptors_config) @@ -1722,8 +1730,8 @@ TEST_F(XMLProfileParserBasicTests, UDP_transport_descriptors_config) xmlparser::sp_transport_t transport = xmlparser::XMLProfileManager::getTransportById("Test"); - using UDPDescriptor = std::shared_ptr; - UDPDescriptor descriptor = std::dynamic_pointer_cast(transport); + using UDPDescriptor = std::shared_ptr; + UDPDescriptor descriptor = std::dynamic_pointer_cast(transport); ASSERT_NE(descriptor, nullptr); EXPECT_EQ(descriptor->sendBufferSize, 8192u); @@ -1777,15 +1785,9 @@ TEST_F(XMLProfileParserBasicTests, insertTransportByIdNegativeClauses) */ TEST_F(XMLProfileParserBasicTests, getDynamicTypeByNameNegativeClausesNegativeClauses) { - EXPECT_EQ(nullptr, xmlparser::XMLProfileManager::getDynamicTypeByName("wrong_type")); -} - -/* - * Test return code of the CreateDynamicPubSubType method when trying to retrieve a type which has not been parsed - */ -TEST_F(XMLProfileParserBasicTests, CreateDynamicPubSubType) -{ - EXPECT_EQ(nullptr, xmlparser::XMLProfileManager::CreateDynamicPubSubType("wrong_type")); + eprosima::fastdds::dds::traits::ref_type type; + EXPECT_EQ(xmlparser::XMLP_ret::XML_ERROR, xmlparser::XMLProfileManager::getDynamicTypeByName(type, "wrong_type")); + ASSERT_FALSE(type); } /* @@ -2074,7 +2076,7 @@ TEST_F(XMLProfileParserBasicTests, skip_default_xml) "; tinyxml2::XMLDocument xml_doc; xml_doc.Parse(xml); - xml_doc.SaveFile("DEFAULT_FASTRTPS_PROFILES.xml"); + xml_doc.SaveFile("DEFAULT_FASTDDS_PROFILES.xml"); #ifdef _WIN32 _putenv_s("SKIP_DEFAULT_XML_FILE", "1"); @@ -2094,13 +2096,13 @@ TEST_F(XMLProfileParserBasicTests, skip_default_xml) xmlparser::XMLProfileManager::loadDefaultXMLFile(); xmlparser::XMLProfileManager::getDefaultParticipantAttributes(participant_atts_default); - remove("DEFAULT_FASTRTPS_PROFILES.xml"); + remove("DEFAULT_FASTDDS_PROFILES.xml"); EXPECT_NE(participant_atts_none.domainId, participant_atts_default.domainId); } /* - * Tests whether the FASTRTPS_DEFAULT_PROFILES_FILE environment file correctly loads the selected file as default. + * Tests whether the FASTDDS_DEFAULT_PROFILES_FILE environment file correctly loads the selected file as default. * - participant_atts_default contains the attributes in the default file in this folder. * - participant_atts_file contains the attributes in the default file created by the test. */ @@ -2117,21 +2119,21 @@ TEST_F(XMLProfileParserBasicTests, default_env_variable) "; tinyxml2::XMLDocument xml_doc; xml_doc.Parse(xml); - xml_doc.SaveFile("FASTRTPS_PROFILES.xml"); + xml_doc.SaveFile("FASTDDS_PROFILES.xml"); ParticipantAttributes participant_atts_default; xmlparser::XMLProfileManager::loadDefaultXMLFile(); xmlparser::XMLProfileManager::getDefaultParticipantAttributes(participant_atts_default); #ifdef _WIN32 - _putenv_s("FASTRTPS_DEFAULT_PROFILES_FILE", "FASTRTPS_PROFILES.xml"); + _putenv_s("FASTDDS_DEFAULT_PROFILES_FILE", "FASTDDS_PROFILES.xml"); #else - setenv("FASTRTPS_DEFAULT_PROFILES_FILE", "FASTRTPS_PROFILES.xml", 1); + setenv("FASTDDS_DEFAULT_PROFILES_FILE", "FASTDDS_PROFILES.xml", 1); #endif // ifdef _WIN32 ParticipantAttributes participant_atts_file; xmlparser::XMLProfileManager::loadDefaultXMLFile(); xmlparser::XMLProfileManager::getDefaultParticipantAttributes(participant_atts_file); - remove("FASTRTPS_PROFILES.xml"); + remove("FASTDDS_PROFILES.xml"); EXPECT_NE(participant_atts_file.domainId, participant_atts_default.domainId); } @@ -3232,7 +3234,7 @@ TEST_F(XMLProfileParserBasicTests, log_thread_settings_qos) "log_thread_settings_ok", R"( - + -1 @@ -3248,7 +3250,7 @@ TEST_F(XMLProfileParserBasicTests, log_thread_settings_qos) "log_thread_settings_duplicate", R"( - + -1 @@ -3270,7 +3272,7 @@ TEST_F(XMLProfileParserBasicTests, log_thread_settings_qos) "log_thread_settings_wrong", R"( - + -1 @@ -3325,7 +3327,7 @@ TEST_F(XMLProfileParserBasicTests, domainparticipantfactory) "entity_factory_ok", R"( - + @@ -3345,7 +3347,7 @@ TEST_F(XMLProfileParserBasicTests, domainparticipantfactory) "shm_watchdog_thread_ok", R"( - + @@ -3368,7 +3370,7 @@ TEST_F(XMLProfileParserBasicTests, domainparticipantfactory) "file_watch_threads_ok", R"( - + @@ -3391,7 +3393,7 @@ TEST_F(XMLProfileParserBasicTests, domainparticipantfactory) "all_present_ok", R"( - + @@ -3423,7 +3425,7 @@ TEST_F(XMLProfileParserBasicTests, domainparticipantfactory) "qos_duplicated", R"( - + @@ -3448,7 +3450,7 @@ TEST_F(XMLProfileParserBasicTests, domainparticipantfactory) "entity_factory_wrong_tag", R"( - + @@ -3468,7 +3470,7 @@ TEST_F(XMLProfileParserBasicTests, domainparticipantfactory) "entity_factory_duplicated_autoenable_created_entities_tag", R"( - + @@ -3489,7 +3491,7 @@ TEST_F(XMLProfileParserBasicTests, domainparticipantfactory) "entity_factory_duplicated_autoenable_created_entities_and_wrong_tag", R"( - + @@ -3510,7 +3512,7 @@ TEST_F(XMLProfileParserBasicTests, domainparticipantfactory) "entity_factory_duplicated", R"( - + @@ -3545,7 +3547,7 @@ TEST_F(XMLProfileParserBasicTests, domainparticipantfactory) "shm_watchdog_thread_duplicated", R"( - + @@ -3583,7 +3585,7 @@ TEST_F(XMLProfileParserBasicTests, domainparticipantfactory) "file_watch_threads_duplicated", R"( - + @@ -3677,7 +3679,7 @@ TEST_F(XMLProfileParserBasicTests, participant_thread_settings) "builtin_controllers_sender_thread_ok", R"( - + @@ -3704,7 +3706,7 @@ TEST_F(XMLProfileParserBasicTests, participant_thread_settings) "builtin_controllers_sender_thread_nok", R"( - + @@ -3731,7 +3733,7 @@ TEST_F(XMLProfileParserBasicTests, participant_thread_settings) "timed_events_thread_ok", R"( - + @@ -3758,7 +3760,7 @@ TEST_F(XMLProfileParserBasicTests, participant_thread_settings) "timed_events_thread_nok", R"( - + @@ -3785,7 +3787,7 @@ TEST_F(XMLProfileParserBasicTests, participant_thread_settings) "discovery_server_thread_ok", R"( - + @@ -3812,7 +3814,7 @@ TEST_F(XMLProfileParserBasicTests, participant_thread_settings) "discovery_server_thread_nok", R"( - + @@ -3839,7 +3841,7 @@ TEST_F(XMLProfileParserBasicTests, participant_thread_settings) "builtin_transports_reception_threads_ok", R"( - + @@ -3866,7 +3868,7 @@ TEST_F(XMLProfileParserBasicTests, participant_thread_settings) "builtin_transports_reception_threads_nok", R"( - + @@ -3894,7 +3896,7 @@ TEST_F(XMLProfileParserBasicTests, participant_thread_settings) "security_log_thread_ok", R"( - + @@ -3919,7 +3921,7 @@ TEST_F(XMLProfileParserBasicTests, participant_thread_settings) "security_log_thread_nok", R"( - + @@ -4000,7 +4002,7 @@ TEST_F(XMLProfileParserBasicTests, datareader_thread_settings) "data_sharing_listener_thread_ok", R"( - + @@ -4024,7 +4026,7 @@ TEST_F(XMLProfileParserBasicTests, datareader_thread_settings) "data_sharing_listener_thread_empty", R"( - + @@ -4044,7 +4046,7 @@ TEST_F(XMLProfileParserBasicTests, datareader_thread_settings) "no_data_sharing_listener_thread", R"( - + @@ -4062,7 +4064,7 @@ TEST_F(XMLProfileParserBasicTests, datareader_thread_settings) "data_sharing_listener_thread_wrong_value", R"( - + @@ -4086,7 +4088,7 @@ TEST_F(XMLProfileParserBasicTests, datareader_thread_settings) "data_sharing_listener_thread_wrong_tag", R"( - + diff --git a/test/unittest/xmlparser/XMLTreeTests.cpp b/test/unittest/xmlparser/XMLTreeTests.cpp index 035e7fa4e24..2bdcd23f13a 100644 --- a/test/unittest/xmlparser/XMLTreeTests.cpp +++ b/test/unittest/xmlparser/XMLTreeTests.cpp @@ -1,7 +1,21 @@ -#include +// Copyright 2020 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +#include -#include #include +#include #include diff --git a/test/unittest/xmlparser/log_def_file_profile.xml b/test/unittest/xmlparser/log_def_file_profile.xml index 38b052a081c..75d4e306f48 100644 --- a/test/unittest/xmlparser/log_def_file_profile.xml +++ b/test/unittest/xmlparser/log_def_file_profile.xml @@ -1,5 +1,5 @@ - + TRUE diff --git a/test/unittest/xmlparser/log_inactive_profile.xml b/test/unittest/xmlparser/log_inactive_profile.xml index 2039beb7893..c0ec35418f7 100644 --- a/test/unittest/xmlparser/log_inactive_profile.xml +++ b/test/unittest/xmlparser/log_inactive_profile.xml @@ -1,5 +1,5 @@ - + FALSE diff --git a/test/unittest/xmlparser/log_node_file_append_profile.xml b/test/unittest/xmlparser/log_node_file_append_profile.xml index 635690b99fc..abab527ad4a 100644 --- a/test/unittest/xmlparser/log_node_file_append_profile.xml +++ b/test/unittest/xmlparser/log_node_file_append_profile.xml @@ -1,5 +1,5 @@ - + FALSE diff --git a/test/unittest/xmlparser/log_stdouterr_profile.xml b/test/unittest/xmlparser/log_stdouterr_profile.xml index 7faf82121d2..e9df184dd96 100644 --- a/test/unittest/xmlparser/log_stdouterr_profile.xml +++ b/test/unittest/xmlparser/log_stdouterr_profile.xml @@ -1,5 +1,5 @@ - + FALSE diff --git a/test/unittest/xmlparser/log_stdouterr_two_thresholds_profile.xml b/test/unittest/xmlparser/log_stdouterr_two_thresholds_profile.xml index d543dd93d21..bc19a1a9b81 100644 --- a/test/unittest/xmlparser/log_stdouterr_two_thresholds_profile.xml +++ b/test/unittest/xmlparser/log_stdouterr_two_thresholds_profile.xml @@ -1,5 +1,5 @@ - + FALSE diff --git a/test/unittest/xmlparser/log_stdouterr_wrong_property_name_profile_invalid.xml b/test/unittest/xmlparser/log_stdouterr_wrong_property_name_profile_invalid.xml index dd0d194e9ff..86f63abb28a 100644 --- a/test/unittest/xmlparser/log_stdouterr_wrong_property_name_profile_invalid.xml +++ b/test/unittest/xmlparser/log_stdouterr_wrong_property_name_profile_invalid.xml @@ -1,5 +1,5 @@ - + FALSE diff --git a/test/unittest/xmlparser/log_stdouterr_wrong_property_value_profile_invalid.xml b/test/unittest/xmlparser/log_stdouterr_wrong_property_value_profile_invalid.xml index e6ae3b47e5e..a12f037253c 100644 --- a/test/unittest/xmlparser/log_stdouterr_wrong_property_value_profile_invalid.xml +++ b/test/unittest/xmlparser/log_stdouterr_wrong_property_value_profile_invalid.xml @@ -1,5 +1,5 @@ - + FALSE diff --git a/test/unittest/xmlparser/regressions/simple_participant_profiles_nok.xml b/test/unittest/xmlparser/regressions/simple_participant_profiles_nok.xml index 6c8f945c202..87a11151c4b 100644 --- a/test/unittest/xmlparser/regressions/simple_participant_profiles_nok.xml +++ b/test/unittest/xmlparser/regressions/simple_participant_profiles_nok.xml @@ -1,5 +1,5 @@ - + 1 diff --git a/test/unittest/xmlparser/regressions/simple_participant_profiles_ok.xml b/test/unittest/xmlparser/regressions/simple_participant_profiles_ok.xml index ef1729dde01..660706c1f02 100644 --- a/test/unittest/xmlparser/regressions/simple_participant_profiles_ok.xml +++ b/test/unittest/xmlparser/regressions/simple_participant_profiles_ok.xml @@ -1,5 +1,5 @@ - + diff --git a/test/unittest/xmlparser/test_xml_deprecated.xml b/test/unittest/xmlparser/test_xml_deprecated.xml index 99ead8f8282..baa203da3df 100644 --- a/test/unittest/xmlparser/test_xml_deprecated.xml +++ b/test/unittest/xmlparser/test_xml_deprecated.xml @@ -1,5 +1,5 @@ - + 2019102 @@ -127,10 +127,6 @@ 1000 2000 55 - - true - true - 12 @@ -169,6 +165,12 @@ 12 12 + + 12 + 12 + 12 + 12 + 12 12 diff --git a/test/unittest/xmlparser/test_xml_duration_profile.xml b/test/unittest/xmlparser/test_xml_duration_profile.xml index 8829d39f714..e9cafefa7ff 100644 --- a/test/unittest/xmlparser/test_xml_duration_profile.xml +++ b/test/unittest/xmlparser/test_xml_duration_profile.xml @@ -1,5 +1,5 @@ - + 80 diff --git a/test/unittest/xmlparser/test_xml_profile.xml b/test/unittest/xmlparser/test_xml_profile.xml index fa9207f9c52..f75239b65db 100644 --- a/test/unittest/xmlparser/test_xml_profile.xml +++ b/test/unittest/xmlparser/test_xml_profile.xml @@ -1,5 +1,5 @@ - + @@ -146,10 +146,6 @@ 1000 2000 55 - - true - true - 12 @@ -185,6 +181,12 @@ 12 12 + + 12 + 12 + 12 + 12 + 12 12 @@ -434,6 +436,48 @@ 1001 + + request_topic_name + reply_topic_name + + + + MANUAL_BY_TOPIC + + + + + + + MANUAL_BY_TOPIC + + + + + + request_topic_name + reply_topic_name + + + + MANUAL_BY_TOPIC + + + + + + + MANUAL_BY_TOPIC + + + + FULL diff --git a/test/unittest/xmlparser/test_xml_profile_env_var.xml b/test/unittest/xmlparser/test_xml_profile_env_var.xml index 63a4deb22b7..57428c1151a 100644 --- a/test/unittest/xmlparser/test_xml_profile_env_var.xml +++ b/test/unittest/xmlparser/test_xml_profile_env_var.xml @@ -1,5 +1,5 @@ - + ${XML_PROFILES_ENV_VAR_1} @@ -127,10 +127,6 @@ ${XML_PROFILES_ENV_VAR_51} ${XML_PROFILES_ENV_VAR_52} ${XML_PROFILES_ENV_VAR_53} - - ${XML_PROFILES_ENV_VAR_54} - ${XML_PROFILES_ENV_VAR_55} - ${XML_PROFILES_ENV_VAR_56} @@ -166,6 +162,12 @@ ${XML_PROFILES_ENV_VAR_160} ${XML_PROFILES_ENV_VAR_161} + + ${XML_PROFILES_ENV_VAR_158} + ${XML_PROFILES_ENV_VAR_159} + ${XML_PROFILES_ENV_VAR_160} + ${XML_PROFILES_ENV_VAR_161} + ${XML_PROFILES_ENV_VAR_158} ${XML_PROFILES_ENV_VAR_159} diff --git a/test/unittest/xmlparser/test_xml_root_library_settings_profile.xml b/test/unittest/xmlparser/test_xml_root_library_settings_profile.xml index 38b4b0f3d78..6edb9e2d25b 100644 --- a/test/unittest/xmlparser/test_xml_root_library_settings_profile.xml +++ b/test/unittest/xmlparser/test_xml_root_library_settings_profile.xml @@ -1,5 +1,5 @@ - + USER_DATA_ONLY diff --git a/test/unittest/xmlparser/test_xml_rooted_deprecated.xml b/test/unittest/xmlparser/test_xml_rooted_deprecated.xml index 79d773dfba8..3a5939c3cf8 100644 --- a/test/unittest/xmlparser/test_xml_rooted_deprecated.xml +++ b/test/unittest/xmlparser/test_xml_rooted_deprecated.xml @@ -1,5 +1,5 @@ - + @@ -105,10 +105,6 @@ - - true - true - 12 @@ -144,6 +140,12 @@ 12 12 + + 12 + 12 + 12 + 12 + 12 12 diff --git a/test/unittest/xmlparser/test_xml_rooted_profile.xml b/test/unittest/xmlparser/test_xml_rooted_profile.xml index b6e95e1751e..d02b379f79a 100644 --- a/test/unittest/xmlparser/test_xml_rooted_profile.xml +++ b/test/unittest/xmlparser/test_xml_rooted_profile.xml @@ -1,5 +1,5 @@ - + @@ -124,10 +124,6 @@ - - true - true - 12 @@ -159,6 +155,12 @@ 12 12 + + 12 + 12 + 12 + 12 + 12 12 diff --git a/test/unittest/xmlparser/test_xml_security_profile.xml b/test/unittest/xmlparser/test_xml_security_profile.xml index 644b35a7da7..825f678f5cb 100644 --- a/test/unittest/xmlparser/test_xml_security_profile.xml +++ b/test/unittest/xmlparser/test_xml_security_profile.xml @@ -1,5 +1,5 @@ - + diff --git a/test/unittest/xmlparser/tls_config_profile.xml b/test/unittest/xmlparser/tls_config_profile.xml index 5944cdc4b03..e04382f07e7 100644 --- a/test/unittest/xmlparser/tls_config_profile.xml +++ b/test/unittest/xmlparser/tls_config_profile.xml @@ -1,5 +1,5 @@ - + diff --git a/test/unittest/xmlparser/wrapper/XMLParserTest.hpp b/test/unittest/xmlparser/wrapper/XMLParserTest.hpp index 3372b20b638..f6b54832a32 100644 --- a/test/unittest/xmlparser/wrapper/XMLParserTest.hpp +++ b/test/unittest/xmlparser/wrapper/XMLParserTest.hpp @@ -13,10 +13,13 @@ // limitations under the License. #include +#include #include #include -#include +#include + +using namespace eprosima::fastdds; using namespace eprosima::fastrtps; using namespace eprosima::fastrtps::rtps; @@ -147,7 +150,7 @@ class XMLParserTest : public XMLParser static XMLP_ret getXMLTransports_wrapper( tinyxml2::XMLElement* elem, - std::vector>& transports, + std::vector>& transports, uint8_t ident) { return getXMLTransports(elem, transports, ident); @@ -242,14 +245,6 @@ class XMLParserTest : public XMLParser return getXMLBuiltinAttributes(elem, builtin, ident); } - static XMLP_ret getXMLTypeLookupSettings_wrapper( - tinyxml2::XMLElement* elem, - TypeLookupSettings& settings, - uint8_t ident) - { - return getXMLTypeLookupSettings(elem, settings, ident); - } - static XMLP_ret getXMLThroughputController_wrapper( tinyxml2::XMLElement* elem, ThroughputControllerDescriptor& throughputController, @@ -412,7 +407,7 @@ class XMLParserTest : public XMLParser static XMLP_ret getXMLEnum_wrapper( tinyxml2::XMLElement* elem, - IntraprocessDeliveryType* e, + eprosima::fastdds::IntraprocessDeliveryType* e, uint8_t ident) { return getXMLEnum(elem, e, ident); diff --git a/test/unittest/xtypes/CMakeLists.txt b/test/unittest/xtypes/CMakeLists.txt deleted file mode 100644 index 3b10f04b396..00000000000 --- a/test/unittest/xtypes/CMakeLists.txt +++ /dev/null @@ -1,103 +0,0 @@ -# Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -# -# Licensed 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 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -if(WIN32) - add_definitions( - -D_WIN32_WINNT=0x0601 - -D_CRT_SECURE_NO_WARNINGS - ) -endif() - -set(XTYPES_SOURCE - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/AnnotationDescriptor.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/AnnotationParameterValue.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/BuiltinAnnotationsTypeObject.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicData.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicDataFactory.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicDataPtr.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicPubSubType.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicType.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeBuilder.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeBuilderFactory.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeBuilderPtr.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypeMember.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/DynamicTypePtr.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/MemberDescriptor.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeDescriptor.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeIdentifier.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeIdentifierTypes.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeNamesGenerator.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeObject.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeObjectFactory.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypeObjectHashId.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/dynamic-types/TypesBase.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/Log.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/OStreamConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/log/StdoutErrConsumer.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/fastdds/topic/TopicDataType.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/LocatorWithMask.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/common/Time_t.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/network/utils/netmask_filter.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/network/utils/network.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/transport/network/NetmaskFilterKind.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/transport/network/NetworkInterface.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/rtps/transport/network/NetworkInterfaceWithFilter.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/utils/IPFinder.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/utils/IPLocator.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/utils/md5.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/utils/string_convert.cpp - ${PROJECT_SOURCE_DIR}/src/cpp/utils/SystemInfo.cpp - ) - -set(XTYPES_TEST_SOURCE - XTypesTests.cpp - idl/TypesTypeObject.cxx - idl/Types.cxx - idl/Typesv1.cxx - idl/WideEnumTypeObject.cxx - idl/WideEnum.cxx - idl/WideEnumv1.cxx - ${XTYPES_SOURCE} - ) - -if(ANDROID) - if (ANDROID_NATIVE_API_LEVEL LESS 24) - list(APPEND XTYPES_TEST_SOURCE - ${ANDROID_IFADDRS_SOURCE_DIR}/ifaddrs.c - ) - endif() -endif() - -include_directories(mock/) - -add_executable(XTypesTests ${XTYPES_TEST_SOURCE}) -target_compile_definitions(XTypesTests PRIVATE - BOOST_ASIO_STANDALONE - ASIO_STANDALONE - $<$>,$>:__DEBUG> - $<$:__INTERNALDEBUG> # Internal debug activated. - ) -target_include_directories(XTypesTests PRIVATE - ${Asio_INCLUDE_DIR} - ${PROJECT_SOURCE_DIR}/include ${PROJECT_BINARY_DIR}/include - ${PROJECT_SOURCE_DIR}/src/cpp - ) -target_link_libraries(XTypesTests GTest::gtest ${MOCKS}) -if(MSVC OR MSVC_IDE) - target_link_libraries(XTypesTests ${PRIVACY} fastcdr iphlpapi Shlwapi ws2_32) -else() - target_link_libraries(XTypesTests ${PRIVACY} fastcdr) -endif() -gtest_discover_tests(XTypesTests) diff --git a/test/unittest/xtypes/XTypesTests.cpp b/test/unittest/xtypes/XTypesTests.cpp deleted file mode 100644 index d32886e3322..00000000000 --- a/test/unittest/xtypes/XTypesTests.cpp +++ /dev/null @@ -1,844 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -#include -#include -#include -#include "idl/TypesTypeObject.h" -#include "idl/WideEnumTypeObject.h" -#include -#include -#include - -using namespace eprosima::fastrtps; -using namespace eprosima::fastrtps::types; - -class XTypesTests : public ::testing::Test -{ -public: - - XTypesTests() - { - //registerTypesTypes(); - } - - ~XTypesTests() - { - TypeObjectFactory::delete_instance(); - eprosima::fastdds::dds::Log::KillThread(); - } - - virtual void TearDown() - { - } - -}; - -TEST_F(XTypesTests, EnumMinimalCoercion) -{ - // Get Struct TypeObjects (always test struct to test the aliases and types hierarchy) - TypeConsistencyEnforcementQosPolicy consistencyQos; - const TypeObject* my_enum = GetMinimalMyEnumStructObject(); - const TypeObject* my_bad_enum = GetMinimalMyBadEnumStructObject(); - const TypeObject* my_wide_enum = GetMinimalMyEnumWideStructObject(); - - // Configure the TypeConsistencyEnforcementQos - consistencyQos.m_force_type_validation = true; - consistencyQos.m_ignore_member_names = true; - consistencyQos.m_ignore_sequence_bounds = true; - consistencyQos.m_ignore_string_bounds = true; - consistencyQos.m_prevent_type_widening = false; - consistencyQos.m_kind = ALLOW_TYPE_COERCION; - - // Check results - ASSERT_TRUE(my_enum->consistent(*my_enum, consistencyQos)); - ASSERT_TRUE(my_enum->consistent(*my_bad_enum, consistencyQos)); - ASSERT_TRUE(my_enum->consistent(*my_wide_enum, consistencyQos)); - ASSERT_TRUE(my_wide_enum->consistent(*my_enum, consistencyQos)); - - // Now don't ignore names - consistencyQos.m_ignore_member_names = false; - ASSERT_FALSE(my_enum->consistent(*my_bad_enum, consistencyQos)); - ASSERT_FALSE(my_enum->consistent(*my_wide_enum, consistencyQos)); - ASSERT_FALSE(my_wide_enum->consistent(*my_enum, consistencyQos)); - - // Now don't allow type widening - consistencyQos.m_ignore_member_names = true; - consistencyQos.m_prevent_type_widening = true; - ASSERT_TRUE(my_enum->consistent(*my_wide_enum, consistencyQos)); - ASSERT_FALSE(my_wide_enum->consistent(*my_enum, consistencyQos)); -} - -TEST_F(XTypesTests, EnumCompleteCoercion) -{ - // Get Struct TypeObjects (always test struct to test the aliases and types hierarchy) - TypeConsistencyEnforcementQosPolicy consistencyQos; - const TypeObject* my_enum = GetCompleteMyEnumStructObject(); - const TypeObject* my_bad_enum = GetCompleteMyBadEnumStructObject(); - const TypeObject* my_wide_enum = GetCompleteMyEnumWideStructObject(); - - // Configure the TypeConsistencyEnforcementQos - consistencyQos.m_force_type_validation = true; - consistencyQos.m_ignore_member_names = true; - consistencyQos.m_ignore_sequence_bounds = true; - consistencyQos.m_ignore_string_bounds = true; - consistencyQos.m_prevent_type_widening = false; - consistencyQos.m_kind = ALLOW_TYPE_COERCION; - - // Check results - ASSERT_TRUE(my_enum->consistent(*my_enum, consistencyQos)); - ASSERT_TRUE(my_enum->consistent(*my_bad_enum, consistencyQos)); - ASSERT_TRUE(my_enum->consistent(*my_wide_enum, consistencyQos)); - ASSERT_TRUE(my_wide_enum->consistent(*my_enum, consistencyQos)); - - // Now don't ignore names - consistencyQos.m_ignore_member_names = false; - ASSERT_FALSE(my_enum->consistent(*my_bad_enum, consistencyQos)); - ASSERT_FALSE(my_enum->consistent(*my_wide_enum, consistencyQos)); - ASSERT_FALSE(my_wide_enum->consistent(*my_enum, consistencyQos)); - - // Now don't allow type widening - consistencyQos.m_ignore_member_names = true; - consistencyQos.m_prevent_type_widening = true; - ASSERT_TRUE(my_enum->consistent(*my_wide_enum, consistencyQos)); - ASSERT_FALSE(my_wide_enum->consistent(*my_enum, consistencyQos)); -} - -TEST_F(XTypesTests, AliasMinimalCoercion) -{ - // Get Struct TypeObjects (always test struct to test the aliases and types hierarchy) - TypeConsistencyEnforcementQosPolicy consistencyQos; - const TypeObject* my_enum = GetMinimalMyEnumStructObject(); - const TypeObject* my_alias_enum = GetMinimalMyAliasEnumStructObject(); - - // Configure the TypeConsistencyEnforcementQos - consistencyQos.m_force_type_validation = true; - consistencyQos.m_ignore_member_names = true; - consistencyQos.m_ignore_sequence_bounds = true; - consistencyQos.m_ignore_string_bounds = true; - consistencyQos.m_prevent_type_widening = false; - consistencyQos.m_kind = ALLOW_TYPE_COERCION; - - // Check results - ASSERT_TRUE(my_enum->consistent(*my_alias_enum, consistencyQos)); - ASSERT_TRUE(my_alias_enum->consistent(*my_enum, consistencyQos)); - - // Don't ignoring member names - consistencyQos.m_ignore_member_names = false; - ASSERT_TRUE(my_enum->consistent(*my_alias_enum, consistencyQos)); - ASSERT_TRUE(my_alias_enum->consistent(*my_enum, consistencyQos)); -} - -TEST_F(XTypesTests, AliasCompleteCoercion) -{ - // Get Struct TypeObjects (always test struct to test the aliases and types hierarchy) - TypeConsistencyEnforcementQosPolicy consistencyQos; - const TypeObject* my_enum = GetCompleteMyEnumStructObject(); - const TypeObject* my_alias_enum = GetCompleteMyAliasEnumStructObject(); - - // Configure the TypeConsistencyEnforcementQos - consistencyQos.m_force_type_validation = true; - consistencyQos.m_ignore_member_names = true; - consistencyQos.m_ignore_sequence_bounds = true; - consistencyQos.m_ignore_string_bounds = true; - consistencyQos.m_prevent_type_widening = false; - consistencyQos.m_kind = ALLOW_TYPE_COERCION; - - // Check results - ASSERT_TRUE(my_enum->consistent(*my_alias_enum, consistencyQos)); - ASSERT_TRUE(my_alias_enum->consistent(*my_enum, consistencyQos)); - - // Don't ignoring member names - consistencyQos.m_ignore_member_names = false; - ASSERT_TRUE(my_enum->consistent(*my_alias_enum, consistencyQos)); - ASSERT_TRUE(my_alias_enum->consistent(*my_enum, consistencyQos)); -} - -TEST_F(XTypesTests, BasicStructMinimalCoercion) -{ - // Get Struct TypeObjects (always test struct to test the aliases and types hierarchy) - TypeConsistencyEnforcementQosPolicy consistencyQos; - const TypeObject* basic_struct = GetMinimalBasicStructObject(); - const TypeObject* basic_names_struct = GetMinimalBasicNamesStructObject(); - const TypeObject* basic_bad_struct = GetMinimalBasicBadStructObject(); - const TypeObject* basic_wide_struct = GetMinimalBasicWideStructObject(); - const TypeObject* basic_wide_bad_struct = GetMinimalBadBasicWideStructObject(); - - // Configure the TypeConsistencyEnforcementQos - consistencyQos.m_force_type_validation = true; - consistencyQos.m_ignore_member_names = true; - consistencyQos.m_ignore_sequence_bounds = true; - consistencyQos.m_ignore_string_bounds = true; - consistencyQos.m_prevent_type_widening = false; - consistencyQos.m_kind = ALLOW_TYPE_COERCION; - - // Check results - ASSERT_TRUE(basic_struct->consistent(*basic_names_struct, consistencyQos)); - ASSERT_FALSE(basic_struct->consistent(*basic_bad_struct, consistencyQos)); - ASSERT_TRUE(basic_struct->consistent(*basic_wide_struct, consistencyQos)); - ASSERT_TRUE(basic_wide_struct->consistent(*basic_struct, consistencyQos)); - ASSERT_FALSE(basic_struct->consistent(*basic_wide_bad_struct, consistencyQos)); - ASSERT_FALSE(basic_wide_bad_struct->consistent(*basic_struct, consistencyQos)); - - // Don't ignoring member names - consistencyQos.m_ignore_member_names = false; - ASSERT_FALSE(basic_struct->consistent(*basic_names_struct, consistencyQos)); - ASSERT_TRUE(basic_struct->consistent(*basic_wide_struct, consistencyQos)); - ASSERT_TRUE(basic_wide_struct->consistent(*basic_struct, consistencyQos)); - - // Don't allow type widening - consistencyQos.m_ignore_member_names = true; - consistencyQos.m_prevent_type_widening = true; - ASSERT_TRUE(basic_struct->consistent(*basic_wide_struct, consistencyQos)); - ASSERT_FALSE(basic_wide_struct->consistent(*basic_struct, consistencyQos)); - ASSERT_FALSE(basic_struct->consistent(*basic_wide_bad_struct, consistencyQos)); - ASSERT_FALSE(basic_wide_bad_struct->consistent(*basic_struct, consistencyQos)); - - // DISALLOW coercion - consistencyQos.m_kind = DISALLOW_TYPE_COERCION; - ASSERT_FALSE(basic_struct->consistent(*basic_wide_struct, consistencyQos)); - ASSERT_FALSE(basic_wide_struct->consistent(*basic_struct, consistencyQos)); -} - -TEST_F(XTypesTests, BasicStructCompleteCoercion) -{ - // Get Struct TypeObjects (always test struct to test the aliases and types hierarchy) - TypeConsistencyEnforcementQosPolicy consistencyQos; - const TypeObject* basic_struct = GetCompleteBasicStructObject(); - const TypeObject* basic_names_struct = GetCompleteBasicNamesStructObject(); - const TypeObject* basic_bad_struct = GetCompleteBasicBadStructObject(); - const TypeObject* basic_wide_struct = GetCompleteBasicWideStructObject(); - const TypeObject* basic_wide_bad_struct = GetCompleteBadBasicWideStructObject(); - - // Configure the TypeConsistencyEnforcementQos - consistencyQos.m_force_type_validation = true; - consistencyQos.m_ignore_member_names = true; - consistencyQos.m_ignore_sequence_bounds = true; - consistencyQos.m_ignore_string_bounds = true; - consistencyQos.m_prevent_type_widening = false; - consistencyQos.m_kind = ALLOW_TYPE_COERCION; - - // Check results - ASSERT_TRUE(basic_struct->consistent(*basic_names_struct, consistencyQos)); - ASSERT_FALSE(basic_struct->consistent(*basic_bad_struct, consistencyQos)); - ASSERT_TRUE(basic_struct->consistent(*basic_wide_struct, consistencyQos)); - ASSERT_TRUE(basic_wide_struct->consistent(*basic_struct, consistencyQos)); - ASSERT_FALSE(basic_struct->consistent(*basic_wide_bad_struct, consistencyQos)); - ASSERT_FALSE(basic_wide_bad_struct->consistent(*basic_struct, consistencyQos)); - - // Don't ignoring member names - consistencyQos.m_ignore_member_names = false; - ASSERT_FALSE(basic_struct->consistent(*basic_names_struct, consistencyQos)); - ASSERT_TRUE(basic_struct->consistent(*basic_wide_struct, consistencyQos)); - ASSERT_TRUE(basic_wide_struct->consistent(*basic_struct, consistencyQos)); - - // Don't allow type widening - consistencyQos.m_ignore_member_names = true; - consistencyQos.m_prevent_type_widening = true; - ASSERT_TRUE(basic_struct->consistent(*basic_wide_struct, consistencyQos)); - ASSERT_FALSE(basic_wide_struct->consistent(*basic_struct, consistencyQos)); - ASSERT_FALSE(basic_struct->consistent(*basic_wide_bad_struct, consistencyQos)); - ASSERT_FALSE(basic_wide_bad_struct->consistent(*basic_struct, consistencyQos)); - - // DISALLOW coercion - consistencyQos.m_kind = DISALLOW_TYPE_COERCION; - ASSERT_FALSE(basic_struct->consistent(*basic_wide_struct, consistencyQos)); - ASSERT_FALSE(basic_wide_struct->consistent(*basic_struct, consistencyQos)); -} - -TEST_F(XTypesTests, StringMinimalCoercion) -{ - // Get Struct TypeObjects (always test struct to test the aliases and types hierarchy) - TypeConsistencyEnforcementQosPolicy consistencyQos; - const TypeObject* my_string = GetMinimalStringStructObject(); - const TypeObject* my_lstring = GetMinimalLargeStringStructObject(); - const TypeObject* my_wstring = GetMinimalWStringStructObject(); - const TypeObject* my_lwstring = GetMinimalLargeWStringStructObject(); - - // Configure the TypeConsistencyEnforcementQos - consistencyQos.m_force_type_validation = true; - consistencyQos.m_ignore_member_names = true; - consistencyQos.m_ignore_sequence_bounds = true; - consistencyQos.m_ignore_string_bounds = true; - consistencyQos.m_prevent_type_widening = false; - consistencyQos.m_kind = ALLOW_TYPE_COERCION; - - // Check results - ASSERT_TRUE(my_string->consistent(*my_lstring, consistencyQos)); - ASSERT_TRUE(my_lstring->consistent(*my_string, consistencyQos)); - ASSERT_TRUE(my_wstring->consistent(*my_lwstring, consistencyQos)); - ASSERT_TRUE(my_lwstring->consistent(*my_wstring, consistencyQos)); - ASSERT_FALSE(my_string->consistent(*my_wstring, consistencyQos)); - ASSERT_FALSE(my_wstring->consistent(*my_string, consistencyQos)); - ASSERT_FALSE(my_lstring->consistent(*my_lwstring, consistencyQos)); - ASSERT_FALSE(my_lwstring->consistent(*my_lstring, consistencyQos)); - - // Don't ignoring member names - consistencyQos.m_ignore_member_names = false; - ASSERT_FALSE(my_string->consistent(*my_lstring, consistencyQos)); - ASSERT_FALSE(my_lstring->consistent(*my_string, consistencyQos)); - ASSERT_FALSE(my_wstring->consistent(*my_lwstring, consistencyQos)); - ASSERT_FALSE(my_lwstring->consistent(*my_wstring, consistencyQos)); - - // Don't ignoring string bounds - consistencyQos.m_ignore_member_names = true; - consistencyQos.m_ignore_string_bounds = false; - ASSERT_FALSE(my_string->consistent(*my_lstring, consistencyQos)); - ASSERT_TRUE(my_lstring->consistent(*my_string, consistencyQos)); - ASSERT_FALSE(my_wstring->consistent(*my_lwstring, consistencyQos)); - ASSERT_TRUE(my_lwstring->consistent(*my_wstring, consistencyQos)); -} - -TEST_F(XTypesTests, StringCompleteCoercion) -{ - // Get Struct TypeObjects (always test struct to test the aliases and types hierarchy) - TypeConsistencyEnforcementQosPolicy consistencyQos; - const TypeObject* my_string = GetCompleteStringStructObject(); - const TypeObject* my_lstring = GetCompleteLargeStringStructObject(); - const TypeObject* my_wstring = GetCompleteWStringStructObject(); - const TypeObject* my_lwstring = GetCompleteLargeWStringStructObject(); - - // Configure the TypeConsistencyEnforcementQos - consistencyQos.m_force_type_validation = true; - consistencyQos.m_ignore_member_names = true; - consistencyQos.m_ignore_sequence_bounds = true; - consistencyQos.m_ignore_string_bounds = true; - consistencyQos.m_prevent_type_widening = false; - consistencyQos.m_kind = ALLOW_TYPE_COERCION; - - // Check results - ASSERT_TRUE(my_string->consistent(*my_lstring, consistencyQos)); - ASSERT_TRUE(my_lstring->consistent(*my_string, consistencyQos)); - ASSERT_TRUE(my_wstring->consistent(*my_lwstring, consistencyQos)); - ASSERT_TRUE(my_lwstring->consistent(*my_wstring, consistencyQos)); - ASSERT_FALSE(my_string->consistent(*my_wstring, consistencyQos)); - ASSERT_FALSE(my_wstring->consistent(*my_string, consistencyQos)); - ASSERT_FALSE(my_lstring->consistent(*my_lwstring, consistencyQos)); - ASSERT_FALSE(my_lwstring->consistent(*my_lstring, consistencyQos)); - - // Don't ignoring member names - consistencyQos.m_ignore_member_names = false; - ASSERT_FALSE(my_string->consistent(*my_lstring, consistencyQos)); - ASSERT_FALSE(my_lstring->consistent(*my_string, consistencyQos)); - ASSERT_FALSE(my_wstring->consistent(*my_lwstring, consistencyQos)); - ASSERT_FALSE(my_lwstring->consistent(*my_wstring, consistencyQos)); - - // Don't ignoring string bounds - consistencyQos.m_ignore_member_names = true; - consistencyQos.m_ignore_string_bounds = false; - ASSERT_FALSE(my_string->consistent(*my_lstring, consistencyQos)); - ASSERT_TRUE(my_lstring->consistent(*my_string, consistencyQos)); - ASSERT_FALSE(my_wstring->consistent(*my_lwstring, consistencyQos)); - ASSERT_TRUE(my_lwstring->consistent(*my_wstring, consistencyQos)); -} - -TEST_F(XTypesTests, ArrayMinimalCoercion) -{ - // Get Struct TypeObjects (always test struct to test the aliases and types hierarchy) - TypeConsistencyEnforcementQosPolicy consistencyQos; - const TypeObject* my_array = GetMinimalArrayStructObject(); - const TypeObject* my_array_equal = GetMinimalArrayStructEqualObject(); - const TypeObject* my_array_bad = GetMinimalArrayBadStructObject(); - const TypeObject* my_array_dims = GetMinimalArrayDimensionsStructObject(); - const TypeObject* my_array_size = GetMinimalArraySizeStructObject(); - - // Configure the TypeConsistencyEnforcementQos - consistencyQos.m_force_type_validation = true; - consistencyQos.m_ignore_member_names = true; - consistencyQos.m_ignore_sequence_bounds = true; - consistencyQos.m_ignore_string_bounds = true; - consistencyQos.m_prevent_type_widening = false; - consistencyQos.m_kind = ALLOW_TYPE_COERCION; - - // Check results - ASSERT_TRUE(my_array->consistent(*my_array_equal, consistencyQos)); - ASSERT_FALSE(my_array->consistent(*my_array_bad, consistencyQos)); - ASSERT_FALSE(my_array->consistent(*my_array_dims, consistencyQos)); - ASSERT_FALSE(my_array->consistent(*my_array_size, consistencyQos)); - ASSERT_TRUE(my_array_equal->consistent(*my_array, consistencyQos)); - ASSERT_FALSE(my_array_bad->consistent(*my_array, consistencyQos)); - ASSERT_FALSE(my_array_dims->consistent(*my_array, consistencyQos)); - ASSERT_FALSE(my_array_size->consistent(*my_array, consistencyQos)); - - // Don't ignoring member names - consistencyQos.m_ignore_member_names = false; - ASSERT_FALSE(my_array->consistent(*my_array_equal, consistencyQos)); -} - -TEST_F(XTypesTests, ArrayCompleteCoercion) -{ - // Get Struct TypeObjects (always test struct to test the aliases and types hierarchy) - TypeConsistencyEnforcementQosPolicy consistencyQos; - const TypeObject* my_array = GetCompleteArrayStructObject(); - const TypeObject* my_array_equal = GetCompleteArrayStructEqualObject(); - const TypeObject* my_array_bad = GetCompleteArrayBadStructObject(); - const TypeObject* my_array_dims = GetCompleteArrayDimensionsStructObject(); - const TypeObject* my_array_size = GetCompleteArraySizeStructObject(); - - // Configure the TypeConsistencyEnforcementQos - consistencyQos.m_force_type_validation = true; - consistencyQos.m_ignore_member_names = true; - consistencyQos.m_ignore_sequence_bounds = true; - consistencyQos.m_ignore_string_bounds = true; - consistencyQos.m_prevent_type_widening = false; - consistencyQos.m_kind = ALLOW_TYPE_COERCION; - - // Check results - ASSERT_TRUE(my_array->consistent(*my_array_equal, consistencyQos)); - ASSERT_FALSE(my_array->consistent(*my_array_bad, consistencyQos)); - ASSERT_FALSE(my_array->consistent(*my_array_dims, consistencyQos)); - ASSERT_FALSE(my_array->consistent(*my_array_size, consistencyQos)); - ASSERT_TRUE(my_array_equal->consistent(*my_array, consistencyQos)); - ASSERT_FALSE(my_array_bad->consistent(*my_array, consistencyQos)); - ASSERT_FALSE(my_array_dims->consistent(*my_array, consistencyQos)); - ASSERT_FALSE(my_array_size->consistent(*my_array, consistencyQos)); - - // Don't ignoring member names - consistencyQos.m_ignore_member_names = false; - ASSERT_FALSE(my_array->consistent(*my_array_equal, consistencyQos)); -} - -TEST_F(XTypesTests, SequenceMinimalCoercion) -{ - // Get Struct TypeObjects (always test struct to test the aliases and types hierarchy) - TypeConsistencyEnforcementQosPolicy consistencyQos; - const TypeObject* my_sequence = GetMinimalSequenceStructObject(); - const TypeObject* my_sequence_equal = GetMinimalSequenceStructEqualObject(); - const TypeObject* my_sequence_bad = GetMinimalSequenceBadStructObject(); - const TypeObject* my_sequence_bound = GetMinimalSequenceBoundsStructObject(); - const TypeObject* my_sequence_sequence = GetMinimalSequenceSequenceStructObject(); - const TypeObject* my_sequence_sequence_bound = GetMinimalSequenceSequenceBoundsStructObject(); - - // Configure the TypeConsistencyEnforcementQos - consistencyQos.m_force_type_validation = true; - consistencyQos.m_ignore_member_names = true; - consistencyQos.m_ignore_sequence_bounds = true; - consistencyQos.m_ignore_string_bounds = true; - consistencyQos.m_prevent_type_widening = false; - consistencyQos.m_kind = ALLOW_TYPE_COERCION; - - // Check results - ASSERT_TRUE(my_sequence->consistent(*my_sequence_equal, consistencyQos)); - ASSERT_FALSE(my_sequence->consistent(*my_sequence_bad, consistencyQos)); - ASSERT_TRUE(my_sequence->consistent(*my_sequence_bound, consistencyQos)); - ASSERT_TRUE(my_sequence_equal->consistent(*my_sequence, consistencyQos)); - ASSERT_FALSE(my_sequence_bad->consistent(*my_sequence, consistencyQos)); - ASSERT_TRUE(my_sequence_bound->consistent(*my_sequence, consistencyQos)); - - ASSERT_TRUE(my_sequence_sequence->consistent(*my_sequence_sequence_bound, consistencyQos)); - ASSERT_TRUE(my_sequence_sequence_bound->consistent(*my_sequence_sequence, consistencyQos)); - - // Don't ignoring member names - consistencyQos.m_ignore_member_names = false; - ASSERT_FALSE(my_sequence->consistent(*my_sequence_equal, consistencyQos)); - ASSERT_FALSE(my_sequence_equal->consistent(*my_sequence, consistencyQos)); - ASSERT_TRUE(my_sequence->consistent(*my_sequence_bound, consistencyQos)); - ASSERT_TRUE(my_sequence_bound->consistent(*my_sequence, consistencyQos)); - - ASSERT_TRUE(my_sequence_sequence->consistent(*my_sequence_sequence_bound, consistencyQos)); - ASSERT_TRUE(my_sequence_sequence_bound->consistent(*my_sequence_sequence, consistencyQos)); - - // Don't ignoring sequence bounds - consistencyQos.m_ignore_member_names = true; - consistencyQos.m_ignore_sequence_bounds = false; - ASSERT_TRUE(my_sequence->consistent(*my_sequence_equal, consistencyQos)); - ASSERT_TRUE(my_sequence_equal->consistent(*my_sequence, consistencyQos)); - ASSERT_FALSE(my_sequence->consistent(*my_sequence_bound, consistencyQos)); - ASSERT_TRUE(my_sequence_bound->consistent(*my_sequence, consistencyQos)); - - ASSERT_FALSE(my_sequence_sequence->consistent(*my_sequence_sequence_bound, consistencyQos)); - ASSERT_TRUE(my_sequence_sequence_bound->consistent(*my_sequence_sequence, consistencyQos)); -} - -TEST_F(XTypesTests, SequenceCompleteCoercion) -{ - // Get Struct TypeObjects (always test struct to test the aliases and types hierarchy) - TypeConsistencyEnforcementQosPolicy consistencyQos; - const TypeObject* my_sequence = GetCompleteSequenceStructObject(); - const TypeObject* my_sequence_equal = GetCompleteSequenceStructEqualObject(); - const TypeObject* my_sequence_bad = GetCompleteSequenceBadStructObject(); - const TypeObject* my_sequence_bound = GetCompleteSequenceBoundsStructObject(); - const TypeObject* my_sequence_sequence = GetCompleteSequenceSequenceStructObject(); - const TypeObject* my_sequence_sequence_bound = GetCompleteSequenceSequenceBoundsStructObject(); - - // Configure the TypeConsistencyEnforcementQos - consistencyQos.m_force_type_validation = true; - consistencyQos.m_ignore_member_names = true; - consistencyQos.m_ignore_sequence_bounds = true; - consistencyQos.m_ignore_string_bounds = true; - consistencyQos.m_prevent_type_widening = false; - consistencyQos.m_kind = ALLOW_TYPE_COERCION; - - // Check results - ASSERT_TRUE(my_sequence->consistent(*my_sequence_equal, consistencyQos)); - ASSERT_FALSE(my_sequence->consistent(*my_sequence_bad, consistencyQos)); - ASSERT_TRUE(my_sequence->consistent(*my_sequence_bound, consistencyQos)); - ASSERT_TRUE(my_sequence_equal->consistent(*my_sequence, consistencyQos)); - ASSERT_FALSE(my_sequence_bad->consistent(*my_sequence, consistencyQos)); - ASSERT_TRUE(my_sequence_bound->consistent(*my_sequence, consistencyQos)); - - ASSERT_TRUE(my_sequence_sequence->consistent(*my_sequence_sequence_bound, consistencyQos)); - ASSERT_TRUE(my_sequence_sequence_bound->consistent(*my_sequence_sequence, consistencyQos)); - - // Don't ignoring member names - consistencyQos.m_ignore_member_names = false; - ASSERT_FALSE(my_sequence->consistent(*my_sequence_equal, consistencyQos)); - ASSERT_FALSE(my_sequence_equal->consistent(*my_sequence, consistencyQos)); - ASSERT_TRUE(my_sequence->consistent(*my_sequence_bound, consistencyQos)); - ASSERT_TRUE(my_sequence_bound->consistent(*my_sequence, consistencyQos)); - - ASSERT_TRUE(my_sequence_sequence->consistent(*my_sequence_sequence_bound, consistencyQos)); - ASSERT_TRUE(my_sequence_sequence_bound->consistent(*my_sequence_sequence, consistencyQos)); - - // Don't ignoring sequence bounds - consistencyQos.m_ignore_member_names = true; - consistencyQos.m_ignore_sequence_bounds = false; - ASSERT_TRUE(my_sequence->consistent(*my_sequence_equal, consistencyQos)); - ASSERT_TRUE(my_sequence_equal->consistent(*my_sequence, consistencyQos)); - ASSERT_FALSE(my_sequence->consistent(*my_sequence_bound, consistencyQos)); - ASSERT_TRUE(my_sequence_bound->consistent(*my_sequence, consistencyQos)); - - ASSERT_FALSE(my_sequence_sequence->consistent(*my_sequence_sequence_bound, consistencyQos)); - ASSERT_TRUE(my_sequence_sequence_bound->consistent(*my_sequence_sequence, consistencyQos)); -} - -TEST_F(XTypesTests, MapMinimalCoercion) -{ - // Get Struct TypeObjects (always test struct to test the aliases and types hierarchy) - TypeConsistencyEnforcementQosPolicy consistencyQos; - const TypeObject* my_map = GetMinimalMapStructObject(); - const TypeObject* my_map_equal = GetMinimalMapStructEqualObject(); - const TypeObject* my_map_bad_key = GetMinimalMapBadKeyStructObject(); - const TypeObject* my_map_bad_elem = GetMinimalMapBadElemStructObject(); - const TypeObject* my_map_bound = GetMinimalMapBoundsStructObject(); - const TypeObject* my_map_map = GetMinimalMapMapStructObject(); - const TypeObject* my_map_map_bound = GetMinimalMapMapBoundsStructObject(); - - // Configure the TypeConsistencyEnforcementQos - consistencyQos.m_force_type_validation = true; - consistencyQos.m_ignore_member_names = true; - consistencyQos.m_ignore_sequence_bounds = true; - consistencyQos.m_ignore_string_bounds = true; - consistencyQos.m_prevent_type_widening = false; - consistencyQos.m_kind = ALLOW_TYPE_COERCION; - - // Check results - ASSERT_TRUE(my_map->consistent(*my_map_equal, consistencyQos)); - ASSERT_FALSE(my_map->consistent(*my_map_bad_key, consistencyQos)); - ASSERT_FALSE(my_map->consistent(*my_map_bad_elem, consistencyQos)); - ASSERT_TRUE(my_map->consistent(*my_map_bound, consistencyQos)); - - ASSERT_TRUE(my_map_equal->consistent(*my_map, consistencyQos)); - ASSERT_FALSE(my_map_bad_key->consistent(*my_map, consistencyQos)); - ASSERT_FALSE(my_map_bad_elem->consistent(*my_map, consistencyQos)); - ASSERT_TRUE(my_map_bound->consistent(*my_map, consistencyQos)); - - ASSERT_TRUE(my_map_map->consistent(*my_map_map_bound, consistencyQos)); - ASSERT_TRUE(my_map_map_bound->consistent(*my_map_map, consistencyQos)); - - // Don't ignoring member names - consistencyQos.m_ignore_member_names = false; - ASSERT_FALSE(my_map->consistent(*my_map_equal, consistencyQos)); - ASSERT_FALSE(my_map_equal->consistent(*my_map, consistencyQos)); - ASSERT_TRUE(my_map->consistent(*my_map_bound, consistencyQos)); - ASSERT_TRUE(my_map_bound->consistent(*my_map, consistencyQos)); - - ASSERT_TRUE(my_map_map->consistent(*my_map_map_bound, consistencyQos)); - ASSERT_TRUE(my_map_map_bound->consistent(*my_map_map, consistencyQos)); - - // Don't ignoring map bounds, doesn't apply on maps - consistencyQos.m_ignore_member_names = true; - consistencyQos.m_ignore_sequence_bounds = false; - ASSERT_TRUE(my_map->consistent(*my_map_equal, consistencyQos)); - ASSERT_TRUE(my_map_equal->consistent(*my_map, consistencyQos)); - ASSERT_FALSE(my_map->consistent(*my_map_bound, consistencyQos)); - ASSERT_FALSE(my_map_bound->consistent(*my_map, consistencyQos)); - - ASSERT_FALSE(my_map_map->consistent(*my_map_map_bound, consistencyQos)); - ASSERT_FALSE(my_map_map_bound->consistent(*my_map_map, consistencyQos)); -} - -TEST_F(XTypesTests, MapCompleteCoercion) -{ - // Get Struct TypeObjects (always test struct to test the aliases and types hierarchy) - TypeConsistencyEnforcementQosPolicy consistencyQos; - const TypeObject* my_map = GetCompleteMapStructObject(); - const TypeObject* my_map_equal = GetCompleteMapStructEqualObject(); - const TypeObject* my_map_bad_key = GetCompleteMapBadKeyStructObject(); - const TypeObject* my_map_bad_elem = GetCompleteMapBadElemStructObject(); - const TypeObject* my_map_bound = GetCompleteMapBoundsStructObject(); - const TypeObject* my_map_map = GetCompleteMapMapStructObject(); - const TypeObject* my_map_map_bound = GetCompleteMapMapBoundsStructObject(); - - // Configure the TypeConsistencyEnforcementQos - consistencyQos.m_force_type_validation = true; - consistencyQos.m_ignore_member_names = true; - consistencyQos.m_ignore_sequence_bounds = true; - consistencyQos.m_ignore_string_bounds = true; - consistencyQos.m_prevent_type_widening = false; - consistencyQos.m_kind = ALLOW_TYPE_COERCION; - - // Check results - ASSERT_TRUE(my_map->consistent(*my_map_equal, consistencyQos)); - ASSERT_FALSE(my_map->consistent(*my_map_bad_key, consistencyQos)); - ASSERT_FALSE(my_map->consistent(*my_map_bad_elem, consistencyQos)); - ASSERT_TRUE(my_map->consistent(*my_map_bound, consistencyQos)); - - ASSERT_TRUE(my_map_equal->consistent(*my_map, consistencyQos)); - ASSERT_FALSE(my_map_bad_key->consistent(*my_map, consistencyQos)); - ASSERT_FALSE(my_map_bad_elem->consistent(*my_map, consistencyQos)); - ASSERT_TRUE(my_map_bound->consistent(*my_map, consistencyQos)); - - ASSERT_TRUE(my_map_map->consistent(*my_map_map_bound, consistencyQos)); - ASSERT_TRUE(my_map_map_bound->consistent(*my_map_map, consistencyQos)); - - // Don't ignoring member names - consistencyQos.m_ignore_member_names = false; - ASSERT_FALSE(my_map->consistent(*my_map_equal, consistencyQos)); - ASSERT_FALSE(my_map_equal->consistent(*my_map, consistencyQos)); - ASSERT_TRUE(my_map->consistent(*my_map_bound, consistencyQos)); - ASSERT_TRUE(my_map_bound->consistent(*my_map, consistencyQos)); - - ASSERT_TRUE(my_map_map->consistent(*my_map_map_bound, consistencyQos)); - ASSERT_TRUE(my_map_map_bound->consistent(*my_map_map, consistencyQos)); - - // Don't ignoring map bounds, doesn't apply on maps - consistencyQos.m_ignore_member_names = true; - consistencyQos.m_ignore_sequence_bounds = false; - ASSERT_TRUE(my_map->consistent(*my_map_equal, consistencyQos)); - ASSERT_TRUE(my_map_equal->consistent(*my_map, consistencyQos)); - ASSERT_FALSE(my_map->consistent(*my_map_bound, consistencyQos)); - ASSERT_FALSE(my_map_bound->consistent(*my_map, consistencyQos)); - - ASSERT_FALSE(my_map_map->consistent(*my_map_map_bound, consistencyQos)); - ASSERT_FALSE(my_map_map_bound->consistent(*my_map_map, consistencyQos)); -} - -TEST_F(XTypesTests, SimpleUnionMinimalCoercion) -{ - // Get Struct TypeObjects (always test struct to test the aliases and types hierarchy) - TypeConsistencyEnforcementQosPolicy consistencyQos; - const TypeObject* basic_union = GetMinimalSimpleUnionStructObject(); - const TypeObject* basic_union_equal = GetMinimalSimpleUnionStructEqualObject(); - const TypeObject* basic_union_names = GetMinimalSimpleUnionNamesStructObject(); - const TypeObject* basic_union_type = GetMinimalSimpleTypeUnionStructObject(); - const TypeObject* basic_bad_union = GetMinimalSimpleBadUnionStructObject(); - const TypeObject* basic_bad_union_disc = GetMinimalSimplBadDiscUnionStructObject(); - const TypeObject* basic_wide_union = GetMinimalSimpleWideUnionStructObject(); - - // Configure the TypeConsistencyEnforcementQos - consistencyQos.m_force_type_validation = true; - consistencyQos.m_ignore_member_names = true; - consistencyQos.m_ignore_sequence_bounds = true; - consistencyQos.m_ignore_string_bounds = true; - consistencyQos.m_prevent_type_widening = false; - consistencyQos.m_kind = ALLOW_TYPE_COERCION; - - // Check results - ASSERT_TRUE(basic_union->consistent(*basic_union_equal, consistencyQos)); - ASSERT_TRUE(basic_union->consistent(*basic_union_names, consistencyQos)); - ASSERT_FALSE(basic_union->consistent(*basic_union_type, consistencyQos)); - ASSERT_FALSE(basic_union->consistent(*basic_bad_union, consistencyQos)); - ASSERT_FALSE(basic_union->consistent(*basic_bad_union_disc, consistencyQos)); - ASSERT_TRUE(basic_union_equal->consistent(*basic_union, consistencyQos)); - ASSERT_TRUE(basic_union_names->consistent(*basic_union, consistencyQos)); - ASSERT_FALSE(basic_union_type->consistent(*basic_union, consistencyQos)); - ASSERT_FALSE(basic_bad_union->consistent(*basic_union, consistencyQos)); - ASSERT_FALSE(basic_bad_union_disc->consistent(*basic_union, consistencyQos)); - - - ASSERT_TRUE(basic_union->consistent(*basic_wide_union, consistencyQos)); - ASSERT_TRUE(basic_wide_union->consistent(*basic_union, consistencyQos)); - - // Don't ignoring member names - consistencyQos.m_ignore_member_names = false; - ASSERT_FALSE(basic_union->consistent(*basic_union_names, consistencyQos)); - ASSERT_FALSE(basic_union->consistent(*basic_union_equal, consistencyQos)); - ASSERT_FALSE(basic_union_equal->consistent(*basic_union, consistencyQos)); - ASSERT_TRUE(basic_union->consistent(*basic_wide_union, consistencyQos)); - - // Don't allow type widening - consistencyQos.m_ignore_member_names = true; - consistencyQos.m_prevent_type_widening = true; - ASSERT_TRUE(basic_union->consistent(*basic_wide_union, consistencyQos)); - ASSERT_FALSE(basic_wide_union->consistent(*basic_union, consistencyQos)); - - // DISALLOW coercion - consistencyQos.m_kind = DISALLOW_TYPE_COERCION; - ASSERT_FALSE(basic_union->consistent(*basic_wide_union, consistencyQos)); - ASSERT_FALSE(basic_wide_union->consistent(*basic_union, consistencyQos)); -} - -TEST_F(XTypesTests, SimpleUnionCompleteCoercion) -{ - // Get Struct TypeObjects (always test struct to test the aliases and types hierarchy) - TypeConsistencyEnforcementQosPolicy consistencyQos; - const TypeObject* basic_union = GetCompleteSimpleUnionStructObject(); - const TypeObject* basic_union_equal = GetCompleteSimpleUnionStructEqualObject(); - const TypeObject* basic_union_names = GetCompleteSimpleUnionNamesStructObject(); - const TypeObject* basic_union_type = GetCompleteSimpleTypeUnionStructObject(); - const TypeObject* basic_bad_union = GetCompleteSimpleBadUnionStructObject(); - const TypeObject* basic_bad_union_disc = GetCompleteSimplBadDiscUnionStructObject(); - const TypeObject* basic_wide_union = GetCompleteSimpleWideUnionStructObject(); - - // Configure the TypeConsistencyEnforcementQos - consistencyQos.m_force_type_validation = true; - consistencyQos.m_ignore_member_names = true; - consistencyQos.m_ignore_sequence_bounds = true; - consistencyQos.m_ignore_string_bounds = true; - consistencyQos.m_prevent_type_widening = false; - consistencyQos.m_kind = ALLOW_TYPE_COERCION; - - // Check results - ASSERT_TRUE(basic_union->consistent(*basic_union_equal, consistencyQos)); - ASSERT_TRUE(basic_union->consistent(*basic_union_names, consistencyQos)); - ASSERT_FALSE(basic_union->consistent(*basic_union_type, consistencyQos)); - ASSERT_FALSE(basic_union->consistent(*basic_bad_union, consistencyQos)); - ASSERT_FALSE(basic_union->consistent(*basic_bad_union_disc, consistencyQos)); - ASSERT_TRUE(basic_union_equal->consistent(*basic_union, consistencyQos)); - ASSERT_TRUE(basic_union_names->consistent(*basic_union, consistencyQos)); - ASSERT_FALSE(basic_union_type->consistent(*basic_union, consistencyQos)); - ASSERT_FALSE(basic_bad_union->consistent(*basic_union, consistencyQos)); - ASSERT_FALSE(basic_bad_union_disc->consistent(*basic_union, consistencyQos)); - - - ASSERT_TRUE(basic_union->consistent(*basic_wide_union, consistencyQos)); - ASSERT_TRUE(basic_wide_union->consistent(*basic_union, consistencyQos)); - - // Don't ignoring member names - consistencyQos.m_ignore_member_names = false; - ASSERT_FALSE(basic_union->consistent(*basic_union_names, consistencyQos)); - ASSERT_FALSE(basic_union->consistent(*basic_union_equal, consistencyQos)); - ASSERT_FALSE(basic_union_equal->consistent(*basic_union, consistencyQos)); - ASSERT_TRUE(basic_union->consistent(*basic_wide_union, consistencyQos)); - - // Don't allow type widening - consistencyQos.m_ignore_member_names = true; - consistencyQos.m_prevent_type_widening = true; - ASSERT_TRUE(basic_union->consistent(*basic_wide_union, consistencyQos)); - ASSERT_FALSE(basic_wide_union->consistent(*basic_union, consistencyQos)); - - // DISALLOW coercion - consistencyQos.m_kind = DISALLOW_TYPE_COERCION; - ASSERT_FALSE(basic_union->consistent(*basic_wide_union, consistencyQos)); - ASSERT_FALSE(basic_wide_union->consistent(*basic_union, consistencyQos)); -} - -TEST_F(XTypesTests, TypeDescriptorFullyQualifiedName) -{ - DynamicTypeBuilder_ptr my_builder(DynamicTypeBuilderFactory::get_instance()->create_struct_builder()); - my_builder->add_member(0, "x", DynamicTypeBuilderFactory::get_instance()->create_float32_type()); - my_builder->add_member(0, "y", DynamicTypeBuilderFactory::get_instance()->create_float32_type()); - my_builder->add_member(0, "z", DynamicTypeBuilderFactory::get_instance()->create_float32_type()); - const TypeDescriptor* my_descriptor = my_builder->get_type_descriptor(); - - my_builder->set_name("Position"); - ASSERT_TRUE(my_descriptor->is_consistent()); - my_builder->set_name("Position_"); - ASSERT_TRUE(my_descriptor->is_consistent()); - my_builder->set_name("Position123"); - ASSERT_TRUE(my_descriptor->is_consistent()); - my_builder->set_name("position_123"); - ASSERT_TRUE(my_descriptor->is_consistent()); - my_builder->set_name("_Position"); - ASSERT_FALSE(my_descriptor->is_consistent()); - my_builder->set_name("123Position"); - ASSERT_FALSE(my_descriptor->is_consistent()); - my_builder->set_name("Position&"); - ASSERT_FALSE(my_descriptor->is_consistent()); - - my_builder->set_name("my_interface::action::dds_::Position"); - ASSERT_TRUE(my_descriptor->is_consistent()); - my_builder->set_name("my_interface:action::dds_::Position"); - ASSERT_FALSE(my_descriptor->is_consistent()); - my_builder->set_name("my_interface:::action::dds_::Position"); - ASSERT_FALSE(my_descriptor->is_consistent()); - my_builder->set_name("_my_interface::action::dds_::Position"); - ASSERT_FALSE(my_descriptor->is_consistent()); - my_builder->set_name("1my_interface::action::dds_::Position"); - ASSERT_FALSE(my_descriptor->is_consistent()); - my_builder->set_name(":my_interface::action::dds_::Position"); - ASSERT_FALSE(my_descriptor->is_consistent()); - my_builder->set_name("::my_interface::action::dds_::Position"); - ASSERT_FALSE(my_descriptor->is_consistent()); - my_builder->set_name("$my_interface::action::dds_::Position"); - ASSERT_FALSE(my_descriptor->is_consistent()); - my_builder->set_name("my_interface::2action::dds_::Position"); - ASSERT_FALSE(my_descriptor->is_consistent()); - my_builder->set_name("my_interface::_action::dds_::Position"); - ASSERT_FALSE(my_descriptor->is_consistent()); - my_builder->set_name("my_interface::*action::dds_::Position"); - ASSERT_FALSE(my_descriptor->is_consistent()); - my_builder->set_name("my_interface::action*::dds_::Position"); - ASSERT_FALSE(my_descriptor->is_consistent()); -} - -TEST_F(XTypesTests, MemberDescriptorFullyQualifiedName) -{ - MemberId member_id = 0; - DynamicTypeBuilder_ptr my_builder(DynamicTypeBuilderFactory::get_instance()->create_struct_builder()); - my_builder->add_member(member_id++, "x", DynamicTypeBuilderFactory::get_instance()->create_float32_type()); - my_builder->add_member(member_id++, "y", DynamicTypeBuilderFactory::get_instance()->create_float32_type()); - my_builder->add_member(member_id, "z", DynamicTypeBuilderFactory::get_instance()->create_float32_type()); - - my_builder->set_name("Position"); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, my_builder->add_member(member_id++, "t1", my_builder->build())); - my_builder->set_name("Position_"); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, my_builder->add_member(member_id++, "t2", my_builder->build())); - my_builder->set_name("Position123"); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, my_builder->add_member(member_id++, "t3", my_builder->build())); - my_builder->set_name("position_123"); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, my_builder->add_member(member_id++, "t4", my_builder->build())); - my_builder->set_name("_Position"); - EXPECT_EQ(ReturnCode_t::RETCODE_BAD_PARAMETER, my_builder->add_member(member_id++, "t5", my_builder->build())); - my_builder->set_name("123Position"); - EXPECT_EQ(ReturnCode_t::RETCODE_BAD_PARAMETER, my_builder->add_member(member_id++, "t6", my_builder->build())); - my_builder->set_name("Position&"); - EXPECT_EQ(ReturnCode_t::RETCODE_BAD_PARAMETER, my_builder->add_member(member_id++, "t7", my_builder->build())); - - my_builder->set_name("my_interface::action::dds_::Position"); - EXPECT_EQ(ReturnCode_t::RETCODE_OK, my_builder->add_member(member_id++, "t8", my_builder->build())); - my_builder->set_name("my_interface:action::dds_::Position"); - EXPECT_EQ(ReturnCode_t::RETCODE_BAD_PARAMETER, my_builder->add_member(member_id++, "t9", my_builder->build())); - my_builder->set_name("my_interface:::action::dds_::Position"); - EXPECT_EQ(ReturnCode_t::RETCODE_BAD_PARAMETER, my_builder->add_member(member_id++, "tA", my_builder->build())); - my_builder->set_name("_my_interface::action::dds_::Position"); - EXPECT_EQ(ReturnCode_t::RETCODE_BAD_PARAMETER, my_builder->add_member(member_id++, "tB", my_builder->build())); - my_builder->set_name("1my_interface::action::dds_::Position"); - EXPECT_EQ(ReturnCode_t::RETCODE_BAD_PARAMETER, my_builder->add_member(member_id++, "tC", my_builder->build())); - my_builder->set_name(":my_interface::action::dds_::Position"); - EXPECT_EQ(ReturnCode_t::RETCODE_BAD_PARAMETER, my_builder->add_member(member_id++, "tD", my_builder->build())); - my_builder->set_name("::my_interface::action::dds_::Position"); - EXPECT_EQ(ReturnCode_t::RETCODE_BAD_PARAMETER, my_builder->add_member(member_id++, "tE", my_builder->build())); - my_builder->set_name("$my_interface::action::dds_::Position"); - EXPECT_EQ(ReturnCode_t::RETCODE_BAD_PARAMETER, my_builder->add_member(member_id++, "tF", my_builder->build())); - my_builder->set_name("my_interface::2action::dds_::Position"); - EXPECT_EQ(ReturnCode_t::RETCODE_BAD_PARAMETER, my_builder->add_member(member_id++, "tG", my_builder->build())); - my_builder->set_name("my_interface::_action::dds_::Position"); - EXPECT_EQ(ReturnCode_t::RETCODE_BAD_PARAMETER, my_builder->add_member(member_id++, "tH", my_builder->build())); - my_builder->set_name("my_interface::*action::dds_::Position"); - EXPECT_EQ(ReturnCode_t::RETCODE_BAD_PARAMETER, my_builder->add_member(member_id++, "tI", my_builder->build())); - my_builder->set_name("my_interface::action*::dds_::Position"); - EXPECT_EQ(ReturnCode_t::RETCODE_BAD_PARAMETER, my_builder->add_member(member_id++, "tJ", my_builder->build())); -} - -int main( - int argc, - char** argv) -{ - eprosima::fastdds::dds::Log::SetVerbosity(eprosima::fastdds::dds::Log::Info); - - testing::InitGoogleTest(&argc, argv); - return RUN_ALL_TESTS(); -} diff --git a/test/unittest/xtypes/idl/Types.cxx b/test/unittest/xtypes/idl/Types.cxx deleted file mode 100644 index d0ee9153b8d..00000000000 --- a/test/unittest/xtypes/idl/Types.cxx +++ /dev/null @@ -1,5244 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file Types.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "Types.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#include "TypesTypeObject.h" - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - - - - -MyEnumStruct::MyEnumStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -MyEnumStruct::~MyEnumStruct() -{ -} - -MyEnumStruct::MyEnumStruct( - const MyEnumStruct& x) -{ - m_my_enum = x.m_my_enum; -} - -MyEnumStruct::MyEnumStruct( - MyEnumStruct&& x) noexcept -{ - m_my_enum = x.m_my_enum; -} - -MyEnumStruct& MyEnumStruct::operator =( - const MyEnumStruct& x) -{ - - m_my_enum = x.m_my_enum; - return *this; -} - -MyEnumStruct& MyEnumStruct::operator =( - MyEnumStruct&& x) noexcept -{ - - m_my_enum = x.m_my_enum; - return *this; -} - -bool MyEnumStruct::operator ==( - const MyEnumStruct& x) const -{ - return (m_my_enum == x.m_my_enum); -} - -bool MyEnumStruct::operator !=( - const MyEnumStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member my_enum - * @param _my_enum New value for member my_enum - */ -void MyEnumStruct::my_enum( - MyEnum _my_enum) -{ - m_my_enum = _my_enum; -} - -/*! - * @brief This function returns the value of member my_enum - * @return Value of member my_enum - */ -MyEnum MyEnumStruct::my_enum() const -{ - return m_my_enum; -} - -/*! - * @brief This function returns a reference to member my_enum - * @return Reference to member my_enum - */ -MyEnum& MyEnumStruct::my_enum() -{ - return m_my_enum; -} - - - - -MyBadEnumStruct::MyBadEnumStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -MyBadEnumStruct::~MyBadEnumStruct() -{ -} - -MyBadEnumStruct::MyBadEnumStruct( - const MyBadEnumStruct& x) -{ - m_my_enum = x.m_my_enum; -} - -MyBadEnumStruct::MyBadEnumStruct( - MyBadEnumStruct&& x) noexcept -{ - m_my_enum = x.m_my_enum; -} - -MyBadEnumStruct& MyBadEnumStruct::operator =( - const MyBadEnumStruct& x) -{ - - m_my_enum = x.m_my_enum; - return *this; -} - -MyBadEnumStruct& MyBadEnumStruct::operator =( - MyBadEnumStruct&& x) noexcept -{ - - m_my_enum = x.m_my_enum; - return *this; -} - -bool MyBadEnumStruct::operator ==( - const MyBadEnumStruct& x) const -{ - return (m_my_enum == x.m_my_enum); -} - -bool MyBadEnumStruct::operator !=( - const MyBadEnumStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member my_enum - * @param _my_enum New value for member my_enum - */ -void MyBadEnumStruct::my_enum( - MyBadEnum _my_enum) -{ - m_my_enum = _my_enum; -} - -/*! - * @brief This function returns the value of member my_enum - * @return Value of member my_enum - */ -MyBadEnum MyBadEnumStruct::my_enum() const -{ - return m_my_enum; -} - -/*! - * @brief This function returns a reference to member my_enum - * @return Reference to member my_enum - */ -MyBadEnum& MyBadEnumStruct::my_enum() -{ - return m_my_enum; -} - - - - - -MyAliasEnumStruct::MyAliasEnumStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -MyAliasEnumStruct::~MyAliasEnumStruct() -{ -} - -MyAliasEnumStruct::MyAliasEnumStruct( - const MyAliasEnumStruct& x) -{ - m_my_enum = x.m_my_enum; -} - -MyAliasEnumStruct::MyAliasEnumStruct( - MyAliasEnumStruct&& x) noexcept -{ - m_my_enum = x.m_my_enum; -} - -MyAliasEnumStruct& MyAliasEnumStruct::operator =( - const MyAliasEnumStruct& x) -{ - - m_my_enum = x.m_my_enum; - return *this; -} - -MyAliasEnumStruct& MyAliasEnumStruct::operator =( - MyAliasEnumStruct&& x) noexcept -{ - - m_my_enum = x.m_my_enum; - return *this; -} - -bool MyAliasEnumStruct::operator ==( - const MyAliasEnumStruct& x) const -{ - return (m_my_enum == x.m_my_enum); -} - -bool MyAliasEnumStruct::operator !=( - const MyAliasEnumStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member my_enum - * @param _my_enum New value for member my_enum - */ -void MyAliasEnumStruct::my_enum( - MyAliasEnum _my_enum) -{ - m_my_enum = _my_enum; -} - -/*! - * @brief This function returns the value of member my_enum - * @return Value of member my_enum - */ -MyAliasEnum MyAliasEnumStruct::my_enum() const -{ - return m_my_enum; -} - -/*! - * @brief This function returns a reference to member my_enum - * @return Reference to member my_enum - */ -MyAliasEnum& MyAliasEnumStruct::my_enum() -{ - return m_my_enum; -} - - - - -BasicStruct::BasicStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -BasicStruct::~BasicStruct() -{ -} - -BasicStruct::BasicStruct( - const BasicStruct& x) -{ - m_my_bool = x.m_my_bool; - m_my_int32 = x.m_my_int32; - m_my_string = x.m_my_string; -} - -BasicStruct::BasicStruct( - BasicStruct&& x) noexcept -{ - m_my_bool = x.m_my_bool; - m_my_int32 = x.m_my_int32; - m_my_string = std::move(x.m_my_string); -} - -BasicStruct& BasicStruct::operator =( - const BasicStruct& x) -{ - - m_my_bool = x.m_my_bool; - m_my_int32 = x.m_my_int32; - m_my_string = x.m_my_string; - return *this; -} - -BasicStruct& BasicStruct::operator =( - BasicStruct&& x) noexcept -{ - - m_my_bool = x.m_my_bool; - m_my_int32 = x.m_my_int32; - m_my_string = std::move(x.m_my_string); - return *this; -} - -bool BasicStruct::operator ==( - const BasicStruct& x) const -{ - return (m_my_bool == x.m_my_bool && - m_my_int32 == x.m_my_int32 && - m_my_string == x.m_my_string); -} - -bool BasicStruct::operator !=( - const BasicStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member my_bool - * @param _my_bool New value for member my_bool - */ -void BasicStruct::my_bool( - bool _my_bool) -{ - m_my_bool = _my_bool; -} - -/*! - * @brief This function returns the value of member my_bool - * @return Value of member my_bool - */ -bool BasicStruct::my_bool() const -{ - return m_my_bool; -} - -/*! - * @brief This function returns a reference to member my_bool - * @return Reference to member my_bool - */ -bool& BasicStruct::my_bool() -{ - return m_my_bool; -} - - -/*! - * @brief This function sets a value in member my_int32 - * @param _my_int32 New value for member my_int32 - */ -void BasicStruct::my_int32( - int32_t _my_int32) -{ - m_my_int32 = _my_int32; -} - -/*! - * @brief This function returns the value of member my_int32 - * @return Value of member my_int32 - */ -int32_t BasicStruct::my_int32() const -{ - return m_my_int32; -} - -/*! - * @brief This function returns a reference to member my_int32 - * @return Reference to member my_int32 - */ -int32_t& BasicStruct::my_int32() -{ - return m_my_int32; -} - - -/*! - * @brief This function copies the value in member my_string - * @param _my_string New value to be copied in member my_string - */ -void BasicStruct::my_string( - const std::string& _my_string) -{ - m_my_string = _my_string; -} - -/*! - * @brief This function moves the value in member my_string - * @param _my_string New value to be moved in member my_string - */ -void BasicStruct::my_string( - std::string&& _my_string) -{ - m_my_string = std::move(_my_string); -} - -/*! - * @brief This function returns a constant reference to member my_string - * @return Constant reference to member my_string - */ -const std::string& BasicStruct::my_string() const -{ - return m_my_string; -} - -/*! - * @brief This function returns a reference to member my_string - * @return Reference to member my_string - */ -std::string& BasicStruct::my_string() -{ - return m_my_string; -} - - - - -BasicNamesStruct::BasicNamesStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -BasicNamesStruct::~BasicNamesStruct() -{ -} - -BasicNamesStruct::BasicNamesStruct( - const BasicNamesStruct& x) -{ - m_my_bool_name = x.m_my_bool_name; - m_my_int32_name = x.m_my_int32_name; - m_my_string_name = x.m_my_string_name; -} - -BasicNamesStruct::BasicNamesStruct( - BasicNamesStruct&& x) noexcept -{ - m_my_bool_name = x.m_my_bool_name; - m_my_int32_name = x.m_my_int32_name; - m_my_string_name = std::move(x.m_my_string_name); -} - -BasicNamesStruct& BasicNamesStruct::operator =( - const BasicNamesStruct& x) -{ - - m_my_bool_name = x.m_my_bool_name; - m_my_int32_name = x.m_my_int32_name; - m_my_string_name = x.m_my_string_name; - return *this; -} - -BasicNamesStruct& BasicNamesStruct::operator =( - BasicNamesStruct&& x) noexcept -{ - - m_my_bool_name = x.m_my_bool_name; - m_my_int32_name = x.m_my_int32_name; - m_my_string_name = std::move(x.m_my_string_name); - return *this; -} - -bool BasicNamesStruct::operator ==( - const BasicNamesStruct& x) const -{ - return (m_my_bool_name == x.m_my_bool_name && - m_my_int32_name == x.m_my_int32_name && - m_my_string_name == x.m_my_string_name); -} - -bool BasicNamesStruct::operator !=( - const BasicNamesStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member my_bool_name - * @param _my_bool_name New value for member my_bool_name - */ -void BasicNamesStruct::my_bool_name( - bool _my_bool_name) -{ - m_my_bool_name = _my_bool_name; -} - -/*! - * @brief This function returns the value of member my_bool_name - * @return Value of member my_bool_name - */ -bool BasicNamesStruct::my_bool_name() const -{ - return m_my_bool_name; -} - -/*! - * @brief This function returns a reference to member my_bool_name - * @return Reference to member my_bool_name - */ -bool& BasicNamesStruct::my_bool_name() -{ - return m_my_bool_name; -} - - -/*! - * @brief This function sets a value in member my_int32_name - * @param _my_int32_name New value for member my_int32_name - */ -void BasicNamesStruct::my_int32_name( - int32_t _my_int32_name) -{ - m_my_int32_name = _my_int32_name; -} - -/*! - * @brief This function returns the value of member my_int32_name - * @return Value of member my_int32_name - */ -int32_t BasicNamesStruct::my_int32_name() const -{ - return m_my_int32_name; -} - -/*! - * @brief This function returns a reference to member my_int32_name - * @return Reference to member my_int32_name - */ -int32_t& BasicNamesStruct::my_int32_name() -{ - return m_my_int32_name; -} - - -/*! - * @brief This function copies the value in member my_string_name - * @param _my_string_name New value to be copied in member my_string_name - */ -void BasicNamesStruct::my_string_name( - const std::string& _my_string_name) -{ - m_my_string_name = _my_string_name; -} - -/*! - * @brief This function moves the value in member my_string_name - * @param _my_string_name New value to be moved in member my_string_name - */ -void BasicNamesStruct::my_string_name( - std::string&& _my_string_name) -{ - m_my_string_name = std::move(_my_string_name); -} - -/*! - * @brief This function returns a constant reference to member my_string_name - * @return Constant reference to member my_string_name - */ -const std::string& BasicNamesStruct::my_string_name() const -{ - return m_my_string_name; -} - -/*! - * @brief This function returns a reference to member my_string_name - * @return Reference to member my_string_name - */ -std::string& BasicNamesStruct::my_string_name() -{ - return m_my_string_name; -} - - - - -BasicBadStruct::BasicBadStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -BasicBadStruct::~BasicBadStruct() -{ -} - -BasicBadStruct::BasicBadStruct( - const BasicBadStruct& x) -{ - m_my_bool = x.m_my_bool; - m_my_int32 = x.m_my_int32; - m_my_string = x.m_my_string; -} - -BasicBadStruct::BasicBadStruct( - BasicBadStruct&& x) noexcept -{ - m_my_bool = x.m_my_bool; - m_my_int32 = x.m_my_int32; - m_my_string = std::move(x.m_my_string); -} - -BasicBadStruct& BasicBadStruct::operator =( - const BasicBadStruct& x) -{ - - m_my_bool = x.m_my_bool; - m_my_int32 = x.m_my_int32; - m_my_string = x.m_my_string; - return *this; -} - -BasicBadStruct& BasicBadStruct::operator =( - BasicBadStruct&& x) noexcept -{ - - m_my_bool = x.m_my_bool; - m_my_int32 = x.m_my_int32; - m_my_string = std::move(x.m_my_string); - return *this; -} - -bool BasicBadStruct::operator ==( - const BasicBadStruct& x) const -{ - return (m_my_bool == x.m_my_bool && - m_my_int32 == x.m_my_int32 && - m_my_string == x.m_my_string); -} - -bool BasicBadStruct::operator !=( - const BasicBadStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member my_bool - * @param _my_bool New value for member my_bool - */ -void BasicBadStruct::my_bool( - uint8_t _my_bool) -{ - m_my_bool = _my_bool; -} - -/*! - * @brief This function returns the value of member my_bool - * @return Value of member my_bool - */ -uint8_t BasicBadStruct::my_bool() const -{ - return m_my_bool; -} - -/*! - * @brief This function returns a reference to member my_bool - * @return Reference to member my_bool - */ -uint8_t& BasicBadStruct::my_bool() -{ - return m_my_bool; -} - - -/*! - * @brief This function sets a value in member my_int32 - * @param _my_int32 New value for member my_int32 - */ -void BasicBadStruct::my_int32( - int32_t _my_int32) -{ - m_my_int32 = _my_int32; -} - -/*! - * @brief This function returns the value of member my_int32 - * @return Value of member my_int32 - */ -int32_t BasicBadStruct::my_int32() const -{ - return m_my_int32; -} - -/*! - * @brief This function returns a reference to member my_int32 - * @return Reference to member my_int32 - */ -int32_t& BasicBadStruct::my_int32() -{ - return m_my_int32; -} - - -/*! - * @brief This function copies the value in member my_string - * @param _my_string New value to be copied in member my_string - */ -void BasicBadStruct::my_string( - const std::string& _my_string) -{ - m_my_string = _my_string; -} - -/*! - * @brief This function moves the value in member my_string - * @param _my_string New value to be moved in member my_string - */ -void BasicBadStruct::my_string( - std::string&& _my_string) -{ - m_my_string = std::move(_my_string); -} - -/*! - * @brief This function returns a constant reference to member my_string - * @return Constant reference to member my_string - */ -const std::string& BasicBadStruct::my_string() const -{ - return m_my_string; -} - -/*! - * @brief This function returns a reference to member my_string - * @return Reference to member my_string - */ -std::string& BasicBadStruct::my_string() -{ - return m_my_string; -} - - - - -BasicWideStruct::BasicWideStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -BasicWideStruct::~BasicWideStruct() -{ -} - -BasicWideStruct::BasicWideStruct( - const BasicWideStruct& x) -{ - m_my_bool = x.m_my_bool; - m_my_int32 = x.m_my_int32; - m_my_string = x.m_my_string; - m_new_int32 = x.m_new_int32; - m_new_string = x.m_new_string; -} - -BasicWideStruct::BasicWideStruct( - BasicWideStruct&& x) noexcept -{ - m_my_bool = x.m_my_bool; - m_my_int32 = x.m_my_int32; - m_my_string = std::move(x.m_my_string); - m_new_int32 = x.m_new_int32; - m_new_string = std::move(x.m_new_string); -} - -BasicWideStruct& BasicWideStruct::operator =( - const BasicWideStruct& x) -{ - - m_my_bool = x.m_my_bool; - m_my_int32 = x.m_my_int32; - m_my_string = x.m_my_string; - m_new_int32 = x.m_new_int32; - m_new_string = x.m_new_string; - return *this; -} - -BasicWideStruct& BasicWideStruct::operator =( - BasicWideStruct&& x) noexcept -{ - - m_my_bool = x.m_my_bool; - m_my_int32 = x.m_my_int32; - m_my_string = std::move(x.m_my_string); - m_new_int32 = x.m_new_int32; - m_new_string = std::move(x.m_new_string); - return *this; -} - -bool BasicWideStruct::operator ==( - const BasicWideStruct& x) const -{ - return (m_my_bool == x.m_my_bool && - m_my_int32 == x.m_my_int32 && - m_my_string == x.m_my_string && - m_new_int32 == x.m_new_int32 && - m_new_string == x.m_new_string); -} - -bool BasicWideStruct::operator !=( - const BasicWideStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member my_bool - * @param _my_bool New value for member my_bool - */ -void BasicWideStruct::my_bool( - bool _my_bool) -{ - m_my_bool = _my_bool; -} - -/*! - * @brief This function returns the value of member my_bool - * @return Value of member my_bool - */ -bool BasicWideStruct::my_bool() const -{ - return m_my_bool; -} - -/*! - * @brief This function returns a reference to member my_bool - * @return Reference to member my_bool - */ -bool& BasicWideStruct::my_bool() -{ - return m_my_bool; -} - - -/*! - * @brief This function sets a value in member my_int32 - * @param _my_int32 New value for member my_int32 - */ -void BasicWideStruct::my_int32( - int32_t _my_int32) -{ - m_my_int32 = _my_int32; -} - -/*! - * @brief This function returns the value of member my_int32 - * @return Value of member my_int32 - */ -int32_t BasicWideStruct::my_int32() const -{ - return m_my_int32; -} - -/*! - * @brief This function returns a reference to member my_int32 - * @return Reference to member my_int32 - */ -int32_t& BasicWideStruct::my_int32() -{ - return m_my_int32; -} - - -/*! - * @brief This function copies the value in member my_string - * @param _my_string New value to be copied in member my_string - */ -void BasicWideStruct::my_string( - const std::string& _my_string) -{ - m_my_string = _my_string; -} - -/*! - * @brief This function moves the value in member my_string - * @param _my_string New value to be moved in member my_string - */ -void BasicWideStruct::my_string( - std::string&& _my_string) -{ - m_my_string = std::move(_my_string); -} - -/*! - * @brief This function returns a constant reference to member my_string - * @return Constant reference to member my_string - */ -const std::string& BasicWideStruct::my_string() const -{ - return m_my_string; -} - -/*! - * @brief This function returns a reference to member my_string - * @return Reference to member my_string - */ -std::string& BasicWideStruct::my_string() -{ - return m_my_string; -} - - -/*! - * @brief This function sets a value in member new_int32 - * @param _new_int32 New value for member new_int32 - */ -void BasicWideStruct::new_int32( - int32_t _new_int32) -{ - m_new_int32 = _new_int32; -} - -/*! - * @brief This function returns the value of member new_int32 - * @return Value of member new_int32 - */ -int32_t BasicWideStruct::new_int32() const -{ - return m_new_int32; -} - -/*! - * @brief This function returns a reference to member new_int32 - * @return Reference to member new_int32 - */ -int32_t& BasicWideStruct::new_int32() -{ - return m_new_int32; -} - - -/*! - * @brief This function copies the value in member new_string - * @param _new_string New value to be copied in member new_string - */ -void BasicWideStruct::new_string( - const std::string& _new_string) -{ - m_new_string = _new_string; -} - -/*! - * @brief This function moves the value in member new_string - * @param _new_string New value to be moved in member new_string - */ -void BasicWideStruct::new_string( - std::string&& _new_string) -{ - m_new_string = std::move(_new_string); -} - -/*! - * @brief This function returns a constant reference to member new_string - * @return Constant reference to member new_string - */ -const std::string& BasicWideStruct::new_string() const -{ - return m_new_string; -} - -/*! - * @brief This function returns a reference to member new_string - * @return Reference to member new_string - */ -std::string& BasicWideStruct::new_string() -{ - return m_new_string; -} - - - - -BadBasicWideStruct::BadBasicWideStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -BadBasicWideStruct::~BadBasicWideStruct() -{ -} - -BadBasicWideStruct::BadBasicWideStruct( - const BadBasicWideStruct& x) -{ - m_new_int32 = x.m_new_int32; - m_new_string = x.m_new_string; - m_my_bool = x.m_my_bool; - m_my_int32 = x.m_my_int32; - m_my_string = x.m_my_string; -} - -BadBasicWideStruct::BadBasicWideStruct( - BadBasicWideStruct&& x) noexcept -{ - m_new_int32 = x.m_new_int32; - m_new_string = std::move(x.m_new_string); - m_my_bool = x.m_my_bool; - m_my_int32 = x.m_my_int32; - m_my_string = std::move(x.m_my_string); -} - -BadBasicWideStruct& BadBasicWideStruct::operator =( - const BadBasicWideStruct& x) -{ - - m_new_int32 = x.m_new_int32; - m_new_string = x.m_new_string; - m_my_bool = x.m_my_bool; - m_my_int32 = x.m_my_int32; - m_my_string = x.m_my_string; - return *this; -} - -BadBasicWideStruct& BadBasicWideStruct::operator =( - BadBasicWideStruct&& x) noexcept -{ - - m_new_int32 = x.m_new_int32; - m_new_string = std::move(x.m_new_string); - m_my_bool = x.m_my_bool; - m_my_int32 = x.m_my_int32; - m_my_string = std::move(x.m_my_string); - return *this; -} - -bool BadBasicWideStruct::operator ==( - const BadBasicWideStruct& x) const -{ - return (m_new_int32 == x.m_new_int32 && - m_new_string == x.m_new_string && - m_my_bool == x.m_my_bool && - m_my_int32 == x.m_my_int32 && - m_my_string == x.m_my_string); -} - -bool BadBasicWideStruct::operator !=( - const BadBasicWideStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member new_int32 - * @param _new_int32 New value for member new_int32 - */ -void BadBasicWideStruct::new_int32( - int32_t _new_int32) -{ - m_new_int32 = _new_int32; -} - -/*! - * @brief This function returns the value of member new_int32 - * @return Value of member new_int32 - */ -int32_t BadBasicWideStruct::new_int32() const -{ - return m_new_int32; -} - -/*! - * @brief This function returns a reference to member new_int32 - * @return Reference to member new_int32 - */ -int32_t& BadBasicWideStruct::new_int32() -{ - return m_new_int32; -} - - -/*! - * @brief This function copies the value in member new_string - * @param _new_string New value to be copied in member new_string - */ -void BadBasicWideStruct::new_string( - const std::string& _new_string) -{ - m_new_string = _new_string; -} - -/*! - * @brief This function moves the value in member new_string - * @param _new_string New value to be moved in member new_string - */ -void BadBasicWideStruct::new_string( - std::string&& _new_string) -{ - m_new_string = std::move(_new_string); -} - -/*! - * @brief This function returns a constant reference to member new_string - * @return Constant reference to member new_string - */ -const std::string& BadBasicWideStruct::new_string() const -{ - return m_new_string; -} - -/*! - * @brief This function returns a reference to member new_string - * @return Reference to member new_string - */ -std::string& BadBasicWideStruct::new_string() -{ - return m_new_string; -} - - -/*! - * @brief This function sets a value in member my_bool - * @param _my_bool New value for member my_bool - */ -void BadBasicWideStruct::my_bool( - bool _my_bool) -{ - m_my_bool = _my_bool; -} - -/*! - * @brief This function returns the value of member my_bool - * @return Value of member my_bool - */ -bool BadBasicWideStruct::my_bool() const -{ - return m_my_bool; -} - -/*! - * @brief This function returns a reference to member my_bool - * @return Reference to member my_bool - */ -bool& BadBasicWideStruct::my_bool() -{ - return m_my_bool; -} - - -/*! - * @brief This function sets a value in member my_int32 - * @param _my_int32 New value for member my_int32 - */ -void BadBasicWideStruct::my_int32( - int32_t _my_int32) -{ - m_my_int32 = _my_int32; -} - -/*! - * @brief This function returns the value of member my_int32 - * @return Value of member my_int32 - */ -int32_t BadBasicWideStruct::my_int32() const -{ - return m_my_int32; -} - -/*! - * @brief This function returns a reference to member my_int32 - * @return Reference to member my_int32 - */ -int32_t& BadBasicWideStruct::my_int32() -{ - return m_my_int32; -} - - -/*! - * @brief This function copies the value in member my_string - * @param _my_string New value to be copied in member my_string - */ -void BadBasicWideStruct::my_string( - const std::string& _my_string) -{ - m_my_string = _my_string; -} - -/*! - * @brief This function moves the value in member my_string - * @param _my_string New value to be moved in member my_string - */ -void BadBasicWideStruct::my_string( - std::string&& _my_string) -{ - m_my_string = std::move(_my_string); -} - -/*! - * @brief This function returns a constant reference to member my_string - * @return Constant reference to member my_string - */ -const std::string& BadBasicWideStruct::my_string() const -{ - return m_my_string; -} - -/*! - * @brief This function returns a reference to member my_string - * @return Reference to member my_string - */ -std::string& BadBasicWideStruct::my_string() -{ - return m_my_string; -} - - - - -StringStruct::StringStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -StringStruct::~StringStruct() -{ -} - -StringStruct::StringStruct( - const StringStruct& x) -{ - m_my_string = x.m_my_string; -} - -StringStruct::StringStruct( - StringStruct&& x) noexcept -{ - m_my_string = std::move(x.m_my_string); -} - -StringStruct& StringStruct::operator =( - const StringStruct& x) -{ - - m_my_string = x.m_my_string; - return *this; -} - -StringStruct& StringStruct::operator =( - StringStruct&& x) noexcept -{ - - m_my_string = std::move(x.m_my_string); - return *this; -} - -bool StringStruct::operator ==( - const StringStruct& x) const -{ - return (m_my_string == x.m_my_string); -} - -bool StringStruct::operator !=( - const StringStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_string - * @param _my_string New value to be copied in member my_string - */ -void StringStruct::my_string( - const std::string& _my_string) -{ - m_my_string = _my_string; -} - -/*! - * @brief This function moves the value in member my_string - * @param _my_string New value to be moved in member my_string - */ -void StringStruct::my_string( - std::string&& _my_string) -{ - m_my_string = std::move(_my_string); -} - -/*! - * @brief This function returns a constant reference to member my_string - * @return Constant reference to member my_string - */ -const std::string& StringStruct::my_string() const -{ - return m_my_string; -} - -/*! - * @brief This function returns a reference to member my_string - * @return Reference to member my_string - */ -std::string& StringStruct::my_string() -{ - return m_my_string; -} - - - - -LargeStringStruct::LargeStringStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -LargeStringStruct::~LargeStringStruct() -{ -} - -LargeStringStruct::LargeStringStruct( - const LargeStringStruct& x) -{ - m_my_large_string = x.m_my_large_string; -} - -LargeStringStruct::LargeStringStruct( - LargeStringStruct&& x) noexcept -{ - m_my_large_string = std::move(x.m_my_large_string); -} - -LargeStringStruct& LargeStringStruct::operator =( - const LargeStringStruct& x) -{ - - m_my_large_string = x.m_my_large_string; - return *this; -} - -LargeStringStruct& LargeStringStruct::operator =( - LargeStringStruct&& x) noexcept -{ - - m_my_large_string = std::move(x.m_my_large_string); - return *this; -} - -bool LargeStringStruct::operator ==( - const LargeStringStruct& x) const -{ - return (m_my_large_string == x.m_my_large_string); -} - -bool LargeStringStruct::operator !=( - const LargeStringStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_large_string - * @param _my_large_string New value to be copied in member my_large_string - */ -void LargeStringStruct::my_large_string( - const eprosima::fastcdr::fixed_string<41925>& _my_large_string) -{ - m_my_large_string = _my_large_string; -} - -/*! - * @brief This function moves the value in member my_large_string - * @param _my_large_string New value to be moved in member my_large_string - */ -void LargeStringStruct::my_large_string( - eprosima::fastcdr::fixed_string<41925>&& _my_large_string) -{ - m_my_large_string = std::move(_my_large_string); -} - -/*! - * @brief This function returns a constant reference to member my_large_string - * @return Constant reference to member my_large_string - */ -const eprosima::fastcdr::fixed_string<41925>& LargeStringStruct::my_large_string() const -{ - return m_my_large_string; -} - -/*! - * @brief This function returns a reference to member my_large_string - * @return Reference to member my_large_string - */ -eprosima::fastcdr::fixed_string<41925>& LargeStringStruct::my_large_string() -{ - return m_my_large_string; -} - - - - -WStringStruct::WStringStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -WStringStruct::~WStringStruct() -{ -} - -WStringStruct::WStringStruct( - const WStringStruct& x) -{ - m_my_wstring = x.m_my_wstring; -} - -WStringStruct::WStringStruct( - WStringStruct&& x) noexcept -{ - m_my_wstring = std::move(x.m_my_wstring); -} - -WStringStruct& WStringStruct::operator =( - const WStringStruct& x) -{ - - m_my_wstring = x.m_my_wstring; - return *this; -} - -WStringStruct& WStringStruct::operator =( - WStringStruct&& x) noexcept -{ - - m_my_wstring = std::move(x.m_my_wstring); - return *this; -} - -bool WStringStruct::operator ==( - const WStringStruct& x) const -{ - return (m_my_wstring == x.m_my_wstring); -} - -bool WStringStruct::operator !=( - const WStringStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_wstring - * @param _my_wstring New value to be copied in member my_wstring - */ -void WStringStruct::my_wstring( - const std::wstring& _my_wstring) -{ - m_my_wstring = _my_wstring; -} - -/*! - * @brief This function moves the value in member my_wstring - * @param _my_wstring New value to be moved in member my_wstring - */ -void WStringStruct::my_wstring( - std::wstring&& _my_wstring) -{ - m_my_wstring = std::move(_my_wstring); -} - -/*! - * @brief This function returns a constant reference to member my_wstring - * @return Constant reference to member my_wstring - */ -const std::wstring& WStringStruct::my_wstring() const -{ - return m_my_wstring; -} - -/*! - * @brief This function returns a reference to member my_wstring - * @return Reference to member my_wstring - */ -std::wstring& WStringStruct::my_wstring() -{ - return m_my_wstring; -} - - - - -LargeWStringStruct::LargeWStringStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -LargeWStringStruct::~LargeWStringStruct() -{ -} - -LargeWStringStruct::LargeWStringStruct( - const LargeWStringStruct& x) -{ - m_my_large_wstring = x.m_my_large_wstring; -} - -LargeWStringStruct::LargeWStringStruct( - LargeWStringStruct&& x) noexcept -{ - m_my_large_wstring = std::move(x.m_my_large_wstring); -} - -LargeWStringStruct& LargeWStringStruct::operator =( - const LargeWStringStruct& x) -{ - - m_my_large_wstring = x.m_my_large_wstring; - return *this; -} - -LargeWStringStruct& LargeWStringStruct::operator =( - LargeWStringStruct&& x) noexcept -{ - - m_my_large_wstring = std::move(x.m_my_large_wstring); - return *this; -} - -bool LargeWStringStruct::operator ==( - const LargeWStringStruct& x) const -{ - return (m_my_large_wstring == x.m_my_large_wstring); -} - -bool LargeWStringStruct::operator !=( - const LargeWStringStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_large_wstring - * @param _my_large_wstring New value to be copied in member my_large_wstring - */ -void LargeWStringStruct::my_large_wstring( - const std::wstring& _my_large_wstring) -{ - m_my_large_wstring = _my_large_wstring; -} - -/*! - * @brief This function moves the value in member my_large_wstring - * @param _my_large_wstring New value to be moved in member my_large_wstring - */ -void LargeWStringStruct::my_large_wstring( - std::wstring&& _my_large_wstring) -{ - m_my_large_wstring = std::move(_my_large_wstring); -} - -/*! - * @brief This function returns a constant reference to member my_large_wstring - * @return Constant reference to member my_large_wstring - */ -const std::wstring& LargeWStringStruct::my_large_wstring() const -{ - return m_my_large_wstring; -} - -/*! - * @brief This function returns a reference to member my_large_wstring - * @return Reference to member my_large_wstring - */ -std::wstring& LargeWStringStruct::my_large_wstring() -{ - return m_my_large_wstring; -} - - - - -ArrayStruct::ArrayStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -ArrayStruct::~ArrayStruct() -{ -} - -ArrayStruct::ArrayStruct( - const ArrayStruct& x) -{ - m_my_array = x.m_my_array; -} - -ArrayStruct::ArrayStruct( - ArrayStruct&& x) noexcept -{ - m_my_array = std::move(x.m_my_array); -} - -ArrayStruct& ArrayStruct::operator =( - const ArrayStruct& x) -{ - - m_my_array = x.m_my_array; - return *this; -} - -ArrayStruct& ArrayStruct::operator =( - ArrayStruct&& x) noexcept -{ - - m_my_array = std::move(x.m_my_array); - return *this; -} - -bool ArrayStruct::operator ==( - const ArrayStruct& x) const -{ - return (m_my_array == x.m_my_array); -} - -bool ArrayStruct::operator !=( - const ArrayStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_array - * @param _my_array New value to be copied in member my_array - */ -void ArrayStruct::my_array( - const std::array& _my_array) -{ - m_my_array = _my_array; -} - -/*! - * @brief This function moves the value in member my_array - * @param _my_array New value to be moved in member my_array - */ -void ArrayStruct::my_array( - std::array&& _my_array) -{ - m_my_array = std::move(_my_array); -} - -/*! - * @brief This function returns a constant reference to member my_array - * @return Constant reference to member my_array - */ -const std::array& ArrayStruct::my_array() const -{ - return m_my_array; -} - -/*! - * @brief This function returns a reference to member my_array - * @return Reference to member my_array - */ -std::array& ArrayStruct::my_array() -{ - return m_my_array; -} - - - - -ArrayStructEqual::ArrayStructEqual() -{ - // Just to register all known types - registerTypesTypes(); -} - -ArrayStructEqual::~ArrayStructEqual() -{ -} - -ArrayStructEqual::ArrayStructEqual( - const ArrayStructEqual& x) -{ - m_my_array_equal = x.m_my_array_equal; -} - -ArrayStructEqual::ArrayStructEqual( - ArrayStructEqual&& x) noexcept -{ - m_my_array_equal = std::move(x.m_my_array_equal); -} - -ArrayStructEqual& ArrayStructEqual::operator =( - const ArrayStructEqual& x) -{ - - m_my_array_equal = x.m_my_array_equal; - return *this; -} - -ArrayStructEqual& ArrayStructEqual::operator =( - ArrayStructEqual&& x) noexcept -{ - - m_my_array_equal = std::move(x.m_my_array_equal); - return *this; -} - -bool ArrayStructEqual::operator ==( - const ArrayStructEqual& x) const -{ - return (m_my_array_equal == x.m_my_array_equal); -} - -bool ArrayStructEqual::operator !=( - const ArrayStructEqual& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_array_equal - * @param _my_array_equal New value to be copied in member my_array_equal - */ -void ArrayStructEqual::my_array_equal( - const std::array& _my_array_equal) -{ - m_my_array_equal = _my_array_equal; -} - -/*! - * @brief This function moves the value in member my_array_equal - * @param _my_array_equal New value to be moved in member my_array_equal - */ -void ArrayStructEqual::my_array_equal( - std::array&& _my_array_equal) -{ - m_my_array_equal = std::move(_my_array_equal); -} - -/*! - * @brief This function returns a constant reference to member my_array_equal - * @return Constant reference to member my_array_equal - */ -const std::array& ArrayStructEqual::my_array_equal() const -{ - return m_my_array_equal; -} - -/*! - * @brief This function returns a reference to member my_array_equal - * @return Reference to member my_array_equal - */ -std::array& ArrayStructEqual::my_array_equal() -{ - return m_my_array_equal; -} - - - - -ArrayBadStruct::ArrayBadStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -ArrayBadStruct::~ArrayBadStruct() -{ -} - -ArrayBadStruct::ArrayBadStruct( - const ArrayBadStruct& x) -{ - m_my_array = x.m_my_array; -} - -ArrayBadStruct::ArrayBadStruct( - ArrayBadStruct&& x) noexcept -{ - m_my_array = std::move(x.m_my_array); -} - -ArrayBadStruct& ArrayBadStruct::operator =( - const ArrayBadStruct& x) -{ - - m_my_array = x.m_my_array; - return *this; -} - -ArrayBadStruct& ArrayBadStruct::operator =( - ArrayBadStruct&& x) noexcept -{ - - m_my_array = std::move(x.m_my_array); - return *this; -} - -bool ArrayBadStruct::operator ==( - const ArrayBadStruct& x) const -{ - return (m_my_array == x.m_my_array); -} - -bool ArrayBadStruct::operator !=( - const ArrayBadStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_array - * @param _my_array New value to be copied in member my_array - */ -void ArrayBadStruct::my_array( - const std::array& _my_array) -{ - m_my_array = _my_array; -} - -/*! - * @brief This function moves the value in member my_array - * @param _my_array New value to be moved in member my_array - */ -void ArrayBadStruct::my_array( - std::array&& _my_array) -{ - m_my_array = std::move(_my_array); -} - -/*! - * @brief This function returns a constant reference to member my_array - * @return Constant reference to member my_array - */ -const std::array& ArrayBadStruct::my_array() const -{ - return m_my_array; -} - -/*! - * @brief This function returns a reference to member my_array - * @return Reference to member my_array - */ -std::array& ArrayBadStruct::my_array() -{ - return m_my_array; -} - - - - -ArrayDimensionsStruct::ArrayDimensionsStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -ArrayDimensionsStruct::~ArrayDimensionsStruct() -{ -} - -ArrayDimensionsStruct::ArrayDimensionsStruct( - const ArrayDimensionsStruct& x) -{ - m_my_array = x.m_my_array; -} - -ArrayDimensionsStruct::ArrayDimensionsStruct( - ArrayDimensionsStruct&& x) noexcept -{ - m_my_array = std::move(x.m_my_array); -} - -ArrayDimensionsStruct& ArrayDimensionsStruct::operator =( - const ArrayDimensionsStruct& x) -{ - - m_my_array = x.m_my_array; - return *this; -} - -ArrayDimensionsStruct& ArrayDimensionsStruct::operator =( - ArrayDimensionsStruct&& x) noexcept -{ - - m_my_array = std::move(x.m_my_array); - return *this; -} - -bool ArrayDimensionsStruct::operator ==( - const ArrayDimensionsStruct& x) const -{ - return (m_my_array == x.m_my_array); -} - -bool ArrayDimensionsStruct::operator !=( - const ArrayDimensionsStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_array - * @param _my_array New value to be copied in member my_array - */ -void ArrayDimensionsStruct::my_array( - const std::array, 2>& _my_array) -{ - m_my_array = _my_array; -} - -/*! - * @brief This function moves the value in member my_array - * @param _my_array New value to be moved in member my_array - */ -void ArrayDimensionsStruct::my_array( - std::array, 2>&& _my_array) -{ - m_my_array = std::move(_my_array); -} - -/*! - * @brief This function returns a constant reference to member my_array - * @return Constant reference to member my_array - */ -const std::array, 2>& ArrayDimensionsStruct::my_array() const -{ - return m_my_array; -} - -/*! - * @brief This function returns a reference to member my_array - * @return Reference to member my_array - */ -std::array, 2>& ArrayDimensionsStruct::my_array() -{ - return m_my_array; -} - - - - -ArraySizeStruct::ArraySizeStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -ArraySizeStruct::~ArraySizeStruct() -{ -} - -ArraySizeStruct::ArraySizeStruct( - const ArraySizeStruct& x) -{ - m_my_array = x.m_my_array; -} - -ArraySizeStruct::ArraySizeStruct( - ArraySizeStruct&& x) noexcept -{ - m_my_array = std::move(x.m_my_array); -} - -ArraySizeStruct& ArraySizeStruct::operator =( - const ArraySizeStruct& x) -{ - - m_my_array = x.m_my_array; - return *this; -} - -ArraySizeStruct& ArraySizeStruct::operator =( - ArraySizeStruct&& x) noexcept -{ - - m_my_array = std::move(x.m_my_array); - return *this; -} - -bool ArraySizeStruct::operator ==( - const ArraySizeStruct& x) const -{ - return (m_my_array == x.m_my_array); -} - -bool ArraySizeStruct::operator !=( - const ArraySizeStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_array - * @param _my_array New value to be copied in member my_array - */ -void ArraySizeStruct::my_array( - const std::array& _my_array) -{ - m_my_array = _my_array; -} - -/*! - * @brief This function moves the value in member my_array - * @param _my_array New value to be moved in member my_array - */ -void ArraySizeStruct::my_array( - std::array&& _my_array) -{ - m_my_array = std::move(_my_array); -} - -/*! - * @brief This function returns a constant reference to member my_array - * @return Constant reference to member my_array - */ -const std::array& ArraySizeStruct::my_array() const -{ - return m_my_array; -} - -/*! - * @brief This function returns a reference to member my_array - * @return Reference to member my_array - */ -std::array& ArraySizeStruct::my_array() -{ - return m_my_array; -} - - - - - - -SequenceStruct::SequenceStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -SequenceStruct::~SequenceStruct() -{ -} - -SequenceStruct::SequenceStruct( - const SequenceStruct& x) -{ - m_my_sequence = x.m_my_sequence; -} - -SequenceStruct::SequenceStruct( - SequenceStruct&& x) noexcept -{ - m_my_sequence = std::move(x.m_my_sequence); -} - -SequenceStruct& SequenceStruct::operator =( - const SequenceStruct& x) -{ - - m_my_sequence = x.m_my_sequence; - return *this; -} - -SequenceStruct& SequenceStruct::operator =( - SequenceStruct&& x) noexcept -{ - - m_my_sequence = std::move(x.m_my_sequence); - return *this; -} - -bool SequenceStruct::operator ==( - const SequenceStruct& x) const -{ - return (m_my_sequence == x.m_my_sequence); -} - -bool SequenceStruct::operator !=( - const SequenceStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_sequence - * @param _my_sequence New value to be copied in member my_sequence - */ -void SequenceStruct::my_sequence( - const std::vector& _my_sequence) -{ - m_my_sequence = _my_sequence; -} - -/*! - * @brief This function moves the value in member my_sequence - * @param _my_sequence New value to be moved in member my_sequence - */ -void SequenceStruct::my_sequence( - std::vector&& _my_sequence) -{ - m_my_sequence = std::move(_my_sequence); -} - -/*! - * @brief This function returns a constant reference to member my_sequence - * @return Constant reference to member my_sequence - */ -const std::vector& SequenceStruct::my_sequence() const -{ - return m_my_sequence; -} - -/*! - * @brief This function returns a reference to member my_sequence - * @return Reference to member my_sequence - */ -std::vector& SequenceStruct::my_sequence() -{ - return m_my_sequence; -} - - - - - - -SequenceStructEqual::SequenceStructEqual() -{ - // Just to register all known types - registerTypesTypes(); -} - -SequenceStructEqual::~SequenceStructEqual() -{ -} - -SequenceStructEqual::SequenceStructEqual( - const SequenceStructEqual& x) -{ - m_my_sequence_equal = x.m_my_sequence_equal; -} - -SequenceStructEqual::SequenceStructEqual( - SequenceStructEqual&& x) noexcept -{ - m_my_sequence_equal = std::move(x.m_my_sequence_equal); -} - -SequenceStructEqual& SequenceStructEqual::operator =( - const SequenceStructEqual& x) -{ - - m_my_sequence_equal = x.m_my_sequence_equal; - return *this; -} - -SequenceStructEqual& SequenceStructEqual::operator =( - SequenceStructEqual&& x) noexcept -{ - - m_my_sequence_equal = std::move(x.m_my_sequence_equal); - return *this; -} - -bool SequenceStructEqual::operator ==( - const SequenceStructEqual& x) const -{ - return (m_my_sequence_equal == x.m_my_sequence_equal); -} - -bool SequenceStructEqual::operator !=( - const SequenceStructEqual& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_sequence_equal - * @param _my_sequence_equal New value to be copied in member my_sequence_equal - */ -void SequenceStructEqual::my_sequence_equal( - const std::vector& _my_sequence_equal) -{ - m_my_sequence_equal = _my_sequence_equal; -} - -/*! - * @brief This function moves the value in member my_sequence_equal - * @param _my_sequence_equal New value to be moved in member my_sequence_equal - */ -void SequenceStructEqual::my_sequence_equal( - std::vector&& _my_sequence_equal) -{ - m_my_sequence_equal = std::move(_my_sequence_equal); -} - -/*! - * @brief This function returns a constant reference to member my_sequence_equal - * @return Constant reference to member my_sequence_equal - */ -const std::vector& SequenceStructEqual::my_sequence_equal() const -{ - return m_my_sequence_equal; -} - -/*! - * @brief This function returns a reference to member my_sequence_equal - * @return Reference to member my_sequence_equal - */ -std::vector& SequenceStructEqual::my_sequence_equal() -{ - return m_my_sequence_equal; -} - - - - - - -SequenceBadStruct::SequenceBadStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -SequenceBadStruct::~SequenceBadStruct() -{ -} - -SequenceBadStruct::SequenceBadStruct( - const SequenceBadStruct& x) -{ - m_my_sequence = x.m_my_sequence; -} - -SequenceBadStruct::SequenceBadStruct( - SequenceBadStruct&& x) noexcept -{ - m_my_sequence = std::move(x.m_my_sequence); -} - -SequenceBadStruct& SequenceBadStruct::operator =( - const SequenceBadStruct& x) -{ - - m_my_sequence = x.m_my_sequence; - return *this; -} - -SequenceBadStruct& SequenceBadStruct::operator =( - SequenceBadStruct&& x) noexcept -{ - - m_my_sequence = std::move(x.m_my_sequence); - return *this; -} - -bool SequenceBadStruct::operator ==( - const SequenceBadStruct& x) const -{ - return (m_my_sequence == x.m_my_sequence); -} - -bool SequenceBadStruct::operator !=( - const SequenceBadStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_sequence - * @param _my_sequence New value to be copied in member my_sequence - */ -void SequenceBadStruct::my_sequence( - const std::vector& _my_sequence) -{ - m_my_sequence = _my_sequence; -} - -/*! - * @brief This function moves the value in member my_sequence - * @param _my_sequence New value to be moved in member my_sequence - */ -void SequenceBadStruct::my_sequence( - std::vector&& _my_sequence) -{ - m_my_sequence = std::move(_my_sequence); -} - -/*! - * @brief This function returns a constant reference to member my_sequence - * @return Constant reference to member my_sequence - */ -const std::vector& SequenceBadStruct::my_sequence() const -{ - return m_my_sequence; -} - -/*! - * @brief This function returns a reference to member my_sequence - * @return Reference to member my_sequence - */ -std::vector& SequenceBadStruct::my_sequence() -{ - return m_my_sequence; -} - - - - - - -SequenceBoundsStruct::SequenceBoundsStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -SequenceBoundsStruct::~SequenceBoundsStruct() -{ -} - -SequenceBoundsStruct::SequenceBoundsStruct( - const SequenceBoundsStruct& x) -{ - m_my_sequence = x.m_my_sequence; -} - -SequenceBoundsStruct::SequenceBoundsStruct( - SequenceBoundsStruct&& x) noexcept -{ - m_my_sequence = std::move(x.m_my_sequence); -} - -SequenceBoundsStruct& SequenceBoundsStruct::operator =( - const SequenceBoundsStruct& x) -{ - - m_my_sequence = x.m_my_sequence; - return *this; -} - -SequenceBoundsStruct& SequenceBoundsStruct::operator =( - SequenceBoundsStruct&& x) noexcept -{ - - m_my_sequence = std::move(x.m_my_sequence); - return *this; -} - -bool SequenceBoundsStruct::operator ==( - const SequenceBoundsStruct& x) const -{ - return (m_my_sequence == x.m_my_sequence); -} - -bool SequenceBoundsStruct::operator !=( - const SequenceBoundsStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_sequence - * @param _my_sequence New value to be copied in member my_sequence - */ -void SequenceBoundsStruct::my_sequence( - const std::vector& _my_sequence) -{ - m_my_sequence = _my_sequence; -} - -/*! - * @brief This function moves the value in member my_sequence - * @param _my_sequence New value to be moved in member my_sequence - */ -void SequenceBoundsStruct::my_sequence( - std::vector&& _my_sequence) -{ - m_my_sequence = std::move(_my_sequence); -} - -/*! - * @brief This function returns a constant reference to member my_sequence - * @return Constant reference to member my_sequence - */ -const std::vector& SequenceBoundsStruct::my_sequence() const -{ - return m_my_sequence; -} - -/*! - * @brief This function returns a reference to member my_sequence - * @return Reference to member my_sequence - */ -std::vector& SequenceBoundsStruct::my_sequence() -{ - return m_my_sequence; -} - - - - - - - - -SequenceSequenceStruct::SequenceSequenceStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -SequenceSequenceStruct::~SequenceSequenceStruct() -{ -} - -SequenceSequenceStruct::SequenceSequenceStruct( - const SequenceSequenceStruct& x) -{ - m_my_sequence_sequence = x.m_my_sequence_sequence; -} - -SequenceSequenceStruct::SequenceSequenceStruct( - SequenceSequenceStruct&& x) noexcept -{ - m_my_sequence_sequence = std::move(x.m_my_sequence_sequence); -} - -SequenceSequenceStruct& SequenceSequenceStruct::operator =( - const SequenceSequenceStruct& x) -{ - - m_my_sequence_sequence = x.m_my_sequence_sequence; - return *this; -} - -SequenceSequenceStruct& SequenceSequenceStruct::operator =( - SequenceSequenceStruct&& x) noexcept -{ - - m_my_sequence_sequence = std::move(x.m_my_sequence_sequence); - return *this; -} - -bool SequenceSequenceStruct::operator ==( - const SequenceSequenceStruct& x) const -{ - return (m_my_sequence_sequence == x.m_my_sequence_sequence); -} - -bool SequenceSequenceStruct::operator !=( - const SequenceSequenceStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_sequence_sequence - * @param _my_sequence_sequence New value to be copied in member my_sequence_sequence - */ -void SequenceSequenceStruct::my_sequence_sequence( - const std::vector>& _my_sequence_sequence) -{ - m_my_sequence_sequence = _my_sequence_sequence; -} - -/*! - * @brief This function moves the value in member my_sequence_sequence - * @param _my_sequence_sequence New value to be moved in member my_sequence_sequence - */ -void SequenceSequenceStruct::my_sequence_sequence( - std::vector>&& _my_sequence_sequence) -{ - m_my_sequence_sequence = std::move(_my_sequence_sequence); -} - -/*! - * @brief This function returns a constant reference to member my_sequence_sequence - * @return Constant reference to member my_sequence_sequence - */ -const std::vector>& SequenceSequenceStruct::my_sequence_sequence() const -{ - return m_my_sequence_sequence; -} - -/*! - * @brief This function returns a reference to member my_sequence_sequence - * @return Reference to member my_sequence_sequence - */ -std::vector>& SequenceSequenceStruct::my_sequence_sequence() -{ - return m_my_sequence_sequence; -} - - - - - - - - -SequenceSequenceBoundsStruct::SequenceSequenceBoundsStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -SequenceSequenceBoundsStruct::~SequenceSequenceBoundsStruct() -{ -} - -SequenceSequenceBoundsStruct::SequenceSequenceBoundsStruct( - const SequenceSequenceBoundsStruct& x) -{ - m_my_sequence_sequence = x.m_my_sequence_sequence; -} - -SequenceSequenceBoundsStruct::SequenceSequenceBoundsStruct( - SequenceSequenceBoundsStruct&& x) noexcept -{ - m_my_sequence_sequence = std::move(x.m_my_sequence_sequence); -} - -SequenceSequenceBoundsStruct& SequenceSequenceBoundsStruct::operator =( - const SequenceSequenceBoundsStruct& x) -{ - - m_my_sequence_sequence = x.m_my_sequence_sequence; - return *this; -} - -SequenceSequenceBoundsStruct& SequenceSequenceBoundsStruct::operator =( - SequenceSequenceBoundsStruct&& x) noexcept -{ - - m_my_sequence_sequence = std::move(x.m_my_sequence_sequence); - return *this; -} - -bool SequenceSequenceBoundsStruct::operator ==( - const SequenceSequenceBoundsStruct& x) const -{ - return (m_my_sequence_sequence == x.m_my_sequence_sequence); -} - -bool SequenceSequenceBoundsStruct::operator !=( - const SequenceSequenceBoundsStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_sequence_sequence - * @param _my_sequence_sequence New value to be copied in member my_sequence_sequence - */ -void SequenceSequenceBoundsStruct::my_sequence_sequence( - const std::vector>& _my_sequence_sequence) -{ - m_my_sequence_sequence = _my_sequence_sequence; -} - -/*! - * @brief This function moves the value in member my_sequence_sequence - * @param _my_sequence_sequence New value to be moved in member my_sequence_sequence - */ -void SequenceSequenceBoundsStruct::my_sequence_sequence( - std::vector>&& _my_sequence_sequence) -{ - m_my_sequence_sequence = std::move(_my_sequence_sequence); -} - -/*! - * @brief This function returns a constant reference to member my_sequence_sequence - * @return Constant reference to member my_sequence_sequence - */ -const std::vector>& SequenceSequenceBoundsStruct::my_sequence_sequence() const -{ - return m_my_sequence_sequence; -} - -/*! - * @brief This function returns a reference to member my_sequence_sequence - * @return Reference to member my_sequence_sequence - */ -std::vector>& SequenceSequenceBoundsStruct::my_sequence_sequence() -{ - return m_my_sequence_sequence; -} - - - - - - -MapStruct::MapStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -MapStruct::~MapStruct() -{ -} - -MapStruct::MapStruct( - const MapStruct& x) -{ - m_my_map = x.m_my_map; -} - -MapStruct::MapStruct( - MapStruct&& x) noexcept -{ - m_my_map = std::move(x.m_my_map); -} - -MapStruct& MapStruct::operator =( - const MapStruct& x) -{ - - m_my_map = x.m_my_map; - return *this; -} - -MapStruct& MapStruct::operator =( - MapStruct&& x) noexcept -{ - - m_my_map = std::move(x.m_my_map); - return *this; -} - -bool MapStruct::operator ==( - const MapStruct& x) const -{ - return (m_my_map == x.m_my_map); -} - -bool MapStruct::operator !=( - const MapStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_map - * @param _my_map New value to be copied in member my_map - */ -void MapStruct::my_map( - const std::map& _my_map) -{ - m_my_map = _my_map; -} - -/*! - * @brief This function moves the value in member my_map - * @param _my_map New value to be moved in member my_map - */ -void MapStruct::my_map( - std::map&& _my_map) -{ - m_my_map = std::move(_my_map); -} - -/*! - * @brief This function returns a constant reference to member my_map - * @return Constant reference to member my_map - */ -const std::map& MapStruct::my_map() const -{ - return m_my_map; -} - -/*! - * @brief This function returns a reference to member my_map - * @return Reference to member my_map - */ -std::map& MapStruct::my_map() -{ - return m_my_map; -} - - - - - - -MapStructEqual::MapStructEqual() -{ - // Just to register all known types - registerTypesTypes(); -} - -MapStructEqual::~MapStructEqual() -{ -} - -MapStructEqual::MapStructEqual( - const MapStructEqual& x) -{ - m_my_map_equal = x.m_my_map_equal; -} - -MapStructEqual::MapStructEqual( - MapStructEqual&& x) noexcept -{ - m_my_map_equal = std::move(x.m_my_map_equal); -} - -MapStructEqual& MapStructEqual::operator =( - const MapStructEqual& x) -{ - - m_my_map_equal = x.m_my_map_equal; - return *this; -} - -MapStructEqual& MapStructEqual::operator =( - MapStructEqual&& x) noexcept -{ - - m_my_map_equal = std::move(x.m_my_map_equal); - return *this; -} - -bool MapStructEqual::operator ==( - const MapStructEqual& x) const -{ - return (m_my_map_equal == x.m_my_map_equal); -} - -bool MapStructEqual::operator !=( - const MapStructEqual& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_map_equal - * @param _my_map_equal New value to be copied in member my_map_equal - */ -void MapStructEqual::my_map_equal( - const std::map& _my_map_equal) -{ - m_my_map_equal = _my_map_equal; -} - -/*! - * @brief This function moves the value in member my_map_equal - * @param _my_map_equal New value to be moved in member my_map_equal - */ -void MapStructEqual::my_map_equal( - std::map&& _my_map_equal) -{ - m_my_map_equal = std::move(_my_map_equal); -} - -/*! - * @brief This function returns a constant reference to member my_map_equal - * @return Constant reference to member my_map_equal - */ -const std::map& MapStructEqual::my_map_equal() const -{ - return m_my_map_equal; -} - -/*! - * @brief This function returns a reference to member my_map_equal - * @return Reference to member my_map_equal - */ -std::map& MapStructEqual::my_map_equal() -{ - return m_my_map_equal; -} - - - - - - -MapBadKeyStruct::MapBadKeyStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -MapBadKeyStruct::~MapBadKeyStruct() -{ -} - -MapBadKeyStruct::MapBadKeyStruct( - const MapBadKeyStruct& x) -{ - m_my_map = x.m_my_map; -} - -MapBadKeyStruct::MapBadKeyStruct( - MapBadKeyStruct&& x) noexcept -{ - m_my_map = std::move(x.m_my_map); -} - -MapBadKeyStruct& MapBadKeyStruct::operator =( - const MapBadKeyStruct& x) -{ - - m_my_map = x.m_my_map; - return *this; -} - -MapBadKeyStruct& MapBadKeyStruct::operator =( - MapBadKeyStruct&& x) noexcept -{ - - m_my_map = std::move(x.m_my_map); - return *this; -} - -bool MapBadKeyStruct::operator ==( - const MapBadKeyStruct& x) const -{ - return (m_my_map == x.m_my_map); -} - -bool MapBadKeyStruct::operator !=( - const MapBadKeyStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_map - * @param _my_map New value to be copied in member my_map - */ -void MapBadKeyStruct::my_map( - const std::map& _my_map) -{ - m_my_map = _my_map; -} - -/*! - * @brief This function moves the value in member my_map - * @param _my_map New value to be moved in member my_map - */ -void MapBadKeyStruct::my_map( - std::map&& _my_map) -{ - m_my_map = std::move(_my_map); -} - -/*! - * @brief This function returns a constant reference to member my_map - * @return Constant reference to member my_map - */ -const std::map& MapBadKeyStruct::my_map() const -{ - return m_my_map; -} - -/*! - * @brief This function returns a reference to member my_map - * @return Reference to member my_map - */ -std::map& MapBadKeyStruct::my_map() -{ - return m_my_map; -} - - - - - - -MapBadElemStruct::MapBadElemStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -MapBadElemStruct::~MapBadElemStruct() -{ -} - -MapBadElemStruct::MapBadElemStruct( - const MapBadElemStruct& x) -{ - m_my_map = x.m_my_map; -} - -MapBadElemStruct::MapBadElemStruct( - MapBadElemStruct&& x) noexcept -{ - m_my_map = std::move(x.m_my_map); -} - -MapBadElemStruct& MapBadElemStruct::operator =( - const MapBadElemStruct& x) -{ - - m_my_map = x.m_my_map; - return *this; -} - -MapBadElemStruct& MapBadElemStruct::operator =( - MapBadElemStruct&& x) noexcept -{ - - m_my_map = std::move(x.m_my_map); - return *this; -} - -bool MapBadElemStruct::operator ==( - const MapBadElemStruct& x) const -{ - return (m_my_map == x.m_my_map); -} - -bool MapBadElemStruct::operator !=( - const MapBadElemStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_map - * @param _my_map New value to be copied in member my_map - */ -void MapBadElemStruct::my_map( - const std::map& _my_map) -{ - m_my_map = _my_map; -} - -/*! - * @brief This function moves the value in member my_map - * @param _my_map New value to be moved in member my_map - */ -void MapBadElemStruct::my_map( - std::map&& _my_map) -{ - m_my_map = std::move(_my_map); -} - -/*! - * @brief This function returns a constant reference to member my_map - * @return Constant reference to member my_map - */ -const std::map& MapBadElemStruct::my_map() const -{ - return m_my_map; -} - -/*! - * @brief This function returns a reference to member my_map - * @return Reference to member my_map - */ -std::map& MapBadElemStruct::my_map() -{ - return m_my_map; -} - - - - - - -MapBoundsStruct::MapBoundsStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -MapBoundsStruct::~MapBoundsStruct() -{ -} - -MapBoundsStruct::MapBoundsStruct( - const MapBoundsStruct& x) -{ - m_my_map = x.m_my_map; -} - -MapBoundsStruct::MapBoundsStruct( - MapBoundsStruct&& x) noexcept -{ - m_my_map = std::move(x.m_my_map); -} - -MapBoundsStruct& MapBoundsStruct::operator =( - const MapBoundsStruct& x) -{ - - m_my_map = x.m_my_map; - return *this; -} - -MapBoundsStruct& MapBoundsStruct::operator =( - MapBoundsStruct&& x) noexcept -{ - - m_my_map = std::move(x.m_my_map); - return *this; -} - -bool MapBoundsStruct::operator ==( - const MapBoundsStruct& x) const -{ - return (m_my_map == x.m_my_map); -} - -bool MapBoundsStruct::operator !=( - const MapBoundsStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_map - * @param _my_map New value to be copied in member my_map - */ -void MapBoundsStruct::my_map( - const std::map& _my_map) -{ - m_my_map = _my_map; -} - -/*! - * @brief This function moves the value in member my_map - * @param _my_map New value to be moved in member my_map - */ -void MapBoundsStruct::my_map( - std::map&& _my_map) -{ - m_my_map = std::move(_my_map); -} - -/*! - * @brief This function returns a constant reference to member my_map - * @return Constant reference to member my_map - */ -const std::map& MapBoundsStruct::my_map() const -{ - return m_my_map; -} - -/*! - * @brief This function returns a reference to member my_map - * @return Reference to member my_map - */ -std::map& MapBoundsStruct::my_map() -{ - return m_my_map; -} - - - - - - - - -MapMapStruct::MapMapStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -MapMapStruct::~MapMapStruct() -{ -} - -MapMapStruct::MapMapStruct( - const MapMapStruct& x) -{ - m_my_map_map = x.m_my_map_map; -} - -MapMapStruct::MapMapStruct( - MapMapStruct&& x) noexcept -{ - m_my_map_map = std::move(x.m_my_map_map); -} - -MapMapStruct& MapMapStruct::operator =( - const MapMapStruct& x) -{ - - m_my_map_map = x.m_my_map_map; - return *this; -} - -MapMapStruct& MapMapStruct::operator =( - MapMapStruct&& x) noexcept -{ - - m_my_map_map = std::move(x.m_my_map_map); - return *this; -} - -bool MapMapStruct::operator ==( - const MapMapStruct& x) const -{ - return (m_my_map_map == x.m_my_map_map); -} - -bool MapMapStruct::operator !=( - const MapMapStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_map_map - * @param _my_map_map New value to be copied in member my_map_map - */ -void MapMapStruct::my_map_map( - const std::map>& _my_map_map) -{ - m_my_map_map = _my_map_map; -} - -/*! - * @brief This function moves the value in member my_map_map - * @param _my_map_map New value to be moved in member my_map_map - */ -void MapMapStruct::my_map_map( - std::map>&& _my_map_map) -{ - m_my_map_map = std::move(_my_map_map); -} - -/*! - * @brief This function returns a constant reference to member my_map_map - * @return Constant reference to member my_map_map - */ -const std::map>& MapMapStruct::my_map_map() const -{ - return m_my_map_map; -} - -/*! - * @brief This function returns a reference to member my_map_map - * @return Reference to member my_map_map - */ -std::map>& MapMapStruct::my_map_map() -{ - return m_my_map_map; -} - - - - - - - - -MapMapBoundsStruct::MapMapBoundsStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -MapMapBoundsStruct::~MapMapBoundsStruct() -{ -} - -MapMapBoundsStruct::MapMapBoundsStruct( - const MapMapBoundsStruct& x) -{ - m_my_map_map = x.m_my_map_map; -} - -MapMapBoundsStruct::MapMapBoundsStruct( - MapMapBoundsStruct&& x) noexcept -{ - m_my_map_map = std::move(x.m_my_map_map); -} - -MapMapBoundsStruct& MapMapBoundsStruct::operator =( - const MapMapBoundsStruct& x) -{ - - m_my_map_map = x.m_my_map_map; - return *this; -} - -MapMapBoundsStruct& MapMapBoundsStruct::operator =( - MapMapBoundsStruct&& x) noexcept -{ - - m_my_map_map = std::move(x.m_my_map_map); - return *this; -} - -bool MapMapBoundsStruct::operator ==( - const MapMapBoundsStruct& x) const -{ - return (m_my_map_map == x.m_my_map_map); -} - -bool MapMapBoundsStruct::operator !=( - const MapMapBoundsStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_map_map - * @param _my_map_map New value to be copied in member my_map_map - */ -void MapMapBoundsStruct::my_map_map( - const std::map>& _my_map_map) -{ - m_my_map_map = _my_map_map; -} - -/*! - * @brief This function moves the value in member my_map_map - * @param _my_map_map New value to be moved in member my_map_map - */ -void MapMapBoundsStruct::my_map_map( - std::map>&& _my_map_map) -{ - m_my_map_map = std::move(_my_map_map); -} - -/*! - * @brief This function returns a constant reference to member my_map_map - * @return Constant reference to member my_map_map - */ -const std::map>& MapMapBoundsStruct::my_map_map() const -{ - return m_my_map_map; -} - -/*! - * @brief This function returns a reference to member my_map_map - * @return Reference to member my_map_map - */ -std::map>& MapMapBoundsStruct::my_map_map() -{ - return m_my_map_map; -} - - - - -SimpleUnion::SimpleUnion() -{ - m__d = A; -} - -SimpleUnion::~SimpleUnion() -{ -} - -SimpleUnion::SimpleUnion( - const SimpleUnion& x) -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } -} - -SimpleUnion::SimpleUnion( - SimpleUnion&& x) noexcept -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } -} - -SimpleUnion& SimpleUnion::operator =( - const SimpleUnion& x) -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } - - return *this; -} - -SimpleUnion& SimpleUnion::operator =( - SimpleUnion&& x) noexcept -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } - - return *this; -} - -bool SimpleUnion::operator ==( - const SimpleUnion& x) const -{ - if (m__d != x.m__d) - { - return false; - } - - switch (m__d) - { - case A: - return (m_first == x.m_first); - break; - - - case B: - return (m_second == x.m_second); - break; - - default: - break; - } - return false; -} - -bool SimpleUnion::operator !=( - const SimpleUnion& x) const -{ - return !(*this == x); -} - -void SimpleUnion::_d( - int32_t __d) -{ - bool b = false; - - switch (m__d) - { - case A: - switch (__d) - { - case A: - b = true; - break; - default: - break; - } - break; - - - case B: - switch (__d) - { - case B: - b = true; - break; - default: - break; - } - break; - - default: - break; - } - - if (!b) - { - throw BadParamException("Discriminator doesn't correspond with the selected union member"); - } - - m__d = __d; -} - -int32_t SimpleUnion::_d() const -{ - return m__d; -} - -int32_t& SimpleUnion::_d() -{ - return m__d; -} - -void SimpleUnion::first( - int32_t _first) -{ - m_first = _first; - m__d = A; - -} - -int32_t SimpleUnion::first() const -{ - bool b = false; - - switch (m__d) - { - case A: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first; -} - -int32_t& SimpleUnion::first() -{ - bool b = false; - - switch (m__d) - { - case A: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first; -} - - -void SimpleUnion::second( - int64_t _second) -{ - m_second = _second; - m__d = B; - -} - -int64_t SimpleUnion::second() const -{ - bool b = false; - - switch (m__d) - { - case B: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second; -} - -int64_t& SimpleUnion::second() -{ - bool b = false; - - switch (m__d) - { - case B: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second; -} - - - - -SimpleUnionNames::SimpleUnionNames() -{ - m__d = A; -} - -SimpleUnionNames::~SimpleUnionNames() -{ -} - -SimpleUnionNames::SimpleUnionNames( - const SimpleUnionNames& x) -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_first_case = x.m_first_case; - break; - - - case B: - m_second_case = x.m_second_case; - break; - - default: - break; - } -} - -SimpleUnionNames::SimpleUnionNames( - SimpleUnionNames&& x) noexcept -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_first_case = x.m_first_case; - break; - - - case B: - m_second_case = x.m_second_case; - break; - - default: - break; - } -} - -SimpleUnionNames& SimpleUnionNames::operator =( - const SimpleUnionNames& x) -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_first_case = x.m_first_case; - break; - - - case B: - m_second_case = x.m_second_case; - break; - - default: - break; - } - - return *this; -} - -SimpleUnionNames& SimpleUnionNames::operator =( - SimpleUnionNames&& x) noexcept -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_first_case = x.m_first_case; - break; - - - case B: - m_second_case = x.m_second_case; - break; - - default: - break; - } - - return *this; -} - -bool SimpleUnionNames::operator ==( - const SimpleUnionNames& x) const -{ - if (m__d != x.m__d) - { - return false; - } - - switch (m__d) - { - case A: - return (m_first_case == x.m_first_case); - break; - - - case B: - return (m_second_case == x.m_second_case); - break; - - default: - break; - } - return false; -} - -bool SimpleUnionNames::operator !=( - const SimpleUnionNames& x) const -{ - return !(*this == x); -} - -void SimpleUnionNames::_d( - int32_t __d) -{ - bool b = false; - - switch (m__d) - { - case A: - switch (__d) - { - case A: - b = true; - break; - default: - break; - } - break; - - - case B: - switch (__d) - { - case B: - b = true; - break; - default: - break; - } - break; - - default: - break; - } - - if (!b) - { - throw BadParamException("Discriminator doesn't correspond with the selected union member"); - } - - m__d = __d; -} - -int32_t SimpleUnionNames::_d() const -{ - return m__d; -} - -int32_t& SimpleUnionNames::_d() -{ - return m__d; -} - -void SimpleUnionNames::first_case( - int32_t _first_case) -{ - m_first_case = _first_case; - m__d = A; - -} - -int32_t SimpleUnionNames::first_case() const -{ - bool b = false; - - switch (m__d) - { - case A: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first_case; -} - -int32_t& SimpleUnionNames::first_case() -{ - bool b = false; - - switch (m__d) - { - case A: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first_case; -} - - -void SimpleUnionNames::second_case( - int64_t _second_case) -{ - m_second_case = _second_case; - m__d = B; - -} - -int64_t SimpleUnionNames::second_case() const -{ - bool b = false; - - switch (m__d) - { - case B: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second_case; -} - -int64_t& SimpleUnionNames::second_case() -{ - bool b = false; - - switch (m__d) - { - case B: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second_case; -} - - - - -SimpleTypeUnion::SimpleTypeUnion() -{ - m__d = A; -} - -SimpleTypeUnion::~SimpleTypeUnion() -{ -} - -SimpleTypeUnion::SimpleTypeUnion( - const SimpleTypeUnion& x) -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } -} - -SimpleTypeUnion::SimpleTypeUnion( - SimpleTypeUnion&& x) noexcept -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } -} - -SimpleTypeUnion& SimpleTypeUnion::operator =( - const SimpleTypeUnion& x) -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } - - return *this; -} - -SimpleTypeUnion& SimpleTypeUnion::operator =( - SimpleTypeUnion&& x) noexcept -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } - - return *this; -} - -bool SimpleTypeUnion::operator ==( - const SimpleTypeUnion& x) const -{ - if (m__d != x.m__d) - { - return false; - } - - switch (m__d) - { - case A: - return (m_first == x.m_first); - break; - - - case B: - return (m_second == x.m_second); - break; - - default: - break; - } - return false; -} - -bool SimpleTypeUnion::operator !=( - const SimpleTypeUnion& x) const -{ - return !(*this == x); -} - -void SimpleTypeUnion::_d( - int32_t __d) -{ - bool b = false; - - switch (m__d) - { - case A: - switch (__d) - { - case A: - b = true; - break; - default: - break; - } - break; - - - case B: - switch (__d) - { - case B: - b = true; - break; - default: - break; - } - break; - - default: - break; - } - - if (!b) - { - throw BadParamException("Discriminator doesn't correspond with the selected union member"); - } - - m__d = __d; -} - -int32_t SimpleTypeUnion::_d() const -{ - return m__d; -} - -int32_t& SimpleTypeUnion::_d() -{ - return m__d; -} - -void SimpleTypeUnion::first( - uint8_t _first) -{ - m_first = _first; - m__d = A; - -} - -uint8_t SimpleTypeUnion::first() const -{ - bool b = false; - - switch (m__d) - { - case A: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first; -} - -uint8_t& SimpleTypeUnion::first() -{ - bool b = false; - - switch (m__d) - { - case A: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first; -} - - -void SimpleTypeUnion::second( - int64_t _second) -{ - m_second = _second; - m__d = B; - -} - -int64_t SimpleTypeUnion::second() const -{ - bool b = false; - - switch (m__d) - { - case B: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second; -} - -int64_t& SimpleTypeUnion::second() -{ - bool b = false; - - switch (m__d) - { - case B: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second; -} - - - - -SimpleBadUnion::SimpleBadUnion() -{ - m__d = A; -} - -SimpleBadUnion::~SimpleBadUnion() -{ -} - -SimpleBadUnion::SimpleBadUnion( - const SimpleBadUnion& x) -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_first = x.m_first; - break; - - - case C: - m_second = x.m_second; - break; - - default: - break; - } -} - -SimpleBadUnion::SimpleBadUnion( - SimpleBadUnion&& x) noexcept -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_first = x.m_first; - break; - - - case C: - m_second = x.m_second; - break; - - default: - break; - } -} - -SimpleBadUnion& SimpleBadUnion::operator =( - const SimpleBadUnion& x) -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_first = x.m_first; - break; - - - case C: - m_second = x.m_second; - break; - - default: - break; - } - - return *this; -} - -SimpleBadUnion& SimpleBadUnion::operator =( - SimpleBadUnion&& x) noexcept -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_first = x.m_first; - break; - - - case C: - m_second = x.m_second; - break; - - default: - break; - } - - return *this; -} - -bool SimpleBadUnion::operator ==( - const SimpleBadUnion& x) const -{ - if (m__d != x.m__d) - { - return false; - } - - switch (m__d) - { - case A: - return (m_first == x.m_first); - break; - - - case C: - return (m_second == x.m_second); - break; - - default: - break; - } - return false; -} - -bool SimpleBadUnion::operator !=( - const SimpleBadUnion& x) const -{ - return !(*this == x); -} - -void SimpleBadUnion::_d( - int32_t __d) -{ - bool b = false; - - switch (m__d) - { - case A: - switch (__d) - { - case A: - b = true; - break; - default: - break; - } - break; - - - case C: - switch (__d) - { - case C: - b = true; - break; - default: - break; - } - break; - - default: - break; - } - - if (!b) - { - throw BadParamException("Discriminator doesn't correspond with the selected union member"); - } - - m__d = __d; -} - -int32_t SimpleBadUnion::_d() const -{ - return m__d; -} - -int32_t& SimpleBadUnion::_d() -{ - return m__d; -} - -void SimpleBadUnion::first( - int32_t _first) -{ - m_first = _first; - m__d = A; - -} - -int32_t SimpleBadUnion::first() const -{ - bool b = false; - - switch (m__d) - { - case A: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first; -} - -int32_t& SimpleBadUnion::first() -{ - bool b = false; - - switch (m__d) - { - case A: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first; -} - - -void SimpleBadUnion::second( - int64_t _second) -{ - m_second = _second; - m__d = C; - -} - -int64_t SimpleBadUnion::second() const -{ - bool b = false; - - switch (m__d) - { - case C: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second; -} - -int64_t& SimpleBadUnion::second() -{ - bool b = false; - - switch (m__d) - { - case C: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second; -} - - - - -SimpleBadDiscUnion::SimpleBadDiscUnion() -{ - m__d = 0; -} - -SimpleBadDiscUnion::~SimpleBadDiscUnion() -{ -} - -SimpleBadDiscUnion::SimpleBadDiscUnion( - const SimpleBadDiscUnion& x) -{ - m__d = x.m__d; - - switch (m__d) - { - case 0: - m_first = x.m_first; - break; - - - case 1: - m_second = x.m_second; - break; - - default: - break; - } -} - -SimpleBadDiscUnion::SimpleBadDiscUnion( - SimpleBadDiscUnion&& x) noexcept -{ - m__d = x.m__d; - - switch (m__d) - { - case 0: - m_first = x.m_first; - break; - - - case 1: - m_second = x.m_second; - break; - - default: - break; - } -} - -SimpleBadDiscUnion& SimpleBadDiscUnion::operator =( - const SimpleBadDiscUnion& x) -{ - m__d = x.m__d; - - switch (m__d) - { - case 0: - m_first = x.m_first; - break; - - - case 1: - m_second = x.m_second; - break; - - default: - break; - } - - return *this; -} - -SimpleBadDiscUnion& SimpleBadDiscUnion::operator =( - SimpleBadDiscUnion&& x) noexcept -{ - m__d = x.m__d; - - switch (m__d) - { - case 0: - m_first = x.m_first; - break; - - - case 1: - m_second = x.m_second; - break; - - default: - break; - } - - return *this; -} - -bool SimpleBadDiscUnion::operator ==( - const SimpleBadDiscUnion& x) const -{ - if (m__d != x.m__d) - { - return false; - } - - switch (m__d) - { - case 0: - return (m_first == x.m_first); - break; - - - case 1: - return (m_second == x.m_second); - break; - - default: - break; - } - return false; -} - -bool SimpleBadDiscUnion::operator !=( - const SimpleBadDiscUnion& x) const -{ - return !(*this == x); -} - -void SimpleBadDiscUnion::_d( - uint8_t __d) -{ - bool b = false; - - switch (m__d) - { - case 0: - switch (__d) - { - case 0: - b = true; - break; - default: - break; - } - break; - - - case 1: - switch (__d) - { - case 1: - b = true; - break; - default: - break; - } - break; - - default: - break; - } - - if (!b) - { - throw BadParamException("Discriminator doesn't correspond with the selected union member"); - } - - m__d = __d; -} - -uint8_t SimpleBadDiscUnion::_d() const -{ - return m__d; -} - -uint8_t& SimpleBadDiscUnion::_d() -{ - return m__d; -} - -void SimpleBadDiscUnion::first( - int32_t _first) -{ - m_first = _first; - m__d = 0; - -} - -int32_t SimpleBadDiscUnion::first() const -{ - bool b = false; - - switch (m__d) - { - case 0: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first; -} - -int32_t& SimpleBadDiscUnion::first() -{ - bool b = false; - - switch (m__d) - { - case 0: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first; -} - - -void SimpleBadDiscUnion::second( - int64_t _second) -{ - m_second = _second; - m__d = 1; - -} - -int64_t SimpleBadDiscUnion::second() const -{ - bool b = false; - - switch (m__d) - { - case 1: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second; -} - -int64_t& SimpleBadDiscUnion::second() -{ - bool b = false; - - switch (m__d) - { - case 1: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second; -} - - - - -SimpleUnionStruct::SimpleUnionStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -SimpleUnionStruct::~SimpleUnionStruct() -{ -} - -SimpleUnionStruct::SimpleUnionStruct( - const SimpleUnionStruct& x) -{ - m_my_union = x.m_my_union; -} - -SimpleUnionStruct::SimpleUnionStruct( - SimpleUnionStruct&& x) noexcept -{ - m_my_union = std::move(x.m_my_union); -} - -SimpleUnionStruct& SimpleUnionStruct::operator =( - const SimpleUnionStruct& x) -{ - - m_my_union = x.m_my_union; - return *this; -} - -SimpleUnionStruct& SimpleUnionStruct::operator =( - SimpleUnionStruct&& x) noexcept -{ - - m_my_union = std::move(x.m_my_union); - return *this; -} - -bool SimpleUnionStruct::operator ==( - const SimpleUnionStruct& x) const -{ - return (m_my_union == x.m_my_union); -} - -bool SimpleUnionStruct::operator !=( - const SimpleUnionStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ -void SimpleUnionStruct::my_union( - const SimpleUnion& _my_union) -{ - m_my_union = _my_union; -} - -/*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ -void SimpleUnionStruct::my_union( - SimpleUnion&& _my_union) -{ - m_my_union = std::move(_my_union); -} - -/*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ -const SimpleUnion& SimpleUnionStruct::my_union() const -{ - return m_my_union; -} - -/*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ -SimpleUnion& SimpleUnionStruct::my_union() -{ - return m_my_union; -} - - - - -SimpleUnionStructEqual::SimpleUnionStructEqual() -{ - // Just to register all known types - registerTypesTypes(); -} - -SimpleUnionStructEqual::~SimpleUnionStructEqual() -{ -} - -SimpleUnionStructEqual::SimpleUnionStructEqual( - const SimpleUnionStructEqual& x) -{ - m_my_union_equal = x.m_my_union_equal; -} - -SimpleUnionStructEqual::SimpleUnionStructEqual( - SimpleUnionStructEqual&& x) noexcept -{ - m_my_union_equal = std::move(x.m_my_union_equal); -} - -SimpleUnionStructEqual& SimpleUnionStructEqual::operator =( - const SimpleUnionStructEqual& x) -{ - - m_my_union_equal = x.m_my_union_equal; - return *this; -} - -SimpleUnionStructEqual& SimpleUnionStructEqual::operator =( - SimpleUnionStructEqual&& x) noexcept -{ - - m_my_union_equal = std::move(x.m_my_union_equal); - return *this; -} - -bool SimpleUnionStructEqual::operator ==( - const SimpleUnionStructEqual& x) const -{ - return (m_my_union_equal == x.m_my_union_equal); -} - -bool SimpleUnionStructEqual::operator !=( - const SimpleUnionStructEqual& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_union_equal - * @param _my_union_equal New value to be copied in member my_union_equal - */ -void SimpleUnionStructEqual::my_union_equal( - const SimpleUnion& _my_union_equal) -{ - m_my_union_equal = _my_union_equal; -} - -/*! - * @brief This function moves the value in member my_union_equal - * @param _my_union_equal New value to be moved in member my_union_equal - */ -void SimpleUnionStructEqual::my_union_equal( - SimpleUnion&& _my_union_equal) -{ - m_my_union_equal = std::move(_my_union_equal); -} - -/*! - * @brief This function returns a constant reference to member my_union_equal - * @return Constant reference to member my_union_equal - */ -const SimpleUnion& SimpleUnionStructEqual::my_union_equal() const -{ - return m_my_union_equal; -} - -/*! - * @brief This function returns a reference to member my_union_equal - * @return Reference to member my_union_equal - */ -SimpleUnion& SimpleUnionStructEqual::my_union_equal() -{ - return m_my_union_equal; -} - - - - -SimpleUnionNamesStruct::SimpleUnionNamesStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -SimpleUnionNamesStruct::~SimpleUnionNamesStruct() -{ -} - -SimpleUnionNamesStruct::SimpleUnionNamesStruct( - const SimpleUnionNamesStruct& x) -{ - m_my_union = x.m_my_union; -} - -SimpleUnionNamesStruct::SimpleUnionNamesStruct( - SimpleUnionNamesStruct&& x) noexcept -{ - m_my_union = std::move(x.m_my_union); -} - -SimpleUnionNamesStruct& SimpleUnionNamesStruct::operator =( - const SimpleUnionNamesStruct& x) -{ - - m_my_union = x.m_my_union; - return *this; -} - -SimpleUnionNamesStruct& SimpleUnionNamesStruct::operator =( - SimpleUnionNamesStruct&& x) noexcept -{ - - m_my_union = std::move(x.m_my_union); - return *this; -} - -bool SimpleUnionNamesStruct::operator ==( - const SimpleUnionNamesStruct& x) const -{ - return (m_my_union == x.m_my_union); -} - -bool SimpleUnionNamesStruct::operator !=( - const SimpleUnionNamesStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ -void SimpleUnionNamesStruct::my_union( - const SimpleUnionNames& _my_union) -{ - m_my_union = _my_union; -} - -/*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ -void SimpleUnionNamesStruct::my_union( - SimpleUnionNames&& _my_union) -{ - m_my_union = std::move(_my_union); -} - -/*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ -const SimpleUnionNames& SimpleUnionNamesStruct::my_union() const -{ - return m_my_union; -} - -/*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ -SimpleUnionNames& SimpleUnionNamesStruct::my_union() -{ - return m_my_union; -} - - - - -SimpleTypeUnionStruct::SimpleTypeUnionStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -SimpleTypeUnionStruct::~SimpleTypeUnionStruct() -{ -} - -SimpleTypeUnionStruct::SimpleTypeUnionStruct( - const SimpleTypeUnionStruct& x) -{ - m_my_union = x.m_my_union; -} - -SimpleTypeUnionStruct::SimpleTypeUnionStruct( - SimpleTypeUnionStruct&& x) noexcept -{ - m_my_union = std::move(x.m_my_union); -} - -SimpleTypeUnionStruct& SimpleTypeUnionStruct::operator =( - const SimpleTypeUnionStruct& x) -{ - - m_my_union = x.m_my_union; - return *this; -} - -SimpleTypeUnionStruct& SimpleTypeUnionStruct::operator =( - SimpleTypeUnionStruct&& x) noexcept -{ - - m_my_union = std::move(x.m_my_union); - return *this; -} - -bool SimpleTypeUnionStruct::operator ==( - const SimpleTypeUnionStruct& x) const -{ - return (m_my_union == x.m_my_union); -} - -bool SimpleTypeUnionStruct::operator !=( - const SimpleTypeUnionStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ -void SimpleTypeUnionStruct::my_union( - const SimpleTypeUnion& _my_union) -{ - m_my_union = _my_union; -} - -/*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ -void SimpleTypeUnionStruct::my_union( - SimpleTypeUnion&& _my_union) -{ - m_my_union = std::move(_my_union); -} - -/*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ -const SimpleTypeUnion& SimpleTypeUnionStruct::my_union() const -{ - return m_my_union; -} - -/*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ -SimpleTypeUnion& SimpleTypeUnionStruct::my_union() -{ - return m_my_union; -} - - - - -SimpleBadUnionStruct::SimpleBadUnionStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -SimpleBadUnionStruct::~SimpleBadUnionStruct() -{ -} - -SimpleBadUnionStruct::SimpleBadUnionStruct( - const SimpleBadUnionStruct& x) -{ - m_my_union = x.m_my_union; -} - -SimpleBadUnionStruct::SimpleBadUnionStruct( - SimpleBadUnionStruct&& x) noexcept -{ - m_my_union = std::move(x.m_my_union); -} - -SimpleBadUnionStruct& SimpleBadUnionStruct::operator =( - const SimpleBadUnionStruct& x) -{ - - m_my_union = x.m_my_union; - return *this; -} - -SimpleBadUnionStruct& SimpleBadUnionStruct::operator =( - SimpleBadUnionStruct&& x) noexcept -{ - - m_my_union = std::move(x.m_my_union); - return *this; -} - -bool SimpleBadUnionStruct::operator ==( - const SimpleBadUnionStruct& x) const -{ - return (m_my_union == x.m_my_union); -} - -bool SimpleBadUnionStruct::operator !=( - const SimpleBadUnionStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ -void SimpleBadUnionStruct::my_union( - const SimpleBadUnion& _my_union) -{ - m_my_union = _my_union; -} - -/*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ -void SimpleBadUnionStruct::my_union( - SimpleBadUnion&& _my_union) -{ - m_my_union = std::move(_my_union); -} - -/*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ -const SimpleBadUnion& SimpleBadUnionStruct::my_union() const -{ - return m_my_union; -} - -/*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ -SimpleBadUnion& SimpleBadUnionStruct::my_union() -{ - return m_my_union; -} - - - - -SimplBadDiscUnionStruct::SimplBadDiscUnionStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -SimplBadDiscUnionStruct::~SimplBadDiscUnionStruct() -{ -} - -SimplBadDiscUnionStruct::SimplBadDiscUnionStruct( - const SimplBadDiscUnionStruct& x) -{ - m_my_union = x.m_my_union; -} - -SimplBadDiscUnionStruct::SimplBadDiscUnionStruct( - SimplBadDiscUnionStruct&& x) noexcept -{ - m_my_union = std::move(x.m_my_union); -} - -SimplBadDiscUnionStruct& SimplBadDiscUnionStruct::operator =( - const SimplBadDiscUnionStruct& x) -{ - - m_my_union = x.m_my_union; - return *this; -} - -SimplBadDiscUnionStruct& SimplBadDiscUnionStruct::operator =( - SimplBadDiscUnionStruct&& x) noexcept -{ - - m_my_union = std::move(x.m_my_union); - return *this; -} - -bool SimplBadDiscUnionStruct::operator ==( - const SimplBadDiscUnionStruct& x) const -{ - return (m_my_union == x.m_my_union); -} - -bool SimplBadDiscUnionStruct::operator !=( - const SimplBadDiscUnionStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ -void SimplBadDiscUnionStruct::my_union( - const SimpleBadDiscUnion& _my_union) -{ - m_my_union = _my_union; -} - -/*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ -void SimplBadDiscUnionStruct::my_union( - SimpleBadDiscUnion&& _my_union) -{ - m_my_union = std::move(_my_union); -} - -/*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ -const SimpleBadDiscUnion& SimplBadDiscUnionStruct::my_union() const -{ - return m_my_union; -} - -/*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ -SimpleBadDiscUnion& SimplBadDiscUnionStruct::my_union() -{ - return m_my_union; -} - - -// Include auxiliary functions like for serializing/deserializing. -#include "TypesCdrAux.ipp" - -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/test/unittest/xtypes/idl/Types.h b/test/unittest/xtypes/idl/Types.h deleted file mode 100644 index e482676e515..00000000000 --- a/test/unittest/xtypes/idl/Types.h +++ /dev/null @@ -1,4432 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file Types.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#include -#include "Typesv1.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#ifndef _FAST_DDS_GENERATED_TYPES_H_ -#define _FAST_DDS_GENERATED_TYPES_H_ - -#include -#include -#include -#include -#include -#include - -#include -#include -#include - - - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define eProsima_user_DllExport -#endif // _WIN32 - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(TYPES_SOURCE) -#define TYPES_DllAPI __declspec( dllexport ) -#else -#define TYPES_DllAPI __declspec( dllimport ) -#endif // TYPES_SOURCE -#else -#define TYPES_DllAPI -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define TYPES_DllAPI -#endif // _WIN32 - -namespace eprosima { -namespace fastcdr { -class Cdr; -class CdrSizeCalculator; -} // namespace fastcdr -} // namespace eprosima - - - -/*! - * @brief This class represents the enumeration MyEnum defined by the user in the IDL file. - * @ingroup Types - */ -enum MyEnum : uint32_t -{ - A, - B, - C -}; -/*! - * @brief This class represents the enumeration MyBadEnum defined by the user in the IDL file. - * @ingroup Types - */ -enum MyBadEnum : uint32_t -{ - A1, - B1, - C1 -}; - - -/*! - * @brief This class represents the structure MyEnumStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MyEnumStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MyEnumStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MyEnumStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MyEnumStruct that will be copied. - */ - eProsima_user_DllExport MyEnumStruct( - const MyEnumStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MyEnumStruct that will be copied. - */ - eProsima_user_DllExport MyEnumStruct( - MyEnumStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MyEnumStruct that will be copied. - */ - eProsima_user_DllExport MyEnumStruct& operator =( - const MyEnumStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MyEnumStruct that will be copied. - */ - eProsima_user_DllExport MyEnumStruct& operator =( - MyEnumStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MyEnumStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MyEnumStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x MyEnumStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MyEnumStruct& x) const; - - /*! - * @brief This function sets a value in member my_enum - * @param _my_enum New value for member my_enum - */ - eProsima_user_DllExport void my_enum( - MyEnum _my_enum); - - /*! - * @brief This function returns the value of member my_enum - * @return Value of member my_enum - */ - eProsima_user_DllExport MyEnum my_enum() const; - - /*! - * @brief This function returns a reference to member my_enum - * @return Reference to member my_enum - */ - eProsima_user_DllExport MyEnum& my_enum(); - -private: - - MyEnum m_my_enum{::A}; - -}; - - -/*! - * @brief This class represents the structure MyBadEnumStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MyBadEnumStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MyBadEnumStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MyBadEnumStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MyBadEnumStruct that will be copied. - */ - eProsima_user_DllExport MyBadEnumStruct( - const MyBadEnumStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MyBadEnumStruct that will be copied. - */ - eProsima_user_DllExport MyBadEnumStruct( - MyBadEnumStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MyBadEnumStruct that will be copied. - */ - eProsima_user_DllExport MyBadEnumStruct& operator =( - const MyBadEnumStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MyBadEnumStruct that will be copied. - */ - eProsima_user_DllExport MyBadEnumStruct& operator =( - MyBadEnumStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MyBadEnumStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MyBadEnumStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x MyBadEnumStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MyBadEnumStruct& x) const; - - /*! - * @brief This function sets a value in member my_enum - * @param _my_enum New value for member my_enum - */ - eProsima_user_DllExport void my_enum( - MyBadEnum _my_enum); - - /*! - * @brief This function returns the value of member my_enum - * @return Value of member my_enum - */ - eProsima_user_DllExport MyBadEnum my_enum() const; - - /*! - * @brief This function returns a reference to member my_enum - * @return Reference to member my_enum - */ - eProsima_user_DllExport MyBadEnum& my_enum(); - -private: - - MyBadEnum m_my_enum{::A1}; - -}; -typedef MyEnum MyAliasEnum; - - - -/*! - * @brief This class represents the structure MyAliasEnumStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MyAliasEnumStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MyAliasEnumStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MyAliasEnumStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MyAliasEnumStruct that will be copied. - */ - eProsima_user_DllExport MyAliasEnumStruct( - const MyAliasEnumStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MyAliasEnumStruct that will be copied. - */ - eProsima_user_DllExport MyAliasEnumStruct( - MyAliasEnumStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MyAliasEnumStruct that will be copied. - */ - eProsima_user_DllExport MyAliasEnumStruct& operator =( - const MyAliasEnumStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MyAliasEnumStruct that will be copied. - */ - eProsima_user_DllExport MyAliasEnumStruct& operator =( - MyAliasEnumStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MyAliasEnumStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MyAliasEnumStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x MyAliasEnumStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MyAliasEnumStruct& x) const; - - /*! - * @brief This function sets a value in member my_enum - * @param _my_enum New value for member my_enum - */ - eProsima_user_DllExport void my_enum( - MyAliasEnum _my_enum); - - /*! - * @brief This function returns the value of member my_enum - * @return Value of member my_enum - */ - eProsima_user_DllExport MyAliasEnum my_enum() const; - - /*! - * @brief This function returns a reference to member my_enum - * @return Reference to member my_enum - */ - eProsima_user_DllExport MyAliasEnum& my_enum(); - -private: - - MyAliasEnum m_my_enum{::A}; - -}; - - -/*! - * @brief This class represents the structure BasicStruct defined by the user in the IDL file. - * @ingroup Types - */ -class BasicStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport BasicStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~BasicStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object BasicStruct that will be copied. - */ - eProsima_user_DllExport BasicStruct( - const BasicStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object BasicStruct that will be copied. - */ - eProsima_user_DllExport BasicStruct( - BasicStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object BasicStruct that will be copied. - */ - eProsima_user_DllExport BasicStruct& operator =( - const BasicStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object BasicStruct that will be copied. - */ - eProsima_user_DllExport BasicStruct& operator =( - BasicStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x BasicStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const BasicStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x BasicStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const BasicStruct& x) const; - - /*! - * @brief This function sets a value in member my_bool - * @param _my_bool New value for member my_bool - */ - eProsima_user_DllExport void my_bool( - bool _my_bool); - - /*! - * @brief This function returns the value of member my_bool - * @return Value of member my_bool - */ - eProsima_user_DllExport bool my_bool() const; - - /*! - * @brief This function returns a reference to member my_bool - * @return Reference to member my_bool - */ - eProsima_user_DllExport bool& my_bool(); - - - /*! - * @brief This function sets a value in member my_int32 - * @param _my_int32 New value for member my_int32 - */ - eProsima_user_DllExport void my_int32( - int32_t _my_int32); - - /*! - * @brief This function returns the value of member my_int32 - * @return Value of member my_int32 - */ - eProsima_user_DllExport int32_t my_int32() const; - - /*! - * @brief This function returns a reference to member my_int32 - * @return Reference to member my_int32 - */ - eProsima_user_DllExport int32_t& my_int32(); - - - /*! - * @brief This function copies the value in member my_string - * @param _my_string New value to be copied in member my_string - */ - eProsima_user_DllExport void my_string( - const std::string& _my_string); - - /*! - * @brief This function moves the value in member my_string - * @param _my_string New value to be moved in member my_string - */ - eProsima_user_DllExport void my_string( - std::string&& _my_string); - - /*! - * @brief This function returns a constant reference to member my_string - * @return Constant reference to member my_string - */ - eProsima_user_DllExport const std::string& my_string() const; - - /*! - * @brief This function returns a reference to member my_string - * @return Reference to member my_string - */ - eProsima_user_DllExport std::string& my_string(); - -private: - - bool m_my_bool{false}; - int32_t m_my_int32{0}; - std::string m_my_string; - -}; - - -/*! - * @brief This class represents the structure BasicNamesStruct defined by the user in the IDL file. - * @ingroup Types - */ -class BasicNamesStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport BasicNamesStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~BasicNamesStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object BasicNamesStruct that will be copied. - */ - eProsima_user_DllExport BasicNamesStruct( - const BasicNamesStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object BasicNamesStruct that will be copied. - */ - eProsima_user_DllExport BasicNamesStruct( - BasicNamesStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object BasicNamesStruct that will be copied. - */ - eProsima_user_DllExport BasicNamesStruct& operator =( - const BasicNamesStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object BasicNamesStruct that will be copied. - */ - eProsima_user_DllExport BasicNamesStruct& operator =( - BasicNamesStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x BasicNamesStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const BasicNamesStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x BasicNamesStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const BasicNamesStruct& x) const; - - /*! - * @brief This function sets a value in member my_bool_name - * @param _my_bool_name New value for member my_bool_name - */ - eProsima_user_DllExport void my_bool_name( - bool _my_bool_name); - - /*! - * @brief This function returns the value of member my_bool_name - * @return Value of member my_bool_name - */ - eProsima_user_DllExport bool my_bool_name() const; - - /*! - * @brief This function returns a reference to member my_bool_name - * @return Reference to member my_bool_name - */ - eProsima_user_DllExport bool& my_bool_name(); - - - /*! - * @brief This function sets a value in member my_int32_name - * @param _my_int32_name New value for member my_int32_name - */ - eProsima_user_DllExport void my_int32_name( - int32_t _my_int32_name); - - /*! - * @brief This function returns the value of member my_int32_name - * @return Value of member my_int32_name - */ - eProsima_user_DllExport int32_t my_int32_name() const; - - /*! - * @brief This function returns a reference to member my_int32_name - * @return Reference to member my_int32_name - */ - eProsima_user_DllExport int32_t& my_int32_name(); - - - /*! - * @brief This function copies the value in member my_string_name - * @param _my_string_name New value to be copied in member my_string_name - */ - eProsima_user_DllExport void my_string_name( - const std::string& _my_string_name); - - /*! - * @brief This function moves the value in member my_string_name - * @param _my_string_name New value to be moved in member my_string_name - */ - eProsima_user_DllExport void my_string_name( - std::string&& _my_string_name); - - /*! - * @brief This function returns a constant reference to member my_string_name - * @return Constant reference to member my_string_name - */ - eProsima_user_DllExport const std::string& my_string_name() const; - - /*! - * @brief This function returns a reference to member my_string_name - * @return Reference to member my_string_name - */ - eProsima_user_DllExport std::string& my_string_name(); - -private: - - bool m_my_bool_name{false}; - int32_t m_my_int32_name{0}; - std::string m_my_string_name; - -}; - - -/*! - * @brief This class represents the structure BasicBadStruct defined by the user in the IDL file. - * @ingroup Types - */ -class BasicBadStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport BasicBadStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~BasicBadStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object BasicBadStruct that will be copied. - */ - eProsima_user_DllExport BasicBadStruct( - const BasicBadStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object BasicBadStruct that will be copied. - */ - eProsima_user_DllExport BasicBadStruct( - BasicBadStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object BasicBadStruct that will be copied. - */ - eProsima_user_DllExport BasicBadStruct& operator =( - const BasicBadStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object BasicBadStruct that will be copied. - */ - eProsima_user_DllExport BasicBadStruct& operator =( - BasicBadStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x BasicBadStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const BasicBadStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x BasicBadStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const BasicBadStruct& x) const; - - /*! - * @brief This function sets a value in member my_bool - * @param _my_bool New value for member my_bool - */ - eProsima_user_DllExport void my_bool( - uint8_t _my_bool); - - /*! - * @brief This function returns the value of member my_bool - * @return Value of member my_bool - */ - eProsima_user_DllExport uint8_t my_bool() const; - - /*! - * @brief This function returns a reference to member my_bool - * @return Reference to member my_bool - */ - eProsima_user_DllExport uint8_t& my_bool(); - - - /*! - * @brief This function sets a value in member my_int32 - * @param _my_int32 New value for member my_int32 - */ - eProsima_user_DllExport void my_int32( - int32_t _my_int32); - - /*! - * @brief This function returns the value of member my_int32 - * @return Value of member my_int32 - */ - eProsima_user_DllExport int32_t my_int32() const; - - /*! - * @brief This function returns a reference to member my_int32 - * @return Reference to member my_int32 - */ - eProsima_user_DllExport int32_t& my_int32(); - - - /*! - * @brief This function copies the value in member my_string - * @param _my_string New value to be copied in member my_string - */ - eProsima_user_DllExport void my_string( - const std::string& _my_string); - - /*! - * @brief This function moves the value in member my_string - * @param _my_string New value to be moved in member my_string - */ - eProsima_user_DllExport void my_string( - std::string&& _my_string); - - /*! - * @brief This function returns a constant reference to member my_string - * @return Constant reference to member my_string - */ - eProsima_user_DllExport const std::string& my_string() const; - - /*! - * @brief This function returns a reference to member my_string - * @return Reference to member my_string - */ - eProsima_user_DllExport std::string& my_string(); - -private: - - uint8_t m_my_bool{0}; - int32_t m_my_int32{0}; - std::string m_my_string; - -}; - - -/*! - * @brief This class represents the structure BasicWideStruct defined by the user in the IDL file. - * @ingroup Types - */ -class BasicWideStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport BasicWideStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~BasicWideStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object BasicWideStruct that will be copied. - */ - eProsima_user_DllExport BasicWideStruct( - const BasicWideStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object BasicWideStruct that will be copied. - */ - eProsima_user_DllExport BasicWideStruct( - BasicWideStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object BasicWideStruct that will be copied. - */ - eProsima_user_DllExport BasicWideStruct& operator =( - const BasicWideStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object BasicWideStruct that will be copied. - */ - eProsima_user_DllExport BasicWideStruct& operator =( - BasicWideStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x BasicWideStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const BasicWideStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x BasicWideStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const BasicWideStruct& x) const; - - /*! - * @brief This function sets a value in member my_bool - * @param _my_bool New value for member my_bool - */ - eProsima_user_DllExport void my_bool( - bool _my_bool); - - /*! - * @brief This function returns the value of member my_bool - * @return Value of member my_bool - */ - eProsima_user_DllExport bool my_bool() const; - - /*! - * @brief This function returns a reference to member my_bool - * @return Reference to member my_bool - */ - eProsima_user_DllExport bool& my_bool(); - - - /*! - * @brief This function sets a value in member my_int32 - * @param _my_int32 New value for member my_int32 - */ - eProsima_user_DllExport void my_int32( - int32_t _my_int32); - - /*! - * @brief This function returns the value of member my_int32 - * @return Value of member my_int32 - */ - eProsima_user_DllExport int32_t my_int32() const; - - /*! - * @brief This function returns a reference to member my_int32 - * @return Reference to member my_int32 - */ - eProsima_user_DllExport int32_t& my_int32(); - - - /*! - * @brief This function copies the value in member my_string - * @param _my_string New value to be copied in member my_string - */ - eProsima_user_DllExport void my_string( - const std::string& _my_string); - - /*! - * @brief This function moves the value in member my_string - * @param _my_string New value to be moved in member my_string - */ - eProsima_user_DllExport void my_string( - std::string&& _my_string); - - /*! - * @brief This function returns a constant reference to member my_string - * @return Constant reference to member my_string - */ - eProsima_user_DllExport const std::string& my_string() const; - - /*! - * @brief This function returns a reference to member my_string - * @return Reference to member my_string - */ - eProsima_user_DllExport std::string& my_string(); - - - /*! - * @brief This function sets a value in member new_int32 - * @param _new_int32 New value for member new_int32 - */ - eProsima_user_DllExport void new_int32( - int32_t _new_int32); - - /*! - * @brief This function returns the value of member new_int32 - * @return Value of member new_int32 - */ - eProsima_user_DllExport int32_t new_int32() const; - - /*! - * @brief This function returns a reference to member new_int32 - * @return Reference to member new_int32 - */ - eProsima_user_DllExport int32_t& new_int32(); - - - /*! - * @brief This function copies the value in member new_string - * @param _new_string New value to be copied in member new_string - */ - eProsima_user_DllExport void new_string( - const std::string& _new_string); - - /*! - * @brief This function moves the value in member new_string - * @param _new_string New value to be moved in member new_string - */ - eProsima_user_DllExport void new_string( - std::string&& _new_string); - - /*! - * @brief This function returns a constant reference to member new_string - * @return Constant reference to member new_string - */ - eProsima_user_DllExport const std::string& new_string() const; - - /*! - * @brief This function returns a reference to member new_string - * @return Reference to member new_string - */ - eProsima_user_DllExport std::string& new_string(); - -private: - - bool m_my_bool{false}; - int32_t m_my_int32{0}; - std::string m_my_string; - int32_t m_new_int32{0}; - std::string m_new_string; - -}; - - -/*! - * @brief This class represents the structure BadBasicWideStruct defined by the user in the IDL file. - * @ingroup Types - */ -class BadBasicWideStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport BadBasicWideStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~BadBasicWideStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object BadBasicWideStruct that will be copied. - */ - eProsima_user_DllExport BadBasicWideStruct( - const BadBasicWideStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object BadBasicWideStruct that will be copied. - */ - eProsima_user_DllExport BadBasicWideStruct( - BadBasicWideStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object BadBasicWideStruct that will be copied. - */ - eProsima_user_DllExport BadBasicWideStruct& operator =( - const BadBasicWideStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object BadBasicWideStruct that will be copied. - */ - eProsima_user_DllExport BadBasicWideStruct& operator =( - BadBasicWideStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x BadBasicWideStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const BadBasicWideStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x BadBasicWideStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const BadBasicWideStruct& x) const; - - /*! - * @brief This function sets a value in member new_int32 - * @param _new_int32 New value for member new_int32 - */ - eProsima_user_DllExport void new_int32( - int32_t _new_int32); - - /*! - * @brief This function returns the value of member new_int32 - * @return Value of member new_int32 - */ - eProsima_user_DllExport int32_t new_int32() const; - - /*! - * @brief This function returns a reference to member new_int32 - * @return Reference to member new_int32 - */ - eProsima_user_DllExport int32_t& new_int32(); - - - /*! - * @brief This function copies the value in member new_string - * @param _new_string New value to be copied in member new_string - */ - eProsima_user_DllExport void new_string( - const std::string& _new_string); - - /*! - * @brief This function moves the value in member new_string - * @param _new_string New value to be moved in member new_string - */ - eProsima_user_DllExport void new_string( - std::string&& _new_string); - - /*! - * @brief This function returns a constant reference to member new_string - * @return Constant reference to member new_string - */ - eProsima_user_DllExport const std::string& new_string() const; - - /*! - * @brief This function returns a reference to member new_string - * @return Reference to member new_string - */ - eProsima_user_DllExport std::string& new_string(); - - - /*! - * @brief This function sets a value in member my_bool - * @param _my_bool New value for member my_bool - */ - eProsima_user_DllExport void my_bool( - bool _my_bool); - - /*! - * @brief This function returns the value of member my_bool - * @return Value of member my_bool - */ - eProsima_user_DllExport bool my_bool() const; - - /*! - * @brief This function returns a reference to member my_bool - * @return Reference to member my_bool - */ - eProsima_user_DllExport bool& my_bool(); - - - /*! - * @brief This function sets a value in member my_int32 - * @param _my_int32 New value for member my_int32 - */ - eProsima_user_DllExport void my_int32( - int32_t _my_int32); - - /*! - * @brief This function returns the value of member my_int32 - * @return Value of member my_int32 - */ - eProsima_user_DllExport int32_t my_int32() const; - - /*! - * @brief This function returns a reference to member my_int32 - * @return Reference to member my_int32 - */ - eProsima_user_DllExport int32_t& my_int32(); - - - /*! - * @brief This function copies the value in member my_string - * @param _my_string New value to be copied in member my_string - */ - eProsima_user_DllExport void my_string( - const std::string& _my_string); - - /*! - * @brief This function moves the value in member my_string - * @param _my_string New value to be moved in member my_string - */ - eProsima_user_DllExport void my_string( - std::string&& _my_string); - - /*! - * @brief This function returns a constant reference to member my_string - * @return Constant reference to member my_string - */ - eProsima_user_DllExport const std::string& my_string() const; - - /*! - * @brief This function returns a reference to member my_string - * @return Reference to member my_string - */ - eProsima_user_DllExport std::string& my_string(); - -private: - - int32_t m_new_int32{0}; - std::string m_new_string; - bool m_my_bool{false}; - int32_t m_my_int32{0}; - std::string m_my_string; - -}; - - -/*! - * @brief This class represents the structure StringStruct defined by the user in the IDL file. - * @ingroup Types - */ -class StringStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport StringStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~StringStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object StringStruct that will be copied. - */ - eProsima_user_DllExport StringStruct( - const StringStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object StringStruct that will be copied. - */ - eProsima_user_DllExport StringStruct( - StringStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object StringStruct that will be copied. - */ - eProsima_user_DllExport StringStruct& operator =( - const StringStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object StringStruct that will be copied. - */ - eProsima_user_DllExport StringStruct& operator =( - StringStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x StringStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const StringStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x StringStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const StringStruct& x) const; - - /*! - * @brief This function copies the value in member my_string - * @param _my_string New value to be copied in member my_string - */ - eProsima_user_DllExport void my_string( - const std::string& _my_string); - - /*! - * @brief This function moves the value in member my_string - * @param _my_string New value to be moved in member my_string - */ - eProsima_user_DllExport void my_string( - std::string&& _my_string); - - /*! - * @brief This function returns a constant reference to member my_string - * @return Constant reference to member my_string - */ - eProsima_user_DllExport const std::string& my_string() const; - - /*! - * @brief This function returns a reference to member my_string - * @return Reference to member my_string - */ - eProsima_user_DllExport std::string& my_string(); - -private: - - std::string m_my_string; - -}; - - -/*! - * @brief This class represents the structure LargeStringStruct defined by the user in the IDL file. - * @ingroup Types - */ -class LargeStringStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport LargeStringStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~LargeStringStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object LargeStringStruct that will be copied. - */ - eProsima_user_DllExport LargeStringStruct( - const LargeStringStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object LargeStringStruct that will be copied. - */ - eProsima_user_DllExport LargeStringStruct( - LargeStringStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object LargeStringStruct that will be copied. - */ - eProsima_user_DllExport LargeStringStruct& operator =( - const LargeStringStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object LargeStringStruct that will be copied. - */ - eProsima_user_DllExport LargeStringStruct& operator =( - LargeStringStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x LargeStringStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const LargeStringStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x LargeStringStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const LargeStringStruct& x) const; - - /*! - * @brief This function copies the value in member my_large_string - * @param _my_large_string New value to be copied in member my_large_string - */ - eProsima_user_DllExport void my_large_string( - const eprosima::fastcdr::fixed_string<41925>& _my_large_string); - - /*! - * @brief This function moves the value in member my_large_string - * @param _my_large_string New value to be moved in member my_large_string - */ - eProsima_user_DllExport void my_large_string( - eprosima::fastcdr::fixed_string<41925>&& _my_large_string); - - /*! - * @brief This function returns a constant reference to member my_large_string - * @return Constant reference to member my_large_string - */ - eProsima_user_DllExport const eprosima::fastcdr::fixed_string<41925>& my_large_string() const; - - /*! - * @brief This function returns a reference to member my_large_string - * @return Reference to member my_large_string - */ - eProsima_user_DllExport eprosima::fastcdr::fixed_string<41925>& my_large_string(); - -private: - - eprosima::fastcdr::fixed_string<41925> m_my_large_string; - -}; - - -/*! - * @brief This class represents the structure WStringStruct defined by the user in the IDL file. - * @ingroup Types - */ -class WStringStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport WStringStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~WStringStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object WStringStruct that will be copied. - */ - eProsima_user_DllExport WStringStruct( - const WStringStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object WStringStruct that will be copied. - */ - eProsima_user_DllExport WStringStruct( - WStringStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object WStringStruct that will be copied. - */ - eProsima_user_DllExport WStringStruct& operator =( - const WStringStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object WStringStruct that will be copied. - */ - eProsima_user_DllExport WStringStruct& operator =( - WStringStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x WStringStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const WStringStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x WStringStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const WStringStruct& x) const; - - /*! - * @brief This function copies the value in member my_wstring - * @param _my_wstring New value to be copied in member my_wstring - */ - eProsima_user_DllExport void my_wstring( - const std::wstring& _my_wstring); - - /*! - * @brief This function moves the value in member my_wstring - * @param _my_wstring New value to be moved in member my_wstring - */ - eProsima_user_DllExport void my_wstring( - std::wstring&& _my_wstring); - - /*! - * @brief This function returns a constant reference to member my_wstring - * @return Constant reference to member my_wstring - */ - eProsima_user_DllExport const std::wstring& my_wstring() const; - - /*! - * @brief This function returns a reference to member my_wstring - * @return Reference to member my_wstring - */ - eProsima_user_DllExport std::wstring& my_wstring(); - -private: - - std::wstring m_my_wstring; - -}; - - -/*! - * @brief This class represents the structure LargeWStringStruct defined by the user in the IDL file. - * @ingroup Types - */ -class LargeWStringStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport LargeWStringStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~LargeWStringStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object LargeWStringStruct that will be copied. - */ - eProsima_user_DllExport LargeWStringStruct( - const LargeWStringStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object LargeWStringStruct that will be copied. - */ - eProsima_user_DllExport LargeWStringStruct( - LargeWStringStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object LargeWStringStruct that will be copied. - */ - eProsima_user_DllExport LargeWStringStruct& operator =( - const LargeWStringStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object LargeWStringStruct that will be copied. - */ - eProsima_user_DllExport LargeWStringStruct& operator =( - LargeWStringStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x LargeWStringStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const LargeWStringStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x LargeWStringStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const LargeWStringStruct& x) const; - - /*! - * @brief This function copies the value in member my_large_wstring - * @param _my_large_wstring New value to be copied in member my_large_wstring - */ - eProsima_user_DllExport void my_large_wstring( - const std::wstring& _my_large_wstring); - - /*! - * @brief This function moves the value in member my_large_wstring - * @param _my_large_wstring New value to be moved in member my_large_wstring - */ - eProsima_user_DllExport void my_large_wstring( - std::wstring&& _my_large_wstring); - - /*! - * @brief This function returns a constant reference to member my_large_wstring - * @return Constant reference to member my_large_wstring - */ - eProsima_user_DllExport const std::wstring& my_large_wstring() const; - - /*! - * @brief This function returns a reference to member my_large_wstring - * @return Reference to member my_large_wstring - */ - eProsima_user_DllExport std::wstring& my_large_wstring(); - -private: - - std::wstring m_my_large_wstring; - -}; - - -/*! - * @brief This class represents the structure ArrayStruct defined by the user in the IDL file. - * @ingroup Types - */ -class ArrayStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport ArrayStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~ArrayStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object ArrayStruct that will be copied. - */ - eProsima_user_DllExport ArrayStruct( - const ArrayStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object ArrayStruct that will be copied. - */ - eProsima_user_DllExport ArrayStruct( - ArrayStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object ArrayStruct that will be copied. - */ - eProsima_user_DllExport ArrayStruct& operator =( - const ArrayStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object ArrayStruct that will be copied. - */ - eProsima_user_DllExport ArrayStruct& operator =( - ArrayStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x ArrayStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const ArrayStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x ArrayStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const ArrayStruct& x) const; - - /*! - * @brief This function copies the value in member my_array - * @param _my_array New value to be copied in member my_array - */ - eProsima_user_DllExport void my_array( - const std::array& _my_array); - - /*! - * @brief This function moves the value in member my_array - * @param _my_array New value to be moved in member my_array - */ - eProsima_user_DllExport void my_array( - std::array&& _my_array); - - /*! - * @brief This function returns a constant reference to member my_array - * @return Constant reference to member my_array - */ - eProsima_user_DllExport const std::array& my_array() const; - - /*! - * @brief This function returns a reference to member my_array - * @return Reference to member my_array - */ - eProsima_user_DllExport std::array& my_array(); - -private: - - std::array m_my_array{0}; - -}; - - -/*! - * @brief This class represents the structure ArrayStructEqual defined by the user in the IDL file. - * @ingroup Types - */ -class ArrayStructEqual -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport ArrayStructEqual(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~ArrayStructEqual(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object ArrayStructEqual that will be copied. - */ - eProsima_user_DllExport ArrayStructEqual( - const ArrayStructEqual& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object ArrayStructEqual that will be copied. - */ - eProsima_user_DllExport ArrayStructEqual( - ArrayStructEqual&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object ArrayStructEqual that will be copied. - */ - eProsima_user_DllExport ArrayStructEqual& operator =( - const ArrayStructEqual& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object ArrayStructEqual that will be copied. - */ - eProsima_user_DllExport ArrayStructEqual& operator =( - ArrayStructEqual&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x ArrayStructEqual object to compare. - */ - eProsima_user_DllExport bool operator ==( - const ArrayStructEqual& x) const; - - /*! - * @brief Comparison operator. - * @param x ArrayStructEqual object to compare. - */ - eProsima_user_DllExport bool operator !=( - const ArrayStructEqual& x) const; - - /*! - * @brief This function copies the value in member my_array_equal - * @param _my_array_equal New value to be copied in member my_array_equal - */ - eProsima_user_DllExport void my_array_equal( - const std::array& _my_array_equal); - - /*! - * @brief This function moves the value in member my_array_equal - * @param _my_array_equal New value to be moved in member my_array_equal - */ - eProsima_user_DllExport void my_array_equal( - std::array&& _my_array_equal); - - /*! - * @brief This function returns a constant reference to member my_array_equal - * @return Constant reference to member my_array_equal - */ - eProsima_user_DllExport const std::array& my_array_equal() const; - - /*! - * @brief This function returns a reference to member my_array_equal - * @return Reference to member my_array_equal - */ - eProsima_user_DllExport std::array& my_array_equal(); - -private: - - std::array m_my_array_equal{0}; - -}; - - -/*! - * @brief This class represents the structure ArrayBadStruct defined by the user in the IDL file. - * @ingroup Types - */ -class ArrayBadStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport ArrayBadStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~ArrayBadStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object ArrayBadStruct that will be copied. - */ - eProsima_user_DllExport ArrayBadStruct( - const ArrayBadStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object ArrayBadStruct that will be copied. - */ - eProsima_user_DllExport ArrayBadStruct( - ArrayBadStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object ArrayBadStruct that will be copied. - */ - eProsima_user_DllExport ArrayBadStruct& operator =( - const ArrayBadStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object ArrayBadStruct that will be copied. - */ - eProsima_user_DllExport ArrayBadStruct& operator =( - ArrayBadStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x ArrayBadStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const ArrayBadStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x ArrayBadStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const ArrayBadStruct& x) const; - - /*! - * @brief This function copies the value in member my_array - * @param _my_array New value to be copied in member my_array - */ - eProsima_user_DllExport void my_array( - const std::array& _my_array); - - /*! - * @brief This function moves the value in member my_array - * @param _my_array New value to be moved in member my_array - */ - eProsima_user_DllExport void my_array( - std::array&& _my_array); - - /*! - * @brief This function returns a constant reference to member my_array - * @return Constant reference to member my_array - */ - eProsima_user_DllExport const std::array& my_array() const; - - /*! - * @brief This function returns a reference to member my_array - * @return Reference to member my_array - */ - eProsima_user_DllExport std::array& my_array(); - -private: - - std::array m_my_array{0}; - -}; - - -/*! - * @brief This class represents the structure ArrayDimensionsStruct defined by the user in the IDL file. - * @ingroup Types - */ -class ArrayDimensionsStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport ArrayDimensionsStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~ArrayDimensionsStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object ArrayDimensionsStruct that will be copied. - */ - eProsima_user_DllExport ArrayDimensionsStruct( - const ArrayDimensionsStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object ArrayDimensionsStruct that will be copied. - */ - eProsima_user_DllExport ArrayDimensionsStruct( - ArrayDimensionsStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object ArrayDimensionsStruct that will be copied. - */ - eProsima_user_DllExport ArrayDimensionsStruct& operator =( - const ArrayDimensionsStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object ArrayDimensionsStruct that will be copied. - */ - eProsima_user_DllExport ArrayDimensionsStruct& operator =( - ArrayDimensionsStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x ArrayDimensionsStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const ArrayDimensionsStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x ArrayDimensionsStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const ArrayDimensionsStruct& x) const; - - /*! - * @brief This function copies the value in member my_array - * @param _my_array New value to be copied in member my_array - */ - eProsima_user_DllExport void my_array( - const std::array, 2>& _my_array); - - /*! - * @brief This function moves the value in member my_array - * @param _my_array New value to be moved in member my_array - */ - eProsima_user_DllExport void my_array( - std::array, 2>&& _my_array); - - /*! - * @brief This function returns a constant reference to member my_array - * @return Constant reference to member my_array - */ - eProsima_user_DllExport const std::array, 2>& my_array() const; - - /*! - * @brief This function returns a reference to member my_array - * @return Reference to member my_array - */ - eProsima_user_DllExport std::array, 2>& my_array(); - -private: - - std::array, 2> m_my_array{ {{0}} }; - -}; - - -/*! - * @brief This class represents the structure ArraySizeStruct defined by the user in the IDL file. - * @ingroup Types - */ -class ArraySizeStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport ArraySizeStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~ArraySizeStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object ArraySizeStruct that will be copied. - */ - eProsima_user_DllExport ArraySizeStruct( - const ArraySizeStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object ArraySizeStruct that will be copied. - */ - eProsima_user_DllExport ArraySizeStruct( - ArraySizeStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object ArraySizeStruct that will be copied. - */ - eProsima_user_DllExport ArraySizeStruct& operator =( - const ArraySizeStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object ArraySizeStruct that will be copied. - */ - eProsima_user_DllExport ArraySizeStruct& operator =( - ArraySizeStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x ArraySizeStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const ArraySizeStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x ArraySizeStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const ArraySizeStruct& x) const; - - /*! - * @brief This function copies the value in member my_array - * @param _my_array New value to be copied in member my_array - */ - eProsima_user_DllExport void my_array( - const std::array& _my_array); - - /*! - * @brief This function moves the value in member my_array - * @param _my_array New value to be moved in member my_array - */ - eProsima_user_DllExport void my_array( - std::array&& _my_array); - - /*! - * @brief This function returns a constant reference to member my_array - * @return Constant reference to member my_array - */ - eProsima_user_DllExport const std::array& my_array() const; - - /*! - * @brief This function returns a reference to member my_array - * @return Reference to member my_array - */ - eProsima_user_DllExport std::array& my_array(); - -private: - - std::array m_my_array{0}; - -}; - - - - -/*! - * @brief This class represents the structure SequenceStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SequenceStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SequenceStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SequenceStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SequenceStruct that will be copied. - */ - eProsima_user_DllExport SequenceStruct( - const SequenceStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SequenceStruct that will be copied. - */ - eProsima_user_DllExport SequenceStruct( - SequenceStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SequenceStruct that will be copied. - */ - eProsima_user_DllExport SequenceStruct& operator =( - const SequenceStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SequenceStruct that will be copied. - */ - eProsima_user_DllExport SequenceStruct& operator =( - SequenceStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SequenceStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SequenceStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x SequenceStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SequenceStruct& x) const; - - /*! - * @brief This function copies the value in member my_sequence - * @param _my_sequence New value to be copied in member my_sequence - */ - eProsima_user_DllExport void my_sequence( - const std::vector& _my_sequence); - - /*! - * @brief This function moves the value in member my_sequence - * @param _my_sequence New value to be moved in member my_sequence - */ - eProsima_user_DllExport void my_sequence( - std::vector&& _my_sequence); - - /*! - * @brief This function returns a constant reference to member my_sequence - * @return Constant reference to member my_sequence - */ - eProsima_user_DllExport const std::vector& my_sequence() const; - - /*! - * @brief This function returns a reference to member my_sequence - * @return Reference to member my_sequence - */ - eProsima_user_DllExport std::vector& my_sequence(); - -private: - - std::vector m_my_sequence; - -}; - - - - -/*! - * @brief This class represents the structure SequenceStructEqual defined by the user in the IDL file. - * @ingroup Types - */ -class SequenceStructEqual -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SequenceStructEqual(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SequenceStructEqual(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SequenceStructEqual that will be copied. - */ - eProsima_user_DllExport SequenceStructEqual( - const SequenceStructEqual& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SequenceStructEqual that will be copied. - */ - eProsima_user_DllExport SequenceStructEqual( - SequenceStructEqual&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SequenceStructEqual that will be copied. - */ - eProsima_user_DllExport SequenceStructEqual& operator =( - const SequenceStructEqual& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SequenceStructEqual that will be copied. - */ - eProsima_user_DllExport SequenceStructEqual& operator =( - SequenceStructEqual&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SequenceStructEqual object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SequenceStructEqual& x) const; - - /*! - * @brief Comparison operator. - * @param x SequenceStructEqual object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SequenceStructEqual& x) const; - - /*! - * @brief This function copies the value in member my_sequence_equal - * @param _my_sequence_equal New value to be copied in member my_sequence_equal - */ - eProsima_user_DllExport void my_sequence_equal( - const std::vector& _my_sequence_equal); - - /*! - * @brief This function moves the value in member my_sequence_equal - * @param _my_sequence_equal New value to be moved in member my_sequence_equal - */ - eProsima_user_DllExport void my_sequence_equal( - std::vector&& _my_sequence_equal); - - /*! - * @brief This function returns a constant reference to member my_sequence_equal - * @return Constant reference to member my_sequence_equal - */ - eProsima_user_DllExport const std::vector& my_sequence_equal() const; - - /*! - * @brief This function returns a reference to member my_sequence_equal - * @return Reference to member my_sequence_equal - */ - eProsima_user_DllExport std::vector& my_sequence_equal(); - -private: - - std::vector m_my_sequence_equal; - -}; - - - - -/*! - * @brief This class represents the structure SequenceBadStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SequenceBadStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SequenceBadStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SequenceBadStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SequenceBadStruct that will be copied. - */ - eProsima_user_DllExport SequenceBadStruct( - const SequenceBadStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SequenceBadStruct that will be copied. - */ - eProsima_user_DllExport SequenceBadStruct( - SequenceBadStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SequenceBadStruct that will be copied. - */ - eProsima_user_DllExport SequenceBadStruct& operator =( - const SequenceBadStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SequenceBadStruct that will be copied. - */ - eProsima_user_DllExport SequenceBadStruct& operator =( - SequenceBadStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SequenceBadStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SequenceBadStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x SequenceBadStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SequenceBadStruct& x) const; - - /*! - * @brief This function copies the value in member my_sequence - * @param _my_sequence New value to be copied in member my_sequence - */ - eProsima_user_DllExport void my_sequence( - const std::vector& _my_sequence); - - /*! - * @brief This function moves the value in member my_sequence - * @param _my_sequence New value to be moved in member my_sequence - */ - eProsima_user_DllExport void my_sequence( - std::vector&& _my_sequence); - - /*! - * @brief This function returns a constant reference to member my_sequence - * @return Constant reference to member my_sequence - */ - eProsima_user_DllExport const std::vector& my_sequence() const; - - /*! - * @brief This function returns a reference to member my_sequence - * @return Reference to member my_sequence - */ - eProsima_user_DllExport std::vector& my_sequence(); - -private: - - std::vector m_my_sequence; - -}; - - - - -/*! - * @brief This class represents the structure SequenceBoundsStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SequenceBoundsStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SequenceBoundsStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SequenceBoundsStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SequenceBoundsStruct that will be copied. - */ - eProsima_user_DllExport SequenceBoundsStruct( - const SequenceBoundsStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SequenceBoundsStruct that will be copied. - */ - eProsima_user_DllExport SequenceBoundsStruct( - SequenceBoundsStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SequenceBoundsStruct that will be copied. - */ - eProsima_user_DllExport SequenceBoundsStruct& operator =( - const SequenceBoundsStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SequenceBoundsStruct that will be copied. - */ - eProsima_user_DllExport SequenceBoundsStruct& operator =( - SequenceBoundsStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SequenceBoundsStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SequenceBoundsStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x SequenceBoundsStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SequenceBoundsStruct& x) const; - - /*! - * @brief This function copies the value in member my_sequence - * @param _my_sequence New value to be copied in member my_sequence - */ - eProsima_user_DllExport void my_sequence( - const std::vector& _my_sequence); - - /*! - * @brief This function moves the value in member my_sequence - * @param _my_sequence New value to be moved in member my_sequence - */ - eProsima_user_DllExport void my_sequence( - std::vector&& _my_sequence); - - /*! - * @brief This function returns a constant reference to member my_sequence - * @return Constant reference to member my_sequence - */ - eProsima_user_DllExport const std::vector& my_sequence() const; - - /*! - * @brief This function returns a reference to member my_sequence - * @return Reference to member my_sequence - */ - eProsima_user_DllExport std::vector& my_sequence(); - -private: - - std::vector m_my_sequence; - -}; - - - - - - -/*! - * @brief This class represents the structure SequenceSequenceStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SequenceSequenceStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SequenceSequenceStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SequenceSequenceStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SequenceSequenceStruct that will be copied. - */ - eProsima_user_DllExport SequenceSequenceStruct( - const SequenceSequenceStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SequenceSequenceStruct that will be copied. - */ - eProsima_user_DllExport SequenceSequenceStruct( - SequenceSequenceStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SequenceSequenceStruct that will be copied. - */ - eProsima_user_DllExport SequenceSequenceStruct& operator =( - const SequenceSequenceStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SequenceSequenceStruct that will be copied. - */ - eProsima_user_DllExport SequenceSequenceStruct& operator =( - SequenceSequenceStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SequenceSequenceStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SequenceSequenceStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x SequenceSequenceStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SequenceSequenceStruct& x) const; - - /*! - * @brief This function copies the value in member my_sequence_sequence - * @param _my_sequence_sequence New value to be copied in member my_sequence_sequence - */ - eProsima_user_DllExport void my_sequence_sequence( - const std::vector>& _my_sequence_sequence); - - /*! - * @brief This function moves the value in member my_sequence_sequence - * @param _my_sequence_sequence New value to be moved in member my_sequence_sequence - */ - eProsima_user_DllExport void my_sequence_sequence( - std::vector>&& _my_sequence_sequence); - - /*! - * @brief This function returns a constant reference to member my_sequence_sequence - * @return Constant reference to member my_sequence_sequence - */ - eProsima_user_DllExport const std::vector>& my_sequence_sequence() const; - - /*! - * @brief This function returns a reference to member my_sequence_sequence - * @return Reference to member my_sequence_sequence - */ - eProsima_user_DllExport std::vector>& my_sequence_sequence(); - -private: - - std::vector> m_my_sequence_sequence; - -}; - - - - - - -/*! - * @brief This class represents the structure SequenceSequenceBoundsStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SequenceSequenceBoundsStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SequenceSequenceBoundsStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SequenceSequenceBoundsStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SequenceSequenceBoundsStruct that will be copied. - */ - eProsima_user_DllExport SequenceSequenceBoundsStruct( - const SequenceSequenceBoundsStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SequenceSequenceBoundsStruct that will be copied. - */ - eProsima_user_DllExport SequenceSequenceBoundsStruct( - SequenceSequenceBoundsStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SequenceSequenceBoundsStruct that will be copied. - */ - eProsima_user_DllExport SequenceSequenceBoundsStruct& operator =( - const SequenceSequenceBoundsStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SequenceSequenceBoundsStruct that will be copied. - */ - eProsima_user_DllExport SequenceSequenceBoundsStruct& operator =( - SequenceSequenceBoundsStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SequenceSequenceBoundsStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SequenceSequenceBoundsStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x SequenceSequenceBoundsStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SequenceSequenceBoundsStruct& x) const; - - /*! - * @brief This function copies the value in member my_sequence_sequence - * @param _my_sequence_sequence New value to be copied in member my_sequence_sequence - */ - eProsima_user_DllExport void my_sequence_sequence( - const std::vector>& _my_sequence_sequence); - - /*! - * @brief This function moves the value in member my_sequence_sequence - * @param _my_sequence_sequence New value to be moved in member my_sequence_sequence - */ - eProsima_user_DllExport void my_sequence_sequence( - std::vector>&& _my_sequence_sequence); - - /*! - * @brief This function returns a constant reference to member my_sequence_sequence - * @return Constant reference to member my_sequence_sequence - */ - eProsima_user_DllExport const std::vector>& my_sequence_sequence() const; - - /*! - * @brief This function returns a reference to member my_sequence_sequence - * @return Reference to member my_sequence_sequence - */ - eProsima_user_DllExport std::vector>& my_sequence_sequence(); - -private: - - std::vector> m_my_sequence_sequence; - -}; - - - - -/*! - * @brief This class represents the structure MapStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MapStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MapStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MapStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MapStruct that will be copied. - */ - eProsima_user_DllExport MapStruct( - const MapStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MapStruct that will be copied. - */ - eProsima_user_DllExport MapStruct( - MapStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MapStruct that will be copied. - */ - eProsima_user_DllExport MapStruct& operator =( - const MapStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MapStruct that will be copied. - */ - eProsima_user_DllExport MapStruct& operator =( - MapStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MapStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MapStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x MapStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MapStruct& x) const; - - /*! - * @brief This function copies the value in member my_map - * @param _my_map New value to be copied in member my_map - */ - eProsima_user_DllExport void my_map( - const std::map& _my_map); - - /*! - * @brief This function moves the value in member my_map - * @param _my_map New value to be moved in member my_map - */ - eProsima_user_DllExport void my_map( - std::map&& _my_map); - - /*! - * @brief This function returns a constant reference to member my_map - * @return Constant reference to member my_map - */ - eProsima_user_DllExport const std::map& my_map() const; - - /*! - * @brief This function returns a reference to member my_map - * @return Reference to member my_map - */ - eProsima_user_DllExport std::map& my_map(); - -private: - - std::map m_my_map; - -}; - - - - -/*! - * @brief This class represents the structure MapStructEqual defined by the user in the IDL file. - * @ingroup Types - */ -class MapStructEqual -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MapStructEqual(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MapStructEqual(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MapStructEqual that will be copied. - */ - eProsima_user_DllExport MapStructEqual( - const MapStructEqual& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MapStructEqual that will be copied. - */ - eProsima_user_DllExport MapStructEqual( - MapStructEqual&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MapStructEqual that will be copied. - */ - eProsima_user_DllExport MapStructEqual& operator =( - const MapStructEqual& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MapStructEqual that will be copied. - */ - eProsima_user_DllExport MapStructEqual& operator =( - MapStructEqual&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MapStructEqual object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MapStructEqual& x) const; - - /*! - * @brief Comparison operator. - * @param x MapStructEqual object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MapStructEqual& x) const; - - /*! - * @brief This function copies the value in member my_map_equal - * @param _my_map_equal New value to be copied in member my_map_equal - */ - eProsima_user_DllExport void my_map_equal( - const std::map& _my_map_equal); - - /*! - * @brief This function moves the value in member my_map_equal - * @param _my_map_equal New value to be moved in member my_map_equal - */ - eProsima_user_DllExport void my_map_equal( - std::map&& _my_map_equal); - - /*! - * @brief This function returns a constant reference to member my_map_equal - * @return Constant reference to member my_map_equal - */ - eProsima_user_DllExport const std::map& my_map_equal() const; - - /*! - * @brief This function returns a reference to member my_map_equal - * @return Reference to member my_map_equal - */ - eProsima_user_DllExport std::map& my_map_equal(); - -private: - - std::map m_my_map_equal; - -}; - - - - -/*! - * @brief This class represents the structure MapBadKeyStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MapBadKeyStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MapBadKeyStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MapBadKeyStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MapBadKeyStruct that will be copied. - */ - eProsima_user_DllExport MapBadKeyStruct( - const MapBadKeyStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MapBadKeyStruct that will be copied. - */ - eProsima_user_DllExport MapBadKeyStruct( - MapBadKeyStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MapBadKeyStruct that will be copied. - */ - eProsima_user_DllExport MapBadKeyStruct& operator =( - const MapBadKeyStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MapBadKeyStruct that will be copied. - */ - eProsima_user_DllExport MapBadKeyStruct& operator =( - MapBadKeyStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MapBadKeyStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MapBadKeyStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x MapBadKeyStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MapBadKeyStruct& x) const; - - /*! - * @brief This function copies the value in member my_map - * @param _my_map New value to be copied in member my_map - */ - eProsima_user_DllExport void my_map( - const std::map& _my_map); - - /*! - * @brief This function moves the value in member my_map - * @param _my_map New value to be moved in member my_map - */ - eProsima_user_DllExport void my_map( - std::map&& _my_map); - - /*! - * @brief This function returns a constant reference to member my_map - * @return Constant reference to member my_map - */ - eProsima_user_DllExport const std::map& my_map() const; - - /*! - * @brief This function returns a reference to member my_map - * @return Reference to member my_map - */ - eProsima_user_DllExport std::map& my_map(); - -private: - - std::map m_my_map; - -}; - - - - -/*! - * @brief This class represents the structure MapBadElemStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MapBadElemStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MapBadElemStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MapBadElemStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MapBadElemStruct that will be copied. - */ - eProsima_user_DllExport MapBadElemStruct( - const MapBadElemStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MapBadElemStruct that will be copied. - */ - eProsima_user_DllExport MapBadElemStruct( - MapBadElemStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MapBadElemStruct that will be copied. - */ - eProsima_user_DllExport MapBadElemStruct& operator =( - const MapBadElemStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MapBadElemStruct that will be copied. - */ - eProsima_user_DllExport MapBadElemStruct& operator =( - MapBadElemStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MapBadElemStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MapBadElemStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x MapBadElemStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MapBadElemStruct& x) const; - - /*! - * @brief This function copies the value in member my_map - * @param _my_map New value to be copied in member my_map - */ - eProsima_user_DllExport void my_map( - const std::map& _my_map); - - /*! - * @brief This function moves the value in member my_map - * @param _my_map New value to be moved in member my_map - */ - eProsima_user_DllExport void my_map( - std::map&& _my_map); - - /*! - * @brief This function returns a constant reference to member my_map - * @return Constant reference to member my_map - */ - eProsima_user_DllExport const std::map& my_map() const; - - /*! - * @brief This function returns a reference to member my_map - * @return Reference to member my_map - */ - eProsima_user_DllExport std::map& my_map(); - -private: - - std::map m_my_map; - -}; - - - - -/*! - * @brief This class represents the structure MapBoundsStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MapBoundsStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MapBoundsStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MapBoundsStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MapBoundsStruct that will be copied. - */ - eProsima_user_DllExport MapBoundsStruct( - const MapBoundsStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MapBoundsStruct that will be copied. - */ - eProsima_user_DllExport MapBoundsStruct( - MapBoundsStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MapBoundsStruct that will be copied. - */ - eProsima_user_DllExport MapBoundsStruct& operator =( - const MapBoundsStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MapBoundsStruct that will be copied. - */ - eProsima_user_DllExport MapBoundsStruct& operator =( - MapBoundsStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MapBoundsStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MapBoundsStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x MapBoundsStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MapBoundsStruct& x) const; - - /*! - * @brief This function copies the value in member my_map - * @param _my_map New value to be copied in member my_map - */ - eProsima_user_DllExport void my_map( - const std::map& _my_map); - - /*! - * @brief This function moves the value in member my_map - * @param _my_map New value to be moved in member my_map - */ - eProsima_user_DllExport void my_map( - std::map&& _my_map); - - /*! - * @brief This function returns a constant reference to member my_map - * @return Constant reference to member my_map - */ - eProsima_user_DllExport const std::map& my_map() const; - - /*! - * @brief This function returns a reference to member my_map - * @return Reference to member my_map - */ - eProsima_user_DllExport std::map& my_map(); - -private: - - std::map m_my_map; - -}; - - - - - - -/*! - * @brief This class represents the structure MapMapStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MapMapStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MapMapStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MapMapStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MapMapStruct that will be copied. - */ - eProsima_user_DllExport MapMapStruct( - const MapMapStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MapMapStruct that will be copied. - */ - eProsima_user_DllExport MapMapStruct( - MapMapStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MapMapStruct that will be copied. - */ - eProsima_user_DllExport MapMapStruct& operator =( - const MapMapStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MapMapStruct that will be copied. - */ - eProsima_user_DllExport MapMapStruct& operator =( - MapMapStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MapMapStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MapMapStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x MapMapStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MapMapStruct& x) const; - - /*! - * @brief This function copies the value in member my_map_map - * @param _my_map_map New value to be copied in member my_map_map - */ - eProsima_user_DllExport void my_map_map( - const std::map>& _my_map_map); - - /*! - * @brief This function moves the value in member my_map_map - * @param _my_map_map New value to be moved in member my_map_map - */ - eProsima_user_DllExport void my_map_map( - std::map>&& _my_map_map); - - /*! - * @brief This function returns a constant reference to member my_map_map - * @return Constant reference to member my_map_map - */ - eProsima_user_DllExport const std::map>& my_map_map() const; - - /*! - * @brief This function returns a reference to member my_map_map - * @return Reference to member my_map_map - */ - eProsima_user_DllExport std::map>& my_map_map(); - -private: - - std::map> m_my_map_map; - -}; - - - - - - -/*! - * @brief This class represents the structure MapMapBoundsStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MapMapBoundsStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MapMapBoundsStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MapMapBoundsStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MapMapBoundsStruct that will be copied. - */ - eProsima_user_DllExport MapMapBoundsStruct( - const MapMapBoundsStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MapMapBoundsStruct that will be copied. - */ - eProsima_user_DllExport MapMapBoundsStruct( - MapMapBoundsStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MapMapBoundsStruct that will be copied. - */ - eProsima_user_DllExport MapMapBoundsStruct& operator =( - const MapMapBoundsStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MapMapBoundsStruct that will be copied. - */ - eProsima_user_DllExport MapMapBoundsStruct& operator =( - MapMapBoundsStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MapMapBoundsStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MapMapBoundsStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x MapMapBoundsStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MapMapBoundsStruct& x) const; - - /*! - * @brief This function copies the value in member my_map_map - * @param _my_map_map New value to be copied in member my_map_map - */ - eProsima_user_DllExport void my_map_map( - const std::map>& _my_map_map); - - /*! - * @brief This function moves the value in member my_map_map - * @param _my_map_map New value to be moved in member my_map_map - */ - eProsima_user_DllExport void my_map_map( - std::map>&& _my_map_map); - - /*! - * @brief This function returns a constant reference to member my_map_map - * @return Constant reference to member my_map_map - */ - eProsima_user_DllExport const std::map>& my_map_map() const; - - /*! - * @brief This function returns a reference to member my_map_map - * @return Reference to member my_map_map - */ - eProsima_user_DllExport std::map>& my_map_map(); - -private: - - std::map> m_my_map_map; - -}; - - -/*! - * @brief This class represents the union SimpleUnion defined by the user in the IDL file. - * @ingroup Types - */ -class SimpleUnion -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimpleUnion(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimpleUnion(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimpleUnion that will be copied. - */ - eProsima_user_DllExport SimpleUnion( - const SimpleUnion& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimpleUnion that will be copied. - */ - eProsima_user_DllExport SimpleUnion( - SimpleUnion&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimpleUnion that will be copied. - */ - eProsima_user_DllExport SimpleUnion& operator =( - const SimpleUnion& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimpleUnion that will be copied. - */ - eProsima_user_DllExport SimpleUnion& operator =( - SimpleUnion&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimpleUnion object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimpleUnion& x) const; - - /*! - * @brief Comparison operator. - * @param x SimpleUnion object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimpleUnion& x) const; - - /*! - * @brief This function sets the discriminator value. - * @param __d New value for the discriminator. - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the new value doesn't correspond to the selected union member. - */ - eProsima_user_DllExport void _d( - int32_t __d); - - /*! - * @brief This function returns the value of the discriminator. - * @return Value of the discriminator - */ - eProsima_user_DllExport int32_t _d() const; - - /*! - * @brief This function returns a reference to the discriminator. - * @return Reference to the discriminator. - */ - eProsima_user_DllExport int32_t& _d(); - - /*! - * @brief This function sets a value in member first - * @param _first New value for member first - */ - eProsima_user_DllExport void first( - int32_t _first); - - /*! - * @brief This function returns the value of member first - * @return Value of member first - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t first() const; - - /*! - * @brief This function returns a reference to member first - * @return Reference to member first - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t& first(); - - - /*! - * @brief This function sets a value in member second - * @param _second New value for member second - */ - eProsima_user_DllExport void second( - int64_t _second); - - /*! - * @brief This function returns the value of member second - * @return Value of member second - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t second() const; - - /*! - * @brief This function returns a reference to member second - * @return Reference to member second - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t& second(); - -private: - - int32_t m__d; - - int32_t m_first{0}; - int64_t m_second{0}; -}; - - -/*! - * @brief This class represents the union SimpleUnionNames defined by the user in the IDL file. - * @ingroup Types - */ -class SimpleUnionNames -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimpleUnionNames(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimpleUnionNames(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimpleUnionNames that will be copied. - */ - eProsima_user_DllExport SimpleUnionNames( - const SimpleUnionNames& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimpleUnionNames that will be copied. - */ - eProsima_user_DllExport SimpleUnionNames( - SimpleUnionNames&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimpleUnionNames that will be copied. - */ - eProsima_user_DllExport SimpleUnionNames& operator =( - const SimpleUnionNames& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimpleUnionNames that will be copied. - */ - eProsima_user_DllExport SimpleUnionNames& operator =( - SimpleUnionNames&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimpleUnionNames object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimpleUnionNames& x) const; - - /*! - * @brief Comparison operator. - * @param x SimpleUnionNames object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimpleUnionNames& x) const; - - /*! - * @brief This function sets the discriminator value. - * @param __d New value for the discriminator. - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the new value doesn't correspond to the selected union member. - */ - eProsima_user_DllExport void _d( - int32_t __d); - - /*! - * @brief This function returns the value of the discriminator. - * @return Value of the discriminator - */ - eProsima_user_DllExport int32_t _d() const; - - /*! - * @brief This function returns a reference to the discriminator. - * @return Reference to the discriminator. - */ - eProsima_user_DllExport int32_t& _d(); - - /*! - * @brief This function sets a value in member first_case - * @param _first_case New value for member first_case - */ - eProsima_user_DllExport void first_case( - int32_t _first_case); - - /*! - * @brief This function returns the value of member first_case - * @return Value of member first_case - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t first_case() const; - - /*! - * @brief This function returns a reference to member first_case - * @return Reference to member first_case - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t& first_case(); - - - /*! - * @brief This function sets a value in member second_case - * @param _second_case New value for member second_case - */ - eProsima_user_DllExport void second_case( - int64_t _second_case); - - /*! - * @brief This function returns the value of member second_case - * @return Value of member second_case - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t second_case() const; - - /*! - * @brief This function returns a reference to member second_case - * @return Reference to member second_case - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t& second_case(); - -private: - - int32_t m__d; - - int32_t m_first_case{0}; - int64_t m_second_case{0}; -}; - - -/*! - * @brief This class represents the union SimpleTypeUnion defined by the user in the IDL file. - * @ingroup Types - */ -class SimpleTypeUnion -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimpleTypeUnion(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimpleTypeUnion(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimpleTypeUnion that will be copied. - */ - eProsima_user_DllExport SimpleTypeUnion( - const SimpleTypeUnion& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimpleTypeUnion that will be copied. - */ - eProsima_user_DllExport SimpleTypeUnion( - SimpleTypeUnion&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimpleTypeUnion that will be copied. - */ - eProsima_user_DllExport SimpleTypeUnion& operator =( - const SimpleTypeUnion& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimpleTypeUnion that will be copied. - */ - eProsima_user_DllExport SimpleTypeUnion& operator =( - SimpleTypeUnion&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimpleTypeUnion object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimpleTypeUnion& x) const; - - /*! - * @brief Comparison operator. - * @param x SimpleTypeUnion object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimpleTypeUnion& x) const; - - /*! - * @brief This function sets the discriminator value. - * @param __d New value for the discriminator. - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the new value doesn't correspond to the selected union member. - */ - eProsima_user_DllExport void _d( - int32_t __d); - - /*! - * @brief This function returns the value of the discriminator. - * @return Value of the discriminator - */ - eProsima_user_DllExport int32_t _d() const; - - /*! - * @brief This function returns a reference to the discriminator. - * @return Reference to the discriminator. - */ - eProsima_user_DllExport int32_t& _d(); - - /*! - * @brief This function sets a value in member first - * @param _first New value for member first - */ - eProsima_user_DllExport void first( - uint8_t _first); - - /*! - * @brief This function returns the value of member first - * @return Value of member first - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport uint8_t first() const; - - /*! - * @brief This function returns a reference to member first - * @return Reference to member first - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport uint8_t& first(); - - - /*! - * @brief This function sets a value in member second - * @param _second New value for member second - */ - eProsima_user_DllExport void second( - int64_t _second); - - /*! - * @brief This function returns the value of member second - * @return Value of member second - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t second() const; - - /*! - * @brief This function returns a reference to member second - * @return Reference to member second - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t& second(); - -private: - - int32_t m__d; - - uint8_t m_first{0}; - int64_t m_second{0}; -}; - - -/*! - * @brief This class represents the union SimpleBadUnion defined by the user in the IDL file. - * @ingroup Types - */ -class SimpleBadUnion -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimpleBadUnion(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimpleBadUnion(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimpleBadUnion that will be copied. - */ - eProsima_user_DllExport SimpleBadUnion( - const SimpleBadUnion& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimpleBadUnion that will be copied. - */ - eProsima_user_DllExport SimpleBadUnion( - SimpleBadUnion&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimpleBadUnion that will be copied. - */ - eProsima_user_DllExport SimpleBadUnion& operator =( - const SimpleBadUnion& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimpleBadUnion that will be copied. - */ - eProsima_user_DllExport SimpleBadUnion& operator =( - SimpleBadUnion&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimpleBadUnion object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimpleBadUnion& x) const; - - /*! - * @brief Comparison operator. - * @param x SimpleBadUnion object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimpleBadUnion& x) const; - - /*! - * @brief This function sets the discriminator value. - * @param __d New value for the discriminator. - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the new value doesn't correspond to the selected union member. - */ - eProsima_user_DllExport void _d( - int32_t __d); - - /*! - * @brief This function returns the value of the discriminator. - * @return Value of the discriminator - */ - eProsima_user_DllExport int32_t _d() const; - - /*! - * @brief This function returns a reference to the discriminator. - * @return Reference to the discriminator. - */ - eProsima_user_DllExport int32_t& _d(); - - /*! - * @brief This function sets a value in member first - * @param _first New value for member first - */ - eProsima_user_DllExport void first( - int32_t _first); - - /*! - * @brief This function returns the value of member first - * @return Value of member first - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t first() const; - - /*! - * @brief This function returns a reference to member first - * @return Reference to member first - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t& first(); - - - /*! - * @brief This function sets a value in member second - * @param _second New value for member second - */ - eProsima_user_DllExport void second( - int64_t _second); - - /*! - * @brief This function returns the value of member second - * @return Value of member second - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t second() const; - - /*! - * @brief This function returns a reference to member second - * @return Reference to member second - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t& second(); - -private: - - int32_t m__d; - - int32_t m_first{0}; - int64_t m_second{0}; -}; - - -/*! - * @brief This class represents the union SimpleBadDiscUnion defined by the user in the IDL file. - * @ingroup Types - */ -class SimpleBadDiscUnion -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimpleBadDiscUnion(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimpleBadDiscUnion(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimpleBadDiscUnion that will be copied. - */ - eProsima_user_DllExport SimpleBadDiscUnion( - const SimpleBadDiscUnion& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimpleBadDiscUnion that will be copied. - */ - eProsima_user_DllExport SimpleBadDiscUnion( - SimpleBadDiscUnion&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimpleBadDiscUnion that will be copied. - */ - eProsima_user_DllExport SimpleBadDiscUnion& operator =( - const SimpleBadDiscUnion& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimpleBadDiscUnion that will be copied. - */ - eProsima_user_DllExport SimpleBadDiscUnion& operator =( - SimpleBadDiscUnion&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimpleBadDiscUnion object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimpleBadDiscUnion& x) const; - - /*! - * @brief Comparison operator. - * @param x SimpleBadDiscUnion object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimpleBadDiscUnion& x) const; - - /*! - * @brief This function sets the discriminator value. - * @param __d New value for the discriminator. - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the new value doesn't correspond to the selected union member. - */ - eProsima_user_DllExport void _d( - uint8_t __d); - - /*! - * @brief This function returns the value of the discriminator. - * @return Value of the discriminator - */ - eProsima_user_DllExport uint8_t _d() const; - - /*! - * @brief This function returns a reference to the discriminator. - * @return Reference to the discriminator. - */ - eProsima_user_DllExport uint8_t& _d(); - - /*! - * @brief This function sets a value in member first - * @param _first New value for member first - */ - eProsima_user_DllExport void first( - int32_t _first); - - /*! - * @brief This function returns the value of member first - * @return Value of member first - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t first() const; - - /*! - * @brief This function returns a reference to member first - * @return Reference to member first - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t& first(); - - - /*! - * @brief This function sets a value in member second - * @param _second New value for member second - */ - eProsima_user_DllExport void second( - int64_t _second); - - /*! - * @brief This function returns the value of member second - * @return Value of member second - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t second() const; - - /*! - * @brief This function returns a reference to member second - * @return Reference to member second - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t& second(); - -private: - - uint8_t m__d; - - int32_t m_first{0}; - int64_t m_second{0}; -}; - - -/*! - * @brief This class represents the structure SimpleUnionStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SimpleUnionStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimpleUnionStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimpleUnionStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimpleUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleUnionStruct( - const SimpleUnionStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimpleUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleUnionStruct( - SimpleUnionStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimpleUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleUnionStruct& operator =( - const SimpleUnionStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimpleUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleUnionStruct& operator =( - SimpleUnionStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimpleUnionStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimpleUnionStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x SimpleUnionStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimpleUnionStruct& x) const; - - /*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ - eProsima_user_DllExport void my_union( - const SimpleUnion& _my_union); - - /*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ - eProsima_user_DllExport void my_union( - SimpleUnion&& _my_union); - - /*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ - eProsima_user_DllExport const SimpleUnion& my_union() const; - - /*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ - eProsima_user_DllExport SimpleUnion& my_union(); - -private: - - SimpleUnion m_my_union; - -}; - - -/*! - * @brief This class represents the structure SimpleUnionStructEqual defined by the user in the IDL file. - * @ingroup Types - */ -class SimpleUnionStructEqual -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimpleUnionStructEqual(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimpleUnionStructEqual(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimpleUnionStructEqual that will be copied. - */ - eProsima_user_DllExport SimpleUnionStructEqual( - const SimpleUnionStructEqual& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimpleUnionStructEqual that will be copied. - */ - eProsima_user_DllExport SimpleUnionStructEqual( - SimpleUnionStructEqual&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimpleUnionStructEqual that will be copied. - */ - eProsima_user_DllExport SimpleUnionStructEqual& operator =( - const SimpleUnionStructEqual& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimpleUnionStructEqual that will be copied. - */ - eProsima_user_DllExport SimpleUnionStructEqual& operator =( - SimpleUnionStructEqual&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimpleUnionStructEqual object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimpleUnionStructEqual& x) const; - - /*! - * @brief Comparison operator. - * @param x SimpleUnionStructEqual object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimpleUnionStructEqual& x) const; - - /*! - * @brief This function copies the value in member my_union_equal - * @param _my_union_equal New value to be copied in member my_union_equal - */ - eProsima_user_DllExport void my_union_equal( - const SimpleUnion& _my_union_equal); - - /*! - * @brief This function moves the value in member my_union_equal - * @param _my_union_equal New value to be moved in member my_union_equal - */ - eProsima_user_DllExport void my_union_equal( - SimpleUnion&& _my_union_equal); - - /*! - * @brief This function returns a constant reference to member my_union_equal - * @return Constant reference to member my_union_equal - */ - eProsima_user_DllExport const SimpleUnion& my_union_equal() const; - - /*! - * @brief This function returns a reference to member my_union_equal - * @return Reference to member my_union_equal - */ - eProsima_user_DllExport SimpleUnion& my_union_equal(); - -private: - - SimpleUnion m_my_union_equal; - -}; - - -/*! - * @brief This class represents the structure SimpleUnionNamesStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SimpleUnionNamesStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimpleUnionNamesStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimpleUnionNamesStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimpleUnionNamesStruct that will be copied. - */ - eProsima_user_DllExport SimpleUnionNamesStruct( - const SimpleUnionNamesStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimpleUnionNamesStruct that will be copied. - */ - eProsima_user_DllExport SimpleUnionNamesStruct( - SimpleUnionNamesStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimpleUnionNamesStruct that will be copied. - */ - eProsima_user_DllExport SimpleUnionNamesStruct& operator =( - const SimpleUnionNamesStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimpleUnionNamesStruct that will be copied. - */ - eProsima_user_DllExport SimpleUnionNamesStruct& operator =( - SimpleUnionNamesStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimpleUnionNamesStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimpleUnionNamesStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x SimpleUnionNamesStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimpleUnionNamesStruct& x) const; - - /*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ - eProsima_user_DllExport void my_union( - const SimpleUnionNames& _my_union); - - /*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ - eProsima_user_DllExport void my_union( - SimpleUnionNames&& _my_union); - - /*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ - eProsima_user_DllExport const SimpleUnionNames& my_union() const; - - /*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ - eProsima_user_DllExport SimpleUnionNames& my_union(); - -private: - - SimpleUnionNames m_my_union; - -}; - - -/*! - * @brief This class represents the structure SimpleTypeUnionStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SimpleTypeUnionStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimpleTypeUnionStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimpleTypeUnionStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimpleTypeUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleTypeUnionStruct( - const SimpleTypeUnionStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimpleTypeUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleTypeUnionStruct( - SimpleTypeUnionStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimpleTypeUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleTypeUnionStruct& operator =( - const SimpleTypeUnionStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimpleTypeUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleTypeUnionStruct& operator =( - SimpleTypeUnionStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimpleTypeUnionStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimpleTypeUnionStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x SimpleTypeUnionStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimpleTypeUnionStruct& x) const; - - /*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ - eProsima_user_DllExport void my_union( - const SimpleTypeUnion& _my_union); - - /*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ - eProsima_user_DllExport void my_union( - SimpleTypeUnion&& _my_union); - - /*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ - eProsima_user_DllExport const SimpleTypeUnion& my_union() const; - - /*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ - eProsima_user_DllExport SimpleTypeUnion& my_union(); - -private: - - SimpleTypeUnion m_my_union; - -}; - - -/*! - * @brief This class represents the structure SimpleBadUnionStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SimpleBadUnionStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimpleBadUnionStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimpleBadUnionStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimpleBadUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleBadUnionStruct( - const SimpleBadUnionStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimpleBadUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleBadUnionStruct( - SimpleBadUnionStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimpleBadUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleBadUnionStruct& operator =( - const SimpleBadUnionStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimpleBadUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleBadUnionStruct& operator =( - SimpleBadUnionStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimpleBadUnionStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimpleBadUnionStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x SimpleBadUnionStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimpleBadUnionStruct& x) const; - - /*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ - eProsima_user_DllExport void my_union( - const SimpleBadUnion& _my_union); - - /*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ - eProsima_user_DllExport void my_union( - SimpleBadUnion&& _my_union); - - /*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ - eProsima_user_DllExport const SimpleBadUnion& my_union() const; - - /*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ - eProsima_user_DllExport SimpleBadUnion& my_union(); - -private: - - SimpleBadUnion m_my_union; - -}; - - -/*! - * @brief This class represents the structure SimplBadDiscUnionStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SimplBadDiscUnionStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimplBadDiscUnionStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimplBadDiscUnionStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimplBadDiscUnionStruct that will be copied. - */ - eProsima_user_DllExport SimplBadDiscUnionStruct( - const SimplBadDiscUnionStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimplBadDiscUnionStruct that will be copied. - */ - eProsima_user_DllExport SimplBadDiscUnionStruct( - SimplBadDiscUnionStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimplBadDiscUnionStruct that will be copied. - */ - eProsima_user_DllExport SimplBadDiscUnionStruct& operator =( - const SimplBadDiscUnionStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimplBadDiscUnionStruct that will be copied. - */ - eProsima_user_DllExport SimplBadDiscUnionStruct& operator =( - SimplBadDiscUnionStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimplBadDiscUnionStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimplBadDiscUnionStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x SimplBadDiscUnionStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimplBadDiscUnionStruct& x) const; - - /*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ - eProsima_user_DllExport void my_union( - const SimpleBadDiscUnion& _my_union); - - /*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ - eProsima_user_DllExport void my_union( - SimpleBadDiscUnion&& _my_union); - - /*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ - eProsima_user_DllExport const SimpleBadDiscUnion& my_union() const; - - /*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ - eProsima_user_DllExport SimpleBadDiscUnion& my_union(); - -private: - - SimpleBadDiscUnion m_my_union; - -}; - -#endif // _FAST_DDS_GENERATED_TYPES_H_ - - - -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/test/unittest/xtypes/idl/Types.idl b/test/unittest/xtypes/idl/Types.idl deleted file mode 100644 index fea3438ed82..00000000000 --- a/test/unittest/xtypes/idl/Types.idl +++ /dev/null @@ -1,271 +0,0 @@ -// Enum - -enum MyEnum -{ - A, - B, - C -}; - -enum MyBadEnum -{ - A1, - B1, - C1 -}; - -struct MyEnumStruct -{ - MyEnum my_enum; -}; - -struct MyBadEnumStruct -{ - MyBadEnum my_enum; -}; - -// Alias - -typedef MyEnum MyAliasEnum; - -struct MyAliasEnumStruct -{ - MyAliasEnum my_enum; // Keep same name -}; - -// All basic types - -struct BasicStruct -{ - boolean my_bool; - long my_int32; - string my_string; -}; - -struct BasicNamesStruct -{ - boolean my_bool_name; - long my_int32_name; - string my_string_name; -}; - -struct BasicBadStruct -{ - octet my_bool; - long my_int32; - string my_string; -}; - -// Wide Struct - -struct BasicWideStruct -{ - boolean my_bool; - long my_int32; - string my_string; - long new_int32; - string new_string; -}; - -// Bad Wide Struct - -struct BadBasicWideStruct -{ - long new_int32; - string new_string; - boolean my_bool; - long my_int32; - string my_string; -}; - -// String bounds - -struct StringStruct -{ - string my_string; -}; - -struct LargeStringStruct -{ - string<41925> my_large_string; -}; - -// WString bounds - -struct WStringStruct -{ - wstring my_wstring; -}; - -struct LargeWStringStruct -{ - wstring<41925> my_large_wstring; -}; - -// Array dimensions and size - -struct ArrayStruct -{ - long my_array[2]; -}; - -struct ArrayStructEqual -{ - long my_array_equal[2]; -}; - -struct ArrayBadStruct -{ - octet my_array[2]; -}; - -struct ArrayDimensionsStruct -{ - long my_array[2][2]; -}; - -struct ArraySizeStruct -{ - long my_array[5]; -}; - -// Sequence bounds - -struct SequenceStruct -{ - sequence my_sequence; -}; - -struct SequenceStructEqual -{ - sequence my_sequence_equal; -}; - -struct SequenceBadStruct -{ - sequence my_sequence; -}; - -struct SequenceBoundsStruct -{ - sequence my_sequence; -}; - -struct SequenceSequenceStruct -{ - sequence, 3> my_sequence_sequence; -}; - -struct SequenceSequenceBoundsStruct -{ - sequence, 5> my_sequence_sequence; -}; - -// Map bounds - -struct MapStruct -{ - map my_map; -}; - -struct MapStructEqual -{ - map my_map_equal; -}; - -struct MapBadKeyStruct -{ - map my_map; -}; - -struct MapBadElemStruct -{ - map my_map; -}; - -struct MapBoundsStruct -{ - map my_map; -}; - -struct MapMapStruct -{ - map , 2> my_map_map; -}; - -struct MapMapBoundsStruct -{ - map , 3> my_map_map; -}; - -// Unions - -union SimpleUnion switch (long) -{ - case A: - long first; - case B: - long long second; -}; - -union SimpleUnionNames switch (long) -{ - case A: - long first_case; - case B: - long long second_case; -}; - -union SimpleTypeUnion switch (long) -{ - case A: - octet first; - case B: - long long second; -}; - -union SimpleBadUnion switch (long) -{ - case A: - long first; - case C: - long long second; -}; - -union SimpleBadDiscUnion switch (octet) -{ - case 0: - long first; - case 1: - long long second; -}; - -struct SimpleUnionStruct -{ - SimpleUnion my_union; -}; - -struct SimpleUnionStructEqual -{ - SimpleUnion my_union_equal; -}; - -struct SimpleUnionNamesStruct -{ - SimpleUnionNames my_union; -}; - -struct SimpleTypeUnionStruct -{ - SimpleTypeUnion my_union; -}; - -struct SimpleBadUnionStruct -{ - SimpleBadUnion my_union; -}; - -struct SimplBadDiscUnionStruct -{ - SimpleBadDiscUnion my_union; -}; \ No newline at end of file diff --git a/test/unittest/xtypes/idl/TypesCdrAux.hpp b/test/unittest/xtypes/idl/TypesCdrAux.hpp deleted file mode 100644 index 14992724933..00000000000 --- a/test/unittest/xtypes/idl/TypesCdrAux.hpp +++ /dev/null @@ -1,427 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file TypesCdrAux.hpp - * This source file contains some definitions of CDR related functions. - * - * This file was generated by the tool fastddsgen. - */ - -#ifndef _FAST_DDS_GENERATED_TYPESCDRAUX_HPP_ -#define _FAST_DDS_GENERATED_TYPESCDRAUX_HPP_ - -#include "Types.h" - -constexpr uint32_t SimpleUnionStruct_max_cdr_typesize {24UL}; -constexpr uint32_t SimpleUnionStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t SequenceSequenceBoundsStruct_max_cdr_typesize {132UL}; -constexpr uint32_t SequenceSequenceBoundsStruct_max_key_cdr_typesize {0UL}; - - -constexpr uint32_t MyAliasEnumStruct_max_cdr_typesize {8UL}; -constexpr uint32_t MyAliasEnumStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t ArrayBadStruct_max_cdr_typesize {6UL}; -constexpr uint32_t ArrayBadStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t MapBadKeyStruct_max_cdr_typesize {24UL}; -constexpr uint32_t MapBadKeyStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t SimpleBadUnionStruct_max_cdr_typesize {24UL}; -constexpr uint32_t SimpleBadUnionStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t MyEnumStruct_max_cdr_typesize {8UL}; -constexpr uint32_t MyEnumStruct_max_key_cdr_typesize {0UL}; - - -constexpr uint32_t ArrayStructEqual_max_cdr_typesize {12UL}; -constexpr uint32_t ArrayStructEqual_max_key_cdr_typesize {0UL}; - -constexpr uint32_t LargeWStringStruct_max_cdr_typesize {83858UL}; -constexpr uint32_t LargeWStringStruct_max_key_cdr_typesize {0UL}; - - -constexpr uint32_t WStringStruct_max_cdr_typesize {518UL}; -constexpr uint32_t WStringStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t SequenceStruct_max_cdr_typesize {16UL}; -constexpr uint32_t SequenceStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t SimpleTypeUnionStruct_max_cdr_typesize {24UL}; -constexpr uint32_t SimpleTypeUnionStruct_max_key_cdr_typesize {0UL}; - - -constexpr uint32_t ArrayDimensionsStruct_max_cdr_typesize {20UL}; -constexpr uint32_t ArrayDimensionsStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t SequenceSequenceStruct_max_cdr_typesize {48UL}; -constexpr uint32_t SequenceSequenceStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t MapBoundsStruct_max_cdr_typesize {40UL}; -constexpr uint32_t MapBoundsStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t SequenceStructEqual_max_cdr_typesize {16UL}; -constexpr uint32_t SequenceStructEqual_max_key_cdr_typesize {0UL}; - -constexpr uint32_t MapStructEqual_max_cdr_typesize {24UL}; -constexpr uint32_t MapStructEqual_max_key_cdr_typesize {0UL}; - -constexpr uint32_t BasicStruct_max_cdr_typesize {272UL}; -constexpr uint32_t BasicStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t SequenceBoundsStruct_max_cdr_typesize {24UL}; -constexpr uint32_t SequenceBoundsStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t MapMapStruct_max_cdr_typesize {60UL}; -constexpr uint32_t MapMapStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t BasicWideStruct_max_cdr_typesize {536UL}; -constexpr uint32_t BasicWideStruct_max_key_cdr_typesize {0UL}; - - -constexpr uint32_t SimplBadDiscUnionStruct_max_cdr_typesize {24UL}; -constexpr uint32_t SimplBadDiscUnionStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t MapStruct_max_cdr_typesize {24UL}; -constexpr uint32_t MapStruct_max_key_cdr_typesize {0UL}; - - -constexpr uint32_t MyBadEnumStruct_max_cdr_typesize {8UL}; -constexpr uint32_t MyBadEnumStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t SequenceBadStruct_max_cdr_typesize {10UL}; -constexpr uint32_t SequenceBadStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t SimpleUnionNamesStruct_max_cdr_typesize {24UL}; -constexpr uint32_t SimpleUnionNamesStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t LargeStringStruct_max_cdr_typesize {41934UL}; -constexpr uint32_t LargeStringStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t ArrayStruct_max_cdr_typesize {12UL}; -constexpr uint32_t ArrayStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t BadBasicWideStruct_max_cdr_typesize {536UL}; -constexpr uint32_t BadBasicWideStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t ArraySizeStruct_max_cdr_typesize {24UL}; -constexpr uint32_t ArraySizeStruct_max_key_cdr_typesize {0UL}; - - -constexpr uint32_t MapBadElemStruct_max_cdr_typesize {40UL}; -constexpr uint32_t MapBadElemStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t SimpleUnionStructEqual_max_cdr_typesize {24UL}; -constexpr uint32_t SimpleUnionStructEqual_max_key_cdr_typesize {0UL}; - -constexpr uint32_t BasicBadStruct_max_cdr_typesize {272UL}; -constexpr uint32_t BasicBadStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t BasicNamesStruct_max_cdr_typesize {272UL}; -constexpr uint32_t BasicNamesStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t StringStruct_max_cdr_typesize {264UL}; -constexpr uint32_t StringStruct_max_key_cdr_typesize {0UL}; - - -constexpr uint32_t MapMapBoundsStruct_max_cdr_typesize {108UL}; -constexpr uint32_t MapMapBoundsStruct_max_key_cdr_typesize {0UL}; - - -namespace eprosima { -namespace fastcdr { - -class Cdr; -class CdrSizeCalculator; - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const MyEnumStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const MyBadEnumStruct& data); - - - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const MyAliasEnumStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const BasicStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const BasicNamesStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const BasicBadStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const BasicWideStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const BadBasicWideStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const StringStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const LargeStringStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const WStringStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const LargeWStringStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const ArrayStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const ArrayStructEqual& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const ArrayBadStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const ArrayDimensionsStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const ArraySizeStruct& data); - - - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SequenceStruct& data); - - - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SequenceStructEqual& data); - - - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SequenceBadStruct& data); - - - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SequenceBoundsStruct& data); - - - - - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SequenceSequenceStruct& data); - - - - - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SequenceSequenceBoundsStruct& data); - - - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const MapStruct& data); - - - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const MapStructEqual& data); - - - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const MapBadKeyStruct& data); - - - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const MapBadElemStruct& data); - - - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const MapBoundsStruct& data); - - - - - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const MapMapStruct& data); - - - - - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const MapMapBoundsStruct& data); - - - - - - - - - - - - - - - - - - - - - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SimpleUnionStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SimpleUnionStructEqual& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SimpleUnionNamesStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SimpleTypeUnionStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SimpleBadUnionStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SimplBadDiscUnionStruct& data); - - -} // namespace fastcdr -} // namespace eprosima - -#endif // _FAST_DDS_GENERATED_TYPESCDRAUX_HPP_ - diff --git a/test/unittest/xtypes/idl/TypesCdrAux.ipp b/test/unittest/xtypes/idl/TypesCdrAux.ipp deleted file mode 100644 index 5d6735bcfef..00000000000 --- a/test/unittest/xtypes/idl/TypesCdrAux.ipp +++ /dev/null @@ -1,3543 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file TypesCdrAux.ipp - * This source file contains some declarations of CDR related functions. - * - * This file was generated by the tool fastddsgen. - */ - -#ifndef _FAST_DDS_GENERATED_TYPESCDRAUX_IPP_ -#define _FAST_DDS_GENERATED_TYPESCDRAUX_IPP_ - -#include "TypesCdrAux.hpp" - -#include -#include - - -#include -using namespace eprosima::fastcdr::exception; - -namespace eprosima { -namespace fastcdr { - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const MyEnumStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_enum(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const MyEnumStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_enum() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - MyEnumStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_enum(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const MyEnumStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const MyBadEnumStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_enum(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const MyBadEnumStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_enum() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - MyBadEnumStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_enum(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const MyBadEnumStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const MyAliasEnumStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_enum(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const MyAliasEnumStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_enum() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - MyAliasEnumStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_enum(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const MyAliasEnumStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const BasicStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_bool(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(1), - data.my_int32(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(2), - data.my_string(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const BasicStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_bool() - << eprosima::fastcdr::MemberId(1) << data.my_int32() - << eprosima::fastcdr::MemberId(2) << data.my_string() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - BasicStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_bool(); - break; - - case 1: - dcdr >> data.my_int32(); - break; - - case 2: - dcdr >> data.my_string(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const BasicStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const BasicNamesStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_bool_name(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(1), - data.my_int32_name(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(2), - data.my_string_name(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const BasicNamesStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_bool_name() - << eprosima::fastcdr::MemberId(1) << data.my_int32_name() - << eprosima::fastcdr::MemberId(2) << data.my_string_name() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - BasicNamesStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_bool_name(); - break; - - case 1: - dcdr >> data.my_int32_name(); - break; - - case 2: - dcdr >> data.my_string_name(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const BasicNamesStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const BasicBadStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_bool(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(1), - data.my_int32(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(2), - data.my_string(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const BasicBadStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_bool() - << eprosima::fastcdr::MemberId(1) << data.my_int32() - << eprosima::fastcdr::MemberId(2) << data.my_string() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - BasicBadStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_bool(); - break; - - case 1: - dcdr >> data.my_int32(); - break; - - case 2: - dcdr >> data.my_string(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const BasicBadStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const BasicWideStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_bool(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(1), - data.my_int32(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(2), - data.my_string(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(3), - data.new_int32(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(4), - data.new_string(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const BasicWideStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_bool() - << eprosima::fastcdr::MemberId(1) << data.my_int32() - << eprosima::fastcdr::MemberId(2) << data.my_string() - << eprosima::fastcdr::MemberId(3) << data.new_int32() - << eprosima::fastcdr::MemberId(4) << data.new_string() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - BasicWideStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_bool(); - break; - - case 1: - dcdr >> data.my_int32(); - break; - - case 2: - dcdr >> data.my_string(); - break; - - case 3: - dcdr >> data.new_int32(); - break; - - case 4: - dcdr >> data.new_string(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const BasicWideStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const BadBasicWideStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.new_int32(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(1), - data.new_string(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(2), - data.my_bool(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(3), - data.my_int32(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(4), - data.my_string(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const BadBasicWideStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.new_int32() - << eprosima::fastcdr::MemberId(1) << data.new_string() - << eprosima::fastcdr::MemberId(2) << data.my_bool() - << eprosima::fastcdr::MemberId(3) << data.my_int32() - << eprosima::fastcdr::MemberId(4) << data.my_string() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - BadBasicWideStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.new_int32(); - break; - - case 1: - dcdr >> data.new_string(); - break; - - case 2: - dcdr >> data.my_bool(); - break; - - case 3: - dcdr >> data.my_int32(); - break; - - case 4: - dcdr >> data.my_string(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const BadBasicWideStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const StringStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_string(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const StringStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_string() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - StringStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_string(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const StringStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const LargeStringStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_large_string(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const LargeStringStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_large_string() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - LargeStringStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_large_string(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const LargeStringStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const WStringStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_wstring(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const WStringStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_wstring() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - WStringStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_wstring(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const WStringStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const LargeWStringStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_large_wstring(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const LargeWStringStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_large_wstring() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - LargeWStringStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_large_wstring(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const LargeWStringStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const ArrayStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_array(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const ArrayStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_array() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - ArrayStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_array(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const ArrayStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const ArrayStructEqual& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_array_equal(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const ArrayStructEqual& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_array_equal() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - ArrayStructEqual& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_array_equal(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const ArrayStructEqual& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const ArrayBadStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_array(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const ArrayBadStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_array() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - ArrayBadStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_array(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const ArrayBadStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const ArrayDimensionsStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_array(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const ArrayDimensionsStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_array() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - ArrayDimensionsStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_array(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const ArrayDimensionsStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const ArraySizeStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_array(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const ArraySizeStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_array() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - ArraySizeStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_array(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const ArraySizeStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const SequenceStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_sequence(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const SequenceStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_sequence() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - SequenceStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_sequence(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SequenceStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const SequenceStructEqual& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_sequence_equal(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const SequenceStructEqual& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_sequence_equal() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - SequenceStructEqual& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_sequence_equal(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SequenceStructEqual& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const SequenceBadStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_sequence(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const SequenceBadStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_sequence() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - SequenceBadStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_sequence(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SequenceBadStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const SequenceBoundsStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_sequence(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const SequenceBoundsStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_sequence() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - SequenceBoundsStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_sequence(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SequenceBoundsStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const SequenceSequenceStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_sequence_sequence(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const SequenceSequenceStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_sequence_sequence() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - SequenceSequenceStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_sequence_sequence(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SequenceSequenceStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const SequenceSequenceBoundsStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_sequence_sequence(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const SequenceSequenceBoundsStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_sequence_sequence() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - SequenceSequenceBoundsStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_sequence_sequence(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SequenceSequenceBoundsStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const MapStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_map(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const MapStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_map() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - MapStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_map(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const MapStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const MapStructEqual& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_map_equal(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const MapStructEqual& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_map_equal() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - MapStructEqual& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_map_equal(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const MapStructEqual& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const MapBadKeyStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_map(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const MapBadKeyStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_map() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - MapBadKeyStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_map(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const MapBadKeyStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const MapBadElemStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_map(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const MapBadElemStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_map() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - MapBadElemStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_map(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const MapBadElemStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const MapBoundsStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_map(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const MapBoundsStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_map() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - MapBoundsStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_map(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const MapBoundsStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const MapMapStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_map_map(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const MapMapStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_map_map() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - MapMapStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_map_map(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const MapMapStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const MapMapBoundsStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_map_map(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const MapMapBoundsStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_map_map() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - MapMapBoundsStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_map_map(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const MapMapBoundsStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const SimpleUnion& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), data._d(), - current_alignment); - - switch (data._d()) - { - case A: - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(1), - data.first(), current_alignment); - break; - - case B: - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(2), - data.second(), current_alignment); - break; - - default: - break; - } - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const SimpleUnion& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr << eprosima::fastcdr::MemberId(0) << data._d(); - - switch (data._d()) - { - case A: - scdr << eprosima::fastcdr::MemberId(1) << data.first(); - break; - - case B: - scdr << eprosima::fastcdr::MemberId(2) << data.second(); - break; - - default: - break; - } - - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - SimpleUnion& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data._d(); - break; - default: - switch (data._d()) - { - case A: - dcdr >> data.first(); - break; - - case B: - dcdr >> data.second(); - break; - - default: - break; - } - ret_value = false; - break; - } - return ret_value; - }); -} - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const SimpleUnionNames& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), data._d(), - current_alignment); - - switch (data._d()) - { - case A: - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(1), - data.first_case(), current_alignment); - break; - - case B: - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(2), - data.second_case(), current_alignment); - break; - - default: - break; - } - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const SimpleUnionNames& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr << eprosima::fastcdr::MemberId(0) << data._d(); - - switch (data._d()) - { - case A: - scdr << eprosima::fastcdr::MemberId(1) << data.first_case(); - break; - - case B: - scdr << eprosima::fastcdr::MemberId(2) << data.second_case(); - break; - - default: - break; - } - - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - SimpleUnionNames& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data._d(); - break; - default: - switch (data._d()) - { - case A: - dcdr >> data.first_case(); - break; - - case B: - dcdr >> data.second_case(); - break; - - default: - break; - } - ret_value = false; - break; - } - return ret_value; - }); -} - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const SimpleTypeUnion& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), data._d(), - current_alignment); - - switch (data._d()) - { - case A: - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(1), - data.first(), current_alignment); - break; - - case B: - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(2), - data.second(), current_alignment); - break; - - default: - break; - } - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const SimpleTypeUnion& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr << eprosima::fastcdr::MemberId(0) << data._d(); - - switch (data._d()) - { - case A: - scdr << eprosima::fastcdr::MemberId(1) << data.first(); - break; - - case B: - scdr << eprosima::fastcdr::MemberId(2) << data.second(); - break; - - default: - break; - } - - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - SimpleTypeUnion& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data._d(); - break; - default: - switch (data._d()) - { - case A: - dcdr >> data.first(); - break; - - case B: - dcdr >> data.second(); - break; - - default: - break; - } - ret_value = false; - break; - } - return ret_value; - }); -} - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const SimpleBadUnion& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), data._d(), - current_alignment); - - switch (data._d()) - { - case A: - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(1), - data.first(), current_alignment); - break; - - case C: - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(2), - data.second(), current_alignment); - break; - - default: - break; - } - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const SimpleBadUnion& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr << eprosima::fastcdr::MemberId(0) << data._d(); - - switch (data._d()) - { - case A: - scdr << eprosima::fastcdr::MemberId(1) << data.first(); - break; - - case C: - scdr << eprosima::fastcdr::MemberId(2) << data.second(); - break; - - default: - break; - } - - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - SimpleBadUnion& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data._d(); - break; - default: - switch (data._d()) - { - case A: - dcdr >> data.first(); - break; - - case C: - dcdr >> data.second(); - break; - - default: - break; - } - ret_value = false; - break; - } - return ret_value; - }); -} - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const SimpleBadDiscUnion& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), data._d(), - current_alignment); - - switch (data._d()) - { - case 0: - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(1), - data.first(), current_alignment); - break; - - case 1: - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(2), - data.second(), current_alignment); - break; - - default: - break; - } - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const SimpleBadDiscUnion& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr << eprosima::fastcdr::MemberId(0) << data._d(); - - switch (data._d()) - { - case 0: - scdr << eprosima::fastcdr::MemberId(1) << data.first(); - break; - - case 1: - scdr << eprosima::fastcdr::MemberId(2) << data.second(); - break; - - default: - break; - } - - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - SimpleBadDiscUnion& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data._d(); - break; - default: - switch (data._d()) - { - case 0: - dcdr >> data.first(); - break; - - case 1: - dcdr >> data.second(); - break; - - default: - break; - } - ret_value = false; - break; - } - return ret_value; - }); -} - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const SimpleUnionStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_union(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const SimpleUnionStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_union() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - SimpleUnionStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_union(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SimpleUnionStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const SimpleUnionStructEqual& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_union_equal(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const SimpleUnionStructEqual& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_union_equal() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - SimpleUnionStructEqual& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_union_equal(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SimpleUnionStructEqual& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const SimpleUnionNamesStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_union(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const SimpleUnionNamesStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_union() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - SimpleUnionNamesStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_union(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SimpleUnionNamesStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const SimpleTypeUnionStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_union(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const SimpleTypeUnionStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_union() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - SimpleTypeUnionStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_union(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SimpleTypeUnionStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const SimpleBadUnionStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_union(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const SimpleBadUnionStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_union() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - SimpleBadUnionStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_union(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SimpleBadUnionStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const SimplBadDiscUnionStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_union(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const SimplBadDiscUnionStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_union() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - SimplBadDiscUnionStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_union(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SimplBadDiscUnionStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - -} // namespace fastcdr -} // namespace eprosima - -#endif // _FAST_DDS_GENERATED_TYPESCDRAUX_IPP_ - diff --git a/test/unittest/xtypes/idl/TypesPubSubTypes.cxx b/test/unittest/xtypes/idl/TypesPubSubTypes.cxx deleted file mode 100644 index 0c0a8f0363e..00000000000 --- a/test/unittest/xtypes/idl/TypesPubSubTypes.cxx +++ /dev/null @@ -1,6927 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file TypesPubSubTypes.cpp - * This header file contains the implementation of the serialization functions. - * - * This file was generated by the tool fastddsgen. - */ - - -#include - -#include "TypesPubSubTypes.h" -#include "TypesCdrAux.hpp" - -using SerializedPayload_t = eprosima::fastrtps::rtps::SerializedPayload_t; -using InstanceHandle_t = eprosima::fastrtps::rtps::InstanceHandle_t; -using DataRepresentationId_t = eprosima::fastdds::dds::DataRepresentationId_t; - - - -MyEnumStructPubSubType::MyEnumStructPubSubType() -{ - setName("MyEnumStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(MyEnumStruct::getMaxCdrSerializedSize()); -#else - MyEnumStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = MyEnumStruct_max_key_cdr_typesize > 16 ? MyEnumStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -MyEnumStructPubSubType::~MyEnumStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool MyEnumStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - MyEnumStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool MyEnumStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - MyEnumStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function MyEnumStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* MyEnumStructPubSubType::createData() -{ - return reinterpret_cast(new MyEnumStruct()); -} - -void MyEnumStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool MyEnumStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - MyEnumStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - MyEnumStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || MyEnumStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -MyBadEnumStructPubSubType::MyBadEnumStructPubSubType() -{ - setName("MyBadEnumStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(MyBadEnumStruct::getMaxCdrSerializedSize()); -#else - MyBadEnumStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = MyBadEnumStruct_max_key_cdr_typesize > 16 ? MyBadEnumStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -MyBadEnumStructPubSubType::~MyBadEnumStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool MyBadEnumStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - MyBadEnumStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool MyBadEnumStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - MyBadEnumStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function MyBadEnumStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* MyBadEnumStructPubSubType::createData() -{ - return reinterpret_cast(new MyBadEnumStruct()); -} - -void MyBadEnumStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool MyBadEnumStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - MyBadEnumStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - MyBadEnumStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || MyBadEnumStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - - - -MyAliasEnumStructPubSubType::MyAliasEnumStructPubSubType() -{ - setName("MyAliasEnumStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(MyAliasEnumStruct::getMaxCdrSerializedSize()); -#else - MyAliasEnumStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = MyAliasEnumStruct_max_key_cdr_typesize > 16 ? MyAliasEnumStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -MyAliasEnumStructPubSubType::~MyAliasEnumStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool MyAliasEnumStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - MyAliasEnumStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool MyAliasEnumStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - MyAliasEnumStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function MyAliasEnumStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* MyAliasEnumStructPubSubType::createData() -{ - return reinterpret_cast(new MyAliasEnumStruct()); -} - -void MyAliasEnumStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool MyAliasEnumStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - MyAliasEnumStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - MyAliasEnumStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || MyAliasEnumStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -BasicStructPubSubType::BasicStructPubSubType() -{ - setName("BasicStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(BasicStruct::getMaxCdrSerializedSize()); -#else - BasicStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = BasicStruct_max_key_cdr_typesize > 16 ? BasicStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -BasicStructPubSubType::~BasicStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool BasicStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - BasicStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool BasicStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - BasicStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function BasicStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* BasicStructPubSubType::createData() -{ - return reinterpret_cast(new BasicStruct()); -} - -void BasicStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool BasicStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - BasicStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - BasicStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || BasicStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -BasicNamesStructPubSubType::BasicNamesStructPubSubType() -{ - setName("BasicNamesStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(BasicNamesStruct::getMaxCdrSerializedSize()); -#else - BasicNamesStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = BasicNamesStruct_max_key_cdr_typesize > 16 ? BasicNamesStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -BasicNamesStructPubSubType::~BasicNamesStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool BasicNamesStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - BasicNamesStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool BasicNamesStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - BasicNamesStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function BasicNamesStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* BasicNamesStructPubSubType::createData() -{ - return reinterpret_cast(new BasicNamesStruct()); -} - -void BasicNamesStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool BasicNamesStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - BasicNamesStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - BasicNamesStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || BasicNamesStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -BasicBadStructPubSubType::BasicBadStructPubSubType() -{ - setName("BasicBadStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(BasicBadStruct::getMaxCdrSerializedSize()); -#else - BasicBadStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = BasicBadStruct_max_key_cdr_typesize > 16 ? BasicBadStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -BasicBadStructPubSubType::~BasicBadStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool BasicBadStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - BasicBadStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool BasicBadStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - BasicBadStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function BasicBadStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* BasicBadStructPubSubType::createData() -{ - return reinterpret_cast(new BasicBadStruct()); -} - -void BasicBadStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool BasicBadStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - BasicBadStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - BasicBadStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || BasicBadStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -BasicWideStructPubSubType::BasicWideStructPubSubType() -{ - setName("BasicWideStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(BasicWideStruct::getMaxCdrSerializedSize()); -#else - BasicWideStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = BasicWideStruct_max_key_cdr_typesize > 16 ? BasicWideStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -BasicWideStructPubSubType::~BasicWideStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool BasicWideStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - BasicWideStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool BasicWideStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - BasicWideStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function BasicWideStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* BasicWideStructPubSubType::createData() -{ - return reinterpret_cast(new BasicWideStruct()); -} - -void BasicWideStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool BasicWideStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - BasicWideStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - BasicWideStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || BasicWideStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -BadBasicWideStructPubSubType::BadBasicWideStructPubSubType() -{ - setName("BadBasicWideStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(BadBasicWideStruct::getMaxCdrSerializedSize()); -#else - BadBasicWideStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = BadBasicWideStruct_max_key_cdr_typesize > 16 ? BadBasicWideStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -BadBasicWideStructPubSubType::~BadBasicWideStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool BadBasicWideStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - BadBasicWideStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool BadBasicWideStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - BadBasicWideStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function BadBasicWideStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* BadBasicWideStructPubSubType::createData() -{ - return reinterpret_cast(new BadBasicWideStruct()); -} - -void BadBasicWideStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool BadBasicWideStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - BadBasicWideStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - BadBasicWideStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || BadBasicWideStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -StringStructPubSubType::StringStructPubSubType() -{ - setName("StringStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(StringStruct::getMaxCdrSerializedSize()); -#else - StringStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = StringStruct_max_key_cdr_typesize > 16 ? StringStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -StringStructPubSubType::~StringStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool StringStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - StringStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool StringStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - StringStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function StringStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* StringStructPubSubType::createData() -{ - return reinterpret_cast(new StringStruct()); -} - -void StringStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool StringStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - StringStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - StringStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || StringStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -LargeStringStructPubSubType::LargeStringStructPubSubType() -{ - setName("LargeStringStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(LargeStringStruct::getMaxCdrSerializedSize()); -#else - LargeStringStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = LargeStringStruct_max_key_cdr_typesize > 16 ? LargeStringStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -LargeStringStructPubSubType::~LargeStringStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool LargeStringStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - LargeStringStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool LargeStringStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - LargeStringStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function LargeStringStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* LargeStringStructPubSubType::createData() -{ - return reinterpret_cast(new LargeStringStruct()); -} - -void LargeStringStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool LargeStringStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - LargeStringStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - LargeStringStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || LargeStringStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -WStringStructPubSubType::WStringStructPubSubType() -{ - setName("WStringStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(WStringStruct::getMaxCdrSerializedSize()); -#else - WStringStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = WStringStruct_max_key_cdr_typesize > 16 ? WStringStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -WStringStructPubSubType::~WStringStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool WStringStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - WStringStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool WStringStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - WStringStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function WStringStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* WStringStructPubSubType::createData() -{ - return reinterpret_cast(new WStringStruct()); -} - -void WStringStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool WStringStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - WStringStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - WStringStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || WStringStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -LargeWStringStructPubSubType::LargeWStringStructPubSubType() -{ - setName("LargeWStringStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(LargeWStringStruct::getMaxCdrSerializedSize()); -#else - LargeWStringStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = LargeWStringStruct_max_key_cdr_typesize > 16 ? LargeWStringStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -LargeWStringStructPubSubType::~LargeWStringStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool LargeWStringStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - LargeWStringStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool LargeWStringStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - LargeWStringStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function LargeWStringStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* LargeWStringStructPubSubType::createData() -{ - return reinterpret_cast(new LargeWStringStruct()); -} - -void LargeWStringStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool LargeWStringStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - LargeWStringStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - LargeWStringStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || LargeWStringStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -ArrayStructPubSubType::ArrayStructPubSubType() -{ - setName("ArrayStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(ArrayStruct::getMaxCdrSerializedSize()); -#else - ArrayStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = ArrayStruct_max_key_cdr_typesize > 16 ? ArrayStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -ArrayStructPubSubType::~ArrayStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool ArrayStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - ArrayStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool ArrayStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - ArrayStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function ArrayStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* ArrayStructPubSubType::createData() -{ - return reinterpret_cast(new ArrayStruct()); -} - -void ArrayStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool ArrayStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - ArrayStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - ArrayStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || ArrayStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -ArrayStructEqualPubSubType::ArrayStructEqualPubSubType() -{ - setName("ArrayStructEqual"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(ArrayStructEqual::getMaxCdrSerializedSize()); -#else - ArrayStructEqual_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = ArrayStructEqual_max_key_cdr_typesize > 16 ? ArrayStructEqual_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -ArrayStructEqualPubSubType::~ArrayStructEqualPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool ArrayStructEqualPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - ArrayStructEqual* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool ArrayStructEqualPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - ArrayStructEqual* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function ArrayStructEqualPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* ArrayStructEqualPubSubType::createData() -{ - return reinterpret_cast(new ArrayStructEqual()); -} - -void ArrayStructEqualPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool ArrayStructEqualPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - ArrayStructEqual* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - ArrayStructEqual_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || ArrayStructEqual_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -ArrayBadStructPubSubType::ArrayBadStructPubSubType() -{ - setName("ArrayBadStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(ArrayBadStruct::getMaxCdrSerializedSize()); -#else - ArrayBadStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = ArrayBadStruct_max_key_cdr_typesize > 16 ? ArrayBadStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -ArrayBadStructPubSubType::~ArrayBadStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool ArrayBadStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - ArrayBadStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool ArrayBadStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - ArrayBadStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function ArrayBadStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* ArrayBadStructPubSubType::createData() -{ - return reinterpret_cast(new ArrayBadStruct()); -} - -void ArrayBadStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool ArrayBadStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - ArrayBadStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - ArrayBadStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || ArrayBadStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -ArrayDimensionsStructPubSubType::ArrayDimensionsStructPubSubType() -{ - setName("ArrayDimensionsStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(ArrayDimensionsStruct::getMaxCdrSerializedSize()); -#else - ArrayDimensionsStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = ArrayDimensionsStruct_max_key_cdr_typesize > 16 ? ArrayDimensionsStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -ArrayDimensionsStructPubSubType::~ArrayDimensionsStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool ArrayDimensionsStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - ArrayDimensionsStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool ArrayDimensionsStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - ArrayDimensionsStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function ArrayDimensionsStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* ArrayDimensionsStructPubSubType::createData() -{ - return reinterpret_cast(new ArrayDimensionsStruct()); -} - -void ArrayDimensionsStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool ArrayDimensionsStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - ArrayDimensionsStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - ArrayDimensionsStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || ArrayDimensionsStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -ArraySizeStructPubSubType::ArraySizeStructPubSubType() -{ - setName("ArraySizeStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(ArraySizeStruct::getMaxCdrSerializedSize()); -#else - ArraySizeStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = ArraySizeStruct_max_key_cdr_typesize > 16 ? ArraySizeStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -ArraySizeStructPubSubType::~ArraySizeStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool ArraySizeStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - ArraySizeStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool ArraySizeStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - ArraySizeStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function ArraySizeStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* ArraySizeStructPubSubType::createData() -{ - return reinterpret_cast(new ArraySizeStruct()); -} - -void ArraySizeStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool ArraySizeStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - ArraySizeStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - ArraySizeStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || ArraySizeStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - - - -SequenceStructPubSubType::SequenceStructPubSubType() -{ - setName("SequenceStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(SequenceStruct::getMaxCdrSerializedSize()); -#else - SequenceStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = SequenceStruct_max_key_cdr_typesize > 16 ? SequenceStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -SequenceStructPubSubType::~SequenceStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool SequenceStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - SequenceStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool SequenceStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - SequenceStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function SequenceStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* SequenceStructPubSubType::createData() -{ - return reinterpret_cast(new SequenceStruct()); -} - -void SequenceStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool SequenceStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - SequenceStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - SequenceStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || SequenceStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - - - -SequenceStructEqualPubSubType::SequenceStructEqualPubSubType() -{ - setName("SequenceStructEqual"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(SequenceStructEqual::getMaxCdrSerializedSize()); -#else - SequenceStructEqual_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = SequenceStructEqual_max_key_cdr_typesize > 16 ? SequenceStructEqual_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -SequenceStructEqualPubSubType::~SequenceStructEqualPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool SequenceStructEqualPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - SequenceStructEqual* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool SequenceStructEqualPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - SequenceStructEqual* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function SequenceStructEqualPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* SequenceStructEqualPubSubType::createData() -{ - return reinterpret_cast(new SequenceStructEqual()); -} - -void SequenceStructEqualPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool SequenceStructEqualPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - SequenceStructEqual* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - SequenceStructEqual_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || SequenceStructEqual_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - - - -SequenceBadStructPubSubType::SequenceBadStructPubSubType() -{ - setName("SequenceBadStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(SequenceBadStruct::getMaxCdrSerializedSize()); -#else - SequenceBadStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = SequenceBadStruct_max_key_cdr_typesize > 16 ? SequenceBadStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -SequenceBadStructPubSubType::~SequenceBadStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool SequenceBadStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - SequenceBadStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool SequenceBadStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - SequenceBadStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function SequenceBadStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* SequenceBadStructPubSubType::createData() -{ - return reinterpret_cast(new SequenceBadStruct()); -} - -void SequenceBadStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool SequenceBadStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - SequenceBadStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - SequenceBadStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || SequenceBadStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - - - -SequenceBoundsStructPubSubType::SequenceBoundsStructPubSubType() -{ - setName("SequenceBoundsStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(SequenceBoundsStruct::getMaxCdrSerializedSize()); -#else - SequenceBoundsStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = SequenceBoundsStruct_max_key_cdr_typesize > 16 ? SequenceBoundsStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -SequenceBoundsStructPubSubType::~SequenceBoundsStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool SequenceBoundsStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - SequenceBoundsStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool SequenceBoundsStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - SequenceBoundsStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function SequenceBoundsStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* SequenceBoundsStructPubSubType::createData() -{ - return reinterpret_cast(new SequenceBoundsStruct()); -} - -void SequenceBoundsStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool SequenceBoundsStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - SequenceBoundsStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - SequenceBoundsStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || SequenceBoundsStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - - - - - -SequenceSequenceStructPubSubType::SequenceSequenceStructPubSubType() -{ - setName("SequenceSequenceStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(SequenceSequenceStruct::getMaxCdrSerializedSize()); -#else - SequenceSequenceStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = SequenceSequenceStruct_max_key_cdr_typesize > 16 ? SequenceSequenceStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -SequenceSequenceStructPubSubType::~SequenceSequenceStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool SequenceSequenceStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - SequenceSequenceStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool SequenceSequenceStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - SequenceSequenceStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function SequenceSequenceStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* SequenceSequenceStructPubSubType::createData() -{ - return reinterpret_cast(new SequenceSequenceStruct()); -} - -void SequenceSequenceStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool SequenceSequenceStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - SequenceSequenceStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - SequenceSequenceStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || SequenceSequenceStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - - - - - -SequenceSequenceBoundsStructPubSubType::SequenceSequenceBoundsStructPubSubType() -{ - setName("SequenceSequenceBoundsStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(SequenceSequenceBoundsStruct::getMaxCdrSerializedSize()); -#else - SequenceSequenceBoundsStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = SequenceSequenceBoundsStruct_max_key_cdr_typesize > 16 ? SequenceSequenceBoundsStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -SequenceSequenceBoundsStructPubSubType::~SequenceSequenceBoundsStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool SequenceSequenceBoundsStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - SequenceSequenceBoundsStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool SequenceSequenceBoundsStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - SequenceSequenceBoundsStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function SequenceSequenceBoundsStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* SequenceSequenceBoundsStructPubSubType::createData() -{ - return reinterpret_cast(new SequenceSequenceBoundsStruct()); -} - -void SequenceSequenceBoundsStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool SequenceSequenceBoundsStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - SequenceSequenceBoundsStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - SequenceSequenceBoundsStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || SequenceSequenceBoundsStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - - - -MapStructPubSubType::MapStructPubSubType() -{ - setName("MapStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(MapStruct::getMaxCdrSerializedSize()); -#else - MapStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = MapStruct_max_key_cdr_typesize > 16 ? MapStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -MapStructPubSubType::~MapStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool MapStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - MapStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool MapStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - MapStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function MapStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* MapStructPubSubType::createData() -{ - return reinterpret_cast(new MapStruct()); -} - -void MapStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool MapStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - MapStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - MapStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || MapStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - - - -MapStructEqualPubSubType::MapStructEqualPubSubType() -{ - setName("MapStructEqual"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(MapStructEqual::getMaxCdrSerializedSize()); -#else - MapStructEqual_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = MapStructEqual_max_key_cdr_typesize > 16 ? MapStructEqual_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -MapStructEqualPubSubType::~MapStructEqualPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool MapStructEqualPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - MapStructEqual* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool MapStructEqualPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - MapStructEqual* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function MapStructEqualPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* MapStructEqualPubSubType::createData() -{ - return reinterpret_cast(new MapStructEqual()); -} - -void MapStructEqualPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool MapStructEqualPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - MapStructEqual* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - MapStructEqual_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || MapStructEqual_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - - - -MapBadKeyStructPubSubType::MapBadKeyStructPubSubType() -{ - setName("MapBadKeyStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(MapBadKeyStruct::getMaxCdrSerializedSize()); -#else - MapBadKeyStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = MapBadKeyStruct_max_key_cdr_typesize > 16 ? MapBadKeyStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -MapBadKeyStructPubSubType::~MapBadKeyStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool MapBadKeyStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - MapBadKeyStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool MapBadKeyStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - MapBadKeyStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function MapBadKeyStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* MapBadKeyStructPubSubType::createData() -{ - return reinterpret_cast(new MapBadKeyStruct()); -} - -void MapBadKeyStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool MapBadKeyStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - MapBadKeyStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - MapBadKeyStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || MapBadKeyStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - - - -MapBadElemStructPubSubType::MapBadElemStructPubSubType() -{ - setName("MapBadElemStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(MapBadElemStruct::getMaxCdrSerializedSize()); -#else - MapBadElemStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = MapBadElemStruct_max_key_cdr_typesize > 16 ? MapBadElemStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -MapBadElemStructPubSubType::~MapBadElemStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool MapBadElemStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - MapBadElemStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool MapBadElemStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - MapBadElemStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function MapBadElemStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* MapBadElemStructPubSubType::createData() -{ - return reinterpret_cast(new MapBadElemStruct()); -} - -void MapBadElemStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool MapBadElemStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - MapBadElemStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - MapBadElemStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || MapBadElemStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - - - -MapBoundsStructPubSubType::MapBoundsStructPubSubType() -{ - setName("MapBoundsStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(MapBoundsStruct::getMaxCdrSerializedSize()); -#else - MapBoundsStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = MapBoundsStruct_max_key_cdr_typesize > 16 ? MapBoundsStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -MapBoundsStructPubSubType::~MapBoundsStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool MapBoundsStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - MapBoundsStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool MapBoundsStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - MapBoundsStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function MapBoundsStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* MapBoundsStructPubSubType::createData() -{ - return reinterpret_cast(new MapBoundsStruct()); -} - -void MapBoundsStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool MapBoundsStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - MapBoundsStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - MapBoundsStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || MapBoundsStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - - - - - -MapMapStructPubSubType::MapMapStructPubSubType() -{ - setName("MapMapStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(MapMapStruct::getMaxCdrSerializedSize()); -#else - MapMapStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = MapMapStruct_max_key_cdr_typesize > 16 ? MapMapStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -MapMapStructPubSubType::~MapMapStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool MapMapStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - MapMapStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool MapMapStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - MapMapStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function MapMapStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* MapMapStructPubSubType::createData() -{ - return reinterpret_cast(new MapMapStruct()); -} - -void MapMapStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool MapMapStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - MapMapStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - MapMapStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || MapMapStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - - - - - -MapMapBoundsStructPubSubType::MapMapBoundsStructPubSubType() -{ - setName("MapMapBoundsStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(MapMapBoundsStruct::getMaxCdrSerializedSize()); -#else - MapMapBoundsStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = MapMapBoundsStruct_max_key_cdr_typesize > 16 ? MapMapBoundsStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -MapMapBoundsStructPubSubType::~MapMapBoundsStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool MapMapBoundsStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - MapMapBoundsStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool MapMapBoundsStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - MapMapBoundsStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function MapMapBoundsStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* MapMapBoundsStructPubSubType::createData() -{ - return reinterpret_cast(new MapMapBoundsStruct()); -} - -void MapMapBoundsStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool MapMapBoundsStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - MapMapBoundsStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - MapMapBoundsStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || MapMapBoundsStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - - - - - - - - - - - - - - - - - - - - - -SimpleUnionStructPubSubType::SimpleUnionStructPubSubType() -{ - setName("SimpleUnionStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(SimpleUnionStruct::getMaxCdrSerializedSize()); -#else - SimpleUnionStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = SimpleUnionStruct_max_key_cdr_typesize > 16 ? SimpleUnionStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -SimpleUnionStructPubSubType::~SimpleUnionStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool SimpleUnionStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - SimpleUnionStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool SimpleUnionStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - SimpleUnionStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function SimpleUnionStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* SimpleUnionStructPubSubType::createData() -{ - return reinterpret_cast(new SimpleUnionStruct()); -} - -void SimpleUnionStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool SimpleUnionStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - SimpleUnionStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - SimpleUnionStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || SimpleUnionStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -SimpleUnionStructEqualPubSubType::SimpleUnionStructEqualPubSubType() -{ - setName("SimpleUnionStructEqual"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(SimpleUnionStructEqual::getMaxCdrSerializedSize()); -#else - SimpleUnionStructEqual_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = SimpleUnionStructEqual_max_key_cdr_typesize > 16 ? SimpleUnionStructEqual_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -SimpleUnionStructEqualPubSubType::~SimpleUnionStructEqualPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool SimpleUnionStructEqualPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - SimpleUnionStructEqual* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool SimpleUnionStructEqualPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - SimpleUnionStructEqual* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function SimpleUnionStructEqualPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* SimpleUnionStructEqualPubSubType::createData() -{ - return reinterpret_cast(new SimpleUnionStructEqual()); -} - -void SimpleUnionStructEqualPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool SimpleUnionStructEqualPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - SimpleUnionStructEqual* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - SimpleUnionStructEqual_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || SimpleUnionStructEqual_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -SimpleUnionNamesStructPubSubType::SimpleUnionNamesStructPubSubType() -{ - setName("SimpleUnionNamesStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(SimpleUnionNamesStruct::getMaxCdrSerializedSize()); -#else - SimpleUnionNamesStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = SimpleUnionNamesStruct_max_key_cdr_typesize > 16 ? SimpleUnionNamesStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -SimpleUnionNamesStructPubSubType::~SimpleUnionNamesStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool SimpleUnionNamesStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - SimpleUnionNamesStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool SimpleUnionNamesStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - SimpleUnionNamesStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function SimpleUnionNamesStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* SimpleUnionNamesStructPubSubType::createData() -{ - return reinterpret_cast(new SimpleUnionNamesStruct()); -} - -void SimpleUnionNamesStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool SimpleUnionNamesStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - SimpleUnionNamesStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - SimpleUnionNamesStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || SimpleUnionNamesStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -SimpleTypeUnionStructPubSubType::SimpleTypeUnionStructPubSubType() -{ - setName("SimpleTypeUnionStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(SimpleTypeUnionStruct::getMaxCdrSerializedSize()); -#else - SimpleTypeUnionStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = SimpleTypeUnionStruct_max_key_cdr_typesize > 16 ? SimpleTypeUnionStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -SimpleTypeUnionStructPubSubType::~SimpleTypeUnionStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool SimpleTypeUnionStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - SimpleTypeUnionStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool SimpleTypeUnionStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - SimpleTypeUnionStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function SimpleTypeUnionStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* SimpleTypeUnionStructPubSubType::createData() -{ - return reinterpret_cast(new SimpleTypeUnionStruct()); -} - -void SimpleTypeUnionStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool SimpleTypeUnionStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - SimpleTypeUnionStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - SimpleTypeUnionStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || SimpleTypeUnionStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -SimpleBadUnionStructPubSubType::SimpleBadUnionStructPubSubType() -{ - setName("SimpleBadUnionStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(SimpleBadUnionStruct::getMaxCdrSerializedSize()); -#else - SimpleBadUnionStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = SimpleBadUnionStruct_max_key_cdr_typesize > 16 ? SimpleBadUnionStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -SimpleBadUnionStructPubSubType::~SimpleBadUnionStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool SimpleBadUnionStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - SimpleBadUnionStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool SimpleBadUnionStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - SimpleBadUnionStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function SimpleBadUnionStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* SimpleBadUnionStructPubSubType::createData() -{ - return reinterpret_cast(new SimpleBadUnionStruct()); -} - -void SimpleBadUnionStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool SimpleBadUnionStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - SimpleBadUnionStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - SimpleBadUnionStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || SimpleBadUnionStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -SimplBadDiscUnionStructPubSubType::SimplBadDiscUnionStructPubSubType() -{ - setName("SimplBadDiscUnionStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(SimplBadDiscUnionStruct::getMaxCdrSerializedSize()); -#else - SimplBadDiscUnionStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = SimplBadDiscUnionStruct_max_key_cdr_typesize > 16 ? SimplBadDiscUnionStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -SimplBadDiscUnionStructPubSubType::~SimplBadDiscUnionStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool SimplBadDiscUnionStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - SimplBadDiscUnionStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool SimplBadDiscUnionStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - SimplBadDiscUnionStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function SimplBadDiscUnionStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* SimplBadDiscUnionStructPubSubType::createData() -{ - return reinterpret_cast(new SimplBadDiscUnionStruct()); -} - -void SimplBadDiscUnionStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool SimplBadDiscUnionStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - SimplBadDiscUnionStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - SimplBadDiscUnionStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || SimplBadDiscUnionStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - diff --git a/test/unittest/xtypes/idl/TypesPubSubTypes.h b/test/unittest/xtypes/idl/TypesPubSubTypes.h deleted file mode 100644 index 6a934f82843..00000000000 --- a/test/unittest/xtypes/idl/TypesPubSubTypes.h +++ /dev/null @@ -1,3337 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file TypesPubSubTypes.h - * This header file contains the declaration of the serialization functions. - * - * This file was generated by the tool fastddsgen. - */ - - -#ifndef _FAST_DDS_GENERATED_TYPES_PUBSUBTYPES_H_ -#define _FAST_DDS_GENERATED_TYPES_PUBSUBTYPES_H_ - -#include -#include -#include -#include -#include - -#include "Types.h" - - -#if !defined(GEN_API_VER) || (GEN_API_VER != 2) -#error \ - Generated Types is not compatible with current installed Fast DDS. Please, regenerate it with fastddsgen. -#endif // GEN_API_VER - - - - -/*! - * @brief This class represents the TopicDataType of the type MyEnumStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MyEnumStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef MyEnumStruct type; - - eProsima_user_DllExport MyEnumStructPubSubType(); - - eProsima_user_DllExport ~MyEnumStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type MyBadEnumStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MyBadEnumStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef MyBadEnumStruct type; - - eProsima_user_DllExport MyBadEnumStructPubSubType(); - - eProsima_user_DllExport ~MyBadEnumStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; -typedef MyEnum MyAliasEnum; - - - -/*! - * @brief This class represents the TopicDataType of the type MyAliasEnumStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MyAliasEnumStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef MyAliasEnumStruct type; - - eProsima_user_DllExport MyAliasEnumStructPubSubType(); - - eProsima_user_DllExport ~MyAliasEnumStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type BasicStruct defined by the user in the IDL file. - * @ingroup Types - */ -class BasicStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef BasicStruct type; - - eProsima_user_DllExport BasicStructPubSubType(); - - eProsima_user_DllExport ~BasicStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type BasicNamesStruct defined by the user in the IDL file. - * @ingroup Types - */ -class BasicNamesStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef BasicNamesStruct type; - - eProsima_user_DllExport BasicNamesStructPubSubType(); - - eProsima_user_DllExport ~BasicNamesStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type BasicBadStruct defined by the user in the IDL file. - * @ingroup Types - */ -class BasicBadStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef BasicBadStruct type; - - eProsima_user_DllExport BasicBadStructPubSubType(); - - eProsima_user_DllExport ~BasicBadStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type BasicWideStruct defined by the user in the IDL file. - * @ingroup Types - */ -class BasicWideStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef BasicWideStruct type; - - eProsima_user_DllExport BasicWideStructPubSubType(); - - eProsima_user_DllExport ~BasicWideStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type BadBasicWideStruct defined by the user in the IDL file. - * @ingroup Types - */ -class BadBasicWideStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef BadBasicWideStruct type; - - eProsima_user_DllExport BadBasicWideStructPubSubType(); - - eProsima_user_DllExport ~BadBasicWideStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type StringStruct defined by the user in the IDL file. - * @ingroup Types - */ -class StringStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef StringStruct type; - - eProsima_user_DllExport StringStructPubSubType(); - - eProsima_user_DllExport ~StringStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type LargeStringStruct defined by the user in the IDL file. - * @ingroup Types - */ -class LargeStringStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef LargeStringStruct type; - - eProsima_user_DllExport LargeStringStructPubSubType(); - - eProsima_user_DllExport ~LargeStringStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type WStringStruct defined by the user in the IDL file. - * @ingroup Types - */ -class WStringStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef WStringStruct type; - - eProsima_user_DllExport WStringStructPubSubType(); - - eProsima_user_DllExport ~WStringStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type LargeWStringStruct defined by the user in the IDL file. - * @ingroup Types - */ -class LargeWStringStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef LargeWStringStruct type; - - eProsima_user_DllExport LargeWStringStructPubSubType(); - - eProsima_user_DllExport ~LargeWStringStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type ArrayStruct defined by the user in the IDL file. - * @ingroup Types - */ -class ArrayStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef ArrayStruct type; - - eProsima_user_DllExport ArrayStructPubSubType(); - - eProsima_user_DllExport ~ArrayStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type ArrayStructEqual defined by the user in the IDL file. - * @ingroup Types - */ -class ArrayStructEqualPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef ArrayStructEqual type; - - eProsima_user_DllExport ArrayStructEqualPubSubType(); - - eProsima_user_DllExport ~ArrayStructEqualPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type ArrayBadStruct defined by the user in the IDL file. - * @ingroup Types - */ -class ArrayBadStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef ArrayBadStruct type; - - eProsima_user_DllExport ArrayBadStructPubSubType(); - - eProsima_user_DllExport ~ArrayBadStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type ArrayDimensionsStruct defined by the user in the IDL file. - * @ingroup Types - */ -class ArrayDimensionsStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef ArrayDimensionsStruct type; - - eProsima_user_DllExport ArrayDimensionsStructPubSubType(); - - eProsima_user_DllExport ~ArrayDimensionsStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type ArraySizeStruct defined by the user in the IDL file. - * @ingroup Types - */ -class ArraySizeStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef ArraySizeStruct type; - - eProsima_user_DllExport ArraySizeStructPubSubType(); - - eProsima_user_DllExport ~ArraySizeStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - - - -/*! - * @brief This class represents the TopicDataType of the type SequenceStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SequenceStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef SequenceStruct type; - - eProsima_user_DllExport SequenceStructPubSubType(); - - eProsima_user_DllExport ~SequenceStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - - - -/*! - * @brief This class represents the TopicDataType of the type SequenceStructEqual defined by the user in the IDL file. - * @ingroup Types - */ -class SequenceStructEqualPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef SequenceStructEqual type; - - eProsima_user_DllExport SequenceStructEqualPubSubType(); - - eProsima_user_DllExport ~SequenceStructEqualPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - - - -/*! - * @brief This class represents the TopicDataType of the type SequenceBadStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SequenceBadStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef SequenceBadStruct type; - - eProsima_user_DllExport SequenceBadStructPubSubType(); - - eProsima_user_DllExport ~SequenceBadStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - - - -/*! - * @brief This class represents the TopicDataType of the type SequenceBoundsStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SequenceBoundsStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef SequenceBoundsStruct type; - - eProsima_user_DllExport SequenceBoundsStructPubSubType(); - - eProsima_user_DllExport ~SequenceBoundsStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - - - - - -/*! - * @brief This class represents the TopicDataType of the type SequenceSequenceStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SequenceSequenceStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef SequenceSequenceStruct type; - - eProsima_user_DllExport SequenceSequenceStructPubSubType(); - - eProsima_user_DllExport ~SequenceSequenceStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - - - - - -/*! - * @brief This class represents the TopicDataType of the type SequenceSequenceBoundsStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SequenceSequenceBoundsStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef SequenceSequenceBoundsStruct type; - - eProsima_user_DllExport SequenceSequenceBoundsStructPubSubType(); - - eProsima_user_DllExport ~SequenceSequenceBoundsStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - - - -/*! - * @brief This class represents the TopicDataType of the type MapStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MapStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef MapStruct type; - - eProsima_user_DllExport MapStructPubSubType(); - - eProsima_user_DllExport ~MapStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - - - -/*! - * @brief This class represents the TopicDataType of the type MapStructEqual defined by the user in the IDL file. - * @ingroup Types - */ -class MapStructEqualPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef MapStructEqual type; - - eProsima_user_DllExport MapStructEqualPubSubType(); - - eProsima_user_DllExport ~MapStructEqualPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - - - -/*! - * @brief This class represents the TopicDataType of the type MapBadKeyStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MapBadKeyStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef MapBadKeyStruct type; - - eProsima_user_DllExport MapBadKeyStructPubSubType(); - - eProsima_user_DllExport ~MapBadKeyStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - - - -/*! - * @brief This class represents the TopicDataType of the type MapBadElemStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MapBadElemStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef MapBadElemStruct type; - - eProsima_user_DllExport MapBadElemStructPubSubType(); - - eProsima_user_DllExport ~MapBadElemStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - - - -/*! - * @brief This class represents the TopicDataType of the type MapBoundsStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MapBoundsStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef MapBoundsStruct type; - - eProsima_user_DllExport MapBoundsStructPubSubType(); - - eProsima_user_DllExport ~MapBoundsStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - - - - - -/*! - * @brief This class represents the TopicDataType of the type MapMapStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MapMapStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef MapMapStruct type; - - eProsima_user_DllExport MapMapStructPubSubType(); - - eProsima_user_DllExport ~MapMapStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - - - - - -/*! - * @brief This class represents the TopicDataType of the type MapMapBoundsStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MapMapBoundsStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef MapMapBoundsStruct type; - - eProsima_user_DllExport MapMapBoundsStructPubSubType(); - - eProsima_user_DllExport ~MapMapBoundsStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - - - - - - - - - - - - - - - - - - - - - -/*! - * @brief This class represents the TopicDataType of the type SimpleUnionStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SimpleUnionStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef SimpleUnionStruct type; - - eProsima_user_DllExport SimpleUnionStructPubSubType(); - - eProsima_user_DllExport ~SimpleUnionStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type SimpleUnionStructEqual defined by the user in the IDL file. - * @ingroup Types - */ -class SimpleUnionStructEqualPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef SimpleUnionStructEqual type; - - eProsima_user_DllExport SimpleUnionStructEqualPubSubType(); - - eProsima_user_DllExport ~SimpleUnionStructEqualPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type SimpleUnionNamesStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SimpleUnionNamesStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef SimpleUnionNamesStruct type; - - eProsima_user_DllExport SimpleUnionNamesStructPubSubType(); - - eProsima_user_DllExport ~SimpleUnionNamesStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type SimpleTypeUnionStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SimpleTypeUnionStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef SimpleTypeUnionStruct type; - - eProsima_user_DllExport SimpleTypeUnionStructPubSubType(); - - eProsima_user_DllExport ~SimpleTypeUnionStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type SimpleBadUnionStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SimpleBadUnionStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef SimpleBadUnionStruct type; - - eProsima_user_DllExport SimpleBadUnionStructPubSubType(); - - eProsima_user_DllExport ~SimpleBadUnionStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type SimplBadDiscUnionStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SimplBadDiscUnionStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef SimplBadDiscUnionStruct type; - - eProsima_user_DllExport SimplBadDiscUnionStructPubSubType(); - - eProsima_user_DllExport ~SimplBadDiscUnionStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - -#endif // _FAST_DDS_GENERATED_TYPES_PUBSUBTYPES_H_ - diff --git a/test/unittest/xtypes/idl/TypesTypeObject.cxx b/test/unittest/xtypes/idl/TypesTypeObject.cxx deleted file mode 100644 index bcefed47249..00000000000 --- a/test/unittest/xtypes/idl/TypesTypeObject.cxx +++ /dev/null @@ -1,8988 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file TypesTypeObject.cpp - * This source file contains the definition of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { char dummy; } -#endif - -#include "Types.h" -#include "TypesTypeObject.h" -#include -#include -#include -#include -#include -#include -#include -#include -#include - -using namespace eprosima::fastrtps::rtps; - -void registerTypesTypes() -{ - static std::once_flag once_flag; - std::call_once(once_flag, []() - { - TypeObjectFactory *factory = TypeObjectFactory::get_instance(); - factory->add_type_object("MyEnum", GetMyEnumIdentifier(true), - GetMyEnumObject(true)); - factory->add_type_object("MyEnum", GetMyEnumIdentifier(false), - GetMyEnumObject(false)); - - - factory->add_type_object("MyBadEnum", GetMyBadEnumIdentifier(true), - GetMyBadEnumObject(true)); - factory->add_type_object("MyBadEnum", GetMyBadEnumIdentifier(false), - GetMyBadEnumObject(false)); - - - factory->add_type_object("MyEnumStruct", GetMyEnumStructIdentifier(true), - GetMyEnumStructObject(true)); - factory->add_type_object("MyEnumStruct", GetMyEnumStructIdentifier(false), - GetMyEnumStructObject(false)); - - - factory->add_type_object("MyBadEnumStruct", GetMyBadEnumStructIdentifier(true), - GetMyBadEnumStructObject(true)); - factory->add_type_object("MyBadEnumStruct", GetMyBadEnumStructIdentifier(false), - GetMyBadEnumStructObject(false)); - - - factory->add_type_object("MyAliasEnum", GetMyAliasEnumIdentifier(true), - GetMyAliasEnumObject(true)); - factory->add_type_object("MyAliasEnum", GetMyAliasEnumIdentifier(false), - GetMyAliasEnumObject(false)); - - - factory->add_type_object("MyAliasEnumStruct", GetMyAliasEnumStructIdentifier(true), - GetMyAliasEnumStructObject(true)); - factory->add_type_object("MyAliasEnumStruct", GetMyAliasEnumStructIdentifier(false), - GetMyAliasEnumStructObject(false)); - - - factory->add_type_object("BasicStruct", GetBasicStructIdentifier(true), - GetBasicStructObject(true)); - factory->add_type_object("BasicStruct", GetBasicStructIdentifier(false), - GetBasicStructObject(false)); - - - factory->add_type_object("BasicNamesStruct", GetBasicNamesStructIdentifier(true), - GetBasicNamesStructObject(true)); - factory->add_type_object("BasicNamesStruct", GetBasicNamesStructIdentifier(false), - GetBasicNamesStructObject(false)); - - - factory->add_type_object("BasicBadStruct", GetBasicBadStructIdentifier(true), - GetBasicBadStructObject(true)); - factory->add_type_object("BasicBadStruct", GetBasicBadStructIdentifier(false), - GetBasicBadStructObject(false)); - - - factory->add_type_object("BasicWideStruct", GetBasicWideStructIdentifier(true), - GetBasicWideStructObject(true)); - factory->add_type_object("BasicWideStruct", GetBasicWideStructIdentifier(false), - GetBasicWideStructObject(false)); - - - factory->add_type_object("BadBasicWideStruct", GetBadBasicWideStructIdentifier(true), - GetBadBasicWideStructObject(true)); - factory->add_type_object("BadBasicWideStruct", GetBadBasicWideStructIdentifier(false), - GetBadBasicWideStructObject(false)); - - - factory->add_type_object("StringStruct", GetStringStructIdentifier(true), - GetStringStructObject(true)); - factory->add_type_object("StringStruct", GetStringStructIdentifier(false), - GetStringStructObject(false)); - - - factory->add_type_object("LargeStringStruct", GetLargeStringStructIdentifier(true), - GetLargeStringStructObject(true)); - factory->add_type_object("LargeStringStruct", GetLargeStringStructIdentifier(false), - GetLargeStringStructObject(false)); - - - factory->add_type_object("WStringStruct", GetWStringStructIdentifier(true), - GetWStringStructObject(true)); - factory->add_type_object("WStringStruct", GetWStringStructIdentifier(false), - GetWStringStructObject(false)); - - - factory->add_type_object("LargeWStringStruct", GetLargeWStringStructIdentifier(true), - GetLargeWStringStructObject(true)); - factory->add_type_object("LargeWStringStruct", GetLargeWStringStructIdentifier(false), - GetLargeWStringStructObject(false)); - - - factory->add_type_object("ArrayStruct", GetArrayStructIdentifier(true), - GetArrayStructObject(true)); - factory->add_type_object("ArrayStruct", GetArrayStructIdentifier(false), - GetArrayStructObject(false)); - - - factory->add_type_object("ArrayStructEqual", GetArrayStructEqualIdentifier(true), - GetArrayStructEqualObject(true)); - factory->add_type_object("ArrayStructEqual", GetArrayStructEqualIdentifier(false), - GetArrayStructEqualObject(false)); - - - factory->add_type_object("ArrayBadStruct", GetArrayBadStructIdentifier(true), - GetArrayBadStructObject(true)); - factory->add_type_object("ArrayBadStruct", GetArrayBadStructIdentifier(false), - GetArrayBadStructObject(false)); - - - factory->add_type_object("ArrayDimensionsStruct", GetArrayDimensionsStructIdentifier(true), - GetArrayDimensionsStructObject(true)); - factory->add_type_object("ArrayDimensionsStruct", GetArrayDimensionsStructIdentifier(false), - GetArrayDimensionsStructObject(false)); - - - factory->add_type_object("ArraySizeStruct", GetArraySizeStructIdentifier(true), - GetArraySizeStructObject(true)); - factory->add_type_object("ArraySizeStruct", GetArraySizeStructIdentifier(false), - GetArraySizeStructObject(false)); - - - factory->add_type_object("SequenceStruct", GetSequenceStructIdentifier(true), - GetSequenceStructObject(true)); - factory->add_type_object("SequenceStruct", GetSequenceStructIdentifier(false), - GetSequenceStructObject(false)); - - - factory->add_type_object("SequenceStructEqual", GetSequenceStructEqualIdentifier(true), - GetSequenceStructEqualObject(true)); - factory->add_type_object("SequenceStructEqual", GetSequenceStructEqualIdentifier(false), - GetSequenceStructEqualObject(false)); - - - factory->add_type_object("SequenceBadStruct", GetSequenceBadStructIdentifier(true), - GetSequenceBadStructObject(true)); - factory->add_type_object("SequenceBadStruct", GetSequenceBadStructIdentifier(false), - GetSequenceBadStructObject(false)); - - - factory->add_type_object("SequenceBoundsStruct", GetSequenceBoundsStructIdentifier(true), - GetSequenceBoundsStructObject(true)); - factory->add_type_object("SequenceBoundsStruct", GetSequenceBoundsStructIdentifier(false), - GetSequenceBoundsStructObject(false)); - - - factory->add_type_object("SequenceSequenceStruct", GetSequenceSequenceStructIdentifier(true), - GetSequenceSequenceStructObject(true)); - factory->add_type_object("SequenceSequenceStruct", GetSequenceSequenceStructIdentifier(false), - GetSequenceSequenceStructObject(false)); - - - factory->add_type_object("SequenceSequenceBoundsStruct", GetSequenceSequenceBoundsStructIdentifier(true), - GetSequenceSequenceBoundsStructObject(true)); - factory->add_type_object("SequenceSequenceBoundsStruct", GetSequenceSequenceBoundsStructIdentifier(false), - GetSequenceSequenceBoundsStructObject(false)); - - - factory->add_type_object("MapStruct", GetMapStructIdentifier(true), - GetMapStructObject(true)); - factory->add_type_object("MapStruct", GetMapStructIdentifier(false), - GetMapStructObject(false)); - - - factory->add_type_object("MapStructEqual", GetMapStructEqualIdentifier(true), - GetMapStructEqualObject(true)); - factory->add_type_object("MapStructEqual", GetMapStructEqualIdentifier(false), - GetMapStructEqualObject(false)); - - - factory->add_type_object("MapBadKeyStruct", GetMapBadKeyStructIdentifier(true), - GetMapBadKeyStructObject(true)); - factory->add_type_object("MapBadKeyStruct", GetMapBadKeyStructIdentifier(false), - GetMapBadKeyStructObject(false)); - - - factory->add_type_object("MapBadElemStruct", GetMapBadElemStructIdentifier(true), - GetMapBadElemStructObject(true)); - factory->add_type_object("MapBadElemStruct", GetMapBadElemStructIdentifier(false), - GetMapBadElemStructObject(false)); - - - factory->add_type_object("MapBoundsStruct", GetMapBoundsStructIdentifier(true), - GetMapBoundsStructObject(true)); - factory->add_type_object("MapBoundsStruct", GetMapBoundsStructIdentifier(false), - GetMapBoundsStructObject(false)); - - - factory->add_type_object("MapMapStruct", GetMapMapStructIdentifier(true), - GetMapMapStructObject(true)); - factory->add_type_object("MapMapStruct", GetMapMapStructIdentifier(false), - GetMapMapStructObject(false)); - - - factory->add_type_object("MapMapBoundsStruct", GetMapMapBoundsStructIdentifier(true), - GetMapMapBoundsStructObject(true)); - factory->add_type_object("MapMapBoundsStruct", GetMapMapBoundsStructIdentifier(false), - GetMapMapBoundsStructObject(false)); - - - factory->add_type_object("SimpleUnion", GetSimpleUnionIdentifier(true), - GetSimpleUnionObject(true)); - factory->add_type_object("SimpleUnion", GetSimpleUnionIdentifier(false), - GetSimpleUnionObject(false)); - - - factory->add_type_object("SimpleUnionNames", GetSimpleUnionNamesIdentifier(true), - GetSimpleUnionNamesObject(true)); - factory->add_type_object("SimpleUnionNames", GetSimpleUnionNamesIdentifier(false), - GetSimpleUnionNamesObject(false)); - - - factory->add_type_object("SimpleTypeUnion", GetSimpleTypeUnionIdentifier(true), - GetSimpleTypeUnionObject(true)); - factory->add_type_object("SimpleTypeUnion", GetSimpleTypeUnionIdentifier(false), - GetSimpleTypeUnionObject(false)); - - - factory->add_type_object("SimpleBadUnion", GetSimpleBadUnionIdentifier(true), - GetSimpleBadUnionObject(true)); - factory->add_type_object("SimpleBadUnion", GetSimpleBadUnionIdentifier(false), - GetSimpleBadUnionObject(false)); - - - factory->add_type_object("SimpleBadDiscUnion", GetSimpleBadDiscUnionIdentifier(true), - GetSimpleBadDiscUnionObject(true)); - factory->add_type_object("SimpleBadDiscUnion", GetSimpleBadDiscUnionIdentifier(false), - GetSimpleBadDiscUnionObject(false)); - - - factory->add_type_object("SimpleUnionStruct", GetSimpleUnionStructIdentifier(true), - GetSimpleUnionStructObject(true)); - factory->add_type_object("SimpleUnionStruct", GetSimpleUnionStructIdentifier(false), - GetSimpleUnionStructObject(false)); - - - factory->add_type_object("SimpleUnionStructEqual", GetSimpleUnionStructEqualIdentifier(true), - GetSimpleUnionStructEqualObject(true)); - factory->add_type_object("SimpleUnionStructEqual", GetSimpleUnionStructEqualIdentifier(false), - GetSimpleUnionStructEqualObject(false)); - - - factory->add_type_object("SimpleUnionNamesStruct", GetSimpleUnionNamesStructIdentifier(true), - GetSimpleUnionNamesStructObject(true)); - factory->add_type_object("SimpleUnionNamesStruct", GetSimpleUnionNamesStructIdentifier(false), - GetSimpleUnionNamesStructObject(false)); - - - factory->add_type_object("SimpleTypeUnionStruct", GetSimpleTypeUnionStructIdentifier(true), - GetSimpleTypeUnionStructObject(true)); - factory->add_type_object("SimpleTypeUnionStruct", GetSimpleTypeUnionStructIdentifier(false), - GetSimpleTypeUnionStructObject(false)); - - - factory->add_type_object("SimpleBadUnionStruct", GetSimpleBadUnionStructIdentifier(true), - GetSimpleBadUnionStructObject(true)); - factory->add_type_object("SimpleBadUnionStruct", GetSimpleBadUnionStructIdentifier(false), - GetSimpleBadUnionStructObject(false)); - - - factory->add_type_object("SimplBadDiscUnionStruct", GetSimplBadDiscUnionStructIdentifier(true), - GetSimplBadDiscUnionStructObject(true)); - factory->add_type_object("SimplBadDiscUnionStruct", GetSimplBadDiscUnionStructIdentifier(false), - GetSimplBadDiscUnionStructObject(false)); - - }); -} - -const TypeIdentifier* GetMyEnumIdentifier(bool complete) -{ - const TypeIdentifier* c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("MyEnum", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetMyEnumObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("MyEnum", complete); -} - -const TypeObject* GetMyEnumObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyEnum", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteMyEnumObject(); - } - // else - return GetMinimalMyEnumObject(); -} - -const TypeObject* GetMinimalMyEnumObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyEnum", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_ENUM); - - // No flags apply - //type_object->minimal().enumerated_type().enum_flags().IS_FINAL(false); - //type_object->minimal().enumerated_type().enum_flags().IS_APPENDABLE(false); - //type_object->minimal().enumerated_type().enum_flags().IS_MUTABLE(false); - //type_object->minimal().enumerated_type().enum_flags().IS_NESTED(false); - //type_object->minimal().enumerated_type().enum_flags().IS_AUTOID_HASH(false); - - type_object->minimal().enumerated_type().header().common().bit_bound(32); // TODO fixed by IDL, isn't? - - uint32_t value = 0; - MinimalEnumeratedLiteral mel_A; - mel_A.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - mel_A.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - mel_A.common().flags().IS_EXTERNAL(false); // Doesn't apply - mel_A.common().flags().IS_OPTIONAL(false); // Doesn't apply - mel_A.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mel_A.common().flags().IS_KEY(false); // Doesn't apply - mel_A.common().flags().IS_DEFAULT(false); - mel_A.common().value(value++); - MD5 A_hash("A"); - for(int i = 0; i < 4; ++i) - { - mel_A.detail().name_hash()[i] = A_hash.digest[i]; - } - type_object->minimal().enumerated_type().literal_seq().emplace_back(mel_A); - - MinimalEnumeratedLiteral mel_B; - mel_B.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - mel_B.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - mel_B.common().flags().IS_EXTERNAL(false); // Doesn't apply - mel_B.common().flags().IS_OPTIONAL(false); // Doesn't apply - mel_B.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mel_B.common().flags().IS_KEY(false); // Doesn't apply - mel_B.common().flags().IS_DEFAULT(false); - mel_B.common().value(value++); - MD5 B_hash("B"); - for(int i = 0; i < 4; ++i) - { - mel_B.detail().name_hash()[i] = B_hash.digest[i]; - } - type_object->minimal().enumerated_type().literal_seq().emplace_back(mel_B); - - MinimalEnumeratedLiteral mel_C; - mel_C.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - mel_C.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - mel_C.common().flags().IS_EXTERNAL(false); // Doesn't apply - mel_C.common().flags().IS_OPTIONAL(false); // Doesn't apply - mel_C.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mel_C.common().flags().IS_KEY(false); // Doesn't apply - mel_C.common().flags().IS_DEFAULT(false); - mel_C.common().value(value++); - MD5 C_hash("C"); - for(int i = 0; i < 4; ++i) - { - mel_C.detail().name_hash()[i] = C_hash.digest[i]; - } - type_object->minimal().enumerated_type().literal_seq().emplace_back(mel_C); - - - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().enumerated_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MyEnum", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyEnum", false); -} - -const TypeObject* GetCompleteMyEnumObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyEnum", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_ENUM); - - // No flags apply - //type_object->complete().enumerated_type().enum_flags().IS_FINAL(false); - //type_object->complete().enumerated_type().enum_flags().IS_APPENDABLE(false); - //type_object->complete().enumerated_type().enum_flags().IS_MUTABLE(false); - //type_object->complete().enumerated_type().enum_flags().IS_NESTED(false); - //type_object->complete().enumerated_type().enum_flags().IS_AUTOID_HASH(false); - - type_object->complete().enumerated_type().header().common().bit_bound(32); // TODO fixed by IDL, isn't? - type_object->complete().enumerated_type().header().detail().type_name("MyEnum"); - - uint32_t value = 0; - CompleteEnumeratedLiteral cel_A; - cel_A.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - cel_A.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - cel_A.common().flags().IS_EXTERNAL(false); // Doesn't apply - cel_A.common().flags().IS_OPTIONAL(false); // Doesn't apply - cel_A.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cel_A.common().flags().IS_KEY(false); // Doesn't apply - cel_A.common().flags().IS_DEFAULT(false); - cel_A.common().value(value++); - cel_A.detail().name("A"); - - type_object->complete().enumerated_type().literal_seq().emplace_back(cel_A); - - CompleteEnumeratedLiteral cel_B; - cel_B.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - cel_B.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - cel_B.common().flags().IS_EXTERNAL(false); // Doesn't apply - cel_B.common().flags().IS_OPTIONAL(false); // Doesn't apply - cel_B.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cel_B.common().flags().IS_KEY(false); // Doesn't apply - cel_B.common().flags().IS_DEFAULT(false); - cel_B.common().value(value++); - cel_B.detail().name("B"); - - type_object->complete().enumerated_type().literal_seq().emplace_back(cel_B); - - CompleteEnumeratedLiteral cel_C; - cel_C.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - cel_C.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - cel_C.common().flags().IS_EXTERNAL(false); // Doesn't apply - cel_C.common().flags().IS_OPTIONAL(false); // Doesn't apply - cel_C.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cel_C.common().flags().IS_KEY(false); // Doesn't apply - cel_C.common().flags().IS_DEFAULT(false); - cel_C.common().value(value++); - cel_C.detail().name("C"); - - type_object->complete().enumerated_type().literal_seq().emplace_back(cel_C); - - - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().enumerated_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MyEnum", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyEnum", true); -} - -const TypeIdentifier* GetMyBadEnumIdentifier(bool complete) -{ - const TypeIdentifier* c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("MyBadEnum", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetMyBadEnumObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("MyBadEnum", complete); -} - -const TypeObject* GetMyBadEnumObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyBadEnum", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteMyBadEnumObject(); - } - // else - return GetMinimalMyBadEnumObject(); -} - -const TypeObject* GetMinimalMyBadEnumObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyBadEnum", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_ENUM); - - // No flags apply - //type_object->minimal().enumerated_type().enum_flags().IS_FINAL(false); - //type_object->minimal().enumerated_type().enum_flags().IS_APPENDABLE(false); - //type_object->minimal().enumerated_type().enum_flags().IS_MUTABLE(false); - //type_object->minimal().enumerated_type().enum_flags().IS_NESTED(false); - //type_object->minimal().enumerated_type().enum_flags().IS_AUTOID_HASH(false); - - type_object->minimal().enumerated_type().header().common().bit_bound(32); // TODO fixed by IDL, isn't? - - uint32_t value = 0; - MinimalEnumeratedLiteral mel_A1; - mel_A1.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - mel_A1.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - mel_A1.common().flags().IS_EXTERNAL(false); // Doesn't apply - mel_A1.common().flags().IS_OPTIONAL(false); // Doesn't apply - mel_A1.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mel_A1.common().flags().IS_KEY(false); // Doesn't apply - mel_A1.common().flags().IS_DEFAULT(false); - mel_A1.common().value(value++); - MD5 A1_hash("A1"); - for(int i = 0; i < 4; ++i) - { - mel_A1.detail().name_hash()[i] = A1_hash.digest[i]; - } - type_object->minimal().enumerated_type().literal_seq().emplace_back(mel_A1); - - MinimalEnumeratedLiteral mel_B1; - mel_B1.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - mel_B1.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - mel_B1.common().flags().IS_EXTERNAL(false); // Doesn't apply - mel_B1.common().flags().IS_OPTIONAL(false); // Doesn't apply - mel_B1.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mel_B1.common().flags().IS_KEY(false); // Doesn't apply - mel_B1.common().flags().IS_DEFAULT(false); - mel_B1.common().value(value++); - MD5 B1_hash("B1"); - for(int i = 0; i < 4; ++i) - { - mel_B1.detail().name_hash()[i] = B1_hash.digest[i]; - } - type_object->minimal().enumerated_type().literal_seq().emplace_back(mel_B1); - - MinimalEnumeratedLiteral mel_C1; - mel_C1.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - mel_C1.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - mel_C1.common().flags().IS_EXTERNAL(false); // Doesn't apply - mel_C1.common().flags().IS_OPTIONAL(false); // Doesn't apply - mel_C1.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mel_C1.common().flags().IS_KEY(false); // Doesn't apply - mel_C1.common().flags().IS_DEFAULT(false); - mel_C1.common().value(value++); - MD5 C1_hash("C1"); - for(int i = 0; i < 4; ++i) - { - mel_C1.detail().name_hash()[i] = C1_hash.digest[i]; - } - type_object->minimal().enumerated_type().literal_seq().emplace_back(mel_C1); - - - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().enumerated_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MyBadEnum", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyBadEnum", false); -} - -const TypeObject* GetCompleteMyBadEnumObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyBadEnum", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_ENUM); - - // No flags apply - //type_object->complete().enumerated_type().enum_flags().IS_FINAL(false); - //type_object->complete().enumerated_type().enum_flags().IS_APPENDABLE(false); - //type_object->complete().enumerated_type().enum_flags().IS_MUTABLE(false); - //type_object->complete().enumerated_type().enum_flags().IS_NESTED(false); - //type_object->complete().enumerated_type().enum_flags().IS_AUTOID_HASH(false); - - type_object->complete().enumerated_type().header().common().bit_bound(32); // TODO fixed by IDL, isn't? - type_object->complete().enumerated_type().header().detail().type_name("MyBadEnum"); - - uint32_t value = 0; - CompleteEnumeratedLiteral cel_A1; - cel_A1.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - cel_A1.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - cel_A1.common().flags().IS_EXTERNAL(false); // Doesn't apply - cel_A1.common().flags().IS_OPTIONAL(false); // Doesn't apply - cel_A1.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cel_A1.common().flags().IS_KEY(false); // Doesn't apply - cel_A1.common().flags().IS_DEFAULT(false); - cel_A1.common().value(value++); - cel_A1.detail().name("A1"); - - type_object->complete().enumerated_type().literal_seq().emplace_back(cel_A1); - - CompleteEnumeratedLiteral cel_B1; - cel_B1.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - cel_B1.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - cel_B1.common().flags().IS_EXTERNAL(false); // Doesn't apply - cel_B1.common().flags().IS_OPTIONAL(false); // Doesn't apply - cel_B1.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cel_B1.common().flags().IS_KEY(false); // Doesn't apply - cel_B1.common().flags().IS_DEFAULT(false); - cel_B1.common().value(value++); - cel_B1.detail().name("B1"); - - type_object->complete().enumerated_type().literal_seq().emplace_back(cel_B1); - - CompleteEnumeratedLiteral cel_C1; - cel_C1.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - cel_C1.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - cel_C1.common().flags().IS_EXTERNAL(false); // Doesn't apply - cel_C1.common().flags().IS_OPTIONAL(false); // Doesn't apply - cel_C1.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cel_C1.common().flags().IS_KEY(false); // Doesn't apply - cel_C1.common().flags().IS_DEFAULT(false); - cel_C1.common().value(value++); - cel_C1.detail().name("C1"); - - type_object->complete().enumerated_type().literal_seq().emplace_back(cel_C1); - - - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().enumerated_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MyBadEnum", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyBadEnum", true); -} - - - -const TypeIdentifier* GetMyEnumStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("MyEnumStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetMyEnumStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("MyEnumStruct", complete); -} - -const TypeObject* GetMyEnumStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyEnumStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteMyEnumStructObject(); - } - //else - return GetMinimalMyEnumStructObject(); -} - -const TypeObject* GetMinimalMyEnumStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyEnumStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_enum; - mst_my_enum.common().member_id(memberId++); - mst_my_enum.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_enum.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_enum.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_enum.common().member_flags().IS_OPTIONAL(false); - mst_my_enum.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_enum.common().member_flags().IS_KEY(false); - mst_my_enum.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_enum.common().member_type_id(*GetMyEnumIdentifier(false)); - - MD5 my_enum_hash("my_enum"); - for(int i = 0; i < 4; ++i) - { - mst_my_enum.detail().name_hash()[i] = my_enum_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_enum); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MyEnumStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyEnumStruct", false); -} - -const TypeObject* GetCompleteMyEnumStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyEnumStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_enum; - cst_my_enum.common().member_id(memberId++); - cst_my_enum.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_enum.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_enum.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_enum.common().member_flags().IS_OPTIONAL(false); - cst_my_enum.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_enum.common().member_flags().IS_KEY(false); - cst_my_enum.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_enum.common().member_type_id(*GetMyEnumIdentifier(true)); - - cst_my_enum.detail().name("my_enum"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_enum); - - - // Header - type_object->complete().struct_type().header().detail().type_name("MyEnumStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MyEnumStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyEnumStruct", true); -} - - - -const TypeIdentifier* GetMyBadEnumStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("MyBadEnumStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetMyBadEnumStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("MyBadEnumStruct", complete); -} - -const TypeObject* GetMyBadEnumStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyBadEnumStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteMyBadEnumStructObject(); - } - //else - return GetMinimalMyBadEnumStructObject(); -} - -const TypeObject* GetMinimalMyBadEnumStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyBadEnumStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_enum; - mst_my_enum.common().member_id(memberId++); - mst_my_enum.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_enum.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_enum.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_enum.common().member_flags().IS_OPTIONAL(false); - mst_my_enum.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_enum.common().member_flags().IS_KEY(false); - mst_my_enum.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_enum.common().member_type_id(*GetMyBadEnumIdentifier(false)); - - MD5 my_enum_hash("my_enum"); - for(int i = 0; i < 4; ++i) - { - mst_my_enum.detail().name_hash()[i] = my_enum_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_enum); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MyBadEnumStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyBadEnumStruct", false); -} - -const TypeObject* GetCompleteMyBadEnumStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyBadEnumStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_enum; - cst_my_enum.common().member_id(memberId++); - cst_my_enum.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_enum.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_enum.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_enum.common().member_flags().IS_OPTIONAL(false); - cst_my_enum.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_enum.common().member_flags().IS_KEY(false); - cst_my_enum.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_enum.common().member_type_id(*GetMyBadEnumIdentifier(true)); - - cst_my_enum.detail().name("my_enum"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_enum); - - - // Header - type_object->complete().struct_type().header().detail().type_name("MyBadEnumStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MyBadEnumStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyBadEnumStruct", true); -} - -const TypeIdentifier* GetMyAliasEnumIdentifier(bool complete) -{ - const TypeIdentifier* c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("MyAliasEnum", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetMyAliasEnumObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("MyAliasEnum", complete); -} - -const TypeObject* GetMyAliasEnumObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyAliasEnum", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteMyAliasEnumObject(); - } - else - { - return GetMinimalMyAliasEnumObject(); - } -} - -const TypeObject* GetMinimalMyAliasEnumObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyAliasEnum", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_ALIAS); - - // No flags apply - //type_object->minimal().alias_type().alias_flags().IS_FINAL(false); - //type_object->minimal().alias_type().alias_flags().IS_APPENDABLE(false); - //type_object->minimal().alias_type().alias_flags().IS_MUTABLE(false); - //type_object->minimal().alias_type().alias_flags().IS_NESTED(false); - //type_object->minimal().alias_type().alias_flags().IS_AUTOID_HASH(false); - - // type_object->minimal().alias_type().header()... Is empty - - // No flags apply - //type_object->minimal().alias_type().body().common().related_flags().TRY_CONSTRUCT1(false); - //type_object->minimal().alias_type().body().common().related_flags().TRY_CONSTRUCT2(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_EXTERNAL(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_OPTIONAL(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_MUST_UNDERSTAND(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_KEY(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_DEFAULT(false); - - // Must be defined already, if don't, may be an recursive alias - const TypeIdentifier *relatedType = TypeObjectFactory::get_instance()->get_type_identifier("MyEnum", false); - - - if (relatedType != nullptr) - { - type_object->minimal().alias_type().body().common().related_type() = *relatedType; // Make a copy - } - else - { - // Cannot determine base type - delete type_object; - return nullptr; - } - - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().alias_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - // Don't add our TypeIdentifier but our alias - TypeObjectFactory::get_instance()->add_alias("MyAliasEnum", "MyEnum"); - - TypeObjectFactory::get_instance()->add_type_object("MyAliasEnum", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyAliasEnum", false); -} - -const TypeObject* GetCompleteMyAliasEnumObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyAliasEnum", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_ALIAS); - - // No flags apply - //type_object->complete().alias_type().alias_flags().IS_FINAL(false); - //type_object->complete().alias_type().alias_flags().IS_APPENDABLE(false); - //type_object->complete().alias_type().alias_flags().IS_MUTABLE(false); - //type_object->complete().alias_type().alias_flags().IS_NESTED(false); - //type_object->complete().alias_type().alias_flags().IS_AUTOID_HASH(false); - - //type_object->complete().alias_type().header().detail().ann_builtin().verbatim().placement("placement"); - //type_object->complete().alias_type().header().detail().ann_builtin().verbatim().language("language"); - //type_object->complete().alias_type().header().detail().ann_builtin().verbatim().text("text"); - //type_object->complete().alias_type().header().detail().ann_custom().push_back(...); - type_object->complete().alias_type().header().detail().type_name("MyAliasEnum"); - - // No flags apply - //type_object->complete().alias_type().body().common().related_flags().TRY_CONSTRUCT1(false); - //type_object->complete().alias_type().body().common().related_flags().TRY_CONSTRUCT2(false); - //type_object->complete().alias_type().body().common().related_flags().IS_EXTERNAL(false); - //type_object->complete().alias_type().body().common().related_flags().IS_OPTIONAL(false); - //type_object->complete().alias_type().body().common().related_flags().IS_MUST_UNDERSTAND(false); - //type_object->complete().alias_type().body().common().related_flags().IS_KEY(false); - //type_object->complete().alias_type().body().common().related_flags().IS_DEFAULT(false); - - //type_object->complete().alias_type().body().common().ann_builtin() - //type_object->complete().alias_type().body().common().ann_custom() - - // Must be defined already, if don't, may be an recursive alias - const TypeIdentifier *relatedType = TypeObjectFactory::get_instance()->get_type_identifier_trying_complete("MyEnum"); - - - if (relatedType != nullptr) - { - type_object->complete().alias_type().body().common().related_type() = *relatedType; // Make a copy - } - else - { - // Cannot determine base type - delete type_object; - return nullptr; - } - - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().alias_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - // Don't add our TypeIdentifier but our alias - TypeObjectFactory::get_instance()->add_alias("MyAliasEnum", "MyEnum"); - - TypeObjectFactory::get_instance()->add_type_object("MyAliasEnum", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyAliasEnum", true); -} - - - -const TypeIdentifier* GetMyAliasEnumStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("MyAliasEnumStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetMyAliasEnumStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("MyAliasEnumStruct", complete); -} - -const TypeObject* GetMyAliasEnumStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyAliasEnumStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteMyAliasEnumStructObject(); - } - //else - return GetMinimalMyAliasEnumStructObject(); -} - -const TypeObject* GetMinimalMyAliasEnumStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyAliasEnumStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_enum; - mst_my_enum.common().member_id(memberId++); - mst_my_enum.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_enum.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_enum.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_enum.common().member_flags().IS_OPTIONAL(false); - mst_my_enum.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_enum.common().member_flags().IS_KEY(false); - mst_my_enum.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_enum.common().member_type_id(*GetMyAliasEnumIdentifier(false)); - - MD5 my_enum_hash("my_enum"); - for(int i = 0; i < 4; ++i) - { - mst_my_enum.detail().name_hash()[i] = my_enum_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_enum); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MyAliasEnumStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyAliasEnumStruct", false); -} - -const TypeObject* GetCompleteMyAliasEnumStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyAliasEnumStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_enum; - cst_my_enum.common().member_id(memberId++); - cst_my_enum.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_enum.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_enum.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_enum.common().member_flags().IS_OPTIONAL(false); - cst_my_enum.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_enum.common().member_flags().IS_KEY(false); - cst_my_enum.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_enum.common().member_type_id(*GetMyAliasEnumIdentifier(true)); - - cst_my_enum.detail().name("my_enum"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_enum); - - - // Header - type_object->complete().struct_type().header().detail().type_name("MyAliasEnumStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MyAliasEnumStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyAliasEnumStruct", true); -} - - - -const TypeIdentifier* GetBasicStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("BasicStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetBasicStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("BasicStruct", complete); -} - -const TypeObject* GetBasicStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("BasicStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteBasicStructObject(); - } - //else - return GetMinimalBasicStructObject(); -} - -const TypeObject* GetMinimalBasicStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("BasicStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_bool; - mst_my_bool.common().member_id(memberId++); - mst_my_bool.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_bool.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_bool.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_bool.common().member_flags().IS_OPTIONAL(false); - mst_my_bool.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_bool.common().member_flags().IS_KEY(false); - mst_my_bool.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_bool.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("bool", false)); - - - MD5 my_bool_hash("my_bool"); - for(int i = 0; i < 4; ++i) - { - mst_my_bool.detail().name_hash()[i] = my_bool_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_bool); - - MinimalStructMember mst_my_int32; - mst_my_int32.common().member_id(memberId++); - mst_my_int32.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_int32.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_int32.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_int32.common().member_flags().IS_OPTIONAL(false); - mst_my_int32.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_int32.common().member_flags().IS_KEY(false); - mst_my_int32.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_int32.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - MD5 my_int32_hash("my_int32"); - for(int i = 0; i < 4; ++i) - { - mst_my_int32.detail().name_hash()[i] = my_int32_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_int32); - - MinimalStructMember mst_my_string; - mst_my_string.common().member_id(memberId++); - mst_my_string.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_string.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_string.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_string.common().member_flags().IS_OPTIONAL(false); - mst_my_string.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_string.common().member_flags().IS_KEY(false); - mst_my_string.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_string.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, false)); - - MD5 my_string_hash("my_string"); - for(int i = 0; i < 4; ++i) - { - mst_my_string.detail().name_hash()[i] = my_string_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_string); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("BasicStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("BasicStruct", false); -} - -const TypeObject* GetCompleteBasicStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("BasicStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_bool; - cst_my_bool.common().member_id(memberId++); - cst_my_bool.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_bool.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_bool.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_bool.common().member_flags().IS_OPTIONAL(false); - cst_my_bool.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_bool.common().member_flags().IS_KEY(false); - cst_my_bool.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_bool.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("bool", false)); - - - cst_my_bool.detail().name("my_bool"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_bool); - - CompleteStructMember cst_my_int32; - cst_my_int32.common().member_id(memberId++); - cst_my_int32.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_int32.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_int32.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_int32.common().member_flags().IS_OPTIONAL(false); - cst_my_int32.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_int32.common().member_flags().IS_KEY(false); - cst_my_int32.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_int32.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - cst_my_int32.detail().name("my_int32"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_int32); - - CompleteStructMember cst_my_string; - cst_my_string.common().member_id(memberId++); - cst_my_string.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_string.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_string.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_string.common().member_flags().IS_OPTIONAL(false); - cst_my_string.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_string.common().member_flags().IS_KEY(false); - cst_my_string.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_string.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, false)); - - cst_my_string.detail().name("my_string"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_string); - - - // Header - type_object->complete().struct_type().header().detail().type_name("BasicStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("BasicStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("BasicStruct", true); -} - - - -const TypeIdentifier* GetBasicNamesStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("BasicNamesStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetBasicNamesStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("BasicNamesStruct", complete); -} - -const TypeObject* GetBasicNamesStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("BasicNamesStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteBasicNamesStructObject(); - } - //else - return GetMinimalBasicNamesStructObject(); -} - -const TypeObject* GetMinimalBasicNamesStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("BasicNamesStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_bool_name; - mst_my_bool_name.common().member_id(memberId++); - mst_my_bool_name.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_bool_name.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_bool_name.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_bool_name.common().member_flags().IS_OPTIONAL(false); - mst_my_bool_name.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_bool_name.common().member_flags().IS_KEY(false); - mst_my_bool_name.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_bool_name.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("bool", false)); - - - MD5 my_bool_name_hash("my_bool_name"); - for(int i = 0; i < 4; ++i) - { - mst_my_bool_name.detail().name_hash()[i] = my_bool_name_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_bool_name); - - MinimalStructMember mst_my_int32_name; - mst_my_int32_name.common().member_id(memberId++); - mst_my_int32_name.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_int32_name.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_int32_name.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_int32_name.common().member_flags().IS_OPTIONAL(false); - mst_my_int32_name.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_int32_name.common().member_flags().IS_KEY(false); - mst_my_int32_name.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_int32_name.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - MD5 my_int32_name_hash("my_int32_name"); - for(int i = 0; i < 4; ++i) - { - mst_my_int32_name.detail().name_hash()[i] = my_int32_name_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_int32_name); - - MinimalStructMember mst_my_string_name; - mst_my_string_name.common().member_id(memberId++); - mst_my_string_name.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_string_name.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_string_name.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_string_name.common().member_flags().IS_OPTIONAL(false); - mst_my_string_name.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_string_name.common().member_flags().IS_KEY(false); - mst_my_string_name.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_string_name.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, false)); - - MD5 my_string_name_hash("my_string_name"); - for(int i = 0; i < 4; ++i) - { - mst_my_string_name.detail().name_hash()[i] = my_string_name_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_string_name); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("BasicNamesStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("BasicNamesStruct", false); -} - -const TypeObject* GetCompleteBasicNamesStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("BasicNamesStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_bool_name; - cst_my_bool_name.common().member_id(memberId++); - cst_my_bool_name.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_bool_name.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_bool_name.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_bool_name.common().member_flags().IS_OPTIONAL(false); - cst_my_bool_name.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_bool_name.common().member_flags().IS_KEY(false); - cst_my_bool_name.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_bool_name.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("bool", false)); - - - cst_my_bool_name.detail().name("my_bool_name"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_bool_name); - - CompleteStructMember cst_my_int32_name; - cst_my_int32_name.common().member_id(memberId++); - cst_my_int32_name.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_int32_name.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_int32_name.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_int32_name.common().member_flags().IS_OPTIONAL(false); - cst_my_int32_name.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_int32_name.common().member_flags().IS_KEY(false); - cst_my_int32_name.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_int32_name.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - cst_my_int32_name.detail().name("my_int32_name"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_int32_name); - - CompleteStructMember cst_my_string_name; - cst_my_string_name.common().member_id(memberId++); - cst_my_string_name.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_string_name.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_string_name.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_string_name.common().member_flags().IS_OPTIONAL(false); - cst_my_string_name.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_string_name.common().member_flags().IS_KEY(false); - cst_my_string_name.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_string_name.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, false)); - - cst_my_string_name.detail().name("my_string_name"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_string_name); - - - // Header - type_object->complete().struct_type().header().detail().type_name("BasicNamesStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("BasicNamesStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("BasicNamesStruct", true); -} - - - -const TypeIdentifier* GetBasicBadStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("BasicBadStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetBasicBadStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("BasicBadStruct", complete); -} - -const TypeObject* GetBasicBadStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("BasicBadStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteBasicBadStructObject(); - } - //else - return GetMinimalBasicBadStructObject(); -} - -const TypeObject* GetMinimalBasicBadStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("BasicBadStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_bool; - mst_my_bool.common().member_id(memberId++); - mst_my_bool.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_bool.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_bool.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_bool.common().member_flags().IS_OPTIONAL(false); - mst_my_bool.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_bool.common().member_flags().IS_KEY(false); - mst_my_bool.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_bool.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint8_t", false)); - - - MD5 my_bool_hash("my_bool"); - for(int i = 0; i < 4; ++i) - { - mst_my_bool.detail().name_hash()[i] = my_bool_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_bool); - - MinimalStructMember mst_my_int32; - mst_my_int32.common().member_id(memberId++); - mst_my_int32.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_int32.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_int32.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_int32.common().member_flags().IS_OPTIONAL(false); - mst_my_int32.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_int32.common().member_flags().IS_KEY(false); - mst_my_int32.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_int32.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - MD5 my_int32_hash("my_int32"); - for(int i = 0; i < 4; ++i) - { - mst_my_int32.detail().name_hash()[i] = my_int32_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_int32); - - MinimalStructMember mst_my_string; - mst_my_string.common().member_id(memberId++); - mst_my_string.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_string.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_string.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_string.common().member_flags().IS_OPTIONAL(false); - mst_my_string.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_string.common().member_flags().IS_KEY(false); - mst_my_string.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_string.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, false)); - - MD5 my_string_hash("my_string"); - for(int i = 0; i < 4; ++i) - { - mst_my_string.detail().name_hash()[i] = my_string_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_string); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("BasicBadStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("BasicBadStruct", false); -} - -const TypeObject* GetCompleteBasicBadStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("BasicBadStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_bool; - cst_my_bool.common().member_id(memberId++); - cst_my_bool.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_bool.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_bool.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_bool.common().member_flags().IS_OPTIONAL(false); - cst_my_bool.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_bool.common().member_flags().IS_KEY(false); - cst_my_bool.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_bool.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint8_t", false)); - - - cst_my_bool.detail().name("my_bool"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_bool); - - CompleteStructMember cst_my_int32; - cst_my_int32.common().member_id(memberId++); - cst_my_int32.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_int32.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_int32.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_int32.common().member_flags().IS_OPTIONAL(false); - cst_my_int32.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_int32.common().member_flags().IS_KEY(false); - cst_my_int32.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_int32.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - cst_my_int32.detail().name("my_int32"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_int32); - - CompleteStructMember cst_my_string; - cst_my_string.common().member_id(memberId++); - cst_my_string.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_string.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_string.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_string.common().member_flags().IS_OPTIONAL(false); - cst_my_string.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_string.common().member_flags().IS_KEY(false); - cst_my_string.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_string.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, false)); - - cst_my_string.detail().name("my_string"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_string); - - - // Header - type_object->complete().struct_type().header().detail().type_name("BasicBadStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("BasicBadStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("BasicBadStruct", true); -} - - - -const TypeIdentifier* GetBasicWideStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("BasicWideStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetBasicWideStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("BasicWideStruct", complete); -} - -const TypeObject* GetBasicWideStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("BasicWideStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteBasicWideStructObject(); - } - //else - return GetMinimalBasicWideStructObject(); -} - -const TypeObject* GetMinimalBasicWideStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("BasicWideStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_bool; - mst_my_bool.common().member_id(memberId++); - mst_my_bool.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_bool.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_bool.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_bool.common().member_flags().IS_OPTIONAL(false); - mst_my_bool.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_bool.common().member_flags().IS_KEY(false); - mst_my_bool.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_bool.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("bool", false)); - - - MD5 my_bool_hash("my_bool"); - for(int i = 0; i < 4; ++i) - { - mst_my_bool.detail().name_hash()[i] = my_bool_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_bool); - - MinimalStructMember mst_my_int32; - mst_my_int32.common().member_id(memberId++); - mst_my_int32.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_int32.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_int32.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_int32.common().member_flags().IS_OPTIONAL(false); - mst_my_int32.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_int32.common().member_flags().IS_KEY(false); - mst_my_int32.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_int32.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - MD5 my_int32_hash("my_int32"); - for(int i = 0; i < 4; ++i) - { - mst_my_int32.detail().name_hash()[i] = my_int32_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_int32); - - MinimalStructMember mst_my_string; - mst_my_string.common().member_id(memberId++); - mst_my_string.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_string.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_string.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_string.common().member_flags().IS_OPTIONAL(false); - mst_my_string.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_string.common().member_flags().IS_KEY(false); - mst_my_string.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_string.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, false)); - - MD5 my_string_hash("my_string"); - for(int i = 0; i < 4; ++i) - { - mst_my_string.detail().name_hash()[i] = my_string_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_string); - - MinimalStructMember mst_new_int32; - mst_new_int32.common().member_id(memberId++); - mst_new_int32.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_new_int32.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_new_int32.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_new_int32.common().member_flags().IS_OPTIONAL(false); - mst_new_int32.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_new_int32.common().member_flags().IS_KEY(false); - mst_new_int32.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_new_int32.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - MD5 new_int32_hash("new_int32"); - for(int i = 0; i < 4; ++i) - { - mst_new_int32.detail().name_hash()[i] = new_int32_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_new_int32); - - MinimalStructMember mst_new_string; - mst_new_string.common().member_id(memberId++); - mst_new_string.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_new_string.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_new_string.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_new_string.common().member_flags().IS_OPTIONAL(false); - mst_new_string.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_new_string.common().member_flags().IS_KEY(false); - mst_new_string.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_new_string.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, false)); - - MD5 new_string_hash("new_string"); - for(int i = 0; i < 4; ++i) - { - mst_new_string.detail().name_hash()[i] = new_string_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_new_string); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("BasicWideStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("BasicWideStruct", false); -} - -const TypeObject* GetCompleteBasicWideStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("BasicWideStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_bool; - cst_my_bool.common().member_id(memberId++); - cst_my_bool.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_bool.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_bool.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_bool.common().member_flags().IS_OPTIONAL(false); - cst_my_bool.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_bool.common().member_flags().IS_KEY(false); - cst_my_bool.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_bool.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("bool", false)); - - - cst_my_bool.detail().name("my_bool"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_bool); - - CompleteStructMember cst_my_int32; - cst_my_int32.common().member_id(memberId++); - cst_my_int32.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_int32.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_int32.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_int32.common().member_flags().IS_OPTIONAL(false); - cst_my_int32.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_int32.common().member_flags().IS_KEY(false); - cst_my_int32.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_int32.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - cst_my_int32.detail().name("my_int32"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_int32); - - CompleteStructMember cst_my_string; - cst_my_string.common().member_id(memberId++); - cst_my_string.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_string.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_string.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_string.common().member_flags().IS_OPTIONAL(false); - cst_my_string.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_string.common().member_flags().IS_KEY(false); - cst_my_string.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_string.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, false)); - - cst_my_string.detail().name("my_string"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_string); - - CompleteStructMember cst_new_int32; - cst_new_int32.common().member_id(memberId++); - cst_new_int32.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_new_int32.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_new_int32.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_new_int32.common().member_flags().IS_OPTIONAL(false); - cst_new_int32.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_new_int32.common().member_flags().IS_KEY(false); - cst_new_int32.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_new_int32.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - cst_new_int32.detail().name("new_int32"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_new_int32); - - CompleteStructMember cst_new_string; - cst_new_string.common().member_id(memberId++); - cst_new_string.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_new_string.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_new_string.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_new_string.common().member_flags().IS_OPTIONAL(false); - cst_new_string.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_new_string.common().member_flags().IS_KEY(false); - cst_new_string.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_new_string.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, false)); - - cst_new_string.detail().name("new_string"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_new_string); - - - // Header - type_object->complete().struct_type().header().detail().type_name("BasicWideStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("BasicWideStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("BasicWideStruct", true); -} - - - -const TypeIdentifier* GetBadBasicWideStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("BadBasicWideStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetBadBasicWideStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("BadBasicWideStruct", complete); -} - -const TypeObject* GetBadBasicWideStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("BadBasicWideStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteBadBasicWideStructObject(); - } - //else - return GetMinimalBadBasicWideStructObject(); -} - -const TypeObject* GetMinimalBadBasicWideStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("BadBasicWideStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_new_int32; - mst_new_int32.common().member_id(memberId++); - mst_new_int32.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_new_int32.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_new_int32.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_new_int32.common().member_flags().IS_OPTIONAL(false); - mst_new_int32.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_new_int32.common().member_flags().IS_KEY(false); - mst_new_int32.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_new_int32.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - MD5 new_int32_hash("new_int32"); - for(int i = 0; i < 4; ++i) - { - mst_new_int32.detail().name_hash()[i] = new_int32_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_new_int32); - - MinimalStructMember mst_new_string; - mst_new_string.common().member_id(memberId++); - mst_new_string.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_new_string.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_new_string.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_new_string.common().member_flags().IS_OPTIONAL(false); - mst_new_string.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_new_string.common().member_flags().IS_KEY(false); - mst_new_string.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_new_string.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, false)); - - MD5 new_string_hash("new_string"); - for(int i = 0; i < 4; ++i) - { - mst_new_string.detail().name_hash()[i] = new_string_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_new_string); - - MinimalStructMember mst_my_bool; - mst_my_bool.common().member_id(memberId++); - mst_my_bool.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_bool.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_bool.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_bool.common().member_flags().IS_OPTIONAL(false); - mst_my_bool.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_bool.common().member_flags().IS_KEY(false); - mst_my_bool.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_bool.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("bool", false)); - - - MD5 my_bool_hash("my_bool"); - for(int i = 0; i < 4; ++i) - { - mst_my_bool.detail().name_hash()[i] = my_bool_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_bool); - - MinimalStructMember mst_my_int32; - mst_my_int32.common().member_id(memberId++); - mst_my_int32.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_int32.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_int32.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_int32.common().member_flags().IS_OPTIONAL(false); - mst_my_int32.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_int32.common().member_flags().IS_KEY(false); - mst_my_int32.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_int32.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - MD5 my_int32_hash("my_int32"); - for(int i = 0; i < 4; ++i) - { - mst_my_int32.detail().name_hash()[i] = my_int32_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_int32); - - MinimalStructMember mst_my_string; - mst_my_string.common().member_id(memberId++); - mst_my_string.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_string.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_string.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_string.common().member_flags().IS_OPTIONAL(false); - mst_my_string.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_string.common().member_flags().IS_KEY(false); - mst_my_string.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_string.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, false)); - - MD5 my_string_hash("my_string"); - for(int i = 0; i < 4; ++i) - { - mst_my_string.detail().name_hash()[i] = my_string_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_string); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("BadBasicWideStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("BadBasicWideStruct", false); -} - -const TypeObject* GetCompleteBadBasicWideStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("BadBasicWideStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_new_int32; - cst_new_int32.common().member_id(memberId++); - cst_new_int32.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_new_int32.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_new_int32.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_new_int32.common().member_flags().IS_OPTIONAL(false); - cst_new_int32.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_new_int32.common().member_flags().IS_KEY(false); - cst_new_int32.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_new_int32.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - cst_new_int32.detail().name("new_int32"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_new_int32); - - CompleteStructMember cst_new_string; - cst_new_string.common().member_id(memberId++); - cst_new_string.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_new_string.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_new_string.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_new_string.common().member_flags().IS_OPTIONAL(false); - cst_new_string.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_new_string.common().member_flags().IS_KEY(false); - cst_new_string.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_new_string.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, false)); - - cst_new_string.detail().name("new_string"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_new_string); - - CompleteStructMember cst_my_bool; - cst_my_bool.common().member_id(memberId++); - cst_my_bool.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_bool.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_bool.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_bool.common().member_flags().IS_OPTIONAL(false); - cst_my_bool.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_bool.common().member_flags().IS_KEY(false); - cst_my_bool.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_bool.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("bool", false)); - - - cst_my_bool.detail().name("my_bool"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_bool); - - CompleteStructMember cst_my_int32; - cst_my_int32.common().member_id(memberId++); - cst_my_int32.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_int32.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_int32.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_int32.common().member_flags().IS_OPTIONAL(false); - cst_my_int32.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_int32.common().member_flags().IS_KEY(false); - cst_my_int32.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_int32.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - cst_my_int32.detail().name("my_int32"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_int32); - - CompleteStructMember cst_my_string; - cst_my_string.common().member_id(memberId++); - cst_my_string.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_string.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_string.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_string.common().member_flags().IS_OPTIONAL(false); - cst_my_string.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_string.common().member_flags().IS_KEY(false); - cst_my_string.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_string.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, false)); - - cst_my_string.detail().name("my_string"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_string); - - - // Header - type_object->complete().struct_type().header().detail().type_name("BadBasicWideStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("BadBasicWideStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("BadBasicWideStruct", true); -} - - - -const TypeIdentifier* GetStringStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("StringStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetStringStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("StringStruct", complete); -} - -const TypeObject* GetStringStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("StringStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteStringStructObject(); - } - //else - return GetMinimalStringStructObject(); -} - -const TypeObject* GetMinimalStringStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("StringStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_string; - mst_my_string.common().member_id(memberId++); - mst_my_string.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_string.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_string.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_string.common().member_flags().IS_OPTIONAL(false); - mst_my_string.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_string.common().member_flags().IS_KEY(false); - mst_my_string.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_string.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, false)); - - MD5 my_string_hash("my_string"); - for(int i = 0; i < 4; ++i) - { - mst_my_string.detail().name_hash()[i] = my_string_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_string); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("StringStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("StringStruct", false); -} - -const TypeObject* GetCompleteStringStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("StringStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_string; - cst_my_string.common().member_id(memberId++); - cst_my_string.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_string.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_string.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_string.common().member_flags().IS_OPTIONAL(false); - cst_my_string.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_string.common().member_flags().IS_KEY(false); - cst_my_string.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_string.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, false)); - - cst_my_string.detail().name("my_string"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_string); - - - // Header - type_object->complete().struct_type().header().detail().type_name("StringStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("StringStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("StringStruct", true); -} - - - -const TypeIdentifier* GetLargeStringStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("LargeStringStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetLargeStringStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("LargeStringStruct", complete); -} - -const TypeObject* GetLargeStringStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("LargeStringStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteLargeStringStructObject(); - } - //else - return GetMinimalLargeStringStructObject(); -} - -const TypeObject* GetMinimalLargeStringStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("LargeStringStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_large_string; - mst_my_large_string.common().member_id(memberId++); - mst_my_large_string.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_large_string.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_large_string.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_large_string.common().member_flags().IS_OPTIONAL(false); - mst_my_large_string.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_large_string.common().member_flags().IS_KEY(false); - mst_my_large_string.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_large_string.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(41925, false)); - - MD5 my_large_string_hash("my_large_string"); - for(int i = 0; i < 4; ++i) - { - mst_my_large_string.detail().name_hash()[i] = my_large_string_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_large_string); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("LargeStringStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("LargeStringStruct", false); -} - -const TypeObject* GetCompleteLargeStringStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("LargeStringStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_large_string; - cst_my_large_string.common().member_id(memberId++); - cst_my_large_string.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_large_string.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_large_string.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_large_string.common().member_flags().IS_OPTIONAL(false); - cst_my_large_string.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_large_string.common().member_flags().IS_KEY(false); - cst_my_large_string.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_large_string.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(41925, false)); - - cst_my_large_string.detail().name("my_large_string"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_large_string); - - - // Header - type_object->complete().struct_type().header().detail().type_name("LargeStringStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("LargeStringStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("LargeStringStruct", true); -} - - - -const TypeIdentifier* GetWStringStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("WStringStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetWStringStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("WStringStruct", complete); -} - -const TypeObject* GetWStringStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("WStringStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteWStringStructObject(); - } - //else - return GetMinimalWStringStructObject(); -} - -const TypeObject* GetMinimalWStringStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("WStringStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_wstring; - mst_my_wstring.common().member_id(memberId++); - mst_my_wstring.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_wstring.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_wstring.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_wstring.common().member_flags().IS_OPTIONAL(false); - mst_my_wstring.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_wstring.common().member_flags().IS_KEY(false); - mst_my_wstring.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_wstring.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, true)); - - MD5 my_wstring_hash("my_wstring"); - for(int i = 0; i < 4; ++i) - { - mst_my_wstring.detail().name_hash()[i] = my_wstring_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_wstring); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("WStringStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("WStringStruct", false); -} - -const TypeObject* GetCompleteWStringStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("WStringStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_wstring; - cst_my_wstring.common().member_id(memberId++); - cst_my_wstring.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_wstring.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_wstring.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_wstring.common().member_flags().IS_OPTIONAL(false); - cst_my_wstring.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_wstring.common().member_flags().IS_KEY(false); - cst_my_wstring.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_wstring.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, true)); - - cst_my_wstring.detail().name("my_wstring"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_wstring); - - - // Header - type_object->complete().struct_type().header().detail().type_name("WStringStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("WStringStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("WStringStruct", true); -} - - - -const TypeIdentifier* GetLargeWStringStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("LargeWStringStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetLargeWStringStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("LargeWStringStruct", complete); -} - -const TypeObject* GetLargeWStringStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("LargeWStringStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteLargeWStringStructObject(); - } - //else - return GetMinimalLargeWStringStructObject(); -} - -const TypeObject* GetMinimalLargeWStringStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("LargeWStringStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_large_wstring; - mst_my_large_wstring.common().member_id(memberId++); - mst_my_large_wstring.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_large_wstring.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_large_wstring.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_large_wstring.common().member_flags().IS_OPTIONAL(false); - mst_my_large_wstring.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_large_wstring.common().member_flags().IS_KEY(false); - mst_my_large_wstring.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_large_wstring.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(41925, true)); - - MD5 my_large_wstring_hash("my_large_wstring"); - for(int i = 0; i < 4; ++i) - { - mst_my_large_wstring.detail().name_hash()[i] = my_large_wstring_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_large_wstring); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("LargeWStringStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("LargeWStringStruct", false); -} - -const TypeObject* GetCompleteLargeWStringStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("LargeWStringStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_large_wstring; - cst_my_large_wstring.common().member_id(memberId++); - cst_my_large_wstring.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_large_wstring.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_large_wstring.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_large_wstring.common().member_flags().IS_OPTIONAL(false); - cst_my_large_wstring.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_large_wstring.common().member_flags().IS_KEY(false); - cst_my_large_wstring.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_large_wstring.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(41925, true)); - - cst_my_large_wstring.detail().name("my_large_wstring"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_large_wstring); - - - // Header - type_object->complete().struct_type().header().detail().type_name("LargeWStringStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("LargeWStringStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("LargeWStringStruct", true); -} - - - -const TypeIdentifier* GetArrayStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("ArrayStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetArrayStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("ArrayStruct", complete); -} - -const TypeObject* GetArrayStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ArrayStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteArrayStructObject(); - } - //else - return GetMinimalArrayStructObject(); -} - -const TypeObject* GetMinimalArrayStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ArrayStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_array; - mst_my_array.common().member_id(memberId++); - mst_my_array.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_array.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_array.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_array.common().member_flags().IS_OPTIONAL(false); - mst_my_array.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_array.common().member_flags().IS_KEY(false); - mst_my_array.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_array.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("int32_t", {2}, false)); - - MD5 my_array_hash("my_array"); - for(int i = 0; i < 4; ++i) - { - mst_my_array.detail().name_hash()[i] = my_array_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_array); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("ArrayStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("ArrayStruct", false); -} - -const TypeObject* GetCompleteArrayStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ArrayStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_array; - cst_my_array.common().member_id(memberId++); - cst_my_array.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_array.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_array.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_array.common().member_flags().IS_OPTIONAL(false); - cst_my_array.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_array.common().member_flags().IS_KEY(false); - cst_my_array.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_array.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("int32_t", {2}, true)); - - cst_my_array.detail().name("my_array"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_array); - - - // Header - type_object->complete().struct_type().header().detail().type_name("ArrayStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("ArrayStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("ArrayStruct", true); -} - - - -const TypeIdentifier* GetArrayStructEqualIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("ArrayStructEqual", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetArrayStructEqualObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("ArrayStructEqual", complete); -} - -const TypeObject* GetArrayStructEqualObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ArrayStructEqual", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteArrayStructEqualObject(); - } - //else - return GetMinimalArrayStructEqualObject(); -} - -const TypeObject* GetMinimalArrayStructEqualObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ArrayStructEqual", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_array_equal; - mst_my_array_equal.common().member_id(memberId++); - mst_my_array_equal.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_array_equal.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_array_equal.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_array_equal.common().member_flags().IS_OPTIONAL(false); - mst_my_array_equal.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_array_equal.common().member_flags().IS_KEY(false); - mst_my_array_equal.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_array_equal.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("int32_t", {2}, false)); - - MD5 my_array_equal_hash("my_array_equal"); - for(int i = 0; i < 4; ++i) - { - mst_my_array_equal.detail().name_hash()[i] = my_array_equal_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_array_equal); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("ArrayStructEqual", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("ArrayStructEqual", false); -} - -const TypeObject* GetCompleteArrayStructEqualObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ArrayStructEqual", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_array_equal; - cst_my_array_equal.common().member_id(memberId++); - cst_my_array_equal.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_array_equal.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_array_equal.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_array_equal.common().member_flags().IS_OPTIONAL(false); - cst_my_array_equal.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_array_equal.common().member_flags().IS_KEY(false); - cst_my_array_equal.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_array_equal.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("int32_t", {2}, true)); - - cst_my_array_equal.detail().name("my_array_equal"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_array_equal); - - - // Header - type_object->complete().struct_type().header().detail().type_name("ArrayStructEqual"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("ArrayStructEqual", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("ArrayStructEqual", true); -} - - - -const TypeIdentifier* GetArrayBadStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("ArrayBadStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetArrayBadStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("ArrayBadStruct", complete); -} - -const TypeObject* GetArrayBadStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ArrayBadStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteArrayBadStructObject(); - } - //else - return GetMinimalArrayBadStructObject(); -} - -const TypeObject* GetMinimalArrayBadStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ArrayBadStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_array; - mst_my_array.common().member_id(memberId++); - mst_my_array.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_array.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_array.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_array.common().member_flags().IS_OPTIONAL(false); - mst_my_array.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_array.common().member_flags().IS_KEY(false); - mst_my_array.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_array.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("uint8_t", {2}, false)); - - MD5 my_array_hash("my_array"); - for(int i = 0; i < 4; ++i) - { - mst_my_array.detail().name_hash()[i] = my_array_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_array); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("ArrayBadStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("ArrayBadStruct", false); -} - -const TypeObject* GetCompleteArrayBadStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ArrayBadStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_array; - cst_my_array.common().member_id(memberId++); - cst_my_array.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_array.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_array.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_array.common().member_flags().IS_OPTIONAL(false); - cst_my_array.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_array.common().member_flags().IS_KEY(false); - cst_my_array.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_array.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("uint8_t", {2}, true)); - - cst_my_array.detail().name("my_array"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_array); - - - // Header - type_object->complete().struct_type().header().detail().type_name("ArrayBadStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("ArrayBadStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("ArrayBadStruct", true); -} - - - -const TypeIdentifier* GetArrayDimensionsStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("ArrayDimensionsStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetArrayDimensionsStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("ArrayDimensionsStruct", complete); -} - -const TypeObject* GetArrayDimensionsStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ArrayDimensionsStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteArrayDimensionsStructObject(); - } - //else - return GetMinimalArrayDimensionsStructObject(); -} - -const TypeObject* GetMinimalArrayDimensionsStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ArrayDimensionsStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_array; - mst_my_array.common().member_id(memberId++); - mst_my_array.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_array.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_array.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_array.common().member_flags().IS_OPTIONAL(false); - mst_my_array.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_array.common().member_flags().IS_KEY(false); - mst_my_array.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_array.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("int32_t", {2, 2}, false)); - - MD5 my_array_hash("my_array"); - for(int i = 0; i < 4; ++i) - { - mst_my_array.detail().name_hash()[i] = my_array_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_array); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("ArrayDimensionsStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("ArrayDimensionsStruct", false); -} - -const TypeObject* GetCompleteArrayDimensionsStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ArrayDimensionsStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_array; - cst_my_array.common().member_id(memberId++); - cst_my_array.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_array.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_array.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_array.common().member_flags().IS_OPTIONAL(false); - cst_my_array.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_array.common().member_flags().IS_KEY(false); - cst_my_array.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_array.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("int32_t", {2, 2}, true)); - - cst_my_array.detail().name("my_array"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_array); - - - // Header - type_object->complete().struct_type().header().detail().type_name("ArrayDimensionsStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("ArrayDimensionsStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("ArrayDimensionsStruct", true); -} - - - -const TypeIdentifier* GetArraySizeStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("ArraySizeStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetArraySizeStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("ArraySizeStruct", complete); -} - -const TypeObject* GetArraySizeStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ArraySizeStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteArraySizeStructObject(); - } - //else - return GetMinimalArraySizeStructObject(); -} - -const TypeObject* GetMinimalArraySizeStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ArraySizeStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_array; - mst_my_array.common().member_id(memberId++); - mst_my_array.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_array.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_array.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_array.common().member_flags().IS_OPTIONAL(false); - mst_my_array.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_array.common().member_flags().IS_KEY(false); - mst_my_array.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_array.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("int32_t", {5}, false)); - - MD5 my_array_hash("my_array"); - for(int i = 0; i < 4; ++i) - { - mst_my_array.detail().name_hash()[i] = my_array_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_array); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("ArraySizeStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("ArraySizeStruct", false); -} - -const TypeObject* GetCompleteArraySizeStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ArraySizeStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_array; - cst_my_array.common().member_id(memberId++); - cst_my_array.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_array.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_array.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_array.common().member_flags().IS_OPTIONAL(false); - cst_my_array.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_array.common().member_flags().IS_KEY(false); - cst_my_array.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_array.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("int32_t", {5}, true)); - - cst_my_array.detail().name("my_array"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_array); - - - // Header - type_object->complete().struct_type().header().detail().type_name("ArraySizeStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("ArraySizeStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("ArraySizeStruct", true); -} - - - - - -const TypeIdentifier* GetSequenceStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("SequenceStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetSequenceStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("SequenceStruct", complete); -} - -const TypeObject* GetSequenceStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SequenceStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteSequenceStructObject(); - } - //else - return GetMinimalSequenceStructObject(); -} - -const TypeObject* GetMinimalSequenceStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SequenceStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_sequence; - mst_my_sequence.common().member_id(memberId++); - mst_my_sequence.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_sequence.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_sequence.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_sequence.common().member_flags().IS_OPTIONAL(false); - mst_my_sequence.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_sequence.common().member_flags().IS_KEY(false); - mst_my_sequence.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_sequence.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("int32_t", 2, false)); - - MD5 my_sequence_hash("my_sequence"); - for(int i = 0; i < 4; ++i) - { - mst_my_sequence.detail().name_hash()[i] = my_sequence_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_sequence); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SequenceStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SequenceStruct", false); -} - -const TypeObject* GetCompleteSequenceStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SequenceStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_sequence; - cst_my_sequence.common().member_id(memberId++); - cst_my_sequence.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_sequence.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_sequence.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_sequence.common().member_flags().IS_OPTIONAL(false); - cst_my_sequence.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_sequence.common().member_flags().IS_KEY(false); - cst_my_sequence.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_sequence.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("int32_t", 2, true)); - - cst_my_sequence.detail().name("my_sequence"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_sequence); - - - // Header - type_object->complete().struct_type().header().detail().type_name("SequenceStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SequenceStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SequenceStruct", true); -} - - - - - -const TypeIdentifier* GetSequenceStructEqualIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("SequenceStructEqual", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetSequenceStructEqualObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("SequenceStructEqual", complete); -} - -const TypeObject* GetSequenceStructEqualObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SequenceStructEqual", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteSequenceStructEqualObject(); - } - //else - return GetMinimalSequenceStructEqualObject(); -} - -const TypeObject* GetMinimalSequenceStructEqualObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SequenceStructEqual", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_sequence_equal; - mst_my_sequence_equal.common().member_id(memberId++); - mst_my_sequence_equal.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_sequence_equal.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_sequence_equal.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_sequence_equal.common().member_flags().IS_OPTIONAL(false); - mst_my_sequence_equal.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_sequence_equal.common().member_flags().IS_KEY(false); - mst_my_sequence_equal.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_sequence_equal.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("int32_t", 2, false)); - - MD5 my_sequence_equal_hash("my_sequence_equal"); - for(int i = 0; i < 4; ++i) - { - mst_my_sequence_equal.detail().name_hash()[i] = my_sequence_equal_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_sequence_equal); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SequenceStructEqual", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SequenceStructEqual", false); -} - -const TypeObject* GetCompleteSequenceStructEqualObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SequenceStructEqual", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_sequence_equal; - cst_my_sequence_equal.common().member_id(memberId++); - cst_my_sequence_equal.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_sequence_equal.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_sequence_equal.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_sequence_equal.common().member_flags().IS_OPTIONAL(false); - cst_my_sequence_equal.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_sequence_equal.common().member_flags().IS_KEY(false); - cst_my_sequence_equal.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_sequence_equal.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("int32_t", 2, true)); - - cst_my_sequence_equal.detail().name("my_sequence_equal"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_sequence_equal); - - - // Header - type_object->complete().struct_type().header().detail().type_name("SequenceStructEqual"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SequenceStructEqual", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SequenceStructEqual", true); -} - - - - - -const TypeIdentifier* GetSequenceBadStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("SequenceBadStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetSequenceBadStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("SequenceBadStruct", complete); -} - -const TypeObject* GetSequenceBadStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SequenceBadStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteSequenceBadStructObject(); - } - //else - return GetMinimalSequenceBadStructObject(); -} - -const TypeObject* GetMinimalSequenceBadStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SequenceBadStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_sequence; - mst_my_sequence.common().member_id(memberId++); - mst_my_sequence.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_sequence.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_sequence.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_sequence.common().member_flags().IS_OPTIONAL(false); - mst_my_sequence.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_sequence.common().member_flags().IS_KEY(false); - mst_my_sequence.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_sequence.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("uint8_t", 2, false)); - - MD5 my_sequence_hash("my_sequence"); - for(int i = 0; i < 4; ++i) - { - mst_my_sequence.detail().name_hash()[i] = my_sequence_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_sequence); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SequenceBadStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SequenceBadStruct", false); -} - -const TypeObject* GetCompleteSequenceBadStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SequenceBadStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_sequence; - cst_my_sequence.common().member_id(memberId++); - cst_my_sequence.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_sequence.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_sequence.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_sequence.common().member_flags().IS_OPTIONAL(false); - cst_my_sequence.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_sequence.common().member_flags().IS_KEY(false); - cst_my_sequence.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_sequence.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("uint8_t", 2, true)); - - cst_my_sequence.detail().name("my_sequence"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_sequence); - - - // Header - type_object->complete().struct_type().header().detail().type_name("SequenceBadStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SequenceBadStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SequenceBadStruct", true); -} - - - - - -const TypeIdentifier* GetSequenceBoundsStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("SequenceBoundsStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetSequenceBoundsStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("SequenceBoundsStruct", complete); -} - -const TypeObject* GetSequenceBoundsStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SequenceBoundsStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteSequenceBoundsStructObject(); - } - //else - return GetMinimalSequenceBoundsStructObject(); -} - -const TypeObject* GetMinimalSequenceBoundsStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SequenceBoundsStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_sequence; - mst_my_sequence.common().member_id(memberId++); - mst_my_sequence.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_sequence.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_sequence.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_sequence.common().member_flags().IS_OPTIONAL(false); - mst_my_sequence.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_sequence.common().member_flags().IS_KEY(false); - mst_my_sequence.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_sequence.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("int32_t", 4, false)); - - MD5 my_sequence_hash("my_sequence"); - for(int i = 0; i < 4; ++i) - { - mst_my_sequence.detail().name_hash()[i] = my_sequence_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_sequence); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SequenceBoundsStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SequenceBoundsStruct", false); -} - -const TypeObject* GetCompleteSequenceBoundsStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SequenceBoundsStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_sequence; - cst_my_sequence.common().member_id(memberId++); - cst_my_sequence.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_sequence.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_sequence.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_sequence.common().member_flags().IS_OPTIONAL(false); - cst_my_sequence.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_sequence.common().member_flags().IS_KEY(false); - cst_my_sequence.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_sequence.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("int32_t", 4, true)); - - cst_my_sequence.detail().name("my_sequence"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_sequence); - - - // Header - type_object->complete().struct_type().header().detail().type_name("SequenceBoundsStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SequenceBoundsStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SequenceBoundsStruct", true); -} - - - - - - - -const TypeIdentifier* GetSequenceSequenceStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("SequenceSequenceStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetSequenceSequenceStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("SequenceSequenceStruct", complete); -} - -const TypeObject* GetSequenceSequenceStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SequenceSequenceStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteSequenceSequenceStructObject(); - } - //else - return GetMinimalSequenceSequenceStructObject(); -} - -const TypeObject* GetMinimalSequenceSequenceStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SequenceSequenceStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_sequence_sequence; - mst_my_sequence_sequence.common().member_id(memberId++); - mst_my_sequence_sequence.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_sequence_sequence.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_sequence_sequence.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_sequence_sequence.common().member_flags().IS_OPTIONAL(false); - mst_my_sequence_sequence.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_sequence_sequence.common().member_flags().IS_KEY(false); - mst_my_sequence_sequence.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_sequence_sequence.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier(TypeNamesGenerator::get_sequence_type_name("int32_t", 2), 3, false)); - - MD5 my_sequence_sequence_hash("my_sequence_sequence"); - for(int i = 0; i < 4; ++i) - { - mst_my_sequence_sequence.detail().name_hash()[i] = my_sequence_sequence_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_sequence_sequence); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SequenceSequenceStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SequenceSequenceStruct", false); -} - -const TypeObject* GetCompleteSequenceSequenceStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SequenceSequenceStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_sequence_sequence; - cst_my_sequence_sequence.common().member_id(memberId++); - cst_my_sequence_sequence.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_sequence_sequence.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_sequence_sequence.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_sequence_sequence.common().member_flags().IS_OPTIONAL(false); - cst_my_sequence_sequence.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_sequence_sequence.common().member_flags().IS_KEY(false); - cst_my_sequence_sequence.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_sequence_sequence.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier(TypeNamesGenerator::get_sequence_type_name("int32_t", 2), 3, true)); - - cst_my_sequence_sequence.detail().name("my_sequence_sequence"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_sequence_sequence); - - - // Header - type_object->complete().struct_type().header().detail().type_name("SequenceSequenceStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SequenceSequenceStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SequenceSequenceStruct", true); -} - - - - - - - -const TypeIdentifier* GetSequenceSequenceBoundsStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("SequenceSequenceBoundsStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetSequenceSequenceBoundsStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("SequenceSequenceBoundsStruct", complete); -} - -const TypeObject* GetSequenceSequenceBoundsStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SequenceSequenceBoundsStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteSequenceSequenceBoundsStructObject(); - } - //else - return GetMinimalSequenceSequenceBoundsStructObject(); -} - -const TypeObject* GetMinimalSequenceSequenceBoundsStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SequenceSequenceBoundsStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_sequence_sequence; - mst_my_sequence_sequence.common().member_id(memberId++); - mst_my_sequence_sequence.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_sequence_sequence.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_sequence_sequence.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_sequence_sequence.common().member_flags().IS_OPTIONAL(false); - mst_my_sequence_sequence.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_sequence_sequence.common().member_flags().IS_KEY(false); - mst_my_sequence_sequence.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_sequence_sequence.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier(TypeNamesGenerator::get_sequence_type_name("int32_t", 5), 5, false)); - - MD5 my_sequence_sequence_hash("my_sequence_sequence"); - for(int i = 0; i < 4; ++i) - { - mst_my_sequence_sequence.detail().name_hash()[i] = my_sequence_sequence_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_sequence_sequence); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SequenceSequenceBoundsStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SequenceSequenceBoundsStruct", false); -} - -const TypeObject* GetCompleteSequenceSequenceBoundsStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SequenceSequenceBoundsStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_sequence_sequence; - cst_my_sequence_sequence.common().member_id(memberId++); - cst_my_sequence_sequence.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_sequence_sequence.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_sequence_sequence.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_sequence_sequence.common().member_flags().IS_OPTIONAL(false); - cst_my_sequence_sequence.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_sequence_sequence.common().member_flags().IS_KEY(false); - cst_my_sequence_sequence.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_sequence_sequence.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier(TypeNamesGenerator::get_sequence_type_name("int32_t", 5), 5, true)); - - cst_my_sequence_sequence.detail().name("my_sequence_sequence"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_sequence_sequence); - - - // Header - type_object->complete().struct_type().header().detail().type_name("SequenceSequenceBoundsStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SequenceSequenceBoundsStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SequenceSequenceBoundsStruct", true); -} - - - - - -const TypeIdentifier* GetMapStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("MapStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetMapStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("MapStruct", complete); -} - -const TypeObject* GetMapStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MapStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteMapStructObject(); - } - //else - return GetMinimalMapStructObject(); -} - -const TypeObject* GetMinimalMapStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MapStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_map; - mst_my_map.common().member_id(memberId++); - mst_my_map.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_map.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_map.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_map.common().member_flags().IS_OPTIONAL(false); - mst_my_map.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_map.common().member_flags().IS_KEY(false); - mst_my_map.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_map.common().member_type_id(*TypeObjectFactory::get_instance()->get_map_identifier("int32_t", "int32_t", 2, false)); - - MD5 my_map_hash("my_map"); - for(int i = 0; i < 4; ++i) - { - mst_my_map.detail().name_hash()[i] = my_map_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_map); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MapStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MapStruct", false); -} - -const TypeObject* GetCompleteMapStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MapStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_map; - cst_my_map.common().member_id(memberId++); - cst_my_map.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_map.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_map.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_map.common().member_flags().IS_OPTIONAL(false); - cst_my_map.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_map.common().member_flags().IS_KEY(false); - cst_my_map.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_map.common().member_type_id(*TypeObjectFactory::get_instance()->get_map_identifier("int32_t", "int32_t", 2, true)); - - cst_my_map.detail().name("my_map"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_map); - - - // Header - type_object->complete().struct_type().header().detail().type_name("MapStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MapStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MapStruct", true); -} - - - - - -const TypeIdentifier* GetMapStructEqualIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("MapStructEqual", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetMapStructEqualObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("MapStructEqual", complete); -} - -const TypeObject* GetMapStructEqualObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MapStructEqual", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteMapStructEqualObject(); - } - //else - return GetMinimalMapStructEqualObject(); -} - -const TypeObject* GetMinimalMapStructEqualObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MapStructEqual", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_map_equal; - mst_my_map_equal.common().member_id(memberId++); - mst_my_map_equal.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_map_equal.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_map_equal.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_map_equal.common().member_flags().IS_OPTIONAL(false); - mst_my_map_equal.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_map_equal.common().member_flags().IS_KEY(false); - mst_my_map_equal.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_map_equal.common().member_type_id(*TypeObjectFactory::get_instance()->get_map_identifier("int32_t", "int32_t", 2, false)); - - MD5 my_map_equal_hash("my_map_equal"); - for(int i = 0; i < 4; ++i) - { - mst_my_map_equal.detail().name_hash()[i] = my_map_equal_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_map_equal); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MapStructEqual", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MapStructEqual", false); -} - -const TypeObject* GetCompleteMapStructEqualObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MapStructEqual", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_map_equal; - cst_my_map_equal.common().member_id(memberId++); - cst_my_map_equal.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_map_equal.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_map_equal.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_map_equal.common().member_flags().IS_OPTIONAL(false); - cst_my_map_equal.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_map_equal.common().member_flags().IS_KEY(false); - cst_my_map_equal.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_map_equal.common().member_type_id(*TypeObjectFactory::get_instance()->get_map_identifier("int32_t", "int32_t", 2, true)); - - cst_my_map_equal.detail().name("my_map_equal"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_map_equal); - - - // Header - type_object->complete().struct_type().header().detail().type_name("MapStructEqual"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MapStructEqual", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MapStructEqual", true); -} - - - - - -const TypeIdentifier* GetMapBadKeyStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("MapBadKeyStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetMapBadKeyStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("MapBadKeyStruct", complete); -} - -const TypeObject* GetMapBadKeyStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MapBadKeyStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteMapBadKeyStructObject(); - } - //else - return GetMinimalMapBadKeyStructObject(); -} - -const TypeObject* GetMinimalMapBadKeyStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MapBadKeyStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_map; - mst_my_map.common().member_id(memberId++); - mst_my_map.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_map.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_map.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_map.common().member_flags().IS_OPTIONAL(false); - mst_my_map.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_map.common().member_flags().IS_KEY(false); - mst_my_map.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_map.common().member_type_id(*TypeObjectFactory::get_instance()->get_map_identifier("uint8_t", "int32_t", 2, false)); - - MD5 my_map_hash("my_map"); - for(int i = 0; i < 4; ++i) - { - mst_my_map.detail().name_hash()[i] = my_map_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_map); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MapBadKeyStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MapBadKeyStruct", false); -} - -const TypeObject* GetCompleteMapBadKeyStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MapBadKeyStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_map; - cst_my_map.common().member_id(memberId++); - cst_my_map.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_map.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_map.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_map.common().member_flags().IS_OPTIONAL(false); - cst_my_map.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_map.common().member_flags().IS_KEY(false); - cst_my_map.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_map.common().member_type_id(*TypeObjectFactory::get_instance()->get_map_identifier("uint8_t", "int32_t", 2, true)); - - cst_my_map.detail().name("my_map"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_map); - - - // Header - type_object->complete().struct_type().header().detail().type_name("MapBadKeyStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MapBadKeyStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MapBadKeyStruct", true); -} - - - - - -const TypeIdentifier* GetMapBadElemStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("MapBadElemStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetMapBadElemStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("MapBadElemStruct", complete); -} - -const TypeObject* GetMapBadElemStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MapBadElemStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteMapBadElemStructObject(); - } - //else - return GetMinimalMapBadElemStructObject(); -} - -const TypeObject* GetMinimalMapBadElemStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MapBadElemStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_map; - mst_my_map.common().member_id(memberId++); - mst_my_map.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_map.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_map.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_map.common().member_flags().IS_OPTIONAL(false); - mst_my_map.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_map.common().member_flags().IS_KEY(false); - mst_my_map.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_map.common().member_type_id(*TypeObjectFactory::get_instance()->get_map_identifier("int32_t", "int64_t", 2, false)); - - MD5 my_map_hash("my_map"); - for(int i = 0; i < 4; ++i) - { - mst_my_map.detail().name_hash()[i] = my_map_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_map); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MapBadElemStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MapBadElemStruct", false); -} - -const TypeObject* GetCompleteMapBadElemStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MapBadElemStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_map; - cst_my_map.common().member_id(memberId++); - cst_my_map.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_map.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_map.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_map.common().member_flags().IS_OPTIONAL(false); - cst_my_map.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_map.common().member_flags().IS_KEY(false); - cst_my_map.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_map.common().member_type_id(*TypeObjectFactory::get_instance()->get_map_identifier("int32_t", "int64_t", 2, true)); - - cst_my_map.detail().name("my_map"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_map); - - - // Header - type_object->complete().struct_type().header().detail().type_name("MapBadElemStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MapBadElemStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MapBadElemStruct", true); -} - - - - - -const TypeIdentifier* GetMapBoundsStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("MapBoundsStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetMapBoundsStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("MapBoundsStruct", complete); -} - -const TypeObject* GetMapBoundsStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MapBoundsStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteMapBoundsStructObject(); - } - //else - return GetMinimalMapBoundsStructObject(); -} - -const TypeObject* GetMinimalMapBoundsStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MapBoundsStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_map; - mst_my_map.common().member_id(memberId++); - mst_my_map.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_map.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_map.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_map.common().member_flags().IS_OPTIONAL(false); - mst_my_map.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_map.common().member_flags().IS_KEY(false); - mst_my_map.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_map.common().member_type_id(*TypeObjectFactory::get_instance()->get_map_identifier("int32_t", "int32_t", 4, false)); - - MD5 my_map_hash("my_map"); - for(int i = 0; i < 4; ++i) - { - mst_my_map.detail().name_hash()[i] = my_map_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_map); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MapBoundsStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MapBoundsStruct", false); -} - -const TypeObject* GetCompleteMapBoundsStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MapBoundsStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_map; - cst_my_map.common().member_id(memberId++); - cst_my_map.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_map.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_map.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_map.common().member_flags().IS_OPTIONAL(false); - cst_my_map.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_map.common().member_flags().IS_KEY(false); - cst_my_map.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_map.common().member_type_id(*TypeObjectFactory::get_instance()->get_map_identifier("int32_t", "int32_t", 4, true)); - - cst_my_map.detail().name("my_map"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_map); - - - // Header - type_object->complete().struct_type().header().detail().type_name("MapBoundsStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MapBoundsStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MapBoundsStruct", true); -} - - - - - - - -const TypeIdentifier* GetMapMapStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("MapMapStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetMapMapStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("MapMapStruct", complete); -} - -const TypeObject* GetMapMapStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MapMapStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteMapMapStructObject(); - } - //else - return GetMinimalMapMapStructObject(); -} - -const TypeObject* GetMinimalMapMapStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MapMapStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_map_map; - mst_my_map_map.common().member_id(memberId++); - mst_my_map_map.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_map_map.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_map_map.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_map_map.common().member_flags().IS_OPTIONAL(false); - mst_my_map_map.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_map_map.common().member_flags().IS_KEY(false); - mst_my_map_map.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_map_map.common().member_type_id(*TypeObjectFactory::get_instance()->get_map_identifier("int32_t", TypeNamesGenerator::get_map_type_name("int32_t", "int32_t", 2), 2, false)); - - MD5 my_map_map_hash("my_map_map"); - for(int i = 0; i < 4; ++i) - { - mst_my_map_map.detail().name_hash()[i] = my_map_map_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_map_map); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MapMapStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MapMapStruct", false); -} - -const TypeObject* GetCompleteMapMapStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MapMapStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_map_map; - cst_my_map_map.common().member_id(memberId++); - cst_my_map_map.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_map_map.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_map_map.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_map_map.common().member_flags().IS_OPTIONAL(false); - cst_my_map_map.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_map_map.common().member_flags().IS_KEY(false); - cst_my_map_map.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_map_map.common().member_type_id(*TypeObjectFactory::get_instance()->get_map_identifier("int32_t", TypeNamesGenerator::get_map_type_name("int32_t", "int32_t", 2), 2, true)); - - cst_my_map_map.detail().name("my_map_map"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_map_map); - - - // Header - type_object->complete().struct_type().header().detail().type_name("MapMapStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MapMapStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MapMapStruct", true); -} - - - - - - - -const TypeIdentifier* GetMapMapBoundsStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("MapMapBoundsStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetMapMapBoundsStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("MapMapBoundsStruct", complete); -} - -const TypeObject* GetMapMapBoundsStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MapMapBoundsStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteMapMapBoundsStructObject(); - } - //else - return GetMinimalMapMapBoundsStructObject(); -} - -const TypeObject* GetMinimalMapMapBoundsStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MapMapBoundsStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_map_map; - mst_my_map_map.common().member_id(memberId++); - mst_my_map_map.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_map_map.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_map_map.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_map_map.common().member_flags().IS_OPTIONAL(false); - mst_my_map_map.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_map_map.common().member_flags().IS_KEY(false); - mst_my_map_map.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_map_map.common().member_type_id(*TypeObjectFactory::get_instance()->get_map_identifier("int32_t", TypeNamesGenerator::get_map_type_name("int32_t", "int32_t", 3), 3, false)); - - MD5 my_map_map_hash("my_map_map"); - for(int i = 0; i < 4; ++i) - { - mst_my_map_map.detail().name_hash()[i] = my_map_map_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_map_map); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MapMapBoundsStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MapMapBoundsStruct", false); -} - -const TypeObject* GetCompleteMapMapBoundsStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MapMapBoundsStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_map_map; - cst_my_map_map.common().member_id(memberId++); - cst_my_map_map.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_map_map.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_map_map.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_map_map.common().member_flags().IS_OPTIONAL(false); - cst_my_map_map.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_map_map.common().member_flags().IS_KEY(false); - cst_my_map_map.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_map_map.common().member_type_id(*TypeObjectFactory::get_instance()->get_map_identifier("int32_t", TypeNamesGenerator::get_map_type_name("int32_t", "int32_t", 3), 3, true)); - - cst_my_map_map.detail().name("my_map_map"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_map_map); - - - // Header - type_object->complete().struct_type().header().detail().type_name("MapMapBoundsStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MapMapBoundsStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MapMapBoundsStruct", true); -} - - - -const TypeIdentifier* GetSimpleUnionIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("SimpleUnion", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetSimpleUnionObject(complete); - return TypeObjectFactory::get_instance()->get_type_identifier("SimpleUnion", complete); -} - -const TypeObject* GetSimpleUnionObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleUnion", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteSimpleUnionObject(); - } - // else - return GetMinimalSimpleUnionObject(); -} - -const TypeObject* GetMinimalSimpleUnionObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleUnion", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_UNION); - - type_object->minimal().union_type().union_flags().IS_FINAL(false); - type_object->minimal().union_type().union_flags().IS_APPENDABLE(false); - type_object->minimal().union_type().union_flags().IS_MUTABLE(false); - type_object->minimal().union_type().union_flags().IS_NESTED(false); - type_object->minimal().union_type().union_flags().IS_AUTOID_HASH(false); // Unsupported - - type_object->minimal().union_type().discriminator().common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().IS_EXTERNAL(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_OPTIONAL(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_KEY(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().IS_DEFAULT(false); // Doesn't apply - - type_object->minimal().union_type().discriminator().common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - MemberId memberId = 0; - MinimalUnionMember mst_first; - mst_first.common().member_id(memberId++); - mst_first.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_first.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_first.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_first.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - mst_first.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mst_first.common().member_flags().IS_KEY(false); // Doesn't apply - mst_first.common().member_flags().IS_DEFAULT(false); - mst_first.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - mst_first.common().label_seq().emplace_back(A); - - MD5 first_hash("first"); - for(int i = 0; i < 4; ++i) - { - mst_first.detail().name_hash()[i] = first_hash.digest[i]; - } - type_object->minimal().union_type().member_seq().emplace_back(mst_first); - - MinimalUnionMember mst_second; - mst_second.common().member_id(memberId++); - mst_second.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_second.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_second.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_second.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - mst_second.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mst_second.common().member_flags().IS_KEY(false); // Doesn't apply - mst_second.common().member_flags().IS_DEFAULT(false); - mst_second.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int64_t", false)); - - - mst_second.common().label_seq().emplace_back(B); - - MD5 second_hash("second"); - for(int i = 0; i < 4; ++i) - { - mst_second.detail().name_hash()[i] = second_hash.digest[i]; - } - type_object->minimal().union_type().member_seq().emplace_back(mst_second); - - - // Header - //type_object->minimal().union_type().header().detail()... // Empty - - TypeIdentifier* identifier = new TypeIdentifier(); - identifier->_d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().union_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier->equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimpleUnion", identifier, type_object); - delete type_object; - delete identifier; - return TypeObjectFactory::get_instance()->get_type_object("SimpleUnion", false); -} - -const TypeObject* GetCompleteSimpleUnionObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleUnion", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_UNION); - - type_object->complete().union_type().union_flags().IS_FINAL(false); - type_object->complete().union_type().union_flags().IS_APPENDABLE(false); - type_object->complete().union_type().union_flags().IS_MUTABLE(false); - type_object->complete().union_type().union_flags().IS_NESTED(false); - type_object->complete().union_type().union_flags().IS_AUTOID_HASH(false); // Unsupported - - type_object->complete().union_type().discriminator().common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().IS_EXTERNAL(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_OPTIONAL(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_KEY(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().IS_DEFAULT(false); // Doesn't apply - - type_object->complete().union_type().discriminator().common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - MemberId memberId = 0; - CompleteUnionMember cst_first; - cst_first.common().member_id(memberId++); - cst_first.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_first.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_first.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_first.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - cst_first.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cst_first.common().member_flags().IS_KEY(false); // Doesn't apply - cst_first.common().member_flags().IS_DEFAULT(false); - cst_first.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - cst_first.common().label_seq().emplace_back(A); - - - cst_first.detail().name("first"); - - type_object->complete().union_type().member_seq().emplace_back(cst_first); - - CompleteUnionMember cst_second; - cst_second.common().member_id(memberId++); - cst_second.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_second.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_second.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_second.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - cst_second.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cst_second.common().member_flags().IS_KEY(false); // Doesn't apply - cst_second.common().member_flags().IS_DEFAULT(false); - cst_second.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int64_t", false)); - - cst_second.common().label_seq().emplace_back(B); - - - cst_second.detail().name("second"); - - type_object->complete().union_type().member_seq().emplace_back(cst_second); - - - // Header - type_object->complete().union_type().header().detail().type_name("SimpleUnion"); - - TypeIdentifier* identifier = new TypeIdentifier(); - identifier->_d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().union_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier->equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimpleUnion", identifier, type_object); - delete type_object; - delete identifier; - return TypeObjectFactory::get_instance()->get_type_object("SimpleUnion", true); -} - - - -const TypeIdentifier* GetSimpleUnionNamesIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("SimpleUnionNames", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetSimpleUnionNamesObject(complete); - return TypeObjectFactory::get_instance()->get_type_identifier("SimpleUnionNames", complete); -} - -const TypeObject* GetSimpleUnionNamesObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleUnionNames", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteSimpleUnionNamesObject(); - } - // else - return GetMinimalSimpleUnionNamesObject(); -} - -const TypeObject* GetMinimalSimpleUnionNamesObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleUnionNames", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_UNION); - - type_object->minimal().union_type().union_flags().IS_FINAL(false); - type_object->minimal().union_type().union_flags().IS_APPENDABLE(false); - type_object->minimal().union_type().union_flags().IS_MUTABLE(false); - type_object->minimal().union_type().union_flags().IS_NESTED(false); - type_object->minimal().union_type().union_flags().IS_AUTOID_HASH(false); // Unsupported - - type_object->minimal().union_type().discriminator().common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().IS_EXTERNAL(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_OPTIONAL(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_KEY(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().IS_DEFAULT(false); // Doesn't apply - - type_object->minimal().union_type().discriminator().common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - MemberId memberId = 0; - MinimalUnionMember mst_first_case; - mst_first_case.common().member_id(memberId++); - mst_first_case.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_first_case.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_first_case.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_first_case.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - mst_first_case.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mst_first_case.common().member_flags().IS_KEY(false); // Doesn't apply - mst_first_case.common().member_flags().IS_DEFAULT(false); - mst_first_case.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - mst_first_case.common().label_seq().emplace_back(A); - - MD5 first_case_hash("first_case"); - for(int i = 0; i < 4; ++i) - { - mst_first_case.detail().name_hash()[i] = first_case_hash.digest[i]; - } - type_object->minimal().union_type().member_seq().emplace_back(mst_first_case); - - MinimalUnionMember mst_second_case; - mst_second_case.common().member_id(memberId++); - mst_second_case.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_second_case.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_second_case.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_second_case.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - mst_second_case.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mst_second_case.common().member_flags().IS_KEY(false); // Doesn't apply - mst_second_case.common().member_flags().IS_DEFAULT(false); - mst_second_case.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int64_t", false)); - - - mst_second_case.common().label_seq().emplace_back(B); - - MD5 second_case_hash("second_case"); - for(int i = 0; i < 4; ++i) - { - mst_second_case.detail().name_hash()[i] = second_case_hash.digest[i]; - } - type_object->minimal().union_type().member_seq().emplace_back(mst_second_case); - - - // Header - //type_object->minimal().union_type().header().detail()... // Empty - - TypeIdentifier* identifier = new TypeIdentifier(); - identifier->_d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().union_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier->equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimpleUnionNames", identifier, type_object); - delete type_object; - delete identifier; - return TypeObjectFactory::get_instance()->get_type_object("SimpleUnionNames", false); -} - -const TypeObject* GetCompleteSimpleUnionNamesObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleUnionNames", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_UNION); - - type_object->complete().union_type().union_flags().IS_FINAL(false); - type_object->complete().union_type().union_flags().IS_APPENDABLE(false); - type_object->complete().union_type().union_flags().IS_MUTABLE(false); - type_object->complete().union_type().union_flags().IS_NESTED(false); - type_object->complete().union_type().union_flags().IS_AUTOID_HASH(false); // Unsupported - - type_object->complete().union_type().discriminator().common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().IS_EXTERNAL(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_OPTIONAL(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_KEY(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().IS_DEFAULT(false); // Doesn't apply - - type_object->complete().union_type().discriminator().common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - MemberId memberId = 0; - CompleteUnionMember cst_first_case; - cst_first_case.common().member_id(memberId++); - cst_first_case.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_first_case.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_first_case.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_first_case.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - cst_first_case.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cst_first_case.common().member_flags().IS_KEY(false); // Doesn't apply - cst_first_case.common().member_flags().IS_DEFAULT(false); - cst_first_case.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - cst_first_case.common().label_seq().emplace_back(A); - - - cst_first_case.detail().name("first_case"); - - type_object->complete().union_type().member_seq().emplace_back(cst_first_case); - - CompleteUnionMember cst_second_case; - cst_second_case.common().member_id(memberId++); - cst_second_case.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_second_case.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_second_case.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_second_case.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - cst_second_case.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cst_second_case.common().member_flags().IS_KEY(false); // Doesn't apply - cst_second_case.common().member_flags().IS_DEFAULT(false); - cst_second_case.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int64_t", false)); - - cst_second_case.common().label_seq().emplace_back(B); - - - cst_second_case.detail().name("second_case"); - - type_object->complete().union_type().member_seq().emplace_back(cst_second_case); - - - // Header - type_object->complete().union_type().header().detail().type_name("SimpleUnionNames"); - - TypeIdentifier* identifier = new TypeIdentifier(); - identifier->_d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().union_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier->equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimpleUnionNames", identifier, type_object); - delete type_object; - delete identifier; - return TypeObjectFactory::get_instance()->get_type_object("SimpleUnionNames", true); -} - - - -const TypeIdentifier* GetSimpleTypeUnionIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("SimpleTypeUnion", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetSimpleTypeUnionObject(complete); - return TypeObjectFactory::get_instance()->get_type_identifier("SimpleTypeUnion", complete); -} - -const TypeObject* GetSimpleTypeUnionObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleTypeUnion", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteSimpleTypeUnionObject(); - } - // else - return GetMinimalSimpleTypeUnionObject(); -} - -const TypeObject* GetMinimalSimpleTypeUnionObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleTypeUnion", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_UNION); - - type_object->minimal().union_type().union_flags().IS_FINAL(false); - type_object->minimal().union_type().union_flags().IS_APPENDABLE(false); - type_object->minimal().union_type().union_flags().IS_MUTABLE(false); - type_object->minimal().union_type().union_flags().IS_NESTED(false); - type_object->minimal().union_type().union_flags().IS_AUTOID_HASH(false); // Unsupported - - type_object->minimal().union_type().discriminator().common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().IS_EXTERNAL(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_OPTIONAL(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_KEY(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().IS_DEFAULT(false); // Doesn't apply - - type_object->minimal().union_type().discriminator().common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - MemberId memberId = 0; - MinimalUnionMember mst_first; - mst_first.common().member_id(memberId++); - mst_first.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_first.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_first.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_first.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - mst_first.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mst_first.common().member_flags().IS_KEY(false); // Doesn't apply - mst_first.common().member_flags().IS_DEFAULT(false); - mst_first.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint8_t", false)); - - - mst_first.common().label_seq().emplace_back(A); - - MD5 first_hash("first"); - for(int i = 0; i < 4; ++i) - { - mst_first.detail().name_hash()[i] = first_hash.digest[i]; - } - type_object->minimal().union_type().member_seq().emplace_back(mst_first); - - MinimalUnionMember mst_second; - mst_second.common().member_id(memberId++); - mst_second.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_second.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_second.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_second.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - mst_second.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mst_second.common().member_flags().IS_KEY(false); // Doesn't apply - mst_second.common().member_flags().IS_DEFAULT(false); - mst_second.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int64_t", false)); - - - mst_second.common().label_seq().emplace_back(B); - - MD5 second_hash("second"); - for(int i = 0; i < 4; ++i) - { - mst_second.detail().name_hash()[i] = second_hash.digest[i]; - } - type_object->minimal().union_type().member_seq().emplace_back(mst_second); - - - // Header - //type_object->minimal().union_type().header().detail()... // Empty - - TypeIdentifier* identifier = new TypeIdentifier(); - identifier->_d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().union_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier->equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimpleTypeUnion", identifier, type_object); - delete type_object; - delete identifier; - return TypeObjectFactory::get_instance()->get_type_object("SimpleTypeUnion", false); -} - -const TypeObject* GetCompleteSimpleTypeUnionObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleTypeUnion", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_UNION); - - type_object->complete().union_type().union_flags().IS_FINAL(false); - type_object->complete().union_type().union_flags().IS_APPENDABLE(false); - type_object->complete().union_type().union_flags().IS_MUTABLE(false); - type_object->complete().union_type().union_flags().IS_NESTED(false); - type_object->complete().union_type().union_flags().IS_AUTOID_HASH(false); // Unsupported - - type_object->complete().union_type().discriminator().common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().IS_EXTERNAL(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_OPTIONAL(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_KEY(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().IS_DEFAULT(false); // Doesn't apply - - type_object->complete().union_type().discriminator().common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - MemberId memberId = 0; - CompleteUnionMember cst_first; - cst_first.common().member_id(memberId++); - cst_first.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_first.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_first.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_first.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - cst_first.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cst_first.common().member_flags().IS_KEY(false); // Doesn't apply - cst_first.common().member_flags().IS_DEFAULT(false); - cst_first.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint8_t", false)); - - cst_first.common().label_seq().emplace_back(A); - - - cst_first.detail().name("first"); - - type_object->complete().union_type().member_seq().emplace_back(cst_first); - - CompleteUnionMember cst_second; - cst_second.common().member_id(memberId++); - cst_second.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_second.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_second.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_second.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - cst_second.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cst_second.common().member_flags().IS_KEY(false); // Doesn't apply - cst_second.common().member_flags().IS_DEFAULT(false); - cst_second.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int64_t", false)); - - cst_second.common().label_seq().emplace_back(B); - - - cst_second.detail().name("second"); - - type_object->complete().union_type().member_seq().emplace_back(cst_second); - - - // Header - type_object->complete().union_type().header().detail().type_name("SimpleTypeUnion"); - - TypeIdentifier* identifier = new TypeIdentifier(); - identifier->_d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().union_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier->equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimpleTypeUnion", identifier, type_object); - delete type_object; - delete identifier; - return TypeObjectFactory::get_instance()->get_type_object("SimpleTypeUnion", true); -} - - - -const TypeIdentifier* GetSimpleBadUnionIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("SimpleBadUnion", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetSimpleBadUnionObject(complete); - return TypeObjectFactory::get_instance()->get_type_identifier("SimpleBadUnion", complete); -} - -const TypeObject* GetSimpleBadUnionObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleBadUnion", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteSimpleBadUnionObject(); - } - // else - return GetMinimalSimpleBadUnionObject(); -} - -const TypeObject* GetMinimalSimpleBadUnionObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleBadUnion", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_UNION); - - type_object->minimal().union_type().union_flags().IS_FINAL(false); - type_object->minimal().union_type().union_flags().IS_APPENDABLE(false); - type_object->minimal().union_type().union_flags().IS_MUTABLE(false); - type_object->minimal().union_type().union_flags().IS_NESTED(false); - type_object->minimal().union_type().union_flags().IS_AUTOID_HASH(false); // Unsupported - - type_object->minimal().union_type().discriminator().common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().IS_EXTERNAL(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_OPTIONAL(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_KEY(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().IS_DEFAULT(false); // Doesn't apply - - type_object->minimal().union_type().discriminator().common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - MemberId memberId = 0; - MinimalUnionMember mst_first; - mst_first.common().member_id(memberId++); - mst_first.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_first.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_first.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_first.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - mst_first.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mst_first.common().member_flags().IS_KEY(false); // Doesn't apply - mst_first.common().member_flags().IS_DEFAULT(false); - mst_first.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - mst_first.common().label_seq().emplace_back(A); - - MD5 first_hash("first"); - for(int i = 0; i < 4; ++i) - { - mst_first.detail().name_hash()[i] = first_hash.digest[i]; - } - type_object->minimal().union_type().member_seq().emplace_back(mst_first); - - MinimalUnionMember mst_second; - mst_second.common().member_id(memberId++); - mst_second.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_second.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_second.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_second.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - mst_second.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mst_second.common().member_flags().IS_KEY(false); // Doesn't apply - mst_second.common().member_flags().IS_DEFAULT(false); - mst_second.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int64_t", false)); - - - mst_second.common().label_seq().emplace_back(C); - - MD5 second_hash("second"); - for(int i = 0; i < 4; ++i) - { - mst_second.detail().name_hash()[i] = second_hash.digest[i]; - } - type_object->minimal().union_type().member_seq().emplace_back(mst_second); - - - // Header - //type_object->minimal().union_type().header().detail()... // Empty - - TypeIdentifier* identifier = new TypeIdentifier(); - identifier->_d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().union_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier->equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimpleBadUnion", identifier, type_object); - delete type_object; - delete identifier; - return TypeObjectFactory::get_instance()->get_type_object("SimpleBadUnion", false); -} - -const TypeObject* GetCompleteSimpleBadUnionObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleBadUnion", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_UNION); - - type_object->complete().union_type().union_flags().IS_FINAL(false); - type_object->complete().union_type().union_flags().IS_APPENDABLE(false); - type_object->complete().union_type().union_flags().IS_MUTABLE(false); - type_object->complete().union_type().union_flags().IS_NESTED(false); - type_object->complete().union_type().union_flags().IS_AUTOID_HASH(false); // Unsupported - - type_object->complete().union_type().discriminator().common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().IS_EXTERNAL(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_OPTIONAL(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_KEY(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().IS_DEFAULT(false); // Doesn't apply - - type_object->complete().union_type().discriminator().common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - MemberId memberId = 0; - CompleteUnionMember cst_first; - cst_first.common().member_id(memberId++); - cst_first.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_first.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_first.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_first.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - cst_first.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cst_first.common().member_flags().IS_KEY(false); // Doesn't apply - cst_first.common().member_flags().IS_DEFAULT(false); - cst_first.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - cst_first.common().label_seq().emplace_back(A); - - - cst_first.detail().name("first"); - - type_object->complete().union_type().member_seq().emplace_back(cst_first); - - CompleteUnionMember cst_second; - cst_second.common().member_id(memberId++); - cst_second.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_second.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_second.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_second.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - cst_second.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cst_second.common().member_flags().IS_KEY(false); // Doesn't apply - cst_second.common().member_flags().IS_DEFAULT(false); - cst_second.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int64_t", false)); - - cst_second.common().label_seq().emplace_back(C); - - - cst_second.detail().name("second"); - - type_object->complete().union_type().member_seq().emplace_back(cst_second); - - - // Header - type_object->complete().union_type().header().detail().type_name("SimpleBadUnion"); - - TypeIdentifier* identifier = new TypeIdentifier(); - identifier->_d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().union_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier->equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimpleBadUnion", identifier, type_object); - delete type_object; - delete identifier; - return TypeObjectFactory::get_instance()->get_type_object("SimpleBadUnion", true); -} - - - -const TypeIdentifier* GetSimpleBadDiscUnionIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("SimpleBadDiscUnion", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetSimpleBadDiscUnionObject(complete); - return TypeObjectFactory::get_instance()->get_type_identifier("SimpleBadDiscUnion", complete); -} - -const TypeObject* GetSimpleBadDiscUnionObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleBadDiscUnion", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteSimpleBadDiscUnionObject(); - } - // else - return GetMinimalSimpleBadDiscUnionObject(); -} - -const TypeObject* GetMinimalSimpleBadDiscUnionObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleBadDiscUnion", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_UNION); - - type_object->minimal().union_type().union_flags().IS_FINAL(false); - type_object->minimal().union_type().union_flags().IS_APPENDABLE(false); - type_object->minimal().union_type().union_flags().IS_MUTABLE(false); - type_object->minimal().union_type().union_flags().IS_NESTED(false); - type_object->minimal().union_type().union_flags().IS_AUTOID_HASH(false); // Unsupported - - type_object->minimal().union_type().discriminator().common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().IS_EXTERNAL(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_OPTIONAL(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_KEY(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().IS_DEFAULT(false); // Doesn't apply - - type_object->minimal().union_type().discriminator().common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint8_t", false)); - - MemberId memberId = 0; - MinimalUnionMember mst_first; - mst_first.common().member_id(memberId++); - mst_first.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_first.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_first.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_first.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - mst_first.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mst_first.common().member_flags().IS_KEY(false); // Doesn't apply - mst_first.common().member_flags().IS_DEFAULT(false); - mst_first.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - mst_first.common().label_seq().emplace_back(0); - - MD5 first_hash("first"); - for(int i = 0; i < 4; ++i) - { - mst_first.detail().name_hash()[i] = first_hash.digest[i]; - } - type_object->minimal().union_type().member_seq().emplace_back(mst_first); - - MinimalUnionMember mst_second; - mst_second.common().member_id(memberId++); - mst_second.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_second.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_second.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_second.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - mst_second.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mst_second.common().member_flags().IS_KEY(false); // Doesn't apply - mst_second.common().member_flags().IS_DEFAULT(false); - mst_second.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int64_t", false)); - - - mst_second.common().label_seq().emplace_back(1); - - MD5 second_hash("second"); - for(int i = 0; i < 4; ++i) - { - mst_second.detail().name_hash()[i] = second_hash.digest[i]; - } - type_object->minimal().union_type().member_seq().emplace_back(mst_second); - - - // Header - //type_object->minimal().union_type().header().detail()... // Empty - - TypeIdentifier* identifier = new TypeIdentifier(); - identifier->_d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().union_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier->equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimpleBadDiscUnion", identifier, type_object); - delete type_object; - delete identifier; - return TypeObjectFactory::get_instance()->get_type_object("SimpleBadDiscUnion", false); -} - -const TypeObject* GetCompleteSimpleBadDiscUnionObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleBadDiscUnion", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_UNION); - - type_object->complete().union_type().union_flags().IS_FINAL(false); - type_object->complete().union_type().union_flags().IS_APPENDABLE(false); - type_object->complete().union_type().union_flags().IS_MUTABLE(false); - type_object->complete().union_type().union_flags().IS_NESTED(false); - type_object->complete().union_type().union_flags().IS_AUTOID_HASH(false); // Unsupported - - type_object->complete().union_type().discriminator().common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().IS_EXTERNAL(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_OPTIONAL(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_KEY(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().IS_DEFAULT(false); // Doesn't apply - - type_object->complete().union_type().discriminator().common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint8_t", false)); - - MemberId memberId = 0; - CompleteUnionMember cst_first; - cst_first.common().member_id(memberId++); - cst_first.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_first.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_first.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_first.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - cst_first.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cst_first.common().member_flags().IS_KEY(false); // Doesn't apply - cst_first.common().member_flags().IS_DEFAULT(false); - cst_first.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - cst_first.common().label_seq().emplace_back(0); - - - cst_first.detail().name("first"); - - type_object->complete().union_type().member_seq().emplace_back(cst_first); - - CompleteUnionMember cst_second; - cst_second.common().member_id(memberId++); - cst_second.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_second.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_second.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_second.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - cst_second.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cst_second.common().member_flags().IS_KEY(false); // Doesn't apply - cst_second.common().member_flags().IS_DEFAULT(false); - cst_second.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int64_t", false)); - - cst_second.common().label_seq().emplace_back(1); - - - cst_second.detail().name("second"); - - type_object->complete().union_type().member_seq().emplace_back(cst_second); - - - // Header - type_object->complete().union_type().header().detail().type_name("SimpleBadDiscUnion"); - - TypeIdentifier* identifier = new TypeIdentifier(); - identifier->_d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().union_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier->equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimpleBadDiscUnion", identifier, type_object); - delete type_object; - delete identifier; - return TypeObjectFactory::get_instance()->get_type_object("SimpleBadDiscUnion", true); -} - - - -const TypeIdentifier* GetSimpleUnionStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("SimpleUnionStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetSimpleUnionStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("SimpleUnionStruct", complete); -} - -const TypeObject* GetSimpleUnionStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleUnionStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteSimpleUnionStructObject(); - } - //else - return GetMinimalSimpleUnionStructObject(); -} - -const TypeObject* GetMinimalSimpleUnionStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleUnionStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_union; - mst_my_union.common().member_id(memberId++); - mst_my_union.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_union.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_union.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_union.common().member_flags().IS_OPTIONAL(false); - mst_my_union.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_union.common().member_flags().IS_KEY(false); - mst_my_union.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_union.common().member_type_id(*GetSimpleUnionIdentifier(false)); - - MD5 my_union_hash("my_union"); - for(int i = 0; i < 4; ++i) - { - mst_my_union.detail().name_hash()[i] = my_union_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_union); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimpleUnionStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SimpleUnionStruct", false); -} - -const TypeObject* GetCompleteSimpleUnionStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleUnionStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_union; - cst_my_union.common().member_id(memberId++); - cst_my_union.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_union.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_union.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_union.common().member_flags().IS_OPTIONAL(false); - cst_my_union.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_union.common().member_flags().IS_KEY(false); - cst_my_union.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_union.common().member_type_id(*GetSimpleUnionIdentifier(true)); - - cst_my_union.detail().name("my_union"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_union); - - - // Header - type_object->complete().struct_type().header().detail().type_name("SimpleUnionStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimpleUnionStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SimpleUnionStruct", true); -} - - - -const TypeIdentifier* GetSimpleUnionStructEqualIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("SimpleUnionStructEqual", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetSimpleUnionStructEqualObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("SimpleUnionStructEqual", complete); -} - -const TypeObject* GetSimpleUnionStructEqualObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleUnionStructEqual", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteSimpleUnionStructEqualObject(); - } - //else - return GetMinimalSimpleUnionStructEqualObject(); -} - -const TypeObject* GetMinimalSimpleUnionStructEqualObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleUnionStructEqual", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_union_equal; - mst_my_union_equal.common().member_id(memberId++); - mst_my_union_equal.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_union_equal.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_union_equal.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_union_equal.common().member_flags().IS_OPTIONAL(false); - mst_my_union_equal.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_union_equal.common().member_flags().IS_KEY(false); - mst_my_union_equal.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_union_equal.common().member_type_id(*GetSimpleUnionIdentifier(false)); - - MD5 my_union_equal_hash("my_union_equal"); - for(int i = 0; i < 4; ++i) - { - mst_my_union_equal.detail().name_hash()[i] = my_union_equal_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_union_equal); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimpleUnionStructEqual", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SimpleUnionStructEqual", false); -} - -const TypeObject* GetCompleteSimpleUnionStructEqualObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleUnionStructEqual", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_union_equal; - cst_my_union_equal.common().member_id(memberId++); - cst_my_union_equal.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_union_equal.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_union_equal.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_union_equal.common().member_flags().IS_OPTIONAL(false); - cst_my_union_equal.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_union_equal.common().member_flags().IS_KEY(false); - cst_my_union_equal.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_union_equal.common().member_type_id(*GetSimpleUnionIdentifier(true)); - - cst_my_union_equal.detail().name("my_union_equal"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_union_equal); - - - // Header - type_object->complete().struct_type().header().detail().type_name("SimpleUnionStructEqual"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimpleUnionStructEqual", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SimpleUnionStructEqual", true); -} - - - -const TypeIdentifier* GetSimpleUnionNamesStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("SimpleUnionNamesStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetSimpleUnionNamesStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("SimpleUnionNamesStruct", complete); -} - -const TypeObject* GetSimpleUnionNamesStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleUnionNamesStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteSimpleUnionNamesStructObject(); - } - //else - return GetMinimalSimpleUnionNamesStructObject(); -} - -const TypeObject* GetMinimalSimpleUnionNamesStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleUnionNamesStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_union; - mst_my_union.common().member_id(memberId++); - mst_my_union.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_union.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_union.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_union.common().member_flags().IS_OPTIONAL(false); - mst_my_union.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_union.common().member_flags().IS_KEY(false); - mst_my_union.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_union.common().member_type_id(*GetSimpleUnionNamesIdentifier(false)); - - MD5 my_union_hash("my_union"); - for(int i = 0; i < 4; ++i) - { - mst_my_union.detail().name_hash()[i] = my_union_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_union); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimpleUnionNamesStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SimpleUnionNamesStruct", false); -} - -const TypeObject* GetCompleteSimpleUnionNamesStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleUnionNamesStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_union; - cst_my_union.common().member_id(memberId++); - cst_my_union.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_union.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_union.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_union.common().member_flags().IS_OPTIONAL(false); - cst_my_union.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_union.common().member_flags().IS_KEY(false); - cst_my_union.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_union.common().member_type_id(*GetSimpleUnionNamesIdentifier(true)); - - cst_my_union.detail().name("my_union"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_union); - - - // Header - type_object->complete().struct_type().header().detail().type_name("SimpleUnionNamesStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimpleUnionNamesStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SimpleUnionNamesStruct", true); -} - - - -const TypeIdentifier* GetSimpleTypeUnionStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("SimpleTypeUnionStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetSimpleTypeUnionStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("SimpleTypeUnionStruct", complete); -} - -const TypeObject* GetSimpleTypeUnionStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleTypeUnionStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteSimpleTypeUnionStructObject(); - } - //else - return GetMinimalSimpleTypeUnionStructObject(); -} - -const TypeObject* GetMinimalSimpleTypeUnionStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleTypeUnionStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_union; - mst_my_union.common().member_id(memberId++); - mst_my_union.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_union.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_union.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_union.common().member_flags().IS_OPTIONAL(false); - mst_my_union.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_union.common().member_flags().IS_KEY(false); - mst_my_union.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_union.common().member_type_id(*GetSimpleTypeUnionIdentifier(false)); - - MD5 my_union_hash("my_union"); - for(int i = 0; i < 4; ++i) - { - mst_my_union.detail().name_hash()[i] = my_union_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_union); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimpleTypeUnionStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SimpleTypeUnionStruct", false); -} - -const TypeObject* GetCompleteSimpleTypeUnionStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleTypeUnionStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_union; - cst_my_union.common().member_id(memberId++); - cst_my_union.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_union.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_union.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_union.common().member_flags().IS_OPTIONAL(false); - cst_my_union.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_union.common().member_flags().IS_KEY(false); - cst_my_union.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_union.common().member_type_id(*GetSimpleTypeUnionIdentifier(true)); - - cst_my_union.detail().name("my_union"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_union); - - - // Header - type_object->complete().struct_type().header().detail().type_name("SimpleTypeUnionStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimpleTypeUnionStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SimpleTypeUnionStruct", true); -} - - - -const TypeIdentifier* GetSimpleBadUnionStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("SimpleBadUnionStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetSimpleBadUnionStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("SimpleBadUnionStruct", complete); -} - -const TypeObject* GetSimpleBadUnionStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleBadUnionStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteSimpleBadUnionStructObject(); - } - //else - return GetMinimalSimpleBadUnionStructObject(); -} - -const TypeObject* GetMinimalSimpleBadUnionStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleBadUnionStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_union; - mst_my_union.common().member_id(memberId++); - mst_my_union.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_union.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_union.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_union.common().member_flags().IS_OPTIONAL(false); - mst_my_union.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_union.common().member_flags().IS_KEY(false); - mst_my_union.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_union.common().member_type_id(*GetSimpleBadUnionIdentifier(false)); - - MD5 my_union_hash("my_union"); - for(int i = 0; i < 4; ++i) - { - mst_my_union.detail().name_hash()[i] = my_union_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_union); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimpleBadUnionStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SimpleBadUnionStruct", false); -} - -const TypeObject* GetCompleteSimpleBadUnionStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleBadUnionStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_union; - cst_my_union.common().member_id(memberId++); - cst_my_union.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_union.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_union.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_union.common().member_flags().IS_OPTIONAL(false); - cst_my_union.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_union.common().member_flags().IS_KEY(false); - cst_my_union.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_union.common().member_type_id(*GetSimpleBadUnionIdentifier(true)); - - cst_my_union.detail().name("my_union"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_union); - - - // Header - type_object->complete().struct_type().header().detail().type_name("SimpleBadUnionStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimpleBadUnionStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SimpleBadUnionStruct", true); -} - - - -const TypeIdentifier* GetSimplBadDiscUnionStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("SimplBadDiscUnionStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetSimplBadDiscUnionStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("SimplBadDiscUnionStruct", complete); -} - -const TypeObject* GetSimplBadDiscUnionStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimplBadDiscUnionStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteSimplBadDiscUnionStructObject(); - } - //else - return GetMinimalSimplBadDiscUnionStructObject(); -} - -const TypeObject* GetMinimalSimplBadDiscUnionStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimplBadDiscUnionStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_union; - mst_my_union.common().member_id(memberId++); - mst_my_union.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_union.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_union.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_union.common().member_flags().IS_OPTIONAL(false); - mst_my_union.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_union.common().member_flags().IS_KEY(false); - mst_my_union.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_union.common().member_type_id(*GetSimpleBadDiscUnionIdentifier(false)); - - MD5 my_union_hash("my_union"); - for(int i = 0; i < 4; ++i) - { - mst_my_union.detail().name_hash()[i] = my_union_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_union); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimplBadDiscUnionStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SimplBadDiscUnionStruct", false); -} - -const TypeObject* GetCompleteSimplBadDiscUnionStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimplBadDiscUnionStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_union; - cst_my_union.common().member_id(memberId++); - cst_my_union.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_union.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_union.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_union.common().member_flags().IS_OPTIONAL(false); - cst_my_union.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_union.common().member_flags().IS_KEY(false); - cst_my_union.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_union.common().member_type_id(*GetSimpleBadDiscUnionIdentifier(true)); - - cst_my_union.detail().name("my_union"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_union); - - - // Header - type_object->complete().struct_type().header().detail().type_name("SimplBadDiscUnionStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimplBadDiscUnionStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SimplBadDiscUnionStruct", true); -} diff --git a/test/unittest/xtypes/idl/TypesTypeObject.h b/test/unittest/xtypes/idl/TypesTypeObject.h deleted file mode 100644 index 2f615b62792..00000000000 --- a/test/unittest/xtypes/idl/TypesTypeObject.h +++ /dev/null @@ -1,394 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file TypesTypeObject.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifndef _FAST_DDS_GENERATED_TYPES_TYPE_OBJECT_H_ -#define _FAST_DDS_GENERATED_TYPES_TYPE_OBJECT_H_ - - -#include -#include - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif -#else -#define eProsima_user_DllExport -#endif - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(Types_SOURCE) -#define Types_DllAPI __declspec( dllexport ) -#else -#define Types_DllAPI __declspec( dllimport ) -#endif // Types_SOURCE -#else -#define Types_DllAPI -#endif -#else -#define Types_DllAPI -#endif // _WIN32 - -using namespace eprosima::fastrtps::types; - -eProsima_user_DllExport void registerTypesTypes(); - -eProsima_user_DllExport const TypeIdentifier* GetMyEnumIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMyEnumObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalMyEnumObject(); -eProsima_user_DllExport const TypeObject* GetCompleteMyEnumObject(); - -eProsima_user_DllExport const TypeIdentifier* GetMyBadEnumIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMyBadEnumObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalMyBadEnumObject(); -eProsima_user_DllExport const TypeObject* GetCompleteMyBadEnumObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetMyEnumStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMyEnumStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalMyEnumStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteMyEnumStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetMyBadEnumStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMyBadEnumStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalMyBadEnumStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteMyBadEnumStructObject(); - -eProsima_user_DllExport const TypeIdentifier* GetMyAliasEnumIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMyAliasEnumObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalMyAliasEnumObject(); -eProsima_user_DllExport const TypeObject* GetCompleteMyAliasEnumObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetMyAliasEnumStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMyAliasEnumStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalMyAliasEnumStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteMyAliasEnumStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetBasicStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetBasicStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalBasicStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteBasicStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetBasicNamesStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetBasicNamesStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalBasicNamesStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteBasicNamesStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetBasicBadStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetBasicBadStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalBasicBadStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteBasicBadStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetBasicWideStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetBasicWideStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalBasicWideStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteBasicWideStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetBadBasicWideStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetBadBasicWideStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalBadBasicWideStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteBadBasicWideStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetStringStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetStringStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalStringStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteStringStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetLargeStringStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetLargeStringStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalLargeStringStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteLargeStringStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetWStringStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetWStringStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalWStringStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteWStringStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetLargeWStringStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetLargeWStringStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalLargeWStringStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteLargeWStringStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetArrayStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetArrayStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalArrayStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteArrayStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetArrayStructEqualIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetArrayStructEqualObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalArrayStructEqualObject(); -eProsima_user_DllExport const TypeObject* GetCompleteArrayStructEqualObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetArrayBadStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetArrayBadStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalArrayBadStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteArrayBadStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetArrayDimensionsStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetArrayDimensionsStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalArrayDimensionsStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteArrayDimensionsStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetArraySizeStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetArraySizeStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalArraySizeStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteArraySizeStructObject(); - - - - - -eProsima_user_DllExport const TypeIdentifier* GetSequenceStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetSequenceStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalSequenceStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteSequenceStructObject(); - - - - - -eProsima_user_DllExport const TypeIdentifier* GetSequenceStructEqualIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetSequenceStructEqualObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalSequenceStructEqualObject(); -eProsima_user_DllExport const TypeObject* GetCompleteSequenceStructEqualObject(); - - - - - -eProsima_user_DllExport const TypeIdentifier* GetSequenceBadStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetSequenceBadStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalSequenceBadStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteSequenceBadStructObject(); - - - - - -eProsima_user_DllExport const TypeIdentifier* GetSequenceBoundsStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetSequenceBoundsStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalSequenceBoundsStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteSequenceBoundsStructObject(); - - - - - - - -eProsima_user_DllExport const TypeIdentifier* GetSequenceSequenceStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetSequenceSequenceStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalSequenceSequenceStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteSequenceSequenceStructObject(); - - - - - - - -eProsima_user_DllExport const TypeIdentifier* GetSequenceSequenceBoundsStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetSequenceSequenceBoundsStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalSequenceSequenceBoundsStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteSequenceSequenceBoundsStructObject(); - - - - - -eProsima_user_DllExport const TypeIdentifier* GetMapStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMapStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalMapStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteMapStructObject(); - - - - - -eProsima_user_DllExport const TypeIdentifier* GetMapStructEqualIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMapStructEqualObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalMapStructEqualObject(); -eProsima_user_DllExport const TypeObject* GetCompleteMapStructEqualObject(); - - - - - -eProsima_user_DllExport const TypeIdentifier* GetMapBadKeyStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMapBadKeyStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalMapBadKeyStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteMapBadKeyStructObject(); - - - - - -eProsima_user_DllExport const TypeIdentifier* GetMapBadElemStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMapBadElemStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalMapBadElemStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteMapBadElemStructObject(); - - - - - -eProsima_user_DllExport const TypeIdentifier* GetMapBoundsStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMapBoundsStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalMapBoundsStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteMapBoundsStructObject(); - - - - - - - -eProsima_user_DllExport const TypeIdentifier* GetMapMapStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMapMapStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalMapMapStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteMapMapStructObject(); - - - - - - - -eProsima_user_DllExport const TypeIdentifier* GetMapMapBoundsStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMapMapBoundsStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalMapMapBoundsStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteMapMapBoundsStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetSimpleUnionIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetSimpleUnionObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalSimpleUnionObject(); -eProsima_user_DllExport const TypeObject* GetCompleteSimpleUnionObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetSimpleUnionNamesIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetSimpleUnionNamesObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalSimpleUnionNamesObject(); -eProsima_user_DllExport const TypeObject* GetCompleteSimpleUnionNamesObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetSimpleTypeUnionIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetSimpleTypeUnionObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalSimpleTypeUnionObject(); -eProsima_user_DllExport const TypeObject* GetCompleteSimpleTypeUnionObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetSimpleBadUnionIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetSimpleBadUnionObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalSimpleBadUnionObject(); -eProsima_user_DllExport const TypeObject* GetCompleteSimpleBadUnionObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetSimpleBadDiscUnionIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetSimpleBadDiscUnionObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalSimpleBadDiscUnionObject(); -eProsima_user_DllExport const TypeObject* GetCompleteSimpleBadDiscUnionObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetSimpleUnionStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetSimpleUnionStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalSimpleUnionStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteSimpleUnionStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetSimpleUnionStructEqualIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetSimpleUnionStructEqualObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalSimpleUnionStructEqualObject(); -eProsima_user_DllExport const TypeObject* GetCompleteSimpleUnionStructEqualObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetSimpleUnionNamesStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetSimpleUnionNamesStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalSimpleUnionNamesStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteSimpleUnionNamesStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetSimpleTypeUnionStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetSimpleTypeUnionStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalSimpleTypeUnionStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteSimpleTypeUnionStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetSimpleBadUnionStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetSimpleBadUnionStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalSimpleBadUnionStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteSimpleBadUnionStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetSimplBadDiscUnionStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetSimplBadDiscUnionStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalSimplBadDiscUnionStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteSimplBadDiscUnionStructObject(); - - -#endif // _FAST_DDS_GENERATED_TYPES_TYPE_OBJECT_H_ \ No newline at end of file diff --git a/test/unittest/xtypes/idl/Typesv1.cxx b/test/unittest/xtypes/idl/Typesv1.cxx deleted file mode 100644 index 54b0d494ecc..00000000000 --- a/test/unittest/xtypes/idl/Typesv1.cxx +++ /dev/null @@ -1,8202 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file Types.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "Types.h" - -#if FASTCDR_VERSION_MAJOR == 1 - -#include "TypesTypeObject.h" - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - -namespace helper { namespace internal { - -enum class Size { - UInt8, - UInt16, - UInt32, - UInt64, -}; - -constexpr Size get_size(int s) { - return (s <= 8 ) ? Size::UInt8: - (s <= 16) ? Size::UInt16: - (s <= 32) ? Size::UInt32: Size::UInt64; -} - -template -struct FindTypeH; - -template<> -struct FindTypeH { - using type = std::uint8_t; -}; - -template<> -struct FindTypeH { - using type = std::uint16_t; -}; - -template<> -struct FindTypeH { - using type = std::uint32_t; -}; - -template<> -struct FindTypeH { - using type = std::uint64_t; -}; -} - -template -struct FindType { - using type = typename internal::FindTypeH::type; -}; -} - -#define SimpleUnionStruct_max_cdr_typesize 24ULL; -#define SequenceSequenceBoundsStruct_max_cdr_typesize 132ULL; - -#define MyAliasEnumStruct_max_cdr_typesize 8ULL; -#define ArrayBadStruct_max_cdr_typesize 6ULL; -#define MapBadKeyStruct_max_cdr_typesize 24ULL; -#define SimpleBadUnionStruct_max_cdr_typesize 24ULL; -#define MyEnumStruct_max_cdr_typesize 8ULL; - -#define ArrayStructEqual_max_cdr_typesize 12ULL; -#define LargeWStringStruct_max_cdr_typesize 167708ULL; - -#define WStringStruct_max_cdr_typesize 1028ULL; -#define SequenceStruct_max_cdr_typesize 16ULL; -#define SimpleTypeUnionStruct_max_cdr_typesize 24ULL; - -#define ArrayDimensionsStruct_max_cdr_typesize 20ULL; -#define SequenceSequenceStruct_max_cdr_typesize 48ULL; -#define MapBoundsStruct_max_cdr_typesize 40ULL; -#define SequenceStructEqual_max_cdr_typesize 16ULL; -#define MapStructEqual_max_cdr_typesize 24ULL; -#define BasicStruct_max_cdr_typesize 272ULL; -#define SequenceBoundsStruct_max_cdr_typesize 24ULL; -#define MapMapStruct_max_cdr_typesize 60ULL; -#define BasicWideStruct_max_cdr_typesize 536ULL; - -#define SimplBadDiscUnionStruct_max_cdr_typesize 24ULL; -#define MapStruct_max_cdr_typesize 24ULL; - -#define MyBadEnumStruct_max_cdr_typesize 8ULL; -#define SequenceBadStruct_max_cdr_typesize 10ULL; -#define SimpleUnionNamesStruct_max_cdr_typesize 24ULL; -#define LargeStringStruct_max_cdr_typesize 41934ULL; -#define ArrayStruct_max_cdr_typesize 12ULL; -#define BadBasicWideStruct_max_cdr_typesize 536ULL; -#define ArraySizeStruct_max_cdr_typesize 24ULL; - -#define MapBadElemStruct_max_cdr_typesize 40ULL; -#define SimpleUnionStructEqual_max_cdr_typesize 24ULL; -#define BasicBadStruct_max_cdr_typesize 272ULL; -#define BasicNamesStruct_max_cdr_typesize 272ULL; -#define StringStruct_max_cdr_typesize 264ULL; - -#define MapMapBoundsStruct_max_cdr_typesize 108ULL; - - - - -MyEnumStruct::MyEnumStruct() -{ - // MyEnum m_my_enum - m_my_enum = ::A; - - // Just to register all known types - registerTypesTypes(); -} - -MyEnumStruct::~MyEnumStruct() -{ -} - -MyEnumStruct::MyEnumStruct( - const MyEnumStruct& x) -{ - m_my_enum = x.m_my_enum; - -} - -MyEnumStruct::MyEnumStruct( - MyEnumStruct&& x) noexcept -{ - m_my_enum = x.m_my_enum; - -} - -MyEnumStruct& MyEnumStruct::operator =( - const MyEnumStruct& x) -{ - m_my_enum = x.m_my_enum; - - return *this; -} - -MyEnumStruct& MyEnumStruct::operator =( - MyEnumStruct&& x) noexcept -{ - m_my_enum = x.m_my_enum; - - return *this; -} - -bool MyEnumStruct::operator ==( - const MyEnumStruct& x) const -{ - return (m_my_enum == x.m_my_enum); -} - -bool MyEnumStruct::operator !=( - const MyEnumStruct& x) const -{ - return !(*this == x); -} - -size_t MyEnumStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return MyEnumStruct_max_cdr_typesize; -} - -size_t MyEnumStruct::getCdrSerializedSize( - const MyEnumStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - return current_alignment - initial_alignment; -} - - -void MyEnumStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << (uint32_t)m_my_enum; - -} - -void MyEnumStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - { - uint32_t enum_value = 0; - dcdr >> enum_value; - m_my_enum = (MyEnum)enum_value; - } - - -} - - -bool MyEnumStruct::isKeyDefined() -{ - return false; -} - -void MyEnumStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member my_enum - * @param _my_enum New value for member my_enum - */ -void MyEnumStruct::my_enum( - MyEnum _my_enum) -{ - m_my_enum = _my_enum; -} - -/*! - * @brief This function returns the value of member my_enum - * @return Value of member my_enum - */ -MyEnum MyEnumStruct::my_enum() const -{ - return m_my_enum; -} - -/*! - * @brief This function returns a reference to member my_enum - * @return Reference to member my_enum - */ -MyEnum& MyEnumStruct::my_enum() -{ - return m_my_enum; -} - - - - - -MyBadEnumStruct::MyBadEnumStruct() -{ - // MyBadEnum m_my_enum - m_my_enum = ::A1; - - // Just to register all known types - registerTypesTypes(); -} - -MyBadEnumStruct::~MyBadEnumStruct() -{ -} - -MyBadEnumStruct::MyBadEnumStruct( - const MyBadEnumStruct& x) -{ - m_my_enum = x.m_my_enum; - -} - -MyBadEnumStruct::MyBadEnumStruct( - MyBadEnumStruct&& x) noexcept -{ - m_my_enum = x.m_my_enum; - -} - -MyBadEnumStruct& MyBadEnumStruct::operator =( - const MyBadEnumStruct& x) -{ - m_my_enum = x.m_my_enum; - - return *this; -} - -MyBadEnumStruct& MyBadEnumStruct::operator =( - MyBadEnumStruct&& x) noexcept -{ - m_my_enum = x.m_my_enum; - - return *this; -} - -bool MyBadEnumStruct::operator ==( - const MyBadEnumStruct& x) const -{ - return (m_my_enum == x.m_my_enum); -} - -bool MyBadEnumStruct::operator !=( - const MyBadEnumStruct& x) const -{ - return !(*this == x); -} - -size_t MyBadEnumStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return MyBadEnumStruct_max_cdr_typesize; -} - -size_t MyBadEnumStruct::getCdrSerializedSize( - const MyBadEnumStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - return current_alignment - initial_alignment; -} - - -void MyBadEnumStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << (uint32_t)m_my_enum; - -} - -void MyBadEnumStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - { - uint32_t enum_value = 0; - dcdr >> enum_value; - m_my_enum = (MyBadEnum)enum_value; - } - - -} - - -bool MyBadEnumStruct::isKeyDefined() -{ - return false; -} - -void MyBadEnumStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member my_enum - * @param _my_enum New value for member my_enum - */ -void MyBadEnumStruct::my_enum( - MyBadEnum _my_enum) -{ - m_my_enum = _my_enum; -} - -/*! - * @brief This function returns the value of member my_enum - * @return Value of member my_enum - */ -MyBadEnum MyBadEnumStruct::my_enum() const -{ - return m_my_enum; -} - -/*! - * @brief This function returns a reference to member my_enum - * @return Reference to member my_enum - */ -MyBadEnum& MyBadEnumStruct::my_enum() -{ - return m_my_enum; -} - - - - - - -MyAliasEnumStruct::MyAliasEnumStruct() -{ - // MyAliasEnum m_my_enum - m_my_enum = ::A; - - // Just to register all known types - registerTypesTypes(); -} - -MyAliasEnumStruct::~MyAliasEnumStruct() -{ -} - -MyAliasEnumStruct::MyAliasEnumStruct( - const MyAliasEnumStruct& x) -{ - m_my_enum = x.m_my_enum; - -} - -MyAliasEnumStruct::MyAliasEnumStruct( - MyAliasEnumStruct&& x) noexcept -{ - m_my_enum = x.m_my_enum; - -} - -MyAliasEnumStruct& MyAliasEnumStruct::operator =( - const MyAliasEnumStruct& x) -{ - m_my_enum = x.m_my_enum; - - return *this; -} - -MyAliasEnumStruct& MyAliasEnumStruct::operator =( - MyAliasEnumStruct&& x) noexcept -{ - m_my_enum = x.m_my_enum; - - return *this; -} - -bool MyAliasEnumStruct::operator ==( - const MyAliasEnumStruct& x) const -{ - return (m_my_enum == x.m_my_enum); -} - -bool MyAliasEnumStruct::operator !=( - const MyAliasEnumStruct& x) const -{ - return !(*this == x); -} - -size_t MyAliasEnumStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return MyAliasEnumStruct_max_cdr_typesize; -} - -size_t MyAliasEnumStruct::getCdrSerializedSize( - const MyAliasEnumStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - return current_alignment - initial_alignment; -} - - -void MyAliasEnumStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << (uint32_t)m_my_enum; - -} - -void MyAliasEnumStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - { - uint32_t enum_value = 0; - dcdr >> enum_value; - m_my_enum = (MyAliasEnum)enum_value; - } - - -} - - -bool MyAliasEnumStruct::isKeyDefined() -{ - return false; -} - -void MyAliasEnumStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member my_enum - * @param _my_enum New value for member my_enum - */ -void MyAliasEnumStruct::my_enum( - MyAliasEnum _my_enum) -{ - m_my_enum = _my_enum; -} - -/*! - * @brief This function returns the value of member my_enum - * @return Value of member my_enum - */ -MyAliasEnum MyAliasEnumStruct::my_enum() const -{ - return m_my_enum; -} - -/*! - * @brief This function returns a reference to member my_enum - * @return Reference to member my_enum - */ -MyAliasEnum& MyAliasEnumStruct::my_enum() -{ - return m_my_enum; -} - - - - - -BasicStruct::BasicStruct() -{ - // boolean m_my_bool - m_my_bool = false; - // long m_my_int32 - m_my_int32 = 0; - // /type_d() m_my_string - - - // Just to register all known types - registerTypesTypes(); -} - -BasicStruct::~BasicStruct() -{ -} - -BasicStruct::BasicStruct( - const BasicStruct& x) -{ - m_my_bool = x.m_my_bool; - - - m_my_int32 = x.m_my_int32; - - - m_my_string = x.m_my_string; - -} - -BasicStruct::BasicStruct( - BasicStruct&& x) noexcept -{ - m_my_bool = x.m_my_bool; - - - m_my_int32 = x.m_my_int32; - - - m_my_string = std::move(x.m_my_string); - -} - -BasicStruct& BasicStruct::operator =( - const BasicStruct& x) -{ - m_my_bool = x.m_my_bool; - - - m_my_int32 = x.m_my_int32; - - - m_my_string = x.m_my_string; - - return *this; -} - -BasicStruct& BasicStruct::operator =( - BasicStruct&& x) noexcept -{ - m_my_bool = x.m_my_bool; - - - m_my_int32 = x.m_my_int32; - - - m_my_string = std::move(x.m_my_string); - - return *this; -} - -bool BasicStruct::operator ==( - const BasicStruct& x) const -{ - return (m_my_bool == x.m_my_bool && - m_my_int32 == x.m_my_int32 && - m_my_string == x.m_my_string); -} - -bool BasicStruct::operator !=( - const BasicStruct& x) const -{ - return !(*this == x); -} - -size_t BasicStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return BasicStruct_max_cdr_typesize; -} - -size_t BasicStruct::getCdrSerializedSize( - const BasicStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + data.my_string().size() + 1; - - - return current_alignment - initial_alignment; -} - - -void BasicStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_bool; - - scdr << m_my_int32; - - scdr << m_my_string.c_str(); - -} - -void BasicStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_bool; - - - - dcdr >> m_my_int32; - - - - dcdr >> m_my_string; - - -} - - -bool BasicStruct::isKeyDefined() -{ - return false; -} - -void BasicStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member my_bool - * @param _my_bool New value for member my_bool - */ -void BasicStruct::my_bool( - bool _my_bool) -{ - m_my_bool = _my_bool; -} - -/*! - * @brief This function returns the value of member my_bool - * @return Value of member my_bool - */ -bool BasicStruct::my_bool() const -{ - return m_my_bool; -} - -/*! - * @brief This function returns a reference to member my_bool - * @return Reference to member my_bool - */ -bool& BasicStruct::my_bool() -{ - return m_my_bool; -} - - -/*! - * @brief This function sets a value in member my_int32 - * @param _my_int32 New value for member my_int32 - */ -void BasicStruct::my_int32( - int32_t _my_int32) -{ - m_my_int32 = _my_int32; -} - -/*! - * @brief This function returns the value of member my_int32 - * @return Value of member my_int32 - */ -int32_t BasicStruct::my_int32() const -{ - return m_my_int32; -} - -/*! - * @brief This function returns a reference to member my_int32 - * @return Reference to member my_int32 - */ -int32_t& BasicStruct::my_int32() -{ - return m_my_int32; -} - - -/*! - * @brief This function copies the value in member my_string - * @param _my_string New value to be copied in member my_string - */ -void BasicStruct::my_string( - const std::string& _my_string) -{ - m_my_string = _my_string; -} - -/*! - * @brief This function moves the value in member my_string - * @param _my_string New value to be moved in member my_string - */ -void BasicStruct::my_string( - std::string&& _my_string) -{ - m_my_string = std::move(_my_string); -} - -/*! - * @brief This function returns a constant reference to member my_string - * @return Constant reference to member my_string - */ -const std::string& BasicStruct::my_string() const -{ - return m_my_string; -} - -/*! - * @brief This function returns a reference to member my_string - * @return Reference to member my_string - */ -std::string& BasicStruct::my_string() -{ - return m_my_string; -} - - - - - -BasicNamesStruct::BasicNamesStruct() -{ - // boolean m_my_bool_name - m_my_bool_name = false; - // long m_my_int32_name - m_my_int32_name = 0; - // /type_d() m_my_string_name - - - // Just to register all known types - registerTypesTypes(); -} - -BasicNamesStruct::~BasicNamesStruct() -{ -} - -BasicNamesStruct::BasicNamesStruct( - const BasicNamesStruct& x) -{ - m_my_bool_name = x.m_my_bool_name; - - - m_my_int32_name = x.m_my_int32_name; - - - m_my_string_name = x.m_my_string_name; - -} - -BasicNamesStruct::BasicNamesStruct( - BasicNamesStruct&& x) noexcept -{ - m_my_bool_name = x.m_my_bool_name; - - - m_my_int32_name = x.m_my_int32_name; - - - m_my_string_name = std::move(x.m_my_string_name); - -} - -BasicNamesStruct& BasicNamesStruct::operator =( - const BasicNamesStruct& x) -{ - m_my_bool_name = x.m_my_bool_name; - - - m_my_int32_name = x.m_my_int32_name; - - - m_my_string_name = x.m_my_string_name; - - return *this; -} - -BasicNamesStruct& BasicNamesStruct::operator =( - BasicNamesStruct&& x) noexcept -{ - m_my_bool_name = x.m_my_bool_name; - - - m_my_int32_name = x.m_my_int32_name; - - - m_my_string_name = std::move(x.m_my_string_name); - - return *this; -} - -bool BasicNamesStruct::operator ==( - const BasicNamesStruct& x) const -{ - return (m_my_bool_name == x.m_my_bool_name && - m_my_int32_name == x.m_my_int32_name && - m_my_string_name == x.m_my_string_name); -} - -bool BasicNamesStruct::operator !=( - const BasicNamesStruct& x) const -{ - return !(*this == x); -} - -size_t BasicNamesStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return BasicNamesStruct_max_cdr_typesize; -} - -size_t BasicNamesStruct::getCdrSerializedSize( - const BasicNamesStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + data.my_string_name().size() + 1; - - - return current_alignment - initial_alignment; -} - - -void BasicNamesStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_bool_name; - - scdr << m_my_int32_name; - - scdr << m_my_string_name.c_str(); - -} - -void BasicNamesStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_bool_name; - - - - dcdr >> m_my_int32_name; - - - - dcdr >> m_my_string_name; - - -} - - -bool BasicNamesStruct::isKeyDefined() -{ - return false; -} - -void BasicNamesStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member my_bool_name - * @param _my_bool_name New value for member my_bool_name - */ -void BasicNamesStruct::my_bool_name( - bool _my_bool_name) -{ - m_my_bool_name = _my_bool_name; -} - -/*! - * @brief This function returns the value of member my_bool_name - * @return Value of member my_bool_name - */ -bool BasicNamesStruct::my_bool_name() const -{ - return m_my_bool_name; -} - -/*! - * @brief This function returns a reference to member my_bool_name - * @return Reference to member my_bool_name - */ -bool& BasicNamesStruct::my_bool_name() -{ - return m_my_bool_name; -} - - -/*! - * @brief This function sets a value in member my_int32_name - * @param _my_int32_name New value for member my_int32_name - */ -void BasicNamesStruct::my_int32_name( - int32_t _my_int32_name) -{ - m_my_int32_name = _my_int32_name; -} - -/*! - * @brief This function returns the value of member my_int32_name - * @return Value of member my_int32_name - */ -int32_t BasicNamesStruct::my_int32_name() const -{ - return m_my_int32_name; -} - -/*! - * @brief This function returns a reference to member my_int32_name - * @return Reference to member my_int32_name - */ -int32_t& BasicNamesStruct::my_int32_name() -{ - return m_my_int32_name; -} - - -/*! - * @brief This function copies the value in member my_string_name - * @param _my_string_name New value to be copied in member my_string_name - */ -void BasicNamesStruct::my_string_name( - const std::string& _my_string_name) -{ - m_my_string_name = _my_string_name; -} - -/*! - * @brief This function moves the value in member my_string_name - * @param _my_string_name New value to be moved in member my_string_name - */ -void BasicNamesStruct::my_string_name( - std::string&& _my_string_name) -{ - m_my_string_name = std::move(_my_string_name); -} - -/*! - * @brief This function returns a constant reference to member my_string_name - * @return Constant reference to member my_string_name - */ -const std::string& BasicNamesStruct::my_string_name() const -{ - return m_my_string_name; -} - -/*! - * @brief This function returns a reference to member my_string_name - * @return Reference to member my_string_name - */ -std::string& BasicNamesStruct::my_string_name() -{ - return m_my_string_name; -} - - - - - -BasicBadStruct::BasicBadStruct() -{ - // octet m_my_bool - m_my_bool = 0; - // long m_my_int32 - m_my_int32 = 0; - // /type_d() m_my_string - - - // Just to register all known types - registerTypesTypes(); -} - -BasicBadStruct::~BasicBadStruct() -{ -} - -BasicBadStruct::BasicBadStruct( - const BasicBadStruct& x) -{ - m_my_bool = x.m_my_bool; - - - m_my_int32 = x.m_my_int32; - - - m_my_string = x.m_my_string; - -} - -BasicBadStruct::BasicBadStruct( - BasicBadStruct&& x) noexcept -{ - m_my_bool = x.m_my_bool; - - - m_my_int32 = x.m_my_int32; - - - m_my_string = std::move(x.m_my_string); - -} - -BasicBadStruct& BasicBadStruct::operator =( - const BasicBadStruct& x) -{ - m_my_bool = x.m_my_bool; - - - m_my_int32 = x.m_my_int32; - - - m_my_string = x.m_my_string; - - return *this; -} - -BasicBadStruct& BasicBadStruct::operator =( - BasicBadStruct&& x) noexcept -{ - m_my_bool = x.m_my_bool; - - - m_my_int32 = x.m_my_int32; - - - m_my_string = std::move(x.m_my_string); - - return *this; -} - -bool BasicBadStruct::operator ==( - const BasicBadStruct& x) const -{ - return (m_my_bool == x.m_my_bool && - m_my_int32 == x.m_my_int32 && - m_my_string == x.m_my_string); -} - -bool BasicBadStruct::operator !=( - const BasicBadStruct& x) const -{ - return !(*this == x); -} - -size_t BasicBadStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return BasicBadStruct_max_cdr_typesize; -} - -size_t BasicBadStruct::getCdrSerializedSize( - const BasicBadStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + data.my_string().size() + 1; - - - return current_alignment - initial_alignment; -} - - -void BasicBadStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_bool; - - scdr << m_my_int32; - - scdr << m_my_string.c_str(); - -} - -void BasicBadStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_bool; - - - - dcdr >> m_my_int32; - - - - dcdr >> m_my_string; - - -} - - -bool BasicBadStruct::isKeyDefined() -{ - return false; -} - -void BasicBadStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member my_bool - * @param _my_bool New value for member my_bool - */ -void BasicBadStruct::my_bool( - uint8_t _my_bool) -{ - m_my_bool = _my_bool; -} - -/*! - * @brief This function returns the value of member my_bool - * @return Value of member my_bool - */ -uint8_t BasicBadStruct::my_bool() const -{ - return m_my_bool; -} - -/*! - * @brief This function returns a reference to member my_bool - * @return Reference to member my_bool - */ -uint8_t& BasicBadStruct::my_bool() -{ - return m_my_bool; -} - - -/*! - * @brief This function sets a value in member my_int32 - * @param _my_int32 New value for member my_int32 - */ -void BasicBadStruct::my_int32( - int32_t _my_int32) -{ - m_my_int32 = _my_int32; -} - -/*! - * @brief This function returns the value of member my_int32 - * @return Value of member my_int32 - */ -int32_t BasicBadStruct::my_int32() const -{ - return m_my_int32; -} - -/*! - * @brief This function returns a reference to member my_int32 - * @return Reference to member my_int32 - */ -int32_t& BasicBadStruct::my_int32() -{ - return m_my_int32; -} - - -/*! - * @brief This function copies the value in member my_string - * @param _my_string New value to be copied in member my_string - */ -void BasicBadStruct::my_string( - const std::string& _my_string) -{ - m_my_string = _my_string; -} - -/*! - * @brief This function moves the value in member my_string - * @param _my_string New value to be moved in member my_string - */ -void BasicBadStruct::my_string( - std::string&& _my_string) -{ - m_my_string = std::move(_my_string); -} - -/*! - * @brief This function returns a constant reference to member my_string - * @return Constant reference to member my_string - */ -const std::string& BasicBadStruct::my_string() const -{ - return m_my_string; -} - -/*! - * @brief This function returns a reference to member my_string - * @return Reference to member my_string - */ -std::string& BasicBadStruct::my_string() -{ - return m_my_string; -} - - - - - -BasicWideStruct::BasicWideStruct() -{ - // boolean m_my_bool - m_my_bool = false; - // long m_my_int32 - m_my_int32 = 0; - // /type_d() m_my_string - - // long m_new_int32 - m_new_int32 = 0; - // /type_d() m_new_string - - - // Just to register all known types - registerTypesTypes(); -} - -BasicWideStruct::~BasicWideStruct() -{ -} - -BasicWideStruct::BasicWideStruct( - const BasicWideStruct& x) -{ - m_my_bool = x.m_my_bool; - - - m_my_int32 = x.m_my_int32; - - - m_my_string = x.m_my_string; - - - m_new_int32 = x.m_new_int32; - - - m_new_string = x.m_new_string; - -} - -BasicWideStruct::BasicWideStruct( - BasicWideStruct&& x) noexcept -{ - m_my_bool = x.m_my_bool; - - - m_my_int32 = x.m_my_int32; - - - m_my_string = std::move(x.m_my_string); - - - m_new_int32 = x.m_new_int32; - - - m_new_string = std::move(x.m_new_string); - -} - -BasicWideStruct& BasicWideStruct::operator =( - const BasicWideStruct& x) -{ - m_my_bool = x.m_my_bool; - - - m_my_int32 = x.m_my_int32; - - - m_my_string = x.m_my_string; - - - m_new_int32 = x.m_new_int32; - - - m_new_string = x.m_new_string; - - return *this; -} - -BasicWideStruct& BasicWideStruct::operator =( - BasicWideStruct&& x) noexcept -{ - m_my_bool = x.m_my_bool; - - - m_my_int32 = x.m_my_int32; - - - m_my_string = std::move(x.m_my_string); - - - m_new_int32 = x.m_new_int32; - - - m_new_string = std::move(x.m_new_string); - - return *this; -} - -bool BasicWideStruct::operator ==( - const BasicWideStruct& x) const -{ - return (m_my_bool == x.m_my_bool && - m_my_int32 == x.m_my_int32 && - m_my_string == x.m_my_string && - m_new_int32 == x.m_new_int32 && - m_new_string == x.m_new_string); -} - -bool BasicWideStruct::operator !=( - const BasicWideStruct& x) const -{ - return !(*this == x); -} - -size_t BasicWideStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return BasicWideStruct_max_cdr_typesize; -} - -size_t BasicWideStruct::getCdrSerializedSize( - const BasicWideStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + data.my_string().size() + 1; - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + data.new_string().size() + 1; - - - return current_alignment - initial_alignment; -} - - -void BasicWideStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_bool; - - scdr << m_my_int32; - - scdr << m_my_string.c_str(); - - scdr << m_new_int32; - - scdr << m_new_string.c_str(); - -} - -void BasicWideStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_bool; - - - - dcdr >> m_my_int32; - - - - dcdr >> m_my_string; - - - - dcdr >> m_new_int32; - - - - dcdr >> m_new_string; - - -} - - -bool BasicWideStruct::isKeyDefined() -{ - return false; -} - -void BasicWideStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member my_bool - * @param _my_bool New value for member my_bool - */ -void BasicWideStruct::my_bool( - bool _my_bool) -{ - m_my_bool = _my_bool; -} - -/*! - * @brief This function returns the value of member my_bool - * @return Value of member my_bool - */ -bool BasicWideStruct::my_bool() const -{ - return m_my_bool; -} - -/*! - * @brief This function returns a reference to member my_bool - * @return Reference to member my_bool - */ -bool& BasicWideStruct::my_bool() -{ - return m_my_bool; -} - - -/*! - * @brief This function sets a value in member my_int32 - * @param _my_int32 New value for member my_int32 - */ -void BasicWideStruct::my_int32( - int32_t _my_int32) -{ - m_my_int32 = _my_int32; -} - -/*! - * @brief This function returns the value of member my_int32 - * @return Value of member my_int32 - */ -int32_t BasicWideStruct::my_int32() const -{ - return m_my_int32; -} - -/*! - * @brief This function returns a reference to member my_int32 - * @return Reference to member my_int32 - */ -int32_t& BasicWideStruct::my_int32() -{ - return m_my_int32; -} - - -/*! - * @brief This function copies the value in member my_string - * @param _my_string New value to be copied in member my_string - */ -void BasicWideStruct::my_string( - const std::string& _my_string) -{ - m_my_string = _my_string; -} - -/*! - * @brief This function moves the value in member my_string - * @param _my_string New value to be moved in member my_string - */ -void BasicWideStruct::my_string( - std::string&& _my_string) -{ - m_my_string = std::move(_my_string); -} - -/*! - * @brief This function returns a constant reference to member my_string - * @return Constant reference to member my_string - */ -const std::string& BasicWideStruct::my_string() const -{ - return m_my_string; -} - -/*! - * @brief This function returns a reference to member my_string - * @return Reference to member my_string - */ -std::string& BasicWideStruct::my_string() -{ - return m_my_string; -} - - -/*! - * @brief This function sets a value in member new_int32 - * @param _new_int32 New value for member new_int32 - */ -void BasicWideStruct::new_int32( - int32_t _new_int32) -{ - m_new_int32 = _new_int32; -} - -/*! - * @brief This function returns the value of member new_int32 - * @return Value of member new_int32 - */ -int32_t BasicWideStruct::new_int32() const -{ - return m_new_int32; -} - -/*! - * @brief This function returns a reference to member new_int32 - * @return Reference to member new_int32 - */ -int32_t& BasicWideStruct::new_int32() -{ - return m_new_int32; -} - - -/*! - * @brief This function copies the value in member new_string - * @param _new_string New value to be copied in member new_string - */ -void BasicWideStruct::new_string( - const std::string& _new_string) -{ - m_new_string = _new_string; -} - -/*! - * @brief This function moves the value in member new_string - * @param _new_string New value to be moved in member new_string - */ -void BasicWideStruct::new_string( - std::string&& _new_string) -{ - m_new_string = std::move(_new_string); -} - -/*! - * @brief This function returns a constant reference to member new_string - * @return Constant reference to member new_string - */ -const std::string& BasicWideStruct::new_string() const -{ - return m_new_string; -} - -/*! - * @brief This function returns a reference to member new_string - * @return Reference to member new_string - */ -std::string& BasicWideStruct::new_string() -{ - return m_new_string; -} - - - - - -BadBasicWideStruct::BadBasicWideStruct() -{ - // long m_new_int32 - m_new_int32 = 0; - // /type_d() m_new_string - - // boolean m_my_bool - m_my_bool = false; - // long m_my_int32 - m_my_int32 = 0; - // /type_d() m_my_string - - - // Just to register all known types - registerTypesTypes(); -} - -BadBasicWideStruct::~BadBasicWideStruct() -{ -} - -BadBasicWideStruct::BadBasicWideStruct( - const BadBasicWideStruct& x) -{ - m_new_int32 = x.m_new_int32; - - - m_new_string = x.m_new_string; - - - m_my_bool = x.m_my_bool; - - - m_my_int32 = x.m_my_int32; - - - m_my_string = x.m_my_string; - -} - -BadBasicWideStruct::BadBasicWideStruct( - BadBasicWideStruct&& x) noexcept -{ - m_new_int32 = x.m_new_int32; - - - m_new_string = std::move(x.m_new_string); - - - m_my_bool = x.m_my_bool; - - - m_my_int32 = x.m_my_int32; - - - m_my_string = std::move(x.m_my_string); - -} - -BadBasicWideStruct& BadBasicWideStruct::operator =( - const BadBasicWideStruct& x) -{ - m_new_int32 = x.m_new_int32; - - - m_new_string = x.m_new_string; - - - m_my_bool = x.m_my_bool; - - - m_my_int32 = x.m_my_int32; - - - m_my_string = x.m_my_string; - - return *this; -} - -BadBasicWideStruct& BadBasicWideStruct::operator =( - BadBasicWideStruct&& x) noexcept -{ - m_new_int32 = x.m_new_int32; - - - m_new_string = std::move(x.m_new_string); - - - m_my_bool = x.m_my_bool; - - - m_my_int32 = x.m_my_int32; - - - m_my_string = std::move(x.m_my_string); - - return *this; -} - -bool BadBasicWideStruct::operator ==( - const BadBasicWideStruct& x) const -{ - return (m_new_int32 == x.m_new_int32 && - m_new_string == x.m_new_string && - m_my_bool == x.m_my_bool && - m_my_int32 == x.m_my_int32 && - m_my_string == x.m_my_string); -} - -bool BadBasicWideStruct::operator !=( - const BadBasicWideStruct& x) const -{ - return !(*this == x); -} - -size_t BadBasicWideStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return BadBasicWideStruct_max_cdr_typesize; -} - -size_t BadBasicWideStruct::getCdrSerializedSize( - const BadBasicWideStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + data.new_string().size() + 1; - - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + data.my_string().size() + 1; - - - return current_alignment - initial_alignment; -} - - -void BadBasicWideStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_new_int32; - - scdr << m_new_string.c_str(); - - scdr << m_my_bool; - - scdr << m_my_int32; - - scdr << m_my_string.c_str(); - -} - -void BadBasicWideStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_new_int32; - - - - dcdr >> m_new_string; - - - - dcdr >> m_my_bool; - - - - dcdr >> m_my_int32; - - - - dcdr >> m_my_string; - - -} - - -bool BadBasicWideStruct::isKeyDefined() -{ - return false; -} - -void BadBasicWideStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member new_int32 - * @param _new_int32 New value for member new_int32 - */ -void BadBasicWideStruct::new_int32( - int32_t _new_int32) -{ - m_new_int32 = _new_int32; -} - -/*! - * @brief This function returns the value of member new_int32 - * @return Value of member new_int32 - */ -int32_t BadBasicWideStruct::new_int32() const -{ - return m_new_int32; -} - -/*! - * @brief This function returns a reference to member new_int32 - * @return Reference to member new_int32 - */ -int32_t& BadBasicWideStruct::new_int32() -{ - return m_new_int32; -} - - -/*! - * @brief This function copies the value in member new_string - * @param _new_string New value to be copied in member new_string - */ -void BadBasicWideStruct::new_string( - const std::string& _new_string) -{ - m_new_string = _new_string; -} - -/*! - * @brief This function moves the value in member new_string - * @param _new_string New value to be moved in member new_string - */ -void BadBasicWideStruct::new_string( - std::string&& _new_string) -{ - m_new_string = std::move(_new_string); -} - -/*! - * @brief This function returns a constant reference to member new_string - * @return Constant reference to member new_string - */ -const std::string& BadBasicWideStruct::new_string() const -{ - return m_new_string; -} - -/*! - * @brief This function returns a reference to member new_string - * @return Reference to member new_string - */ -std::string& BadBasicWideStruct::new_string() -{ - return m_new_string; -} - - -/*! - * @brief This function sets a value in member my_bool - * @param _my_bool New value for member my_bool - */ -void BadBasicWideStruct::my_bool( - bool _my_bool) -{ - m_my_bool = _my_bool; -} - -/*! - * @brief This function returns the value of member my_bool - * @return Value of member my_bool - */ -bool BadBasicWideStruct::my_bool() const -{ - return m_my_bool; -} - -/*! - * @brief This function returns a reference to member my_bool - * @return Reference to member my_bool - */ -bool& BadBasicWideStruct::my_bool() -{ - return m_my_bool; -} - - -/*! - * @brief This function sets a value in member my_int32 - * @param _my_int32 New value for member my_int32 - */ -void BadBasicWideStruct::my_int32( - int32_t _my_int32) -{ - m_my_int32 = _my_int32; -} - -/*! - * @brief This function returns the value of member my_int32 - * @return Value of member my_int32 - */ -int32_t BadBasicWideStruct::my_int32() const -{ - return m_my_int32; -} - -/*! - * @brief This function returns a reference to member my_int32 - * @return Reference to member my_int32 - */ -int32_t& BadBasicWideStruct::my_int32() -{ - return m_my_int32; -} - - -/*! - * @brief This function copies the value in member my_string - * @param _my_string New value to be copied in member my_string - */ -void BadBasicWideStruct::my_string( - const std::string& _my_string) -{ - m_my_string = _my_string; -} - -/*! - * @brief This function moves the value in member my_string - * @param _my_string New value to be moved in member my_string - */ -void BadBasicWideStruct::my_string( - std::string&& _my_string) -{ - m_my_string = std::move(_my_string); -} - -/*! - * @brief This function returns a constant reference to member my_string - * @return Constant reference to member my_string - */ -const std::string& BadBasicWideStruct::my_string() const -{ - return m_my_string; -} - -/*! - * @brief This function returns a reference to member my_string - * @return Reference to member my_string - */ -std::string& BadBasicWideStruct::my_string() -{ - return m_my_string; -} - - - - - -StringStruct::StringStruct() -{ - // /type_d() m_my_string - - - // Just to register all known types - registerTypesTypes(); -} - -StringStruct::~StringStruct() -{ -} - -StringStruct::StringStruct( - const StringStruct& x) -{ - m_my_string = x.m_my_string; - -} - -StringStruct::StringStruct( - StringStruct&& x) noexcept -{ - m_my_string = std::move(x.m_my_string); - -} - -StringStruct& StringStruct::operator =( - const StringStruct& x) -{ - m_my_string = x.m_my_string; - - return *this; -} - -StringStruct& StringStruct::operator =( - StringStruct&& x) noexcept -{ - m_my_string = std::move(x.m_my_string); - - return *this; -} - -bool StringStruct::operator ==( - const StringStruct& x) const -{ - return (m_my_string == x.m_my_string); -} - -bool StringStruct::operator !=( - const StringStruct& x) const -{ - return !(*this == x); -} - -size_t StringStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return StringStruct_max_cdr_typesize; -} - -size_t StringStruct::getCdrSerializedSize( - const StringStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + data.my_string().size() + 1; - - - return current_alignment - initial_alignment; -} - - -void StringStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_string.c_str(); - -} - -void StringStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_string; - - -} - - -bool StringStruct::isKeyDefined() -{ - return false; -} - -void StringStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_string - * @param _my_string New value to be copied in member my_string - */ -void StringStruct::my_string( - const std::string& _my_string) -{ - m_my_string = _my_string; -} - -/*! - * @brief This function moves the value in member my_string - * @param _my_string New value to be moved in member my_string - */ -void StringStruct::my_string( - std::string&& _my_string) -{ - m_my_string = std::move(_my_string); -} - -/*! - * @brief This function returns a constant reference to member my_string - * @return Constant reference to member my_string - */ -const std::string& StringStruct::my_string() const -{ - return m_my_string; -} - -/*! - * @brief This function returns a reference to member my_string - * @return Reference to member my_string - */ -std::string& StringStruct::my_string() -{ - return m_my_string; -} - - - - - -LargeStringStruct::LargeStringStruct() -{ - // /type_d() m_my_large_string - - - // Just to register all known types - registerTypesTypes(); -} - -LargeStringStruct::~LargeStringStruct() -{ -} - -LargeStringStruct::LargeStringStruct( - const LargeStringStruct& x) -{ - m_my_large_string = x.m_my_large_string; - -} - -LargeStringStruct::LargeStringStruct( - LargeStringStruct&& x) noexcept -{ - m_my_large_string = std::move(x.m_my_large_string); - -} - -LargeStringStruct& LargeStringStruct::operator =( - const LargeStringStruct& x) -{ - m_my_large_string = x.m_my_large_string; - - return *this; -} - -LargeStringStruct& LargeStringStruct::operator =( - LargeStringStruct&& x) noexcept -{ - m_my_large_string = std::move(x.m_my_large_string); - - return *this; -} - -bool LargeStringStruct::operator ==( - const LargeStringStruct& x) const -{ - return (m_my_large_string == x.m_my_large_string); -} - -bool LargeStringStruct::operator !=( - const LargeStringStruct& x) const -{ - return !(*this == x); -} - -size_t LargeStringStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return LargeStringStruct_max_cdr_typesize; -} - -size_t LargeStringStruct::getCdrSerializedSize( - const LargeStringStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + data.my_large_string().size() + 1; - - - return current_alignment - initial_alignment; -} - - -void LargeStringStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_large_string.c_str(); - -} - -void LargeStringStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - { - std::string aux; - dcdr >> aux; - m_my_large_string = aux.c_str(); - } - - -} - - -bool LargeStringStruct::isKeyDefined() -{ - return false; -} - -void LargeStringStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_large_string - * @param _my_large_string New value to be copied in member my_large_string - */ -void LargeStringStruct::my_large_string( - const eprosima::fastrtps::fixed_string<41925>& _my_large_string) -{ - m_my_large_string = _my_large_string; -} - -/*! - * @brief This function moves the value in member my_large_string - * @param _my_large_string New value to be moved in member my_large_string - */ -void LargeStringStruct::my_large_string( - eprosima::fastrtps::fixed_string<41925>&& _my_large_string) -{ - m_my_large_string = std::move(_my_large_string); -} - -/*! - * @brief This function returns a constant reference to member my_large_string - * @return Constant reference to member my_large_string - */ -const eprosima::fastrtps::fixed_string<41925>& LargeStringStruct::my_large_string() const -{ - return m_my_large_string; -} - -/*! - * @brief This function returns a reference to member my_large_string - * @return Reference to member my_large_string - */ -eprosima::fastrtps::fixed_string<41925>& LargeStringStruct::my_large_string() -{ - return m_my_large_string; -} - - - - - -WStringStruct::WStringStruct() -{ - // /type_15() m_my_wstring - - - // Just to register all known types - registerTypesTypes(); -} - -WStringStruct::~WStringStruct() -{ -} - -WStringStruct::WStringStruct( - const WStringStruct& x) -{ - m_my_wstring = x.m_my_wstring; - -} - -WStringStruct::WStringStruct( - WStringStruct&& x) noexcept -{ - m_my_wstring = std::move(x.m_my_wstring); - -} - -WStringStruct& WStringStruct::operator =( - const WStringStruct& x) -{ - m_my_wstring = x.m_my_wstring; - - return *this; -} - -WStringStruct& WStringStruct::operator =( - WStringStruct&& x) noexcept -{ - m_my_wstring = std::move(x.m_my_wstring); - - return *this; -} - -bool WStringStruct::operator ==( - const WStringStruct& x) const -{ - return (m_my_wstring == x.m_my_wstring); -} - -bool WStringStruct::operator !=( - const WStringStruct& x) const -{ - return !(*this == x); -} - -size_t WStringStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return WStringStruct_max_cdr_typesize; -} - -size_t WStringStruct::getCdrSerializedSize( - const WStringStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + (data.my_wstring().size()) * 4; // 32 bits - - - return current_alignment - initial_alignment; -} - - -void WStringStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_wstring; - -} - -void WStringStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_wstring; - - -} - - -bool WStringStruct::isKeyDefined() -{ - return false; -} - -void WStringStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_wstring - * @param _my_wstring New value to be copied in member my_wstring - */ -void WStringStruct::my_wstring( - const std::wstring& _my_wstring) -{ - m_my_wstring = _my_wstring; -} - -/*! - * @brief This function moves the value in member my_wstring - * @param _my_wstring New value to be moved in member my_wstring - */ -void WStringStruct::my_wstring( - std::wstring&& _my_wstring) -{ - m_my_wstring = std::move(_my_wstring); -} - -/*! - * @brief This function returns a constant reference to member my_wstring - * @return Constant reference to member my_wstring - */ -const std::wstring& WStringStruct::my_wstring() const -{ - return m_my_wstring; -} - -/*! - * @brief This function returns a reference to member my_wstring - * @return Reference to member my_wstring - */ -std::wstring& WStringStruct::my_wstring() -{ - return m_my_wstring; -} - - - - - -LargeWStringStruct::LargeWStringStruct() -{ - // /type_15() m_my_large_wstring - - - // Just to register all known types - registerTypesTypes(); -} - -LargeWStringStruct::~LargeWStringStruct() -{ -} - -LargeWStringStruct::LargeWStringStruct( - const LargeWStringStruct& x) -{ - m_my_large_wstring = x.m_my_large_wstring; - -} - -LargeWStringStruct::LargeWStringStruct( - LargeWStringStruct&& x) noexcept -{ - m_my_large_wstring = std::move(x.m_my_large_wstring); - -} - -LargeWStringStruct& LargeWStringStruct::operator =( - const LargeWStringStruct& x) -{ - m_my_large_wstring = x.m_my_large_wstring; - - return *this; -} - -LargeWStringStruct& LargeWStringStruct::operator =( - LargeWStringStruct&& x) noexcept -{ - m_my_large_wstring = std::move(x.m_my_large_wstring); - - return *this; -} - -bool LargeWStringStruct::operator ==( - const LargeWStringStruct& x) const -{ - return (m_my_large_wstring == x.m_my_large_wstring); -} - -bool LargeWStringStruct::operator !=( - const LargeWStringStruct& x) const -{ - return !(*this == x); -} - -size_t LargeWStringStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return LargeWStringStruct_max_cdr_typesize; -} - -size_t LargeWStringStruct::getCdrSerializedSize( - const LargeWStringStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + (data.my_large_wstring().size()) * 4; // 32 bits - - - return current_alignment - initial_alignment; -} - - -void LargeWStringStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_large_wstring; - -} - -void LargeWStringStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_large_wstring; - - -} - - -bool LargeWStringStruct::isKeyDefined() -{ - return false; -} - -void LargeWStringStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_large_wstring - * @param _my_large_wstring New value to be copied in member my_large_wstring - */ -void LargeWStringStruct::my_large_wstring( - const std::wstring& _my_large_wstring) -{ - m_my_large_wstring = _my_large_wstring; -} - -/*! - * @brief This function moves the value in member my_large_wstring - * @param _my_large_wstring New value to be moved in member my_large_wstring - */ -void LargeWStringStruct::my_large_wstring( - std::wstring&& _my_large_wstring) -{ - m_my_large_wstring = std::move(_my_large_wstring); -} - -/*! - * @brief This function returns a constant reference to member my_large_wstring - * @return Constant reference to member my_large_wstring - */ -const std::wstring& LargeWStringStruct::my_large_wstring() const -{ - return m_my_large_wstring; -} - -/*! - * @brief This function returns a reference to member my_large_wstring - * @return Reference to member my_large_wstring - */ -std::wstring& LargeWStringStruct::my_large_wstring() -{ - return m_my_large_wstring; -} - - - - - -ArrayStruct::ArrayStruct() -{ - // long m_my_array - memset(&m_my_array, 0, ((2)) * 4); - - // Just to register all known types - registerTypesTypes(); -} - -ArrayStruct::~ArrayStruct() -{ -} - -ArrayStruct::ArrayStruct( - const ArrayStruct& x) -{ - m_my_array = x.m_my_array; - -} - -ArrayStruct::ArrayStruct( - ArrayStruct&& x) noexcept -{ - m_my_array = std::move(x.m_my_array); - -} - -ArrayStruct& ArrayStruct::operator =( - const ArrayStruct& x) -{ - m_my_array = x.m_my_array; - - return *this; -} - -ArrayStruct& ArrayStruct::operator =( - ArrayStruct&& x) noexcept -{ - m_my_array = std::move(x.m_my_array); - - return *this; -} - -bool ArrayStruct::operator ==( - const ArrayStruct& x) const -{ - return (m_my_array == x.m_my_array); -} - -bool ArrayStruct::operator !=( - const ArrayStruct& x) const -{ - return !(*this == x); -} - -size_t ArrayStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return ArrayStruct_max_cdr_typesize; -} - -size_t ArrayStruct::getCdrSerializedSize( - const ArrayStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += (((2)) * 4) + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - - return current_alignment - initial_alignment; -} - - -void ArrayStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_array; - - -} - -void ArrayStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_array; - - -} - - -bool ArrayStruct::isKeyDefined() -{ - return false; -} - -void ArrayStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_array - * @param _my_array New value to be copied in member my_array - */ -void ArrayStruct::my_array( - const std::array& _my_array) -{ - m_my_array = _my_array; -} - -/*! - * @brief This function moves the value in member my_array - * @param _my_array New value to be moved in member my_array - */ -void ArrayStruct::my_array( - std::array&& _my_array) -{ - m_my_array = std::move(_my_array); -} - -/*! - * @brief This function returns a constant reference to member my_array - * @return Constant reference to member my_array - */ -const std::array& ArrayStruct::my_array() const -{ - return m_my_array; -} - -/*! - * @brief This function returns a reference to member my_array - * @return Reference to member my_array - */ -std::array& ArrayStruct::my_array() -{ - return m_my_array; -} - - - - - -ArrayStructEqual::ArrayStructEqual() -{ - // long m_my_array_equal - memset(&m_my_array_equal, 0, ((2)) * 4); - - // Just to register all known types - registerTypesTypes(); -} - -ArrayStructEqual::~ArrayStructEqual() -{ -} - -ArrayStructEqual::ArrayStructEqual( - const ArrayStructEqual& x) -{ - m_my_array_equal = x.m_my_array_equal; - -} - -ArrayStructEqual::ArrayStructEqual( - ArrayStructEqual&& x) noexcept -{ - m_my_array_equal = std::move(x.m_my_array_equal); - -} - -ArrayStructEqual& ArrayStructEqual::operator =( - const ArrayStructEqual& x) -{ - m_my_array_equal = x.m_my_array_equal; - - return *this; -} - -ArrayStructEqual& ArrayStructEqual::operator =( - ArrayStructEqual&& x) noexcept -{ - m_my_array_equal = std::move(x.m_my_array_equal); - - return *this; -} - -bool ArrayStructEqual::operator ==( - const ArrayStructEqual& x) const -{ - return (m_my_array_equal == x.m_my_array_equal); -} - -bool ArrayStructEqual::operator !=( - const ArrayStructEqual& x) const -{ - return !(*this == x); -} - -size_t ArrayStructEqual::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return ArrayStructEqual_max_cdr_typesize; -} - -size_t ArrayStructEqual::getCdrSerializedSize( - const ArrayStructEqual& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += (((2)) * 4) + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - - return current_alignment - initial_alignment; -} - - -void ArrayStructEqual::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_array_equal; - - -} - -void ArrayStructEqual::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_array_equal; - - -} - - -bool ArrayStructEqual::isKeyDefined() -{ - return false; -} - -void ArrayStructEqual::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_array_equal - * @param _my_array_equal New value to be copied in member my_array_equal - */ -void ArrayStructEqual::my_array_equal( - const std::array& _my_array_equal) -{ - m_my_array_equal = _my_array_equal; -} - -/*! - * @brief This function moves the value in member my_array_equal - * @param _my_array_equal New value to be moved in member my_array_equal - */ -void ArrayStructEqual::my_array_equal( - std::array&& _my_array_equal) -{ - m_my_array_equal = std::move(_my_array_equal); -} - -/*! - * @brief This function returns a constant reference to member my_array_equal - * @return Constant reference to member my_array_equal - */ -const std::array& ArrayStructEqual::my_array_equal() const -{ - return m_my_array_equal; -} - -/*! - * @brief This function returns a reference to member my_array_equal - * @return Reference to member my_array_equal - */ -std::array& ArrayStructEqual::my_array_equal() -{ - return m_my_array_equal; -} - - - - - -ArrayBadStruct::ArrayBadStruct() -{ - // octet m_my_array - memset(&m_my_array, 0, ((2)) * 1); - - // Just to register all known types - registerTypesTypes(); -} - -ArrayBadStruct::~ArrayBadStruct() -{ -} - -ArrayBadStruct::ArrayBadStruct( - const ArrayBadStruct& x) -{ - m_my_array = x.m_my_array; - -} - -ArrayBadStruct::ArrayBadStruct( - ArrayBadStruct&& x) noexcept -{ - m_my_array = std::move(x.m_my_array); - -} - -ArrayBadStruct& ArrayBadStruct::operator =( - const ArrayBadStruct& x) -{ - m_my_array = x.m_my_array; - - return *this; -} - -ArrayBadStruct& ArrayBadStruct::operator =( - ArrayBadStruct&& x) noexcept -{ - m_my_array = std::move(x.m_my_array); - - return *this; -} - -bool ArrayBadStruct::operator ==( - const ArrayBadStruct& x) const -{ - return (m_my_array == x.m_my_array); -} - -bool ArrayBadStruct::operator !=( - const ArrayBadStruct& x) const -{ - return !(*this == x); -} - -size_t ArrayBadStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return ArrayBadStruct_max_cdr_typesize; -} - -size_t ArrayBadStruct::getCdrSerializedSize( - const ArrayBadStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += (((2)) * 1) + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - - return current_alignment - initial_alignment; -} - - -void ArrayBadStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_array; - - -} - -void ArrayBadStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_array; - - -} - - -bool ArrayBadStruct::isKeyDefined() -{ - return false; -} - -void ArrayBadStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_array - * @param _my_array New value to be copied in member my_array - */ -void ArrayBadStruct::my_array( - const std::array& _my_array) -{ - m_my_array = _my_array; -} - -/*! - * @brief This function moves the value in member my_array - * @param _my_array New value to be moved in member my_array - */ -void ArrayBadStruct::my_array( - std::array&& _my_array) -{ - m_my_array = std::move(_my_array); -} - -/*! - * @brief This function returns a constant reference to member my_array - * @return Constant reference to member my_array - */ -const std::array& ArrayBadStruct::my_array() const -{ - return m_my_array; -} - -/*! - * @brief This function returns a reference to member my_array - * @return Reference to member my_array - */ -std::array& ArrayBadStruct::my_array() -{ - return m_my_array; -} - - - - - -ArrayDimensionsStruct::ArrayDimensionsStruct() -{ - // long m_my_array - memset(&m_my_array, 0, ((2) * (2)) * 4); - - // Just to register all known types - registerTypesTypes(); -} - -ArrayDimensionsStruct::~ArrayDimensionsStruct() -{ -} - -ArrayDimensionsStruct::ArrayDimensionsStruct( - const ArrayDimensionsStruct& x) -{ - m_my_array = x.m_my_array; - -} - -ArrayDimensionsStruct::ArrayDimensionsStruct( - ArrayDimensionsStruct&& x) noexcept -{ - m_my_array = std::move(x.m_my_array); - -} - -ArrayDimensionsStruct& ArrayDimensionsStruct::operator =( - const ArrayDimensionsStruct& x) -{ - m_my_array = x.m_my_array; - - return *this; -} - -ArrayDimensionsStruct& ArrayDimensionsStruct::operator =( - ArrayDimensionsStruct&& x) noexcept -{ - m_my_array = std::move(x.m_my_array); - - return *this; -} - -bool ArrayDimensionsStruct::operator ==( - const ArrayDimensionsStruct& x) const -{ - return (m_my_array == x.m_my_array); -} - -bool ArrayDimensionsStruct::operator !=( - const ArrayDimensionsStruct& x) const -{ - return !(*this == x); -} - -size_t ArrayDimensionsStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return ArrayDimensionsStruct_max_cdr_typesize; -} - -size_t ArrayDimensionsStruct::getCdrSerializedSize( - const ArrayDimensionsStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += (((2) * (2)) * 4) + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - - return current_alignment - initial_alignment; -} - - -void ArrayDimensionsStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - for (uint32_t b = 0; b < m_my_array.size(); ++b) - { - scdr << m_my_array[b]; - - } - - - -} - -void ArrayDimensionsStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - for (uint32_t d = 0; d < m_my_array.size(); ++d) - { - dcdr >> m_my_array[d]; - - } - - - -} - - -bool ArrayDimensionsStruct::isKeyDefined() -{ - return false; -} - -void ArrayDimensionsStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_array - * @param _my_array New value to be copied in member my_array - */ -void ArrayDimensionsStruct::my_array( - const std::array, 2>& _my_array) -{ - m_my_array = _my_array; -} - -/*! - * @brief This function moves the value in member my_array - * @param _my_array New value to be moved in member my_array - */ -void ArrayDimensionsStruct::my_array( - std::array, 2>&& _my_array) -{ - m_my_array = std::move(_my_array); -} - -/*! - * @brief This function returns a constant reference to member my_array - * @return Constant reference to member my_array - */ -const std::array, 2>& ArrayDimensionsStruct::my_array() const -{ - return m_my_array; -} - -/*! - * @brief This function returns a reference to member my_array - * @return Reference to member my_array - */ -std::array, 2>& ArrayDimensionsStruct::my_array() -{ - return m_my_array; -} - - - - - -ArraySizeStruct::ArraySizeStruct() -{ - // long m_my_array - memset(&m_my_array, 0, ((5)) * 4); - - // Just to register all known types - registerTypesTypes(); -} - -ArraySizeStruct::~ArraySizeStruct() -{ -} - -ArraySizeStruct::ArraySizeStruct( - const ArraySizeStruct& x) -{ - m_my_array = x.m_my_array; - -} - -ArraySizeStruct::ArraySizeStruct( - ArraySizeStruct&& x) noexcept -{ - m_my_array = std::move(x.m_my_array); - -} - -ArraySizeStruct& ArraySizeStruct::operator =( - const ArraySizeStruct& x) -{ - m_my_array = x.m_my_array; - - return *this; -} - -ArraySizeStruct& ArraySizeStruct::operator =( - ArraySizeStruct&& x) noexcept -{ - m_my_array = std::move(x.m_my_array); - - return *this; -} - -bool ArraySizeStruct::operator ==( - const ArraySizeStruct& x) const -{ - return (m_my_array == x.m_my_array); -} - -bool ArraySizeStruct::operator !=( - const ArraySizeStruct& x) const -{ - return !(*this == x); -} - -size_t ArraySizeStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return ArraySizeStruct_max_cdr_typesize; -} - -size_t ArraySizeStruct::getCdrSerializedSize( - const ArraySizeStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += (((5)) * 4) + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - - return current_alignment - initial_alignment; -} - - -void ArraySizeStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_array; - - -} - -void ArraySizeStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_array; - - -} - - -bool ArraySizeStruct::isKeyDefined() -{ - return false; -} - -void ArraySizeStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_array - * @param _my_array New value to be copied in member my_array - */ -void ArraySizeStruct::my_array( - const std::array& _my_array) -{ - m_my_array = _my_array; -} - -/*! - * @brief This function moves the value in member my_array - * @param _my_array New value to be moved in member my_array - */ -void ArraySizeStruct::my_array( - std::array&& _my_array) -{ - m_my_array = std::move(_my_array); -} - -/*! - * @brief This function returns a constant reference to member my_array - * @return Constant reference to member my_array - */ -const std::array& ArraySizeStruct::my_array() const -{ - return m_my_array; -} - -/*! - * @brief This function returns a reference to member my_array - * @return Reference to member my_array - */ -std::array& ArraySizeStruct::my_array() -{ - return m_my_array; -} - - - - - - - -SequenceStruct::SequenceStruct() -{ - // sequence m_my_sequence - - - // Just to register all known types - registerTypesTypes(); -} - -SequenceStruct::~SequenceStruct() -{ -} - -SequenceStruct::SequenceStruct( - const SequenceStruct& x) -{ - m_my_sequence = x.m_my_sequence; - -} - -SequenceStruct::SequenceStruct( - SequenceStruct&& x) noexcept -{ - m_my_sequence = std::move(x.m_my_sequence); - -} - -SequenceStruct& SequenceStruct::operator =( - const SequenceStruct& x) -{ - m_my_sequence = x.m_my_sequence; - - return *this; -} - -SequenceStruct& SequenceStruct::operator =( - SequenceStruct&& x) noexcept -{ - m_my_sequence = std::move(x.m_my_sequence); - - return *this; -} - -bool SequenceStruct::operator ==( - const SequenceStruct& x) const -{ - return (m_my_sequence == x.m_my_sequence); -} - -bool SequenceStruct::operator !=( - const SequenceStruct& x) const -{ - return !(*this == x); -} - -size_t SequenceStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return SequenceStruct_max_cdr_typesize; -} - -size_t SequenceStruct::getCdrSerializedSize( - const SequenceStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - if (data.my_sequence().size() > 0) - { - current_alignment += (data.my_sequence().size() * 4) + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - } - - - - - return current_alignment - initial_alignment; -} - - -void SequenceStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_sequence; - - -} - -void SequenceStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_sequence; - - -} - - -bool SequenceStruct::isKeyDefined() -{ - return false; -} - -void SequenceStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_sequence - * @param _my_sequence New value to be copied in member my_sequence - */ -void SequenceStruct::my_sequence( - const std::vector& _my_sequence) -{ - m_my_sequence = _my_sequence; -} - -/*! - * @brief This function moves the value in member my_sequence - * @param _my_sequence New value to be moved in member my_sequence - */ -void SequenceStruct::my_sequence( - std::vector&& _my_sequence) -{ - m_my_sequence = std::move(_my_sequence); -} - -/*! - * @brief This function returns a constant reference to member my_sequence - * @return Constant reference to member my_sequence - */ -const std::vector& SequenceStruct::my_sequence() const -{ - return m_my_sequence; -} - -/*! - * @brief This function returns a reference to member my_sequence - * @return Reference to member my_sequence - */ -std::vector& SequenceStruct::my_sequence() -{ - return m_my_sequence; -} - - - - - - - -SequenceStructEqual::SequenceStructEqual() -{ - // sequence m_my_sequence_equal - - - // Just to register all known types - registerTypesTypes(); -} - -SequenceStructEqual::~SequenceStructEqual() -{ -} - -SequenceStructEqual::SequenceStructEqual( - const SequenceStructEqual& x) -{ - m_my_sequence_equal = x.m_my_sequence_equal; - -} - -SequenceStructEqual::SequenceStructEqual( - SequenceStructEqual&& x) noexcept -{ - m_my_sequence_equal = std::move(x.m_my_sequence_equal); - -} - -SequenceStructEqual& SequenceStructEqual::operator =( - const SequenceStructEqual& x) -{ - m_my_sequence_equal = x.m_my_sequence_equal; - - return *this; -} - -SequenceStructEqual& SequenceStructEqual::operator =( - SequenceStructEqual&& x) noexcept -{ - m_my_sequence_equal = std::move(x.m_my_sequence_equal); - - return *this; -} - -bool SequenceStructEqual::operator ==( - const SequenceStructEqual& x) const -{ - return (m_my_sequence_equal == x.m_my_sequence_equal); -} - -bool SequenceStructEqual::operator !=( - const SequenceStructEqual& x) const -{ - return !(*this == x); -} - -size_t SequenceStructEqual::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return SequenceStructEqual_max_cdr_typesize; -} - -size_t SequenceStructEqual::getCdrSerializedSize( - const SequenceStructEqual& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - if (data.my_sequence_equal().size() > 0) - { - current_alignment += (data.my_sequence_equal().size() * 4) + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - } - - - - - return current_alignment - initial_alignment; -} - - -void SequenceStructEqual::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_sequence_equal; - - -} - -void SequenceStructEqual::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_sequence_equal; - - -} - - -bool SequenceStructEqual::isKeyDefined() -{ - return false; -} - -void SequenceStructEqual::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_sequence_equal - * @param _my_sequence_equal New value to be copied in member my_sequence_equal - */ -void SequenceStructEqual::my_sequence_equal( - const std::vector& _my_sequence_equal) -{ - m_my_sequence_equal = _my_sequence_equal; -} - -/*! - * @brief This function moves the value in member my_sequence_equal - * @param _my_sequence_equal New value to be moved in member my_sequence_equal - */ -void SequenceStructEqual::my_sequence_equal( - std::vector&& _my_sequence_equal) -{ - m_my_sequence_equal = std::move(_my_sequence_equal); -} - -/*! - * @brief This function returns a constant reference to member my_sequence_equal - * @return Constant reference to member my_sequence_equal - */ -const std::vector& SequenceStructEqual::my_sequence_equal() const -{ - return m_my_sequence_equal; -} - -/*! - * @brief This function returns a reference to member my_sequence_equal - * @return Reference to member my_sequence_equal - */ -std::vector& SequenceStructEqual::my_sequence_equal() -{ - return m_my_sequence_equal; -} - - - - - - - -SequenceBadStruct::SequenceBadStruct() -{ - // sequence m_my_sequence - - - // Just to register all known types - registerTypesTypes(); -} - -SequenceBadStruct::~SequenceBadStruct() -{ -} - -SequenceBadStruct::SequenceBadStruct( - const SequenceBadStruct& x) -{ - m_my_sequence = x.m_my_sequence; - -} - -SequenceBadStruct::SequenceBadStruct( - SequenceBadStruct&& x) noexcept -{ - m_my_sequence = std::move(x.m_my_sequence); - -} - -SequenceBadStruct& SequenceBadStruct::operator =( - const SequenceBadStruct& x) -{ - m_my_sequence = x.m_my_sequence; - - return *this; -} - -SequenceBadStruct& SequenceBadStruct::operator =( - SequenceBadStruct&& x) noexcept -{ - m_my_sequence = std::move(x.m_my_sequence); - - return *this; -} - -bool SequenceBadStruct::operator ==( - const SequenceBadStruct& x) const -{ - return (m_my_sequence == x.m_my_sequence); -} - -bool SequenceBadStruct::operator !=( - const SequenceBadStruct& x) const -{ - return !(*this == x); -} - -size_t SequenceBadStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return SequenceBadStruct_max_cdr_typesize; -} - -size_t SequenceBadStruct::getCdrSerializedSize( - const SequenceBadStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - if (data.my_sequence().size() > 0) - { - current_alignment += (data.my_sequence().size() * 1) + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - } - - - - - return current_alignment - initial_alignment; -} - - -void SequenceBadStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_sequence; - - -} - -void SequenceBadStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_sequence; - - -} - - -bool SequenceBadStruct::isKeyDefined() -{ - return false; -} - -void SequenceBadStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_sequence - * @param _my_sequence New value to be copied in member my_sequence - */ -void SequenceBadStruct::my_sequence( - const std::vector& _my_sequence) -{ - m_my_sequence = _my_sequence; -} - -/*! - * @brief This function moves the value in member my_sequence - * @param _my_sequence New value to be moved in member my_sequence - */ -void SequenceBadStruct::my_sequence( - std::vector&& _my_sequence) -{ - m_my_sequence = std::move(_my_sequence); -} - -/*! - * @brief This function returns a constant reference to member my_sequence - * @return Constant reference to member my_sequence - */ -const std::vector& SequenceBadStruct::my_sequence() const -{ - return m_my_sequence; -} - -/*! - * @brief This function returns a reference to member my_sequence - * @return Reference to member my_sequence - */ -std::vector& SequenceBadStruct::my_sequence() -{ - return m_my_sequence; -} - - - - - - - -SequenceBoundsStruct::SequenceBoundsStruct() -{ - // sequence m_my_sequence - - - // Just to register all known types - registerTypesTypes(); -} - -SequenceBoundsStruct::~SequenceBoundsStruct() -{ -} - -SequenceBoundsStruct::SequenceBoundsStruct( - const SequenceBoundsStruct& x) -{ - m_my_sequence = x.m_my_sequence; - -} - -SequenceBoundsStruct::SequenceBoundsStruct( - SequenceBoundsStruct&& x) noexcept -{ - m_my_sequence = std::move(x.m_my_sequence); - -} - -SequenceBoundsStruct& SequenceBoundsStruct::operator =( - const SequenceBoundsStruct& x) -{ - m_my_sequence = x.m_my_sequence; - - return *this; -} - -SequenceBoundsStruct& SequenceBoundsStruct::operator =( - SequenceBoundsStruct&& x) noexcept -{ - m_my_sequence = std::move(x.m_my_sequence); - - return *this; -} - -bool SequenceBoundsStruct::operator ==( - const SequenceBoundsStruct& x) const -{ - return (m_my_sequence == x.m_my_sequence); -} - -bool SequenceBoundsStruct::operator !=( - const SequenceBoundsStruct& x) const -{ - return !(*this == x); -} - -size_t SequenceBoundsStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return SequenceBoundsStruct_max_cdr_typesize; -} - -size_t SequenceBoundsStruct::getCdrSerializedSize( - const SequenceBoundsStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - if (data.my_sequence().size() > 0) - { - current_alignment += (data.my_sequence().size() * 4) + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - } - - - - - return current_alignment - initial_alignment; -} - - -void SequenceBoundsStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_sequence; - - -} - -void SequenceBoundsStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_sequence; - - -} - - -bool SequenceBoundsStruct::isKeyDefined() -{ - return false; -} - -void SequenceBoundsStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_sequence - * @param _my_sequence New value to be copied in member my_sequence - */ -void SequenceBoundsStruct::my_sequence( - const std::vector& _my_sequence) -{ - m_my_sequence = _my_sequence; -} - -/*! - * @brief This function moves the value in member my_sequence - * @param _my_sequence New value to be moved in member my_sequence - */ -void SequenceBoundsStruct::my_sequence( - std::vector&& _my_sequence) -{ - m_my_sequence = std::move(_my_sequence); -} - -/*! - * @brief This function returns a constant reference to member my_sequence - * @return Constant reference to member my_sequence - */ -const std::vector& SequenceBoundsStruct::my_sequence() const -{ - return m_my_sequence; -} - -/*! - * @brief This function returns a reference to member my_sequence - * @return Reference to member my_sequence - */ -std::vector& SequenceBoundsStruct::my_sequence() -{ - return m_my_sequence; -} - - - - - - - - - -SequenceSequenceStruct::SequenceSequenceStruct() -{ - // sequence, 3> m_my_sequence_sequence - - - // Just to register all known types - registerTypesTypes(); -} - -SequenceSequenceStruct::~SequenceSequenceStruct() -{ -} - -SequenceSequenceStruct::SequenceSequenceStruct( - const SequenceSequenceStruct& x) -{ - m_my_sequence_sequence = x.m_my_sequence_sequence; - -} - -SequenceSequenceStruct::SequenceSequenceStruct( - SequenceSequenceStruct&& x) noexcept -{ - m_my_sequence_sequence = std::move(x.m_my_sequence_sequence); - -} - -SequenceSequenceStruct& SequenceSequenceStruct::operator =( - const SequenceSequenceStruct& x) -{ - m_my_sequence_sequence = x.m_my_sequence_sequence; - - return *this; -} - -SequenceSequenceStruct& SequenceSequenceStruct::operator =( - SequenceSequenceStruct&& x) noexcept -{ - m_my_sequence_sequence = std::move(x.m_my_sequence_sequence); - - return *this; -} - -bool SequenceSequenceStruct::operator ==( - const SequenceSequenceStruct& x) const -{ - return (m_my_sequence_sequence == x.m_my_sequence_sequence); -} - -bool SequenceSequenceStruct::operator !=( - const SequenceSequenceStruct& x) const -{ - return !(*this == x); -} - -size_t SequenceSequenceStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return SequenceSequenceStruct_max_cdr_typesize; -} - -size_t SequenceSequenceStruct::getCdrSerializedSize( - const SequenceSequenceStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - for(size_t a = 0; a < data.my_sequence_sequence().size(); ++a) - { - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - if (data.my_sequence_sequence().at(a).size() > 0) - { - current_alignment += (data.my_sequence_sequence().at(a).size() * 4) + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - } - - - } - - - - return current_alignment - initial_alignment; -} - - -void SequenceSequenceStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_sequence_sequence; - - -} - -void SequenceSequenceStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_sequence_sequence; - - -} - - -bool SequenceSequenceStruct::isKeyDefined() -{ - return false; -} - -void SequenceSequenceStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_sequence_sequence - * @param _my_sequence_sequence New value to be copied in member my_sequence_sequence - */ -void SequenceSequenceStruct::my_sequence_sequence( - const std::vector>& _my_sequence_sequence) -{ - m_my_sequence_sequence = _my_sequence_sequence; -} - -/*! - * @brief This function moves the value in member my_sequence_sequence - * @param _my_sequence_sequence New value to be moved in member my_sequence_sequence - */ -void SequenceSequenceStruct::my_sequence_sequence( - std::vector>&& _my_sequence_sequence) -{ - m_my_sequence_sequence = std::move(_my_sequence_sequence); -} - -/*! - * @brief This function returns a constant reference to member my_sequence_sequence - * @return Constant reference to member my_sequence_sequence - */ -const std::vector>& SequenceSequenceStruct::my_sequence_sequence() const -{ - return m_my_sequence_sequence; -} - -/*! - * @brief This function returns a reference to member my_sequence_sequence - * @return Reference to member my_sequence_sequence - */ -std::vector>& SequenceSequenceStruct::my_sequence_sequence() -{ - return m_my_sequence_sequence; -} - - - - - - - - - -SequenceSequenceBoundsStruct::SequenceSequenceBoundsStruct() -{ - // sequence, 5> m_my_sequence_sequence - - - // Just to register all known types - registerTypesTypes(); -} - -SequenceSequenceBoundsStruct::~SequenceSequenceBoundsStruct() -{ -} - -SequenceSequenceBoundsStruct::SequenceSequenceBoundsStruct( - const SequenceSequenceBoundsStruct& x) -{ - m_my_sequence_sequence = x.m_my_sequence_sequence; - -} - -SequenceSequenceBoundsStruct::SequenceSequenceBoundsStruct( - SequenceSequenceBoundsStruct&& x) noexcept -{ - m_my_sequence_sequence = std::move(x.m_my_sequence_sequence); - -} - -SequenceSequenceBoundsStruct& SequenceSequenceBoundsStruct::operator =( - const SequenceSequenceBoundsStruct& x) -{ - m_my_sequence_sequence = x.m_my_sequence_sequence; - - return *this; -} - -SequenceSequenceBoundsStruct& SequenceSequenceBoundsStruct::operator =( - SequenceSequenceBoundsStruct&& x) noexcept -{ - m_my_sequence_sequence = std::move(x.m_my_sequence_sequence); - - return *this; -} - -bool SequenceSequenceBoundsStruct::operator ==( - const SequenceSequenceBoundsStruct& x) const -{ - return (m_my_sequence_sequence == x.m_my_sequence_sequence); -} - -bool SequenceSequenceBoundsStruct::operator !=( - const SequenceSequenceBoundsStruct& x) const -{ - return !(*this == x); -} - -size_t SequenceSequenceBoundsStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return SequenceSequenceBoundsStruct_max_cdr_typesize; -} - -size_t SequenceSequenceBoundsStruct::getCdrSerializedSize( - const SequenceSequenceBoundsStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - for(size_t a = 0; a < data.my_sequence_sequence().size(); ++a) - { - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - if (data.my_sequence_sequence().at(a).size() > 0) - { - current_alignment += (data.my_sequence_sequence().at(a).size() * 4) + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - } - - - } - - - - return current_alignment - initial_alignment; -} - - -void SequenceSequenceBoundsStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_sequence_sequence; - - -} - -void SequenceSequenceBoundsStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_sequence_sequence; - - -} - - -bool SequenceSequenceBoundsStruct::isKeyDefined() -{ - return false; -} - -void SequenceSequenceBoundsStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_sequence_sequence - * @param _my_sequence_sequence New value to be copied in member my_sequence_sequence - */ -void SequenceSequenceBoundsStruct::my_sequence_sequence( - const std::vector>& _my_sequence_sequence) -{ - m_my_sequence_sequence = _my_sequence_sequence; -} - -/*! - * @brief This function moves the value in member my_sequence_sequence - * @param _my_sequence_sequence New value to be moved in member my_sequence_sequence - */ -void SequenceSequenceBoundsStruct::my_sequence_sequence( - std::vector>&& _my_sequence_sequence) -{ - m_my_sequence_sequence = std::move(_my_sequence_sequence); -} - -/*! - * @brief This function returns a constant reference to member my_sequence_sequence - * @return Constant reference to member my_sequence_sequence - */ -const std::vector>& SequenceSequenceBoundsStruct::my_sequence_sequence() const -{ - return m_my_sequence_sequence; -} - -/*! - * @brief This function returns a reference to member my_sequence_sequence - * @return Reference to member my_sequence_sequence - */ -std::vector>& SequenceSequenceBoundsStruct::my_sequence_sequence() -{ - return m_my_sequence_sequence; -} - - - - - - - -MapStruct::MapStruct() -{ - // map m_my_map - - - // Just to register all known types - registerTypesTypes(); -} - -MapStruct::~MapStruct() -{ -} - -MapStruct::MapStruct( - const MapStruct& x) -{ - m_my_map = x.m_my_map; - -} - -MapStruct::MapStruct( - MapStruct&& x) noexcept -{ - m_my_map = std::move(x.m_my_map); - -} - -MapStruct& MapStruct::operator =( - const MapStruct& x) -{ - m_my_map = x.m_my_map; - - return *this; -} - -MapStruct& MapStruct::operator =( - MapStruct&& x) noexcept -{ - m_my_map = std::move(x.m_my_map); - - return *this; -} - -bool MapStruct::operator ==( - const MapStruct& x) const -{ - return (m_my_map == x.m_my_map); -} - -bool MapStruct::operator !=( - const MapStruct& x) const -{ - return !(*this == x); -} - -size_t MapStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return MapStruct_max_cdr_typesize; -} - -size_t MapStruct::getCdrSerializedSize( - const MapStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - for(auto a : data.my_map()) - { - (void)a; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - } - - - return current_alignment - initial_alignment; -} - - -void MapStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << static_cast(m_my_map.size()); - for (const auto& pair : m_my_map) - { - scdr << pair.first; - scdr << pair.second; - } - -} - -void MapStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - - dcdr >> m_my_map; - - -} - - -bool MapStruct::isKeyDefined() -{ - return false; -} - -void MapStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_map - * @param _my_map New value to be copied in member my_map - */ -void MapStruct::my_map( - const std::map& _my_map) -{ - m_my_map = _my_map; -} - -/*! - * @brief This function moves the value in member my_map - * @param _my_map New value to be moved in member my_map - */ -void MapStruct::my_map( - std::map&& _my_map) -{ - m_my_map = std::move(_my_map); -} - -/*! - * @brief This function returns a constant reference to member my_map - * @return Constant reference to member my_map - */ -const std::map& MapStruct::my_map() const -{ - return m_my_map; -} - -/*! - * @brief This function returns a reference to member my_map - * @return Reference to member my_map - */ -std::map& MapStruct::my_map() -{ - return m_my_map; -} - - - - - - - -MapStructEqual::MapStructEqual() -{ - // map m_my_map_equal - - - // Just to register all known types - registerTypesTypes(); -} - -MapStructEqual::~MapStructEqual() -{ -} - -MapStructEqual::MapStructEqual( - const MapStructEqual& x) -{ - m_my_map_equal = x.m_my_map_equal; - -} - -MapStructEqual::MapStructEqual( - MapStructEqual&& x) noexcept -{ - m_my_map_equal = std::move(x.m_my_map_equal); - -} - -MapStructEqual& MapStructEqual::operator =( - const MapStructEqual& x) -{ - m_my_map_equal = x.m_my_map_equal; - - return *this; -} - -MapStructEqual& MapStructEqual::operator =( - MapStructEqual&& x) noexcept -{ - m_my_map_equal = std::move(x.m_my_map_equal); - - return *this; -} - -bool MapStructEqual::operator ==( - const MapStructEqual& x) const -{ - return (m_my_map_equal == x.m_my_map_equal); -} - -bool MapStructEqual::operator !=( - const MapStructEqual& x) const -{ - return !(*this == x); -} - -size_t MapStructEqual::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return MapStructEqual_max_cdr_typesize; -} - -size_t MapStructEqual::getCdrSerializedSize( - const MapStructEqual& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - for(auto a : data.my_map_equal()) - { - (void)a; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - } - - - return current_alignment - initial_alignment; -} - - -void MapStructEqual::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << static_cast(m_my_map_equal.size()); - for (const auto& pair : m_my_map_equal) - { - scdr << pair.first; - scdr << pair.second; - } - -} - -void MapStructEqual::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - - dcdr >> m_my_map_equal; - - -} - - -bool MapStructEqual::isKeyDefined() -{ - return false; -} - -void MapStructEqual::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_map_equal - * @param _my_map_equal New value to be copied in member my_map_equal - */ -void MapStructEqual::my_map_equal( - const std::map& _my_map_equal) -{ - m_my_map_equal = _my_map_equal; -} - -/*! - * @brief This function moves the value in member my_map_equal - * @param _my_map_equal New value to be moved in member my_map_equal - */ -void MapStructEqual::my_map_equal( - std::map&& _my_map_equal) -{ - m_my_map_equal = std::move(_my_map_equal); -} - -/*! - * @brief This function returns a constant reference to member my_map_equal - * @return Constant reference to member my_map_equal - */ -const std::map& MapStructEqual::my_map_equal() const -{ - return m_my_map_equal; -} - -/*! - * @brief This function returns a reference to member my_map_equal - * @return Reference to member my_map_equal - */ -std::map& MapStructEqual::my_map_equal() -{ - return m_my_map_equal; -} - - - - - - - -MapBadKeyStruct::MapBadKeyStruct() -{ - // map m_my_map - - - // Just to register all known types - registerTypesTypes(); -} - -MapBadKeyStruct::~MapBadKeyStruct() -{ -} - -MapBadKeyStruct::MapBadKeyStruct( - const MapBadKeyStruct& x) -{ - m_my_map = x.m_my_map; - -} - -MapBadKeyStruct::MapBadKeyStruct( - MapBadKeyStruct&& x) noexcept -{ - m_my_map = std::move(x.m_my_map); - -} - -MapBadKeyStruct& MapBadKeyStruct::operator =( - const MapBadKeyStruct& x) -{ - m_my_map = x.m_my_map; - - return *this; -} - -MapBadKeyStruct& MapBadKeyStruct::operator =( - MapBadKeyStruct&& x) noexcept -{ - m_my_map = std::move(x.m_my_map); - - return *this; -} - -bool MapBadKeyStruct::operator ==( - const MapBadKeyStruct& x) const -{ - return (m_my_map == x.m_my_map); -} - -bool MapBadKeyStruct::operator !=( - const MapBadKeyStruct& x) const -{ - return !(*this == x); -} - -size_t MapBadKeyStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return MapBadKeyStruct_max_cdr_typesize; -} - -size_t MapBadKeyStruct::getCdrSerializedSize( - const MapBadKeyStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - for(auto a : data.my_map()) - { - (void)a; - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - } - - - return current_alignment - initial_alignment; -} - - -void MapBadKeyStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << static_cast(m_my_map.size()); - for (const auto& pair : m_my_map) - { - scdr << pair.first; - scdr << pair.second; - } - -} - -void MapBadKeyStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - - dcdr >> m_my_map; - - -} - - -bool MapBadKeyStruct::isKeyDefined() -{ - return false; -} - -void MapBadKeyStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_map - * @param _my_map New value to be copied in member my_map - */ -void MapBadKeyStruct::my_map( - const std::map& _my_map) -{ - m_my_map = _my_map; -} - -/*! - * @brief This function moves the value in member my_map - * @param _my_map New value to be moved in member my_map - */ -void MapBadKeyStruct::my_map( - std::map&& _my_map) -{ - m_my_map = std::move(_my_map); -} - -/*! - * @brief This function returns a constant reference to member my_map - * @return Constant reference to member my_map - */ -const std::map& MapBadKeyStruct::my_map() const -{ - return m_my_map; -} - -/*! - * @brief This function returns a reference to member my_map - * @return Reference to member my_map - */ -std::map& MapBadKeyStruct::my_map() -{ - return m_my_map; -} - - - - - - - -MapBadElemStruct::MapBadElemStruct() -{ - // map m_my_map - - - // Just to register all known types - registerTypesTypes(); -} - -MapBadElemStruct::~MapBadElemStruct() -{ -} - -MapBadElemStruct::MapBadElemStruct( - const MapBadElemStruct& x) -{ - m_my_map = x.m_my_map; - -} - -MapBadElemStruct::MapBadElemStruct( - MapBadElemStruct&& x) noexcept -{ - m_my_map = std::move(x.m_my_map); - -} - -MapBadElemStruct& MapBadElemStruct::operator =( - const MapBadElemStruct& x) -{ - m_my_map = x.m_my_map; - - return *this; -} - -MapBadElemStruct& MapBadElemStruct::operator =( - MapBadElemStruct&& x) noexcept -{ - m_my_map = std::move(x.m_my_map); - - return *this; -} - -bool MapBadElemStruct::operator ==( - const MapBadElemStruct& x) const -{ - return (m_my_map == x.m_my_map); -} - -bool MapBadElemStruct::operator !=( - const MapBadElemStruct& x) const -{ - return !(*this == x); -} - -size_t MapBadElemStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return MapBadElemStruct_max_cdr_typesize; -} - -size_t MapBadElemStruct::getCdrSerializedSize( - const MapBadElemStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - for(auto a : data.my_map()) - { - (void)a; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - current_alignment += 8 + eprosima::fastcdr::Cdr::alignment(current_alignment, 8); - - } - - - return current_alignment - initial_alignment; -} - - -void MapBadElemStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << static_cast(m_my_map.size()); - for (const auto& pair : m_my_map) - { - scdr << pair.first; - scdr << pair.second; - } - -} - -void MapBadElemStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - - dcdr >> m_my_map; - - -} - - -bool MapBadElemStruct::isKeyDefined() -{ - return false; -} - -void MapBadElemStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_map - * @param _my_map New value to be copied in member my_map - */ -void MapBadElemStruct::my_map( - const std::map& _my_map) -{ - m_my_map = _my_map; -} - -/*! - * @brief This function moves the value in member my_map - * @param _my_map New value to be moved in member my_map - */ -void MapBadElemStruct::my_map( - std::map&& _my_map) -{ - m_my_map = std::move(_my_map); -} - -/*! - * @brief This function returns a constant reference to member my_map - * @return Constant reference to member my_map - */ -const std::map& MapBadElemStruct::my_map() const -{ - return m_my_map; -} - -/*! - * @brief This function returns a reference to member my_map - * @return Reference to member my_map - */ -std::map& MapBadElemStruct::my_map() -{ - return m_my_map; -} - - - - - - - -MapBoundsStruct::MapBoundsStruct() -{ - // map m_my_map - - - // Just to register all known types - registerTypesTypes(); -} - -MapBoundsStruct::~MapBoundsStruct() -{ -} - -MapBoundsStruct::MapBoundsStruct( - const MapBoundsStruct& x) -{ - m_my_map = x.m_my_map; - -} - -MapBoundsStruct::MapBoundsStruct( - MapBoundsStruct&& x) noexcept -{ - m_my_map = std::move(x.m_my_map); - -} - -MapBoundsStruct& MapBoundsStruct::operator =( - const MapBoundsStruct& x) -{ - m_my_map = x.m_my_map; - - return *this; -} - -MapBoundsStruct& MapBoundsStruct::operator =( - MapBoundsStruct&& x) noexcept -{ - m_my_map = std::move(x.m_my_map); - - return *this; -} - -bool MapBoundsStruct::operator ==( - const MapBoundsStruct& x) const -{ - return (m_my_map == x.m_my_map); -} - -bool MapBoundsStruct::operator !=( - const MapBoundsStruct& x) const -{ - return !(*this == x); -} - -size_t MapBoundsStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return MapBoundsStruct_max_cdr_typesize; -} - -size_t MapBoundsStruct::getCdrSerializedSize( - const MapBoundsStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - for(auto a : data.my_map()) - { - (void)a; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - } - - - return current_alignment - initial_alignment; -} - - -void MapBoundsStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << static_cast(m_my_map.size()); - for (const auto& pair : m_my_map) - { - scdr << pair.first; - scdr << pair.second; - } - -} - -void MapBoundsStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - - dcdr >> m_my_map; - - -} - - -bool MapBoundsStruct::isKeyDefined() -{ - return false; -} - -void MapBoundsStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_map - * @param _my_map New value to be copied in member my_map - */ -void MapBoundsStruct::my_map( - const std::map& _my_map) -{ - m_my_map = _my_map; -} - -/*! - * @brief This function moves the value in member my_map - * @param _my_map New value to be moved in member my_map - */ -void MapBoundsStruct::my_map( - std::map&& _my_map) -{ - m_my_map = std::move(_my_map); -} - -/*! - * @brief This function returns a constant reference to member my_map - * @return Constant reference to member my_map - */ -const std::map& MapBoundsStruct::my_map() const -{ - return m_my_map; -} - -/*! - * @brief This function returns a reference to member my_map - * @return Reference to member my_map - */ -std::map& MapBoundsStruct::my_map() -{ - return m_my_map; -} - - - - - - - - - -MapMapStruct::MapMapStruct() -{ - // map> m_my_map_map - - - // Just to register all known types - registerTypesTypes(); -} - -MapMapStruct::~MapMapStruct() -{ -} - -MapMapStruct::MapMapStruct( - const MapMapStruct& x) -{ - m_my_map_map = x.m_my_map_map; - -} - -MapMapStruct::MapMapStruct( - MapMapStruct&& x) noexcept -{ - m_my_map_map = std::move(x.m_my_map_map); - -} - -MapMapStruct& MapMapStruct::operator =( - const MapMapStruct& x) -{ - m_my_map_map = x.m_my_map_map; - - return *this; -} - -MapMapStruct& MapMapStruct::operator =( - MapMapStruct&& x) noexcept -{ - m_my_map_map = std::move(x.m_my_map_map); - - return *this; -} - -bool MapMapStruct::operator ==( - const MapMapStruct& x) const -{ - return (m_my_map_map == x.m_my_map_map); -} - -bool MapMapStruct::operator !=( - const MapMapStruct& x) const -{ - return !(*this == x); -} - -size_t MapMapStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return MapMapStruct_max_cdr_typesize; -} - -size_t MapMapStruct::getCdrSerializedSize( - const MapMapStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - for(auto a : data.my_map_map()) - { - (void)a; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - for(auto b : a.second) - { - (void)b; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - } - - } - - - return current_alignment - initial_alignment; -} - - -void MapMapStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << static_cast(m_my_map_map.size()); - for (const auto& pair : m_my_map_map) - { - scdr << pair.first; - scdr << pair.second; - } - -} - -void MapMapStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - - dcdr >> m_my_map_map; - - -} - - -bool MapMapStruct::isKeyDefined() -{ - return false; -} - -void MapMapStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_map_map - * @param _my_map_map New value to be copied in member my_map_map - */ -void MapMapStruct::my_map_map( - const std::map>& _my_map_map) -{ - m_my_map_map = _my_map_map; -} - -/*! - * @brief This function moves the value in member my_map_map - * @param _my_map_map New value to be moved in member my_map_map - */ -void MapMapStruct::my_map_map( - std::map>&& _my_map_map) -{ - m_my_map_map = std::move(_my_map_map); -} - -/*! - * @brief This function returns a constant reference to member my_map_map - * @return Constant reference to member my_map_map - */ -const std::map>& MapMapStruct::my_map_map() const -{ - return m_my_map_map; -} - -/*! - * @brief This function returns a reference to member my_map_map - * @return Reference to member my_map_map - */ -std::map>& MapMapStruct::my_map_map() -{ - return m_my_map_map; -} - - - - - - - - - -MapMapBoundsStruct::MapMapBoundsStruct() -{ - // map> m_my_map_map - - - // Just to register all known types - registerTypesTypes(); -} - -MapMapBoundsStruct::~MapMapBoundsStruct() -{ -} - -MapMapBoundsStruct::MapMapBoundsStruct( - const MapMapBoundsStruct& x) -{ - m_my_map_map = x.m_my_map_map; - -} - -MapMapBoundsStruct::MapMapBoundsStruct( - MapMapBoundsStruct&& x) noexcept -{ - m_my_map_map = std::move(x.m_my_map_map); - -} - -MapMapBoundsStruct& MapMapBoundsStruct::operator =( - const MapMapBoundsStruct& x) -{ - m_my_map_map = x.m_my_map_map; - - return *this; -} - -MapMapBoundsStruct& MapMapBoundsStruct::operator =( - MapMapBoundsStruct&& x) noexcept -{ - m_my_map_map = std::move(x.m_my_map_map); - - return *this; -} - -bool MapMapBoundsStruct::operator ==( - const MapMapBoundsStruct& x) const -{ - return (m_my_map_map == x.m_my_map_map); -} - -bool MapMapBoundsStruct::operator !=( - const MapMapBoundsStruct& x) const -{ - return !(*this == x); -} - -size_t MapMapBoundsStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return MapMapBoundsStruct_max_cdr_typesize; -} - -size_t MapMapBoundsStruct::getCdrSerializedSize( - const MapMapBoundsStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - for(auto a : data.my_map_map()) - { - (void)a; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - for(auto b : a.second) - { - (void)b; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - } - - } - - - return current_alignment - initial_alignment; -} - - -void MapMapBoundsStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << static_cast(m_my_map_map.size()); - for (const auto& pair : m_my_map_map) - { - scdr << pair.first; - scdr << pair.second; - } - -} - -void MapMapBoundsStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - - dcdr >> m_my_map_map; - - -} - - -bool MapMapBoundsStruct::isKeyDefined() -{ - return false; -} - -void MapMapBoundsStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_map_map - * @param _my_map_map New value to be copied in member my_map_map - */ -void MapMapBoundsStruct::my_map_map( - const std::map>& _my_map_map) -{ - m_my_map_map = _my_map_map; -} - -/*! - * @brief This function moves the value in member my_map_map - * @param _my_map_map New value to be moved in member my_map_map - */ -void MapMapBoundsStruct::my_map_map( - std::map>&& _my_map_map) -{ - m_my_map_map = std::move(_my_map_map); -} - -/*! - * @brief This function returns a constant reference to member my_map_map - * @return Constant reference to member my_map_map - */ -const std::map>& MapMapBoundsStruct::my_map_map() const -{ - return m_my_map_map; -} - -/*! - * @brief This function returns a reference to member my_map_map - * @return Reference to member my_map_map - */ -std::map>& MapMapBoundsStruct::my_map_map() -{ - return m_my_map_map; -} - - - - - -SimpleUnion::SimpleUnion() -{ - m__d = A; - // long m_first - m_first = 0; - // long long m_second - m_second = 0; -} - -SimpleUnion::~SimpleUnion() -{ -} - -SimpleUnion::SimpleUnion( - const SimpleUnion& x) -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } -} - -SimpleUnion::SimpleUnion( - SimpleUnion&& x) noexcept -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } -} - -SimpleUnion& SimpleUnion::operator =( - const SimpleUnion& x) -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } - - return *this; -} - -SimpleUnion& SimpleUnion::operator =( - SimpleUnion&& x) noexcept -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } - - return *this; -} - -bool SimpleUnion::operator ==( - const SimpleUnion& x) const -{ - if (m__d != x.m__d) - { - return false; - } - - switch(m__d) - { - case A: - return (m_first == x.m_first); - break; - - - case B: - return (m_second == x.m_second); - break; - - default: - break; - } - return false; -} - -bool SimpleUnion::operator !=( - const SimpleUnion& x) const -{ - return !(*this == x); -} - -void SimpleUnion::_d( - int32_t __d) -{ - bool b = false; - - switch(m__d) - { - case A: - switch(__d) - { - case A: - b = true; - break; - default: - break; - } - break; - - - case B: - switch(__d) - { - case B: - b = true; - break; - default: - break; - } - break; - - } - - if(!b) - { - throw BadParamException("Discriminator doesn't correspond with the selected union member"); - } - - m__d = __d; -} - -int32_t SimpleUnion::_d() const -{ - return m__d; -} - -int32_t& SimpleUnion::_d() -{ - return m__d; -} - -void SimpleUnion::first( - int32_t _first) -{ - m_first = _first; - m__d = A; - -} - -int32_t SimpleUnion::first() const -{ - bool b = false; - - switch(m__d) - { - case A: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first; -} - -int32_t& SimpleUnion::first() -{ - bool b = false; - - switch(m__d) - { - case A: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first; -} - - -void SimpleUnion::second( - int64_t _second) -{ - m_second = _second; - m__d = B; - -} - -int64_t SimpleUnion::second() const -{ - bool b = false; - - switch(m__d) - { - case B: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second; -} - -int64_t& SimpleUnion::second() -{ - bool b = false; - - switch(m__d) - { - case B: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second; -} - - -// TODO(Ricardo) Review -size_t SimpleUnion::getCdrSerializedSize( - const SimpleUnion& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - - switch(data.m__d) - { - case A: - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - break; - - - case B: - current_alignment += 8 + eprosima::fastcdr::Cdr::alignment(current_alignment, 8); - - break; - - default: - break; - } - - return current_alignment - initial_alignment; -} - - -void SimpleUnion::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m__d; - - switch(m__d) - { - case A: - scdr << m_first; - - break; - - - case B: - scdr << m_second; - - break; - - default: - break; - } -} - -void SimpleUnion::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m__d; - - - switch(m__d) - { - case A: - dcdr >> m_first; - - - break; - - - case B: - dcdr >> m_second; - - - break; - - default: - break; - } -} - - - - - -SimpleUnionNames::SimpleUnionNames() -{ - m__d = A; - // long m_first_case - m_first_case = 0; - // long long m_second_case - m_second_case = 0; -} - -SimpleUnionNames::~SimpleUnionNames() -{ -} - -SimpleUnionNames::SimpleUnionNames( - const SimpleUnionNames& x) -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_first_case = x.m_first_case; - break; - - - case B: - m_second_case = x.m_second_case; - break; - - default: - break; - } -} - -SimpleUnionNames::SimpleUnionNames( - SimpleUnionNames&& x) noexcept -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_first_case = x.m_first_case; - break; - - - case B: - m_second_case = x.m_second_case; - break; - - default: - break; - } -} - -SimpleUnionNames& SimpleUnionNames::operator =( - const SimpleUnionNames& x) -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_first_case = x.m_first_case; - break; - - - case B: - m_second_case = x.m_second_case; - break; - - default: - break; - } - - return *this; -} - -SimpleUnionNames& SimpleUnionNames::operator =( - SimpleUnionNames&& x) noexcept -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_first_case = x.m_first_case; - break; - - - case B: - m_second_case = x.m_second_case; - break; - - default: - break; - } - - return *this; -} - -bool SimpleUnionNames::operator ==( - const SimpleUnionNames& x) const -{ - if (m__d != x.m__d) - { - return false; - } - - switch(m__d) - { - case A: - return (m_first_case == x.m_first_case); - break; - - - case B: - return (m_second_case == x.m_second_case); - break; - - default: - break; - } - return false; -} - -bool SimpleUnionNames::operator !=( - const SimpleUnionNames& x) const -{ - return !(*this == x); -} - -void SimpleUnionNames::_d( - int32_t __d) -{ - bool b = false; - - switch(m__d) - { - case A: - switch(__d) - { - case A: - b = true; - break; - default: - break; - } - break; - - - case B: - switch(__d) - { - case B: - b = true; - break; - default: - break; - } - break; - - } - - if(!b) - { - throw BadParamException("Discriminator doesn't correspond with the selected union member"); - } - - m__d = __d; -} - -int32_t SimpleUnionNames::_d() const -{ - return m__d; -} - -int32_t& SimpleUnionNames::_d() -{ - return m__d; -} - -void SimpleUnionNames::first_case( - int32_t _first_case) -{ - m_first_case = _first_case; - m__d = A; - -} - -int32_t SimpleUnionNames::first_case() const -{ - bool b = false; - - switch(m__d) - { - case A: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first_case; -} - -int32_t& SimpleUnionNames::first_case() -{ - bool b = false; - - switch(m__d) - { - case A: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first_case; -} - - -void SimpleUnionNames::second_case( - int64_t _second_case) -{ - m_second_case = _second_case; - m__d = B; - -} - -int64_t SimpleUnionNames::second_case() const -{ - bool b = false; - - switch(m__d) - { - case B: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second_case; -} - -int64_t& SimpleUnionNames::second_case() -{ - bool b = false; - - switch(m__d) - { - case B: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second_case; -} - - -// TODO(Ricardo) Review -size_t SimpleUnionNames::getCdrSerializedSize( - const SimpleUnionNames& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - - switch(data.m__d) - { - case A: - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - break; - - - case B: - current_alignment += 8 + eprosima::fastcdr::Cdr::alignment(current_alignment, 8); - - break; - - default: - break; - } - - return current_alignment - initial_alignment; -} - - -void SimpleUnionNames::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m__d; - - switch(m__d) - { - case A: - scdr << m_first_case; - - break; - - - case B: - scdr << m_second_case; - - break; - - default: - break; - } -} - -void SimpleUnionNames::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m__d; - - - switch(m__d) - { - case A: - dcdr >> m_first_case; - - - break; - - - case B: - dcdr >> m_second_case; - - - break; - - default: - break; - } -} - - - - - -SimpleTypeUnion::SimpleTypeUnion() -{ - m__d = A; - // octet m_first - m_first = 0; - // long long m_second - m_second = 0; -} - -SimpleTypeUnion::~SimpleTypeUnion() -{ -} - -SimpleTypeUnion::SimpleTypeUnion( - const SimpleTypeUnion& x) -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } -} - -SimpleTypeUnion::SimpleTypeUnion( - SimpleTypeUnion&& x) noexcept -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } -} - -SimpleTypeUnion& SimpleTypeUnion::operator =( - const SimpleTypeUnion& x) -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } - - return *this; -} - -SimpleTypeUnion& SimpleTypeUnion::operator =( - SimpleTypeUnion&& x) noexcept -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } - - return *this; -} - -bool SimpleTypeUnion::operator ==( - const SimpleTypeUnion& x) const -{ - if (m__d != x.m__d) - { - return false; - } - - switch(m__d) - { - case A: - return (m_first == x.m_first); - break; - - - case B: - return (m_second == x.m_second); - break; - - default: - break; - } - return false; -} - -bool SimpleTypeUnion::operator !=( - const SimpleTypeUnion& x) const -{ - return !(*this == x); -} - -void SimpleTypeUnion::_d( - int32_t __d) -{ - bool b = false; - - switch(m__d) - { - case A: - switch(__d) - { - case A: - b = true; - break; - default: - break; - } - break; - - - case B: - switch(__d) - { - case B: - b = true; - break; - default: - break; - } - break; - - } - - if(!b) - { - throw BadParamException("Discriminator doesn't correspond with the selected union member"); - } - - m__d = __d; -} - -int32_t SimpleTypeUnion::_d() const -{ - return m__d; -} - -int32_t& SimpleTypeUnion::_d() -{ - return m__d; -} - -void SimpleTypeUnion::first( - uint8_t _first) -{ - m_first = _first; - m__d = A; - -} - -uint8_t SimpleTypeUnion::first() const -{ - bool b = false; - - switch(m__d) - { - case A: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first; -} - -uint8_t& SimpleTypeUnion::first() -{ - bool b = false; - - switch(m__d) - { - case A: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first; -} - - -void SimpleTypeUnion::second( - int64_t _second) -{ - m_second = _second; - m__d = B; - -} - -int64_t SimpleTypeUnion::second() const -{ - bool b = false; - - switch(m__d) - { - case B: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second; -} - -int64_t& SimpleTypeUnion::second() -{ - bool b = false; - - switch(m__d) - { - case B: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second; -} - - -// TODO(Ricardo) Review -size_t SimpleTypeUnion::getCdrSerializedSize( - const SimpleTypeUnion& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - - switch(data.m__d) - { - case A: - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - break; - - - case B: - current_alignment += 8 + eprosima::fastcdr::Cdr::alignment(current_alignment, 8); - - break; - - default: - break; - } - - return current_alignment - initial_alignment; -} - - -void SimpleTypeUnion::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m__d; - - switch(m__d) - { - case A: - scdr << m_first; - - break; - - - case B: - scdr << m_second; - - break; - - default: - break; - } -} - -void SimpleTypeUnion::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m__d; - - - switch(m__d) - { - case A: - dcdr >> m_first; - - - break; - - - case B: - dcdr >> m_second; - - - break; - - default: - break; - } -} - - - - - -SimpleBadUnion::SimpleBadUnion() -{ - m__d = A; - // long m_first - m_first = 0; - // long long m_second - m_second = 0; -} - -SimpleBadUnion::~SimpleBadUnion() -{ -} - -SimpleBadUnion::SimpleBadUnion( - const SimpleBadUnion& x) -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_first = x.m_first; - break; - - - case C: - m_second = x.m_second; - break; - - default: - break; - } -} - -SimpleBadUnion::SimpleBadUnion( - SimpleBadUnion&& x) noexcept -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_first = x.m_first; - break; - - - case C: - m_second = x.m_second; - break; - - default: - break; - } -} - -SimpleBadUnion& SimpleBadUnion::operator =( - const SimpleBadUnion& x) -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_first = x.m_first; - break; - - - case C: - m_second = x.m_second; - break; - - default: - break; - } - - return *this; -} - -SimpleBadUnion& SimpleBadUnion::operator =( - SimpleBadUnion&& x) noexcept -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_first = x.m_first; - break; - - - case C: - m_second = x.m_second; - break; - - default: - break; - } - - return *this; -} - -bool SimpleBadUnion::operator ==( - const SimpleBadUnion& x) const -{ - if (m__d != x.m__d) - { - return false; - } - - switch(m__d) - { - case A: - return (m_first == x.m_first); - break; - - - case C: - return (m_second == x.m_second); - break; - - default: - break; - } - return false; -} - -bool SimpleBadUnion::operator !=( - const SimpleBadUnion& x) const -{ - return !(*this == x); -} - -void SimpleBadUnion::_d( - int32_t __d) -{ - bool b = false; - - switch(m__d) - { - case A: - switch(__d) - { - case A: - b = true; - break; - default: - break; - } - break; - - - case C: - switch(__d) - { - case C: - b = true; - break; - default: - break; - } - break; - - } - - if(!b) - { - throw BadParamException("Discriminator doesn't correspond with the selected union member"); - } - - m__d = __d; -} - -int32_t SimpleBadUnion::_d() const -{ - return m__d; -} - -int32_t& SimpleBadUnion::_d() -{ - return m__d; -} - -void SimpleBadUnion::first( - int32_t _first) -{ - m_first = _first; - m__d = A; - -} - -int32_t SimpleBadUnion::first() const -{ - bool b = false; - - switch(m__d) - { - case A: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first; -} - -int32_t& SimpleBadUnion::first() -{ - bool b = false; - - switch(m__d) - { - case A: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first; -} - - -void SimpleBadUnion::second( - int64_t _second) -{ - m_second = _second; - m__d = C; - -} - -int64_t SimpleBadUnion::second() const -{ - bool b = false; - - switch(m__d) - { - case C: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second; -} - -int64_t& SimpleBadUnion::second() -{ - bool b = false; - - switch(m__d) - { - case C: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second; -} - - -// TODO(Ricardo) Review -size_t SimpleBadUnion::getCdrSerializedSize( - const SimpleBadUnion& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - - switch(data.m__d) - { - case A: - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - break; - - - case C: - current_alignment += 8 + eprosima::fastcdr::Cdr::alignment(current_alignment, 8); - - break; - - default: - break; - } - - return current_alignment - initial_alignment; -} - - -void SimpleBadUnion::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m__d; - - switch(m__d) - { - case A: - scdr << m_first; - - break; - - - case C: - scdr << m_second; - - break; - - default: - break; - } -} - -void SimpleBadUnion::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m__d; - - - switch(m__d) - { - case A: - dcdr >> m_first; - - - break; - - - case C: - dcdr >> m_second; - - - break; - - default: - break; - } -} - - - - - -SimpleBadDiscUnion::SimpleBadDiscUnion() -{ - m__d = 0; - // long m_first - m_first = 0; - // long long m_second - m_second = 0; -} - -SimpleBadDiscUnion::~SimpleBadDiscUnion() -{ -} - -SimpleBadDiscUnion::SimpleBadDiscUnion( - const SimpleBadDiscUnion& x) -{ - m__d = x.m__d; - - switch(m__d) - { - case 0: - m_first = x.m_first; - break; - - - case 1: - m_second = x.m_second; - break; - - default: - break; - } -} - -SimpleBadDiscUnion::SimpleBadDiscUnion( - SimpleBadDiscUnion&& x) noexcept -{ - m__d = x.m__d; - - switch(m__d) - { - case 0: - m_first = x.m_first; - break; - - - case 1: - m_second = x.m_second; - break; - - default: - break; - } -} - -SimpleBadDiscUnion& SimpleBadDiscUnion::operator =( - const SimpleBadDiscUnion& x) -{ - m__d = x.m__d; - - switch(m__d) - { - case 0: - m_first = x.m_first; - break; - - - case 1: - m_second = x.m_second; - break; - - default: - break; - } - - return *this; -} - -SimpleBadDiscUnion& SimpleBadDiscUnion::operator =( - SimpleBadDiscUnion&& x) noexcept -{ - m__d = x.m__d; - - switch(m__d) - { - case 0: - m_first = x.m_first; - break; - - - case 1: - m_second = x.m_second; - break; - - default: - break; - } - - return *this; -} - -bool SimpleBadDiscUnion::operator ==( - const SimpleBadDiscUnion& x) const -{ - if (m__d != x.m__d) - { - return false; - } - - switch(m__d) - { - case 0: - return (m_first == x.m_first); - break; - - - case 1: - return (m_second == x.m_second); - break; - - default: - break; - } - return false; -} - -bool SimpleBadDiscUnion::operator !=( - const SimpleBadDiscUnion& x) const -{ - return !(*this == x); -} - -void SimpleBadDiscUnion::_d( - uint8_t __d) -{ - bool b = false; - - switch(m__d) - { - case 0: - switch(__d) - { - case 0: - b = true; - break; - default: - break; - } - break; - - - case 1: - switch(__d) - { - case 1: - b = true; - break; - default: - break; - } - break; - - } - - if(!b) - { - throw BadParamException("Discriminator doesn't correspond with the selected union member"); - } - - m__d = __d; -} - -uint8_t SimpleBadDiscUnion::_d() const -{ - return m__d; -} - -uint8_t& SimpleBadDiscUnion::_d() -{ - return m__d; -} - -void SimpleBadDiscUnion::first( - int32_t _first) -{ - m_first = _first; - m__d = 0; - -} - -int32_t SimpleBadDiscUnion::first() const -{ - bool b = false; - - switch(m__d) - { - case 0: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first; -} - -int32_t& SimpleBadDiscUnion::first() -{ - bool b = false; - - switch(m__d) - { - case 0: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first; -} - - -void SimpleBadDiscUnion::second( - int64_t _second) -{ - m_second = _second; - m__d = 1; - -} - -int64_t SimpleBadDiscUnion::second() const -{ - bool b = false; - - switch(m__d) - { - case 1: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second; -} - -int64_t& SimpleBadDiscUnion::second() -{ - bool b = false; - - switch(m__d) - { - case 1: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second; -} - - -// TODO(Ricardo) Review -size_t SimpleBadDiscUnion::getCdrSerializedSize( - const SimpleBadDiscUnion& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - - switch(data.m__d) - { - case 0: - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - break; - - - case 1: - current_alignment += 8 + eprosima::fastcdr::Cdr::alignment(current_alignment, 8); - - break; - - default: - break; - } - - return current_alignment - initial_alignment; -} - - -void SimpleBadDiscUnion::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m__d; - - switch(m__d) - { - case 0: - scdr << m_first; - - break; - - - case 1: - scdr << m_second; - - break; - - default: - break; - } -} - -void SimpleBadDiscUnion::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m__d; - - - switch(m__d) - { - case 0: - dcdr >> m_first; - - - break; - - - case 1: - dcdr >> m_second; - - - break; - - default: - break; - } -} - - - - - -SimpleUnionStruct::SimpleUnionStruct() -{ - // SimpleUnion m_my_union - - - // Just to register all known types - registerTypesTypes(); -} - -SimpleUnionStruct::~SimpleUnionStruct() -{ -} - -SimpleUnionStruct::SimpleUnionStruct( - const SimpleUnionStruct& x) -{ - m_my_union = x.m_my_union; - -} - -SimpleUnionStruct::SimpleUnionStruct( - SimpleUnionStruct&& x) noexcept -{ - m_my_union = std::move(x.m_my_union); - -} - -SimpleUnionStruct& SimpleUnionStruct::operator =( - const SimpleUnionStruct& x) -{ - m_my_union = x.m_my_union; - - return *this; -} - -SimpleUnionStruct& SimpleUnionStruct::operator =( - SimpleUnionStruct&& x) noexcept -{ - m_my_union = std::move(x.m_my_union); - - return *this; -} - -bool SimpleUnionStruct::operator ==( - const SimpleUnionStruct& x) const -{ - return (m_my_union == x.m_my_union); -} - -bool SimpleUnionStruct::operator !=( - const SimpleUnionStruct& x) const -{ - return !(*this == x); -} - -size_t SimpleUnionStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return SimpleUnionStruct_max_cdr_typesize; -} - -size_t SimpleUnionStruct::getCdrSerializedSize( - const SimpleUnionStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += SimpleUnion::getCdrSerializedSize(data.my_union(), current_alignment); - - - return current_alignment - initial_alignment; -} - - -void SimpleUnionStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_union; - -} - -void SimpleUnionStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_union; - - -} - - -bool SimpleUnionStruct::isKeyDefined() -{ - return false; -} - -void SimpleUnionStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ -void SimpleUnionStruct::my_union( - const SimpleUnion& _my_union) -{ - m_my_union = _my_union; -} - -/*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ -void SimpleUnionStruct::my_union( - SimpleUnion&& _my_union) -{ - m_my_union = std::move(_my_union); -} - -/*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ -const SimpleUnion& SimpleUnionStruct::my_union() const -{ - return m_my_union; -} - -/*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ -SimpleUnion& SimpleUnionStruct::my_union() -{ - return m_my_union; -} - - - - - -SimpleUnionStructEqual::SimpleUnionStructEqual() -{ - // SimpleUnion m_my_union_equal - - - // Just to register all known types - registerTypesTypes(); -} - -SimpleUnionStructEqual::~SimpleUnionStructEqual() -{ -} - -SimpleUnionStructEqual::SimpleUnionStructEqual( - const SimpleUnionStructEqual& x) -{ - m_my_union_equal = x.m_my_union_equal; - -} - -SimpleUnionStructEqual::SimpleUnionStructEqual( - SimpleUnionStructEqual&& x) noexcept -{ - m_my_union_equal = std::move(x.m_my_union_equal); - -} - -SimpleUnionStructEqual& SimpleUnionStructEqual::operator =( - const SimpleUnionStructEqual& x) -{ - m_my_union_equal = x.m_my_union_equal; - - return *this; -} - -SimpleUnionStructEqual& SimpleUnionStructEqual::operator =( - SimpleUnionStructEqual&& x) noexcept -{ - m_my_union_equal = std::move(x.m_my_union_equal); - - return *this; -} - -bool SimpleUnionStructEqual::operator ==( - const SimpleUnionStructEqual& x) const -{ - return (m_my_union_equal == x.m_my_union_equal); -} - -bool SimpleUnionStructEqual::operator !=( - const SimpleUnionStructEqual& x) const -{ - return !(*this == x); -} - -size_t SimpleUnionStructEqual::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return SimpleUnionStructEqual_max_cdr_typesize; -} - -size_t SimpleUnionStructEqual::getCdrSerializedSize( - const SimpleUnionStructEqual& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += SimpleUnion::getCdrSerializedSize(data.my_union_equal(), current_alignment); - - - return current_alignment - initial_alignment; -} - - -void SimpleUnionStructEqual::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_union_equal; - -} - -void SimpleUnionStructEqual::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_union_equal; - - -} - - -bool SimpleUnionStructEqual::isKeyDefined() -{ - return false; -} - -void SimpleUnionStructEqual::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_union_equal - * @param _my_union_equal New value to be copied in member my_union_equal - */ -void SimpleUnionStructEqual::my_union_equal( - const SimpleUnion& _my_union_equal) -{ - m_my_union_equal = _my_union_equal; -} - -/*! - * @brief This function moves the value in member my_union_equal - * @param _my_union_equal New value to be moved in member my_union_equal - */ -void SimpleUnionStructEqual::my_union_equal( - SimpleUnion&& _my_union_equal) -{ - m_my_union_equal = std::move(_my_union_equal); -} - -/*! - * @brief This function returns a constant reference to member my_union_equal - * @return Constant reference to member my_union_equal - */ -const SimpleUnion& SimpleUnionStructEqual::my_union_equal() const -{ - return m_my_union_equal; -} - -/*! - * @brief This function returns a reference to member my_union_equal - * @return Reference to member my_union_equal - */ -SimpleUnion& SimpleUnionStructEqual::my_union_equal() -{ - return m_my_union_equal; -} - - - - - -SimpleUnionNamesStruct::SimpleUnionNamesStruct() -{ - // SimpleUnionNames m_my_union - - - // Just to register all known types - registerTypesTypes(); -} - -SimpleUnionNamesStruct::~SimpleUnionNamesStruct() -{ -} - -SimpleUnionNamesStruct::SimpleUnionNamesStruct( - const SimpleUnionNamesStruct& x) -{ - m_my_union = x.m_my_union; - -} - -SimpleUnionNamesStruct::SimpleUnionNamesStruct( - SimpleUnionNamesStruct&& x) noexcept -{ - m_my_union = std::move(x.m_my_union); - -} - -SimpleUnionNamesStruct& SimpleUnionNamesStruct::operator =( - const SimpleUnionNamesStruct& x) -{ - m_my_union = x.m_my_union; - - return *this; -} - -SimpleUnionNamesStruct& SimpleUnionNamesStruct::operator =( - SimpleUnionNamesStruct&& x) noexcept -{ - m_my_union = std::move(x.m_my_union); - - return *this; -} - -bool SimpleUnionNamesStruct::operator ==( - const SimpleUnionNamesStruct& x) const -{ - return (m_my_union == x.m_my_union); -} - -bool SimpleUnionNamesStruct::operator !=( - const SimpleUnionNamesStruct& x) const -{ - return !(*this == x); -} - -size_t SimpleUnionNamesStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return SimpleUnionNamesStruct_max_cdr_typesize; -} - -size_t SimpleUnionNamesStruct::getCdrSerializedSize( - const SimpleUnionNamesStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += SimpleUnionNames::getCdrSerializedSize(data.my_union(), current_alignment); - - - return current_alignment - initial_alignment; -} - - -void SimpleUnionNamesStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_union; - -} - -void SimpleUnionNamesStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_union; - - -} - - -bool SimpleUnionNamesStruct::isKeyDefined() -{ - return false; -} - -void SimpleUnionNamesStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ -void SimpleUnionNamesStruct::my_union( - const SimpleUnionNames& _my_union) -{ - m_my_union = _my_union; -} - -/*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ -void SimpleUnionNamesStruct::my_union( - SimpleUnionNames&& _my_union) -{ - m_my_union = std::move(_my_union); -} - -/*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ -const SimpleUnionNames& SimpleUnionNamesStruct::my_union() const -{ - return m_my_union; -} - -/*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ -SimpleUnionNames& SimpleUnionNamesStruct::my_union() -{ - return m_my_union; -} - - - - - -SimpleTypeUnionStruct::SimpleTypeUnionStruct() -{ - // SimpleTypeUnion m_my_union - - - // Just to register all known types - registerTypesTypes(); -} - -SimpleTypeUnionStruct::~SimpleTypeUnionStruct() -{ -} - -SimpleTypeUnionStruct::SimpleTypeUnionStruct( - const SimpleTypeUnionStruct& x) -{ - m_my_union = x.m_my_union; - -} - -SimpleTypeUnionStruct::SimpleTypeUnionStruct( - SimpleTypeUnionStruct&& x) noexcept -{ - m_my_union = std::move(x.m_my_union); - -} - -SimpleTypeUnionStruct& SimpleTypeUnionStruct::operator =( - const SimpleTypeUnionStruct& x) -{ - m_my_union = x.m_my_union; - - return *this; -} - -SimpleTypeUnionStruct& SimpleTypeUnionStruct::operator =( - SimpleTypeUnionStruct&& x) noexcept -{ - m_my_union = std::move(x.m_my_union); - - return *this; -} - -bool SimpleTypeUnionStruct::operator ==( - const SimpleTypeUnionStruct& x) const -{ - return (m_my_union == x.m_my_union); -} - -bool SimpleTypeUnionStruct::operator !=( - const SimpleTypeUnionStruct& x) const -{ - return !(*this == x); -} - -size_t SimpleTypeUnionStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return SimpleTypeUnionStruct_max_cdr_typesize; -} - -size_t SimpleTypeUnionStruct::getCdrSerializedSize( - const SimpleTypeUnionStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += SimpleTypeUnion::getCdrSerializedSize(data.my_union(), current_alignment); - - - return current_alignment - initial_alignment; -} - - -void SimpleTypeUnionStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_union; - -} - -void SimpleTypeUnionStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_union; - - -} - - -bool SimpleTypeUnionStruct::isKeyDefined() -{ - return false; -} - -void SimpleTypeUnionStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ -void SimpleTypeUnionStruct::my_union( - const SimpleTypeUnion& _my_union) -{ - m_my_union = _my_union; -} - -/*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ -void SimpleTypeUnionStruct::my_union( - SimpleTypeUnion&& _my_union) -{ - m_my_union = std::move(_my_union); -} - -/*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ -const SimpleTypeUnion& SimpleTypeUnionStruct::my_union() const -{ - return m_my_union; -} - -/*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ -SimpleTypeUnion& SimpleTypeUnionStruct::my_union() -{ - return m_my_union; -} - - - - - -SimpleBadUnionStruct::SimpleBadUnionStruct() -{ - // SimpleBadUnion m_my_union - - - // Just to register all known types - registerTypesTypes(); -} - -SimpleBadUnionStruct::~SimpleBadUnionStruct() -{ -} - -SimpleBadUnionStruct::SimpleBadUnionStruct( - const SimpleBadUnionStruct& x) -{ - m_my_union = x.m_my_union; - -} - -SimpleBadUnionStruct::SimpleBadUnionStruct( - SimpleBadUnionStruct&& x) noexcept -{ - m_my_union = std::move(x.m_my_union); - -} - -SimpleBadUnionStruct& SimpleBadUnionStruct::operator =( - const SimpleBadUnionStruct& x) -{ - m_my_union = x.m_my_union; - - return *this; -} - -SimpleBadUnionStruct& SimpleBadUnionStruct::operator =( - SimpleBadUnionStruct&& x) noexcept -{ - m_my_union = std::move(x.m_my_union); - - return *this; -} - -bool SimpleBadUnionStruct::operator ==( - const SimpleBadUnionStruct& x) const -{ - return (m_my_union == x.m_my_union); -} - -bool SimpleBadUnionStruct::operator !=( - const SimpleBadUnionStruct& x) const -{ - return !(*this == x); -} - -size_t SimpleBadUnionStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return SimpleBadUnionStruct_max_cdr_typesize; -} - -size_t SimpleBadUnionStruct::getCdrSerializedSize( - const SimpleBadUnionStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += SimpleBadUnion::getCdrSerializedSize(data.my_union(), current_alignment); - - - return current_alignment - initial_alignment; -} - - -void SimpleBadUnionStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_union; - -} - -void SimpleBadUnionStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_union; - - -} - - -bool SimpleBadUnionStruct::isKeyDefined() -{ - return false; -} - -void SimpleBadUnionStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ -void SimpleBadUnionStruct::my_union( - const SimpleBadUnion& _my_union) -{ - m_my_union = _my_union; -} - -/*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ -void SimpleBadUnionStruct::my_union( - SimpleBadUnion&& _my_union) -{ - m_my_union = std::move(_my_union); -} - -/*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ -const SimpleBadUnion& SimpleBadUnionStruct::my_union() const -{ - return m_my_union; -} - -/*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ -SimpleBadUnion& SimpleBadUnionStruct::my_union() -{ - return m_my_union; -} - - - - - -SimplBadDiscUnionStruct::SimplBadDiscUnionStruct() -{ - // SimpleBadDiscUnion m_my_union - - - // Just to register all known types - registerTypesTypes(); -} - -SimplBadDiscUnionStruct::~SimplBadDiscUnionStruct() -{ -} - -SimplBadDiscUnionStruct::SimplBadDiscUnionStruct( - const SimplBadDiscUnionStruct& x) -{ - m_my_union = x.m_my_union; - -} - -SimplBadDiscUnionStruct::SimplBadDiscUnionStruct( - SimplBadDiscUnionStruct&& x) noexcept -{ - m_my_union = std::move(x.m_my_union); - -} - -SimplBadDiscUnionStruct& SimplBadDiscUnionStruct::operator =( - const SimplBadDiscUnionStruct& x) -{ - m_my_union = x.m_my_union; - - return *this; -} - -SimplBadDiscUnionStruct& SimplBadDiscUnionStruct::operator =( - SimplBadDiscUnionStruct&& x) noexcept -{ - m_my_union = std::move(x.m_my_union); - - return *this; -} - -bool SimplBadDiscUnionStruct::operator ==( - const SimplBadDiscUnionStruct& x) const -{ - return (m_my_union == x.m_my_union); -} - -bool SimplBadDiscUnionStruct::operator !=( - const SimplBadDiscUnionStruct& x) const -{ - return !(*this == x); -} - -size_t SimplBadDiscUnionStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return SimplBadDiscUnionStruct_max_cdr_typesize; -} - -size_t SimplBadDiscUnionStruct::getCdrSerializedSize( - const SimplBadDiscUnionStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += SimpleBadDiscUnion::getCdrSerializedSize(data.my_union(), current_alignment); - - - return current_alignment - initial_alignment; -} - - -void SimplBadDiscUnionStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_union; - -} - -void SimplBadDiscUnionStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_union; - - -} - - -bool SimplBadDiscUnionStruct::isKeyDefined() -{ - return false; -} - -void SimplBadDiscUnionStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ -void SimplBadDiscUnionStruct::my_union( - const SimpleBadDiscUnion& _my_union) -{ - m_my_union = _my_union; -} - -/*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ -void SimplBadDiscUnionStruct::my_union( - SimpleBadDiscUnion&& _my_union) -{ - m_my_union = std::move(_my_union); -} - -/*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ -const SimpleBadDiscUnion& SimplBadDiscUnionStruct::my_union() const -{ - return m_my_union; -} - -/*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ -SimpleBadDiscUnion& SimplBadDiscUnionStruct::my_union() -{ - return m_my_union; -} - - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/test/unittest/xtypes/idl/Typesv1.h b/test/unittest/xtypes/idl/Typesv1.h deleted file mode 100644 index d350f662843..00000000000 --- a/test/unittest/xtypes/idl/Typesv1.h +++ /dev/null @@ -1,6496 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file Types.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#include - -#if FASTCDR_VERSION_MAJOR == 1 - -#ifndef _FAST_DDS_GENERATED_TYPES_H_ -#define _FAST_DDS_GENERATED_TYPES_H_ - - -#include - -#include -#include -#include -#include -#include -#include -#include - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define eProsima_user_DllExport -#endif // _WIN32 - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(TYPES_SOURCE) -#define TYPES_DllAPI __declspec( dllexport ) -#else -#define TYPES_DllAPI __declspec( dllimport ) -#endif // TYPES_SOURCE -#else -#define TYPES_DllAPI -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define TYPES_DllAPI -#endif // _WIN32 - -namespace eprosima { -namespace fastcdr { -class Cdr; -} // namespace fastcdr -} // namespace eprosima - - - -/*! - * @brief This class represents the enumeration MyEnum defined by the user in the IDL file. - * @ingroup Types - */ -enum MyEnum : uint32_t -{ - A, - B, - C -}; -/*! - * @brief This class represents the enumeration MyBadEnum defined by the user in the IDL file. - * @ingroup Types - */ -enum MyBadEnum : uint32_t -{ - A1, - B1, - C1 -}; - - -/*! - * @brief This class represents the structure MyEnumStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MyEnumStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MyEnumStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MyEnumStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MyEnumStruct that will be copied. - */ - eProsima_user_DllExport MyEnumStruct( - const MyEnumStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MyEnumStruct that will be copied. - */ - eProsima_user_DllExport MyEnumStruct( - MyEnumStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MyEnumStruct that will be copied. - */ - eProsima_user_DllExport MyEnumStruct& operator =( - const MyEnumStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MyEnumStruct that will be copied. - */ - eProsima_user_DllExport MyEnumStruct& operator =( - MyEnumStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MyEnumStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MyEnumStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x MyEnumStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MyEnumStruct& x) const; - - /*! - * @brief This function sets a value in member my_enum - * @param _my_enum New value for member my_enum - */ - eProsima_user_DllExport void my_enum( - MyEnum _my_enum); - - /*! - * @brief This function returns the value of member my_enum - * @return Value of member my_enum - */ - eProsima_user_DllExport MyEnum my_enum() const; - - /*! - * @brief This function returns a reference to member my_enum - * @return Reference to member my_enum - */ - eProsima_user_DllExport MyEnum& my_enum(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const MyEnumStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - MyEnum m_my_enum; - -}; - - - -/*! - * @brief This class represents the structure MyBadEnumStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MyBadEnumStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MyBadEnumStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MyBadEnumStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MyBadEnumStruct that will be copied. - */ - eProsima_user_DllExport MyBadEnumStruct( - const MyBadEnumStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MyBadEnumStruct that will be copied. - */ - eProsima_user_DllExport MyBadEnumStruct( - MyBadEnumStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MyBadEnumStruct that will be copied. - */ - eProsima_user_DllExport MyBadEnumStruct& operator =( - const MyBadEnumStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MyBadEnumStruct that will be copied. - */ - eProsima_user_DllExport MyBadEnumStruct& operator =( - MyBadEnumStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MyBadEnumStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MyBadEnumStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x MyBadEnumStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MyBadEnumStruct& x) const; - - /*! - * @brief This function sets a value in member my_enum - * @param _my_enum New value for member my_enum - */ - eProsima_user_DllExport void my_enum( - MyBadEnum _my_enum); - - /*! - * @brief This function returns the value of member my_enum - * @return Value of member my_enum - */ - eProsima_user_DllExport MyBadEnum my_enum() const; - - /*! - * @brief This function returns a reference to member my_enum - * @return Reference to member my_enum - */ - eProsima_user_DllExport MyBadEnum& my_enum(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const MyBadEnumStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - MyBadEnum m_my_enum; - -}; - -typedef MyEnum MyAliasEnum; - - - -/*! - * @brief This class represents the structure MyAliasEnumStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MyAliasEnumStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MyAliasEnumStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MyAliasEnumStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MyAliasEnumStruct that will be copied. - */ - eProsima_user_DllExport MyAliasEnumStruct( - const MyAliasEnumStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MyAliasEnumStruct that will be copied. - */ - eProsima_user_DllExport MyAliasEnumStruct( - MyAliasEnumStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MyAliasEnumStruct that will be copied. - */ - eProsima_user_DllExport MyAliasEnumStruct& operator =( - const MyAliasEnumStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MyAliasEnumStruct that will be copied. - */ - eProsima_user_DllExport MyAliasEnumStruct& operator =( - MyAliasEnumStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MyAliasEnumStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MyAliasEnumStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x MyAliasEnumStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MyAliasEnumStruct& x) const; - - /*! - * @brief This function sets a value in member my_enum - * @param _my_enum New value for member my_enum - */ - eProsima_user_DllExport void my_enum( - MyAliasEnum _my_enum); - - /*! - * @brief This function returns the value of member my_enum - * @return Value of member my_enum - */ - eProsima_user_DllExport MyAliasEnum my_enum() const; - - /*! - * @brief This function returns a reference to member my_enum - * @return Reference to member my_enum - */ - eProsima_user_DllExport MyAliasEnum& my_enum(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const MyAliasEnumStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - MyAliasEnum m_my_enum; - -}; - - - -/*! - * @brief This class represents the structure BasicStruct defined by the user in the IDL file. - * @ingroup Types - */ -class BasicStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport BasicStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~BasicStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object BasicStruct that will be copied. - */ - eProsima_user_DllExport BasicStruct( - const BasicStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object BasicStruct that will be copied. - */ - eProsima_user_DllExport BasicStruct( - BasicStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object BasicStruct that will be copied. - */ - eProsima_user_DllExport BasicStruct& operator =( - const BasicStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object BasicStruct that will be copied. - */ - eProsima_user_DllExport BasicStruct& operator =( - BasicStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x BasicStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const BasicStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x BasicStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const BasicStruct& x) const; - - /*! - * @brief This function sets a value in member my_bool - * @param _my_bool New value for member my_bool - */ - eProsima_user_DllExport void my_bool( - bool _my_bool); - - /*! - * @brief This function returns the value of member my_bool - * @return Value of member my_bool - */ - eProsima_user_DllExport bool my_bool() const; - - /*! - * @brief This function returns a reference to member my_bool - * @return Reference to member my_bool - */ - eProsima_user_DllExport bool& my_bool(); - - - /*! - * @brief This function sets a value in member my_int32 - * @param _my_int32 New value for member my_int32 - */ - eProsima_user_DllExport void my_int32( - int32_t _my_int32); - - /*! - * @brief This function returns the value of member my_int32 - * @return Value of member my_int32 - */ - eProsima_user_DllExport int32_t my_int32() const; - - /*! - * @brief This function returns a reference to member my_int32 - * @return Reference to member my_int32 - */ - eProsima_user_DllExport int32_t& my_int32(); - - - /*! - * @brief This function copies the value in member my_string - * @param _my_string New value to be copied in member my_string - */ - eProsima_user_DllExport void my_string( - const std::string& _my_string); - - /*! - * @brief This function moves the value in member my_string - * @param _my_string New value to be moved in member my_string - */ - eProsima_user_DllExport void my_string( - std::string&& _my_string); - - /*! - * @brief This function returns a constant reference to member my_string - * @return Constant reference to member my_string - */ - eProsima_user_DllExport const std::string& my_string() const; - - /*! - * @brief This function returns a reference to member my_string - * @return Reference to member my_string - */ - eProsima_user_DllExport std::string& my_string(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const BasicStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - bool m_my_bool; - int32_t m_my_int32; - std::string m_my_string; - -}; - - - -/*! - * @brief This class represents the structure BasicNamesStruct defined by the user in the IDL file. - * @ingroup Types - */ -class BasicNamesStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport BasicNamesStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~BasicNamesStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object BasicNamesStruct that will be copied. - */ - eProsima_user_DllExport BasicNamesStruct( - const BasicNamesStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object BasicNamesStruct that will be copied. - */ - eProsima_user_DllExport BasicNamesStruct( - BasicNamesStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object BasicNamesStruct that will be copied. - */ - eProsima_user_DllExport BasicNamesStruct& operator =( - const BasicNamesStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object BasicNamesStruct that will be copied. - */ - eProsima_user_DllExport BasicNamesStruct& operator =( - BasicNamesStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x BasicNamesStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const BasicNamesStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x BasicNamesStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const BasicNamesStruct& x) const; - - /*! - * @brief This function sets a value in member my_bool_name - * @param _my_bool_name New value for member my_bool_name - */ - eProsima_user_DllExport void my_bool_name( - bool _my_bool_name); - - /*! - * @brief This function returns the value of member my_bool_name - * @return Value of member my_bool_name - */ - eProsima_user_DllExport bool my_bool_name() const; - - /*! - * @brief This function returns a reference to member my_bool_name - * @return Reference to member my_bool_name - */ - eProsima_user_DllExport bool& my_bool_name(); - - - /*! - * @brief This function sets a value in member my_int32_name - * @param _my_int32_name New value for member my_int32_name - */ - eProsima_user_DllExport void my_int32_name( - int32_t _my_int32_name); - - /*! - * @brief This function returns the value of member my_int32_name - * @return Value of member my_int32_name - */ - eProsima_user_DllExport int32_t my_int32_name() const; - - /*! - * @brief This function returns a reference to member my_int32_name - * @return Reference to member my_int32_name - */ - eProsima_user_DllExport int32_t& my_int32_name(); - - - /*! - * @brief This function copies the value in member my_string_name - * @param _my_string_name New value to be copied in member my_string_name - */ - eProsima_user_DllExport void my_string_name( - const std::string& _my_string_name); - - /*! - * @brief This function moves the value in member my_string_name - * @param _my_string_name New value to be moved in member my_string_name - */ - eProsima_user_DllExport void my_string_name( - std::string&& _my_string_name); - - /*! - * @brief This function returns a constant reference to member my_string_name - * @return Constant reference to member my_string_name - */ - eProsima_user_DllExport const std::string& my_string_name() const; - - /*! - * @brief This function returns a reference to member my_string_name - * @return Reference to member my_string_name - */ - eProsima_user_DllExport std::string& my_string_name(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const BasicNamesStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - bool m_my_bool_name; - int32_t m_my_int32_name; - std::string m_my_string_name; - -}; - - - -/*! - * @brief This class represents the structure BasicBadStruct defined by the user in the IDL file. - * @ingroup Types - */ -class BasicBadStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport BasicBadStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~BasicBadStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object BasicBadStruct that will be copied. - */ - eProsima_user_DllExport BasicBadStruct( - const BasicBadStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object BasicBadStruct that will be copied. - */ - eProsima_user_DllExport BasicBadStruct( - BasicBadStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object BasicBadStruct that will be copied. - */ - eProsima_user_DllExport BasicBadStruct& operator =( - const BasicBadStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object BasicBadStruct that will be copied. - */ - eProsima_user_DllExport BasicBadStruct& operator =( - BasicBadStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x BasicBadStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const BasicBadStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x BasicBadStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const BasicBadStruct& x) const; - - /*! - * @brief This function sets a value in member my_bool - * @param _my_bool New value for member my_bool - */ - eProsima_user_DllExport void my_bool( - uint8_t _my_bool); - - /*! - * @brief This function returns the value of member my_bool - * @return Value of member my_bool - */ - eProsima_user_DllExport uint8_t my_bool() const; - - /*! - * @brief This function returns a reference to member my_bool - * @return Reference to member my_bool - */ - eProsima_user_DllExport uint8_t& my_bool(); - - - /*! - * @brief This function sets a value in member my_int32 - * @param _my_int32 New value for member my_int32 - */ - eProsima_user_DllExport void my_int32( - int32_t _my_int32); - - /*! - * @brief This function returns the value of member my_int32 - * @return Value of member my_int32 - */ - eProsima_user_DllExport int32_t my_int32() const; - - /*! - * @brief This function returns a reference to member my_int32 - * @return Reference to member my_int32 - */ - eProsima_user_DllExport int32_t& my_int32(); - - - /*! - * @brief This function copies the value in member my_string - * @param _my_string New value to be copied in member my_string - */ - eProsima_user_DllExport void my_string( - const std::string& _my_string); - - /*! - * @brief This function moves the value in member my_string - * @param _my_string New value to be moved in member my_string - */ - eProsima_user_DllExport void my_string( - std::string&& _my_string); - - /*! - * @brief This function returns a constant reference to member my_string - * @return Constant reference to member my_string - */ - eProsima_user_DllExport const std::string& my_string() const; - - /*! - * @brief This function returns a reference to member my_string - * @return Reference to member my_string - */ - eProsima_user_DllExport std::string& my_string(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const BasicBadStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - uint8_t m_my_bool; - int32_t m_my_int32; - std::string m_my_string; - -}; - - - -/*! - * @brief This class represents the structure BasicWideStruct defined by the user in the IDL file. - * @ingroup Types - */ -class BasicWideStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport BasicWideStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~BasicWideStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object BasicWideStruct that will be copied. - */ - eProsima_user_DllExport BasicWideStruct( - const BasicWideStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object BasicWideStruct that will be copied. - */ - eProsima_user_DllExport BasicWideStruct( - BasicWideStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object BasicWideStruct that will be copied. - */ - eProsima_user_DllExport BasicWideStruct& operator =( - const BasicWideStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object BasicWideStruct that will be copied. - */ - eProsima_user_DllExport BasicWideStruct& operator =( - BasicWideStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x BasicWideStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const BasicWideStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x BasicWideStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const BasicWideStruct& x) const; - - /*! - * @brief This function sets a value in member my_bool - * @param _my_bool New value for member my_bool - */ - eProsima_user_DllExport void my_bool( - bool _my_bool); - - /*! - * @brief This function returns the value of member my_bool - * @return Value of member my_bool - */ - eProsima_user_DllExport bool my_bool() const; - - /*! - * @brief This function returns a reference to member my_bool - * @return Reference to member my_bool - */ - eProsima_user_DllExport bool& my_bool(); - - - /*! - * @brief This function sets a value in member my_int32 - * @param _my_int32 New value for member my_int32 - */ - eProsima_user_DllExport void my_int32( - int32_t _my_int32); - - /*! - * @brief This function returns the value of member my_int32 - * @return Value of member my_int32 - */ - eProsima_user_DllExport int32_t my_int32() const; - - /*! - * @brief This function returns a reference to member my_int32 - * @return Reference to member my_int32 - */ - eProsima_user_DllExport int32_t& my_int32(); - - - /*! - * @brief This function copies the value in member my_string - * @param _my_string New value to be copied in member my_string - */ - eProsima_user_DllExport void my_string( - const std::string& _my_string); - - /*! - * @brief This function moves the value in member my_string - * @param _my_string New value to be moved in member my_string - */ - eProsima_user_DllExport void my_string( - std::string&& _my_string); - - /*! - * @brief This function returns a constant reference to member my_string - * @return Constant reference to member my_string - */ - eProsima_user_DllExport const std::string& my_string() const; - - /*! - * @brief This function returns a reference to member my_string - * @return Reference to member my_string - */ - eProsima_user_DllExport std::string& my_string(); - - - /*! - * @brief This function sets a value in member new_int32 - * @param _new_int32 New value for member new_int32 - */ - eProsima_user_DllExport void new_int32( - int32_t _new_int32); - - /*! - * @brief This function returns the value of member new_int32 - * @return Value of member new_int32 - */ - eProsima_user_DllExport int32_t new_int32() const; - - /*! - * @brief This function returns a reference to member new_int32 - * @return Reference to member new_int32 - */ - eProsima_user_DllExport int32_t& new_int32(); - - - /*! - * @brief This function copies the value in member new_string - * @param _new_string New value to be copied in member new_string - */ - eProsima_user_DllExport void new_string( - const std::string& _new_string); - - /*! - * @brief This function moves the value in member new_string - * @param _new_string New value to be moved in member new_string - */ - eProsima_user_DllExport void new_string( - std::string&& _new_string); - - /*! - * @brief This function returns a constant reference to member new_string - * @return Constant reference to member new_string - */ - eProsima_user_DllExport const std::string& new_string() const; - - /*! - * @brief This function returns a reference to member new_string - * @return Reference to member new_string - */ - eProsima_user_DllExport std::string& new_string(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const BasicWideStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - bool m_my_bool; - int32_t m_my_int32; - std::string m_my_string; - int32_t m_new_int32; - std::string m_new_string; - -}; - - - -/*! - * @brief This class represents the structure BadBasicWideStruct defined by the user in the IDL file. - * @ingroup Types - */ -class BadBasicWideStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport BadBasicWideStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~BadBasicWideStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object BadBasicWideStruct that will be copied. - */ - eProsima_user_DllExport BadBasicWideStruct( - const BadBasicWideStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object BadBasicWideStruct that will be copied. - */ - eProsima_user_DllExport BadBasicWideStruct( - BadBasicWideStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object BadBasicWideStruct that will be copied. - */ - eProsima_user_DllExport BadBasicWideStruct& operator =( - const BadBasicWideStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object BadBasicWideStruct that will be copied. - */ - eProsima_user_DllExport BadBasicWideStruct& operator =( - BadBasicWideStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x BadBasicWideStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const BadBasicWideStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x BadBasicWideStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const BadBasicWideStruct& x) const; - - /*! - * @brief This function sets a value in member new_int32 - * @param _new_int32 New value for member new_int32 - */ - eProsima_user_DllExport void new_int32( - int32_t _new_int32); - - /*! - * @brief This function returns the value of member new_int32 - * @return Value of member new_int32 - */ - eProsima_user_DllExport int32_t new_int32() const; - - /*! - * @brief This function returns a reference to member new_int32 - * @return Reference to member new_int32 - */ - eProsima_user_DllExport int32_t& new_int32(); - - - /*! - * @brief This function copies the value in member new_string - * @param _new_string New value to be copied in member new_string - */ - eProsima_user_DllExport void new_string( - const std::string& _new_string); - - /*! - * @brief This function moves the value in member new_string - * @param _new_string New value to be moved in member new_string - */ - eProsima_user_DllExport void new_string( - std::string&& _new_string); - - /*! - * @brief This function returns a constant reference to member new_string - * @return Constant reference to member new_string - */ - eProsima_user_DllExport const std::string& new_string() const; - - /*! - * @brief This function returns a reference to member new_string - * @return Reference to member new_string - */ - eProsima_user_DllExport std::string& new_string(); - - - /*! - * @brief This function sets a value in member my_bool - * @param _my_bool New value for member my_bool - */ - eProsima_user_DllExport void my_bool( - bool _my_bool); - - /*! - * @brief This function returns the value of member my_bool - * @return Value of member my_bool - */ - eProsima_user_DllExport bool my_bool() const; - - /*! - * @brief This function returns a reference to member my_bool - * @return Reference to member my_bool - */ - eProsima_user_DllExport bool& my_bool(); - - - /*! - * @brief This function sets a value in member my_int32 - * @param _my_int32 New value for member my_int32 - */ - eProsima_user_DllExport void my_int32( - int32_t _my_int32); - - /*! - * @brief This function returns the value of member my_int32 - * @return Value of member my_int32 - */ - eProsima_user_DllExport int32_t my_int32() const; - - /*! - * @brief This function returns a reference to member my_int32 - * @return Reference to member my_int32 - */ - eProsima_user_DllExport int32_t& my_int32(); - - - /*! - * @brief This function copies the value in member my_string - * @param _my_string New value to be copied in member my_string - */ - eProsima_user_DllExport void my_string( - const std::string& _my_string); - - /*! - * @brief This function moves the value in member my_string - * @param _my_string New value to be moved in member my_string - */ - eProsima_user_DllExport void my_string( - std::string&& _my_string); - - /*! - * @brief This function returns a constant reference to member my_string - * @return Constant reference to member my_string - */ - eProsima_user_DllExport const std::string& my_string() const; - - /*! - * @brief This function returns a reference to member my_string - * @return Reference to member my_string - */ - eProsima_user_DllExport std::string& my_string(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const BadBasicWideStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - int32_t m_new_int32; - std::string m_new_string; - bool m_my_bool; - int32_t m_my_int32; - std::string m_my_string; - -}; - - - -/*! - * @brief This class represents the structure StringStruct defined by the user in the IDL file. - * @ingroup Types - */ -class StringStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport StringStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~StringStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object StringStruct that will be copied. - */ - eProsima_user_DllExport StringStruct( - const StringStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object StringStruct that will be copied. - */ - eProsima_user_DllExport StringStruct( - StringStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object StringStruct that will be copied. - */ - eProsima_user_DllExport StringStruct& operator =( - const StringStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object StringStruct that will be copied. - */ - eProsima_user_DllExport StringStruct& operator =( - StringStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x StringStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const StringStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x StringStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const StringStruct& x) const; - - /*! - * @brief This function copies the value in member my_string - * @param _my_string New value to be copied in member my_string - */ - eProsima_user_DllExport void my_string( - const std::string& _my_string); - - /*! - * @brief This function moves the value in member my_string - * @param _my_string New value to be moved in member my_string - */ - eProsima_user_DllExport void my_string( - std::string&& _my_string); - - /*! - * @brief This function returns a constant reference to member my_string - * @return Constant reference to member my_string - */ - eProsima_user_DllExport const std::string& my_string() const; - - /*! - * @brief This function returns a reference to member my_string - * @return Reference to member my_string - */ - eProsima_user_DllExport std::string& my_string(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const StringStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::string m_my_string; - -}; - - - -/*! - * @brief This class represents the structure LargeStringStruct defined by the user in the IDL file. - * @ingroup Types - */ -class LargeStringStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport LargeStringStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~LargeStringStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object LargeStringStruct that will be copied. - */ - eProsima_user_DllExport LargeStringStruct( - const LargeStringStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object LargeStringStruct that will be copied. - */ - eProsima_user_DllExport LargeStringStruct( - LargeStringStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object LargeStringStruct that will be copied. - */ - eProsima_user_DllExport LargeStringStruct& operator =( - const LargeStringStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object LargeStringStruct that will be copied. - */ - eProsima_user_DllExport LargeStringStruct& operator =( - LargeStringStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x LargeStringStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const LargeStringStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x LargeStringStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const LargeStringStruct& x) const; - - /*! - * @brief This function copies the value in member my_large_string - * @param _my_large_string New value to be copied in member my_large_string - */ - eProsima_user_DllExport void my_large_string( - const eprosima::fastrtps::fixed_string<41925>& _my_large_string); - - /*! - * @brief This function moves the value in member my_large_string - * @param _my_large_string New value to be moved in member my_large_string - */ - eProsima_user_DllExport void my_large_string( - eprosima::fastrtps::fixed_string<41925>&& _my_large_string); - - /*! - * @brief This function returns a constant reference to member my_large_string - * @return Constant reference to member my_large_string - */ - eProsima_user_DllExport const eprosima::fastrtps::fixed_string<41925>& my_large_string() const; - - /*! - * @brief This function returns a reference to member my_large_string - * @return Reference to member my_large_string - */ - eProsima_user_DllExport eprosima::fastrtps::fixed_string<41925>& my_large_string(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const LargeStringStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - eprosima::fastrtps::fixed_string<41925> m_my_large_string; - -}; - - - -/*! - * @brief This class represents the structure WStringStruct defined by the user in the IDL file. - * @ingroup Types - */ -class WStringStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport WStringStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~WStringStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object WStringStruct that will be copied. - */ - eProsima_user_DllExport WStringStruct( - const WStringStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object WStringStruct that will be copied. - */ - eProsima_user_DllExport WStringStruct( - WStringStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object WStringStruct that will be copied. - */ - eProsima_user_DllExport WStringStruct& operator =( - const WStringStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object WStringStruct that will be copied. - */ - eProsima_user_DllExport WStringStruct& operator =( - WStringStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x WStringStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const WStringStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x WStringStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const WStringStruct& x) const; - - /*! - * @brief This function copies the value in member my_wstring - * @param _my_wstring New value to be copied in member my_wstring - */ - eProsima_user_DllExport void my_wstring( - const std::wstring& _my_wstring); - - /*! - * @brief This function moves the value in member my_wstring - * @param _my_wstring New value to be moved in member my_wstring - */ - eProsima_user_DllExport void my_wstring( - std::wstring&& _my_wstring); - - /*! - * @brief This function returns a constant reference to member my_wstring - * @return Constant reference to member my_wstring - */ - eProsima_user_DllExport const std::wstring& my_wstring() const; - - /*! - * @brief This function returns a reference to member my_wstring - * @return Reference to member my_wstring - */ - eProsima_user_DllExport std::wstring& my_wstring(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const WStringStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::wstring m_my_wstring; - -}; - - - -/*! - * @brief This class represents the structure LargeWStringStruct defined by the user in the IDL file. - * @ingroup Types - */ -class LargeWStringStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport LargeWStringStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~LargeWStringStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object LargeWStringStruct that will be copied. - */ - eProsima_user_DllExport LargeWStringStruct( - const LargeWStringStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object LargeWStringStruct that will be copied. - */ - eProsima_user_DllExport LargeWStringStruct( - LargeWStringStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object LargeWStringStruct that will be copied. - */ - eProsima_user_DllExport LargeWStringStruct& operator =( - const LargeWStringStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object LargeWStringStruct that will be copied. - */ - eProsima_user_DllExport LargeWStringStruct& operator =( - LargeWStringStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x LargeWStringStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const LargeWStringStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x LargeWStringStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const LargeWStringStruct& x) const; - - /*! - * @brief This function copies the value in member my_large_wstring - * @param _my_large_wstring New value to be copied in member my_large_wstring - */ - eProsima_user_DllExport void my_large_wstring( - const std::wstring& _my_large_wstring); - - /*! - * @brief This function moves the value in member my_large_wstring - * @param _my_large_wstring New value to be moved in member my_large_wstring - */ - eProsima_user_DllExport void my_large_wstring( - std::wstring&& _my_large_wstring); - - /*! - * @brief This function returns a constant reference to member my_large_wstring - * @return Constant reference to member my_large_wstring - */ - eProsima_user_DllExport const std::wstring& my_large_wstring() const; - - /*! - * @brief This function returns a reference to member my_large_wstring - * @return Reference to member my_large_wstring - */ - eProsima_user_DllExport std::wstring& my_large_wstring(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const LargeWStringStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::wstring m_my_large_wstring; - -}; - - - -/*! - * @brief This class represents the structure ArrayStruct defined by the user in the IDL file. - * @ingroup Types - */ -class ArrayStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport ArrayStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~ArrayStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object ArrayStruct that will be copied. - */ - eProsima_user_DllExport ArrayStruct( - const ArrayStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object ArrayStruct that will be copied. - */ - eProsima_user_DllExport ArrayStruct( - ArrayStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object ArrayStruct that will be copied. - */ - eProsima_user_DllExport ArrayStruct& operator =( - const ArrayStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object ArrayStruct that will be copied. - */ - eProsima_user_DllExport ArrayStruct& operator =( - ArrayStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x ArrayStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const ArrayStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x ArrayStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const ArrayStruct& x) const; - - /*! - * @brief This function copies the value in member my_array - * @param _my_array New value to be copied in member my_array - */ - eProsima_user_DllExport void my_array( - const std::array& _my_array); - - /*! - * @brief This function moves the value in member my_array - * @param _my_array New value to be moved in member my_array - */ - eProsima_user_DllExport void my_array( - std::array&& _my_array); - - /*! - * @brief This function returns a constant reference to member my_array - * @return Constant reference to member my_array - */ - eProsima_user_DllExport const std::array& my_array() const; - - /*! - * @brief This function returns a reference to member my_array - * @return Reference to member my_array - */ - eProsima_user_DllExport std::array& my_array(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const ArrayStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::array m_my_array; - -}; - - - -/*! - * @brief This class represents the structure ArrayStructEqual defined by the user in the IDL file. - * @ingroup Types - */ -class ArrayStructEqual -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport ArrayStructEqual(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~ArrayStructEqual(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object ArrayStructEqual that will be copied. - */ - eProsima_user_DllExport ArrayStructEqual( - const ArrayStructEqual& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object ArrayStructEqual that will be copied. - */ - eProsima_user_DllExport ArrayStructEqual( - ArrayStructEqual&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object ArrayStructEqual that will be copied. - */ - eProsima_user_DllExport ArrayStructEqual& operator =( - const ArrayStructEqual& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object ArrayStructEqual that will be copied. - */ - eProsima_user_DllExport ArrayStructEqual& operator =( - ArrayStructEqual&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x ArrayStructEqual object to compare. - */ - eProsima_user_DllExport bool operator ==( - const ArrayStructEqual& x) const; - - /*! - * @brief Comparison operator. - * @param x ArrayStructEqual object to compare. - */ - eProsima_user_DllExport bool operator !=( - const ArrayStructEqual& x) const; - - /*! - * @brief This function copies the value in member my_array_equal - * @param _my_array_equal New value to be copied in member my_array_equal - */ - eProsima_user_DllExport void my_array_equal( - const std::array& _my_array_equal); - - /*! - * @brief This function moves the value in member my_array_equal - * @param _my_array_equal New value to be moved in member my_array_equal - */ - eProsima_user_DllExport void my_array_equal( - std::array&& _my_array_equal); - - /*! - * @brief This function returns a constant reference to member my_array_equal - * @return Constant reference to member my_array_equal - */ - eProsima_user_DllExport const std::array& my_array_equal() const; - - /*! - * @brief This function returns a reference to member my_array_equal - * @return Reference to member my_array_equal - */ - eProsima_user_DllExport std::array& my_array_equal(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const ArrayStructEqual& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::array m_my_array_equal; - -}; - - - -/*! - * @brief This class represents the structure ArrayBadStruct defined by the user in the IDL file. - * @ingroup Types - */ -class ArrayBadStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport ArrayBadStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~ArrayBadStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object ArrayBadStruct that will be copied. - */ - eProsima_user_DllExport ArrayBadStruct( - const ArrayBadStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object ArrayBadStruct that will be copied. - */ - eProsima_user_DllExport ArrayBadStruct( - ArrayBadStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object ArrayBadStruct that will be copied. - */ - eProsima_user_DllExport ArrayBadStruct& operator =( - const ArrayBadStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object ArrayBadStruct that will be copied. - */ - eProsima_user_DllExport ArrayBadStruct& operator =( - ArrayBadStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x ArrayBadStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const ArrayBadStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x ArrayBadStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const ArrayBadStruct& x) const; - - /*! - * @brief This function copies the value in member my_array - * @param _my_array New value to be copied in member my_array - */ - eProsima_user_DllExport void my_array( - const std::array& _my_array); - - /*! - * @brief This function moves the value in member my_array - * @param _my_array New value to be moved in member my_array - */ - eProsima_user_DllExport void my_array( - std::array&& _my_array); - - /*! - * @brief This function returns a constant reference to member my_array - * @return Constant reference to member my_array - */ - eProsima_user_DllExport const std::array& my_array() const; - - /*! - * @brief This function returns a reference to member my_array - * @return Reference to member my_array - */ - eProsima_user_DllExport std::array& my_array(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const ArrayBadStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::array m_my_array; - -}; - - - -/*! - * @brief This class represents the structure ArrayDimensionsStruct defined by the user in the IDL file. - * @ingroup Types - */ -class ArrayDimensionsStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport ArrayDimensionsStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~ArrayDimensionsStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object ArrayDimensionsStruct that will be copied. - */ - eProsima_user_DllExport ArrayDimensionsStruct( - const ArrayDimensionsStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object ArrayDimensionsStruct that will be copied. - */ - eProsima_user_DllExport ArrayDimensionsStruct( - ArrayDimensionsStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object ArrayDimensionsStruct that will be copied. - */ - eProsima_user_DllExport ArrayDimensionsStruct& operator =( - const ArrayDimensionsStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object ArrayDimensionsStruct that will be copied. - */ - eProsima_user_DllExport ArrayDimensionsStruct& operator =( - ArrayDimensionsStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x ArrayDimensionsStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const ArrayDimensionsStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x ArrayDimensionsStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const ArrayDimensionsStruct& x) const; - - /*! - * @brief This function copies the value in member my_array - * @param _my_array New value to be copied in member my_array - */ - eProsima_user_DllExport void my_array( - const std::array, 2>& _my_array); - - /*! - * @brief This function moves the value in member my_array - * @param _my_array New value to be moved in member my_array - */ - eProsima_user_DllExport void my_array( - std::array, 2>&& _my_array); - - /*! - * @brief This function returns a constant reference to member my_array - * @return Constant reference to member my_array - */ - eProsima_user_DllExport const std::array, 2>& my_array() const; - - /*! - * @brief This function returns a reference to member my_array - * @return Reference to member my_array - */ - eProsima_user_DllExport std::array, 2>& my_array(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const ArrayDimensionsStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::array, 2> m_my_array; - -}; - - - -/*! - * @brief This class represents the structure ArraySizeStruct defined by the user in the IDL file. - * @ingroup Types - */ -class ArraySizeStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport ArraySizeStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~ArraySizeStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object ArraySizeStruct that will be copied. - */ - eProsima_user_DllExport ArraySizeStruct( - const ArraySizeStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object ArraySizeStruct that will be copied. - */ - eProsima_user_DllExport ArraySizeStruct( - ArraySizeStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object ArraySizeStruct that will be copied. - */ - eProsima_user_DllExport ArraySizeStruct& operator =( - const ArraySizeStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object ArraySizeStruct that will be copied. - */ - eProsima_user_DllExport ArraySizeStruct& operator =( - ArraySizeStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x ArraySizeStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const ArraySizeStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x ArraySizeStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const ArraySizeStruct& x) const; - - /*! - * @brief This function copies the value in member my_array - * @param _my_array New value to be copied in member my_array - */ - eProsima_user_DllExport void my_array( - const std::array& _my_array); - - /*! - * @brief This function moves the value in member my_array - * @param _my_array New value to be moved in member my_array - */ - eProsima_user_DllExport void my_array( - std::array&& _my_array); - - /*! - * @brief This function returns a constant reference to member my_array - * @return Constant reference to member my_array - */ - eProsima_user_DllExport const std::array& my_array() const; - - /*! - * @brief This function returns a reference to member my_array - * @return Reference to member my_array - */ - eProsima_user_DllExport std::array& my_array(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const ArraySizeStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::array m_my_array; - -}; - - - - - -/*! - * @brief This class represents the structure SequenceStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SequenceStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SequenceStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SequenceStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SequenceStruct that will be copied. - */ - eProsima_user_DllExport SequenceStruct( - const SequenceStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SequenceStruct that will be copied. - */ - eProsima_user_DllExport SequenceStruct( - SequenceStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SequenceStruct that will be copied. - */ - eProsima_user_DllExport SequenceStruct& operator =( - const SequenceStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SequenceStruct that will be copied. - */ - eProsima_user_DllExport SequenceStruct& operator =( - SequenceStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SequenceStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SequenceStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x SequenceStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SequenceStruct& x) const; - - /*! - * @brief This function copies the value in member my_sequence - * @param _my_sequence New value to be copied in member my_sequence - */ - eProsima_user_DllExport void my_sequence( - const std::vector& _my_sequence); - - /*! - * @brief This function moves the value in member my_sequence - * @param _my_sequence New value to be moved in member my_sequence - */ - eProsima_user_DllExport void my_sequence( - std::vector&& _my_sequence); - - /*! - * @brief This function returns a constant reference to member my_sequence - * @return Constant reference to member my_sequence - */ - eProsima_user_DllExport const std::vector& my_sequence() const; - - /*! - * @brief This function returns a reference to member my_sequence - * @return Reference to member my_sequence - */ - eProsima_user_DllExport std::vector& my_sequence(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const SequenceStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::vector m_my_sequence; - -}; - - - - - -/*! - * @brief This class represents the structure SequenceStructEqual defined by the user in the IDL file. - * @ingroup Types - */ -class SequenceStructEqual -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SequenceStructEqual(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SequenceStructEqual(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SequenceStructEqual that will be copied. - */ - eProsima_user_DllExport SequenceStructEqual( - const SequenceStructEqual& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SequenceStructEqual that will be copied. - */ - eProsima_user_DllExport SequenceStructEqual( - SequenceStructEqual&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SequenceStructEqual that will be copied. - */ - eProsima_user_DllExport SequenceStructEqual& operator =( - const SequenceStructEqual& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SequenceStructEqual that will be copied. - */ - eProsima_user_DllExport SequenceStructEqual& operator =( - SequenceStructEqual&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SequenceStructEqual object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SequenceStructEqual& x) const; - - /*! - * @brief Comparison operator. - * @param x SequenceStructEqual object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SequenceStructEqual& x) const; - - /*! - * @brief This function copies the value in member my_sequence_equal - * @param _my_sequence_equal New value to be copied in member my_sequence_equal - */ - eProsima_user_DllExport void my_sequence_equal( - const std::vector& _my_sequence_equal); - - /*! - * @brief This function moves the value in member my_sequence_equal - * @param _my_sequence_equal New value to be moved in member my_sequence_equal - */ - eProsima_user_DllExport void my_sequence_equal( - std::vector&& _my_sequence_equal); - - /*! - * @brief This function returns a constant reference to member my_sequence_equal - * @return Constant reference to member my_sequence_equal - */ - eProsima_user_DllExport const std::vector& my_sequence_equal() const; - - /*! - * @brief This function returns a reference to member my_sequence_equal - * @return Reference to member my_sequence_equal - */ - eProsima_user_DllExport std::vector& my_sequence_equal(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const SequenceStructEqual& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::vector m_my_sequence_equal; - -}; - - - - - -/*! - * @brief This class represents the structure SequenceBadStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SequenceBadStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SequenceBadStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SequenceBadStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SequenceBadStruct that will be copied. - */ - eProsima_user_DllExport SequenceBadStruct( - const SequenceBadStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SequenceBadStruct that will be copied. - */ - eProsima_user_DllExport SequenceBadStruct( - SequenceBadStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SequenceBadStruct that will be copied. - */ - eProsima_user_DllExport SequenceBadStruct& operator =( - const SequenceBadStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SequenceBadStruct that will be copied. - */ - eProsima_user_DllExport SequenceBadStruct& operator =( - SequenceBadStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SequenceBadStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SequenceBadStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x SequenceBadStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SequenceBadStruct& x) const; - - /*! - * @brief This function copies the value in member my_sequence - * @param _my_sequence New value to be copied in member my_sequence - */ - eProsima_user_DllExport void my_sequence( - const std::vector& _my_sequence); - - /*! - * @brief This function moves the value in member my_sequence - * @param _my_sequence New value to be moved in member my_sequence - */ - eProsima_user_DllExport void my_sequence( - std::vector&& _my_sequence); - - /*! - * @brief This function returns a constant reference to member my_sequence - * @return Constant reference to member my_sequence - */ - eProsima_user_DllExport const std::vector& my_sequence() const; - - /*! - * @brief This function returns a reference to member my_sequence - * @return Reference to member my_sequence - */ - eProsima_user_DllExport std::vector& my_sequence(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const SequenceBadStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::vector m_my_sequence; - -}; - - - - - -/*! - * @brief This class represents the structure SequenceBoundsStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SequenceBoundsStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SequenceBoundsStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SequenceBoundsStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SequenceBoundsStruct that will be copied. - */ - eProsima_user_DllExport SequenceBoundsStruct( - const SequenceBoundsStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SequenceBoundsStruct that will be copied. - */ - eProsima_user_DllExport SequenceBoundsStruct( - SequenceBoundsStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SequenceBoundsStruct that will be copied. - */ - eProsima_user_DllExport SequenceBoundsStruct& operator =( - const SequenceBoundsStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SequenceBoundsStruct that will be copied. - */ - eProsima_user_DllExport SequenceBoundsStruct& operator =( - SequenceBoundsStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SequenceBoundsStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SequenceBoundsStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x SequenceBoundsStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SequenceBoundsStruct& x) const; - - /*! - * @brief This function copies the value in member my_sequence - * @param _my_sequence New value to be copied in member my_sequence - */ - eProsima_user_DllExport void my_sequence( - const std::vector& _my_sequence); - - /*! - * @brief This function moves the value in member my_sequence - * @param _my_sequence New value to be moved in member my_sequence - */ - eProsima_user_DllExport void my_sequence( - std::vector&& _my_sequence); - - /*! - * @brief This function returns a constant reference to member my_sequence - * @return Constant reference to member my_sequence - */ - eProsima_user_DllExport const std::vector& my_sequence() const; - - /*! - * @brief This function returns a reference to member my_sequence - * @return Reference to member my_sequence - */ - eProsima_user_DllExport std::vector& my_sequence(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const SequenceBoundsStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::vector m_my_sequence; - -}; - - - - - - - -/*! - * @brief This class represents the structure SequenceSequenceStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SequenceSequenceStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SequenceSequenceStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SequenceSequenceStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SequenceSequenceStruct that will be copied. - */ - eProsima_user_DllExport SequenceSequenceStruct( - const SequenceSequenceStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SequenceSequenceStruct that will be copied. - */ - eProsima_user_DllExport SequenceSequenceStruct( - SequenceSequenceStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SequenceSequenceStruct that will be copied. - */ - eProsima_user_DllExport SequenceSequenceStruct& operator =( - const SequenceSequenceStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SequenceSequenceStruct that will be copied. - */ - eProsima_user_DllExport SequenceSequenceStruct& operator =( - SequenceSequenceStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SequenceSequenceStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SequenceSequenceStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x SequenceSequenceStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SequenceSequenceStruct& x) const; - - /*! - * @brief This function copies the value in member my_sequence_sequence - * @param _my_sequence_sequence New value to be copied in member my_sequence_sequence - */ - eProsima_user_DllExport void my_sequence_sequence( - const std::vector>& _my_sequence_sequence); - - /*! - * @brief This function moves the value in member my_sequence_sequence - * @param _my_sequence_sequence New value to be moved in member my_sequence_sequence - */ - eProsima_user_DllExport void my_sequence_sequence( - std::vector>&& _my_sequence_sequence); - - /*! - * @brief This function returns a constant reference to member my_sequence_sequence - * @return Constant reference to member my_sequence_sequence - */ - eProsima_user_DllExport const std::vector>& my_sequence_sequence() const; - - /*! - * @brief This function returns a reference to member my_sequence_sequence - * @return Reference to member my_sequence_sequence - */ - eProsima_user_DllExport std::vector>& my_sequence_sequence(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const SequenceSequenceStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::vector> m_my_sequence_sequence; - -}; - - - - - - - -/*! - * @brief This class represents the structure SequenceSequenceBoundsStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SequenceSequenceBoundsStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SequenceSequenceBoundsStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SequenceSequenceBoundsStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SequenceSequenceBoundsStruct that will be copied. - */ - eProsima_user_DllExport SequenceSequenceBoundsStruct( - const SequenceSequenceBoundsStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SequenceSequenceBoundsStruct that will be copied. - */ - eProsima_user_DllExport SequenceSequenceBoundsStruct( - SequenceSequenceBoundsStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SequenceSequenceBoundsStruct that will be copied. - */ - eProsima_user_DllExport SequenceSequenceBoundsStruct& operator =( - const SequenceSequenceBoundsStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SequenceSequenceBoundsStruct that will be copied. - */ - eProsima_user_DllExport SequenceSequenceBoundsStruct& operator =( - SequenceSequenceBoundsStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SequenceSequenceBoundsStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SequenceSequenceBoundsStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x SequenceSequenceBoundsStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SequenceSequenceBoundsStruct& x) const; - - /*! - * @brief This function copies the value in member my_sequence_sequence - * @param _my_sequence_sequence New value to be copied in member my_sequence_sequence - */ - eProsima_user_DllExport void my_sequence_sequence( - const std::vector>& _my_sequence_sequence); - - /*! - * @brief This function moves the value in member my_sequence_sequence - * @param _my_sequence_sequence New value to be moved in member my_sequence_sequence - */ - eProsima_user_DllExport void my_sequence_sequence( - std::vector>&& _my_sequence_sequence); - - /*! - * @brief This function returns a constant reference to member my_sequence_sequence - * @return Constant reference to member my_sequence_sequence - */ - eProsima_user_DllExport const std::vector>& my_sequence_sequence() const; - - /*! - * @brief This function returns a reference to member my_sequence_sequence - * @return Reference to member my_sequence_sequence - */ - eProsima_user_DllExport std::vector>& my_sequence_sequence(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const SequenceSequenceBoundsStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::vector> m_my_sequence_sequence; - -}; - - - - - -/*! - * @brief This class represents the structure MapStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MapStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MapStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MapStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MapStruct that will be copied. - */ - eProsima_user_DllExport MapStruct( - const MapStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MapStruct that will be copied. - */ - eProsima_user_DllExport MapStruct( - MapStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MapStruct that will be copied. - */ - eProsima_user_DllExport MapStruct& operator =( - const MapStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MapStruct that will be copied. - */ - eProsima_user_DllExport MapStruct& operator =( - MapStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MapStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MapStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x MapStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MapStruct& x) const; - - /*! - * @brief This function copies the value in member my_map - * @param _my_map New value to be copied in member my_map - */ - eProsima_user_DllExport void my_map( - const std::map& _my_map); - - /*! - * @brief This function moves the value in member my_map - * @param _my_map New value to be moved in member my_map - */ - eProsima_user_DllExport void my_map( - std::map&& _my_map); - - /*! - * @brief This function returns a constant reference to member my_map - * @return Constant reference to member my_map - */ - eProsima_user_DllExport const std::map& my_map() const; - - /*! - * @brief This function returns a reference to member my_map - * @return Reference to member my_map - */ - eProsima_user_DllExport std::map& my_map(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const MapStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::map m_my_map; - -}; - - - - - -/*! - * @brief This class represents the structure MapStructEqual defined by the user in the IDL file. - * @ingroup Types - */ -class MapStructEqual -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MapStructEqual(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MapStructEqual(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MapStructEqual that will be copied. - */ - eProsima_user_DllExport MapStructEqual( - const MapStructEqual& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MapStructEqual that will be copied. - */ - eProsima_user_DllExport MapStructEqual( - MapStructEqual&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MapStructEqual that will be copied. - */ - eProsima_user_DllExport MapStructEqual& operator =( - const MapStructEqual& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MapStructEqual that will be copied. - */ - eProsima_user_DllExport MapStructEqual& operator =( - MapStructEqual&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MapStructEqual object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MapStructEqual& x) const; - - /*! - * @brief Comparison operator. - * @param x MapStructEqual object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MapStructEqual& x) const; - - /*! - * @brief This function copies the value in member my_map_equal - * @param _my_map_equal New value to be copied in member my_map_equal - */ - eProsima_user_DllExport void my_map_equal( - const std::map& _my_map_equal); - - /*! - * @brief This function moves the value in member my_map_equal - * @param _my_map_equal New value to be moved in member my_map_equal - */ - eProsima_user_DllExport void my_map_equal( - std::map&& _my_map_equal); - - /*! - * @brief This function returns a constant reference to member my_map_equal - * @return Constant reference to member my_map_equal - */ - eProsima_user_DllExport const std::map& my_map_equal() const; - - /*! - * @brief This function returns a reference to member my_map_equal - * @return Reference to member my_map_equal - */ - eProsima_user_DllExport std::map& my_map_equal(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const MapStructEqual& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::map m_my_map_equal; - -}; - - - - - -/*! - * @brief This class represents the structure MapBadKeyStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MapBadKeyStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MapBadKeyStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MapBadKeyStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MapBadKeyStruct that will be copied. - */ - eProsima_user_DllExport MapBadKeyStruct( - const MapBadKeyStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MapBadKeyStruct that will be copied. - */ - eProsima_user_DllExport MapBadKeyStruct( - MapBadKeyStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MapBadKeyStruct that will be copied. - */ - eProsima_user_DllExport MapBadKeyStruct& operator =( - const MapBadKeyStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MapBadKeyStruct that will be copied. - */ - eProsima_user_DllExport MapBadKeyStruct& operator =( - MapBadKeyStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MapBadKeyStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MapBadKeyStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x MapBadKeyStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MapBadKeyStruct& x) const; - - /*! - * @brief This function copies the value in member my_map - * @param _my_map New value to be copied in member my_map - */ - eProsima_user_DllExport void my_map( - const std::map& _my_map); - - /*! - * @brief This function moves the value in member my_map - * @param _my_map New value to be moved in member my_map - */ - eProsima_user_DllExport void my_map( - std::map&& _my_map); - - /*! - * @brief This function returns a constant reference to member my_map - * @return Constant reference to member my_map - */ - eProsima_user_DllExport const std::map& my_map() const; - - /*! - * @brief This function returns a reference to member my_map - * @return Reference to member my_map - */ - eProsima_user_DllExport std::map& my_map(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const MapBadKeyStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::map m_my_map; - -}; - - - - - -/*! - * @brief This class represents the structure MapBadElemStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MapBadElemStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MapBadElemStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MapBadElemStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MapBadElemStruct that will be copied. - */ - eProsima_user_DllExport MapBadElemStruct( - const MapBadElemStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MapBadElemStruct that will be copied. - */ - eProsima_user_DllExport MapBadElemStruct( - MapBadElemStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MapBadElemStruct that will be copied. - */ - eProsima_user_DllExport MapBadElemStruct& operator =( - const MapBadElemStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MapBadElemStruct that will be copied. - */ - eProsima_user_DllExport MapBadElemStruct& operator =( - MapBadElemStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MapBadElemStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MapBadElemStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x MapBadElemStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MapBadElemStruct& x) const; - - /*! - * @brief This function copies the value in member my_map - * @param _my_map New value to be copied in member my_map - */ - eProsima_user_DllExport void my_map( - const std::map& _my_map); - - /*! - * @brief This function moves the value in member my_map - * @param _my_map New value to be moved in member my_map - */ - eProsima_user_DllExport void my_map( - std::map&& _my_map); - - /*! - * @brief This function returns a constant reference to member my_map - * @return Constant reference to member my_map - */ - eProsima_user_DllExport const std::map& my_map() const; - - /*! - * @brief This function returns a reference to member my_map - * @return Reference to member my_map - */ - eProsima_user_DllExport std::map& my_map(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const MapBadElemStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::map m_my_map; - -}; - - - - - -/*! - * @brief This class represents the structure MapBoundsStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MapBoundsStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MapBoundsStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MapBoundsStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MapBoundsStruct that will be copied. - */ - eProsima_user_DllExport MapBoundsStruct( - const MapBoundsStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MapBoundsStruct that will be copied. - */ - eProsima_user_DllExport MapBoundsStruct( - MapBoundsStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MapBoundsStruct that will be copied. - */ - eProsima_user_DllExport MapBoundsStruct& operator =( - const MapBoundsStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MapBoundsStruct that will be copied. - */ - eProsima_user_DllExport MapBoundsStruct& operator =( - MapBoundsStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MapBoundsStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MapBoundsStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x MapBoundsStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MapBoundsStruct& x) const; - - /*! - * @brief This function copies the value in member my_map - * @param _my_map New value to be copied in member my_map - */ - eProsima_user_DllExport void my_map( - const std::map& _my_map); - - /*! - * @brief This function moves the value in member my_map - * @param _my_map New value to be moved in member my_map - */ - eProsima_user_DllExport void my_map( - std::map&& _my_map); - - /*! - * @brief This function returns a constant reference to member my_map - * @return Constant reference to member my_map - */ - eProsima_user_DllExport const std::map& my_map() const; - - /*! - * @brief This function returns a reference to member my_map - * @return Reference to member my_map - */ - eProsima_user_DllExport std::map& my_map(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const MapBoundsStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::map m_my_map; - -}; - - - - - - - -/*! - * @brief This class represents the structure MapMapStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MapMapStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MapMapStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MapMapStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MapMapStruct that will be copied. - */ - eProsima_user_DllExport MapMapStruct( - const MapMapStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MapMapStruct that will be copied. - */ - eProsima_user_DllExport MapMapStruct( - MapMapStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MapMapStruct that will be copied. - */ - eProsima_user_DllExport MapMapStruct& operator =( - const MapMapStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MapMapStruct that will be copied. - */ - eProsima_user_DllExport MapMapStruct& operator =( - MapMapStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MapMapStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MapMapStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x MapMapStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MapMapStruct& x) const; - - /*! - * @brief This function copies the value in member my_map_map - * @param _my_map_map New value to be copied in member my_map_map - */ - eProsima_user_DllExport void my_map_map( - const std::map>& _my_map_map); - - /*! - * @brief This function moves the value in member my_map_map - * @param _my_map_map New value to be moved in member my_map_map - */ - eProsima_user_DllExport void my_map_map( - std::map>&& _my_map_map); - - /*! - * @brief This function returns a constant reference to member my_map_map - * @return Constant reference to member my_map_map - */ - eProsima_user_DllExport const std::map>& my_map_map() const; - - /*! - * @brief This function returns a reference to member my_map_map - * @return Reference to member my_map_map - */ - eProsima_user_DllExport std::map>& my_map_map(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const MapMapStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::map> m_my_map_map; - -}; - - - - - - - -/*! - * @brief This class represents the structure MapMapBoundsStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MapMapBoundsStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MapMapBoundsStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MapMapBoundsStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MapMapBoundsStruct that will be copied. - */ - eProsima_user_DllExport MapMapBoundsStruct( - const MapMapBoundsStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MapMapBoundsStruct that will be copied. - */ - eProsima_user_DllExport MapMapBoundsStruct( - MapMapBoundsStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MapMapBoundsStruct that will be copied. - */ - eProsima_user_DllExport MapMapBoundsStruct& operator =( - const MapMapBoundsStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MapMapBoundsStruct that will be copied. - */ - eProsima_user_DllExport MapMapBoundsStruct& operator =( - MapMapBoundsStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MapMapBoundsStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MapMapBoundsStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x MapMapBoundsStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MapMapBoundsStruct& x) const; - - /*! - * @brief This function copies the value in member my_map_map - * @param _my_map_map New value to be copied in member my_map_map - */ - eProsima_user_DllExport void my_map_map( - const std::map>& _my_map_map); - - /*! - * @brief This function moves the value in member my_map_map - * @param _my_map_map New value to be moved in member my_map_map - */ - eProsima_user_DllExport void my_map_map( - std::map>&& _my_map_map); - - /*! - * @brief This function returns a constant reference to member my_map_map - * @return Constant reference to member my_map_map - */ - eProsima_user_DllExport const std::map>& my_map_map() const; - - /*! - * @brief This function returns a reference to member my_map_map - * @return Reference to member my_map_map - */ - eProsima_user_DllExport std::map>& my_map_map(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const MapMapBoundsStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::map> m_my_map_map; - -}; - - - -/*! - * @brief This class represents the union SimpleUnion defined by the user in the IDL file. - * @ingroup Types - */ -class SimpleUnion -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimpleUnion(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimpleUnion(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimpleUnion that will be copied. - */ - eProsima_user_DllExport SimpleUnion( - const SimpleUnion& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimpleUnion that will be copied. - */ - eProsima_user_DllExport SimpleUnion( - SimpleUnion&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimpleUnion that will be copied. - */ - eProsima_user_DllExport SimpleUnion& operator =( - const SimpleUnion& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimpleUnion that will be copied. - */ - eProsima_user_DllExport SimpleUnion& operator =( - SimpleUnion&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimpleUnion object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimpleUnion& x) const; - - /*! - * @brief Comparison operator. - * @param x SimpleUnion object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimpleUnion& x) const; - - /*! - * @brief This function sets the discriminator value. - * @param __d New value for the discriminator. - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the new value doesn't correspond to the selected union member. - */ - eProsima_user_DllExport void _d( - int32_t __d); - - /*! - * @brief This function returns the value of the discriminator. - * @return Value of the discriminator - */ - eProsima_user_DllExport int32_t _d() const; - - /*! - * @brief This function returns a reference to the discriminator. - * @return Reference to the discriminator. - */ - eProsima_user_DllExport int32_t& _d(); - - /*! - * @brief This function sets a value in member first - * @param _first New value for member first - */ - eProsima_user_DllExport void first( - int32_t _first); - - /*! - * @brief This function returns the value of member first - * @return Value of member first - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t first() const; - - /*! - * @brief This function returns a reference to member first - * @return Reference to member first - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t& first(); - - - /*! - * @brief This function sets a value in member second - * @param _second New value for member second - */ - eProsima_user_DllExport void second( - int64_t _second); - - /*! - * @brief This function returns the value of member second - * @return Value of member second - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t second() const; - - /*! - * @brief This function returns a reference to member second - * @return Reference to member second - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t& second(); - - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const SimpleUnion& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - -private: - - int32_t m__d; - - int32_t m_first; - int64_t m_second; -}; - - - -/*! - * @brief This class represents the union SimpleUnionNames defined by the user in the IDL file. - * @ingroup Types - */ -class SimpleUnionNames -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimpleUnionNames(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimpleUnionNames(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimpleUnionNames that will be copied. - */ - eProsima_user_DllExport SimpleUnionNames( - const SimpleUnionNames& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimpleUnionNames that will be copied. - */ - eProsima_user_DllExport SimpleUnionNames( - SimpleUnionNames&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimpleUnionNames that will be copied. - */ - eProsima_user_DllExport SimpleUnionNames& operator =( - const SimpleUnionNames& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimpleUnionNames that will be copied. - */ - eProsima_user_DllExport SimpleUnionNames& operator =( - SimpleUnionNames&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimpleUnionNames object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimpleUnionNames& x) const; - - /*! - * @brief Comparison operator. - * @param x SimpleUnionNames object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimpleUnionNames& x) const; - - /*! - * @brief This function sets the discriminator value. - * @param __d New value for the discriminator. - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the new value doesn't correspond to the selected union member. - */ - eProsima_user_DllExport void _d( - int32_t __d); - - /*! - * @brief This function returns the value of the discriminator. - * @return Value of the discriminator - */ - eProsima_user_DllExport int32_t _d() const; - - /*! - * @brief This function returns a reference to the discriminator. - * @return Reference to the discriminator. - */ - eProsima_user_DllExport int32_t& _d(); - - /*! - * @brief This function sets a value in member first_case - * @param _first_case New value for member first_case - */ - eProsima_user_DllExport void first_case( - int32_t _first_case); - - /*! - * @brief This function returns the value of member first_case - * @return Value of member first_case - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t first_case() const; - - /*! - * @brief This function returns a reference to member first_case - * @return Reference to member first_case - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t& first_case(); - - - /*! - * @brief This function sets a value in member second_case - * @param _second_case New value for member second_case - */ - eProsima_user_DllExport void second_case( - int64_t _second_case); - - /*! - * @brief This function returns the value of member second_case - * @return Value of member second_case - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t second_case() const; - - /*! - * @brief This function returns a reference to member second_case - * @return Reference to member second_case - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t& second_case(); - - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const SimpleUnionNames& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - -private: - - int32_t m__d; - - int32_t m_first_case; - int64_t m_second_case; -}; - - - -/*! - * @brief This class represents the union SimpleTypeUnion defined by the user in the IDL file. - * @ingroup Types - */ -class SimpleTypeUnion -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimpleTypeUnion(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimpleTypeUnion(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimpleTypeUnion that will be copied. - */ - eProsima_user_DllExport SimpleTypeUnion( - const SimpleTypeUnion& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimpleTypeUnion that will be copied. - */ - eProsima_user_DllExport SimpleTypeUnion( - SimpleTypeUnion&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimpleTypeUnion that will be copied. - */ - eProsima_user_DllExport SimpleTypeUnion& operator =( - const SimpleTypeUnion& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimpleTypeUnion that will be copied. - */ - eProsima_user_DllExport SimpleTypeUnion& operator =( - SimpleTypeUnion&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimpleTypeUnion object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimpleTypeUnion& x) const; - - /*! - * @brief Comparison operator. - * @param x SimpleTypeUnion object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimpleTypeUnion& x) const; - - /*! - * @brief This function sets the discriminator value. - * @param __d New value for the discriminator. - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the new value doesn't correspond to the selected union member. - */ - eProsima_user_DllExport void _d( - int32_t __d); - - /*! - * @brief This function returns the value of the discriminator. - * @return Value of the discriminator - */ - eProsima_user_DllExport int32_t _d() const; - - /*! - * @brief This function returns a reference to the discriminator. - * @return Reference to the discriminator. - */ - eProsima_user_DllExport int32_t& _d(); - - /*! - * @brief This function sets a value in member first - * @param _first New value for member first - */ - eProsima_user_DllExport void first( - uint8_t _first); - - /*! - * @brief This function returns the value of member first - * @return Value of member first - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport uint8_t first() const; - - /*! - * @brief This function returns a reference to member first - * @return Reference to member first - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport uint8_t& first(); - - - /*! - * @brief This function sets a value in member second - * @param _second New value for member second - */ - eProsima_user_DllExport void second( - int64_t _second); - - /*! - * @brief This function returns the value of member second - * @return Value of member second - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t second() const; - - /*! - * @brief This function returns a reference to member second - * @return Reference to member second - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t& second(); - - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const SimpleTypeUnion& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - -private: - - int32_t m__d; - - uint8_t m_first; - int64_t m_second; -}; - - - -/*! - * @brief This class represents the union SimpleBadUnion defined by the user in the IDL file. - * @ingroup Types - */ -class SimpleBadUnion -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimpleBadUnion(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimpleBadUnion(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimpleBadUnion that will be copied. - */ - eProsima_user_DllExport SimpleBadUnion( - const SimpleBadUnion& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimpleBadUnion that will be copied. - */ - eProsima_user_DllExport SimpleBadUnion( - SimpleBadUnion&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimpleBadUnion that will be copied. - */ - eProsima_user_DllExport SimpleBadUnion& operator =( - const SimpleBadUnion& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimpleBadUnion that will be copied. - */ - eProsima_user_DllExport SimpleBadUnion& operator =( - SimpleBadUnion&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimpleBadUnion object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimpleBadUnion& x) const; - - /*! - * @brief Comparison operator. - * @param x SimpleBadUnion object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimpleBadUnion& x) const; - - /*! - * @brief This function sets the discriminator value. - * @param __d New value for the discriminator. - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the new value doesn't correspond to the selected union member. - */ - eProsima_user_DllExport void _d( - int32_t __d); - - /*! - * @brief This function returns the value of the discriminator. - * @return Value of the discriminator - */ - eProsima_user_DllExport int32_t _d() const; - - /*! - * @brief This function returns a reference to the discriminator. - * @return Reference to the discriminator. - */ - eProsima_user_DllExport int32_t& _d(); - - /*! - * @brief This function sets a value in member first - * @param _first New value for member first - */ - eProsima_user_DllExport void first( - int32_t _first); - - /*! - * @brief This function returns the value of member first - * @return Value of member first - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t first() const; - - /*! - * @brief This function returns a reference to member first - * @return Reference to member first - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t& first(); - - - /*! - * @brief This function sets a value in member second - * @param _second New value for member second - */ - eProsima_user_DllExport void second( - int64_t _second); - - /*! - * @brief This function returns the value of member second - * @return Value of member second - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t second() const; - - /*! - * @brief This function returns a reference to member second - * @return Reference to member second - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t& second(); - - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const SimpleBadUnion& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - -private: - - int32_t m__d; - - int32_t m_first; - int64_t m_second; -}; - - - -/*! - * @brief This class represents the union SimpleBadDiscUnion defined by the user in the IDL file. - * @ingroup Types - */ -class SimpleBadDiscUnion -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimpleBadDiscUnion(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimpleBadDiscUnion(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimpleBadDiscUnion that will be copied. - */ - eProsima_user_DllExport SimpleBadDiscUnion( - const SimpleBadDiscUnion& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimpleBadDiscUnion that will be copied. - */ - eProsima_user_DllExport SimpleBadDiscUnion( - SimpleBadDiscUnion&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimpleBadDiscUnion that will be copied. - */ - eProsima_user_DllExport SimpleBadDiscUnion& operator =( - const SimpleBadDiscUnion& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimpleBadDiscUnion that will be copied. - */ - eProsima_user_DllExport SimpleBadDiscUnion& operator =( - SimpleBadDiscUnion&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimpleBadDiscUnion object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimpleBadDiscUnion& x) const; - - /*! - * @brief Comparison operator. - * @param x SimpleBadDiscUnion object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimpleBadDiscUnion& x) const; - - /*! - * @brief This function sets the discriminator value. - * @param __d New value for the discriminator. - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the new value doesn't correspond to the selected union member. - */ - eProsima_user_DllExport void _d( - uint8_t __d); - - /*! - * @brief This function returns the value of the discriminator. - * @return Value of the discriminator - */ - eProsima_user_DllExport uint8_t _d() const; - - /*! - * @brief This function returns a reference to the discriminator. - * @return Reference to the discriminator. - */ - eProsima_user_DllExport uint8_t& _d(); - - /*! - * @brief This function sets a value in member first - * @param _first New value for member first - */ - eProsima_user_DllExport void first( - int32_t _first); - - /*! - * @brief This function returns the value of member first - * @return Value of member first - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t first() const; - - /*! - * @brief This function returns a reference to member first - * @return Reference to member first - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t& first(); - - - /*! - * @brief This function sets a value in member second - * @param _second New value for member second - */ - eProsima_user_DllExport void second( - int64_t _second); - - /*! - * @brief This function returns the value of member second - * @return Value of member second - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t second() const; - - /*! - * @brief This function returns a reference to member second - * @return Reference to member second - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t& second(); - - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const SimpleBadDiscUnion& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - -private: - - uint8_t m__d; - - int32_t m_first; - int64_t m_second; -}; - - - -/*! - * @brief This class represents the structure SimpleUnionStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SimpleUnionStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimpleUnionStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimpleUnionStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimpleUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleUnionStruct( - const SimpleUnionStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimpleUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleUnionStruct( - SimpleUnionStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimpleUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleUnionStruct& operator =( - const SimpleUnionStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimpleUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleUnionStruct& operator =( - SimpleUnionStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimpleUnionStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimpleUnionStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x SimpleUnionStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimpleUnionStruct& x) const; - - /*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ - eProsima_user_DllExport void my_union( - const SimpleUnion& _my_union); - - /*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ - eProsima_user_DllExport void my_union( - SimpleUnion&& _my_union); - - /*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ - eProsima_user_DllExport const SimpleUnion& my_union() const; - - /*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ - eProsima_user_DllExport SimpleUnion& my_union(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const SimpleUnionStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - SimpleUnion m_my_union; - -}; - - - -/*! - * @brief This class represents the structure SimpleUnionStructEqual defined by the user in the IDL file. - * @ingroup Types - */ -class SimpleUnionStructEqual -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimpleUnionStructEqual(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimpleUnionStructEqual(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimpleUnionStructEqual that will be copied. - */ - eProsima_user_DllExport SimpleUnionStructEqual( - const SimpleUnionStructEqual& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimpleUnionStructEqual that will be copied. - */ - eProsima_user_DllExport SimpleUnionStructEqual( - SimpleUnionStructEqual&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimpleUnionStructEqual that will be copied. - */ - eProsima_user_DllExport SimpleUnionStructEqual& operator =( - const SimpleUnionStructEqual& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimpleUnionStructEqual that will be copied. - */ - eProsima_user_DllExport SimpleUnionStructEqual& operator =( - SimpleUnionStructEqual&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimpleUnionStructEqual object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimpleUnionStructEqual& x) const; - - /*! - * @brief Comparison operator. - * @param x SimpleUnionStructEqual object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimpleUnionStructEqual& x) const; - - /*! - * @brief This function copies the value in member my_union_equal - * @param _my_union_equal New value to be copied in member my_union_equal - */ - eProsima_user_DllExport void my_union_equal( - const SimpleUnion& _my_union_equal); - - /*! - * @brief This function moves the value in member my_union_equal - * @param _my_union_equal New value to be moved in member my_union_equal - */ - eProsima_user_DllExport void my_union_equal( - SimpleUnion&& _my_union_equal); - - /*! - * @brief This function returns a constant reference to member my_union_equal - * @return Constant reference to member my_union_equal - */ - eProsima_user_DllExport const SimpleUnion& my_union_equal() const; - - /*! - * @brief This function returns a reference to member my_union_equal - * @return Reference to member my_union_equal - */ - eProsima_user_DllExport SimpleUnion& my_union_equal(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const SimpleUnionStructEqual& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - SimpleUnion m_my_union_equal; - -}; - - - -/*! - * @brief This class represents the structure SimpleUnionNamesStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SimpleUnionNamesStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimpleUnionNamesStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimpleUnionNamesStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimpleUnionNamesStruct that will be copied. - */ - eProsima_user_DllExport SimpleUnionNamesStruct( - const SimpleUnionNamesStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimpleUnionNamesStruct that will be copied. - */ - eProsima_user_DllExport SimpleUnionNamesStruct( - SimpleUnionNamesStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimpleUnionNamesStruct that will be copied. - */ - eProsima_user_DllExport SimpleUnionNamesStruct& operator =( - const SimpleUnionNamesStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimpleUnionNamesStruct that will be copied. - */ - eProsima_user_DllExport SimpleUnionNamesStruct& operator =( - SimpleUnionNamesStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimpleUnionNamesStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimpleUnionNamesStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x SimpleUnionNamesStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimpleUnionNamesStruct& x) const; - - /*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ - eProsima_user_DllExport void my_union( - const SimpleUnionNames& _my_union); - - /*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ - eProsima_user_DllExport void my_union( - SimpleUnionNames&& _my_union); - - /*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ - eProsima_user_DllExport const SimpleUnionNames& my_union() const; - - /*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ - eProsima_user_DllExport SimpleUnionNames& my_union(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const SimpleUnionNamesStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - SimpleUnionNames m_my_union; - -}; - - - -/*! - * @brief This class represents the structure SimpleTypeUnionStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SimpleTypeUnionStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimpleTypeUnionStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimpleTypeUnionStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimpleTypeUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleTypeUnionStruct( - const SimpleTypeUnionStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimpleTypeUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleTypeUnionStruct( - SimpleTypeUnionStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimpleTypeUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleTypeUnionStruct& operator =( - const SimpleTypeUnionStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimpleTypeUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleTypeUnionStruct& operator =( - SimpleTypeUnionStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimpleTypeUnionStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimpleTypeUnionStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x SimpleTypeUnionStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimpleTypeUnionStruct& x) const; - - /*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ - eProsima_user_DllExport void my_union( - const SimpleTypeUnion& _my_union); - - /*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ - eProsima_user_DllExport void my_union( - SimpleTypeUnion&& _my_union); - - /*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ - eProsima_user_DllExport const SimpleTypeUnion& my_union() const; - - /*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ - eProsima_user_DllExport SimpleTypeUnion& my_union(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const SimpleTypeUnionStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - SimpleTypeUnion m_my_union; - -}; - - - -/*! - * @brief This class represents the structure SimpleBadUnionStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SimpleBadUnionStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimpleBadUnionStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimpleBadUnionStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimpleBadUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleBadUnionStruct( - const SimpleBadUnionStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimpleBadUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleBadUnionStruct( - SimpleBadUnionStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimpleBadUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleBadUnionStruct& operator =( - const SimpleBadUnionStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimpleBadUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleBadUnionStruct& operator =( - SimpleBadUnionStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimpleBadUnionStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimpleBadUnionStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x SimpleBadUnionStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimpleBadUnionStruct& x) const; - - /*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ - eProsima_user_DllExport void my_union( - const SimpleBadUnion& _my_union); - - /*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ - eProsima_user_DllExport void my_union( - SimpleBadUnion&& _my_union); - - /*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ - eProsima_user_DllExport const SimpleBadUnion& my_union() const; - - /*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ - eProsima_user_DllExport SimpleBadUnion& my_union(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const SimpleBadUnionStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - SimpleBadUnion m_my_union; - -}; - - - -/*! - * @brief This class represents the structure SimplBadDiscUnionStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SimplBadDiscUnionStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimplBadDiscUnionStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimplBadDiscUnionStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimplBadDiscUnionStruct that will be copied. - */ - eProsima_user_DllExport SimplBadDiscUnionStruct( - const SimplBadDiscUnionStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimplBadDiscUnionStruct that will be copied. - */ - eProsima_user_DllExport SimplBadDiscUnionStruct( - SimplBadDiscUnionStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimplBadDiscUnionStruct that will be copied. - */ - eProsima_user_DllExport SimplBadDiscUnionStruct& operator =( - const SimplBadDiscUnionStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimplBadDiscUnionStruct that will be copied. - */ - eProsima_user_DllExport SimplBadDiscUnionStruct& operator =( - SimplBadDiscUnionStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimplBadDiscUnionStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimplBadDiscUnionStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x SimplBadDiscUnionStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimplBadDiscUnionStruct& x) const; - - /*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ - eProsima_user_DllExport void my_union( - const SimpleBadDiscUnion& _my_union); - - /*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ - eProsima_user_DllExport void my_union( - SimpleBadDiscUnion&& _my_union); - - /*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ - eProsima_user_DllExport const SimpleBadDiscUnion& my_union() const; - - /*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ - eProsima_user_DllExport SimpleBadDiscUnion& my_union(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const SimplBadDiscUnionStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - SimpleBadDiscUnion m_my_union; - -}; - - -#endif // _FAST_DDS_GENERATED_TYPES_H_ - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/test/unittest/xtypes/idl/WideEnum.cxx b/test/unittest/xtypes/idl/WideEnum.cxx deleted file mode 100644 index 504b70b0b4a..00000000000 --- a/test/unittest/xtypes/idl/WideEnum.cxx +++ /dev/null @@ -1,591 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file WideEnum.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "WideEnum.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#include "WideEnumTypeObject.h" - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - - - - -MyEnumWideStruct::MyEnumWideStruct() -{ - // Just to register all known types - registerWideEnumTypes(); -} - -MyEnumWideStruct::~MyEnumWideStruct() -{ -} - -MyEnumWideStruct::MyEnumWideStruct( - const MyEnumWideStruct& x) -{ - m_my_enum_wide = x.m_my_enum_wide; -} - -MyEnumWideStruct::MyEnumWideStruct( - MyEnumWideStruct&& x) noexcept -{ - m_my_enum_wide = x.m_my_enum_wide; -} - -MyEnumWideStruct& MyEnumWideStruct::operator =( - const MyEnumWideStruct& x) -{ - - m_my_enum_wide = x.m_my_enum_wide; - return *this; -} - -MyEnumWideStruct& MyEnumWideStruct::operator =( - MyEnumWideStruct&& x) noexcept -{ - - m_my_enum_wide = x.m_my_enum_wide; - return *this; -} - -bool MyEnumWideStruct::operator ==( - const MyEnumWideStruct& x) const -{ - return (m_my_enum_wide == x.m_my_enum_wide); -} - -bool MyEnumWideStruct::operator !=( - const MyEnumWideStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member my_enum_wide - * @param _my_enum_wide New value for member my_enum_wide - */ -void MyEnumWideStruct::my_enum_wide( - MyEnumWide _my_enum_wide) -{ - m_my_enum_wide = _my_enum_wide; -} - -/*! - * @brief This function returns the value of member my_enum_wide - * @return Value of member my_enum_wide - */ -MyEnumWide MyEnumWideStruct::my_enum_wide() const -{ - return m_my_enum_wide; -} - -/*! - * @brief This function returns a reference to member my_enum_wide - * @return Reference to member my_enum_wide - */ -MyEnumWide& MyEnumWideStruct::my_enum_wide() -{ - return m_my_enum_wide; -} - - - - -SimpleWideUnion::SimpleWideUnion() -{ - m__d = A; -} - -SimpleWideUnion::~SimpleWideUnion() -{ -} - -SimpleWideUnion::SimpleWideUnion( - const SimpleWideUnion& x) -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - - case D: - m_third = x.m_third; - break; - - default: - break; - } -} - -SimpleWideUnion::SimpleWideUnion( - SimpleWideUnion&& x) noexcept -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - - case D: - m_third = x.m_third; - break; - - default: - break; - } -} - -SimpleWideUnion& SimpleWideUnion::operator =( - const SimpleWideUnion& x) -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - - case D: - m_third = x.m_third; - break; - - default: - break; - } - - return *this; -} - -SimpleWideUnion& SimpleWideUnion::operator =( - SimpleWideUnion&& x) noexcept -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - - case D: - m_third = x.m_third; - break; - - default: - break; - } - - return *this; -} - -bool SimpleWideUnion::operator ==( - const SimpleWideUnion& x) const -{ - if (m__d != x.m__d) - { - return false; - } - - switch (m__d) - { - case A: - return (m_first == x.m_first); - break; - - - case B: - return (m_second == x.m_second); - break; - - - case D: - return (m_third == x.m_third); - break; - - default: - break; - } - return false; -} - -bool SimpleWideUnion::operator !=( - const SimpleWideUnion& x) const -{ - return !(*this == x); -} - -void SimpleWideUnion::_d( - int32_t __d) -{ - bool b = false; - - switch (m__d) - { - case A: - switch (__d) - { - case A: - b = true; - break; - default: - break; - } - break; - - - case B: - switch (__d) - { - case B: - b = true; - break; - default: - break; - } - break; - - - case D: - switch (__d) - { - case D: - b = true; - break; - default: - break; - } - break; - - default: - break; - } - - if (!b) - { - throw BadParamException("Discriminator doesn't correspond with the selected union member"); - } - - m__d = __d; -} - -int32_t SimpleWideUnion::_d() const -{ - return m__d; -} - -int32_t& SimpleWideUnion::_d() -{ - return m__d; -} - -void SimpleWideUnion::first( - int32_t _first) -{ - m_first = _first; - m__d = A; - -} - -int32_t SimpleWideUnion::first() const -{ - bool b = false; - - switch (m__d) - { - case A: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first; -} - -int32_t& SimpleWideUnion::first() -{ - bool b = false; - - switch (m__d) - { - case A: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first; -} - - -void SimpleWideUnion::second( - int64_t _second) -{ - m_second = _second; - m__d = B; - -} - -int64_t SimpleWideUnion::second() const -{ - bool b = false; - - switch (m__d) - { - case B: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second; -} - -int64_t& SimpleWideUnion::second() -{ - bool b = false; - - switch (m__d) - { - case B: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second; -} - - -void SimpleWideUnion::third( - uint8_t _third) -{ - m_third = _third; - m__d = D; - -} - -uint8_t SimpleWideUnion::third() const -{ - bool b = false; - - switch (m__d) - { - case D: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_third; -} - -uint8_t& SimpleWideUnion::third() -{ - bool b = false; - - switch (m__d) - { - case D: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_third; -} - - - - -SimpleWideUnionStruct::SimpleWideUnionStruct() -{ - // Just to register all known types - registerWideEnumTypes(); -} - -SimpleWideUnionStruct::~SimpleWideUnionStruct() -{ -} - -SimpleWideUnionStruct::SimpleWideUnionStruct( - const SimpleWideUnionStruct& x) -{ - m_my_union = x.m_my_union; -} - -SimpleWideUnionStruct::SimpleWideUnionStruct( - SimpleWideUnionStruct&& x) noexcept -{ - m_my_union = std::move(x.m_my_union); -} - -SimpleWideUnionStruct& SimpleWideUnionStruct::operator =( - const SimpleWideUnionStruct& x) -{ - - m_my_union = x.m_my_union; - return *this; -} - -SimpleWideUnionStruct& SimpleWideUnionStruct::operator =( - SimpleWideUnionStruct&& x) noexcept -{ - - m_my_union = std::move(x.m_my_union); - return *this; -} - -bool SimpleWideUnionStruct::operator ==( - const SimpleWideUnionStruct& x) const -{ - return (m_my_union == x.m_my_union); -} - -bool SimpleWideUnionStruct::operator !=( - const SimpleWideUnionStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ -void SimpleWideUnionStruct::my_union( - const SimpleWideUnion& _my_union) -{ - m_my_union = _my_union; -} - -/*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ -void SimpleWideUnionStruct::my_union( - SimpleWideUnion&& _my_union) -{ - m_my_union = std::move(_my_union); -} - -/*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ -const SimpleWideUnion& SimpleWideUnionStruct::my_union() const -{ - return m_my_union; -} - -/*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ -SimpleWideUnion& SimpleWideUnionStruct::my_union() -{ - return m_my_union; -} - - -// Include auxiliary functions like for serializing/deserializing. -#include "WideEnumCdrAux.ipp" - -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/test/unittest/xtypes/idl/WideEnum.h b/test/unittest/xtypes/idl/WideEnum.h deleted file mode 100644 index 3a731aeb935..00000000000 --- a/test/unittest/xtypes/idl/WideEnum.h +++ /dev/null @@ -1,426 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file WideEnum.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#include -#include "WideEnumv1.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#ifndef _FAST_DDS_GENERATED_WIDEENUM_H_ -#define _FAST_DDS_GENERATED_WIDEENUM_H_ - -#include -#include -#include -#include -#include -#include - -#include -#include -#include - - - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define eProsima_user_DllExport -#endif // _WIN32 - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(WIDEENUM_SOURCE) -#define WIDEENUM_DllAPI __declspec( dllexport ) -#else -#define WIDEENUM_DllAPI __declspec( dllimport ) -#endif // WIDEENUM_SOURCE -#else -#define WIDEENUM_DllAPI -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define WIDEENUM_DllAPI -#endif // _WIN32 - -namespace eprosima { -namespace fastcdr { -class Cdr; -class CdrSizeCalculator; -} // namespace fastcdr -} // namespace eprosima - - - -/*! - * @brief This class represents the enumeration MyEnumWide defined by the user in the IDL file. - * @ingroup WideEnum - */ -enum MyEnumWide : uint32_t -{ - A, - B, - C, - D -}; - - -/*! - * @brief This class represents the structure MyEnumWideStruct defined by the user in the IDL file. - * @ingroup WideEnum - */ -class MyEnumWideStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MyEnumWideStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MyEnumWideStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MyEnumWideStruct that will be copied. - */ - eProsima_user_DllExport MyEnumWideStruct( - const MyEnumWideStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MyEnumWideStruct that will be copied. - */ - eProsima_user_DllExport MyEnumWideStruct( - MyEnumWideStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MyEnumWideStruct that will be copied. - */ - eProsima_user_DllExport MyEnumWideStruct& operator =( - const MyEnumWideStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MyEnumWideStruct that will be copied. - */ - eProsima_user_DllExport MyEnumWideStruct& operator =( - MyEnumWideStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MyEnumWideStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MyEnumWideStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x MyEnumWideStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MyEnumWideStruct& x) const; - - /*! - * @brief This function sets a value in member my_enum_wide - * @param _my_enum_wide New value for member my_enum_wide - */ - eProsima_user_DllExport void my_enum_wide( - MyEnumWide _my_enum_wide); - - /*! - * @brief This function returns the value of member my_enum_wide - * @return Value of member my_enum_wide - */ - eProsima_user_DllExport MyEnumWide my_enum_wide() const; - - /*! - * @brief This function returns a reference to member my_enum_wide - * @return Reference to member my_enum_wide - */ - eProsima_user_DllExport MyEnumWide& my_enum_wide(); - -private: - - MyEnumWide m_my_enum_wide{::A}; - -}; - - -/*! - * @brief This class represents the union SimpleWideUnion defined by the user in the IDL file. - * @ingroup WideEnum - */ -class SimpleWideUnion -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimpleWideUnion(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimpleWideUnion(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimpleWideUnion that will be copied. - */ - eProsima_user_DllExport SimpleWideUnion( - const SimpleWideUnion& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimpleWideUnion that will be copied. - */ - eProsima_user_DllExport SimpleWideUnion( - SimpleWideUnion&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimpleWideUnion that will be copied. - */ - eProsima_user_DllExport SimpleWideUnion& operator =( - const SimpleWideUnion& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimpleWideUnion that will be copied. - */ - eProsima_user_DllExport SimpleWideUnion& operator =( - SimpleWideUnion&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimpleWideUnion object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimpleWideUnion& x) const; - - /*! - * @brief Comparison operator. - * @param x SimpleWideUnion object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimpleWideUnion& x) const; - - /*! - * @brief This function sets the discriminator value. - * @param __d New value for the discriminator. - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the new value doesn't correspond to the selected union member. - */ - eProsima_user_DllExport void _d( - int32_t __d); - - /*! - * @brief This function returns the value of the discriminator. - * @return Value of the discriminator - */ - eProsima_user_DllExport int32_t _d() const; - - /*! - * @brief This function returns a reference to the discriminator. - * @return Reference to the discriminator. - */ - eProsima_user_DllExport int32_t& _d(); - - /*! - * @brief This function sets a value in member first - * @param _first New value for member first - */ - eProsima_user_DllExport void first( - int32_t _first); - - /*! - * @brief This function returns the value of member first - * @return Value of member first - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t first() const; - - /*! - * @brief This function returns a reference to member first - * @return Reference to member first - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t& first(); - - - /*! - * @brief This function sets a value in member second - * @param _second New value for member second - */ - eProsima_user_DllExport void second( - int64_t _second); - - /*! - * @brief This function returns the value of member second - * @return Value of member second - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t second() const; - - /*! - * @brief This function returns a reference to member second - * @return Reference to member second - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t& second(); - - - /*! - * @brief This function sets a value in member third - * @param _third New value for member third - */ - eProsima_user_DllExport void third( - uint8_t _third); - - /*! - * @brief This function returns the value of member third - * @return Value of member third - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport uint8_t third() const; - - /*! - * @brief This function returns a reference to member third - * @return Reference to member third - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport uint8_t& third(); - -private: - - int32_t m__d; - - int32_t m_first{0}; - int64_t m_second{0}; - uint8_t m_third{0}; -}; - - -/*! - * @brief This class represents the structure SimpleWideUnionStruct defined by the user in the IDL file. - * @ingroup WideEnum - */ -class SimpleWideUnionStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimpleWideUnionStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimpleWideUnionStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimpleWideUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleWideUnionStruct( - const SimpleWideUnionStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimpleWideUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleWideUnionStruct( - SimpleWideUnionStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimpleWideUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleWideUnionStruct& operator =( - const SimpleWideUnionStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimpleWideUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleWideUnionStruct& operator =( - SimpleWideUnionStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimpleWideUnionStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimpleWideUnionStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x SimpleWideUnionStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimpleWideUnionStruct& x) const; - - /*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ - eProsima_user_DllExport void my_union( - const SimpleWideUnion& _my_union); - - /*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ - eProsima_user_DllExport void my_union( - SimpleWideUnion&& _my_union); - - /*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ - eProsima_user_DllExport const SimpleWideUnion& my_union() const; - - /*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ - eProsima_user_DllExport SimpleWideUnion& my_union(); - -private: - - SimpleWideUnion m_my_union; - -}; - -#endif // _FAST_DDS_GENERATED_WIDEENUM_H_ - - - -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/test/unittest/xtypes/idl/WideEnum.idl b/test/unittest/xtypes/idl/WideEnum.idl deleted file mode 100644 index b31b2bb7070..00000000000 --- a/test/unittest/xtypes/idl/WideEnum.idl +++ /dev/null @@ -1,30 +0,0 @@ -// Enum - -enum MyEnumWide -{ - A, - B, - C, - D -}; - -struct MyEnumWideStruct -{ - MyEnumWide my_enum_wide; -}; - - -union SimpleWideUnion switch (long) -{ - case A: - long first; - case B: - long long second; - case D: - octet third; -}; - -struct SimpleWideUnionStruct -{ - SimpleWideUnion my_union; -}; \ No newline at end of file diff --git a/test/unittest/xtypes/idl/WideEnumCdrAux.hpp b/test/unittest/xtypes/idl/WideEnumCdrAux.hpp deleted file mode 100644 index 34c5600fbef..00000000000 --- a/test/unittest/xtypes/idl/WideEnumCdrAux.hpp +++ /dev/null @@ -1,63 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file WideEnumCdrAux.hpp - * This source file contains some definitions of CDR related functions. - * - * This file was generated by the tool fastddsgen. - */ - -#ifndef _FAST_DDS_GENERATED_WIDEENUMCDRAUX_HPP_ -#define _FAST_DDS_GENERATED_WIDEENUMCDRAUX_HPP_ - -#include "WideEnum.h" - -constexpr uint32_t MyEnumWideStruct_max_cdr_typesize {8UL}; -constexpr uint32_t MyEnumWideStruct_max_key_cdr_typesize {0UL}; - - -constexpr uint32_t SimpleWideUnionStruct_max_cdr_typesize {24UL}; -constexpr uint32_t SimpleWideUnionStruct_max_key_cdr_typesize {0UL}; - - - -namespace eprosima { -namespace fastcdr { - -class Cdr; -class CdrSizeCalculator; - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const MyEnumWideStruct& data); - - - - - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SimpleWideUnionStruct& data); - - -} // namespace fastcdr -} // namespace eprosima - -#endif // _FAST_DDS_GENERATED_WIDEENUMCDRAUX_HPP_ - diff --git a/test/unittest/xtypes/idl/WideEnumCdrAux.ipp b/test/unittest/xtypes/idl/WideEnumCdrAux.ipp deleted file mode 100644 index 380b5cf4c6f..00000000000 --- a/test/unittest/xtypes/idl/WideEnumCdrAux.ipp +++ /dev/null @@ -1,320 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file WideEnumCdrAux.ipp - * This source file contains some declarations of CDR related functions. - * - * This file was generated by the tool fastddsgen. - */ - -#ifndef _FAST_DDS_GENERATED_WIDEENUMCDRAUX_IPP_ -#define _FAST_DDS_GENERATED_WIDEENUMCDRAUX_IPP_ - -#include "WideEnumCdrAux.hpp" - -#include -#include - - -#include -using namespace eprosima::fastcdr::exception; - -namespace eprosima { -namespace fastcdr { - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const MyEnumWideStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_enum_wide(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const MyEnumWideStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_enum_wide() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - MyEnumWideStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_enum_wide(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const MyEnumWideStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const SimpleWideUnion& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), data._d(), - current_alignment); - - switch (data._d()) - { - case A: - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(1), - data.first(), current_alignment); - break; - - case B: - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(2), - data.second(), current_alignment); - break; - - case D: - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(3), - data.third(), current_alignment); - break; - - default: - break; - } - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const SimpleWideUnion& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr << eprosima::fastcdr::MemberId(0) << data._d(); - - switch (data._d()) - { - case A: - scdr << eprosima::fastcdr::MemberId(1) << data.first(); - break; - - case B: - scdr << eprosima::fastcdr::MemberId(2) << data.second(); - break; - - case D: - scdr << eprosima::fastcdr::MemberId(3) << data.third(); - break; - - default: - break; - } - - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - SimpleWideUnion& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data._d(); - break; - default: - switch (data._d()) - { - case A: - dcdr >> data.first(); - break; - - case B: - dcdr >> data.second(); - break; - - case D: - dcdr >> data.third(); - break; - - default: - break; - } - ret_value = false; - break; - } - return ret_value; - }); -} - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const SimpleWideUnionStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_union(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const SimpleWideUnionStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_union() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - SimpleWideUnionStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_union(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SimpleWideUnionStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - -} // namespace fastcdr -} // namespace eprosima - -#endif // _FAST_DDS_GENERATED_WIDEENUMCDRAUX_IPP_ - diff --git a/test/unittest/xtypes/idl/WideEnumPubSubTypes.cxx b/test/unittest/xtypes/idl/WideEnumPubSubTypes.cxx deleted file mode 100644 index 3e60c0cd922..00000000000 --- a/test/unittest/xtypes/idl/WideEnumPubSubTypes.cxx +++ /dev/null @@ -1,415 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file WideEnumPubSubTypes.cpp - * This header file contains the implementation of the serialization functions. - * - * This file was generated by the tool fastddsgen. - */ - - -#include - -#include "WideEnumPubSubTypes.h" -#include "WideEnumCdrAux.hpp" - -using SerializedPayload_t = eprosima::fastrtps::rtps::SerializedPayload_t; -using InstanceHandle_t = eprosima::fastrtps::rtps::InstanceHandle_t; -using DataRepresentationId_t = eprosima::fastdds::dds::DataRepresentationId_t; - - - -MyEnumWideStructPubSubType::MyEnumWideStructPubSubType() -{ - setName("MyEnumWideStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(MyEnumWideStruct::getMaxCdrSerializedSize()); -#else - MyEnumWideStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = MyEnumWideStruct_max_key_cdr_typesize > 16 ? MyEnumWideStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -MyEnumWideStructPubSubType::~MyEnumWideStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool MyEnumWideStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - MyEnumWideStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool MyEnumWideStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - MyEnumWideStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function MyEnumWideStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* MyEnumWideStructPubSubType::createData() -{ - return reinterpret_cast(new MyEnumWideStruct()); -} - -void MyEnumWideStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool MyEnumWideStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - MyEnumWideStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - MyEnumWideStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || MyEnumWideStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - - - - - -SimpleWideUnionStructPubSubType::SimpleWideUnionStructPubSubType() -{ - setName("SimpleWideUnionStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(SimpleWideUnionStruct::getMaxCdrSerializedSize()); -#else - SimpleWideUnionStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = SimpleWideUnionStruct_max_key_cdr_typesize > 16 ? SimpleWideUnionStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -SimpleWideUnionStructPubSubType::~SimpleWideUnionStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool SimpleWideUnionStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - SimpleWideUnionStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool SimpleWideUnionStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - SimpleWideUnionStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function SimpleWideUnionStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* SimpleWideUnionStructPubSubType::createData() -{ - return reinterpret_cast(new SimpleWideUnionStruct()); -} - -void SimpleWideUnionStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool SimpleWideUnionStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - SimpleWideUnionStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - SimpleWideUnionStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || SimpleWideUnionStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - diff --git a/test/unittest/xtypes/idl/WideEnumPubSubTypes.h b/test/unittest/xtypes/idl/WideEnumPubSubTypes.h deleted file mode 100644 index 8119ba12ac2..00000000000 --- a/test/unittest/xtypes/idl/WideEnumPubSubTypes.h +++ /dev/null @@ -1,226 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file WideEnumPubSubTypes.h - * This header file contains the declaration of the serialization functions. - * - * This file was generated by the tool fastddsgen. - */ - - -#ifndef _FAST_DDS_GENERATED_WIDEENUM_PUBSUBTYPES_H_ -#define _FAST_DDS_GENERATED_WIDEENUM_PUBSUBTYPES_H_ - -#include -#include -#include -#include -#include - -#include "WideEnum.h" - - -#if !defined(GEN_API_VER) || (GEN_API_VER != 2) -#error \ - Generated WideEnum is not compatible with current installed Fast DDS. Please, regenerate it with fastddsgen. -#endif // GEN_API_VER - - - - -/*! - * @brief This class represents the TopicDataType of the type MyEnumWideStruct defined by the user in the IDL file. - * @ingroup WideEnum - */ -class MyEnumWideStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef MyEnumWideStruct type; - - eProsima_user_DllExport MyEnumWideStructPubSubType(); - - eProsima_user_DllExport ~MyEnumWideStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - - - - - -/*! - * @brief This class represents the TopicDataType of the type SimpleWideUnionStruct defined by the user in the IDL file. - * @ingroup WideEnum - */ -class SimpleWideUnionStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef SimpleWideUnionStruct type; - - eProsima_user_DllExport SimpleWideUnionStructPubSubType(); - - eProsima_user_DllExport ~SimpleWideUnionStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - -#endif // _FAST_DDS_GENERATED_WIDEENUM_PUBSUBTYPES_H_ - diff --git a/test/unittest/xtypes/idl/WideEnumTypeObject.cxx b/test/unittest/xtypes/idl/WideEnumTypeObject.cxx deleted file mode 100644 index 0ae2ba7138b..00000000000 --- a/test/unittest/xtypes/idl/WideEnumTypeObject.cxx +++ /dev/null @@ -1,957 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file WideEnumTypeObject.cpp - * This source file contains the definition of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { char dummy; } -#endif - -#include "WideEnum.h" -#include "WideEnumTypeObject.h" -#include -#include -#include -#include -#include -#include -#include -#include -#include - -using namespace eprosima::fastrtps::rtps; - -void registerWideEnumTypes() -{ - static std::once_flag once_flag; - std::call_once(once_flag, []() - { - TypeObjectFactory *factory = TypeObjectFactory::get_instance(); - factory->add_type_object("MyEnumWide", GetMyEnumWideIdentifier(true), - GetMyEnumWideObject(true)); - factory->add_type_object("MyEnumWide", GetMyEnumWideIdentifier(false), - GetMyEnumWideObject(false)); - - - factory->add_type_object("MyEnumWideStruct", GetMyEnumWideStructIdentifier(true), - GetMyEnumWideStructObject(true)); - factory->add_type_object("MyEnumWideStruct", GetMyEnumWideStructIdentifier(false), - GetMyEnumWideStructObject(false)); - - - factory->add_type_object("SimpleWideUnion", GetSimpleWideUnionIdentifier(true), - GetSimpleWideUnionObject(true)); - factory->add_type_object("SimpleWideUnion", GetSimpleWideUnionIdentifier(false), - GetSimpleWideUnionObject(false)); - - - factory->add_type_object("SimpleWideUnionStruct", GetSimpleWideUnionStructIdentifier(true), - GetSimpleWideUnionStructObject(true)); - factory->add_type_object("SimpleWideUnionStruct", GetSimpleWideUnionStructIdentifier(false), - GetSimpleWideUnionStructObject(false)); - - }); -} - -const TypeIdentifier* GetMyEnumWideIdentifier(bool complete) -{ - const TypeIdentifier* c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("MyEnumWide", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetMyEnumWideObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("MyEnumWide", complete); -} - -const TypeObject* GetMyEnumWideObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyEnumWide", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteMyEnumWideObject(); - } - // else - return GetMinimalMyEnumWideObject(); -} - -const TypeObject* GetMinimalMyEnumWideObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyEnumWide", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_ENUM); - - // No flags apply - //type_object->minimal().enumerated_type().enum_flags().IS_FINAL(false); - //type_object->minimal().enumerated_type().enum_flags().IS_APPENDABLE(false); - //type_object->minimal().enumerated_type().enum_flags().IS_MUTABLE(false); - //type_object->minimal().enumerated_type().enum_flags().IS_NESTED(false); - //type_object->minimal().enumerated_type().enum_flags().IS_AUTOID_HASH(false); - - type_object->minimal().enumerated_type().header().common().bit_bound(32); // TODO fixed by IDL, isn't? - - uint32_t value = 0; - MinimalEnumeratedLiteral mel_A; - mel_A.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - mel_A.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - mel_A.common().flags().IS_EXTERNAL(false); // Doesn't apply - mel_A.common().flags().IS_OPTIONAL(false); // Doesn't apply - mel_A.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mel_A.common().flags().IS_KEY(false); // Doesn't apply - mel_A.common().flags().IS_DEFAULT(false); - mel_A.common().value(value++); - MD5 A_hash("A"); - for(int i = 0; i < 4; ++i) - { - mel_A.detail().name_hash()[i] = A_hash.digest[i]; - } - type_object->minimal().enumerated_type().literal_seq().emplace_back(mel_A); - - MinimalEnumeratedLiteral mel_B; - mel_B.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - mel_B.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - mel_B.common().flags().IS_EXTERNAL(false); // Doesn't apply - mel_B.common().flags().IS_OPTIONAL(false); // Doesn't apply - mel_B.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mel_B.common().flags().IS_KEY(false); // Doesn't apply - mel_B.common().flags().IS_DEFAULT(false); - mel_B.common().value(value++); - MD5 B_hash("B"); - for(int i = 0; i < 4; ++i) - { - mel_B.detail().name_hash()[i] = B_hash.digest[i]; - } - type_object->minimal().enumerated_type().literal_seq().emplace_back(mel_B); - - MinimalEnumeratedLiteral mel_C; - mel_C.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - mel_C.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - mel_C.common().flags().IS_EXTERNAL(false); // Doesn't apply - mel_C.common().flags().IS_OPTIONAL(false); // Doesn't apply - mel_C.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mel_C.common().flags().IS_KEY(false); // Doesn't apply - mel_C.common().flags().IS_DEFAULT(false); - mel_C.common().value(value++); - MD5 C_hash("C"); - for(int i = 0; i < 4; ++i) - { - mel_C.detail().name_hash()[i] = C_hash.digest[i]; - } - type_object->minimal().enumerated_type().literal_seq().emplace_back(mel_C); - - MinimalEnumeratedLiteral mel_D; - mel_D.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - mel_D.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - mel_D.common().flags().IS_EXTERNAL(false); // Doesn't apply - mel_D.common().flags().IS_OPTIONAL(false); // Doesn't apply - mel_D.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mel_D.common().flags().IS_KEY(false); // Doesn't apply - mel_D.common().flags().IS_DEFAULT(false); - mel_D.common().value(value++); - MD5 D_hash("D"); - for(int i = 0; i < 4; ++i) - { - mel_D.detail().name_hash()[i] = D_hash.digest[i]; - } - type_object->minimal().enumerated_type().literal_seq().emplace_back(mel_D); - - - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().enumerated_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MyEnumWide", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyEnumWide", false); -} - -const TypeObject* GetCompleteMyEnumWideObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyEnumWide", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_ENUM); - - // No flags apply - //type_object->complete().enumerated_type().enum_flags().IS_FINAL(false); - //type_object->complete().enumerated_type().enum_flags().IS_APPENDABLE(false); - //type_object->complete().enumerated_type().enum_flags().IS_MUTABLE(false); - //type_object->complete().enumerated_type().enum_flags().IS_NESTED(false); - //type_object->complete().enumerated_type().enum_flags().IS_AUTOID_HASH(false); - - type_object->complete().enumerated_type().header().common().bit_bound(32); // TODO fixed by IDL, isn't? - type_object->complete().enumerated_type().header().detail().type_name("MyEnumWide"); - - uint32_t value = 0; - CompleteEnumeratedLiteral cel_A; - cel_A.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - cel_A.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - cel_A.common().flags().IS_EXTERNAL(false); // Doesn't apply - cel_A.common().flags().IS_OPTIONAL(false); // Doesn't apply - cel_A.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cel_A.common().flags().IS_KEY(false); // Doesn't apply - cel_A.common().flags().IS_DEFAULT(false); - cel_A.common().value(value++); - cel_A.detail().name("A"); - - type_object->complete().enumerated_type().literal_seq().emplace_back(cel_A); - - CompleteEnumeratedLiteral cel_B; - cel_B.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - cel_B.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - cel_B.common().flags().IS_EXTERNAL(false); // Doesn't apply - cel_B.common().flags().IS_OPTIONAL(false); // Doesn't apply - cel_B.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cel_B.common().flags().IS_KEY(false); // Doesn't apply - cel_B.common().flags().IS_DEFAULT(false); - cel_B.common().value(value++); - cel_B.detail().name("B"); - - type_object->complete().enumerated_type().literal_seq().emplace_back(cel_B); - - CompleteEnumeratedLiteral cel_C; - cel_C.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - cel_C.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - cel_C.common().flags().IS_EXTERNAL(false); // Doesn't apply - cel_C.common().flags().IS_OPTIONAL(false); // Doesn't apply - cel_C.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cel_C.common().flags().IS_KEY(false); // Doesn't apply - cel_C.common().flags().IS_DEFAULT(false); - cel_C.common().value(value++); - cel_C.detail().name("C"); - - type_object->complete().enumerated_type().literal_seq().emplace_back(cel_C); - - CompleteEnumeratedLiteral cel_D; - cel_D.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - cel_D.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - cel_D.common().flags().IS_EXTERNAL(false); // Doesn't apply - cel_D.common().flags().IS_OPTIONAL(false); // Doesn't apply - cel_D.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cel_D.common().flags().IS_KEY(false); // Doesn't apply - cel_D.common().flags().IS_DEFAULT(false); - cel_D.common().value(value++); - cel_D.detail().name("D"); - - type_object->complete().enumerated_type().literal_seq().emplace_back(cel_D); - - - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().enumerated_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MyEnumWide", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyEnumWide", true); -} - - - -const TypeIdentifier* GetMyEnumWideStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("MyEnumWideStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetMyEnumWideStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("MyEnumWideStruct", complete); -} - -const TypeObject* GetMyEnumWideStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyEnumWideStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteMyEnumWideStructObject(); - } - //else - return GetMinimalMyEnumWideStructObject(); -} - -const TypeObject* GetMinimalMyEnumWideStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyEnumWideStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_enum_wide; - mst_my_enum_wide.common().member_id(memberId++); - mst_my_enum_wide.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_enum_wide.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_enum_wide.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_enum_wide.common().member_flags().IS_OPTIONAL(false); - mst_my_enum_wide.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_enum_wide.common().member_flags().IS_KEY(false); - mst_my_enum_wide.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_enum_wide.common().member_type_id(*GetMyEnumWideIdentifier(false)); - - MD5 my_enum_wide_hash("my_enum_wide"); - for(int i = 0; i < 4; ++i) - { - mst_my_enum_wide.detail().name_hash()[i] = my_enum_wide_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_enum_wide); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MyEnumWideStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyEnumWideStruct", false); -} - -const TypeObject* GetCompleteMyEnumWideStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyEnumWideStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_enum_wide; - cst_my_enum_wide.common().member_id(memberId++); - cst_my_enum_wide.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_enum_wide.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_enum_wide.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_enum_wide.common().member_flags().IS_OPTIONAL(false); - cst_my_enum_wide.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_enum_wide.common().member_flags().IS_KEY(false); - cst_my_enum_wide.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_enum_wide.common().member_type_id(*GetMyEnumWideIdentifier(true)); - - cst_my_enum_wide.detail().name("my_enum_wide"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_enum_wide); - - - // Header - type_object->complete().struct_type().header().detail().type_name("MyEnumWideStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MyEnumWideStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyEnumWideStruct", true); -} - - - -const TypeIdentifier* GetSimpleWideUnionIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("SimpleWideUnion", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetSimpleWideUnionObject(complete); - return TypeObjectFactory::get_instance()->get_type_identifier("SimpleWideUnion", complete); -} - -const TypeObject* GetSimpleWideUnionObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleWideUnion", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteSimpleWideUnionObject(); - } - // else - return GetMinimalSimpleWideUnionObject(); -} - -const TypeObject* GetMinimalSimpleWideUnionObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleWideUnion", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_UNION); - - type_object->minimal().union_type().union_flags().IS_FINAL(false); - type_object->minimal().union_type().union_flags().IS_APPENDABLE(false); - type_object->minimal().union_type().union_flags().IS_MUTABLE(false); - type_object->minimal().union_type().union_flags().IS_NESTED(false); - type_object->minimal().union_type().union_flags().IS_AUTOID_HASH(false); // Unsupported - - type_object->minimal().union_type().discriminator().common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().IS_EXTERNAL(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_OPTIONAL(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_KEY(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().IS_DEFAULT(false); // Doesn't apply - - type_object->minimal().union_type().discriminator().common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - MemberId memberId = 0; - MinimalUnionMember mst_first; - mst_first.common().member_id(memberId++); - mst_first.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_first.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_first.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_first.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - mst_first.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mst_first.common().member_flags().IS_KEY(false); // Doesn't apply - mst_first.common().member_flags().IS_DEFAULT(false); - mst_first.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - mst_first.common().label_seq().emplace_back(A); - - MD5 first_hash("first"); - for(int i = 0; i < 4; ++i) - { - mst_first.detail().name_hash()[i] = first_hash.digest[i]; - } - type_object->minimal().union_type().member_seq().emplace_back(mst_first); - - MinimalUnionMember mst_second; - mst_second.common().member_id(memberId++); - mst_second.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_second.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_second.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_second.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - mst_second.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mst_second.common().member_flags().IS_KEY(false); // Doesn't apply - mst_second.common().member_flags().IS_DEFAULT(false); - mst_second.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int64_t", false)); - - - mst_second.common().label_seq().emplace_back(B); - - MD5 second_hash("second"); - for(int i = 0; i < 4; ++i) - { - mst_second.detail().name_hash()[i] = second_hash.digest[i]; - } - type_object->minimal().union_type().member_seq().emplace_back(mst_second); - - MinimalUnionMember mst_third; - mst_third.common().member_id(memberId++); - mst_third.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_third.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_third.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_third.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - mst_third.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mst_third.common().member_flags().IS_KEY(false); // Doesn't apply - mst_third.common().member_flags().IS_DEFAULT(false); - mst_third.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint8_t", false)); - - - mst_third.common().label_seq().emplace_back(D); - - MD5 third_hash("third"); - for(int i = 0; i < 4; ++i) - { - mst_third.detail().name_hash()[i] = third_hash.digest[i]; - } - type_object->minimal().union_type().member_seq().emplace_back(mst_third); - - - // Header - //type_object->minimal().union_type().header().detail()... // Empty - - TypeIdentifier* identifier = new TypeIdentifier(); - identifier->_d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().union_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier->equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimpleWideUnion", identifier, type_object); - delete type_object; - delete identifier; - return TypeObjectFactory::get_instance()->get_type_object("SimpleWideUnion", false); -} - -const TypeObject* GetCompleteSimpleWideUnionObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleWideUnion", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_UNION); - - type_object->complete().union_type().union_flags().IS_FINAL(false); - type_object->complete().union_type().union_flags().IS_APPENDABLE(false); - type_object->complete().union_type().union_flags().IS_MUTABLE(false); - type_object->complete().union_type().union_flags().IS_NESTED(false); - type_object->complete().union_type().union_flags().IS_AUTOID_HASH(false); // Unsupported - - type_object->complete().union_type().discriminator().common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().IS_EXTERNAL(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_OPTIONAL(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_KEY(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().IS_DEFAULT(false); // Doesn't apply - - type_object->complete().union_type().discriminator().common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - MemberId memberId = 0; - CompleteUnionMember cst_first; - cst_first.common().member_id(memberId++); - cst_first.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_first.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_first.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_first.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - cst_first.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cst_first.common().member_flags().IS_KEY(false); // Doesn't apply - cst_first.common().member_flags().IS_DEFAULT(false); - cst_first.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - cst_first.common().label_seq().emplace_back(A); - - - cst_first.detail().name("first"); - - type_object->complete().union_type().member_seq().emplace_back(cst_first); - - CompleteUnionMember cst_second; - cst_second.common().member_id(memberId++); - cst_second.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_second.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_second.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_second.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - cst_second.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cst_second.common().member_flags().IS_KEY(false); // Doesn't apply - cst_second.common().member_flags().IS_DEFAULT(false); - cst_second.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int64_t", false)); - - cst_second.common().label_seq().emplace_back(B); - - - cst_second.detail().name("second"); - - type_object->complete().union_type().member_seq().emplace_back(cst_second); - - CompleteUnionMember cst_third; - cst_third.common().member_id(memberId++); - cst_third.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_third.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_third.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_third.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - cst_third.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cst_third.common().member_flags().IS_KEY(false); // Doesn't apply - cst_third.common().member_flags().IS_DEFAULT(false); - cst_third.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint8_t", false)); - - cst_third.common().label_seq().emplace_back(D); - - - cst_third.detail().name("third"); - - type_object->complete().union_type().member_seq().emplace_back(cst_third); - - - // Header - type_object->complete().union_type().header().detail().type_name("SimpleWideUnion"); - - TypeIdentifier* identifier = new TypeIdentifier(); - identifier->_d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().union_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier->equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimpleWideUnion", identifier, type_object); - delete type_object; - delete identifier; - return TypeObjectFactory::get_instance()->get_type_object("SimpleWideUnion", true); -} - - - -const TypeIdentifier* GetSimpleWideUnionStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("SimpleWideUnionStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetSimpleWideUnionStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("SimpleWideUnionStruct", complete); -} - -const TypeObject* GetSimpleWideUnionStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleWideUnionStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteSimpleWideUnionStructObject(); - } - //else - return GetMinimalSimpleWideUnionStructObject(); -} - -const TypeObject* GetMinimalSimpleWideUnionStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleWideUnionStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_union; - mst_my_union.common().member_id(memberId++); - mst_my_union.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_union.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_union.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_union.common().member_flags().IS_OPTIONAL(false); - mst_my_union.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_union.common().member_flags().IS_KEY(false); - mst_my_union.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_union.common().member_type_id(*GetSimpleWideUnionIdentifier(false)); - - MD5 my_union_hash("my_union"); - for(int i = 0; i < 4; ++i) - { - mst_my_union.detail().name_hash()[i] = my_union_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_union); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimpleWideUnionStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SimpleWideUnionStruct", false); -} - -const TypeObject* GetCompleteSimpleWideUnionStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleWideUnionStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_union; - cst_my_union.common().member_id(memberId++); - cst_my_union.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_union.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_union.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_union.common().member_flags().IS_OPTIONAL(false); - cst_my_union.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_union.common().member_flags().IS_KEY(false); - cst_my_union.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_union.common().member_type_id(*GetSimpleWideUnionIdentifier(true)); - - cst_my_union.detail().name("my_union"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_union); - - - // Header - type_object->complete().struct_type().header().detail().type_name("SimpleWideUnionStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimpleWideUnionStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SimpleWideUnionStruct", true); -} diff --git a/test/unittest/xtypes/idl/WideEnumTypeObject.h b/test/unittest/xtypes/idl/WideEnumTypeObject.h deleted file mode 100644 index 34ea60df451..00000000000 --- a/test/unittest/xtypes/idl/WideEnumTypeObject.h +++ /dev/null @@ -1,84 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file WideEnumTypeObject.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifndef _FAST_DDS_GENERATED_WIDEENUM_TYPE_OBJECT_H_ -#define _FAST_DDS_GENERATED_WIDEENUM_TYPE_OBJECT_H_ - - -#include -#include - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif -#else -#define eProsima_user_DllExport -#endif - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(WideEnum_SOURCE) -#define WideEnum_DllAPI __declspec( dllexport ) -#else -#define WideEnum_DllAPI __declspec( dllimport ) -#endif // WideEnum_SOURCE -#else -#define WideEnum_DllAPI -#endif -#else -#define WideEnum_DllAPI -#endif // _WIN32 - -using namespace eprosima::fastrtps::types; - -eProsima_user_DllExport void registerWideEnumTypes(); - -eProsima_user_DllExport const TypeIdentifier* GetMyEnumWideIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMyEnumWideObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalMyEnumWideObject(); -eProsima_user_DllExport const TypeObject* GetCompleteMyEnumWideObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetMyEnumWideStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMyEnumWideStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalMyEnumWideStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteMyEnumWideStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetSimpleWideUnionIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetSimpleWideUnionObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalSimpleWideUnionObject(); -eProsima_user_DllExport const TypeObject* GetCompleteSimpleWideUnionObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetSimpleWideUnionStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetSimpleWideUnionStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalSimpleWideUnionStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteSimpleWideUnionStructObject(); - - -#endif // _FAST_DDS_GENERATED_WIDEENUM_TYPE_OBJECT_H_ \ No newline at end of file diff --git a/test/unittest/xtypes/idl/WideEnumv1.cxx b/test/unittest/xtypes/idl/WideEnumv1.cxx deleted file mode 100644 index a49be8dfc84..00000000000 --- a/test/unittest/xtypes/idl/WideEnumv1.cxx +++ /dev/null @@ -1,858 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file WideEnum.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "WideEnum.h" - -#if FASTCDR_VERSION_MAJOR == 1 - -#include "WideEnumTypeObject.h" - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - -namespace helper { namespace internal { - -enum class Size { - UInt8, - UInt16, - UInt32, - UInt64, -}; - -constexpr Size get_size(int s) { - return (s <= 8 ) ? Size::UInt8: - (s <= 16) ? Size::UInt16: - (s <= 32) ? Size::UInt32: Size::UInt64; -} - -template -struct FindTypeH; - -template<> -struct FindTypeH { - using type = std::uint8_t; -}; - -template<> -struct FindTypeH { - using type = std::uint16_t; -}; - -template<> -struct FindTypeH { - using type = std::uint32_t; -}; - -template<> -struct FindTypeH { - using type = std::uint64_t; -}; -} - -template -struct FindType { - using type = typename internal::FindTypeH::type; -}; -} - -#define MyEnumWideStruct_max_cdr_typesize 8ULL; - -#define SimpleWideUnionStruct_max_cdr_typesize 24ULL; - - - - - -MyEnumWideStruct::MyEnumWideStruct() -{ - // MyEnumWide m_my_enum_wide - m_my_enum_wide = ::A; - - // Just to register all known types - registerWideEnumTypes(); -} - -MyEnumWideStruct::~MyEnumWideStruct() -{ -} - -MyEnumWideStruct::MyEnumWideStruct( - const MyEnumWideStruct& x) -{ - m_my_enum_wide = x.m_my_enum_wide; - -} - -MyEnumWideStruct::MyEnumWideStruct( - MyEnumWideStruct&& x) noexcept -{ - m_my_enum_wide = x.m_my_enum_wide; - -} - -MyEnumWideStruct& MyEnumWideStruct::operator =( - const MyEnumWideStruct& x) -{ - m_my_enum_wide = x.m_my_enum_wide; - - return *this; -} - -MyEnumWideStruct& MyEnumWideStruct::operator =( - MyEnumWideStruct&& x) noexcept -{ - m_my_enum_wide = x.m_my_enum_wide; - - return *this; -} - -bool MyEnumWideStruct::operator ==( - const MyEnumWideStruct& x) const -{ - return (m_my_enum_wide == x.m_my_enum_wide); -} - -bool MyEnumWideStruct::operator !=( - const MyEnumWideStruct& x) const -{ - return !(*this == x); -} - -size_t MyEnumWideStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return MyEnumWideStruct_max_cdr_typesize; -} - -size_t MyEnumWideStruct::getCdrSerializedSize( - const MyEnumWideStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - return current_alignment - initial_alignment; -} - - -void MyEnumWideStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << (uint32_t)m_my_enum_wide; - -} - -void MyEnumWideStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - { - uint32_t enum_value = 0; - dcdr >> enum_value; - m_my_enum_wide = (MyEnumWide)enum_value; - } - - -} - - -bool MyEnumWideStruct::isKeyDefined() -{ - return false; -} - -void MyEnumWideStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member my_enum_wide - * @param _my_enum_wide New value for member my_enum_wide - */ -void MyEnumWideStruct::my_enum_wide( - MyEnumWide _my_enum_wide) -{ - m_my_enum_wide = _my_enum_wide; -} - -/*! - * @brief This function returns the value of member my_enum_wide - * @return Value of member my_enum_wide - */ -MyEnumWide MyEnumWideStruct::my_enum_wide() const -{ - return m_my_enum_wide; -} - -/*! - * @brief This function returns a reference to member my_enum_wide - * @return Reference to member my_enum_wide - */ -MyEnumWide& MyEnumWideStruct::my_enum_wide() -{ - return m_my_enum_wide; -} - - - - - -SimpleWideUnion::SimpleWideUnion() -{ - m__d = A; - // long m_first - m_first = 0; - // long long m_second - m_second = 0; - // octet m_third - m_third = 0; -} - -SimpleWideUnion::~SimpleWideUnion() -{ -} - -SimpleWideUnion::SimpleWideUnion( - const SimpleWideUnion& x) -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - - case D: - m_third = x.m_third; - break; - - default: - break; - } -} - -SimpleWideUnion::SimpleWideUnion( - SimpleWideUnion&& x) noexcept -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - - case D: - m_third = x.m_third; - break; - - default: - break; - } -} - -SimpleWideUnion& SimpleWideUnion::operator =( - const SimpleWideUnion& x) -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - - case D: - m_third = x.m_third; - break; - - default: - break; - } - - return *this; -} - -SimpleWideUnion& SimpleWideUnion::operator =( - SimpleWideUnion&& x) noexcept -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - - case D: - m_third = x.m_third; - break; - - default: - break; - } - - return *this; -} - -bool SimpleWideUnion::operator ==( - const SimpleWideUnion& x) const -{ - if (m__d != x.m__d) - { - return false; - } - - switch(m__d) - { - case A: - return (m_first == x.m_first); - break; - - - case B: - return (m_second == x.m_second); - break; - - - case D: - return (m_third == x.m_third); - break; - - default: - break; - } - return false; -} - -bool SimpleWideUnion::operator !=( - const SimpleWideUnion& x) const -{ - return !(*this == x); -} - -void SimpleWideUnion::_d( - int32_t __d) -{ - bool b = false; - - switch(m__d) - { - case A: - switch(__d) - { - case A: - b = true; - break; - default: - break; - } - break; - - - case B: - switch(__d) - { - case B: - b = true; - break; - default: - break; - } - break; - - - case D: - switch(__d) - { - case D: - b = true; - break; - default: - break; - } - break; - - } - - if(!b) - { - throw BadParamException("Discriminator doesn't correspond with the selected union member"); - } - - m__d = __d; -} - -int32_t SimpleWideUnion::_d() const -{ - return m__d; -} - -int32_t& SimpleWideUnion::_d() -{ - return m__d; -} - -void SimpleWideUnion::first( - int32_t _first) -{ - m_first = _first; - m__d = A; - -} - -int32_t SimpleWideUnion::first() const -{ - bool b = false; - - switch(m__d) - { - case A: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first; -} - -int32_t& SimpleWideUnion::first() -{ - bool b = false; - - switch(m__d) - { - case A: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first; -} - - -void SimpleWideUnion::second( - int64_t _second) -{ - m_second = _second; - m__d = B; - -} - -int64_t SimpleWideUnion::second() const -{ - bool b = false; - - switch(m__d) - { - case B: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second; -} - -int64_t& SimpleWideUnion::second() -{ - bool b = false; - - switch(m__d) - { - case B: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second; -} - - -void SimpleWideUnion::third( - uint8_t _third) -{ - m_third = _third; - m__d = D; - -} - -uint8_t SimpleWideUnion::third() const -{ - bool b = false; - - switch(m__d) - { - case D: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_third; -} - -uint8_t& SimpleWideUnion::third() -{ - bool b = false; - - switch(m__d) - { - case D: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_third; -} - - -// TODO(Ricardo) Review -size_t SimpleWideUnion::getCdrSerializedSize( - const SimpleWideUnion& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - - switch(data.m__d) - { - case A: - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - break; - - - case B: - current_alignment += 8 + eprosima::fastcdr::Cdr::alignment(current_alignment, 8); - - break; - - - case D: - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - break; - - default: - break; - } - - return current_alignment - initial_alignment; -} - - -void SimpleWideUnion::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m__d; - - switch(m__d) - { - case A: - scdr << m_first; - - break; - - - case B: - scdr << m_second; - - break; - - - case D: - scdr << m_third; - - break; - - default: - break; - } -} - -void SimpleWideUnion::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m__d; - - - switch(m__d) - { - case A: - dcdr >> m_first; - - - break; - - - case B: - dcdr >> m_second; - - - break; - - - case D: - dcdr >> m_third; - - - break; - - default: - break; - } -} - - - - - -SimpleWideUnionStruct::SimpleWideUnionStruct() -{ - // SimpleWideUnion m_my_union - - - // Just to register all known types - registerWideEnumTypes(); -} - -SimpleWideUnionStruct::~SimpleWideUnionStruct() -{ -} - -SimpleWideUnionStruct::SimpleWideUnionStruct( - const SimpleWideUnionStruct& x) -{ - m_my_union = x.m_my_union; - -} - -SimpleWideUnionStruct::SimpleWideUnionStruct( - SimpleWideUnionStruct&& x) noexcept -{ - m_my_union = std::move(x.m_my_union); - -} - -SimpleWideUnionStruct& SimpleWideUnionStruct::operator =( - const SimpleWideUnionStruct& x) -{ - m_my_union = x.m_my_union; - - return *this; -} - -SimpleWideUnionStruct& SimpleWideUnionStruct::operator =( - SimpleWideUnionStruct&& x) noexcept -{ - m_my_union = std::move(x.m_my_union); - - return *this; -} - -bool SimpleWideUnionStruct::operator ==( - const SimpleWideUnionStruct& x) const -{ - return (m_my_union == x.m_my_union); -} - -bool SimpleWideUnionStruct::operator !=( - const SimpleWideUnionStruct& x) const -{ - return !(*this == x); -} - -size_t SimpleWideUnionStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return SimpleWideUnionStruct_max_cdr_typesize; -} - -size_t SimpleWideUnionStruct::getCdrSerializedSize( - const SimpleWideUnionStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += SimpleWideUnion::getCdrSerializedSize(data.my_union(), current_alignment); - - - return current_alignment - initial_alignment; -} - - -void SimpleWideUnionStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_union; - -} - -void SimpleWideUnionStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_union; - - -} - - -bool SimpleWideUnionStruct::isKeyDefined() -{ - return false; -} - -void SimpleWideUnionStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ -void SimpleWideUnionStruct::my_union( - const SimpleWideUnion& _my_union) -{ - m_my_union = _my_union; -} - -/*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ -void SimpleWideUnionStruct::my_union( - SimpleWideUnion&& _my_union) -{ - m_my_union = std::move(_my_union); -} - -/*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ -const SimpleWideUnion& SimpleWideUnionStruct::my_union() const -{ - return m_my_union; -} - -/*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ -SimpleWideUnion& SimpleWideUnionStruct::my_union() -{ - return m_my_union; -} - - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/test/unittest/xtypes/idl/WideEnumv1.h b/test/unittest/xtypes/idl/WideEnumv1.h deleted file mode 100644 index aac7aeb1a72..00000000000 --- a/test/unittest/xtypes/idl/WideEnumv1.h +++ /dev/null @@ -1,560 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file WideEnum.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#include - -#if FASTCDR_VERSION_MAJOR == 1 - -#ifndef _FAST_DDS_GENERATED_WIDEENUM_H_ -#define _FAST_DDS_GENERATED_WIDEENUM_H_ - - -#include - -#include -#include -#include -#include -#include -#include -#include - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define eProsima_user_DllExport -#endif // _WIN32 - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(WIDEENUM_SOURCE) -#define WIDEENUM_DllAPI __declspec( dllexport ) -#else -#define WIDEENUM_DllAPI __declspec( dllimport ) -#endif // WIDEENUM_SOURCE -#else -#define WIDEENUM_DllAPI -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define WIDEENUM_DllAPI -#endif // _WIN32 - -namespace eprosima { -namespace fastcdr { -class Cdr; -} // namespace fastcdr -} // namespace eprosima - - - -/*! - * @brief This class represents the enumeration MyEnumWide defined by the user in the IDL file. - * @ingroup WideEnum - */ -enum MyEnumWide : uint32_t -{ - A, - B, - C, - D -}; - - -/*! - * @brief This class represents the structure MyEnumWideStruct defined by the user in the IDL file. - * @ingroup WideEnum - */ -class MyEnumWideStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MyEnumWideStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MyEnumWideStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MyEnumWideStruct that will be copied. - */ - eProsima_user_DllExport MyEnumWideStruct( - const MyEnumWideStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MyEnumWideStruct that will be copied. - */ - eProsima_user_DllExport MyEnumWideStruct( - MyEnumWideStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MyEnumWideStruct that will be copied. - */ - eProsima_user_DllExport MyEnumWideStruct& operator =( - const MyEnumWideStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MyEnumWideStruct that will be copied. - */ - eProsima_user_DllExport MyEnumWideStruct& operator =( - MyEnumWideStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MyEnumWideStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MyEnumWideStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x MyEnumWideStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MyEnumWideStruct& x) const; - - /*! - * @brief This function sets a value in member my_enum_wide - * @param _my_enum_wide New value for member my_enum_wide - */ - eProsima_user_DllExport void my_enum_wide( - MyEnumWide _my_enum_wide); - - /*! - * @brief This function returns the value of member my_enum_wide - * @return Value of member my_enum_wide - */ - eProsima_user_DllExport MyEnumWide my_enum_wide() const; - - /*! - * @brief This function returns a reference to member my_enum_wide - * @return Reference to member my_enum_wide - */ - eProsima_user_DllExport MyEnumWide& my_enum_wide(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const MyEnumWideStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - MyEnumWide m_my_enum_wide; - -}; - - - -/*! - * @brief This class represents the union SimpleWideUnion defined by the user in the IDL file. - * @ingroup WideEnum - */ -class SimpleWideUnion -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimpleWideUnion(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimpleWideUnion(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimpleWideUnion that will be copied. - */ - eProsima_user_DllExport SimpleWideUnion( - const SimpleWideUnion& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimpleWideUnion that will be copied. - */ - eProsima_user_DllExport SimpleWideUnion( - SimpleWideUnion&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimpleWideUnion that will be copied. - */ - eProsima_user_DllExport SimpleWideUnion& operator =( - const SimpleWideUnion& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimpleWideUnion that will be copied. - */ - eProsima_user_DllExport SimpleWideUnion& operator =( - SimpleWideUnion&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimpleWideUnion object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimpleWideUnion& x) const; - - /*! - * @brief Comparison operator. - * @param x SimpleWideUnion object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimpleWideUnion& x) const; - - /*! - * @brief This function sets the discriminator value. - * @param __d New value for the discriminator. - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the new value doesn't correspond to the selected union member. - */ - eProsima_user_DllExport void _d( - int32_t __d); - - /*! - * @brief This function returns the value of the discriminator. - * @return Value of the discriminator - */ - eProsima_user_DllExport int32_t _d() const; - - /*! - * @brief This function returns a reference to the discriminator. - * @return Reference to the discriminator. - */ - eProsima_user_DllExport int32_t& _d(); - - /*! - * @brief This function sets a value in member first - * @param _first New value for member first - */ - eProsima_user_DllExport void first( - int32_t _first); - - /*! - * @brief This function returns the value of member first - * @return Value of member first - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t first() const; - - /*! - * @brief This function returns a reference to member first - * @return Reference to member first - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t& first(); - - - /*! - * @brief This function sets a value in member second - * @param _second New value for member second - */ - eProsima_user_DllExport void second( - int64_t _second); - - /*! - * @brief This function returns the value of member second - * @return Value of member second - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t second() const; - - /*! - * @brief This function returns a reference to member second - * @return Reference to member second - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t& second(); - - - /*! - * @brief This function sets a value in member third - * @param _third New value for member third - */ - eProsima_user_DllExport void third( - uint8_t _third); - - /*! - * @brief This function returns the value of member third - * @return Value of member third - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport uint8_t third() const; - - /*! - * @brief This function returns a reference to member third - * @return Reference to member third - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport uint8_t& third(); - - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const SimpleWideUnion& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - -private: - - int32_t m__d; - - int32_t m_first; - int64_t m_second; - uint8_t m_third; -}; - - - -/*! - * @brief This class represents the structure SimpleWideUnionStruct defined by the user in the IDL file. - * @ingroup WideEnum - */ -class SimpleWideUnionStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimpleWideUnionStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimpleWideUnionStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimpleWideUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleWideUnionStruct( - const SimpleWideUnionStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimpleWideUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleWideUnionStruct( - SimpleWideUnionStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimpleWideUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleWideUnionStruct& operator =( - const SimpleWideUnionStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimpleWideUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleWideUnionStruct& operator =( - SimpleWideUnionStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimpleWideUnionStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimpleWideUnionStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x SimpleWideUnionStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimpleWideUnionStruct& x) const; - - /*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ - eProsima_user_DllExport void my_union( - const SimpleWideUnion& _my_union); - - /*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ - eProsima_user_DllExport void my_union( - SimpleWideUnion&& _my_union); - - /*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ - eProsima_user_DllExport const SimpleWideUnion& my_union() const; - - /*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ - eProsima_user_DllExport SimpleWideUnion& my_union(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const SimpleWideUnionStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - SimpleWideUnion m_my_union; - -}; - - -#endif // _FAST_DDS_GENERATED_WIDEENUM_H_ - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/test/utils/ScopedLogs.hpp b/test/utils/ScopedLogs.hpp new file mode 100644 index 00000000000..72cd50fbdbc --- /dev/null +++ b/test/utils/ScopedLogs.hpp @@ -0,0 +1,69 @@ +// Copyright 2024 Proyectos y Sistemas de Mantenimiento SL (eProsima). +// +// Licensed 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 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#ifndef _TEST_UTILS_SCOPEDLOGS_HPP_ +#define _TEST_UTILS_SCOPEDLOGS_HPP_ + +#include + +#include + +namespace eprosima { +namespace fastdds { +namespace testing { + +//! RAII to setup Logging +struct ScopeLogs +{ + //! Set a specific category filter + ScopeLogs( + std::string category_filter) + { +#ifdef __cpp_lib_make_unique + filter_ = std::make_unique(dds::Log::GetCategoryFilter()); +#else + filter_ = std::unique_ptr(new std::regex(dds::Log::GetCategoryFilter())); +#endif // ifdef __cpp_lib_make_unique + dds::Log::SetCategoryFilter(std::regex{category_filter}); + } + + //! Set a specified level + ScopeLogs( + dds::Log::Kind new_verbosity = dds::Log::Error) + { + old_ = dds::Log::GetVerbosity(); + dds::Log::SetVerbosity(new_verbosity); + } + + ~ScopeLogs() + { + if (filter_) + { + dds::Log::SetCategoryFilter(*filter_); + } + else + { + dds::Log::SetVerbosity(old_); + } + } + + dds::Log::Kind old_; + std::unique_ptr filter_; +}; + +} // namespace testing +} // namespace fastdds +} // namespace eprosima + +#endif // _TEST_UTILS_SCOPEDLOGS_HPP_ diff --git a/test/xtypes/CMakeLists.txt b/test/xtypes/CMakeLists.txt deleted file mode 100644 index 1719a3fdead..00000000000 --- a/test/xtypes/CMakeLists.txt +++ /dev/null @@ -1,44 +0,0 @@ -# Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -# -# Licensed 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 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -if(WIN32) - add_definitions( - -D_WIN32_WINNT=0x0601 - -D_CRT_SECURE_NO_WARNINGS - ) -endif() - -############################################################################### -# Unit tests -############################################################################### -set(XTYPES_TESTS_SOURCE XTypesTests.cpp - idl/Types.cxx - idl/Typesv1.cxx - idl/TypesPubSubTypes.cxx - idl/TypesTypeObject.cxx - TestPublisher.cpp - TestSubscriber.cpp - ) - -add_executable(XTypesBlackBoxTests ${XTYPES_TESTS_SOURCE}) -target_compile_definitions(XTypesBlackBoxTests PRIVATE - EPROSIMA_SHAPES_DLL_EXPORT - BUILD_SHARED_LIBS - BOOST_ASIO_STANDALONE - ASIO_STANDALONE - $<$>,$>:__DEBUG> - $<$:__INTERNALDEBUG> # Internal debug activated. - ) -target_include_directories(XTypesBlackBoxTests PRIVATE ${Asio_INCLUDE_DIR}) -target_link_libraries(XTypesBlackBoxTests fastrtps fastcdr GTest::gtest) -gtest_discover_tests(XTypesBlackBoxTests) diff --git a/test/xtypes/TestPublisher.cpp b/test/xtypes/TestPublisher.cpp deleted file mode 100644 index 5076ee6eda4..00000000000 --- a/test/xtypes/TestPublisher.cpp +++ /dev/null @@ -1,358 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -/** - * @file TestPublisher.cpp - * - */ - -#include "TestPublisher.h" - -#include -#include - -#include - -#include - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -using namespace eprosima::fastdds::dds; -using namespace eprosima::fastdds::dds::xtypes; -using namespace eprosima::fastrtps; -using namespace eprosima::fastrtps::rtps; - -TestPublisher::TestPublisher() - : m_iSamples(-1) - , m_sentSamples(0) - , m_iWaitTime(1000) - , m_Data(nullptr) - , m_bInitialized(false) - , using_typelookup_(false) - , tls_callback_called_(false) - , mp_participant(nullptr) - , mp_publisher(nullptr) - , writer_(nullptr) - , part_listener_(this) - , m_pubListener(this) - -{ -} - -bool TestPublisher::init( - const std::string& topicName, - int domain, - eprosima::fastdds::dds::TypeSupport type, - const eprosima::fastrtps::types::TypeObject* type_object, - const eprosima::fastrtps::types::TypeIdentifier* type_identifier, - const eprosima::fastrtps::types::TypeInformation* type_info, - const std::string& name, - const eprosima::fastrtps::DataRepresentationQosPolicy* dataRepresentationQos, - bool use_typelookup) -{ - m_Name = name; - m_Type.swap(type); - using_typelookup_ = use_typelookup; - - DomainParticipantQos pqos; - pqos.wire_protocol().builtin.discovery_config.leaseDuration = c_TimeInfinite; - pqos.wire_protocol().builtin.discovery_config.leaseDuration_announcementperiod = Duration_t(1, 0); - pqos.wire_protocol().builtin.typelookup_config.use_client = using_typelookup_; - pqos.wire_protocol().builtin.typelookup_config.use_server = using_typelookup_; - pqos.name(m_Name.c_str()); - - //Do not enable entities on creation - DomainParticipantFactoryQos factory_qos; - factory_qos.entity_factory().autoenable_created_entities = false; - DomainParticipantFactory::get_instance()->set_qos(factory_qos); - - mp_participant = DomainParticipantFactory::get_instance()->create_participant(domain, pqos, &part_listener_); - if (mp_participant == nullptr) - { - return false; - } - mp_participant->enable(); - - // CREATE THE PUBLISHER - std::string data_type = m_Type != nullptr ? m_Type->getName() : ""; - DataWriterQos wqos; - - //REGISTER THE TYPE - if (m_Type != nullptr) - { - m_Type->auto_fill_type_information(false); - m_Type->auto_fill_type_object(false); - if (type_object != nullptr) - { - m_Type->type_object(*type_object); - } - if (type_identifier != nullptr) - { - m_Type->type_identifier(*type_identifier); - } - if (type_info != nullptr) - { - m_Type->type_information(*type_info); - } - m_Type.register_type(mp_participant); - } - - std::ostringstream t; - t << topicName << "_" << asio::ip::host_name() << "_" << domain; - topic_name_ = t.str(); - - if (dataRepresentationQos != nullptr) - { - wqos.representation(*dataRepresentationQos); - } - - if (m_Type != nullptr) - { - mp_publisher = mp_participant->create_publisher(PUBLISHER_QOS_DEFAULT, nullptr); - if (mp_publisher == nullptr) - { - return false; - } - - mp_topic = mp_participant->create_topic(t.str(), data_type, TOPIC_QOS_DEFAULT); - if (mp_topic == nullptr) - { - return false; - } - - writer_ = mp_publisher->create_datawriter(mp_topic, wqos, &m_pubListener); - - m_Data = m_Type->createData(); - } - - m_bInitialized = true; - writer_qos = wqos; - - return true; -} - -TestPublisher::~TestPublisher() -{ - if (m_Type) - { - m_Type->deleteData(m_Data); - } - if (writer_) - { - mp_publisher->delete_datawriter(writer_); - } - if (mp_publisher) - { - mp_participant->delete_publisher(mp_publisher); - } - if (mp_topic) - { - mp_participant->delete_topic(mp_topic); - } - DomainParticipantFactory::get_instance()->delete_participant(mp_participant); -} - -void TestPublisher::waitDiscovery( - bool expectMatch, - int maxWait) -{ - std::unique_lock lock(m_mDiscovery); - - if (m_pubListener.n_matched == 0) - { - m_cvDiscovery.wait_for(lock, std::chrono::seconds(maxWait)); - } - - if (expectMatch) - { - ASSERT_GE(m_pubListener.n_matched, 1); - } - else - { - ASSERT_EQ(m_pubListener.n_matched, 0); - } -} - -void TestPublisher::waitTypeDiscovery( - bool expectMatch, - int maxWait) -{ - std::unique_lock lock(mtx_type_discovery_); - - if (!part_listener_.discovered_) - { - cv_type_discovery_.wait_for(lock, std::chrono::seconds(maxWait)); - } - - if (expectMatch) - { - ASSERT_TRUE(part_listener_.discovered_); - } - else - { - ASSERT_FALSE(part_listener_.discovered_); - } -} - -void TestPublisher::matched() -{ - std::unique_lock lock(m_mDiscovery); - ++m_pubListener.n_matched; - if (m_pubListener.n_matched >= 1) - { - m_cvDiscovery.notify_one(); - } -} - -TestPublisher::PubListener::PubListener( - TestPublisher* parent) - : mParent(parent) - , n_matched(0) -{ -} - -void TestPublisher::PubListener::on_publication_matched( - eprosima::fastdds::dds::DataWriter*, - const eprosima::fastdds::dds::PublicationMatchedStatus& info) -{ - if (info.current_count_change > 0) - { - std::cout << mParent->m_Name << " matched." << std::endl; - mParent->matched(); - } - else - { - std::cout << mParent->m_Name << " unmatched." << std::endl; - } -} - -void TestPublisher::PartListener::on_type_discovery( - eprosima::fastdds::dds::DomainParticipant*, - const rtps::SampleIdentity&, - const eprosima::fastrtps::string_255& topic, - const eprosima::fastrtps::types::TypeIdentifier*, - const eprosima::fastrtps::types::TypeObject*, - eprosima::fastrtps::types::DynamicType_ptr dyn_type) -{ - if (!parent_->using_typelookup_ || parent_->tls_callback_called_) - { - std::cout << "Discovered type: " << dyn_type->get_name() << " on topic: " << topic << std::endl; - std::lock_guard lock(parent_->mtx_type_discovery_); - discovered_ = true; - parent_->disc_type_ = dyn_type; - parent_->cv_type_discovery_.notify_one(); - } -} - -void TestPublisher::PartListener::on_type_information_received( - eprosima::fastdds::dds::DomainParticipant*, - const eprosima::fastrtps::string_255 topic_name, - const eprosima::fastrtps::string_255 type_name, - const eprosima::fastrtps::types::TypeInformation& type_information) -{ - std::function callback = - [this, topic_name](const std::string&, const types::DynamicType_ptr type) - { - std::cout << "Callback for type: " << type->get_name() << " on topic: " << topic_name << std::endl; - parent_->tls_callback_called_ = true; - on_type_discovery(nullptr, rtps::SampleIdentity(), topic_name, nullptr, nullptr, type); - parent_->tls_callback_called_ = false; - }; - - std::cout << "Received type information: " << type_name << " on topic: " << topic_name << std::endl; - parent_->mp_participant->register_remote_type(type_information, type_name.to_string(), callback); -} - -void TestPublisher::runThread() -{ - int iPrevCount = 0; - std::cout << m_Name << " running..." << std::endl; - while (!publish() && iPrevCount < m_iSamples) - { - std::this_thread::sleep_for(std::chrono::milliseconds(m_iWaitTime)); - ++iPrevCount; - } -} - -void TestPublisher::run() -{ - std::thread thread(&TestPublisher::runThread, this); - thread.join(); -} - -bool TestPublisher::publish() -{ - if (m_pubListener.n_matched > 0) - { - if (writer_->write(m_Data)) - { - ++m_sentSamples; - //std::cout << m_Name << " sent a total of " << m_sentSamples << " samples." << std::endl; - return true; - } - //else - //{ - // std::cout << m_Name << " failed to send " << (m_sentSamples + 1) << " sample." << std::endl; - //} - } - return false; -} - -DataWriter* TestPublisher::create_datawriter() -{ - if (mp_publisher == nullptr) - { - mp_publisher = mp_participant->create_publisher(PUBLISHER_QOS_DEFAULT, nullptr); - - if (mp_publisher == nullptr) - { - return nullptr; - } - } - mp_topic = mp_participant->create_topic(topic_name_, disc_type_->get_name(), TOPIC_QOS_DEFAULT); - if (mp_topic == nullptr) - { - return nullptr; - } - return mp_publisher->create_datawriter(mp_topic, writer_qos, &m_pubListener); - -} - -void TestPublisher::delete_datawriter( - eprosima::fastdds::dds::DataWriter* writer) -{ - mp_publisher->delete_datawriter(writer); -} - -bool TestPublisher::register_discovered_type() -{ - TypeSupport type(disc_type_); - type->auto_fill_type_object(true); - type->auto_fill_type_information(true); - return type.register_type(mp_participant, disc_type_->get_name()) == ReturnCode_t::RETCODE_OK; -} diff --git a/test/xtypes/TestPublisher.h b/test/xtypes/TestPublisher.h deleted file mode 100644 index 5eef5b1359b..00000000000 --- a/test/xtypes/TestPublisher.h +++ /dev/null @@ -1,207 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file TestPublisher.h - * - */ - -#ifndef _TEST_PUBLISHER_H_ -#define _TEST_PUBLISHER_H_ - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -class TestPublisher -{ -public: - - TestPublisher(); - - virtual ~TestPublisher(); - - //!Initialize - bool init( - const std::string& topicName, - int domain, - eprosima::fastdds::dds::TypeSupport type, - const eprosima::fastrtps::types::TypeObject* type_object, - const eprosima::fastrtps::types::TypeIdentifier* type_identifier, - const eprosima::fastrtps::types::TypeInformation* type_info, - const std::string& name, - const eprosima::fastrtps::DataRepresentationQosPolicy* dataRepresentationQos, - bool use_typelookup = false); - - //!Publish a sample - bool publish(); - - //!Run for number samples - void run(); - - // Auxiliar test methods - bool isInitialized() const - { - return m_bInitialized; - } - - void waitDiscovery( - bool expectMatch = true, - int maxWait = 10); - - void waitTypeDiscovery( - bool expectMatch = true, - int maxWait = 10); - - void matched(); - - bool isMatched() - { - return m_pubListener.n_matched > 0; - } - - void send() - { - waitDiscovery(); publish(); - } - - eprosima::fastrtps::types::DynamicType_ptr discovered_type() const - { - return disc_type_; - } - - eprosima::fastdds::dds::DataWriter* create_datawriter(); - - void delete_datawriter( - eprosima::fastdds::dds::DataWriter* writer); - - bool register_discovered_type(); - - eprosima::fastdds::dds::TypeSupport m_Type; - -private: - - std::string m_Name; - - std::string topic_name_; - - - - int m_iSamples; - - int m_sentSamples; - - int m_iWaitTime; - - void* m_Data; - - bool m_bInitialized; - - bool using_typelookup_; - - bool tls_callback_called_; - - std::mutex m_mDiscovery; - - std::mutex mtx_type_discovery_; - - std::condition_variable m_cvDiscovery; - - std::condition_variable cv_type_discovery_; - - eprosima::fastdds::dds::DomainParticipant* mp_participant; - - eprosima::fastdds::dds::Publisher* mp_publisher; - - eprosima::fastdds::dds::Topic* mp_topic; - - eprosima::fastdds::dds::DataWriter* writer_; - - eprosima::fastrtps::types::DynamicType_ptr disc_type_; - - eprosima::fastdds::dds::DataWriterQos writer_qos; - - class PartListener : public eprosima::fastdds::dds::DomainParticipantListener - { -public: - - PartListener( - TestPublisher* parent) - : parent_(parent) - , discovered_(false) - { - } - - ~PartListener() override - { - } - - void on_type_discovery( - eprosima::fastdds::dds::DomainParticipant* participant, - const eprosima::fastrtps::rtps::SampleIdentity& request_sample_id, - const eprosima::fastrtps::string_255& topic, - const eprosima::fastrtps::types::TypeIdentifier* identifier, - const eprosima::fastrtps::types::TypeObject* object, - eprosima::fastrtps::types::DynamicType_ptr dyn_type) override; - - void on_type_information_received( - eprosima::fastdds::dds::DomainParticipant* participant, - const eprosima::fastrtps::string_255 topic_name, - const eprosima::fastrtps::string_255 type_name, - const eprosima::fastrtps::types::TypeInformation& type_information) override; - - TestPublisher* parent_; - std::atomic discovered_; - - } part_listener_; - - class PubListener : public eprosima::fastdds::dds::DataWriterListener - { -public: - - PubListener() - { - } - - PubListener( - TestPublisher* parent); - - ~PubListener() override - { - } - - void on_publication_matched( - eprosima::fastdds::dds::DataWriter* writer, - const eprosima::fastdds::dds::PublicationMatchedStatus& info) override; - - TestPublisher* mParent; - int n_matched; - } m_pubListener; - - void runThread(); -}; - - - -#endif /* _TEST_PUBLISHER_H_ */ diff --git a/test/xtypes/TestSubscriber.cpp b/test/xtypes/TestSubscriber.cpp deleted file mode 100644 index b524fba7a7e..00000000000 --- a/test/xtypes/TestSubscriber.cpp +++ /dev/null @@ -1,379 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file TestSubscriber.cpp - * - */ - -#include "TestSubscriber.h" -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - - -#include - -using namespace eprosima::fastdds::dds; -using namespace eprosima::fastrtps; -using namespace eprosima::fastrtps::rtps; - -TestSubscriber::TestSubscriber() - : mp_participant(nullptr) - , mp_subscriber(nullptr) - , reader_(nullptr) - , topic_(nullptr) - , m_Data(nullptr) - , m_bInitialized(false) - , using_typelookup_(false) - , tls_callback_called_(false) - , dataRepresentationQos_(nullptr) - , typeConsistencyQos_(nullptr) - , part_listener_(this) - , m_subListener(this) -{ -} - -bool TestSubscriber::init( - const std::string& topicName, - int domain, - eprosima::fastdds::dds::TypeSupport type, - const eprosima::fastrtps::types::TypeObject* type_object, - const eprosima::fastrtps::types::TypeIdentifier* type_identifier, - const eprosima::fastrtps::types::TypeInformation* type_info, - const std::string& name, - const eprosima::fastrtps::DataRepresentationQosPolicy* dataRepresentationQos, - const eprosima::fastrtps::TypeConsistencyEnforcementQosPolicy* typeConsistencyQos, - bool use_typelookup) -{ - dataRepresentationQos_ = dataRepresentationQos; - typeConsistencyQos_ = typeConsistencyQos; - - m_Name = name; - m_Type.swap(type); - using_typelookup_ = use_typelookup; - DomainParticipantQos pqos; - pqos.wire_protocol().builtin.discovery_config.leaseDuration = c_TimeInfinite; - pqos.wire_protocol().builtin.discovery_config.leaseDuration_announcementperiod = Duration_t(1, 0); - pqos.wire_protocol().builtin.typelookup_config.use_client = using_typelookup_; - pqos.wire_protocol().builtin.typelookup_config.use_server = using_typelookup_; - pqos.name(m_Name.c_str()); - - //Do not enable entities on creation - DomainParticipantFactoryQos factory_qos; - factory_qos.entity_factory().autoenable_created_entities = false; - DomainParticipantFactory::get_instance()->set_qos(factory_qos); - - mp_participant = DomainParticipantFactory::get_instance()->create_participant(domain, pqos, &part_listener_); - if (mp_participant == nullptr) - { - std::cout << "ERROR" << std::endl; - return false; - } - mp_participant->enable(); - - std::ostringstream t; - t << topicName << "_" << asio::ip::host_name() << "_" << domain; - topic_name_ = t.str(); - - //REGISTER THE TYPE - if (m_Type != nullptr) - { - if (type_object != nullptr) - { - m_Type->type_object(*type_object); - } - if (type_identifier != nullptr) - { - m_Type->type_identifier(*type_identifier); - } - if (type_info != nullptr) - { - m_Type->type_information(*type_info); - } - - m_Type->auto_fill_type_information(false); - m_Type->auto_fill_type_object(false); - m_Type.register_type(mp_participant); - - //CREATE THE TOPIC - topic_ = mp_participant->create_topic( - topic_name_, - m_Type->getName(), - TOPIC_QOS_DEFAULT); - - if (topic_ == nullptr) - { - return false; - } - - //CREATE THE SUBSCRIBER - mp_subscriber = mp_participant->create_subscriber(SUBSCRIBER_QOS_DEFAULT, nullptr); - - if (mp_subscriber == nullptr) - { - return false; - } - - //CREATE THE DATAREADER - reader_qos = mp_subscriber->get_default_datareader_qos(); - if (typeConsistencyQos_ != nullptr) - { - reader_qos.type_consistency().type_consistency = *typeConsistencyQos_; - } - if (dataRepresentationQos_ != nullptr) - { - reader_qos.type_consistency().representation = *dataRepresentationQos_; - } - reader_ = mp_subscriber->create_datareader(topic_, reader_qos, &m_subListener); - - if (reader_ == nullptr) - { - return false; - } - - m_Data = m_Type->createData(); - } - m_bInitialized = true; - - return true; -} - -TestSubscriber::~TestSubscriber() -{ - if (m_Type != nullptr) - { - m_Type->deleteData(m_Data); - } - - if (reader_ != nullptr) - { - mp_subscriber->delete_datareader(reader_); - } - if (mp_subscriber != nullptr) - { - mp_participant->delete_subscriber(mp_subscriber); - } - if (topic_ != nullptr) - { - mp_participant->delete_topic(topic_); - } - DomainParticipantFactory::get_instance()->delete_participant(mp_participant); -} - -TestSubscriber::SubListener::SubListener( - TestSubscriber* parent) - : mParent(parent) - , n_matched(0) - , n_samples(0) -{ -} - -void TestSubscriber::waitDiscovery( - bool expectMatch, - int maxWait) -{ - std::unique_lock lock(m_mDiscovery); - - if (m_subListener.n_matched == 0) - { - m_cvDiscovery.wait_for(lock, std::chrono::seconds(maxWait)); - } - - if (expectMatch) - { - ASSERT_GE(m_subListener.n_matched, 1); - } - else - { - ASSERT_EQ(m_subListener.n_matched, 0); - } -} - -void TestSubscriber::waitTypeDiscovery( - bool expectMatch, - int maxWait) -{ - std::unique_lock lock(mtx_type_discovery_); - - if (!part_listener_.discovered_) - { - cv_type_discovery_.wait_for(lock, std::chrono::seconds(maxWait)); - } - - if (expectMatch) - { - ASSERT_TRUE(part_listener_.discovered_); - } - else - { - ASSERT_FALSE(part_listener_.discovered_); - } -} - -void TestSubscriber::matched( - bool unmatched) -{ - std::unique_lock lock(m_mDiscovery); - if (unmatched) - { - --m_subListener.n_matched; - } - else - { - ++m_subListener.n_matched; - } - if (m_subListener.n_matched >= 1) - { - m_cvDiscovery.notify_one(); - } -} - -void TestSubscriber::SubListener::on_subscription_matched( - eprosima::fastdds::dds::DataReader*, - const eprosima::fastdds::dds::SubscriptionMatchedStatus& info) -{ - if (info.current_count_change > 0) - { - mParent->matched(); - std::cout << mParent->m_Name << " matched." << std::endl; - } - else if (info.current_count_change < 0) - { - mParent->matched(true); - std::cout << mParent->m_Name << " unmatched." << std::endl; - } -} - -void TestSubscriber::SubListener::on_data_available( - eprosima::fastdds::dds::DataReader* reader) -{ - SampleInfo info; - if (!!reader->take_next_sample(mParent->m_Data, &info)) - { - if (info.valid_data) - { - ++n_samples; - mParent->cv_.notify_one(); - //std::cout << mParent->m_Name << " received a total of " << n_samples << " samples." << std::endl; - } - } -} - -void TestSubscriber::PartListener::on_type_discovery( - eprosima::fastdds::dds::DomainParticipant*, - const rtps::SampleIdentity&, - const eprosima::fastrtps::string_255& topic, - const eprosima::fastrtps::types::TypeIdentifier*, - const eprosima::fastrtps::types::TypeObject*, - eprosima::fastrtps::types::DynamicType_ptr dyn_type) -{ - if (!parent_->using_typelookup_ || parent_->tls_callback_called_) - { - std::cout << "Discovered type: " << dyn_type->get_name() << " on topic: " << topic << std::endl; - std::lock_guard lock(parent_->mtx_type_discovery_); - discovered_ = true; - parent_->disc_type_ = dyn_type; - parent_->cv_type_discovery_.notify_one(); - } -} - -void TestSubscriber::PartListener::on_type_information_received( - eprosima::fastdds::dds::DomainParticipant*, - const eprosima::fastrtps::string_255 topic_name, - const eprosima::fastrtps::string_255 type_name, - const eprosima::fastrtps::types::TypeInformation& type_information) -{ - std::function callback = - [this, topic_name](const std::string&, const types::DynamicType_ptr type) - { - std::cout << "Callback for type: " << type->get_name() << " on topic: " << topic_name << std::endl; - parent_->tls_callback_called_ = true; - on_type_discovery(nullptr, rtps::SampleIdentity(), topic_name, nullptr, nullptr, type); - parent_->tls_callback_called_ = false; - }; - - std::cout << "Received type information: " << type_name << " on topic: " << topic_name << std::endl; - parent_->mp_participant->register_remote_type(type_information, type_name.to_string(), callback); -} - -DataReader* TestSubscriber::create_datareader() -{ - assert (topic_ == nullptr); - assert (mp_subscriber == nullptr); - - //CREATE THE TOPIC - topic_ = mp_participant->create_topic( - topic_name_, - disc_type_->get_name(), - TOPIC_QOS_DEFAULT); - - if (topic_ == nullptr) - { - return nullptr; - } - - mp_subscriber = mp_participant->create_subscriber(SUBSCRIBER_QOS_DEFAULT, nullptr); - - if (mp_subscriber == nullptr) - { - return nullptr; - } - - reader_qos = mp_subscriber->get_default_datareader_qos(); - if (typeConsistencyQos_ != nullptr) - { - reader_qos.type_consistency().type_consistency = *typeConsistencyQos_; - } - if (dataRepresentationQos_ != nullptr) - { - reader_qos.type_consistency().representation = *dataRepresentationQos_; - } - reader_ = mp_subscriber->create_datareader(topic_, reader_qos, &m_subListener); - return reader_; -} - -void TestSubscriber::delete_datareader( - eprosima::fastdds::dds::DataReader* reader) -{ - mp_subscriber->delete_datareader(reader); -} - -bool TestSubscriber::register_discovered_type() -{ - TypeSupport type(disc_type_); - type->auto_fill_type_object(true); - type->auto_fill_type_information(true); - return type.register_type(mp_participant, disc_type_->get_name()) == ReturnCode_t::RETCODE_OK; -} - -void TestSubscriber::run() -{ - std::cout << m_Name << " running..." << std::endl; - std::cin.ignore(); -} diff --git a/test/xtypes/TestSubscriber.h b/test/xtypes/TestSubscriber.h deleted file mode 100644 index 35476289132..00000000000 --- a/test/xtypes/TestSubscriber.h +++ /dev/null @@ -1,187 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file TestSubscriber.h - * - */ - -#ifndef _TEST_SUBSCRIBER_H_ -#define _TEST_SUBSCRIBER_H_ - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#include -#include - -class TestSubscriber -{ -public: - - TestSubscriber(); - - virtual ~TestSubscriber(); - - //!Initialize the subscriber - bool init( - const std::string& topicName, - int domain, - eprosima::fastdds::dds::TypeSupport type, - const eprosima::fastrtps::types::TypeObject* type_object, - const eprosima::fastrtps::types::TypeIdentifier* type_identifier, - const eprosima::fastrtps::types::TypeInformation* type_info, - const std::string& name, - const eprosima::fastrtps::DataRepresentationQosPolicy* dataRepresentationQos, - const eprosima::fastrtps::TypeConsistencyEnforcementQosPolicy* typeConsistencyQos, - bool use_typelookup = false); - - //!RUN the subscriber - void run(); - - // Auxiliar test methods - bool isInitialized() const - { - return m_bInitialized; - } - - void waitDiscovery( - bool expectMatch = true, - int maxWait = 10); - void waitTypeDiscovery( - bool expectMatch = true, - int maxWait = 10); - void matched( - bool unmatched = false); - bool isMatched() - { - return m_subListener.n_matched > 0; - } - - uint32_t samplesReceived() - { - return m_subListener.n_samples; - } - - eprosima::fastrtps::types::DynamicType_ptr discovered_type() const - { - return disc_type_; - } - - bool register_discovered_type(); - - eprosima::fastdds::dds::DataReader* create_datareader(); - - void delete_datareader( - eprosima::fastdds::dds::DataReader* reader); - - eprosima::fastdds::dds::TypeSupport m_Type; - -private: - - std::string m_Name; - - eprosima::fastdds::dds::DomainParticipant* mp_participant; - eprosima::fastdds::dds::Subscriber* mp_subscriber; - eprosima::fastdds::dds::DataReader* reader_; - eprosima::fastdds::dds::Topic* topic_; - void* m_Data; - bool m_bInitialized; - std::mutex m_mDiscovery; - std::mutex mtx_type_discovery_; - std::condition_variable m_cvDiscovery; - std::condition_variable cv_type_discovery_; - std::condition_variable cv_; - eprosima::fastrtps::types::DynamicType_ptr disc_type_; - eprosima::fastdds::dds::DataReaderQos reader_qos; - bool using_typelookup_; - bool tls_callback_called_; - std::string topic_name_; - const eprosima::fastrtps::DataRepresentationQosPolicy* dataRepresentationQos_; - const eprosima::fastrtps::TypeConsistencyEnforcementQosPolicy* typeConsistencyQos_; - -public: - - class PartListener : public eprosima::fastdds::dds::DomainParticipantListener - { -public: - - PartListener( - TestSubscriber* parent) - : parent_(parent) - , discovered_(false) - { - } - - ~PartListener() override - { - } - - void on_type_discovery( - eprosima::fastdds::dds::DomainParticipant* participant, - const eprosima::fastrtps::rtps::SampleIdentity& request_sample_id, - const eprosima::fastrtps::string_255& topic, - const eprosima::fastrtps::types::TypeIdentifier* identifier, - const eprosima::fastrtps::types::TypeObject* object, - eprosima::fastrtps::types::DynamicType_ptr dyn_type) override; - - void on_type_information_received( - eprosima::fastdds::dds::DomainParticipant* participant, - const eprosima::fastrtps::string_255 topic_name, - const eprosima::fastrtps::string_255 type_name, - const eprosima::fastrtps::types::TypeInformation& type_information) override; - - TestSubscriber* parent_; - std::atomic discovered_; - - } part_listener_; - - class SubListener : public eprosima::fastdds::dds::DataReaderListener - { -public: - - SubListener() - { - } - - SubListener( - TestSubscriber* parent); - - ~SubListener() override - { - } - - void on_subscription_matched( - eprosima::fastdds::dds::DataReader* reader, - const eprosima::fastdds::dds::SubscriptionMatchedStatus& info) override; - - void on_data_available( - eprosima::fastdds::dds::DataReader* reader) override; - - TestSubscriber* mParent; - int n_matched; - uint32_t n_samples; - } m_subListener; -}; - -#endif /* _TEST_SUBSCRIBER_H_ */ diff --git a/test/xtypes/XTypesTests.cpp b/test/xtypes/XTypesTests.cpp deleted file mode 100644 index b3b3c901454..00000000000 --- a/test/xtypes/XTypesTests.cpp +++ /dev/null @@ -1,1687 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -#include "idl/TypesPubSubTypes.h" -#include "idl/TypesTypeObject.h" - -#include - -#include "TestPublisher.h" -#include "TestSubscriber.h" - -#include -#include -#include -#include -#include -#include - -#include -#include -#include -#include -#include - -#if defined(_WIN32) -#define GET_PID _getpid -#include -#else -#define GET_PID getpid -#include -#include -#endif // if defined(_WIN32) - -using namespace eprosima::fastdds::dds; -using namespace eprosima::fastrtps::rtps; - -static int DOMAIN_ID_ = 10; - -// TODO - Remove DISABLED when XTYPES are implemented. - -class xtypestests : public ::testing::Test -{ -public: - - xtypestests() - { - //Log::SetVerbosity(eprosima::fastdds::dds::Log::Info); - //Log::SetCategoryFilter(std::regex("(SECURITY)")); - - DOMAIN_ID_ = static_cast(GET_PID()) % 230; - registerTypesTypes(); - } - - ~xtypestests() - { - //Log::Reset(); - eprosima::fastdds::dds::Log::KillThread(); - eprosima::fastrtps::Domain::stopAll(); - ++DOMAIN_ID_; - DOMAIN_ID_ %= 230; - } - -}; - -/**** NO TYPE OBJECT ****/ - -/* - * Both endpoints share the same type without DataRepresentationQos, so they must match. - * This represents classical match. - */ -TEST_F(xtypestests, NoTypeObjectSameType) -{ - TypeSupport type(new BasicStructPubSubType()); - TestPublisher pub; - TestSubscriber sub; - - ASSERT_TRUE(type != nullptr); - ASSERT_FALSE(type == nullptr); - - pub.init("NoTypeObjectSameType", DOMAIN_ID_, type, nullptr, nullptr, nullptr, "Pub1", nullptr); - ASSERT_TRUE(pub.isInitialized()); - - sub.init("NoTypeObjectSameType", DOMAIN_ID_, type, nullptr, nullptr, nullptr, "Sub1", nullptr, nullptr); - ASSERT_TRUE(sub.isInitialized()); - - // Wait for discovery. - sub.waitDiscovery(true, 3); - pub.waitDiscovery(true, 3); -} - -/* - * Both endpoints share the same type without DataRepresentationQosm, but they force type validation, - * so they must not match. - */ -TEST_F(xtypestests, NoTypeObjectSameTypeForce) -{ - TypeSupport type(new BasicStructPubSubType()); - TestPublisher pub; - TestSubscriber sub; - - TypeConsistencyEnforcementQosPolicy typeConQos; - //typeConQos.m_kind = TypeConsistencyKind::ALLOW_TYPE_COERCION; - //typeConQos.m_kind = TypeConsistencyKind::DISALLOW_TYPE_COERCION; - //typeConQos.m_ignore_sequence_bounds = true; - //typeConQos.m_ignore_string_bounds = true; - //typeConQos.m_ignore_member_names = true; - //typeConQos.m_prevent_type_widening = false; - typeConQos.m_force_type_validation = true; - - pub.init("NoTypeObjectSameTypeForce", DOMAIN_ID_, type, nullptr, nullptr, nullptr, "Pub1", nullptr); - ASSERT_TRUE(pub.isInitialized()); - - sub.init("NoTypeObjectSameTypeForce", DOMAIN_ID_, type, nullptr, nullptr, nullptr, "Sub1", nullptr, - &typeConQos); - ASSERT_TRUE(sub.isInitialized()); - - // Wait for discovery. - sub.waitDiscovery(false, 3); - pub.waitDiscovery(false, 3); -} - -/* - * The endpoints have different types without DataRepresentationQos, so they must not match. - * This represents classical mismatch. - */ -TEST_F(xtypestests, NoTypeObjectDifferentType) -{ - TypeSupport type(new BasicStructPubSubType()); - TypeSupport type2(new BasicNamesStructPubSubType()); - TestPublisher pub; - TestSubscriber sub; - - pub.init("NoTypeObjectDifferentType", DOMAIN_ID_, type, nullptr, nullptr, nullptr, "Pub1", nullptr); - ASSERT_TRUE(pub.isInitialized()); - - sub.init("NoTypeObjectDifferentType", DOMAIN_ID_, type2, nullptr, nullptr, nullptr, "Sub1", nullptr, - nullptr); - ASSERT_TRUE(sub.isInitialized()); - - // Wait for discovery. - sub.waitDiscovery(false, 3); - pub.waitDiscovery(false, 3); -} - -/**** TYPE OBJECT V1 ****/ - -/* - * Both endpoints share the same type using XCDR1 so they must match. - * This represents classical match. - */ -TEST_F(xtypestests, TypeObjectV1SameType) -{ - TypeSupport type(new BasicStructPubSubType()); - const TypeObject* type_obj = GetMinimalBasicStructObject(); - const TypeIdentifier* type_id = GetBasicStructIdentifier(false); - TestPublisher pub; - TestSubscriber sub; - //TypeInformation* type_info = nullptr; // Not using it - - DataRepresentationQosPolicy dataRepQos; - dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XML_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - - //TypeConsistencyEnforcementQosPolicy typeConQos; - //typeConQos.m_kind = TypeConsistencyKind::ALLOW_TYPE_COERCION; - //typeConQos.m_kind = TypeConsistencyKind::DISALLOW_TYPE_COERCION; - //typeConQos.m_ignore_sequence_bounds = true; - //typeConQos.m_ignore_string_bounds = true; - //typeConQos.m_ignore_member_names = true; - //typeConQos.m_prevent_type_widening = false; - //typeConQos.m_force_type_validation = false; - - pub.init("TypeObjectV1SameType", DOMAIN_ID_, type, type_obj, type_id, nullptr, "Pub1", &dataRepQos); - ASSERT_TRUE(pub.isInitialized()); - - sub.init("TypeObjectV1SameType", DOMAIN_ID_, type, type_obj, type_id, nullptr, "Sub1", &dataRepQos, - nullptr); - ASSERT_TRUE(sub.isInitialized()); - - // Wait for discovery. - sub.waitDiscovery(true, 30); - pub.waitDiscovery(true, 30); -} - -/* - * TEST TYPE DISCOVERY - * RETRIEVE PUB's TYPE - */ -TEST_F(xtypestests, TypeDiscoverySubs) -{ - TypeSupport type(new BasicStructPubSubType()); - const TypeObject* type_obj = GetCompleteBasicStructObject(); - const TypeIdentifier* type_id = GetBasicStructIdentifier(true); - TestPublisher pub; - TestSubscriber sub; - //TypeInformation* type_info = nullptr; // Not using it - - DataRepresentationQosPolicy dataRepQos; - dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XML_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - - //TypeConsistencyEnforcementQosPolicy typeConQos; - //typeConQos.m_kind = TypeConsistencyKind::ALLOW_TYPE_COERCION; - //typeConQos.m_kind = TypeConsistencyKind::DISALLOW_TYPE_COERCION; - //typeConQos.m_ignore_sequence_bounds = true; - //typeConQos.m_ignore_string_bounds = true; - //typeConQos.m_ignore_member_names = true; - //typeConQos.m_prevent_type_widening = false; - //typeConQos.m_force_type_validation = false; - - pub.init("TypeDiscoverySubs", DOMAIN_ID_, type, type_obj, type_id, nullptr, "Pub1", &dataRepQos); - ASSERT_TRUE(pub.isInitialized()); - - sub.init("TypeDiscoverySubs", DOMAIN_ID_, TypeSupport( - nullptr), nullptr, nullptr, nullptr, "Sub1", &dataRepQos, nullptr); - ASSERT_TRUE(sub.isInitialized()); - - // Wait for discovery. - sub.waitTypeDiscovery(true, 3); - - eprosima::fastrtps::types::DynamicType_ptr disc_type = sub.discovered_type(); - ASSERT_TRUE(disc_type != nullptr); - - sub.register_discovered_type(); - sub.create_datareader(); - - pub.waitDiscovery(true, 3); - sub.waitDiscovery(true, 3); -} - -/* - * TEST TYPE DISCOVERY - * RETRIEVE SUB's TYPE - */ -TEST_F(xtypestests, TypeDiscoveryPubs) -{ - TypeSupport type(new BasicStructPubSubType()); - const TypeObject* type_obj = GetCompleteBasicStructObject(); - const TypeIdentifier* type_id = GetBasicStructIdentifier(true); - TestPublisher pub; - TestSubscriber sub; - //TypeInformation* type_info = nullptr; // Not using it - - DataRepresentationQosPolicy dataRepQos; - dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XML_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - - //TypeConsistencyEnforcementQosPolicy typeConQos; - //typeConQos.m_kind = TypeConsistencyKind::ALLOW_TYPE_COERCION; - //typeConQos.m_kind = TypeConsistencyKind::DISALLOW_TYPE_COERCION; - //typeConQos.m_ignore_sequence_bounds = true; - //typeConQos.m_ignore_string_bounds = true; - //typeConQos.m_ignore_member_names = true; - //typeConQos.m_prevent_type_widening = false; - //typeConQos.m_force_type_validation = false; - - pub.init("TypeDiscoveryPubs", DOMAIN_ID_, TypeSupport(nullptr), nullptr, nullptr, nullptr, "Pub1", &dataRepQos); - ASSERT_TRUE(pub.isInitialized()); - - sub.init("TypeDiscoveryPubs", DOMAIN_ID_, type, type_obj, type_id, nullptr, "Sub1", &dataRepQos, nullptr); - ASSERT_TRUE(sub.isInitialized()); - - // Wait for discovery. - pub.waitTypeDiscovery(true, 3); - - eprosima::fastrtps::types::DynamicType_ptr disc_type = pub.discovered_type(); - ASSERT_TRUE(disc_type != nullptr); - - pub.register_discovered_type(); - DataWriter* writer = pub.create_datawriter(); - - pub.waitDiscovery(true, 3); - sub.waitDiscovery(true, 3); - - writer->set_listener(nullptr); - pub.delete_datawriter(writer); -} - -/* - * Both endpoints different types using XCDR1 so they must not match even with full coercion allowed. - */ -TEST_F(xtypestests, TypeObjectV1DifferentType) -{ - TypeSupport type1(new BasicStructPubSubType()); - TypeSupport type2(new BasicBadStructPubSubType()); - const TypeObject* type_obj1 = GetMinimalBasicStructObject(); - const TypeIdentifier* type_id1 = GetBasicStructIdentifier(false); - const TypeObject* type_obj2 = GetMinimalBasicBadStructObject(); - const TypeIdentifier* type_id2 = GetBasicBadStructIdentifier(false); - TestPublisher pub; - TestSubscriber sub; - //TypeInformation* type_info = nullptr; // Not using it - - DataRepresentationQosPolicy dataRepQos; - dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XML_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - - TypeConsistencyEnforcementQosPolicy typeConQos; - typeConQos.m_kind = TypeConsistencyKind::ALLOW_TYPE_COERCION; - //typeConQos.m_kind = TypeConsistencyKind::DISALLOW_TYPE_COERCION; - typeConQos.m_ignore_sequence_bounds = true; - typeConQos.m_ignore_string_bounds = true; - typeConQos.m_ignore_member_names = true; - typeConQos.m_prevent_type_widening = false; - typeConQos.m_force_type_validation = false; - - pub.init("TypeObjectV1DifferentType", DOMAIN_ID_, type1, type_obj1, type_id1, nullptr, "Pub1", &dataRepQos); - ASSERT_TRUE(pub.isInitialized()); - - sub.init("TypeObjectV1DifferentType", DOMAIN_ID_, type2, type_obj2, type_id2, nullptr, "Sub1", &dataRepQos, - &typeConQos); - ASSERT_TRUE(sub.isInitialized()); - - // Wait for discovery. - sub.waitDiscovery(false, 3); - pub.waitDiscovery(false, 3); -} - -/* - * BasicStruct and BasicNamesStruct are similar structures, but with different names in members. - * This test checks failure at the member names through TypeIdentifier's hashes. The endpoints must not match. - */ -TEST_F(xtypestests, TypeObjectV1NamesManaged) -{ - TypeSupport type1(new BasicStructPubSubType()); - TypeSupport type2(new BasicNamesStructPubSubType()); - const TypeObject* type_obj1 = GetMinimalBasicStructObject(); - const TypeIdentifier* type_id1 = GetBasicStructIdentifier(false); - const TypeObject* type_obj2 = GetMinimalBasicNamesStructObject(); - const TypeIdentifier* type_id2 = GetBasicNamesStructIdentifier(false); - TestPublisher pub; - TestSubscriber sub; - //TypeInformation* type_info = nullptr; // Not using it - - DataRepresentationQosPolicy dataRepQos; - dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XML_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - - TypeConsistencyEnforcementQosPolicy typeConQos; - typeConQos.m_kind = TypeConsistencyKind::ALLOW_TYPE_COERCION; - //typeConQos.m_kind = TypeConsistencyKind::DISALLOW_TYPE_COERCION; - //typeConQos.m_ignore_sequence_bounds = true; - //typeConQos.m_ignore_string_bounds = true; - typeConQos.m_ignore_member_names = false; - //typeConQos.m_prevent_type_widening = false; - //typeConQos.m_force_type_validation = false; - - pub.init("TypeObjectV1NamesManaged", DOMAIN_ID_, type1, type_obj1, type_id1, nullptr, "Pub1", &dataRepQos); - ASSERT_TRUE(pub.isInitialized()); - - sub.init("TypeObjectV1NamesManaged", DOMAIN_ID_, type2, type_obj2, type_id2, nullptr, "Sub1", &dataRepQos, - &typeConQos); - ASSERT_TRUE(sub.isInitialized()); - - // Wait for discovery. - sub.waitDiscovery(false, 3); - pub.waitDiscovery(false, 3); -} - -/* - * BasicStruct and BasicNamesStruct are similar structures, but with different names in struct and members. - * This test checks ignoring at the member names through TypeIdentifier's hashes. The endpoints must match. - */ -TEST_F(xtypestests, DISABLED_TypeObjectV1NamesIgnored) -{ - TypeSupport type1(new BasicStructPubSubType()); - TypeSupport type2(new BasicNamesStructPubSubType()); - const TypeObject* type_obj1 = GetMinimalBasicStructObject(); - const TypeIdentifier* type_id1 = GetBasicStructIdentifier(false); - const TypeObject* type_obj2 = GetMinimalBasicNamesStructObject(); - const TypeIdentifier* type_id2 = GetBasicNamesStructIdentifier(false); - TestPublisher pub; - TestSubscriber sub; - //TypeInformation* type_info = nullptr; // Not using it - - DataRepresentationQosPolicy dataRepQos; - dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XML_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - - TypeConsistencyEnforcementQosPolicy typeConQos; - typeConQos.m_kind = TypeConsistencyKind::ALLOW_TYPE_COERCION; - //typeConQos.m_kind = TypeConsistencyKind::DISALLOW_TYPE_COERCION; - //typeConQos.m_ignore_sequence_bounds = true; - //typeConQos.m_ignore_string_bounds = true; - typeConQos.m_ignore_member_names = true; - //typeConQos.m_prevent_type_widening = false; - //typeConQos.m_force_type_validation = false; - - pub.init("TypeObjectV1NamesIgnored", DOMAIN_ID_, type1, type_obj1, type_id1, nullptr, "Pub1", &dataRepQos); - ASSERT_TRUE(pub.isInitialized()); - - sub.init("TypeObjectV1NamesIgnored", DOMAIN_ID_, type2, type_obj2, type_id2, nullptr, "Sub1", &dataRepQos, - &typeConQos); - ASSERT_TRUE(sub.isInitialized()); - - // Wait for discovery. - sub.waitDiscovery(true, 3); - pub.waitDiscovery(true, 3); -} - -/* - * BasicStruct and BasicNamesStruct are similar structures, but with different names in struct and members. - * This test checks ignoring at the member names when disallowed type coercion has no effect. - * The endpoints must not match. - */ -TEST_F(xtypestests, TypeObjectV1NamesIgnoredDisallow) -{ - TypeSupport type1(new BasicStructPubSubType()); - TypeSupport type2(new BasicNamesStructPubSubType()); - const TypeObject* type_obj1 = GetMinimalBasicStructObject(); - const TypeIdentifier* type_id1 = GetBasicStructIdentifier(false); - const TypeObject* type_obj2 = GetMinimalBasicNamesStructObject(); - const TypeIdentifier* type_id2 = GetBasicNamesStructIdentifier(false); - TestPublisher pub; - TestSubscriber sub; - //TypeInformation* type_info = nullptr; // Not using it - - DataRepresentationQosPolicy dataRepQos; - dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XML_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - - TypeConsistencyEnforcementQosPolicy typeConQos; - //typeConQos.m_kind = TypeConsistencyKind::ALLOW_TYPE_COERCION; - typeConQos.m_kind = TypeConsistencyKind::DISALLOW_TYPE_COERCION; - //typeConQos.m_ignore_sequence_bounds = true; - //typeConQos.m_ignore_string_bounds = true; - typeConQos.m_ignore_member_names = true; - //typeConQos.m_prevent_type_widening = false; - //typeConQos.m_force_type_validation = false; - - pub.init("TypeObjectV1NamesIgnoredDisallow", DOMAIN_ID_, type1, type_obj1, type_id1, nullptr, "Pub1", &dataRepQos); - ASSERT_TRUE(pub.isInitialized()); - - sub.init("TypeObjectV1NamesIgnoredDisallow", DOMAIN_ID_, type2, type_obj2, type_id2, nullptr, "Sub1", - &dataRepQos, &typeConQos); - ASSERT_TRUE(sub.isInitialized()); - - // Wait for discovery. - sub.waitDiscovery(false, 3); - pub.waitDiscovery(false, 3); -} - -/* - * BasicStruct and BasicWideStruct are similar structures, but with "Wide" adds a member. - * This test checks type widening. The endpoints must match. - */ -TEST_F(xtypestests, DISABLED_TypeObjectV1TypeWidening) -{ - TypeSupport type1(new BasicStructPubSubType()); - TypeSupport type2(new BasicWideStructPubSubType()); - const TypeObject* type_obj1 = GetMinimalBasicStructObject(); - const TypeIdentifier* type_id1 = GetBasicStructIdentifier(false); - const TypeObject* type_obj2 = GetMinimalBasicWideStructObject(); - const TypeIdentifier* type_id2 = GetBasicWideStructIdentifier(false); - TestPublisher pub; - TestSubscriber sub; - //TypeInformation* type_info = nullptr; // Not using it - - DataRepresentationQosPolicy dataRepQos; - dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XML_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - - TypeConsistencyEnforcementQosPolicy typeConQos; - typeConQos.m_kind = TypeConsistencyKind::ALLOW_TYPE_COERCION; - //typeConQos.m_kind = TypeConsistencyKind::DISALLOW_TYPE_COERCION; - //typeConQos.m_ignore_sequence_bounds = true; - //typeConQos.m_ignore_string_bounds = true; - //typeConQos.m_ignore_member_names = true; - typeConQos.m_prevent_type_widening = false; - //typeConQos.m_force_type_validation = false; - - pub.init("TypeObjectV1TypeWidening", DOMAIN_ID_, type1, type_obj1, type_id1, nullptr, "Pub1", &dataRepQos); - ASSERT_TRUE(pub.isInitialized()); - - sub.init("TypeObjectV1TypeWidening", DOMAIN_ID_, type2, type_obj2, type_id2, nullptr, "Sub1", &dataRepQos, - &typeConQos); - ASSERT_TRUE(sub.isInitialized()); - - // Wait for discovery. - sub.waitDiscovery(true, 3); - pub.waitDiscovery(true, 3); -} - -/* - * BasicStruct and BadBasicWideStruct are similar structures, but with "Wide" adds a member, and in this case - * modifies the type of other member. The endpoints must not match. - */ -TEST_F(xtypestests, TypeObjectV1BadTypeWidening) -{ - TypeSupport type1(new BasicStructPubSubType()); - TypeSupport type2(new BadBasicWideStructPubSubType()); - const TypeObject* type_obj1 = GetMinimalBasicStructObject(); - const TypeIdentifier* type_id1 = GetBasicStructIdentifier(false); - const TypeObject* type_obj2 = GetMinimalBadBasicWideStructObject(); - const TypeIdentifier* type_id2 = GetBadBasicWideStructIdentifier(false); - TestPublisher pub; - TestSubscriber sub; - //TypeInformation* type_info = nullptr; // Not using it - - DataRepresentationQosPolicy dataRepQos; - dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XML_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - - TypeConsistencyEnforcementQosPolicy typeConQos; - typeConQos.m_kind = TypeConsistencyKind::ALLOW_TYPE_COERCION; - //typeConQos.m_kind = TypeConsistencyKind::DISALLOW_TYPE_COERCION; - //typeConQos.m_ignore_sequence_bounds = true; - //typeConQos.m_ignore_string_bounds = true; - //typeConQos.m_ignore_member_names = true; - typeConQos.m_prevent_type_widening = false; - //typeConQos.m_force_type_validation = false; - - pub.init("TypeObjectV1BadTypeWidening", DOMAIN_ID_, type1, type_obj1, type_id1, nullptr, "Pub1", &dataRepQos); - ASSERT_TRUE(pub.isInitialized()); - - sub.init("TypeObjectV1BadTypeWidening", DOMAIN_ID_, type2, type_obj2, type_id2, nullptr, "Sub1", - &dataRepQos, &typeConQos); - ASSERT_TRUE(sub.isInitialized()); - - // Wait for discovery. - sub.waitDiscovery(false, 3); - pub.waitDiscovery(false, 3); -} - -/* - * BasicStruct and BasicWideStruct are similar structures, but with "Wide" adds a member. - * This test checks prevent type widening when assigning narrow to wide. The endpoints must match. - */ -TEST_F(xtypestests, DISABLED_TypeObjectV1TypeWideningPreventedNarrowToWide) -{ - TypeSupport type1(new BasicStructPubSubType()); - TypeSupport type2(new BasicWideStructPubSubType()); - const TypeObject* type_obj1 = GetMinimalBasicStructObject(); - const TypeIdentifier* type_id1 = GetBasicStructIdentifier(false); - const TypeObject* type_obj2 = GetMinimalBasicWideStructObject(); - const TypeIdentifier* type_id2 = GetBasicWideStructIdentifier(false); - TestPublisher pub; - TestSubscriber sub; - //TypeInformation* type_info = nullptr; // Not using it - - DataRepresentationQosPolicy dataRepQos; - dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XML_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - - TypeConsistencyEnforcementQosPolicy typeConQos; - typeConQos.m_kind = TypeConsistencyKind::ALLOW_TYPE_COERCION; - //typeConQos.m_kind = TypeConsistencyKind::DISALLOW_TYPE_COERCION; - //typeConQos.m_ignore_sequence_bounds = true; - //typeConQos.m_ignore_string_bounds = true; - //typeConQos.m_ignore_member_names = true; - typeConQos.m_prevent_type_widening = true; - //typeConQos.m_force_type_validation = false; - - pub.init("TypeObjectV1TypeWideningPreventedNarrowToWide", DOMAIN_ID_, type1, type_obj1, type_id1, nullptr, "Pub1", - &dataRepQos); - ASSERT_TRUE(pub.isInitialized()); - - sub.init("TypeObjectV1TypeWideningPreventedNarrowToWide", DOMAIN_ID_, type2, type_obj2, type_id2, nullptr, - "Sub1", &dataRepQos, &typeConQos); - ASSERT_TRUE(sub.isInitialized()); - - // Wait for discovery. - sub.waitDiscovery(true, 3); - pub.waitDiscovery(true, 3); -} - -/* - * BasicStruct and BasicWideStruct are similar structures, but with "Wide" adds a member. - * This test checks prevent type widening when assining from wide to narrow. The endpoints must not match. - */ -TEST_F(xtypestests, TypeObjectV1TypeWideningPreventedWideToNarrow) -{ - TypeSupport type1(new BasicStructPubSubType()); - TypeSupport type2(new BasicWideStructPubSubType()); - const TypeObject* type_obj1 = GetMinimalBasicStructObject(); - const TypeIdentifier* type_id1 = GetBasicStructIdentifier(false); - const TypeObject* type_obj2 = GetMinimalBasicWideStructObject(); - const TypeIdentifier* type_id2 = GetBasicWideStructIdentifier(false); - TestPublisher pub; - TestSubscriber sub; - //TypeInformation* type_info = nullptr; // Not using it - - DataRepresentationQosPolicy dataRepQos; - dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XML_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - - TypeConsistencyEnforcementQosPolicy typeConQos; - typeConQos.m_kind = TypeConsistencyKind::ALLOW_TYPE_COERCION; - //typeConQos.m_kind = TypeConsistencyKind::DISALLOW_TYPE_COERCION; - //typeConQos.m_ignore_sequence_bounds = true; - //typeConQos.m_ignore_string_bounds = true; - //typeConQos.m_ignore_member_names = true; - typeConQos.m_prevent_type_widening = true; - //typeConQos.m_force_type_validation = false; - - pub.init("TypeObjectV1TypeWideningPreventedWideToNarrow", DOMAIN_ID_, type2, type_obj2, type_id2, nullptr, "Pub1", - &dataRepQos); - ASSERT_TRUE(pub.isInitialized()); - - sub.init("TypeObjectV1TypeWideningPreventedWideToNarrow", DOMAIN_ID_, type1, type_obj1, type_id1, nullptr, - "Sub1", &dataRepQos, &typeConQos); - ASSERT_TRUE(sub.isInitialized()); - - // Wait for discovery. - sub.waitDiscovery(false, 3); - pub.waitDiscovery(false, 3); -} - -/* - * BasicStruct and BasicWideStruct are similar structures, but with "Wide" adds a member, but coercion is disallowed. - * This test checks type widening. The endpoints must match. - */ -TEST_F(xtypestests, TypeObjectV1TypeWideningDisallow) -{ - TypeSupport type1(new BasicStructPubSubType()); - TypeSupport type2(new BasicWideStructPubSubType()); - const TypeObject* type_obj1 = GetMinimalBasicStructObject(); - const TypeIdentifier* type_id1 = GetBasicStructIdentifier(false); - const TypeObject* type_obj2 = GetMinimalBasicWideStructObject(); - const TypeIdentifier* type_id2 = GetBasicWideStructIdentifier(false); - TestPublisher pub; - TestSubscriber sub; - //TypeInformation* type_info = nullptr; // Not using it - - DataRepresentationQosPolicy dataRepQos; - dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XML_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - - TypeConsistencyEnforcementQosPolicy typeConQos; - //typeConQos.m_kind = TypeConsistencyKind::ALLOW_TYPE_COERCION; - typeConQos.m_kind = TypeConsistencyKind::DISALLOW_TYPE_COERCION; - //typeConQos.m_ignore_sequence_bounds = true; - //typeConQos.m_ignore_string_bounds = true; - //typeConQos.m_ignore_member_names = true; - typeConQos.m_prevent_type_widening = false; - //typeConQos.m_force_type_validation = false; - - pub.init("TypeObjectV1TypeWideningDisallow", DOMAIN_ID_, type1, type_obj1, type_id1, nullptr, "Pub1", &dataRepQos); - ASSERT_TRUE(pub.isInitialized()); - - sub.init("TypeObjectV1TypeWideningDisallow", DOMAIN_ID_, type2, type_obj2, type_id2, nullptr, "Sub1", - &dataRepQos, &typeConQos); - ASSERT_TRUE(sub.isInitialized()); - - // Wait for discovery. - sub.waitDiscovery(false, 3); - pub.waitDiscovery(false, 3); -} - -/* - * SequenceStruct and SequenceBoundsStruct are similar structures, but with "Bounds" the size of the sequence is bigger. - * This test checks sequence bounds. The endpoints must match. - */ -TEST_F(xtypestests, DISABLED_TypeObjectV1SequenceBoundsIgnored) -{ - TypeSupport type1(new SequenceStructPubSubType()); - TypeSupport type2(new SequenceBoundsStructPubSubType()); - const TypeObject* type_obj1 = GetMinimalSequenceStructObject(); - const TypeIdentifier* type_id1 = GetSequenceStructIdentifier(false); - const TypeObject* type_obj2 = GetMinimalSequenceBoundsStructObject(); - const TypeIdentifier* type_id2 = GetSequenceBoundsStructIdentifier(false); - TestPublisher pub; - TestSubscriber sub; - //TypeInformation* type_info = nullptr; // Not using it - - DataRepresentationQosPolicy dataRepQos; - dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XML_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - - TypeConsistencyEnforcementQosPolicy typeConQos; - typeConQos.m_kind = TypeConsistencyKind::ALLOW_TYPE_COERCION; - //typeConQos.m_kind = TypeConsistencyKind::DISALLOW_TYPE_COERCION; - typeConQos.m_ignore_sequence_bounds = true; - //typeConQos.m_ignore_string_bounds = true; - //typeConQos.m_ignore_member_names = true; - //typeConQos.m_prevent_type_widening = false; - //typeConQos.m_force_type_validation = false; - - pub.init("TypeObjectV1SequenceBoundsIgnored", DOMAIN_ID_, type1, type_obj1, type_id1, nullptr, "Pub1", &dataRepQos); - ASSERT_TRUE(pub.isInitialized()); - - sub.init("TypeObjectV1SequenceBoundsIgnored", DOMAIN_ID_, type2, type_obj2, type_id2, nullptr, "Sub1", - &dataRepQos, &typeConQos); - ASSERT_TRUE(sub.isInitialized()); - - // Wait for discovery. - sub.waitDiscovery(true, 3); - pub.waitDiscovery(true, 3); -} - -/* - * SequenceStruct and SequenceBoundsStruct are similar structures, but with "Bounds" the size of the sequence is bigger. - * This test checks sequence bounds. The endpoints must not match. - */ -TEST_F(xtypestests, TypeObjectV1SequenceBoundsManaged) -{ - TypeSupport type1(new SequenceStructPubSubType()); - TypeSupport type2(new SequenceBoundsStructPubSubType()); - const TypeObject* type_obj1 = GetMinimalSequenceStructObject(); - const TypeIdentifier* type_id1 = GetSequenceStructIdentifier(false); - const TypeObject* type_obj2 = GetMinimalSequenceBoundsStructObject(); - const TypeIdentifier* type_id2 = GetSequenceBoundsStructIdentifier(false); - TestPublisher pub; - TestSubscriber sub; - //TypeInformation* type_info = nullptr; // Not using it - - DataRepresentationQosPolicy dataRepQos; - dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XML_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - - TypeConsistencyEnforcementQosPolicy typeConQos; - typeConQos.m_kind = TypeConsistencyKind::ALLOW_TYPE_COERCION; - //typeConQos.m_kind = TypeConsistencyKind::DISALLOW_TYPE_COERCION; - typeConQos.m_ignore_sequence_bounds = false; - //typeConQos.m_ignore_string_bounds = true; - //typeConQos.m_ignore_member_names = true; - //typeConQos.m_prevent_type_widening = false; - //typeConQos.m_force_type_validation = false; - - pub.init("TypeObjectV1SequenceBoundsManaged", DOMAIN_ID_, type1, type_obj1, type_id1, nullptr, "Pub1", &dataRepQos); - ASSERT_TRUE(pub.isInitialized()); - - sub.init("TypeObjectV1SequenceBoundsManaged", DOMAIN_ID_, type2, type_obj2, type_id2, nullptr, "Sub1", - &dataRepQos, &typeConQos); - ASSERT_TRUE(sub.isInitialized()); - - // Wait for discovery. - sub.waitDiscovery(false, 3); - pub.waitDiscovery(false, 3); -} - -/* - * StringStruct and LargeStringStruct are similar structures, but with "Large" the size of the string is bigger. - * Names are ignored because the member is named different. - * This test checks string bounds. The endpoints must match. - */ -TEST_F(xtypestests, DISABLED_TypeObjectV1LargeStringIgnored) -{ - TypeSupport type1(new StringStructPubSubType()); - TypeSupport type2(new LargeStringStructPubSubType()); - const TypeObject* type_obj1 = GetMinimalStringStructObject(); - const TypeIdentifier* type_id1 = GetStringStructIdentifier(false); - const TypeObject* type_obj2 = GetMinimalLargeStringStructObject(); - const TypeIdentifier* type_id2 = GetLargeStringStructIdentifier(false); - TestPublisher pub; - TestSubscriber sub; - //TypeInformation* type_info = nullptr; // Not using it - - DataRepresentationQosPolicy dataRepQos; - dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XML_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - - TypeConsistencyEnforcementQosPolicy typeConQos; - typeConQos.m_kind = TypeConsistencyKind::ALLOW_TYPE_COERCION; - //typeConQos.m_kind = TypeConsistencyKind::DISALLOW_TYPE_COERCION; - //typeConQos.m_ignore_sequence_bounds = true; - typeConQos.m_ignore_string_bounds = true; - typeConQos.m_ignore_member_names = true; - //typeConQos.m_prevent_type_widening = false; - //typeConQos.m_force_type_validation = false; - - pub.init("TypeObjectV1LargeStringIgnored", DOMAIN_ID_, type1, type_obj1, type_id1, nullptr, "Pub1", &dataRepQos); - ASSERT_TRUE(pub.isInitialized()); - - sub.init("TypeObjectV1LargeStringIgnored", DOMAIN_ID_, type2, type_obj2, type_id2, nullptr, "Sub1", - &dataRepQos, &typeConQos); - ASSERT_TRUE(sub.isInitialized()); - - // Wait for discovery. - sub.waitDiscovery(true, 3); - pub.waitDiscovery(true, 3); -} - -/* - * StringStruct and LargeStringStruct are similar structures, but with "Large" the size of the string is bigger. - * Names are ignored because the member is named different. - * This test checks string bounds. The endpoints must not match. - */ -TEST_F(xtypestests, TypeObjectV1LargeStringManaged) -{ - TypeSupport type1(new StringStructPubSubType()); - TypeSupport type2(new LargeStringStructPubSubType()); - const TypeObject* type_obj1 = GetMinimalStringStructObject(); - const TypeIdentifier* type_id1 = GetStringStructIdentifier(false); - const TypeObject* type_obj2 = GetMinimalLargeStringStructObject(); - const TypeIdentifier* type_id2 = GetLargeStringStructIdentifier(false); - TestPublisher pub; - TestSubscriber sub; - //TypeInformation* type_info = nullptr; // Not using it - - DataRepresentationQosPolicy dataRepQos; - dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XML_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - - TypeConsistencyEnforcementQosPolicy typeConQos; - typeConQos.m_kind = TypeConsistencyKind::ALLOW_TYPE_COERCION; - //typeConQos.m_kind = TypeConsistencyKind::DISALLOW_TYPE_COERCION; - //typeConQos.m_ignore_sequence_bounds = false; - typeConQos.m_ignore_string_bounds = false; - typeConQos.m_ignore_member_names = true; - //typeConQos.m_prevent_type_widening = false; - //typeConQos.m_force_type_validation = false; - - pub.init("TypeObjectV1LargeStringManaged", DOMAIN_ID_, type1, type_obj1, type_id1, nullptr, "Pub1", &dataRepQos); - ASSERT_TRUE(pub.isInitialized()); - - sub.init("TypeObjectV1LargeStringManaged", DOMAIN_ID_, type2, type_obj2, type_id2, nullptr, "Sub1", - &dataRepQos, &typeConQos); - ASSERT_TRUE(sub.isInitialized()); - - // Wait for discovery. - sub.waitDiscovery(false, 3); - pub.waitDiscovery(false, 3); -} - -/* - * Both endpoints share the same type using XCDR1 so they must match, in this case using Complete. - */ -TEST_F(xtypestests, TypeObjectV1SameTypeComplete) -{ - TypeSupport type(new BasicStructPubSubType()); - const TypeObject* type_obj = GetCompleteBasicStructObject(); - const TypeIdentifier* type_id = GetBasicStructIdentifier(true); - TestPublisher pub; - TestSubscriber sub; - //TypeInformation* type_info = nullptr; // Not using it - - DataRepresentationQosPolicy dataRepQos; - dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XML_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - - //TypeConsistencyEnforcementQosPolicy typeConQos; - //typeConQos.m_kind = TypeConsistencyKind::ALLOW_TYPE_COERCION; - //typeConQos.m_kind = TypeConsistencyKind::DISALLOW_TYPE_COERCION; - //typeConQos.m_ignore_sequence_bounds = true; - //typeConQos.m_ignore_string_bounds = true; - //typeConQos.m_ignore_member_names = true; - //typeConQos.m_prevent_type_widening = false; - //typeConQos.m_force_type_validation = false; - - pub.init("TypeObjectV1SameTypeComplete", DOMAIN_ID_, type, type_obj, type_id, nullptr, "Pub1", &dataRepQos); - ASSERT_TRUE(pub.isInitialized()); - - sub.init("TypeObjectV1SameTypeComplete", DOMAIN_ID_, type, type_obj, type_id, nullptr, "Sub1", &dataRepQos, - nullptr); - ASSERT_TRUE(sub.isInitialized()); - - // Wait for discovery. - sub.waitDiscovery(true, 3); - pub.waitDiscovery(true, 3); -} - -/* - * Both endpoints use compatible but different types using XCDR1 but without coercion so they must not match, - * in this case using Complete. - */ -TEST_F(xtypestests, TypeObjectV1InvalidComplete) -{ - TypeSupport type1(new BasicStructPubSubType()); - TypeSupport type2(new BasicNamesStructPubSubType()); - const TypeObject* type_obj1 = GetCompleteBasicStructObject(); - const TypeIdentifier* type_id1 = GetBasicStructIdentifier(true); - const TypeObject* type_obj2 = GetCompleteBasicNamesStructObject(); - const TypeIdentifier* type_id2 = GetBasicNamesStructIdentifier(true); - TestPublisher pub; - TestSubscriber sub; - //TypeInformation* type_info = nullptr; // Not using it - - DataRepresentationQosPolicy dataRepQos; - dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XML_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - - //TypeConsistencyEnforcementQosPolicy typeConQos; - //typeConQos.m_kind = TypeConsistencyKind::ALLOW_TYPE_COERCION; - //typeConQos.m_kind = TypeConsistencyKind::DISALLOW_TYPE_COERCION; - //typeConQos.m_ignore_sequence_bounds = true; - //typeConQos.m_ignore_string_bounds = true; - //typeConQos.m_ignore_member_names = true; - //typeConQos.m_prevent_type_widening = false; - //typeConQos.m_force_type_validation = false; - - pub.init("TypeObjectV1InvalidComplete", DOMAIN_ID_, type1, type_obj1, type_id1, nullptr, "Pub1", &dataRepQos); - ASSERT_TRUE(pub.isInitialized()); - - sub.init("TypeObjectV1InvalidComplete", DOMAIN_ID_, type2, type_obj2, type_id2, nullptr, "Sub1", - &dataRepQos, nullptr); - ASSERT_TRUE(sub.isInitialized()); - - // Wait for discovery. - sub.waitDiscovery(false, 3); - pub.waitDiscovery(false, 3); -} - -/* - * Both endpoints the same type using XCDR1 but one using minimal and the other complete. - * They shouldn't match. - */ -TEST_F(xtypestests, MixingMinimalAndComplete) -{ - TypeSupport type1(new BasicStructPubSubType()); - const TypeObject* type_obj1 = GetMinimalBasicStructObject(); - const TypeIdentifier* type_id1 = GetBasicStructIdentifier(false); - const TypeObject* type_obj2 = GetCompleteBasicStructObject(); - const TypeIdentifier* type_id2 = GetBasicStructIdentifier(true); - TestPublisher pub; - TestSubscriber sub; - //TypeInformation* type_info = nullptr; // Not using it - - DataRepresentationQosPolicy dataRepQos; - dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XML_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - - //TypeConsistencyEnforcementQosPolicy typeConQos; - //typeConQos.m_kind = TypeConsistencyKind::ALLOW_TYPE_COERCION; - //typeConQos.m_kind = TypeConsistencyKind::DISALLOW_TYPE_COERCION; - //typeConQos.m_ignore_sequence_bounds = true; - //typeConQos.m_ignore_string_bounds = true; - //typeConQos.m_ignore_member_names = true; - //typeConQos.m_prevent_type_widening = false; - //typeConQos.m_force_type_validation = false; - - pub.init("MixingMinimalAndComplete", DOMAIN_ID_, type1, type_obj1, type_id1, nullptr, "Pub1", &dataRepQos); - ASSERT_TRUE(pub.isInitialized()); - - sub.init("MixingMinimalAndComplete", DOMAIN_ID_, type1, type_obj2, type_id2, nullptr, "Sub1", &dataRepQos, - nullptr); - ASSERT_TRUE(sub.isInitialized()); - - // Wait for discovery. - sub.waitDiscovery(false, 3); - pub.waitDiscovery(false, 3); -} - -/**** TYPE IDENTIFIER ****/ - -/* - * Both endpoints share the same type using XCDR1 so they must match. - * This represents classical match. - */ -TEST_F(xtypestests, TypeIdentifierSameType) -{ - TypeSupport type(new BasicStructPubSubType()); - const TypeIdentifier* type_id = GetBasicStructIdentifier(false); - TestPublisher pub; - TestSubscriber sub; - //TypeInformation* type_info = nullptr; // Not using it - - DataRepresentationQosPolicy dataRepQos; - dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XML_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - - //TypeConsistencyEnforcementQosPolicy typeConQos; - //typeConQos.m_kind = TypeConsistencyKind::ALLOW_TYPE_COERCION; - //typeConQos.m_kind = TypeConsistencyKind::DISALLOW_TYPE_COERCION; - //typeConQos.m_ignore_sequence_bounds = true; - //typeConQos.m_ignore_string_bounds = true; - //typeConQos.m_ignore_member_names = true; - //typeConQos.m_prevent_type_widening = false; - //typeConQos.m_force_type_validation = false; - - pub.init("TypeIdentifierSameType", DOMAIN_ID_, type, nullptr, type_id, nullptr, "Pub1", &dataRepQos); - ASSERT_TRUE(pub.isInitialized()); - - sub.init("TypeIdentifierSameType", DOMAIN_ID_, type, nullptr, type_id, nullptr, "Sub1", &dataRepQos, - nullptr); - ASSERT_TRUE(sub.isInitialized()); - - // Wait for discovery. - sub.waitDiscovery(true, 3); - pub.waitDiscovery(true, 3); -} - -/* - * Both endpoints different types using XCDR1 so they must not match even with full coercion allowed. - */ -TEST_F(xtypestests, TypeIdentifierDifferentType) -{ - TypeSupport type1(new BasicStructPubSubType()); - TypeSupport type2(new BasicBadStructPubSubType()); - const TypeIdentifier* type_id1 = GetBasicStructIdentifier(false); - const TypeIdentifier* type_id2 = GetBasicBadStructIdentifier(false); - TestPublisher pub; - TestSubscriber sub; - //TypeInformation* type_info = nullptr; // Not using it - - DataRepresentationQosPolicy dataRepQos; - dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XML_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - - TypeConsistencyEnforcementQosPolicy typeConQos; - typeConQos.m_kind = TypeConsistencyKind::ALLOW_TYPE_COERCION; - //typeConQos.m_kind = TypeConsistencyKind::DISALLOW_TYPE_COERCION; - typeConQos.m_ignore_sequence_bounds = true; - typeConQos.m_ignore_string_bounds = true; - typeConQos.m_ignore_member_names = true; - typeConQos.m_prevent_type_widening = false; - typeConQos.m_force_type_validation = false; - - pub.init("TypeIdentifierDifferentType", DOMAIN_ID_, type1, nullptr, type_id1, nullptr, "Pub1", &dataRepQos); - ASSERT_TRUE(pub.isInitialized()); - - sub.init("TypeIdentifierDifferentType", DOMAIN_ID_, type2, nullptr, type_id2, nullptr, "Sub1", &dataRepQos, - &typeConQos); - ASSERT_TRUE(sub.isInitialized()); - - // Wait for discovery. - sub.waitDiscovery(false, 3); - pub.waitDiscovery(false, 3); -} - -/* - * BasicStruct and BasicNamesStruct are similar structures, but with different names in members. - * This test checks failure at the member names through TypeIdentifier's hashes. The endpoints must not match. - */ -TEST_F(xtypestests, TypeIdentifierNamesManaged) -{ - TypeSupport type1(new BasicStructPubSubType()); - TypeSupport type2(new BasicNamesStructPubSubType()); - const TypeIdentifier* type_id1 = GetBasicStructIdentifier(false); - const TypeIdentifier* type_id2 = GetBasicNamesStructIdentifier(false); - TestPublisher pub; - TestSubscriber sub; - //TypeInformation* type_info = nullptr; // Not using it - - DataRepresentationQosPolicy dataRepQos; - dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XML_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - - TypeConsistencyEnforcementQosPolicy typeConQos; - typeConQos.m_kind = TypeConsistencyKind::ALLOW_TYPE_COERCION; - //typeConQos.m_kind = TypeConsistencyKind::DISALLOW_TYPE_COERCION; - //typeConQos.m_ignore_sequence_bounds = true; - //typeConQos.m_ignore_string_bounds = true; - typeConQos.m_ignore_member_names = false; - //typeConQos.m_prevent_type_widening = false; - //typeConQos.m_force_type_validation = false; - - pub.init("TypeIdentifierNamesManaged", DOMAIN_ID_, type1, nullptr, type_id1, nullptr, "Pub1", &dataRepQos); - ASSERT_TRUE(pub.isInitialized()); - - sub.init("TypeIdentifierNamesManaged", DOMAIN_ID_, type2, nullptr, type_id2, nullptr, "Sub1", &dataRepQos, - &typeConQos); - ASSERT_TRUE(sub.isInitialized()); - - // Wait for discovery. - sub.waitDiscovery(false, 3); - pub.waitDiscovery(false, 3); -} - -/* - * BasicStruct and BasicNamesStruct are similar structures, but with different names in struct and members. - * This test checks ignoring at the member names through TypeIdentifier's hashes. The endpoints must match. - */ -TEST_F(xtypestests, DISABLED_TypeIdentifierNamesIgnored) -{ - TypeSupport type1(new BasicStructPubSubType()); - TypeSupport type2(new BasicNamesStructPubSubType()); - const TypeIdentifier* type_id1 = GetBasicStructIdentifier(false); - const TypeIdentifier* type_id2 = GetBasicNamesStructIdentifier(false); - TestPublisher pub; - TestSubscriber sub; - //TypeInformation* type_info = nullptr; // Not using it - - DataRepresentationQosPolicy dataRepQos; - dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XML_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - - TypeConsistencyEnforcementQosPolicy typeConQos; - typeConQos.m_kind = TypeConsistencyKind::ALLOW_TYPE_COERCION; - //typeConQos.m_kind = TypeConsistencyKind::DISALLOW_TYPE_COERCION; - //typeConQos.m_ignore_sequence_bounds = true; - //typeConQos.m_ignore_string_bounds = true; - typeConQos.m_ignore_member_names = true; - //typeConQos.m_prevent_type_widening = false; - //typeConQos.m_force_type_validation = false; - - pub.init("TypeIdentifierNamesIgnored", DOMAIN_ID_, type1, nullptr, type_id1, nullptr, "Pub1", &dataRepQos); - ASSERT_TRUE(pub.isInitialized()); - - sub.init("TypeIdentifierNamesIgnored", DOMAIN_ID_, type2, nullptr, type_id2, nullptr, "Sub1", &dataRepQos, - &typeConQos); - ASSERT_TRUE(sub.isInitialized()); - - // Wait for discovery. - sub.waitDiscovery(true, 3); - pub.waitDiscovery(true, 3); -} - -/**** TYPE INFORMATION ****/ - -/* - * Both endpoints share the same type using XCDR1 so they must match. - * This represents classical match. - */ -TEST_F(xtypestests, TypeInformationSameType) -{ - TypeSupport type(new BasicStructPubSubType()); - const TypeInformation* type_info = TypeObjectFactory::get_instance()->get_type_information("BasicStruct"); - TestPublisher pub; - TestSubscriber sub; - - DataRepresentationQosPolicy dataRepQos; - dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XML_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - - //TypeConsistencyEnforcementQosPolicy typeConQos; - //typeConQos.m_kind = TypeConsistencyKind::ALLOW_TYPE_COERCION; - //typeConQos.m_kind = TypeConsistencyKind::DISALLOW_TYPE_COERCION; - //typeConQos.m_ignore_sequence_bounds = true; - //typeConQos.m_ignore_string_bounds = true; - //typeConQos.m_ignore_member_names = true; - //typeConQos.m_prevent_type_widening = false; - //typeConQos.m_force_type_validation = false; - - pub.init("TypeInformationSameType", DOMAIN_ID_, type, nullptr, nullptr, type_info, "Pub1", &dataRepQos); - ASSERT_TRUE(pub.isInitialized()); - - sub.init("TypeInformationSameType", DOMAIN_ID_, type, nullptr, nullptr, type_info, "Sub1", &dataRepQos, - nullptr); - ASSERT_TRUE(sub.isInitialized()); - - // Wait for discovery. - sub.waitDiscovery(true, 3); - pub.waitDiscovery(true, 3); -} - -/* - * Both endpoints different types using XCDR1 so they must not match even with full coercion allowed. - */ -TEST_F(xtypestests, TypeInformationDifferentType) -{ - TypeSupport type1(new BasicStructPubSubType()); - TypeSupport type2(new BasicBadStructPubSubType()); - const TypeInformation* type_info1 = TypeObjectFactory::get_instance()->get_type_information("BasicStruct"); - const TypeInformation* type_info2 = TypeObjectFactory::get_instance()->get_type_information("BasicBadStruct"); - TestPublisher pub; - TestSubscriber sub; - //TypeInformation* type_info = nullptr; // Not using it - - DataRepresentationQosPolicy dataRepQos; - dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XML_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - - TypeConsistencyEnforcementQosPolicy typeConQos; - typeConQos.m_kind = TypeConsistencyKind::ALLOW_TYPE_COERCION; - //typeConQos.m_kind = TypeConsistencyKind::DISALLOW_TYPE_COERCION; - typeConQos.m_ignore_sequence_bounds = true; - typeConQos.m_ignore_string_bounds = true; - typeConQos.m_ignore_member_names = true; - typeConQos.m_prevent_type_widening = false; - typeConQos.m_force_type_validation = false; - - pub.init("TypeInformationDifferentType", DOMAIN_ID_, type1, nullptr, nullptr, type_info1, "Pub1", &dataRepQos); - ASSERT_TRUE(pub.isInitialized()); - - sub.init("TypeInformationDifferentType", DOMAIN_ID_, type2, nullptr, nullptr, type_info2, "Sub1", - &dataRepQos, &typeConQos); - ASSERT_TRUE(sub.isInitialized()); - - // Wait for discovery. - sub.waitDiscovery(false, 3); - pub.waitDiscovery(false, 3); -} - -/* - * BasicStruct and BasicNamesStruct are similar structures, but with different names in members. - * This test checks failure at the member names through TypeInformation's hashes. The endpoints must not match. - */ -TEST_F(xtypestests, TypeInformationNamesManaged) -{ - TypeSupport type1(new BasicStructPubSubType()); - TypeSupport type2(new BasicNamesStructPubSubType()); - const TypeInformation* type_info1 = TypeObjectFactory::get_instance()->get_type_information("BasicStruct"); - const TypeInformation* type_info2 = TypeObjectFactory::get_instance()->get_type_information("BasicNamesStruct"); - TestPublisher pub; - TestSubscriber sub; - //TypeInformation* type_info = nullptr; // Not using it - - DataRepresentationQosPolicy dataRepQos; - dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XML_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - - TypeConsistencyEnforcementQosPolicy typeConQos; - typeConQos.m_kind = TypeConsistencyKind::ALLOW_TYPE_COERCION; - //typeConQos.m_kind = TypeConsistencyKind::DISALLOW_TYPE_COERCION; - //typeConQos.m_ignore_sequence_bounds = true; - //typeConQos.m_ignore_string_bounds = true; - typeConQos.m_ignore_member_names = false; - //typeConQos.m_prevent_type_widening = false; - //typeConQos.m_force_type_validation = false; - - pub.init("TypeInformationNamesManaged", DOMAIN_ID_, type1, nullptr, nullptr, type_info1, "Pub1", &dataRepQos); - ASSERT_TRUE(pub.isInitialized()); - - sub.init("TypeInformationNamesManaged", DOMAIN_ID_, type2, nullptr, nullptr, type_info2, "Sub1", - &dataRepQos, &typeConQos); - ASSERT_TRUE(sub.isInitialized()); - - // Wait for discovery. - sub.waitDiscovery(false, 3); - pub.waitDiscovery(false, 3); -} - -/* - * BasicStruct and BasicNamesStruct are similar structures, but with different names in struct and members. - * This test checks ignoring at the member names through TypeInformation's hashes. The endpoints must match. - */ -TEST_F(xtypestests, DISABLED_TypeInformationNamesIgnored) -{ - TypeSupport type1(new BasicStructPubSubType()); - TypeSupport type2(new BasicNamesStructPubSubType()); - const TypeInformation* type_info1 = TypeObjectFactory::get_instance()->get_type_information("BasicStruct"); - const TypeInformation* type_info2 = TypeObjectFactory::get_instance()->get_type_information("BasicNamesStruct"); - TestPublisher pub; - TestSubscriber sub; - //TypeInformation* type_info = nullptr; // Not using it - - DataRepresentationQosPolicy dataRepQos; - dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XML_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - - TypeConsistencyEnforcementQosPolicy typeConQos; - typeConQos.m_kind = TypeConsistencyKind::ALLOW_TYPE_COERCION; - //typeConQos.m_kind = TypeConsistencyKind::DISALLOW_TYPE_COERCION; - //typeConQos.m_ignore_sequence_bounds = true; - //typeConQos.m_ignore_string_bounds = true; - typeConQos.m_ignore_member_names = true; - //typeConQos.m_prevent_type_widening = false; - //typeConQos.m_force_type_validation = false; - - pub.init("TypeInformationNamesIgnored", DOMAIN_ID_, type1, nullptr, nullptr, type_info1, "Pub1", &dataRepQos); - ASSERT_TRUE(pub.isInitialized()); - - sub.init("TypeInformationNamesIgnored", DOMAIN_ID_, type2, nullptr, nullptr, type_info2, "Sub1", - &dataRepQos, &typeConQos); - ASSERT_TRUE(sub.isInitialized()); - - // Wait for discovery. - sub.waitDiscovery(true, 3); - pub.waitDiscovery(true, 3); -} - -/**** Mixing TypeObject, TypeInformation and TypeIdentifier ****/ - -TEST_F(xtypestests, TypeIdentifier_TypeObject) -{ - TypeSupport type(new BasicStructPubSubType()); - TypeSupport type1(new BasicStructPubSubType()); - const TypeObject* type_obj = GetMinimalBasicStructObject(); - const TypeIdentifier* type_id = GetBasicStructIdentifier(false); - TestPublisher pub; - TestSubscriber sub; - - TypeConsistencyEnforcementQosPolicy typeConQos; - typeConQos.m_kind = TypeConsistencyKind::ALLOW_TYPE_COERCION; - typeConQos.m_force_type_validation = true; - - pub.init("TypeIdentifier_TypeObject", DOMAIN_ID_, type, nullptr, type_id, nullptr, "Pub1", nullptr); - ASSERT_TRUE(pub.isInitialized()); - - sub.init("TypeIdentifier_TypeObject", DOMAIN_ID_, type1, type_obj, nullptr, nullptr, "Sub1", nullptr, - &typeConQos); - ASSERT_TRUE(sub.isInitialized()); - - // Wait for discovery. - sub.waitDiscovery(false, 3); - pub.waitDiscovery(false, 3); -} - -TEST_F(xtypestests, TypeIdentifier_TypeInformation) -{ - TypeSupport type(new BasicStructPubSubType()); - TypeSupport type1(new BasicStructPubSubType()); - const TypeIdentifier* type_id = GetBasicStructIdentifier(false); - TestPublisher pub; - TestSubscriber sub; - const TypeInformation* type_info = TypeObjectFactory::get_instance()->get_type_information("BasicStruct"); - - TypeConsistencyEnforcementQosPolicy typeConQos; - typeConQos.m_kind = TypeConsistencyKind::ALLOW_TYPE_COERCION; - typeConQos.m_force_type_validation = true; - - pub.init("TypeIdentifier_TypeInformation", DOMAIN_ID_, type, nullptr, type_id, nullptr, "Pub1", nullptr); - ASSERT_TRUE(pub.isInitialized()); - - sub.init("TypeIdentifier_TypeInformation", DOMAIN_ID_, type1, nullptr, nullptr, type_info, "Sub1", nullptr, - &typeConQos); - ASSERT_TRUE(sub.isInitialized()); - - // Wait for discovery. - sub.waitDiscovery(false, 3); - pub.waitDiscovery(false, 3); -} - -TEST_F(xtypestests, TypeObject_TypeInformation) -{ - TypeSupport type(new BasicStructPubSubType()); - TypeSupport type1(new BasicStructPubSubType()); - const TypeObject* type_obj = GetMinimalBasicStructObject(); - TestPublisher pub; - TestSubscriber sub; - const TypeInformation* type_info = TypeObjectFactory::get_instance()->get_type_information("BasicStruct"); - - TypeConsistencyEnforcementQosPolicy typeConQos; - typeConQos.m_kind = TypeConsistencyKind::ALLOW_TYPE_COERCION; - typeConQos.m_force_type_validation = true; - - pub.init("TypeObject_TypeInformation", DOMAIN_ID_, type, type_obj, nullptr, nullptr, "Pub1", nullptr); - ASSERT_TRUE(pub.isInitialized()); - - sub.init("TypeObject_TypeInformation", DOMAIN_ID_, type1, nullptr, nullptr, type_info, "Sub1", nullptr, - &typeConQos); - ASSERT_TRUE(sub.isInitialized()); - - // Wait for discovery. - sub.waitDiscovery(false, 3); - pub.waitDiscovery(false, 3); -} - -/**** TODO - Enable when implemented - DataRepresentation Compatibility tests ****/ - -/* - * Empty-Empty - */ -TEST_F(xtypestests, DISABLED_DataRepQoSEE) -{ - TypeSupport type(new BasicStructPubSubType()); - TestPublisher pub; - TestSubscriber sub; - - DataRepresentationQosPolicy dataRepQos; - //dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XML_DATA_REPRESENTATION); - //dataRepQos.m_value.push_back(DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - - pub.init("DataRepQoSEE", DOMAIN_ID_, type, nullptr, nullptr, nullptr, "Pub1", &dataRepQos); - ASSERT_TRUE(pub.isInitialized()); - - sub.init("DataRepQoSEE", DOMAIN_ID_, type, nullptr, nullptr, nullptr, "Sub1", &dataRepQos, nullptr); - ASSERT_TRUE(sub.isInitialized()); - - // Wait for discovery. - sub.waitDiscovery(true, 3); - pub.waitDiscovery(true, 3); -} - -/* - * Empty-XCDR1 - */ -TEST_F(xtypestests, DISABLED_DataRepQoSE1) -{ - TypeSupport type(new BasicStructPubSubType()); - TestPublisher pub; - TestSubscriber sub; - - DataRepresentationQosPolicy dataRepQos1; - //dataRepQos1.m_value.push_back(DataRepresentationId_t::XCDR_DATA_REPRESENTATION); - //dataRepQos1.m_value.push_back(DataRepresentationId_t::XML_DATA_REPRESENTATION); - //dataRepQos1.m_value.push_back(DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - - DataRepresentationQosPolicy dataRepQos2; - dataRepQos2.m_value.push_back(DataRepresentationId_t::XCDR_DATA_REPRESENTATION); - //dataRepQos2.m_value.push_back(DataRepresentationId_t::XML_DATA_REPRESENTATION); - //dataRepQos2.m_value.push_back(DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - - pub.init("DataRepQoSE1", DOMAIN_ID_, type, nullptr, nullptr, nullptr, "Pub1", &dataRepQos1); - ASSERT_TRUE(pub.isInitialized()); - - sub.init("DataRepQoSE1", DOMAIN_ID_, type, nullptr, nullptr, nullptr, "Sub1", &dataRepQos2, nullptr); - ASSERT_TRUE(sub.isInitialized()); - - // Wait for discovery. - sub.waitDiscovery(true, 3); - pub.waitDiscovery(true, 3); -} - -/* - * Empty-XCDR2 - */ -TEST_F(xtypestests, DISABLED_DataRepQoSE2) -{ - TypeSupport type(new BasicStructPubSubType()); - TestPublisher pub; - TestSubscriber sub; - - DataRepresentationQosPolicy dataRepQos1; - //dataRepQos1.m_value.push_back(DataRepresentationId_t::XCDR_DATA_REPRESENTATION); - //dataRepQos1.m_value.push_back(DataRepresentationId_t::XML_DATA_REPRESENTATION); - //dataRepQos1.m_value.push_back(DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - - DataRepresentationQosPolicy dataRepQos2; - //dataRepQos2.m_value.push_back(DataRepresentationId_t::XCDR_DATA_REPRESENTATION); - //dataRepQos2.m_value.push_back(DataRepresentationId_t::XML_DATA_REPRESENTATION); - dataRepQos2.m_value.push_back(DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - - pub.init("DataRepQoSE2", DOMAIN_ID_, type, nullptr, nullptr, nullptr, "Pub1", &dataRepQos1); - ASSERT_TRUE(pub.isInitialized()); - - sub.init("DataRepQoSE2", DOMAIN_ID_, type, nullptr, nullptr, nullptr, "Sub1", &dataRepQos2, nullptr); - ASSERT_TRUE(sub.isInitialized()); - - // Wait for discovery. - sub.waitDiscovery(true, 3); - pub.waitDiscovery(true, 3); -} - -/* - * Empty-XML - */ -TEST_F(xtypestests, DISABLED_DataRepQoSEX) -{ - TypeSupport type(new BasicStructPubSubType()); - TestPublisher pub; - TestSubscriber sub; - - DataRepresentationQosPolicy dataRepQos1; - //dataRepQos1.m_value.push_back(DataRepresentationId_t::XCDR_DATA_REPRESENTATION); - //dataRepQos1.m_value.push_back(DataRepresentationId_t::XML_DATA_REPRESENTATION); - //dataRepQos1.m_value.push_back(DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - - DataRepresentationQosPolicy dataRepQos2; - //dataRepQos2.m_value.push_back(DataRepresentationId_t::XCDR_DATA_REPRESENTATION); - dataRepQos2.m_value.push_back(DataRepresentationId_t::XML_DATA_REPRESENTATION); - //dataRepQos2.m_value.push_back(DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - - pub.init("DataRepQoSEX", DOMAIN_ID_, type, nullptr, nullptr, nullptr, "Pub1", &dataRepQos1); - ASSERT_TRUE(pub.isInitialized()); - - sub.init("DataRepQoSEX", DOMAIN_ID_, type, nullptr, nullptr, nullptr, "Sub1", &dataRepQos2, nullptr); - ASSERT_TRUE(sub.isInitialized()); - - // Wait for discovery. - sub.waitDiscovery(false, 3); - pub.waitDiscovery(false, 3); -} - -/* - * Empty-XCDR12 - */ -TEST_F(xtypestests, DISABLED_DataRepQoSE12) -{ - TypeSupport type(new BasicStructPubSubType()); - TestPublisher pub; - TestSubscriber sub; - - DataRepresentationQosPolicy dataRepQos1; - //dataRepQos1.m_value.push_back(DataRepresentationId_t::XCDR_DATA_REPRESENTATION); - //dataRepQos1.m_value.push_back(DataRepresentationId_t::XML_DATA_REPRESENTATION); - //dataRepQos1.m_value.push_back(DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - - DataRepresentationQosPolicy dataRepQos2; - dataRepQos2.m_value.push_back(DataRepresentationId_t::XCDR_DATA_REPRESENTATION); - //dataRepQos2.m_value.push_back(DataRepresentationId_t::XML_DATA_REPRESENTATION); - dataRepQos2.m_value.push_back(DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - - pub.init("DataRepQoSE12", DOMAIN_ID_, type, nullptr, nullptr, nullptr, "Pub1", &dataRepQos1); - ASSERT_TRUE(pub.isInitialized()); - - sub.init("DataRepQoSE12", DOMAIN_ID_, type, nullptr, nullptr, nullptr, "Sub1", &dataRepQos2, nullptr); - ASSERT_TRUE(sub.isInitialized()); - - // Wait for discovery. - sub.waitDiscovery(true, 3); - pub.waitDiscovery(true, 3); -} - -/* - * XCDR1-XCDR2 - */ -TEST_F(xtypestests, DISABLED_DataRepQoS12) -{ - TypeSupport type(new BasicStructPubSubType()); - TestPublisher pub; - TestSubscriber sub; - - DataRepresentationQosPolicy dataRepQos1; - dataRepQos1.m_value.push_back(DataRepresentationId_t::XCDR_DATA_REPRESENTATION); - //dataRepQos1.m_value.push_back(DataRepresentationId_t::XML_DATA_REPRESENTATION); - //dataRepQos1.m_value.push_back(DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - - DataRepresentationQosPolicy dataRepQos2; - //dataRepQos2.m_value.push_back(DataRepresentationId_t::XCDR_DATA_REPRESENTATION); - //dataRepQos2.m_value.push_back(DataRepresentationId_t::XML_DATA_REPRESENTATION); - dataRepQos2.m_value.push_back(DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - - pub.init("DataRepQoS12", DOMAIN_ID_, type, nullptr, nullptr, nullptr, "Pub1", &dataRepQos1); - ASSERT_TRUE(pub.isInitialized()); - - sub.init("DataRepQoS12", DOMAIN_ID_, type, nullptr, nullptr, nullptr, "Sub1", &dataRepQos2, nullptr); - ASSERT_TRUE(sub.isInitialized()); - - // Wait for discovery. - sub.waitDiscovery(true, 3); - pub.waitDiscovery(true, 3); -} - -/* - * XCDR2-Empty - */ -TEST_F(xtypestests, DISABLED_DataRepQoS2E) -{ - TypeSupport type(new BasicStructPubSubType()); - TestPublisher pub; - TestSubscriber sub; - - DataRepresentationQosPolicy dataRepQos1; - //dataRepQos1.m_value.push_back(DataRepresentationId_t::XCDR_DATA_REPRESENTATION); - //dataRepQos1.m_value.push_back(DataRepresentationId_t::XML_DATA_REPRESENTATION); - //dataRepQos1.m_value.push_back(DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - - DataRepresentationQosPolicy dataRepQos2; - //dataRepQos2.m_value.push_back(DataRepresentationId_t::XCDR_DATA_REPRESENTATION); - //dataRepQos2.m_value.push_back(DataRepresentationId_t::XML_DATA_REPRESENTATION); - dataRepQos2.m_value.push_back(DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - - pub.init("DataRepQoS21", DOMAIN_ID_, type, nullptr, nullptr, nullptr, "Pub1", &dataRepQos2); - ASSERT_TRUE(pub.isInitialized()); - - sub.init("DataRepQoS21", DOMAIN_ID_, type, nullptr, nullptr, nullptr, "Sub1", &dataRepQos1, nullptr); - ASSERT_TRUE(sub.isInitialized()); - - // Wait for discovery. - sub.waitDiscovery(false, 3); - pub.waitDiscovery(false, 3); -} - -/* - * XCDR2-XCDR1 - */ -TEST_F(xtypestests, DISABLED_DataRepQoS21) -{ - TypeSupport type(new BasicStructPubSubType()); - TestPublisher pub; - TestSubscriber sub; - - DataRepresentationQosPolicy dataRepQos1; - dataRepQos1.m_value.push_back(DataRepresentationId_t::XCDR_DATA_REPRESENTATION); - //dataRepQos1.m_value.push_back(DataRepresentationId_t::XML_DATA_REPRESENTATION); - //dataRepQos1.m_value.push_back(DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - - DataRepresentationQosPolicy dataRepQos2; - //dataRepQos2.m_value.push_back(DataRepresentationId_t::XCDR_DATA_REPRESENTATION); - //dataRepQos2.m_value.push_back(DataRepresentationId_t::XML_DATA_REPRESENTATION); - dataRepQos2.m_value.push_back(DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - - pub.init("DataRepQoS21", DOMAIN_ID_, type, nullptr, nullptr, nullptr, "Pub1", &dataRepQos2); - ASSERT_TRUE(pub.isInitialized()); - - sub.init("DataRepQoS21", DOMAIN_ID_, type, nullptr, nullptr, nullptr, "Sub1", &dataRepQos1, nullptr); - ASSERT_TRUE(sub.isInitialized()); - - // Wait for discovery. - sub.waitDiscovery(false, 3); - pub.waitDiscovery(false, 3); -} - -/* - * XCDR2-XCDR2 - */ -TEST_F(xtypestests, DISABLED_DataRepQoS22) -{ - TypeSupport type(new BasicStructPubSubType()); - TestPublisher pub; - TestSubscriber sub; - - DataRepresentationQosPolicy dataRepQos2; - //dataRepQos2.m_value.push_back(DataRepresentationId_t::XCDR_DATA_REPRESENTATION); - //dataRepQos2.m_value.push_back(DataRepresentationId_t::XML_DATA_REPRESENTATION); - dataRepQos2.m_value.push_back(DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - - pub.init("DataRepQoS22", DOMAIN_ID_, type, nullptr, nullptr, nullptr, "Pub1", &dataRepQos2); - ASSERT_TRUE(pub.isInitialized()); - - sub.init("DataRepQoS22", DOMAIN_ID_, type, nullptr, nullptr, nullptr, "Sub1", &dataRepQos2, nullptr); - ASSERT_TRUE(sub.isInitialized()); - - // Wait for discovery. - sub.waitDiscovery(true, 3); - pub.waitDiscovery(true, 3); -} - -/* - * XML-Empty - */ -TEST_F(xtypestests, DISABLED_DataRepQoSXE) -{ - TypeSupport type(new BasicStructPubSubType()); - TestPublisher pub; - TestSubscriber sub; - - DataRepresentationQosPolicy dataRepQos1; - //dataRepQos1.m_value.push_back(DataRepresentationId_t::XCDR_DATA_REPRESENTATION); - //dataRepQos1.m_value.push_back(DataRepresentationId_t::XML_DATA_REPRESENTATION); - //dataRepQos1.m_value.push_back(DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - - DataRepresentationQosPolicy dataRepQos2; - //dataRepQos2.m_value.push_back(DataRepresentationId_t::XCDR_DATA_REPRESENTATION); - dataRepQos2.m_value.push_back(DataRepresentationId_t::XML_DATA_REPRESENTATION); - //dataRepQos2.m_value.push_back(DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - - pub.init("DataRepQoSXE", DOMAIN_ID_, type, nullptr, nullptr, nullptr, "Pub1", &dataRepQos2); - ASSERT_TRUE(pub.isInitialized()); - - sub.init("DataRepQoSXE", DOMAIN_ID_, type, nullptr, nullptr, nullptr, "Sub1", &dataRepQos1, nullptr); - ASSERT_TRUE(sub.isInitialized()); - - // Wait for discovery. - sub.waitDiscovery(false, 3); - pub.waitDiscovery(false, 3); -} - -/* - * XML-XML - Fails until supported. - */ -TEST_F(xtypestests, DISABLED_DataRepQoSXX) -{ - TypeSupport type(new BasicStructPubSubType()); - TestPublisher pub; - TestSubscriber sub; - - DataRepresentationQosPolicy dataRepQos1; - //dataRepQos1.m_value.push_back(DataRepresentationId_t::XCDR_DATA_REPRESENTATION); - dataRepQos1.m_value.push_back(DataRepresentationId_t::XML_DATA_REPRESENTATION); - //dataRepQos1.m_value.push_back(DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - - DataRepresentationQosPolicy dataRepQos2; - //dataRepQos2.m_value.push_back(DataRepresentationId_t::XCDR_DATA_REPRESENTATION); - dataRepQos2.m_value.push_back(DataRepresentationId_t::XML_DATA_REPRESENTATION); - //dataRepQos2.m_value.push_back(DataRepresentationId_t::XCDR2_DATA_REPRESENTATION); - - pub.init("DataRepQoSXE", DOMAIN_ID_, type, nullptr, nullptr, nullptr, "Pub1", &dataRepQos2); - ASSERT_TRUE(pub.isInitialized()); - - sub.init("DataRepQoSXE", DOMAIN_ID_, type, nullptr, nullptr, nullptr, "Sub1", &dataRepQos1, nullptr); - ASSERT_TRUE(sub.isInitialized()); - - // Wait for discovery. - sub.waitDiscovery(false, 3); - pub.waitDiscovery(false, 3); -} - -int main( - int argc, - char** argv) -{ - testing::InitGoogleTest(&argc, argv); - - return RUN_ALL_TESTS(); -} diff --git a/test/xtypes/idl/Types.cxx b/test/xtypes/idl/Types.cxx deleted file mode 100644 index d0ee9153b8d..00000000000 --- a/test/xtypes/idl/Types.cxx +++ /dev/null @@ -1,5244 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file Types.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "Types.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#include "TypesTypeObject.h" - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - - - - -MyEnumStruct::MyEnumStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -MyEnumStruct::~MyEnumStruct() -{ -} - -MyEnumStruct::MyEnumStruct( - const MyEnumStruct& x) -{ - m_my_enum = x.m_my_enum; -} - -MyEnumStruct::MyEnumStruct( - MyEnumStruct&& x) noexcept -{ - m_my_enum = x.m_my_enum; -} - -MyEnumStruct& MyEnumStruct::operator =( - const MyEnumStruct& x) -{ - - m_my_enum = x.m_my_enum; - return *this; -} - -MyEnumStruct& MyEnumStruct::operator =( - MyEnumStruct&& x) noexcept -{ - - m_my_enum = x.m_my_enum; - return *this; -} - -bool MyEnumStruct::operator ==( - const MyEnumStruct& x) const -{ - return (m_my_enum == x.m_my_enum); -} - -bool MyEnumStruct::operator !=( - const MyEnumStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member my_enum - * @param _my_enum New value for member my_enum - */ -void MyEnumStruct::my_enum( - MyEnum _my_enum) -{ - m_my_enum = _my_enum; -} - -/*! - * @brief This function returns the value of member my_enum - * @return Value of member my_enum - */ -MyEnum MyEnumStruct::my_enum() const -{ - return m_my_enum; -} - -/*! - * @brief This function returns a reference to member my_enum - * @return Reference to member my_enum - */ -MyEnum& MyEnumStruct::my_enum() -{ - return m_my_enum; -} - - - - -MyBadEnumStruct::MyBadEnumStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -MyBadEnumStruct::~MyBadEnumStruct() -{ -} - -MyBadEnumStruct::MyBadEnumStruct( - const MyBadEnumStruct& x) -{ - m_my_enum = x.m_my_enum; -} - -MyBadEnumStruct::MyBadEnumStruct( - MyBadEnumStruct&& x) noexcept -{ - m_my_enum = x.m_my_enum; -} - -MyBadEnumStruct& MyBadEnumStruct::operator =( - const MyBadEnumStruct& x) -{ - - m_my_enum = x.m_my_enum; - return *this; -} - -MyBadEnumStruct& MyBadEnumStruct::operator =( - MyBadEnumStruct&& x) noexcept -{ - - m_my_enum = x.m_my_enum; - return *this; -} - -bool MyBadEnumStruct::operator ==( - const MyBadEnumStruct& x) const -{ - return (m_my_enum == x.m_my_enum); -} - -bool MyBadEnumStruct::operator !=( - const MyBadEnumStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member my_enum - * @param _my_enum New value for member my_enum - */ -void MyBadEnumStruct::my_enum( - MyBadEnum _my_enum) -{ - m_my_enum = _my_enum; -} - -/*! - * @brief This function returns the value of member my_enum - * @return Value of member my_enum - */ -MyBadEnum MyBadEnumStruct::my_enum() const -{ - return m_my_enum; -} - -/*! - * @brief This function returns a reference to member my_enum - * @return Reference to member my_enum - */ -MyBadEnum& MyBadEnumStruct::my_enum() -{ - return m_my_enum; -} - - - - - -MyAliasEnumStruct::MyAliasEnumStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -MyAliasEnumStruct::~MyAliasEnumStruct() -{ -} - -MyAliasEnumStruct::MyAliasEnumStruct( - const MyAliasEnumStruct& x) -{ - m_my_enum = x.m_my_enum; -} - -MyAliasEnumStruct::MyAliasEnumStruct( - MyAliasEnumStruct&& x) noexcept -{ - m_my_enum = x.m_my_enum; -} - -MyAliasEnumStruct& MyAliasEnumStruct::operator =( - const MyAliasEnumStruct& x) -{ - - m_my_enum = x.m_my_enum; - return *this; -} - -MyAliasEnumStruct& MyAliasEnumStruct::operator =( - MyAliasEnumStruct&& x) noexcept -{ - - m_my_enum = x.m_my_enum; - return *this; -} - -bool MyAliasEnumStruct::operator ==( - const MyAliasEnumStruct& x) const -{ - return (m_my_enum == x.m_my_enum); -} - -bool MyAliasEnumStruct::operator !=( - const MyAliasEnumStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member my_enum - * @param _my_enum New value for member my_enum - */ -void MyAliasEnumStruct::my_enum( - MyAliasEnum _my_enum) -{ - m_my_enum = _my_enum; -} - -/*! - * @brief This function returns the value of member my_enum - * @return Value of member my_enum - */ -MyAliasEnum MyAliasEnumStruct::my_enum() const -{ - return m_my_enum; -} - -/*! - * @brief This function returns a reference to member my_enum - * @return Reference to member my_enum - */ -MyAliasEnum& MyAliasEnumStruct::my_enum() -{ - return m_my_enum; -} - - - - -BasicStruct::BasicStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -BasicStruct::~BasicStruct() -{ -} - -BasicStruct::BasicStruct( - const BasicStruct& x) -{ - m_my_bool = x.m_my_bool; - m_my_int32 = x.m_my_int32; - m_my_string = x.m_my_string; -} - -BasicStruct::BasicStruct( - BasicStruct&& x) noexcept -{ - m_my_bool = x.m_my_bool; - m_my_int32 = x.m_my_int32; - m_my_string = std::move(x.m_my_string); -} - -BasicStruct& BasicStruct::operator =( - const BasicStruct& x) -{ - - m_my_bool = x.m_my_bool; - m_my_int32 = x.m_my_int32; - m_my_string = x.m_my_string; - return *this; -} - -BasicStruct& BasicStruct::operator =( - BasicStruct&& x) noexcept -{ - - m_my_bool = x.m_my_bool; - m_my_int32 = x.m_my_int32; - m_my_string = std::move(x.m_my_string); - return *this; -} - -bool BasicStruct::operator ==( - const BasicStruct& x) const -{ - return (m_my_bool == x.m_my_bool && - m_my_int32 == x.m_my_int32 && - m_my_string == x.m_my_string); -} - -bool BasicStruct::operator !=( - const BasicStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member my_bool - * @param _my_bool New value for member my_bool - */ -void BasicStruct::my_bool( - bool _my_bool) -{ - m_my_bool = _my_bool; -} - -/*! - * @brief This function returns the value of member my_bool - * @return Value of member my_bool - */ -bool BasicStruct::my_bool() const -{ - return m_my_bool; -} - -/*! - * @brief This function returns a reference to member my_bool - * @return Reference to member my_bool - */ -bool& BasicStruct::my_bool() -{ - return m_my_bool; -} - - -/*! - * @brief This function sets a value in member my_int32 - * @param _my_int32 New value for member my_int32 - */ -void BasicStruct::my_int32( - int32_t _my_int32) -{ - m_my_int32 = _my_int32; -} - -/*! - * @brief This function returns the value of member my_int32 - * @return Value of member my_int32 - */ -int32_t BasicStruct::my_int32() const -{ - return m_my_int32; -} - -/*! - * @brief This function returns a reference to member my_int32 - * @return Reference to member my_int32 - */ -int32_t& BasicStruct::my_int32() -{ - return m_my_int32; -} - - -/*! - * @brief This function copies the value in member my_string - * @param _my_string New value to be copied in member my_string - */ -void BasicStruct::my_string( - const std::string& _my_string) -{ - m_my_string = _my_string; -} - -/*! - * @brief This function moves the value in member my_string - * @param _my_string New value to be moved in member my_string - */ -void BasicStruct::my_string( - std::string&& _my_string) -{ - m_my_string = std::move(_my_string); -} - -/*! - * @brief This function returns a constant reference to member my_string - * @return Constant reference to member my_string - */ -const std::string& BasicStruct::my_string() const -{ - return m_my_string; -} - -/*! - * @brief This function returns a reference to member my_string - * @return Reference to member my_string - */ -std::string& BasicStruct::my_string() -{ - return m_my_string; -} - - - - -BasicNamesStruct::BasicNamesStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -BasicNamesStruct::~BasicNamesStruct() -{ -} - -BasicNamesStruct::BasicNamesStruct( - const BasicNamesStruct& x) -{ - m_my_bool_name = x.m_my_bool_name; - m_my_int32_name = x.m_my_int32_name; - m_my_string_name = x.m_my_string_name; -} - -BasicNamesStruct::BasicNamesStruct( - BasicNamesStruct&& x) noexcept -{ - m_my_bool_name = x.m_my_bool_name; - m_my_int32_name = x.m_my_int32_name; - m_my_string_name = std::move(x.m_my_string_name); -} - -BasicNamesStruct& BasicNamesStruct::operator =( - const BasicNamesStruct& x) -{ - - m_my_bool_name = x.m_my_bool_name; - m_my_int32_name = x.m_my_int32_name; - m_my_string_name = x.m_my_string_name; - return *this; -} - -BasicNamesStruct& BasicNamesStruct::operator =( - BasicNamesStruct&& x) noexcept -{ - - m_my_bool_name = x.m_my_bool_name; - m_my_int32_name = x.m_my_int32_name; - m_my_string_name = std::move(x.m_my_string_name); - return *this; -} - -bool BasicNamesStruct::operator ==( - const BasicNamesStruct& x) const -{ - return (m_my_bool_name == x.m_my_bool_name && - m_my_int32_name == x.m_my_int32_name && - m_my_string_name == x.m_my_string_name); -} - -bool BasicNamesStruct::operator !=( - const BasicNamesStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member my_bool_name - * @param _my_bool_name New value for member my_bool_name - */ -void BasicNamesStruct::my_bool_name( - bool _my_bool_name) -{ - m_my_bool_name = _my_bool_name; -} - -/*! - * @brief This function returns the value of member my_bool_name - * @return Value of member my_bool_name - */ -bool BasicNamesStruct::my_bool_name() const -{ - return m_my_bool_name; -} - -/*! - * @brief This function returns a reference to member my_bool_name - * @return Reference to member my_bool_name - */ -bool& BasicNamesStruct::my_bool_name() -{ - return m_my_bool_name; -} - - -/*! - * @brief This function sets a value in member my_int32_name - * @param _my_int32_name New value for member my_int32_name - */ -void BasicNamesStruct::my_int32_name( - int32_t _my_int32_name) -{ - m_my_int32_name = _my_int32_name; -} - -/*! - * @brief This function returns the value of member my_int32_name - * @return Value of member my_int32_name - */ -int32_t BasicNamesStruct::my_int32_name() const -{ - return m_my_int32_name; -} - -/*! - * @brief This function returns a reference to member my_int32_name - * @return Reference to member my_int32_name - */ -int32_t& BasicNamesStruct::my_int32_name() -{ - return m_my_int32_name; -} - - -/*! - * @brief This function copies the value in member my_string_name - * @param _my_string_name New value to be copied in member my_string_name - */ -void BasicNamesStruct::my_string_name( - const std::string& _my_string_name) -{ - m_my_string_name = _my_string_name; -} - -/*! - * @brief This function moves the value in member my_string_name - * @param _my_string_name New value to be moved in member my_string_name - */ -void BasicNamesStruct::my_string_name( - std::string&& _my_string_name) -{ - m_my_string_name = std::move(_my_string_name); -} - -/*! - * @brief This function returns a constant reference to member my_string_name - * @return Constant reference to member my_string_name - */ -const std::string& BasicNamesStruct::my_string_name() const -{ - return m_my_string_name; -} - -/*! - * @brief This function returns a reference to member my_string_name - * @return Reference to member my_string_name - */ -std::string& BasicNamesStruct::my_string_name() -{ - return m_my_string_name; -} - - - - -BasicBadStruct::BasicBadStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -BasicBadStruct::~BasicBadStruct() -{ -} - -BasicBadStruct::BasicBadStruct( - const BasicBadStruct& x) -{ - m_my_bool = x.m_my_bool; - m_my_int32 = x.m_my_int32; - m_my_string = x.m_my_string; -} - -BasicBadStruct::BasicBadStruct( - BasicBadStruct&& x) noexcept -{ - m_my_bool = x.m_my_bool; - m_my_int32 = x.m_my_int32; - m_my_string = std::move(x.m_my_string); -} - -BasicBadStruct& BasicBadStruct::operator =( - const BasicBadStruct& x) -{ - - m_my_bool = x.m_my_bool; - m_my_int32 = x.m_my_int32; - m_my_string = x.m_my_string; - return *this; -} - -BasicBadStruct& BasicBadStruct::operator =( - BasicBadStruct&& x) noexcept -{ - - m_my_bool = x.m_my_bool; - m_my_int32 = x.m_my_int32; - m_my_string = std::move(x.m_my_string); - return *this; -} - -bool BasicBadStruct::operator ==( - const BasicBadStruct& x) const -{ - return (m_my_bool == x.m_my_bool && - m_my_int32 == x.m_my_int32 && - m_my_string == x.m_my_string); -} - -bool BasicBadStruct::operator !=( - const BasicBadStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member my_bool - * @param _my_bool New value for member my_bool - */ -void BasicBadStruct::my_bool( - uint8_t _my_bool) -{ - m_my_bool = _my_bool; -} - -/*! - * @brief This function returns the value of member my_bool - * @return Value of member my_bool - */ -uint8_t BasicBadStruct::my_bool() const -{ - return m_my_bool; -} - -/*! - * @brief This function returns a reference to member my_bool - * @return Reference to member my_bool - */ -uint8_t& BasicBadStruct::my_bool() -{ - return m_my_bool; -} - - -/*! - * @brief This function sets a value in member my_int32 - * @param _my_int32 New value for member my_int32 - */ -void BasicBadStruct::my_int32( - int32_t _my_int32) -{ - m_my_int32 = _my_int32; -} - -/*! - * @brief This function returns the value of member my_int32 - * @return Value of member my_int32 - */ -int32_t BasicBadStruct::my_int32() const -{ - return m_my_int32; -} - -/*! - * @brief This function returns a reference to member my_int32 - * @return Reference to member my_int32 - */ -int32_t& BasicBadStruct::my_int32() -{ - return m_my_int32; -} - - -/*! - * @brief This function copies the value in member my_string - * @param _my_string New value to be copied in member my_string - */ -void BasicBadStruct::my_string( - const std::string& _my_string) -{ - m_my_string = _my_string; -} - -/*! - * @brief This function moves the value in member my_string - * @param _my_string New value to be moved in member my_string - */ -void BasicBadStruct::my_string( - std::string&& _my_string) -{ - m_my_string = std::move(_my_string); -} - -/*! - * @brief This function returns a constant reference to member my_string - * @return Constant reference to member my_string - */ -const std::string& BasicBadStruct::my_string() const -{ - return m_my_string; -} - -/*! - * @brief This function returns a reference to member my_string - * @return Reference to member my_string - */ -std::string& BasicBadStruct::my_string() -{ - return m_my_string; -} - - - - -BasicWideStruct::BasicWideStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -BasicWideStruct::~BasicWideStruct() -{ -} - -BasicWideStruct::BasicWideStruct( - const BasicWideStruct& x) -{ - m_my_bool = x.m_my_bool; - m_my_int32 = x.m_my_int32; - m_my_string = x.m_my_string; - m_new_int32 = x.m_new_int32; - m_new_string = x.m_new_string; -} - -BasicWideStruct::BasicWideStruct( - BasicWideStruct&& x) noexcept -{ - m_my_bool = x.m_my_bool; - m_my_int32 = x.m_my_int32; - m_my_string = std::move(x.m_my_string); - m_new_int32 = x.m_new_int32; - m_new_string = std::move(x.m_new_string); -} - -BasicWideStruct& BasicWideStruct::operator =( - const BasicWideStruct& x) -{ - - m_my_bool = x.m_my_bool; - m_my_int32 = x.m_my_int32; - m_my_string = x.m_my_string; - m_new_int32 = x.m_new_int32; - m_new_string = x.m_new_string; - return *this; -} - -BasicWideStruct& BasicWideStruct::operator =( - BasicWideStruct&& x) noexcept -{ - - m_my_bool = x.m_my_bool; - m_my_int32 = x.m_my_int32; - m_my_string = std::move(x.m_my_string); - m_new_int32 = x.m_new_int32; - m_new_string = std::move(x.m_new_string); - return *this; -} - -bool BasicWideStruct::operator ==( - const BasicWideStruct& x) const -{ - return (m_my_bool == x.m_my_bool && - m_my_int32 == x.m_my_int32 && - m_my_string == x.m_my_string && - m_new_int32 == x.m_new_int32 && - m_new_string == x.m_new_string); -} - -bool BasicWideStruct::operator !=( - const BasicWideStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member my_bool - * @param _my_bool New value for member my_bool - */ -void BasicWideStruct::my_bool( - bool _my_bool) -{ - m_my_bool = _my_bool; -} - -/*! - * @brief This function returns the value of member my_bool - * @return Value of member my_bool - */ -bool BasicWideStruct::my_bool() const -{ - return m_my_bool; -} - -/*! - * @brief This function returns a reference to member my_bool - * @return Reference to member my_bool - */ -bool& BasicWideStruct::my_bool() -{ - return m_my_bool; -} - - -/*! - * @brief This function sets a value in member my_int32 - * @param _my_int32 New value for member my_int32 - */ -void BasicWideStruct::my_int32( - int32_t _my_int32) -{ - m_my_int32 = _my_int32; -} - -/*! - * @brief This function returns the value of member my_int32 - * @return Value of member my_int32 - */ -int32_t BasicWideStruct::my_int32() const -{ - return m_my_int32; -} - -/*! - * @brief This function returns a reference to member my_int32 - * @return Reference to member my_int32 - */ -int32_t& BasicWideStruct::my_int32() -{ - return m_my_int32; -} - - -/*! - * @brief This function copies the value in member my_string - * @param _my_string New value to be copied in member my_string - */ -void BasicWideStruct::my_string( - const std::string& _my_string) -{ - m_my_string = _my_string; -} - -/*! - * @brief This function moves the value in member my_string - * @param _my_string New value to be moved in member my_string - */ -void BasicWideStruct::my_string( - std::string&& _my_string) -{ - m_my_string = std::move(_my_string); -} - -/*! - * @brief This function returns a constant reference to member my_string - * @return Constant reference to member my_string - */ -const std::string& BasicWideStruct::my_string() const -{ - return m_my_string; -} - -/*! - * @brief This function returns a reference to member my_string - * @return Reference to member my_string - */ -std::string& BasicWideStruct::my_string() -{ - return m_my_string; -} - - -/*! - * @brief This function sets a value in member new_int32 - * @param _new_int32 New value for member new_int32 - */ -void BasicWideStruct::new_int32( - int32_t _new_int32) -{ - m_new_int32 = _new_int32; -} - -/*! - * @brief This function returns the value of member new_int32 - * @return Value of member new_int32 - */ -int32_t BasicWideStruct::new_int32() const -{ - return m_new_int32; -} - -/*! - * @brief This function returns a reference to member new_int32 - * @return Reference to member new_int32 - */ -int32_t& BasicWideStruct::new_int32() -{ - return m_new_int32; -} - - -/*! - * @brief This function copies the value in member new_string - * @param _new_string New value to be copied in member new_string - */ -void BasicWideStruct::new_string( - const std::string& _new_string) -{ - m_new_string = _new_string; -} - -/*! - * @brief This function moves the value in member new_string - * @param _new_string New value to be moved in member new_string - */ -void BasicWideStruct::new_string( - std::string&& _new_string) -{ - m_new_string = std::move(_new_string); -} - -/*! - * @brief This function returns a constant reference to member new_string - * @return Constant reference to member new_string - */ -const std::string& BasicWideStruct::new_string() const -{ - return m_new_string; -} - -/*! - * @brief This function returns a reference to member new_string - * @return Reference to member new_string - */ -std::string& BasicWideStruct::new_string() -{ - return m_new_string; -} - - - - -BadBasicWideStruct::BadBasicWideStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -BadBasicWideStruct::~BadBasicWideStruct() -{ -} - -BadBasicWideStruct::BadBasicWideStruct( - const BadBasicWideStruct& x) -{ - m_new_int32 = x.m_new_int32; - m_new_string = x.m_new_string; - m_my_bool = x.m_my_bool; - m_my_int32 = x.m_my_int32; - m_my_string = x.m_my_string; -} - -BadBasicWideStruct::BadBasicWideStruct( - BadBasicWideStruct&& x) noexcept -{ - m_new_int32 = x.m_new_int32; - m_new_string = std::move(x.m_new_string); - m_my_bool = x.m_my_bool; - m_my_int32 = x.m_my_int32; - m_my_string = std::move(x.m_my_string); -} - -BadBasicWideStruct& BadBasicWideStruct::operator =( - const BadBasicWideStruct& x) -{ - - m_new_int32 = x.m_new_int32; - m_new_string = x.m_new_string; - m_my_bool = x.m_my_bool; - m_my_int32 = x.m_my_int32; - m_my_string = x.m_my_string; - return *this; -} - -BadBasicWideStruct& BadBasicWideStruct::operator =( - BadBasicWideStruct&& x) noexcept -{ - - m_new_int32 = x.m_new_int32; - m_new_string = std::move(x.m_new_string); - m_my_bool = x.m_my_bool; - m_my_int32 = x.m_my_int32; - m_my_string = std::move(x.m_my_string); - return *this; -} - -bool BadBasicWideStruct::operator ==( - const BadBasicWideStruct& x) const -{ - return (m_new_int32 == x.m_new_int32 && - m_new_string == x.m_new_string && - m_my_bool == x.m_my_bool && - m_my_int32 == x.m_my_int32 && - m_my_string == x.m_my_string); -} - -bool BadBasicWideStruct::operator !=( - const BadBasicWideStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function sets a value in member new_int32 - * @param _new_int32 New value for member new_int32 - */ -void BadBasicWideStruct::new_int32( - int32_t _new_int32) -{ - m_new_int32 = _new_int32; -} - -/*! - * @brief This function returns the value of member new_int32 - * @return Value of member new_int32 - */ -int32_t BadBasicWideStruct::new_int32() const -{ - return m_new_int32; -} - -/*! - * @brief This function returns a reference to member new_int32 - * @return Reference to member new_int32 - */ -int32_t& BadBasicWideStruct::new_int32() -{ - return m_new_int32; -} - - -/*! - * @brief This function copies the value in member new_string - * @param _new_string New value to be copied in member new_string - */ -void BadBasicWideStruct::new_string( - const std::string& _new_string) -{ - m_new_string = _new_string; -} - -/*! - * @brief This function moves the value in member new_string - * @param _new_string New value to be moved in member new_string - */ -void BadBasicWideStruct::new_string( - std::string&& _new_string) -{ - m_new_string = std::move(_new_string); -} - -/*! - * @brief This function returns a constant reference to member new_string - * @return Constant reference to member new_string - */ -const std::string& BadBasicWideStruct::new_string() const -{ - return m_new_string; -} - -/*! - * @brief This function returns a reference to member new_string - * @return Reference to member new_string - */ -std::string& BadBasicWideStruct::new_string() -{ - return m_new_string; -} - - -/*! - * @brief This function sets a value in member my_bool - * @param _my_bool New value for member my_bool - */ -void BadBasicWideStruct::my_bool( - bool _my_bool) -{ - m_my_bool = _my_bool; -} - -/*! - * @brief This function returns the value of member my_bool - * @return Value of member my_bool - */ -bool BadBasicWideStruct::my_bool() const -{ - return m_my_bool; -} - -/*! - * @brief This function returns a reference to member my_bool - * @return Reference to member my_bool - */ -bool& BadBasicWideStruct::my_bool() -{ - return m_my_bool; -} - - -/*! - * @brief This function sets a value in member my_int32 - * @param _my_int32 New value for member my_int32 - */ -void BadBasicWideStruct::my_int32( - int32_t _my_int32) -{ - m_my_int32 = _my_int32; -} - -/*! - * @brief This function returns the value of member my_int32 - * @return Value of member my_int32 - */ -int32_t BadBasicWideStruct::my_int32() const -{ - return m_my_int32; -} - -/*! - * @brief This function returns a reference to member my_int32 - * @return Reference to member my_int32 - */ -int32_t& BadBasicWideStruct::my_int32() -{ - return m_my_int32; -} - - -/*! - * @brief This function copies the value in member my_string - * @param _my_string New value to be copied in member my_string - */ -void BadBasicWideStruct::my_string( - const std::string& _my_string) -{ - m_my_string = _my_string; -} - -/*! - * @brief This function moves the value in member my_string - * @param _my_string New value to be moved in member my_string - */ -void BadBasicWideStruct::my_string( - std::string&& _my_string) -{ - m_my_string = std::move(_my_string); -} - -/*! - * @brief This function returns a constant reference to member my_string - * @return Constant reference to member my_string - */ -const std::string& BadBasicWideStruct::my_string() const -{ - return m_my_string; -} - -/*! - * @brief This function returns a reference to member my_string - * @return Reference to member my_string - */ -std::string& BadBasicWideStruct::my_string() -{ - return m_my_string; -} - - - - -StringStruct::StringStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -StringStruct::~StringStruct() -{ -} - -StringStruct::StringStruct( - const StringStruct& x) -{ - m_my_string = x.m_my_string; -} - -StringStruct::StringStruct( - StringStruct&& x) noexcept -{ - m_my_string = std::move(x.m_my_string); -} - -StringStruct& StringStruct::operator =( - const StringStruct& x) -{ - - m_my_string = x.m_my_string; - return *this; -} - -StringStruct& StringStruct::operator =( - StringStruct&& x) noexcept -{ - - m_my_string = std::move(x.m_my_string); - return *this; -} - -bool StringStruct::operator ==( - const StringStruct& x) const -{ - return (m_my_string == x.m_my_string); -} - -bool StringStruct::operator !=( - const StringStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_string - * @param _my_string New value to be copied in member my_string - */ -void StringStruct::my_string( - const std::string& _my_string) -{ - m_my_string = _my_string; -} - -/*! - * @brief This function moves the value in member my_string - * @param _my_string New value to be moved in member my_string - */ -void StringStruct::my_string( - std::string&& _my_string) -{ - m_my_string = std::move(_my_string); -} - -/*! - * @brief This function returns a constant reference to member my_string - * @return Constant reference to member my_string - */ -const std::string& StringStruct::my_string() const -{ - return m_my_string; -} - -/*! - * @brief This function returns a reference to member my_string - * @return Reference to member my_string - */ -std::string& StringStruct::my_string() -{ - return m_my_string; -} - - - - -LargeStringStruct::LargeStringStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -LargeStringStruct::~LargeStringStruct() -{ -} - -LargeStringStruct::LargeStringStruct( - const LargeStringStruct& x) -{ - m_my_large_string = x.m_my_large_string; -} - -LargeStringStruct::LargeStringStruct( - LargeStringStruct&& x) noexcept -{ - m_my_large_string = std::move(x.m_my_large_string); -} - -LargeStringStruct& LargeStringStruct::operator =( - const LargeStringStruct& x) -{ - - m_my_large_string = x.m_my_large_string; - return *this; -} - -LargeStringStruct& LargeStringStruct::operator =( - LargeStringStruct&& x) noexcept -{ - - m_my_large_string = std::move(x.m_my_large_string); - return *this; -} - -bool LargeStringStruct::operator ==( - const LargeStringStruct& x) const -{ - return (m_my_large_string == x.m_my_large_string); -} - -bool LargeStringStruct::operator !=( - const LargeStringStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_large_string - * @param _my_large_string New value to be copied in member my_large_string - */ -void LargeStringStruct::my_large_string( - const eprosima::fastcdr::fixed_string<41925>& _my_large_string) -{ - m_my_large_string = _my_large_string; -} - -/*! - * @brief This function moves the value in member my_large_string - * @param _my_large_string New value to be moved in member my_large_string - */ -void LargeStringStruct::my_large_string( - eprosima::fastcdr::fixed_string<41925>&& _my_large_string) -{ - m_my_large_string = std::move(_my_large_string); -} - -/*! - * @brief This function returns a constant reference to member my_large_string - * @return Constant reference to member my_large_string - */ -const eprosima::fastcdr::fixed_string<41925>& LargeStringStruct::my_large_string() const -{ - return m_my_large_string; -} - -/*! - * @brief This function returns a reference to member my_large_string - * @return Reference to member my_large_string - */ -eprosima::fastcdr::fixed_string<41925>& LargeStringStruct::my_large_string() -{ - return m_my_large_string; -} - - - - -WStringStruct::WStringStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -WStringStruct::~WStringStruct() -{ -} - -WStringStruct::WStringStruct( - const WStringStruct& x) -{ - m_my_wstring = x.m_my_wstring; -} - -WStringStruct::WStringStruct( - WStringStruct&& x) noexcept -{ - m_my_wstring = std::move(x.m_my_wstring); -} - -WStringStruct& WStringStruct::operator =( - const WStringStruct& x) -{ - - m_my_wstring = x.m_my_wstring; - return *this; -} - -WStringStruct& WStringStruct::operator =( - WStringStruct&& x) noexcept -{ - - m_my_wstring = std::move(x.m_my_wstring); - return *this; -} - -bool WStringStruct::operator ==( - const WStringStruct& x) const -{ - return (m_my_wstring == x.m_my_wstring); -} - -bool WStringStruct::operator !=( - const WStringStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_wstring - * @param _my_wstring New value to be copied in member my_wstring - */ -void WStringStruct::my_wstring( - const std::wstring& _my_wstring) -{ - m_my_wstring = _my_wstring; -} - -/*! - * @brief This function moves the value in member my_wstring - * @param _my_wstring New value to be moved in member my_wstring - */ -void WStringStruct::my_wstring( - std::wstring&& _my_wstring) -{ - m_my_wstring = std::move(_my_wstring); -} - -/*! - * @brief This function returns a constant reference to member my_wstring - * @return Constant reference to member my_wstring - */ -const std::wstring& WStringStruct::my_wstring() const -{ - return m_my_wstring; -} - -/*! - * @brief This function returns a reference to member my_wstring - * @return Reference to member my_wstring - */ -std::wstring& WStringStruct::my_wstring() -{ - return m_my_wstring; -} - - - - -LargeWStringStruct::LargeWStringStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -LargeWStringStruct::~LargeWStringStruct() -{ -} - -LargeWStringStruct::LargeWStringStruct( - const LargeWStringStruct& x) -{ - m_my_large_wstring = x.m_my_large_wstring; -} - -LargeWStringStruct::LargeWStringStruct( - LargeWStringStruct&& x) noexcept -{ - m_my_large_wstring = std::move(x.m_my_large_wstring); -} - -LargeWStringStruct& LargeWStringStruct::operator =( - const LargeWStringStruct& x) -{ - - m_my_large_wstring = x.m_my_large_wstring; - return *this; -} - -LargeWStringStruct& LargeWStringStruct::operator =( - LargeWStringStruct&& x) noexcept -{ - - m_my_large_wstring = std::move(x.m_my_large_wstring); - return *this; -} - -bool LargeWStringStruct::operator ==( - const LargeWStringStruct& x) const -{ - return (m_my_large_wstring == x.m_my_large_wstring); -} - -bool LargeWStringStruct::operator !=( - const LargeWStringStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_large_wstring - * @param _my_large_wstring New value to be copied in member my_large_wstring - */ -void LargeWStringStruct::my_large_wstring( - const std::wstring& _my_large_wstring) -{ - m_my_large_wstring = _my_large_wstring; -} - -/*! - * @brief This function moves the value in member my_large_wstring - * @param _my_large_wstring New value to be moved in member my_large_wstring - */ -void LargeWStringStruct::my_large_wstring( - std::wstring&& _my_large_wstring) -{ - m_my_large_wstring = std::move(_my_large_wstring); -} - -/*! - * @brief This function returns a constant reference to member my_large_wstring - * @return Constant reference to member my_large_wstring - */ -const std::wstring& LargeWStringStruct::my_large_wstring() const -{ - return m_my_large_wstring; -} - -/*! - * @brief This function returns a reference to member my_large_wstring - * @return Reference to member my_large_wstring - */ -std::wstring& LargeWStringStruct::my_large_wstring() -{ - return m_my_large_wstring; -} - - - - -ArrayStruct::ArrayStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -ArrayStruct::~ArrayStruct() -{ -} - -ArrayStruct::ArrayStruct( - const ArrayStruct& x) -{ - m_my_array = x.m_my_array; -} - -ArrayStruct::ArrayStruct( - ArrayStruct&& x) noexcept -{ - m_my_array = std::move(x.m_my_array); -} - -ArrayStruct& ArrayStruct::operator =( - const ArrayStruct& x) -{ - - m_my_array = x.m_my_array; - return *this; -} - -ArrayStruct& ArrayStruct::operator =( - ArrayStruct&& x) noexcept -{ - - m_my_array = std::move(x.m_my_array); - return *this; -} - -bool ArrayStruct::operator ==( - const ArrayStruct& x) const -{ - return (m_my_array == x.m_my_array); -} - -bool ArrayStruct::operator !=( - const ArrayStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_array - * @param _my_array New value to be copied in member my_array - */ -void ArrayStruct::my_array( - const std::array& _my_array) -{ - m_my_array = _my_array; -} - -/*! - * @brief This function moves the value in member my_array - * @param _my_array New value to be moved in member my_array - */ -void ArrayStruct::my_array( - std::array&& _my_array) -{ - m_my_array = std::move(_my_array); -} - -/*! - * @brief This function returns a constant reference to member my_array - * @return Constant reference to member my_array - */ -const std::array& ArrayStruct::my_array() const -{ - return m_my_array; -} - -/*! - * @brief This function returns a reference to member my_array - * @return Reference to member my_array - */ -std::array& ArrayStruct::my_array() -{ - return m_my_array; -} - - - - -ArrayStructEqual::ArrayStructEqual() -{ - // Just to register all known types - registerTypesTypes(); -} - -ArrayStructEqual::~ArrayStructEqual() -{ -} - -ArrayStructEqual::ArrayStructEqual( - const ArrayStructEqual& x) -{ - m_my_array_equal = x.m_my_array_equal; -} - -ArrayStructEqual::ArrayStructEqual( - ArrayStructEqual&& x) noexcept -{ - m_my_array_equal = std::move(x.m_my_array_equal); -} - -ArrayStructEqual& ArrayStructEqual::operator =( - const ArrayStructEqual& x) -{ - - m_my_array_equal = x.m_my_array_equal; - return *this; -} - -ArrayStructEqual& ArrayStructEqual::operator =( - ArrayStructEqual&& x) noexcept -{ - - m_my_array_equal = std::move(x.m_my_array_equal); - return *this; -} - -bool ArrayStructEqual::operator ==( - const ArrayStructEqual& x) const -{ - return (m_my_array_equal == x.m_my_array_equal); -} - -bool ArrayStructEqual::operator !=( - const ArrayStructEqual& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_array_equal - * @param _my_array_equal New value to be copied in member my_array_equal - */ -void ArrayStructEqual::my_array_equal( - const std::array& _my_array_equal) -{ - m_my_array_equal = _my_array_equal; -} - -/*! - * @brief This function moves the value in member my_array_equal - * @param _my_array_equal New value to be moved in member my_array_equal - */ -void ArrayStructEqual::my_array_equal( - std::array&& _my_array_equal) -{ - m_my_array_equal = std::move(_my_array_equal); -} - -/*! - * @brief This function returns a constant reference to member my_array_equal - * @return Constant reference to member my_array_equal - */ -const std::array& ArrayStructEqual::my_array_equal() const -{ - return m_my_array_equal; -} - -/*! - * @brief This function returns a reference to member my_array_equal - * @return Reference to member my_array_equal - */ -std::array& ArrayStructEqual::my_array_equal() -{ - return m_my_array_equal; -} - - - - -ArrayBadStruct::ArrayBadStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -ArrayBadStruct::~ArrayBadStruct() -{ -} - -ArrayBadStruct::ArrayBadStruct( - const ArrayBadStruct& x) -{ - m_my_array = x.m_my_array; -} - -ArrayBadStruct::ArrayBadStruct( - ArrayBadStruct&& x) noexcept -{ - m_my_array = std::move(x.m_my_array); -} - -ArrayBadStruct& ArrayBadStruct::operator =( - const ArrayBadStruct& x) -{ - - m_my_array = x.m_my_array; - return *this; -} - -ArrayBadStruct& ArrayBadStruct::operator =( - ArrayBadStruct&& x) noexcept -{ - - m_my_array = std::move(x.m_my_array); - return *this; -} - -bool ArrayBadStruct::operator ==( - const ArrayBadStruct& x) const -{ - return (m_my_array == x.m_my_array); -} - -bool ArrayBadStruct::operator !=( - const ArrayBadStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_array - * @param _my_array New value to be copied in member my_array - */ -void ArrayBadStruct::my_array( - const std::array& _my_array) -{ - m_my_array = _my_array; -} - -/*! - * @brief This function moves the value in member my_array - * @param _my_array New value to be moved in member my_array - */ -void ArrayBadStruct::my_array( - std::array&& _my_array) -{ - m_my_array = std::move(_my_array); -} - -/*! - * @brief This function returns a constant reference to member my_array - * @return Constant reference to member my_array - */ -const std::array& ArrayBadStruct::my_array() const -{ - return m_my_array; -} - -/*! - * @brief This function returns a reference to member my_array - * @return Reference to member my_array - */ -std::array& ArrayBadStruct::my_array() -{ - return m_my_array; -} - - - - -ArrayDimensionsStruct::ArrayDimensionsStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -ArrayDimensionsStruct::~ArrayDimensionsStruct() -{ -} - -ArrayDimensionsStruct::ArrayDimensionsStruct( - const ArrayDimensionsStruct& x) -{ - m_my_array = x.m_my_array; -} - -ArrayDimensionsStruct::ArrayDimensionsStruct( - ArrayDimensionsStruct&& x) noexcept -{ - m_my_array = std::move(x.m_my_array); -} - -ArrayDimensionsStruct& ArrayDimensionsStruct::operator =( - const ArrayDimensionsStruct& x) -{ - - m_my_array = x.m_my_array; - return *this; -} - -ArrayDimensionsStruct& ArrayDimensionsStruct::operator =( - ArrayDimensionsStruct&& x) noexcept -{ - - m_my_array = std::move(x.m_my_array); - return *this; -} - -bool ArrayDimensionsStruct::operator ==( - const ArrayDimensionsStruct& x) const -{ - return (m_my_array == x.m_my_array); -} - -bool ArrayDimensionsStruct::operator !=( - const ArrayDimensionsStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_array - * @param _my_array New value to be copied in member my_array - */ -void ArrayDimensionsStruct::my_array( - const std::array, 2>& _my_array) -{ - m_my_array = _my_array; -} - -/*! - * @brief This function moves the value in member my_array - * @param _my_array New value to be moved in member my_array - */ -void ArrayDimensionsStruct::my_array( - std::array, 2>&& _my_array) -{ - m_my_array = std::move(_my_array); -} - -/*! - * @brief This function returns a constant reference to member my_array - * @return Constant reference to member my_array - */ -const std::array, 2>& ArrayDimensionsStruct::my_array() const -{ - return m_my_array; -} - -/*! - * @brief This function returns a reference to member my_array - * @return Reference to member my_array - */ -std::array, 2>& ArrayDimensionsStruct::my_array() -{ - return m_my_array; -} - - - - -ArraySizeStruct::ArraySizeStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -ArraySizeStruct::~ArraySizeStruct() -{ -} - -ArraySizeStruct::ArraySizeStruct( - const ArraySizeStruct& x) -{ - m_my_array = x.m_my_array; -} - -ArraySizeStruct::ArraySizeStruct( - ArraySizeStruct&& x) noexcept -{ - m_my_array = std::move(x.m_my_array); -} - -ArraySizeStruct& ArraySizeStruct::operator =( - const ArraySizeStruct& x) -{ - - m_my_array = x.m_my_array; - return *this; -} - -ArraySizeStruct& ArraySizeStruct::operator =( - ArraySizeStruct&& x) noexcept -{ - - m_my_array = std::move(x.m_my_array); - return *this; -} - -bool ArraySizeStruct::operator ==( - const ArraySizeStruct& x) const -{ - return (m_my_array == x.m_my_array); -} - -bool ArraySizeStruct::operator !=( - const ArraySizeStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_array - * @param _my_array New value to be copied in member my_array - */ -void ArraySizeStruct::my_array( - const std::array& _my_array) -{ - m_my_array = _my_array; -} - -/*! - * @brief This function moves the value in member my_array - * @param _my_array New value to be moved in member my_array - */ -void ArraySizeStruct::my_array( - std::array&& _my_array) -{ - m_my_array = std::move(_my_array); -} - -/*! - * @brief This function returns a constant reference to member my_array - * @return Constant reference to member my_array - */ -const std::array& ArraySizeStruct::my_array() const -{ - return m_my_array; -} - -/*! - * @brief This function returns a reference to member my_array - * @return Reference to member my_array - */ -std::array& ArraySizeStruct::my_array() -{ - return m_my_array; -} - - - - - - -SequenceStruct::SequenceStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -SequenceStruct::~SequenceStruct() -{ -} - -SequenceStruct::SequenceStruct( - const SequenceStruct& x) -{ - m_my_sequence = x.m_my_sequence; -} - -SequenceStruct::SequenceStruct( - SequenceStruct&& x) noexcept -{ - m_my_sequence = std::move(x.m_my_sequence); -} - -SequenceStruct& SequenceStruct::operator =( - const SequenceStruct& x) -{ - - m_my_sequence = x.m_my_sequence; - return *this; -} - -SequenceStruct& SequenceStruct::operator =( - SequenceStruct&& x) noexcept -{ - - m_my_sequence = std::move(x.m_my_sequence); - return *this; -} - -bool SequenceStruct::operator ==( - const SequenceStruct& x) const -{ - return (m_my_sequence == x.m_my_sequence); -} - -bool SequenceStruct::operator !=( - const SequenceStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_sequence - * @param _my_sequence New value to be copied in member my_sequence - */ -void SequenceStruct::my_sequence( - const std::vector& _my_sequence) -{ - m_my_sequence = _my_sequence; -} - -/*! - * @brief This function moves the value in member my_sequence - * @param _my_sequence New value to be moved in member my_sequence - */ -void SequenceStruct::my_sequence( - std::vector&& _my_sequence) -{ - m_my_sequence = std::move(_my_sequence); -} - -/*! - * @brief This function returns a constant reference to member my_sequence - * @return Constant reference to member my_sequence - */ -const std::vector& SequenceStruct::my_sequence() const -{ - return m_my_sequence; -} - -/*! - * @brief This function returns a reference to member my_sequence - * @return Reference to member my_sequence - */ -std::vector& SequenceStruct::my_sequence() -{ - return m_my_sequence; -} - - - - - - -SequenceStructEqual::SequenceStructEqual() -{ - // Just to register all known types - registerTypesTypes(); -} - -SequenceStructEqual::~SequenceStructEqual() -{ -} - -SequenceStructEqual::SequenceStructEqual( - const SequenceStructEqual& x) -{ - m_my_sequence_equal = x.m_my_sequence_equal; -} - -SequenceStructEqual::SequenceStructEqual( - SequenceStructEqual&& x) noexcept -{ - m_my_sequence_equal = std::move(x.m_my_sequence_equal); -} - -SequenceStructEqual& SequenceStructEqual::operator =( - const SequenceStructEqual& x) -{ - - m_my_sequence_equal = x.m_my_sequence_equal; - return *this; -} - -SequenceStructEqual& SequenceStructEqual::operator =( - SequenceStructEqual&& x) noexcept -{ - - m_my_sequence_equal = std::move(x.m_my_sequence_equal); - return *this; -} - -bool SequenceStructEqual::operator ==( - const SequenceStructEqual& x) const -{ - return (m_my_sequence_equal == x.m_my_sequence_equal); -} - -bool SequenceStructEqual::operator !=( - const SequenceStructEqual& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_sequence_equal - * @param _my_sequence_equal New value to be copied in member my_sequence_equal - */ -void SequenceStructEqual::my_sequence_equal( - const std::vector& _my_sequence_equal) -{ - m_my_sequence_equal = _my_sequence_equal; -} - -/*! - * @brief This function moves the value in member my_sequence_equal - * @param _my_sequence_equal New value to be moved in member my_sequence_equal - */ -void SequenceStructEqual::my_sequence_equal( - std::vector&& _my_sequence_equal) -{ - m_my_sequence_equal = std::move(_my_sequence_equal); -} - -/*! - * @brief This function returns a constant reference to member my_sequence_equal - * @return Constant reference to member my_sequence_equal - */ -const std::vector& SequenceStructEqual::my_sequence_equal() const -{ - return m_my_sequence_equal; -} - -/*! - * @brief This function returns a reference to member my_sequence_equal - * @return Reference to member my_sequence_equal - */ -std::vector& SequenceStructEqual::my_sequence_equal() -{ - return m_my_sequence_equal; -} - - - - - - -SequenceBadStruct::SequenceBadStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -SequenceBadStruct::~SequenceBadStruct() -{ -} - -SequenceBadStruct::SequenceBadStruct( - const SequenceBadStruct& x) -{ - m_my_sequence = x.m_my_sequence; -} - -SequenceBadStruct::SequenceBadStruct( - SequenceBadStruct&& x) noexcept -{ - m_my_sequence = std::move(x.m_my_sequence); -} - -SequenceBadStruct& SequenceBadStruct::operator =( - const SequenceBadStruct& x) -{ - - m_my_sequence = x.m_my_sequence; - return *this; -} - -SequenceBadStruct& SequenceBadStruct::operator =( - SequenceBadStruct&& x) noexcept -{ - - m_my_sequence = std::move(x.m_my_sequence); - return *this; -} - -bool SequenceBadStruct::operator ==( - const SequenceBadStruct& x) const -{ - return (m_my_sequence == x.m_my_sequence); -} - -bool SequenceBadStruct::operator !=( - const SequenceBadStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_sequence - * @param _my_sequence New value to be copied in member my_sequence - */ -void SequenceBadStruct::my_sequence( - const std::vector& _my_sequence) -{ - m_my_sequence = _my_sequence; -} - -/*! - * @brief This function moves the value in member my_sequence - * @param _my_sequence New value to be moved in member my_sequence - */ -void SequenceBadStruct::my_sequence( - std::vector&& _my_sequence) -{ - m_my_sequence = std::move(_my_sequence); -} - -/*! - * @brief This function returns a constant reference to member my_sequence - * @return Constant reference to member my_sequence - */ -const std::vector& SequenceBadStruct::my_sequence() const -{ - return m_my_sequence; -} - -/*! - * @brief This function returns a reference to member my_sequence - * @return Reference to member my_sequence - */ -std::vector& SequenceBadStruct::my_sequence() -{ - return m_my_sequence; -} - - - - - - -SequenceBoundsStruct::SequenceBoundsStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -SequenceBoundsStruct::~SequenceBoundsStruct() -{ -} - -SequenceBoundsStruct::SequenceBoundsStruct( - const SequenceBoundsStruct& x) -{ - m_my_sequence = x.m_my_sequence; -} - -SequenceBoundsStruct::SequenceBoundsStruct( - SequenceBoundsStruct&& x) noexcept -{ - m_my_sequence = std::move(x.m_my_sequence); -} - -SequenceBoundsStruct& SequenceBoundsStruct::operator =( - const SequenceBoundsStruct& x) -{ - - m_my_sequence = x.m_my_sequence; - return *this; -} - -SequenceBoundsStruct& SequenceBoundsStruct::operator =( - SequenceBoundsStruct&& x) noexcept -{ - - m_my_sequence = std::move(x.m_my_sequence); - return *this; -} - -bool SequenceBoundsStruct::operator ==( - const SequenceBoundsStruct& x) const -{ - return (m_my_sequence == x.m_my_sequence); -} - -bool SequenceBoundsStruct::operator !=( - const SequenceBoundsStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_sequence - * @param _my_sequence New value to be copied in member my_sequence - */ -void SequenceBoundsStruct::my_sequence( - const std::vector& _my_sequence) -{ - m_my_sequence = _my_sequence; -} - -/*! - * @brief This function moves the value in member my_sequence - * @param _my_sequence New value to be moved in member my_sequence - */ -void SequenceBoundsStruct::my_sequence( - std::vector&& _my_sequence) -{ - m_my_sequence = std::move(_my_sequence); -} - -/*! - * @brief This function returns a constant reference to member my_sequence - * @return Constant reference to member my_sequence - */ -const std::vector& SequenceBoundsStruct::my_sequence() const -{ - return m_my_sequence; -} - -/*! - * @brief This function returns a reference to member my_sequence - * @return Reference to member my_sequence - */ -std::vector& SequenceBoundsStruct::my_sequence() -{ - return m_my_sequence; -} - - - - - - - - -SequenceSequenceStruct::SequenceSequenceStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -SequenceSequenceStruct::~SequenceSequenceStruct() -{ -} - -SequenceSequenceStruct::SequenceSequenceStruct( - const SequenceSequenceStruct& x) -{ - m_my_sequence_sequence = x.m_my_sequence_sequence; -} - -SequenceSequenceStruct::SequenceSequenceStruct( - SequenceSequenceStruct&& x) noexcept -{ - m_my_sequence_sequence = std::move(x.m_my_sequence_sequence); -} - -SequenceSequenceStruct& SequenceSequenceStruct::operator =( - const SequenceSequenceStruct& x) -{ - - m_my_sequence_sequence = x.m_my_sequence_sequence; - return *this; -} - -SequenceSequenceStruct& SequenceSequenceStruct::operator =( - SequenceSequenceStruct&& x) noexcept -{ - - m_my_sequence_sequence = std::move(x.m_my_sequence_sequence); - return *this; -} - -bool SequenceSequenceStruct::operator ==( - const SequenceSequenceStruct& x) const -{ - return (m_my_sequence_sequence == x.m_my_sequence_sequence); -} - -bool SequenceSequenceStruct::operator !=( - const SequenceSequenceStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_sequence_sequence - * @param _my_sequence_sequence New value to be copied in member my_sequence_sequence - */ -void SequenceSequenceStruct::my_sequence_sequence( - const std::vector>& _my_sequence_sequence) -{ - m_my_sequence_sequence = _my_sequence_sequence; -} - -/*! - * @brief This function moves the value in member my_sequence_sequence - * @param _my_sequence_sequence New value to be moved in member my_sequence_sequence - */ -void SequenceSequenceStruct::my_sequence_sequence( - std::vector>&& _my_sequence_sequence) -{ - m_my_sequence_sequence = std::move(_my_sequence_sequence); -} - -/*! - * @brief This function returns a constant reference to member my_sequence_sequence - * @return Constant reference to member my_sequence_sequence - */ -const std::vector>& SequenceSequenceStruct::my_sequence_sequence() const -{ - return m_my_sequence_sequence; -} - -/*! - * @brief This function returns a reference to member my_sequence_sequence - * @return Reference to member my_sequence_sequence - */ -std::vector>& SequenceSequenceStruct::my_sequence_sequence() -{ - return m_my_sequence_sequence; -} - - - - - - - - -SequenceSequenceBoundsStruct::SequenceSequenceBoundsStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -SequenceSequenceBoundsStruct::~SequenceSequenceBoundsStruct() -{ -} - -SequenceSequenceBoundsStruct::SequenceSequenceBoundsStruct( - const SequenceSequenceBoundsStruct& x) -{ - m_my_sequence_sequence = x.m_my_sequence_sequence; -} - -SequenceSequenceBoundsStruct::SequenceSequenceBoundsStruct( - SequenceSequenceBoundsStruct&& x) noexcept -{ - m_my_sequence_sequence = std::move(x.m_my_sequence_sequence); -} - -SequenceSequenceBoundsStruct& SequenceSequenceBoundsStruct::operator =( - const SequenceSequenceBoundsStruct& x) -{ - - m_my_sequence_sequence = x.m_my_sequence_sequence; - return *this; -} - -SequenceSequenceBoundsStruct& SequenceSequenceBoundsStruct::operator =( - SequenceSequenceBoundsStruct&& x) noexcept -{ - - m_my_sequence_sequence = std::move(x.m_my_sequence_sequence); - return *this; -} - -bool SequenceSequenceBoundsStruct::operator ==( - const SequenceSequenceBoundsStruct& x) const -{ - return (m_my_sequence_sequence == x.m_my_sequence_sequence); -} - -bool SequenceSequenceBoundsStruct::operator !=( - const SequenceSequenceBoundsStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_sequence_sequence - * @param _my_sequence_sequence New value to be copied in member my_sequence_sequence - */ -void SequenceSequenceBoundsStruct::my_sequence_sequence( - const std::vector>& _my_sequence_sequence) -{ - m_my_sequence_sequence = _my_sequence_sequence; -} - -/*! - * @brief This function moves the value in member my_sequence_sequence - * @param _my_sequence_sequence New value to be moved in member my_sequence_sequence - */ -void SequenceSequenceBoundsStruct::my_sequence_sequence( - std::vector>&& _my_sequence_sequence) -{ - m_my_sequence_sequence = std::move(_my_sequence_sequence); -} - -/*! - * @brief This function returns a constant reference to member my_sequence_sequence - * @return Constant reference to member my_sequence_sequence - */ -const std::vector>& SequenceSequenceBoundsStruct::my_sequence_sequence() const -{ - return m_my_sequence_sequence; -} - -/*! - * @brief This function returns a reference to member my_sequence_sequence - * @return Reference to member my_sequence_sequence - */ -std::vector>& SequenceSequenceBoundsStruct::my_sequence_sequence() -{ - return m_my_sequence_sequence; -} - - - - - - -MapStruct::MapStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -MapStruct::~MapStruct() -{ -} - -MapStruct::MapStruct( - const MapStruct& x) -{ - m_my_map = x.m_my_map; -} - -MapStruct::MapStruct( - MapStruct&& x) noexcept -{ - m_my_map = std::move(x.m_my_map); -} - -MapStruct& MapStruct::operator =( - const MapStruct& x) -{ - - m_my_map = x.m_my_map; - return *this; -} - -MapStruct& MapStruct::operator =( - MapStruct&& x) noexcept -{ - - m_my_map = std::move(x.m_my_map); - return *this; -} - -bool MapStruct::operator ==( - const MapStruct& x) const -{ - return (m_my_map == x.m_my_map); -} - -bool MapStruct::operator !=( - const MapStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_map - * @param _my_map New value to be copied in member my_map - */ -void MapStruct::my_map( - const std::map& _my_map) -{ - m_my_map = _my_map; -} - -/*! - * @brief This function moves the value in member my_map - * @param _my_map New value to be moved in member my_map - */ -void MapStruct::my_map( - std::map&& _my_map) -{ - m_my_map = std::move(_my_map); -} - -/*! - * @brief This function returns a constant reference to member my_map - * @return Constant reference to member my_map - */ -const std::map& MapStruct::my_map() const -{ - return m_my_map; -} - -/*! - * @brief This function returns a reference to member my_map - * @return Reference to member my_map - */ -std::map& MapStruct::my_map() -{ - return m_my_map; -} - - - - - - -MapStructEqual::MapStructEqual() -{ - // Just to register all known types - registerTypesTypes(); -} - -MapStructEqual::~MapStructEqual() -{ -} - -MapStructEqual::MapStructEqual( - const MapStructEqual& x) -{ - m_my_map_equal = x.m_my_map_equal; -} - -MapStructEqual::MapStructEqual( - MapStructEqual&& x) noexcept -{ - m_my_map_equal = std::move(x.m_my_map_equal); -} - -MapStructEqual& MapStructEqual::operator =( - const MapStructEqual& x) -{ - - m_my_map_equal = x.m_my_map_equal; - return *this; -} - -MapStructEqual& MapStructEqual::operator =( - MapStructEqual&& x) noexcept -{ - - m_my_map_equal = std::move(x.m_my_map_equal); - return *this; -} - -bool MapStructEqual::operator ==( - const MapStructEqual& x) const -{ - return (m_my_map_equal == x.m_my_map_equal); -} - -bool MapStructEqual::operator !=( - const MapStructEqual& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_map_equal - * @param _my_map_equal New value to be copied in member my_map_equal - */ -void MapStructEqual::my_map_equal( - const std::map& _my_map_equal) -{ - m_my_map_equal = _my_map_equal; -} - -/*! - * @brief This function moves the value in member my_map_equal - * @param _my_map_equal New value to be moved in member my_map_equal - */ -void MapStructEqual::my_map_equal( - std::map&& _my_map_equal) -{ - m_my_map_equal = std::move(_my_map_equal); -} - -/*! - * @brief This function returns a constant reference to member my_map_equal - * @return Constant reference to member my_map_equal - */ -const std::map& MapStructEqual::my_map_equal() const -{ - return m_my_map_equal; -} - -/*! - * @brief This function returns a reference to member my_map_equal - * @return Reference to member my_map_equal - */ -std::map& MapStructEqual::my_map_equal() -{ - return m_my_map_equal; -} - - - - - - -MapBadKeyStruct::MapBadKeyStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -MapBadKeyStruct::~MapBadKeyStruct() -{ -} - -MapBadKeyStruct::MapBadKeyStruct( - const MapBadKeyStruct& x) -{ - m_my_map = x.m_my_map; -} - -MapBadKeyStruct::MapBadKeyStruct( - MapBadKeyStruct&& x) noexcept -{ - m_my_map = std::move(x.m_my_map); -} - -MapBadKeyStruct& MapBadKeyStruct::operator =( - const MapBadKeyStruct& x) -{ - - m_my_map = x.m_my_map; - return *this; -} - -MapBadKeyStruct& MapBadKeyStruct::operator =( - MapBadKeyStruct&& x) noexcept -{ - - m_my_map = std::move(x.m_my_map); - return *this; -} - -bool MapBadKeyStruct::operator ==( - const MapBadKeyStruct& x) const -{ - return (m_my_map == x.m_my_map); -} - -bool MapBadKeyStruct::operator !=( - const MapBadKeyStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_map - * @param _my_map New value to be copied in member my_map - */ -void MapBadKeyStruct::my_map( - const std::map& _my_map) -{ - m_my_map = _my_map; -} - -/*! - * @brief This function moves the value in member my_map - * @param _my_map New value to be moved in member my_map - */ -void MapBadKeyStruct::my_map( - std::map&& _my_map) -{ - m_my_map = std::move(_my_map); -} - -/*! - * @brief This function returns a constant reference to member my_map - * @return Constant reference to member my_map - */ -const std::map& MapBadKeyStruct::my_map() const -{ - return m_my_map; -} - -/*! - * @brief This function returns a reference to member my_map - * @return Reference to member my_map - */ -std::map& MapBadKeyStruct::my_map() -{ - return m_my_map; -} - - - - - - -MapBadElemStruct::MapBadElemStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -MapBadElemStruct::~MapBadElemStruct() -{ -} - -MapBadElemStruct::MapBadElemStruct( - const MapBadElemStruct& x) -{ - m_my_map = x.m_my_map; -} - -MapBadElemStruct::MapBadElemStruct( - MapBadElemStruct&& x) noexcept -{ - m_my_map = std::move(x.m_my_map); -} - -MapBadElemStruct& MapBadElemStruct::operator =( - const MapBadElemStruct& x) -{ - - m_my_map = x.m_my_map; - return *this; -} - -MapBadElemStruct& MapBadElemStruct::operator =( - MapBadElemStruct&& x) noexcept -{ - - m_my_map = std::move(x.m_my_map); - return *this; -} - -bool MapBadElemStruct::operator ==( - const MapBadElemStruct& x) const -{ - return (m_my_map == x.m_my_map); -} - -bool MapBadElemStruct::operator !=( - const MapBadElemStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_map - * @param _my_map New value to be copied in member my_map - */ -void MapBadElemStruct::my_map( - const std::map& _my_map) -{ - m_my_map = _my_map; -} - -/*! - * @brief This function moves the value in member my_map - * @param _my_map New value to be moved in member my_map - */ -void MapBadElemStruct::my_map( - std::map&& _my_map) -{ - m_my_map = std::move(_my_map); -} - -/*! - * @brief This function returns a constant reference to member my_map - * @return Constant reference to member my_map - */ -const std::map& MapBadElemStruct::my_map() const -{ - return m_my_map; -} - -/*! - * @brief This function returns a reference to member my_map - * @return Reference to member my_map - */ -std::map& MapBadElemStruct::my_map() -{ - return m_my_map; -} - - - - - - -MapBoundsStruct::MapBoundsStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -MapBoundsStruct::~MapBoundsStruct() -{ -} - -MapBoundsStruct::MapBoundsStruct( - const MapBoundsStruct& x) -{ - m_my_map = x.m_my_map; -} - -MapBoundsStruct::MapBoundsStruct( - MapBoundsStruct&& x) noexcept -{ - m_my_map = std::move(x.m_my_map); -} - -MapBoundsStruct& MapBoundsStruct::operator =( - const MapBoundsStruct& x) -{ - - m_my_map = x.m_my_map; - return *this; -} - -MapBoundsStruct& MapBoundsStruct::operator =( - MapBoundsStruct&& x) noexcept -{ - - m_my_map = std::move(x.m_my_map); - return *this; -} - -bool MapBoundsStruct::operator ==( - const MapBoundsStruct& x) const -{ - return (m_my_map == x.m_my_map); -} - -bool MapBoundsStruct::operator !=( - const MapBoundsStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_map - * @param _my_map New value to be copied in member my_map - */ -void MapBoundsStruct::my_map( - const std::map& _my_map) -{ - m_my_map = _my_map; -} - -/*! - * @brief This function moves the value in member my_map - * @param _my_map New value to be moved in member my_map - */ -void MapBoundsStruct::my_map( - std::map&& _my_map) -{ - m_my_map = std::move(_my_map); -} - -/*! - * @brief This function returns a constant reference to member my_map - * @return Constant reference to member my_map - */ -const std::map& MapBoundsStruct::my_map() const -{ - return m_my_map; -} - -/*! - * @brief This function returns a reference to member my_map - * @return Reference to member my_map - */ -std::map& MapBoundsStruct::my_map() -{ - return m_my_map; -} - - - - - - - - -MapMapStruct::MapMapStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -MapMapStruct::~MapMapStruct() -{ -} - -MapMapStruct::MapMapStruct( - const MapMapStruct& x) -{ - m_my_map_map = x.m_my_map_map; -} - -MapMapStruct::MapMapStruct( - MapMapStruct&& x) noexcept -{ - m_my_map_map = std::move(x.m_my_map_map); -} - -MapMapStruct& MapMapStruct::operator =( - const MapMapStruct& x) -{ - - m_my_map_map = x.m_my_map_map; - return *this; -} - -MapMapStruct& MapMapStruct::operator =( - MapMapStruct&& x) noexcept -{ - - m_my_map_map = std::move(x.m_my_map_map); - return *this; -} - -bool MapMapStruct::operator ==( - const MapMapStruct& x) const -{ - return (m_my_map_map == x.m_my_map_map); -} - -bool MapMapStruct::operator !=( - const MapMapStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_map_map - * @param _my_map_map New value to be copied in member my_map_map - */ -void MapMapStruct::my_map_map( - const std::map>& _my_map_map) -{ - m_my_map_map = _my_map_map; -} - -/*! - * @brief This function moves the value in member my_map_map - * @param _my_map_map New value to be moved in member my_map_map - */ -void MapMapStruct::my_map_map( - std::map>&& _my_map_map) -{ - m_my_map_map = std::move(_my_map_map); -} - -/*! - * @brief This function returns a constant reference to member my_map_map - * @return Constant reference to member my_map_map - */ -const std::map>& MapMapStruct::my_map_map() const -{ - return m_my_map_map; -} - -/*! - * @brief This function returns a reference to member my_map_map - * @return Reference to member my_map_map - */ -std::map>& MapMapStruct::my_map_map() -{ - return m_my_map_map; -} - - - - - - - - -MapMapBoundsStruct::MapMapBoundsStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -MapMapBoundsStruct::~MapMapBoundsStruct() -{ -} - -MapMapBoundsStruct::MapMapBoundsStruct( - const MapMapBoundsStruct& x) -{ - m_my_map_map = x.m_my_map_map; -} - -MapMapBoundsStruct::MapMapBoundsStruct( - MapMapBoundsStruct&& x) noexcept -{ - m_my_map_map = std::move(x.m_my_map_map); -} - -MapMapBoundsStruct& MapMapBoundsStruct::operator =( - const MapMapBoundsStruct& x) -{ - - m_my_map_map = x.m_my_map_map; - return *this; -} - -MapMapBoundsStruct& MapMapBoundsStruct::operator =( - MapMapBoundsStruct&& x) noexcept -{ - - m_my_map_map = std::move(x.m_my_map_map); - return *this; -} - -bool MapMapBoundsStruct::operator ==( - const MapMapBoundsStruct& x) const -{ - return (m_my_map_map == x.m_my_map_map); -} - -bool MapMapBoundsStruct::operator !=( - const MapMapBoundsStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_map_map - * @param _my_map_map New value to be copied in member my_map_map - */ -void MapMapBoundsStruct::my_map_map( - const std::map>& _my_map_map) -{ - m_my_map_map = _my_map_map; -} - -/*! - * @brief This function moves the value in member my_map_map - * @param _my_map_map New value to be moved in member my_map_map - */ -void MapMapBoundsStruct::my_map_map( - std::map>&& _my_map_map) -{ - m_my_map_map = std::move(_my_map_map); -} - -/*! - * @brief This function returns a constant reference to member my_map_map - * @return Constant reference to member my_map_map - */ -const std::map>& MapMapBoundsStruct::my_map_map() const -{ - return m_my_map_map; -} - -/*! - * @brief This function returns a reference to member my_map_map - * @return Reference to member my_map_map - */ -std::map>& MapMapBoundsStruct::my_map_map() -{ - return m_my_map_map; -} - - - - -SimpleUnion::SimpleUnion() -{ - m__d = A; -} - -SimpleUnion::~SimpleUnion() -{ -} - -SimpleUnion::SimpleUnion( - const SimpleUnion& x) -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } -} - -SimpleUnion::SimpleUnion( - SimpleUnion&& x) noexcept -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } -} - -SimpleUnion& SimpleUnion::operator =( - const SimpleUnion& x) -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } - - return *this; -} - -SimpleUnion& SimpleUnion::operator =( - SimpleUnion&& x) noexcept -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } - - return *this; -} - -bool SimpleUnion::operator ==( - const SimpleUnion& x) const -{ - if (m__d != x.m__d) - { - return false; - } - - switch (m__d) - { - case A: - return (m_first == x.m_first); - break; - - - case B: - return (m_second == x.m_second); - break; - - default: - break; - } - return false; -} - -bool SimpleUnion::operator !=( - const SimpleUnion& x) const -{ - return !(*this == x); -} - -void SimpleUnion::_d( - int32_t __d) -{ - bool b = false; - - switch (m__d) - { - case A: - switch (__d) - { - case A: - b = true; - break; - default: - break; - } - break; - - - case B: - switch (__d) - { - case B: - b = true; - break; - default: - break; - } - break; - - default: - break; - } - - if (!b) - { - throw BadParamException("Discriminator doesn't correspond with the selected union member"); - } - - m__d = __d; -} - -int32_t SimpleUnion::_d() const -{ - return m__d; -} - -int32_t& SimpleUnion::_d() -{ - return m__d; -} - -void SimpleUnion::first( - int32_t _first) -{ - m_first = _first; - m__d = A; - -} - -int32_t SimpleUnion::first() const -{ - bool b = false; - - switch (m__d) - { - case A: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first; -} - -int32_t& SimpleUnion::first() -{ - bool b = false; - - switch (m__d) - { - case A: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first; -} - - -void SimpleUnion::second( - int64_t _second) -{ - m_second = _second; - m__d = B; - -} - -int64_t SimpleUnion::second() const -{ - bool b = false; - - switch (m__d) - { - case B: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second; -} - -int64_t& SimpleUnion::second() -{ - bool b = false; - - switch (m__d) - { - case B: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second; -} - - - - -SimpleUnionNames::SimpleUnionNames() -{ - m__d = A; -} - -SimpleUnionNames::~SimpleUnionNames() -{ -} - -SimpleUnionNames::SimpleUnionNames( - const SimpleUnionNames& x) -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_first_case = x.m_first_case; - break; - - - case B: - m_second_case = x.m_second_case; - break; - - default: - break; - } -} - -SimpleUnionNames::SimpleUnionNames( - SimpleUnionNames&& x) noexcept -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_first_case = x.m_first_case; - break; - - - case B: - m_second_case = x.m_second_case; - break; - - default: - break; - } -} - -SimpleUnionNames& SimpleUnionNames::operator =( - const SimpleUnionNames& x) -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_first_case = x.m_first_case; - break; - - - case B: - m_second_case = x.m_second_case; - break; - - default: - break; - } - - return *this; -} - -SimpleUnionNames& SimpleUnionNames::operator =( - SimpleUnionNames&& x) noexcept -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_first_case = x.m_first_case; - break; - - - case B: - m_second_case = x.m_second_case; - break; - - default: - break; - } - - return *this; -} - -bool SimpleUnionNames::operator ==( - const SimpleUnionNames& x) const -{ - if (m__d != x.m__d) - { - return false; - } - - switch (m__d) - { - case A: - return (m_first_case == x.m_first_case); - break; - - - case B: - return (m_second_case == x.m_second_case); - break; - - default: - break; - } - return false; -} - -bool SimpleUnionNames::operator !=( - const SimpleUnionNames& x) const -{ - return !(*this == x); -} - -void SimpleUnionNames::_d( - int32_t __d) -{ - bool b = false; - - switch (m__d) - { - case A: - switch (__d) - { - case A: - b = true; - break; - default: - break; - } - break; - - - case B: - switch (__d) - { - case B: - b = true; - break; - default: - break; - } - break; - - default: - break; - } - - if (!b) - { - throw BadParamException("Discriminator doesn't correspond with the selected union member"); - } - - m__d = __d; -} - -int32_t SimpleUnionNames::_d() const -{ - return m__d; -} - -int32_t& SimpleUnionNames::_d() -{ - return m__d; -} - -void SimpleUnionNames::first_case( - int32_t _first_case) -{ - m_first_case = _first_case; - m__d = A; - -} - -int32_t SimpleUnionNames::first_case() const -{ - bool b = false; - - switch (m__d) - { - case A: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first_case; -} - -int32_t& SimpleUnionNames::first_case() -{ - bool b = false; - - switch (m__d) - { - case A: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first_case; -} - - -void SimpleUnionNames::second_case( - int64_t _second_case) -{ - m_second_case = _second_case; - m__d = B; - -} - -int64_t SimpleUnionNames::second_case() const -{ - bool b = false; - - switch (m__d) - { - case B: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second_case; -} - -int64_t& SimpleUnionNames::second_case() -{ - bool b = false; - - switch (m__d) - { - case B: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second_case; -} - - - - -SimpleTypeUnion::SimpleTypeUnion() -{ - m__d = A; -} - -SimpleTypeUnion::~SimpleTypeUnion() -{ -} - -SimpleTypeUnion::SimpleTypeUnion( - const SimpleTypeUnion& x) -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } -} - -SimpleTypeUnion::SimpleTypeUnion( - SimpleTypeUnion&& x) noexcept -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } -} - -SimpleTypeUnion& SimpleTypeUnion::operator =( - const SimpleTypeUnion& x) -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } - - return *this; -} - -SimpleTypeUnion& SimpleTypeUnion::operator =( - SimpleTypeUnion&& x) noexcept -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } - - return *this; -} - -bool SimpleTypeUnion::operator ==( - const SimpleTypeUnion& x) const -{ - if (m__d != x.m__d) - { - return false; - } - - switch (m__d) - { - case A: - return (m_first == x.m_first); - break; - - - case B: - return (m_second == x.m_second); - break; - - default: - break; - } - return false; -} - -bool SimpleTypeUnion::operator !=( - const SimpleTypeUnion& x) const -{ - return !(*this == x); -} - -void SimpleTypeUnion::_d( - int32_t __d) -{ - bool b = false; - - switch (m__d) - { - case A: - switch (__d) - { - case A: - b = true; - break; - default: - break; - } - break; - - - case B: - switch (__d) - { - case B: - b = true; - break; - default: - break; - } - break; - - default: - break; - } - - if (!b) - { - throw BadParamException("Discriminator doesn't correspond with the selected union member"); - } - - m__d = __d; -} - -int32_t SimpleTypeUnion::_d() const -{ - return m__d; -} - -int32_t& SimpleTypeUnion::_d() -{ - return m__d; -} - -void SimpleTypeUnion::first( - uint8_t _first) -{ - m_first = _first; - m__d = A; - -} - -uint8_t SimpleTypeUnion::first() const -{ - bool b = false; - - switch (m__d) - { - case A: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first; -} - -uint8_t& SimpleTypeUnion::first() -{ - bool b = false; - - switch (m__d) - { - case A: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first; -} - - -void SimpleTypeUnion::second( - int64_t _second) -{ - m_second = _second; - m__d = B; - -} - -int64_t SimpleTypeUnion::second() const -{ - bool b = false; - - switch (m__d) - { - case B: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second; -} - -int64_t& SimpleTypeUnion::second() -{ - bool b = false; - - switch (m__d) - { - case B: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second; -} - - - - -SimpleBadUnion::SimpleBadUnion() -{ - m__d = A; -} - -SimpleBadUnion::~SimpleBadUnion() -{ -} - -SimpleBadUnion::SimpleBadUnion( - const SimpleBadUnion& x) -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_first = x.m_first; - break; - - - case C: - m_second = x.m_second; - break; - - default: - break; - } -} - -SimpleBadUnion::SimpleBadUnion( - SimpleBadUnion&& x) noexcept -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_first = x.m_first; - break; - - - case C: - m_second = x.m_second; - break; - - default: - break; - } -} - -SimpleBadUnion& SimpleBadUnion::operator =( - const SimpleBadUnion& x) -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_first = x.m_first; - break; - - - case C: - m_second = x.m_second; - break; - - default: - break; - } - - return *this; -} - -SimpleBadUnion& SimpleBadUnion::operator =( - SimpleBadUnion&& x) noexcept -{ - m__d = x.m__d; - - switch (m__d) - { - case A: - m_first = x.m_first; - break; - - - case C: - m_second = x.m_second; - break; - - default: - break; - } - - return *this; -} - -bool SimpleBadUnion::operator ==( - const SimpleBadUnion& x) const -{ - if (m__d != x.m__d) - { - return false; - } - - switch (m__d) - { - case A: - return (m_first == x.m_first); - break; - - - case C: - return (m_second == x.m_second); - break; - - default: - break; - } - return false; -} - -bool SimpleBadUnion::operator !=( - const SimpleBadUnion& x) const -{ - return !(*this == x); -} - -void SimpleBadUnion::_d( - int32_t __d) -{ - bool b = false; - - switch (m__d) - { - case A: - switch (__d) - { - case A: - b = true; - break; - default: - break; - } - break; - - - case C: - switch (__d) - { - case C: - b = true; - break; - default: - break; - } - break; - - default: - break; - } - - if (!b) - { - throw BadParamException("Discriminator doesn't correspond with the selected union member"); - } - - m__d = __d; -} - -int32_t SimpleBadUnion::_d() const -{ - return m__d; -} - -int32_t& SimpleBadUnion::_d() -{ - return m__d; -} - -void SimpleBadUnion::first( - int32_t _first) -{ - m_first = _first; - m__d = A; - -} - -int32_t SimpleBadUnion::first() const -{ - bool b = false; - - switch (m__d) - { - case A: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first; -} - -int32_t& SimpleBadUnion::first() -{ - bool b = false; - - switch (m__d) - { - case A: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first; -} - - -void SimpleBadUnion::second( - int64_t _second) -{ - m_second = _second; - m__d = C; - -} - -int64_t SimpleBadUnion::second() const -{ - bool b = false; - - switch (m__d) - { - case C: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second; -} - -int64_t& SimpleBadUnion::second() -{ - bool b = false; - - switch (m__d) - { - case C: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second; -} - - - - -SimpleBadDiscUnion::SimpleBadDiscUnion() -{ - m__d = 0; -} - -SimpleBadDiscUnion::~SimpleBadDiscUnion() -{ -} - -SimpleBadDiscUnion::SimpleBadDiscUnion( - const SimpleBadDiscUnion& x) -{ - m__d = x.m__d; - - switch (m__d) - { - case 0: - m_first = x.m_first; - break; - - - case 1: - m_second = x.m_second; - break; - - default: - break; - } -} - -SimpleBadDiscUnion::SimpleBadDiscUnion( - SimpleBadDiscUnion&& x) noexcept -{ - m__d = x.m__d; - - switch (m__d) - { - case 0: - m_first = x.m_first; - break; - - - case 1: - m_second = x.m_second; - break; - - default: - break; - } -} - -SimpleBadDiscUnion& SimpleBadDiscUnion::operator =( - const SimpleBadDiscUnion& x) -{ - m__d = x.m__d; - - switch (m__d) - { - case 0: - m_first = x.m_first; - break; - - - case 1: - m_second = x.m_second; - break; - - default: - break; - } - - return *this; -} - -SimpleBadDiscUnion& SimpleBadDiscUnion::operator =( - SimpleBadDiscUnion&& x) noexcept -{ - m__d = x.m__d; - - switch (m__d) - { - case 0: - m_first = x.m_first; - break; - - - case 1: - m_second = x.m_second; - break; - - default: - break; - } - - return *this; -} - -bool SimpleBadDiscUnion::operator ==( - const SimpleBadDiscUnion& x) const -{ - if (m__d != x.m__d) - { - return false; - } - - switch (m__d) - { - case 0: - return (m_first == x.m_first); - break; - - - case 1: - return (m_second == x.m_second); - break; - - default: - break; - } - return false; -} - -bool SimpleBadDiscUnion::operator !=( - const SimpleBadDiscUnion& x) const -{ - return !(*this == x); -} - -void SimpleBadDiscUnion::_d( - uint8_t __d) -{ - bool b = false; - - switch (m__d) - { - case 0: - switch (__d) - { - case 0: - b = true; - break; - default: - break; - } - break; - - - case 1: - switch (__d) - { - case 1: - b = true; - break; - default: - break; - } - break; - - default: - break; - } - - if (!b) - { - throw BadParamException("Discriminator doesn't correspond with the selected union member"); - } - - m__d = __d; -} - -uint8_t SimpleBadDiscUnion::_d() const -{ - return m__d; -} - -uint8_t& SimpleBadDiscUnion::_d() -{ - return m__d; -} - -void SimpleBadDiscUnion::first( - int32_t _first) -{ - m_first = _first; - m__d = 0; - -} - -int32_t SimpleBadDiscUnion::first() const -{ - bool b = false; - - switch (m__d) - { - case 0: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first; -} - -int32_t& SimpleBadDiscUnion::first() -{ - bool b = false; - - switch (m__d) - { - case 0: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first; -} - - -void SimpleBadDiscUnion::second( - int64_t _second) -{ - m_second = _second; - m__d = 1; - -} - -int64_t SimpleBadDiscUnion::second() const -{ - bool b = false; - - switch (m__d) - { - case 1: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second; -} - -int64_t& SimpleBadDiscUnion::second() -{ - bool b = false; - - switch (m__d) - { - case 1: - b = true; - break; - default: - break; - } - - if (!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second; -} - - - - -SimpleUnionStruct::SimpleUnionStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -SimpleUnionStruct::~SimpleUnionStruct() -{ -} - -SimpleUnionStruct::SimpleUnionStruct( - const SimpleUnionStruct& x) -{ - m_my_union = x.m_my_union; -} - -SimpleUnionStruct::SimpleUnionStruct( - SimpleUnionStruct&& x) noexcept -{ - m_my_union = std::move(x.m_my_union); -} - -SimpleUnionStruct& SimpleUnionStruct::operator =( - const SimpleUnionStruct& x) -{ - - m_my_union = x.m_my_union; - return *this; -} - -SimpleUnionStruct& SimpleUnionStruct::operator =( - SimpleUnionStruct&& x) noexcept -{ - - m_my_union = std::move(x.m_my_union); - return *this; -} - -bool SimpleUnionStruct::operator ==( - const SimpleUnionStruct& x) const -{ - return (m_my_union == x.m_my_union); -} - -bool SimpleUnionStruct::operator !=( - const SimpleUnionStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ -void SimpleUnionStruct::my_union( - const SimpleUnion& _my_union) -{ - m_my_union = _my_union; -} - -/*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ -void SimpleUnionStruct::my_union( - SimpleUnion&& _my_union) -{ - m_my_union = std::move(_my_union); -} - -/*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ -const SimpleUnion& SimpleUnionStruct::my_union() const -{ - return m_my_union; -} - -/*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ -SimpleUnion& SimpleUnionStruct::my_union() -{ - return m_my_union; -} - - - - -SimpleUnionStructEqual::SimpleUnionStructEqual() -{ - // Just to register all known types - registerTypesTypes(); -} - -SimpleUnionStructEqual::~SimpleUnionStructEqual() -{ -} - -SimpleUnionStructEqual::SimpleUnionStructEqual( - const SimpleUnionStructEqual& x) -{ - m_my_union_equal = x.m_my_union_equal; -} - -SimpleUnionStructEqual::SimpleUnionStructEqual( - SimpleUnionStructEqual&& x) noexcept -{ - m_my_union_equal = std::move(x.m_my_union_equal); -} - -SimpleUnionStructEqual& SimpleUnionStructEqual::operator =( - const SimpleUnionStructEqual& x) -{ - - m_my_union_equal = x.m_my_union_equal; - return *this; -} - -SimpleUnionStructEqual& SimpleUnionStructEqual::operator =( - SimpleUnionStructEqual&& x) noexcept -{ - - m_my_union_equal = std::move(x.m_my_union_equal); - return *this; -} - -bool SimpleUnionStructEqual::operator ==( - const SimpleUnionStructEqual& x) const -{ - return (m_my_union_equal == x.m_my_union_equal); -} - -bool SimpleUnionStructEqual::operator !=( - const SimpleUnionStructEqual& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_union_equal - * @param _my_union_equal New value to be copied in member my_union_equal - */ -void SimpleUnionStructEqual::my_union_equal( - const SimpleUnion& _my_union_equal) -{ - m_my_union_equal = _my_union_equal; -} - -/*! - * @brief This function moves the value in member my_union_equal - * @param _my_union_equal New value to be moved in member my_union_equal - */ -void SimpleUnionStructEqual::my_union_equal( - SimpleUnion&& _my_union_equal) -{ - m_my_union_equal = std::move(_my_union_equal); -} - -/*! - * @brief This function returns a constant reference to member my_union_equal - * @return Constant reference to member my_union_equal - */ -const SimpleUnion& SimpleUnionStructEqual::my_union_equal() const -{ - return m_my_union_equal; -} - -/*! - * @brief This function returns a reference to member my_union_equal - * @return Reference to member my_union_equal - */ -SimpleUnion& SimpleUnionStructEqual::my_union_equal() -{ - return m_my_union_equal; -} - - - - -SimpleUnionNamesStruct::SimpleUnionNamesStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -SimpleUnionNamesStruct::~SimpleUnionNamesStruct() -{ -} - -SimpleUnionNamesStruct::SimpleUnionNamesStruct( - const SimpleUnionNamesStruct& x) -{ - m_my_union = x.m_my_union; -} - -SimpleUnionNamesStruct::SimpleUnionNamesStruct( - SimpleUnionNamesStruct&& x) noexcept -{ - m_my_union = std::move(x.m_my_union); -} - -SimpleUnionNamesStruct& SimpleUnionNamesStruct::operator =( - const SimpleUnionNamesStruct& x) -{ - - m_my_union = x.m_my_union; - return *this; -} - -SimpleUnionNamesStruct& SimpleUnionNamesStruct::operator =( - SimpleUnionNamesStruct&& x) noexcept -{ - - m_my_union = std::move(x.m_my_union); - return *this; -} - -bool SimpleUnionNamesStruct::operator ==( - const SimpleUnionNamesStruct& x) const -{ - return (m_my_union == x.m_my_union); -} - -bool SimpleUnionNamesStruct::operator !=( - const SimpleUnionNamesStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ -void SimpleUnionNamesStruct::my_union( - const SimpleUnionNames& _my_union) -{ - m_my_union = _my_union; -} - -/*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ -void SimpleUnionNamesStruct::my_union( - SimpleUnionNames&& _my_union) -{ - m_my_union = std::move(_my_union); -} - -/*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ -const SimpleUnionNames& SimpleUnionNamesStruct::my_union() const -{ - return m_my_union; -} - -/*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ -SimpleUnionNames& SimpleUnionNamesStruct::my_union() -{ - return m_my_union; -} - - - - -SimpleTypeUnionStruct::SimpleTypeUnionStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -SimpleTypeUnionStruct::~SimpleTypeUnionStruct() -{ -} - -SimpleTypeUnionStruct::SimpleTypeUnionStruct( - const SimpleTypeUnionStruct& x) -{ - m_my_union = x.m_my_union; -} - -SimpleTypeUnionStruct::SimpleTypeUnionStruct( - SimpleTypeUnionStruct&& x) noexcept -{ - m_my_union = std::move(x.m_my_union); -} - -SimpleTypeUnionStruct& SimpleTypeUnionStruct::operator =( - const SimpleTypeUnionStruct& x) -{ - - m_my_union = x.m_my_union; - return *this; -} - -SimpleTypeUnionStruct& SimpleTypeUnionStruct::operator =( - SimpleTypeUnionStruct&& x) noexcept -{ - - m_my_union = std::move(x.m_my_union); - return *this; -} - -bool SimpleTypeUnionStruct::operator ==( - const SimpleTypeUnionStruct& x) const -{ - return (m_my_union == x.m_my_union); -} - -bool SimpleTypeUnionStruct::operator !=( - const SimpleTypeUnionStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ -void SimpleTypeUnionStruct::my_union( - const SimpleTypeUnion& _my_union) -{ - m_my_union = _my_union; -} - -/*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ -void SimpleTypeUnionStruct::my_union( - SimpleTypeUnion&& _my_union) -{ - m_my_union = std::move(_my_union); -} - -/*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ -const SimpleTypeUnion& SimpleTypeUnionStruct::my_union() const -{ - return m_my_union; -} - -/*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ -SimpleTypeUnion& SimpleTypeUnionStruct::my_union() -{ - return m_my_union; -} - - - - -SimpleBadUnionStruct::SimpleBadUnionStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -SimpleBadUnionStruct::~SimpleBadUnionStruct() -{ -} - -SimpleBadUnionStruct::SimpleBadUnionStruct( - const SimpleBadUnionStruct& x) -{ - m_my_union = x.m_my_union; -} - -SimpleBadUnionStruct::SimpleBadUnionStruct( - SimpleBadUnionStruct&& x) noexcept -{ - m_my_union = std::move(x.m_my_union); -} - -SimpleBadUnionStruct& SimpleBadUnionStruct::operator =( - const SimpleBadUnionStruct& x) -{ - - m_my_union = x.m_my_union; - return *this; -} - -SimpleBadUnionStruct& SimpleBadUnionStruct::operator =( - SimpleBadUnionStruct&& x) noexcept -{ - - m_my_union = std::move(x.m_my_union); - return *this; -} - -bool SimpleBadUnionStruct::operator ==( - const SimpleBadUnionStruct& x) const -{ - return (m_my_union == x.m_my_union); -} - -bool SimpleBadUnionStruct::operator !=( - const SimpleBadUnionStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ -void SimpleBadUnionStruct::my_union( - const SimpleBadUnion& _my_union) -{ - m_my_union = _my_union; -} - -/*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ -void SimpleBadUnionStruct::my_union( - SimpleBadUnion&& _my_union) -{ - m_my_union = std::move(_my_union); -} - -/*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ -const SimpleBadUnion& SimpleBadUnionStruct::my_union() const -{ - return m_my_union; -} - -/*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ -SimpleBadUnion& SimpleBadUnionStruct::my_union() -{ - return m_my_union; -} - - - - -SimplBadDiscUnionStruct::SimplBadDiscUnionStruct() -{ - // Just to register all known types - registerTypesTypes(); -} - -SimplBadDiscUnionStruct::~SimplBadDiscUnionStruct() -{ -} - -SimplBadDiscUnionStruct::SimplBadDiscUnionStruct( - const SimplBadDiscUnionStruct& x) -{ - m_my_union = x.m_my_union; -} - -SimplBadDiscUnionStruct::SimplBadDiscUnionStruct( - SimplBadDiscUnionStruct&& x) noexcept -{ - m_my_union = std::move(x.m_my_union); -} - -SimplBadDiscUnionStruct& SimplBadDiscUnionStruct::operator =( - const SimplBadDiscUnionStruct& x) -{ - - m_my_union = x.m_my_union; - return *this; -} - -SimplBadDiscUnionStruct& SimplBadDiscUnionStruct::operator =( - SimplBadDiscUnionStruct&& x) noexcept -{ - - m_my_union = std::move(x.m_my_union); - return *this; -} - -bool SimplBadDiscUnionStruct::operator ==( - const SimplBadDiscUnionStruct& x) const -{ - return (m_my_union == x.m_my_union); -} - -bool SimplBadDiscUnionStruct::operator !=( - const SimplBadDiscUnionStruct& x) const -{ - return !(*this == x); -} - -/*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ -void SimplBadDiscUnionStruct::my_union( - const SimpleBadDiscUnion& _my_union) -{ - m_my_union = _my_union; -} - -/*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ -void SimplBadDiscUnionStruct::my_union( - SimpleBadDiscUnion&& _my_union) -{ - m_my_union = std::move(_my_union); -} - -/*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ -const SimpleBadDiscUnion& SimplBadDiscUnionStruct::my_union() const -{ - return m_my_union; -} - -/*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ -SimpleBadDiscUnion& SimplBadDiscUnionStruct::my_union() -{ - return m_my_union; -} - - -// Include auxiliary functions like for serializing/deserializing. -#include "TypesCdrAux.ipp" - -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/test/xtypes/idl/Types.h b/test/xtypes/idl/Types.h deleted file mode 100644 index e482676e515..00000000000 --- a/test/xtypes/idl/Types.h +++ /dev/null @@ -1,4432 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file Types.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#include -#include "Typesv1.h" - -#if FASTCDR_VERSION_MAJOR > 1 - -#ifndef _FAST_DDS_GENERATED_TYPES_H_ -#define _FAST_DDS_GENERATED_TYPES_H_ - -#include -#include -#include -#include -#include -#include - -#include -#include -#include - - - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define eProsima_user_DllExport -#endif // _WIN32 - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(TYPES_SOURCE) -#define TYPES_DllAPI __declspec( dllexport ) -#else -#define TYPES_DllAPI __declspec( dllimport ) -#endif // TYPES_SOURCE -#else -#define TYPES_DllAPI -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define TYPES_DllAPI -#endif // _WIN32 - -namespace eprosima { -namespace fastcdr { -class Cdr; -class CdrSizeCalculator; -} // namespace fastcdr -} // namespace eprosima - - - -/*! - * @brief This class represents the enumeration MyEnum defined by the user in the IDL file. - * @ingroup Types - */ -enum MyEnum : uint32_t -{ - A, - B, - C -}; -/*! - * @brief This class represents the enumeration MyBadEnum defined by the user in the IDL file. - * @ingroup Types - */ -enum MyBadEnum : uint32_t -{ - A1, - B1, - C1 -}; - - -/*! - * @brief This class represents the structure MyEnumStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MyEnumStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MyEnumStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MyEnumStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MyEnumStruct that will be copied. - */ - eProsima_user_DllExport MyEnumStruct( - const MyEnumStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MyEnumStruct that will be copied. - */ - eProsima_user_DllExport MyEnumStruct( - MyEnumStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MyEnumStruct that will be copied. - */ - eProsima_user_DllExport MyEnumStruct& operator =( - const MyEnumStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MyEnumStruct that will be copied. - */ - eProsima_user_DllExport MyEnumStruct& operator =( - MyEnumStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MyEnumStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MyEnumStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x MyEnumStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MyEnumStruct& x) const; - - /*! - * @brief This function sets a value in member my_enum - * @param _my_enum New value for member my_enum - */ - eProsima_user_DllExport void my_enum( - MyEnum _my_enum); - - /*! - * @brief This function returns the value of member my_enum - * @return Value of member my_enum - */ - eProsima_user_DllExport MyEnum my_enum() const; - - /*! - * @brief This function returns a reference to member my_enum - * @return Reference to member my_enum - */ - eProsima_user_DllExport MyEnum& my_enum(); - -private: - - MyEnum m_my_enum{::A}; - -}; - - -/*! - * @brief This class represents the structure MyBadEnumStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MyBadEnumStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MyBadEnumStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MyBadEnumStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MyBadEnumStruct that will be copied. - */ - eProsima_user_DllExport MyBadEnumStruct( - const MyBadEnumStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MyBadEnumStruct that will be copied. - */ - eProsima_user_DllExport MyBadEnumStruct( - MyBadEnumStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MyBadEnumStruct that will be copied. - */ - eProsima_user_DllExport MyBadEnumStruct& operator =( - const MyBadEnumStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MyBadEnumStruct that will be copied. - */ - eProsima_user_DllExport MyBadEnumStruct& operator =( - MyBadEnumStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MyBadEnumStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MyBadEnumStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x MyBadEnumStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MyBadEnumStruct& x) const; - - /*! - * @brief This function sets a value in member my_enum - * @param _my_enum New value for member my_enum - */ - eProsima_user_DllExport void my_enum( - MyBadEnum _my_enum); - - /*! - * @brief This function returns the value of member my_enum - * @return Value of member my_enum - */ - eProsima_user_DllExport MyBadEnum my_enum() const; - - /*! - * @brief This function returns a reference to member my_enum - * @return Reference to member my_enum - */ - eProsima_user_DllExport MyBadEnum& my_enum(); - -private: - - MyBadEnum m_my_enum{::A1}; - -}; -typedef MyEnum MyAliasEnum; - - - -/*! - * @brief This class represents the structure MyAliasEnumStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MyAliasEnumStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MyAliasEnumStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MyAliasEnumStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MyAliasEnumStruct that will be copied. - */ - eProsima_user_DllExport MyAliasEnumStruct( - const MyAliasEnumStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MyAliasEnumStruct that will be copied. - */ - eProsima_user_DllExport MyAliasEnumStruct( - MyAliasEnumStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MyAliasEnumStruct that will be copied. - */ - eProsima_user_DllExport MyAliasEnumStruct& operator =( - const MyAliasEnumStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MyAliasEnumStruct that will be copied. - */ - eProsima_user_DllExport MyAliasEnumStruct& operator =( - MyAliasEnumStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MyAliasEnumStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MyAliasEnumStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x MyAliasEnumStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MyAliasEnumStruct& x) const; - - /*! - * @brief This function sets a value in member my_enum - * @param _my_enum New value for member my_enum - */ - eProsima_user_DllExport void my_enum( - MyAliasEnum _my_enum); - - /*! - * @brief This function returns the value of member my_enum - * @return Value of member my_enum - */ - eProsima_user_DllExport MyAliasEnum my_enum() const; - - /*! - * @brief This function returns a reference to member my_enum - * @return Reference to member my_enum - */ - eProsima_user_DllExport MyAliasEnum& my_enum(); - -private: - - MyAliasEnum m_my_enum{::A}; - -}; - - -/*! - * @brief This class represents the structure BasicStruct defined by the user in the IDL file. - * @ingroup Types - */ -class BasicStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport BasicStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~BasicStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object BasicStruct that will be copied. - */ - eProsima_user_DllExport BasicStruct( - const BasicStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object BasicStruct that will be copied. - */ - eProsima_user_DllExport BasicStruct( - BasicStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object BasicStruct that will be copied. - */ - eProsima_user_DllExport BasicStruct& operator =( - const BasicStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object BasicStruct that will be copied. - */ - eProsima_user_DllExport BasicStruct& operator =( - BasicStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x BasicStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const BasicStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x BasicStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const BasicStruct& x) const; - - /*! - * @brief This function sets a value in member my_bool - * @param _my_bool New value for member my_bool - */ - eProsima_user_DllExport void my_bool( - bool _my_bool); - - /*! - * @brief This function returns the value of member my_bool - * @return Value of member my_bool - */ - eProsima_user_DllExport bool my_bool() const; - - /*! - * @brief This function returns a reference to member my_bool - * @return Reference to member my_bool - */ - eProsima_user_DllExport bool& my_bool(); - - - /*! - * @brief This function sets a value in member my_int32 - * @param _my_int32 New value for member my_int32 - */ - eProsima_user_DllExport void my_int32( - int32_t _my_int32); - - /*! - * @brief This function returns the value of member my_int32 - * @return Value of member my_int32 - */ - eProsima_user_DllExport int32_t my_int32() const; - - /*! - * @brief This function returns a reference to member my_int32 - * @return Reference to member my_int32 - */ - eProsima_user_DllExport int32_t& my_int32(); - - - /*! - * @brief This function copies the value in member my_string - * @param _my_string New value to be copied in member my_string - */ - eProsima_user_DllExport void my_string( - const std::string& _my_string); - - /*! - * @brief This function moves the value in member my_string - * @param _my_string New value to be moved in member my_string - */ - eProsima_user_DllExport void my_string( - std::string&& _my_string); - - /*! - * @brief This function returns a constant reference to member my_string - * @return Constant reference to member my_string - */ - eProsima_user_DllExport const std::string& my_string() const; - - /*! - * @brief This function returns a reference to member my_string - * @return Reference to member my_string - */ - eProsima_user_DllExport std::string& my_string(); - -private: - - bool m_my_bool{false}; - int32_t m_my_int32{0}; - std::string m_my_string; - -}; - - -/*! - * @brief This class represents the structure BasicNamesStruct defined by the user in the IDL file. - * @ingroup Types - */ -class BasicNamesStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport BasicNamesStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~BasicNamesStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object BasicNamesStruct that will be copied. - */ - eProsima_user_DllExport BasicNamesStruct( - const BasicNamesStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object BasicNamesStruct that will be copied. - */ - eProsima_user_DllExport BasicNamesStruct( - BasicNamesStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object BasicNamesStruct that will be copied. - */ - eProsima_user_DllExport BasicNamesStruct& operator =( - const BasicNamesStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object BasicNamesStruct that will be copied. - */ - eProsima_user_DllExport BasicNamesStruct& operator =( - BasicNamesStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x BasicNamesStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const BasicNamesStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x BasicNamesStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const BasicNamesStruct& x) const; - - /*! - * @brief This function sets a value in member my_bool_name - * @param _my_bool_name New value for member my_bool_name - */ - eProsima_user_DllExport void my_bool_name( - bool _my_bool_name); - - /*! - * @brief This function returns the value of member my_bool_name - * @return Value of member my_bool_name - */ - eProsima_user_DllExport bool my_bool_name() const; - - /*! - * @brief This function returns a reference to member my_bool_name - * @return Reference to member my_bool_name - */ - eProsima_user_DllExport bool& my_bool_name(); - - - /*! - * @brief This function sets a value in member my_int32_name - * @param _my_int32_name New value for member my_int32_name - */ - eProsima_user_DllExport void my_int32_name( - int32_t _my_int32_name); - - /*! - * @brief This function returns the value of member my_int32_name - * @return Value of member my_int32_name - */ - eProsima_user_DllExport int32_t my_int32_name() const; - - /*! - * @brief This function returns a reference to member my_int32_name - * @return Reference to member my_int32_name - */ - eProsima_user_DllExport int32_t& my_int32_name(); - - - /*! - * @brief This function copies the value in member my_string_name - * @param _my_string_name New value to be copied in member my_string_name - */ - eProsima_user_DllExport void my_string_name( - const std::string& _my_string_name); - - /*! - * @brief This function moves the value in member my_string_name - * @param _my_string_name New value to be moved in member my_string_name - */ - eProsima_user_DllExport void my_string_name( - std::string&& _my_string_name); - - /*! - * @brief This function returns a constant reference to member my_string_name - * @return Constant reference to member my_string_name - */ - eProsima_user_DllExport const std::string& my_string_name() const; - - /*! - * @brief This function returns a reference to member my_string_name - * @return Reference to member my_string_name - */ - eProsima_user_DllExport std::string& my_string_name(); - -private: - - bool m_my_bool_name{false}; - int32_t m_my_int32_name{0}; - std::string m_my_string_name; - -}; - - -/*! - * @brief This class represents the structure BasicBadStruct defined by the user in the IDL file. - * @ingroup Types - */ -class BasicBadStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport BasicBadStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~BasicBadStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object BasicBadStruct that will be copied. - */ - eProsima_user_DllExport BasicBadStruct( - const BasicBadStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object BasicBadStruct that will be copied. - */ - eProsima_user_DllExport BasicBadStruct( - BasicBadStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object BasicBadStruct that will be copied. - */ - eProsima_user_DllExport BasicBadStruct& operator =( - const BasicBadStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object BasicBadStruct that will be copied. - */ - eProsima_user_DllExport BasicBadStruct& operator =( - BasicBadStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x BasicBadStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const BasicBadStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x BasicBadStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const BasicBadStruct& x) const; - - /*! - * @brief This function sets a value in member my_bool - * @param _my_bool New value for member my_bool - */ - eProsima_user_DllExport void my_bool( - uint8_t _my_bool); - - /*! - * @brief This function returns the value of member my_bool - * @return Value of member my_bool - */ - eProsima_user_DllExport uint8_t my_bool() const; - - /*! - * @brief This function returns a reference to member my_bool - * @return Reference to member my_bool - */ - eProsima_user_DllExport uint8_t& my_bool(); - - - /*! - * @brief This function sets a value in member my_int32 - * @param _my_int32 New value for member my_int32 - */ - eProsima_user_DllExport void my_int32( - int32_t _my_int32); - - /*! - * @brief This function returns the value of member my_int32 - * @return Value of member my_int32 - */ - eProsima_user_DllExport int32_t my_int32() const; - - /*! - * @brief This function returns a reference to member my_int32 - * @return Reference to member my_int32 - */ - eProsima_user_DllExport int32_t& my_int32(); - - - /*! - * @brief This function copies the value in member my_string - * @param _my_string New value to be copied in member my_string - */ - eProsima_user_DllExport void my_string( - const std::string& _my_string); - - /*! - * @brief This function moves the value in member my_string - * @param _my_string New value to be moved in member my_string - */ - eProsima_user_DllExport void my_string( - std::string&& _my_string); - - /*! - * @brief This function returns a constant reference to member my_string - * @return Constant reference to member my_string - */ - eProsima_user_DllExport const std::string& my_string() const; - - /*! - * @brief This function returns a reference to member my_string - * @return Reference to member my_string - */ - eProsima_user_DllExport std::string& my_string(); - -private: - - uint8_t m_my_bool{0}; - int32_t m_my_int32{0}; - std::string m_my_string; - -}; - - -/*! - * @brief This class represents the structure BasicWideStruct defined by the user in the IDL file. - * @ingroup Types - */ -class BasicWideStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport BasicWideStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~BasicWideStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object BasicWideStruct that will be copied. - */ - eProsima_user_DllExport BasicWideStruct( - const BasicWideStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object BasicWideStruct that will be copied. - */ - eProsima_user_DllExport BasicWideStruct( - BasicWideStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object BasicWideStruct that will be copied. - */ - eProsima_user_DllExport BasicWideStruct& operator =( - const BasicWideStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object BasicWideStruct that will be copied. - */ - eProsima_user_DllExport BasicWideStruct& operator =( - BasicWideStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x BasicWideStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const BasicWideStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x BasicWideStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const BasicWideStruct& x) const; - - /*! - * @brief This function sets a value in member my_bool - * @param _my_bool New value for member my_bool - */ - eProsima_user_DllExport void my_bool( - bool _my_bool); - - /*! - * @brief This function returns the value of member my_bool - * @return Value of member my_bool - */ - eProsima_user_DllExport bool my_bool() const; - - /*! - * @brief This function returns a reference to member my_bool - * @return Reference to member my_bool - */ - eProsima_user_DllExport bool& my_bool(); - - - /*! - * @brief This function sets a value in member my_int32 - * @param _my_int32 New value for member my_int32 - */ - eProsima_user_DllExport void my_int32( - int32_t _my_int32); - - /*! - * @brief This function returns the value of member my_int32 - * @return Value of member my_int32 - */ - eProsima_user_DllExport int32_t my_int32() const; - - /*! - * @brief This function returns a reference to member my_int32 - * @return Reference to member my_int32 - */ - eProsima_user_DllExport int32_t& my_int32(); - - - /*! - * @brief This function copies the value in member my_string - * @param _my_string New value to be copied in member my_string - */ - eProsima_user_DllExport void my_string( - const std::string& _my_string); - - /*! - * @brief This function moves the value in member my_string - * @param _my_string New value to be moved in member my_string - */ - eProsima_user_DllExport void my_string( - std::string&& _my_string); - - /*! - * @brief This function returns a constant reference to member my_string - * @return Constant reference to member my_string - */ - eProsima_user_DllExport const std::string& my_string() const; - - /*! - * @brief This function returns a reference to member my_string - * @return Reference to member my_string - */ - eProsima_user_DllExport std::string& my_string(); - - - /*! - * @brief This function sets a value in member new_int32 - * @param _new_int32 New value for member new_int32 - */ - eProsima_user_DllExport void new_int32( - int32_t _new_int32); - - /*! - * @brief This function returns the value of member new_int32 - * @return Value of member new_int32 - */ - eProsima_user_DllExport int32_t new_int32() const; - - /*! - * @brief This function returns a reference to member new_int32 - * @return Reference to member new_int32 - */ - eProsima_user_DllExport int32_t& new_int32(); - - - /*! - * @brief This function copies the value in member new_string - * @param _new_string New value to be copied in member new_string - */ - eProsima_user_DllExport void new_string( - const std::string& _new_string); - - /*! - * @brief This function moves the value in member new_string - * @param _new_string New value to be moved in member new_string - */ - eProsima_user_DllExport void new_string( - std::string&& _new_string); - - /*! - * @brief This function returns a constant reference to member new_string - * @return Constant reference to member new_string - */ - eProsima_user_DllExport const std::string& new_string() const; - - /*! - * @brief This function returns a reference to member new_string - * @return Reference to member new_string - */ - eProsima_user_DllExport std::string& new_string(); - -private: - - bool m_my_bool{false}; - int32_t m_my_int32{0}; - std::string m_my_string; - int32_t m_new_int32{0}; - std::string m_new_string; - -}; - - -/*! - * @brief This class represents the structure BadBasicWideStruct defined by the user in the IDL file. - * @ingroup Types - */ -class BadBasicWideStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport BadBasicWideStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~BadBasicWideStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object BadBasicWideStruct that will be copied. - */ - eProsima_user_DllExport BadBasicWideStruct( - const BadBasicWideStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object BadBasicWideStruct that will be copied. - */ - eProsima_user_DllExport BadBasicWideStruct( - BadBasicWideStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object BadBasicWideStruct that will be copied. - */ - eProsima_user_DllExport BadBasicWideStruct& operator =( - const BadBasicWideStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object BadBasicWideStruct that will be copied. - */ - eProsima_user_DllExport BadBasicWideStruct& operator =( - BadBasicWideStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x BadBasicWideStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const BadBasicWideStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x BadBasicWideStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const BadBasicWideStruct& x) const; - - /*! - * @brief This function sets a value in member new_int32 - * @param _new_int32 New value for member new_int32 - */ - eProsima_user_DllExport void new_int32( - int32_t _new_int32); - - /*! - * @brief This function returns the value of member new_int32 - * @return Value of member new_int32 - */ - eProsima_user_DllExport int32_t new_int32() const; - - /*! - * @brief This function returns a reference to member new_int32 - * @return Reference to member new_int32 - */ - eProsima_user_DllExport int32_t& new_int32(); - - - /*! - * @brief This function copies the value in member new_string - * @param _new_string New value to be copied in member new_string - */ - eProsima_user_DllExport void new_string( - const std::string& _new_string); - - /*! - * @brief This function moves the value in member new_string - * @param _new_string New value to be moved in member new_string - */ - eProsima_user_DllExport void new_string( - std::string&& _new_string); - - /*! - * @brief This function returns a constant reference to member new_string - * @return Constant reference to member new_string - */ - eProsima_user_DllExport const std::string& new_string() const; - - /*! - * @brief This function returns a reference to member new_string - * @return Reference to member new_string - */ - eProsima_user_DllExport std::string& new_string(); - - - /*! - * @brief This function sets a value in member my_bool - * @param _my_bool New value for member my_bool - */ - eProsima_user_DllExport void my_bool( - bool _my_bool); - - /*! - * @brief This function returns the value of member my_bool - * @return Value of member my_bool - */ - eProsima_user_DllExport bool my_bool() const; - - /*! - * @brief This function returns a reference to member my_bool - * @return Reference to member my_bool - */ - eProsima_user_DllExport bool& my_bool(); - - - /*! - * @brief This function sets a value in member my_int32 - * @param _my_int32 New value for member my_int32 - */ - eProsima_user_DllExport void my_int32( - int32_t _my_int32); - - /*! - * @brief This function returns the value of member my_int32 - * @return Value of member my_int32 - */ - eProsima_user_DllExport int32_t my_int32() const; - - /*! - * @brief This function returns a reference to member my_int32 - * @return Reference to member my_int32 - */ - eProsima_user_DllExport int32_t& my_int32(); - - - /*! - * @brief This function copies the value in member my_string - * @param _my_string New value to be copied in member my_string - */ - eProsima_user_DllExport void my_string( - const std::string& _my_string); - - /*! - * @brief This function moves the value in member my_string - * @param _my_string New value to be moved in member my_string - */ - eProsima_user_DllExport void my_string( - std::string&& _my_string); - - /*! - * @brief This function returns a constant reference to member my_string - * @return Constant reference to member my_string - */ - eProsima_user_DllExport const std::string& my_string() const; - - /*! - * @brief This function returns a reference to member my_string - * @return Reference to member my_string - */ - eProsima_user_DllExport std::string& my_string(); - -private: - - int32_t m_new_int32{0}; - std::string m_new_string; - bool m_my_bool{false}; - int32_t m_my_int32{0}; - std::string m_my_string; - -}; - - -/*! - * @brief This class represents the structure StringStruct defined by the user in the IDL file. - * @ingroup Types - */ -class StringStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport StringStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~StringStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object StringStruct that will be copied. - */ - eProsima_user_DllExport StringStruct( - const StringStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object StringStruct that will be copied. - */ - eProsima_user_DllExport StringStruct( - StringStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object StringStruct that will be copied. - */ - eProsima_user_DllExport StringStruct& operator =( - const StringStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object StringStruct that will be copied. - */ - eProsima_user_DllExport StringStruct& operator =( - StringStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x StringStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const StringStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x StringStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const StringStruct& x) const; - - /*! - * @brief This function copies the value in member my_string - * @param _my_string New value to be copied in member my_string - */ - eProsima_user_DllExport void my_string( - const std::string& _my_string); - - /*! - * @brief This function moves the value in member my_string - * @param _my_string New value to be moved in member my_string - */ - eProsima_user_DllExport void my_string( - std::string&& _my_string); - - /*! - * @brief This function returns a constant reference to member my_string - * @return Constant reference to member my_string - */ - eProsima_user_DllExport const std::string& my_string() const; - - /*! - * @brief This function returns a reference to member my_string - * @return Reference to member my_string - */ - eProsima_user_DllExport std::string& my_string(); - -private: - - std::string m_my_string; - -}; - - -/*! - * @brief This class represents the structure LargeStringStruct defined by the user in the IDL file. - * @ingroup Types - */ -class LargeStringStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport LargeStringStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~LargeStringStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object LargeStringStruct that will be copied. - */ - eProsima_user_DllExport LargeStringStruct( - const LargeStringStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object LargeStringStruct that will be copied. - */ - eProsima_user_DllExport LargeStringStruct( - LargeStringStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object LargeStringStruct that will be copied. - */ - eProsima_user_DllExport LargeStringStruct& operator =( - const LargeStringStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object LargeStringStruct that will be copied. - */ - eProsima_user_DllExport LargeStringStruct& operator =( - LargeStringStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x LargeStringStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const LargeStringStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x LargeStringStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const LargeStringStruct& x) const; - - /*! - * @brief This function copies the value in member my_large_string - * @param _my_large_string New value to be copied in member my_large_string - */ - eProsima_user_DllExport void my_large_string( - const eprosima::fastcdr::fixed_string<41925>& _my_large_string); - - /*! - * @brief This function moves the value in member my_large_string - * @param _my_large_string New value to be moved in member my_large_string - */ - eProsima_user_DllExport void my_large_string( - eprosima::fastcdr::fixed_string<41925>&& _my_large_string); - - /*! - * @brief This function returns a constant reference to member my_large_string - * @return Constant reference to member my_large_string - */ - eProsima_user_DllExport const eprosima::fastcdr::fixed_string<41925>& my_large_string() const; - - /*! - * @brief This function returns a reference to member my_large_string - * @return Reference to member my_large_string - */ - eProsima_user_DllExport eprosima::fastcdr::fixed_string<41925>& my_large_string(); - -private: - - eprosima::fastcdr::fixed_string<41925> m_my_large_string; - -}; - - -/*! - * @brief This class represents the structure WStringStruct defined by the user in the IDL file. - * @ingroup Types - */ -class WStringStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport WStringStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~WStringStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object WStringStruct that will be copied. - */ - eProsima_user_DllExport WStringStruct( - const WStringStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object WStringStruct that will be copied. - */ - eProsima_user_DllExport WStringStruct( - WStringStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object WStringStruct that will be copied. - */ - eProsima_user_DllExport WStringStruct& operator =( - const WStringStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object WStringStruct that will be copied. - */ - eProsima_user_DllExport WStringStruct& operator =( - WStringStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x WStringStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const WStringStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x WStringStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const WStringStruct& x) const; - - /*! - * @brief This function copies the value in member my_wstring - * @param _my_wstring New value to be copied in member my_wstring - */ - eProsima_user_DllExport void my_wstring( - const std::wstring& _my_wstring); - - /*! - * @brief This function moves the value in member my_wstring - * @param _my_wstring New value to be moved in member my_wstring - */ - eProsima_user_DllExport void my_wstring( - std::wstring&& _my_wstring); - - /*! - * @brief This function returns a constant reference to member my_wstring - * @return Constant reference to member my_wstring - */ - eProsima_user_DllExport const std::wstring& my_wstring() const; - - /*! - * @brief This function returns a reference to member my_wstring - * @return Reference to member my_wstring - */ - eProsima_user_DllExport std::wstring& my_wstring(); - -private: - - std::wstring m_my_wstring; - -}; - - -/*! - * @brief This class represents the structure LargeWStringStruct defined by the user in the IDL file. - * @ingroup Types - */ -class LargeWStringStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport LargeWStringStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~LargeWStringStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object LargeWStringStruct that will be copied. - */ - eProsima_user_DllExport LargeWStringStruct( - const LargeWStringStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object LargeWStringStruct that will be copied. - */ - eProsima_user_DllExport LargeWStringStruct( - LargeWStringStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object LargeWStringStruct that will be copied. - */ - eProsima_user_DllExport LargeWStringStruct& operator =( - const LargeWStringStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object LargeWStringStruct that will be copied. - */ - eProsima_user_DllExport LargeWStringStruct& operator =( - LargeWStringStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x LargeWStringStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const LargeWStringStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x LargeWStringStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const LargeWStringStruct& x) const; - - /*! - * @brief This function copies the value in member my_large_wstring - * @param _my_large_wstring New value to be copied in member my_large_wstring - */ - eProsima_user_DllExport void my_large_wstring( - const std::wstring& _my_large_wstring); - - /*! - * @brief This function moves the value in member my_large_wstring - * @param _my_large_wstring New value to be moved in member my_large_wstring - */ - eProsima_user_DllExport void my_large_wstring( - std::wstring&& _my_large_wstring); - - /*! - * @brief This function returns a constant reference to member my_large_wstring - * @return Constant reference to member my_large_wstring - */ - eProsima_user_DllExport const std::wstring& my_large_wstring() const; - - /*! - * @brief This function returns a reference to member my_large_wstring - * @return Reference to member my_large_wstring - */ - eProsima_user_DllExport std::wstring& my_large_wstring(); - -private: - - std::wstring m_my_large_wstring; - -}; - - -/*! - * @brief This class represents the structure ArrayStruct defined by the user in the IDL file. - * @ingroup Types - */ -class ArrayStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport ArrayStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~ArrayStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object ArrayStruct that will be copied. - */ - eProsima_user_DllExport ArrayStruct( - const ArrayStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object ArrayStruct that will be copied. - */ - eProsima_user_DllExport ArrayStruct( - ArrayStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object ArrayStruct that will be copied. - */ - eProsima_user_DllExport ArrayStruct& operator =( - const ArrayStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object ArrayStruct that will be copied. - */ - eProsima_user_DllExport ArrayStruct& operator =( - ArrayStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x ArrayStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const ArrayStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x ArrayStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const ArrayStruct& x) const; - - /*! - * @brief This function copies the value in member my_array - * @param _my_array New value to be copied in member my_array - */ - eProsima_user_DllExport void my_array( - const std::array& _my_array); - - /*! - * @brief This function moves the value in member my_array - * @param _my_array New value to be moved in member my_array - */ - eProsima_user_DllExport void my_array( - std::array&& _my_array); - - /*! - * @brief This function returns a constant reference to member my_array - * @return Constant reference to member my_array - */ - eProsima_user_DllExport const std::array& my_array() const; - - /*! - * @brief This function returns a reference to member my_array - * @return Reference to member my_array - */ - eProsima_user_DllExport std::array& my_array(); - -private: - - std::array m_my_array{0}; - -}; - - -/*! - * @brief This class represents the structure ArrayStructEqual defined by the user in the IDL file. - * @ingroup Types - */ -class ArrayStructEqual -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport ArrayStructEqual(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~ArrayStructEqual(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object ArrayStructEqual that will be copied. - */ - eProsima_user_DllExport ArrayStructEqual( - const ArrayStructEqual& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object ArrayStructEqual that will be copied. - */ - eProsima_user_DllExport ArrayStructEqual( - ArrayStructEqual&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object ArrayStructEqual that will be copied. - */ - eProsima_user_DllExport ArrayStructEqual& operator =( - const ArrayStructEqual& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object ArrayStructEqual that will be copied. - */ - eProsima_user_DllExport ArrayStructEqual& operator =( - ArrayStructEqual&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x ArrayStructEqual object to compare. - */ - eProsima_user_DllExport bool operator ==( - const ArrayStructEqual& x) const; - - /*! - * @brief Comparison operator. - * @param x ArrayStructEqual object to compare. - */ - eProsima_user_DllExport bool operator !=( - const ArrayStructEqual& x) const; - - /*! - * @brief This function copies the value in member my_array_equal - * @param _my_array_equal New value to be copied in member my_array_equal - */ - eProsima_user_DllExport void my_array_equal( - const std::array& _my_array_equal); - - /*! - * @brief This function moves the value in member my_array_equal - * @param _my_array_equal New value to be moved in member my_array_equal - */ - eProsima_user_DllExport void my_array_equal( - std::array&& _my_array_equal); - - /*! - * @brief This function returns a constant reference to member my_array_equal - * @return Constant reference to member my_array_equal - */ - eProsima_user_DllExport const std::array& my_array_equal() const; - - /*! - * @brief This function returns a reference to member my_array_equal - * @return Reference to member my_array_equal - */ - eProsima_user_DllExport std::array& my_array_equal(); - -private: - - std::array m_my_array_equal{0}; - -}; - - -/*! - * @brief This class represents the structure ArrayBadStruct defined by the user in the IDL file. - * @ingroup Types - */ -class ArrayBadStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport ArrayBadStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~ArrayBadStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object ArrayBadStruct that will be copied. - */ - eProsima_user_DllExport ArrayBadStruct( - const ArrayBadStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object ArrayBadStruct that will be copied. - */ - eProsima_user_DllExport ArrayBadStruct( - ArrayBadStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object ArrayBadStruct that will be copied. - */ - eProsima_user_DllExport ArrayBadStruct& operator =( - const ArrayBadStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object ArrayBadStruct that will be copied. - */ - eProsima_user_DllExport ArrayBadStruct& operator =( - ArrayBadStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x ArrayBadStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const ArrayBadStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x ArrayBadStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const ArrayBadStruct& x) const; - - /*! - * @brief This function copies the value in member my_array - * @param _my_array New value to be copied in member my_array - */ - eProsima_user_DllExport void my_array( - const std::array& _my_array); - - /*! - * @brief This function moves the value in member my_array - * @param _my_array New value to be moved in member my_array - */ - eProsima_user_DllExport void my_array( - std::array&& _my_array); - - /*! - * @brief This function returns a constant reference to member my_array - * @return Constant reference to member my_array - */ - eProsima_user_DllExport const std::array& my_array() const; - - /*! - * @brief This function returns a reference to member my_array - * @return Reference to member my_array - */ - eProsima_user_DllExport std::array& my_array(); - -private: - - std::array m_my_array{0}; - -}; - - -/*! - * @brief This class represents the structure ArrayDimensionsStruct defined by the user in the IDL file. - * @ingroup Types - */ -class ArrayDimensionsStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport ArrayDimensionsStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~ArrayDimensionsStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object ArrayDimensionsStruct that will be copied. - */ - eProsima_user_DllExport ArrayDimensionsStruct( - const ArrayDimensionsStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object ArrayDimensionsStruct that will be copied. - */ - eProsima_user_DllExport ArrayDimensionsStruct( - ArrayDimensionsStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object ArrayDimensionsStruct that will be copied. - */ - eProsima_user_DllExport ArrayDimensionsStruct& operator =( - const ArrayDimensionsStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object ArrayDimensionsStruct that will be copied. - */ - eProsima_user_DllExport ArrayDimensionsStruct& operator =( - ArrayDimensionsStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x ArrayDimensionsStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const ArrayDimensionsStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x ArrayDimensionsStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const ArrayDimensionsStruct& x) const; - - /*! - * @brief This function copies the value in member my_array - * @param _my_array New value to be copied in member my_array - */ - eProsima_user_DllExport void my_array( - const std::array, 2>& _my_array); - - /*! - * @brief This function moves the value in member my_array - * @param _my_array New value to be moved in member my_array - */ - eProsima_user_DllExport void my_array( - std::array, 2>&& _my_array); - - /*! - * @brief This function returns a constant reference to member my_array - * @return Constant reference to member my_array - */ - eProsima_user_DllExport const std::array, 2>& my_array() const; - - /*! - * @brief This function returns a reference to member my_array - * @return Reference to member my_array - */ - eProsima_user_DllExport std::array, 2>& my_array(); - -private: - - std::array, 2> m_my_array{ {{0}} }; - -}; - - -/*! - * @brief This class represents the structure ArraySizeStruct defined by the user in the IDL file. - * @ingroup Types - */ -class ArraySizeStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport ArraySizeStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~ArraySizeStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object ArraySizeStruct that will be copied. - */ - eProsima_user_DllExport ArraySizeStruct( - const ArraySizeStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object ArraySizeStruct that will be copied. - */ - eProsima_user_DllExport ArraySizeStruct( - ArraySizeStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object ArraySizeStruct that will be copied. - */ - eProsima_user_DllExport ArraySizeStruct& operator =( - const ArraySizeStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object ArraySizeStruct that will be copied. - */ - eProsima_user_DllExport ArraySizeStruct& operator =( - ArraySizeStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x ArraySizeStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const ArraySizeStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x ArraySizeStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const ArraySizeStruct& x) const; - - /*! - * @brief This function copies the value in member my_array - * @param _my_array New value to be copied in member my_array - */ - eProsima_user_DllExport void my_array( - const std::array& _my_array); - - /*! - * @brief This function moves the value in member my_array - * @param _my_array New value to be moved in member my_array - */ - eProsima_user_DllExport void my_array( - std::array&& _my_array); - - /*! - * @brief This function returns a constant reference to member my_array - * @return Constant reference to member my_array - */ - eProsima_user_DllExport const std::array& my_array() const; - - /*! - * @brief This function returns a reference to member my_array - * @return Reference to member my_array - */ - eProsima_user_DllExport std::array& my_array(); - -private: - - std::array m_my_array{0}; - -}; - - - - -/*! - * @brief This class represents the structure SequenceStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SequenceStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SequenceStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SequenceStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SequenceStruct that will be copied. - */ - eProsima_user_DllExport SequenceStruct( - const SequenceStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SequenceStruct that will be copied. - */ - eProsima_user_DllExport SequenceStruct( - SequenceStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SequenceStruct that will be copied. - */ - eProsima_user_DllExport SequenceStruct& operator =( - const SequenceStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SequenceStruct that will be copied. - */ - eProsima_user_DllExport SequenceStruct& operator =( - SequenceStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SequenceStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SequenceStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x SequenceStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SequenceStruct& x) const; - - /*! - * @brief This function copies the value in member my_sequence - * @param _my_sequence New value to be copied in member my_sequence - */ - eProsima_user_DllExport void my_sequence( - const std::vector& _my_sequence); - - /*! - * @brief This function moves the value in member my_sequence - * @param _my_sequence New value to be moved in member my_sequence - */ - eProsima_user_DllExport void my_sequence( - std::vector&& _my_sequence); - - /*! - * @brief This function returns a constant reference to member my_sequence - * @return Constant reference to member my_sequence - */ - eProsima_user_DllExport const std::vector& my_sequence() const; - - /*! - * @brief This function returns a reference to member my_sequence - * @return Reference to member my_sequence - */ - eProsima_user_DllExport std::vector& my_sequence(); - -private: - - std::vector m_my_sequence; - -}; - - - - -/*! - * @brief This class represents the structure SequenceStructEqual defined by the user in the IDL file. - * @ingroup Types - */ -class SequenceStructEqual -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SequenceStructEqual(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SequenceStructEqual(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SequenceStructEqual that will be copied. - */ - eProsima_user_DllExport SequenceStructEqual( - const SequenceStructEqual& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SequenceStructEqual that will be copied. - */ - eProsima_user_DllExport SequenceStructEqual( - SequenceStructEqual&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SequenceStructEqual that will be copied. - */ - eProsima_user_DllExport SequenceStructEqual& operator =( - const SequenceStructEqual& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SequenceStructEqual that will be copied. - */ - eProsima_user_DllExport SequenceStructEqual& operator =( - SequenceStructEqual&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SequenceStructEqual object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SequenceStructEqual& x) const; - - /*! - * @brief Comparison operator. - * @param x SequenceStructEqual object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SequenceStructEqual& x) const; - - /*! - * @brief This function copies the value in member my_sequence_equal - * @param _my_sequence_equal New value to be copied in member my_sequence_equal - */ - eProsima_user_DllExport void my_sequence_equal( - const std::vector& _my_sequence_equal); - - /*! - * @brief This function moves the value in member my_sequence_equal - * @param _my_sequence_equal New value to be moved in member my_sequence_equal - */ - eProsima_user_DllExport void my_sequence_equal( - std::vector&& _my_sequence_equal); - - /*! - * @brief This function returns a constant reference to member my_sequence_equal - * @return Constant reference to member my_sequence_equal - */ - eProsima_user_DllExport const std::vector& my_sequence_equal() const; - - /*! - * @brief This function returns a reference to member my_sequence_equal - * @return Reference to member my_sequence_equal - */ - eProsima_user_DllExport std::vector& my_sequence_equal(); - -private: - - std::vector m_my_sequence_equal; - -}; - - - - -/*! - * @brief This class represents the structure SequenceBadStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SequenceBadStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SequenceBadStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SequenceBadStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SequenceBadStruct that will be copied. - */ - eProsima_user_DllExport SequenceBadStruct( - const SequenceBadStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SequenceBadStruct that will be copied. - */ - eProsima_user_DllExport SequenceBadStruct( - SequenceBadStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SequenceBadStruct that will be copied. - */ - eProsima_user_DllExport SequenceBadStruct& operator =( - const SequenceBadStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SequenceBadStruct that will be copied. - */ - eProsima_user_DllExport SequenceBadStruct& operator =( - SequenceBadStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SequenceBadStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SequenceBadStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x SequenceBadStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SequenceBadStruct& x) const; - - /*! - * @brief This function copies the value in member my_sequence - * @param _my_sequence New value to be copied in member my_sequence - */ - eProsima_user_DllExport void my_sequence( - const std::vector& _my_sequence); - - /*! - * @brief This function moves the value in member my_sequence - * @param _my_sequence New value to be moved in member my_sequence - */ - eProsima_user_DllExport void my_sequence( - std::vector&& _my_sequence); - - /*! - * @brief This function returns a constant reference to member my_sequence - * @return Constant reference to member my_sequence - */ - eProsima_user_DllExport const std::vector& my_sequence() const; - - /*! - * @brief This function returns a reference to member my_sequence - * @return Reference to member my_sequence - */ - eProsima_user_DllExport std::vector& my_sequence(); - -private: - - std::vector m_my_sequence; - -}; - - - - -/*! - * @brief This class represents the structure SequenceBoundsStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SequenceBoundsStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SequenceBoundsStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SequenceBoundsStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SequenceBoundsStruct that will be copied. - */ - eProsima_user_DllExport SequenceBoundsStruct( - const SequenceBoundsStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SequenceBoundsStruct that will be copied. - */ - eProsima_user_DllExport SequenceBoundsStruct( - SequenceBoundsStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SequenceBoundsStruct that will be copied. - */ - eProsima_user_DllExport SequenceBoundsStruct& operator =( - const SequenceBoundsStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SequenceBoundsStruct that will be copied. - */ - eProsima_user_DllExport SequenceBoundsStruct& operator =( - SequenceBoundsStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SequenceBoundsStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SequenceBoundsStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x SequenceBoundsStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SequenceBoundsStruct& x) const; - - /*! - * @brief This function copies the value in member my_sequence - * @param _my_sequence New value to be copied in member my_sequence - */ - eProsima_user_DllExport void my_sequence( - const std::vector& _my_sequence); - - /*! - * @brief This function moves the value in member my_sequence - * @param _my_sequence New value to be moved in member my_sequence - */ - eProsima_user_DllExport void my_sequence( - std::vector&& _my_sequence); - - /*! - * @brief This function returns a constant reference to member my_sequence - * @return Constant reference to member my_sequence - */ - eProsima_user_DllExport const std::vector& my_sequence() const; - - /*! - * @brief This function returns a reference to member my_sequence - * @return Reference to member my_sequence - */ - eProsima_user_DllExport std::vector& my_sequence(); - -private: - - std::vector m_my_sequence; - -}; - - - - - - -/*! - * @brief This class represents the structure SequenceSequenceStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SequenceSequenceStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SequenceSequenceStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SequenceSequenceStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SequenceSequenceStruct that will be copied. - */ - eProsima_user_DllExport SequenceSequenceStruct( - const SequenceSequenceStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SequenceSequenceStruct that will be copied. - */ - eProsima_user_DllExport SequenceSequenceStruct( - SequenceSequenceStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SequenceSequenceStruct that will be copied. - */ - eProsima_user_DllExport SequenceSequenceStruct& operator =( - const SequenceSequenceStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SequenceSequenceStruct that will be copied. - */ - eProsima_user_DllExport SequenceSequenceStruct& operator =( - SequenceSequenceStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SequenceSequenceStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SequenceSequenceStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x SequenceSequenceStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SequenceSequenceStruct& x) const; - - /*! - * @brief This function copies the value in member my_sequence_sequence - * @param _my_sequence_sequence New value to be copied in member my_sequence_sequence - */ - eProsima_user_DllExport void my_sequence_sequence( - const std::vector>& _my_sequence_sequence); - - /*! - * @brief This function moves the value in member my_sequence_sequence - * @param _my_sequence_sequence New value to be moved in member my_sequence_sequence - */ - eProsima_user_DllExport void my_sequence_sequence( - std::vector>&& _my_sequence_sequence); - - /*! - * @brief This function returns a constant reference to member my_sequence_sequence - * @return Constant reference to member my_sequence_sequence - */ - eProsima_user_DllExport const std::vector>& my_sequence_sequence() const; - - /*! - * @brief This function returns a reference to member my_sequence_sequence - * @return Reference to member my_sequence_sequence - */ - eProsima_user_DllExport std::vector>& my_sequence_sequence(); - -private: - - std::vector> m_my_sequence_sequence; - -}; - - - - - - -/*! - * @brief This class represents the structure SequenceSequenceBoundsStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SequenceSequenceBoundsStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SequenceSequenceBoundsStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SequenceSequenceBoundsStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SequenceSequenceBoundsStruct that will be copied. - */ - eProsima_user_DllExport SequenceSequenceBoundsStruct( - const SequenceSequenceBoundsStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SequenceSequenceBoundsStruct that will be copied. - */ - eProsima_user_DllExport SequenceSequenceBoundsStruct( - SequenceSequenceBoundsStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SequenceSequenceBoundsStruct that will be copied. - */ - eProsima_user_DllExport SequenceSequenceBoundsStruct& operator =( - const SequenceSequenceBoundsStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SequenceSequenceBoundsStruct that will be copied. - */ - eProsima_user_DllExport SequenceSequenceBoundsStruct& operator =( - SequenceSequenceBoundsStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SequenceSequenceBoundsStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SequenceSequenceBoundsStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x SequenceSequenceBoundsStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SequenceSequenceBoundsStruct& x) const; - - /*! - * @brief This function copies the value in member my_sequence_sequence - * @param _my_sequence_sequence New value to be copied in member my_sequence_sequence - */ - eProsima_user_DllExport void my_sequence_sequence( - const std::vector>& _my_sequence_sequence); - - /*! - * @brief This function moves the value in member my_sequence_sequence - * @param _my_sequence_sequence New value to be moved in member my_sequence_sequence - */ - eProsima_user_DllExport void my_sequence_sequence( - std::vector>&& _my_sequence_sequence); - - /*! - * @brief This function returns a constant reference to member my_sequence_sequence - * @return Constant reference to member my_sequence_sequence - */ - eProsima_user_DllExport const std::vector>& my_sequence_sequence() const; - - /*! - * @brief This function returns a reference to member my_sequence_sequence - * @return Reference to member my_sequence_sequence - */ - eProsima_user_DllExport std::vector>& my_sequence_sequence(); - -private: - - std::vector> m_my_sequence_sequence; - -}; - - - - -/*! - * @brief This class represents the structure MapStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MapStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MapStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MapStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MapStruct that will be copied. - */ - eProsima_user_DllExport MapStruct( - const MapStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MapStruct that will be copied. - */ - eProsima_user_DllExport MapStruct( - MapStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MapStruct that will be copied. - */ - eProsima_user_DllExport MapStruct& operator =( - const MapStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MapStruct that will be copied. - */ - eProsima_user_DllExport MapStruct& operator =( - MapStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MapStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MapStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x MapStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MapStruct& x) const; - - /*! - * @brief This function copies the value in member my_map - * @param _my_map New value to be copied in member my_map - */ - eProsima_user_DllExport void my_map( - const std::map& _my_map); - - /*! - * @brief This function moves the value in member my_map - * @param _my_map New value to be moved in member my_map - */ - eProsima_user_DllExport void my_map( - std::map&& _my_map); - - /*! - * @brief This function returns a constant reference to member my_map - * @return Constant reference to member my_map - */ - eProsima_user_DllExport const std::map& my_map() const; - - /*! - * @brief This function returns a reference to member my_map - * @return Reference to member my_map - */ - eProsima_user_DllExport std::map& my_map(); - -private: - - std::map m_my_map; - -}; - - - - -/*! - * @brief This class represents the structure MapStructEqual defined by the user in the IDL file. - * @ingroup Types - */ -class MapStructEqual -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MapStructEqual(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MapStructEqual(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MapStructEqual that will be copied. - */ - eProsima_user_DllExport MapStructEqual( - const MapStructEqual& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MapStructEqual that will be copied. - */ - eProsima_user_DllExport MapStructEqual( - MapStructEqual&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MapStructEqual that will be copied. - */ - eProsima_user_DllExport MapStructEqual& operator =( - const MapStructEqual& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MapStructEqual that will be copied. - */ - eProsima_user_DllExport MapStructEqual& operator =( - MapStructEqual&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MapStructEqual object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MapStructEqual& x) const; - - /*! - * @brief Comparison operator. - * @param x MapStructEqual object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MapStructEqual& x) const; - - /*! - * @brief This function copies the value in member my_map_equal - * @param _my_map_equal New value to be copied in member my_map_equal - */ - eProsima_user_DllExport void my_map_equal( - const std::map& _my_map_equal); - - /*! - * @brief This function moves the value in member my_map_equal - * @param _my_map_equal New value to be moved in member my_map_equal - */ - eProsima_user_DllExport void my_map_equal( - std::map&& _my_map_equal); - - /*! - * @brief This function returns a constant reference to member my_map_equal - * @return Constant reference to member my_map_equal - */ - eProsima_user_DllExport const std::map& my_map_equal() const; - - /*! - * @brief This function returns a reference to member my_map_equal - * @return Reference to member my_map_equal - */ - eProsima_user_DllExport std::map& my_map_equal(); - -private: - - std::map m_my_map_equal; - -}; - - - - -/*! - * @brief This class represents the structure MapBadKeyStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MapBadKeyStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MapBadKeyStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MapBadKeyStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MapBadKeyStruct that will be copied. - */ - eProsima_user_DllExport MapBadKeyStruct( - const MapBadKeyStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MapBadKeyStruct that will be copied. - */ - eProsima_user_DllExport MapBadKeyStruct( - MapBadKeyStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MapBadKeyStruct that will be copied. - */ - eProsima_user_DllExport MapBadKeyStruct& operator =( - const MapBadKeyStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MapBadKeyStruct that will be copied. - */ - eProsima_user_DllExport MapBadKeyStruct& operator =( - MapBadKeyStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MapBadKeyStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MapBadKeyStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x MapBadKeyStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MapBadKeyStruct& x) const; - - /*! - * @brief This function copies the value in member my_map - * @param _my_map New value to be copied in member my_map - */ - eProsima_user_DllExport void my_map( - const std::map& _my_map); - - /*! - * @brief This function moves the value in member my_map - * @param _my_map New value to be moved in member my_map - */ - eProsima_user_DllExport void my_map( - std::map&& _my_map); - - /*! - * @brief This function returns a constant reference to member my_map - * @return Constant reference to member my_map - */ - eProsima_user_DllExport const std::map& my_map() const; - - /*! - * @brief This function returns a reference to member my_map - * @return Reference to member my_map - */ - eProsima_user_DllExport std::map& my_map(); - -private: - - std::map m_my_map; - -}; - - - - -/*! - * @brief This class represents the structure MapBadElemStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MapBadElemStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MapBadElemStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MapBadElemStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MapBadElemStruct that will be copied. - */ - eProsima_user_DllExport MapBadElemStruct( - const MapBadElemStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MapBadElemStruct that will be copied. - */ - eProsima_user_DllExport MapBadElemStruct( - MapBadElemStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MapBadElemStruct that will be copied. - */ - eProsima_user_DllExport MapBadElemStruct& operator =( - const MapBadElemStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MapBadElemStruct that will be copied. - */ - eProsima_user_DllExport MapBadElemStruct& operator =( - MapBadElemStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MapBadElemStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MapBadElemStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x MapBadElemStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MapBadElemStruct& x) const; - - /*! - * @brief This function copies the value in member my_map - * @param _my_map New value to be copied in member my_map - */ - eProsima_user_DllExport void my_map( - const std::map& _my_map); - - /*! - * @brief This function moves the value in member my_map - * @param _my_map New value to be moved in member my_map - */ - eProsima_user_DllExport void my_map( - std::map&& _my_map); - - /*! - * @brief This function returns a constant reference to member my_map - * @return Constant reference to member my_map - */ - eProsima_user_DllExport const std::map& my_map() const; - - /*! - * @brief This function returns a reference to member my_map - * @return Reference to member my_map - */ - eProsima_user_DllExport std::map& my_map(); - -private: - - std::map m_my_map; - -}; - - - - -/*! - * @brief This class represents the structure MapBoundsStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MapBoundsStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MapBoundsStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MapBoundsStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MapBoundsStruct that will be copied. - */ - eProsima_user_DllExport MapBoundsStruct( - const MapBoundsStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MapBoundsStruct that will be copied. - */ - eProsima_user_DllExport MapBoundsStruct( - MapBoundsStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MapBoundsStruct that will be copied. - */ - eProsima_user_DllExport MapBoundsStruct& operator =( - const MapBoundsStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MapBoundsStruct that will be copied. - */ - eProsima_user_DllExport MapBoundsStruct& operator =( - MapBoundsStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MapBoundsStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MapBoundsStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x MapBoundsStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MapBoundsStruct& x) const; - - /*! - * @brief This function copies the value in member my_map - * @param _my_map New value to be copied in member my_map - */ - eProsima_user_DllExport void my_map( - const std::map& _my_map); - - /*! - * @brief This function moves the value in member my_map - * @param _my_map New value to be moved in member my_map - */ - eProsima_user_DllExport void my_map( - std::map&& _my_map); - - /*! - * @brief This function returns a constant reference to member my_map - * @return Constant reference to member my_map - */ - eProsima_user_DllExport const std::map& my_map() const; - - /*! - * @brief This function returns a reference to member my_map - * @return Reference to member my_map - */ - eProsima_user_DllExport std::map& my_map(); - -private: - - std::map m_my_map; - -}; - - - - - - -/*! - * @brief This class represents the structure MapMapStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MapMapStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MapMapStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MapMapStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MapMapStruct that will be copied. - */ - eProsima_user_DllExport MapMapStruct( - const MapMapStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MapMapStruct that will be copied. - */ - eProsima_user_DllExport MapMapStruct( - MapMapStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MapMapStruct that will be copied. - */ - eProsima_user_DllExport MapMapStruct& operator =( - const MapMapStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MapMapStruct that will be copied. - */ - eProsima_user_DllExport MapMapStruct& operator =( - MapMapStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MapMapStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MapMapStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x MapMapStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MapMapStruct& x) const; - - /*! - * @brief This function copies the value in member my_map_map - * @param _my_map_map New value to be copied in member my_map_map - */ - eProsima_user_DllExport void my_map_map( - const std::map>& _my_map_map); - - /*! - * @brief This function moves the value in member my_map_map - * @param _my_map_map New value to be moved in member my_map_map - */ - eProsima_user_DllExport void my_map_map( - std::map>&& _my_map_map); - - /*! - * @brief This function returns a constant reference to member my_map_map - * @return Constant reference to member my_map_map - */ - eProsima_user_DllExport const std::map>& my_map_map() const; - - /*! - * @brief This function returns a reference to member my_map_map - * @return Reference to member my_map_map - */ - eProsima_user_DllExport std::map>& my_map_map(); - -private: - - std::map> m_my_map_map; - -}; - - - - - - -/*! - * @brief This class represents the structure MapMapBoundsStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MapMapBoundsStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MapMapBoundsStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MapMapBoundsStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MapMapBoundsStruct that will be copied. - */ - eProsima_user_DllExport MapMapBoundsStruct( - const MapMapBoundsStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MapMapBoundsStruct that will be copied. - */ - eProsima_user_DllExport MapMapBoundsStruct( - MapMapBoundsStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MapMapBoundsStruct that will be copied. - */ - eProsima_user_DllExport MapMapBoundsStruct& operator =( - const MapMapBoundsStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MapMapBoundsStruct that will be copied. - */ - eProsima_user_DllExport MapMapBoundsStruct& operator =( - MapMapBoundsStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MapMapBoundsStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MapMapBoundsStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x MapMapBoundsStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MapMapBoundsStruct& x) const; - - /*! - * @brief This function copies the value in member my_map_map - * @param _my_map_map New value to be copied in member my_map_map - */ - eProsima_user_DllExport void my_map_map( - const std::map>& _my_map_map); - - /*! - * @brief This function moves the value in member my_map_map - * @param _my_map_map New value to be moved in member my_map_map - */ - eProsima_user_DllExport void my_map_map( - std::map>&& _my_map_map); - - /*! - * @brief This function returns a constant reference to member my_map_map - * @return Constant reference to member my_map_map - */ - eProsima_user_DllExport const std::map>& my_map_map() const; - - /*! - * @brief This function returns a reference to member my_map_map - * @return Reference to member my_map_map - */ - eProsima_user_DllExport std::map>& my_map_map(); - -private: - - std::map> m_my_map_map; - -}; - - -/*! - * @brief This class represents the union SimpleUnion defined by the user in the IDL file. - * @ingroup Types - */ -class SimpleUnion -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimpleUnion(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimpleUnion(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimpleUnion that will be copied. - */ - eProsima_user_DllExport SimpleUnion( - const SimpleUnion& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimpleUnion that will be copied. - */ - eProsima_user_DllExport SimpleUnion( - SimpleUnion&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimpleUnion that will be copied. - */ - eProsima_user_DllExport SimpleUnion& operator =( - const SimpleUnion& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimpleUnion that will be copied. - */ - eProsima_user_DllExport SimpleUnion& operator =( - SimpleUnion&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimpleUnion object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimpleUnion& x) const; - - /*! - * @brief Comparison operator. - * @param x SimpleUnion object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimpleUnion& x) const; - - /*! - * @brief This function sets the discriminator value. - * @param __d New value for the discriminator. - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the new value doesn't correspond to the selected union member. - */ - eProsima_user_DllExport void _d( - int32_t __d); - - /*! - * @brief This function returns the value of the discriminator. - * @return Value of the discriminator - */ - eProsima_user_DllExport int32_t _d() const; - - /*! - * @brief This function returns a reference to the discriminator. - * @return Reference to the discriminator. - */ - eProsima_user_DllExport int32_t& _d(); - - /*! - * @brief This function sets a value in member first - * @param _first New value for member first - */ - eProsima_user_DllExport void first( - int32_t _first); - - /*! - * @brief This function returns the value of member first - * @return Value of member first - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t first() const; - - /*! - * @brief This function returns a reference to member first - * @return Reference to member first - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t& first(); - - - /*! - * @brief This function sets a value in member second - * @param _second New value for member second - */ - eProsima_user_DllExport void second( - int64_t _second); - - /*! - * @brief This function returns the value of member second - * @return Value of member second - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t second() const; - - /*! - * @brief This function returns a reference to member second - * @return Reference to member second - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t& second(); - -private: - - int32_t m__d; - - int32_t m_first{0}; - int64_t m_second{0}; -}; - - -/*! - * @brief This class represents the union SimpleUnionNames defined by the user in the IDL file. - * @ingroup Types - */ -class SimpleUnionNames -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimpleUnionNames(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimpleUnionNames(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimpleUnionNames that will be copied. - */ - eProsima_user_DllExport SimpleUnionNames( - const SimpleUnionNames& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimpleUnionNames that will be copied. - */ - eProsima_user_DllExport SimpleUnionNames( - SimpleUnionNames&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimpleUnionNames that will be copied. - */ - eProsima_user_DllExport SimpleUnionNames& operator =( - const SimpleUnionNames& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimpleUnionNames that will be copied. - */ - eProsima_user_DllExport SimpleUnionNames& operator =( - SimpleUnionNames&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimpleUnionNames object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimpleUnionNames& x) const; - - /*! - * @brief Comparison operator. - * @param x SimpleUnionNames object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimpleUnionNames& x) const; - - /*! - * @brief This function sets the discriminator value. - * @param __d New value for the discriminator. - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the new value doesn't correspond to the selected union member. - */ - eProsima_user_DllExport void _d( - int32_t __d); - - /*! - * @brief This function returns the value of the discriminator. - * @return Value of the discriminator - */ - eProsima_user_DllExport int32_t _d() const; - - /*! - * @brief This function returns a reference to the discriminator. - * @return Reference to the discriminator. - */ - eProsima_user_DllExport int32_t& _d(); - - /*! - * @brief This function sets a value in member first_case - * @param _first_case New value for member first_case - */ - eProsima_user_DllExport void first_case( - int32_t _first_case); - - /*! - * @brief This function returns the value of member first_case - * @return Value of member first_case - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t first_case() const; - - /*! - * @brief This function returns a reference to member first_case - * @return Reference to member first_case - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t& first_case(); - - - /*! - * @brief This function sets a value in member second_case - * @param _second_case New value for member second_case - */ - eProsima_user_DllExport void second_case( - int64_t _second_case); - - /*! - * @brief This function returns the value of member second_case - * @return Value of member second_case - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t second_case() const; - - /*! - * @brief This function returns a reference to member second_case - * @return Reference to member second_case - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t& second_case(); - -private: - - int32_t m__d; - - int32_t m_first_case{0}; - int64_t m_second_case{0}; -}; - - -/*! - * @brief This class represents the union SimpleTypeUnion defined by the user in the IDL file. - * @ingroup Types - */ -class SimpleTypeUnion -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimpleTypeUnion(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimpleTypeUnion(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimpleTypeUnion that will be copied. - */ - eProsima_user_DllExport SimpleTypeUnion( - const SimpleTypeUnion& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimpleTypeUnion that will be copied. - */ - eProsima_user_DllExport SimpleTypeUnion( - SimpleTypeUnion&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimpleTypeUnion that will be copied. - */ - eProsima_user_DllExport SimpleTypeUnion& operator =( - const SimpleTypeUnion& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimpleTypeUnion that will be copied. - */ - eProsima_user_DllExport SimpleTypeUnion& operator =( - SimpleTypeUnion&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimpleTypeUnion object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimpleTypeUnion& x) const; - - /*! - * @brief Comparison operator. - * @param x SimpleTypeUnion object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimpleTypeUnion& x) const; - - /*! - * @brief This function sets the discriminator value. - * @param __d New value for the discriminator. - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the new value doesn't correspond to the selected union member. - */ - eProsima_user_DllExport void _d( - int32_t __d); - - /*! - * @brief This function returns the value of the discriminator. - * @return Value of the discriminator - */ - eProsima_user_DllExport int32_t _d() const; - - /*! - * @brief This function returns a reference to the discriminator. - * @return Reference to the discriminator. - */ - eProsima_user_DllExport int32_t& _d(); - - /*! - * @brief This function sets a value in member first - * @param _first New value for member first - */ - eProsima_user_DllExport void first( - uint8_t _first); - - /*! - * @brief This function returns the value of member first - * @return Value of member first - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport uint8_t first() const; - - /*! - * @brief This function returns a reference to member first - * @return Reference to member first - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport uint8_t& first(); - - - /*! - * @brief This function sets a value in member second - * @param _second New value for member second - */ - eProsima_user_DllExport void second( - int64_t _second); - - /*! - * @brief This function returns the value of member second - * @return Value of member second - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t second() const; - - /*! - * @brief This function returns a reference to member second - * @return Reference to member second - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t& second(); - -private: - - int32_t m__d; - - uint8_t m_first{0}; - int64_t m_second{0}; -}; - - -/*! - * @brief This class represents the union SimpleBadUnion defined by the user in the IDL file. - * @ingroup Types - */ -class SimpleBadUnion -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimpleBadUnion(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimpleBadUnion(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimpleBadUnion that will be copied. - */ - eProsima_user_DllExport SimpleBadUnion( - const SimpleBadUnion& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimpleBadUnion that will be copied. - */ - eProsima_user_DllExport SimpleBadUnion( - SimpleBadUnion&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimpleBadUnion that will be copied. - */ - eProsima_user_DllExport SimpleBadUnion& operator =( - const SimpleBadUnion& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimpleBadUnion that will be copied. - */ - eProsima_user_DllExport SimpleBadUnion& operator =( - SimpleBadUnion&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimpleBadUnion object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimpleBadUnion& x) const; - - /*! - * @brief Comparison operator. - * @param x SimpleBadUnion object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimpleBadUnion& x) const; - - /*! - * @brief This function sets the discriminator value. - * @param __d New value for the discriminator. - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the new value doesn't correspond to the selected union member. - */ - eProsima_user_DllExport void _d( - int32_t __d); - - /*! - * @brief This function returns the value of the discriminator. - * @return Value of the discriminator - */ - eProsima_user_DllExport int32_t _d() const; - - /*! - * @brief This function returns a reference to the discriminator. - * @return Reference to the discriminator. - */ - eProsima_user_DllExport int32_t& _d(); - - /*! - * @brief This function sets a value in member first - * @param _first New value for member first - */ - eProsima_user_DllExport void first( - int32_t _first); - - /*! - * @brief This function returns the value of member first - * @return Value of member first - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t first() const; - - /*! - * @brief This function returns a reference to member first - * @return Reference to member first - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t& first(); - - - /*! - * @brief This function sets a value in member second - * @param _second New value for member second - */ - eProsima_user_DllExport void second( - int64_t _second); - - /*! - * @brief This function returns the value of member second - * @return Value of member second - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t second() const; - - /*! - * @brief This function returns a reference to member second - * @return Reference to member second - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t& second(); - -private: - - int32_t m__d; - - int32_t m_first{0}; - int64_t m_second{0}; -}; - - -/*! - * @brief This class represents the union SimpleBadDiscUnion defined by the user in the IDL file. - * @ingroup Types - */ -class SimpleBadDiscUnion -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimpleBadDiscUnion(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimpleBadDiscUnion(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimpleBadDiscUnion that will be copied. - */ - eProsima_user_DllExport SimpleBadDiscUnion( - const SimpleBadDiscUnion& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimpleBadDiscUnion that will be copied. - */ - eProsima_user_DllExport SimpleBadDiscUnion( - SimpleBadDiscUnion&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimpleBadDiscUnion that will be copied. - */ - eProsima_user_DllExport SimpleBadDiscUnion& operator =( - const SimpleBadDiscUnion& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimpleBadDiscUnion that will be copied. - */ - eProsima_user_DllExport SimpleBadDiscUnion& operator =( - SimpleBadDiscUnion&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimpleBadDiscUnion object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimpleBadDiscUnion& x) const; - - /*! - * @brief Comparison operator. - * @param x SimpleBadDiscUnion object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimpleBadDiscUnion& x) const; - - /*! - * @brief This function sets the discriminator value. - * @param __d New value for the discriminator. - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the new value doesn't correspond to the selected union member. - */ - eProsima_user_DllExport void _d( - uint8_t __d); - - /*! - * @brief This function returns the value of the discriminator. - * @return Value of the discriminator - */ - eProsima_user_DllExport uint8_t _d() const; - - /*! - * @brief This function returns a reference to the discriminator. - * @return Reference to the discriminator. - */ - eProsima_user_DllExport uint8_t& _d(); - - /*! - * @brief This function sets a value in member first - * @param _first New value for member first - */ - eProsima_user_DllExport void first( - int32_t _first); - - /*! - * @brief This function returns the value of member first - * @return Value of member first - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t first() const; - - /*! - * @brief This function returns a reference to member first - * @return Reference to member first - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t& first(); - - - /*! - * @brief This function sets a value in member second - * @param _second New value for member second - */ - eProsima_user_DllExport void second( - int64_t _second); - - /*! - * @brief This function returns the value of member second - * @return Value of member second - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t second() const; - - /*! - * @brief This function returns a reference to member second - * @return Reference to member second - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t& second(); - -private: - - uint8_t m__d; - - int32_t m_first{0}; - int64_t m_second{0}; -}; - - -/*! - * @brief This class represents the structure SimpleUnionStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SimpleUnionStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimpleUnionStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimpleUnionStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimpleUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleUnionStruct( - const SimpleUnionStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimpleUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleUnionStruct( - SimpleUnionStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimpleUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleUnionStruct& operator =( - const SimpleUnionStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimpleUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleUnionStruct& operator =( - SimpleUnionStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimpleUnionStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimpleUnionStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x SimpleUnionStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimpleUnionStruct& x) const; - - /*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ - eProsima_user_DllExport void my_union( - const SimpleUnion& _my_union); - - /*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ - eProsima_user_DllExport void my_union( - SimpleUnion&& _my_union); - - /*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ - eProsima_user_DllExport const SimpleUnion& my_union() const; - - /*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ - eProsima_user_DllExport SimpleUnion& my_union(); - -private: - - SimpleUnion m_my_union; - -}; - - -/*! - * @brief This class represents the structure SimpleUnionStructEqual defined by the user in the IDL file. - * @ingroup Types - */ -class SimpleUnionStructEqual -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimpleUnionStructEqual(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimpleUnionStructEqual(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimpleUnionStructEqual that will be copied. - */ - eProsima_user_DllExport SimpleUnionStructEqual( - const SimpleUnionStructEqual& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimpleUnionStructEqual that will be copied. - */ - eProsima_user_DllExport SimpleUnionStructEqual( - SimpleUnionStructEqual&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimpleUnionStructEqual that will be copied. - */ - eProsima_user_DllExport SimpleUnionStructEqual& operator =( - const SimpleUnionStructEqual& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimpleUnionStructEqual that will be copied. - */ - eProsima_user_DllExport SimpleUnionStructEqual& operator =( - SimpleUnionStructEqual&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimpleUnionStructEqual object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimpleUnionStructEqual& x) const; - - /*! - * @brief Comparison operator. - * @param x SimpleUnionStructEqual object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimpleUnionStructEqual& x) const; - - /*! - * @brief This function copies the value in member my_union_equal - * @param _my_union_equal New value to be copied in member my_union_equal - */ - eProsima_user_DllExport void my_union_equal( - const SimpleUnion& _my_union_equal); - - /*! - * @brief This function moves the value in member my_union_equal - * @param _my_union_equal New value to be moved in member my_union_equal - */ - eProsima_user_DllExport void my_union_equal( - SimpleUnion&& _my_union_equal); - - /*! - * @brief This function returns a constant reference to member my_union_equal - * @return Constant reference to member my_union_equal - */ - eProsima_user_DllExport const SimpleUnion& my_union_equal() const; - - /*! - * @brief This function returns a reference to member my_union_equal - * @return Reference to member my_union_equal - */ - eProsima_user_DllExport SimpleUnion& my_union_equal(); - -private: - - SimpleUnion m_my_union_equal; - -}; - - -/*! - * @brief This class represents the structure SimpleUnionNamesStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SimpleUnionNamesStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimpleUnionNamesStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimpleUnionNamesStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimpleUnionNamesStruct that will be copied. - */ - eProsima_user_DllExport SimpleUnionNamesStruct( - const SimpleUnionNamesStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimpleUnionNamesStruct that will be copied. - */ - eProsima_user_DllExport SimpleUnionNamesStruct( - SimpleUnionNamesStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimpleUnionNamesStruct that will be copied. - */ - eProsima_user_DllExport SimpleUnionNamesStruct& operator =( - const SimpleUnionNamesStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimpleUnionNamesStruct that will be copied. - */ - eProsima_user_DllExport SimpleUnionNamesStruct& operator =( - SimpleUnionNamesStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimpleUnionNamesStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimpleUnionNamesStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x SimpleUnionNamesStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimpleUnionNamesStruct& x) const; - - /*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ - eProsima_user_DllExport void my_union( - const SimpleUnionNames& _my_union); - - /*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ - eProsima_user_DllExport void my_union( - SimpleUnionNames&& _my_union); - - /*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ - eProsima_user_DllExport const SimpleUnionNames& my_union() const; - - /*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ - eProsima_user_DllExport SimpleUnionNames& my_union(); - -private: - - SimpleUnionNames m_my_union; - -}; - - -/*! - * @brief This class represents the structure SimpleTypeUnionStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SimpleTypeUnionStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimpleTypeUnionStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimpleTypeUnionStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimpleTypeUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleTypeUnionStruct( - const SimpleTypeUnionStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimpleTypeUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleTypeUnionStruct( - SimpleTypeUnionStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimpleTypeUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleTypeUnionStruct& operator =( - const SimpleTypeUnionStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimpleTypeUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleTypeUnionStruct& operator =( - SimpleTypeUnionStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimpleTypeUnionStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimpleTypeUnionStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x SimpleTypeUnionStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimpleTypeUnionStruct& x) const; - - /*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ - eProsima_user_DllExport void my_union( - const SimpleTypeUnion& _my_union); - - /*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ - eProsima_user_DllExport void my_union( - SimpleTypeUnion&& _my_union); - - /*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ - eProsima_user_DllExport const SimpleTypeUnion& my_union() const; - - /*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ - eProsima_user_DllExport SimpleTypeUnion& my_union(); - -private: - - SimpleTypeUnion m_my_union; - -}; - - -/*! - * @brief This class represents the structure SimpleBadUnionStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SimpleBadUnionStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimpleBadUnionStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimpleBadUnionStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimpleBadUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleBadUnionStruct( - const SimpleBadUnionStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimpleBadUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleBadUnionStruct( - SimpleBadUnionStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimpleBadUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleBadUnionStruct& operator =( - const SimpleBadUnionStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimpleBadUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleBadUnionStruct& operator =( - SimpleBadUnionStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimpleBadUnionStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimpleBadUnionStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x SimpleBadUnionStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimpleBadUnionStruct& x) const; - - /*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ - eProsima_user_DllExport void my_union( - const SimpleBadUnion& _my_union); - - /*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ - eProsima_user_DllExport void my_union( - SimpleBadUnion&& _my_union); - - /*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ - eProsima_user_DllExport const SimpleBadUnion& my_union() const; - - /*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ - eProsima_user_DllExport SimpleBadUnion& my_union(); - -private: - - SimpleBadUnion m_my_union; - -}; - - -/*! - * @brief This class represents the structure SimplBadDiscUnionStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SimplBadDiscUnionStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimplBadDiscUnionStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimplBadDiscUnionStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimplBadDiscUnionStruct that will be copied. - */ - eProsima_user_DllExport SimplBadDiscUnionStruct( - const SimplBadDiscUnionStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimplBadDiscUnionStruct that will be copied. - */ - eProsima_user_DllExport SimplBadDiscUnionStruct( - SimplBadDiscUnionStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimplBadDiscUnionStruct that will be copied. - */ - eProsima_user_DllExport SimplBadDiscUnionStruct& operator =( - const SimplBadDiscUnionStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimplBadDiscUnionStruct that will be copied. - */ - eProsima_user_DllExport SimplBadDiscUnionStruct& operator =( - SimplBadDiscUnionStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimplBadDiscUnionStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimplBadDiscUnionStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x SimplBadDiscUnionStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimplBadDiscUnionStruct& x) const; - - /*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ - eProsima_user_DllExport void my_union( - const SimpleBadDiscUnion& _my_union); - - /*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ - eProsima_user_DllExport void my_union( - SimpleBadDiscUnion&& _my_union); - - /*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ - eProsima_user_DllExport const SimpleBadDiscUnion& my_union() const; - - /*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ - eProsima_user_DllExport SimpleBadDiscUnion& my_union(); - -private: - - SimpleBadDiscUnion m_my_union; - -}; - -#endif // _FAST_DDS_GENERATED_TYPES_H_ - - - -#endif // FASTCDR_VERSION_MAJOR > 1 diff --git a/test/xtypes/idl/Types.idl b/test/xtypes/idl/Types.idl deleted file mode 100644 index fea3438ed82..00000000000 --- a/test/xtypes/idl/Types.idl +++ /dev/null @@ -1,271 +0,0 @@ -// Enum - -enum MyEnum -{ - A, - B, - C -}; - -enum MyBadEnum -{ - A1, - B1, - C1 -}; - -struct MyEnumStruct -{ - MyEnum my_enum; -}; - -struct MyBadEnumStruct -{ - MyBadEnum my_enum; -}; - -// Alias - -typedef MyEnum MyAliasEnum; - -struct MyAliasEnumStruct -{ - MyAliasEnum my_enum; // Keep same name -}; - -// All basic types - -struct BasicStruct -{ - boolean my_bool; - long my_int32; - string my_string; -}; - -struct BasicNamesStruct -{ - boolean my_bool_name; - long my_int32_name; - string my_string_name; -}; - -struct BasicBadStruct -{ - octet my_bool; - long my_int32; - string my_string; -}; - -// Wide Struct - -struct BasicWideStruct -{ - boolean my_bool; - long my_int32; - string my_string; - long new_int32; - string new_string; -}; - -// Bad Wide Struct - -struct BadBasicWideStruct -{ - long new_int32; - string new_string; - boolean my_bool; - long my_int32; - string my_string; -}; - -// String bounds - -struct StringStruct -{ - string my_string; -}; - -struct LargeStringStruct -{ - string<41925> my_large_string; -}; - -// WString bounds - -struct WStringStruct -{ - wstring my_wstring; -}; - -struct LargeWStringStruct -{ - wstring<41925> my_large_wstring; -}; - -// Array dimensions and size - -struct ArrayStruct -{ - long my_array[2]; -}; - -struct ArrayStructEqual -{ - long my_array_equal[2]; -}; - -struct ArrayBadStruct -{ - octet my_array[2]; -}; - -struct ArrayDimensionsStruct -{ - long my_array[2][2]; -}; - -struct ArraySizeStruct -{ - long my_array[5]; -}; - -// Sequence bounds - -struct SequenceStruct -{ - sequence my_sequence; -}; - -struct SequenceStructEqual -{ - sequence my_sequence_equal; -}; - -struct SequenceBadStruct -{ - sequence my_sequence; -}; - -struct SequenceBoundsStruct -{ - sequence my_sequence; -}; - -struct SequenceSequenceStruct -{ - sequence, 3> my_sequence_sequence; -}; - -struct SequenceSequenceBoundsStruct -{ - sequence, 5> my_sequence_sequence; -}; - -// Map bounds - -struct MapStruct -{ - map my_map; -}; - -struct MapStructEqual -{ - map my_map_equal; -}; - -struct MapBadKeyStruct -{ - map my_map; -}; - -struct MapBadElemStruct -{ - map my_map; -}; - -struct MapBoundsStruct -{ - map my_map; -}; - -struct MapMapStruct -{ - map , 2> my_map_map; -}; - -struct MapMapBoundsStruct -{ - map , 3> my_map_map; -}; - -// Unions - -union SimpleUnion switch (long) -{ - case A: - long first; - case B: - long long second; -}; - -union SimpleUnionNames switch (long) -{ - case A: - long first_case; - case B: - long long second_case; -}; - -union SimpleTypeUnion switch (long) -{ - case A: - octet first; - case B: - long long second; -}; - -union SimpleBadUnion switch (long) -{ - case A: - long first; - case C: - long long second; -}; - -union SimpleBadDiscUnion switch (octet) -{ - case 0: - long first; - case 1: - long long second; -}; - -struct SimpleUnionStruct -{ - SimpleUnion my_union; -}; - -struct SimpleUnionStructEqual -{ - SimpleUnion my_union_equal; -}; - -struct SimpleUnionNamesStruct -{ - SimpleUnionNames my_union; -}; - -struct SimpleTypeUnionStruct -{ - SimpleTypeUnion my_union; -}; - -struct SimpleBadUnionStruct -{ - SimpleBadUnion my_union; -}; - -struct SimplBadDiscUnionStruct -{ - SimpleBadDiscUnion my_union; -}; \ No newline at end of file diff --git a/test/xtypes/idl/TypesCdrAux.hpp b/test/xtypes/idl/TypesCdrAux.hpp deleted file mode 100644 index 14992724933..00000000000 --- a/test/xtypes/idl/TypesCdrAux.hpp +++ /dev/null @@ -1,427 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file TypesCdrAux.hpp - * This source file contains some definitions of CDR related functions. - * - * This file was generated by the tool fastddsgen. - */ - -#ifndef _FAST_DDS_GENERATED_TYPESCDRAUX_HPP_ -#define _FAST_DDS_GENERATED_TYPESCDRAUX_HPP_ - -#include "Types.h" - -constexpr uint32_t SimpleUnionStruct_max_cdr_typesize {24UL}; -constexpr uint32_t SimpleUnionStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t SequenceSequenceBoundsStruct_max_cdr_typesize {132UL}; -constexpr uint32_t SequenceSequenceBoundsStruct_max_key_cdr_typesize {0UL}; - - -constexpr uint32_t MyAliasEnumStruct_max_cdr_typesize {8UL}; -constexpr uint32_t MyAliasEnumStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t ArrayBadStruct_max_cdr_typesize {6UL}; -constexpr uint32_t ArrayBadStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t MapBadKeyStruct_max_cdr_typesize {24UL}; -constexpr uint32_t MapBadKeyStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t SimpleBadUnionStruct_max_cdr_typesize {24UL}; -constexpr uint32_t SimpleBadUnionStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t MyEnumStruct_max_cdr_typesize {8UL}; -constexpr uint32_t MyEnumStruct_max_key_cdr_typesize {0UL}; - - -constexpr uint32_t ArrayStructEqual_max_cdr_typesize {12UL}; -constexpr uint32_t ArrayStructEqual_max_key_cdr_typesize {0UL}; - -constexpr uint32_t LargeWStringStruct_max_cdr_typesize {83858UL}; -constexpr uint32_t LargeWStringStruct_max_key_cdr_typesize {0UL}; - - -constexpr uint32_t WStringStruct_max_cdr_typesize {518UL}; -constexpr uint32_t WStringStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t SequenceStruct_max_cdr_typesize {16UL}; -constexpr uint32_t SequenceStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t SimpleTypeUnionStruct_max_cdr_typesize {24UL}; -constexpr uint32_t SimpleTypeUnionStruct_max_key_cdr_typesize {0UL}; - - -constexpr uint32_t ArrayDimensionsStruct_max_cdr_typesize {20UL}; -constexpr uint32_t ArrayDimensionsStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t SequenceSequenceStruct_max_cdr_typesize {48UL}; -constexpr uint32_t SequenceSequenceStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t MapBoundsStruct_max_cdr_typesize {40UL}; -constexpr uint32_t MapBoundsStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t SequenceStructEqual_max_cdr_typesize {16UL}; -constexpr uint32_t SequenceStructEqual_max_key_cdr_typesize {0UL}; - -constexpr uint32_t MapStructEqual_max_cdr_typesize {24UL}; -constexpr uint32_t MapStructEqual_max_key_cdr_typesize {0UL}; - -constexpr uint32_t BasicStruct_max_cdr_typesize {272UL}; -constexpr uint32_t BasicStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t SequenceBoundsStruct_max_cdr_typesize {24UL}; -constexpr uint32_t SequenceBoundsStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t MapMapStruct_max_cdr_typesize {60UL}; -constexpr uint32_t MapMapStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t BasicWideStruct_max_cdr_typesize {536UL}; -constexpr uint32_t BasicWideStruct_max_key_cdr_typesize {0UL}; - - -constexpr uint32_t SimplBadDiscUnionStruct_max_cdr_typesize {24UL}; -constexpr uint32_t SimplBadDiscUnionStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t MapStruct_max_cdr_typesize {24UL}; -constexpr uint32_t MapStruct_max_key_cdr_typesize {0UL}; - - -constexpr uint32_t MyBadEnumStruct_max_cdr_typesize {8UL}; -constexpr uint32_t MyBadEnumStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t SequenceBadStruct_max_cdr_typesize {10UL}; -constexpr uint32_t SequenceBadStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t SimpleUnionNamesStruct_max_cdr_typesize {24UL}; -constexpr uint32_t SimpleUnionNamesStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t LargeStringStruct_max_cdr_typesize {41934UL}; -constexpr uint32_t LargeStringStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t ArrayStruct_max_cdr_typesize {12UL}; -constexpr uint32_t ArrayStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t BadBasicWideStruct_max_cdr_typesize {536UL}; -constexpr uint32_t BadBasicWideStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t ArraySizeStruct_max_cdr_typesize {24UL}; -constexpr uint32_t ArraySizeStruct_max_key_cdr_typesize {0UL}; - - -constexpr uint32_t MapBadElemStruct_max_cdr_typesize {40UL}; -constexpr uint32_t MapBadElemStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t SimpleUnionStructEqual_max_cdr_typesize {24UL}; -constexpr uint32_t SimpleUnionStructEqual_max_key_cdr_typesize {0UL}; - -constexpr uint32_t BasicBadStruct_max_cdr_typesize {272UL}; -constexpr uint32_t BasicBadStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t BasicNamesStruct_max_cdr_typesize {272UL}; -constexpr uint32_t BasicNamesStruct_max_key_cdr_typesize {0UL}; - -constexpr uint32_t StringStruct_max_cdr_typesize {264UL}; -constexpr uint32_t StringStruct_max_key_cdr_typesize {0UL}; - - -constexpr uint32_t MapMapBoundsStruct_max_cdr_typesize {108UL}; -constexpr uint32_t MapMapBoundsStruct_max_key_cdr_typesize {0UL}; - - -namespace eprosima { -namespace fastcdr { - -class Cdr; -class CdrSizeCalculator; - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const MyEnumStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const MyBadEnumStruct& data); - - - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const MyAliasEnumStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const BasicStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const BasicNamesStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const BasicBadStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const BasicWideStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const BadBasicWideStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const StringStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const LargeStringStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const WStringStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const LargeWStringStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const ArrayStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const ArrayStructEqual& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const ArrayBadStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const ArrayDimensionsStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const ArraySizeStruct& data); - - - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SequenceStruct& data); - - - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SequenceStructEqual& data); - - - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SequenceBadStruct& data); - - - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SequenceBoundsStruct& data); - - - - - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SequenceSequenceStruct& data); - - - - - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SequenceSequenceBoundsStruct& data); - - - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const MapStruct& data); - - - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const MapStructEqual& data); - - - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const MapBadKeyStruct& data); - - - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const MapBadElemStruct& data); - - - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const MapBoundsStruct& data); - - - - - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const MapMapStruct& data); - - - - - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const MapMapBoundsStruct& data); - - - - - - - - - - - - - - - - - - - - - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SimpleUnionStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SimpleUnionStructEqual& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SimpleUnionNamesStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SimpleTypeUnionStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SimpleBadUnionStruct& data); - - - -eProsima_user_DllExport void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SimplBadDiscUnionStruct& data); - - -} // namespace fastcdr -} // namespace eprosima - -#endif // _FAST_DDS_GENERATED_TYPESCDRAUX_HPP_ - diff --git a/test/xtypes/idl/TypesCdrAux.ipp b/test/xtypes/idl/TypesCdrAux.ipp deleted file mode 100644 index 5d6735bcfef..00000000000 --- a/test/xtypes/idl/TypesCdrAux.ipp +++ /dev/null @@ -1,3543 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file TypesCdrAux.ipp - * This source file contains some declarations of CDR related functions. - * - * This file was generated by the tool fastddsgen. - */ - -#ifndef _FAST_DDS_GENERATED_TYPESCDRAUX_IPP_ -#define _FAST_DDS_GENERATED_TYPESCDRAUX_IPP_ - -#include "TypesCdrAux.hpp" - -#include -#include - - -#include -using namespace eprosima::fastcdr::exception; - -namespace eprosima { -namespace fastcdr { - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const MyEnumStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_enum(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const MyEnumStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_enum() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - MyEnumStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_enum(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const MyEnumStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const MyBadEnumStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_enum(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const MyBadEnumStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_enum() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - MyBadEnumStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_enum(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const MyBadEnumStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const MyAliasEnumStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_enum(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const MyAliasEnumStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_enum() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - MyAliasEnumStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_enum(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const MyAliasEnumStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const BasicStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_bool(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(1), - data.my_int32(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(2), - data.my_string(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const BasicStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_bool() - << eprosima::fastcdr::MemberId(1) << data.my_int32() - << eprosima::fastcdr::MemberId(2) << data.my_string() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - BasicStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_bool(); - break; - - case 1: - dcdr >> data.my_int32(); - break; - - case 2: - dcdr >> data.my_string(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const BasicStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const BasicNamesStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_bool_name(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(1), - data.my_int32_name(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(2), - data.my_string_name(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const BasicNamesStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_bool_name() - << eprosima::fastcdr::MemberId(1) << data.my_int32_name() - << eprosima::fastcdr::MemberId(2) << data.my_string_name() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - BasicNamesStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_bool_name(); - break; - - case 1: - dcdr >> data.my_int32_name(); - break; - - case 2: - dcdr >> data.my_string_name(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const BasicNamesStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const BasicBadStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_bool(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(1), - data.my_int32(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(2), - data.my_string(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const BasicBadStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_bool() - << eprosima::fastcdr::MemberId(1) << data.my_int32() - << eprosima::fastcdr::MemberId(2) << data.my_string() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - BasicBadStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_bool(); - break; - - case 1: - dcdr >> data.my_int32(); - break; - - case 2: - dcdr >> data.my_string(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const BasicBadStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const BasicWideStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_bool(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(1), - data.my_int32(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(2), - data.my_string(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(3), - data.new_int32(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(4), - data.new_string(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const BasicWideStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_bool() - << eprosima::fastcdr::MemberId(1) << data.my_int32() - << eprosima::fastcdr::MemberId(2) << data.my_string() - << eprosima::fastcdr::MemberId(3) << data.new_int32() - << eprosima::fastcdr::MemberId(4) << data.new_string() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - BasicWideStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_bool(); - break; - - case 1: - dcdr >> data.my_int32(); - break; - - case 2: - dcdr >> data.my_string(); - break; - - case 3: - dcdr >> data.new_int32(); - break; - - case 4: - dcdr >> data.new_string(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const BasicWideStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const BadBasicWideStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.new_int32(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(1), - data.new_string(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(2), - data.my_bool(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(3), - data.my_int32(), current_alignment); - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(4), - data.my_string(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const BadBasicWideStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.new_int32() - << eprosima::fastcdr::MemberId(1) << data.new_string() - << eprosima::fastcdr::MemberId(2) << data.my_bool() - << eprosima::fastcdr::MemberId(3) << data.my_int32() - << eprosima::fastcdr::MemberId(4) << data.my_string() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - BadBasicWideStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.new_int32(); - break; - - case 1: - dcdr >> data.new_string(); - break; - - case 2: - dcdr >> data.my_bool(); - break; - - case 3: - dcdr >> data.my_int32(); - break; - - case 4: - dcdr >> data.my_string(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const BadBasicWideStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const StringStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_string(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const StringStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_string() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - StringStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_string(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const StringStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const LargeStringStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_large_string(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const LargeStringStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_large_string() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - LargeStringStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_large_string(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const LargeStringStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const WStringStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_wstring(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const WStringStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_wstring() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - WStringStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_wstring(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const WStringStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const LargeWStringStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_large_wstring(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const LargeWStringStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_large_wstring() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - LargeWStringStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_large_wstring(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const LargeWStringStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const ArrayStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_array(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const ArrayStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_array() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - ArrayStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_array(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const ArrayStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const ArrayStructEqual& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_array_equal(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const ArrayStructEqual& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_array_equal() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - ArrayStructEqual& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_array_equal(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const ArrayStructEqual& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const ArrayBadStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_array(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const ArrayBadStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_array() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - ArrayBadStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_array(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const ArrayBadStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const ArrayDimensionsStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_array(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const ArrayDimensionsStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_array() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - ArrayDimensionsStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_array(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const ArrayDimensionsStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const ArraySizeStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_array(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const ArraySizeStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_array() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - ArraySizeStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_array(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const ArraySizeStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const SequenceStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_sequence(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const SequenceStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_sequence() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - SequenceStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_sequence(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SequenceStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const SequenceStructEqual& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_sequence_equal(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const SequenceStructEqual& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_sequence_equal() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - SequenceStructEqual& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_sequence_equal(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SequenceStructEqual& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const SequenceBadStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_sequence(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const SequenceBadStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_sequence() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - SequenceBadStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_sequence(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SequenceBadStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const SequenceBoundsStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_sequence(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const SequenceBoundsStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_sequence() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - SequenceBoundsStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_sequence(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SequenceBoundsStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const SequenceSequenceStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_sequence_sequence(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const SequenceSequenceStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_sequence_sequence() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - SequenceSequenceStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_sequence_sequence(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SequenceSequenceStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const SequenceSequenceBoundsStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_sequence_sequence(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const SequenceSequenceBoundsStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_sequence_sequence() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - SequenceSequenceBoundsStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_sequence_sequence(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SequenceSequenceBoundsStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const MapStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_map(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const MapStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_map() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - MapStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_map(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const MapStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const MapStructEqual& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_map_equal(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const MapStructEqual& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_map_equal() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - MapStructEqual& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_map_equal(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const MapStructEqual& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const MapBadKeyStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_map(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const MapBadKeyStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_map() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - MapBadKeyStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_map(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const MapBadKeyStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const MapBadElemStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_map(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const MapBadElemStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_map() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - MapBadElemStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_map(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const MapBadElemStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const MapBoundsStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_map(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const MapBoundsStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_map() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - MapBoundsStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_map(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const MapBoundsStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const MapMapStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_map_map(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const MapMapStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_map_map() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - MapMapStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_map_map(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const MapMapStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const MapMapBoundsStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_map_map(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const MapMapBoundsStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_map_map() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - MapMapBoundsStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_map_map(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const MapMapBoundsStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const SimpleUnion& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), data._d(), - current_alignment); - - switch (data._d()) - { - case A: - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(1), - data.first(), current_alignment); - break; - - case B: - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(2), - data.second(), current_alignment); - break; - - default: - break; - } - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const SimpleUnion& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr << eprosima::fastcdr::MemberId(0) << data._d(); - - switch (data._d()) - { - case A: - scdr << eprosima::fastcdr::MemberId(1) << data.first(); - break; - - case B: - scdr << eprosima::fastcdr::MemberId(2) << data.second(); - break; - - default: - break; - } - - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - SimpleUnion& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data._d(); - break; - default: - switch (data._d()) - { - case A: - dcdr >> data.first(); - break; - - case B: - dcdr >> data.second(); - break; - - default: - break; - } - ret_value = false; - break; - } - return ret_value; - }); -} - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const SimpleUnionNames& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), data._d(), - current_alignment); - - switch (data._d()) - { - case A: - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(1), - data.first_case(), current_alignment); - break; - - case B: - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(2), - data.second_case(), current_alignment); - break; - - default: - break; - } - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const SimpleUnionNames& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr << eprosima::fastcdr::MemberId(0) << data._d(); - - switch (data._d()) - { - case A: - scdr << eprosima::fastcdr::MemberId(1) << data.first_case(); - break; - - case B: - scdr << eprosima::fastcdr::MemberId(2) << data.second_case(); - break; - - default: - break; - } - - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - SimpleUnionNames& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data._d(); - break; - default: - switch (data._d()) - { - case A: - dcdr >> data.first_case(); - break; - - case B: - dcdr >> data.second_case(); - break; - - default: - break; - } - ret_value = false; - break; - } - return ret_value; - }); -} - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const SimpleTypeUnion& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), data._d(), - current_alignment); - - switch (data._d()) - { - case A: - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(1), - data.first(), current_alignment); - break; - - case B: - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(2), - data.second(), current_alignment); - break; - - default: - break; - } - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const SimpleTypeUnion& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr << eprosima::fastcdr::MemberId(0) << data._d(); - - switch (data._d()) - { - case A: - scdr << eprosima::fastcdr::MemberId(1) << data.first(); - break; - - case B: - scdr << eprosima::fastcdr::MemberId(2) << data.second(); - break; - - default: - break; - } - - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - SimpleTypeUnion& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data._d(); - break; - default: - switch (data._d()) - { - case A: - dcdr >> data.first(); - break; - - case B: - dcdr >> data.second(); - break; - - default: - break; - } - ret_value = false; - break; - } - return ret_value; - }); -} - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const SimpleBadUnion& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), data._d(), - current_alignment); - - switch (data._d()) - { - case A: - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(1), - data.first(), current_alignment); - break; - - case C: - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(2), - data.second(), current_alignment); - break; - - default: - break; - } - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const SimpleBadUnion& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr << eprosima::fastcdr::MemberId(0) << data._d(); - - switch (data._d()) - { - case A: - scdr << eprosima::fastcdr::MemberId(1) << data.first(); - break; - - case C: - scdr << eprosima::fastcdr::MemberId(2) << data.second(); - break; - - default: - break; - } - - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - SimpleBadUnion& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data._d(); - break; - default: - switch (data._d()) - { - case A: - dcdr >> data.first(); - break; - - case C: - dcdr >> data.second(); - break; - - default: - break; - } - ret_value = false; - break; - } - return ret_value; - }); -} - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const SimpleBadDiscUnion& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), data._d(), - current_alignment); - - switch (data._d()) - { - case 0: - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(1), - data.first(), current_alignment); - break; - - case 1: - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(2), - data.second(), current_alignment); - break; - - default: - break; - } - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const SimpleBadDiscUnion& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr << eprosima::fastcdr::MemberId(0) << data._d(); - - switch (data._d()) - { - case 0: - scdr << eprosima::fastcdr::MemberId(1) << data.first(); - break; - - case 1: - scdr << eprosima::fastcdr::MemberId(2) << data.second(); - break; - - default: - break; - } - - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - SimpleBadDiscUnion& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data._d(); - break; - default: - switch (data._d()) - { - case 0: - dcdr >> data.first(); - break; - - case 1: - dcdr >> data.second(); - break; - - default: - break; - } - ret_value = false; - break; - } - return ret_value; - }); -} - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const SimpleUnionStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_union(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const SimpleUnionStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_union() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - SimpleUnionStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_union(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SimpleUnionStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const SimpleUnionStructEqual& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_union_equal(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const SimpleUnionStructEqual& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_union_equal() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - SimpleUnionStructEqual& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_union_equal(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SimpleUnionStructEqual& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const SimpleUnionNamesStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_union(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const SimpleUnionNamesStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_union() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - SimpleUnionNamesStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_union(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SimpleUnionNamesStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const SimpleTypeUnionStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_union(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const SimpleTypeUnionStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_union() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - SimpleTypeUnionStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_union(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SimpleTypeUnionStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const SimpleBadUnionStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_union(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const SimpleBadUnionStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_union() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - SimpleBadUnionStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_union(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SimpleBadUnionStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - - -template<> -eProsima_user_DllExport size_t calculate_serialized_size( - eprosima::fastcdr::CdrSizeCalculator& calculator, - const SimplBadDiscUnionStruct& data, - size_t& current_alignment) -{ - static_cast(data); - - eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); - size_t calculated_size {calculator.begin_calculate_type_serialized_size( - eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - current_alignment)}; - - - calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), - data.my_union(), current_alignment); - - - calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); - - return calculated_size; -} - -template<> -eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& scdr, - const SimplBadDiscUnionStruct& data) -{ - eprosima::fastcdr::Cdr::state current_state(scdr); - scdr.begin_serialize_type(current_state, - eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); - - scdr - << eprosima::fastcdr::MemberId(0) << data.my_union() -; - scdr.end_serialize_type(current_state); -} - -template<> -eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr, - SimplBadDiscUnionStruct& data) -{ - cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, - [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool - { - bool ret_value = true; - switch (mid.id) - { - case 0: - dcdr >> data.my_union(); - break; - - default: - ret_value = false; - break; - } - return ret_value; - }); -} - -void serialize_key( - eprosima::fastcdr::Cdr& scdr, - const SimplBadDiscUnionStruct& data) -{ - static_cast(scdr); - static_cast(data); -} - - - -} // namespace fastcdr -} // namespace eprosima - -#endif // _FAST_DDS_GENERATED_TYPESCDRAUX_IPP_ - diff --git a/test/xtypes/idl/TypesPubSubTypes.cxx b/test/xtypes/idl/TypesPubSubTypes.cxx deleted file mode 100644 index 0c0a8f0363e..00000000000 --- a/test/xtypes/idl/TypesPubSubTypes.cxx +++ /dev/null @@ -1,6927 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file TypesPubSubTypes.cpp - * This header file contains the implementation of the serialization functions. - * - * This file was generated by the tool fastddsgen. - */ - - -#include - -#include "TypesPubSubTypes.h" -#include "TypesCdrAux.hpp" - -using SerializedPayload_t = eprosima::fastrtps::rtps::SerializedPayload_t; -using InstanceHandle_t = eprosima::fastrtps::rtps::InstanceHandle_t; -using DataRepresentationId_t = eprosima::fastdds::dds::DataRepresentationId_t; - - - -MyEnumStructPubSubType::MyEnumStructPubSubType() -{ - setName("MyEnumStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(MyEnumStruct::getMaxCdrSerializedSize()); -#else - MyEnumStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = MyEnumStruct_max_key_cdr_typesize > 16 ? MyEnumStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -MyEnumStructPubSubType::~MyEnumStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool MyEnumStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - MyEnumStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool MyEnumStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - MyEnumStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function MyEnumStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* MyEnumStructPubSubType::createData() -{ - return reinterpret_cast(new MyEnumStruct()); -} - -void MyEnumStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool MyEnumStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - MyEnumStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - MyEnumStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || MyEnumStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -MyBadEnumStructPubSubType::MyBadEnumStructPubSubType() -{ - setName("MyBadEnumStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(MyBadEnumStruct::getMaxCdrSerializedSize()); -#else - MyBadEnumStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = MyBadEnumStruct_max_key_cdr_typesize > 16 ? MyBadEnumStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -MyBadEnumStructPubSubType::~MyBadEnumStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool MyBadEnumStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - MyBadEnumStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool MyBadEnumStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - MyBadEnumStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function MyBadEnumStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* MyBadEnumStructPubSubType::createData() -{ - return reinterpret_cast(new MyBadEnumStruct()); -} - -void MyBadEnumStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool MyBadEnumStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - MyBadEnumStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - MyBadEnumStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || MyBadEnumStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - - - -MyAliasEnumStructPubSubType::MyAliasEnumStructPubSubType() -{ - setName("MyAliasEnumStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(MyAliasEnumStruct::getMaxCdrSerializedSize()); -#else - MyAliasEnumStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = MyAliasEnumStruct_max_key_cdr_typesize > 16 ? MyAliasEnumStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -MyAliasEnumStructPubSubType::~MyAliasEnumStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool MyAliasEnumStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - MyAliasEnumStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool MyAliasEnumStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - MyAliasEnumStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function MyAliasEnumStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* MyAliasEnumStructPubSubType::createData() -{ - return reinterpret_cast(new MyAliasEnumStruct()); -} - -void MyAliasEnumStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool MyAliasEnumStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - MyAliasEnumStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - MyAliasEnumStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || MyAliasEnumStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -BasicStructPubSubType::BasicStructPubSubType() -{ - setName("BasicStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(BasicStruct::getMaxCdrSerializedSize()); -#else - BasicStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = BasicStruct_max_key_cdr_typesize > 16 ? BasicStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -BasicStructPubSubType::~BasicStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool BasicStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - BasicStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool BasicStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - BasicStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function BasicStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* BasicStructPubSubType::createData() -{ - return reinterpret_cast(new BasicStruct()); -} - -void BasicStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool BasicStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - BasicStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - BasicStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || BasicStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -BasicNamesStructPubSubType::BasicNamesStructPubSubType() -{ - setName("BasicNamesStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(BasicNamesStruct::getMaxCdrSerializedSize()); -#else - BasicNamesStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = BasicNamesStruct_max_key_cdr_typesize > 16 ? BasicNamesStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -BasicNamesStructPubSubType::~BasicNamesStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool BasicNamesStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - BasicNamesStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool BasicNamesStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - BasicNamesStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function BasicNamesStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* BasicNamesStructPubSubType::createData() -{ - return reinterpret_cast(new BasicNamesStruct()); -} - -void BasicNamesStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool BasicNamesStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - BasicNamesStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - BasicNamesStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || BasicNamesStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -BasicBadStructPubSubType::BasicBadStructPubSubType() -{ - setName("BasicBadStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(BasicBadStruct::getMaxCdrSerializedSize()); -#else - BasicBadStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = BasicBadStruct_max_key_cdr_typesize > 16 ? BasicBadStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -BasicBadStructPubSubType::~BasicBadStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool BasicBadStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - BasicBadStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool BasicBadStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - BasicBadStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function BasicBadStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* BasicBadStructPubSubType::createData() -{ - return reinterpret_cast(new BasicBadStruct()); -} - -void BasicBadStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool BasicBadStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - BasicBadStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - BasicBadStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || BasicBadStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -BasicWideStructPubSubType::BasicWideStructPubSubType() -{ - setName("BasicWideStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(BasicWideStruct::getMaxCdrSerializedSize()); -#else - BasicWideStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = BasicWideStruct_max_key_cdr_typesize > 16 ? BasicWideStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -BasicWideStructPubSubType::~BasicWideStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool BasicWideStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - BasicWideStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool BasicWideStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - BasicWideStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function BasicWideStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* BasicWideStructPubSubType::createData() -{ - return reinterpret_cast(new BasicWideStruct()); -} - -void BasicWideStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool BasicWideStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - BasicWideStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - BasicWideStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || BasicWideStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -BadBasicWideStructPubSubType::BadBasicWideStructPubSubType() -{ - setName("BadBasicWideStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(BadBasicWideStruct::getMaxCdrSerializedSize()); -#else - BadBasicWideStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = BadBasicWideStruct_max_key_cdr_typesize > 16 ? BadBasicWideStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -BadBasicWideStructPubSubType::~BadBasicWideStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool BadBasicWideStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - BadBasicWideStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool BadBasicWideStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - BadBasicWideStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function BadBasicWideStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* BadBasicWideStructPubSubType::createData() -{ - return reinterpret_cast(new BadBasicWideStruct()); -} - -void BadBasicWideStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool BadBasicWideStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - BadBasicWideStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - BadBasicWideStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || BadBasicWideStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -StringStructPubSubType::StringStructPubSubType() -{ - setName("StringStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(StringStruct::getMaxCdrSerializedSize()); -#else - StringStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = StringStruct_max_key_cdr_typesize > 16 ? StringStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -StringStructPubSubType::~StringStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool StringStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - StringStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool StringStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - StringStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function StringStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* StringStructPubSubType::createData() -{ - return reinterpret_cast(new StringStruct()); -} - -void StringStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool StringStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - StringStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - StringStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || StringStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -LargeStringStructPubSubType::LargeStringStructPubSubType() -{ - setName("LargeStringStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(LargeStringStruct::getMaxCdrSerializedSize()); -#else - LargeStringStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = LargeStringStruct_max_key_cdr_typesize > 16 ? LargeStringStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -LargeStringStructPubSubType::~LargeStringStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool LargeStringStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - LargeStringStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool LargeStringStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - LargeStringStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function LargeStringStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* LargeStringStructPubSubType::createData() -{ - return reinterpret_cast(new LargeStringStruct()); -} - -void LargeStringStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool LargeStringStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - LargeStringStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - LargeStringStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || LargeStringStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -WStringStructPubSubType::WStringStructPubSubType() -{ - setName("WStringStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(WStringStruct::getMaxCdrSerializedSize()); -#else - WStringStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = WStringStruct_max_key_cdr_typesize > 16 ? WStringStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -WStringStructPubSubType::~WStringStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool WStringStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - WStringStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool WStringStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - WStringStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function WStringStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* WStringStructPubSubType::createData() -{ - return reinterpret_cast(new WStringStruct()); -} - -void WStringStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool WStringStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - WStringStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - WStringStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || WStringStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -LargeWStringStructPubSubType::LargeWStringStructPubSubType() -{ - setName("LargeWStringStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(LargeWStringStruct::getMaxCdrSerializedSize()); -#else - LargeWStringStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = LargeWStringStruct_max_key_cdr_typesize > 16 ? LargeWStringStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -LargeWStringStructPubSubType::~LargeWStringStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool LargeWStringStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - LargeWStringStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool LargeWStringStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - LargeWStringStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function LargeWStringStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* LargeWStringStructPubSubType::createData() -{ - return reinterpret_cast(new LargeWStringStruct()); -} - -void LargeWStringStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool LargeWStringStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - LargeWStringStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - LargeWStringStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || LargeWStringStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -ArrayStructPubSubType::ArrayStructPubSubType() -{ - setName("ArrayStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(ArrayStruct::getMaxCdrSerializedSize()); -#else - ArrayStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = ArrayStruct_max_key_cdr_typesize > 16 ? ArrayStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -ArrayStructPubSubType::~ArrayStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool ArrayStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - ArrayStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool ArrayStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - ArrayStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function ArrayStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* ArrayStructPubSubType::createData() -{ - return reinterpret_cast(new ArrayStruct()); -} - -void ArrayStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool ArrayStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - ArrayStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - ArrayStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || ArrayStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -ArrayStructEqualPubSubType::ArrayStructEqualPubSubType() -{ - setName("ArrayStructEqual"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(ArrayStructEqual::getMaxCdrSerializedSize()); -#else - ArrayStructEqual_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = ArrayStructEqual_max_key_cdr_typesize > 16 ? ArrayStructEqual_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -ArrayStructEqualPubSubType::~ArrayStructEqualPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool ArrayStructEqualPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - ArrayStructEqual* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool ArrayStructEqualPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - ArrayStructEqual* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function ArrayStructEqualPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* ArrayStructEqualPubSubType::createData() -{ - return reinterpret_cast(new ArrayStructEqual()); -} - -void ArrayStructEqualPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool ArrayStructEqualPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - ArrayStructEqual* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - ArrayStructEqual_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || ArrayStructEqual_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -ArrayBadStructPubSubType::ArrayBadStructPubSubType() -{ - setName("ArrayBadStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(ArrayBadStruct::getMaxCdrSerializedSize()); -#else - ArrayBadStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = ArrayBadStruct_max_key_cdr_typesize > 16 ? ArrayBadStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -ArrayBadStructPubSubType::~ArrayBadStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool ArrayBadStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - ArrayBadStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool ArrayBadStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - ArrayBadStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function ArrayBadStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* ArrayBadStructPubSubType::createData() -{ - return reinterpret_cast(new ArrayBadStruct()); -} - -void ArrayBadStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool ArrayBadStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - ArrayBadStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - ArrayBadStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || ArrayBadStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -ArrayDimensionsStructPubSubType::ArrayDimensionsStructPubSubType() -{ - setName("ArrayDimensionsStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(ArrayDimensionsStruct::getMaxCdrSerializedSize()); -#else - ArrayDimensionsStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = ArrayDimensionsStruct_max_key_cdr_typesize > 16 ? ArrayDimensionsStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -ArrayDimensionsStructPubSubType::~ArrayDimensionsStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool ArrayDimensionsStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - ArrayDimensionsStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool ArrayDimensionsStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - ArrayDimensionsStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function ArrayDimensionsStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* ArrayDimensionsStructPubSubType::createData() -{ - return reinterpret_cast(new ArrayDimensionsStruct()); -} - -void ArrayDimensionsStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool ArrayDimensionsStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - ArrayDimensionsStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - ArrayDimensionsStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || ArrayDimensionsStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -ArraySizeStructPubSubType::ArraySizeStructPubSubType() -{ - setName("ArraySizeStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(ArraySizeStruct::getMaxCdrSerializedSize()); -#else - ArraySizeStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = ArraySizeStruct_max_key_cdr_typesize > 16 ? ArraySizeStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -ArraySizeStructPubSubType::~ArraySizeStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool ArraySizeStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - ArraySizeStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool ArraySizeStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - ArraySizeStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function ArraySizeStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* ArraySizeStructPubSubType::createData() -{ - return reinterpret_cast(new ArraySizeStruct()); -} - -void ArraySizeStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool ArraySizeStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - ArraySizeStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - ArraySizeStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || ArraySizeStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - - - -SequenceStructPubSubType::SequenceStructPubSubType() -{ - setName("SequenceStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(SequenceStruct::getMaxCdrSerializedSize()); -#else - SequenceStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = SequenceStruct_max_key_cdr_typesize > 16 ? SequenceStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -SequenceStructPubSubType::~SequenceStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool SequenceStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - SequenceStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool SequenceStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - SequenceStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function SequenceStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* SequenceStructPubSubType::createData() -{ - return reinterpret_cast(new SequenceStruct()); -} - -void SequenceStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool SequenceStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - SequenceStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - SequenceStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || SequenceStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - - - -SequenceStructEqualPubSubType::SequenceStructEqualPubSubType() -{ - setName("SequenceStructEqual"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(SequenceStructEqual::getMaxCdrSerializedSize()); -#else - SequenceStructEqual_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = SequenceStructEqual_max_key_cdr_typesize > 16 ? SequenceStructEqual_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -SequenceStructEqualPubSubType::~SequenceStructEqualPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool SequenceStructEqualPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - SequenceStructEqual* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool SequenceStructEqualPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - SequenceStructEqual* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function SequenceStructEqualPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* SequenceStructEqualPubSubType::createData() -{ - return reinterpret_cast(new SequenceStructEqual()); -} - -void SequenceStructEqualPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool SequenceStructEqualPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - SequenceStructEqual* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - SequenceStructEqual_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || SequenceStructEqual_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - - - -SequenceBadStructPubSubType::SequenceBadStructPubSubType() -{ - setName("SequenceBadStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(SequenceBadStruct::getMaxCdrSerializedSize()); -#else - SequenceBadStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = SequenceBadStruct_max_key_cdr_typesize > 16 ? SequenceBadStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -SequenceBadStructPubSubType::~SequenceBadStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool SequenceBadStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - SequenceBadStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool SequenceBadStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - SequenceBadStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function SequenceBadStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* SequenceBadStructPubSubType::createData() -{ - return reinterpret_cast(new SequenceBadStruct()); -} - -void SequenceBadStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool SequenceBadStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - SequenceBadStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - SequenceBadStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || SequenceBadStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - - - -SequenceBoundsStructPubSubType::SequenceBoundsStructPubSubType() -{ - setName("SequenceBoundsStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(SequenceBoundsStruct::getMaxCdrSerializedSize()); -#else - SequenceBoundsStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = SequenceBoundsStruct_max_key_cdr_typesize > 16 ? SequenceBoundsStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -SequenceBoundsStructPubSubType::~SequenceBoundsStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool SequenceBoundsStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - SequenceBoundsStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool SequenceBoundsStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - SequenceBoundsStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function SequenceBoundsStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* SequenceBoundsStructPubSubType::createData() -{ - return reinterpret_cast(new SequenceBoundsStruct()); -} - -void SequenceBoundsStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool SequenceBoundsStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - SequenceBoundsStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - SequenceBoundsStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || SequenceBoundsStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - - - - - -SequenceSequenceStructPubSubType::SequenceSequenceStructPubSubType() -{ - setName("SequenceSequenceStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(SequenceSequenceStruct::getMaxCdrSerializedSize()); -#else - SequenceSequenceStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = SequenceSequenceStruct_max_key_cdr_typesize > 16 ? SequenceSequenceStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -SequenceSequenceStructPubSubType::~SequenceSequenceStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool SequenceSequenceStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - SequenceSequenceStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool SequenceSequenceStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - SequenceSequenceStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function SequenceSequenceStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* SequenceSequenceStructPubSubType::createData() -{ - return reinterpret_cast(new SequenceSequenceStruct()); -} - -void SequenceSequenceStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool SequenceSequenceStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - SequenceSequenceStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - SequenceSequenceStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || SequenceSequenceStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - - - - - -SequenceSequenceBoundsStructPubSubType::SequenceSequenceBoundsStructPubSubType() -{ - setName("SequenceSequenceBoundsStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(SequenceSequenceBoundsStruct::getMaxCdrSerializedSize()); -#else - SequenceSequenceBoundsStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = SequenceSequenceBoundsStruct_max_key_cdr_typesize > 16 ? SequenceSequenceBoundsStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -SequenceSequenceBoundsStructPubSubType::~SequenceSequenceBoundsStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool SequenceSequenceBoundsStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - SequenceSequenceBoundsStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool SequenceSequenceBoundsStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - SequenceSequenceBoundsStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function SequenceSequenceBoundsStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* SequenceSequenceBoundsStructPubSubType::createData() -{ - return reinterpret_cast(new SequenceSequenceBoundsStruct()); -} - -void SequenceSequenceBoundsStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool SequenceSequenceBoundsStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - SequenceSequenceBoundsStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - SequenceSequenceBoundsStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || SequenceSequenceBoundsStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - - - -MapStructPubSubType::MapStructPubSubType() -{ - setName("MapStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(MapStruct::getMaxCdrSerializedSize()); -#else - MapStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = MapStruct_max_key_cdr_typesize > 16 ? MapStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -MapStructPubSubType::~MapStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool MapStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - MapStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool MapStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - MapStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function MapStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* MapStructPubSubType::createData() -{ - return reinterpret_cast(new MapStruct()); -} - -void MapStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool MapStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - MapStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - MapStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || MapStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - - - -MapStructEqualPubSubType::MapStructEqualPubSubType() -{ - setName("MapStructEqual"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(MapStructEqual::getMaxCdrSerializedSize()); -#else - MapStructEqual_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = MapStructEqual_max_key_cdr_typesize > 16 ? MapStructEqual_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -MapStructEqualPubSubType::~MapStructEqualPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool MapStructEqualPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - MapStructEqual* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool MapStructEqualPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - MapStructEqual* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function MapStructEqualPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* MapStructEqualPubSubType::createData() -{ - return reinterpret_cast(new MapStructEqual()); -} - -void MapStructEqualPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool MapStructEqualPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - MapStructEqual* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - MapStructEqual_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || MapStructEqual_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - - - -MapBadKeyStructPubSubType::MapBadKeyStructPubSubType() -{ - setName("MapBadKeyStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(MapBadKeyStruct::getMaxCdrSerializedSize()); -#else - MapBadKeyStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = MapBadKeyStruct_max_key_cdr_typesize > 16 ? MapBadKeyStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -MapBadKeyStructPubSubType::~MapBadKeyStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool MapBadKeyStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - MapBadKeyStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool MapBadKeyStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - MapBadKeyStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function MapBadKeyStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* MapBadKeyStructPubSubType::createData() -{ - return reinterpret_cast(new MapBadKeyStruct()); -} - -void MapBadKeyStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool MapBadKeyStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - MapBadKeyStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - MapBadKeyStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || MapBadKeyStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - - - -MapBadElemStructPubSubType::MapBadElemStructPubSubType() -{ - setName("MapBadElemStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(MapBadElemStruct::getMaxCdrSerializedSize()); -#else - MapBadElemStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = MapBadElemStruct_max_key_cdr_typesize > 16 ? MapBadElemStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -MapBadElemStructPubSubType::~MapBadElemStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool MapBadElemStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - MapBadElemStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool MapBadElemStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - MapBadElemStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function MapBadElemStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* MapBadElemStructPubSubType::createData() -{ - return reinterpret_cast(new MapBadElemStruct()); -} - -void MapBadElemStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool MapBadElemStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - MapBadElemStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - MapBadElemStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || MapBadElemStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - - - -MapBoundsStructPubSubType::MapBoundsStructPubSubType() -{ - setName("MapBoundsStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(MapBoundsStruct::getMaxCdrSerializedSize()); -#else - MapBoundsStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = MapBoundsStruct_max_key_cdr_typesize > 16 ? MapBoundsStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -MapBoundsStructPubSubType::~MapBoundsStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool MapBoundsStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - MapBoundsStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool MapBoundsStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - MapBoundsStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function MapBoundsStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* MapBoundsStructPubSubType::createData() -{ - return reinterpret_cast(new MapBoundsStruct()); -} - -void MapBoundsStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool MapBoundsStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - MapBoundsStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - MapBoundsStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || MapBoundsStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - - - - - -MapMapStructPubSubType::MapMapStructPubSubType() -{ - setName("MapMapStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(MapMapStruct::getMaxCdrSerializedSize()); -#else - MapMapStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = MapMapStruct_max_key_cdr_typesize > 16 ? MapMapStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -MapMapStructPubSubType::~MapMapStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool MapMapStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - MapMapStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool MapMapStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - MapMapStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function MapMapStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* MapMapStructPubSubType::createData() -{ - return reinterpret_cast(new MapMapStruct()); -} - -void MapMapStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool MapMapStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - MapMapStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - MapMapStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || MapMapStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - - - - - -MapMapBoundsStructPubSubType::MapMapBoundsStructPubSubType() -{ - setName("MapMapBoundsStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(MapMapBoundsStruct::getMaxCdrSerializedSize()); -#else - MapMapBoundsStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = MapMapBoundsStruct_max_key_cdr_typesize > 16 ? MapMapBoundsStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -MapMapBoundsStructPubSubType::~MapMapBoundsStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool MapMapBoundsStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - MapMapBoundsStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool MapMapBoundsStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - MapMapBoundsStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function MapMapBoundsStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* MapMapBoundsStructPubSubType::createData() -{ - return reinterpret_cast(new MapMapBoundsStruct()); -} - -void MapMapBoundsStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool MapMapBoundsStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - MapMapBoundsStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - MapMapBoundsStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || MapMapBoundsStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - - - - - - - - - - - - - - - - - - - - - -SimpleUnionStructPubSubType::SimpleUnionStructPubSubType() -{ - setName("SimpleUnionStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(SimpleUnionStruct::getMaxCdrSerializedSize()); -#else - SimpleUnionStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = SimpleUnionStruct_max_key_cdr_typesize > 16 ? SimpleUnionStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -SimpleUnionStructPubSubType::~SimpleUnionStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool SimpleUnionStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - SimpleUnionStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool SimpleUnionStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - SimpleUnionStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function SimpleUnionStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* SimpleUnionStructPubSubType::createData() -{ - return reinterpret_cast(new SimpleUnionStruct()); -} - -void SimpleUnionStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool SimpleUnionStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - SimpleUnionStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - SimpleUnionStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || SimpleUnionStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -SimpleUnionStructEqualPubSubType::SimpleUnionStructEqualPubSubType() -{ - setName("SimpleUnionStructEqual"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(SimpleUnionStructEqual::getMaxCdrSerializedSize()); -#else - SimpleUnionStructEqual_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = SimpleUnionStructEqual_max_key_cdr_typesize > 16 ? SimpleUnionStructEqual_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -SimpleUnionStructEqualPubSubType::~SimpleUnionStructEqualPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool SimpleUnionStructEqualPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - SimpleUnionStructEqual* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool SimpleUnionStructEqualPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - SimpleUnionStructEqual* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function SimpleUnionStructEqualPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* SimpleUnionStructEqualPubSubType::createData() -{ - return reinterpret_cast(new SimpleUnionStructEqual()); -} - -void SimpleUnionStructEqualPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool SimpleUnionStructEqualPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - SimpleUnionStructEqual* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - SimpleUnionStructEqual_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || SimpleUnionStructEqual_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -SimpleUnionNamesStructPubSubType::SimpleUnionNamesStructPubSubType() -{ - setName("SimpleUnionNamesStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(SimpleUnionNamesStruct::getMaxCdrSerializedSize()); -#else - SimpleUnionNamesStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = SimpleUnionNamesStruct_max_key_cdr_typesize > 16 ? SimpleUnionNamesStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -SimpleUnionNamesStructPubSubType::~SimpleUnionNamesStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool SimpleUnionNamesStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - SimpleUnionNamesStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool SimpleUnionNamesStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - SimpleUnionNamesStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function SimpleUnionNamesStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* SimpleUnionNamesStructPubSubType::createData() -{ - return reinterpret_cast(new SimpleUnionNamesStruct()); -} - -void SimpleUnionNamesStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool SimpleUnionNamesStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - SimpleUnionNamesStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - SimpleUnionNamesStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || SimpleUnionNamesStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -SimpleTypeUnionStructPubSubType::SimpleTypeUnionStructPubSubType() -{ - setName("SimpleTypeUnionStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(SimpleTypeUnionStruct::getMaxCdrSerializedSize()); -#else - SimpleTypeUnionStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = SimpleTypeUnionStruct_max_key_cdr_typesize > 16 ? SimpleTypeUnionStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -SimpleTypeUnionStructPubSubType::~SimpleTypeUnionStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool SimpleTypeUnionStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - SimpleTypeUnionStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool SimpleTypeUnionStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - SimpleTypeUnionStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function SimpleTypeUnionStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* SimpleTypeUnionStructPubSubType::createData() -{ - return reinterpret_cast(new SimpleTypeUnionStruct()); -} - -void SimpleTypeUnionStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool SimpleTypeUnionStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - SimpleTypeUnionStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - SimpleTypeUnionStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || SimpleTypeUnionStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -SimpleBadUnionStructPubSubType::SimpleBadUnionStructPubSubType() -{ - setName("SimpleBadUnionStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(SimpleBadUnionStruct::getMaxCdrSerializedSize()); -#else - SimpleBadUnionStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = SimpleBadUnionStruct_max_key_cdr_typesize > 16 ? SimpleBadUnionStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -SimpleBadUnionStructPubSubType::~SimpleBadUnionStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool SimpleBadUnionStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - SimpleBadUnionStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool SimpleBadUnionStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - SimpleBadUnionStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function SimpleBadUnionStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* SimpleBadUnionStructPubSubType::createData() -{ - return reinterpret_cast(new SimpleBadUnionStruct()); -} - -void SimpleBadUnionStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool SimpleBadUnionStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - SimpleBadUnionStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - SimpleBadUnionStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || SimpleBadUnionStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - - - -SimplBadDiscUnionStructPubSubType::SimplBadDiscUnionStructPubSubType() -{ - setName("SimplBadDiscUnionStruct"); - uint32_t type_size = -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(SimplBadDiscUnionStruct::getMaxCdrSerializedSize()); -#else - SimplBadDiscUnionStruct_max_cdr_typesize; -#endif - type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ - m_typeSize = type_size + 4; /*encapsulation*/ - m_isGetKeyDefined = false; - uint32_t keyLength = SimplBadDiscUnionStruct_max_key_cdr_typesize > 16 ? SimplBadDiscUnionStruct_max_key_cdr_typesize : 16; - m_keyBuffer = reinterpret_cast(malloc(keyLength)); - memset(m_keyBuffer, 0, keyLength); -} - -SimplBadDiscUnionStructPubSubType::~SimplBadDiscUnionStructPubSubType() -{ - if (m_keyBuffer != nullptr) - { - free(m_keyBuffer); - } -} - -bool SimplBadDiscUnionStructPubSubType::serialize( - void* data, - SerializedPayload_t* payload, - DataRepresentationId_t data_representation) -{ - SimplBadDiscUnionStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->max_size); - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); - payload->encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; -#if FASTCDR_VERSION_MAJOR > 1 - ser.set_encoding_flag( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : - eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); -#endif // FASTCDR_VERSION_MAJOR > 1 - - try - { - // Serialize encapsulation - ser.serialize_encapsulation(); - // Serialize the object. - ser << *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - // Get the serialized length -#if FASTCDR_VERSION_MAJOR == 1 - payload->length = static_cast(ser.getSerializedDataLength()); -#else - payload->length = static_cast(ser.get_serialized_data_length()); -#endif // FASTCDR_VERSION_MAJOR == 1 - return true; -} - -bool SimplBadDiscUnionStructPubSubType::deserialize( - SerializedPayload_t* payload, - void* data) -{ - try - { - // Convert DATA to pointer of your type - SimplBadDiscUnionStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload->data), payload->length); - - // Object that deserializes the data. - eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN -#if FASTCDR_VERSION_MAJOR == 1 - , eprosima::fastcdr::Cdr::CdrType::DDS_CDR -#endif // FASTCDR_VERSION_MAJOR == 1 - ); - - // Deserialize encapsulation. - deser.read_encapsulation(); - payload->encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - // Deserialize the object. - deser >> *p_type; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return false; - } - - return true; -} - -std::function SimplBadDiscUnionStructPubSubType::getSerializedSizeProvider( - void* data, - DataRepresentationId_t data_representation) -{ - return [data, data_representation]() -> uint32_t - { -#if FASTCDR_VERSION_MAJOR == 1 - static_cast(data_representation); - return static_cast(type::getCdrSerializedSize(*static_cast(data))) + - 4u /*encapsulation*/; -#else - try - { - eprosima::fastcdr::CdrSizeCalculator calculator( - data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? - eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); - size_t current_alignment {0}; - return static_cast(calculator.calculate_serialized_size( - *static_cast(data), current_alignment)) + - 4u /*encapsulation*/; - } - catch (eprosima::fastcdr::exception::Exception& /*exception*/) - { - return 0; - } -#endif // FASTCDR_VERSION_MAJOR == 1 - }; -} - -void* SimplBadDiscUnionStructPubSubType::createData() -{ - return reinterpret_cast(new SimplBadDiscUnionStruct()); -} - -void SimplBadDiscUnionStructPubSubType::deleteData( - void* data) -{ - delete(reinterpret_cast(data)); -} - -bool SimplBadDiscUnionStructPubSubType::getKey( - void* data, - InstanceHandle_t* handle, - bool force_md5) -{ - if (!m_isGetKeyDefined) - { - return false; - } - - SimplBadDiscUnionStruct* p_type = static_cast(data); - - // Object that manages the raw buffer. - eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(m_keyBuffer), - SimplBadDiscUnionStruct_max_key_cdr_typesize); - - // Object that serializes the data. - eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv1); -#if FASTCDR_VERSION_MAJOR == 1 - p_type->serializeKey(ser); -#else - eprosima::fastcdr::serialize_key(ser, *p_type); -#endif // FASTCDR_VERSION_MAJOR == 1 - if (force_md5 || SimplBadDiscUnionStruct_max_key_cdr_typesize > 16) - { - m_md5.init(); -#if FASTCDR_VERSION_MAJOR == 1 - m_md5.update(m_keyBuffer, static_cast(ser.getSerializedDataLength())); -#else - m_md5.update(m_keyBuffer, static_cast(ser.get_serialized_data_length())); -#endif // FASTCDR_VERSION_MAJOR == 1 - m_md5.finalize(); - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_md5.digest[i]; - } - } - else - { - for (uint8_t i = 0; i < 16; ++i) - { - handle->value[i] = m_keyBuffer[i]; - } - } - return true; -} - diff --git a/test/xtypes/idl/TypesPubSubTypes.h b/test/xtypes/idl/TypesPubSubTypes.h deleted file mode 100644 index 6a934f82843..00000000000 --- a/test/xtypes/idl/TypesPubSubTypes.h +++ /dev/null @@ -1,3337 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file TypesPubSubTypes.h - * This header file contains the declaration of the serialization functions. - * - * This file was generated by the tool fastddsgen. - */ - - -#ifndef _FAST_DDS_GENERATED_TYPES_PUBSUBTYPES_H_ -#define _FAST_DDS_GENERATED_TYPES_PUBSUBTYPES_H_ - -#include -#include -#include -#include -#include - -#include "Types.h" - - -#if !defined(GEN_API_VER) || (GEN_API_VER != 2) -#error \ - Generated Types is not compatible with current installed Fast DDS. Please, regenerate it with fastddsgen. -#endif // GEN_API_VER - - - - -/*! - * @brief This class represents the TopicDataType of the type MyEnumStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MyEnumStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef MyEnumStruct type; - - eProsima_user_DllExport MyEnumStructPubSubType(); - - eProsima_user_DllExport ~MyEnumStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type MyBadEnumStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MyBadEnumStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef MyBadEnumStruct type; - - eProsima_user_DllExport MyBadEnumStructPubSubType(); - - eProsima_user_DllExport ~MyBadEnumStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; -typedef MyEnum MyAliasEnum; - - - -/*! - * @brief This class represents the TopicDataType of the type MyAliasEnumStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MyAliasEnumStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef MyAliasEnumStruct type; - - eProsima_user_DllExport MyAliasEnumStructPubSubType(); - - eProsima_user_DllExport ~MyAliasEnumStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type BasicStruct defined by the user in the IDL file. - * @ingroup Types - */ -class BasicStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef BasicStruct type; - - eProsima_user_DllExport BasicStructPubSubType(); - - eProsima_user_DllExport ~BasicStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type BasicNamesStruct defined by the user in the IDL file. - * @ingroup Types - */ -class BasicNamesStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef BasicNamesStruct type; - - eProsima_user_DllExport BasicNamesStructPubSubType(); - - eProsima_user_DllExport ~BasicNamesStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type BasicBadStruct defined by the user in the IDL file. - * @ingroup Types - */ -class BasicBadStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef BasicBadStruct type; - - eProsima_user_DllExport BasicBadStructPubSubType(); - - eProsima_user_DllExport ~BasicBadStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type BasicWideStruct defined by the user in the IDL file. - * @ingroup Types - */ -class BasicWideStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef BasicWideStruct type; - - eProsima_user_DllExport BasicWideStructPubSubType(); - - eProsima_user_DllExport ~BasicWideStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type BadBasicWideStruct defined by the user in the IDL file. - * @ingroup Types - */ -class BadBasicWideStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef BadBasicWideStruct type; - - eProsima_user_DllExport BadBasicWideStructPubSubType(); - - eProsima_user_DllExport ~BadBasicWideStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type StringStruct defined by the user in the IDL file. - * @ingroup Types - */ -class StringStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef StringStruct type; - - eProsima_user_DllExport StringStructPubSubType(); - - eProsima_user_DllExport ~StringStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type LargeStringStruct defined by the user in the IDL file. - * @ingroup Types - */ -class LargeStringStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef LargeStringStruct type; - - eProsima_user_DllExport LargeStringStructPubSubType(); - - eProsima_user_DllExport ~LargeStringStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type WStringStruct defined by the user in the IDL file. - * @ingroup Types - */ -class WStringStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef WStringStruct type; - - eProsima_user_DllExport WStringStructPubSubType(); - - eProsima_user_DllExport ~WStringStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type LargeWStringStruct defined by the user in the IDL file. - * @ingroup Types - */ -class LargeWStringStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef LargeWStringStruct type; - - eProsima_user_DllExport LargeWStringStructPubSubType(); - - eProsima_user_DllExport ~LargeWStringStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type ArrayStruct defined by the user in the IDL file. - * @ingroup Types - */ -class ArrayStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef ArrayStruct type; - - eProsima_user_DllExport ArrayStructPubSubType(); - - eProsima_user_DllExport ~ArrayStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type ArrayStructEqual defined by the user in the IDL file. - * @ingroup Types - */ -class ArrayStructEqualPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef ArrayStructEqual type; - - eProsima_user_DllExport ArrayStructEqualPubSubType(); - - eProsima_user_DllExport ~ArrayStructEqualPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type ArrayBadStruct defined by the user in the IDL file. - * @ingroup Types - */ -class ArrayBadStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef ArrayBadStruct type; - - eProsima_user_DllExport ArrayBadStructPubSubType(); - - eProsima_user_DllExport ~ArrayBadStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type ArrayDimensionsStruct defined by the user in the IDL file. - * @ingroup Types - */ -class ArrayDimensionsStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef ArrayDimensionsStruct type; - - eProsima_user_DllExport ArrayDimensionsStructPubSubType(); - - eProsima_user_DllExport ~ArrayDimensionsStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type ArraySizeStruct defined by the user in the IDL file. - * @ingroup Types - */ -class ArraySizeStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef ArraySizeStruct type; - - eProsima_user_DllExport ArraySizeStructPubSubType(); - - eProsima_user_DllExport ~ArraySizeStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - - - -/*! - * @brief This class represents the TopicDataType of the type SequenceStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SequenceStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef SequenceStruct type; - - eProsima_user_DllExport SequenceStructPubSubType(); - - eProsima_user_DllExport ~SequenceStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - - - -/*! - * @brief This class represents the TopicDataType of the type SequenceStructEqual defined by the user in the IDL file. - * @ingroup Types - */ -class SequenceStructEqualPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef SequenceStructEqual type; - - eProsima_user_DllExport SequenceStructEqualPubSubType(); - - eProsima_user_DllExport ~SequenceStructEqualPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - - - -/*! - * @brief This class represents the TopicDataType of the type SequenceBadStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SequenceBadStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef SequenceBadStruct type; - - eProsima_user_DllExport SequenceBadStructPubSubType(); - - eProsima_user_DllExport ~SequenceBadStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - - - -/*! - * @brief This class represents the TopicDataType of the type SequenceBoundsStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SequenceBoundsStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef SequenceBoundsStruct type; - - eProsima_user_DllExport SequenceBoundsStructPubSubType(); - - eProsima_user_DllExport ~SequenceBoundsStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - - - - - -/*! - * @brief This class represents the TopicDataType of the type SequenceSequenceStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SequenceSequenceStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef SequenceSequenceStruct type; - - eProsima_user_DllExport SequenceSequenceStructPubSubType(); - - eProsima_user_DllExport ~SequenceSequenceStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - - - - - -/*! - * @brief This class represents the TopicDataType of the type SequenceSequenceBoundsStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SequenceSequenceBoundsStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef SequenceSequenceBoundsStruct type; - - eProsima_user_DllExport SequenceSequenceBoundsStructPubSubType(); - - eProsima_user_DllExport ~SequenceSequenceBoundsStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - - - -/*! - * @brief This class represents the TopicDataType of the type MapStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MapStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef MapStruct type; - - eProsima_user_DllExport MapStructPubSubType(); - - eProsima_user_DllExport ~MapStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - - - -/*! - * @brief This class represents the TopicDataType of the type MapStructEqual defined by the user in the IDL file. - * @ingroup Types - */ -class MapStructEqualPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef MapStructEqual type; - - eProsima_user_DllExport MapStructEqualPubSubType(); - - eProsima_user_DllExport ~MapStructEqualPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - - - -/*! - * @brief This class represents the TopicDataType of the type MapBadKeyStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MapBadKeyStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef MapBadKeyStruct type; - - eProsima_user_DllExport MapBadKeyStructPubSubType(); - - eProsima_user_DllExport ~MapBadKeyStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - - - -/*! - * @brief This class represents the TopicDataType of the type MapBadElemStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MapBadElemStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef MapBadElemStruct type; - - eProsima_user_DllExport MapBadElemStructPubSubType(); - - eProsima_user_DllExport ~MapBadElemStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - - - -/*! - * @brief This class represents the TopicDataType of the type MapBoundsStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MapBoundsStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef MapBoundsStruct type; - - eProsima_user_DllExport MapBoundsStructPubSubType(); - - eProsima_user_DllExport ~MapBoundsStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - - - - - -/*! - * @brief This class represents the TopicDataType of the type MapMapStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MapMapStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef MapMapStruct type; - - eProsima_user_DllExport MapMapStructPubSubType(); - - eProsima_user_DllExport ~MapMapStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - - - - - -/*! - * @brief This class represents the TopicDataType of the type MapMapBoundsStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MapMapBoundsStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef MapMapBoundsStruct type; - - eProsima_user_DllExport MapMapBoundsStructPubSubType(); - - eProsima_user_DllExport ~MapMapBoundsStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - - - - - - - - - - - - - - - - - - - - - -/*! - * @brief This class represents the TopicDataType of the type SimpleUnionStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SimpleUnionStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef SimpleUnionStruct type; - - eProsima_user_DllExport SimpleUnionStructPubSubType(); - - eProsima_user_DllExport ~SimpleUnionStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type SimpleUnionStructEqual defined by the user in the IDL file. - * @ingroup Types - */ -class SimpleUnionStructEqualPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef SimpleUnionStructEqual type; - - eProsima_user_DllExport SimpleUnionStructEqualPubSubType(); - - eProsima_user_DllExport ~SimpleUnionStructEqualPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type SimpleUnionNamesStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SimpleUnionNamesStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef SimpleUnionNamesStruct type; - - eProsima_user_DllExport SimpleUnionNamesStructPubSubType(); - - eProsima_user_DllExport ~SimpleUnionNamesStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type SimpleTypeUnionStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SimpleTypeUnionStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef SimpleTypeUnionStruct type; - - eProsima_user_DllExport SimpleTypeUnionStructPubSubType(); - - eProsima_user_DllExport ~SimpleTypeUnionStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type SimpleBadUnionStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SimpleBadUnionStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef SimpleBadUnionStruct type; - - eProsima_user_DllExport SimpleBadUnionStructPubSubType(); - - eProsima_user_DllExport ~SimpleBadUnionStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - - - -/*! - * @brief This class represents the TopicDataType of the type SimplBadDiscUnionStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SimplBadDiscUnionStructPubSubType : public eprosima::fastdds::dds::TopicDataType -{ -public: - - typedef SimplBadDiscUnionStruct type; - - eProsima_user_DllExport SimplBadDiscUnionStructPubSubType(); - - eProsima_user_DllExport ~SimplBadDiscUnionStructPubSubType() override; - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload) override - { - return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport bool serialize( - void* data, - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool deserialize( - eprosima::fastrtps::rtps::SerializedPayload_t* payload, - void* data) override; - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data) override - { - return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); - } - - eProsima_user_DllExport std::function getSerializedSizeProvider( - void* data, - eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; - - eProsima_user_DllExport bool getKey( - void* data, - eprosima::fastrtps::rtps::InstanceHandle_t* ihandle, - bool force_md5 = false) override; - - eProsima_user_DllExport void* createData() override; - - eProsima_user_DllExport void deleteData( - void* data) override; - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - eProsima_user_DllExport inline bool is_bounded() const override - { - return true; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED - -#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - eProsima_user_DllExport inline bool is_plain() const override - { - return false; - } - - eProsima_user_DllExport inline bool is_plain( - eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override - { - static_cast(data_representation); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN - -#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - eProsima_user_DllExport inline bool construct_sample( - void* memory) const override - { - static_cast(memory); - return false; - } - -#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE - - MD5 m_md5; - unsigned char* m_keyBuffer; - -}; - -#endif // _FAST_DDS_GENERATED_TYPES_PUBSUBTYPES_H_ - diff --git a/test/xtypes/idl/TypesTypeObject.cxx b/test/xtypes/idl/TypesTypeObject.cxx deleted file mode 100644 index bcefed47249..00000000000 --- a/test/xtypes/idl/TypesTypeObject.cxx +++ /dev/null @@ -1,8988 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file TypesTypeObject.cpp - * This source file contains the definition of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { char dummy; } -#endif - -#include "Types.h" -#include "TypesTypeObject.h" -#include -#include -#include -#include -#include -#include -#include -#include -#include - -using namespace eprosima::fastrtps::rtps; - -void registerTypesTypes() -{ - static std::once_flag once_flag; - std::call_once(once_flag, []() - { - TypeObjectFactory *factory = TypeObjectFactory::get_instance(); - factory->add_type_object("MyEnum", GetMyEnumIdentifier(true), - GetMyEnumObject(true)); - factory->add_type_object("MyEnum", GetMyEnumIdentifier(false), - GetMyEnumObject(false)); - - - factory->add_type_object("MyBadEnum", GetMyBadEnumIdentifier(true), - GetMyBadEnumObject(true)); - factory->add_type_object("MyBadEnum", GetMyBadEnumIdentifier(false), - GetMyBadEnumObject(false)); - - - factory->add_type_object("MyEnumStruct", GetMyEnumStructIdentifier(true), - GetMyEnumStructObject(true)); - factory->add_type_object("MyEnumStruct", GetMyEnumStructIdentifier(false), - GetMyEnumStructObject(false)); - - - factory->add_type_object("MyBadEnumStruct", GetMyBadEnumStructIdentifier(true), - GetMyBadEnumStructObject(true)); - factory->add_type_object("MyBadEnumStruct", GetMyBadEnumStructIdentifier(false), - GetMyBadEnumStructObject(false)); - - - factory->add_type_object("MyAliasEnum", GetMyAliasEnumIdentifier(true), - GetMyAliasEnumObject(true)); - factory->add_type_object("MyAliasEnum", GetMyAliasEnumIdentifier(false), - GetMyAliasEnumObject(false)); - - - factory->add_type_object("MyAliasEnumStruct", GetMyAliasEnumStructIdentifier(true), - GetMyAliasEnumStructObject(true)); - factory->add_type_object("MyAliasEnumStruct", GetMyAliasEnumStructIdentifier(false), - GetMyAliasEnumStructObject(false)); - - - factory->add_type_object("BasicStruct", GetBasicStructIdentifier(true), - GetBasicStructObject(true)); - factory->add_type_object("BasicStruct", GetBasicStructIdentifier(false), - GetBasicStructObject(false)); - - - factory->add_type_object("BasicNamesStruct", GetBasicNamesStructIdentifier(true), - GetBasicNamesStructObject(true)); - factory->add_type_object("BasicNamesStruct", GetBasicNamesStructIdentifier(false), - GetBasicNamesStructObject(false)); - - - factory->add_type_object("BasicBadStruct", GetBasicBadStructIdentifier(true), - GetBasicBadStructObject(true)); - factory->add_type_object("BasicBadStruct", GetBasicBadStructIdentifier(false), - GetBasicBadStructObject(false)); - - - factory->add_type_object("BasicWideStruct", GetBasicWideStructIdentifier(true), - GetBasicWideStructObject(true)); - factory->add_type_object("BasicWideStruct", GetBasicWideStructIdentifier(false), - GetBasicWideStructObject(false)); - - - factory->add_type_object("BadBasicWideStruct", GetBadBasicWideStructIdentifier(true), - GetBadBasicWideStructObject(true)); - factory->add_type_object("BadBasicWideStruct", GetBadBasicWideStructIdentifier(false), - GetBadBasicWideStructObject(false)); - - - factory->add_type_object("StringStruct", GetStringStructIdentifier(true), - GetStringStructObject(true)); - factory->add_type_object("StringStruct", GetStringStructIdentifier(false), - GetStringStructObject(false)); - - - factory->add_type_object("LargeStringStruct", GetLargeStringStructIdentifier(true), - GetLargeStringStructObject(true)); - factory->add_type_object("LargeStringStruct", GetLargeStringStructIdentifier(false), - GetLargeStringStructObject(false)); - - - factory->add_type_object("WStringStruct", GetWStringStructIdentifier(true), - GetWStringStructObject(true)); - factory->add_type_object("WStringStruct", GetWStringStructIdentifier(false), - GetWStringStructObject(false)); - - - factory->add_type_object("LargeWStringStruct", GetLargeWStringStructIdentifier(true), - GetLargeWStringStructObject(true)); - factory->add_type_object("LargeWStringStruct", GetLargeWStringStructIdentifier(false), - GetLargeWStringStructObject(false)); - - - factory->add_type_object("ArrayStruct", GetArrayStructIdentifier(true), - GetArrayStructObject(true)); - factory->add_type_object("ArrayStruct", GetArrayStructIdentifier(false), - GetArrayStructObject(false)); - - - factory->add_type_object("ArrayStructEqual", GetArrayStructEqualIdentifier(true), - GetArrayStructEqualObject(true)); - factory->add_type_object("ArrayStructEqual", GetArrayStructEqualIdentifier(false), - GetArrayStructEqualObject(false)); - - - factory->add_type_object("ArrayBadStruct", GetArrayBadStructIdentifier(true), - GetArrayBadStructObject(true)); - factory->add_type_object("ArrayBadStruct", GetArrayBadStructIdentifier(false), - GetArrayBadStructObject(false)); - - - factory->add_type_object("ArrayDimensionsStruct", GetArrayDimensionsStructIdentifier(true), - GetArrayDimensionsStructObject(true)); - factory->add_type_object("ArrayDimensionsStruct", GetArrayDimensionsStructIdentifier(false), - GetArrayDimensionsStructObject(false)); - - - factory->add_type_object("ArraySizeStruct", GetArraySizeStructIdentifier(true), - GetArraySizeStructObject(true)); - factory->add_type_object("ArraySizeStruct", GetArraySizeStructIdentifier(false), - GetArraySizeStructObject(false)); - - - factory->add_type_object("SequenceStruct", GetSequenceStructIdentifier(true), - GetSequenceStructObject(true)); - factory->add_type_object("SequenceStruct", GetSequenceStructIdentifier(false), - GetSequenceStructObject(false)); - - - factory->add_type_object("SequenceStructEqual", GetSequenceStructEqualIdentifier(true), - GetSequenceStructEqualObject(true)); - factory->add_type_object("SequenceStructEqual", GetSequenceStructEqualIdentifier(false), - GetSequenceStructEqualObject(false)); - - - factory->add_type_object("SequenceBadStruct", GetSequenceBadStructIdentifier(true), - GetSequenceBadStructObject(true)); - factory->add_type_object("SequenceBadStruct", GetSequenceBadStructIdentifier(false), - GetSequenceBadStructObject(false)); - - - factory->add_type_object("SequenceBoundsStruct", GetSequenceBoundsStructIdentifier(true), - GetSequenceBoundsStructObject(true)); - factory->add_type_object("SequenceBoundsStruct", GetSequenceBoundsStructIdentifier(false), - GetSequenceBoundsStructObject(false)); - - - factory->add_type_object("SequenceSequenceStruct", GetSequenceSequenceStructIdentifier(true), - GetSequenceSequenceStructObject(true)); - factory->add_type_object("SequenceSequenceStruct", GetSequenceSequenceStructIdentifier(false), - GetSequenceSequenceStructObject(false)); - - - factory->add_type_object("SequenceSequenceBoundsStruct", GetSequenceSequenceBoundsStructIdentifier(true), - GetSequenceSequenceBoundsStructObject(true)); - factory->add_type_object("SequenceSequenceBoundsStruct", GetSequenceSequenceBoundsStructIdentifier(false), - GetSequenceSequenceBoundsStructObject(false)); - - - factory->add_type_object("MapStruct", GetMapStructIdentifier(true), - GetMapStructObject(true)); - factory->add_type_object("MapStruct", GetMapStructIdentifier(false), - GetMapStructObject(false)); - - - factory->add_type_object("MapStructEqual", GetMapStructEqualIdentifier(true), - GetMapStructEqualObject(true)); - factory->add_type_object("MapStructEqual", GetMapStructEqualIdentifier(false), - GetMapStructEqualObject(false)); - - - factory->add_type_object("MapBadKeyStruct", GetMapBadKeyStructIdentifier(true), - GetMapBadKeyStructObject(true)); - factory->add_type_object("MapBadKeyStruct", GetMapBadKeyStructIdentifier(false), - GetMapBadKeyStructObject(false)); - - - factory->add_type_object("MapBadElemStruct", GetMapBadElemStructIdentifier(true), - GetMapBadElemStructObject(true)); - factory->add_type_object("MapBadElemStruct", GetMapBadElemStructIdentifier(false), - GetMapBadElemStructObject(false)); - - - factory->add_type_object("MapBoundsStruct", GetMapBoundsStructIdentifier(true), - GetMapBoundsStructObject(true)); - factory->add_type_object("MapBoundsStruct", GetMapBoundsStructIdentifier(false), - GetMapBoundsStructObject(false)); - - - factory->add_type_object("MapMapStruct", GetMapMapStructIdentifier(true), - GetMapMapStructObject(true)); - factory->add_type_object("MapMapStruct", GetMapMapStructIdentifier(false), - GetMapMapStructObject(false)); - - - factory->add_type_object("MapMapBoundsStruct", GetMapMapBoundsStructIdentifier(true), - GetMapMapBoundsStructObject(true)); - factory->add_type_object("MapMapBoundsStruct", GetMapMapBoundsStructIdentifier(false), - GetMapMapBoundsStructObject(false)); - - - factory->add_type_object("SimpleUnion", GetSimpleUnionIdentifier(true), - GetSimpleUnionObject(true)); - factory->add_type_object("SimpleUnion", GetSimpleUnionIdentifier(false), - GetSimpleUnionObject(false)); - - - factory->add_type_object("SimpleUnionNames", GetSimpleUnionNamesIdentifier(true), - GetSimpleUnionNamesObject(true)); - factory->add_type_object("SimpleUnionNames", GetSimpleUnionNamesIdentifier(false), - GetSimpleUnionNamesObject(false)); - - - factory->add_type_object("SimpleTypeUnion", GetSimpleTypeUnionIdentifier(true), - GetSimpleTypeUnionObject(true)); - factory->add_type_object("SimpleTypeUnion", GetSimpleTypeUnionIdentifier(false), - GetSimpleTypeUnionObject(false)); - - - factory->add_type_object("SimpleBadUnion", GetSimpleBadUnionIdentifier(true), - GetSimpleBadUnionObject(true)); - factory->add_type_object("SimpleBadUnion", GetSimpleBadUnionIdentifier(false), - GetSimpleBadUnionObject(false)); - - - factory->add_type_object("SimpleBadDiscUnion", GetSimpleBadDiscUnionIdentifier(true), - GetSimpleBadDiscUnionObject(true)); - factory->add_type_object("SimpleBadDiscUnion", GetSimpleBadDiscUnionIdentifier(false), - GetSimpleBadDiscUnionObject(false)); - - - factory->add_type_object("SimpleUnionStruct", GetSimpleUnionStructIdentifier(true), - GetSimpleUnionStructObject(true)); - factory->add_type_object("SimpleUnionStruct", GetSimpleUnionStructIdentifier(false), - GetSimpleUnionStructObject(false)); - - - factory->add_type_object("SimpleUnionStructEqual", GetSimpleUnionStructEqualIdentifier(true), - GetSimpleUnionStructEqualObject(true)); - factory->add_type_object("SimpleUnionStructEqual", GetSimpleUnionStructEqualIdentifier(false), - GetSimpleUnionStructEqualObject(false)); - - - factory->add_type_object("SimpleUnionNamesStruct", GetSimpleUnionNamesStructIdentifier(true), - GetSimpleUnionNamesStructObject(true)); - factory->add_type_object("SimpleUnionNamesStruct", GetSimpleUnionNamesStructIdentifier(false), - GetSimpleUnionNamesStructObject(false)); - - - factory->add_type_object("SimpleTypeUnionStruct", GetSimpleTypeUnionStructIdentifier(true), - GetSimpleTypeUnionStructObject(true)); - factory->add_type_object("SimpleTypeUnionStruct", GetSimpleTypeUnionStructIdentifier(false), - GetSimpleTypeUnionStructObject(false)); - - - factory->add_type_object("SimpleBadUnionStruct", GetSimpleBadUnionStructIdentifier(true), - GetSimpleBadUnionStructObject(true)); - factory->add_type_object("SimpleBadUnionStruct", GetSimpleBadUnionStructIdentifier(false), - GetSimpleBadUnionStructObject(false)); - - - factory->add_type_object("SimplBadDiscUnionStruct", GetSimplBadDiscUnionStructIdentifier(true), - GetSimplBadDiscUnionStructObject(true)); - factory->add_type_object("SimplBadDiscUnionStruct", GetSimplBadDiscUnionStructIdentifier(false), - GetSimplBadDiscUnionStructObject(false)); - - }); -} - -const TypeIdentifier* GetMyEnumIdentifier(bool complete) -{ - const TypeIdentifier* c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("MyEnum", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetMyEnumObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("MyEnum", complete); -} - -const TypeObject* GetMyEnumObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyEnum", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteMyEnumObject(); - } - // else - return GetMinimalMyEnumObject(); -} - -const TypeObject* GetMinimalMyEnumObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyEnum", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_ENUM); - - // No flags apply - //type_object->minimal().enumerated_type().enum_flags().IS_FINAL(false); - //type_object->minimal().enumerated_type().enum_flags().IS_APPENDABLE(false); - //type_object->minimal().enumerated_type().enum_flags().IS_MUTABLE(false); - //type_object->minimal().enumerated_type().enum_flags().IS_NESTED(false); - //type_object->minimal().enumerated_type().enum_flags().IS_AUTOID_HASH(false); - - type_object->minimal().enumerated_type().header().common().bit_bound(32); // TODO fixed by IDL, isn't? - - uint32_t value = 0; - MinimalEnumeratedLiteral mel_A; - mel_A.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - mel_A.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - mel_A.common().flags().IS_EXTERNAL(false); // Doesn't apply - mel_A.common().flags().IS_OPTIONAL(false); // Doesn't apply - mel_A.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mel_A.common().flags().IS_KEY(false); // Doesn't apply - mel_A.common().flags().IS_DEFAULT(false); - mel_A.common().value(value++); - MD5 A_hash("A"); - for(int i = 0; i < 4; ++i) - { - mel_A.detail().name_hash()[i] = A_hash.digest[i]; - } - type_object->minimal().enumerated_type().literal_seq().emplace_back(mel_A); - - MinimalEnumeratedLiteral mel_B; - mel_B.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - mel_B.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - mel_B.common().flags().IS_EXTERNAL(false); // Doesn't apply - mel_B.common().flags().IS_OPTIONAL(false); // Doesn't apply - mel_B.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mel_B.common().flags().IS_KEY(false); // Doesn't apply - mel_B.common().flags().IS_DEFAULT(false); - mel_B.common().value(value++); - MD5 B_hash("B"); - for(int i = 0; i < 4; ++i) - { - mel_B.detail().name_hash()[i] = B_hash.digest[i]; - } - type_object->minimal().enumerated_type().literal_seq().emplace_back(mel_B); - - MinimalEnumeratedLiteral mel_C; - mel_C.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - mel_C.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - mel_C.common().flags().IS_EXTERNAL(false); // Doesn't apply - mel_C.common().flags().IS_OPTIONAL(false); // Doesn't apply - mel_C.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mel_C.common().flags().IS_KEY(false); // Doesn't apply - mel_C.common().flags().IS_DEFAULT(false); - mel_C.common().value(value++); - MD5 C_hash("C"); - for(int i = 0; i < 4; ++i) - { - mel_C.detail().name_hash()[i] = C_hash.digest[i]; - } - type_object->minimal().enumerated_type().literal_seq().emplace_back(mel_C); - - - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().enumerated_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MyEnum", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyEnum", false); -} - -const TypeObject* GetCompleteMyEnumObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyEnum", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_ENUM); - - // No flags apply - //type_object->complete().enumerated_type().enum_flags().IS_FINAL(false); - //type_object->complete().enumerated_type().enum_flags().IS_APPENDABLE(false); - //type_object->complete().enumerated_type().enum_flags().IS_MUTABLE(false); - //type_object->complete().enumerated_type().enum_flags().IS_NESTED(false); - //type_object->complete().enumerated_type().enum_flags().IS_AUTOID_HASH(false); - - type_object->complete().enumerated_type().header().common().bit_bound(32); // TODO fixed by IDL, isn't? - type_object->complete().enumerated_type().header().detail().type_name("MyEnum"); - - uint32_t value = 0; - CompleteEnumeratedLiteral cel_A; - cel_A.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - cel_A.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - cel_A.common().flags().IS_EXTERNAL(false); // Doesn't apply - cel_A.common().flags().IS_OPTIONAL(false); // Doesn't apply - cel_A.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cel_A.common().flags().IS_KEY(false); // Doesn't apply - cel_A.common().flags().IS_DEFAULT(false); - cel_A.common().value(value++); - cel_A.detail().name("A"); - - type_object->complete().enumerated_type().literal_seq().emplace_back(cel_A); - - CompleteEnumeratedLiteral cel_B; - cel_B.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - cel_B.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - cel_B.common().flags().IS_EXTERNAL(false); // Doesn't apply - cel_B.common().flags().IS_OPTIONAL(false); // Doesn't apply - cel_B.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cel_B.common().flags().IS_KEY(false); // Doesn't apply - cel_B.common().flags().IS_DEFAULT(false); - cel_B.common().value(value++); - cel_B.detail().name("B"); - - type_object->complete().enumerated_type().literal_seq().emplace_back(cel_B); - - CompleteEnumeratedLiteral cel_C; - cel_C.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - cel_C.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - cel_C.common().flags().IS_EXTERNAL(false); // Doesn't apply - cel_C.common().flags().IS_OPTIONAL(false); // Doesn't apply - cel_C.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cel_C.common().flags().IS_KEY(false); // Doesn't apply - cel_C.common().flags().IS_DEFAULT(false); - cel_C.common().value(value++); - cel_C.detail().name("C"); - - type_object->complete().enumerated_type().literal_seq().emplace_back(cel_C); - - - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().enumerated_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MyEnum", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyEnum", true); -} - -const TypeIdentifier* GetMyBadEnumIdentifier(bool complete) -{ - const TypeIdentifier* c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("MyBadEnum", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetMyBadEnumObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("MyBadEnum", complete); -} - -const TypeObject* GetMyBadEnumObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyBadEnum", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteMyBadEnumObject(); - } - // else - return GetMinimalMyBadEnumObject(); -} - -const TypeObject* GetMinimalMyBadEnumObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyBadEnum", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_ENUM); - - // No flags apply - //type_object->minimal().enumerated_type().enum_flags().IS_FINAL(false); - //type_object->minimal().enumerated_type().enum_flags().IS_APPENDABLE(false); - //type_object->minimal().enumerated_type().enum_flags().IS_MUTABLE(false); - //type_object->minimal().enumerated_type().enum_flags().IS_NESTED(false); - //type_object->minimal().enumerated_type().enum_flags().IS_AUTOID_HASH(false); - - type_object->minimal().enumerated_type().header().common().bit_bound(32); // TODO fixed by IDL, isn't? - - uint32_t value = 0; - MinimalEnumeratedLiteral mel_A1; - mel_A1.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - mel_A1.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - mel_A1.common().flags().IS_EXTERNAL(false); // Doesn't apply - mel_A1.common().flags().IS_OPTIONAL(false); // Doesn't apply - mel_A1.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mel_A1.common().flags().IS_KEY(false); // Doesn't apply - mel_A1.common().flags().IS_DEFAULT(false); - mel_A1.common().value(value++); - MD5 A1_hash("A1"); - for(int i = 0; i < 4; ++i) - { - mel_A1.detail().name_hash()[i] = A1_hash.digest[i]; - } - type_object->minimal().enumerated_type().literal_seq().emplace_back(mel_A1); - - MinimalEnumeratedLiteral mel_B1; - mel_B1.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - mel_B1.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - mel_B1.common().flags().IS_EXTERNAL(false); // Doesn't apply - mel_B1.common().flags().IS_OPTIONAL(false); // Doesn't apply - mel_B1.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mel_B1.common().flags().IS_KEY(false); // Doesn't apply - mel_B1.common().flags().IS_DEFAULT(false); - mel_B1.common().value(value++); - MD5 B1_hash("B1"); - for(int i = 0; i < 4; ++i) - { - mel_B1.detail().name_hash()[i] = B1_hash.digest[i]; - } - type_object->minimal().enumerated_type().literal_seq().emplace_back(mel_B1); - - MinimalEnumeratedLiteral mel_C1; - mel_C1.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - mel_C1.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - mel_C1.common().flags().IS_EXTERNAL(false); // Doesn't apply - mel_C1.common().flags().IS_OPTIONAL(false); // Doesn't apply - mel_C1.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mel_C1.common().flags().IS_KEY(false); // Doesn't apply - mel_C1.common().flags().IS_DEFAULT(false); - mel_C1.common().value(value++); - MD5 C1_hash("C1"); - for(int i = 0; i < 4; ++i) - { - mel_C1.detail().name_hash()[i] = C1_hash.digest[i]; - } - type_object->minimal().enumerated_type().literal_seq().emplace_back(mel_C1); - - - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().enumerated_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MyBadEnum", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyBadEnum", false); -} - -const TypeObject* GetCompleteMyBadEnumObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyBadEnum", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_ENUM); - - // No flags apply - //type_object->complete().enumerated_type().enum_flags().IS_FINAL(false); - //type_object->complete().enumerated_type().enum_flags().IS_APPENDABLE(false); - //type_object->complete().enumerated_type().enum_flags().IS_MUTABLE(false); - //type_object->complete().enumerated_type().enum_flags().IS_NESTED(false); - //type_object->complete().enumerated_type().enum_flags().IS_AUTOID_HASH(false); - - type_object->complete().enumerated_type().header().common().bit_bound(32); // TODO fixed by IDL, isn't? - type_object->complete().enumerated_type().header().detail().type_name("MyBadEnum"); - - uint32_t value = 0; - CompleteEnumeratedLiteral cel_A1; - cel_A1.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - cel_A1.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - cel_A1.common().flags().IS_EXTERNAL(false); // Doesn't apply - cel_A1.common().flags().IS_OPTIONAL(false); // Doesn't apply - cel_A1.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cel_A1.common().flags().IS_KEY(false); // Doesn't apply - cel_A1.common().flags().IS_DEFAULT(false); - cel_A1.common().value(value++); - cel_A1.detail().name("A1"); - - type_object->complete().enumerated_type().literal_seq().emplace_back(cel_A1); - - CompleteEnumeratedLiteral cel_B1; - cel_B1.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - cel_B1.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - cel_B1.common().flags().IS_EXTERNAL(false); // Doesn't apply - cel_B1.common().flags().IS_OPTIONAL(false); // Doesn't apply - cel_B1.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cel_B1.common().flags().IS_KEY(false); // Doesn't apply - cel_B1.common().flags().IS_DEFAULT(false); - cel_B1.common().value(value++); - cel_B1.detail().name("B1"); - - type_object->complete().enumerated_type().literal_seq().emplace_back(cel_B1); - - CompleteEnumeratedLiteral cel_C1; - cel_C1.common().flags().TRY_CONSTRUCT1(false); // Doesn't apply - cel_C1.common().flags().TRY_CONSTRUCT2(false); // Doesn't apply - cel_C1.common().flags().IS_EXTERNAL(false); // Doesn't apply - cel_C1.common().flags().IS_OPTIONAL(false); // Doesn't apply - cel_C1.common().flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cel_C1.common().flags().IS_KEY(false); // Doesn't apply - cel_C1.common().flags().IS_DEFAULT(false); - cel_C1.common().value(value++); - cel_C1.detail().name("C1"); - - type_object->complete().enumerated_type().literal_seq().emplace_back(cel_C1); - - - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().enumerated_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MyBadEnum", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyBadEnum", true); -} - - - -const TypeIdentifier* GetMyEnumStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("MyEnumStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetMyEnumStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("MyEnumStruct", complete); -} - -const TypeObject* GetMyEnumStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyEnumStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteMyEnumStructObject(); - } - //else - return GetMinimalMyEnumStructObject(); -} - -const TypeObject* GetMinimalMyEnumStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyEnumStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_enum; - mst_my_enum.common().member_id(memberId++); - mst_my_enum.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_enum.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_enum.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_enum.common().member_flags().IS_OPTIONAL(false); - mst_my_enum.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_enum.common().member_flags().IS_KEY(false); - mst_my_enum.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_enum.common().member_type_id(*GetMyEnumIdentifier(false)); - - MD5 my_enum_hash("my_enum"); - for(int i = 0; i < 4; ++i) - { - mst_my_enum.detail().name_hash()[i] = my_enum_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_enum); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MyEnumStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyEnumStruct", false); -} - -const TypeObject* GetCompleteMyEnumStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyEnumStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_enum; - cst_my_enum.common().member_id(memberId++); - cst_my_enum.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_enum.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_enum.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_enum.common().member_flags().IS_OPTIONAL(false); - cst_my_enum.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_enum.common().member_flags().IS_KEY(false); - cst_my_enum.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_enum.common().member_type_id(*GetMyEnumIdentifier(true)); - - cst_my_enum.detail().name("my_enum"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_enum); - - - // Header - type_object->complete().struct_type().header().detail().type_name("MyEnumStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MyEnumStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyEnumStruct", true); -} - - - -const TypeIdentifier* GetMyBadEnumStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("MyBadEnumStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetMyBadEnumStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("MyBadEnumStruct", complete); -} - -const TypeObject* GetMyBadEnumStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyBadEnumStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteMyBadEnumStructObject(); - } - //else - return GetMinimalMyBadEnumStructObject(); -} - -const TypeObject* GetMinimalMyBadEnumStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyBadEnumStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_enum; - mst_my_enum.common().member_id(memberId++); - mst_my_enum.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_enum.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_enum.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_enum.common().member_flags().IS_OPTIONAL(false); - mst_my_enum.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_enum.common().member_flags().IS_KEY(false); - mst_my_enum.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_enum.common().member_type_id(*GetMyBadEnumIdentifier(false)); - - MD5 my_enum_hash("my_enum"); - for(int i = 0; i < 4; ++i) - { - mst_my_enum.detail().name_hash()[i] = my_enum_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_enum); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MyBadEnumStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyBadEnumStruct", false); -} - -const TypeObject* GetCompleteMyBadEnumStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyBadEnumStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_enum; - cst_my_enum.common().member_id(memberId++); - cst_my_enum.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_enum.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_enum.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_enum.common().member_flags().IS_OPTIONAL(false); - cst_my_enum.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_enum.common().member_flags().IS_KEY(false); - cst_my_enum.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_enum.common().member_type_id(*GetMyBadEnumIdentifier(true)); - - cst_my_enum.detail().name("my_enum"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_enum); - - - // Header - type_object->complete().struct_type().header().detail().type_name("MyBadEnumStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MyBadEnumStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyBadEnumStruct", true); -} - -const TypeIdentifier* GetMyAliasEnumIdentifier(bool complete) -{ - const TypeIdentifier* c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("MyAliasEnum", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetMyAliasEnumObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("MyAliasEnum", complete); -} - -const TypeObject* GetMyAliasEnumObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyAliasEnum", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteMyAliasEnumObject(); - } - else - { - return GetMinimalMyAliasEnumObject(); - } -} - -const TypeObject* GetMinimalMyAliasEnumObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyAliasEnum", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_ALIAS); - - // No flags apply - //type_object->minimal().alias_type().alias_flags().IS_FINAL(false); - //type_object->minimal().alias_type().alias_flags().IS_APPENDABLE(false); - //type_object->minimal().alias_type().alias_flags().IS_MUTABLE(false); - //type_object->minimal().alias_type().alias_flags().IS_NESTED(false); - //type_object->minimal().alias_type().alias_flags().IS_AUTOID_HASH(false); - - // type_object->minimal().alias_type().header()... Is empty - - // No flags apply - //type_object->minimal().alias_type().body().common().related_flags().TRY_CONSTRUCT1(false); - //type_object->minimal().alias_type().body().common().related_flags().TRY_CONSTRUCT2(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_EXTERNAL(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_OPTIONAL(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_MUST_UNDERSTAND(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_KEY(false); - //type_object->minimal().alias_type().body().common().related_flags().IS_DEFAULT(false); - - // Must be defined already, if don't, may be an recursive alias - const TypeIdentifier *relatedType = TypeObjectFactory::get_instance()->get_type_identifier("MyEnum", false); - - - if (relatedType != nullptr) - { - type_object->minimal().alias_type().body().common().related_type() = *relatedType; // Make a copy - } - else - { - // Cannot determine base type - delete type_object; - return nullptr; - } - - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().alias_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - // Don't add our TypeIdentifier but our alias - TypeObjectFactory::get_instance()->add_alias("MyAliasEnum", "MyEnum"); - - TypeObjectFactory::get_instance()->add_type_object("MyAliasEnum", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyAliasEnum", false); -} - -const TypeObject* GetCompleteMyAliasEnumObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyAliasEnum", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_ALIAS); - - // No flags apply - //type_object->complete().alias_type().alias_flags().IS_FINAL(false); - //type_object->complete().alias_type().alias_flags().IS_APPENDABLE(false); - //type_object->complete().alias_type().alias_flags().IS_MUTABLE(false); - //type_object->complete().alias_type().alias_flags().IS_NESTED(false); - //type_object->complete().alias_type().alias_flags().IS_AUTOID_HASH(false); - - //type_object->complete().alias_type().header().detail().ann_builtin().verbatim().placement("placement"); - //type_object->complete().alias_type().header().detail().ann_builtin().verbatim().language("language"); - //type_object->complete().alias_type().header().detail().ann_builtin().verbatim().text("text"); - //type_object->complete().alias_type().header().detail().ann_custom().push_back(...); - type_object->complete().alias_type().header().detail().type_name("MyAliasEnum"); - - // No flags apply - //type_object->complete().alias_type().body().common().related_flags().TRY_CONSTRUCT1(false); - //type_object->complete().alias_type().body().common().related_flags().TRY_CONSTRUCT2(false); - //type_object->complete().alias_type().body().common().related_flags().IS_EXTERNAL(false); - //type_object->complete().alias_type().body().common().related_flags().IS_OPTIONAL(false); - //type_object->complete().alias_type().body().common().related_flags().IS_MUST_UNDERSTAND(false); - //type_object->complete().alias_type().body().common().related_flags().IS_KEY(false); - //type_object->complete().alias_type().body().common().related_flags().IS_DEFAULT(false); - - //type_object->complete().alias_type().body().common().ann_builtin() - //type_object->complete().alias_type().body().common().ann_custom() - - // Must be defined already, if don't, may be an recursive alias - const TypeIdentifier *relatedType = TypeObjectFactory::get_instance()->get_type_identifier_trying_complete("MyEnum"); - - - if (relatedType != nullptr) - { - type_object->complete().alias_type().body().common().related_type() = *relatedType; // Make a copy - } - else - { - // Cannot determine base type - delete type_object; - return nullptr; - } - - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().alias_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - // Don't add our TypeIdentifier but our alias - TypeObjectFactory::get_instance()->add_alias("MyAliasEnum", "MyEnum"); - - TypeObjectFactory::get_instance()->add_type_object("MyAliasEnum", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyAliasEnum", true); -} - - - -const TypeIdentifier* GetMyAliasEnumStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("MyAliasEnumStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetMyAliasEnumStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("MyAliasEnumStruct", complete); -} - -const TypeObject* GetMyAliasEnumStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyAliasEnumStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteMyAliasEnumStructObject(); - } - //else - return GetMinimalMyAliasEnumStructObject(); -} - -const TypeObject* GetMinimalMyAliasEnumStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyAliasEnumStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_enum; - mst_my_enum.common().member_id(memberId++); - mst_my_enum.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_enum.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_enum.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_enum.common().member_flags().IS_OPTIONAL(false); - mst_my_enum.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_enum.common().member_flags().IS_KEY(false); - mst_my_enum.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_enum.common().member_type_id(*GetMyAliasEnumIdentifier(false)); - - MD5 my_enum_hash("my_enum"); - for(int i = 0; i < 4; ++i) - { - mst_my_enum.detail().name_hash()[i] = my_enum_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_enum); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MyAliasEnumStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyAliasEnumStruct", false); -} - -const TypeObject* GetCompleteMyAliasEnumStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MyAliasEnumStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_enum; - cst_my_enum.common().member_id(memberId++); - cst_my_enum.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_enum.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_enum.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_enum.common().member_flags().IS_OPTIONAL(false); - cst_my_enum.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_enum.common().member_flags().IS_KEY(false); - cst_my_enum.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_enum.common().member_type_id(*GetMyAliasEnumIdentifier(true)); - - cst_my_enum.detail().name("my_enum"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_enum); - - - // Header - type_object->complete().struct_type().header().detail().type_name("MyAliasEnumStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MyAliasEnumStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MyAliasEnumStruct", true); -} - - - -const TypeIdentifier* GetBasicStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("BasicStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetBasicStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("BasicStruct", complete); -} - -const TypeObject* GetBasicStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("BasicStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteBasicStructObject(); - } - //else - return GetMinimalBasicStructObject(); -} - -const TypeObject* GetMinimalBasicStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("BasicStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_bool; - mst_my_bool.common().member_id(memberId++); - mst_my_bool.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_bool.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_bool.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_bool.common().member_flags().IS_OPTIONAL(false); - mst_my_bool.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_bool.common().member_flags().IS_KEY(false); - mst_my_bool.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_bool.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("bool", false)); - - - MD5 my_bool_hash("my_bool"); - for(int i = 0; i < 4; ++i) - { - mst_my_bool.detail().name_hash()[i] = my_bool_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_bool); - - MinimalStructMember mst_my_int32; - mst_my_int32.common().member_id(memberId++); - mst_my_int32.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_int32.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_int32.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_int32.common().member_flags().IS_OPTIONAL(false); - mst_my_int32.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_int32.common().member_flags().IS_KEY(false); - mst_my_int32.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_int32.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - MD5 my_int32_hash("my_int32"); - for(int i = 0; i < 4; ++i) - { - mst_my_int32.detail().name_hash()[i] = my_int32_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_int32); - - MinimalStructMember mst_my_string; - mst_my_string.common().member_id(memberId++); - mst_my_string.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_string.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_string.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_string.common().member_flags().IS_OPTIONAL(false); - mst_my_string.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_string.common().member_flags().IS_KEY(false); - mst_my_string.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_string.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, false)); - - MD5 my_string_hash("my_string"); - for(int i = 0; i < 4; ++i) - { - mst_my_string.detail().name_hash()[i] = my_string_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_string); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("BasicStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("BasicStruct", false); -} - -const TypeObject* GetCompleteBasicStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("BasicStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_bool; - cst_my_bool.common().member_id(memberId++); - cst_my_bool.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_bool.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_bool.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_bool.common().member_flags().IS_OPTIONAL(false); - cst_my_bool.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_bool.common().member_flags().IS_KEY(false); - cst_my_bool.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_bool.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("bool", false)); - - - cst_my_bool.detail().name("my_bool"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_bool); - - CompleteStructMember cst_my_int32; - cst_my_int32.common().member_id(memberId++); - cst_my_int32.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_int32.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_int32.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_int32.common().member_flags().IS_OPTIONAL(false); - cst_my_int32.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_int32.common().member_flags().IS_KEY(false); - cst_my_int32.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_int32.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - cst_my_int32.detail().name("my_int32"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_int32); - - CompleteStructMember cst_my_string; - cst_my_string.common().member_id(memberId++); - cst_my_string.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_string.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_string.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_string.common().member_flags().IS_OPTIONAL(false); - cst_my_string.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_string.common().member_flags().IS_KEY(false); - cst_my_string.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_string.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, false)); - - cst_my_string.detail().name("my_string"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_string); - - - // Header - type_object->complete().struct_type().header().detail().type_name("BasicStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("BasicStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("BasicStruct", true); -} - - - -const TypeIdentifier* GetBasicNamesStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("BasicNamesStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetBasicNamesStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("BasicNamesStruct", complete); -} - -const TypeObject* GetBasicNamesStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("BasicNamesStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteBasicNamesStructObject(); - } - //else - return GetMinimalBasicNamesStructObject(); -} - -const TypeObject* GetMinimalBasicNamesStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("BasicNamesStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_bool_name; - mst_my_bool_name.common().member_id(memberId++); - mst_my_bool_name.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_bool_name.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_bool_name.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_bool_name.common().member_flags().IS_OPTIONAL(false); - mst_my_bool_name.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_bool_name.common().member_flags().IS_KEY(false); - mst_my_bool_name.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_bool_name.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("bool", false)); - - - MD5 my_bool_name_hash("my_bool_name"); - for(int i = 0; i < 4; ++i) - { - mst_my_bool_name.detail().name_hash()[i] = my_bool_name_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_bool_name); - - MinimalStructMember mst_my_int32_name; - mst_my_int32_name.common().member_id(memberId++); - mst_my_int32_name.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_int32_name.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_int32_name.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_int32_name.common().member_flags().IS_OPTIONAL(false); - mst_my_int32_name.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_int32_name.common().member_flags().IS_KEY(false); - mst_my_int32_name.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_int32_name.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - MD5 my_int32_name_hash("my_int32_name"); - for(int i = 0; i < 4; ++i) - { - mst_my_int32_name.detail().name_hash()[i] = my_int32_name_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_int32_name); - - MinimalStructMember mst_my_string_name; - mst_my_string_name.common().member_id(memberId++); - mst_my_string_name.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_string_name.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_string_name.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_string_name.common().member_flags().IS_OPTIONAL(false); - mst_my_string_name.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_string_name.common().member_flags().IS_KEY(false); - mst_my_string_name.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_string_name.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, false)); - - MD5 my_string_name_hash("my_string_name"); - for(int i = 0; i < 4; ++i) - { - mst_my_string_name.detail().name_hash()[i] = my_string_name_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_string_name); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("BasicNamesStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("BasicNamesStruct", false); -} - -const TypeObject* GetCompleteBasicNamesStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("BasicNamesStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_bool_name; - cst_my_bool_name.common().member_id(memberId++); - cst_my_bool_name.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_bool_name.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_bool_name.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_bool_name.common().member_flags().IS_OPTIONAL(false); - cst_my_bool_name.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_bool_name.common().member_flags().IS_KEY(false); - cst_my_bool_name.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_bool_name.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("bool", false)); - - - cst_my_bool_name.detail().name("my_bool_name"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_bool_name); - - CompleteStructMember cst_my_int32_name; - cst_my_int32_name.common().member_id(memberId++); - cst_my_int32_name.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_int32_name.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_int32_name.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_int32_name.common().member_flags().IS_OPTIONAL(false); - cst_my_int32_name.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_int32_name.common().member_flags().IS_KEY(false); - cst_my_int32_name.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_int32_name.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - cst_my_int32_name.detail().name("my_int32_name"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_int32_name); - - CompleteStructMember cst_my_string_name; - cst_my_string_name.common().member_id(memberId++); - cst_my_string_name.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_string_name.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_string_name.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_string_name.common().member_flags().IS_OPTIONAL(false); - cst_my_string_name.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_string_name.common().member_flags().IS_KEY(false); - cst_my_string_name.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_string_name.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, false)); - - cst_my_string_name.detail().name("my_string_name"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_string_name); - - - // Header - type_object->complete().struct_type().header().detail().type_name("BasicNamesStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("BasicNamesStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("BasicNamesStruct", true); -} - - - -const TypeIdentifier* GetBasicBadStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("BasicBadStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetBasicBadStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("BasicBadStruct", complete); -} - -const TypeObject* GetBasicBadStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("BasicBadStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteBasicBadStructObject(); - } - //else - return GetMinimalBasicBadStructObject(); -} - -const TypeObject* GetMinimalBasicBadStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("BasicBadStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_bool; - mst_my_bool.common().member_id(memberId++); - mst_my_bool.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_bool.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_bool.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_bool.common().member_flags().IS_OPTIONAL(false); - mst_my_bool.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_bool.common().member_flags().IS_KEY(false); - mst_my_bool.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_bool.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint8_t", false)); - - - MD5 my_bool_hash("my_bool"); - for(int i = 0; i < 4; ++i) - { - mst_my_bool.detail().name_hash()[i] = my_bool_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_bool); - - MinimalStructMember mst_my_int32; - mst_my_int32.common().member_id(memberId++); - mst_my_int32.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_int32.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_int32.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_int32.common().member_flags().IS_OPTIONAL(false); - mst_my_int32.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_int32.common().member_flags().IS_KEY(false); - mst_my_int32.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_int32.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - MD5 my_int32_hash("my_int32"); - for(int i = 0; i < 4; ++i) - { - mst_my_int32.detail().name_hash()[i] = my_int32_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_int32); - - MinimalStructMember mst_my_string; - mst_my_string.common().member_id(memberId++); - mst_my_string.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_string.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_string.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_string.common().member_flags().IS_OPTIONAL(false); - mst_my_string.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_string.common().member_flags().IS_KEY(false); - mst_my_string.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_string.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, false)); - - MD5 my_string_hash("my_string"); - for(int i = 0; i < 4; ++i) - { - mst_my_string.detail().name_hash()[i] = my_string_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_string); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("BasicBadStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("BasicBadStruct", false); -} - -const TypeObject* GetCompleteBasicBadStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("BasicBadStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_bool; - cst_my_bool.common().member_id(memberId++); - cst_my_bool.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_bool.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_bool.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_bool.common().member_flags().IS_OPTIONAL(false); - cst_my_bool.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_bool.common().member_flags().IS_KEY(false); - cst_my_bool.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_bool.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint8_t", false)); - - - cst_my_bool.detail().name("my_bool"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_bool); - - CompleteStructMember cst_my_int32; - cst_my_int32.common().member_id(memberId++); - cst_my_int32.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_int32.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_int32.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_int32.common().member_flags().IS_OPTIONAL(false); - cst_my_int32.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_int32.common().member_flags().IS_KEY(false); - cst_my_int32.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_int32.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - cst_my_int32.detail().name("my_int32"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_int32); - - CompleteStructMember cst_my_string; - cst_my_string.common().member_id(memberId++); - cst_my_string.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_string.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_string.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_string.common().member_flags().IS_OPTIONAL(false); - cst_my_string.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_string.common().member_flags().IS_KEY(false); - cst_my_string.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_string.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, false)); - - cst_my_string.detail().name("my_string"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_string); - - - // Header - type_object->complete().struct_type().header().detail().type_name("BasicBadStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("BasicBadStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("BasicBadStruct", true); -} - - - -const TypeIdentifier* GetBasicWideStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("BasicWideStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetBasicWideStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("BasicWideStruct", complete); -} - -const TypeObject* GetBasicWideStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("BasicWideStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteBasicWideStructObject(); - } - //else - return GetMinimalBasicWideStructObject(); -} - -const TypeObject* GetMinimalBasicWideStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("BasicWideStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_bool; - mst_my_bool.common().member_id(memberId++); - mst_my_bool.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_bool.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_bool.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_bool.common().member_flags().IS_OPTIONAL(false); - mst_my_bool.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_bool.common().member_flags().IS_KEY(false); - mst_my_bool.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_bool.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("bool", false)); - - - MD5 my_bool_hash("my_bool"); - for(int i = 0; i < 4; ++i) - { - mst_my_bool.detail().name_hash()[i] = my_bool_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_bool); - - MinimalStructMember mst_my_int32; - mst_my_int32.common().member_id(memberId++); - mst_my_int32.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_int32.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_int32.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_int32.common().member_flags().IS_OPTIONAL(false); - mst_my_int32.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_int32.common().member_flags().IS_KEY(false); - mst_my_int32.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_int32.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - MD5 my_int32_hash("my_int32"); - for(int i = 0; i < 4; ++i) - { - mst_my_int32.detail().name_hash()[i] = my_int32_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_int32); - - MinimalStructMember mst_my_string; - mst_my_string.common().member_id(memberId++); - mst_my_string.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_string.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_string.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_string.common().member_flags().IS_OPTIONAL(false); - mst_my_string.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_string.common().member_flags().IS_KEY(false); - mst_my_string.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_string.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, false)); - - MD5 my_string_hash("my_string"); - for(int i = 0; i < 4; ++i) - { - mst_my_string.detail().name_hash()[i] = my_string_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_string); - - MinimalStructMember mst_new_int32; - mst_new_int32.common().member_id(memberId++); - mst_new_int32.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_new_int32.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_new_int32.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_new_int32.common().member_flags().IS_OPTIONAL(false); - mst_new_int32.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_new_int32.common().member_flags().IS_KEY(false); - mst_new_int32.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_new_int32.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - MD5 new_int32_hash("new_int32"); - for(int i = 0; i < 4; ++i) - { - mst_new_int32.detail().name_hash()[i] = new_int32_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_new_int32); - - MinimalStructMember mst_new_string; - mst_new_string.common().member_id(memberId++); - mst_new_string.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_new_string.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_new_string.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_new_string.common().member_flags().IS_OPTIONAL(false); - mst_new_string.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_new_string.common().member_flags().IS_KEY(false); - mst_new_string.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_new_string.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, false)); - - MD5 new_string_hash("new_string"); - for(int i = 0; i < 4; ++i) - { - mst_new_string.detail().name_hash()[i] = new_string_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_new_string); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("BasicWideStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("BasicWideStruct", false); -} - -const TypeObject* GetCompleteBasicWideStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("BasicWideStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_bool; - cst_my_bool.common().member_id(memberId++); - cst_my_bool.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_bool.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_bool.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_bool.common().member_flags().IS_OPTIONAL(false); - cst_my_bool.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_bool.common().member_flags().IS_KEY(false); - cst_my_bool.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_bool.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("bool", false)); - - - cst_my_bool.detail().name("my_bool"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_bool); - - CompleteStructMember cst_my_int32; - cst_my_int32.common().member_id(memberId++); - cst_my_int32.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_int32.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_int32.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_int32.common().member_flags().IS_OPTIONAL(false); - cst_my_int32.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_int32.common().member_flags().IS_KEY(false); - cst_my_int32.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_int32.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - cst_my_int32.detail().name("my_int32"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_int32); - - CompleteStructMember cst_my_string; - cst_my_string.common().member_id(memberId++); - cst_my_string.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_string.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_string.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_string.common().member_flags().IS_OPTIONAL(false); - cst_my_string.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_string.common().member_flags().IS_KEY(false); - cst_my_string.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_string.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, false)); - - cst_my_string.detail().name("my_string"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_string); - - CompleteStructMember cst_new_int32; - cst_new_int32.common().member_id(memberId++); - cst_new_int32.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_new_int32.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_new_int32.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_new_int32.common().member_flags().IS_OPTIONAL(false); - cst_new_int32.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_new_int32.common().member_flags().IS_KEY(false); - cst_new_int32.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_new_int32.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - cst_new_int32.detail().name("new_int32"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_new_int32); - - CompleteStructMember cst_new_string; - cst_new_string.common().member_id(memberId++); - cst_new_string.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_new_string.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_new_string.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_new_string.common().member_flags().IS_OPTIONAL(false); - cst_new_string.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_new_string.common().member_flags().IS_KEY(false); - cst_new_string.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_new_string.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, false)); - - cst_new_string.detail().name("new_string"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_new_string); - - - // Header - type_object->complete().struct_type().header().detail().type_name("BasicWideStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("BasicWideStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("BasicWideStruct", true); -} - - - -const TypeIdentifier* GetBadBasicWideStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("BadBasicWideStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetBadBasicWideStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("BadBasicWideStruct", complete); -} - -const TypeObject* GetBadBasicWideStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("BadBasicWideStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteBadBasicWideStructObject(); - } - //else - return GetMinimalBadBasicWideStructObject(); -} - -const TypeObject* GetMinimalBadBasicWideStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("BadBasicWideStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_new_int32; - mst_new_int32.common().member_id(memberId++); - mst_new_int32.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_new_int32.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_new_int32.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_new_int32.common().member_flags().IS_OPTIONAL(false); - mst_new_int32.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_new_int32.common().member_flags().IS_KEY(false); - mst_new_int32.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_new_int32.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - MD5 new_int32_hash("new_int32"); - for(int i = 0; i < 4; ++i) - { - mst_new_int32.detail().name_hash()[i] = new_int32_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_new_int32); - - MinimalStructMember mst_new_string; - mst_new_string.common().member_id(memberId++); - mst_new_string.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_new_string.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_new_string.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_new_string.common().member_flags().IS_OPTIONAL(false); - mst_new_string.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_new_string.common().member_flags().IS_KEY(false); - mst_new_string.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_new_string.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, false)); - - MD5 new_string_hash("new_string"); - for(int i = 0; i < 4; ++i) - { - mst_new_string.detail().name_hash()[i] = new_string_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_new_string); - - MinimalStructMember mst_my_bool; - mst_my_bool.common().member_id(memberId++); - mst_my_bool.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_bool.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_bool.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_bool.common().member_flags().IS_OPTIONAL(false); - mst_my_bool.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_bool.common().member_flags().IS_KEY(false); - mst_my_bool.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_bool.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("bool", false)); - - - MD5 my_bool_hash("my_bool"); - for(int i = 0; i < 4; ++i) - { - mst_my_bool.detail().name_hash()[i] = my_bool_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_bool); - - MinimalStructMember mst_my_int32; - mst_my_int32.common().member_id(memberId++); - mst_my_int32.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_int32.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_int32.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_int32.common().member_flags().IS_OPTIONAL(false); - mst_my_int32.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_int32.common().member_flags().IS_KEY(false); - mst_my_int32.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_int32.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - MD5 my_int32_hash("my_int32"); - for(int i = 0; i < 4; ++i) - { - mst_my_int32.detail().name_hash()[i] = my_int32_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_int32); - - MinimalStructMember mst_my_string; - mst_my_string.common().member_id(memberId++); - mst_my_string.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_string.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_string.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_string.common().member_flags().IS_OPTIONAL(false); - mst_my_string.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_string.common().member_flags().IS_KEY(false); - mst_my_string.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_string.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, false)); - - MD5 my_string_hash("my_string"); - for(int i = 0; i < 4; ++i) - { - mst_my_string.detail().name_hash()[i] = my_string_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_string); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("BadBasicWideStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("BadBasicWideStruct", false); -} - -const TypeObject* GetCompleteBadBasicWideStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("BadBasicWideStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_new_int32; - cst_new_int32.common().member_id(memberId++); - cst_new_int32.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_new_int32.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_new_int32.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_new_int32.common().member_flags().IS_OPTIONAL(false); - cst_new_int32.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_new_int32.common().member_flags().IS_KEY(false); - cst_new_int32.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_new_int32.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - cst_new_int32.detail().name("new_int32"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_new_int32); - - CompleteStructMember cst_new_string; - cst_new_string.common().member_id(memberId++); - cst_new_string.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_new_string.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_new_string.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_new_string.common().member_flags().IS_OPTIONAL(false); - cst_new_string.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_new_string.common().member_flags().IS_KEY(false); - cst_new_string.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_new_string.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, false)); - - cst_new_string.detail().name("new_string"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_new_string); - - CompleteStructMember cst_my_bool; - cst_my_bool.common().member_id(memberId++); - cst_my_bool.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_bool.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_bool.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_bool.common().member_flags().IS_OPTIONAL(false); - cst_my_bool.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_bool.common().member_flags().IS_KEY(false); - cst_my_bool.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_bool.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("bool", false)); - - - cst_my_bool.detail().name("my_bool"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_bool); - - CompleteStructMember cst_my_int32; - cst_my_int32.common().member_id(memberId++); - cst_my_int32.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_int32.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_int32.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_int32.common().member_flags().IS_OPTIONAL(false); - cst_my_int32.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_int32.common().member_flags().IS_KEY(false); - cst_my_int32.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_int32.common().member_type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - cst_my_int32.detail().name("my_int32"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_int32); - - CompleteStructMember cst_my_string; - cst_my_string.common().member_id(memberId++); - cst_my_string.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_string.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_string.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_string.common().member_flags().IS_OPTIONAL(false); - cst_my_string.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_string.common().member_flags().IS_KEY(false); - cst_my_string.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_string.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, false)); - - cst_my_string.detail().name("my_string"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_string); - - - // Header - type_object->complete().struct_type().header().detail().type_name("BadBasicWideStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("BadBasicWideStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("BadBasicWideStruct", true); -} - - - -const TypeIdentifier* GetStringStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("StringStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetStringStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("StringStruct", complete); -} - -const TypeObject* GetStringStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("StringStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteStringStructObject(); - } - //else - return GetMinimalStringStructObject(); -} - -const TypeObject* GetMinimalStringStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("StringStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_string; - mst_my_string.common().member_id(memberId++); - mst_my_string.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_string.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_string.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_string.common().member_flags().IS_OPTIONAL(false); - mst_my_string.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_string.common().member_flags().IS_KEY(false); - mst_my_string.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_string.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, false)); - - MD5 my_string_hash("my_string"); - for(int i = 0; i < 4; ++i) - { - mst_my_string.detail().name_hash()[i] = my_string_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_string); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("StringStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("StringStruct", false); -} - -const TypeObject* GetCompleteStringStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("StringStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_string; - cst_my_string.common().member_id(memberId++); - cst_my_string.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_string.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_string.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_string.common().member_flags().IS_OPTIONAL(false); - cst_my_string.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_string.common().member_flags().IS_KEY(false); - cst_my_string.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_string.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, false)); - - cst_my_string.detail().name("my_string"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_string); - - - // Header - type_object->complete().struct_type().header().detail().type_name("StringStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("StringStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("StringStruct", true); -} - - - -const TypeIdentifier* GetLargeStringStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("LargeStringStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetLargeStringStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("LargeStringStruct", complete); -} - -const TypeObject* GetLargeStringStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("LargeStringStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteLargeStringStructObject(); - } - //else - return GetMinimalLargeStringStructObject(); -} - -const TypeObject* GetMinimalLargeStringStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("LargeStringStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_large_string; - mst_my_large_string.common().member_id(memberId++); - mst_my_large_string.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_large_string.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_large_string.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_large_string.common().member_flags().IS_OPTIONAL(false); - mst_my_large_string.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_large_string.common().member_flags().IS_KEY(false); - mst_my_large_string.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_large_string.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(41925, false)); - - MD5 my_large_string_hash("my_large_string"); - for(int i = 0; i < 4; ++i) - { - mst_my_large_string.detail().name_hash()[i] = my_large_string_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_large_string); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("LargeStringStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("LargeStringStruct", false); -} - -const TypeObject* GetCompleteLargeStringStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("LargeStringStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_large_string; - cst_my_large_string.common().member_id(memberId++); - cst_my_large_string.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_large_string.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_large_string.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_large_string.common().member_flags().IS_OPTIONAL(false); - cst_my_large_string.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_large_string.common().member_flags().IS_KEY(false); - cst_my_large_string.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_large_string.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(41925, false)); - - cst_my_large_string.detail().name("my_large_string"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_large_string); - - - // Header - type_object->complete().struct_type().header().detail().type_name("LargeStringStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("LargeStringStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("LargeStringStruct", true); -} - - - -const TypeIdentifier* GetWStringStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("WStringStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetWStringStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("WStringStruct", complete); -} - -const TypeObject* GetWStringStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("WStringStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteWStringStructObject(); - } - //else - return GetMinimalWStringStructObject(); -} - -const TypeObject* GetMinimalWStringStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("WStringStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_wstring; - mst_my_wstring.common().member_id(memberId++); - mst_my_wstring.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_wstring.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_wstring.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_wstring.common().member_flags().IS_OPTIONAL(false); - mst_my_wstring.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_wstring.common().member_flags().IS_KEY(false); - mst_my_wstring.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_wstring.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, true)); - - MD5 my_wstring_hash("my_wstring"); - for(int i = 0; i < 4; ++i) - { - mst_my_wstring.detail().name_hash()[i] = my_wstring_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_wstring); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("WStringStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("WStringStruct", false); -} - -const TypeObject* GetCompleteWStringStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("WStringStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_wstring; - cst_my_wstring.common().member_id(memberId++); - cst_my_wstring.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_wstring.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_wstring.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_wstring.common().member_flags().IS_OPTIONAL(false); - cst_my_wstring.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_wstring.common().member_flags().IS_KEY(false); - cst_my_wstring.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_wstring.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(255, true)); - - cst_my_wstring.detail().name("my_wstring"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_wstring); - - - // Header - type_object->complete().struct_type().header().detail().type_name("WStringStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("WStringStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("WStringStruct", true); -} - - - -const TypeIdentifier* GetLargeWStringStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("LargeWStringStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetLargeWStringStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("LargeWStringStruct", complete); -} - -const TypeObject* GetLargeWStringStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("LargeWStringStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteLargeWStringStructObject(); - } - //else - return GetMinimalLargeWStringStructObject(); -} - -const TypeObject* GetMinimalLargeWStringStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("LargeWStringStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_large_wstring; - mst_my_large_wstring.common().member_id(memberId++); - mst_my_large_wstring.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_large_wstring.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_large_wstring.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_large_wstring.common().member_flags().IS_OPTIONAL(false); - mst_my_large_wstring.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_large_wstring.common().member_flags().IS_KEY(false); - mst_my_large_wstring.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_large_wstring.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(41925, true)); - - MD5 my_large_wstring_hash("my_large_wstring"); - for(int i = 0; i < 4; ++i) - { - mst_my_large_wstring.detail().name_hash()[i] = my_large_wstring_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_large_wstring); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("LargeWStringStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("LargeWStringStruct", false); -} - -const TypeObject* GetCompleteLargeWStringStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("LargeWStringStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_large_wstring; - cst_my_large_wstring.common().member_id(memberId++); - cst_my_large_wstring.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_large_wstring.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_large_wstring.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_large_wstring.common().member_flags().IS_OPTIONAL(false); - cst_my_large_wstring.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_large_wstring.common().member_flags().IS_KEY(false); - cst_my_large_wstring.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_large_wstring.common().member_type_id(*TypeObjectFactory::get_instance()->get_string_identifier(41925, true)); - - cst_my_large_wstring.detail().name("my_large_wstring"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_large_wstring); - - - // Header - type_object->complete().struct_type().header().detail().type_name("LargeWStringStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("LargeWStringStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("LargeWStringStruct", true); -} - - - -const TypeIdentifier* GetArrayStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("ArrayStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetArrayStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("ArrayStruct", complete); -} - -const TypeObject* GetArrayStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ArrayStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteArrayStructObject(); - } - //else - return GetMinimalArrayStructObject(); -} - -const TypeObject* GetMinimalArrayStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ArrayStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_array; - mst_my_array.common().member_id(memberId++); - mst_my_array.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_array.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_array.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_array.common().member_flags().IS_OPTIONAL(false); - mst_my_array.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_array.common().member_flags().IS_KEY(false); - mst_my_array.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_array.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("int32_t", {2}, false)); - - MD5 my_array_hash("my_array"); - for(int i = 0; i < 4; ++i) - { - mst_my_array.detail().name_hash()[i] = my_array_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_array); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("ArrayStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("ArrayStruct", false); -} - -const TypeObject* GetCompleteArrayStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ArrayStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_array; - cst_my_array.common().member_id(memberId++); - cst_my_array.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_array.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_array.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_array.common().member_flags().IS_OPTIONAL(false); - cst_my_array.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_array.common().member_flags().IS_KEY(false); - cst_my_array.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_array.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("int32_t", {2}, true)); - - cst_my_array.detail().name("my_array"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_array); - - - // Header - type_object->complete().struct_type().header().detail().type_name("ArrayStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("ArrayStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("ArrayStruct", true); -} - - - -const TypeIdentifier* GetArrayStructEqualIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("ArrayStructEqual", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetArrayStructEqualObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("ArrayStructEqual", complete); -} - -const TypeObject* GetArrayStructEqualObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ArrayStructEqual", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteArrayStructEqualObject(); - } - //else - return GetMinimalArrayStructEqualObject(); -} - -const TypeObject* GetMinimalArrayStructEqualObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ArrayStructEqual", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_array_equal; - mst_my_array_equal.common().member_id(memberId++); - mst_my_array_equal.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_array_equal.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_array_equal.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_array_equal.common().member_flags().IS_OPTIONAL(false); - mst_my_array_equal.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_array_equal.common().member_flags().IS_KEY(false); - mst_my_array_equal.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_array_equal.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("int32_t", {2}, false)); - - MD5 my_array_equal_hash("my_array_equal"); - for(int i = 0; i < 4; ++i) - { - mst_my_array_equal.detail().name_hash()[i] = my_array_equal_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_array_equal); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("ArrayStructEqual", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("ArrayStructEqual", false); -} - -const TypeObject* GetCompleteArrayStructEqualObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ArrayStructEqual", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_array_equal; - cst_my_array_equal.common().member_id(memberId++); - cst_my_array_equal.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_array_equal.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_array_equal.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_array_equal.common().member_flags().IS_OPTIONAL(false); - cst_my_array_equal.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_array_equal.common().member_flags().IS_KEY(false); - cst_my_array_equal.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_array_equal.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("int32_t", {2}, true)); - - cst_my_array_equal.detail().name("my_array_equal"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_array_equal); - - - // Header - type_object->complete().struct_type().header().detail().type_name("ArrayStructEqual"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("ArrayStructEqual", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("ArrayStructEqual", true); -} - - - -const TypeIdentifier* GetArrayBadStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("ArrayBadStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetArrayBadStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("ArrayBadStruct", complete); -} - -const TypeObject* GetArrayBadStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ArrayBadStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteArrayBadStructObject(); - } - //else - return GetMinimalArrayBadStructObject(); -} - -const TypeObject* GetMinimalArrayBadStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ArrayBadStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_array; - mst_my_array.common().member_id(memberId++); - mst_my_array.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_array.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_array.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_array.common().member_flags().IS_OPTIONAL(false); - mst_my_array.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_array.common().member_flags().IS_KEY(false); - mst_my_array.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_array.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("uint8_t", {2}, false)); - - MD5 my_array_hash("my_array"); - for(int i = 0; i < 4; ++i) - { - mst_my_array.detail().name_hash()[i] = my_array_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_array); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("ArrayBadStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("ArrayBadStruct", false); -} - -const TypeObject* GetCompleteArrayBadStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ArrayBadStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_array; - cst_my_array.common().member_id(memberId++); - cst_my_array.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_array.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_array.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_array.common().member_flags().IS_OPTIONAL(false); - cst_my_array.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_array.common().member_flags().IS_KEY(false); - cst_my_array.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_array.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("uint8_t", {2}, true)); - - cst_my_array.detail().name("my_array"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_array); - - - // Header - type_object->complete().struct_type().header().detail().type_name("ArrayBadStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("ArrayBadStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("ArrayBadStruct", true); -} - - - -const TypeIdentifier* GetArrayDimensionsStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("ArrayDimensionsStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetArrayDimensionsStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("ArrayDimensionsStruct", complete); -} - -const TypeObject* GetArrayDimensionsStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ArrayDimensionsStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteArrayDimensionsStructObject(); - } - //else - return GetMinimalArrayDimensionsStructObject(); -} - -const TypeObject* GetMinimalArrayDimensionsStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ArrayDimensionsStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_array; - mst_my_array.common().member_id(memberId++); - mst_my_array.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_array.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_array.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_array.common().member_flags().IS_OPTIONAL(false); - mst_my_array.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_array.common().member_flags().IS_KEY(false); - mst_my_array.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_array.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("int32_t", {2, 2}, false)); - - MD5 my_array_hash("my_array"); - for(int i = 0; i < 4; ++i) - { - mst_my_array.detail().name_hash()[i] = my_array_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_array); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("ArrayDimensionsStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("ArrayDimensionsStruct", false); -} - -const TypeObject* GetCompleteArrayDimensionsStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ArrayDimensionsStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_array; - cst_my_array.common().member_id(memberId++); - cst_my_array.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_array.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_array.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_array.common().member_flags().IS_OPTIONAL(false); - cst_my_array.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_array.common().member_flags().IS_KEY(false); - cst_my_array.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_array.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("int32_t", {2, 2}, true)); - - cst_my_array.detail().name("my_array"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_array); - - - // Header - type_object->complete().struct_type().header().detail().type_name("ArrayDimensionsStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("ArrayDimensionsStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("ArrayDimensionsStruct", true); -} - - - -const TypeIdentifier* GetArraySizeStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("ArraySizeStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetArraySizeStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("ArraySizeStruct", complete); -} - -const TypeObject* GetArraySizeStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ArraySizeStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteArraySizeStructObject(); - } - //else - return GetMinimalArraySizeStructObject(); -} - -const TypeObject* GetMinimalArraySizeStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ArraySizeStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_array; - mst_my_array.common().member_id(memberId++); - mst_my_array.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_array.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_array.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_array.common().member_flags().IS_OPTIONAL(false); - mst_my_array.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_array.common().member_flags().IS_KEY(false); - mst_my_array.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_array.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("int32_t", {5}, false)); - - MD5 my_array_hash("my_array"); - for(int i = 0; i < 4; ++i) - { - mst_my_array.detail().name_hash()[i] = my_array_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_array); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("ArraySizeStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("ArraySizeStruct", false); -} - -const TypeObject* GetCompleteArraySizeStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("ArraySizeStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_array; - cst_my_array.common().member_id(memberId++); - cst_my_array.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_array.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_array.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_array.common().member_flags().IS_OPTIONAL(false); - cst_my_array.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_array.common().member_flags().IS_KEY(false); - cst_my_array.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_array.common().member_type_id(*TypeObjectFactory::get_instance()->get_array_identifier("int32_t", {5}, true)); - - cst_my_array.detail().name("my_array"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_array); - - - // Header - type_object->complete().struct_type().header().detail().type_name("ArraySizeStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("ArraySizeStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("ArraySizeStruct", true); -} - - - - - -const TypeIdentifier* GetSequenceStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("SequenceStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetSequenceStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("SequenceStruct", complete); -} - -const TypeObject* GetSequenceStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SequenceStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteSequenceStructObject(); - } - //else - return GetMinimalSequenceStructObject(); -} - -const TypeObject* GetMinimalSequenceStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SequenceStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_sequence; - mst_my_sequence.common().member_id(memberId++); - mst_my_sequence.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_sequence.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_sequence.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_sequence.common().member_flags().IS_OPTIONAL(false); - mst_my_sequence.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_sequence.common().member_flags().IS_KEY(false); - mst_my_sequence.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_sequence.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("int32_t", 2, false)); - - MD5 my_sequence_hash("my_sequence"); - for(int i = 0; i < 4; ++i) - { - mst_my_sequence.detail().name_hash()[i] = my_sequence_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_sequence); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SequenceStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SequenceStruct", false); -} - -const TypeObject* GetCompleteSequenceStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SequenceStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_sequence; - cst_my_sequence.common().member_id(memberId++); - cst_my_sequence.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_sequence.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_sequence.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_sequence.common().member_flags().IS_OPTIONAL(false); - cst_my_sequence.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_sequence.common().member_flags().IS_KEY(false); - cst_my_sequence.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_sequence.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("int32_t", 2, true)); - - cst_my_sequence.detail().name("my_sequence"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_sequence); - - - // Header - type_object->complete().struct_type().header().detail().type_name("SequenceStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SequenceStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SequenceStruct", true); -} - - - - - -const TypeIdentifier* GetSequenceStructEqualIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("SequenceStructEqual", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetSequenceStructEqualObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("SequenceStructEqual", complete); -} - -const TypeObject* GetSequenceStructEqualObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SequenceStructEqual", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteSequenceStructEqualObject(); - } - //else - return GetMinimalSequenceStructEqualObject(); -} - -const TypeObject* GetMinimalSequenceStructEqualObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SequenceStructEqual", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_sequence_equal; - mst_my_sequence_equal.common().member_id(memberId++); - mst_my_sequence_equal.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_sequence_equal.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_sequence_equal.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_sequence_equal.common().member_flags().IS_OPTIONAL(false); - mst_my_sequence_equal.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_sequence_equal.common().member_flags().IS_KEY(false); - mst_my_sequence_equal.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_sequence_equal.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("int32_t", 2, false)); - - MD5 my_sequence_equal_hash("my_sequence_equal"); - for(int i = 0; i < 4; ++i) - { - mst_my_sequence_equal.detail().name_hash()[i] = my_sequence_equal_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_sequence_equal); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SequenceStructEqual", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SequenceStructEqual", false); -} - -const TypeObject* GetCompleteSequenceStructEqualObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SequenceStructEqual", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_sequence_equal; - cst_my_sequence_equal.common().member_id(memberId++); - cst_my_sequence_equal.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_sequence_equal.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_sequence_equal.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_sequence_equal.common().member_flags().IS_OPTIONAL(false); - cst_my_sequence_equal.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_sequence_equal.common().member_flags().IS_KEY(false); - cst_my_sequence_equal.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_sequence_equal.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("int32_t", 2, true)); - - cst_my_sequence_equal.detail().name("my_sequence_equal"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_sequence_equal); - - - // Header - type_object->complete().struct_type().header().detail().type_name("SequenceStructEqual"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SequenceStructEqual", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SequenceStructEqual", true); -} - - - - - -const TypeIdentifier* GetSequenceBadStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("SequenceBadStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetSequenceBadStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("SequenceBadStruct", complete); -} - -const TypeObject* GetSequenceBadStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SequenceBadStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteSequenceBadStructObject(); - } - //else - return GetMinimalSequenceBadStructObject(); -} - -const TypeObject* GetMinimalSequenceBadStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SequenceBadStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_sequence; - mst_my_sequence.common().member_id(memberId++); - mst_my_sequence.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_sequence.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_sequence.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_sequence.common().member_flags().IS_OPTIONAL(false); - mst_my_sequence.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_sequence.common().member_flags().IS_KEY(false); - mst_my_sequence.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_sequence.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("uint8_t", 2, false)); - - MD5 my_sequence_hash("my_sequence"); - for(int i = 0; i < 4; ++i) - { - mst_my_sequence.detail().name_hash()[i] = my_sequence_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_sequence); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SequenceBadStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SequenceBadStruct", false); -} - -const TypeObject* GetCompleteSequenceBadStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SequenceBadStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_sequence; - cst_my_sequence.common().member_id(memberId++); - cst_my_sequence.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_sequence.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_sequence.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_sequence.common().member_flags().IS_OPTIONAL(false); - cst_my_sequence.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_sequence.common().member_flags().IS_KEY(false); - cst_my_sequence.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_sequence.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("uint8_t", 2, true)); - - cst_my_sequence.detail().name("my_sequence"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_sequence); - - - // Header - type_object->complete().struct_type().header().detail().type_name("SequenceBadStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SequenceBadStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SequenceBadStruct", true); -} - - - - - -const TypeIdentifier* GetSequenceBoundsStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("SequenceBoundsStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetSequenceBoundsStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("SequenceBoundsStruct", complete); -} - -const TypeObject* GetSequenceBoundsStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SequenceBoundsStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteSequenceBoundsStructObject(); - } - //else - return GetMinimalSequenceBoundsStructObject(); -} - -const TypeObject* GetMinimalSequenceBoundsStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SequenceBoundsStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_sequence; - mst_my_sequence.common().member_id(memberId++); - mst_my_sequence.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_sequence.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_sequence.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_sequence.common().member_flags().IS_OPTIONAL(false); - mst_my_sequence.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_sequence.common().member_flags().IS_KEY(false); - mst_my_sequence.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_sequence.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("int32_t", 4, false)); - - MD5 my_sequence_hash("my_sequence"); - for(int i = 0; i < 4; ++i) - { - mst_my_sequence.detail().name_hash()[i] = my_sequence_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_sequence); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SequenceBoundsStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SequenceBoundsStruct", false); -} - -const TypeObject* GetCompleteSequenceBoundsStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SequenceBoundsStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_sequence; - cst_my_sequence.common().member_id(memberId++); - cst_my_sequence.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_sequence.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_sequence.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_sequence.common().member_flags().IS_OPTIONAL(false); - cst_my_sequence.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_sequence.common().member_flags().IS_KEY(false); - cst_my_sequence.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_sequence.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier("int32_t", 4, true)); - - cst_my_sequence.detail().name("my_sequence"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_sequence); - - - // Header - type_object->complete().struct_type().header().detail().type_name("SequenceBoundsStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SequenceBoundsStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SequenceBoundsStruct", true); -} - - - - - - - -const TypeIdentifier* GetSequenceSequenceStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("SequenceSequenceStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetSequenceSequenceStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("SequenceSequenceStruct", complete); -} - -const TypeObject* GetSequenceSequenceStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SequenceSequenceStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteSequenceSequenceStructObject(); - } - //else - return GetMinimalSequenceSequenceStructObject(); -} - -const TypeObject* GetMinimalSequenceSequenceStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SequenceSequenceStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_sequence_sequence; - mst_my_sequence_sequence.common().member_id(memberId++); - mst_my_sequence_sequence.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_sequence_sequence.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_sequence_sequence.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_sequence_sequence.common().member_flags().IS_OPTIONAL(false); - mst_my_sequence_sequence.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_sequence_sequence.common().member_flags().IS_KEY(false); - mst_my_sequence_sequence.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_sequence_sequence.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier(TypeNamesGenerator::get_sequence_type_name("int32_t", 2), 3, false)); - - MD5 my_sequence_sequence_hash("my_sequence_sequence"); - for(int i = 0; i < 4; ++i) - { - mst_my_sequence_sequence.detail().name_hash()[i] = my_sequence_sequence_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_sequence_sequence); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SequenceSequenceStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SequenceSequenceStruct", false); -} - -const TypeObject* GetCompleteSequenceSequenceStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SequenceSequenceStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_sequence_sequence; - cst_my_sequence_sequence.common().member_id(memberId++); - cst_my_sequence_sequence.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_sequence_sequence.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_sequence_sequence.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_sequence_sequence.common().member_flags().IS_OPTIONAL(false); - cst_my_sequence_sequence.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_sequence_sequence.common().member_flags().IS_KEY(false); - cst_my_sequence_sequence.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_sequence_sequence.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier(TypeNamesGenerator::get_sequence_type_name("int32_t", 2), 3, true)); - - cst_my_sequence_sequence.detail().name("my_sequence_sequence"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_sequence_sequence); - - - // Header - type_object->complete().struct_type().header().detail().type_name("SequenceSequenceStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SequenceSequenceStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SequenceSequenceStruct", true); -} - - - - - - - -const TypeIdentifier* GetSequenceSequenceBoundsStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("SequenceSequenceBoundsStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetSequenceSequenceBoundsStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("SequenceSequenceBoundsStruct", complete); -} - -const TypeObject* GetSequenceSequenceBoundsStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SequenceSequenceBoundsStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteSequenceSequenceBoundsStructObject(); - } - //else - return GetMinimalSequenceSequenceBoundsStructObject(); -} - -const TypeObject* GetMinimalSequenceSequenceBoundsStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SequenceSequenceBoundsStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_sequence_sequence; - mst_my_sequence_sequence.common().member_id(memberId++); - mst_my_sequence_sequence.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_sequence_sequence.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_sequence_sequence.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_sequence_sequence.common().member_flags().IS_OPTIONAL(false); - mst_my_sequence_sequence.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_sequence_sequence.common().member_flags().IS_KEY(false); - mst_my_sequence_sequence.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_sequence_sequence.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier(TypeNamesGenerator::get_sequence_type_name("int32_t", 5), 5, false)); - - MD5 my_sequence_sequence_hash("my_sequence_sequence"); - for(int i = 0; i < 4; ++i) - { - mst_my_sequence_sequence.detail().name_hash()[i] = my_sequence_sequence_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_sequence_sequence); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SequenceSequenceBoundsStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SequenceSequenceBoundsStruct", false); -} - -const TypeObject* GetCompleteSequenceSequenceBoundsStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SequenceSequenceBoundsStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_sequence_sequence; - cst_my_sequence_sequence.common().member_id(memberId++); - cst_my_sequence_sequence.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_sequence_sequence.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_sequence_sequence.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_sequence_sequence.common().member_flags().IS_OPTIONAL(false); - cst_my_sequence_sequence.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_sequence_sequence.common().member_flags().IS_KEY(false); - cst_my_sequence_sequence.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_sequence_sequence.common().member_type_id(*TypeObjectFactory::get_instance()->get_sequence_identifier(TypeNamesGenerator::get_sequence_type_name("int32_t", 5), 5, true)); - - cst_my_sequence_sequence.detail().name("my_sequence_sequence"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_sequence_sequence); - - - // Header - type_object->complete().struct_type().header().detail().type_name("SequenceSequenceBoundsStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SequenceSequenceBoundsStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SequenceSequenceBoundsStruct", true); -} - - - - - -const TypeIdentifier* GetMapStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("MapStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetMapStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("MapStruct", complete); -} - -const TypeObject* GetMapStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MapStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteMapStructObject(); - } - //else - return GetMinimalMapStructObject(); -} - -const TypeObject* GetMinimalMapStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MapStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_map; - mst_my_map.common().member_id(memberId++); - mst_my_map.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_map.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_map.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_map.common().member_flags().IS_OPTIONAL(false); - mst_my_map.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_map.common().member_flags().IS_KEY(false); - mst_my_map.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_map.common().member_type_id(*TypeObjectFactory::get_instance()->get_map_identifier("int32_t", "int32_t", 2, false)); - - MD5 my_map_hash("my_map"); - for(int i = 0; i < 4; ++i) - { - mst_my_map.detail().name_hash()[i] = my_map_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_map); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MapStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MapStruct", false); -} - -const TypeObject* GetCompleteMapStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MapStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_map; - cst_my_map.common().member_id(memberId++); - cst_my_map.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_map.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_map.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_map.common().member_flags().IS_OPTIONAL(false); - cst_my_map.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_map.common().member_flags().IS_KEY(false); - cst_my_map.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_map.common().member_type_id(*TypeObjectFactory::get_instance()->get_map_identifier("int32_t", "int32_t", 2, true)); - - cst_my_map.detail().name("my_map"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_map); - - - // Header - type_object->complete().struct_type().header().detail().type_name("MapStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MapStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MapStruct", true); -} - - - - - -const TypeIdentifier* GetMapStructEqualIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("MapStructEqual", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetMapStructEqualObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("MapStructEqual", complete); -} - -const TypeObject* GetMapStructEqualObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MapStructEqual", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteMapStructEqualObject(); - } - //else - return GetMinimalMapStructEqualObject(); -} - -const TypeObject* GetMinimalMapStructEqualObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MapStructEqual", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_map_equal; - mst_my_map_equal.common().member_id(memberId++); - mst_my_map_equal.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_map_equal.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_map_equal.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_map_equal.common().member_flags().IS_OPTIONAL(false); - mst_my_map_equal.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_map_equal.common().member_flags().IS_KEY(false); - mst_my_map_equal.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_map_equal.common().member_type_id(*TypeObjectFactory::get_instance()->get_map_identifier("int32_t", "int32_t", 2, false)); - - MD5 my_map_equal_hash("my_map_equal"); - for(int i = 0; i < 4; ++i) - { - mst_my_map_equal.detail().name_hash()[i] = my_map_equal_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_map_equal); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MapStructEqual", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MapStructEqual", false); -} - -const TypeObject* GetCompleteMapStructEqualObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MapStructEqual", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_map_equal; - cst_my_map_equal.common().member_id(memberId++); - cst_my_map_equal.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_map_equal.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_map_equal.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_map_equal.common().member_flags().IS_OPTIONAL(false); - cst_my_map_equal.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_map_equal.common().member_flags().IS_KEY(false); - cst_my_map_equal.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_map_equal.common().member_type_id(*TypeObjectFactory::get_instance()->get_map_identifier("int32_t", "int32_t", 2, true)); - - cst_my_map_equal.detail().name("my_map_equal"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_map_equal); - - - // Header - type_object->complete().struct_type().header().detail().type_name("MapStructEqual"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MapStructEqual", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MapStructEqual", true); -} - - - - - -const TypeIdentifier* GetMapBadKeyStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("MapBadKeyStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetMapBadKeyStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("MapBadKeyStruct", complete); -} - -const TypeObject* GetMapBadKeyStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MapBadKeyStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteMapBadKeyStructObject(); - } - //else - return GetMinimalMapBadKeyStructObject(); -} - -const TypeObject* GetMinimalMapBadKeyStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MapBadKeyStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_map; - mst_my_map.common().member_id(memberId++); - mst_my_map.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_map.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_map.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_map.common().member_flags().IS_OPTIONAL(false); - mst_my_map.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_map.common().member_flags().IS_KEY(false); - mst_my_map.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_map.common().member_type_id(*TypeObjectFactory::get_instance()->get_map_identifier("uint8_t", "int32_t", 2, false)); - - MD5 my_map_hash("my_map"); - for(int i = 0; i < 4; ++i) - { - mst_my_map.detail().name_hash()[i] = my_map_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_map); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MapBadKeyStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MapBadKeyStruct", false); -} - -const TypeObject* GetCompleteMapBadKeyStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MapBadKeyStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_map; - cst_my_map.common().member_id(memberId++); - cst_my_map.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_map.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_map.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_map.common().member_flags().IS_OPTIONAL(false); - cst_my_map.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_map.common().member_flags().IS_KEY(false); - cst_my_map.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_map.common().member_type_id(*TypeObjectFactory::get_instance()->get_map_identifier("uint8_t", "int32_t", 2, true)); - - cst_my_map.detail().name("my_map"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_map); - - - // Header - type_object->complete().struct_type().header().detail().type_name("MapBadKeyStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MapBadKeyStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MapBadKeyStruct", true); -} - - - - - -const TypeIdentifier* GetMapBadElemStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("MapBadElemStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetMapBadElemStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("MapBadElemStruct", complete); -} - -const TypeObject* GetMapBadElemStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MapBadElemStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteMapBadElemStructObject(); - } - //else - return GetMinimalMapBadElemStructObject(); -} - -const TypeObject* GetMinimalMapBadElemStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MapBadElemStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_map; - mst_my_map.common().member_id(memberId++); - mst_my_map.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_map.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_map.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_map.common().member_flags().IS_OPTIONAL(false); - mst_my_map.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_map.common().member_flags().IS_KEY(false); - mst_my_map.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_map.common().member_type_id(*TypeObjectFactory::get_instance()->get_map_identifier("int32_t", "int64_t", 2, false)); - - MD5 my_map_hash("my_map"); - for(int i = 0; i < 4; ++i) - { - mst_my_map.detail().name_hash()[i] = my_map_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_map); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MapBadElemStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MapBadElemStruct", false); -} - -const TypeObject* GetCompleteMapBadElemStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MapBadElemStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_map; - cst_my_map.common().member_id(memberId++); - cst_my_map.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_map.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_map.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_map.common().member_flags().IS_OPTIONAL(false); - cst_my_map.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_map.common().member_flags().IS_KEY(false); - cst_my_map.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_map.common().member_type_id(*TypeObjectFactory::get_instance()->get_map_identifier("int32_t", "int64_t", 2, true)); - - cst_my_map.detail().name("my_map"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_map); - - - // Header - type_object->complete().struct_type().header().detail().type_name("MapBadElemStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MapBadElemStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MapBadElemStruct", true); -} - - - - - -const TypeIdentifier* GetMapBoundsStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("MapBoundsStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetMapBoundsStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("MapBoundsStruct", complete); -} - -const TypeObject* GetMapBoundsStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MapBoundsStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteMapBoundsStructObject(); - } - //else - return GetMinimalMapBoundsStructObject(); -} - -const TypeObject* GetMinimalMapBoundsStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MapBoundsStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_map; - mst_my_map.common().member_id(memberId++); - mst_my_map.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_map.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_map.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_map.common().member_flags().IS_OPTIONAL(false); - mst_my_map.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_map.common().member_flags().IS_KEY(false); - mst_my_map.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_map.common().member_type_id(*TypeObjectFactory::get_instance()->get_map_identifier("int32_t", "int32_t", 4, false)); - - MD5 my_map_hash("my_map"); - for(int i = 0; i < 4; ++i) - { - mst_my_map.detail().name_hash()[i] = my_map_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_map); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MapBoundsStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MapBoundsStruct", false); -} - -const TypeObject* GetCompleteMapBoundsStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MapBoundsStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_map; - cst_my_map.common().member_id(memberId++); - cst_my_map.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_map.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_map.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_map.common().member_flags().IS_OPTIONAL(false); - cst_my_map.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_map.common().member_flags().IS_KEY(false); - cst_my_map.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_map.common().member_type_id(*TypeObjectFactory::get_instance()->get_map_identifier("int32_t", "int32_t", 4, true)); - - cst_my_map.detail().name("my_map"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_map); - - - // Header - type_object->complete().struct_type().header().detail().type_name("MapBoundsStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MapBoundsStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MapBoundsStruct", true); -} - - - - - - - -const TypeIdentifier* GetMapMapStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("MapMapStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetMapMapStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("MapMapStruct", complete); -} - -const TypeObject* GetMapMapStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MapMapStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteMapMapStructObject(); - } - //else - return GetMinimalMapMapStructObject(); -} - -const TypeObject* GetMinimalMapMapStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MapMapStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_map_map; - mst_my_map_map.common().member_id(memberId++); - mst_my_map_map.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_map_map.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_map_map.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_map_map.common().member_flags().IS_OPTIONAL(false); - mst_my_map_map.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_map_map.common().member_flags().IS_KEY(false); - mst_my_map_map.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_map_map.common().member_type_id(*TypeObjectFactory::get_instance()->get_map_identifier("int32_t", TypeNamesGenerator::get_map_type_name("int32_t", "int32_t", 2), 2, false)); - - MD5 my_map_map_hash("my_map_map"); - for(int i = 0; i < 4; ++i) - { - mst_my_map_map.detail().name_hash()[i] = my_map_map_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_map_map); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MapMapStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MapMapStruct", false); -} - -const TypeObject* GetCompleteMapMapStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MapMapStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_map_map; - cst_my_map_map.common().member_id(memberId++); - cst_my_map_map.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_map_map.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_map_map.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_map_map.common().member_flags().IS_OPTIONAL(false); - cst_my_map_map.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_map_map.common().member_flags().IS_KEY(false); - cst_my_map_map.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_map_map.common().member_type_id(*TypeObjectFactory::get_instance()->get_map_identifier("int32_t", TypeNamesGenerator::get_map_type_name("int32_t", "int32_t", 2), 2, true)); - - cst_my_map_map.detail().name("my_map_map"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_map_map); - - - // Header - type_object->complete().struct_type().header().detail().type_name("MapMapStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MapMapStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MapMapStruct", true); -} - - - - - - - -const TypeIdentifier* GetMapMapBoundsStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("MapMapBoundsStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetMapMapBoundsStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("MapMapBoundsStruct", complete); -} - -const TypeObject* GetMapMapBoundsStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MapMapBoundsStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteMapMapBoundsStructObject(); - } - //else - return GetMinimalMapMapBoundsStructObject(); -} - -const TypeObject* GetMinimalMapMapBoundsStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MapMapBoundsStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_map_map; - mst_my_map_map.common().member_id(memberId++); - mst_my_map_map.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_map_map.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_map_map.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_map_map.common().member_flags().IS_OPTIONAL(false); - mst_my_map_map.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_map_map.common().member_flags().IS_KEY(false); - mst_my_map_map.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_map_map.common().member_type_id(*TypeObjectFactory::get_instance()->get_map_identifier("int32_t", TypeNamesGenerator::get_map_type_name("int32_t", "int32_t", 3), 3, false)); - - MD5 my_map_map_hash("my_map_map"); - for(int i = 0; i < 4; ++i) - { - mst_my_map_map.detail().name_hash()[i] = my_map_map_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_map_map); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MapMapBoundsStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MapMapBoundsStruct", false); -} - -const TypeObject* GetCompleteMapMapBoundsStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("MapMapBoundsStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_map_map; - cst_my_map_map.common().member_id(memberId++); - cst_my_map_map.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_map_map.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_map_map.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_map_map.common().member_flags().IS_OPTIONAL(false); - cst_my_map_map.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_map_map.common().member_flags().IS_KEY(false); - cst_my_map_map.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_map_map.common().member_type_id(*TypeObjectFactory::get_instance()->get_map_identifier("int32_t", TypeNamesGenerator::get_map_type_name("int32_t", "int32_t", 3), 3, true)); - - cst_my_map_map.detail().name("my_map_map"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_map_map); - - - // Header - type_object->complete().struct_type().header().detail().type_name("MapMapBoundsStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("MapMapBoundsStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("MapMapBoundsStruct", true); -} - - - -const TypeIdentifier* GetSimpleUnionIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("SimpleUnion", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetSimpleUnionObject(complete); - return TypeObjectFactory::get_instance()->get_type_identifier("SimpleUnion", complete); -} - -const TypeObject* GetSimpleUnionObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleUnion", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteSimpleUnionObject(); - } - // else - return GetMinimalSimpleUnionObject(); -} - -const TypeObject* GetMinimalSimpleUnionObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleUnion", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_UNION); - - type_object->minimal().union_type().union_flags().IS_FINAL(false); - type_object->minimal().union_type().union_flags().IS_APPENDABLE(false); - type_object->minimal().union_type().union_flags().IS_MUTABLE(false); - type_object->minimal().union_type().union_flags().IS_NESTED(false); - type_object->minimal().union_type().union_flags().IS_AUTOID_HASH(false); // Unsupported - - type_object->minimal().union_type().discriminator().common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().IS_EXTERNAL(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_OPTIONAL(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_KEY(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().IS_DEFAULT(false); // Doesn't apply - - type_object->minimal().union_type().discriminator().common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - MemberId memberId = 0; - MinimalUnionMember mst_first; - mst_first.common().member_id(memberId++); - mst_first.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_first.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_first.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_first.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - mst_first.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mst_first.common().member_flags().IS_KEY(false); // Doesn't apply - mst_first.common().member_flags().IS_DEFAULT(false); - mst_first.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - mst_first.common().label_seq().emplace_back(A); - - MD5 first_hash("first"); - for(int i = 0; i < 4; ++i) - { - mst_first.detail().name_hash()[i] = first_hash.digest[i]; - } - type_object->minimal().union_type().member_seq().emplace_back(mst_first); - - MinimalUnionMember mst_second; - mst_second.common().member_id(memberId++); - mst_second.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_second.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_second.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_second.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - mst_second.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mst_second.common().member_flags().IS_KEY(false); // Doesn't apply - mst_second.common().member_flags().IS_DEFAULT(false); - mst_second.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int64_t", false)); - - - mst_second.common().label_seq().emplace_back(B); - - MD5 second_hash("second"); - for(int i = 0; i < 4; ++i) - { - mst_second.detail().name_hash()[i] = second_hash.digest[i]; - } - type_object->minimal().union_type().member_seq().emplace_back(mst_second); - - - // Header - //type_object->minimal().union_type().header().detail()... // Empty - - TypeIdentifier* identifier = new TypeIdentifier(); - identifier->_d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().union_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier->equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimpleUnion", identifier, type_object); - delete type_object; - delete identifier; - return TypeObjectFactory::get_instance()->get_type_object("SimpleUnion", false); -} - -const TypeObject* GetCompleteSimpleUnionObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleUnion", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_UNION); - - type_object->complete().union_type().union_flags().IS_FINAL(false); - type_object->complete().union_type().union_flags().IS_APPENDABLE(false); - type_object->complete().union_type().union_flags().IS_MUTABLE(false); - type_object->complete().union_type().union_flags().IS_NESTED(false); - type_object->complete().union_type().union_flags().IS_AUTOID_HASH(false); // Unsupported - - type_object->complete().union_type().discriminator().common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().IS_EXTERNAL(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_OPTIONAL(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_KEY(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().IS_DEFAULT(false); // Doesn't apply - - type_object->complete().union_type().discriminator().common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - MemberId memberId = 0; - CompleteUnionMember cst_first; - cst_first.common().member_id(memberId++); - cst_first.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_first.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_first.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_first.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - cst_first.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cst_first.common().member_flags().IS_KEY(false); // Doesn't apply - cst_first.common().member_flags().IS_DEFAULT(false); - cst_first.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - cst_first.common().label_seq().emplace_back(A); - - - cst_first.detail().name("first"); - - type_object->complete().union_type().member_seq().emplace_back(cst_first); - - CompleteUnionMember cst_second; - cst_second.common().member_id(memberId++); - cst_second.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_second.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_second.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_second.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - cst_second.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cst_second.common().member_flags().IS_KEY(false); // Doesn't apply - cst_second.common().member_flags().IS_DEFAULT(false); - cst_second.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int64_t", false)); - - cst_second.common().label_seq().emplace_back(B); - - - cst_second.detail().name("second"); - - type_object->complete().union_type().member_seq().emplace_back(cst_second); - - - // Header - type_object->complete().union_type().header().detail().type_name("SimpleUnion"); - - TypeIdentifier* identifier = new TypeIdentifier(); - identifier->_d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().union_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier->equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimpleUnion", identifier, type_object); - delete type_object; - delete identifier; - return TypeObjectFactory::get_instance()->get_type_object("SimpleUnion", true); -} - - - -const TypeIdentifier* GetSimpleUnionNamesIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("SimpleUnionNames", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetSimpleUnionNamesObject(complete); - return TypeObjectFactory::get_instance()->get_type_identifier("SimpleUnionNames", complete); -} - -const TypeObject* GetSimpleUnionNamesObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleUnionNames", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteSimpleUnionNamesObject(); - } - // else - return GetMinimalSimpleUnionNamesObject(); -} - -const TypeObject* GetMinimalSimpleUnionNamesObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleUnionNames", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_UNION); - - type_object->minimal().union_type().union_flags().IS_FINAL(false); - type_object->minimal().union_type().union_flags().IS_APPENDABLE(false); - type_object->minimal().union_type().union_flags().IS_MUTABLE(false); - type_object->minimal().union_type().union_flags().IS_NESTED(false); - type_object->minimal().union_type().union_flags().IS_AUTOID_HASH(false); // Unsupported - - type_object->minimal().union_type().discriminator().common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().IS_EXTERNAL(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_OPTIONAL(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_KEY(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().IS_DEFAULT(false); // Doesn't apply - - type_object->minimal().union_type().discriminator().common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - MemberId memberId = 0; - MinimalUnionMember mst_first_case; - mst_first_case.common().member_id(memberId++); - mst_first_case.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_first_case.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_first_case.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_first_case.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - mst_first_case.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mst_first_case.common().member_flags().IS_KEY(false); // Doesn't apply - mst_first_case.common().member_flags().IS_DEFAULT(false); - mst_first_case.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - mst_first_case.common().label_seq().emplace_back(A); - - MD5 first_case_hash("first_case"); - for(int i = 0; i < 4; ++i) - { - mst_first_case.detail().name_hash()[i] = first_case_hash.digest[i]; - } - type_object->minimal().union_type().member_seq().emplace_back(mst_first_case); - - MinimalUnionMember mst_second_case; - mst_second_case.common().member_id(memberId++); - mst_second_case.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_second_case.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_second_case.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_second_case.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - mst_second_case.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mst_second_case.common().member_flags().IS_KEY(false); // Doesn't apply - mst_second_case.common().member_flags().IS_DEFAULT(false); - mst_second_case.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int64_t", false)); - - - mst_second_case.common().label_seq().emplace_back(B); - - MD5 second_case_hash("second_case"); - for(int i = 0; i < 4; ++i) - { - mst_second_case.detail().name_hash()[i] = second_case_hash.digest[i]; - } - type_object->minimal().union_type().member_seq().emplace_back(mst_second_case); - - - // Header - //type_object->minimal().union_type().header().detail()... // Empty - - TypeIdentifier* identifier = new TypeIdentifier(); - identifier->_d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().union_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier->equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimpleUnionNames", identifier, type_object); - delete type_object; - delete identifier; - return TypeObjectFactory::get_instance()->get_type_object("SimpleUnionNames", false); -} - -const TypeObject* GetCompleteSimpleUnionNamesObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleUnionNames", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_UNION); - - type_object->complete().union_type().union_flags().IS_FINAL(false); - type_object->complete().union_type().union_flags().IS_APPENDABLE(false); - type_object->complete().union_type().union_flags().IS_MUTABLE(false); - type_object->complete().union_type().union_flags().IS_NESTED(false); - type_object->complete().union_type().union_flags().IS_AUTOID_HASH(false); // Unsupported - - type_object->complete().union_type().discriminator().common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().IS_EXTERNAL(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_OPTIONAL(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_KEY(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().IS_DEFAULT(false); // Doesn't apply - - type_object->complete().union_type().discriminator().common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - MemberId memberId = 0; - CompleteUnionMember cst_first_case; - cst_first_case.common().member_id(memberId++); - cst_first_case.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_first_case.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_first_case.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_first_case.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - cst_first_case.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cst_first_case.common().member_flags().IS_KEY(false); // Doesn't apply - cst_first_case.common().member_flags().IS_DEFAULT(false); - cst_first_case.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - cst_first_case.common().label_seq().emplace_back(A); - - - cst_first_case.detail().name("first_case"); - - type_object->complete().union_type().member_seq().emplace_back(cst_first_case); - - CompleteUnionMember cst_second_case; - cst_second_case.common().member_id(memberId++); - cst_second_case.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_second_case.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_second_case.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_second_case.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - cst_second_case.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cst_second_case.common().member_flags().IS_KEY(false); // Doesn't apply - cst_second_case.common().member_flags().IS_DEFAULT(false); - cst_second_case.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int64_t", false)); - - cst_second_case.common().label_seq().emplace_back(B); - - - cst_second_case.detail().name("second_case"); - - type_object->complete().union_type().member_seq().emplace_back(cst_second_case); - - - // Header - type_object->complete().union_type().header().detail().type_name("SimpleUnionNames"); - - TypeIdentifier* identifier = new TypeIdentifier(); - identifier->_d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().union_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier->equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimpleUnionNames", identifier, type_object); - delete type_object; - delete identifier; - return TypeObjectFactory::get_instance()->get_type_object("SimpleUnionNames", true); -} - - - -const TypeIdentifier* GetSimpleTypeUnionIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("SimpleTypeUnion", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetSimpleTypeUnionObject(complete); - return TypeObjectFactory::get_instance()->get_type_identifier("SimpleTypeUnion", complete); -} - -const TypeObject* GetSimpleTypeUnionObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleTypeUnion", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteSimpleTypeUnionObject(); - } - // else - return GetMinimalSimpleTypeUnionObject(); -} - -const TypeObject* GetMinimalSimpleTypeUnionObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleTypeUnion", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_UNION); - - type_object->minimal().union_type().union_flags().IS_FINAL(false); - type_object->minimal().union_type().union_flags().IS_APPENDABLE(false); - type_object->minimal().union_type().union_flags().IS_MUTABLE(false); - type_object->minimal().union_type().union_flags().IS_NESTED(false); - type_object->minimal().union_type().union_flags().IS_AUTOID_HASH(false); // Unsupported - - type_object->minimal().union_type().discriminator().common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().IS_EXTERNAL(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_OPTIONAL(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_KEY(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().IS_DEFAULT(false); // Doesn't apply - - type_object->minimal().union_type().discriminator().common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - MemberId memberId = 0; - MinimalUnionMember mst_first; - mst_first.common().member_id(memberId++); - mst_first.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_first.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_first.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_first.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - mst_first.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mst_first.common().member_flags().IS_KEY(false); // Doesn't apply - mst_first.common().member_flags().IS_DEFAULT(false); - mst_first.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint8_t", false)); - - - mst_first.common().label_seq().emplace_back(A); - - MD5 first_hash("first"); - for(int i = 0; i < 4; ++i) - { - mst_first.detail().name_hash()[i] = first_hash.digest[i]; - } - type_object->minimal().union_type().member_seq().emplace_back(mst_first); - - MinimalUnionMember mst_second; - mst_second.common().member_id(memberId++); - mst_second.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_second.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_second.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_second.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - mst_second.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mst_second.common().member_flags().IS_KEY(false); // Doesn't apply - mst_second.common().member_flags().IS_DEFAULT(false); - mst_second.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int64_t", false)); - - - mst_second.common().label_seq().emplace_back(B); - - MD5 second_hash("second"); - for(int i = 0; i < 4; ++i) - { - mst_second.detail().name_hash()[i] = second_hash.digest[i]; - } - type_object->minimal().union_type().member_seq().emplace_back(mst_second); - - - // Header - //type_object->minimal().union_type().header().detail()... // Empty - - TypeIdentifier* identifier = new TypeIdentifier(); - identifier->_d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().union_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier->equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimpleTypeUnion", identifier, type_object); - delete type_object; - delete identifier; - return TypeObjectFactory::get_instance()->get_type_object("SimpleTypeUnion", false); -} - -const TypeObject* GetCompleteSimpleTypeUnionObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleTypeUnion", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_UNION); - - type_object->complete().union_type().union_flags().IS_FINAL(false); - type_object->complete().union_type().union_flags().IS_APPENDABLE(false); - type_object->complete().union_type().union_flags().IS_MUTABLE(false); - type_object->complete().union_type().union_flags().IS_NESTED(false); - type_object->complete().union_type().union_flags().IS_AUTOID_HASH(false); // Unsupported - - type_object->complete().union_type().discriminator().common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().IS_EXTERNAL(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_OPTIONAL(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_KEY(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().IS_DEFAULT(false); // Doesn't apply - - type_object->complete().union_type().discriminator().common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - MemberId memberId = 0; - CompleteUnionMember cst_first; - cst_first.common().member_id(memberId++); - cst_first.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_first.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_first.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_first.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - cst_first.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cst_first.common().member_flags().IS_KEY(false); // Doesn't apply - cst_first.common().member_flags().IS_DEFAULT(false); - cst_first.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint8_t", false)); - - cst_first.common().label_seq().emplace_back(A); - - - cst_first.detail().name("first"); - - type_object->complete().union_type().member_seq().emplace_back(cst_first); - - CompleteUnionMember cst_second; - cst_second.common().member_id(memberId++); - cst_second.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_second.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_second.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_second.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - cst_second.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cst_second.common().member_flags().IS_KEY(false); // Doesn't apply - cst_second.common().member_flags().IS_DEFAULT(false); - cst_second.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int64_t", false)); - - cst_second.common().label_seq().emplace_back(B); - - - cst_second.detail().name("second"); - - type_object->complete().union_type().member_seq().emplace_back(cst_second); - - - // Header - type_object->complete().union_type().header().detail().type_name("SimpleTypeUnion"); - - TypeIdentifier* identifier = new TypeIdentifier(); - identifier->_d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().union_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier->equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimpleTypeUnion", identifier, type_object); - delete type_object; - delete identifier; - return TypeObjectFactory::get_instance()->get_type_object("SimpleTypeUnion", true); -} - - - -const TypeIdentifier* GetSimpleBadUnionIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("SimpleBadUnion", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetSimpleBadUnionObject(complete); - return TypeObjectFactory::get_instance()->get_type_identifier("SimpleBadUnion", complete); -} - -const TypeObject* GetSimpleBadUnionObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleBadUnion", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteSimpleBadUnionObject(); - } - // else - return GetMinimalSimpleBadUnionObject(); -} - -const TypeObject* GetMinimalSimpleBadUnionObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleBadUnion", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_UNION); - - type_object->minimal().union_type().union_flags().IS_FINAL(false); - type_object->minimal().union_type().union_flags().IS_APPENDABLE(false); - type_object->minimal().union_type().union_flags().IS_MUTABLE(false); - type_object->minimal().union_type().union_flags().IS_NESTED(false); - type_object->minimal().union_type().union_flags().IS_AUTOID_HASH(false); // Unsupported - - type_object->minimal().union_type().discriminator().common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().IS_EXTERNAL(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_OPTIONAL(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_KEY(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().IS_DEFAULT(false); // Doesn't apply - - type_object->minimal().union_type().discriminator().common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - MemberId memberId = 0; - MinimalUnionMember mst_first; - mst_first.common().member_id(memberId++); - mst_first.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_first.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_first.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_first.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - mst_first.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mst_first.common().member_flags().IS_KEY(false); // Doesn't apply - mst_first.common().member_flags().IS_DEFAULT(false); - mst_first.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - mst_first.common().label_seq().emplace_back(A); - - MD5 first_hash("first"); - for(int i = 0; i < 4; ++i) - { - mst_first.detail().name_hash()[i] = first_hash.digest[i]; - } - type_object->minimal().union_type().member_seq().emplace_back(mst_first); - - MinimalUnionMember mst_second; - mst_second.common().member_id(memberId++); - mst_second.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_second.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_second.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_second.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - mst_second.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mst_second.common().member_flags().IS_KEY(false); // Doesn't apply - mst_second.common().member_flags().IS_DEFAULT(false); - mst_second.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int64_t", false)); - - - mst_second.common().label_seq().emplace_back(C); - - MD5 second_hash("second"); - for(int i = 0; i < 4; ++i) - { - mst_second.detail().name_hash()[i] = second_hash.digest[i]; - } - type_object->minimal().union_type().member_seq().emplace_back(mst_second); - - - // Header - //type_object->minimal().union_type().header().detail()... // Empty - - TypeIdentifier* identifier = new TypeIdentifier(); - identifier->_d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().union_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier->equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimpleBadUnion", identifier, type_object); - delete type_object; - delete identifier; - return TypeObjectFactory::get_instance()->get_type_object("SimpleBadUnion", false); -} - -const TypeObject* GetCompleteSimpleBadUnionObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleBadUnion", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_UNION); - - type_object->complete().union_type().union_flags().IS_FINAL(false); - type_object->complete().union_type().union_flags().IS_APPENDABLE(false); - type_object->complete().union_type().union_flags().IS_MUTABLE(false); - type_object->complete().union_type().union_flags().IS_NESTED(false); - type_object->complete().union_type().union_flags().IS_AUTOID_HASH(false); // Unsupported - - type_object->complete().union_type().discriminator().common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().IS_EXTERNAL(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_OPTIONAL(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_KEY(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().IS_DEFAULT(false); // Doesn't apply - - type_object->complete().union_type().discriminator().common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - MemberId memberId = 0; - CompleteUnionMember cst_first; - cst_first.common().member_id(memberId++); - cst_first.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_first.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_first.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_first.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - cst_first.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cst_first.common().member_flags().IS_KEY(false); // Doesn't apply - cst_first.common().member_flags().IS_DEFAULT(false); - cst_first.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - cst_first.common().label_seq().emplace_back(A); - - - cst_first.detail().name("first"); - - type_object->complete().union_type().member_seq().emplace_back(cst_first); - - CompleteUnionMember cst_second; - cst_second.common().member_id(memberId++); - cst_second.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_second.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_second.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_second.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - cst_second.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cst_second.common().member_flags().IS_KEY(false); // Doesn't apply - cst_second.common().member_flags().IS_DEFAULT(false); - cst_second.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int64_t", false)); - - cst_second.common().label_seq().emplace_back(C); - - - cst_second.detail().name("second"); - - type_object->complete().union_type().member_seq().emplace_back(cst_second); - - - // Header - type_object->complete().union_type().header().detail().type_name("SimpleBadUnion"); - - TypeIdentifier* identifier = new TypeIdentifier(); - identifier->_d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().union_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier->equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimpleBadUnion", identifier, type_object); - delete type_object; - delete identifier; - return TypeObjectFactory::get_instance()->get_type_object("SimpleBadUnion", true); -} - - - -const TypeIdentifier* GetSimpleBadDiscUnionIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("SimpleBadDiscUnion", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetSimpleBadDiscUnionObject(complete); - return TypeObjectFactory::get_instance()->get_type_identifier("SimpleBadDiscUnion", complete); -} - -const TypeObject* GetSimpleBadDiscUnionObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleBadDiscUnion", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteSimpleBadDiscUnionObject(); - } - // else - return GetMinimalSimpleBadDiscUnionObject(); -} - -const TypeObject* GetMinimalSimpleBadDiscUnionObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleBadDiscUnion", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_UNION); - - type_object->minimal().union_type().union_flags().IS_FINAL(false); - type_object->minimal().union_type().union_flags().IS_APPENDABLE(false); - type_object->minimal().union_type().union_flags().IS_MUTABLE(false); - type_object->minimal().union_type().union_flags().IS_NESTED(false); - type_object->minimal().union_type().union_flags().IS_AUTOID_HASH(false); // Unsupported - - type_object->minimal().union_type().discriminator().common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().IS_EXTERNAL(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_OPTIONAL(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - type_object->minimal().union_type().discriminator().common().member_flags().IS_KEY(false); // Unsupported - type_object->minimal().union_type().discriminator().common().member_flags().IS_DEFAULT(false); // Doesn't apply - - type_object->minimal().union_type().discriminator().common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint8_t", false)); - - MemberId memberId = 0; - MinimalUnionMember mst_first; - mst_first.common().member_id(memberId++); - mst_first.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_first.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_first.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_first.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - mst_first.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mst_first.common().member_flags().IS_KEY(false); // Doesn't apply - mst_first.common().member_flags().IS_DEFAULT(false); - mst_first.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - - mst_first.common().label_seq().emplace_back(0); - - MD5 first_hash("first"); - for(int i = 0; i < 4; ++i) - { - mst_first.detail().name_hash()[i] = first_hash.digest[i]; - } - type_object->minimal().union_type().member_seq().emplace_back(mst_first); - - MinimalUnionMember mst_second; - mst_second.common().member_id(memberId++); - mst_second.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_second.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_second.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_second.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - mst_second.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - mst_second.common().member_flags().IS_KEY(false); // Doesn't apply - mst_second.common().member_flags().IS_DEFAULT(false); - mst_second.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int64_t", false)); - - - mst_second.common().label_seq().emplace_back(1); - - MD5 second_hash("second"); - for(int i = 0; i < 4; ++i) - { - mst_second.detail().name_hash()[i] = second_hash.digest[i]; - } - type_object->minimal().union_type().member_seq().emplace_back(mst_second); - - - // Header - //type_object->minimal().union_type().header().detail()... // Empty - - TypeIdentifier* identifier = new TypeIdentifier(); - identifier->_d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().union_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier->equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimpleBadDiscUnion", identifier, type_object); - delete type_object; - delete identifier; - return TypeObjectFactory::get_instance()->get_type_object("SimpleBadDiscUnion", false); -} - -const TypeObject* GetCompleteSimpleBadDiscUnionObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleBadDiscUnion", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_UNION); - - type_object->complete().union_type().union_flags().IS_FINAL(false); - type_object->complete().union_type().union_flags().IS_APPENDABLE(false); - type_object->complete().union_type().union_flags().IS_MUTABLE(false); - type_object->complete().union_type().union_flags().IS_NESTED(false); - type_object->complete().union_type().union_flags().IS_AUTOID_HASH(false); // Unsupported - - type_object->complete().union_type().discriminator().common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().IS_EXTERNAL(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_OPTIONAL(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - type_object->complete().union_type().discriminator().common().member_flags().IS_KEY(false); // Unsupported - type_object->complete().union_type().discriminator().common().member_flags().IS_DEFAULT(false); // Doesn't apply - - type_object->complete().union_type().discriminator().common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("uint8_t", false)); - - MemberId memberId = 0; - CompleteUnionMember cst_first; - cst_first.common().member_id(memberId++); - cst_first.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_first.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_first.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_first.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - cst_first.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cst_first.common().member_flags().IS_KEY(false); // Doesn't apply - cst_first.common().member_flags().IS_DEFAULT(false); - cst_first.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int32_t", false)); - - cst_first.common().label_seq().emplace_back(0); - - - cst_first.detail().name("first"); - - type_object->complete().union_type().member_seq().emplace_back(cst_first); - - CompleteUnionMember cst_second; - cst_second.common().member_id(memberId++); - cst_second.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_second.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_second.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_second.common().member_flags().IS_OPTIONAL(false); // Doesn't apply - cst_second.common().member_flags().IS_MUST_UNDERSTAND(false); // Doesn't apply - cst_second.common().member_flags().IS_KEY(false); // Doesn't apply - cst_second.common().member_flags().IS_DEFAULT(false); - cst_second.common().type_id(*TypeObjectFactory::get_instance()->get_type_identifier("int64_t", false)); - - cst_second.common().label_seq().emplace_back(1); - - - cst_second.detail().name("second"); - - type_object->complete().union_type().member_seq().emplace_back(cst_second); - - - // Header - type_object->complete().union_type().header().detail().type_name("SimpleBadDiscUnion"); - - TypeIdentifier* identifier = new TypeIdentifier(); - identifier->_d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().union_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier->equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimpleBadDiscUnion", identifier, type_object); - delete type_object; - delete identifier; - return TypeObjectFactory::get_instance()->get_type_object("SimpleBadDiscUnion", true); -} - - - -const TypeIdentifier* GetSimpleUnionStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("SimpleUnionStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetSimpleUnionStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("SimpleUnionStruct", complete); -} - -const TypeObject* GetSimpleUnionStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleUnionStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteSimpleUnionStructObject(); - } - //else - return GetMinimalSimpleUnionStructObject(); -} - -const TypeObject* GetMinimalSimpleUnionStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleUnionStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_union; - mst_my_union.common().member_id(memberId++); - mst_my_union.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_union.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_union.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_union.common().member_flags().IS_OPTIONAL(false); - mst_my_union.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_union.common().member_flags().IS_KEY(false); - mst_my_union.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_union.common().member_type_id(*GetSimpleUnionIdentifier(false)); - - MD5 my_union_hash("my_union"); - for(int i = 0; i < 4; ++i) - { - mst_my_union.detail().name_hash()[i] = my_union_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_union); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimpleUnionStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SimpleUnionStruct", false); -} - -const TypeObject* GetCompleteSimpleUnionStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleUnionStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_union; - cst_my_union.common().member_id(memberId++); - cst_my_union.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_union.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_union.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_union.common().member_flags().IS_OPTIONAL(false); - cst_my_union.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_union.common().member_flags().IS_KEY(false); - cst_my_union.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_union.common().member_type_id(*GetSimpleUnionIdentifier(true)); - - cst_my_union.detail().name("my_union"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_union); - - - // Header - type_object->complete().struct_type().header().detail().type_name("SimpleUnionStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimpleUnionStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SimpleUnionStruct", true); -} - - - -const TypeIdentifier* GetSimpleUnionStructEqualIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("SimpleUnionStructEqual", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetSimpleUnionStructEqualObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("SimpleUnionStructEqual", complete); -} - -const TypeObject* GetSimpleUnionStructEqualObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleUnionStructEqual", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteSimpleUnionStructEqualObject(); - } - //else - return GetMinimalSimpleUnionStructEqualObject(); -} - -const TypeObject* GetMinimalSimpleUnionStructEqualObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleUnionStructEqual", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_union_equal; - mst_my_union_equal.common().member_id(memberId++); - mst_my_union_equal.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_union_equal.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_union_equal.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_union_equal.common().member_flags().IS_OPTIONAL(false); - mst_my_union_equal.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_union_equal.common().member_flags().IS_KEY(false); - mst_my_union_equal.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_union_equal.common().member_type_id(*GetSimpleUnionIdentifier(false)); - - MD5 my_union_equal_hash("my_union_equal"); - for(int i = 0; i < 4; ++i) - { - mst_my_union_equal.detail().name_hash()[i] = my_union_equal_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_union_equal); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimpleUnionStructEqual", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SimpleUnionStructEqual", false); -} - -const TypeObject* GetCompleteSimpleUnionStructEqualObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleUnionStructEqual", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_union_equal; - cst_my_union_equal.common().member_id(memberId++); - cst_my_union_equal.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_union_equal.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_union_equal.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_union_equal.common().member_flags().IS_OPTIONAL(false); - cst_my_union_equal.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_union_equal.common().member_flags().IS_KEY(false); - cst_my_union_equal.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_union_equal.common().member_type_id(*GetSimpleUnionIdentifier(true)); - - cst_my_union_equal.detail().name("my_union_equal"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_union_equal); - - - // Header - type_object->complete().struct_type().header().detail().type_name("SimpleUnionStructEqual"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimpleUnionStructEqual", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SimpleUnionStructEqual", true); -} - - - -const TypeIdentifier* GetSimpleUnionNamesStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("SimpleUnionNamesStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetSimpleUnionNamesStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("SimpleUnionNamesStruct", complete); -} - -const TypeObject* GetSimpleUnionNamesStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleUnionNamesStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteSimpleUnionNamesStructObject(); - } - //else - return GetMinimalSimpleUnionNamesStructObject(); -} - -const TypeObject* GetMinimalSimpleUnionNamesStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleUnionNamesStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_union; - mst_my_union.common().member_id(memberId++); - mst_my_union.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_union.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_union.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_union.common().member_flags().IS_OPTIONAL(false); - mst_my_union.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_union.common().member_flags().IS_KEY(false); - mst_my_union.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_union.common().member_type_id(*GetSimpleUnionNamesIdentifier(false)); - - MD5 my_union_hash("my_union"); - for(int i = 0; i < 4; ++i) - { - mst_my_union.detail().name_hash()[i] = my_union_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_union); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimpleUnionNamesStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SimpleUnionNamesStruct", false); -} - -const TypeObject* GetCompleteSimpleUnionNamesStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleUnionNamesStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_union; - cst_my_union.common().member_id(memberId++); - cst_my_union.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_union.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_union.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_union.common().member_flags().IS_OPTIONAL(false); - cst_my_union.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_union.common().member_flags().IS_KEY(false); - cst_my_union.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_union.common().member_type_id(*GetSimpleUnionNamesIdentifier(true)); - - cst_my_union.detail().name("my_union"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_union); - - - // Header - type_object->complete().struct_type().header().detail().type_name("SimpleUnionNamesStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimpleUnionNamesStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SimpleUnionNamesStruct", true); -} - - - -const TypeIdentifier* GetSimpleTypeUnionStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("SimpleTypeUnionStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetSimpleTypeUnionStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("SimpleTypeUnionStruct", complete); -} - -const TypeObject* GetSimpleTypeUnionStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleTypeUnionStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteSimpleTypeUnionStructObject(); - } - //else - return GetMinimalSimpleTypeUnionStructObject(); -} - -const TypeObject* GetMinimalSimpleTypeUnionStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleTypeUnionStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_union; - mst_my_union.common().member_id(memberId++); - mst_my_union.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_union.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_union.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_union.common().member_flags().IS_OPTIONAL(false); - mst_my_union.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_union.common().member_flags().IS_KEY(false); - mst_my_union.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_union.common().member_type_id(*GetSimpleTypeUnionIdentifier(false)); - - MD5 my_union_hash("my_union"); - for(int i = 0; i < 4; ++i) - { - mst_my_union.detail().name_hash()[i] = my_union_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_union); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimpleTypeUnionStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SimpleTypeUnionStruct", false); -} - -const TypeObject* GetCompleteSimpleTypeUnionStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleTypeUnionStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_union; - cst_my_union.common().member_id(memberId++); - cst_my_union.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_union.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_union.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_union.common().member_flags().IS_OPTIONAL(false); - cst_my_union.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_union.common().member_flags().IS_KEY(false); - cst_my_union.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_union.common().member_type_id(*GetSimpleTypeUnionIdentifier(true)); - - cst_my_union.detail().name("my_union"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_union); - - - // Header - type_object->complete().struct_type().header().detail().type_name("SimpleTypeUnionStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimpleTypeUnionStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SimpleTypeUnionStruct", true); -} - - - -const TypeIdentifier* GetSimpleBadUnionStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("SimpleBadUnionStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetSimpleBadUnionStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("SimpleBadUnionStruct", complete); -} - -const TypeObject* GetSimpleBadUnionStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleBadUnionStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteSimpleBadUnionStructObject(); - } - //else - return GetMinimalSimpleBadUnionStructObject(); -} - -const TypeObject* GetMinimalSimpleBadUnionStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleBadUnionStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_union; - mst_my_union.common().member_id(memberId++); - mst_my_union.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_union.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_union.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_union.common().member_flags().IS_OPTIONAL(false); - mst_my_union.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_union.common().member_flags().IS_KEY(false); - mst_my_union.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_union.common().member_type_id(*GetSimpleBadUnionIdentifier(false)); - - MD5 my_union_hash("my_union"); - for(int i = 0; i < 4; ++i) - { - mst_my_union.detail().name_hash()[i] = my_union_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_union); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimpleBadUnionStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SimpleBadUnionStruct", false); -} - -const TypeObject* GetCompleteSimpleBadUnionStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimpleBadUnionStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_union; - cst_my_union.common().member_id(memberId++); - cst_my_union.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_union.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_union.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_union.common().member_flags().IS_OPTIONAL(false); - cst_my_union.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_union.common().member_flags().IS_KEY(false); - cst_my_union.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_union.common().member_type_id(*GetSimpleBadUnionIdentifier(true)); - - cst_my_union.detail().name("my_union"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_union); - - - // Header - type_object->complete().struct_type().header().detail().type_name("SimpleBadUnionStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimpleBadUnionStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SimpleBadUnionStruct", true); -} - - - -const TypeIdentifier* GetSimplBadDiscUnionStructIdentifier(bool complete) -{ - const TypeIdentifier * c_identifier = TypeObjectFactory::get_instance()->get_type_identifier("SimplBadDiscUnionStruct", complete); - if (c_identifier != nullptr && (!complete || c_identifier->_d() == EK_COMPLETE)) - { - return c_identifier; - } - - GetSimplBadDiscUnionStructObject(complete); // Generated inside - return TypeObjectFactory::get_instance()->get_type_identifier("SimplBadDiscUnionStruct", complete); -} - -const TypeObject* GetSimplBadDiscUnionStructObject(bool complete) -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimplBadDiscUnionStruct", complete); - if (c_type_object != nullptr) - { - return c_type_object; - } - else if (complete) - { - return GetCompleteSimplBadDiscUnionStructObject(); - } - //else - return GetMinimalSimplBadDiscUnionStructObject(); -} - -const TypeObject* GetMinimalSimplBadDiscUnionStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimplBadDiscUnionStruct", false); - if (c_type_object != nullptr) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_MINIMAL); - type_object->minimal()._d(TK_STRUCTURE); - - type_object->minimal().struct_type().struct_flags().IS_FINAL(false); - type_object->minimal().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->minimal().struct_type().struct_flags().IS_MUTABLE(false); - type_object->minimal().struct_type().struct_flags().IS_NESTED(false); - type_object->minimal().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - MinimalStructMember mst_my_union; - mst_my_union.common().member_id(memberId++); - mst_my_union.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - mst_my_union.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - mst_my_union.common().member_flags().IS_EXTERNAL(false); // Unsupported - mst_my_union.common().member_flags().IS_OPTIONAL(false); - mst_my_union.common().member_flags().IS_MUST_UNDERSTAND(false); - mst_my_union.common().member_flags().IS_KEY(false); - mst_my_union.common().member_flags().IS_DEFAULT(false); // Doesn't apply - mst_my_union.common().member_type_id(*GetSimpleBadDiscUnionIdentifier(false)); - - MD5 my_union_hash("my_union"); - for(int i = 0; i < 4; ++i) - { - mst_my_union.detail().name_hash()[i] = my_union_hash.digest[i]; - } - type_object->minimal().struct_type().member_seq().emplace_back(mst_my_union); - - - // Header - // TODO Inheritance - //type_object->minimal().struct_type().header().base_type()._d(EK_MINIMAL); - //type_object->minimal().struct_type().header().base_type().equivalence_hash()[0..13]; - TypeIdentifier identifier; - identifier._d(EK_MINIMAL); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->minimal().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimplBadDiscUnionStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SimplBadDiscUnionStruct", false); -} - -const TypeObject* GetCompleteSimplBadDiscUnionStructObject() -{ - const TypeObject* c_type_object = TypeObjectFactory::get_instance()->get_type_object("SimplBadDiscUnionStruct", true); - if (c_type_object != nullptr && c_type_object->_d() == EK_COMPLETE) - { - return c_type_object; - } - - TypeObject *type_object = new TypeObject(); - type_object->_d(EK_COMPLETE); - type_object->complete()._d(TK_STRUCTURE); - - type_object->complete().struct_type().struct_flags().IS_FINAL(false); - type_object->complete().struct_type().struct_flags().IS_APPENDABLE(false); - type_object->complete().struct_type().struct_flags().IS_MUTABLE(false); - type_object->complete().struct_type().struct_flags().IS_NESTED(false); - type_object->complete().struct_type().struct_flags().IS_AUTOID_HASH(false); // Unsupported - - MemberId memberId = 0; - CompleteStructMember cst_my_union; - cst_my_union.common().member_id(memberId++); - cst_my_union.common().member_flags().TRY_CONSTRUCT1(false); // Unsupported - cst_my_union.common().member_flags().TRY_CONSTRUCT2(false); // Unsupported - cst_my_union.common().member_flags().IS_EXTERNAL(false); // Unsupported - cst_my_union.common().member_flags().IS_OPTIONAL(false); - cst_my_union.common().member_flags().IS_MUST_UNDERSTAND(false); - cst_my_union.common().member_flags().IS_KEY(false); - cst_my_union.common().member_flags().IS_DEFAULT(false); // Doesn't apply - cst_my_union.common().member_type_id(*GetSimpleBadDiscUnionIdentifier(true)); - - cst_my_union.detail().name("my_union"); - - type_object->complete().struct_type().member_seq().emplace_back(cst_my_union); - - - // Header - type_object->complete().struct_type().header().detail().type_name("SimplBadDiscUnionStruct"); - // TODO inheritance - TypeIdentifier identifier; - identifier._d(EK_COMPLETE); - - eprosima::fastcdr::CdrSizeCalculator calculator(eprosima::fastcdr::CdrVersion::XCDRv1); - size_t current_alignment {0}; - SerializedPayload_t payload(static_cast( - calculator.calculate_serialized_size(type_object->complete().struct_type(), current_alignment) + 4)); - eprosima::fastcdr::FastBuffer fastbuffer((char*) payload.data, payload.max_size); - // Fixed endian (Page 221, EquivalenceHash definition of Extensible and Dynamic Topic Types for DDS document) - eprosima::fastcdr::Cdr ser( - fastbuffer, eprosima::fastcdr::Cdr::LITTLE_ENDIANNESS, - eprosima::fastcdr::CdrVersion::XCDRv1); // Object that serializes the data. - payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; - - ser << *type_object; -#if FASTCDR_VERSION_MAJOR == 1 - payload.length = (uint32_t)ser.getSerializedDataLength(); //Get the serialized length -#else - payload.length = (uint32_t)ser.get_serialized_data_length(); //Get the serialized length -#endif // FASTCDR_VERSION_MAJOR == 1 - MD5 objectHash; - objectHash.update((char*)payload.data, payload.length); - objectHash.finalize(); - for(int i = 0; i < 14; ++i) - { - identifier.equivalence_hash()[i] = objectHash.digest[i]; - } - - TypeObjectFactory::get_instance()->add_type_object("SimplBadDiscUnionStruct", &identifier, type_object); - delete type_object; - return TypeObjectFactory::get_instance()->get_type_object("SimplBadDiscUnionStruct", true); -} diff --git a/test/xtypes/idl/TypesTypeObject.h b/test/xtypes/idl/TypesTypeObject.h deleted file mode 100644 index 2f615b62792..00000000000 --- a/test/xtypes/idl/TypesTypeObject.h +++ /dev/null @@ -1,394 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file TypesTypeObject.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifndef _FAST_DDS_GENERATED_TYPES_TYPE_OBJECT_H_ -#define _FAST_DDS_GENERATED_TYPES_TYPE_OBJECT_H_ - - -#include -#include - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif -#else -#define eProsima_user_DllExport -#endif - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(Types_SOURCE) -#define Types_DllAPI __declspec( dllexport ) -#else -#define Types_DllAPI __declspec( dllimport ) -#endif // Types_SOURCE -#else -#define Types_DllAPI -#endif -#else -#define Types_DllAPI -#endif // _WIN32 - -using namespace eprosima::fastrtps::types; - -eProsima_user_DllExport void registerTypesTypes(); - -eProsima_user_DllExport const TypeIdentifier* GetMyEnumIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMyEnumObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalMyEnumObject(); -eProsima_user_DllExport const TypeObject* GetCompleteMyEnumObject(); - -eProsima_user_DllExport const TypeIdentifier* GetMyBadEnumIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMyBadEnumObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalMyBadEnumObject(); -eProsima_user_DllExport const TypeObject* GetCompleteMyBadEnumObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetMyEnumStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMyEnumStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalMyEnumStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteMyEnumStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetMyBadEnumStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMyBadEnumStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalMyBadEnumStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteMyBadEnumStructObject(); - -eProsima_user_DllExport const TypeIdentifier* GetMyAliasEnumIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMyAliasEnumObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalMyAliasEnumObject(); -eProsima_user_DllExport const TypeObject* GetCompleteMyAliasEnumObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetMyAliasEnumStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMyAliasEnumStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalMyAliasEnumStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteMyAliasEnumStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetBasicStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetBasicStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalBasicStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteBasicStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetBasicNamesStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetBasicNamesStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalBasicNamesStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteBasicNamesStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetBasicBadStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetBasicBadStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalBasicBadStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteBasicBadStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetBasicWideStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetBasicWideStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalBasicWideStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteBasicWideStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetBadBasicWideStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetBadBasicWideStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalBadBasicWideStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteBadBasicWideStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetStringStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetStringStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalStringStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteStringStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetLargeStringStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetLargeStringStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalLargeStringStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteLargeStringStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetWStringStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetWStringStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalWStringStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteWStringStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetLargeWStringStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetLargeWStringStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalLargeWStringStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteLargeWStringStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetArrayStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetArrayStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalArrayStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteArrayStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetArrayStructEqualIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetArrayStructEqualObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalArrayStructEqualObject(); -eProsima_user_DllExport const TypeObject* GetCompleteArrayStructEqualObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetArrayBadStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetArrayBadStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalArrayBadStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteArrayBadStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetArrayDimensionsStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetArrayDimensionsStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalArrayDimensionsStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteArrayDimensionsStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetArraySizeStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetArraySizeStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalArraySizeStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteArraySizeStructObject(); - - - - - -eProsima_user_DllExport const TypeIdentifier* GetSequenceStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetSequenceStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalSequenceStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteSequenceStructObject(); - - - - - -eProsima_user_DllExport const TypeIdentifier* GetSequenceStructEqualIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetSequenceStructEqualObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalSequenceStructEqualObject(); -eProsima_user_DllExport const TypeObject* GetCompleteSequenceStructEqualObject(); - - - - - -eProsima_user_DllExport const TypeIdentifier* GetSequenceBadStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetSequenceBadStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalSequenceBadStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteSequenceBadStructObject(); - - - - - -eProsima_user_DllExport const TypeIdentifier* GetSequenceBoundsStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetSequenceBoundsStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalSequenceBoundsStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteSequenceBoundsStructObject(); - - - - - - - -eProsima_user_DllExport const TypeIdentifier* GetSequenceSequenceStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetSequenceSequenceStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalSequenceSequenceStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteSequenceSequenceStructObject(); - - - - - - - -eProsima_user_DllExport const TypeIdentifier* GetSequenceSequenceBoundsStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetSequenceSequenceBoundsStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalSequenceSequenceBoundsStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteSequenceSequenceBoundsStructObject(); - - - - - -eProsima_user_DllExport const TypeIdentifier* GetMapStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMapStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalMapStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteMapStructObject(); - - - - - -eProsima_user_DllExport const TypeIdentifier* GetMapStructEqualIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMapStructEqualObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalMapStructEqualObject(); -eProsima_user_DllExport const TypeObject* GetCompleteMapStructEqualObject(); - - - - - -eProsima_user_DllExport const TypeIdentifier* GetMapBadKeyStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMapBadKeyStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalMapBadKeyStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteMapBadKeyStructObject(); - - - - - -eProsima_user_DllExport const TypeIdentifier* GetMapBadElemStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMapBadElemStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalMapBadElemStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteMapBadElemStructObject(); - - - - - -eProsima_user_DllExport const TypeIdentifier* GetMapBoundsStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMapBoundsStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalMapBoundsStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteMapBoundsStructObject(); - - - - - - - -eProsima_user_DllExport const TypeIdentifier* GetMapMapStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMapMapStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalMapMapStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteMapMapStructObject(); - - - - - - - -eProsima_user_DllExport const TypeIdentifier* GetMapMapBoundsStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMapMapBoundsStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalMapMapBoundsStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteMapMapBoundsStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetSimpleUnionIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetSimpleUnionObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalSimpleUnionObject(); -eProsima_user_DllExport const TypeObject* GetCompleteSimpleUnionObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetSimpleUnionNamesIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetSimpleUnionNamesObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalSimpleUnionNamesObject(); -eProsima_user_DllExport const TypeObject* GetCompleteSimpleUnionNamesObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetSimpleTypeUnionIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetSimpleTypeUnionObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalSimpleTypeUnionObject(); -eProsima_user_DllExport const TypeObject* GetCompleteSimpleTypeUnionObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetSimpleBadUnionIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetSimpleBadUnionObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalSimpleBadUnionObject(); -eProsima_user_DllExport const TypeObject* GetCompleteSimpleBadUnionObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetSimpleBadDiscUnionIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetSimpleBadDiscUnionObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalSimpleBadDiscUnionObject(); -eProsima_user_DllExport const TypeObject* GetCompleteSimpleBadDiscUnionObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetSimpleUnionStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetSimpleUnionStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalSimpleUnionStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteSimpleUnionStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetSimpleUnionStructEqualIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetSimpleUnionStructEqualObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalSimpleUnionStructEqualObject(); -eProsima_user_DllExport const TypeObject* GetCompleteSimpleUnionStructEqualObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetSimpleUnionNamesStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetSimpleUnionNamesStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalSimpleUnionNamesStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteSimpleUnionNamesStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetSimpleTypeUnionStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetSimpleTypeUnionStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalSimpleTypeUnionStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteSimpleTypeUnionStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetSimpleBadUnionStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetSimpleBadUnionStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalSimpleBadUnionStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteSimpleBadUnionStructObject(); - - - -eProsima_user_DllExport const TypeIdentifier* GetSimplBadDiscUnionStructIdentifier(bool complete = false); -eProsima_user_DllExport const TypeObject* GetSimplBadDiscUnionStructObject(bool complete = false); -eProsima_user_DllExport const TypeObject* GetMinimalSimplBadDiscUnionStructObject(); -eProsima_user_DllExport const TypeObject* GetCompleteSimplBadDiscUnionStructObject(); - - -#endif // _FAST_DDS_GENERATED_TYPES_TYPE_OBJECT_H_ \ No newline at end of file diff --git a/test/xtypes/idl/Typesv1.cxx b/test/xtypes/idl/Typesv1.cxx deleted file mode 100644 index 54b0d494ecc..00000000000 --- a/test/xtypes/idl/Typesv1.cxx +++ /dev/null @@ -1,8202 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file Types.cpp - * This source file contains the implementation of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#ifdef _WIN32 -// Remove linker warning LNK4221 on Visual Studio -namespace { -char dummy; -} // namespace -#endif // _WIN32 - -#include "Types.h" - -#if FASTCDR_VERSION_MAJOR == 1 - -#include "TypesTypeObject.h" - -#include - - -#include -using namespace eprosima::fastcdr::exception; - -#include - -namespace helper { namespace internal { - -enum class Size { - UInt8, - UInt16, - UInt32, - UInt64, -}; - -constexpr Size get_size(int s) { - return (s <= 8 ) ? Size::UInt8: - (s <= 16) ? Size::UInt16: - (s <= 32) ? Size::UInt32: Size::UInt64; -} - -template -struct FindTypeH; - -template<> -struct FindTypeH { - using type = std::uint8_t; -}; - -template<> -struct FindTypeH { - using type = std::uint16_t; -}; - -template<> -struct FindTypeH { - using type = std::uint32_t; -}; - -template<> -struct FindTypeH { - using type = std::uint64_t; -}; -} - -template -struct FindType { - using type = typename internal::FindTypeH::type; -}; -} - -#define SimpleUnionStruct_max_cdr_typesize 24ULL; -#define SequenceSequenceBoundsStruct_max_cdr_typesize 132ULL; - -#define MyAliasEnumStruct_max_cdr_typesize 8ULL; -#define ArrayBadStruct_max_cdr_typesize 6ULL; -#define MapBadKeyStruct_max_cdr_typesize 24ULL; -#define SimpleBadUnionStruct_max_cdr_typesize 24ULL; -#define MyEnumStruct_max_cdr_typesize 8ULL; - -#define ArrayStructEqual_max_cdr_typesize 12ULL; -#define LargeWStringStruct_max_cdr_typesize 167708ULL; - -#define WStringStruct_max_cdr_typesize 1028ULL; -#define SequenceStruct_max_cdr_typesize 16ULL; -#define SimpleTypeUnionStruct_max_cdr_typesize 24ULL; - -#define ArrayDimensionsStruct_max_cdr_typesize 20ULL; -#define SequenceSequenceStruct_max_cdr_typesize 48ULL; -#define MapBoundsStruct_max_cdr_typesize 40ULL; -#define SequenceStructEqual_max_cdr_typesize 16ULL; -#define MapStructEqual_max_cdr_typesize 24ULL; -#define BasicStruct_max_cdr_typesize 272ULL; -#define SequenceBoundsStruct_max_cdr_typesize 24ULL; -#define MapMapStruct_max_cdr_typesize 60ULL; -#define BasicWideStruct_max_cdr_typesize 536ULL; - -#define SimplBadDiscUnionStruct_max_cdr_typesize 24ULL; -#define MapStruct_max_cdr_typesize 24ULL; - -#define MyBadEnumStruct_max_cdr_typesize 8ULL; -#define SequenceBadStruct_max_cdr_typesize 10ULL; -#define SimpleUnionNamesStruct_max_cdr_typesize 24ULL; -#define LargeStringStruct_max_cdr_typesize 41934ULL; -#define ArrayStruct_max_cdr_typesize 12ULL; -#define BadBasicWideStruct_max_cdr_typesize 536ULL; -#define ArraySizeStruct_max_cdr_typesize 24ULL; - -#define MapBadElemStruct_max_cdr_typesize 40ULL; -#define SimpleUnionStructEqual_max_cdr_typesize 24ULL; -#define BasicBadStruct_max_cdr_typesize 272ULL; -#define BasicNamesStruct_max_cdr_typesize 272ULL; -#define StringStruct_max_cdr_typesize 264ULL; - -#define MapMapBoundsStruct_max_cdr_typesize 108ULL; - - - - -MyEnumStruct::MyEnumStruct() -{ - // MyEnum m_my_enum - m_my_enum = ::A; - - // Just to register all known types - registerTypesTypes(); -} - -MyEnumStruct::~MyEnumStruct() -{ -} - -MyEnumStruct::MyEnumStruct( - const MyEnumStruct& x) -{ - m_my_enum = x.m_my_enum; - -} - -MyEnumStruct::MyEnumStruct( - MyEnumStruct&& x) noexcept -{ - m_my_enum = x.m_my_enum; - -} - -MyEnumStruct& MyEnumStruct::operator =( - const MyEnumStruct& x) -{ - m_my_enum = x.m_my_enum; - - return *this; -} - -MyEnumStruct& MyEnumStruct::operator =( - MyEnumStruct&& x) noexcept -{ - m_my_enum = x.m_my_enum; - - return *this; -} - -bool MyEnumStruct::operator ==( - const MyEnumStruct& x) const -{ - return (m_my_enum == x.m_my_enum); -} - -bool MyEnumStruct::operator !=( - const MyEnumStruct& x) const -{ - return !(*this == x); -} - -size_t MyEnumStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return MyEnumStruct_max_cdr_typesize; -} - -size_t MyEnumStruct::getCdrSerializedSize( - const MyEnumStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - return current_alignment - initial_alignment; -} - - -void MyEnumStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << (uint32_t)m_my_enum; - -} - -void MyEnumStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - { - uint32_t enum_value = 0; - dcdr >> enum_value; - m_my_enum = (MyEnum)enum_value; - } - - -} - - -bool MyEnumStruct::isKeyDefined() -{ - return false; -} - -void MyEnumStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member my_enum - * @param _my_enum New value for member my_enum - */ -void MyEnumStruct::my_enum( - MyEnum _my_enum) -{ - m_my_enum = _my_enum; -} - -/*! - * @brief This function returns the value of member my_enum - * @return Value of member my_enum - */ -MyEnum MyEnumStruct::my_enum() const -{ - return m_my_enum; -} - -/*! - * @brief This function returns a reference to member my_enum - * @return Reference to member my_enum - */ -MyEnum& MyEnumStruct::my_enum() -{ - return m_my_enum; -} - - - - - -MyBadEnumStruct::MyBadEnumStruct() -{ - // MyBadEnum m_my_enum - m_my_enum = ::A1; - - // Just to register all known types - registerTypesTypes(); -} - -MyBadEnumStruct::~MyBadEnumStruct() -{ -} - -MyBadEnumStruct::MyBadEnumStruct( - const MyBadEnumStruct& x) -{ - m_my_enum = x.m_my_enum; - -} - -MyBadEnumStruct::MyBadEnumStruct( - MyBadEnumStruct&& x) noexcept -{ - m_my_enum = x.m_my_enum; - -} - -MyBadEnumStruct& MyBadEnumStruct::operator =( - const MyBadEnumStruct& x) -{ - m_my_enum = x.m_my_enum; - - return *this; -} - -MyBadEnumStruct& MyBadEnumStruct::operator =( - MyBadEnumStruct&& x) noexcept -{ - m_my_enum = x.m_my_enum; - - return *this; -} - -bool MyBadEnumStruct::operator ==( - const MyBadEnumStruct& x) const -{ - return (m_my_enum == x.m_my_enum); -} - -bool MyBadEnumStruct::operator !=( - const MyBadEnumStruct& x) const -{ - return !(*this == x); -} - -size_t MyBadEnumStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return MyBadEnumStruct_max_cdr_typesize; -} - -size_t MyBadEnumStruct::getCdrSerializedSize( - const MyBadEnumStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - return current_alignment - initial_alignment; -} - - -void MyBadEnumStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << (uint32_t)m_my_enum; - -} - -void MyBadEnumStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - { - uint32_t enum_value = 0; - dcdr >> enum_value; - m_my_enum = (MyBadEnum)enum_value; - } - - -} - - -bool MyBadEnumStruct::isKeyDefined() -{ - return false; -} - -void MyBadEnumStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member my_enum - * @param _my_enum New value for member my_enum - */ -void MyBadEnumStruct::my_enum( - MyBadEnum _my_enum) -{ - m_my_enum = _my_enum; -} - -/*! - * @brief This function returns the value of member my_enum - * @return Value of member my_enum - */ -MyBadEnum MyBadEnumStruct::my_enum() const -{ - return m_my_enum; -} - -/*! - * @brief This function returns a reference to member my_enum - * @return Reference to member my_enum - */ -MyBadEnum& MyBadEnumStruct::my_enum() -{ - return m_my_enum; -} - - - - - - -MyAliasEnumStruct::MyAliasEnumStruct() -{ - // MyAliasEnum m_my_enum - m_my_enum = ::A; - - // Just to register all known types - registerTypesTypes(); -} - -MyAliasEnumStruct::~MyAliasEnumStruct() -{ -} - -MyAliasEnumStruct::MyAliasEnumStruct( - const MyAliasEnumStruct& x) -{ - m_my_enum = x.m_my_enum; - -} - -MyAliasEnumStruct::MyAliasEnumStruct( - MyAliasEnumStruct&& x) noexcept -{ - m_my_enum = x.m_my_enum; - -} - -MyAliasEnumStruct& MyAliasEnumStruct::operator =( - const MyAliasEnumStruct& x) -{ - m_my_enum = x.m_my_enum; - - return *this; -} - -MyAliasEnumStruct& MyAliasEnumStruct::operator =( - MyAliasEnumStruct&& x) noexcept -{ - m_my_enum = x.m_my_enum; - - return *this; -} - -bool MyAliasEnumStruct::operator ==( - const MyAliasEnumStruct& x) const -{ - return (m_my_enum == x.m_my_enum); -} - -bool MyAliasEnumStruct::operator !=( - const MyAliasEnumStruct& x) const -{ - return !(*this == x); -} - -size_t MyAliasEnumStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return MyAliasEnumStruct_max_cdr_typesize; -} - -size_t MyAliasEnumStruct::getCdrSerializedSize( - const MyAliasEnumStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - return current_alignment - initial_alignment; -} - - -void MyAliasEnumStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << (uint32_t)m_my_enum; - -} - -void MyAliasEnumStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - { - uint32_t enum_value = 0; - dcdr >> enum_value; - m_my_enum = (MyAliasEnum)enum_value; - } - - -} - - -bool MyAliasEnumStruct::isKeyDefined() -{ - return false; -} - -void MyAliasEnumStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member my_enum - * @param _my_enum New value for member my_enum - */ -void MyAliasEnumStruct::my_enum( - MyAliasEnum _my_enum) -{ - m_my_enum = _my_enum; -} - -/*! - * @brief This function returns the value of member my_enum - * @return Value of member my_enum - */ -MyAliasEnum MyAliasEnumStruct::my_enum() const -{ - return m_my_enum; -} - -/*! - * @brief This function returns a reference to member my_enum - * @return Reference to member my_enum - */ -MyAliasEnum& MyAliasEnumStruct::my_enum() -{ - return m_my_enum; -} - - - - - -BasicStruct::BasicStruct() -{ - // boolean m_my_bool - m_my_bool = false; - // long m_my_int32 - m_my_int32 = 0; - // /type_d() m_my_string - - - // Just to register all known types - registerTypesTypes(); -} - -BasicStruct::~BasicStruct() -{ -} - -BasicStruct::BasicStruct( - const BasicStruct& x) -{ - m_my_bool = x.m_my_bool; - - - m_my_int32 = x.m_my_int32; - - - m_my_string = x.m_my_string; - -} - -BasicStruct::BasicStruct( - BasicStruct&& x) noexcept -{ - m_my_bool = x.m_my_bool; - - - m_my_int32 = x.m_my_int32; - - - m_my_string = std::move(x.m_my_string); - -} - -BasicStruct& BasicStruct::operator =( - const BasicStruct& x) -{ - m_my_bool = x.m_my_bool; - - - m_my_int32 = x.m_my_int32; - - - m_my_string = x.m_my_string; - - return *this; -} - -BasicStruct& BasicStruct::operator =( - BasicStruct&& x) noexcept -{ - m_my_bool = x.m_my_bool; - - - m_my_int32 = x.m_my_int32; - - - m_my_string = std::move(x.m_my_string); - - return *this; -} - -bool BasicStruct::operator ==( - const BasicStruct& x) const -{ - return (m_my_bool == x.m_my_bool && - m_my_int32 == x.m_my_int32 && - m_my_string == x.m_my_string); -} - -bool BasicStruct::operator !=( - const BasicStruct& x) const -{ - return !(*this == x); -} - -size_t BasicStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return BasicStruct_max_cdr_typesize; -} - -size_t BasicStruct::getCdrSerializedSize( - const BasicStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + data.my_string().size() + 1; - - - return current_alignment - initial_alignment; -} - - -void BasicStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_bool; - - scdr << m_my_int32; - - scdr << m_my_string.c_str(); - -} - -void BasicStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_bool; - - - - dcdr >> m_my_int32; - - - - dcdr >> m_my_string; - - -} - - -bool BasicStruct::isKeyDefined() -{ - return false; -} - -void BasicStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member my_bool - * @param _my_bool New value for member my_bool - */ -void BasicStruct::my_bool( - bool _my_bool) -{ - m_my_bool = _my_bool; -} - -/*! - * @brief This function returns the value of member my_bool - * @return Value of member my_bool - */ -bool BasicStruct::my_bool() const -{ - return m_my_bool; -} - -/*! - * @brief This function returns a reference to member my_bool - * @return Reference to member my_bool - */ -bool& BasicStruct::my_bool() -{ - return m_my_bool; -} - - -/*! - * @brief This function sets a value in member my_int32 - * @param _my_int32 New value for member my_int32 - */ -void BasicStruct::my_int32( - int32_t _my_int32) -{ - m_my_int32 = _my_int32; -} - -/*! - * @brief This function returns the value of member my_int32 - * @return Value of member my_int32 - */ -int32_t BasicStruct::my_int32() const -{ - return m_my_int32; -} - -/*! - * @brief This function returns a reference to member my_int32 - * @return Reference to member my_int32 - */ -int32_t& BasicStruct::my_int32() -{ - return m_my_int32; -} - - -/*! - * @brief This function copies the value in member my_string - * @param _my_string New value to be copied in member my_string - */ -void BasicStruct::my_string( - const std::string& _my_string) -{ - m_my_string = _my_string; -} - -/*! - * @brief This function moves the value in member my_string - * @param _my_string New value to be moved in member my_string - */ -void BasicStruct::my_string( - std::string&& _my_string) -{ - m_my_string = std::move(_my_string); -} - -/*! - * @brief This function returns a constant reference to member my_string - * @return Constant reference to member my_string - */ -const std::string& BasicStruct::my_string() const -{ - return m_my_string; -} - -/*! - * @brief This function returns a reference to member my_string - * @return Reference to member my_string - */ -std::string& BasicStruct::my_string() -{ - return m_my_string; -} - - - - - -BasicNamesStruct::BasicNamesStruct() -{ - // boolean m_my_bool_name - m_my_bool_name = false; - // long m_my_int32_name - m_my_int32_name = 0; - // /type_d() m_my_string_name - - - // Just to register all known types - registerTypesTypes(); -} - -BasicNamesStruct::~BasicNamesStruct() -{ -} - -BasicNamesStruct::BasicNamesStruct( - const BasicNamesStruct& x) -{ - m_my_bool_name = x.m_my_bool_name; - - - m_my_int32_name = x.m_my_int32_name; - - - m_my_string_name = x.m_my_string_name; - -} - -BasicNamesStruct::BasicNamesStruct( - BasicNamesStruct&& x) noexcept -{ - m_my_bool_name = x.m_my_bool_name; - - - m_my_int32_name = x.m_my_int32_name; - - - m_my_string_name = std::move(x.m_my_string_name); - -} - -BasicNamesStruct& BasicNamesStruct::operator =( - const BasicNamesStruct& x) -{ - m_my_bool_name = x.m_my_bool_name; - - - m_my_int32_name = x.m_my_int32_name; - - - m_my_string_name = x.m_my_string_name; - - return *this; -} - -BasicNamesStruct& BasicNamesStruct::operator =( - BasicNamesStruct&& x) noexcept -{ - m_my_bool_name = x.m_my_bool_name; - - - m_my_int32_name = x.m_my_int32_name; - - - m_my_string_name = std::move(x.m_my_string_name); - - return *this; -} - -bool BasicNamesStruct::operator ==( - const BasicNamesStruct& x) const -{ - return (m_my_bool_name == x.m_my_bool_name && - m_my_int32_name == x.m_my_int32_name && - m_my_string_name == x.m_my_string_name); -} - -bool BasicNamesStruct::operator !=( - const BasicNamesStruct& x) const -{ - return !(*this == x); -} - -size_t BasicNamesStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return BasicNamesStruct_max_cdr_typesize; -} - -size_t BasicNamesStruct::getCdrSerializedSize( - const BasicNamesStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + data.my_string_name().size() + 1; - - - return current_alignment - initial_alignment; -} - - -void BasicNamesStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_bool_name; - - scdr << m_my_int32_name; - - scdr << m_my_string_name.c_str(); - -} - -void BasicNamesStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_bool_name; - - - - dcdr >> m_my_int32_name; - - - - dcdr >> m_my_string_name; - - -} - - -bool BasicNamesStruct::isKeyDefined() -{ - return false; -} - -void BasicNamesStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member my_bool_name - * @param _my_bool_name New value for member my_bool_name - */ -void BasicNamesStruct::my_bool_name( - bool _my_bool_name) -{ - m_my_bool_name = _my_bool_name; -} - -/*! - * @brief This function returns the value of member my_bool_name - * @return Value of member my_bool_name - */ -bool BasicNamesStruct::my_bool_name() const -{ - return m_my_bool_name; -} - -/*! - * @brief This function returns a reference to member my_bool_name - * @return Reference to member my_bool_name - */ -bool& BasicNamesStruct::my_bool_name() -{ - return m_my_bool_name; -} - - -/*! - * @brief This function sets a value in member my_int32_name - * @param _my_int32_name New value for member my_int32_name - */ -void BasicNamesStruct::my_int32_name( - int32_t _my_int32_name) -{ - m_my_int32_name = _my_int32_name; -} - -/*! - * @brief This function returns the value of member my_int32_name - * @return Value of member my_int32_name - */ -int32_t BasicNamesStruct::my_int32_name() const -{ - return m_my_int32_name; -} - -/*! - * @brief This function returns a reference to member my_int32_name - * @return Reference to member my_int32_name - */ -int32_t& BasicNamesStruct::my_int32_name() -{ - return m_my_int32_name; -} - - -/*! - * @brief This function copies the value in member my_string_name - * @param _my_string_name New value to be copied in member my_string_name - */ -void BasicNamesStruct::my_string_name( - const std::string& _my_string_name) -{ - m_my_string_name = _my_string_name; -} - -/*! - * @brief This function moves the value in member my_string_name - * @param _my_string_name New value to be moved in member my_string_name - */ -void BasicNamesStruct::my_string_name( - std::string&& _my_string_name) -{ - m_my_string_name = std::move(_my_string_name); -} - -/*! - * @brief This function returns a constant reference to member my_string_name - * @return Constant reference to member my_string_name - */ -const std::string& BasicNamesStruct::my_string_name() const -{ - return m_my_string_name; -} - -/*! - * @brief This function returns a reference to member my_string_name - * @return Reference to member my_string_name - */ -std::string& BasicNamesStruct::my_string_name() -{ - return m_my_string_name; -} - - - - - -BasicBadStruct::BasicBadStruct() -{ - // octet m_my_bool - m_my_bool = 0; - // long m_my_int32 - m_my_int32 = 0; - // /type_d() m_my_string - - - // Just to register all known types - registerTypesTypes(); -} - -BasicBadStruct::~BasicBadStruct() -{ -} - -BasicBadStruct::BasicBadStruct( - const BasicBadStruct& x) -{ - m_my_bool = x.m_my_bool; - - - m_my_int32 = x.m_my_int32; - - - m_my_string = x.m_my_string; - -} - -BasicBadStruct::BasicBadStruct( - BasicBadStruct&& x) noexcept -{ - m_my_bool = x.m_my_bool; - - - m_my_int32 = x.m_my_int32; - - - m_my_string = std::move(x.m_my_string); - -} - -BasicBadStruct& BasicBadStruct::operator =( - const BasicBadStruct& x) -{ - m_my_bool = x.m_my_bool; - - - m_my_int32 = x.m_my_int32; - - - m_my_string = x.m_my_string; - - return *this; -} - -BasicBadStruct& BasicBadStruct::operator =( - BasicBadStruct&& x) noexcept -{ - m_my_bool = x.m_my_bool; - - - m_my_int32 = x.m_my_int32; - - - m_my_string = std::move(x.m_my_string); - - return *this; -} - -bool BasicBadStruct::operator ==( - const BasicBadStruct& x) const -{ - return (m_my_bool == x.m_my_bool && - m_my_int32 == x.m_my_int32 && - m_my_string == x.m_my_string); -} - -bool BasicBadStruct::operator !=( - const BasicBadStruct& x) const -{ - return !(*this == x); -} - -size_t BasicBadStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return BasicBadStruct_max_cdr_typesize; -} - -size_t BasicBadStruct::getCdrSerializedSize( - const BasicBadStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + data.my_string().size() + 1; - - - return current_alignment - initial_alignment; -} - - -void BasicBadStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_bool; - - scdr << m_my_int32; - - scdr << m_my_string.c_str(); - -} - -void BasicBadStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_bool; - - - - dcdr >> m_my_int32; - - - - dcdr >> m_my_string; - - -} - - -bool BasicBadStruct::isKeyDefined() -{ - return false; -} - -void BasicBadStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member my_bool - * @param _my_bool New value for member my_bool - */ -void BasicBadStruct::my_bool( - uint8_t _my_bool) -{ - m_my_bool = _my_bool; -} - -/*! - * @brief This function returns the value of member my_bool - * @return Value of member my_bool - */ -uint8_t BasicBadStruct::my_bool() const -{ - return m_my_bool; -} - -/*! - * @brief This function returns a reference to member my_bool - * @return Reference to member my_bool - */ -uint8_t& BasicBadStruct::my_bool() -{ - return m_my_bool; -} - - -/*! - * @brief This function sets a value in member my_int32 - * @param _my_int32 New value for member my_int32 - */ -void BasicBadStruct::my_int32( - int32_t _my_int32) -{ - m_my_int32 = _my_int32; -} - -/*! - * @brief This function returns the value of member my_int32 - * @return Value of member my_int32 - */ -int32_t BasicBadStruct::my_int32() const -{ - return m_my_int32; -} - -/*! - * @brief This function returns a reference to member my_int32 - * @return Reference to member my_int32 - */ -int32_t& BasicBadStruct::my_int32() -{ - return m_my_int32; -} - - -/*! - * @brief This function copies the value in member my_string - * @param _my_string New value to be copied in member my_string - */ -void BasicBadStruct::my_string( - const std::string& _my_string) -{ - m_my_string = _my_string; -} - -/*! - * @brief This function moves the value in member my_string - * @param _my_string New value to be moved in member my_string - */ -void BasicBadStruct::my_string( - std::string&& _my_string) -{ - m_my_string = std::move(_my_string); -} - -/*! - * @brief This function returns a constant reference to member my_string - * @return Constant reference to member my_string - */ -const std::string& BasicBadStruct::my_string() const -{ - return m_my_string; -} - -/*! - * @brief This function returns a reference to member my_string - * @return Reference to member my_string - */ -std::string& BasicBadStruct::my_string() -{ - return m_my_string; -} - - - - - -BasicWideStruct::BasicWideStruct() -{ - // boolean m_my_bool - m_my_bool = false; - // long m_my_int32 - m_my_int32 = 0; - // /type_d() m_my_string - - // long m_new_int32 - m_new_int32 = 0; - // /type_d() m_new_string - - - // Just to register all known types - registerTypesTypes(); -} - -BasicWideStruct::~BasicWideStruct() -{ -} - -BasicWideStruct::BasicWideStruct( - const BasicWideStruct& x) -{ - m_my_bool = x.m_my_bool; - - - m_my_int32 = x.m_my_int32; - - - m_my_string = x.m_my_string; - - - m_new_int32 = x.m_new_int32; - - - m_new_string = x.m_new_string; - -} - -BasicWideStruct::BasicWideStruct( - BasicWideStruct&& x) noexcept -{ - m_my_bool = x.m_my_bool; - - - m_my_int32 = x.m_my_int32; - - - m_my_string = std::move(x.m_my_string); - - - m_new_int32 = x.m_new_int32; - - - m_new_string = std::move(x.m_new_string); - -} - -BasicWideStruct& BasicWideStruct::operator =( - const BasicWideStruct& x) -{ - m_my_bool = x.m_my_bool; - - - m_my_int32 = x.m_my_int32; - - - m_my_string = x.m_my_string; - - - m_new_int32 = x.m_new_int32; - - - m_new_string = x.m_new_string; - - return *this; -} - -BasicWideStruct& BasicWideStruct::operator =( - BasicWideStruct&& x) noexcept -{ - m_my_bool = x.m_my_bool; - - - m_my_int32 = x.m_my_int32; - - - m_my_string = std::move(x.m_my_string); - - - m_new_int32 = x.m_new_int32; - - - m_new_string = std::move(x.m_new_string); - - return *this; -} - -bool BasicWideStruct::operator ==( - const BasicWideStruct& x) const -{ - return (m_my_bool == x.m_my_bool && - m_my_int32 == x.m_my_int32 && - m_my_string == x.m_my_string && - m_new_int32 == x.m_new_int32 && - m_new_string == x.m_new_string); -} - -bool BasicWideStruct::operator !=( - const BasicWideStruct& x) const -{ - return !(*this == x); -} - -size_t BasicWideStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return BasicWideStruct_max_cdr_typesize; -} - -size_t BasicWideStruct::getCdrSerializedSize( - const BasicWideStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + data.my_string().size() + 1; - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + data.new_string().size() + 1; - - - return current_alignment - initial_alignment; -} - - -void BasicWideStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_bool; - - scdr << m_my_int32; - - scdr << m_my_string.c_str(); - - scdr << m_new_int32; - - scdr << m_new_string.c_str(); - -} - -void BasicWideStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_bool; - - - - dcdr >> m_my_int32; - - - - dcdr >> m_my_string; - - - - dcdr >> m_new_int32; - - - - dcdr >> m_new_string; - - -} - - -bool BasicWideStruct::isKeyDefined() -{ - return false; -} - -void BasicWideStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member my_bool - * @param _my_bool New value for member my_bool - */ -void BasicWideStruct::my_bool( - bool _my_bool) -{ - m_my_bool = _my_bool; -} - -/*! - * @brief This function returns the value of member my_bool - * @return Value of member my_bool - */ -bool BasicWideStruct::my_bool() const -{ - return m_my_bool; -} - -/*! - * @brief This function returns a reference to member my_bool - * @return Reference to member my_bool - */ -bool& BasicWideStruct::my_bool() -{ - return m_my_bool; -} - - -/*! - * @brief This function sets a value in member my_int32 - * @param _my_int32 New value for member my_int32 - */ -void BasicWideStruct::my_int32( - int32_t _my_int32) -{ - m_my_int32 = _my_int32; -} - -/*! - * @brief This function returns the value of member my_int32 - * @return Value of member my_int32 - */ -int32_t BasicWideStruct::my_int32() const -{ - return m_my_int32; -} - -/*! - * @brief This function returns a reference to member my_int32 - * @return Reference to member my_int32 - */ -int32_t& BasicWideStruct::my_int32() -{ - return m_my_int32; -} - - -/*! - * @brief This function copies the value in member my_string - * @param _my_string New value to be copied in member my_string - */ -void BasicWideStruct::my_string( - const std::string& _my_string) -{ - m_my_string = _my_string; -} - -/*! - * @brief This function moves the value in member my_string - * @param _my_string New value to be moved in member my_string - */ -void BasicWideStruct::my_string( - std::string&& _my_string) -{ - m_my_string = std::move(_my_string); -} - -/*! - * @brief This function returns a constant reference to member my_string - * @return Constant reference to member my_string - */ -const std::string& BasicWideStruct::my_string() const -{ - return m_my_string; -} - -/*! - * @brief This function returns a reference to member my_string - * @return Reference to member my_string - */ -std::string& BasicWideStruct::my_string() -{ - return m_my_string; -} - - -/*! - * @brief This function sets a value in member new_int32 - * @param _new_int32 New value for member new_int32 - */ -void BasicWideStruct::new_int32( - int32_t _new_int32) -{ - m_new_int32 = _new_int32; -} - -/*! - * @brief This function returns the value of member new_int32 - * @return Value of member new_int32 - */ -int32_t BasicWideStruct::new_int32() const -{ - return m_new_int32; -} - -/*! - * @brief This function returns a reference to member new_int32 - * @return Reference to member new_int32 - */ -int32_t& BasicWideStruct::new_int32() -{ - return m_new_int32; -} - - -/*! - * @brief This function copies the value in member new_string - * @param _new_string New value to be copied in member new_string - */ -void BasicWideStruct::new_string( - const std::string& _new_string) -{ - m_new_string = _new_string; -} - -/*! - * @brief This function moves the value in member new_string - * @param _new_string New value to be moved in member new_string - */ -void BasicWideStruct::new_string( - std::string&& _new_string) -{ - m_new_string = std::move(_new_string); -} - -/*! - * @brief This function returns a constant reference to member new_string - * @return Constant reference to member new_string - */ -const std::string& BasicWideStruct::new_string() const -{ - return m_new_string; -} - -/*! - * @brief This function returns a reference to member new_string - * @return Reference to member new_string - */ -std::string& BasicWideStruct::new_string() -{ - return m_new_string; -} - - - - - -BadBasicWideStruct::BadBasicWideStruct() -{ - // long m_new_int32 - m_new_int32 = 0; - // /type_d() m_new_string - - // boolean m_my_bool - m_my_bool = false; - // long m_my_int32 - m_my_int32 = 0; - // /type_d() m_my_string - - - // Just to register all known types - registerTypesTypes(); -} - -BadBasicWideStruct::~BadBasicWideStruct() -{ -} - -BadBasicWideStruct::BadBasicWideStruct( - const BadBasicWideStruct& x) -{ - m_new_int32 = x.m_new_int32; - - - m_new_string = x.m_new_string; - - - m_my_bool = x.m_my_bool; - - - m_my_int32 = x.m_my_int32; - - - m_my_string = x.m_my_string; - -} - -BadBasicWideStruct::BadBasicWideStruct( - BadBasicWideStruct&& x) noexcept -{ - m_new_int32 = x.m_new_int32; - - - m_new_string = std::move(x.m_new_string); - - - m_my_bool = x.m_my_bool; - - - m_my_int32 = x.m_my_int32; - - - m_my_string = std::move(x.m_my_string); - -} - -BadBasicWideStruct& BadBasicWideStruct::operator =( - const BadBasicWideStruct& x) -{ - m_new_int32 = x.m_new_int32; - - - m_new_string = x.m_new_string; - - - m_my_bool = x.m_my_bool; - - - m_my_int32 = x.m_my_int32; - - - m_my_string = x.m_my_string; - - return *this; -} - -BadBasicWideStruct& BadBasicWideStruct::operator =( - BadBasicWideStruct&& x) noexcept -{ - m_new_int32 = x.m_new_int32; - - - m_new_string = std::move(x.m_new_string); - - - m_my_bool = x.m_my_bool; - - - m_my_int32 = x.m_my_int32; - - - m_my_string = std::move(x.m_my_string); - - return *this; -} - -bool BadBasicWideStruct::operator ==( - const BadBasicWideStruct& x) const -{ - return (m_new_int32 == x.m_new_int32 && - m_new_string == x.m_new_string && - m_my_bool == x.m_my_bool && - m_my_int32 == x.m_my_int32 && - m_my_string == x.m_my_string); -} - -bool BadBasicWideStruct::operator !=( - const BadBasicWideStruct& x) const -{ - return !(*this == x); -} - -size_t BadBasicWideStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return BadBasicWideStruct_max_cdr_typesize; -} - -size_t BadBasicWideStruct::getCdrSerializedSize( - const BadBasicWideStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + data.new_string().size() + 1; - - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + data.my_string().size() + 1; - - - return current_alignment - initial_alignment; -} - - -void BadBasicWideStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_new_int32; - - scdr << m_new_string.c_str(); - - scdr << m_my_bool; - - scdr << m_my_int32; - - scdr << m_my_string.c_str(); - -} - -void BadBasicWideStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_new_int32; - - - - dcdr >> m_new_string; - - - - dcdr >> m_my_bool; - - - - dcdr >> m_my_int32; - - - - dcdr >> m_my_string; - - -} - - -bool BadBasicWideStruct::isKeyDefined() -{ - return false; -} - -void BadBasicWideStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function sets a value in member new_int32 - * @param _new_int32 New value for member new_int32 - */ -void BadBasicWideStruct::new_int32( - int32_t _new_int32) -{ - m_new_int32 = _new_int32; -} - -/*! - * @brief This function returns the value of member new_int32 - * @return Value of member new_int32 - */ -int32_t BadBasicWideStruct::new_int32() const -{ - return m_new_int32; -} - -/*! - * @brief This function returns a reference to member new_int32 - * @return Reference to member new_int32 - */ -int32_t& BadBasicWideStruct::new_int32() -{ - return m_new_int32; -} - - -/*! - * @brief This function copies the value in member new_string - * @param _new_string New value to be copied in member new_string - */ -void BadBasicWideStruct::new_string( - const std::string& _new_string) -{ - m_new_string = _new_string; -} - -/*! - * @brief This function moves the value in member new_string - * @param _new_string New value to be moved in member new_string - */ -void BadBasicWideStruct::new_string( - std::string&& _new_string) -{ - m_new_string = std::move(_new_string); -} - -/*! - * @brief This function returns a constant reference to member new_string - * @return Constant reference to member new_string - */ -const std::string& BadBasicWideStruct::new_string() const -{ - return m_new_string; -} - -/*! - * @brief This function returns a reference to member new_string - * @return Reference to member new_string - */ -std::string& BadBasicWideStruct::new_string() -{ - return m_new_string; -} - - -/*! - * @brief This function sets a value in member my_bool - * @param _my_bool New value for member my_bool - */ -void BadBasicWideStruct::my_bool( - bool _my_bool) -{ - m_my_bool = _my_bool; -} - -/*! - * @brief This function returns the value of member my_bool - * @return Value of member my_bool - */ -bool BadBasicWideStruct::my_bool() const -{ - return m_my_bool; -} - -/*! - * @brief This function returns a reference to member my_bool - * @return Reference to member my_bool - */ -bool& BadBasicWideStruct::my_bool() -{ - return m_my_bool; -} - - -/*! - * @brief This function sets a value in member my_int32 - * @param _my_int32 New value for member my_int32 - */ -void BadBasicWideStruct::my_int32( - int32_t _my_int32) -{ - m_my_int32 = _my_int32; -} - -/*! - * @brief This function returns the value of member my_int32 - * @return Value of member my_int32 - */ -int32_t BadBasicWideStruct::my_int32() const -{ - return m_my_int32; -} - -/*! - * @brief This function returns a reference to member my_int32 - * @return Reference to member my_int32 - */ -int32_t& BadBasicWideStruct::my_int32() -{ - return m_my_int32; -} - - -/*! - * @brief This function copies the value in member my_string - * @param _my_string New value to be copied in member my_string - */ -void BadBasicWideStruct::my_string( - const std::string& _my_string) -{ - m_my_string = _my_string; -} - -/*! - * @brief This function moves the value in member my_string - * @param _my_string New value to be moved in member my_string - */ -void BadBasicWideStruct::my_string( - std::string&& _my_string) -{ - m_my_string = std::move(_my_string); -} - -/*! - * @brief This function returns a constant reference to member my_string - * @return Constant reference to member my_string - */ -const std::string& BadBasicWideStruct::my_string() const -{ - return m_my_string; -} - -/*! - * @brief This function returns a reference to member my_string - * @return Reference to member my_string - */ -std::string& BadBasicWideStruct::my_string() -{ - return m_my_string; -} - - - - - -StringStruct::StringStruct() -{ - // /type_d() m_my_string - - - // Just to register all known types - registerTypesTypes(); -} - -StringStruct::~StringStruct() -{ -} - -StringStruct::StringStruct( - const StringStruct& x) -{ - m_my_string = x.m_my_string; - -} - -StringStruct::StringStruct( - StringStruct&& x) noexcept -{ - m_my_string = std::move(x.m_my_string); - -} - -StringStruct& StringStruct::operator =( - const StringStruct& x) -{ - m_my_string = x.m_my_string; - - return *this; -} - -StringStruct& StringStruct::operator =( - StringStruct&& x) noexcept -{ - m_my_string = std::move(x.m_my_string); - - return *this; -} - -bool StringStruct::operator ==( - const StringStruct& x) const -{ - return (m_my_string == x.m_my_string); -} - -bool StringStruct::operator !=( - const StringStruct& x) const -{ - return !(*this == x); -} - -size_t StringStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return StringStruct_max_cdr_typesize; -} - -size_t StringStruct::getCdrSerializedSize( - const StringStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + data.my_string().size() + 1; - - - return current_alignment - initial_alignment; -} - - -void StringStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_string.c_str(); - -} - -void StringStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_string; - - -} - - -bool StringStruct::isKeyDefined() -{ - return false; -} - -void StringStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_string - * @param _my_string New value to be copied in member my_string - */ -void StringStruct::my_string( - const std::string& _my_string) -{ - m_my_string = _my_string; -} - -/*! - * @brief This function moves the value in member my_string - * @param _my_string New value to be moved in member my_string - */ -void StringStruct::my_string( - std::string&& _my_string) -{ - m_my_string = std::move(_my_string); -} - -/*! - * @brief This function returns a constant reference to member my_string - * @return Constant reference to member my_string - */ -const std::string& StringStruct::my_string() const -{ - return m_my_string; -} - -/*! - * @brief This function returns a reference to member my_string - * @return Reference to member my_string - */ -std::string& StringStruct::my_string() -{ - return m_my_string; -} - - - - - -LargeStringStruct::LargeStringStruct() -{ - // /type_d() m_my_large_string - - - // Just to register all known types - registerTypesTypes(); -} - -LargeStringStruct::~LargeStringStruct() -{ -} - -LargeStringStruct::LargeStringStruct( - const LargeStringStruct& x) -{ - m_my_large_string = x.m_my_large_string; - -} - -LargeStringStruct::LargeStringStruct( - LargeStringStruct&& x) noexcept -{ - m_my_large_string = std::move(x.m_my_large_string); - -} - -LargeStringStruct& LargeStringStruct::operator =( - const LargeStringStruct& x) -{ - m_my_large_string = x.m_my_large_string; - - return *this; -} - -LargeStringStruct& LargeStringStruct::operator =( - LargeStringStruct&& x) noexcept -{ - m_my_large_string = std::move(x.m_my_large_string); - - return *this; -} - -bool LargeStringStruct::operator ==( - const LargeStringStruct& x) const -{ - return (m_my_large_string == x.m_my_large_string); -} - -bool LargeStringStruct::operator !=( - const LargeStringStruct& x) const -{ - return !(*this == x); -} - -size_t LargeStringStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return LargeStringStruct_max_cdr_typesize; -} - -size_t LargeStringStruct::getCdrSerializedSize( - const LargeStringStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + data.my_large_string().size() + 1; - - - return current_alignment - initial_alignment; -} - - -void LargeStringStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_large_string.c_str(); - -} - -void LargeStringStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - { - std::string aux; - dcdr >> aux; - m_my_large_string = aux.c_str(); - } - - -} - - -bool LargeStringStruct::isKeyDefined() -{ - return false; -} - -void LargeStringStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_large_string - * @param _my_large_string New value to be copied in member my_large_string - */ -void LargeStringStruct::my_large_string( - const eprosima::fastrtps::fixed_string<41925>& _my_large_string) -{ - m_my_large_string = _my_large_string; -} - -/*! - * @brief This function moves the value in member my_large_string - * @param _my_large_string New value to be moved in member my_large_string - */ -void LargeStringStruct::my_large_string( - eprosima::fastrtps::fixed_string<41925>&& _my_large_string) -{ - m_my_large_string = std::move(_my_large_string); -} - -/*! - * @brief This function returns a constant reference to member my_large_string - * @return Constant reference to member my_large_string - */ -const eprosima::fastrtps::fixed_string<41925>& LargeStringStruct::my_large_string() const -{ - return m_my_large_string; -} - -/*! - * @brief This function returns a reference to member my_large_string - * @return Reference to member my_large_string - */ -eprosima::fastrtps::fixed_string<41925>& LargeStringStruct::my_large_string() -{ - return m_my_large_string; -} - - - - - -WStringStruct::WStringStruct() -{ - // /type_15() m_my_wstring - - - // Just to register all known types - registerTypesTypes(); -} - -WStringStruct::~WStringStruct() -{ -} - -WStringStruct::WStringStruct( - const WStringStruct& x) -{ - m_my_wstring = x.m_my_wstring; - -} - -WStringStruct::WStringStruct( - WStringStruct&& x) noexcept -{ - m_my_wstring = std::move(x.m_my_wstring); - -} - -WStringStruct& WStringStruct::operator =( - const WStringStruct& x) -{ - m_my_wstring = x.m_my_wstring; - - return *this; -} - -WStringStruct& WStringStruct::operator =( - WStringStruct&& x) noexcept -{ - m_my_wstring = std::move(x.m_my_wstring); - - return *this; -} - -bool WStringStruct::operator ==( - const WStringStruct& x) const -{ - return (m_my_wstring == x.m_my_wstring); -} - -bool WStringStruct::operator !=( - const WStringStruct& x) const -{ - return !(*this == x); -} - -size_t WStringStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return WStringStruct_max_cdr_typesize; -} - -size_t WStringStruct::getCdrSerializedSize( - const WStringStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + (data.my_wstring().size()) * 4; // 32 bits - - - return current_alignment - initial_alignment; -} - - -void WStringStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_wstring; - -} - -void WStringStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_wstring; - - -} - - -bool WStringStruct::isKeyDefined() -{ - return false; -} - -void WStringStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_wstring - * @param _my_wstring New value to be copied in member my_wstring - */ -void WStringStruct::my_wstring( - const std::wstring& _my_wstring) -{ - m_my_wstring = _my_wstring; -} - -/*! - * @brief This function moves the value in member my_wstring - * @param _my_wstring New value to be moved in member my_wstring - */ -void WStringStruct::my_wstring( - std::wstring&& _my_wstring) -{ - m_my_wstring = std::move(_my_wstring); -} - -/*! - * @brief This function returns a constant reference to member my_wstring - * @return Constant reference to member my_wstring - */ -const std::wstring& WStringStruct::my_wstring() const -{ - return m_my_wstring; -} - -/*! - * @brief This function returns a reference to member my_wstring - * @return Reference to member my_wstring - */ -std::wstring& WStringStruct::my_wstring() -{ - return m_my_wstring; -} - - - - - -LargeWStringStruct::LargeWStringStruct() -{ - // /type_15() m_my_large_wstring - - - // Just to register all known types - registerTypesTypes(); -} - -LargeWStringStruct::~LargeWStringStruct() -{ -} - -LargeWStringStruct::LargeWStringStruct( - const LargeWStringStruct& x) -{ - m_my_large_wstring = x.m_my_large_wstring; - -} - -LargeWStringStruct::LargeWStringStruct( - LargeWStringStruct&& x) noexcept -{ - m_my_large_wstring = std::move(x.m_my_large_wstring); - -} - -LargeWStringStruct& LargeWStringStruct::operator =( - const LargeWStringStruct& x) -{ - m_my_large_wstring = x.m_my_large_wstring; - - return *this; -} - -LargeWStringStruct& LargeWStringStruct::operator =( - LargeWStringStruct&& x) noexcept -{ - m_my_large_wstring = std::move(x.m_my_large_wstring); - - return *this; -} - -bool LargeWStringStruct::operator ==( - const LargeWStringStruct& x) const -{ - return (m_my_large_wstring == x.m_my_large_wstring); -} - -bool LargeWStringStruct::operator !=( - const LargeWStringStruct& x) const -{ - return !(*this == x); -} - -size_t LargeWStringStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return LargeWStringStruct_max_cdr_typesize; -} - -size_t LargeWStringStruct::getCdrSerializedSize( - const LargeWStringStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4) + (data.my_large_wstring().size()) * 4; // 32 bits - - - return current_alignment - initial_alignment; -} - - -void LargeWStringStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_large_wstring; - -} - -void LargeWStringStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_large_wstring; - - -} - - -bool LargeWStringStruct::isKeyDefined() -{ - return false; -} - -void LargeWStringStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_large_wstring - * @param _my_large_wstring New value to be copied in member my_large_wstring - */ -void LargeWStringStruct::my_large_wstring( - const std::wstring& _my_large_wstring) -{ - m_my_large_wstring = _my_large_wstring; -} - -/*! - * @brief This function moves the value in member my_large_wstring - * @param _my_large_wstring New value to be moved in member my_large_wstring - */ -void LargeWStringStruct::my_large_wstring( - std::wstring&& _my_large_wstring) -{ - m_my_large_wstring = std::move(_my_large_wstring); -} - -/*! - * @brief This function returns a constant reference to member my_large_wstring - * @return Constant reference to member my_large_wstring - */ -const std::wstring& LargeWStringStruct::my_large_wstring() const -{ - return m_my_large_wstring; -} - -/*! - * @brief This function returns a reference to member my_large_wstring - * @return Reference to member my_large_wstring - */ -std::wstring& LargeWStringStruct::my_large_wstring() -{ - return m_my_large_wstring; -} - - - - - -ArrayStruct::ArrayStruct() -{ - // long m_my_array - memset(&m_my_array, 0, ((2)) * 4); - - // Just to register all known types - registerTypesTypes(); -} - -ArrayStruct::~ArrayStruct() -{ -} - -ArrayStruct::ArrayStruct( - const ArrayStruct& x) -{ - m_my_array = x.m_my_array; - -} - -ArrayStruct::ArrayStruct( - ArrayStruct&& x) noexcept -{ - m_my_array = std::move(x.m_my_array); - -} - -ArrayStruct& ArrayStruct::operator =( - const ArrayStruct& x) -{ - m_my_array = x.m_my_array; - - return *this; -} - -ArrayStruct& ArrayStruct::operator =( - ArrayStruct&& x) noexcept -{ - m_my_array = std::move(x.m_my_array); - - return *this; -} - -bool ArrayStruct::operator ==( - const ArrayStruct& x) const -{ - return (m_my_array == x.m_my_array); -} - -bool ArrayStruct::operator !=( - const ArrayStruct& x) const -{ - return !(*this == x); -} - -size_t ArrayStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return ArrayStruct_max_cdr_typesize; -} - -size_t ArrayStruct::getCdrSerializedSize( - const ArrayStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += (((2)) * 4) + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - - return current_alignment - initial_alignment; -} - - -void ArrayStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_array; - - -} - -void ArrayStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_array; - - -} - - -bool ArrayStruct::isKeyDefined() -{ - return false; -} - -void ArrayStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_array - * @param _my_array New value to be copied in member my_array - */ -void ArrayStruct::my_array( - const std::array& _my_array) -{ - m_my_array = _my_array; -} - -/*! - * @brief This function moves the value in member my_array - * @param _my_array New value to be moved in member my_array - */ -void ArrayStruct::my_array( - std::array&& _my_array) -{ - m_my_array = std::move(_my_array); -} - -/*! - * @brief This function returns a constant reference to member my_array - * @return Constant reference to member my_array - */ -const std::array& ArrayStruct::my_array() const -{ - return m_my_array; -} - -/*! - * @brief This function returns a reference to member my_array - * @return Reference to member my_array - */ -std::array& ArrayStruct::my_array() -{ - return m_my_array; -} - - - - - -ArrayStructEqual::ArrayStructEqual() -{ - // long m_my_array_equal - memset(&m_my_array_equal, 0, ((2)) * 4); - - // Just to register all known types - registerTypesTypes(); -} - -ArrayStructEqual::~ArrayStructEqual() -{ -} - -ArrayStructEqual::ArrayStructEqual( - const ArrayStructEqual& x) -{ - m_my_array_equal = x.m_my_array_equal; - -} - -ArrayStructEqual::ArrayStructEqual( - ArrayStructEqual&& x) noexcept -{ - m_my_array_equal = std::move(x.m_my_array_equal); - -} - -ArrayStructEqual& ArrayStructEqual::operator =( - const ArrayStructEqual& x) -{ - m_my_array_equal = x.m_my_array_equal; - - return *this; -} - -ArrayStructEqual& ArrayStructEqual::operator =( - ArrayStructEqual&& x) noexcept -{ - m_my_array_equal = std::move(x.m_my_array_equal); - - return *this; -} - -bool ArrayStructEqual::operator ==( - const ArrayStructEqual& x) const -{ - return (m_my_array_equal == x.m_my_array_equal); -} - -bool ArrayStructEqual::operator !=( - const ArrayStructEqual& x) const -{ - return !(*this == x); -} - -size_t ArrayStructEqual::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return ArrayStructEqual_max_cdr_typesize; -} - -size_t ArrayStructEqual::getCdrSerializedSize( - const ArrayStructEqual& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += (((2)) * 4) + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - - return current_alignment - initial_alignment; -} - - -void ArrayStructEqual::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_array_equal; - - -} - -void ArrayStructEqual::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_array_equal; - - -} - - -bool ArrayStructEqual::isKeyDefined() -{ - return false; -} - -void ArrayStructEqual::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_array_equal - * @param _my_array_equal New value to be copied in member my_array_equal - */ -void ArrayStructEqual::my_array_equal( - const std::array& _my_array_equal) -{ - m_my_array_equal = _my_array_equal; -} - -/*! - * @brief This function moves the value in member my_array_equal - * @param _my_array_equal New value to be moved in member my_array_equal - */ -void ArrayStructEqual::my_array_equal( - std::array&& _my_array_equal) -{ - m_my_array_equal = std::move(_my_array_equal); -} - -/*! - * @brief This function returns a constant reference to member my_array_equal - * @return Constant reference to member my_array_equal - */ -const std::array& ArrayStructEqual::my_array_equal() const -{ - return m_my_array_equal; -} - -/*! - * @brief This function returns a reference to member my_array_equal - * @return Reference to member my_array_equal - */ -std::array& ArrayStructEqual::my_array_equal() -{ - return m_my_array_equal; -} - - - - - -ArrayBadStruct::ArrayBadStruct() -{ - // octet m_my_array - memset(&m_my_array, 0, ((2)) * 1); - - // Just to register all known types - registerTypesTypes(); -} - -ArrayBadStruct::~ArrayBadStruct() -{ -} - -ArrayBadStruct::ArrayBadStruct( - const ArrayBadStruct& x) -{ - m_my_array = x.m_my_array; - -} - -ArrayBadStruct::ArrayBadStruct( - ArrayBadStruct&& x) noexcept -{ - m_my_array = std::move(x.m_my_array); - -} - -ArrayBadStruct& ArrayBadStruct::operator =( - const ArrayBadStruct& x) -{ - m_my_array = x.m_my_array; - - return *this; -} - -ArrayBadStruct& ArrayBadStruct::operator =( - ArrayBadStruct&& x) noexcept -{ - m_my_array = std::move(x.m_my_array); - - return *this; -} - -bool ArrayBadStruct::operator ==( - const ArrayBadStruct& x) const -{ - return (m_my_array == x.m_my_array); -} - -bool ArrayBadStruct::operator !=( - const ArrayBadStruct& x) const -{ - return !(*this == x); -} - -size_t ArrayBadStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return ArrayBadStruct_max_cdr_typesize; -} - -size_t ArrayBadStruct::getCdrSerializedSize( - const ArrayBadStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += (((2)) * 1) + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - - return current_alignment - initial_alignment; -} - - -void ArrayBadStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_array; - - -} - -void ArrayBadStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_array; - - -} - - -bool ArrayBadStruct::isKeyDefined() -{ - return false; -} - -void ArrayBadStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_array - * @param _my_array New value to be copied in member my_array - */ -void ArrayBadStruct::my_array( - const std::array& _my_array) -{ - m_my_array = _my_array; -} - -/*! - * @brief This function moves the value in member my_array - * @param _my_array New value to be moved in member my_array - */ -void ArrayBadStruct::my_array( - std::array&& _my_array) -{ - m_my_array = std::move(_my_array); -} - -/*! - * @brief This function returns a constant reference to member my_array - * @return Constant reference to member my_array - */ -const std::array& ArrayBadStruct::my_array() const -{ - return m_my_array; -} - -/*! - * @brief This function returns a reference to member my_array - * @return Reference to member my_array - */ -std::array& ArrayBadStruct::my_array() -{ - return m_my_array; -} - - - - - -ArrayDimensionsStruct::ArrayDimensionsStruct() -{ - // long m_my_array - memset(&m_my_array, 0, ((2) * (2)) * 4); - - // Just to register all known types - registerTypesTypes(); -} - -ArrayDimensionsStruct::~ArrayDimensionsStruct() -{ -} - -ArrayDimensionsStruct::ArrayDimensionsStruct( - const ArrayDimensionsStruct& x) -{ - m_my_array = x.m_my_array; - -} - -ArrayDimensionsStruct::ArrayDimensionsStruct( - ArrayDimensionsStruct&& x) noexcept -{ - m_my_array = std::move(x.m_my_array); - -} - -ArrayDimensionsStruct& ArrayDimensionsStruct::operator =( - const ArrayDimensionsStruct& x) -{ - m_my_array = x.m_my_array; - - return *this; -} - -ArrayDimensionsStruct& ArrayDimensionsStruct::operator =( - ArrayDimensionsStruct&& x) noexcept -{ - m_my_array = std::move(x.m_my_array); - - return *this; -} - -bool ArrayDimensionsStruct::operator ==( - const ArrayDimensionsStruct& x) const -{ - return (m_my_array == x.m_my_array); -} - -bool ArrayDimensionsStruct::operator !=( - const ArrayDimensionsStruct& x) const -{ - return !(*this == x); -} - -size_t ArrayDimensionsStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return ArrayDimensionsStruct_max_cdr_typesize; -} - -size_t ArrayDimensionsStruct::getCdrSerializedSize( - const ArrayDimensionsStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += (((2) * (2)) * 4) + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - - return current_alignment - initial_alignment; -} - - -void ArrayDimensionsStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - for (uint32_t b = 0; b < m_my_array.size(); ++b) - { - scdr << m_my_array[b]; - - } - - - -} - -void ArrayDimensionsStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - for (uint32_t d = 0; d < m_my_array.size(); ++d) - { - dcdr >> m_my_array[d]; - - } - - - -} - - -bool ArrayDimensionsStruct::isKeyDefined() -{ - return false; -} - -void ArrayDimensionsStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_array - * @param _my_array New value to be copied in member my_array - */ -void ArrayDimensionsStruct::my_array( - const std::array, 2>& _my_array) -{ - m_my_array = _my_array; -} - -/*! - * @brief This function moves the value in member my_array - * @param _my_array New value to be moved in member my_array - */ -void ArrayDimensionsStruct::my_array( - std::array, 2>&& _my_array) -{ - m_my_array = std::move(_my_array); -} - -/*! - * @brief This function returns a constant reference to member my_array - * @return Constant reference to member my_array - */ -const std::array, 2>& ArrayDimensionsStruct::my_array() const -{ - return m_my_array; -} - -/*! - * @brief This function returns a reference to member my_array - * @return Reference to member my_array - */ -std::array, 2>& ArrayDimensionsStruct::my_array() -{ - return m_my_array; -} - - - - - -ArraySizeStruct::ArraySizeStruct() -{ - // long m_my_array - memset(&m_my_array, 0, ((5)) * 4); - - // Just to register all known types - registerTypesTypes(); -} - -ArraySizeStruct::~ArraySizeStruct() -{ -} - -ArraySizeStruct::ArraySizeStruct( - const ArraySizeStruct& x) -{ - m_my_array = x.m_my_array; - -} - -ArraySizeStruct::ArraySizeStruct( - ArraySizeStruct&& x) noexcept -{ - m_my_array = std::move(x.m_my_array); - -} - -ArraySizeStruct& ArraySizeStruct::operator =( - const ArraySizeStruct& x) -{ - m_my_array = x.m_my_array; - - return *this; -} - -ArraySizeStruct& ArraySizeStruct::operator =( - ArraySizeStruct&& x) noexcept -{ - m_my_array = std::move(x.m_my_array); - - return *this; -} - -bool ArraySizeStruct::operator ==( - const ArraySizeStruct& x) const -{ - return (m_my_array == x.m_my_array); -} - -bool ArraySizeStruct::operator !=( - const ArraySizeStruct& x) const -{ - return !(*this == x); -} - -size_t ArraySizeStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return ArraySizeStruct_max_cdr_typesize; -} - -size_t ArraySizeStruct::getCdrSerializedSize( - const ArraySizeStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += (((5)) * 4) + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - - return current_alignment - initial_alignment; -} - - -void ArraySizeStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_array; - - -} - -void ArraySizeStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_array; - - -} - - -bool ArraySizeStruct::isKeyDefined() -{ - return false; -} - -void ArraySizeStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_array - * @param _my_array New value to be copied in member my_array - */ -void ArraySizeStruct::my_array( - const std::array& _my_array) -{ - m_my_array = _my_array; -} - -/*! - * @brief This function moves the value in member my_array - * @param _my_array New value to be moved in member my_array - */ -void ArraySizeStruct::my_array( - std::array&& _my_array) -{ - m_my_array = std::move(_my_array); -} - -/*! - * @brief This function returns a constant reference to member my_array - * @return Constant reference to member my_array - */ -const std::array& ArraySizeStruct::my_array() const -{ - return m_my_array; -} - -/*! - * @brief This function returns a reference to member my_array - * @return Reference to member my_array - */ -std::array& ArraySizeStruct::my_array() -{ - return m_my_array; -} - - - - - - - -SequenceStruct::SequenceStruct() -{ - // sequence m_my_sequence - - - // Just to register all known types - registerTypesTypes(); -} - -SequenceStruct::~SequenceStruct() -{ -} - -SequenceStruct::SequenceStruct( - const SequenceStruct& x) -{ - m_my_sequence = x.m_my_sequence; - -} - -SequenceStruct::SequenceStruct( - SequenceStruct&& x) noexcept -{ - m_my_sequence = std::move(x.m_my_sequence); - -} - -SequenceStruct& SequenceStruct::operator =( - const SequenceStruct& x) -{ - m_my_sequence = x.m_my_sequence; - - return *this; -} - -SequenceStruct& SequenceStruct::operator =( - SequenceStruct&& x) noexcept -{ - m_my_sequence = std::move(x.m_my_sequence); - - return *this; -} - -bool SequenceStruct::operator ==( - const SequenceStruct& x) const -{ - return (m_my_sequence == x.m_my_sequence); -} - -bool SequenceStruct::operator !=( - const SequenceStruct& x) const -{ - return !(*this == x); -} - -size_t SequenceStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return SequenceStruct_max_cdr_typesize; -} - -size_t SequenceStruct::getCdrSerializedSize( - const SequenceStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - if (data.my_sequence().size() > 0) - { - current_alignment += (data.my_sequence().size() * 4) + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - } - - - - - return current_alignment - initial_alignment; -} - - -void SequenceStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_sequence; - - -} - -void SequenceStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_sequence; - - -} - - -bool SequenceStruct::isKeyDefined() -{ - return false; -} - -void SequenceStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_sequence - * @param _my_sequence New value to be copied in member my_sequence - */ -void SequenceStruct::my_sequence( - const std::vector& _my_sequence) -{ - m_my_sequence = _my_sequence; -} - -/*! - * @brief This function moves the value in member my_sequence - * @param _my_sequence New value to be moved in member my_sequence - */ -void SequenceStruct::my_sequence( - std::vector&& _my_sequence) -{ - m_my_sequence = std::move(_my_sequence); -} - -/*! - * @brief This function returns a constant reference to member my_sequence - * @return Constant reference to member my_sequence - */ -const std::vector& SequenceStruct::my_sequence() const -{ - return m_my_sequence; -} - -/*! - * @brief This function returns a reference to member my_sequence - * @return Reference to member my_sequence - */ -std::vector& SequenceStruct::my_sequence() -{ - return m_my_sequence; -} - - - - - - - -SequenceStructEqual::SequenceStructEqual() -{ - // sequence m_my_sequence_equal - - - // Just to register all known types - registerTypesTypes(); -} - -SequenceStructEqual::~SequenceStructEqual() -{ -} - -SequenceStructEqual::SequenceStructEqual( - const SequenceStructEqual& x) -{ - m_my_sequence_equal = x.m_my_sequence_equal; - -} - -SequenceStructEqual::SequenceStructEqual( - SequenceStructEqual&& x) noexcept -{ - m_my_sequence_equal = std::move(x.m_my_sequence_equal); - -} - -SequenceStructEqual& SequenceStructEqual::operator =( - const SequenceStructEqual& x) -{ - m_my_sequence_equal = x.m_my_sequence_equal; - - return *this; -} - -SequenceStructEqual& SequenceStructEqual::operator =( - SequenceStructEqual&& x) noexcept -{ - m_my_sequence_equal = std::move(x.m_my_sequence_equal); - - return *this; -} - -bool SequenceStructEqual::operator ==( - const SequenceStructEqual& x) const -{ - return (m_my_sequence_equal == x.m_my_sequence_equal); -} - -bool SequenceStructEqual::operator !=( - const SequenceStructEqual& x) const -{ - return !(*this == x); -} - -size_t SequenceStructEqual::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return SequenceStructEqual_max_cdr_typesize; -} - -size_t SequenceStructEqual::getCdrSerializedSize( - const SequenceStructEqual& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - if (data.my_sequence_equal().size() > 0) - { - current_alignment += (data.my_sequence_equal().size() * 4) + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - } - - - - - return current_alignment - initial_alignment; -} - - -void SequenceStructEqual::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_sequence_equal; - - -} - -void SequenceStructEqual::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_sequence_equal; - - -} - - -bool SequenceStructEqual::isKeyDefined() -{ - return false; -} - -void SequenceStructEqual::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_sequence_equal - * @param _my_sequence_equal New value to be copied in member my_sequence_equal - */ -void SequenceStructEqual::my_sequence_equal( - const std::vector& _my_sequence_equal) -{ - m_my_sequence_equal = _my_sequence_equal; -} - -/*! - * @brief This function moves the value in member my_sequence_equal - * @param _my_sequence_equal New value to be moved in member my_sequence_equal - */ -void SequenceStructEqual::my_sequence_equal( - std::vector&& _my_sequence_equal) -{ - m_my_sequence_equal = std::move(_my_sequence_equal); -} - -/*! - * @brief This function returns a constant reference to member my_sequence_equal - * @return Constant reference to member my_sequence_equal - */ -const std::vector& SequenceStructEqual::my_sequence_equal() const -{ - return m_my_sequence_equal; -} - -/*! - * @brief This function returns a reference to member my_sequence_equal - * @return Reference to member my_sequence_equal - */ -std::vector& SequenceStructEqual::my_sequence_equal() -{ - return m_my_sequence_equal; -} - - - - - - - -SequenceBadStruct::SequenceBadStruct() -{ - // sequence m_my_sequence - - - // Just to register all known types - registerTypesTypes(); -} - -SequenceBadStruct::~SequenceBadStruct() -{ -} - -SequenceBadStruct::SequenceBadStruct( - const SequenceBadStruct& x) -{ - m_my_sequence = x.m_my_sequence; - -} - -SequenceBadStruct::SequenceBadStruct( - SequenceBadStruct&& x) noexcept -{ - m_my_sequence = std::move(x.m_my_sequence); - -} - -SequenceBadStruct& SequenceBadStruct::operator =( - const SequenceBadStruct& x) -{ - m_my_sequence = x.m_my_sequence; - - return *this; -} - -SequenceBadStruct& SequenceBadStruct::operator =( - SequenceBadStruct&& x) noexcept -{ - m_my_sequence = std::move(x.m_my_sequence); - - return *this; -} - -bool SequenceBadStruct::operator ==( - const SequenceBadStruct& x) const -{ - return (m_my_sequence == x.m_my_sequence); -} - -bool SequenceBadStruct::operator !=( - const SequenceBadStruct& x) const -{ - return !(*this == x); -} - -size_t SequenceBadStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return SequenceBadStruct_max_cdr_typesize; -} - -size_t SequenceBadStruct::getCdrSerializedSize( - const SequenceBadStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - if (data.my_sequence().size() > 0) - { - current_alignment += (data.my_sequence().size() * 1) + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - } - - - - - return current_alignment - initial_alignment; -} - - -void SequenceBadStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_sequence; - - -} - -void SequenceBadStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_sequence; - - -} - - -bool SequenceBadStruct::isKeyDefined() -{ - return false; -} - -void SequenceBadStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_sequence - * @param _my_sequence New value to be copied in member my_sequence - */ -void SequenceBadStruct::my_sequence( - const std::vector& _my_sequence) -{ - m_my_sequence = _my_sequence; -} - -/*! - * @brief This function moves the value in member my_sequence - * @param _my_sequence New value to be moved in member my_sequence - */ -void SequenceBadStruct::my_sequence( - std::vector&& _my_sequence) -{ - m_my_sequence = std::move(_my_sequence); -} - -/*! - * @brief This function returns a constant reference to member my_sequence - * @return Constant reference to member my_sequence - */ -const std::vector& SequenceBadStruct::my_sequence() const -{ - return m_my_sequence; -} - -/*! - * @brief This function returns a reference to member my_sequence - * @return Reference to member my_sequence - */ -std::vector& SequenceBadStruct::my_sequence() -{ - return m_my_sequence; -} - - - - - - - -SequenceBoundsStruct::SequenceBoundsStruct() -{ - // sequence m_my_sequence - - - // Just to register all known types - registerTypesTypes(); -} - -SequenceBoundsStruct::~SequenceBoundsStruct() -{ -} - -SequenceBoundsStruct::SequenceBoundsStruct( - const SequenceBoundsStruct& x) -{ - m_my_sequence = x.m_my_sequence; - -} - -SequenceBoundsStruct::SequenceBoundsStruct( - SequenceBoundsStruct&& x) noexcept -{ - m_my_sequence = std::move(x.m_my_sequence); - -} - -SequenceBoundsStruct& SequenceBoundsStruct::operator =( - const SequenceBoundsStruct& x) -{ - m_my_sequence = x.m_my_sequence; - - return *this; -} - -SequenceBoundsStruct& SequenceBoundsStruct::operator =( - SequenceBoundsStruct&& x) noexcept -{ - m_my_sequence = std::move(x.m_my_sequence); - - return *this; -} - -bool SequenceBoundsStruct::operator ==( - const SequenceBoundsStruct& x) const -{ - return (m_my_sequence == x.m_my_sequence); -} - -bool SequenceBoundsStruct::operator !=( - const SequenceBoundsStruct& x) const -{ - return !(*this == x); -} - -size_t SequenceBoundsStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return SequenceBoundsStruct_max_cdr_typesize; -} - -size_t SequenceBoundsStruct::getCdrSerializedSize( - const SequenceBoundsStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - if (data.my_sequence().size() > 0) - { - current_alignment += (data.my_sequence().size() * 4) + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - } - - - - - return current_alignment - initial_alignment; -} - - -void SequenceBoundsStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_sequence; - - -} - -void SequenceBoundsStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_sequence; - - -} - - -bool SequenceBoundsStruct::isKeyDefined() -{ - return false; -} - -void SequenceBoundsStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_sequence - * @param _my_sequence New value to be copied in member my_sequence - */ -void SequenceBoundsStruct::my_sequence( - const std::vector& _my_sequence) -{ - m_my_sequence = _my_sequence; -} - -/*! - * @brief This function moves the value in member my_sequence - * @param _my_sequence New value to be moved in member my_sequence - */ -void SequenceBoundsStruct::my_sequence( - std::vector&& _my_sequence) -{ - m_my_sequence = std::move(_my_sequence); -} - -/*! - * @brief This function returns a constant reference to member my_sequence - * @return Constant reference to member my_sequence - */ -const std::vector& SequenceBoundsStruct::my_sequence() const -{ - return m_my_sequence; -} - -/*! - * @brief This function returns a reference to member my_sequence - * @return Reference to member my_sequence - */ -std::vector& SequenceBoundsStruct::my_sequence() -{ - return m_my_sequence; -} - - - - - - - - - -SequenceSequenceStruct::SequenceSequenceStruct() -{ - // sequence, 3> m_my_sequence_sequence - - - // Just to register all known types - registerTypesTypes(); -} - -SequenceSequenceStruct::~SequenceSequenceStruct() -{ -} - -SequenceSequenceStruct::SequenceSequenceStruct( - const SequenceSequenceStruct& x) -{ - m_my_sequence_sequence = x.m_my_sequence_sequence; - -} - -SequenceSequenceStruct::SequenceSequenceStruct( - SequenceSequenceStruct&& x) noexcept -{ - m_my_sequence_sequence = std::move(x.m_my_sequence_sequence); - -} - -SequenceSequenceStruct& SequenceSequenceStruct::operator =( - const SequenceSequenceStruct& x) -{ - m_my_sequence_sequence = x.m_my_sequence_sequence; - - return *this; -} - -SequenceSequenceStruct& SequenceSequenceStruct::operator =( - SequenceSequenceStruct&& x) noexcept -{ - m_my_sequence_sequence = std::move(x.m_my_sequence_sequence); - - return *this; -} - -bool SequenceSequenceStruct::operator ==( - const SequenceSequenceStruct& x) const -{ - return (m_my_sequence_sequence == x.m_my_sequence_sequence); -} - -bool SequenceSequenceStruct::operator !=( - const SequenceSequenceStruct& x) const -{ - return !(*this == x); -} - -size_t SequenceSequenceStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return SequenceSequenceStruct_max_cdr_typesize; -} - -size_t SequenceSequenceStruct::getCdrSerializedSize( - const SequenceSequenceStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - for(size_t a = 0; a < data.my_sequence_sequence().size(); ++a) - { - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - if (data.my_sequence_sequence().at(a).size() > 0) - { - current_alignment += (data.my_sequence_sequence().at(a).size() * 4) + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - } - - - } - - - - return current_alignment - initial_alignment; -} - - -void SequenceSequenceStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_sequence_sequence; - - -} - -void SequenceSequenceStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_sequence_sequence; - - -} - - -bool SequenceSequenceStruct::isKeyDefined() -{ - return false; -} - -void SequenceSequenceStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_sequence_sequence - * @param _my_sequence_sequence New value to be copied in member my_sequence_sequence - */ -void SequenceSequenceStruct::my_sequence_sequence( - const std::vector>& _my_sequence_sequence) -{ - m_my_sequence_sequence = _my_sequence_sequence; -} - -/*! - * @brief This function moves the value in member my_sequence_sequence - * @param _my_sequence_sequence New value to be moved in member my_sequence_sequence - */ -void SequenceSequenceStruct::my_sequence_sequence( - std::vector>&& _my_sequence_sequence) -{ - m_my_sequence_sequence = std::move(_my_sequence_sequence); -} - -/*! - * @brief This function returns a constant reference to member my_sequence_sequence - * @return Constant reference to member my_sequence_sequence - */ -const std::vector>& SequenceSequenceStruct::my_sequence_sequence() const -{ - return m_my_sequence_sequence; -} - -/*! - * @brief This function returns a reference to member my_sequence_sequence - * @return Reference to member my_sequence_sequence - */ -std::vector>& SequenceSequenceStruct::my_sequence_sequence() -{ - return m_my_sequence_sequence; -} - - - - - - - - - -SequenceSequenceBoundsStruct::SequenceSequenceBoundsStruct() -{ - // sequence, 5> m_my_sequence_sequence - - - // Just to register all known types - registerTypesTypes(); -} - -SequenceSequenceBoundsStruct::~SequenceSequenceBoundsStruct() -{ -} - -SequenceSequenceBoundsStruct::SequenceSequenceBoundsStruct( - const SequenceSequenceBoundsStruct& x) -{ - m_my_sequence_sequence = x.m_my_sequence_sequence; - -} - -SequenceSequenceBoundsStruct::SequenceSequenceBoundsStruct( - SequenceSequenceBoundsStruct&& x) noexcept -{ - m_my_sequence_sequence = std::move(x.m_my_sequence_sequence); - -} - -SequenceSequenceBoundsStruct& SequenceSequenceBoundsStruct::operator =( - const SequenceSequenceBoundsStruct& x) -{ - m_my_sequence_sequence = x.m_my_sequence_sequence; - - return *this; -} - -SequenceSequenceBoundsStruct& SequenceSequenceBoundsStruct::operator =( - SequenceSequenceBoundsStruct&& x) noexcept -{ - m_my_sequence_sequence = std::move(x.m_my_sequence_sequence); - - return *this; -} - -bool SequenceSequenceBoundsStruct::operator ==( - const SequenceSequenceBoundsStruct& x) const -{ - return (m_my_sequence_sequence == x.m_my_sequence_sequence); -} - -bool SequenceSequenceBoundsStruct::operator !=( - const SequenceSequenceBoundsStruct& x) const -{ - return !(*this == x); -} - -size_t SequenceSequenceBoundsStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return SequenceSequenceBoundsStruct_max_cdr_typesize; -} - -size_t SequenceSequenceBoundsStruct::getCdrSerializedSize( - const SequenceSequenceBoundsStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - for(size_t a = 0; a < data.my_sequence_sequence().size(); ++a) - { - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - if (data.my_sequence_sequence().at(a).size() > 0) - { - current_alignment += (data.my_sequence_sequence().at(a).size() * 4) + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - } - - - } - - - - return current_alignment - initial_alignment; -} - - -void SequenceSequenceBoundsStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_sequence_sequence; - - -} - -void SequenceSequenceBoundsStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_sequence_sequence; - - -} - - -bool SequenceSequenceBoundsStruct::isKeyDefined() -{ - return false; -} - -void SequenceSequenceBoundsStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_sequence_sequence - * @param _my_sequence_sequence New value to be copied in member my_sequence_sequence - */ -void SequenceSequenceBoundsStruct::my_sequence_sequence( - const std::vector>& _my_sequence_sequence) -{ - m_my_sequence_sequence = _my_sequence_sequence; -} - -/*! - * @brief This function moves the value in member my_sequence_sequence - * @param _my_sequence_sequence New value to be moved in member my_sequence_sequence - */ -void SequenceSequenceBoundsStruct::my_sequence_sequence( - std::vector>&& _my_sequence_sequence) -{ - m_my_sequence_sequence = std::move(_my_sequence_sequence); -} - -/*! - * @brief This function returns a constant reference to member my_sequence_sequence - * @return Constant reference to member my_sequence_sequence - */ -const std::vector>& SequenceSequenceBoundsStruct::my_sequence_sequence() const -{ - return m_my_sequence_sequence; -} - -/*! - * @brief This function returns a reference to member my_sequence_sequence - * @return Reference to member my_sequence_sequence - */ -std::vector>& SequenceSequenceBoundsStruct::my_sequence_sequence() -{ - return m_my_sequence_sequence; -} - - - - - - - -MapStruct::MapStruct() -{ - // map m_my_map - - - // Just to register all known types - registerTypesTypes(); -} - -MapStruct::~MapStruct() -{ -} - -MapStruct::MapStruct( - const MapStruct& x) -{ - m_my_map = x.m_my_map; - -} - -MapStruct::MapStruct( - MapStruct&& x) noexcept -{ - m_my_map = std::move(x.m_my_map); - -} - -MapStruct& MapStruct::operator =( - const MapStruct& x) -{ - m_my_map = x.m_my_map; - - return *this; -} - -MapStruct& MapStruct::operator =( - MapStruct&& x) noexcept -{ - m_my_map = std::move(x.m_my_map); - - return *this; -} - -bool MapStruct::operator ==( - const MapStruct& x) const -{ - return (m_my_map == x.m_my_map); -} - -bool MapStruct::operator !=( - const MapStruct& x) const -{ - return !(*this == x); -} - -size_t MapStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return MapStruct_max_cdr_typesize; -} - -size_t MapStruct::getCdrSerializedSize( - const MapStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - for(auto a : data.my_map()) - { - (void)a; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - } - - - return current_alignment - initial_alignment; -} - - -void MapStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << static_cast(m_my_map.size()); - for (const auto& pair : m_my_map) - { - scdr << pair.first; - scdr << pair.second; - } - -} - -void MapStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - - dcdr >> m_my_map; - - -} - - -bool MapStruct::isKeyDefined() -{ - return false; -} - -void MapStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_map - * @param _my_map New value to be copied in member my_map - */ -void MapStruct::my_map( - const std::map& _my_map) -{ - m_my_map = _my_map; -} - -/*! - * @brief This function moves the value in member my_map - * @param _my_map New value to be moved in member my_map - */ -void MapStruct::my_map( - std::map&& _my_map) -{ - m_my_map = std::move(_my_map); -} - -/*! - * @brief This function returns a constant reference to member my_map - * @return Constant reference to member my_map - */ -const std::map& MapStruct::my_map() const -{ - return m_my_map; -} - -/*! - * @brief This function returns a reference to member my_map - * @return Reference to member my_map - */ -std::map& MapStruct::my_map() -{ - return m_my_map; -} - - - - - - - -MapStructEqual::MapStructEqual() -{ - // map m_my_map_equal - - - // Just to register all known types - registerTypesTypes(); -} - -MapStructEqual::~MapStructEqual() -{ -} - -MapStructEqual::MapStructEqual( - const MapStructEqual& x) -{ - m_my_map_equal = x.m_my_map_equal; - -} - -MapStructEqual::MapStructEqual( - MapStructEqual&& x) noexcept -{ - m_my_map_equal = std::move(x.m_my_map_equal); - -} - -MapStructEqual& MapStructEqual::operator =( - const MapStructEqual& x) -{ - m_my_map_equal = x.m_my_map_equal; - - return *this; -} - -MapStructEqual& MapStructEqual::operator =( - MapStructEqual&& x) noexcept -{ - m_my_map_equal = std::move(x.m_my_map_equal); - - return *this; -} - -bool MapStructEqual::operator ==( - const MapStructEqual& x) const -{ - return (m_my_map_equal == x.m_my_map_equal); -} - -bool MapStructEqual::operator !=( - const MapStructEqual& x) const -{ - return !(*this == x); -} - -size_t MapStructEqual::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return MapStructEqual_max_cdr_typesize; -} - -size_t MapStructEqual::getCdrSerializedSize( - const MapStructEqual& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - for(auto a : data.my_map_equal()) - { - (void)a; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - } - - - return current_alignment - initial_alignment; -} - - -void MapStructEqual::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << static_cast(m_my_map_equal.size()); - for (const auto& pair : m_my_map_equal) - { - scdr << pair.first; - scdr << pair.second; - } - -} - -void MapStructEqual::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - - dcdr >> m_my_map_equal; - - -} - - -bool MapStructEqual::isKeyDefined() -{ - return false; -} - -void MapStructEqual::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_map_equal - * @param _my_map_equal New value to be copied in member my_map_equal - */ -void MapStructEqual::my_map_equal( - const std::map& _my_map_equal) -{ - m_my_map_equal = _my_map_equal; -} - -/*! - * @brief This function moves the value in member my_map_equal - * @param _my_map_equal New value to be moved in member my_map_equal - */ -void MapStructEqual::my_map_equal( - std::map&& _my_map_equal) -{ - m_my_map_equal = std::move(_my_map_equal); -} - -/*! - * @brief This function returns a constant reference to member my_map_equal - * @return Constant reference to member my_map_equal - */ -const std::map& MapStructEqual::my_map_equal() const -{ - return m_my_map_equal; -} - -/*! - * @brief This function returns a reference to member my_map_equal - * @return Reference to member my_map_equal - */ -std::map& MapStructEqual::my_map_equal() -{ - return m_my_map_equal; -} - - - - - - - -MapBadKeyStruct::MapBadKeyStruct() -{ - // map m_my_map - - - // Just to register all known types - registerTypesTypes(); -} - -MapBadKeyStruct::~MapBadKeyStruct() -{ -} - -MapBadKeyStruct::MapBadKeyStruct( - const MapBadKeyStruct& x) -{ - m_my_map = x.m_my_map; - -} - -MapBadKeyStruct::MapBadKeyStruct( - MapBadKeyStruct&& x) noexcept -{ - m_my_map = std::move(x.m_my_map); - -} - -MapBadKeyStruct& MapBadKeyStruct::operator =( - const MapBadKeyStruct& x) -{ - m_my_map = x.m_my_map; - - return *this; -} - -MapBadKeyStruct& MapBadKeyStruct::operator =( - MapBadKeyStruct&& x) noexcept -{ - m_my_map = std::move(x.m_my_map); - - return *this; -} - -bool MapBadKeyStruct::operator ==( - const MapBadKeyStruct& x) const -{ - return (m_my_map == x.m_my_map); -} - -bool MapBadKeyStruct::operator !=( - const MapBadKeyStruct& x) const -{ - return !(*this == x); -} - -size_t MapBadKeyStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return MapBadKeyStruct_max_cdr_typesize; -} - -size_t MapBadKeyStruct::getCdrSerializedSize( - const MapBadKeyStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - for(auto a : data.my_map()) - { - (void)a; - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - } - - - return current_alignment - initial_alignment; -} - - -void MapBadKeyStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << static_cast(m_my_map.size()); - for (const auto& pair : m_my_map) - { - scdr << pair.first; - scdr << pair.second; - } - -} - -void MapBadKeyStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - - dcdr >> m_my_map; - - -} - - -bool MapBadKeyStruct::isKeyDefined() -{ - return false; -} - -void MapBadKeyStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_map - * @param _my_map New value to be copied in member my_map - */ -void MapBadKeyStruct::my_map( - const std::map& _my_map) -{ - m_my_map = _my_map; -} - -/*! - * @brief This function moves the value in member my_map - * @param _my_map New value to be moved in member my_map - */ -void MapBadKeyStruct::my_map( - std::map&& _my_map) -{ - m_my_map = std::move(_my_map); -} - -/*! - * @brief This function returns a constant reference to member my_map - * @return Constant reference to member my_map - */ -const std::map& MapBadKeyStruct::my_map() const -{ - return m_my_map; -} - -/*! - * @brief This function returns a reference to member my_map - * @return Reference to member my_map - */ -std::map& MapBadKeyStruct::my_map() -{ - return m_my_map; -} - - - - - - - -MapBadElemStruct::MapBadElemStruct() -{ - // map m_my_map - - - // Just to register all known types - registerTypesTypes(); -} - -MapBadElemStruct::~MapBadElemStruct() -{ -} - -MapBadElemStruct::MapBadElemStruct( - const MapBadElemStruct& x) -{ - m_my_map = x.m_my_map; - -} - -MapBadElemStruct::MapBadElemStruct( - MapBadElemStruct&& x) noexcept -{ - m_my_map = std::move(x.m_my_map); - -} - -MapBadElemStruct& MapBadElemStruct::operator =( - const MapBadElemStruct& x) -{ - m_my_map = x.m_my_map; - - return *this; -} - -MapBadElemStruct& MapBadElemStruct::operator =( - MapBadElemStruct&& x) noexcept -{ - m_my_map = std::move(x.m_my_map); - - return *this; -} - -bool MapBadElemStruct::operator ==( - const MapBadElemStruct& x) const -{ - return (m_my_map == x.m_my_map); -} - -bool MapBadElemStruct::operator !=( - const MapBadElemStruct& x) const -{ - return !(*this == x); -} - -size_t MapBadElemStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return MapBadElemStruct_max_cdr_typesize; -} - -size_t MapBadElemStruct::getCdrSerializedSize( - const MapBadElemStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - for(auto a : data.my_map()) - { - (void)a; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - current_alignment += 8 + eprosima::fastcdr::Cdr::alignment(current_alignment, 8); - - } - - - return current_alignment - initial_alignment; -} - - -void MapBadElemStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << static_cast(m_my_map.size()); - for (const auto& pair : m_my_map) - { - scdr << pair.first; - scdr << pair.second; - } - -} - -void MapBadElemStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - - dcdr >> m_my_map; - - -} - - -bool MapBadElemStruct::isKeyDefined() -{ - return false; -} - -void MapBadElemStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_map - * @param _my_map New value to be copied in member my_map - */ -void MapBadElemStruct::my_map( - const std::map& _my_map) -{ - m_my_map = _my_map; -} - -/*! - * @brief This function moves the value in member my_map - * @param _my_map New value to be moved in member my_map - */ -void MapBadElemStruct::my_map( - std::map&& _my_map) -{ - m_my_map = std::move(_my_map); -} - -/*! - * @brief This function returns a constant reference to member my_map - * @return Constant reference to member my_map - */ -const std::map& MapBadElemStruct::my_map() const -{ - return m_my_map; -} - -/*! - * @brief This function returns a reference to member my_map - * @return Reference to member my_map - */ -std::map& MapBadElemStruct::my_map() -{ - return m_my_map; -} - - - - - - - -MapBoundsStruct::MapBoundsStruct() -{ - // map m_my_map - - - // Just to register all known types - registerTypesTypes(); -} - -MapBoundsStruct::~MapBoundsStruct() -{ -} - -MapBoundsStruct::MapBoundsStruct( - const MapBoundsStruct& x) -{ - m_my_map = x.m_my_map; - -} - -MapBoundsStruct::MapBoundsStruct( - MapBoundsStruct&& x) noexcept -{ - m_my_map = std::move(x.m_my_map); - -} - -MapBoundsStruct& MapBoundsStruct::operator =( - const MapBoundsStruct& x) -{ - m_my_map = x.m_my_map; - - return *this; -} - -MapBoundsStruct& MapBoundsStruct::operator =( - MapBoundsStruct&& x) noexcept -{ - m_my_map = std::move(x.m_my_map); - - return *this; -} - -bool MapBoundsStruct::operator ==( - const MapBoundsStruct& x) const -{ - return (m_my_map == x.m_my_map); -} - -bool MapBoundsStruct::operator !=( - const MapBoundsStruct& x) const -{ - return !(*this == x); -} - -size_t MapBoundsStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return MapBoundsStruct_max_cdr_typesize; -} - -size_t MapBoundsStruct::getCdrSerializedSize( - const MapBoundsStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - for(auto a : data.my_map()) - { - (void)a; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - } - - - return current_alignment - initial_alignment; -} - - -void MapBoundsStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << static_cast(m_my_map.size()); - for (const auto& pair : m_my_map) - { - scdr << pair.first; - scdr << pair.second; - } - -} - -void MapBoundsStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - - dcdr >> m_my_map; - - -} - - -bool MapBoundsStruct::isKeyDefined() -{ - return false; -} - -void MapBoundsStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_map - * @param _my_map New value to be copied in member my_map - */ -void MapBoundsStruct::my_map( - const std::map& _my_map) -{ - m_my_map = _my_map; -} - -/*! - * @brief This function moves the value in member my_map - * @param _my_map New value to be moved in member my_map - */ -void MapBoundsStruct::my_map( - std::map&& _my_map) -{ - m_my_map = std::move(_my_map); -} - -/*! - * @brief This function returns a constant reference to member my_map - * @return Constant reference to member my_map - */ -const std::map& MapBoundsStruct::my_map() const -{ - return m_my_map; -} - -/*! - * @brief This function returns a reference to member my_map - * @return Reference to member my_map - */ -std::map& MapBoundsStruct::my_map() -{ - return m_my_map; -} - - - - - - - - - -MapMapStruct::MapMapStruct() -{ - // map> m_my_map_map - - - // Just to register all known types - registerTypesTypes(); -} - -MapMapStruct::~MapMapStruct() -{ -} - -MapMapStruct::MapMapStruct( - const MapMapStruct& x) -{ - m_my_map_map = x.m_my_map_map; - -} - -MapMapStruct::MapMapStruct( - MapMapStruct&& x) noexcept -{ - m_my_map_map = std::move(x.m_my_map_map); - -} - -MapMapStruct& MapMapStruct::operator =( - const MapMapStruct& x) -{ - m_my_map_map = x.m_my_map_map; - - return *this; -} - -MapMapStruct& MapMapStruct::operator =( - MapMapStruct&& x) noexcept -{ - m_my_map_map = std::move(x.m_my_map_map); - - return *this; -} - -bool MapMapStruct::operator ==( - const MapMapStruct& x) const -{ - return (m_my_map_map == x.m_my_map_map); -} - -bool MapMapStruct::operator !=( - const MapMapStruct& x) const -{ - return !(*this == x); -} - -size_t MapMapStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return MapMapStruct_max_cdr_typesize; -} - -size_t MapMapStruct::getCdrSerializedSize( - const MapMapStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - for(auto a : data.my_map_map()) - { - (void)a; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - for(auto b : a.second) - { - (void)b; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - } - - } - - - return current_alignment - initial_alignment; -} - - -void MapMapStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << static_cast(m_my_map_map.size()); - for (const auto& pair : m_my_map_map) - { - scdr << pair.first; - scdr << pair.second; - } - -} - -void MapMapStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - - dcdr >> m_my_map_map; - - -} - - -bool MapMapStruct::isKeyDefined() -{ - return false; -} - -void MapMapStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_map_map - * @param _my_map_map New value to be copied in member my_map_map - */ -void MapMapStruct::my_map_map( - const std::map>& _my_map_map) -{ - m_my_map_map = _my_map_map; -} - -/*! - * @brief This function moves the value in member my_map_map - * @param _my_map_map New value to be moved in member my_map_map - */ -void MapMapStruct::my_map_map( - std::map>&& _my_map_map) -{ - m_my_map_map = std::move(_my_map_map); -} - -/*! - * @brief This function returns a constant reference to member my_map_map - * @return Constant reference to member my_map_map - */ -const std::map>& MapMapStruct::my_map_map() const -{ - return m_my_map_map; -} - -/*! - * @brief This function returns a reference to member my_map_map - * @return Reference to member my_map_map - */ -std::map>& MapMapStruct::my_map_map() -{ - return m_my_map_map; -} - - - - - - - - - -MapMapBoundsStruct::MapMapBoundsStruct() -{ - // map> m_my_map_map - - - // Just to register all known types - registerTypesTypes(); -} - -MapMapBoundsStruct::~MapMapBoundsStruct() -{ -} - -MapMapBoundsStruct::MapMapBoundsStruct( - const MapMapBoundsStruct& x) -{ - m_my_map_map = x.m_my_map_map; - -} - -MapMapBoundsStruct::MapMapBoundsStruct( - MapMapBoundsStruct&& x) noexcept -{ - m_my_map_map = std::move(x.m_my_map_map); - -} - -MapMapBoundsStruct& MapMapBoundsStruct::operator =( - const MapMapBoundsStruct& x) -{ - m_my_map_map = x.m_my_map_map; - - return *this; -} - -MapMapBoundsStruct& MapMapBoundsStruct::operator =( - MapMapBoundsStruct&& x) noexcept -{ - m_my_map_map = std::move(x.m_my_map_map); - - return *this; -} - -bool MapMapBoundsStruct::operator ==( - const MapMapBoundsStruct& x) const -{ - return (m_my_map_map == x.m_my_map_map); -} - -bool MapMapBoundsStruct::operator !=( - const MapMapBoundsStruct& x) const -{ - return !(*this == x); -} - -size_t MapMapBoundsStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return MapMapBoundsStruct_max_cdr_typesize; -} - -size_t MapMapBoundsStruct::getCdrSerializedSize( - const MapMapBoundsStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - for(auto a : data.my_map_map()) - { - (void)a; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - for(auto b : a.second) - { - (void)b; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - } - - } - - - return current_alignment - initial_alignment; -} - - -void MapMapBoundsStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << static_cast(m_my_map_map.size()); - for (const auto& pair : m_my_map_map) - { - scdr << pair.first; - scdr << pair.second; - } - -} - -void MapMapBoundsStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - - dcdr >> m_my_map_map; - - -} - - -bool MapMapBoundsStruct::isKeyDefined() -{ - return false; -} - -void MapMapBoundsStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_map_map - * @param _my_map_map New value to be copied in member my_map_map - */ -void MapMapBoundsStruct::my_map_map( - const std::map>& _my_map_map) -{ - m_my_map_map = _my_map_map; -} - -/*! - * @brief This function moves the value in member my_map_map - * @param _my_map_map New value to be moved in member my_map_map - */ -void MapMapBoundsStruct::my_map_map( - std::map>&& _my_map_map) -{ - m_my_map_map = std::move(_my_map_map); -} - -/*! - * @brief This function returns a constant reference to member my_map_map - * @return Constant reference to member my_map_map - */ -const std::map>& MapMapBoundsStruct::my_map_map() const -{ - return m_my_map_map; -} - -/*! - * @brief This function returns a reference to member my_map_map - * @return Reference to member my_map_map - */ -std::map>& MapMapBoundsStruct::my_map_map() -{ - return m_my_map_map; -} - - - - - -SimpleUnion::SimpleUnion() -{ - m__d = A; - // long m_first - m_first = 0; - // long long m_second - m_second = 0; -} - -SimpleUnion::~SimpleUnion() -{ -} - -SimpleUnion::SimpleUnion( - const SimpleUnion& x) -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } -} - -SimpleUnion::SimpleUnion( - SimpleUnion&& x) noexcept -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } -} - -SimpleUnion& SimpleUnion::operator =( - const SimpleUnion& x) -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } - - return *this; -} - -SimpleUnion& SimpleUnion::operator =( - SimpleUnion&& x) noexcept -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } - - return *this; -} - -bool SimpleUnion::operator ==( - const SimpleUnion& x) const -{ - if (m__d != x.m__d) - { - return false; - } - - switch(m__d) - { - case A: - return (m_first == x.m_first); - break; - - - case B: - return (m_second == x.m_second); - break; - - default: - break; - } - return false; -} - -bool SimpleUnion::operator !=( - const SimpleUnion& x) const -{ - return !(*this == x); -} - -void SimpleUnion::_d( - int32_t __d) -{ - bool b = false; - - switch(m__d) - { - case A: - switch(__d) - { - case A: - b = true; - break; - default: - break; - } - break; - - - case B: - switch(__d) - { - case B: - b = true; - break; - default: - break; - } - break; - - } - - if(!b) - { - throw BadParamException("Discriminator doesn't correspond with the selected union member"); - } - - m__d = __d; -} - -int32_t SimpleUnion::_d() const -{ - return m__d; -} - -int32_t& SimpleUnion::_d() -{ - return m__d; -} - -void SimpleUnion::first( - int32_t _first) -{ - m_first = _first; - m__d = A; - -} - -int32_t SimpleUnion::first() const -{ - bool b = false; - - switch(m__d) - { - case A: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first; -} - -int32_t& SimpleUnion::first() -{ - bool b = false; - - switch(m__d) - { - case A: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first; -} - - -void SimpleUnion::second( - int64_t _second) -{ - m_second = _second; - m__d = B; - -} - -int64_t SimpleUnion::second() const -{ - bool b = false; - - switch(m__d) - { - case B: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second; -} - -int64_t& SimpleUnion::second() -{ - bool b = false; - - switch(m__d) - { - case B: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second; -} - - -// TODO(Ricardo) Review -size_t SimpleUnion::getCdrSerializedSize( - const SimpleUnion& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - - switch(data.m__d) - { - case A: - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - break; - - - case B: - current_alignment += 8 + eprosima::fastcdr::Cdr::alignment(current_alignment, 8); - - break; - - default: - break; - } - - return current_alignment - initial_alignment; -} - - -void SimpleUnion::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m__d; - - switch(m__d) - { - case A: - scdr << m_first; - - break; - - - case B: - scdr << m_second; - - break; - - default: - break; - } -} - -void SimpleUnion::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m__d; - - - switch(m__d) - { - case A: - dcdr >> m_first; - - - break; - - - case B: - dcdr >> m_second; - - - break; - - default: - break; - } -} - - - - - -SimpleUnionNames::SimpleUnionNames() -{ - m__d = A; - // long m_first_case - m_first_case = 0; - // long long m_second_case - m_second_case = 0; -} - -SimpleUnionNames::~SimpleUnionNames() -{ -} - -SimpleUnionNames::SimpleUnionNames( - const SimpleUnionNames& x) -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_first_case = x.m_first_case; - break; - - - case B: - m_second_case = x.m_second_case; - break; - - default: - break; - } -} - -SimpleUnionNames::SimpleUnionNames( - SimpleUnionNames&& x) noexcept -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_first_case = x.m_first_case; - break; - - - case B: - m_second_case = x.m_second_case; - break; - - default: - break; - } -} - -SimpleUnionNames& SimpleUnionNames::operator =( - const SimpleUnionNames& x) -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_first_case = x.m_first_case; - break; - - - case B: - m_second_case = x.m_second_case; - break; - - default: - break; - } - - return *this; -} - -SimpleUnionNames& SimpleUnionNames::operator =( - SimpleUnionNames&& x) noexcept -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_first_case = x.m_first_case; - break; - - - case B: - m_second_case = x.m_second_case; - break; - - default: - break; - } - - return *this; -} - -bool SimpleUnionNames::operator ==( - const SimpleUnionNames& x) const -{ - if (m__d != x.m__d) - { - return false; - } - - switch(m__d) - { - case A: - return (m_first_case == x.m_first_case); - break; - - - case B: - return (m_second_case == x.m_second_case); - break; - - default: - break; - } - return false; -} - -bool SimpleUnionNames::operator !=( - const SimpleUnionNames& x) const -{ - return !(*this == x); -} - -void SimpleUnionNames::_d( - int32_t __d) -{ - bool b = false; - - switch(m__d) - { - case A: - switch(__d) - { - case A: - b = true; - break; - default: - break; - } - break; - - - case B: - switch(__d) - { - case B: - b = true; - break; - default: - break; - } - break; - - } - - if(!b) - { - throw BadParamException("Discriminator doesn't correspond with the selected union member"); - } - - m__d = __d; -} - -int32_t SimpleUnionNames::_d() const -{ - return m__d; -} - -int32_t& SimpleUnionNames::_d() -{ - return m__d; -} - -void SimpleUnionNames::first_case( - int32_t _first_case) -{ - m_first_case = _first_case; - m__d = A; - -} - -int32_t SimpleUnionNames::first_case() const -{ - bool b = false; - - switch(m__d) - { - case A: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first_case; -} - -int32_t& SimpleUnionNames::first_case() -{ - bool b = false; - - switch(m__d) - { - case A: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first_case; -} - - -void SimpleUnionNames::second_case( - int64_t _second_case) -{ - m_second_case = _second_case; - m__d = B; - -} - -int64_t SimpleUnionNames::second_case() const -{ - bool b = false; - - switch(m__d) - { - case B: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second_case; -} - -int64_t& SimpleUnionNames::second_case() -{ - bool b = false; - - switch(m__d) - { - case B: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second_case; -} - - -// TODO(Ricardo) Review -size_t SimpleUnionNames::getCdrSerializedSize( - const SimpleUnionNames& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - - switch(data.m__d) - { - case A: - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - break; - - - case B: - current_alignment += 8 + eprosima::fastcdr::Cdr::alignment(current_alignment, 8); - - break; - - default: - break; - } - - return current_alignment - initial_alignment; -} - - -void SimpleUnionNames::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m__d; - - switch(m__d) - { - case A: - scdr << m_first_case; - - break; - - - case B: - scdr << m_second_case; - - break; - - default: - break; - } -} - -void SimpleUnionNames::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m__d; - - - switch(m__d) - { - case A: - dcdr >> m_first_case; - - - break; - - - case B: - dcdr >> m_second_case; - - - break; - - default: - break; - } -} - - - - - -SimpleTypeUnion::SimpleTypeUnion() -{ - m__d = A; - // octet m_first - m_first = 0; - // long long m_second - m_second = 0; -} - -SimpleTypeUnion::~SimpleTypeUnion() -{ -} - -SimpleTypeUnion::SimpleTypeUnion( - const SimpleTypeUnion& x) -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } -} - -SimpleTypeUnion::SimpleTypeUnion( - SimpleTypeUnion&& x) noexcept -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } -} - -SimpleTypeUnion& SimpleTypeUnion::operator =( - const SimpleTypeUnion& x) -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } - - return *this; -} - -SimpleTypeUnion& SimpleTypeUnion::operator =( - SimpleTypeUnion&& x) noexcept -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_first = x.m_first; - break; - - - case B: - m_second = x.m_second; - break; - - default: - break; - } - - return *this; -} - -bool SimpleTypeUnion::operator ==( - const SimpleTypeUnion& x) const -{ - if (m__d != x.m__d) - { - return false; - } - - switch(m__d) - { - case A: - return (m_first == x.m_first); - break; - - - case B: - return (m_second == x.m_second); - break; - - default: - break; - } - return false; -} - -bool SimpleTypeUnion::operator !=( - const SimpleTypeUnion& x) const -{ - return !(*this == x); -} - -void SimpleTypeUnion::_d( - int32_t __d) -{ - bool b = false; - - switch(m__d) - { - case A: - switch(__d) - { - case A: - b = true; - break; - default: - break; - } - break; - - - case B: - switch(__d) - { - case B: - b = true; - break; - default: - break; - } - break; - - } - - if(!b) - { - throw BadParamException("Discriminator doesn't correspond with the selected union member"); - } - - m__d = __d; -} - -int32_t SimpleTypeUnion::_d() const -{ - return m__d; -} - -int32_t& SimpleTypeUnion::_d() -{ - return m__d; -} - -void SimpleTypeUnion::first( - uint8_t _first) -{ - m_first = _first; - m__d = A; - -} - -uint8_t SimpleTypeUnion::first() const -{ - bool b = false; - - switch(m__d) - { - case A: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first; -} - -uint8_t& SimpleTypeUnion::first() -{ - bool b = false; - - switch(m__d) - { - case A: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first; -} - - -void SimpleTypeUnion::second( - int64_t _second) -{ - m_second = _second; - m__d = B; - -} - -int64_t SimpleTypeUnion::second() const -{ - bool b = false; - - switch(m__d) - { - case B: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second; -} - -int64_t& SimpleTypeUnion::second() -{ - bool b = false; - - switch(m__d) - { - case B: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second; -} - - -// TODO(Ricardo) Review -size_t SimpleTypeUnion::getCdrSerializedSize( - const SimpleTypeUnion& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - - switch(data.m__d) - { - case A: - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - break; - - - case B: - current_alignment += 8 + eprosima::fastcdr::Cdr::alignment(current_alignment, 8); - - break; - - default: - break; - } - - return current_alignment - initial_alignment; -} - - -void SimpleTypeUnion::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m__d; - - switch(m__d) - { - case A: - scdr << m_first; - - break; - - - case B: - scdr << m_second; - - break; - - default: - break; - } -} - -void SimpleTypeUnion::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m__d; - - - switch(m__d) - { - case A: - dcdr >> m_first; - - - break; - - - case B: - dcdr >> m_second; - - - break; - - default: - break; - } -} - - - - - -SimpleBadUnion::SimpleBadUnion() -{ - m__d = A; - // long m_first - m_first = 0; - // long long m_second - m_second = 0; -} - -SimpleBadUnion::~SimpleBadUnion() -{ -} - -SimpleBadUnion::SimpleBadUnion( - const SimpleBadUnion& x) -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_first = x.m_first; - break; - - - case C: - m_second = x.m_second; - break; - - default: - break; - } -} - -SimpleBadUnion::SimpleBadUnion( - SimpleBadUnion&& x) noexcept -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_first = x.m_first; - break; - - - case C: - m_second = x.m_second; - break; - - default: - break; - } -} - -SimpleBadUnion& SimpleBadUnion::operator =( - const SimpleBadUnion& x) -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_first = x.m_first; - break; - - - case C: - m_second = x.m_second; - break; - - default: - break; - } - - return *this; -} - -SimpleBadUnion& SimpleBadUnion::operator =( - SimpleBadUnion&& x) noexcept -{ - m__d = x.m__d; - - switch(m__d) - { - case A: - m_first = x.m_first; - break; - - - case C: - m_second = x.m_second; - break; - - default: - break; - } - - return *this; -} - -bool SimpleBadUnion::operator ==( - const SimpleBadUnion& x) const -{ - if (m__d != x.m__d) - { - return false; - } - - switch(m__d) - { - case A: - return (m_first == x.m_first); - break; - - - case C: - return (m_second == x.m_second); - break; - - default: - break; - } - return false; -} - -bool SimpleBadUnion::operator !=( - const SimpleBadUnion& x) const -{ - return !(*this == x); -} - -void SimpleBadUnion::_d( - int32_t __d) -{ - bool b = false; - - switch(m__d) - { - case A: - switch(__d) - { - case A: - b = true; - break; - default: - break; - } - break; - - - case C: - switch(__d) - { - case C: - b = true; - break; - default: - break; - } - break; - - } - - if(!b) - { - throw BadParamException("Discriminator doesn't correspond with the selected union member"); - } - - m__d = __d; -} - -int32_t SimpleBadUnion::_d() const -{ - return m__d; -} - -int32_t& SimpleBadUnion::_d() -{ - return m__d; -} - -void SimpleBadUnion::first( - int32_t _first) -{ - m_first = _first; - m__d = A; - -} - -int32_t SimpleBadUnion::first() const -{ - bool b = false; - - switch(m__d) - { - case A: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first; -} - -int32_t& SimpleBadUnion::first() -{ - bool b = false; - - switch(m__d) - { - case A: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first; -} - - -void SimpleBadUnion::second( - int64_t _second) -{ - m_second = _second; - m__d = C; - -} - -int64_t SimpleBadUnion::second() const -{ - bool b = false; - - switch(m__d) - { - case C: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second; -} - -int64_t& SimpleBadUnion::second() -{ - bool b = false; - - switch(m__d) - { - case C: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second; -} - - -// TODO(Ricardo) Review -size_t SimpleBadUnion::getCdrSerializedSize( - const SimpleBadUnion& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - - - switch(data.m__d) - { - case A: - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - break; - - - case C: - current_alignment += 8 + eprosima::fastcdr::Cdr::alignment(current_alignment, 8); - - break; - - default: - break; - } - - return current_alignment - initial_alignment; -} - - -void SimpleBadUnion::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m__d; - - switch(m__d) - { - case A: - scdr << m_first; - - break; - - - case C: - scdr << m_second; - - break; - - default: - break; - } -} - -void SimpleBadUnion::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m__d; - - - switch(m__d) - { - case A: - dcdr >> m_first; - - - break; - - - case C: - dcdr >> m_second; - - - break; - - default: - break; - } -} - - - - - -SimpleBadDiscUnion::SimpleBadDiscUnion() -{ - m__d = 0; - // long m_first - m_first = 0; - // long long m_second - m_second = 0; -} - -SimpleBadDiscUnion::~SimpleBadDiscUnion() -{ -} - -SimpleBadDiscUnion::SimpleBadDiscUnion( - const SimpleBadDiscUnion& x) -{ - m__d = x.m__d; - - switch(m__d) - { - case 0: - m_first = x.m_first; - break; - - - case 1: - m_second = x.m_second; - break; - - default: - break; - } -} - -SimpleBadDiscUnion::SimpleBadDiscUnion( - SimpleBadDiscUnion&& x) noexcept -{ - m__d = x.m__d; - - switch(m__d) - { - case 0: - m_first = x.m_first; - break; - - - case 1: - m_second = x.m_second; - break; - - default: - break; - } -} - -SimpleBadDiscUnion& SimpleBadDiscUnion::operator =( - const SimpleBadDiscUnion& x) -{ - m__d = x.m__d; - - switch(m__d) - { - case 0: - m_first = x.m_first; - break; - - - case 1: - m_second = x.m_second; - break; - - default: - break; - } - - return *this; -} - -SimpleBadDiscUnion& SimpleBadDiscUnion::operator =( - SimpleBadDiscUnion&& x) noexcept -{ - m__d = x.m__d; - - switch(m__d) - { - case 0: - m_first = x.m_first; - break; - - - case 1: - m_second = x.m_second; - break; - - default: - break; - } - - return *this; -} - -bool SimpleBadDiscUnion::operator ==( - const SimpleBadDiscUnion& x) const -{ - if (m__d != x.m__d) - { - return false; - } - - switch(m__d) - { - case 0: - return (m_first == x.m_first); - break; - - - case 1: - return (m_second == x.m_second); - break; - - default: - break; - } - return false; -} - -bool SimpleBadDiscUnion::operator !=( - const SimpleBadDiscUnion& x) const -{ - return !(*this == x); -} - -void SimpleBadDiscUnion::_d( - uint8_t __d) -{ - bool b = false; - - switch(m__d) - { - case 0: - switch(__d) - { - case 0: - b = true; - break; - default: - break; - } - break; - - - case 1: - switch(__d) - { - case 1: - b = true; - break; - default: - break; - } - break; - - } - - if(!b) - { - throw BadParamException("Discriminator doesn't correspond with the selected union member"); - } - - m__d = __d; -} - -uint8_t SimpleBadDiscUnion::_d() const -{ - return m__d; -} - -uint8_t& SimpleBadDiscUnion::_d() -{ - return m__d; -} - -void SimpleBadDiscUnion::first( - int32_t _first) -{ - m_first = _first; - m__d = 0; - -} - -int32_t SimpleBadDiscUnion::first() const -{ - bool b = false; - - switch(m__d) - { - case 0: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first; -} - -int32_t& SimpleBadDiscUnion::first() -{ - bool b = false; - - switch(m__d) - { - case 0: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_first; -} - - -void SimpleBadDiscUnion::second( - int64_t _second) -{ - m_second = _second; - m__d = 1; - -} - -int64_t SimpleBadDiscUnion::second() const -{ - bool b = false; - - switch(m__d) - { - case 1: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second; -} - -int64_t& SimpleBadDiscUnion::second() -{ - bool b = false; - - switch(m__d) - { - case 1: - b = true; - break; - default: - break; - } - - if(!b) - { - throw BadParamException("This member has not been selected"); - } - - return m_second; -} - - -// TODO(Ricardo) Review -size_t SimpleBadDiscUnion::getCdrSerializedSize( - const SimpleBadDiscUnion& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += 1 + eprosima::fastcdr::Cdr::alignment(current_alignment, 1); - - - - switch(data.m__d) - { - case 0: - current_alignment += 4 + eprosima::fastcdr::Cdr::alignment(current_alignment, 4); - - break; - - - case 1: - current_alignment += 8 + eprosima::fastcdr::Cdr::alignment(current_alignment, 8); - - break; - - default: - break; - } - - return current_alignment - initial_alignment; -} - - -void SimpleBadDiscUnion::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m__d; - - switch(m__d) - { - case 0: - scdr << m_first; - - break; - - - case 1: - scdr << m_second; - - break; - - default: - break; - } -} - -void SimpleBadDiscUnion::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m__d; - - - switch(m__d) - { - case 0: - dcdr >> m_first; - - - break; - - - case 1: - dcdr >> m_second; - - - break; - - default: - break; - } -} - - - - - -SimpleUnionStruct::SimpleUnionStruct() -{ - // SimpleUnion m_my_union - - - // Just to register all known types - registerTypesTypes(); -} - -SimpleUnionStruct::~SimpleUnionStruct() -{ -} - -SimpleUnionStruct::SimpleUnionStruct( - const SimpleUnionStruct& x) -{ - m_my_union = x.m_my_union; - -} - -SimpleUnionStruct::SimpleUnionStruct( - SimpleUnionStruct&& x) noexcept -{ - m_my_union = std::move(x.m_my_union); - -} - -SimpleUnionStruct& SimpleUnionStruct::operator =( - const SimpleUnionStruct& x) -{ - m_my_union = x.m_my_union; - - return *this; -} - -SimpleUnionStruct& SimpleUnionStruct::operator =( - SimpleUnionStruct&& x) noexcept -{ - m_my_union = std::move(x.m_my_union); - - return *this; -} - -bool SimpleUnionStruct::operator ==( - const SimpleUnionStruct& x) const -{ - return (m_my_union == x.m_my_union); -} - -bool SimpleUnionStruct::operator !=( - const SimpleUnionStruct& x) const -{ - return !(*this == x); -} - -size_t SimpleUnionStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return SimpleUnionStruct_max_cdr_typesize; -} - -size_t SimpleUnionStruct::getCdrSerializedSize( - const SimpleUnionStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += SimpleUnion::getCdrSerializedSize(data.my_union(), current_alignment); - - - return current_alignment - initial_alignment; -} - - -void SimpleUnionStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_union; - -} - -void SimpleUnionStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_union; - - -} - - -bool SimpleUnionStruct::isKeyDefined() -{ - return false; -} - -void SimpleUnionStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ -void SimpleUnionStruct::my_union( - const SimpleUnion& _my_union) -{ - m_my_union = _my_union; -} - -/*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ -void SimpleUnionStruct::my_union( - SimpleUnion&& _my_union) -{ - m_my_union = std::move(_my_union); -} - -/*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ -const SimpleUnion& SimpleUnionStruct::my_union() const -{ - return m_my_union; -} - -/*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ -SimpleUnion& SimpleUnionStruct::my_union() -{ - return m_my_union; -} - - - - - -SimpleUnionStructEqual::SimpleUnionStructEqual() -{ - // SimpleUnion m_my_union_equal - - - // Just to register all known types - registerTypesTypes(); -} - -SimpleUnionStructEqual::~SimpleUnionStructEqual() -{ -} - -SimpleUnionStructEqual::SimpleUnionStructEqual( - const SimpleUnionStructEqual& x) -{ - m_my_union_equal = x.m_my_union_equal; - -} - -SimpleUnionStructEqual::SimpleUnionStructEqual( - SimpleUnionStructEqual&& x) noexcept -{ - m_my_union_equal = std::move(x.m_my_union_equal); - -} - -SimpleUnionStructEqual& SimpleUnionStructEqual::operator =( - const SimpleUnionStructEqual& x) -{ - m_my_union_equal = x.m_my_union_equal; - - return *this; -} - -SimpleUnionStructEqual& SimpleUnionStructEqual::operator =( - SimpleUnionStructEqual&& x) noexcept -{ - m_my_union_equal = std::move(x.m_my_union_equal); - - return *this; -} - -bool SimpleUnionStructEqual::operator ==( - const SimpleUnionStructEqual& x) const -{ - return (m_my_union_equal == x.m_my_union_equal); -} - -bool SimpleUnionStructEqual::operator !=( - const SimpleUnionStructEqual& x) const -{ - return !(*this == x); -} - -size_t SimpleUnionStructEqual::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return SimpleUnionStructEqual_max_cdr_typesize; -} - -size_t SimpleUnionStructEqual::getCdrSerializedSize( - const SimpleUnionStructEqual& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += SimpleUnion::getCdrSerializedSize(data.my_union_equal(), current_alignment); - - - return current_alignment - initial_alignment; -} - - -void SimpleUnionStructEqual::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_union_equal; - -} - -void SimpleUnionStructEqual::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_union_equal; - - -} - - -bool SimpleUnionStructEqual::isKeyDefined() -{ - return false; -} - -void SimpleUnionStructEqual::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_union_equal - * @param _my_union_equal New value to be copied in member my_union_equal - */ -void SimpleUnionStructEqual::my_union_equal( - const SimpleUnion& _my_union_equal) -{ - m_my_union_equal = _my_union_equal; -} - -/*! - * @brief This function moves the value in member my_union_equal - * @param _my_union_equal New value to be moved in member my_union_equal - */ -void SimpleUnionStructEqual::my_union_equal( - SimpleUnion&& _my_union_equal) -{ - m_my_union_equal = std::move(_my_union_equal); -} - -/*! - * @brief This function returns a constant reference to member my_union_equal - * @return Constant reference to member my_union_equal - */ -const SimpleUnion& SimpleUnionStructEqual::my_union_equal() const -{ - return m_my_union_equal; -} - -/*! - * @brief This function returns a reference to member my_union_equal - * @return Reference to member my_union_equal - */ -SimpleUnion& SimpleUnionStructEqual::my_union_equal() -{ - return m_my_union_equal; -} - - - - - -SimpleUnionNamesStruct::SimpleUnionNamesStruct() -{ - // SimpleUnionNames m_my_union - - - // Just to register all known types - registerTypesTypes(); -} - -SimpleUnionNamesStruct::~SimpleUnionNamesStruct() -{ -} - -SimpleUnionNamesStruct::SimpleUnionNamesStruct( - const SimpleUnionNamesStruct& x) -{ - m_my_union = x.m_my_union; - -} - -SimpleUnionNamesStruct::SimpleUnionNamesStruct( - SimpleUnionNamesStruct&& x) noexcept -{ - m_my_union = std::move(x.m_my_union); - -} - -SimpleUnionNamesStruct& SimpleUnionNamesStruct::operator =( - const SimpleUnionNamesStruct& x) -{ - m_my_union = x.m_my_union; - - return *this; -} - -SimpleUnionNamesStruct& SimpleUnionNamesStruct::operator =( - SimpleUnionNamesStruct&& x) noexcept -{ - m_my_union = std::move(x.m_my_union); - - return *this; -} - -bool SimpleUnionNamesStruct::operator ==( - const SimpleUnionNamesStruct& x) const -{ - return (m_my_union == x.m_my_union); -} - -bool SimpleUnionNamesStruct::operator !=( - const SimpleUnionNamesStruct& x) const -{ - return !(*this == x); -} - -size_t SimpleUnionNamesStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return SimpleUnionNamesStruct_max_cdr_typesize; -} - -size_t SimpleUnionNamesStruct::getCdrSerializedSize( - const SimpleUnionNamesStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += SimpleUnionNames::getCdrSerializedSize(data.my_union(), current_alignment); - - - return current_alignment - initial_alignment; -} - - -void SimpleUnionNamesStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_union; - -} - -void SimpleUnionNamesStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_union; - - -} - - -bool SimpleUnionNamesStruct::isKeyDefined() -{ - return false; -} - -void SimpleUnionNamesStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ -void SimpleUnionNamesStruct::my_union( - const SimpleUnionNames& _my_union) -{ - m_my_union = _my_union; -} - -/*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ -void SimpleUnionNamesStruct::my_union( - SimpleUnionNames&& _my_union) -{ - m_my_union = std::move(_my_union); -} - -/*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ -const SimpleUnionNames& SimpleUnionNamesStruct::my_union() const -{ - return m_my_union; -} - -/*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ -SimpleUnionNames& SimpleUnionNamesStruct::my_union() -{ - return m_my_union; -} - - - - - -SimpleTypeUnionStruct::SimpleTypeUnionStruct() -{ - // SimpleTypeUnion m_my_union - - - // Just to register all known types - registerTypesTypes(); -} - -SimpleTypeUnionStruct::~SimpleTypeUnionStruct() -{ -} - -SimpleTypeUnionStruct::SimpleTypeUnionStruct( - const SimpleTypeUnionStruct& x) -{ - m_my_union = x.m_my_union; - -} - -SimpleTypeUnionStruct::SimpleTypeUnionStruct( - SimpleTypeUnionStruct&& x) noexcept -{ - m_my_union = std::move(x.m_my_union); - -} - -SimpleTypeUnionStruct& SimpleTypeUnionStruct::operator =( - const SimpleTypeUnionStruct& x) -{ - m_my_union = x.m_my_union; - - return *this; -} - -SimpleTypeUnionStruct& SimpleTypeUnionStruct::operator =( - SimpleTypeUnionStruct&& x) noexcept -{ - m_my_union = std::move(x.m_my_union); - - return *this; -} - -bool SimpleTypeUnionStruct::operator ==( - const SimpleTypeUnionStruct& x) const -{ - return (m_my_union == x.m_my_union); -} - -bool SimpleTypeUnionStruct::operator !=( - const SimpleTypeUnionStruct& x) const -{ - return !(*this == x); -} - -size_t SimpleTypeUnionStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return SimpleTypeUnionStruct_max_cdr_typesize; -} - -size_t SimpleTypeUnionStruct::getCdrSerializedSize( - const SimpleTypeUnionStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += SimpleTypeUnion::getCdrSerializedSize(data.my_union(), current_alignment); - - - return current_alignment - initial_alignment; -} - - -void SimpleTypeUnionStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_union; - -} - -void SimpleTypeUnionStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_union; - - -} - - -bool SimpleTypeUnionStruct::isKeyDefined() -{ - return false; -} - -void SimpleTypeUnionStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ -void SimpleTypeUnionStruct::my_union( - const SimpleTypeUnion& _my_union) -{ - m_my_union = _my_union; -} - -/*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ -void SimpleTypeUnionStruct::my_union( - SimpleTypeUnion&& _my_union) -{ - m_my_union = std::move(_my_union); -} - -/*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ -const SimpleTypeUnion& SimpleTypeUnionStruct::my_union() const -{ - return m_my_union; -} - -/*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ -SimpleTypeUnion& SimpleTypeUnionStruct::my_union() -{ - return m_my_union; -} - - - - - -SimpleBadUnionStruct::SimpleBadUnionStruct() -{ - // SimpleBadUnion m_my_union - - - // Just to register all known types - registerTypesTypes(); -} - -SimpleBadUnionStruct::~SimpleBadUnionStruct() -{ -} - -SimpleBadUnionStruct::SimpleBadUnionStruct( - const SimpleBadUnionStruct& x) -{ - m_my_union = x.m_my_union; - -} - -SimpleBadUnionStruct::SimpleBadUnionStruct( - SimpleBadUnionStruct&& x) noexcept -{ - m_my_union = std::move(x.m_my_union); - -} - -SimpleBadUnionStruct& SimpleBadUnionStruct::operator =( - const SimpleBadUnionStruct& x) -{ - m_my_union = x.m_my_union; - - return *this; -} - -SimpleBadUnionStruct& SimpleBadUnionStruct::operator =( - SimpleBadUnionStruct&& x) noexcept -{ - m_my_union = std::move(x.m_my_union); - - return *this; -} - -bool SimpleBadUnionStruct::operator ==( - const SimpleBadUnionStruct& x) const -{ - return (m_my_union == x.m_my_union); -} - -bool SimpleBadUnionStruct::operator !=( - const SimpleBadUnionStruct& x) const -{ - return !(*this == x); -} - -size_t SimpleBadUnionStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return SimpleBadUnionStruct_max_cdr_typesize; -} - -size_t SimpleBadUnionStruct::getCdrSerializedSize( - const SimpleBadUnionStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += SimpleBadUnion::getCdrSerializedSize(data.my_union(), current_alignment); - - - return current_alignment - initial_alignment; -} - - -void SimpleBadUnionStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_union; - -} - -void SimpleBadUnionStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_union; - - -} - - -bool SimpleBadUnionStruct::isKeyDefined() -{ - return false; -} - -void SimpleBadUnionStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ -void SimpleBadUnionStruct::my_union( - const SimpleBadUnion& _my_union) -{ - m_my_union = _my_union; -} - -/*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ -void SimpleBadUnionStruct::my_union( - SimpleBadUnion&& _my_union) -{ - m_my_union = std::move(_my_union); -} - -/*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ -const SimpleBadUnion& SimpleBadUnionStruct::my_union() const -{ - return m_my_union; -} - -/*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ -SimpleBadUnion& SimpleBadUnionStruct::my_union() -{ - return m_my_union; -} - - - - - -SimplBadDiscUnionStruct::SimplBadDiscUnionStruct() -{ - // SimpleBadDiscUnion m_my_union - - - // Just to register all known types - registerTypesTypes(); -} - -SimplBadDiscUnionStruct::~SimplBadDiscUnionStruct() -{ -} - -SimplBadDiscUnionStruct::SimplBadDiscUnionStruct( - const SimplBadDiscUnionStruct& x) -{ - m_my_union = x.m_my_union; - -} - -SimplBadDiscUnionStruct::SimplBadDiscUnionStruct( - SimplBadDiscUnionStruct&& x) noexcept -{ - m_my_union = std::move(x.m_my_union); - -} - -SimplBadDiscUnionStruct& SimplBadDiscUnionStruct::operator =( - const SimplBadDiscUnionStruct& x) -{ - m_my_union = x.m_my_union; - - return *this; -} - -SimplBadDiscUnionStruct& SimplBadDiscUnionStruct::operator =( - SimplBadDiscUnionStruct&& x) noexcept -{ - m_my_union = std::move(x.m_my_union); - - return *this; -} - -bool SimplBadDiscUnionStruct::operator ==( - const SimplBadDiscUnionStruct& x) const -{ - return (m_my_union == x.m_my_union); -} - -bool SimplBadDiscUnionStruct::operator !=( - const SimplBadDiscUnionStruct& x) const -{ - return !(*this == x); -} - -size_t SimplBadDiscUnionStruct::getMaxCdrSerializedSize( - size_t current_alignment) -{ - static_cast(current_alignment); - return SimplBadDiscUnionStruct_max_cdr_typesize; -} - -size_t SimplBadDiscUnionStruct::getCdrSerializedSize( - const SimplBadDiscUnionStruct& data, - size_t current_alignment) -{ - (void)data; - size_t initial_alignment = current_alignment; - - current_alignment += SimpleBadDiscUnion::getCdrSerializedSize(data.my_union(), current_alignment); - - - return current_alignment - initial_alignment; -} - - -void SimplBadDiscUnionStruct::serialize( - eprosima::fastcdr::Cdr& scdr) const -{ - scdr << m_my_union; - -} - -void SimplBadDiscUnionStruct::deserialize( - eprosima::fastcdr::Cdr& dcdr) -{ - dcdr >> m_my_union; - - -} - - -bool SimplBadDiscUnionStruct::isKeyDefined() -{ - return false; -} - -void SimplBadDiscUnionStruct::serializeKey( - eprosima::fastcdr::Cdr& scdr) const -{ - (void) scdr; -} - -/*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ -void SimplBadDiscUnionStruct::my_union( - const SimpleBadDiscUnion& _my_union) -{ - m_my_union = _my_union; -} - -/*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ -void SimplBadDiscUnionStruct::my_union( - SimpleBadDiscUnion&& _my_union) -{ - m_my_union = std::move(_my_union); -} - -/*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ -const SimpleBadDiscUnion& SimplBadDiscUnionStruct::my_union() const -{ - return m_my_union; -} - -/*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ -SimpleBadDiscUnion& SimplBadDiscUnionStruct::my_union() -{ - return m_my_union; -} - - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/test/xtypes/idl/Typesv1.h b/test/xtypes/idl/Typesv1.h deleted file mode 100644 index d350f662843..00000000000 --- a/test/xtypes/idl/Typesv1.h +++ /dev/null @@ -1,6496 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/*! - * @file Types.h - * This header file contains the declaration of the described types in the IDL file. - * - * This file was generated by the tool fastddsgen. - */ - -#include - -#if FASTCDR_VERSION_MAJOR == 1 - -#ifndef _FAST_DDS_GENERATED_TYPES_H_ -#define _FAST_DDS_GENERATED_TYPES_H_ - - -#include - -#include -#include -#include -#include -#include -#include -#include - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#define eProsima_user_DllExport __declspec( dllexport ) -#else -#define eProsima_user_DllExport -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define eProsima_user_DllExport -#endif // _WIN32 - -#if defined(_WIN32) -#if defined(EPROSIMA_USER_DLL_EXPORT) -#if defined(TYPES_SOURCE) -#define TYPES_DllAPI __declspec( dllexport ) -#else -#define TYPES_DllAPI __declspec( dllimport ) -#endif // TYPES_SOURCE -#else -#define TYPES_DllAPI -#endif // EPROSIMA_USER_DLL_EXPORT -#else -#define TYPES_DllAPI -#endif // _WIN32 - -namespace eprosima { -namespace fastcdr { -class Cdr; -} // namespace fastcdr -} // namespace eprosima - - - -/*! - * @brief This class represents the enumeration MyEnum defined by the user in the IDL file. - * @ingroup Types - */ -enum MyEnum : uint32_t -{ - A, - B, - C -}; -/*! - * @brief This class represents the enumeration MyBadEnum defined by the user in the IDL file. - * @ingroup Types - */ -enum MyBadEnum : uint32_t -{ - A1, - B1, - C1 -}; - - -/*! - * @brief This class represents the structure MyEnumStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MyEnumStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MyEnumStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MyEnumStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MyEnumStruct that will be copied. - */ - eProsima_user_DllExport MyEnumStruct( - const MyEnumStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MyEnumStruct that will be copied. - */ - eProsima_user_DllExport MyEnumStruct( - MyEnumStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MyEnumStruct that will be copied. - */ - eProsima_user_DllExport MyEnumStruct& operator =( - const MyEnumStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MyEnumStruct that will be copied. - */ - eProsima_user_DllExport MyEnumStruct& operator =( - MyEnumStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MyEnumStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MyEnumStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x MyEnumStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MyEnumStruct& x) const; - - /*! - * @brief This function sets a value in member my_enum - * @param _my_enum New value for member my_enum - */ - eProsima_user_DllExport void my_enum( - MyEnum _my_enum); - - /*! - * @brief This function returns the value of member my_enum - * @return Value of member my_enum - */ - eProsima_user_DllExport MyEnum my_enum() const; - - /*! - * @brief This function returns a reference to member my_enum - * @return Reference to member my_enum - */ - eProsima_user_DllExport MyEnum& my_enum(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const MyEnumStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - MyEnum m_my_enum; - -}; - - - -/*! - * @brief This class represents the structure MyBadEnumStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MyBadEnumStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MyBadEnumStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MyBadEnumStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MyBadEnumStruct that will be copied. - */ - eProsima_user_DllExport MyBadEnumStruct( - const MyBadEnumStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MyBadEnumStruct that will be copied. - */ - eProsima_user_DllExport MyBadEnumStruct( - MyBadEnumStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MyBadEnumStruct that will be copied. - */ - eProsima_user_DllExport MyBadEnumStruct& operator =( - const MyBadEnumStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MyBadEnumStruct that will be copied. - */ - eProsima_user_DllExport MyBadEnumStruct& operator =( - MyBadEnumStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MyBadEnumStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MyBadEnumStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x MyBadEnumStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MyBadEnumStruct& x) const; - - /*! - * @brief This function sets a value in member my_enum - * @param _my_enum New value for member my_enum - */ - eProsima_user_DllExport void my_enum( - MyBadEnum _my_enum); - - /*! - * @brief This function returns the value of member my_enum - * @return Value of member my_enum - */ - eProsima_user_DllExport MyBadEnum my_enum() const; - - /*! - * @brief This function returns a reference to member my_enum - * @return Reference to member my_enum - */ - eProsima_user_DllExport MyBadEnum& my_enum(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const MyBadEnumStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - MyBadEnum m_my_enum; - -}; - -typedef MyEnum MyAliasEnum; - - - -/*! - * @brief This class represents the structure MyAliasEnumStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MyAliasEnumStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MyAliasEnumStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MyAliasEnumStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MyAliasEnumStruct that will be copied. - */ - eProsima_user_DllExport MyAliasEnumStruct( - const MyAliasEnumStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MyAliasEnumStruct that will be copied. - */ - eProsima_user_DllExport MyAliasEnumStruct( - MyAliasEnumStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MyAliasEnumStruct that will be copied. - */ - eProsima_user_DllExport MyAliasEnumStruct& operator =( - const MyAliasEnumStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MyAliasEnumStruct that will be copied. - */ - eProsima_user_DllExport MyAliasEnumStruct& operator =( - MyAliasEnumStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MyAliasEnumStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MyAliasEnumStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x MyAliasEnumStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MyAliasEnumStruct& x) const; - - /*! - * @brief This function sets a value in member my_enum - * @param _my_enum New value for member my_enum - */ - eProsima_user_DllExport void my_enum( - MyAliasEnum _my_enum); - - /*! - * @brief This function returns the value of member my_enum - * @return Value of member my_enum - */ - eProsima_user_DllExport MyAliasEnum my_enum() const; - - /*! - * @brief This function returns a reference to member my_enum - * @return Reference to member my_enum - */ - eProsima_user_DllExport MyAliasEnum& my_enum(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const MyAliasEnumStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - MyAliasEnum m_my_enum; - -}; - - - -/*! - * @brief This class represents the structure BasicStruct defined by the user in the IDL file. - * @ingroup Types - */ -class BasicStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport BasicStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~BasicStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object BasicStruct that will be copied. - */ - eProsima_user_DllExport BasicStruct( - const BasicStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object BasicStruct that will be copied. - */ - eProsima_user_DllExport BasicStruct( - BasicStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object BasicStruct that will be copied. - */ - eProsima_user_DllExport BasicStruct& operator =( - const BasicStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object BasicStruct that will be copied. - */ - eProsima_user_DllExport BasicStruct& operator =( - BasicStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x BasicStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const BasicStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x BasicStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const BasicStruct& x) const; - - /*! - * @brief This function sets a value in member my_bool - * @param _my_bool New value for member my_bool - */ - eProsima_user_DllExport void my_bool( - bool _my_bool); - - /*! - * @brief This function returns the value of member my_bool - * @return Value of member my_bool - */ - eProsima_user_DllExport bool my_bool() const; - - /*! - * @brief This function returns a reference to member my_bool - * @return Reference to member my_bool - */ - eProsima_user_DllExport bool& my_bool(); - - - /*! - * @brief This function sets a value in member my_int32 - * @param _my_int32 New value for member my_int32 - */ - eProsima_user_DllExport void my_int32( - int32_t _my_int32); - - /*! - * @brief This function returns the value of member my_int32 - * @return Value of member my_int32 - */ - eProsima_user_DllExport int32_t my_int32() const; - - /*! - * @brief This function returns a reference to member my_int32 - * @return Reference to member my_int32 - */ - eProsima_user_DllExport int32_t& my_int32(); - - - /*! - * @brief This function copies the value in member my_string - * @param _my_string New value to be copied in member my_string - */ - eProsima_user_DllExport void my_string( - const std::string& _my_string); - - /*! - * @brief This function moves the value in member my_string - * @param _my_string New value to be moved in member my_string - */ - eProsima_user_DllExport void my_string( - std::string&& _my_string); - - /*! - * @brief This function returns a constant reference to member my_string - * @return Constant reference to member my_string - */ - eProsima_user_DllExport const std::string& my_string() const; - - /*! - * @brief This function returns a reference to member my_string - * @return Reference to member my_string - */ - eProsima_user_DllExport std::string& my_string(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const BasicStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - bool m_my_bool; - int32_t m_my_int32; - std::string m_my_string; - -}; - - - -/*! - * @brief This class represents the structure BasicNamesStruct defined by the user in the IDL file. - * @ingroup Types - */ -class BasicNamesStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport BasicNamesStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~BasicNamesStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object BasicNamesStruct that will be copied. - */ - eProsima_user_DllExport BasicNamesStruct( - const BasicNamesStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object BasicNamesStruct that will be copied. - */ - eProsima_user_DllExport BasicNamesStruct( - BasicNamesStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object BasicNamesStruct that will be copied. - */ - eProsima_user_DllExport BasicNamesStruct& operator =( - const BasicNamesStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object BasicNamesStruct that will be copied. - */ - eProsima_user_DllExport BasicNamesStruct& operator =( - BasicNamesStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x BasicNamesStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const BasicNamesStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x BasicNamesStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const BasicNamesStruct& x) const; - - /*! - * @brief This function sets a value in member my_bool_name - * @param _my_bool_name New value for member my_bool_name - */ - eProsima_user_DllExport void my_bool_name( - bool _my_bool_name); - - /*! - * @brief This function returns the value of member my_bool_name - * @return Value of member my_bool_name - */ - eProsima_user_DllExport bool my_bool_name() const; - - /*! - * @brief This function returns a reference to member my_bool_name - * @return Reference to member my_bool_name - */ - eProsima_user_DllExport bool& my_bool_name(); - - - /*! - * @brief This function sets a value in member my_int32_name - * @param _my_int32_name New value for member my_int32_name - */ - eProsima_user_DllExport void my_int32_name( - int32_t _my_int32_name); - - /*! - * @brief This function returns the value of member my_int32_name - * @return Value of member my_int32_name - */ - eProsima_user_DllExport int32_t my_int32_name() const; - - /*! - * @brief This function returns a reference to member my_int32_name - * @return Reference to member my_int32_name - */ - eProsima_user_DllExport int32_t& my_int32_name(); - - - /*! - * @brief This function copies the value in member my_string_name - * @param _my_string_name New value to be copied in member my_string_name - */ - eProsima_user_DllExport void my_string_name( - const std::string& _my_string_name); - - /*! - * @brief This function moves the value in member my_string_name - * @param _my_string_name New value to be moved in member my_string_name - */ - eProsima_user_DllExport void my_string_name( - std::string&& _my_string_name); - - /*! - * @brief This function returns a constant reference to member my_string_name - * @return Constant reference to member my_string_name - */ - eProsima_user_DllExport const std::string& my_string_name() const; - - /*! - * @brief This function returns a reference to member my_string_name - * @return Reference to member my_string_name - */ - eProsima_user_DllExport std::string& my_string_name(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const BasicNamesStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - bool m_my_bool_name; - int32_t m_my_int32_name; - std::string m_my_string_name; - -}; - - - -/*! - * @brief This class represents the structure BasicBadStruct defined by the user in the IDL file. - * @ingroup Types - */ -class BasicBadStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport BasicBadStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~BasicBadStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object BasicBadStruct that will be copied. - */ - eProsima_user_DllExport BasicBadStruct( - const BasicBadStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object BasicBadStruct that will be copied. - */ - eProsima_user_DllExport BasicBadStruct( - BasicBadStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object BasicBadStruct that will be copied. - */ - eProsima_user_DllExport BasicBadStruct& operator =( - const BasicBadStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object BasicBadStruct that will be copied. - */ - eProsima_user_DllExport BasicBadStruct& operator =( - BasicBadStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x BasicBadStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const BasicBadStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x BasicBadStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const BasicBadStruct& x) const; - - /*! - * @brief This function sets a value in member my_bool - * @param _my_bool New value for member my_bool - */ - eProsima_user_DllExport void my_bool( - uint8_t _my_bool); - - /*! - * @brief This function returns the value of member my_bool - * @return Value of member my_bool - */ - eProsima_user_DllExport uint8_t my_bool() const; - - /*! - * @brief This function returns a reference to member my_bool - * @return Reference to member my_bool - */ - eProsima_user_DllExport uint8_t& my_bool(); - - - /*! - * @brief This function sets a value in member my_int32 - * @param _my_int32 New value for member my_int32 - */ - eProsima_user_DllExport void my_int32( - int32_t _my_int32); - - /*! - * @brief This function returns the value of member my_int32 - * @return Value of member my_int32 - */ - eProsima_user_DllExport int32_t my_int32() const; - - /*! - * @brief This function returns a reference to member my_int32 - * @return Reference to member my_int32 - */ - eProsima_user_DllExport int32_t& my_int32(); - - - /*! - * @brief This function copies the value in member my_string - * @param _my_string New value to be copied in member my_string - */ - eProsima_user_DllExport void my_string( - const std::string& _my_string); - - /*! - * @brief This function moves the value in member my_string - * @param _my_string New value to be moved in member my_string - */ - eProsima_user_DllExport void my_string( - std::string&& _my_string); - - /*! - * @brief This function returns a constant reference to member my_string - * @return Constant reference to member my_string - */ - eProsima_user_DllExport const std::string& my_string() const; - - /*! - * @brief This function returns a reference to member my_string - * @return Reference to member my_string - */ - eProsima_user_DllExport std::string& my_string(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const BasicBadStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - uint8_t m_my_bool; - int32_t m_my_int32; - std::string m_my_string; - -}; - - - -/*! - * @brief This class represents the structure BasicWideStruct defined by the user in the IDL file. - * @ingroup Types - */ -class BasicWideStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport BasicWideStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~BasicWideStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object BasicWideStruct that will be copied. - */ - eProsima_user_DllExport BasicWideStruct( - const BasicWideStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object BasicWideStruct that will be copied. - */ - eProsima_user_DllExport BasicWideStruct( - BasicWideStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object BasicWideStruct that will be copied. - */ - eProsima_user_DllExport BasicWideStruct& operator =( - const BasicWideStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object BasicWideStruct that will be copied. - */ - eProsima_user_DllExport BasicWideStruct& operator =( - BasicWideStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x BasicWideStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const BasicWideStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x BasicWideStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const BasicWideStruct& x) const; - - /*! - * @brief This function sets a value in member my_bool - * @param _my_bool New value for member my_bool - */ - eProsima_user_DllExport void my_bool( - bool _my_bool); - - /*! - * @brief This function returns the value of member my_bool - * @return Value of member my_bool - */ - eProsima_user_DllExport bool my_bool() const; - - /*! - * @brief This function returns a reference to member my_bool - * @return Reference to member my_bool - */ - eProsima_user_DllExport bool& my_bool(); - - - /*! - * @brief This function sets a value in member my_int32 - * @param _my_int32 New value for member my_int32 - */ - eProsima_user_DllExport void my_int32( - int32_t _my_int32); - - /*! - * @brief This function returns the value of member my_int32 - * @return Value of member my_int32 - */ - eProsima_user_DllExport int32_t my_int32() const; - - /*! - * @brief This function returns a reference to member my_int32 - * @return Reference to member my_int32 - */ - eProsima_user_DllExport int32_t& my_int32(); - - - /*! - * @brief This function copies the value in member my_string - * @param _my_string New value to be copied in member my_string - */ - eProsima_user_DllExport void my_string( - const std::string& _my_string); - - /*! - * @brief This function moves the value in member my_string - * @param _my_string New value to be moved in member my_string - */ - eProsima_user_DllExport void my_string( - std::string&& _my_string); - - /*! - * @brief This function returns a constant reference to member my_string - * @return Constant reference to member my_string - */ - eProsima_user_DllExport const std::string& my_string() const; - - /*! - * @brief This function returns a reference to member my_string - * @return Reference to member my_string - */ - eProsima_user_DllExport std::string& my_string(); - - - /*! - * @brief This function sets a value in member new_int32 - * @param _new_int32 New value for member new_int32 - */ - eProsima_user_DllExport void new_int32( - int32_t _new_int32); - - /*! - * @brief This function returns the value of member new_int32 - * @return Value of member new_int32 - */ - eProsima_user_DllExport int32_t new_int32() const; - - /*! - * @brief This function returns a reference to member new_int32 - * @return Reference to member new_int32 - */ - eProsima_user_DllExport int32_t& new_int32(); - - - /*! - * @brief This function copies the value in member new_string - * @param _new_string New value to be copied in member new_string - */ - eProsima_user_DllExport void new_string( - const std::string& _new_string); - - /*! - * @brief This function moves the value in member new_string - * @param _new_string New value to be moved in member new_string - */ - eProsima_user_DllExport void new_string( - std::string&& _new_string); - - /*! - * @brief This function returns a constant reference to member new_string - * @return Constant reference to member new_string - */ - eProsima_user_DllExport const std::string& new_string() const; - - /*! - * @brief This function returns a reference to member new_string - * @return Reference to member new_string - */ - eProsima_user_DllExport std::string& new_string(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const BasicWideStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - bool m_my_bool; - int32_t m_my_int32; - std::string m_my_string; - int32_t m_new_int32; - std::string m_new_string; - -}; - - - -/*! - * @brief This class represents the structure BadBasicWideStruct defined by the user in the IDL file. - * @ingroup Types - */ -class BadBasicWideStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport BadBasicWideStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~BadBasicWideStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object BadBasicWideStruct that will be copied. - */ - eProsima_user_DllExport BadBasicWideStruct( - const BadBasicWideStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object BadBasicWideStruct that will be copied. - */ - eProsima_user_DllExport BadBasicWideStruct( - BadBasicWideStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object BadBasicWideStruct that will be copied. - */ - eProsima_user_DllExport BadBasicWideStruct& operator =( - const BadBasicWideStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object BadBasicWideStruct that will be copied. - */ - eProsima_user_DllExport BadBasicWideStruct& operator =( - BadBasicWideStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x BadBasicWideStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const BadBasicWideStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x BadBasicWideStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const BadBasicWideStruct& x) const; - - /*! - * @brief This function sets a value in member new_int32 - * @param _new_int32 New value for member new_int32 - */ - eProsima_user_DllExport void new_int32( - int32_t _new_int32); - - /*! - * @brief This function returns the value of member new_int32 - * @return Value of member new_int32 - */ - eProsima_user_DllExport int32_t new_int32() const; - - /*! - * @brief This function returns a reference to member new_int32 - * @return Reference to member new_int32 - */ - eProsima_user_DllExport int32_t& new_int32(); - - - /*! - * @brief This function copies the value in member new_string - * @param _new_string New value to be copied in member new_string - */ - eProsima_user_DllExport void new_string( - const std::string& _new_string); - - /*! - * @brief This function moves the value in member new_string - * @param _new_string New value to be moved in member new_string - */ - eProsima_user_DllExport void new_string( - std::string&& _new_string); - - /*! - * @brief This function returns a constant reference to member new_string - * @return Constant reference to member new_string - */ - eProsima_user_DllExport const std::string& new_string() const; - - /*! - * @brief This function returns a reference to member new_string - * @return Reference to member new_string - */ - eProsima_user_DllExport std::string& new_string(); - - - /*! - * @brief This function sets a value in member my_bool - * @param _my_bool New value for member my_bool - */ - eProsima_user_DllExport void my_bool( - bool _my_bool); - - /*! - * @brief This function returns the value of member my_bool - * @return Value of member my_bool - */ - eProsima_user_DllExport bool my_bool() const; - - /*! - * @brief This function returns a reference to member my_bool - * @return Reference to member my_bool - */ - eProsima_user_DllExport bool& my_bool(); - - - /*! - * @brief This function sets a value in member my_int32 - * @param _my_int32 New value for member my_int32 - */ - eProsima_user_DllExport void my_int32( - int32_t _my_int32); - - /*! - * @brief This function returns the value of member my_int32 - * @return Value of member my_int32 - */ - eProsima_user_DllExport int32_t my_int32() const; - - /*! - * @brief This function returns a reference to member my_int32 - * @return Reference to member my_int32 - */ - eProsima_user_DllExport int32_t& my_int32(); - - - /*! - * @brief This function copies the value in member my_string - * @param _my_string New value to be copied in member my_string - */ - eProsima_user_DllExport void my_string( - const std::string& _my_string); - - /*! - * @brief This function moves the value in member my_string - * @param _my_string New value to be moved in member my_string - */ - eProsima_user_DllExport void my_string( - std::string&& _my_string); - - /*! - * @brief This function returns a constant reference to member my_string - * @return Constant reference to member my_string - */ - eProsima_user_DllExport const std::string& my_string() const; - - /*! - * @brief This function returns a reference to member my_string - * @return Reference to member my_string - */ - eProsima_user_DllExport std::string& my_string(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const BadBasicWideStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - int32_t m_new_int32; - std::string m_new_string; - bool m_my_bool; - int32_t m_my_int32; - std::string m_my_string; - -}; - - - -/*! - * @brief This class represents the structure StringStruct defined by the user in the IDL file. - * @ingroup Types - */ -class StringStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport StringStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~StringStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object StringStruct that will be copied. - */ - eProsima_user_DllExport StringStruct( - const StringStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object StringStruct that will be copied. - */ - eProsima_user_DllExport StringStruct( - StringStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object StringStruct that will be copied. - */ - eProsima_user_DllExport StringStruct& operator =( - const StringStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object StringStruct that will be copied. - */ - eProsima_user_DllExport StringStruct& operator =( - StringStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x StringStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const StringStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x StringStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const StringStruct& x) const; - - /*! - * @brief This function copies the value in member my_string - * @param _my_string New value to be copied in member my_string - */ - eProsima_user_DllExport void my_string( - const std::string& _my_string); - - /*! - * @brief This function moves the value in member my_string - * @param _my_string New value to be moved in member my_string - */ - eProsima_user_DllExport void my_string( - std::string&& _my_string); - - /*! - * @brief This function returns a constant reference to member my_string - * @return Constant reference to member my_string - */ - eProsima_user_DllExport const std::string& my_string() const; - - /*! - * @brief This function returns a reference to member my_string - * @return Reference to member my_string - */ - eProsima_user_DllExport std::string& my_string(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const StringStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::string m_my_string; - -}; - - - -/*! - * @brief This class represents the structure LargeStringStruct defined by the user in the IDL file. - * @ingroup Types - */ -class LargeStringStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport LargeStringStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~LargeStringStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object LargeStringStruct that will be copied. - */ - eProsima_user_DllExport LargeStringStruct( - const LargeStringStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object LargeStringStruct that will be copied. - */ - eProsima_user_DllExport LargeStringStruct( - LargeStringStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object LargeStringStruct that will be copied. - */ - eProsima_user_DllExport LargeStringStruct& operator =( - const LargeStringStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object LargeStringStruct that will be copied. - */ - eProsima_user_DllExport LargeStringStruct& operator =( - LargeStringStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x LargeStringStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const LargeStringStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x LargeStringStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const LargeStringStruct& x) const; - - /*! - * @brief This function copies the value in member my_large_string - * @param _my_large_string New value to be copied in member my_large_string - */ - eProsima_user_DllExport void my_large_string( - const eprosima::fastrtps::fixed_string<41925>& _my_large_string); - - /*! - * @brief This function moves the value in member my_large_string - * @param _my_large_string New value to be moved in member my_large_string - */ - eProsima_user_DllExport void my_large_string( - eprosima::fastrtps::fixed_string<41925>&& _my_large_string); - - /*! - * @brief This function returns a constant reference to member my_large_string - * @return Constant reference to member my_large_string - */ - eProsima_user_DllExport const eprosima::fastrtps::fixed_string<41925>& my_large_string() const; - - /*! - * @brief This function returns a reference to member my_large_string - * @return Reference to member my_large_string - */ - eProsima_user_DllExport eprosima::fastrtps::fixed_string<41925>& my_large_string(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const LargeStringStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - eprosima::fastrtps::fixed_string<41925> m_my_large_string; - -}; - - - -/*! - * @brief This class represents the structure WStringStruct defined by the user in the IDL file. - * @ingroup Types - */ -class WStringStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport WStringStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~WStringStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object WStringStruct that will be copied. - */ - eProsima_user_DllExport WStringStruct( - const WStringStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object WStringStruct that will be copied. - */ - eProsima_user_DllExport WStringStruct( - WStringStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object WStringStruct that will be copied. - */ - eProsima_user_DllExport WStringStruct& operator =( - const WStringStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object WStringStruct that will be copied. - */ - eProsima_user_DllExport WStringStruct& operator =( - WStringStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x WStringStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const WStringStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x WStringStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const WStringStruct& x) const; - - /*! - * @brief This function copies the value in member my_wstring - * @param _my_wstring New value to be copied in member my_wstring - */ - eProsima_user_DllExport void my_wstring( - const std::wstring& _my_wstring); - - /*! - * @brief This function moves the value in member my_wstring - * @param _my_wstring New value to be moved in member my_wstring - */ - eProsima_user_DllExport void my_wstring( - std::wstring&& _my_wstring); - - /*! - * @brief This function returns a constant reference to member my_wstring - * @return Constant reference to member my_wstring - */ - eProsima_user_DllExport const std::wstring& my_wstring() const; - - /*! - * @brief This function returns a reference to member my_wstring - * @return Reference to member my_wstring - */ - eProsima_user_DllExport std::wstring& my_wstring(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const WStringStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::wstring m_my_wstring; - -}; - - - -/*! - * @brief This class represents the structure LargeWStringStruct defined by the user in the IDL file. - * @ingroup Types - */ -class LargeWStringStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport LargeWStringStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~LargeWStringStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object LargeWStringStruct that will be copied. - */ - eProsima_user_DllExport LargeWStringStruct( - const LargeWStringStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object LargeWStringStruct that will be copied. - */ - eProsima_user_DllExport LargeWStringStruct( - LargeWStringStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object LargeWStringStruct that will be copied. - */ - eProsima_user_DllExport LargeWStringStruct& operator =( - const LargeWStringStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object LargeWStringStruct that will be copied. - */ - eProsima_user_DllExport LargeWStringStruct& operator =( - LargeWStringStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x LargeWStringStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const LargeWStringStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x LargeWStringStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const LargeWStringStruct& x) const; - - /*! - * @brief This function copies the value in member my_large_wstring - * @param _my_large_wstring New value to be copied in member my_large_wstring - */ - eProsima_user_DllExport void my_large_wstring( - const std::wstring& _my_large_wstring); - - /*! - * @brief This function moves the value in member my_large_wstring - * @param _my_large_wstring New value to be moved in member my_large_wstring - */ - eProsima_user_DllExport void my_large_wstring( - std::wstring&& _my_large_wstring); - - /*! - * @brief This function returns a constant reference to member my_large_wstring - * @return Constant reference to member my_large_wstring - */ - eProsima_user_DllExport const std::wstring& my_large_wstring() const; - - /*! - * @brief This function returns a reference to member my_large_wstring - * @return Reference to member my_large_wstring - */ - eProsima_user_DllExport std::wstring& my_large_wstring(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const LargeWStringStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::wstring m_my_large_wstring; - -}; - - - -/*! - * @brief This class represents the structure ArrayStruct defined by the user in the IDL file. - * @ingroup Types - */ -class ArrayStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport ArrayStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~ArrayStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object ArrayStruct that will be copied. - */ - eProsima_user_DllExport ArrayStruct( - const ArrayStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object ArrayStruct that will be copied. - */ - eProsima_user_DllExport ArrayStruct( - ArrayStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object ArrayStruct that will be copied. - */ - eProsima_user_DllExport ArrayStruct& operator =( - const ArrayStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object ArrayStruct that will be copied. - */ - eProsima_user_DllExport ArrayStruct& operator =( - ArrayStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x ArrayStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const ArrayStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x ArrayStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const ArrayStruct& x) const; - - /*! - * @brief This function copies the value in member my_array - * @param _my_array New value to be copied in member my_array - */ - eProsima_user_DllExport void my_array( - const std::array& _my_array); - - /*! - * @brief This function moves the value in member my_array - * @param _my_array New value to be moved in member my_array - */ - eProsima_user_DllExport void my_array( - std::array&& _my_array); - - /*! - * @brief This function returns a constant reference to member my_array - * @return Constant reference to member my_array - */ - eProsima_user_DllExport const std::array& my_array() const; - - /*! - * @brief This function returns a reference to member my_array - * @return Reference to member my_array - */ - eProsima_user_DllExport std::array& my_array(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const ArrayStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::array m_my_array; - -}; - - - -/*! - * @brief This class represents the structure ArrayStructEqual defined by the user in the IDL file. - * @ingroup Types - */ -class ArrayStructEqual -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport ArrayStructEqual(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~ArrayStructEqual(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object ArrayStructEqual that will be copied. - */ - eProsima_user_DllExport ArrayStructEqual( - const ArrayStructEqual& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object ArrayStructEqual that will be copied. - */ - eProsima_user_DllExport ArrayStructEqual( - ArrayStructEqual&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object ArrayStructEqual that will be copied. - */ - eProsima_user_DllExport ArrayStructEqual& operator =( - const ArrayStructEqual& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object ArrayStructEqual that will be copied. - */ - eProsima_user_DllExport ArrayStructEqual& operator =( - ArrayStructEqual&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x ArrayStructEqual object to compare. - */ - eProsima_user_DllExport bool operator ==( - const ArrayStructEqual& x) const; - - /*! - * @brief Comparison operator. - * @param x ArrayStructEqual object to compare. - */ - eProsima_user_DllExport bool operator !=( - const ArrayStructEqual& x) const; - - /*! - * @brief This function copies the value in member my_array_equal - * @param _my_array_equal New value to be copied in member my_array_equal - */ - eProsima_user_DllExport void my_array_equal( - const std::array& _my_array_equal); - - /*! - * @brief This function moves the value in member my_array_equal - * @param _my_array_equal New value to be moved in member my_array_equal - */ - eProsima_user_DllExport void my_array_equal( - std::array&& _my_array_equal); - - /*! - * @brief This function returns a constant reference to member my_array_equal - * @return Constant reference to member my_array_equal - */ - eProsima_user_DllExport const std::array& my_array_equal() const; - - /*! - * @brief This function returns a reference to member my_array_equal - * @return Reference to member my_array_equal - */ - eProsima_user_DllExport std::array& my_array_equal(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const ArrayStructEqual& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::array m_my_array_equal; - -}; - - - -/*! - * @brief This class represents the structure ArrayBadStruct defined by the user in the IDL file. - * @ingroup Types - */ -class ArrayBadStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport ArrayBadStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~ArrayBadStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object ArrayBadStruct that will be copied. - */ - eProsima_user_DllExport ArrayBadStruct( - const ArrayBadStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object ArrayBadStruct that will be copied. - */ - eProsima_user_DllExport ArrayBadStruct( - ArrayBadStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object ArrayBadStruct that will be copied. - */ - eProsima_user_DllExport ArrayBadStruct& operator =( - const ArrayBadStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object ArrayBadStruct that will be copied. - */ - eProsima_user_DllExport ArrayBadStruct& operator =( - ArrayBadStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x ArrayBadStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const ArrayBadStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x ArrayBadStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const ArrayBadStruct& x) const; - - /*! - * @brief This function copies the value in member my_array - * @param _my_array New value to be copied in member my_array - */ - eProsima_user_DllExport void my_array( - const std::array& _my_array); - - /*! - * @brief This function moves the value in member my_array - * @param _my_array New value to be moved in member my_array - */ - eProsima_user_DllExport void my_array( - std::array&& _my_array); - - /*! - * @brief This function returns a constant reference to member my_array - * @return Constant reference to member my_array - */ - eProsima_user_DllExport const std::array& my_array() const; - - /*! - * @brief This function returns a reference to member my_array - * @return Reference to member my_array - */ - eProsima_user_DllExport std::array& my_array(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const ArrayBadStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::array m_my_array; - -}; - - - -/*! - * @brief This class represents the structure ArrayDimensionsStruct defined by the user in the IDL file. - * @ingroup Types - */ -class ArrayDimensionsStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport ArrayDimensionsStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~ArrayDimensionsStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object ArrayDimensionsStruct that will be copied. - */ - eProsima_user_DllExport ArrayDimensionsStruct( - const ArrayDimensionsStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object ArrayDimensionsStruct that will be copied. - */ - eProsima_user_DllExport ArrayDimensionsStruct( - ArrayDimensionsStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object ArrayDimensionsStruct that will be copied. - */ - eProsima_user_DllExport ArrayDimensionsStruct& operator =( - const ArrayDimensionsStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object ArrayDimensionsStruct that will be copied. - */ - eProsima_user_DllExport ArrayDimensionsStruct& operator =( - ArrayDimensionsStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x ArrayDimensionsStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const ArrayDimensionsStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x ArrayDimensionsStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const ArrayDimensionsStruct& x) const; - - /*! - * @brief This function copies the value in member my_array - * @param _my_array New value to be copied in member my_array - */ - eProsima_user_DllExport void my_array( - const std::array, 2>& _my_array); - - /*! - * @brief This function moves the value in member my_array - * @param _my_array New value to be moved in member my_array - */ - eProsima_user_DllExport void my_array( - std::array, 2>&& _my_array); - - /*! - * @brief This function returns a constant reference to member my_array - * @return Constant reference to member my_array - */ - eProsima_user_DllExport const std::array, 2>& my_array() const; - - /*! - * @brief This function returns a reference to member my_array - * @return Reference to member my_array - */ - eProsima_user_DllExport std::array, 2>& my_array(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const ArrayDimensionsStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::array, 2> m_my_array; - -}; - - - -/*! - * @brief This class represents the structure ArraySizeStruct defined by the user in the IDL file. - * @ingroup Types - */ -class ArraySizeStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport ArraySizeStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~ArraySizeStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object ArraySizeStruct that will be copied. - */ - eProsima_user_DllExport ArraySizeStruct( - const ArraySizeStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object ArraySizeStruct that will be copied. - */ - eProsima_user_DllExport ArraySizeStruct( - ArraySizeStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object ArraySizeStruct that will be copied. - */ - eProsima_user_DllExport ArraySizeStruct& operator =( - const ArraySizeStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object ArraySizeStruct that will be copied. - */ - eProsima_user_DllExport ArraySizeStruct& operator =( - ArraySizeStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x ArraySizeStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const ArraySizeStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x ArraySizeStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const ArraySizeStruct& x) const; - - /*! - * @brief This function copies the value in member my_array - * @param _my_array New value to be copied in member my_array - */ - eProsima_user_DllExport void my_array( - const std::array& _my_array); - - /*! - * @brief This function moves the value in member my_array - * @param _my_array New value to be moved in member my_array - */ - eProsima_user_DllExport void my_array( - std::array&& _my_array); - - /*! - * @brief This function returns a constant reference to member my_array - * @return Constant reference to member my_array - */ - eProsima_user_DllExport const std::array& my_array() const; - - /*! - * @brief This function returns a reference to member my_array - * @return Reference to member my_array - */ - eProsima_user_DllExport std::array& my_array(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const ArraySizeStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::array m_my_array; - -}; - - - - - -/*! - * @brief This class represents the structure SequenceStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SequenceStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SequenceStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SequenceStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SequenceStruct that will be copied. - */ - eProsima_user_DllExport SequenceStruct( - const SequenceStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SequenceStruct that will be copied. - */ - eProsima_user_DllExport SequenceStruct( - SequenceStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SequenceStruct that will be copied. - */ - eProsima_user_DllExport SequenceStruct& operator =( - const SequenceStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SequenceStruct that will be copied. - */ - eProsima_user_DllExport SequenceStruct& operator =( - SequenceStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SequenceStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SequenceStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x SequenceStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SequenceStruct& x) const; - - /*! - * @brief This function copies the value in member my_sequence - * @param _my_sequence New value to be copied in member my_sequence - */ - eProsima_user_DllExport void my_sequence( - const std::vector& _my_sequence); - - /*! - * @brief This function moves the value in member my_sequence - * @param _my_sequence New value to be moved in member my_sequence - */ - eProsima_user_DllExport void my_sequence( - std::vector&& _my_sequence); - - /*! - * @brief This function returns a constant reference to member my_sequence - * @return Constant reference to member my_sequence - */ - eProsima_user_DllExport const std::vector& my_sequence() const; - - /*! - * @brief This function returns a reference to member my_sequence - * @return Reference to member my_sequence - */ - eProsima_user_DllExport std::vector& my_sequence(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const SequenceStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::vector m_my_sequence; - -}; - - - - - -/*! - * @brief This class represents the structure SequenceStructEqual defined by the user in the IDL file. - * @ingroup Types - */ -class SequenceStructEqual -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SequenceStructEqual(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SequenceStructEqual(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SequenceStructEqual that will be copied. - */ - eProsima_user_DllExport SequenceStructEqual( - const SequenceStructEqual& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SequenceStructEqual that will be copied. - */ - eProsima_user_DllExport SequenceStructEqual( - SequenceStructEqual&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SequenceStructEqual that will be copied. - */ - eProsima_user_DllExport SequenceStructEqual& operator =( - const SequenceStructEqual& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SequenceStructEqual that will be copied. - */ - eProsima_user_DllExport SequenceStructEqual& operator =( - SequenceStructEqual&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SequenceStructEqual object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SequenceStructEqual& x) const; - - /*! - * @brief Comparison operator. - * @param x SequenceStructEqual object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SequenceStructEqual& x) const; - - /*! - * @brief This function copies the value in member my_sequence_equal - * @param _my_sequence_equal New value to be copied in member my_sequence_equal - */ - eProsima_user_DllExport void my_sequence_equal( - const std::vector& _my_sequence_equal); - - /*! - * @brief This function moves the value in member my_sequence_equal - * @param _my_sequence_equal New value to be moved in member my_sequence_equal - */ - eProsima_user_DllExport void my_sequence_equal( - std::vector&& _my_sequence_equal); - - /*! - * @brief This function returns a constant reference to member my_sequence_equal - * @return Constant reference to member my_sequence_equal - */ - eProsima_user_DllExport const std::vector& my_sequence_equal() const; - - /*! - * @brief This function returns a reference to member my_sequence_equal - * @return Reference to member my_sequence_equal - */ - eProsima_user_DllExport std::vector& my_sequence_equal(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const SequenceStructEqual& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::vector m_my_sequence_equal; - -}; - - - - - -/*! - * @brief This class represents the structure SequenceBadStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SequenceBadStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SequenceBadStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SequenceBadStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SequenceBadStruct that will be copied. - */ - eProsima_user_DllExport SequenceBadStruct( - const SequenceBadStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SequenceBadStruct that will be copied. - */ - eProsima_user_DllExport SequenceBadStruct( - SequenceBadStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SequenceBadStruct that will be copied. - */ - eProsima_user_DllExport SequenceBadStruct& operator =( - const SequenceBadStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SequenceBadStruct that will be copied. - */ - eProsima_user_DllExport SequenceBadStruct& operator =( - SequenceBadStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SequenceBadStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SequenceBadStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x SequenceBadStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SequenceBadStruct& x) const; - - /*! - * @brief This function copies the value in member my_sequence - * @param _my_sequence New value to be copied in member my_sequence - */ - eProsima_user_DllExport void my_sequence( - const std::vector& _my_sequence); - - /*! - * @brief This function moves the value in member my_sequence - * @param _my_sequence New value to be moved in member my_sequence - */ - eProsima_user_DllExport void my_sequence( - std::vector&& _my_sequence); - - /*! - * @brief This function returns a constant reference to member my_sequence - * @return Constant reference to member my_sequence - */ - eProsima_user_DllExport const std::vector& my_sequence() const; - - /*! - * @brief This function returns a reference to member my_sequence - * @return Reference to member my_sequence - */ - eProsima_user_DllExport std::vector& my_sequence(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const SequenceBadStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::vector m_my_sequence; - -}; - - - - - -/*! - * @brief This class represents the structure SequenceBoundsStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SequenceBoundsStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SequenceBoundsStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SequenceBoundsStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SequenceBoundsStruct that will be copied. - */ - eProsima_user_DllExport SequenceBoundsStruct( - const SequenceBoundsStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SequenceBoundsStruct that will be copied. - */ - eProsima_user_DllExport SequenceBoundsStruct( - SequenceBoundsStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SequenceBoundsStruct that will be copied. - */ - eProsima_user_DllExport SequenceBoundsStruct& operator =( - const SequenceBoundsStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SequenceBoundsStruct that will be copied. - */ - eProsima_user_DllExport SequenceBoundsStruct& operator =( - SequenceBoundsStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SequenceBoundsStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SequenceBoundsStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x SequenceBoundsStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SequenceBoundsStruct& x) const; - - /*! - * @brief This function copies the value in member my_sequence - * @param _my_sequence New value to be copied in member my_sequence - */ - eProsima_user_DllExport void my_sequence( - const std::vector& _my_sequence); - - /*! - * @brief This function moves the value in member my_sequence - * @param _my_sequence New value to be moved in member my_sequence - */ - eProsima_user_DllExport void my_sequence( - std::vector&& _my_sequence); - - /*! - * @brief This function returns a constant reference to member my_sequence - * @return Constant reference to member my_sequence - */ - eProsima_user_DllExport const std::vector& my_sequence() const; - - /*! - * @brief This function returns a reference to member my_sequence - * @return Reference to member my_sequence - */ - eProsima_user_DllExport std::vector& my_sequence(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const SequenceBoundsStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::vector m_my_sequence; - -}; - - - - - - - -/*! - * @brief This class represents the structure SequenceSequenceStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SequenceSequenceStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SequenceSequenceStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SequenceSequenceStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SequenceSequenceStruct that will be copied. - */ - eProsima_user_DllExport SequenceSequenceStruct( - const SequenceSequenceStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SequenceSequenceStruct that will be copied. - */ - eProsima_user_DllExport SequenceSequenceStruct( - SequenceSequenceStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SequenceSequenceStruct that will be copied. - */ - eProsima_user_DllExport SequenceSequenceStruct& operator =( - const SequenceSequenceStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SequenceSequenceStruct that will be copied. - */ - eProsima_user_DllExport SequenceSequenceStruct& operator =( - SequenceSequenceStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SequenceSequenceStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SequenceSequenceStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x SequenceSequenceStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SequenceSequenceStruct& x) const; - - /*! - * @brief This function copies the value in member my_sequence_sequence - * @param _my_sequence_sequence New value to be copied in member my_sequence_sequence - */ - eProsima_user_DllExport void my_sequence_sequence( - const std::vector>& _my_sequence_sequence); - - /*! - * @brief This function moves the value in member my_sequence_sequence - * @param _my_sequence_sequence New value to be moved in member my_sequence_sequence - */ - eProsima_user_DllExport void my_sequence_sequence( - std::vector>&& _my_sequence_sequence); - - /*! - * @brief This function returns a constant reference to member my_sequence_sequence - * @return Constant reference to member my_sequence_sequence - */ - eProsima_user_DllExport const std::vector>& my_sequence_sequence() const; - - /*! - * @brief This function returns a reference to member my_sequence_sequence - * @return Reference to member my_sequence_sequence - */ - eProsima_user_DllExport std::vector>& my_sequence_sequence(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const SequenceSequenceStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::vector> m_my_sequence_sequence; - -}; - - - - - - - -/*! - * @brief This class represents the structure SequenceSequenceBoundsStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SequenceSequenceBoundsStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SequenceSequenceBoundsStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SequenceSequenceBoundsStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SequenceSequenceBoundsStruct that will be copied. - */ - eProsima_user_DllExport SequenceSequenceBoundsStruct( - const SequenceSequenceBoundsStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SequenceSequenceBoundsStruct that will be copied. - */ - eProsima_user_DllExport SequenceSequenceBoundsStruct( - SequenceSequenceBoundsStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SequenceSequenceBoundsStruct that will be copied. - */ - eProsima_user_DllExport SequenceSequenceBoundsStruct& operator =( - const SequenceSequenceBoundsStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SequenceSequenceBoundsStruct that will be copied. - */ - eProsima_user_DllExport SequenceSequenceBoundsStruct& operator =( - SequenceSequenceBoundsStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SequenceSequenceBoundsStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SequenceSequenceBoundsStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x SequenceSequenceBoundsStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SequenceSequenceBoundsStruct& x) const; - - /*! - * @brief This function copies the value in member my_sequence_sequence - * @param _my_sequence_sequence New value to be copied in member my_sequence_sequence - */ - eProsima_user_DllExport void my_sequence_sequence( - const std::vector>& _my_sequence_sequence); - - /*! - * @brief This function moves the value in member my_sequence_sequence - * @param _my_sequence_sequence New value to be moved in member my_sequence_sequence - */ - eProsima_user_DllExport void my_sequence_sequence( - std::vector>&& _my_sequence_sequence); - - /*! - * @brief This function returns a constant reference to member my_sequence_sequence - * @return Constant reference to member my_sequence_sequence - */ - eProsima_user_DllExport const std::vector>& my_sequence_sequence() const; - - /*! - * @brief This function returns a reference to member my_sequence_sequence - * @return Reference to member my_sequence_sequence - */ - eProsima_user_DllExport std::vector>& my_sequence_sequence(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const SequenceSequenceBoundsStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::vector> m_my_sequence_sequence; - -}; - - - - - -/*! - * @brief This class represents the structure MapStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MapStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MapStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MapStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MapStruct that will be copied. - */ - eProsima_user_DllExport MapStruct( - const MapStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MapStruct that will be copied. - */ - eProsima_user_DllExport MapStruct( - MapStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MapStruct that will be copied. - */ - eProsima_user_DllExport MapStruct& operator =( - const MapStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MapStruct that will be copied. - */ - eProsima_user_DllExport MapStruct& operator =( - MapStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MapStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MapStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x MapStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MapStruct& x) const; - - /*! - * @brief This function copies the value in member my_map - * @param _my_map New value to be copied in member my_map - */ - eProsima_user_DllExport void my_map( - const std::map& _my_map); - - /*! - * @brief This function moves the value in member my_map - * @param _my_map New value to be moved in member my_map - */ - eProsima_user_DllExport void my_map( - std::map&& _my_map); - - /*! - * @brief This function returns a constant reference to member my_map - * @return Constant reference to member my_map - */ - eProsima_user_DllExport const std::map& my_map() const; - - /*! - * @brief This function returns a reference to member my_map - * @return Reference to member my_map - */ - eProsima_user_DllExport std::map& my_map(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const MapStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::map m_my_map; - -}; - - - - - -/*! - * @brief This class represents the structure MapStructEqual defined by the user in the IDL file. - * @ingroup Types - */ -class MapStructEqual -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MapStructEqual(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MapStructEqual(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MapStructEqual that will be copied. - */ - eProsima_user_DllExport MapStructEqual( - const MapStructEqual& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MapStructEqual that will be copied. - */ - eProsima_user_DllExport MapStructEqual( - MapStructEqual&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MapStructEqual that will be copied. - */ - eProsima_user_DllExport MapStructEqual& operator =( - const MapStructEqual& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MapStructEqual that will be copied. - */ - eProsima_user_DllExport MapStructEqual& operator =( - MapStructEqual&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MapStructEqual object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MapStructEqual& x) const; - - /*! - * @brief Comparison operator. - * @param x MapStructEqual object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MapStructEqual& x) const; - - /*! - * @brief This function copies the value in member my_map_equal - * @param _my_map_equal New value to be copied in member my_map_equal - */ - eProsima_user_DllExport void my_map_equal( - const std::map& _my_map_equal); - - /*! - * @brief This function moves the value in member my_map_equal - * @param _my_map_equal New value to be moved in member my_map_equal - */ - eProsima_user_DllExport void my_map_equal( - std::map&& _my_map_equal); - - /*! - * @brief This function returns a constant reference to member my_map_equal - * @return Constant reference to member my_map_equal - */ - eProsima_user_DllExport const std::map& my_map_equal() const; - - /*! - * @brief This function returns a reference to member my_map_equal - * @return Reference to member my_map_equal - */ - eProsima_user_DllExport std::map& my_map_equal(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const MapStructEqual& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::map m_my_map_equal; - -}; - - - - - -/*! - * @brief This class represents the structure MapBadKeyStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MapBadKeyStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MapBadKeyStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MapBadKeyStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MapBadKeyStruct that will be copied. - */ - eProsima_user_DllExport MapBadKeyStruct( - const MapBadKeyStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MapBadKeyStruct that will be copied. - */ - eProsima_user_DllExport MapBadKeyStruct( - MapBadKeyStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MapBadKeyStruct that will be copied. - */ - eProsima_user_DllExport MapBadKeyStruct& operator =( - const MapBadKeyStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MapBadKeyStruct that will be copied. - */ - eProsima_user_DllExport MapBadKeyStruct& operator =( - MapBadKeyStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MapBadKeyStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MapBadKeyStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x MapBadKeyStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MapBadKeyStruct& x) const; - - /*! - * @brief This function copies the value in member my_map - * @param _my_map New value to be copied in member my_map - */ - eProsima_user_DllExport void my_map( - const std::map& _my_map); - - /*! - * @brief This function moves the value in member my_map - * @param _my_map New value to be moved in member my_map - */ - eProsima_user_DllExport void my_map( - std::map&& _my_map); - - /*! - * @brief This function returns a constant reference to member my_map - * @return Constant reference to member my_map - */ - eProsima_user_DllExport const std::map& my_map() const; - - /*! - * @brief This function returns a reference to member my_map - * @return Reference to member my_map - */ - eProsima_user_DllExport std::map& my_map(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const MapBadKeyStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::map m_my_map; - -}; - - - - - -/*! - * @brief This class represents the structure MapBadElemStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MapBadElemStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MapBadElemStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MapBadElemStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MapBadElemStruct that will be copied. - */ - eProsima_user_DllExport MapBadElemStruct( - const MapBadElemStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MapBadElemStruct that will be copied. - */ - eProsima_user_DllExport MapBadElemStruct( - MapBadElemStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MapBadElemStruct that will be copied. - */ - eProsima_user_DllExport MapBadElemStruct& operator =( - const MapBadElemStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MapBadElemStruct that will be copied. - */ - eProsima_user_DllExport MapBadElemStruct& operator =( - MapBadElemStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MapBadElemStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MapBadElemStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x MapBadElemStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MapBadElemStruct& x) const; - - /*! - * @brief This function copies the value in member my_map - * @param _my_map New value to be copied in member my_map - */ - eProsima_user_DllExport void my_map( - const std::map& _my_map); - - /*! - * @brief This function moves the value in member my_map - * @param _my_map New value to be moved in member my_map - */ - eProsima_user_DllExport void my_map( - std::map&& _my_map); - - /*! - * @brief This function returns a constant reference to member my_map - * @return Constant reference to member my_map - */ - eProsima_user_DllExport const std::map& my_map() const; - - /*! - * @brief This function returns a reference to member my_map - * @return Reference to member my_map - */ - eProsima_user_DllExport std::map& my_map(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const MapBadElemStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::map m_my_map; - -}; - - - - - -/*! - * @brief This class represents the structure MapBoundsStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MapBoundsStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MapBoundsStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MapBoundsStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MapBoundsStruct that will be copied. - */ - eProsima_user_DllExport MapBoundsStruct( - const MapBoundsStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MapBoundsStruct that will be copied. - */ - eProsima_user_DllExport MapBoundsStruct( - MapBoundsStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MapBoundsStruct that will be copied. - */ - eProsima_user_DllExport MapBoundsStruct& operator =( - const MapBoundsStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MapBoundsStruct that will be copied. - */ - eProsima_user_DllExport MapBoundsStruct& operator =( - MapBoundsStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MapBoundsStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MapBoundsStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x MapBoundsStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MapBoundsStruct& x) const; - - /*! - * @brief This function copies the value in member my_map - * @param _my_map New value to be copied in member my_map - */ - eProsima_user_DllExport void my_map( - const std::map& _my_map); - - /*! - * @brief This function moves the value in member my_map - * @param _my_map New value to be moved in member my_map - */ - eProsima_user_DllExport void my_map( - std::map&& _my_map); - - /*! - * @brief This function returns a constant reference to member my_map - * @return Constant reference to member my_map - */ - eProsima_user_DllExport const std::map& my_map() const; - - /*! - * @brief This function returns a reference to member my_map - * @return Reference to member my_map - */ - eProsima_user_DllExport std::map& my_map(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const MapBoundsStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::map m_my_map; - -}; - - - - - - - -/*! - * @brief This class represents the structure MapMapStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MapMapStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MapMapStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MapMapStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MapMapStruct that will be copied. - */ - eProsima_user_DllExport MapMapStruct( - const MapMapStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MapMapStruct that will be copied. - */ - eProsima_user_DllExport MapMapStruct( - MapMapStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MapMapStruct that will be copied. - */ - eProsima_user_DllExport MapMapStruct& operator =( - const MapMapStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MapMapStruct that will be copied. - */ - eProsima_user_DllExport MapMapStruct& operator =( - MapMapStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MapMapStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MapMapStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x MapMapStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MapMapStruct& x) const; - - /*! - * @brief This function copies the value in member my_map_map - * @param _my_map_map New value to be copied in member my_map_map - */ - eProsima_user_DllExport void my_map_map( - const std::map>& _my_map_map); - - /*! - * @brief This function moves the value in member my_map_map - * @param _my_map_map New value to be moved in member my_map_map - */ - eProsima_user_DllExport void my_map_map( - std::map>&& _my_map_map); - - /*! - * @brief This function returns a constant reference to member my_map_map - * @return Constant reference to member my_map_map - */ - eProsima_user_DllExport const std::map>& my_map_map() const; - - /*! - * @brief This function returns a reference to member my_map_map - * @return Reference to member my_map_map - */ - eProsima_user_DllExport std::map>& my_map_map(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const MapMapStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::map> m_my_map_map; - -}; - - - - - - - -/*! - * @brief This class represents the structure MapMapBoundsStruct defined by the user in the IDL file. - * @ingroup Types - */ -class MapMapBoundsStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport MapMapBoundsStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~MapMapBoundsStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object MapMapBoundsStruct that will be copied. - */ - eProsima_user_DllExport MapMapBoundsStruct( - const MapMapBoundsStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object MapMapBoundsStruct that will be copied. - */ - eProsima_user_DllExport MapMapBoundsStruct( - MapMapBoundsStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object MapMapBoundsStruct that will be copied. - */ - eProsima_user_DllExport MapMapBoundsStruct& operator =( - const MapMapBoundsStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object MapMapBoundsStruct that will be copied. - */ - eProsima_user_DllExport MapMapBoundsStruct& operator =( - MapMapBoundsStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x MapMapBoundsStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const MapMapBoundsStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x MapMapBoundsStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const MapMapBoundsStruct& x) const; - - /*! - * @brief This function copies the value in member my_map_map - * @param _my_map_map New value to be copied in member my_map_map - */ - eProsima_user_DllExport void my_map_map( - const std::map>& _my_map_map); - - /*! - * @brief This function moves the value in member my_map_map - * @param _my_map_map New value to be moved in member my_map_map - */ - eProsima_user_DllExport void my_map_map( - std::map>&& _my_map_map); - - /*! - * @brief This function returns a constant reference to member my_map_map - * @return Constant reference to member my_map_map - */ - eProsima_user_DllExport const std::map>& my_map_map() const; - - /*! - * @brief This function returns a reference to member my_map_map - * @return Reference to member my_map_map - */ - eProsima_user_DllExport std::map>& my_map_map(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const MapMapBoundsStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - std::map> m_my_map_map; - -}; - - - -/*! - * @brief This class represents the union SimpleUnion defined by the user in the IDL file. - * @ingroup Types - */ -class SimpleUnion -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimpleUnion(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimpleUnion(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimpleUnion that will be copied. - */ - eProsima_user_DllExport SimpleUnion( - const SimpleUnion& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimpleUnion that will be copied. - */ - eProsima_user_DllExport SimpleUnion( - SimpleUnion&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimpleUnion that will be copied. - */ - eProsima_user_DllExport SimpleUnion& operator =( - const SimpleUnion& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimpleUnion that will be copied. - */ - eProsima_user_DllExport SimpleUnion& operator =( - SimpleUnion&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimpleUnion object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimpleUnion& x) const; - - /*! - * @brief Comparison operator. - * @param x SimpleUnion object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimpleUnion& x) const; - - /*! - * @brief This function sets the discriminator value. - * @param __d New value for the discriminator. - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the new value doesn't correspond to the selected union member. - */ - eProsima_user_DllExport void _d( - int32_t __d); - - /*! - * @brief This function returns the value of the discriminator. - * @return Value of the discriminator - */ - eProsima_user_DllExport int32_t _d() const; - - /*! - * @brief This function returns a reference to the discriminator. - * @return Reference to the discriminator. - */ - eProsima_user_DllExport int32_t& _d(); - - /*! - * @brief This function sets a value in member first - * @param _first New value for member first - */ - eProsima_user_DllExport void first( - int32_t _first); - - /*! - * @brief This function returns the value of member first - * @return Value of member first - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t first() const; - - /*! - * @brief This function returns a reference to member first - * @return Reference to member first - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t& first(); - - - /*! - * @brief This function sets a value in member second - * @param _second New value for member second - */ - eProsima_user_DllExport void second( - int64_t _second); - - /*! - * @brief This function returns the value of member second - * @return Value of member second - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t second() const; - - /*! - * @brief This function returns a reference to member second - * @return Reference to member second - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t& second(); - - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const SimpleUnion& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - -private: - - int32_t m__d; - - int32_t m_first; - int64_t m_second; -}; - - - -/*! - * @brief This class represents the union SimpleUnionNames defined by the user in the IDL file. - * @ingroup Types - */ -class SimpleUnionNames -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimpleUnionNames(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimpleUnionNames(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimpleUnionNames that will be copied. - */ - eProsima_user_DllExport SimpleUnionNames( - const SimpleUnionNames& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimpleUnionNames that will be copied. - */ - eProsima_user_DllExport SimpleUnionNames( - SimpleUnionNames&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimpleUnionNames that will be copied. - */ - eProsima_user_DllExport SimpleUnionNames& operator =( - const SimpleUnionNames& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimpleUnionNames that will be copied. - */ - eProsima_user_DllExport SimpleUnionNames& operator =( - SimpleUnionNames&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimpleUnionNames object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimpleUnionNames& x) const; - - /*! - * @brief Comparison operator. - * @param x SimpleUnionNames object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimpleUnionNames& x) const; - - /*! - * @brief This function sets the discriminator value. - * @param __d New value for the discriminator. - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the new value doesn't correspond to the selected union member. - */ - eProsima_user_DllExport void _d( - int32_t __d); - - /*! - * @brief This function returns the value of the discriminator. - * @return Value of the discriminator - */ - eProsima_user_DllExport int32_t _d() const; - - /*! - * @brief This function returns a reference to the discriminator. - * @return Reference to the discriminator. - */ - eProsima_user_DllExport int32_t& _d(); - - /*! - * @brief This function sets a value in member first_case - * @param _first_case New value for member first_case - */ - eProsima_user_DllExport void first_case( - int32_t _first_case); - - /*! - * @brief This function returns the value of member first_case - * @return Value of member first_case - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t first_case() const; - - /*! - * @brief This function returns a reference to member first_case - * @return Reference to member first_case - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t& first_case(); - - - /*! - * @brief This function sets a value in member second_case - * @param _second_case New value for member second_case - */ - eProsima_user_DllExport void second_case( - int64_t _second_case); - - /*! - * @brief This function returns the value of member second_case - * @return Value of member second_case - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t second_case() const; - - /*! - * @brief This function returns a reference to member second_case - * @return Reference to member second_case - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t& second_case(); - - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const SimpleUnionNames& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - -private: - - int32_t m__d; - - int32_t m_first_case; - int64_t m_second_case; -}; - - - -/*! - * @brief This class represents the union SimpleTypeUnion defined by the user in the IDL file. - * @ingroup Types - */ -class SimpleTypeUnion -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimpleTypeUnion(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimpleTypeUnion(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimpleTypeUnion that will be copied. - */ - eProsima_user_DllExport SimpleTypeUnion( - const SimpleTypeUnion& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimpleTypeUnion that will be copied. - */ - eProsima_user_DllExport SimpleTypeUnion( - SimpleTypeUnion&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimpleTypeUnion that will be copied. - */ - eProsima_user_DllExport SimpleTypeUnion& operator =( - const SimpleTypeUnion& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimpleTypeUnion that will be copied. - */ - eProsima_user_DllExport SimpleTypeUnion& operator =( - SimpleTypeUnion&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimpleTypeUnion object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimpleTypeUnion& x) const; - - /*! - * @brief Comparison operator. - * @param x SimpleTypeUnion object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimpleTypeUnion& x) const; - - /*! - * @brief This function sets the discriminator value. - * @param __d New value for the discriminator. - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the new value doesn't correspond to the selected union member. - */ - eProsima_user_DllExport void _d( - int32_t __d); - - /*! - * @brief This function returns the value of the discriminator. - * @return Value of the discriminator - */ - eProsima_user_DllExport int32_t _d() const; - - /*! - * @brief This function returns a reference to the discriminator. - * @return Reference to the discriminator. - */ - eProsima_user_DllExport int32_t& _d(); - - /*! - * @brief This function sets a value in member first - * @param _first New value for member first - */ - eProsima_user_DllExport void first( - uint8_t _first); - - /*! - * @brief This function returns the value of member first - * @return Value of member first - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport uint8_t first() const; - - /*! - * @brief This function returns a reference to member first - * @return Reference to member first - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport uint8_t& first(); - - - /*! - * @brief This function sets a value in member second - * @param _second New value for member second - */ - eProsima_user_DllExport void second( - int64_t _second); - - /*! - * @brief This function returns the value of member second - * @return Value of member second - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t second() const; - - /*! - * @brief This function returns a reference to member second - * @return Reference to member second - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t& second(); - - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const SimpleTypeUnion& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - -private: - - int32_t m__d; - - uint8_t m_first; - int64_t m_second; -}; - - - -/*! - * @brief This class represents the union SimpleBadUnion defined by the user in the IDL file. - * @ingroup Types - */ -class SimpleBadUnion -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimpleBadUnion(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimpleBadUnion(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimpleBadUnion that will be copied. - */ - eProsima_user_DllExport SimpleBadUnion( - const SimpleBadUnion& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimpleBadUnion that will be copied. - */ - eProsima_user_DllExport SimpleBadUnion( - SimpleBadUnion&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimpleBadUnion that will be copied. - */ - eProsima_user_DllExport SimpleBadUnion& operator =( - const SimpleBadUnion& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimpleBadUnion that will be copied. - */ - eProsima_user_DllExport SimpleBadUnion& operator =( - SimpleBadUnion&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimpleBadUnion object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimpleBadUnion& x) const; - - /*! - * @brief Comparison operator. - * @param x SimpleBadUnion object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimpleBadUnion& x) const; - - /*! - * @brief This function sets the discriminator value. - * @param __d New value for the discriminator. - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the new value doesn't correspond to the selected union member. - */ - eProsima_user_DllExport void _d( - int32_t __d); - - /*! - * @brief This function returns the value of the discriminator. - * @return Value of the discriminator - */ - eProsima_user_DllExport int32_t _d() const; - - /*! - * @brief This function returns a reference to the discriminator. - * @return Reference to the discriminator. - */ - eProsima_user_DllExport int32_t& _d(); - - /*! - * @brief This function sets a value in member first - * @param _first New value for member first - */ - eProsima_user_DllExport void first( - int32_t _first); - - /*! - * @brief This function returns the value of member first - * @return Value of member first - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t first() const; - - /*! - * @brief This function returns a reference to member first - * @return Reference to member first - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t& first(); - - - /*! - * @brief This function sets a value in member second - * @param _second New value for member second - */ - eProsima_user_DllExport void second( - int64_t _second); - - /*! - * @brief This function returns the value of member second - * @return Value of member second - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t second() const; - - /*! - * @brief This function returns a reference to member second - * @return Reference to member second - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t& second(); - - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const SimpleBadUnion& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - -private: - - int32_t m__d; - - int32_t m_first; - int64_t m_second; -}; - - - -/*! - * @brief This class represents the union SimpleBadDiscUnion defined by the user in the IDL file. - * @ingroup Types - */ -class SimpleBadDiscUnion -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimpleBadDiscUnion(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimpleBadDiscUnion(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimpleBadDiscUnion that will be copied. - */ - eProsima_user_DllExport SimpleBadDiscUnion( - const SimpleBadDiscUnion& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimpleBadDiscUnion that will be copied. - */ - eProsima_user_DllExport SimpleBadDiscUnion( - SimpleBadDiscUnion&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimpleBadDiscUnion that will be copied. - */ - eProsima_user_DllExport SimpleBadDiscUnion& operator =( - const SimpleBadDiscUnion& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimpleBadDiscUnion that will be copied. - */ - eProsima_user_DllExport SimpleBadDiscUnion& operator =( - SimpleBadDiscUnion&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimpleBadDiscUnion object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimpleBadDiscUnion& x) const; - - /*! - * @brief Comparison operator. - * @param x SimpleBadDiscUnion object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimpleBadDiscUnion& x) const; - - /*! - * @brief This function sets the discriminator value. - * @param __d New value for the discriminator. - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the new value doesn't correspond to the selected union member. - */ - eProsima_user_DllExport void _d( - uint8_t __d); - - /*! - * @brief This function returns the value of the discriminator. - * @return Value of the discriminator - */ - eProsima_user_DllExport uint8_t _d() const; - - /*! - * @brief This function returns a reference to the discriminator. - * @return Reference to the discriminator. - */ - eProsima_user_DllExport uint8_t& _d(); - - /*! - * @brief This function sets a value in member first - * @param _first New value for member first - */ - eProsima_user_DllExport void first( - int32_t _first); - - /*! - * @brief This function returns the value of member first - * @return Value of member first - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t first() const; - - /*! - * @brief This function returns a reference to member first - * @return Reference to member first - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int32_t& first(); - - - /*! - * @brief This function sets a value in member second - * @param _second New value for member second - */ - eProsima_user_DllExport void second( - int64_t _second); - - /*! - * @brief This function returns the value of member second - * @return Value of member second - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t second() const; - - /*! - * @brief This function returns a reference to member second - * @return Reference to member second - * @exception eprosima::fastcdr::BadParamException This exception is thrown if the requested union member is not the current selection. - */ - eProsima_user_DllExport int64_t& second(); - - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const SimpleBadDiscUnion& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - -private: - - uint8_t m__d; - - int32_t m_first; - int64_t m_second; -}; - - - -/*! - * @brief This class represents the structure SimpleUnionStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SimpleUnionStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimpleUnionStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimpleUnionStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimpleUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleUnionStruct( - const SimpleUnionStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimpleUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleUnionStruct( - SimpleUnionStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimpleUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleUnionStruct& operator =( - const SimpleUnionStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimpleUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleUnionStruct& operator =( - SimpleUnionStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimpleUnionStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimpleUnionStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x SimpleUnionStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimpleUnionStruct& x) const; - - /*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ - eProsima_user_DllExport void my_union( - const SimpleUnion& _my_union); - - /*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ - eProsima_user_DllExport void my_union( - SimpleUnion&& _my_union); - - /*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ - eProsima_user_DllExport const SimpleUnion& my_union() const; - - /*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ - eProsima_user_DllExport SimpleUnion& my_union(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const SimpleUnionStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - SimpleUnion m_my_union; - -}; - - - -/*! - * @brief This class represents the structure SimpleUnionStructEqual defined by the user in the IDL file. - * @ingroup Types - */ -class SimpleUnionStructEqual -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimpleUnionStructEqual(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimpleUnionStructEqual(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimpleUnionStructEqual that will be copied. - */ - eProsima_user_DllExport SimpleUnionStructEqual( - const SimpleUnionStructEqual& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimpleUnionStructEqual that will be copied. - */ - eProsima_user_DllExport SimpleUnionStructEqual( - SimpleUnionStructEqual&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimpleUnionStructEqual that will be copied. - */ - eProsima_user_DllExport SimpleUnionStructEqual& operator =( - const SimpleUnionStructEqual& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimpleUnionStructEqual that will be copied. - */ - eProsima_user_DllExport SimpleUnionStructEqual& operator =( - SimpleUnionStructEqual&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimpleUnionStructEqual object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimpleUnionStructEqual& x) const; - - /*! - * @brief Comparison operator. - * @param x SimpleUnionStructEqual object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimpleUnionStructEqual& x) const; - - /*! - * @brief This function copies the value in member my_union_equal - * @param _my_union_equal New value to be copied in member my_union_equal - */ - eProsima_user_DllExport void my_union_equal( - const SimpleUnion& _my_union_equal); - - /*! - * @brief This function moves the value in member my_union_equal - * @param _my_union_equal New value to be moved in member my_union_equal - */ - eProsima_user_DllExport void my_union_equal( - SimpleUnion&& _my_union_equal); - - /*! - * @brief This function returns a constant reference to member my_union_equal - * @return Constant reference to member my_union_equal - */ - eProsima_user_DllExport const SimpleUnion& my_union_equal() const; - - /*! - * @brief This function returns a reference to member my_union_equal - * @return Reference to member my_union_equal - */ - eProsima_user_DllExport SimpleUnion& my_union_equal(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const SimpleUnionStructEqual& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - SimpleUnion m_my_union_equal; - -}; - - - -/*! - * @brief This class represents the structure SimpleUnionNamesStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SimpleUnionNamesStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimpleUnionNamesStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimpleUnionNamesStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimpleUnionNamesStruct that will be copied. - */ - eProsima_user_DllExport SimpleUnionNamesStruct( - const SimpleUnionNamesStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimpleUnionNamesStruct that will be copied. - */ - eProsima_user_DllExport SimpleUnionNamesStruct( - SimpleUnionNamesStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimpleUnionNamesStruct that will be copied. - */ - eProsima_user_DllExport SimpleUnionNamesStruct& operator =( - const SimpleUnionNamesStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimpleUnionNamesStruct that will be copied. - */ - eProsima_user_DllExport SimpleUnionNamesStruct& operator =( - SimpleUnionNamesStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimpleUnionNamesStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimpleUnionNamesStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x SimpleUnionNamesStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimpleUnionNamesStruct& x) const; - - /*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ - eProsima_user_DllExport void my_union( - const SimpleUnionNames& _my_union); - - /*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ - eProsima_user_DllExport void my_union( - SimpleUnionNames&& _my_union); - - /*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ - eProsima_user_DllExport const SimpleUnionNames& my_union() const; - - /*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ - eProsima_user_DllExport SimpleUnionNames& my_union(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const SimpleUnionNamesStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - SimpleUnionNames m_my_union; - -}; - - - -/*! - * @brief This class represents the structure SimpleTypeUnionStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SimpleTypeUnionStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimpleTypeUnionStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimpleTypeUnionStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimpleTypeUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleTypeUnionStruct( - const SimpleTypeUnionStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimpleTypeUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleTypeUnionStruct( - SimpleTypeUnionStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimpleTypeUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleTypeUnionStruct& operator =( - const SimpleTypeUnionStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimpleTypeUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleTypeUnionStruct& operator =( - SimpleTypeUnionStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimpleTypeUnionStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimpleTypeUnionStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x SimpleTypeUnionStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimpleTypeUnionStruct& x) const; - - /*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ - eProsima_user_DllExport void my_union( - const SimpleTypeUnion& _my_union); - - /*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ - eProsima_user_DllExport void my_union( - SimpleTypeUnion&& _my_union); - - /*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ - eProsima_user_DllExport const SimpleTypeUnion& my_union() const; - - /*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ - eProsima_user_DllExport SimpleTypeUnion& my_union(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const SimpleTypeUnionStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - SimpleTypeUnion m_my_union; - -}; - - - -/*! - * @brief This class represents the structure SimpleBadUnionStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SimpleBadUnionStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimpleBadUnionStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimpleBadUnionStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimpleBadUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleBadUnionStruct( - const SimpleBadUnionStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimpleBadUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleBadUnionStruct( - SimpleBadUnionStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimpleBadUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleBadUnionStruct& operator =( - const SimpleBadUnionStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimpleBadUnionStruct that will be copied. - */ - eProsima_user_DllExport SimpleBadUnionStruct& operator =( - SimpleBadUnionStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimpleBadUnionStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimpleBadUnionStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x SimpleBadUnionStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimpleBadUnionStruct& x) const; - - /*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ - eProsima_user_DllExport void my_union( - const SimpleBadUnion& _my_union); - - /*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ - eProsima_user_DllExport void my_union( - SimpleBadUnion&& _my_union); - - /*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ - eProsima_user_DllExport const SimpleBadUnion& my_union() const; - - /*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ - eProsima_user_DllExport SimpleBadUnion& my_union(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const SimpleBadUnionStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - SimpleBadUnion m_my_union; - -}; - - - -/*! - * @brief This class represents the structure SimplBadDiscUnionStruct defined by the user in the IDL file. - * @ingroup Types - */ -class SimplBadDiscUnionStruct -{ -public: - - /*! - * @brief Default constructor. - */ - eProsima_user_DllExport SimplBadDiscUnionStruct(); - - /*! - * @brief Default destructor. - */ - eProsima_user_DllExport ~SimplBadDiscUnionStruct(); - - /*! - * @brief Copy constructor. - * @param x Reference to the object SimplBadDiscUnionStruct that will be copied. - */ - eProsima_user_DllExport SimplBadDiscUnionStruct( - const SimplBadDiscUnionStruct& x); - - /*! - * @brief Move constructor. - * @param x Reference to the object SimplBadDiscUnionStruct that will be copied. - */ - eProsima_user_DllExport SimplBadDiscUnionStruct( - SimplBadDiscUnionStruct&& x) noexcept; - - /*! - * @brief Copy assignment. - * @param x Reference to the object SimplBadDiscUnionStruct that will be copied. - */ - eProsima_user_DllExport SimplBadDiscUnionStruct& operator =( - const SimplBadDiscUnionStruct& x); - - /*! - * @brief Move assignment. - * @param x Reference to the object SimplBadDiscUnionStruct that will be copied. - */ - eProsima_user_DllExport SimplBadDiscUnionStruct& operator =( - SimplBadDiscUnionStruct&& x) noexcept; - - /*! - * @brief Comparison operator. - * @param x SimplBadDiscUnionStruct object to compare. - */ - eProsima_user_DllExport bool operator ==( - const SimplBadDiscUnionStruct& x) const; - - /*! - * @brief Comparison operator. - * @param x SimplBadDiscUnionStruct object to compare. - */ - eProsima_user_DllExport bool operator !=( - const SimplBadDiscUnionStruct& x) const; - - /*! - * @brief This function copies the value in member my_union - * @param _my_union New value to be copied in member my_union - */ - eProsima_user_DllExport void my_union( - const SimpleBadDiscUnion& _my_union); - - /*! - * @brief This function moves the value in member my_union - * @param _my_union New value to be moved in member my_union - */ - eProsima_user_DllExport void my_union( - SimpleBadDiscUnion&& _my_union); - - /*! - * @brief This function returns a constant reference to member my_union - * @return Constant reference to member my_union - */ - eProsima_user_DllExport const SimpleBadDiscUnion& my_union() const; - - /*! - * @brief This function returns a reference to member my_union - * @return Reference to member my_union - */ - eProsima_user_DllExport SimpleBadDiscUnion& my_union(); - - - /*! - * @brief This function returns the maximum serialized size of an object - * depending on the buffer alignment. - * @param current_alignment Buffer alignment. - * @return Maximum serialized size. - */ - eProsima_user_DllExport static size_t getMaxCdrSerializedSize( - size_t current_alignment = 0); - - /*! - * @brief This function returns the serialized size of a data depending on the buffer alignment. - * @param data Data which is calculated its serialized size. - * @param current_alignment Buffer alignment. - * @return Serialized size. - */ - eProsima_user_DllExport static size_t getCdrSerializedSize( - const SimplBadDiscUnionStruct& data, - size_t current_alignment = 0); - - - - /*! - * @brief This function serializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serialize( - eprosima::fastcdr::Cdr& cdr) const; - - /*! - * @brief This function deserializes an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void deserialize( - eprosima::fastcdr::Cdr& cdr); - - - - - /*! - * @brief This function tells you if the Key has been defined for this type - */ - eProsima_user_DllExport static bool isKeyDefined(); - - /*! - * @brief This function serializes the key members of an object using CDR serialization. - * @param cdr CDR serialization object. - */ - eProsima_user_DllExport void serializeKey( - eprosima::fastcdr::Cdr& cdr) const; - - -private: - - SimpleBadDiscUnion m_my_union; - -}; - - -#endif // _FAST_DDS_GENERATED_TYPES_H_ - - - -#endif // FASTCDR_VERSION_MAJOR == 1 diff --git a/thirdparty/boost/include/boostconfig.hpp b/thirdparty/boost/include/boostconfig.hpp index 7cd06c68b1f..e2594b80eb3 100644 --- a/thirdparty/boost/include/boostconfig.hpp +++ b/thirdparty/boost/include/boostconfig.hpp @@ -42,7 +42,7 @@ #include // TODO(Adolfo): This will fail if windows system without program data in C: drive -#define BOOST_INTERPROCESS_SHARED_DIR_PATH "C:\\ProgramData\\eprosima\\fastrtps_interprocess" +#define BOOST_INTERPROCESS_SHARED_DIR_PATH "C:\\ProgramData\\eprosima\\fastdds_interprocess" // Check that generic emulation has not been accidentally enabled #include diff --git a/tools/CMakeLists.txt b/tools/CMakeLists.txt index 065857df1b4..fe0c55218de 100644 --- a/tools/CMakeLists.txt +++ b/tools/CMakeLists.txt @@ -12,7 +12,7 @@ # See the License for the specific language governing permissions and # limitations under the License. -set(fastrtps_FOUND TRUE) +set(fastdds_FOUND TRUE) cmake_policy(PUSH) add_subdirectory(fds) diff --git a/tools/fastdds/fastdds.py b/tools/fastdds/fastdds.py index 15cdad83790..c5b632d765a 100755 --- a/tools/fastdds/fastdds.py +++ b/tools/fastdds/fastdds.py @@ -17,7 +17,7 @@ """ fastdds CLI tool. -This CLI tool provide a set commands and sub-commands to perform, Fast-DDS +This CLI tool provide a set commands and sub-commands to perform, Fast DDS related, maintenance / configuration tasks. usage: fastdds [] diff --git a/tools/fastdds/shm/clean.py b/tools/fastdds/shm/clean.py index d0196176dba..03dc71464fb 100644 --- a/tools/fastdds/shm/clean.py +++ b/tools/fastdds/shm/clean.py @@ -63,7 +63,7 @@ def __shm_dir(self): # Windows if os.name == 'nt': shm_path = Path('c:\\programdata\\eprosima\\' - 'fastrtps_interprocess\\').resolve() + 'fastdds_interprocess\\').resolve() elif os.name == 'posix': # MAC if platform.mac_ver()[0] != '': @@ -91,7 +91,7 @@ def __clean_zombie_segments(self): The deleted file names """ - segment_lock_re = re.compile('^fastrtps_(\\d|[a-z]){16}(_el|_sl)') + segment_lock_re = re.compile('^fastdds_(\\d|[a-z]){16}(_el|_sl)') # Each segment has an "_el" lock file that is locked if the segment # is open and the owner process is alive @@ -123,7 +123,7 @@ def __clean_zombie_ports(self): the deleted file names """ - port_lock_re = re.compile('^fastrtps_port\\d{,5}(_el|_sl)') + port_lock_re = re.compile('^fastdds_port\\d{,5}(_el|_sl)') # Each port has an "_el | _sl" lock file that is locked if the port # is open and the owner process is alive port_locks = [ diff --git a/tools/fastdds/shm/parser.py b/tools/fastdds/shm/parser.py index 64f8f9e171d..86e91fb2e69 100644 --- a/tools/fastdds/shm/parser.py +++ b/tools/fastdds/shm/parser.py @@ -15,7 +15,7 @@ """ fastdds shm sub-command. -This verb provides maintenance tasks related with Fast-DDS shared-memory +This verb provides maintenance tasks related with Fast DDS shared-memory transport. usage: fastdds shm [] diff --git a/tools/fastdds/xml_ci/parser.py b/tools/fastdds/xml_ci/parser.py index e638256439c..f295073e761 100644 --- a/tools/fastdds/xml_ci/parser.py +++ b/tools/fastdds/xml_ci/parser.py @@ -108,4 +108,4 @@ def xsd_dir(self): """ tool_path = Path(os.path.dirname(os.path.realpath(__file__))) # We assume the schema path is relative to our installation path - return tool_path / '../../../share/fastRTPS_profiles.xsd' + return tool_path / '../../../share/fastdds_profiles.xsd' diff --git a/tools/fds/CMakeLists.txt b/tools/fds/CMakeLists.txt index 6d523d7628a..8e6008952a8 100644 --- a/tools/fds/CMakeLists.txt +++ b/tools/fds/CMakeLists.txt @@ -20,8 +20,8 @@ project(fast-discovery-server VERSION 1.0.1 LANGUAGES CXX) # Load external dependencies ############################################################################### -if(NOT fastrtps_FOUND) - find_package(fastrtps 2.12 REQUIRED) +if(NOT fastdds_FOUND) + find_package(fastdds 3 REQUIRED) endif() ############################################################################### @@ -34,7 +34,7 @@ if (MSVC) if (CMAKE_PROJECT_NAME STREQUAL PROJECT_NAME) # add fast headers to enable class view on visual studio IDE - get_target_property(FAST_INCLUDE_DIR fastrtps INTERFACE_INCLUDE_DIRECTORIES) + get_target_property(FAST_INCLUDE_DIR fastdds INTERFACE_INCLUDE_DIRECTORIES) list(GET FAST_INCLUDE_DIR 0 FAST_INCLUDE_DIR) file(GLOB_RECURSE ALL_FAST_HEADERS @@ -43,7 +43,7 @@ if (MSVC) "${FAST_INCLUDE_DIR}/**/*.hxx" ) - source_group("Fast-RTPS Headers" FILES ${ALL_FAST_HEADERS}) + source_group("Fast DDS Headers" FILES ${ALL_FAST_HEADERS}) endif() @@ -62,7 +62,7 @@ target_compile_definitions(${PROJECT_NAME} PRIVATE FAST_SERVER_VERSION=\"${PROJECT_VERSION}\" PRIVATE FAST_SERVER_BINARY=\"$\" ) -target_link_libraries(${PROJECT_NAME} fastrtps fastcdr fastdds::optionparser) +target_link_libraries(${PROJECT_NAME} fastdds fastcdr fastdds::optionparser) # Properties that change bin names depending on current config. # This is convenient because on installation all bins share folder @@ -76,8 +76,8 @@ set_target_properties(${PROJECT_NAME} PROPERTIES DEBUG_POSTFIX d-${PROJECT_VERSI ############################################################################### # If not isolated integrate -if(CMAKE_PROJECT_NAME STREQUAL "fastrtps" ) - set(BIN_INSTALL_DIR tools/fds/${BIN_INSTALL_DIR} CACHE PATH "Installation directory for binaries within Fast-DDS") +if(CMAKE_PROJECT_NAME STREQUAL "fastdds" ) + set(BIN_INSTALL_DIR tools/fds/${BIN_INSTALL_DIR} CACHE PATH "Installation directory for binaries within Fast DDS") else() set(BIN_INSTALL_DIR bin/ CACHE PATH "Installation directory for binaries") endif() @@ -102,7 +102,7 @@ install(EXPORT ${PROJECT_NAME}-targets ) # export xsd schema -install(FILES ../../resources/xsd/fastRTPS_profiles.xsd +install(FILES ../../resources/xsd/fastdds_profiles.xsd DESTINATION ${DATA_INSTALL_DIR} COMPONENT cmake ) diff --git a/tools/fds/server.cpp b/tools/fds/server.cpp index 29cc0f5e172..251aab948f5 100644 --- a/tools/fds/server.cpp +++ b/tools/fds/server.cpp @@ -33,8 +33,7 @@ #include #include #include -#include -#include +#include volatile sig_atomic_t g_signal_status = 0; std::mutex g_signal_mutex; @@ -117,7 +116,7 @@ int fastdds_discovery_server( sXMLConfigFile = sXMLConfigFile.substr(delimiter_pos + 1, sXMLConfigFile.length()); } - if (ReturnCode_t::RETCODE_OK != DomainParticipantFactory::get_instance()->load_XML_profiles_file( + if (RETCODE_OK != DomainParticipantFactory::get_instance()->load_XML_profiles_file( sXMLConfigFile)) { std::cout << "Cannot open XML file " << sXMLConfigFile << ". Please, check the path of this " @@ -128,7 +127,7 @@ int fastdds_discovery_server( { // Set environment variables to prevent loading the default XML file #ifdef _WIN32 - if (0 != _putenv_s("FASTRTPS_DEFAULT_PROFILES_FILE", "") || + if (0 != _putenv_s("FASTDDS_DEFAULT_PROFILES_FILE", "") || 0 != _putenv_s("SKIP_DEFAULT_XML_FILE", "1")) { char errmsg[1024]; @@ -137,15 +136,15 @@ int fastdds_discovery_server( return 1; } #else - if (0 != unsetenv(fastrtps::xmlparser::DEFAULT_FASTRTPS_ENV_VARIABLE) || - 0 != setenv(fastrtps::xmlparser::SKIP_DEFAULT_XML_FILE, "1", 1)) + if (0 != unsetenv("FASTDDS_DEFAULT_PROFILES_FILE") || + 0 != setenv("SKIP_DEFAULT_XML_FILE", "1", 1)) { std::cout << "Error setting environment variables: " << std::strerror(errno) << std::endl; return 1; } #endif // ifdef _WIN32 // Set default participant QoS from XML file - if (ReturnCode_t::RETCODE_OK != DomainParticipantFactory::get_instance()->load_profiles()) + if (RETCODE_OK != DomainParticipantFactory::get_instance()->load_profiles()) { std::cout << "Error setting default DomainParticipantQos from XML default profile." << std::endl; return 1; @@ -154,7 +153,7 @@ int fastdds_discovery_server( } else { - if (ReturnCode_t::RETCODE_OK != + if (RETCODE_OK != DomainParticipantFactory::get_instance()->get_participant_qos_from_profile( profile, participantQos)) { diff --git a/utils/doxygen/complete_doxyfile_api b/utils/doxygen/complete_doxyfile_api deleted file mode 100644 index 4cd522704d8..00000000000 --- a/utils/doxygen/complete_doxyfile_api +++ /dev/null @@ -1,2355 +0,0 @@ -# Doxyfile 1.8.6 - -# This file describes the settings to be used by the documentation system -# doxygen (www.doxygen.org) for a project. -# -# All text after a double hash (##) is considered a comment and is placed in -# front of the TAG it is preceding. -# -# All text after a single hash (#) is considered a comment and will be ignored. -# The format is: -# TAG = value [value, ...] -# For lists, items can also be appended using: -# TAG += value [value, ...] -# Values that contain spaces should be placed between quotes (\" \"). - -#--------------------------------------------------------------------------- -# Project related configuration options -#--------------------------------------------------------------------------- - -# This tag specifies the encoding used for all characters in the config file -# that follow. The default is UTF-8 which is also the encoding used for all text -# before the first occurrence of this tag. Doxygen uses libiconv (or the iconv -# built into libc) for the transcoding. See http://www.gnu.org/software/libiconv -# for the list of possible encodings. -# The default value is: UTF-8. - -DOXYFILE_ENCODING = UTF-8 - -# The PROJECT_NAME tag is a single word (or a sequence of words surrounded by -# double-quotes, unless you are using Doxywizard) that should identify the -# project for which the documentation is generated. This name is used in the -# title of most generated pages and in a few other places. -# The default value is: My Project. - -PROJECT_NAME = "Fast RTPS" - -# The PROJECT_NUMBER tag can be used to enter a project or revision number. This -# could be handy for archiving the generated documentation or if some version -# control system is used. - -PROJECT_NUMBER = $(VERSION_DOX) - -# Using the PROJECT_BRIEF tag one can provide an optional one line description -# for a project that appears at the top of each page and should give viewer a -# quick idea about the purpose of the project. Keep the description short. - -PROJECT_BRIEF = "Fast RTPS Implementation" - -# With the PROJECT_LOGO tag one can specify an logo or icon that is included in -# the documentation. The maximum height of the logo should not exceed 55 pixels -# and the maximum width should not exceed 200 pixels. Doxygen will copy the logo -# to the output directory. - -PROJECT_LOGO = ./doxygenfiles/eProsimaLogo.png - -# The OUTPUT_DIRECTORY tag is used to specify the (relative or absolute) path -# into which the generated documentation will be written. If a relative path is -# entered, it will be relative to the location where doxygen was started. If -# left blank the current directory will be used. - -OUTPUT_DIRECTORY = output/doxygen - -# If the CREATE_SUBDIRS tag is set to YES, then doxygen will create 4096 sub- -# directories (in 2 levels) under the output directory of each output format and -# will distribute the generated files over these directories. Enabling this -# option can be useful when feeding doxygen a huge amount of source files, where -# putting all generated files in the same directory would otherwise causes -# performance problems for the file system. -# The default value is: NO. - -CREATE_SUBDIRS = NO - -# The OUTPUT_LANGUAGE tag is used to specify the language in which all -# documentation generated by doxygen is written. Doxygen will use this -# information to generate all constant output in the proper language. -# Possible values are: Afrikaans, Arabic, Armenian, Brazilian, Catalan, Chinese, -# Chinese-Traditional, Croatian, Czech, Danish, Dutch, English (United States), -# Esperanto, Farsi (Persian), Finnish, French, German, Greek, Hungarian, -# Indonesian, Italian, Japanese, Japanese-en (Japanese with English messages), -# Korean, Korean-en (Korean with English messages), Latvian, Lithuanian, -# Macedonian, Norwegian, Persian (Farsi), Polish, Portuguese, Romanian, Russian, -# Serbian, Serbian-Cyrillic, Slovak, Slovene, Spanish, Swedish, Turkish, -# Ukrainian and Vietnamese. -# The default value is: English. - -OUTPUT_LANGUAGE = English - -# If the BRIEF_MEMBER_DESC tag is set to YES doxygen will include brief member -# descriptions after the members that are listed in the file and class -# documentation (similar to Javadoc). Set to NO to disable this. -# The default value is: YES. - -BRIEF_MEMBER_DESC = YES - -# If the REPEAT_BRIEF tag is set to YES doxygen will prepend the brief -# description of a member or function before the detailed description -# -# Note: If both HIDE_UNDOC_MEMBERS and BRIEF_MEMBER_DESC are set to NO, the -# brief descriptions will be completely suppressed. -# The default value is: YES. - -REPEAT_BRIEF = YES - -# This tag implements a quasi-intelligent brief description abbreviator that is -# used to form the text in various listings. Each string in this list, if found -# as the leading text of the brief description, will be stripped from the text -# and the result, after processing the whole list, is used as the annotated -# text. Otherwise, the brief description is used as-is. If left blank, the -# following values are used ($name is automatically replaced with the name of -# the entity):The $name class, The $name widget, The $name file, is, provides, -# specifies, contains, represents, a, an and the. - -ABBREVIATE_BRIEF = "The $name class" \ - "The $name widget" \ - "The $name file" \ - is \ - provides \ - specifies \ - contains \ - represents \ - a \ - an \ - the - -# If the ALWAYS_DETAILED_SEC and REPEAT_BRIEF tags are both set to YES then -# doxygen will generate a detailed section even if there is only a brief -# description. -# The default value is: NO. - -ALWAYS_DETAILED_SEC = NO - -# If the INLINE_INHERITED_MEMB tag is set to YES, doxygen will show all -# inherited members of a class in the documentation of that class as if those -# members were ordinary class members. Constructors, destructors and assignment -# operators of the base classes will not be shown. -# The default value is: NO. - -INLINE_INHERITED_MEMB = NO - -# If the FULL_PATH_NAMES tag is set to YES doxygen will prepend the full path -# before files name in the file list and in the header files. If set to NO the -# shortest path that makes the file name unique will be used -# The default value is: YES. - -FULL_PATH_NAMES = YES - -# The STRIP_FROM_PATH tag can be used to strip a user-defined part of the path. -# Stripping is only done if one of the specified strings matches the left-hand -# part of the path. The tag can be used to show relative paths in the file list. -# If left blank the directory from which doxygen is run is used as the path to -# strip. -# -# Note that you can specify absolute paths here, but also relative paths, which -# will be relative from the directory where doxygen is started. -# This tag requires that the tag FULL_PATH_NAMES is set to YES. - -STRIP_FROM_PATH = - -# The STRIP_FROM_INC_PATH tag can be used to strip a user-defined part of the -# path mentioned in the documentation of a class, which tells the reader which -# header file to include in order to use a class. If left blank only the name of -# the header file containing the class definition is used. Otherwise one should -# specify the list of include paths that are normally passed to the compiler -# using the -I flag. - -STRIP_FROM_INC_PATH = - -# If the SHORT_NAMES tag is set to YES, doxygen will generate much shorter (but -# less readable) file names. This can be useful is your file systems doesn't -# support long names like on DOS, Mac, or CD-ROM. -# The default value is: NO. - -SHORT_NAMES = NO - -# If the JAVADOC_AUTOBRIEF tag is set to YES then doxygen will interpret the -# first line (until the first dot) of a Javadoc-style comment as the brief -# description. If set to NO, the Javadoc-style will behave just like regular Qt- -# style comments (thus requiring an explicit @brief command for a brief -# description.) -# The default value is: NO. - -JAVADOC_AUTOBRIEF = YES - -# If the QT_AUTOBRIEF tag is set to YES then doxygen will interpret the first -# line (until the first dot) of a Qt-style comment as the brief description. If -# set to NO, the Qt-style will behave just like regular Qt-style comments (thus -# requiring an explicit \brief command for a brief description.) -# The default value is: NO. - -QT_AUTOBRIEF = NO - -# The MULTILINE_CPP_IS_BRIEF tag can be set to YES to make doxygen treat a -# multi-line C++ special comment block (i.e. a block of //! or /// comments) as -# a brief description. This used to be the default behavior. The new default is -# to treat a multi-line C++ comment block as a detailed description. Set this -# tag to YES if you prefer the old behavior instead. -# -# Note that setting this tag to YES also means that rational rose comments are -# not recognized any more. -# The default value is: NO. - -MULTILINE_CPP_IS_BRIEF = NO - -# If the INHERIT_DOCS tag is set to YES then an undocumented member inherits the -# documentation from any documented member that it re-implements. -# The default value is: YES. - -INHERIT_DOCS = YES - -# If the SEPARATE_MEMBER_PAGES tag is set to YES, then doxygen will produce a -# new page for each member. If set to NO, the documentation of a member will be -# part of the file/class/namespace that contains it. -# The default value is: NO. - -SEPARATE_MEMBER_PAGES = NO - -# The TAB_SIZE tag can be used to set the number of spaces in a tab. Doxygen -# uses this value to replace tabs by spaces in code fragments. -# Minimum value: 1, maximum value: 16, default value: 4. - -TAB_SIZE = 8 - -# This tag can be used to specify a number of aliases that act as commands in -# the documentation. An alias has the form: -# name=value -# For example adding -# "sideeffect=@par Side Effects:\n" -# will allow you to put the command \sideeffect (or @sideeffect) in the -# documentation, which will result in a user-defined paragraph with heading -# "Side Effects:". You can put \n's in the value part of an alias to insert -# newlines. - -ALIASES = - -# This tag can be used to specify a number of word-keyword mappings (TCL only). -# A mapping has the form "name=value". For example adding "class=itcl::class" -# will allow you to use the command class in the itcl::class meaning. - -TCL_SUBST = - -# Set the OPTIMIZE_OUTPUT_FOR_C tag to YES if your project consists of C sources -# only. Doxygen will then generate output that is more tailored for C. For -# instance, some of the names that are used will be different. The list of all -# members will be omitted, etc. -# The default value is: NO. - -OPTIMIZE_OUTPUT_FOR_C = NO - -# Set the OPTIMIZE_OUTPUT_JAVA tag to YES if your project consists of Java or -# Python sources only. Doxygen will then generate output that is more tailored -# for that language. For instance, namespaces will be presented as packages, -# qualified scopes will look different, etc. -# The default value is: NO. - -OPTIMIZE_OUTPUT_JAVA = NO - -# Set the OPTIMIZE_FOR_FORTRAN tag to YES if your project consists of Fortran -# sources. Doxygen will then generate output that is tailored for Fortran. -# The default value is: NO. - -OPTIMIZE_FOR_FORTRAN = NO - -# Set the OPTIMIZE_OUTPUT_VHDL tag to YES if your project consists of VHDL -# sources. Doxygen will then generate output that is tailored for VHDL. -# The default value is: NO. - -OPTIMIZE_OUTPUT_VHDL = NO - -# Doxygen selects the parser to use depending on the extension of the files it -# parses. With this tag you can assign which parser to use for a given -# extension. Doxygen has a built-in mapping, but you can override or extend it -# using this tag. The format is ext=language, where ext is a file extension, and -# language is one of the parsers supported by doxygen: IDL, Java, Javascript, -# C#, C, C++, D, PHP, Objective-C, Python, Fortran, VHDL. For instance to make -# doxygen treat .inc files as Fortran files (default is PHP), and .f files as C -# (default is Fortran), use: inc=Fortran f=C. -# -# Note For files without extension you can use no_extension as a placeholder. -# -# Note that for custom extensions you also need to set FILE_PATTERNS otherwise -# the files are not read by doxygen. - -EXTENSION_MAPPING = - -# If the MARKDOWN_SUPPORT tag is enabled then doxygen pre-processes all comments -# according to the Markdown format, which allows for more readable -# documentation. See http://daringfireball.net/projects/markdown/ for details. -# The output of markdown processing is further processed by doxygen, so you can -# mix doxygen, HTML, and XML commands with Markdown formatting. Disable only in -# case of backward compatibilities issues. -# The default value is: YES. - -MARKDOWN_SUPPORT = YES - -# When enabled doxygen tries to link words that correspond to documented -# classes, or namespaces to their corresponding documentation. Such a link can -# be prevented in individual cases by by putting a % sign in front of the word -# or globally by setting AUTOLINK_SUPPORT to NO. -# The default value is: YES. - -AUTOLINK_SUPPORT = YES - -# If you use STL classes (i.e. std::string, std::vector, etc.) but do not want -# to include (a tag file for) the STL sources as input, then you should set this -# tag to YES in order to let doxygen match functions declarations and -# definitions whose arguments contain STL classes (e.g. func(std::string); -# versus func(std::string) {}). This also make the inheritance and collaboration -# diagrams that involve STL classes more complete and accurate. -# The default value is: NO. - -BUILTIN_STL_SUPPORT = NO - -# If you use Microsoft's C++/CLI language, you should set this option to YES to -# enable parsing support. -# The default value is: NO. - -CPP_CLI_SUPPORT = NO - -# Set the SIP_SUPPORT tag to YES if your project consists of sip (see: -# http://www.riverbankcomputing.co.uk/software/sip/intro) sources only. Doxygen -# will parse them like normal C++ but will assume all classes use public instead -# of private inheritance when no explicit protection keyword is present. -# The default value is: NO. - -SIP_SUPPORT = NO - -# For Microsoft's IDL there are propget and propput attributes to indicate -# getter and setter methods for a property. Setting this option to YES will make -# doxygen to replace the get and set methods by a property in the documentation. -# This will only work if the methods are indeed getting or setting a simple -# type. If this is not the case, or you want to show the methods anyway, you -# should set this option to NO. -# The default value is: YES. - -IDL_PROPERTY_SUPPORT = YES - -# If member grouping is used in the documentation and the DISTRIBUTE_GROUP_DOC -# tag is set to YES, then doxygen will reuse the documentation of the first -# member in the group (if any) for the other members of the group. By default -# all members of a group must be documented explicitly. -# The default value is: NO. - -DISTRIBUTE_GROUP_DOC = NO - -# Set the SUBGROUPING tag to YES to allow class member groups of the same type -# (for instance a group of public functions) to be put as a subgroup of that -# type (e.g. under the Public Functions section). Set it to NO to prevent -# subgrouping. Alternatively, this can be done per class using the -# \nosubgrouping command. -# The default value is: YES. - -SUBGROUPING = YES - -# When the INLINE_GROUPED_CLASSES tag is set to YES, classes, structs and unions -# are shown inside the group in which they are included (e.g. using \ingroup) -# instead of on a separate page (for HTML and Man pages) or section (for LaTeX -# and RTF). -# -# Note that this feature does not work in combination with -# SEPARATE_MEMBER_PAGES. -# The default value is: NO. - -INLINE_GROUPED_CLASSES = NO - -# When the INLINE_SIMPLE_STRUCTS tag is set to YES, structs, classes, and unions -# with only public data fields or simple typedef fields will be shown inline in -# the documentation of the scope in which they are defined (i.e. file, -# namespace, or group documentation), provided this scope is documented. If set -# to NO, structs, classes, and unions are shown on a separate page (for HTML and -# Man pages) or section (for LaTeX and RTF). -# The default value is: NO. - -INLINE_SIMPLE_STRUCTS = NO - -# When TYPEDEF_HIDES_STRUCT tag is enabled, a typedef of a struct, union, or -# enum is documented as struct, union, or enum with the name of the typedef. So -# typedef struct TypeS {} TypeT, will appear in the documentation as a struct -# with name TypeT. When disabled the typedef will appear as a member of a file, -# namespace, or class. And the struct will be named TypeS. This can typically be -# useful for C code in case the coding convention dictates that all compound -# types are typedef'ed and only the typedef is referenced, never the tag name. -# The default value is: NO. - -TYPEDEF_HIDES_STRUCT = NO - -# The size of the symbol lookup cache can be set using LOOKUP_CACHE_SIZE. This -# cache is used to resolve symbols given their name and scope. Since this can be -# an expensive process and often the same symbol appears multiple times in the -# code, doxygen keeps a cache of pre-resolved symbols. If the cache is too small -# doxygen will become slower. If the cache is too large, memory is wasted. The -# cache size is given by this formula: 2^(16+LOOKUP_CACHE_SIZE). The valid range -# is 0..9, the default is 0, corresponding to a cache size of 2^16=65536 -# symbols. At the end of a run doxygen will report the cache usage and suggest -# the optimal cache size from a speed point of view. -# Minimum value: 0, maximum value: 9, default value: 0. - -LOOKUP_CACHE_SIZE = 0 - -#--------------------------------------------------------------------------- -# Build related configuration options -#--------------------------------------------------------------------------- - -# If the EXTRACT_ALL tag is set to YES doxygen will assume all entities in -# documentation are documented, even if no documentation was available. Private -# class members and static file members will be hidden unless the -# EXTRACT_PRIVATE respectively EXTRACT_STATIC tags are set to YES. -# Note: This will also disable the warnings about undocumented members that are -# normally produced when WARNINGS is set to YES. -# The default value is: NO. - -EXTRACT_ALL = YES - -# If the EXTRACT_PRIVATE tag is set to YES all private members of a class will -# be included in the documentation. -# The default value is: NO. - -EXTRACT_PRIVATE = NO - -# If the EXTRACT_PACKAGE tag is set to YES all members with package or internal -# scope will be included in the documentation. -# The default value is: NO. - -EXTRACT_PACKAGE = YES - -# If the EXTRACT_STATIC tag is set to YES all static members of a file will be -# included in the documentation. -# The default value is: NO. - -EXTRACT_STATIC = YES - -# If the EXTRACT_LOCAL_CLASSES tag is set to YES classes (and structs) defined -# locally in source files will be included in the documentation. If set to NO -# only classes defined in header files are included. Does not have any effect -# for Java sources. -# The default value is: YES. - -EXTRACT_LOCAL_CLASSES = YES - -# This flag is only useful for Objective-C code. When set to YES local methods, -# which are defined in the implementation section but not in the interface are -# included in the documentation. If set to NO only methods in the interface are -# included. -# The default value is: NO. - -EXTRACT_LOCAL_METHODS = YES - -# If this flag is set to YES, the members of anonymous namespaces will be -# extracted and appear in the documentation as a namespace called -# 'anonymous_namespace{file}', where file will be replaced with the base name of -# the file that contains the anonymous namespace. By default anonymous namespace -# are hidden. -# The default value is: NO. - -EXTRACT_ANON_NSPACES = NO - -# If the HIDE_UNDOC_MEMBERS tag is set to YES, doxygen will hide all -# undocumented members inside documented classes or files. If set to NO these -# members will be included in the various overviews, but no documentation -# section is generated. This option has no effect if EXTRACT_ALL is enabled. -# The default value is: NO. - -HIDE_UNDOC_MEMBERS = NO - -# If the HIDE_UNDOC_CLASSES tag is set to YES, doxygen will hide all -# undocumented classes that are normally visible in the class hierarchy. If set -# to NO these classes will be included in the various overviews. This option has -# no effect if EXTRACT_ALL is enabled. -# The default value is: NO. - -HIDE_UNDOC_CLASSES = NO - -# If the HIDE_FRIEND_COMPOUNDS tag is set to YES, doxygen will hide all friend -# (class|struct|union) declarations. If set to NO these declarations will be -# included in the documentation. -# The default value is: NO. - -HIDE_FRIEND_COMPOUNDS = NO - -# If the HIDE_IN_BODY_DOCS tag is set to YES, doxygen will hide any -# documentation blocks found inside the body of a function. If set to NO these -# blocks will be appended to the function's detailed documentation block. -# The default value is: NO. - -HIDE_IN_BODY_DOCS = NO - -# The INTERNAL_DOCS tag determines if documentation that is typed after a -# \internal command is included. If the tag is set to NO then the documentation -# will be excluded. Set it to YES to include the internal documentation. -# The default value is: NO. - -INTERNAL_DOCS = NO - -# If the CASE_SENSE_NAMES tag is set to NO then doxygen will only generate file -# names in lower-case letters. If set to YES upper-case letters are also -# allowed. This is useful if you have classes or files whose names only differ -# in case and if your file system supports case sensitive file names. Windows -# and Mac users are advised to set this option to NO. -# The default value is: system dependent. - -CASE_SENSE_NAMES = NO - -# If the HIDE_SCOPE_NAMES tag is set to NO then doxygen will show members with -# their full class and namespace scopes in the documentation. If set to YES the -# scope will be hidden. -# The default value is: NO. - -HIDE_SCOPE_NAMES = YES - -# If the SHOW_INCLUDE_FILES tag is set to YES then doxygen will put a list of -# the files that are included by a file in the documentation of that file. -# The default value is: YES. - -SHOW_INCLUDE_FILES = YES - -# If the SHOW_GROUPED_MEMB_INC tag is set to YES then Doxygen will add for each -# grouped member an include statement to the documentation, telling the reader -# which file to include in order to use the member. -# The default value is: NO. - -SHOW_GROUPED_MEMB_INC = NO - -# If the FORCE_LOCAL_INCLUDES tag is set to YES then doxygen will list include -# files with double quotes in the documentation rather than with sharp brackets. -# The default value is: NO. - -FORCE_LOCAL_INCLUDES = NO - -# If the INLINE_INFO tag is set to YES then a tag [inline] is inserted in the -# documentation for inline members. -# The default value is: YES. - -INLINE_INFO = YES - -# If the SORT_MEMBER_DOCS tag is set to YES then doxygen will sort the -# (detailed) documentation of file and class members alphabetically by member -# name. If set to NO the members will appear in declaration order. -# The default value is: YES. - -SORT_MEMBER_DOCS = YES - -# If the SORT_BRIEF_DOCS tag is set to YES then doxygen will sort the brief -# descriptions of file, namespace and class members alphabetically by member -# name. If set to NO the members will appear in declaration order. Note that -# this will also influence the order of the classes in the class list. -# The default value is: NO. - -SORT_BRIEF_DOCS = NO - -# If the SORT_MEMBERS_CTORS_1ST tag is set to YES then doxygen will sort the -# (brief and detailed) documentation of class members so that constructors and -# destructors are listed first. If set to NO the constructors will appear in the -# respective orders defined by SORT_BRIEF_DOCS and SORT_MEMBER_DOCS. -# Note: If SORT_BRIEF_DOCS is set to NO this option is ignored for sorting brief -# member documentation. -# Note: If SORT_MEMBER_DOCS is set to NO this option is ignored for sorting -# detailed member documentation. -# The default value is: NO. - -SORT_MEMBERS_CTORS_1ST = NO - -# If the SORT_GROUP_NAMES tag is set to YES then doxygen will sort the hierarchy -# of group names into alphabetical order. If set to NO the group names will -# appear in their defined order. -# The default value is: NO. - -SORT_GROUP_NAMES = NO - -# If the SORT_BY_SCOPE_NAME tag is set to YES, the class list will be sorted by -# fully-qualified names, including namespaces. If set to NO, the class list will -# be sorted only by class name, not including the namespace part. -# Note: This option is not very useful if HIDE_SCOPE_NAMES is set to YES. -# Note: This option applies only to the class list, not to the alphabetical -# list. -# The default value is: NO. - -SORT_BY_SCOPE_NAME = NO - -# If the STRICT_PROTO_MATCHING option is enabled and doxygen fails to do proper -# type resolution of all parameters of a function it will reject a match between -# the prototype and the implementation of a member function even if there is -# only one candidate or it is obvious which candidate to choose by doing a -# simple string match. By disabling STRICT_PROTO_MATCHING doxygen will still -# accept a match between prototype and implementation in such cases. -# The default value is: NO. - -STRICT_PROTO_MATCHING = NO - -# The GENERATE_TODOLIST tag can be used to enable ( YES) or disable ( NO) the -# todo list. This list is created by putting \todo commands in the -# documentation. -# The default value is: YES. - -GENERATE_TODOLIST = YES - -# The GENERATE_TESTLIST tag can be used to enable ( YES) or disable ( NO) the -# test list. This list is created by putting \test commands in the -# documentation. -# The default value is: YES. - -GENERATE_TESTLIST = YES - -# The GENERATE_BUGLIST tag can be used to enable ( YES) or disable ( NO) the bug -# list. This list is created by putting \bug commands in the documentation. -# The default value is: YES. - -GENERATE_BUGLIST = YES - -# The GENERATE_DEPRECATEDLIST tag can be used to enable ( YES) or disable ( NO) -# the deprecated list. This list is created by putting \deprecated commands in -# the documentation. -# The default value is: YES. - -GENERATE_DEPRECATEDLIST= YES - -# The ENABLED_SECTIONS tag can be used to enable conditional documentation -# sections, marked by \if ... \endif and \cond -# ... \endcond blocks. - -ENABLED_SECTIONS = - -# The MAX_INITIALIZER_LINES tag determines the maximum number of lines that the -# initial value of a variable or macro / define can have for it to appear in the -# documentation. If the initializer consists of more lines than specified here -# it will be hidden. Use a value of 0 to hide initializers completely. The -# appearance of the value of individual variables and macros / defines can be -# controlled using \showinitializer or \hideinitializer command in the -# documentation regardless of this setting. -# Minimum value: 0, maximum value: 10000, default value: 30. - -MAX_INITIALIZER_LINES = 30 - -# Set the SHOW_USED_FILES tag to NO to disable the list of files generated at -# the bottom of the documentation of classes and structs. If set to YES the list -# will mention the files that were used to generate the documentation. -# The default value is: YES. - -SHOW_USED_FILES = YES - -# Set the SHOW_FILES tag to NO to disable the generation of the Files page. This -# will remove the Files entry from the Quick Index and from the Folder Tree View -# (if specified). -# The default value is: YES. - -SHOW_FILES = NO - -# Set the SHOW_NAMESPACES tag to NO to disable the generation of the Namespaces -# page. This will remove the Namespaces entry from the Quick Index and from the -# Folder Tree View (if specified). -# The default value is: YES. - -SHOW_NAMESPACES = YES - -# The FILE_VERSION_FILTER tag can be used to specify a program or script that -# doxygen should invoke to get the current version for each file (typically from -# the version control system). Doxygen will invoke the program by executing (via -# popen()) the command command input-file, where command is the value of the -# FILE_VERSION_FILTER tag, and input-file is the name of an input file provided -# by doxygen. Whatever the program writes to standard output is used as the file -# version. For an example see the documentation. - -FILE_VERSION_FILTER = - -# The LAYOUT_FILE tag can be used to specify a layout file which will be parsed -# by doxygen. The layout file controls the global structure of the generated -# output files in an output format independent way. To create the layout file -# that represents doxygen's defaults, run doxygen with the -l option. You can -# optionally specify a file name after the option, if omitted DoxygenLayout.xml -# will be used as the name of the layout file. -# -# Note that if you run doxygen from a directory containing a file called -# DoxygenLayout.xml, doxygen will parse it automatically even if the LAYOUT_FILE -# tag is left empty. - -LAYOUT_FILE = - -# The CITE_BIB_FILES tag can be used to specify one or more bib files containing -# the reference definitions. This must be a list of .bib files. The .bib -# extension is automatically appended if omitted. This requires the bibtex tool -# to be installed. See also http://en.wikipedia.org/wiki/BibTeX for more info. -# For LaTeX the style of the bibliography can be controlled using -# LATEX_BIB_STYLE. To use this feature you need bibtex and perl available in the -# search path. Do not use file names with spaces, bibtex cannot handle them. See -# also \cite for info how to create references. - -CITE_BIB_FILES = - -#--------------------------------------------------------------------------- -# Configuration options related to warning and progress messages -#--------------------------------------------------------------------------- - -# The QUIET tag can be used to turn on/off the messages that are generated to -# standard output by doxygen. If QUIET is set to YES this implies that the -# messages are off. -# The default value is: NO. - -QUIET = NO - -# The WARNINGS tag can be used to turn on/off the warning messages that are -# generated to standard error ( stderr) by doxygen. If WARNINGS is set to YES -# this implies that the warnings are on. -# -# Tip: Turn warnings on while writing the documentation. -# The default value is: YES. - -WARNINGS = YES - -# If the WARN_IF_UNDOCUMENTED tag is set to YES, then doxygen will generate -# warnings for undocumented members. If EXTRACT_ALL is set to YES then this flag -# will automatically be disabled. -# The default value is: YES. - -WARN_IF_UNDOCUMENTED = YES - -# If the WARN_IF_DOC_ERROR tag is set to YES, doxygen will generate warnings for -# potential errors in the documentation, such as not documenting some parameters -# in a documented function, or documenting parameters that don't exist or using -# markup commands wrongly. -# The default value is: YES. - -WARN_IF_DOC_ERROR = YES - -# This WARN_NO_PARAMDOC option can be enabled to get warnings for functions that -# are documented, but have no documentation for their parameters or return -# value. If set to NO doxygen will only warn about wrong or incomplete parameter -# documentation, but not about the absence of documentation. -# The default value is: NO. - -WARN_NO_PARAMDOC = YES - -# If the WARN_AS_ERROR tag is set to YES then doxygen will immediately stop when -# a warning is encountered. -# The default value is: NO. - -WARN_AS_ERROR = YES - -# The WARN_FORMAT tag determines the format of the warning messages that doxygen -# can produce. The string should contain the $file, $line, and $text tags, which -# will be replaced by the file and line number from which the warning originated -# and the warning text. Optionally the format may contain $version, which will -# be replaced by the version of the file (if it could be obtained via -# FILE_VERSION_FILTER) -# The default value is: $file:$line: $text. - -WARN_FORMAT = "$file:$line: $text" - -# The WARN_LOGFILE tag can be used to specify a file to which warning and error -# messages should be written. If left blank the output is written to standard -# error (stderr). - -WARN_LOGFILE = - -#--------------------------------------------------------------------------- -# Configuration options related to the input files -#--------------------------------------------------------------------------- - -# The INPUT tag is used to specify the files and/or directories that contain -# documented source files. You may enter file names like myfile.cpp or -# directories like /usr/src/myproject. Separate the files or directories with -# spaces. -# Note: If this tag is empty the current directory is searched. - -INPUT = ../../include/fastrtps \ - ../../thirdparty/eprosima-common-code/eProsima_cpp/log \ - doxygenfiles/mainpage.dox - -# This tag can be used to specify the character encoding of the source files -# that doxygen parses. Internally doxygen uses the UTF-8 encoding. Doxygen uses -# libiconv (or the iconv built into libc) for the transcoding. See the libiconv -# documentation (see: http://www.gnu.org/software/libiconv) for the list of -# possible encodings. -# The default value is: UTF-8. - -INPUT_ENCODING = UTF-8 - -# If the value of the INPUT tag contains directories, you can use the -# FILE_PATTERNS tag to specify one or more wildcard patterns (like *.cpp and -# *.h) to filter out the source-files in the directories. If left blank the -# following patterns are tested:*.c, *.cc, *.cxx, *.cpp, *.c++, *.java, *.ii, -# *.ixx, *.ipp, *.i++, *.inl, *.idl, *.ddl, *.odl, *.h, *.hh, *.hxx, *.hpp, -# *.h++, *.cs, *.d, *.php, *.php4, *.php5, *.phtml, *.inc, *.m, *.markdown, -# *.md, *.mm, *.dox, *.py, *.f90, *.f, *.for, *.tcl, *.vhd, *.vhdl, *.ucf, -# *.qsf, *.as and *.js. - -FILE_PATTERNS = *.c \ - *.cc \ - *.cxx \ - *.cpp \ - *.c++ \ - *.d \ - *.java \ - *.ii \ - *.ixx \ - *.ipp \ - *.i++ \ - *.inl \ - *.h \ - *.hh \ - *.hxx \ - *.hpp \ - *.h++ \ - *.idl \ - *.odl \ - *.cs \ - *.php \ - *.php3 \ - *.inc \ - *.m \ - *.markdown \ - *.md \ - *.mm \ - *.dox \ - *.py \ - *.f90 \ - *.f \ - *.for \ - *.vhd \ - *.vhdl - -# The RECURSIVE tag can be used to specify whether or not subdirectories should -# be searched for input files as well. -# The default value is: NO. - -RECURSIVE = YES - -# The EXCLUDE tag can be used to specify files and/or directories that should be -# excluded from the INPUT source files. This way you can easily exclude a -# subdirectory from a directory tree whose root is specified with the INPUT tag. -# -# Note that relative paths are relative to the directory from which doxygen is -# run. - -EXCLUDE = - -# The EXCLUDE_SYMLINKS tag can be used to select whether or not files or -# directories that are symbolic links (a Unix file system feature) are excluded -# from the input. -# The default value is: NO. - -EXCLUDE_SYMLINKS = NO - -# If the value of the INPUT tag contains directories, you can use the -# EXCLUDE_PATTERNS tag to specify one or more wildcard patterns to exclude -# certain files from those directories. -# -# Note that the wildcards are matched against the file with absolute path, so to -# exclude all test directories for example use the pattern */test/* - -EXCLUDE_PATTERNS = - -# The EXCLUDE_SYMBOLS tag can be used to specify one or more symbol names -# (namespaces, classes, functions, etc.) that should be excluded from the -# output. The symbol name can be a fully qualified name, a word, or if the -# wildcard * is used, a substring. Examples: ANamespace, AClass, -# AClass::ANamespace, ANamespace::*Test -# -# Note that the wildcards are matched against the file with absolute path, so to -# exclude all test directories use the pattern */test/* - -EXCLUDE_SYMBOLS = boost - -# The EXAMPLE_PATH tag can be used to specify one or more files or directories -# that contain example code fragments that are included (see the \include -# command). - -EXAMPLE_PATH = ./utils/examples \ - ./examples/C++ - -# If the value of the EXAMPLE_PATH tag contains directories, you can use the -# EXAMPLE_PATTERNS tag to specify one or more wildcard pattern (like *.cpp and -# *.h) to filter out the source-files in the directories. If left blank all -# files are included. - -EXAMPLE_PATTERNS = * - -# If the EXAMPLE_RECURSIVE tag is set to YES then subdirectories will be -# searched for input files to be used with the \include or \dontinclude commands -# irrespective of the value of the RECURSIVE tag. -# The default value is: NO. - -EXAMPLE_RECURSIVE = NO - -# The IMAGE_PATH tag can be used to specify one or more files or directories -# that contain images that are to be included in the documentation (see the -# \image command). - -IMAGE_PATH = doxygenfiles - -# The INPUT_FILTER tag can be used to specify a program that doxygen should -# invoke to filter for each input file. Doxygen will invoke the filter program -# by executing (via popen()) the command: -# -# -# -# where is the value of the INPUT_FILTER tag, and is the -# name of an input file. Doxygen will then use the output that the filter -# program writes to standard output. If FILTER_PATTERNS is specified, this tag -# will be ignored. -# -# Note that the filter must not add or remove lines; it is applied before the -# code is scanned, but not when the output code is generated. If lines are added -# or removed, the anchors will not be placed correctly. - -INPUT_FILTER = - -# The FILTER_PATTERNS tag can be used to specify filters on a per file pattern -# basis. Doxygen will compare the file name with each pattern and apply the -# filter if there is a match. The filters are a list of the form: pattern=filter -# (like *.cpp=my_cpp_filter). See INPUT_FILTER for further information on how -# filters are used. If the FILTER_PATTERNS tag is empty or if none of the -# patterns match the file name, INPUT_FILTER is applied. - -FILTER_PATTERNS = - -# If the FILTER_SOURCE_FILES tag is set to YES, the input filter (if set using -# INPUT_FILTER ) will also be used to filter the input files that are used for -# producing the source files to browse (i.e. when SOURCE_BROWSER is set to YES). -# The default value is: NO. - -FILTER_SOURCE_FILES = NO - -# The FILTER_SOURCE_PATTERNS tag can be used to specify source filters per file -# pattern. A pattern will override the setting for FILTER_PATTERN (if any) and -# it is also possible to disable source filtering for a specific pattern using -# *.ext= (so without naming a filter). -# This tag requires that the tag FILTER_SOURCE_FILES is set to YES. - -FILTER_SOURCE_PATTERNS = - -# If the USE_MDFILE_AS_MAINPAGE tag refers to the name of a markdown file that -# is part of the input, its contents will be placed on the main page -# (index.html). This can be useful if you have a project on for instance GitHub -# and want to reuse the introduction page also for the doxygen output. - -USE_MDFILE_AS_MAINPAGE = - -#--------------------------------------------------------------------------- -# Configuration options related to source browsing -#--------------------------------------------------------------------------- - -# If the SOURCE_BROWSER tag is set to YES then a list of source files will be -# generated. Documented entities will be cross-referenced with these sources. -# -# Note: To get rid of all source code in the generated output, make sure that -# also VERBATIM_HEADERS is set to NO. -# The default value is: NO. - -SOURCE_BROWSER = NO - -# Setting the INLINE_SOURCES tag to YES will include the body of functions, -# classes and enums directly into the documentation. -# The default value is: NO. - -INLINE_SOURCES = NO - -# Setting the STRIP_CODE_COMMENTS tag to YES will instruct doxygen to hide any -# special comment blocks from generated source code fragments. Normal C, C++ and -# Fortran comments will always remain visible. -# The default value is: YES. - -STRIP_CODE_COMMENTS = YES - -# If the REFERENCED_BY_RELATION tag is set to YES then for each documented -# function all documented functions referencing it will be listed. -# The default value is: NO. - -REFERENCED_BY_RELATION = NO - -# If the REFERENCES_RELATION tag is set to YES then for each documented function -# all documented entities called/used by that function will be listed. -# The default value is: NO. - -REFERENCES_RELATION = NO - -# If the REFERENCES_LINK_SOURCE tag is set to YES and SOURCE_BROWSER tag is set -# to YES, then the hyperlinks from functions in REFERENCES_RELATION and -# REFERENCED_BY_RELATION lists will link to the source code. Otherwise they will -# link to the documentation. -# The default value is: YES. - -REFERENCES_LINK_SOURCE = YES - -# If SOURCE_TOOLTIPS is enabled (the default) then hovering a hyperlink in the -# source code will show a tooltip with additional information such as prototype, -# brief description and links to the definition and documentation. Since this -# will make the HTML file larger and loading of large files a bit slower, you -# can opt to disable this feature. -# The default value is: YES. -# This tag requires that the tag SOURCE_BROWSER is set to YES. - -SOURCE_TOOLTIPS = YES - -# If the USE_HTAGS tag is set to YES then the references to source code will -# point to the HTML generated by the htags(1) tool instead of doxygen built-in -# source browser. The htags tool is part of GNU's global source tagging system -# (see http://www.gnu.org/software/global/global.html). You will need version -# 4.8.6 or higher. -# -# To use it do the following: -# - Install the latest version of global -# - Enable SOURCE_BROWSER and USE_HTAGS in the config file -# - Make sure the INPUT points to the root of the source tree -# - Run doxygen as normal -# -# Doxygen will invoke htags (and that will in turn invoke gtags), so these -# tools must be available from the command line (i.e. in the search path). -# -# The result: instead of the source browser generated by doxygen, the links to -# source code will now point to the output of htags. -# The default value is: NO. -# This tag requires that the tag SOURCE_BROWSER is set to YES. - -USE_HTAGS = NO - -# If the VERBATIM_HEADERS tag is set the YES then doxygen will generate a -# verbatim copy of the header file for each class for which an include is -# specified. Set to NO to disable this. -# See also: Section \class. -# The default value is: YES. - -VERBATIM_HEADERS = YES - -#--------------------------------------------------------------------------- -# Configuration options related to the alphabetical class index -#--------------------------------------------------------------------------- - -# If the ALPHABETICAL_INDEX tag is set to YES, an alphabetical index of all -# compounds will be generated. Enable this if the project contains a lot of -# classes, structs, unions or interfaces. -# The default value is: YES. - -ALPHABETICAL_INDEX = YES - -# The COLS_IN_ALPHA_INDEX tag can be used to specify the number of columns in -# which the alphabetical index list will be split. -# Minimum value: 1, maximum value: 20, default value: 5. -# This tag requires that the tag ALPHABETICAL_INDEX is set to YES. - -COLS_IN_ALPHA_INDEX = 5 - -# In case all classes in a project start with a common prefix, all classes will -# be put under the same header in the alphabetical index. The IGNORE_PREFIX tag -# can be used to specify a prefix (or a list of prefixes) that should be ignored -# while generating the index headers. -# This tag requires that the tag ALPHABETICAL_INDEX is set to YES. - -IGNORE_PREFIX = - -#--------------------------------------------------------------------------- -# Configuration options related to the HTML output -#--------------------------------------------------------------------------- - -# If the GENERATE_HTML tag is set to YES doxygen will generate HTML output -# The default value is: YES. - -GENERATE_HTML = YES - -# The HTML_OUTPUT tag is used to specify where the HTML docs will be put. If a -# relative path is entered the value of OUTPUT_DIRECTORY will be put in front of -# it. -# The default directory is: html. -# This tag requires that the tag GENERATE_HTML is set to YES. - -HTML_OUTPUT = html - -# The HTML_FILE_EXTENSION tag can be used to specify the file extension for each -# generated HTML page (for example: .htm, .php, .asp). -# The default value is: .html. -# This tag requires that the tag GENERATE_HTML is set to YES. - -HTML_FILE_EXTENSION = .html - -# The HTML_HEADER tag can be used to specify a user-defined HTML header file for -# each generated HTML page. If the tag is left blank doxygen will generate a -# standard header. -# -# To get valid HTML the header file that includes any scripts and style sheets -# that doxygen needs, which is dependent on the configuration options used (e.g. -# the setting GENERATE_TREEVIEW). It is highly recommended to start with a -# default header using -# doxygen -w html new_header.html new_footer.html new_stylesheet.css -# YourConfigFile -# and then modify the file new_header.html. See also section "Doxygen usage" -# for information on how to generate the default header that doxygen normally -# uses. -# Note: The header is subject to change so you typically have to regenerate the -# default header when upgrading to a newer version of doxygen. For a description -# of the possible markers and block names see the documentation. -# This tag requires that the tag GENERATE_HTML is set to YES. - -HTML_HEADER = ./doxygenfiles/eprosima_header.html - -# The HTML_FOOTER tag can be used to specify a user-defined HTML footer for each -# generated HTML page. If the tag is left blank doxygen will generate a standard -# footer. See HTML_HEADER for more information on how to generate a default -# footer and what special commands can be used inside the footer. See also -# section "Doxygen usage" for information on how to generate the default footer -# that doxygen normally uses. -# This tag requires that the tag GENERATE_HTML is set to YES. - -HTML_FOOTER = ./doxygenfiles/eprosima_footer.html - -# The HTML_STYLESHEET tag can be used to specify a user-defined cascading style -# sheet that is used by each HTML page. It can be used to fine-tune the look of -# the HTML output. If left blank doxygen will generate a default style sheet. -# See also section "Doxygen usage" for information on how to generate the style -# sheet that doxygen normally uses. -# Note: It is recommended to use HTML_EXTRA_STYLESHEET instead of this tag, as -# it is more robust and this tag (HTML_STYLESHEET) will in the future become -# obsolete. -# This tag requires that the tag GENERATE_HTML is set to YES. - -HTML_STYLESHEET = ./doxygenfiles/customdoxygen.css - -# The HTML_EXTRA_STYLESHEET tag can be used to specify an additional user- -# defined cascading style sheet that is included after the standard style sheets -# created by doxygen. Using this option one can overrule certain style aspects. -# This is preferred over using HTML_STYLESHEET since it does not replace the -# standard style sheet and is therefor more robust against future updates. -# Doxygen will copy the style sheet file to the output directory. For an example -# see the documentation. -# This tag requires that the tag GENERATE_HTML is set to YES. - -HTML_EXTRA_STYLESHEET = - -# The HTML_EXTRA_FILES tag can be used to specify one or more extra images or -# other source files which should be copied to the HTML output directory. Note -# that these files will be copied to the base HTML output directory. Use the -# $relpath^ marker in the HTML_HEADER and/or HTML_FOOTER files to load these -# files. In the HTML_STYLESHEET file, use the file name only. Also note that the -# files will be copied as-is; there are no commands or markers available. -# This tag requires that the tag GENERATE_HTML is set to YES. - -HTML_EXTRA_FILES = ./doxygenfiles/general_architecture.png - -# The HTML_COLORSTYLE_HUE tag controls the color of the HTML output. Doxygen -# will adjust the colors in the stylesheet and background images according to -# this color. Hue is specified as an angle on a colorwheel, see -# http://en.wikipedia.org/wiki/Hue for more information. For instance the value -# 0 represents red, 60 is yellow, 120 is green, 180 is cyan, 240 is blue, 300 -# purple, and 360 is red again. -# Minimum value: 0, maximum value: 359, default value: 220. -# This tag requires that the tag GENERATE_HTML is set to YES. - -HTML_COLORSTYLE_HUE = 208 - -# The HTML_COLORSTYLE_SAT tag controls the purity (or saturation) of the colors -# in the HTML output. For a value of 0 the output will use grayscales only. A -# value of 255 will produce the most vivid colors. -# Minimum value: 0, maximum value: 255, default value: 100. -# This tag requires that the tag GENERATE_HTML is set to YES. - -HTML_COLORSTYLE_SAT = 221 - -# The HTML_COLORSTYLE_GAMMA tag controls the gamma correction applied to the -# luminance component of the colors in the HTML output. Values below 100 -# gradually make the output lighter, whereas values above 100 make the output -# darker. The value divided by 100 is the actual gamma applied, so 80 represents -# a gamma of 0.8, The value 220 represents a gamma of 2.2, and 100 does not -# change the gamma. -# Minimum value: 40, maximum value: 240, default value: 80. -# This tag requires that the tag GENERATE_HTML is set to YES. - -HTML_COLORSTYLE_GAMMA = 100 - -# If the HTML_TIMESTAMP tag is set to YES then the footer of each generated HTML -# page will contain the date and time when the page was generated. Setting this -# to NO can help when comparing the output of multiple runs. -# The default value is: YES. -# This tag requires that the tag GENERATE_HTML is set to YES. - -HTML_TIMESTAMP = YES - -# If the HTML_DYNAMIC_SECTIONS tag is set to YES then the generated HTML -# documentation will contain sections that can be hidden and shown after the -# page has loaded. -# The default value is: NO. -# This tag requires that the tag GENERATE_HTML is set to YES. - -HTML_DYNAMIC_SECTIONS = NO - -# With HTML_INDEX_NUM_ENTRIES one can control the preferred number of entries -# shown in the various tree structured indices initially; the user can expand -# and collapse entries dynamically later on. Doxygen will expand the tree to -# such a level that at most the specified number of entries are visible (unless -# a fully collapsed tree already exceeds this amount). So setting the number of -# entries 1 will produce a full collapsed tree by default. 0 is a special value -# representing an infinite number of entries and will result in a full expanded -# tree by default. -# Minimum value: 0, maximum value: 9999, default value: 100. -# This tag requires that the tag GENERATE_HTML is set to YES. - -HTML_INDEX_NUM_ENTRIES = 100 - -# If the GENERATE_DOCSET tag is set to YES, additional index files will be -# generated that can be used as input for Apple's Xcode 3 integrated development -# environment (see: http://developer.apple.com/tools/xcode/), introduced with -# OSX 10.5 (Leopard). To create a documentation set, doxygen will generate a -# Makefile in the HTML output directory. Running make will produce the docset in -# that directory and running make install will install the docset in -# ~/Library/Developer/Shared/Documentation/DocSets so that Xcode will find it at -# startup. See http://developer.apple.com/tools/creatingdocsetswithdoxygen.html -# for more information. -# The default value is: NO. -# This tag requires that the tag GENERATE_HTML is set to YES. - -GENERATE_DOCSET = NO - -# This tag determines the name of the docset feed. A documentation feed provides -# an umbrella under which multiple documentation sets from a single provider -# (such as a company or product suite) can be grouped. -# The default value is: Doxygen generated docs. -# This tag requires that the tag GENERATE_DOCSET is set to YES. - -DOCSET_FEEDNAME = "Doxygen generated docs" - -# This tag specifies a string that should uniquely identify the documentation -# set bundle. This should be a reverse domain-name style string, e.g. -# com.mycompany.MyDocSet. Doxygen will append .docset to the name. -# The default value is: org.doxygen.Project. -# This tag requires that the tag GENERATE_DOCSET is set to YES. - -DOCSET_BUNDLE_ID = org.doxygen.Project - -# The DOCSET_PUBLISHER_ID tag specifies a string that should uniquely identify -# the documentation publisher. This should be a reverse domain-name style -# string, e.g. com.mycompany.MyDocSet.documentation. -# The default value is: org.doxygen.Publisher. -# This tag requires that the tag GENERATE_DOCSET is set to YES. - -DOCSET_PUBLISHER_ID = org.doxygen.Publisher - -# The DOCSET_PUBLISHER_NAME tag identifies the documentation publisher. -# The default value is: Publisher. -# This tag requires that the tag GENERATE_DOCSET is set to YES. - -DOCSET_PUBLISHER_NAME = Publisher - -# If the GENERATE_HTMLHELP tag is set to YES then doxygen generates three -# additional HTML index files: index.hhp, index.hhc, and index.hhk. The -# index.hhp is a project file that can be read by Microsoft's HTML Help Workshop -# (see: http://www.microsoft.com/en-us/download/details.aspx?id=21138) on -# Windows. -# -# The HTML Help Workshop contains a compiler that can convert all HTML output -# generated by doxygen into a single compiled HTML file (.chm). Compiled HTML -# files are now used as the Windows 98 help format, and will replace the old -# Windows help format (.hlp) on all Windows platforms in the future. Compressed -# HTML files also contain an index, a table of contents, and you can search for -# words in the documentation. The HTML workshop also contains a viewer for -# compressed HTML files. -# The default value is: NO. -# This tag requires that the tag GENERATE_HTML is set to YES. - -GENERATE_HTMLHELP = NO - -# The CHM_FILE tag can be used to specify the file name of the resulting .chm -# file. You can add a path in front of the file if the result should not be -# written to the html output directory. -# This tag requires that the tag GENERATE_HTMLHELP is set to YES. - -CHM_FILE = - -# The HHC_LOCATION tag can be used to specify the location (absolute path -# including file name) of the HTML help compiler ( hhc.exe). If non-empty -# doxygen will try to run the HTML help compiler on the generated index.hhp. -# The file has to be specified with full path. -# This tag requires that the tag GENERATE_HTMLHELP is set to YES. - -HHC_LOCATION = - -# The GENERATE_CHI flag controls if a separate .chi index file is generated ( -# YES) or that it should be included in the master .chm file ( NO). -# The default value is: NO. -# This tag requires that the tag GENERATE_HTMLHELP is set to YES. - -GENERATE_CHI = NO - -# The CHM_INDEX_ENCODING is used to encode HtmlHelp index ( hhk), content ( hhc) -# and project file content. -# This tag requires that the tag GENERATE_HTMLHELP is set to YES. - -CHM_INDEX_ENCODING = - -# The BINARY_TOC flag controls whether a binary table of contents is generated ( -# YES) or a normal table of contents ( NO) in the .chm file. -# The default value is: NO. -# This tag requires that the tag GENERATE_HTMLHELP is set to YES. - -BINARY_TOC = NO - -# The TOC_EXPAND flag can be set to YES to add extra items for group members to -# the table of contents of the HTML help documentation and to the tree view. -# The default value is: NO. -# This tag requires that the tag GENERATE_HTMLHELP is set to YES. - -TOC_EXPAND = NO - -# If the GENERATE_QHP tag is set to YES and both QHP_NAMESPACE and -# QHP_VIRTUAL_FOLDER are set, an additional index file will be generated that -# can be used as input for Qt's qhelpgenerator to generate a Qt Compressed Help -# (.qch) of the generated HTML documentation. -# The default value is: NO. -# This tag requires that the tag GENERATE_HTML is set to YES. - -GENERATE_QHP = NO - -# If the QHG_LOCATION tag is specified, the QCH_FILE tag can be used to specify -# the file name of the resulting .qch file. The path specified is relative to -# the HTML output folder. -# This tag requires that the tag GENERATE_QHP is set to YES. - -QCH_FILE = - -# The QHP_NAMESPACE tag specifies the namespace to use when generating Qt Help -# Project output. For more information please see Qt Help Project / Namespace -# (see: http://qt-project.org/doc/qt-4.8/qthelpproject.html#namespace). -# The default value is: org.doxygen.Project. -# This tag requires that the tag GENERATE_QHP is set to YES. - -QHP_NAMESPACE = org.doxygen.Project - -# The QHP_VIRTUAL_FOLDER tag specifies the namespace to use when generating Qt -# Help Project output. For more information please see Qt Help Project / Virtual -# Folders (see: http://qt-project.org/doc/qt-4.8/qthelpproject.html#virtual- -# folders). -# The default value is: doc. -# This tag requires that the tag GENERATE_QHP is set to YES. - -QHP_VIRTUAL_FOLDER = doc - -# If the QHP_CUST_FILTER_NAME tag is set, it specifies the name of a custom -# filter to add. For more information please see Qt Help Project / Custom -# Filters (see: http://qt-project.org/doc/qt-4.8/qthelpproject.html#custom- -# filters). -# This tag requires that the tag GENERATE_QHP is set to YES. - -QHP_CUST_FILTER_NAME = - -# The QHP_CUST_FILTER_ATTRS tag specifies the list of the attributes of the -# custom filter to add. For more information please see Qt Help Project / Custom -# Filters (see: http://qt-project.org/doc/qt-4.8/qthelpproject.html#custom- -# filters). -# This tag requires that the tag GENERATE_QHP is set to YES. - -QHP_CUST_FILTER_ATTRS = - -# The QHP_SECT_FILTER_ATTRS tag specifies the list of the attributes this -# project's filter section matches. Qt Help Project / Filter Attributes (see: -# http://qt-project.org/doc/qt-4.8/qthelpproject.html#filter-attributes). -# This tag requires that the tag GENERATE_QHP is set to YES. - -QHP_SECT_FILTER_ATTRS = - -# The QHG_LOCATION tag can be used to specify the location of Qt's -# qhelpgenerator. If non-empty doxygen will try to run qhelpgenerator on the -# generated .qhp file. -# This tag requires that the tag GENERATE_QHP is set to YES. - -QHG_LOCATION = - -# If the GENERATE_ECLIPSEHELP tag is set to YES, additional index files will be -# generated, together with the HTML files, they form an Eclipse help plugin. To -# install this plugin and make it available under the help contents menu in -# Eclipse, the contents of the directory containing the HTML and XML files needs -# to be copied into the plugins directory of eclipse. The name of the directory -# within the plugins directory should be the same as the ECLIPSE_DOC_ID value. -# After copying Eclipse needs to be restarted before the help appears. -# The default value is: NO. -# This tag requires that the tag GENERATE_HTML is set to YES. - -GENERATE_ECLIPSEHELP = NO - -# A unique identifier for the Eclipse help plugin. When installing the plugin -# the directory name containing the HTML and XML files should also have this -# name. Each documentation set should have its own identifier. -# The default value is: org.doxygen.Project. -# This tag requires that the tag GENERATE_ECLIPSEHELP is set to YES. - -ECLIPSE_DOC_ID = org.doxygen.Project - -# If you want full control over the layout of the generated HTML pages it might -# be necessary to disable the index and replace it with your own. The -# DISABLE_INDEX tag can be used to turn on/off the condensed index (tabs) at top -# of each HTML page. A value of NO enables the index and the value YES disables -# it. Since the tabs in the index contain the same information as the navigation -# tree, you can set this option to YES if you also set GENERATE_TREEVIEW to YES. -# The default value is: NO. -# This tag requires that the tag GENERATE_HTML is set to YES. - -DISABLE_INDEX = NO - -# The GENERATE_TREEVIEW tag is used to specify whether a tree-like index -# structure should be generated to display hierarchical information. If the tag -# value is set to YES, a side panel will be generated containing a tree-like -# index structure (just like the one that is generated for HTML Help). For this -# to work a browser that supports JavaScript, DHTML, CSS and frames is required -# (i.e. any modern browser). Windows users are probably better off using the -# HTML help feature. Via custom stylesheets (see HTML_EXTRA_STYLESHEET) one can -# further fine-tune the look of the index. As an example, the default style -# sheet generated by doxygen has an example that shows how to put an image at -# the root of the tree instead of the PROJECT_NAME. Since the tree basically has -# the same information as the tab index, you could consider setting -# DISABLE_INDEX to YES when enabling this option. -# The default value is: NO. -# This tag requires that the tag GENERATE_HTML is set to YES. - -GENERATE_TREEVIEW = YES - -# The ENUM_VALUES_PER_LINE tag can be used to set the number of enum values that -# doxygen will group on one line in the generated HTML documentation. -# -# Note that a value of 0 will completely suppress the enum values from appearing -# in the overview section. -# Minimum value: 0, maximum value: 20, default value: 4. -# This tag requires that the tag GENERATE_HTML is set to YES. - -ENUM_VALUES_PER_LINE = 4 - -# If the treeview is enabled (see GENERATE_TREEVIEW) then this tag can be used -# to set the initial width (in pixels) of the frame in which the tree is shown. -# Minimum value: 0, maximum value: 1500, default value: 250. -# This tag requires that the tag GENERATE_HTML is set to YES. - -TREEVIEW_WIDTH = 250 - -# When the EXT_LINKS_IN_WINDOW option is set to YES doxygen will open links to -# external symbols imported via tag files in a separate window. -# The default value is: NO. -# This tag requires that the tag GENERATE_HTML is set to YES. - -EXT_LINKS_IN_WINDOW = NO - -# Use this tag to change the font size of LaTeX formulas included as images in -# the HTML documentation. When you change the font size after a successful -# doxygen run you need to manually remove any form_*.png images from the HTML -# output directory to force them to be regenerated. -# Minimum value: 8, maximum value: 50, default value: 10. -# This tag requires that the tag GENERATE_HTML is set to YES. - -FORMULA_FONTSIZE = 10 - -# Use the FORMULA_TRANPARENT tag to determine whether or not the images -# generated for formulas are transparent PNGs. Transparent PNGs are not -# supported properly for IE 6.0, but are supported on all modern browsers. -# -# Note that when changing this option you need to delete any form_*.png files in -# the HTML output directory before the changes have effect. -# The default value is: YES. -# This tag requires that the tag GENERATE_HTML is set to YES. - -FORMULA_TRANSPARENT = YES - -# Enable the USE_MATHJAX option to render LaTeX formulas using MathJax (see -# http://www.mathjax.org) which uses client side Javascript for the rendering -# instead of using prerendered bitmaps. Use this if you do not have LaTeX -# installed or if you want to formulas look prettier in the HTML output. When -# enabled you may also need to install MathJax separately and configure the path -# to it using the MATHJAX_RELPATH option. -# The default value is: NO. -# This tag requires that the tag GENERATE_HTML is set to YES. - -USE_MATHJAX = NO - -# When MathJax is enabled you can set the default output format to be used for -# the MathJax output. See the MathJax site (see: -# http://docs.mathjax.org/en/latest/output.html) for more details. -# Possible values are: HTML-CSS (which is slower, but has the best -# compatibility), NativeMML (i.e. MathML) and SVG. -# The default value is: HTML-CSS. -# This tag requires that the tag USE_MATHJAX is set to YES. - -MATHJAX_FORMAT = HTML-CSS - -# When MathJax is enabled you need to specify the location relative to the HTML -# output directory using the MATHJAX_RELPATH option. The destination directory -# should contain the MathJax.js script. For instance, if the mathjax directory -# is located at the same level as the HTML output directory, then -# MATHJAX_RELPATH should be ../mathjax. The default value points to the MathJax -# Content Delivery Network so you can quickly see the result without installing -# MathJax. However, it is strongly recommended to install a local copy of -# MathJax from http://www.mathjax.org before deployment. -# The default value is: http://cdn.mathjax.org/mathjax/latest. -# This tag requires that the tag USE_MATHJAX is set to YES. - -MATHJAX_RELPATH = http://cdn.mathjax.org/mathjax/latest - -# The MATHJAX_EXTENSIONS tag can be used to specify one or more MathJax -# extension names that should be enabled during MathJax rendering. For example -# MATHJAX_EXTENSIONS = TeX/AMSmath TeX/AMSsymbols -# This tag requires that the tag USE_MATHJAX is set to YES. - -MATHJAX_EXTENSIONS = - -# The MATHJAX_CODEFILE tag can be used to specify a file with javascript pieces -# of code that will be used on startup of the MathJax code. See the MathJax site -# (see: http://docs.mathjax.org/en/latest/output.html) for more details. For an -# example see the documentation. -# This tag requires that the tag USE_MATHJAX is set to YES. - -MATHJAX_CODEFILE = - -# When the SEARCHENGINE tag is enabled doxygen will generate a search box for -# the HTML output. The underlying search engine uses javascript and DHTML and -# should work on any modern browser. Note that when using HTML help -# (GENERATE_HTMLHELP), Qt help (GENERATE_QHP), or docsets (GENERATE_DOCSET) -# there is already a search function so this one should typically be disabled. -# For large projects the javascript based search engine can be slow, then -# enabling SERVER_BASED_SEARCH may provide a better solution. It is possible to -# search using the keyboard; to jump to the search box use + S -# (what the is depends on the OS and browser, but it is typically -# , /

    VOBO(t0I?m8}%*?Yb!;kp7BYvT=uacI+8^)6{}c@xR327 zoNu@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gMYv+}Y|5EKg>eZL~eEyb;)o}trcKip!UxUK{ diff --git a/utils/doxygen/pages/mainpage.dox b/utils/doxygen/pages/mainpage.dox deleted file mode 100644 index 4c5fe77330a..00000000000 --- a/utils/doxygen/pages/mainpage.dox +++ /dev/null @@ -1,60 +0,0 @@ -/*! - * @mainpage eProsima Fast DDS library. - *

    - *

    Purpose

    - * Real-Time Publish-Subscribe (RTPS) is the wire interoperability protocol defined for the Data-Distribution Service (DDS) standard by - *the Object Management Group (OMG) consortium. This protocol standard is also defined by the OMG in the specification document - *“The Real-Time Publish-Subscribe Wire Protocol. DDS Interoperability Wire Protocol Specification (DDS-RTPS)” that can - *be obtained from the OMG web-page. The main objective of this specification is that all RTPSParticipants in a DDS communication - *structure, even if they use different vendor's implementations, can interoperate. - *

    - *

    Scope

    - * The scope of this implementation is going to be limited by the RTPS protocol specification of the OMG. Since the main purpose - *of this design is to facilitate the implementation of a standalone RTPS wire protocol as close to the specification as possible, - *the included features will be the ones described in the OMG document. The OMG specification defines message formats, interpretation - *and usage scenarios for any application willing to use RTPS protocol -* The most important features are: -*
      -*
    • Enable best-effort and reliable publish-subscribe communications for real-time applications.
    • -*
    • Plug and play connectivity so that any new applications are automatically discovered by the other members of the network.
    • -*
    • Modularity and scalability to allow continuous growth with both complex and simple devices in the network.
    • -*
    - * - *

    System architecture

    - * A general view of the system architecture can be found below: - * - * The Fast DDS library provides the user with two different layers to access its capabilities. The first is the RTPS layer, contained in the - * RTPSDomain. Using this layer, the user can directly create RTPSWriter and RTPSReader type objects and access their - * corresponding Histories. To facilitate the use of this layer an additional Publication-Subscription layer has - * been developed. This second layer allows the user to create Publishers and Subscribers associated to certain topics and - * transmit user-defined TopicDataTypes between them. - -

    Behavior Implementation

    -The correct behavior of the RTPS protocol will be achieved by using an event-based implementation. Multiple events will be handled by different threads allowing the application to efficiently tackle the different tasks. The thread structure, as well as the main events will be discussed in this section. -
    -

    Thread Structure

    -For each RTPSParticipant, various threads will be spawned to manage different aspects of the RTPS implementation. Each application using this implementation will at least have the following threads: -
    • Main thread: This will be the thread managed by the application or the user. The user will interact with the objects through the defined public APIs. -
    • Receive thread: These threads will be in charge of listening to the different ports. Since these threads will be blocked until a RTPS message is received there will be a different thread for each different IP-port combination that the RTPSParticipant is listening from. Multiple endpoints can be assigned to the same listening thread. -
    • Event thread(s): This thread will be in charge of processing events triggered by some periodic condition, or by actions performed by the user in the main thread. In this version a single event thread will be created and used per RTPSParticipant. -
    - -

    Resource Structure

    -There are three main types of resources in the implementation, that directly correspond with three classes. All resources are managed by the RTPSParticipant. -
    • ResourceListen: Each listen resource is assigned to a single IP:port combination. It receives and processes messages directed to that socket and performs the necessary actions in one or more of the associated Writers or Readers. In this version each ResourceListen runs a single thread listening to a single socket. Future versions may allow the association of multiple sockets (multiple ResourceListen objects) with a single listen thread. -
    • ResourceEvent: This resource manages the time-delayed event triggered periodically or by some message-based event. A single resource is implemented per RTPSParticipant, with a single thread performing all the actions. Future versions may include multiple ResourceEvents running in multiple threads to improve performance. -
    • Event thread(s): This resource manages ALL send operations in the RTPSParticipant. This means that all endpoints included in an RTPSParticipant send their messages through the socket defined in this resource. All messages are send synchronously. Future versions will include multiple ResourceSend objects and the possibility to asynchronously send messages. -
    - - -

    Main events

    -There are multiple events that are triggered wither directly by some action performed by the user, the reception of messages or even periodically. A list of the main events and the actions that need to be performed after them is included below, whereas a detailed description of all the events associated with each class of the design will be included in the detailed implementation chapter. -
    • User-triggered events: These events are triggered directly after the user performs some action, either directly to the RTPS Writer or its associated HistoryCache. -
    • Message-triggered events: These events are triggered by the reception of an RTPS message. For example, the reception of an ACKNACK message would trigger a change in the status of some CacheChanges in the HistoryCache and, maybe, the re-send of some packets to a specific Reader. -
    • Periodic events: Some events must be triggered periodically according to DDS rules. For example, heartbeat packets must be send each heartbeatPeriod to all matching Readers. -
    -
    -* - */ - - diff --git a/utils/futureCode/ReceivedChanges.cpp b/utils/futureCode/ReceivedChanges.cpp deleted file mode 100644 index 6618b6d91c8..00000000000 --- a/utils/futureCode/ReceivedChanges.cpp +++ /dev/null @@ -1,83 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file ReceivedChanges.cpp - * - */ - -#include "ReceivedChanges.h" - -namespace eprosima { -namespace fastrtps { -namespace rtps { - -ReceivedChanges::ReceivedChanges() { - // TODO Auto-generated constructor stub -m_missingChanges.reserve(1000); -} - -ReceivedChanges::~ReceivedChanges() { - // TODO Auto-generated destructor stub -} - -bool ReceivedChanges::add(SequenceNumber_t& s) -{ - if(s > this->m_largestSequenceNumberReceived) - { - return insertMissingSequenceNumbers(s); - } - else if(s == this->m_largestSequenceNumberReceived) - { - return false; - } - else if(s < this->m_largestSequenceNumberReceived) - { - return missingSequenceNumberReceived(s); - } - return false; -} - -bool ReceivedChanges::insertMissingSequenceNumbers(SequenceNumber_t& s) -{ - int i = 1; - while(m_largestSequenceNumberReceived+i < s) - { - m_missingChanges.push_back(m_largestSequenceNumberReceived+i); - ++i; - } - m_largestSequenceNumberReceived = s; - return true; -} - -bool ReceivedChanges::missingSequenceNumberReceived(SequenceNumber_t& s) -{ - std::vector::iterator it = m_missingChanges.end(); - while(it > m_missingChanges.begin()) - { - --it; - if(*it == s) - { - m_missingChanges.erase(it); - return true; - } - if(*it< s) - return false; - } - return false; -} - -} -} /* namespace rtps */ -} /* namespace eprosima */ diff --git a/utils/futureCode/ReceivedChanges.h b/utils/futureCode/ReceivedChanges.h deleted file mode 100644 index 210f1b29e64..00000000000 --- a/utils/futureCode/ReceivedChanges.h +++ /dev/null @@ -1,48 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file ReceivedChanges.h - * - */ - -#ifndef RECEIVEDCHANGES_H_ -#define RECEIVEDCHANGES_H_ - -#include "fastrtps/rtps/common/SequenceNumber.h" - -namespace eprosima { -namespace fastrtps { -namespace rtps{ - -class ReceivedChanges { -public: - ReceivedChanges(); - virtual ~ReceivedChanges(); - - bool add(SequenceNumber_t& s); -private: - bool insertMissingSequenceNumbers(SequenceNumber_t& s); - bool missingSequenceNumberReceived(SequenceNumber_t& s); - - std::vector m_missingChanges; - SequenceNumber_t m_largestSequenceNumberReceived; - -}; - -} -} /* namespace rtps */ -} /* namespace eprosima */ - -#endif /* RECEIVEDCHANGES_H_ */ diff --git a/utils/futureCode/SkipList.cpp b/utils/futureCode/SkipList.cpp deleted file mode 100644 index 1338a35ce2e..00000000000 --- a/utils/futureCode/SkipList.cpp +++ /dev/null @@ -1,172 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file SkipList.cpp - * - */ - -#include "SkipList.h" - -#include -#include - -namespace eprosima { -namespace fastrtps{ -namespace rtps { - - -template -SkipNode::~SkipNode() -{ - delete [] mp_fwdNodes; -} - -template -SkipNode::SkipNode(Obj* obj,uint32_t level):m_height(level), -mp_data(obj) -{ - mp_fwdNodes = new SkipNode* [m_height]; - for(int x = 0;x -SkipNode::SkipNode(uint32_t level):m_height(level), -mp_data(nullptr) -{ - mp_fwdNodes = new SkipNode* [m_height]; - for(int x = 0;x -SkipList::SkipList(float probability,uint32_t maxHeight): m_maxHeight(maxHeight), -m_currHeight(0), -m_probability(probability), -mp_head(nullptr), -mp_tails(nullptr) -{ - srand (time(NULL)); - mp_head = new SkipNode(m_maxHeight); - mp_tails = new SkipNode* [m_maxHeight]; - for ( int x = 0; x < m_maxHeight; x++ ) - { - mp_head->mp_fwdNodes[x] = nullptr; - mp_tails[x] = mp_head; - } - -} - -template -SkipList::~SkipList() { - // Walk 0 level nodes and delete all - SkipNode* tmp; - SkipNode* nxt; - tmp = mp_head; - while ( tmp ) - { - nxt = tmp->mp_fwdNodes[0]; - delete tmp; - tmp = nxt; - } - delete [] mp_tails; -} - -template -bool SkipList::insert_at_end(Obj* obj) -{ - SkipNode* tmp = new SkipNode(obj,newLevel()); - for(int x = 0;xm_height;++x) - { - mp_tails[x]->mp_fwdNodes[x] = tmp; - mp_tails[x] = tmp; - } - return true; -} - -template -bool SkipList::insert(Obj* obj) -{ - int lvl = 0, h = 0; - SkipNode** updateVec = new SkipNode* [m_maxHeight]; - SkipNode* tmp = mp_head; - // Figure out where new node goes - for ( h = m_currHeight; h >= 0; h-- ) - { - while (tmp->mp_fwdNodes[h] != nullptr && *tmp->mp_fwdNodes[h]->mp_data < *obj ) - { - tmp = tmp->fwdNodes[h]; - } - updateVec[h] = tmp; - } - tmp = tmp->fwdNodes[0]; //Element just before the one we are inserting. - // If dup, return false - if ( *tmp->mp_data == *obj ) - { - return false; - } - else - { - // Perform an insert - lvl = newLevel(); - if ( lvl > m_currHeight ) - { - for ( int i = m_currHeight; i <= lvl; i++ ) - updateVec[i] = mp_head; - m_currHeight = lvl; - } - // Insert new element - tmp = new SkipNode(obj, lvl); - for ( int i = 0; i < lvl; i++ ) - { - tmp->fwdNodes[i] = updateVec[i]->fwdNodes[i]; - updateVec[i]->fwdNodes[i] = tmp; - } - } - return true; -} - - -template -bool SkipList::remove(Obj* obj) -{ - -} - - - -template -uint32_t SkipList::newLevel() -{ - uint32_t tmpLvl = 1; - // Develop a random number between 1 and maxLvl (node height). - while ((rand01() < m_probability) && - (tmpLvl < m_maxHeight)) - tmpLvl++; - - return tmpLvl; -} - -template -float SkipList::rand01() -{ - return static_cast (rand()) / static_cast (RAND_MAX); -} - -} -} /* namespace rtps */ -} /* namespace eprosima */ diff --git a/utils/futureCode/SkipList.h b/utils/futureCode/SkipList.h deleted file mode 100644 index a09b29b1343..00000000000 --- a/utils/futureCode/SkipList.h +++ /dev/null @@ -1,67 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed 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 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file SkipList.h - * - */ - -#ifndef SKIPLIST_H_ -#define SKIPLIST_H_ - -namespace eprosima { -namespace fastrtps{ -namespace rtps { - -template -class SkipNode -{ -public: - SkipNode(Obj* obj,uint32_t level); - SkipNode(uint32_t level); - ~SkipNode(); - uint32_t m_height; - Obj* mp_data; - SkipNode** mp_fwdNodes; - -}; - - -template -class SkipList { -public: - SkipList(float probability, uint32_t maxHeight); - virtual ~SkipList(); - - bool insert_at_end(Obj* obj); - bool remove(Obj* obj); - bool insert(Obj* obj); - - -private: - uint32_t newLevel(); - float rand01(); - uint32_t m_maxHeight; - uint32_t m_currHeight; - float m_probability; - SkipNode* mp_head; - SkipNode** mp_tails; - -}; - -} -} /* namespace rtps */ -} /* namespace eprosima */ - -#endif /* SKIPLIST_H_ */ diff --git a/utils/images/icon/eprosima_icon.bmp b/utils/images/icon/eprosima_icon.bmp deleted file mode 100644 index 5f75476b6ba2003cb450174f46eb76f8294c5f42..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 9742 zcmeI$KW-aW5PLCbnj;V8o6pvA5NreHy zY*I|V{lnF+$%IS8yHde5ekQqIfFI_)B_;p-%eUW4d;Ivd$PYaG6+huC*|g`IzrOpX z!^!3!nj=Ik#CS9d3Dy#pX4Br$g3`ZT57y6UG-D zKVPG3$a;LqI`<>b3SC3i!+x07?bGpyCTEuK`mC(>KT#&3U;4%8Wi8*;--$aG@uuJM zXBUy#EWM7~?gOI9iog4=b9<{nf-D-`!dS|qtXEq{7HL?@=i{u?%ecb+YBtXhcDM~6w%rHCiJjG*T48^k2>Xx48&$5< zHJ#Y`td-W0L5!AiM%H>=FJW`CR_r>2&B|J{s|%Z#wQ5&vpC6mwh~^w?-H&rx#@AfC h#?v_e{5r4mGa6rUo!598=bvBab$&+UE8gzB{sqTm$Kn70 diff --git a/utils/images/icon/eprosima_icon.ico b/utils/images/icon/eprosima_icon.ico deleted file mode 100644 index 615e83a3a0552f645c936d07ce55f3832c11c3d1..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 99678 zcmeG_2V7Lg(|a6n6ajlzu*M!^FNqjYRIv9NP0>^}F?J~j2v`xN9aSt?u|@xu*w9an zB5+493S#d{G)7Gf@0;0o?>Nr8UY z0HRthC|iJ!#ZIRF?t=)!-hw9pV+y8Q;!g>ehqKwbqP!doqXMy$vZ{{jWNs@>TaOI{%m@IR5uJJjS zSL`I*ac-??Pk7!7?%q;~;Irg#tC~f*0ryZ#`=k(~{}6^$Vs!1)N-HN{0*kpH@Jep#3` zjV4K~h5#Oa6}>CZD-m9og;yOWi>N+G8di01aFe6> z_m#dtl^V`Izo}~Tto!m4wdwjy+`D=TS@; z3RrtqO(ZT3MvA!SP@7G(Uz7L4uKi7K1^+mJ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cdF`}R2A8|?XSowK?Z`1IDk zDw*4RZbW@RA9F)&_w0Dz*6sGiUku~D?yRWLH?#NH$Ku|NGJkVG-gjJDXYybAwl*v8 zCb$}GI~B^&(ifh&^V4k?U{7$V`vK%Vj`#j1|E6zm9a#F34LK?U1z@Zerf%sTa>-v* zsx>3@(@Y4UX5M;h9yk@H*Gv z+?ug4-W%+Cm5PJqN9Nk8FKTA)?&>NHs}?T{t@S8LV)05ER^_EMq~?Q^s0J7E4h>%N zD0fqx@|R?QP?;%k_2`Ipw=XVn&y4MOBxnDpvG=523+`NUYgw6bHsGc|3gjLfY<~Nq zYlE!aom%DmX5aE|l6SouXMZ;M>gkWf21o`97${(%fPn%A3K%G0pn!n_6-WWFgI0!X zZE++Dg~j79N%43AaW9sTPwb1u9RK#R_~)h(P)IOJI<4ya3|v zN(uQ8w^xeCLEKg;E{3==0uWV3fF8oBga8y@3;`@&838O_8G(EnFG3)W#)}XT(|8dA zG%80xegLQ)M*+4h@-v43TNY7JAfILyAd2o-!#EljA{hIkxCqY`v&FcWKDWV;BEZIN zF&||CeGFOiFpqyQVEK#Roz zcCq*KRp7-zT)8|kMY%{u0kkdT;Y5bk9rAE8O=$ypIF4hT6bu2JkhV0B96tob(G!yp z6wM=lj-W7)JW4@f9(laH#UrH=hPxadfEFP-TyYRDMs0}O!gH>82IBUBE?0YuBe%HP zV;u9_D#1he_K;3x7DBAPyBOk_NlqR_i2?;!q>xaNr-j11#GME+nbL&TUo3)bavDKs zn{S(saasv6B7jtd3z2|-fUFp!G@ef@L!&fKX-$h~pCe={@bdSuWOrIT`y3Inr^T~z z%qlOQ4gZu#YJgj z0BsP^@@BpjdGr14^~UoCWs9@-wfCM|q3=KTp1O=Kufz diff --git a/utils/pcTests/Readme.md b/utils/pcTests/Readme.md deleted file mode 100644 index b920f23f575..00000000000 --- a/utils/pcTests/Readme.md +++ /dev/null @@ -1,3 +0,0 @@ -The files on this folder were removed on release 2.0.0. -You can find them on an eariler commit like 852db23cc121652c4f513c43bb2b9a5bb90b1ab6 or -on a previous release like [1.10.0](https://github.com/eProsima/Fast-RTPS/tree/1.10.x/utils/pcTests) \ No newline at end of file diff --git a/utils/scripts/update_generated_code_from_idl.sh b/utils/scripts/update_generated_code_from_idl.sh index 59752c93d00..68c836ce41c 100755 --- a/utils/scripts/update_generated_code_from_idl.sh +++ b/utils/scripts/update_generated_code_from_idl.sh @@ -1,30 +1,27 @@ #!/usr/bin/env bash files_to_exclude=( - './include/fastrtps/types/*' ) -files_needing_typeobject=( - './examples/cpp/dds/ContentFilteredTopicExample/HelloWorld.idl' - './test/blackbox/types/HelloWorld.idl' - './test/blackbox/types/TestIncludeRegression3361.idl' - './test/blackbox/types/TestRegression3361.idl' - './test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestType.idl' - './test/unittest/dynamic_types/idl/Basic.idl' - './test/unittest/dynamic_types/idl/new_features_4_2.idl' - './test/unittest/dynamic_types/idl/Test.idl' - './test/unittest/xtypes/idl/Types.idl' - './test/unittest/xtypes/idl/WideEnum.idl' - './test/xtypes/idl/Types.idl' +files_not_needing_typeobject=( + './include/fastdds/dds/xtypes/type_representation/detail/dds-xtypes_typeobject.idl' + './src/cpp/fastdds/builtin/type_lookup_service/detail/TypeLookupTypes.idl' + './src/cpp/fastdds/builtin/type_lookup_service/detail/rpc_types.idl' ) files_needing_case_sensitive=( - './test/unittest/dynamic_types/idl/new_features_4_2.idl' ) files_needing_output_dir=( './include/fastdds/statistics/types.idl|../../../src/cpp/statistics/types|../../../test/blackbox/types/statistics' - './include/fastdds/statistics/monitorservice_types.idl|../../../src/cpp/statistics/types' + './include/fastdds/statistics/monitorservice_types.idl|../../../src/cpp/statistics/types|../../../test/blackbox/types/statistics' + './include/fastdds/dds/xtypes/type_representation/dds-xtypes_typeobject.idl|./detail' + ) + +files_needing_no_typesupport=( + './include/fastdds/dds/core/detail/DDSReturnCode.idl' + './include/fastdds/dds/core/detail/DDSSecurityReturnCode.idl' + './include/fastdds/dds/xtypes/dynamic_types/detail/dynamic_language_binding.idl' ) red='\E[1;31m' @@ -63,11 +60,13 @@ for idl_file in "${idl_files[@]}"; do cd "${idl_dir}" # Detect if needs type_object. - [[ ${files_needing_typeobject[*]} =~ $idl_file ]] && to_arg='-typeobject' || to_arg='' + [[ ${files_not_needing_typeobject[*]} =~ $idl_file ]] && to_arg='-no-typeobjectsupport' || to_arg='' # Detect if needs case sensitive. [[ ${files_needing_case_sensitive[*]} =~ $idl_file ]] && cs_arg='-cs' || cs_arg='' + [[ ${files_needing_no_typesupport[*]} =~ $idl_file ]] && nosupport_arg='-no-typesupport' || nosupport_arg='' + # Detect if needs output directories. not_processed=true for od_entry in ${files_needing_output_dir[@]}; do @@ -76,14 +75,14 @@ for idl_file in "${idl_files[@]}"; do od_entry_split=(${od_entry//\|/ }) for od_entry_split_element in ${od_entry_split[@]:1}; do od_arg="-d ${od_entry_split_element}" - fastddsgen -cdr both -replace $to_arg $cs_arg $od_arg "$file_from_gen" + fastddsgen -replace -genapi $to_arg $cs_arg $od_arg "$file_from_gen" -no-dependencies done break fi done if $not_processed ; then - fastddsgen -cdr both -replace $to_arg $cs_arg "$file_from_gen" + fastddsgen -replace -genapi $to_arg $cs_arg $nosupport_arg "$file_from_gen" -no-dependencies fi if [[ $? != 0 ]]; then @@ -93,4 +92,18 @@ for idl_file in "${idl_files[@]}"; do cd - done +# Move source files to src/cpp +mv ./include/fastdds/dds/xtypes/type_representation/detail/dds_xtypes_typeobjectCdrAux.ipp ./src/cpp/fastdds/xtypes/type_representation/dds_xtypes_typeobjectCdrAux.ipp +mv ./include/fastdds/dds/xtypes/type_representation/detail/dds_xtypes_typeobjectPubSubTypes.cxx ./src/cpp/fastdds/xtypes/type_representation/dds_xtypes_typeobjectPubSubTypes.cxx + +sed -i 's+"dds_xtypes_typeobjectCdrAux.hpp"++' ./src/cpp/fastdds/xtypes/type_representation/dds_xtypes_typeobjectCdrAux.ipp +sed -i 's+"dds_xtypes_typeobjectCdrAux.hpp"++' ./src/cpp/fastdds/xtypes/type_representation/dds_xtypes_typeobjectPubSubTypes.cxx +sed -i 's+"dds_xtypes_typeobjectPubSubTypes.h"++' ./src/cpp/fastdds/xtypes/type_representation/dds_xtypes_typeobjectPubSubTypes.cxx + +sed -i 's+"../../../../../../include/fastdds/dds/xtypes/type_representation/detail/dds-xtypes_typeobject.hpp"++' ./src/cpp/fastdds/builtin/type_lookup_service/detail/TypeLookupTypes.hpp +sed -i 's+"../../../../../../include/fastdds/dds/core/detail/DDSReturnCode.hpp"++' ./src/cpp/fastdds/builtin/type_lookup_service/detail/TypeLookupTypes.hpp + +sed -i 's+"../../../../../../include/fastdds/dds/xtypes/type_representation/detail/dds-xtypes_typeobjectPubSubTypes.h"++' ./src/cpp/fastdds/builtin/type_lookup_service/detail/TypeLookupTypesPubSubTypes.h +sed -i 's+"../../../../../../include/fastdds/dds/core/detail/DDSReturnCodePubSubTypes.h"++' ./src/cpp/fastdds/builtin/type_lookup_service/detail/TypeLookupTypesPubSubTypes.h + exit $ret_value diff --git a/versions.md b/versions.md index 9725611018d..dd41d9af90c 100644 --- a/versions.md +++ b/versions.md @@ -1,6 +1,36 @@ Forthcoming ----------- +* Rename project to `fastdds`. +* Rename environment variable to `FASTDDS_DEFAULT_PROFILES_FILE` and rename default XML profiles file to `FASTDDS_DEFAULT_PROFILES`. +* Remove API marked as deprecated. +* Removed deprecated FastRTPS API tests. +* Removed no longer supported `FASTRTPS_API_TESTS` CMake options. +* Public API that is no longer public: + * XML Parser API no longer public. + * ParticipantAttributes + * ReplierAttributes + * RequesterAttributes + * PublisherAttributes + * SubscriberAttributes + * All discovery implementation related API + * ProxyPool + * Semaphore + * MessageReceiver + * BuiltinProtocols + * Liveliness implementation related API + * shared_mutex + * StringMatching + * TimeConversion + * TypeLookupService + * DBQueue +* Added create participant methods that use environment XML profile for participant configuration. +* New TypeObjectRegistry class to register/query TypeObjects/TypeIdentifiers. +* New TypeObjectUtils class providing API to build and register TypeObjects/TypeIdentifiers. +* Refactor Dynamic Language Binding API according to OMG XTypes v1.3 specification. +* Refactor ReturnCode complying with OMG DDS specification. +* Calling `DataReader::return_loan` returns `ReturnCode_t::RETCODE_OK` both for empty sequences and for sequences that were not loaned. + Version 2.14.0 -------------- @@ -31,7 +61,7 @@ Version 2.12.0 * Exposed custom payload pool on DDS endpoints declaration * Processing environment variables on XML text * Upgrade to support Fast CDR v2.0.0. - Default encoding is XCDRv1 to maintain interoperability with previous Fast-DDS versions. + Default encoding is XCDRv1 to maintain interoperability with previous Fast DDS versions. Some concerns: - Data type source code generated with Fast DDS-Gen v2 should be regenerated using Fast DDS-Gen v3. - **API break**. Changed a `MEMBER_INVALID` identifier from a `#define` to a `constexpr`.

qnFb~wt)VO4iCF&0KT40cT7<_@hW>irV%B<%YJ_*P=$*VlczyLa!h z#Li#1v1eP?Oqn7T7Qt+MsKr5ae6f-`RNrEodvqiW1hyuxG_7BHT%L z$Rl{-I?QUG=;&Nr$1PW@CKCuF zV|_~oZ4NJOe$69J@Ilf)?4=wlmBzkM3Q|p?os9{)fuy01cki){`4O1f+O2#)qAkc` zeFD2{3442chft`uBLsjONU?rn85aIf74C4!D7H;|R_WLnO-#Yt%kO*U>rC&ZP~@r4 z-22;koR~@C%otEl@`OWmw~f@i#U>?*A z4M9vN?Uj}M35kge?HDoi_Ue?6&<21_S%$P2-|VC3jRl`|@-aki9TwEqA^{|yBtztJ z^U~3&Z+y=J{=8|Tg{Y?Xc1g7eJu$tg`^ppuoa;cY?53g>(@;&G!cdPmDZxuBP$T=h zGd@f0Sm-*%&R-qhicU`3BkynEWftED782OTlAi4iQxaBxB93Uo9i>_%>L*?nSbL$#F}_Jyo0+6A-lF>Y zqLWj__3h%FCjzE7u{!l8Z_qHC8#np=`axm_j!r@;`DLE>AUmZ;(wHjLA&own=ziOOj!K0&p#8jcX zkrMFThLvHSwn{2`V7VRC(9=G6tt0o91A0k`0#`_%pM?ma3wg>8tE^?FWXpdkDuV5N zualE;)B8Nzxq8fH7^a_<^<@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^Ol$^wzSNvIbq9toKkKn%Fd!~31QI2S2&(f&*g#PP};pbikYCk*m; z)JxrB+A%r+;G$iu`72XLoa)%PIhZ?wq4us^@XJ$9n4|S2%jFt@(ukrMAU^*D(Jr>$ zD>I=70PMk@PHu3Z1=zyozx`h#bwiGu?6?5{n>Hi>_7x0qwt+xeI61=qlk$J>@}Xd; zfjpwvlZ)f;T|U!Bly*YkaHym8pT(VjM-soA)*(Uc8!9*c9wvh&JEAK>}Q~U#TO}5h8azwSe%S)Z8L`f;Jx;>^GwGZ=U{|IINp%nXP zw5}xS_bk88o#t;?E+y*sJQpH$WntIw{3=<$XZm$SZPzgUEMb4~TrPm0H_i(YyRs7m a&$W`Kp^ExvE&0VB`v9@uW=mYGp#K9(rq7uG diff --git a/doc/pdf/Fast RTPS - User Manual.odt b/doc/pdf/Fast RTPS - User Manual.odt deleted file mode 100644 index 9f4a3ff045be56516dc7b159424c1cc10f5ad7e6..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 281315 zcmeFZbyOU|_b)g&1WibS1xP{yAq02V;1CGz?hNh@!Gk1_po2SuyH9}N?!h4g3@|th zgR?`v?|07bp7;LPci#T7dtT4!(>-0cZdKi?x^?g8cD0HE2If-$02crV=9rT;?ByU} z0000FC+ZOZXalrx^LDZ@adNV^F*9+qadcqya4=_aG;y_YWpQ+}a4>f?a|c>DxUsld zc)6+kUzm|(nZ$$e0f2{-9K}rC+8t=>U}9tM%IfxCw=7N$R#7U-GK7yPAE8JHW`u%Y82n8gKV5N-WCyzc#8zs#cr^=e3 z&Y7gkn_?`OW-6ZL0nZ9m&Z`F(X?!Wxj07756$S)Hd4{E!hnHH%Ry+Kt^NcO@PAGRy ztando@dLHV)GewvE`M%bF=$^kYhSg7tlRxs_v(R$hK7Fm5*r;I9TD{-_IpM`Lc))P z3=jwu5}Oy9kQb8K`V$0BPtEy~2Z_sRjLwH70zHI!aIl+`+x)-Vogo-C;8%xf6TZyqUV zn<(j+sBa$#8{GO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